From 6e34ee7cc08b4002deb302bbeafacc9838b5012f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:47 +0100 Subject: [PATCH 0001/3340] - patchlevel 108 --- 7.3.108 | 111 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 111 insertions(+) create mode 100644 7.3.108 diff --git a/7.3.108 b/7.3.108 new file mode 100644 index 00000000..91f3ceb9 --- /dev/null +++ b/7.3.108 @@ -0,0 +1,111 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.108 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.108 +Problem: Useless check for NULL when calling vim_free(). +Solution: Remove the check. (Dominique Pelle) +Files: src/eval.c, src/ex_cmds.c, src/os_win32.c + + +*** ../vim-7.3.107/src/eval.c 2011-01-22 01:13:33.000000000 +0100 +--- src/eval.c 2011-01-30 21:37:53.000000000 +0100 +*************** +*** 5106,5114 **** + else + ret = OK; + } +! +! if (alias != NULL) +! vim_free(alias); + } + + *arg = skipwhite(*arg); +--- 5106,5112 ---- + else + ret = OK; + } +! vim_free(alias); + } + + *arg = skipwhite(*arg); +*************** +*** 19807,19813 **** + EMSG2(_("E704: Funcref variable name must start with a capital: %s"), name); + return; + } +! /* Don't allow hiding a function. When "v" is not NULL we migth be + * assigning another function to the same var, the type is checked + * below. */ + if (v == NULL && function_exists(name)) +--- 19805,19811 ---- + EMSG2(_("E704: Funcref variable name must start with a capital: %s"), name); + return; + } +! /* Don't allow hiding a function. When "v" is not NULL we might be + * assigning another function to the same var, the type is checked + * below. */ + if (v == NULL && function_exists(name)) +*** ../vim-7.3.107/src/ex_cmds.c 2010-12-17 18:06:00.000000000 +0100 +--- src/ex_cmds.c 2011-01-30 21:37:53.000000000 +0100 +*************** +*** 5412,5418 **** + vir_T *virp; + int force; + { +! if (old_sub != NULL && force) + vim_free(old_sub); + if (force || old_sub == NULL) + old_sub = viminfo_readstring(virp, 1, TRUE); +--- 5412,5418 ---- + vir_T *virp; + int force; + { +! if (force) + vim_free(old_sub); + if (force || old_sub == NULL) + old_sub = viminfo_readstring(virp, 1, TRUE); +*** ../vim-7.3.107/src/os_win32.c 2010-12-17 20:23:56.000000000 +0100 +--- src/os_win32.c 2011-01-30 21:37:53.000000000 +0100 +*************** +*** 1886,1893 **** + cb->BufferSize.X = cb->Info.dwSize.X; + cb->BufferSize.Y = cb->Info.dwSize.Y; + NumCells = cb->BufferSize.X * cb->BufferSize.Y; +! if (cb->Buffer != NULL) +! vim_free(cb->Buffer); + cb->Buffer = (PCHAR_INFO)alloc(NumCells * sizeof(CHAR_INFO)); + if (cb->Buffer == NULL) + return FALSE; +--- 1886,1892 ---- + cb->BufferSize.X = cb->Info.dwSize.X; + cb->BufferSize.Y = cb->Info.dwSize.Y; + NumCells = cb->BufferSize.X * cb->BufferSize.Y; +! vim_free(cb->Buffer); + cb->Buffer = (PCHAR_INFO)alloc(NumCells * sizeof(CHAR_INFO)); + if (cb->Buffer == NULL) + return FALSE; +*** ../vim-7.3.107/src/version.c 2011-01-22 21:25:07.000000000 +0100 +--- src/version.c 2011-02-01 13:47:07.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 108, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +173. You keep tracking down the email addresses of all your friends + (even childhood friends). + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 23b7277b937c562292ac4f3d829a7f495afde1a5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:48 +0100 Subject: [PATCH 0002/3340] - patchlevel 109 --- 7.3.109 | 266 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 266 insertions(+) create mode 100644 7.3.109 diff --git a/7.3.109 b/7.3.109 new file mode 100644 index 00000000..ce35fb0a --- /dev/null +++ b/7.3.109 @@ -0,0 +1,266 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.109 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.109 +Problem: Processing new Esperanto spell file fails and crashes Vim. + (Dominique Pelle) +Solution: When running out of memory give an error. Handle '?' in + COMPOUNDRULE properly. +Files: src/spell.c + + +*** ../vim-7.3.108/src/spell.c 2010-12-17 18:06:00.000000000 +0100 +--- src/spell.c 2011-02-01 13:43:52.000000000 +0100 +*************** +*** 3634,3640 **** + } + + /* Add all flags to "sl_compallflags". */ +! if (vim_strchr((char_u *)"+*[]/", c) == NULL + && !byte_in_str(slang->sl_compallflags, c)) + { + *ap++ = c; +--- 3634,3640 ---- + } + + /* Add all flags to "sl_compallflags". */ +! if (vim_strchr((char_u *)"?*+[]/", c) == NULL + && !byte_in_str(slang->sl_compallflags, c)) + { + *ap++ = c; +*************** +*** 3664,3670 **** + /* Copy flag to "sl_comprules", unless we run into a wildcard. */ + if (crp != NULL) + { +! if (c == '+' || c == '*') + { + vim_free(slang->sl_comprules); + slang->sl_comprules = NULL; +--- 3664,3670 ---- + /* Copy flag to "sl_comprules", unless we run into a wildcard. */ + if (crp != NULL) + { +! if (c == '?' || c == '+' || c == '*') + { + vim_free(slang->sl_comprules); + slang->sl_comprules = NULL; +*************** +*** 3682,3689 **** + } + else /* normal char, "[abc]" and '*' are copied as-is */ + { +! if (c == '+' || c == '~') +! *pp++ = '\\'; /* "a+" becomes "a\+" */ + #ifdef FEAT_MBYTE + if (enc_utf8) + pp += mb_char2bytes(c, pp); +--- 3682,3689 ---- + } + else /* normal char, "[abc]" and '*' are copied as-is */ + { +! if (c == '?' || c == '+' || c == '~') +! *pp++ = '\\'; /* "a?" becomes "a\?", "a+" becomes "a\+" */ + #ifdef FEAT_MBYTE + if (enc_utf8) + pp += mb_char2bytes(c, pp); +*************** +*** 4951,4956 **** +--- 4951,4958 ---- + + sblock_T *si_blocks; /* memory blocks used */ + long si_blocks_cnt; /* memory blocks allocated */ ++ int si_did_emsg; /* TRUE when ran out of memory */ ++ + long si_compress_cnt; /* words to add before lowering + compression limit */ + wordnode_T *si_first_free; /* List of nodes that have been freed during +*************** +*** 5477,5497 **** + } + else if (is_aff_rule(items, itemcnt, "COMPOUNDRULE", 2)) + { +! /* Concatenate this string to previously defined ones, using a +! * slash to separate them. */ +! l = (int)STRLEN(items[1]) + 1; +! if (compflags != NULL) +! l += (int)STRLEN(compflags) + 1; +! p = getroom(spin, l, FALSE); +! if (p != NULL) + { + if (compflags != NULL) + { +! STRCPY(p, compflags); +! STRCAT(p, "/"); + } +- STRCAT(p, items[1]); +- compflags = p; + } + } + else if (is_aff_rule(items, itemcnt, "COMPOUNDWORDMAX", 2) +--- 5479,5503 ---- + } + else if (is_aff_rule(items, itemcnt, "COMPOUNDRULE", 2)) + { +! /* Don't use the first rule if it is a number. */ +! if (compflags != NULL || *skipdigits(items[1]) != NUL) + { ++ /* Concatenate this string to previously defined ones, ++ * using a slash to separate them. */ ++ l = (int)STRLEN(items[1]) + 1; + if (compflags != NULL) ++ l += (int)STRLEN(compflags) + 1; ++ p = getroom(spin, l, FALSE); ++ if (p != NULL) + { +! if (compflags != NULL) +! { +! STRCPY(p, compflags); +! STRCAT(p, "/"); +! } +! STRCAT(p, items[1]); +! compflags = p; + } + } + } + else if (is_aff_rule(items, itemcnt, "COMPOUNDWORDMAX", 2) +*************** +*** 6291,6297 **** + + for (p = compflags; *p != NUL; ) + { +! if (vim_strchr((char_u *)"/*+[]", *p) != NULL) + /* Copy non-flag characters directly. */ + *tp++ = *p++; + else +--- 6297,6303 ---- + + for (p = compflags; *p != NUL; ) + { +! if (vim_strchr((char_u *)"/?*+[]", *p) != NULL) + /* Copy non-flag characters directly. */ + *tp++ = *p++; + else +*************** +*** 6320,6326 **** + { + check_renumber(spin); + id = spin->si_newcompID--; +! } while (vim_strchr((char_u *)"/+*[]\\-^", id) != NULL); + ci->ci_newID = id; + hash_add(&aff->af_comp, ci->ci_key); + } +--- 6326,6332 ---- + { + check_renumber(spin); + id = spin->si_newcompID--; +! } while (vim_strchr((char_u *)"/?*+[]\\-^", id) != NULL); + ci->ci_newID = id; + hash_add(&aff->af_comp, ci->ci_key); + } +*************** +*** 7364,7373 **** + + if (bl == NULL || bl->sb_used + len > SBLOCKSIZE) + { +! /* Allocate a block of memory. This is not freed until much later. */ +! bl = (sblock_T *)alloc_clear((unsigned)(sizeof(sblock_T) + SBLOCKSIZE)); + if (bl == NULL) + return NULL; + bl->sb_next = spin->si_blocks; + spin->si_blocks = bl; + bl->sb_used = 0; +--- 7370,7390 ---- + + if (bl == NULL || bl->sb_used + len > SBLOCKSIZE) + { +! if (len >= SBLOCKSIZE) +! bl = NULL; +! else +! /* Allocate a block of memory. It is not freed until much later. */ +! bl = (sblock_T *)alloc_clear( +! (unsigned)(sizeof(sblock_T) + SBLOCKSIZE)); + if (bl == NULL) ++ { ++ if (!spin->si_did_emsg) ++ { ++ EMSG(_("E845: Insufficient memory, word list will be incomplete")); ++ spin->si_did_emsg = TRUE; ++ } + return NULL; ++ } + bl->sb_next = spin->si_blocks; + spin->si_blocks = bl; + bl->sb_used = 0; +*************** +*** 7382,7387 **** +--- 7399,7405 ---- + + /* + * Make a copy of a string into memory allocated with getroom(). ++ * Returns NULL when out of memory. + */ + static char_u * + getroom_save(spin, s) +*************** +*** 7416,7421 **** +--- 7434,7440 ---- + + /* + * Allocate the root of a word tree. ++ * Returns NULL when out of memory. + */ + static wordnode_T * + wordtree_alloc(spin) +*************** +*** 7700,7705 **** +--- 7719,7725 ---- + /* + * Get a wordnode_T, either from the list of previously freed nodes or + * allocate a new one. ++ * Returns NULL when out of memory. + */ + static wordnode_T * + get_wordnode(spin) +*************** +*** 7717,7723 **** + --spin->si_free_count; + } + #ifdef SPELL_PRINTTREE +! n->wn_nr = ++spin->si_wordnode_nr; + #endif + return n; + } +--- 7737,7744 ---- + --spin->si_free_count; + } + #ifdef SPELL_PRINTTREE +! if (n != NULL) +! n->wn_nr = ++spin->si_wordnode_nr; + #endif + return n; + } +*** ../vim-7.3.108/src/version.c 2011-02-01 13:48:47.000000000 +0100 +--- src/version.c 2011-02-01 13:56:38.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 109, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +174. You know what a listserv is. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b9f861e8f10ba8dc457f443e03c7068ea56f1bf4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:49 +0100 Subject: [PATCH 0003/3340] - patchlevel 110 --- 7.3.110 | 76 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 7.3.110 diff --git a/7.3.110 b/7.3.110 new file mode 100644 index 00000000..3ffc7f2c --- /dev/null +++ b/7.3.110 @@ -0,0 +1,76 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.110 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.110 +Problem: The "nbsp" item in 'listchars' isn't used for ":list". +Solution: Make it work. (Christian Brabandt) +Files: src/message.c + + +*** ../vim-7.3.109/src/message.c 2011-01-17 20:08:03.000000000 +0100 +--- src/message.c 2011-02-01 17:06:21.000000000 +0100 +*************** +*** 1637,1644 **** + else if (has_mbyte && (l = (*mb_ptr2len)(s)) > 1) + { + col += (*mb_ptr2cells)(s); +! mch_memmove(buf, s, (size_t)l); +! buf[l] = NUL; + msg_puts(buf); + s += l; + continue; +--- 1637,1652 ---- + else if (has_mbyte && (l = (*mb_ptr2len)(s)) > 1) + { + col += (*mb_ptr2cells)(s); +! if (lcs_nbsp != NUL && list && mb_ptr2char(s) == 160) +! { +! mb_char2bytes(lcs_nbsp, buf); +! buf[(*mb_ptr2len)(buf)] = NUL; +! } +! else +! { +! mch_memmove(buf, s, (size_t)l); +! buf[l] = NUL; +! } + msg_puts(buf); + s += l; + continue; +*************** +*** 1664,1669 **** +--- 1672,1682 ---- + attr = hl_attr(HLF_8); + } + } ++ else if (c == 160 && list && lcs_nbsp != NUL) ++ { ++ c = lcs_nbsp; ++ attr = hl_attr(HLF_8); ++ } + else if (c == NUL && list && lcs_eol != NUL) + { + p_extra = (char_u *)""; +*** ../vim-7.3.109/src/version.c 2011-02-01 13:59:44.000000000 +0100 +--- src/version.c 2011-02-01 17:08:31.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 110, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +176. You lie, even to user-friends, about how long you were online yesterday. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 094258983029ab4600268c5518945f332376eaa2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:49 +0100 Subject: [PATCH 0004/3340] - patchlevel 111 --- 7.3.111 | 121 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 121 insertions(+) create mode 100644 7.3.111 diff --git a/7.3.111 b/7.3.111 new file mode 100644 index 00000000..e3cf717c --- /dev/null +++ b/7.3.111 @@ -0,0 +1,121 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.111 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.111 (after 7.3.100) +Problem: Executing a :normal command in 'statusline' evaluation causes the + cursor to move. (Dominique Pelle) +Solution: When updating the cursor for 'cursorbind' allow the cursor beyond + the end of the line. When evaluating 'statusline' temporarily + reset 'cursorbind'. +Files: src/move.c, src/screen.c + + +*** ../vim-7.3.110/src/move.c 2011-01-22 21:05:02.000000000 +0100 +--- src/move.c 2011-02-01 17:36:10.000000000 +0100 +*************** +*** 2846,2851 **** +--- 2846,2852 ---- + colnr_T col = curwin->w_cursor.col; + win_T *old_curwin = curwin; + buf_T *old_curbuf = curbuf; ++ int restart_edit_save; + # ifdef FEAT_VISUAL + int old_VIsual_select = VIsual_select; + int old_VIsual_active = VIsual_active; +*************** +*** 2875,2882 **** + curwin->w_cursor.lnum = line; + curwin->w_cursor.col = col; + +! /* Make sure the cursor is in a valid position. */ + check_cursor(); + # ifdef FEAT_MBYTE + /* Correct cursor for multi-byte character. */ + if (has_mbyte) +--- 2876,2887 ---- + curwin->w_cursor.lnum = line; + curwin->w_cursor.col = col; + +! /* Make sure the cursor is in a valid position. Temporarily set +! * "restart_edit" to allow the cursor to be beyond the EOL. */ +! restart_edit_save = restart_edit; +! restart_edit = TRUE; + check_cursor(); ++ restart_edit = restart_edit_save; + # ifdef FEAT_MBYTE + /* Correct cursor for multi-byte character. */ + if (has_mbyte) +*** ../vim-7.3.110/src/screen.c 2010-12-30 14:57:03.000000000 +0100 +--- src/screen.c 2011-02-01 17:45:45.000000000 +0100 +*************** +*** 6435,6440 **** +--- 6435,6442 ---- + struct stl_hlrec hltab[STL_MAX_ITEM]; + struct stl_hlrec tabtab[STL_MAX_ITEM]; + int use_sandbox = FALSE; ++ win_T *ewp; ++ int p_crb_save; + + /* setup environment for the task at hand */ + if (wp == NULL) +*************** +*** 6513,6526 **** + if (maxwidth <= 0) + return; + + /* Make a copy, because the statusline may include a function call that + * might change the option value and free the memory. */ + stl = vim_strsave(stl); +! width = build_stl_str_hl(wp == NULL ? curwin : wp, +! buf, sizeof(buf), + stl, use_sandbox, + fillchar, maxwidth, hltab, tabtab); + vim_free(stl); + + /* Make all characters printable. */ + p = transstr(buf); +--- 6515,6534 ---- + if (maxwidth <= 0) + return; + ++ /* Temporarily reset 'cursorbind', we don't want a side effect from moving ++ * the cursor away and back. */ ++ ewp = wp == NULL ? curwin : wp; ++ p_crb_save = ewp->w_p_crb; ++ ewp->w_p_crb = FALSE; ++ + /* Make a copy, because the statusline may include a function call that + * might change the option value and free the memory. */ + stl = vim_strsave(stl); +! width = build_stl_str_hl(ewp, buf, sizeof(buf), + stl, use_sandbox, + fillchar, maxwidth, hltab, tabtab); + vim_free(stl); ++ ewp->w_p_crb = p_crb_save; + + /* Make all characters printable. */ + p = transstr(buf); +*** ../vim-7.3.110/src/version.c 2011-02-01 17:12:20.000000000 +0100 +--- src/version.c 2011-02-01 18:00:14.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 111, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +177. You log off of your system because it's time to go to work. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 29545bca4a336757b9c6ed6039955b6103397866 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:49 +0100 Subject: [PATCH 0005/3340] - patchlevel 112 --- 7.3.112 | 63 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 7.3.112 diff --git a/7.3.112 b/7.3.112 new file mode 100644 index 00000000..af9b8818 --- /dev/null +++ b/7.3.112 @@ -0,0 +1,63 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.112 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.112 +Problem: Setting 'statusline' to "%!'asdf%' reads uninitialized memory. +Solution: Check for NUL after %. +Files: src/buffer.c + + +*** ../vim-7.3.111/src/buffer.c 2010-10-27 16:17:56.000000000 +0200 +--- src/buffer.c 2011-02-01 21:40:17.000000000 +0100 +*************** +*** 3364,3370 **** + * or truncated if too long, fillchar is used for all whitespace. + */ + int +! build_stl_str_hl(wp, out, outlen, fmt, use_sandbox, fillchar, maxwidth, hltab, tabtab) + win_T *wp; + char_u *out; /* buffer to write into != NameBuff */ + size_t outlen; /* length of out[] */ +--- 3364,3371 ---- + * or truncated if too long, fillchar is used for all whitespace. + */ + int +! build_stl_str_hl(wp, out, outlen, fmt, use_sandbox, fillchar, +! maxwidth, hltab, tabtab) + win_T *wp; + char_u *out; /* buffer to write into != NameBuff */ + size_t outlen; /* length of out[] */ +*************** +*** 3474,3479 **** +--- 3475,3482 ---- + * Handle one '%' item. + */ + s++; ++ if (*s == NUL) /* ignore trailing % */ ++ break; + if (*s == '%') + { + if (p + 1 >= out + outlen) +*** ../vim-7.3.111/src/version.c 2011-02-01 18:01:06.000000000 +0100 +--- src/version.c 2011-02-01 21:54:01.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 112, + /**/ + +-- +Rule #1: Don't give somebody a tool that he's going to hurt himself with. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ff480b82902c454aceeb2d5384a2ea1058c3b2d3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:50 +0100 Subject: [PATCH 0006/3340] - patchlevel 113 --- 7.3.113 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.113 diff --git a/7.3.113 b/7.3.113 new file mode 100644 index 00000000..a4383ad9 --- /dev/null +++ b/7.3.113 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.113 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.113 +Problem: Windows: Fall back directory for creating temp file is wrong. +Solution: Use "." instead of empty string. (Hong Xu) +Files: src/fileio.c + + +*** ../vim-7.3.112/src/fileio.c 2011-01-17 20:08:03.000000000 +0100 +--- src/fileio.c 2011-02-06 13:14:25.000000000 +0100 +*************** +*** 7459,7465 **** + + STRCPY(itmp, ""); + if (GetTempPath(_MAX_PATH, szTempFile) == 0) +! szTempFile[0] = NUL; /* GetTempPath() failed, use current dir */ + strcpy(buf4, "VIM"); + buf4[2] = extra_char; /* make it "VIa", "VIb", etc. */ + if (GetTempFileName(szTempFile, buf4, 0, itmp) == 0) +--- 7459,7468 ---- + + STRCPY(itmp, ""); + if (GetTempPath(_MAX_PATH, szTempFile) == 0) +! { +! szTempFile[0] = '.'; /* GetTempPath() failed, use current dir */ +! szTempFile[1] = NUL; +! } + strcpy(buf4, "VIM"); + buf4[2] = extra_char; /* make it "VIa", "VIb", etc. */ + if (GetTempFileName(szTempFile, buf4, 0, itmp) == 0) +*** ../vim-7.3.112/src/version.c 2011-02-01 21:54:56.000000000 +0100 +--- src/version.c 2011-02-09 14:46:12.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 113, + /**/ + +-- +'Psychologist' -- Someone who looks at everyone else when +an attractive woman enters the room. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ecce15e19d97f46ec54ab3f9e7a7c58692e6256c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:50 +0100 Subject: [PATCH 0007/3340] - patchlevel 114 --- 7.3.114 | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 7.3.114 diff --git a/7.3.114 b/7.3.114 new file mode 100644 index 00000000..34bdd364 --- /dev/null +++ b/7.3.114 @@ -0,0 +1,50 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.114 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.114 +Problem: Potential problem in initialization when giving an error message + early. +Solution: Initialize 'verbosefile' empty. (Ben Schmidt) +Files: src/option.h + + +*** ../vim-7.3.113/src/option.h 2010-12-02 16:01:23.000000000 +0100 +--- src/option.h 2011-02-09 15:37:36.000000000 +0100 +*************** +*** 854,860 **** +--- 854,864 ---- + # define VE_ONEMORE 8 + #endif + EXTERN long p_verbose; /* 'verbose' */ ++ #ifdef IN_OPTION_C ++ char_u *p_vfile = (char_u *)""; /* used before options are initialized */ ++ #else + EXTERN char_u *p_vfile; /* 'verbosefile' */ ++ #endif + EXTERN int p_warn; /* 'warn' */ + #ifdef FEAT_CMDL_COMPL + EXTERN char_u *p_wop; /* 'wildoptions' */ +*** ../vim-7.3.113/src/version.c 2011-02-09 14:46:58.000000000 +0100 +--- src/version.c 2011-02-09 15:46:17.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 114, + /**/ + +-- +From the classified section of a city newspaper: +Dog for sale: eats anything and is fond of children. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2c24ebe3abe4988191ca2ee55a30ec9885c153c0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:51 +0100 Subject: [PATCH 0008/3340] - patchlevel 115 --- 7.3.115 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.115 diff --git a/7.3.115 b/7.3.115 new file mode 100644 index 00000000..dd36df30 --- /dev/null +++ b/7.3.115 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.115 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.115 +Problem: Vim can crash when tmpnam() returns NULL. +Solution: Check for NULL. (Hong Xu) +Files: src/fileio.c + + +*** ../vim-7.3.114/src/fileio.c 2011-02-09 14:46:58.000000000 +0100 +--- src/fileio.c 2011-02-09 16:14:35.000000000 +0100 +*************** +*** 7483,7490 **** + # else /* WIN3264 */ + + # ifdef USE_TMPNAM + /* tmpnam() will make its own name */ +! if (*tmpnam((char *)itmp) == NUL) + return NULL; + # else + char_u *p; +--- 7483,7493 ---- + # else /* WIN3264 */ + + # ifdef USE_TMPNAM ++ char_u *p; ++ + /* tmpnam() will make its own name */ +! p = tmpnam((char *)itmp); +! if (p == NULL || *p == NUL) + return NULL; + # else + char_u *p; +*** ../vim-7.3.114/src/version.c 2011-02-09 15:59:32.000000000 +0100 +--- src/version.c 2011-02-09 16:44:11.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 115, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +218. Your spouse hands you a gift wrapped magnet with your PC's name + on it and you accuse him or her of genocide. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 57977b8a5ef2247408f6394a714248a2ceeba93e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:51 +0100 Subject: [PATCH 0009/3340] - patchlevel 116 --- 7.3.116 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.116 diff --git a/7.3.116 b/7.3.116 new file mode 100644 index 00000000..ee9543af --- /dev/null +++ b/7.3.116 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.116 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.116 +Problem: 'cursorline' is displayed too short when there are concealed + characters and 'list' is set. (Dennis Preiser) +Solution: Check for 'cursorline' when 'list' is set. (Christian Brabandt) +Files: src/screen.c + + +*** ../vim-7.3.115/src/screen.c 2011-02-01 18:01:06.000000000 +0100 +--- src/screen.c 2011-02-09 16:59:28.000000000 +0100 +*************** +*** 5099,5105 **** + #ifdef FEAT_DIFF + || filler_todo > 0 + #endif +! || (wp->w_p_list && lcs_eol != NUL && p_extra != at_end_str) + || (n_extra != 0 && (c_extra != NUL || *p_extra != NUL))) + ) + { +--- 5099,5109 ---- + #ifdef FEAT_DIFF + || filler_todo > 0 + #endif +! || (wp->w_p_list && lcs_eol != NUL && p_extra != at_end_str +! #ifdef FEAT_SYN_HL +! && !wp->w_p_cul +! #endif +! ) + || (n_extra != 0 && (c_extra != NUL || *p_extra != NUL))) + ) + { +*** ../vim-7.3.115/src/version.c 2011-02-09 16:44:45.000000000 +0100 +--- src/version.c 2011-02-09 17:08:58.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 116, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +219. Your spouse has his or her lawyer deliver the divorce papers... + via e-mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a92fb25a883ec8f9f6ac45a304d7326a73b8256d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:51 +0100 Subject: [PATCH 0010/3340] - patchlevel 117 --- 7.3.117 | 89 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) create mode 100644 7.3.117 diff --git a/7.3.117 b/7.3.117 new file mode 100644 index 00000000..19fcf739 --- /dev/null +++ b/7.3.117 @@ -0,0 +1,89 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.117 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.117 +Problem: On some systems --as-needed does not work, because the "tinfo" + library is included indirectly from "ncurses". (Charles Campbell) +Solution: In configure prefer using "tinfo" instead of "ncurses". +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.116/src/configure.in 2010-11-16 19:25:56.000000000 +0100 +--- src/configure.in 2011-02-09 17:28:16.000000000 +0100 +*************** +*** 2618,2630 **** + AC_MSG_RESULT([empty: automatic terminal library selection]) + dnl On HP-UX 10.10 termcap or termlib should be used instead of + dnl curses, because curses is much slower. +! dnl Newer versions of ncurses are preferred over anything. + dnl Older versions of ncurses have bugs, get a new one! + dnl Digital Unix (OSF1) should use curses (Ronald Schild). + dnl On SCO Openserver should prefer termlib (Roger Cornelius). + case "`uname -s 2>/dev/null`" in +! OSF1|SCO_SV) tlibs="ncurses curses termlib termcap";; +! *) tlibs="ncurses termlib termcap curses";; + esac + for libname in $tlibs; do + AC_CHECK_LIB(${libname}, tgetent,,) +--- 2618,2631 ---- + AC_MSG_RESULT([empty: automatic terminal library selection]) + dnl On HP-UX 10.10 termcap or termlib should be used instead of + dnl curses, because curses is much slower. +! dnl Newer versions of ncurses are preferred over anything, except +! dnl when tinfo has been split off, it conains all we need. + dnl Older versions of ncurses have bugs, get a new one! + dnl Digital Unix (OSF1) should use curses (Ronald Schild). + dnl On SCO Openserver should prefer termlib (Roger Cornelius). + case "`uname -s 2>/dev/null`" in +! OSF1|SCO_SV) tlibs="tinfo ncurses curses termlib termcap";; +! *) tlibs="tinfo ncurses termlib termcap curses";; + esac + for libname in $tlibs; do + AC_CHECK_LIB(${libname}, tgetent,,) +*** ../vim-7.3.116/src/auto/configure 2010-11-16 19:25:56.000000000 +0100 +--- src/auto/configure 2011-02-09 17:29:13.000000000 +0100 +*************** +*** 9886,9894 **** + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: empty: automatic terminal library selection" >&5 + $as_echo "empty: automatic terminal library selection" >&6; } +! case "`uname -s 2>/dev/null`" in +! OSF1|SCO_SV) tlibs="ncurses curses termlib termcap";; +! *) tlibs="ncurses termlib termcap curses";; + esac + for libname in $tlibs; do + as_ac_Lib=`$as_echo "ac_cv_lib_${libname}''_tgetent" | $as_tr_sh` +--- 9886,9894 ---- + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: empty: automatic terminal library selection" >&5 + $as_echo "empty: automatic terminal library selection" >&6; } +! case "`uname -s 2>/dev/null`" in +! OSF1|SCO_SV) tlibs="tinfo ncurses curses termlib termcap";; +! *) tlibs="tinfo ncurses termlib termcap curses";; + esac + for libname in $tlibs; do + as_ac_Lib=`$as_echo "ac_cv_lib_${libname}''_tgetent" | $as_tr_sh` +*** ../vim-7.3.116/src/version.c 2011-02-09 17:09:26.000000000 +0100 +--- src/version.c 2011-02-09 17:41:37.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 117, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +220. Your wife asks for sex and you tell her where to find you on IRC. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7725f6e4b9198f297dfdcc50e98d411b4b511015 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:52 +0100 Subject: [PATCH 0011/3340] - patchlevel 118 --- 7.3.118 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.118 diff --git a/7.3.118 b/7.3.118 new file mode 100644 index 00000000..fecb948b --- /dev/null +++ b/7.3.118 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.118 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.118 +Problem: Ruby uses SIGVTALARM which makes Vim exit. (Alec Tica) +Solution: Ignore SIGVTALARM. (Dominique Pelle) +Files: src/os_unix.c + + +*** ../vim-7.3.117/src/os_unix.c 2010-12-17 16:27:10.000000000 +0100 +--- src/os_unix.c 2011-02-09 18:19:57.000000000 +0100 +*************** +*** 283,289 **** + #ifdef SIGTERM + {SIGTERM, "TERM", TRUE}, + #endif +! #ifdef SIGVTALRM + {SIGVTALRM, "VTALRM", TRUE}, + #endif + #if defined(SIGPROF) && !defined(FEAT_MZSCHEME) && !defined(WE_ARE_PROFILING) +--- 283,289 ---- + #ifdef SIGTERM + {SIGTERM, "TERM", TRUE}, + #endif +! #if defined(SIGVTALRM) && !defined(FEAT_RUBY) + {SIGVTALRM, "VTALRM", TRUE}, + #endif + #if defined(SIGPROF) && !defined(FEAT_MZSCHEME) && !defined(WE_ARE_PROFILING) +*************** +*** 1107,1113 **** + * On Linux, signal is not always handled immediately either. + * See https://bugs.launchpad.net/bugs/291373 + * +! * volatile because it is used in in signal handler sigcont_handler(). + */ + static volatile int sigcont_received; + static RETSIGTYPE sigcont_handler __ARGS(SIGPROTOARG); +--- 1107,1113 ---- + * On Linux, signal is not always handled immediately either. + * See https://bugs.launchpad.net/bugs/291373 + * +! * volatile because it is used in signal handler sigcont_handler(). + */ + static volatile int sigcont_received; + static RETSIGTYPE sigcont_handler __ARGS(SIGPROTOARG); +*** ../vim-7.3.117/src/version.c 2011-02-09 17:42:53.000000000 +0100 +--- src/version.c 2011-02-09 18:46:53.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 118, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +221. Your wife melts your keyboard in the oven. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5b22ed06a49d5775c5a5fe0cd9101486d3fb53ac Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:52 +0100 Subject: [PATCH 0012/3340] - patchlevel 119 --- 7.3.119 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.119 diff --git a/7.3.119 b/7.3.119 new file mode 100644 index 00000000..1547625d --- /dev/null +++ b/7.3.119 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.119 +Problem: Build problem on Mac. (Nicholas Stallard) +Solution: Use "extern" instead of "EXTERN" for p_vfile. +Files: src/option.h + + +*** ../vim-7.3.118/src/option.h 2011-02-09 15:59:32.000000000 +0100 +--- src/option.h 2011-02-12 13:56:50.000000000 +0100 +*************** +*** 857,863 **** + #ifdef IN_OPTION_C + char_u *p_vfile = (char_u *)""; /* used before options are initialized */ + #else +! EXTERN char_u *p_vfile; /* 'verbosefile' */ + #endif + EXTERN int p_warn; /* 'warn' */ + #ifdef FEAT_CMDL_COMPL +--- 857,863 ---- + #ifdef IN_OPTION_C + char_u *p_vfile = (char_u *)""; /* used before options are initialized */ + #else +! extern char_u *p_vfile; /* 'verbosefile' */ + #endif + EXTERN int p_warn; /* 'warn' */ + #ifdef FEAT_CMDL_COMPL +*** ../vim-7.3.118/src/version.c 2011-02-09 18:47:36.000000000 +0100 +--- src/version.c 2011-02-12 13:59:41.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 119, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +237. You tattoo your email address on your forehead. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 72c373ae0004b6e8c2843ae8bf25e7d0851b3c06 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:53 +0100 Subject: [PATCH 0013/3340] - patchlevel 120 --- 7.3.120 | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.120 diff --git a/7.3.120 b/7.3.120 new file mode 100644 index 00000000..04e2f633 --- /dev/null +++ b/7.3.120 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.120 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.120 +Problem: The message for an existing swap file is too long to fit in a 25 + line terminal. +Solution: Make the message shorter. (Chad Miller) +Files: src/memline.c + + +*** ../vim-7.3.119/src/memline.c 2011-01-17 20:08:03.000000000 +0100 +--- src/memline.c 2011-02-13 14:18:08.000000000 +0100 +*************** +*** 4071,4079 **** + } + /* Some of these messages are long to allow translation to + * other languages. */ +! MSG_PUTS(_("\n(1) Another program may be editing the same file.\n If this is the case, be careful not to end up with two\n different instances of the same file when making changes.\n")); +! MSG_PUTS(_(" Quit, or continue with caution.\n")); +! MSG_PUTS(_("\n(2) An edit session for this file crashed.\n")); + MSG_PUTS(_(" If this is the case, use \":recover\" or \"vim -r ")); + msg_outtrans(buf->b_fname); + MSG_PUTS(_("\"\n to recover the changes (see \":help recovery\").\n")); +--- 4071,4079 ---- + } + /* Some of these messages are long to allow translation to + * other languages. */ +! MSG_PUTS(_("\n(1) Another program may be editing the same file. If this is the case,\n be careful not to end up with two different instances of the same\n file when making changes.")); +! MSG_PUTS(_(" Quit, or continue with caution.\n")); +! MSG_PUTS(_("(2) An edit session for this file crashed.\n")); + MSG_PUTS(_(" If this is the case, use \":recover\" or \"vim -r ")); + msg_outtrans(buf->b_fname); + MSG_PUTS(_("\"\n to recover the changes (see \":help recovery\").\n")); +*** ../vim-7.3.119/src/version.c 2011-02-12 13:59:55.000000000 +0100 +--- src/version.c 2011-02-15 11:56:14.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 120, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +257. Your "hundred-and-one" lists include well over 101 items, since you + automatically interpret all numbers in hexadecimal notation. + (hex 101 = decimal 257) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From cdec9e4fe3e94f534bb6146b950ba20fa2850ea3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:53 +0100 Subject: [PATCH 0014/3340] - patchlevel 121 --- 7.3.121 | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 7.3.121 diff --git a/7.3.121 b/7.3.121 new file mode 100644 index 00000000..f51a7747 --- /dev/null +++ b/7.3.121 @@ -0,0 +1,57 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.121 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.121 +Problem: Complicated 'statusline' causes a crash. (Christian Brabandt) +Solution: Check that the number of items is not too big. +Files: src/buffer.c + + +*** ../vim-7.3.120/src/buffer.c 2011-02-01 21:54:56.000000000 +0100 +--- src/buffer.c 2011-02-15 14:00:51.000000000 +0100 +*************** +*** 3460,3465 **** +--- 3461,3478 ---- + prevchar_isitem = FALSE; + for (s = usefmt; *s; ) + { ++ if (curitem == STL_MAX_ITEM) ++ { ++ /* There are too many items. Add the error code to the statusline ++ * to give the user a hint about what went wrong. */ ++ if (p + 6 < out + outlen) ++ { ++ mch_memmove(p, " E541", (size_t)5); ++ p += 5; ++ } ++ break; ++ } ++ + if (*s != NUL && *s != '%') + prevchar_isflag = prevchar_isitem = FALSE; + +*** ../vim-7.3.120/src/version.c 2011-02-15 11:56:56.000000000 +0100 +--- src/version.c 2011-02-15 14:23:39.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 121, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +265. Your reason for not staying in touch with family is that + they do not have e-mail addresses. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 63e282dcbe59747e72e52aef764358b50298ac20 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:54 +0100 Subject: [PATCH 0015/3340] - patchlevel 122 --- 7.3.122 | 100 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 100 insertions(+) create mode 100644 7.3.122 diff --git a/7.3.122 b/7.3.122 new file mode 100644 index 00000000..02e9759b --- /dev/null +++ b/7.3.122 @@ -0,0 +1,100 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.122 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.122 +Problem: Having auto/config.mk in the repository causes problems. +Solution: Remove auto/config.mk from the distribution. In the toplevel + Makefile copy it from the "dist" file. +Files: Makefile, src/Makefile, src/auto/config.mk + + +*** ../vim-7.3.121/Makefile 2010-08-15 21:57:20.000000000 +0200 +--- Makefile 2011-02-12 14:28:09.000000000 +0100 +*************** +*** 23,28 **** +--- 23,31 ---- + # has run can result in compiling with $(CC) empty. + + first: ++ @if test ! -f src/auto/config.mk; then \ ++ cp src/config.mk.dist src/auto/config.mk; \ ++ fi + @echo "Starting make in the src directory." + @echo "If there are problems, cd to the src directory and run make there" + cd src && $(MAKE) $@ +*************** +*** 30,35 **** +--- 33,41 ---- + # Some make programs use the last target for the $@ default; put the other + # targets separately to always let $@ expand to "first" by default. + all install uninstall tools config configure reconfig proto depend lint tags types test testclean clean distclean: ++ @if test ! -f src/auto/config.mk; then \ ++ cp src/config.mk.dist src/auto/config.mk; \ ++ fi + @echo "Starting make in the src directory." + @echo "If there are problems, cd to the src directory and run make there" + cd src && $(MAKE) $@ +*** ../vim-7.3.121/src/Makefile 2010-11-03 22:32:18.000000000 +0100 +--- src/Makefile 2011-02-15 15:21:37.000000000 +0100 +*************** +*** 283,294 **** + + ######################## auto/config.mk ######################## {{{1 + # At this position auto/config.mk is included. When starting from the +! # distribution it is almost empty. After running auto/configure it contains +! # settings that have been discovered for your system. Settings below this +! # include override settings in auto/config.mk! +! +! # Note: if auto/config.mk is lost somehow (e.g., because configure was +! # interrupted), create an empty auto/config.mk file and do "make config". + + # (X) How to include auto/config.mk depends on the version of "make" you have, + # if the current choice doesn't work, try the other one. +--- 283,295 ---- + + ######################## auto/config.mk ######################## {{{1 + # At this position auto/config.mk is included. When starting from the +! # toplevel Makefile it is almost empty. After running auto/configure it +! # contains settings that have been discovered for your system. Settings below +! # this include override settings in auto/config.mk! +! +! # Note: If make fails because auto/config.mk does not exist (it is not +! # included in the repository), do: +! # cp config.mk.dist auto/config.mk + + # (X) How to include auto/config.mk depends on the version of "make" you have, + # if the current choice doesn't work, try the other one. +*** ../vim-7.3.121/src/auto/config.mk 2010-08-16 21:59:00.000000000 +0200 +--- src/auto/config.mk 1970-01-01 01:00:00.000000000 +0100 +*************** +*** 1,5 **** +- the first targets to make vim are: scratch config myself +- srcdir = . +- VIMNAME = vim +- EXNAME = ex +- VIEWNAME = view +--- 0 ---- +*** ../vim-7.3.121/src/version.c 2011-02-15 14:24:42.000000000 +0100 +--- src/version.c 2011-02-15 15:25:07.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 122, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +267. You get an extra phone line so you can get phone calls. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f0928f6eecf8ddcbfae272926cd571b7291a2523 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:54 +0100 Subject: [PATCH 0016/3340] - patchlevel 123 --- 7.3.123 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.123 diff --git a/7.3.123 b/7.3.123 new file mode 100644 index 00000000..0bca41b8 --- /dev/null +++ b/7.3.123 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.123 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.123 +Problem: ml_get error when executing register being recorded into, deleting + lines and 'conceallevel' is set. (ZyX) +Solution: Don't redraw a line for concealing when it doesn't exist. +Files: src/main.c + + +*** ../vim-7.3.122/src/main.c 2010-12-17 18:06:00.000000000 +0100 +--- src/main.c 2011-02-15 16:09:41.000000000 +0100 +*************** +*** 1198,1204 **** + || conceal_cursor_line(curwin) + || need_cursor_line_redraw)) + { +! if (conceal_old_cursor_line != conceal_new_cursor_line) + update_single_line(curwin, conceal_old_cursor_line); + update_single_line(curwin, conceal_new_cursor_line); + curwin->w_valid &= ~VALID_CROW; +--- 1198,1206 ---- + || conceal_cursor_line(curwin) + || need_cursor_line_redraw)) + { +! if (conceal_old_cursor_line != conceal_new_cursor_line +! && conceal_old_cursor_line +! <= curbuf->b_ml.ml_line_count) + update_single_line(curwin, conceal_old_cursor_line); + update_single_line(curwin, conceal_new_cursor_line); + curwin->w_valid &= ~VALID_CROW; +*** ../vim-7.3.122/src/version.c 2011-02-15 15:27:00.000000000 +0100 +--- src/version.c 2011-02-15 16:15:28.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 123, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +268. You get up in the morning and go online before getting your coffee. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c98a974e43273fcb42416196a1f0f1e1daa0f21b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:55 +0100 Subject: [PATCH 0017/3340] - patchlevel 124 --- 7.3.124 | 229 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 229 insertions(+) create mode 100644 7.3.124 diff --git a/7.3.124 b/7.3.124 new file mode 100644 index 00000000..738c2a16 --- /dev/null +++ b/7.3.124 @@ -0,0 +1,229 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.124 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.124 +Problem: When writing a file in binary mode it may be missing the final EOL + if a file previously read was missing the EOL. (Kevin Goodsell) +Solution: Move the write_no_eol_lnum into the buffer struct. +Files: src/structs.h, src/fileio.c, src/globals.h, src/os_unix.c + + +*** ../vim-7.3.123/src/structs.h 2010-10-20 21:22:17.000000000 +0200 +--- src/structs.h 2011-02-15 17:06:34.000000000 +0100 +*************** +*** 1564,1569 **** +--- 1564,1572 ---- + + /* end of buffer options */ + ++ linenr_T b_no_eol_lnum; /* non-zero lnum when last line of next binary ++ * write should not have an end-of-line */ ++ + int b_start_eol; /* last line had eol when it was read */ + int b_start_ffc; /* first char of 'ff' when edit started */ + #ifdef FEAT_MBYTE +*** ../vim-7.3.123/src/fileio.c 2011-02-09 16:44:45.000000000 +0100 +--- src/fileio.c 2011-02-15 17:30:54.000000000 +0100 +*************** +*** 317,323 **** + int using_b_fname; + #endif + +! write_no_eol_lnum = 0; /* in case it was set by the previous read */ + + /* + * If there is no file name yet, use the one for the read file. +--- 317,323 ---- + int using_b_fname; + #endif + +! curbuf->b_no_eol_lnum = 0; /* in case it was set by the previous read */ + + /* + * If there is no file name yet, use the one for the read file. +*************** +*** 2599,2608 **** + + /* + * Trick: We remember if the last line of the read didn't have +! * an eol for when writing it again. This is required for + * ":autocmd FileReadPost *.gz set bin|'[,']!gunzip" to work. + */ +! write_no_eol_lnum = read_no_eol_lnum; + + /* When reloading a buffer put the cursor at the first line that is + * different. */ +--- 2599,2609 ---- + + /* + * Trick: We remember if the last line of the read didn't have +! * an eol even when 'binary' is off, for when writing it again with +! * 'binary' on. This is required for + * ":autocmd FileReadPost *.gz set bin|'[,']!gunzip" to work. + */ +! curbuf->b_no_eol_lnum = read_no_eol_lnum; + + /* When reloading a buffer put the cursor at the first line that is + * different. */ +*************** +*** 2650,2662 **** + FALSE, NULL, eap); + if (msg_scrolled == n) + msg_scroll = m; +! #ifdef FEAT_EVAL + if (aborting()) /* autocmds may abort script processing */ + return FAIL; +! #endif + } + #endif + + if (recoverymode && error) + return FAIL; + return OK; +--- 2651,2667 ---- + FALSE, NULL, eap); + if (msg_scrolled == n) + msg_scroll = m; +! # ifdef FEAT_EVAL + if (aborting()) /* autocmds may abort script processing */ + return FAIL; +! # endif + } + #endif + ++ /* Reset now, following writes should not omit the EOL. Also, the line ++ * number will become invalid because of edits. */ ++ curbuf->b_no_eol_lnum = 0; ++ + if (recoverymode && error) + return FAIL; + return OK; +*************** +*** 4560,4566 **** + if (end == 0 + || (lnum == end + && write_bin +! && (lnum == write_no_eol_lnum + || (lnum == buf->b_ml.ml_line_count && !buf->b_p_eol)))) + { + ++lnum; /* written the line, count it */ +--- 4565,4571 ---- + if (end == 0 + || (lnum == end + && write_bin +! && (lnum == buf->b_no_eol_lnum + || (lnum == buf->b_ml.ml_line_count && !buf->b_p_eol)))) + { + ++lnum; /* written the line, count it */ +*************** +*** 5086,5093 **** + { + aco_save_T aco; + +- write_no_eol_lnum = 0; /* in case it was set by the previous read */ +- + /* + * Apply POST autocommands. + * Careful: The autocommands may call buf_write() recursively! +--- 5091,5096 ---- +*************** +*** 7256,7263 **** + write_lnum_adjust(offset) + linenr_T offset; + { +! if (write_no_eol_lnum != 0) /* only if there is a missing eol */ +! write_no_eol_lnum += offset; + } + + #if defined(TEMPDIRNAMES) || defined(PROTO) +--- 7259,7266 ---- + write_lnum_adjust(offset) + linenr_T offset; + { +! if (curbuf->b_no_eol_lnum != 0) /* only if there is a missing eol */ +! curbuf->b_no_eol_lnum += offset; + } + + #if defined(TEMPDIRNAMES) || defined(PROTO) +*** ../vim-7.3.123/src/globals.h 2010-12-02 21:43:10.000000000 +0100 +--- src/globals.h 2011-02-15 17:06:06.000000000 +0100 +*************** +*** 1057,1066 **** + ; + #endif + +- EXTERN linenr_T write_no_eol_lnum INIT(= 0); /* non-zero lnum when last line +- of next binary write should +- not have an end-of-line */ +- + #ifdef FEAT_WINDOWS + EXTERN int postponed_split INIT(= 0); /* for CTRL-W CTRL-] command */ + EXTERN int postponed_split_flags INIT(= 0); /* args for win_split() */ +--- 1057,1062 ---- +*** ../vim-7.3.123/src/os_unix.c 2011-02-09 18:47:36.000000000 +0100 +--- src/os_unix.c 2011-02-15 17:07:22.000000000 +0100 +*************** +*** 4245,4251 **** + * should not have one. */ + if (lnum != curbuf->b_op_end.lnum + || !curbuf->b_p_bin +! || (lnum != write_no_eol_lnum + && (lnum != + curbuf->b_ml.ml_line_count + || curbuf->b_p_eol))) +--- 4245,4251 ---- + * should not have one. */ + if (lnum != curbuf->b_op_end.lnum + || !curbuf->b_p_bin +! || (lnum != curbuf->b_no_eol_lnum + && (lnum != + curbuf->b_ml.ml_line_count + || curbuf->b_p_eol))) +*************** +*** 4588,4597 **** + { + append_ga_line(&ga); + /* remember that the NL was missing */ +! write_no_eol_lnum = curwin->w_cursor.lnum; + } + else +! write_no_eol_lnum = 0; + ga_clear(&ga); + } + +--- 4588,4597 ---- + { + append_ga_line(&ga); + /* remember that the NL was missing */ +! curbuf->b_no_eol_lnum = curwin->w_cursor.lnum; + } + else +! curbuf->b_no_eol_lnum = 0; + ga_clear(&ga); + } + +*** ../vim-7.3.123/src/version.c 2011-02-15 16:29:54.000000000 +0100 +--- src/version.c 2011-02-15 17:37:38.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 124, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +270. You are subscribed to a mailing list for every piece of software + you use. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c29843deae4de57439b4a55cf3313a475c510a76 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:55 +0100 Subject: [PATCH 0018/3340] - patchlevel 125 --- 7.3.125 | 66 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) create mode 100644 7.3.125 diff --git a/7.3.125 b/7.3.125 new file mode 100644 index 00000000..719fc95e --- /dev/null +++ b/7.3.125 @@ -0,0 +1,66 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.125 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.125 +Problem: MSVC: Problem with quotes in link argument. +Solution: Escape backslashes and quotes. (Weasley) +Files: src/Make_mvc.mak + + +*** ../vim-7.3.124/src/Make_mvc.mak 2010-12-08 14:54:58.000000000 +0100 +--- src/Make_mvc.mak 2011-02-15 17:55:24.000000000 +0100 +*************** +*** 1159,1164 **** +--- 1159,1168 ---- + E0_CFLAGS = $(CFLAGS:\=\\) + E_CFLAGS = $(E0_CFLAGS:"=\") + # ") stop the string ++ # $LINKARGS2 may contain backslashes and double quotes, escape them both. ++ E0_LINKARGS2 = $(LINKARGS2:\=\\) ++ E_LINKARGS2 = $(E0_LINKARGS2:"=\") ++ # ") stop the string + + $(PATHDEF_SRC): auto + @echo creating $(PATHDEF_SRC) +*************** +*** 1167,1173 **** + @echo char_u *default_vim_dir = (char_u *)"$(VIMRCLOC:\=\\)"; >> $(PATHDEF_SRC) + @echo char_u *default_vimruntime_dir = (char_u *)"$(VIMRUNTIMEDIR:\=\\)"; >> $(PATHDEF_SRC) + @echo char_u *all_cflags = (char_u *)"$(CC:\=\\) $(E_CFLAGS)"; >> $(PATHDEF_SRC) +! @echo char_u *all_lflags = (char_u *)"$(link:\=\\) $(LINKARGS1:\=\\) $(LINKARGS2:\=\\)"; >> $(PATHDEF_SRC) + @echo char_u *compiled_user = (char_u *)"$(USERNAME)"; >> $(PATHDEF_SRC) + @echo char_u *compiled_sys = (char_u *)"$(USERDOMAIN)"; >> $(PATHDEF_SRC) + +--- 1171,1177 ---- + @echo char_u *default_vim_dir = (char_u *)"$(VIMRCLOC:\=\\)"; >> $(PATHDEF_SRC) + @echo char_u *default_vimruntime_dir = (char_u *)"$(VIMRUNTIMEDIR:\=\\)"; >> $(PATHDEF_SRC) + @echo char_u *all_cflags = (char_u *)"$(CC:\=\\) $(E_CFLAGS)"; >> $(PATHDEF_SRC) +! @echo char_u *all_lflags = (char_u *)"$(link:\=\\) $(LINKARGS1:\=\\) $(E_LINKARGS2)"; >> $(PATHDEF_SRC) + @echo char_u *compiled_user = (char_u *)"$(USERNAME)"; >> $(PATHDEF_SRC) + @echo char_u *compiled_sys = (char_u *)"$(USERDOMAIN)"; >> $(PATHDEF_SRC) + +*** ../vim-7.3.124/src/version.c 2011-02-15 17:39:14.000000000 +0100 +--- src/version.c 2011-02-15 17:55:49.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 125, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +271. You collect hilarious signatures from all 250 mailing lists you + are subscribed to. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e7adc9900ac3ded0940e64b1e18bedef0d7c8caa Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:55 +0100 Subject: [PATCH 0019/3340] - patchlevel 126 --- 7.3.126 | 63 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 7.3.126 diff --git a/7.3.126 b/7.3.126 new file mode 100644 index 00000000..89d9684f --- /dev/null +++ b/7.3.126 @@ -0,0 +1,63 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.126 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.126 +Problem: Compiler warning for signed pointer. +Solution: Use unsigned int argument for sscanf(). +Files: src/blowfish.c + + +*** ../vim-7.3.125/src/blowfish.c 2010-08-15 21:57:28.000000000 +0200 +--- src/blowfish.c 2010-12-17 19:58:18.000000000 +0100 +*************** +*** 413,418 **** +--- 413,419 ---- + int salt_len; + { + int i, j, keypos = 0; ++ unsigned u; + UINT32_T val, data_l, data_r; + char_u *key; + int keylen; +*************** +*** 432,439 **** + } + for (i = 0; i < keylen; i++) + { +! sscanf((char *)&key[i * 2], "%2x", &j); +! key[i] = j; + } + + mch_memmove(sbx, sbi, 4 * 4 * 256); +--- 433,440 ---- + } + for (i = 0; i < keylen; i++) + { +! sscanf((char *)&key[i * 2], "%2x", &u); +! key[i] = u; + } + + mch_memmove(sbx, sbi, 4 * 4 * 256); +*** ../vim-7.3.125/src/version.c 2011-02-15 18:06:11.000000000 +0100 +--- src/version.c 2011-02-25 14:40:22.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 126, + /**/ + +-- +Why doesn't Tarzan have a beard? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8fda1f7262c71211bc54ba77c9597b7029cbf507 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:56 +0100 Subject: [PATCH 0020/3340] - patchlevel 127 --- 7.3.127 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.127 diff --git a/7.3.127 b/7.3.127 new file mode 100644 index 00000000..518d2f7c --- /dev/null +++ b/7.3.127 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.127 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.127 +Problem: Compiler complains about comma. +Solution: Remove comma after last enum element. +Files: src/ex_cmds2.c + + +*** ../vim-7.3.126/src/ex_cmds2.c 2010-12-17 18:06:00.000000000 +0100 +--- src/ex_cmds2.c 2010-12-17 19:58:37.000000000 +0100 +*************** +*** 1115,1121 **** + static enum + { + PEXP_SUBCMD, /* expand :profile sub-commands */ +! PEXP_FUNC, /* expand :profile func {funcname} */ + } pexpand_what; + + static char *pexpand_cmds[] = { +--- 1115,1121 ---- + static enum + { + PEXP_SUBCMD, /* expand :profile sub-commands */ +! PEXP_FUNC /* expand :profile func {funcname} */ + } pexpand_what; + + static char *pexpand_cmds[] = { +*** ../vim-7.3.126/src/version.c 2011-02-25 14:40:51.000000000 +0100 +--- src/version.c 2011-02-25 14:45:19.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 127, + /**/ + +-- + LAUNCELOT leaps into SHOT with a mighty cry and runs the GUARD through and + hacks him to the floor. Blood. Swashbuckling music (perhaps). + LAUNCELOT races through into the castle screaming. +SECOND SENTRY: Hey! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f31dad7da740ebfb88765d8f4b311375eb57f1cf Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:56 +0100 Subject: [PATCH 0021/3340] - patchlevel 128 --- 7.3.128 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.128 diff --git a/7.3.128 b/7.3.128 new file mode 100644 index 00000000..d4438688 --- /dev/null +++ b/7.3.128 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.128 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.128 +Problem: Another compiler warning for signed pointer. +Solution: Use unsigned int argument for sscanf(). +Files: src/mark.c + + +*** ../vim-7.3.127/src/mark.c 2010-08-15 21:57:25.000000000 +0200 +--- src/mark.c 2010-12-17 20:00:05.000000000 +0100 +*************** +*** 1750,1756 **** + { + if (line[1] != NUL) + { +! sscanf((char *)line + 2, "%ld %u", &pos.lnum, &pos.col); + switch (line[1]) + { + case '"': curbuf->b_last_cursor = pos; break; +--- 1750,1759 ---- + { + if (line[1] != NUL) + { +! unsigned u; +! +! sscanf((char *)line + 2, "%ld %u", &pos.lnum, &u); +! pos.col = u; + switch (line[1]) + { + case '"': curbuf->b_last_cursor = pos; break; +*** ../vim-7.3.127/src/version.c 2011-02-25 14:46:06.000000000 +0100 +--- src/version.c 2011-02-25 15:10:34.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 128, + /**/ + +-- +FATHER: Who are you? +PRINCE: I'm ... your son ... +FATHER: Not you. +LAUNCELOT: I'm ... er ... Sir Launcelot, sir. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 911dc05b23d194e0c088559d452b38f1d0dd160d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:57 +0100 Subject: [PATCH 0022/3340] - patchlevel 129 --- 7.3.129 | 241 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 241 insertions(+) create mode 100644 7.3.129 diff --git a/7.3.129 b/7.3.129 new file mode 100644 index 00000000..10f11d61 --- /dev/null +++ b/7.3.129 @@ -0,0 +1,241 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.129 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.129 +Problem: Using integer like a boolean. +Solution: Nicer check for integer being non-zero. +Files: src/tag.c + + +*** ../vim-7.3.128/src/tag.c 2010-12-17 18:06:00.000000000 +0100 +--- src/tag.c 2010-12-17 17:49:35.000000000 +0100 +*************** +*** 204,210 **** + else + { + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview) + use_tagstack = FALSE; + else + #endif +--- 204,210 ---- + else + { + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview != 0) + use_tagstack = FALSE; + else + #endif +*************** +*** 222,228 **** + )) + { + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview) + { + if (ptag_entry.tagname != NULL + && STRCMP(ptag_entry.tagname, tag) == 0) +--- 222,228 ---- + )) + { + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview != 0) + { + if (ptag_entry.tagname != NULL + && STRCMP(ptag_entry.tagname, tag) == 0) +*************** +*** 278,284 **** + { + if ( + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! g_do_tagpreview ? ptag_entry.tagname == NULL : + #endif + tagstacklen == 0) + { +--- 278,284 ---- + { + if ( + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! g_do_tagpreview != 0 ? ptag_entry.tagname == NULL : + #endif + tagstacklen == 0) + { +*************** +*** 361,367 **** + ) + { + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview) + { + cur_match = ptag_entry.cur_match; + cur_fnum = ptag_entry.cur_fnum; +--- 361,367 ---- + ) + { + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview != 0) + { + cur_match = ptag_entry.cur_match; + cur_fnum = ptag_entry.cur_fnum; +*************** +*** 399,405 **** + prevtagstackidx = tagstackidx; + + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview) + { + cur_match = ptag_entry.cur_match; + cur_fnum = ptag_entry.cur_fnum; +--- 399,405 ---- + prevtagstackidx = tagstackidx; + + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview != 0) + { + cur_match = ptag_entry.cur_match; + cur_fnum = ptag_entry.cur_fnum; +*************** +*** 437,443 **** + } + + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview) + { + if (type != DT_SELECT && type != DT_JUMP) + { +--- 437,443 ---- + } + + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview != 0) + { + if (type != DT_SELECT && type != DT_JUMP) + { +*************** +*** 492,498 **** + if (use_tagstack) + name = tagstack[tagstackidx].tagname; + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! else if (g_do_tagpreview) + name = ptag_entry.tagname; + #endif + else +--- 492,498 ---- + if (use_tagstack) + name = tagstack[tagstackidx].tagname; + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! else if (g_do_tagpreview != 0) + name = ptag_entry.tagname; + #endif + else +*************** +*** 620,626 **** + parse_match(matches[i], &tagp); + if (!new_tag && ( + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! (g_do_tagpreview + && i == ptag_entry.cur_match) || + #endif + (use_tagstack +--- 620,626 ---- + parse_match(matches[i], &tagp); + if (!new_tag && ( + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! (g_do_tagpreview != 0 + && i == ptag_entry.cur_match) || + #endif + (use_tagstack +*************** +*** 962,968 **** + ++tagstackidx; + } + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! else if (g_do_tagpreview) + { + ptag_entry.cur_match = cur_match; + ptag_entry.cur_fnum = cur_fnum; +--- 962,968 ---- + ++tagstackidx; + } + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! else if (g_do_tagpreview != 0) + { + ptag_entry.cur_match = cur_match; + ptag_entry.cur_fnum = cur_fnum; +*************** +*** 3110,3116 **** + #endif + + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview) + { + postponed_split = 0; /* don't split again below */ + curwin_save = curwin; /* Save current window */ +--- 3110,3116 ---- + #endif + + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview != 0) + { + postponed_split = 0; /* don't split again below */ + curwin_save = curwin; /* Save current window */ +*************** +*** 3148,3154 **** + /* A :ta from a help file will keep the b_help flag set. For ":ptag" + * we need to use the flag from the window where we came from. */ + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview) + keep_help_flag = curwin_save->w_buffer->b_help; + else + #endif +--- 3148,3154 ---- + /* A :ta from a help file will keep the b_help flag set. For ":ptag" + * we need to use the flag from the window where we came from. */ + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview != 0) + keep_help_flag = curwin_save->w_buffer->b_help; + else + #endif +*************** +*** 3322,3328 **** + } + + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview && curwin != curwin_save && win_valid(curwin_save)) + { + /* Return cursor to where we were */ + validate_cursor(); +--- 3322,3329 ---- + } + + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! if (g_do_tagpreview != 0 +! && curwin != curwin_save && win_valid(curwin_save)) + { + /* Return cursor to where we were */ + validate_cursor(); +*** ../vim-7.3.128/src/version.c 2011-02-25 15:11:17.000000000 +0100 +--- src/version.c 2011-02-25 15:12:25.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 129, + /**/ + +-- +PRINCE: He's come to rescue me, father. +LAUNCELOT: (embarrassed) Well, let's not jump to conclusions ... + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From baccee5d27f276f0d4182f2f0a14ce4af3a94bf3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:57 +0100 Subject: [PATCH 0023/3340] - patchlevel 130 --- 7.3.130 | 74 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 7.3.130 diff --git a/7.3.130 b/7.3.130 new file mode 100644 index 00000000..3f7db765 --- /dev/null +++ b/7.3.130 @@ -0,0 +1,74 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.130 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.130 +Problem: Variable misplaced in #ifdef. +Solution: Move clipboard_event_time outside of #ifdef. +Files: src/gui_gtk_x11.c + + +*** ../vim-7.3.129/src/gui_gtk_x11.c 2010-08-15 21:57:31.000000000 +0200 +--- src/gui_gtk_x11.c 2010-12-04 15:26:41.000000000 +0100 +*************** +*** 86,94 **** + + #ifdef HAVE_X11_SUNKEYSYM_H + # include +- static guint32 clipboard_event_time = CurrentTime; + #endif + + /* + * Easy-to-use macro for multihead support. + */ +--- 86,95 ---- + + #ifdef HAVE_X11_SUNKEYSYM_H + # include + #endif + ++ static guint32 clipboard_event_time = CurrentTime; ++ + /* + * Easy-to-use macro for multihead support. + */ +*************** +*** 5419,5425 **** + } + + #if defined(FEAT_NETBEANS_INTG) +! /* Process the queued netbeans messages. */ + netbeans_parse_messages(); + #endif + +--- 5420,5426 ---- + } + + #if defined(FEAT_NETBEANS_INTG) +! /* Process any queued netbeans messages. */ + netbeans_parse_messages(); + #endif + +*** ../vim-7.3.129/src/version.c 2011-02-25 15:13:43.000000000 +0100 +--- src/version.c 2011-02-25 15:15:02.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 130, + /**/ + +-- +A vacation is a period of travel during which you find that you +took twice as many clothes and half as much money as you needed. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2398cd017aff0ef291b2d0391a83b42a9c035d28 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:57 +0100 Subject: [PATCH 0024/3340] - patchlevel 131 --- 7.3.131 | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 7.3.131 diff --git a/7.3.131 b/7.3.131 new file mode 100644 index 00000000..e142059f --- /dev/null +++ b/7.3.131 @@ -0,0 +1,47 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.131 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.131 +Problem: Including errno.h too often. +Solution: Don't include errno.h in Unix header file. +Files: src/os_unix.h + + +*** ../vim-7.3.130/src/os_unix.h 2010-08-15 21:57:28.000000000 +0200 +--- src/os_unix.h 2010-12-17 20:05:34.000000000 +0100 +*************** +*** 184,193 **** + + #define BASENAMELEN (MAXNAMLEN - 5) + +- #ifdef HAVE_ERRNO_H +- # include +- #endif +- + #ifdef HAVE_PWD_H + # include + #endif +--- 184,189 ---- +*** ../vim-7.3.130/src/version.c 2011-02-25 15:15:43.000000000 +0100 +--- src/version.c 2011-02-25 15:16:49.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 131, + /**/ + +-- +Overflow on /dev/null, please empty the bit bucket. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f00b18f5f06f705f700a0536f9ae03109f18cbf6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:58 +0100 Subject: [PATCH 0025/3340] - patchlevel 132 --- 7.3.132 | 82 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 82 insertions(+) create mode 100644 7.3.132 diff --git a/7.3.132 b/7.3.132 new file mode 100644 index 00000000..2f0753df --- /dev/null +++ b/7.3.132 @@ -0,0 +1,82 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.132 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.132 +Problem: C++ style comments. +Solution: Change to C comments. +Files: src/if_python3.c + + +*** ../vim-7.3.131/src/if_python3.c 2010-11-16 19:25:56.000000000 +0100 +--- src/if_python3.c 2011-01-16 01:28:35.000000000 +0100 +*************** +*** 22,29 **** + * Adaptations to support both python3.x and python2.x + */ + +! // uncomment this if used with the debug version of python +! // #define Py_DEBUG + + #include "vim.h" + +--- 22,29 ---- + * Adaptations to support both python3.x and python2.x + */ + +! /* uncomment this if used with the debug version of python */ +! /* #define Py_DEBUG */ + + #include "vim.h" + +*************** +*** 74,80 **** + #define PyString_Size(obj) PyUnicode_GET_SIZE(obj) + #define PyString_FromString(repr) PyUnicode_FromString(repr) + +! #if defined(DYNAMIC_PYTHON3) + + # ifndef WIN3264 + # include +--- 74,80 ---- + #define PyString_Size(obj) PyUnicode_GET_SIZE(obj) + #define PyString_FromString(repr) PyUnicode_FromString(repr) + +! #if defined(DYNAMIC_PYTHON3) || defined(PROTO) + + # ifndef WIN3264 + # include +*** ../vim-7.3.131/src/version.c 2011-02-25 15:17:14.000000000 +0100 +--- src/version.c 2011-02-25 15:18:18.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 132, + /**/ + +-- + ** Hello and Welcome to the Psychiatric Hotline ** +If you are obsessive-compulsive, please press 1 repeatedly. +If you are co-dependent, please ask someone to press 2. +If you have multiple personalities, please press 3, 4, 5 and 6. +If you are paranoid-delusional, we know who you are and what you want + - just stay on the line so we can trace the call. +If you are schizophrenic, listen carefully and a little voice will + tell you which number to press next. +If you are manic-depressive, it doesn't matter which number you press + - no one will answer. +If you suffer from panic attacks, push every button you can find. +If you are sane, please hold on - we have the rest of humanity on the + other line and they desparately want to ask you a few questions. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4779b8a1c3f7df8f5637436f3495a2390fa58e9b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:58 +0100 Subject: [PATCH 0026/3340] - patchlevel 133 --- 7.3.133 | 122 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 122 insertions(+) create mode 100644 7.3.133 diff --git a/7.3.133 b/7.3.133 new file mode 100644 index 00000000..d7d99518 --- /dev/null +++ b/7.3.133 @@ -0,0 +1,122 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.133 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.133 +Problem: When using encryption it's not clear what method was used. +Solution: In the file message show "blowfish" when using blowfish. +Files: src/fileio.c + + +*** ../vim-7.3.132/src/fileio.c 2011-02-15 17:39:14.000000000 +0100 +--- src/fileio.c 2011-02-25 16:30:19.000000000 +0100 +*************** +*** 250,255 **** +--- 250,256 ---- + #ifdef FEAT_CRYPT + char_u *cryptkey = NULL; + int did_ask_for_key = FALSE; ++ int crypt_method_used; + #endif + #ifdef FEAT_PERSISTENT_UNDO + context_sha256_T sha_ctx; +*************** +*** 2289,2294 **** +--- 2290,2296 ---- + save_file_ff(curbuf); /* remember the current file format */ + + #ifdef FEAT_CRYPT ++ crypt_method_used = use_crypt_method; + if (cryptkey != NULL) + { + crypt_pop_state(); +*************** +*** 2483,2489 **** + #ifdef FEAT_CRYPT + if (cryptkey != NULL) + { +! STRCAT(IObuff, _("[crypted]")); + c = TRUE; + } + #endif +--- 2485,2494 ---- + #ifdef FEAT_CRYPT + if (cryptkey != NULL) + { +! if (crypt_method_used == 1) +! STRCAT(IObuff, _("[blowfish]")); +! else +! STRCAT(IObuff, _("[crypted]")); + c = TRUE; + } + #endif +*************** +*** 3199,3204 **** +--- 3204,3212 ---- + int write_undo_file = FALSE; + context_sha256_T sha_ctx; + #endif ++ #ifdef FEAT_CRYPT ++ int crypt_method_used; ++ #endif + + if (fname == NULL || *fname == NUL) /* safety check */ + return FAIL; +*************** +*** 4728,4733 **** +--- 4736,4742 ---- + mch_set_acl(wfname, acl); + #endif + #ifdef FEAT_CRYPT ++ crypt_method_used = use_crypt_method; + if (wb_flags & FIO_ENCRYPTED) + crypt_pop_state(); + #endif +*************** +*** 4882,4888 **** + #ifdef FEAT_CRYPT + if (wb_flags & FIO_ENCRYPTED) + { +! STRCAT(IObuff, _("[crypted]")); + c = TRUE; + } + #endif +--- 4891,4900 ---- + #ifdef FEAT_CRYPT + if (wb_flags & FIO_ENCRYPTED) + { +! if (crypt_method_used == 1) +! STRCAT(IObuff, _("[blowfish]")); +! else +! STRCAT(IObuff, _("[crypted]")); + c = TRUE; + } + #endif +*** ../vim-7.3.132/src/version.c 2011-02-25 15:18:46.000000000 +0100 +--- src/version.c 2011-02-25 16:42:58.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 133, + /**/ + +-- + [clop clop] +GUARD #1: Halt! Who goes there? +ARTHUR: It is I, Arthur, son of Uther Pendragon, from the castle of + Camelot. King of the Britons, defeator of the Saxons, sovereign of + all England! +GUARD #1: Pull the other one! + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 506a516169e960201678592d27b9d418ecd31362 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:59 +0100 Subject: [PATCH 0027/3340] - patchlevel 134 --- 7.3.134 | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 7.3.134 diff --git a/7.3.134 b/7.3.134 new file mode 100644 index 00000000..cb20ce43 --- /dev/null +++ b/7.3.134 @@ -0,0 +1,51 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.134 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.134 +Problem: Drag-n-drop doesn't work in KDE Dolphin. +Solution: Add GDK_ACTION_MOVE flag. (Florian Degner) +Files: src/gui_gtk_x11.c + + +*** ../vim-7.3.133/src/gui_gtk_x11.c 2011-02-25 15:15:43.000000000 +0100 +--- src/gui_gtk_x11.c 2011-02-25 17:07:36.000000000 +0100 +*************** +*** 3094,3100 **** + gtk_drag_dest_set(gui.drawarea, + GTK_DEST_DEFAULT_ALL, + targets, n_targets, +! GDK_ACTION_COPY); + } + + /* +--- 3094,3100 ---- + gtk_drag_dest_set(gui.drawarea, + GTK_DEST_DEFAULT_ALL, + targets, n_targets, +! GDK_ACTION_COPY | GDK_ACTION_MOVE); + } + + /* +*** ../vim-7.3.133/src/version.c 2011-02-25 16:52:13.000000000 +0100 +--- src/version.c 2011-02-25 17:08:35.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 134, + /**/ + +-- +Proverb: A nightingale that forgets the lyrics is a hummingbird. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From dc6759a80393345719cc5c0ea25d9afabf053a31 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:59 +0100 Subject: [PATCH 0028/3340] - patchlevel 135 --- 7.3.135 | 90 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) create mode 100644 7.3.135 diff --git a/7.3.135 b/7.3.135 new file mode 100644 index 00000000..ca1ebd68 --- /dev/null +++ b/7.3.135 @@ -0,0 +1,90 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.135 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.135 +Problem: When there is no previous substitute pattern, the previous search + pattern is used. The other way around doesn't work. +Solution: When there is no previous search pattern, use the previous + substitute pattern if possible. (Christian Brabandt) +Files: src/search.c + + +*** ../vim-7.3.134/src/search.c 2010-09-21 16:56:29.000000000 +0200 +--- src/search.c 2011-02-25 18:36:56.000000000 +0100 +*************** +*** 1161,1172 **** + { + if (spats[RE_SEARCH].pat == NULL) /* no previous pattern */ + { +! EMSG(_(e_noprevre)); +! retval = 0; +! goto end_do_search; + } +- /* make search_regcomp() use spats[RE_SEARCH].pat */ +- searchstr = (char_u *)""; + } + + if (pat != NULL && *pat != NUL) /* look for (new) offset */ +--- 1161,1180 ---- + { + if (spats[RE_SEARCH].pat == NULL) /* no previous pattern */ + { +! pat = spats[RE_SUBST].pat; +! if (pat == NULL) +! { +! EMSG(_(e_noprevre)); +! retval = 0; +! goto end_do_search; +! } +! searchstr = pat; +! } +! else +! { +! /* make search_regcomp() use spats[RE_SEARCH].pat */ +! searchstr = (char_u *)""; + } + } + + if (pat != NULL && *pat != NUL) /* look for (new) offset */ +*************** +*** 4527,4533 **** + #if defined(FEAT_FIND_ID) || defined(PROTO) + /* + * Find identifiers or defines in included files. +! * if p_ic && (compl_cont_status & CONT_SOL) then ptr must be in lowercase. + */ + void + find_pattern_in_path(ptr, dir, len, whole, skip_comments, +--- 4535,4541 ---- + #if defined(FEAT_FIND_ID) || defined(PROTO) + /* + * Find identifiers or defines in included files. +! * If p_ic && (compl_cont_status & CONT_SOL) then ptr must be in lowercase. + */ + void + find_pattern_in_path(ptr, dir, len, whole, skip_comments, +*** ../vim-7.3.134/src/version.c 2011-02-25 17:10:22.000000000 +0100 +--- src/version.c 2011-02-25 18:35:30.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 135, + /**/ + +-- +A real patriot is the fellow who gets a parking ticket and rejoices +that the system works. + + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 628e945c8a9907d0eab928a1e2cb766ad468790c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:17:59 +0100 Subject: [PATCH 0029/3340] - patchlevel 136 --- 7.3.136 | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 7.3.136 diff --git a/7.3.136 b/7.3.136 new file mode 100644 index 00000000..87acecb6 --- /dev/null +++ b/7.3.136 @@ -0,0 +1,51 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.136 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.136 +Problem: Duplicate include of assert.h. +Solution: Remove it. +Files: src/if_cscope.c + + +*** ../vim-7.3.135/src/if_cscope.c 2010-12-30 11:41:05.000000000 +0100 +--- src/if_cscope.c 2011-03-03 15:01:15.000000000 +0100 +*************** +*** 13,19 **** + + #if defined(FEAT_CSCOPE) || defined(PROTO) + +- #include + #include + #include + #if defined(UNIX) +--- 13,18 ---- +*** ../vim-7.3.135/src/version.c 2011-02-25 18:38:29.000000000 +0100 +--- src/version.c 2011-03-03 14:59:32.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 136, + /**/ + +-- +ARTHUR: You fight with the strength of many men, Sir knight. + I am Arthur, King of the Britons. [pause] + I seek the finest and the bravest knights in the land to join me + in my Court of Camelot. [pause] + You have proved yourself worthy; will you join me? [pause] + You make me sad. So be it. Come, Patsy. +BLACK KNIGHT: None shall pass. + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 71fd57d381a15421364e5990d3f048fd45af2c92 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:18:01 +0100 Subject: [PATCH 0030/3340] - patchlevel 137 --- 7.3.137 | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 7.3.137 diff --git a/7.3.137 b/7.3.137 new file mode 100644 index 00000000..91f68ed3 --- /dev/null +++ b/7.3.137 @@ -0,0 +1,81 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.137 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.137 (after 7.3.091) +Problem: When 'lazyredraw' is set the screen may not be updated. (Ivan + Krasilnikov) +Solution: Call update_screen() before waiting for input. +Files: src/misc1.c, src/getchar.c + + +*** ../vim-7.3.136/src/misc1.c 2011-01-22 00:11:42.000000000 +0100 +--- src/misc1.c 2011-03-03 14:02:02.000000000 +0100 +*************** +*** 3115,3121 **** +--- 3115,3129 ---- + continue; + + if (n == KEYLEN_REMOVED) /* key code removed */ ++ { ++ if (must_redraw) ++ { ++ /* Redrawing was postponed, do it now. */ ++ update_screen(0); ++ setcursor(); /* put cursor back where it belongs */ ++ } + continue; ++ } + if (n > 0) /* found a termcode: adjust length */ + len = n; + if (len == 0) /* nothing typed yet */ +*** ../vim-7.3.136/src/getchar.c 2010-12-30 12:30:26.000000000 +0100 +--- src/getchar.c 2011-03-03 14:01:26.000000000 +0100 +*************** +*** 2710,2717 **** + * are still available. But when those available characters + * are part of a mapping, and we are going to do a blocking + * wait here. Need to update the screen to display the +! * changed text so far. */ +! if ((State & INSERT) && advance && must_redraw != 0) + { + update_screen(0); + setcursor(); /* put cursor back where it belongs */ +--- 2710,2719 ---- + * are still available. But when those available characters + * are part of a mapping, and we are going to do a blocking + * wait here. Need to update the screen to display the +! * changed text so far. Also for when 'lazyredraw' is set and +! * redrawing was postponed because there was something in the +! * input buffer (e.g., termresponse). */ +! if (((State & INSERT) || p_lz) && advance && must_redraw != 0) + { + update_screen(0); + setcursor(); /* put cursor back where it belongs */ +*** ../vim-7.3.136/src/version.c 2011-03-03 15:01:25.000000000 +0100 +--- src/version.c 2011-03-03 15:02:45.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 137, + /**/ + +-- +ARTHUR: What? +BLACK KNIGHT: None shall pass. +ARTHUR: I have no quarrel with you, good Sir knight, but I must cross + this bridge. +BLACK KNIGHT: Then you shall die. + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d93a1aaec3ef7b82a234c91963ab77e4e7de7260 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:18:02 +0100 Subject: [PATCH 0031/3340] - patchlevel 138 --- 7.3.138 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.138 diff --git a/7.3.138 b/7.3.138 new file mode 100644 index 00000000..e045e790 --- /dev/null +++ b/7.3.138 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.138 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.138 +Problem: ":com" changes the multi-byte text of :echo. (Dimitar Dimitrov) +Solution: Search for K_SPECIAL as a byte, not a character. (Ben Schmidt) +Files: src/ex_docmd.c + + +*** ../vim-7.3.137/src/ex_docmd.c 2011-01-17 19:50:01.000000000 +0100 +--- src/ex_docmd.c 2011-03-03 15:47:00.000000000 +0100 +*************** +*** 6054,6068 **** + end = vim_strchr(start + 1, '>'); + if (buf != NULL) + { +! ksp = vim_strchr(p, K_SPECIAL); +! if (ksp != NULL && (start == NULL || ksp < start || end == NULL) + && ((ksp[1] == KS_SPECIAL && ksp[2] == KE_FILLER) + # ifdef FEAT_GUI + || (ksp[1] == KS_EXTRA && ksp[2] == (int)KE_CSI) + # endif + )) + { +! /* K_SPECIAL han been put in the buffer as K_SPECIAL + * KS_SPECIAL KE_FILLER, like for mappings, but + * do_cmdline() doesn't handle that, so convert it back. + * Also change K_SPECIAL KS_EXTRA KE_CSI into CSI. */ +--- 6054,6070 ---- + end = vim_strchr(start + 1, '>'); + if (buf != NULL) + { +! for (ksp = p; *ksp != NUL && *ksp != K_SPECIAL; ++ksp) +! ; +! if (*ksp == K_SPECIAL +! && (start == NULL || ksp < start || end == NULL) + && ((ksp[1] == KS_SPECIAL && ksp[2] == KE_FILLER) + # ifdef FEAT_GUI + || (ksp[1] == KS_EXTRA && ksp[2] == (int)KE_CSI) + # endif + )) + { +! /* K_SPECIAL has been put in the buffer as K_SPECIAL + * KS_SPECIAL KE_FILLER, like for mappings, but + * do_cmdline() doesn't handle that, so convert it back. + * Also change K_SPECIAL KS_EXTRA KE_CSI into CSI. */ +*** ../vim-7.3.137/src/version.c 2011-03-03 15:04:01.000000000 +0100 +--- src/version.c 2011-03-03 15:53:41.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 138, + /**/ + +-- + f y cn rd ths thn y cn hv grt jb n cmptr prgrmmng + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5b2e52ec4b50ccddec1308a72dd80f6add048414 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 17 Mar 2011 10:18:02 +0100 Subject: [PATCH 0032/3340] - patchlevel 138 --- README.patches | 31 +++++++++++++++++++++++ vim.spec | 69 ++++++++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 98 insertions(+), 2 deletions(-) diff --git a/README.patches b/README.patches index 57760ac6..33227b9a 100644 --- a/README.patches +++ b/README.patches @@ -133,3 +133,34 @@ Individual patches for Vim 7.3: 1539 7.3.105 can't get the value of "b:changedtick" with getbufvar() 1650 7.3.106 other window scrolls if both 'scrollbind' and 'cursorbind' set 1986 7.3.107 year in :undolist can be confusing + 3425 7.3.108 useless check for NULL when calling vim_free() + 7203 7.3.109 processing new Esperanto spell file fails and crashes Vim + 2122 7.3.110 the "nbsp" item in 'listchars' isn't used for ":list" + 4010 7.3.111 :normal command in 'statusline' causes the cursor to move + 1978 7.3.112 setting 'statusline' to "%!'asdf%' reads uninitialized memory + 1838 7.3.113 Windows: Fall back directory for creating temp file is wrong + 1568 7.3.114 potential problem using 'verbosefile' uninitialized + 1645 7.3.115 Vim can crash when tmpnam() returns NULL + 1788 7.3.116 'cursorline' too short with concealed chars and 'list' set + 3835 7.3.117 build failed when --as-needed excludes ncurses + 2283 7.3.118 Ruby uses SIGVTALARM which makes Vim exit + 1637 7.3.119 (after 7.3.114) build problem on Mac + 2597 7.3.120 message for existing swap file does not fit in 25 lines + 1721 7.3.121 crash when using complicated 'statusline' + 3936 7.3.122 having src/auto/config.mk in the distribution causes problems + 1954 7.3.123 ml_get error when 'conceallevel' is set + 6777 7.3.124 EOL may be missing from written file + 2672 7.3.125 MSVC: quote in link argument causes trouble + 1652 7.3.126 compiler warning for signed pointer + 1747 7.3.127 compiler complains about comma after last enum item + 1706 7.3.128 another compiler warning for signed pointer + 6608 7.3.129 using integer like a boolean + 1908 7.3.130 clipboard_event_time misplaced in #ifdef + 1280 7.3.131 including errno.h too often + 2648 7.3.132 C++ style comments + 3169 7.3.133 when using encryption it's not clear what method was used + 1470 7.3.134 drag-n-drop doesn't work in KDE Dolphin + 2678 7.3.135 inconsistency: last substitute pattern isn't used for search + 1653 7.3.136 duplicate include of assert.h + 2881 7.3.137 when 'lazyredraw' is set the screen may not be updated + 2399 7.3.138 ":com" changes the multi-byte text of :echo diff --git a/vim.spec b/vim.spec index d8ea8136..94e5802f 100644 --- a/vim.spec +++ b/vim.spec @@ -18,13 +18,13 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 107 +%define patchlevel 138 Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 2%{?dist} +Release: 1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -171,6 +171,37 @@ Patch104: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.104 Patch105: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.105 Patch106: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.106 Patch107: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.107 +Patch108: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.108 +Patch109: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.109 +Patch110: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.110 +Patch111: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.111 +Patch112: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.112 +Patch113: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.113 +Patch114: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.114 +Patch115: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.115 +Patch116: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.116 +Patch117: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.117 +Patch118: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.118 +Patch119: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.119 +Patch120: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.120 +Patch121: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.121 +Patch122: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.122 +Patch123: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.123 +Patch124: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.124 +Patch125: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.125 +Patch126: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.126 +Patch127: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.127 +Patch128: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.128 +Patch129: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.129 +Patch130: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.130 +Patch131: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.131 +Patch132: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.132 +Patch133: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.133 +Patch134: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.134 +Patch135: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.135 +Patch136: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.136 +Patch137: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.137 +Patch138: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.138 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -422,6 +453,37 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch105 -p0 %patch106 -p0 %patch107 -p0 +%patch108 -p0 +%patch109 -p0 +%patch110 -p0 +%patch111 -p0 +%patch112 -p0 +%patch113 -p0 +%patch114 -p0 +%patch115 -p0 +%patch116 -p0 +%patch117 -p0 +%patch118 -p0 +%patch119 -p0 +%patch120 -p0 +%patch121 -p0 +%patch122 -p0 +%patch123 -p0 +%patch124 -p0 +%patch125 -p0 +%patch126 -p0 +%patch127 -p0 +%patch128 -p0 +%patch129 -p0 +%patch130 -p0 +%patch131 -p0 +%patch132 -p0 +%patch133 -p0 +%patch134 -p0 +%patch135 -p0 +%patch136 -p0 +%patch137 -p0 +%patch138 -p0 # install spell files @@ -889,6 +951,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Thu Mar 17 2011 Karsten Hopp 7.3.138-1 +- patchlevel 138 + * Mon Feb 07 2011 Fedora Release Engineering - 2:7.3.107-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild From 187c4ebd920e3ccdc37cbf753a01a2bfddf1966e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 26 Sep 2011 15:58:46 +0200 Subject: [PATCH 0033/3340] - patchlevel 316 --- 7.3.316 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.316 diff --git a/7.3.316 b/7.3.316 new file mode 100644 index 00000000..96a7d42b --- /dev/null +++ b/7.3.316 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.316 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.316 (after 7.3.306) +Problem: Crash when 'colorcolumn' is set and closing buffer. +Solution: Check for w_buffer to be NULL. (Yasuhiro Matsumoto) +Files: src/option.c + + +*** ../vim-7.3.315/src/option.c 2011-06-12 22:13:37.000000000 +0200 +--- src/option.c 2011-09-21 13:26:31.000000000 +0200 +*************** +*** 7036,7041 **** +--- 7036,7044 ---- + int i; + int j = 0; + ++ if (wp->w_buffer == NULL) ++ return NULL; /* buffer was closed */ ++ + for (s = wp->w_p_cc; *s != NUL && count < 255;) + { + if (*s == '-' || *s == '+') +*** ../vim-7.3.315/src/version.c 2011-09-14 19:04:35.000000000 +0200 +--- src/version.c 2011-09-21 13:40:05.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 316, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +25. You believe nothing looks sexier than a man in boxer shorts illuminated + only by a 17" inch svga monitor. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 98cd3d4a69189703e21b1f7e56491e4095db7515 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 26 Sep 2011 15:58:49 +0200 Subject: [PATCH 0034/3340] - patchlevel 317 --- 7.3.317 | 116 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 116 insertions(+) create mode 100644 7.3.317 diff --git a/7.3.317 b/7.3.317 new file mode 100644 index 00000000..220cae21 --- /dev/null +++ b/7.3.317 @@ -0,0 +1,116 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.317 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.317 +Problem: Calling debug.debug() in Lua may cause Vim to hang. +Solution: Add a better debug method. (Rob Hoelz, Luis Carvalho) +Files: src/if_lua.c + + +*** ../vim-7.3.316/src/if_lua.c 2011-01-17 19:53:20.000000000 +0100 +--- src/if_lua.c 2011-09-21 17:15:21.000000000 +0200 +*************** +*** 100,105 **** +--- 100,106 ---- + #define lua_setfield dll_lua_setfield + #define lua_rawset dll_lua_rawset + #define lua_rawseti dll_lua_rawseti ++ #define lua_remove dll_lua_remove + #define lua_setmetatable dll_lua_setmetatable + #define lua_call dll_lua_call + #define lua_pcall dll_lua_pcall +*************** +*** 161,166 **** +--- 162,168 ---- + void (*dll_lua_setfield) (lua_State *L, int idx, const char *k); + void (*dll_lua_rawset) (lua_State *L, int idx); + void (*dll_lua_rawseti) (lua_State *L, int idx, int n); ++ void (*dll_lua_remove) (lua_State *L, int idx); + int (*dll_lua_setmetatable) (lua_State *L, int objindex); + void (*dll_lua_call) (lua_State *L, int nargs, int nresults); + int (*dll_lua_pcall) (lua_State *L, int nargs, int nresults, int errfunc); +*************** +*** 229,234 **** +--- 231,237 ---- + {"lua_setfield", (luaV_function) &dll_lua_setfield}, + {"lua_rawset", (luaV_function) &dll_lua_rawset}, + {"lua_rawseti", (luaV_function) &dll_lua_rawseti}, ++ {"lua_remove", (luaV_function) &dll_lua_remove}, + {"lua_setmetatable", (luaV_function) &dll_lua_setmetatable}, + {"lua_call", (luaV_function) &dll_lua_call}, + {"lua_pcall", (luaV_function) &dll_lua_pcall}, +*************** +*** 924,929 **** +--- 927,957 ---- + } + + static int ++ luaV_debug(lua_State *L) ++ { ++ lua_settop(L, 0); ++ lua_getglobal(L, "vim"); ++ lua_getfield(L, -1, "eval"); ++ lua_remove(L, -2); /* vim.eval at position 1 */ ++ for (;;) ++ { ++ const char *input; ++ size_t l; ++ lua_pushvalue(L, 1); /* vim.eval */ ++ lua_pushliteral(L, "input('lua_debug> ')"); ++ lua_call(L, 1, 1); /* return string */ ++ input = lua_tolstring(L, -1, &l); ++ if (l == 0 || strcmp(input, "cont") == 0) ++ return 0; ++ msg_putchar('\n'); /* avoid outputting on input line */ ++ if (luaL_loadbuffer(L, input, l, "=(debug command)") ++ || lua_pcall(L, 0, 0, 0)) ++ luaV_emsg(L); ++ lua_settop(L, 1); /* remove eventual returns, but keep vim.eval */ ++ } ++ } ++ ++ static int + luaV_command(lua_State *L) + { + do_cmdline_cmd((char_u *) luaL_checkstring(L, 1)); +*************** +*** 1082,1087 **** +--- 1110,1120 ---- + /* print */ + lua_pushcfunction(L, luaV_print); + lua_setglobal(L, "print"); ++ /* debug.debug */ ++ lua_getglobal(L, "debug"); ++ lua_pushcfunction(L, luaV_debug); ++ lua_setfield(L, -2, "debug"); ++ lua_pop(L, 1); + /* free */ + lua_pushlightuserdata(L, (void *) LUAVIM_FREE); + lua_pushcfunction(L, luaV_free); +*** ../vim-7.3.316/src/version.c 2011-09-21 13:40:13.000000000 +0200 +--- src/version.c 2011-09-21 17:14:01.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 317, + /**/ + +-- +Q: What is the difference betwee open-source and commercial software? +A: If you have a problem with commercial software you can call a phone + number and they will tell you it might be solved in a future version. + For open-source software there isn't a phone number to call, but you + get the solution within a day. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 76bbfe2ebd319457c1886bc2b9363f545c3e7815 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 26 Sep 2011 15:58:51 +0200 Subject: [PATCH 0035/3340] - patchlevel 318 --- 7.3.318 | 90 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) create mode 100644 7.3.318 diff --git a/7.3.318 b/7.3.318 new file mode 100644 index 00000000..36944802 --- /dev/null +++ b/7.3.318 @@ -0,0 +1,90 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.318 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.318 +Problem: "C" on the last line deletes that line if it's blank. +Solution: Only delete the last line for a delete operation. (James Vega) +Files: src/ops.c + + +*** ../vim-7.3.317/src/ops.c 2011-08-10 12:10:55.000000000 +0200 +--- src/ops.c 2011-09-21 17:32:36.000000000 +0200 +*************** +*** 1922,1928 **** + curwin->w_cursor.coladd = 0; + } + #endif +! if (oap->inclusive && oap->end.lnum == curbuf->b_ml.ml_line_count + && n > (int)STRLEN(ml_get(oap->end.lnum))) + { + /* Special case: gH deletes the last line. */ +--- 1922,1930 ---- + curwin->w_cursor.coladd = 0; + } + #endif +! if (oap->op_type == OP_DELETE +! && oap->inclusive +! && oap->end.lnum == curbuf->b_ml.ml_line_count + && n > (int)STRLEN(ml_get(oap->end.lnum))) + { + /* Special case: gH deletes the last line. */ +*************** +*** 3331,3338 **** + if (regname == '=') + { + /* For the = register we need to split the string at NL +! * characters. */ +! /* Loop twice: count the number of lines and save them. */ + for (;;) + { + y_size = 0; +--- 3333,3340 ---- + if (regname == '=') + { + /* For the = register we need to split the string at NL +! * characters. +! * Loop twice: count the number of lines and save them. */ + for (;;) + { + y_size = 0; +*************** +*** 3348,3354 **** + if (y_array != NULL) + *ptr = NUL; + ++ptr; +! /* A trailing '\n' makes the string linewise */ + if (*ptr == NUL) + { + y_type = MLINE; +--- 3350,3356 ---- + if (y_array != NULL) + *ptr = NUL; + ++ptr; +! /* A trailing '\n' makes the register linewise. */ + if (*ptr == NUL) + { + y_type = MLINE; +*** ../vim-7.3.317/src/version.c 2011-09-21 17:15:34.000000000 +0200 +--- src/version.c 2011-09-21 17:31:48.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 318, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +26. You check your mail. It says "no new messages." So you check it again. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 20f83950ce0a492752d280e0867e05608d613e1c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 26 Sep 2011 15:58:52 +0200 Subject: [PATCH 0036/3340] - patchlevel 319 --- 7.3.319 | 154 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 154 insertions(+) create mode 100644 7.3.319 diff --git a/7.3.319 b/7.3.319 new file mode 100644 index 00000000..68448ab6 --- /dev/null +++ b/7.3.319 @@ -0,0 +1,154 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.319 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.319 (after 7.3.311) +Problem: Redobuff doesn't always include changes of the completion leader. +Solution: Insert backspaces as needed. (idea by Taro Muraoka) +Files: src/edit.c + + +*** ../vim-7.3.318/src/edit.c 2011-09-14 16:52:02.000000000 +0200 +--- src/edit.c 2011-09-21 17:59:10.000000000 +0200 +*************** +*** 163,168 **** +--- 163,169 ---- + static void ins_compl_set_original_text __ARGS((char_u *str)); + static void ins_compl_addfrommatch __ARGS((void)); + static int ins_compl_prep __ARGS((int c)); ++ static void ins_compl_fixRedoBufForLeader __ARGS((char_u *ptr_arg)); + static buf_T *ins_compl_next_buf __ARGS((buf_T *buf, int flag)); + #if defined(FEAT_COMPL_FUNC) || defined(FEAT_EVAL) + static void ins_compl_add_list __ARGS((list_T *list)); +*************** +*** 3713,3721 **** + * memory that was used, and make sure we can redo the insert. */ + if (compl_curr_match != NULL || compl_leader != NULL || c == Ctrl_E) + { +- char_u *p; +- int temp = 0; +- + /* + * If any of the original typed text has been changed, eg when + * ignorecase is set, we must add back-spaces to the redo +--- 3714,3719 ---- +*************** +*** 3726,3750 **** + */ + if (compl_curr_match != NULL && compl_used_match && c != Ctrl_E) + ptr = compl_curr_match->cp_str; +- else if (compl_leader != NULL) +- ptr = compl_leader; + else +! ptr = compl_orig_text; +! if (compl_orig_text != NULL) +! { +! p = compl_orig_text; +! for (temp = 0; p[temp] != NUL && p[temp] == ptr[temp]; +! ++temp) +! ; +! #ifdef FEAT_MBYTE +! if (temp > 0) +! temp -= (*mb_head_off)(compl_orig_text, p + temp); +! #endif +! for (p += temp; *p != NUL; mb_ptr_adv(p)) +! AppendCharToRedobuff(K_BS); +! } +! if (ptr != NULL) +! AppendToRedobuffLit(ptr + temp, -1); + } + + #ifdef FEAT_CINDENT +--- 3724,3732 ---- + */ + if (compl_curr_match != NULL && compl_used_match && c != Ctrl_E) + ptr = compl_curr_match->cp_str; + else +! ptr = NULL; +! ins_compl_fixRedoBufForLeader(ptr); + } + + #ifdef FEAT_CINDENT +*************** +*** 3834,3839 **** +--- 3816,3859 ---- + } + + /* ++ * Fix the redo buffer for the completion leader replacing some of the typed ++ * text. This inserts backspaces and appends the changed text. ++ * "ptr" is the known leader text or NUL. ++ */ ++ static void ++ ins_compl_fixRedoBufForLeader(ptr_arg) ++ char_u *ptr_arg; ++ { ++ int len; ++ char_u *p; ++ char_u *ptr = ptr_arg; ++ ++ if (ptr == NULL) ++ { ++ if (compl_leader != NULL) ++ ptr = compl_leader; ++ else ++ return; /* nothing to do */ ++ } ++ if (compl_orig_text != NULL) ++ { ++ p = compl_orig_text; ++ for (len = 0; p[len] != NUL && p[len] == ptr[len]; ++len) ++ ; ++ #ifdef FEAT_MBYTE ++ if (len > 0) ++ len -= (*mb_head_off)(p, p + len); ++ #endif ++ for (p += len; *p != NUL; mb_ptr_adv(p)) ++ AppendCharToRedobuff(K_BS); ++ } ++ else ++ len = 0; ++ if (ptr != NULL) ++ AppendToRedobuffLit(ptr + len, -1); ++ } ++ ++ /* + * Loops through the list of windows, loaded-buffers or non-loaded-buffers + * (depending on flag) starting from buf and looking for a non-scanned + * buffer (other than curbuf). curbuf is special, if it is called with +*************** +*** 5241,5246 **** +--- 5261,5270 ---- + else + edit_submode = (char_u *)_(CTRL_X_MSG(ctrl_x_mode)); + ++ /* If any of the original typed text has been changed we need to fix ++ * the redo buffer. */ ++ ins_compl_fixRedoBufForLeader(NULL); ++ + /* Always add completion for the original text. */ + vim_free(compl_orig_text); + compl_orig_text = vim_strnsave(line + compl_col, compl_length); +*** ../vim-7.3.318/src/version.c 2011-09-21 17:33:49.000000000 +0200 +--- src/version.c 2011-09-21 18:21:07.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 319, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +27. You refer to your age as 3.x. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ddfcc6a46972e8929a824d33588af218fd1b3b0c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 26 Sep 2011 15:58:53 +0200 Subject: [PATCH 0037/3340] - patchlevel 320 --- 7.3.320 | 130 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 130 insertions(+) create mode 100644 7.3.320 diff --git a/7.3.320 b/7.3.320 new file mode 100644 index 00000000..3b957c29 --- /dev/null +++ b/7.3.320 @@ -0,0 +1,130 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.320 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.320 +Problem: When a 0xa0 character is in a sourced file the error message for + unrecognized command does not show the problem. +Solution: Display 0xa0 as . +Files: src/ex_docmd.c + + +*** ../vim-7.3.319/src/ex_docmd.c 2011-07-20 16:36:35.000000000 +0200 +--- src/ex_docmd.c 2011-09-21 19:02:15.000000000 +0200 +*************** +*** 61,66 **** +--- 61,67 ---- + static char_u *do_one_cmd __ARGS((char_u **, int, char_u *(*fgetline)(int, void *, int), void *cookie)); + static int if_level = 0; /* depth in :if */ + #endif ++ static void append_command __ARGS((char_u *cmd)); + static char_u *find_command __ARGS((exarg_T *eap, int *full)); + + static void ex_abbreviate __ARGS((exarg_T *eap)); +*************** +*** 2136,2145 **** + { + STRCPY(IObuff, _("E492: Not an editor command")); + if (!sourcing) +! { +! STRCAT(IObuff, ": "); +! STRNCAT(IObuff, *cmdlinep, 40); +! } + errormsg = IObuff; + } + goto doend; +--- 2137,2143 ---- + { + STRCPY(IObuff, _("E492: Not an editor command")); + if (!sourcing) +! append_command(*cmdlinep); + errormsg = IObuff; + } + goto doend; +*************** +*** 2708,2715 **** + STRCPY(IObuff, errormsg); + errormsg = IObuff; + } +! STRCAT(errormsg, ": "); +! STRNCAT(errormsg, *cmdlinep, IOSIZE - STRLEN(IObuff) - 1); + } + emsg(errormsg); + } +--- 2706,2712 ---- + STRCPY(IObuff, errormsg); + errormsg = IObuff; + } +! append_command(*cmdlinep); + } + emsg(errormsg); + } +*************** +*** 2797,2802 **** +--- 2794,2835 ---- + } + + /* ++ * Append "cmd" to the error message in IObuff. ++ * Takes care of limiting the length and handling 0xa0, which would be ++ * invisible otherwise. ++ */ ++ static void ++ append_command(cmd) ++ char_u *cmd; ++ { ++ char_u *s = cmd; ++ char_u *d; ++ ++ STRCAT(IObuff, ": "); ++ d = IObuff + STRLEN(IObuff); ++ while (*s != NUL && d - IObuff < IOSIZE - 7) ++ { ++ if ( ++ #ifdef FEAT_MBYTE ++ enc_utf8 ? (s[0] == 0xc2 && s[1] == 0xa0) : ++ #endif ++ *s == 0xa0) ++ { ++ s += ++ #ifdef FEAT_MBYTE ++ enc_utf8 ? 2 : ++ #endif ++ 1; ++ STRCPY(d, ""); ++ d += 4; ++ } ++ else ++ MB_COPY_CHAR(s, d); ++ } ++ *d = NUL; ++ } ++ ++ /* + * Find an Ex command by its name, either built-in or user. + * Start of the name can be found at eap->cmd. + * Returns pointer to char after the command name. +*** ../vim-7.3.319/src/version.c 2011-09-21 18:23:02.000000000 +0200 +--- src/version.c 2011-09-21 19:04:35.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 320, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +28. You have comandeered your teenager's phone line for the net and even his + friends know not to call on his line anymore. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2de159d080195e87158f895e701ab2d3c4553cf1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 26 Sep 2011 15:58:54 +0200 Subject: [PATCH 0038/3340] - patchlevel 321 --- 7.3.321 | 304 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 304 insertions(+) create mode 100644 7.3.321 diff --git a/7.3.321 b/7.3.321 new file mode 100644 index 00000000..6303b013 --- /dev/null +++ b/7.3.321 @@ -0,0 +1,304 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.321 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.321 +Problem: Code not following Vim style. +Solution: Fix the style. (Elias Diem) +Files: src/os_qnx.c + + +*** ../vim-7.3.320/src/os_qnx.c 2011-06-19 01:14:22.000000000 +0200 +--- src/os_qnx.c 2011-09-21 19:48:08.000000000 +0200 +*************** +*** 24,33 **** + #if defined(FEAT_GUI_PHOTON) + PhChannelParms_t parms; + +! memset( &parms, 0, sizeof( parms ) ); + parms.flags = Ph_DYNAMIC_BUFFER; + +! is_photon_available = (PhAttach( NULL, &parms ) != NULL) ? TRUE : FALSE; + #endif + } + +--- 24,33 ---- + #if defined(FEAT_GUI_PHOTON) + PhChannelParms_t parms; + +! memset(&parms, 0, sizeof(parms)); + parms.flags = Ph_DYNAMIC_BUFFER; + +! is_photon_available = (PhAttach(NULL, &parms) != NULL) ? TRUE : FALSE; + #endif + } + +*************** +*** 39,46 **** + /* Turn on the clipboard for a console vim when photon is running */ + void qnx_clip_init() + { +! if( is_photon_available == TRUE && !gui.in_use) +! clip_init( TRUE ); + } + + /*****************************************************************************/ +--- 39,46 ---- + /* Turn on the clipboard for a console vim when photon is running */ + void qnx_clip_init() + { +! if (is_photon_available == TRUE && !gui.in_use) +! clip_init(TRUE); + } + + /*****************************************************************************/ +*************** +*** 48,79 **** + + /* No support for owning the clipboard */ + int +! clip_mch_own_selection( VimClipboard *cbd ) + { + return FALSE; + } + + void +! clip_mch_lose_selection( VimClipboard *cbd ) + { + } + + void +! clip_mch_request_selection( VimClipboard *cbd ) + { + int type = MLINE, clip_length = 0, is_type_set = FALSE; + void *cbdata; + PhClipHeader *clip_header; + char_u *clip_text = NULL; + +! cbdata = PhClipboardPasteStart( PhInputGroup( NULL )); +! if( cbdata != NULL ) + { + /* Look for the vim specific clip first */ +! clip_header = PhClipboardPasteType( cbdata, CLIP_TYPE_VIM ); +! if( clip_header != NULL && clip_header->data != NULL ) + { +! switch( *(char *) clip_header->data ) + { + default: /* fallthrough to line type */ + case 'L': type = MLINE; break; +--- 48,79 ---- + + /* No support for owning the clipboard */ + int +! clip_mch_own_selection(VimClipboard *cbd) + { + return FALSE; + } + + void +! clip_mch_lose_selection(VimClipboard *cbd) + { + } + + void +! clip_mch_request_selection(VimClipboard *cbd) + { + int type = MLINE, clip_length = 0, is_type_set = FALSE; + void *cbdata; + PhClipHeader *clip_header; + char_u *clip_text = NULL; + +! cbdata = PhClipboardPasteStart(PhInputGroup(NULL)); +! if (cbdata != NULL) + { + /* Look for the vim specific clip first */ +! clip_header = PhClipboardPasteType(cbdata, CLIP_TYPE_VIM); +! if (clip_header != NULL && clip_header->data != NULL) + { +! switch(*(char *) clip_header->data) + { + default: /* fallthrough to line type */ + case 'L': type = MLINE; break; +*************** +*** 86,112 **** + } + + /* Try for just normal text */ +! clip_header = PhClipboardPasteType( cbdata, CLIP_TYPE_TEXT ); +! if( clip_header != NULL ) + { + clip_text = clip_header->data; + clip_length = clip_header->length - 1; + +! if( clip_text != NULL && is_type_set == FALSE ) + type = MAUTO; + } + +! if( (clip_text != NULL) && (clip_length > 0) ) + { +! clip_yank_selection( type, clip_text, clip_length, cbd ); + } + +! PhClipboardPasteFinish( cbdata ); + } + } + + void +! clip_mch_set_selection( VimClipboard *cbd ) + { + int type; + long_u len; +--- 86,112 ---- + } + + /* Try for just normal text */ +! clip_header = PhClipboardPasteType(cbdata, CLIP_TYPE_TEXT); +! if (clip_header != NULL) + { + clip_text = clip_header->data; + clip_length = clip_header->length - 1; + +! if (clip_text != NULL && is_type_set == FALSE) + type = MAUTO; + } + +! if ((clip_text != NULL) && (clip_length > 0)) + { +! clip_yank_selection(type, clip_text, clip_length, cbd); + } + +! PhClipboardPasteFinish(cbdata); + } + } + + void +! clip_mch_set_selection(VimClipboard *cbd) + { + int type; + long_u len; +*************** +*** 114,144 **** + PhClipHeader clip_header[2]; + + /* Prevent recursion from clip_get_selection() */ +! if( cbd->owned == TRUE ) + return; + + cbd->owned = TRUE; +! clip_get_selection( cbd ); + cbd->owned = FALSE; + +! type = clip_convert_selection( &str, &len, cbd ); +! if( type >= 0 ) + { +! text_clip = lalloc( len + 1, TRUE ); /* Normal text */ + +! if( text_clip && vim_clip ) + { +! memset( clip_header, 0, sizeof( clip_header ) ); + +! STRNCPY( clip_header[0].type, CLIP_TYPE_VIM, 8 ); +! clip_header[0].length = sizeof( vim_clip ); + clip_header[0].data = vim_clip; + +! STRNCPY( clip_header[1].type, CLIP_TYPE_TEXT, 8 ); + clip_header[1].length = len + 1; + clip_header[1].data = text_clip; + +! switch( type ) + { + default: /* fallthrough to MLINE */ + case MLINE: *vim_clip = 'L'; break; +--- 114,144 ---- + PhClipHeader clip_header[2]; + + /* Prevent recursion from clip_get_selection() */ +! if (cbd->owned == TRUE) + return; + + cbd->owned = TRUE; +! clip_get_selection(cbd); + cbd->owned = FALSE; + +! type = clip_convert_selection(&str, &len, cbd); +! if (type >= 0) + { +! text_clip = lalloc(len + 1, TRUE); /* Normal text */ + +! if (text_clip && vim_clip) + { +! memset(clip_header, 0, sizeof(clip_header)); + +! STRNCPY(clip_header[0].type, CLIP_TYPE_VIM, 8); +! clip_header[0].length = sizeof(vim_clip); + clip_header[0].data = vim_clip; + +! STRNCPY(clip_header[1].type, CLIP_TYPE_TEXT, 8); + clip_header[1].length = len + 1; + clip_header[1].data = text_clip; + +! switch(type) + { + default: /* fallthrough to MLINE */ + case MLINE: *vim_clip = 'L'; break; +*************** +*** 148,161 **** + #endif + } + +! vim_strncpy( text_clip, str, len ); + + vim_clip[ 1 ] = NUL; + +! PhClipboardCopy( PhInputGroup( NULL ), 2, clip_header); + } +! vim_free( text_clip ); + } +! vim_free( str ); + } + #endif +--- 148,161 ---- + #endif + } + +! vim_strncpy(text_clip, str, len); + + vim_clip[ 1 ] = NUL; + +! PhClipboardCopy(PhInputGroup(NULL), 2, clip_header); + } +! vim_free(text_clip); + } +! vim_free(str); + } + #endif +*** ../vim-7.3.320/src/version.c 2011-09-21 19:10:42.000000000 +0200 +--- src/version.c 2011-09-21 19:47:50.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 321, + /**/ + +-- +Bypasses are devices that allow some people to dash from point A to +point B very fast while other people dash from point B to point A very +fast. People living at point C, being a point directly in between, are +often given to wonder what's so great about point A that so many people +from point B are so keen to get there and what's so great about point B +that so many people from point A are so keen to get there. They often +wish that people would just once and for all work out where the hell +they wanted to be. + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8cfad4c0d2cc089554ca9b0d984273398b951f3c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 26 Sep 2011 15:58:55 +0200 Subject: [PATCH 0039/3340] - patchlevel 322 --- 7.3.322 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.322 diff --git a/7.3.322 b/7.3.322 new file mode 100644 index 00000000..d81b9ec6 --- /dev/null +++ b/7.3.322 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.322 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.322 +Problem: #ifdef for PDP_RETVAL doesn't work, INT_PTR can be a typedef. +Solution: Check the MSC version and 64 bit flags. (Sergiu Dotenco) +Files: src/os_mswin.c + + +*** ../vim-7.3.321/src/os_mswin.c 2011-08-10 17:07:56.000000000 +0200 +--- src/os_mswin.c 2011-09-21 20:09:05.000000000 +0200 +*************** +*** 1781,1787 **** + } + + /* Attempt to make this work for old and new compilers */ +! #if !defined(_MSC_VER) || (_MSC_VER < 1300) || !defined(INT_PTR) + # define PDP_RETVAL BOOL + #else + # define PDP_RETVAL INT_PTR +--- 1781,1787 ---- + } + + /* Attempt to make this work for old and new compilers */ +! #if !defined(_WIN64) && (!defined(_MSC_VER) || _MSC_VER < 1300) + # define PDP_RETVAL BOOL + #else + # define PDP_RETVAL INT_PTR +*** ../vim-7.3.321/src/version.c 2011-09-21 19:50:00.000000000 +0200 +--- src/version.c 2011-09-21 20:08:29.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 322, + /**/ + +-- +Don't Panic! + -- The Hitchhiker's Guide to the Galaxy + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f3ca875a345d2a42afd95ee9ad0c46b27925dca8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 26 Sep 2011 15:58:58 +0200 Subject: [PATCH 0040/3340] - patchlevel 322 --- README.patches | 7 +++++++ vim.spec | 19 ++++++++++++++++++- 2 files changed, 25 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index 08d345ce..1dc2a793 100644 --- a/README.patches +++ b/README.patches @@ -346,3 +346,10 @@ Individual patches for Vim 7.3: 2141 7.3.313 (after 7.3.307) warning compiling with dynamic Python 3 1740 7.3.314 (after 7.3.304) missing parenthesis 13684 7.3.315 opening a window before forking causes problems for GTK + 1499 7.3.316 (after 7.3.306) crash if 'colorcolumn' set and closing buffer + 3918 7.3.317 Lua: debug.debug() may hang + 2662 7.3.318 "C" on the last line deletes that line if it's blank + 4573 7.3.319 redobuff doesn't always include completion leader changes + 3363 7.3.320 0xa0 character in sourced file is hard to spot + 7855 7.3.321 code not following Vim style + 1585 7.3.322 #ifdef for PDP_RETVAL doesn't work, INT_PTR can be a typedef diff --git a/vim.spec b/vim.spec index a90284c1..f9886639 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 315 +%define patchlevel 322 Summary: The VIM editor URL: http://www.vim.org/ @@ -369,6 +369,13 @@ Patch312: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.312 Patch313: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.313 Patch314: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.314 Patch315: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.315 +Patch316: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.316 +Patch317: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.317 +Patch318: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.318 +Patch319: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.319 +Patch320: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.320 +Patch321: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.321 +Patch322: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.322 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -826,6 +833,13 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch313 -p0 %patch314 -p0 %patch315 -p0 +%patch316 -p0 +%patch317 -p0 +%patch318 -p0 +%patch319 -p0 +%patch320 -p0 +%patch321 -p0 +%patch322 -p0 # install spell files @@ -1283,6 +1297,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Sep 26 2011 Karsten Hopp 7.3.322-1 +- patchlevel 322 + * Wed Sep 21 2011 Karsten Hopp 7.3.315-1 - patchlevel 315 From 4f48217379f78d2fcf6241e5133fa6c5818ba7bb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:35 +0100 Subject: [PATCH 0041/3340] - patchlevel 323 --- 7.3.323 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.323 diff --git a/7.3.323 b/7.3.323 new file mode 100644 index 00000000..10f6d193 --- /dev/null +++ b/7.3.323 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.323 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.323 +Problem: The default 'errorformat' does not ignore some "included from" + lines. +Solution: Add a few more patterns. (Ben Boeckel) +Files: src/option.h + + +*** ../vim-7.3.322/src/option.h 2011-07-27 13:59:12.000000000 +0200 +--- src/option.h 2011-09-30 14:32:13.000000000 +0200 +*************** +*** 33,39 **** + # ifdef EBCDIC + #define DFLT_EFM "%*[^ ] %*[^ ] %f:%l%*[ ]%m,%*[^\"]\"%f\"%*\\D%l: %m,\"%f\"%*\\D%l: %m,%f:%l:%c:%m,%f(%l):%m,%f:%l:%m,\"%f\"\\, line %l%*\\D%c%*[^ ] %m,%D%*\\a[%*\\d]: Entering directory `%f',%X%*\\a[%*\\d]: Leaving directory `%f',%DMaking %*\\a in %f,%f|%l| %m" + # else +! #define DFLT_EFM "%*[^\"]\"%f\"%*\\D%l: %m,\"%f\"%*\\D%l: %m,%-G%f:%l: (Each undeclared identifier is reported only once,%-G%f:%l: for each function it appears in.),%-GIn file included from %f:%l:%c:,%-GIn file included from %f:%l:%c,%-GIn file included from %f:%l,%-Gfrom %f:%l:%c,%-Gfrom %f:%l,%f:%l:%c:%m,%f(%l):%m,%f:%l:%m,\"%f\"\\, line %l%*\\D%c%*[^ ] %m,%D%*\\a[%*\\d]: Entering directory `%f',%X%*\\a[%*\\d]: Leaving directory `%f',%D%*\\a: Entering directory `%f',%X%*\\a: Leaving directory `%f',%DMaking %*\\a in %f,%f|%l| %m" + # endif + # endif + # endif +--- 33,39 ---- + # ifdef EBCDIC + #define DFLT_EFM "%*[^ ] %*[^ ] %f:%l%*[ ]%m,%*[^\"]\"%f\"%*\\D%l: %m,\"%f\"%*\\D%l: %m,%f:%l:%c:%m,%f(%l):%m,%f:%l:%m,\"%f\"\\, line %l%*\\D%c%*[^ ] %m,%D%*\\a[%*\\d]: Entering directory `%f',%X%*\\a[%*\\d]: Leaving directory `%f',%DMaking %*\\a in %f,%f|%l| %m" + # else +! #define DFLT_EFM "%*[^\"]\"%f\"%*\\D%l: %m,\"%f\"%*\\D%l: %m,%-G%f:%l: (Each undeclared identifier is reported only once,%-G%f:%l: for each function it appears in.),%-GIn file included from %f:%l:%c:,%-GIn file included from %f:%l:%c\\,,%-GIn file included from %f:%l:%c,%-GIn file included from %f:%l,%-G%*[ ]from %f:%l:%c,%-G%*[ ]from %f:%l:,%-G%*[ ]from %f:%l\\,,%-G%*[ ]from %f:%l,%f:%l:%c:%m,%f(%l):%m,%f:%l:%m,\"%f\"\\, line %l%*\\D%c%*[^ ] %m,%D%*\\a[%*\\d]: Entering directory `%f',%X%*\\a[%*\\d]: Leaving directory `%f',%D%*\\a: Entering directory `%f',%X%*\\a: Leaving directory `%f',%DMaking %*\\a in %f,%f|%l| %m" + # endif + # endif + # endif +*** ../vim-7.3.322/src/version.c 2011-09-21 20:09:38.000000000 +0200 +--- src/version.c 2011-09-30 14:38:59.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 323, + /**/ + +-- +Due knot trussed yore spell chequer two fined awl miss steaks. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a7ba460e21ad7d85193627326c80971a86e05ca4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:38 +0100 Subject: [PATCH 0042/3340] - patchlevel 324 --- 7.3.324 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.324 diff --git a/7.3.324 b/7.3.324 new file mode 100644 index 00000000..59b5c6c0 --- /dev/null +++ b/7.3.324 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.324 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.324 (after 7.3.237) +Problem: Completion for ":compiler" shows color scheme names. +Solution: Fix the directory name. (James Vega) +Files: src/ex_getln.c + + +*** ../vim-7.3.323/src/ex_getln.c 2011-08-17 16:25:43.000000000 +0200 +--- src/ex_getln.c 2011-09-30 16:22:14.000000000 +0200 +*************** +*** 4546,4552 **** + } + if (xp->xp_context == EXPAND_COMPILER) + { +! char *directories[] = {"colors", NULL}; + return ExpandRTDir(pat, num_file, file, directories); + } + if (xp->xp_context == EXPAND_OWNSYNTAX) +--- 4546,4552 ---- + } + if (xp->xp_context == EXPAND_COMPILER) + { +! char *directories[] = {"compiler", NULL}; + return ExpandRTDir(pat, num_file, file, directories); + } + if (xp->xp_context == EXPAND_OWNSYNTAX) +*** ../vim-7.3.323/src/version.c 2011-09-30 14:44:49.000000000 +0200 +--- src/version.c 2011-09-30 16:23:15.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 324, + /**/ + + +-- +hundred-and-one symptoms of being an internet addict: +31. You code your homework in HTML and give your instructor the URL. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d099d9416cdee0cbc43851285db1e014f223bb0a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:38 +0100 Subject: [PATCH 0043/3340] - patchlevel 325 --- 7.3.325 | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 7.3.325 diff --git a/7.3.325 b/7.3.325 new file mode 100644 index 00000000..80ebc6de --- /dev/null +++ b/7.3.325 @@ -0,0 +1,64 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.325 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.325 +Problem: A duplicated function argument gives an internal error. +Solution: Give a proper error message. (based on patch by Tyru) +Files: src/eval.c + + +*** ../vim-7.3.324/src/eval.c 2011-09-14 16:52:02.000000000 +0200 +--- src/eval.c 2011-09-30 16:32:20.000000000 +0200 +*************** +*** 20461,20466 **** +--- 20461,20467 ---- + exarg_T *eap; + { + char_u *theline; ++ int i; + int j; + int c; + int saved_did_emsg; +*************** +*** 20707,20712 **** +--- 20708,20722 ---- + arg = vim_strsave(arg); + if (arg == NULL) + goto erret; ++ ++ /* Check for duplicate argument name. */ ++ for (i = 0; i < newargs.ga_len; ++i) ++ if (STRCMP(((char_u **)(newargs.ga_data))[i], arg) == 0) ++ { ++ EMSG2(_("E853: Duplicate argument name: %s"), arg); ++ goto erret; ++ } ++ + ((char_u **)(newargs.ga_data))[newargs.ga_len] = arg; + *p = c; + newargs.ga_len++; +*** ../vim-7.3.324/src/version.c 2011-09-30 16:23:21.000000000 +0200 +--- src/version.c 2011-09-30 16:39:16.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 325, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +32. You don't know what sex three of your closest friends are, because they + have neutral nicknames and you never bothered to ask. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From be8276bb88e116891ec3a29af8c6a0a1ffad371b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:38 +0100 Subject: [PATCH 0044/3340] - patchlevel 326 --- 7.3.326 | 285 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 285 insertions(+) create mode 100644 7.3.326 diff --git a/7.3.326 b/7.3.326 new file mode 100644 index 00000000..4ad52e96 --- /dev/null +++ b/7.3.326 @@ -0,0 +1,285 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.326 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.326 +Problem: MingW 4.6 no longer supports the -mno-cygwin option. +Solution: Split the Cygwin and MingW makefiles. (Matsushita Shougo) +Files: src/GvimExt/Make_cyg.mak, src/GvimExt/Make_ming.mak, + src/Make_cyg.mak, src/Make_ming.mak, src/xxd/Make_ming.mak, + Filelist + + +*** ../vim-7.3.325/src/GvimExt/Make_cyg.mak 2011-09-30 16:55:18.000000000 +0200 +--- src/GvimExt/Make_cyg.mak 2011-09-30 16:45:49.000000000 +0200 +*************** +*** 0 **** +--- 1,77 ---- ++ # Project: gvimext ++ # Generates gvimext.dll with gcc. ++ # To be used with Cygwin. ++ # ++ # Originally, the DLL base address was fixed: -Wl,--image-base=0x1C000000 ++ # Now it is allocated dymanically by the linker by evaluating all DLLs ++ # already loaded in memory. The binary image contains as well information ++ # for automatic pseudo-rebasing, if needed by the system. ALV 2004-02-29 ++ ++ # If cross-compiling set this to yes, else set it to no ++ CROSS = no ++ #CROSS = yes ++ # For the old MinGW 2.95 (the one you get e.g. with debian woody) ++ # set the following variable to yes and check if the executables are ++ # really named that way. ++ # If you have a newer MinGW or you are using cygwin set it to no and ++ # check also the executables ++ MINGWOLD = no ++ ++ # Link against the shared versions of libgcc/libstdc++ by default. Set ++ # STATIC_STDCPLUS to "yes" to link against static versions instead. ++ STATIC_STDCPLUS=no ++ #STATIC_STDCPLUS=yes ++ ++ # Note: -static-libstdc++ is not available until gcc 4.5.x. ++ LDFLAGS += -shared ++ ifeq (yes, $(STATIC_STDCPLUS)) ++ LDFLAGS += -static-libgcc -static-libstdc++ ++ endif ++ ++ ifeq ($(CROSS),yes) ++ DEL = rm ++ ifeq ($(MINGWOLD),yes) ++ CXXFLAGS := -O2 -mno-cygwin -fvtable-thunks ++ else ++ CXXFLAGS := -O2 -mno-cygwin ++ endif ++ else ++ CXXFLAGS := -O2 -mno-cygwin ++ ifneq (sh.exe, $(SHELL)) ++ DEL = rm ++ else ++ DEL = del ++ endif ++ endif ++ CXX := $(CROSS_COMPILE)g++ ++ WINDRES := $(CROSS_COMPILE)windres ++ WINDRES_CXX = $(CXX) ++ WINDRES_FLAGS = --preprocessor="$(WINDRES_CXX) -E -xc" -DRC_INVOKED ++ LIBS := -luuid ++ RES := gvimext.res ++ DEFFILE = gvimext_ming.def ++ OBJ := gvimext.o ++ ++ DLL := gvimext.dll ++ ++ .PHONY: all all-before all-after clean clean-custom ++ ++ all: all-before $(DLL) all-after ++ ++ $(DLL): $(OBJ) $(RES) $(DEFFILE) ++ $(CXX) $(LDFLAGS) $(CXXFLAGS) -s -o $@ \ ++ -Wl,--enable-auto-image-base \ ++ -Wl,--enable-auto-import \ ++ -Wl,--whole-archive \ ++ $^ \ ++ -Wl,--no-whole-archive \ ++ $(LIBS) ++ ++ gvimext.o: gvimext.cpp ++ $(CXX) $(CXXFLAGS) -DFEAT_GETTEXT -c $? -o $@ ++ ++ $(RES): gvimext_ming.rc ++ $(WINDRES) $(WINDRES_FLAGS) --input-format=rc --output-format=coff -DMING $? -o $@ ++ ++ clean: clean-custom ++ -$(DEL) $(OBJ) $(RES) $(DLL) +*** ../vim-7.3.325/src/GvimExt/Make_ming.mak 2010-12-30 14:50:46.000000000 +0100 +--- src/GvimExt/Make_ming.mak 2011-09-30 16:47:09.000000000 +0200 +*************** +*** 1,6 **** + # Project: gvimext + # Generates gvimext.dll with gcc. +! # Can be used for Cygwin and MingW (MingW ignores -mno-cygwin) + # + # Originally, the DLL base address was fixed: -Wl,--image-base=0x1C000000 + # Now it is allocated dymanically by the linker by evaluating all DLLs +--- 1,6 ---- + # Project: gvimext + # Generates gvimext.dll with gcc. +! # To be used with MingW. + # + # Originally, the DLL base address was fixed: -Wl,--image-base=0x1C000000 + # Now it is allocated dymanically by the linker by evaluating all DLLs +*************** +*** 31,42 **** + ifeq ($(CROSS),yes) + DEL = rm + ifeq ($(MINGWOLD),yes) +! CXXFLAGS := -O2 -mno-cygwin -fvtable-thunks + else +! CXXFLAGS := -O2 -mno-cygwin + endif + else +! CXXFLAGS := -O2 -mno-cygwin + ifneq (sh.exe, $(SHELL)) + DEL = rm + else +--- 31,42 ---- + ifeq ($(CROSS),yes) + DEL = rm + ifeq ($(MINGWOLD),yes) +! CXXFLAGS := -O2 -fvtable-thunks + else +! CXXFLAGS := -O2 + endif + else +! CXXFLAGS := -O2 + ifneq (sh.exe, $(SHELL)) + DEL = rm + else +*************** +*** 75,78 **** + + clean: clean-custom + -$(DEL) $(OBJ) $(RES) $(DLL) +- +--- 75,77 ---- +*** ../vim-7.3.325/src/Make_cyg.mak 2010-11-03 21:59:23.000000000 +0100 +--- src/Make_cyg.mak 2011-09-30 16:48:11.000000000 +0200 +*************** +*** 536,542 **** + $(MAKE) -C xxd -f Make_cyg.mak CC=$(CC) USEDLL=$(USEDLL) + + GvimExt/gvimext.dll: GvimExt/gvimext.cpp GvimExt/gvimext.rc GvimExt/gvimext.h +! $(MAKE) -C GvimExt -f Make_ming.mak CROSS_COMPILE=$(CROSS_COMPILE) + + vimrun.exe: vimrun.c + $(CC) $(CFLAGS) -o vimrun.exe vimrun.c $(LIBS) +--- 536,542 ---- + $(MAKE) -C xxd -f Make_cyg.mak CC=$(CC) USEDLL=$(USEDLL) + + GvimExt/gvimext.dll: GvimExt/gvimext.cpp GvimExt/gvimext.rc GvimExt/gvimext.h +! $(MAKE) -C GvimExt -f Make_cyg.mak CROSS_COMPILE=$(CROSS_COMPILE) + + vimrun.exe: vimrun.c + $(CC) $(CFLAGS) -o vimrun.exe vimrun.c $(LIBS) +*************** +*** 565,571 **** + endif + -$(DEL) pathdef.c + $(MAKE) -C xxd -f Make_cyg.mak clean +! $(MAKE) -C GvimExt -f Make_ming.mak clean + + distclean: clean + -$(DEL) obj$(DIRSLASH)*.o +--- 565,571 ---- + endif + -$(DEL) pathdef.c + $(MAKE) -C xxd -f Make_cyg.mak clean +! $(MAKE) -C GvimExt -f Make_cyg.mak clean + + distclean: clean + -$(DEL) obj$(DIRSLASH)*.o +*** ../vim-7.3.325/src/Make_ming.mak 2011-09-14 10:49:44.000000000 +0200 +--- src/Make_ming.mak 2011-09-30 16:48:11.000000000 +0200 +*************** +*** 641,647 **** + upx vim.exe + + xxd/xxd.exe: xxd/xxd.c +! $(MAKE) -C xxd -f Make_cyg.mak CC=$(CC) + + GvimExt/gvimext.dll: GvimExt/gvimext.cpp GvimExt/gvimext.rc GvimExt/gvimext.h + $(MAKE) -C GvimExt -f Make_ming.mak CROSS=$(CROSS) CROSS_COMPILE=$(CROSS_COMPILE) +--- 641,647 ---- + upx vim.exe + + xxd/xxd.exe: xxd/xxd.c +! $(MAKE) -C xxd -f Make_ming.mak CC=$(CC) + + GvimExt/gvimext.dll: GvimExt/gvimext.cpp GvimExt/gvimext.rc GvimExt/gvimext.h + $(MAKE) -C GvimExt -f Make_ming.mak CROSS=$(CROSS) CROSS_COMPILE=$(CROSS_COMPILE) +*************** +*** 659,665 **** + -$(DEL) mzscheme_base.c + endif + $(MAKE) -C GvimExt -f Make_ming.mak clean +! $(MAKE) -C xxd -f Make_cyg.mak clean + + ########################################################################### + INCL = vim.h feature.h os_win32.h os_dos.h ascii.h keymap.h term.h macros.h \ +--- 659,665 ---- + -$(DEL) mzscheme_base.c + endif + $(MAKE) -C GvimExt -f Make_ming.mak clean +! $(MAKE) -C xxd -f Make_ming.mak clean + + ########################################################################### + INCL = vim.h feature.h os_win32.h os_dos.h ascii.h keymap.h term.h macros.h \ +*** ../vim-7.3.325/src/xxd/Make_ming.mak 2011-09-30 16:55:18.000000000 +0200 +--- src/xxd/Make_ming.mak 2011-09-30 16:48:34.000000000 +0200 +*************** +*** 0 **** +--- 1,28 ---- ++ # The most simplistic Makefile, for MinGW gcc on MS-DOS ++ ++ ifndef USEDLL ++ USEDLL = no ++ endif ++ ++ ifeq (yes, $(USEDLL)) ++ DEFINES = ++ LIBS = -lc ++ else ++ DEFINES = ++ LIBS = ++ endif ++ ++ CC = gcc ++ CFLAGS = -O2 -Wall -DWIN32 $(DEFINES) ++ ++ ifneq (sh.exe, $(SHELL)) ++ DEL = rm ++ else ++ DEL = del ++ endif ++ ++ xxd.exe: xxd.c ++ $(CC) $(CFLAGS) -s -o xxd.exe xxd.c $(LIBS) ++ ++ clean: ++ -$(DEL) xxd.exe +*** ../vim-7.3.325/Filelist 2011-06-12 20:36:00.000000000 +0200 +--- Filelist 2011-09-30 16:49:29.000000000 +0200 +*************** +*** 313,318 **** +--- 313,319 ---- + src/xxd/Make_bc5.mak \ + src/xxd/Make_cyg.mak \ + src/xxd/Make_djg.mak \ ++ src/xxd/Make_ming.mak \ + src/xxd/Make_mvc.mak \ + nsis/gvim.nsi \ + nsis/README.txt \ +*** ../vim-7.3.325/src/version.c 2011-09-30 16:39:41.000000000 +0200 +--- src/version.c 2011-09-30 16:49:57.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 326, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +33. You name your children Eudora, Mozilla and Dotcom. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 555633b2bd7b85172238a8de6b13047091bc5e14 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:39 +0100 Subject: [PATCH 0045/3340] - patchlevel 327 --- 7.3.327 | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 7.3.327 diff --git a/7.3.327 b/7.3.327 new file mode 100644 index 00000000..1de5a996 --- /dev/null +++ b/7.3.327 @@ -0,0 +1,64 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.327 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.327 +Problem: When jumping to a help tag a closed fold doesn't open. +Solution: Save and restore KeyTyped. (Yasuhiro Matsumoto) +Files: src/ex_cmds.c + + +*** ../vim-7.3.326/src/ex_cmds.c 2011-09-14 14:43:21.000000000 +0200 +--- src/ex_cmds.c 2011-09-30 17:24:03.000000000 +0200 +*************** +*** 5508,5513 **** +--- 5508,5516 ---- + int len; + char_u *lang; + #endif ++ #ifdef FEAT_FOLDING ++ int old_KeyTyped = KeyTyped; ++ #endif + + if (eap != NULL) + { +*************** +*** 5671,5676 **** +--- 5674,5685 ---- + if (!p_im) + restart_edit = 0; /* don't want insert mode in help file */ + ++ #ifdef FEAT_FOLDING ++ /* Restore KeyTyped, setting 'filetype=help' may reset it. ++ * It is needed for do_tag top open folds under the cursor. */ ++ KeyTyped = old_KeyTyped; ++ #endif ++ + if (tag != NULL) + do_tag(tag, DT_HELP, 1, FALSE, TRUE); + +*** ../vim-7.3.326/src/version.c 2011-09-30 16:56:00.000000000 +0200 +--- src/version.c 2011-09-30 17:24:17.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 327, + /**/ + +-- +Q. What happens to programmers when they die? +A: MS-Windows programmers are reinstalled. C++ programmers become undefined, + anyone who refers to them will die as well. Java programmers reincarnate + after being garbage collected. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e202b2c9aa808578d3328ec166a5cff7d7aae939 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:39 +0100 Subject: [PATCH 0046/3340] - patchlevel 328 --- 7.3.328 | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 7.3.328 diff --git a/7.3.328 b/7.3.328 new file mode 100644 index 00000000..24dad702 --- /dev/null +++ b/7.3.328 @@ -0,0 +1,45 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.328 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.328 +Problem: When command line wraps the cursor may be displayed wrong when + there are multi-byte characters. +Solution: Position the cursor before drawing the text. (Yasuhiro Matsumoto) +Files: src/ex_getln.c + + +*** ../vim-7.3.327/src/ex_getln.c 2011-09-30 16:23:21.000000000 +0200 +--- src/ex_getln.c 2011-09-30 17:39:27.000000000 +0200 +*************** +*** 2870,2875 **** +--- 2870,2876 ---- + { + msg_no_more = TRUE; + i = cmdline_row; ++ cursorcmd(); + draw_cmdline(ccline.cmdpos, ccline.cmdlen - ccline.cmdpos); + /* Avoid clearing the rest of the line too often. */ + if (cmdline_row != i || ccline.overstrike) +*** ../vim-7.3.327/src/version.c 2011-09-30 17:30:27.000000000 +0200 +--- src/version.c 2011-09-30 17:45:28.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 328, + /**/ + +-- +To define recursion, we must first define recursion. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d5f5f38aa829eb3c62aa844e9a2d42c386099cfe Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:39 +0100 Subject: [PATCH 0047/3340] - patchlevel 329 --- 7.3.329 | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 7.3.329 diff --git a/7.3.329 b/7.3.329 new file mode 100644 index 00000000..fe48eb52 --- /dev/null +++ b/7.3.329 @@ -0,0 +1,72 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.329 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.329 +Problem: When skipping over code from ":for" to ":endfor" get an error for + calling a dict function. (Yasuhiro Matsumoto) +Solution: Ignore errors when skipping over :call command. +Files: src/ex_docmd.c, src/eval.c + + +*** ../vim-7.3.328/src/ex_docmd.c 2011-09-21 19:10:42.000000000 +0200 +--- src/ex_docmd.c 2011-09-30 17:59:51.000000000 +0200 +*************** +*** 371,381 **** + # define ex_endif ex_ni + # define ex_else ex_ni + # define ex_while ex_ni +- # define ex_for ex_ni + # define ex_continue ex_ni + # define ex_break ex_ni + # define ex_endwhile ex_ni +- # define ex_endfor ex_ni + # define ex_throw ex_ni + # define ex_try ex_ni + # define ex_catch ex_ni +--- 371,379 ---- +*** ../vim-7.3.328/src/eval.c 2011-09-30 16:39:41.000000000 +0200 +--- src/eval.c 2011-09-30 18:29:58.000000000 +0200 +*************** +*** 3377,3383 **** + /* trans_function_name() doesn't work well when skipping, use eval0() + * instead to skip to any following command, e.g. for: + * :if 0 | call dict.foo().bar() | endif */ +! eval0(eap->arg, &rettv, &eap->nextcmd, FALSE); + return; + } + +--- 3377,3386 ---- + /* trans_function_name() doesn't work well when skipping, use eval0() + * instead to skip to any following command, e.g. for: + * :if 0 | call dict.foo().bar() | endif */ +! ++emsg_skip; +! if (eval0(eap->arg, &rettv, &eap->nextcmd, FALSE) != FAIL) +! clear_tv(&rettv); +! --emsg_skip; + return; + } + +*** ../vim-7.3.328/src/version.c 2011-09-30 17:46:14.000000000 +0200 +--- src/version.c 2011-09-30 18:32:27.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 329, + /**/ + +-- +Have you heard about the new Beowulf cluster? It's so fast, it executes +an infinite loop in 6 seconds. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9a764b6363f6e9650a34b4184023cc52e58951ca Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:40 +0100 Subject: [PATCH 0048/3340] - patchlevel 330 --- 7.3.330 | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 7.3.330 diff --git a/7.3.330 b/7.3.330 new file mode 100644 index 00000000..ab828b94 --- /dev/null +++ b/7.3.330 @@ -0,0 +1,45 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.330 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.330 +Problem: When longjmp() is invoked if the X server gives an error the state + is not properly restored. +Solution: Reset vgetc_busy. (Yukihiro Nakadaira) +Files: src/main.c + + +*** ../vim-7.3.329/src/main.c 2011-05-10 16:41:13.000000000 +0200 +--- src/main.c 2011-10-04 16:41:03.000000000 +0200 +*************** +*** 1009,1014 **** +--- 1009,1015 ---- + skip_redraw = FALSE; + RedrawingDisabled = 0; + no_wait_return = 0; ++ vgetc_busy = 0; + # ifdef FEAT_EVAL + emsg_skip = 0; + # endif +*** ../vim-7.3.329/src/version.c 2011-09-30 18:35:49.000000000 +0200 +--- src/version.c 2011-10-04 16:42:23.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 330, + /**/ + +-- +Just remember...if the world didn't suck, we'd all fall off. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a3832777374a27493b36c9ebffaf2eaaa327f236 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:40 +0100 Subject: [PATCH 0049/3340] - patchlevel 331 --- 7.3.331 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.331 diff --git a/7.3.331 b/7.3.331 new file mode 100644 index 00000000..ba63c172 --- /dev/null +++ b/7.3.331 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.331 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.331 +Problem: "vit" selects wrong text when a tag name starts with the same text + as an outer tag name. (Ben Fritz) +Solution: Add "\>" to the pattern to check for word boundary. +Files: src/search.c + + +*** ../vim-7.3.330/src/search.c 2011-07-15 13:21:24.000000000 +0200 +--- src/search.c 2011-10-04 16:54:08.000000000 +0200 +*************** +*** 3927,3933 **** + curwin->w_cursor = old_pos; + goto theend; + } +! sprintf((char *)spat, "<%.*s\\%%(\\_[^>]\\{-}[^/]>\\|>\\)\\c", len, p); + sprintf((char *)epat, "\\c", len, p); + + r = do_searchpair(spat, (char_u *)"", epat, FORWARD, (char_u *)"", +--- 3927,3933 ---- + curwin->w_cursor = old_pos; + goto theend; + } +! sprintf((char *)spat, "<%.*s\\>\\%%(\\_[^>]\\{-}[^/]>\\|>\\)\\c", len, p); + sprintf((char *)epat, "\\c", len, p); + + r = do_searchpair(spat, (char_u *)"", epat, FORWARD, (char_u *)"", +*** ../vim-7.3.330/src/version.c 2011-10-04 16:43:49.000000000 +0200 +--- src/version.c 2011-10-04 16:59:47.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 331, + /**/ + +-- +The 50-50-90 rule: Anytime you have a 50-50 chance of getting +something right, there's a 90% probability you'll get it wrong. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f409bd054bc380d714d586d191fd077da934b504 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:41 +0100 Subject: [PATCH 0050/3340] - patchlevel 332 --- 7.3.332 | 206 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 206 insertions(+) create mode 100644 7.3.332 diff --git a/7.3.332 b/7.3.332 new file mode 100644 index 00000000..ff0ab7c6 --- /dev/null +++ b/7.3.332 @@ -0,0 +1,206 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.332 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.332 (after 7.3.202) +Problem: Indent after "public:" is not increased in C++ code. (Lech Lorens) +Solution: Check for namespace after the regular checks. (partly by Martin + Gieseking) +Files: src/misc1.c, src/testdir/test3.in, src/testdir/test3.ok + + +*** ../vim-7.3.331/src/misc1.c 2011-09-07 19:58:04.000000000 +0200 +--- src/misc1.c 2011-10-04 17:59:52.000000000 +0200 +*************** +*** 6389,6394 **** +--- 6389,6395 ---- + int lookfor_cpp_namespace = FALSE; + int cont_amount = 0; /* amount for continuation line */ + int original_line_islabel; ++ int added_to_amount = 0; + + for (options = curbuf->b_p_cino; *options; ) + { +*************** +*** 7216,7267 **** + else + amount += ind_continuation; + } +! else if (lookfor_cpp_namespace) + { +! if (curwin->w_cursor.lnum == ourscope) +! continue; + +! if (curwin->w_cursor.lnum == 0 +! || curwin->w_cursor.lnum + < ourscope - FIND_NAMESPACE_LIM) +! break; + +! l = ml_get_curline(); + +! /* +! * If we're in a comment now, skip to the start of the +! * comment. +! */ +! trypos = find_start_comment(ind_maxcomment); +! if (trypos != NULL) +! { +! curwin->w_cursor.lnum = trypos->lnum + 1; +! curwin->w_cursor.col = 0; +! continue; +! } +! +! /* +! * Skip preprocessor directives and blank lines. +! */ +! if (cin_ispreproc_cont(&l, &curwin->w_cursor.lnum)) +! continue; + +! if (cin_is_cpp_namespace(l)) +! { +! amount += ind_cpp_namespace; +! break; +! } + +! if (cin_nocode(l)) +! continue; + +! } +! else if (lookfor != LOOKFOR_TERM +! && lookfor != LOOKFOR_CPP_BASECLASS) +! { +! amount = scope_amount; +! if (theline[0] == '{') +! amount += ind_open_extra; + } + break; + } +--- 7217,7275 ---- + else + amount += ind_continuation; + } +! else + { +! if (lookfor != LOOKFOR_TERM +! && lookfor != LOOKFOR_CPP_BASECLASS) +! { +! amount = scope_amount; +! if (theline[0] == '{') +! { +! amount += ind_open_extra; +! added_to_amount = ind_open_extra; +! } +! } + +! if (lookfor_cpp_namespace) +! { +! /* +! * Looking for C++ namespace, need to look further +! * back. +! */ +! if (curwin->w_cursor.lnum == ourscope) +! continue; +! +! if (curwin->w_cursor.lnum == 0 +! || curwin->w_cursor.lnum + < ourscope - FIND_NAMESPACE_LIM) +! break; + +! l = ml_get_curline(); + +! /* If we're in a comment now, skip to the start of +! * the comment. */ +! trypos = find_start_comment(ind_maxcomment); +! if (trypos != NULL) +! { +! curwin->w_cursor.lnum = trypos->lnum + 1; +! curwin->w_cursor.col = 0; +! continue; +! } + +! /* Skip preprocessor directives and blank lines. */ +! if (cin_ispreproc_cont(&l, &curwin->w_cursor.lnum)) +! continue; + +! /* Finally the actual check for "namespace". */ +! if (cin_is_cpp_namespace(l)) +! { +! amount += ind_cpp_namespace - added_to_amount; +! break; +! } + +! if (cin_nocode(l)) +! continue; +! } + } + break; + } +*** ../vim-7.3.331/src/testdir/test3.in 2011-07-20 15:09:38.000000000 +0200 +--- src/testdir/test3.in 2011-10-04 17:45:20.000000000 +0200 +*************** +*** 1309,1314 **** +--- 1309,1328 ---- + }; + + STARTTEST ++ :set cino=(0,gs,hs ++ 2kdd]]=][ ++ ENDTEST ++ ++ class Foo : public Bar ++ { ++ public: ++ virtual void method1(void) = 0; ++ virtual void method2(int arg1, ++ int arg2, ++ int arg3) = 0; ++ }; ++ ++ STARTTEST + :set cino=+20 + 2kdd]]=][ + ENDTEST +*** ../vim-7.3.331/src/testdir/test3.ok 2011-07-20 15:09:38.000000000 +0200 +--- src/testdir/test3.ok 2011-10-04 17:47:25.000000000 +0200 +*************** +*** 1190,1195 **** +--- 1190,1205 ---- + }; + + ++ class Foo : public Bar ++ { ++ public: ++ virtual void method1(void) = 0; ++ virtual void method2(int arg1, ++ int arg2, ++ int arg3) = 0; ++ }; ++ ++ + void + foo() + { +*** ../vim-7.3.331/src/version.c 2011-10-04 17:00:13.000000000 +0200 +--- src/version.c 2011-10-04 18:02:17.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 332, + /**/ + +-- +Latest survey shows that 3 out of 4 people make up 75% of the +world's population. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 361ac5521c3ffaa187c59b57aab93bd60c789e4d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:41 +0100 Subject: [PATCH 0051/3340] - patchlevel 333 --- 7.3.333 | 245 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 245 insertions(+) create mode 100644 7.3.333 diff --git a/7.3.333 b/7.3.333 new file mode 100644 index 00000000..974b0cda --- /dev/null +++ b/7.3.333 @@ -0,0 +1,245 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.333 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.333 +Problem: Using "." to repeat a Visual delete counts the size in bytes, not + characters. (Connor Lane Smith) +Solution: Store the virtual column numbers instead of byte positions. +Files: src/normal.c + + +*** ../vim-7.3.332/src/normal.c 2011-07-15 17:51:30.000000000 +0200 +--- src/normal.c 2011-10-04 19:47:14.000000000 +0200 +*************** +*** 20,26 **** + */ + static int resel_VIsual_mode = NUL; /* 'v', 'V', or Ctrl-V */ + static linenr_T resel_VIsual_line_count; /* number of lines */ +! static colnr_T resel_VIsual_col; /* nr of cols or end col */ + + static int restart_VIsual_select = 0; + #endif +--- 20,26 ---- + */ + static int resel_VIsual_mode = NUL; /* 'v', 'V', or Ctrl-V */ + static linenr_T resel_VIsual_line_count; /* number of lines */ +! static colnr_T resel_VIsual_vcol; /* nr of cols or end col */ + + static int restart_VIsual_select = 0; + #endif +*************** +*** 1436,1442 **** + /* The visual area is remembered for redo */ + static int redo_VIsual_mode = NUL; /* 'v', 'V', or Ctrl-V */ + static linenr_T redo_VIsual_line_count; /* number of lines */ +! static colnr_T redo_VIsual_col; /* number of cols or end column */ + static long redo_VIsual_count; /* count for Visual operator */ + # ifdef FEAT_VIRTUALEDIT + int include_line_break = FALSE; +--- 1436,1442 ---- + /* The visual area is remembered for redo */ + static int redo_VIsual_mode = NUL; /* 'v', 'V', or Ctrl-V */ + static linenr_T redo_VIsual_line_count; /* number of lines */ +! static colnr_T redo_VIsual_vcol; /* number of cols or end column */ + static long redo_VIsual_count; /* count for Visual operator */ + # ifdef FEAT_VIRTUALEDIT + int include_line_break = FALSE; +*************** +*** 1549,1570 **** + #ifdef FEAT_VISUAL + if (redo_VIsual_busy) + { + oap->start = curwin->w_cursor; + curwin->w_cursor.lnum += redo_VIsual_line_count - 1; + if (curwin->w_cursor.lnum > curbuf->b_ml.ml_line_count) + curwin->w_cursor.lnum = curbuf->b_ml.ml_line_count; + VIsual_mode = redo_VIsual_mode; +! if (VIsual_mode == 'v') + { +! if (redo_VIsual_line_count <= 1) +! curwin->w_cursor.col += redo_VIsual_col - 1; + else +! curwin->w_cursor.col = redo_VIsual_col; +! } +! if (redo_VIsual_col == MAXCOL) +! { +! curwin->w_curswant = MAXCOL; +! coladvance((colnr_T)MAXCOL); + } + cap->count0 = redo_VIsual_count; + if (redo_VIsual_count != 0) +--- 1549,1579 ---- + #ifdef FEAT_VISUAL + if (redo_VIsual_busy) + { ++ /* Redo of an operation on a Visual area. Use the same size from ++ * redo_VIsual_line_count and redo_VIsual_vcol. */ + oap->start = curwin->w_cursor; + curwin->w_cursor.lnum += redo_VIsual_line_count - 1; + if (curwin->w_cursor.lnum > curbuf->b_ml.ml_line_count) + curwin->w_cursor.lnum = curbuf->b_ml.ml_line_count; + VIsual_mode = redo_VIsual_mode; +! if (redo_VIsual_vcol == MAXCOL || VIsual_mode == 'v') + { +! if (VIsual_mode == 'v') +! { +! if (redo_VIsual_line_count <= 1) +! { +! validate_virtcol(); +! curwin->w_curswant = +! curwin->w_virtcol + redo_VIsual_vcol - 1; +! } +! else +! curwin->w_curswant = redo_VIsual_vcol; +! } + else +! { +! curwin->w_curswant = MAXCOL; +! } +! coladvance(curwin->w_curswant); + } + cap->count0 = redo_VIsual_count; + if (redo_VIsual_count != 0) +*************** +*** 1710,1716 **** + } + } + else if (redo_VIsual_busy) +! oap->end_vcol = oap->start_vcol + redo_VIsual_col - 1; + /* + * Correct oap->end.col and oap->start.col to be the + * upper-left and lower-right corner of the block area. +--- 1719,1725 ---- + } + } + else if (redo_VIsual_busy) +! oap->end_vcol = oap->start_vcol + redo_VIsual_vcol - 1; + /* + * Correct oap->end.col and oap->start.col to be the + * upper-left and lower-right corner of the block area. +*************** +*** 1735,1747 **** + */ + resel_VIsual_mode = VIsual_mode; + if (curwin->w_curswant == MAXCOL) +! resel_VIsual_col = MAXCOL; +! else if (VIsual_mode == Ctrl_V) +! resel_VIsual_col = oap->end_vcol - oap->start_vcol + 1; +! else if (oap->line_count > 1) +! resel_VIsual_col = oap->end.col; + else +! resel_VIsual_col = oap->end.col - oap->start.col + 1; + resel_VIsual_line_count = oap->line_count; + } + +--- 1744,1765 ---- + */ + resel_VIsual_mode = VIsual_mode; + if (curwin->w_curswant == MAXCOL) +! resel_VIsual_vcol = MAXCOL; + else +! { +! if (VIsual_mode != Ctrl_V) +! getvvcol(curwin, &(oap->end), +! NULL, NULL, &oap->end_vcol); +! if (VIsual_mode == Ctrl_V || oap->line_count <= 1) +! { +! if (VIsual_mode != Ctrl_V) +! getvvcol(curwin, &(oap->start), +! &oap->start_vcol, NULL, NULL); +! resel_VIsual_vcol = oap->end_vcol - oap->start_vcol + 1; +! } +! else +! resel_VIsual_vcol = oap->end_vcol; +! } + resel_VIsual_line_count = oap->line_count; + } + +*************** +*** 1769,1775 **** + if (!redo_VIsual_busy) + { + redo_VIsual_mode = resel_VIsual_mode; +! redo_VIsual_col = resel_VIsual_col; + redo_VIsual_line_count = resel_VIsual_line_count; + redo_VIsual_count = cap->count0; + } +--- 1787,1793 ---- + if (!redo_VIsual_busy) + { + redo_VIsual_mode = resel_VIsual_mode; +! redo_VIsual_vcol = resel_VIsual_vcol; + redo_VIsual_line_count = resel_VIsual_line_count; + redo_VIsual_count = cap->count0; + } +*************** +*** 7631,7642 **** + if (VIsual_mode == 'v') + { + if (resel_VIsual_line_count <= 1) +! curwin->w_cursor.col += resel_VIsual_col * cap->count0 - 1; + else +! curwin->w_cursor.col = resel_VIsual_col; +! check_cursor_col(); + } +! if (resel_VIsual_col == MAXCOL) + { + curwin->w_curswant = MAXCOL; + coladvance((colnr_T)MAXCOL); +--- 7649,7664 ---- + if (VIsual_mode == 'v') + { + if (resel_VIsual_line_count <= 1) +! { +! validate_virtcol(); +! curwin->w_curswant = curwin->w_virtcol +! + resel_VIsual_vcol * cap->count0 - 1; +! } + else +! curwin->w_curswant = resel_VIsual_vcol; +! coladvance(curwin->w_curswant); + } +! if (resel_VIsual_vcol == MAXCOL) + { + curwin->w_curswant = MAXCOL; + coladvance((colnr_T)MAXCOL); +*************** +*** 7645,7651 **** + { + validate_virtcol(); + curwin->w_curswant = curwin->w_virtcol +! + resel_VIsual_col * cap->count0 - 1; + coladvance(curwin->w_curswant); + } + else +--- 7667,7673 ---- + { + validate_virtcol(); + curwin->w_curswant = curwin->w_virtcol +! + resel_VIsual_vcol * cap->count0 - 1; + coladvance(curwin->w_curswant); + } + else +*** ../vim-7.3.332/src/version.c 2011-10-04 18:03:43.000000000 +0200 +--- src/version.c 2011-10-04 21:05:44.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 333, + /**/ + +-- +It was recently discovered that research causes cancer in rats. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e33cf8e1f11e16177208b9f0536a060109a240a8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:41 +0100 Subject: [PATCH 0052/3340] - patchlevel 334 --- 7.3.334 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.334 diff --git a/7.3.334 b/7.3.334 new file mode 100644 index 00000000..85d5b16d --- /dev/null +++ b/7.3.334 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.334 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.334 +Problem: Latest MingW about XSUBPP referencing itself. (Gongqian Li) +Solution: Rename the first use to XSUBPPTRY. +Files: src/Make_ming.mak + + +*** ../vim-7.3.333/src/Make_ming.mak 2011-09-30 16:56:00.000000000 +0200 +--- src/Make_ming.mak 2011-10-09 14:23:06.000000000 +0200 +*************** +*** 108,117 **** + # on NT, it's here: + PERLLIB=$(PERL)/lib + PERLLIBS=$(PERLLIB)/Core +! XSUBPP=$(PERLLIB)/ExtUtils/xsubpp +! XSUBPP_EXISTS=$(shell perl -e "print 1 unless -e '$(XSUBPP)'") + ifeq "$(XSUBPP_EXISTS)" "" +! XSUBPP=perl $(XSUBPP) + else + XSUBPP=xsubpp + endif +--- 108,117 ---- + # on NT, it's here: + PERLLIB=$(PERL)/lib + PERLLIBS=$(PERLLIB)/Core +! XSUBPPTRY=$(PERLLIB)/ExtUtils/xsubpp +! XSUBPP_EXISTS=$(shell perl -e "print 1 unless -e '$(XSUBPPTRY)'") + ifeq "$(XSUBPP_EXISTS)" "" +! XSUBPP=perl $(XSUBPPTRY) + else + XSUBPP=xsubpp + endif +*** ../vim-7.3.333/src/version.c 2011-10-04 21:22:40.000000000 +0200 +--- src/version.c 2011-10-12 14:10:20.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 334, + /**/ + +-- +Q: Should I clean my house or work on Vim? +A: Whatever contains more bugs. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From df049c9de8b62d2a2f4c1c4f7ac444ce66e46947 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:42 +0100 Subject: [PATCH 0053/3340] - patchlevel 335 --- 7.3.335 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.335 diff --git a/7.3.335 b/7.3.335 new file mode 100644 index 00000000..dc1cc560 --- /dev/null +++ b/7.3.335 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.335 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.335 +Problem: When 'imdisable' is reset from an autocommand in Insert mode it + doesn't take effect. +Solution: Call im_set_active() in Insert mode. (Taro Muraoka) +Files: src/option.c + + +*** ../vim-7.3.334/src/option.c 2011-09-21 13:40:13.000000000 +0200 +--- src/option.c 2011-10-12 14:09:46.000000000 +0200 +*************** +*** 7806,7811 **** +--- 7806,7815 ---- + /* Only de-activate it here, it will be enabled when changing mode. */ + if (p_imdisable) + im_set_active(FALSE); ++ else if (State & INSERT) ++ /* When the option is set from an autocommand, it may need to take ++ * effect right away. */ ++ im_set_active(curbuf->b_p_iminsert == B_IMODE_IM); + } + #endif + +*** ../vim-7.3.334/src/version.c 2011-10-12 14:11:43.000000000 +0200 +--- src/version.c 2011-10-12 16:56:30.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 335, + /**/ + +-- +Time is money. Especially if you make clocks. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 27b736dc86acd3cd4328aafd36691f990733f868 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:42 +0100 Subject: [PATCH 0054/3340] - patchlevel 336 --- 7.3.336 | 1100 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1100 insertions(+) create mode 100644 7.3.336 diff --git a/7.3.336 b/7.3.336 new file mode 100644 index 00000000..f1a92c61 --- /dev/null +++ b/7.3.336 @@ -0,0 +1,1100 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.336 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.336 +Problem: When a tags file specifies an encoding different from 'enc' it + may hang and using a pattern doesn't work. +Solution: Convert the whole line. Continue reading the header after the + SORT tag. Add test83. (Yukihiro Nakadaira) +Files: src/tag.c, src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak, + src/testdir/Make_ming.mak, src/testdir/Make_os2.mak, + src/testdir/Make_vms.mms, src/testdir/Makefile, + src/testdir/test83-tags2, src/testdir/test83-tags3, + src/testdir/test83.in, src/testdir/test83.ok + + +*** ../vim-7.3.335/src/tag.c 2011-04-11 21:35:03.000000000 +0200 +--- src/tag.c 2011-10-12 19:51:04.000000000 +0200 +*************** +*** 1277,1282 **** +--- 1277,1283 ---- + { + FILE *fp; + char_u *lbuf; /* line buffer */ ++ int lbuf_size = LSIZE; /* length of lbuf */ + char_u *tag_fname; /* name of tag file */ + tagname_T tn; /* info for get_tagfname() */ + int first_file; /* trying first tag file */ +*************** +*** 1291,1296 **** +--- 1292,1298 ---- + char_u *s; + int i; + #ifdef FEAT_TAG_BINS ++ int tag_file_sorted = NUL; /* !_TAG_FILE_SORTED value */ + struct tag_search_info /* Binary search file offsets */ + { + off_t low_offset; /* offset for first char of first line that +*************** +*** 1360,1372 **** + char_u *saved_pat = NULL; /* copy of pat[] */ + #endif + +- /* Use two sets of variables for the pattern: "orgpat" holds the values +- * for the original pattern and "convpat" converted from 'encoding' to +- * encoding of the tags file. "pats" point to either one of these. */ +- pat_T *pats; + pat_T orgpat; /* holds unconverted pattern info */ + #ifdef FEAT_MBYTE +- pat_T convpat; /* holds converted pattern info */ + vimconv_T vimconv; + #endif + +--- 1362,1369 ---- +*************** +*** 1390,1396 **** + + help_save = curbuf->b_help; + orgpat.pat = pat; +- pats = &orgpat; + #ifdef FEAT_MBYTE + vimconv.vc_type = CONV_NONE; + #endif +--- 1387,1392 ---- +*************** +*** 1398,1404 **** + /* + * Allocate memory for the buffers that are used + */ +! lbuf = alloc(LSIZE); + tag_fname = alloc(MAXPATHL + 1); + #ifdef FEAT_EMACS_TAGS + ebuf = alloc(LSIZE); +--- 1394,1400 ---- + /* + * Allocate memory for the buffers that are used + */ +! lbuf = alloc(lbuf_size); + tag_fname = alloc(MAXPATHL + 1); + #ifdef FEAT_EMACS_TAGS + ebuf = alloc(LSIZE); +*************** +*** 1424,1453 **** + if (help_only) /* want tags from help file */ + curbuf->b_help = TRUE; /* will be restored later */ + +! pats->len = (int)STRLEN(pat); + #ifdef FEAT_MULTI_LANG + if (curbuf->b_help) + { + /* When "@ab" is specified use only the "ab" language, otherwise + * search all languages. */ +! if (pats->len > 3 && pat[pats->len - 3] == '@' +! && ASCII_ISALPHA(pat[pats->len - 2]) +! && ASCII_ISALPHA(pat[pats->len - 1])) + { +! saved_pat = vim_strnsave(pat, pats->len - 3); + if (saved_pat != NULL) + { +! help_lang_find = &pat[pats->len - 2]; +! pats->pat = saved_pat; +! pats->len -= 3; + } + } + } + #endif +! if (p_tl != 0 && pats->len > p_tl) /* adjust for 'taglength' */ +! pats->len = p_tl; + +! prepare_pats(pats, has_re); + + #ifdef FEAT_TAG_BINS + /* This is only to avoid a compiler warning for using search_info +--- 1420,1449 ---- + if (help_only) /* want tags from help file */ + curbuf->b_help = TRUE; /* will be restored later */ + +! orgpat.len = (int)STRLEN(pat); + #ifdef FEAT_MULTI_LANG + if (curbuf->b_help) + { + /* When "@ab" is specified use only the "ab" language, otherwise + * search all languages. */ +! if (orgpat.len > 3 && pat[orgpat.len - 3] == '@' +! && ASCII_ISALPHA(pat[orgpat.len - 2]) +! && ASCII_ISALPHA(pat[orgpat.len - 1])) + { +! saved_pat = vim_strnsave(pat, orgpat.len - 3); + if (saved_pat != NULL) + { +! help_lang_find = &pat[orgpat.len - 2]; +! orgpat.pat = saved_pat; +! orgpat.len -= 3; + } + } + } + #endif +! if (p_tl != 0 && orgpat.len > p_tl) /* adjust for 'taglength' */ +! orgpat.len = p_tl; + +! prepare_pats(&orgpat, has_re); + + #ifdef FEAT_TAG_BINS + /* This is only to avoid a compiler warning for using search_info +*************** +*** 1466,1478 **** + * Only ignore case when TAG_NOIC not used or 'ignorecase' set. + */ + #ifdef FEAT_TAG_BINS +! pats->regmatch.rm_ic = ((p_ic || !noic) +! && (findall || pats->headlen == 0 || !p_tbs)); + for (round = 1; round <= 2; ++round) + { +! linear = (pats->headlen == 0 || !p_tbs || round == 2); + #else +! pats->regmatch.rm_ic = (p_ic || !noic); + #endif + + /* +--- 1462,1474 ---- + * Only ignore case when TAG_NOIC not used or 'ignorecase' set. + */ + #ifdef FEAT_TAG_BINS +! orgpat.regmatch.rm_ic = ((p_ic || !noic) +! && (findall || orgpat.headlen == 0 || !p_tbs)); + for (round = 1; round <= 2; ++round) + { +! linear = (orgpat.headlen == 0 || !p_tbs || round == 2); + #else +! orgpat.regmatch.rm_ic = (p_ic || !noic); + #endif + + /* +*************** +*** 1701,1706 **** +--- 1697,1732 ---- + } + line_read_in: + ++ #ifdef FEAT_MBYTE ++ if (vimconv.vc_type != CONV_NONE) ++ { ++ char_u *conv_line; ++ int len; ++ ++ /* Convert every line. Converting the pattern from 'enc' to ++ * the tags file encoding doesn't work, because characters are ++ * not recognized. */ ++ conv_line = string_convert(&vimconv, lbuf, NULL); ++ if (conv_line != NULL) ++ { ++ /* Copy or swap lbuf and conv_line. */ ++ len = (int)STRLEN(conv_line) + 1; ++ if (len > lbuf_size) ++ { ++ vim_free(lbuf); ++ lbuf = conv_line; ++ lbuf_size = len; ++ } ++ else ++ { ++ STRCPY(lbuf, conv_line); ++ vim_free(conv_line); ++ } ++ } ++ } ++ #endif ++ ++ + #ifdef FEAT_EMACS_TAGS + /* + * Emacs tags line with CTRL-L: New file name on next line. +*************** +*** 1770,1775 **** +--- 1796,1828 ---- + */ + if (state == TS_START) + { ++ if (STRNCMP(lbuf, "!_TAG_", 6) <= 0) ++ { ++ /* ++ * Read header line. ++ */ ++ #ifdef FEAT_TAG_BINS ++ if (STRNCMP(lbuf, "!_TAG_FILE_SORTED\t", 18) == 0) ++ tag_file_sorted = lbuf[18]; ++ #endif ++ #ifdef FEAT_MBYTE ++ if (STRNCMP(lbuf, "!_TAG_FILE_ENCODING\t", 20) == 0) ++ { ++ /* Prepare to convert every line from the specified ++ * encoding to 'encoding'. */ ++ for (p = lbuf + 20; *p > ' ' && *p < 127; ++p) ++ ; ++ *p = NUL; ++ convert_setup(&vimconv, lbuf + 20, p_enc); ++ } ++ #endif ++ ++ /* Read the next line. Unrecognized flags are ignored. */ ++ continue; ++ } ++ ++ /* Headers ends. */ ++ + #ifdef FEAT_TAG_BINS + /* + * When there is no tag head, or ignoring case, need to do a +*************** +*** 1786,1809 **** + if (linear) + # endif + state = TS_LINEAR; +! else if (STRNCMP(lbuf, "!_TAG_", 6) > 0) + state = TS_BINARY; +! else if (STRNCMP(lbuf, "!_TAG_FILE_SORTED\t", 18) == 0) +! { +! /* Check sorted flag */ +! if (lbuf[18] == '1') + state = TS_BINARY; +! else if (lbuf[18] == '2') +! { +! state = TS_BINARY; +! sortic = TRUE; +! pats->regmatch.rm_ic = (p_ic || !noic); +! } +! else +! state = TS_LINEAR; + } + +! if (state == TS_BINARY && pats->regmatch.rm_ic && !sortic) + { + /* binary search won't work for ignoring case, use linear + * search. */ +--- 1839,1858 ---- + if (linear) + # endif + state = TS_LINEAR; +! else if (tag_file_sorted == NUL) + state = TS_BINARY; +! else if (tag_file_sorted == '1') + state = TS_BINARY; +! else if (tag_file_sorted == '2') +! { +! state = TS_BINARY; +! sortic = TRUE; +! orgpat.regmatch.rm_ic = (p_ic || !noic); + } ++ else ++ state = TS_LINEAR; + +! if (state == TS_BINARY && orgpat.regmatch.rm_ic && !sortic) + { + /* binary search won't work for ignoring case, use linear + * search. */ +*************** +*** 1843,1882 **** + #endif + } + +- #ifdef FEAT_MBYTE +- if (lbuf[0] == '!' && pats == &orgpat +- && STRNCMP(lbuf, "!_TAG_FILE_ENCODING\t", 20) == 0) +- { +- /* Convert the search pattern from 'encoding' to the +- * specified encoding. */ +- for (p = lbuf + 20; *p > ' ' && *p < 127; ++p) +- ; +- *p = NUL; +- convert_setup(&vimconv, p_enc, lbuf + 20); +- if (vimconv.vc_type != CONV_NONE) +- { +- convpat.pat = string_convert(&vimconv, pats->pat, NULL); +- if (convpat.pat != NULL) +- { +- pats = &convpat; +- pats->len = (int)STRLEN(pats->pat); +- prepare_pats(pats, has_re); +- pats->regmatch.rm_ic = orgpat.regmatch.rm_ic; +- } +- } +- +- /* Prepare for converting a match the other way around. */ +- convert_setup(&vimconv, lbuf + 20, p_enc); +- continue; +- } +- #endif +- + /* + * Figure out where the different strings are in this line. + * For "normal" tags: Do a quick check if the tag matches. + * This speeds up tag searching a lot! + */ +! if (pats->headlen + #ifdef FEAT_EMACS_TAGS + && !is_etag + #endif +--- 1892,1903 ---- + #endif + } + + /* + * Figure out where the different strings are in this line. + * For "normal" tags: Do a quick check if the tag matches. + * This speeds up tag searching a lot! + */ +! if (orgpat.headlen + #ifdef FEAT_EMACS_TAGS + && !is_etag + #endif +*************** +*** 1933,1941 **** + cmplen = (int)(tagp.tagname_end - tagp.tagname); + if (p_tl != 0 && cmplen > p_tl) /* adjust for 'taglength' */ + cmplen = p_tl; +! if (has_re && pats->headlen < cmplen) +! cmplen = pats->headlen; +! else if (state == TS_LINEAR && pats->headlen != cmplen) + continue; + + #ifdef FEAT_TAG_BINS +--- 1954,1962 ---- + cmplen = (int)(tagp.tagname_end - tagp.tagname); + if (p_tl != 0 && cmplen > p_tl) /* adjust for 'taglength' */ + cmplen = p_tl; +! if (has_re && orgpat.headlen < cmplen) +! cmplen = orgpat.headlen; +! else if (state == TS_LINEAR && orgpat.headlen != cmplen) + continue; + + #ifdef FEAT_TAG_BINS +*************** +*** 1954,1963 **** + * Compare the current tag with the searched tag. + */ + if (sortic) +! tagcmp = tag_strnicmp(tagp.tagname, pats->head, + (size_t)cmplen); + else +! tagcmp = STRNCMP(tagp.tagname, pats->head, cmplen); + + /* + * A match with a shorter tag means to search forward. +--- 1975,1984 ---- + * Compare the current tag with the searched tag. + */ + if (sortic) +! tagcmp = tag_strnicmp(tagp.tagname, orgpat.head, + (size_t)cmplen); + else +! tagcmp = STRNCMP(tagp.tagname, orgpat.head, cmplen); + + /* + * A match with a shorter tag means to search forward. +*************** +*** 1965,1973 **** + */ + if (tagcmp == 0) + { +! if (cmplen < pats->headlen) + tagcmp = -1; +! else if (cmplen > pats->headlen) + tagcmp = 1; + } + +--- 1986,1994 ---- + */ + if (tagcmp == 0) + { +! if (cmplen < orgpat.headlen) + tagcmp = -1; +! else if (cmplen > orgpat.headlen) + tagcmp = 1; + } + +*************** +*** 2011,2017 **** + } + else if (state == TS_SKIP_BACK) + { +! if (MB_STRNICMP(tagp.tagname, pats->head, cmplen) != 0) + state = TS_STEP_FORWARD; + else + /* Have to skip back more. Restore the curr_offset +--- 2032,2038 ---- + } + else if (state == TS_SKIP_BACK) + { +! if (MB_STRNICMP(tagp.tagname, orgpat.head, cmplen) != 0) + state = TS_STEP_FORWARD; + else + /* Have to skip back more. Restore the curr_offset +*************** +*** 2021,2027 **** + } + else if (state == TS_STEP_FORWARD) + { +! if (MB_STRNICMP(tagp.tagname, pats->head, cmplen) != 0) + { + if ((off_t)ftell(fp) > search_info.match_offset) + break; /* past last match */ +--- 2042,2048 ---- + } + else if (state == TS_STEP_FORWARD) + { +! if (MB_STRNICMP(tagp.tagname, orgpat.head, cmplen) != 0) + { + if ((off_t)ftell(fp) > search_info.match_offset) + break; /* past last match */ +*************** +*** 2032,2038 **** + else + #endif + /* skip this match if it can't match */ +! if (MB_STRNICMP(tagp.tagname, pats->head, cmplen) != 0) + continue; + + /* +--- 2053,2059 ---- + else + #endif + /* skip this match if it can't match */ +! if (MB_STRNICMP(tagp.tagname, orgpat.head, cmplen) != 0) + continue; + + /* +*************** +*** 2083,2123 **** + if (p_tl != 0 && cmplen > p_tl) /* adjust for 'taglength' */ + cmplen = p_tl; + /* if tag length does not match, don't try comparing */ +! if (pats->len != cmplen) + match = FALSE; + else + { +! if (pats->regmatch.rm_ic) + { +! match = (MB_STRNICMP(tagp.tagname, pats->pat, cmplen) == 0); + if (match) +! match_no_ic = (STRNCMP(tagp.tagname, pats->pat, + cmplen) == 0); + } + else +! match = (STRNCMP(tagp.tagname, pats->pat, cmplen) == 0); + } + + /* + * Has a regexp: Also find tags matching regexp. + */ + match_re = FALSE; +! if (!match && pats->regmatch.regprog != NULL) + { + int cc; + + cc = *tagp.tagname_end; + *tagp.tagname_end = NUL; +! match = vim_regexec(&pats->regmatch, tagp.tagname, (colnr_T)0); + if (match) + { +! matchoff = (int)(pats->regmatch.startp[0] - tagp.tagname); +! if (pats->regmatch.rm_ic) + { +! pats->regmatch.rm_ic = FALSE; +! match_no_ic = vim_regexec(&pats->regmatch, tagp.tagname, + (colnr_T)0); +! pats->regmatch.rm_ic = TRUE; + } + } + *tagp.tagname_end = cc; +--- 2104,2144 ---- + if (p_tl != 0 && cmplen > p_tl) /* adjust for 'taglength' */ + cmplen = p_tl; + /* if tag length does not match, don't try comparing */ +! if (orgpat.len != cmplen) + match = FALSE; + else + { +! if (orgpat.regmatch.rm_ic) + { +! match = (MB_STRNICMP(tagp.tagname, orgpat.pat, cmplen) == 0); + if (match) +! match_no_ic = (STRNCMP(tagp.tagname, orgpat.pat, + cmplen) == 0); + } + else +! match = (STRNCMP(tagp.tagname, orgpat.pat, cmplen) == 0); + } + + /* + * Has a regexp: Also find tags matching regexp. + */ + match_re = FALSE; +! if (!match && orgpat.regmatch.regprog != NULL) + { + int cc; + + cc = *tagp.tagname_end; + *tagp.tagname_end = NUL; +! match = vim_regexec(&orgpat.regmatch, tagp.tagname, (colnr_T)0); + if (match) + { +! matchoff = (int)(orgpat.regmatch.startp[0] - tagp.tagname); +! if (orgpat.regmatch.rm_ic) + { +! orgpat.regmatch.rm_ic = FALSE; +! match_no_ic = vim_regexec(&orgpat.regmatch, tagp.tagname, + (colnr_T)0); +! orgpat.regmatch.rm_ic = TRUE; + } + } + *tagp.tagname_end = cc; +*************** +*** 2174,2180 **** + else + mtt = MT_GL_OTH; + } +! if (pats->regmatch.rm_ic && !match_no_ic) + mtt += MT_IC_OFF; + if (match_re) + mtt += MT_RE_OFF; +--- 2195,2201 ---- + else + mtt = MT_GL_OTH; + } +! if (orgpat.regmatch.rm_ic && !match_no_ic) + mtt += MT_IC_OFF; + if (match_re) + mtt += MT_RE_OFF; +*************** +*** 2187,2221 **** + */ + if (ga_grow(&ga_match[mtt], 1) == OK) + { +- #ifdef FEAT_MBYTE +- char_u *conv_line = NULL; +- char_u *lbuf_line = lbuf; +- +- if (vimconv.vc_type != CONV_NONE) +- { +- /* Convert the tag line from the encoding of the tags +- * file to 'encoding'. Then parse the line again. */ +- conv_line = string_convert(&vimconv, lbuf, NULL); +- if (conv_line != NULL) +- { +- if (parse_tag_line(conv_line, +- #ifdef FEAT_EMACS_TAGS +- is_etag, +- #endif +- &tagp) == OK) +- lbuf_line = conv_line; +- else +- /* doesn't work, go back to unconverted line. */ +- (void)parse_tag_line(lbuf, +- #ifdef FEAT_EMACS_TAGS +- is_etag, +- #endif +- &tagp); +- } +- } +- #else +- # define lbuf_line lbuf +- #endif + if (help_only) + { + #ifdef FEAT_MULTI_LANG +--- 2208,2213 ---- +*************** +*** 2307,2313 **** + * without Emacs tags: + */ + len = (int)STRLEN(tag_fname) +! + (int)STRLEN(lbuf_line) + 3; + #ifdef FEAT_EMACS_TAGS + if (is_etag) + len += (int)STRLEN(ebuf) + 1; +--- 2299,2305 ---- + * without Emacs tags: + */ + len = (int)STRLEN(tag_fname) +! + (int)STRLEN(lbuf) + 3; + #ifdef FEAT_EMACS_TAGS + if (is_etag) + len += (int)STRLEN(ebuf) + 1; +*************** +*** 2337,2343 **** + else + *s++ = NUL; + #endif +! STRCPY(s, lbuf_line); + } + } + +--- 2329,2335 ---- + else + *s++ = NUL; + #endif +! STRCPY(s, lbuf); + } + } + +*************** +*** 2373,2382 **** + else + vim_free(mfp); + } +- #ifdef FEAT_MBYTE +- /* Note: this makes the values in "tagp" invalid! */ +- vim_free(conv_line); +- #endif + } + else /* Out of memory! Just forget about the rest. */ + { +--- 2365,2370 ---- +*************** +*** 2415,2433 **** + } + #endif + #ifdef FEAT_MBYTE +- if (pats == &convpat) +- { +- /* Go back from converted pattern to original pattern. */ +- vim_free(pats->pat); +- vim_free(pats->regmatch.regprog); +- orgpat.regmatch.rm_ic = pats->regmatch.rm_ic; +- pats = &orgpat; +- } + if (vimconv.vc_type != CONV_NONE) + convert_setup(&vimconv, NULL, NULL); + #endif + + #ifdef FEAT_TAG_BINS + if (sort_error) + { + EMSG2(_("E432: Tags file not sorted: %s"), tag_fname); +--- 2403,2414 ---- + } + #endif + #ifdef FEAT_MBYTE + if (vimconv.vc_type != CONV_NONE) + convert_setup(&vimconv, NULL, NULL); + #endif + + #ifdef FEAT_TAG_BINS ++ tag_file_sorted = NUL; + if (sort_error) + { + EMSG2(_("E432: Tags file not sorted: %s"), tag_fname); +*************** +*** 2461,2473 **** + #ifdef FEAT_TAG_BINS + /* stop searching when already did a linear search, or when TAG_NOIC + * used, and 'ignorecase' not set or already did case-ignore search */ +! if (stop_searching || linear || (!p_ic && noic) || pats->regmatch.rm_ic) + break; + # ifdef FEAT_CSCOPE + if (use_cscope) + break; + # endif +! pats->regmatch.rm_ic = TRUE; /* try another time while ignoring case */ + } + #endif + +--- 2442,2454 ---- + #ifdef FEAT_TAG_BINS + /* stop searching when already did a linear search, or when TAG_NOIC + * used, and 'ignorecase' not set or already did case-ignore search */ +! if (stop_searching || linear || (!p_ic && noic) || orgpat.regmatch.rm_ic) + break; + # ifdef FEAT_CSCOPE + if (use_cscope) + break; + # endif +! orgpat.regmatch.rm_ic = TRUE; /* try another time while ignoring case */ + } + #endif + +*************** +*** 2480,2486 **** + + findtag_end: + vim_free(lbuf); +! vim_free(pats->regmatch.regprog); + vim_free(tag_fname); + #ifdef FEAT_EMACS_TAGS + vim_free(ebuf); +--- 2461,2467 ---- + + findtag_end: + vim_free(lbuf); +! vim_free(orgpat.regmatch.regprog); + vim_free(tag_fname); + #ifdef FEAT_EMACS_TAGS + vim_free(ebuf); +*** ../vim-7.3.335/src/testdir/Make_amiga.mak 2011-07-15 21:16:54.000000000 +0200 +--- src/testdir/Make_amiga.mak 2011-10-12 19:21:00.000000000 +0200 +*************** +*** 29,35 **** + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out + + .SUFFIXES: .in .out + +--- 29,35 ---- + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out test83.out + + .SUFFIXES: .in .out + +*************** +*** 131,133 **** +--- 131,134 ---- + test80.out: test80.in + test81.out: test81.in + test82.out: test82.in ++ test83.out: test83.in +*** ../vim-7.3.335/src/testdir/Make_dos.mak 2011-07-15 21:16:54.000000000 +0200 +--- src/testdir/Make_dos.mak 2011-10-12 17:39:03.000000000 +0200 +*************** +*** 29,35 **** + test42.out test52.out test65.out test66.out test67.out \ + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ +! test79.out test80.out test81.out test82.out + + SCRIPTS32 = test50.out test70.out + +--- 29,35 ---- + test42.out test52.out test65.out test66.out test67.out \ + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ +! test79.out test80.out test81.out test82.out test83.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.335/src/testdir/Make_ming.mak 2011-07-15 21:16:54.000000000 +0200 +--- src/testdir/Make_ming.mak 2011-10-12 17:39:03.000000000 +0200 +*************** +*** 49,55 **** + test42.out test52.out test65.out test66.out test67.out \ + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ +! test79.out test80.out test81.out test82.out + + SCRIPTS32 = test50.out test70.out + +--- 49,55 ---- + test42.out test52.out test65.out test66.out test67.out \ + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ +! test79.out test80.out test81.out test82.out test83.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.335/src/testdir/Make_os2.mak 2011-07-15 21:16:54.000000000 +0200 +--- src/testdir/Make_os2.mak 2011-10-12 17:39:03.000000000 +0200 +*************** +*** 29,35 **** + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out + + .SUFFIXES: .in .out + +--- 29,35 ---- + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out test83.out + + .SUFFIXES: .in .out + +*** ../vim-7.3.335/src/testdir/Make_vms.mms 2011-07-15 21:16:54.000000000 +0200 +--- src/testdir/Make_vms.mms 2011-10-12 17:39:03.000000000 +0200 +*************** +*** 76,82 **** + test66.out test67.out test68.out test69.out \ + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ +! test82.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +--- 76,82 ---- + test66.out test67.out test68.out test69.out \ + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ +! test82.out test83.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +*** ../vim-7.3.335/src/testdir/Makefile 2011-07-15 21:16:54.000000000 +0200 +--- src/testdir/Makefile 2011-10-12 17:39:03.000000000 +0200 +*************** +*** 26,32 **** + test64.out test65.out test66.out test67.out test68.out \ + test69.out test70.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ +! test79.out test80.out test81.out test82.out + + SCRIPTS_GUI = test16.out + +--- 26,32 ---- + test64.out test65.out test66.out test67.out test68.out \ + test69.out test70.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ +! test79.out test80.out test81.out test82.out test83.out + + SCRIPTS_GUI = test16.out + +*************** +*** 72,78 **** + fi \ + else echo $* NO OUTPUT >>test.log; \ + fi" +! -rm -rf X* test.ok viminfo + + test49.out: test49.vim + +--- 72,78 ---- + fi \ + else echo $* NO OUTPUT >>test.log; \ + fi" +! # -rm -rf X* test.ok viminfo + + test49.out: test49.vim + +*** ../vim-7.3.335/src/testdir/test83-tags2 2011-10-12 19:49:38.000000000 +0200 +--- src/testdir/test83-tags2 2011-10-12 19:34:15.000000000 +0200 +*************** +*** 0 **** +--- 1,2 ---- ++ !_TAG_FILE_ENCODING cp932 // ++ ‚`‚a‚b Xtags2.txt /‚`‚a‚b +*** ../vim-7.3.335/src/testdir/test83-tags3 2011-10-12 19:49:38.000000000 +0200 +--- src/testdir/test83-tags3 2011-10-12 19:35:42.000000000 +0200 +*************** +*** 0 **** +--- 1,102 ---- ++ !_TAG_FILE_SORTED 1 // ++ !_TAG_FILE_ENCODING cp932 // ++ abc1 Xtags3.txt /‚`‚a‚b ++ abc2 Xtags3.txt /‚`‚a‚b ++ abc3 Xtags3.txt /‚`‚a‚b ++ abc4 Xtags3.txt /‚`‚a‚b ++ abc5 Xtags3.txt /‚`‚a‚b ++ abc6 Xtags3.txt /‚`‚a‚b ++ abc7 Xtags3.txt /‚`‚a‚b ++ abc8 Xtags3.txt /‚`‚a‚b ++ abc9 Xtags3.txt /‚`‚a‚b ++ abc10 Xtags3.txt /‚`‚a‚b ++ abc11 Xtags3.txt /‚`‚a‚b ++ abc12 Xtags3.txt /‚`‚a‚b ++ abc13 Xtags3.txt /‚`‚a‚b ++ abc14 Xtags3.txt /‚`‚a‚b ++ abc15 Xtags3.txt /‚`‚a‚b ++ abc16 Xtags3.txt /‚`‚a‚b ++ abc17 Xtags3.txt /‚`‚a‚b ++ abc18 Xtags3.txt /‚`‚a‚b ++ abc19 Xtags3.txt /‚`‚a‚b ++ abc20 Xtags3.txt /‚`‚a‚b ++ abc21 Xtags3.txt /‚`‚a‚b ++ abc22 Xtags3.txt /‚`‚a‚b ++ abc23 Xtags3.txt /‚`‚a‚b ++ abc24 Xtags3.txt /‚`‚a‚b ++ abc25 Xtags3.txt /‚`‚a‚b ++ abc26 Xtags3.txt /‚`‚a‚b ++ abc27 Xtags3.txt /‚`‚a‚b ++ abc28 Xtags3.txt /‚`‚a‚b ++ abc29 Xtags3.txt /‚`‚a‚b ++ abc30 Xtags3.txt /‚`‚a‚b ++ abc31 Xtags3.txt /‚`‚a‚b ++ abc32 Xtags3.txt /‚`‚a‚b ++ abc33 Xtags3.txt /‚`‚a‚b ++ abc34 Xtags3.txt /‚`‚a‚b ++ abc35 Xtags3.txt /‚`‚a‚b ++ abc36 Xtags3.txt /‚`‚a‚b ++ abc37 Xtags3.txt /‚`‚a‚b ++ abc38 Xtags3.txt /‚`‚a‚b ++ abc39 Xtags3.txt /‚`‚a‚b ++ abc40 Xtags3.txt /‚`‚a‚b ++ abc41 Xtags3.txt /‚`‚a‚b ++ abc42 Xtags3.txt /‚`‚a‚b ++ abc43 Xtags3.txt /‚`‚a‚b ++ abc44 Xtags3.txt /‚`‚a‚b ++ abc45 Xtags3.txt /‚`‚a‚b ++ abc46 Xtags3.txt /‚`‚a‚b ++ abc47 Xtags3.txt /‚`‚a‚b ++ abc48 Xtags3.txt /‚`‚a‚b ++ abc49 Xtags3.txt /‚`‚a‚b ++ abc50 Xtags3.txt /‚`‚a‚b ++ abc51 Xtags3.txt /‚`‚a‚b ++ abc52 Xtags3.txt /‚`‚a‚b ++ abc53 Xtags3.txt /‚`‚a‚b ++ abc54 Xtags3.txt /‚`‚a‚b ++ abc55 Xtags3.txt /‚`‚a‚b ++ abc56 Xtags3.txt /‚`‚a‚b ++ abc57 Xtags3.txt /‚`‚a‚b ++ abc58 Xtags3.txt /‚`‚a‚b ++ abc59 Xtags3.txt /‚`‚a‚b ++ abc60 Xtags3.txt /‚`‚a‚b ++ abc61 Xtags3.txt /‚`‚a‚b ++ abc62 Xtags3.txt /‚`‚a‚b ++ abc63 Xtags3.txt /‚`‚a‚b ++ abc64 Xtags3.txt /‚`‚a‚b ++ abc65 Xtags3.txt /‚`‚a‚b ++ abc66 Xtags3.txt /‚`‚a‚b ++ abc67 Xtags3.txt /‚`‚a‚b ++ abc68 Xtags3.txt /‚`‚a‚b ++ abc69 Xtags3.txt /‚`‚a‚b ++ abc70 Xtags3.txt /‚`‚a‚b ++ abc71 Xtags3.txt /‚`‚a‚b ++ abc72 Xtags3.txt /‚`‚a‚b ++ abc73 Xtags3.txt /‚`‚a‚b ++ abc74 Xtags3.txt /‚`‚a‚b ++ abc75 Xtags3.txt /‚`‚a‚b ++ abc76 Xtags3.txt /‚`‚a‚b ++ abc77 Xtags3.txt /‚`‚a‚b ++ abc78 Xtags3.txt /‚`‚a‚b ++ abc79 Xtags3.txt /‚`‚a‚b ++ abc80 Xtags3.txt /‚`‚a‚b ++ abc81 Xtags3.txt /‚`‚a‚b ++ abc82 Xtags3.txt /‚`‚a‚b ++ abc83 Xtags3.txt /‚`‚a‚b ++ abc84 Xtags3.txt /‚`‚a‚b ++ abc85 Xtags3.txt /‚`‚a‚b ++ abc86 Xtags3.txt /‚`‚a‚b ++ abc87 Xtags3.txt /‚`‚a‚b ++ abc88 Xtags3.txt /‚`‚a‚b ++ abc89 Xtags3.txt /‚`‚a‚b ++ abc90 Xtags3.txt /‚`‚a‚b ++ abc91 Xtags3.txt /‚`‚a‚b ++ abc92 Xtags3.txt /‚`‚a‚b ++ abc93 Xtags3.txt /‚`‚a‚b ++ abc94 Xtags3.txt /‚`‚a‚b ++ abc95 Xtags3.txt /‚`‚a‚b ++ abc96 Xtags3.txt /‚`‚a‚b ++ abc97 Xtags3.txt /‚`‚a‚b ++ abc98 Xtags3.txt /‚`‚a‚b ++ abc99 Xtags3.txt /‚`‚a‚b ++ abc100 Xtags3.txt /‚`‚a‚b +*** ../vim-7.3.335/src/testdir/test83.in 2011-10-12 19:49:38.000000000 +0200 +--- src/testdir/test83.in 2011-10-12 19:40:47.000000000 +0200 +*************** +*** 0 **** +--- 1,76 ---- ++ Tests for tag search with !_TAG_FILE_ENCODING. ++ ++ STARTTEST ++ :so mbyte.vim ++ :if !has('iconv') ++ : e! test.ok ++ : w! test.out ++ : qa! ++ :endif ++ :set enc=utf8 ++ ++ :/^text for tags1$/,/^text for tags1$/+1w! Xtags1.txt ++ :/^text for tags2$/,/^text for tags2$/+1w! Xtags2.txt ++ :/^text for tags3$/,/^text for tags3$/+1w! Xtags3.txt ++ :/^tags1$/+1,/^tags1-end$/-1w! Xtags1 ++ ++ ggdG ++ ++ :call setline('.', 'Results of test83') ++ ++ :" case1: ++ :new ++ :set tags=Xtags1 ++ :let v:errmsg = '' ++ :tag abcdefghijklmnopqrs ++ :if v:errmsg =~ 'E426:' || getline('.') != 'abcdefghijklmnopqrs' ++ : close ++ : put ='case1: failed' ++ :else ++ : close ++ : put ='case1: ok' ++ :endif ++ ++ :" case2: ++ :new ++ :set tags=test83-tags2 ++ :let v:errmsg = '' ++ :tag /.BC ++ :if v:errmsg =~ 'E426:' || getline('.') != 'ABC' ++ : close ++ : put ='case2: failed' ++ :else ++ : close ++ : put ='case2: ok' ++ :endif ++ ++ :" case3: ++ :new ++ :set tags=test83-tags3 ++ :let v:errmsg = '' ++ :tag abc50 ++ :if v:errmsg =~ 'E426:' || getline('.') != 'ABC' ++ : close ++ : put ='case3: failed' ++ :else ++ : close ++ : put ='case3: ok' ++ :endif ++ :close ++ ++ :wq! test.out ++ ENDTEST ++ ++ text for tags1 ++ abcdefghijklmnopqrs ++ ++ text for tags2 ++ ABC ++ ++ text for tags3 ++ ABC ++ ++ tags1 ++ !_TAG_FILE_ENCODING utf-8 // ++ abcdefghijklmnopqrs Xtags1.txt /abcdefghijklmnopqrs ++ tags1-end +*** ../vim-7.3.335/src/testdir/test83.ok 2011-10-12 19:49:38.000000000 +0200 +--- src/testdir/test83.ok 2011-10-12 17:39:03.000000000 +0200 +*************** +*** 0 **** +--- 1,4 ---- ++ Results of test83 ++ case1: ok ++ case2: ok ++ case3: ok +*** ../vim-7.3.335/src/version.c 2011-10-12 16:57:07.000000000 +0200 +--- src/version.c 2011-10-12 19:45:46.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 336, + /**/ + + +-- +hundred-and-one symptoms of being an internet addict: +62. If your doorbell rings, you think that new mail has arrived. And then + you're disappointed that it's only someone at the door. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e3f5b956a92eaefff4c4e49544472978a4e366c8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:43 +0100 Subject: [PATCH 0055/3340] - patchlevel 337 --- 7.3.337 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.337 diff --git a/7.3.337 b/7.3.337 new file mode 100644 index 00000000..a2aeb04f --- /dev/null +++ b/7.3.337 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.337 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.337 (after 7.3.295) +Problem: Screen doesn't update after resizing the xterm until a character + is typed. +Solution: When the select call is interrupted check do_resize. (Taylor + Hedberg) +Files: src/os_unix.c + + +*** ../vim-7.3.336/src/os_unix.c 2011-09-08 23:24:09.000000000 +0200 +--- src/os_unix.c 2011-10-12 20:57:15.000000000 +0200 +*************** +*** 5146,5156 **** +--- 5146,5163 ---- + # endif + # ifdef EINTR + if (ret == -1 && errno == EINTR) ++ { ++ /* Check whether window has been resized, EINTR may be caused by ++ * SIGWINCH. */ ++ if (do_resize) ++ handle_resize(); ++ + /* Interrupted by a signal, need to try again. We ignore msec + * here, because we do want to check even after a timeout if + * characters are available. Needed for reading output of an + * external command after the process has finished. */ + goto select_eintr; ++ } + # endif + # ifdef __TANDEM + if (ret == -1 && errno == ENOTSUP) +*** ../vim-7.3.336/src/version.c 2011-10-12 19:53:31.000000000 +0200 +--- src/version.c 2011-10-12 21:03:47.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 337, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +64. The remote to the T.V. is missing...and you don't even care. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From af9cd0f6e2eb67fdd5290c2c6bb059c1ac638dc8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:43 +0100 Subject: [PATCH 0056/3340] - patchlevel 338 --- 7.3.338 | 100 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 100 insertions(+) create mode 100644 7.3.338 diff --git a/7.3.338 b/7.3.338 new file mode 100644 index 00000000..f273212a --- /dev/null +++ b/7.3.338 @@ -0,0 +1,100 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.338 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.338 +Problem: Using getchar() in an expression mapping doesn't work well. +Solution: Don't save and restore the typeahead. (James Vega) +Files: src/getchar.c, src/testdir/test34.ok + + +*** ../vim-7.3.337/src/getchar.c 2011-08-17 20:33:18.000000000 +0200 +--- src/getchar.c 2011-10-12 21:53:27.000000000 +0200 +*************** +*** 2460,2486 **** + + /* + * Handle ":map ": evaluate the {rhs} as an +! * expression. Save and restore the typeahead so that +! * getchar() can be used. Also save and restore the +! * command line for "normal :". + */ + if (mp->m_expr) + { +- tasave_T tabuf; + int save_vgetc_busy = vgetc_busy; + +! save_typeahead(&tabuf); +! if (tabuf.typebuf_valid) +! { +! vgetc_busy = 0; +! save_m_keys = vim_strsave(mp->m_keys); +! save_m_str = vim_strsave(mp->m_str); +! s = eval_map_expr(save_m_str, NUL); +! vgetc_busy = save_vgetc_busy; +! } +! else +! s = NULL; +! restore_typeahead(&tabuf); + } + else + #endif +--- 2460,2477 ---- + + /* + * Handle ":map ": evaluate the {rhs} as an +! * expression. Also save and restore the command line +! * for "normal :". + */ + if (mp->m_expr) + { + int save_vgetc_busy = vgetc_busy; + +! vgetc_busy = 0; +! save_m_keys = vim_strsave(mp->m_keys); +! save_m_str = vim_strsave(mp->m_str); +! s = eval_map_expr(save_m_str, NUL); +! vgetc_busy = save_vgetc_busy; + } + else + #endif +*** ../vim-7.3.337/src/testdir/test34.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test34.ok 2011-10-12 21:59:39.000000000 +0200 +*************** +*** 1,5 **** + xxx4asdf fail nop ok 9 333 +! XX111XX + ---222--- + 1. one + 2. two +--- 1,5 ---- + xxx4asdf fail nop ok 9 333 +! XX111-XX + ---222--- + 1. one + 2. two +*** ../vim-7.3.337/src/version.c 2011-10-12 21:04:15.000000000 +0200 +--- src/version.c 2011-10-12 21:20:31.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 338, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +65. The last time you looked at the clock it was 11:30pm, and in what + seems like only a few seconds later, your sister runs past you to + catch her 7am school bus. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 979ffb2be88c657c380fb511379cdadc15f86d45 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:43 +0100 Subject: [PATCH 0057/3340] - patchlevel 339 --- 7.3.339 | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 7.3.339 diff --git a/7.3.339 b/7.3.339 new file mode 100644 index 00000000..f108ad6e --- /dev/null +++ b/7.3.339 @@ -0,0 +1,57 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.339 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.339 +Problem: "make shadow" doesn't link all test files. +Solution: Add a line in Makefile and Filelist. +Files: src/Makefile, Filelist + + +*** ../vim-7.3.338/Filelist 2011-09-30 16:56:00.000000000 +0200 +--- Filelist 2011-10-16 14:00:42.000000000 +0200 +*************** +*** 81,86 **** +--- 81,87 ---- + src/testdir/test[0-9]*.ok \ + src/testdir/test49.vim \ + src/testdir/test60.vim \ ++ src/testdir/test83-tags? \ + src/proto.h \ + src/proto/blowfish.pro \ + src/proto/buffer.pro \ +*** ../vim-7.3.338/src/Makefile 2011-05-19 13:40:47.000000000 +0200 +--- src/Makefile 2011-10-16 13:59:40.000000000 +0200 +*************** +*** 2328,2333 **** +--- 2328,2334 ---- + ../../testdir/vimrc.unix \ + ../../testdir/*.in \ + ../../testdir/*.vim \ ++ ../../testdir/test83-tags? \ + ../../testdir/*.ok . + + # Link needed for doing "make install" in a shadow directory. +*** ../vim-7.3.338/src/version.c 2011-10-12 22:02:07.000000000 +0200 +--- src/version.c 2011-10-20 16:34:28.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 339, + /**/ + +-- +From "know your smileys": + :-O>-o Smiley American tourist (note big mouth and camera) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 20da593bd9ec840e2d6bf936cfdd87d6d0229c75 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:44 +0100 Subject: [PATCH 0058/3340] - patchlevel 340 --- 7.3.340 | 62 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 7.3.340 diff --git a/7.3.340 b/7.3.340 new file mode 100644 index 00000000..fb0b8423 --- /dev/null +++ b/7.3.340 @@ -0,0 +1,62 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.340 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.340 +Problem: When 'verbosefile' is set ftplugof.vim can give an error. +Solution: Only remove filetypeplugin autocommands when they exist. (Yasuhiro + Matsumoto) +Files: runtime/ftplugof.vim + + +*** ../vim-7.3.339/runtime/ftplugof.vim 2010-08-15 21:57:11.000000000 +0200 +--- runtime/ftplugof.vim 2011-10-20 16:51:00.000000000 +0200 +*************** +*** 1,11 **** + " Vim support file to switch off loading plugins for file types + " + " Maintainer: Bram Moolenaar +! " Last Change: 2002 Apr 04 + + if exists("did_load_ftplugin") + unlet did_load_ftplugin + endif + +! " Remove all autocommands in the filetypeplugin group +! silent! au! filetypeplugin * +--- 1,13 ---- + " Vim support file to switch off loading plugins for file types + " + " Maintainer: Bram Moolenaar +! " Last Change: 2011 Oct 20 + + if exists("did_load_ftplugin") + unlet did_load_ftplugin + endif + +! " Remove all autocommands in the filetypeplugin group, if any exist. +! if exists("#filetypeplugin") +! silent! au! filetypeplugin * +! endif +*** ../vim-7.3.339/src/version.c 2011-10-20 16:35:25.000000000 +0200 +--- src/version.c 2011-10-20 18:01:18.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 340, + /**/ + +-- +How many light bulbs does it take to change a person? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 53adffab25aed74b29c0308d1dc9adbe19d8a0e3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:44 +0100 Subject: [PATCH 0059/3340] - patchlevel 341 --- 7.3.341 | 360 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 360 insertions(+) create mode 100644 7.3.341 diff --git a/7.3.341 b/7.3.341 new file mode 100644 index 00000000..6ea38603 --- /dev/null +++ b/7.3.341 @@ -0,0 +1,360 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.341 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.341 +Problem: Local help files are only listed in help.txt, not in translated + help files. +Solution: Also find translated help files. (Yasuhiro Matsumoto) +Files: src/ex_cmds.c + + +*** ../vim-7.3.340/src/ex_cmds.c 2011-09-30 17:30:27.000000000 +0200 +--- src/ex_cmds.c 2011-10-20 17:39:45.000000000 +0200 +*************** +*** 5982,5987 **** +--- 5982,5988 ---- + char_u *line; + int in_example = FALSE; + int len; ++ char_u *fname; + char_u *p; + char_u *rt; + int mustfree; +*************** +*** 6028,6151 **** + } + + /* +! * In the "help.txt" file, add the locally added help files. +! * This uses the very first line in the help file. + */ +! if (fnamecmp(gettail(curbuf->b_fname), "help.txt") == 0) + { + for (lnum = 1; lnum < curbuf->b_ml.ml_line_count; ++lnum) + { + line = ml_get_buf(curbuf, lnum, FALSE); +! if (strstr((char *)line, "*local-additions*") != NULL) + { +! /* Go through all directories in 'runtimepath', skipping +! * $VIMRUNTIME. */ +! p = p_rtp; +! while (*p != NUL) + { +! copy_option_part(&p, NameBuff, MAXPATHL, ","); +! mustfree = FALSE; +! rt = vim_getenv((char_u *)"VIMRUNTIME", &mustfree); +! if (fullpathcmp(rt, NameBuff, FALSE) != FPC_SAME) +! { +! int fcount; +! char_u **fnames; +! FILE *fd; +! char_u *s; +! int fi; + #ifdef FEAT_MBYTE +! vimconv_T vc; +! char_u *cp; + #endif + +! /* Find all "doc/ *.txt" files in this directory. */ +! add_pathsep(NameBuff); +! STRCAT(NameBuff, "doc/*.txt"); +! if (gen_expand_wildcards(1, &NameBuff, &fcount, +! &fnames, EW_FILE|EW_SILENT) == OK +! && fcount > 0) + { +! for (fi = 0; fi < fcount; ++fi) + { +! fd = mch_fopen((char *)fnames[fi], "r"); +! if (fd != NULL) + { +! vim_fgets(IObuff, IOSIZE, fd); +! if (IObuff[0] == '*' +! && (s = vim_strchr(IObuff + 1, '*')) +! != NULL) +! { +! #ifdef FEAT_MBYTE +! int this_utf = MAYBE; + #endif +! /* Change tag definition to a +! * reference and remove /. */ +! IObuff[0] = '|'; +! *s = '|'; +! while (*s != NUL) +! { +! if (*s == '\r' || *s == '\n') +! *s = NUL; + #ifdef FEAT_MBYTE +! /* The text is utf-8 when a byte +! * above 127 is found and no +! * illegal byte sequence is found. +! */ +! if (*s >= 0x80 && this_utf != FALSE) +! { +! int l; +! +! this_utf = TRUE; +! l = utf_ptr2len(s); +! if (l == 1) +! this_utf = FALSE; +! s += l - 1; +! } + #endif +! ++s; +! } + #ifdef FEAT_MBYTE +! /* The help file is latin1 or utf-8; +! * conversion to the current +! * 'encoding' may be required. */ +! vc.vc_type = CONV_NONE; +! convert_setup(&vc, (char_u *)( +! this_utf == TRUE ? "utf-8" +! : "latin1"), p_enc); +! if (vc.vc_type == CONV_NONE) +! /* No conversion needed. */ +! cp = IObuff; +! else + { +! /* Do the conversion. If it fails +! * use the unconverted text. */ +! cp = string_convert(&vc, IObuff, +! NULL); +! if (cp == NULL) +! cp = IObuff; + } +! convert_setup(&vc, NULL, NULL); + +! ml_append(lnum, cp, (colnr_T)0, FALSE); +! if (cp != IObuff) +! vim_free(cp); + #else +! ml_append(lnum, IObuff, (colnr_T)0, +! FALSE); + #endif +! ++lnum; +! } +! fclose(fd); + } + } +- FreeWild(fcount, fnames); + } + } +- if (mustfree) +- vim_free(rt); + } +! break; + } + } + } + } +--- 6029,6215 ---- + } + + /* +! * In the "help.txt" and "help.abx" file, add the locally added help +! * files. This uses the very first line in the help file. + */ +! fname = gettail(curbuf->b_fname); +! if (fnamecmp(fname, "help.txt") == 0 +! #ifdef FEAT_MULTI_LANG +! || (fnamencmp(fname, "help.", 5) == 0 +! && ASCII_ISALPHA(fname[5]) +! && ASCII_ISALPHA(fname[6]) +! && TOLOWER_ASC(fname[7]) == 'x' +! && fname[8] == NUL) +! #endif +! ) + { + for (lnum = 1; lnum < curbuf->b_ml.ml_line_count; ++lnum) + { + line = ml_get_buf(curbuf, lnum, FALSE); +! if (strstr((char *)line, "*local-additions*") == NULL) +! continue; +! +! /* Go through all directories in 'runtimepath', skipping +! * $VIMRUNTIME. */ +! p = p_rtp; +! while (*p != NUL) + { +! copy_option_part(&p, NameBuff, MAXPATHL, ","); +! mustfree = FALSE; +! rt = vim_getenv((char_u *)"VIMRUNTIME", &mustfree); +! if (fullpathcmp(rt, NameBuff, FALSE) != FPC_SAME) + { +! int fcount; +! char_u **fnames; +! FILE *fd; +! char_u *s; +! int fi; + #ifdef FEAT_MBYTE +! vimconv_T vc; +! char_u *cp; + #endif + +! /* Find all "doc/ *.txt" files in this directory. */ +! add_pathsep(NameBuff); +! #ifdef FEAT_MULTI_LANG +! STRCAT(NameBuff, "doc/*.??[tx]"); +! #else +! STRCAT(NameBuff, "doc/*.txt"); +! #endif +! if (gen_expand_wildcards(1, &NameBuff, &fcount, +! &fnames, EW_FILE|EW_SILENT) == OK +! && fcount > 0) +! { +! #ifdef FEAT_MULTI_LANG +! int i1; +! int i2; +! char_u *f1; +! char_u *f2; +! char_u *t1; +! char_u *e1; +! char_u *e2; +! +! /* If foo.abx is found use it instead of foo.txt in +! * the same directory. */ +! for (i1 = 0; i1 < fcount; ++i1) + { +! for (i2 = 0; i2 < fcount; ++i2) + { +! if (i1 == i2) +! continue; +! if (fnames[i1] == NULL || fnames[i2] == NULL) +! continue; +! f1 = fnames[i1]; +! f2 = fnames[i2]; +! t1 = gettail(f1); +! if (fnamencmp(f1, f2, t1 - f1) != 0) +! continue; +! e1 = vim_strrchr(t1, '.'); +! e2 = vim_strrchr(gettail(f2), '.'); +! if (e1 == NUL || e2 == NUL) +! continue; +! if (fnamecmp(e1, ".txt") != 0 +! && fnamecmp(e1, fname + 4) != 0) + { +! /* Not .txt and not .abx, remove it. */ +! vim_free(fnames[i1]); +! fnames[i1] = NULL; +! continue; +! } +! if (fnamencmp(f1, f2, e1 - f1) != 0) +! continue; +! if (fnamecmp(e1, ".txt") == 0 +! && fnamecmp(e2, fname + 4) == 0) +! { +! /* use .abx instead of .txt */ +! vim_free(fnames[i1]); +! fnames[i1] = NULL; +! } +! } +! } + #endif +! for (fi = 0; fi < fcount; ++fi) +! { +! if (fnames[fi] == NULL) +! continue; +! fd = mch_fopen((char *)fnames[fi], "r"); +! if (fd != NULL) +! { +! vim_fgets(IObuff, IOSIZE, fd); +! if (IObuff[0] == '*' +! && (s = vim_strchr(IObuff + 1, '*')) +! != NULL) +! { + #ifdef FEAT_MBYTE +! int this_utf = MAYBE; + #endif +! /* Change tag definition to a +! * reference and remove /. */ +! IObuff[0] = '|'; +! *s = '|'; +! while (*s != NUL) +! { +! if (*s == '\r' || *s == '\n') +! *s = NUL; + #ifdef FEAT_MBYTE +! /* The text is utf-8 when a byte +! * above 127 is found and no +! * illegal byte sequence is found. +! */ +! if (*s >= 0x80 && this_utf != FALSE) + { +! int l; +! +! this_utf = TRUE; +! l = utf_ptr2len(s); +! if (l == 1) +! this_utf = FALSE; +! s += l - 1; + } +! #endif +! ++s; +! } +! #ifdef FEAT_MBYTE +! /* The help file is latin1 or utf-8; +! * conversion to the current +! * 'encoding' may be required. */ +! vc.vc_type = CONV_NONE; +! convert_setup(&vc, (char_u *)( +! this_utf == TRUE ? "utf-8" +! : "latin1"), p_enc); +! if (vc.vc_type == CONV_NONE) +! /* No conversion needed. */ +! cp = IObuff; +! else +! { +! /* Do the conversion. If it fails +! * use the unconverted text. */ +! cp = string_convert(&vc, IObuff, +! NULL); +! if (cp == NULL) +! cp = IObuff; +! } +! convert_setup(&vc, NULL, NULL); + +! ml_append(lnum, cp, (colnr_T)0, FALSE); +! if (cp != IObuff) +! vim_free(cp); + #else +! ml_append(lnum, IObuff, (colnr_T)0, +! FALSE); + #endif +! ++lnum; + } ++ fclose(fd); + } + } ++ FreeWild(fcount, fnames); + } + } +! if (mustfree) +! vim_free(rt); + } ++ break; + } + } + } +*** ../vim-7.3.340/src/version.c 2011-10-20 18:12:27.000000000 +0200 +--- src/version.c 2011-10-20 18:13:46.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 341, + /**/ + +-- +From "know your smileys": + :-)-O Smiling doctor with stethoscope + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bd56983132c9d6949814e4ddb198c8f06656dbf9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:44 +0100 Subject: [PATCH 0060/3340] - patchlevel 342 --- 7.3.342 | 93 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 93 insertions(+) create mode 100644 7.3.342 diff --git a/7.3.342 b/7.3.342 new file mode 100644 index 00000000..2deb7e38 --- /dev/null +++ b/7.3.342 @@ -0,0 +1,93 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.342 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.342 +Problem: Code not in Vim style. +Solution: Fix the style. (Elias Diem) +Files: src/os_amiga.c, src/os_mac_conv.c, src/os_win16.c + + +*** ../vim-7.3.341/src/os_amiga.c 2010-08-15 21:57:27.000000000 +0200 +--- src/os_amiga.c 2011-10-20 18:19:45.000000000 +0200 +*************** +*** 1022,1028 **** + + /* insure longword alignment */ + #ifdef __amigaos4__ +! if(!(id = AllocDosObject(DOS_INFODATA, 0))) + goto out; + #else + id = (struct InfoData *)(((long)id_a + 3L) & ~3L); +--- 1022,1028 ---- + + /* insure longword alignment */ + #ifdef __amigaos4__ +! if (!(id = AllocDosObject(DOS_INFODATA, 0))) + goto out; + #else + id = (struct InfoData *)(((long)id_a + 3L) & ~3L); +*** ../vim-7.3.341/src/os_mac_conv.c 2011-06-13 02:03:55.000000000 +0200 +--- src/os_mac_conv.c 2011-10-20 18:19:45.000000000 +0200 +*************** +*** 77,83 **** + *unconvlenp = 0; + cfstr = CFStringCreateWithBytes(NULL, ptr, len, from, 0); + +! if(cfstr == NULL) + fprintf(stderr, "Encoding failed\n"); + /* When conversion failed, try excluding bytes from the end, helps when + * there is an incomplete byte sequence. Only do up to 6 bytes to avoid +--- 77,83 ---- + *unconvlenp = 0; + cfstr = CFStringCreateWithBytes(NULL, ptr, len, from, 0); + +! if (cfstr == NULL) + fprintf(stderr, "Encoding failed\n"); + /* When conversion failed, try excluding bytes from the end, helps when + * there is an incomplete byte sequence. Only do up to 6 bytes to avoid +*** ../vim-7.3.341/src/os_win16.c 2010-12-17 20:23:56.000000000 +0100 +--- src/os_win16.c 2011-10-20 18:19:45.000000000 +0200 +*************** +*** 243,251 **** + /* Wait for the command to terminate before continuing */ + while (GetModuleUsage((HINSTANCE)h_module) > 0 && again ) + { +! while( PeekMessage( &msg, NULL, 0, 0, PM_REMOVE ) && again ) + { +! if(msg.message == WM_QUIT) + + { + PostQuitMessage(msg.wParam); +--- 243,251 ---- + /* Wait for the command to terminate before continuing */ + while (GetModuleUsage((HINSTANCE)h_module) > 0 && again ) + { +! while (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE) && again) + { +! if (msg.message == WM_QUIT) + + { + PostQuitMessage(msg.wParam); +*** ../vim-7.3.341/src/version.c 2011-10-20 18:17:38.000000000 +0200 +--- src/version.c 2011-10-20 18:21:43.000000000 +0200 +*************** +*** 711,712 **** +--- 711,714 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 342, + /**/ + +-- +You are only young once, but you can stay immature indefinitely. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4f05e0cb7c6e97c551f2a665bdfc3e7e5a52c530 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:45 +0100 Subject: [PATCH 0061/3340] - patchlevel 343 --- 7.3.343 | 252 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 252 insertions(+) create mode 100644 7.3.343 diff --git a/7.3.343 b/7.3.343 new file mode 100644 index 00000000..db62264d --- /dev/null +++ b/7.3.343 @@ -0,0 +1,252 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.343 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.343 +Problem: No mouse support for urxvt. +Solution: Implement urxvt mouse support, also for > 252 columns. (Yiding + Jia) +Files: src/feature.h, src/keymap.h, src/option.h, src/os_unix.c, + src/term.c, src/version.c + + +*** ../vim-7.3.342/src/feature.h 2011-05-19 13:40:47.000000000 +0200 +--- src/feature.h 2011-10-20 21:02:15.000000000 +0200 +*************** +*** 1053,1058 **** +--- 1053,1061 ---- + # ifdef FEAT_BIG + # define FEAT_MOUSE_DEC + # endif ++ # ifdef FEAT_BIG ++ # define FEAT_MOUSE_URXVT ++ # endif + # if defined(FEAT_NORMAL) && (defined(MSDOS) || defined(WIN3264)) + # define DOS_MOUSE + # endif +*************** +*** 1068,1080 **** + #if defined(FEAT_NORMAL) && defined(HAVE_SYSMOUSE) + # define FEAT_SYSMOUSE + #endif + /* Define FEAT_MOUSE when any of the above is defined or FEAT_GUI. */ + #if !defined(FEAT_MOUSE_TTY) \ + && (defined(FEAT_MOUSE_XTERM) \ +! || defined(FEAT_MOUSE_NET) || defined(FEAT_MOUSE_DEC) \ +! || defined(DOS_MOUSE) || defined(FEAT_MOUSE_GPM) \ +! || defined(FEAT_MOUSE_JSB) || defined(FEAT_MOUSE_PTERM) \ +! || defined(FEAT_SYSMOUSE)) + # define FEAT_MOUSE_TTY /* include non-GUI mouse support */ + #endif + #if !defined(FEAT_MOUSE) && (defined(FEAT_MOUSE_TTY) || defined(FEAT_GUI)) +--- 1071,1093 ---- + #if defined(FEAT_NORMAL) && defined(HAVE_SYSMOUSE) + # define FEAT_SYSMOUSE + #endif ++ ++ /* urxvt is a small variation of mouse_xterm, and shares its code */ ++ #if defined(FEAT_MOUSE_URXVT) && !defined(FEAT_MOUSE_XTERM) ++ # define FEAT_MOUSE_XTERM ++ #endif ++ + /* Define FEAT_MOUSE when any of the above is defined or FEAT_GUI. */ + #if !defined(FEAT_MOUSE_TTY) \ + && (defined(FEAT_MOUSE_XTERM) \ +! || defined(FEAT_MOUSE_NET) \ +! || defined(FEAT_MOUSE_DEC) \ +! || defined(DOS_MOUSE) \ +! || defined(FEAT_MOUSE_GPM) \ +! || defined(FEAT_MOUSE_JSB) \ +! || defined(FEAT_MOUSE_PTERM) \ +! || defined(FEAT_SYSMOUSE) \ +! || defined(FEAT_MOUSE_URXVT)) + # define FEAT_MOUSE_TTY /* include non-GUI mouse support */ + #endif + #if !defined(FEAT_MOUSE) && (defined(FEAT_MOUSE_TTY) || defined(FEAT_GUI)) +*** ../vim-7.3.342/src/keymap.h 2010-08-15 21:57:32.000000000 +0200 +--- src/keymap.h 2011-10-20 21:00:37.000000000 +0200 +*************** +*** 92,104 **** + */ + #define KS_TEAROFF 244 + +! /* used for JSB term mouse */ + #define KS_JSBTERM_MOUSE 243 + +! /* used a termcap entry that produces a normal character */ + #define KS_KEY 242 + +! /* Used for the qnx pterm mouse */ + #define KS_PTERM_MOUSE 241 + + /* Used for click in a tab pages label. */ +--- 92,104 ---- + */ + #define KS_TEAROFF 244 + +! /* Used for JSB term mouse. */ + #define KS_JSBTERM_MOUSE 243 + +! /* Used a termcap entry that produces a normal character. */ + #define KS_KEY 242 + +! /* Used for the qnx pterm mouse. */ + #define KS_PTERM_MOUSE 241 + + /* Used for click in a tab pages label. */ +*************** +*** 107,112 **** +--- 107,115 ---- + /* Used for menu in a tab pages line. */ + #define KS_TABMENU 239 + ++ /* Used for the urxvt mouse. */ ++ #define KS_URXVT_MOUSE 238 ++ + /* + * Filler used after KS_SPECIAL and others + */ +*** ../vim-7.3.342/src/option.h 2011-09-30 14:44:49.000000000 +0200 +--- src/option.h 2011-10-20 19:38:59.000000000 +0200 +*************** +*** 819,825 **** + EXTERN char_u *p_ttym; /* 'ttymouse' */ + EXTERN unsigned ttym_flags; + # ifdef IN_OPTION_C +! static char *(p_ttym_values[]) = {"xterm", "xterm2", "dec", "netterm", "jsbterm", "pterm", NULL}; + # endif + # define TTYM_XTERM 0x01 + # define TTYM_XTERM2 0x02 +--- 819,825 ---- + EXTERN char_u *p_ttym; /* 'ttymouse' */ + EXTERN unsigned ttym_flags; + # ifdef IN_OPTION_C +! static char *(p_ttym_values[]) = {"xterm", "xterm2", "dec", "netterm", "jsbterm", "pterm", "urxvt", NULL}; + # endif + # define TTYM_XTERM 0x01 + # define TTYM_XTERM2 0x02 +*************** +*** 827,832 **** +--- 827,833 ---- + # define TTYM_NETTERM 0x08 + # define TTYM_JSBTERM 0x10 + # define TTYM_PTERM 0x20 ++ # define TTYM_URXVT 0x40 + #endif + EXTERN char_u *p_udir; /* 'undodir' */ + EXTERN long p_ul; /* 'undolevels' */ +*** ../vim-7.3.342/src/os_unix.c 2011-10-12 21:04:15.000000000 +0200 +--- src/os_unix.c 2011-10-20 21:02:00.000000000 +0200 +*************** +*** 2158,2167 **** +--- 2158,2170 ---- + * Return non-zero when using an xterm mouse, according to 'ttymouse'. + * Return 1 for "xterm". + * Return 2 for "xterm2". ++ * Return 3 for "urxvt". + */ + int + use_xterm_mouse() + { ++ if (ttym_flags == TTYM_URXVT) ++ return 3; + if (ttym_flags == TTYM_XTERM2) + return 2; + if (ttym_flags == TTYM_XTERM) +*************** +*** 3318,3323 **** +--- 3321,3337 ---- + return; + + xterm_mouse_vers = use_xterm_mouse(); ++ ++ # ifdef FEAT_MOUSE_URXVT ++ if (ttym_flags == TTYM_URXVT) { ++ out_str_nf((char_u *) ++ (on ++ ? IF_EB("\033[?1015h", ESC_STR "[?1015h") ++ : IF_EB("\033[?1015l", ESC_STR "[?1015l"))); ++ ison = on; ++ } ++ # endif ++ + if (xterm_mouse_vers > 0) + { + if (on) /* enable mouse events, use mouse tracking if available */ +*************** +*** 3434,3439 **** +--- 3448,3456 ---- + { + # ifdef FEAT_MOUSE_XTERM + if (use_xterm_mouse() ++ # ifdef FEAT_MOUSE_URXVT ++ && use_xterm_mouse() != 3 ++ # endif + # ifdef FEAT_GUI + && !gui.in_use + # endif +*************** +*** 3523,3528 **** +--- 3540,3566 ---- + else + del_mouse_termcode(KS_PTERM_MOUSE); + # endif ++ # ifdef FEAT_MOUSE_URXVT ++ /* same as the dec mouse */ ++ if (use_xterm_mouse() == 3 ++ # ifdef FEAT_GUI ++ && !gui.in_use ++ # endif ++ ) ++ { ++ set_mouse_termcode(KS_URXVT_MOUSE, (char_u *)(term_is_8bit(T_NAME) ++ ? IF_EB("\233", CSI_STR) ++ : IF_EB("\033[", ESC_STR "["))); ++ ++ if (*p_mouse != NUL) ++ { ++ mch_setmouse(FALSE); ++ setmouse(); ++ } ++ } ++ else ++ del_mouse_termcode(KS_URXVT_MOUSE); ++ # endif + } + #endif + +*** ../vim-7.3.342/src/version.c 2011-10-20 18:24:16.000000000 +0200 +--- src/version.c 2011-10-20 19:40:48.000000000 +0200 +*************** +*** 380,383 **** +--- 380,388 ---- + "-mouse_xterm", + # endif ++ # ifdef FEAT_MOUSE_URXVT ++ "+mouse_urxvt", ++ # else ++ "-mouse_urxvt", ++ # endif + #endif + #ifdef __QNX__ +*************** +*** 711,712 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 343, + /**/ + +-- +Warning label on a superhero Halloween costume: +"Caution: Cape does not enable user to fly." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 47277ee72f5021acfab9d1a94ceeca08e3e282e1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:45 +0100 Subject: [PATCH 0062/3340] - patchlevel 344 --- 7.3.344 | 121 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 121 insertions(+) create mode 100644 7.3.344 diff --git a/7.3.344 b/7.3.344 new file mode 100644 index 00000000..d2bb1dbe --- /dev/null +++ b/7.3.344 @@ -0,0 +1,121 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.344 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.344 +Problem: Problem with GUI startup related to XInitThreads. +Solution: Use read() and write() instead of fputs() and fread(). (James + Vega) +Files: src/gui.c + + +*** ../vim-7.3.343/src/gui.c 2011-09-14 19:04:35.000000000 +0200 +--- src/gui.c 2011-10-20 21:23:43.000000000 +0200 +*************** +*** 212,218 **** + int status; + int exit_status; + pid_t pid = -1; +- FILE *parent_file; + + /* Setup a pipe between the child and the parent, so that the parent + * knows when the child has done the setsid() call and is allowed to +--- 212,217 ---- +*************** +*** 290,308 **** + gui_mch_forked(); + # endif + +- if (!pipe_error) +- parent_file = fdopen(pipefd[1], "w"); +- else +- parent_file = NULL; +- + /* Try to start the GUI */ + gui_attempt_start(); + + /* Notify the parent */ +! if (parent_file != NULL) + { +! fputs(gui.in_use ? "ok" : "fail", parent_file); +! fclose(parent_file); + } + + /* If we failed to start the GUI, exit now. */ +--- 289,305 ---- + gui_mch_forked(); + # endif + + /* Try to start the GUI */ + gui_attempt_start(); + + /* Notify the parent */ +! if (!pipe_error) + { +! if (gui.in_use) +! write_eintr(pipefd[1], "ok", 3); +! else +! write_eintr(pipefd[1], "fail", 5); +! close(pipefd[1]); + } + + /* If we failed to start the GUI, exit now. */ +*************** +*** 323,339 **** + static int + gui_read_child_pipe(int fd) + { +! size_t bytes_read; +! FILE *file; +! char buffer[10]; +! +! file = fdopen(fd, "r"); +! if (!file) + return GUI_CHILD_IO_ERROR; +! +! bytes_read = fread(buffer, sizeof(char), sizeof(buffer)-1, file); +! buffer[bytes_read] = '\0'; +! fclose(file); + if (strcmp(buffer, "ok") == 0) + return GUI_CHILD_OK; + return GUI_CHILD_FAILED; +--- 320,335 ---- + static int + gui_read_child_pipe(int fd) + { +! long bytes_read; +! #define READ_BUFFER_SIZE 10 +! char buffer[READ_BUFFER_SIZE]; +! +! bytes_read = read_eintr(fd, buffer, READ_BUFFER_SIZE - 1); +! #undef READ_BUFFER_SIZE +! close(fd); +! if (bytes_read < 0) + return GUI_CHILD_IO_ERROR; +! buffer[bytes_read] = NUL; + if (strcmp(buffer, "ok") == 0) + return GUI_CHILD_OK; + return GUI_CHILD_FAILED; +*** ../vim-7.3.343/src/version.c 2011-10-20 21:09:25.000000000 +0200 +--- src/version.c 2011-10-20 21:27:31.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 344, + /**/ + +-- +From "know your smileys": + *<|:-) Santa Claus (Ho Ho Ho) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6c944f62a3fbf14208e83d5d7dff6e231e20918d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:45 +0100 Subject: [PATCH 0063/3340] - patchlevel 345 --- 7.3.345 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.345 diff --git a/7.3.345 b/7.3.345 new file mode 100644 index 00000000..99dd074a --- /dev/null +++ b/7.3.345 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.345 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.345 +Problem: When switching language with ":lang" the window title doesn't + change until later. +Solution: Update the window title right away. (Dominique Pelle) +Files: src/ex_cmds2.c + + +*** ../vim-7.3.344/src/ex_cmds2.c 2011-06-26 04:25:24.000000000 +0200 +--- src/ex_cmds2.c 2011-10-20 21:31:09.000000000 +0200 +*************** +*** 4154,4159 **** +--- 4154,4162 ---- + /* Set v:lang, v:lc_time and v:ctype to the final result. */ + set_lang_var(); + # endif ++ # ifdef FEAT_TITLE ++ maketitle(); ++ # endif + } + } + } +*** ../vim-7.3.344/src/version.c 2011-10-20 21:27:57.000000000 +0200 +--- src/version.c 2011-10-20 21:38:32.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 345, + /**/ + +-- +You can't have everything. Where would you put it? + -- Steven Wright + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 311f59ad9245a9faf71642792156c3683cfe312f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:46 +0100 Subject: [PATCH 0064/3340] - patchlevel 346 --- 7.3.346 | 143 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 143 insertions(+) create mode 100644 7.3.346 diff --git a/7.3.346 b/7.3.346 new file mode 100644 index 00000000..e6b1a2b6 --- /dev/null +++ b/7.3.346 @@ -0,0 +1,143 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.346 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.346 +Problem: It's hard to test netbeans commands. +Solution: Process netbeans commands after :sleep. (Xavier de Gaye) +Files: runtime/doc/netbeans.txt, src/ex_docmd.c, src/netbeans.c + + +*** ../vim-7.3.345/runtime/doc/netbeans.txt 2010-09-29 17:26:57.000000000 +0200 +--- runtime/doc/netbeans.txt 2011-10-20 21:51:41.000000000 +0200 +*************** +*** 1,4 **** +! *netbeans.txt* For Vim version 7.3. Last change: 2010 Aug 20 + + + VIM REFERENCE MANUAL by Gordon Prieur et al. +--- 1,4 ---- +! *netbeans.txt* For Vim version 7.3. Last change: 2011 Oct 20 + + + VIM REFERENCE MANUAL by Gordon Prieur et al. +*************** +*** 263,268 **** +--- 263,274 ---- + plain UTF-8 text this protocol could also be used with any other communication + mechanism. + ++ Netbeans messages are processed when Vim is idle, waiting for user input. ++ When Vim is run in non-interactive mode, for example when running an automated ++ test case that sources a Vim script, the idle loop may not be called often ++ enough. In that case, insert |sleep| commands in the Vim script. The |sleep| ++ command does invoke Netbeans messages processing. ++ + 6.1 Kinds of messages |nb-messages| + 6.2 Terms |nb-terms| + 6.3 Commands |nb-commands| +*************** +*** 820,826 **** + ============================================================================== + 7. NetBeans commands *netbeans-commands* + +! *:nbstart* *E511* + :nbs[tart] {connection} Start a new Netbeans session with {connection} as the + socket connection parameters. The format of + {connection} is described in |netbeans-parameters|. +--- 826,832 ---- + ============================================================================== + 7. NetBeans commands *netbeans-commands* + +! *:nbstart* *E511* *E838* + :nbs[tart] {connection} Start a new Netbeans session with {connection} as the + socket connection parameters. The format of + {connection} is described in |netbeans-parameters|. +*************** +*** 833,843 **** + signs. + + *:nbkey* +! :nb[key] {key} Pass the {key} to the Vim Controller for processing +! +! When a hot-key has been installed with the specialKeys command, this command +! can be used to generate a hotkey messages to the Vim Controller. The events +! newDotAndMark, keyCommand and keyAtPos are generated (in this order). + + + ============================================================================== +--- 839,854 ---- + signs. + + *:nbkey* +! :nb[key] {key} Pass the {key} to the Vim Controller for processing. +! When a hot-key has been installed with the specialKeys +! command, this command can be used to generate a hotkey +! message to the Vim Controller. +! This command can also be used to pass any text to the +! Vim Controller. It is used by Pyclewn, for example, +! to build the complete set of gdb commands as Vim user +! commands. +! The events newDotAndMark, keyCommand and keyAtPos are +! generated (in this order). + + + ============================================================================== +*** ../vim-7.3.345/src/ex_docmd.c 2011-09-30 18:35:49.000000000 +0200 +--- src/ex_docmd.c 2011-10-20 21:50:06.000000000 +0200 +*************** +*** 8205,8210 **** +--- 8205,8216 ---- + { + ui_delay(msec - done > 1000L ? 1000L : msec - done, TRUE); + ui_breakcheck(); ++ #ifdef FEAT_NETBEANS_INTG ++ /* Process the netbeans messages that may have been received in the ++ * call to ui_breakcheck() when the GUI is in use. This may occur when ++ * running a test case. */ ++ netbeans_parse_messages(); ++ #endif + } + } + +*** ../vim-7.3.345/src/netbeans.c 2011-04-11 21:35:03.000000000 +0200 +--- src/netbeans.c 2011-10-20 21:47:17.000000000 +0200 +*************** +*** 14,19 **** +--- 14,26 ---- + * which are *between* characters, whereas vim uses line number + * and column number which are *on* characters. + * See ":help netbeans-protocol" for explanation. ++ * ++ * The Netbeans messages are received and queued in the gui event loop, or in ++ * the select loop when Vim runs in a terminal. These messages are processed ++ * by netbeans_parse_messages() which is invoked in the idle loop when Vim is ++ * waiting for user input. The function netbeans_parse_messages() is also ++ * called from the ":sleep" command, to allow the execution of test cases that ++ * may not invoke the idle loop. + */ + + #include "vim.h" +*** ../vim-7.3.345/src/version.c 2011-10-20 21:57:43.000000000 +0200 +--- src/version.c 2011-10-20 21:50:23.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 346, + /**/ + +-- +From "know your smileys": + ...---... SOS + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8fc669a0ffd8b433a191536bf93488059a0e37f6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:46 +0100 Subject: [PATCH 0065/3340] - patchlevel 347 --- 7.3.347 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 7.3.347 diff --git a/7.3.347 b/7.3.347 new file mode 100644 index 00000000..85b0feb7 --- /dev/null +++ b/7.3.347 @@ -0,0 +1,54 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.347 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.347 +Problem: When dropping text from a browser on Vim it receives HTML even + though "html" is excluded from 'clipboard'. (Andrei Avk) +Solution: Fix the condition for TARGET_HTML. +Files: src/gui_gtk_x11.c + + +*** ../vim-7.3.346/src/gui_gtk_x11.c 2011-08-10 17:44:41.000000000 +0200 +--- src/gui_gtk_x11.c 2011-10-23 20:56:38.000000000 +0200 +*************** +*** 3081,3087 **** + + for (i = 0; i < (int)N_DND_TARGETS; ++i) + { +! if (!clip_html && selection_targets[i].info == TARGET_HTML) + n_targets--; + else + targets[j++] = dnd_targets[i]; +--- 3081,3087 ---- + + for (i = 0; i < (int)N_DND_TARGETS; ++i) + { +! if (!clip_html && dnd_targets[i].info == TARGET_HTML) + n_targets--; + else + targets[j++] = dnd_targets[i]; +*** ../vim-7.3.346/src/version.c 2011-10-20 21:58:20.000000000 +0200 +--- src/version.c 2011-10-26 11:35:23.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 347, + /**/ + +-- +I AM THANKFUL... +...for a lawn that needs mowing, windows that need cleaning +and gutters that need fixing because it means I have a home. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5ba89bebe6496c0474d3f34bd199ed913b418474 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:47 +0100 Subject: [PATCH 0066/3340] - patchlevel 348 --- 7.3.348 | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 7.3.348 diff --git a/7.3.348 b/7.3.348 new file mode 100644 index 00000000..e92febb9 --- /dev/null +++ b/7.3.348 @@ -0,0 +1,57 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.348 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.348 +Problem: "call range(1, 947948399)" causes a crash. (ZyX) +Solution: Avoid a loop in the out of memory message. +Files: src/misc2.c + + +*** ../vim-7.3.347/src/misc2.c 2011-08-19 22:28:58.000000000 +0200 +--- src/misc2.c 2011-10-26 11:17:26.000000000 +0200 +*************** +*** 1012,1019 **** + { + /* Don't hide this message */ + emsg_silent = 0; +! EMSGN(_("E342: Out of memory! (allocating %lu bytes)"), size); + did_outofmem_msg = TRUE; + } + } + +--- 1012,1023 ---- + { + /* Don't hide this message */ + emsg_silent = 0; +! +! /* Must come first to avoid coming back here when printing the error +! * message fails, e.g. when setting v:errmsg. */ + did_outofmem_msg = TRUE; ++ ++ EMSGN(_("E342: Out of memory! (allocating %lu bytes)"), size); + } + } + +*** ../vim-7.3.347/src/version.c 2011-10-26 11:36:21.000000000 +0200 +--- src/version.c 2011-10-26 11:38:33.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 348, + /**/ + +-- +A fool learns from his mistakes, a wise man from someone else's. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ffc5796f96dd0d47f9b614b6300824b87bebd09e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:47 +0100 Subject: [PATCH 0067/3340] - patchlevel 349 --- 7.3.349 | 88 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 88 insertions(+) create mode 100644 7.3.349 diff --git a/7.3.349 b/7.3.349 new file mode 100644 index 00000000..ac519afe --- /dev/null +++ b/7.3.349 @@ -0,0 +1,88 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.349 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.349 +Problem: When running out of memory during startup trying to open a + swapfile will loop forever. +Solution: Let findswapname() set dirp to NULL if out of memory. +Files: src/memline.c + + +*** ../vim-7.3.348/src/memline.c 2011-06-13 01:07:22.000000000 +0200 +--- src/memline.c 2011-10-26 11:26:06.000000000 +0200 +*************** +*** 621,626 **** +--- 621,628 ---- + break; + fname = findswapname(buf, &dirp, mfp->mf_fname); + /* alloc's fname */ ++ if (dirp == NULL) /* out of memory */ ++ break; + if (fname == NULL) /* no file name found for this dir */ + continue; + +*************** +*** 744,749 **** +--- 746,753 ---- + * and creating it, another Vim creates the file. In that case the + * creation will fail and we will use another directory. */ + fname = findswapname(buf, &dirp, NULL); /* allocates fname */ ++ if (dirp == NULL) ++ break; /* out of memory */ + if (fname == NULL) + continue; + if (mf_open_file(mfp, fname) == OK) /* consumes fname! */ +*************** +*** 4114,4119 **** +--- 4118,4124 ---- + * + * Several names are tried to find one that does not exist + * Returns the name in allocated memory or NULL. ++ * When out of memory "dirp" is set to NULL. + * + * Note: If BASENAMELEN is not correct, you will get error messages for + * not being able to open the swap or undo file +*************** +*** 4157,4163 **** + * First allocate some memory to put the directory name in. + */ + dir_name = alloc((unsigned)STRLEN(*dirp) + 1); +! if (dir_name != NULL) + (void)copy_option_part(dirp, dir_name, 31000, ","); + + /* +--- 4162,4170 ---- + * First allocate some memory to put the directory name in. + */ + dir_name = alloc((unsigned)STRLEN(*dirp) + 1); +! if (dir_name == NULL) +! *dirp = NULL; +! else + (void)copy_option_part(dirp, dir_name, 31000, ","); + + /* +*** ../vim-7.3.348/src/version.c 2011-10-26 11:40:56.000000000 +0200 +--- src/version.c 2011-10-26 11:43:05.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 349, + /**/ + +-- +I AM THANKFUL... +...for all the complaining I hear about the government +because it means we have freedom of speech. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8761921240f00dae34195d3e383e83471f0df4a5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:47 +0100 Subject: [PATCH 0068/3340] - patchlevel 350 --- 7.3.350 | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 7.3.350 diff --git a/7.3.350 b/7.3.350 new file mode 100644 index 00000000..5a1f3327 --- /dev/null +++ b/7.3.350 @@ -0,0 +1,46 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.350 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.350 +Problem: Block of code after ":lua << EOF" may not work. (Paul Isambert) +Solution: Recognize the ":lua" command, skip to EOF. +Files: src/eval.c + + +*** ../vim-7.3.349/src/eval.c 2011-09-30 18:35:49.000000000 +0200 +--- src/eval.c 2011-10-26 13:12:06.000000000 +0200 +*************** +*** 20899,20904 **** +--- 20899,20906 ---- + && (!ASCII_ISALPHA(p[2]) || p[2] == 'r')) + || (p[0] == 't' && p[1] == 'c' + && (!ASCII_ISALPHA(p[2]) || p[2] == 'l')) ++ || (p[0] == 'l' && p[1] == 'u' && p[2] == 'a' ++ && !ASCII_ISALPHA(p[3])) + || (p[0] == 'r' && p[1] == 'u' && p[2] == 'b' + && (!ASCII_ISALPHA(p[3]) || p[3] == 'y')) + || (p[0] == 'm' && p[1] == 'z' +*** ../vim-7.3.349/src/version.c 2011-10-26 11:44:15.000000000 +0200 +--- src/version.c 2011-10-26 13:13:21.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 350, + /**/ + +-- +From "know your smileys": + :-| :-| Deja' vu! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8c13b96a3aaf7d596f83e8e309496e0fe1f73032 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:48 +0100 Subject: [PATCH 0069/3340] - patchlevel 351 --- 7.3.351 | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 7.3.351 diff --git a/7.3.351 b/7.3.351 new file mode 100644 index 00000000..15b2194c --- /dev/null +++ b/7.3.351 @@ -0,0 +1,46 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.351 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.351 +Problem: Text formatting uses start of insert position when it should not. + (Peter Wagenaar) +Solution: Do not use Insstart when intentionally formatting. +Files: src/edit.c + + +*** ../vim-7.3.350/src/edit.c 2011-09-21 18:23:02.000000000 +0200 +--- src/edit.c 2011-10-26 16:58:21.000000000 +0200 +*************** +*** 6078,6083 **** +--- 6078,6084 ---- + * Stop at first entered white when 'formatoptions' has 'v' + */ + while ((!fo_ins_blank && !has_format_option(FO_INS_VI)) ++ || (flags & INSCHAR_FORMAT) + || curwin->w_cursor.lnum != Insstart.lnum + || curwin->w_cursor.col >= Insstart.col) + { +*** ../vim-7.3.350/src/version.c 2011-10-26 13:19:23.000000000 +0200 +--- src/version.c 2011-10-26 17:03:37.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 351, + /**/ + +-- +From "know your smileys": + :-* A big kiss! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 760944db55f921240bf853df99efc4eb2b89e56b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:48 +0100 Subject: [PATCH 0070/3340] - patchlevel 352 --- 7.3.352 | 108 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 108 insertions(+) create mode 100644 7.3.352 diff --git a/7.3.352 b/7.3.352 new file mode 100644 index 00000000..52842cfc --- /dev/null +++ b/7.3.352 @@ -0,0 +1,108 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.352 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.352 +Problem: When completing methods dict functions and script-local functions + get in the way. +Solution: Sort function names starting with "<" to the end. (Yasuhiro + Matsumoto) +Files: src/ex_getln.c + + +*** ../vim-7.3.351/src/ex_getln.c 2011-09-30 17:46:14.000000000 +0200 +--- src/ex_getln.c 2011-10-26 21:37:53.000000000 +0200 +*************** +*** 121,126 **** +--- 121,134 ---- + static int ex_window __ARGS((void)); + #endif + ++ #if defined(FEAT_CMDL_COMPL) || defined(PROTO) ++ static int ++ #ifdef __BORLANDC__ ++ _RTLENTRYF ++ #endif ++ sort_func_compare __ARGS((const void *s1, const void *s2)); ++ #endif ++ + /* + * getcmdline() - accept a command line starting with firstc. + * +*************** +*** 3286,3291 **** +--- 3294,3317 ---- + return check_abbr(c, ccline.cmdbuff, ccline.cmdpos, 0); + } + ++ #if defined(FEAT_CMDL_COMPL) || defined(PROTO) ++ static int ++ #ifdef __BORLANDC__ ++ _RTLENTRYF ++ #endif ++ sort_func_compare(s1, s2) ++ const void *s1; ++ const void *s2; ++ { ++ char_u *p1 = *(char_u **)s1; ++ char_u *p2 = *(char_u **)s2; ++ ++ if (*p1 != '<' && *p2 == '<') return -1; ++ if (*p1 == '<' && *p2 != '<') return 1; ++ return STRCMP(p1, p2); ++ } ++ #endif ++ + /* + * Return FAIL if this is not an appropriate context in which to do + * completion of anything, return OK if it is (even if there are no matches). +*************** +*** 4735,4741 **** + + /* Sort the results. Keep menu's in the specified order. */ + if (xp->xp_context != EXPAND_MENUNAMES && xp->xp_context != EXPAND_MENUS) +! sort_strings(*file, *num_file); + + #ifdef FEAT_CMDL_COMPL + /* Reset the variables used for special highlight names expansion, so that +--- 4761,4776 ---- + + /* Sort the results. Keep menu's in the specified order. */ + if (xp->xp_context != EXPAND_MENUNAMES && xp->xp_context != EXPAND_MENUS) +! { +! if (xp->xp_context == EXPAND_EXPRESSION +! || xp->xp_context == EXPAND_FUNCTIONS +! || xp->xp_context == EXPAND_USER_FUNC) +! /* functions should be sorted to the end. */ +! qsort((void *)*file, (size_t)*num_file, sizeof(char_u *), +! sort_func_compare); +! else +! sort_strings(*file, *num_file); +! } + + #ifdef FEAT_CMDL_COMPL + /* Reset the variables used for special highlight names expansion, so that +*** ../vim-7.3.351/src/version.c 2011-10-26 17:04:23.000000000 +0200 +--- src/version.c 2011-10-26 21:49:53.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 352, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +94. Now admit it... How many of you have made "modem noises" into + the phone just to see if it was possible? :-) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 952ed818f9aa557c54a793327eb5761791b56423 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:48 +0100 Subject: [PATCH 0071/3340] - patchlevel 353 --- 7.3.353 | 155 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 155 insertions(+) create mode 100644 7.3.353 diff --git a/7.3.353 b/7.3.353 new file mode 100644 index 00000000..1846243e --- /dev/null +++ b/7.3.353 @@ -0,0 +1,155 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.353 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.353 (after 7.3.343) +Problem: Missing part of the urxvt patch. +Solution: Add the change in term.c +Files: src/term.c + + +*** ../vim-7.3.352/src/term.c 2011-09-14 14:43:21.000000000 +0200 +--- src/term.c 2011-10-26 23:48:01.000000000 +0200 +*************** +*** 4008,4014 **** + } + + #ifdef FEAT_TERMRESPONSE +! if (key_name[0] == NUL) + { + /* Check for xterm version string: "[>{x};{vers};{y}c". Also + * eat other possible responses to t_RV, rxvt returns +--- 4008,4016 ---- + } + + #ifdef FEAT_TERMRESPONSE +! if (key_name[0] == NUL +! /* URXVT mouse uses [#;#;#M, but we are matching [ */ +! || key_name[0] == KS_URXVT_MOUSE) + { + /* Check for xterm version string: "[>{x};{vers};{y}c". Also + * eat other possible responses to t_RV, rxvt returns +*************** +*** 4047,4053 **** + if (tp[1 + (tp[0] != CSI)] == '>' && j == 2) + { + /* if xterm version >= 95 use mouse dragging */ +! if (extra >= 95) + set_option_value((char_u *)"ttym", 0L, + (char_u *)"xterm2", 0); + /* if xterm version >= 141 try to get termcap codes */ +--- 4049,4055 ---- + if (tp[1 + (tp[0] != CSI)] == '>' && j == 2) + { + /* if xterm version >= 95 use mouse dragging */ +! if (extra >= 95 && ttym_flags != TTYM_URXVT) + set_option_value((char_u *)"ttym", 0L, + (char_u *)"xterm2", 0); + /* if xterm version >= 141 try to get termcap codes */ +*************** +*** 4141,4146 **** +--- 4143,4151 ---- + # ifdef FEAT_MOUSE_PTERM + || key_name[0] == (int)KS_PTERM_MOUSE + # endif ++ # ifdef FEAT_MOUSE_URXVT ++ || key_name[0] == (int)KS_URXVT_MOUSE ++ # endif + ) + { + is_click = is_drag = FALSE; +*************** +*** 4219,4225 **** +--- 4224,4292 ---- + else + break; + } ++ } ++ ++ # ifdef FEAT_MOUSE_URXVT ++ if (key_name[0] == (int)KS_URXVT_MOUSE) ++ { ++ for (;;) ++ { ++ /* URXVT 1015 mouse reporting mode: ++ * Almost identical to xterm mouse mode, except the values ++ * are decimal instead of bytes. ++ * ++ * \033[%d;%d;%dM ++ * ^-- row ++ * ^----- column ++ * ^-------- code ++ */ ++ p = tp + slen; ++ ++ mouse_code = getdigits(&p); ++ if (*p++ != ';') ++ return -1; ++ ++ mouse_col = getdigits(&p) - 1; ++ if (*p++ != ';') ++ return -1; ++ ++ mouse_row = getdigits(&p) - 1; ++ if (*p++ != 'M') ++ return -1; ++ ++ slen += (int)(p - (tp + slen)); ++ ++ /* skip this one if next one has same code (like xterm ++ * case) */ ++ j = termcodes[idx].len; ++ if (STRNCMP(tp, tp + slen, (size_t)j) == 0) { ++ /* check if the command is complete by looking for the ++ * M */ ++ int slen2; ++ int cmd_complete = 0; ++ for (slen2 = slen; slen2 < len; slen2++) { ++ if (tp[slen2] == 'M') { ++ cmd_complete = 1; ++ break; ++ } ++ } ++ p += j; ++ if (cmd_complete && getdigits(&p) == mouse_code) { ++ slen += j; /* skip the \033[ */ ++ continue; ++ } ++ } ++ break; ++ } ++ } ++ # endif + ++ if (key_name[0] == (int)KS_MOUSE ++ #ifdef FEAT_MOUSE_URXVT ++ || key_name[0] == (int)KS_URXVT_MOUSE ++ #endif ++ ) ++ { + # if !defined(MSWIN) && !defined(MSDOS) + /* + * Handle mouse events. +*** ../vim-7.3.352/src/version.c 2011-10-26 22:02:10.000000000 +0200 +--- src/version.c 2011-10-26 23:43:26.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 353, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +99. The hum of a cooling fan and the click of keys is comforting to you. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 62b65ca7d59f7e0c0eafdf3a01c99db7eb81ab49 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:49 +0100 Subject: [PATCH 0072/3340] - patchlevel 354 --- 7.3.354 | 71 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) create mode 100644 7.3.354 diff --git a/7.3.354 b/7.3.354 new file mode 100644 index 00000000..8250f9af --- /dev/null +++ b/7.3.354 @@ -0,0 +1,71 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.354 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.354 +Problem: ":set backspace+=eol" doesn't work when 'backspace' has a + backwards compatible value of 2. +Solution: Convert the number to a string. (Hirohito Higashi) +Files: src/option.c + + +*** ../vim-7.3.353/src/option.c 2011-10-12 16:57:07.000000000 +0200 +--- src/option.c 2011-11-30 11:11:15.000000000 +0100 +*************** +*** 4567,4572 **** +--- 4567,4597 ---- + arg = errbuf; + } + /* ++ * Convert 'backspace' number to string, for ++ * adding, prepending and removing string. ++ */ ++ else if (varp == (char_u *)&p_bs ++ && VIM_ISDIGIT(**(char_u **)varp)) ++ { ++ i = getdigits((char_u **)varp); ++ switch (i) ++ { ++ case 0: ++ *(char_u **)varp = empty_option; ++ break; ++ case 1: ++ *(char_u **)varp = vim_strsave( ++ (char_u *)"indent,eol"); ++ break; ++ case 2: ++ *(char_u **)varp = vim_strsave( ++ (char_u *)"indent,eol,start"); ++ break; ++ } ++ vim_free(oldval); ++ oldval = *(char_u **)varp; ++ } ++ /* + * Convert 'whichwrap' number to string, for + * backwards compatibility with Vim 3.0. + * Misuse errbuf[] for the resulting string. +*** ../vim-7.3.353/src/version.c 2011-10-26 23:48:17.000000000 +0200 +--- src/version.c 2011-11-30 11:14:44.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 354, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +206. You religiously respond immediately to e-mail, while ignoring + your growing pile of snail mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f598b00e61b0c1a64067923b1519236599f5fe45 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:49 +0100 Subject: [PATCH 0073/3340] - patchlevel 355 --- 7.3.355 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.355 diff --git a/7.3.355 b/7.3.355 new file mode 100644 index 00000000..51bc3b7f --- /dev/null +++ b/7.3.355 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.355 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.355 +Problem: GTK warnings when using netrw.vim. (Ivan Krasilnikov) +Solution: Do not remove the beval event handler twice. +Files: src/option.c + + +*** ../vim-7.3.354/src/option.c 2011-11-30 11:15:40.000000000 +0100 +--- src/option.c 2011-11-30 11:11:15.000000000 +0100 +*************** +*** 7796,7804 **** + #ifdef FEAT_BEVAL + else if ((int *)varp == &p_beval) + { +! if (p_beval == TRUE) + gui_mch_enable_beval_area(balloonEval); +! else + gui_mch_disable_beval_area(balloonEval); + } + #endif +--- 7796,7804 ---- + #ifdef FEAT_BEVAL + else if ((int *)varp == &p_beval) + { +! if (p_beval && !old_value) + gui_mch_enable_beval_area(balloonEval); +! else if (!p_beval && old_value) + gui_mch_disable_beval_area(balloonEval); + } + #endif +*** ../vim-7.3.354/src/version.c 2011-11-30 11:15:40.000000000 +0100 +--- src/version.c 2011-11-30 11:30:55.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 355, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +209. Your house stinks because you haven't cleaned it in a week. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0019b2d609595d608905c287d6758a6eb3fcbdfe Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:50 +0100 Subject: [PATCH 0074/3340] - patchlevel 356 --- 7.3.356 | 79 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 79 insertions(+) create mode 100644 7.3.356 diff --git a/7.3.356 b/7.3.356 new file mode 100644 index 00000000..8b5572bd --- /dev/null +++ b/7.3.356 @@ -0,0 +1,79 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.356 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.356 +Problem: Using "o" with 'cindent' set may freeze Vim. (lolilolicon) +Solution: Skip over {} correctly. (Hari G) +Files: src/misc1.c + + +*** ../vim-7.3.355/src/misc1.c 2011-10-04 18:03:43.000000000 +0200 +--- src/misc1.c 2011-11-30 12:56:55.000000000 +0100 +*************** +*** 6127,6133 **** + + /* + * Set w_cursor.col to the column number of the last unmatched ')' or '{' in +! * line "l". + */ + static int + find_last_paren(l, start, end) +--- 6127,6133 ---- + + /* + * Set w_cursor.col to the column number of the last unmatched ')' or '{' in +! * line "l". "l" must point to the start of the line. + */ + static int + find_last_paren(l, start, end) +*************** +*** 6140,6146 **** + + curwin->w_cursor.col = 0; /* default is start of line */ + +! for (i = 0; l[i]; i++) + { + i = (int)(cin_skipcomment(l + i) - l); /* ignore parens in comments */ + i = (int)(skip_string(l + i) - l); /* ignore parens in quotes */ +--- 6140,6146 ---- + + curwin->w_cursor.col = 0; /* default is start of line */ + +! for (i = 0; l[i] != NUL; i++) + { + i = (int)(cin_skipcomment(l + i) - l); /* ignore parens in comments */ + i = (int)(skip_string(l + i) - l); /* ignore parens in quotes */ +*************** +*** 7953,7958 **** +--- 7953,7959 ---- + * If we're at the end of a block, skip to the start of + * that block. + */ ++ l = ml_get_curline(); + if (find_last_paren(l, '{', '}') + && (trypos = find_start_brace(ind_maxcomment)) + != NULL) /* XXX */ +*** ../vim-7.3.355/src/version.c 2011-11-30 11:31:25.000000000 +0100 +--- src/version.c 2011-11-30 13:02:52.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 356, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +213. Your kids start referring to you as "that guy in front of the monitor." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 82274d7dd736f6e023e523e0a84b804a08039ea0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:50 +0100 Subject: [PATCH 0075/3340] - patchlevel 357 --- 7.3.357 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.357 diff --git a/7.3.357 b/7.3.357 new file mode 100644 index 00000000..893a6bb4 --- /dev/null +++ b/7.3.357 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.357 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.357 +Problem: Compiler warning in MS-Windows console build. +Solution: Adjust return type of PrintHookProc(). (Mike Williams) +Files: src/os_mswin.c + + +*** ../vim-7.3.356/src/os_mswin.c 2011-09-21 20:09:38.000000000 +0200 +--- src/os_mswin.c 2011-11-30 13:41:13.000000000 +0100 +*************** +*** 1869,1875 **** + + #ifndef FEAT_GUI + +! static UINT CALLBACK + PrintHookProc( + HWND hDlg, // handle to dialog box + UINT uiMsg, // message identifier +--- 1869,1875 ---- + + #ifndef FEAT_GUI + +! static UINT_PTR CALLBACK + PrintHookProc( + HWND hDlg, // handle to dialog box + UINT uiMsg, // message identifier +*** ../vim-7.3.356/src/version.c 2011-11-30 13:03:24.000000000 +0100 +--- src/version.c 2011-11-30 13:41:55.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 357, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +215. Your mouse-clicking forearm rivals Popeye's. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5241c5ea9a219346f8138ad5218865d199b106dd Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:50 +0100 Subject: [PATCH 0076/3340] - patchlevel 358 --- 7.3.358 | 74 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 7.3.358 diff --git a/7.3.358 b/7.3.358 new file mode 100644 index 00000000..b9b385f8 --- /dev/null +++ b/7.3.358 @@ -0,0 +1,74 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.358 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.358 (after 7.3.353) +Problem: Mouse support doesn't work properly. +Solution: Add HMT_URXVT. (lilydjwg, James McCoy) +Files: src/term.c + + +*** ../vim-7.3.357/src/term.c 2011-10-26 23:48:17.000000000 +0200 +--- src/term.c 2011-11-30 14:42:22.000000000 +0100 +*************** +*** 1996,2001 **** +--- 1996,2002 ---- + # define HMT_DEC 4 + # define HMT_JSBTERM 8 + # define HMT_PTERM 16 ++ # define HMT_URXVT 32 + static int has_mouse_termcode = 0; + # endif + +*************** +*** 2031,2036 **** +--- 2032,2042 ---- + has_mouse_termcode |= HMT_PTERM; + else + # endif ++ # ifdef FEAT_MOUSE_URXVT ++ if (n == KS_URXVT_MOUSE) ++ has_mouse_termcode |= HMT_URXVT; ++ else ++ # endif + has_mouse_termcode |= HMT_NORMAL; + # endif + } +*************** +*** 2068,2073 **** +--- 2074,2084 ---- + has_mouse_termcode &= ~HMT_PTERM; + else + # endif ++ # ifdef FEAT_MOUSE_URXVT ++ if (n == KS_URXVT_MOUSE) ++ has_mouse_termcode &= ~HMT_URXVT; ++ else ++ # endif + has_mouse_termcode &= ~HMT_NORMAL; + # endif + } +*** ../vim-7.3.357/src/version.c 2011-11-30 13:42:40.000000000 +0100 +--- src/version.c 2011-11-30 14:45:06.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 358, + /**/ + +-- +I noticed my daughter's Disney-net password on a sticky note: +"MickeyMinnieGoofyPluto". I asked her why it was so long. +"Because they say it has to have at least four characters." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3adf03b52af8463a491bf41e8ecfa2bc4677294b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:51 +0100 Subject: [PATCH 0077/3340] - patchlevel 359 --- 7.3.359 | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 7.3.359 diff --git a/7.3.359 b/7.3.359 new file mode 100644 index 00000000..7fbd3f6f --- /dev/null +++ b/7.3.359 @@ -0,0 +1,64 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.359 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.359 +Problem: Command line completion shows dict functions. +Solution: Skip dict functions for completion. (Yasuhiro Matsumoto) +Files: src/eval.c + + +*** ../vim-7.3.358/src/eval.c 2011-10-26 13:19:23.000000000 +0200 +--- src/eval.c 2011-11-30 14:53:38.000000000 +0100 +*************** +*** 875,881 **** + + #ifdef EBCDIC + /* +! * Sort the function table, to enable binary sort. + */ + sortFunctions(); + #endif +--- 875,881 ---- + + #ifdef EBCDIC + /* +! * Sort the function table, to enable binary search. + */ + sortFunctions(); + #endif +*************** +*** 21737,21742 **** +--- 21737,21745 ---- + ++hi; + fp = HI2UF(hi); + ++ if (fp->uf_flags & FC_DICT) ++ return NULL; /* don't show dict functions */ ++ + if (STRLEN(fp->uf_name) + 4 >= IOSIZE) + return fp->uf_name; /* prevents overflow */ + +*** ../vim-7.3.358/src/version.c 2011-11-30 14:47:12.000000000 +0100 +--- src/version.c 2011-11-30 14:56:57.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 359, + /**/ + +-- +'Psychologist' -- Someone who looks at everyone else when +an attractive woman enters the room. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c708c412519a74e2f5ba2aefe75727470a0d81ac Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:51 +0100 Subject: [PATCH 0078/3340] - patchlevel 360 --- 7.3.360 | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 7.3.360 diff --git a/7.3.360 b/7.3.360 new file mode 100644 index 00000000..de153c83 --- /dev/null +++ b/7.3.360 @@ -0,0 +1,61 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.360 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.360 +Problem: Interrupting the load of an autoload function may cause a crash. +Solution: Do not use the hashitem when not valid. (Yukihiro Nakadaira) +Files: src/eval.c + + +*** ../vim-7.3.359/src/eval.c 2011-11-30 14:57:26.000000000 +0100 +--- src/eval.c 2011-11-30 15:06:53.000000000 +0100 +*************** +*** 19589,19597 **** + * worked find the variable again. Don't auto-load a script if it was + * loaded already, otherwise it would be loaded every time when + * checking if a function name is a Funcref variable. */ +! if (ht == &globvarht && !writing +! && script_autoload(varname, FALSE) && !aborting()) + hi = hash_find(ht, varname); + if (HASHITEM_EMPTY(hi)) + return NULL; + } +--- 19589,19602 ---- + * worked find the variable again. Don't auto-load a script if it was + * loaded already, otherwise it would be loaded every time when + * checking if a function name is a Funcref variable. */ +! if (ht == &globvarht && !writing) +! { +! /* Note: script_autoload() may make "hi" invalid. It must either +! * be obtained again or not used. */ +! if (!script_autoload(varname, FALSE) || aborting()) +! return NULL; + hi = hash_find(ht, varname); ++ } + if (HASHITEM_EMPTY(hi)) + return NULL; + } +*** ../vim-7.3.359/src/version.c 2011-11-30 14:57:26.000000000 +0100 +--- src/version.c 2011-11-30 15:17:28.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 360, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +217. Your sex life has drastically improved...so what if it's only cyber-sex! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ef6c1909c495c2478fbaa74c9d6e398ed2dc6bc7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:52 +0100 Subject: [PATCH 0079/3340] - patchlevel 361 --- 7.3.361 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.361 diff --git a/7.3.361 b/7.3.361 new file mode 100644 index 00000000..c128057f --- /dev/null +++ b/7.3.361 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.361 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.361 +Problem: Accessing memory after it is freed when EXITFREE is defined. +Solution: Don't access curwin when firstwin is NULL. (Dominique Pelle) +Files: src/buffer.c + +*** ../vim-7.3.360/src/buffer.c 2011-09-14 17:50:05.000000000 +0200 +--- src/buffer.c 2011-11-30 15:38:00.000000000 +0100 +*************** +*** 567,574 **** + diff_buf_delete(buf); /* Can't use 'diff' for unloaded buffer. */ + #endif + #ifdef FEAT_SYN_HL +! if (curwin->w_buffer == buf) +! reset_synblock(curwin); /* remove any ownsyntax */ + #endif + + #ifdef FEAT_FOLDING +--- 567,575 ---- + diff_buf_delete(buf); /* Can't use 'diff' for unloaded buffer. */ + #endif + #ifdef FEAT_SYN_HL +! /* Remove any ownsyntax, unless exiting. */ +! if (firstwin != NULL && curwin->w_buffer == buf) +! reset_synblock(curwin); + #endif + + #ifdef FEAT_FOLDING +*** ../vim-7.3.360/src/version.c 2011-11-30 15:19:25.000000000 +0100 +--- src/version.c 2011-11-30 15:40:22.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 361, + /**/ + + +-- +From the classified section of a city newspaper: +Dog for sale: eats anything and is fond of children. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From cade0dc5a66535757c5a320c031cd47546f8285b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:52 +0100 Subject: [PATCH 0080/3340] - patchlevel 362 --- 7.3.362 | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.362 diff --git a/7.3.362 b/7.3.362 new file mode 100644 index 00000000..00568861 --- /dev/null +++ b/7.3.362 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.362 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.362 +Problem: ml_get error when using ":g" with folded lines. +Solution: Adjust the line number for changed_lines(). (Christian Brabandt) +Files: src/ex_cmds.c + + +*** ../vim-7.3.361/src/ex_cmds.c 2011-10-20 18:17:38.000000000 +0200 +--- src/ex_cmds.c 2011-11-30 16:58:34.000000000 +0100 +*************** +*** 820,826 **** + curwin->w_cursor.lnum = dest + (line2 - line1) + 1; + + if (line1 < dest) +! changed_lines(line1, 0, dest + num_lines + 1, 0L); + else + changed_lines(dest + 1, 0, line1 + num_lines, 0L); + +--- 820,832 ---- + curwin->w_cursor.lnum = dest + (line2 - line1) + 1; + + if (line1 < dest) +! { +! dest += num_lines + 1; +! last_line = curbuf->b_ml.ml_line_count; +! if (dest > last_line + 1) +! dest = last_line + 1; +! changed_lines(line1, 0, dest, 0L); +! } + else + changed_lines(dest + 1, 0, line1 + num_lines, 0L); + +*** ../vim-7.3.361/src/version.c 2011-11-30 15:40:51.000000000 +0100 +--- src/version.c 2011-11-30 17:01:07.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 362, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +218. Your spouse hands you a gift wrapped magnet with your PC's name + on it and you accuse him or her of genocide. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9bf8d7517be122ef61c6a11773e71bf0deb7fca3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:52 +0100 Subject: [PATCH 0081/3340] - patchlevel 363 --- 7.3.363 | 110 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 110 insertions(+) create mode 100644 7.3.363 diff --git a/7.3.363 b/7.3.363 new file mode 100644 index 00000000..10ab5482 --- /dev/null +++ b/7.3.363 @@ -0,0 +1,110 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.363 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.363 +Problem: C indenting is wrong after #endif followed by a semicolon. +Solution: Add special handling for a semicolon in a line by itself. (Lech + Lorens) +Files: src/misc1.c, src/testdir/test3.in, src/testdir/test3.ok + + +*** ../vim-7.3.362/src/misc1.c 2011-11-30 13:03:24.000000000 +0100 +--- src/misc1.c 2011-11-30 17:10:59.000000000 +0100 +*************** +*** 8143,8148 **** +--- 8143,8171 ---- + break; + + /* ++ * Find a line only has a semicolon that belongs to a previous ++ * line ending in '}', e.g. before an #endif. Don't increase ++ * indent then. ++ */ ++ if (*(look = skipwhite(l)) == ';' && cin_nocode(look + 1)) ++ { ++ pos_T curpos_save = curwin->w_cursor; ++ ++ while (curwin->w_cursor.lnum > 1) ++ { ++ look = ml_get(--curwin->w_cursor.lnum); ++ if (!(cin_nocode(look) || cin_ispreproc_cont( ++ &look, &curwin->w_cursor.lnum))) ++ break; ++ } ++ if (curwin->w_cursor.lnum > 0 ++ && cin_ends_in(look, (char_u *)"}", NULL)) ++ break; ++ ++ curwin->w_cursor = curpos_save; ++ } ++ ++ /* + * If the PREVIOUS line is a function declaration, the current + * line (and the ones that follow) needs to be indented as + * parameters. +*** ../vim-7.3.362/src/testdir/test3.in 2011-10-04 18:03:43.000000000 +0200 +--- src/testdir/test3.in 2011-11-30 17:05:20.000000000 +0100 +*************** +*** 1454,1459 **** +--- 1454,1469 ---- + printf("This line used to be indented incorrectly.\n"); + } + ++ int foo[] ++ #ifdef BAR ++ ++ = { 1, 2, 3, ++ 4, 5, 6 } ++ ++ #endif ++ ; ++ int baz; ++ + void func3(void) + { + int tab[] = { +*** ../vim-7.3.362/src/testdir/test3.ok 2011-10-04 18:03:43.000000000 +0200 +--- src/testdir/test3.ok 2011-11-30 17:05:20.000000000 +0100 +*************** +*** 1307,1312 **** +--- 1307,1322 ---- + printf("This line used to be indented incorrectly.\n"); + } + ++ int foo[] ++ #ifdef BAR ++ ++ = { 1, 2, 3, ++ 4, 5, 6 } ++ ++ #endif ++ ; ++ int baz; ++ + void func3(void) + { + int tab[] = { +*** ../vim-7.3.362/src/version.c 2011-11-30 17:01:55.000000000 +0100 +--- src/version.c 2011-11-30 17:06:57.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 363, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +220. Your wife asks for sex and you tell her where to find you on IRC. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f9665062e48e149340168d25ada5839bd6a9a7d9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:53 +0100 Subject: [PATCH 0082/3340] - patchlevel 364 --- 7.3.364 | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 7.3.364 diff --git a/7.3.364 b/7.3.364 new file mode 100644 index 00000000..e62ef76d --- /dev/null +++ b/7.3.364 @@ -0,0 +1,57 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.364 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.364 (after 7.3.353) +Problem: Can't compile on HP-UX. (John Marriott) +Solution: Only use TTYM_URXVT when it is defined. +Files: src/term.c + + +*** ../vim-7.3.363/src/term.c 2011-11-30 14:47:12.000000000 +0100 +--- src/term.c 2011-12-01 20:53:57.000000000 +0100 +*************** +*** 4060,4066 **** + if (tp[1 + (tp[0] != CSI)] == '>' && j == 2) + { + /* if xterm version >= 95 use mouse dragging */ +! if (extra >= 95 && ttym_flags != TTYM_URXVT) + set_option_value((char_u *)"ttym", 0L, + (char_u *)"xterm2", 0); + /* if xterm version >= 141 try to get termcap codes */ +--- 4060,4070 ---- + if (tp[1 + (tp[0] != CSI)] == '>' && j == 2) + { + /* if xterm version >= 95 use mouse dragging */ +! if (extra >= 95 +! # ifdef TTYM_URXVT +! && ttym_flags != TTYM_URXVT +! # endif +! ) + set_option_value((char_u *)"ttym", 0L, + (char_u *)"xterm2", 0); + /* if xterm version >= 141 try to get termcap codes */ +*** ../vim-7.3.363/src/version.c 2011-11-30 17:20:18.000000000 +0100 +--- src/version.c 2011-12-01 20:56:55.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 364, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +224. You set up your own Web page. You set up a Web page for each + of your kids... and your pets. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 756952d8edc9699f32b5782ea2ed51bc99c86632 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:53 +0100 Subject: [PATCH 0083/3340] - patchlevel 365 --- 7.3.365 | 131 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 131 insertions(+) create mode 100644 7.3.365 diff --git a/7.3.365 b/7.3.365 new file mode 100644 index 00000000..16d5ad1b --- /dev/null +++ b/7.3.365 @@ -0,0 +1,131 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.365 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.365 +Problem: Crash when using a large Unicode character in a file that has + syntax highlighting. (ngollan) +Solution: Check for going past the end of the utf tables. (Dominique Pelle) +Files: src/mbyte.c + + +*** ../vim-7.3.364/src/mbyte.c 2011-08-10 13:21:30.000000000 +0200 +--- src/mbyte.c 2011-12-08 15:09:13.000000000 +0100 +*************** +*** 2764,2782 **** + int tableSize; + { + int start, mid, end; /* indices into table */ + + start = 0; +! end = tableSize / sizeof(convertStruct); + while (start < end) + { + /* need to search further */ +! mid = (end + start) /2; + if (table[mid].rangeEnd < a) + start = mid + 1; + else + end = mid; + } +! if (table[start].rangeStart <= a && a <= table[start].rangeEnd + && (a - table[start].rangeStart) % table[start].step == 0) + return (a + table[start].offset); + else +--- 2764,2785 ---- + int tableSize; + { + int start, mid, end; /* indices into table */ ++ int entries = tableSize / sizeof(convertStruct); + + start = 0; +! end = entries; + while (start < end) + { + /* need to search further */ +! mid = (end + start) / 2; + if (table[mid].rangeEnd < a) + start = mid + 1; + else + end = mid; + } +! if (start < entries +! && table[start].rangeStart <= a +! && a <= table[start].rangeEnd + && (a - table[start].rangeStart) % table[start].step == 0) + return (a + table[start].offset); + else +*************** +*** 2791,2797 **** + utf_fold(a) + int a; + { +! return utf_convert(a, foldCase, sizeof(foldCase)); + } + + static convertStruct toLower[] = +--- 2794,2800 ---- + utf_fold(a) + int a; + { +! return utf_convert(a, foldCase, (int)sizeof(foldCase)); + } + + static convertStruct toLower[] = +*************** +*** 3119,3125 **** + return TOUPPER_LOC(a); + + /* For any other characters use the above mapping table. */ +! return utf_convert(a, toUpper, sizeof(toUpper)); + } + + int +--- 3122,3128 ---- + return TOUPPER_LOC(a); + + /* For any other characters use the above mapping table. */ +! return utf_convert(a, toUpper, (int)sizeof(toUpper)); + } + + int +*************** +*** 3152,3158 **** + return TOLOWER_LOC(a); + + /* For any other characters use the above mapping table. */ +! return utf_convert(a, toLower, sizeof(toLower)); + } + + int +--- 3155,3161 ---- + return TOLOWER_LOC(a); + + /* For any other characters use the above mapping table. */ +! return utf_convert(a, toLower, (int)sizeof(toLower)); + } + + int +*** ../vim-7.3.364/src/version.c 2011-12-01 20:59:16.000000000 +0100 +--- src/version.c 2011-12-08 15:07:53.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 365, + /**/ + +-- +Hear about the guy who played a blank tape at full blast? +The mime next door went nuts. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a9d4f86aa738141d1df85f9f50502b6767420cd4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:53 +0100 Subject: [PATCH 0084/3340] - patchlevel 366 --- 7.3.366 | 76 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 7.3.366 diff --git a/7.3.366 b/7.3.366 new file mode 100644 index 00000000..ddf39903 --- /dev/null +++ b/7.3.366 @@ -0,0 +1,76 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.366 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.366 +Problem: A tags file with an extremely long name causes errors. +Solution: Ignore tags that are too long. (Arno Renevier) +Files: src/tag.c + + +*** ../vim-7.3.365/src/tag.c 2011-10-12 19:53:31.000000000 +0200 +--- src/tag.c 2011-12-08 13:32:51.000000000 +0100 +*************** +*** 1906,1917 **** + tagp.tagname = lbuf; + #ifdef FEAT_TAG_ANYWHITE + tagp.tagname_end = skiptowhite(lbuf); +! if (*tagp.tagname_end == NUL) /* corrupted tag line */ + #else + tagp.tagname_end = vim_strchr(lbuf, TAB); +! if (tagp.tagname_end == NULL) /* corrupted tag line */ + #endif + { + line_error = TRUE; + break; + } +--- 1906,1931 ---- + tagp.tagname = lbuf; + #ifdef FEAT_TAG_ANYWHITE + tagp.tagname_end = skiptowhite(lbuf); +! if (*tagp.tagname_end == NUL) + #else + tagp.tagname_end = vim_strchr(lbuf, TAB); +! if (tagp.tagname_end == NULL) + #endif + { ++ if (vim_strchr(lbuf, NL) == NULL) ++ { ++ /* Truncated line, ignore it. Has been reported for ++ * Mozilla JS with extremely long names. */ ++ if (p_verbose >= 5) ++ { ++ verbose_enter(); ++ MSG(_("Ignoring long line in tags file")); ++ verbose_leave(); ++ } ++ continue; ++ } ++ ++ /* Corrupted tag line. */ + line_error = TRUE; + break; + } +*** ../vim-7.3.365/src/version.c 2011-12-08 15:09:46.000000000 +0100 +--- src/version.c 2011-12-08 15:11:10.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 366, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +246. You use up your free 100 hours in less than a week. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3ebc5f39253e1353ebb618d3cbcbd4b59c4940c3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:54 +0100 Subject: [PATCH 0085/3340] - patchlevel 367 --- 7.3.367 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.367 diff --git a/7.3.367 b/7.3.367 new file mode 100644 index 00000000..2452d531 --- /dev/null +++ b/7.3.367 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.367 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.367 +Problem: :wundo and :rundo use a wrong checksum. +Solution: Include the last line when computing the hash. (Christian Brabandt) +Files: src/undo.c + + +*** ../vim-7.3.366/src/undo.c 2011-01-22 21:25:07.000000000 +0100 +--- src/undo.c 2011-12-08 14:19:03.000000000 +0100 +*************** +*** 719,725 **** + char_u *p; + + sha256_start(&ctx); +! for (lnum = 1; lnum < curbuf->b_ml.ml_line_count; ++lnum) + { + p = ml_get(lnum); + sha256_update(&ctx, p, (UINT32_T)(STRLEN(p) + 1)); +--- 719,725 ---- + char_u *p; + + sha256_start(&ctx); +! for (lnum = 1; lnum <= curbuf->b_ml.ml_line_count; ++lnum) + { + p = ml_get(lnum); + sha256_update(&ctx, p, (UINT32_T)(STRLEN(p) + 1)); +*** ../vim-7.3.366/src/version.c 2011-12-08 15:12:08.000000000 +0100 +--- src/version.c 2011-12-08 15:13:32.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 367, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +247. You use www.switchboard.com instead of dialing 411 and 555-12-12 + for directory assistance. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bde42a417db949bad7360df4420a119119b6ad9d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:54 +0100 Subject: [PATCH 0086/3340] - patchlevel 368 --- 7.3.368 | 103 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 103 insertions(+) create mode 100644 7.3.368 diff --git a/7.3.368 b/7.3.368 new file mode 100644 index 00000000..958c69e7 --- /dev/null +++ b/7.3.368 @@ -0,0 +1,103 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.368 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.368 +Problem: Gcc complains about redefining _FORTIFY_SOURCE. +Solution: Undefine it before redefining it. +Files: src/Makefile, src/configure.in, src/auto/configure + + +*** ../vim-7.3.367/src/Makefile 2011-10-20 16:35:25.000000000 +0200 +--- src/Makefile 2011-12-08 15:16:13.000000000 +0100 +*************** +*** 561,568 **** + #CFLAGS = -g -O2 '-DSTARTUPTIME="vimstartup"' -fno-strength-reduce -Wall -Wmissing-prototypes + + # Use this with GCC to check for mistakes, unused arguments, etc. +! #CFLAGS = -g -Wall -Wextra -Wmissing-prototypes -Wunreachable-code -D_FORTIFY_SOURCE=1 +! #CFLAGS = -g -O2 -Wall -Wextra -Wmissing-prototypes -D_FORTIFY_SOURCE=1 -DU_DEBUG + #PYTHON_CFLAGS_EXTRA = -Wno-missing-field-initializers + #MZSCHEME_CFLAGS_EXTRA = -Wno-unreachable-code -Wno-unused-parameter + +--- 561,568 ---- + #CFLAGS = -g -O2 '-DSTARTUPTIME="vimstartup"' -fno-strength-reduce -Wall -Wmissing-prototypes + + # Use this with GCC to check for mistakes, unused arguments, etc. +! #CFLAGS = -g -Wall -Wextra -Wmissing-prototypes -Wunreachable-code -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1 +! #CFLAGS = -g -O2 -Wall -Wextra -Wmissing-prototypes -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1 -DU_DEBUG + #PYTHON_CFLAGS_EXTRA = -Wno-missing-field-initializers + #MZSCHEME_CFLAGS_EXTRA = -Wno-unreachable-code -Wno-unused-parameter + +*** ../vim-7.3.367/src/configure.in 2011-09-02 12:27:20.000000000 +0200 +--- src/configure.in 2011-12-01 20:23:22.000000000 +0100 +*************** +*** 3584,3592 **** + dnl -D_FORTIFY_SOURCE=2 crashes Vim on strcpy(buf, "000") when buf is + dnl declared as char x[1] but actually longer. Introduced in gcc 4.0. + dnl Also remove duplicate _FORTIFY_SOURCE arguments. + AC_MSG_CHECKING(whether we need -D_FORTIFY_SOURCE=1) + if test "$gccmajor" -gt "3"; then +! CFLAGS=`echo "$CFLAGS" | sed -e 's/-Wp,-D_FORTIFY_SOURCE=.//g' -e 's/-D_FORTIFY_SOURCE=.//g' -e 's/$/ -D_FORTIFY_SOURCE=1/'` + AC_MSG_RESULT(yes) + else + AC_MSG_RESULT(no) +--- 3584,3593 ---- + dnl -D_FORTIFY_SOURCE=2 crashes Vim on strcpy(buf, "000") when buf is + dnl declared as char x[1] but actually longer. Introduced in gcc 4.0. + dnl Also remove duplicate _FORTIFY_SOURCE arguments. ++ dnl And undefine it first to avoid a warning. + AC_MSG_CHECKING(whether we need -D_FORTIFY_SOURCE=1) + if test "$gccmajor" -gt "3"; then +! CFLAGS=`echo "$CFLAGS" | sed -e 's/-Wp,-D_FORTIFY_SOURCE=.//g' -e 's/-D_FORTIFY_SOURCE=.//g' -e 's/$/ -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1/'` + AC_MSG_RESULT(yes) + else + AC_MSG_RESULT(no) +*** ../vim-7.3.367/src/auto/configure 2011-09-02 12:27:20.000000000 +0200 +--- src/auto/configure 2011-12-01 20:24:02.000000000 +0100 +*************** +*** 12483,12492 **** + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 + $as_echo "no" >&6; } + fi +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_FORTIFY_SOURCE=1" >&5 + $as_echo_n "checking whether we need -D_FORTIFY_SOURCE=1... " >&6; } + if test "$gccmajor" -gt "3"; then +! CFLAGS=`echo "$CFLAGS" | sed -e 's/-Wp,-D_FORTIFY_SOURCE=.//g' -e 's/-D_FORTIFY_SOURCE=.//g' -e 's/$/ -D_FORTIFY_SOURCE=1/'` + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 + $as_echo "yes" >&6; } + else +--- 12483,12492 ---- + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 + $as_echo "no" >&6; } + fi +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_FORTIFY_SOURCE=1" >&5 + $as_echo_n "checking whether we need -D_FORTIFY_SOURCE=1... " >&6; } + if test "$gccmajor" -gt "3"; then +! CFLAGS=`echo "$CFLAGS" | sed -e 's/-Wp,-D_FORTIFY_SOURCE=.//g' -e 's/-D_FORTIFY_SOURCE=.//g' -e 's/$/ -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1/'` + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 + $as_echo "yes" >&6; } + else +*** ../vim-7.3.367/src/version.c 2011-12-08 15:14:04.000000000 +0100 +--- src/version.c 2011-12-08 15:15:13.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 368, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +248. You sign your letters with your e-mail address instead of your name. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e2bb212eb29415d790049cb377e3e6b8752d04d1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:54 +0100 Subject: [PATCH 0087/3340] - patchlevel 369 --- 7.3.369 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.369 diff --git a/7.3.369 b/7.3.369 new file mode 100644 index 00000000..af6e7e6e --- /dev/null +++ b/7.3.369 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.369 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.369 +Problem: When compiled with Gnome get an error message when using --help. +Solution: Don't fork. (Ivan Krasilnikov) +Files: src/main.c + + +*** ../vim-7.3.368/src/main.c 2011-10-04 16:43:49.000000000 +0200 +--- src/main.c 2011-12-01 20:27:11.000000000 +0100 +*************** +*** 3294,3300 **** +--- 3294,3303 ---- + #ifdef FEAT_GUI_GNOME + /* Gnome gives extra messages for --help if we continue, but not for -h. */ + if (gui.starting) ++ { + mch_msg("\n"); ++ gui.dofork = FALSE; ++ } + else + #endif + mch_exit(0); +*** ../vim-7.3.368/src/version.c 2011-12-08 15:17:28.000000000 +0100 +--- src/version.c 2011-12-08 15:57:03.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 369, + /**/ + +-- +Vi is clearly superior to emacs, since "vi" has only two characters +(and two keystrokes), while "emacs" has five. (Randy C. Ford) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 53ef4e28e2d349feec2f876da82a5e73fbd3a79e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:55 +0100 Subject: [PATCH 0088/3340] - patchlevel 370 --- 7.3.370 | 63 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 7.3.370 diff --git a/7.3.370 b/7.3.370 new file mode 100644 index 00000000..26bce4d1 --- /dev/null +++ b/7.3.370 @@ -0,0 +1,63 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.370 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.370 +Problem: Compiler warns for unused variable in Lua interface. +Solution: Remove the variable. +Files: src/if_lua.c + + +*** ../vim-7.3.369/src/if_lua.c 2011-09-21 17:15:34.000000000 +0200 +--- src/if_lua.c 2011-12-01 20:19:17.000000000 +0100 +*************** +*** 1044,1056 **** + static int + luaV_open(lua_State *L) + { +- luaV_Buffer *b; + char_u *s = NULL; + #ifdef HAVE_SANDBOX + luaV_checksandbox(L); + #endif + if (lua_isstring(L, 1)) s = (char_u *) lua_tostring(L, 1); +! b = luaV_pushbuffer(L, buflist_new(s, NULL, 1L, BLN_LISTED)); + return 1; + } + +--- 1044,1055 ---- + static int + luaV_open(lua_State *L) + { + char_u *s = NULL; + #ifdef HAVE_SANDBOX + luaV_checksandbox(L); + #endif + if (lua_isstring(L, 1)) s = (char_u *) lua_tostring(L, 1); +! luaV_pushbuffer(L, buflist_new(s, NULL, 1L, BLN_LISTED)); + return 1; + } + +*** ../vim-7.3.369/src/version.c 2011-12-08 15:57:54.000000000 +0100 +--- src/version.c 2011-12-08 15:59:35.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 370, + /**/ + +-- +Emacs is a nice OS - but it lacks a good text editor. +That's why I am using Vim. --Anonymous + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6b729c566ede0ffff8141bd2058447b4971904b3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:55 +0100 Subject: [PATCH 0089/3340] - patchlevel 371 --- 7.3.371 | 75 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 75 insertions(+) create mode 100644 7.3.371 diff --git a/7.3.371 b/7.3.371 new file mode 100644 index 00000000..1701c118 --- /dev/null +++ b/7.3.371 @@ -0,0 +1,75 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.371 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.371 +Problem: Crash in autocomplete. (Greg Weber) +Solution: Check not going over allocated buffer size. +Files: src/misc2.c + + +*** ../vim-7.3.370/src/misc2.c 2011-10-26 11:40:56.000000000 +0200 +--- src/misc2.c 2011-12-08 17:49:23.000000000 +0100 +*************** +*** 4293,4298 **** +--- 4293,4300 ---- + static int ff_path_in_stoplist __ARGS((char_u *, int, char_u **)); + #endif + ++ static char_u e_pathtoolong[] = N_("E854: path too long for completion"); ++ + #if 0 + /* + * if someone likes findfirst/findnext, here are the functions +*************** +*** 4589,4594 **** +--- 4591,4601 ---- + len = 0; + while (*wc_part != NUL) + { ++ if (len + 5 >= MAXPATHL) ++ { ++ EMSG(_(e_pathtoolong)); ++ break; ++ } + if (STRNCMP(wc_part, "**", 2) == 0) + { + ff_expand_buffer[len++] = *wc_part++; +*************** +*** 4634,4639 **** +--- 4641,4652 ---- + } + + /* create an absolute path */ ++ if (STRLEN(search_ctx->ffsc_start_dir) ++ + STRLEN(search_ctx->ffsc_fix_path) + 3 >= MAXPATHL) ++ { ++ EMSG(_(e_pathtoolong)); ++ goto error_return; ++ } + STRCPY(ff_expand_buffer, search_ctx->ffsc_start_dir); + add_pathsep(ff_expand_buffer); + STRCAT(ff_expand_buffer, search_ctx->ffsc_fix_path); +*** ../vim-7.3.370/src/version.c 2011-12-08 16:00:12.000000000 +0100 +--- src/version.c 2011-12-08 17:46:41.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 371, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +253. You wait for a slow loading web page before going to the toilet. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7a6ccdddde91e5d87109a426e602a4b9b3312cfc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:56 +0100 Subject: [PATCH 0090/3340] - patchlevel 372 --- 7.3.372 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.372 diff --git a/7.3.372 b/7.3.372 new file mode 100644 index 00000000..c9978c31 --- /dev/null +++ b/7.3.372 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.372 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.372 +Problem: When using a command line mapping to with file name + completion to go one directory up, 'wildchar' is inserted. + (Yasuhiro Matsumoto) +Solution: Set the KeyTyped flag. +Files: src/ex_getln.c + + +*** ../vim-7.3.371/src/ex_getln.c 2011-10-26 22:02:10.000000000 +0200 +--- src/ex_getln.c 2011-12-08 18:40:49.000000000 +0100 +*************** +*** 645,651 **** +--- 645,655 ---- + } + else if (ccline.cmdpos > i) + cmdline_del(i); ++ ++ /* Now complete in the new directory. Set KeyTyped in case the ++ * Up key came from a mapping. */ + c = p_wc; ++ KeyTyped = TRUE; + } + } + +*** ../vim-7.3.371/src/version.c 2011-12-08 17:49:31.000000000 +0100 +--- src/version.c 2011-12-08 18:42:54.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 372, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +255. You work for a newspaper and your editor asks you to write an + article about Internet addiction...in the "first person." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 24582d5fc6f99d4357969f99051e22df6f1c0386 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:56 +0100 Subject: [PATCH 0091/3340] - patchlevel 373 --- 7.3.373 | 78 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) create mode 100644 7.3.373 diff --git a/7.3.373 b/7.3.373 new file mode 100644 index 00000000..3e8937a0 --- /dev/null +++ b/7.3.373 @@ -0,0 +1,78 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.373 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.373 (after 7.3.366) +Problem: A tags file with an extremely long name may cause an infinite loop. +Solution: When encountering a long name switch to linear search. +Files: src/tag.c + + +*** ../vim-7.3.372/src/tag.c 2011-12-08 15:12:08.000000000 +0100 +--- src/tag.c 2011-12-14 14:13:28.000000000 +0100 +*************** +*** 1854,1860 **** + + if (state == TS_BINARY && orgpat.regmatch.rm_ic && !sortic) + { +! /* binary search won't work for ignoring case, use linear + * search. */ + linear = TRUE; + state = TS_LINEAR; +--- 1854,1860 ---- + + if (state == TS_BINARY && orgpat.regmatch.rm_ic && !sortic) + { +! /* Binary search won't work for ignoring case, use linear + * search. */ + linear = TRUE; + state = TS_LINEAR; +*************** +*** 1922,1927 **** +--- 1922,1940 ---- + MSG(_("Ignoring long line in tags file")); + verbose_leave(); + } ++ #ifdef FEAT_TAG_BINS ++ if (state != TS_LINEAR) ++ { ++ /* Avoid getting stuck. */ ++ linear = TRUE; ++ state = TS_LINEAR; ++ # ifdef HAVE_FSEEKO ++ fseeko(fp, search_info.low_offset, SEEK_SET); ++ # else ++ fseek(fp, (long)search_info.low_offset, SEEK_SET); ++ # endif ++ } ++ #endif + continue; + } + +*** ../vim-7.3.372/src/version.c 2011-12-08 18:44:47.000000000 +0100 +--- src/version.c 2011-12-14 14:12:06.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 373, + /**/ + +-- +ZOOT: I'm afraid our life must seem very dull and quiet compared to yours. + We are but eightscore young blondes, all between sixteen and + nineteen-and-a-half, cut off in this castle, with no one to protect us. + Oooh. It is a lonely life ... bathing ... dressing ... undressing ... + making exciting underwear.... + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 916666d6530d1894d896c0d1938aa381171b62e0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:56 +0100 Subject: [PATCH 0092/3340] - patchlevel 374 --- 7.3.374 | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.374 diff --git a/7.3.374 b/7.3.374 new file mode 100644 index 00000000..b312828a --- /dev/null +++ b/7.3.374 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.374 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.374 +Problem: ++encoding does not work properly. +Solution: Recognize ++encoding before ++enc. (Charles Cooper) +Files: src/ex_docmd.c + + +*** ../vim-7.3.373/src/ex_docmd.c 2011-10-20 21:58:20.000000000 +0200 +--- src/ex_docmd.c 2011-12-14 14:46:05.000000000 +0100 +*************** +*** 4840,4851 **** + #ifdef FEAT_MBYTE + else if (STRNCMP(arg, "enc", 3) == 0) + { +! arg += 3; +! pp = &eap->force_enc; +! } +! else if (STRNCMP(arg, "encoding", 8) == 0) +! { +! arg += 8; + pp = &eap->force_enc; + } + else if (STRNCMP(arg, "bad", 3) == 0) +--- 4840,4849 ---- + #ifdef FEAT_MBYTE + else if (STRNCMP(arg, "enc", 3) == 0) + { +! if (STRNCMP(arg, "encoding", 8) == 0) +! arg += 8; +! else +! arg += 3; + pp = &eap->force_enc; + } + else if (STRNCMP(arg, "bad", 3) == 0) +*** ../vim-7.3.373/src/version.c 2011-12-14 14:15:12.000000000 +0100 +--- src/version.c 2011-12-14 14:44:01.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 374, + /**/ + +-- +Linux is just like a wigwam: no Windows, no Gates and an Apache inside. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b1adb41c41a6e8562b556a560949a42534ca1524 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:57 +0100 Subject: [PATCH 0093/3340] - patchlevel 375 --- 7.3.375 | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 7.3.375 diff --git a/7.3.375 b/7.3.375 new file mode 100644 index 00000000..6f15fea1 --- /dev/null +++ b/7.3.375 @@ -0,0 +1,64 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.375 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.375 +Problem: Duplicate return statement. +Solution: Remove the superfluous one. (Dominique Pelle) +Files: src/gui_mac.c + + +*** ../vim-7.3.374/src/gui_mac.c 2011-06-19 01:14:22.000000000 +0200 +--- src/gui_mac.c 2011-12-10 17:20:59.000000000 +0100 +*************** +*** 3216,3222 **** + { + /* TODO: + * This proc is called when Normal is set to a value +! * so what msut be done? I don't know + */ + } + +--- 3216,3222 ---- + { + /* TODO: + * This proc is called when Normal is set to a value +! * so what must be done? I don't know + */ + } + +*************** +*** 3303,3309 **** + *x = bounds.left; + *y = bounds.top; + return OK; +- return FAIL; + } + + /* +--- 3303,3308 ---- +*** ../vim-7.3.374/src/version.c 2011-12-14 14:49:41.000000000 +0100 +--- src/version.c 2011-12-14 15:06:01.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 375, + /**/ + +-- +GALAHAD: No look, really, this isn't nescess ... +PIGLET: We must examine you. +GALAHAD: There's nothing wrong with ... that. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b6aa031038994d3769401b48b1a5eeb9acaae349 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:57 +0100 Subject: [PATCH 0094/3340] - patchlevel 376 --- 7.3.376 | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 7.3.376 diff --git a/7.3.376 b/7.3.376 new file mode 100644 index 00000000..1e20743e --- /dev/null +++ b/7.3.376 @@ -0,0 +1,57 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.376 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.376 +Problem: Win32: Toolbar repainting does not work when the mouse pointer + hovers over a button. +Solution: Call DefWindowProc() when not handling an event. (Sergiu Dotenco) +Files: src/gui_w32.c + + +*** ../vim-7.3.375/src/gui_w32.c 2011-08-10 17:07:56.000000000 +0200 +--- src/gui_w32.c 2011-12-14 15:14:48.000000000 +0100 +*************** +*** 1101,1107 **** + return MyWindowProc(hwnd, uMsg, wParam, lParam); + } + +! return 1; + } + + /* +--- 1101,1107 ---- + return MyWindowProc(hwnd, uMsg, wParam, lParam); + } + +! return DefWindowProc(hwnd, uMsg, wParam, lParam); + } + + /* +*** ../vim-7.3.375/src/version.c 2011-12-14 15:07:11.000000000 +0100 +--- src/version.c 2011-12-14 15:23:10.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 376, + /**/ + +-- + GALAHAD hurries to the door and pushes through it. As he leaves the room + we CUT TO the reverse to show that he is now in a room full of bathing + and romping GIRLIES, all innocent, wide-eyed and beautiful. They smile + enchantingly at him as he tries to keep walking without being diverted by + the lovely sights assaulting his eyeballs. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ccc43770cc7acd17bf95e3f8b215d735eedbef32 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:57 +0100 Subject: [PATCH 0095/3340] - patchlevel 377 --- 7.3.377 | 406 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 406 insertions(+) create mode 100644 7.3.377 diff --git a/7.3.377 b/7.3.377 new file mode 100644 index 00000000..1a2df1d5 --- /dev/null +++ b/7.3.377 @@ -0,0 +1,406 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.377 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.377 +Problem: No support for bitwise AND, OR, XOR and invert. +Solution: Add and(), or(), invert() and xor() functions. +Files: src/eval.c, src/testdir/test49.in, src/testdir/test65.in, + src/testdir/test65.ok, runtime/doc/eval.txt + + +*** ../vim-7.3.376/src/eval.c 2011-11-30 15:19:25.000000000 +0100 +--- src/eval.c 2011-12-11 13:49:31.000000000 +0100 +*************** +*** 474,479 **** +--- 474,480 ---- + static void f_acos __ARGS((typval_T *argvars, typval_T *rettv)); + #endif + static void f_add __ARGS((typval_T *argvars, typval_T *rettv)); ++ static void f_and __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_append __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_argc __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_argidx __ARGS((typval_T *argvars, typval_T *rettv)); +*************** +*** 602,607 **** +--- 603,609 ---- + static void f_inputsave __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_inputsecret __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_insert __ARGS((typval_T *argvars, typval_T *rettv)); ++ static void f_invert __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_isdirectory __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_islocked __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_items __ARGS((typval_T *argvars, typval_T *rettv)); +*************** +*** 640,645 **** +--- 642,648 ---- + #endif + static void f_nextnonblank __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_nr2char __ARGS((typval_T *argvars, typval_T *rettv)); ++ static void f_or __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_pathshorten __ARGS((typval_T *argvars, typval_T *rettv)); + #ifdef FEAT_FLOAT + static void f_pow __ARGS((typval_T *argvars, typval_T *rettv)); +*************** +*** 751,756 **** +--- 754,760 ---- + static void f_winsaveview __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_winwidth __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_writefile __ARGS((typval_T *argvars, typval_T *rettv)); ++ static void f_xor __ARGS((typval_T *argvars, typval_T *rettv)); + + static int list2fpos __ARGS((typval_T *arg, pos_T *posp, int *fnump)); + static pos_T *var2fpos __ARGS((typval_T *varp, int dollar_lnum, int *fnum)); +*************** +*** 7715,7720 **** +--- 7719,7725 ---- + {"acos", 1, 1, f_acos}, /* WJMc */ + #endif + {"add", 2, 2, f_add}, ++ {"and", 2, 2, f_and}, + {"append", 2, 2, f_append}, + {"argc", 0, 0, f_argc}, + {"argidx", 0, 0, f_argidx}, +*************** +*** 7850,7855 **** +--- 7855,7861 ---- + {"inputsave", 0, 0, f_inputsave}, + {"inputsecret", 1, 2, f_inputsecret}, + {"insert", 2, 3, f_insert}, ++ {"invert", 1, 1, f_invert}, + {"isdirectory", 1, 1, f_isdirectory}, + {"islocked", 1, 1, f_islocked}, + {"items", 1, 1, f_items}, +*************** +*** 7888,7893 **** +--- 7894,7900 ---- + #endif + {"nextnonblank", 1, 1, f_nextnonblank}, + {"nr2char", 1, 1, f_nr2char}, ++ {"or", 2, 2, f_or}, + {"pathshorten", 1, 1, f_pathshorten}, + #ifdef FEAT_FLOAT + {"pow", 2, 2, f_pow}, +*************** +*** 7999,8004 **** +--- 8006,8012 ---- + {"winsaveview", 0, 0, f_winsaveview}, + {"winwidth", 1, 1, f_winwidth}, + {"writefile", 2, 3, f_writefile}, ++ {"xor", 2, 2, f_xor}, + }; + + #if defined(FEAT_CMDL_COMPL) || defined(PROTO) +*************** +*** 8572,8577 **** +--- 8580,8597 ---- + } + + /* ++ * "and(expr, expr)" function ++ */ ++ static void ++ f_and(argvars, rettv) ++ typval_T *argvars; ++ typval_T *rettv; ++ { ++ rettv->vval.v_number = get_tv_number_chk(&argvars[0], NULL) ++ & get_tv_number_chk(&argvars[1], NULL); ++ } ++ ++ /* + * "append(lnum, string/list)" function + */ + static void +*************** +*** 12958,12963 **** +--- 12978,12994 ---- + } + + /* ++ * "invert(expr)" function ++ */ ++ static void ++ f_invert(argvars, rettv) ++ typval_T *argvars; ++ typval_T *rettv; ++ { ++ rettv->vval.v_number = ~get_tv_number_chk(&argvars[0], NULL); ++ } ++ ++ /* + * "isdirectory()" function + */ + static void +*************** +*** 14108,14113 **** +--- 14139,14156 ---- + } + + /* ++ * "or(expr, expr)" function ++ */ ++ static void ++ f_or(argvars, rettv) ++ typval_T *argvars; ++ typval_T *rettv; ++ { ++ rettv->vval.v_number = get_tv_number_chk(&argvars[0], NULL) ++ | get_tv_number_chk(&argvars[1], NULL); ++ } ++ ++ /* + * "pathshorten()" function + */ + static void +*************** +*** 18394,18399 **** +--- 18437,18455 ---- + } + + /* ++ * "xor(expr, expr)" function ++ */ ++ static void ++ f_xor(argvars, rettv) ++ typval_T *argvars; ++ typval_T *rettv; ++ { ++ rettv->vval.v_number = get_tv_number_chk(&argvars[0], NULL) ++ ^ get_tv_number_chk(&argvars[1], NULL); ++ } ++ ++ ++ /* + * Translate a String variable into a position. + * Returns NULL when there is an error. + */ +*** ../vim-7.3.376/src/testdir/test65.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test65.in 2011-12-11 13:55:06.000000000 +0100 +*************** +*** 1,4 **** +! Test for floating point. + + STARTTEST + :so small.vim +--- 1,4 ---- +! Test for floating point and logical operators. + + STARTTEST + :so small.vim +*************** +*** 72,77 **** +--- 72,94 ---- + :$put ='float2nr' + :$put =float2nr(123.456) + :$put =float2nr(-123.456) ++ :$put ='AND' ++ :$put =and(127, 127) ++ :$put =and(127, 16) ++ :$put =and(127, 128) ++ :$put ='OR' ++ :$put =or(16, 7) ++ :$put =or(8, 7) ++ :$put =or(0, 123) ++ :$put ='XOR' ++ :$put =xor(127, 127) ++ :$put =xor(127, 16) ++ :$put =xor(127, 128) ++ :$put ='invert' ++ :$put =and(invert(127), 65535) ++ :$put =and(invert(16), 65535) ++ :$put =and(invert(128), 65535) ++ :$put =invert(1.0) + :/^Results/,$wq! test.out + ENDTEST + +*** ../vim-7.3.376/src/testdir/test65.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test65.ok 2011-12-11 13:55:30.000000000 +0100 +*************** +*** 54,56 **** +--- 54,73 ---- + float2nr + 123 + -123 ++ AND ++ 127 ++ 16 ++ 0 ++ OR ++ 23 ++ 15 ++ 123 ++ XOR ++ 0 ++ 111 ++ 255 ++ invert ++ 65408 ++ 65519 ++ 65407 ++ 0 +*** ../vim-7.3.376/runtime/doc/eval.txt 2011-06-19 02:55:32.000000000 +0200 +--- runtime/doc/eval.txt 2011-12-14 15:28:23.000000000 +0100 +*************** +*** 798,808 **** + For |Lists| only "+" is possible and then both expr6 must be a list. The + result is a new list with the two lists Concatenated. + +! expr7 * expr7 .. number multiplication *expr-star* +! expr7 / expr7 .. number division *expr-/* +! expr7 % expr7 .. number modulo *expr-%* + + For all, except ".", Strings are converted to Numbers. + + Note the difference between "+" and ".": + "123" + "456" = 579 +--- 800,811 ---- + For |Lists| only "+" is possible and then both expr6 must be a list. The + result is a new list with the two lists Concatenated. + +! expr7 * expr7 .. Number multiplication *expr-star* +! expr7 / expr7 .. Number division *expr-/* +! expr7 % expr7 .. Number modulo *expr-%* + + For all, except ".", Strings are converted to Numbers. ++ For bitwise operators see |and()|, |or()| and |xor()|. + + Note the difference between "+" and ".": + "123" + "456" = 579 +*************** +*** 1679,1684 **** +--- 1688,1694 ---- + abs( {expr}) Float or Number absolute value of {expr} + acos( {expr}) Float arc cosine of {expr} + add( {list}, {item}) List append {item} to |List| {list} ++ and( {expr}, {expr}) Number bitwise AND + append( {lnum}, {string}) Number append {string} below line {lnum} + append( {lnum}, {list}) Number append lines {list} below line {lnum} + argc() Number number of files in the argument list +*************** +*** 1817,1822 **** +--- 1827,1833 ---- + inputsave() Number save and clear typeahead + inputsecret( {prompt} [, {text}]) String like input() but hiding the text + insert( {list}, {item} [, {idx}]) List insert {item} in {list} [before {idx}] ++ invert( {expr}) Number bitwise invert + isdirectory( {directory}) Number TRUE if {directory} is a directory + islocked( {expr}) Number TRUE if {expr} is locked + items( {dict}) List key-value pairs in {dict} +*************** +*** 1856,1861 **** +--- 1868,1874 ---- + mzeval( {expr}) any evaluate |MzScheme| expression + nextnonblank( {lnum}) Number line nr of non-blank line >= {lnum} + nr2char( {expr}) String single char with ASCII value {expr} ++ or( {expr}, {expr}) Number bitwise OR + pathshorten( {expr}) String shorten directory names in a path + pow( {x}, {y}) Float {x} to the power of {y} + prevnonblank( {lnum}) Number line nr of non-blank line <= {lnum} +*************** +*** 1978,1983 **** +--- 1992,1998 ---- + winwidth( {nr}) Number width of window {nr} + writefile( {list}, {fname} [, {binary}]) + Number write list of lines to file {fname} ++ xor( {expr}, {expr}) Number bitwise XOR + + abs({expr}) *abs()* + Return the absolute value of {expr}. When {expr} evaluates to +*************** +*** 2017,2022 **** +--- 2032,2044 ---- + Use |insert()| to add an item at another position. + + ++ and({expr}, {expr}) *and()* ++ Bitwise AND on the two arguments. The arguments are converted ++ to a number. A List, Dict or Float argument causes an error. ++ Example: > ++ :let flag = and(bits, 0x80) ++ ++ + append({lnum}, {expr}) *append()* + When {expr} is a |List|: Append each item of the |List| as a + text line below line {lnum} in the current buffer. +*************** +*** 3770,3775 **** +--- 3798,3808 ---- + Note that when {item} is a |List| it is inserted as a single + item. Use |extend()| to concatenate |Lists|. + ++ invert({expr}) *invert()* ++ Bitwise invert. The argument is converted to a number. A ++ List, Dict or Float argument causes an error. Example: > ++ :let bits = invert(bits) ++ + isdirectory({directory}) *isdirectory()* + The result is a Number, which is non-zero when a directory + with the name {directory} exists. If {directory} doesn't +*************** +*** 4334,4339 **** +--- 4368,4380 ---- + call setpos('.', save_cursor) + < Also see |setpos()|. + ++ or({expr}, {expr}) *or()* ++ Bitwise OR on the two arguments. The arguments are converted ++ to a number. A List, Dict or Float argument causes an error. ++ Example: > ++ :let bits = or(bits, 0x80) ++ ++ + pathshorten({expr}) *pathshorten()* + Shorten directory names in the path {expr} and return the + result. The tail, the file name, is kept as-is. The other +*************** +*** 6097,6103 **** + To copy a file byte for byte: > + :let fl = readfile("foo", "b") + :call writefile(fl, "foocopy", "b") +! < + + *feature-list* + There are three types of features: +--- 6149,6163 ---- + To copy a file byte for byte: > + :let fl = readfile("foo", "b") + :call writefile(fl, "foocopy", "b") +! +! +! xor({expr}, {expr}) *xor()* +! Bitwise XOR on the two arguments. The arguments are converted +! to a number. A List, Dict or Float argument causes an error. +! Example: > +! :let bits = xor(bits, 0x80) +! +! + + *feature-list* + There are three types of features: +*** ../vim-7.3.376/src/version.c 2011-12-14 15:23:53.000000000 +0100 +--- src/version.c 2011-12-14 15:28:39.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 377, + /**/ + +-- +DINGO: Wicked wicked Zoot ... she is a bad person and she must pay the + penalty. And here in Castle Anthrax, we have but one punishment + ... you must tie her down on a bed ... and spank her. Come! +GIRLS: A spanking! A spanking! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 29bed3789ae3727dda6d0625f1bb30566681a3c6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:58 +0100 Subject: [PATCH 0096/3340] - patchlevel 378 --- 7.3.378 | 71 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) create mode 100644 7.3.378 diff --git a/7.3.378 b/7.3.378 new file mode 100644 index 00000000..8ad3d703 --- /dev/null +++ b/7.3.378 @@ -0,0 +1,71 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.378 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.378 +Problem: When cross-compiling the check for uint32_t fails. +Solution: Only give a warning message. (Maksim Melnikau) +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.377/src/configure.in 2011-12-08 15:17:28.000000000 +0100 +--- src/configure.in 2011-12-14 19:18:36.000000000 +0100 +*************** +*** 3283,3289 **** + }], + AC_MSG_RESULT(ok), + AC_MSG_ERROR([WRONG! uint32_t not defined correctly.]), +! AC_MSG_ERROR([could not compile program using uint32_t.])) + + dnl Check for memmove() before bcopy(), makes memmove() be used when both are + dnl present, fixes problem with incompatibility between Solaris 2.4 and 2.5. +--- 3283,3289 ---- + }], + AC_MSG_RESULT(ok), + AC_MSG_ERROR([WRONG! uint32_t not defined correctly.]), +! AC_MSG_WARN([cannot check uint32_t when cross-compiling.])) + + dnl Check for memmove() before bcopy(), makes memmove() be used when both are + dnl present, fixes problem with incompatibility between Solaris 2.4 and 2.5. +*** ../vim-7.3.377/src/auto/configure 2011-12-08 15:17:28.000000000 +0100 +--- src/auto/configure 2011-12-14 19:20:55.000000000 +0100 +*************** +*** 11777,11783 **** + { $as_echo "$as_me:${as_lineno-$LINENO}: checking uint32_t is 32 bits" >&5 + $as_echo_n "checking uint32_t is 32 bits... " >&6; } + if test "$cross_compiling" = yes; then : +! as_fn_error "could not compile program using uint32_t." "$LINENO" 5 + else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ +--- 11777,11784 ---- + { $as_echo "$as_me:${as_lineno-$LINENO}: checking uint32_t is 32 bits" >&5 + $as_echo_n "checking uint32_t is 32 bits... " >&6; } + if test "$cross_compiling" = yes; then : +! { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check uint32_t when cross-compiling." >&5 +! $as_echo "$as_me: WARNING: cannot check uint32_t when cross-compiling." >&2;} + else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ +*** ../vim-7.3.377/src/version.c 2011-12-14 15:32:44.000000000 +0100 +--- src/version.c 2011-12-14 19:21:08.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 378, + /**/ + +-- + ### Hiroshima 45, Chernobyl 86, Windows 95 ### + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 527dd279be99adba2de9d8e228239fbfbc3f8d8a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:58 +0100 Subject: [PATCH 0097/3340] - patchlevel 379 --- 7.3.379 | 112 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 112 insertions(+) create mode 100644 7.3.379 diff --git a/7.3.379 b/7.3.379 new file mode 100644 index 00000000..fd87f9a1 --- /dev/null +++ b/7.3.379 @@ -0,0 +1,112 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.379 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.379 +Problem: C-indenting wrong for static enum. +Solution: Skip over "static". (Lech Lorens) +Files: src/misc1.c, src/testdir/test3.in, src/testdir/test3.ok + + +*** ../vim-7.3.378/src/misc1.c 2011-11-30 17:20:18.000000000 +0100 +--- src/misc1.c 2011-12-14 19:37:48.000000000 +0100 +*************** +*** 5138,5143 **** +--- 5138,5146 ---- + if (STRNCMP(s, "typedef", 7) == 0 && !vim_isIDc(s[7])) + s = cin_skipcomment(s + 7); + ++ if (STRNCMP(s, "static", 6) == 0 && !vim_isIDc(s[6])) ++ s = cin_skipcomment(s + 6); ++ + if (STRNCMP(s, "enum", 4) == 0 && !vim_isIDc(s[4])) + return TRUE; + +*** ../vim-7.3.378/src/testdir/test3.in 2011-11-30 17:20:18.000000000 +0100 +--- src/testdir/test3.in 2011-12-14 20:03:11.000000000 +0100 +*************** +*** 299,316 **** + + enum soppie + { +! yes = 0, +! no, +! maybe + }; + + typedef enum soppie + { +! yes = 0, +! no, +! maybe + }; + + { + int a, + b; +--- 299,323 ---- + + enum soppie + { +! yes = 0, +! no, +! maybe + }; + + typedef enum soppie + { +! yes = 0, +! no, +! maybe + }; + ++ static enum ++ { ++ yes = 0, ++ no, ++ maybe ++ } soppie; ++ + { + int a, + b; +*** ../vim-7.3.378/src/testdir/test3.ok 2011-11-30 17:20:18.000000000 +0100 +--- src/testdir/test3.ok 2011-12-14 19:37:48.000000000 +0100 +*************** +*** 299,304 **** +--- 299,311 ---- + maybe + }; + ++ static enum ++ { ++ yes = 0, ++ no, ++ maybe ++ } soppie; ++ + { + int a, + b; +*** ../vim-7.3.378/src/version.c 2011-12-14 19:22:29.000000000 +0100 +--- src/version.c 2011-12-14 20:02:19.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 379, + /**/ + +-- +You cannot propel yourself forward by patting yourself on the back. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b77daeee411542ab07658217908e796878e4172e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:58 +0100 Subject: [PATCH 0098/3340] - patchlevel 380 --- 7.3.380 | 318 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 318 insertions(+) create mode 100644 7.3.380 diff --git a/7.3.380 b/7.3.380 new file mode 100644 index 00000000..a8f4bcf6 --- /dev/null +++ b/7.3.380 @@ -0,0 +1,318 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.380 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.380 +Problem: C-indenting wrong for a function header. +Solution: Skip to the start paren. (Lech Lorens) +Files: src/misc1.c, src/testdir/test3.in, src/testdir/test3.ok + + +*** ../vim-7.3.379/src/misc1.c 2011-12-14 20:05:17.000000000 +0100 +--- src/misc1.c 2011-12-14 20:16:43.000000000 +0100 +*************** +*** 4943,4949 **** + static int cin_islinecomment __ARGS((char_u *)); + static int cin_isterminated __ARGS((char_u *, int, int)); + static int cin_isinit __ARGS((void)); +! static int cin_isfuncdecl __ARGS((char_u **, linenr_T)); + static int cin_isif __ARGS((char_u *)); + static int cin_iselse __ARGS((char_u *)); + static int cin_isdo __ARGS((char_u *)); +--- 4943,4949 ---- + static int cin_islinecomment __ARGS((char_u *)); + static int cin_isterminated __ARGS((char_u *, int, int)); + static int cin_isinit __ARGS((void)); +! static int cin_isfuncdecl __ARGS((char_u **, linenr_T, linenr_T, int, int)); + static int cin_isif __ARGS((char_u *)); + static int cin_iselse __ARGS((char_u *)); + static int cin_isdo __ARGS((char_u *)); +*************** +*** 5585,5605 **** + * "sp" points to a string with the line. When looking at other lines it must + * be restored to the line. When it's NULL fetch lines here. + * "lnum" is where we start looking. + */ + static int +! cin_isfuncdecl(sp, first_lnum) + char_u **sp; + linenr_T first_lnum; + { + char_u *s; + linenr_T lnum = first_lnum; + int retval = FALSE; + + if (sp == NULL) + s = ml_get(lnum); + else + s = *sp; + + /* Ignore line starting with #. */ + if (cin_ispreproc(s)) + return FALSE; +--- 5585,5621 ---- + * "sp" points to a string with the line. When looking at other lines it must + * be restored to the line. When it's NULL fetch lines here. + * "lnum" is where we start looking. ++ * "min_lnum" is the line before which we will not be looking. + */ + static int +! cin_isfuncdecl(sp, first_lnum, min_lnum, ind_maxparen, ind_maxcomment) + char_u **sp; + linenr_T first_lnum; ++ linenr_T min_lnum; ++ int ind_maxparen; ++ int ind_maxcomment; + { + char_u *s; + linenr_T lnum = first_lnum; + int retval = FALSE; ++ pos_T *trypos; ++ int just_started = TRUE; + + if (sp == NULL) + s = ml_get(lnum); + else + s = *sp; + ++ if (find_last_paren(s, '(', ')') ++ && (trypos = find_match_paren(ind_maxparen, ind_maxcomment)) != NULL) ++ { ++ lnum = trypos->lnum; ++ if (lnum < min_lnum) ++ return FALSE; ++ ++ s = ml_get(lnum); ++ } ++ + /* Ignore line starting with #. */ + if (cin_ispreproc(s)) + return FALSE; +*************** +*** 5650,5662 **** + /* Require a comma at end of the line or a comma or ')' at the + * start of next line. */ + s = skipwhite(s); +! if (!comma && *s != ',' && *s != ')') + break; + } + else if (cin_iscomment(s)) /* ignore comments */ + s = cin_skipcomment(s); + else + ++s; + } + + done: +--- 5666,5682 ---- + /* Require a comma at end of the line or a comma or ')' at the + * start of next line. */ + s = skipwhite(s); +! if (!just_started && (!comma && *s != ',' && *s != ')')) + break; ++ just_started = FALSE; + } + else if (cin_iscomment(s)) /* ignore comments */ + s = cin_skipcomment(s); + else ++ { + ++s; ++ just_started = FALSE; ++ } + } + + done: +*************** +*** 7158,7164 **** + * (it's a variable declaration). + */ + if (start_brace != BRACE_IN_COL0 +! || !cin_isfuncdecl(&l, curwin->w_cursor.lnum)) + { + /* if the line is terminated with another ',' + * it is a continued variable initialization. +--- 7178,7185 ---- + * (it's a variable declaration). + */ + if (start_brace != BRACE_IN_COL0 +! || !cin_isfuncdecl(&l, curwin->w_cursor.lnum, +! 0, ind_maxparen, ind_maxcomment)) + { + /* if the line is terminated with another ',' + * it is a continued variable initialization. +*************** +*** 8019,8025 **** + && vim_strchr(theline, '}') == NULL + && !cin_ends_in(theline, (char_u *)":", NULL) + && !cin_ends_in(theline, (char_u *)",", NULL) +! && cin_isfuncdecl(NULL, cur_curpos.lnum + 1) + && !cin_isterminated(theline, FALSE, TRUE)) + { + amount = ind_func_type; +--- 8040,8048 ---- + && vim_strchr(theline, '}') == NULL + && !cin_ends_in(theline, (char_u *)":", NULL) + && !cin_ends_in(theline, (char_u *)",", NULL) +! && cin_isfuncdecl(NULL, cur_curpos.lnum + 1, +! cur_curpos.lnum + 1, +! ind_maxparen, ind_maxcomment) + && !cin_isterminated(theline, FALSE, TRUE)) + { + amount = ind_func_type; +*************** +*** 8125,8131 **** + * If the line looks like a function declaration, and we're + * not in a comment, put it the left margin. + */ +! if (cin_isfuncdecl(NULL, cur_curpos.lnum)) /* XXX */ + break; + l = ml_get_curline(); + +--- 8148,8155 ---- + * If the line looks like a function declaration, and we're + * not in a comment, put it the left margin. + */ +! if (cin_isfuncdecl(NULL, cur_curpos.lnum, 0, +! ind_maxparen, ind_maxcomment)) /* XXX */ + break; + l = ml_get_curline(); + +*************** +*** 8173,8179 **** + * line (and the ones that follow) needs to be indented as + * parameters. + */ +! if (cin_isfuncdecl(&l, curwin->w_cursor.lnum)) + { + amount = ind_param; + break; +--- 8197,8204 ---- + * line (and the ones that follow) needs to be indented as + * parameters. + */ +! if (cin_isfuncdecl(&l, curwin->w_cursor.lnum, 0, +! ind_maxparen, ind_maxcomment)) + { + amount = ind_param; + break; +*** ../vim-7.3.379/src/testdir/test3.in 2011-12-14 20:05:17.000000000 +0100 +--- src/testdir/test3.in 2011-12-14 20:11:24.000000000 +0100 +*************** +*** 1429,1435 **** + + STARTTEST + :set cino& +! 2kdd=4][ + ENDTEST + + void func(void) +--- 1429,1435 ---- + + STARTTEST + :set cino& +! 2kdd=7][ + ENDTEST + + void func(void) +*************** +*** 1478,1484 **** + 3, 4, + 5, 6}; + +! printf("Don't you dare indent this line incorrectly!\n); + } + + STARTTEST +--- 1478,1506 ---- + 3, 4, + 5, 6}; + +! printf("Don't you dare indent this line incorrectly!\n"); +! } +! +! void +! func4(a, b, +! c) +! int a; +! int b; +! int c; +! { +! } +! +! void +! func5( +! int a, +! int b) +! { +! } +! +! void +! func6( +! int a) +! { + } + + STARTTEST +*** ../vim-7.3.379/src/testdir/test3.ok 2011-12-14 20:05:17.000000000 +0100 +--- src/testdir/test3.ok 2011-12-14 20:11:24.000000000 +0100 +*************** +*** 1331,1337 **** + 3, 4, + 5, 6}; + +! printf("Don't you dare indent this line incorrectly!\n); + } + + +--- 1331,1359 ---- + 3, 4, + 5, 6}; + +! printf("Don't you dare indent this line incorrectly!\n"); +! } +! +! void +! func4(a, b, +! c) +! int a; +! int b; +! int c; +! { +! } +! +! void +! func5( +! int a, +! int b) +! { +! } +! +! void +! func6( +! int a) +! { + } + + +*** ../vim-7.3.379/src/version.c 2011-12-14 20:05:17.000000000 +0100 +--- src/version.c 2011-12-14 20:20:50.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 380, + /**/ + +-- +"Intelligence has much less practical application than you'd think." + -- Scott Adams, Dilbert. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e7b51d82c7735057c8da6d865fbcffb0ca09e260 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:59 +0100 Subject: [PATCH 0099/3340] - patchlevel 381 --- 7.3.381 | 260 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 260 insertions(+) create mode 100644 7.3.381 diff --git a/7.3.381 b/7.3.381 new file mode 100644 index 00000000..b7957379 --- /dev/null +++ b/7.3.381 @@ -0,0 +1,260 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.381 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.381 +Problem: Configure silently skips interfaces that won't work. +Solution: Add the --enable-fail_if_missing argument. (Shlomi Fish) +Files: src/Makefile, src/configure.in, src/auto/configure + + +*** ../vim-7.3.380/src/Makefile 2011-12-08 15:17:28.000000000 +0100 +--- src/Makefile 2011-12-14 20:49:26.000000000 +0100 +*************** +*** 389,394 **** +--- 389,399 ---- + #CONF_OPT_PLTHOME = --with-plthome=/usr/local/drscheme + #CONF_OPT_PLTHOME = --with-plthome=/home/me/mz + ++ # Uncomment the next line to fail if one of the requested language interfaces ++ # cannot be configured. Without this Vim will be build anyway, without ++ # the failing interfaces. ++ #CONF_OPT_FAIL = --enable-fail-if-missing ++ + # PERL + # Uncomment one of these when you want to include the Perl interface. + # First one is for static linking, second one for dynamic loading. +*************** +*** 1648,1654 **** + CC="$(CC)" CPPFLAGS="$(CPPFLAGS)" CFLAGS="$(CFLAGS)" \ + LDFLAGS="$(LDFLAGS)" $(CONF_SHELL) srcdir="$(srcdir)" \ + ./configure $(CONF_OPT_GUI) $(CONF_OPT_X) $(CONF_OPT_XSMP) \ +! $(CONF_OPT_DARWIN) $(CONF_OPT_PERL) $(CONF_OPT_PYTHON) $(CONF_OPT_PYTHON3) \ + $(CONF_OPT_TCL) $(CONF_OPT_RUBY) $(CONF_OPT_NLS) \ + $(CONF_OPT_CSCOPE) $(CONF_OPT_MULTIBYTE) $(CONF_OPT_INPUT) \ + $(CONF_OPT_OUTPUT) $(CONF_OPT_GPM) $(CONF_OPT_WORKSHOP) \ +--- 1653,1660 ---- + CC="$(CC)" CPPFLAGS="$(CPPFLAGS)" CFLAGS="$(CFLAGS)" \ + LDFLAGS="$(LDFLAGS)" $(CONF_SHELL) srcdir="$(srcdir)" \ + ./configure $(CONF_OPT_GUI) $(CONF_OPT_X) $(CONF_OPT_XSMP) \ +! $(CONF_OPT_DARWIN) $(CONF_OPT_FAIL) \ +! $(CONF_OPT_PERL) $(CONF_OPT_PYTHON) $(CONF_OPT_PYTHON3) \ + $(CONF_OPT_TCL) $(CONF_OPT_RUBY) $(CONF_OPT_NLS) \ + $(CONF_OPT_CSCOPE) $(CONF_OPT_MULTIBYTE) $(CONF_OPT_INPUT) \ + $(CONF_OPT_OUTPUT) $(CONF_OPT_GPM) $(CONF_OPT_WORKSHOP) \ +*** ../vim-7.3.380/src/configure.in 2011-12-14 19:22:29.000000000 +0100 +--- src/configure.in 2011-12-14 20:46:36.000000000 +0100 +*************** +*** 28,33 **** +--- 28,43 ---- + AC_HEADER_STDC + AC_HEADER_SYS_WAIT + ++ dnl Check for the flag that fails if stuff are missing. ++ ++ AC_MSG_CHECKING(--enable-fail-if-missing argument) ++ AC_ARG_ENABLE(fail_if_missing, ++ [ --enable-fail-if-missing Fail if dependencies on additional features ++ specified on the command line are missing.], ++ [fail_if_missing="yes"], ++ [fail_if_missing="no"]) ++ AC_MSG_RESULT($fail_if_missing) ++ + dnl Set default value for CFLAGS if none is defined or it's empty + if test -z "$CFLAGS"; then + CFLAGS="-O" +*************** +*** 491,496 **** +--- 501,509 ---- + LUA_CFLAGS="-DDYNAMIC_LUA_DLL=\\\"liblua${vi_cv_version_lua}.so$LUA_SONAME\\\" $LUA_CFLAGS" + fi + fi ++ if test "$fail_if_missing" = "yes" -a -z "$LUA_SRC"; then ++ AC_MSG_ERROR([could not configure lua]) ++ fi + AC_SUBST(LUA_SRC) + AC_SUBST(LUA_OBJ) + AC_SUBST(LUA_PRO) +*************** +*** 781,786 **** +--- 794,803 ---- + PERL_CFLAGS="-DDYNAMIC_PERL_DLL=\\\"$libperl\\\" $PERL_CFLAGS" + fi + fi ++ ++ if test "$fail_if_missing" = "yes" -a "$perl_ok" != "yes"; then ++ AC_MSG_ERROR([could not configure perl]) ++ fi + fi + AC_SUBST(shrpenv) + AC_SUBST(PERL_SRC) +*************** +*** 966,971 **** +--- 983,992 ---- + AC_MSG_RESULT(too old) + fi + fi ++ ++ if test "$fail_if_missing" = "yes" -a "$python_ok" != "yes"; then ++ AC_MSG_ERROR([could not configure python]) ++ fi + fi + + AC_SUBST(PYTHON_CONFDIR) +*************** +*** 1389,1394 **** +--- 1410,1418 ---- + AC_MSG_RESULT(too old; need Tcl version 8.0 or later) + fi + fi ++ if test "$fail_if_missing" = "yes" -a -z "$TCL_SRC"; then ++ AC_MSG_ERROR([could not configure Tcl]) ++ fi + fi + AC_SUBST(TCL_SRC) + AC_SUBST(TCL_OBJ) +*************** +*** 1469,1474 **** +--- 1493,1502 ---- + AC_MSG_RESULT(too old; need Ruby version 1.6.0 or later) + fi + fi ++ ++ if test "$fail_if_missing" = "yes" -a -z "$RUBY_OBJ"; then ++ AC_MSG_ERROR([could not configure Ruby]) ++ fi + fi + AC_SUBST(RUBY_SRC) + AC_SUBST(RUBY_OBJ) +*** ../vim-7.3.380/src/auto/configure 2011-12-14 19:22:29.000000000 +0100 +--- src/auto/configure 2011-12-14 20:49:51.000000000 +0100 +*************** +*** 741,746 **** +--- 741,747 ---- + ac_subst_files='' + ac_user_opts=' + enable_option_checking ++ enable_fail_if_missing + enable_darwin + with_mac_arch + with_developer_dir +*************** +*** 1418,1423 **** +--- 1419,1426 ---- + --disable-option-checking ignore unrecognized --enable/--with options + --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) + --enable-FEATURE[=ARG] include FEATURE [ARG=yes] ++ --enable-fail-if-missing Fail if dependencies on additional features ++ specified on the command line are missing. + --disable-darwin Disable Darwin (Mac OS X) support. + --disable-selinux Don't check for SELinux support. + --disable-xsmp Disable XSMP session management +*************** +*** 3949,3954 **** +--- 3952,3970 ---- + fi + + ++ ++ { $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-fail-if-missing argument" >&5 ++ $as_echo_n "checking --enable-fail-if-missing argument... " >&6; } ++ # Check whether --enable-fail_if_missing was given. ++ if test "${enable_fail_if_missing+set}" = set; then : ++ enableval=$enable_fail_if_missing; fail_if_missing="yes" ++ else ++ fail_if_missing="no" ++ fi ++ ++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $fail_if_missing" >&5 ++ $as_echo "$fail_if_missing" >&6; } ++ + if test -z "$CFLAGS"; then + CFLAGS="-O" + test "$GCC" = yes && CFLAGS="-O2 -fno-strength-reduce -Wall" +*************** +*** 4727,4732 **** +--- 4743,4751 ---- + LUA_CFLAGS="-DDYNAMIC_LUA_DLL=\\\"liblua${vi_cv_version_lua}.so$LUA_SONAME\\\" $LUA_CFLAGS" + fi + fi ++ if test "$fail_if_missing" = "yes" -a -z "$LUA_SRC"; then ++ as_fn_error "could not configure lua" "$LINENO" 5 ++ fi + + + +*************** +*** 5140,5145 **** +--- 5159,5168 ---- + PERL_CFLAGS="-DDYNAMIC_PERL_DLL=\\\"$libperl\\\" $PERL_CFLAGS" + fi + fi ++ ++ if test "$fail_if_missing" = "yes" -a "$perl_ok" != "yes"; then ++ as_fn_error "could not configure perl" "$LINENO" 5 ++ fi + fi + + +*************** +*** 5429,5434 **** +--- 5452,5461 ---- + $as_echo "too old" >&6; } + fi + fi ++ ++ if test "$fail_if_missing" = "yes" -a "$python_ok" != "yes"; then ++ as_fn_error "could not configure python" "$LINENO" 5 ++ fi + fi + + +*************** +*** 6216,6221 **** +--- 6243,6251 ---- + $as_echo "too old; need Tcl version 8.0 or later" >&6; } + fi + fi ++ if test "$fail_if_missing" = "yes" -a -z "$TCL_SRC"; then ++ as_fn_error "could not configure Tcl" "$LINENO" 5 ++ fi + fi + + +*************** +*** 6353,6358 **** +--- 6383,6392 ---- + $as_echo "too old; need Ruby version 1.6.0 or later" >&6; } + fi + fi ++ ++ if test "$fail_if_missing" = "yes" -a -z "$RUBY_OBJ"; then ++ as_fn_error "could not configure Ruby" "$LINENO" 5 ++ fi + fi + + +*** ../vim-7.3.380/src/version.c 2011-12-14 20:21:29.000000000 +0100 +--- src/version.c 2011-12-14 20:50:42.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 381, + /**/ + +-- +The psychic said, "God bless you." I said, "I didn't sneeze." She +looked deep into my eyes and said, "You will, eventually." And, damn +if she wasn't right. Two days later, I sneezed. --Ellen Degeneres + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7e41f97a3f2e47859d752bc9bdfe1dbbebbc9b6b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:59 +0100 Subject: [PATCH 0100/3340] - patchlevel 382 --- 7.3.382 | 173 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 173 insertions(+) create mode 100644 7.3.382 diff --git a/7.3.382 b/7.3.382 new file mode 100644 index 00000000..7f344e7e --- /dev/null +++ b/7.3.382 @@ -0,0 +1,173 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.382 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.382 (after 7.3.376) +Problem: IME characters are inserted twice. +Solution: Do not call DefWindowProc() if the event was handled. (Yasuhiro + Matsumoto) +Files: src/gui_w32.c + + +*** ../vim-7.3.381/src/gui_w32.c 2011-12-14 15:23:53.000000000 +0100 +--- src/gui_w32.c 2011-12-15 21:50:51.000000000 +0100 +*************** +*** 798,804 **** + if (pt.y < rect.top) + { + show_tabline_popup_menu(); +! return 0; + } + } + return MyWindowProc(hwnd, uMsg, wParam, lParam); +--- 798,804 ---- + if (pt.y < rect.top) + { + show_tabline_popup_menu(); +! return 0L; + } + } + return MyWindowProc(hwnd, uMsg, wParam, lParam); +*************** +*** 828,834 **** +--- 828,837 ---- + + case WM_ENDSESSION: + if (wParam) /* system only really goes down when wParam is TRUE */ ++ { + _OnEndSession(); ++ return 0L; ++ } + break; + + case WM_CHAR: +*************** +*** 866,872 **** + * are received, mouse pointer remains hidden. */ + return MyWindowProc(hwnd, uMsg, wParam, lParam); + #else +! return 0; + #endif + + case WM_SIZING: /* HANDLE_MSG doesn't seem to handle this one */ +--- 869,875 ---- + * are received, mouse pointer remains hidden. */ + return MyWindowProc(hwnd, uMsg, wParam, lParam); + #else +! return 0L; + #endif + + case WM_SIZING: /* HANDLE_MSG doesn't seem to handle this one */ +*************** +*** 874,880 **** + + case WM_MOUSEWHEEL: + _OnMouseWheel(hwnd, HIWORD(wParam)); +! break; + + /* Notification for change in SystemParametersInfo() */ + case WM_SETTINGCHANGE: +--- 877,883 ---- + + case WM_MOUSEWHEEL: + _OnMouseWheel(hwnd, HIWORD(wParam)); +! return 0L; + + /* Notification for change in SystemParametersInfo() */ + case WM_SETTINGCHANGE: +*************** +*** 987,999 **** +--- 990,1008 ---- + case TCN_SELCHANGE: + if (gui_mch_showing_tabline() + && ((LPNMHDR)lParam)->hwndFrom == s_tabhwnd) ++ { + send_tabline_event(TabCtrl_GetCurSel(s_tabhwnd) + 1); ++ return 0L; ++ } + break; + + case NM_RCLICK: + if (gui_mch_showing_tabline() + && ((LPNMHDR)lParam)->hwndFrom == s_tabhwnd) ++ { + show_tabline_popup_menu(); ++ return 0L; ++ } + break; + # endif + default: +*************** +*** 1037,1042 **** +--- 1046,1052 ---- + out_flush(); + did_menu_tip = TRUE; + } ++ return 0L; + } + break; + #endif +*************** +*** 1079,1096 **** + case WM_IME_NOTIFY: + if (!_OnImeNotify(hwnd, (DWORD)wParam, (DWORD)lParam)) + return MyWindowProc(hwnd, uMsg, wParam, lParam); +! break; + case WM_IME_COMPOSITION: + if (!_OnImeComposition(hwnd, wParam, lParam)) + return MyWindowProc(hwnd, uMsg, wParam, lParam); +! break; + #endif + + default: + if (uMsg == msh_msgmousewheel && msh_msgmousewheel != 0) + { /* handle MSH_MOUSEWHEEL messages for Intellimouse */ + _OnMouseWheel(hwnd, HIWORD(wParam)); +! break; + } + #ifdef MSWIN_FIND_REPLACE + else if (uMsg == s_findrep_msg && s_findrep_msg != 0) +--- 1089,1107 ---- + case WM_IME_NOTIFY: + if (!_OnImeNotify(hwnd, (DWORD)wParam, (DWORD)lParam)) + return MyWindowProc(hwnd, uMsg, wParam, lParam); +! return 1L; +! + case WM_IME_COMPOSITION: + if (!_OnImeComposition(hwnd, wParam, lParam)) + return MyWindowProc(hwnd, uMsg, wParam, lParam); +! return 1L; + #endif + + default: + if (uMsg == msh_msgmousewheel && msh_msgmousewheel != 0) + { /* handle MSH_MOUSEWHEEL messages for Intellimouse */ + _OnMouseWheel(hwnd, HIWORD(wParam)); +! return 0L; + } + #ifdef MSWIN_FIND_REPLACE + else if (uMsg == s_findrep_msg && s_findrep_msg != 0) +*** ../vim-7.3.381/src/version.c 2011-12-14 20:51:19.000000000 +0100 +--- src/version.c 2011-12-15 21:48:49.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 382, + /**/ + +-- +Even got a Datapoint 3600(?) with a DD50 connector instead of the +usual DB25... what a nightmare trying to figure out the pinout +for *that* with no spex... + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d672a9b04bf5fe03e1c0995bd3bd0193e2775b90 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:30:59 +0100 Subject: [PATCH 0101/3340] - patchlevel 383 --- 7.3.383 | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 7.3.383 diff --git a/7.3.383 b/7.3.383 new file mode 100644 index 00000000..c0ce6d90 --- /dev/null +++ b/7.3.383 @@ -0,0 +1,51 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.383 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.383 +Problem: For EBCDIC pound sign is defined as 't'. +Solution: Correctly define POUND. +Files: src/ascii.h + + +*** ../vim-7.3.382/src/ascii.h 2011-09-02 14:18:14.000000000 +0200 +--- src/ascii.h 2011-12-17 21:38:36.000000000 +0100 +*************** +*** 123,129 **** + #define DCS 0x90 /* Device Control String */ + #define STERM 0x9c /* String Terminator */ + +! #define POUND '\xA3' + + #define CTRL_F_STR "\056" + #define CTRL_H_STR "\026" +--- 123,129 ---- + #define DCS 0x90 /* Device Control String */ + #define STERM 0x9c /* String Terminator */ + +! #define POUND 0xB1 + + #define CTRL_F_STR "\056" + #define CTRL_H_STR "\026" +*** ../vim-7.3.382/src/version.c 2011-12-15 21:51:32.000000000 +0100 +--- src/version.c 2011-12-23 12:46:08.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 383, + /**/ + +-- +Vim is like Emacs without all the typing. (John "Johann" Spetz) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ace30519c964832e615e8ef4c017fdb44f5a7af7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:31:00 +0100 Subject: [PATCH 0102/3340] - patchlevel 384 --- 7.3.384 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.384 diff --git a/7.3.384 b/7.3.384 new file mode 100644 index 00000000..f75ff408 --- /dev/null +++ b/7.3.384 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.384 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.384 +Problem: Mapping CTRL-K in Insert mode breaks CTRL-X CTRL-K for dictionary + completion. +Solution: Add CTRL-K to the list of recognized keys. (James McCoy) +Files: src/edit.c + + +*** ../vim-7.3.383/src/edit.c 2011-10-26 17:04:23.000000000 +0200 +--- src/edit.c 2011-12-23 12:36:22.000000000 +0100 +*************** +*** 2183,2189 **** + || c == Ctrl_I || c == Ctrl_D || c == Ctrl_P + || c == Ctrl_N || c == Ctrl_T || c == Ctrl_V + || c == Ctrl_Q || c == Ctrl_U || c == Ctrl_O +! || c == Ctrl_S || c == 's'); + case CTRL_X_SCROLL: + return (c == Ctrl_Y || c == Ctrl_E); + case CTRL_X_WHOLE_LINE: +--- 2183,2189 ---- + || c == Ctrl_I || c == Ctrl_D || c == Ctrl_P + || c == Ctrl_N || c == Ctrl_T || c == Ctrl_V + || c == Ctrl_Q || c == Ctrl_U || c == Ctrl_O +! || c == Ctrl_S || c == Ctrl_K || c == 's'); + case CTRL_X_SCROLL: + return (c == Ctrl_Y || c == Ctrl_E); + case CTRL_X_WHOLE_LINE: +*** ../vim-7.3.383/src/version.c 2011-12-23 12:46:56.000000000 +0100 +--- src/version.c 2011-12-23 12:53:38.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 384, + /**/ + +-- +Q: Is selling software the same as selling hardware? +A: No, good hardware is sold new, good software has already been used by many. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From afd011b494e016bd386ecf72cb0a4c14cf85df9a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:31:00 +0100 Subject: [PATCH 0103/3340] - patchlevel 385 --- 7.3.385 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.385 diff --git a/7.3.385 b/7.3.385 new file mode 100644 index 00000000..405a77f0 --- /dev/null +++ b/7.3.385 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.385 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.385 +Problem: When using an expression mapping on the command line the cursor + ends up in the wrong place. (Yasuhiro Matsumoto) +Solution: Save and restore msg_col and msg_row when evaluating the + expression. +Files: src/getchar. + + +*** ../vim-7.3.384/src/getchar.c 2011-10-12 22:02:07.000000000 +0200 +--- src/getchar.c 2011-12-14 18:37:52.000000000 +0100 +*************** +*** 4510,4515 **** +--- 4510,4517 ---- + char_u *expr; + char_u *save_cmd; + pos_T save_cursor; ++ int save_msg_col; ++ int save_msg_row; + + /* Remove escaping of CSI, because "str" is in a format to be used as + * typeahead. */ +*************** +*** 4533,4544 **** +--- 4535,4550 ---- + #endif + set_vim_var_char(c); /* set v:char to the typed character */ + save_cursor = curwin->w_cursor; ++ save_msg_col = msg_col; ++ save_msg_row = msg_row; + p = eval_to_string(expr, NULL, FALSE); + --textlock; + #ifdef FEAT_EX_EXTRA + --ex_normal_lock; + #endif + curwin->w_cursor = save_cursor; ++ msg_col = save_msg_col; ++ msg_row = save_msg_row; + + restore_cmdline_alloc(save_cmd); + vim_free(expr); +*** ../vim-7.3.384/src/version.c 2011-12-23 13:14:58.000000000 +0100 +--- src/version.c 2011-12-23 14:53:23.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 385, + /**/ + +-- +`When any government, or any church for that matter, undertakes to say to + its subjects, "This you may not read, this you must not see, this you are + forbidden to know," the end result is tyranny and oppression no matter how + holy the motives' -- Robert A Heinlein, "If this goes on --" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From af844f6fd98c00b1f1ad085228c54ed62c2037fe Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:31:01 +0100 Subject: [PATCH 0104/3340] - patchlevel 386 --- 7.3.386 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.386 diff --git a/7.3.386 b/7.3.386 new file mode 100644 index 00000000..c9035050 --- /dev/null +++ b/7.3.386 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.386 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.386 +Problem: Test 83 fails when iconv does not support cp932. (raf) +Solution: Test if conversion works. (Yukihiro Nakadaira) +Files: src/testdir/test83.in + + +*** ../vim-7.3.385/src/testdir/test83.in 2011-10-12 19:53:31.000000000 +0200 +--- src/testdir/test83.in 2011-12-21 21:01:44.000000000 +0100 +*************** +*** 2,8 **** + + STARTTEST + :so mbyte.vim +! :if !has('iconv') + : e! test.ok + : w! test.out + : qa! +--- 2,8 ---- + + STARTTEST + :so mbyte.vim +! :if !has('iconv') || iconv("\x82\x60", "cp932", "utf-8") != "\uff21" + : e! test.ok + : w! test.out + : qa! +*** ../vim-7.3.385/src/version.c 2011-12-23 14:54:01.000000000 +0100 +--- src/version.c 2011-12-23 14:55:38.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 386, + /**/ + +-- +WOMAN: King of the who? +ARTHUR: The Britons. +WOMAN: Who are the Britons? +ARTHUR: Well, we all are. we're all Britons and I am your king. + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 42964609b2109ae3ab74c855a8d56c1ab37c7561 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:31:01 +0100 Subject: [PATCH 0105/3340] - patchlevel 386 --- README.patches | 64 ++++++++++++++++++++++++ vim.spec | 133 ++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 196 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index 1dc2a793..0e3c8efd 100644 --- a/README.patches +++ b/README.patches @@ -353,3 +353,67 @@ Individual patches for Vim 7.3: 3363 7.3.320 0xa0 character in sourced file is hard to spot 7855 7.3.321 code not following Vim style 1585 7.3.322 #ifdef for PDP_RETVAL doesn't work, INT_PTR can be a typedef + 3022 7.3.323 the default 'efm' does not ignore some "included from" lines + 1676 7.3.324 (after 7.3.237) completion for ":compiler" shows color schemes + 1901 7.3.325 a duplicated function argument gives an internal error + 8244 7.3.326 MingW 4.6 no longer supports the -mno-cygwin option + 1902 7.3.327 when jumping to a help tag a closed fold doesn't open + 1487 7.3.328 wrapping command line displays wrong multi-byte cursor + 2337 7.3.329 error when skipping over dict function inside :for + 1340 7.3.330 state not properly restored when longjmp() is invoked + 1815 7.3.331 "vit" gets confused when one tag name starts contains another + 4994 7.3.332 indent after "public:" is not increased in C++ code + 7688 7.3.333 "." repeats a Visual delete by byte size instead of characters + 1710 7.3.334 latest MingW complains about XSUBPP referencing itself + 1532 7.3.335 changing 'imdisable' in Insert mode takes effect only later + 30504 7.3.336 encoding in tags file causes trouble + 1876 7.3.337 no screen update after resizing xterm until character typed + 2851 7.3.338 using getchar() in an expression mapping doesn't work well + 1762 7.3.339 "make shadow" doesn't link all test files + 1887 7.3.340 when 'verbosefile' is set ftplugof.vim can give an error + 9335 7.3.341 translated and local help files are not listed in help.* + 3079 7.3.342 code not in Vim style + 6949 7.3.343 no mouse support for urxvt + 3131 7.3.344 problem with GUI startup related to XInitThreads + 1395 7.3.345 window title not updated when switching language with ":lang" + 5238 7.3.346 it's hard to test netbeans commands + 1689 7.3.347 dropped text is HTML although "html" is not in 'clipboard' + 1634 7.3.348 "call range(1, 947948399)" causes a crash + 2793 7.3.349 opening swapfile loops forever when out of memory in startup + 1525 7.3.350 block of code after ":lua << EOF" may not work + 1453 7.3.351 text formatting uses insert start position when it should not + 3276 7.3.352 when completing functions script-local functions come first + 4245 7.3.353 (after 7.3.343) missing urxvt patch for term.c + 2182 7.3.354 ":set backspace+=eol" doesn't work when 'backspace' is 2 + 1683 7.3.355 GTK warnings when using netrw.vim + 2453 7.3.356 using "o" with 'cindent' set may freeze Vim + 1511 7.3.357 compiler warning in MS-Windows console build + 1994 7.3.358 (after 7.3.353) mouse support doesn't work properly + 1727 7.3.359 command line completion shows dict functions + 2183 7.3.360 interrupting autoload function load may cause a crash + 1733 7.3.361 accessing memory after it is freed when EXITFREE is defined + 1828 7.3.362 ml_get error when using ":g" with folded lines + 2914 7.3.363 C indenting is wrong after #endif followed by a semicolon + 1924 7.3.364 (after 7.3.353) can't compile on HP-UX + 3451 7.3.365 crash when using a large Unicode character with syntax highl. + 2192 7.3.366 a tags file with an extremely long name causes errors + 1650 7.3.367 :wundo and :rundo use a wrong checksum + 4734 7.3.368 gcc complains about redefining _FORTIFY_SOURCE + 1452 7.3.369 get an error message when using --help and compiled with Gnome + 1766 7.3.370 compiler warns for unused variable in Lua interface + 2155 7.3.371 crash in autocomplete + 1603 7.3.372 command line mapping to doesn't work for file completion + 2464 7.3.373 (after 7.3.366) infinite loop in tags file with long name + 1670 7.3.374 ++encoding is not recognized + 1716 7.3.375 duplicate return statement + 1817 7.3.376 Win32: Toolbar repainting not always right + 12178 7.3.377 no support for bitwise AND, OR, XOR and invert + 2773 7.3.378 configure fails when cross-compiling + 2257 7.3.379 C-indenting wrong for static enum + 7825 7.3.380 C-indenting wrong for function header + 7960 7.3.381 configure can't be told to stop when a language is unavailable + 4585 7.3.382 (after 7.3.376) IME characters are inserted twice + 1489 7.3.383 for EBCDIC pound sign is defined as 't' + 1869 7.3.384 mapping CTRL-K breaks CTRL-X CTRL-K for dictionary completion + 2220 7.3.385 with expression mapping cursor may end up in the wrong place + 1577 7.3.386 test 83 fails when iconv does not support cp932 diff --git a/vim.spec b/vim.spec index f9886639..e33122f2 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 322 +%define patchlevel 386 Summary: The VIM editor URL: http://www.vim.org/ @@ -376,6 +376,70 @@ Patch319: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.319 Patch320: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.320 Patch321: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.321 Patch322: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.322 +Patch323: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.323 +Patch324: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.324 +Patch325: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.325 +Patch326: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.326 +Patch327: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.327 +Patch328: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.328 +Patch329: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.329 +Patch330: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.330 +Patch331: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.331 +Patch332: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.332 +Patch333: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.333 +Patch334: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.334 +Patch335: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.335 +Patch336: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.336 +Patch337: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.337 +Patch338: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.338 +Patch339: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.339 +Patch340: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.340 +Patch341: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.341 +Patch342: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.342 +Patch343: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.343 +Patch344: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.344 +Patch345: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.345 +Patch346: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.346 +Patch347: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.347 +Patch348: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.348 +Patch349: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.349 +Patch350: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.350 +Patch351: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.351 +Patch352: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.352 +Patch353: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.353 +Patch354: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.354 +Patch355: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.355 +Patch356: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.356 +Patch357: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.357 +Patch358: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.358 +Patch359: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.359 +Patch360: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.360 +Patch361: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.361 +Patch362: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.362 +Patch363: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.363 +Patch364: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.364 +Patch365: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.365 +Patch366: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.366 +Patch367: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.367 +Patch368: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.368 +Patch369: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.369 +Patch370: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.370 +Patch371: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.371 +Patch372: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.372 +Patch373: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.373 +Patch374: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.374 +Patch375: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.375 +Patch376: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.376 +Patch377: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.377 +Patch378: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.378 +Patch379: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.379 +Patch380: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.380 +Patch381: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.381 +Patch382: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.382 +Patch383: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.383 +Patch384: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.384 +Patch385: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.385 +Patch386: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.386 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -840,6 +904,70 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch320 -p0 %patch321 -p0 %patch322 -p0 +%patch323 -p0 +%patch324 -p0 +%patch325 -p0 +%patch326 -p0 +%patch327 -p0 +%patch328 -p0 +%patch329 -p0 +%patch330 -p0 +%patch331 -p0 +%patch332 -p0 +%patch333 -p0 +%patch334 -p0 +%patch335 -p0 +%patch336 -p0 +%patch337 -p0 +%patch338 -p0 +%patch339 -p0 +%patch340 -p0 +%patch341 -p0 +%patch342 -p0 +%patch343 -p0 +%patch344 -p0 +%patch345 -p0 +%patch346 -p0 +%patch347 -p0 +%patch348 -p0 +%patch349 -p0 +%patch350 -p0 +%patch351 -p0 +%patch352 -p0 +%patch353 -p0 +%patch354 -p0 +%patch355 -p0 +%patch356 -p0 +%patch357 -p0 +%patch358 -p0 +%patch359 -p0 +%patch360 -p0 +%patch361 -p0 +%patch362 -p0 +%patch363 -p0 +%patch364 -p0 +%patch365 -p0 +%patch366 -p0 +%patch367 -p0 +%patch368 -p0 +%patch369 -p0 +%patch370 -p0 +%patch371 -p0 +%patch372 -p0 +%patch373 -p0 +%patch374 -p0 +%patch375 -p0 +%patch376 -p0 +%patch377 -p0 +%patch378 -p0 +%patch379 -p0 +%patch380 -p0 +%patch381 -p0 +%patch382 -p0 +%patch383 -p0 +%patch384 -p0 +%patch385 -p0 +%patch386 -p0 # install spell files @@ -1297,6 +1425,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Fri Dec 23 2011 Karsten Hopp 7.3.386-1 +- patchlevel 386 + * Mon Sep 26 2011 Karsten Hopp 7.3.322-1 - patchlevel 322 From f1da73308321351f0fd76b6aa1514029e9875af7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 22:43:29 +0100 Subject: [PATCH 0106/3340] fix boolean key 'Termina' in gvim.desktop --- gvim.desktop | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gvim.desktop b/gvim.desktop index 4f0d294e..97bf6ac8 100644 --- a/gvim.desktop +++ b/gvim.desktop @@ -58,7 +58,7 @@ MimeType=text/english;text/plain;text/x-makefile;text/x-c++hdr;text/x-c++src;tex Exec=gvim -f %F Icon=gvim Type=Application -Terminal=0 +Terminal=false X-XClassHintResName=VIM MapNotify=false Categories=Utility;TextEditor; From 5fb26504866e5625323996710f908bc8cb646c1f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 23 Dec 2011 23:02:11 +0100 Subject: [PATCH 0107/3340] next attempt to fix boolean syntax --- gvim.desktop | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gvim.desktop b/gvim.desktop index 97bf6ac8..35527372 100644 --- a/gvim.desktop +++ b/gvim.desktop @@ -58,7 +58,7 @@ MimeType=text/english;text/plain;text/x-makefile;text/x-c++hdr;text/x-c++src;tex Exec=gvim -f %F Icon=gvim Type=Application -Terminal=false +Terminal="false" X-XClassHintResName=VIM MapNotify=false Categories=Utility;TextEditor; From e66e3bcc5093bfd36bd0327b3fca81b2148997d0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 5 Jan 2012 12:44:52 +0100 Subject: [PATCH 0108/3340] - patchlevel 387 --- 7.3.387 | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 7.3.387 diff --git a/7.3.387 b/7.3.387 new file mode 100644 index 00000000..6b20a58a --- /dev/null +++ b/7.3.387 @@ -0,0 +1,61 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.387 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.387 (after 7.3.386) +Problem: Test 83 may fail for some encodings. +Solution: Set 'encoding' to utf-8 earlier. +Files: src/testdir/test83.in + + +*** ../vim-7.3.386/src/testdir/test83.in 2011-12-23 14:56:24.000000000 +0100 +--- src/testdir/test83.in 2011-12-30 13:05:05.000000000 +0100 +*************** +*** 2,13 **** + + STARTTEST + :so mbyte.vim + :if !has('iconv') || iconv("\x82\x60", "cp932", "utf-8") != "\uff21" + : e! test.ok + : w! test.out + : qa! + :endif +- :set enc=utf8 + + :/^text for tags1$/,/^text for tags1$/+1w! Xtags1.txt + :/^text for tags2$/,/^text for tags2$/+1w! Xtags2.txt +--- 2,13 ---- + + STARTTEST + :so mbyte.vim ++ :set enc=utf8 + :if !has('iconv') || iconv("\x82\x60", "cp932", "utf-8") != "\uff21" + : e! test.ok + : w! test.out + : qa! + :endif + + :/^text for tags1$/,/^text for tags1$/+1w! Xtags1.txt + :/^text for tags2$/,/^text for tags2$/+1w! Xtags2.txt +*** ../vim-7.3.386/src/version.c 2011-12-23 14:56:24.000000000 +0100 +--- src/version.c 2011-12-30 13:06:17.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 387, + /**/ + +-- +Mental Floss prevents moral decay! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a14d21f58a9498f202aba6f405f874da6bb4e00a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 5 Jan 2012 12:44:55 +0100 Subject: [PATCH 0109/3340] - patchlevel 388 --- 7.3.388 | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 7.3.388 diff --git a/7.3.388 b/7.3.388 new file mode 100644 index 00000000..7a6df895 --- /dev/null +++ b/7.3.388 @@ -0,0 +1,45 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.388 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.388 +Problem: Crash on exit when EXITFREE is defined and using tiny features. +Solution: Check for NULL window pointer. (Dominique Pelle) +Files: src/buffer.c + + +*** ../vim-7.3.387/src/buffer.c 2011-11-30 15:40:51.000000000 +0100 +--- src/buffer.c 2011-12-30 13:35:26.000000000 +0100 +*************** +*** 419,424 **** +--- 419,426 ---- + if ( + #ifdef FEAT_WINDOWS + win_valid(win) && ++ #else ++ win != NULL && + #endif + win->w_buffer == buf) + win->w_buffer = NULL; /* make sure we don't use the buffer now */ +*** ../vim-7.3.387/src/version.c 2011-12-30 13:09:15.000000000 +0100 +--- src/version.c 2011-12-30 13:37:23.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 388, + /**/ + +-- +Be nice to your kids... they'll be the ones choosing your nursing home. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c28513f6345ea6cc7a8b6567d1623c458825645a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 5 Jan 2012 12:44:56 +0100 Subject: [PATCH 0110/3340] - patchlevel 389 --- 7.3.389 | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 7.3.389 diff --git a/7.3.389 b/7.3.389 new file mode 100644 index 00000000..c8a968c3 --- /dev/null +++ b/7.3.389 @@ -0,0 +1,61 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.389 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.389 +Problem: After typing at a prompt the "MORE" message appears too soon. +Solution: reset lines_left in msg_end_prompt(). (Eswald) +Files: src/message.c + + +*** ../vim-7.3.388/src/message.c 2011-09-14 15:39:26.000000000 +0200 +--- src/message.c 2011-12-30 14:08:05.000000000 +0100 +*************** +*** 85,91 **** + * need_wait_return to be set. This is a hack to make ":ts" + * work without an extra prompt. + * lines_left Number of lines available for messages before the +! * more-prompt is to be given. + * need_wait_return TRUE when the hit-return prompt is needed. + * Reset: After giving the hit-return prompt, when the user + * has answered some other prompt. +--- 85,91 ---- + * need_wait_return to be set. This is a hack to make ":ts" + * work without an extra prompt. + * lines_left Number of lines available for messages before the +! * more-prompt is to be given. -1 when not set. + * need_wait_return TRUE when the hit-return prompt is needed. + * Reset: After giving the hit-return prompt, when the user + * has answered some other prompt. +*************** +*** 855,860 **** +--- 855,861 ---- + cmdline_row = msg_row; + msg_col = 0; + msg_clr_eos(); ++ lines_left = -1; + } + #endif + +*** ../vim-7.3.388/src/version.c 2011-12-30 13:39:04.000000000 +0100 +--- src/version.c 2011-12-30 14:11:00.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 389, + /**/ + +-- +Proofread carefully to see if you any words out. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ce80b874cfef9d4bdf698b611201c947a58e7587 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 5 Jan 2012 12:44:57 +0100 Subject: [PATCH 0111/3340] - patchlevel 390 --- 7.3.390 | 155 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 155 insertions(+) create mode 100644 7.3.390 diff --git a/7.3.390 b/7.3.390 new file mode 100644 index 00000000..7199f8e1 --- /dev/null +++ b/7.3.390 @@ -0,0 +1,155 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.390 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.390 +Problem: Using NULL buffer pointer in a window. +Solution: Check for w_buffer being NULL in more places. (Bjorn Winckler) +Files: src/ex_cmds.c, src/quickfix.c, src/window.c + + +*** ../vim-7.3.389/src/ex_cmds.c 2011-11-30 17:01:55.000000000 +0100 +--- src/ex_cmds.c 2011-12-30 14:59:57.000000000 +0100 +*************** +*** 3390,3395 **** +--- 3390,3402 ---- + (flags & ECMD_HIDE) ? 0 : DOBUF_UNLOAD); + + #ifdef FEAT_AUTOCMD ++ /* Autocommands may open a new window and leave oldwin open ++ * which leads to crashes since the above call sets ++ * oldwin->w_buffer to NULL. */ ++ if (curwin != oldwin && oldwin != aucmd_win ++ && win_valid(oldwin) && oldwin->w_buffer == NULL) ++ win_close(oldwin, FALSE); ++ + # ifdef FEAT_EVAL + if (aborting()) /* autocmds may abort script processing */ + { +*** ../vim-7.3.389/src/quickfix.c 2011-08-10 18:36:49.000000000 +0200 +--- src/quickfix.c 2011-12-30 14:45:19.000000000 +0100 +*************** +*** 2675,2681 **** + bt_quickfix(buf) + buf_T *buf; + { +! return (buf->b_p_bt[0] == 'q'); + } + + /* +--- 2675,2681 ---- + bt_quickfix(buf) + buf_T *buf; + { +! return buf != NULL && buf->b_p_bt[0] == 'q'; + } + + /* +*************** +*** 2686,2693 **** + bt_nofile(buf) + buf_T *buf; + { +! return (buf->b_p_bt[0] == 'n' && buf->b_p_bt[2] == 'f') +! || buf->b_p_bt[0] == 'a'; + } + + /* +--- 2686,2693 ---- + bt_nofile(buf) + buf_T *buf; + { +! return buf != NULL && ((buf->b_p_bt[0] == 'n' && buf->b_p_bt[2] == 'f') +! || buf->b_p_bt[0] == 'a'); + } + + /* +*************** +*** 2697,2703 **** + bt_dontwrite(buf) + buf_T *buf; + { +! return (buf->b_p_bt[0] == 'n'); + } + + int +--- 2697,2703 ---- + bt_dontwrite(buf) + buf_T *buf; + { +! return buf != NULL && buf->b_p_bt[0] == 'n'; + } + + int +*** ../vim-7.3.389/src/window.c 2011-09-14 14:43:21.000000000 +0200 +--- src/window.c 2011-12-30 14:44:18.000000000 +0100 +*************** +*** 2170,2176 **** + + /* When closing the help window, try restoring a snapshot after closing + * the window. Otherwise clear the snapshot, it's now invalid. */ +! if (win->w_buffer->b_help) + help_window = TRUE; + else + clear_snapshot(curtab, SNAP_HELP_IDX); +--- 2170,2176 ---- + + /* When closing the help window, try restoring a snapshot after closing + * the window. Otherwise clear the snapshot, it's now invalid. */ +! if (win->w_buffer != NULL && win->w_buffer->b_help) + help_window = TRUE; + else + clear_snapshot(curtab, SNAP_HELP_IDX); +*************** +*** 2214,2226 **** + + #ifdef FEAT_SYN_HL + /* Free independent synblock before the buffer is freed. */ +! reset_synblock(win); + #endif + + /* + * Close the link to the buffer. + */ +! close_buffer(win, win->w_buffer, free_buf ? DOBUF_UNLOAD : 0); + + /* Autocommands may have closed the window already, or closed the only + * other window or moved to another tab page. */ +--- 2214,2228 ---- + + #ifdef FEAT_SYN_HL + /* Free independent synblock before the buffer is freed. */ +! if (win->w_buffer != NULL) +! reset_synblock(win); + #endif + + /* + * Close the link to the buffer. + */ +! if (win->w_buffer != NULL) +! close_buffer(win, win->w_buffer, free_buf ? DOBUF_UNLOAD : 0); + + /* Autocommands may have closed the window already, or closed the only + * other window or moved to another tab page. */ +*** ../vim-7.3.389/src/version.c 2011-12-30 14:14:16.000000000 +0100 +--- src/version.c 2011-12-30 14:38:39.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 390, + /**/ + +-- +There can't be a crisis today, my schedule is already full. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bb6a0a61e4fcfedb3a577b18d8439a5e3006cff5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 5 Jan 2012 12:44:58 +0100 Subject: [PATCH 0112/3340] - patchlevel 391 --- 7.3.391 | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 7.3.391 diff --git a/7.3.391 b/7.3.391 new file mode 100644 index 00000000..0a1bcceb --- /dev/null +++ b/7.3.391 @@ -0,0 +1,51 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.391 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.391 +Problem: Can't check if the XPM_W32 feature is enabled. +Solution: Add xpm_w32 to the list of features. (kat) +Files: src/eval.c + + +*** ../vim-7.3.390/src/eval.c 2011-12-14 15:32:44.000000000 +0100 +--- src/eval.c 2012-01-04 14:33:22.000000000 +0100 +*************** +*** 12260,12265 **** +--- 12260,12268 ---- + #ifdef FEAT_XFONTSET + "xfontset", + #endif ++ #ifdef FEAT_XPM_W32 ++ "xpm_w32", ++ #endif + #ifdef USE_XSMP + "xsmp", + #endif +*** ../vim-7.3.390/src/version.c 2011-12-30 15:01:55.000000000 +0100 +--- src/version.c 2012-01-04 14:34:31.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 391, + /**/ + +-- +ROBIN: The what? +ARTHUR: The Holy Hand Grenade of Antioch. 'Tis one of the sacred relics + Brother Maynard always carries with him. +ALL: Yes. Of course. +ARTHUR: (shouting) Bring up the Holy Hand Grenade! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From eb674223efa197443bbb362cd5200ac9e10c9255 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 5 Jan 2012 12:44:58 +0100 Subject: [PATCH 0113/3340] - patchlevel 392 --- 7.3.392 | 115 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 115 insertions(+) create mode 100644 7.3.392 diff --git a/7.3.392 b/7.3.392 new file mode 100644 index 00000000..a603d90e --- /dev/null +++ b/7.3.392 @@ -0,0 +1,115 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.392 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.392 +Problem: When setting 'undofile' while the file is already loaded but + unchanged, try reading the undo file. (Andy Wokula) +Solution: Compute a checksum of the text when 'undofile' is set. (Christian + Brabandt) +Files: src/option.c, src/testdir/test72.in, src/testdir/test72.ok + + +*** ../vim-7.3.391/src/option.c 2011-11-30 11:31:25.000000000 +0100 +--- src/option.c 2012-01-04 19:34:11.000000000 +0100 +*************** +*** 7516,7521 **** +--- 7516,7545 ---- + compatible_set(); + } + ++ #ifdef FEAT_PERSISTENT_UNDO ++ /* 'undofile' */ ++ else if ((int *)varp == &curbuf->b_p_udf || (int *)varp == &p_udf) ++ { ++ char_u hash[UNDO_HASH_SIZE]; ++ buf_T *save_curbuf = curbuf; ++ ++ for (curbuf = firstbuf; curbuf != NULL; curbuf = curbuf->b_next) ++ { ++ /* When 'undofile' is set globally: for every buffer, otherwise ++ * only for the current buffer: Try to read in the undofile, if ++ * one exists and the buffer wasn't changed. */ ++ if ((curbuf == save_curbuf ++ || (opt_flags & OPT_GLOBAL) || opt_flags == 0) ++ && !curbufIsChanged()) ++ { ++ u_compute_hash(hash); ++ u_read_undo(NULL, hash, curbuf->b_fname); ++ } ++ } ++ curbuf = save_curbuf; ++ } ++ #endif ++ + /* 'list', 'number' */ + else if ((int *)varp == &curwin->w_p_list + || (int *)varp == &curwin->w_p_nu +*** ../vim-7.3.391/src/testdir/test72.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test72.in 2012-01-04 19:04:17.000000000 +0100 +*************** +*** 51,56 **** +--- 51,62 ---- + :e Xtestfile + uuu:w >>test.out + :" ++ :" Test that reading the undofiles when setting undofile works ++ :set noundofile ul=0 ++ i ++ u:e! Xtestfile ++ :set undofile ul=100 ++ uuuuuu:w >>test.out + :" And now with encryption, cryptmethod=zip + :e! Xtestfile + :set undofile cm=zip +*** ../vim-7.3.391/src/testdir/test72.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test72.ok 2012-01-04 19:04:17.000000000 +0100 +*************** +*** 7,12 **** +--- 7,22 ---- + eight + nine + ten ++ one ++ two ++ three ++ four ++ five ++ six ++ seven ++ eight ++ nine ++ ten + monday + wednesday + thursday +*** ../vim-7.3.391/src/version.c 2012-01-04 14:35:31.000000000 +0100 +--- src/version.c 2012-01-04 19:33:41.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 392, + /**/ + +-- +BROTHER MAYNARD: Armaments Chapter Two Verses Nine to Twenty One. +ANOTHER MONK: And St. Attila raised his hand grenade up on high saying "O + Lord bless this thy hand grenade that with it thou mayest + blow thine enemies to tiny bits, in thy mercy. "and the Lord + did grin and people did feast upon the lambs and sloths and + carp and anchovies and orang-utans and breakfast cereals and + fruit bats and... +BROTHER MAYNARD: Skip a bit brother ... + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2f6f86fde976d0961a873684e3af89cc8597f82b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 5 Jan 2012 12:44:59 +0100 Subject: [PATCH 0114/3340] - patchlevel 393 --- 7.3.393 | 130 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 130 insertions(+) create mode 100644 7.3.393 diff --git a/7.3.393 b/7.3.393 new file mode 100644 index 00000000..ca6cbc96 --- /dev/null +++ b/7.3.393 @@ -0,0 +1,130 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.393 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.393 +Problem: Win32: When resizing Vim it is always moved to the primary monitor + if the secondary monitor is on the left. +Solution: Use the nearest monitor. (Yukihiro Nakadaira) +Files: src/gui_w32.c + + +*** ../vim-7.3.392/src/gui_w32.c 2011-12-15 21:51:32.000000000 +0100 +--- src/gui_w32.c 2012-01-04 20:25:58.000000000 +0100 +*************** +*** 1661,1669 **** + { + RECT workarea_rect; + int win_width, win_height; +- int win_xpos, win_ypos; + WINDOWPLACEMENT wndpl; +- int workarea_left; + + /* Try to keep window completely on screen. */ + /* Get position of the screen work area. This is the part that is not +--- 1661,1667 ---- +*************** +*** 1685,1693 **** + GetWindowPlacement(s_hwnd, &wndpl); + } + +- win_xpos = wndpl.rcNormalPosition.left; +- win_ypos = wndpl.rcNormalPosition.top; +- + /* compute the size of the outside of the window */ + win_width = width + GetSystemMetrics(SM_CXFRAME) * 2; + win_height = height + GetSystemMetrics(SM_CYFRAME) * 2 +--- 1683,1688 ---- +*************** +*** 1697,1732 **** + #endif + ; + +! /* There is an inconsistency when using two monitors and Vim is on the +! * second (right) one: win_xpos will be the offset from the workarea of +! * the left monitor. While with one monitor it's the offset from the +! * workarea (including a possible taskbar on the left). Detect the second +! * monitor by checking for the left offset to be quite big. */ +! if (workarea_rect.left > 300) +! workarea_left = 0; +! else +! workarea_left = workarea_rect.left; + +! /* If the window is going off the screen, move it on to the screen. +! * win_xpos and win_ypos are relative to the workarea. */ + if ((direction & RESIZE_HOR) +! && workarea_left + win_xpos + win_width > workarea_rect.right) +! win_xpos = workarea_rect.right - win_width - workarea_left; + +! if ((direction & RESIZE_HOR) && win_xpos < 0) +! win_xpos = 0; + + if ((direction & RESIZE_VERT) +! && workarea_rect.top + win_ypos + win_height > workarea_rect.bottom) +! win_ypos = workarea_rect.bottom - win_height - workarea_rect.top; + +! if ((direction & RESIZE_VERT) && win_ypos < 0) +! win_ypos = 0; +! +! wndpl.rcNormalPosition.left = win_xpos; +! wndpl.rcNormalPosition.right = win_xpos + win_width; +! wndpl.rcNormalPosition.top = win_ypos; +! wndpl.rcNormalPosition.bottom = win_ypos + win_height; + + /* set window position - we should use SetWindowPlacement rather than + * SetWindowPos as the MSDN docs say the coord systems returned by +--- 1692,1723 ---- + #endif + ; + +! /* The following should take care of keeping Vim on the same monitor, no +! * matter if the secondary monitor is left or right of the primary +! * monitor. */ +! wndpl.rcNormalPosition.right = wndpl.rcNormalPosition.left + win_width; +! wndpl.rcNormalPosition.bottom = wndpl.rcNormalPosition.top + win_height; + +! /* If the window is going off the screen, move it on to the screen. */ + if ((direction & RESIZE_HOR) +! && wndpl.rcNormalPosition.right > workarea_rect.right) +! OffsetRect(&wndpl.rcNormalPosition, +! workarea_rect.right - wndpl.rcNormalPosition.right, 0); + +! if ((direction & RESIZE_HOR) +! && wndpl.rcNormalPosition.left < workarea_rect.left) +! OffsetRect(&wndpl.rcNormalPosition, +! workarea_rect.left - wndpl.rcNormalPosition.left, 0); + + if ((direction & RESIZE_VERT) +! && wndpl.rcNormalPosition.bottom > workarea_rect.bottom) +! OffsetRect(&wndpl.rcNormalPosition, +! 0, workarea_rect.bottom - wndpl.rcNormalPosition.bottom); + +! if ((direction & RESIZE_VERT) +! && wndpl.rcNormalPosition.top < workarea_rect.top) +! OffsetRect(&wndpl.rcNormalPosition, +! 0, workarea_rect.top - wndpl.rcNormalPosition.top); + + /* set window position - we should use SetWindowPlacement rather than + * SetWindowPos as the MSDN docs say the coord systems returned by +*** ../vim-7.3.392/src/version.c 2012-01-04 19:34:32.000000000 +0100 +--- src/version.c 2012-01-04 20:28:57.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 393, + /**/ + +-- +I wonder, do vegetarians eat fruit bats? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9ba71d80aff5181a2e26564d75b21926d7705a8b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 5 Jan 2012 12:45:01 +0100 Subject: [PATCH 0115/3340] - patchlevel 393 --- README.patches | 7 +++++++ vim.spec | 19 ++++++++++++++++++- 2 files changed, 25 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index 0e3c8efd..d082f57c 100644 --- a/README.patches +++ b/README.patches @@ -417,3 +417,10 @@ Individual patches for Vim 7.3: 1869 7.3.384 mapping CTRL-K breaks CTRL-X CTRL-K for dictionary completion 2220 7.3.385 with expression mapping cursor may end up in the wrong place 1577 7.3.386 test 83 fails when iconv does not support cp932 + 1708 7.3.387 (after 7.3.386) test 83 may fail for some encodings + 1378 7.3.388 crash on exit when EXITFREE is defined and using tiny features + 2117 7.3.389 after typing at a prompt the "MORE" message appears too soon + 4295 7.3.390 using NULL buffer pointer in a window + 1520 7.3.391 can't check if the XPM_W32 feature is enabled + 3505 7.3.392 setting 'undofile' does not trigger reading the undo file + 4803 7.3.393 Win32: When resizing Vim it may be moved to another monitor diff --git a/vim.spec b/vim.spec index e33122f2..59908e67 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 386 +%define patchlevel 393 Summary: The VIM editor URL: http://www.vim.org/ @@ -440,6 +440,13 @@ Patch383: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.383 Patch384: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.384 Patch385: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.385 Patch386: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.386 +Patch387: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.387 +Patch388: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.388 +Patch389: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.389 +Patch390: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.390 +Patch391: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.391 +Patch392: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.392 +Patch393: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.393 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -968,6 +975,13 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch384 -p0 %patch385 -p0 %patch386 -p0 +%patch387 -p0 +%patch388 -p0 +%patch389 -p0 +%patch390 -p0 +%patch391 -p0 +%patch392 -p0 +%patch393 -p0 # install spell files @@ -1425,6 +1439,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Thu Jan 05 2012 Karsten Hopp 7.3.393-1 +- patchlevel 393 + * Fri Dec 23 2011 Karsten Hopp 7.3.386-1 - patchlevel 386 From 91311cbc1385db8657a54655dca8b27919077f6c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 5 Jan 2012 15:40:27 +0100 Subject: [PATCH 0116/3340] fix boolean key 'Terminal' in gvim.desktop --- gvim.desktop | 2 +- vim.spec | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/gvim.desktop b/gvim.desktop index 35527372..97bf6ac8 100644 --- a/gvim.desktop +++ b/gvim.desktop @@ -58,7 +58,7 @@ MimeType=text/english;text/plain;text/x-makefile;text/x-c++hdr;text/x-c++src;tex Exec=gvim -f %F Icon=gvim Type=Application -Terminal="false" +Terminal=false X-XClassHintResName=VIM MapNotify=false Categories=Utility;TextEditor; diff --git a/vim.spec b/vim.spec index 59908e67..31ae8842 100644 --- a/vim.spec +++ b/vim.spec @@ -1441,6 +1441,7 @@ rm -rf $RPM_BUILD_ROOT %changelog * Thu Jan 05 2012 Karsten Hopp 7.3.393-1 - patchlevel 393 +- fix boolean key 'Terminal' in gvim.desktop * Fri Dec 23 2011 Karsten Hopp 7.3.386-1 - patchlevel 386 From 346844e66f8bebea2b61488d39edd70249b2de11 Mon Sep 17 00:00:00 2001 From: Harald Hoyer Date: Thu, 26 Jan 2012 13:38:45 +0100 Subject: [PATCH 0117/3340] install everything in /usr This patch is needed for the /usr-move feature https://fedoraproject.org/wiki/Features/UsrMove This package requires now 'filesystem' >= 3, which is only installable on a system which has /bin, /sbin, /lib, /lib64 as symlinks to /usr and not regular directories. The 'filesystem' package acts as a guard, to prevent *this* package to be installed on old unconverted systems. New installations will have the 'filesystem' >=3 layout right away, old installations need to be converted with anaconda or dracut first; only after that, the 'filesystem' package, and also *this* package can be installed. Packages *should* not install files in /bin, /sbin, /lib, /lib64, but only in the corresponding directories in /usr. Packages *must* not install conflicting files with the same names in the corresponding directories in / and /usr. Especially compatibility symlinks must not be installed. Feel free to modify any of the changes to the spec file, but keep the above in mind. --- vim.spec | 43 +++++++++++++++++++++---------------------- 1 file changed, 21 insertions(+), 22 deletions(-) diff --git a/vim.spec b/vim.spec index 31ae8842..b39ab818 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1%{?dist} +Release: 2%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -475,6 +475,7 @@ Requires: desktop-file-utils BuildRequires: desktop-file-utils >= %{desktop_file_utils_version} %endif Epoch: 2 +Conflicts: filesystem < 3 %description VIM (VIsual editor iMproved) is an updated and improved version of the @@ -514,6 +515,7 @@ many different languages. Summary: A minimal version of the VIM editor Group: Applications/Editors Provides: vi = %{version}-%{release} +Provides: /bin/vi %description minimal VIM (VIsual editor iMproved) is an updated and improved version of the @@ -1083,7 +1085,6 @@ make VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} %{?_smp_mflags} %install rm -rf $RPM_BUILD_ROOT -mkdir -p $RPM_BUILD_ROOT/bin mkdir -p $RPM_BUILD_ROOT/%{_bindir} mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/{after,autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/after/{autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} @@ -1095,12 +1096,12 @@ rm -f README*.info cd src -make install DESTDIR=$RPM_BUILD_ROOT BINDIR=/bin VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} -make installgtutorbin DESTDIR=$RPM_BUILD_ROOT BINDIR=/bin VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} -mv $RPM_BUILD_ROOT/bin/xxd $RPM_BUILD_ROOT/%{_bindir}/xxd -mv $RPM_BUILD_ROOT/bin/gvimtutor $RPM_BUILD_ROOT/%{_bindir}/gvimtutor +make install DESTDIR=$RPM_BUILD_ROOT BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} +make installgtutorbin DESTDIR=$RPM_BUILD_ROOT BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} mkdir -p $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/{16x16,32x32,48x48,64x64}/apps -install -m755 gvim $RPM_BUILD_ROOT/%{_bindir}/gvim +install -m755 vim $RPM_BUILD_ROOT%{_bindir}/vi +install -m755 enhanced-vim $RPM_BUILD_ROOT%{_bindir}/vim +install -m755 gvim $RPM_BUILD_ROOT%{_bindir}/gvim install -p -m644 %{SOURCE7} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/16x16/apps/gvim.png install -p -m644 %{SOURCE8} \ @@ -1109,17 +1110,12 @@ install -p -m644 %{SOURCE9} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/48x48/apps/gvim.png install -p -m644 %{SOURCE10} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/64x64/apps/gvim.png -install -m755 enhanced-vim $RPM_BUILD_ROOT/%{_bindir}/vim ( cd $RPM_BUILD_ROOT - mv ./bin/vimtutor ./%{_bindir}/vimtutor - mv ./bin/vim ./bin/vi - rm -f ./bin/rvim - ln -sf vi ./bin/ex - ln -sf vi ./bin/rvi - ln -sf vi ./bin/rview - ln -sf vi ./bin/view - ln -sf vim ./%{_bindir}/ex + ln -sf vi ./%{_bindir}/rvi + ln -sf vi ./%{_bindir}/rview + ln -sf vi ./%{_bindir}/view + ln -sf vi ./%{_bindir}/ex ln -sf vim ./%{_bindir}/rvim ln -sf vim ./%{_bindir}/vimdiff perl -pi -e "s,$RPM_BUILD_ROOT,," .%{_mandir}/man1/vim.1 .%{_mandir}/man1/vimtutor.1 @@ -1382,18 +1378,17 @@ rm -rf $RPM_BUILD_ROOT %files minimal %defattr(-,root,root) %config(noreplace) %{_sysconfdir}/virc -/bin/ex -/bin/vi -/bin/view -/bin/rvi -/bin/rview +%{_bindir}/ex +%{_bindir}/vi +%{_bindir}/view +%{_bindir}/rvi +%{_bindir}/rview %files enhanced %defattr(-,root,root) %{_bindir}/vim %{_bindir}/rvim %{_bindir}/vimdiff -%{_bindir}/ex %{_bindir}/vimtutor %config(noreplace) %{_sysconfdir}/profile.d/vim.* %{_mandir}/man1/rvim.* @@ -1439,6 +1434,10 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Thu Jan 26 2012 Harald Hoyer 7.3.393-2 +- install everything in /usr + https://fedoraproject.org/wiki/Features/UsrMove + * Thu Jan 05 2012 Karsten Hopp 7.3.393-1 - patchlevel 393 - fix boolean key 'Terminal' in gvim.desktop From 1619ab79ba21b952ed1a7f7716fac065fa4134e6 Mon Sep 17 00:00:00 2001 From: Harald Hoyer Date: Thu, 26 Jan 2012 16:28:15 +0100 Subject: [PATCH 0118/3340] rebuild against the new ruby library --- vim.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vim.spec b/vim.spec index b39ab818..10c51006 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 2%{?dist} +Release: 3%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -1434,6 +1434,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Thu Jan 26 2012 Harald Hoyer 7.3.393-3 +- rebuild against the new ruby library + * Thu Jan 26 2012 Harald Hoyer 7.3.393-2 - install everything in /usr https://fedoraproject.org/wiki/Features/UsrMove From 80a1b0c0855321c7487451c3b31e41737d14edbb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:41:32 +0100 Subject: [PATCH 0119/3340] update spec file template (#736774) --- spec-template.new | 36 ++++++++++++++++++++++++++++++++++++ vim.spec | 5 +++++ 2 files changed, 41 insertions(+) create mode 100644 spec-template.new diff --git a/spec-template.new b/spec-template.new new file mode 100644 index 00000000..da558005 --- /dev/null +++ b/spec-template.new @@ -0,0 +1,36 @@ +Name: +Version: +Release: 1%{?dist} +Summary: + +Group: +License: +URL: +Source0: + +BuildRequires: +Requires: + +%description + + +%prep +%setup -q + + +%build +%configure +make %{?_smp_mflags} + + +%install +rm -rf $RPM_BUILD_ROOT +make install DESTDIR=$RPM_BUILD_ROOT + + +%files +%doc + + + +%changelog diff --git a/vim.spec b/vim.spec index 10c51006..1f819c9b 100644 --- a/vim.spec +++ b/vim.spec @@ -41,6 +41,7 @@ Source12: vi_help.txt Source13: vim-spell-files.tar.bz2 %endif Source14: spec-template +Source15: spec-template.new Patch2002: vim-7.0-fixkeys.patch Patch2003: vim-6.2-specsyntax.patch @@ -1089,7 +1090,11 @@ mkdir -p $RPM_BUILD_ROOT/%{_bindir} mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/{after,autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/after/{autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} cp -f %{SOURCE11} . +%if %{?fedora}%{!?fedora:0} >= 16 || %{?rhel}%{!?rhel:0} >= 6 +cp -f %{SOURCE15} $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/template.spec +%else cp -f %{SOURCE14} $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/template.spec +%endif cp runtime/doc/uganda.txt LICENSE # Those aren't Linux info files but some binary files for Amiga: rm -f README*.info From 8c78c6e3e903172af4c06a234c2eec7888bbe3cb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:44:22 +0100 Subject: [PATCH 0120/3340] update spec file template (#736774) --- vim.spec | 3 +++ 1 file changed, 3 insertions(+) diff --git a/vim.spec b/vim.spec index 1f819c9b..2f03cd65 100644 --- a/vim.spec +++ b/vim.spec @@ -1439,6 +1439,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Tue Feb 07 2012 Karsten Hopp 7.3.393-3 +- update spec file template, bugzilla 736774 + * Thu Jan 26 2012 Harald Hoyer 7.3.393-3 - rebuild against the new ruby library From e9308db3bbf700199ea3055e341bfad59c0c6683 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:25 +0100 Subject: [PATCH 0121/3340] - patchlevel 394 --- 7.3.394 | 62 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 7.3.394 diff --git a/7.3.394 b/7.3.394 new file mode 100644 index 00000000..20c7cffe --- /dev/null +++ b/7.3.394 @@ -0,0 +1,62 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.394 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.394 +Problem: When placing a mark while starting up a screen redraw messes up + the screen. (lith) +Solution: Don't redraw while still starting up. (Christian Brabandt) +Files: src/screen.c + + +*** ../vim-7.3.393/src/screen.c 2011-09-02 14:07:31.000000000 +0200 +--- src/screen.c 2012-01-10 12:36:52.000000000 +0100 +*************** +*** 764,772 **** + doit = TRUE; + } + +! /* Return when there is nothing to do or screen updating already +! * happening. */ +! if (!doit || updating_screen) + return; + + /* update all windows that need updating */ +--- 764,776 ---- + doit = TRUE; + } + +! /* Return when there is nothing to do, screen updating is already +! * happening (recursive call) or still starting up. */ +! if (!doit || updating_screen +! #ifdef FEAT_GUI +! || gui.starting +! #endif +! || starting) + return; + + /* update all windows that need updating */ +*** ../vim-7.3.393/src/version.c 2012-01-04 20:29:18.000000000 +0100 +--- src/version.c 2012-01-10 12:41:32.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 394, + /**/ + +-- +It is illegal for anyone to try and stop a child from playfully jumping over +puddles of water. + [real standing law in California, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 39d3d53feb098f9ab6126c316907187d2a8d1a1b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:26 +0100 Subject: [PATCH 0122/3340] - patchlevel 395 --- 7.3.395 | 115 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 115 insertions(+) create mode 100644 7.3.395 diff --git a/7.3.395 b/7.3.395 new file mode 100644 index 00000000..cb268939 --- /dev/null +++ b/7.3.395 @@ -0,0 +1,115 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.395 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.395 (after 7.3.251) +Problem: "dv?bar" in the last line deletes too much and breaks undo. +Solution: Only adjust the cursor position when it's after the last line of + the buffer. Add a test. (Christian Brabandt) +Files: src/ops.c, src/testdir/test43.in, src/testdir/test43.ok + + +*** ../vim-7.3.394/src/ops.c 2011-09-21 17:33:49.000000000 +0200 +--- src/ops.c 2012-01-10 13:28:05.000000000 +0100 +*************** +*** 1961,1968 **** + /* Special case: gH deletes the last line. */ + del_lines(1L, FALSE); + curwin->w_cursor = curpos; /* restore curwin->w_cursor */ +! if (curwin->w_cursor.lnum > 1) +! --curwin->w_cursor.lnum; + } + else + { +--- 1962,1969 ---- + /* Special case: gH deletes the last line. */ + del_lines(1L, FALSE); + curwin->w_cursor = curpos; /* restore curwin->w_cursor */ +! if (curwin->w_cursor.lnum > curbuf->b_ml.ml_line_count) +! curwin->w_cursor.lnum = curbuf->b_ml.ml_line_count; + } + else + { +*************** +*** 4434,4440 **** + #endif + + /* +! * implementation of the format operator 'gq' + */ + void + op_format(oap, keep_cursor) +--- 4435,4441 ---- + #endif + + /* +! * Implementation of the format operator 'gq'. + */ + void + op_format(oap, keep_cursor) +*** ../vim-7.3.394/src/testdir/test43.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test43.in 2012-01-10 13:41:13.000000000 +0100 +*************** +*** 13,19 **** + x:set magic + /\v(a)(b)\2\1\1/e + x/\V[ab]\(\[xy]\)\1 +! x:?^1?,$w! test.out + :qa! + ENDTEST + +--- 13,23 ---- + x:set magic + /\v(a)(b)\2\1\1/e + x/\V[ab]\(\[xy]\)\1 +! x:$ +! :set undolevels=100 +! dv?bar? +! Yup:" +! :?^1?,$w! test.out + :qa! + ENDTEST + +*************** +*** 25,27 **** +--- 29,33 ---- + 6 x ^aa$ x + 7 (a)(b) abbaa + 8 axx [ab]xx ++ 9 foobar ++ +*** ../vim-7.3.394/src/testdir/test43.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test43.ok 2012-01-10 13:42:39.000000000 +0100 +*************** +*** 6,8 **** +--- 6,11 ---- + 6 x aa$ x + 7 (a)(b) abba + 8 axx ab]xx ++ 9 foobar ++ 9 foo ++ +*** ../vim-7.3.394/src/version.c 2012-01-10 12:42:05.000000000 +0100 +--- src/version.c 2012-01-10 13:30:40.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 395, + /**/ + +-- +The Law, in its majestic equality, forbids the rich, as well as the +poor, to sleep under the bridges, to beg in the streets, and to steal +bread. -- Anatole France + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 254acb64b353bce6f0b12e69803bfc39fb716268 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:26 +0100 Subject: [PATCH 0123/3340] - patchlevel 396 --- 7.3.396 | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 7.3.396 diff --git a/7.3.396 b/7.3.396 new file mode 100644 index 00000000..72b55a29 --- /dev/null +++ b/7.3.396 @@ -0,0 +1,49 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.396 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.396 +Problem: After forcing an operator to be characterwise it can still become + linewise when spanning whole lines. +Solution: Don't make the operator linewise when motion_force was set. + (Christian Brabandt) +Files: src/ops.c + + +*** ../vim-7.3.395/src/ops.c 2012-01-10 13:44:23.000000000 +0100 +--- src/ops.c 2012-01-10 13:28:05.000000000 +0100 +*************** +*** 1648,1653 **** +--- 1648,1654 ---- + && !oap->block_mode + #endif + && oap->line_count > 1 ++ && oap->motion_force == NUL + && oap->op_type == OP_DELETE) + { + ptr = ml_get(oap->end.lnum) + oap->end.col; +*** ../vim-7.3.395/src/version.c 2012-01-10 13:44:23.000000000 +0100 +--- src/version.c 2012-01-10 13:45:31.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 396, + /**/ + +-- +Any sufficiently advanced technology is indistinguishable from magic. + Arthur C. Clarke +Any sufficiently advanced bug is indistinguishable from a feature. + Rich Kulawiec + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e0388c6d32ebf53f8add71e78ba243917fc940c1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:27 +0100 Subject: [PATCH 0124/3340] - patchlevel 397 --- 7.3.397 | 224 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 224 insertions(+) create mode 100644 7.3.397 diff --git a/7.3.397 b/7.3.397 new file mode 100644 index 00000000..866b3aac --- /dev/null +++ b/7.3.397 @@ -0,0 +1,224 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.397 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.397 +Problem: ":helpgrep" does not work properly when 'encoding' is not utf-8 or + latin1. +Solution: Convert non-ascii lines to 'encoding'. (Yasuhiro Matsumoto) +Files: src/quickfix.c, src/spell.c, src/misc2.c, src/proto/misc2.pro + + +*** ../vim-7.3.396/src/quickfix.c 2011-12-30 15:01:55.000000000 +0100 +--- src/quickfix.c 2012-01-10 16:18:51.000000000 +0100 +*************** +*** 3914,3919 **** +--- 3914,3929 ---- + regmatch.rm_ic = FALSE; + if (regmatch.regprog != NULL) + { ++ #ifdef FEAT_MBYTE ++ vimconv_T vc; ++ ++ /* Help files are in utf-8 or latin1, convert lines when 'encoding' ++ * differs. */ ++ vc.vc_type = CONV_NONE; ++ if (!enc_utf8) ++ convert_setup(&vc, (char_u *)"utf-8", p_enc); ++ #endif ++ + /* create a new quickfix list */ + qf_new_list(qi, *eap->cmdlinep); + +*************** +*** 3948,3968 **** + lnum = 1; + while (!vim_fgets(IObuff, IOSIZE, fd) && !got_int) + { +! if (vim_regexec(®match, IObuff, (colnr_T)0)) + { +! int l = (int)STRLEN(IObuff); + + /* remove trailing CR, LF, spaces, etc. */ +! while (l > 0 && IObuff[l - 1] <= ' ') +! IObuff[--l] = NUL; + + if (qf_add_entry(qi, &prevp, + NULL, /* dir */ + fnames[fi], + 0, +! IObuff, + lnum, +! (int)(regmatch.startp[0] - IObuff) + + 1, /* col */ + FALSE, /* vis_col */ + NULL, /* search pattern */ +--- 3958,3990 ---- + lnum = 1; + while (!vim_fgets(IObuff, IOSIZE, fd) && !got_int) + { +! char_u *line = IObuff; +! #ifdef FEAT_MBYTE +! /* Convert a line if 'encoding' is not utf-8 and +! * the line contains a non-ASCII character. */ +! if (vc.vc_type != CONV_NONE +! && has_non_ascii(IObuff)) { +! line = string_convert(&vc, IObuff, NULL); +! if (line == NULL) +! line = IObuff; +! } +! #endif +! +! if (vim_regexec(®match, line, (colnr_T)0)) + { +! int l = (int)STRLEN(line); + + /* remove trailing CR, LF, spaces, etc. */ +! while (l > 0 && line[l - 1] <= ' ') +! line[--l] = NUL; + + if (qf_add_entry(qi, &prevp, + NULL, /* dir */ + fnames[fi], + 0, +! line, + lnum, +! (int)(regmatch.startp[0] - line) + + 1, /* col */ + FALSE, /* vis_col */ + NULL, /* search pattern */ +*************** +*** 3972,3980 **** +--- 3994,4010 ---- + ) == FAIL) + { + got_int = TRUE; ++ #ifdef FEAT_MBYTE ++ if (line != IObuff) ++ vim_free(line); ++ #endif + break; + } + } ++ #ifdef FEAT_MBYTE ++ if (line != IObuff) ++ vim_free(line); ++ #endif + ++lnum; + line_breakcheck(); + } +*************** +*** 3984,3990 **** +--- 4014,4025 ---- + FreeWild(fcount, fnames); + } + } ++ + vim_free(regmatch.regprog); ++ #ifdef FEAT_MBYTE ++ if (vc.vc_type != CONV_NONE) ++ convert_setup(&vc, NULL, NULL); ++ #endif + + qi->qf_lists[qi->qf_curlist].qf_nonevalid = FALSE; + qi->qf_lists[qi->qf_curlist].qf_ptr = +*** ../vim-7.3.396/src/spell.c 2011-09-02 14:18:14.000000000 +0200 +--- src/spell.c 2012-01-10 16:19:33.000000000 +0100 +*************** +*** 5020,5026 **** + static int str_equal __ARGS((char_u *s1, char_u *s2)); + static void add_fromto __ARGS((spellinfo_T *spin, garray_T *gap, char_u *from, char_u *to)); + static int sal_to_bool __ARGS((char_u *s)); +- static int has_non_ascii __ARGS((char_u *s)); + static void spell_free_aff __ARGS((afffile_T *aff)); + static int spell_read_dic __ARGS((spellinfo_T *spin, char_u *fname, afffile_T *affile)); + static int get_affix_flags __ARGS((afffile_T *affile, char_u *afflist)); +--- 5020,5025 ---- +*************** +*** 6485,6507 **** + } + + /* +- * Return TRUE if string "s" contains a non-ASCII character (128 or higher). +- * When "s" is NULL FALSE is returned. +- */ +- static int +- has_non_ascii(s) +- char_u *s; +- { +- char_u *p; +- +- if (s != NULL) +- for (p = s; *p != NUL; ++p) +- if (*p >= 128) +- return TRUE; +- return FALSE; +- } +- +- /* + * Free the structure filled by spell_read_aff(). + */ + static void +--- 6484,6489 ---- +*** ../vim-7.3.396/src/misc2.c 2011-12-08 17:49:31.000000000 +0100 +--- src/misc2.c 2012-01-10 16:25:53.000000000 +0100 +*************** +*** 6541,6543 **** +--- 6541,6563 ---- + #endif + + #endif ++ ++ #if (defined(FEAT_MBYTE) && defined(FEAT_QUICKFIX)) \ ++ || defined(FEAT_SPELL) || defined(PROTO) ++ /* ++ * Return TRUE if string "s" contains a non-ASCII character (128 or higher). ++ * When "s" is NULL FALSE is returned. ++ */ ++ int ++ has_non_ascii(s) ++ char_u *s; ++ { ++ char_u *p; ++ ++ if (s != NULL) ++ for (p = s; *p != NUL; ++p) ++ if (*p >= 128) ++ return TRUE; ++ return FALSE; ++ } ++ #endif +*** ../vim-7.3.396/src/proto/misc2.pro 2011-07-07 16:20:45.000000000 +0200 +--- src/proto/misc2.pro 2012-01-10 16:20:03.000000000 +0100 +*************** +*** 116,119 **** +--- 116,120 ---- + char_u *read_string __ARGS((FILE *fd, int cnt)); + int put_bytes __ARGS((FILE *fd, long_u nr, int len)); + void put_time __ARGS((FILE *fd, time_t the_time)); ++ int has_non_ascii __ARGS((char_u *s)); + /* vim: set ft=c : */ +*** ../vim-7.3.396/src/version.c 2012-01-10 13:46:18.000000000 +0100 +--- src/version.c 2012-01-10 16:26:32.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 397, + /**/ + +-- +Biting someone with your natural teeth is "simple assault," while biting +someone with your false teeth is "aggravated assault." + [real standing law in Louisana, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From aab5e3da6ff4434d3726b4ed178fe81704ee8999 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:27 +0100 Subject: [PATCH 0125/3340] - patchlevel 398 --- 7.3.398 | 65 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 7.3.398 diff --git a/7.3.398 b/7.3.398 new file mode 100644 index 00000000..8d4b2138 --- /dev/null +++ b/7.3.398 @@ -0,0 +1,65 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.398 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.398 +Problem: When creating more than 10 location lists and adding items one by + one a previous location may be used. (Audrius Kažukauskas) +Solution: Clear the location list completely when adding the tenth one. +Files: src/quickfix.c + + +*** ../vim-7.3.397/src/quickfix.c 2012-01-10 16:28:41.000000000 +0100 +--- src/quickfix.c 2012-01-10 16:58:52.000000000 +0100 +*************** +*** 899,906 **** + } + else + qi->qf_curlist = qi->qf_listcount++; +! qi->qf_lists[qi->qf_curlist].qf_index = 0; +! qi->qf_lists[qi->qf_curlist].qf_count = 0; + if (qf_title != NULL) + { + char_u *p = alloc((int)STRLEN(qf_title) + 2); +--- 899,905 ---- + } + else + qi->qf_curlist = qi->qf_listcount++; +! vim_memset(&qi->qf_lists[qi->qf_curlist], 0, (size_t)(sizeof(qf_list_T))); + if (qf_title != NULL) + { + char_u *p = alloc((int)STRLEN(qf_title) + 2); +*************** +*** 909,916 **** + if (p != NULL) + sprintf((char *)p, ":%s", (char *)qf_title); + } +- else +- qi->qf_lists[qi->qf_curlist].qf_title = NULL; + } + + /* +--- 908,913 ---- +*** ../vim-7.3.397/src/version.c 2012-01-10 16:28:41.000000000 +0100 +--- src/version.c 2012-01-10 17:13:09.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 398, + /**/ + +-- +Why don't cannibals eat clowns? +Because they taste funny. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6fff82c3e2c9f0393bfa3b5b0b26d32a29f4106f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:27 +0100 Subject: [PATCH 0126/3340] - patchlevel 399 --- 7.3.399 | 137 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 137 insertions(+) create mode 100644 7.3.399 diff --git a/7.3.399 b/7.3.399 new file mode 100644 index 00000000..33d06302 --- /dev/null +++ b/7.3.399 @@ -0,0 +1,137 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.399 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.399 +Problem: ":cd" doesn't work when the path contains wildcards. (Yukihiro + Nakadaira) +Solution: Ignore wildcard errors when the EW_NOTWILD flag is used. +Files: src/misc1.c + + +*** ../vim-7.3.398/src/misc1.c 2011-12-14 20:21:29.000000000 +0100 +--- src/misc1.c 2012-01-10 17:57:42.000000000 +0100 +*************** +*** 9103,9117 **** + } + + /* compile the regexp into a program */ +! if (flags & EW_NOERROR) + ++emsg_silent; + regmatch.rm_ic = TRUE; /* Always ignore case */ + regmatch.regprog = vim_regcomp(pat, RE_MAGIC); +! if (flags & EW_NOERROR) + --emsg_silent; + vim_free(pat); + +! if (regmatch.regprog == NULL) + { + vim_free(buf); + return 0; +--- 9103,9117 ---- + } + + /* compile the regexp into a program */ +! if (flags & (EW_NOERROR | EW_NOTWILD)) + ++emsg_silent; + regmatch.rm_ic = TRUE; /* Always ignore case */ + regmatch.regprog = vim_regcomp(pat, RE_MAGIC); +! if (flags & (EW_NOERROR | EW_NOTWILD)) + --emsg_silent; + vim_free(pat); + +! if (regmatch.regprog == NULL && (flags & EW_NOTWILD) == 0) + { + vim_free(buf); + return 0; +*************** +*** 9179,9185 **** + * all entries found with "matchname". */ + if ((p[0] != '.' || starts_with_dot) + && (matchname == NULL +! || vim_regexec(®match, p, (colnr_T)0) + || ((flags & EW_NOTWILD) + && fnamencmp(path + (s - buf), p, e - s) == 0))) + { +--- 9179,9186 ---- + * all entries found with "matchname". */ + if ((p[0] != '.' || starts_with_dot) + && (matchname == NULL +! || (regmatch.regprog != NULL +! && vim_regexec(®match, p, (colnr_T)0)) + || ((flags & EW_NOTWILD) + && fnamencmp(path + (s - buf), p, e - s) == 0))) + { +*************** +*** 9419,9428 **** + else + regmatch.rm_ic = FALSE; /* Don't ignore case */ + #endif + regmatch.regprog = vim_regcomp(pat, RE_MAGIC); + vim_free(pat); + +! if (regmatch.regprog == NULL) + { + vim_free(buf); + return 0; +--- 9420,9433 ---- + else + regmatch.rm_ic = FALSE; /* Don't ignore case */ + #endif ++ if (flags & (EW_NOERROR | EW_NOTWILD)) ++ ++emsg_silent; + regmatch.regprog = vim_regcomp(pat, RE_MAGIC); ++ if (flags & (EW_NOERROR | EW_NOTWILD)) ++ --emsg_silent; + vim_free(pat); + +! if (regmatch.regprog == NULL && (flags & EW_NOTWILD) == 0) + { + vim_free(buf); + return 0; +*************** +*** 9452,9458 **** + if (dp == NULL) + break; + if ((dp->d_name[0] != '.' || starts_with_dot) +! && (vim_regexec(®match, (char_u *)dp->d_name, (colnr_T)0) + || ((flags & EW_NOTWILD) + && fnamencmp(path + (s - buf), dp->d_name, e - s) == 0))) + { +--- 9457,9464 ---- + if (dp == NULL) + break; + if ((dp->d_name[0] != '.' || starts_with_dot) +! && ((regmatch.regprog != NULL && vim_regexec(®match, +! (char_u *)dp->d_name, (colnr_T)0)) + || ((flags & EW_NOTWILD) + && fnamencmp(path + (s - buf), dp->d_name, e - s) == 0))) + { +*** ../vim-7.3.398/src/version.c 2012-01-10 17:13:48.000000000 +0100 +--- src/version.c 2012-01-10 18:21:05.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 399, + /**/ + +-- +Close your shells, or I'll kill -9 you +Tomorrow I'll quota you +Remember the disks'll always be full +And then while I'm away +I'll write ~ everyday +And I'll send-pr all my buggings to you. + [ CVS log "Beatles style" for FreeBSD ports/INDEX, Satoshi Asami ] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 34a375bdb9fc1e99d73cd3755b0742148de8c705 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:28 +0100 Subject: [PATCH 0127/3340] - patchlevel 400 --- 7.3.400 | 1762 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1762 insertions(+) create mode 100644 7.3.400 diff --git a/7.3.400 b/7.3.400 new file mode 100644 index 00000000..c621a881 --- /dev/null +++ b/7.3.400 @@ -0,0 +1,1762 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.400 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.400 +Problem: Compiler warnings for shadowed variables. +Solution: Remove or rename the variables. +Files: src/charset.c, src/digraph.c, src/edit.c, src/eval.c, src/fold.c, + src/getchar.c, src/message.c, src/misc2.c, src/move.c, + src/netbeans.c, src/option.c, src/os_unix.c, src/screen.c, + src/search.c, src/spell.c, src/syntax.c, src/tag.c, src/window.c + + +*** ../vim-7.3.399/src/charset.c 2010-08-15 21:57:25.000000000 +0200 +--- src/charset.c 2012-01-10 21:55:50.000000000 +0100 +*************** +*** 463,503 **** + if (enc_utf8) + { + int c = utf_ptr2char(STR_PTR(i)); +! int ol = utf_ptr2len(STR_PTR(i)); + int lc = utf_tolower(c); + + /* Only replace the character when it is not an invalid + * sequence (ASCII character or more than one byte) and + * utf_tolower() doesn't return the original character. */ +! if ((c < 0x80 || ol > 1) && c != lc) + { +! int nl = utf_char2len(lc); + + /* If the byte length changes need to shift the following + * characters forward or backward. */ +! if (ol != nl) + { +! if (nl > ol) + { +! if (buf == NULL ? ga_grow(&ga, nl - ol + 1) == FAIL +! : len + nl - ol >= buflen) + { + /* out of memory, keep old char */ + lc = c; +! nl = ol; + } + } +! if (ol != nl) + { + if (buf == NULL) + { +! STRMOVE(GA_PTR(i) + nl, GA_PTR(i) + ol); +! ga.ga_len += nl - ol; + } + else + { +! STRMOVE(buf + i + nl, buf + i + ol); +! len += nl - ol; + } + } + } +--- 463,504 ---- + if (enc_utf8) + { + int c = utf_ptr2char(STR_PTR(i)); +! int olen = utf_ptr2len(STR_PTR(i)); + int lc = utf_tolower(c); + + /* Only replace the character when it is not an invalid + * sequence (ASCII character or more than one byte) and + * utf_tolower() doesn't return the original character. */ +! if ((c < 0x80 || olen > 1) && c != lc) + { +! int nlen = utf_char2len(lc); + + /* If the byte length changes need to shift the following + * characters forward or backward. */ +! if (olen != nlen) + { +! if (nlen > olen) + { +! if (buf == NULL +! ? ga_grow(&ga, nlen - olen + 1) == FAIL +! : len + nlen - olen >= buflen) + { + /* out of memory, keep old char */ + lc = c; +! nlen = olen; + } + } +! if (olen != nlen) + { + if (buf == NULL) + { +! STRMOVE(GA_PTR(i) + nlen, GA_PTR(i) + olen); +! ga.ga_len += nlen - olen; + } + else + { +! STRMOVE(buf + i + nlen, buf + i + olen); +! len += nlen - olen; + } + } + } +*** ../vim-7.3.399/src/digraph.c 2010-08-15 21:57:28.000000000 +0200 +--- src/digraph.c 2012-01-10 21:57:16.000000000 +0100 +*************** +*** 2080,2092 **** + /* + * Lookup the pair "char1", "char2" in the digraph tables. + * If no match, return "char2". +! * If "meta" is TRUE and "char1" is a space, return "char2" | 0x80. + */ + static int +! getexactdigraph(char1, char2, meta) + int char1; + int char2; +! int meta; + { + int i; + int retval = 0; +--- 2080,2092 ---- + /* + * Lookup the pair "char1", "char2" in the digraph tables. + * If no match, return "char2". +! * If "meta_char" is TRUE and "char1" is a space, return "char2" | 0x80. + */ + static int +! getexactdigraph(char1, char2, meta_char) + int char1; + int char2; +! int meta_char; + { + int i; + int retval = 0; +*************** +*** 2159,2165 **** + + if (retval == 0) /* digraph deleted or not found */ + { +! if (char1 == ' ' && meta) /* --> meta-char */ + return (char2 | 0x80); + return char2; + } +--- 2159,2165 ---- + + if (retval == 0) /* digraph deleted or not found */ + { +! if (char1 == ' ' && meta_char) /* --> meta-char */ + return (char2 | 0x80); + return char2; + } +*************** +*** 2171,2186 **** + * Allow for both char1-char2 and char2-char1 + */ + int +! getdigraph(char1, char2, meta) + int char1; + int char2; +! int meta; + { + int retval; + +! if (((retval = getexactdigraph(char1, char2, meta)) == char2) + && (char1 != char2) +! && ((retval = getexactdigraph(char2, char1, meta)) == char1)) + return char2; + return retval; + } +--- 2171,2186 ---- + * Allow for both char1-char2 and char2-char1 + */ + int +! getdigraph(char1, char2, meta_char) + int char1; + int char2; +! int meta_char; + { + int retval; + +! if (((retval = getexactdigraph(char1, char2, meta_char)) == char2) + && (char1 != char2) +! && ((retval = getexactdigraph(char2, char1, meta_char)) == char1)) + return char2; + return retval; + } +*** ../vim-7.3.399/src/edit.c 2011-12-23 13:14:58.000000000 +0100 +--- src/edit.c 2012-01-10 21:58:28.000000000 +0100 +*************** +*** 4003,4026 **** + ins_compl_add_dict(dict) + dict_T *dict; + { +! dictitem_T *refresh; +! dictitem_T *words; + + /* Check for optional "refresh" item. */ + compl_opt_refresh_always = FALSE; +! refresh = dict_find(dict, (char_u *)"refresh", 7); +! if (refresh != NULL && refresh->di_tv.v_type == VAR_STRING) + { +! char_u *v = refresh->di_tv.vval.v_string; + + if (v != NULL && STRCMP(v, (char_u *)"always") == 0) + compl_opt_refresh_always = TRUE; + } + + /* Add completions from a "words" list. */ +! words = dict_find(dict, (char_u *)"words", 5); +! if (words != NULL && words->di_tv.v_type == VAR_LIST) +! ins_compl_add_list(words->di_tv.vval.v_list); + } + + /* +--- 4003,4026 ---- + ins_compl_add_dict(dict) + dict_T *dict; + { +! dictitem_T *di_refresh; +! dictitem_T *di_words; + + /* Check for optional "refresh" item. */ + compl_opt_refresh_always = FALSE; +! di_refresh = dict_find(dict, (char_u *)"refresh", 7); +! if (di_refresh != NULL && di_refresh->di_tv.v_type == VAR_STRING) + { +! char_u *v = di_refresh->di_tv.vval.v_string; + + if (v != NULL && STRCMP(v, (char_u *)"always") == 0) + compl_opt_refresh_always = TRUE; + } + + /* Add completions from a "words" list. */ +! di_words = dict_find(dict, (char_u *)"words", 5); +! if (di_words != NULL && di_words->di_tv.v_type == VAR_LIST) +! ins_compl_add_list(di_words->di_tv.vval.v_list); + } + + /* +*** ../vim-7.3.399/src/eval.c 2012-01-04 14:35:31.000000000 +0100 +--- src/eval.c 2012-01-10 22:00:50.000000000 +0100 +*************** +*** 6573,6587 **** + + /* + * Join list "l" into a string in "*gap", using separator "sep". +! * When "echo" is TRUE use String as echoed, otherwise as inside a List. + * Return FAIL or OK. + */ + static int +! list_join(gap, l, sep, echo, copyID) + garray_T *gap; + list_T *l; + char_u *sep; +! int echo; + int copyID; + { + int first = TRUE; +--- 6573,6587 ---- + + /* + * Join list "l" into a string in "*gap", using separator "sep". +! * When "echo_style" is TRUE use String as echoed, otherwise as inside a List. + * Return FAIL or OK. + */ + static int +! list_join(gap, l, sep, echo_style, copyID) + garray_T *gap; + list_T *l; + char_u *sep; +! int echo_style; + int copyID; + { + int first = TRUE; +*************** +*** 6597,6603 **** + else + ga_concat(gap, sep); + +! if (echo) + s = echo_string(&item->li_tv, &tofree, numbuf, copyID); + else + s = tv2string(&item->li_tv, &tofree, numbuf, copyID); +--- 6597,6603 ---- + else + ga_concat(gap, sep); + +! if (echo_style) + s = echo_string(&item->li_tv, &tofree, numbuf, copyID); + else + s = tv2string(&item->li_tv, &tofree, numbuf, copyID); +*************** +*** 17893,17899 **** + typval_T *argvars; + typval_T *rettv; + { +! char_u *instr; + char_u *fromstr; + char_u *tostr; + char_u *p; +--- 17893,17899 ---- + typval_T *argvars; + typval_T *rettv; + { +! char_u *in_str; + char_u *fromstr; + char_u *tostr; + char_u *p; +*************** +*** 17910,17916 **** + char_u buf2[NUMBUFLEN]; + garray_T ga; + +! instr = get_tv_string(&argvars[0]); + fromstr = get_tv_string_buf_chk(&argvars[1], buf); + tostr = get_tv_string_buf_chk(&argvars[2], buf2); + +--- 17910,17916 ---- + char_u buf2[NUMBUFLEN]; + garray_T ga; + +! in_str = get_tv_string(&argvars[0]); + fromstr = get_tv_string_buf_chk(&argvars[1], buf); + tostr = get_tv_string_buf_chk(&argvars[2], buf2); + +*************** +*** 17936,17954 **** + } + + /* fromstr and tostr have to contain the same number of chars */ +! while (*instr != NUL) + { + #ifdef FEAT_MBYTE + if (has_mbyte) + { +! inlen = (*mb_ptr2len)(instr); +! cpstr = instr; + cplen = inlen; + idx = 0; + for (p = fromstr; *p != NUL; p += fromlen) + { + fromlen = (*mb_ptr2len)(p); +! if (fromlen == inlen && STRNCMP(instr, p, inlen) == 0) + { + for (p = tostr; *p != NUL; p += tolen) + { +--- 17936,17954 ---- + } + + /* fromstr and tostr have to contain the same number of chars */ +! while (*in_str != NUL) + { + #ifdef FEAT_MBYTE + if (has_mbyte) + { +! inlen = (*mb_ptr2len)(in_str); +! cpstr = in_str; + cplen = inlen; + idx = 0; + for (p = fromstr; *p != NUL; p += fromlen) + { + fromlen = (*mb_ptr2len)(p); +! if (fromlen == inlen && STRNCMP(in_str, p, inlen) == 0) + { + for (p = tostr; *p != NUL; p += tolen) + { +*************** +*** 17967,17977 **** + ++idx; + } + +! if (first && cpstr == instr) + { + /* Check that fromstr and tostr have the same number of + * (multi-byte) characters. Done only once when a character +! * of instr doesn't appear in fromstr. */ + first = FALSE; + for (p = tostr; *p != NUL; p += tolen) + { +--- 17967,17977 ---- + ++idx; + } + +! if (first && cpstr == in_str) + { + /* Check that fromstr and tostr have the same number of + * (multi-byte) characters. Done only once when a character +! * of in_str doesn't appear in fromstr. */ + first = FALSE; + for (p = tostr; *p != NUL; p += tolen) + { +*************** +*** 17986,18003 **** + mch_memmove((char *)ga.ga_data + ga.ga_len, cpstr, (size_t)cplen); + ga.ga_len += cplen; + +! instr += inlen; + } + else + #endif + { + /* When not using multi-byte chars we can do it faster. */ +! p = vim_strchr(fromstr, *instr); + if (p != NULL) + ga_append(&ga, tostr[p - fromstr]); + else +! ga_append(&ga, *instr); +! ++instr; + } + } + +--- 17986,18003 ---- + mch_memmove((char *)ga.ga_data + ga.ga_len, cpstr, (size_t)cplen); + ga.ga_len += cplen; + +! in_str += inlen; + } + else + #endif + { + /* When not using multi-byte chars we can do it faster. */ +! p = vim_strchr(fromstr, *in_str); + if (p != NULL) + ga_append(&ga, tostr[p - fromstr]); + else +! ga_append(&ga, *in_str); +! ++in_str; + } + } + +*** ../vim-7.3.399/src/fold.c 2011-08-26 16:12:55.000000000 +0200 +--- src/fold.c 2012-01-10 22:01:26.000000000 +0100 +*************** +*** 1033,1042 **** + * Init the fold info in a new window. + */ + void +! foldInitWin(newwin) +! win_T *newwin; + { +! ga_init2(&newwin->w_folds, (int)sizeof(fold_T), 10); + } + + /* find_wl_entry() {{{2 */ +--- 1033,1042 ---- + * Init the fold info in a new window. + */ + void +! foldInitWin(new_win) +! win_T *new_win; + { +! ga_init2(&new_win->w_folds, (int)sizeof(fold_T), 10); + } + + /* find_wl_entry() {{{2 */ +*** ../vim-7.3.399/src/getchar.c 2011-12-23 14:54:01.000000000 +0100 +--- src/getchar.c 2012-01-10 22:02:30.000000000 +0100 +*************** +*** 418,429 **** + + /* + * Remove the contents of the stuff buffer and the mapped characters in the +! * typeahead buffer (used in case of an error). If 'typeahead' is true, + * flush all typeahead characters (used when interrupted by a CTRL-C). + */ + void +! flush_buffers(typeahead) +! int typeahead; + { + init_typebuf(); + +--- 418,429 ---- + + /* + * Remove the contents of the stuff buffer and the mapped characters in the +! * typeahead buffer (used in case of an error). If "flush_typeahead" is true, + * flush all typeahead characters (used when interrupted by a CTRL-C). + */ + void +! flush_buffers(flush_typeahead) +! int flush_typeahead; + { + init_typebuf(); + +*************** +*** 431,437 **** + while (read_stuff(TRUE) != NUL) + ; + +! if (typeahead) /* remove all typeahead */ + { + /* + * We have to get all characters, because we may delete the first part +--- 431,437 ---- + while (read_stuff(TRUE) != NUL) + ; + +! if (flush_typeahead) /* remove all typeahead */ + { + /* + * We have to get all characters, because we may delete the first part +*** ../vim-7.3.399/src/message.c 2011-12-30 14:14:16.000000000 +0100 +--- src/message.c 2012-01-10 22:03:56.000000000 +0100 +*************** +*** 2487,2493 **** + #ifdef FEAT_CON_DIALOG + int retval = FALSE; + #endif +! int scroll; + msgchunk_T *mp_last = NULL; + msgchunk_T *mp; + int i; +--- 2487,2493 ---- + #ifdef FEAT_CON_DIALOG + int retval = FALSE; + #endif +! int toscroll; + msgchunk_T *mp_last = NULL; + msgchunk_T *mp; + int i; +*************** +*** 2538,2586 **** + } + #endif + +! scroll = 0; + switch (c) + { + case BS: /* scroll one line back */ + case K_BS: + case 'k': + case K_UP: +! scroll = -1; + break; + + case CAR: /* one extra line */ + case NL: + case 'j': + case K_DOWN: +! scroll = 1; + break; + + case 'u': /* Up half a page */ +! scroll = -(Rows / 2); + break; + + case 'd': /* Down half a page */ +! scroll = Rows / 2; + break; + + case 'b': /* one page back */ + case K_PAGEUP: +! scroll = -(Rows - 1); + break; + + case ' ': /* one extra page */ + case 'f': + case K_PAGEDOWN: + case K_LEFTMOUSE: +! scroll = Rows - 1; + break; + + case 'g': /* all the way back to the start */ +! scroll = -999999; + break; + + case 'G': /* all the way to the end */ +! scroll = 999999; + lines_left = 999999; + break; + +--- 2538,2586 ---- + } + #endif + +! toscroll = 0; + switch (c) + { + case BS: /* scroll one line back */ + case K_BS: + case 'k': + case K_UP: +! toscroll = -1; + break; + + case CAR: /* one extra line */ + case NL: + case 'j': + case K_DOWN: +! toscroll = 1; + break; + + case 'u': /* Up half a page */ +! toscroll = -(Rows / 2); + break; + + case 'd': /* Down half a page */ +! toscroll = Rows / 2; + break; + + case 'b': /* one page back */ + case K_PAGEUP: +! toscroll = -(Rows - 1); + break; + + case ' ': /* one extra page */ + case 'f': + case K_PAGEDOWN: + case K_LEFTMOUSE: +! toscroll = Rows - 1; + break; + + case 'g': /* all the way back to the start */ +! toscroll = -999999; + break; + + case 'G': /* all the way to the end */ +! toscroll = 999999; + lines_left = 999999; + break; + +*************** +*** 2633,2641 **** + continue; + } + +! if (scroll != 0) + { +! if (scroll < 0) + { + /* go to start of last line */ + if (mp_last == NULL) +--- 2633,2641 ---- + continue; + } + +! if (toscroll != 0) + { +! if (toscroll < 0) + { + /* go to start of last line */ + if (mp_last == NULL) +*************** +*** 2653,2659 **** + if (mp != NULL && mp->sb_prev != NULL) + { + /* Find line to be displayed at top. */ +! for (i = 0; i > scroll; --i) + { + if (mp == NULL || mp->sb_prev == NULL) + break; +--- 2653,2659 ---- + if (mp != NULL && mp->sb_prev != NULL) + { + /* Find line to be displayed at top. */ +! for (i = 0; i > toscroll; --i) + { + if (mp == NULL || mp->sb_prev == NULL) + break; +*************** +*** 2664,2670 **** + mp_last = msg_sb_start(mp_last->sb_prev); + } + +! if (scroll == -1 && screen_ins_lines(0, 0, 1, + (int)Rows, NULL) == OK) + { + /* display line at top */ +--- 2664,2670 ---- + mp_last = msg_sb_start(mp_last->sb_prev); + } + +! if (toscroll == -1 && screen_ins_lines(0, 0, 1, + (int)Rows, NULL) == OK) + { + /* display line at top */ +*************** +*** 2680,2692 **** + ++msg_scrolled; + } + } +! scroll = 0; + } + } + else + { + /* First display any text that we scrolled back. */ +! while (scroll > 0 && mp_last != NULL) + { + /* scroll up, display line at bottom */ + msg_scroll_up(); +--- 2680,2692 ---- + ++msg_scrolled; + } + } +! toscroll = 0; + } + } + else + { + /* First display any text that we scrolled back. */ +! while (toscroll > 0 && mp_last != NULL) + { + /* scroll up, display line at bottom */ + msg_scroll_up(); +*************** +*** 2694,2704 **** + screen_fill((int)Rows - 2, (int)Rows - 1, 0, + (int)Columns, ' ', ' ', 0); + mp_last = disp_sb_line((int)Rows - 2, mp_last); +! --scroll; + } + } + +! if (scroll <= 0) + { + /* displayed the requested text, more prompt again */ + screen_fill((int)Rows - 1, (int)Rows, 0, +--- 2694,2704 ---- + screen_fill((int)Rows - 2, (int)Rows - 1, 0, + (int)Columns, ' ', ' ', 0); + mp_last = disp_sb_line((int)Rows - 2, mp_last); +! --toscroll; + } + } + +! if (toscroll <= 0) + { + /* displayed the requested text, more prompt again */ + screen_fill((int)Rows - 1, (int)Rows, 0, +*************** +*** 2708,2714 **** + } + + /* display more text, return to caller */ +! lines_left = scroll; + } + + break; +--- 2708,2714 ---- + } + + /* display more text, return to caller */ +! lines_left = toscroll; + } + + break; +*** ../vim-7.3.399/src/misc2.c 2012-01-10 16:28:41.000000000 +0100 +--- src/misc2.c 2012-01-10 22:04:25.000000000 +0100 +*************** +*** 1559,1565 **** + if (enc_utf8) + { + int c, uc; +! int nl; + char_u *s; + + c = utf_ptr2char(p); +--- 1559,1565 ---- + if (enc_utf8) + { + int c, uc; +! int newl; + char_u *s; + + c = utf_ptr2char(p); +*************** +*** 1568,1588 **** + /* Reallocate string when byte count changes. This is rare, + * thus it's OK to do another malloc()/free(). */ + l = utf_ptr2len(p); +! nl = utf_char2len(uc); +! if (nl != l) + { +! s = alloc((unsigned)STRLEN(res) + 1 + nl - l); + if (s == NULL) + break; + mch_memmove(s, res, p - res); +! STRCPY(s + (p - res) + nl, p + l); + p = s + (p - res); + vim_free(res); + res = s; + } + + utf_char2bytes(uc, p); +! p += nl; + } + else if (has_mbyte && (l = (*mb_ptr2len)(p)) > 1) + p += l; /* skip multi-byte character */ +--- 1568,1588 ---- + /* Reallocate string when byte count changes. This is rare, + * thus it's OK to do another malloc()/free(). */ + l = utf_ptr2len(p); +! newl = utf_char2len(uc); +! if (newl != l) + { +! s = alloc((unsigned)STRLEN(res) + 1 + newl - l); + if (s == NULL) + break; + mch_memmove(s, res, p - res); +! STRCPY(s + (p - res) + newl, p + l); + p = s + (p - res); + vim_free(res); + res = s; + } + + utf_char2bytes(uc, p); +! p += newl; + } + else if (has_mbyte && (l = (*mb_ptr2len)(p)) > 1) + p += l; /* skip multi-byte character */ +*** ../vim-7.3.399/src/move.c 2011-02-01 18:01:06.000000000 +0100 +--- src/move.c 2012-01-10 22:05:22.000000000 +0100 +*************** +*** 926,933 **** + * Also updates curwin->w_leftcol. + */ + void +! curs_columns(scroll) +! int scroll; /* when TRUE, may scroll horizontally */ + { + int diff; + int extra; /* offset for first screen line */ +--- 926,933 ---- + * Also updates curwin->w_leftcol. + */ + void +! curs_columns(may_scroll) +! int may_scroll; /* when TRUE, may scroll horizontally */ + { + int diff; + int extra; /* offset for first screen line */ +*************** +*** 1014,1020 **** + /* No line wrapping: compute curwin->w_leftcol if scrolling is on and line + * is not folded. + * If scrolling is off, curwin->w_leftcol is assumed to be 0 */ +! else if (scroll + #ifdef FEAT_FOLDING + && !curwin->w_cline_folded + #endif +--- 1014,1020 ---- + /* No line wrapping: compute curwin->w_leftcol if scrolling is on and line + * is not folded. + * If scrolling is off, curwin->w_leftcol is assumed to be 0 */ +! else if (may_scroll + #ifdef FEAT_FOLDING + && !curwin->w_cline_folded + #endif +*** ../vim-7.3.399/src/netbeans.c 2011-10-20 21:58:20.000000000 +0200 +--- src/netbeans.c 2012-01-10 22:16:26.000000000 +0100 +*************** +*** 1395,1401 **** + int cmdno, + char_u *args) /* points to space before arguments or NUL */ + { +! int doupdate = 0; + long off = 0; + nbbuf_T *buf = nb_get_buf(bufno); + static int skip = 0; +--- 1395,1401 ---- + int cmdno, + char_u *args) /* points to space before arguments or NUL */ + { +! int do_update = 0; + long off = 0; + nbbuf_T *buf = nb_get_buf(bufno); + static int skip = 0; +*************** +*** 1600,1606 **** + last.lnum, last.col)); + del_from_lnum = first.lnum; + del_to_lnum = last.lnum; +! doupdate = 1; + + /* Get the position of the first byte after the deleted + * section. "next" is NULL when deleting to the end of the +--- 1600,1606 ---- + last.lnum, last.col)); + del_from_lnum = first.lnum; + del_to_lnum = last.lnum; +! do_update = 1; + + /* Get the position of the first byte after the deleted + * section. "next" is NULL when deleting to the end of the +*************** +*** 1777,1783 **** + lnum = lnum_start; + + /* Loop over the "\n" separated lines of the argument. */ +! doupdate = 1; + while (*args != NUL) + { + nl = vim_strchr(args, '\n'); +--- 1777,1783 ---- + lnum = lnum_start; + + /* Loop over the "\n" separated lines of the argument. */ +! do_update = 1; + while (*args != NUL) + { + nl = vim_strchr(args, '\n'); +*************** +*** 1992,1998 **** + EMSG("E640: invalid buffer identifier in initDone"); + return FAIL; + } +! doupdate = 1; + buf->initDone = TRUE; + nb_set_curbuf(buf->bufp); + #if defined(FEAT_AUTOCMD) +--- 1992,1998 ---- + EMSG("E640: invalid buffer identifier in initDone"); + return FAIL; + } +! do_update = 1; + buf->initDone = TRUE; + nb_set_curbuf(buf->bufp); + #if defined(FEAT_AUTOCMD) +*************** +*** 2081,2087 **** + ECMD_HIDE + ECMD_OLDBUF, curwin); + buf->bufp = curbuf; + buf->initDone = TRUE; +! doupdate = 1; + #if defined(FEAT_TITLE) + maketitle(); + #endif +--- 2081,2087 ---- + ECMD_HIDE + ECMD_OLDBUF, curwin); + buf->bufp = curbuf; + buf->initDone = TRUE; +! do_update = 1; + #if defined(FEAT_TITLE) + maketitle(); + #endif +*************** +*** 2109,2115 **** + exarg.forceit = FALSE; + dosetvisible = TRUE; + goto_buffer(&exarg, DOBUF_FIRST, FORWARD, buf->bufp->b_fnum); +! doupdate = 1; + dosetvisible = FALSE; + + #ifdef FEAT_GUI +--- 2109,2115 ---- + exarg.forceit = FALSE; + dosetvisible = TRUE; + goto_buffer(&exarg, DOBUF_FIRST, FORWARD, buf->bufp->b_fnum); +! do_update = 1; + dosetvisible = FALSE; + + #ifdef FEAT_GUI +*************** +*** 2309,2315 **** + buf->bufp->b_fnum, TRUE); + buf->bufp = NULL; + buf->initDone = FALSE; +! doupdate = 1; + /* =====================================================================*/ + } + else if (streq((char *)cmd, "setStyle")) /* obsolete... */ +--- 2309,2315 ---- + buf->bufp->b_fnum, TRUE); + buf->bufp = NULL; + buf->initDone = FALSE; +! do_update = 1; + /* =====================================================================*/ + } + else if (streq((char *)cmd, "setStyle")) /* obsolete... */ +*************** +*** 2400,2406 **** + return FAIL; + } + +! doupdate = 1; + + cp = (char *)args; + serNum = strtol(cp, &cp, 10); +--- 2400,2406 ---- + return FAIL; + } + +! do_update = 1; + + cp = (char *)args; + serNum = strtol(cp, &cp, 10); +*************** +*** 2448,2454 **** + nbdebug((" invalid buffer identifier in removeAnno\n")); + return FAIL; + } +! doupdate = 1; + cp = (char *)args; + serNum = strtol(cp, &cp, 10); + args = (char_u *)cp; +--- 2448,2454 ---- + nbdebug((" invalid buffer identifier in removeAnno\n")); + return FAIL; + } +! do_update = 1; + cp = (char *)args; + serNum = strtol(cp, &cp, 10); + args = (char_u *)cp; +*************** +*** 2493,2499 **** + len = strtol(cp, NULL, 10); + args = (char_u *)cp; + pos = off2pos(buf->bufp, off); +! doupdate = 1; + if (!pos) + nbdebug((" no such start pos in %s, %ld\n", cmd, off)); + else +--- 2493,2499 ---- + len = strtol(cp, NULL, 10); + args = (char_u *)cp; + pos = off2pos(buf->bufp, off); +! do_update = 1; + if (!pos) + nbdebug((" no such start pos in %s, %ld\n", cmd, off)); + else +*************** +*** 2555,2561 **** + inAtomic = 0; + if (needupdate) + { +! doupdate = 1; + needupdate = 0; + } + /* =====================================================================*/ +--- 2555,2561 ---- + inAtomic = 0; + if (needupdate) + { +! do_update = 1; + needupdate = 0; + } + /* =====================================================================*/ +*************** +*** 2636,2653 **** + * Unrecognized command is ignored. + */ + } +! if (inAtomic && doupdate) + { + needupdate = 1; +! doupdate = 0; + } + + /* + * Is this needed? I moved the netbeans_Xt_connect() later during startup + * and it may no longer be necessary. If its not needed then needupdate +! * and doupdate can also be removed. + */ +! if (buf != NULL && buf->initDone && doupdate) + { + update_screen(NOT_VALID); + setcursor(); +--- 2636,2653 ---- + * Unrecognized command is ignored. + */ + } +! if (inAtomic && do_update) + { + needupdate = 1; +! do_update = 0; + } + + /* + * Is this needed? I moved the netbeans_Xt_connect() later during startup + * and it may no longer be necessary. If its not needed then needupdate +! * and do_update can also be removed. + */ +! if (buf != NULL && buf->initDone && do_update) + { + update_screen(NOT_VALID); + setcursor(); +*** ../vim-7.3.399/src/option.c 2012-01-04 19:34:32.000000000 +0100 +--- src/option.c 2012-01-10 22:06:03.000000000 +0100 +*************** +*** 8584,8591 **** + long_u flags; + { + /* Careful: P_RCLR and P_RALL are a combination of other P_ flags */ +! int clear = (flags & P_RCLR) == P_RCLR; +! int all = ((flags & P_RALL) == P_RALL || clear); + + #ifdef FEAT_WINDOWS + if ((flags & P_RSTAT) || all) /* mark all status lines dirty */ +--- 8584,8591 ---- + long_u flags; + { + /* Careful: P_RCLR and P_RALL are a combination of other P_ flags */ +! int doclear = (flags & P_RCLR) == P_RCLR; +! int all = ((flags & P_RALL) == P_RALL || doclear); + + #ifdef FEAT_WINDOWS + if ((flags & P_RSTAT) || all) /* mark all status lines dirty */ +*************** +*** 8596,8602 **** + changed_window_setting(); + if (flags & P_RBUF) + redraw_curbuf_later(NOT_VALID); +! if (clear) + redraw_all_later(CLEAR); + else if (all) + redraw_all_later(NOT_VALID); +--- 8596,8602 ---- + changed_window_setting(); + if (flags & P_RBUF) + redraw_curbuf_later(NOT_VALID); +! if (doclear) + redraw_all_later(CLEAR); + else if (all) + redraw_all_later(NOT_VALID); +*** ../vim-7.3.399/src/os_unix.c 2011-10-20 21:09:25.000000000 +0200 +--- src/os_unix.c 2012-01-10 21:48:49.000000000 +0100 +*************** +*** 3884,3890 **** + char_u *p_shcf_copy = NULL; + int i; + char_u *p; +- char_u *s; + int inquote; + int pty_master_fd = -1; /* for pty's */ + # ifdef FEAT_GUI +--- 3884,3889 ---- +*************** +*** 3963,3968 **** +--- 3962,3969 ---- + } + if (cmd != NULL) + { ++ char_u *s; ++ + if (extra_shell_arg != NULL) + argv[argc++] = (char *)extra_shell_arg; + +*************** +*** 4325,4331 **** + linenr_T lnum = curbuf->b_op_start.lnum; + int written = 0; + char_u *lp = ml_get(lnum); +- char_u *s; + size_t l; + + close(fromshell_fd); +--- 4326,4331 ---- +*************** +*** 4339,4345 **** + len = write(toshell_fd, "", (size_t)1); + else + { +! s = vim_strchr(lp + written, NL); + len = write(toshell_fd, (char *)lp + written, + s == NULL ? l + : (size_t)(s - (lp + written))); +--- 4339,4346 ---- + len = write(toshell_fd, "", (size_t)1); + else + { +! char_u *s = vim_strchr(lp + written, NL); +! + len = write(toshell_fd, (char *)lp + written, + s == NULL ? l + : (size_t)(s - (lp + written))); +*** ../vim-7.3.399/src/screen.c 2012-01-10 12:42:05.000000000 +0100 +--- src/screen.c 2012-01-10 22:06:51.000000000 +0100 +*************** +*** 7849,7863 **** + + /* + * screen_valid - allocate screen buffers if size changed +! * If "clear" is TRUE: clear screen if it has been resized. + * Returns TRUE if there is a valid screen to write to. + * Returns FALSE when starting up and screen not initialized yet. + */ + int +! screen_valid(clear) +! int clear; + { +! screenalloc(clear); /* allocate screen buffers if size changed */ + return (ScreenLines != NULL); + } + +--- 7849,7863 ---- + + /* + * screen_valid - allocate screen buffers if size changed +! * If "doclear" is TRUE: clear screen if it has been resized. + * Returns TRUE if there is a valid screen to write to. + * Returns FALSE when starting up and screen not initialized yet. + */ + int +! screen_valid(doclear) +! int doclear; + { +! screenalloc(doclear); /* allocate screen buffers if size changed */ + return (ScreenLines != NULL); + } + +*************** +*** 7872,7879 **** + * final size of the shell is needed. + */ + void +! screenalloc(clear) +! int clear; + { + int new_row, old_row; + #ifdef FEAT_GUI +--- 7872,7879 ---- + * final size of the shell is needed. + */ + void +! screenalloc(doclear) +! int doclear; + { + int new_row, old_row; + #ifdef FEAT_GUI +*************** +*** 8069,8075 **** + * (used when resizing the window at the "--more--" prompt or when + * executing an external command, for the GUI). + */ +! if (!clear) + { + (void)vim_memset(new_ScreenLines + new_row * Columns, + ' ', (size_t)Columns * sizeof(schar_T)); +--- 8069,8075 ---- + * (used when resizing the window at the "--more--" prompt or when + * executing an external command, for the GUI). + */ +! if (!doclear) + { + (void)vim_memset(new_ScreenLines + new_row * Columns, + ' ', (size_t)Columns * sizeof(schar_T)); +*************** +*** 8159,8165 **** + screen_Columns = Columns; + + must_redraw = CLEAR; /* need to clear the screen later */ +! if (clear) + screenclear2(); + + #ifdef FEAT_GUI +--- 8159,8165 ---- + screen_Columns = Columns; + + must_redraw = CLEAR; /* need to clear the screen later */ +! if (doclear) + screenclear2(); + + #ifdef FEAT_GUI +*** ../vim-7.3.399/src/search.c 2011-10-04 17:00:13.000000000 +0200 +--- src/search.c 2012-01-10 22:07:16.000000000 +0100 +*************** +*** 2402,2425 **** + { + if (vim_strchr(p, ';') != NULL) /* there may be comments */ + { +! int instr = FALSE; /* inside of string */ + + p = line; /* scan from start */ + while ((p = vim_strpbrk(p, (char_u *)"\";")) != NULL) + { + if (*p == '"') + { +! if (instr) + { + if (*(p - 1) != '\\') /* skip escaped quote */ +! instr = FALSE; + } + else if (p == line || ((p - line) >= 2 + /* skip #\" form */ + && *(p - 1) != '\\' && *(p - 2) != '#')) +! instr = TRUE; + } +! else if (!instr && ((p - line) < 2 + || (*(p - 1) != '\\' && *(p - 2) != '#'))) + break; /* found! */ + ++p; +--- 2402,2425 ---- + { + if (vim_strchr(p, ';') != NULL) /* there may be comments */ + { +! int in_str = FALSE; /* inside of string */ + + p = line; /* scan from start */ + while ((p = vim_strpbrk(p, (char_u *)"\";")) != NULL) + { + if (*p == '"') + { +! if (in_str) + { + if (*(p - 1) != '\\') /* skip escaped quote */ +! in_str = FALSE; + } + else if (p == line || ((p - line) >= 2 + /* skip #\" form */ + && *(p - 1) != '\\' && *(p - 2) != '#')) +! in_str = TRUE; + } +! else if (!in_str && ((p - line) < 2 + || (*(p - 1) != '\\' && *(p - 2) != '#'))) + break; /* found! */ + ++p; +*** ../vim-7.3.399/src/spell.c 2012-01-10 16:28:41.000000000 +0100 +--- src/spell.c 2012-01-10 22:09:23.000000000 +0100 +*************** +*** 5049,5055 **** + static int offset2bytes __ARGS((int nr, char_u *buf)); + static int bytes2offset __ARGS((char_u **pp)); + static void sug_write __ARGS((spellinfo_T *spin, char_u *fname)); +! static void mkspell __ARGS((int fcount, char_u **fnames, int ascii, int overwrite, int added_word)); + static void spell_message __ARGS((spellinfo_T *spin, char_u *str)); + static void init_spellfile __ARGS((void)); + +--- 5049,5055 ---- + static int offset2bytes __ARGS((int nr, char_u *buf)); + static int bytes2offset __ARGS((char_u **pp)); + static void sug_write __ARGS((spellinfo_T *spin, char_u *fname)); +! static void mkspell __ARGS((int fcount, char_u **fnames, int ascii, int over_write, int added_word)); + static void spell_message __ARGS((spellinfo_T *spin, char_u *str)); + static void init_spellfile __ARGS((void)); + +*************** +*** 9085,9095 **** + * and ".spl" is appended to make the output file name. + */ + static void +! mkspell(fcount, fnames, ascii, overwrite, added_word) + int fcount; + char_u **fnames; + int ascii; /* -ascii argument given */ +! int overwrite; /* overwrite existing output file */ + int added_word; /* invoked through "zg" */ + { + char_u *fname = NULL; +--- 9085,9095 ---- + * and ".spl" is appended to make the output file name. + */ + static void +! mkspell(fcount, fnames, ascii, over_write, added_word) + int fcount; + char_u **fnames; + int ascii; /* -ascii argument given */ +! int over_write; /* overwrite existing output file */ + int added_word; /* invoked through "zg" */ + { + char_u *fname = NULL; +*************** +*** 9173,9179 **** + { + /* Check for overwriting before doing things that may take a lot of + * time. */ +! if (!overwrite && mch_stat((char *)wfname, &st) >= 0) + { + EMSG(_(e_exists)); + goto theend; +--- 9173,9179 ---- + { + /* Check for overwriting before doing things that may take a lot of + * time. */ +! if (!over_write && mch_stat((char *)wfname, &st) >= 0) + { + EMSG(_(e_exists)); + goto theend; +*** ../vim-7.3.399/src/syntax.c 2011-06-19 04:54:17.000000000 +0200 +--- src/syntax.c 2012-01-10 22:10:23.000000000 +0100 +*************** +*** 4006,4022 **** + } + + static void +! syn_list_flags(nl, flags, attr) +! struct name_list *nl; + int flags; + int attr; + { + int i; + +! for (i = 0; nl[i].flag != 0; ++i) +! if (flags & nl[i].flag) + { +! msg_puts_attr((char_u *)nl[i].name, attr); + msg_putchar(' '); + } + } +--- 4006,4022 ---- + } + + static void +! syn_list_flags(nlist, flags, attr) +! struct name_list *nlist; + int flags; + int attr; + { + int i; + +! for (i = 0; nlist[i].flag != 0; ++i) +! if (flags & nlist[i].flag) + { +! msg_puts_attr((char_u *)nlist[i].name, attr); + msg_putchar(' '); + } + } +*** ../vim-7.3.399/src/tag.c 2011-12-14 14:15:12.000000000 +0100 +--- src/tag.c 2012-01-10 21:51:05.000000000 +0100 +*************** +*** 1353,1359 **** + int match_count = 0; /* number of matches found */ + char_u **matches; + int mtt; +- int len; + int help_save; + #ifdef FEAT_MULTI_LANG + int help_pri = 0; +--- 1353,1358 ---- +*************** +*** 2235,2240 **** +--- 2234,2241 ---- + */ + if (ga_grow(&ga_match[mtt], 1) == OK) + { ++ int len; ++ + if (help_only) + { + #ifdef FEAT_MULTI_LANG +*** ../vim-7.3.399/src/window.c 2011-12-30 15:01:55.000000000 +0100 +--- src/window.c 2012-01-10 22:11:41.000000000 +0100 +*************** +*** 683,701 **** + } + + /* +! * When "newwin" is NULL: split the current window in two. +! * When "newwin" is not NULL: insert this window at the far + * top/left/right/bottom. + * return FAIL for failure, OK otherwise + */ + int +! win_split_ins(size, flags, newwin, dir) + int size; + int flags; +! win_T *newwin; + int dir; + { +! win_T *wp = newwin; + win_T *oldwin; + int new_size = size; + int i; +--- 683,701 ---- + } + + /* +! * When "new_wp" is NULL: split the current window in two. +! * When "new_wp" is not NULL: insert this window at the far + * top/left/right/bottom. + * return FAIL for failure, OK otherwise + */ + int +! win_split_ins(size, flags, new_wp, dir) + int size; + int flags; +! win_T *new_wp; + int dir; + { +! win_T *wp = new_wp; + win_T *oldwin; + int new_size = size; + int i; +*************** +*** 718,724 **** + /* add a status line when p_ls == 1 and splitting the first window */ + if (lastwin == firstwin && p_ls == 1 && oldwin->w_status_height == 0) + { +! if (oldwin->w_height <= p_wmh && newwin == NULL) + { + EMSG(_(e_noroom)); + return FAIL; +--- 718,724 ---- + /* add a status line when p_ls == 1 and splitting the first window */ + if (lastwin == firstwin && p_ls == 1 && oldwin->w_status_height == 0) + { +! if (oldwin->w_height <= p_wmh && new_wp == NULL) + { + EMSG(_(e_noroom)); + return FAIL; +*************** +*** 751,757 **** + } + else + available = oldwin->w_width; +! if (available < needed && newwin == NULL) + { + EMSG(_(e_noroom)); + return FAIL; +--- 751,757 ---- + } + else + available = oldwin->w_width; +! if (available < needed && new_wp == NULL) + { + EMSG(_(e_noroom)); + return FAIL; +*************** +*** 815,821 **** + available = oldwin->w_height; + needed += p_wmh; + } +! if (available < needed && newwin == NULL) + { + EMSG(_(e_noroom)); + return FAIL; +--- 815,821 ---- + available = oldwin->w_height; + needed += p_wmh; + } +! if (available < needed && new_wp == NULL) + { + EMSG(_(e_noroom)); + return FAIL; +*************** +*** 888,907 **** + p_sb)))) + { + /* new window below/right of current one */ +! if (newwin == NULL) + wp = win_alloc(oldwin, FALSE); + else + win_append(oldwin, wp); + } + else + { +! if (newwin == NULL) + wp = win_alloc(oldwin->w_prev, FALSE); + else + win_append(oldwin->w_prev, wp); + } + +! if (newwin == NULL) + { + if (wp == NULL) + return FAIL; +--- 888,907 ---- + p_sb)))) + { + /* new window below/right of current one */ +! if (new_wp == NULL) + wp = win_alloc(oldwin, FALSE); + else + win_append(oldwin, wp); + } + else + { +! if (new_wp == NULL) + wp = win_alloc(oldwin->w_prev, FALSE); + else + win_append(oldwin->w_prev, wp); + } + +! if (new_wp == NULL) + { + if (wp == NULL) + return FAIL; +*************** +*** 972,981 **** + frp->fr_parent = curfrp; + } + +! if (newwin == NULL) + frp = wp->w_frame; + else +! frp = newwin->w_frame; + frp->fr_parent = curfrp->fr_parent; + + /* Insert the new frame at the right place in the frame list. */ +--- 972,981 ---- + frp->fr_parent = curfrp; + } + +! if (new_wp == NULL) + frp = wp->w_frame; + else +! frp = new_wp->w_frame; + frp->fr_parent = curfrp->fr_parent; + + /* Insert the new frame at the right place in the frame list. */ +*************** +*** 4284,4302 **** + win_T *after UNUSED; + int hidden UNUSED; + { +! win_T *newwin; + + /* + * allocate window structure and linesizes arrays + */ +! newwin = (win_T *)alloc_clear((unsigned)sizeof(win_T)); +! if (newwin != NULL && win_alloc_lines(newwin) == FAIL) + { +! vim_free(newwin); +! newwin = NULL; + } + +! if (newwin != NULL) + { + #ifdef FEAT_AUTOCMD + /* Don't execute autocommands while the window is not properly +--- 4284,4302 ---- + win_T *after UNUSED; + int hidden UNUSED; + { +! win_T *new_wp; + + /* + * allocate window structure and linesizes arrays + */ +! new_wp = (win_T *)alloc_clear((unsigned)sizeof(win_T)); +! if (new_wp != NULL && win_alloc_lines(new_wp) == FAIL) + { +! vim_free(new_wp); +! new_wp = NULL; + } + +! if (new_wp != NULL) + { + #ifdef FEAT_AUTOCMD + /* Don't execute autocommands while the window is not properly +*************** +*** 4309,4361 **** + */ + #ifdef FEAT_WINDOWS + if (!hidden) +! win_append(after, newwin); + #endif + #ifdef FEAT_VERTSPLIT +! newwin->w_wincol = 0; +! newwin->w_width = Columns; + #endif + + /* position the display and the cursor at the top of the file. */ +! newwin->w_topline = 1; + #ifdef FEAT_DIFF +! newwin->w_topfill = 0; + #endif +! newwin->w_botline = 2; +! newwin->w_cursor.lnum = 1; + #ifdef FEAT_SCROLLBIND +! newwin->w_scbind_pos = 1; + #endif + + /* We won't calculate w_fraction until resizing the window */ +! newwin->w_fraction = 0; +! newwin->w_prev_fraction_row = -1; + + #ifdef FEAT_GUI + if (gui.in_use) + { +! gui_create_scrollbar(&newwin->w_scrollbars[SBAR_LEFT], +! SBAR_LEFT, newwin); +! gui_create_scrollbar(&newwin->w_scrollbars[SBAR_RIGHT], +! SBAR_RIGHT, newwin); + } + #endif + #ifdef FEAT_EVAL + /* init w: variables */ +! init_var_dict(&newwin->w_vars, &newwin->w_winvar); + #endif + #ifdef FEAT_FOLDING +! foldInitWin(newwin); + #endif + #ifdef FEAT_AUTOCMD + unblock_autocmds(); + #endif + #ifdef FEAT_SEARCH_EXTRA +! newwin->w_match_head = NULL; +! newwin->w_next_match_id = 4; + #endif + } +! return newwin; + } + + #if defined(FEAT_WINDOWS) || defined(PROTO) +--- 4309,4361 ---- + */ + #ifdef FEAT_WINDOWS + if (!hidden) +! win_append(after, new_wp); + #endif + #ifdef FEAT_VERTSPLIT +! new_wp->w_wincol = 0; +! new_wp->w_width = Columns; + #endif + + /* position the display and the cursor at the top of the file. */ +! new_wp->w_topline = 1; + #ifdef FEAT_DIFF +! new_wp->w_topfill = 0; + #endif +! new_wp->w_botline = 2; +! new_wp->w_cursor.lnum = 1; + #ifdef FEAT_SCROLLBIND +! new_wp->w_scbind_pos = 1; + #endif + + /* We won't calculate w_fraction until resizing the window */ +! new_wp->w_fraction = 0; +! new_wp->w_prev_fraction_row = -1; + + #ifdef FEAT_GUI + if (gui.in_use) + { +! gui_create_scrollbar(&new_wp->w_scrollbars[SBAR_LEFT], +! SBAR_LEFT, new_wp); +! gui_create_scrollbar(&new_wp->w_scrollbars[SBAR_RIGHT], +! SBAR_RIGHT, new_wp); + } + #endif + #ifdef FEAT_EVAL + /* init w: variables */ +! init_var_dict(&new_wp->w_vars, &new_wp->w_winvar); + #endif + #ifdef FEAT_FOLDING +! foldInitWin(new_wp); + #endif + #ifdef FEAT_AUTOCMD + unblock_autocmds(); + #endif + #ifdef FEAT_SEARCH_EXTRA +! new_wp->w_match_head = NULL; +! new_wp->w_next_match_id = 4; + #endif + } +! return new_wp; + } + + #if defined(FEAT_WINDOWS) || defined(PROTO) +*** ../vim-7.3.399/src/version.c 2012-01-10 18:37:53.000000000 +0100 +--- src/version.c 2012-01-10 22:23:10.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 400, + /**/ + +-- +A parent can be arrested if his child cannot hold back a burp during a church +service. + [real standing law in Nebraska, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 52df027c22f83553f33ab0bfd0017bc9553f3dee Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:28 +0100 Subject: [PATCH 0128/3340] - patchlevel 401 --- 7.3.401 | 191 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 191 insertions(+) create mode 100644 7.3.401 diff --git a/7.3.401 b/7.3.401 new file mode 100644 index 00000000..6a473c57 --- /dev/null +++ b/7.3.401 @@ -0,0 +1,191 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.401 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.401 +Problem: A couple more shadowed variables. +Solution: Rename the variables. +Files: src/netbeans.c + + +*** ../vim-7.3.400/src/netbeans.c 2012-01-10 22:26:12.000000000 +0100 +--- src/netbeans.c 2012-01-10 22:30:17.000000000 +0100 +*************** +*** 443,449 **** + FILE *fp; + char_u buf[BUFSIZ]; + char_u *lp; +! char_u *nl; + #ifdef UNIX + struct stat st; + +--- 443,449 ---- + FILE *fp; + char_u buf[BUFSIZ]; + char_u *lp; +! char_u *nlp; + #ifdef UNIX + struct stat st; + +*************** +*** 472,479 **** + /* Read the file. There should be one of each parameter */ + while ((lp = (char_u *)fgets((char *)buf, BUFSIZ, fp)) != NULL) + { +! if ((nl = vim_strchr(lp, '\n')) != NULL) +! *nl = 0; /* strip off the trailing newline */ + + if (STRNCMP(lp, "host=", 5) == 0) + { +--- 472,479 ---- + /* Read the file. There should be one of each parameter */ + while ((lp = (char_u *)fgets((char *)buf, BUFSIZ, fp)) != NULL) + { +! if ((nlp = vim_strchr(lp, '\n')) != NULL) +! *nlp = 0; /* strip off the trailing newline */ + + if (STRNCMP(lp, "host=", 5) == 0) + { +*************** +*** 1740,1746 **** + int added = 0; + int oldFire = netbeansFireChanges; + int old_b_changed; +! char_u *nl; + linenr_T lnum; + linenr_T lnum_start; + pos_T *pos; +--- 1740,1746 ---- + int added = 0; + int oldFire = netbeansFireChanges; + int old_b_changed; +! char_u *nlp; + linenr_T lnum; + linenr_T lnum_start; + pos_T *pos; +*************** +*** 1780,1787 **** + do_update = 1; + while (*args != NUL) + { +! nl = vim_strchr(args, '\n'); +! if (nl == NULL) + { + /* Incomplete line, probably truncated. Next "insert" + * command should append to this one. */ +--- 1780,1787 ---- + do_update = 1; + while (*args != NUL) + { +! nlp = vim_strchr(args, '\n'); +! if (nlp == NULL) + { + /* Incomplete line, probably truncated. Next "insert" + * command should append to this one. */ +*************** +*** 1789,1801 **** + } + else + { +! len = nl - args; + + /* + * We need to detect EOL style, because the commands + * use a character offset. + */ +! if (nl > args && nl[-1] == '\r') + { + ff_detected = EOL_DOS; + --len; +--- 1789,1801 ---- + } + else + { +! len = nlp - args; + + /* + * We need to detect EOL style, because the commands + * use a character offset. + */ +! if (nlp > args && nlp[-1] == '\r') + { + ff_detected = EOL_DOS; + --len; +*************** +*** 1814,1820 **** + + /* Insert halfway a line. For simplicity we assume we + * need to append to the line. */ +! newline = alloc_check((unsigned)(STRLEN(oldline) + len + 1)); + if (newline != NULL) + { + STRCPY(newline, oldline); +--- 1814,1821 ---- + + /* Insert halfway a line. For simplicity we assume we + * need to append to the line. */ +! newline = alloc_check( +! (unsigned)(STRLEN(oldline) + len + 1)); + if (newline != NULL) + { + STRCPY(newline, oldline); +*************** +*** 1826,1839 **** + { + /* Append a new line. Not that we always do this, + * also when the text doesn't end in a "\n". */ +! ml_append((linenr_T)(lnum - 1), args, (colnr_T)(len + 1), FALSE); + ++added; + } + +! if (nl == NULL) + break; + ++lnum; +! args = nl + 1; + } + + /* Adjust the marks below the inserted lines. */ +--- 1827,1841 ---- + { + /* Append a new line. Not that we always do this, + * also when the text doesn't end in a "\n". */ +! ml_append((linenr_T)(lnum - 1), args, +! (colnr_T)(len + 1), FALSE); + ++added; + } + +! if (nlp == NULL) + break; + ++lnum; +! args = nlp + 1; + } + + /* Adjust the marks below the inserted lines. */ +*** ../vim-7.3.400/src/version.c 2012-01-10 22:26:12.000000000 +0100 +--- src/version.c 2012-01-10 22:30:47.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 401, + /**/ + +-- +So when I saw the post to comp.editors, I rushed over to the FTP site to +grab it. So I yank apart the tarball, light x candles, where x= the +vim version multiplied by the md5sum of the source divided by the MAC of +my NIC (8A3FA78155A8A1D346C3C4A), put on black robes, dim the lights, +wave a dead chicken over the hard drive, and summon the power of GNU GCC +with the magic words "make config ; make!". + [Jason Spence, compiling Vim 5.0] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fefa3ff3a379cf74b575f56a29900ff3d3daf3d6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:29 +0100 Subject: [PATCH 0129/3340] - patchlevel 402 --- 7.3.402 | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.402 diff --git a/7.3.402 b/7.3.402 new file mode 100644 index 00000000..a5501f8c --- /dev/null +++ b/7.3.402 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.402 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.402 +Problem: When jumping to the first error a line of the buffer is sometimes + redrawn on top of the list of errors. +Solution: Do not call update_topline_redraw() if the display was scrolled + up. +Files: src/quickfix.c + + +*** ../vim-7.3.401/src/quickfix.c 2012-01-10 17:13:48.000000000 +0100 +--- src/quickfix.c 2012-01-20 13:13:25.000000000 +0100 +*************** +*** 1842,1849 **** + #endif + if (print_message) + { +! /* Update the screen before showing the message */ +! update_topline_redraw(); + sprintf((char *)IObuff, _("(%d of %d)%s%s: "), qf_index, + qi->qf_lists[qi->qf_curlist].qf_count, + qf_ptr->qf_cleared ? _(" (line deleted)") : "", +--- 1842,1851 ---- + #endif + if (print_message) + { +! /* Update the screen before showing the message, unless the screen +! * scrolled up. */ +! if (!msg_scrolled) +! update_topline_redraw(); + sprintf((char *)IObuff, _("(%d of %d)%s%s: "), qf_index, + qi->qf_lists[qi->qf_curlist].qf_count, + qf_ptr->qf_cleared ? _(" (line deleted)") : "", +*** ../vim-7.3.401/src/version.c 2012-01-10 22:31:26.000000000 +0100 +--- src/version.c 2012-01-20 13:17:50.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 402, + /**/ + +-- +If all you have is a hammer, everything looks like a nail. +When your hammer is C++, everything begins to look like a thumb. + -- Steve Hoflich, comp.lang.c++ + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From aa7dd6dea7ab516f4884b50817efcd74072e07b4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:29 +0100 Subject: [PATCH 0130/3340] - patchlevel 403 --- 7.3.403 | 108 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 108 insertions(+) create mode 100644 7.3.403 diff --git a/7.3.403 b/7.3.403 new file mode 100644 index 00000000..bc3bf549 --- /dev/null +++ b/7.3.403 @@ -0,0 +1,108 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.403 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.403 +Problem: ":helpgrep" does not trigger QuickFixCmd* autocommands. +Solution: Trigger the autocommands. (Christian Brabandt) +Files: src/quickfix.c + + +*** ../vim-7.3.402/src/quickfix.c 2012-01-20 13:28:28.000000000 +0100 +--- src/quickfix.c 2012-01-20 13:37:10.000000000 +0100 +*************** +*** 3878,3893 **** + qf_info_T *qi = &ql_info; + int new_qi = FALSE; + win_T *wp; +! +! /* Make 'cpoptions' empty, the 'l' flag should not be used here. */ +! save_cpo = p_cpo; +! p_cpo = empty_option; + + #ifdef FEAT_MULTI_LANG + /* Check for a specified language */ + lang = check_help_lang(eap->arg); + #endif + + if (eap->cmdidx == CMD_lhelpgrep) + { + /* Find an existing help window */ +--- 3878,3912 ---- + qf_info_T *qi = &ql_info; + int new_qi = FALSE; + win_T *wp; +! #ifdef FEAT_AUTOCMD +! char_u *au_name = NULL; +! #endif + + #ifdef FEAT_MULTI_LANG + /* Check for a specified language */ + lang = check_help_lang(eap->arg); + #endif + ++ #ifdef FEAT_AUTOCMD ++ switch (eap->cmdidx) ++ { ++ case CMD_helpgrep: au_name = (char_u *)"helpgrep"; break; ++ case CMD_lhelpgrep: au_name = (char_u *)"lhelpgrep"; break; ++ default: break; ++ } ++ if (au_name != NULL) ++ { ++ apply_autocmds(EVENT_QUICKFIXCMDPRE, au_name, ++ curbuf->b_fname, TRUE, curbuf); ++ if (did_throw || force_abort) ++ return; ++ } ++ #endif ++ ++ /* Make 'cpoptions' empty, the 'l' flag should not be used here. */ ++ save_cpo = p_cpo; ++ p_cpo = empty_option; ++ + if (eap->cmdidx == CMD_lhelpgrep) + { + /* Find an existing help window */ +*************** +*** 4036,4041 **** +--- 4055,4071 ---- + qf_update_buffer(qi); + #endif + ++ #ifdef FEAT_AUTOCMD ++ if (au_name != NULL) ++ { ++ apply_autocmds(EVENT_QUICKFIXCMDPOST, au_name, ++ curbuf->b_fname, TRUE, curbuf); ++ if (!new_qi && qi != &ql_info && qf_find_buf(qi) == NULL) ++ /* autocommands made "qi" invalid */ ++ return; ++ } ++ #endif ++ + /* Jump to first match. */ + if (qi->qf_lists[qi->qf_curlist].qf_count > 0) + qf_jump(qi, 0, 0, FALSE); +*** ../vim-7.3.402/src/version.c 2012-01-20 13:28:28.000000000 +0100 +--- src/version.c 2012-01-20 13:30:37.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 403, + /**/ + +-- +Looking at Perl through Lisp glasses, Perl looks atrocious. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From dd421e8e5ad2c582d5189d140084886917311a7e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:30 +0100 Subject: [PATCH 0131/3340] - patchlevel 404 --- 7.3.404 | 85 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100644 7.3.404 diff --git a/7.3.404 b/7.3.404 new file mode 100644 index 00000000..445d7051 --- /dev/null +++ b/7.3.404 @@ -0,0 +1,85 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.404 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.404 +Problem: When a complete function uses refresh "always" redo will not work + properly. +Solution: Do not reset compl_leader when compl_opt_refresh_always is set. + (Yasuhiro Matsumoto) +Files: src/edit.c + + +*** ../vim-7.3.403/src/edit.c 2012-01-10 22:26:12.000000000 +0100 +--- src/edit.c 2012-01-20 14:26:06.000000000 +0100 +*************** +*** 3465,3475 **** + if (ins_compl_need_restart()) + ins_compl_restart(); + +! vim_free(compl_leader); +! compl_leader = vim_strnsave(ml_get_curline() + compl_col, + (int)(curwin->w_cursor.col - compl_col)); +! if (compl_leader != NULL) +! ins_compl_new_leader(); + } + + /* +--- 3465,3481 ---- + if (ins_compl_need_restart()) + ins_compl_restart(); + +! /* When 'always' is set, don't reset compl_leader. While completing, +! * cursor don't point original position, changing compl_leader would +! * break redo. */ +! if (!compl_opt_refresh_always) +! { +! vim_free(compl_leader); +! compl_leader = vim_strnsave(ml_get_curline() + compl_col, + (int)(curwin->w_cursor.col - compl_col)); +! if (compl_leader != NULL) +! ins_compl_new_leader(); +! } + } + + /* +*************** +*** 4554,4559 **** +--- 4560,4570 ---- + int found_end = FALSE; + int advance; + ++ /* When user complete function return -1 for findstart which is next ++ * time of 'always', compl_shown_match become NULL. */ ++ if (compl_shown_match == NULL) ++ return -1; ++ + if (compl_leader != NULL + && (compl_shown_match->cp_flags & ORIGINAL_TEXT) == 0) + { +*** ../vim-7.3.403/src/version.c 2012-01-20 13:39:03.000000000 +0100 +--- src/version.c 2012-01-20 14:31:26.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 404, + /**/ + +-- +ARTHUR: I've said I'm sorry about the old woman, but from the behind you + looked ... +DENNIS: What I object to is that you automatically treat me like an inferior... +ARTHUR: Well ... I AM king. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d618c280ddaeb2fa51029d4c73b4b7de17539bfb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:30 +0100 Subject: [PATCH 0132/3340] - patchlevel 405 --- 7.3.405 | 101 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 101 insertions(+) create mode 100644 7.3.405 diff --git a/7.3.405 b/7.3.405 new file mode 100644 index 00000000..087aecc4 --- /dev/null +++ b/7.3.405 @@ -0,0 +1,101 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.405 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.405 +Problem: When xterm gets back the function keys it may delete the urxvt + mouse termcap code. +Solution: Check for the whole code, not just the start. (Egmont Koblinger) +Files: src/keymap.h, src/misc2.c, src/term.c + + +*** ../vim-7.3.404/src/keymap.h 2011-10-20 21:09:25.000000000 +0200 +--- src/keymap.h 2012-01-20 16:35:43.000000000 +0100 +*************** +*** 411,416 **** +--- 411,417 ---- + #define K_DEC_MOUSE TERMCAP2KEY(KS_DEC_MOUSE, KE_FILLER) + #define K_JSBTERM_MOUSE TERMCAP2KEY(KS_JSBTERM_MOUSE, KE_FILLER) + #define K_PTERM_MOUSE TERMCAP2KEY(KS_PTERM_MOUSE, KE_FILLER) ++ #define K_URXVT_MOUSE TERMCAP2KEY(KS_URXVT_MOUSE, KE_FILLER) + + #define K_SELECT TERMCAP2KEY(KS_SELECT, KE_FILLER) + #define K_TEAROFF TERMCAP2KEY(KS_TEAROFF, KE_FILLER) +*** ../vim-7.3.404/src/misc2.c 2012-01-10 22:26:12.000000000 +0100 +--- src/misc2.c 2012-01-20 16:38:27.000000000 +0100 +*************** +*** 2416,2425 **** +--- 2416,2436 ---- + {'<', (char_u *)"lt"}, + + {K_MOUSE, (char_u *)"Mouse"}, ++ #ifdef FEAT_MOUSE_NET + {K_NETTERM_MOUSE, (char_u *)"NetMouse"}, ++ #endif ++ #ifdef FEAT_MOUSE_DEC + {K_DEC_MOUSE, (char_u *)"DecMouse"}, ++ #endif ++ #ifdef FEAT_MOUSE_JSB + {K_JSBTERM_MOUSE, (char_u *)"JsbMouse"}, ++ #endif ++ #ifdef FEAT_MOUSE_PTERM + {K_PTERM_MOUSE, (char_u *)"PtermMouse"}, ++ #endif ++ #ifdef FEAT_MOUSE_URXVT ++ {K_URXVT_MOUSE, (char_u *)"UrxvtMouse"}, ++ #endif + {K_LEFTMOUSE, (char_u *)"LeftMouse"}, + {K_LEFTMOUSE_NM, (char_u *)"LeftMouseNM"}, + {K_LEFTDRAG, (char_u *)"LeftDrag"}, +*** ../vim-7.3.404/src/term.c 2011-12-01 20:59:16.000000000 +0100 +--- src/term.c 2012-01-20 16:50:41.000000000 +0100 +*************** +*** 5252,5263 **** + char_u *src; + { + int i; +! int slen; + + for (i = 0; i < tc_len; ++i) + { +! slen = termcodes[i].len; +! if (slen > 1 && STRNCMP(termcodes[i].code, src, (size_t)slen) == 0) + return i; + } + return -1; +--- 5252,5263 ---- + char_u *src; + { + int i; +! int slen = STRLEN(src); + + for (i = 0; i < tc_len; ++i) + { +! if (slen == termcodes[i].len +! && STRNCMP(termcodes[i].code, src, (size_t)slen) == 0) + return i; + } + return -1; +*** ../vim-7.3.404/src/version.c 2012-01-20 14:32:22.000000000 +0100 +--- src/version.c 2012-01-20 16:59:47.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 405, + /**/ + +-- +"The future's already arrived - it's just not evenly distributed yet." + -- William Gibson + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1c295479c24e5d727dcfee1c3b1f31ab87fc9946 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:30 +0100 Subject: [PATCH 0133/3340] - patchlevel 406 --- 7.3.406 | 103 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 103 insertions(+) create mode 100644 7.3.406 diff --git a/7.3.406 b/7.3.406 new file mode 100644 index 00000000..dceca0ed --- /dev/null +++ b/7.3.406 @@ -0,0 +1,103 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.406 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.406 +Problem: Multi-byte characters in b:browsefilter are not handled correctly. +Solution: First use convert_filter() normally and then convert to wide + characters. (Taro Muraoka) +Files: src/gui_w48.c + + +*** ../vim-7.3.405/src/gui_w48.c 2011-09-07 18:58:24.000000000 +0200 +--- src/gui_w48.c 2012-01-20 17:54:19.000000000 +0100 +*************** +*** 328,333 **** +--- 328,337 ---- + static LRESULT _OnImeNotify(HWND hWnd, DWORD dwCommand, DWORD dwData); + #endif + ++ #if defined(FEAT_MBYTE) && defined(WIN3264) ++ static char_u *convert_filter(char_u *s); ++ #endif ++ + #ifdef DEBUG_PRINT_ERROR + /* + * Print out the last Windows error message +*************** +*** 3275,3302 **** + + # if defined(FEAT_MBYTE) && defined(WIN3264) + /* +! * Wide version of convert_filter(). Keep in sync! + */ + static WCHAR * + convert_filterW(char_u *s) + { +! WCHAR *res; +! unsigned s_len = (unsigned)STRLEN(s); +! unsigned i; + +! res = (WCHAR *)alloc((s_len + 3) * sizeof(WCHAR)); +! if (res != NULL) +! { +! for (i = 0; i < s_len; ++i) +! if (s[i] == '\t' || s[i] == '\n') +! res[i] = '\0'; +! else +! res[i] = s[i]; +! res[s_len] = NUL; +! /* Add two extra NULs to make sure it's properly terminated. */ +! res[s_len + 1] = NUL; +! res[s_len + 2] = NUL; +! } + return res; + } + +--- 3279,3298 ---- + + # if defined(FEAT_MBYTE) && defined(WIN3264) + /* +! * Wide version of convert_filter(). + */ + static WCHAR * + convert_filterW(char_u *s) + { +! char_u *tmp; +! int len; + +! tmp = convert_filter(s); +! if (tmp == NULL) +! return NULL; +! len = (int)STRLEN(s) + 3; +! res = enc_to_utf16(tmp, &len); +! vim_free(tmp); + return res; + } + +*** ../vim-7.3.405/src/version.c 2012-01-20 17:15:47.000000000 +0100 +--- src/version.c 2012-01-20 17:57:09.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 406, + /**/ + +-- +DENNIS: Look, strange women lying on their backs in ponds handing out + swords ... that's no basis for a system of government. Supreme + executive power derives from a mandate from the masses, not from some + farcical aquatic ceremony. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b5c309534e3a7a168437e46c1424ca0d4aedde4d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:31 +0100 Subject: [PATCH 0134/3340] - patchlevel 407 --- 7.3.407 | 270 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 270 insertions(+) create mode 100644 7.3.407 diff --git a/7.3.407 b/7.3.407 new file mode 100644 index 00000000..d5ac1330 --- /dev/null +++ b/7.3.407 @@ -0,0 +1,270 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.407 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.407 +Problem: ":12verbose call F()" may duplicate text while trying to truncate. + (Thinca) +Solution: Only truncate when there is not enough room. Also check the byte + length of the buffer. +Files: src/buffer.c, src/eval.c, src/ex_getln.c, src/message.c, + src/proto/message.pro + + +*** ../vim-7.3.406/src/buffer.c 2011-12-30 13:39:04.000000000 +0100 +--- src/buffer.c 2012-01-20 18:37:43.000000000 +0100 +*************** +*** 3258,3266 **** + if (maxlen > 0) + { + /* make it shorter by removing a bit in the middle */ +! len = vim_strsize(buf); +! if (len > maxlen) +! trunc_string(buf, buf, maxlen); + } + } + } +--- 3258,3265 ---- + if (maxlen > 0) + { + /* make it shorter by removing a bit in the middle */ +! if (vim_strsize(buf) > maxlen) +! trunc_string(buf, buf, maxlen, IOSIZE); + } + } + } +*** ../vim-7.3.406/src/eval.c 2012-01-10 22:26:12.000000000 +0100 +--- src/eval.c 2012-01-20 20:43:32.000000000 +0100 +*************** +*** 22163,22170 **** + s = tv2string(&argvars[i], &tofree, numbuf2, 0); + if (s != NULL) + { +! trunc_string(s, buf, MSG_BUF_CLEN); +! msg_puts(buf); + vim_free(tofree); + } + } +--- 22163,22174 ---- + s = tv2string(&argvars[i], &tofree, numbuf2, 0); + if (s != NULL) + { +! if (vim_strsize(s) > MSG_BUF_CLEN) +! { +! trunc_string(s, buf, MSG_BUF_CLEN, MSG_BUF_LEN); +! s = buf; +! } +! msg_puts(s); + vim_free(tofree); + } + } +*************** +*** 22252,22259 **** + s = tv2string(fc->rettv, &tofree, numbuf2, 0); + if (s != NULL) + { +! trunc_string(s, buf, MSG_BUF_CLEN); +! smsg((char_u *)_("%s returning %s"), sourcing_name, buf); + vim_free(tofree); + } + } +--- 22256,22267 ---- + s = tv2string(fc->rettv, &tofree, numbuf2, 0); + if (s != NULL) + { +! if (vim_strsize(s) > MSG_BUF_CLEN) +! { +! trunc_string(s, buf, MSG_BUF_CLEN, MSG_BUF_LEN); +! s = buf; +! } +! smsg((char_u *)_("%s returning %s"), sourcing_name, s); + vim_free(tofree); + } + } +*** ../vim-7.3.406/src/ex_getln.c 2011-12-08 18:44:47.000000000 +0100 +--- src/ex_getln.c 2012-01-20 18:40:46.000000000 +0100 +*************** +*** 5923,5929 **** + hist[i].hisnum); + if (vim_strsize(hist[i].hisstr) > (int)Columns - 10) + trunc_string(hist[i].hisstr, IObuff + STRLEN(IObuff), +! (int)Columns - 10); + else + STRCAT(IObuff, hist[i].hisstr); + msg_outtrans(IObuff); +--- 5923,5929 ---- + hist[i].hisnum); + if (vim_strsize(hist[i].hisstr) > (int)Columns - 10) + trunc_string(hist[i].hisstr, IObuff + STRLEN(IObuff), +! (int)Columns - 10, IOSIZE - STRLEN(IObuff)); + else + STRCAT(IObuff, hist[i].hisstr); + msg_outtrans(IObuff); +*** ../vim-7.3.406/src/message.c 2012-01-10 22:26:12.000000000 +0100 +--- src/message.c 2012-01-20 20:38:29.000000000 +0100 +*************** +*** 222,236 **** + if (enc_utf8) + /* may have up to 18 bytes per cell (6 per char, up to two + * composing chars) */ +! buf = alloc((room + 2) * 18); + else if (enc_dbcs == DBCS_JPNU) + /* may have up to 2 bytes per cell for euc-jp */ +! buf = alloc((room + 2) * 2); + else + #endif +! buf = alloc(room + 2); + if (buf != NULL) +! trunc_string(s, buf, room); + } + } + return buf; +--- 222,237 ---- + if (enc_utf8) + /* may have up to 18 bytes per cell (6 per char, up to two + * composing chars) */ +! len = (room + 2) * 18; + else if (enc_dbcs == DBCS_JPNU) + /* may have up to 2 bytes per cell for euc-jp */ +! len = (room + 2) * 2; + else + #endif +! len = room + 2; +! buf = alloc(len); + if (buf != NULL) +! trunc_string(s, buf, room, len); + } + } + return buf; +*************** +*** 241,250 **** + * "s" and "buf" may be equal. + */ + void +! trunc_string(s, buf, room) + char_u *s; + char_u *buf; + int room; + { + int half; + int len; +--- 242,252 ---- + * "s" and "buf" may be equal. + */ + void +! trunc_string(s, buf, room, buflen) + char_u *s; + char_u *buf; + int room; ++ int buflen; + { + int half; + int len; +*************** +*** 257,263 **** + len = 0; + + /* First part: Start of the string. */ +! for (e = 0; len < half; ++e) + { + if (s[e] == NUL) + { +--- 259,265 ---- + len = 0; + + /* First part: Start of the string. */ +! for (e = 0; len < half && e < buflen; ++e) + { + if (s[e] == NUL) + { +*************** +*** 274,280 **** + if (has_mbyte) + for (n = (*mb_ptr2len)(s + e); --n > 0; ) + { +! ++e; + buf[e] = s[e]; + } + #endif +--- 276,283 ---- + if (has_mbyte) + for (n = (*mb_ptr2len)(s + e); --n > 0; ) + { +! if (++e == buflen) +! break; + buf[e] = s[e]; + } + #endif +*************** +*** 319,326 **** + } + + /* Set the middle and copy the last part. */ +! mch_memmove(buf + e, "...", (size_t)3); +! STRMOVE(buf + e + 3, s + i); + } + + /* +--- 322,340 ---- + } + + /* Set the middle and copy the last part. */ +! if (e + 3 < buflen) +! { +! mch_memmove(buf + e, "...", (size_t)3); +! len = STRLEN(s + i) + 1; +! if (len >= buflen - e - 3) +! len = buflen - e - 3 - 1; +! mch_memmove(buf + e + 3, s + i, len); +! buf[e + 3 + len - 1] = NUL; +! } +! else +! { +! buf[e - 1] = NUL; // make sure it is truncated +! } + } + + /* +*** ../vim-7.3.406/src/proto/message.pro 2011-01-17 20:08:03.000000000 +0100 +--- src/proto/message.pro 2012-01-20 18:51:19.000000000 +0100 +*************** +*** 4,10 **** + int msg_attr __ARGS((char_u *s, int attr)); + int msg_attr_keep __ARGS((char_u *s, int attr, int keep)); + char_u *msg_strtrunc __ARGS((char_u *s, int force)); +! void trunc_string __ARGS((char_u *s, char_u *buf, int room)); + void reset_last_sourcing __ARGS((void)); + void msg_source __ARGS((int attr)); + int emsg_not_now __ARGS((void)); +--- 4,10 ---- + int msg_attr __ARGS((char_u *s, int attr)); + int msg_attr_keep __ARGS((char_u *s, int attr, int keep)); + char_u *msg_strtrunc __ARGS((char_u *s, int force)); +! void trunc_string __ARGS((char_u *s, char_u *buf, int room, int buflen)); + void reset_last_sourcing __ARGS((void)); + void msg_source __ARGS((int attr)); + int emsg_not_now __ARGS((void)); +*** ../vim-7.3.406/src/version.c 2012-01-20 17:57:47.000000000 +0100 +--- src/version.c 2012-01-20 20:42:23.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 407, + /**/ + +-- +Hanson's Treatment of Time: + There are never enough hours in a day, but always too + many days before Saturday. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b4351cac5fd0617ebdb4f3a38b1c620ff2f5041c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:31 +0100 Subject: [PATCH 0135/3340] - patchlevel 408 --- 7.3.408 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.408 diff --git a/7.3.408 b/7.3.408 new file mode 100644 index 00000000..02276085 --- /dev/null +++ b/7.3.408 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.408 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.408 (after 7.3.406) +Problem: Missing declaration. +Solution: Add the declaration. (John Marriott) +Files: src/gui_w48.c + + +*** ../vim-7.3.407/src/gui_w48.c 2012-01-20 17:57:47.000000000 +0100 +--- src/gui_w48.c 2012-01-20 20:51:57.000000000 +0100 +*************** +*** 3286,3291 **** +--- 3286,3292 ---- + { + char_u *tmp; + int len; ++ WCHAR *res; + + tmp = convert_filter(s); + if (tmp == NULL) +*** ../vim-7.3.407/src/version.c 2012-01-20 20:44:38.000000000 +0100 +--- src/version.c 2012-01-20 20:52:56.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 408, + /**/ + +-- +BLACK KNIGHT: None shall pass. +ARTHUR: I have no quarrel with you, brave Sir knight, but I must cross + this bridge. +BLACK KNIGHT: Then you shall die. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f18e713d2ac36aa690a9631c5b1a7ed27a8dbad0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:32 +0100 Subject: [PATCH 0136/3340] - patchlevel 409 --- 7.3.409 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.409 diff --git a/7.3.409 b/7.3.409 new file mode 100644 index 00000000..a00fdcb8 --- /dev/null +++ b/7.3.409 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.409 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.409 +Problem: The license in pty.c is unclear. +Solution: Add a comment about the license. +Files: src/pty.c + + +*** ../vim-7.3.408/src/pty.c 2011-05-19 13:40:47.000000000 +0200 +--- src/pty.c 2012-01-20 21:07:56.000000000 +0100 +*************** +*** 14,19 **** +--- 14,23 ---- + * It has been modified to work better with Vim. + * The parts that are not used in Vim have been deleted. + * See the "screen" sources for the complete stuff. ++ * ++ * This specific version is distibuted under the Vim license (attribution by ++ * Juergen Weigert), the GPL applies to the original version, see the ++ * copyright notice below. + */ + + /* Copyright (c) 1993 +*** ../vim-7.3.408/src/version.c 2012-01-20 20:54:15.000000000 +0100 +--- src/version.c 2012-01-20 21:13:11.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 409, + /**/ + +-- +ARTHUR: What are you going to do. bleed on me? + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f4becbdc2ab757b4deaace74272628e21f923276 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:32 +0100 Subject: [PATCH 0137/3340] - patchlevel 410 --- 7.3.410 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 7.3.410 diff --git a/7.3.410 b/7.3.410 new file mode 100644 index 00000000..f40e06fa --- /dev/null +++ b/7.3.410 @@ -0,0 +1,54 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.410 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.410 +Problem: Compiler error for // comment. (Joachim Schmitz) +Solution: Turn into /* comment */. +Files: src/message.c + + +*** ../vim-7.3.409/src/message.c 2012-01-20 20:44:38.000000000 +0100 +--- src/message.c 2012-01-23 20:46:36.000000000 +0100 +*************** +*** 333,339 **** + } + else + { +! buf[e - 1] = NUL; // make sure it is truncated + } + } + +--- 333,339 ---- + } + else + { +! buf[e - 1] = NUL; /* make sure it is truncated */ + } + } + +*** ../vim-7.3.409/src/version.c 2012-01-20 21:13:55.000000000 +0100 +--- src/version.c 2012-01-23 20:47:30.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 410, + /**/ + + +-- +Are leaders born or made? And if they're made, can we return them under +warranty? + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ae2d84f1175e0b444bbd81b59539ceb23dd45a2a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:32 +0100 Subject: [PATCH 0138/3340] - patchlevel 411 --- 7.3.411 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.411 diff --git a/7.3.411 b/7.3.411 new file mode 100644 index 00000000..fe759952 --- /dev/null +++ b/7.3.411 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.411 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.411 +Problem: Pasting in Visual mode using the "" register does not work. (John + Beckett) +Solution: Detect that the write is overwriting the pasted register. + (Christian Brabandt) +Files: src/normal.c + + +*** ../vim-7.3.410/src/normal.c 2011-10-04 21:22:40.000000000 +0200 +--- src/normal.c 2012-01-23 22:13:44.000000000 +0100 +*************** +*** 9329,9335 **** + # ifdef FEAT_CLIPBOARD + adjust_clip_reg(®name); + # endif +! if (regname == 0 || VIM_ISDIGIT(regname) + # ifdef FEAT_CLIPBOARD + || (clip_unnamed && (regname == '*' || regname == '+')) + # endif +--- 9329,9335 ---- + # ifdef FEAT_CLIPBOARD + adjust_clip_reg(®name); + # endif +! if (regname == 0 || regname == '"' || VIM_ISDIGIT(regname) + # ifdef FEAT_CLIPBOARD + || (clip_unnamed && (regname == '*' || regname == '+')) + # endif +*** ../vim-7.3.410/src/version.c 2012-01-23 20:48:34.000000000 +0100 +--- src/version.c 2012-01-26 11:42:33.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 411, + /**/ + +-- +Engineers understand that their appearance only bothers other people and +therefore it is not worth optimizing. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 250b7e39dad42d083c52b039b0ac223d669dd086 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:33 +0100 Subject: [PATCH 0139/3340] - patchlevel 412 --- 7.3.412 | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 7.3.412 diff --git a/7.3.412 b/7.3.412 new file mode 100644 index 00000000..3b181883 --- /dev/null +++ b/7.3.412 @@ -0,0 +1,51 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.412 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.412 +Problem: Storing a float in a session file has an additional '&'. +Solution: Remove the '&'. (Yasuhiro Matsumoto) +Files: src/eval.c + + +*** ../vim-7.3.411/src/eval.c 2012-01-20 20:44:38.000000000 +0100 +--- src/eval.c 2012-01-26 11:39:39.000000000 +0100 +*************** +*** 22929,22935 **** + f = -f; + sign = '-'; + } +! if ((fprintf(fd, "let %s = %c&%f", + this_var->di_key, sign, f) < 0) + || put_eol(fd) == FAIL) + return FAIL; +--- 22929,22935 ---- + f = -f; + sign = '-'; + } +! if ((fprintf(fd, "let %s = %c%f", + this_var->di_key, sign, f) < 0) + || put_eol(fd) == FAIL) + return FAIL; +*** ../vim-7.3.411/src/version.c 2012-01-26 11:43:04.000000000 +0100 +--- src/version.c 2012-01-26 11:44:56.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 412, + /**/ + +-- +Imagine a world without hypothetical situations. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b23a4e59e925c1a3706bb6933296758dc2ff13fb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:33 +0100 Subject: [PATCH 0140/3340] - patchlevel 413 --- 7.3.413 | 90 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) create mode 100644 7.3.413 diff --git a/7.3.413 b/7.3.413 new file mode 100644 index 00000000..c32c9b1d --- /dev/null +++ b/7.3.413 @@ -0,0 +1,90 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.413 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.413 +Problem: Build warnings on MS-Windows. +Solution: Add type casts. (Mike Williams) +Files: src/ex_getln.c, src/message.c, src/term.c + + +*** ../vim-7.3.412/src/ex_getln.c 2012-01-20 20:44:38.000000000 +0100 +--- src/ex_getln.c 2012-01-26 12:58:54.000000000 +0100 +*************** +*** 5923,5929 **** + hist[i].hisnum); + if (vim_strsize(hist[i].hisstr) > (int)Columns - 10) + trunc_string(hist[i].hisstr, IObuff + STRLEN(IObuff), +! (int)Columns - 10, IOSIZE - STRLEN(IObuff)); + else + STRCAT(IObuff, hist[i].hisstr); + msg_outtrans(IObuff); +--- 5923,5929 ---- + hist[i].hisnum); + if (vim_strsize(hist[i].hisstr) > (int)Columns - 10) + trunc_string(hist[i].hisstr, IObuff + STRLEN(IObuff), +! (int)Columns - 10, IOSIZE - (int)STRLEN(IObuff)); + else + STRCAT(IObuff, hist[i].hisstr); + msg_outtrans(IObuff); +*** ../vim-7.3.412/src/message.c 2012-01-23 20:48:34.000000000 +0100 +--- src/message.c 2012-01-26 12:58:54.000000000 +0100 +*************** +*** 325,331 **** + if (e + 3 < buflen) + { + mch_memmove(buf + e, "...", (size_t)3); +! len = STRLEN(s + i) + 1; + if (len >= buflen - e - 3) + len = buflen - e - 3 - 1; + mch_memmove(buf + e + 3, s + i, len); +--- 325,331 ---- + if (e + 3 < buflen) + { + mch_memmove(buf + e, "...", (size_t)3); +! len = (int)STRLEN(s + i) + 1; + if (len >= buflen - e - 3) + len = buflen - e - 3 - 1; + mch_memmove(buf + e + 3, s + i, len); +*** ../vim-7.3.412/src/term.c 2012-01-20 17:15:47.000000000 +0100 +--- src/term.c 2012-01-26 12:58:54.000000000 +0100 +*************** +*** 5252,5258 **** + char_u *src; + { + int i; +! int slen = STRLEN(src); + + for (i = 0; i < tc_len; ++i) + { +--- 5252,5258 ---- + char_u *src; + { + int i; +! int slen = (int)STRLEN(src); + + for (i = 0; i < tc_len; ++i) + { +*** ../vim-7.3.412/src/version.c 2012-01-26 11:45:25.000000000 +0100 +--- src/version.c 2012-01-26 12:59:14.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 413, + /**/ + +-- +It doesn't really matter what you are able to do if you don't do it. + (Bram Moolenaar) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e057ec62659688123d224cb9eac3945ded430ac5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:34 +0100 Subject: [PATCH 0141/3340] - patchlevel 414 --- 7.3.414 | 90 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) create mode 100644 7.3.414 diff --git a/7.3.414 b/7.3.414 new file mode 100644 index 00000000..6f6c3075 --- /dev/null +++ b/7.3.414 @@ -0,0 +1,90 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.414 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.414 +Problem: Using CTRL-A on "000" drops the leading zero, while on "001" it + doesn't. +Solution: Detect "000" as an octal number. (James McCoy) +Files: src/charset.c + + +*** ../vim-7.3.413/src/charset.c 2012-01-10 22:26:12.000000000 +0100 +--- src/charset.c 2012-01-26 13:33:45.000000000 +0100 +*************** +*** 764,770 **** + } + + /* +! * Return the number of characters string "s" will take on the screen, + * counting TABs as two characters: "^I". + */ + int +--- 764,770 ---- + } + + /* +! * Return the number of character cells string "s" will take on the screen, + * counting TABs as two characters: "^I". + */ + int +*************** +*** 775,782 **** + } + + /* +! * Return the number of characters string "s[len]" will take on the screen, +! * counting TABs as two characters: "^I". + */ + int + vim_strnsize(s, len) +--- 775,782 ---- + } + + /* +! * Return the number of character cells string "s[len]" will take on the +! * screen, counting TABs as two characters: "^I". + */ + int + vim_strnsize(s, len) +*************** +*** 1830,1836 **** + hex = 0; /* can't be octal */ + break; + } +! if (ptr[n] > '0') + hex = '0'; /* assume octal */ + } + } +--- 1830,1836 ---- + hex = 0; /* can't be octal */ + break; + } +! if (ptr[n] >= '0') + hex = '0'; /* assume octal */ + } + } +*** ../vim-7.3.413/src/version.c 2012-01-26 13:01:54.000000000 +0100 +--- src/version.c 2012-01-26 13:38:04.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 414, + /**/ + +-- +No engineer can take a shower without wondering if some sort of Teflon coating +would make showering unnecessary. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 81043d7a785596900e798ccb0e6dc8c6cab433a2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:34 +0100 Subject: [PATCH 0142/3340] - patchlevel 415 --- 7.3.415 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 7.3.415 diff --git a/7.3.415 b/7.3.415 new file mode 100644 index 00000000..74e757b2 --- /dev/null +++ b/7.3.415 @@ -0,0 +1,54 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.415 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.415 (after 7.3.359) +Problem: Completion of functions stops once a dictionary is encountered. + (James McCoy) +Solution: Return an empty string instead of NULL. +Files: src/eval.c + + +*** ../vim-7.3.414/src/eval.c 2012-01-26 11:45:25.000000000 +0100 +--- src/eval.c 2012-01-26 13:45:52.000000000 +0100 +*************** +*** 21802,21808 **** + fp = HI2UF(hi); + + if (fp->uf_flags & FC_DICT) +! return NULL; /* don't show dict functions */ + + if (STRLEN(fp->uf_name) + 4 >= IOSIZE) + return fp->uf_name; /* prevents overflow */ +--- 21802,21808 ---- + fp = HI2UF(hi); + + if (fp->uf_flags & FC_DICT) +! return ""; /* don't show dict functions */ + + if (STRLEN(fp->uf_name) + 4 >= IOSIZE) + return fp->uf_name; /* prevents overflow */ +*** ../vim-7.3.414/src/version.c 2012-01-26 13:40:04.000000000 +0100 +--- src/version.c 2012-01-26 14:32:16.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 415, + /**/ + +-- +Normal people believe that if it ain't broke, don't fix it. Engineers believe +that if it ain't broke, it doesn't have enough features yet. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1de616e37aa0d512654bfe0d6c9730e9be63f4e5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:35 +0100 Subject: [PATCH 0143/3340] - patchlevel 416 --- 7.3.416 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 7.3.416 diff --git a/7.3.416 b/7.3.416 new file mode 100644 index 00000000..f65bb0d2 --- /dev/null +++ b/7.3.416 @@ -0,0 +1,54 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.416 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.416 (after 7.3.415) +Problem: Compiler warning for wrong pointer. +Solution: Add type cast. +Files: src/eval.c + + +*** ../vim-7.3.415/src/eval.c 2012-01-26 14:32:26.000000000 +0100 +--- src/eval.c 2012-01-26 15:42:56.000000000 +0100 +*************** +*** 21802,21808 **** + fp = HI2UF(hi); + + if (fp->uf_flags & FC_DICT) +! return ""; /* don't show dict functions */ + + if (STRLEN(fp->uf_name) + 4 >= IOSIZE) + return fp->uf_name; /* prevents overflow */ +--- 21802,21808 ---- + fp = HI2UF(hi); + + if (fp->uf_flags & FC_DICT) +! return (char_u *)""; /* don't show dict functions */ + + if (STRLEN(fp->uf_name) + 4 >= IOSIZE) + return fp->uf_name; /* prevents overflow */ +*** ../vim-7.3.415/src/version.c 2012-01-26 14:32:26.000000000 +0100 +--- src/version.c 2012-01-26 15:43:31.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 416, + /**/ + +-- +It's totally unfair to suggest - as many have - that engineers are socially +inept. Engineers simply have different objectives when it comes to social +interaction. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From eb27f2cf53ea95e967c2529cc0b6c67786c40e14 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:35 +0100 Subject: [PATCH 0144/3340] - patchlevel 417 --- 7.3.417 | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 7.3.417 diff --git a/7.3.417 b/7.3.417 new file mode 100644 index 00000000..489d27eb --- /dev/null +++ b/7.3.417 @@ -0,0 +1,47 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.417 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.417 (after 7.3.395) +Problem: Test 43 fails with a tiny build. +Solution: Only run test 43 with at least a small build. +Files: src/testdir/test43.in + + +*** ../vim-7.3.415/src/testdir/test43.in 2012-01-10 13:44:23.000000000 +0100 +--- src/testdir/test43.in 2012-01-26 18:00:06.000000000 +0100 +*************** +*** 1,6 **** +--- 1,7 ---- + Tests for regexp with various magic settings. + + STARTTEST ++ :so small.vim + :set nocompatible viminfo+=nviminfo + /^1 + /a*b\{2}c\+/e +*** ../vim-7.3.415/src/version.c 2012-01-26 14:32:26.000000000 +0100 +--- src/version.c 2012-01-26 18:02:30.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 417, + /**/ + +-- +I learned the customs and mannerisms of engineers by observing them, much the +way Jane Goodall learned about the great apes, but without the hassle of +grooming. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 50e9a51d6605d9c86789a7d3eacdcd69d5fcb70c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:35 +0100 Subject: [PATCH 0145/3340] - patchlevel 418 --- 7.3.418 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.418 diff --git a/7.3.418 b/7.3.418 new file mode 100644 index 00000000..6ff486b6 --- /dev/null +++ b/7.3.418 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.418 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.418 +Problem: When a user complete function returns -1 an error message is + given. +Solution: When -2 is returned stop completion silently. (Yasuhiro Matsumoto) +Files: src/edit.c + + +*** ../vim-7.3.417/src/edit.c 2012-01-20 14:32:22.000000000 +0100 +--- src/edit.c 2012-01-26 18:32:23.000000000 +0100 +*************** +*** 5189,5194 **** +--- 5189,5199 ---- + return FAIL; + } + ++ /* Return value -2 means the user complete function wants to ++ * cancel the complete without an error. */ ++ if (col == -2) ++ return FAIL; ++ + /* + * Reset extended parameters of completion, when start new + * completion. +*** ../vim-7.3.417/src/version.c 2012-01-26 18:58:13.000000000 +0100 +--- src/version.c 2012-01-26 18:42:14.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 418, + /**/ + +-- +If someone questions your market projections, simply point out that your +target market is "People who are nuts" and "People who will buy any damn +thing". Nobody is going to tell you there aren't enough of those people +to go around. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 32f7831d57e38a38a45c9b801ce23b6a9773d054 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:36 +0100 Subject: [PATCH 0146/3340] - patchlevel 419 --- 7.3.419 | 85 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100644 7.3.419 diff --git a/7.3.419 b/7.3.419 new file mode 100644 index 00000000..865a47c7 --- /dev/null +++ b/7.3.419 @@ -0,0 +1,85 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.419 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.419 +Problem: DBCS encoding in a user command does not always work. +Solution: Skip over DBCS characters. (Yasuhiro Matsumoto) +Files: src/ex_docmd.c + + +*** ../vim-7.3.418/src/ex_docmd.c 2011-12-14 14:49:41.000000000 +0100 +--- src/ex_docmd.c 2012-01-26 20:04:01.000000000 +0100 +*************** +*** 5967,5973 **** + result = STRLEN(eap->arg) + 2; + for (p = eap->arg; *p; ++p) + { +! if (*p == '\\' || *p == '"') + ++result; + } + +--- 5967,5980 ---- + result = STRLEN(eap->arg) + 2; + for (p = eap->arg; *p; ++p) + { +! #ifdef FEAT_MBYTE +! if (enc_dbcs != 0 && (*mb_ptr2len)(p) == 2) +! /* DBCS can contain \ in a trail byte, skip the +! * double-byte character. */ +! ++p; +! else +! #endif +! if (*p == '\\' || *p == '"') + ++result; + } + +*************** +*** 5976,5982 **** + *buf++ = '"'; + for (p = eap->arg; *p; ++p) + { +! if (*p == '\\' || *p == '"') + *buf++ = '\\'; + *buf++ = *p; + } +--- 5983,5996 ---- + *buf++ = '"'; + for (p = eap->arg; *p; ++p) + { +! #ifdef FEAT_MBYTE +! if (enc_dbcs != 0 && (*mb_ptr2len)(p) == 2) +! /* DBCS can contain \ in a trail byte, copy the +! * double-byte character to avoid escaping. */ +! *buf++ = *p++; +! else +! #endif +! if (*p == '\\' || *p == '"') + *buf++ = '\\'; + *buf++ = *p; + } +*** ../vim-7.3.418/src/version.c 2012-01-26 18:58:25.000000000 +0100 +--- src/version.c 2012-01-26 20:40:34.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 419, + /**/ + +-- +You have heard the saying that if you put a thousand monkeys in a room with a +thousand typewriters and waited long enough, eventually you would have a room +full of dead monkeys. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8ccb2278878168c5ef4d6191ddd1dcff70961fbc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:36 +0100 Subject: [PATCH 0147/3340] - patchlevel 420 --- 7.3.420 | 70 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 7.3.420 diff --git a/7.3.420 b/7.3.420 new file mode 100644 index 00000000..d698d0b4 --- /dev/null +++ b/7.3.420 @@ -0,0 +1,70 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.420 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.420 +Problem: "it" and "at" don't work properly with a dash in the tag name. +Solution: Require a space to match the tag name. (Christian Brabandt) +Files: src/search.c + + +*** ../vim-7.3.419/src/search.c 2012-01-10 22:26:12.000000000 +0100 +--- src/search.c 2012-01-26 20:51:43.000000000 +0100 +*************** +*** 3918,3924 **** + curwin->w_cursor = old_pos; + goto theend; + } +! spat = alloc(len + 29); + epat = alloc(len + 9); + if (spat == NULL || epat == NULL) + { +--- 3918,3924 ---- + curwin->w_cursor = old_pos; + goto theend; + } +! spat = alloc(len + 31); + epat = alloc(len + 9); + if (spat == NULL || epat == NULL) + { +*************** +*** 3927,3933 **** + curwin->w_cursor = old_pos; + goto theend; + } +! sprintf((char *)spat, "<%.*s\\>\\%%(\\_[^>]\\{-}[^/]>\\|>\\)\\c", len, p); + sprintf((char *)epat, "\\c", len, p); + + r = do_searchpair(spat, (char_u *)"", epat, FORWARD, (char_u *)"", +--- 3927,3933 ---- + curwin->w_cursor = old_pos; + goto theend; + } +! sprintf((char *)spat, "<%.*s\\>\\%%(\\s\\_[^>]\\{-}[^/]>\\|>\\)\\c", len, p); + sprintf((char *)epat, "\\c", len, p); + + r = do_searchpair(spat, (char_u *)"", epat, FORWARD, (char_u *)"", +*** ../vim-7.3.419/src/version.c 2012-01-26 20:41:22.000000000 +0100 +--- src/version.c 2012-01-26 20:51:16.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 420, + /**/ + +-- +All good vision statements are created by groups of people with bloated +bladders who would rather be doing anything else. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c0c7a5e5bfb67a4cbbab442dbfcee3bfb237964b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:36 +0100 Subject: [PATCH 0148/3340] - patchlevel 421 --- 7.3.421 | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 7.3.421 diff --git a/7.3.421 b/7.3.421 new file mode 100644 index 00000000..eadc29df --- /dev/null +++ b/7.3.421 @@ -0,0 +1,60 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.421 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.421 +Problem: Get E832 when setting 'undofile' in vimrc and there is a file to + be edited on the command line. (Toothpik) +Solution: Do not try reading the undo file for a file that wasn't loaded. +Files: src/option.c + + +*** ../vim-7.3.420/src/option.c 2012-01-10 22:26:12.000000000 +0100 +--- src/option.c 2012-01-28 17:55:24.000000000 +0100 +*************** +*** 7527,7536 **** + { + /* When 'undofile' is set globally: for every buffer, otherwise + * only for the current buffer: Try to read in the undofile, if +! * one exists and the buffer wasn't changed. */ + if ((curbuf == save_curbuf + || (opt_flags & OPT_GLOBAL) || opt_flags == 0) +! && !curbufIsChanged()) + { + u_compute_hash(hash); + u_read_undo(NULL, hash, curbuf->b_fname); +--- 7527,7537 ---- + { + /* When 'undofile' is set globally: for every buffer, otherwise + * only for the current buffer: Try to read in the undofile, if +! * one exists and the buffer wasn't changed and the buffer was +! * loaded. */ + if ((curbuf == save_curbuf + || (opt_flags & OPT_GLOBAL) || opt_flags == 0) +! && !curbufIsChanged() && curbuf->b_ml.ml_mfp != NULL) + { + u_compute_hash(hash); + u_read_undo(NULL, hash, curbuf->b_fname); +*** ../vim-7.3.420/src/version.c 2012-01-26 20:58:21.000000000 +0100 +--- src/version.c 2012-01-28 18:03:09.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 421, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +4. Your eyeglasses have a web site burned in on them. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e49773d38134761b583029aa444c5ca0a4b563cc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:37 +0100 Subject: [PATCH 0149/3340] - patchlevel 422 --- 7.3.422 | 94 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 94 insertions(+) create mode 100644 7.3.422 diff --git a/7.3.422 b/7.3.422 new file mode 100644 index 00000000..7be4aebd --- /dev/null +++ b/7.3.422 @@ -0,0 +1,94 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.422 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.422 +Problem: Python 3 does not have __members__. +Solution: Add "name" and "number" in another way. (lilydjwg) +Files: src/if_py_both.h, src/if_python3.c + + +*** ../vim-7.3.421/src/if_py_both.h 2011-09-07 19:30:17.000000000 +0200 +--- src/if_py_both.h 2012-02-04 19:59:43.000000000 +0100 +*************** +*** 1479,1484 **** +--- 1479,1487 ---- + {"append", BufferAppend, 1, "Append data to Vim buffer" }, + {"mark", BufferMark, 1, "Return (row,col) representing position of named mark" }, + {"range", BufferRange, 1, "Return a range object which represents the part of the given buffer between line numbers s and e" }, ++ #if PY_VERSION_HEX >= 0x03000000 ++ {"__dir__", BufferDir, 4, "List its attributes" }, ++ #endif + { NULL, NULL, 0, NULL } + }; + +*** ../vim-7.3.421/src/if_python3.c 2011-09-14 18:59:35.000000000 +0200 +--- src/if_python3.c 2012-02-04 20:13:00.000000000 +0100 +*************** +*** 468,473 **** +--- 468,474 ---- + static PyObject *BufferNew (buf_T *); + static PyObject *WindowNew(win_T *); + static PyObject *LineToString(const char *); ++ static PyObject *BufferDir(PyObject *, PyObject *); + + static PyTypeObject RangeType; + +*************** +*** 961,973 **** + return Py_BuildValue("s", this->buf->b_ffname); + else if (strcmp(name, "number") == 0) + return Py_BuildValue("n", this->buf->b_fnum); +- else if (strcmp(name,"__members__") == 0) +- return Py_BuildValue("[ss]", "name", "number"); + else + return PyObject_GenericGetAttr(self, nameobj); + } + + static PyObject * + BufferRepr(PyObject *self) + { + static char repr[100]; +--- 962,979 ---- + return Py_BuildValue("s", this->buf->b_ffname); + else if (strcmp(name, "number") == 0) + return Py_BuildValue("n", this->buf->b_fnum); + else + return PyObject_GenericGetAttr(self, nameobj); + } + + static PyObject * ++ BufferDir(PyObject *self UNUSED, PyObject *args UNUSED) ++ { ++ return Py_BuildValue("[sssss]", "name", "number", ++ "append", "mark", "range"); ++ } ++ ++ static PyObject * + BufferRepr(PyObject *self) + { + static char repr[100]; +*** ../vim-7.3.421/src/version.c 2012-01-28 18:03:30.000000000 +0100 +--- src/version.c 2012-02-04 20:14:58.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 422, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +15. Five days in advance, tell your friends you can't attend their + party because you're not in the mood. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c37e05f0de9f3478566be3c7ce50263640105691 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:37 +0100 Subject: [PATCH 0150/3340] - patchlevel 423 --- 7.3.423 | 130 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 130 insertions(+) create mode 100644 7.3.423 diff --git a/7.3.423 b/7.3.423 new file mode 100644 index 00000000..74bf62d2 --- /dev/null +++ b/7.3.423 @@ -0,0 +1,130 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.423 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.423 +Problem: Small mistakes in comments, proto and indent. +Solution: Fix the mistakes. +Files: src/ex_cmds2.c, src/structs.h, src/ui.c, src/proto/ex_docmd.pro + + +*** ../vim-7.3.422/src/ex_cmds2.c 2011-10-20 21:38:37.000000000 +0200 +--- src/ex_cmds2.c 2011-11-30 11:02:20.000000000 +0100 +*************** +*** 1939,1945 **** + } + + /* +! * Return TRUE if window "win" is editing then file at the current argument + * index. + */ + static int +--- 1939,1945 ---- + } + + /* +! * Return TRUE if window "win" is editing the file at the current argument + * index. + */ + static int +*** ../vim-7.3.422/src/structs.h 2011-05-19 13:40:47.000000000 +0200 +--- src/structs.h 2011-09-10 13:48:53.000000000 +0200 +*************** +*** 1846,1852 **** + often, keep it the first item!) */ + + #if defined(FEAT_SYN_HL) || defined(FEAT_SPELL) +! synblock_T *w_s; + #endif + + #ifdef FEAT_WINDOWS +--- 1846,1852 ---- + often, keep it the first item!) */ + + #if defined(FEAT_SYN_HL) || defined(FEAT_SPELL) +! synblock_T *w_s; /* for :ownsyntax */ + #endif + + #ifdef FEAT_WINDOWS +*** ../vim-7.3.422/src/ui.c 2011-07-07 16:20:45.000000000 +0200 +--- src/ui.c 2012-01-21 14:03:42.000000000 +0100 +*************** +*** 2363,2376 **** + XtLastTimestampProcessed(XtDisplay(myShell)), + clip_x11_convert_selection_cb, clip_x11_lose_ownership_cb, + NULL) == False) +! return FAIL; + } + else + #endif + { + if (!XChangeProperty(XtDisplay(myShell), XtWindow(myShell), + cbd->sel_atom, timestamp_atom, 32, PropModeAppend, NULL, 0)) +! return FAIL; + } + /* Flush is required in a terminal as nothing else is doing it. */ + XFlush(XtDisplay(myShell)); +--- 2363,2376 ---- + XtLastTimestampProcessed(XtDisplay(myShell)), + clip_x11_convert_selection_cb, clip_x11_lose_ownership_cb, + NULL) == False) +! return FAIL; + } + else + #endif + { + if (!XChangeProperty(XtDisplay(myShell), XtWindow(myShell), + cbd->sel_atom, timestamp_atom, 32, PropModeAppend, NULL, 0)) +! return FAIL; + } + /* Flush is required in a terminal as nothing else is doing it. */ + XFlush(XtDisplay(myShell)); +*** ../vim-7.3.422/src/proto/ex_docmd.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/ex_docmd.pro 2011-01-16 00:22:21.000000000 +0100 +*************** +*** 1,7 **** + /* ex_docmd.c */ + void do_exmode __ARGS((int improved)); + int do_cmdline_cmd __ARGS((char_u *cmd)); +! int do_cmdline __ARGS((char_u *cmdline, char_u *(*getline)(int, void *, int), void *cookie, int flags)); + int getline_equal __ARGS((char_u *(*fgetline)(int, void *, int), void *cookie, char_u *(*func)(int, void *, int))); + void *getline_cookie __ARGS((char_u *(*fgetline)(int, void *, int), void *cookie)); + int checkforcmd __ARGS((char_u **pp, char *cmd, int len)); +--- 1,7 ---- + /* ex_docmd.c */ + void do_exmode __ARGS((int improved)); + int do_cmdline_cmd __ARGS((char_u *cmd)); +! int do_cmdline __ARGS((char_u *cmdline, char_u *(*fgetline)(int, void *, int), void *cookie, int flags)); + int getline_equal __ARGS((char_u *(*fgetline)(int, void *, int), void *cookie, char_u *(*func)(int, void *, int))); + void *getline_cookie __ARGS((char_u *(*fgetline)(int, void *, int), void *cookie)); + int checkforcmd __ARGS((char_u **pp, char *cmd, int len)); +*** ../vim-7.3.422/src/version.c 2012-02-04 20:17:21.000000000 +0100 +--- src/version.c 2012-02-04 21:56:43.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 423, + /**/ + +-- +In many of the more relaxed civilizations on the Outer Eastern Rim of the +Galaxy, "The Hitchhiker's Guide to the Galaxy" has already supplanted the +great "Encyclopedia Galactica" as the standard repository of all knowledge +and wisdom, for though it has many omissions and contains much that is +apocryphal, or at least wildly inaccurate, it scores over the older, more +pedestrian work in two important respects. +First, it is slightly cheaper; and second, it has the words "DON'T PANIC" +inscribed in large friendly letters on its cover. + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ec63556aded873ebb0b051887ce480c947a3622b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:37 +0100 Subject: [PATCH 0151/3340] - patchlevel 424 --- 7.3.424 | 62 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 7.3.424 diff --git a/7.3.424 b/7.3.424 new file mode 100644 index 00000000..61786ed8 --- /dev/null +++ b/7.3.424 @@ -0,0 +1,62 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.424 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.424 +Problem: Win16 version missing some functions. +Solution: Add #defines for the functions. +Files: src/gui_w16.c + + +*** ../vim-7.3.423/src/gui_w16.c 2011-01-17 20:08:03.000000000 +0100 +--- src/gui_w16.c 2011-08-10 16:50:21.000000000 +0200 +*************** +*** 21,26 **** +--- 21,32 ---- + * + */ + ++ /* Win16 doesn't use the "W" methods. */ ++ #define pDispatchMessage DispatchMessage ++ #define pGetMessage GetMessage ++ #define pIsDialogMessage IsDialogMessage ++ #define pPeekMessage PeekMessage ++ + /* + * Include the common stuff for MS-Windows GUI. + */ +*** ../vim-7.3.423/src/version.c 2012-02-04 21:57:44.000000000 +0100 +--- src/version.c 2012-02-04 22:01:13.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 424, + /**/ + +-- +Now it is such a bizarrely improbable coincidence that anything as +mind-bogglingly useful as the Babel fish could have evolved purely by chance +that some thinkers have chosen to see it as a final and clinching proof of the +NON-existence of God. +The argument goes something like this: 'I refuse to prove that I exist,' says +God, 'for proof denies faith, and without faith I am nothing.' +'But,' says Man, 'the Babel fish is a dead giveaway, isn't it? It could not +have evolved by chance. It proves you exist, and so therefore, by your own +arguments, you don't. QED.' +'Oh dear,' says God, 'I hadn't thought of that,' and promptly vanishes in a +puff of logic. +'Oh, that was easy,' says Man, and for an encore goes on to prove that black +is white and gets himself killed on the next pedestrian crossing. + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e6bc0dcac95ab85f6fd9780e2fe1190bf8f03d27 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:38 +0100 Subject: [PATCH 0152/3340] - patchlevel 425 --- 7.3.425 | 78 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) create mode 100644 7.3.425 diff --git a/7.3.425 b/7.3.425 new file mode 100644 index 00000000..aeadf3a3 --- /dev/null +++ b/7.3.425 @@ -0,0 +1,78 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.425 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.425 (after 7.3.265) +Problem: Search history lines are duplicated. (Edwin Steiner) +Solution: Convert separator character from space to NUL. +Files: src/ex_getln.c + + +*** ../vim-7.3.424/src/ex_getln.c 2012-01-26 13:01:54.000000000 +0100 +--- src/ex_getln.c 2012-02-04 22:27:43.000000000 +0100 +*************** +*** 6027,6034 **** + val = viminfo_readstring(virp, 1, TRUE); + if (val != NULL && *val != NUL) + { + if (!in_history(type, val + (type == HIST_SEARCH), +! viminfo_add_at_front, *val)) + { + /* Need to re-allocate to append the separator byte. */ + len = STRLEN(val); +--- 6027,6036 ---- + val = viminfo_readstring(virp, 1, TRUE); + if (val != NULL && *val != NUL) + { ++ int sep = (*val == ' ' ? NUL : *val); ++ + if (!in_history(type, val + (type == HIST_SEARCH), +! viminfo_add_at_front, sep)) + { + /* Need to re-allocate to append the separator byte. */ + len = STRLEN(val); +*************** +*** 6040,6046 **** + /* Search entry: Move the separator from the first + * column to after the NUL. */ + mch_memmove(p, val + 1, (size_t)len); +! p[len] = (*val == ' ' ? NUL : *val); + } + else + { +--- 6042,6048 ---- + /* Search entry: Move the separator from the first + * column to after the NUL. */ + mch_memmove(p, val + 1, (size_t)len); +! p[len] = sep; + } + else + { +*** ../vim-7.3.424/src/version.c 2012-02-04 22:01:44.000000000 +0100 +--- src/version.c 2012-02-04 22:30:36.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 425, + /**/ + +-- +"So this is it," said Arthur, "we are going to die." +"Yes," said Ford, "except...no! Wait a minute!" He suddenly lunged across +the chamber at something behind Arthur's line of vision. "What's this +switch?" he cried. +"What? Where?" cried Arthur, twisting around. +"No, I was only fooling," said Ford, "we are going to die after all." + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 227f6b4b4beeed96f71854d465c9bbda2301ce44 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:38 +0100 Subject: [PATCH 0153/3340] - patchlevel 426 --- 7.3.426 | 279 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 279 insertions(+) create mode 100644 7.3.426 diff --git a/7.3.426 b/7.3.426 new file mode 100644 index 00000000..76380af1 --- /dev/null +++ b/7.3.426 @@ -0,0 +1,279 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.426 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.426 +Problem: With '$' in 'cpoptions' the $ is not displayed in the first + column. +Solution: Use -1 instead of 0 as a special value. (Hideki Eiraku and + Hirohito Higashi) +Files: src/edit.c, src/globals.h, src/move.c, src/screen.c, src/search.c + + +*** ../vim-7.3.425/src/edit.c 2012-01-26 18:58:25.000000000 +0100 +--- src/edit.c 2012-02-04 23:23:45.000000000 +0100 +*************** +*** 1763,1771 **** + static void + undisplay_dollar() + { +! if (dollar_vcol) + { +! dollar_vcol = 0; + redrawWinline(curwin->w_cursor.lnum, FALSE); + } + } +--- 1763,1771 ---- + static void + undisplay_dollar() + { +! if (dollar_vcol >= 0) + { +! dollar_vcol = -1; + redrawWinline(curwin->w_cursor.lnum, FALSE); + } + } +*************** +*** 5441,5447 **** + compl_curr_match->cp_number); + edit_submode_extra = match_ref; + edit_submode_highl = HLF_R; +! if (dollar_vcol) + curs_columns(FALSE); + } + } +--- 5441,5447 ---- + compl_curr_match->cp_number); + edit_submode_extra = match_ref; + edit_submode_highl = HLF_R; +! if (dollar_vcol >= 0) + curs_columns(FALSE); + } + } +*************** +*** 8961,8967 **** + * We can emulate the vi behaviour by pretending there is a dollar + * displayed even when there isn't. + * --pkv Sun Jan 19 01:56:40 EST 2003 */ +! if (vim_strchr(p_cpo, CPO_BACKSPACE) != NULL && dollar_vcol == 0) + dollar_vcol = curwin->w_virtcol; + + #ifdef FEAT_FOLDING +--- 8961,8967 ---- + * We can emulate the vi behaviour by pretending there is a dollar + * displayed even when there isn't. + * --pkv Sun Jan 19 01:56:40 EST 2003 */ +! if (vim_strchr(p_cpo, CPO_BACKSPACE) != NULL && dollar_vcol == -1) + dollar_vcol = curwin->w_virtcol; + + #ifdef FEAT_FOLDING +*** ../vim-7.3.425/src/globals.h 2011-05-10 16:41:13.000000000 +0200 +--- src/globals.h 2012-02-04 23:24:07.000000000 +0100 +*************** +*** 113,121 **** + * When '$' is included in 'cpoptions' option set: + * When a change command is given that deletes only part of a line, a dollar + * is put at the end of the changed text. dollar_vcol is set to the virtual +! * column of this '$'. + */ +! EXTERN colnr_T dollar_vcol INIT(= 0); + + #ifdef FEAT_INS_EXPAND + /* +--- 113,121 ---- + * When '$' is included in 'cpoptions' option set: + * When a change command is given that deletes only part of a line, a dollar + * is put at the end of the changed text. dollar_vcol is set to the virtual +! * column of this '$'. -1 is used to indicate no $ is being displayed. + */ +! EXTERN colnr_T dollar_vcol INIT(= -1); + + #ifdef FEAT_INS_EXPAND + /* +*** ../vim-7.3.425/src/move.c 2012-01-10 22:26:12.000000000 +0100 +--- src/move.c 2012-02-04 23:21:08.000000000 +0100 +*************** +*** 362,368 **** + #endif + ) + { +! dollar_vcol = 0; + if (curwin->w_skipcol != 0) + { + curwin->w_skipcol = 0; +--- 362,368 ---- + #endif + ) + { +! dollar_vcol = -1; + if (curwin->w_skipcol != 0) + { + curwin->w_skipcol = 0; +*************** +*** 966,972 **** + + /* remove '$' from change command when cursor moves onto it */ + if (startcol > dollar_vcol) +! dollar_vcol = 0; + + extra = curwin_col_off(); + curwin->w_wcol = curwin->w_virtcol + extra; +--- 966,972 ---- + + /* remove '$' from change command when cursor moves onto it */ + if (startcol > dollar_vcol) +! dollar_vcol = -1; + + extra = curwin_col_off(); + curwin->w_wcol = curwin->w_virtcol + extra; +*** ../vim-7.3.425/src/screen.c 2012-01-10 22:26:12.000000000 +0100 +--- src/screen.c 2012-02-04 23:22:44.000000000 +0100 +*************** +*** 1637,1647 **** + * When at start of changed lines: May scroll following lines + * up or down to minimize redrawing. + * Don't do this when the change continues until the end. +! * Don't scroll when dollar_vcol is non-zero, keep the "$". + */ + if (lnum == mod_top + && mod_bot != MAXLNUM +! && !(dollar_vcol != 0 && mod_bot == mod_top + 1)) + { + int old_rows = 0; + int new_rows = 0; +--- 1637,1647 ---- + * When at start of changed lines: May scroll following lines + * up or down to minimize redrawing. + * Don't do this when the change continues until the end. +! * Don't scroll when dollar_vcol >= 0, keep the "$". + */ + if (lnum == mod_top + && mod_bot != MAXLNUM +! && !(dollar_vcol >= 0 && mod_bot == mod_top + 1)) + { + int old_rows = 0; + int new_rows = 0; +*************** +*** 1868,1879 **** + if (row > wp->w_height) /* past end of screen */ + { + /* we may need the size of that too long line later on */ +! if (dollar_vcol == 0) + wp->w_lines[idx].wl_size = plines_win(wp, lnum, TRUE); + ++idx; + break; + } +! if (dollar_vcol == 0) + wp->w_lines[idx].wl_size = row - srow; + ++idx; + #ifdef FEAT_FOLDING +--- 1868,1879 ---- + if (row > wp->w_height) /* past end of screen */ + { + /* we may need the size of that too long line later on */ +! if (dollar_vcol == -1) + wp->w_lines[idx].wl_size = plines_win(wp, lnum, TRUE); + ++idx; + break; + } +! if (dollar_vcol == -1) + wp->w_lines[idx].wl_size = row - srow; + ++idx; + #ifdef FEAT_FOLDING +*************** +*** 1990,1996 **** + } + #endif + } +! else if (dollar_vcol == 0) + wp->w_botline = lnum; + + /* make sure the rest of the screen is blank */ +--- 1990,1996 ---- + } + #endif + } +! else if (dollar_vcol == -1) + wp->w_botline = lnum; + + /* make sure the rest of the screen is blank */ +*************** +*** 2005,2011 **** + wp->w_old_botfill = wp->w_botfill; + #endif + +! if (dollar_vcol == 0) + { + /* + * There is a trick with w_botline. If we invalidate it on each +--- 2005,2011 ---- + wp->w_old_botfill = wp->w_botfill; + #endif + +! if (dollar_vcol == -1) + { + /* + * There is a trick with w_botline. If we invalidate it on each +*************** +*** 3564,3570 **** + } + + /* When still displaying '$' of change command, stop at cursor */ +! if (dollar_vcol != 0 && wp == curwin + && lnum == wp->w_cursor.lnum && vcol >= (long)wp->w_virtcol + #ifdef FEAT_DIFF + && filler_todo <= 0 +--- 3564,3570 ---- + } + + /* When still displaying '$' of change command, stop at cursor */ +! if (dollar_vcol >= 0 && wp == curwin + && lnum == wp->w_cursor.lnum && vcol >= (long)wp->w_virtcol + #ifdef FEAT_DIFF + && filler_todo <= 0 +*** ../vim-7.3.425/src/search.c 2012-01-26 20:58:21.000000000 +0100 +--- src/search.c 2012-02-04 23:23:10.000000000 +0100 +*************** +*** 2501,2508 **** + save_siso = p_siso; + /* Handle "$" in 'cpo': If the ')' is typed on top of the "$", + * stop displaying the "$". */ +! if (dollar_vcol > 0 && dollar_vcol == curwin->w_virtcol) +! dollar_vcol = 0; + ++curwin->w_virtcol; /* do display ')' just before "$" */ + update_screen(VALID); /* show the new char first */ + +--- 2501,2508 ---- + save_siso = p_siso; + /* Handle "$" in 'cpo': If the ')' is typed on top of the "$", + * stop displaying the "$". */ +! if (dollar_vcol >= 0 && dollar_vcol == curwin->w_virtcol) +! dollar_vcol = -1; + ++curwin->w_virtcol; /* do display ')' just before "$" */ + update_screen(VALID); /* show the new char first */ + +*** ../vim-7.3.425/src/version.c 2012-02-04 22:44:27.000000000 +0100 +--- src/version.c 2012-02-04 23:32:55.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 426, + /**/ + + +-- +I am also told that there is a logical proof out there somewhere +that demonstrates that there is no task which duct tape cannot handle. + -- Paul Brannan + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 552d0de7f1ee87ef1484565b597a16484f15d199 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:39 +0100 Subject: [PATCH 0154/3340] - patchlevel 427 --- 7.3.427 | 395 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 395 insertions(+) create mode 100644 7.3.427 diff --git a/7.3.427 b/7.3.427 new file mode 100644 index 00000000..cc77ac3c --- /dev/null +++ b/7.3.427 @@ -0,0 +1,395 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.427 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.427 +Problem: readfile() can be slow with long lines. +Solution: Use realloc() instead of alloc(). (John Little) +Files: src/eval.c + + +*** ../vim-7.3.426/src/eval.c 2012-01-26 14:32:26.000000000 +0100 +--- src/eval.c 2012-02-05 00:25:39.000000000 +0100 +*************** +*** 14325,14346 **** + typval_T *rettv; + { + int binary = FALSE; + char_u *fname; + FILE *fd; +! listitem_T *li; +! #define FREAD_SIZE 200 /* optimized for text lines */ +! char_u buf[FREAD_SIZE]; +! int readlen; /* size of last fread() */ +! int buflen; /* nr of valid chars in buf[] */ +! int filtd; /* how much in buf[] was NUL -> '\n' filtered */ +! int tolist; /* first byte in buf[] still to be put in list */ +! int chop; /* how many CR to chop off */ +! char_u *prev = NULL; /* previously read bytes, if any */ +! int prevlen = 0; /* length of "prev" if not NULL */ +! char_u *s; +! int len; +! long maxline = MAXLNUM; +! long cnt = 0; + + if (argvars[1].v_type != VAR_UNKNOWN) + { +--- 14325,14343 ---- + typval_T *rettv; + { + int binary = FALSE; ++ int failed = FALSE; + char_u *fname; + FILE *fd; +! char_u buf[(IOSIZE/256)*256]; /* rounded to avoid odd + 1 */ +! int io_size = sizeof(buf); +! int readlen; /* size of last fread() */ +! char_u *prev = NULL; /* previously read bytes, if any */ +! long prevlen = 0; /* length of data in prev */ +! long prevsize = 0; /* size of prev buffer */ +! long maxline = MAXLNUM; +! long cnt = 0; +! char_u *p; /* position in buf */ +! char_u *start; /* start of current line */ + + if (argvars[1].v_type != VAR_UNKNOWN) + { +*************** +*** 14362,14410 **** + return; + } + +- filtd = 0; + while (cnt < maxline || maxline < 0) + { +! readlen = (int)fread(buf + filtd, 1, FREAD_SIZE - filtd, fd); +! buflen = filtd + readlen; +! tolist = 0; +! for ( ; filtd < buflen || readlen <= 0; ++filtd) +! { +! if (readlen <= 0 || buf[filtd] == '\n') +! { +! /* In binary mode add an empty list item when the last +! * non-empty line ends in a '\n'. */ +! if (!binary && readlen == 0 && filtd == 0 && prev == NULL) +! break; + +! /* Found end-of-line or end-of-file: add a text line to the +! * list. */ +! chop = 0; +! if (!binary) +! while (filtd - chop - 1 >= tolist +! && buf[filtd - chop - 1] == '\r') +! ++chop; +! len = filtd - tolist - chop; +! if (prev == NULL) +! s = vim_strnsave(buf + tolist, len); + else + { +! s = alloc((unsigned)(prevlen + len + 1)); +! if (s != NULL) + { +! mch_memmove(s, prev, prevlen); +! vim_free(prev); +! prev = NULL; +! mch_memmove(s + prevlen, buf + tolist, len); + s[prevlen + len] = NUL; + } + } +! tolist = filtd + 1; + +! li = listitem_alloc(); +! if (li == NULL) + { + vim_free(s); + break; + } + li->li_tv.v_type = VAR_STRING; +--- 14359,14419 ---- + return; + } + + while (cnt < maxline || maxline < 0) + { +! readlen = (int)fread(buf, 1, io_size, fd); +! +! /* This for loop processes what was read, but is also entered at end +! * of file so that either: +! * - an incomplete line gets written +! * - a "binary" file gets an empty line at the end if it ends in a +! * newline. */ +! for (p = buf, start = buf; +! p < buf + readlen || (readlen <= 0 && (prevlen > 0 || binary)); +! ++p) +! { +! if (*p == '\n' || readlen <= 0) +! { +! listitem_T *li; +! char_u *s = NULL; +! long_u len = p - start; + +! /* Finished a line. Remove CRs before NL. */ +! if (readlen > 0 && !binary) +! { +! while (len > 0 && start[len - 1] == '\r') +! --len; +! /* removal may cross back to the "prev" string */ +! if (len == 0) +! while (prevlen > 0 && prev[prevlen - 1] == '\r') +! --prevlen; +! } +! if (prevlen == 0) +! s = vim_strnsave(start, len); + else + { +! /* Change "prev" buffer to be the right size. This way +! * the bytes are only copied once, and very long lines are +! * allocated only once. */ +! if ((s = vim_realloc(prev, prevlen + len + 1)) != NULL) + { +! mch_memmove(s + prevlen, start, len); + s[prevlen + len] = NUL; ++ prev = NULL; /* the list will own the string */ ++ prevlen = prevsize = 0; + } + } +! if (s == NULL) +! { +! do_outofmem_msg((long_u) prevlen + len + 1); +! failed = TRUE; +! break; +! } + +! if ((li = listitem_alloc()) == NULL) + { + vim_free(s); ++ failed = TRUE; + break; + } + li->li_tv.v_type = VAR_STRING; +*************** +*** 14412,14485 **** + li->li_tv.vval.v_string = s; + list_append(rettv->vval.v_list, li); + +! if (++cnt >= maxline && maxline >= 0) +! break; +! if (readlen <= 0) + break; + } +! else if (buf[filtd] == NUL) +! buf[filtd] = '\n'; + #ifdef FEAT_MBYTE +! else if (buf[filtd] == 0xef +! && enc_utf8 +! && filtd + 2 < buflen +! && !binary +! && buf[filtd + 1] == 0xbb +! && buf[filtd + 2] == 0xbf) +! { +! /* remove utf-8 byte order mark */ +! mch_memmove(buf + filtd, buf + filtd + 3, buflen - filtd - 3); +! --filtd; +! buflen -= 3; + } + #endif +! } +! if (readlen <= 0) +! break; + +! if (tolist == 0) + { +! if (buflen >= FREAD_SIZE / 2) + { +! /* "buf" is full, need to move text to an allocated buffer */ +! if (prev == NULL) + { +! prev = vim_strnsave(buf, buflen); +! prevlen = buflen; + } +! else + { +! s = alloc((unsigned)(prevlen + buflen)); +! if (s != NULL) +! { +! mch_memmove(s, prev, prevlen); +! mch_memmove(s + prevlen, buf, buflen); +! vim_free(prev); +! prev = s; +! prevlen += buflen; +! } + } +! filtd = 0; + } + } +! else +! { +! mch_memmove(buf, buf + tolist, buflen - tolist); +! filtd -= tolist; +! } +! } + + /* + * For a negative line count use only the lines at the end of the file, + * free the rest. + */ +! if (maxline < 0) + while (cnt > -maxline) + { + listitem_remove(rettv->vval.v_list, rettv->vval.v_list->lv_first); + --cnt; + } + + vim_free(prev); + fclose(fd); + } +--- 14421,14529 ---- + li->li_tv.vval.v_string = s; + list_append(rettv->vval.v_list, li); + +! start = p + 1; /* step over newline */ +! if ((++cnt >= maxline && maxline >= 0) || readlen <= 0) + break; + } +! else if (*p == NUL) +! *p = '\n'; + #ifdef FEAT_MBYTE +! /* Check for utf8 "bom"; U+FEFF is encoded as EF BB BF. Do this +! * when finding the BF and check the previous two bytes. */ +! else if (*p == 0xbf && enc_utf8 && !binary) +! { +! /* Find the two bytes before the 0xbf. If p is at buf, or buf +! * + 1, these may be in the "prev" string. */ +! char_u back1 = p >= buf + 1 ? p[-1] +! : prevlen >= 1 ? prev[prevlen - 1] : NUL; +! char_u back2 = p >= buf + 2 ? p[-2] +! : p == buf + 1 && prevlen >= 1 ? prev[prevlen - 1] +! : prevlen >= 2 ? prev[prevlen - 2] : NUL; +! +! if (back2 == 0xef && back1 == 0xbb) +! { +! char_u *dest = p - 2; +! +! /* Usually a BOM is at the beginning of a file, and so at +! * the beginning of a line; then we can just step over it. +! */ +! if (start == dest) +! start = p + 1; +! else +! { +! /* have to shuffle buf to close gap */ +! int adjust_prevlen = 0; +! +! if (dest < buf) +! { +! adjust_prevlen = buf - dest; /* must be 1 or 2 */ +! dest = buf; +! } +! if (readlen > p - buf + 1) +! mch_memmove(dest, p + 1, readlen - (p - buf) - 1); +! readlen -= 3 - adjust_prevlen; +! prevlen -= adjust_prevlen; +! p = dest - 1; +! } +! } + } + #endif +! } /* for */ + +! if (failed || (cnt >= maxline && maxline >= 0) || readlen <= 0) +! break; +! if (start < p) + { +! /* There's part of a line in buf, store it in "prev". */ +! if (p - start + prevlen >= prevsize) + { +! /* need bigger "prev" buffer */ +! char_u *newprev; +! +! /* A common use case is ordinary text files and "prev" gets a +! * fragment of a line, so the first allocation is made +! * small, to avoid repeatedly 'allocing' large and +! * 'reallocing' small. */ +! if (prevsize == 0) +! prevsize = p - start; +! else + { +! long grow50pc = (prevsize * 3) / 2; +! long growmin = (p - start) * 2 + prevlen; +! prevsize = grow50pc > growmin ? grow50pc : growmin; + } +! if ((newprev = vim_realloc(prev, prevsize)) == NULL) + { +! do_outofmem_msg((long_u)prevsize); +! failed = TRUE; +! break; + } +! prev = newprev; + } ++ /* Add the line part to end of "prev". */ ++ mch_memmove(prev + prevlen, start, p - start); ++ prevlen += p - start; + } +! } /* while */ + + /* + * For a negative line count use only the lines at the end of the file, + * free the rest. + */ +! if (!failed && maxline < 0) + while (cnt > -maxline) + { + listitem_remove(rettv->vval.v_list, rettv->vval.v_list->lv_first); + --cnt; + } + ++ if (failed) ++ { ++ list_free(rettv->vval.v_list, TRUE); ++ /* readfile doc says an empty list is returned on error */ ++ rettv->vval.v_list = list_alloc(); ++ } ++ + vim_free(prev); + fclose(fd); + } +*************** +*** 21802,21808 **** + fp = HI2UF(hi); + + if (fp->uf_flags & FC_DICT) +! return ""; /* don't show dict functions */ + + if (STRLEN(fp->uf_name) + 4 >= IOSIZE) + return fp->uf_name; /* prevents overflow */ +--- 21846,21852 ---- + fp = HI2UF(hi); + + if (fp->uf_flags & FC_DICT) +! return (char_u *)""; /* don't show dict functions */ + + if (STRLEN(fp->uf_name) + 4 >= IOSIZE) + return fp->uf_name; /* prevents overflow */ +*** ../vim-7.3.426/src/version.c 2012-02-04 23:34:57.000000000 +0100 +--- src/version.c 2012-02-05 00:38:34.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 427, + /**/ + +-- +One difference between a man and a machine is that a machine is quiet +when well oiled. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7ff731831b65c87f95a6b3232cab9ecace2aff89 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:39 +0100 Subject: [PATCH 0155/3340] - patchlevel 428 --- 7.3.428 | 113 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 113 insertions(+) create mode 100644 7.3.428 diff --git a/7.3.428 b/7.3.428 new file mode 100644 index 00000000..89567ed8 --- /dev/null +++ b/7.3.428 @@ -0,0 +1,113 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.428 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.428 +Problem: Win32: an xpm file without a mask crashes Vim. +Solution: Fail when the mask is missing. (Dave Bodenstab) +Files: src/xpm_w32.c + + +*** ../vim-7.3.427/src/xpm_w32.c 2010-08-15 21:57:25.000000000 +0200 +--- src/xpm_w32.c 2012-02-05 00:46:13.000000000 +0100 +*************** +*** 1,4 **** +! /* + * Load XPM image. + * + * This function is placed in separate file because Xpm headers conflict with +--- 1,5 ---- +! /* vi:set ts=8 sts=4 sw=4: +! * + * Load XPM image. + * + * This function is placed in separate file because Xpm headers conflict with +*************** +*** 30,38 **** + #include "xpm.h" + + /* +! * Tries to load Xpm image from file 'filename'. +! * If fails return -1. +! * success - 0 and image and mask BITMAPS + */ + int + LoadXpmImage(filename, hImage, hShape) +--- 31,40 ---- + #include "xpm.h" + + /* +! * Tries to load an Xpm image from the file "filename". +! * Returns -1 on failure. +! * Returns 0 on success and stores image and mask BITMAPS in "hImage" and +! * "hShape". + */ + int + LoadXpmImage(filename, hImage, hShape) +*************** +*** 40,46 **** + HBITMAP *hImage; + HBITMAP *hShape; + { +! XImage *img; /* loaded image */ + XImage *shp; /* shapeimage */ + XpmAttributes attr; + int res; +--- 42,48 ---- + HBITMAP *hImage; + HBITMAP *hShape; + { +! XImage *img; /* loaded image */ + XImage *shp; /* shapeimage */ + XpmAttributes attr; + int res; +*************** +*** 51,60 **** + DeleteDC(hdc); + if (res < 0) + return -1; +! else + { +! *hImage = img->bitmap; +! *hShape = shp->bitmap; +! return 0; + } + } +--- 53,65 ---- + DeleteDC(hdc); + if (res < 0) + return -1; +! if (shp == NULL) + { +! if (img) +! XDestroyImage(img); +! return -1; + } ++ *hImage = img->bitmap; ++ *hShape = shp->bitmap; ++ return 0; + } +*** ../vim-7.3.427/src/version.c 2012-02-05 00:39:14.000000000 +0100 +--- src/version.c 2012-02-05 00:47:08.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 428, + /**/ + +-- +I'm not familiar with this proof, but I'm aware of a significant +following of toddlers who believe that peanut butter is the solution +to all of life's problems... -- Tim Hammerquist + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 60da82b5b20f91d496de470b0373e87e8fcf43eb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:40 +0100 Subject: [PATCH 0156/3340] - patchlevel 429 --- 7.3.429 | 192 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 192 insertions(+) create mode 100644 7.3.429 diff --git a/7.3.429 b/7.3.429 new file mode 100644 index 00000000..801e25f9 --- /dev/null +++ b/7.3.429 @@ -0,0 +1,192 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.429 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.429 +Problem: When 'cpoptions' includes "E" "c0" in the first column is an + error. The redo register is then set to the errornous command. +Solution: Do not set the redo register if the command fails because of an + empty region. (Hideki Eiraku) +Files: src/getchar.c, src/normal.c, src/proto/getchar.pro + + +*** ../vim-7.3.428/src/getchar.c 2012-01-10 22:26:12.000000000 +0100 +--- src/getchar.c 2012-02-05 01:05:09.000000000 +0100 +*************** +*** 470,475 **** +--- 470,493 ---- + } + } + ++ /* ++ * Discard the contents of the redo buffer and restore the previous redo ++ * buffer. ++ */ ++ void ++ CancelRedo() ++ { ++ if (!block_redo) ++ { ++ free_buff(&redobuff); ++ redobuff = old_redobuff; ++ old_redobuff.bh_first.b_next = NULL; ++ start_stuff(); ++ while (read_stuff(TRUE) != NUL) ++ ; ++ } ++ } ++ + #if defined(FEAT_AUTOCMD) || defined(FEAT_EVAL) || defined(PROTO) + /* + * Save redobuff and old_redobuff to save_redobuff and save_old_redobuff. +*************** +*** 691,699 **** + * Read a character from the redo buffer. Translates K_SPECIAL, CSI and + * multibyte characters. + * The redo buffer is left as it is. +! * if init is TRUE, prepare for redo, return FAIL if nothing to redo, OK +! * otherwise +! * if old is TRUE, use old_redobuff instead of redobuff + */ + static int + read_redo(init, old_redo) +--- 709,717 ---- + * Read a character from the redo buffer. Translates K_SPECIAL, CSI and + * multibyte characters. + * The redo buffer is left as it is. +! * If init is TRUE, prepare for redo, return FAIL if nothing to redo, OK +! * otherwise. +! * If old is TRUE, use old_redobuff instead of redobuff. + */ + static int + read_redo(init, old_redo) +*** ../vim-7.3.428/src/normal.c 2012-01-26 11:43:04.000000000 +0100 +--- src/normal.c 2012-02-05 01:06:01.000000000 +0100 +*************** +*** 1978,1984 **** +--- 1978,1987 ---- + VIsual_reselect = FALSE; /* don't reselect now */ + #endif + if (empty_region_error) ++ { + vim_beep(); ++ CancelRedo(); ++ } + else + { + (void)op_delete(oap); +*************** +*** 1992,1998 **** +--- 1995,2004 ---- + if (empty_region_error) + { + if (!gui_yank) ++ { + vim_beep(); ++ CancelRedo(); ++ } + } + else + (void)op_yank(oap, FALSE, !gui_yank); +*************** +*** 2004,2010 **** +--- 2010,2019 ---- + VIsual_reselect = FALSE; /* don't reselect now */ + #endif + if (empty_region_error) ++ { + vim_beep(); ++ CancelRedo(); ++ } + else + { + /* This is a new edit command, not a restart. Need to +*************** +*** 2066,2072 **** +--- 2075,2084 ---- + case OP_LOWER: + case OP_ROT13: + if (empty_region_error) ++ { + vim_beep(); ++ CancelRedo(); ++ } + else + op_tilde(oap); + check_cursor_col(); +*************** +*** 2099,2105 **** +--- 2111,2120 ---- + #endif + #ifdef FEAT_VISUALEXTRA + if (empty_region_error) ++ { + vim_beep(); ++ CancelRedo(); ++ } + else + { + /* This is a new edit command, not a restart. Need to +*************** +*** 2129,2135 **** +--- 2144,2153 ---- + #ifdef FEAT_VISUALEXTRA + if (empty_region_error) + #endif ++ { + vim_beep(); ++ CancelRedo(); ++ } + #ifdef FEAT_VISUALEXTRA + else + op_replace(oap, cap->nchar); +*** ../vim-7.3.428/src/proto/getchar.pro 2010-10-20 21:22:17.000000000 +0200 +--- src/proto/getchar.pro 2012-02-05 01:05:20.000000000 +0100 +*************** +*** 4,11 **** + char_u *get_inserted __ARGS((void)); + int stuff_empty __ARGS((void)); + void typeahead_noflush __ARGS((int c)); +! void flush_buffers __ARGS((int typeahead)); + void ResetRedobuff __ARGS((void)); + void saveRedobuff __ARGS((void)); + void restoreRedobuff __ARGS((void)); + void AppendToRedobuff __ARGS((char_u *s)); +--- 4,12 ---- + char_u *get_inserted __ARGS((void)); + int stuff_empty __ARGS((void)); + void typeahead_noflush __ARGS((int c)); +! void flush_buffers __ARGS((int flush_typeahead)); + void ResetRedobuff __ARGS((void)); ++ void CancelRedo __ARGS((void)); + void saveRedobuff __ARGS((void)); + void restoreRedobuff __ARGS((void)); + void AppendToRedobuff __ARGS((char_u *s)); +*** ../vim-7.3.428/src/version.c 2012-02-05 00:47:56.000000000 +0100 +--- src/version.c 2012-02-05 01:09:23.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 429, + /**/ + +-- +The History of every major Galactic Civilization tends to pass through +three distinct and recognizable phases, those of Survival, Inquiry and +Sophistication, otherwise known as the How, Why and Where phases. +For instance, the first phase is characterized by the question 'How can +we eat?' the second by the question 'Why do we eat?' and the third by +the question 'Where shall we have lunch?' + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4adb1f1a993fdc1a678d8d638e1bdccd323fc31f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:40 +0100 Subject: [PATCH 0157/3340] - patchlevel 430 --- 7.3.430 | 80 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 7.3.430 diff --git a/7.3.430 b/7.3.430 new file mode 100644 index 00000000..c67e7fb0 --- /dev/null +++ b/7.3.430 @@ -0,0 +1,80 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.430 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.430 +Problem: When a custom filetype detection uses "augroup END" the conf + fileytpe detection does not have the filetypedetect group. +Solution: Always end the group and include filetypedetect in the conf + autocommand. (Lech Lorens) +Files: runtime/filetype.vim + + +*** ../vim-7.3.429/runtime/filetype.vim 2012-02-05 20:08:08.000000000 +0100 +--- runtime/filetype.vim 2012-02-05 19:59:40.000000000 +0100 +*************** +*** 2545,2561 **** + " detected filetypes. + runtime! ftdetect/*.vim + + + " Generic configuration file (check this last, it's just guessing!) +! au BufNewFile,BufRead,StdinReadPost * + \ if !did_filetype() && expand("") !~ g:ft_ignore_pat + \ && (getline(1) =~ '^#' || getline(2) =~ '^#' || getline(3) =~ '^#' + \ || getline(4) =~ '^#' || getline(5) =~ '^#') | + \ setf conf | + \ endif + +- augroup END +- + + " If the GUI is already running, may still need to install the Syntax menu. + " Don't do it when the 'M' flag is included in 'guioptions'. +--- 2545,2563 ---- + " detected filetypes. + runtime! ftdetect/*.vim + ++ " NOTE: The above command could have ended the filetypedetect autocmd group ++ " and started another one. Let's make sure it has ended to get to a consistant ++ " state. ++ augroup END + + " Generic configuration file (check this last, it's just guessing!) +! au filetypedetect BufNewFile,BufRead,StdinReadPost * + \ if !did_filetype() && expand("") !~ g:ft_ignore_pat + \ && (getline(1) =~ '^#' || getline(2) =~ '^#' || getline(3) =~ '^#' + \ || getline(4) =~ '^#' || getline(5) =~ '^#') | + \ setf conf | + \ endif + + + " If the GUI is already running, may still need to install the Syntax menu. + " Don't do it when the 'M' flag is included in 'guioptions'. +*** ../vim-7.3.429/src/version.c 2012-02-05 01:18:41.000000000 +0100 +--- src/version.c 2012-02-05 20:02:18.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 430, + /**/ + +-- +The technology involved in making anything invisible is so infinitely +complex that nine hundred and ninety-nine billion, nine hundred and +ninety-nine million, nine hundred and ninety-nine thousand, nine hundred +and ninety-nine times out of a trillion it is much simpler and more +effective just to take the thing away and do without it. + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c72e4f2ea3f9834c93b0c819d79f882c298a76ed Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:40 +0100 Subject: [PATCH 0158/3340] - patchlevel 431 --- 7.3.431 | 280 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 280 insertions(+) create mode 100644 7.3.431 diff --git a/7.3.431 b/7.3.431 new file mode 100644 index 00000000..2e4e62b3 --- /dev/null +++ b/7.3.431 @@ -0,0 +1,280 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.431 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.431 +Problem: Fetching a key at a prompt may be confused by escape sequences. + Especially when getting a prompt at a VimEnter autocommand. + (Alex Efros) +Solution: Properly handle escape sequences deleted by check_termcode(). +Files: src/getchar.c, src/misc1.c, src/term.c, src/proto/term.pro + + +*** ../vim-7.3.430/src/getchar.c 2012-02-05 01:18:41.000000000 +0100 +--- src/getchar.c 2012-02-05 22:04:33.000000000 +0100 +*************** +*** 2282,2288 **** + typebuf.tb_off] == RM_YES)) + && !timedout) + { +! keylen = check_termcode(max_mlen + 1, NULL, 0); + + /* If no termcode matched but 'pastetoggle' + * matched partially it's like an incomplete key +--- 2282,2289 ---- + typebuf.tb_off] == RM_YES)) + && !timedout) + { +! keylen = check_termcode(max_mlen + 1, +! NULL, 0, NULL); + + /* If no termcode matched but 'pastetoggle' + * matched partially it's like an incomplete key +*** ../vim-7.3.430/src/misc1.c 2012-01-10 18:37:53.000000000 +0100 +--- src/misc1.c 2012-02-05 21:59:53.000000000 +0100 +*************** +*** 3105,3112 **** + int + get_keystroke() + { +! #define CBUFLEN 151 +! char_u buf[CBUFLEN]; + int len = 0; + int n; + int save_mapped_ctrl_c = mapped_ctrl_c; +--- 3105,3113 ---- + int + get_keystroke() + { +! char_u *buf = NULL; +! int buflen = 150; +! int maxlen; + int len = 0; + int n; + int save_mapped_ctrl_c = mapped_ctrl_c; +*************** +*** 3118,3129 **** + cursor_on(); + out_flush(); + + /* First time: blocking wait. Second time: wait up to 100ms for a +! * terminal code to complete. Leave some room for check_termcode() to +! * insert a key code into (max 5 chars plus NUL). And +! * fix_input_buffer() can triple the number of bytes. */ +! n = ui_inchar(buf + len, (CBUFLEN - 6 - len) / 3, +! len == 0 ? -1L : 100L, 0); + if (n > 0) + { + /* Replace zero and CSI by a special key code. */ +--- 3119,3147 ---- + cursor_on(); + out_flush(); + ++ /* Leave some room for check_termcode() to insert a key code into (max ++ * 5 chars plus NUL). And fix_input_buffer() can triple the number of ++ * bytes. */ ++ maxlen = (buflen - 6 - len) / 3; ++ if (buf == NULL) ++ buf = alloc(buflen); ++ else if (maxlen < 10) ++ { ++ /* Need some more space. This migth happen when receiving a long ++ * escape sequence. */ ++ buflen += 100; ++ buf = vim_realloc(buf, buflen); ++ maxlen = (buflen - 6 - len) / 3; ++ } ++ if (buf == NULL) ++ { ++ do_outofmem_msg((long_u)buflen); ++ return ESC; /* panic! */ ++ } ++ + /* First time: blocking wait. Second time: wait up to 100ms for a +! * terminal code to complete. */ +! n = ui_inchar(buf + len, maxlen, len == 0 ? -1L : 100L, 0); + if (n > 0) + { + /* Replace zero and CSI by a special key code. */ +*************** +*** 3135,3141 **** + ++waited; /* keep track of the waiting time */ + + /* Incomplete termcode and not timed out yet: get more characters */ +! if ((n = check_termcode(1, buf, len)) < 0 + && (!p_ttimeout || waited * 100L < (p_ttm < 0 ? p_tm : p_ttm))) + continue; + +--- 3153,3159 ---- + ++waited; /* keep track of the waiting time */ + + /* Incomplete termcode and not timed out yet: get more characters */ +! if ((n = check_termcode(1, buf, buflen, &len)) < 0 + && (!p_ttimeout || waited * 100L < (p_ttm < 0 ? p_tm : p_ttm))) + continue; + +*************** +*** 3203,3209 **** + { + if (MB_BYTE2LEN(n) > len) + continue; /* more bytes to get */ +! buf[len >= CBUFLEN ? CBUFLEN - 1 : len] = NUL; + n = (*mb_ptr2char)(buf); + } + #endif +--- 3221,3227 ---- + { + if (MB_BYTE2LEN(n) > len) + continue; /* more bytes to get */ +! buf[len >= buflen ? buflen - 1 : len] = NUL; + n = (*mb_ptr2char)(buf); + } + #endif +*************** +*** 3213,3218 **** +--- 3231,3237 ---- + #endif + break; + } ++ vim_free(buf); + + mapped_ctrl_c = save_mapped_ctrl_c; + return n; +*** ../vim-7.3.430/src/term.c 2012-01-26 13:01:54.000000000 +0100 +--- src/term.c 2012-02-05 21:45:09.000000000 +0100 +*************** +*** 3785,3798 **** + * With a match, the match is removed, the replacement code is inserted in + * typebuf.tb_buf[] and the number of characters in typebuf.tb_buf[] is + * returned. +! * When "buf" is not NULL, it is used instead of typebuf.tb_buf[]. "buflen" is +! * then the length of the string in buf[]. + */ + int +! check_termcode(max_offset, buf, buflen) + int max_offset; + char_u *buf; +! int buflen; + { + char_u *tp; + char_u *p; +--- 3785,3800 ---- + * With a match, the match is removed, the replacement code is inserted in + * typebuf.tb_buf[] and the number of characters in typebuf.tb_buf[] is + * returned. +! * When "buf" is not NULL, buf[bufsize] is used instead of typebuf.tb_buf[]. +! * "buflen" is then the length of the string in buf[] and is updated for +! * inserts and deletes. + */ + int +! check_termcode(max_offset, buf, bufsize, buflen) + int max_offset; + char_u *buf; +! int bufsize; +! int *buflen; + { + char_u *tp; + char_u *p; +*************** +*** 3864,3873 **** + } + else + { +! if (offset >= buflen) + break; + tp = buf + offset; +! len = buflen - offset; + } + + /* +--- 3866,3875 ---- + } + else + { +! if (offset >= *buflen) + break; + tp = buf + offset; +! len = *buflen - offset; + } + + /* +*************** +*** 5002,5013 **** + if (extra < 0) + /* remove matched characters */ + mch_memmove(buf + offset, buf + offset - extra, +! (size_t)(buflen + offset + extra)); + else if (extra > 0) +! /* insert the extra space we need */ + mch_memmove(buf + offset + extra, buf + offset, +! (size_t)(buflen - offset)); + mch_memmove(buf + offset, string, (size_t)new_slen); + } + return retval == 0 ? (len + extra + offset) : retval; + } +--- 5004,5021 ---- + if (extra < 0) + /* remove matched characters */ + mch_memmove(buf + offset, buf + offset - extra, +! (size_t)(*buflen + offset + extra)); + else if (extra > 0) +! { +! /* Insert the extra space we need. If there is insufficient +! * space return -1. */ +! if (*buflen + extra + new_slen >= bufsize) +! return -1; + mch_memmove(buf + offset + extra, buf + offset, +! (size_t)(*buflen - offset)); +! } + mch_memmove(buf + offset, string, (size_t)new_slen); ++ *buflen = *buflen + extra + new_slen; + } + return retval == 0 ? (len + extra + offset) : retval; + } +*** ../vim-7.3.430/src/proto/term.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/term.pro 2012-02-05 21:45:16.000000000 +0100 +*************** +*** 50,56 **** + char_u *get_termcode __ARGS((int i)); + void del_termcode __ARGS((char_u *name)); + void set_mouse_topline __ARGS((win_T *wp)); +! int check_termcode __ARGS((int max_offset, char_u *buf, int buflen)); + char_u *replace_termcodes __ARGS((char_u *from, char_u **bufp, int from_part, int do_lt, int special)); + int find_term_bykeys __ARGS((char_u *src)); + void show_termcodes __ARGS((void)); +--- 50,56 ---- + char_u *get_termcode __ARGS((int i)); + void del_termcode __ARGS((char_u *name)); + void set_mouse_topline __ARGS((win_T *wp)); +! int check_termcode __ARGS((int max_offset, char_u *buf, int bufsize, int *buflen)); + char_u *replace_termcodes __ARGS((char_u *from, char_u **bufp, int from_part, int do_lt, int special)); + int find_term_bykeys __ARGS((char_u *src)); + void show_termcodes __ARGS((void)); +*** ../vim-7.3.430/src/version.c 2012-02-05 20:08:30.000000000 +0100 +--- src/version.c 2012-02-05 22:03:43.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 431, + /**/ + +-- +"You know, it's at times like this when I'm trapped in a Vogon airlock with +a man from Betelgeuse and about to die of asphyxiation in deep space that I +really wish I'd listened to what my mother told me when I was young!" +"Why, what did she tell you?" +"I don't know, I didn't listen!" + -- Arthur Dent and Ford Prefect in Douglas Adams' + "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7520b485ea9b6d7d663a9a87424279b989de3181 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:41 +0100 Subject: [PATCH 0159/3340] - patchlevel 432 --- 7.3.432 | 228 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 228 insertions(+) create mode 100644 7.3.432 diff --git a/7.3.432 b/7.3.432 new file mode 100644 index 00000000..c01dd59a --- /dev/null +++ b/7.3.432 @@ -0,0 +1,228 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.432 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.432 +Problem: ACLs are not supported for ZFS or NFSv4 on Solaris. +Solution: Add configure check and code. (Danek Duvall) +Files: src/configure.in, src/auto/configure, src/config.h.in, + src/os_unix.c + + +*** ../vim-7.3.431/src/configure.in 2011-12-14 20:51:19.000000000 +0100 +--- src/configure.in 2012-02-05 22:40:22.000000000 +0100 +*************** +*** 3106,3111 **** +--- 3106,3112 ---- + + dnl Link with -lposix1e for ACL stuff; if not found, try -lacl for SGI + dnl when -lacl works, also try to use -lattr (required for Debian). ++ dnl On Solaris, use the acl_get/set functions in libsec, if present. + AC_MSG_CHECKING(--disable-acl argument) + AC_ARG_ENABLE(acl, + [ --disable-acl Don't check for ACL support.], +*************** +*** 3128,3133 **** +--- 3129,3135 ---- + AC_MSG_RESULT(yes); AC_DEFINE(HAVE_POSIX_ACL), + AC_MSG_RESULT(no)) + ++ AC_CHECK_LIB(sec, acl_get, [LIBS="$LIBS -lsec"; AC_DEFINE(HAVE_SOLARIS_ZFS_ACL)], + AC_MSG_CHECKING(for Solaris ACL support) + AC_TRY_LINK([ + #ifdef HAVE_SYS_ACL_H +*************** +*** 3135,3141 **** + #endif], [acl("foo", GETACLCNT, 0, NULL); + ], + AC_MSG_RESULT(yes); AC_DEFINE(HAVE_SOLARIS_ACL), +! AC_MSG_RESULT(no)) + + AC_MSG_CHECKING(for AIX ACL support) + AC_TRY_LINK([ +--- 3137,3143 ---- + #endif], [acl("foo", GETACLCNT, 0, NULL); + ], + AC_MSG_RESULT(yes); AC_DEFINE(HAVE_SOLARIS_ACL), +! AC_MSG_RESULT(no))) + + AC_MSG_CHECKING(for AIX ACL support) + AC_TRY_LINK([ +*** ../vim-7.3.431/src/auto/configure 2011-12-14 20:51:19.000000000 +0100 +--- src/auto/configure 2012-02-05 22:41:01.000000000 +0100 +*************** +*** 11328,11334 **** + rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Solaris ACL support" >&5 + $as_echo_n "checking for Solaris ACL support... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ +--- 11328,11374 ---- + rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking for acl_get in -lsec" >&5 +! $as_echo_n "checking for acl_get in -lsec... " >&6; } +! if test "${ac_cv_lib_sec_acl_get+set}" = set; then : +! $as_echo_n "(cached) " >&6 +! else +! ac_check_lib_save_LIBS=$LIBS +! LIBS="-lsec $LIBS" +! cat confdefs.h - <<_ACEOF >conftest.$ac_ext +! /* end confdefs.h. */ +! +! /* Override any GCC internal prototype to avoid an error. +! Use char because int might match the return type of a GCC +! builtin and then its argument prototype would still apply. */ +! #ifdef __cplusplus +! extern "C" +! #endif +! char acl_get (); +! int +! main () +! { +! return acl_get (); +! ; +! return 0; +! } +! _ACEOF +! if ac_fn_c_try_link "$LINENO"; then : +! ac_cv_lib_sec_acl_get=yes +! else +! ac_cv_lib_sec_acl_get=no +! fi +! rm -f core conftest.err conftest.$ac_objext \ +! conftest$ac_exeext conftest.$ac_ext +! LIBS=$ac_check_lib_save_LIBS +! fi +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sec_acl_get" >&5 +! $as_echo "$ac_cv_lib_sec_acl_get" >&6; } +! if test "x$ac_cv_lib_sec_acl_get" = x""yes; then : +! LIBS="$LIBS -lsec"; $as_echo "#define HAVE_SOLARIS_ZFS_ACL 1" >>confdefs.h +! +! else +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Solaris ACL support" >&5 + $as_echo_n "checking for Solaris ACL support... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ +*************** +*** 11355,11360 **** +--- 11395,11402 ---- + fi + rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++ fi ++ + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AIX ACL support" >&5 + $as_echo_n "checking for AIX ACL support... " >&6; } +*** ../vim-7.3.431/src/config.h.in 2011-09-02 12:27:20.000000000 +0200 +--- src/config.h.in 2012-02-05 22:40:22.000000000 +0100 +*************** +*** 363,368 **** +--- 363,369 ---- + + /* Define if you want to add support for ACL */ + #undef HAVE_POSIX_ACL ++ #undef HAVE_SOLARIS_ZFS_ACL + #undef HAVE_SOLARIS_ACL + #undef HAVE_AIX_ACL + +*** ../vim-7.3.431/src/os_unix.c 2012-01-10 22:26:12.000000000 +0100 +--- src/os_unix.c 2012-02-05 22:40:22.000000000 +0100 +*************** +*** 2746,2751 **** +--- 2746,2758 ---- + #ifdef HAVE_POSIX_ACL + ret = (vim_acl_T)acl_get_file((char *)fname, ACL_TYPE_ACCESS); + #else ++ #ifdef HAVE_SOLARIS_ZFS_ACL ++ acl_t *aclent; ++ ++ if (acl_get((char *)fname, 0, &aclent) < 0) ++ return NULL; ++ ret = (vim_acl_T)aclent; ++ #else + #ifdef HAVE_SOLARIS_ACL + vim_acl_solaris_T *aclent; + +*************** +*** 2791,2796 **** +--- 2798,2804 ---- + ret = (vim_acl_T)aclent; + #endif /* HAVE_AIX_ACL */ + #endif /* HAVE_SOLARIS_ACL */ ++ #endif /* HAVE_SOLARIS_ZFS_ACL */ + #endif /* HAVE_POSIX_ACL */ + return ret; + } +*************** +*** 2808,2813 **** +--- 2816,2824 ---- + #ifdef HAVE_POSIX_ACL + acl_set_file((char *)fname, ACL_TYPE_ACCESS, (acl_t)aclent); + #else ++ #ifdef HAVE_SOLARIS_ZFS_ACL ++ acl_set((char *)fname, (acl_t *)aclent); ++ #else + #ifdef HAVE_SOLARIS_ACL + acl((char *)fname, SETACL, ((vim_acl_solaris_T *)aclent)->acl_cnt, + ((vim_acl_solaris_T *)aclent)->acl_entry); +*************** +*** 2816,2821 **** +--- 2827,2833 ---- + chacl((char *)fname, aclent, ((struct acl *)aclent)->acl_len); + #endif /* HAVE_AIX_ACL */ + #endif /* HAVE_SOLARIS_ACL */ ++ #endif /* HAVE_SOLARIS_ZFS_ACL */ + #endif /* HAVE_POSIX_ACL */ + } + +*************** +*** 2828,2833 **** +--- 2840,2848 ---- + #ifdef HAVE_POSIX_ACL + acl_free((acl_t)aclent); + #else ++ #ifdef HAVE_SOLARIS_ZFS_ACL ++ acl_free((acl_t *)aclent); ++ #else + #ifdef HAVE_SOLARIS_ACL + free(((vim_acl_solaris_T *)aclent)->acl_entry); + free(aclent); +*************** +*** 2836,2841 **** +--- 2851,2857 ---- + free(aclent); + #endif /* HAVE_AIX_ACL */ + #endif /* HAVE_SOLARIS_ACL */ ++ #endif /* HAVE_SOLARIS_ZFS_ACL */ + #endif /* HAVE_POSIX_ACL */ + } + #endif +*** ../vim-7.3.431/src/version.c 2012-02-05 22:05:44.000000000 +0100 +--- src/version.c 2012-02-05 22:44:10.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 432, + /**/ + +-- +If you put 7 of the most talented OSS developers in a room for a week +and asked them to fix a bug in a spreadsheet program, in 1 week +you'd have 2 new mail readers and a text-based web browser. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b3b8b923287683478c4268a51af1c962e3f62201 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:41 +0100 Subject: [PATCH 0160/3340] - patchlevel 433 --- 7.3.433 | 92 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 92 insertions(+) create mode 100644 7.3.433 diff --git a/7.3.433 b/7.3.433 new file mode 100644 index 00000000..bb83828f --- /dev/null +++ b/7.3.433 @@ -0,0 +1,92 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.433 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.433 +Problem: Using continued lines in a Vim script can be slow. +Solution: Instead of reallocating for every line use a growarray. (Yasuhiro + Matsumoto) +Files: src/ex_cmds2.c + + +*** ../vim-7.3.432/src/ex_cmds2.c 2012-02-04 21:57:44.000000000 +0100 +--- src/ex_cmds2.c 2012-02-05 23:06:31.000000000 +0100 +*************** +*** 3439,3460 **** + { + /* compensate for the one line read-ahead */ + --sourcing_lnum; +! for (;;) + { +! sp->nextline = get_one_sourceline(sp); +! if (sp->nextline == NULL) +! break; +! p = skipwhite(sp->nextline); +! if (*p != '\\') +! break; +! s = alloc((unsigned)(STRLEN(line) + STRLEN(p))); +! if (s == NULL) /* out of memory */ +! break; +! STRCPY(s, line); +! STRCAT(s, p + 1); + vim_free(line); +! line = s; +! vim_free(sp->nextline); + } + } + +--- 3439,3470 ---- + { + /* compensate for the one line read-ahead */ + --sourcing_lnum; +! +! /* Get the next line and concatenate it when it starts with a +! * backslash. We always need to read the next line, keep it in +! * sp->nextline. */ +! sp->nextline = get_one_sourceline(sp); +! if (sp->nextline != NULL && *(p = skipwhite(sp->nextline)) == '\\') + { +! garray_T ga; +! +! ga_init2(&ga, (int)sizeof(char_u), 200); +! ga_concat(&ga, line); +! ga_concat(&ga, p + 1); +! for (;;) +! { +! vim_free(sp->nextline); +! sp->nextline = get_one_sourceline(sp); +! if (sp->nextline == NULL) +! break; +! p = skipwhite(sp->nextline); +! if (*p != '\\') +! break; +! ga_concat(&ga, p + 1); +! } +! ga_append(&ga, NUL); + vim_free(line); +! line = ga.ga_data; + } + } + +*** ../vim-7.3.432/src/version.c 2012-02-05 22:51:27.000000000 +0100 +--- src/version.c 2012-02-05 23:09:21.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 433, + /**/ + +-- +Due knot trussed yore spell chequer two fined awl miss steaks. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 466924ff9f6ea858cb4d12b8dbe15b425b0d77a3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:41 +0100 Subject: [PATCH 0161/3340] - patchlevel 434 --- 7.3.434 | 233 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 233 insertions(+) create mode 100644 7.3.434 diff --git a/7.3.434 b/7.3.434 new file mode 100644 index 00000000..52c14b90 --- /dev/null +++ b/7.3.434 @@ -0,0 +1,233 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.434 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.434 +Problem: Using join() can be slow. +Solution: Compute the size of the result before allocation to avoid a lot of + allocations and copies. (Taro Muraoka) +Files: src/eval.c + + +*** ../vim-7.3.433/src/eval.c 2012-02-05 00:39:14.000000000 +0100 +--- src/eval.c 2012-02-06 00:05:31.000000000 +0100 +*************** +*** 442,447 **** +--- 442,448 ---- + static list_T *list_copy __ARGS((list_T *orig, int deep, int copyID)); + static void list_remove __ARGS((list_T *l, listitem_T *item, listitem_T *item2)); + static char_u *list2string __ARGS((typval_T *tv, int copyID)); ++ static int list_join_inner __ARGS((garray_T *gap, list_T *l, char_u *sep, int echo_style, int copyID, garray_T *join_gap)); + static int list_join __ARGS((garray_T *gap, list_T *l, char_u *sep, int echo, int copyID)); + static int free_unref_items __ARGS((int copyID)); + static void set_ref_in_ht __ARGS((hashtab_T *ht, int copyID)); +*************** +*** 6571,6617 **** + return (char_u *)ga.ga_data; + } + +! /* +! * Join list "l" into a string in "*gap", using separator "sep". +! * When "echo_style" is TRUE use String as echoed, otherwise as inside a List. +! * Return FAIL or OK. +! */ + static int +! list_join(gap, l, sep, echo_style, copyID) +! garray_T *gap; + list_T *l; + char_u *sep; + int echo_style; + int copyID; + { + int first = TRUE; + char_u *tofree; + char_u numbuf[NUMBUFLEN]; + listitem_T *item; + char_u *s; + + for (item = l->lv_first; item != NULL && !got_int; item = item->li_next) + { +- if (first) +- first = FALSE; +- else +- ga_concat(gap, sep); +- + if (echo_style) + s = echo_string(&item->li_tv, &tofree, numbuf, copyID); + else + s = tv2string(&item->li_tv, &tofree, numbuf, copyID); +- if (s != NULL) +- ga_concat(gap, s); +- vim_free(tofree); + if (s == NULL) + return FAIL; + line_breakcheck(); + } + return OK; + } + + /* + * Garbage collection for lists and dictionaries. + * + * We use reference counts to be able to free most items right away when they +--- 6572,6690 ---- + return (char_u *)ga.ga_data; + } + +! typedef struct join_S { +! char_u *s; +! char_u *tofree; +! } join_T; +! + static int +! list_join_inner(gap, l, sep, echo_style, copyID, join_gap) +! garray_T *gap; /* to store the result in */ + list_T *l; + char_u *sep; + int echo_style; + int copyID; ++ garray_T *join_gap; /* to keep each list item string */ + { ++ int i; ++ join_T *p; ++ int len; ++ int sumlen = 0; + int first = TRUE; + char_u *tofree; + char_u numbuf[NUMBUFLEN]; + listitem_T *item; + char_u *s; + ++ /* Stringify each item in the list. */ + for (item = l->lv_first; item != NULL && !got_int; item = item->li_next) + { + if (echo_style) + s = echo_string(&item->li_tv, &tofree, numbuf, copyID); + else + s = tv2string(&item->li_tv, &tofree, numbuf, copyID); + if (s == NULL) + return FAIL; ++ ++ len = (int)STRLEN(s); ++ sumlen += len; ++ ++ ga_grow(join_gap, 1); ++ p = ((join_T *)join_gap->ga_data) + (join_gap->ga_len++); ++ if (tofree != NULL || s != numbuf) ++ { ++ p->s = s; ++ p->tofree = tofree; ++ } ++ else ++ { ++ p->s = vim_strnsave(s, len); ++ p->tofree = p->s; ++ } ++ ++ line_breakcheck(); ++ } ++ ++ /* Allocate result buffer with its total size, avoid re-allocation and ++ * multiple copy operations. Add 2 for a tailing ']' and NUL. */ ++ if (join_gap->ga_len >= 2) ++ sumlen += (int)STRLEN(sep) * (join_gap->ga_len - 1); ++ if (ga_grow(gap, sumlen + 2) == FAIL) ++ return FAIL; ++ ++ for (i = 0; i < join_gap->ga_len && !got_int; ++i) ++ { ++ if (first) ++ first = FALSE; ++ else ++ ga_concat(gap, sep); ++ p = ((join_T *)join_gap->ga_data) + i; ++ ++ if (p->s != NULL) ++ ga_concat(gap, p->s); + line_breakcheck(); + } ++ + return OK; + } + + /* ++ * Join list "l" into a string in "*gap", using separator "sep". ++ * When "echo_style" is TRUE use String as echoed, otherwise as inside a List. ++ * Return FAIL or OK. ++ */ ++ static int ++ list_join(gap, l, sep, echo_style, copyID) ++ garray_T *gap; ++ list_T *l; ++ char_u *sep; ++ int echo_style; ++ int copyID; ++ { ++ garray_T join_ga; ++ int retval; ++ join_T *p; ++ int i; ++ ++ ga_init2(&join_ga, (int)sizeof(join_T), l->lv_len); ++ retval = list_join_inner(gap, l, sep, echo_style, copyID, &join_ga); ++ ++ /* Dispose each item in join_ga. */ ++ if (join_ga.ga_data != NULL) ++ { ++ p = (join_T *)join_ga.ga_data; ++ for (i = 0; i < join_ga.ga_len; ++i) ++ { ++ vim_free(p->tofree); ++ ++p; ++ } ++ ga_clear(&join_ga); ++ } ++ ++ return retval; ++ } ++ ++ /* + * Garbage collection for lists and dictionaries. + * + * We use reference counts to be able to free most items right away when they +*************** +*** 13406,13412 **** + char_u *rhs; + int mode; + int abbr = FALSE; +! int get_dict = FALSE; + mapblock_T *mp; + int buffer_local; + +--- 13479,13485 ---- + char_u *rhs; + int mode; + int abbr = FALSE; +! int get_dict = FALSE; + mapblock_T *mp; + int buffer_local; + +*** ../vim-7.3.433/src/version.c 2012-02-05 23:10:25.000000000 +0100 +--- src/version.c 2012-02-06 00:10:23.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 434, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +30. Even though you died last week, you've managed to retain OPS on your + favorite IRC channel. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7656b7661edc2e627f49dbbf4f909eaf724f6b2c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 14:45:42 +0100 Subject: [PATCH 0162/3340] - patchlevel 434 --- README.patches | 41 +++++++++++++++++++++++ vim.spec | 89 ++++++++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 128 insertions(+), 2 deletions(-) diff --git a/README.patches b/README.patches index d082f57c..3f4196f2 100644 --- a/README.patches +++ b/README.patches @@ -424,3 +424,44 @@ Individual patches for Vim 7.3: 1520 7.3.391 can't check if the XPM_W32 feature is enabled 3505 7.3.392 setting 'undofile' does not trigger reading the undo file 4803 7.3.393 Win32: When resizing Vim it may be moved to another monitor + 1866 7.3.394 screen messed up when placing a mark while starting up + 3012 7.3.395 (after 7.3.251) "dv?bar" deletes too much and breaks undo + 1598 7.3.396 operator can become linewise after forcing it characterwise + 6186 7.3.397 ":helpgrep" does not work when 'encoding' is not utf-8 + 1928 7.3.398 jumping to wrong location after creating 10 location lists + 4052 7.3.399 ":cd" doesn't work when the path contains wildcards + 44950 7.3.400 compiler warnings for shadowed variables + 5138 7.3.401 couple more compiler warning for shadowed variables + 2006 7.3.402 line of text redrawn while at the more prompt + 2976 7.3.403 ":helpgrep" does not trigger QuickFixCmd* autocommands + 2638 7.3.404 using refresh "always" in a complete function breaks redo + 3074 7.3.405 xterm may delete the urxvt mouse termcap code + 2830 7.3.406 Win32: multi-byte characters in b:browsefilter broken + 7268 7.3.407 ":12verbose call F()" duplicates text while trying to truncate + 1446 7.3.408 (after 7.3.406) missing declaration breaks compilation + 1565 7.3.409 the license in pty.c is unclear + 1396 7.3.410 compiler error for // comment + 1775 7.3.411 pasting in Visual mode using the "" register does not work + 1502 7.3.412 storing a float in a session file has an additional '&' + 2770 7.3.413 compiler warnings on MS-Windows + 2304 7.3.414 using CTRL-A on "000" drops the leading zero + 1727 7.3.415 (after 7.3.359) function completion stops after a dictionary + 1687 7.3.416 (after 7.3.415) compiler warning for pointer type + 1460 7.3.417 (after 7.3.395) test 43 fails with a tiny build + 1705 7.3.418 get an error message when a user complete function returns -1 + 2376 7.3.419 DBCS encoding in a user command does not always work + 2202 7.3.420 "it" and "at" don't work properly with a dash in the tag name + 2161 7.3.421 get E832 when setting 'undofile' in vimrc + 3076 7.3.422 Python 3 does not have __members__ + 4733 7.3.423 small mistakes in comments, proto and indent + 2210 7.3.424 Win16 version missing some functions + 2572 7.3.425 (after 7.3.265) search history lines are duplicated + 8345 7.3.426 with '$' in 'cpoptions' $ is not displayed in the first column + 10744 7.3.427 readfile() can be slow with long lines + 2881 7.3.428 Win32: an xpm file without a mask crashes Vim + 5441 7.3.429 with 'E' in 'cpoptions' redo wrong after "c0" in first column + 2949 7.3.430 conf filetype detection may end up in the wrong augroup + 8810 7.3.431 fetching a key at a prompt may be confused by escape sequences + 6926 7.3.432 ACLs are not supported for ZFS or NFSv4 on Solaris + 2538 7.3.433 using continued lines in a Vim script can be slow + 6194 7.3.434 using join() can be slow diff --git a/vim.spec b/vim.spec index 2f03cd65..9adbe73d 100644 --- a/vim.spec +++ b/vim.spec @@ -18,13 +18,13 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 393 +%define patchlevel 434 Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 3%{?dist} +Release: 1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -448,6 +448,47 @@ Patch390: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.390 Patch391: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.391 Patch392: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.392 Patch393: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.393 +Patch394: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.394 +Patch395: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.395 +Patch396: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.396 +Patch397: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.397 +Patch398: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.398 +Patch399: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.399 +Patch400: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.400 +Patch401: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.401 +Patch402: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.402 +Patch403: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.403 +Patch404: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.404 +Patch405: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.405 +Patch406: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.406 +Patch407: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.407 +Patch408: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.408 +Patch409: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.409 +Patch410: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.410 +Patch411: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.411 +Patch412: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.412 +Patch413: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.413 +Patch414: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.414 +Patch415: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.415 +Patch416: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.416 +Patch417: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.417 +Patch418: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.418 +Patch419: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.419 +Patch420: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.420 +Patch421: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.421 +Patch422: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.422 +Patch423: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.423 +Patch424: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.424 +Patch425: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.425 +Patch426: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.426 +Patch427: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.427 +Patch428: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.428 +Patch429: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.429 +Patch430: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.430 +Patch431: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.431 +Patch432: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.432 +Patch433: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.433 +Patch434: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.434 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -985,6 +1026,47 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch391 -p0 %patch392 -p0 %patch393 -p0 +%patch394 -p0 +%patch395 -p0 +%patch396 -p0 +%patch397 -p0 +%patch398 -p0 +%patch399 -p0 +%patch400 -p0 +%patch401 -p0 +%patch402 -p0 +%patch403 -p0 +%patch404 -p0 +%patch405 -p0 +%patch406 -p0 +%patch407 -p0 +%patch408 -p0 +%patch409 -p0 +%patch410 -p0 +%patch411 -p0 +%patch412 -p0 +%patch413 -p0 +%patch414 -p0 +%patch415 -p0 +%patch416 -p0 +%patch417 -p0 +%patch418 -p0 +%patch419 -p0 +%patch420 -p0 +%patch421 -p0 +%patch422 -p0 +%patch423 -p0 +%patch424 -p0 +%patch425 -p0 +%patch426 -p0 +%patch427 -p0 +%patch428 -p0 +%patch429 -p0 +%patch430 -p0 +%patch431 -p0 +%patch432 -p0 +%patch433 -p0 +%patch434 -p0 # install spell files @@ -1439,6 +1521,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Tue Feb 07 2012 Karsten Hopp 7.3.434-1 +- patchlevel 434 + * Tue Feb 07 2012 Karsten Hopp 7.3.393-3 - update spec file template, bugzilla 736774 From 3442b3baa50f871a20114f28757d68c3fbb581c6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 7 Feb 2012 15:01:51 +0100 Subject: [PATCH 0163/3340] drop duplicate patch 416 --- vim.spec | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/vim.spec b/vim.spec index 9adbe73d..eb7c5675 100644 --- a/vim.spec +++ b/vim.spec @@ -470,7 +470,8 @@ Patch412: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.412 Patch413: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.413 Patch414: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.414 Patch415: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.415 -Patch416: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.416 +# Duplicate patch in 427: +#Patch416: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.416 Patch417: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.417 Patch418: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.418 Patch419: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.419 @@ -1048,7 +1049,8 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch413 -p0 %patch414 -p0 %patch415 -p0 -%patch416 -p0 +# Duplicate patch in 427: +#patch416 -p0 %patch417 -p0 %patch418 -p0 %patch419 -p0 From 4a68883680048c26829fe9036479250c8199e2cc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 Feb 2012 12:54:45 +0100 Subject: [PATCH 0164/3340] - patchlevel 435 --- 7.3.435 | 63 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 7.3.435 diff --git a/7.3.435 b/7.3.435 new file mode 100644 index 00000000..e1b13709 --- /dev/null +++ b/7.3.435 @@ -0,0 +1,63 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.435 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.435 +Problem: Compiler warning for unused variable. +Solution: Move the variable inside #ifdef. +Files: src/ex_cmds2.c + + +*** ../vim-7.3.434/src/ex_cmds2.c 2012-02-05 23:10:25.000000000 +0100 +--- src/ex_cmds2.c 2012-02-06 06:16:28.000000000 +0100 +*************** +*** 3400,3406 **** + { + struct source_cookie *sp = (struct source_cookie *)cookie; + char_u *line; +! char_u *p, *s; + + #ifdef FEAT_EVAL + /* If breakpoints have been added/deleted need to check for it. */ +--- 3400,3406 ---- + { + struct source_cookie *sp = (struct source_cookie *)cookie; + char_u *line; +! char_u *p; + + #ifdef FEAT_EVAL + /* If breakpoints have been added/deleted need to check for it. */ +*************** +*** 3471,3476 **** +--- 3471,3478 ---- + #ifdef FEAT_MBYTE + if (line != NULL && sp->conv.vc_type != CONV_NONE) + { ++ char_u *s; ++ + /* Convert the encoding of the script line. */ + s = string_convert(&sp->conv, line, NULL); + if (s != NULL) +*** ../vim-7.3.434/src/version.c 2012-02-06 00:13:16.000000000 +0100 +--- src/version.c 2012-02-11 20:38:49.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 435, + /**/ + +-- +Light travels faster than sound. This is why some people +appear bright until you hear them speak + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 56007da60f632989fa250e76a25318b339d9dc89 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 Feb 2012 12:54:48 +0100 Subject: [PATCH 0165/3340] - patchlevel 436 --- 7.3.436 | 111 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 111 insertions(+) create mode 100644 7.3.436 diff --git a/7.3.436 b/7.3.436 new file mode 100644 index 00000000..777371ca --- /dev/null +++ b/7.3.436 @@ -0,0 +1,111 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.436 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.436 +Problem: Compiler warnings for types on Windows. +Solution: Add type casts. (Mike Williams) +Files: src/eval.c + + +*** ../vim-7.3.435/src/eval.c 2012-02-06 00:13:16.000000000 +0100 +--- src/eval.c 2012-02-11 20:38:16.000000000 +0100 +*************** +*** 14462,14468 **** + --prevlen; + } + if (prevlen == 0) +! s = vim_strnsave(start, len); + else + { + /* Change "prev" buffer to be the right size. This way +--- 14462,14468 ---- + --prevlen; + } + if (prevlen == 0) +! s = vim_strnsave(start, (int)len); + else + { + /* Change "prev" buffer to be the right size. This way +*************** +*** 14529,14535 **** + + if (dest < buf) + { +! adjust_prevlen = buf - dest; /* must be 1 or 2 */ + dest = buf; + } + if (readlen > p - buf + 1) +--- 14529,14535 ---- + + if (dest < buf) + { +! adjust_prevlen = (int)(buf - dest); /* must be 1 or 2 */ + dest = buf; + } + if (readlen > p - buf + 1) +*************** +*** 14558,14568 **** + * small, to avoid repeatedly 'allocing' large and + * 'reallocing' small. */ + if (prevsize == 0) +! prevsize = p - start; + else + { + long grow50pc = (prevsize * 3) / 2; +! long growmin = (p - start) * 2 + prevlen; + prevsize = grow50pc > growmin ? grow50pc : growmin; + } + if ((newprev = vim_realloc(prev, prevsize)) == NULL) +--- 14558,14568 ---- + * small, to avoid repeatedly 'allocing' large and + * 'reallocing' small. */ + if (prevsize == 0) +! prevsize = (long)(p - start); + else + { + long grow50pc = (prevsize * 3) / 2; +! long growmin = (long)((p - start) * 2 + prevlen); + prevsize = grow50pc > growmin ? grow50pc : growmin; + } + if ((newprev = vim_realloc(prev, prevsize)) == NULL) +*************** +*** 14575,14581 **** + } + /* Add the line part to end of "prev". */ + mch_memmove(prev + prevlen, start, p - start); +! prevlen += p - start; + } + } /* while */ + +--- 14575,14581 ---- + } + /* Add the line part to end of "prev". */ + mch_memmove(prev + prevlen, start, p - start); +! prevlen += (long)(p - start); + } + } /* while */ + +*** ../vim-7.3.435/src/version.c 2012-02-11 20:40:49.000000000 +0100 +--- src/version.c 2012-02-11 20:43:18.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 436, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +39. You move into a new house and decide to Netscape before you landscape. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 96628cf2adf775b3df523b02d8f762c9d60be38e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 Feb 2012 12:54:48 +0100 Subject: [PATCH 0166/3340] - patchlevel 437 --- 7.3.437 | 73 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 7.3.437 diff --git a/7.3.437 b/7.3.437 new file mode 100644 index 00000000..889efe74 --- /dev/null +++ b/7.3.437 @@ -0,0 +1,73 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.437 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.437 +Problem: Continue looping inside FOR_ALL_TAB_WINDOWS even when already done. +Solution: Use goto instead of break. (Hirohito Higashi) +Files: src/fileio.c, src/globals.h + + +*** ../vim-7.3.436/src/fileio.c 2011-09-02 11:56:15.000000000 +0200 +--- src/fileio.c 2012-02-11 23:40:23.000000000 +0100 +*************** +*** 8898,8907 **** + if (tp != curtab) + goto_tabpage_tp(tp); + win_goto(aucmd_win); +! break; + } + } + } + + /* Remove the window and frame from the tree of frames. */ + (void)winframe_remove(curwin, &dummy, NULL); +--- 8898,8908 ---- + if (tp != curtab) + goto_tabpage_tp(tp); + win_goto(aucmd_win); +! goto win_found; + } + } + } ++ win_found: + + /* Remove the window and frame from the tree of frames. */ + (void)winframe_remove(curwin, &dummy, NULL); +*** ../vim-7.3.436/src/globals.h 2012-02-04 23:34:57.000000000 +0100 +--- src/globals.h 2012-02-11 23:43:45.000000000 +0100 +*************** +*** 535,540 **** +--- 535,544 ---- + EXTERN win_T *prevwin INIT(= NULL); /* previous window */ + # define W_NEXT(wp) ((wp)->w_next) + # define FOR_ALL_WINDOWS(wp) for (wp = firstwin; wp != NULL; wp = wp->w_next) ++ /* ++ * When using this macro "break" only breaks out of the inner loop. Use "goto" ++ * to break out of the tabpage loop. ++ */ + # define FOR_ALL_TAB_WINDOWS(tp, wp) \ + for ((tp) = first_tabpage; (tp) != NULL; (tp) = (tp)->tp_next) \ + for ((wp) = ((tp) == curtab) \ +*** ../vim-7.3.436/src/version.c 2012-02-11 20:44:01.000000000 +0100 +--- src/version.c 2012-02-11 23:40:47.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 437, + /**/ + +-- +The future isn't what it used to be. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2594a4f8ffe07973273d8836b76fbe919d1950b5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 Feb 2012 12:54:49 +0100 Subject: [PATCH 0167/3340] - patchlevel 438 --- 7.3.438 | 126 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 126 insertions(+) create mode 100644 7.3.438 diff --git a/7.3.438 b/7.3.438 new file mode 100644 index 00000000..94786d7c --- /dev/null +++ b/7.3.438 @@ -0,0 +1,126 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.438 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.438 +Problem: There is no way to avoid ":doautoall" reading modelines. +Solution: Add the argument. Adjust documentation. +Files: src/fileio.c, runtime/doc/autocmd.txt + + +*** ../vim-7.3.437/src/fileio.c 2012-02-11 23:45:30.000000000 +0100 +--- src/fileio.c 2012-02-12 00:08:17.000000000 +0100 +*************** +*** 8739,8744 **** +--- 8739,8752 ---- + int retval; + aco_save_T aco; + buf_T *buf; ++ char_u *arg = eap->arg; ++ int call_do_modelines = TRUE; ++ ++ if (STRNCMP(arg, "", 12) == 0) ++ { ++ call_do_modelines = FALSE; ++ arg = skipwhite(arg + 12); ++ } + + /* + * This is a bit tricky: For some commands curwin->w_buffer needs to be +*************** +*** 8755,8765 **** + aucmd_prepbuf(&aco, buf); + + /* execute the autocommands for this buffer */ +! retval = do_doautocmd(eap->arg, FALSE); + +! /* Execute the modeline settings, but don't set window-local +! * options if we are using the current window for another buffer. */ +! do_modelines(curwin == aucmd_win ? OPT_NOWIN : 0); + + /* restore the current window */ + aucmd_restbuf(&aco); +--- 8763,8777 ---- + aucmd_prepbuf(&aco, buf); + + /* execute the autocommands for this buffer */ +! retval = do_doautocmd(arg, FALSE); + +! if (call_do_modelines) +! { +! /* Execute the modeline settings, but don't set window-local +! * options if we are using the current window for another +! * buffer. */ +! do_modelines(curwin == aucmd_win ? OPT_NOWIN : 0); +! } + + /* restore the current window */ + aucmd_restbuf(&aco); +*** ../vim-7.3.437/runtime/doc/autocmd.txt 2011-05-19 17:25:36.000000000 +0200 +--- runtime/doc/autocmd.txt 2012-02-12 00:03:45.000000000 +0100 +*************** +*** 1065,1077 **** + autocommands for that group. Note: if you use an + undefined group name, Vim gives you an error message. + +- After applying the autocommands the modelines are +- processed, so that their settings overrule the +- settings from autocommands, like what happens when +- editing a file. +- + *:doautoa* *:doautoall* +! :doautoa[ll] [group] {event} [fname] + Like ":doautocmd", but apply the autocommands to each + loaded buffer. Note that [fname] is used to select + the autocommands, not the buffers to which they are +--- 1073,1080 ---- + autocommands for that group. Note: if you use an + undefined group name, Vim gives you an error message. + + *:doautoa* *:doautoall* +! :doautoa[ll] [] [group] {event} [fname] + Like ":doautocmd", but apply the autocommands to each + loaded buffer. Note that [fname] is used to select + the autocommands, not the buffers to which they are +*************** +*** 1082,1087 **** +--- 1085,1096 ---- + This command is intended for autocommands that set + options, change highlighting, and things like that. + ++ After applying the autocommands the modelines are ++ processed, so that their settings overrule the ++ settings from autocommands, like what happens when ++ editing a file. This is skipped when the ++ argument is present. ++ + ============================================================================== + 10. Using autocommands *autocmd-use* + +*** ../vim-7.3.437/src/version.c 2012-02-11 23:45:30.000000000 +0100 +--- src/version.c 2012-02-12 00:16:04.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 438, + /**/ + +-- +"Oh, no! NOT the Spanish Inquisition!" +"NOBODY expects the Spanish Inquisition!!!" + -- Monty Python sketch -- +"Oh, no! NOT another option!" +"EVERYBODY expects another option!!!" + -- Discussion in vim-dev mailing list -- + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From dbb154b0c5d8efbb4e6bb8c6822882cbb471e7ec Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 Feb 2012 12:54:49 +0100 Subject: [PATCH 0168/3340] - patchlevel 439 --- 7.3.439 | 87 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 87 insertions(+) create mode 100644 7.3.439 diff --git a/7.3.439 b/7.3.439 new file mode 100644 index 00000000..63d8f693 --- /dev/null +++ b/7.3.439 @@ -0,0 +1,87 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.439 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.439 +Problem: Compiler warnings to size casts in Perl interface. +Solution: Use XS macros. (James McCoy) +Files: src/if_perl.xs, src/typemap + + +*** ../vim-7.3.438/src/if_perl.xs 2011-09-07 18:47:19.000000000 +0200 +--- src/if_perl.xs 2012-02-12 00:28:52.000000000 +0100 +*************** +*** 611,617 **** + if (ptr->w_perl_private == NULL) + { + ptr->w_perl_private = newSV(0); +! sv_setiv(ptr->w_perl_private, (IV)ptr); + } + else + SvREFCNT_inc(ptr->w_perl_private); +--- 611,617 ---- + if (ptr->w_perl_private == NULL) + { + ptr->w_perl_private = newSV(0); +! sv_setiv(ptr->w_perl_private, PTR2IV(ptr)); + } + else + SvREFCNT_inc(ptr->w_perl_private); +*************** +*** 629,635 **** + if (ptr->b_perl_private == NULL) + { + ptr->b_perl_private = newSV(0); +! sv_setiv(ptr->b_perl_private, (IV)ptr); + } + else + SvREFCNT_inc(ptr->b_perl_private); +--- 629,635 ---- + if (ptr->b_perl_private == NULL) + { + ptr->b_perl_private = newSV(0); +! sv_setiv(ptr->b_perl_private, PTR2IV(ptr)); + } + else + SvREFCNT_inc(ptr->b_perl_private); +*** ../vim-7.3.438/src/typemap 2010-08-15 21:57:29.000000000 +0200 +--- src/typemap 2012-02-12 00:28:52.000000000 +0100 +*************** +*** 6,12 **** + T_VIOBJNOMUNGE + if (sv_isa($arg, \"${ntype}\")) { + IV tmp = SvIV((SV*)SvRV($arg)); +! $var = ($type) tmp; + if (!tmp) + croak(\"$ntype no longer exists\"); + } +--- 6,12 ---- + T_VIOBJNOMUNGE + if (sv_isa($arg, \"${ntype}\")) { + IV tmp = SvIV((SV*)SvRV($arg)); +! $var = INT2PTR($type, tmp); + if (!tmp) + croak(\"$ntype no longer exists\"); + } +*** ../vim-7.3.438/src/version.c 2012-02-12 00:18:54.000000000 +0100 +--- src/version.c 2012-02-12 00:31:18.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 439, + /**/ + +-- +Microsoft is to software what McDonalds is to gourmet cooking + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 37e4ea2e06874d6c7201cd1829ede433a8c01ecb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 Feb 2012 12:54:50 +0100 Subject: [PATCH 0169/3340] - patchlevel 440 --- 7.3.440 | 211 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 211 insertions(+) create mode 100644 7.3.440 diff --git a/7.3.440 b/7.3.440 new file mode 100644 index 00000000..39313b0f --- /dev/null +++ b/7.3.440 @@ -0,0 +1,211 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.440 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.440 +Problem: Vim does not support UTF8_STRING for the X selection. +Solution: Add UTF8_STRING atom support. (Alex Efros) Use it only when + 'encoding' is set to Unicode. +Files: src/ui.c + + +*** ../vim-7.3.439/src/ui.c 2012-02-04 21:57:44.000000000 +0100 +--- src/ui.c 2012-02-12 01:28:30.000000000 +0100 +*************** +*** 1917,1922 **** +--- 1917,1923 ---- + static Atom vim_atom; /* Vim's own special selection format */ + #ifdef FEAT_MBYTE + static Atom vimenc_atom; /* Vim's extended selection format */ ++ static Atom utf8_atom; + #endif + static Atom compound_text_atom; + static Atom text_atom; +*************** +*** 1930,1935 **** +--- 1931,1937 ---- + vim_atom = XInternAtom(dpy, VIM_ATOM_NAME, False); + #ifdef FEAT_MBYTE + vimenc_atom = XInternAtom(dpy, VIMENC_ATOM_NAME,False); ++ utf8_atom = XInternAtom(dpy, "UTF8_STRING", False); + #endif + compound_text_atom = XInternAtom(dpy, "COMPOUND_TEXT", False); + text_atom = XInternAtom(dpy, "TEXT", False); +*************** +*** 2074,2080 **** + } + #endif + +! else if (*type == compound_text_atom || ( + #ifdef FEAT_MBYTE + enc_dbcs != 0 && + #endif +--- 2076,2086 ---- + } + #endif + +! else if (*type == compound_text_atom +! #ifdef FEAT_MBYTE +! || *type == utf8_atom +! #endif +! || ( + #ifdef FEAT_MBYTE + enc_dbcs != 0 && + #endif +*************** +*** 2128,2134 **** + #else + 1 + #endif +! ; i < 5; i++) + { + switch (i) + { +--- 2134,2140 ---- + #else + 1 + #endif +! ; i < 6; i++) + { + switch (i) + { +*************** +*** 2136,2145 **** + case 0: type = vimenc_atom; break; + #endif + case 1: type = vim_atom; break; +! case 2: type = compound_text_atom; break; +! case 3: type = text_atom; break; + default: type = XA_STRING; + } + success = MAYBE; + XtGetSelectionValue(myShell, cbd->sel_atom, type, + clip_x11_request_selection_cb, (XtPointer)&success, CurrentTime); +--- 2142,2159 ---- + case 0: type = vimenc_atom; break; + #endif + case 1: type = vim_atom; break; +! #ifdef FEAT_MBYTE +! case 2: type = utf8_atom; break; +! #endif +! case 3: type = compound_text_atom; break; +! case 4: type = text_atom; break; + default: type = XA_STRING; + } ++ #ifdef FEAT_MBYTE ++ if (type == utf8_atom && !enc_utf8) ++ /* Only request utf-8 when 'encoding' is utf8. */ ++ continue; ++ #endif + success = MAYBE; + XtGetSelectionValue(myShell, cbd->sel_atom, type, + clip_x11_request_selection_cb, (XtPointer)&success, CurrentTime); +*************** +*** 2230,2247 **** + { + Atom *array; + +! if ((array = (Atom *)XtMalloc((unsigned)(sizeof(Atom) * 6))) == NULL) + return False; + *value = (XtPointer)array; + i = 0; +- array[i++] = XA_STRING; + array[i++] = targets_atom; + #ifdef FEAT_MBYTE + array[i++] = vimenc_atom; + #endif + array[i++] = vim_atom; + array[i++] = text_atom; + array[i++] = compound_text_atom; + *type = XA_ATOM; + /* This used to be: *format = sizeof(Atom) * 8; but that caused + * crashes on 64 bit machines. (Peter Derr) */ +--- 2244,2266 ---- + { + Atom *array; + +! if ((array = (Atom *)XtMalloc((unsigned)(sizeof(Atom) * 7))) == NULL) + return False; + *value = (XtPointer)array; + i = 0; + array[i++] = targets_atom; + #ifdef FEAT_MBYTE + array[i++] = vimenc_atom; + #endif + array[i++] = vim_atom; ++ #ifdef FEAT_MBYTE ++ if (enc_utf8) ++ array[i++] = utf8_atom; ++ #endif ++ array[i++] = XA_STRING; + array[i++] = text_atom; + array[i++] = compound_text_atom; ++ + *type = XA_ATOM; + /* This used to be: *format = sizeof(Atom) * 8; but that caused + * crashes on 64 bit machines. (Peter Derr) */ +*************** +*** 2253,2258 **** +--- 2272,2278 ---- + if ( *target != XA_STRING + #ifdef FEAT_MBYTE + && *target != vimenc_atom ++ && *target != utf8_atom + #endif + && *target != vim_atom + && *target != text_atom +*************** +*** 2282,2294 **** + return False; + } + +! if (*target == XA_STRING) + { + mch_memmove(result, string, (size_t)(*length)); +! *type = XA_STRING; + } +! else if (*target == compound_text_atom +! || *target == text_atom) + { + XTextProperty text_prop; + char *string_nt = (char *)alloc((unsigned)*length + 1); +--- 2302,2317 ---- + return False; + } + +! if (*target == XA_STRING +! #ifdef FEAT_MBYTE +! || (*target == utf8_atom && enc_utf8) +! #endif +! ) + { + mch_memmove(result, string, (size_t)(*length)); +! *type = *target; + } +! else if (*target == compound_text_atom || *target == text_atom) + { + XTextProperty text_prop; + char *string_nt = (char *)alloc((unsigned)*length + 1); +*** ../vim-7.3.439/src/version.c 2012-02-12 00:31:47.000000000 +0100 +--- src/version.c 2012-02-12 01:34:22.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 440, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +42. Your virtual girlfriend finds a new net sweetheart with a larger bandwidth. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 92d8bb423697f959e2d19ef41ef1abcf1ffe79e3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 Feb 2012 12:54:50 +0100 Subject: [PATCH 0170/3340] - patchlevel 441 --- 7.3.441 | 341 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 341 insertions(+) create mode 100644 7.3.441 diff --git a/7.3.441 b/7.3.441 new file mode 100644 index 00000000..9a7539b5 --- /dev/null +++ b/7.3.441 @@ -0,0 +1,341 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.441 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.441 +Problem: Newer versions of MzScheme (Racket) require earlier (trampolined) + initialisation. +Solution: Call mzscheme_main() early in main(). (Sergey Khorev) +Files: src/Make_mvc.mak, src/if_mzsch.c, src/main.c, + src/proto/if_mzsch.pro + + +*** ../vim-7.3.440/src/Make_mvc.mak 2011-09-14 19:01:38.000000000 +0200 +--- src/Make_mvc.mak 2012-02-12 01:46:05.000000000 +0100 +*************** +*** 740,745 **** +--- 740,747 ---- + !endif + !endif + MZSCHEME_OBJ = $(OUTDIR)\if_mzsch.obj ++ # increase stack size ++ MZSCHEME_LIB = $(MZSCHEME_LIB) /STACK:8388608 + !endif + + # Perl interface +*** ../vim-7.3.440/src/if_mzsch.c 2010-11-03 21:59:23.000000000 +0100 +--- src/if_mzsch.c 2012-02-12 01:47:31.000000000 +0100 +*************** +*** 31,38 **** + * depend". */ + #if defined(FEAT_MZSCHEME) || defined(PROTO) + +- #include +- + /* Base data structures */ + #define SCHEME_VIMBUFFERP(obj) SAME_TYPE(SCHEME_TYPE(obj), mz_buffer_type) + #define SCHEME_VIMWINDOWP(obj) SAME_TYPE(SCHEME_TYPE(obj), mz_window_type) +--- 31,36 ---- +*************** +*** 559,575 **** + hMzSch = vimLoadLib(sch_dll); + hMzGC = vimLoadLib(gc_dll); + +! if (!hMzSch) + { + if (verbose) +! EMSG2(_(e_loadlib), sch_dll); + return FAIL; + } + +! if (!hMzGC) + { + if (verbose) +! EMSG2(_(e_loadlib), gc_dll); + return FAIL; + } + +--- 557,573 ---- + hMzSch = vimLoadLib(sch_dll); + hMzGC = vimLoadLib(gc_dll); + +! if (!hMzGC) + { + if (verbose) +! EMSG2(_(e_loadlib), gc_dll); + return FAIL; + } + +! if (!hMzSch) + { + if (verbose) +! EMSG2(_(e_loadlib), sch_dll); + return FAIL; + } + +*************** +*** 798,862 **** + static __declspec(thread) void *tls_space; + #endif + +! void +! mzscheme_main(void) + { + #if MZSCHEME_VERSION_MAJOR >= 500 && defined(WIN32) && defined(USE_THREAD_LOCAL) + scheme_register_tls_space(&tls_space, 0); + #endif +! #if defined(MZ_PRECISE_GC) && MZSCHEME_VERSION_MAJOR >= 400 +! /* use trampoline for precise GC in MzScheme >= 4.x */ +! scheme_main_setup(TRUE, mzscheme_env_main, 0, NULL); + #else +! mzscheme_env_main(NULL, 0, NULL); + #endif + } + + static int +! mzscheme_env_main(Scheme_Env *env, int argc UNUSED, char **argv UNUSED) + { +! /* neither argument nor return values are used */ +! #ifdef MZ_PRECISE_GC +! # if MZSCHEME_VERSION_MAJOR < 400 +! /* +! * Starting from version 4.x, embedding applications must use +! * scheme_main_setup/scheme_main_stack_setup trampolines +! * rather than setting stack base directly with scheme_set_stack_base +! */ + Scheme_Object *dummy = NULL; + MZ_GC_DECL_REG(1); + MZ_GC_VAR_IN_REG(0, dummy); + + stack_base = &__gc_var_stack__; + # else +- /* environment has been created by us by Scheme */ +- environment = env; +- # endif +- /* +- * In 4.x, all activities must be performed inside trampoline +- * so we are forced to initialise GC immediately +- * This can be postponed in 3.x but I see no point in implementing +- * a feature which will work in older versions only. +- * One would better use conservative GC if he needs dynamic MzScheme +- */ +- mzscheme_init(); +- #else + int dummy = 0; + stack_base = (void *)&dummy; + #endif +! main_loop(FALSE, FALSE); +! #if defined(MZ_PRECISE_GC) && MZSCHEME_VERSION_MAJOR < 400 + /* releasing dummy */ + MZ_GC_REG(); + MZ_GC_UNREG(); + #endif +! return 0; + } + + static void + startup_mzscheme(void) + { +! #if !defined(MZ_PRECISE_GC) || MZSCHEME_VERSION_MAJOR < 400 + scheme_set_stack_base(stack_base, 1); + #endif + +--- 796,863 ---- + static __declspec(thread) void *tls_space; + #endif + +! /* +! * Since version 4.x precise GC requires trampolined startup. +! * Futures and places in version 5.x need it too. +! */ +! #if defined(MZ_PRECISE_GC) && MZSCHEME_VERSION_MAJOR >= 400 \ +! || MZSCHEME_VERSION_MAJOR >= 500 && (defined(MZ_USE_FUTURES) || defined(MZ_USE_PLACES)) +! # ifdef DYNAMIC_MZSCHEME +! # error Precise GC v.4+ or Racket with futures/places do not support dynamic MzScheme +! # endif +! # define TRAMPOLINED_MZVIM_STARTUP +! #endif +! +! int +! mzscheme_main(int argc, char** argv) + { + #if MZSCHEME_VERSION_MAJOR >= 500 && defined(WIN32) && defined(USE_THREAD_LOCAL) + scheme_register_tls_space(&tls_space, 0); + #endif +! #ifdef TRAMPOLINED_MZVIM_STARTUP +! return scheme_main_setup(TRUE, mzscheme_env_main, argc, argv); + #else +! return mzscheme_env_main(NULL, argc, argv); + #endif + } + + static int +! mzscheme_env_main(Scheme_Env *env, int argc, char **argv) + { +! int vim_main_result; +! #ifdef TRAMPOLINED_MZVIM_STARTUP +! /* Scheme has created the environment for us */ +! environment = env; +! #else +! # ifdef MZ_PRECISE_GC + Scheme_Object *dummy = NULL; + MZ_GC_DECL_REG(1); + MZ_GC_VAR_IN_REG(0, dummy); + + stack_base = &__gc_var_stack__; + # else + int dummy = 0; + stack_base = (void *)&dummy; ++ # endif + #endif +! +! /* mzscheme_main is called as a trampoline from main. +! * We trampoline into vim_main2 +! * Passing argc, argv through from mzscheme_main +! */ +! vim_main_result = vim_main2(argc, argv); +! #if !defined(TRAMPOLINED_MZVIM_STARTUP) && defined(MZ_PRECISE_GC) + /* releasing dummy */ + MZ_GC_REG(); + MZ_GC_UNREG(); + #endif +! return vim_main_result; + } + + static void + startup_mzscheme(void) + { +! #ifndef TRAMPOLINED_MZVIM_STARTUP + scheme_set_stack_base(stack_base, 1); + #endif + +*************** +*** 868,874 **** + MZ_REGISTER_STATIC(exn_message); + MZ_REGISTER_STATIC(vim_exn); + +! #if !defined(MZ_PRECISE_GC) || MZSCHEME_VERSION_MAJOR < 400 + /* in newer versions of precise GC the initial env has been created */ + environment = scheme_basic_env(); + #endif +--- 869,875 ---- + MZ_REGISTER_STATIC(exn_message); + MZ_REGISTER_STATIC(vim_exn); + +! #ifndef TRAMPOLINED_MZVIM_STARTUP + /* in newer versions of precise GC the initial env has been created */ + environment = scheme_basic_env(); + #endif +*************** +*** 3013,3019 **** + MZ_GC_REG(); + + tmp = scheme_make_struct_names(exn_name, scheme_null, 0, &nc); +- assert(nc <= 5); + mch_memmove(exn_names, tmp, nc * sizeof(Scheme_Object *)); + MZ_GC_CHECK(); + +--- 3014,3019 ---- +*** ../vim-7.3.440/src/main.c 2011-12-08 15:57:54.000000000 +0100 +--- src/main.c 2012-02-12 01:49:50.000000000 +0100 +*************** +*** 554,559 **** +--- 554,584 ---- + debug_break_level = params.use_debug_break_level; + #endif + ++ #ifdef FEAT_MZSCHEME ++ /* ++ * Newer version of MzScheme (Racket) require earlier (trampolined) ++ * initialisation via scheme_main_setup. ++ * Implement this by initialising it as early as possible ++ * and splitting off remaining Vim main into vim_main2 ++ */ ++ { ++ /* Pack up preprocessed command line arguments. ++ * It is safe because Scheme does not access argc/argv. */ ++ char *args[2]; ++ args[0] = (char *)fname; ++ args[1] = (char *)¶ms; ++ return mzscheme_main(2, args); ++ } ++ } ++ ++ int vim_main2(int argc, char **argv) ++ { ++ char_u *fname = (char_u *)argv[0]; ++ mparm_T params; ++ ++ memcpy(¶ms, argv[1], sizeof(params)); ++ #endif ++ + /* Execute --cmd arguments. */ + exe_pre_commands(¶ms); + +*************** +*** 957,970 **** + + /* + * Call the main command loop. This never returns. +! * For embedded MzScheme the main_loop will be called by Scheme +! * for proper stack tracking +! */ +! #ifndef FEAT_MZSCHEME + main_loop(FALSE, FALSE); +- #else +- mzscheme_main(); +- #endif + + return 0; + } +--- 982,989 ---- + + /* + * Call the main command loop. This never returns. +! */ + main_loop(FALSE, FALSE); + + return 0; + } +*** ../vim-7.3.440/src/proto/if_mzsch.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/if_mzsch.pro 2012-02-12 01:50:57.000000000 +0100 +*************** +*** 14,19 **** + void mzvim_reset_timer __ARGS((void)); + void *mzvim_eval_string __ARGS((char_u *str)); + int mzthreads_allowed __ARGS((void)); +! void mzscheme_main __ARGS((void)); + void do_mzeval __ARGS((char_u *str, typval_T *rettv)); + /* vim: set ft=c : */ +--- 14,20 ---- + void mzvim_reset_timer __ARGS((void)); + void *mzvim_eval_string __ARGS((char_u *str)); + int mzthreads_allowed __ARGS((void)); +! int mzscheme_main __ARGS((int argc, char **argv)); + void do_mzeval __ARGS((char_u *str, typval_T *rettv)); ++ int vim_main2 __ARGS((int argc, char **argv)); + /* vim: set ft=c : */ +*** ../vim-7.3.440/src/version.c 2012-02-12 01:35:06.000000000 +0100 +--- src/version.c 2012-02-12 01:54:14.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 441, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +43. You tell the kids they can't use the computer because "Daddy's got work to + do" and you don't even have a job. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4f31f789e44c144230673948dbc5778264991e54 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 Feb 2012 12:54:50 +0100 Subject: [PATCH 0171/3340] - patchlevel 442 --- 7.3.442 | 186 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 186 insertions(+) create mode 100644 7.3.442 diff --git a/7.3.442 b/7.3.442 new file mode 100644 index 00000000..58b58b4e --- /dev/null +++ b/7.3.442 @@ -0,0 +1,186 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.442 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.442 (after 7.3.438) +Problem: Still read modelines for ":doautocmd". +Solution: Move check for to separate function. +Files: src/fileio.c, src/ex_docmd.c, src/proto/fileio.pro, + runtime/doc/autocmd.txt + + +*** ../vim-7.3.441/src/fileio.c 2012-02-12 00:18:54.000000000 +0100 +--- src/fileio.c 2012-02-12 20:05:35.000000000 +0100 +*************** +*** 8740,8752 **** + aco_save_T aco; + buf_T *buf; + char_u *arg = eap->arg; +! int call_do_modelines = TRUE; +! +! if (STRNCMP(arg, "", 12) == 0) +! { +! call_do_modelines = FALSE; +! arg = skipwhite(arg + 12); +! } + + /* + * This is a bit tricky: For some commands curwin->w_buffer needs to be +--- 8740,8746 ---- + aco_save_T aco; + buf_T *buf; + char_u *arg = eap->arg; +! int call_do_modelines = check_nomodeline(&arg); + + /* + * This is a bit tricky: For some commands curwin->w_buffer needs to be +*************** +*** 8786,8791 **** +--- 8780,8802 ---- + } + + /* ++ * Check *argp for . When it is present return FALSE, otherwise ++ * return TRUE and advance *argp to after it. ++ * Thus return TRUE when do_modelines() should be called. ++ */ ++ int ++ check_nomodeline(argp) ++ char_u **argp; ++ { ++ if (STRNCMP(*argp, "", 12) == 0) ++ { ++ *argp = skipwhite(*argp + 12); ++ return FALSE; ++ } ++ return TRUE; ++ } ++ ++ /* + * Prepare for executing autocommands for (hidden) buffer "buf". + * Search for a visible window containing the current buffer. If there isn't + * one then use "aucmd_win". +*** ../vim-7.3.441/src/ex_docmd.c 2012-01-26 20:41:22.000000000 +0100 +--- src/ex_docmd.c 2012-02-12 20:05:18.000000000 +0100 +*************** +*** 4955,4961 **** + map_clear(eap->cmd, eap->arg, TRUE, TRUE); + } + +! #ifdef FEAT_AUTOCMD + static void + ex_autocmd(eap) + exarg_T *eap; +--- 4955,4961 ---- + map_clear(eap->cmd, eap->arg, TRUE, TRUE); + } + +! #if defined(FEAT_AUTOCMD) || defined(PROTO) + static void + ex_autocmd(eap) + exarg_T *eap; +*************** +*** 4982,4989 **** + ex_doautocmd(eap) + exarg_T *eap; + { +! (void)do_doautocmd(eap->arg, TRUE); +! do_modelines(0); + } + #endif + +--- 4982,4993 ---- + ex_doautocmd(eap) + exarg_T *eap; + { +! char_u *arg = eap->arg; +! int call_do_modelines = check_nomodeline(&arg); +! +! (void)do_doautocmd(arg, TRUE); +! if (call_do_modelines) /* Only when there is no . */ +! do_modelines(0); + } + #endif + +*** ../vim-7.3.441/src/proto/fileio.pro 2010-12-17 16:27:10.000000000 +0100 +--- src/proto/fileio.pro 2012-02-12 20:05:26.000000000 +0100 +*************** +*** 35,40 **** +--- 35,41 ---- + void do_autocmd __ARGS((char_u *arg, int forceit)); + int do_doautocmd __ARGS((char_u *arg, int do_msg)); + void ex_doautoall __ARGS((exarg_T *eap)); ++ int check_nomodeline __ARGS((char_u **argp)); + void aucmd_prepbuf __ARGS((aco_save_T *aco, buf_T *buf)); + void aucmd_restbuf __ARGS((aco_save_T *aco)); + int apply_autocmds __ARGS((event_T event, char_u *fname, char_u *fname_io, int force, buf_T *buf)); +*** ../vim-7.3.441/runtime/doc/autocmd.txt 2012-02-12 00:18:54.000000000 +0100 +--- runtime/doc/autocmd.txt 2012-02-12 20:11:05.000000000 +0100 +*************** +*** 1064,1069 **** +--- 1072,1085 ---- + argument is included, Vim executes only the matching + autocommands for that group. Note: if you use an + undefined group name, Vim gives you an error message. ++ ** ++ After applying the autocommands the modelines are ++ processed, so that their settings overrule the ++ settings from autocommands, like what happens when ++ editing a file. This is skipped when the ++ argument is present. You probably want to use ++ for events that are not used when loading ++ a buffer, such as |User|. + + *:doautoa* *:doautoall* + :doautoa[ll] [] [group] {event} [fname] +*************** +*** 1077,1088 **** + This command is intended for autocommands that set + options, change highlighting, and things like that. + +- After applying the autocommands the modelines are +- processed, so that their settings overrule the +- settings from autocommands, like what happens when +- editing a file. This is skipped when the +- argument is present. +- + ============================================================================== + 10. Using autocommands *autocmd-use* + +--- 1093,1098 ---- +*** ../vim-7.3.441/src/version.c 2012-02-12 01:55:50.000000000 +0100 +--- src/version.c 2012-02-12 20:11:34.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 442, + /**/ + +-- +The real +trick is +this: to +keep the +lines as +short as +possible +and keep +the size +the same +yet free +from the +need for +hyphena- +Dammit!! (Matthew Winn) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a63318b76778c50480894e66374067bdebe8e067 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 Feb 2012 12:54:51 +0100 Subject: [PATCH 0172/3340] - patchlevel 443 --- 7.3.443 | 206 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 206 insertions(+) create mode 100644 7.3.443 diff --git a/7.3.443 b/7.3.443 new file mode 100644 index 00000000..84b45baa --- /dev/null +++ b/7.3.443 @@ -0,0 +1,206 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.443 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.443 +Problem: MS-Windows: 'shcf' and 'shellxquote' defaults are not very good. +Solution: Make a better guess when 'shell' is set to "cmd.exe". (Ben Fritz) +Files: src/option.c, runtime/doc/options.txt + + +*** ../vim-7.3.442/src/option.c 2012-01-28 18:03:30.000000000 +0100 +--- src/option.c 2012-02-12 23:17:55.000000000 +0100 +*************** +*** 3883,3889 **** + + #if defined(MSDOS) || defined(WIN3264) || defined(OS2) + /* +! * Set 'shellcmdflag and 'shellquote' depending on the 'shell' option. + * This is done after other initializations, where 'shell' might have been + * set, but only if they have not been set before. Default for p_shcf is + * "/c", for p_shq is "". For "sh" like shells it is changed here to +--- 3883,3890 ---- + + #if defined(MSDOS) || defined(WIN3264) || defined(OS2) + /* +! * Set 'shellcmdflag', 'shellxquote', and 'shellquote' depending on the +! * 'shell' option. + * This is done after other initializations, where 'shell' might have been + * set, but only if they have not been set before. Default for p_shcf is + * "/c", for p_shq is "". For "sh" like shells it is changed here to +*************** +*** 3920,3925 **** +--- 3921,3962 ---- + # endif + # endif + } ++ else if (strstr((char *)gettail(p_sh), "cmd.exe") != NULL) ++ { ++ int idx3; ++ ++ /* ++ * cmd.exe on Windows will strip the first and last double quote given ++ * on the command line, e.g. most of the time things like: ++ * cmd /c "my path/to/echo" "my args to echo" ++ * become: ++ * my path/to/echo" "my args to echo ++ * when executed. ++ * ++ * To avoid this, use the /s argument in addition to /c to force the ++ * stripping behavior, and also set shellxquote to automatically ++ * surround the entire command in quotes (which get stripped as ++ * noted). ++ */ ++ ++ /* Set shellxquote default to add the quotes to be stripped. */ ++ idx3 = findoption((char_u *)"sxq"); ++ if (idx3 >= 0 && !(options[idx3].flags & P_WAS_SET)) ++ { ++ p_sxq = (char_u *)"\""; ++ options[idx3].def_val[VI_DEFAULT] = p_sxq; ++ } ++ ++ /* Set shellcmdflag default to always strip the quotes, note the order ++ * between /s and /c is important or cmd.exe will treat the /s as part ++ * of the command to be executed. */ ++ idx3 = findoption((char_u *)"shcf"); ++ if (idx3 >= 0 && !(options[idx3].flags & P_WAS_SET)) ++ { ++ p_shcf = (char_u *)"/s /c"; ++ options[idx3].def_val[VI_DEFAULT] = p_shcf; ++ } ++ } + #endif + + #ifdef FEAT_TITLE +*** ../vim-7.3.442/runtime/doc/options.txt 2011-06-26 05:36:07.000000000 +0200 +--- runtime/doc/options.txt 2012-02-12 23:21:59.000000000 +0100 +*************** +*** 5880,5895 **** + security reasons. + + *'shellcmdflag'* *'shcf'* +! 'shellcmdflag' 'shcf' string (default: "-c", MS-DOS and Win32, when 'shell' +! does not contain "sh" somewhere: "/c") + global + {not in Vi} + Flag passed to the shell to execute "!" and ":!" commands; e.g., + "bash.exe -c ls" or "command.com /c dir". For the MS-DOS-like + systems, the default is set according to the value of 'shell', to + reduce the need to set this option by the user. It's not used for +! OS/2 (EMX figures this out itself). See |option-backslash| about +! including spaces and backslashes. See |dos-shell|. + This option cannot be set from a |modeline| or in the |sandbox|, for + security reasons. + +--- 5899,5919 ---- + security reasons. + + *'shellcmdflag'* *'shcf'* +! 'shellcmdflag' 'shcf' string (default: "-c"; +! Win32, when 'shell' is cmd.exe: "/s /c"; +! MS-DOS and Win32, when 'shell' neither is +! cmd.exe nor contains "sh" somewhere: "/c") + global + {not in Vi} + Flag passed to the shell to execute "!" and ":!" commands; e.g., + "bash.exe -c ls" or "command.com /c dir". For the MS-DOS-like + systems, the default is set according to the value of 'shell', to + reduce the need to set this option by the user. It's not used for +! OS/2 (EMX figures this out itself). +! On Unix it can have more than one flag. Each white space separated +! part is passed as an argument to the shell command. +! See |option-backslash| about including spaces and backslashes. +! Also see |dos-shell| for MS-DOS and MS-Windows. + This option cannot be set from a |modeline| or in the |sandbox|, for + security reasons. + +*************** +*** 5910,5918 **** + For Unix the default it "| tee". The stdout of the compiler is saved + in a file and echoed to the screen. If the 'shell' option is "csh" or + "tcsh" after initializations, the default becomes "|& tee". If the +! 'shell' option is "sh", "ksh", "zsh" or "bash" the default becomes +! "2>&1| tee". This means that stderr is also included. Before using +! the 'shell' option a path is removed, thus "/bin/sh" uses "sh". + The initialization of this option is done after reading the ".vimrc" + and the other initializations, so that when the 'shell' option is set + there, the 'shellpipe' option changes automatically, unless it was +--- 5934,5943 ---- + For Unix the default it "| tee". The stdout of the compiler is saved + in a file and echoed to the screen. If the 'shell' option is "csh" or + "tcsh" after initializations, the default becomes "|& tee". If the +! 'shell' option is "sh", "ksh", "mksh", "pdksh", "zsh" or "bash" the +! default becomes "2>&1| tee". This means that stderr is also included. +! Before using the 'shell' option a path is removed, thus "/bin/sh" uses +! "sh". + The initialization of this option is done after reading the ".vimrc" + and the other initializations, so that when the 'shell' option is set + there, the 'shellpipe' option changes automatically, unless it was +*************** +*** 6017,6024 **** + + *'shellxquote'* *'sxq'* + 'shellxquote' 'sxq' string (default: ""; +! for Win32, when 'shell' contains "sh" +! somewhere: "\"" + for Unix, when using system(): "\"") + global + {not in Vi} +--- 6043,6050 ---- + + *'shellxquote'* *'sxq'* + 'shellxquote' 'sxq' string (default: ""; +! for Win32, when 'shell' is cmd.exe or +! contains "sh" somewhere: "\"" + for Unix, when using system(): "\"") + global + {not in Vi} +*************** +*** 6026,6036 **** + the "!" and ":!" commands. Includes the redirection. See + 'shellquote' to exclude the redirection. It's probably not useful + to set both options. +! This is an empty string by default. Known to be useful for +! third-party shells when using the Win32 version, such as the MKS Korn +! Shell or bash, where it should be "\"". The default is adjusted +! according the value of 'shell', to reduce the need to set this option +! by the user. See |dos-shell|. + This option cannot be set from a |modeline| or in the |sandbox|, for + security reasons. + +--- 6052,6063 ---- + the "!" and ":!" commands. Includes the redirection. See + 'shellquote' to exclude the redirection. It's probably not useful + to set both options. +! This is an empty string by default on most systems, but is known to be +! useful for on Win32 version, either for cmd.exe which automatically +! strips off the first and last quote on a command, or 3rd-party shells +! such as the MKS Korn Shell or bash, where it should be "\"". The +! default is adjusted according the value of 'shell', to reduce the need +! to set this option by the user. See |dos-shell|. + This option cannot be set from a |modeline| or in the |sandbox|, for + security reasons. + +*** ../vim-7.3.442/src/version.c 2012-02-12 20:13:55.000000000 +0100 +--- src/version.c 2012-02-12 23:18:40.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 443, + /**/ + +-- +CVS sux, men don't like commitment + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 170224db27393fa61f779dfd30a3decada1aa6b8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 Feb 2012 12:54:51 +0100 Subject: [PATCH 0173/3340] - patchlevel 444 --- 7.3.444 | 96 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 96 insertions(+) create mode 100644 7.3.444 diff --git a/7.3.444 b/7.3.444 new file mode 100644 index 00000000..64ed88bf --- /dev/null +++ b/7.3.444 @@ -0,0 +1,96 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.444 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.444 +Problem: ":all!" and ":sall!" give error E477, even though the + documentation says these are valid commands. +Solution: Support the exclamation mark. (Hirohito Higashi) +Files: src/ex_cmds.h, src/testdir/test31.in, src/testdir/test31.ok + + +*** ../vim-7.3.443/src/ex_cmds.h 2011-06-20 05:02:53.000000000 +0200 +--- src/ex_cmds.h 2012-02-12 23:53:31.000000000 +0100 +*************** +*** 102,108 **** + EX(CMD_aboveleft, "aboveleft", ex_wrongmodifier, + NEEDARG|EXTRA|NOTRLCOM), + EX(CMD_all, "all", ex_all, +! RANGE|NOTADR|COUNT|TRLBAR), + EX(CMD_amenu, "amenu", ex_menu, + RANGE|NOTADR|ZEROR|EXTRA|TRLBAR|NOTRLCOM|USECTRLV|CMDWIN), + EX(CMD_anoremenu, "anoremenu", ex_menu, +--- 102,108 ---- + EX(CMD_aboveleft, "aboveleft", ex_wrongmodifier, + NEEDARG|EXTRA|NOTRLCOM), + EX(CMD_all, "all", ex_all, +! BANG|RANGE|NOTADR|COUNT|TRLBAR), + EX(CMD_amenu, "amenu", ex_menu, + RANGE|NOTADR|ZEROR|EXTRA|TRLBAR|NOTRLCOM|USECTRLV|CMDWIN), + EX(CMD_anoremenu, "anoremenu", ex_menu, +*************** +*** 798,804 **** + EX(CMD_sargument, "sargument", ex_argument, + BANG|RANGE|NOTADR|COUNT|EXTRA|EDITCMD|ARGOPT|TRLBAR), + EX(CMD_sall, "sall", ex_all, +! RANGE|NOTADR|COUNT|TRLBAR), + EX(CMD_sandbox, "sandbox", ex_wrongmodifier, + NEEDARG|EXTRA|NOTRLCOM), + EX(CMD_saveas, "saveas", ex_write, +--- 798,804 ---- + EX(CMD_sargument, "sargument", ex_argument, + BANG|RANGE|NOTADR|COUNT|EXTRA|EDITCMD|ARGOPT|TRLBAR), + EX(CMD_sall, "sall", ex_all, +! BANG|RANGE|NOTADR|COUNT|TRLBAR), + EX(CMD_sandbox, "sandbox", ex_wrongmodifier, + NEEDARG|EXTRA|NOTRLCOM), + EX(CMD_saveas, "saveas", ex_write, +*** ../vim-7.3.443/src/testdir/test31.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test31.in 2012-02-12 23:57:42.000000000 +0100 +*************** +*** 63,68 **** +--- 63,74 ---- + :" write "testtext 1" + A 3:close! + :w >>test.out ++ :set nohidden ++ :" test ":all!" hides changed buffer; write "testtext 2 2 2" ++ :sp Xtest4 ++ GA 4:all! ++ :1wincmd w ++ :w >>test.out + :qa! + ENDTEST + +*** ../vim-7.3.443/src/testdir/test31.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test31.ok 2012-02-13 00:00:13.000000000 +0100 +*************** +*** 9,11 **** +--- 9,12 ---- + testtext 1 + testtext 3 3 3 + testtext 1 ++ testtext 2 2 2 +*** ../vim-7.3.443/src/version.c 2012-02-12 23:23:25.000000000 +0100 +--- src/version.c 2012-02-12 23:52:47.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 444, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +50. The last girl you picked up was only a jpeg. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From dc868b4304ab0cc289e12a50d5132b5dc8529f31 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 Feb 2012 12:54:53 +0100 Subject: [PATCH 0174/3340] - patchlevel 444 --- README.patches | 12 +++++++++++- vim.spec | 25 ++++++++++++++++++++++++- 2 files changed, 35 insertions(+), 2 deletions(-) diff --git a/README.patches b/README.patches index 3f4196f2..39d64247 100644 --- a/README.patches +++ b/README.patches @@ -457,7 +457,7 @@ Individual patches for Vim 7.3: 2210 7.3.424 Win16 version missing some functions 2572 7.3.425 (after 7.3.265) search history lines are duplicated 8345 7.3.426 with '$' in 'cpoptions' $ is not displayed in the first column - 10744 7.3.427 readfile() can be slow with long lines + 10278 7.3.427 readfile() can be slow with long lines 2881 7.3.428 Win32: an xpm file without a mask crashes Vim 5441 7.3.429 with 'E' in 'cpoptions' redo wrong after "c0" in first column 2949 7.3.430 conf filetype detection may end up in the wrong augroup @@ -465,3 +465,13 @@ Individual patches for Vim 7.3: 6926 7.3.432 ACLs are not supported for ZFS or NFSv4 on Solaris 2538 7.3.433 using continued lines in a Vim script can be slow 6194 7.3.434 using join() can be slow + 1864 7.3.435 compiler warning for unused variable + 3128 7.3.436 compiler warnings for types on Windows + 2282 7.3.437 looping inside FOR_ALL_TAB_WINDOWS even when already done + 4305 7.3.438 there is no way to avoid ":doautoall" reading modelines + 2487 7.3.439 compiler warnings to size casts in Perl interface + 5664 7.3.440 Vim does not support UTF8_STRING for the X selection + 9578 7.3.441 newer versions of MzScheme require earlier initialisation + 5445 7.3.442 (after 7.3.438) still read modelines for ":doautocmd" + 8329 7.3.443 MS-Windows: 'shcf' and 'sxq' defaults are not very good + 3159 7.3.444 ":all!" and ":sall!" give error E477 diff --git a/vim.spec b/vim.spec index eb7c5675..0ef1f82c 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 434 +%define patchlevel 444 Summary: The VIM editor URL: http://www.vim.org/ @@ -490,6 +490,16 @@ Patch431: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.431 Patch432: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.432 Patch433: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.433 Patch434: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.434 +Patch435: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.435 +Patch436: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.436 +Patch437: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.437 +Patch438: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.438 +Patch439: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.439 +Patch440: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.440 +Patch441: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.441 +Patch442: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.442 +Patch443: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.443 +Patch444: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.444 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1069,6 +1079,16 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch432 -p0 %patch433 -p0 %patch434 -p0 +%patch435 -p0 +%patch436 -p0 +%patch437 -p0 +%patch438 -p0 +%patch439 -p0 +%patch440 -p0 +%patch441 -p0 +%patch442 -p0 +%patch443 -p0 +%patch444 -p0 # install spell files @@ -1523,6 +1543,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Feb 13 2012 Karsten Hopp 7.3.444-1 +- patchlevel 444 + * Tue Feb 07 2012 Karsten Hopp 7.3.434-1 - patchlevel 434 From e97cbc3962619924aa85573dca8d078d8b8744d9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:45 +0100 Subject: [PATCH 0175/3340] - patchlevel 445 --- 7.3.445 | 199 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 199 insertions(+) create mode 100644 7.3.445 diff --git a/7.3.445 b/7.3.445 new file mode 100644 index 00000000..8d7c337b --- /dev/null +++ b/7.3.445 @@ -0,0 +1,199 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.445 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.445 (after 7.3.443) +Problem: Can't properly escape commands for cmd.exe. +Solution: Default 'shellxquote' to '('. Append ')' to make '(command)'. + No need to use "/s" for 'shellcmdflag'. +Files: src/misc2.c, src/option.c, src/os_win32.c + + +*** ../vim-7.3.444/src/misc2.c 2012-01-20 17:15:47.000000000 +0100 +--- src/misc2.c 2012-02-16 05:34:37.000000000 +0100 +*************** +*** 3230,3236 **** + { + STRCPY(ncmd, p_sxq); + STRCAT(ncmd, cmd); +! STRCAT(ncmd, p_sxq); + retval = mch_call_shell(ncmd, opt); + vim_free(ncmd); + } +--- 3230,3240 ---- + { + STRCPY(ncmd, p_sxq); + STRCAT(ncmd, cmd); +! /* When 'shellxquote' is ( append ). +! * When 'shellxquote' is "( append )". */ +! STRCAT(ncmd, STRCMP(p_sxq, "(") == 0 ? (char_u *)")" +! : STRCMP(p_sxq, "\"(") == 0 ? (char_u *)")\"" +! : p_sxq); + retval = mch_call_shell(ncmd, opt); + vim_free(ncmd); + } +*** ../vim-7.3.444/src/option.c 2012-02-12 23:23:25.000000000 +0100 +--- src/option.c 2012-02-19 18:08:48.000000000 +0100 +*************** +*** 3933,3959 **** + * my path/to/echo" "my args to echo + * when executed. + * +! * To avoid this, use the /s argument in addition to /c to force the +! * stripping behavior, and also set shellxquote to automatically +! * surround the entire command in quotes (which get stripped as +! * noted). + */ +- +- /* Set shellxquote default to add the quotes to be stripped. */ + idx3 = findoption((char_u *)"sxq"); + if (idx3 >= 0 && !(options[idx3].flags & P_WAS_SET)) + { +! p_sxq = (char_u *)"\""; + options[idx3].def_val[VI_DEFAULT] = p_sxq; + } + +- /* Set shellcmdflag default to always strip the quotes, note the order +- * between /s and /c is important or cmd.exe will treat the /s as part +- * of the command to be executed. */ + idx3 = findoption((char_u *)"shcf"); + if (idx3 >= 0 && !(options[idx3].flags & P_WAS_SET)) + { +! p_shcf = (char_u *)"/s /c"; + options[idx3].def_val[VI_DEFAULT] = p_shcf; + } + } +--- 3933,3954 ---- + * my path/to/echo" "my args to echo + * when executed. + * +! * To avoid this, set shellxquote to surround the command in +! * parenthesis. This appears to make most commands work, without +! * breaking commands that worked previously, such as +! * '"path with spaces/cmd" "a&b"'. + */ + idx3 = findoption((char_u *)"sxq"); + if (idx3 >= 0 && !(options[idx3].flags & P_WAS_SET)) + { +! p_sxq = (char_u *)"("; + options[idx3].def_val[VI_DEFAULT] = p_sxq; + } + + idx3 = findoption((char_u *)"shcf"); + if (idx3 >= 0 && !(options[idx3].flags & P_WAS_SET)) + { +! p_shcf = (char_u *)"/c"; + options[idx3].def_val[VI_DEFAULT] = p_shcf; + } + } +*** ../vim-7.3.444/src/os_win32.c 2011-08-27 15:10:00.000000000 +0200 +--- src/os_win32.c 2012-02-19 18:11:23.000000000 +0100 +*************** +*** 3908,3915 **** + newcmd = lalloc(cmdlen, TRUE); + if (newcmd != NULL) + { +! char_u *cmdbase = (*cmd == '"' ? cmd + 1 : cmd); + + if ((STRNICMP(cmdbase, "start", 5) == 0) && vim_iswhite(cmdbase[5])) + { + STARTUPINFO si; +--- 3908,3920 ---- + newcmd = lalloc(cmdlen, TRUE); + if (newcmd != NULL) + { +! char_u *cmdbase = cmd; + ++ /* Skip a leading ", ( and "(. */ ++ if (*cmdbase == '"' ) ++ ++cmdbase; ++ if (*cmdbase == '(') ++ ++cmdbase; + if ((STRNICMP(cmdbase, "start", 5) == 0) && vim_iswhite(cmdbase[5])) + { + STARTUPINFO si; +*************** +*** 3953,3968 **** + * empty, keep the double quotes around the command. + * Otherwise remove the double quotes, they aren't needed + * here, because we don't use a shell to run the command. */ +! if (*cmd == '"' && *p_sxq == NUL) + { +! newcmd[0] = '"'; +! STRCPY(newcmd + 1, cmdbase); +! } +! else +! { +! STRCPY(newcmd, cmdbase); +! if (*cmd == '"' && *newcmd != NUL) +! newcmd[STRLEN(newcmd) - 1] = NUL; + } + + /* +--- 3958,3983 ---- + * empty, keep the double quotes around the command. + * Otherwise remove the double quotes, they aren't needed + * here, because we don't use a shell to run the command. */ +! if (cmdbase > cmd) + { +! if (STRNCMP(cmd, p_sxq, cmd - cmdbase) != 0) +! { +! STRCPY(newcmd, cmd); +! } +! else +! { +! char_u *p; +! +! STRCPY(newcmd, cmdbase); +! /* Remove a trailing ", ) and )" if they have a match +! * at the start of the command. */ +! p = newcmd + STRLEN(newcmd); +! if (p > newcmd && p[-1] == '"' && *cmd == '"') +! *--p = NUL; +! if (p > newcmd && p[-1] == ')' +! && (*cmd =='(' || cmd[1] == '(')) +! *--p = NUL; +! } + } + + /* +*************** +*** 3970,3976 **** + * inherit our handles which causes unpleasant dangling swap + * files if we exit before the spawned process + */ +! if (CreateProcess (NULL, // Executable name + newcmd, // Command to execute + NULL, // Process security attributes + NULL, // Thread security attributes +--- 3985,3991 ---- + * inherit our handles which causes unpleasant dangling swap + * files if we exit before the spawned process + */ +! if (CreateProcess(NULL, // Executable name + newcmd, // Command to execute + NULL, // Process security attributes + NULL, // Thread security attributes +*** ../vim-7.3.444/src/version.c 2012-02-13 00:01:38.000000000 +0100 +--- src/version.c 2012-02-19 18:01:46.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 445, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +80. At parties, you introduce your spouse as your "service provider." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 24e118b985d9e13bc7499bad08e4c6d3bd407e4a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:45 +0100 Subject: [PATCH 0176/3340] - patchlevel 446 --- 7.3.446 | 164 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 164 insertions(+) create mode 100644 7.3.446 diff --git a/7.3.446 b/7.3.446 new file mode 100644 index 00000000..59a2b254 --- /dev/null +++ b/7.3.446 @@ -0,0 +1,164 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.446 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.446 (after 7.3.445) +Problem: Win32: External commands with special characters don't work. +Solution: Add the 'shellxescape' option. +Files: src/misc2.c, src/option.c, src/option.h, runtime/doc/options.txt + + +*** ../vim-7.3.445/src/misc2.c 2012-02-19 18:19:24.000000000 +0100 +--- src/misc2.c 2012-02-20 22:05:22.000000000 +0100 +*************** +*** 3225,3235 **** + retval = mch_call_shell(cmd, opt); + else + { +! ncmd = alloc((unsigned)(STRLEN(cmd) + STRLEN(p_sxq) * 2 + 1)); + if (ncmd != NULL) + { + STRCPY(ncmd, p_sxq); +! STRCAT(ncmd, cmd); + /* When 'shellxquote' is ( append ). + * When 'shellxquote' is "( append )". */ + STRCAT(ncmd, STRCMP(p_sxq, "(") == 0 ? (char_u *)")" +--- 3225,3243 ---- + retval = mch_call_shell(cmd, opt); + else + { +! char_u *ecmd = cmd; +! +! if (*p_sxe != NUL && STRCMP(p_sxq, "(") == 0) +! { +! ecmd = vim_strsave_escaped_ext(cmd, p_sxe, '^', FALSE); +! if (ecmd == NULL) +! ecmd = cmd; +! } +! ncmd = alloc((unsigned)(STRLEN(ecmd) + STRLEN(p_sxq) * 2 + 1)); + if (ncmd != NULL) + { + STRCPY(ncmd, p_sxq); +! STRCAT(ncmd, ecmd); + /* When 'shellxquote' is ( append ). + * When 'shellxquote' is "( append )". */ + STRCAT(ncmd, STRCMP(p_sxq, "(") == 0 ? (char_u *)")" +*************** +*** 3240,3245 **** +--- 3248,3255 ---- + } + else + retval = -1; ++ if (ecmd != cmd) ++ vim_free(ecmd); + } + #ifdef FEAT_GUI + --hold_gui_events; +*** ../vim-7.3.445/src/option.c 2012-02-19 18:19:24.000000000 +0100 +--- src/option.c 2012-02-20 22:01:07.000000000 +0100 +*************** +*** 2273,2278 **** +--- 2273,2287 ---- + (char_u *)"", + #endif + (char_u *)0L} SCRIPTID_INIT}, ++ {"shellxescape", "sxe", P_STRING|P_VI_DEF|P_SECURE, ++ (char_u *)&p_sxe, PV_NONE, ++ { ++ #if defined(MSDOS) || defined(WIN16) || defined(WIN3264) ++ (char_u *)"\"&|<>()@^", ++ #else ++ (char_u *)"", ++ #endif ++ (char_u *)0L} SCRIPTID_INIT}, + {"shiftround", "sr", P_BOOL|P_VI_DEF|P_VIM, + (char_u *)&p_sr, PV_NONE, + {(char_u *)FALSE, (char_u *)0L} SCRIPTID_INIT}, +*** ../vim-7.3.445/src/option.h 2011-10-20 21:09:25.000000000 +0200 +--- src/option.h 2012-02-20 21:45:31.000000000 +0100 +*************** +*** 712,717 **** +--- 712,718 ---- + #endif + EXTERN char_u *p_shq; /* 'shellquote' */ + EXTERN char_u *p_sxq; /* 'shellxquote' */ ++ EXTERN char_u *p_sxe; /* 'shellxescape' */ + EXTERN char_u *p_srr; /* 'shellredir' */ + #ifdef AMIGA + EXTERN long p_st; /* 'shelltype' */ +*** ../vim-7.3.445/runtime/doc/options.txt 2012-02-12 23:23:25.000000000 +0100 +--- runtime/doc/options.txt 2012-02-20 22:09:19.000000000 +0100 +*************** +*** 6023,6030 **** + + *'shellxquote'* *'sxq'* + 'shellxquote' 'sxq' string (default: ""; +! for Win32, when 'shell' is cmd.exe or +! contains "sh" somewhere: "\"" + for Unix, when using system(): "\"") + global + {not in Vi} +--- 6042,6050 ---- + + *'shellxquote'* *'sxq'* + 'shellxquote' 'sxq' string (default: ""; +! for Win32, when 'shell' is cmd.exe: "(" +! for Win32, when 'shell' contains "sh" +! somewhere: "\"" + for Unix, when using system(): "\"") + global + {not in Vi} +*************** +*** 6032,6037 **** +--- 6052,6060 ---- + the "!" and ":!" commands. Includes the redirection. See + 'shellquote' to exclude the redirection. It's probably not useful + to set both options. ++ When the value is '(' then ')' is appended. When the value is '"(' ++ then ')"' is appended. ++ When the value is '(' then also see 'shellxescape'. + This is an empty string by default on most systems, but is known to be + useful for on Win32 version, either for cmd.exe which automatically + strips off the first and last quote on a command, or 3rd-party shells +*************** +*** 6041,6046 **** +--- 6064,6079 ---- + This option cannot be set from a |modeline| or in the |sandbox|, for + security reasons. + ++ *'shellxescape'* *'sxe'* ++ 'shellxescape' 'sxe' string (default: ""; ++ for MS-DOS and MS-Windows: "\"&|<>()@^") ++ global ++ {not in Vi} ++ When 'shellxquote' is set to "(" then the characters listed in this ++ option will be escaped with a '^' character. This makes it possible ++ to execute most external commands with cmd.exe. ++ ++ + *'shiftround'* *'sr'* *'noshiftround'* *'nosr'* + 'shiftround' 'sr' boolean (default off) + global +*** ../vim-7.3.445/src/version.c 2012-02-19 18:19:24.000000000 +0100 +--- src/version.c 2012-02-20 22:12:32.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 446, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +86. E-mail Deficiency Depression (EDD) forces you to e-mail yourself. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2f10541dd5f21db66269c21d026fb24cfc873d5e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:46 +0100 Subject: [PATCH 0177/3340] - patchlevel 447 --- 7.3.447 | 377 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 377 insertions(+) create mode 100644 7.3.447 diff --git a/7.3.447 b/7.3.447 new file mode 100644 index 00000000..9c0af9f4 --- /dev/null +++ b/7.3.447 @@ -0,0 +1,377 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.447 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.447 (after 7.3.446) +Problem: Win32: External commands with "start" do not work. +Solution: Unescape part of the command. (Yasuhiro Matsumoto) +Files: src/os_win32.c + + +*** ../vim-7.3.446/src/os_win32.c 2012-02-19 18:19:24.000000000 +0100 +--- src/os_win32.c 2012-02-21 20:56:51.000000000 +0100 +*************** +*** 259,264 **** +--- 259,287 ---- + } + + /* ++ * Unescape characters in "p" that appear in "escaped". ++ */ ++ static void ++ unescape_shellxquote(char_u *p, char_u *escaped) ++ { ++ int l = STRLEN(p); ++ int n; ++ ++ while (*p != NUL) ++ { ++ if (*p == '^' && vim_strchr(escaped, p[1]) != NULL) ++ mch_memmove(p, p + 1, l--); ++ #ifdef FEAT_MBYTE ++ n = (*mb_ptr2len)(p); ++ #else ++ n = 1; ++ #endif ++ p += n; ++ l -= n; ++ } ++ } ++ ++ /* + * Load library "name". + */ + HINSTANCE +*************** +*** 3559,3564 **** +--- 3582,3588 ---- + garray_T ga; + int delay = 1; + DWORD buffer_off = 0; /* valid bytes in buffer[] */ ++ char *p = NULL; + + SECURITY_ATTRIBUTES saAttr; + +*************** +*** 3599,3607 **** + if (options & SHELL_READ) + ga_init2(&ga, 1, BUFLEN); + + /* Now, run the command */ + CreateProcess(NULL, /* Executable name */ +! cmd, /* Command to execute */ + NULL, /* Process security attributes */ + NULL, /* Thread security attributes */ + +--- 3623,3640 ---- + if (options & SHELL_READ) + ga_init2(&ga, 1, BUFLEN); + ++ if (cmd != NULL) ++ { ++ p = (char *)vim_strsave((char_u *)cmd); ++ if (p != NULL) ++ unescape_shellxquote((char_u *)p, p_sxe); ++ else ++ p = cmd; ++ } ++ + /* Now, run the command */ + CreateProcess(NULL, /* Executable name */ +! p, /* Command to execute */ + NULL, /* Process security attributes */ + NULL, /* Thread security attributes */ + +*************** +*** 3616,3621 **** +--- 3649,3656 ---- + &si, /* Startup information */ + &pi); /* Process information */ + ++ if (p != cmd) ++ vim_free(p); + + /* Close our unused side of the pipes */ + CloseHandle(g_hChildStd_IN_Rd); +*************** +*** 3898,4018 **** + else + { + /* we use "command" or "cmd" to start the shell; slow but easy */ +! char_u *newcmd; +! long_u cmdlen = ( +! #ifdef FEAT_GUI_W32 +! (allowPiping && !p_stmp ? 0 : STRLEN(vimrun_path)) + +! #endif +! STRLEN(p_sh) + STRLEN(p_shcf) + STRLEN(cmd) + 10); +! +! newcmd = lalloc(cmdlen, TRUE); +! if (newcmd != NULL) +! { +! char_u *cmdbase = cmd; +! +! /* Skip a leading ", ( and "(. */ +! if (*cmdbase == '"' ) +! ++cmdbase; +! if (*cmdbase == '(') +! ++cmdbase; +! if ((STRNICMP(cmdbase, "start", 5) == 0) && vim_iswhite(cmdbase[5])) +! { +! STARTUPINFO si; +! PROCESS_INFORMATION pi; +! DWORD flags = CREATE_NEW_CONSOLE; +! +! si.cb = sizeof(si); +! si.lpReserved = NULL; +! si.lpDesktop = NULL; +! si.lpTitle = NULL; +! si.dwFlags = 0; +! si.cbReserved2 = 0; +! si.lpReserved2 = NULL; +! +! cmdbase = skipwhite(cmdbase + 5); +! if ((STRNICMP(cmdbase, "/min", 4) == 0) +! && vim_iswhite(cmdbase[4])) +! { +! cmdbase = skipwhite(cmdbase + 4); +! si.dwFlags = STARTF_USESHOWWINDOW; +! si.wShowWindow = SW_SHOWMINNOACTIVE; +! } +! else if ((STRNICMP(cmdbase, "/b", 2) == 0) +! && vim_iswhite(cmdbase[2])) +! { +! cmdbase = skipwhite(cmdbase + 2); +! flags = CREATE_NO_WINDOW; +! si.dwFlags = STARTF_USESTDHANDLES; +! si.hStdInput = CreateFile("\\\\.\\NUL", // File name +! GENERIC_READ, // Access flags +! 0, // Share flags +! NULL, // Security att. +! OPEN_EXISTING, // Open flags +! FILE_ATTRIBUTE_NORMAL, // File att. +! NULL); // Temp file +! si.hStdOutput = si.hStdInput; +! si.hStdError = si.hStdInput; +! } + +! /* When the command is in double quotes, but 'shellxquote' is +! * empty, keep the double quotes around the command. +! * Otherwise remove the double quotes, they aren't needed +! * here, because we don't use a shell to run the command. */ +! if (cmdbase > cmd) +! { +! if (STRNCMP(cmd, p_sxq, cmd - cmdbase) != 0) +! { +! STRCPY(newcmd, cmd); +! } +! else +! { +! char_u *p; + +! STRCPY(newcmd, cmdbase); +! /* Remove a trailing ", ) and )" if they have a match +! * at the start of the command. */ +! p = newcmd + STRLEN(newcmd); +! if (p > newcmd && p[-1] == '"' && *cmd == '"') +! *--p = NUL; +! if (p > newcmd && p[-1] == ')' +! && (*cmd =='(' || cmd[1] == '(')) +! *--p = NUL; +! } +! } + +! /* +! * Now, start the command as a process, so that it doesn't +! * inherit our handles which causes unpleasant dangling swap +! * files if we exit before the spawned process +! */ +! if (CreateProcess(NULL, // Executable name +! newcmd, // Command to execute +! NULL, // Process security attributes +! NULL, // Thread security attributes +! FALSE, // Inherit handles +! flags, // Creation flags +! NULL, // Environment +! NULL, // Current directory +! &si, // Startup information +! &pi)) // Process information +! x = 0; +! else +! { +! x = -1; + #ifdef FEAT_GUI_W32 +! EMSG(_("E371: Command not found")); + #endif +- } +- if (si.hStdInput != NULL) +- { +- /* Close the handle to \\.\NUL */ +- CloseHandle(si.hStdInput); +- } +- /* Close the handles to the subprocess, so that it goes away */ +- CloseHandle(pi.hThread); +- CloseHandle(pi.hProcess); + } +! else + { + #if defined(FEAT_GUI_W32) + if (need_vimrun_warning) +--- 3933,4048 ---- + else + { + /* we use "command" or "cmd" to start the shell; slow but easy */ +! char_u *cmdbase = cmd; + +! /* Skip a leading ", ( and "(. */ +! if (*cmdbase == '"' ) +! ++cmdbase; +! if (*cmdbase == '(') +! ++cmdbase; +! +! if ((STRNICMP(cmdbase, "start", 5) == 0) && vim_iswhite(cmdbase[5])) +! { +! STARTUPINFO si; +! PROCESS_INFORMATION pi; +! DWORD flags = CREATE_NEW_CONSOLE; +! char_u *p; +! +! si.cb = sizeof(si); +! si.lpReserved = NULL; +! si.lpDesktop = NULL; +! si.lpTitle = NULL; +! si.dwFlags = 0; +! si.cbReserved2 = 0; +! si.lpReserved2 = NULL; +! +! cmdbase = skipwhite(cmdbase + 5); +! if ((STRNICMP(cmdbase, "/min", 4) == 0) +! && vim_iswhite(cmdbase[4])) +! { +! cmdbase = skipwhite(cmdbase + 4); +! si.dwFlags = STARTF_USESHOWWINDOW; +! si.wShowWindow = SW_SHOWMINNOACTIVE; +! } +! else if ((STRNICMP(cmdbase, "/b", 2) == 0) +! && vim_iswhite(cmdbase[2])) +! { +! cmdbase = skipwhite(cmdbase + 2); +! flags = CREATE_NO_WINDOW; +! si.dwFlags = STARTF_USESTDHANDLES; +! si.hStdInput = CreateFile("\\\\.\\NUL", // File name +! GENERIC_READ, // Access flags +! 0, // Share flags +! NULL, // Security att. +! OPEN_EXISTING, // Open flags +! FILE_ATTRIBUTE_NORMAL, // File att. +! NULL); // Temp file +! si.hStdOutput = si.hStdInput; +! si.hStdError = si.hStdInput; +! } +! +! /* Remove a trailing ", ) and )" if they have a match +! * at the start of the command. */ +! if (cmdbase > cmd) +! { +! p = cmdbase + STRLEN(cmdbase); +! if (p > cmdbase && p[-1] == '"' && *cmd == '"') +! *--p = NUL; +! if (p > cmdbase && p[-1] == ')' +! && (*cmd =='(' || cmd[1] == '(')) +! *--p = NUL; +! } + +! /* +! * Unescape characters in shellxescape. This is workaround for +! * /b option. Only redirect character should be unescaped. +! */ +! unescape_shellxquote(cmdbase, +! (flags & CREATE_NEW_CONSOLE) ? p_sxe : "<>"); + +! /* +! * Now, start the command as a process, so that it doesn't +! * inherit our handles which causes unpleasant dangling swap +! * files if we exit before the spawned process +! */ +! if (CreateProcess(NULL, // Executable name +! cmdbase, // Command to execute +! NULL, // Process security attributes +! NULL, // Thread security attributes +! FALSE, // Inherit handles +! flags, // Creation flags +! NULL, // Environment +! NULL, // Current directory +! &si, // Startup information +! &pi)) // Process information +! x = 0; +! else +! { +! x = -1; + #ifdef FEAT_GUI_W32 +! EMSG(_("E371: Command not found")); + #endif + } +! if (si.hStdInput != NULL) +! { +! /* Close the handle to \\.\NUL */ +! CloseHandle(si.hStdInput); +! } +! /* Close the handles to the subprocess, so that it goes away */ +! CloseHandle(pi.hThread); +! CloseHandle(pi.hProcess); +! } +! else +! { +! char_u *newcmd; +! long_u cmdlen = ( +! #ifdef FEAT_GUI_W32 +! (allowPiping && !p_stmp ? 0 : STRLEN(vimrun_path)) + +! #endif +! STRLEN(p_sh) + STRLEN(p_shcf) + STRLEN(cmd) + 10); +! +! newcmd = lalloc(cmdlen, TRUE); +! if (newcmd != NULL) + { + #if defined(FEAT_GUI_W32) + if (need_vimrun_warning) +*************** +*** 4038,4045 **** + vim_snprintf((char *)newcmd, cmdlen, "%s %s %s", + p_sh, p_shcf, cmd); + x = mch_system((char *)newcmd, options); + } +- vim_free(newcmd); + } + } + +--- 4068,4075 ---- + vim_snprintf((char *)newcmd, cmdlen, "%s %s %s", + p_sh, p_shcf, cmd); + x = mch_system((char *)newcmd, options); ++ vim_free(newcmd); + } + } + } + +*** ../vim-7.3.446/src/version.c 2012-02-20 22:18:23.000000000 +0100 +--- src/version.c 2012-02-21 21:20:05.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 447, + /**/ + +-- +From "know your smileys": + :----} You lie like Pinocchio + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0c3fda78437e9bb6923a5c801b73dad4726121f6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:46 +0100 Subject: [PATCH 0178/3340] - patchlevel 448 --- 7.3.448 | 180 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 180 insertions(+) create mode 100644 7.3.448 diff --git a/7.3.448 b/7.3.448 new file mode 100644 index 00000000..91d8f26e --- /dev/null +++ b/7.3.448 @@ -0,0 +1,180 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.448 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.448 (after 7.3.447) +Problem: Win32: Still a problem with "!start /b". +Solution: Escape only '|'. (Yasuhiro Matsumoto) +Files: src/os_win32.c + + +*** ../vim-7.3.447/src/os_win32.c 2012-02-21 21:22:40.000000000 +0100 +--- src/os_win32.c 2012-02-22 13:06:55.000000000 +0100 +*************** +*** 3933,3939 **** + else + { + /* we use "command" or "cmd" to start the shell; slow but easy */ +! char_u *cmdbase = cmd; + + /* Skip a leading ", ( and "(. */ + if (*cmdbase == '"' ) +--- 3933,3941 ---- + else + { + /* we use "command" or "cmd" to start the shell; slow but easy */ +! char_u *newcmd = NULL; +! char_u *cmdbase = cmd; +! long_u cmdlen; + + /* Skip a leading ", ( and "(. */ + if (*cmdbase == '"' ) +*************** +*** 3971,3982 **** + flags = CREATE_NO_WINDOW; + si.dwFlags = STARTF_USESTDHANDLES; + si.hStdInput = CreateFile("\\\\.\\NUL", // File name +! GENERIC_READ, // Access flags + 0, // Share flags +! NULL, // Security att. +! OPEN_EXISTING, // Open flags +! FILE_ATTRIBUTE_NORMAL, // File att. +! NULL); // Temp file + si.hStdOutput = si.hStdInput; + si.hStdError = si.hStdInput; + } +--- 3973,3984 ---- + flags = CREATE_NO_WINDOW; + si.dwFlags = STARTF_USESTDHANDLES; + si.hStdInput = CreateFile("\\\\.\\NUL", // File name +! GENERIC_READ, // Access flags + 0, // Share flags +! NULL, // Security att. +! OPEN_EXISTING, // Open flags +! FILE_ATTRIBUTE_NORMAL, // File att. +! NULL); // Temp file + si.hStdOutput = si.hStdInput; + si.hStdError = si.hStdInput; + } +*************** +*** 3993,4004 **** + *--p = NUL; + } + + /* +! * Unescape characters in shellxescape. This is workaround for +! * /b option. Only redirect character should be unescaped. + */ +! unescape_shellxquote(cmdbase, +! (flags & CREATE_NEW_CONSOLE) ? p_sxe : "<>"); + + /* + * Now, start the command as a process, so that it doesn't +--- 3995,4030 ---- + *--p = NUL; + } + ++ newcmd = cmdbase; ++ unescape_shellxquote(cmdbase, p_sxe); ++ + /* +! * If creating new console, arguments are passed to the +! * 'cmd.exe' as-is. If it's not, arguments are not treated +! * correctly for current 'cmd.exe'. So unescape characters in +! * shellxescape except '|' for avoiding to be treated as +! * argument to them. Pass the arguments to sub-shell. + */ +! if (flags != CREATE_NEW_CONSOLE) +! { +! char_u *subcmd; +! char_u *cmd_shell = default_shell(); +! +! subcmd = vim_strsave_escaped_ext(cmdbase, "|", '^', FALSE); +! if (subcmd != NULL) +! { +! /* make "cmd.exe /c arguments" */ +! cmdlen = STRLEN(cmd_shell) + STRLEN(subcmd) + 5; +! vim_free(subcmd); +! +! newcmd = lalloc(cmdlen, TRUE); +! if (newcmd != NULL) +! vim_snprintf((char *)newcmd, cmdlen, "%s /c %s", +! default_shell, subcmd); +! else +! newcmd = cmdbase; +! } +! } + + /* + * Now, start the command as a process, so that it doesn't +*************** +*** 4006,4012 **** + * files if we exit before the spawned process + */ + if (CreateProcess(NULL, // Executable name +! cmdbase, // Command to execute + NULL, // Process security attributes + NULL, // Thread security attributes + FALSE, // Inherit handles +--- 4032,4038 ---- + * files if we exit before the spawned process + */ + if (CreateProcess(NULL, // Executable name +! newcmd, // Command to execute + NULL, // Process security attributes + NULL, // Thread security attributes + FALSE, // Inherit handles +*************** +*** 4023,4028 **** +--- 4049,4058 ---- + EMSG(_("E371: Command not found")); + #endif + } ++ ++ if (newcmd != cmdbase) ++ vim_free(newcmd); ++ + if (si.hStdInput != NULL) + { + /* Close the handle to \\.\NUL */ +*************** +*** 4034,4041 **** + } + else + { +! char_u *newcmd; +! long_u cmdlen = ( + #ifdef FEAT_GUI_W32 + (allowPiping && !p_stmp ? 0 : STRLEN(vimrun_path)) + + #endif +--- 4064,4070 ---- + } + else + { +! cmdlen = ( + #ifdef FEAT_GUI_W32 + (allowPiping && !p_stmp ? 0 : STRLEN(vimrun_path)) + + #endif +*** ../vim-7.3.447/src/version.c 2012-02-21 21:22:40.000000000 +0100 +--- src/version.c 2012-02-22 13:02:15.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 448, + /**/ + +-- +From "know your smileys": + ~#:-( I just washed my hair, and I can't do nuthin' with it. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6dde40a47e9a0ff81b837b836fd79abeeed71e1d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:46 +0100 Subject: [PATCH 0179/3340] - patchlevel 449 --- 7.3.449 | 455 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 455 insertions(+) create mode 100644 7.3.449 diff --git a/7.3.449 b/7.3.449 new file mode 100644 index 00000000..9b5bdea8 --- /dev/null +++ b/7.3.449 @@ -0,0 +1,455 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.449 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.449 +Problem: Crash when a BufWinLeave autocommand closes the only other window. + (Daniel Hunt) +Solution: Abort closing a buffer when it becomes the only one. +Files: src/buffer.c, src/proto/buffer.pro, src/ex_cmds.c, src/ex_getln.c, + src/misc2.c, src/quickfix.c, src/window.c, src/proto/window.pro + + +*** ../vim-7.3.448/src/buffer.c 2012-01-20 20:44:38.000000000 +0100 +--- src/buffer.c 2012-02-22 14:50:42.000000000 +0100 +*************** +*** 64,69 **** +--- 64,72 ---- + static char *msg_loclist = N_("[Location List]"); + static char *msg_qflist = N_("[Quickfix List]"); + #endif ++ #ifdef FEAT_AUTOCMD ++ static char *e_auabort = N_("E855: Autocommands caused command to abort"); ++ #endif + + /* + * Open current buffer, that is: open the memfile and read the file into +*************** +*** 96,102 **** + * There MUST be a memfile, otherwise we can't do anything + * If we can't create one for the current buffer, take another buffer + */ +! close_buffer(NULL, curbuf, 0); + for (curbuf = firstbuf; curbuf != NULL; curbuf = curbuf->b_next) + if (curbuf->b_ml.ml_mfp != NULL) + break; +--- 99,105 ---- + * There MUST be a memfile, otherwise we can't do anything + * If we can't create one for the current buffer, take another buffer + */ +! close_buffer(NULL, curbuf, 0, FALSE); + for (curbuf = firstbuf; curbuf != NULL; curbuf = curbuf->b_next) + if (curbuf->b_ml.ml_mfp != NULL) + break; +*************** +*** 316,327 **** + * get a new buffer very soon! + * + * The 'bufhidden' option can force freeing and deleting. + */ + void +! close_buffer(win, buf, action) + win_T *win; /* if not NULL, set b_last_cursor */ + buf_T *buf; + int action; + { + #ifdef FEAT_AUTOCMD + int is_curbuf; +--- 319,335 ---- + * get a new buffer very soon! + * + * The 'bufhidden' option can force freeing and deleting. ++ * ++ * When "abort_if_last" is TRUE then do not close the buffer if autocommands ++ * cause there to be only one window with this buffer. e.g. when ":quit" is ++ * supposed to close the window but autocommands close all other windows. + */ + void +! close_buffer(win, buf, action, abort_if_last) + win_T *win; /* if not NULL, set b_last_cursor */ + buf_T *buf; + int action; ++ int abort_if_last; + { + #ifdef FEAT_AUTOCMD + int is_curbuf; +*************** +*** 371,378 **** + { + apply_autocmds(EVENT_BUFWINLEAVE, buf->b_fname, buf->b_fname, + FALSE, buf); +! if (!buf_valid(buf)) /* autocommands may delete the buffer */ + return; + + /* When the buffer becomes hidden, but is not unloaded, trigger + * BufHidden */ +--- 379,390 ---- + { + apply_autocmds(EVENT_BUFWINLEAVE, buf->b_fname, buf->b_fname, + FALSE, buf); +! /* Return if autocommands deleted the buffer or made it the only one. */ +! if (!buf_valid(buf) || (abort_if_last && one_window())) +! { +! EMSG(_(e_auabort)); + return; ++ } + + /* When the buffer becomes hidden, but is not unloaded, trigger + * BufHidden */ +*************** +*** 380,387 **** + { + apply_autocmds(EVENT_BUFHIDDEN, buf->b_fname, buf->b_fname, + FALSE, buf); +! if (!buf_valid(buf)) /* autocmds may delete the buffer */ + return; + } + # ifdef FEAT_EVAL + if (aborting()) /* autocmds may abort script processing */ +--- 392,404 ---- + { + apply_autocmds(EVENT_BUFHIDDEN, buf->b_fname, buf->b_fname, + FALSE, buf); +! /* Return if autocommands deleted the buffer or made it the only +! * one. */ +! if (!buf_valid(buf) || (abort_if_last && one_window())) +! { +! EMSG(_(e_auabort)); + return; ++ } + } + # ifdef FEAT_EVAL + if (aborting()) /* autocmds may abort script processing */ +*************** +*** 775,781 **** + * open a new, empty buffer. */ + swap_exists_action = SEA_NONE; /* don't want it again */ + swap_exists_did_quit = TRUE; +! close_buffer(curwin, curbuf, DOBUF_UNLOAD); + if (!buf_valid(old_curbuf) || old_curbuf == curbuf) + old_curbuf = buflist_new(NULL, NULL, 1L, BLN_CURBUF | BLN_LISTED); + if (old_curbuf != NULL) +--- 792,798 ---- + * open a new, empty buffer. */ + swap_exists_action = SEA_NONE; /* don't want it again */ + swap_exists_did_quit = TRUE; +! close_buffer(curwin, curbuf, DOBUF_UNLOAD, FALSE); + if (!buf_valid(old_curbuf) || old_curbuf == curbuf) + old_curbuf = buflist_new(NULL, NULL, 1L, BLN_CURBUF | BLN_LISTED); + if (old_curbuf != NULL) +*************** +*** 1122,1128 **** + * if the buffer still exists. + */ + if (buf != curbuf && buf_valid(buf) && buf->b_nwindows == 0) +! close_buffer(NULL, buf, action); + return retval; + } + +--- 1139,1145 ---- + * if the buffer still exists. + */ + if (buf != curbuf && buf_valid(buf) && buf->b_nwindows == 0) +! close_buffer(NULL, buf, action, FALSE); + return retval; + } + +*************** +*** 1146,1152 **** + close_windows(buf, FALSE); + #endif + if (buf != curbuf && buf_valid(buf) && buf->b_nwindows <= 0) +! close_buffer(NULL, buf, action); + return OK; + } + +--- 1163,1169 ---- + close_windows(buf, FALSE); + #endif + if (buf != curbuf && buf_valid(buf) && buf->b_nwindows <= 0) +! close_buffer(NULL, buf, action, FALSE); + return OK; + } + +*************** +*** 1378,1384 **** + close_buffer(prevbuf == curwin->w_buffer ? curwin : NULL, prevbuf, + unload ? action : (action == DOBUF_GOTO + && !P_HID(prevbuf) +! && !bufIsChanged(prevbuf)) ? DOBUF_UNLOAD : 0); + } + } + #ifdef FEAT_AUTOCMD +--- 1395,1401 ---- + close_buffer(prevbuf == curwin->w_buffer ? curwin : NULL, prevbuf, + unload ? action : (action == DOBUF_GOTO + && !P_HID(prevbuf) +! && !bufIsChanged(prevbuf)) ? DOBUF_UNLOAD : 0, FALSE); + } + } + #ifdef FEAT_AUTOCMD +*************** +*** 2708,2714 **** + vim_free(ffname); + return FAIL; + } +! close_buffer(NULL, obuf, DOBUF_WIPE); /* delete from the list */ + } + sfname = vim_strsave(sfname); + if (ffname == NULL || sfname == NULL) +--- 2725,2732 ---- + vim_free(ffname); + return FAIL; + } +! /* delete from the list */ +! close_buffer(NULL, obuf, DOBUF_WIPE, FALSE); + } + sfname = vim_strsave(sfname); + if (ffname == NULL || sfname == NULL) +*************** +*** 5638,5644 **** + if (!aucmd) /* Don't trigger BufDelete autocommands here. */ + block_autocmds(); + #endif +! close_buffer(NULL, buf, DOBUF_WIPE); + #ifdef FEAT_AUTOCMD + if (!aucmd) + unblock_autocmds(); +--- 5656,5662 ---- + if (!aucmd) /* Don't trigger BufDelete autocommands here. */ + block_autocmds(); + #endif +! close_buffer(NULL, buf, DOBUF_WIPE, FALSE); + #ifdef FEAT_AUTOCMD + if (!aucmd) + unblock_autocmds(); +*** ../vim-7.3.448/src/proto/buffer.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/buffer.pro 2012-02-22 14:04:26.000000000 +0100 +*************** +*** 1,7 **** + /* buffer.c */ + int open_buffer __ARGS((int read_stdin, exarg_T *eap, int flags)); + int buf_valid __ARGS((buf_T *buf)); +! void close_buffer __ARGS((win_T *win, buf_T *buf, int action)); + void buf_clear_file __ARGS((buf_T *buf)); + void buf_freeall __ARGS((buf_T *buf, int flags)); + void goto_buffer __ARGS((exarg_T *eap, int start, int dir, int count)); +--- 1,7 ---- + /* buffer.c */ + int open_buffer __ARGS((int read_stdin, exarg_T *eap, int flags)); + int buf_valid __ARGS((buf_T *buf)); +! void close_buffer __ARGS((win_T *win, buf_T *buf, int action, int abort_if_last)); + void buf_clear_file __ARGS((buf_T *buf)); + void buf_freeall __ARGS((buf_T *buf, int flags)); + void goto_buffer __ARGS((exarg_T *eap, int start, int dir, int count)); +*** ../vim-7.3.448/src/ex_cmds.c 2011-12-30 15:01:55.000000000 +0100 +--- src/ex_cmds.c 2012-02-22 14:00:32.000000000 +0100 +*************** +*** 3387,3393 **** + /* close the link to the current buffer */ + u_sync(FALSE); + close_buffer(oldwin, curbuf, +! (flags & ECMD_HIDE) ? 0 : DOBUF_UNLOAD); + + #ifdef FEAT_AUTOCMD + /* Autocommands may open a new window and leave oldwin open +--- 3387,3393 ---- + /* close the link to the current buffer */ + u_sync(FALSE); + close_buffer(oldwin, curbuf, +! (flags & ECMD_HIDE) ? 0 : DOBUF_UNLOAD, FALSE); + + #ifdef FEAT_AUTOCMD + /* Autocommands may open a new window and leave oldwin open +*** ../vim-7.3.448/src/ex_getln.c 2012-02-04 22:44:27.000000000 +0100 +--- src/ex_getln.c 2012-02-22 14:01:56.000000000 +0100 +*************** +*** 6443,6449 **** + /* win_close() may have already wiped the buffer when 'bh' is + * set to 'wipe' */ + if (buf_valid(bp)) +! close_buffer(NULL, bp, DOBUF_WIPE); + + /* Restore window sizes. */ + win_size_restore(&winsizes); +--- 6443,6449 ---- + /* win_close() may have already wiped the buffer when 'bh' is + * set to 'wipe' */ + if (buf_valid(bp)) +! close_buffer(NULL, bp, DOBUF_WIPE, FALSE); + + /* Restore window sizes. */ + win_size_restore(&winsizes); +*** ../vim-7.3.448/src/misc2.c 2012-02-20 22:18:22.000000000 +0100 +--- src/misc2.c 2012-02-22 14:02:12.000000000 +0100 +*************** +*** 1173,1179 **** + for (buf = firstbuf; buf != NULL; ) + { + nextbuf = buf->b_next; +! close_buffer(NULL, buf, DOBUF_WIPE); + if (buf_valid(buf)) + buf = nextbuf; /* didn't work, try next one */ + else +--- 1173,1179 ---- + for (buf = firstbuf; buf != NULL; ) + { + nextbuf = buf->b_next; +! close_buffer(NULL, buf, DOBUF_WIPE, FALSE); + if (buf_valid(buf)) + buf = nextbuf; /* didn't work, try next one */ + else +*** ../vim-7.3.448/src/quickfix.c 2012-01-20 13:39:03.000000000 +0100 +--- src/quickfix.c 2012-02-22 14:02:20.000000000 +0100 +*************** +*** 3565,3571 **** + buf_T *buf; + { + if (curbuf != buf) /* safety check */ +! close_buffer(NULL, buf, DOBUF_UNLOAD); + } + + #if defined(FEAT_EVAL) || defined(PROTO) +--- 3565,3571 ---- + buf_T *buf; + { + if (curbuf != buf) /* safety check */ +! close_buffer(NULL, buf, DOBUF_UNLOAD, FALSE); + } + + #if defined(FEAT_EVAL) || defined(PROTO) +*** ../vim-7.3.448/src/window.c 2012-01-10 22:26:12.000000000 +0100 +--- src/window.c 2012-02-22 14:08:13.000000000 +0100 +*************** +*** 23,29 **** + static void win_totop __ARGS((int size, int flags)); + static void win_equal_rec __ARGS((win_T *next_curwin, int current, frame_T *topfr, int dir, int col, int row, int width, int height)); + static int last_window __ARGS((void)); +- static int one_window __ARGS((void)); + static win_T *win_free_mem __ARGS((win_T *win, int *dirp, tabpage_T *tp)); + static frame_T *win_altframe __ARGS((win_T *win, tabpage_T *tp)); + static tabpage_T *alt_tabpage __ARGS((void)); +--- 23,28 ---- +*************** +*** 2083,2089 **** + * Return TRUE if there is only one window other than "aucmd_win" in the + * current tab page. + */ +! static int + one_window() + { + #ifdef FEAT_AUTOCMD +--- 2082,2088 ---- + * Return TRUE if there is only one window other than "aucmd_win" in the + * current tab page. + */ +! int + one_window() + { + #ifdef FEAT_AUTOCMD +*************** +*** 2109,2115 **** + * Close window "win". Only works for the current tab page. + * If "free_buf" is TRUE related buffer may be unloaded. + * +! * called by :quit, :close, :xit, :wq and findtag() + */ + void + win_close(win, free_buf) +--- 2108,2114 ---- + * Close window "win". Only works for the current tab page. + * If "free_buf" is TRUE related buffer may be unloaded. + * +! * Called by :quit, :close, :xit, :wq and findtag(). + */ + void + win_close(win, free_buf) +*************** +*** 2222,2228 **** + * Close the link to the buffer. + */ + if (win->w_buffer != NULL) +! close_buffer(win, win->w_buffer, free_buf ? DOBUF_UNLOAD : 0); + + /* Autocommands may have closed the window already, or closed the only + * other window or moved to another tab page. */ +--- 2221,2227 ---- + * Close the link to the buffer. + */ + if (win->w_buffer != NULL) +! close_buffer(win, win->w_buffer, free_buf ? DOBUF_UNLOAD : 0, TRUE); + + /* Autocommands may have closed the window already, or closed the only + * other window or moved to another tab page. */ +*************** +*** 2328,2334 **** + int free_tp = FALSE; + + /* Close the link to the buffer. */ +! close_buffer(win, win->w_buffer, free_buf ? DOBUF_UNLOAD : 0); + + /* Careful: Autocommands may have closed the tab page or made it the + * current tab page. */ +--- 2327,2333 ---- + int free_tp = FALSE; + + /* Close the link to the buffer. */ +! close_buffer(win, win->w_buffer, free_buf ? DOBUF_UNLOAD : 0, FALSE); + + /* Careful: Autocommands may have closed the tab page or made it the + * current tab page. */ +*** ../vim-7.3.448/src/proto/window.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/window.pro 2012-02-22 14:08:28.000000000 +0100 +*************** +*** 1,13 **** + /* window.c */ + void do_window __ARGS((int nchar, long Prenum, int xchar)); + int win_split __ARGS((int size, int flags)); +! int win_split_ins __ARGS((int size, int flags, win_T *newwin, int dir)); + int win_valid __ARGS((win_T *win)); + int win_count __ARGS((void)); + int make_windows __ARGS((int count, int vertical)); + void win_move_after __ARGS((win_T *win1, win_T *win2)); + void win_equal __ARGS((win_T *next_curwin, int current, int dir)); + void close_windows __ARGS((buf_T *buf, int keep_curwin)); + void win_close __ARGS((win_T *win, int free_buf)); + void win_close_othertab __ARGS((win_T *win, int free_buf, tabpage_T *tp)); + void win_free_all __ARGS((void)); +--- 1,14 ---- + /* window.c */ + void do_window __ARGS((int nchar, long Prenum, int xchar)); + int win_split __ARGS((int size, int flags)); +! int win_split_ins __ARGS((int size, int flags, win_T *new_wp, int dir)); + int win_valid __ARGS((win_T *win)); + int win_count __ARGS((void)); + int make_windows __ARGS((int count, int vertical)); + void win_move_after __ARGS((win_T *win1, win_T *win2)); + void win_equal __ARGS((win_T *next_curwin, int current, int dir)); + void close_windows __ARGS((buf_T *buf, int keep_curwin)); ++ int one_window __ARGS((void)); + void win_close __ARGS((win_T *win, int free_buf)); + void win_close_othertab __ARGS((win_T *win, int free_buf, tabpage_T *tp)); + void win_free_all __ARGS((void)); +*** ../vim-7.3.448/src/version.c 2012-02-22 13:07:02.000000000 +0100 +--- src/version.c 2012-02-22 14:55:21.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 449, + /**/ + +-- +From "know your smileys": + :-)-O Smiling doctor with stethoscope + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7e0b75180ca107f3c898fea9a3e8c3107da1621e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:46 +0100 Subject: [PATCH 0180/3340] - patchlevel 450 --- 7.3.450 | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 7.3.450 diff --git a/7.3.450 b/7.3.450 new file mode 100644 index 00000000..7112668f --- /dev/null +++ b/7.3.450 @@ -0,0 +1,81 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.450 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.450 (after 7.3.448) +Problem: Win32: Still a problem with "!start /b". +Solution: Fix pointer use. (Yasuhiro Matsumoto) +Files: src/os_win32.c + + +*** ../vim-7.3.449/src/os_win32.c 2012-02-22 13:07:02.000000000 +0100 +--- src/os_win32.c 2012-02-22 15:29:56.000000000 +0100 +*************** +*** 4008,4028 **** + if (flags != CREATE_NEW_CONSOLE) + { + char_u *subcmd; +! char_u *cmd_shell = default_shell(); + + subcmd = vim_strsave_escaped_ext(cmdbase, "|", '^', FALSE); + if (subcmd != NULL) + { + /* make "cmd.exe /c arguments" */ + cmdlen = STRLEN(cmd_shell) + STRLEN(subcmd) + 5; +- vim_free(subcmd); +- + newcmd = lalloc(cmdlen, TRUE); + if (newcmd != NULL) + vim_snprintf((char *)newcmd, cmdlen, "%s /c %s", +! default_shell, subcmd); + else + newcmd = cmdbase; + } + } + +--- 4008,4030 ---- + if (flags != CREATE_NEW_CONSOLE) + { + char_u *subcmd; +! char_u *cmd_shell = mch_getenv("COMSPEC"); +! +! if (cmd_shell == NULL || *cmd_shell == NUL) +! cmd_shell = default_shell(); + + subcmd = vim_strsave_escaped_ext(cmdbase, "|", '^', FALSE); + if (subcmd != NULL) + { + /* make "cmd.exe /c arguments" */ + cmdlen = STRLEN(cmd_shell) + STRLEN(subcmd) + 5; + newcmd = lalloc(cmdlen, TRUE); + if (newcmd != NULL) + vim_snprintf((char *)newcmd, cmdlen, "%s /c %s", +! cmd_shell, subcmd); + else + newcmd = cmdbase; ++ vim_free(subcmd); + } + } + +*** ../vim-7.3.449/src/version.c 2012-02-22 14:58:24.000000000 +0100 +--- src/version.c 2012-02-22 15:33:53.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 450, + /**/ + +-- +You are only young once, but you can stay immature indefinitely. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c81e3f7ed6722b2690ebfd6240276252acbe3e18 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:47 +0100 Subject: [PATCH 0181/3340] - patchlevel 451 --- 7.3.451 | 363 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 363 insertions(+) create mode 100644 7.3.451 diff --git a/7.3.451 b/7.3.451 new file mode 100644 index 00000000..25d1b046 --- /dev/null +++ b/7.3.451 @@ -0,0 +1,363 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.451 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.451 +Problem: Tcl doesn't work on 64 bit MS-Windows. +Solution: Make it work. (Dave Bodenstab) +Files: src/Make_mvc.mak, src/if_tcl.c + + +*** ../vim-7.3.450/src/Make_mvc.mak 2012-02-12 01:55:50.000000000 +0100 +--- src/Make_mvc.mak 2012-02-22 15:43:01.000000000 +0100 +*************** +*** 616,622 **** + -DDYNAMIC_TCL_VER=\"$(TCL_VER_LONG)\" + TCL_OBJ = $(OUTDIR)\if_tcl.obj + TCL_INC = /I "$(TCL)\Include" /I "$(TCL)" +! TCL_LIB = $(TCL)\lib\tclstub$(TCL_VER).lib + !else + CFLAGS = $(CFLAGS) -DFEAT_TCL + TCL_OBJ = $(OUTDIR)\if_tcl.obj +--- 616,622 ---- + -DDYNAMIC_TCL_VER=\"$(TCL_VER_LONG)\" + TCL_OBJ = $(OUTDIR)\if_tcl.obj + TCL_INC = /I "$(TCL)\Include" /I "$(TCL)" +! TCL_LIB = "$(TCL)\lib\tclstub$(TCL_VER).lib" + !else + CFLAGS = $(CFLAGS) -DFEAT_TCL + TCL_OBJ = $(OUTDIR)\if_tcl.obj +*** ../vim-7.3.450/src/if_tcl.c 2011-07-27 14:15:41.000000000 +0200 +--- src/if_tcl.c 2012-02-22 15:47:00.000000000 +0100 +*************** +*** 79,90 **** + typedef struct + { + Tcl_Interp *interp; + int range_start, range_end; + int lbase; + char *curbuf, *curwin; + } tcl_info; + +! static tcl_info tclinfo = { NULL, 0, 0, 0, NULL, NULL }; + + #define VAR_RANGE1 "::vim::range(start)" + #define VAR_RANGE2 "::vim::range(begin)" +--- 79,91 ---- + typedef struct + { + Tcl_Interp *interp; ++ int exitvalue; + int range_start, range_end; + int lbase; + char *curbuf, *curwin; + } tcl_info; + +! static tcl_info tclinfo = { NULL, 0, 0, 0, 0, NULL, NULL }; + + #define VAR_RANGE1 "::vim::range(start)" + #define VAR_RANGE2 "::vim::range(begin)" +*************** +*** 279,294 **** + ****************************************************************************/ + + /* +! * Replace standard "exit" and "catch" commands. + * +! * This is a design flaw in Tcl - the standard "exit" command just calls +! * exit() and kills the application. It should return TCL_EXIT to the +! * app, which then decides if it wants to terminate or not. In our case, +! * we just delete the Tcl interpreter (and create a new one with the next +! * :tcl command). + */ +- #define TCL_EXIT 5 +- + static int + exitcmd(dummy, interp, objc, objv) + ClientData dummy UNUSED; +--- 280,298 ---- + ****************************************************************************/ + + /* +! * Replace standard "exit" command. + * +! * Delete the Tcl interpreter; a new one will be created with the next +! * :tcl command). The exit code is saved (and retrieved in tclexit()). +! * Since Tcl's exit is never expected to return and this replacement +! * does, then (except for a trivial case) additional Tcl commands will +! * be run. Since the interpreter is now marked as deleted, an error +! * will be returned -- typically "attempt to call eval in deleted +! * interpreter". Hopefully, at this point, checks for TCL_ERROR take +! * place and control percolates back up to Vim -- but with this new error +! * string in the interpreter's result value. Therefore it would be +! * useless for this routine to return the exit code via Tcl_SetResult(). + */ + static int + exitcmd(dummy, interp, objc, objv) + ClientData dummy UNUSED; +*************** +*** 305,351 **** + break; + /* FALLTHROUGH */ + case 1: +! Tcl_SetObjResult(interp, Tcl_NewIntObj(value)); +! return TCL_EXIT; +! default: +! Tcl_WrongNumArgs(interp, 1, objv, "?returnCode?"); +! } +! return TCL_ERROR; +! } + +! static int +! catchcmd(dummy, interp, objc, objv) +! ClientData dummy UNUSED; +! Tcl_Interp *interp; +! int objc; +! Tcl_Obj *CONST objv[]; +! { +! char *varname = NULL; +! int result; +! +! switch (objc) +! { +! case 3: +! varname = Tcl_GetStringFromObj(objv[2], NULL); +! /* fallthrough */ +! case 2: +! Tcl_ResetResult(interp); +! Tcl_AllowExceptions(interp); +! result = Tcl_EvalObj(interp, objv[1]); +! if (result == TCL_EXIT) +! return result; +! if (varname) +! { +! if (Tcl_SetVar(interp, varname, Tcl_GetStringResult(interp), 0) == NULL) +! { +! Tcl_SetResult(interp, "couldn't save command result in variable", TCL_STATIC); +! return TCL_ERROR; +! } +! } +! Tcl_SetObjResult(interp, Tcl_NewIntObj(result)); +! return TCL_OK; + default: +! Tcl_WrongNumArgs(interp, 1, objv, "command ?varName?"); + } + return TCL_ERROR; + } +--- 309,320 ---- + break; + /* FALLTHROUGH */ + case 1: +! tclinfo.exitvalue = value; + +! Tcl_DeleteInterp(interp); +! break; + default: +! Tcl_WrongNumArgs(interp, 1, objv, "?returnCode?"); + } + return TCL_ERROR; + } +*************** +*** 372,377 **** +--- 341,347 ---- + /* + * "::vim::buffer list" - create a list of buffer commands. + * "::vim::buffer {N}" - create buffer command for buffer N. ++ * "::vim::buffer exists {N}" - test if buffer N exists. + * "::vim::buffer new" - create a new buffer (not implemented) + */ + static int +*************** +*** 1663,1669 **** + static Tcl_ChannelType channel_type = + { + "vimmessage", /* typeName */ +! NULL, /* version */ + channel_close, /* closeProc */ + channel_input, /* inputProc */ + channel_output, /* outputProc */ +--- 1633,1639 ---- + static Tcl_ChannelType channel_type = + { + "vimmessage", /* typeName */ +! TCL_CHANNEL_VERSION_2, /* version */ + channel_close, /* closeProc */ + channel_input, /* inputProc */ + channel_output, /* outputProc */ +*************** +*** 1678,1683 **** +--- 1648,1655 ---- + NULL, /* flushProc */ + NULL, /* handlerProc */ + #endif ++ /* The following should not be necessary since TCL_CHANNEL_VERSION_2 was ++ * set above */ + #ifdef TCL_CHANNEL_VERSION_3 + NULL, /* wideSeekProc */ + #endif +*************** +*** 1741,1747 **** + Tcl_Interp *interp; + static Tcl_Channel ch1, ch2; + +! /* replace stdout and stderr */ + ch1 = Tcl_CreateChannel(&channel_type, "vimout", VIMOUT, TCL_WRITABLE); + ch2 = Tcl_CreateChannel(&channel_type, "vimerr", VIMERR, TCL_WRITABLE); + Tcl_SetStdChannel(ch1, TCL_STDOUT); +--- 1713,1721 ---- + Tcl_Interp *interp; + static Tcl_Channel ch1, ch2; + +! /* Create replacement channels for stdout and stderr; this has to be +! * done each time an interpreter is created since the channels are closed +! * when the interpreter is deleted */ + ch1 = Tcl_CreateChannel(&channel_type, "vimout", VIMOUT, TCL_WRITABLE); + ch2 = Tcl_CreateChannel(&channel_type, "vimerr", VIMERR, TCL_WRITABLE); + Tcl_SetStdChannel(ch1, TCL_STDOUT); +*************** +*** 1761,1775 **** + #endif + + Tcl_SetChannelOption(interp, ch1, "-buffering", "line"); + Tcl_SetChannelOption(interp, ch2, "-buffering", "line"); + +! /* replace some standard Tcl commands */ + Tcl_DeleteCommand(interp, "exit"); + Tcl_CreateObjCommand(interp, "exit", exitcmd, + (ClientData)NULL, (Tcl_CmdDeleteProc *)NULL); +- Tcl_DeleteCommand(interp, "catch"); +- Tcl_CreateObjCommand(interp, "catch", catchcmd, +- (ClientData)NULL, (Tcl_CmdDeleteProc *)NULL); + + /* new commands, in ::vim namespace */ + Tcl_CreateObjCommand(interp, "::vim::buffer", buffercmd, +--- 1735,1752 ---- + #endif + + Tcl_SetChannelOption(interp, ch1, "-buffering", "line"); ++ #ifdef WIN3264 ++ Tcl_SetChannelOption(interp, ch1, "-translation", "lf"); ++ #endif + Tcl_SetChannelOption(interp, ch2, "-buffering", "line"); ++ #ifdef WIN3264 ++ Tcl_SetChannelOption(interp, ch2, "-translation", "lf"); ++ #endif + +! /* replace standard Tcl exit command */ + Tcl_DeleteCommand(interp, "exit"); + Tcl_CreateObjCommand(interp, "exit", exitcmd, + (ClientData)NULL, (Tcl_CmdDeleteProc *)NULL); + + /* new commands, in ::vim namespace */ + Tcl_CreateObjCommand(interp, "::vim::buffer", buffercmd, +*************** +*** 1821,1826 **** +--- 1798,1805 ---- + tclinfo.range_end = row2tcl(eap->line2); + tclupdatevars(); + } ++ ++ tclinfo.exitvalue = 0; + return OK; + } + +*************** +*** 1884,1913 **** + { + int newerr = OK; + +! if (error == TCL_EXIT) + { +- int retval; + char buf[50]; +- Tcl_Obj *robj; + +! robj = Tcl_GetObjResult(tclinfo.interp); +! if (Tcl_GetIntFromObj(tclinfo.interp, robj, &retval) != TCL_OK) + { +! EMSG(_("E281: TCL ERROR: exit code is not int!? Please report this to vim-dev@vim.org")); +! newerr = FAIL; + } + else +! { +! sprintf(buf, _("E572: exit code %d"), retval); +! tclerrmsg(buf); +! if (retval == 0) +! { +! did_emsg = 0; +! newerr = OK; +! } +! else +! newerr = FAIL; +! } + + tcldelthisinterp(); + } +--- 1863,1885 ---- + { + int newerr = OK; + +! if (Tcl_InterpDeleted(tclinfo.interp) /* True if we intercepted Tcl's exit command */ +! #if (TCL_MAJOR_VERSION == 8 && TCL_MINOR_VERSION >= 5) || TCL_MAJOR_VERSION > 8 +! || Tcl_LimitExceeded(tclinfo.interp) /* True if the interpreter cannot continue */ +! #endif +! ) + { + char buf[50]; + +! sprintf(buf, _("E572: exit code %d"), tclinfo.exitvalue); +! tclerrmsg(buf); +! if (tclinfo.exitvalue == 0) + { +! did_emsg = 0; +! newerr = OK; + } + else +! newerr = FAIL; + + tcldelthisinterp(); + } +*************** +*** 2021,2027 **** + Tcl_SetVar(tclinfo.interp, var_line, line, 0); + Tcl_AllowExceptions(tclinfo.interp); + err = Tcl_Eval(tclinfo.interp, script); +! if (err != TCL_OK) + break; + line = (char *)Tcl_GetVar(tclinfo.interp, var_line, 0); + if (line) +--- 1993,2004 ---- + Tcl_SetVar(tclinfo.interp, var_line, line, 0); + Tcl_AllowExceptions(tclinfo.interp); + err = Tcl_Eval(tclinfo.interp, script); +! if (err != TCL_OK +! || Tcl_InterpDeleted(tclinfo.interp) +! #if (TCL_MAJOR_VERSION == 8 && TCL_MINOR_VERSION >= 5) || TCL_MAJOR_VERSION > 8 +! || Tcl_LimitExceeded(tclinfo.interp) +! #endif +! ) + break; + line = (char *)Tcl_GetVar(tclinfo.interp, var_line, 0); + if (line) +*** ../vim-7.3.450/src/version.c 2012-02-22 15:34:05.000000000 +0100 +--- src/version.c 2012-02-22 16:00:49.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 451, + /**/ + +-- +Where do you want to crash today? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1d826f942e4af93e5e014590f267a8856ee7fb03 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:47 +0100 Subject: [PATCH 0182/3340] - patchlevel 452 --- 7.3.452 | 70 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 7.3.452 diff --git a/7.3.452 b/7.3.452 new file mode 100644 index 00000000..295b2fe8 --- /dev/null +++ b/7.3.452 @@ -0,0 +1,70 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.452 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.452 +Problem: Undo broken when pasting close to the last line. (Andrey Radev) +Solution: Use a flag to remember if the deleted included the last line. + (Christian Brabandt) +Files: src/ops.c + + +*** ../vim-7.3.451/src/ops.c 2012-01-10 13:46:18.000000000 +0100 +--- src/ops.c 2012-02-22 17:32:40.000000000 +0100 +*************** +*** 1943,1954 **** +--- 1943,1956 ---- + else /* delete characters between lines */ + { + pos_T curpos; ++ int delete_last_line; + + /* save deleted and changed lines for undo */ + if (u_save((linenr_T)(curwin->w_cursor.lnum - 1), + (linenr_T)(curwin->w_cursor.lnum + oap->line_count)) == FAIL) + return FAIL; + ++ delete_last_line = (oap->end.lnum == curbuf->b_ml.ml_line_count); + truncate_line(TRUE); /* delete from cursor to end of line */ + + curpos = curwin->w_cursor; /* remember curwin->w_cursor */ +*************** +*** 1956,1962 **** + del_lines((long)(oap->line_count - 2), FALSE); + + n = (oap->end.col + 1 - !oap->inclusive); +! if (oap->inclusive && oap->end.lnum == curbuf->b_ml.ml_line_count + && n > (int)STRLEN(ml_get(oap->end.lnum))) + { + /* Special case: gH deletes the last line. */ +--- 1958,1964 ---- + del_lines((long)(oap->line_count - 2), FALSE); + + n = (oap->end.col + 1 - !oap->inclusive); +! if (oap->inclusive && delete_last_line + && n > (int)STRLEN(ml_get(oap->end.lnum))) + { + /* Special case: gH deletes the last line. */ +*** ../vim-7.3.451/src/version.c 2012-02-22 16:01:53.000000000 +0100 +--- src/version.c 2012-02-22 17:37:18.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 452, + /**/ + +-- +From "know your smileys": + =):-) Uncle Sam + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 33144356d63b2f6c0237b5fa2feb2e8c5f370fd9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:47 +0100 Subject: [PATCH 0183/3340] - patchlevel 453 --- 7.3.453 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.453 diff --git a/7.3.453 b/7.3.453 new file mode 100644 index 00000000..cf0f0e71 --- /dev/null +++ b/7.3.453 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.453 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.453 +Problem: Pasting in the command line is slow. +Solution: Don't redraw if there is another character to read. (Dominique + Pelle) +Files: src/ex_getln.c + + +*** ../vim-7.3.452/src/ex_getln.c 2012-02-22 14:58:24.000000000 +0100 +--- src/ex_getln.c 2012-02-22 17:53:32.000000000 +0100 +*************** +*** 1852,1859 **** + # endif + ) + /* Always redraw the whole command line to fix shaping and +! * right-left typing. Not efficient, but it works. */ +! redrawcmd(); + #endif + } + +--- 1852,1862 ---- + # endif + ) + /* Always redraw the whole command line to fix shaping and +! * right-left typing. Not efficient, but it works. +! * Do it only when there are no characters left to read +! * to avoid useless intermediate redraws. */ +! if (vpeekc() == NUL) +! redrawcmd(); + #endif + } + +*** ../vim-7.3.452/src/version.c 2012-02-22 17:37:55.000000000 +0100 +--- src/version.c 2012-02-22 17:56:59.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 453, + /**/ + +-- +From "know your smileys": + <<<:-{ Worf (Never smiles anyways, so he's a bad smiley) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From cc8e676eddd23924aac1aaa9e76c78b73b3a0b52 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:48 +0100 Subject: [PATCH 0184/3340] - patchlevel 454 --- 7.3.454 | 84 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 7.3.454 diff --git a/7.3.454 b/7.3.454 new file mode 100644 index 00000000..8658926a --- /dev/null +++ b/7.3.454 @@ -0,0 +1,84 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.454 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.454 +Problem: Re-allocating memory slows Vim down. +Solution: Use realloc() in ga_grow(). (Dominique Pelle) +Files: src/misc2.c + + +*** ../vim-7.3.453/src/misc2.c 2012-02-22 14:58:24.000000000 +0100 +--- src/misc2.c 2012-02-22 18:07:45.000000000 +0100 +*************** +*** 2064,2087 **** + garray_T *gap; + int n; + { +! size_t len; + char_u *pp; + + if (gap->ga_maxlen - gap->ga_len < n) + { + if (n < gap->ga_growsize) + n = gap->ga_growsize; +! len = gap->ga_itemsize * (gap->ga_len + n); +! pp = alloc_clear((unsigned)len); + if (pp == NULL) + return FAIL; + gap->ga_maxlen = gap->ga_len + n; +- if (gap->ga_data != NULL) +- { +- mch_memmove(pp, gap->ga_data, +- (size_t)(gap->ga_itemsize * gap->ga_len)); +- vim_free(gap->ga_data); +- } + gap->ga_data = pp; + } + return OK; +--- 2064,2085 ---- + garray_T *gap; + int n; + { +! size_t old_len; +! size_t new_len; + char_u *pp; + + if (gap->ga_maxlen - gap->ga_len < n) + { + if (n < gap->ga_growsize) + n = gap->ga_growsize; +! new_len = gap->ga_itemsize * (gap->ga_len + n); +! pp = (gap->ga_data == NULL) +! ? alloc(new_len) : vim_realloc(gap->ga_data, new_len); + if (pp == NULL) + return FAIL; ++ old_len = gap->ga_itemsize * gap->ga_maxlen; ++ vim_memset(pp + old_len, 0, new_len - old_len); + gap->ga_maxlen = gap->ga_len + n; + gap->ga_data = pp; + } + return OK; +*** ../vim-7.3.453/src/version.c 2012-02-22 17:58:00.000000000 +0100 +--- src/version.c 2012-02-22 18:09:42.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 454, + /**/ + +-- +From "know your smileys": + (X0||) Double hamburger with lettuce and tomato + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bff263021a892a914bfaf9806600a1f3c59ade9b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:48 +0100 Subject: [PATCH 0185/3340] - patchlevel 455 --- 7.3.455 | 70 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 7.3.455 diff --git a/7.3.455 b/7.3.455 new file mode 100644 index 00000000..217b00d7 --- /dev/null +++ b/7.3.455 @@ -0,0 +1,70 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.455 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.455 +Problem: Using many continuation lines can be slow. +Solution: Adjust the reallocation size to the current length. +Files: src/ex_cmds2.c + + +*** ../vim-7.3.454/src/ex_cmds2.c 2012-02-11 20:40:49.000000000 +0100 +--- src/ex_cmds2.c 2012-02-22 18:24:11.000000000 +0100 +*************** +*** 3448,3454 **** + { + garray_T ga; + +! ga_init2(&ga, (int)sizeof(char_u), 200); + ga_concat(&ga, line); + ga_concat(&ga, p + 1); + for (;;) +--- 3448,3454 ---- + { + garray_T ga; + +! ga_init2(&ga, (int)sizeof(char_u), 400); + ga_concat(&ga, line); + ga_concat(&ga, p + 1); + for (;;) +*************** +*** 3460,3465 **** +--- 3460,3474 ---- + p = skipwhite(sp->nextline); + if (*p != '\\') + break; ++ /* Adjust the growsize to the current length to speed up ++ * concatenating many lines. */ ++ if (ga.ga_len > 400) ++ { ++ if (ga.ga_len > 8000) ++ ga.ga_growsize = 8000; ++ else ++ ga.ga_growsize = ga.ga_len; ++ } + ga_concat(&ga, p + 1); + } + ga_append(&ga, NUL); +*** ../vim-7.3.454/src/version.c 2012-02-22 18:12:29.000000000 +0100 +--- src/version.c 2012-02-22 18:24:58.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 455, + /**/ + +-- +From "know your smileys": + :-X My lips are sealed + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d5f1ea5711b52ddf1373d8b3ad8e2c9818f0ac47 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:48 +0100 Subject: [PATCH 0186/3340] - patchlevel 456 --- 7.3.456 | 376 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 376 insertions(+) create mode 100644 7.3.456 diff --git a/7.3.456 b/7.3.456 new file mode 100644 index 00000000..26fc2a98 --- /dev/null +++ b/7.3.456 @@ -0,0 +1,376 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.456 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.456 +Problem: ":tab drop file" has several problems, including moving the + current window and opening a new tab for a file that already has a + window. +Solution: Refactor ":tab drop" handling. (Hirohito Higashi) +Files: src/buffer.c, src/testdir/test62.in, src/testdir/test62.ok + + +*** ../vim-7.3.455/src/buffer.c 2012-02-22 14:58:24.000000000 +0100 +--- src/buffer.c 2012-02-22 19:08:34.000000000 +0100 +*************** +*** 4405,4411 **** + { + int i; + win_T *wp, *wpnext; +! char_u *opened; /* array of flags for which args are open */ + int opened_len; /* length of opened[] */ + int use_firstwin = FALSE; /* use first window for arglist */ + int split_ret = OK; +--- 4405,4416 ---- + { + int i; + win_T *wp, *wpnext; +! char_u *opened; /* Array of weight for which args are open: +! * 0: not opened +! * 1: opened in other tab +! * 2: opened in curtab +! * 3: opened in curtab and curwin +! */ + int opened_len; /* length of opened[] */ + int use_firstwin = FALSE; /* use first window for arglist */ + int split_ret = OK; +*************** +*** 4414,4419 **** +--- 4419,4426 ---- + buf_T *buf; + tabpage_T *tpnext; + int had_tab = cmdmod.tab; ++ win_T *old_curwin, *last_curwin; ++ tabpage_T *old_curtab, *last_curtab; + win_T *new_curwin = NULL; + tabpage_T *new_curtab = NULL; + +*************** +*** 4430,4435 **** +--- 4437,4451 ---- + if (opened == NULL) + return; + ++ /* Autocommands may do anything to the argument list. Make sure it's not ++ * freed while we are working here by "locking" it. We still have to ++ * watch out for its size to be changed. */ ++ alist = curwin->w_alist; ++ ++alist->al_refcount; ++ ++ old_curwin = curwin; ++ old_curtab = curtab; ++ + #ifdef FEAT_GUI + need_mouse_correct = TRUE; + #endif +*************** +*** 4451,4486 **** + wpnext = wp->w_next; + buf = wp->w_buffer; + if (buf->b_ffname == NULL +! || buf->b_nwindows > 1 + #ifdef FEAT_VERTSPLIT + || wp->w_width != Columns + #endif + ) +! i = ARGCOUNT; + else + { + /* check if the buffer in this window is in the arglist */ +! for (i = 0; i < ARGCOUNT; ++i) + { +! if (ARGLIST[i].ae_fnum == buf->b_fnum +! || fullpathcmp(alist_name(&ARGLIST[i]), +! buf->b_ffname, TRUE) & FPC_SAME) + { +! if (i < opened_len) + { +! opened[i] = TRUE; + if (i == 0) + { + new_curwin = wp; + new_curtab = curtab; + } + } +! if (wp->w_alist != curwin->w_alist) + { + /* Use the current argument list for all windows + * containing a file from it. */ + alist_unlink(wp->w_alist); +! wp->w_alist = curwin->w_alist; + ++wp->w_alist->al_refcount; + } + break; +--- 4467,4517 ---- + wpnext = wp->w_next; + buf = wp->w_buffer; + if (buf->b_ffname == NULL +! || (!keep_tabs && buf->b_nwindows > 1) + #ifdef FEAT_VERTSPLIT + || wp->w_width != Columns + #endif + ) +! i = opened_len; + else + { + /* check if the buffer in this window is in the arglist */ +! for (i = 0; i < opened_len; ++i) + { +! if (i < alist->al_ga.ga_len +! && (AARGLIST(alist)[i].ae_fnum == buf->b_fnum +! || fullpathcmp(alist_name(&AARGLIST(alist)[i]), +! buf->b_ffname, TRUE) & FPC_SAME)) + { +! int weight = 1; +! +! if (old_curtab == curtab) +! { +! ++weight; +! if (old_curwin == wp) +! ++weight; +! } +! +! if (weight > (int)opened[i]) + { +! opened[i] = (char_u)weight; + if (i == 0) + { ++ if (new_curwin != NULL) ++ new_curwin->w_arg_idx = opened_len; + new_curwin = wp; + new_curtab = curtab; + } + } +! else if (keep_tabs) +! i = opened_len; +! +! if (wp->w_alist != alist) + { + /* Use the current argument list for all windows + * containing a file from it. */ + alist_unlink(wp->w_alist); +! wp->w_alist = alist; + ++wp->w_alist->al_refcount; + } + break; +*************** +*** 4489,4495 **** + } + wp->w_arg_idx = i; + +! if (i == ARGCOUNT && !keep_tabs) /* close this window */ + { + if (P_HID(buf) || forceit || buf->b_nwindows > 1 + || !bufIsChanged(buf)) +--- 4520,4526 ---- + } + wp->w_arg_idx = i; + +! if (i == opened_len && !keep_tabs)/* close this window */ + { + if (P_HID(buf) || forceit || buf->b_nwindows > 1 + || !bufIsChanged(buf)) +*************** +*** 4511,4517 **** + } + #ifdef FEAT_WINDOWS + /* don't close last window */ +! if (firstwin == lastwin && first_tabpage->tp_next == NULL) + #endif + use_firstwin = TRUE; + #ifdef FEAT_WINDOWS +--- 4542,4549 ---- + } + #ifdef FEAT_WINDOWS + /* don't close last window */ +! if (firstwin == lastwin +! && (first_tabpage->tp_next == NULL || !had_tab)) + #endif + use_firstwin = TRUE; + #ifdef FEAT_WINDOWS +*************** +*** 4545,4564 **** + * Open a window for files in the argument list that don't have one. + * ARGCOUNT may change while doing this, because of autocommands. + */ +! if (count > ARGCOUNT || count <= 0) +! count = ARGCOUNT; +! +! /* Autocommands may do anything to the argument list. Make sure it's not +! * freed while we are working here by "locking" it. We still have to +! * watch out for its size to be changed. */ +! alist = curwin->w_alist; +! ++alist->al_refcount; + + #ifdef FEAT_AUTOCMD + /* Don't execute Win/Buf Enter/Leave autocommands here. */ + ++autocmd_no_enter; + ++autocmd_no_leave; + #endif + win_enter(lastwin, FALSE); + #ifdef FEAT_WINDOWS + /* ":drop all" should re-use an empty window to avoid "--remote-tab" +--- 4577,4592 ---- + * Open a window for files in the argument list that don't have one. + * ARGCOUNT may change while doing this, because of autocommands. + */ +! if (count > opened_len || count <= 0) +! count = opened_len; + + #ifdef FEAT_AUTOCMD + /* Don't execute Win/Buf Enter/Leave autocommands here. */ + ++autocmd_no_enter; + ++autocmd_no_leave; + #endif ++ last_curwin = curwin; ++ last_curtab = curtab; + win_enter(lastwin, FALSE); + #ifdef FEAT_WINDOWS + /* ":drop all" should re-use an empty window to avoid "--remote-tab" +*************** +*** 4568,4578 **** + use_firstwin = TRUE; + #endif + +! for (i = 0; i < count && i < alist->al_ga.ga_len && !got_int; ++i) + { + if (alist == &global_alist && i == global_alist.al_ga.ga_len - 1) + arg_had_last = TRUE; +! if (i < opened_len && opened[i]) + { + /* Move the already present window to below the current window */ + if (curwin->w_arg_idx != i) +--- 4596,4606 ---- + use_firstwin = TRUE; + #endif + +! for (i = 0; i < count && i < opened_len && !got_int; ++i) + { + if (alist == &global_alist && i == global_alist.al_ga.ga_len - 1) + arg_had_last = TRUE; +! if (opened[i] > 0) + { + /* Move the already present window to below the current window */ + if (curwin->w_arg_idx != i) +*************** +*** 4581,4587 **** + { + if (wpnext->w_arg_idx == i) + { +! win_move_after(wpnext, curwin); + break; + } + } +--- 4609,4621 ---- + { + if (wpnext->w_arg_idx == i) + { +! if (keep_tabs) +! { +! new_curwin = wpnext; +! new_curtab = curtab; +! } +! else +! win_move_after(wpnext, curwin); + break; + } + } +*************** +*** 4636,4641 **** +--- 4670,4683 ---- + #ifdef FEAT_AUTOCMD + --autocmd_no_enter; + #endif ++ /* restore last referenced tabpage's curwin */ ++ if (last_curtab != new_curtab) ++ { ++ if (valid_tabpage(last_curtab)) ++ goto_tabpage_tp(last_curtab); ++ if (win_valid(last_curwin)) ++ win_enter(last_curwin, FALSE); ++ } + /* to window with first arg */ + if (valid_tabpage(new_curtab)) + goto_tabpage_tp(new_curtab); +*** ../vim-7.3.455/src/testdir/test62.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test62.in 2012-02-22 18:45:10.000000000 +0100 +*************** +*** 50,55 **** +--- 50,92 ---- + :call append(line('$'), test_status) + :" + :" ++ :" Test for ":tab drop exist-file" to keep current window. ++ :sp test1 ++ :tab drop test1 ++ :let test_status = 'tab drop 1: fail' ++ :if tabpagenr('$') == 1 && winnr('$') == 2 && winnr() == 1 ++ : let test_status = 'tab drop 1: pass' ++ :endif ++ :close ++ :call append(line('$'), test_status) ++ :" ++ :" ++ :" Test for ":tab drop new-file" to keep current window of tabpage 1. ++ :split ++ :tab drop newfile ++ :let test_status = 'tab drop 2: fail' ++ :if tabpagenr('$') == 2 && tabpagewinnr(1, '$') == 2 && tabpagewinnr(1) == 1 ++ : let test_status = 'tab drop 2: pass' ++ :endif ++ :tabclose ++ :q ++ :call append(line('$'), test_status) ++ :" ++ :" ++ :" Test for ":tab drop multi-opend-file" to keep current tabpage and window. ++ :new test1 ++ :tabnew ++ :new test1 ++ :tab drop test1 ++ :let test_status = 'tab drop 3: fail' ++ :if tabpagenr() == 2 && tabpagewinnr(2, '$') == 2 && tabpagewinnr(2) == 1 ++ : let test_status = 'tab drop 3: pass' ++ :endif ++ :tabclose ++ :q ++ :call append(line('$'), test_status) ++ :" ++ :" + :/^Results/,$w! test.out + :qa! + ENDTEST +*** ../vim-7.3.455/src/testdir/test62.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test62.ok 2012-02-22 18:45:10.000000000 +0100 +*************** +*** 5,7 **** +--- 5,10 ---- + this is tab page 4 + gettabvar: pass + settabvar: pass ++ tab drop 1: pass ++ tab drop 2: pass ++ tab drop 3: pass +*** ../vim-7.3.455/src/version.c 2012-02-22 18:29:29.000000000 +0100 +--- src/version.c 2012-02-22 19:11:52.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 456, + /**/ + +-- +% cat /usr/include/life.h +void life(void); + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2356d03a53571f6d0c2c626f7d84d7fdd9373d00 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:48 +0100 Subject: [PATCH 0187/3340] - patchlevel 457 --- 7.3.457 | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 7.3.457 diff --git a/7.3.457 b/7.3.457 new file mode 100644 index 00000000..e60d6242 --- /dev/null +++ b/7.3.457 @@ -0,0 +1,81 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.457 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.457 +Problem: When setting $VIMRUNTIME later the directory for fetching + translated messages is not adjusted. +Solution: Put bindtextdomain() in vim_setenv(). +Files: src/misc1.c + + +*** ../vim-7.3.456/src/misc1.c 2012-02-05 22:05:44.000000000 +0100 +--- src/misc1.c 2012-02-26 13:27:28.000000000 +0100 +*************** +*** 4133,4149 **** + { + vim_setenv((char_u *)"VIMRUNTIME", p); + didset_vimruntime = TRUE; +- #ifdef FEAT_GETTEXT +- { +- char_u *buf = concat_str(p, (char_u *)"/lang"); +- +- if (buf != NULL) +- { +- bindtextdomain(VIMPACKAGE, (char *)buf); +- vim_free(buf); +- } +- } +- #endif + } + else + { +--- 4133,4138 ---- +*************** +*** 4221,4226 **** +--- 4210,4231 ---- + putenv((char *)envbuf); + } + #endif ++ #ifdef FEAT_GETTEXT ++ /* ++ * When setting $VIMRUNTIME adjust the directory to find message ++ * translations to $VIMRUNTIME/lang. ++ */ ++ if (*val != NUL && STRICMP(name, "VIMRUNTIME") == 0) ++ { ++ char_u *buf = concat_str(val, (char_u *)"/lang"); ++ ++ if (buf != NULL) ++ { ++ bindtextdomain(VIMPACKAGE, (char *)buf); ++ vim_free(buf); ++ } ++ } ++ #endif + } + + #if defined(FEAT_CMDL_COMPL) || defined(PROTO) +*** ../vim-7.3.456/src/version.c 2012-02-22 19:13:00.000000000 +0100 +--- src/version.c 2012-02-29 13:47:09.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 457, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +118. You are on a first-name basis with your ISP's staff. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 30bf611d317cdc3f3d56f11990cb12e9e550cbe6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:49 +0100 Subject: [PATCH 0188/3340] - patchlevel 458 --- 7.3.458 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.458 diff --git a/7.3.458 b/7.3.458 new file mode 100644 index 00000000..9bd44073 --- /dev/null +++ b/7.3.458 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.458 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.458 +Problem: Crash when calling smsg() during startup. +Solution: Don't use 'shortmess' when it is not set yet. +Files: src/option.c + + +*** ../vim-7.3.457/src/option.c 2012-02-20 22:18:22.000000000 +0100 +--- src/option.c 2012-02-26 13:14:48.000000000 +0100 +*************** +*** 10984,10990 **** + shortmess(x) + int x; + { +! return ( vim_strchr(p_shm, x) != NULL + || (vim_strchr(p_shm, 'a') != NULL + && vim_strchr((char_u *)SHM_A, x) != NULL)); + } +--- 10984,10991 ---- + shortmess(x) + int x; + { +! return p_shm != NULL && +! ( vim_strchr(p_shm, x) != NULL + || (vim_strchr(p_shm, 'a') != NULL + && vim_strchr((char_u *)SHM_A, x) != NULL)); + } +*** ../vim-7.3.457/src/version.c 2012-02-29 13:49:03.000000000 +0100 +--- src/version.c 2012-02-29 13:50:52.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 458, + /**/ + +-- +Support your right to bare arms! Wear short sleeves! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0cf258a91d3bd381f05eaa5f4504879f92370e21 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:49 +0100 Subject: [PATCH 0189/3340] - patchlevel 459 --- 7.3.459 | 71 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) create mode 100644 7.3.459 diff --git a/7.3.459 b/7.3.459 new file mode 100644 index 00000000..d75a38b4 --- /dev/null +++ b/7.3.459 @@ -0,0 +1,71 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.459 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.459 +Problem: Win32: Warnings for type conversion. +Solution: Add type casts. (Mike Williams) +Files: src/misc2.c, src/os_win32.c + + +*** ../vim-7.3.458/src/misc2.c 2012-02-22 18:12:29.000000000 +0100 +--- src/misc2.c 2012-02-29 13:44:17.000000000 +0100 +*************** +*** 2074,2080 **** + n = gap->ga_growsize; + new_len = gap->ga_itemsize * (gap->ga_len + n); + pp = (gap->ga_data == NULL) +! ? alloc(new_len) : vim_realloc(gap->ga_data, new_len); + if (pp == NULL) + return FAIL; + old_len = gap->ga_itemsize * gap->ga_maxlen; +--- 2074,2080 ---- + n = gap->ga_growsize; + new_len = gap->ga_itemsize * (gap->ga_len + n); + pp = (gap->ga_data == NULL) +! ? alloc((unsigned)new_len) : vim_realloc(gap->ga_data, new_len); + if (pp == NULL) + return FAIL; + old_len = gap->ga_itemsize * gap->ga_maxlen; +*** ../vim-7.3.458/src/os_win32.c 2012-02-22 15:34:05.000000000 +0100 +--- src/os_win32.c 2012-02-29 13:43:39.000000000 +0100 +*************** +*** 264,270 **** + static void + unescape_shellxquote(char_u *p, char_u *escaped) + { +! int l = STRLEN(p); + int n; + + while (*p != NUL) +--- 264,270 ---- + static void + unescape_shellxquote(char_u *p, char_u *escaped) + { +! int l = (int)STRLEN(p); + int n; + + while (*p != NUL) +*** ../vim-7.3.458/src/version.c 2012-02-29 13:51:32.000000000 +0100 +--- src/version.c 2012-02-29 13:58:08.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 459, + /**/ + +-- +"A clear conscience is usually the sign of a bad memory." + -- Steven Wright + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5ac2292e0b88c7d9d4dfbb8505ff39fbcbec13ff Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:49 +0100 Subject: [PATCH 0190/3340] - patchlevel 460 --- 7.3.460 | 89 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) create mode 100644 7.3.460 diff --git a/7.3.460 b/7.3.460 new file mode 100644 index 00000000..c1d7e85b --- /dev/null +++ b/7.3.460 @@ -0,0 +1,89 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.460 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.460 +Problem: Win32: UPX does not compress 64 bit binaries. +Solution: Mention and add the alternative: mpress. (Dave Bodenstab) +Files: src/INSTALLpc.txt, src/Make_ming.mak + + +*** ../vim-7.3.459/src/INSTALLpc.txt 2011-07-15 13:51:57.000000000 +0200 +--- src/INSTALLpc.txt 2012-02-29 14:01:34.000000000 +0100 +*************** +*** 239,244 **** +--- 239,250 ---- + found at + http://www.upx.org/ + ++ As of 2011, UPX still does not support compressing 64-bit EXE's; if you have ++ built a 64-bit vim then an alternative to UPX is 'MPRESS'. MPRESS can be found ++ at: ++ http://www.matcode.com/mpress.htm ++ ++ + ADDITION: NLS support with MinGW + + (by Eduardo F. Amatria ) +*** ../vim-7.3.459/src/Make_ming.mak 2011-10-12 14:11:43.000000000 +0200 +--- src/Make_ming.mak 2012-02-29 16:54:09.000000000 +0100 +*************** +*** 14,22 **** + # it's just run out of memory or something. Run again, and it will continue + # with 'xxd'. + # +! # "make upx" makes *compressed* versions of the GUI and console EXEs, using the +! # excellent UPX compressor: + # http://upx.sourceforge.net/ + # + # Maintained by Ron Aaron + # updated 2003 Jan 20 +--- 14,24 ---- + # it's just run out of memory or something. Run again, and it will continue + # with 'xxd'. + # +! # "make upx" makes *compressed* versions of the 32 bit GUI and console EXEs, +! # using the excellent UPX compressor: + # http://upx.sourceforge.net/ ++ # "make mpress" uses the MPRESS compressor for 32- and 64-bit EXEs: ++ # http://www.matcode.com/mpress.htm + # + # Maintained by Ron Aaron + # updated 2003 Jan 20 +*************** +*** 640,645 **** +--- 642,651 ---- + upx gvim.exe + upx vim.exe + ++ mpress: exes ++ mpress gvim.exe ++ mpress vim.exe ++ + xxd/xxd.exe: xxd/xxd.c + $(MAKE) -C xxd -f Make_ming.mak CC=$(CC) + +*** ../vim-7.3.459/src/version.c 2012-02-29 13:58:43.000000000 +0100 +--- src/version.c 2012-02-29 16:54:40.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 460, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +119. You are reading a book and look for the scroll bar to get to + the next page. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4e97607aff78f0b42fe4d4aaba483a6615707fad Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:50 +0100 Subject: [PATCH 0191/3340] - patchlevel 461 --- 7.3.461 | 243 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 243 insertions(+) create mode 100644 7.3.461 diff --git a/7.3.461 b/7.3.461 new file mode 100644 index 00000000..53c83c06 --- /dev/null +++ b/7.3.461 @@ -0,0 +1,243 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.461 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.461 +Problem: The InsertCharPre autocommand event is not triggered during + completion and when typing several characters quickly. +Solution: Also trigger InsertCharPre during completion. Do not read ahead + when an InsertCharPre autocommand is defined. (Yasuhiro Matsumoto) +Files: src/edit.c, src/fileio.c, src/proto/fileio.pro + + +*** ../vim-7.3.460/src/edit.c 2012-02-04 23:34:57.000000000 +0100 +--- src/edit.c 2012-02-29 18:17:31.000000000 +0100 +*************** +*** 259,264 **** +--- 259,267 ---- + static void ins_try_si __ARGS((int c)); + #endif + static colnr_T get_nolist_virtcol __ARGS((void)); ++ #ifdef FEAT_AUTOCMD ++ static char_u *do_insert_char_pre __ARGS((int c)); ++ #endif + + static colnr_T Insstart_textlen; /* length of line when insert started */ + static colnr_T Insstart_blank_vcol; /* vcol for first inserted blank */ +*************** +*** 784,790 **** + * completion: Add to "compl_leader". */ + if (ins_compl_accept_char(c)) + { +! ins_compl_addleader(c); + continue; + } + +--- 787,806 ---- + * completion: Add to "compl_leader". */ + if (ins_compl_accept_char(c)) + { +! #ifdef FEAT_AUTOCMD +! /* Trigger InsertCharPre. */ +! char_u *str = do_insert_char_pre(c); +! char_u *p; +! +! if (str != NULL) +! { +! for (p = str; *p != NUL; mb_ptr_adv(p)) +! ins_compl_addleader(PTR2CHAR(p)); +! vim_free(str); +! } +! else +! #endif +! ins_compl_addleader(c); + continue; + } + +*************** +*** 1393,1426 **** + #ifdef FEAT_AUTOCMD + if (!p_paste) + { +! /* Trigger the InsertCharPre event. Lock the text to avoid +! * weird things from happening. */ +! set_vim_var_char(c); +! ++textlock; +! if (apply_autocmds(EVENT_INSERTCHARPRE, NULL, NULL, +! FALSE, curbuf)) +! { +! /* Get the new value of v:char. If it is more than one +! * character insert it literally. */ +! char_u *s = get_vim_var_str(VV_CHAR); +! if (MB_CHARLEN(s) > 1) + { +! if (stop_arrow() != FAIL) + { +! ins_str(s); +! AppendToRedobuffLit(s, -1); + } +! c = NUL; + } +! else +! c = PTR2CHAR(s); + } + +! set_vim_var_string(VV_CHAR, NULL, -1); +! --textlock; +! +! /* If the new value is an empty string then don't insert a +! * char. */ + if (c == NUL) + break; + } +--- 1409,1439 ---- + #ifdef FEAT_AUTOCMD + if (!p_paste) + { +! /* Trigger InsertCharPre. */ +! char_u *str = do_insert_char_pre(c); +! char_u *p; +! +! if (str != NULL) +! { +! if (*str != NUL && stop_arrow() != FAIL) + { +! /* Insert the new value of v:char literally. */ +! for (p = str; *p != NUL; mb_ptr_adv(p)) + { +! c = PTR2CHAR(p); +! if (c == CAR || c == K_KENTER || c == NL) +! ins_eol(c); +! else +! ins_char(c); + } +! AppendToRedobuffLit(str, -1); + } +! vim_free(str); +! c = NUL; + } + +! /* If the new value is already inserted or an empty string +! * then don't insert any character. */ + if (c == NUL) + break; + } +*************** +*** 5883,5888 **** +--- 5896,5903 ---- + * Don't do this when 'cindent' or 'indentexpr' is set, because we might + * need to re-indent at a ':', or any other character (but not what + * 'paste' is set).. ++ * Don't do this when there an InsertCharPre autocommand is defined, ++ * because we need to fire the event for every character. + */ + #ifdef USE_ON_FLY_SCROLL + dont_scroll = FALSE; /* allow scrolling here */ +*************** +*** 5900,5905 **** +--- 5915,5923 ---- + #ifdef FEAT_RIGHTLEFT + && !p_ri + #endif ++ #ifdef FEAT_AUTOCMD ++ && !has_insertcharpre() ++ #endif + ) + { + #define INPUT_BUFLEN 100 +*************** +*** 10068,10070 **** +--- 10086,10123 ---- + validate_virtcol(); + return curwin->w_virtcol; + } ++ ++ #ifdef FEAT_AUTOCMD ++ /* ++ * Handle the InsertCharPre autocommand. ++ * "c" is the character that was typed. ++ * Return a pointer to allocated memory with the replacement string. ++ * Return NULL to continue inserting "c". ++ */ ++ static char_u * ++ do_insert_char_pre(c) ++ int c; ++ { ++ char_u *res; ++ ++ /* Return quickly when there is nothing to do. */ ++ if (!has_insertcharpre()) ++ return NULL; ++ ++ /* Lock the text to avoid weird things from happening. */ ++ ++textlock; ++ set_vim_var_char(c); /* set v:char */ ++ ++ if (apply_autocmds(EVENT_INSERTCHARPRE, NULL, NULL, FALSE, curbuf)) ++ /* Get the new value of v:char. It may be empty or more than one ++ * character. */ ++ res = vim_strsave(get_vim_var_str(VV_CHAR)); ++ else ++ res = NULL; ++ ++ set_vim_var_string(VV_CHAR, NULL, -1); /* clear v:char */ ++ --textlock; ++ ++ return res; ++ } ++ #endif +*** ../vim-7.3.460/src/fileio.c 2012-02-12 20:13:55.000000000 +0100 +--- src/fileio.c 2012-02-29 17:50:32.000000000 +0100 +*************** +*** 9116,9121 **** +--- 9116,9130 ---- + return (first_autopat[(int)EVENT_CURSORMOVEDI] != NULL); + } + ++ /* ++ * Return TRUE when there is an InsertCharPre autocommand defined. ++ */ ++ int ++ has_insertcharpre() ++ { ++ return (first_autopat[(int)EVENT_INSERTCHARPRE] != NULL); ++ } ++ + static int + apply_autocmds_group(event, fname, fname_io, force, group, buf, eap) + event_T event; +*** ../vim-7.3.460/src/proto/fileio.pro 2012-02-12 20:13:55.000000000 +0100 +--- src/proto/fileio.pro 2012-02-29 17:50:38.000000000 +0100 +*************** +*** 44,49 **** +--- 44,50 ---- + int trigger_cursorhold __ARGS((void)); + int has_cursormoved __ARGS((void)); + int has_cursormovedI __ARGS((void)); ++ int has_insertcharpre __ARGS((void)); + void block_autocmds __ARGS((void)); + void unblock_autocmds __ARGS((void)); + int has_autocmd __ARGS((event_T event, char_u *sfname, buf_T *buf)); +*** ../vim-7.3.460/src/version.c 2012-02-29 16:56:35.000000000 +0100 +--- src/version.c 2012-02-29 18:15:34.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 461, + /**/ + +-- +"Computers in the future may weigh no more than 1.5 tons." + Popular Mechanics, 1949 + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b1eb23dab4e2104a73ae5037181c4102f558f7b9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:50 +0100 Subject: [PATCH 0192/3340] - patchlevel 462 --- 7.3.462 | 191 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 191 insertions(+) create mode 100644 7.3.462 diff --git a/7.3.462 b/7.3.462 new file mode 100644 index 00000000..df037242 --- /dev/null +++ b/7.3.462 @@ -0,0 +1,191 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.462 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.462 +Problem: When using ":loadview" folds may be closed unexpectedly. +Solution: Take into account foldlevel. (Xavier de Gaye) +Files: src/fold.c + + +*** ../vim-7.3.461/src/fold.c 2012-01-10 22:26:12.000000000 +0100 +--- src/fold.c 2012-02-29 19:18:07.000000000 +0100 +*************** +*** 3292,3298 **** + /* put_folds() {{{2 */ + #if defined(FEAT_SESSION) || defined(PROTO) + static int put_folds_recurse __ARGS((FILE *fd, garray_T *gap, linenr_T off)); +! static int put_foldopen_recurse __ARGS((FILE *fd, garray_T *gap, linenr_T off)); + + /* + * Write commands to "fd" to restore the manual folds in window "wp". +--- 3292,3299 ---- + /* put_folds() {{{2 */ + #if defined(FEAT_SESSION) || defined(PROTO) + static int put_folds_recurse __ARGS((FILE *fd, garray_T *gap, linenr_T off)); +! static int put_foldopen_recurse __ARGS((FILE *fd, win_T *wp, garray_T *gap, linenr_T off)); +! static int put_fold_open_close __ARGS((FILE *fd, fold_T *fp, linenr_T off)); + + /* + * Write commands to "fd" to restore the manual folds in window "wp". +*************** +*** 3312,3318 **** + + /* If some folds are manually opened/closed, need to restore that. */ + if (wp->w_fold_manual) +! return put_foldopen_recurse(fd, &wp->w_folds, (linenr_T)0); + + return OK; + } +--- 3313,3319 ---- + + /* If some folds are manually opened/closed, need to restore that. */ + if (wp->w_fold_manual) +! return put_foldopen_recurse(fd, wp, &wp->w_folds, (linenr_T)0); + + return OK; + } +*************** +*** 3352,3363 **** + * Returns FAIL when writing failed. + */ + static int +! put_foldopen_recurse(fd, gap, off) + FILE *fd; + garray_T *gap; + linenr_T off; + { + int i; + fold_T *fp; + + fp = (fold_T *)gap->ga_data; +--- 3353,3366 ---- + * Returns FAIL when writing failed. + */ + static int +! put_foldopen_recurse(fd, wp, gap, off) + FILE *fd; ++ win_T *wp; + garray_T *gap; + linenr_T off; + { + int i; ++ int level; + fold_T *fp; + + fp = (fold_T *)gap->ga_data; +*************** +*** 3367,3393 **** + { + if (fp->fd_nested.ga_len > 0) + { +! /* open/close nested folds while this fold is open */ + if (fprintf(fd, "%ld", fp->fd_top + off) < 0 + || put_eol(fd) == FAIL + || put_line(fd, "normal zo") == FAIL) + return FAIL; +! if (put_foldopen_recurse(fd, &fp->fd_nested, off + fp->fd_top) + == FAIL) + return FAIL; + } +- if (fprintf(fd, "%ld", fp->fd_top + off) < 0 +- || put_eol(fd) == FAIL +- || fprintf(fd, "normal z%c", +- fp->fd_flags == FD_CLOSED ? 'c' : 'o') < 0 +- || put_eol(fd) == FAIL) +- return FAIL; + } + ++fp; + } + + return OK; + } + #endif /* FEAT_SESSION */ + + /* }}}1 */ +--- 3370,3429 ---- + { + if (fp->fd_nested.ga_len > 0) + { +! /* open nested folds while this fold is open */ + if (fprintf(fd, "%ld", fp->fd_top + off) < 0 + || put_eol(fd) == FAIL + || put_line(fd, "normal zo") == FAIL) + return FAIL; +! if (put_foldopen_recurse(fd, wp, &fp->fd_nested, +! off + fp->fd_top) + == FAIL) + return FAIL; ++ /* close the parent when needed */ ++ if (fp->fd_flags == FD_CLOSED) ++ { ++ if (put_fold_open_close(fd, fp, off) == FAIL) ++ return FAIL; ++ } ++ } ++ else ++ { ++ /* Open or close the leaf according to the window foldlevel. ++ * Do not close a leaf that is already closed, as it will close ++ * the parent. */ ++ level = foldLevelWin(wp, off + fp->fd_top); ++ if ((fp->fd_flags == FD_CLOSED && wp->w_p_fdl >= level) ++ || (fp->fd_flags != FD_CLOSED && wp->w_p_fdl < level)) ++ if (put_fold_open_close(fd, fp, off) == FAIL) ++ return FAIL; + } + } + ++fp; + } + + return OK; + } ++ ++ /* put_fold_open_close() {{{2 */ ++ /* ++ * Write the open or close command to "fd". ++ * Returns FAIL when writing failed. ++ */ ++ static int ++ put_fold_open_close(fd, fp, off) ++ FILE *fd; ++ fold_T *fp; ++ linenr_T off; ++ { ++ if (fprintf(fd, "%ld", fp->fd_top + off) < 0 ++ || put_eol(fd) == FAIL ++ || fprintf(fd, "normal z%c", ++ fp->fd_flags == FD_CLOSED ? 'c' : 'o') < 0 ++ || put_eol(fd) == FAIL) ++ return FAIL; ++ ++ return OK; ++ } + #endif /* FEAT_SESSION */ + + /* }}}1 */ +*** ../vim-7.3.461/src/version.c 2012-02-29 18:22:03.000000000 +0100 +--- src/version.c 2012-02-29 18:40:43.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 462, + /**/ + +-- +~ +~ +~ +".signature" 4 lines, 50 characters written + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8969a5c182abd1c8580ed10852d9ecdc6c9fdb37 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:50 +0100 Subject: [PATCH 0193/3340] - patchlevel 463 --- 7.3.463 | 63 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 7.3.463 diff --git a/7.3.463 b/7.3.463 new file mode 100644 index 00000000..1e7cb238 --- /dev/null +++ b/7.3.463 @@ -0,0 +1,63 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.463 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.463 +Problem: When using ":s///c" the cursor is moved away from the match. + (Lawman) +Solution: Don't move the cursor when do_ask is set. (Christian Brabandt) +Files: src/ex_cmds.c + + +*** ../vim-7.3.462/src/ex_cmds.c 2012-02-22 14:58:24.000000000 +0100 +--- src/ex_cmds.c 2012-03-07 14:54:21.000000000 +0100 +*************** +*** 5151,5160 **** + + if (!global_busy) + { +! if (endcolumn) +! coladvance((colnr_T)MAXCOL); +! else +! beginline(BL_WHITE | BL_FIX); + if (!do_sub_msg(do_count) && do_ask) + MSG(""); + } +--- 5151,5163 ---- + + if (!global_busy) + { +! if (!do_ask) /* when interactive leave cursor on the match */ +! { +! if (endcolumn) +! coladvance((colnr_T)MAXCOL); +! else +! beginline(BL_WHITE | BL_FIX); +! } + if (!do_sub_msg(do_count) && do_ask) + MSG(""); + } +*** ../vim-7.3.462/src/version.c 2012-02-29 19:19:57.000000000 +0100 +--- src/version.c 2012-03-07 14:55:39.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 463, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +151. You find yourself engaged to someone you've never actually met, + except through e-mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f86442843e4e2dad03ab0835e4ed2e9973810ed7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:51 +0100 Subject: [PATCH 0194/3340] - patchlevel 464 --- 7.3.464 | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 7.3.464 diff --git a/7.3.464 b/7.3.464 new file mode 100644 index 00000000..fdfdfffc --- /dev/null +++ b/7.3.464 @@ -0,0 +1,60 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.464 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.464 +Problem: Compiler warning for sprintf. +Solution: Put the length in a variable. (Dominique Pelle) +Files: src/version.c + + +*** ../vim-7.3.463/src/version.c 2012-03-07 14:57:50.000000000 +0100 +--- src/version.c 2012-03-07 17:58:41.000000000 +0100 +*************** +*** 2187,2198 **** + /* Check for 9.9x or 9.9xx, alpha/beta version */ + if (isalpha((int)vers[3])) + { +! if (isalpha((int)vers[4])) +! sprintf((char *)vers + 5, ".%d%s", highest_patch(), +! mediumVersion + 5); +! else +! sprintf((char *)vers + 4, ".%d%s", highest_patch(), +! mediumVersion + 4); + } + else + sprintf((char *)vers + 3, ".%d", highest_patch()); +--- 2189,2197 ---- + /* Check for 9.9x or 9.9xx, alpha/beta version */ + if (isalpha((int)vers[3])) + { +! int len = (isalpha((int)vers[4])) ? 5 : 4; +! sprintf((char *)vers + len, ".%d%s", highest_patch(), +! mediumVersion + len); + } + else + sprintf((char *)vers + 3, ".%d", highest_patch()); +*** ../vim-7.3.463/src/version.c 2012-03-07 14:57:50.000000000 +0100 +--- src/version.c 2012-03-07 17:58:41.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 464, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +152. You find yourself falling for someone you've never seen or hardly + know, but, boy can he/she TYPE!!!!!! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 962e0f64981327c91b45136af341c019d93a41ad Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:51 +0100 Subject: [PATCH 0195/3340] - patchlevel 465 --- 7.3.465 | 398 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 398 insertions(+) create mode 100644 7.3.465 diff --git a/7.3.465 b/7.3.465 new file mode 100644 index 00000000..c4a857ac --- /dev/null +++ b/7.3.465 @@ -0,0 +1,398 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.465 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.465 +Problem: Cannot get file name with newline from glob(). +Solution: Add argument to glob() and expand() to indicate they must return a + list. (Christian Brabandt) +Files: runtime/doc/eval.txt, src/eval.c, src/ex_getln.c, src/vim.h + + +*** ../vim-7.3.464/runtime/doc/eval.txt 2011-12-14 15:32:44.000000000 +0100 +--- runtime/doc/eval.txt 2012-03-07 18:49:26.000000000 +0100 +*************** +*** 1738,1744 **** + extend( {expr1}, {expr2} [, {expr3}]) + List/Dict insert items of {expr2} into {expr1} + exp( {expr}) Float exponential of {expr} +! expand( {expr} [, {flag}]) String expand special keywords in {expr} + feedkeys( {string} [, {mode}]) Number add key sequence to typeahead buffer + filereadable( {file}) Number TRUE if {file} is a readable file + filewritable( {file}) Number TRUE if {file} is a writable file +--- 1746,1753 ---- + extend( {expr1}, {expr2} [, {expr3}]) + List/Dict insert items of {expr2} into {expr1} + exp( {expr}) Float exponential of {expr} +! expand( {expr} [, {nosuf} [, {list}]]) +! any expand special keywords in {expr} + feedkeys( {string} [, {mode}]) Number add key sequence to typeahead buffer + filereadable( {file}) Number TRUE if {file} is a readable file + filewritable( {file}) Number TRUE if {file} is a writable file +*************** +*** 1792,1798 **** + getwinposx() Number X coord in pixels of GUI Vim window + getwinposy() Number Y coord in pixels of GUI Vim window + getwinvar( {nr}, {varname}) any variable {varname} in window {nr} +! glob( {expr} [, {flag}]) String expand file wildcards in {expr} + globpath( {path}, {expr} [, {flag}]) + String do glob({expr}) for all dirs in {path} + has( {feature}) Number TRUE if feature {feature} supported +--- 1801,1808 ---- + getwinposx() Number X coord in pixels of GUI Vim window + getwinposy() Number Y coord in pixels of GUI Vim window + getwinvar( {nr}, {varname}) any variable {varname} in window {nr} +! glob( {expr} [, {nosuf} [, {list}]]) +! any expand file wildcards in {expr} + globpath( {path}, {expr} [, {flag}]) + String do glob({expr}) for all dirs in {path} + has( {feature}) Number TRUE if feature {feature} supported +*************** +*** 2731,2743 **** + {only available when compiled with the |+float| feature} + + +! expand({expr} [, {flag}]) *expand()* + Expand wildcards and the following special keywords in {expr}. +! The result is a String. + +! When there are several matches, they are separated by +! characters. [Note: in version 5.0 a space was used, which +! caused problems when a file name contains a space] + + If the expansion fails, the result is an empty string. A name + for a non-existing file is not included. +--- 2744,2758 ---- + {only available when compiled with the |+float| feature} + + +! expand({expr} [, {nosuf} [, {list}]]) *expand()* + Expand wildcards and the following special keywords in {expr}. +! 'wildignorecase' applies. + +! If {list} is given and it is non-zero, a List will be returned. +! Otherwise the result is a String and when there are several +! matches, they are separated by characters. [Note: in +! version 5.0 a space was used, which caused problems when a +! file name contains a space] + + If the expansion fails, the result is an empty string. A name + for a non-existing file is not included. +*************** +*** 2754,2759 **** +--- 2769,2775 ---- + autocmd buffer number (as a String!) + autocmd matched name + sourced script file name ++ sourced script file line number + word under the cursor + WORD under the cursor + the {clientid} of the last received +*************** +*** 2790,2799 **** + When {expr} does not start with '%', '#' or '<', it is + expanded like a file name is expanded on the command line. + 'suffixes' and 'wildignore' are used, unless the optional +! {flag} argument is given and it is non-zero. Names for +! non-existing files are included. The "**" item can be used to +! search in a directory tree. For example, to find all "README" +! files in the current directory and below: > + :echo expand("**/README") + < + Expand() can also be used to expand variables and environment +--- 2806,2815 ---- + When {expr} does not start with '%', '#' or '<', it is + expanded like a file name is expanded on the command line. + 'suffixes' and 'wildignore' are used, unless the optional +! {nosuf} argument is given and it is non-zero. +! Names for non-existing files are included. The "**" item can +! be used to search in a directory tree. For example, to find +! all "README" files in the current directory and below: > + :echo expand("**/README") + < + Expand() can also be used to expand variables and environment +*************** +*** 3437,3453 **** + :let list_is_on = getwinvar(2, '&list') + :echo "myvar = " . getwinvar(1, 'myvar') + < +! glob({expr} [, {flag}]) *glob()* + Expand the file wildcards in {expr}. See |wildcards| for the + use of special characters. +! The result is a String. +! When there are several matches, they are separated by +! characters. +! Unless the optional {flag} argument is given and is non-zero, + the 'suffixes' and 'wildignore' options apply: Names matching + one of the patterns in 'wildignore' will be skipped and + 'suffixes' affect the ordering of matches. +! If the expansion fails, the result is an empty string. + A name for a non-existing file is not included. + + For most systems backticks can be used to get files names from +--- 3456,3478 ---- + :let list_is_on = getwinvar(2, '&list') + :echo "myvar = " . getwinvar(1, 'myvar') + < +! glob({expr} [, {nosuf} [, {list}]]) *glob()* + Expand the file wildcards in {expr}. See |wildcards| for the + use of special characters. +! +! Unless the optional {nosuf} argument is given and is non-zero, + the 'suffixes' and 'wildignore' options apply: Names matching + one of the patterns in 'wildignore' will be skipped and + 'suffixes' affect the ordering of matches. +! 'wildignorecase' always applies. +! +! When {list} is present and it is non-zero the result is a List +! with all matching files. The advantage of using a List is, +! you also get filenames containing newlines correctly. +! Otherwise the result is a String and when there are several +! matches, they are separated by characters. +! +! If the expansion fails, the result is an empty String or List. + A name for a non-existing file is not included. + + For most systems backticks can be used to get files names from +*** ../vim-7.3.464/src/eval.c 2012-02-11 20:44:01.000000000 +0100 +--- src/eval.c 2012-03-07 19:08:36.000000000 +0100 +*************** +*** 7852,7858 **** + #ifdef FEAT_FLOAT + {"exp", 1, 1, f_exp}, + #endif +! {"expand", 1, 2, f_expand}, + {"extend", 2, 3, f_extend}, + {"feedkeys", 1, 2, f_feedkeys}, + {"file_readable", 1, 1, f_filereadable}, /* obsolete */ +--- 7852,7858 ---- + #ifdef FEAT_FLOAT + {"exp", 1, 1, f_exp}, + #endif +! {"expand", 1, 3, f_expand}, + {"extend", 2, 3, f_extend}, + {"feedkeys", 1, 2, f_feedkeys}, + {"file_readable", 1, 1, f_filereadable}, /* obsolete */ +*************** +*** 7903,7909 **** + {"getwinposx", 0, 0, f_getwinposx}, + {"getwinposy", 0, 0, f_getwinposy}, + {"getwinvar", 2, 2, f_getwinvar}, +! {"glob", 1, 2, f_glob}, + {"globpath", 2, 3, f_globpath}, + {"has", 1, 1, f_has}, + {"has_key", 2, 2, f_has_key}, +--- 7903,7909 ---- + {"getwinposx", 0, 0, f_getwinposx}, + {"getwinposy", 0, 0, f_getwinposy}, + {"getwinvar", 2, 2, f_getwinvar}, +! {"glob", 1, 3, f_glob}, + {"globpath", 2, 3, f_globpath}, + {"has", 1, 1, f_has}, + {"has_key", 2, 2, f_has_key}, +*************** +*** 10019,10032 **** + int options = WILD_SILENT|WILD_USE_NL|WILD_LIST_NOTFOUND; + expand_T xpc; + int error = FALSE; + + rettv->v_type = VAR_STRING; + s = get_tv_string(&argvars[0]); + if (*s == '%' || *s == '#' || *s == '<') + { + ++emsg_off; +! rettv->vval.v_string = eval_vars(s, s, &len, NULL, &errormsg, NULL); + --emsg_off; + } + else + { +--- 10019,10051 ---- + int options = WILD_SILENT|WILD_USE_NL|WILD_LIST_NOTFOUND; + expand_T xpc; + int error = FALSE; ++ char_u *result; + + rettv->v_type = VAR_STRING; ++ if (argvars[1].v_type != VAR_UNKNOWN ++ && argvars[2].v_type != VAR_UNKNOWN ++ && get_tv_number_chk(&argvars[2], &error) ++ && !error) ++ { ++ rettv->v_type = VAR_LIST; ++ rettv->vval.v_list = NULL; ++ } ++ + s = get_tv_string(&argvars[0]); + if (*s == '%' || *s == '#' || *s == '<') + { + ++emsg_off; +! result = eval_vars(s, s, &len, NULL, &errormsg, NULL); + --emsg_off; ++ if (rettv->v_type == VAR_LIST) ++ { ++ if (rettv_list_alloc(rettv) != FAIL && result != NULL) ++ list_append_string(rettv->vval.v_list, result, -1); ++ else ++ vim_free(result); ++ } ++ else ++ rettv->vval.v_string = result; + } + else + { +*************** +*** 10041,10047 **** + xpc.xp_context = EXPAND_FILES; + if (p_wic) + options += WILD_ICASE; +! rettv->vval.v_string = ExpandOne(&xpc, s, NULL, options, WILD_ALL); + } + else + rettv->vval.v_string = NULL; +--- 10060,10077 ---- + xpc.xp_context = EXPAND_FILES; + if (p_wic) + options += WILD_ICASE; +! if (rettv->v_type == VAR_STRING) +! rettv->vval.v_string = ExpandOne(&xpc, s, NULL, +! options, WILD_ALL); +! else if (rettv_list_alloc(rettv) != FAIL) +! { +! int i; +! +! ExpandOne(&xpc, s, NULL, options, WILD_ALL_KEEP); +! for (i = 0; i < xpc.xp_numfiles; i++) +! list_append_string(rettv->vval.v_list, xpc.xp_files[i], -1); +! ExpandCleanup(&xpc); +! } + } + else + rettv->vval.v_string = NULL; +*************** +*** 11833,11851 **** + int error = FALSE; + + /* When the optional second argument is non-zero, don't remove matches +! * for 'wildignore' and don't put matches for 'suffixes' at the end. */ +! if (argvars[1].v_type != VAR_UNKNOWN +! && get_tv_number_chk(&argvars[1], &error)) +! options |= WILD_KEEP_ALL; + rettv->v_type = VAR_STRING; + if (!error) + { + ExpandInit(&xpc); + xpc.xp_context = EXPAND_FILES; + if (p_wic) + options += WILD_ICASE; +! rettv->vval.v_string = ExpandOne(&xpc, get_tv_string(&argvars[0]), + NULL, options, WILD_ALL); + } + else + rettv->vval.v_string = NULL; +--- 11863,11901 ---- + int error = FALSE; + + /* When the optional second argument is non-zero, don't remove matches +! * for 'wildignore' and don't put matches for 'suffixes' at the end. */ + rettv->v_type = VAR_STRING; ++ if (argvars[1].v_type != VAR_UNKNOWN) ++ { ++ if (get_tv_number_chk(&argvars[1], &error)) ++ options |= WILD_KEEP_ALL; ++ if (argvars[2].v_type != VAR_UNKNOWN ++ && get_tv_number_chk(&argvars[2], &error)) ++ { ++ rettv->v_type = VAR_LIST; ++ rettv->vval.v_list = NULL; ++ } ++ } + if (!error) + { + ExpandInit(&xpc); + xpc.xp_context = EXPAND_FILES; + if (p_wic) + options += WILD_ICASE; +! if (rettv->v_type == VAR_STRING) +! rettv->vval.v_string = ExpandOne(&xpc, get_tv_string(&argvars[0]), + NULL, options, WILD_ALL); ++ else if (rettv_list_alloc(rettv) != FAIL) ++ { ++ int i; ++ ++ ExpandOne(&xpc, get_tv_string(&argvars[0]), ++ NULL, options, WILD_ALL_KEEP); ++ for (i = 0; i < xpc.xp_numfiles; i++) ++ list_append_string(rettv->vval.v_list, xpc.xp_files[i], -1); ++ ++ ExpandCleanup(&xpc); ++ } + } + else + rettv->vval.v_string = NULL; +*** ../vim-7.3.464/src/ex_getln.c 2012-02-22 17:58:00.000000000 +0100 +--- src/ex_getln.c 2012-03-07 19:07:01.000000000 +0100 +*************** +*** 3461,3466 **** +--- 3461,3467 ---- + * mode = WILD_PREV: use previous match in multiple match, wrap to first + * mode = WILD_ALL: return all matches concatenated + * mode = WILD_LONGEST: return longest matched part ++ * mode = WILD_ALL_KEEP: get all matches, keep matches + * + * options = WILD_LIST_NOTFOUND: list entries without a match + * options = WILD_HOME_REPLACE: do home_replace() for buffer names +*************** +*** 3584,3590 **** + /* + * Check for matching suffixes in file names. + */ +! if (mode != WILD_ALL && mode != WILD_LONGEST) + { + if (xp->xp_numfiles) + non_suf_match = xp->xp_numfiles; +--- 3585,3592 ---- + /* + * Check for matching suffixes in file names. + */ +! if (mode != WILD_ALL && mode != WILD_ALL_KEEP +! && mode != WILD_LONGEST) + { + if (xp->xp_numfiles) + non_suf_match = xp->xp_numfiles; +*** ../vim-7.3.464/src/vim.h 2011-07-27 17:31:42.000000000 +0200 +--- src/vim.h 2012-03-07 19:03:43.000000000 +0100 +*************** +*** 794,799 **** +--- 794,800 ---- + #define WILD_PREV 5 + #define WILD_ALL 6 + #define WILD_LONGEST 7 ++ #define WILD_ALL_KEEP 8 + + #define WILD_LIST_NOTFOUND 1 + #define WILD_HOME_REPLACE 2 +*** ../vim-7.3.464/src/version.c 2012-03-07 18:04:00.000000000 +0100 +--- src/version.c 2012-03-07 19:14:39.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 465, + /**/ + +-- +Although the scythe isn't pre-eminent among the weapons of war, anyone who +has been on the wrong end of, say, a peasants' revolt will know that in +skilled hands it is fearsome. + -- (Terry Pratchett, Mort) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3e6a8718b7b0526a22b0fae0dad20abde3613103 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:51 +0100 Subject: [PATCH 0196/3340] - patchlevel 466 --- 7.3.466 | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 7.3.466 diff --git a/7.3.466 b/7.3.466 new file mode 100644 index 00000000..0dc42934 --- /dev/null +++ b/7.3.466 @@ -0,0 +1,49 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.466 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.466 +Problem: Get ml_get error when ":behave mswin" was used and selecting + several lines. (A. Sinan Unur) +Solution: Adjust the end of the operation. (Christian Brabandt) +Files: src/ops.c + + +*** ../vim-7.3.465/src/ops.c 2012-02-22 17:37:55.000000000 +0100 +--- src/ops.c 2012-03-07 19:27:08.000000000 +0100 +*************** +*** 1957,1962 **** +--- 1957,1965 ---- + ++curwin->w_cursor.lnum; + del_lines((long)(oap->line_count - 2), FALSE); + ++ if (delete_last_line) ++ oap->end.lnum = curbuf->b_ml.ml_line_count; ++ + n = (oap->end.col + 1 - !oap->inclusive); + if (oap->inclusive && delete_last_line + && n > (int)STRLEN(ml_get(oap->end.lnum))) +*** ../vim-7.3.465/src/version.c 2012-03-07 19:16:49.000000000 +0100 +--- src/version.c 2012-03-07 19:29:52.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 466, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +153. You find yourself staring at your "inbox" waiting for new e-mail + to arrive. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2619ed84e4a004319aa5ffd078db6099a4cdc448 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:52 +0100 Subject: [PATCH 0197/3340] - patchlevel 467 --- 7.3.467 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 7.3.467 diff --git a/7.3.467 b/7.3.467 new file mode 100644 index 00000000..7764217c --- /dev/null +++ b/7.3.467 @@ -0,0 +1,54 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.467 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.467 +Problem: Cursor positioned wrong at the command line when regaining focus + and using some input method. +Solution: Do not position the cursor in command line mode. +Files: src/mbyte.c + + +*** ../vim-7.3.466/src/mbyte.c 2011-12-08 15:09:46.000000000 +0100 +--- src/mbyte.c 2012-03-07 19:36:44.000000000 +0100 +*************** +*** 4504,4510 **** + vgetc_busy = TRUE; + showmode(); + vgetc_busy = old_vgetc_busy; +! setcursor(); + out_flush(); + } + +--- 4504,4511 ---- + vgetc_busy = TRUE; + showmode(); + vgetc_busy = old_vgetc_busy; +! if ((State & NORMAL) || (State & INSERT)) +! setcursor(); + out_flush(); + } + +*** ../vim-7.3.466/src/version.c 2012-03-07 19:30:32.000000000 +0100 +--- src/version.c 2012-03-07 19:38:22.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 467, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +154. You fondle your mouse. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8188525bec622ec53272f242e215ca95eda8618d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:52 +0100 Subject: [PATCH 0198/3340] - patchlevel 468 --- 7.3.468 | 144 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 144 insertions(+) create mode 100644 7.3.468 diff --git a/7.3.468 b/7.3.468 new file mode 100644 index 00000000..e078f9ea --- /dev/null +++ b/7.3.468 @@ -0,0 +1,144 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.468 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.468 +Problem: For some compilers the error file is not easily readable. +Solution: Use QuickFixCmdPre for more commands. (Marcin Szamotulski) +Files: runtime/doc/autocmd.txt, src/quickfix.c + + +*** ../vim-7.3.467/runtime/doc/autocmd.txt 2012-02-12 20:13:55.000000000 +0100 +--- runtime/doc/autocmd.txt 2012-03-07 20:07:23.000000000 +0100 +*************** +*** 695,701 **** + QuickFixCmdPre Before a quickfix command is run (|:make|, + |:lmake|, |:grep|, |:lgrep|, |:grepadd|, + |:lgrepadd|, |:vimgrep|, |:lvimgrep|, +! |:vimgrepadd|, |:lvimgrepadd|, |:cscope|). + The pattern is matched against the command + being run. When |:grep| is used but 'grepprg' + is set to "internal" it still matches "grep". +--- 699,708 ---- + QuickFixCmdPre Before a quickfix command is run (|:make|, + |:lmake|, |:grep|, |:lgrep|, |:grepadd|, + |:lgrepadd|, |:vimgrep|, |:lvimgrep|, +! |:vimgrepadd|, |:lvimgrepadd|, |:cscope|, +! |:cfile|, |:cgetfile|, |:caddfile|, |:lfile|, +! |:lgetfile|, |:laddfile|, |:helpgrep|, +! |:lhelpgrep|). + The pattern is matched against the command + being run. When |:grep| is used but 'grepprg' + is set to "internal" it still matches "grep". +*************** +*** 706,712 **** + *QuickFixCmdPost* + QuickFixCmdPost Like QuickFixCmdPre, but after a quickfix + command is run, before jumping to the first +! location. See |QuickFixCmdPost-example|. + *RemoteReply* + RemoteReply When a reply from a Vim that functions as + server was received |server2client()|. The +--- 713,722 ---- + *QuickFixCmdPost* + QuickFixCmdPost Like QuickFixCmdPre, but after a quickfix + command is run, before jumping to the first +! location. For |:cfile| and |:lfile| commands +! it is run after error file is read and before +! moving to the first error. +! See |QuickFixCmdPost-example|. + *RemoteReply* + RemoteReply When a reply from a Vim that functions as + server was received |server2client()|. The +*** ../vim-7.3.467/src/quickfix.c 2012-02-22 14:58:24.000000000 +0100 +--- src/quickfix.c 2012-03-07 20:10:07.000000000 +0100 +*************** +*** 2995,3005 **** + { + win_T *wp = NULL; + qf_info_T *qi = &ql_info; + + if (eap->cmdidx == CMD_lfile || eap->cmdidx == CMD_lgetfile +! || eap->cmdidx == CMD_laddfile) + wp = curwin; + + #ifdef FEAT_BROWSE + if (cmdmod.browse) + { +--- 2995,3022 ---- + { + win_T *wp = NULL; + qf_info_T *qi = &ql_info; ++ #ifdef FEAT_AUTOCMD ++ char_u *au_name = NULL; ++ #endif + + if (eap->cmdidx == CMD_lfile || eap->cmdidx == CMD_lgetfile +! || eap->cmdidx == CMD_laddfile) + wp = curwin; + ++ #ifdef FEAT_AUTOCMD ++ switch (eap->cmdidx) ++ { ++ case CMD_cfile: au_name = (char_u *)"cfile"; break; ++ case CMD_cgetfile: au_name = (char_u *)"cgetfile"; break; ++ case CMD_caddfile: au_name = (char_u *)"caddfile"; break; ++ case CMD_lfile: au_name = (char_u *)"lfile"; break; ++ case CMD_lgetfile: au_name = (char_u *)"lgetfile"; break; ++ case CMD_laddfile: au_name = (char_u *)"laddfile"; break; ++ default: break; ++ } ++ if (au_name != NULL) ++ apply_autocmds(EVENT_QUICKFIXCMDPRE, au_name, NULL, FALSE, curbuf); ++ #endif + #ifdef FEAT_BROWSE + if (cmdmod.browse) + { +*************** +*** 3031,3040 **** +--- 3048,3069 ---- + && (eap->cmdidx == CMD_cfile + || eap->cmdidx == CMD_lfile)) + { ++ #ifdef FEAT_AUTOCMD ++ if (au_name != NULL) ++ apply_autocmds(EVENT_QUICKFIXCMDPOST, au_name, NULL, FALSE, curbuf); ++ #endif + if (wp != NULL) + qi = GET_LOC_LIST(wp); + qf_jump(qi, 0, 0, eap->forceit); /* display first error */ + } ++ ++ else ++ { ++ #ifdef FEAT_AUTOCMD ++ if (au_name != NULL) ++ apply_autocmds(EVENT_QUICKFIXCMDPOST, au_name, NULL, FALSE, curbuf); ++ #endif ++ } + } + + /* +*** ../vim-7.3.467/src/version.c 2012-03-07 19:38:52.000000000 +0100 +--- src/version.c 2012-03-07 20:11:54.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 468, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +155. You forget to eat because you're too busy surfing the net. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e983b749aea54b8813fe167979b5bc63195da55a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:52 +0100 Subject: [PATCH 0199/3340] - patchlevel 469 --- 7.3.469 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.469 diff --git a/7.3.469 b/7.3.469 new file mode 100644 index 00000000..77ca4a05 --- /dev/null +++ b/7.3.469 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.469 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.469 +Problem: Compiler warning for unused argument without some features. +Solution: Add UNUSED. +Files: src/buffer.c + + +*** ../vim-7.3.468/src/buffer.c 2012-02-22 19:13:00.000000000 +0100 +--- src/buffer.c 2012-03-07 22:30:56.000000000 +0100 +*************** +*** 329,335 **** + win_T *win; /* if not NULL, set b_last_cursor */ + buf_T *buf; + int action; +! int abort_if_last; + { + #ifdef FEAT_AUTOCMD + int is_curbuf; +--- 329,335 ---- + win_T *win; /* if not NULL, set b_last_cursor */ + buf_T *buf; + int action; +! int abort_if_last UNUSED; + { + #ifdef FEAT_AUTOCMD + int is_curbuf; +*** ../vim-7.3.468/src/version.c 2012-03-07 20:13:44.000000000 +0100 +--- src/version.c 2012-03-07 22:51:54.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 469, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +157. You fum through a magazine, you first check to see if it has a web + address. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2e7c51897ed4e5386c2a417c74647736288f1ee7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:52 +0100 Subject: [PATCH 0200/3340] - patchlevel 470 --- 7.3.470 | 67 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 7.3.470 diff --git a/7.3.470 b/7.3.470 new file mode 100644 index 00000000..80bec156 --- /dev/null +++ b/7.3.470 @@ -0,0 +1,67 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.470 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.470 +Problem: Test 62 fails when compiled without GUI and X11. +Solution: Don't test :drop when it is not supported. +Files: src/testdir/test62.in + + +*** ../vim-7.3.469/src/testdir/test62.in 2012-02-22 19:13:00.000000000 +0100 +--- src/testdir/test62.in 2012-03-07 22:46:17.000000000 +0100 +*************** +*** 49,55 **** + :tabclose + :call append(line('$'), test_status) + :" +! :" + :" Test for ":tab drop exist-file" to keep current window. + :sp test1 + :tab drop test1 +--- 49,55 ---- + :tabclose + :call append(line('$'), test_status) + :" +! :if has('gui') || has('clientserver') + :" Test for ":tab drop exist-file" to keep current window. + :sp test1 + :tab drop test1 +*************** +*** 85,90 **** +--- 85,96 ---- + :tabclose + :q + :call append(line('$'), test_status) ++ :else ++ :" :drop not supported ++ :call append(line('$'), 'tab drop 1: pass') ++ :call append(line('$'), 'tab drop 2: pass') ++ :call append(line('$'), 'tab drop 3: pass') ++ :endif + :" + :" + :/^Results/,$w! test.out +*** ../vim-7.3.469/src/version.c 2012-03-07 22:52:30.000000000 +0100 +--- src/version.c 2012-03-07 22:53:40.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 470, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +158. You get a tuner card so you can watch TV while surfing. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 41723464ddfc8966996c25e1f2f06b3a07e7e2e6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:53 +0100 Subject: [PATCH 0201/3340] - patchlevel 471 --- 7.3.471 | 92 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 92 insertions(+) create mode 100644 7.3.471 diff --git a/7.3.471 b/7.3.471 new file mode 100644 index 00000000..be814324 --- /dev/null +++ b/7.3.471 @@ -0,0 +1,92 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.471 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.471 +Problem: Can't abort listing placed signs. +Solution: Check "got_int". (Christian Brabandt) +Files: src/buffer.c, src/ex_cmds.c + + +*** ../vim-7.3.470/src/buffer.c 2012-03-07 22:52:30.000000000 +0100 +--- src/buffer.c 2012-03-16 13:54:48.000000000 +0100 +*************** +*** 5557,5563 **** + buf = firstbuf; + else + buf = rbuf; +! while (buf != NULL) + { + if (buf->b_signlist != NULL) + { +--- 5557,5563 ---- + buf = firstbuf; + else + buf = rbuf; +! while (buf != NULL && !got_int) + { + if (buf->b_signlist != NULL) + { +*************** +*** 5565,5571 **** + MSG_PUTS_ATTR(lbuf, hl_attr(HLF_D)); + msg_putchar('\n'); + } +! for (p = buf->b_signlist; p != NULL; p = p->next) + { + vim_snprintf(lbuf, BUFSIZ, _(" line=%ld id=%d name=%s"), + (long)p->lnum, p->id, sign_typenr2name(p->typenr)); +--- 5565,5571 ---- + MSG_PUTS_ATTR(lbuf, hl_attr(HLF_D)); + msg_putchar('\n'); + } +! for (p = buf->b_signlist; p != NULL && !got_int; p = p->next) + { + vim_snprintf(lbuf, BUFSIZ, _(" line=%ld id=%d name=%s"), + (long)p->lnum, p->id, sign_typenr2name(p->typenr)); +*** ../vim-7.3.470/src/ex_cmds.c 2012-03-07 14:57:50.000000000 +0100 +--- src/ex_cmds.c 2012-03-16 13:58:50.000000000 +0100 +*************** +*** 6729,6735 **** + if (idx == SIGNCMD_LIST && *arg == NUL) + { + /* ":sign list": list all defined signs */ +! for (sp = first_sign; sp != NULL; sp = sp->sn_next) + sign_list_defined(sp); + } + else if (*arg == NUL) +--- 6729,6735 ---- + if (idx == SIGNCMD_LIST && *arg == NUL) + { + /* ":sign list": list all defined signs */ +! for (sp = first_sign; sp != NULL && !got_int; sp = sp->sn_next) + sign_list_defined(sp); + } + else if (*arg == NUL) +*** ../vim-7.3.470/src/version.c 2012-03-07 22:55:17.000000000 +0100 +--- src/version.c 2012-03-16 13:55:28.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 471, + /**/ + +-- +Some of the well know MS-Windows errors: + EMEMORY Memory error caused by..., eh... + ELICENSE Your license has expired, give us more money! + EMOUSE Mouse moved, reinstall Windows + EILLEGAL Illegal error, you are not allowed to see this + EVIRUS Undetectable virus found + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0d5b4b0abcc10061184d3fcfce77c17b8fb59572 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 16 Mar 2012 18:44:53 +0100 Subject: [PATCH 0202/3340] - patchlevel 471 --- README.patches | 27 +++++++++++++++++++++++ vim.spec | 59 +++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 85 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index 39d64247..d42ea558 100644 --- a/README.patches +++ b/README.patches @@ -475,3 +475,30 @@ Individual patches for Vim 7.3: 5445 7.3.442 (after 7.3.438) still read modelines for ":doautocmd" 8329 7.3.443 MS-Windows: 'shcf' and 'sxq' defaults are not very good 3159 7.3.444 ":all!" and ":sall!" give error E477 + 6224 7.3.445 (after 7.3.443) can't properly escape commands for cmd.exe + 5338 7.3.446 (after 7.3.445) external command with special char doesnt work + 10262 7.3.447 (after 7.3.446) External commands with "start" do not work + 5192 7.3.448 (after 7.3.447) Win32: Still a problem with "!start /b" + 15177 7.3.449 crash when a BufWinLeave autocmd closes the only other window + 2359 7.3.450 (after 7.3.448) Win32: Still a problem with "!start /b" + 10656 7.3.451 Tcl doesn't work on 64 bit MS-Windows + 2329 7.3.452 undo broken when pasting close to the last line + 1718 7.3.453 pasting in the command line is slow + 2299 7.3.454 re-allocating memory slows Vim down + 1891 7.3.455 using many continuation lines can be slow + 10445 7.3.456 ":tab drop file" handling doesn't work well + 2123 7.3.457 message translation dir not set when setting $VIMRUNTIME later + 1532 7.3.458 crash when calling smsg() during startup + 2196 7.3.459 compiler warnings for types on Windows + 2785 7.3.460 Win32: UPX does not compress 64 bit binaries + 6734 7.3.461 InsertCharPre event not always triggered + 5129 7.3.462 when using ":loadview" folds may be closed unexpectedly + 1774 7.3.463 cursor moved after using ":s///c" + 1969 7.3.464 compiler warning for sprintf + 14135 7.3.465 cannot get file name with newline from glob() + 1606 7.3.466 ml_get error when replacing several selected lines + 1526 7.3.467 cursor position wrong at command line when using input method + 4775 7.3.468 for some compilers the error file is not easily readable + 1557 7.3.469 compiler warning for unused argument + 1892 7.3.470 test 62 fails when compiled without GUI and X11 + 2817 7.3.471 can't abort listing placed signs diff --git a/vim.spec b/vim.spec index 0ef1f82c..2a10394b 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 444 +%define patchlevel 471 Summary: The VIM editor URL: http://www.vim.org/ @@ -500,6 +500,33 @@ Patch441: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.441 Patch442: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.442 Patch443: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.443 Patch444: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.444 +Patch445: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.445 +Patch446: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.446 +Patch447: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.447 +Patch448: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.448 +Patch449: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.449 +Patch450: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.450 +Patch451: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.451 +Patch452: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.452 +Patch453: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.453 +Patch454: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.454 +Patch455: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.455 +Patch456: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.456 +Patch457: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.457 +Patch458: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.458 +Patch459: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.459 +Patch460: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.460 +Patch461: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.461 +Patch462: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.462 +Patch463: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.463 +Patch464: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.464 +Patch465: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.465 +Patch466: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.466 +Patch467: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.467 +Patch468: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.468 +Patch469: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.469 +Patch470: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.470 +Patch471: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.471 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1089,6 +1116,33 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch442 -p0 %patch443 -p0 %patch444 -p0 +%patch445 -p0 +%patch446 -p0 +%patch447 -p0 +%patch448 -p0 +%patch449 -p0 +%patch450 -p0 +%patch451 -p0 +%patch452 -p0 +%patch453 -p0 +%patch454 -p0 +%patch455 -p0 +%patch456 -p0 +%patch457 -p0 +%patch458 -p0 +%patch459 -p0 +%patch460 -p0 +%patch461 -p0 +%patch462 -p0 +%patch463 -p0 +%patch464 -p0 +%patch465 -p0 +%patch466 -p0 +%patch467 -p0 +%patch468 -p0 +%patch469 -p0 +%patch470 -p0 +%patch471 -p0 # install spell files @@ -1543,6 +1597,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Fri Mar 16 2012 Karsten Hopp 7.3.471-1 +- patchlevel 471 + * Mon Feb 13 2012 Karsten Hopp 7.3.444-1 - patchlevel 444 From 0ff37bc37ac8fea9c34e8d601511c04cdfa5007b Mon Sep 17 00:00:00 2001 From: Daniel Mach Date: Wed, 11 Apr 2012 07:59:18 +0200 Subject: [PATCH 0203/3340] Rebuild for ruby --- vim.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vim.spec b/vim.spec index 2a10394b..cbb09309 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1%{?dist} +Release: 1.1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -1597,6 +1597,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Wed Apr 11 2012 Daniel Mach - 2:7.3.471-1.1 +- Rebuild for ruby + * Fri Mar 16 2012 Karsten Hopp 7.3.471-1 - patchlevel 471 From 240837eb4513a05e2954f56f8397d35678d5fc4f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:10 +0200 Subject: [PATCH 0204/3340] - patchlevel 472 --- 7.3.472 | 88 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 88 insertions(+) create mode 100644 7.3.472 diff --git a/7.3.472 b/7.3.472 new file mode 100644 index 00000000..217b2fc9 --- /dev/null +++ b/7.3.472 @@ -0,0 +1,88 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.472 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.472 +Problem: Crash when using ":redraw" in a BufEnter autocommand and + switching to another tab. (驼峰) +Solution: Move triggering the the autocommands to after correcting the + option values. Also check the row value to be out of bounds. + (Christian Brabandt, Sergey Khorev) +Files: src/screen.c, src/window.c + + +*** ../vim-7.3.471/src/screen.c 2012-02-04 23:34:57.000000000 +0100 +--- src/screen.c 2012-03-16 18:59:20.000000000 +0100 +*************** +*** 5371,5376 **** +--- 5371,5382 ---- + # define CHAR_CELLS 1 + #endif + ++ /* Check for illegal row and col, just in case. */ ++ if (row >= Rows) ++ row = Rows - 1; ++ if (endcol > Columns) ++ endcol = Columns; ++ + # ifdef FEAT_CLIPBOARD + clip_may_clear_selection(row, row); + # endif +*** ../vim-7.3.471/src/window.c 2012-02-22 14:58:24.000000000 +0100 +--- src/window.c 2012-03-16 18:43:01.000000000 +0100 +*************** +*** 3676,3688 **** + win_enter_ext(tp->tp_curwin, FALSE, TRUE); + prevwin = next_prevwin; + +- #ifdef FEAT_AUTOCMD +- apply_autocmds(EVENT_TABENTER, NULL, NULL, FALSE, curbuf); +- +- if (old_curbuf != curbuf) +- apply_autocmds(EVENT_BUFENTER, NULL, NULL, FALSE, curbuf); +- #endif +- + last_status(FALSE); /* status line may appear or disappear */ + (void)win_comp_pos(); /* recompute w_winrow for all windows */ + must_redraw = CLEAR; /* need to redraw everything */ +--- 3676,3681 ---- +*************** +*** 3712,3717 **** +--- 3705,3718 ---- + gui_may_update_scrollbars(); + #endif + ++ #ifdef FEAT_AUTOCMD ++ /* Apply autocommands after updating the display, when 'rows' and ++ * 'columns' have been set correctly. */ ++ apply_autocmds(EVENT_TABENTER, NULL, NULL, FALSE, curbuf); ++ if (old_curbuf != curbuf) ++ apply_autocmds(EVENT_BUFENTER, NULL, NULL, FALSE, curbuf); ++ #endif ++ + redraw_all_later(CLEAR); + } + +*** ../vim-7.3.471/src/version.c 2012-03-16 14:32:10.000000000 +0100 +--- src/version.c 2012-03-16 19:02:53.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 472, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +200. You really believe in the concept of a "paperless" office. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ceb597d3095e76649f0912e5adf98ecdc21c7757 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:11 +0200 Subject: [PATCH 0205/3340] - patchlevel 473 --- 7.3.473 | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 7.3.473 diff --git a/7.3.473 b/7.3.473 new file mode 100644 index 00000000..571f85da --- /dev/null +++ b/7.3.473 @@ -0,0 +1,68 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.473 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.473 +Problem: 'cursorbind' does not work correctly in combination with + 'virtualedit' set to "all". +Solution: Copy coladd. (Gary Johnson) +Files: src/move.c + + +*** ../vim-7.3.472/src/move.c 2012-02-04 23:34:57.000000000 +0100 +--- src/move.c 2012-03-16 19:20:57.000000000 +0100 +*************** +*** 2843,2849 **** + do_check_cursorbind() + { + linenr_T line = curwin->w_cursor.lnum; +! colnr_T col = curwin->w_cursor.col; + win_T *old_curwin = curwin; + buf_T *old_curbuf = curbuf; + int restart_edit_save; +--- 2843,2852 ---- + do_check_cursorbind() + { + linenr_T line = curwin->w_cursor.lnum; +! colnr_T col = curwin->w_cursor.col; +! # ifdef FEAT_VIRTUALEDIT +! colnr_T coladd = curwin->w_cursor.coladd; +! # endif + win_T *old_curwin = curwin; + buf_T *old_curbuf = curbuf; + int restart_edit_save; +*************** +*** 2875,2880 **** +--- 2878,2886 ---- + # endif + curwin->w_cursor.lnum = line; + curwin->w_cursor.col = col; ++ # ifdef FEAT_VIRTUALEDIT ++ curwin->w_cursor.coladd = coladd; ++ # endif + + /* Make sure the cursor is in a valid position. Temporarily set + * "restart_edit" to allow the cursor to be beyond the EOL. */ +*** ../vim-7.3.472/src/version.c 2012-03-16 19:07:54.000000000 +0100 +--- src/version.c 2012-03-16 19:24:06.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 473, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +201. When somebody asks you where you are, you tell them in which chat room. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7cbeb90f2ee81bcf8ddb9a99d79576c04b1a5bbf Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:11 +0200 Subject: [PATCH 0206/3340] - patchlevel 474 --- 7.3.474 | 62 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 7.3.474 diff --git a/7.3.474 b/7.3.474 new file mode 100644 index 00000000..dc6b1d6e --- /dev/null +++ b/7.3.474 @@ -0,0 +1,62 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.474 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.474 +Problem: Perl build with gcc 4 fails. +Solution: Remove XS() statements. (Yasuhiro Matsumoto) +Files: src/if_perl.xs + + +*** ../vim-7.3.473/src/if_perl.xs 2012-02-12 00:31:47.000000000 +0100 +--- src/if_perl.xs 2012-03-16 19:33:23.000000000 +0100 +*************** +*** 913,936 **** + win_T *win_find_nr(int n) { return curwin; } + #endif + +- XS(XS_VIM_Msg); +- XS(XS_VIM_SetOption); +- XS(XS_VIM_DoCommand); +- XS(XS_VIM_Eval); +- XS(XS_VIM_Buffers); +- XS(XS_VIM_Windows); +- XS(XS_VIWIN_DESTROY); +- XS(XS_VIWIN_Buffer); +- XS(XS_VIWIN_SetHeight); +- XS(XS_VIWIN_Cursor); +- XS(XS_VIBUF_DESTROY); +- XS(XS_VIBUF_Name); +- XS(XS_VIBUF_Number); +- XS(XS_VIBUF_Count); +- XS(XS_VIBUF_Get); +- XS(XS_VIBUF_Set); +- XS(XS_VIBUF_Delete); +- XS(XS_VIBUF_Append); + XS(boot_VIM); + + static void +--- 913,918 ---- +*** ../vim-7.3.473/src/version.c 2012-03-16 19:24:21.000000000 +0100 +--- src/version.c 2012-03-16 19:28:03.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 474, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +202. You're amazed to find out Spam is a food. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From db2e522f1b70f746b0513304974f3078791af8a6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:11 +0200 Subject: [PATCH 0207/3340] - patchlevel 475 --- 7.3.475 | 98 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 98 insertions(+) create mode 100644 7.3.475 diff --git a/7.3.475 b/7.3.475 new file mode 100644 index 00000000..54c27a21 --- /dev/null +++ b/7.3.475 @@ -0,0 +1,98 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.475 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.475 +Problem: In a terminal with few colors the omnicomplete menu may be hard to + see when using the default colors. +Solution: Use more explicit colors. (suggested by Alex Henrie) +Files: src/syntax.c + + +*** ../vim-7.3.474/src/syntax.c 2012-01-10 22:26:12.000000000 +0100 +--- src/syntax.c 2012-03-16 20:14:22.000000000 +0100 +*************** +*** 6516,6523 **** + "DiffText term=reverse cterm=bold ctermbg=Red gui=bold guibg=Red"), + #endif + #ifdef FEAT_INS_EXPAND +- CENT("PmenuThumb cterm=reverse", +- "PmenuThumb cterm=reverse gui=reverse"), + CENT("PmenuSbar ctermbg=Grey", + "PmenuSbar ctermbg=Grey guibg=Grey"), + #endif +--- 6516,6521 ---- +*************** +*** 6557,6566 **** + "SpellLocal term=underline ctermbg=Cyan guisp=DarkCyan gui=undercurl"), + #endif + #ifdef FEAT_INS_EXPAND +! CENT("Pmenu ctermbg=LightMagenta", +! "Pmenu ctermbg=LightMagenta guibg=LightMagenta"), +! CENT("PmenuSel ctermbg=LightGrey", +! "PmenuSel ctermbg=LightGrey guibg=Grey"), + #endif + CENT("SpecialKey term=bold ctermfg=DarkBlue", + "SpecialKey term=bold ctermfg=DarkBlue guifg=Blue"), +--- 6555,6566 ---- + "SpellLocal term=underline ctermbg=Cyan guisp=DarkCyan gui=undercurl"), + #endif + #ifdef FEAT_INS_EXPAND +! CENT("PmenuThumb ctermbg=Black", +! "PmenuThumb ctermbg=Black guibg=Black"), +! CENT("Pmenu ctermbg=LightMagenta ctermfg=Black", +! "Pmenu ctermbg=LightMagenta ctermfg=Black guibg=LightMagenta"), +! CENT("PmenuSel ctermbg=LightGrey ctermfg=Black", +! "PmenuSel ctermbg=LightGrey ctermfg=Black guibg=Grey"), + #endif + CENT("SpecialKey term=bold ctermfg=DarkBlue", + "SpecialKey term=bold ctermfg=DarkBlue guifg=Blue"), +*************** +*** 6645,6654 **** + "SpellLocal term=underline ctermbg=Cyan guisp=Cyan gui=undercurl"), + #endif + #ifdef FEAT_INS_EXPAND +! CENT("Pmenu ctermbg=Magenta", +! "Pmenu ctermbg=Magenta guibg=Magenta"), +! CENT("PmenuSel ctermbg=DarkGrey", +! "PmenuSel ctermbg=DarkGrey guibg=DarkGrey"), + #endif + CENT("Title term=bold ctermfg=LightMagenta", + "Title term=bold ctermfg=LightMagenta gui=bold guifg=Magenta"), +--- 6645,6656 ---- + "SpellLocal term=underline ctermbg=Cyan guisp=Cyan gui=undercurl"), + #endif + #ifdef FEAT_INS_EXPAND +! CENT("PmenuThumb ctermbg=White", +! "PmenuThumb ctermbg=White guibg=White"), +! CENT("Pmenu ctermbg=Magenta ctermfg=Black", +! "Pmenu ctermbg=Magenta ctermfg=Black guibg=Magenta"), +! CENT("PmenuSel ctermbg=DarkGrey ctermfg=Black", +! "PmenuSel ctermbg=DarkGrey ctermfg=Black guibg=DarkGrey"), + #endif + CENT("Title term=bold ctermfg=LightMagenta", + "Title term=bold ctermfg=LightMagenta gui=bold guifg=Magenta"), +*** ../vim-7.3.474/src/version.c 2012-03-16 19:34:43.000000000 +0100 +--- src/version.c 2012-03-16 20:05:35.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 475, + /**/ + +-- +Spam seems to be something useful to novices. Later you realize that +it's a bunch of indigestable junk that only clogs your system. +Applies to both the food and the e-mail! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ccfa666ec75692f00a1829f583e8a608d3599d85 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:12 +0200 Subject: [PATCH 0208/3340] - patchlevel 476 --- 7.3.476 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.476 diff --git a/7.3.476 b/7.3.476 new file mode 100644 index 00000000..959b906b --- /dev/null +++ b/7.3.476 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.476 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.476 +Problem: When selecting a block, using "$" to include the end of each line + and using "A" and typing a backspace strange things happen. + (Yuangchen Xie) +Solution: Avoid using a negative length. (Christian Brabandt) +Files: src/ops.c + + +*** ../vim-7.3.475/src/ops.c 2012-03-07 19:30:32.000000000 +0100 +--- src/ops.c 2012-03-23 12:22:36.000000000 +0100 +*************** +*** 2602,2608 **** + firstline = ml_get(oap->start.lnum) + bd.textcol; + if (oap->op_type == OP_APPEND) + firstline += bd.textlen; +! if ((ins_len = (long)STRLEN(firstline) - pre_textlen) > 0) + { + ins_text = vim_strnsave(firstline, (int)ins_len); + if (ins_text != NULL) +--- 2602,2609 ---- + firstline = ml_get(oap->start.lnum) + bd.textcol; + if (oap->op_type == OP_APPEND) + firstline += bd.textlen; +! if (pre_textlen >= 0 +! && (ins_len = (long)STRLEN(firstline) - pre_textlen) > 0) + { + ins_text = vim_strnsave(firstline, (int)ins_len); + if (ins_text != NULL) +*** ../vim-7.3.475/src/version.c 2012-03-16 20:16:42.000000000 +0100 +--- src/version.c 2012-03-23 14:14:49.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 476, + /**/ + +-- +"Marriage is a wonderful institution... +but who wants to live in an institution?" + - Groucho Marx + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c34d2e8e49de59cff4796f37c4fb3820c091906b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:12 +0200 Subject: [PATCH 0209/3340] - patchlevel 477 --- 7.3.477 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.477 diff --git a/7.3.477 b/7.3.477 new file mode 100644 index 00000000..8030ee65 --- /dev/null +++ b/7.3.477 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.477 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.477 +Problem: Using ":echo" to output enough lines to scroll, then using "j" and + "k" at the more prompt, displays the command on top of the output. + (Marcin Szamotulski) +Solution: Put the output below the command. (Christian Brabandt) +Files: src/eval.c + + +*** ../vim-7.3.476/src/eval.c 2012-03-07 19:16:49.000000000 +0100 +--- src/eval.c 2012-03-23 15:11:30.000000000 +0100 +*************** +*** 20492,20498 **** +--- 20492,20503 ---- + /* Call msg_start() after eval1(), evaluating the expression + * may cause a message to appear. */ + if (eap->cmdidx == CMD_echo) ++ { ++ /* Put the output below the command, makes scrolling back ++ * at more prompt work. */ ++ msg_didout = TRUE; + msg_start(); ++ } + } + else if (eap->cmdidx == CMD_echo) + msg_puts_attr((char_u *)" ", echo_attr); +*** ../vim-7.3.476/src/version.c 2012-03-23 14:16:19.000000000 +0100 +--- src/version.c 2012-03-23 15:13:58.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 477, + /**/ + +-- +"Marriage is when a man and woman become as one; the trouble starts +when they try to decide which one" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 040d154850f0af611defe5442d4c39d6eb956bfa Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:12 +0200 Subject: [PATCH 0210/3340] - patchlevel 478 --- 7.3.478 | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 7.3.478 diff --git a/7.3.478 b/7.3.478 new file mode 100644 index 00000000..bad69ef2 --- /dev/null +++ b/7.3.478 @@ -0,0 +1,46 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.478 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.478 +Problem: Memory leak using the ':rv!' command when reading dictionary or + list global variables i.e. with 'viminfo' containing !. +Solution: Free the typeval. (Dominique Pelle) +Files: src/eval.c + + +*** ../vim-7.3.477/src/eval.c 2012-03-23 15:18:20.000000000 +0100 +--- src/eval.c 2012-03-23 15:28:42.000000000 +0100 +*************** +*** 22976,22981 **** +--- 22976,22982 ---- + { + vim_free(tv.vval.v_string); + tv = *etv; ++ vim_free(etv); + } + } + +*** ../vim-7.3.477/src/version.c 2012-03-23 15:18:20.000000000 +0100 +--- src/version.c 2012-03-23 15:29:22.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 478, + /**/ + +-- +"Marriage is the process of finding out what kind of man your wife +would have preferred" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1c2452683bb8c91ed5dceadb106003a9c5fac266 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:13 +0200 Subject: [PATCH 0211/3340] - patchlevel 479 --- 7.3.479 | 134 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 134 insertions(+) create mode 100644 7.3.479 diff --git a/7.3.479 b/7.3.479 new file mode 100644 index 00000000..fc256c1f --- /dev/null +++ b/7.3.479 @@ -0,0 +1,134 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.479 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.479 +Problem: When 'cursorline' is set the line number highlighting can't be set + separately. +Solution: Add "CursorLineNr". (Howard Buchholz) +Files: src/option.c, src/screen.c, src/syntax.c, src/vim.h + + +*** ../vim-7.3.478/src/option.c 2012-02-29 13:51:32.000000000 +0100 +--- src/option.c 2012-03-23 15:44:57.000000000 +0100 +*************** +*** 460,468 **** + #if defined(FEAT_DIFF) || defined(FEAT_FOLDING) || defined(FEAT_SPELL) \ + || defined(FEAT_VERTSPLIT) || defined(FEAT_CLIPBOARD) \ + || defined(FEAT_INS_EXPAND) || defined(FEAT_SYN_HL) || defined(FEAT_CONCEAL) +! # define HIGHLIGHT_INIT "8:SpecialKey,@:NonText,d:Directory,e:ErrorMsg,i:IncSearch,l:Search,m:MoreMsg,M:ModeMsg,n:LineNr,r:Question,s:StatusLine,S:StatusLineNC,c:VertSplit,t:Title,v:Visual,V:VisualNOS,w:WarningMsg,W:WildMenu,f:Folded,F:FoldColumn,A:DiffAdd,C:DiffChange,D:DiffDelete,T:DiffText,>:SignColumn,-:Conceal,B:SpellBad,P:SpellCap,R:SpellRare,L:SpellLocal,+:Pmenu,=:PmenuSel,x:PmenuSbar,X:PmenuThumb,*:TabLine,#:TabLineSel,_:TabLineFill,!:CursorColumn,.:CursorLine,o:ColorColumn" + #else +! # define HIGHLIGHT_INIT "8:SpecialKey,@:NonText,d:Directory,e:ErrorMsg,i:IncSearch,l:Search,m:MoreMsg,M:ModeMsg,n:LineNr,r:Question,s:StatusLine,S:StatusLineNC,t:Title,v:Visual,w:WarningMsg,W:WildMenu,>:SignColumn,*:TabLine,#:TabLineSel,_:TabLineFill" + #endif + + /* +--- 460,468 ---- + #if defined(FEAT_DIFF) || defined(FEAT_FOLDING) || defined(FEAT_SPELL) \ + || defined(FEAT_VERTSPLIT) || defined(FEAT_CLIPBOARD) \ + || defined(FEAT_INS_EXPAND) || defined(FEAT_SYN_HL) || defined(FEAT_CONCEAL) +! # define HIGHLIGHT_INIT "8:SpecialKey,@:NonText,d:Directory,e:ErrorMsg,i:IncSearch,l:Search,m:MoreMsg,M:ModeMsg,n:LineNr,N:CursorLineNr,r:Question,s:StatusLine,S:StatusLineNC,c:VertSplit,t:Title,v:Visual,V:VisualNOS,w:WarningMsg,W:WildMenu,f:Folded,F:FoldColumn,A:DiffAdd,C:DiffChange,D:DiffDelete,T:DiffText,>:SignColumn,-:Conceal,B:SpellBad,P:SpellCap,R:SpellRare,L:SpellLocal,+:Pmenu,=:PmenuSel,x:PmenuSbar,X:PmenuThumb,*:TabLine,#:TabLineSel,_:TabLineFill,!:CursorColumn,.:CursorLine,o:ColorColumn" + #else +! # define HIGHLIGHT_INIT "8:SpecialKey,@:NonText,d:Directory,e:ErrorMsg,i:IncSearch,l:Search,m:MoreMsg,M:ModeMsg,n:LineNr,N:CursorLineNr,r:Question,s:StatusLine,S:StatusLineNC,t:Title,v:Visual,w:WarningMsg,W:WildMenu,>:SignColumn,*:TabLine,#:TabLineSel,_:TabLineFill" + #endif + + /* +*** ../vim-7.3.478/src/screen.c 2012-03-16 19:07:54.000000000 +0100 +--- src/screen.c 2012-03-23 16:09:15.000000000 +0100 +*************** +*** 3501,3509 **** + char_attr = hl_attr(HLF_N); + #ifdef FEAT_SYN_HL + /* When 'cursorline' is set highlight the line number of +! * the current line differently. */ + if (wp->w_p_cul && lnum == wp->w_cursor.lnum) +! char_attr = hl_combine_attr(hl_attr(HLF_CUL), char_attr); + #endif + } + } +--- 3501,3511 ---- + char_attr = hl_attr(HLF_N); + #ifdef FEAT_SYN_HL + /* When 'cursorline' is set highlight the line number of +! * the current line differently. +! * TODO: Can we use CursorLine instead of CursorLineNr +! * when CursorLineNr isn't set? */ + if (wp->w_p_cul && lnum == wp->w_cursor.lnum) +! char_attr = hl_attr(HLF_CLN); + #endif + } + } +*** ../vim-7.3.478/src/syntax.c 2012-03-16 20:16:42.000000000 +0100 +--- src/syntax.c 2012-03-23 16:23:57.000000000 +0100 +*************** +*** 6538,6543 **** +--- 6538,6545 ---- + "Directory term=bold ctermfg=DarkBlue guifg=Blue"), + CENT("LineNr term=underline ctermfg=Brown", + "LineNr term=underline ctermfg=Brown guifg=Brown"), ++ CENT("CursorLineNr term=bold ctermfg=Brown", ++ "CursorLineNr term=bold ctermfg=Brown gui=bold guifg=Brown"), + CENT("MoreMsg term=bold ctermfg=DarkGreen", + "MoreMsg term=bold ctermfg=DarkGreen gui=bold guifg=SeaGreen"), + CENT("Question term=standout ctermfg=DarkGreen", +*************** +*** 6626,6631 **** +--- 6628,6635 ---- + "Directory term=bold ctermfg=LightCyan guifg=Cyan"), + CENT("LineNr term=underline ctermfg=Yellow", + "LineNr term=underline ctermfg=Yellow guifg=Yellow"), ++ CENT("CursorLineNr term=bold ctermfg=Yellow", ++ "CursorLineNr term=bold ctermfg=Yellow gui=bold guifg=Yellow"), + CENT("MoreMsg term=bold ctermfg=LightGreen", + "MoreMsg term=bold ctermfg=LightGreen gui=bold guifg=SeaGreen"), + CENT("Question term=standout ctermfg=LightGreen", +*** ../vim-7.3.478/src/vim.h 2012-03-07 19:16:49.000000000 +0100 +--- src/vim.h 2012-03-23 15:44:57.000000000 +0100 +*************** +*** 1318,1323 **** +--- 1318,1324 ---- + , HLF_M /* "--More--" message */ + , HLF_CM /* Mode (e.g., "-- INSERT --") */ + , HLF_N /* line number for ":number" and ":#" commands */ ++ , HLF_CLN /* current line number */ + , HLF_R /* return to continue message and yes/no questions */ + , HLF_S /* status lines */ + , HLF_SNC /* status lines of not-current windows */ +*************** +*** 1355,1361 **** + /* The HL_FLAGS must be in the same order as the HLF_ enums! + * When changing this also adjust the default for 'highlight'. */ + #define HL_FLAGS {'8', '@', 'd', 'e', 'h', 'i', 'l', 'm', 'M', \ +! 'n', 'r', 's', 'S', 'c', 't', 'v', 'V', 'w', 'W', \ + 'f', 'F', 'A', 'C', 'D', 'T', '-', '>', \ + 'B', 'P', 'R', 'L', \ + '+', '=', 'x', 'X', '*', '#', '_', '!', '.', 'o'} +--- 1356,1362 ---- + /* The HL_FLAGS must be in the same order as the HLF_ enums! + * When changing this also adjust the default for 'highlight'. */ + #define HL_FLAGS {'8', '@', 'd', 'e', 'h', 'i', 'l', 'm', 'M', \ +! 'n', 'N', 'r', 's', 'S', 'c', 't', 'v', 'V', 'w', 'W', \ + 'f', 'F', 'A', 'C', 'D', 'T', '-', '>', \ + 'B', 'P', 'R', 'L', \ + '+', '=', 'x', 'X', '*', '#', '_', '!', '.', 'o'} +*** ../vim-7.3.478/src/version.c 2012-03-23 15:36:57.000000000 +0100 +--- src/version.c 2012-03-23 16:16:41.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 479, + /**/ + +-- +If you're sending someone Styrofoam, what do you pack it in? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a33f2534d3a10dfa767a8c91de0829b34ac40175 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:13 +0200 Subject: [PATCH 0212/3340] - patchlevel 480 --- 7.3.480 | 237 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 237 insertions(+) create mode 100644 7.3.480 diff --git a/7.3.480 b/7.3.480 new file mode 100644 index 00000000..6d1e21de --- /dev/null +++ b/7.3.480 @@ -0,0 +1,237 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.480 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.480 +Problem: When using ":qa" and there is a changed buffer picking the buffer + to jump to is not very good. +Solution: Consider current and other tab pages. (Hirohito Higashi) +Files: src/ex_cmds2.c + + +*** ../vim-7.3.479/src/ex_cmds2.c 2012-02-22 18:29:29.000000000 +0100 +--- src/ex_cmds2.c 2012-03-23 17:01:31.000000000 +0100 +*************** +*** 1569,1574 **** +--- 1569,1594 ---- + || forceit); + } + ++ static void add_bufnum __ARGS((int *bufnrs, int *bufnump, int nr)); ++ ++ /* ++ * Add a buffer number to "bufnrs", unless it's already there. ++ */ ++ static void ++ add_bufnum(bufnrs, bufnump, nr) ++ int *bufnrs; ++ int *bufnump; ++ int nr; ++ { ++ int i; ++ ++ for (i = 0; i < *bufnump; ++i) ++ if (bufnrs[i] == nr) ++ return; ++ bufnrs[*bufnump] = nr; ++ *bufnump = *bufnump + 1; ++ } ++ + /* + * Return TRUE if any buffer was changed and cannot be abandoned. + * That changed buffer becomes the current buffer. +*************** +*** 1577,1608 **** + check_changed_any(hidden) + int hidden; /* Only check hidden buffers */ + { + buf_T *buf; + int save; + #ifdef FEAT_WINDOWS + win_T *wp; + #endif + +! for (;;) + { +! /* check curbuf first: if it was changed we can't abandon it */ +! if (!hidden && curbufIsChanged()) +! buf = curbuf; +! else + { +! for (buf = firstbuf; buf != NULL; buf = buf->b_next) +! if ((!hidden || buf->b_nwindows == 0) && bufIsChanged(buf)) +! break; + } +- if (buf == NULL) /* No buffers changed */ +- return FALSE; +- +- /* Try auto-writing the buffer. If this fails but the buffer no +- * longer exists it's not changed, that's OK. */ +- if (check_changed(buf, p_awa, TRUE, FALSE, TRUE) && buf_valid(buf)) +- break; /* didn't save - still changes */ + } + + exiting = FALSE; + #if defined(FEAT_GUI_DIALOG) || defined(FEAT_CON_DIALOG) + /* +--- 1597,1660 ---- + check_changed_any(hidden) + int hidden; /* Only check hidden buffers */ + { ++ int ret = FALSE; + buf_T *buf; + int save; ++ int i; ++ int bufnum = 0; ++ int bufcount = 0; ++ int *bufnrs; + #ifdef FEAT_WINDOWS ++ tabpage_T *tp; + win_T *wp; + #endif + +! for (buf = firstbuf; buf != NULL; buf = buf->b_next) +! ++bufcount; +! +! if (bufcount == 0) +! return FALSE; +! +! bufnrs = (int *)alloc(sizeof(int) * bufcount); +! if (bufnrs == NULL) +! return FALSE; +! +! /* curbuf */ +! bufnrs[bufnum++] = curbuf->b_fnum; +! #ifdef FEAT_WINDOWS +! /* buf in curtab */ +! FOR_ALL_WINDOWS(wp) +! if (wp->w_buffer != curbuf) +! add_bufnum(bufnrs, &bufnum, wp->w_buffer->b_fnum); +! +! /* buf in other tab */ +! for (tp = first_tabpage; tp != NULL; tp = tp->tp_next) +! if (tp != curtab) +! for (wp = tp->tp_firstwin; wp != NULL; wp = wp->w_next) +! add_bufnum(bufnrs, &bufnum, wp->w_buffer->b_fnum); +! #endif +! /* any other buf */ +! for (buf = firstbuf; buf != NULL; buf = buf->b_next) +! add_bufnum(bufnrs, &bufnum, buf->b_fnum); +! +! for (i = 0; i < bufnum; ++i) + { +! buf = buflist_findnr(bufnrs[i]); +! if (buf == NULL) +! continue; +! if ((!hidden || buf->b_nwindows == 0) && bufIsChanged(buf)) + { +! /* Try auto-writing the buffer. If this fails but the buffer no +! * longer exists it's not changed, that's OK. */ +! if (check_changed(buf, p_awa, TRUE, FALSE, TRUE) && buf_valid(buf)) +! break; /* didn't save - still changes */ + } + } + ++ if (i >= bufnum) ++ goto theend; ++ ++ ret = TRUE; + exiting = FALSE; + #if defined(FEAT_GUI_DIALOG) || defined(FEAT_CON_DIALOG) + /* +*************** +*** 1635,1658 **** + #ifdef FEAT_WINDOWS + /* Try to find a window that contains the buffer. */ + if (buf != curbuf) +! for (wp = firstwin; wp != NULL; wp = wp->w_next) + if (wp->w_buffer == buf) + { +! win_goto(wp); + # ifdef FEAT_AUTOCMD + /* Paranoia: did autocms wipe out the buffer with changes? */ + if (!buf_valid(buf)) +! return TRUE; + # endif +! break; + } + #endif + + /* Open the changed buffer in the current window. */ + if (buf != curbuf) + set_curbuf(buf, DOBUF_GOTO); + +! return TRUE; + } + + /* +--- 1687,1715 ---- + #ifdef FEAT_WINDOWS + /* Try to find a window that contains the buffer. */ + if (buf != curbuf) +! FOR_ALL_TAB_WINDOWS(tp, wp) + if (wp->w_buffer == buf) + { +! goto_tabpage_win(tp, wp); + # ifdef FEAT_AUTOCMD + /* Paranoia: did autocms wipe out the buffer with changes? */ + if (!buf_valid(buf)) +! { +! goto theend; +! } + # endif +! goto buf_found; + } ++ buf_found: + #endif + + /* Open the changed buffer in the current window. */ + if (buf != curbuf) + set_curbuf(buf, DOBUF_GOTO); + +! theend: +! vim_free(bufnrs); +! return ret; + } + + /* +*************** +*** 3274,3280 **** + home_replace(NULL, SCRIPT_ITEM(i).sn_name, + NameBuff, MAXPATHL, TRUE); + smsg((char_u *)"%3d: %s", i, NameBuff); +! } + } + + # if defined(BACKSLASH_IN_FILENAME) || defined(PROTO) +--- 3331,3337 ---- + home_replace(NULL, SCRIPT_ITEM(i).sn_name, + NameBuff, MAXPATHL, TRUE); + smsg((char_u *)"%3d: %s", i, NameBuff); +! } + } + + # if defined(BACKSLASH_IN_FILENAME) || defined(PROTO) +*** ../vim-7.3.479/src/version.c 2012-03-23 16:25:13.000000000 +0100 +--- src/version.c 2012-03-23 16:48:06.000000000 +0100 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 480, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +243. You unsuccessfully try to download a pizza from www.dominos.com. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a41e5f2f84216e70ac56c302a183fcd9e9ab6864 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:13 +0200 Subject: [PATCH 0213/3340] - patchlevel 481 --- 7.3.481 | 65 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 7.3.481 diff --git a/7.3.481 b/7.3.481 new file mode 100644 index 00000000..69f69158 --- /dev/null +++ b/7.3.481 @@ -0,0 +1,65 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.481 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.481 +Problem: Changing 'virtualedit' in an operator function to "all" does not + have the desired effect. (Aaron Bohannon) +Solution: Save, reset and restore virtual_op when executing an operator + function. +Files: src/normal.c + + +*** ../vim-7.3.480/src/normal.c 2012-02-05 01:18:41.000000000 +0100 +--- src/normal.c 2012-03-28 12:59:46.000000000 +0200 +*************** +*** 2279,2284 **** +--- 2279,2285 ---- + { + #ifdef FEAT_EVAL + char_u *(argv[1]); ++ int save_virtual_op = virtual_op; + + if (*p_opfunc == NUL) + EMSG(_("E774: 'operatorfunc' is empty")); +*************** +*** 2297,2303 **** +--- 2298,2311 ---- + argv[0] = (char_u *)"line"; + else + argv[0] = (char_u *)"char"; ++ ++ /* Reset virtual_op so that 'virtualedit' can be changed in the ++ * function. */ ++ virtual_op = MAYBE; ++ + (void)call_func_retnr(p_opfunc, 1, argv, FALSE); ++ ++ virtual_op = save_virtual_op; + } + #else + EMSG(_("E775: Eval feature not available")); +*** ../vim-7.3.480/src/version.c 2012-03-23 18:39:10.000000000 +0100 +--- src/version.c 2012-03-28 12:50:20.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 481, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +269. You wonder how you can make your dustbin produce Sesame Street's + Oscar's the Garbage Monster song when you empty it. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e9630a5b1c37fb5a6ec98404e60a39960313b477 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:14 +0200 Subject: [PATCH 0214/3340] - patchlevel 482 --- 7.3.482 | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 7.3.482 diff --git a/7.3.482 b/7.3.482 new file mode 100644 index 00000000..56ff3017 --- /dev/null +++ b/7.3.482 @@ -0,0 +1,57 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.482 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.482 +Problem: With 'cursorbind' set moving up/down does not always keep the same + column. +Solution: Set curswant appropriately. (Gary Johnson) +Files: src/move.c + + +*** ../vim-7.3.481/src/move.c 2012-03-16 19:24:21.000000000 +0100 +--- src/move.c 2012-03-28 14:16:02.000000000 +0200 +*************** +*** 2847,2852 **** +--- 2847,2854 ---- + # ifdef FEAT_VIRTUALEDIT + colnr_T coladd = curwin->w_cursor.coladd; + # endif ++ colnr_T curswant = curwin->w_curswant; ++ int set_curswant = curwin->w_set_curswant; + win_T *old_curwin = curwin; + buf_T *old_curbuf = curbuf; + int restart_edit_save; +*************** +*** 2881,2886 **** +--- 2883,2890 ---- + # ifdef FEAT_VIRTUALEDIT + curwin->w_cursor.coladd = coladd; + # endif ++ curwin->w_curswant = curswant; ++ curwin->w_set_curswant = set_curswant; + + /* Make sure the cursor is in a valid position. Temporarily set + * "restart_edit" to allow the cursor to be beyond the EOL. */ +*** ../vim-7.3.481/src/version.c 2012-03-28 12:59:53.000000000 +0200 +--- src/version.c 2012-03-28 14:15:56.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 482, + /**/ + +-- +Women are probably the main cause of free software starvation. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 98dbbbdfb28dd29c17fd45d046fb43ae35e8bc8d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:14 +0200 Subject: [PATCH 0215/3340] - patchlevel 483 --- 7.3.483 | 97 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100644 7.3.483 diff --git a/7.3.483 b/7.3.483 new file mode 100644 index 00000000..bab488b4 --- /dev/null +++ b/7.3.483 @@ -0,0 +1,97 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.483 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.483 (after 7.3.477) +Problem: More prompt shows up too often. +Solution: Instead of adding a line break, only start a new line in the + message history. (Christian Brabandt) +Files: src/eval.c, src/message.c, src/proto/message.pro + + +*** ../vim-7.3.482/src/eval.c 2012-03-23 15:36:57.000000000 +0100 +--- src/eval.c 2012-03-28 16:41:03.000000000 +0200 +*************** +*** 20493,20501 **** + * may cause a message to appear. */ + if (eap->cmdidx == CMD_echo) + { +! /* Put the output below the command, makes scrolling back +! * at more prompt work. */ +! msg_didout = TRUE; + msg_start(); + } + } +--- 20493,20502 ---- + * may cause a message to appear. */ + if (eap->cmdidx == CMD_echo) + { +! /* Mark the saved text as finishing the line, so that what +! * follows is displayed on a new line when scrolling back +! * at the more prompt. */ +! msg_sb_eol(); + msg_start(); + } + } +*** ../vim-7.3.482/src/message.c 2012-01-26 13:01:54.000000000 +0100 +--- src/message.c 2012-03-28 16:35:26.000000000 +0200 +*************** +*** 2348,2353 **** +--- 2348,2363 ---- + } + + /* ++ * Mark the last message chunk as finishing the line. ++ */ ++ void ++ msg_sb_eol() ++ { ++ if (last_msgchunk != NULL) ++ last_msgchunk->sb_eol = TRUE; ++ } ++ ++ /* + * Display a screen line from previously displayed text at row "row". + * Returns a pointer to the text for the next line (can be NULL). + */ +*** ../vim-7.3.482/src/proto/message.pro 2012-01-20 20:44:38.000000000 +0100 +--- src/proto/message.pro 2012-03-28 16:35:33.000000000 +0200 +*************** +*** 45,50 **** +--- 45,51 ---- + void may_clear_sb_text __ARGS((void)); + void clear_sb_text __ARGS((void)); + void show_sb_text __ARGS((void)); ++ void msg_sb_eol __ARGS((void)); + int msg_use_printf __ARGS((void)); + void mch_errmsg __ARGS((char *str)); + void mch_msg __ARGS((char *str)); +*** ../vim-7.3.482/src/version.c 2012-03-28 14:19:46.000000000 +0200 +--- src/version.c 2012-03-28 16:48:53.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 483, + /**/ + +-- + We're knights of the Round Table + Our shows are formidable + But many times + We're given rhymes + That are quite unsingable + We're opera mad in Camelot + We sing from the diaphragm a lot. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5659b5773a520d701269d9f2217411462ce8ee6f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:14 +0200 Subject: [PATCH 0216/3340] - patchlevel 484 --- 7.3.484 | 62 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 7.3.484 diff --git a/7.3.484 b/7.3.484 new file mode 100644 index 00000000..99968eb2 --- /dev/null +++ b/7.3.484 @@ -0,0 +1,62 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.484 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.484 +Problem: The -E and --echo-wid command line arguments are not mentioned in + "vim --help". +Solution: Add the help lines. (Dominique Pelle) +Files: src/main.c + + +*** ../vim-7.3.483/src/main.c 2012-02-12 01:55:50.000000000 +0100 +--- src/main.c 2012-03-28 16:55:03.000000000 +0200 +*************** +*** 3181,3186 **** +--- 3181,3187 ---- + #endif + main_msg(_("-v\t\t\tVi mode (like \"vi\")")); + main_msg(_("-e\t\t\tEx mode (like \"ex\")")); ++ main_msg(_("-E\t\t\tImproved Ex mode")); + main_msg(_("-s\t\t\tSilent (batch) mode (only for \"ex\")")); + #ifdef FEAT_DIFF + main_msg(_("-d\t\t\tDiff mode (like \"vimdiff\")")); +*************** +*** 3304,3309 **** +--- 3305,3311 ---- + main_msg(_("-display \tRun vim on (also: --display)")); + main_msg(_("--role \tSet a unique role to identify the main window")); + main_msg(_("--socketid \tOpen Vim inside another GTK widget")); ++ main_msg(_("--echo-wid\t\tMake gvim echo the Window ID on stdout")); + #endif + #ifdef FEAT_GUI_W32 + main_msg(_("-P \tOpen Vim inside parent application")); +*** ../vim-7.3.483/src/version.c 2012-03-28 16:49:25.000000000 +0200 +--- src/version.c 2012-03-28 17:10:08.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 484, + /**/ + +-- + In war we're tough and able. + Quite indefatigable + Between our quests + We sequin vests + And impersonate Clark Gable + It's a busy life in Camelot. + I have to push the pram a lot. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6c586fe32e346cce9a1def8436e92aec5e41557e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:14 +0200 Subject: [PATCH 0217/3340] - patchlevel 485 --- 7.3.485 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.485 diff --git a/7.3.485 b/7.3.485 new file mode 100644 index 00000000..46b4cb73 --- /dev/null +++ b/7.3.485 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.485 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.485 +Problem: When building Vim LDFLAGS isn't passed on to building xxd. +Solution: Pass the LDFLAGS value. (James McCoy) +Files: src/Makefile + + +*** ../vim-7.3.484/src/Makefile 2011-12-14 20:51:19.000000000 +0100 +--- src/Makefile 2012-03-28 17:16:06.000000000 +0200 +*************** +*** 1720,1726 **** + sh $(srcdir)/link.sh + + xxd/xxd$(EXEEXT): xxd/xxd.c +! cd xxd; CC="$(CC)" CFLAGS="$(CPPFLAGS) $(CFLAGS)" \ + $(MAKE) -f Makefile + + # Build the language specific files if they were unpacked. +--- 1720,1726 ---- + sh $(srcdir)/link.sh + + xxd/xxd$(EXEEXT): xxd/xxd.c +! cd xxd; CC="$(CC)" CFLAGS="$(CPPFLAGS) $(CFLAGS)" LDFLAGS="$(LDFLAGS)" \ + $(MAKE) -f Makefile + + # Build the language specific files if they were unpacked. +*** ../vim-7.3.484/src/version.c 2012-03-28 17:10:26.000000000 +0200 +--- src/version.c 2012-03-28 17:16:15.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 485, + /**/ + +-- +GOD: That is your purpose Arthur ... the Quest for the Holy Grail ... + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c64ac5e8643f81261addb1d8e5d35c6ca5160d29 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:15 +0200 Subject: [PATCH 0218/3340] - patchlevel 486 --- 7.3.486 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.486 diff --git a/7.3.486 b/7.3.486 new file mode 100644 index 00000000..44e2afe8 --- /dev/null +++ b/7.3.486 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.486 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.486 +Problem: Build error with mingw64 on Windows 7. +Solution: Avoid the step of going through vimres.res. (Guopeng Wen) +Files: src/Make_ming.mak + + +*** ../vim-7.3.485/src/Make_ming.mak 2012-02-29 16:56:35.000000000 +0100 +--- src/Make_ming.mak 2012-03-28 17:41:55.000000000 +0200 +*************** +*** 681,691 **** + $(OUTDIR)/%.o : %.c $(INCL) + $(CC) -c $(CFLAGS) $< -o $@ + +! $(OUTDIR)/vimres.res: vim.rc version.h gui_w32_rc.h +! $(WINDRES) $(WINDRES_FLAGS) $(DEFINES) vim.rc $(OUTDIR)/vimres.res +! +! $(OUTDIR)/vimrc.o: $(OUTDIR)/vimres.res +! $(WINDRES) $(WINDRES_FLAGS) $(OUTDIR)/vimres.res $(OUTDIR)/vimrc.o + + $(OUTDIR): + $(MKDIR) $(OUTDIR) +--- 681,689 ---- + $(OUTDIR)/%.o : %.c $(INCL) + $(CC) -c $(CFLAGS) $< -o $@ + +! $(OUTDIR)/vimrc.o: vim.rc version.h gui_w32_rc.h +! $(WINDRES) $(WINDRES_FLAGS) $(DEFINES) \ +! --input-format=rc --output-format=coff -i vim.rc -o $@ + + $(OUTDIR): + $(MKDIR) $(OUTDIR) +*** ../vim-7.3.485/src/version.c 2012-03-28 17:17:45.000000000 +0200 +--- src/version.c 2012-03-28 17:42:25.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 486, + /**/ + +-- +There is a fine line between courage and foolishness. +Unfortunately, it's not a fence. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 235c0c5a035647087ae77d7f5e0cd7aa82fef44b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:15 +0200 Subject: [PATCH 0219/3340] - patchlevel 487 --- 7.3.487 | 572 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 572 insertions(+) create mode 100644 7.3.487 diff --git a/7.3.487 b/7.3.487 new file mode 100644 index 00000000..3c00349b --- /dev/null +++ b/7.3.487 @@ -0,0 +1,572 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.487 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.487 +Problem: When setting 'timeoutlen' or 'ttimeoutlen' the column for vertical + movement is reset unnecessarily. +Solution: Do not set w_set_curswant for every option. Add a test for this. + (Kana Natsuno) Add the P_CURSWANT flag for options. +Files: src/option.c, src/testdir/test84.in, src/testdir/test84.ok, + src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak, + src/testdir/Make_ming.mak, src/testdir/Make_os2.mak, + src/testdir/Make_vms.mms, src/testdir/Makefile + + +*** ../vim-7.3.486/src/option.c 2012-03-23 16:25:13.000000000 +0100 +--- src/option.c 2012-03-28 19:57:46.000000000 +0200 +*************** +*** 433,449 **** + #define P_RCLR 0x7000 /* clear and redraw all */ + + #define P_COMMA 0x8000 /* comma separated list */ +! #define P_NODUP 0x10000L/* don't allow duplicate strings */ +! #define P_FLAGLIST 0x20000L/* list of single-char flags */ + +! #define P_SECURE 0x40000L/* cannot change in modeline or secure mode */ +! #define P_GETTEXT 0x80000L/* expand default value with _() */ +! #define P_NOGLOB 0x100000L/* do not use local value for global vimrc */ +! #define P_NFNAME 0x200000L/* only normal file name chars allowed */ +! #define P_INSECURE 0x400000L/* option was set from a modeline */ +! #define P_PRI_MKRC 0x800000L/* priority for :mkvimrc (setting option has + side effects) */ +! #define P_NO_ML 0x1000000L/* not allowed in modeline */ + + #define ISK_LATIN1 (char_u *)"@,48-57,_,192-255" + +--- 433,451 ---- + #define P_RCLR 0x7000 /* clear and redraw all */ + + #define P_COMMA 0x8000 /* comma separated list */ +! #define P_NODUP 0x10000L /* don't allow duplicate strings */ +! #define P_FLAGLIST 0x20000L /* list of single-char flags */ + +! #define P_SECURE 0x40000L /* cannot change in modeline or secure mode */ +! #define P_GETTEXT 0x80000L /* expand default value with _() */ +! #define P_NOGLOB 0x100000L /* do not use local value for global vimrc */ +! #define P_NFNAME 0x200000L /* only normal file name chars allowed */ +! #define P_INSECURE 0x400000L /* option was set from a modeline */ +! #define P_PRI_MKRC 0x800000L /* priority for :mkvimrc (setting option has + side effects) */ +! #define P_NO_ML 0x1000000L /* not allowed in modeline */ +! #define P_CURSWANT 0x2000000L /* update curswant required; not needed when +! * there is a redraw flag */ + + #define ISK_LATIN1 (char_u *)"@,48-57,_,192-255" + +*************** +*** 479,485 **** + #endif + options[] = + { +! {"aleph", "al", P_NUM|P_VI_DEF, + #ifdef FEAT_RIGHTLEFT + (char_u *)&p_aleph, PV_NONE, + #else +--- 481,487 ---- + #endif + options[] = + { +! {"aleph", "al", P_NUM|P_VI_DEF|P_CURSWANT, + #ifdef FEAT_RIGHTLEFT + (char_u *)&p_aleph, PV_NONE, + #else +*************** +*** 501,507 **** + {(char_u *)FALSE, (char_u *)FALSE} + #endif + SCRIPTID_INIT}, +! {"arabic", "arab", P_BOOL|P_VI_DEF|P_VIM, + #ifdef FEAT_ARABIC + (char_u *)VAR_WIN, PV_ARAB, + #else +--- 503,509 ---- + {(char_u *)FALSE, (char_u *)FALSE} + #endif + SCRIPTID_INIT}, +! {"arabic", "arab", P_BOOL|P_VI_DEF|P_VIM|P_CURSWANT, + #ifdef FEAT_ARABIC + (char_u *)VAR_WIN, PV_ARAB, + #else +*************** +*** 778,784 **** + {"columns", "co", P_NUM|P_NODEFAULT|P_NO_MKRC|P_VI_DEF|P_RCLR, + (char_u *)&Columns, PV_NONE, + {(char_u *)80L, (char_u *)0L} SCRIPTID_INIT}, +! {"comments", "com", P_STRING|P_ALLOCED|P_VI_DEF|P_COMMA|P_NODUP, + #ifdef FEAT_COMMENTS + (char_u *)&p_com, PV_COM, + {(char_u *)"s1:/*,mb:*,ex:*/,://,b:#,:%,:XCOMM,n:>,fb:-", +--- 780,786 ---- + {"columns", "co", P_NUM|P_NODEFAULT|P_NO_MKRC|P_VI_DEF|P_RCLR, + (char_u *)&Columns, PV_NONE, + {(char_u *)80L, (char_u *)0L} SCRIPTID_INIT}, +! {"comments", "com", P_STRING|P_ALLOCED|P_VI_DEF|P_COMMA|P_NODUP|P_CURSWANT, + #ifdef FEAT_COMMENTS + (char_u *)&p_com, PV_COM, + {(char_u *)"s1:/*,mb:*,ex:*/,://,b:#,:%,:XCOMM,n:>,fb:-", +*************** +*** 788,794 **** + {(char_u *)0L, (char_u *)0L} + #endif + SCRIPTID_INIT}, +! {"commentstring", "cms", P_STRING|P_ALLOCED|P_VI_DEF, + #ifdef FEAT_FOLDING + (char_u *)&p_cms, PV_CMS, + {(char_u *)"/*%s*/", (char_u *)0L} +--- 790,796 ---- + {(char_u *)0L, (char_u *)0L} + #endif + SCRIPTID_INIT}, +! {"commentstring", "cms", P_STRING|P_ALLOCED|P_VI_DEF|P_CURSWANT, + #ifdef FEAT_FOLDING + (char_u *)&p_cms, PV_CMS, + {(char_u *)"/*%s*/", (char_u *)0L} +*************** +*** 953,959 **** + {"debug", NULL, P_STRING|P_VI_DEF, + (char_u *)&p_debug, PV_NONE, + {(char_u *)"", (char_u *)0L} SCRIPTID_INIT}, +! {"define", "def", P_STRING|P_ALLOCED|P_VI_DEF, + #ifdef FEAT_FIND_ID + (char_u *)&p_def, PV_DEF, + {(char_u *)"^\\s*#\\s*define", (char_u *)0L} +--- 955,961 ---- + {"debug", NULL, P_STRING|P_VI_DEF, + (char_u *)&p_debug, PV_NONE, + {(char_u *)"", (char_u *)0L} SCRIPTID_INIT}, +! {"define", "def", P_STRING|P_ALLOCED|P_VI_DEF|P_CURSWANT, + #ifdef FEAT_FIND_ID + (char_u *)&p_def, PV_DEF, + {(char_u *)"^\\s*#\\s*define", (char_u *)0L} +*************** +*** 983,989 **** + (char_u *)NULL, PV_NONE, + #endif + {(char_u *)FALSE, (char_u *)0L} SCRIPTID_INIT}, +! {"diffexpr", "dex", P_STRING|P_VI_DEF|P_SECURE, + #if defined(FEAT_DIFF) && defined(FEAT_EVAL) + (char_u *)&p_dex, PV_NONE, + {(char_u *)"", (char_u *)0L} +--- 985,991 ---- + (char_u *)NULL, PV_NONE, + #endif + {(char_u *)FALSE, (char_u *)0L} SCRIPTID_INIT}, +! {"diffexpr", "dex", P_STRING|P_VI_DEF|P_SECURE|P_CURSWANT, + #if defined(FEAT_DIFF) && defined(FEAT_EVAL) + (char_u *)&p_dex, PV_NONE, + {(char_u *)"", (char_u *)0L} +*************** +*** 1099,1105 **** + {(char_u *)0L, (char_u *)0L} + #endif + SCRIPTID_INIT}, +! {"fileformat", "ff", P_STRING|P_ALLOCED|P_VI_DEF|P_RSTAT|P_NO_MKRC, + (char_u *)&p_ff, PV_FF, + {(char_u *)DFLT_FF, (char_u *)0L} SCRIPTID_INIT}, + {"fileformats", "ffs", P_STRING|P_VIM|P_COMMA|P_NODUP, +--- 1101,1107 ---- + {(char_u *)0L, (char_u *)0L} + #endif + SCRIPTID_INIT}, +! {"fileformat", "ff", P_STRING|P_ALLOCED|P_VI_DEF|P_RSTAT|P_NO_MKRC|P_CURSWANT, + (char_u *)&p_ff, PV_FF, + {(char_u *)DFLT_FF, (char_u *)0L} SCRIPTID_INIT}, + {"fileformats", "ffs", P_STRING|P_VIM|P_COMMA|P_NODUP, +*************** +*** 1159,1165 **** + {"foldlevel", "fdl", P_NUM|P_VI_DEF|P_RWIN, + (char_u *)VAR_WIN, PV_FDL, + {(char_u *)0L, (char_u *)0L} SCRIPTID_INIT}, +! {"foldlevelstart","fdls", P_NUM|P_VI_DEF, + (char_u *)&p_fdls, PV_NONE, + {(char_u *)-1L, (char_u *)0L} SCRIPTID_INIT}, + {"foldmarker", "fmr", P_STRING|P_ALLOCED|P_VIM|P_VI_DEF| +--- 1161,1167 ---- + {"foldlevel", "fdl", P_NUM|P_VI_DEF|P_RWIN, + (char_u *)VAR_WIN, PV_FDL, + {(char_u *)0L, (char_u *)0L} SCRIPTID_INIT}, +! {"foldlevelstart","fdls", P_NUM|P_VI_DEF|P_CURSWANT, + (char_u *)&p_fdls, PV_NONE, + {(char_u *)-1L, (char_u *)0L} SCRIPTID_INIT}, + {"foldmarker", "fmr", P_STRING|P_ALLOCED|P_VIM|P_VI_DEF| +*************** +*** 1176,1182 **** + {"foldnestmax", "fdn", P_NUM|P_VI_DEF|P_RWIN, + (char_u *)VAR_WIN, PV_FDN, + {(char_u *)20L, (char_u *)0L} SCRIPTID_INIT}, +! {"foldopen", "fdo", P_STRING|P_VI_DEF|P_COMMA|P_NODUP, + (char_u *)&p_fdo, PV_NONE, + {(char_u *)"block,hor,mark,percent,quickfix,search,tag,undo", + (char_u *)0L} SCRIPTID_INIT}, +--- 1178,1184 ---- + {"foldnestmax", "fdn", P_NUM|P_VI_DEF|P_RWIN, + (char_u *)VAR_WIN, PV_FDN, + {(char_u *)20L, (char_u *)0L} SCRIPTID_INIT}, +! {"foldopen", "fdo", P_STRING|P_VI_DEF|P_COMMA|P_NODUP|P_CURSWANT, + (char_u *)&p_fdo, PV_NONE, + {(char_u *)"block,hor,mark,percent,quickfix,search,tag,undo", + (char_u *)0L} SCRIPTID_INIT}, +*************** +*** 1741,1747 **** + {"matchtime", "mat", P_NUM|P_VI_DEF, + (char_u *)&p_mat, PV_NONE, + {(char_u *)5L, (char_u *)0L} SCRIPTID_INIT}, +! {"maxcombine", "mco", P_NUM|P_VI_DEF, + #ifdef FEAT_MBYTE + (char_u *)&p_mco, PV_NONE, + #else +--- 1743,1749 ---- + {"matchtime", "mat", P_NUM|P_VI_DEF, + (char_u *)&p_mat, PV_NONE, + {(char_u *)5L, (char_u *)0L} SCRIPTID_INIT}, +! {"maxcombine", "mco", P_NUM|P_VI_DEF|P_CURSWANT, + #ifdef FEAT_MBYTE + (char_u *)&p_mco, PV_NONE, + #else +*************** +*** 2710,2716 **** + {(char_u *)0L, (char_u *)0L} + #endif + SCRIPTID_INIT}, +! {"virtualedit", "ve", P_STRING|P_COMMA|P_NODUP|P_VI_DEF|P_VIM, + #ifdef FEAT_VIRTUALEDIT + (char_u *)&p_ve, PV_NONE, + {(char_u *)"", (char_u *)""} +--- 2712,2718 ---- + {(char_u *)0L, (char_u *)0L} + #endif + SCRIPTID_INIT}, +! {"virtualedit", "ve", P_STRING|P_COMMA|P_NODUP|P_VI_DEF|P_VIM|P_CURSWANT, + #ifdef FEAT_VIRTUALEDIT + (char_u *)&p_ve, PV_NONE, + {(char_u *)"", (char_u *)""} +*************** +*** 7064,7071 **** + } + #endif + +! if (curwin->w_curswant != MAXCOL) +! curwin->w_set_curswant = TRUE; /* in case 'showbreak' changed */ + #ifdef FEAT_GUI + /* check redraw when it's not a GUI option or the GUI is active. */ + if (!redraw_gui_only || gui.in_use) +--- 7066,7075 ---- + } + #endif + +! if (curwin->w_curswant != MAXCOL +! && (options[opt_idx].flags & (P_CURSWANT | P_RCLR)) != 0) +! curwin->w_set_curswant = TRUE; +! + #ifdef FEAT_GUI + /* check redraw when it's not a GUI option or the GUI is active. */ + if (!redraw_gui_only || gui.in_use) +*************** +*** 7587,7595 **** + || (int *)varp == &curwin->w_p_nu + || (int *)varp == &curwin->w_p_rnu) + { +- if (curwin->w_curswant != MAXCOL) +- curwin->w_set_curswant = TRUE; +- + /* If 'number' is set, reset 'relativenumber'. */ + /* If 'relativenumber' is set, reset 'number'. */ + if ((int *)varp == &curwin->w_p_nu && curwin->w_p_nu) +--- 7591,7596 ---- +*************** +*** 7834,7841 **** + { + if (curwin->w_p_wrap) + curwin->w_leftcol = 0; +- if (curwin->w_curswant != MAXCOL) +- curwin->w_set_curswant = TRUE; + } + + #ifdef FEAT_WINDOWS +--- 7835,7840 ---- +*************** +*** 8062,8092 **** + curbuf->b_p_imsearch = B_IMODE_USE_INSERT; + # endif + } +- if (curwin->w_curswant != MAXCOL) +- curwin->w_set_curswant = TRUE; + } + +- else if ((int *)varp == &p_arshape) +- { +- if (curwin->w_curswant != MAXCOL) +- curwin->w_set_curswant = TRUE; +- } +- #endif +- +- #ifdef FEAT_LINEBREAK +- if ((int *)varp == &curwin->w_p_lbr) +- { +- if (curwin->w_curswant != MAXCOL) +- curwin->w_set_curswant = TRUE; +- } +- #endif +- +- #ifdef FEAT_RIGHTLEFT +- if ((int *)varp == &curwin->w_p_rl) +- { +- if (curwin->w_curswant != MAXCOL) +- curwin->w_set_curswant = TRUE; +- } + #endif + + /* +--- 8061,8068 ---- +*************** +*** 8096,8102 **** + options[opt_idx].flags |= P_WAS_SET; + + comp_col(); /* in case 'ruler' or 'showcmd' changed */ +! + check_redraw(options[opt_idx].flags); + + return NULL; +--- 8072,8080 ---- + options[opt_idx].flags |= P_WAS_SET; + + comp_col(); /* in case 'ruler' or 'showcmd' changed */ +! if (curwin->w_curswant != MAXCOL +! && (options[opt_idx].flags & (P_CURSWANT | P_RCLR)) != 0) +! curwin->w_set_curswant = TRUE; + check_redraw(options[opt_idx].flags); + + return NULL; +*************** +*** 8611,8618 **** + options[opt_idx].flags |= P_WAS_SET; + + comp_col(); /* in case 'columns' or 'ls' changed */ +! if (curwin->w_curswant != MAXCOL) +! curwin->w_set_curswant = TRUE; /* in case 'tabstop' changed */ + check_redraw(options[opt_idx].flags); + + return errmsg; +--- 8589,8597 ---- + options[opt_idx].flags |= P_WAS_SET; + + comp_col(); /* in case 'columns' or 'ls' changed */ +! if (curwin->w_curswant != MAXCOL +! && (options[opt_idx].flags & (P_CURSWANT | P_RCLR)) != 0) +! curwin->w_set_curswant = TRUE; + check_redraw(options[opt_idx].flags); + + return errmsg; +*** ../vim-7.3.486/src/testdir/test84.in 2012-03-28 19:55:12.000000000 +0200 +--- src/testdir/test84.in 2012-03-28 19:46:53.000000000 +0200 +*************** +*** 0 **** +--- 1,35 ---- ++ Tests for curswant not changing when setting an option ++ ++ STARTTEST ++ :so small.vim ++ :/^start target options$/+1,/^end target options$/-1 yank ++ :let target_option_names = split(@0) ++ :function TestCurswant(option_name) ++ : normal! ggf8j ++ : let curswant_before = winsaveview().curswant ++ : execute 'let' '&'.a:option_name '=' '&'.a:option_name ++ : let curswant_after = winsaveview().curswant ++ : return [a:option_name, curswant_before, curswant_after] ++ :endfunction ++ : ++ :new ++ :put =['1234567890', '12345'] ++ :1 delete _ ++ :let result = [] ++ :for option_name in target_option_names ++ : call add(result, TestCurswant(option_name)) ++ :endfor ++ : ++ :new ++ :put =map(copy(result), 'join(v:val, '' '')') ++ :1 delete _ ++ :write test.out ++ : ++ :qall! ++ ENDTEST ++ ++ start target options ++ tabstop ++ timeoutlen ++ ttimeoutlen ++ end target options +*** ../vim-7.3.486/src/testdir/test84.ok 2012-03-28 19:55:12.000000000 +0200 +--- src/testdir/test84.ok 2012-03-28 19:48:36.000000000 +0200 +*************** +*** 0 **** +--- 1,3 ---- ++ tabstop 7 4 ++ timeoutlen 7 7 ++ ttimeoutlen 7 7 +*** ../vim-7.3.486/src/testdir/Make_amiga.mak 2011-10-12 19:53:31.000000000 +0200 +--- src/testdir/Make_amiga.mak 2012-03-28 18:14:08.000000000 +0200 +*************** +*** 29,35 **** + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out test83.out + + .SUFFIXES: .in .out + +--- 29,35 ---- + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out test83.out test84.out + + .SUFFIXES: .in .out + +*************** +*** 132,134 **** +--- 132,135 ---- + test81.out: test81.in + test82.out: test82.in + test83.out: test83.in ++ test84.out: test84.in +*** ../vim-7.3.486/src/testdir/Make_dos.mak 2011-10-12 19:53:31.000000000 +0200 +--- src/testdir/Make_dos.mak 2012-03-28 18:14:41.000000000 +0200 +*************** +*** 29,35 **** + test42.out test52.out test65.out test66.out test67.out \ + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ +! test79.out test80.out test81.out test82.out test83.out + + SCRIPTS32 = test50.out test70.out + +--- 29,36 ---- + test42.out test52.out test65.out test66.out test67.out \ + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ +! test79.out test80.out test81.out test82.out test83.out \ +! test84.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.486/src/testdir/Make_ming.mak 2011-10-12 19:53:31.000000000 +0200 +--- src/testdir/Make_ming.mak 2012-03-28 18:14:46.000000000 +0200 +*************** +*** 49,55 **** + test42.out test52.out test65.out test66.out test67.out \ + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ +! test79.out test80.out test81.out test82.out test83.out + + SCRIPTS32 = test50.out test70.out + +--- 49,56 ---- + test42.out test52.out test65.out test66.out test67.out \ + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ +! test79.out test80.out test81.out test82.out test83.out \ +! test84.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.486/src/testdir/Make_os2.mak 2011-10-12 19:53:31.000000000 +0200 +--- src/testdir/Make_os2.mak 2012-03-28 18:15:00.000000000 +0200 +*************** +*** 29,35 **** + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out test83.out + + .SUFFIXES: .in .out + +--- 29,35 ---- + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out test83.out test84.out + + .SUFFIXES: .in .out + +*** ../vim-7.3.486/src/testdir/Make_vms.mms 2011-10-12 19:53:31.000000000 +0200 +--- src/testdir/Make_vms.mms 2012-03-28 18:15:15.000000000 +0200 +*************** +*** 4,10 **** + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2011 Jul 15 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +--- 4,10 ---- + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2012 Mar 28 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +*************** +*** 76,82 **** + test66.out test67.out test68.out test69.out \ + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ +! test82.out test83.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +--- 76,82 ---- + test66.out test67.out test68.out test69.out \ + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ +! test82.out test83.out test84.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +*** ../vim-7.3.486/src/testdir/Makefile 2011-10-12 19:53:31.000000000 +0200 +--- src/testdir/Makefile 2012-03-28 18:15:29.000000000 +0200 +*************** +*** 26,32 **** + test64.out test65.out test66.out test67.out test68.out \ + test69.out test70.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ +! test79.out test80.out test81.out test82.out test83.out + + SCRIPTS_GUI = test16.out + +--- 26,33 ---- + test64.out test65.out test66.out test67.out test68.out \ + test69.out test70.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ +! test79.out test80.out test81.out test82.out test83.out \ +! test84.out + + SCRIPTS_GUI = test16.out + +*** ../vim-7.3.486/src/version.c 2012-03-28 17:43:06.000000000 +0200 +--- src/version.c 2012-03-28 19:49:41.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 487, + /**/ + +-- +"Time flies like an arrow". So I put an arrow on my desk, now +awaiting one of these time flies showing up. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 13577ba917fd9ed482fa012ed0f05d645d001548 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:15 +0200 Subject: [PATCH 0220/3340] - patchlevel 488 --- 7.3.488 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.488 diff --git a/7.3.488 b/7.3.488 new file mode 100644 index 00000000..e0787404 --- /dev/null +++ b/7.3.488 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.488 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.488 +Problem: ":help!" in a help file does not work as document. +Solution: When in a help file don't give an error message. (thinca) +Files: src/ex_cmds.c + + +*** ../vim-7.3.487/src/ex_cmds.c 2012-03-16 14:32:10.000000000 +0100 +--- src/ex_cmds.c 2012-04-01 14:25:35.000000000 +0200 +*************** +*** 5546,5552 **** + } + arg = eap->arg; + +! if (eap->forceit && *arg == NUL) + { + EMSG(_("E478: Don't panic!")); + return; +--- 5546,5552 ---- + } + arg = eap->arg; + +! if (eap->forceit && *arg == NUL && !curbuf->b_help) + { + EMSG(_("E478: Don't panic!")); + return; +*** ../vim-7.3.487/src/version.c 2012-03-28 19:58:34.000000000 +0200 +--- src/version.c 2012-04-05 16:04:13.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 488, + /**/ + + +-- +I'd like to meet the man who invented sex and see what he's working on now. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 698978d86e2fea7bc1f92eeaccd3a50849bd3004 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:15 +0200 Subject: [PATCH 0221/3340] - patchlevel 489 --- 7.3.489 | 89 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) create mode 100644 7.3.489 diff --git a/7.3.489 b/7.3.489 new file mode 100644 index 00000000..fbdf2c39 --- /dev/null +++ b/7.3.489 @@ -0,0 +1,89 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.489 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.489 +Problem: CTRL-] in Insert mode does not expand abbreviation when used in a + mapping. (Yichao Zhou) +Solution: Special case using CTRL-]. (Christian Brabandt) +Files: src/getchar.c, src/edit.c + + +*** ../vim-7.3.488/src/getchar.c 2012-02-05 22:05:44.000000000 +0100 +--- src/getchar.c 2012-04-05 15:54:00.000000000 +0200 +*************** +*** 4352,4359 **** + + if (typebuf.tb_no_abbr_cnt) /* abbrev. are not recursive */ + return FALSE; +! if ((KeyNoremap & (RM_NONE|RM_SCRIPT)) != 0) +! /* no remapping implies no abbreviation */ + return FALSE; + + /* +--- 4352,4360 ---- + + if (typebuf.tb_no_abbr_cnt) /* abbrev. are not recursive */ + return FALSE; +! +! /* no remapping implies no abbreviation, except for CTRL-] */ +! if ((KeyNoremap & (RM_NONE|RM_SCRIPT)) != 0 && c != Ctrl_RSB) + return FALSE; + + /* +*** ../vim-7.3.488/src/edit.c 2012-02-29 18:22:03.000000000 +0100 +--- src/edit.c 2012-04-05 15:57:46.000000000 +0200 +*************** +*** 1455,1467 **** + Insstart_blank_vcol = get_nolist_virtcol(); + } + +! if (vim_iswordc(c) || !echeck_abbr( + #ifdef FEAT_MBYTE + /* Add ABBR_OFF for characters above 0x100, this is + * what check_abbr() expects. */ + (has_mbyte && c >= 0x100) ? (c + ABBR_OFF) : + #endif +! c)) + { + insert_special(c, FALSE, FALSE); + #ifdef FEAT_RIGHTLEFT +--- 1455,1470 ---- + Insstart_blank_vcol = get_nolist_virtcol(); + } + +! /* Insert a normal character and check for abbreviations on a +! * special character. Let CTRL-] expand abbreviations without +! * inserting it. */ +! if (vim_iswordc(c) || (!echeck_abbr( + #ifdef FEAT_MBYTE + /* Add ABBR_OFF for characters above 0x100, this is + * what check_abbr() expects. */ + (has_mbyte && c >= 0x100) ? (c + ABBR_OFF) : + #endif +! c) && c != Ctrl_RSB)) + { + insert_special(c, FALSE, FALSE); + #ifdef FEAT_RIGHTLEFT +*** ../vim-7.3.488/src/version.c 2012-04-05 16:04:58.000000000 +0200 +--- src/version.c 2012-04-05 16:06:12.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 489, + /**/ + +-- +Just think of all the things we haven't thought of yet. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b81f34ea93c23e6ee51b10baf857bc2d36d11fff Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:16 +0200 Subject: [PATCH 0222/3340] - patchlevel 490 --- 7.3.490 | 2517 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 2517 insertions(+) create mode 100644 7.3.490 diff --git a/7.3.490 b/7.3.490 new file mode 100644 index 00000000..6c49a48d --- /dev/null +++ b/7.3.490 @@ -0,0 +1,2517 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.490 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.490 +Problem: Member confusion in Lua interface. +Solution: Fix it. Add luaeval(). (Taro Muraoka, Luis Carvalho) +Files: runtime/doc/if_lua.txt, src/eval.c, src/if_lua.c, + src/proto/if_lua.pro + + +*** ../vim-7.3.489/runtime/doc/if_lua.txt 2010-08-15 21:57:14.000000000 +0200 +--- runtime/doc/if_lua.txt 2012-04-05 16:41:35.000000000 +0200 +*************** +*** 1,4 **** +! *if_lua.txt* For Vim version 7.3. Last change: 2010 Jul 22 + + + VIM REFERENCE MANUAL by Luis Carvalho +--- 1,4 ---- +! *if_lua.txt* For Vim version 7.3. Last change: 2012 Jan 16 + + + VIM REFERENCE MANUAL by Luis Carvalho +*************** +*** 8,15 **** + + 1. Commands |lua-commands| + 2. The vim module |lua-vim| +! 3. Buffer userdata |lua-buffer| +! 4. Window userdata |lua-window| + + {Vi does not have any of these commands} + +--- 8,18 ---- + + 1. Commands |lua-commands| + 2. The vim module |lua-vim| +! 3. List userdata |lua-list| +! 4. Dict userdata |lua-dict| +! 5. Buffer userdata |lua-buffer| +! 6. Window userdata |lua-window| +! 7. The luaeval function |lua-luaeval| + + {Vi does not have any of these commands} + +*************** +*** 88,98 **** + All these commands execute a Lua chunk from either the command line (:lua and + :luado) or a file (:luafile) with the given line [range]. Similarly to the Lua + interpreter, each chunk has its own scope and so only global variables are +! shared between command calls. Lua default libraries "table", "string", "math", +! and "package" are available, "io" and "debug" are not, and "os" is restricted +! to functions "date", "clock", "time", "difftime", and "getenv". In addition, +! Lua "print" function has its output redirected to the Vim message area, with +! arguments separated by a white space instead of a tab. + + Lua uses the "vim" module (see |lua-vim|) to issue commands to Vim + and manage buffers (|lua-buffer|) and windows (|lua-window|). However, +--- 91,99 ---- + All these commands execute a Lua chunk from either the command line (:lua and + :luado) or a file (:luafile) with the given line [range]. Similarly to the Lua + interpreter, each chunk has its own scope and so only global variables are +! shared between command calls. All Lua default libraries are available. In +! addition, Lua "print" function has its output redirected to the Vim message +! area, with arguments separated by a white space instead of a tab. + + Lua uses the "vim" module (see |lua-vim|) to issue commands to Vim + and manage buffers (|lua-buffer|) and windows (|lua-window|). However, +*************** +*** 108,116 **** + module also includes routines for buffer, window, and current line queries, + Vim evaluation and command execution, and others. + +! vim.isbuffer(value) Returns 'true' (boolean, not string) if +! "value" is a buffer userdata and 'false' +! otherwise (see |lua-buffer|). + + vim.buffer([arg]) If "arg" is a number, returns buffer with + number "arg" in the buffer list or, if "arg" +--- 109,117 ---- + module also includes routines for buffer, window, and current line queries, + Vim evaluation and command execution, and others. + +! vim.list() Returns an empty list (see |List|). +! +! vim.dict() Returns an empty dictionary (see |Dictionary|). + + vim.buffer([arg]) If "arg" is a number, returns buffer with + number "arg" in the buffer list or, if "arg" +*************** +*** 121,136 **** + 'true' returns the first buffer in the buffer + list or else the current buffer. + +- vim.iswindow(value) Returns 'true' (boolean, not string) if +- "value" is a window userdata and +- 'false' otherwise (see |lua-window|). +- + vim.window([arg]) If "arg" is a number, returns window with + number "arg" or 'nil' (nil value, not string) + if not found. Otherwise, if "toboolean(arg)" + is 'true' returns the first window or else the + current window. + + vim.command({cmd}) Executes the vim (ex-mode) command {cmd}. + Examples: > + :lua vim.command"set tw=60" +--- 122,142 ---- + 'true' returns the first buffer in the buffer + list or else the current buffer. + + vim.window([arg]) If "arg" is a number, returns window with + number "arg" or 'nil' (nil value, not string) + if not found. Otherwise, if "toboolean(arg)" + is 'true' returns the first window or else the + current window. + ++ vim.type({arg}) Returns the type of {arg}. It is equivalent to ++ Lua's "type" function, but returns "list", ++ "dict", "buffer", or "window" if {arg} is a ++ list, dictionary, buffer, or window, ++ respectively. Examples: > ++ :lua l = vim.list() ++ :lua print(type(l), vim.type(l)) ++ :" userdata list ++ < + vim.command({cmd}) Executes the vim (ex-mode) command {cmd}. + Examples: > + :lua vim.command"set tw=60" +*************** +*** 141,147 **** + Vim strings and numbers are directly converted + to Lua strings and numbers respectively. Vim + lists and dictionaries are converted to Lua +! tables (lists become integer-keyed tables). + Examples: > + :lua tw = vim.eval"&tw" + :lua print(vim.eval"{'a': 'one'}".a) +--- 147,153 ---- + Vim strings and numbers are directly converted + to Lua strings and numbers respectively. Vim + lists and dictionaries are converted to Lua +! userdata (see |lua-list| and |lua-dict|). + Examples: > + :lua tw = vim.eval"&tw" + :lua print(vim.eval"{'a': 'one'}".a) +*************** +*** 157,163 **** + + + ============================================================================== +! 3. Buffer userdata *lua-buffer* + + Buffer userdata represent vim buffers. A buffer userdata "b" has the following + properties and methods: +--- 163,234 ---- + + + ============================================================================== +! 3. List userdata *lua-list* +! +! List userdata represent vim lists, and the interface tries to follow closely +! Vim's syntax for lists. Since lists are objects, changes in list references in +! Lua are reflected in Vim and vice-versa. A list "l" has the following +! properties and methods: +! +! Properties +! ---------- +! o "#l" is the number of items in list "l", equivalent to "len(l)" +! in Vim. +! o "l[k]" returns the k-th item in "l"; "l" is zero-indexed, as in Vim. +! To modify the k-th item, simply do "l[k] = newitem"; in +! particular, "l[k] = nil" removes the k-th item from "l". +! o "l()" returns an iterator for "l". +! +! Methods +! ------- +! o "l:add(item)" appends "item" to the end of "l". +! o "l:insert(item[, pos])" inserts "item" at (optional) +! position "pos" in the list. The default value for "pos" is 0. +! +! Examples: +! > +! :let l = [1, 'item'] +! :lua l = vim.eval('l') -- same 'l' +! :lua l:add(vim.list()) +! :lua l[0] = math.pi +! :echo l[0] " 3.141593 +! :lua l[0] = nil -- remove first item +! :lua l:insert(true, 1) +! :lua print(l, #l, l[0], l[1], l[-1]) +! :lua for item in l() do print(item) end +! < +! +! ============================================================================== +! 4. Dict userdata *lua-dict* +! +! Similarly to list userdata, dict userdata represent vim dictionaries; since +! dictionaries are also objects, references are kept between Lua and Vim. A dict +! "d" has the following properties: +! +! Properties +! ---------- +! o "#d" is the number of items in dict "d", equivalent to "len(d)" +! in Vim. +! o "d.key" or "d['key']" returns the value at entry "key" in "d". +! To modify the entry at this key, simply do "d.key = newvalue"; in +! particular, "d.key = nil" removes the entry from "d". +! o "d()" returns an iterator for "d" and is equivalent to "items(d)" in +! Vim. +! +! Examples: +! > +! :let d = {'n':10} +! :lua d = vim.eval('d') -- same 'd' +! :lua print(d, d.n, #d) +! :let d.self = d +! :lua for k, v in d() do print(d, k, v) end +! :lua d.x = math.pi +! :lua d.self = nil -- remove entry +! :echo d +! < +! +! ============================================================================== +! 5. Buffer userdata *lua-buffer* + + Buffer userdata represent vim buffers. A buffer userdata "b" has the following + properties and methods: +*************** +*** 209,215 **** + < + + ============================================================================== +! 4. Window userdata *lua-window* + + Window objects represent vim windows. A window userdata "w" has the following + properties and methods: +--- 280,286 ---- + < + + ============================================================================== +! 6. Window userdata *lua-window* + + Window objects represent vim windows. A window userdata "w" has the following + properties and methods: +*************** +*** 241,244 **** + < + + ============================================================================== +! vim:tw=78:ts=8:ft=help:norl: +--- 312,340 ---- + < + + ============================================================================== +! 7. The luaeval function *lua-luaeval* +! +! The (dual) equivalent of "vim.eval" for passing Lua values to Vim is +! "luaeval". "luaeval" takes an expression string and an optional argument and +! returns the result of the expression. It is semantically equivalent in Lua to: +! > +! local chunkheader = "local _A = select(1, ...) return " +! function luaeval (expstr, arg) +! local chunk = assert(loadstring(chunkheader .. expstr, "luaeval")) +! return chunk(arg) -- return typval +! end +! < +! Note that "_A" receives the argument to "luaeval". Examples: > +! +! :echo luaeval('math.pi') +! :lua a = vim.list():add('newlist') +! :let a = luaeval('a') +! :echo a[0] " 'newlist' +! :function Rand(x,y) " random uniform between x and y +! : return luaeval('(_A.y-_A.x)*math.random()+_A.x', {'x':a:x,'y':a:y}) +! : endfunction +! :echo Rand(1,10) +! +! +! ============================================================================== +! vim:tw=78:ts=8:noet:ft=help:norl: +*** ../vim-7.3.489/src/eval.c 2012-03-28 16:49:25.000000000 +0200 +--- src/eval.c 2012-04-05 16:41:35.000000000 +0200 +*************** +*** 622,627 **** +--- 622,630 ---- + static void f_log __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_log10 __ARGS((typval_T *argvars, typval_T *rettv)); + #endif ++ #ifdef FEAT_LUA ++ static void f_luaeval __ARGS((typval_T *argvars, typval_T *rettv)); ++ #endif + static void f_map __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_maparg __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_mapcheck __ARGS((typval_T *argvars, typval_T *rettv)); +*************** +*** 6777,6782 **** +--- 6780,6789 ---- + /* v: vars */ + set_ref_in_ht(&vimvarht, copyID); + ++ #ifdef FEAT_LUA ++ set_ref_in_lua(copyID); ++ #endif ++ + /* + * 2. Free lists and dictionaries that are not referenced. + */ +*************** +*** 7946,7951 **** +--- 7953,7961 ---- + {"log", 1, 1, f_log}, + {"log10", 1, 1, f_log10}, + #endif ++ #ifdef FEAT_LUA ++ {"luaeval", 1, 2, f_luaeval}, ++ #endif + {"map", 2, 2, f_map}, + {"maparg", 1, 4, f_maparg}, + {"mapcheck", 1, 3, f_mapcheck}, +*************** +*** 13626,13631 **** +--- 13636,13658 ---- + } + #endif + ++ #ifdef FEAT_LUA ++ /* ++ * "luaeval()" function ++ */ ++ static void ++ f_luaeval(argvars, rettv) ++ typval_T *argvars; ++ typval_T *rettv; ++ { ++ char_u *str; ++ char_u buf[NUMBUFLEN]; ++ ++ str = get_tv_string_buf(&argvars[0], buf); ++ do_luaeval(str, argvars + 1, rettv); ++ } ++ #endif ++ + /* + * "map()" function + */ +*** ../vim-7.3.489/src/if_lua.c 2011-12-08 16:00:12.000000000 +0100 +--- src/if_lua.c 2012-04-05 16:41:35.000000000 +0200 +*************** +*** 1,4 **** +! /* vi:set ts=8 sts=4 sw=4: + * + * VIM - Vi IMproved by Bram Moolenaar + * +--- 1,4 ---- +! /* vi:set ts=8 sts=4 sw=4 noet: + * + * VIM - Vi IMproved by Bram Moolenaar + * +*************** +*** 21,35 **** +--- 21,53 ---- + + #define LUAVIM_CHUNKNAME "vim chunk" + #define LUAVIM_NAME "vim" ++ #define LUAVIM_EVALNAME "luaeval" ++ #define LUAVIM_EVALHEADER "local _A=select(1,...) return " + + typedef buf_T *luaV_Buffer; + typedef win_T *luaV_Window; ++ typedef dict_T *luaV_Dict; ++ typedef list_T *luaV_List; + typedef void (*msgfunc_T)(char_u *); + ++ static const char LUAVIM_DICT[] = "dict"; ++ static const char LUAVIM_LIST[] = "list"; + static const char LUAVIM_BUFFER[] = "buffer"; + static const char LUAVIM_WINDOW[] = "window"; + static const char LUAVIM_FREE[] = "luaV_free"; ++ static const char LUAVIM_LUAEVAL[] = "luaV_luaeval"; ++ static const char LUAVIM_SETREF[] = "luaV_setref"; + ++ /* most functions are closures with a cache table as first upvalue; ++ * get/setudata manage references to vim userdata in cache table through ++ * object pointers (light userdata) */ ++ #define luaV_getudata(L, v) \ ++ lua_pushlightuserdata((L), (void *) (v)); \ ++ lua_rawget((L), lua_upvalueindex(1)) ++ #define luaV_setudata(L, v) \ ++ lua_pushlightuserdata((L), (void *) (v)); \ ++ lua_pushvalue((L), -2); \ ++ lua_rawset((L), lua_upvalueindex(1)) + #define luaV_getfield(L, s) \ + lua_pushlightuserdata((L), (void *)(s)); \ + lua_rawget((L), LUA_REGISTRYINDEX) +*************** +*** 38,43 **** +--- 56,70 ---- + #define luaV_msg(L) luaV_msgfunc((L), (msgfunc_T) msg) + #define luaV_emsg(L) luaV_msgfunc((L), (msgfunc_T) emsg) + ++ static luaV_List *luaV_pushlist (lua_State *L, list_T *lis); ++ static luaV_Dict *luaV_pushdict (lua_State *L, dict_T *dic); ++ ++ #if LUA_VERSION_NUM <= 501 ++ #define luaV_openlib(L, l, n) luaL_openlib(L, NULL, l, n) ++ #define luaL_typeerror luaL_typerror ++ #else ++ #define luaV_openlib luaL_setfuncs ++ #endif + + #ifdef DYNAMIC_LUA + +*************** +*** 54,85 **** + #endif + + /* lauxlib */ + #define luaL_register dll_luaL_register + #define luaL_typerror dll_luaL_typerror + #define luaL_checklstring dll_luaL_checklstring + #define luaL_checkinteger dll_luaL_checkinteger + #define luaL_optinteger dll_luaL_optinteger + #define luaL_checktype dll_luaL_checktype + #define luaL_error dll_luaL_error +- #define luaL_loadfile dll_luaL_loadfile +- #define luaL_loadbuffer dll_luaL_loadbuffer + #define luaL_newstate dll_luaL_newstate + #define luaL_buffinit dll_luaL_buffinit +- #define luaL_prepbuffer dll_luaL_prepbuffer + #define luaL_addlstring dll_luaL_addlstring + #define luaL_pushresult dll_luaL_pushresult + /* lua */ + #define lua_close dll_lua_close + #define lua_gettop dll_lua_gettop + #define lua_settop dll_lua_settop + #define lua_pushvalue dll_lua_pushvalue + #define lua_replace dll_lua_replace + #define lua_isnumber dll_lua_isnumber + #define lua_isstring dll_lua_isstring + #define lua_type dll_lua_type + #define lua_rawequal dll_lua_rawequal +- #define lua_tonumber dll_lua_tonumber +- #define lua_tointeger dll_lua_tointeger + #define lua_toboolean dll_lua_toboolean + #define lua_tolstring dll_lua_tolstring + #define lua_touserdata dll_lua_touserdata +--- 81,134 ---- + #endif + + /* lauxlib */ ++ #if LUA_VERSION_NUM <= 501 + #define luaL_register dll_luaL_register ++ #define luaL_prepbuffer dll_luaL_prepbuffer ++ #define luaL_openlib dll_luaL_openlib + #define luaL_typerror dll_luaL_typerror ++ #define luaL_loadfile dll_luaL_loadfile ++ #define luaL_loadbuffer dll_luaL_loadbuffer ++ #else ++ #define luaL_prepbuffsize dll_luaL_prepbuffsize ++ #define luaL_setfuncs dll_luaL_setfuncs ++ #define luaL_loadfilex dll_luaL_loadfilex ++ #define luaL_loadbufferx dll_luaL_loadbufferx ++ #define luaL_argerror dll_luaL_argerror ++ #endif + #define luaL_checklstring dll_luaL_checklstring + #define luaL_checkinteger dll_luaL_checkinteger + #define luaL_optinteger dll_luaL_optinteger + #define luaL_checktype dll_luaL_checktype + #define luaL_error dll_luaL_error + #define luaL_newstate dll_luaL_newstate + #define luaL_buffinit dll_luaL_buffinit + #define luaL_addlstring dll_luaL_addlstring + #define luaL_pushresult dll_luaL_pushresult + /* lua */ ++ #if LUA_VERSION_NUM <= 501 ++ #define lua_tonumber dll_lua_tonumber ++ #define lua_tointeger dll_lua_tointeger ++ #define lua_call dll_lua_call ++ #define lua_pcall dll_lua_pcall ++ #else ++ #define lua_tonumberx dll_lua_tonumberx ++ #define lua_tointegerx dll_lua_tointegerx ++ #define lua_callk dll_lua_callk ++ #define lua_pcallk dll_lua_pcallk ++ #define lua_getglobal dll_lua_getglobal ++ #define lua_setglobal dll_lua_setglobal ++ #define lua_typename dll_lua_typename ++ #endif + #define lua_close dll_lua_close + #define lua_gettop dll_lua_gettop + #define lua_settop dll_lua_settop + #define lua_pushvalue dll_lua_pushvalue + #define lua_replace dll_lua_replace ++ #define lua_remove dll_lua_remove + #define lua_isnumber dll_lua_isnumber + #define lua_isstring dll_lua_isstring + #define lua_type dll_lua_type + #define lua_rawequal dll_lua_rawequal + #define lua_toboolean dll_lua_toboolean + #define lua_tolstring dll_lua_tolstring + #define lua_touserdata dll_lua_touserdata +*************** +*** 94,109 **** + #define lua_pushlightuserdata dll_lua_pushlightuserdata + #define lua_getfield dll_lua_getfield + #define lua_rawget dll_lua_rawget + #define lua_createtable dll_lua_createtable + #define lua_newuserdata dll_lua_newuserdata + #define lua_getmetatable dll_lua_getmetatable + #define lua_setfield dll_lua_setfield + #define lua_rawset dll_lua_rawset + #define lua_rawseti dll_lua_rawseti +- #define lua_remove dll_lua_remove + #define lua_setmetatable dll_lua_setmetatable +- #define lua_call dll_lua_call +- #define lua_pcall dll_lua_pcall + /* libs */ + #define luaopen_base dll_luaopen_base + #define luaopen_table dll_luaopen_table +--- 143,156 ---- + #define lua_pushlightuserdata dll_lua_pushlightuserdata + #define lua_getfield dll_lua_getfield + #define lua_rawget dll_lua_rawget ++ #define lua_rawgeti dll_lua_rawgeti + #define lua_createtable dll_lua_createtable + #define lua_newuserdata dll_lua_newuserdata + #define lua_getmetatable dll_lua_getmetatable + #define lua_setfield dll_lua_setfield + #define lua_rawset dll_lua_rawset + #define lua_rawseti dll_lua_rawseti + #define lua_setmetatable dll_lua_setmetatable + /* libs */ + #define luaopen_base dll_luaopen_base + #define luaopen_table dll_luaopen_table +*************** +*** 116,147 **** + #define luaL_openlibs dll_luaL_openlibs + + /* lauxlib */ + void (*dll_luaL_register) (lua_State *L, const char *libname, const luaL_Reg *l); + int (*dll_luaL_typerror) (lua_State *L, int narg, const char *tname); + const char *(*dll_luaL_checklstring) (lua_State *L, int numArg, size_t *l); + lua_Integer (*dll_luaL_checkinteger) (lua_State *L, int numArg); + lua_Integer (*dll_luaL_optinteger) (lua_State *L, int nArg, lua_Integer def); + void (*dll_luaL_checktype) (lua_State *L, int narg, int t); + int (*dll_luaL_error) (lua_State *L, const char *fmt, ...); +- int (*dll_luaL_loadfile) (lua_State *L, const char *filename); +- int (*dll_luaL_loadbuffer) (lua_State *L, const char *buff, size_t sz, const char *name); + lua_State *(*dll_luaL_newstate) (void); + void (*dll_luaL_buffinit) (lua_State *L, luaL_Buffer *B); +- char *(*dll_luaL_prepbuffer) (luaL_Buffer *B); + void (*dll_luaL_addlstring) (luaL_Buffer *B, const char *s, size_t l); + void (*dll_luaL_pushresult) (luaL_Buffer *B); + /* lua */ + void (*dll_lua_close) (lua_State *L); + int (*dll_lua_gettop) (lua_State *L); + void (*dll_lua_settop) (lua_State *L, int idx); + void (*dll_lua_pushvalue) (lua_State *L, int idx); + void (*dll_lua_replace) (lua_State *L, int idx); + int (*dll_lua_isnumber) (lua_State *L, int idx); + int (*dll_lua_isstring) (lua_State *L, int idx); + int (*dll_lua_type) (lua_State *L, int idx); + int (*dll_lua_rawequal) (lua_State *L, int idx1, int idx2); +- lua_Number (*dll_lua_tonumber) (lua_State *L, int idx); +- lua_Integer (*dll_lua_tointeger) (lua_State *L, int idx); + int (*dll_lua_toboolean) (lua_State *L, int idx); + const char *(*dll_lua_tolstring) (lua_State *L, int idx, size_t *len); + void *(*dll_lua_touserdata) (lua_State *L, int idx); +--- 163,218 ---- + #define luaL_openlibs dll_luaL_openlibs + + /* lauxlib */ ++ #if LUA_VERSION_NUM <= 501 + void (*dll_luaL_register) (lua_State *L, const char *libname, const luaL_Reg *l); ++ char *(*dll_luaL_prepbuffer) (luaL_Buffer *B); ++ void (*dll_luaL_openlib) (lua_State *L, const char *libname, const luaL_Reg *l, int nup); + int (*dll_luaL_typerror) (lua_State *L, int narg, const char *tname); ++ int (*dll_luaL_loadfile) (lua_State *L, const char *filename); ++ int (*dll_luaL_loadbuffer) (lua_State *L, const char *buff, size_t sz, const char *name); ++ #else ++ char *(*dll_luaL_prepbuffsize) (luaL_Buffer *B, size_t sz); ++ void (*dll_luaL_setfuncs) (lua_State *L, const luaL_Reg *l, int nup); ++ int (*dll_luaL_loadfilex) (lua_State *L, const char *filename, const char *mode); ++ int (*dll_luaL_loadbufferx) (lua_State *L, const char *buff, size_t sz, const char *name, const char *mode); ++ int (*dll_luaL_argerror) (lua_State *L, int numarg, const char *extramsg); ++ #endif + const char *(*dll_luaL_checklstring) (lua_State *L, int numArg, size_t *l); + lua_Integer (*dll_luaL_checkinteger) (lua_State *L, int numArg); + lua_Integer (*dll_luaL_optinteger) (lua_State *L, int nArg, lua_Integer def); + void (*dll_luaL_checktype) (lua_State *L, int narg, int t); + int (*dll_luaL_error) (lua_State *L, const char *fmt, ...); + lua_State *(*dll_luaL_newstate) (void); + void (*dll_luaL_buffinit) (lua_State *L, luaL_Buffer *B); + void (*dll_luaL_addlstring) (luaL_Buffer *B, const char *s, size_t l); + void (*dll_luaL_pushresult) (luaL_Buffer *B); + /* lua */ ++ #if LUA_VERSION_NUM <= 501 ++ lua_Number (*dll_lua_tonumber) (lua_State *L, int idx); ++ lua_Integer (*dll_lua_tointeger) (lua_State *L, int idx); ++ void (*dll_lua_call) (lua_State *L, int nargs, int nresults); ++ int (*dll_lua_pcall) (lua_State *L, int nargs, int nresults, int errfunc); ++ #else ++ lua_Number (*dll_lua_tonumberx) (lua_State *L, int idx, int *isnum); ++ lua_Integer (*dll_lua_tointegerx) (lua_State *L, int idx, int *isnum); ++ void (*dll_lua_callk) (lua_State *L, int nargs, int nresults, int ctx, ++ lua_CFunction k); ++ int (*dll_lua_pcallk) (lua_State *L, int nargs, int nresults, int errfunc, ++ int ctx, lua_CFunction k); ++ void (*dll_lua_getglobal) (lua_State *L, const char *var); ++ void (*dll_lua_setglobal) (lua_State *L, const char *var); ++ const char *(*dll_lua_typename) (lua_State *L, int tp); ++ #endif + void (*dll_lua_close) (lua_State *L); + int (*dll_lua_gettop) (lua_State *L); + void (*dll_lua_settop) (lua_State *L, int idx); + void (*dll_lua_pushvalue) (lua_State *L, int idx); + void (*dll_lua_replace) (lua_State *L, int idx); ++ void (*dll_lua_remove) (lua_State *L, int idx); + int (*dll_lua_isnumber) (lua_State *L, int idx); + int (*dll_lua_isstring) (lua_State *L, int idx); + int (*dll_lua_type) (lua_State *L, int idx); + int (*dll_lua_rawequal) (lua_State *L, int idx1, int idx2); + int (*dll_lua_toboolean) (lua_State *L, int idx); + const char *(*dll_lua_tolstring) (lua_State *L, int idx, size_t *len); + void *(*dll_lua_touserdata) (lua_State *L, int idx); +*************** +*** 156,171 **** + void (*dll_lua_pushlightuserdata) (lua_State *L, void *p); + void (*dll_lua_getfield) (lua_State *L, int idx, const char *k); + void (*dll_lua_rawget) (lua_State *L, int idx); + void (*dll_lua_createtable) (lua_State *L, int narr, int nrec); + void *(*dll_lua_newuserdata) (lua_State *L, size_t sz); + int (*dll_lua_getmetatable) (lua_State *L, int objindex); + void (*dll_lua_setfield) (lua_State *L, int idx, const char *k); + void (*dll_lua_rawset) (lua_State *L, int idx); + void (*dll_lua_rawseti) (lua_State *L, int idx, int n); +- void (*dll_lua_remove) (lua_State *L, int idx); + int (*dll_lua_setmetatable) (lua_State *L, int objindex); +- void (*dll_lua_call) (lua_State *L, int nargs, int nresults); +- int (*dll_lua_pcall) (lua_State *L, int nargs, int nresults, int errfunc); + /* libs */ + int (*dll_luaopen_base) (lua_State *L); + int (*dll_luaopen_table) (lua_State *L); +--- 227,240 ---- + void (*dll_lua_pushlightuserdata) (lua_State *L, void *p); + void (*dll_lua_getfield) (lua_State *L, int idx, const char *k); + void (*dll_lua_rawget) (lua_State *L, int idx); ++ void (*dll_lua_rawgeti) (lua_State *L, int idx, int n); + void (*dll_lua_createtable) (lua_State *L, int narr, int nrec); + void *(*dll_lua_newuserdata) (lua_State *L, size_t sz); + int (*dll_lua_getmetatable) (lua_State *L, int objindex); + void (*dll_lua_setfield) (lua_State *L, int idx, const char *k); + void (*dll_lua_rawset) (lua_State *L, int idx); + void (*dll_lua_rawseti) (lua_State *L, int idx, int n); + int (*dll_lua_setmetatable) (lua_State *L, int objindex); + /* libs */ + int (*dll_luaopen_base) (lua_State *L); + int (*dll_luaopen_table) (lua_State *L); +*************** +*** 185,216 **** + + static const luaV_Reg luaV_dll[] = { + /* lauxlib */ + {"luaL_register", (luaV_function) &dll_luaL_register}, + {"luaL_typerror", (luaV_function) &dll_luaL_typerror}, + {"luaL_checklstring", (luaV_function) &dll_luaL_checklstring}, + {"luaL_checkinteger", (luaV_function) &dll_luaL_checkinteger}, + {"luaL_optinteger", (luaV_function) &dll_luaL_optinteger}, + {"luaL_checktype", (luaV_function) &dll_luaL_checktype}, + {"luaL_error", (luaV_function) &dll_luaL_error}, +- {"luaL_loadfile", (luaV_function) &dll_luaL_loadfile}, +- {"luaL_loadbuffer", (luaV_function) &dll_luaL_loadbuffer}, + {"luaL_newstate", (luaV_function) &dll_luaL_newstate}, + {"luaL_buffinit", (luaV_function) &dll_luaL_buffinit}, +- {"luaL_prepbuffer", (luaV_function) &dll_luaL_prepbuffer}, + {"luaL_addlstring", (luaV_function) &dll_luaL_addlstring}, + {"luaL_pushresult", (luaV_function) &dll_luaL_pushresult}, + /* lua */ + {"lua_close", (luaV_function) &dll_lua_close}, + {"lua_gettop", (luaV_function) &dll_lua_gettop}, + {"lua_settop", (luaV_function) &dll_lua_settop}, + {"lua_pushvalue", (luaV_function) &dll_lua_pushvalue}, + {"lua_replace", (luaV_function) &dll_lua_replace}, + {"lua_isnumber", (luaV_function) &dll_lua_isnumber}, + {"lua_isstring", (luaV_function) &dll_lua_isstring}, + {"lua_type", (luaV_function) &dll_lua_type}, + {"lua_rawequal", (luaV_function) &dll_lua_rawequal}, +- {"lua_tonumber", (luaV_function) &dll_lua_tonumber}, +- {"lua_tointeger", (luaV_function) &dll_lua_tointeger}, + {"lua_toboolean", (luaV_function) &dll_lua_toboolean}, + {"lua_tolstring", (luaV_function) &dll_lua_tolstring}, + {"lua_touserdata", (luaV_function) &dll_lua_touserdata}, +--- 254,307 ---- + + static const luaV_Reg luaV_dll[] = { + /* lauxlib */ ++ #if LUA_VERSION_NUM <= 501 + {"luaL_register", (luaV_function) &dll_luaL_register}, ++ {"luaL_prepbuffer", (luaV_function) &dll_luaL_prepbuffer}, ++ {"luaL_openlib", (luaV_function) &dll_luaL_openlib}, + {"luaL_typerror", (luaV_function) &dll_luaL_typerror}, ++ {"luaL_loadfile", (luaV_function) &dll_luaL_loadfile}, ++ {"luaL_loadbuffer", (luaV_function) &dll_luaL_loadbuffer}, ++ #else ++ {"luaL_prepbuffsize", (luaV_function) &dll_luaL_prepbuffsize}, ++ {"luaL_setfuncs", (luaV_function) &dll_luaL_setfuncs}, ++ {"luaL_loadfilex", (luaV_function) &dll_luaL_loadfilex}, ++ {"luaL_loadbufferx", (luaV_function) &dll_luaL_loadbufferx}, ++ {"luaL_argerror", (luaV_function) &dll_luaL_argerror}, ++ #endif + {"luaL_checklstring", (luaV_function) &dll_luaL_checklstring}, + {"luaL_checkinteger", (luaV_function) &dll_luaL_checkinteger}, + {"luaL_optinteger", (luaV_function) &dll_luaL_optinteger}, + {"luaL_checktype", (luaV_function) &dll_luaL_checktype}, + {"luaL_error", (luaV_function) &dll_luaL_error}, + {"luaL_newstate", (luaV_function) &dll_luaL_newstate}, + {"luaL_buffinit", (luaV_function) &dll_luaL_buffinit}, + {"luaL_addlstring", (luaV_function) &dll_luaL_addlstring}, + {"luaL_pushresult", (luaV_function) &dll_luaL_pushresult}, + /* lua */ ++ #if LUA_VERSION_NUM <= 501 ++ {"lua_tonumber", (luaV_function) &dll_lua_tonumber}, ++ {"lua_tointeger", (luaV_function) &dll_lua_tointeger}, ++ {"lua_call", (luaV_function) &dll_lua_call}, ++ {"lua_pcall", (luaV_function) &dll_lua_pcall}, ++ #else ++ {"lua_tonumberx", (luaV_function) &dll_lua_tonumberx}, ++ {"lua_tointegerx", (luaV_function) &dll_lua_tointegerx}, ++ {"lua_callk", (luaV_function) &dll_lua_callk}, ++ {"lua_pcallk", (luaV_function) &dll_lua_pcallk}, ++ {"lua_getglobal", (luaV_function) &dll_lua_getglobal}, ++ {"lua_setglobal", (luaV_function) &dll_lua_setglobal}, ++ {"lua_typename", (luaV_function) &dll_lua_typename}, ++ #endif + {"lua_close", (luaV_function) &dll_lua_close}, + {"lua_gettop", (luaV_function) &dll_lua_gettop}, + {"lua_settop", (luaV_function) &dll_lua_settop}, + {"lua_pushvalue", (luaV_function) &dll_lua_pushvalue}, + {"lua_replace", (luaV_function) &dll_lua_replace}, ++ {"lua_remove", (luaV_function) &dll_lua_remove}, + {"lua_isnumber", (luaV_function) &dll_lua_isnumber}, + {"lua_isstring", (luaV_function) &dll_lua_isstring}, + {"lua_type", (luaV_function) &dll_lua_type}, + {"lua_rawequal", (luaV_function) &dll_lua_rawequal}, + {"lua_toboolean", (luaV_function) &dll_lua_toboolean}, + {"lua_tolstring", (luaV_function) &dll_lua_tolstring}, + {"lua_touserdata", (luaV_function) &dll_lua_touserdata}, +*************** +*** 225,240 **** + {"lua_pushlightuserdata", (luaV_function) &dll_lua_pushlightuserdata}, + {"lua_getfield", (luaV_function) &dll_lua_getfield}, + {"lua_rawget", (luaV_function) &dll_lua_rawget}, + {"lua_createtable", (luaV_function) &dll_lua_createtable}, + {"lua_newuserdata", (luaV_function) &dll_lua_newuserdata}, + {"lua_getmetatable", (luaV_function) &dll_lua_getmetatable}, + {"lua_setfield", (luaV_function) &dll_lua_setfield}, + {"lua_rawset", (luaV_function) &dll_lua_rawset}, + {"lua_rawseti", (luaV_function) &dll_lua_rawseti}, +- {"lua_remove", (luaV_function) &dll_lua_remove}, + {"lua_setmetatable", (luaV_function) &dll_lua_setmetatable}, +- {"lua_call", (luaV_function) &dll_lua_call}, +- {"lua_pcall", (luaV_function) &dll_lua_pcall}, + /* libs */ + {"luaopen_base", (luaV_function) &dll_luaopen_base}, + {"luaopen_table", (luaV_function) &dll_luaopen_table}, +--- 316,329 ---- + {"lua_pushlightuserdata", (luaV_function) &dll_lua_pushlightuserdata}, + {"lua_getfield", (luaV_function) &dll_lua_getfield}, + {"lua_rawget", (luaV_function) &dll_lua_rawget}, ++ {"lua_rawgeti", (luaV_function) &dll_lua_rawgeti}, + {"lua_createtable", (luaV_function) &dll_lua_createtable}, + {"lua_newuserdata", (luaV_function) &dll_lua_newuserdata}, + {"lua_getmetatable", (luaV_function) &dll_lua_getmetatable}, + {"lua_setfield", (luaV_function) &dll_lua_setfield}, + {"lua_rawset", (luaV_function) &dll_lua_rawset}, + {"lua_rawseti", (luaV_function) &dll_lua_rawseti}, + {"lua_setmetatable", (luaV_function) &dll_lua_setmetatable}, + /* libs */ + {"luaopen_base", (luaV_function) &dll_luaopen_base}, + {"luaopen_table", (luaV_function) &dll_luaopen_table}, +*************** +*** 294,299 **** +--- 383,398 ---- + + #endif /* DYNAMIC_LUA */ + ++ #if LUA_VERSION_NUM > 501 ++ static int ++ luaL_typeerror (lua_State *L, int narg, const char *tname) ++ { ++ const char *msg = lua_pushfstring(L, "%s expected, got %s", ++ tname, luaL_typename(L, narg)); ++ return luaL_argerror(L, narg, msg); ++ } ++ #endif ++ + + /* ======= Internal ======= */ + +*************** +*** 327,343 **** + } + + static void * + luaV_checkudata(lua_State *L, int ud, const char *tname) + { + void *p = luaV_toudata(L, ud, tname); +! if (p == NULL) luaL_typerror(L, ud, tname); + return p; + } + + static void + luaV_pushtypval(lua_State *L, typval_T *tv) + { +! if (tv == NULL) luaL_error(L, "null type"); + switch (tv->v_type) + { + case VAR_STRING: +--- 426,460 ---- + } + + static void * ++ luaV_checkcache(lua_State *L, void *p) ++ { ++ luaV_getudata(L, p); ++ if (lua_isnil(L, -1)) luaL_error(L, "invalid object"); ++ lua_pop(L, 1); ++ return p; ++ } ++ ++ #define luaV_unbox(L,luatyp,ud) (*((luatyp *) lua_touserdata((L),(ud)))) ++ ++ #define luaV_checkvalid(L,luatyp,ud) \ ++ luaV_checkcache((L), (void *) luaV_unbox((L),luatyp,(ud))) ++ ++ static void * + luaV_checkudata(lua_State *L, int ud, const char *tname) + { + void *p = luaV_toudata(L, ud, tname); +! if (p == NULL) luaL_typeerror(L, ud, tname); + return p; + } + + static void + luaV_pushtypval(lua_State *L, typval_T *tv) + { +! if (tv == NULL) +! { +! lua_pushnil(L); +! return; +! } + switch (tv->v_type) + { + case VAR_STRING: +*************** +*** 351,418 **** + lua_pushnumber(L, (lua_Number) tv->vval.v_float); + break; + #endif +! case VAR_LIST: { +! list_T *l = tv->vval.v_list; + +! if (l != NULL) + { +! /* check cache */ +! lua_pushlightuserdata(L, (void *) l); +! lua_rawget(L, LUA_ENVIRONINDEX); +! if (lua_isnil(L, -1)) /* not interned? */ + { +! listitem_T *li; +! int n = 0; +! lua_pop(L, 1); /* nil */ +! lua_newtable(L); +! lua_pushlightuserdata(L, (void *) l); +! lua_pushvalue(L, -2); +! lua_rawset(L, LUA_ENVIRONINDEX); +! for (li = l->lv_first; li != NULL; li = li->li_next) +! { +! luaV_pushtypval(L, &li->li_tv); +! lua_rawseti(L, -2, ++n); +! } + } +! } +! else lua_pushnil(L); +! break; +! } +! case VAR_DICT: { +! dict_T *d = tv->vval.v_dict; +! +! if (d != NULL) +! { +! /* check cache */ +! lua_pushlightuserdata(L, (void *) d); +! lua_rawget(L, LUA_ENVIRONINDEX); +! if (lua_isnil(L, -1)) /* not interned? */ + { +! hashtab_T *ht = &d->dv_hashtab; +! hashitem_T *hi; +! int n = ht->ht_used; /* remaining items */ +! lua_pop(L, 1); /* nil */ +! lua_newtable(L); +! lua_pushlightuserdata(L, (void *) d); +! lua_pushvalue(L, -2); +! lua_rawset(L, LUA_ENVIRONINDEX); +! for (hi = ht->ht_array; n > 0; hi++) +! { +! if (!HASHITEM_EMPTY(hi)) +! { +! dictitem_T *di = dict_lookup(hi); +! luaV_pushtypval(L, &di->di_tv); +! lua_setfield(L, -2, (char *) hi->hi_key); +! n--; +! } +! } + } + } +- else lua_pushnil(L); + break; + } + default: +! luaL_error(L, "invalid type"); + } + } + +--- 468,537 ---- + lua_pushnumber(L, (lua_Number) tv->vval.v_float); + break; + #endif +! case VAR_LIST: +! luaV_pushlist(L, tv->vval.v_list); +! break; +! case VAR_DICT: +! luaV_pushdict(L, tv->vval.v_dict); +! break; +! default: +! lua_pushnil(L); +! } +! } + +! /* converts lua value at 'pos' to typval 'tv' */ +! static void +! luaV_totypval (lua_State *L, int pos, typval_T *tv) +! { +! switch(lua_type(L, pos)) { +! case LUA_TBOOLEAN: +! tv->v_type = VAR_NUMBER; +! tv->vval.v_number = (varnumber_T) lua_toboolean(L, pos); +! break; +! case LUA_TSTRING: +! tv->v_type = VAR_STRING; +! tv->vval.v_string = vim_strsave((char_u *) lua_tostring(L, pos)); +! break; +! case LUA_TNUMBER: +! #ifdef FEAT_FLOAT +! tv->v_type = VAR_FLOAT; +! tv->vval.v_float = (float_T) lua_tonumber(L, pos); +! #else +! tv->v_type = VAR_NUMBER; +! tv->vval.v_number = (varnumber_T) lua_tointeger(L, pos); +! #endif +! break; +! case LUA_TUSERDATA: { +! void *p = lua_touserdata(L, pos); +! if (lua_getmetatable(L, pos)) /* has metatable? */ + { +! /* check list */ +! luaV_getfield(L, LUAVIM_LIST); +! if (lua_rawequal(L, -1, -2)) + { +! tv->v_type = VAR_LIST; +! tv->vval.v_list = *((luaV_List *) p); +! ++tv->vval.v_list->lv_refcount; +! lua_pop(L, 2); /* MTs */ +! return; + } +! /* check dict */ +! luaV_getfield(L, LUAVIM_DICT); +! if (lua_rawequal(L, -1, -3)) + { +! tv->v_type = VAR_DICT; +! tv->vval.v_dict = *((luaV_Dict *) p); +! ++tv->vval.v_dict->dv_refcount; +! lua_pop(L, 3); /* MTs */ +! return; + } ++ lua_pop(L, 3); /* MTs */ + } + break; + } + default: +! tv->v_type = VAR_NUMBER; +! tv->vval.v_number = 0; + } + } + +*************** +*** 481,569 **** + lua_pop(L, 2); /* original and modified strings */ + } + + +! /* ======= Buffer type ======= */ + +! static luaV_Buffer * +! luaV_newbuffer(lua_State *L, buf_T *buf) + { +! luaV_Buffer *b = (luaV_Buffer *) lua_newuserdata(L, sizeof(luaV_Buffer)); +! *b = buf; +! lua_pushlightuserdata(L, (void *) buf); +! lua_pushvalue(L, -2); +! lua_rawset(L, LUA_ENVIRONINDEX); /* env[buf] = udata */ +! /* to avoid GC, store as key in env */ +! lua_pushvalue(L, -1); +! lua_pushboolean(L, 1); +! lua_rawset(L, LUA_ENVIRONINDEX); /* env[udata] = true */ +! /* set metatable */ +! luaV_getfield(L, LUAVIM_BUFFER); + lua_setmetatable(L, -2); +! return b; + } + +! static luaV_Buffer * +! luaV_pushbuffer (lua_State *L, buf_T *buf) + { +! luaV_Buffer *b = NULL; +! if (buf == NULL) +! lua_pushnil(L); +! else { +! lua_pushlightuserdata(L, (void *) buf); +! lua_rawget(L, LUA_ENVIRONINDEX); +! if (lua_isnil(L, -1)) /* not interned? */ + { +! lua_pop(L, 1); +! b = luaV_newbuffer(L, buf); + } + else +! b = (luaV_Buffer *) lua_touserdata(L, -1); + } +! return b; + } + +! /* Buffer metamethods */ + + static int +! luaV_buffer_tostring(lua_State *L) + { +! lua_pushfstring(L, "%s: %p", LUAVIM_BUFFER, lua_touserdata(L, 1)); + return 1; + } + + static int + luaV_buffer_len(lua_State *L) + { +! luaV_Buffer *b = lua_touserdata(L, 1); +! lua_pushinteger(L, (*b)->b_ml.ml_line_count); + return 1; + } + + static int + luaV_buffer_call(lua_State *L) + { +! luaV_Buffer *b = (luaV_Buffer *) lua_touserdata(L, 1); + lua_settop(L, 1); +! set_curbuf(*b, DOBUF_SPLIT); + return 1; + } + + static int + luaV_buffer_index(lua_State *L) + { +! luaV_Buffer *b = (luaV_Buffer *) lua_touserdata(L, 1); + linenr_T n = (linenr_T) lua_tointeger(L, 2); +! if (n > 0 && n <= (*b)->b_ml.ml_line_count) +! luaV_pushline(L, *b, n); + else if (lua_isstring(L, 2)) + { + const char *s = lua_tostring(L, 2); + if (strncmp(s, "name", 4) == 0) +! lua_pushstring(L, (char *) (*b)->b_sfname); + else if (strncmp(s, "fname", 5) == 0) +! lua_pushstring(L, (char *) (*b)->b_ffname); + else if (strncmp(s, "number", 6) == 0) +! lua_pushinteger(L, (*b)->b_fnum); + /* methods */ + else if (strncmp(s, "insert", 6) == 0 + || strncmp(s, "next", 4) == 0 +--- 600,1107 ---- + lua_pop(L, 2); /* original and modified strings */ + } + ++ #define luaV_newtype(typ,tname,luatyp,luatname) \ ++ static luatyp * \ ++ luaV_new##tname (lua_State *L, typ *obj) \ ++ { \ ++ luatyp *o = (luatyp *) lua_newuserdata(L, sizeof(luatyp)); \ ++ *o = obj; \ ++ luaV_setudata(L, obj); /* cache[obj] = udata */ \ ++ luaV_getfield(L, luatname); \ ++ lua_setmetatable(L, -2); \ ++ return o; \ ++ } ++ ++ #define luaV_pushtype(typ,tname,luatyp) \ ++ static luatyp * \ ++ luaV_push##tname (lua_State *L, typ *obj) \ ++ { \ ++ luatyp *o = NULL; \ ++ if (obj == NULL) \ ++ lua_pushnil(L); \ ++ else { \ ++ luaV_getudata(L, obj); \ ++ if (lua_isnil(L, -1)) /* not interned? */ \ ++ { \ ++ lua_pop(L, 1); \ ++ o = luaV_new##tname(L, obj); \ ++ } \ ++ else \ ++ o = (luatyp *) lua_touserdata(L, -1); \ ++ } \ ++ return o; \ ++ } ++ ++ #define luaV_type_tostring(tname,luatname) \ ++ static int \ ++ luaV_##tname##_tostring (lua_State *L) \ ++ { \ ++ lua_pushfstring(L, "%s: %p", luatname, lua_touserdata(L, 1)); \ ++ return 1; \ ++ } ++ + +! /* adapted from eval.c */ +! +! #define listitem_alloc() (listitem_T *)alloc(sizeof(listitem_T)) +! +! static listitem_T * +! list_find (list_T *l, long n) +! { +! listitem_T *li; +! if (l == NULL || n < -l->lv_len || n >= l->lv_len) +! return NULL; +! if (n < 0) /* search backward? */ +! for (li = l->lv_last; n < -1; li = li->li_prev) +! n++; +! else /* search forward */ +! for (li = l->lv_first; n > 0; li = li->li_next) +! n--; +! return li; +! } + +! static void +! list_remove (list_T *l, listitem_T *li) + { +! listwatch_T *lw; +! --l->lv_len; +! /* fix watchers */ +! for (lw = l->lv_watch; lw != NULL; lw = lw->lw_next) +! if (lw->lw_item == li) +! lw->lw_item = li->li_next; +! /* fix list pointers */ +! if (li->li_next == NULL) /* last? */ +! l->lv_last = li->li_prev; +! else +! li->li_next->li_prev = li->li_prev; +! if (li->li_prev == NULL) /* first? */ +! l->lv_first = li->li_next; +! else +! li->li_prev->li_next = li->li_next; +! l->lv_idx_item = NULL; +! } +! +! static void +! list_append(list_T *l, listitem_T *item) +! { +! if (l->lv_last == NULL) /* empty list? */ +! l->lv_first = item; +! else +! l->lv_last->li_next = item; +! item->li_prev = l->lv_last; +! item->li_next = NULL; +! l->lv_last = item; +! ++l->lv_len; +! } +! +! static int +! list_insert_tv(list_T *l, typval_T *tv, listitem_T *item) +! { +! listitem_T *ni = listitem_alloc(); +! +! if (ni == NULL) +! return FAIL; +! copy_tv(tv, &ni->li_tv); +! if (item == NULL) +! list_append(l, ni); +! else +! { +! ni->li_prev = item->li_prev; +! ni->li_next = item; +! if (item->li_prev == NULL) +! { +! l->lv_first = ni; +! ++l->lv_idx; +! } +! else +! { +! item->li_prev->li_next = ni; +! l->lv_idx_item = NULL; +! } +! item->li_prev = ni; +! ++l->lv_len; +! } +! return OK; +! } +! +! /* set references */ +! +! static void set_ref_in_tv (typval_T *tv, int copyID); +! +! static void +! set_ref_in_dict(dict_T *d, int copyID) +! { +! hashtab_T *ht = &d->dv_hashtab; +! int n = ht->ht_used; +! hashitem_T *hi; +! for (hi = ht->ht_array; n > 0; ++hi) +! if (!HASHITEM_EMPTY(hi)) +! { +! dictitem_T *di = dict_lookup(hi); +! set_ref_in_tv(&di->di_tv, copyID); +! --n; +! } +! } +! +! static void +! set_ref_in_list(list_T *l, int copyID) +! { +! listitem_T *li; +! for (li = l->lv_first; li != NULL; li = li->li_next) +! set_ref_in_tv(&li->li_tv, copyID); +! } +! +! static void +! set_ref_in_tv(typval_T *tv, int copyID) +! { +! if (tv->v_type == VAR_LIST) +! { +! list_T *l = tv->vval.v_list; +! if (l != NULL && l->lv_copyID != copyID) +! { +! l->lv_copyID = copyID; +! set_ref_in_list(l, copyID); +! } +! } +! else if (tv->v_type == VAR_DICT) +! { +! dict_T *d = tv->vval.v_dict; +! if (d != NULL && d->dv_copyID != copyID) +! { +! d->dv_copyID = copyID; +! set_ref_in_dict(d, copyID); +! } +! } +! } +! +! +! /* ======= List type ======= */ +! +! static luaV_List * +! luaV_newlist (lua_State *L, list_T *lis) +! { +! luaV_List *l = (luaV_List *) lua_newuserdata(L, sizeof(luaV_List)); +! *l = lis; +! lis->lv_refcount++; /* reference in Lua */ +! luaV_setudata(L, lis); /* cache[lis] = udata */ +! luaV_getfield(L, LUAVIM_LIST); + lua_setmetatable(L, -2); +! return l; + } + +! luaV_pushtype(list_T, list, luaV_List) +! luaV_type_tostring(list, LUAVIM_LIST) +! +! static int +! luaV_list_gc (lua_State *L) + { +! list_unref(luaV_unbox(L, luaV_List, 1)); +! return 0; +! } +! +! static int +! luaV_list_len (lua_State *L) +! { +! list_T *l = luaV_unbox(L, luaV_List, 1); +! lua_pushinteger(L, (l == NULL) ? 0 : (int) l->lv_len); +! return 1; +! } +! +! static int +! luaV_list_iter (lua_State *L) +! { +! listitem_T *li = (listitem_T *) lua_touserdata(L, lua_upvalueindex(2)); +! if (li == NULL) return 0; +! luaV_pushtypval(L, &li->li_tv); +! lua_pushlightuserdata(L, (void *) li->li_next); +! lua_replace(L, lua_upvalueindex(2)); +! return 1; +! } +! +! static int +! luaV_list_call (lua_State *L) +! { +! list_T *l = luaV_unbox(L, luaV_List, 1); +! lua_pushvalue(L, lua_upvalueindex(1)); /* pass cache table along */ +! lua_pushlightuserdata(L, (void *) l->lv_first); +! lua_pushcclosure(L, luaV_list_iter, 2); +! return 1; +! } +! +! static int +! luaV_list_index (lua_State *L) +! { +! list_T *l = luaV_unbox(L, luaV_List, 1); +! if (lua_isnumber(L, 2)) /* list item? */ +! { +! listitem_T *li = list_find(l, (long) luaL_checkinteger(L, 2)); +! if (li == NULL) +! lua_pushnil(L); +! else +! luaV_pushtypval(L, &li->li_tv); +! } +! else if (lua_isstring(L, 2)) /* method? */ +! { +! const char *s = lua_tostring(L, 2); +! if (strncmp(s, "add", 3) == 0 +! || strncmp(s, "insert", 6) == 0 +! || strncmp(s, "extend", 6) == 0) + { +! lua_getmetatable(L, 1); +! lua_getfield(L, -1, s); + } + else +! lua_pushnil(L); + } +! else +! lua_pushnil(L); +! return 1; + } + +! static int +! luaV_list_newindex (lua_State *L) +! { +! list_T *l = luaV_unbox(L, luaV_List, 1); +! long n = (long) luaL_checkinteger(L, 2); +! listitem_T *li; +! if (l->lv_lock) +! luaL_error(L, "list is locked"); +! li = list_find(l, n); +! if (li == NULL) return 0; +! if (lua_isnil(L, 3)) /* remove? */ +! { +! list_remove(l, li); +! clear_tv(&li->li_tv); +! vim_free(li); +! } +! else +! { +! typval_T v; +! luaV_totypval(L, 3, &v); +! clear_tv(&li->li_tv); +! copy_tv(&v, &li->li_tv); +! } +! return 0; +! } + + static int +! luaV_list_add (lua_State *L) + { +! luaV_List *lis = luaV_checkudata(L, 1, LUAVIM_LIST); +! list_T *l = (list_T *) luaV_checkcache(L, (void *) *lis); +! listitem_T *li; +! if (l->lv_lock) +! luaL_error(L, "list is locked"); +! li = listitem_alloc(); +! if (li != NULL) +! { +! typval_T v; +! lua_settop(L, 2); +! luaV_totypval(L, 2, &v); +! copy_tv(&v, &li->li_tv); +! list_append(l, li); +! } +! lua_settop(L, 1); + return 1; + } + + static int ++ luaV_list_insert (lua_State *L) ++ { ++ luaV_List *lis = luaV_checkudata(L, 1, LUAVIM_LIST); ++ list_T *l = (list_T *) luaV_checkcache(L, (void *) *lis); ++ long pos = luaL_optlong(L, 3, 0); ++ listitem_T *li = NULL; ++ typval_T v; ++ if (l->lv_lock) ++ luaL_error(L, "list is locked"); ++ if (pos < l->lv_len) ++ { ++ li = list_find(l, pos); ++ if (li == NULL) ++ luaL_error(L, "invalid position"); ++ } ++ lua_settop(L, 2); ++ luaV_totypval(L, 2, &v); ++ list_insert_tv(l, &v, li); ++ lua_settop(L, 1); ++ return 1; ++ } ++ ++ static const luaL_Reg luaV_List_mt[] = { ++ {"__tostring", luaV_list_tostring}, ++ {"__gc", luaV_list_gc}, ++ {"__len", luaV_list_len}, ++ {"__call", luaV_list_call}, ++ {"__index", luaV_list_index}, ++ {"__newindex", luaV_list_newindex}, ++ {"add", luaV_list_add}, ++ {"insert", luaV_list_insert}, ++ {NULL, NULL} ++ }; ++ ++ ++ /* ======= Dict type ======= */ ++ ++ static luaV_Dict * ++ luaV_newdict (lua_State *L, dict_T *dic) ++ { ++ luaV_Dict *d = (luaV_Dict *) lua_newuserdata(L, sizeof(luaV_Dict)); ++ *d = dic; ++ dic->dv_refcount++; /* reference in Lua */ ++ luaV_setudata(L, dic); /* cache[dic] = udata */ ++ luaV_getfield(L, LUAVIM_DICT); ++ lua_setmetatable(L, -2); ++ return d; ++ } ++ ++ luaV_pushtype(dict_T, dict, luaV_Dict) ++ luaV_type_tostring(dict, LUAVIM_DICT) ++ ++ static int ++ luaV_dict_gc (lua_State *L) ++ { ++ dict_unref(luaV_unbox(L, luaV_Dict, 1)); ++ return 0; ++ } ++ ++ static int ++ luaV_dict_len (lua_State *L) ++ { ++ dict_T *d = luaV_unbox(L, luaV_Dict, 1); ++ lua_pushinteger(L, (d == NULL) ? 0 : (int) d->dv_hashtab.ht_used); ++ return 1; ++ } ++ ++ static int ++ luaV_dict_iter (lua_State *L) ++ { ++ hashitem_T *hi = (hashitem_T *) lua_touserdata(L, lua_upvalueindex(2)); ++ int n = lua_tointeger(L, lua_upvalueindex(3)); ++ dictitem_T *di; ++ if (n <= 0) return 0; ++ while (HASHITEM_EMPTY(hi)) hi++; ++ di = dict_lookup(hi); ++ lua_pushstring(L, (char *) hi->hi_key); ++ luaV_pushtypval(L, &di->di_tv); ++ lua_pushlightuserdata(L, (void *) (hi + 1)); ++ lua_replace(L, lua_upvalueindex(2)); ++ lua_pushinteger(L, n - 1); ++ lua_replace(L, lua_upvalueindex(3)); ++ return 2; ++ } ++ ++ static int ++ luaV_dict_call (lua_State *L) ++ { ++ dict_T *d = luaV_unbox(L, luaV_Dict, 1); ++ hashtab_T *ht = &d->dv_hashtab; ++ lua_pushvalue(L, lua_upvalueindex(1)); /* pass cache table along */ ++ lua_pushlightuserdata(L, (void *) ht->ht_array); ++ lua_pushinteger(L, ht->ht_used); /* # remaining items */ ++ lua_pushcclosure(L, luaV_dict_iter, 3); ++ return 1; ++ } ++ ++ static int ++ luaV_dict_index (lua_State *L) ++ { ++ dict_T *d = luaV_unbox(L, luaV_Dict, 1); ++ char_u *key = (char_u *) luaL_checkstring(L, 2); ++ dictitem_T *di = dict_find(d, key, -1); ++ if (di == NULL) ++ lua_pushnil(L); ++ else ++ luaV_pushtypval(L, &di->di_tv); ++ return 1; ++ } ++ ++ static int ++ luaV_dict_newindex (lua_State *L) ++ { ++ dict_T *d = luaV_unbox(L, luaV_Dict, 1); ++ char_u *key = (char_u *) luaL_checkstring(L, 2); ++ dictitem_T *di; ++ if (d->dv_lock) ++ luaL_error(L, "dict is locked"); ++ di = dict_find(d, key, -1); ++ if (di == NULL) /* non-existing key? */ ++ { ++ if (lua_isnil(L, 3)) return 0; ++ di = dictitem_alloc(key); ++ if (di == NULL) return 0; ++ if (dict_add(d, di) == FAIL) ++ { ++ vim_free(di); ++ return 0; ++ } ++ } ++ else ++ clear_tv(&di->di_tv); ++ if (lua_isnil(L, 3)) /* remove? */ ++ { ++ hashitem_T *hi = hash_find(&d->dv_hashtab, di->di_key); ++ hash_remove(&d->dv_hashtab, hi); ++ dictitem_free(di); ++ } ++ else { ++ typval_T v; ++ luaV_totypval(L, 3, &v); ++ copy_tv(&v, &di->di_tv); ++ } ++ return 0; ++ } ++ ++ static const luaL_Reg luaV_Dict_mt[] = { ++ {"__tostring", luaV_dict_tostring}, ++ {"__gc", luaV_dict_gc}, ++ {"__len", luaV_dict_len}, ++ {"__call", luaV_dict_call}, ++ {"__index", luaV_dict_index}, ++ {"__newindex", luaV_dict_newindex}, ++ {NULL, NULL} ++ }; ++ ++ ++ /* ======= Buffer type ======= */ ++ ++ luaV_newtype(buf_T, buffer, luaV_Buffer, LUAVIM_BUFFER) ++ luaV_pushtype(buf_T, buffer, luaV_Buffer) ++ luaV_type_tostring(buffer, LUAVIM_BUFFER) ++ ++ static int + luaV_buffer_len(lua_State *L) + { +! buf_T *b = (buf_T *) luaV_checkvalid(L, luaV_Buffer, 1); +! lua_pushinteger(L, b->b_ml.ml_line_count); + return 1; + } + + static int + luaV_buffer_call(lua_State *L) + { +! buf_T *b = (buf_T *) luaV_checkvalid(L, luaV_Buffer, 1); + lua_settop(L, 1); +! set_curbuf(b, DOBUF_SPLIT); + return 1; + } + + static int + luaV_buffer_index(lua_State *L) + { +! buf_T *b = (buf_T *) luaV_checkvalid(L, luaV_Buffer, 1); + linenr_T n = (linenr_T) lua_tointeger(L, 2); +! if (n > 0 && n <= b->b_ml.ml_line_count) +! luaV_pushline(L, b, n); + else if (lua_isstring(L, 2)) + { + const char *s = lua_tostring(L, 2); + if (strncmp(s, "name", 4) == 0) +! lua_pushstring(L, (char *) b->b_sfname); + else if (strncmp(s, "fname", 5) == 0) +! lua_pushstring(L, (char *) b->b_ffname); + else if (strncmp(s, "number", 6) == 0) +! lua_pushinteger(L, b->b_fnum); + /* methods */ + else if (strncmp(s, "insert", 6) == 0 + || strncmp(s, "next", 4) == 0 +*************** +*** 584,600 **** + static int + luaV_buffer_newindex(lua_State *L) + { +! luaV_Buffer *b = (luaV_Buffer *) lua_touserdata(L, 1); + linenr_T n = (linenr_T) luaL_checkinteger(L, 2); + #ifdef HAVE_SANDBOX + luaV_checksandbox(L); + #endif +! if (n < 1 || n > (*b)->b_ml.ml_line_count) + luaL_error(L, "invalid line number"); + if (lua_isnil(L, 3)) /* delete line */ + { + buf_T *buf = curbuf; +! curbuf = *b; + if (u_savedel(n, 1L) == FAIL) + { + curbuf = buf; +--- 1122,1138 ---- + static int + luaV_buffer_newindex(lua_State *L) + { +! buf_T *b = (buf_T *) luaV_checkvalid(L, luaV_Buffer, 1); + linenr_T n = (linenr_T) luaL_checkinteger(L, 2); + #ifdef HAVE_SANDBOX + luaV_checksandbox(L); + #endif +! if (n < 1 || n > b->b_ml.ml_line_count) + luaL_error(L, "invalid line number"); + if (lua_isnil(L, 3)) /* delete line */ + { + buf_T *buf = curbuf; +! curbuf = b; + if (u_savedel(n, 1L) == FAIL) + { + curbuf = buf; +*************** +*** 607,613 **** + } + else { + deleted_lines_mark(n, 1L); +! if (*b == curwin->w_buffer) /* fix cursor in current window? */ + { + if (curwin->w_cursor.lnum >= n) + { +--- 1145,1151 ---- + } + else { + deleted_lines_mark(n, 1L); +! if (b == curwin->w_buffer) /* fix cursor in current window? */ + { + if (curwin->w_cursor.lnum >= n) + { +*************** +*** 627,633 **** + else if (lua_isstring(L, 3)) /* update line */ + { + buf_T *buf = curbuf; +! curbuf = *b; + if (u_savesub(n) == FAIL) + { + curbuf = buf; +--- 1165,1171 ---- + else if (lua_isstring(L, 3)) /* update line */ + { + buf_T *buf = curbuf; +! curbuf = b; + if (u_savesub(n) == FAIL) + { + curbuf = buf; +*************** +*** 640,646 **** + } + else changed_bytes(n, 0); + curbuf = buf; +! if (*b == curwin->w_buffer) + check_cursor_col(); + } + else +--- 1178,1184 ---- + } + else changed_bytes(n, 0); + curbuf = buf; +! if (b == curwin->w_buffer) + check_cursor_col(); + } + else +*************** +*** 651,658 **** + static int + luaV_buffer_insert(lua_State *L) + { +! luaV_Buffer *b = luaV_checkudata(L, 1, LUAVIM_BUFFER); +! linenr_T last = (*b)->b_ml.ml_line_count; + linenr_T n = (linenr_T) luaL_optinteger(L, 3, last); + buf_T *buf; + luaL_checktype(L, 2, LUA_TSTRING); +--- 1189,1197 ---- + static int + luaV_buffer_insert(lua_State *L) + { +! luaV_Buffer *lb = luaV_checkudata(L, 1, LUAVIM_BUFFER); +! buf_T *b = (buf_T *) luaV_checkcache(L, (void *) *lb); +! linenr_T last = b->b_ml.ml_line_count; + linenr_T n = (linenr_T) luaL_optinteger(L, 3, last); + buf_T *buf; + luaL_checktype(L, 2, LUA_TSTRING); +*************** +*** 664,670 **** + if (n > last) n = last; + /* insert */ + buf = curbuf; +! curbuf = *b; + if (u_save(n, n + 1) == FAIL) + { + curbuf = buf; +--- 1203,1209 ---- + if (n > last) n = last; + /* insert */ + buf = curbuf; +! curbuf = b; + if (u_save(n, n + 1) == FAIL) + { + curbuf = buf; +*************** +*** 686,692 **** + luaV_buffer_next(lua_State *L) + { + luaV_Buffer *b = luaV_checkudata(L, 1, LUAVIM_BUFFER); +! luaV_pushbuffer(L, (*b)->b_next); + return 1; + } + +--- 1225,1232 ---- + luaV_buffer_next(lua_State *L) + { + luaV_Buffer *b = luaV_checkudata(L, 1, LUAVIM_BUFFER); +! buf_T *buf = (buf_T *) luaV_checkcache(L, (void *) *b); +! luaV_pushbuffer(L, buf->b_next); + return 1; + } + +*************** +*** 694,700 **** + luaV_buffer_previous(lua_State *L) + { + luaV_Buffer *b = luaV_checkudata(L, 1, LUAVIM_BUFFER); +! luaV_pushbuffer(L, (*b)->b_prev); + return 1; + } + +--- 1234,1241 ---- + luaV_buffer_previous(lua_State *L) + { + luaV_Buffer *b = luaV_checkudata(L, 1, LUAVIM_BUFFER); +! buf_T *buf = (buf_T *) luaV_checkcache(L, (void *) *b); +! luaV_pushbuffer(L, buf->b_prev); + return 1; + } + +*************** +*** 702,709 **** + luaV_buffer_isvalid(lua_State *L) + { + luaV_Buffer *b = luaV_checkudata(L, 1, LUAVIM_BUFFER); +! lua_pushlightuserdata(L, (void *) (*b)); +! lua_rawget(L, LUA_ENVIRONINDEX); + lua_pushboolean(L, !lua_isnil(L, -1)); + return 1; + } +--- 1243,1249 ---- + luaV_buffer_isvalid(lua_State *L) + { + luaV_Buffer *b = luaV_checkudata(L, 1, LUAVIM_BUFFER); +! luaV_getudata(L, *b); + lua_pushboolean(L, !lua_isnil(L, -1)); + return 1; + } +*************** +*** 724,801 **** + + /* ======= Window type ======= */ + +! static luaV_Window * +! luaV_newwindow(lua_State *L, win_T *win) +! { +! luaV_Window *w = (luaV_Window *) lua_newuserdata(L, sizeof(luaV_Window)); +! *w = win; +! lua_pushlightuserdata(L, (void *) win); +! lua_pushvalue(L, -2); +! lua_rawset(L, LUA_ENVIRONINDEX); /* env[win] = udata */ +! /* to avoid GC, store as key in env */ +! lua_pushvalue(L, -1); +! lua_pushboolean(L, 1); +! lua_rawset(L, LUA_ENVIRONINDEX); /* env[udata] = true */ +! /* set metatable */ +! luaV_getfield(L, LUAVIM_WINDOW); +! lua_setmetatable(L, -2); +! return w; +! } +! +! static luaV_Window * +! luaV_pushwindow(lua_State *L, win_T *win) +! { +! luaV_Window *w = NULL; +! if (win == NULL) +! lua_pushnil(L); +! else { +! lua_pushlightuserdata(L, (void *) win); +! lua_rawget(L, LUA_ENVIRONINDEX); +! if (lua_isnil(L, -1)) /* not interned? */ +! { +! lua_pop(L, 1); +! w = luaV_newwindow(L, win); +! } +! else w = (luaV_Window *) lua_touserdata(L, -1); +! } +! return w; +! } +! +! /* Window metamethods */ +! +! static int +! luaV_window_tostring(lua_State *L) +! { +! lua_pushfstring(L, "%s: %p", LUAVIM_WINDOW, lua_touserdata(L, 1)); +! return 1; +! } + + static int + luaV_window_call(lua_State *L) + { +! luaV_Window *w = (luaV_Window *) lua_touserdata(L, 1); + lua_settop(L, 1); +! win_goto(*w); + return 1; + } + + static int + luaV_window_index(lua_State *L) + { +! luaV_Window *w = (luaV_Window *) lua_touserdata(L, 1); + const char *s = luaL_checkstring(L, 2); + if (strncmp(s, "buffer", 6) == 0) +! luaV_pushbuffer(L, (*w)->w_buffer); + else if (strncmp(s, "line", 4) == 0) +! lua_pushinteger(L, (*w)->w_cursor.lnum); + else if (strncmp(s, "col", 3) == 0) +! lua_pushinteger(L, (*w)->w_cursor.col + 1); + #ifdef FEAT_VERTSPLIT + else if (strncmp(s, "width", 5) == 0) +! lua_pushinteger(L, W_WIDTH((*w))); + #endif + else if (strncmp(s, "height", 6) == 0) +! lua_pushinteger(L, (*w)->w_height); + /* methods */ + else if (strncmp(s, "next", 4) == 0 + || strncmp(s, "previous", 8) == 0 +--- 1264,1299 ---- + + /* ======= Window type ======= */ + +! luaV_newtype(win_T, window, luaV_Window, LUAVIM_WINDOW) +! luaV_pushtype(win_T, window, luaV_Window) +! luaV_type_tostring(window, LUAVIM_WINDOW) + + static int + luaV_window_call(lua_State *L) + { +! win_T *w = (win_T *) luaV_checkvalid(L, luaV_Window, 1); + lua_settop(L, 1); +! win_goto(w); + return 1; + } + + static int + luaV_window_index(lua_State *L) + { +! win_T *w = (win_T *) luaV_checkvalid(L, luaV_Window, 1); + const char *s = luaL_checkstring(L, 2); + if (strncmp(s, "buffer", 6) == 0) +! luaV_pushbuffer(L, w->w_buffer); + else if (strncmp(s, "line", 4) == 0) +! lua_pushinteger(L, w->w_cursor.lnum); + else if (strncmp(s, "col", 3) == 0) +! lua_pushinteger(L, w->w_cursor.col + 1); + #ifdef FEAT_VERTSPLIT + else if (strncmp(s, "width", 5) == 0) +! lua_pushinteger(L, W_WIDTH(w)); + #endif + else if (strncmp(s, "height", 6) == 0) +! lua_pushinteger(L, w->w_height); + /* methods */ + else if (strncmp(s, "next", 4) == 0 + || strncmp(s, "previous", 8) == 0 +*************** +*** 812,818 **** + static int + luaV_window_newindex (lua_State *L) + { +! luaV_Window *w = (luaV_Window *) lua_touserdata(L, 1); + const char *s = luaL_checkstring(L, 2); + int v = luaL_checkinteger(L, 3); + if (strncmp(s, "line", 4) == 0) +--- 1310,1316 ---- + static int + luaV_window_newindex (lua_State *L) + { +! win_T *w = (win_T *) luaV_checkvalid(L, luaV_Window, 1); + const char *s = luaL_checkstring(L, 2); + int v = luaL_checkinteger(L, 3); + if (strncmp(s, "line", 4) == 0) +*************** +*** 820,828 **** + #ifdef HAVE_SANDBOX + luaV_checksandbox(L); + #endif +! if (v < 1 || v > (*w)->w_buffer->b_ml.ml_line_count) + luaL_error(L, "line out of range"); +! (*w)->w_cursor.lnum = v; + update_screen(VALID); + } + else if (strncmp(s, "col", 3) == 0) +--- 1318,1326 ---- + #ifdef HAVE_SANDBOX + luaV_checksandbox(L); + #endif +! if (v < 1 || v > w->w_buffer->b_ml.ml_line_count) + luaL_error(L, "line out of range"); +! w->w_cursor.lnum = v; + update_screen(VALID); + } + else if (strncmp(s, "col", 3) == 0) +*************** +*** 830,836 **** + #ifdef HAVE_SANDBOX + luaV_checksandbox(L); + #endif +! (*w)->w_cursor.col = v - 1; + update_screen(VALID); + } + #ifdef FEAT_VERTSPLIT +--- 1328,1334 ---- + #ifdef HAVE_SANDBOX + luaV_checksandbox(L); + #endif +! w->w_cursor.col = v - 1; + update_screen(VALID); + } + #ifdef FEAT_VERTSPLIT +*************** +*** 840,846 **** + #ifdef FEAT_GUI + need_mouse_correct = TRUE; + #endif +! curwin = *w; + win_setwidth(v); + curwin = win; + } +--- 1338,1344 ---- + #ifdef FEAT_GUI + need_mouse_correct = TRUE; + #endif +! curwin = w; + win_setwidth(v); + curwin = win; + } +*************** +*** 851,857 **** + #ifdef FEAT_GUI + need_mouse_correct = TRUE; + #endif +! curwin = *w; + win_setheight(v); + curwin = win; + } +--- 1349,1355 ---- + #ifdef FEAT_GUI + need_mouse_correct = TRUE; + #endif +! curwin = w; + win_setheight(v); + curwin = win; + } +*************** +*** 864,870 **** + luaV_window_next(lua_State *L) + { + luaV_Window *w = luaV_checkudata(L, 1, LUAVIM_WINDOW); +! luaV_pushwindow(L, (*w)->w_next); + return 1; + } + +--- 1362,1369 ---- + luaV_window_next(lua_State *L) + { + luaV_Window *w = luaV_checkudata(L, 1, LUAVIM_WINDOW); +! win_T *win = (win_T *) luaV_checkcache(L, (void *) *w); +! luaV_pushwindow(L, win->w_next); + return 1; + } + +*************** +*** 872,878 **** + luaV_window_previous(lua_State *L) + { + luaV_Window *w = luaV_checkudata(L, 1, LUAVIM_WINDOW); +! luaV_pushwindow(L, (*w)->w_prev); + return 1; + } + +--- 1371,1378 ---- + luaV_window_previous(lua_State *L) + { + luaV_Window *w = luaV_checkudata(L, 1, LUAVIM_WINDOW); +! win_T *win = (win_T *) luaV_checkcache(L, (void *) *w); +! luaV_pushwindow(L, win->w_prev); + return 1; + } + +*************** +*** 880,887 **** + luaV_window_isvalid(lua_State *L) + { + luaV_Window *w = luaV_checkudata(L, 1, LUAVIM_WINDOW); +! lua_pushlightuserdata(L, (void *) (*w)); +! lua_rawget(L, LUA_ENVIRONINDEX); + lua_pushboolean(L, !lua_isnil(L, -1)); + return 1; + } +--- 1380,1386 ---- + luaV_window_isvalid(lua_State *L) + { + luaV_Window *w = luaV_checkudata(L, 1, LUAVIM_WINDOW); +! luaV_getudata(L, *w); + lua_pushboolean(L, !lua_isnil(L, -1)); + return 1; + } +*************** +*** 983,988 **** +--- 1482,1509 ---- + } + + static int ++ luaV_list(lua_State *L) ++ { ++ list_T *l = list_alloc(); ++ if (l == NULL) ++ lua_pushnil(L); ++ else ++ luaV_newlist(L, l); ++ return 1; ++ } ++ ++ static int ++ luaV_dict(lua_State *L) ++ { ++ dict_T *d = dict_alloc(); ++ if (d == NULL) ++ lua_pushnil(L); ++ else ++ luaV_newdict(L, d); ++ return 1; ++ } ++ ++ static int + luaV_buffer(lua_State *L) + { + buf_T *buf; +*************** +*** 1008,1022 **** + break; + } + } +- if (buf == NULL) /* not found? */ +- lua_pushnil(L); +- else +- luaV_pushbuffer(L, buf); + } +! else { + buf = (lua_toboolean(L, 1)) ? firstbuf : curbuf; /* first buffer? */ +! luaV_pushbuffer(L, buf); +! } + return 1; + } + +--- 1529,1538 ---- + break; + } + } + } +! else + buf = (lua_toboolean(L, 1)) ? firstbuf : curbuf; /* first buffer? */ +! luaV_pushbuffer(L, buf); + return 1; + } + +*************** +*** 1029,1043 **** + int n = lua_tointeger(L, 1); + for (win = firstwin; win != NULL; win = win->w_next, n--) + if (n == 1) break; +- if (win == NULL) /* not found? */ +- lua_pushnil(L); +- else +- luaV_pushwindow(L, win); + } +! else { + win = (lua_toboolean(L, 1)) ? firstwin : curwin; /* first window? */ +! luaV_pushwindow(L, win); +! } + return 1; + } + +--- 1545,1554 ---- + int n = lua_tointeger(L, 1); + for (win = firstwin; win != NULL; win = win->w_next, n--) + if (n == 1) break; + } +! else + win = (lua_toboolean(L, 1)) ? firstwin : curwin; /* first window? */ +! luaV_pushwindow(L, win); + return 1; + } + +*************** +*** 1054,1086 **** + } + + static int +! luaV_isbuffer(lua_State *L) +! { +! lua_pushboolean(L, luaV_toudata(L, 1, LUAVIM_BUFFER) != NULL); +! return 1; +! } +! +! static int +! luaV_iswindow(lua_State *L) + { +! lua_pushboolean(L, luaV_toudata(L, 1, LUAVIM_WINDOW) != NULL); +! return 1; +! } +! +! /* for freeing buffer and window objects; lightuserdata as arg */ +! static int +! luaV_free(lua_State *L) +! { +! lua_pushvalue(L, 1); /* lightudata */ +! lua_rawget(L, LUA_ENVIRONINDEX); +! if (!lua_isnil(L, -1)) + { +! lua_pushnil(L); +! lua_rawset(L, LUA_ENVIRONINDEX); /* env[udata] = nil */ +! lua_pushnil(L); +! lua_rawset(L, LUA_ENVIRONINDEX); /* env[lightudata] = nil */ + } +! return 0; + } + + static const luaL_Reg luaV_module[] = { +--- 1565,1606 ---- + } + + static int +! luaV_type(lua_State *L) + { +! luaL_checkany(L, 1); +! if (lua_type(L, 1) == LUA_TUSERDATA) /* check vim udata? */ + { +! lua_settop(L, 1); +! if (lua_getmetatable(L, 1)) +! { +! luaV_getfield(L, LUAVIM_LIST); +! if (lua_rawequal(L, -1, 2)) +! { +! lua_pushstring(L, "list"); +! return 1; +! } +! luaV_getfield(L, LUAVIM_DICT); +! if (lua_rawequal(L, -1, 2)) +! { +! lua_pushstring(L, "dict"); +! return 1; +! } +! luaV_getfield(L, LUAVIM_BUFFER); +! if (lua_rawequal(L, -1, 2)) +! { +! lua_pushstring(L, "buffer"); +! return 1; +! } +! luaV_getfield(L, LUAVIM_WINDOW); +! if (lua_rawequal(L, -1, 2)) +! { +! lua_pushstring(L, "window"); +! return 1; +! } +! } + } +! lua_pushstring(L, luaL_typename(L, 1)); /* fallback */ +! return 1; + } + + static const luaL_Reg luaV_module[] = { +*************** +*** 1088,1111 **** + {"eval", luaV_eval}, + {"beep", luaV_beep}, + {"line", luaV_line}, + {"buffer", luaV_buffer}, + {"window", luaV_window}, + {"open", luaV_open}, +! {"isbuffer", luaV_isbuffer}, +! {"iswindow", luaV_iswindow}, + {NULL, NULL} + }; + + static int + luaopen_vim(lua_State *L) + { +! /* set environment */ + lua_newtable(L); + lua_newtable(L); +! lua_pushliteral(L, "v"); + lua_setfield(L, -2, "__mode"); +! lua_setmetatable(L, -2); +! lua_replace(L, LUA_ENVIRONINDEX); + /* print */ + lua_pushcfunction(L, luaV_print); + lua_setglobal(L, "print"); +--- 1608,1695 ---- + {"eval", luaV_eval}, + {"beep", luaV_beep}, + {"line", luaV_line}, ++ {"list", luaV_list}, ++ {"dict", luaV_dict}, + {"buffer", luaV_buffer}, + {"window", luaV_window}, + {"open", luaV_open}, +! {"type", luaV_type}, + {NULL, NULL} + }; + ++ /* for freeing list, dict, buffer and window objects; lightuserdata as arg */ ++ static int ++ luaV_free(lua_State *L) ++ { ++ lua_pushnil(L); ++ luaV_setudata(L, lua_touserdata(L, 1)); ++ return 0; ++ } ++ ++ static int ++ luaV_luaeval (lua_State *L) ++ { ++ luaL_Buffer b; ++ size_t l; ++ const char *str = lua_tolstring(L, 1, &l); ++ typval_T *arg = (typval_T *) lua_touserdata(L, 2); ++ typval_T *rettv = (typval_T *) lua_touserdata(L, 3); ++ luaL_buffinit(L, &b); ++ luaL_addlstring(&b, LUAVIM_EVALHEADER, sizeof(LUAVIM_EVALHEADER) - 1); ++ luaL_addlstring(&b, str, l); ++ luaL_pushresult(&b); ++ str = lua_tolstring(L, -1, &l); ++ if (luaL_loadbuffer(L, str, l, LUAVIM_EVALNAME)) /* compile error? */ ++ { ++ luaV_emsg(L); ++ return 0; ++ } ++ luaV_pushtypval(L, arg); ++ if (lua_pcall(L, 1, 1, 0)) /* running error? */ ++ { ++ luaV_emsg(L); ++ return 0; ++ } ++ luaV_totypval(L, -1, rettv); ++ return 0; ++ } ++ ++ static int ++ luaV_setref (lua_State *L) ++ { ++ int copyID = lua_tointeger(L, 1); ++ typval_T tv; ++ luaV_getfield(L, LUAVIM_LIST); ++ luaV_getfield(L, LUAVIM_DICT); ++ lua_pushnil(L); ++ while (lua_next(L, lua_upvalueindex(1)) != 0) /* traverse cache table */ ++ { ++ lua_getmetatable(L, -1); ++ if (lua_rawequal(L, -1, 2)) /* list? */ ++ { ++ tv.v_type = VAR_LIST; ++ tv.vval.v_list = (list_T *) lua_touserdata(L, 4); /* key */ ++ } ++ else if (lua_rawequal(L, -1, 3)) /* dict? */ ++ { ++ tv.v_type = VAR_DICT; ++ tv.vval.v_dict = (dict_T *) lua_touserdata(L, 4); /* key */ ++ } ++ lua_pop(L, 2); /* metatable and value */ ++ set_ref_in_tv(&tv, copyID); ++ } ++ return 0; ++ } ++ + static int + luaopen_vim(lua_State *L) + { +! /* set cache table */ + lua_newtable(L); + lua_newtable(L); +! lua_pushstring(L, "v"); + lua_setfield(L, -2, "__mode"); +! lua_setmetatable(L, -2); /* cache is weak-valued */ + /* print */ + lua_pushcfunction(L, luaV_print); + lua_setglobal(L, "print"); +*************** +*** 1116,1129 **** + lua_pop(L, 1); + /* free */ + lua_pushlightuserdata(L, (void *) LUAVIM_FREE); +! lua_pushcfunction(L, luaV_free); + lua_rawset(L, LUA_REGISTRYINDEX); + /* register */ + luaV_newmetatable(L, LUAVIM_BUFFER); +! luaL_register(L, NULL, luaV_Buffer_mt); + luaV_newmetatable(L, LUAVIM_WINDOW); +! luaL_register(L, NULL, luaV_Window_mt); +! luaL_register(L, LUAVIM_NAME, luaV_module); + return 0; + } + +--- 1700,1735 ---- + lua_pop(L, 1); + /* free */ + lua_pushlightuserdata(L, (void *) LUAVIM_FREE); +! lua_pushvalue(L, 1); /* cache table */ +! lua_pushcclosure(L, luaV_free, 1); +! lua_rawset(L, LUA_REGISTRYINDEX); +! /* luaeval */ +! lua_pushlightuserdata(L, (void *) LUAVIM_LUAEVAL); +! lua_pushvalue(L, 1); /* cache table */ +! lua_pushcclosure(L, luaV_luaeval, 1); +! lua_rawset(L, LUA_REGISTRYINDEX); +! /* setref */ +! lua_pushlightuserdata(L, (void *) LUAVIM_SETREF); +! lua_pushvalue(L, 1); /* cache table */ +! lua_pushcclosure(L, luaV_setref, 1); + lua_rawset(L, LUA_REGISTRYINDEX); + /* register */ ++ luaV_newmetatable(L, LUAVIM_LIST); ++ lua_pushvalue(L, 1); ++ luaV_openlib(L, luaV_List_mt, 1); ++ luaV_newmetatable(L, LUAVIM_DICT); ++ lua_pushvalue(L, 1); ++ luaV_openlib(L, luaV_Dict_mt, 1); + luaV_newmetatable(L, LUAVIM_BUFFER); +! lua_pushvalue(L, 1); /* cache table */ +! luaV_openlib(L, luaV_Buffer_mt, 1); + luaV_newmetatable(L, LUAVIM_WINDOW); +! lua_pushvalue(L, 1); /* cache table */ +! luaV_openlib(L, luaV_Window_mt, 1); +! lua_newtable(L); /* vim table */ +! lua_pushvalue(L, 1); /* cache table */ +! luaV_openlib(L, luaV_module, 1); +! lua_setglobal(L, LUAVIM_NAME); + return 0; + } + +*************** +*** 1154,1160 **** + static lua_State *L = NULL; + + static int +! lua_is_open(void) + { + return L != NULL; + } +--- 1760,1766 ---- + static lua_State *L = NULL; + + static int +! lua_isopen(void) + { + return L != NULL; + } +*************** +*** 1162,1168 **** + static int + lua_init(void) + { +! if (L == NULL) + { + #ifdef DYNAMIC_LUA + if (!lua_enabled(TRUE)) +--- 1768,1774 ---- + static int + lua_init(void) + { +! if (!lua_isopen()) + { + #ifdef DYNAMIC_LUA + if (!lua_enabled(TRUE)) +*************** +*** 1179,1185 **** + void + lua_end(void) + { +! if (L != NULL) + { + lua_close(L); + L = NULL; +--- 1785,1791 ---- + void + lua_end(void) + { +! if (lua_isopen()) + { + lua_close(L); + L = NULL; +*************** +*** 1273,1295 **** + } + } + +! /* buffer */ + void +! lua_buffer_free(buf_T *buf) + { +! if (!lua_is_open()) return; +! luaV_getfield(L, LUAVIM_FREE); +! lua_pushlightuserdata(L, (void *) buf); +! lua_call(L, 1, 0); + } + +- /* window */ + void +! lua_window_free(win_T *win) + { +! if (!lua_is_open()) return; +! luaV_getfield(L, LUAVIM_FREE); +! lua_pushlightuserdata(L, (void *) win); + lua_call(L, 1, 0); + } + +--- 1879,1914 ---- + } + } + +! #define luaV_freetype(typ,tname) \ +! void \ +! lua_##tname##_free(typ *o) \ +! { \ +! if (!lua_isopen()) return; \ +! luaV_getfield(L, LUAVIM_FREE); \ +! lua_pushlightuserdata(L, (void *) o); \ +! lua_call(L, 1, 0); \ +! } +! +! luaV_freetype(buf_T, buffer) +! luaV_freetype(win_T, window) +! + void +! do_luaeval (char_u *str, typval_T *arg, typval_T *rettv) + { +! lua_init(); +! luaV_getfield(L, LUAVIM_LUAEVAL); +! lua_pushstring(L, (char *) str); +! lua_pushlightuserdata(L, (void *) arg); +! lua_pushlightuserdata(L, (void *) rettv); +! lua_call(L, 3, 0); + } + + void +! set_ref_in_lua (int copyID) + { +! if (!lua_isopen()) return; +! luaV_getfield(L, LUAVIM_SETREF); +! lua_pushinteger(L, copyID); + lua_call(L, 1, 0); + } + +*** ../vim-7.3.489/src/proto/if_lua.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/if_lua.pro 2012-04-05 16:41:35.000000000 +0200 +*************** +*** 6,9 **** +--- 6,11 ---- + void ex_luafile __ARGS((exarg_T *eap)); + void lua_buffer_free __ARGS((buf_T *buf)); + void lua_window_free __ARGS((win_T *win)); ++ void do_luaeval __ARGS((char_u *str, typval_T *arg, typval_T *rettv)); ++ void set_ref_in_lua __ARGS((int copyID)); + /* vim: set ft=c : */ +*** ../vim-7.3.489/src/version.c 2012-04-05 16:07:01.000000000 +0200 +--- src/version.c 2012-04-05 16:52:08.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 490, + /**/ + +-- +Even got a Datapoint 3600(?) with a DD50 connector instead of the +usual DB25... what a nightmare trying to figure out the pinout +for *that* with no spex... + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5a39af3ee9db4bbdf7d408551cb7e4d10c166381 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:16 +0200 Subject: [PATCH 0223/3340] - patchlevel 491 --- 7.3.491 | 235 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 235 insertions(+) create mode 100644 7.3.491 diff --git a/7.3.491 b/7.3.491 new file mode 100644 index 00000000..b675722e --- /dev/null +++ b/7.3.491 @@ -0,0 +1,235 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.491 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.491 +Problem: No tests for Lua. +Solution: Add some simple tests for Lua. (Luis Carvalho) +Files: src/testdir/test1.in, src/testdir/test85.in, src/testdir/test85.ok + src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak, + src/testdir/Make_ming.mak, src/testdir/Make_os2.mak, + src/testdir/Make_vms.mms, src/testdir/Makefile + + +*** ../vim-7.3.490/src/testdir/test1.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test1.in 2012-04-05 16:37:37.000000000 +0200 +*************** +*** 15,20 **** +--- 15,21 ---- + be set like small.vim above. mbyte.vim is sourced by tests that require the + +multi_byte feature. + Similar logic is applied to the +mzscheme feature, using mzscheme.vim. ++ Similar logic is applied to the +lua feature, using lua.vim. + + STARTTEST + :" Write a single line to test.out to check if testing works at all. +*************** +*** 28,37 **** +--- 29,45 ---- + qa! + :w! mbyte.vim + :w! mzscheme.vim ++ :w! lua.vim ++ :" + :" If +multi_byte feature supported, make mbyte.vim empty. + :if has("multi_byte") | sp another | w! mbyte.vim | q | endif ++ :" + :" If +mzscheme feature supported, make mzscheme.vim empty. + :if has("mzscheme") | sp another | w! mzscheme.vim | q | endif ++ :" ++ :" If +lua feature supported, make lua.vim empty. ++ :if has("lua") | sp another | w! lua.vim | q | endif ++ :" + :" If +eval feature supported quit here, leaving tiny.vim and small.vim empty. + :" Otherwise write small.vim to skip the test. + :if 1 | q! | endif +*** ../vim-7.3.490/src/testdir/test85.in 2012-04-05 16:56:12.000000000 +0200 +--- src/testdir/test85.in 2012-04-05 16:44:00.000000000 +0200 +*************** +*** 0 **** +--- 1,42 ---- ++ Test for Lua interface and luaeval() function ++ ++ STARTTEST ++ :so small.vim ++ :so lua.vim ++ :set nocompatible viminfo+=nviminfo ++ :lua l = vim.list():add"item0":add"dictionary with list OK":add"item2" ++ :lua h = vim.dict(); h.list = l ++ :call garbagecollect() ++ /^1 ++ :" change buffer contents ++ :lua curbuf = vim.buffer() ++ :lua curline = vim.eval"line('.')" ++ :lua curbuf[curline] = "1 changed line 1" ++ :" scalar test ++ :let tmp_string = luaeval('"string"') ++ :let tmp_1000 = luaeval('1000') ++ :if printf("%s%.0f", tmp_string, tmp_1000) == "string1000" ++ :let scalar_res = "OK" ++ :else ++ :let scalar_res = "FAILED" ++ :endif ++ :call append(search("^1"), "scalar test " . scalar_res) ++ :" dictionary containing a list ++ :let tmp = luaeval("h").list[1] ++ :/^2/put =tmp ++ :" circular list (at the same time test lists containing lists) ++ :lua l[2] = l ++ :let l2 = luaeval("h").list ++ :if l2[2] == l2 ++ :let res = "OK" ++ :else ++ :let res = "FAILED" ++ :endif ++ :call setline(search("^3"), "circular test " . res) ++ :?^1?,$w! test.out ++ :qa! ++ ENDTEST ++ ++ 1 line 1 ++ 2 line 2 ++ 3 line 3 +*** ../vim-7.3.490/src/testdir/test85.ok 2012-04-05 16:56:12.000000000 +0200 +--- src/testdir/test85.ok 2012-04-05 16:18:56.000000000 +0200 +*************** +*** 0 **** +--- 1,5 ---- ++ 1 changed line 1 ++ scalar test OK ++ 2 line 2 ++ dictionary with list OK ++ circular test OK +*** ../vim-7.3.490/src/testdir/Make_amiga.mak 2012-03-28 19:58:34.000000000 +0200 +--- src/testdir/Make_amiga.mak 2012-04-05 16:21:55.000000000 +0200 +*************** +*** 13,18 **** +--- 13,19 ---- + # test25 uses symbolic link + # test27 can't edit file with "*" + # test52 only for Win32 ++ # test85 no Lua interface + + SCRIPTS = test1.out test3.out test4.out test5.out test6.out \ + test7.out test8.out test9.out \ +*** ../vim-7.3.490/src/testdir/Make_dos.mak 2012-03-28 19:58:34.000000000 +0200 +--- src/testdir/Make_dos.mak 2012-04-05 16:22:16.000000000 +0200 +*************** +*** 30,36 **** + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out + + SCRIPTS32 = test50.out test70.out + +--- 30,36 ---- + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.490/src/testdir/Make_ming.mak 2012-03-28 19:58:34.000000000 +0200 +--- src/testdir/Make_ming.mak 2012-04-05 16:22:25.000000000 +0200 +*************** +*** 50,56 **** + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out + + SCRIPTS32 = test50.out test70.out + +--- 50,56 ---- + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.490/src/testdir/Make_os2.mak 2012-03-28 19:58:34.000000000 +0200 +--- src/testdir/Make_os2.mak 2012-04-05 16:22:38.000000000 +0200 +*************** +*** 13,18 **** +--- 13,19 ---- + # test25 uses symbolic link + # test27 can't edit file with "*" in file name + # test52 only for Win32 ++ # test85 no Lua interface + + SCRIPTS = test1.out test3.out test4.out test5.out test6.out \ + test7.out test8.out test9.out \ +*** ../vim-7.3.490/src/testdir/Make_vms.mms 2012-03-28 19:58:34.000000000 +0200 +--- src/testdir/Make_vms.mms 2012-04-05 16:23:08.000000000 +0200 +*************** +*** 4,10 **** + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2012 Mar 28 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +--- 4,10 ---- + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2012 Apr 05 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +*************** +*** 89,94 **** +--- 89,95 ---- + # with too many dots). + # + # Test 72: unknown reason ++ # Test 85: no Lua interface + + .IFDEF WANT_GUI + SCRIPT_GUI = test16.out +*** ../vim-7.3.490/src/testdir/Makefile 2012-03-28 19:58:34.000000000 +0200 +--- src/testdir/Makefile 2012-04-05 16:21:13.000000000 +0200 +*************** +*** 27,33 **** + test69.out test70.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out + + SCRIPTS_GUI = test16.out + +--- 27,33 ---- + test69.out test70.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out + + SCRIPTS_GUI = test16.out + +*** ../vim-7.3.490/src/version.c 2012-04-05 16:53:56.000000000 +0200 +--- src/version.c 2012-04-05 16:55:27.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 491, + /**/ + +-- +You had connectors? Eeee, when I were a lad we 'ad to carry the +bits between the computer and the terminal with a spoon... + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ea8b6566e269a10041be1bc45610920668cba8f5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:16 +0200 Subject: [PATCH 0224/3340] - patchlevel 492 --- 7.3.492 | 718 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 718 insertions(+) create mode 100644 7.3.492 diff --git a/7.3.492 b/7.3.492 new file mode 100644 index 00000000..b32b6f68 --- /dev/null +++ b/7.3.492 @@ -0,0 +1,718 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.492 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.492 +Problem: Can't indent conditions separately from function arguments. +Solution: Add the 'k' flag in 'cino. (Lech Lorens) +Files: runtime/doc/indent.txt, src/misc1.c, src/testdir/test3.in, + src/testdir/test3.ok + + +*** ../vim-7.3.491/runtime/doc/indent.txt 2011-06-26 03:16:58.000000000 +0200 +--- runtime/doc/indent.txt 2012-04-05 17:12:14.000000000 +0200 +*************** +*** 459,464 **** +--- 460,481 ---- + a_short_line(argument, a_short_line(argument, + argument); argument); + < ++ *cino-k* ++ kN When in unclosed parentheses which follow "if", "for" or ++ "while" and N is non-zero, overrides the behaviour defined by ++ "(N": causes the indent to be N characters relative to the outer ++ context (i.e. the line where "if", "for" or "while" is). Has ++ no effect on deeper levels of nesting. Affects flags like "wN" ++ only for the "if", "for" and "while" conditions. If 0, defaults ++ to behaviour defined by the "(N" flag. (default: 0). ++ ++ cino=(0 cino=(0,ks > ++ if (condition1 if (condition1 ++ && condition2) && condition2) ++ action(); action(); ++ function(argument1 function(argument1 ++ && argument2); && argument2); ++ < + *cino-m* + mN When N is non-zero, line up a line starting with a closing + parentheses with the first character of the line with the +*************** +*** 527,540 **** + + *cino-#* + #N When N is non-zero recognize shell/Perl comments, starting with +! '#'. Default N is zero: don't recognizes '#' comments. Note + that lines starting with # will still be seen as preprocessor + lines. + + + The defaults, spelled out in full, are: + cinoptions=>s,e0,n0,f0,{0,}0,^0,L-1,:s,=s,l0,b0,gs,hs,N0,ps,ts,is,+s, +! c3,C0,/0,(2s,us,U0,w0,W0,m0,j0,J0,)20,*70,#0 + + Vim puts a line in column 1 if: + - It starts with '#' (preprocessor directives), if 'cinkeys' contains '#'. +--- 546,559 ---- + + *cino-#* + #N When N is non-zero recognize shell/Perl comments, starting with +! '#'. Default N is zero: don't recognize '#' comments. Note + that lines starting with # will still be seen as preprocessor + lines. + + + The defaults, spelled out in full, are: + cinoptions=>s,e0,n0,f0,{0,}0,^0,L-1,:s,=s,l0,b0,gs,hs,N0,ps,ts,is,+s, +! c3,C0,/0,(2s,us,U0,w0,W0,k0,m0,j0,J0,)20,*70,#0 + + Vim puts a line in column 1 if: + - It starts with '#' (preprocessor directives), if 'cinkeys' contains '#'. +*** ../vim-7.3.491/src/misc1.c 2012-02-29 13:49:03.000000000 +0100 +--- src/misc1.c 2012-04-05 17:12:14.000000000 +0200 +*************** +*** 5771,5776 **** +--- 5771,5822 ---- + } + + /* ++ * Check whether in "p" there is an "if", "for" or "while" before offset. ++ * Return 0 if there is none. ++ * Otherwise return !0 and update "*poffset" to point to the place where the ++ * string was found. ++ */ ++ static int ++ cin_is_if_for_while_before_offset(line, offset, poffset) ++ char_u *line; ++ size_t offset; ++ int *poffset; ++ { ++ ++ if (offset-- < 2) ++ return 0; ++ while (offset > 2 && vim_iswhite(line[offset])) ++ --offset; ++ ++ offset -= 1; ++ if (!STRNCMP(line + offset, "if", 2)) ++ goto probablyFound; ++ ++ if (offset >= 1) ++ { ++ offset -= 1; ++ if (!STRNCMP(line + offset, "for", 3)) ++ goto probablyFound; ++ ++ if (offset >= 2) ++ { ++ offset -= 2; ++ if (!STRNCMP(line + offset, "while", 5)) ++ goto probablyFound; ++ } ++ } ++ ++ return 0; ++ probablyFound: ++ if (!offset || !vim_isIDc(line[offset - 1])) ++ { ++ *poffset = offset; ++ return 1; ++ } ++ return 0; ++ } ++ ++ /* + * Return TRUE if we are at the end of a do-while. + * do + * nothing; +*************** +*** 6124,6130 **** + + /* + * Find the matching '(', failing if it is in a comment. +! * Return NULL of no match found. + */ + static pos_T * + find_match_paren(ind_maxparen, ind_maxcomment) /* XXX */ +--- 6170,6176 ---- + + /* + * Find the matching '(', failing if it is in a comment. +! * Return NULL if no match found. + */ + static pos_T * + find_match_paren(ind_maxparen, ind_maxcomment) /* XXX */ +*************** +*** 6393,6398 **** +--- 6439,6450 ---- + */ + int ind_cpp_namespace = 0; + ++ /* ++ * handle continuation lines containing conditions of if(), for() and ++ * while() ++ */ ++ int ind_if_for_while = 0; ++ + pos_T cur_curpos; + int amount; + int scope_amount; +*************** +*** 6437,6442 **** +--- 6489,6495 ---- + int cont_amount = 0; /* amount for continuation line */ + int original_line_islabel; + int added_to_amount = 0; ++ int is_if_for_while = 0; + + for (options = curbuf->b_p_cino; *options; ) + { +*************** +*** 6509,6514 **** +--- 6562,6568 ---- + case 'l': ind_keep_case_label = n; break; + case '#': ind_hash_comment = n; break; + case 'N': ind_cpp_namespace = n; break; ++ case 'k': ind_if_for_while = n; break; + } + if (*options == ',') + ++options; +*************** +*** 6812,6817 **** +--- 6866,6900 ---- + if (amount == -1) + { + int ignore_paren_col = 0; ++ int is_if_for_while = 0; ++ ++ if (ind_if_for_while) ++ { ++ /* Look for the outermost opening parenthesis on this line ++ * and check whether it belongs to an "if", "for" or "while". */ ++ ++ pos_T cursor_save = curwin->w_cursor; ++ pos_T outermost; ++ char_u *line; ++ int look_col; ++ ++ trypos = &our_paren_pos; ++ do { ++ outermost = *trypos; ++ curwin->w_cursor.lnum = outermost.lnum; ++ curwin->w_cursor.col = outermost.col; ++ ++ trypos = find_match_paren(ind_maxparen, ind_maxcomment); ++ } while (trypos && trypos->lnum == outermost.lnum); ++ ++ curwin->w_cursor = cursor_save; ++ ++ line = ml_get(outermost.lnum); ++ ++ is_if_for_while = ++ cin_is_if_for_while_before_offset(line, outermost.col, ++ &outermost.col); ++ } + + amount = skip_label(our_paren_pos.lnum, &look, ind_maxcomment); + look = skipwhite(look); +*************** +*** 6836,6842 **** + curwin->w_cursor.lnum = save_lnum; + look = ml_get(our_paren_pos.lnum) + look_col; + } +! if (theline[0] == ')' || ind_unclosed == 0 + || (!ind_unclosed_noignore && *look == '(' + && ignore_paren_col == 0)) + { +--- 6919,6925 ---- + curwin->w_cursor.lnum = save_lnum; + look = ml_get(our_paren_pos.lnum) + look_col; + } +! if (theline[0] == ')' || (ind_unclosed == 0 && is_if_for_while == 0) + || (!ind_unclosed_noignore && *look == '(' + && ignore_paren_col == 0)) + { +*************** +*** 6907,6913 **** + { + /* Line up with the start of the matching paren line. */ + } +! else if (ind_unclosed == 0 || (!ind_unclosed_noignore + && *look == '(' && ignore_paren_col == 0)) + { + if (cur_amount != MAXCOL) +--- 6990,6997 ---- + { + /* Line up with the start of the matching paren line. */ + } +! else if ((ind_unclosed == 0 && is_if_for_while == 0) +! || (!ind_unclosed_noignore + && *look == '(' && ignore_paren_col == 0)) + { + if (cur_amount != MAXCOL) +*************** +*** 6943,6949 **** + if (find_match_paren(ind_maxparen, ind_maxcomment) != NULL) + amount += ind_unclosed2; + else +! amount += ind_unclosed; + } + /* + * For a line starting with ')' use the minimum of the two +--- 7027,7038 ---- + if (find_match_paren(ind_maxparen, ind_maxcomment) != NULL) + amount += ind_unclosed2; + else +! { +! if (is_if_for_while) +! amount += ind_if_for_while; +! else +! amount += ind_unclosed; +! } + } + /* + * For a line starting with ')' use the minimum of the two +*** ../vim-7.3.491/src/testdir/test3.in 2011-12-14 20:21:29.000000000 +0100 +--- src/testdir/test3.in 2012-04-05 17:12:14.000000000 +0200 +*************** +*** 1574,1579 **** +--- 1574,1793 ---- + } + + STARTTEST ++ :set cino=k2s,(0 ++ 2kdd3j=][ ++ ENDTEST ++ ++ void func(void) ++ { ++ if (condition1 ++ && condition2) ++ action(); ++ function(argument1 ++ && argument2); ++ ++ if (c1 && (c2 || ++ c3)) ++ foo; ++ if (c1 && ++ (c2 || c3)) ++ { ++ } ++ ++ if ( c1 ++ && ( c2 ++ || c3)) ++ foo; ++ func( c1 ++ && ( c2 ++ || c3)) ++ foo; ++ } ++ ++ STARTTEST ++ :set cino=k2s,(s ++ 2kdd3j=][ ++ ENDTEST ++ ++ void func(void) ++ { ++ if (condition1 ++ && condition2) ++ action(); ++ function(argument1 ++ && argument2); ++ ++ if (c1 && (c2 || ++ c3)) ++ foo; ++ if (c1 && ++ (c2 || c3)) ++ { ++ } ++ ++ if ( c1 ++ && ( c2 ++ || c3)) ++ foo; ++ func( c1 ++ && ( c2 ++ || c3)) ++ foo; ++ } ++ ++ STARTTEST ++ :set cino=k2s,(s,U1 ++ 2kdd3j=][ ++ ENDTEST ++ ++ void func(void) ++ { ++ if (condition1 ++ && condition2) ++ action(); ++ function(argument1 ++ && argument2); ++ ++ if (c1 && (c2 || ++ c3)) ++ foo; ++ if (c1 && ++ (c2 || c3)) ++ { ++ } ++ if (c123456789 ++ && (c22345 ++ || c3)) ++ printf("foo\n"); ++ ++ c = c1 && ++ ( ++ c2 || ++ c3 ++ ) && c4; ++ } ++ ++ STARTTEST ++ :set cino=k2s,(0,W4 ++ 2kdd3j=][ ++ ENDTEST ++ ++ void func(void) ++ { ++ if (condition1 ++ && condition2) ++ action(); ++ function(argument1 ++ && argument2); ++ ++ if (c1 && (c2 || ++ c3)) ++ foo; ++ if (c1 && ++ (c2 || c3)) ++ { ++ } ++ if (c123456789 ++ && (c22345 ++ || c3)) ++ printf("foo\n"); ++ ++ if ( c1 ++ && ( c2 ++ || c3)) ++ foo; ++ ++ a_long_line( ++ argument, ++ argument); ++ a_short_line(argument, ++ argument); ++ } ++ ++ STARTTEST ++ :set cino=k2s,u2 ++ 2kdd3j=][ ++ ENDTEST ++ ++ void func(void) ++ { ++ if (condition1 ++ && condition2) ++ action(); ++ function(argument1 ++ && argument2); ++ ++ if (c1 && (c2 || ++ c3)) ++ foo; ++ if (c1 && ++ (c2 || c3)) ++ { ++ } ++ if (c123456789 ++ && (c22345 ++ || c3)) ++ printf("foo\n"); ++ } ++ ++ STARTTEST ++ :set cino=k2s,(0,w1 ++ 2kdd3j=][ ++ ENDTEST ++ ++ void func(void) ++ { ++ if (condition1 ++ && condition2) ++ action(); ++ function(argument1 ++ && argument2); ++ ++ if (c1 && (c2 || ++ c3)) ++ foo; ++ if (c1 && ++ (c2 || c3)) ++ { ++ } ++ if (c123456789 ++ && (c22345 ++ || c3)) ++ printf("foo\n"); ++ ++ if ( c1 ++ && ( c2 ++ || c3)) ++ foo; ++ func( c1 ++ && ( c2 ++ || c3)) ++ foo; ++ } ++ ++ STARTTEST ++ :set cino=k2,(s ++ 2kdd3j=][ ++ ENDTEST ++ ++ void func(void) ++ { ++ if (condition1 ++ && condition2) ++ action(); ++ function(argument1 ++ && argument2); ++ ++ if (c1 && (c2 || ++ c3)) ++ foo; ++ if (c1 && ++ (c2 || c3)) ++ { ++ } ++ } ++ ++ STARTTEST + :set cino=N-s + /^NAMESPACESTART + =/^NAMESPACEEND +*** ../vim-7.3.491/src/testdir/test3.ok 2011-12-14 20:21:29.000000000 +0100 +--- src/testdir/test3.ok 2012-04-05 17:12:14.000000000 +0200 +*************** +*** 1411,1416 **** +--- 1411,1602 ---- + } + + ++ void func(void) ++ { ++ if (condition1 ++ && condition2) ++ action(); ++ function(argument1 ++ && argument2); ++ ++ if (c1 && (c2 || ++ c3)) ++ foo; ++ if (c1 && ++ (c2 || c3)) ++ { ++ } ++ ++ if ( c1 ++ && ( c2 ++ || c3)) ++ foo; ++ func( c1 ++ && ( c2 ++ || c3)) ++ foo; ++ } ++ ++ ++ void func(void) ++ { ++ if (condition1 ++ && condition2) ++ action(); ++ function(argument1 ++ && argument2); ++ ++ if (c1 && (c2 || ++ c3)) ++ foo; ++ if (c1 && ++ (c2 || c3)) ++ { ++ } ++ ++ if ( c1 ++ && ( c2 ++ || c3)) ++ foo; ++ func( c1 ++ && ( c2 ++ || c3)) ++ foo; ++ } ++ ++ ++ void func(void) ++ { ++ if (condition1 ++ && condition2) ++ action(); ++ function(argument1 ++ && argument2); ++ ++ if (c1 && (c2 || ++ c3)) ++ foo; ++ if (c1 && ++ (c2 || c3)) ++ { ++ } ++ if (c123456789 ++ && (c22345 ++ || c3)) ++ printf("foo\n"); ++ ++ c = c1 && ++ ( ++ c2 || ++ c3 ++ ) && c4; ++ } ++ ++ ++ void func(void) ++ { ++ if (condition1 ++ && condition2) ++ action(); ++ function(argument1 ++ && argument2); ++ ++ if (c1 && (c2 || ++ c3)) ++ foo; ++ if (c1 && ++ (c2 || c3)) ++ { ++ } ++ if (c123456789 ++ && (c22345 ++ || c3)) ++ printf("foo\n"); ++ ++ if ( c1 ++ && ( c2 ++ || c3)) ++ foo; ++ ++ a_long_line( ++ argument, ++ argument); ++ a_short_line(argument, ++ argument); ++ } ++ ++ ++ void func(void) ++ { ++ if (condition1 ++ && condition2) ++ action(); ++ function(argument1 ++ && argument2); ++ ++ if (c1 && (c2 || ++ c3)) ++ foo; ++ if (c1 && ++ (c2 || c3)) ++ { ++ } ++ if (c123456789 ++ && (c22345 ++ || c3)) ++ printf("foo\n"); ++ } ++ ++ ++ void func(void) ++ { ++ if (condition1 ++ && condition2) ++ action(); ++ function(argument1 ++ && argument2); ++ ++ if (c1 && (c2 || ++ c3)) ++ foo; ++ if (c1 && ++ (c2 || c3)) ++ { ++ } ++ if (c123456789 ++ && (c22345 ++ || c3)) ++ printf("foo\n"); ++ ++ if ( c1 ++ && ( c2 ++ || c3)) ++ foo; ++ func( c1 ++ && ( c2 ++ || c3)) ++ foo; ++ } ++ ++ ++ void func(void) ++ { ++ if (condition1 ++ && condition2) ++ action(); ++ function(argument1 ++ && argument2); ++ ++ if (c1 && (c2 || ++ c3)) ++ foo; ++ if (c1 && ++ (c2 || c3)) ++ { ++ } ++ } ++ ++ + NAMESPACESTART + /* valid namespaces with normal indent */ + namespace +*** ../vim-7.3.491/src/version.c 2012-04-05 16:56:38.000000000 +0200 +--- src/version.c 2012-04-05 17:14:18.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 492, + /**/ + +-- +You were lucky to have a LAKE! There were a hundred and sixty of +us living in a small shoebox in the middle of the road. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 197828b30236a3d635792e2b889a858d4c555f28 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:17 +0200 Subject: [PATCH 0225/3340] - patchlevel 493 --- 7.3.493 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 7.3.493 diff --git a/7.3.493 b/7.3.493 new file mode 100644 index 00000000..ff662b25 --- /dev/null +++ b/7.3.493 @@ -0,0 +1,54 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.493 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.493 (after 7.3.492) +Problem: Two unused variables. +Solution: Remove them. (Hong Xu) +Files: src/misc1.c + + +*** ../vim-7.3.492/src/misc1.c 2012-04-05 17:17:38.000000000 +0200 +--- src/misc1.c 2012-04-06 13:49:39.000000000 +0200 +*************** +*** 6489,6495 **** + int cont_amount = 0; /* amount for continuation line */ + int original_line_islabel; + int added_to_amount = 0; +- int is_if_for_while = 0; + + for (options = curbuf->b_p_cino; *options; ) + { +--- 6489,6494 ---- +*************** +*** 6876,6882 **** + pos_T cursor_save = curwin->w_cursor; + pos_T outermost; + char_u *line; +- int look_col; + + trypos = &our_paren_pos; + do { +--- 6875,6880 ---- +*** ../vim-7.3.492/src/version.c 2012-04-05 17:17:38.000000000 +0200 +--- src/version.c 2012-04-06 13:50:21.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 493, + /**/ + +-- +Not too long ago, compress was something you did to garbage... + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5826ff89aea6b0599e808350ff7ee9b804824d24 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:17 +0200 Subject: [PATCH 0226/3340] - patchlevel 494 --- 7.3.494 | 186 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 186 insertions(+) create mode 100644 7.3.494 diff --git a/7.3.494 b/7.3.494 new file mode 100644 index 00000000..81bd24b7 --- /dev/null +++ b/7.3.494 @@ -0,0 +1,186 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.494 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.494 (after 7.3.491) +Problem: Can't compile with Lua 9.1 or dynamic Lua. +Solution: Fix dll_ methods. Fix luado(). (Muraoka Taro, Luis Carvalho) +Files: src/if_lua.c + + +*** ../vim-7.3.493/src/if_lua.c 2012-04-05 16:53:56.000000000 +0200 +--- src/if_lua.c 2012-04-06 14:24:06.000000000 +0200 +*************** +*** 95,100 **** +--- 95,101 ---- + #define luaL_loadbufferx dll_luaL_loadbufferx + #define luaL_argerror dll_luaL_argerror + #endif ++ #define luaL_checkany dll_luaL_checkany + #define luaL_checklstring dll_luaL_checklstring + #define luaL_checkinteger dll_luaL_checkinteger + #define luaL_optinteger dll_luaL_optinteger +*************** +*** 117,124 **** + #define lua_pcallk dll_lua_pcallk + #define lua_getglobal dll_lua_getglobal + #define lua_setglobal dll_lua_setglobal +- #define lua_typename dll_lua_typename + #endif + #define lua_close dll_lua_close + #define lua_gettop dll_lua_gettop + #define lua_settop dll_lua_settop +--- 118,125 ---- + #define lua_pcallk dll_lua_pcallk + #define lua_getglobal dll_lua_getglobal + #define lua_setglobal dll_lua_setglobal + #endif ++ #define lua_typename dll_lua_typename + #define lua_close dll_lua_close + #define lua_gettop dll_lua_gettop + #define lua_settop dll_lua_settop +*************** +*** 151,156 **** +--- 152,158 ---- + #define lua_rawset dll_lua_rawset + #define lua_rawseti dll_lua_rawseti + #define lua_setmetatable dll_lua_setmetatable ++ #define lua_next dll_lua_next + /* libs */ + #define luaopen_base dll_luaopen_base + #define luaopen_table dll_luaopen_table +*************** +*** 177,182 **** +--- 179,185 ---- + int (*dll_luaL_loadbufferx) (lua_State *L, const char *buff, size_t sz, const char *name, const char *mode); + int (*dll_luaL_argerror) (lua_State *L, int numarg, const char *extramsg); + #endif ++ void (*dll_luaL_checkany) (lua_State *L, int narg); + const char *(*dll_luaL_checklstring) (lua_State *L, int numArg, size_t *l); + lua_Integer (*dll_luaL_checkinteger) (lua_State *L, int numArg); + lua_Integer (*dll_luaL_optinteger) (lua_State *L, int nArg, lua_Integer def); +*************** +*** 201,208 **** + int ctx, lua_CFunction k); + void (*dll_lua_getglobal) (lua_State *L, const char *var); + void (*dll_lua_setglobal) (lua_State *L, const char *var); +- const char *(*dll_lua_typename) (lua_State *L, int tp); + #endif + void (*dll_lua_close) (lua_State *L); + int (*dll_lua_gettop) (lua_State *L); + void (*dll_lua_settop) (lua_State *L, int idx); +--- 204,211 ---- + int ctx, lua_CFunction k); + void (*dll_lua_getglobal) (lua_State *L, const char *var); + void (*dll_lua_setglobal) (lua_State *L, const char *var); + #endif ++ const char *(*dll_lua_typename) (lua_State *L, int tp); + void (*dll_lua_close) (lua_State *L); + int (*dll_lua_gettop) (lua_State *L); + void (*dll_lua_settop) (lua_State *L, int idx); +*************** +*** 235,240 **** +--- 238,244 ---- + void (*dll_lua_rawset) (lua_State *L, int idx); + void (*dll_lua_rawseti) (lua_State *L, int idx, int n); + int (*dll_lua_setmetatable) (lua_State *L, int objindex); ++ int (*dll_lua_next) (lua_State *L, int idx); + /* libs */ + int (*dll_luaopen_base) (lua_State *L); + int (*dll_luaopen_table) (lua_State *L); +*************** +*** 268,273 **** +--- 272,278 ---- + {"luaL_loadbufferx", (luaV_function) &dll_luaL_loadbufferx}, + {"luaL_argerror", (luaV_function) &dll_luaL_argerror}, + #endif ++ {"luaL_checkany", (luaV_function) &dll_luaL_checkany}, + {"luaL_checklstring", (luaV_function) &dll_luaL_checklstring}, + {"luaL_checkinteger", (luaV_function) &dll_luaL_checkinteger}, + {"luaL_optinteger", (luaV_function) &dll_luaL_optinteger}, +*************** +*** 290,297 **** + {"lua_pcallk", (luaV_function) &dll_lua_pcallk}, + {"lua_getglobal", (luaV_function) &dll_lua_getglobal}, + {"lua_setglobal", (luaV_function) &dll_lua_setglobal}, +- {"lua_typename", (luaV_function) &dll_lua_typename}, + #endif + {"lua_close", (luaV_function) &dll_lua_close}, + {"lua_gettop", (luaV_function) &dll_lua_gettop}, + {"lua_settop", (luaV_function) &dll_lua_settop}, +--- 295,302 ---- + {"lua_pcallk", (luaV_function) &dll_lua_pcallk}, + {"lua_getglobal", (luaV_function) &dll_lua_getglobal}, + {"lua_setglobal", (luaV_function) &dll_lua_setglobal}, + #endif ++ {"lua_typename", (luaV_function) &dll_lua_typename}, + {"lua_close", (luaV_function) &dll_lua_close}, + {"lua_gettop", (luaV_function) &dll_lua_gettop}, + {"lua_settop", (luaV_function) &dll_lua_settop}, +*************** +*** 324,329 **** +--- 329,335 ---- + {"lua_rawset", (luaV_function) &dll_lua_rawset}, + {"lua_rawseti", (luaV_function) &dll_lua_rawseti}, + {"lua_setmetatable", (luaV_function) &dll_lua_setmetatable}, ++ {"lua_next", (luaV_function) &dll_lua_next}, + /* libs */ + {"luaopen_base", (luaV_function) &dll_luaopen_base}, + {"luaopen_table", (luaV_function) &dll_luaopen_table}, +*************** +*** 1828,1834 **** + } + luaV_setrange(L, eap->line1, eap->line2); + luaL_buffinit(L, &b); +! luaL_addlstring(&b, "return function(line) ", 22); /* header */ + luaL_addlstring(&b, s, strlen(s)); + luaL_addlstring(&b, " end", 4); /* footer */ + luaL_pushresult(&b); +--- 1834,1840 ---- + } + luaV_setrange(L, eap->line1, eap->line2); + luaL_buffinit(L, &b); +! luaL_addlstring(&b, "return function(line, linenr) ", 30); /* header */ + luaL_addlstring(&b, s, strlen(s)); + luaL_addlstring(&b, " end", 4); /* footer */ + luaL_pushresult(&b); +*************** +*** 1845,1851 **** + { + lua_pushvalue(L, -1); /* function */ + luaV_pushline(L, curbuf, l); /* current line as arg */ +! if (lua_pcall(L, 1, 1, 0)) + { + luaV_emsg(L); + break; +--- 1851,1858 ---- + { + lua_pushvalue(L, -1); /* function */ + luaV_pushline(L, curbuf, l); /* current line as arg */ +! lua_pushinteger(L, l); /* current line number as arg */ +! if (lua_pcall(L, 2, 1, 0)) + { + luaV_emsg(L); + break; +*** ../vim-7.3.493/src/version.c 2012-04-06 13:56:00.000000000 +0200 +--- src/version.c 2012-04-06 14:25:11.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 494, + /**/ + +-- +Why doesn't Tarzan have a beard? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 83157de8151fe86930f870002ee3acf76a4f4137 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:17 +0200 Subject: [PATCH 0227/3340] - patchlevel 495 --- 7.3.495 | 124 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 124 insertions(+) create mode 100644 7.3.495 diff --git a/7.3.495 b/7.3.495 new file mode 100644 index 00000000..54c23062 --- /dev/null +++ b/7.3.495 @@ -0,0 +1,124 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.4 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.495 (after 7.3.492) +Problem: Compiler warnings. +Solution: Add function declaration. Remove "offset" argument. +Files: src/misc1.c + + +*** ../vim-7.3.494/src/misc1.c 2012-04-06 13:56:00.000000000 +0200 +--- src/misc1.c 2012-04-09 20:25:58.000000000 +0200 +*************** +*** 4972,4977 **** +--- 4972,4978 ---- + static int cin_iselse __ARGS((char_u *)); + static int cin_isdo __ARGS((char_u *)); + static int cin_iswhileofdo __ARGS((char_u *, linenr_T, int)); ++ static int cin_is_if_for_while_before_offset __ARGS((char_u *line, int *poffset)); + static int cin_iswhileofdo_end __ARGS((int terminated, int ind_maxparen, int ind_maxcomment)); + static int cin_isbreak __ARGS((char_u *)); + static int cin_is_cpp_baseclass __ARGS((colnr_T *col)); +*************** +*** 5771,5787 **** + } + + /* +! * Check whether in "p" there is an "if", "for" or "while" before offset. + * Return 0 if there is none. + * Otherwise return !0 and update "*poffset" to point to the place where the + * string was found. + */ + static int +! cin_is_if_for_while_before_offset(line, offset, poffset) + char_u *line; +- size_t offset; + int *poffset; + { + + if (offset-- < 2) + return 0; +--- 5772,5788 ---- + } + + /* +! * Check whether in "p" there is an "if", "for" or "while" before "*poffset". + * Return 0 if there is none. + * Otherwise return !0 and update "*poffset" to point to the place where the + * string was found. + */ + static int +! cin_is_if_for_while_before_offset(line, poffset) + char_u *line; + int *poffset; + { ++ int offset = *poffset; + + if (offset-- < 2) + return 0; +*************** +*** 5805,5812 **** + goto probablyFound; + } + } +- + return 0; + probablyFound: + if (!offset || !vim_isIDc(line[offset - 1])) + { +--- 5806,5813 ---- + goto probablyFound; + } + } + return 0; ++ + probablyFound: + if (!offset || !vim_isIDc(line[offset - 1])) + { +*************** +*** 6890,6897 **** + line = ml_get(outermost.lnum); + + is_if_for_while = +! cin_is_if_for_while_before_offset(line, outermost.col, +! &outermost.col); + } + + amount = skip_label(our_paren_pos.lnum, &look, ind_maxcomment); +--- 6891,6897 ---- + line = ml_get(outermost.lnum); + + is_if_for_while = +! cin_is_if_for_while_before_offset(line, &outermost.col); + } + + amount = skip_label(our_paren_pos.lnum, &look, ind_maxcomment); +*** ../vim-7.3.494/src/version.c 2012-04-06 14:30:55.000000000 +0200 +--- src/version.c 2012-04-09 20:41:44.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 495, + /**/ + +-- + [clop clop] +GUARD #1: Halt! Who goes there? +ARTHUR: It is I, Arthur, son of Uther Pendragon, from the castle of + Camelot. King of the Britons, defeator of the Saxons, sovereign of + all England! +GUARD #1: Pull the other one! + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d5697f2b20cf2b3987033e63d56e2f29ffda76fb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:18 +0200 Subject: [PATCH 0228/3340] - patchlevel 496 --- 7.3.496 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.496 diff --git a/7.3.496 b/7.3.496 new file mode 100644 index 00000000..8b110517 --- /dev/null +++ b/7.3.496 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.496 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.496 +Problem: MS-DOS: When "diff" trips over difference in line separators some + tests fail. +Solution: Make some .ok files use unix line separators. (David Pope) +Files: src/testdir/Make_dos.mak, src/testdir/Make_ming.mak + + +*** ../vim-7.3.495/src/testdir/Make_dos.mak 2012-04-05 16:56:38.000000000 +0200 +--- src/testdir/Make_dos.mak 2012-04-09 21:23:43.000000000 +0200 +*************** +*** 52,58 **** + + fixff: + -$(VIMPROG) -u dos.vim --noplugin "+argdo set ff=dos|upd" +q *.in *.ok +! -$(VIMPROG) -u dos.vim --noplugin "+argdo set ff=unix|upd" +q dotest.in + + clean: + -del *.out +--- 52,59 ---- + + fixff: + -$(VIMPROG) -u dos.vim --noplugin "+argdo set ff=dos|upd" +q *.in *.ok +! -$(VIMPROG) -u dos.vim --noplugin "+argdo set ff=unix|upd" +q \ +! dotest.in test60.ok test71.ok test74.ok + + clean: + -del *.out +*** ../vim-7.3.495/src/testdir/Make_ming.mak 2012-04-05 16:56:38.000000000 +0200 +--- src/testdir/Make_ming.mak 2012-04-09 21:25:55.000000000 +0200 +*************** +*** 75,80 **** +--- 75,82 ---- + + fixff: + -$(VIMPROG) -u dos.vim --noplugin "+argdo set ff=dos|upd" +q *.in *.ok ++ -$(VIMPROG) -u dos.vim --noplugin "+argdo set ff=unix|upd" +q \ ++ dotest.in test60.ok test71.ok test74.ok + + clean: + -$(DEL) *.out +*** ../vim-7.3.495/src/version.c 2012-04-09 20:42:20.000000000 +0200 +--- src/version.c 2012-04-13 19:10:04.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 496, + /**/ + +-- +There are 2 kinds of people in my world: those who know Unix, Perl, Vim, GNU, +Linux, etc, and those who know COBOL. It gets very difficult for me at +parties, not knowing which group to socialise with :-) + Sitaram Chamarty + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9476d17dfb7145178a48a52b6f93e9802522b584 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:18 +0200 Subject: [PATCH 0229/3340] - patchlevel 497 --- 7.3.497 | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 7.3.497 diff --git a/7.3.497 b/7.3.497 new file mode 100644 index 00000000..5cbffc4a --- /dev/null +++ b/7.3.497 @@ -0,0 +1,50 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.497 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.497 +Problem: Crash when doing ":python print" and compiled with gcc and + the optimizer enabled. +Solution: Avoid the crash, doesn't really fix the problem. (Christian + Brabandt) +Files: src/if_py_both.h + + +*** ../vim-7.3.496/src/if_py_both.h 2012-02-04 20:17:21.000000000 +0100 +--- src/if_py_both.h 2012-04-20 13:24:31.000000000 +0200 +*************** +*** 77,82 **** +--- 77,87 ---- + if (!PyArg_ParseTuple(args, "et#", ENC_OPT, &str, &len)) + return NULL; + ++ /* TODO: This works around a gcc optimizer problem and avoids Vim ++ * from crashing. Should find a real solution. */ ++ if (str == NULL) ++ return NULL; ++ + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + writer((writefn)(error ? emsg : msg), (char_u *)str, len); +*** ../vim-7.3.496/src/version.c 2012-04-13 19:11:16.000000000 +0200 +--- src/version.c 2012-04-20 13:26:22.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 497, + /**/ + +-- +There can't be a crisis today, my schedule is already full. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From cc554e9e6c3b38594acca24238b2e72b3e536e1c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:18 +0200 Subject: [PATCH 0230/3340] - patchlevel 498 --- 7.3.498 | 63 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 7.3.498 diff --git a/7.3.498 b/7.3.498 new file mode 100644 index 00000000..aa9c621e --- /dev/null +++ b/7.3.498 @@ -0,0 +1,63 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.498 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.498 +Problem: The behavior of the "- register changes depending on value of + the 'clipboard' option. (Szamotulski) +Solution: Also set the "- register when the register is "*" or "+". + (Christian Brabandt) +Files: src/ops.c + + +*** ../vim-7.3.497/src/ops.c 2012-03-23 14:16:19.000000000 +0100 +--- src/ops.c 2012-04-20 13:36:32.000000000 +0200 +*************** +*** 1720,1728 **** + did_yank = TRUE; + } + +! /* Yank into small delete register when no register specified and the +! * delete is within one line. */ +! if (oap->regname == 0 && oap->motion_type != MLINE + && oap->line_count == 1) + { + oap->regname = '-'; +--- 1720,1733 ---- + did_yank = TRUE; + } + +! /* Yank into small delete register when no named register specified +! * and the delete is within one line. */ +! if (( +! #ifdef FEAT_CLIPBOARD +! ((clip_unnamed & CLIP_UNNAMED) && oap->regname == '*') || +! ((clip_unnamed & CLIP_UNNAMED_PLUS) && oap->regname == '+') || +! #endif +! oap->regname == 0) && oap->motion_type != MLINE + && oap->line_count == 1) + { + oap->regname = '-'; +*** ../vim-7.3.497/src/version.c 2012-04-20 13:31:16.000000000 +0200 +--- src/version.c 2012-04-20 13:45:26.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 498, + /**/ + +-- +Did you ever stop to think... and forget to start again? + -- Steven Wright + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c8148400460d470e5e5daca4240bddc92a76f99e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:18 +0200 Subject: [PATCH 0231/3340] - patchlevel 499 --- 7.3.499 | 84 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 7.3.499 diff --git a/7.3.499 b/7.3.499 new file mode 100644 index 00000000..4e45e4fb --- /dev/null +++ b/7.3.499 @@ -0,0 +1,84 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.499 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.499 +Problem: When using any interface language when Vim is waiting for a child + process it gets confused by a child process started through the + interface. +Solution: Always used waitpid() instead of wait(). (Yasuhiro Matsumoto) +Files: src/os_unix.c + + +*** ../vim-7.3.498/src/os_unix.c 2012-02-05 22:51:27.000000000 +0100 +--- src/os_unix.c 2012-04-20 15:47:17.000000000 +0200 +*************** +*** 3734,3757 **** + + while (wait_pid != child) + { +! # ifdef _THREAD_SAFE +! /* Ugly hack: when compiled with Python threads are probably +! * used, in which case wait() sometimes hangs for no obvious +! * reason. Use waitpid() instead and loop (like the GUI). */ +! # ifdef __NeXT__ + wait_pid = wait4(child, status, WNOHANG, (struct rusage *)0); +! # else + wait_pid = waitpid(child, status, WNOHANG); +! # endif + if (wait_pid == 0) + { + /* Wait for 1/100 sec before trying again. */ + mch_delay(10L, TRUE); + continue; + } +- # else +- wait_pid = wait(status); +- # endif + if (wait_pid <= 0 + # ifdef ECHILD + && errno == ECHILD +--- 3734,3754 ---- + + while (wait_pid != child) + { +! /* When compiled with Python threads are probably used, in which case +! * wait() sometimes hangs for no obvious reason. Use waitpid() +! * instead and loop (like the GUI). Also needed for other interfaces, +! * they might call system(). */ +! # ifdef __NeXT__ + wait_pid = wait4(child, status, WNOHANG, (struct rusage *)0); +! # else + wait_pid = waitpid(child, status, WNOHANG); +! # endif + if (wait_pid == 0) + { + /* Wait for 1/100 sec before trying again. */ + mch_delay(10L, TRUE); + continue; + } + if (wait_pid <= 0 + # ifdef ECHILD + && errno == ECHILD +*** ../vim-7.3.498/src/version.c 2012-04-20 13:46:02.000000000 +0200 +--- src/version.c 2012-04-20 15:54:05.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 499, + /**/ + +-- +It's not hard to meet expenses, they're everywhere. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bfcbea361a4db087c4d8e3c3d9b8069db68599e1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:19 +0200 Subject: [PATCH 0232/3340] - patchlevel 500 --- 7.3.500 | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 7.3.500 diff --git a/7.3.500 b/7.3.500 new file mode 100644 index 00000000..b3b6a375 --- /dev/null +++ b/7.3.500 @@ -0,0 +1,46 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.500 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.500 +Problem: Ming makefile unconditionally sets WINVER. +Solution: Only defined when not already defined. (Yasuhiro Matsumoto) +Files: src/Make_ming.mak + + +*** ../vim-7.3.499/src/Make_ming.mak 2012-03-28 17:43:06.000000000 +0200 +--- src/Make_ming.mak 2012-04-20 16:03:50.000000000 +0200 +*************** +*** 51,57 **** +--- 51,59 ---- + # set to yes to enable OLE support + OLE=no + # Set the default $(WINVER) to make it work with pre-Win2k ++ ifndef WINVER + WINVER = 0x0400 ++ endif + # Set to yes to enable Cscope support + CSCOPE=yes + # Set to yes to enable Netbeans support +*** ../vim-7.3.499/src/version.c 2012-04-20 15:55:10.000000000 +0200 +--- src/version.c 2012-04-20 16:12:34.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 500, + /**/ + +-- +Life is a gift, living is an art. (Bram Moolenaar) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b1ba9edffdcf6a85a2ebd785fb1b013f63f20422 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:19 +0200 Subject: [PATCH 0233/3340] - patchlevel 501 --- 7.3.501 | 63 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 7.3.501 diff --git a/7.3.501 b/7.3.501 new file mode 100644 index 00000000..a74b0288 --- /dev/null +++ b/7.3.501 @@ -0,0 +1,63 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.501 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.501 +Problem: Error for "flush" not being defined when using Ruby command. +Solution: Defined "flush" as a no-op method. (Kent Sibilev) +Files: src/if_ruby.c + + +*** ../vim-7.3.500/src/if_ruby.c 2011-08-04 19:34:55.000000000 +0200 +--- src/if_ruby.c 2012-04-20 16:18:56.000000000 +0200 +*************** +*** 1238,1243 **** +--- 1238,1248 ---- + return Qnil; + } + ++ static VALUE f_nop(VALUE self) ++ { ++ return Qnil; ++ } ++ + static VALUE f_p(int argc, VALUE *argv, VALUE self UNUSED) + { + int i; +*************** +*** 1259,1264 **** +--- 1264,1270 ---- + + rb_stdout = rb_obj_alloc(rb_cObject); + rb_define_singleton_method(rb_stdout, "write", vim_message, 1); ++ rb_define_singleton_method(rb_stdout, "flush", f_nop, 0); + rb_define_global_function("p", f_p, -1); + } + +*** ../vim-7.3.500/src/version.c 2012-04-20 16:13:21.000000000 +0200 +--- src/version.c 2012-04-20 16:19:03.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 501, + /**/ + +-- +Q: What do you call a fish without an eye? +A: fsh! +Q: What do you call a deer with no eyes? +A: no eye deer. +Q: What do you call a deer with no eyes and no legs? +A: still no eye deer. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 750d5410c270c2e2c921d5052c51766bd0928e30 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:20 +0200 Subject: [PATCH 0234/3340] - patchlevel 502 --- 7.3.502 | 67 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 7.3.502 diff --git a/7.3.502 b/7.3.502 new file mode 100644 index 00000000..c9710abf --- /dev/null +++ b/7.3.502 @@ -0,0 +1,67 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.502 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.502 +Problem: Netbeans insert halfway a line actually appends to the line. +Solution: Insert halfway the line. (Brian Victor) +Files: src/netbeans.c + + +*** ../vim-7.3.501/src/netbeans.c 2012-01-10 22:31:26.000000000 +0100 +--- src/netbeans.c 2012-04-20 19:44:31.000000000 +0200 +*************** +*** 1812,1825 **** + char_u *oldline = ml_get(lnum); + char_u *newline; + +! /* Insert halfway a line. For simplicity we assume we +! * need to append to the line. */ + newline = alloc_check( + (unsigned)(STRLEN(oldline) + len + 1)); + if (newline != NULL) + { +! STRCPY(newline, oldline); + STRCAT(newline, args); + ml_replace(lnum, newline, FALSE); + } + } +--- 1812,1826 ---- + char_u *oldline = ml_get(lnum); + char_u *newline; + +! /* Insert halfway a line. */ + newline = alloc_check( + (unsigned)(STRLEN(oldline) + len + 1)); + if (newline != NULL) + { +! mch_memmove(newline, oldline, (size_t)pos->col); +! newline[pos->col] = NUL; + STRCAT(newline, args); ++ STRCAT(newline, oldline + pos->col); + ml_replace(lnum, newline, FALSE); + } + } +*** ../vim-7.3.501/src/version.c 2012-04-20 18:05:42.000000000 +0200 +--- src/version.c 2012-04-20 19:46:48.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 502, + /**/ + +-- +Time flies like an arrow. +Fruit flies like a banana. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1d8d1b07fd20234c54ee63b92277034fb8d5a290 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:20 +0200 Subject: [PATCH 0235/3340] - patchlevel 503 --- 7.3.503 | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 7.3.503 diff --git a/7.3.503 b/7.3.503 new file mode 100644 index 00000000..5b776ae0 --- /dev/null +++ b/7.3.503 @@ -0,0 +1,51 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.503 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.503 (after 7.3.501) +Problem: Warning for unused argument. +Solution: Add UNUSED. +Files: src/if_ruby.c + + +*** ../vim-7.3.502/src/if_ruby.c 2012-04-20 18:05:42.000000000 +0200 +--- src/if_ruby.c 2012-04-25 12:26:38.000000000 +0200 +*************** +*** 1238,1244 **** + return Qnil; + } + +! static VALUE f_nop(VALUE self) + { + return Qnil; + } +--- 1238,1244 ---- + return Qnil; + } + +! static VALUE f_nop(VALUE self UNUSED) + { + return Qnil; + } +*** ../vim-7.3.502/src/version.c 2012-04-20 19:47:00.000000000 +0200 +--- src/version.c 2012-04-25 12:27:30.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 503, + /**/ + +-- +Why isn't there mouse-flavored cat food? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d59b1c2b31d6d333806e83563187246f7c484c6f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:20 +0200 Subject: [PATCH 0236/3340] - patchlevel 504 --- 7.3.504 | 87 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 87 insertions(+) create mode 100644 7.3.504 diff --git a/7.3.504 b/7.3.504 new file mode 100644 index 00000000..75227906 --- /dev/null +++ b/7.3.504 @@ -0,0 +1,87 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.504 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.504 +Problem: Commands in help files are not highlighted. +Solution: Allow for commands in backticks. Adjust CTRL-] to remove the + backticks. +Files: src/ex_cmds.c + + +*** ../vim-7.3.503/src/ex_cmds.c 2012-04-05 16:04:58.000000000 +0200 +--- src/ex_cmds.c 2012-04-25 12:51:41.000000000 +0200 +*************** +*** 3421,3427 **** + * and re-attach to buffer, perhaps. + */ + if (curwin->w_s == &(curwin->w_buffer->b_s)) +! curwin->w_s = &(buf->b_s); + #endif + curwin->w_buffer = buf; + curbuf = buf; +--- 3421,3427 ---- + * and re-attach to buffer, perhaps. + */ + if (curwin->w_s == &(curwin->w_buffer->b_s)) +! curwin->w_s = &(buf->b_s); + #endif + curwin->w_buffer = buf; + curbuf = buf; +*************** +*** 5965,5970 **** +--- 5965,5993 ---- + break; + } + *d = NUL; ++ ++ if (*IObuff == '`') ++ { ++ if (d > IObuff + 2 && d[-1] == '`') ++ { ++ /* remove the backticks from `command` */ ++ mch_memmove(IObuff, IObuff + 1, STRLEN(IObuff)); ++ d[-2] = NUL; ++ } ++ else if (d > IObuff + 3 && d[-2] == '`' && d[-1] == ',') ++ { ++ /* remove the backticks and comma from `command`, */ ++ mch_memmove(IObuff, IObuff + 1, STRLEN(IObuff)); ++ d[-3] = NUL; ++ } ++ else if (d > IObuff + 4 && d[-3] == '`' ++ && d[-2] == '\\' && d[-1] == '.') ++ { ++ /* remove the backticks and dot from `command`\. */ ++ mch_memmove(IObuff, IObuff + 1, STRLEN(IObuff)); ++ d[-4] = NUL; ++ } ++ } + } + } + +*** ../vim-7.3.503/src/version.c 2012-04-25 12:28:05.000000000 +0200 +--- src/version.c 2012-04-25 12:46:43.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 504, + /**/ + +-- +TIM: That is not an ordinary rabbit ... 'tis the most foul cruel and + bad-tempered thing you ever set eyes on. +ROBIN: You tit. I soiled my armour I was so scared! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fe956b7396e55cac2574a0a9fcc7c515bd518380 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:21 +0200 Subject: [PATCH 0237/3340] - patchlevel 505 --- 7.3.505 | 116 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 116 insertions(+) create mode 100644 7.3.505 diff --git a/7.3.505 b/7.3.505 new file mode 100644 index 00000000..1a8a7ea3 --- /dev/null +++ b/7.3.505 @@ -0,0 +1,116 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.505 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.505 +Problem: Test 11 fails on MS-Windows in some versions. +Solution: Fix #ifdefs for whether filtering through a pipe is possible. Move + setting b_no_eol_lnum back to where it was before patch 7.3.124. + (David Pope) +Files: src/feature.h, src/eval.c, src/ex_cmds.c, src/fileio.c + + +*** ../vim-7.3.504/src/feature.h 2011-10-20 21:09:25.000000000 +0200 +--- src/feature.h 2012-04-25 16:44:26.000000000 +0200 +*************** +*** 1316,1318 **** +--- 1316,1326 ---- + #ifdef FEAT_NORMAL + # define FEAT_PERSISTENT_UNDO + #endif ++ ++ /* ++ * +filterpipe ++ */ ++ #if (defined(UNIX) && !defined(USE_SYSTEM)) \ ++ || (defined(WIN3264) && defined(FEAT_GUI_W32)) ++ # define FEAT_FILTERPIPE ++ #endif +*** ../vim-7.3.504/src/eval.c 2012-04-05 16:53:55.000000000 +0200 +--- src/eval.c 2012-04-25 16:43:53.000000000 +0200 +*************** +*** 12090,12096 **** + #ifdef FEAT_SEARCHPATH + "file_in_path", + #endif +! #if (defined(UNIX) && !defined(USE_SYSTEM)) || defined(WIN3264) + "filterpipe", + #endif + #ifdef FEAT_FIND_ID +--- 12090,12096 ---- + #ifdef FEAT_SEARCHPATH + "file_in_path", + #endif +! #ifdef FEAT_FILTERPIPE + "filterpipe", + #endif + #ifdef FEAT_FIND_ID +*** ../vim-7.3.504/src/ex_cmds.c 2012-04-25 12:57:23.000000000 +0200 +--- src/ex_cmds.c 2012-04-25 16:46:02.000000000 +0200 +*************** +*** 1113,1119 **** + if (do_out) + shell_flags |= SHELL_DOOUT; + +! #if (!defined(USE_SYSTEM) && defined(UNIX)) || defined(WIN3264) + if (!do_in && do_out && !p_stmp) + { + /* Use a pipe to fetch stdout of the command, do not use a temp file. */ +--- 1113,1119 ---- + if (do_out) + shell_flags |= SHELL_DOOUT; + +! #ifdef FEAT_FILTERPIPE + if (!do_in && do_out && !p_stmp) + { + /* Use a pipe to fetch stdout of the command, do not use a temp file. */ +*** ../vim-7.3.504/src/fileio.c 2012-02-29 18:22:03.000000000 +0100 +--- src/fileio.c 2012-04-25 16:40:37.000000000 +0200 +*************** +*** 2655,2664 **** + } + #endif + +- /* Reset now, following writes should not omit the EOL. Also, the line +- * number will become invalid because of edits. */ +- curbuf->b_no_eol_lnum = 0; +- + if (recoverymode && error) + return FAIL; + return OK; +--- 2655,2660 ---- +*************** +*** 5098,5103 **** +--- 5094,5101 ---- + { + aco_save_T aco; + ++ curbuf->b_no_eol_lnum = 0; /* in case it was set by the previous read */ ++ + /* + * Apply POST autocommands. + * Careful: The autocommands may call buf_write() recursively! +*** ../vim-7.3.504/src/version.c 2012-04-25 12:57:23.000000000 +0200 +--- src/version.c 2012-04-25 16:49:50.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 505, + /**/ + +-- +Lose weight, NEVER Diet again with + The "Invisible Weight Loss Patch" + (spam e-mail) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ec0d344211fe6dce90f50a5a446078b0bd2ce9fe Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:21 +0200 Subject: [PATCH 0238/3340] - patchlevel 506 --- 7.3.506 | 100 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 100 insertions(+) create mode 100644 7.3.506 diff --git a/7.3.506 b/7.3.506 new file mode 100644 index 00000000..32be6fd1 --- /dev/null +++ b/7.3.506 @@ -0,0 +1,100 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.506 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.506 +Problem: GTK gives an error when selecting a non-existent file. +Solution: Add a handler to avoid the error. (Christian Brabandt) +Files: src/gui_gtk.c + + +*** ../vim-7.3.505/src/gui_gtk.c 2011-06-26 04:48:56.000000000 +0200 +--- src/gui_gtk.c 2012-04-25 17:08:58.000000000 +0200 +*************** +*** 90,95 **** +--- 90,100 ---- + static void entry_activate_cb(GtkWidget *widget, gpointer data); + static void entry_changed_cb(GtkWidget *entry, GtkWidget *dialog); + static void find_replace_cb(GtkWidget *widget, gpointer data); ++ static void recent_func_log_func( ++ const gchar *log_domain, ++ GLogLevelFlags log_level, ++ const gchar *message, ++ gpointer user_data); + + #if defined(FEAT_TOOLBAR) + /* +*************** +*** 839,844 **** +--- 844,851 ---- + GtkWidget *fc; + #endif + char_u dirbuf[MAXPATHL]; ++ guint log_handler; ++ const gchar *domain = "Gtk"; + + title = CONVERT_TO_UTF8(title); + +*************** +*** 853,858 **** +--- 860,870 ---- + /* If our pointer is currently hidden, then we should show it. */ + gui_mch_mousehide(FALSE); + ++ /* Hack: The GTK file dialog warns when it can't access a new file, this ++ * makes it shut up. http://bugzilla.gnome.org/show_bug.cgi?id=664587 */ ++ log_handler = g_log_set_handler(domain, G_LOG_LEVEL_WARNING, ++ recent_func_log_func, NULL); ++ + #ifdef USE_FILE_CHOOSER + /* We create the dialog each time, so that the button text can be "Open" + * or "Save" according to the action. */ +*************** +*** 916,921 **** +--- 928,934 ---- + gtk_widget_show(gui.filedlg); + gtk_main(); + #endif ++ g_log_remove_handler(domain, log_handler); + + CONVERT_TO_UTF8_FREE(title); + if (gui.browse_fname == NULL) +*************** +*** 1882,1884 **** +--- 1895,1908 ---- + * backwards compatibility anyway. */ + do_cmdline_cmd((char_u *)"emenu ToolBar.FindHelp"); + } ++ ++ static void ++ recent_func_log_func(const gchar *log_domain UNUSED, ++ GLogLevelFlags log_level UNUSED, ++ const gchar *message UNUSED, ++ gpointer user_data UNUSED) ++ { ++ /* We just want to suppress the warnings. */ ++ /* http://bugzilla.gnome.org/show_bug.cgi?id=664587 */ ++ } ++ +*** ../vim-7.3.505/src/version.c 2012-04-25 16:50:44.000000000 +0200 +--- src/version.c 2012-04-25 17:08:28.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 506, + /**/ + +-- +Compilation process failed successfully. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4069902d77ec7eb7436211fd49b46f02efd9f699 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:21 +0200 Subject: [PATCH 0239/3340] - patchlevel 507 --- 7.3.507 | 149 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 149 insertions(+) create mode 100644 7.3.507 diff --git a/7.3.507 b/7.3.507 new file mode 100644 index 00000000..c96561c3 --- /dev/null +++ b/7.3.507 @@ -0,0 +1,149 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.507 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.507 +Problem: When exiting with unsaved changes, selecting an existing file in + the file dialog, there is no dialog to ask whether the existing + file should be overwritten. (Felipe G. Nievinski) +Solution: Call check_overwrite() before writing. (Christian Brabandt) +Files: src/ex_cmds.c, src/ex_cmds2.c, src/proto/ex_cmds.pro + + +*** ../vim-7.3.506/src/ex_cmds.c 2012-04-25 16:50:44.000000000 +0200 +--- src/ex_cmds.c 2012-04-25 17:19:53.000000000 +0200 +*************** +*** 25,31 **** + static int read_viminfo_up_to_marks __ARGS((vir_T *virp, int forceit, int writing)); + #endif + +- static int check_overwrite __ARGS((exarg_T *eap, buf_T *buf, char_u *fname, char_u *ffname, int other)); + static int check_readonly __ARGS((int *forceit, buf_T *buf)); + #ifdef FEAT_AUTOCMD + static void delbuf_msg __ARGS((char_u *name)); +--- 25,30 ---- +*************** +*** 2722,2728 **** + * May set eap->forceit if a dialog says it's OK to overwrite. + * Return OK if it's OK, FAIL if it is not. + */ +! static int + check_overwrite(eap, buf, fname, ffname, other) + exarg_T *eap; + buf_T *buf; +--- 2721,2727 ---- + * May set eap->forceit if a dialog says it's OK to overwrite. + * Return OK if it's OK, FAIL if it is not. + */ +! int + check_overwrite(eap, buf, fname, ffname, other) + exarg_T *eap; + buf_T *buf; +*** ../vim-7.3.506/src/ex_cmds2.c 2012-03-23 18:39:10.000000000 +0100 +--- src/ex_cmds2.c 2012-04-25 17:24:37.000000000 +0200 +*************** +*** 1489,1494 **** +--- 1489,1495 ---- + char_u buff[DIALOG_MSG_SIZE]; + int ret; + buf_T *buf2; ++ exarg_T ea; + + dialog_msg(buff, _("Save changes to \"%s\"?"), + (buf->b_fname != NULL) ? +*************** +*** 1498,1510 **** + else + ret = vim_dialog_yesnocancel(VIM_QUESTION, NULL, buff, 1); + + if (ret == VIM_YES) + { + #ifdef FEAT_BROWSE + /* May get file name, when there is none */ + browse_save_fname(buf); + #endif +! if (buf->b_fname != NULL) /* didn't hit Cancel */ + (void)buf_write_all(buf, FALSE); + } + else if (ret == VIM_NO) +--- 1499,1517 ---- + else + ret = vim_dialog_yesnocancel(VIM_QUESTION, NULL, buff, 1); + ++ /* Init ea pseudo-structure, this is needed for the check_overwrite() ++ * function. */ ++ ea.append = ea.forceit = FALSE; ++ + if (ret == VIM_YES) + { + #ifdef FEAT_BROWSE + /* May get file name, when there is none */ + browse_save_fname(buf); + #endif +! if (buf->b_fname != NULL && check_overwrite(&ea, buf, +! buf->b_fname, buf->b_ffname, FALSE) == OK) +! /* didn't hit Cancel */ + (void)buf_write_all(buf, FALSE); + } + else if (ret == VIM_NO) +*************** +*** 1532,1538 **** + /* May get file name, when there is none */ + browse_save_fname(buf2); + #endif +! if (buf2->b_fname != NULL) /* didn't hit Cancel */ + (void)buf_write_all(buf2, FALSE); + #ifdef FEAT_AUTOCMD + /* an autocommand may have deleted the buffer */ +--- 1539,1547 ---- + /* May get file name, when there is none */ + browse_save_fname(buf2); + #endif +! if (buf2->b_fname != NULL && check_overwrite(&ea, buf2, +! buf2->b_fname, buf2->b_ffname, FALSE) == OK) +! /* didn't hit Cancel */ + (void)buf_write_all(buf2, FALSE); + #ifdef FEAT_AUTOCMD + /* an autocommand may have deleted the buffer */ +*** ../vim-7.3.506/src/proto/ex_cmds.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/ex_cmds.pro 2012-04-25 17:25:47.000000000 +0200 +*************** +*** 23,28 **** +--- 23,29 ---- + void ex_update __ARGS((exarg_T *eap)); + void ex_write __ARGS((exarg_T *eap)); + int do_write __ARGS((exarg_T *eap)); ++ int check_overwrite __ARGS((exarg_T *eap, buf_T *buf, char_u *fname, char_u *ffname, int other)); + void ex_wnext __ARGS((exarg_T *eap)); + void do_wqall __ARGS((exarg_T *eap)); + int not_writing __ARGS((void)); +*** ../vim-7.3.506/src/version.c 2012-04-25 17:10:12.000000000 +0200 +--- src/version.c 2012-04-25 17:17:30.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 507, + /**/ + +-- +BROTHER MAYNARD: Armaments Chapter Two Verses Nine to Twenty One. +ANOTHER MONK: And St. Attila raised his hand grenade up on high saying "O + Lord bless this thy hand grenade that with it thou mayest + blow thine enemies to tiny bits, in thy mercy. "and the Lord + did grin and people did feast upon the lambs and sloths and + carp and anchovies and orang-utans and breakfast cereals and + fruit bats and... +BROTHER MAYNARD: Skip a bit brother ... + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e2dea896eeace7bbbf2de5312f1f65e929936bb7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:22 +0200 Subject: [PATCH 0240/3340] - patchlevel 508 --- 7.3.508 | 85 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100644 7.3.508 diff --git a/7.3.508 b/7.3.508 new file mode 100644 index 00000000..7b8e7b26 --- /dev/null +++ b/7.3.508 @@ -0,0 +1,85 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.508 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.508 +Problem: Default for v:register is not set. +Solution: Init v:register in eval_init(). Correct for 'clipboard' before the + main loop. (Ingo Karkat) +Files: src/eval.c, src/main.c + + +*** ../vim-7.3.507/src/eval.c 2012-04-25 16:50:44.000000000 +0200 +--- src/eval.c 2012-04-25 17:56:41.000000000 +0200 +*************** +*** 880,885 **** +--- 880,886 ---- + hash_add(&compat_hashtab, p->vv_di.di_key); + } + set_vim_var_nr(VV_SEARCHFORWARD, 1L); ++ set_reg_var(0); /* default for v:register is not 0 but '"' */ + + #ifdef EBCDIC + /* +*** ../vim-7.3.507/src/main.c 2012-03-28 17:10:26.000000000 +0200 +--- src/main.c 2012-04-25 18:01:28.000000000 +0200 +*************** +*** 928,933 **** +--- 928,945 ---- + TIME_MSG("VimEnter autocommands"); + #endif + ++ #if defined(FEAT_EVAL) && defined(FEAT_CLIPBOARD) ++ /* Adjust default register name for "unnamed" in 'clipboard'. Can only be ++ * done after the clipboard is available and all initial commands that may ++ * modify the 'clipboard' setting have run; i.e. just before entering the ++ * main loop. */ ++ { ++ int default_regname = 0; ++ adjust_clip_reg(&default_regname); ++ set_reg_var(default_regname); ++ } ++ #endif ++ + #if defined(FEAT_DIFF) && defined(FEAT_SCROLLBIND) + /* When a startup script or session file setup for diff'ing and + * scrollbind, sync the scrollbind now. */ +*************** +*** 1357,1363 **** + { + apply_autocmds(EVENT_BUFWINLEAVE, buf->b_fname, + buf->b_fname, FALSE, buf); +! buf->b_changedtick = -1; /* note that we did it already */ + /* start all over, autocommands may mess up the lists */ + next_tp = first_tabpage; + break; +--- 1369,1375 ---- + { + apply_autocmds(EVENT_BUFWINLEAVE, buf->b_fname, + buf->b_fname, FALSE, buf); +! buf->b_changedtick = -1; /* note that we did it already */ + /* start all over, autocommands may mess up the lists */ + next_tp = first_tabpage; + break; +*** ../vim-7.3.507/src/version.c 2012-04-25 17:32:14.000000000 +0200 +--- src/version.c 2012-04-25 18:00:28.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 508, + /**/ + +-- +I wonder, do vegetarians eat fruit bats? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d6c1777dda9bfd77269ef5147c14228c5ecda7cb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:22 +0200 Subject: [PATCH 0241/3340] - patchlevel 509 --- 7.3.509 | 304 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 304 insertions(+) create mode 100644 7.3.509 diff --git a/7.3.509 b/7.3.509 new file mode 100644 index 00000000..8dfe9c09 --- /dev/null +++ b/7.3.509 @@ -0,0 +1,304 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.509 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.509 +Problem: ":vimgrep" fails when 'autochdir' is set. +Solution: A more generic solution for changing directory. (Ben Fritz) +Files: src/quickfix.c + + +*** ../vim-7.3.508/src/quickfix.c 2012-03-07 20:13:44.000000000 +0100 +--- src/quickfix.c 2012-04-25 18:52:24.000000000 +0200 +*************** +*** 130,138 **** + static void qf_fill_buffer __ARGS((qf_info_T *qi)); + #endif + static char_u *get_mef_name __ARGS((void)); +! static buf_T *load_dummy_buffer __ARGS((char_u *fname)); +! static void wipe_dummy_buffer __ARGS((buf_T *buf)); +! static void unload_dummy_buffer __ARGS((buf_T *buf)); + static qf_info_T *ll_get_or_alloc_list __ARGS((win_T *)); + + /* Quickfix window check helper macro */ +--- 130,139 ---- + static void qf_fill_buffer __ARGS((qf_info_T *qi)); + #endif + static char_u *get_mef_name __ARGS((void)); +! static void restore_start_dir __ARGS((char_u *dirname_start)); +! static buf_T *load_dummy_buffer __ARGS((char_u *fname, char_u *dirname_start, char_u *resulting_dir)); +! static void wipe_dummy_buffer __ARGS((buf_T *buf, char_u *dirname_start)); +! static void unload_dummy_buffer __ARGS((buf_T *buf, char_u *dirname_start)); + static qf_info_T *ll_get_or_alloc_list __ARGS((win_T *)); + + /* Quickfix window check helper macro */ +*************** +*** 3237,3255 **** + + /* Load file into a buffer, so that 'fileencoding' is detected, + * autocommands applied, etc. */ +! buf = load_dummy_buffer(fname); +! +! /* When autocommands changed directory: go back. We assume it was +! * ":lcd %:p:h". */ +! mch_dirname(dirname_now, MAXPATHL); +! if (STRCMP(dirname_start, dirname_now) != 0) +! { +! exarg_T ea; +! +! ea.arg = dirname_start; +! ea.cmdidx = CMD_lcd; +! ex_cd(&ea); +! } + + p_mls = save_mls; + #if defined(FEAT_AUTOCMD) && defined(FEAT_SYN_HL) +--- 3238,3244 ---- + + /* Load file into a buffer, so that 'fileencoding' is detected, + * autocommands applied, etc. */ +! buf = load_dummy_buffer(fname, dirname_start, dirname_now); + + p_mls = save_mls; + #if defined(FEAT_AUTOCMD) && defined(FEAT_SYN_HL) +*************** +*** 3320,3326 **** + { + /* Never keep a dummy buffer if there is another buffer + * with the same name. */ +! wipe_dummy_buffer(buf); + buf = NULL; + } + else if (!cmdmod.hide +--- 3309,3315 ---- + { + /* Never keep a dummy buffer if there is another buffer + * with the same name. */ +! wipe_dummy_buffer(buf, dirname_start); + buf = NULL; + } + else if (!cmdmod.hide +*************** +*** 3336,3347 **** + * many swap files. */ + if (!found_match) + { +! wipe_dummy_buffer(buf); + buf = NULL; + } + else if (buf != first_match_buf || (flags & VGR_NOJUMP)) + { +! unload_dummy_buffer(buf); + buf = NULL; + } + } +--- 3325,3336 ---- + * many swap files. */ + if (!found_match) + { +! wipe_dummy_buffer(buf, dirname_start); + buf = NULL; + } + else if (buf != first_match_buf || (flags & VGR_NOJUMP)) + { +! unload_dummy_buffer(buf, dirname_start); + buf = NULL; + } + } +*************** +*** 3487,3499 **** + } + + /* +! * Load file "fname" into a dummy buffer and return the buffer pointer. + * Returns NULL if it fails. +- * Must call unload_dummy_buffer() or wipe_dummy_buffer() later! + */ + static buf_T * +! load_dummy_buffer(fname) + char_u *fname; + { + buf_T *newbuf; + buf_T *newbuf_to_wipe = NULL; +--- 3476,3523 ---- + } + + /* +! * Restore current working directory to "dirname_start" if they differ, taking +! * into account whether it is set locally or globally. +! */ +! static void +! restore_start_dir(dirname_start) +! char_u *dirname_start; +! { +! char_u *dirname_now = alloc(MAXPATHL); +! +! if (NULL != dirname_now) +! { +! mch_dirname(dirname_now, MAXPATHL); +! if (STRCMP(dirname_start, dirname_now) != 0) +! { +! /* If the directory has changed, change it back by building up an +! * appropriate ex command and executing it. */ +! exarg_T ea; +! +! ea.arg = dirname_start; +! ea.cmdidx = (curwin->w_localdir == NULL) ? CMD_cd : CMD_lcd; +! ex_cd(&ea); +! } +! } +! } +! +! /* +! * Load file "fname" into a dummy buffer and return the buffer pointer, +! * placing the directory resulting from the buffer load into the +! * "resulting_dir" pointer. "resulting_dir" must be allocated by the caller +! * prior to calling this function. Restores directory to "dirname_start" prior +! * to returning, if autocmds or the 'autochdir' option have changed it. +! * +! * If creating the dummy buffer does not fail, must call unload_dummy_buffer() +! * or wipe_dummy_buffer() later! +! * + * Returns NULL if it fails. + */ + static buf_T * +! load_dummy_buffer(fname, dirname_start, resulting_dir) + char_u *fname; ++ char_u *dirname_start; /* in: old directory */ ++ char_u *resulting_dir; /* out: new directory */ + { + buf_T *newbuf; + buf_T *newbuf_to_wipe = NULL; +*************** +*** 3548,3569 **** + wipe_buffer(newbuf_to_wipe, FALSE); + } + + if (!buf_valid(newbuf)) + return NULL; + if (failed) + { +! wipe_dummy_buffer(newbuf); + return NULL; + } + return newbuf; + } + + /* +! * Wipe out the dummy buffer that load_dummy_buffer() created. + */ + static void +! wipe_dummy_buffer(buf) + buf_T *buf; + { + if (curbuf != buf) /* safety check */ + { +--- 3572,3604 ---- + wipe_buffer(newbuf_to_wipe, FALSE); + } + ++ /* ++ * When autocommands/'autochdir' option changed directory: go back. ++ * Let the caller know what the resulting dir was first, in case it is ++ * important. ++ */ ++ mch_dirname(resulting_dir, MAXPATHL); ++ restore_start_dir(dirname_start); ++ + if (!buf_valid(newbuf)) + return NULL; + if (failed) + { +! wipe_dummy_buffer(newbuf, dirname_start); + return NULL; + } + return newbuf; + } + + /* +! * Wipe out the dummy buffer that load_dummy_buffer() created. Restores +! * directory to "dirname_start" prior to returning, if autocmds or the +! * 'autochdir' option have changed it. + */ + static void +! wipe_dummy_buffer(buf, dirname_start) + buf_T *buf; ++ char_u *dirname_start; + { + if (curbuf != buf) /* safety check */ + { +*************** +*** 3583,3600 **** + * new aborting error, interrupt, or uncaught exception. */ + leave_cleanup(&cs); + #endif + } + } + + /* +! * Unload the dummy buffer that load_dummy_buffer() created. + */ + static void +! unload_dummy_buffer(buf) + buf_T *buf; + { + if (curbuf != buf) /* safety check */ + close_buffer(NULL, buf, DOBUF_UNLOAD, FALSE); + } + + #if defined(FEAT_EVAL) || defined(PROTO) +--- 3618,3645 ---- + * new aborting error, interrupt, or uncaught exception. */ + leave_cleanup(&cs); + #endif ++ /* When autocommands/'autochdir' option changed directory: go back. */ ++ restore_start_dir(dirname_start); + } + } + + /* +! * Unload the dummy buffer that load_dummy_buffer() created. Restores +! * directory to "dirname_start" prior to returning, if autocmds or the +! * 'autochdir' option have changed it. + */ + static void +! unload_dummy_buffer(buf, dirname_start) + buf_T *buf; ++ char_u *dirname_start; + { + if (curbuf != buf) /* safety check */ ++ { + close_buffer(NULL, buf, DOBUF_UNLOAD, FALSE); ++ ++ /* When autocommands/'autochdir' option changed directory: go back. */ ++ restore_start_dir(dirname_start); ++ } + } + + #if defined(FEAT_EVAL) || defined(PROTO) +*** ../vim-7.3.508/src/version.c 2012-04-25 18:24:24.000000000 +0200 +--- src/version.c 2012-04-25 18:43:10.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 509, + /**/ + +-- + Arthur pulls Pin out. The MONK blesses the grenade as ... +ARTHUR: (quietly) One, two, five ... +GALAHAD: Three, sir! +ARTHUR: Three. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From abb655a19688c2e6f54404da9c52852caad837c4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:22 +0200 Subject: [PATCH 0242/3340] - patchlevel 510 --- 7.3.510 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.510 diff --git a/7.3.510 b/7.3.510 new file mode 100644 index 00000000..afe10414 --- /dev/null +++ b/7.3.510 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.510 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.510 +Problem: Test 77 fails on Solaris 7. (Michael Soyka) +Solution: Replace any tabs with spaces. +Files: src/testdir/test77.in + + +*** ../vim-7.3.509/src/testdir/test77.in 2011-03-22 18:10:34.000000000 +0100 +--- src/testdir/test77.in 2012-04-30 11:30:31.000000000 +0200 +*************** +*** 21,27 **** + :while i <= 2000000 | call append(i, range(i, i + 99)) | let i += 100 | endwhile + ggdd + :w! Xtest +! :!cksum Xtest > test.out + :qa! + ENDTEST + +--- 21,29 ---- + :while i <= 2000000 | call append(i, range(i, i + 99)) | let i += 100 | endwhile + ggdd + :w! Xtest +! :r !cksum Xtest +! :s/\s/ /g +! :.w! test.out + :qa! + ENDTEST + +*** ../vim-7.3.509/src/version.c 2012-04-25 18:57:17.000000000 +0200 +--- src/version.c 2012-04-30 11:33:35.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 510, + /**/ + +-- +SIGFUN -- signature too funny (core dumped) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From eb5c8efaf3151c5520ffb0ea279eb24a935d25cf Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:23 +0200 Subject: [PATCH 0243/3340] - patchlevel 511 --- 7.3.511 | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 7.3.511 diff --git a/7.3.511 b/7.3.511 new file mode 100644 index 00000000..a2b6dce0 --- /dev/null +++ b/7.3.511 @@ -0,0 +1,49 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.511 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.511 +Problem: Using a FileReadCmd autocommand that does ":e! {file}" may cause a + crash. (Christian Brabandt) +Solution: Properly restore curwin->w_s. +Files: src/fileio.c + + +*** ../vim-7.3.510/src/fileio.c 2012-04-25 16:50:44.000000000 +0200 +--- src/fileio.c 2012-04-30 17:04:22.000000000 +0200 +*************** +*** 8982,8987 **** +--- 8982,8991 ---- + && buf_valid(aco->new_curbuf) + && aco->new_curbuf->b_ml.ml_mfp != NULL) + { ++ # if defined(FEAT_SYN_HL) || defined(FEAT_SPELL) ++ if (curwin->w_s == &curbuf->b_s) ++ curwin->w_s = &aco->new_curbuf->b_s; ++ # endif + --curbuf->b_nwindows; + curbuf = aco->new_curbuf; + curwin->w_buffer = curbuf; +*** ../vim-7.3.510/src/version.c 2012-04-30 11:34:20.000000000 +0200 +--- src/version.c 2012-04-30 17:01:05.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 511, + /**/ + +-- +There is no right or wrong, there is only your personal opinion. + (Bram Moolenaar) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a32517f4bf19c81e1482a55fe791ae0298ebf45f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:23 +0200 Subject: [PATCH 0244/3340] - patchlevel 512 --- 7.3.512 | 70 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 7.3.512 diff --git a/7.3.512 b/7.3.512 new file mode 100644 index 00000000..838ae3e2 --- /dev/null +++ b/7.3.512 @@ -0,0 +1,70 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.512 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.512 +Problem: undofile() returns a useless name when passed an empty string. +Solution: Return an empty string. (Christian Brabandt) +Files: src/eval.c + + +*** ../vim-7.3.511/src/eval.c 2012-04-25 18:24:24.000000000 +0200 +--- src/eval.c 2012-04-30 17:23:26.000000000 +0200 +*************** +*** 18259,18269 **** + rettv->v_type = VAR_STRING; + #ifdef FEAT_PERSISTENT_UNDO + { +! char_u *ffname = FullName_save(get_tv_string(&argvars[0]), FALSE); + +! if (ffname != NULL) +! rettv->vval.v_string = u_get_undo_file_name(ffname, FALSE); +! vim_free(ffname); + } + #else + rettv->vval.v_string = NULL; +--- 18259,18279 ---- + rettv->v_type = VAR_STRING; + #ifdef FEAT_PERSISTENT_UNDO + { +! char_u *fname = get_tv_string(&argvars[0]); + +! if (*fname == NUL) +! { +! /* If there is no file name there will be no undo file. */ +! rettv->vval.v_string = NULL; +! } +! else +! { +! char_u *ffname = FullName_save(fname, FALSE); +! +! if (ffname != NULL) +! rettv->vval.v_string = u_get_undo_file_name(ffname, FALSE); +! vim_free(ffname); +! } + } + #else + rettv->vval.v_string = NULL; +*** ../vim-7.3.511/src/version.c 2012-04-30 17:04:47.000000000 +0200 +--- src/version.c 2012-04-30 17:24:42.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 512, + /**/ + +-- +It is illegal for a driver to be blindfolded while operating a vehicle. + [real standing law in Alabama, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b46620f33f242b93f134336b6207b05a3e706cea Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:23 +0200 Subject: [PATCH 0245/3340] - patchlevel 513 --- 7.3.513 | 129 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 129 insertions(+) create mode 100644 7.3.513 diff --git a/7.3.513 b/7.3.513 new file mode 100644 index 00000000..396969f5 --- /dev/null +++ b/7.3.513 @@ -0,0 +1,129 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.513 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.513 +Problem: Cannot use CTRL-E and CTRL-Y with "r". +Solution: Make CTRL-E and CTRL-Y work like in Insert mode. (Christian + Brabandt) +Files: src/edit.c, src/normal.c, src/proto/edit.pro + + +*** ../vim-7.3.512/src/edit.c 2012-04-05 16:07:01.000000000 +0200 +--- src/edit.c 2012-04-30 17:53:47.000000000 +0200 +*************** +*** 253,259 **** + #ifdef FEAT_DIGRAPHS + static int ins_digraph __ARGS((void)); + #endif +- static int ins_copychar __ARGS((linenr_T lnum)); + static int ins_ctrl_ey __ARGS((int tc)); + #ifdef FEAT_SMARTINDENT + static void ins_try_si __ARGS((int c)); +--- 253,258 ---- +*************** +*** 9899,9905 **** + * Handle CTRL-E and CTRL-Y in Insert mode: copy char from other line. + * Returns the char to be inserted, or NUL if none found. + */ +! static int + ins_copychar(lnum) + linenr_T lnum; + { +--- 9898,9904 ---- + * Handle CTRL-E and CTRL-Y in Insert mode: copy char from other line. + * Returns the char to be inserted, or NUL if none found. + */ +! int + ins_copychar(lnum) + linenr_T lnum; + { +*** ../vim-7.3.512/src/normal.c 2012-03-28 12:59:53.000000000 +0200 +--- src/normal.c 2012-04-30 18:06:13.000000000 +0200 +*************** +*** 7070,7076 **** + for (n = cap->count1; n > 0; --n) + { + State = REPLACE; +! ins_char(cap->nchar); + State = old_State; + if (cap->ncharC1 != 0) + ins_char(cap->ncharC1); +--- 7070,7087 ---- + for (n = cap->count1; n > 0; --n) + { + State = REPLACE; +! if (cap->nchar == Ctrl_E || cap->nchar == Ctrl_Y) +! { +! int c = ins_copychar(curwin->w_cursor.lnum +! + (cap->nchar == Ctrl_Y ? -1 : 1)); +! if (c != NUL) +! ins_char(c); +! else +! /* will be decremented further down */ +! ++curwin->w_cursor.col; +! } +! else +! ins_char(cap->nchar); + State = old_State; + if (cap->ncharC1 != 0) + ins_char(cap->ncharC1); +*************** +*** 7092,7098 **** + * line will be changed. + */ + ptr = ml_get_buf(curbuf, curwin->w_cursor.lnum, TRUE); +! ptr[curwin->w_cursor.col] = cap->nchar; + if (p_sm && msg_silent == 0) + showmatch(cap->nchar); + ++curwin->w_cursor.col; +--- 7103,7117 ---- + * line will be changed. + */ + ptr = ml_get_buf(curbuf, curwin->w_cursor.lnum, TRUE); +! if (cap->nchar == Ctrl_E || cap->nchar == Ctrl_Y) +! { +! int c = ins_copychar(curwin->w_cursor.lnum +! + (cap->nchar == Ctrl_Y ? -1 : 1)); +! if (c != NUL) +! ptr[curwin->w_cursor.col] = c; +! } +! else +! ptr[curwin->w_cursor.col] = cap->nchar; + if (p_sm && msg_silent == 0) + showmatch(cap->nchar); + ++curwin->w_cursor.col; +*** ../vim-7.3.512/src/proto/edit.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/edit.pro 2012-04-30 17:54:41.000000000 +0200 +*************** +*** 39,42 **** +--- 39,43 ---- + int hkmap __ARGS((int c)); + void ins_scroll __ARGS((void)); + void ins_horscroll __ARGS((void)); ++ int ins_copychar __ARGS((linenr_T lnum)); + /* vim: set ft=c : */ +*** ../vim-7.3.512/src/version.c 2012-04-30 17:35:44.000000000 +0200 +--- src/version.c 2012-04-30 18:17:52.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 513, + /**/ + +-- +It is illegal for anyone to try and stop a child from playfully jumping over +puddles of water. + [real standing law in California, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d5fa79fa810864cf735db001032e1d7da7f8b1a8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:23 +0200 Subject: [PATCH 0246/3340] - patchlevel 514 --- 7.3.514 | 232 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 232 insertions(+) create mode 100644 7.3.514 diff --git a/7.3.514 b/7.3.514 new file mode 100644 index 00000000..79620f0e --- /dev/null +++ b/7.3.514 @@ -0,0 +1,232 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.514 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.514 +Problem: No completion for :history command. +Solution: Add the completion and update the docs. Also fix ":behave" + completion. (Dominique Pelle) +Files: runtime/doc/cmdline.txt, runtime/doc/map.txt, src/ex_docmd.c, + src/ex_getln.c, src/vim.h + + +*** ../vim-7.3.513/runtime/doc/cmdline.txt 2010-08-15 21:57:17.000000000 +0200 +--- runtime/doc/cmdline.txt 2012-04-30 18:30:00.000000000 +0200 +*************** +*** 330,341 **** + + :his[tory] [{name}] [{first}][, [{last}]] + List the contents of history {name} which can be: +! c[md] or : command-line history +! s[earch] or / search string history +! e[xpr] or = expression register history +! i[nput] or @ input line history +! d[ebug] or > debug command history +! a[ll] all of the above + {not in Vi} + + If the numbers {first} and/or {last} are given, the respective +--- 330,341 ---- + + :his[tory] [{name}] [{first}][, [{last}]] + List the contents of history {name} which can be: +! c[md] or : command-line history +! s[earch] or / or ? search string history +! e[xpr] or = expression register history +! i[nput] or @ input line history +! d[ebug] or > debug command history +! a[ll] all of the above + {not in Vi} + + If the numbers {first} and/or {last} are given, the respective +*** ../vim-7.3.513/runtime/doc/map.txt 2011-07-20 16:36:35.000000000 +0200 +--- runtime/doc/map.txt 2012-04-30 18:30:00.000000000 +0200 +*************** +*** 1202,1207 **** +--- 1219,1225 ---- + + -complete=augroup autocmd groups + -complete=buffer buffer names ++ -complete=behave :behave suboptions + -complete=color color schemes + -complete=command Ex command (and arguments) + -complete=compiler compilers +*************** +*** 1216,1221 **** +--- 1234,1240 ---- + -complete=function function name + -complete=help help subjects + -complete=highlight highlight groups ++ -complete=history :history suboptions + -complete=locale locale names (as output of locale -a) + -complete=mapping mapping name + -complete=menu menus +*** ../vim-7.3.513/src/ex_docmd.c 2012-02-12 20:13:55.000000000 +0100 +--- src/ex_docmd.c 2012-04-30 18:33:27.000000000 +0200 +*************** +*** 3920,3927 **** +--- 3920,3935 ---- + #endif + case CMD_behave: + xp->xp_context = EXPAND_BEHAVE; ++ xp->xp_pattern = arg; + break; + ++ #if defined(FEAT_CMDHIST) ++ case CMD_history: ++ xp->xp_context = EXPAND_HISTORY; ++ xp->xp_pattern = arg; ++ break; ++ #endif ++ + #endif /* FEAT_CMDL_COMPL */ + + default: +*************** +*** 5329,5334 **** +--- 5337,5343 ---- + } command_complete[] = + { + {EXPAND_AUGROUP, "augroup"}, ++ {EXPAND_BEHAVE, "behave"}, + {EXPAND_BUFFERS, "buffer"}, + {EXPAND_COLORS, "color"}, + {EXPAND_COMMANDS, "command"}, +*************** +*** 5350,5357 **** + {EXPAND_FUNCTIONS, "function"}, + {EXPAND_HELP, "help"}, + {EXPAND_HIGHLIGHT, "highlight"}, + #if (defined(HAVE_LOCALE_H) || defined(X_LOCALE)) \ +! && (defined(FEAT_GETTEXT) || defined(FEAT_MBYTE)) + {EXPAND_LOCALES, "locale"}, + #endif + {EXPAND_MAPPINGS, "mapping"}, +--- 5359,5369 ---- + {EXPAND_FUNCTIONS, "function"}, + {EXPAND_HELP, "help"}, + {EXPAND_HIGHLIGHT, "highlight"}, ++ #if defined(FEAT_CMDHIST) ++ {EXPAND_HISTORY, "history"}, ++ #endif + #if (defined(HAVE_LOCALE_H) || defined(X_LOCALE)) \ +! && (defined(FEAT_GETTEXT) || defined(FEAT_MBYTE)) + {EXPAND_LOCALES, "locale"}, + #endif + {EXPAND_MAPPINGS, "mapping"}, +*** ../vim-7.3.513/src/ex_getln.c 2012-03-07 19:16:49.000000000 +0100 +--- src/ex_getln.c 2012-04-30 18:36:04.000000000 +0200 +*************** +*** 25,31 **** + int cmdlen; /* number of chars in command line */ + int cmdpos; /* current cursor position */ + int cmdspos; /* cursor column on screen */ +! int cmdfirstc; /* ':', '/', '?', '=' or NUL */ + int cmdindent; /* number of spaces before cmdline */ + char_u *cmdprompt; /* message in front of cmdline */ + int cmdattr; /* attributes for prompt */ +--- 25,31 ---- + int cmdlen; /* number of chars in command line */ + int cmdpos; /* current cursor position */ + int cmdspos; /* cursor column on screen */ +! int cmdfirstc; /* ':', '/', '?', '=', '>' or NUL */ + int cmdindent; /* number of spaces before cmdline */ + char_u *cmdprompt; /* message in front of cmdline */ + int cmdattr; /* attributes for prompt */ +*************** +*** 111,116 **** +--- 111,119 ---- + #ifdef FEAT_CMDL_COMPL + static int expand_shellcmd __ARGS((char_u *filepat, int *num_file, char_u ***file, int flagsarg)); + static int ExpandRTDir __ARGS((char_u *pat, int *num_file, char_u ***file, char *dirname[])); ++ # ifdef FEAT_CMDHIST ++ static char_u *get_history_arg __ARGS((expand_T *xp, int idx)); ++ # endif + # if defined(FEAT_USR_CMDS) && defined(FEAT_EVAL) + static int ExpandUserDefined __ARGS((expand_T *xp, regmatch_T *regmatch, int *num_file, char_u ***file)); + static int ExpandUserList __ARGS((expand_T *xp, int *num_file, char_u ***file)); +*************** +*** 4628,4633 **** +--- 4631,4639 ---- + { + {EXPAND_COMMANDS, get_command_name, FALSE, TRUE}, + {EXPAND_BEHAVE, get_behave_arg, TRUE, TRUE}, ++ #ifdef FEAT_CMDHIST ++ {EXPAND_HISTORY, get_history_arg, TRUE, TRUE}, ++ #endif + #ifdef FEAT_USR_CMDS + {EXPAND_USER_COMMANDS, get_user_commands, FALSE, TRUE}, + {EXPAND_USER_CMD_FLAGS, get_user_cmd_flags, FALSE, TRUE}, +*************** +*** 5245,5250 **** +--- 5251,5284 ---- + NULL + }; + ++ #if defined(FEAT_CMDL_COMPL) || defined(PROTO) ++ /* ++ * Function given to ExpandGeneric() to obtain the possible first ++ * arguments of the ":history command. ++ */ ++ static char_u * ++ get_history_arg(xp, idx) ++ expand_T *xp UNUSED; ++ int idx; ++ { ++ static char_u compl[2] = { NUL, NUL }; ++ char *short_names = ":=@>?/"; ++ int short_names_count = STRLEN(short_names); ++ int history_name_count = sizeof(history_names) / sizeof(char *) - 1; ++ ++ if (idx < short_names_count) ++ { ++ compl[0] = (char_u)short_names[idx]; ++ return compl; ++ } ++ if (idx < short_names_count + history_name_count) ++ return (char_u *)history_names[idx - short_names_count]; ++ if (idx == short_names_count + history_name_count) ++ return (char_u *)"all"; ++ return NULL; ++ } ++ #endif ++ + /* + * init_history() - Initialize the command line history. + * Also used to re-allocate the history when the size changes. +*** ../vim-7.3.513/src/vim.h 2012-03-23 16:25:13.000000000 +0100 +--- src/vim.h 2012-04-30 18:30:00.000000000 +0200 +*************** +*** 781,786 **** +--- 781,787 ---- + #define EXPAND_FILES_IN_PATH 38 + #define EXPAND_OWNSYNTAX 39 + #define EXPAND_LOCALES 40 ++ #define EXPAND_HISTORY 41 + + /* Values for exmode_active (0 is no exmode) */ + #define EXMODE_NORMAL 1 +*** ../vim-7.3.513/src/version.c 2012-04-30 18:18:43.000000000 +0200 +--- src/version.c 2012-04-30 18:36:19.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 514, + /**/ + +-- +You can be stopped by the police for biking over 65 miles per hour. +You are not allowed to walk across a street on your hands. + [real standing laws in Connecticut, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4e2007dd61b5ec2f6f9c8e4ab1b9037bf3674f87 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:24 +0200 Subject: [PATCH 0247/3340] - patchlevel 515 --- 7.3.515 | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 7.3.515 diff --git a/7.3.515 b/7.3.515 new file mode 100644 index 00000000..dad6f617 --- /dev/null +++ b/7.3.515 @@ -0,0 +1,68 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.515 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.515 +Problem: 'wildignorecase' only applies to the last part of the path. +Solution: Also ignore case for letters earlier in the path. +Files: src/misc1.c + + +*** ../vim-7.3.514/src/misc1.c 2012-04-09 20:42:20.000000000 +0200 +--- src/misc1.c 2012-04-30 21:00:18.000000000 +0200 +*************** +*** 9461,9466 **** +--- 9461,9467 ---- + + /* + * Find the first part in the path name that contains a wildcard. ++ * When EW_ICASE is set every letter is considered to be a wildcard. + * Copy it into "buf", including the preceding characters. + */ + p = buf; +*************** +*** 9480,9486 **** + s = p + 1; + } + else if (path_end >= path + wildoff +! && vim_strchr((char_u *)"*?[{~$", *path_end) != NULL) + e = p; + #ifdef FEAT_MBYTE + if (has_mbyte) +--- 9481,9492 ---- + s = p + 1; + } + else if (path_end >= path + wildoff +! && (vim_strchr((char_u *)"*?[{~$", *path_end) != NULL +! #ifndef CASE_INSENSITIVE_FILENAME +! || ((flags & EW_ICASE) +! && isalpha(PTR2CHAR(path_end))) +! #endif +! )) + e = p; + #ifdef FEAT_MBYTE + if (has_mbyte) +*** ../vim-7.3.514/src/version.c 2012-04-30 18:48:38.000000000 +0200 +--- src/version.c 2012-04-30 21:05:10.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 515, + /**/ + +-- +If an elephant is left tied to a parking meter, the parking fee has to be paid +just as it would for a vehicle. + [real standing law in Florida, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e5d40b724531d528d86bb93716956a63ad22bcb0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 16:57:25 +0200 Subject: [PATCH 0248/3340] - patchlevel 515 --- README.patches | 46 ++++++++++++++++++++++++- vim.spec | 93 +++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 137 insertions(+), 2 deletions(-) diff --git a/README.patches b/README.patches index d42ea558..e0e5ed70 100644 --- a/README.patches +++ b/README.patches @@ -366,7 +366,7 @@ Individual patches for Vim 7.3: 7688 7.3.333 "." repeats a Visual delete by byte size instead of characters 1710 7.3.334 latest MingW complains about XSUBPP referencing itself 1532 7.3.335 changing 'imdisable' in Insert mode takes effect only later - 30504 7.3.336 encoding in tags file causes trouble + 30156 7.3.336 encoding in tags file causes trouble (NOW IN LATIN1) 1876 7.3.337 no screen update after resizing xterm until character typed 2851 7.3.338 using getchar() in an expression mapping doesn't work well 1762 7.3.339 "make shadow" doesn't link all test files @@ -502,3 +502,47 @@ Individual patches for Vim 7.3: 1557 7.3.469 compiler warning for unused argument 1892 7.3.470 test 62 fails when compiled without GUI and X11 2817 7.3.471 can't abort listing placed signs + 2792 7.3.472 crash when using ":redraw" in a BufEnter autocmd + 2119 7.3.473 'cursorbind' does not work correctly with 'virtualedit' "all" + 1682 7.3.474 gcc 4 build with Perl fails + 3670 7.3.475 in terminal with few colors omnicomplete menu is hard to see + 1874 7.3.476 backspacing in a Visual block selection causes problems. + 1725 7.3.477 scrolling back at the more prompt shows the wrong text + 1354 7.3.478 memory leak when the ':rv!' command reads a dict or list + 6622 7.3.479 'cursorline' line number highlighting can't be set separately + 6208 7.3.480 when using ":qa" priority of changed buffers could be better + 1945 7.3.481 changing 'virtualedit' in an operator function does not work + 1827 7.3.482 with 'cursorbind' set moving up/down does not keep the column + 3003 7.3.483 (after 7.3.477) more prompt shows up too ofte. + 2206 7.3.484 "vim --help" does not mention -E and --echo-wid + 1677 7.3.485 LDFLAGS isn't passed on to building xxd + 1803 7.3.486 build error with mingw64 on Windows 7 + 19665 7.3.487 column position is reset unnecessarily when setting an option + 1458 7.3.488 ":help!" in a help file does not work as documented + 2783 7.3.489 Insert mode CTRL-] does not expand abbr. from a mapping + 74085 7.3.490 Lua interface: Member confusion, missing luaeval() + 7738 7.3.491 no tests for Lua + 14093 7.3.492 can't indent conditions separately from function arguments + 1565 7.3.493 (after 7.3.492) two unused variables + 6811 7.3.494 (after 7.3.491) can't build with Lua 9.1 or dynamic Lua + 3559 7.3.495 (after 7.3.492) compiler warnings + 2262 7.3.496 MS-DOS: tests fail when "diff" trips over line separators + 1606 7.3.497 crash when doing ":python print", compiled with gcc -O2 + 2021 7.3.498 the behavior of "- register changes depending on 'clipboard' + 2561 7.3.499 may wait for the wrong child process to terminate + 1414 7.3.500 Ming makefile unconditionally sets WINVER + 1761 7.3.501 error for "flush" not being defined when using Ruby command + 2010 7.3.502 Netbeans insert halfway a line actually appends to the line + 1288 7.3.503 (after 7.3.501) warning for unused argument + 2602 7.3.504 commands in help files are not highlighted + 3376 7.3.505 test 11 fails on MS-Windows in some versions + 3040 7.3.506 GTK gives an error when selecting a non-existent file + 5241 7.3.507 overwriting existing file without question from file dialog + 2838 7.3.508 default for v:register is not set + 8621 7.3.509 'autochdir' causes :vimgrep to fail + 1462 7.3.510 test 77 fails on Solaris 7 + 1563 7.3.511 crash when using FileReadCmd autocmd that does :e {file} + 2049 7.3.512 undofile() returns a useless name when passed an empty string + 3925 7.3.513 cannot use CTRL-E and CTRL-Y with "r" + 7792 7.3.514 no completion for :history command + 2073 7.3.515 'wildignorecase' only applies to the last part of the path diff --git a/vim.spec b/vim.spec index 2a10394b..bcef8b9c 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 471 +%define patchlevel 515 Summary: The VIM editor URL: http://www.vim.org/ @@ -527,6 +527,50 @@ Patch468: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.468 Patch469: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.469 Patch470: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.470 Patch471: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.471 +Patch472: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.472 +Patch473: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.473 +Patch474: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.474 +Patch475: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.475 +Patch476: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.476 +Patch477: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.477 +Patch478: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.478 +Patch479: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.479 +Patch480: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.480 +Patch481: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.481 +Patch482: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.482 +Patch483: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.483 +Patch484: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.484 +Patch485: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.485 +Patch486: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.486 +Patch487: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.487 +Patch488: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.488 +Patch489: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.489 +Patch490: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.490 +Patch491: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.491 +Patch492: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.492 +Patch493: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.493 +Patch494: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.494 +Patch495: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.495 +Patch496: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.496 +Patch497: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.497 +Patch498: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.498 +Patch499: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.499 +Patch500: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.500 +Patch501: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.501 +Patch502: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.502 +Patch503: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.503 +Patch504: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.504 +Patch505: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.505 +Patch506: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.506 +Patch507: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.507 +Patch508: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.508 +Patch509: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.509 +Patch510: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.510 +Patch511: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.511 +Patch512: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.512 +Patch513: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.513 +Patch514: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.514 +Patch515: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.515 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1143,6 +1187,50 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch469 -p0 %patch470 -p0 %patch471 -p0 +%patch472 -p0 +%patch473 -p0 +%patch474 -p0 +%patch475 -p0 +%patch476 -p0 +%patch477 -p0 +%patch478 -p0 +%patch479 -p0 +%patch480 -p0 +%patch481 -p0 +%patch482 -p0 +%patch483 -p0 +%patch484 -p0 +%patch485 -p0 +%patch486 -p0 +%patch487 -p0 +%patch488 -p0 +%patch489 -p0 +%patch490 -p0 +%patch491 -p0 +%patch492 -p0 +%patch493 -p0 +%patch494 -p0 +%patch495 -p0 +%patch496 -p0 +%patch497 -p0 +%patch498 -p0 +%patch499 -p0 +%patch500 -p0 +%patch501 -p0 +%patch502 -p0 +%patch503 -p0 +%patch504 -p0 +%patch505 -p0 +%patch506 -p0 +%patch507 -p0 +%patch508 -p0 +%patch509 -p0 +%patch510 -p0 +%patch511 -p0 +%patch512 -p0 +%patch513 -p0 +%patch514 -p0 +%patch515 -p0 # install spell files @@ -1597,6 +1685,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Tue May 08 2012 Karsten Hopp 7.3.515-1 +- patchlevel 515 + * Fri Mar 16 2012 Karsten Hopp 7.3.471-1 - patchlevel 471 From a02e7b91807b769f8cad60cd0c914d152d30716a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 17:27:49 +0200 Subject: [PATCH 0249/3340] include README.patches --- vim.spec | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/vim.spec b/vim.spec index bcef8b9c..86fe4d6a 100644 --- a/vim.spec +++ b/vim.spec @@ -30,7 +30,7 @@ Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 Source3: gvim.desktop Source4: vimrc -#Source5: ftp://ftp.vim.org/pub/vim/patches/README.patches +Source5: ftp://ftp.vim.org/pub/vim/patches/README.patches Source7: gvim16.png Source8: gvim32.png Source9: gvim48.png @@ -1251,6 +1251,7 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch3011 -p1 %build +cp -f %{SOURCE5} . cd src autoconf @@ -1504,7 +1505,7 @@ rm -rf $RPM_BUILD_ROOT %files common %defattr(-,root,root) %config(noreplace) %{_sysconfdir}/vimrc -%doc README* LICENSE +%doc README* LICENSE %doc runtime/docs %doc Changelog.rpm %dir %{_datadir}/%{name} From 79b71d4e37e59a8f617099a753262ec3d7e27372 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 8 May 2012 17:33:30 +0200 Subject: [PATCH 0250/3340] trim Changelog.rpm, move older changelog entries over --- Changelog.rpm | 494 +++++++++++++++----------------------------------- vim.spec | 209 --------------------- 2 files changed, 144 insertions(+), 559 deletions(-) diff --git a/Changelog.rpm b/Changelog.rpm index b49d6ddf..4843d03e 100644 --- a/Changelog.rpm +++ b/Changelog.rpm @@ -1,415 +1,209 @@ -* Fri Jul 04 2008 Karsten Hopp 7.1.330-2 -- new rpm doesn't like zero filled, 3 digit patch numbers +* Tue Jul 27 2010 Mamoru Tasaka 7.2.446-2 +- Rebuild against python 2.7 -* Fri Jul 04 2008 Karsten Hopp 7.1.330-1 -- patchlevel 330 +* Tue Jul 13 2010 Karsten Hopp 7.2.446-1 +- patchlevel 446 -* Wed Jun 04 2008 Karsten Hopp 7.1.309-1 -- Patchlevel 309 +* Thu Jul 08 2010 Karsten Hopp 7.2.445-1 +- patchlevel 445 -* Wed Jun 04 2008 Karsten Hopp 7.1.306-1 -- patchlevel 306, fixes some unicode characters +* Wed Jun 23 2010 Karsten Hopp 7.2.444-2 +- rebuild with perl-5.12 -* Tue Jun 03 2008 Karsten Hopp 7.1.305-1 -- patchlevel 305 -- put /etc/vimrc autocmd's into fedora augroup (similar to #241308) +* Sun Jun 13 2010 Karsten Hopp 7.2.444-1 +- patchlevel 444 -* Thu May 15 2008 Karsten Hopp 7.1.298-1 -- patchlevel 298 +* Sun Jun 13 2010 Karsten Hopp 7.2.443-1 +- patchlevel 443 -* Fri Apr 11 2008 Karsten Hopp 7.1.293-1 -- patchlevel 293 -- update forth syntax file (Benjamin Krill) +* Sat Jun 05 2010 Karsten Hopp 7.2.442-1 +- patchlevel 442 -* Wed Apr 02 2008 Karsten Hopp 7.1.291-1 -- patchlevel 291, more fixes for leftover /tmp/cscope* files +* Wed Jun 02 2010 Marcela Maslanova - 2:7.2.441-2 +- Mass rebuild with perl-5.12.0 -* Tue Mar 18 2008 Tom "spot" Callaway 7.1.283-2 -- add Requires for versioned perl (libperl.so) +* Sun May 30 2010 Karsten Hopp 7.2.441-1 +- patchlevel 441 -* Mon Mar 17 2008 Karsten Hopp 7.1.283-1 -- patchlevel 283, fixes leftover cscope files in /tmp +* Sat May 29 2010 Karsten Hopp 7.2.440-1 +- patchlevel 440 -* Wed Mar 12 2008 Karsten Hopp 7.1.273-1 -- update to patchlevel 273, this fixes #436902 +* Wed May 26 2010 Karsten Hopp 7.2.438-1 +- patchlevel 438 -* Tue Mar 11 2008 Karsten Hopp 7.1.270-1 -- patchlevel 270 -- don't write swapfile on most common locations for USB-sticks (#436752) -- add spec file template +* Sat May 22 2010 Karsten Hopp 7.2.437-1 +- patchlevel 437 -* Mon Mar 10 2008 Tom "spot" Callaway 7.1.269-2 -- BR: ExtUtils::Embed to find perl headers +* Sun May 16 2010 Karsten Hopp 7.2.436-1 +- patchlevel 436 -* Mon Mar 10 2008 Karsten Hopp 7.1.269-1 -- patchlevel 269 -- rebuild with new perl (#436731) +* Sat May 15 2010 Karsten Hopp 7.2.433-1 +- patchlevel 433 -* Mon Mar 03 2008 Karsten Hopp 7.1.266-1 -- patchlevel 266 -- add minimal help page for /bin/vi (#173974) +* Fri May 14 2010 Karsten Hopp 7.2.427-1 +- patchlevel 427 -* Mon Feb 25 2008 Karsten Hopp 7.1.262-1 -- patchlevel 262 -- add fix for #231124, BOM was ignored -- enable ruby interpreter (#215207) -- add filetype for Erlang header files (#417371) +* Thu May 13 2010 Karsten Hopp 7.2.422-1 +- patchlevel 422 -* Mon Feb 11 2008 Karsten Hopp 7.1.245-1 -- patchlevel 245 +* Fri May 07 2010 Karsten Hopp 7.2.416-1 +- patchlevel 416 -* Sun Jan 27 2008 Karsten Hopp 7.1.242-1 -- patchlevel 242 +* Tue Apr 20 2010 Karsten Hopp 7.2.411-2 +- fix rvim manpage (#583180) -* Fri Jan 18 2008 Karsten Hopp 7.1.233-2 -- silence taglist plugin (#429200) +* Wed Mar 24 2010 Karsten Hopp 7.2.411-1 +- patchlevel 411 -* Fri Jan 18 2008 Karsten Hopp 7.1.233-1 -- patchlevel 233 -- fix ada patch +* Tue Mar 23 2010 Karsten Hopp 7.2.410-1 +- patchlevel 410 -* Wed Jan 16 2008 Karsten Hopp 7.1.230-2 -- add newer ada runtime files to fix bugzilla #246378 +* Sat Mar 20 2010 Karsten Hopp 7.2.403-1 +- patchlevel 403 -* Wed Jan 16 2008 Karsten Hopp 7.1.230-1 -- patchlevel 230, fixes memory leak +* Thu Mar 18 2010 Karsten Hopp 7.2.402-1 +- patchlevel 402 -* Mon Jan 14 2008 Karsten Hopp 7.1.228-1 -- patchlevel 228 -- allow overwriting WITH_SELING at build time (#427710) +* Wed Mar 17 2010 Karsten Hopp 7.2.399-1 +- patchlevel 399 -* Thu Jan 10 2008 Karsten Hopp 7.1.214-1 -- patchlevel 214 +* Wed Mar 10 2010 Karsten Hopp 7.2.394-1 +- patchlevel 394 -* Mon Jan 07 2008 Karsten Hopp 7.1.211-1 -- patchlevel 211 +* Wed Mar 03 2010 Karsten Hopp 7.2.385-1 +- patchlevel 385 -* Sat Dec 22 2007 Karsten Hopp 7.1.175-1 -- patchlevel 175 +* Tue Mar 02 2010 Karsten Hopp 7.2.384-1 +- patchlevel 384 -* Thu Nov 22 2007 Karsten Hopp 7.1.159-1 -- patchlevel 159 -- vim-enhanced requires which for vimtutor (#395371) +* Tue Mar 02 2010 Karsten Hopp 7.2.381-1 +- patchlevel 381 -* Thu Oct 04 2007 Karsten Hopp 7.1.135-1 -- patchlevel 135 +* Sat Feb 27 2010 Karsten Hopp 7.2.377-1 +- patchlevel 377 -* Wed Sep 26 2007 Karsten Hopp 7.1.122-1 -- patchlevel 122 +* Wed Feb 24 2010 Karsten Hopp 7.2.376-1 +- patchlevel 376 -* Tue Sep 25 2007 Karsten Hopp 7.1.119-1 -- patchlevel 119 +* Thu Feb 18 2010 Karsten Hopp 7.2.368-1 +- patchlevel 368 -* Mon Sep 24 2007 Karsten Hopp 7.1.116-1 -- patchlevel 116 +* Thu Feb 18 2010 Karsten Hopp 7.2.367-1 +- patchlevel 367 -* Fri Sep 07 2007 Karsten Hopp 7.1.100-1 -- patchlevel 100 +* Wed Feb 17 2010 Karsten Hopp 7.2.365-1 +- patchlevel 365 -* Fri Aug 24 2007 Karsten Hopp 7.1.87-1 -- add build requirement perl-devel -- fix tarball unpacking -- patchlevel 87 +* Fri Feb 12 2010 Karsten Hopp 7.2.359-1 +- patchlevel 359 -* Wed Aug 15 2007 Karsten Hopp 7.1.77-1 -- patchlevel 77 +* Thu Feb 11 2010 Karsten Hopp 7.2.357-1 +- patchlevel 357 -* Mon Aug 13 2007 Karsten Hopp 7.1.68-1 -- patchlevel 68 +* Thu Feb 04 2010 Karsten Hopp 7.2.356-1 +- patchlevel 356 -* Thu Aug 02 2007 Karsten Hopp 7.1.47-1 -- patchlevel 47 +* Wed Feb 03 2010 Karsten Hopp 7.2.354-1 +- patchlevel 354 -* Wed Jul 11 2007 Karsten Hopp 7.1.28-1 -- patchlevel 28 +* Fri Jan 29 2010 Karsten Hopp 7.2.351-1 +- patchlevel 351 -* Wed Jun 27 2007 Karsten Hopp 7.1.12-1 -- Patchlevel 12 +* Thu Jan 28 2010 Karsten Hopp 7.2.350-1 +- patchlevel 350 -* Mon Jun 04 2007 Karsten Hopp 7.1.2-1 -- vim 7.1 -- drop 240 patches +* Mon Dec 7 2009 Stepan Kasal - 2:7.2.315-2 +- rebuild against perl 5.10.1 -* Tue May 22 2007 Karsten Hopp 7.0.235-1 -- Don't wake up system with blinking gvim cursor: - http://www.linuxpowertop.org/known.php +* Wed Dec 03 2009 Karsten Hopp 7.2.315-1 +- patchlevel 315 +- fix vimrc location in man page (#456992) +- correct syntax highlighting of httpd config files in /etc/httpd (#499123) +- Buildrequire ruby, ruby-devel (#503872) +- Remove check for static gravity (#510307) +- sort tags file (#517725) +- use one gvim to open multiple file selections from nautilus (#519265) +- use elinks -source instead of elinks -dump (#518791) +- add ext4 keyword to /etc/fstab syntax highlighting (#498290) -* Mon Apr 30 2007 Karsten Hopp 7.0.235-1 -- update to patchlevel 235, fixes modeline issues +* Mon Nov 09 2009 Karsten Hopp 7.2.284-1 +- patchlevel 284 -* Tue Apr 17 2007 Karsten Hopp 7.0.224-3 -- fix typo in require line (vim-X11 - 2:7.0.224-2.fc7.i386 requires 4) +* Thu Aug 20 2009 Karsten Hopp 7.2.245-3 +- change range of system ids in /etc/profile.d/vim/* (#518555) -* Mon Apr 16 2007 Karsten Hopp 7.0.224-2 -- use more macros -- drop BR perl -- move license to main doc directory -- set vendor to 'fedora' (desktop-file) -- don't own man directories -- preserve timestamps of non-generated files -- run update-desktop-database +* Mon Aug 03 2009 Karsten Hopp 7.2.245-2 +- add fix for glibc fortify segfault (#514717, Adam Tkac) -* Thu Apr 05 2007 Karsten Hopp 7.0.224-1 -- vim-X11 provides gvim +* Sat Aug 01 2009 Karsten Hopp 7.2.245-1 +- add 97 upstream patches to get to patchlevel 245 -* Fri Mar 30 2007 Karsten Hopp 7.0.224-1 -- patchlevel 224 +* Sun Jul 26 2009 Fedora Release Engineering - 2:7.2.148-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild -* Wed Feb 21 2007 Karsten Hopp 7.0.195-2 -- rpmlint fixes (#226526) +* Fri Mar 27 2009 Karsten Hopp 7.2.148-1 +- patchlevel 148, fixes #461417 -* Tue Feb 13 2007 Karsten Hopp 7.0.195-1 -- patchlevel 195 +* Tue Mar 10 2009 Karsten Hopp 7.2.132-1 +- patchlevel 132, fixes accesses to freed memory -* Mon Feb 12 2007 Karsten Hopp 7.0.192-1 -- patchlevel 192 -- test fix for highlighting problems with curly brackets in #define (#203577) +* Wed Mar 04 2009 Karsten Hopp 7.2.131-1 +- patchlevel 131 -* Tue Feb 06 2007 Karsten Hopp 7.0.191-2 -- uses ncurses instead of ncursesw +* Tue Feb 24 2009 Karsten Hopp 7.2.127-1 +- patchlevel 127 -* Tue Feb 06 2007 Karsten Hopp 7.0.191-1 -- patchlevel 191 -- clean up spec file for rpmlint -- drop cvim stuff +* Mon Feb 23 2009 Karsten Hopp 7.2.124-1 +- patchlevel 124 -* Tue Jan 23 2007 Karsten Hopp 7.0.188-3 -- patchlevel 188 +* Mon Jan 26 2009 Karsten Hopp 7.2.088-1 +- patchlevel 88 -* Mon Jan 08 2007 Karsten Hopp 7.0.178-3 -- enable filetype plugin +* Thu Jan 08 2009 Karsten Hopp 7.2.079-2 +- patchlevel 79 -* Thu Dec 14 2006 Karsten Hopp 7.0.178-2 -- build vim-minimal with features=small instead of tiny (#219605) +* Thu Dec 04 2008 Jesse Keating - 7.2.060-2 +- Rebuild for new python. -* Tue Dec 12 2006 Karsten Hopp 7.0.178-1 -- add vimfiles/after to list of owned directories +* Mon Dec 01 2008 Karsten Hopp 7.2.060-1 +- patchlevel 60 -* Tue Dec 12 2006 Karsten Hopp 7.0.178-1 -- patchlevel 178 -- use macros -- Resolves: #219154 - add directory /usr/share/vim/vimfiles for plugins +* Mon Nov 10 2008 Karsten Hopp 7.2.032-1 +- patchlevel 32 -* Thu Dec 7 2006 Jeremy Katz -- rebuild for python 2.5 +* Mon Nov 03 2008 Karsten Hopp 7.2.026-2 +- add more /usr/share/vim/vimfiles directories (#444387) -* Wed Nov 22 2006 Karsten Hopp 7.0.168-1 -- patchlevel 168 -- link with ncurses +* Mon Nov 03 2008 Karsten Hopp 7.2.026-1 +- patchlevel 26 +- own some directories in /usr/share/vim/vimfiles (#469491) -* Tue Nov 21 2006 Karsten Hopp 7.0.164-2 -- patchlevel 164 +* Tue Oct 21 2008 Karsten Hopp 7.2.025-2 +- re-enable clean -* Mon Nov 13 2006 Karsten Hopp 7.0.162-2 -- fix lang problem in spec file mode -- use old g:packager variable when set +* Mon Oct 20 2008 Karsten Hopp 7.2.025-1 +- patchlevel 25 +- add Categories tag to desktop file (#226526) +- add requirement on hicolor-icon-theme to vim-X11 (#226526) +- drop Amiga info files (#226526) +- remove non-utf8 man pages (#226526) +- drop Application from categories (#226526) -* Fri Nov 10 2006 Karsten Hopp 7.0.162-1 -- patchlevel 162 - -* Mon Nov 06 2006 Karsten Hopp 7.0.158-1 -- patchlevel 158 - -* Tue Oct 17 2006 Karsten Hopp 7.0.139-1 -- patchlevel 139 -- provide vim, vi (#210950) - -* Thu Sep 28 2006 Jeremy Katz - 7.0.109-3 -- disable vim-spell subpackage as it pushes us over CD boundaries - -* Tue Sep 28 2006 Karsten Hopp 7.0.109-2 -- fix typo in vimspell.sh (#203178) - -* Tue Sep 19 2006 Karsten Hopp 7.0.109-1 -- update to patchlevel 109 to fix some redraw problems -- fix invisible comments in diff mode (#204042) - -* Tue Sep 12 2006 Karsten Hopp 7.0.100-1 -- Patchlevel 100 -- replace runtime files with newer ones - -* Mon Sep 11 2006 Karsten Hopp 7.0.099-1 -- Patchlevel 99 - -* Mon Sep 05 2006 Karsten Hopp 7.0.086-1 -- Patchlevel 86 - -* Mon Sep 04 2006 Karsten Hopp 7.0.083-1 -- Patchlevel 83 - -* Wed Aug 30 2006 Karsten Hopp 7.0.076-1 -- Patchlevel 76 - -* Thu Aug 25 2006 Karsten Hopp 7.0.066-2 -- fix vimdiff colors (#204042) - -* Thu Aug 24 2006 Karsten Hopp 7.0.066-1 -- fix syntax patch (#203798) -- patchlevel 66 - -* Wed Aug 17 2006 Karsten Hopp 7.0.063-1 -- Patchlevel 63 - -* Wed Aug 15 2006 Karsten Hopp 7.0.053-1 -- Patchlevel 53 -- Buildrequires libXpm-devel - -* Wed Aug 09 2006 Karsten Hopp 7.0.050-1 -- Patchlevel 50 - -* Thu Aug 03 2006 Karsten Hopp 7.0.042-2 -- clean up spec file - -* Mon Jul 24 2006 Karsten Hopp 7.0.042-1 -- patchlevel 42 - -* Wed Jul 20 2006 Karsten Hopp 7.0.039-1 -- patchlevel 39 -- allow usage of $VIM variable (#199465) - -* Wed Jul 12 2006 Jesse Keating - 2:7.0.035-1.1 -- rebuild - -* Tue Jun 27 2006 Karsten Hopp 7.0.035-1 -- patchlevel 35 - -* Wed Jun 21 2006 Karsten Hopp 7.0.022-2 -- add binfmt_misc rpc_pipefs to fstypes for better mtab highlighting - -* Tue Jun 20 2006 Karsten Hopp 7.0.022-1 +* Tue Sep 30 2008 Karsten Hopp 7.2.022-1 - patchlevel 22 -* Tue Jun 20 2006 Karsten Hopp 7.0.020-1 -- patchlevel 20 +* Mon Sep 08 2008 Karsten Hopp 7.2.013-1 +- patchlevel 13 -* Tue Jun 20 2006 Karsten Hopp 7.0.019-1 -- patchlevel 19 -- buildrequire autoconf +* Mon Aug 25 2008 Karsten Hopp 7.2.006-1 +- patchlevel 6 -* Tue May 30 2006 Karsten Hopp 7.0.017-1 -- patchlevel 17, although it affects just the Motif version -- own some directories (#192787) +* Mon Aug 18 2008 Karsten Hopp 7.2.002-1 +- patchlevel 2 +- fix specfile template (#446070) +- old specfile changelog moved to Changelog.rpm -* Sat May 13 2006 Karsten Hopp 7.0.016-1 -- patchlevel 016 - -* Fri May 12 2006 Karsten Hopp 7.0.012-1 -- patchlevel 012 - -* Thu May 11 2006 Karsten Hopp 7.0.010-1 -- patchlevel 010 - -* Wed May 10 2006 Karsten Hopp 7.0.005-2 -- patchlevel 005 -- move older changelogs (<7.0) into a file, no need to keep them - in the rpm database - -* Tue May 09 2006 Karsten Hopp 7.0.000-2 -- bump epoch, the buildsystem thinks 7.0.000-2 is older than 7.0.g001-1 - although rpm is quite happy with it. - -* Mon May 08 2006 Karsten Hopp 7.0.000-1 -- vim-7.0 -- Spell checking support for about 50 languages -- Intelligent completion for C, HTML, Ruby, Python, PHP, etc. -- Tab pages, each containing multiple windows -- Undo branches: never accidentally lose text again -- Vim script supports Lists and Dictionaries (similar to Python) -- Vim script profiling -- Improved Unicode support -- Highlighting of cursor line, cursor column and matching braces -- Translated manual pages support. -- Internal grep; works on all platforms, searches compressed files -- Browsing remote directories, zip and tar archives -- Printing multi-byte text -- find details about the changes since vim-6.4 with :help version7 - -- fix SE Linux context of temporary (.swp) files (#189968) -- /bin/vi /vim-minimal is now using /etc/virc to avoid .rpmnew files - when updating - -* Tue May 02 2006 Karsten Hopp 7.0.g001-1 -- vim-7.0g BETA - -* Fri Apr 28 2006 Karsten Hopp 7.0.f001-1 -- vim-7.0f3 BETA - -* Thu Apr 20 2006 Karsten Hopp 7.0.e001-1 -- vim-7.0e BETA - -* Tue Apr 11 2006 Karsten Hopp 7.0.d001-1 -- vim-7.0d BETA - -* Fri Apr 07 2006 Karsten Hopp 7.0c.000-3 -- fix vimrc filename - -* Thu Apr 06 2006 Karsten Hopp 7.0c.000-2 -- new snapshot - -* Tue Apr 04 2006 Karsten Hopp 7.0c.000-1 -- vim-7.0c BETA - -* Wed Mar 22 2006 Karsten Hopp 7.0aa.000-3 -- Rawhide build as vim, opposed to vim7 (prerelease) -- conflict with older man-pages-{it,fr} packages -- cleanup lang stuff - -* Thu Mar 16 2006 Karsten Hopp 7.0aa.000-2 -- make it coexist with vim-6 (temporarily) -- new CVS snapshot - -* Tue Mar 14 2006 Karsten Hopp 7.0aa.000-1 -- vim7 pre Release -- older changelogs available in Changelog.rpm -* Thu Mar 09 2006 Karsten Hopp 6.4.007-4 -- fix configure check for python (#184478) - -* Thu Mar 09 2006 Karsten Hopp 6.4.007-3 -- rebuild - -* Mon Feb 20 2006 Karsten Hopp 6.4.007-2 -- gtk-update-icon-cache --ignore-theme-index - (avoids %%post failures when hicolor-icon-theme isn't installed) - -* Wed Feb 15 2006 Karsten Hopp 6.4.007-1 -- fix vim.csh script (#180429) -- patchlevel 7 - -* Fri Feb 10 2006 Jesse Keating - 1:6.4.006-1.2 -- bump again for double-long bug on ppc(64) - -* Tue Feb 07 2006 Jesse Keating - 1:6.4.006-1.1 -- rebuilt for new gcc4.1 snapshot and glibc changes - -* Mon Jan 02 2006 Karsten Hopp 6.4.006-1 -- patchlevel 6, fixes bz# 175048 - -* Tue Dec 20 2005 Karsten Hopp 6.4.004-2 -- disable templates when editing new .c / .h files (#175878) - -* Fri Dec 09 2005 Jesse Keating -- rebuilt - -* Thu Dec 08 2005 Karsten Hopp 6.4.004-1 -- fix fstab syntax file (#174735) -- patchlevel 4 - -* Wed Nov 30 2005 Karsten Hopp 6.4.003-1 -- patchlevel 3 -- remove withgui switch as we include vim-X11 in all our distributions now - (#174271) - -* Fri Nov 25 2005 Karsten Hopp 6.4.000-4 -- enable tmpfile patch - -* Thu Oct 27 2005 Karsten Hopp 6.4.000-3 -- test build - -* Tue Oct 25 2005 Karsten Hopp 6.4.000-2 -- use %%{_sysconfdir} (#171556) -- add syntax highlighting rule for %%check (Ralf Ertzinger, #165277) - -* Mon Oct 17 2005 Karsten Hopp 6.4.000-1 -- vim-6.4 patchlevel 0 +* Fri Aug 14 2008 Karsten Hopp 7.2.000-1 +- vim 7.2 +- drop 330 patches diff --git a/vim.spec b/vim.spec index 86fe4d6a..361b593d 100644 --- a/vim.spec +++ b/vim.spec @@ -1864,213 +1864,4 @@ rm -rf $RPM_BUILD_ROOT * Wed Sep 22 2010 Karsten Hopp 7.3.011-1 - update to VIM 7.3 patchlevel 011 -* Tue Jul 27 2010 Mamoru Tasaka 7.2.446-2 -- Rebuild against python 2.7 - -* Tue Jul 13 2010 Karsten Hopp 7.2.446-1 -- patchlevel 446 - -* Thu Jul 08 2010 Karsten Hopp 7.2.445-1 -- patchlevel 445 - -* Wed Jun 23 2010 Karsten Hopp 7.2.444-2 -- rebuild with perl-5.12 - -* Sun Jun 13 2010 Karsten Hopp 7.2.444-1 -- patchlevel 444 - -* Sun Jun 13 2010 Karsten Hopp 7.2.443-1 -- patchlevel 443 - -* Sat Jun 05 2010 Karsten Hopp 7.2.442-1 -- patchlevel 442 - -* Wed Jun 02 2010 Marcela Maslanova - 2:7.2.441-2 -- Mass rebuild with perl-5.12.0 - -* Sun May 30 2010 Karsten Hopp 7.2.441-1 -- patchlevel 441 - -* Sat May 29 2010 Karsten Hopp 7.2.440-1 -- patchlevel 440 - -* Wed May 26 2010 Karsten Hopp 7.2.438-1 -- patchlevel 438 - -* Sat May 22 2010 Karsten Hopp 7.2.437-1 -- patchlevel 437 - -* Sun May 16 2010 Karsten Hopp 7.2.436-1 -- patchlevel 436 - -* Sat May 15 2010 Karsten Hopp 7.2.433-1 -- patchlevel 433 - -* Fri May 14 2010 Karsten Hopp 7.2.427-1 -- patchlevel 427 - -* Thu May 13 2010 Karsten Hopp 7.2.422-1 -- patchlevel 422 - -* Fri May 07 2010 Karsten Hopp 7.2.416-1 -- patchlevel 416 - -* Tue Apr 20 2010 Karsten Hopp 7.2.411-2 -- fix rvim manpage (#583180) - -* Wed Mar 24 2010 Karsten Hopp 7.2.411-1 -- patchlevel 411 - -* Tue Mar 23 2010 Karsten Hopp 7.2.410-1 -- patchlevel 410 - -* Sat Mar 20 2010 Karsten Hopp 7.2.403-1 -- patchlevel 403 - -* Thu Mar 18 2010 Karsten Hopp 7.2.402-1 -- patchlevel 402 - -* Wed Mar 17 2010 Karsten Hopp 7.2.399-1 -- patchlevel 399 - -* Wed Mar 10 2010 Karsten Hopp 7.2.394-1 -- patchlevel 394 - -* Wed Mar 03 2010 Karsten Hopp 7.2.385-1 -- patchlevel 385 - -* Tue Mar 02 2010 Karsten Hopp 7.2.384-1 -- patchlevel 384 - -* Tue Mar 02 2010 Karsten Hopp 7.2.381-1 -- patchlevel 381 - -* Sat Feb 27 2010 Karsten Hopp 7.2.377-1 -- patchlevel 377 - -* Wed Feb 24 2010 Karsten Hopp 7.2.376-1 -- patchlevel 376 - -* Thu Feb 18 2010 Karsten Hopp 7.2.368-1 -- patchlevel 368 - -* Thu Feb 18 2010 Karsten Hopp 7.2.367-1 -- patchlevel 367 - -* Wed Feb 17 2010 Karsten Hopp 7.2.365-1 -- patchlevel 365 - -* Fri Feb 12 2010 Karsten Hopp 7.2.359-1 -- patchlevel 359 - -* Thu Feb 11 2010 Karsten Hopp 7.2.357-1 -- patchlevel 357 - -* Thu Feb 04 2010 Karsten Hopp 7.2.356-1 -- patchlevel 356 - -* Wed Feb 03 2010 Karsten Hopp 7.2.354-1 -- patchlevel 354 - -* Fri Jan 29 2010 Karsten Hopp 7.2.351-1 -- patchlevel 351 - -* Thu Jan 28 2010 Karsten Hopp 7.2.350-1 -- patchlevel 350 - -* Mon Dec 7 2009 Stepan Kasal - 2:7.2.315-2 -- rebuild against perl 5.10.1 - -* Wed Dec 03 2009 Karsten Hopp 7.2.315-1 -- patchlevel 315 -- fix vimrc location in man page (#456992) -- correct syntax highlighting of httpd config files in /etc/httpd (#499123) -- Buildrequire ruby, ruby-devel (#503872) -- Remove check for static gravity (#510307) -- sort tags file (#517725) -- use one gvim to open multiple file selections from nautilus (#519265) -- use elinks -source instead of elinks -dump (#518791) -- add ext4 keyword to /etc/fstab syntax highlighting (#498290) - -* Mon Nov 09 2009 Karsten Hopp 7.2.284-1 -- patchlevel 284 - -* Thu Aug 20 2009 Karsten Hopp 7.2.245-3 -- change range of system ids in /etc/profile.d/vim/* (#518555) - -* Mon Aug 03 2009 Karsten Hopp 7.2.245-2 -- add fix for glibc fortify segfault (#514717, Adam Tkac) - -* Sat Aug 01 2009 Karsten Hopp 7.2.245-1 -- add 97 upstream patches to get to patchlevel 245 - -* Sun Jul 26 2009 Fedora Release Engineering - 2:7.2.148-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild - -* Fri Mar 27 2009 Karsten Hopp 7.2.148-1 -- patchlevel 148, fixes #461417 - -* Tue Mar 10 2009 Karsten Hopp 7.2.132-1 -- patchlevel 132, fixes accesses to freed memory - -* Wed Mar 04 2009 Karsten Hopp 7.2.131-1 -- patchlevel 131 - -* Tue Feb 24 2009 Karsten Hopp 7.2.127-1 -- patchlevel 127 - -* Mon Feb 23 2009 Karsten Hopp 7.2.124-1 -- patchlevel 124 - -* Mon Jan 26 2009 Karsten Hopp 7.2.088-1 -- patchlevel 88 - -* Thu Jan 08 2009 Karsten Hopp 7.2.079-2 -- patchlevel 79 - -* Thu Dec 04 2008 Jesse Keating - 7.2.060-2 -- Rebuild for new python. - -* Mon Dec 01 2008 Karsten Hopp 7.2.060-1 -- patchlevel 60 - -* Mon Nov 10 2008 Karsten Hopp 7.2.032-1 -- patchlevel 32 - -* Mon Nov 03 2008 Karsten Hopp 7.2.026-2 -- add more /usr/share/vim/vimfiles directories (#444387) - -* Mon Nov 03 2008 Karsten Hopp 7.2.026-1 -- patchlevel 26 -- own some directories in /usr/share/vim/vimfiles (#469491) - -* Tue Oct 21 2008 Karsten Hopp 7.2.025-2 -- re-enable clean - -* Mon Oct 20 2008 Karsten Hopp 7.2.025-1 -- patchlevel 25 -- add Categories tag to desktop file (#226526) -- add requirement on hicolor-icon-theme to vim-X11 (#226526) -- drop Amiga info files (#226526) -- remove non-utf8 man pages (#226526) -- drop Application from categories (#226526) - -* Tue Sep 30 2008 Karsten Hopp 7.2.022-1 -- patchlevel 22 - -* Mon Sep 08 2008 Karsten Hopp 7.2.013-1 -- patchlevel 13 - -* Mon Aug 25 2008 Karsten Hopp 7.2.006-1 -- patchlevel 6 - -* Mon Aug 18 2008 Karsten Hopp 7.2.002-1 -- patchlevel 2 -- fix specfile template (#446070) -- old specfile changelog moved to Changelog.rpm - -* Fri Aug 14 2008 Karsten Hopp 7.2.000-1 -- vim 7.2 -- drop 330 patches - # vim:nrformats-=octal From 85f62ef0433a2aba7b5ad8d88ae9b43d3256ca36 Mon Sep 17 00:00:00 2001 From: Daniel Mach Date: Wed, 9 May 2012 03:27:39 -0400 Subject: [PATCH 0251/3340] Reset content to fedora/f17 --- vim.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vim.spec b/vim.spec index ce4f46d3..361b593d 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1.1%{?dist} +Release: 1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 From b3a9f06c32e874edee740fe45c89d3713796938e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 21 May 2012 11:07:53 +0200 Subject: [PATCH 0252/3340] enable highlighting for older log files (#816848) --- vim-7.3-bug816848.patch | 12 ++++++++++++ vim.spec | 5 +++++ 2 files changed, 17 insertions(+) create mode 100644 vim-7.3-bug816848.patch diff --git a/vim-7.3-bug816848.patch b/vim-7.3-bug816848.patch new file mode 100644 index 00000000..ed8ad7a8 --- /dev/null +++ b/vim-7.3-bug816848.patch @@ -0,0 +1,12 @@ +diff -up vim73/runtime/filetype.vim.816848 vim73/runtime/filetype.vim +--- vim73/runtime/filetype.vim.816848 2012-05-21 11:04:08.184266381 +0200 ++++ vim73/runtime/filetype.vim 2012-05-21 11:05:13.511269886 +0200 +@@ -1098,7 +1098,7 @@ au BufNewFile,BufRead *.mel setf mel + au BufNewFile,BufRead *.hgrc,*hgrc setf cfg + + " Messages +-au BufNewFile,BufRead /var/log/messages,/var/log/messages.*[0-9] setf messages ++au BufNewFile,BufRead */log/{auth,cron,daemon,debug,kern,lpr,mail,messages,news/news,syslog,user}{,.log,.err,.info,.warn,.crit,.notice}{,.[0-9]*,-[0-9]*} setf messages + + " Metafont + au BufNewFile,BufRead *.mf setf mf diff --git a/vim.spec b/vim.spec index 361b593d..c67a0ea2 100644 --- a/vim.spec +++ b/vim.spec @@ -582,6 +582,7 @@ Patch3008: vim-7.0-warning.patch Patch3009: vim-7.0-syncolor.patch Patch3010: vim-7.0-specedit.patch Patch3011: vim72-rh514717.patch +Patch3012: vim-7.3-bug816848.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel ncurses-devel gettext perl-devel @@ -1249,6 +1250,7 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch3009 -p1 %patch3010 -p1 %patch3011 -p1 +%patch3012 -p1 %build cp -f %{SOURCE5} . @@ -1686,6 +1688,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon May 21 2012 Karsten Hopp 7.3.515-1 +- enable highlighting for older log files (#816848) + * Tue May 08 2012 Karsten Hopp 7.3.515-1 - patchlevel 515 From 26be22e1e0fdbaf4f685aaa570aab97ab04a3bf7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 23 May 2012 11:27:29 +0200 Subject: [PATCH 0253/3340] Revert "install everything in /usr" This reverts commit 346844e66f8bebea2b61488d39edd70249b2de11. Conflicts: vim.spec --- vim.spec | 37 +++++++++++++++++++++---------------- 1 file changed, 21 insertions(+), 16 deletions(-) diff --git a/vim.spec b/vim.spec index 361b593d..4619882f 100644 --- a/vim.spec +++ b/vim.spec @@ -599,7 +599,6 @@ Requires: desktop-file-utils BuildRequires: desktop-file-utils >= %{desktop_file_utils_version} %endif Epoch: 2 -Conflicts: filesystem < 3 %description VIM (VIsual editor iMproved) is an updated and improved version of the @@ -639,7 +638,6 @@ many different languages. Summary: A minimal version of the VIM editor Group: Applications/Editors Provides: vi = %{version}-%{release} -Provides: /bin/vi %description minimal VIM (VIsual editor iMproved) is an updated and improved version of the @@ -1333,6 +1331,7 @@ make VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} %{?_smp_mflags} %install rm -rf $RPM_BUILD_ROOT +mkdir -p $RPM_BUILD_ROOT/bin mkdir -p $RPM_BUILD_ROOT/%{_bindir} mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/{after,autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/after/{autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} @@ -1348,12 +1347,12 @@ rm -f README*.info cd src -make install DESTDIR=$RPM_BUILD_ROOT BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} -make installgtutorbin DESTDIR=$RPM_BUILD_ROOT BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} +make install DESTDIR=$RPM_BUILD_ROOT BINDIR=/bin VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} +make installgtutorbin DESTDIR=$RPM_BUILD_ROOT BINDIR=/bin VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} +mv $RPM_BUILD_ROOT/bin/xxd $RPM_BUILD_ROOT/%{_bindir}/xxd +mv $RPM_BUILD_ROOT/bin/gvimtutor $RPM_BUILD_ROOT/%{_bindir}/gvimtutor mkdir -p $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/{16x16,32x32,48x48,64x64}/apps -install -m755 vim $RPM_BUILD_ROOT%{_bindir}/vi -install -m755 enhanced-vim $RPM_BUILD_ROOT%{_bindir}/vim -install -m755 gvim $RPM_BUILD_ROOT%{_bindir}/gvim +install -m755 gvim $RPM_BUILD_ROOT/%{_bindir}/gvim install -p -m644 %{SOURCE7} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/16x16/apps/gvim.png install -p -m644 %{SOURCE8} \ @@ -1362,12 +1361,17 @@ install -p -m644 %{SOURCE9} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/48x48/apps/gvim.png install -p -m644 %{SOURCE10} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/64x64/apps/gvim.png +install -m755 enhanced-vim $RPM_BUILD_ROOT/%{_bindir}/vim ( cd $RPM_BUILD_ROOT - ln -sf vi ./%{_bindir}/rvi - ln -sf vi ./%{_bindir}/rview - ln -sf vi ./%{_bindir}/view - ln -sf vi ./%{_bindir}/ex + mv ./bin/vimtutor ./%{_bindir}/vimtutor + mv ./bin/vim ./bin/vi + rm -f ./bin/rvim + ln -sf vi ./bin/ex + ln -sf vi ./bin/rvi + ln -sf vi ./bin/rview + ln -sf vi ./bin/view + ln -sf vim ./%{_bindir}/ex ln -sf vim ./%{_bindir}/rvim ln -sf vim ./%{_bindir}/vimdiff perl -pi -e "s,$RPM_BUILD_ROOT,," .%{_mandir}/man1/vim.1 .%{_mandir}/man1/vimtutor.1 @@ -1630,17 +1634,18 @@ rm -rf $RPM_BUILD_ROOT %files minimal %defattr(-,root,root) %config(noreplace) %{_sysconfdir}/virc -%{_bindir}/ex -%{_bindir}/vi -%{_bindir}/view -%{_bindir}/rvi -%{_bindir}/rview +/bin/ex +/bin/vi +/bin/view +/bin/rvi +/bin/rview %files enhanced %defattr(-,root,root) %{_bindir}/vim %{_bindir}/rvim %{_bindir}/vimdiff +%{_bindir}/ex %{_bindir}/vimtutor %config(noreplace) %{_sysconfdir}/profile.d/vim.* %{_mandir}/man1/rvim.* From 43cd86e171a2c95f821334c6c1f5852d8d683881 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 23 May 2012 11:29:59 +0200 Subject: [PATCH 0254/3340] add back /bin/vi (bz #822314, #823090, #823021) --- vim.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vim.spec b/vim.spec index 4619882f..61e3b174 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1%{?dist} +Release: 2%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -1691,6 +1691,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Wed May 23 2012 Karsten Hopp 7.3.515-2 +- add back /bin/vi (bz #822314, #823090, #823021) + * Tue May 08 2012 Karsten Hopp 7.3.515-1 - patchlevel 515 From 6155ee4c50639563c2607a60e91bc629d6086e8b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 29 May 2012 11:10:25 +0200 Subject: [PATCH 0255/3340] fix spec template --- spec-template.new | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/spec-template.new b/spec-template.new index da558005..cea6bfcd 100644 --- a/spec-template.new +++ b/spec-template.new @@ -24,8 +24,7 @@ make %{?_smp_mflags} %install -rm -rf $RPM_BUILD_ROOT -make install DESTDIR=$RPM_BUILD_ROOT +make install DESTDIR=%{buildroot} %files From 7b49c6e71d807bd9694644db7a3580f7b341703e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 29 May 2012 11:14:24 +0200 Subject: [PATCH 0256/3340] fix spec template (#825702) --- spec-template.new | 3 +-- vim.spec | 5 ++++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/spec-template.new b/spec-template.new index da558005..cea6bfcd 100644 --- a/spec-template.new +++ b/spec-template.new @@ -24,8 +24,7 @@ make %{?_smp_mflags} %install -rm -rf $RPM_BUILD_ROOT -make install DESTDIR=$RPM_BUILD_ROOT +make install DESTDIR=%{buildroot} %files diff --git a/vim.spec b/vim.spec index c67a0ea2..7ecd3288 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1%{?dist} +Release: 2%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -1688,6 +1688,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Tue May 29 2012 Karsten Hopp 7.3.515-2 +- fix spec template + * Mon May 21 2012 Karsten Hopp 7.3.515-1 - enable highlighting for older log files (#816848) From 036c5ecdca9bc99c5d71df82a3fbb45c31a01334 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= Date: Mon, 11 Jun 2012 10:11:47 +0200 Subject: [PATCH 0257/3340] Perl 5.16 rebuild --- vim.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vim.spec b/vim.spec index c67a0ea2..f3223777 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1%{?dist} +Release: 2%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -1688,6 +1688,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Jun 11 2012 Petr Pisar - 2:7.3.515-2 +- Perl 5.16 rebuild + * Mon May 21 2012 Karsten Hopp 7.3.515-1 - enable highlighting for older log files (#816848) From c1700bb921ccb903f98fecb2edc232aa843e5d78 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:50 +0200 Subject: [PATCH 0258/3340] - patchlevel 516 --- 7.3.516 | 94 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 94 insertions(+) create mode 100644 7.3.516 diff --git a/7.3.516 b/7.3.516 new file mode 100644 index 00000000..d43be5a0 --- /dev/null +++ b/7.3.516 @@ -0,0 +1,94 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.516 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.516 +Problem: extend(o, o) may crash Vim. +Solution: Fix crash and add test. (Thinca and Hirohito Higashi) +Files: src/eval.c, src/testdir/test55.in, src/testdir/test55.ok + + +*** ../vim-7.3.515/src/eval.c 2012-04-30 17:35:44.000000000 +0200 +--- src/eval.c 2012-05-18 12:02:44.000000000 +0200 +*************** +*** 10191,10197 **** + EMSG2(_("E737: Key already exists: %s"), hi2->hi_key); + break; + } +! else if (*action == 'f') + { + clear_tv(&di1->di_tv); + copy_tv(&HI2DI(hi2)->di_tv, &di1->di_tv); +--- 10191,10197 ---- + EMSG2(_("E737: Key already exists: %s"), hi2->hi_key); + break; + } +! else if (*action == 'f' && HI2DI(hi2) != di1) + { + clear_tv(&di1->di_tv); + copy_tv(&HI2DI(hi2)->di_tv, &di1->di_tv); +*** ../vim-7.3.515/src/testdir/test55.in 2010-11-10 20:31:24.000000000 +0100 +--- src/testdir/test55.in 2012-05-18 11:57:23.000000000 +0200 +*************** +*** 352,357 **** +--- 352,375 ---- + :let dict4copy = deepcopy(dict4) + :$put =(l == lcopy) + :$put =(dict4 == dict4copy) ++ :" ++ :" Pass the same List to extend() ++ :let l = [1, 2, 3, 4, 5] ++ :call extend(l, l) ++ :$put =string(l) ++ :" ++ :" Pass the same Dict to extend() ++ :let d = { 'a': {'b': 'B'}} ++ :call extend(d, d) ++ :$put =string(d) ++ :" ++ :" Pass the same Dict to extend() with "error" ++ :try ++ : call extend(d, d, "error") ++ :catch ++ : $put =v:exception[:15] . v:exception[-1:-1] ++ :endtry ++ :$put =string(d) + :endfun + :" + :call Test(1, 2, [3, 4], {5: 6}) " This may take a while +*** ../vim-7.3.515/src/testdir/test55.ok 2010-11-10 20:31:24.000000000 +0100 +--- src/testdir/test55.ok 2012-05-18 11:57:01.000000000 +0200 +*************** +*** 111,113 **** +--- 111,117 ---- + 0 + 1 + 1 ++ [1, 2, 3, 4, 5, 1, 2, 3, 4, 5] ++ {'a': {'b': 'B'}} ++ Vim(call):E737: a ++ {'a': {'b': 'B'}} +*** ../vim-7.3.515/src/version.c 2012-04-30 21:09:38.000000000 +0200 +--- src/version.c 2012-05-18 12:04:54.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 516, + /**/ + +-- +I used to wonder about the meaning of life. But I looked it +up in the dictionary under "L" and there it was - the meaning +of life. It was less than I expected. - Dogbert + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e16b7f716a57ada0f7c78fe0a64f5df64e48b7e4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:51 +0200 Subject: [PATCH 0259/3340] - patchlevel 517 --- 7.3.517 | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 7.3.517 diff --git a/7.3.517 b/7.3.517 new file mode 100644 index 00000000..343693ba --- /dev/null +++ b/7.3.517 @@ -0,0 +1,60 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.517 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.517 +Problem: Crash when using "vipvv". (Alexandre Provencio) +Solution: Don't let the text length become negative. +Files: src/ops.c + + +*** ../vim-7.3.516/src/ops.c 2012-04-20 13:46:02.000000000 +0200 +--- src/ops.c 2012-05-18 12:28:09.000000000 +0200 +*************** +*** 3042,3047 **** +--- 3042,3049 ---- + } + #endif + } ++ if (endcol == MAXCOL) ++ endcol = (colnr_T)STRLEN(p); + if (startcol > endcol + #ifdef FEAT_VIRTUALEDIT + || is_oneChar +*************** +*** 3050,3057 **** + bd.textlen = 0; + else + { +- if (endcol == MAXCOL) +- endcol = (colnr_T)STRLEN(p); + bd.textlen = endcol - startcol + oap->inclusive; + } + bd.textstart = p + startcol; +--- 3052,3057 ---- +*** ../vim-7.3.516/src/version.c 2012-05-18 12:06:58.000000000 +0200 +--- src/version.c 2012-05-18 12:48:51.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 517, + /**/ + +-- +BODY: I'm not dead! +CART DRIVER: 'Ere. He says he's not dead. +LARGE MAN: Yes he is. +BODY: I'm not! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a468f727c912fdfe77f17fe03d6ebfdb66891d74 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:51 +0200 Subject: [PATCH 0260/3340] - patchlevel 518 --- 7.3.518 | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 7.3.518 diff --git a/7.3.518 b/7.3.518 new file mode 100644 index 00000000..89429f0c --- /dev/null +++ b/7.3.518 @@ -0,0 +1,57 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.518 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.518 +Problem: When 'encoding' is a double-byte encoding ":helptags" may not find + tags correctly. +Solution: Use vim_strbyte() instead of vim_strchr(). (Yasuhiro Matsumoto) +Files: src/ex_cmds.c + + +*** ../vim-7.3.517/src/ex_cmds.c 2012-04-25 17:32:14.000000000 +0200 +--- src/ex_cmds.c 2012-05-18 16:20:20.000000000 +0200 +*************** +*** 6535,6541 **** + p1 = vim_strchr(IObuff, '*'); /* find first '*' */ + while (p1 != NULL) + { +! p2 = vim_strchr(p1 + 1, '*'); /* find second '*' */ + if (p2 != NULL && p2 > p1 + 1) /* skip "*" and "**" */ + { + for (s = p1 + 1; s < p2; ++s) +--- 6535,6544 ---- + p1 = vim_strchr(IObuff, '*'); /* find first '*' */ + while (p1 != NULL) + { +! /* Use vim_strbyte() instead of vim_strchr() so that when +! * 'encoding' is dbcs it still works, don't find '*' in the +! * second byte. */ +! p2 = vim_strbyte(p1 + 1, '*'); /* find second '*' */ + if (p2 != NULL && p2 > p1 + 1) /* skip "*" and "**" */ + { + for (s = p1 + 1; s < p2; ++s) +*** ../vim-7.3.517/src/version.c 2012-05-18 12:49:33.000000000 +0200 +--- src/version.c 2012-05-18 16:23:50.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 518, + /**/ + +-- +If all you have is a hammer, everything looks like a nail. +When your hammer is C++, everything begins to look like a thumb. + -- Steve Hoflich, comp.lang.c++ + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f4c54c86202aad3dc07e26ea4a1d4083604b37ff Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:51 +0200 Subject: [PATCH 0261/3340] - patchlevel 519 --- 7.3.519 | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 7.3.519 diff --git a/7.3.519 b/7.3.519 new file mode 100644 index 00000000..846cea6b --- /dev/null +++ b/7.3.519 @@ -0,0 +1,64 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.519 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.519 +Problem: When completefunction returns it cannot indicate end of completion + mode. +Solution: Recognize completefunction returning -3. (Mtsushita Shougo) +Files: src/edit.c + + +*** ../vim-7.3.518/src/edit.c 2012-04-30 18:18:43.000000000 +0200 +--- src/edit.c 2012-05-18 16:35:06.000000000 +0200 +*************** +*** 5205,5213 **** + } + + /* Return value -2 means the user complete function wants to +! * cancel the complete without an error. */ + if (col == -2) + return FAIL; + + /* + * Reset extended parameters of completion, when start new +--- 5205,5221 ---- + } + + /* Return value -2 means the user complete function wants to +! * cancel the complete without an error. +! * Return value -3 does the same as -2 and leaves CTRL-X mode.*/ + if (col == -2) + return FAIL; ++ if (col == -3) ++ { ++ ctrl_x_mode = 0; ++ edit_submode = NULL; ++ msg_clr_cmdline(); ++ return FAIL; ++ } + + /* + * Reset extended parameters of completion, when start new +*** ../vim-7.3.518/src/version.c 2012-05-18 16:24:06.000000000 +0200 +--- src/version.c 2012-05-18 16:34:27.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 519, + /**/ + +-- +Looking at Perl through Lisp glasses, Perl looks atrocious. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 503829fc58a6047040de5d6df12ea2394253adc2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:52 +0200 Subject: [PATCH 0262/3340] - patchlevel 520 --- 7.3.520 | 140 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 140 insertions(+) create mode 100644 7.3.520 diff --git a/7.3.520 b/7.3.520 new file mode 100644 index 00000000..9e2da8d7 --- /dev/null +++ b/7.3.520 @@ -0,0 +1,140 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.520 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.520 +Problem: Gvim starts up slow on Unbuntu 12.04. +Solution: Move the call to gui_mch_init_check() to after fork(). (Yasuhiro + Matsumoto) Do check $DISPLAY being set. +Files: src/gui.c, src/gui_gtk_x11.c, src/proto/gui_gtk_x11.pro + + +*** ../vim-7.3.519/src/gui.c 2011-10-20 21:27:57.000000000 +0200 +--- src/gui.c 2012-05-18 16:53:14.000000000 +0200 +*************** +*** 270,275 **** +--- 270,281 ---- + } + /* Child */ + ++ #ifdef FEAT_GUI_GTK ++ /* Call gtk_init_check() here after fork(). See gui_init_check(). */ ++ if (gui_mch_init_check() != OK) ++ exit(1); ++ #endif ++ + # if defined(HAVE_SETSID) || defined(HAVE_SETPGID) + /* + * Change our process group. On some systems/shells a CTRL-C in the +*************** +*** 430,436 **** +--- 436,452 ---- + #ifdef ALWAYS_USE_GUI + result = OK; + #else ++ # ifdef FEAT_GUI_GTK ++ /* ++ * Note: Don't call gtk_init_check() before fork, it will be called after ++ * the fork. When calling it before fork, it make vim hang for a while. ++ * See gui_do_fork(). ++ * Use a simpler check if the GUI window can probably be opened. ++ */ ++ result = gui.dofork ? gui_mch_early_init_check() : gui_mch_init_check(); ++ # else + result = gui_mch_init_check(); ++ # endif + #endif + return result; + } +*** ../vim-7.3.519/src/gui_gtk_x11.c 2011-10-26 11:36:21.000000000 +0200 +--- src/gui_gtk_x11.c 2012-05-18 17:00:45.000000000 +0200 +*************** +*** 1414,1420 **** + } + + /* +! * Check if the GUI can be started. Called before gvimrc is sourced. + * Return OK or FAIL. + */ + int +--- 1414,1442 ---- + } + + /* +! * Check if the GUI can be started. Called before gvimrc is sourced and +! * before fork(). +! * Return OK or FAIL. +! */ +! int +! gui_mch_early_init_check(void) +! { +! char_u *p; +! +! /* Guess that when $DISPLAY isn't set the GUI can't start. */ +! p = mch_getenv((char_u *)"DISPLAY"); +! if (p == NULL || *p == NUL) +! { +! gui.dying = TRUE; +! EMSG(_((char *)e_opendisp)); +! return FAIL; +! } +! return OK; +! } +! +! /* +! * Check if the GUI can be started. Called before gvimrc is sourced but after +! * fork(). + * Return OK or FAIL. + */ + int +*************** +*** 3050,3056 **** + + for (i = 0; i < (int)N_SELECTION_TARGETS; ++i) + { +! /* OpenOffice tries to use TARGET_HTML and fails when it doesn't + * return something, instead of trying another target. Therefore only + * offer TARGET_HTML when it works. */ + if (!clip_html && selection_targets[i].info == TARGET_HTML) +--- 3072,3078 ---- + + for (i = 0; i < (int)N_SELECTION_TARGETS; ++i) + { +! /* OpenOffice tries to use TARGET_HTML and fails when we don't + * return something, instead of trying another target. Therefore only + * offer TARGET_HTML when it works. */ + if (!clip_html && selection_targets[i].info == TARGET_HTML) +*** ../vim-7.3.519/src/proto/gui_gtk_x11.pro 2011-08-10 17:44:41.000000000 +0200 +--- src/proto/gui_gtk_x11.pro 2012-05-18 16:54:28.000000000 +0200 +*************** +*** 4,9 **** +--- 4,10 ---- + void gui_mch_set_blinking __ARGS((long waittime, long on, long off)); + void gui_mch_stop_blink __ARGS((void)); + void gui_mch_start_blink __ARGS((void)); ++ int gui_mch_early_init_check __ARGS((void)); + int gui_mch_init_check __ARGS((void)); + void gui_mch_show_tabline __ARGS((int showit)); + int gui_mch_showing_tabline __ARGS((void)); +*** ../vim-7.3.519/src/version.c 2012-05-18 16:35:17.000000000 +0200 +--- src/version.c 2012-05-18 16:45:30.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 520, + /**/ + +-- +Bad programs can be written in any language. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e67740334aca034396ed3d4993078f8fbecb53ea Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:52 +0200 Subject: [PATCH 0263/3340] - patchlevel 521 --- 7.3.521 | 129 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 129 insertions(+) create mode 100644 7.3.521 diff --git a/7.3.521 b/7.3.521 new file mode 100644 index 00000000..efe7122b --- /dev/null +++ b/7.3.521 @@ -0,0 +1,129 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.521 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.521 +Problem: Using "z=" on a multi-byte character may cause a crash. +Solution: Don't use strlen() on an int pointer. +Files: src/spell.c + + +*** ../vim-7.3.520/src/spell.c 2012-01-10 22:26:12.000000000 +0100 +--- src/spell.c 2012-05-18 18:01:58.000000000 +0200 +*************** +*** 14494,14506 **** + int p0 = -333; + int c0; + int did_white = FALSE; + + /* + * Convert the multi-byte string to a wide-character string. + * Remove accents, if wanted. We actually remove all non-word characters. + * But keep white space. + */ +! n = 0; + for (s = inword; *s != NUL; ) + { + t = s; +--- 14494,14508 ---- + int p0 = -333; + int c0; + int did_white = FALSE; ++ int wordlen; ++ + + /* + * Convert the multi-byte string to a wide-character string. + * Remove accents, if wanted. We actually remove all non-word characters. + * But keep white space. + */ +! wordlen = 0; + for (s = inword; *s != NUL; ) + { + t = s; +*************** +*** 14521,14532 **** + continue; + } + } +! word[n++] = c; + } +! word[n] = NUL; + + /* +! * This comes from Aspell phonet.cpp. + * Converted from C++ to C. Added support for multi-byte chars. + * Changed to keep spaces. + */ +--- 14523,14534 ---- + continue; + } + } +! word[wordlen++] = c; + } +! word[wordlen] = NUL; + + /* +! * This algorithm comes from Aspell phonet.cpp. + * Converted from C++ to C. Added support for multi-byte chars. + * Changed to keep spaces. + */ +*************** +*** 14711,14717 **** + } + if (k > k0) + mch_memmove(word + i + k0, word + i + k, +! sizeof(int) * (STRLEN(word + i + k) + 1)); + + /* new "actual letter" */ + c = word[i]; +--- 14713,14719 ---- + } + if (k > k0) + mch_memmove(word + i + k0, word + i + k, +! sizeof(int) * (wordlen - (i + k) + 1)); + + /* new "actual letter" */ + c = word[i]; +*************** +*** 14739,14745 **** + if (c != NUL) + wres[reslen++] = c; + mch_memmove(word, word + i + 1, +! sizeof(int) * (STRLEN(word + i + 1) + 1)); + i = 0; + z0 = 1; + } +--- 14741,14747 ---- + if (c != NUL) + wres[reslen++] = c; + mch_memmove(word, word + i + 1, +! sizeof(int) * (wordlen - (i + 1) + 1)); + i = 0; + z0 = 1; + } +*** ../vim-7.3.520/src/version.c 2012-05-18 17:03:14.000000000 +0200 +--- src/version.c 2012-05-18 18:06:29.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 521, + /**/ + +-- +OLD WOMAN: King of the WHO? +ARTHUR: The Britons. +OLD WOMAN: Who are the Britons? + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4cf32d50ea2b28407194710d1850a9bdcf660382 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:52 +0200 Subject: [PATCH 0264/3340] - patchlevel 522 --- 7.3.522 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.522 diff --git a/7.3.522 b/7.3.522 new file mode 100644 index 00000000..2f4d17ce --- /dev/null +++ b/7.3.522 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.522 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.522 +Problem: Crash in vim_realloc() when using MEM_PROFILE. +Solution: Avoid using a NULL argument. (Dominique Pelle) +Files: src/eval.c + + +*** ../vim-7.3.521/src/eval.c 2012-05-18 12:06:58.000000000 +0200 +--- src/eval.c 2012-05-18 18:19:25.000000000 +0200 +*************** +*** 14643,14649 **** + long growmin = (long)((p - start) * 2 + prevlen); + prevsize = grow50pc > growmin ? grow50pc : growmin; + } +! if ((newprev = vim_realloc(prev, prevsize)) == NULL) + { + do_outofmem_msg((long_u)prevsize); + failed = TRUE; +--- 14643,14651 ---- + long growmin = (long)((p - start) * 2 + prevlen); + prevsize = grow50pc > growmin ? grow50pc : growmin; + } +! newprev = prev == NULL ? alloc(prevsize) +! : vim_realloc(prev, prevsize); +! if (newprev == NULL) + { + do_outofmem_msg((long_u)prevsize); + failed = TRUE; +*** ../vim-7.3.521/src/version.c 2012-05-18 18:07:57.000000000 +0200 +--- src/version.c 2012-05-18 18:33:36.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 522, + /**/ + +-- +ARTHUR: ... and I am your king .... +OLD WOMAN: Ooooh! I didn't know we had a king. I thought we were an + autonomous collective ... + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ec40abc857cebe4ac7d54938be8a6ad322954db4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:53 +0200 Subject: [PATCH 0265/3340] - patchlevel 523 --- 7.3.523 | 103 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 103 insertions(+) create mode 100644 7.3.523 diff --git a/7.3.523 b/7.3.523 new file mode 100644 index 00000000..7eec3ea2 --- /dev/null +++ b/7.3.523 @@ -0,0 +1,103 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.523 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.523 +Problem: ":diffupdate" doesn't check for files changed elsewhere. +Solution: Add the ! flag. (Christian Brabandt) +Files: runtime/doc/diff.txt, src/diff.c, src/ex_cmds.h + + +*** ../vim-7.3.522/runtime/doc/diff.txt 2010-08-15 21:57:16.000000000 +0200 +--- runtime/doc/diff.txt 2012-05-18 18:41:49.000000000 +0200 +*************** +*** 178,184 **** + nodiff" before hiding it. + + *:diffu* *:diffupdate* +! :diffu[pdate] Update the diff highlighting and folds. + + Vim attempts to keep the differences updated when you make changes to the + text. This mostly takes care of inserted and deleted lines. Changes within a +--- 178,184 ---- + nodiff" before hiding it. + + *:diffu* *:diffupdate* +! :diffu[pdate][!] Update the diff highlighting and folds. + + Vim attempts to keep the differences updated when you make changes to the + text. This mostly takes care of inserted and deleted lines. Changes within a +*************** +*** 187,192 **** +--- 187,195 ---- + + :diffupdate + ++ If the ! is included Vim will check if the file was changed externally and ++ needs to be reloaded. It will prompt for each changed file, like `:checktime` ++ was used. + + Vim will show filler lines for lines that are missing in one window but are + present in another. These lines were inserted in another file or deleted in +*** ../vim-7.3.522/src/diff.c 2010-09-21 16:56:29.000000000 +0200 +--- src/diff.c 2012-05-18 18:45:09.000000000 +0200 +*************** +*** 783,788 **** +--- 783,797 ---- + goto theend; + } + ++ /* :diffupdate! */ ++ if (eap != NULL && eap->forceit) ++ for (idx_new = idx_orig; idx_new < DB_COUNT; ++idx_new) ++ { ++ buf = curtab->tp_diffbuf[idx_new]; ++ if (buf_valid(buf)) ++ buf_check_timestamp(buf, FALSE); ++ } ++ + /* Write the first buffer to a tempfile. */ + buf = curtab->tp_diffbuf[idx_orig]; + if (diff_write(buf, tmp_orig) == FAIL) +*** ../vim-7.3.522/src/ex_cmds.h 2012-02-13 00:01:38.000000000 +0100 +--- src/ex_cmds.h 2012-05-18 18:37:56.000000000 +0200 +*************** +*** 304,310 **** + EX(CMD_display, "display", ex_display, + EXTRA|NOTRLCOM|TRLBAR|SBOXOK|CMDWIN), + EX(CMD_diffupdate, "diffupdate", ex_diffupdate, +! TRLBAR), + EX(CMD_diffget, "diffget", ex_diffgetput, + RANGE|EXTRA|TRLBAR|MODIFY), + EX(CMD_diffoff, "diffoff", ex_diffoff, +--- 304,310 ---- + EX(CMD_display, "display", ex_display, + EXTRA|NOTRLCOM|TRLBAR|SBOXOK|CMDWIN), + EX(CMD_diffupdate, "diffupdate", ex_diffupdate, +! BANG|TRLBAR), + EX(CMD_diffget, "diffget", ex_diffgetput, + RANGE|EXTRA|TRLBAR|MODIFY), + EX(CMD_diffoff, "diffoff", ex_diffoff, +*** ../vim-7.3.522/src/version.c 2012-05-18 18:34:15.000000000 +0200 +--- src/version.c 2012-05-18 18:39:13.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 523 + /**/ + +-- +"The future's already arrived - it's just not evenly distributed yet." + -- William Gibson + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 83990b9deb47d0dbb77b1f3bdf2d9f3e9194e34b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:53 +0200 Subject: [PATCH 0266/3340] - patchlevel 524 --- 7.3.524 | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 7.3.524 diff --git a/7.3.524 b/7.3.524 new file mode 100644 index 00000000..80d7baf6 --- /dev/null +++ b/7.3.524 @@ -0,0 +1,46 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.524 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.524 (after 7.3.523) +Problem: Missing comma. +Solution: Add the comma. +Files: src/version.c + + +*** ../vim-7.3.523/src/version.c 2012-05-18 18:47:11.000000000 +0200 +--- src/version.c 2012-05-18 21:52:26.000000000 +0200 +*************** +*** 715,721 **** + static int included_patches[] = + { /* Add new patch number below this line */ + /**/ +! 523 + /**/ + 522, + /**/ +--- 715,723 ---- + static int included_patches[] = + { /* Add new patch number below this line */ + /**/ +! 524, +! /**/ +! 523, + /**/ + 522, + /**/ + +-- +DENNIS: You can't expect to wield supreme executive power just 'cause some + watery tart threw a sword at you! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8c42ccf4be7f444942bba7ff4d9136c59d3fec66 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:53 +0200 Subject: [PATCH 0267/3340] - patchlevel 525 --- 7.3.525 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.525 diff --git a/7.3.525 b/7.3.525 new file mode 100644 index 00000000..c9741cbf --- /dev/null +++ b/7.3.525 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.525 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.525 +Problem: Compiler warning on 64 bit MS-Windows. +Solution: Add type cast. (Mike Williams) +Files: src/ex_getln.c + + +*** ../vim-7.3.524/src/ex_getln.c 2012-04-30 18:48:38.000000000 +0200 +--- src/ex_getln.c 2012-05-23 20:33:16.000000000 +0200 +*************** +*** 5263,5269 **** + { + static char_u compl[2] = { NUL, NUL }; + char *short_names = ":=@>?/"; +! int short_names_count = STRLEN(short_names); + int history_name_count = sizeof(history_names) / sizeof(char *) - 1; + + if (idx < short_names_count) +--- 5263,5269 ---- + { + static char_u compl[2] = { NUL, NUL }; + char *short_names = ":=@>?/"; +! int short_names_count = (int)STRLEN(short_names); + int history_name_count = sizeof(history_names) / sizeof(char *) - 1; + + if (idx < short_names_count) +*** ../vim-7.3.524/src/version.c 2012-05-18 21:53:29.000000000 +0200 +--- src/version.c 2012-05-25 11:01:51.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 525, + /**/ + +-- +For humans, honesty is a matter of degree. Engineers are always honest in +matters of technology and human relationships. That's why it's a good idea +to keep engineers away from customers, romantic interests, and other people +who can't handle the truth. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ea2046501649f9cd243152cfacb55e8e442f944c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:53 +0200 Subject: [PATCH 0268/3340] - patchlevel 526 --- 7.3.526 | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.526 diff --git a/7.3.526 b/7.3.526 new file mode 100644 index 00000000..036d401f --- /dev/null +++ b/7.3.526 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.526 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.526 +Problem: Confusing indenting for #ifdef. +Solution: Remove and add indent. (Elias Diem) +Files: src/normal.c + + +*** ../vim-7.3.525/src/normal.c 2012-04-30 18:18:43.000000000 +0200 +--- src/normal.c 2012-05-23 20:35:13.000000000 +0200 +*************** +*** 29,37 **** + static void set_vcount_ca __ARGS((cmdarg_T *cap, int *set_prevcount)); + #endif + static int +! # ifdef __BORLANDC__ +! _RTLENTRYF +! # endif + nv_compare __ARGS((const void *s1, const void *s2)); + static int find_command __ARGS((int cmdchar)); + static void op_colon __ARGS((oparg_T *oap)); +--- 29,37 ---- + static void set_vcount_ca __ARGS((cmdarg_T *cap, int *set_prevcount)); + #endif + static int +! #ifdef __BORLANDC__ +! _RTLENTRYF +! #endif + nv_compare __ARGS((const void *s1, const void *s2)); + static int find_command __ARGS((int cmdchar)); + static void op_colon __ARGS((oparg_T *oap)); +*** ../vim-7.3.525/src/version.c 2012-05-25 11:02:34.000000000 +0200 +--- src/version.c 2012-05-25 11:03:37.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 526, + /**/ + +-- +While it's true that many normal people whould prefer not to _date_ an +engineer, most normal people harbor an intense desire to _mate_ with them, +thus producing engineerlike children who will have high-paying jobs long +before losing their virginity. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f66c8df5a3a687ddc05a14e9965c5a9e4b7395e3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:54 +0200 Subject: [PATCH 0269/3340] - patchlevel 527 --- 7.3.527 | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.527 diff --git a/7.3.527 b/7.3.527 new file mode 100644 index 00000000..0c6af2b0 --- /dev/null +++ b/7.3.527 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.527 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=latin1 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.527 +Problem: Clang complains about non-ASCII characters in a string. +Solution: Change to \x88 form. (Dominique Pelle) +Files: src/charset.c + + +*** ../vim-7.3.526/src/charset.c 2012-01-26 13:40:04.000000000 +0100 +--- src/charset.c 2012-05-25 11:49:58.000000000 +0200 +*************** +*** 1602,1611 **** + #define LATIN1LOWER 'l' + #define LATIN1UPPER 'U' + +- /* !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]%_'abcdefghijklmnopqrstuvwxyz{|}~ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖרÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ */ + static char_u latin1flags[257] = " UUUUUUUUUUUUUUUUUUUUUUUUUU llllllllllllllllllllllllll UUUUUUUUUUUUUUUUUUUUUUU UUUUUUUllllllllllllllllllllllll llllllll"; +! static char_u latin1upper[257] = " !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`ABCDEFGHIJKLMNOPQRSTUVWXYZ{|}~€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖרÙÚÛÜÝÞßÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ÷ØÙÚÛÜÝÞÿ"; +! static char_u latin1lower[257] = " !\"#$%&'()*+,-./0123456789:;<=>?@abcdefghijklmnopqrstuvwxyz[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿àáâãäåæçèéêëìíîïðñòóôõö×øùúûüýþßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ"; + + int + vim_islower(c) +--- 1602,1610 ---- + #define LATIN1LOWER 'l' + #define LATIN1UPPER 'U' + + static char_u latin1flags[257] = " UUUUUUUUUUUUUUUUUUUUUUUUUU llllllllllllllllllllllllll UUUUUUUUUUUUUUUUUUUUUUU UUUUUUUllllllllllllllllllllllll llllllll"; +! static char_u latin1upper[257] = " !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`ABCDEFGHIJKLMNOPQRSTUVWXYZ{|}~\x7f\x80\x81\x82\x83\x84\x85\x86\x87\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f\x90\x91\x92\x93\x94\x95\x96\x97\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7\xa8\xa9\xaa\xab\xac\xad\xae\xaf\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xf7\xd8\xd9\xda\xdb\xdc\xdd\xde\xff"; +! static char_u latin1lower[257] = " !\"#$%&'()*+,-./0123456789:;<=>?@abcdefghijklmnopqrstuvwxyz[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~\x7f\x80\x81\x82\x83\x84\x85\x86\x87\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f\x90\x91\x92\x93\x94\x95\x96\x97\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7\xa8\xa9\xaa\xab\xac\xad\xae\xaf\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7\xe8\xe9\xea\xeb\xec\xed\xee\xef\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xd7\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xdf\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7\xe8\xe9\xea\xeb\xec\xed\xee\xef\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"; + + int + vim_islower(c) +*** ../vim-7.3.526/src/version.c 2012-05-25 11:04:34.000000000 +0200 +--- src/version.c 2012-05-25 11:52:06.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 527, + /**/ + +-- +An alien life briefly visits earth. Just before departing it leaves a +message in the dust on the back of a white van. The world is shocked +and wants to know what it means. After months of studies the worlds +best linguistic scientists are able to decipher the message: "Wash me!". + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 31422c1b3a3b76d206737172ab7449cb4f859be9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:54 +0200 Subject: [PATCH 0270/3340] - patchlevel 528 --- 7.3.528 | 171 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 171 insertions(+) create mode 100644 7.3.528 diff --git a/7.3.528 b/7.3.528 new file mode 100644 index 00000000..41084ad4 --- /dev/null +++ b/7.3.528 @@ -0,0 +1,171 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.528 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.528 +Problem: Crash when closing last window in a tab. (Alex Efros) +Solution: Use common code in close_last_window_tabpage(). (Christian + Brabandt) +Files: src/window.c + + +*** ../vim-7.3.527/src/window.c 2012-03-16 19:07:54.000000000 +0100 +--- src/window.c 2012-05-25 12:25:16.000000000 +0200 +*************** +*** 23,28 **** +--- 23,29 ---- + static void win_totop __ARGS((int size, int flags)); + static void win_equal_rec __ARGS((win_T *next_curwin, int current, frame_T *topfr, int dir, int col, int row, int width, int height)); + static int last_window __ARGS((void)); ++ static int close_last_window_tabpage __ARGS((win_T *win, int free_buf, tabpage_T *prev_curtab)); + static win_T *win_free_mem __ARGS((win_T *win, int *dirp, tabpage_T *tp)); + static frame_T *win_altframe __ARGS((win_T *win, tabpage_T *tp)); + static tabpage_T *alt_tabpage __ARGS((void)); +*************** +*** 2105,2110 **** +--- 2106,2147 ---- + } + + /* ++ * Close the possibly last window in a tab page. ++ * Returns TRUE when the window was closed already. ++ */ ++ static int ++ close_last_window_tabpage(win, free_buf, prev_curtab) ++ win_T *win; ++ int free_buf; ++ tabpage_T *prev_curtab; ++ { ++ if (firstwin == lastwin) ++ { ++ /* ++ * Closing the last window in a tab page. First go to another tab ++ * page and then close the window and the tab page. This avoids that ++ * curwin and curtab are invalid while we are freeing memory, they may ++ * be used in GUI events. ++ */ ++ goto_tabpage_tp(alt_tabpage()); ++ redraw_tabline = TRUE; ++ ++ /* Safety check: Autocommands may have closed the window when jumping ++ * to the other tab page. */ ++ if (valid_tabpage(prev_curtab) && prev_curtab->tp_firstwin == win) ++ { ++ int h = tabline_height(); ++ ++ win_close_othertab(win, free_buf, prev_curtab); ++ if (h != tabline_height()) ++ shell_new_rows(); ++ } ++ return TRUE; ++ } ++ return FALSE; ++ } ++ ++ /* + * Close window "win". Only works for the current tab page. + * If "free_buf" is TRUE related buffer may be unloaded. + * +*************** +*** 2143,2171 **** + } + #endif + +! /* +! * When closing the last window in a tab page first go to another tab +! * page and then close the window and the tab page. This avoids that +! * curwin and curtab are not invalid while we are freeing memory, they may +! * be used in GUI events. +! */ +! if (firstwin == lastwin) +! { +! goto_tabpage_tp(alt_tabpage()); +! redraw_tabline = TRUE; +! +! /* Safety check: Autocommands may have closed the window when jumping +! * to the other tab page. */ +! if (valid_tabpage(prev_curtab) && prev_curtab->tp_firstwin == win) +! { +! int h = tabline_height(); +! +! win_close_othertab(win, free_buf, prev_curtab); +! if (h != tabline_height()) +! shell_new_rows(); +! } +! return; +! } + + /* When closing the help window, try restoring a snapshot after closing + * the window. Otherwise clear the snapshot, it's now invalid. */ +--- 2180,2190 ---- + } + #endif + +! /* When closing the last window in a tab page first go to another tab page +! * and then close the window and the tab page to avoid that curwin and +! * curtab are invalid while we are freeing memory. */ +! if (close_last_window_tabpage(win, free_buf, prev_curtab)) +! return; + + /* When closing the help window, try restoring a snapshot after closing + * the window. Otherwise clear the snapshot, it's now invalid. */ +*************** +*** 2225,2231 **** + + /* Autocommands may have closed the window already, or closed the only + * other window or moved to another tab page. */ +! if (!win_valid(win) || last_window() || curtab != prev_curtab) + return; + + /* Free the memory used for the window and get the window that received +--- 2244,2251 ---- + + /* Autocommands may have closed the window already, or closed the only + * other window or moved to another tab page. */ +! if (!win_valid(win) || last_window() || curtab != prev_curtab +! || close_last_window_tabpage(win, free_buf, prev_curtab)) + return; + + /* Free the memory used for the window and get the window that received +*************** +*** 2310,2316 **** + + /* + * Close window "win" in tab page "tp", which is not the current tab page. +! * This may be the last window ih that tab page and result in closing the tab, + * thus "tp" may become invalid! + * Caller must check if buffer is hidden and whether the tabline needs to be + * updated. +--- 2330,2336 ---- + + /* + * Close window "win" in tab page "tp", which is not the current tab page. +! * This may be the last window in that tab page and result in closing the tab, + * thus "tp" may become invalid! + * Caller must check if buffer is hidden and whether the tabline needs to be + * updated. +*** ../vim-7.3.527/src/version.c 2012-05-25 11:56:06.000000000 +0200 +--- src/version.c 2012-05-25 12:38:25.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 528, + /**/ + +-- +For society, it's probably a good thing that engineers value function over +appearance. For example, you wouldn't want engineers to build nuclear power +plants that only _look_ like they would keep all the radiation inside. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8c54bab4eadc8ac429791a6eef3465ea335dd13f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:55 +0200 Subject: [PATCH 0271/3340] - patchlevel 529 --- 7.3.529 | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 7.3.529 diff --git a/7.3.529 b/7.3.529 new file mode 100644 index 00000000..386baf1f --- /dev/null +++ b/7.3.529 @@ -0,0 +1,81 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.529 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.529 +Problem: Using a count before "v" and "V" does not work (Kikyous) +Solution: Make the count select that many characters or lines. (Christian + Brabandt) +Files: src/normal.c + + +*** ../vim-7.3.528/src/normal.c 2012-05-25 11:04:34.000000000 +0200 +--- src/normal.c 2012-05-25 13:12:06.000000000 +0200 +*************** +*** 7660,7672 **** + else /* start Visual mode */ + { + check_visual_highlight(); +! if (cap->count0) /* use previously selected part */ + { +! if (resel_VIsual_mode == NUL) /* there is none */ +! { +! beep_flush(); +! return; +! } + VIsual = curwin->w_cursor; + + VIsual_active = TRUE; +--- 7660,7668 ---- + else /* start Visual mode */ + { + check_visual_highlight(); +! if (cap->count0 > 0 && resel_VIsual_mode != NUL) + { +! /* use previously selected part */ + VIsual = curwin->w_cursor; + + VIsual_active = TRUE; +*************** +*** 7725,7730 **** +--- 7721,7736 ---- + /* start Select mode when 'selectmode' contains "cmd" */ + may_start_select('c'); + n_start_visual_mode(cap->cmdchar); ++ if (VIsual_mode != 'V' && *p_sel == 'e') ++ ++cap->count1; /* include one more char */ ++ if (cap->count0 > 0 && --cap->count1 > 0) ++ { ++ /* With a count select that many characters or lines. */ ++ if (VIsual_mode == 'v' || VIsual_mode == Ctrl_V) ++ nv_right(cap); ++ else if (VIsual_mode == 'V') ++ nv_down(cap); ++ } + } + } + } +*** ../vim-7.3.528/src/version.c 2012-05-25 12:38:57.000000000 +0200 +--- src/version.c 2012-05-25 12:59:58.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 529, + /**/ + +-- +Normal people believe that if it ain't broke, don't fix it. Engineers believe +that if it ain't broke, it doesn't have enough features yet. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 40eeff9f3611363e56c88627d0b1ddbe24a7c88d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:56 +0200 Subject: [PATCH 0272/3340] - patchlevel 530 --- 7.3.530 | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 7.3.530 diff --git a/7.3.530 b/7.3.530 new file mode 100644 index 00000000..216117ca --- /dev/null +++ b/7.3.530 @@ -0,0 +1,50 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.530 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.530 (after 7.3.520) +Problem: Gvim does not work when 'guioptions' includes "f". (Davido) +Solution: Call gui_mch_init_check() when running GUI in the foreground. + (Yasuhiro Matsumoto) +Files: src/gui.c + + +*** ../vim-7.3.529/src/gui.c 2012-05-18 17:03:13.000000000 +0200 +--- src/gui.c 2012-05-25 14:01:26.000000000 +0200 +*************** +*** 102,107 **** +--- 102,111 ---- + else + #endif + { ++ /* If there is 'f' in 'guioptions' and specify -g argument, ++ * gui_mch_init_check() was not called yet. */ ++ if (gui_mch_init_check() != OK) ++ exit(1); + gui_attempt_start(); + } + +*** ../vim-7.3.529/src/version.c 2012-05-25 13:12:33.000000000 +0200 +--- src/version.c 2012-05-25 14:05:46.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 530, + /**/ + +-- +I think that you'll agree that engineers are very effective in their social +interactions. It's the "normal" people who are nuts. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 520a099f24bab92c16f3047d43f3358fa9c1a77a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:56 +0200 Subject: [PATCH 0273/3340] - patchlevel 531 --- 7.3.531 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.531 diff --git a/7.3.531 b/7.3.531 new file mode 100644 index 00000000..652bdb73 --- /dev/null +++ b/7.3.531 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.531 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.531 (after 7.3.530) +Problem: GUI does not work on MS-Windows. +Solution: Add the missing #ifdef. (Patrick Avery) +Files: src/gui.c + + +*** ../vim-7.3.530/src/gui.c 2012-05-25 14:06:18.000000000 +0200 +--- src/gui.c 2012-05-27 00:34:51.000000000 +0200 +*************** +*** 102,111 **** +--- 102,113 ---- + else + #endif + { ++ #ifdef FEAT_GUI_GTK + /* If there is 'f' in 'guioptions' and specify -g argument, + * gui_mch_init_check() was not called yet. */ + if (gui_mch_init_check() != OK) + exit(1); ++ #endif + gui_attempt_start(); + } + +*** ../vim-7.3.530/src/version.c 2012-05-25 14:06:18.000000000 +0200 +--- src/version.c 2012-05-27 00:37:33.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 531, + /**/ + +-- +I learned the customs and mannerisms of engineers by observing them, much the +way Jane Goodall learned about the great apes, but without the hassle of +grooming. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 678db7494088eb99669097a2bcc7a5d440c179ea Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:56 +0200 Subject: [PATCH 0274/3340] - patchlevel 532 --- 7.3.532 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.532 diff --git a/7.3.532 b/7.3.532 new file mode 100644 index 00000000..071cab34 --- /dev/null +++ b/7.3.532 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.532 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.532 +Problem: Compiler warning from Clang. +Solution: Use a different way to point inside a string. (Dominique Pelle) +Files: src/syntax.c + + +*** ../vim-7.3.531/src/syntax.c 2012-03-23 16:25:13.000000000 +0100 +--- src/syntax.c 2012-06-01 13:13:58.000000000 +0200 +*************** +*** 9476,9482 **** + int cnt; + int attr; + { +! msg_puts_attr((char_u *)("N \bI \b! \b" + cnt / 11), attr); + msg_clr_eos(); + out_flush(); + ui_delay(cnt == 99 ? 40L : (long)cnt * 50L, FALSE); +--- 9476,9482 ---- + int cnt; + int attr; + { +! msg_puts_attr((char_u *)&("N \bI \b! \b"[cnt / 11]), attr); + msg_clr_eos(); + out_flush(); + ui_delay(cnt == 99 ? 40L : (long)cnt * 50L, FALSE); +*** ../vim-7.3.531/src/version.c 2012-05-27 00:37:45.000000000 +0200 +--- src/version.c 2012-06-01 13:14:51.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 532, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +8. You spend half of the plane trip with your laptop on your lap...and your + child in the overhead compartment. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From af6abb0401465e7b74db0b8938575894429856ad Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:56 +0200 Subject: [PATCH 0275/3340] - patchlevel 533 --- 7.3.533 | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 7.3.533 diff --git a/7.3.533 b/7.3.533 new file mode 100644 index 00000000..1d71c8d1 --- /dev/null +++ b/7.3.533 @@ -0,0 +1,46 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.533 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.533 +Problem: Memory leak when writing undo file. +Solution: Free the ACL. (Dominique Pelle) +Files: src/undo.c + + +*** ../vim-7.3.532/src/undo.c 2011-12-08 15:14:04.000000000 +0100 +--- src/undo.c 2012-06-01 13:38:42.000000000 +0200 +*************** +*** 1535,1540 **** +--- 1535,1541 ---- + /* For systems that support ACL: get the ACL from the original file. */ + acl = mch_get_acl(buf->b_ffname); + mch_set_acl(file_name, acl); ++ mch_free_acl(acl); + } + #endif + +*** ../vim-7.3.532/src/version.c 2012-06-01 13:18:48.000000000 +0200 +--- src/version.c 2012-06-01 13:39:16.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 533, + /**/ + +-- +"How is your new girlfriend?" +"90-60-90 man!" +"What, pale purple?" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b63fed1ed2585bcff6b6db6309627b7844272211 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:57 +0200 Subject: [PATCH 0276/3340] - patchlevel 534 --- 7.3.534 | 101 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 101 insertions(+) create mode 100644 7.3.534 diff --git a/7.3.534 b/7.3.534 new file mode 100644 index 00000000..618d6e4e --- /dev/null +++ b/7.3.534 @@ -0,0 +1,101 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.534 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.534 (after 7.3.461) +Problem: When using an InsertCharPre autocommand autoindent fails. +Solution: Proper handling of v:char. (Alexey Radkov) +Files: src/edit.c + + +*** ../vim-7.3.533/src/edit.c 2012-05-18 16:35:17.000000000 +0200 +--- src/edit.c 2012-06-01 14:41:06.000000000 +0200 +*************** +*** 10108,10129 **** + do_insert_char_pre(c) + int c; + { +! char_u *res; + + /* Return quickly when there is nothing to do. */ + if (!has_insertcharpre()) + return NULL; + + /* Lock the text to avoid weird things from happening. */ + ++textlock; +! set_vim_var_char(c); /* set v:char */ + + if (apply_autocmds(EVENT_INSERTCHARPRE, NULL, NULL, FALSE, curbuf)) +! /* Get the new value of v:char. It may be empty or more than one +! * character. */ +! res = vim_strsave(get_vim_var_str(VV_CHAR)); +! else +! res = NULL; + + set_vim_var_string(VV_CHAR, NULL, -1); /* clear v:char */ + --textlock; +--- 10108,10147 ---- + do_insert_char_pre(c) + int c; + { +! char_u *res; +! #ifdef FEAT_MBYTE +! char_u buf[MB_MAXBYTES + 1]; +! #else +! char_u buf[2]; +! #endif + + /* Return quickly when there is nothing to do. */ + if (!has_insertcharpre()) + return NULL; + ++ #ifdef FEAT_MBYTE ++ if (has_mbyte) ++ buf[(*mb_char2bytes)(c, buf)] = NUL; ++ else ++ #endif ++ { ++ buf[0] = c; ++ buf[1] = NUL; ++ } ++ + /* Lock the text to avoid weird things from happening. */ + ++textlock; +! set_vim_var_string(VV_CHAR, buf, -1); /* set v:char */ + ++ res = NULL; + if (apply_autocmds(EVENT_INSERTCHARPRE, NULL, NULL, FALSE, curbuf)) +! { +! /* Get the value of v:char. It may be empty or more than one +! * character. Only use it when changed, otherwise continue with the +! * original character to avoid breaking autoindent. */ +! if (STRCMP(buf, get_vim_var_str(VV_CHAR)) != 0) +! res = vim_strsave(get_vim_var_str(VV_CHAR)); +! } + + set_vim_var_string(VV_CHAR, NULL, -1); /* clear v:char */ + --textlock; +*** ../vim-7.3.533/src/version.c 2012-06-01 13:46:06.000000000 +0200 +--- src/version.c 2012-06-01 14:42:19.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 534, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +11. You find yourself typing "com" after every period when using a word + processor.com + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e33e6d694f523f4672ca01b2142ab2c460791dc2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:57 +0200 Subject: [PATCH 0277/3340] - patchlevel 535 --- 7.3.535 | 356 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 356 insertions(+) create mode 100644 7.3.535 diff --git a/7.3.535 b/7.3.535 new file mode 100644 index 00000000..e7f0f8a9 --- /dev/null +++ b/7.3.535 @@ -0,0 +1,356 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.535 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.535 +Problem: Many #ifdefs for MB_MAXBYTES. +Solution: Also define MB_MAXBYTES without the +multi_byte feature. Fix + places where the buffer didn't include space for a NUL byte. +Files: src/arabic.c, src/edit.c, src/eval.c, src/getchar.c, src/mbyte.c, + src/misc1.c, src/screen.c, src/spell.c, src/vim.h + + +*** ../vim-7.3.534/src/arabic.c 2010-08-15 21:57:28.000000000 +0200 +--- src/arabic.c 2012-06-01 14:59:37.000000000 +0200 +*************** +*** 1066,1072 **** + + if (curr_c != c && ccp != NULL) + { +! char_u buf[MB_MAXBYTES]; + + /* Update the first byte of the character. */ + (*mb_char2bytes)(curr_c, buf); +--- 1066,1072 ---- + + if (curr_c != c && ccp != NULL) + { +! char_u buf[MB_MAXBYTES + 1]; + + /* Update the first byte of the character. */ + (*mb_char2bytes)(curr_c, buf); +*** ../vim-7.3.534/src/edit.c 2012-06-01 14:57:47.000000000 +0200 +--- src/edit.c 2012-06-01 15:01:49.000000000 +0200 +*************** +*** 1648,1658 **** + #define PC_STATUS_RIGHT 1 /* right halve of double-wide char */ + #define PC_STATUS_LEFT 2 /* left halve of double-wide char */ + #define PC_STATUS_SET 3 /* pc_bytes was filled */ +- #ifdef FEAT_MBYTE + static char_u pc_bytes[MB_MAXBYTES + 1]; /* saved bytes */ +- #else +- static char_u pc_bytes[2]; /* saved bytes */ +- #endif + static int pc_attr; + static int pc_row; + static int pc_col; +--- 1648,1654 ---- +*************** +*** 6819,6829 **** + char_u *s; + + vim_free(last_insert); +- #ifdef FEAT_MBYTE + last_insert = alloc(MB_MAXBYTES * 3 + 5); +- #else +- last_insert = alloc(6); +- #endif + if (last_insert != NULL) + { + s = last_insert; +--- 6815,6821 ---- +*************** +*** 6861,6867 **** + char_u *s; + { + #ifdef FEAT_MBYTE +! char_u temp[MB_MAXBYTES]; + int i; + int len; + +--- 6853,6859 ---- + char_u *s; + { + #ifdef FEAT_MBYTE +! char_u temp[MB_MAXBYTES + 1]; + int i; + int len; + +*************** +*** 7423,7429 **** + int cc; + { + int n; +! char_u buf[MB_MAXBYTES]; + int i; + int c; + +--- 7415,7421 ---- + int cc; + { + int n; +! char_u buf[MB_MAXBYTES + 1]; + int i; + int c; + +*************** +*** 10109,10119 **** + int c; + { + char_u *res; +- #ifdef FEAT_MBYTE + char_u buf[MB_MAXBYTES + 1]; +- #else +- char_u buf[2]; +- #endif + + /* Return quickly when there is nothing to do. */ + if (!has_insertcharpre()) +--- 10101,10107 ---- +*** ../vim-7.3.534/src/eval.c 2012-05-18 18:34:15.000000000 +0200 +--- src/eval.c 2012-06-01 15:02:08.000000000 +0200 +*************** +*** 19170,19180 **** + set_vim_var_char(c) + int c; + { +! #ifdef FEAT_MBYTE +! char_u buf[MB_MAXBYTES]; +! #else +! char_u buf[2]; +! #endif + + #ifdef FEAT_MBYTE + if (has_mbyte) +--- 19170,19176 ---- + set_vim_var_char(c) + int c; + { +! char_u buf[MB_MAXBYTES + 1]; + + #ifdef FEAT_MBYTE + if (has_mbyte) +*** ../vim-7.3.534/src/getchar.c 2012-04-05 16:07:01.000000000 +0200 +--- src/getchar.c 2012-06-01 15:03:51.000000000 +0200 +*************** +*** 723,729 **** + int c; + #ifdef FEAT_MBYTE + int n; +! char_u buf[MB_MAXBYTES]; + int i; + #endif + +--- 723,729 ---- + int c; + #ifdef FEAT_MBYTE + int n; +! char_u buf[MB_MAXBYTES + 1]; + int i; + #endif + +*************** +*** 1072,1078 **** + int c; + { + #ifdef FEAT_MBYTE +! char_u buf[MB_MAXBYTES]; + #else + char_u buf[4]; + #endif +--- 1072,1078 ---- + int c; + { + #ifdef FEAT_MBYTE +! char_u buf[MB_MAXBYTES + 1]; + #else + char_u buf[4]; + #endif +*************** +*** 1547,1553 **** + int c, c2; + #ifdef FEAT_MBYTE + int n; +! char_u buf[MB_MAXBYTES]; + int i; + #endif + +--- 1547,1553 ---- + int c, c2; + #ifdef FEAT_MBYTE + int n; +! char_u buf[MB_MAXBYTES + 1]; + int i; + #endif + +*************** +*** 4335,4345 **** + int scol; /* starting column of the abbr. */ + int j; + char_u *s; +- #ifdef FEAT_MBYTE + char_u tb[MB_MAXBYTES + 4]; +- #else +- char_u tb[4]; +- #endif + mapblock_T *mp; + #ifdef FEAT_LOCALMAP + mapblock_T *mp2; +--- 4335,4341 ---- +*** ../vim-7.3.534/src/mbyte.c 2012-03-07 19:38:52.000000000 +0100 +--- src/mbyte.c 2012-06-01 15:04:27.000000000 +0200 +*************** +*** 708,714 **** + */ + n = (i & 0x80) ? 2 : 1; + # else +! char buf[MB_MAXBYTES]; + # ifdef X_LOCALE + # ifndef mblen + # define mblen _Xmblen +--- 708,714 ---- + */ + n = (i & 0x80) ? 2 : 1; + # else +! char buf[MB_MAXBYTES + 1]; + # ifdef X_LOCALE + # ifndef mblen + # define mblen _Xmblen +*************** +*** 1953,1959 **** + /* + * Convert the character at screen position "off" to a sequence of bytes. + * Includes the composing characters. +! * "buf" must at least have the length MB_MAXBYTES. + * Only to be used when ScreenLinesUC[off] != 0. + * Returns the produced number of bytes. + */ +--- 1953,1959 ---- + /* + * Convert the character at screen position "off" to a sequence of bytes. + * Includes the composing characters. +! * "buf" must at least have the length MB_MAXBYTES + 1. + * Only to be used when ScreenLinesUC[off] != 0. + * Returns the produced number of bytes. + */ +*** ../vim-7.3.534/src/misc1.c 2012-04-30 21:09:38.000000000 +0200 +--- src/misc1.c 2012-06-01 15:04:56.000000000 +0200 +*************** +*** 1932,1938 **** + int c; + { + #if defined(FEAT_MBYTE) || defined(PROTO) +! char_u buf[MB_MAXBYTES]; + int n; + + n = (*mb_char2bytes)(c, buf); +--- 1932,1938 ---- + int c; + { + #if defined(FEAT_MBYTE) || defined(PROTO) +! char_u buf[MB_MAXBYTES + 1]; + int n; + + n = (*mb_char2bytes)(c, buf); +*** ../vim-7.3.534/src/screen.c 2012-03-23 16:25:13.000000000 +0100 +--- src/screen.c 2012-06-01 15:06:03.000000000 +0200 +*************** +*** 6621,6636 **** + int row, col; + int attr; + { +- #ifdef FEAT_MBYTE + char_u buf[MB_MAXBYTES + 1]; + +! buf[(*mb_char2bytes)(c, buf)] = NUL; +! #else +! char_u buf[2]; +! +! buf[0] = c; +! buf[1] = NUL; + #endif + screen_puts(buf, row, col, attr); + } + +--- 6621,6637 ---- + int row, col; + int attr; + { + char_u buf[MB_MAXBYTES + 1]; + +! #ifdef FEAT_MBYTE +! if (has_mbyte) +! buf[(*mb_char2bytes)(c, buf)] = NUL; +! else + #endif ++ { ++ buf[0] = c; ++ buf[1] = NUL; ++ } + screen_puts(buf, row, col, attr); + } + +*** ../vim-7.3.534/src/spell.c 2012-05-18 18:07:57.000000000 +0200 +--- src/spell.c 2012-06-01 15:06:30.000000000 +0200 +*************** +*** 13694,13700 **** + { + int m1, m2; + #ifdef FEAT_MBYTE +! char_u buf[MB_MAXBYTES]; + hashitem_T *hi; + + if (c1 >= 256) +--- 13694,13700 ---- + { + int m1, m2; + #ifdef FEAT_MBYTE +! char_u buf[MB_MAXBYTES + 1]; + hashitem_T *hi; + + if (c1 >= 256) +*** ../vim-7.3.534/src/vim.h 2012-04-30 18:48:38.000000000 +0200 +--- src/vim.h 2012-06-01 14:59:28.000000000 +0200 +*************** +*** 1703,1708 **** +--- 1703,1710 ---- + * character of up to 6 bytes, or one 16-bit character of up to three bytes + * plus six following composing characters of three bytes each. */ + # define MB_MAXBYTES 21 ++ #else ++ # define MB_MAXBYTES 1 + #endif + + #if (defined(FEAT_PROFILE) || defined(FEAT_RELTIME)) && !defined(PROTO) +*************** +*** 2017,2022 **** +--- 2019,2025 ---- + #pragma warning(disable : 4312) + #endif + ++ /* Note: a NULL argument for vim_realloc() is not portable, don't use it. */ + #if defined(MEM_PROFILE) + # define vim_realloc(ptr, size) mem_realloc((ptr), (size)) + #else +*** ../vim-7.3.534/src/version.c 2012-06-01 14:57:47.000000000 +0200 +--- src/version.c 2012-06-01 15:08:20.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 535, + /**/ + +-- +Me? A skeptic? I trust you have proof. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e4e2eed967d0b35b304e6697208042a8b4e3b156 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:57 +0200 Subject: [PATCH 0278/3340] - patchlevel 536 --- 7.3.536 | 73 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 7.3.536 diff --git a/7.3.536 b/7.3.536 new file mode 100644 index 00000000..e0c3f760 --- /dev/null +++ b/7.3.536 @@ -0,0 +1,73 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.536 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.536 +Problem: When spell checking the German sharp s is not seen as a word + character. (Aexl Bender) +Solution: In utf_islower() return true for the sharp s. Note: also need + updated spell file for this to take effect. +Files: src/mbyte.c + + +*** ../vim-7.3.535/src/mbyte.c 2012-06-01 15:20:49.000000000 +0200 +--- src/mbyte.c 2012-06-01 16:50:41.000000000 +0200 +*************** +*** 2949,2955 **** + { + {0x61,0x7a,1,-32}, + {0xb5,0xb5,-1,743}, +! {0xe0,0xf6,1,-32}, + {0xf8,0xfe,1,-32}, + {0xff,0xff,-1,121}, + {0x101,0x12f,2,-1}, +--- 2949,2955 ---- + { + {0x61,0x7a,1,-32}, + {0xb5,0xb5,-1,743}, +! {0xe0,0xf6,1,-32}, /* 0xdf (German sharp s) is not upper-cased */ + {0xf8,0xfe,1,-32}, + {0xff,0xff,-1,121}, + {0x101,0x12f,2,-1}, +*************** +*** 3129,3135 **** + utf_islower(a) + int a; + { +! return (utf_toupper(a) != a); + } + + /* +--- 3129,3136 ---- + utf_islower(a) + int a; + { +! /* German sharp s is lower case but has no upper case equivalent. */ +! return (utf_toupper(a) != a) || a == 0xdf; + } + + /* +*** ../vim-7.3.535/src/version.c 2012-06-01 15:20:49.000000000 +0200 +--- src/version.c 2012-06-01 17:45:17.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 536, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +16. You step out of your room and realize that your parents have moved and + you don't have a clue when it happened. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 786a62ba0a656840eb3e95da9cbd0bcbaadc146d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:58 +0200 Subject: [PATCH 0279/3340] - patchlevel 537 --- 7.3.537 | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 7.3.537 diff --git a/7.3.537 b/7.3.537 new file mode 100644 index 00000000..76b41c8a --- /dev/null +++ b/7.3.537 @@ -0,0 +1,47 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.537 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.537 +Problem: Unecessary call to init_spell_chartab(). +Solution: Delete the call. +Files: src/spell.c + + +*** ../vim-7.3.536/src/spell.c 2012-06-01 15:20:49.000000000 +0200 +--- src/spell.c 2012-06-01 17:49:44.000000000 +0200 +*************** +*** 4721,4728 **** + int_wordlist = NULL; + } + +- init_spell_chartab(); +- + vim_free(repl_to); + repl_to = NULL; + vim_free(repl_from); +--- 4721,4726 ---- +*** ../vim-7.3.536/src/version.c 2012-06-01 17:46:52.000000000 +0200 +--- src/version.c 2012-06-01 17:49:08.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 537, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +17. You turn on your intercom when leaving the room so you can hear if new + e-mail arrives. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f6d749732f68f85ebfc5fdaeac9bf0afe0da879f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:58 +0200 Subject: [PATCH 0280/3340] - patchlevel 538 --- 7.3.538 | 321 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 321 insertions(+) create mode 100644 7.3.538 diff --git a/7.3.538 b/7.3.538 new file mode 100644 index 00000000..947fa65b --- /dev/null +++ b/7.3.538 @@ -0,0 +1,321 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.538 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.538 +Problem: 'efm' does not handle Tabs in pointer lines. +Solution: Add Tab support. Improve tests. (Lech Lorens) +Files: src/quickfix.c, src/testdir/test10.in, src/testdir/test10.ok + + +*** ../vim-7.3.537/src/quickfix.c 2012-04-25 18:57:17.000000000 +0200 +--- src/quickfix.c 2012-06-01 18:24:07.000000000 +0200 +*************** +*** 247,253 **** + {'t', "."}, + {'m', ".\\+"}, + {'r', ".*"}, +! {'p', "[- .]*"}, + {'v', "\\d\\+"}, + {'s', ".\\+"} + }; +--- 247,253 ---- + {'t', "."}, + {'m', ".\\+"}, + {'r', ".*"}, +! {'p', "[- .]*"}, + {'v', "\\d\\+"}, + {'s', ".\\+"} + }; +*************** +*** 677,687 **** + } + if ((i = (int)fmt_ptr->addr[7]) > 0) /* %p */ + { + if (regmatch.startp[i] == NULL || regmatch.endp[i] == NULL) + continue; +! col = (int)(regmatch.endp[i] - regmatch.startp[i] + 1); +! if (*((char_u *)regmatch.startp[i]) != TAB) +! use_viscol = TRUE; + } + if ((i = (int)fmt_ptr->addr[8]) > 0) /* %v */ + { +--- 677,699 ---- + } + if ((i = (int)fmt_ptr->addr[7]) > 0) /* %p */ + { ++ char_u *match_ptr; ++ + if (regmatch.startp[i] == NULL || regmatch.endp[i] == NULL) + continue; +! col = 0; +! for (match_ptr = regmatch.startp[i]; +! match_ptr != regmatch.endp[i]; ++match_ptr) +! { +! ++col; +! if (*match_ptr == TAB) +! { +! col += 7; +! col -= col % 8; +! } +! } +! ++col; +! use_viscol = TRUE; + } + if ((i = (int)fmt_ptr->addr[8]) > 0) /* %v */ + { +*** ../vim-7.3.537/src/testdir/test10.in 2011-08-10 18:36:49.000000000 +0200 +--- src/testdir/test10.in 2012-06-01 18:22:40.000000000 +0200 +*************** +*** 8,48 **** + :7/start of errorfile/,/end of errorfile/w! Xerrorfile1 + :7/start of errorfile/,/end of errorfile/-1w! Xerrorfile2 + :/start of testfile/,/end of testfile/w! Xtestfile + :cf Xerrorfile2 + :clast + :copen + :let a=w:quickfix_title + :wincmd p +! gR=a  + :cf Xerrorfile1 +! rA + :cn +! rB + :cn +! rC + :cn +! rD + :cn +! rE + :cn + :wincmd w + :let a=w:quickfix_title + :wincmd p +! gR=a  + :w! test.out " Write contents of this file + :qa! + ENDTEST + + start of errorfile + "Xtestfile", line 4.12: 1506-045 (S) Undeclared identifier fd_set. +! "Xtestfile", line 7 col 19; this is an error + gcc -c -DHAVE_CONFIsing-prototypes -I/usr/X11R6/include version.c +! Xtestfile:13: parse error before `asd' + make: *** [vim] Error 1 +! in file "Xtestfile" linenr 16: there is an error + + 2 returned +! "Xtestfile", linenr 19: yet another problem + + Does anyone know what is the problem and how to correction it? + "Xtestfile", line 21 col 9: What is the title of the quickfix window? +--- 8,88 ---- + :7/start of errorfile/,/end of errorfile/w! Xerrorfile1 + :7/start of errorfile/,/end of errorfile/-1w! Xerrorfile2 + :/start of testfile/,/end of testfile/w! Xtestfile ++ :set efm+==%f=\\,\ line\ %l%*\\D%v%*[^\ ]\ %m ++ :set efm^=%AError\ in\ \"%f\"\ at\ line\ %l:,%Z%p^,%C%m + :cf Xerrorfile2 + :clast + :copen + :let a=w:quickfix_title + :wincmd p +! lgR=a  + :cf Xerrorfile1 +! grA + :cn +! gRLINE 6, COL 19 + :cn +! gRNO COLUMN SPECIFIED + :cn +! gRAGAIN NO COLUMN + :cn +! gRCOL 1 + :cn ++ gRCOL 2 ++ :cn ++ gRCOL 10 ++ :cn ++ gRVCOL 10 ++ :cn ++ grI ++ :cn ++ gR. SPACE POINTER ++ :cn ++ gR. DOT POINTER ++ :cn ++ gR. DASH POINTER ++ :cn ++ gR. TAB-SPACE POINTER ++ :clast ++ :cprev ++ :cprev + :wincmd w + :let a=w:quickfix_title + :wincmd p +! lgR=a  + :w! test.out " Write contents of this file + :qa! + ENDTEST + + start of errorfile + "Xtestfile", line 4.12: 1506-045 (S) Undeclared identifier fd_set. +! "Xtestfile", line 6 col 19; this is an error + gcc -c -DHAVE_CONFIsing-prototypes -I/usr/X11R6/include version.c +! Xtestfile:9: parse error before `asd' + make: *** [vim] Error 1 +! in file "Xtestfile" linenr 10: there is an error + + 2 returned +! "Xtestfile", line 11 col 1; this is an error +! "Xtestfile", line 12 col 2; this is another error +! "Xtestfile", line 14:10; this is an error in column 10 +! =Xtestfile=, line 15:10; this is another error, but in vcol 10 this time +! "Xtestfile", linenr 16: yet another problem +! Error in "Xtestfile" at line 17: +! x should be a dot +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 17 +! ^ +! Error in "Xtestfile" at line 18: +! x should be a dot +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 18 +! .............^ +! Error in "Xtestfile" at line 19: +! x should be a dot +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 19 +! --------------^ +! Error in "Xtestfile" at line 20: +! x should be a dot +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 20 +! ^ + + Does anyone know what is the problem and how to correction it? + "Xtestfile", line 21 col 9: What is the title of the quickfix window? +*************** +*** 50,74 **** + end of errorfile + + start of testfile +! line 2 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 3 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 4 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 5 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 6 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 7 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 8 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 9 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 10 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 11 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 12 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 13 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 14 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 15 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 16 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 17 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 18 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 19 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 20 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 21 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 22 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx + end of testfile +--- 90,114 ---- + end of errorfile + + start of testfile +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 2 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 3 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 4 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 5 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 6 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 7 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 8 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 9 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 10 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 11 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 12 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 13 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 14 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 15 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 16 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 17 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 18 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 19 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 20 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 21 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 22 + end of testfile +*** ../vim-7.3.537/src/testdir/test10.ok 2011-08-10 18:36:49.000000000 +0200 +--- src/testdir/test10.ok 2012-06-01 18:22:40.000000000 +0200 +*************** +*** 1,23 **** + start of testfile +! line 2 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 3 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 4 xxxAxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 5 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 6 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 7 xxxxxxxxxxBxxxxxxxxxxxxxxxxxxx +! line 8 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 9 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 10 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 11 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 12 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! Cine 13 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 14 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 15 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! Dine 16 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 17 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 18 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! Eine 19 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 20 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +! line 21 :cf Xerrorfile1xxxxxxxxxxxxxxx +! line 22 :cf Xerrorfile2xxxxxxxxxxxxxxx + end of testfile +--- 1,23 ---- + start of testfile +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 2 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 3 +! xxxxxxxxxxAxxxxxxxxxxxxxxxxxxx line 4 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 5 +! xxxxxxxxxxxxxxxxxLINE 6, COL 19 line 6 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 7 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 8 +! NO COLUMN SPECIFIEDxxxxxxxxxxx line 9 +! AGAIN NO COLUMNxxxxxxxxxxxxxxx line 10 +! COL 1 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 11 +! COL 2xxxxxxxxxxxxxxxxxxxxxxxxx line 12 +! xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 13 +! xxxxxxxxCOL 10xxxxxxxxxxxxxxxx line 14 +! xVCOL 10xxxxxxxxxxxxxxxxxxxxxx line 15 +! Ixxxxxxxxxxxxxxxxxxxxxxxxxxxxx line 16 +! xxxx. SPACE POINTERxxxxxxxxxxx line 17 +! xxxxx. DOT POINTERxxxxxxxxxxxx line 18 +! xxxxxx. DASH POINTERxxxxxxxxxx line 19 +! xxxxxxx. TAB-SPACE POINTERxxxx line 20 +! xxxxxxxx:cf Xerrorfile1xxxxxxx line 21 +! xxxxxxxx:cf Xerrorfile2xxxxxxx line 22 + end of testfile +*** ../vim-7.3.537/src/version.c 2012-06-01 17:49:51.000000000 +0200 +--- src/version.c 2012-06-01 18:22:27.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 538, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +18. Your wife drapes a blond wig over your monitor to remind you of what she + looks like. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8ff69719177f6d4f51342ceb8df4309af8d11e1c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:58 +0200 Subject: [PATCH 0281/3340] - patchlevel 539 --- 7.3.539 | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 7.3.539 diff --git a/7.3.539 b/7.3.539 new file mode 100644 index 00000000..267c076d --- /dev/null +++ b/7.3.539 @@ -0,0 +1,51 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.539 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.539 +Problem: Redrawing a character on the command line does not work properly + for multi-byte charactes. +Solution: Count the number of bytes in a character. (Yukihiro Nakadaira) +Files: src/ex_getln.c + + +*** ../vim-7.3.538/src/ex_getln.c 2012-05-25 11:02:34.000000000 +0200 +--- src/ex_getln.c 2012-06-06 11:50:37.000000000 +0200 +*************** +*** 2764,2769 **** +--- 2764,2774 ---- + msg_no_more = TRUE; + if (ccline.cmdlen == ccline.cmdpos) + msg_putchar(' '); ++ #ifdef FEAT_MBYTE ++ else if (has_mbyte) ++ draw_cmdline(ccline.cmdpos, ++ (*mb_ptr2len)(ccline.cmdbuff + ccline.cmdpos)); ++ #endif + else + draw_cmdline(ccline.cmdpos, 1); + msg_no_more = FALSE; +*** ../vim-7.3.538/src/version.c 2012-06-01 18:34:37.000000000 +0200 +--- src/version.c 2012-06-06 12:02:45.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 539, + /**/ + +-- +If they don't keep on exercising their lips, he thought, their brains +start working. + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 906683b671f97b77d676f820434aaf1c60f8d5b9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:59 +0200 Subject: [PATCH 0282/3340] - patchlevel 540 --- 7.3.540 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.540 diff --git a/7.3.540 b/7.3.540 new file mode 100644 index 00000000..6793eb43 --- /dev/null +++ b/7.3.540 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.540 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.540 +Problem: Cursor is left on the text instead of the command line. +Solution: Don't call setcursor() in command line mode. +Files: src/getchar.c + + +*** ../vim-7.3.539/src/getchar.c 2012-06-01 15:20:49.000000000 +0200 +--- src/getchar.c 2012-06-06 11:58:05.000000000 +0200 +*************** +*** 2819,2825 **** + edit_unputchar(); + if (State & CMDLINE) + unputcmdline(); +! setcursor(); /* put cursor back where it belongs */ + } + + if (c < 0) +--- 2819,2826 ---- + edit_unputchar(); + if (State & CMDLINE) + unputcmdline(); +! else +! setcursor(); /* put cursor back where it belongs */ + } + + if (c < 0) +*** ../vim-7.3.539/src/version.c 2012-06-06 12:02:57.000000000 +0200 +--- src/version.c 2012-06-06 12:05:22.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 540, + /**/ + +-- +"Making it up? Why should I want to make anything up? Life's bad enough +as it is without wanting to invent any more of it." + -- Marvin, the Paranoid Android in Douglas Adams' + "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a660e131e3f9a309044dede87ee9026a5a06ea70 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:59 +0200 Subject: [PATCH 0283/3340] - patchlevel 541 --- 7.3.541 | 1090 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1090 insertions(+) create mode 100644 7.3.541 diff --git a/7.3.541 b/7.3.541 new file mode 100644 index 00000000..133b82da --- /dev/null +++ b/7.3.541 @@ -0,0 +1,1090 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.541 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.541 +Problem: When joining lines comment leaders need to be removed manually. +Solution: Add the 'j' flag to 'formatoptions'. (Lech Lorens) +Files: runtime/doc/change.txt, src/edit.c, src/ex_docmd.c, src/misc1.c, + src/normal.c, src/ops.c, src/option.h, src/proto/misc1.pro, + src/proto/ops.pro, src/search.c, src/testdir/test29.in, + src/testdir/test29.ok + + +*** ../vim-7.3.540/runtime/doc/change.txt 2011-05-05 14:26:37.000000000 +0200 +--- runtime/doc/change.txt 2012-06-06 13:05:04.000000000 +0200 +*************** +*** 1495,1500 **** +--- 1522,1533 ---- + characters. Overruled by the 'M' flag. + 1 Don't break a line after a one-letter word. It's broken before it + instead (if possible). ++ j Where it makes sense, remove a comment leader when joining lines. For ++ example, joining: ++ int i; // the index ~ ++ // in the list ~ ++ Becomes: ++ int i; // the index in the list ~ + + + With 't' and 'c' you can specify when Vim performs auto-wrapping: +*** ../vim-7.3.540/src/edit.c 2012-06-01 15:20:49.000000000 +0200 +--- src/edit.c 2012-06-06 13:00:29.000000000 +0200 +*************** +*** 5847,5853 **** + * Need to remove existing (middle) comment leader and insert end + * comment leader. First, check what comment leader we can find. + */ +! i = get_leader_len(line = ml_get_curline(), &p, FALSE); + if (i > 0 && vim_strchr(p, COM_MIDDLE) != NULL) /* Just checking */ + { + /* Skip middle-comment string */ +--- 5847,5853 ---- + * Need to remove existing (middle) comment leader and insert end + * comment leader. First, check what comment leader we can find. + */ +! i = get_leader_len(line = ml_get_curline(), &p, FALSE, TRUE); + if (i > 0 && vim_strchr(p, COM_MIDDLE) != NULL) /* Just checking */ + { + /* Skip middle-comment string */ +*************** +*** 6085,6091 **** + + /* Don't break until after the comment leader */ + if (do_comments) +! leader_len = get_leader_len(ml_get_curline(), NULL, FALSE); + else + leader_len = 0; + +--- 6085,6091 ---- + + /* Don't break until after the comment leader */ + if (do_comments) +! leader_len = get_leader_len(ml_get_curline(), NULL, FALSE, TRUE); + else + leader_len = 0; + +*************** +*** 6411,6417 **** + /* With the 'c' flag in 'formatoptions' and 't' missing: only format + * comments. */ + if (has_format_option(FO_WRAP_COMS) && !has_format_option(FO_WRAP) +! && get_leader_len(old, NULL, FALSE) == 0) + return; + #endif + +--- 6411,6417 ---- + /* With the 'c' flag in 'formatoptions' and 't' missing: only format + * comments. */ + if (has_format_option(FO_WRAP_COMS) && !has_format_option(FO_WRAP) +! && get_leader_len(old, NULL, FALSE, TRUE) == 0) + return; + #endif + +*************** +*** 8565,8571 **** + { + temp = curwin->w_cursor.col; + if (!can_bs(BS_EOL) /* only if "eol" included */ +! || do_join(2, FALSE, TRUE) == FAIL) + vim_beep(); + else + curwin->w_cursor.col = temp; +--- 8565,8571 ---- + { + temp = curwin->w_cursor.col; + if (!can_bs(BS_EOL) /* only if "eol" included */ +! || do_join(2, FALSE, TRUE, FALSE) == FAIL) + vim_beep(); + else + curwin->w_cursor.col = temp; +*************** +*** 8746,8752 **** + ptr[len - 1] = NUL; + } + +! (void)do_join(2, FALSE, FALSE); + if (temp == NUL && gchar_cursor() != NUL) + inc_cursor(); + } +--- 8746,8752 ---- + ptr[len - 1] = NUL; + } + +! (void)do_join(2, FALSE, FALSE, FALSE); + if (temp == NUL && gchar_cursor() != NUL) + inc_cursor(); + } +*** ../vim-7.3.540/src/ex_docmd.c 2012-04-30 18:48:38.000000000 +0200 +--- src/ex_docmd.c 2012-06-06 13:00:29.000000000 +0200 +*************** +*** 8545,8551 **** + } + ++eap->line2; + } +! (void)do_join(eap->line2 - eap->line1 + 1, !eap->forceit, TRUE); + beginline(BL_WHITE | BL_FIX); + ex_may_print(eap); + } +--- 8545,8551 ---- + } + ++eap->line2; + } +! (void)do_join(eap->line2 - eap->line1 + 1, !eap->forceit, TRUE, TRUE); + beginline(BL_WHITE | BL_FIX); + ex_may_print(eap); + } +*** ../vim-7.3.540/src/misc1.c 2012-06-01 15:20:49.000000000 +0200 +--- src/misc1.c 2012-06-06 13:27:32.000000000 +0200 +*************** +*** 671,677 **** + ptr = saved_line; + # ifdef FEAT_COMMENTS + if (flags & OPENLINE_DO_COM) +! lead_len = get_leader_len(ptr, NULL, FALSE); + else + lead_len = 0; + # endif +--- 671,677 ---- + ptr = saved_line; + # ifdef FEAT_COMMENTS + if (flags & OPENLINE_DO_COM) +! lead_len = get_leader_len(ptr, NULL, FALSE, TRUE); + else + lead_len = 0; + # endif +*************** +*** 693,699 **** + } + # ifdef FEAT_COMMENTS + if (flags & OPENLINE_DO_COM) +! lead_len = get_leader_len(ptr, NULL, FALSE); + else + lead_len = 0; + if (lead_len > 0) +--- 693,699 ---- + } + # ifdef FEAT_COMMENTS + if (flags & OPENLINE_DO_COM) +! lead_len = get_leader_len(ptr, NULL, FALSE, TRUE); + else + lead_len = 0; + if (lead_len > 0) +*************** +*** 836,842 **** + */ + end_comment_pending = NUL; + if (flags & OPENLINE_DO_COM) +! lead_len = get_leader_len(saved_line, &lead_flags, dir == BACKWARD); + else + lead_len = 0; + if (lead_len > 0) +--- 836,842 ---- + */ + end_comment_pending = NUL; + if (flags & OPENLINE_DO_COM) +! lead_len = get_leader_len(saved_line, &lead_flags, dir == BACKWARD, TRUE); + else + lead_len = 0; + if (lead_len > 0) +*************** +*** 1548,1561 **** + * When "flags" is not NULL, it is set to point to the flags of the recognized + * comment leader. + * "backward" must be true for the "O" command. + */ + int +! get_leader_len(line, flags, backward) + char_u *line; + char_u **flags; + int backward; + { + int i, j; + int got_com = FALSE; + int found_one; + char_u part_buf[COM_MAX_LEN]; /* buffer for one option part */ +--- 1548,1565 ---- + * When "flags" is not NULL, it is set to point to the flags of the recognized + * comment leader. + * "backward" must be true for the "O" command. ++ * If "include_space" is set, include trailing whitespace while calculating the ++ * length. + */ + int +! get_leader_len(line, flags, backward, include_space) + char_u *line; + char_u **flags; + int backward; ++ int include_space; + { + int i, j; ++ int result; + int got_com = FALSE; + int found_one; + char_u part_buf[COM_MAX_LEN]; /* buffer for one option part */ +*************** +*** 1565,1571 **** + char_u *prev_list; + char_u *saved_flags = NULL; + +! i = 0; + while (vim_iswhite(line[i])) /* leading white space is ignored */ + ++i; + +--- 1569,1575 ---- + char_u *prev_list; + char_u *saved_flags = NULL; + +! result = i = 0; + while (vim_iswhite(line[i])) /* leading white space is ignored */ + ++i; + +*************** +*** 1668,1684 **** + if (!found_one) + break; + + /* Include any trailing white space. */ + while (vim_iswhite(line[i])) + ++i; + + /* If this comment doesn't nest, stop here. */ + got_com = TRUE; + if (vim_strchr(part_buf, COM_NEST) == NULL) + break; + } + +! return (got_com ? i : 0); + } + #endif + +--- 1672,1838 ---- + if (!found_one) + break; + ++ result = i; ++ + /* Include any trailing white space. */ + while (vim_iswhite(line[i])) + ++i; + ++ if (include_space) ++ result = i; ++ + /* If this comment doesn't nest, stop here. */ + got_com = TRUE; + if (vim_strchr(part_buf, COM_NEST) == NULL) + break; + } ++ return result; ++ } ++ ++ /* ++ * Return the offset at which the last comment in line starts. If there is no ++ * comment in the whole line, -1 is returned. ++ * ++ * When "flags" is not null, it is set to point to the flags describing the ++ * recognized comment leader. ++ */ ++ int ++ get_last_leader_offset(line, flags) ++ char_u *line; ++ char_u **flags; ++ { ++ int result = -1; ++ int i, j; ++ int lower_check_bound = 0; ++ char_u *string; ++ char_u *com_leader; ++ char_u *com_flags; ++ char_u *list; ++ int found_one; ++ char_u part_buf[COM_MAX_LEN]; /* buffer for one option part */ ++ ++ /* ++ * Repeat to match several nested comment strings. ++ */ ++ i = (int)STRLEN(line); ++ while (--i >= lower_check_bound) ++ { ++ /* ++ * scan through the 'comments' option for a match ++ */ ++ found_one = FALSE; ++ for (list = curbuf->b_p_com; *list; ) ++ { ++ char_u *flags_save = list; ++ ++ /* ++ * Get one option part into part_buf[]. Advance list to next one. ++ * put string at start of string. ++ */ ++ (void)copy_option_part(&list, part_buf, COM_MAX_LEN, ","); ++ string = vim_strchr(part_buf, ':'); ++ if (string == NULL) /* If everything is fine, this cannot actually ++ * happen. */ ++ { ++ continue; ++ } ++ *string++ = NUL; /* Isolate flags from string. */ ++ com_leader = string; ++ ++ /* ++ * Line contents and string must match. ++ * When string starts with white space, must have some white space ++ * (but the amount does not need to match, there might be a mix of ++ * TABs and spaces). ++ */ ++ if (vim_iswhite(string[0])) ++ { ++ if (i == 0 || !vim_iswhite(line[i - 1])) ++ continue; ++ while (vim_iswhite(string[0])) ++ ++string; ++ } ++ for (j = 0; string[j] != NUL && string[j] == line[i + j]; ++j) ++ /* do nothing */; ++ if (string[j] != NUL) ++ continue; ++ ++ /* ++ * When 'b' flag used, there must be white space or an ++ * end-of-line after the string in the line. ++ */ ++ if (vim_strchr(part_buf, COM_BLANK) != NULL ++ && !vim_iswhite(line[i + j]) && line[i + j] != NUL) ++ { ++ continue; ++ } ++ ++ /* ++ * We have found a match, stop searching. ++ */ ++ found_one = TRUE; ++ ++ if (flags) ++ *flags = flags_save; ++ com_flags = flags_save; ++ ++ break; ++ } + +! if (found_one) +! { +! char_u part_buf2[COM_MAX_LEN]; /* buffer for one option part */ +! int len1, len2, off; +! +! result = i; +! /* +! * If this comment nests, continue searching. +! */ +! if (vim_strchr(part_buf, COM_NEST) != NULL) +! continue; +! +! lower_check_bound = i; +! +! /* Let's verify whether the comment leader found is a substring +! * of other comment leaders. If it is, let's adjust the +! * lower_check_bound so that we make sure that we have determined +! * the comment leader correctly. +! */ +! +! while (vim_iswhite(*com_leader)) +! ++com_leader; +! len1 = (int)STRLEN(com_leader); +! +! for (list = curbuf->b_p_com; *list; ) +! { +! char_u *flags_save = list; +! +! (void)copy_option_part(&list, part_buf2, COM_MAX_LEN, ","); +! if (flags_save == com_flags) +! continue; +! string = vim_strchr(part_buf2, ':'); +! ++string; +! while (vim_iswhite(*string)) +! ++string; +! len2 = (int)STRLEN(string); +! if (len2 == 0) +! continue; +! +! /* Now we have to verify whether string ends with a substring +! * beginning the com_leader. */ +! for (off = (len2 > i ? i : len2); off > 0 && off + len1 > len2;) +! { +! --off; +! if (!STRNCMP(string + off, com_leader, len2 - off)) +! { +! if (i - off < lower_check_bound) +! lower_check_bound = i - off; +! } +! } +! } +! } +! } +! return result; + } + #endif + +*** ../vim-7.3.540/src/normal.c 2012-05-25 13:12:33.000000000 +0200 +--- src/normal.c 2012-06-06 13:00:29.000000000 +0200 +*************** +*** 1968,1974 **** + beep_flush(); + else + { +! (void)do_join(oap->line_count, oap->op_type == OP_JOIN, TRUE); + auto_format(FALSE, TRUE); + } + break; +--- 1968,1974 ---- + beep_flush(); + else + { +! (void)do_join(oap->line_count, oap->op_type == OP_JOIN, TRUE, TRUE); + auto_format(FALSE, TRUE); + } + break; +*************** +*** 4426,4432 **** + break; + } + #ifdef FEAT_COMMENTS +! if (get_leader_len(ml_get_curline(), NULL, FALSE) > 0) + { + /* Ignore this line, continue at start of next line. */ + ++curwin->w_cursor.lnum; +--- 4426,4432 ---- + break; + } + #ifdef FEAT_COMMENTS +! if (get_leader_len(ml_get_curline(), NULL, FALSE, TRUE) > 0) + { + /* Ignore this line, continue at start of next line. */ + ++curwin->w_cursor.lnum; +*************** +*** 9324,9330 **** + { + prep_redo(cap->oap->regname, cap->count0, + NUL, cap->cmdchar, NUL, NUL, cap->nchar); +! (void)do_join(cap->count0, cap->nchar == NUL, TRUE); + } + } + } +--- 9324,9330 ---- + { + prep_redo(cap->oap->regname, cap->count0, + NUL, cap->cmdchar, NUL, NUL, cap->nchar); +! (void)do_join(cap->count0, cap->nchar == NUL, TRUE, TRUE); + } + } + } +*** ../vim-7.3.540/src/ops.c 2012-05-18 12:49:33.000000000 +0200 +--- src/ops.c 2012-06-06 15:43:31.000000000 +0200 +*************** +*** 112,117 **** +--- 112,120 ---- + # endif + #endif + static void dis_msg __ARGS((char_u *p, int skip_esc)); ++ #if defined(FEAT_COMMENTS) || defined(PROTO) ++ static char_u *skip_comment __ARGS((char_u *line, int process, int include_space, int *is_comment)); ++ #endif + #ifdef FEAT_VISUAL + static void block_prep __ARGS((oparg_T *oap, struct block_def *, linenr_T, int)); + #endif +*************** +*** 1987,1993 **** + curwin->w_cursor = curpos; /* restore curwin->w_cursor */ + } + if (curwin->w_cursor.lnum < curbuf->b_ml.ml_line_count) +! (void)do_join(2, FALSE, FALSE); + } + } + +--- 1990,1996 ---- + curwin->w_cursor = curpos; /* restore curwin->w_cursor */ + } + if (curwin->w_cursor.lnum < curbuf->b_ml.ml_line_count) +! (void)do_join(2, FALSE, FALSE, FALSE); + } + } + +*************** +*** 4197,4213 **** + ui_breakcheck(); + } + + /* + * Join 'count' lines (minimal 2) at cursor position. + * When "save_undo" is TRUE save lines for undo first. + * + * return FAIL for failure, OK otherwise + */ + int +! do_join(count, insert_space, save_undo) + long count; + int insert_space; + int save_undo; + { + char_u *curr = NULL; + char_u *curr_start = NULL; +--- 4200,4297 ---- + ui_breakcheck(); + } + ++ #if defined(FEAT_COMMENTS) || defined(PROTO) ++ /* ++ * If "process" is TRUE and the line begins with a comment leader (possibly ++ * after some white space), return a pointer to the text after it. Put a boolean ++ * value indicating whether the line ends with an unclosed comment in ++ * "is_comment". ++ * line - line to be processed, ++ * process - if FALSE, will only check whether the line ends with an unclosed ++ * comment, ++ * include_space - whether to also skip space following the comment leader, ++ * is_comment - will indicate whether the current line ends with an unclosed ++ * comment. ++ */ ++ static char_u * ++ skip_comment(line, process, include_space, is_comment) ++ char_u *line; ++ int process; ++ int include_space; ++ int *is_comment; ++ { ++ char_u *comment_flags = NULL; ++ int lead_len; ++ int leader_offset = get_last_leader_offset(line, &comment_flags); ++ ++ *is_comment = FALSE; ++ if (leader_offset != -1) ++ { ++ /* Let's check whether the line ends with an unclosed comment. ++ * If the last comment leader has COM_END in flags, there's no comment. ++ */ ++ while (*comment_flags) ++ { ++ if (*comment_flags == COM_END ++ || *comment_flags == ':') ++ break; ++ ++comment_flags; ++ } ++ if (*comment_flags != COM_END) ++ *is_comment = TRUE; ++ } ++ ++ if (process == FALSE) ++ return line; ++ ++ lead_len = get_leader_len(line, &comment_flags, FALSE, include_space); ++ ++ if (lead_len == 0) ++ return line; ++ ++ /* Find: ++ * - COM_START, ++ * - COM_END, ++ * - colon, ++ * whichever comes first. ++ */ ++ while (*comment_flags) ++ { ++ if (*comment_flags == COM_START ++ || *comment_flags == COM_END ++ || *comment_flags == ':') ++ { ++ break; ++ } ++ ++comment_flags; ++ } ++ ++ /* If we found a colon, it means that we are not processing a line ++ * starting with an opening or a closing part of a three-part ++ * comment. That's good, because we don't want to remove those as ++ * this would be annoying. ++ */ ++ if (*comment_flags == ':' || *comment_flags == NUL) ++ line += lead_len; ++ ++ return line; ++ } ++ #endif ++ + /* + * Join 'count' lines (minimal 2) at cursor position. + * When "save_undo" is TRUE save lines for undo first. ++ * Set "use_formatoptions" to FALSE when e.g. processing ++ * backspace and comment leaders should not be removed. + * + * return FAIL for failure, OK otherwise + */ + int +! do_join(count, insert_space, save_undo, use_formatoptions) + long count; + int insert_space; + int save_undo; ++ int use_formatoptions UNUSED; + { + char_u *curr = NULL; + char_u *curr_start = NULL; +*************** +*** 4221,4226 **** +--- 4305,4317 ---- + linenr_T t; + colnr_T col = 0; + int ret = OK; ++ #if defined(FEAT_COMMENTS) || defined(PROTO) ++ int *comments; ++ int remove_comments = (use_formatoptions == TRUE) ++ && has_format_option(FO_REMOVE_COMS); ++ int prev_was_comment; ++ #endif ++ + + if (save_undo && u_save((linenr_T)(curwin->w_cursor.lnum - 1), + (linenr_T)(curwin->w_cursor.lnum + count)) == FAIL) +*************** +*** 4232,4237 **** +--- 4323,4339 ---- + spaces = lalloc_clear((long_u)count, TRUE); + if (spaces == NULL) + return FAIL; ++ #if defined(FEAT_COMMENTS) || defined(PROTO) ++ if (remove_comments) ++ { ++ comments = (int *)lalloc_clear((long_u)count * sizeof(int), TRUE); ++ if (comments == NULL) ++ { ++ vim_free(spaces); ++ return FAIL; ++ } ++ } ++ #endif + + /* + * Don't move anything, just compute the final line length +*************** +*** 4240,4245 **** +--- 4342,4366 ---- + for (t = 0; t < count; ++t) + { + curr = curr_start = ml_get((linenr_T)(curwin->w_cursor.lnum + t)); ++ #if defined(FEAT_COMMENTS) || defined(PROTO) ++ if (remove_comments) ++ { ++ /* We don't want to remove the comment leader if the ++ * previous line is not a comment. */ ++ if (t > 0 && prev_was_comment) ++ { ++ ++ char_u *new_curr = skip_comment(curr, TRUE, insert_space, ++ &prev_was_comment); ++ comments[t] = new_curr - curr; ++ curr = new_curr; ++ } ++ else ++ curr = skip_comment(curr, FALSE, insert_space, ++ &prev_was_comment); ++ } ++ #endif ++ + if (insert_space && t > 0) + { + curr = skipwhite(curr); +*************** +*** 4327,4332 **** +--- 4448,4457 ---- + if (t == 0) + break; + curr = curr_start = ml_get((linenr_T)(curwin->w_cursor.lnum + t - 1)); ++ #if defined(FEAT_COMMENTS) || defined(PROTO) ++ if (remove_comments) ++ curr += comments[t - 1]; ++ #endif + if (insert_space && t > 1) + curr = skipwhite(curr); + currsize = (int)STRLEN(curr); +*************** +*** 4364,4369 **** +--- 4489,4498 ---- + + theend: + vim_free(spaces); ++ #if defined(FEAT_COMMENTS) || defined(PROTO) ++ if (remove_comments) ++ vim_free(comments); ++ #endif + return ret; + } + +*************** +*** 4788,4794 **** + (long)-next_leader_len); + #endif + curwin->w_cursor.lnum--; +! if (do_join(2, TRUE, FALSE) == FAIL) + { + beep_flush(); + break; +--- 4917,4923 ---- + (long)-next_leader_len); + #endif + curwin->w_cursor.lnum--; +! if (do_join(2, TRUE, FALSE, FALSE) == FAIL) + { + beep_flush(); + break; +*************** +*** 4844,4850 **** + + ptr = ml_get(lnum); + if (do_comments) +! *leader_len = get_leader_len(ptr, leader_flags, FALSE); + else + *leader_len = 0; + +--- 4973,4979 ---- + + ptr = ml_get(lnum); + if (do_comments) +! *leader_len = get_leader_len(ptr, leader_flags, FALSE, TRUE); + else + *leader_len = 0; + +*** ../vim-7.3.540/src/option.h 2012-02-20 22:18:22.000000000 +0100 +--- src/option.h 2012-06-06 13:00:29.000000000 +0200 +*************** +*** 104,113 **** + #define FO_ONE_LETTER '1' + #define FO_WHITE_PAR 'w' /* trailing white space continues paragr. */ + #define FO_AUTO 'a' /* automatic formatting */ + + #define DFLT_FO_VI "vt" + #define DFLT_FO_VIM "tcq" +! #define FO_ALL "tcroq2vlb1mMBn,aw" /* for do_set() */ + + /* characters for the p_cpo option: */ + #define CPO_ALTREAD 'a' /* ":read" sets alternate file name */ +--- 104,114 ---- + #define FO_ONE_LETTER '1' + #define FO_WHITE_PAR 'w' /* trailing white space continues paragr. */ + #define FO_AUTO 'a' /* automatic formatting */ ++ #define FO_REMOVE_COMS 'j' /* remove comment leaders when joining lines */ + + #define DFLT_FO_VI "vt" + #define DFLT_FO_VIM "tcq" +! #define FO_ALL "tcroq2vlb1mMBn,awj" /* for do_set() */ + + /* characters for the p_cpo option: */ + #define CPO_ALTREAD 'a' /* ":read" sets alternate file name */ +*** ../vim-7.3.540/src/proto/misc1.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/misc1.pro 2012-06-06 13:00:29.000000000 +0200 +*************** +*** 6,12 **** + int set_indent __ARGS((int size, int flags)); + int get_number_indent __ARGS((linenr_T lnum)); + int open_line __ARGS((int dir, int flags, int old_indent)); +! int get_leader_len __ARGS((char_u *line, char_u **flags, int backward)); + int plines __ARGS((linenr_T lnum)); + int plines_win __ARGS((win_T *wp, linenr_T lnum, int winheight)); + int plines_nofill __ARGS((linenr_T lnum)); +--- 6,13 ---- + int set_indent __ARGS((int size, int flags)); + int get_number_indent __ARGS((linenr_T lnum)); + int open_line __ARGS((int dir, int flags, int old_indent)); +! int get_leader_len __ARGS((char_u *line, char_u **flags, int backward, int do_skip_space)); +! int get_last_leader_offset __ARGS((char_u *line, char_u **flags)); + int plines __ARGS((linenr_T lnum)); + int plines_win __ARGS((win_T *wp, linenr_T lnum, int winheight)); + int plines_nofill __ARGS((linenr_T lnum)); +*** ../vim-7.3.540/src/proto/ops.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/ops.pro 2012-06-06 13:00:29.000000000 +0200 +*************** +*** 36,42 **** + int preprocs_left __ARGS((void)); + int get_register_name __ARGS((int num)); + void ex_display __ARGS((exarg_T *eap)); +! int do_join __ARGS((long count, int insert_space, int save_undo)); + void op_format __ARGS((oparg_T *oap, int keep_cursor)); + void op_formatexpr __ARGS((oparg_T *oap)); + int fex_format __ARGS((linenr_T lnum, long count, int c)); +--- 36,42 ---- + int preprocs_left __ARGS((void)); + int get_register_name __ARGS((int num)); + void ex_display __ARGS((exarg_T *eap)); +! int do_join __ARGS((long count, int insert_space, int save_undo, int use_formatoptions)); + void op_format __ARGS((oparg_T *oap, int keep_cursor)); + void op_formatexpr __ARGS((oparg_T *oap)); + int fex_format __ARGS((linenr_T lnum, long count, int c)); +*** ../vim-7.3.540/src/search.c 2012-02-04 23:34:57.000000000 +0100 +--- src/search.c 2012-06-06 13:00:29.000000000 +0200 +*************** +*** 1548,1554 **** + int len; + int stop = TRUE; + #ifdef FEAT_MBYTE +! static char_u bytes[MB_MAXBYTES]; + static int bytelen = 1; /* >1 for multi-byte char */ + #endif + +--- 1548,1554 ---- + int len; + int stop = TRUE; + #ifdef FEAT_MBYTE +! static char_u bytes[MB_MAXBYTES + 1]; + static int bytelen = 1; /* >1 for multi-byte char */ + #endif + +*************** +*** 4901,4907 **** + #ifdef FEAT_COMMENTS + if ((*line != '#' || + STRNCMP(skipwhite(line + 1), "define", 6) != 0) +! && get_leader_len(line, NULL, FALSE)) + matched = FALSE; + + /* +--- 4901,4907 ---- + #ifdef FEAT_COMMENTS + if ((*line != '#' || + STRNCMP(skipwhite(line + 1), "define", 6) != 0) +! && get_leader_len(line, NULL, FALSE, TRUE)) + matched = FALSE; + + /* +*** ../vim-7.3.540/src/testdir/test29.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test29.in 2012-06-06 15:44:38.000000000 +0200 +*************** +*** 4,19 **** + and with 'cpoptions' flag 'j' set or not + + STARTTEST + :set nocompatible viminfo+=nviminfo + :set nojoinspaces + :set cpoptions-=j + /firstline/ +! j"tdGpJjJjJjJjJjJjJjJjJjJjJjJjJjJj05lmx2j06lmy2k4Jy3l$p`xyl$p`yy2l$p:set cpoptions+=j + j05lmx2j06lmy2k4Jy3l$p`xyl$p`yy2l$p:set cpoptions-=j joinspaces + j"tpJjJjJjJjJjJjJjJjJjJjJjJjJjJj05lmx2j06lmy2k4Jy3l$p`xyl$p`yy2l$p:set cpoptions+=j + j05lmx2j06lmy2k4Jy3l$p`xyl$p`yy2l$p:set cpoptions-=j nojoinspaces compatible +! j"tpJjJjJjJjJjJjJjJjJjJjJjJjJjJj4Jy3l$pjdG:?firstline?+1,$w! test.out +! :qa! + ENDTEST + + firstline +--- 4,20 ---- + and with 'cpoptions' flag 'j' set or not + + STARTTEST ++ :so small.vim + :set nocompatible viminfo+=nviminfo + :set nojoinspaces + :set cpoptions-=j + /firstline/ +! j"td/^STARTTEST/-1 +! PJjJjJjJjJjJjJjJjJjJjJjJjJjJj05lmx2j06lmy2k4Jy3l$p`xyl$p`yy2l$p:set cpoptions+=j + j05lmx2j06lmy2k4Jy3l$p`xyl$p`yy2l$p:set cpoptions-=j joinspaces + j"tpJjJjJjJjJjJjJjJjJjJjJjJjJjJj05lmx2j06lmy2k4Jy3l$p`xyl$p`yy2l$p:set cpoptions+=j + j05lmx2j06lmy2k4Jy3l$p`xyl$p`yy2l$p:set cpoptions-=j nojoinspaces compatible +! j"tpJjJjJjJjJjJjJjJjJjJjJjJjJjJj4Jy3l$pjd/STARTTEST/-2 + ENDTEST + + firstline +*************** +*** 54,56 **** +--- 55,181 ---- + hjkl iop! + ert + ++ STARTTEST ++ /^{/+1 ++ :set comments=s1:/*,mb:*,ex:*/,:// ++ :set nojoinspaces fo=j ++ :set backspace=eol,start ++ :.,+3join ++ j4J ++ :.,+2join ++ j3J ++ :.,+2join ++ j3J ++ :.,+2join ++ jj3J ++ ENDTEST ++ ++ { ++ ++ /* ++ * Make sure the previous comment leader is not removed. ++ */ ++ ++ /* ++ * Make sure the previous comment leader is not removed. ++ */ ++ ++ // Should the next comment leader be left alone? ++ // Yes. ++ ++ // Should the next comment leader be left alone? ++ // Yes. ++ ++ /* Here the comment leader should be left intact. */ ++ // And so should this one. ++ ++ /* Here the comment leader should be left intact. */ ++ // And so should this one. ++ ++ if (condition) // Remove the next comment leader! ++ // OK, I will. ++ action(); ++ ++ if (condition) // Remove the next comment leader! ++ // OK, I will. ++ action(); ++ } ++ ++ STARTTEST ++ /^{/+1 ++ :set comments=s1:/*,mb:*,ex:*/,:// ++ :set comments+=s1:>#,mb:#,ex:#<,:< ++ :set cpoptions-=j joinspaces fo=j ++ :set backspace=eol,start ++ :.,+3join ++ j4J ++ :.,+2join ++ j3J ++ :.,+2join ++ j3J ++ :.,+2join ++ jj3J ++ j:.,+2join ++ jj3J ++ j:.,+5join ++ j6J ++ oSome code! // Make sure backspacing does not remove this comment leader.0i ++ ENDTEST ++ ++ { ++ ++ /* ++ * Make sure the previous comment leader is not removed. ++ */ ++ ++ /* ++ * Make sure the previous comment leader is not removed. ++ */ ++ ++ // Should the next comment leader be left alone? ++ // Yes. ++ ++ // Should the next comment leader be left alone? ++ // Yes. ++ ++ /* Here the comment leader should be left intact. */ ++ // And so should this one. ++ ++ /* Here the comment leader should be left intact. */ ++ // And so should this one. ++ ++ if (condition) // Remove the next comment leader! ++ // OK, I will. ++ action(); ++ ++ if (condition) // Remove the next comment leader! ++ // OK, I will. ++ action(); ++ ++ int i = 7 /* foo *// 3 ++ // comment ++ ; ++ ++ int i = 7 /* foo *// 3 ++ // comment ++ ; ++ ++ ># Note that the last character of the ending comment leader (left angle ++ # bracket) is a comment leader itself. Make sure that this comment leader is ++ # not removed from the next line #< ++ < On this line a new comment is opened which spans 2 lines. This comment should ++ < retain its comment leader. ++ ++ ># Note that the last character of the ending comment leader (left angle ++ # bracket) is a comment leader itself. Make sure that this comment leader is ++ # not removed from the next line #< ++ < On this line a new comment is opened which spans 2 lines. This comment should ++ < retain its comment leader. ++ ++ } ++ ++ STARTTEST ++ :g/^STARTTEST/.,/^ENDTEST/d ++ :?firstline?+1,$w! test.out ++ :qa! ++ ENDTEST +*** ../vim-7.3.540/src/testdir/test29.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test29.ok 2012-06-06 13:00:29.000000000 +0200 +*************** +*** 47,49 **** +--- 47,86 ---- + asdfasdf asdf + asdfasdf asdf + zx cvn. as dfg? hjkl iop! ert a ++ ++ ++ { ++ /* Make sure the previous comment leader is not removed. */ ++ /* Make sure the previous comment leader is not removed. */ ++ // Should the next comment leader be left alone? Yes. ++ // Should the next comment leader be left alone? Yes. ++ /* Here the comment leader should be left intact. */ // And so should this one. ++ /* Here the comment leader should be left intact. */ // And so should this one. ++ if (condition) // Remove the next comment leader! OK, I will. ++ action(); ++ if (condition) // Remove the next comment leader! OK, I will. ++ action(); ++ } ++ ++ ++ { ++ /* Make sure the previous comment leader is not removed. */ ++ /* Make sure the previous comment leader is not removed. */ ++ // Should the next comment leader be left alone? Yes. ++ // Should the next comment leader be left alone? Yes. ++ /* Here the comment leader should be left intact. */ // And so should this one. ++ /* Here the comment leader should be left intact. */ // And so should this one. ++ if (condition) // Remove the next comment leader! OK, I will. ++ action(); ++ if (condition) // Remove the next comment leader! OK, I will. ++ action(); ++ int i = 7 /* foo *// 3 // comment ++ ; ++ int i = 7 /* foo *// 3 // comment ++ ; ++ ># Note that the last character of the ending comment leader (left angle bracket) is a comment leader itself. Make sure that this comment leader is not removed from the next line #< < On this line a new comment is opened which spans 2 lines. This comment should retain its comment leader. ++ ># Note that the last character of the ending comment leader (left angle bracket) is a comment leader itself. Make sure that this comment leader is not removed from the next line #< < On this line a new comment is opened which spans 2 lines. This comment should retain its comment leader. ++ ++ Some code!// Make sure backspacing does not remove this comment leader. ++ } ++ +*** ../vim-7.3.540/src/version.c 2012-06-06 12:06:10.000000000 +0200 +--- src/version.c 2012-06-06 16:10:03.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 541, + /**/ + +-- +I have a drinking problem -- I don't have a drink! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 95019d12af217bfdbfa9afbde002402234e8826b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:08:59 +0200 Subject: [PATCH 0284/3340] - patchlevel 542 --- 7.3.542 | 73 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 7.3.542 diff --git a/7.3.542 b/7.3.542 new file mode 100644 index 00000000..81086126 --- /dev/null +++ b/7.3.542 @@ -0,0 +1,73 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.542 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.542 (after 7.3.506) +Problem: Function is sometimes unused. +Solution: Add #ifdef. +Files: src/gui_gtk.c + + +*** ../vim-7.3.541/src/gui_gtk.c 2012-04-25 17:10:12.000000000 +0200 +--- src/gui_gtk.c 2012-06-06 15:25:12.000000000 +0200 +*************** +*** 90,100 **** +--- 90,102 ---- + static void entry_activate_cb(GtkWidget *widget, gpointer data); + static void entry_changed_cb(GtkWidget *entry, GtkWidget *dialog); + static void find_replace_cb(GtkWidget *widget, gpointer data); ++ #if defined(FEAT_BROWSE) || defined(PROTO) + static void recent_func_log_func( + const gchar *log_domain, + GLogLevelFlags log_level, + const gchar *message, + gpointer user_data); ++ #endif + + #if defined(FEAT_TOOLBAR) + /* +*************** +*** 1896,1901 **** +--- 1898,1904 ---- + do_cmdline_cmd((char_u *)"emenu ToolBar.FindHelp"); + } + ++ #if defined(FEAT_BROWSE) || defined(PROTO) + static void + recent_func_log_func(const gchar *log_domain UNUSED, + GLogLevelFlags log_level UNUSED, +*************** +*** 1905,1908 **** + /* We just want to suppress the warnings. */ + /* http://bugzilla.gnome.org/show_bug.cgi?id=664587 */ + } +! +--- 1908,1911 ---- + /* We just want to suppress the warnings. */ + /* http://bugzilla.gnome.org/show_bug.cgi?id=664587 */ + } +! #endif +*** ../vim-7.3.541/src/version.c 2012-06-06 16:12:54.000000000 +0200 +--- src/version.c 2012-06-06 16:14:17.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 542, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +1. At lunch time, sit in your parked car with sunglasses on and point + a hair dryer at passing cars. See if they slow down. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 44289bb6b89655322e98f35bd9bc91e517f336e1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:09:00 +0200 Subject: [PATCH 0285/3340] - patchlevel 543 --- 7.3.543 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.543 diff --git a/7.3.543 b/7.3.543 new file mode 100644 index 00000000..3fa569cc --- /dev/null +++ b/7.3.543 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.543 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.543 +Problem: The cursor is in the wrong line after using ":copen". (John + Beckett) +Solution: Invoke more drastic redraw method. +Files: src/eval.c + + +*** ../vim-7.3.542/src/eval.c 2012-06-01 15:20:49.000000000 +0200 +--- src/eval.c 2012-06-06 16:28:11.000000000 +0200 +*************** +*** 18507,18515 **** + curwin->w_skipcol = get_dict_number(dict, (char_u *)"skipcol"); + + check_cursor(); +! changed_cline_bef_curs(); +! invalidate_botline(); +! redraw_later(VALID); + + if (curwin->w_topline == 0) + curwin->w_topline = 1; +--- 18507,18513 ---- + curwin->w_skipcol = get_dict_number(dict, (char_u *)"skipcol"); + + check_cursor(); +! changed_window_setting(); + + if (curwin->w_topline == 0) + curwin->w_topline = 1; +*** ../vim-7.3.542/src/version.c 2012-06-06 16:14:36.000000000 +0200 +--- src/version.c 2012-06-06 16:28:16.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 543, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +2. Page yourself over the intercom. Don't disguise your voice. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From cbae781118553b705001e09bc838844d677b0757 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:09:00 +0200 Subject: [PATCH 0286/3340] - patchlevel 544 --- 7.3.544 | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 7.3.544 diff --git a/7.3.544 b/7.3.544 new file mode 100644 index 00000000..198a6cb1 --- /dev/null +++ b/7.3.544 @@ -0,0 +1,81 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.544 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.544 +Problem: There is no good way to close a quickfix window when closing the + last ordinary window. +Solution: Add the QuitPre autocommand. +Files: src/ex_docmd.c, src/fileio.c, src/vim.h + + +*** ../vim-7.3.543/src/ex_docmd.c 2012-06-06 16:12:54.000000000 +0200 +--- src/ex_docmd.c 2012-06-06 17:58:41.000000000 +0200 +*************** +*** 6458,6463 **** +--- 6458,6464 ---- + return; + } + #ifdef FEAT_AUTOCMD ++ apply_autocmds(EVENT_QUITPRE, NULL, NULL, FALSE, curbuf); + if (curbuf_locked()) + return; + #endif +*** ../vim-7.3.543/src/fileio.c 2012-04-30 17:04:47.000000000 +0200 +--- src/fileio.c 2012-06-06 17:32:12.000000000 +0200 +*************** +*** 7678,7683 **** +--- 7678,7684 ---- + {"MenuPopup", EVENT_MENUPOPUP}, + {"QuickFixCmdPost", EVENT_QUICKFIXCMDPOST}, + {"QuickFixCmdPre", EVENT_QUICKFIXCMDPRE}, ++ {"QuitPre", EVENT_QUITPRE}, + {"RemoteReply", EVENT_REMOTEREPLY}, + {"SessionLoadPost", EVENT_SESSIONLOADPOST}, + {"ShellCmdPost", EVENT_SHELLCMDPOST}, +*** ../vim-7.3.543/src/vim.h 2012-06-01 15:20:49.000000000 +0200 +--- src/vim.h 2012-06-06 17:30:01.000000000 +0200 +*************** +*** 1264,1271 **** + EVENT_INSERTENTER, /* when entering Insert mode */ + EVENT_INSERTLEAVE, /* when leaving Insert mode */ + EVENT_MENUPOPUP, /* just before popup menu is displayed */ +! EVENT_QUICKFIXCMDPOST, /* after :make, :grep etc */ +! EVENT_QUICKFIXCMDPRE, /* before :make, :grep etc */ + EVENT_SESSIONLOADPOST, /* after loading a session file */ + EVENT_STDINREADPOST, /* after reading from stdin */ + EVENT_STDINREADPRE, /* before reading from stdin */ +--- 1264,1272 ---- + EVENT_INSERTENTER, /* when entering Insert mode */ + EVENT_INSERTLEAVE, /* when leaving Insert mode */ + EVENT_MENUPOPUP, /* just before popup menu is displayed */ +! EVENT_QUICKFIXCMDPOST, /* after :make, :grep etc. */ +! EVENT_QUICKFIXCMDPRE, /* before :make, :grep etc. */ +! EVENT_QUITPRE, /* before :quit */ + EVENT_SESSIONLOADPOST, /* after loading a session file */ + EVENT_STDINREADPOST, /* after reading from stdin */ + EVENT_STDINREADPRE, /* before reading from stdin */ +*** ../vim-7.3.543/src/version.c 2012-06-06 16:29:06.000000000 +0200 +--- src/version.c 2012-06-06 18:02:09.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 544, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +3. Every time someone asks you to do something, ask if they want fries + with that. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a777373f9ec2fdc279ceeca000ea51defb1ef053 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:09:00 +0200 Subject: [PATCH 0287/3340] - patchlevel 545 --- 7.3.545 | 359 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 359 insertions(+) create mode 100644 7.3.545 diff --git a/7.3.545 b/7.3.545 new file mode 100644 index 00000000..1bd76ebe --- /dev/null +++ b/7.3.545 @@ -0,0 +1,359 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.545 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.545 +Problem: When closing a window or buffer autocommands may close it too, + causing problems for where the autocommand was invoked from. +Solution: Add the w_closing and b_closing flags. When set disallow ":q" and + ":close" to prevent recursive closing. +Files: src/structs.h, src/buffer.c, src/ex_docmd.c, src/window.c + + +*** ../vim-7.3.544/src/structs.h 2012-02-04 21:57:44.000000000 +0100 +--- src/structs.h 2012-06-06 16:43:34.000000000 +0200 +*************** +*** 1201,1206 **** +--- 1201,1210 ---- + typedef struct qf_info_S qf_info_T; + #endif + ++ /* ++ * These are items normally related to a buffer. But when using ":ownsyntax" ++ * a window may have its own instance. ++ */ + typedef struct { + #ifdef FEAT_SYN_HL + hashtab_T b_keywtab; /* syntax keywords hash table */ +*************** +*** 1290,1295 **** +--- 1294,1303 ---- + int b_nwindows; /* nr of windows open on this buffer */ + + int b_flags; /* various BF_ flags */ ++ #ifdef FEAT_AUTOCMD ++ int b_closing; /* buffer is being closed, don't let ++ autocommands close it too. */ ++ #endif + + /* + * b_ffname has the full path of the file (NULL for no name). +*************** +*** 1853,1858 **** +--- 1861,1870 ---- + win_T *w_prev; /* link to previous window */ + win_T *w_next; /* link to next window */ + #endif ++ #ifdef FEAT_AUTOCMD ++ int w_closing; /* window is being closed, don't let ++ autocommands close it too. */ ++ #endif + + frame_T *w_frame; /* frame containing this window */ + +*** ../vim-7.3.544/src/buffer.c 2012-03-16 14:32:10.000000000 +0100 +--- src/buffer.c 2012-06-06 18:57:27.000000000 +0200 +*************** +*** 377,404 **** + /* When the buffer is no longer in a window, trigger BufWinLeave */ + if (buf->b_nwindows == 1) + { + apply_autocmds(EVENT_BUFWINLEAVE, buf->b_fname, buf->b_fname, + FALSE, buf); +! /* Return if autocommands deleted the buffer or made it the only one. */ +! if (!buf_valid(buf) || (abort_if_last && one_window())) + { + EMSG(_(e_auabort)); + return; + } + + /* When the buffer becomes hidden, but is not unloaded, trigger + * BufHidden */ + if (!unload_buf) + { + apply_autocmds(EVENT_BUFHIDDEN, buf->b_fname, buf->b_fname, + FALSE, buf); +! /* Return if autocommands deleted the buffer or made it the only +! * one. */ +! if (!buf_valid(buf) || (abort_if_last && one_window())) +! { +! EMSG(_(e_auabort)); +! return; +! } + } + # ifdef FEAT_EVAL + if (aborting()) /* autocmds may abort script processing */ +--- 377,411 ---- + /* When the buffer is no longer in a window, trigger BufWinLeave */ + if (buf->b_nwindows == 1) + { ++ buf->b_closing = TRUE; + apply_autocmds(EVENT_BUFWINLEAVE, buf->b_fname, buf->b_fname, + FALSE, buf); +! if (!buf_valid(buf)) + { ++ /* Autocommands deleted the buffer. */ ++ aucmd_abort: + EMSG(_(e_auabort)); + return; + } ++ buf->b_closing = FALSE; ++ if (abort_if_last && one_window()) ++ /* Autocommands made this the only window. */ ++ goto aucmd_abort; + + /* When the buffer becomes hidden, but is not unloaded, trigger + * BufHidden */ + if (!unload_buf) + { ++ buf->b_closing = TRUE; + apply_autocmds(EVENT_BUFHIDDEN, buf->b_fname, buf->b_fname, + FALSE, buf); +! if (!buf_valid(buf)) +! /* Autocommands deleted the buffer. */ +! goto aucmd_abort; +! buf->b_closing = FALSE; +! if (abort_if_last && one_window()) +! /* Autocommands made this the only window. */ +! goto aucmd_abort; + } + # ifdef FEAT_EVAL + if (aborting()) /* autocmds may abort script processing */ +*************** +*** 552,557 **** +--- 559,565 ---- + #ifdef FEAT_AUTOCMD + int is_curbuf = (buf == curbuf); + ++ buf->b_closing = TRUE; + apply_autocmds(EVENT_BUFUNLOAD, buf->b_fname, buf->b_fname, FALSE, buf); + if (!buf_valid(buf)) /* autocommands may delete the buffer */ + return; +*************** +*** 568,573 **** +--- 576,582 ---- + if (!buf_valid(buf)) /* autocommands may delete the buffer */ + return; + } ++ buf->b_closing = FALSE; + # ifdef FEAT_EVAL + if (aborting()) /* autocmds may abort script processing */ + return; +*************** +*** 1150,1155 **** +--- 1159,1167 ---- + * a window with this buffer. + */ + while (buf == curbuf ++ # ifdef FEAT_AUTOCMD ++ && !(curwin->w_closing || curwin->w_buffer->b_closing) ++ # endif + && (firstwin != lastwin || first_tabpage->tp_next != NULL)) + win_close(curwin, FALSE); + #endif +*************** +*** 4750,4756 **** + #ifdef FEAT_WINDOWS + || (had_tab > 0 && wp != firstwin) + #endif +! ) && firstwin != lastwin) + { + win_close(wp, FALSE); + #ifdef FEAT_AUTOCMD +--- 4762,4772 ---- + #ifdef FEAT_WINDOWS + || (had_tab > 0 && wp != firstwin) + #endif +! ) && firstwin != lastwin +! #ifdef FEAT_AUTOCMD +! && !(wp->w_closing || wp->w_buffer->b_closing) +! #endif +! ) + { + win_close(wp, FALSE); + #ifdef FEAT_AUTOCMD +*** ../vim-7.3.544/src/ex_docmd.c 2012-06-06 18:03:01.000000000 +0200 +--- src/ex_docmd.c 2012-06-06 18:06:46.000000000 +0200 +*************** +*** 6459,6465 **** + } + #ifdef FEAT_AUTOCMD + apply_autocmds(EVENT_QUITPRE, NULL, NULL, FALSE, curbuf); +! if (curbuf_locked()) + return; + #endif + +--- 6459,6467 ---- + } + #ifdef FEAT_AUTOCMD + apply_autocmds(EVENT_QUITPRE, NULL, NULL, FALSE, curbuf); +! /* Refuse to quick when locked or when the buffer in the last window is +! * being closed (can only happen in autocommands). */ +! if (curbuf_locked() || (curbuf->b_nwindows == 1 && curbuf->b_closing)) + return; + #endif + +*** ../vim-7.3.544/src/window.c 2012-05-25 12:38:57.000000000 +0200 +--- src/window.c 2012-06-06 18:47:19.000000000 +0200 +*************** +*** 2034,2040 **** + + for (wp = firstwin; wp != NULL && lastwin != firstwin; ) + { +! if (wp->w_buffer == buf && (!keep_curwin || wp != curwin)) + { + win_close(wp, FALSE); + +--- 2034,2044 ---- + + for (wp = firstwin; wp != NULL && lastwin != firstwin; ) + { +! if (wp->w_buffer == buf && (!keep_curwin || wp != curwin) +! #ifdef FEAT_AUTOCMD +! && !(wp->w_closing || wp->w_buffer->b_closing) +! #endif +! ) + { + win_close(wp, FALSE); + +*************** +*** 2051,2057 **** + nexttp = tp->tp_next; + if (tp != curtab) + for (wp = tp->tp_firstwin; wp != NULL; wp = wp->w_next) +! if (wp->w_buffer == buf) + { + win_close_othertab(wp, FALSE, tp); + +--- 2055,2065 ---- + nexttp = tp->tp_next; + if (tp != curtab) + for (wp = tp->tp_firstwin; wp != NULL; wp = wp->w_next) +! if (wp->w_buffer == buf +! #ifdef FEAT_AUTOCMD +! && !(wp->w_closing || wp->w_buffer->b_closing) +! #endif +! ) + { + win_close_othertab(wp, FALSE, tp); + +*************** +*** 2168,2173 **** +--- 2176,2183 ---- + } + + #ifdef FEAT_AUTOCMD ++ if (win->w_closing || win->w_buffer->b_closing) ++ return; /* window is already being closed */ + if (win == aucmd_win) + { + EMSG(_("E813: Cannot close autocmd window")); +*************** +*** 2203,2219 **** + wp = frame2win(win_altframe(win, NULL)); + + /* +! * Be careful: If autocommands delete the window, return now. + */ + if (wp->w_buffer != curbuf) + { + other_buffer = TRUE; + apply_autocmds(EVENT_BUFLEAVE, NULL, NULL, FALSE, curbuf); +! if (!win_valid(win) || last_window()) + return; + } + apply_autocmds(EVENT_WINLEAVE, NULL, NULL, FALSE, curbuf); +! if (!win_valid(win) || last_window()) + return; + # ifdef FEAT_EVAL + /* autocmds may abort script processing */ +--- 2213,2238 ---- + wp = frame2win(win_altframe(win, NULL)); + + /* +! * Be careful: If autocommands delete the window or cause this window +! * to be the last one left, return now. + */ + if (wp->w_buffer != curbuf) + { + other_buffer = TRUE; ++ win->w_closing = TRUE; + apply_autocmds(EVENT_BUFLEAVE, NULL, NULL, FALSE, curbuf); +! if (!win_valid(win)) +! return; +! win->w_closing = FALSE; +! if (last_window()) + return; + } ++ win->w_closing = TRUE; + apply_autocmds(EVENT_WINLEAVE, NULL, NULL, FALSE, curbuf); +! if (!win_valid(win)) +! return; +! win->w_closing = FALSE; +! if (last_window()) + return; + # ifdef FEAT_EVAL + /* autocmds may abort script processing */ +*************** +*** 2240,2246 **** + * Close the link to the buffer. + */ + if (win->w_buffer != NULL) +! close_buffer(win, win->w_buffer, free_buf ? DOBUF_UNLOAD : 0, TRUE); + + /* Autocommands may have closed the window already, or closed the only + * other window or moved to another tab page. */ +--- 2259,2274 ---- + * Close the link to the buffer. + */ + if (win->w_buffer != NULL) +! { +! #ifdef FEAT_AUTOCMD +! win->w_closing = TRUE; +! #endif +! close_buffer(win, win->w_buffer, free_buf ? DOBUF_UNLOAD : 0, FALSE); +! #ifdef FEAT_AUTOCMD +! if (win_valid(win)) +! win->w_closing = FALSE; +! #endif +! } + + /* Autocommands may have closed the window already, or closed the only + * other window or moved to another tab page. */ +*************** +*** 2346,2351 **** +--- 2374,2384 ---- + tabpage_T *ptp = NULL; + int free_tp = FALSE; + ++ #ifdef FEAT_AUTOCMD ++ if (win->w_closing || win->w_buffer->b_closing) ++ return; /* window is already being closed */ ++ #endif ++ + /* Close the link to the buffer. */ + close_buffer(win, win->w_buffer, free_buf ? DOBUF_UNLOAD : 0, FALSE); + +*** ../vim-7.3.544/src/version.c 2012-06-06 18:03:01.000000000 +0200 +--- src/version.c 2012-06-06 18:53:06.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 545, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +4. Put your garbage can on your desk and label it "in". + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a91fa3e1eb4e7d13cd7eba9a53fbaa08a2ffaa8f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:09:00 +0200 Subject: [PATCH 0288/3340] - patchlevel 546 --- 7.3.546 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 7.3.546 diff --git a/7.3.546 b/7.3.546 new file mode 100644 index 00000000..c883d2d6 --- /dev/null +++ b/7.3.546 @@ -0,0 +1,54 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.546 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.546 +Problem: Bogus line break. +Solution: Remove the line break. +Files: src/screen.c + + +*** ../vim-7.3.545/src/screen.c 2012-06-01 15:20:49.000000000 +0200 +--- src/screen.c 2012-06-01 16:31:30.000000000 +0200 +*************** +*** 3228,3235 **** + /* no bad word found at line start, don't check until end of a + * word */ + spell_hlf = HLF_COUNT; +! word_end = (int)(spell_to_word_end(ptr, wp) +! - line + 1); + } + else + { +--- 3228,3234 ---- + /* no bad word found at line start, don't check until end of a + * word */ + spell_hlf = HLF_COUNT; +! word_end = (int)(spell_to_word_end(ptr, wp) - line + 1); + } + else + { +*** ../vim-7.3.545/src/version.c 2012-06-06 19:02:40.000000000 +0200 +--- src/version.c 2012-06-06 19:05:11.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 546, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +5. Put decaf in the coffee maker for 3 weeks. Once everyone has gotten + over their caffeine addictions, switch to espresso. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 447c06cfa2832ee715ce7449462b6cb019b63a21 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:09:01 +0200 Subject: [PATCH 0289/3340] - patchlevel 547 --- 7.3.547 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.547 diff --git a/7.3.547 b/7.3.547 new file mode 100644 index 00000000..5533144a --- /dev/null +++ b/7.3.547 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.547 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.547 (after 7.3.541) +Problem: Compiler warning for uninitialized variable. +Solution: Initialize it. +Files: src/ops.c + + +*** ../vim-7.3.546/src/ops.c 2012-06-06 16:12:54.000000000 +0200 +--- src/ops.c 2012-06-06 23:06:45.000000000 +0200 +*************** +*** 4306,4312 **** + colnr_T col = 0; + int ret = OK; + #if defined(FEAT_COMMENTS) || defined(PROTO) +! int *comments; + int remove_comments = (use_formatoptions == TRUE) + && has_format_option(FO_REMOVE_COMS); + int prev_was_comment; +--- 4306,4312 ---- + colnr_T col = 0; + int ret = OK; + #if defined(FEAT_COMMENTS) || defined(PROTO) +! int *comments = NULL; + int remove_comments = (use_formatoptions == TRUE) + && has_format_option(FO_REMOVE_COMS); + int prev_was_comment; +*** ../vim-7.3.546/src/version.c 2012-06-06 19:05:45.000000000 +0200 +--- src/version.c 2012-06-06 23:07:26.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 547, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +9. As often as possible, skip rather than walk. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 856bfdcc62cfe450f02d057ae8ad9da45fa3f992 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:09:01 +0200 Subject: [PATCH 0290/3340] - patchlevel 548 --- 7.3.548 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.548 diff --git a/7.3.548 b/7.3.548 new file mode 100644 index 00000000..3692a9a9 --- /dev/null +++ b/7.3.548 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.548 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.548 +Problem: Compiler warning on 64 bit Windows. +Solution: Add type cast. (Mike Williams) +Files: src/ops.c + + +*** ../vim-7.3.547/src/ops.c 2012-06-06 23:08:33.000000000 +0200 +--- src/ops.c 2012-06-07 21:07:57.000000000 +0200 +*************** +*** 4352,4358 **** + + char_u *new_curr = skip_comment(curr, TRUE, insert_space, + &prev_was_comment); +! comments[t] = new_curr - curr; + curr = new_curr; + } + else +--- 4352,4358 ---- + + char_u *new_curr = skip_comment(curr, TRUE, insert_space, + &prev_was_comment); +! comments[t] = (int)(new_curr - curr); + curr = new_curr; + } + else +*** ../vim-7.3.547/src/version.c 2012-06-06 23:08:33.000000000 +0200 +--- src/version.c 2012-06-07 21:08:35.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 548, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +17. When the money comes out the ATM, scream "I won!, I won! 3rd + time this week!!!!!" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3e4260c8b534106e0852c0b80cc2d8b8db058d67 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:09:01 +0200 Subject: [PATCH 0291/3340] - patchlevel 549 --- 7.3.549 | 125 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 125 insertions(+) create mode 100644 7.3.549 diff --git a/7.3.549 b/7.3.549 new file mode 100644 index 00000000..6d27fc3f --- /dev/null +++ b/7.3.549 @@ -0,0 +1,125 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.549 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.549 +Problem: In 'cinoptions' "0s" is interpreted as one shiftwidth. (David + Pineau) +Solution: Use the zero as zero. (Lech Lorens) +Files: src/misc1.c, src/testdir/test3.in, src/testdir/test3.ok + + +*** ../vim-7.3.548/src/misc1.c 2012-06-06 16:12:54.000000000 +0200 +--- src/misc1.c 2012-06-13 13:17:11.000000000 +0200 +*************** +*** 6635,6640 **** +--- 6635,6641 ---- + int whilelevel; + linenr_T lnum; + char_u *options; ++ char_u *digits; + int fraction = 0; /* init for GCC */ + int divider; + int n; +*************** +*** 6650,6655 **** +--- 6651,6657 ---- + l = options++; + if (*options == '-') + ++options; ++ digits = options; /* remember where the digits start */ + n = getdigits(&options); + divider = 0; + if (*options == '.') /* ".5s" means a fraction */ +*************** +*** 6666,6672 **** + } + if (*options == 's') /* "2s" means two times 'shiftwidth' */ + { +! if (n == 0 && fraction == 0) + n = curbuf->b_p_sw; /* just "s" is one 'shiftwidth' */ + else + { +--- 6668,6674 ---- + } + if (*options == 's') /* "2s" means two times 'shiftwidth' */ + { +! if (options == digits) + n = curbuf->b_p_sw; /* just "s" is one 'shiftwidth' */ + else + { +*** ../vim-7.3.548/src/testdir/test3.in 2012-04-05 17:17:38.000000000 +0200 +--- src/testdir/test3.in 2012-06-13 13:17:31.000000000 +0200 +*************** +*** 977,982 **** +--- 977,1000 ---- + + STARTTEST + :set cin ++ :set cino=es,n0s ++ /main ++ =][ ++ ENDTEST ++ ++ main(void) ++ { ++ /* Make sure that cino=X0s is not parsed like cino=Xs. */ ++ if (cond) ++ foo(); ++ else ++ { ++ bar(); ++ } ++ } ++ ++ STARTTEST ++ :set cin + :set cino= + ]]=][ + ENDTEST +*** ../vim-7.3.548/src/testdir/test3.ok 2012-04-05 17:17:38.000000000 +0200 +--- src/testdir/test3.ok 2012-06-13 13:17:31.000000000 +0200 +*************** +*** 940,945 **** +--- 940,957 ---- + } + + ++ main(void) ++ { ++ /* Make sure that cino=X0s is not parsed like cino=Xs. */ ++ if (cond) ++ foo(); ++ else ++ { ++ bar(); ++ } ++ } ++ ++ + { + do + { +*** ../vim-7.3.548/src/version.c 2012-06-07 21:09:35.000000000 +0200 +--- src/version.c 2012-06-13 13:37:18.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 549, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +29. Your phone bill comes to your doorstep in a box. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f10224f42bfe6b7061c0b04cbb1de9353cdb158c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:09:02 +0200 Subject: [PATCH 0292/3340] - patchlevel 550 --- 7.3.550 | 160 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 160 insertions(+) create mode 100644 7.3.550 diff --git a/7.3.550 b/7.3.550 new file mode 100644 index 00000000..6fba66cd --- /dev/null +++ b/7.3.550 @@ -0,0 +1,160 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.550 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.550 (after 7.3.541) +Problem: With "j" in 'formatoptions' a list leader is not removed. (Gary + Johnson) +Solution: Don't ignore the start of a three part comment. (Lech Lorens) +Files: src/ops.c, src/testdir/test29.in, src/testdir/test29.ok + + +*** ../vim-7.3.549/src/ops.c 2012-06-07 21:09:35.000000000 +0200 +--- src/ops.c 2012-06-13 13:48:26.000000000 +0200 +*************** +*** 4250,4264 **** + return line; + + /* Find: +- * - COM_START, + * - COM_END, + * - colon, + * whichever comes first. + */ + while (*comment_flags) + { +! if (*comment_flags == COM_START +! || *comment_flags == COM_END + || *comment_flags == ':') + { + break; +--- 4250,4262 ---- + return line; + + /* Find: + * - COM_END, + * - colon, + * whichever comes first. + */ + while (*comment_flags) + { +! if (*comment_flags == COM_END + || *comment_flags == ':') + { + break; +*************** +*** 4267,4275 **** + } + + /* If we found a colon, it means that we are not processing a line +! * starting with an opening or a closing part of a three-part +! * comment. That's good, because we don't want to remove those as +! * this would be annoying. + */ + if (*comment_flags == ':' || *comment_flags == NUL) + line += lead_len; +--- 4265,4272 ---- + } + + /* If we found a colon, it means that we are not processing a line +! * starting with a closing part of a three-part comment. That's good, +! * because we don't want to remove those as this would be annoying. + */ + if (*comment_flags == ':' || *comment_flags == NUL) + line += lead_len; +*** ../vim-7.3.549/src/testdir/test29.in 2012-06-06 16:12:54.000000000 +0200 +--- src/testdir/test29.in 2012-06-13 13:48:26.000000000 +0200 +*************** +*** 103,114 **** + + STARTTEST + /^{/+1 +! :set comments=s1:/*,mb:*,ex:*/,:// + :set comments+=s1:>#,mb:#,ex:#<,:< + :set cpoptions-=j joinspaces fo=j + :set backspace=eol,start + :.,+3join + j4J + :.,+2join + j3J + :.,+2join +--- 103,117 ---- + + STARTTEST + /^{/+1 +! :set comments=sO:*\ -,mO:*\ \ ,exO:*/ +! :set comments+=s1:/*,mb:*,ex:*/,:// + :set comments+=s1:>#,mb:#,ex:#<,:< + :set cpoptions-=j joinspaces fo=j + :set backspace=eol,start + :.,+3join + j4J ++ :.,+8join ++ j9J + :.,+2join + j3J + :.,+2join +*************** +*** 132,137 **** +--- 135,158 ---- + * Make sure the previous comment leader is not removed. + */ + ++ /* List: ++ * - item1 ++ * foo bar baz ++ * foo bar baz ++ * - item2 ++ * foo bar baz ++ * foo bar baz ++ */ ++ ++ /* List: ++ * - item1 ++ * foo bar baz ++ * foo bar baz ++ * - item2 ++ * foo bar baz ++ * foo bar baz ++ */ ++ + // Should the next comment leader be left alone? + // Yes. + +*** ../vim-7.3.549/src/testdir/test29.ok 2012-06-06 16:12:54.000000000 +0200 +--- src/testdir/test29.ok 2012-06-13 13:48:26.000000000 +0200 +*************** +*** 66,71 **** +--- 66,73 ---- + { + /* Make sure the previous comment leader is not removed. */ + /* Make sure the previous comment leader is not removed. */ ++ /* List: item1 foo bar baz foo bar baz item2 foo bar baz foo bar baz */ ++ /* List: item1 foo bar baz foo bar baz item2 foo bar baz foo bar baz */ + // Should the next comment leader be left alone? Yes. + // Should the next comment leader be left alone? Yes. + /* Here the comment leader should be left intact. */ // And so should this one. +*** ../vim-7.3.549/src/version.c 2012-06-13 13:40:45.000000000 +0200 +--- src/version.c 2012-06-13 13:50:23.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 550, + /**/ + +-- +If you put 7 of the most talented OSS developers in a room for a week +and asked them to fix a bug in a spreadsheet program, in 1 week +you'd have 2 new mail readers and a text-based web browser. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f5d2c4d0e75fcaaa658657996225340045e151e7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:09:02 +0200 Subject: [PATCH 0293/3340] - patchlevel 551 --- 7.3.551 | 494 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 494 insertions(+) create mode 100644 7.3.551 diff --git a/7.3.551 b/7.3.551 new file mode 100644 index 00000000..db8dbac7 --- /dev/null +++ b/7.3.551 @@ -0,0 +1,494 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.551 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.551 +Problem: When using :tablose a TabEnter autocommand is triggered too early. + (Karthick) +Solution: Don't trigger *Enter autocommands before closing the tab. + (Christian Brabandt) +Files: src/buffer.c, src/eval.c, src/ex_cmds2.c, src/fileio.c, + src/proto/window.pro, src/window.c + + +*** ../vim-7.3.550/src/buffer.c 2012-06-06 19:02:40.000000000 +0200 +--- src/buffer.c 2012-06-13 14:18:58.000000000 +0200 +*************** +*** 4470,4476 **** + * When the ":tab" modifier was used do this for all tab pages. + */ + if (had_tab > 0) +! goto_tabpage_tp(first_tabpage); + for (;;) + { + tpnext = curtab->tp_next; +--- 4470,4476 ---- + * When the ":tab" modifier was used do this for all tab pages. + */ + if (had_tab > 0) +! goto_tabpage_tp(first_tabpage, TRUE); + for (;;) + { + tpnext = curtab->tp_next; +*************** +*** 4582,4588 **** + if (!valid_tabpage(tpnext)) + tpnext = first_tabpage; /* start all over...*/ + # endif +! goto_tabpage_tp(tpnext); + } + + /* +--- 4582,4588 ---- + if (!valid_tabpage(tpnext)) + tpnext = first_tabpage; /* start all over...*/ + # endif +! goto_tabpage_tp(tpnext, TRUE); + } + + /* +*************** +*** 4686,4698 **** + if (last_curtab != new_curtab) + { + if (valid_tabpage(last_curtab)) +! goto_tabpage_tp(last_curtab); + if (win_valid(last_curwin)) + win_enter(last_curwin, FALSE); + } + /* to window with first arg */ + if (valid_tabpage(new_curtab)) +! goto_tabpage_tp(new_curtab); + if (win_valid(new_curwin)) + win_enter(new_curwin, FALSE); + +--- 4686,4698 ---- + if (last_curtab != new_curtab) + { + if (valid_tabpage(last_curtab)) +! goto_tabpage_tp(last_curtab, TRUE); + if (win_valid(last_curwin)) + win_enter(last_curwin, FALSE); + } + /* to window with first arg */ + if (valid_tabpage(new_curtab)) +! goto_tabpage_tp(new_curtab, TRUE); + if (win_valid(new_curwin)) + win_enter(new_curwin, FALSE); + +*************** +*** 4744,4750 **** + */ + #ifdef FEAT_WINDOWS + if (had_tab > 0) +! goto_tabpage_tp(first_tabpage); + for (;;) + { + #endif +--- 4744,4750 ---- + */ + #ifdef FEAT_WINDOWS + if (had_tab > 0) +! goto_tabpage_tp(first_tabpage, TRUE); + for (;;) + { + #endif +*************** +*** 4784,4790 **** + /* Without the ":tab" modifier only do the current tab page. */ + if (had_tab == 0 || tpnext == NULL) + break; +! goto_tabpage_tp(tpnext); + } + #endif + +--- 4784,4790 ---- + /* Without the ":tab" modifier only do the current tab page. */ + if (had_tab == 0 || tpnext == NULL) + break; +! goto_tabpage_tp(tpnext, TRUE); + } + #endif + +*** ../vim-7.3.550/src/eval.c 2012-06-06 16:29:06.000000000 +0200 +--- src/eval.c 2012-06-13 14:18:58.000000000 +0200 +*************** +*** 16415,16421 **** + if (tp != NULL && varname != NULL && varp != NULL) + { + save_curtab = curtab; +! goto_tabpage_tp(tp); + + tabvarname = alloc((unsigned)STRLEN(varname) + 3); + if (tabvarname != NULL) +--- 16415,16421 ---- + if (tp != NULL && varname != NULL && varp != NULL) + { + save_curtab = curtab; +! goto_tabpage_tp(tp, TRUE); + + tabvarname = alloc((unsigned)STRLEN(varname) + 3); + if (tabvarname != NULL) +*************** +*** 16428,16434 **** + + /* Restore current tabpage */ + if (valid_tabpage(save_curtab)) +! goto_tabpage_tp(save_curtab); + } + } + +--- 16428,16434 ---- + + /* Restore current tabpage */ + if (valid_tabpage(save_curtab)) +! goto_tabpage_tp(save_curtab, TRUE); + } + } + +*************** +*** 16492,16498 **** + /* set curwin to be our win, temporarily */ + save_curwin = curwin; + save_curtab = curtab; +! goto_tabpage_tp(tp); + if (!win_valid(win)) + return; + curwin = win; +--- 16492,16498 ---- + /* set curwin to be our win, temporarily */ + save_curwin = curwin; + save_curtab = curtab; +! goto_tabpage_tp(tp, TRUE); + if (!win_valid(win)) + return; + curwin = win; +*************** +*** 16527,16533 **** + /* Restore current tabpage and window, if still valid (autocomands can + * make them invalid). */ + if (valid_tabpage(save_curtab)) +! goto_tabpage_tp(save_curtab); + if (win_valid(save_curwin)) + { + curwin = save_curwin; +--- 16527,16533 ---- + /* Restore current tabpage and window, if still valid (autocomands can + * make them invalid). */ + if (valid_tabpage(save_curtab)) +! goto_tabpage_tp(save_curtab, TRUE); + if (win_valid(save_curwin)) + { + curwin = save_curwin; +*** ../vim-7.3.550/src/ex_cmds2.c 2012-04-25 17:32:14.000000000 +0200 +--- src/ex_cmds2.c 2012-06-13 14:18:58.000000000 +0200 +*************** +*** 2476,2482 **** + /* go to window "tp" */ + if (!valid_tabpage(tp)) + break; +! goto_tabpage_tp(tp); + tp = tp->tp_next; + } + #endif +--- 2476,2482 ---- + /* go to window "tp" */ + if (!valid_tabpage(tp)) + break; +! goto_tabpage_tp(tp, TRUE); + tp = tp->tp_next; + } + #endif +*** ../vim-7.3.550/src/fileio.c 2012-06-06 18:03:01.000000000 +0200 +--- src/fileio.c 2012-06-13 14:18:58.000000000 +0200 +*************** +*** 8918,8924 **** + if (wp == aucmd_win) + { + if (tp != curtab) +! goto_tabpage_tp(tp); + win_goto(aucmd_win); + goto win_found; + } +--- 8918,8924 ---- + if (wp == aucmd_win) + { + if (tp != curtab) +! goto_tabpage_tp(tp, TRUE); + win_goto(aucmd_win); + goto win_found; + } +*** ../vim-7.3.550/src/proto/window.pro 2012-02-22 14:58:24.000000000 +0100 +--- src/proto/window.pro 2012-06-13 14:23:06.000000000 +0200 +*************** +*** 27,33 **** + tabpage_T *find_tabpage __ARGS((int n)); + int tabpage_index __ARGS((tabpage_T *ftp)); + void goto_tabpage __ARGS((int n)); +! void goto_tabpage_tp __ARGS((tabpage_T *tp)); + void goto_tabpage_win __ARGS((tabpage_T *tp, win_T *wp)); + void tabpage_move __ARGS((int nr)); + void win_goto __ARGS((win_T *wp)); +--- 27,33 ---- + tabpage_T *find_tabpage __ARGS((int n)); + int tabpage_index __ARGS((tabpage_T *ftp)); + void goto_tabpage __ARGS((int n)); +! void goto_tabpage_tp __ARGS((tabpage_T *tp, int trigger_autocmds)); + void goto_tabpage_win __ARGS((tabpage_T *tp, win_T *wp)); + void tabpage_move __ARGS((int nr)); + void win_goto __ARGS((win_T *wp)); +*** ../vim-7.3.550/src/window.c 2012-06-06 19:02:40.000000000 +0200 +--- src/window.c 2012-06-13 14:24:38.000000000 +0200 +*************** +*** 45,51 **** + #if defined(FEAT_WINDOWS) || defined(PROTO) + static tabpage_T *alloc_tabpage __ARGS((void)); + static int leave_tabpage __ARGS((buf_T *new_curbuf)); +! static void enter_tabpage __ARGS((tabpage_T *tp, buf_T *old_curbuf)); + static void frame_fix_height __ARGS((win_T *wp)); + static int frame_minheight __ARGS((frame_T *topfrp, win_T *next_curwin)); + static void win_enter_ext __ARGS((win_T *wp, int undo_sync, int no_curwin)); +--- 45,51 ---- + #if defined(FEAT_WINDOWS) || defined(PROTO) + static tabpage_T *alloc_tabpage __ARGS((void)); + static int leave_tabpage __ARGS((buf_T *new_curbuf)); +! static void enter_tabpage __ARGS((tabpage_T *tp, buf_T *old_curbuf, int trigger_autocmds)); + static void frame_fix_height __ARGS((win_T *wp)); + static int frame_minheight __ARGS((frame_T *topfrp, win_T *next_curwin)); + static void win_enter_ext __ARGS((win_T *wp, int undo_sync, int no_curwin)); +*************** +*** 355,365 **** + && valid_tabpage(oldtab)) + { + newtab = curtab; +! goto_tabpage_tp(oldtab); + if (curwin == wp) + win_close(curwin, FALSE); + if (valid_tabpage(newtab)) +! goto_tabpage_tp(newtab); + } + } + break; +--- 355,365 ---- + && valid_tabpage(oldtab)) + { + newtab = curtab; +! goto_tabpage_tp(oldtab, TRUE); + if (curwin == wp) + win_close(curwin, FALSE); + if (valid_tabpage(newtab)) +! goto_tabpage_tp(newtab, TRUE); + } + } + break; +*************** +*** 2130,2137 **** + * page and then close the window and the tab page. This avoids that + * curwin and curtab are invalid while we are freeing memory, they may + * be used in GUI events. + */ +! goto_tabpage_tp(alt_tabpage()); + redraw_tabline = TRUE; + + /* Safety check: Autocommands may have closed the window when jumping +--- 2130,2139 ---- + * page and then close the window and the tab page. This avoids that + * curwin and curtab are invalid while we are freeing memory, they may + * be used in GUI events. ++ * Don't trigger autocommands yet, they may use wrong values, so do ++ * that below. + */ +! goto_tabpage_tp(alt_tabpage(), FALSE); + redraw_tabline = TRUE; + + /* Safety check: Autocommands may have closed the window when jumping +*************** +*** 2144,2149 **** +--- 2146,2157 ---- + if (h != tabline_height()) + shell_new_rows(); + } ++ /* Since goto_tabpage_tp above did not trigger *Enter autocommands, do ++ * that now. */ ++ #ifdef FEAT_AUTOCMD ++ apply_autocmds(EVENT_TABENTER, NULL, NULL, FALSE, curbuf); ++ apply_autocmds(EVENT_WINENTER, NULL, NULL, FALSE, curbuf); ++ #endif + return TRUE; + } + return FALSE; +*************** +*** 3556,3562 **** + } + + /* Failed, get back the previous Tab page */ +! enter_tabpage(curtab, curbuf); + return FAIL; + } + +--- 3564,3570 ---- + } + + /* Failed, get back the previous Tab page */ +! enter_tabpage(curtab, curbuf, TRUE); + return FAIL; + } + +*************** +*** 3709,3719 **** + /* + * Start using tab page "tp". + * Only to be used after leave_tabpage() or freeing the current tab page. + */ + static void +! enter_tabpage(tp, old_curbuf) + tabpage_T *tp; + buf_T *old_curbuf UNUSED; + { + int old_off = tp->tp_firstwin->w_winrow; + win_T *next_prevwin = tp->tp_prevwin; +--- 3717,3729 ---- + /* + * Start using tab page "tp". + * Only to be used after leave_tabpage() or freeing the current tab page. ++ * Only trigger *Enter autocommands when trigger_autocmds is TRUE. + */ + static void +! enter_tabpage(tp, old_curbuf, trigger_autocmds) + tabpage_T *tp; + buf_T *old_curbuf UNUSED; ++ int trigger_autocmds; + { + int old_off = tp->tp_firstwin->w_winrow; + win_T *next_prevwin = tp->tp_prevwin; +*************** +*** 3761,3769 **** + #ifdef FEAT_AUTOCMD + /* Apply autocommands after updating the display, when 'rows' and + * 'columns' have been set correctly. */ +! apply_autocmds(EVENT_TABENTER, NULL, NULL, FALSE, curbuf); +! if (old_curbuf != curbuf) +! apply_autocmds(EVENT_BUFENTER, NULL, NULL, FALSE, curbuf); + #endif + + redraw_all_later(CLEAR); +--- 3771,3782 ---- + #ifdef FEAT_AUTOCMD + /* Apply autocommands after updating the display, when 'rows' and + * 'columns' have been set correctly. */ +! if (trigger_autocmds) +! { +! apply_autocmds(EVENT_TABENTER, NULL, NULL, FALSE, curbuf); +! if (old_curbuf != curbuf) +! apply_autocmds(EVENT_BUFENTER, NULL, NULL, FALSE, curbuf); +! } + #endif + + redraw_all_later(CLEAR); +*************** +*** 3839,3845 **** + } + } + +! goto_tabpage_tp(tp); + + #ifdef FEAT_GUI_TABLINE + if (gui_use_tabline()) +--- 3852,3858 ---- + } + } + +! goto_tabpage_tp(tp, TRUE); + + #ifdef FEAT_GUI_TABLINE + if (gui_use_tabline()) +*************** +*** 3849,3859 **** + + /* + * Go to tabpage "tp". + * Note: doesn't update the GUI tab. + */ + void +! goto_tabpage_tp(tp) + tabpage_T *tp; + { + /* Don't repeat a message in another tab page. */ + set_keep_msg(NULL, 0); +--- 3862,3874 ---- + + /* + * Go to tabpage "tp". ++ * Only trigger *Enter autocommands when trigger_autocmds is TRUE. + * Note: doesn't update the GUI tab. + */ + void +! goto_tabpage_tp(tp, trigger_autocmds) + tabpage_T *tp; ++ int trigger_autocmds; + { + /* Don't repeat a message in another tab page. */ + set_keep_msg(NULL, 0); +*************** +*** 3861,3869 **** + if (tp != curtab && leave_tabpage(tp->tp_curwin->w_buffer) == OK) + { + if (valid_tabpage(tp)) +! enter_tabpage(tp, curbuf); + else +! enter_tabpage(curtab, curbuf); + } + } + +--- 3876,3884 ---- + if (tp != curtab && leave_tabpage(tp->tp_curwin->w_buffer) == OK) + { + if (valid_tabpage(tp)) +! enter_tabpage(tp, curbuf, trigger_autocmds); + else +! enter_tabpage(curtab, curbuf, trigger_autocmds); + } + } + +*************** +*** 3876,3882 **** + tabpage_T *tp; + win_T *wp; + { +! goto_tabpage_tp(tp); + if (curtab == tp && win_valid(wp)) + { + win_enter(wp, TRUE); +--- 3891,3897 ---- + tabpage_T *tp; + win_T *wp; + { +! goto_tabpage_tp(tp, TRUE); + if (curtab == tp && win_valid(wp)) + { + win_enter(wp, TRUE); +*** ../vim-7.3.550/src/version.c 2012-06-13 14:01:36.000000000 +0200 +--- src/version.c 2012-06-13 14:28:00.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 551, + /**/ + +-- +Give a man a computer program and you give him a headache, +but teach him to program computers and you give him the power +to create headaches for others for the rest of his life... + R. B. Forest + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e32f6352eaef16472c63820fc3e6122380c438a4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:09:02 +0200 Subject: [PATCH 0294/3340] - patchlevel 552 --- 7.3.552 | 582 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 582 insertions(+) create mode 100644 7.3.552 diff --git a/7.3.552 b/7.3.552 new file mode 100644 index 00000000..e9a560ec --- /dev/null +++ b/7.3.552 @@ -0,0 +1,582 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.552 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.552 +Problem: Formatting inside comments does not use the "2" flag in + 'formatoptions'. +Solution: Support the "2" flag. (Tor Perkins) +Files: src/vim.h, src/ops.c, src/edit.c, src/misc1.c, + src/testdir/test68.in, src/testdir/test68.ok + + +*** ../vim-7.3.551/src/vim.h 2012-06-06 18:03:01.000000000 +0200 +--- src/vim.h 2012-06-13 16:07:27.000000000 +0200 +*************** +*** 1072,1083 **** +--- 1072,1085 ---- + #define INSCHAR_DO_COM 2 /* format comments */ + #define INSCHAR_CTRLV 4 /* char typed just after CTRL-V */ + #define INSCHAR_NO_FEX 8 /* don't use 'formatexpr' */ ++ #define INSCHAR_COM_LIST 16 /* format comments with list/2nd line indent */ + + /* flags for open_line() */ + #define OPENLINE_DELSPACES 1 /* delete spaces after cursor */ + #define OPENLINE_DO_COM 2 /* format comments */ + #define OPENLINE_KEEPTRAIL 4 /* keep trailing spaces */ + #define OPENLINE_MARKFIX 8 /* fix mark positions */ ++ #define OPENLINE_COM_LIST 16 /* format comments with list/2nd line indent */ + + /* + * There are four history tables: +*** ../vim-7.3.551/src/ops.c 2012-06-13 14:01:36.000000000 +0200 +--- src/ops.c 2012-06-13 16:53:44.000000000 +0200 +*************** +*** 1727,1734 **** + * and the delete is within one line. */ + if (( + #ifdef FEAT_CLIPBOARD +! ((clip_unnamed & CLIP_UNNAMED) && oap->regname == '*') || +! ((clip_unnamed & CLIP_UNNAMED_PLUS) && oap->regname == '+') || + #endif + oap->regname == 0) && oap->motion_type != MLINE + && oap->line_count == 1) +--- 1727,1734 ---- + * and the delete is within one line. */ + if (( + #ifdef FEAT_CLIPBOARD +! ((clip_unnamed & CLIP_UNNAMED) && oap->regname == '*') || +! ((clip_unnamed & CLIP_UNNAMED_PLUS) && oap->regname == '+') || + #endif + oap->regname == 0) && oap->motion_type != MLINE + && oap->line_count == 1) +*************** +*** 4208,4217 **** + * "is_comment". + * line - line to be processed, + * process - if FALSE, will only check whether the line ends with an unclosed +! * comment, + * include_space - whether to also skip space following the comment leader, + * is_comment - will indicate whether the current line ends with an unclosed +! * comment. + */ + static char_u * + skip_comment(line, process, include_space, is_comment) +--- 4208,4217 ---- + * "is_comment". + * line - line to be processed, + * process - if FALSE, will only check whether the line ends with an unclosed +! * comment, + * include_space - whether to also skip space following the comment leader, + * is_comment - will indicate whether the current line ends with an unclosed +! * comment. + */ + static char_u * + skip_comment(line, process, include_space, is_comment) +*************** +*** 4723,4731 **** + char_u *leader_flags = NULL; /* flags for leader of current line */ + char_u *next_leader_flags; /* flags for leader of next line */ + int do_comments; /* format comments */ + #endif + int advance = TRUE; +! int second_indent = -1; + int do_second_indent; + int do_number_indent; + int do_trail_white; +--- 4723,4733 ---- + char_u *leader_flags = NULL; /* flags for leader of current line */ + char_u *next_leader_flags; /* flags for leader of next line */ + int do_comments; /* format comments */ ++ int do_comments_list = 0; /* format comments with 'n' or '2' */ + #endif + int advance = TRUE; +! int second_indent = -1; /* indent for second line (comment +! * aware) */ + int do_second_indent; + int do_number_indent; + int do_trail_white; +*************** +*** 4828,4845 **** + if (first_par_line + && (do_second_indent || do_number_indent) + && prev_is_end_par +! && curwin->w_cursor.lnum < curbuf->b_ml.ml_line_count + #ifdef FEAT_COMMENTS +! && leader_len == 0 +! && next_leader_len == 0 + #endif +! ) +! { +! if (do_second_indent +! && !lineempty(curwin->w_cursor.lnum + 1)) +! second_indent = get_indent_lnum(curwin->w_cursor.lnum + 1); + else if (do_number_indent) +! second_indent = get_number_indent(curwin->w_cursor.lnum); + } + + /* +--- 4830,4875 ---- + if (first_par_line + && (do_second_indent || do_number_indent) + && prev_is_end_par +! && curwin->w_cursor.lnum < curbuf->b_ml.ml_line_count) +! { +! if (do_second_indent && !lineempty(curwin->w_cursor.lnum + 1)) +! { + #ifdef FEAT_COMMENTS +! if (leader_len == 0 && next_leader_len == 0) +! { +! /* no comment found */ + #endif +! second_indent = +! get_indent_lnum(curwin->w_cursor.lnum + 1); +! #ifdef FEAT_COMMENTS +! } +! else +! { +! second_indent = next_leader_len; +! do_comments_list = 1; +! } +! #endif +! } + else if (do_number_indent) +! { +! #ifdef FEAT_COMMENTS +! if (leader_len == 0 && next_leader_len == 0) +! { +! /* no comment found */ +! #endif +! second_indent = +! get_number_indent(curwin->w_cursor.lnum); +! #ifdef FEAT_COMMENTS +! } +! else +! { +! /* get_number_indent() is now "comment aware"... */ +! second_indent = +! get_number_indent(curwin->w_cursor.lnum); +! do_comments_list = 1; +! } +! #endif +! } + } + + /* +*************** +*** 4878,4883 **** +--- 4908,4915 ---- + insertchar(NUL, INSCHAR_FORMAT + #ifdef FEAT_COMMENTS + + (do_comments ? INSCHAR_DO_COM : 0) ++ + (do_comments && do_comments_list ++ ? INSCHAR_COM_LIST : 0) + #endif + + (avoid_fex ? INSCHAR_NO_FEX : 0), second_indent); + State = old_State; +*** ../vim-7.3.551/src/edit.c 2012-06-06 16:12:54.000000000 +0200 +--- src/edit.c 2012-06-13 16:54:10.000000000 +0200 +*************** +*** 1463,1469 **** + * what check_abbr() expects. */ + (has_mbyte && c >= 0x100) ? (c + ABBR_OFF) : + #endif +! c) && c != Ctrl_RSB)) + { + insert_special(c, FALSE, FALSE); + #ifdef FEAT_RIGHTLEFT +--- 1463,1469 ---- + * what check_abbr() expects. */ + (has_mbyte && c >= 0x100) ? (c + ABBR_OFF) : + #endif +! c) && c != Ctrl_RSB)) + { + insert_special(c, FALSE, FALSE); + #ifdef FEAT_RIGHTLEFT +*************** +*** 5769,5774 **** +--- 5769,5784 ---- + # define WHITECHAR(cc) vim_iswhite(cc) + #endif + ++ /* ++ * "flags": INSCHAR_FORMAT - force formatting ++ * INSCHAR_CTRLV - char typed just after CTRL-V ++ * INSCHAR_NO_FEX - don't use 'formatexpr' ++ * ++ * NOTE: passes the flags value straight through to internal_format() which, ++ * beside INSCHAR_FORMAT (above), is also looking for these: ++ * INSCHAR_DO_COM - format comments ++ * INSCHAR_COM_LIST - format comments with num list or 2nd line indent ++ */ + void + insertchar(c, flags, second_indent) + int c; /* character to insert or NUL */ +*************** +*** 6011,6016 **** +--- 6021,6029 ---- + + /* + * Format text at the current insert position. ++ * ++ * If the INSCHAR_COM_LIST flag is present, then the value of second_indent ++ * will be the comment leader length sent to open_line(). + */ + static void + internal_format(textwidth, second_indent, flags, format_only, c) +*************** +*** 6289,6311 **** + + (fo_white_par ? OPENLINE_KEEPTRAIL : 0) + #ifdef FEAT_COMMENTS + + (do_comments ? OPENLINE_DO_COM : 0) + #endif +! , old_indent); +! old_indent = 0; + + replace_offset = 0; + if (first_line) + { +! if (second_indent < 0 && has_format_option(FO_Q_NUMBER)) +! second_indent = get_number_indent(curwin->w_cursor.lnum -1); +! if (second_indent >= 0) + { + #ifdef FEAT_VREPLACE +! if (State & VREPLACE_FLAG) +! change_indent(INDENT_SET, second_indent, FALSE, NUL, TRUE); +! else + #endif +! (void)set_indent(second_indent, SIN_CHANGED); + } + first_line = FALSE; + } +--- 6302,6337 ---- + + (fo_white_par ? OPENLINE_KEEPTRAIL : 0) + #ifdef FEAT_COMMENTS + + (do_comments ? OPENLINE_DO_COM : 0) ++ + ((flags & INSCHAR_COM_LIST) ? OPENLINE_COM_LIST : 0) + #endif +! , ((flags & INSCHAR_COM_LIST) ? second_indent : old_indent)); +! if (!(flags & INSCHAR_COM_LIST)) +! old_indent = 0; + + replace_offset = 0; + if (first_line) + { +! if (!(flags & INSCHAR_COM_LIST)) + { ++ /* ++ * This section is for numeric lists w/o comments. If comment ++ * indents are needed with numeric lists (formatoptions=nq), ++ * then the INSCHAR_COM_LIST flag will cause the corresponding ++ * OPENLINE_COM_LIST flag to be passed through to open_line() ++ * (as seen above)... ++ */ ++ if (second_indent < 0 && has_format_option(FO_Q_NUMBER)) ++ second_indent = get_number_indent(curwin->w_cursor.lnum -1); ++ if (second_indent >= 0) ++ { + #ifdef FEAT_VREPLACE +! if (State & VREPLACE_FLAG) +! change_indent(INDENT_SET, second_indent, +! FALSE, NUL, TRUE); +! else + #endif +! (void)set_indent(second_indent, SIN_CHANGED); +! } + } + first_line = FALSE; + } +*** ../vim-7.3.551/src/misc1.c 2012-06-13 13:40:45.000000000 +0200 +--- src/misc1.c 2012-06-13 16:54:59.000000000 +0200 +*************** +*** 423,449 **** + { + colnr_T col; + pos_T pos; +- regmmatch_T regmatch; + + if (lnum > curbuf->b_ml.ml_line_count) + return -1; + pos.lnum = 0; +! regmatch.regprog = vim_regcomp(curbuf->b_p_flp, RE_MAGIC); +! if (regmatch.regprog != NULL) + { +! regmatch.rmm_ic = FALSE; +! regmatch.rmm_maxcol = 0; +! if (vim_regexec_multi(®match, curwin, curbuf, lnum, +! (colnr_T)0, NULL)) + { +! pos.lnum = regmatch.endpos[0].lnum + lnum; +! pos.col = regmatch.endpos[0].col; + #ifdef FEAT_VIRTUALEDIT +! pos.coladd = 0; + #endif + } + vim_free(regmatch.regprog); + } + + if (pos.lnum == 0 || *ml_get_pos(&pos) == NUL) + return -1; +--- 423,492 ---- + { + colnr_T col; + pos_T pos; + + if (lnum > curbuf->b_ml.ml_line_count) + return -1; + pos.lnum = 0; +! +! #ifdef FEAT_COMMENTS +! if (has_format_option(FO_Q_COMS) && has_format_option(FO_Q_NUMBER)) + { +! regmatch_T regmatch; +! int lead_len; /* length of comment leader */ +! +! lead_len = get_leader_len(ml_get(lnum), NULL, FALSE, TRUE); +! regmatch.regprog = vim_regcomp(curbuf->b_p_flp, RE_MAGIC); +! if (regmatch.regprog != NULL) + { +! regmatch.rm_ic = FALSE; +! +! /* vim_regexec() expects a pointer to a line. This lets us +! * start matching for the flp beyond any comment leader... */ +! if (vim_regexec(®match, ml_get(lnum) + lead_len, (colnr_T)0)) +! { +! pos.lnum = lnum; +! pos.col = *regmatch.endp - (ml_get(lnum) + lead_len); +! pos.col += lead_len; + #ifdef FEAT_VIRTUALEDIT +! pos.coladd = 0; + #endif ++ } + } + vim_free(regmatch.regprog); + } ++ else ++ { ++ /* ++ * What follows is the orig code that is not "comment aware"... ++ * ++ * I'm not sure if regmmatch_T (multi-match) is needed in this case. ++ * It may be true that this section would work properly using the ++ * regmatch_T code above, in which case, these two seperate sections ++ * should be consolidated w/ FEAT_COMMENTS making lead_len > 0... ++ */ ++ #endif ++ regmmatch_T regmatch; ++ ++ regmatch.regprog = vim_regcomp(curbuf->b_p_flp, RE_MAGIC); ++ ++ if (regmatch.regprog != NULL) ++ { ++ regmatch.rmm_ic = FALSE; ++ regmatch.rmm_maxcol = 0; ++ if (vim_regexec_multi(®match, curwin, curbuf, ++ lnum, (colnr_T)0, NULL)) ++ { ++ pos.lnum = regmatch.endpos[0].lnum + lnum; ++ pos.col = regmatch.endpos[0].col; ++ #ifdef FEAT_VIRTUALEDIT ++ pos.coladd = 0; ++ #endif ++ } ++ vim_free(regmatch.regprog); ++ } ++ #ifdef FEAT_COMMENTS ++ } ++ #endif + + if (pos.lnum == 0 || *ml_get_pos(&pos) == NUL) + return -1; +*************** +*** 502,515 **** + * OPENLINE_DO_COM format comments + * OPENLINE_KEEPTRAIL keep trailing spaces + * OPENLINE_MARKFIX adjust mark positions after the line break + * + * Return TRUE for success, FALSE for failure + */ + int +! open_line(dir, flags, old_indent) + int dir; /* FORWARD or BACKWARD */ + int flags; +! int old_indent; /* indent for after ^^D in Insert mode */ + { + char_u *saved_line; /* copy of the original line */ + char_u *next_line = NULL; /* copy of the next line */ +--- 545,562 ---- + * OPENLINE_DO_COM format comments + * OPENLINE_KEEPTRAIL keep trailing spaces + * OPENLINE_MARKFIX adjust mark positions after the line break ++ * OPENLINE_COM_LIST format comments with list or 2nd line indent ++ * ++ * "second_line_indent": indent for after ^^D in Insert mode or if flag ++ * OPENLINE_COM_LIST + * + * Return TRUE for success, FALSE for failure + */ + int +! open_line(dir, flags, second_line_indent) + int dir; /* FORWARD or BACKWARD */ + int flags; +! int second_line_indent; + { + char_u *saved_line; /* copy of the original line */ + char_u *next_line = NULL; /* copy of the next line */ +*************** +*** 650,657 **** + * count white space on current line + */ + newindent = get_indent_str(saved_line, (int)curbuf->b_p_ts); +! if (newindent == 0) +! newindent = old_indent; /* for ^^D command in insert mode */ + + #ifdef FEAT_SMARTINDENT + /* +--- 697,704 ---- + * count white space on current line + */ + newindent = get_indent_str(saved_line, (int)curbuf->b_p_ts); +! if (newindent == 0 && !(flags & OPENLINE_COM_LIST)) +! newindent = second_line_indent; /* for ^^D command in insert mode */ + + #ifdef FEAT_SMARTINDENT + /* +*************** +*** 1008,1015 **** + if (lead_len) + { + /* allocate buffer (may concatenate p_exta later) */ +! leader = alloc(lead_len + lead_repl_len + extra_space + +! extra_len + 1); + allocated = leader; /* remember to free it later */ + + if (leader == NULL) +--- 1055,1062 ---- + if (lead_len) + { + /* allocate buffer (may concatenate p_exta later) */ +! leader = alloc(lead_len + lead_repl_len + extra_space + extra_len +! + (second_line_indent > 0 ? second_line_indent : 0)); + allocated = leader; /* remember to free it later */ + + if (leader == NULL) +*************** +*** 1304,1309 **** +--- 1351,1370 ---- + /* concatenate leader and p_extra, if there is a leader */ + if (lead_len) + { ++ if (flags & OPENLINE_COM_LIST && second_line_indent > 0) ++ { ++ int i; ++ int padding = second_line_indent - (newindent + STRLEN(leader)); ++ ++ /* Here whitespace is inserted after the comment char. ++ * Below, set_indent(newindent, SIN_INSERT) will insert the ++ * whitespace needed before the comment char. */ ++ for (i = 0; i < padding; i++) ++ { ++ STRCAT(leader, " "); ++ newcol++; ++ } ++ } + STRCAT(leader, p_extra); + p_extra = leader; + did_ai = TRUE; /* So truncating blanks works with comments */ +*************** +*** 4966,4973 **** + char_u * + FullName_save(fname, force) + char_u *fname; +! int force; /* force expansion, even when it already looks +! like a full path name */ + { + char_u *buf; + char_u *new_fname = NULL; +--- 5027,5034 ---- + char_u * + FullName_save(fname, force) + char_u *fname; +! int force; /* force expansion, even when it already looks +! * like a full path name */ + { + char_u *buf; + char_u *new_fname = NULL; +*** ../vim-7.3.551/src/testdir/test68.in 2010-10-09 17:21:42.000000000 +0200 +--- src/testdir/test68.in 2012-06-13 15:49:38.000000000 +0200 +*************** +*** 51,56 **** +--- 51,77 ---- + } + + STARTTEST ++ /^{/+1 ++ :set tw=5 fo=qn comments=:# ++ gwap ++ ENDTEST ++ ++ { ++ # 1 a b ++ } ++ ++ STARTTEST ++ /^{/+1 ++ :set tw=5 fo=q2 comments=:# ++ gwap ++ ENDTEST ++ ++ { ++ # x ++ # a b ++ } ++ ++ STARTTEST + /^{/+2 + :set tw& fo=a + I^^ +*** ../vim-7.3.551/src/testdir/test68.ok 2010-10-09 17:21:42.000000000 +0200 +--- src/testdir/test68.ok 2012-06-13 15:49:38.000000000 +0200 +*************** +*** 34,38 **** +--- 34,50 ---- + } + + ++ { ++ # 1 a ++ # b ++ } ++ ++ ++ { ++ # x a ++ # b ++ } ++ ++ + { 1aa ^^2bb } + +*** ../vim-7.3.551/src/version.c 2012-06-13 14:28:16.000000000 +0200 +--- src/version.c 2012-06-13 16:36:14.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 552, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +31. You code your homework in HTML and give your instructor the URL. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f7f00170ab81e7280099fe5bb01023774f73231a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:09:03 +0200 Subject: [PATCH 0295/3340] - patchlevel 553 --- 7.3.553 | 85 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100644 7.3.553 diff --git a/7.3.553 b/7.3.553 new file mode 100644 index 00000000..82c757e1 --- /dev/null +++ b/7.3.553 @@ -0,0 +1,85 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.553 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.553 +Problem: With double-width characters and 'listchars' containing "precedes" + the text is displayed one cell off. +Solution: Check for double-width character being overwritten by the + "precedes" character. (Yasuhiro Matsumoto) +Files: src/screen.c + + +*** ../vim-7.3.552/src/screen.c 2012-06-06 19:05:45.000000000 +0200 +--- src/screen.c 2012-06-13 17:55:10.000000000 +0200 +*************** +*** 89,94 **** +--- 89,97 ---- + + #include "vim.h" + ++ #define MB_FILLER_CHAR '<' /* character used when a double-width character ++ * doesn't fit. */ ++ + /* + * The attributes that are actually active for writing to the screen. + */ +*************** +*** 4016,4022 **** + if (n_skip > 0 && mb_l > 1 && n_extra == 0) + { + n_extra = 1; +! c_extra = '<'; + c = ' '; + if (area_attr == 0 && search_attr == 0) + { +--- 4019,4025 ---- + if (n_skip > 0 && mb_l > 1 && n_extra == 0) + { + n_extra = 1; +! c_extra = MB_FILLER_CHAR; + c = ' '; + if (area_attr == 0 && search_attr == 0) + { +*************** +*** 4576,4581 **** +--- 4579,4593 ---- + c = lcs_prec; + lcs_prec_todo = NUL; + #ifdef FEAT_MBYTE ++ if (has_mbyte && (*mb_char2cells)(mb_c) > 1) ++ { ++ /* Double-width character being overwritten by the "precedes" ++ * character, need to fill up half the character. */ ++ c_extra = MB_FILLER_CHAR; ++ n_extra = 1; ++ n_attr = 2; ++ extra_attr = hl_attr(HLF_AT); ++ } + mb_c = c; + if (enc_utf8 && (*mb_char2len)(c) > 1) + { +*** ../vim-7.3.552/src/version.c 2012-06-13 17:28:51.000000000 +0200 +--- src/version.c 2012-06-13 17:48:45.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 553, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +32. You don't know what sex three of your closest friends are, because they + have neutral nicknames and you never bothered to ask. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fa82c363bd7ee798384c78553c37947170ae0484 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:09:03 +0200 Subject: [PATCH 0296/3340] - patchlevel 554 --- 7.3.554 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.554 diff --git a/7.3.554 b/7.3.554 new file mode 100644 index 00000000..e8d4d37a --- /dev/null +++ b/7.3.554 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.554 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.554 (after 7.3.551) +Problem: Compiler warning for unused argument. +Solution: Add UNUSED. +Files: src/window.c + + +*** ../vim-7.3.553/src/window.c 2012-06-13 14:28:16.000000000 +0200 +--- src/window.c 2012-06-13 17:46:49.000000000 +0200 +*************** +*** 3723,3729 **** + enter_tabpage(tp, old_curbuf, trigger_autocmds) + tabpage_T *tp; + buf_T *old_curbuf UNUSED; +! int trigger_autocmds; + { + int old_off = tp->tp_firstwin->w_winrow; + win_T *next_prevwin = tp->tp_prevwin; +--- 3723,3729 ---- + enter_tabpage(tp, old_curbuf, trigger_autocmds) + tabpage_T *tp; + buf_T *old_curbuf UNUSED; +! int trigger_autocmds UNUSED; + { + int old_off = tp->tp_firstwin->w_winrow; + win_T *next_prevwin = tp->tp_prevwin; +*** ../vim-7.3.553/src/version.c 2012-06-13 18:06:32.000000000 +0200 +--- src/version.c 2012-06-13 18:15:08.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 554, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +33. You name your children Eudora, Mozilla and Dotcom. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8f0e32a6b53b384eaa962baad2eb6e3123eee934 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:09:03 +0200 Subject: [PATCH 0297/3340] - patchlevel 555 --- 7.3.555 | 232 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 232 insertions(+) create mode 100644 7.3.555 diff --git a/7.3.555 b/7.3.555 new file mode 100644 index 00000000..acb68452 --- /dev/null +++ b/7.3.555 @@ -0,0 +1,232 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.555 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.555 +Problem: Building on IBM z/OS fails. +Solution: Adjust configure. Use the QUOTESED value from config.mk instead of + the hard coded one in Makefile. (Stephen Bovy) +Files: src/configure.in, src/auto/configure, src/Makefile + + +*** ../vim-7.3.554/src/configure.in 2012-02-05 22:51:27.000000000 +0100 +--- src/configure.in 2012-06-13 18:52:11.000000000 +0200 +*************** +*** 329,343 **** + echo "" + echo "------------------------------------------" + echo " On z/OS Unix, the environment variable" +! echo " __CC_${ccn}MODE must be set to \"1\"!" + echo " Do:" + echo " export _CC_${ccn}MODE=1" + echo " and then call configure again." + echo "------------------------------------------" + exit 1 + fi +! CFLAGS="$CFLAGS -D_ALL_SOURCE -Wc,float\\(IEEE\\)"; +! LDFLAGS="$LDFLAGS -Wl,EDIT=NO" + AC_MSG_RESULT(yes) + ;; + *) zOSUnix="no"; +--- 329,346 ---- + echo "" + echo "------------------------------------------" + echo " On z/OS Unix, the environment variable" +! echo " _CC_${ccn}MODE must be set to \"1\"!" + echo " Do:" + echo " export _CC_${ccn}MODE=1" + echo " and then call configure again." + echo "------------------------------------------" + exit 1 + fi +! # Set CFLAGS for configure process. +! # This will be reset later for config.mk. +! # Use haltonmsg to force error for missing H files. +! CFLAGS="$CFLAGS -D_ALL_SOURCE -Wc,float(ieee),haltonmsg(3296)"; +! LDFLAGS="$LDFLAGS -Wl,EDIT=NO" + AC_MSG_RESULT(yes) + ;; + *) zOSUnix="no"; +*************** +*** 2378,2387 **** + if test -z "$SKIP_MOTIF"; then + cppflags_save=$CPPFLAGS + CPPFLAGS="$CPPFLAGS $X_CFLAGS" +! AC_CHECK_HEADERS(Xm/Xm.h Xm/XpmP.h Xm/JoinSideT.h Xm/TraitP.h Xm/Manager.h \ +! Xm/UnhighlightT.h Xm/Notebook.h) + +! if test $ac_cv_header_Xm_XpmP_h = yes; then + dnl Solaris uses XpmAttributes_21, very annoying. + AC_MSG_CHECKING([for XpmAttributes_21 in Xm/XpmP.h]) + AC_TRY_COMPILE([#include ], [XpmAttributes_21 attr;], +--- 2381,2395 ---- + if test -z "$SKIP_MOTIF"; then + cppflags_save=$CPPFLAGS + CPPFLAGS="$CPPFLAGS $X_CFLAGS" +! if test "$zOSUnix" = "yes"; then +! xmheader="Xm/Xm.h" +! else +! xmheader="Xm/Xm.h Xm/XpmP.h Xm/JoinSideT.h Xm/TraitP.h Xm/Manager.h +! Xm/UnhighlightT.h Xm/Notebook.h" +! fi +! AC_CHECK_HEADERS($xmheader) + +! if test "x$ac_cv_header_Xm_XpmP_h" = "xyes"; then + dnl Solaris uses XpmAttributes_21, very annoying. + AC_MSG_CHECKING([for XpmAttributes_21 in Xm/XpmP.h]) + AC_TRY_COMPILE([#include ], [XpmAttributes_21 attr;], +*************** +*** 3642,3647 **** +--- 3650,3660 ---- + fi + AC_SUBST(LINK_AS_NEEDED) + ++ # IBM z/OS reset CFLAGS for config.mk ++ if test "$zOSUnix" = "yes"; then ++ CFLAGS="-D_ALL_SOURCE -Wc,float\(ieee\),dll" ++ fi ++ + dnl write output files + AC_OUTPUT(auto/config.mk:config.mk.in) + +*** ../vim-7.3.554/src/auto/configure 2012-02-05 22:51:27.000000000 +0100 +--- src/auto/configure 2012-06-13 18:53:04.000000000 +0200 +*************** +*** 4426,4440 **** + echo "" + echo "------------------------------------------" + echo " On z/OS Unix, the environment variable" +! echo " __CC_${ccn}MODE must be set to \"1\"!" + echo " Do:" + echo " export _CC_${ccn}MODE=1" + echo " and then call configure again." + echo "------------------------------------------" + exit 1 + fi +! CFLAGS="$CFLAGS -D_ALL_SOURCE -Wc,float\\(IEEE\\)"; +! LDFLAGS="$LDFLAGS -Wl,EDIT=NO" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 + $as_echo "yes" >&6; } + ;; +--- 4426,4443 ---- + echo "" + echo "------------------------------------------" + echo " On z/OS Unix, the environment variable" +! echo " _CC_${ccn}MODE must be set to \"1\"!" + echo " Do:" + echo " export _CC_${ccn}MODE=1" + echo " and then call configure again." + echo "------------------------------------------" + exit 1 + fi +! # Set CFLAGS for configure process. +! # This will be reset later for config.mk. +! # Use haltonmsg to force error for missing H files. +! CFLAGS="$CFLAGS -D_ALL_SOURCE -Wc,float(ieee),haltonmsg(3296)"; +! LDFLAGS="$LDFLAGS -Wl,EDIT=NO" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 + $as_echo "yes" >&6; } + ;; +*************** +*** 8697,8704 **** + if test -z "$SKIP_MOTIF"; then + cppflags_save=$CPPFLAGS + CPPFLAGS="$CPPFLAGS $X_CFLAGS" +! for ac_header in Xm/Xm.h Xm/XpmP.h Xm/JoinSideT.h Xm/TraitP.h Xm/Manager.h \ +! Xm/UnhighlightT.h Xm/Notebook.h + do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` + ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +--- 8700,8712 ---- + if test -z "$SKIP_MOTIF"; then + cppflags_save=$CPPFLAGS + CPPFLAGS="$CPPFLAGS $X_CFLAGS" +! if test "$zOSUnix" = "yes"; then +! xmheader="Xm/Xm.h" +! else +! xmheader="Xm/Xm.h Xm/XpmP.h Xm/JoinSideT.h Xm/TraitP.h Xm/Manager.h +! Xm/UnhighlightT.h Xm/Notebook.h" +! fi +! for ac_header in $xmheader + do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` + ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +*************** +*** 8713,8719 **** + done + + +! if test $ac_cv_header_Xm_XpmP_h = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmAttributes_21 in Xm/XpmP.h" >&5 + $as_echo_n "checking for XpmAttributes_21 in Xm/XpmP.h... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +--- 8721,8727 ---- + done + + +! if test "x$ac_cv_header_Xm_XpmP_h" = "xyes"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmAttributes_21 in Xm/XpmP.h" >&5 + $as_echo_n "checking for XpmAttributes_21 in Xm/XpmP.h... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +*************** +*** 12590,12595 **** +--- 12598,12608 ---- + fi + + ++ # IBM z/OS reset CFLAGS for config.mk ++ if test "$zOSUnix" = "yes"; then ++ CFLAGS="-D_ALL_SOURCE -Wc,float\(ieee\),dll" ++ fi ++ + ac_config_files="$ac_config_files auto/config.mk:config.mk.in" + + cat >confcache <<\_ACEOF +*** ../vim-7.3.554/src/Makefile 2012-03-28 17:17:45.000000000 +0200 +--- src/Makefile 2012-06-13 18:48:13.000000000 +0200 +*************** +*** 875,880 **** +--- 875,884 ---- + #CFLAGS = -O -Qtarget=m88110compat + #EXTRA_LIBS = -lgen + ++ # The value of QUOTESED comes from auto/config.mk. ++ # Uncomment the next line to use the default value. ++ # QUOTESED = sed -e 's/[\\"]/\\&/g' -e 's/\\"/"/' -e 's/\\";$$/";/' ++ + ##################### end of system specific lines ################### }}} + + ### Names of the programs and targets {{{1 +*************** +*** 2411,2417 **** + auto/osdef.h: auto/config.h osdef.sh osdef1.h.in osdef2.h.in + CC="$(CC) $(OSDEF_CFLAGS)" srcdir=$(srcdir) sh $(srcdir)/osdef.sh + +- QUOTESED = sed -e 's/[\\"]/\\&/g' -e 's/\\"/"/' -e 's/\\";$$/";/' + auto/pathdef.c: Makefile auto/config.mk + -@echo creating $@ + -@echo '/* pathdef.c */' > $@ +--- 2415,2420 ---- +*** ../vim-7.3.554/src/version.c 2012-06-13 18:15:13.000000000 +0200 +--- src/version.c 2012-06-13 19:13:54.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 555, + /**/ + +-- +My sister Cecilia opened a computer store in Hawaii. +She sells C shells by the seashore. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ca34cbb68fc73d81ddbcafddafe2642d0242078e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:09:03 +0200 Subject: [PATCH 0298/3340] - patchlevel 556 --- 7.3.556 | 70 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 7.3.556 diff --git a/7.3.556 b/7.3.556 new file mode 100644 index 00000000..068b8d1f --- /dev/null +++ b/7.3.556 @@ -0,0 +1,70 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.556 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.556 +Problem: Compiler warnings on 64 bit Windows. +Solution: Add type casts. (Mike Williams) +Files: src/misc1.c + + +*** ../vim-7.3.555/src/misc1.c 2012-06-13 17:28:51.000000000 +0200 +--- src/misc1.c 2012-06-14 20:55:47.000000000 +0200 +*************** +*** 445,452 **** + if (vim_regexec(®match, ml_get(lnum) + lead_len, (colnr_T)0)) + { + pos.lnum = lnum; +! pos.col = *regmatch.endp - (ml_get(lnum) + lead_len); +! pos.col += lead_len; + #ifdef FEAT_VIRTUALEDIT + pos.coladd = 0; + #endif +--- 445,451 ---- + if (vim_regexec(®match, ml_get(lnum) + lead_len, (colnr_T)0)) + { + pos.lnum = lnum; +! pos.col = (colnr_T)(*regmatch.endp - ml_get(lnum)); + #ifdef FEAT_VIRTUALEDIT + pos.coladd = 0; + #endif +*************** +*** 1354,1360 **** + if (flags & OPENLINE_COM_LIST && second_line_indent > 0) + { + int i; +! int padding = second_line_indent - (newindent + STRLEN(leader)); + + /* Here whitespace is inserted after the comment char. + * Below, set_indent(newindent, SIN_INSERT) will insert the +--- 1353,1360 ---- + if (flags & OPENLINE_COM_LIST && second_line_indent > 0) + { + int i; +! int padding = second_line_indent +! - (newindent + (int)STRLEN(leader)); + + /* Here whitespace is inserted after the comment char. + * Below, set_indent(newindent, SIN_INSERT) will insert the +*** ../vim-7.3.555/src/version.c 2012-06-13 19:19:36.000000000 +0200 +--- src/version.c 2012-06-14 20:54:59.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 556, + /**/ + +-- +He who laughs last, thinks slowest. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9a75430f62cfde14a061ef86cd7e3d7ce3f91ea1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Jun 2012 11:09:04 +0200 Subject: [PATCH 0299/3340] - patchlevel 556 --- README.patches | 41 ++++++++++++++++++++++++ vim.spec | 87 +++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 127 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index e0e5ed70..c9045377 100644 --- a/README.patches +++ b/README.patches @@ -546,3 +546,44 @@ Individual patches for Vim 7.3: 3925 7.3.513 cannot use CTRL-E and CTRL-Y with "r" 7792 7.3.514 no completion for :history command 2073 7.3.515 'wildignorecase' only applies to the last part of the path + 2784 7.3.516 extend(o, o) may crash Vim + 1718 7.3.517 crash when using "vipvv" + 1976 7.3.518 ":helptags" cannot find tag when 'encoding' is double-byte + 1894 7.3.519 completefunction cannot indicate end of completion mode + 4238 7.3.520 Gvim starts up slow on Unbuntu 12.04 + 3388 7.3.521 spell checking may crash when using multi-byte characters + 1885 7.3.522 crash in vim_realloc() when using MEM_PROFILE + 3493 7.3.523 ":diffupdate" doesn't check for files changed elsewhere + 1271 7.3.524 missing comma in version.c + 1884 7.3.525 compiler warning on 64 bit MS-Windows + 1950 7.3.526 confusing indenting for #ifdef + 4408 7.3.527 clang complains about non-ASCII characters in a string + 5919 7.3.528 crash when closing last window in a tab + 2439 7.3.529 using a count before "v" and "V" does not work + 1559 7.3.530 (after 7.3.520) gvim does not work when 'guioptions' has "f" + 1546 7.3.531 (after 7.3.530) GUI does not work on MS-Windows + 1685 7.3.532 compiler warning from Clang + 1323 7.3.533 memory leak when writing undo file + 2944 7.3.534 (after 7.3.461) autoindent fails with InsertCharPre autocmd + 8436 7.3.535 many #ifdefs for MB_MAXBYTES + 2014 7.3.536 German sharp s is not seen as a word character + 1352 7.3.537 unecessary call to init_spell_chartab() + 9735 7.3.538 'efm' does not handle Tabs in pointer lines + 1625 7.3.539 redraw multi-byte char on command line does not work properly + 1658 7.3.540 cursor is left on the text instead of the command line + 31063 7.3.541 when joining lines comment leaders need to be removed manually + 2240 7.3.542 (after 7.3.506) function is sometimes unused + 1632 7.3.543 the cursor is in the wrong line after using ":copen" + 3088 7.3.544 no autocommand for :quit before deciding to exit + 10435 7.3.545 autocommands may close a window that is already being closed + 1628 7.3.546 weird line break + 1661 7.3.547 (after 7.3.541) compiler warning for uninitialized variable + 1552 7.3.548 compiler warning on 64 bit Windows + 2957 7.3.549 in 'cinoptions' "0s" is interpreted as one shiftwidth + 4392 7.3.550 (after 7.3.541) with "j" in 'fo' a list leader is not removed + 13725 7.3.551 on :tablose a TabEnter autocommand is triggered too early + 17001 7.3.552 inside comments formatting does not use the "2" flag in 'fo' + 2515 7.3.553 text displayed one cell off if 'listchars' contains "precedes" + 1660 7.3.554 compiler warning for unused argument + 7968 7.3.555 building on IBM z/OS fails + 2194 7.3.556 compiler warnings on 64 bit Windows diff --git a/vim.spec b/vim.spec index c67a0ea2..b3b5975c 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 515 +%define patchlevel 556 Summary: The VIM editor URL: http://www.vim.org/ @@ -571,6 +571,47 @@ Patch512: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.512 Patch513: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.513 Patch514: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.514 Patch515: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.515 +Patch516: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.516 +Patch517: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.517 +Patch518: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.518 +Patch519: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.519 +Patch520: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.520 +Patch521: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.521 +Patch522: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.522 +Patch523: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.523 +Patch524: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.524 +Patch525: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.525 +Patch526: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.526 +Patch527: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.527 +Patch528: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.528 +Patch529: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.529 +Patch530: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.530 +Patch531: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.531 +Patch532: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.532 +Patch533: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.533 +Patch534: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.534 +Patch535: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.535 +Patch536: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.536 +Patch537: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.537 +Patch538: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.538 +Patch539: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.539 +Patch540: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.540 +Patch541: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.541 +Patch542: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.542 +Patch543: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.543 +Patch544: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.544 +Patch545: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.545 +Patch546: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.546 +Patch547: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.547 +Patch548: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.548 +Patch549: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.549 +Patch550: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.550 +Patch551: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.551 +Patch552: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.552 +Patch553: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.553 +Patch554: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.554 +Patch555: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.555 +Patch556: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.556 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1232,6 +1273,47 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch513 -p0 %patch514 -p0 %patch515 -p0 +%patch516 -p0 +%patch517 -p0 +%patch518 -p0 +%patch519 -p0 +%patch520 -p0 +%patch521 -p0 +%patch522 -p0 +%patch523 -p0 +%patch524 -p0 +%patch525 -p0 +%patch526 -p0 +%patch527 -p0 +%patch528 -p0 +%patch529 -p0 +%patch530 -p0 +%patch531 -p0 +%patch532 -p0 +%patch533 -p0 +%patch534 -p0 +%patch535 -p0 +%patch536 -p0 +%patch537 -p0 +%patch538 -p0 +%patch539 -p0 +%patch540 -p0 +%patch541 -p0 +%patch542 -p0 +%patch543 -p0 +%patch544 -p0 +%patch545 -p0 +%patch546 -p0 +%patch547 -p0 +%patch548 -p0 +%patch549 -p0 +%patch550 -p0 +%patch551 -p0 +%patch552 -p0 +%patch553 -p0 +%patch554 -p0 +%patch555 -p0 +%patch556 -p0 # install spell files @@ -1688,6 +1770,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Jun 18 2012 Karsten Hopp 7.3.556-1 +- patchlevel 556 + * Mon May 21 2012 Karsten Hopp 7.3.515-1 - enable highlighting for older log files (#816848) From 5eb5991ba21db5ed5d6f4794fe09645ac17e82c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= Date: Thu, 28 Jun 2012 14:45:35 +0200 Subject: [PATCH 0300/3340] Perl 5.16 rebuild --- vim.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vim.spec b/vim.spec index a1511672..671cd9fe 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1%{?dist} +Release: 2%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -1770,6 +1770,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Thu Jun 28 2012 Petr Pisar - 2:7.3.556-2 +- Perl 5.16 rebuild + * Mon Jun 18 2012 Karsten Hopp 7.3.556-1 - patchlevel 556 From 495b161eb1de4ec9e3a540cb42d8d47786adf551 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:08 +0200 Subject: [PATCH 0301/3340] - patchlevel 557 --- 7.3.557 | 99 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 99 insertions(+) create mode 100644 7.3.557 diff --git a/7.3.557 b/7.3.557 new file mode 100644 index 00000000..663c0720 --- /dev/null +++ b/7.3.557 @@ -0,0 +1,99 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.557 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.557 +Problem: Crash when an autocommand wipes out a buffer when it is hidden. +Solution: Restore the current window when needed. (Christian Brabandt) +Files: src/buffer.c + + +*** ../vim-7.3.556/src/buffer.c 2012-06-13 14:28:16.000000000 +0200 +--- src/buffer.c 2012-06-20 11:49:54.000000000 +0200 +*************** +*** 1363,1368 **** +--- 1363,1369 ---- + int action; + { + buf_T *prevbuf; ++ win_T *prevwin; + int unload = (action == DOBUF_UNLOAD || action == DOBUF_DEL + || action == DOBUF_WIPE); + +*************** +*** 1402,1423 **** + if (buf_valid(prevbuf)) + #endif + { + if (prevbuf == curbuf) + u_sync(FALSE); + close_buffer(prevbuf == curwin->w_buffer ? curwin : NULL, prevbuf, + unload ? action : (action == DOBUF_GOTO + && !P_HID(prevbuf) + && !bufIsChanged(prevbuf)) ? DOBUF_UNLOAD : 0, FALSE); + } + } + #ifdef FEAT_AUTOCMD + /* An autocommand may have deleted "buf", already entered it (e.g., when +! * it did ":bunload") or aborted the script processing! */ +! # ifdef FEAT_EVAL +! if (buf_valid(buf) && buf != curbuf && !aborting()) +! # else +! if (buf_valid(buf) && buf != curbuf) +! # endif + #endif + enter_buffer(buf); + } +--- 1403,1432 ---- + if (buf_valid(prevbuf)) + #endif + { ++ prevwin = curwin; + if (prevbuf == curbuf) + u_sync(FALSE); + close_buffer(prevbuf == curwin->w_buffer ? curwin : NULL, prevbuf, + unload ? action : (action == DOBUF_GOTO + && !P_HID(prevbuf) + && !bufIsChanged(prevbuf)) ? DOBUF_UNLOAD : 0, FALSE); ++ if (curwin != prevwin && win_valid(prevwin)) ++ /* autocommands changed curwin, Grr! */ ++ curwin = prevwin; + } + } + #ifdef FEAT_AUTOCMD + /* An autocommand may have deleted "buf", already entered it (e.g., when +! * it did ":bunload") or aborted the script processing! +! * If curwin->w_buffer is null, enter_buffer() will make it valid again */ +! if ((buf_valid(buf) && buf != curbuf +! #ifdef FEAT_EVAL +! && !aborting() +! #endif +! #ifdef FEAT_WINDOWS +! ) || curwin->w_buffer == NULL +! #endif +! ) + #endif + enter_buffer(buf); + } +*** ../vim-7.3.556/src/version.c 2012-06-14 20:59:20.000000000 +0200 +--- src/version.c 2012-06-20 11:53:56.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 557, + /**/ + +-- +Don't read everything you believe. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 62362fc49aefe29d5f50fa57c1645842fc8d7086 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:08 +0200 Subject: [PATCH 0302/3340] - patchlevel 558 --- 7.3.558 | 90 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) create mode 100644 7.3.558 diff --git a/7.3.558 b/7.3.558 new file mode 100644 index 00000000..015bc37d --- /dev/null +++ b/7.3.558 @@ -0,0 +1,90 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.558 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.558 +Problem: Memory access error. (Gary Johnson) +Solution: Allocate one more byte. (Dominique Pelle) +Files: src/misc1.c + + +*** ../vim-7.3.557/src/misc1.c 2012-06-14 20:59:20.000000000 +0200 +--- src/misc1.c 2012-06-20 12:34:57.000000000 +0200 +*************** +*** 460,466 **** + * + * I'm not sure if regmmatch_T (multi-match) is needed in this case. + * It may be true that this section would work properly using the +! * regmatch_T code above, in which case, these two seperate sections + * should be consolidated w/ FEAT_COMMENTS making lead_len > 0... + */ + #endif +--- 460,466 ---- + * + * I'm not sure if regmmatch_T (multi-match) is needed in this case. + * It may be true that this section would work properly using the +! * regmatch_T code above, in which case, these two separate sections + * should be consolidated w/ FEAT_COMMENTS making lead_len > 0... + */ + #endif +*************** +*** 1053,1061 **** + } + if (lead_len) + { +! /* allocate buffer (may concatenate p_exta later) */ + leader = alloc(lead_len + lead_repl_len + extra_space + extra_len +! + (second_line_indent > 0 ? second_line_indent : 0)); + allocated = leader; /* remember to free it later */ + + if (leader == NULL) +--- 1053,1061 ---- + } + if (lead_len) + { +! /* allocate buffer (may concatenate p_extra later) */ + leader = alloc(lead_len + lead_repl_len + extra_space + extra_len +! + (second_line_indent > 0 ? second_line_indent : 0) + 1); + allocated = leader; /* remember to free it later */ + + if (leader == NULL) +*************** +*** 3342,3348 **** + buf = alloc(buflen); + else if (maxlen < 10) + { +! /* Need some more space. This migth happen when receiving a long + * escape sequence. */ + buflen += 100; + buf = vim_realloc(buf, buflen); +--- 3342,3348 ---- + buf = alloc(buflen); + else if (maxlen < 10) + { +! /* Need some more space. This might happen when receiving a long + * escape sequence. */ + buflen += 100; + buf = vim_realloc(buf, buflen); +*** ../vim-7.3.557/src/version.c 2012-06-20 11:54:55.000000000 +0200 +--- src/version.c 2012-06-20 12:36:29.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 558, + /**/ + +-- +George: "I just got a new set of golf clubs for my wife!" + John: "Great trade!" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 21fddab2c4add54e457530a39c3f650e915d290d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:08 +0200 Subject: [PATCH 0303/3340] - patchlevel 559 --- 7.3.559 | 131 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 131 insertions(+) create mode 100644 7.3.559 diff --git a/7.3.559 b/7.3.559 new file mode 100644 index 00000000..df767372 --- /dev/null +++ b/7.3.559 @@ -0,0 +1,131 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.559 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.559 +Problem: home_replace() does not work with 8.3 filename. +Solution: Make ":p" expand 8.3 name to full path. (Yasuhiro Matsumoto) +Files: src/eval.c, src/misc1.c + + +*** ../vim-7.3.558/src/eval.c 2012-06-13 14:28:16.000000000 +0200 +--- src/eval.c 2012-06-20 13:52:47.000000000 +0200 +*************** +*** 23554,23559 **** +--- 23554,23580 ---- + return -1; + } + ++ #ifdef WIN3264 ++ # if _WIN32_WINNT >= 0x0500 ++ if (vim_strchr(*fnamep, '~') != NULL) ++ { ++ /* Expand 8.3 filename to full path. Needed to make sure the same ++ * file does not have two different names. ++ * Note: problem does not occur if _WIN32_WINNT < 0x0500. */ ++ p = alloc(_MAX_PATH + 1); ++ if (p != NULL) ++ { ++ if (GetLongPathName(*fnamep, p, MAXPATHL)) ++ { ++ vim_free(*bufp); ++ *bufp = *fnamep = p; ++ } ++ else ++ vim_free(p); ++ } ++ } ++ # endif ++ #endif + /* Append a path separator to a directory. */ + if (mch_isdir(*fnamep)) + { +*** ../vim-7.3.558/src/misc1.c 2012-06-20 12:40:01.000000000 +0200 +--- src/misc1.c 2012-06-20 13:57:22.000000000 +0200 +*************** +*** 4499,4505 **** + { + size_t dirlen = 0, envlen = 0; + size_t len; +! char_u *homedir_env; + char_u *p; + + if (src == NULL) +--- 4499,4505 ---- + { + size_t dirlen = 0, envlen = 0; + size_t len; +! char_u *homedir_env, *homedir_env_orig; + char_u *p; + + if (src == NULL) +*************** +*** 4525,4533 **** + dirlen = STRLEN(homedir); + + #ifdef VMS +! homedir_env = mch_getenv((char_u *)"SYS$LOGIN"); + #else +! homedir_env = mch_getenv((char_u *)"HOME"); + #endif + + if (homedir_env != NULL && *homedir_env == NUL) +--- 4525,4548 ---- + dirlen = STRLEN(homedir); + + #ifdef VMS +! homedir_env_orig = homedir_env = mch_getenv((char_u *)"SYS$LOGIN"); + #else +! homedir_env_orig = homedir_env = mch_getenv((char_u *)"HOME"); +! #endif +! #if defined(FEAT_MODIFY_FNAME) || defined(WIN3264) +! if (vim_strchr(homedir_env, '~') != NULL) +! { +! int usedlen = 0; +! int flen; +! char_u *fbuf = NULL; +! +! flen = (int)STRLEN(homedir_env); +! (void)modify_fname(":p", &usedlen, &homedir_env, &fbuf, &flen); +! flen = (int)STRLEN(homedir_env); +! if (flen > 0 && vim_ispathsep(homedir_env[flen - 1])) +! /* Remove the trailing / that is added to a directory. */ +! homedir_env[flen - 1] = NUL; +! } + #endif + + if (homedir_env != NULL && *homedir_env == NUL) +*************** +*** 4585,4590 **** +--- 4600,4608 ---- + /* if (dstlen == 0) out of space, what to do??? */ + + *dst = NUL; ++ ++ if (homedir_env != homedir_env_orig) ++ vim_free(homedir_env); + } + + /* +*** ../vim-7.3.558/src/version.c 2012-06-20 12:40:01.000000000 +0200 +--- src/version.c 2012-06-20 14:02:11.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 559, + /**/ + +-- +The future isn't what it used to be. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8de54c7c9520f5ba9d9e8ba8fd25574aa5b4fb43 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:09 +0200 Subject: [PATCH 0304/3340] - patchlevel 560 --- 7.3.560 | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 7.3.560 diff --git a/7.3.560 b/7.3.560 new file mode 100644 index 00000000..7f464111 --- /dev/null +++ b/7.3.560 @@ -0,0 +1,49 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.560 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.560 +Problem: Get an error for a locked argument in extend(). +Solution: Initialize the lock flag for a dictionary. (Yukihiro Nakadaira) +Files: src/eval.c + + +*** ../vim-7.3.559/src/eval.c 2012-06-20 14:02:23.000000000 +0200 +--- src/eval.c 2012-06-20 14:08:34.000000000 +0200 +*************** +*** 19981,19986 **** +--- 19981,19987 ---- + dictitem_T *dict_var; + { + hash_init(&dict->dv_hashtab); ++ dict->dv_lock = 0; + dict->dv_refcount = DO_NOT_FREE_CNT; + dict->dv_copyID = 0; + dict_var->di_tv.vval.v_dict = dict; +*** ../vim-7.3.559/src/version.c 2012-06-20 14:02:23.000000000 +0200 +--- src/version.c 2012-06-20 14:09:34.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 560, + /**/ + +-- +"Oh, no! NOT the Spanish Inquisition!" +"NOBODY expects the Spanish Inquisition!!!" + -- Monty Python sketch -- +"Oh, no! NOT another option!" +"EVERYBODY expects another option!!!" + -- Discussion in vim-dev mailing list -- + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b63aa53fe99d20b2b2b766a893f71fee9dca2e3f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:09 +0200 Subject: [PATCH 0305/3340] - patchlevel 561 --- 7.3.561 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.561 diff --git a/7.3.561 b/7.3.561 new file mode 100644 index 00000000..d51030c4 --- /dev/null +++ b/7.3.561 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.561 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.561 +Problem: Using refresh: always in a complete function breaks the "." + command. (Val Markovic) +Solution: Add match leader to the redo buffer. (Yasuhiro Matsumoto) +Files: src/edit.c + + +*** ../vim-7.3.560/src/edit.c 2012-06-13 17:28:51.000000000 +0200 +--- src/edit.c 2012-06-20 14:22:23.000000000 +0200 +*************** +*** 3467,3476 **** +--- 3467,3480 ---- + (*mb_char2bytes)(c, buf); + buf[cc] = NUL; + ins_char_bytes(buf, cc); ++ AppendToRedobuff(buf); + } + else + #endif ++ { + ins_char(c); ++ AppendCharToRedobuff(c); ++ } + + /* If we didn't complete finding matches we must search again. */ + if (ins_compl_need_restart()) +*** ../vim-7.3.560/src/version.c 2012-06-20 14:13:02.000000000 +0200 +--- src/version.c 2012-06-20 14:20:13.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 561, + /**/ + +-- +Microsoft is to software what McDonalds is to gourmet cooking + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9bad998ce2c5fc72446b29f43f36e8a436308775 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:09 +0200 Subject: [PATCH 0306/3340] - patchlevel 562 --- 7.3.562 | 63 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 7.3.562 diff --git a/7.3.562 b/7.3.562 new file mode 100644 index 00000000..626de495 --- /dev/null +++ b/7.3.562 @@ -0,0 +1,63 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.562 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.562 +Problem: ":profdel" should not work when the +profile feature is disabled. +Solution: Call ex_ni(). (Yasuhiro Matsumoto) +Files: src/ex_cmds2.c + + +*** ../vim-7.3.561/src/ex_cmds2.c 2012-06-13 14:28:16.000000000 +0200 +--- src/ex_cmds2.c 2012-06-20 15:43:44.000000000 +0200 +*************** +*** 596,605 **** + garray_T *gap; + + gap = &dbg_breakp; +- #ifdef FEAT_PROFILE + if (eap->cmdidx == CMD_profdel) + gap = &prof_ga; + #endif + + if (vim_isdigit(*eap->arg)) + { +--- 596,610 ---- + garray_T *gap; + + gap = &dbg_breakp; + if (eap->cmdidx == CMD_profdel) ++ { ++ #ifdef FEAT_PROFILE + gap = &prof_ga; ++ #else ++ ex_ni(eap); ++ return; + #endif ++ } + + if (vim_isdigit(*eap->arg)) + { +*** ../vim-7.3.561/src/version.c 2012-06-20 14:26:30.000000000 +0200 +--- src/version.c 2012-06-20 15:44:00.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 562, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +42. Your virtual girlfriend finds a new net sweetheart with a larger bandwidth. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0175108f3e7991b96ab620a62605c0ff0108e748 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:10 +0200 Subject: [PATCH 0307/3340] - patchlevel 563 --- 7.3.563 | 97 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100644 7.3.563 diff --git a/7.3.563 b/7.3.563 new file mode 100644 index 00000000..c2ebf410 --- /dev/null +++ b/7.3.563 @@ -0,0 +1,97 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.563 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.563 (after 7.3.557) +Problem: Can't build with tiny features. +Solution: Add #ifdef. +Files: src/buffer.c + + +*** ../vim-7.3.562/src/buffer.c 2012-06-20 11:54:55.000000000 +0200 +--- src/buffer.c 2012-06-20 17:40:59.000000000 +0200 +*************** +*** 1363,1369 **** +--- 1363,1371 ---- + int action; + { + buf_T *prevbuf; ++ #ifdef FEAT_WINDOWS + win_T *prevwin; ++ #endif + int unload = (action == DOBUF_UNLOAD || action == DOBUF_DEL + || action == DOBUF_WIPE); + +*************** +*** 1403,1418 **** +--- 1405,1424 ---- + if (buf_valid(prevbuf)) + #endif + { ++ #ifdef FEAT_WINDOWS + prevwin = curwin; ++ #endif + if (prevbuf == curbuf) + u_sync(FALSE); + close_buffer(prevbuf == curwin->w_buffer ? curwin : NULL, prevbuf, + unload ? action : (action == DOBUF_GOTO + && !P_HID(prevbuf) + && !bufIsChanged(prevbuf)) ? DOBUF_UNLOAD : 0, FALSE); ++ #ifdef FEAT_WINDOWS + if (curwin != prevwin && win_valid(prevwin)) + /* autocommands changed curwin, Grr! */ + curwin = prevwin; ++ #endif + } + } + #ifdef FEAT_AUTOCMD +*************** +*** 1420,1431 **** + * it did ":bunload") or aborted the script processing! + * If curwin->w_buffer is null, enter_buffer() will make it valid again */ + if ((buf_valid(buf) && buf != curbuf +! #ifdef FEAT_EVAL + && !aborting() +! #endif +! #ifdef FEAT_WINDOWS + ) || curwin->w_buffer == NULL +! #endif + ) + #endif + enter_buffer(buf); +--- 1426,1437 ---- + * it did ":bunload") or aborted the script processing! + * If curwin->w_buffer is null, enter_buffer() will make it valid again */ + if ((buf_valid(buf) && buf != curbuf +! # ifdef FEAT_EVAL + && !aborting() +! # endif +! # ifdef FEAT_WINDOWS + ) || curwin->w_buffer == NULL +! # endif + ) + #endif + enter_buffer(buf); +*** ../vim-7.3.562/src/version.c 2012-06-20 15:48:53.000000000 +0200 +--- src/version.c 2012-06-20 17:54:01.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 563, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +45. You buy a Captain Kirk chair with a built-in keyboard and mouse. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5d113c19925564502b574cc7111c1c569613594b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:10 +0200 Subject: [PATCH 0308/3340] - patchlevel 564 --- 7.3.564 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.564 diff --git a/7.3.564 b/7.3.564 new file mode 100644 index 00000000..e806b8e4 --- /dev/null +++ b/7.3.564 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.564 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.564 (after 7.3.559) +Problem: Warning for pointer conversion. +Solution: Add type cast. +Files: src/misc1.c + + +*** ../vim-7.3.563/src/misc1.c 2012-06-20 14:02:23.000000000 +0200 +--- src/misc1.c 2012-06-20 17:41:22.000000000 +0200 +*************** +*** 4537,4543 **** + char_u *fbuf = NULL; + + flen = (int)STRLEN(homedir_env); +! (void)modify_fname(":p", &usedlen, &homedir_env, &fbuf, &flen); + flen = (int)STRLEN(homedir_env); + if (flen > 0 && vim_ispathsep(homedir_env[flen - 1])) + /* Remove the trailing / that is added to a directory. */ +--- 4537,4544 ---- + char_u *fbuf = NULL; + + flen = (int)STRLEN(homedir_env); +! (void)modify_fname((char_u *)":p", &usedlen, +! &homedir_env, &fbuf, &flen); + flen = (int)STRLEN(homedir_env); + if (flen > 0 && vim_ispathsep(homedir_env[flen - 1])) + /* Remove the trailing / that is added to a directory. */ +*** ../vim-7.3.563/src/version.c 2012-06-20 17:54:34.000000000 +0200 +--- src/version.c 2012-06-20 17:55:26.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 564, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +46. Your wife makes a new rule: "The computer cannot come to bed." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 294214a86367e0801fa0529134adea496dba963d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:10 +0200 Subject: [PATCH 0309/3340] - patchlevel 565 --- 7.3.565 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.565 diff --git a/7.3.565 b/7.3.565 new file mode 100644 index 00000000..171520b3 --- /dev/null +++ b/7.3.565 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.566 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.566 +Problem: Can't generate proto file for Python 3. +Solution: Add PYTHON3_CFLAGS to LINT_CFLAGS. +Files: src/Makefile + + +*** ../vim-7.3.564/src/Makefile 2012-06-13 19:19:36.000000000 +0200 +--- src/Makefile 2012-06-20 18:36:14.000000000 +0200 +*************** +*** 1339,1345 **** + # with "-E". + OSDEF_CFLAGS = $(PRE_DEFS) $(POST_DEFS) + +! LINT_CFLAGS = -DLINT -I. $(PRE_DEFS) $(POST_DEFS) $(RUBY_CFLAGS) $(LUA_CFLAGS) $(PERL_CFLAGS) $(PYTHON_CFLAGS) -Dinline= -D__extension__= -Dalloca=alloca + + LINT_EXTRA = -DUSE_SNIFF -DHANGUL_INPUT -D"__attribute__(x)=" + +--- 1339,1345 ---- + # with "-E". + OSDEF_CFLAGS = $(PRE_DEFS) $(POST_DEFS) + +! LINT_CFLAGS = -DLINT -I. $(PRE_DEFS) $(POST_DEFS) $(RUBY_CFLAGS) $(LUA_CFLAGS) $(PERL_CFLAGS) $(PYTHON_CFLAGS) $(PYTHON3_CFLAGS) -Dinline= -D__extension__= -Dalloca=alloca + + LINT_EXTRA = -DUSE_SNIFF -DHANGUL_INPUT -D"__attribute__(x)=" + +*** ../vim-7.3.564/src/version.c 2012-06-20 17:56:06.000000000 +0200 +--- src/version.c 2012-06-20 18:39:04.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 565, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +47. You are so familiar with the WWW that you find the search engines useless. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0904460f336e295694ade4df140cb5833dd0589d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:10 +0200 Subject: [PATCH 0310/3340] - patchlevel 566 --- 7.3.566 | 83 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 7.3.566 diff --git a/7.3.566 b/7.3.566 new file mode 100644 index 00000000..a0600e81 --- /dev/null +++ b/7.3.566 @@ -0,0 +1,83 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.566 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.566 (after 7.3.561) +Problem: Redo after completion does not work correctly when refresh: always + is not used. (Raymond Ko) +Solution: Check the compl_opt_refresh_always flag. (Christian Brabandt) +Files: src/edit.c + + +*** ../vim-7.3.565/src/edit.c 2012-06-20 14:26:30.000000000 +0200 +--- src/edit.c 2012-06-20 22:52:03.000000000 +0200 +*************** +*** 3467,3479 **** + (*mb_char2bytes)(c, buf); + buf[cc] = NUL; + ins_char_bytes(buf, cc); +! AppendToRedobuff(buf); + } + else + #endif + { + ins_char(c); +! AppendCharToRedobuff(c); + } + + /* If we didn't complete finding matches we must search again. */ +--- 3467,3481 ---- + (*mb_char2bytes)(c, buf); + buf[cc] = NUL; + ins_char_bytes(buf, cc); +! if (compl_opt_refresh_always) +! AppendToRedobuff(buf); + } + else + #endif + { + ins_char(c); +! if (compl_opt_refresh_always) +! AppendCharToRedobuff(c); + } + + /* If we didn't complete finding matches we must search again. */ +*************** +*** 3481,3487 **** + ins_compl_restart(); + + /* When 'always' is set, don't reset compl_leader. While completing, +! * cursor don't point original position, changing compl_leader would + * break redo. */ + if (!compl_opt_refresh_always) + { +--- 3483,3489 ---- + ins_compl_restart(); + + /* When 'always' is set, don't reset compl_leader. While completing, +! * cursor doesn't point original position, changing compl_leader would + * break redo. */ + if (!compl_opt_refresh_always) + { +*** ../vim-7.3.565/src/version.c 2012-06-20 18:39:12.000000000 +0200 +--- src/version.c 2012-06-20 22:54:27.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 566, + /**/ + +-- +CVS sux, men don't like commitment + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ce7e209d8dc14185faa4c1a7effb2f3527a60c8a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:11 +0200 Subject: [PATCH 0311/3340] - patchlevel 567 --- 7.3.567 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.567 diff --git a/7.3.567 b/7.3.567 new file mode 100644 index 00000000..62399f18 --- /dev/null +++ b/7.3.567 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.567 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.567 +Problem: Missing copyright notice. +Solution: Add Vim copyright notice. (Taro Muraoka) +Files: src/dehqx.py + + +*** ../vim-7.3.566/src/dehqx.py 2010-08-15 21:57:32.000000000 +0200 +--- src/dehqx.py 2012-06-29 11:27:41.000000000 +0200 +*************** +*** 1,7 **** + # Python script to get both the data and resource fork from a BinHex encoded + # file. +! # Author: Taro Muraoka +! # Last Change: 2003 Oct 25 + + import sys + import binhex +--- 1,10 ---- + # Python script to get both the data and resource fork from a BinHex encoded + # file. +! # Author: MURAOKA Taro +! # Last Change: 2012 Jun 29 +! # +! # Copyright (C) 2003,12 MURAOKA Taro +! # THIS FILE IS DISTRIBUTED UNDER THE VIM LICENSE. + + import sys + import binhex +*** ../vim-7.3.566/src/version.c 2012-06-20 22:55:56.000000000 +0200 +--- src/version.c 2012-06-29 11:45:36.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 567, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +66. You create a homepage with the impression to cure the afflicted...but + your hidden agenda is to receive more e-mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e7d000809c3aeede7ae641716c055d88a94572d6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:11 +0200 Subject: [PATCH 0312/3340] - patchlevel 568 --- 7.3.568 | 138 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 138 insertions(+) create mode 100644 7.3.568 diff --git a/7.3.568 b/7.3.568 new file mode 100644 index 00000000..ef4fcfe5 --- /dev/null +++ b/7.3.568 @@ -0,0 +1,138 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.568 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.568 +Problem: Bad indents for #ifdefs. +Solution: Add and remove spaces. (Elias Diem) +Files: src/globals.h + + +*** ../vim-7.3.567/src/globals.h 2012-02-11 23:45:30.000000000 +0100 +--- src/globals.h 2012-06-29 12:32:14.000000000 +0200 +*************** +*** 513,520 **** + # define ONE_CLIPBOARD + # endif + +! #define CLIP_UNNAMED 1 +! #define CLIP_UNNAMED_PLUS 2 + EXTERN int clip_unnamed INIT(= 0); /* above two values or'ed */ + + EXTERN int clip_autoselect INIT(= FALSE); +--- 513,520 ---- + # define ONE_CLIPBOARD + # endif + +! # define CLIP_UNNAMED 1 +! # define CLIP_UNNAMED_PLUS 2 + EXTERN int clip_unnamed INIT(= 0); /* above two values or'ed */ + + EXTERN int clip_autoselect INIT(= FALSE); +*************** +*** 737,745 **** + #endif + + EXTERN pos_T saved_cursor /* w_cursor before formatting text. */ +! # ifdef DO_INIT + = INIT_POS_T(0, 0, 0) +! # endif + ; + + /* +--- 737,745 ---- + #endif + + EXTERN pos_T saved_cursor /* w_cursor before formatting text. */ +! #ifdef DO_INIT + = INIT_POS_T(0, 0, 0) +! #endif + ; + + /* +*************** +*** 807,815 **** + # endif + EXTERN int has_mbyte INIT(= 0); /* any multi-byte encoding */ + +! #if defined(WIN3264) && defined(FEAT_MBYTE) + EXTERN int wide_WindowProc INIT(= FALSE); /* use wide WindowProc() */ +! #endif + + /* + * To speed up BYTELEN() we fill a table with the byte lengths whenever +--- 807,815 ---- + # endif + EXTERN int has_mbyte INIT(= 0); /* any multi-byte encoding */ + +! # if defined(WIN3264) && defined(FEAT_MBYTE) + EXTERN int wide_WindowProc INIT(= FALSE); /* use wide WindowProc() */ +! # endif + + /* + * To speed up BYTELEN() we fill a table with the byte lengths whenever +*************** +*** 1099,1106 **** + EXTERN int save_p_ls INIT(= -1); /* Save 'laststatus' setting */ + EXTERN int save_p_wmh INIT(= -1); /* Save 'winminheight' setting */ + EXTERN int wild_menu_showing INIT(= 0); +! #define WM_SHOWN 1 /* wildmenu showing */ +! #define WM_SCROLLED 2 /* wildmenu showing with scroll */ + #endif + + #ifdef MSWIN +--- 1099,1106 ---- + EXTERN int save_p_ls INIT(= -1); /* Save 'laststatus' setting */ + EXTERN int save_p_wmh INIT(= -1); /* Save 'winminheight' setting */ + EXTERN int wild_menu_showing INIT(= 0); +! # define WM_SHOWN 1 /* wildmenu showing */ +! # define WM_SCROLLED 2 /* wildmenu showing with scroll */ + #endif + + #ifdef MSWIN +*************** +*** 1310,1318 **** + EXTERN Atom commProperty INIT(= None); + EXTERN char_u *serverDelayedStartName INIT(= NULL); + # else +! # ifdef PROTO + typedef int HWND; +! # endif + EXTERN HWND clientWindow INIT(= 0); + # endif + #endif +--- 1310,1318 ---- + EXTERN Atom commProperty INIT(= None); + EXTERN char_u *serverDelayedStartName INIT(= NULL); + # else +! # ifdef PROTO + typedef int HWND; +! # endif + EXTERN HWND clientWindow INIT(= 0); + # endif + #endif +*** ../vim-7.3.567/src/version.c 2012-06-29 11:46:28.000000000 +0200 +--- src/version.c 2012-06-29 12:34:21.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 568, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +67. Your hard drive crashes. You haven't logged in for two hours. You start + to twitch. You pick up the phone and manually dial your ISP's access + number. You try to hum to communicate with the modem. You succeed. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 80c26f3c393f1172f162808c2adcad73a6bd35f3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:11 +0200 Subject: [PATCH 0313/3340] - patchlevel 569 --- 7.3.569 | 4762 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 4762 insertions(+) create mode 100644 7.3.569 diff --git a/7.3.569 b/7.3.569 new file mode 100644 index 00000000..435733fe --- /dev/null +++ b/7.3.569 @@ -0,0 +1,4762 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.569 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.569 +Problem: Evaluating Vim expression in Python is insufficient. +Solution: Add vim.bindeval(). Also add pyeval() and py3eval(). (ZyX) +Files: runtime/doc/eval.txt, runtime/doc/if_pyth.txt, src/eval.c, + src/if_lua.c, src/if_py_both.h, src/if_python.c, src/if_python3.c, + src/proto/eval.pro, src/proto/if_python.pro, + src/proto/if_python3.pro, src/testdir/Make_amiga.mak, + src/testdir/Make_dos.mak, src/testdir/Make_ming.mak, + src/testdir/Make_os2.mak, src/testdir/Makefile, + src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.568/runtime/doc/eval.txt 2012-03-07 19:16:49.000000000 +0100 +--- runtime/doc/eval.txt 2012-06-20 18:01:02.000000000 +0200 +*************** +*** 1836,1844 **** + localtime() Number current time + log( {expr}) Float natural logarithm (base e) of {expr} + log10( {expr}) Float logarithm of Float {expr} to base 10 + map( {expr}, {string}) List/Dict change each item in {expr} to {expr} + maparg( {name}[, {mode} [, {abbr} [, {dict}]]]) +! String rhs of mapping {name} in mode {mode} + mapcheck( {name}[, {mode} [, {abbr}]]) + String check for mappings matching {name} + match( {expr}, {pat}[, {start}[, {count}]]) +--- 1847,1857 ---- + localtime() Number current time + log( {expr}) Float natural logarithm (base e) of {expr} + log10( {expr}) Float logarithm of Float {expr} to base 10 ++ luaeval( {expr}[, {expr}]) any evaluate |Lua| expression + map( {expr}, {string}) List/Dict change each item in {expr} to {expr} + maparg( {name}[, {mode} [, {abbr} [, {dict}]]]) +! String or Dict +! rhs of mapping {name} in mode {mode} + mapcheck( {name}[, {mode} [, {abbr}]]) + String check for mappings matching {name} + match( {expr}, {pat}[, {start}[, {count}]]) +*************** +*** 1867,1872 **** +--- 1880,1887 ---- + prevnonblank( {lnum}) Number line nr of non-blank line <= {lnum} + printf( {fmt}, {expr1}...) String format text + pumvisible() Number whether popup menu is visible ++ pyeval( {expr}) any evaluate |Python| expression ++ py3eval( {expr}) any evaluate |python3| expression + range( {expr} [, {max} [, {stride}]]) + List items from {expr} to {max} + readfile( {fname} [, {binary} [, {max}]]) +*************** +*** 3980,3985 **** +--- 4003,4022 ---- + < -2.0 + {only available when compiled with the |+float| feature} + ++ luaeval({expr}[, {expr}]) *luaeval()* ++ Evaluate Lua expression {expr} and return its result converted ++ to Vim data structures. Second {expr} may hold additional ++ argument accessible as _A inside first {expr}. ++ Strings are returned as they are. ++ Boolean objects are converted to numbers. ++ Numbers are converted to |Float| values if vim was compiled ++ with |+float| and to numbers otherwise. ++ Dictionaries and lists obtained by vim.eval() are returned ++ as-is. ++ Other objects are returned as zero without any errors. ++ See |lua-luaeval| for more details. ++ {only available when compiled with the |+lua| feature} ++ + map({expr}, {string}) *map()* + {expr} must be a |List| or a |Dictionary|. + Replace each item in {expr} with the result of evaluating +*************** +*** 4574,4579 **** +--- 4612,4640 ---- + This can be used to avoid some things that would remove the + popup menu. + ++ *E860* *E861* ++ py3eval({expr}) *py3eval()* ++ Evaluate Python expression {expr} and return its result ++ converted to Vim data structures. ++ Numbers and strings are returned as they are (strings are ++ copied though, unicode strings are additionally converted to ++ 'encoding'). ++ Lists are represented as Vim |List| type. ++ Dictionaries are represented as Vim |Dictionary| type with ++ keys converted to strings. ++ {only available when compiled with the |+python3| feature} ++ ++ *E858* *E859* ++ pyeval({expr}) *pyeval()* ++ Evaluate Python expression {expr} and return its result ++ converted to Vim data structures. ++ Numbers and strings are returned as they are (strings are ++ copied though). ++ Lists are represented as Vim |List| type. ++ Dictionaries are represented as Vim |Dictionary| type with ++ keys converted to strings. ++ {only available when compiled with the |+python| feature} ++ + *E726* *E727* + range({expr} [, {max} [, {stride}]]) *range()* + Returns a |List| with Numbers: +*************** +*** 4807,4812 **** +--- 4868,4877 ---- + Search for regexp pattern {pattern}. The search starts at the + cursor position (you can use |cursor()| to set it). + ++ If there is no match a 0 is returned and the cursor doesn't ++ move. No error message is given. ++ When a match has been found its line number is returned. ++ + {flags} is a String, which can contain these character flags: + 'b' search backward instead of forward + 'c' accept a match at the cursor position +*** ../vim-7.3.568/runtime/doc/if_pyth.txt 2010-08-15 21:57:12.000000000 +0200 +--- runtime/doc/if_pyth.txt 2012-06-20 18:01:02.000000000 +0200 +*************** +*** 1,4 **** +! *if_pyth.txt* For Vim version 7.3. Last change: 2010 Aug 13 + + + VIM REFERENCE MANUAL by Paul Moore +--- 1,4 ---- +! *if_pyth.txt* For Vim version 7.3. Last change: 2012 Feb 04 + + + VIM REFERENCE MANUAL by Paul Moore +*************** +*** 6,18 **** + + The Python Interface to Vim *python* *Python* + +! 1. Commands |python-commands| +! 2. The vim module |python-vim| +! 3. Buffer objects |python-buffer| +! 4. Range objects |python-range| +! 5. Window objects |python-window| +! 6. Dynamic loading |python-dynamic| +! 7. Python 3 |python3| + + {Vi does not have any of these commands} + +--- 6,19 ---- + + The Python Interface to Vim *python* *Python* + +! 1. Commands |python-commands| +! 2. The vim module |python-vim| +! 3. Buffer objects |python-buffer| +! 4. Range objects |python-range| +! 5. Window objects |python-window| +! 6. pyeval(), py3eval() Vim functions |python-pyeval| +! 7. Dynamic loading |python-dynamic| +! 8. Python 3 |python3| + + {Vi does not have any of these commands} + +*************** +*** 150,155 **** +--- 151,172 ---- + [{'cmd': '/^eval_expr(arg, nextcmd)$/', 'static': 0, 'name': + 'eval_expr', 'kind': 'f', 'filename': './src/eval.c'}] + ++ vim.bindeval(str) *python-bindeval* ++ Like |python-eval|, but ++ 1. if expression evaluates to |List| or |Dictionary| it is returned as ++ vimlist or vimdictionary python type that are connected to original ++ list or dictionary. Thus modifications to these objects imply ++ modifications of the original. ++ 2. if expression evaluates to a function reference, then it returns ++ callable vimfunction object. Use self keyword argument to assign ++ |self| object for dictionary functions. ++ ++ Note: this function has the same behavior as |lua-eval| (except that ++ lua does not support running vim functions), |python-eval| is ++ kept for backwards compatibility in order not to make scripts ++ relying on outputs of vim.eval() being a copy of original or ++ vim.eval("1") returning a string. ++ + + + Error object of the "vim" module +*************** +*** 222,229 **** + - from indexing vim.buffers (|python-buffers|) + - from the "buffer" attribute of a window (|python-window|) + +! Buffer objects have one read-only attribute - name - the full file name for +! the buffer. They also have three methods (append, mark, and range; see below). + + You can also treat buffer objects as sequence objects. In this context, they + act as if they were lists (yes, they are mutable) of strings, with each +--- 239,247 ---- + - from indexing vim.buffers (|python-buffers|) + - from the "buffer" attribute of a window (|python-window|) + +! Buffer objects have two read-only attributes - name - the full file name for +! the buffer, and number - the buffer number. They also have three methods +! (append, mark, and range; see below). + + You can also treat buffer objects as sequence objects. In this context, they + act as if they were lists (yes, they are mutable) of strings, with each +*************** +*** 318,324 **** + The width attribute is writable only if the screen is split vertically. + + ============================================================================== +! 6. Dynamic loading *python-dynamic* + + On MS-Windows the Python library can be loaded dynamically. The |:version| + output then includes |+python/dyn|. +--- 336,348 ---- + The width attribute is writable only if the screen is split vertically. + + ============================================================================== +! 6. pyeval() and py3eval() Vim functions *python-pyeval* +! +! To facilitate bi-directional interface, you can use |pyeval()| and |py3eval()| +! functions to evaluate Python expressions and pass their values to VimL. +! +! ============================================================================== +! 7. Dynamic loading *python-dynamic* + + On MS-Windows the Python library can be loaded dynamically. The |:version| + output then includes |+python/dyn|. +*************** +*** 335,347 **** + sure edit "gvim.exe" and search for "python\d*.dll\c". + + ============================================================================== +! 7. Python 3 *python3* + + *:py3* *:python3* + The |:py3| and |:python3| commands work similar to |:python|. + *:py3file* + The |:py3file| command works similar to |:pyfile|. + + Vim can be built in four ways (:version output): + 1. No Python support (-python, -python3) + 2. Python 2 support only (+python or +python/dyn, -python3) +--- 359,372 ---- + sure edit "gvim.exe" and search for "python\d*.dll\c". + + ============================================================================== +! 8. Python 3 *python3* + + *:py3* *:python3* + The |:py3| and |:python3| commands work similar to |:python|. + *:py3file* + The |:py3file| command works similar to |:pyfile|. + ++ + Vim can be built in four ways (:version output): + 1. No Python support (-python, -python3) + 2. Python 2 support only (+python or +python/dyn, -python3) +*************** +*** 355,361 **** + When doing this on Linux/Unix systems and importing global symbols, this leads + to a crash when the second Python version is used. So either global symbols + are loaded but only one Python version is activated, or no global symbols are +! loaded. The latter makes Python's "import" fail on libaries that expect the + symbols to be provided by Vim. + *E836* *E837* + Vim's configuration script makes a guess for all libraries based on one +--- 380,386 ---- + When doing this on Linux/Unix systems and importing global symbols, this leads + to a crash when the second Python version is used. So either global symbols + are loaded but only one Python version is activated, or no global symbols are +! loaded. The latter makes Python's "import" fail on libraries that expect the + symbols to be provided by Vim. + *E836* *E837* + Vim's configuration script makes a guess for all libraries based on one +*************** +*** 377,382 **** +--- 402,419 ---- + 3. You undefine PY_NO_RTLD_GLOBAL in auto/config.h after configuration. This + may crash Vim though. + ++ *has-python* ++ You can test what Python version is available with: > ++ if has('python') ++ echo 'there is Python 2.x' ++ elseif has('python3') ++ echo 'there is Python 3.x' ++ endif ++ ++ Note however, that when Python 2 and 3 are both available and loaded ++ dynamically, these has() calls will try to load them. If only one can be ++ loaded at a time, just checking if Python 2 or 3 are available will prevent ++ the other one from being available. + + ============================================================================== + vim:tw=78:ts=8:ft=help:norl: +*** ../vim-7.3.568/src/eval.c 2012-06-20 14:13:02.000000000 +0200 +--- src/eval.c 2012-06-20 18:29:15.000000000 +0200 +*************** +*** 424,453 **** + static int get_lit_string_tv __ARGS((char_u **arg, typval_T *rettv, int evaluate)); + static int get_list_tv __ARGS((char_u **arg, typval_T *rettv, int evaluate)); + static int rettv_list_alloc __ARGS((typval_T *rettv)); +- static listitem_T *listitem_alloc __ARGS((void)); + static void listitem_free __ARGS((listitem_T *item)); +- static void listitem_remove __ARGS((list_T *l, listitem_T *item)); + static long list_len __ARGS((list_T *l)); + static int list_equal __ARGS((list_T *l1, list_T *l2, int ic, int recursive)); + static int dict_equal __ARGS((dict_T *d1, dict_T *d2, int ic, int recursive)); + static int tv_equal __ARGS((typval_T *tv1, typval_T *tv2, int ic, int recursive)); +- static listitem_T *list_find __ARGS((list_T *l, long n)); + static long list_find_nr __ARGS((list_T *l, long idx, int *errorp)); + static long list_idx_of_item __ARGS((list_T *l, listitem_T *item)); +- static void list_append __ARGS((list_T *l, listitem_T *item)); + static int list_append_number __ARGS((list_T *l, varnumber_T n)); +- static int list_insert_tv __ARGS((list_T *l, typval_T *tv, listitem_T *item)); + static int list_extend __ARGS((list_T *l1, list_T *l2, listitem_T *bef)); + static int list_concat __ARGS((list_T *l1, list_T *l2, typval_T *tv)); + static list_T *list_copy __ARGS((list_T *orig, int deep, int copyID)); +- static void list_remove __ARGS((list_T *l, listitem_T *item, listitem_T *item2)); + static char_u *list2string __ARGS((typval_T *tv, int copyID)); + static int list_join_inner __ARGS((garray_T *gap, list_T *l, char_u *sep, int echo_style, int copyID, garray_T *join_gap)); + static int list_join __ARGS((garray_T *gap, list_T *l, char_u *sep, int echo, int copyID)); + static int free_unref_items __ARGS((int copyID)); +- static void set_ref_in_ht __ARGS((hashtab_T *ht, int copyID)); +- static void set_ref_in_list __ARGS((list_T *l, int copyID)); +- static void set_ref_in_item __ARGS((typval_T *tv, int copyID)); + static int rettv_dict_alloc __ARGS((typval_T *rettv)); + static void dict_free __ARGS((dict_T *d, int recurse)); + static dictitem_T *dictitem_copy __ARGS((dictitem_T *org)); +--- 424,444 ---- +*************** +*** 654,659 **** +--- 645,656 ---- + static void f_prevnonblank __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_printf __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_pumvisible __ARGS((typval_T *argvars, typval_T *rettv)); ++ #ifdef FEAT_PYTHON3 ++ static void f_py3eval __ARGS((typval_T *argvars, typval_T *rettv)); ++ #endif ++ #ifdef FEAT_PYTHON ++ static void f_pyeval __ARGS((typval_T *argvars, typval_T *rettv)); ++ #endif + static void f_range __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_readfile __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_reltime __ARGS((typval_T *argvars, typval_T *rettv)); +*************** +*** 824,831 **** + static char_u *autoload_name __ARGS((char_u *name)); + static void cat_func_name __ARGS((char_u *buf, ufunc_T *fp)); + static void func_free __ARGS((ufunc_T *fp)); +- static void func_unref __ARGS((char_u *name)); +- static void func_ref __ARGS((char_u *name)); + static void call_user_func __ARGS((ufunc_T *fp, int argcount, typval_T *argvars, typval_T *rettv, linenr_T firstline, linenr_T lastline, dict_T *selfdict)); + static int can_free_funccal __ARGS((funccall_T *fc, int copyID)) ; + static void free_funccal __ARGS((funccall_T *fc, int free_val)); +--- 821,826 ---- +*************** +*** 5927,5933 **** + /* + * Allocate a list item. + */ +! static listitem_T * + listitem_alloc() + { + return (listitem_T *)alloc(sizeof(listitem_T)); +--- 5922,5928 ---- + /* + * Allocate a list item. + */ +! listitem_T * + listitem_alloc() + { + return (listitem_T *)alloc(sizeof(listitem_T)); +*************** +*** 5947,5953 **** + /* + * Remove a list item from a List and free it. Also clears the value. + */ +! static void + listitem_remove(l, item) + list_T *l; + listitem_T *item; +--- 5942,5948 ---- + /* + * Remove a list item from a List and free it. Also clears the value. + */ +! void + listitem_remove(l, item) + list_T *l; + listitem_T *item; +*************** +*** 6123,6129 **** + * A negative index is counted from the end; -1 is the last item. + * Returns NULL when "n" is out of range. + */ +! static listitem_T * + list_find(l, n) + list_T *l; + long n; +--- 6118,6124 ---- + * A negative index is counted from the end; -1 is the last item. + * Returns NULL when "n" is out of range. + */ +! listitem_T * + list_find(l, n) + list_T *l; + long n; +*************** +*** 6265,6271 **** + /* + * Append item "item" to the end of list "l". + */ +! static void + list_append(l, item) + list_T *l; + listitem_T *item; +--- 6260,6266 ---- + /* + * Append item "item" to the end of list "l". + */ +! void + list_append(l, item) + list_T *l; + listitem_T *item; +*************** +*** 6378,6384 **** + * If "item" is NULL append at the end. + * Return FAIL when out of memory. + */ +! static int + list_insert_tv(l, tv, item) + list_T *l; + typval_T *tv; +--- 6373,6379 ---- + * If "item" is NULL append at the end. + * Return FAIL when out of memory. + */ +! int + list_insert_tv(l, tv, item) + list_T *l; + typval_T *tv; +*************** +*** 6523,6529 **** + * Remove items "item" to "item2" from list "l". + * Does not free the listitem or the value! + */ +! static void + list_remove(l, item, item2) + list_T *l; + listitem_T *item; +--- 6518,6524 ---- + * Remove items "item" to "item2" from list "l". + * Does not free the listitem or the value! + */ +! void + list_remove(l, item, item2) + list_T *l; + listitem_T *item; +*************** +*** 6785,6790 **** +--- 6780,6793 ---- + set_ref_in_lua(copyID); + #endif + ++ #ifdef FEAT_PYTHON ++ set_ref_in_python(copyID); ++ #endif ++ ++ #ifdef FEAT_PYTHON3 ++ set_ref_in_python3(copyID); ++ #endif ++ + /* + * 2. Free lists and dictionaries that are not referenced. + */ +*************** +*** 6870,6876 **** + /* + * Mark all lists and dicts referenced through hashtab "ht" with "copyID". + */ +! static void + set_ref_in_ht(ht, copyID) + hashtab_T *ht; + int copyID; +--- 6873,6879 ---- + /* + * Mark all lists and dicts referenced through hashtab "ht" with "copyID". + */ +! void + set_ref_in_ht(ht, copyID) + hashtab_T *ht; + int copyID; +*************** +*** 6890,6896 **** + /* + * Mark all lists and dicts referenced through list "l" with "copyID". + */ +! static void + set_ref_in_list(l, copyID) + list_T *l; + int copyID; +--- 6893,6899 ---- + /* + * Mark all lists and dicts referenced through list "l" with "copyID". + */ +! void + set_ref_in_list(l, copyID) + list_T *l; + int copyID; +*************** +*** 6904,6910 **** + /* + * Mark all lists and dicts referenced through typval "tv" with "copyID". + */ +! static void + set_ref_in_item(tv, copyID) + typval_T *tv; + int copyID; +--- 6907,6913 ---- + /* + * Mark all lists and dicts referenced through typval "tv" with "copyID". + */ +! void + set_ref_in_item(tv, copyID) + typval_T *tv; + int copyID; +*************** +*** 7986,7991 **** +--- 7989,8000 ---- + {"prevnonblank", 1, 1, f_prevnonblank}, + {"printf", 2, 19, f_printf}, + {"pumvisible", 0, 0, f_pumvisible}, ++ #ifdef FEAT_PYTHON3 ++ {"py3eval", 1, 1, f_py3eval}, ++ #endif ++ #ifdef FEAT_PYTHON ++ {"pyeval", 1, 1, f_pyeval}, ++ #endif + {"range", 1, 3, f_range}, + {"readfile", 1, 3, f_readfile}, + {"reltime", 0, 2, f_reltime}, +*************** +*** 9150,9155 **** +--- 9159,9203 ---- + #endif + } + ++ int ++ func_call(name, args, selfdict, rettv) ++ char_u *name; ++ typval_T *args; ++ dict_T *selfdict; ++ typval_T *rettv; ++ { ++ listitem_T *item; ++ typval_T argv[MAX_FUNC_ARGS + 1]; ++ int argc = 0; ++ int dummy; ++ int r = 0; ++ ++ for (item = args->vval.v_list->lv_first; item != NULL; ++ item = item->li_next) ++ { ++ if (argc == MAX_FUNC_ARGS) ++ { ++ EMSG(_("E699: Too many arguments")); ++ break; ++ } ++ /* Make a copy of each argument. This is needed to be able to set ++ * v_lock to VAR_FIXED in the copy without changing the original list. ++ */ ++ copy_tv(&item->li_tv, &argv[argc++]); ++ } ++ ++ if (item == NULL) ++ r = call_func(name, (int)STRLEN(name), rettv, argc, argv, ++ curwin->w_cursor.lnum, curwin->w_cursor.lnum, ++ &dummy, TRUE, selfdict); ++ ++ /* Free the arguments. */ ++ while (argc > 0) ++ clear_tv(&argv[--argc]); ++ ++ return r; ++ } ++ + /* + * "call(func, arglist)" function + */ +*************** +*** 9159,9168 **** + typval_T *rettv; + { + char_u *func; +- typval_T argv[MAX_FUNC_ARGS + 1]; +- int argc = 0; +- listitem_T *item; +- int dummy; + dict_T *selfdict = NULL; + + if (argvars[1].v_type != VAR_LIST) +--- 9207,9212 ---- +*************** +*** 9190,9217 **** + selfdict = argvars[2].vval.v_dict; + } + +! for (item = argvars[1].vval.v_list->lv_first; item != NULL; +! item = item->li_next) +! { +! if (argc == MAX_FUNC_ARGS) +! { +! EMSG(_("E699: Too many arguments")); +! break; +! } +! /* Make a copy of each argument. This is needed to be able to set +! * v_lock to VAR_FIXED in the copy without changing the original list. +! */ +! copy_tv(&item->li_tv, &argv[argc++]); +! } +! +! if (item == NULL) +! (void)call_func(func, (int)STRLEN(func), rettv, argc, argv, +! curwin->w_cursor.lnum, curwin->w_cursor.lnum, +! &dummy, TRUE, selfdict); +! +! /* Free the arguments. */ +! while (argc > 0) +! clear_tv(&argv[--argc]); + } + + #ifdef FEAT_FLOAT +--- 9234,9240 ---- + selfdict = argvars[2].vval.v_dict; + } + +! (void)func_call(func, &argvars[1], selfdict, rettv); + } + + #ifdef FEAT_FLOAT +*************** +*** 14424,14429 **** +--- 14447,14486 ---- + #endif + } + ++ #ifdef FEAT_PYTHON3 ++ /* ++ * "py3eval()" function ++ */ ++ static void ++ f_py3eval(argvars, rettv) ++ typval_T *argvars; ++ typval_T *rettv; ++ { ++ char_u *str; ++ char_u buf[NUMBUFLEN]; ++ ++ str = get_tv_string_buf(&argvars[0], buf); ++ do_py3eval(str, rettv); ++ } ++ #endif ++ ++ #ifdef FEAT_PYTHON ++ /* ++ * "pyeval()" function ++ */ ++ static void ++ f_pyeval(argvars, rettv) ++ typval_T *argvars; ++ typval_T *rettv; ++ { ++ char_u *str; ++ char_u buf[NUMBUFLEN]; ++ ++ str = get_tv_string_buf(&argvars[0], buf); ++ do_pyeval(str, rettv); ++ } ++ #endif ++ + /* + * "range()" function + */ +*************** +*** 22139,22145 **** + * Unreference a Function: decrement the reference count and free it when it + * becomes zero. Only for numbered functions. + */ +! static void + func_unref(name) + char_u *name; + { +--- 22196,22202 ---- + * Unreference a Function: decrement the reference count and free it when it + * becomes zero. Only for numbered functions. + */ +! void + func_unref(name) + char_u *name; + { +*************** +*** 22163,22169 **** + /* + * Count a reference to a Function. + */ +! static void + func_ref(name) + char_u *name; + { +--- 22220,22226 ---- + /* + * Count a reference to a Function. + */ +! void + func_ref(name) + char_u *name; + { +*** ../vim-7.3.568/src/if_lua.c 2012-04-06 14:30:55.000000000 +0200 +--- src/if_lua.c 2012-06-20 18:16:33.000000000 +0200 +*************** +*** 199,207 **** + lua_Number (*dll_lua_tonumberx) (lua_State *L, int idx, int *isnum); + lua_Integer (*dll_lua_tointegerx) (lua_State *L, int idx, int *isnum); + void (*dll_lua_callk) (lua_State *L, int nargs, int nresults, int ctx, +! lua_CFunction k); + int (*dll_lua_pcallk) (lua_State *L, int nargs, int nresults, int errfunc, +! int ctx, lua_CFunction k); + void (*dll_lua_getglobal) (lua_State *L, const char *var); + void (*dll_lua_setglobal) (lua_State *L, const char *var); + #endif +--- 199,207 ---- + lua_Number (*dll_lua_tonumberx) (lua_State *L, int idx, int *isnum); + lua_Integer (*dll_lua_tointegerx) (lua_State *L, int idx, int *isnum); + void (*dll_lua_callk) (lua_State *L, int nargs, int nresults, int ctx, +! lua_CFunction k); + int (*dll_lua_pcallk) (lua_State *L, int nargs, int nresults, int errfunc, +! int ctx, lua_CFunction k); + void (*dll_lua_getglobal) (lua_State *L, const char *var); + void (*dll_lua_setglobal) (lua_State *L, const char *var); + #endif +*************** +*** 394,400 **** + luaL_typeerror (lua_State *L, int narg, const char *tname) + { + const char *msg = lua_pushfstring(L, "%s expected, got %s", +! tname, luaL_typename(L, narg)); + return luaL_argerror(L, narg, msg); + } + #endif +--- 394,400 ---- + luaL_typeerror (lua_State *L, int narg, const char *tname) + { + const char *msg = lua_pushfstring(L, "%s expected, got %s", +! tname, luaL_typename(L, narg)); + return luaL_argerror(L, narg, msg); + } + #endif +*************** +*** 646,786 **** + return 1; \ + } + +- +- /* adapted from eval.c */ +- +- #define listitem_alloc() (listitem_T *)alloc(sizeof(listitem_T)) +- +- static listitem_T * +- list_find (list_T *l, long n) +- { +- listitem_T *li; +- if (l == NULL || n < -l->lv_len || n >= l->lv_len) +- return NULL; +- if (n < 0) /* search backward? */ +- for (li = l->lv_last; n < -1; li = li->li_prev) +- n++; +- else /* search forward */ +- for (li = l->lv_first; n > 0; li = li->li_next) +- n--; +- return li; +- } +- +- static void +- list_remove (list_T *l, listitem_T *li) +- { +- listwatch_T *lw; +- --l->lv_len; +- /* fix watchers */ +- for (lw = l->lv_watch; lw != NULL; lw = lw->lw_next) +- if (lw->lw_item == li) +- lw->lw_item = li->li_next; +- /* fix list pointers */ +- if (li->li_next == NULL) /* last? */ +- l->lv_last = li->li_prev; +- else +- li->li_next->li_prev = li->li_prev; +- if (li->li_prev == NULL) /* first? */ +- l->lv_first = li->li_next; +- else +- li->li_prev->li_next = li->li_next; +- l->lv_idx_item = NULL; +- } +- +- static void +- list_append(list_T *l, listitem_T *item) +- { +- if (l->lv_last == NULL) /* empty list? */ +- l->lv_first = item; +- else +- l->lv_last->li_next = item; +- item->li_prev = l->lv_last; +- item->li_next = NULL; +- l->lv_last = item; +- ++l->lv_len; +- } +- +- static int +- list_insert_tv(list_T *l, typval_T *tv, listitem_T *item) +- { +- listitem_T *ni = listitem_alloc(); +- +- if (ni == NULL) +- return FAIL; +- copy_tv(tv, &ni->li_tv); +- if (item == NULL) +- list_append(l, ni); +- else +- { +- ni->li_prev = item->li_prev; +- ni->li_next = item; +- if (item->li_prev == NULL) +- { +- l->lv_first = ni; +- ++l->lv_idx; +- } +- else +- { +- item->li_prev->li_next = ni; +- l->lv_idx_item = NULL; +- } +- item->li_prev = ni; +- ++l->lv_len; +- } +- return OK; +- } +- +- /* set references */ +- +- static void set_ref_in_tv (typval_T *tv, int copyID); +- +- static void +- set_ref_in_dict(dict_T *d, int copyID) +- { +- hashtab_T *ht = &d->dv_hashtab; +- int n = ht->ht_used; +- hashitem_T *hi; +- for (hi = ht->ht_array; n > 0; ++hi) +- if (!HASHITEM_EMPTY(hi)) +- { +- dictitem_T *di = dict_lookup(hi); +- set_ref_in_tv(&di->di_tv, copyID); +- --n; +- } +- } +- +- static void +- set_ref_in_list(list_T *l, int copyID) +- { +- listitem_T *li; +- for (li = l->lv_first; li != NULL; li = li->li_next) +- set_ref_in_tv(&li->li_tv, copyID); +- } +- +- static void +- set_ref_in_tv(typval_T *tv, int copyID) +- { +- if (tv->v_type == VAR_LIST) +- { +- list_T *l = tv->vval.v_list; +- if (l != NULL && l->lv_copyID != copyID) +- { +- l->lv_copyID = copyID; +- set_ref_in_list(l, copyID); +- } +- } +- else if (tv->v_type == VAR_DICT) +- { +- dict_T *d = tv->vval.v_dict; +- if (d != NULL && d->dv_copyID != copyID) +- { +- d->dv_copyID = copyID; +- set_ref_in_dict(d, copyID); +- } +- } +- } +- +- + /* ======= List type ======= */ + + static luaV_List * +--- 646,651 ---- +*************** +*** 876,882 **** + if (li == NULL) return 0; + if (lua_isnil(L, 3)) /* remove? */ + { +! list_remove(l, li); + clear_tv(&li->li_tv); + vim_free(li); + } +--- 741,747 ---- + if (li == NULL) return 0; + if (lua_isnil(L, 3)) /* remove? */ + { +! list_remove(l, li, li); + clear_tv(&li->li_tv); + vim_free(li); + } +*************** +*** 904,911 **** + typval_T v; + lua_settop(L, 2); + luaV_totypval(L, 2, &v); +! copy_tv(&v, &li->li_tv); +! list_append(l, li); + } + lua_settop(L, 1); + return 1; +--- 769,775 ---- + typval_T v; + lua_settop(L, 2); + luaV_totypval(L, 2, &v); +! list_append_tv(l, &v); + } + lua_settop(L, 1); + return 1; +*************** +*** 1682,1688 **** + tv.vval.v_dict = (dict_T *) lua_touserdata(L, 4); /* key */ + } + lua_pop(L, 2); /* metatable and value */ +! set_ref_in_tv(&tv, copyID); + } + return 0; + } +--- 1546,1552 ---- + tv.vval.v_dict = (dict_T *) lua_touserdata(L, 4); /* key */ + } + lua_pop(L, 2); /* metatable and value */ +! set_ref_in_item(&tv, copyID); + } + return 0; + } +*** ../vim-7.3.568/src/if_py_both.h 2012-04-20 13:31:16.000000000 +0200 +--- src/if_py_both.h 2012-06-29 12:03:52.000000000 +0200 +*************** +*** 1,4 **** +! /* vi:set ts=8 sts=4 sw=4: + * + * VIM - Vi IMproved by Bram Moolenaar + * +--- 1,4 ---- +! /* vi:set ts=8 sts=4 sw=4 noet: + * + * VIM - Vi IMproved by Bram Moolenaar + * +*************** +*** 105,111 **** + return NULL; + Py_INCREF(list); + +! if (!PyList_Check(list)) { + PyErr_SetString(PyExc_TypeError, _("writelines() requires list of strings")); + Py_DECREF(list); + return NULL; +--- 105,112 ---- + return NULL; + Py_INCREF(list); + +! if (!PyList_Check(list)) +! { + PyErr_SetString(PyExc_TypeError, _("writelines() requires list of strings")); + Py_DECREF(list); + return NULL; +*************** +*** 119,125 **** + char *str = NULL; + PyInt len; + +! if (!PyArg_Parse(line, "et#", ENC_OPT, &str, &len)) { + PyErr_SetString(PyExc_TypeError, _("writelines() requires list of strings")); + Py_DECREF(list); + return NULL; +--- 120,127 ---- + char *str = NULL; + PyInt len; + +! if (!PyArg_Parse(line, "et#", ENC_OPT, &str, &len)) +! { + PyErr_SetString(PyExc_TypeError, _("writelines() requires list of strings")); + Py_DECREF(list); + return NULL; +*************** +*** 297,303 **** + { + PyObject *result; + PyObject *newObj; +! char ptrBuf[NUMBUFLEN]; + + /* Avoid infinite recursion */ + if (depth > 100) +--- 299,305 ---- + { + PyObject *result; + PyObject *newObj; +! char ptrBuf[sizeof(void *) * 2 + 3]; + + /* Avoid infinite recursion */ + if (depth > 100) +*************** +*** 312,320 **** + if ((our_tv->v_type == VAR_LIST && our_tv->vval.v_list != NULL) + || (our_tv->v_type == VAR_DICT && our_tv->vval.v_dict != NULL)) + { +! sprintf(ptrBuf, PRINTF_DECIMAL_LONG_U, +! our_tv->v_type == VAR_LIST ? (long_u)our_tv->vval.v_list +! : (long_u)our_tv->vval.v_dict); + result = PyDict_GetItemString(lookupDict, ptrBuf); + if (result != NULL) + { +--- 314,322 ---- + if ((our_tv->v_type == VAR_LIST && our_tv->vval.v_list != NULL) + || (our_tv->v_type == VAR_DICT && our_tv->vval.v_dict != NULL)) + { +! sprintf(ptrBuf, "%p", +! our_tv->v_type == VAR_LIST ? (void *)our_tv->vval.v_list +! : (void *)our_tv->vval.v_dict); + result = PyDict_GetItemString(lookupDict, ptrBuf); + if (result != NULL) + { +*************** +*** 374,509 **** + hashitem_T *hi; + dictitem_T *di; + +! PyDict_SetItemString(lookupDict, ptrBuf, result); + +! for (hi = ht->ht_array; todo > 0; ++hi) + { +! if (!HASHITEM_EMPTY(hi)) +! { +! --todo; +! +! di = dict_lookup(hi); +! newObj = VimToPython(&di->di_tv, depth + 1, lookupDict); +! PyDict_SetItemString(result, (char *)hi->hi_key, newObj); +! Py_DECREF(newObj); +! } + } + } + } +! else + { +! Py_INCREF(Py_None); +! result = Py_None; + } + +! return result; + } +- #endif + + static PyObject * +! VimEval(PyObject *self UNUSED, PyObject *args UNUSED) + { +! #ifdef FEAT_EVAL +! char *expr; +! typval_T *our_tv; +! PyObject *result; +! PyObject *lookup_dict; + +! if (!PyArg_ParseTuple(args, "s", &expr)) + return NULL; + +! Py_BEGIN_ALLOW_THREADS +! Python_Lock_Vim(); +! our_tv = eval_expr((char_u *)expr, NULL); +! +! Python_Release_Vim(); +! Py_END_ALLOW_THREADS +! +! if (our_tv == NULL) + { +! PyErr_SetVim(_("invalid expression")); + return NULL; + } + +- /* Convert the Vim type into a Python type. Create a dictionary that's +- * used to check for recursive loops. */ + lookup_dict = PyDict_New(); +! result = VimToPython(our_tv, 1, lookup_dict); + Py_DECREF(lookup_dict); + +! +! Py_BEGIN_ALLOW_THREADS +! Python_Lock_Vim(); +! free_tv(our_tv); +! Python_Release_Vim(); +! Py_END_ALLOW_THREADS +! +! return result; +! #else +! PyErr_SetVim(_("expressions disabled at compile time")); +! return NULL; +! #endif + } + +! /* +! * Vim module - Definitions +! */ +! +! static struct PyMethodDef VimMethods[] = { +! /* name, function, calling, documentation */ +! {"command", VimCommand, 1, "Execute a Vim ex-mode command" }, +! {"eval", VimEval, 1, "Evaluate an expression using Vim evaluator" }, +! { NULL, NULL, 0, NULL } + }; + + typedef struct + { + PyObject_HEAD +! buf_T *buf; +! } +! BufferObject; + +! #define INVALID_BUFFER_VALUE ((buf_T *)(-1)) +! +! /* +! * Buffer list object - Implementation +! */ + +! static PyInt +! BufListLength(PyObject *self UNUSED) + { +! buf_T *b = firstbuf; +! PyInt n = 0; + +! while (b) + { +! ++n; +! b = b->b_next; + } +! +! return n; + } + + static PyObject * +! BufListItem(PyObject *self UNUSED, PyInt n) + { +! buf_T *b; + +! for (b = firstbuf; b; b = b->b_next, --n) + { +! if (n == 0) +! return BufferNew(b); + } + +! PyErr_SetString(PyExc_IndexError, _("no such buffer")); +! return NULL; + } + +! typedef struct +! { +! PyObject_HEAD +! win_T *win; +! } WindowObject; + + #define INVALID_WINDOW_VALUE ((win_T *)(-1)) + +--- 376,1325 ---- + hashitem_T *hi; + dictitem_T *di; + +! PyDict_SetItemString(lookupDict, ptrBuf, result); +! +! for (hi = ht->ht_array; todo > 0; ++hi) +! { +! if (!HASHITEM_EMPTY(hi)) +! { +! --todo; +! +! di = dict_lookup(hi); +! newObj = VimToPython(&di->di_tv, depth + 1, lookupDict); +! PyDict_SetItemString(result, (char *)hi->hi_key, newObj); +! Py_DECREF(newObj); +! } +! } +! } +! } +! else +! { +! Py_INCREF(Py_None); +! result = Py_None; +! } +! +! return result; +! } +! #endif +! +! static PyObject * +! VimEval(PyObject *self UNUSED, PyObject *args UNUSED) +! { +! #ifdef FEAT_EVAL +! char *expr; +! typval_T *our_tv; +! PyObject *result; +! PyObject *lookup_dict; +! +! if (!PyArg_ParseTuple(args, "s", &expr)) +! return NULL; +! +! Py_BEGIN_ALLOW_THREADS +! Python_Lock_Vim(); +! our_tv = eval_expr((char_u *)expr, NULL); +! +! Python_Release_Vim(); +! Py_END_ALLOW_THREADS +! +! if (our_tv == NULL) +! { +! PyErr_SetVim(_("invalid expression")); +! return NULL; +! } +! +! /* Convert the Vim type into a Python type. Create a dictionary that's +! * used to check for recursive loops. */ +! lookup_dict = PyDict_New(); +! result = VimToPython(our_tv, 1, lookup_dict); +! Py_DECREF(lookup_dict); +! +! +! Py_BEGIN_ALLOW_THREADS +! Python_Lock_Vim(); +! free_tv(our_tv); +! Python_Release_Vim(); +! Py_END_ALLOW_THREADS +! +! return result; +! #else +! PyErr_SetVim(_("expressions disabled at compile time")); +! return NULL; +! #endif +! } +! +! static PyObject *ConvertToPyObject(typval_T *); +! +! static PyObject * +! VimEvalPy(PyObject *self UNUSED, PyObject *args UNUSED) +! { +! #ifdef FEAT_EVAL +! char *expr; +! typval_T *our_tv; +! PyObject *result; +! +! if (!PyArg_ParseTuple(args, "s", &expr)) +! return NULL; +! +! Py_BEGIN_ALLOW_THREADS +! Python_Lock_Vim(); +! our_tv = eval_expr((char_u *)expr, NULL); +! +! Python_Release_Vim(); +! Py_END_ALLOW_THREADS +! +! if (our_tv == NULL) +! { +! PyErr_SetVim(_("invalid expression")); +! return NULL; +! } +! +! result = ConvertToPyObject(our_tv); +! Py_BEGIN_ALLOW_THREADS +! Python_Lock_Vim(); +! free_tv(our_tv); +! Python_Release_Vim(); +! Py_END_ALLOW_THREADS +! +! return result; +! #else +! PyErr_SetVim(_("expressions disabled at compile time")); +! return NULL; +! #endif +! } +! +! static PyObject * +! VimStrwidth(PyObject *self UNUSED, PyObject *args) +! { +! char *expr; +! +! if (!PyArg_ParseTuple(args, "s", &expr)) +! return NULL; +! +! return PyLong_FromLong(mb_string2cells((char_u *)expr, STRLEN(expr))); +! } +! +! /* +! * Vim module - Definitions +! */ +! +! static struct PyMethodDef VimMethods[] = { +! /* name, function, calling, documentation */ +! {"command", VimCommand, 1, "Execute a Vim ex-mode command" }, +! {"eval", VimEval, 1, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, 1, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, 1, "Screen string width, counts as having width 1"}, +! { NULL, NULL, 0, NULL } +! }; +! +! typedef struct +! { +! PyObject_HEAD +! buf_T *buf; +! } BufferObject; +! +! #define INVALID_BUFFER_VALUE ((buf_T *)(-1)) +! +! /* +! * Buffer list object - Implementation +! */ +! +! static PyInt +! BufListLength(PyObject *self UNUSED) +! { +! buf_T *b = firstbuf; +! PyInt n = 0; +! +! while (b) +! { +! ++n; +! b = b->b_next; +! } +! +! return n; +! } +! +! static PyObject * +! BufListItem(PyObject *self UNUSED, PyInt n) +! { +! buf_T *b; +! +! for (b = firstbuf; b; b = b->b_next, --n) +! { +! if (n == 0) +! return BufferNew(b); +! } +! +! PyErr_SetString(PyExc_IndexError, _("no such buffer")); +! return NULL; +! } +! +! typedef struct +! { +! PyObject_HEAD +! win_T *win; +! } WindowObject; +! +! static int ConvertFromPyObject(PyObject *, typval_T *); +! static int _ConvertFromPyObject(PyObject *, typval_T *, PyObject *); +! +! typedef struct pylinkedlist_S { +! struct pylinkedlist_S *pll_next; +! struct pylinkedlist_S *pll_prev; +! PyObject *pll_obj; +! } pylinkedlist_T; +! +! static pylinkedlist_T *lastdict = NULL; +! static pylinkedlist_T *lastlist = NULL; +! +! static void +! pyll_remove(pylinkedlist_T *ref, pylinkedlist_T **last) +! { +! if (ref->pll_prev == NULL) +! { +! if (ref->pll_next == NULL) +! { +! *last = NULL; +! return; +! } +! } +! else +! ref->pll_prev->pll_next = ref->pll_next; +! +! if (ref->pll_next == NULL) +! *last = ref->pll_prev; +! else +! ref->pll_next->pll_prev = ref->pll_prev; +! } +! +! static void +! pyll_add(PyObject *self, pylinkedlist_T *ref, pylinkedlist_T **last) +! { +! if (*last == NULL) +! ref->pll_prev = NULL; +! else +! { +! (*last)->pll_next = ref; +! ref->pll_prev = *last; +! } +! ref->pll_next = NULL; +! ref->pll_obj = self; +! *last = ref; +! } +! +! static PyTypeObject DictionaryType; +! +! typedef struct +! { +! PyObject_HEAD +! dict_T *dict; +! pylinkedlist_T ref; +! } DictionaryObject; +! +! static PyObject * +! DictionaryNew(dict_T *dict) +! { +! DictionaryObject *self; +! +! self = PyObject_NEW(DictionaryObject, &DictionaryType); +! if (self == NULL) +! return NULL; +! self->dict = dict; +! ++dict->dv_refcount; +! +! pyll_add((PyObject *)(self), &self->ref, &lastdict); +! +! return (PyObject *)(self); +! } +! +! static int +! pydict_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) +! { +! dict_T *d; +! char_u *key; +! dictitem_T *di; +! PyObject *keyObject; +! PyObject *valObject; +! Py_ssize_t iter = 0; +! +! d = dict_alloc(); +! if (d == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! +! tv->v_type = VAR_DICT; +! tv->vval.v_dict = d; +! +! while (PyDict_Next(obj, &iter, &keyObject, &valObject)) +! { +! DICTKEY_DECL +! +! if (keyObject == NULL) +! return -1; +! if (valObject == NULL) +! return -1; +! +! DICTKEY_GET(-1) +! +! di = dictitem_alloc(key); +! +! DICTKEY_UNREF +! +! if (di == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! di->di_tv.v_lock = 0; +! +! if (_ConvertFromPyObject(valObject, &di->di_tv, lookupDict) == -1) +! { +! vim_free(di); +! return -1; +! } +! if (dict_add(d, di) == FAIL) +! { +! vim_free(di); +! PyErr_SetVim(_("failed to add key to dictionary")); +! return -1; +! } +! } +! return 0; +! } +! +! static int +! pymap_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) +! { +! dict_T *d; +! char_u *key; +! dictitem_T *di; +! PyObject *list; +! PyObject *litem; +! PyObject *keyObject; +! PyObject *valObject; +! Py_ssize_t lsize; +! +! d = dict_alloc(); +! if (d == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! +! tv->v_type = VAR_DICT; +! tv->vval.v_dict = d; +! +! list = PyMapping_Items(obj); +! lsize = PyList_Size(list); +! while (lsize--) +! { +! DICTKEY_DECL +! +! litem = PyList_GetItem(list, lsize); +! if (litem == NULL) +! { +! Py_DECREF(list); +! return -1; +! } +! +! keyObject = PyTuple_GetItem(litem, 0); +! if (keyObject == NULL) +! { +! Py_DECREF(list); +! Py_DECREF(litem); +! return -1; +! } +! +! DICTKEY_GET(-1) +! +! valObject = PyTuple_GetItem(litem, 1); +! if (valObject == NULL) +! { +! Py_DECREF(list); +! Py_DECREF(litem); +! return -1; +! } +! +! di = dictitem_alloc(key); +! +! DICTKEY_UNREF +! +! if (di == NULL) +! { +! Py_DECREF(list); +! Py_DECREF(litem); +! PyErr_NoMemory(); +! return -1; +! } +! di->di_tv.v_lock = 0; +! +! if (_ConvertFromPyObject(valObject, &di->di_tv, lookupDict) == -1) +! { +! vim_free(di); +! Py_DECREF(list); +! Py_DECREF(litem); +! return -1; +! } +! if (dict_add(d, di) == FAIL) +! { +! vim_free(di); +! Py_DECREF(list); +! Py_DECREF(litem); +! PyErr_SetVim(_("failed to add key to dictionary")); +! return -1; +! } +! Py_DECREF(litem); +! } +! Py_DECREF(list); +! return 0; +! } +! +! static PyInt +! DictionaryLength(PyObject *self) +! { +! return ((PyInt) ((((DictionaryObject *)(self))->dict->dv_hashtab.ht_used))); +! } +! +! static PyObject * +! DictionaryItem(PyObject *self, PyObject *keyObject) +! { +! char_u *key; +! dictitem_T *val; +! DICTKEY_DECL +! +! DICTKEY_GET(NULL) +! +! val = dict_find(((DictionaryObject *) (self))->dict, key, -1); +! +! DICTKEY_UNREF +! +! return ConvertToPyObject(&val->di_tv); +! } +! +! static PyInt +! DictionaryAssItem(PyObject *self, PyObject *keyObject, PyObject *valObject) +! { +! char_u *key; +! typval_T tv; +! dict_T *d = ((DictionaryObject *)(self))->dict; +! dictitem_T *di; +! DICTKEY_DECL +! +! if (d->dv_lock) +! { +! PyErr_SetVim(_("dict is locked")); +! return -1; +! } +! +! DICTKEY_GET(-1) +! +! di = dict_find(d, key, -1); +! +! if (valObject == NULL) +! { +! if (di == NULL) +! { +! PyErr_SetString(PyExc_IndexError, _("no such key in dictionary")); +! return -1; +! } +! hashitem_T *hi = hash_find(&d->dv_hashtab, di->di_key); +! hash_remove(&d->dv_hashtab, hi); +! dictitem_free(di); +! return 0; +! } +! +! if (ConvertFromPyObject(valObject, &tv) == -1) +! { +! return -1; +! } +! +! if (di == NULL) +! { +! di = dictitem_alloc(key); +! if (di == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! di->di_tv.v_lock = 0; +! +! if (dict_add(d, di) == FAIL) +! { +! vim_free(di); +! PyErr_SetVim(_("failed to add key to dictionary")); +! return -1; +! } +! } +! else +! clear_tv(&di->di_tv); +! +! DICTKEY_UNREF +! +! copy_tv(&tv, &di->di_tv); +! return 0; +! } +! +! static PyObject * +! DictionaryListKeys(PyObject *self) +! { +! dict_T *dict = ((DictionaryObject *)(self))->dict; +! long_u todo = dict->dv_hashtab.ht_used; +! Py_ssize_t i = 0; +! PyObject *r; +! hashitem_T *hi; +! +! r = PyList_New(todo); +! for (hi = dict->dv_hashtab.ht_array; todo > 0; ++hi) +! { +! if (!HASHITEM_EMPTY(hi)) +! { +! PyList_SetItem(r, i, PyBytes_FromString((char *)(hi->hi_key))); +! --todo; +! ++i; +! } +! } +! return r; +! } +! +! static struct PyMethodDef DictionaryMethods[] = { +! {"keys", (PyCFunction)DictionaryListKeys, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL } +! }; +! +! static PyTypeObject ListType; +! +! typedef struct +! { +! PyObject_HEAD +! list_T *list; +! pylinkedlist_T ref; +! } ListObject; +! +! static PyObject * +! ListNew(list_T *list) +! { +! ListObject *self; +! +! self = PyObject_NEW(ListObject, &ListType); +! if (self == NULL) +! return NULL; +! self->list = list; +! ++list->lv_refcount; +! +! pyll_add((PyObject *)(self), &self->ref, &lastlist); +! +! return (PyObject *)(self); +! } +! +! static int +! list_py_concat(list_T *l, PyObject *obj, PyObject *lookupDict) +! { +! Py_ssize_t i; +! Py_ssize_t lsize = PySequence_Size(obj); +! PyObject *litem; +! listitem_T *li; +! +! for(i=0; ili_tv.v_lock = 0; +! +! litem = PySequence_GetItem(obj, i); +! if (litem == NULL) +! return -1; +! if (_ConvertFromPyObject(litem, &li->li_tv, lookupDict) == -1) +! return -1; +! +! list_append(l, li); +! } +! return 0; +! } +! +! static int +! pyseq_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) +! { +! list_T *l; +! +! l = list_alloc(); +! if (l == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! +! tv->v_type = VAR_LIST; +! tv->vval.v_list = l; +! +! if (list_py_concat(l, obj, lookupDict) == -1) +! return -1; +! +! return 0; +! } +! +! static int +! pyiter_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) +! { +! PyObject *iterator = PyObject_GetIter(obj); +! PyObject *item; +! list_T *l; +! listitem_T *li; +! +! l = list_alloc(); +! +! if (l == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! +! tv->vval.v_list = l; +! tv->v_type = VAR_LIST; +! +! +! if (iterator == NULL) +! return -1; +! +! while ((item = PyIter_Next(obj))) +! { +! li = listitem_alloc(); +! if (li == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! li->li_tv.v_lock = 0; +! +! if (_ConvertFromPyObject(item, &li->li_tv, lookupDict) == -1) +! return -1; +! +! list_append(l, li); +! +! Py_DECREF(item); +! } +! +! Py_DECREF(iterator); +! return 0; +! } +! +! static PyInt +! ListLength(PyObject *self) +! { +! return ((PyInt) (((ListObject *) (self))->list->lv_len)); +! } +! +! static PyObject * +! ListItem(PyObject *self, Py_ssize_t index) +! { +! listitem_T *li; +! +! if (index>=ListLength(self)) +! { +! PyErr_SetString(PyExc_IndexError, "list index out of range"); +! return NULL; +! } +! li = list_find(((ListObject *) (self))->list, (long) index); +! if (li == NULL) +! { +! PyErr_SetVim(_("internal error: failed to get vim list item")); +! return NULL; +! } +! return ConvertToPyObject(&li->li_tv); +! } +! +! #define PROC_RANGE \ +! if (last < 0) {\ +! if (last < -size) \ +! last = 0; \ +! else \ +! last += size; \ +! } \ +! if (first < 0) \ +! first = 0; \ +! if (first > size) \ +! first = size; \ +! if (last > size) \ +! last = size; +! +! static PyObject * +! ListSlice(PyObject *self, Py_ssize_t first, Py_ssize_t last) +! { +! PyInt i; +! PyInt size = ListLength(self); +! PyInt n; +! PyObject *list; +! int reversed = 0; +! +! PROC_RANGE +! if (first >= last) +! first = last; +! +! n = last-first; +! list = PyList_New(n); +! if (list == NULL) +! return NULL; +! +! for (i = 0; i < n; ++i) +! { +! PyObject *item = ListItem(self, i); +! if (item == NULL) +! { +! Py_DECREF(list); +! return NULL; +! } +! +! if ((PyList_SetItem(list, ((reversed)?(n-i-1):(i)), item))) +! { +! Py_DECREF(item); +! Py_DECREF(list); +! return NULL; +! } +! } +! +! return list; +! } +! +! static int +! ListAssItem(PyObject *self, Py_ssize_t index, PyObject *obj) +! { +! typval_T tv; +! list_T *l = ((ListObject *) (self))->list; +! listitem_T *li; +! Py_ssize_t length = ListLength(self); +! +! if (l->lv_lock) +! { +! PyErr_SetVim(_("list is locked")); +! return -1; +! } +! if (index>length || (index==length && obj==NULL)) +! { +! PyErr_SetString(PyExc_IndexError, "list index out of range"); +! return -1; +! } +! +! if (obj == NULL) +! { +! li = list_find(l, (long) index); +! list_remove(l, li, li); +! clear_tv(&li->li_tv); +! vim_free(li); +! return 0; +! } +! +! if (ConvertFromPyObject(obj, &tv) == -1) +! return -1; +! +! if (index == length) +! { +! if (list_append_tv(l, &tv) == FAIL) +! { +! PyErr_SetVim(_("Failed to add item to list")); +! return -1; +! } +! } +! else +! { +! li = list_find(l, (long) index); +! clear_tv(&li->li_tv); +! copy_tv(&tv, &li->li_tv); +! } +! return 0; +! } +! +! static int +! ListAssSlice(PyObject *self, Py_ssize_t first, Py_ssize_t last, PyObject *obj) +! { +! PyInt size = ListLength(self); +! Py_ssize_t i; +! Py_ssize_t lsize; +! PyObject *litem; +! listitem_T *li; +! listitem_T *next; +! typval_T v; +! list_T *l = ((ListObject *) (self))->list; +! +! if (l->lv_lock) +! { +! PyErr_SetVim(_("list is locked")); +! return -1; +! } +! +! PROC_RANGE + +! if (first == size) +! li = NULL; +! else +! { +! li = list_find(l, (long) first); +! if (li == NULL) +! { +! PyErr_SetVim(_("internal error: no vim list item")); +! return -1; +! } +! if (last > first) +! { +! i = last - first; +! while (i-- && li != NULL) + { +! next = li->li_next; +! listitem_remove(l, li); +! li = next; + } + } + } +! +! if (obj == NULL) +! return 0; +! +! if (!PyList_Check(obj)) + { +! PyErr_SetString(PyExc_TypeError, _("can only assign lists to slice")); +! return -1; + } + +! lsize = PyList_Size(obj); +! +! for(i=0; ilist; +! PyObject *lookup_dict; + +! if (l->lv_lock) +! { +! PyErr_SetVim(_("list is locked")); + return NULL; ++ } + +! if (!PySequence_Check(obj)) + { +! PyErr_SetString(PyExc_TypeError, _("can only concatenate with lists")); + return NULL; + } + + lookup_dict = PyDict_New(); +! if (list_py_concat(l, obj, lookup_dict) == -1) +! { +! Py_DECREF(lookup_dict); +! return NULL; +! } + Py_DECREF(lookup_dict); + +! Py_INCREF(self); +! return self; + } + +! static struct PyMethodDef ListMethods[] = { +! {"extend", (PyCFunction)ListConcatInPlace, METH_O, ""}, +! { NULL, NULL, 0, NULL } + }; + + typedef struct + { + PyObject_HEAD +! char_u *name; +! } FunctionObject; + +! static PyTypeObject FunctionType; + +! static PyObject * +! FunctionNew(char_u *name) + { +! FunctionObject *self; + +! self = PyObject_NEW(FunctionObject, &FunctionType); +! if (self == NULL) +! return NULL; +! self->name = PyMem_New(char_u, STRLEN(name) + 1); +! if (self->name == NULL) + { +! PyErr_NoMemory(); +! return NULL; + } +! STRCPY(self->name, name); +! func_ref(name); +! return (PyObject *)(self); + } + + static PyObject * +! FunctionCall(PyObject *self, PyObject *argsObject, PyObject *kwargs) + { +! FunctionObject *this = (FunctionObject *)(self); +! char_u *name = this->name; +! typval_T args; +! typval_T selfdicttv; +! typval_T rettv; +! dict_T *selfdict = NULL; +! PyObject *selfdictObject; +! PyObject *result; +! int error; + +! if (ConvertFromPyObject(argsObject, &args) == -1) +! return NULL; +! +! if (kwargs != NULL) + { +! selfdictObject = PyDict_GetItemString(kwargs, "self"); +! if (selfdictObject != NULL) +! { +! if (!PyDict_Check(selfdictObject)) +! { +! PyErr_SetString(PyExc_TypeError, _("'self' argument must be a dictionary")); +! clear_tv(&args); +! return NULL; +! } +! if (ConvertFromPyObject(selfdictObject, &selfdicttv) == -1) +! return NULL; +! selfdict = selfdicttv.vval.v_dict; +! } + } + +! error = func_call(name, &args, selfdict, &rettv); +! if (error != OK) +! { +! result = NULL; +! PyErr_SetVim(_("failed to run function")); +! } +! else +! result = ConvertToPyObject(&rettv); +! +! /* FIXME Check what should really be cleared. */ +! clear_tv(&args); +! clear_tv(&rettv); +! /* +! * if (selfdict!=NULL) +! * clear_tv(selfdicttv); +! */ +! +! return result; + } + +! static struct PyMethodDef FunctionMethods[] = { +! {"__call__", (PyCFunction)FunctionCall, METH_VARARGS|METH_KEYWORDS, ""}, +! { NULL, NULL, 0, NULL } +! }; + + #define INVALID_WINDOW_VALUE ((win_T *)(-1)) + +*************** +*** 1567,1569 **** +--- 2383,2638 ---- + { NULL, NULL, 0, NULL } + }; + ++ static void ++ set_ref_in_py(const int copyID) ++ { ++ pylinkedlist_T *cur; ++ dict_T *dd; ++ list_T *ll; ++ ++ if (lastdict != NULL) ++ for(cur = lastdict ; cur != NULL ; cur = cur->pll_prev) ++ { ++ dd = ((DictionaryObject *) (cur->pll_obj))->dict; ++ if (dd->dv_copyID != copyID) ++ { ++ dd->dv_copyID = copyID; ++ set_ref_in_ht(&dd->dv_hashtab, copyID); ++ } ++ } ++ ++ if (lastlist != NULL) ++ for(cur = lastlist ; cur != NULL ; cur = cur->pll_prev) ++ { ++ ll = ((ListObject *) (cur->pll_obj))->list; ++ if (ll->lv_copyID != copyID) ++ { ++ ll->lv_copyID = copyID; ++ set_ref_in_list(ll, copyID); ++ } ++ } ++ } ++ ++ static int ++ set_string_copy(char_u *str, typval_T *tv) ++ { ++ tv->vval.v_string = vim_strsave(str); ++ if (tv->vval.v_string == NULL) ++ { ++ PyErr_NoMemory(); ++ return -1; ++ } ++ return 0; ++ } ++ ++ #ifdef FEAT_EVAL ++ typedef int (*pytotvfunc)(PyObject *, typval_T *, PyObject *); ++ ++ static int ++ convert_dl(PyObject *obj, typval_T *tv, ++ pytotvfunc py_to_tv, PyObject *lookupDict) ++ { ++ PyObject *capsule; ++ char hexBuf[sizeof(void *) * 2 + 3]; ++ ++ sprintf(hexBuf, "%p", obj); ++ ++ capsule = PyDict_GetItemString(lookupDict, hexBuf); ++ if (capsule == NULL) ++ { ++ capsule = PyCapsule_New(tv, NULL, NULL); ++ PyDict_SetItemString(lookupDict, hexBuf, capsule); ++ Py_DECREF(capsule); ++ if (py_to_tv(obj, tv, lookupDict) == -1) ++ { ++ tv->v_type = VAR_UNKNOWN; ++ return -1; ++ } ++ /* As we are not using copy_tv which increments reference count we must ++ * do it ourself. */ ++ switch(tv->v_type) ++ { ++ case VAR_DICT: ++tv->vval.v_dict->dv_refcount; break; ++ case VAR_LIST: ++tv->vval.v_list->lv_refcount; break; ++ } ++ } ++ else ++ { ++ typval_T *v = PyCapsule_GetPointer(capsule, NULL); ++ copy_tv(v, tv); ++ } ++ return 0; ++ } ++ ++ static int ++ ConvertFromPyObject(PyObject *obj, typval_T *tv) ++ { ++ PyObject *lookup_dict; ++ int r; ++ ++ lookup_dict = PyDict_New(); ++ r = _ConvertFromPyObject(obj, tv, lookup_dict); ++ Py_DECREF(lookup_dict); ++ return r; ++ } ++ ++ static int ++ _ConvertFromPyObject(PyObject *obj, typval_T *tv, PyObject *lookupDict) ++ { ++ if (obj->ob_type == &DictionaryType) ++ { ++ tv->v_type = VAR_DICT; ++ tv->vval.v_dict = (((DictionaryObject *)(obj))->dict); ++ ++tv->vval.v_dict->dv_refcount; ++ } ++ else if (obj->ob_type == &ListType) ++ { ++ tv->v_type = VAR_LIST; ++ tv->vval.v_list = (((ListObject *)(obj))->list); ++ ++tv->vval.v_list->lv_refcount; ++ } ++ else if (obj->ob_type == &FunctionType) ++ { ++ if (set_string_copy(((FunctionObject *) (obj))->name, tv) == -1) ++ return -1; ++ ++ tv->v_type = VAR_FUNC; ++ func_ref(tv->vval.v_string); ++ } ++ #if PY_MAJOR_VERSION >= 3 ++ else if (PyBytes_Check(obj)) ++ { ++ char_u *result = (char_u *) PyBytes_AsString(obj); ++ ++ if (result == NULL) ++ return -1; ++ ++ if (set_string_copy(result, tv) == -1) ++ return -1; ++ ++ tv->v_type = VAR_STRING; ++ } ++ else if (PyUnicode_Check(obj)) ++ { ++ PyObject *bytes; ++ char_u *result; ++ ++ bytes = PyString_AsBytes(obj); ++ if (bytes == NULL) ++ return -1; ++ ++ result = (char_u *) PyBytes_AsString(bytes); ++ if (result == NULL) ++ return -1; ++ ++ if (set_string_copy(result, tv) == -1) ++ { ++ Py_XDECREF(bytes); ++ return -1; ++ } ++ Py_XDECREF(bytes); ++ ++ tv->v_type = VAR_STRING; ++ } ++ #else ++ else if (PyUnicode_Check(obj)) ++ { ++ PyObject *bytes; ++ char_u *result; ++ ++ bytes = PyUnicode_AsEncodedString(obj, (char *)ENC_OPT, NULL); ++ if (bytes == NULL) ++ return -1; ++ ++ result=(char_u *) PyString_AsString(bytes); ++ if (result == NULL) ++ return -1; ++ ++ if (set_string_copy(result, tv) == -1) ++ { ++ Py_XDECREF(bytes); ++ return -1; ++ } ++ Py_XDECREF(bytes); ++ ++ tv->v_type = VAR_STRING; ++ } ++ else if (PyString_Check(obj)) ++ { ++ char_u *result = (char_u *) PyString_AsString(obj); ++ ++ if (result == NULL) ++ return -1; ++ ++ if (set_string_copy(result, tv) == -1) ++ return -1; ++ ++ tv->v_type = VAR_STRING; ++ } ++ else if (PyInt_Check(obj)) ++ { ++ tv->v_type = VAR_NUMBER; ++ tv->vval.v_number = (varnumber_T) PyInt_AsLong(obj); ++ } ++ #endif ++ else if (PyLong_Check(obj)) ++ { ++ tv->v_type = VAR_NUMBER; ++ tv->vval.v_number = (varnumber_T) PyLong_AsLong(obj); ++ } ++ else if (PyDict_Check(obj)) ++ return convert_dl(obj, tv, pydict_to_tv, lookupDict); ++ #ifdef FEAT_FLOAT ++ else if (PyFloat_Check(obj)) ++ { ++ tv->v_type = VAR_FLOAT; ++ tv->vval.v_float = (float_T) PyFloat_AsDouble(obj); ++ } ++ #endif ++ else if (PyIter_Check(obj)) ++ return convert_dl(obj, tv, pyiter_to_tv, lookupDict); ++ else if (PySequence_Check(obj)) ++ return convert_dl(obj, tv, pyseq_to_tv, lookupDict); ++ else if (PyMapping_Check(obj)) ++ return convert_dl(obj, tv, pymap_to_tv, lookupDict); ++ else ++ { ++ PyErr_SetString(PyExc_TypeError, _("unable to convert to vim structure")); ++ return -1; ++ } ++ return 0; ++ } ++ ++ static PyObject * ++ ConvertToPyObject(typval_T *tv) ++ { ++ if (tv == NULL) ++ { ++ PyErr_SetVim(_("NULL reference passed")); ++ return NULL; ++ } ++ switch (tv->v_type) ++ { ++ case VAR_STRING: ++ return PyBytes_FromString((char *) tv->vval.v_string); ++ case VAR_NUMBER: ++ return PyLong_FromLong((long) tv->vval.v_number); ++ #ifdef FEAT_FLOAT ++ case VAR_FLOAT: ++ return PyFloat_FromDouble((double) tv->vval.v_float); ++ #endif ++ case VAR_LIST: ++ return ListNew(tv->vval.v_list); ++ case VAR_DICT: ++ return DictionaryNew(tv->vval.v_dict); ++ case VAR_FUNC: ++ return FunctionNew(tv->vval.v_string); ++ case VAR_UNKNOWN: ++ Py_INCREF(Py_None); ++ return Py_None; ++ default: ++ PyErr_SetVim(_("internal error: invalid value type")); ++ return NULL; ++ } ++ } ++ #endif +*** ../vim-7.3.568/src/if_python.c 2011-08-28 16:00:14.000000000 +0200 +--- src/if_python.c 2012-06-29 12:47:48.000000000 +0200 +*************** +*** 1,4 **** +! /* vi:set ts=8 sts=4 sw=4: + * + * VIM - Vi IMproved by Bram Moolenaar + * +--- 1,4 ---- +! /* vi:set ts=8 sts=4 sw=4 noet: + * + * VIM - Vi IMproved by Bram Moolenaar + * +*************** +*** 56,61 **** +--- 56,63 ---- + + static void init_structs(void); + ++ #define PyBytes_FromString PyString_FromString ++ + /* No-op conversion functions, use with care! */ + #define PyString_AsBytes(obj) (obj) + #define PyString_FreeBytes(obj) +*************** +*** 122,132 **** +--- 124,136 ---- + /* This makes if_python.c compile without warnings against Python 2.5 + * on Win32 and Win64. */ + # undef PyRun_SimpleString ++ # undef PyRun_String + # undef PyArg_Parse + # undef PyArg_ParseTuple + # undef Py_BuildValue + # undef Py_InitModule4 + # undef Py_InitModule4_64 ++ # undef PyObject_CallMethod + + /* + * Wrapper defines +*************** +*** 134,139 **** +--- 138,144 ---- + # define PyArg_Parse dll_PyArg_Parse + # define PyArg_ParseTuple dll_PyArg_ParseTuple + # define PyMem_Free dll_PyMem_Free ++ # define PyMem_Malloc dll_PyMem_Malloc + # define PyDict_SetItemString dll_PyDict_SetItemString + # define PyErr_BadArgument dll_PyErr_BadArgument + # define PyErr_Clear dll_PyErr_Clear +*************** +*** 150,172 **** +--- 155,202 ---- + # endif + # define PyInt_AsLong dll_PyInt_AsLong + # define PyInt_FromLong dll_PyInt_FromLong ++ # define PyLong_AsLong dll_PyLong_AsLong ++ # define PyLong_FromLong dll_PyLong_FromLong + # define PyInt_Type (*dll_PyInt_Type) ++ # define PyLong_Type (*dll_PyLong_Type) + # define PyList_GetItem dll_PyList_GetItem + # define PyList_Append dll_PyList_Append + # define PyList_New dll_PyList_New + # define PyList_SetItem dll_PyList_SetItem + # define PyList_Size dll_PyList_Size + # define PyList_Type (*dll_PyList_Type) ++ # define PySequence_Check dll_PySequence_Check ++ # define PySequence_Size dll_PySequence_Size ++ # define PySequence_GetItem dll_PySequence_GetItem ++ # define PyTuple_Size dll_PyTuple_Size ++ # define PyTuple_GetItem dll_PyTuple_GetItem ++ # define PyTuple_Type (*dll_PyTuple_Type) + # define PyImport_ImportModule dll_PyImport_ImportModule + # define PyDict_New dll_PyDict_New + # define PyDict_GetItemString dll_PyDict_GetItemString ++ # define PyDict_Next dll_PyDict_Next ++ # ifdef PyMapping_Items ++ # define PY_NO_MAPPING_ITEMS ++ # else ++ # define PyMapping_Items dll_PyMapping_Items ++ # endif ++ # define PyObject_CallMethod dll_PyObject_CallMethod ++ # define PyMapping_Check dll_PyMapping_Check ++ # define PyIter_Next dll_PyIter_Next + # define PyModule_GetDict dll_PyModule_GetDict + # define PyRun_SimpleString dll_PyRun_SimpleString ++ # define PyRun_String dll_PyRun_String + # define PyString_AsString dll_PyString_AsString + # define PyString_FromString dll_PyString_FromString + # define PyString_FromStringAndSize dll_PyString_FromStringAndSize + # define PyString_Size dll_PyString_Size + # define PyString_Type (*dll_PyString_Type) ++ # define PyUnicode_Type (*dll_PyUnicode_Type) ++ # define PyUnicodeUCS4_AsEncodedString (*dll_PyUnicodeUCS4_AsEncodedString) ++ # define PyFloat_AsDouble dll_PyFloat_AsDouble ++ # define PyFloat_FromDouble dll_PyFloat_FromDouble ++ # define PyFloat_Type (*dll_PyFloat_Type) ++ # define PyImport_AddModule (*dll_PyImport_AddModule) + # define PySys_SetObject dll_PySys_SetObject + # define PySys_SetArgv dll_PySys_SetArgv + # define PyType_Type (*dll_PyType_Type) +*************** +*** 179,186 **** +--- 209,218 ---- + # define Py_Finalize dll_Py_Finalize + # define Py_IsInitialized dll_Py_IsInitialized + # define _PyObject_New dll__PyObject_New ++ # define _PyObject_NextNotImplemented (*dll__PyObject_NextNotImplemented) + # define _Py_NoneStruct (*dll__Py_NoneStruct) + # define PyObject_Init dll__PyObject_Init ++ # define PyObject_GetIter dll_PyObject_GetIter + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + # define PyType_IsSubtype dll_PyType_IsSubtype + # endif +*************** +*** 188,193 **** +--- 220,227 ---- + # define PyObject_Malloc dll_PyObject_Malloc + # define PyObject_Free dll_PyObject_Free + # endif ++ # define PyCapsule_New dll_PyCapsule_New ++ # define PyCapsule_GetPointer dll_PyCapsule_GetPointer + + /* + * Pointers for dynamic link +*************** +*** 195,200 **** +--- 229,235 ---- + static int(*dll_PyArg_Parse)(PyObject *, char *, ...); + static int(*dll_PyArg_ParseTuple)(PyObject *, char *, ...); + static int(*dll_PyMem_Free)(void *); ++ static void* (*dll_PyMem_Malloc)(size_t); + static int(*dll_PyDict_SetItemString)(PyObject *dp, char *key, PyObject *item); + static int(*dll_PyErr_BadArgument)(void); + static void(*dll_PyErr_Clear)(void); +*************** +*** 208,233 **** + # ifdef PY_CAN_RECURSE + static PyGILState_STATE (*dll_PyGILState_Ensure)(void); + static void (*dll_PyGILState_Release)(PyGILState_STATE); +! #endif + static long(*dll_PyInt_AsLong)(PyObject *); + static PyObject*(*dll_PyInt_FromLong)(long); + static PyTypeObject* dll_PyInt_Type; + static PyObject*(*dll_PyList_GetItem)(PyObject *, PyInt); + static PyObject*(*dll_PyList_Append)(PyObject *, PyObject *); + static PyObject*(*dll_PyList_New)(PyInt size); + static int(*dll_PyList_SetItem)(PyObject *, PyInt, PyObject *); + static PyInt(*dll_PyList_Size)(PyObject *); + static PyTypeObject* dll_PyList_Type; + static PyObject*(*dll_PyImport_ImportModule)(const char *); + static PyObject*(*dll_PyDict_New)(void); + static PyObject*(*dll_PyDict_GetItemString)(PyObject *, const char *); + static PyObject*(*dll_PyModule_GetDict)(PyObject *); + static int(*dll_PyRun_SimpleString)(char *); + static char*(*dll_PyString_AsString)(PyObject *); + static PyObject*(*dll_PyString_FromString)(const char *); + static PyObject*(*dll_PyString_FromStringAndSize)(const char *, PyInt); + static PyInt(*dll_PyString_Size)(PyObject *); + static PyTypeObject* dll_PyString_Type; + static int(*dll_PySys_SetObject)(char *, PyObject *); + static int(*dll_PySys_SetArgv)(int, char **); + static PyTypeObject* dll_PyType_Type; +--- 243,290 ---- + # ifdef PY_CAN_RECURSE + static PyGILState_STATE (*dll_PyGILState_Ensure)(void); + static void (*dll_PyGILState_Release)(PyGILState_STATE); +! # endif + static long(*dll_PyInt_AsLong)(PyObject *); + static PyObject*(*dll_PyInt_FromLong)(long); ++ static long(*dll_PyLong_AsLong)(PyObject *); ++ static PyObject*(*dll_PyLong_FromLong)(long); + static PyTypeObject* dll_PyInt_Type; ++ static PyTypeObject* dll_PyLong_Type; + static PyObject*(*dll_PyList_GetItem)(PyObject *, PyInt); + static PyObject*(*dll_PyList_Append)(PyObject *, PyObject *); + static PyObject*(*dll_PyList_New)(PyInt size); + static int(*dll_PyList_SetItem)(PyObject *, PyInt, PyObject *); + static PyInt(*dll_PyList_Size)(PyObject *); + static PyTypeObject* dll_PyList_Type; ++ static int (*dll_PySequence_Check)(PyObject *); ++ static PyInt(*dll_PySequence_Size)(PyObject *); ++ static PyObject*(*dll_PySequence_GetItem)(PyObject *, PyInt); ++ static PyInt(*dll_PyTuple_Size)(PyObject *); ++ static PyObject*(*dll_PyTuple_GetItem)(PyObject *, PyInt); ++ static PyTypeObject* dll_PyTuple_Type; + static PyObject*(*dll_PyImport_ImportModule)(const char *); + static PyObject*(*dll_PyDict_New)(void); + static PyObject*(*dll_PyDict_GetItemString)(PyObject *, const char *); ++ static int (*dll_PyDict_Next)(PyObject *, Py_ssize_t *, PyObject **, PyObject **); ++ # ifndef PY_NO_MAPPING_ITEMS ++ static PyObject* (*dll_PyMapping_Items)(PyObject *); ++ # endif ++ static PyObject* (*dll_PyObject_CallMethod)(PyObject *, char *, PyObject *); ++ static int (*dll_PyMapping_Check)(PyObject *); ++ static PyObject* (*dll_PyIter_Next)(PyObject *); + static PyObject*(*dll_PyModule_GetDict)(PyObject *); + static int(*dll_PyRun_SimpleString)(char *); ++ static PyObject *(*dll_PyRun_String)(char *, int, PyObject *, PyObject *); + static char*(*dll_PyString_AsString)(PyObject *); + static PyObject*(*dll_PyString_FromString)(const char *); + static PyObject*(*dll_PyString_FromStringAndSize)(const char *, PyInt); + static PyInt(*dll_PyString_Size)(PyObject *); + static PyTypeObject* dll_PyString_Type; ++ static PyTypeObject* dll_PyUnicode_Type; ++ static PyObject *(*PyUnicodeUCS4_AsEncodedString)(PyObject *, char *, char *); ++ static double(*dll_PyFloat_AsDouble)(PyObject *); ++ static PyObject*(*dll_PyFloat_FromDouble)(double); ++ static PyTypeObject* dll_PyFloat_Type; + static int(*dll_PySys_SetObject)(char *, PyObject *); + static int(*dll_PySys_SetArgv)(int, char **); + static PyTypeObject* dll_PyType_Type; +*************** +*** 235,246 **** +--- 292,306 ---- + static PyObject*(*dll_Py_BuildValue)(char *, ...); + static PyObject*(*dll_Py_FindMethod)(struct PyMethodDef[], PyObject *, char *); + static PyObject*(*dll_Py_InitModule4)(char *, struct PyMethodDef *, char *, PyObject *, int); ++ static PyObject*(*dll_PyImport_AddModule)(char *); + static void(*dll_Py_SetPythonHome)(char *home); + static void(*dll_Py_Initialize)(void); + static void(*dll_Py_Finalize)(void); + static int(*dll_Py_IsInitialized)(void); + static PyObject*(*dll__PyObject_New)(PyTypeObject *, PyObject *); + static PyObject*(*dll__PyObject_Init)(PyObject *, PyTypeObject *); ++ static PyObject* (*dll_PyObject_GetIter)(PyObject *); ++ static iternextfunc dll__PyObject_NextNotImplemented; + static PyObject* dll__Py_NoneStruct; + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + static int (*dll_PyType_IsSubtype)(PyTypeObject *, PyTypeObject *); +*************** +*** 249,254 **** +--- 309,316 ---- + static void* (*dll_PyObject_Malloc)(size_t); + static void (*dll_PyObject_Free)(void*); + # endif ++ static PyObject* (*dll_PyCapsule_New)(void *, char *, PyCapsule_Destructor); ++ static void* (*dll_PyCapsule_GetPointer)(PyObject *, char *); + + static HINSTANCE hinstPython = 0; /* Instance of python.dll */ + +*************** +*** 278,283 **** +--- 340,346 ---- + {"PyArg_Parse", (PYTHON_PROC*)&dll_PyArg_Parse}, + {"PyArg_ParseTuple", (PYTHON_PROC*)&dll_PyArg_ParseTuple}, + {"PyMem_Free", (PYTHON_PROC*)&dll_PyMem_Free}, ++ {"PyMem_Malloc", (PYTHON_PROC*)&dll_PyMem_Malloc}, + {"PyDict_SetItemString", (PYTHON_PROC*)&dll_PyDict_SetItemString}, + {"PyErr_BadArgument", (PYTHON_PROC*)&dll_PyErr_BadArgument}, + {"PyErr_Clear", (PYTHON_PROC*)&dll_PyErr_Clear}, +*************** +*** 294,316 **** +--- 357,402 ---- + # endif + {"PyInt_AsLong", (PYTHON_PROC*)&dll_PyInt_AsLong}, + {"PyInt_FromLong", (PYTHON_PROC*)&dll_PyInt_FromLong}, ++ {"PyLong_AsLong", (PYTHON_PROC*)&dll_PyLong_AsLong}, ++ {"PyLong_FromLong", (PYTHON_PROC*)&dll_PyLong_FromLong}, + {"PyInt_Type", (PYTHON_PROC*)&dll_PyInt_Type}, ++ {"PyLong_Type", (PYTHON_PROC*)&dll_PyLong_Type}, + {"PyList_GetItem", (PYTHON_PROC*)&dll_PyList_GetItem}, + {"PyList_Append", (PYTHON_PROC*)&dll_PyList_Append}, + {"PyList_New", (PYTHON_PROC*)&dll_PyList_New}, + {"PyList_SetItem", (PYTHON_PROC*)&dll_PyList_SetItem}, + {"PyList_Size", (PYTHON_PROC*)&dll_PyList_Size}, + {"PyList_Type", (PYTHON_PROC*)&dll_PyList_Type}, ++ {"PySequence_GetItem", (PYTHON_PROC*)&dll_PySequence_GetItem}, ++ {"PySequence_Size", (PYTHON_PROC*)&dll_PySequence_Size}, ++ {"PySequence_Check", (PYTHON_PROC*)&dll_PySequence_Check}, ++ {"PyTuple_GetItem", (PYTHON_PROC*)&dll_PyTuple_GetItem}, ++ {"PyTuple_Size", (PYTHON_PROC*)&dll_PyTuple_Size}, ++ {"PyTuple_Type", (PYTHON_PROC*)&dll_PyTuple_Type}, + {"PyImport_ImportModule", (PYTHON_PROC*)&dll_PyImport_ImportModule}, + {"PyDict_GetItemString", (PYTHON_PROC*)&dll_PyDict_GetItemString}, ++ {"PyDict_Next", (PYTHON_PROC*)&dll_PyDict_Next}, + {"PyDict_New", (PYTHON_PROC*)&dll_PyDict_New}, ++ # ifndef PY_NO_MAPPING_ITEMS ++ {"PyMapping_Items", (PYTHON_PROC*)&dll_PyMapping_Items}, ++ # endif ++ {"PyObject_CallMethod", (PYTHON_PROC*)&dll_PyObject_CallMethod}, ++ {"PyMapping_Check", (PYTHON_PROC*)&dll_PyMapping_Check}, ++ {"PyIter_Next", (PYTHON_PROC*)&dll_PyIter_Next}, + {"PyModule_GetDict", (PYTHON_PROC*)&dll_PyModule_GetDict}, + {"PyRun_SimpleString", (PYTHON_PROC*)&dll_PyRun_SimpleString}, ++ {"PyRun_String", (PYTHON_PROC*)&dll_PyRun_String}, + {"PyString_AsString", (PYTHON_PROC*)&dll_PyString_AsString}, + {"PyString_FromString", (PYTHON_PROC*)&dll_PyString_FromString}, + {"PyString_FromStringAndSize", (PYTHON_PROC*)&dll_PyString_FromStringAndSize}, + {"PyString_Size", (PYTHON_PROC*)&dll_PyString_Size}, + {"PyString_Type", (PYTHON_PROC*)&dll_PyString_Type}, ++ {"PyUnicode_Type", (PYTHON_PROC*)&dll_PyUnicode_Type}, ++ {"PyUnicodeUCS4_AsEncodedString", (PYTHON_PROC*)&dll_PyUnicodeUCS4_AsEncodedString}, ++ {"PyFloat_Type", (PYTHON_PROC*)&dll_PyFloat_Type}, ++ {"PyFloat_AsDouble", (PYTHON_PROC*)&dll_PyFloat_AsDouble}, ++ {"PyFloat_FromDouble", (PYTHON_PROC*)&dll_PyFloat_FromDouble}, ++ {"PyImport_AddModule", (PYTHON_PROC*)&dll_PyImport_AddModule}, + {"PySys_SetObject", (PYTHON_PROC*)&dll_PySys_SetObject}, + {"PySys_SetArgv", (PYTHON_PROC*)&dll_PySys_SetArgv}, + {"PyType_Type", (PYTHON_PROC*)&dll_PyType_Type}, +*************** +*** 328,333 **** +--- 414,421 ---- + {"Py_IsInitialized", (PYTHON_PROC*)&dll_Py_IsInitialized}, + {"_PyObject_New", (PYTHON_PROC*)&dll__PyObject_New}, + {"PyObject_Init", (PYTHON_PROC*)&dll__PyObject_Init}, ++ {"PyObject_GetIter", (PYTHON_PROC*)&dll_PyObject_GetIter}, ++ {"_PyObject_NextNotImplemented", (PYTHON_PROC*)&dll__PyObject_NextNotImplemented}, + {"_Py_NoneStruct", (PYTHON_PROC*)&dll__Py_NoneStruct}, + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + {"PyType_IsSubtype", (PYTHON_PROC*)&dll_PyType_IsSubtype}, +*************** +*** 336,341 **** +--- 424,431 ---- + {"PyObject_Malloc", (PYTHON_PROC*)&dll_PyObject_Malloc}, + {"PyObject_Free", (PYTHON_PROC*)&dll_PyObject_Free}, + # endif ++ {"PyCapsule_New", (PYTHON_PROC*)&dll_PyCapsule_New}, ++ {"PyCapsule_GetPointer", (PYTHON_PROC*)&dll_PyCapsule_GetPointer}, + {"", NULL}, + }; + +*************** +*** 434,443 **** +--- 524,548 ---- + + static PyObject *BufferNew (buf_T *); + static PyObject *WindowNew(win_T *); ++ static PyObject *DictionaryNew(dict_T *); + static PyObject *LineToString(const char *); + + static PyTypeObject RangeType; + ++ static int initialised = 0; ++ #define PYINITIALISED initialised ++ ++ /* Add conversion from PyInt? */ ++ #define DICTKEY_GET(err) \ ++ if (!PyString_Check(keyObject)) \ ++ { \ ++ PyErr_SetString(PyExc_TypeError, _("only string keys are allowed")); \ ++ return err; \ ++ } \ ++ key = (char_u *) PyString_AsString(keyObject); ++ #define DICTKEY_UNREF ++ #define DICTKEY_DECL ++ + /* + * Include the code shared with if_python3.c + */ +*************** +*** 451,456 **** +--- 556,563 ---- + static PyInt RangeStart; + static PyInt RangeEnd; + ++ static PyObject *globals; ++ + static void PythonIO_Flush(void); + static int PythonIO_Init(void); + static int PythonMod_Init(void); +*************** +*** 466,473 **** + * 1. Python interpreter main program. + */ + +- static int initialised = 0; +- + #if PYTHON_API_VERSION < 1007 /* Python 1.4 */ + typedef PyObject PyThreadState; + #endif +--- 573,578 ---- +*************** +*** 581,586 **** +--- 686,693 ---- + if (PythonMod_Init()) + goto fail; + ++ globals = PyModule_GetDict(PyImport_AddModule("__main__")); ++ + /* Remove the element from sys.path that was added because of our + * argv[0] value in PythonMod_Init(). Previously we used an empty + * string, but dependinding on the OS we then get an empty entry or +*************** +*** 609,615 **** + * External interface + */ + static void +! DoPythonCommand(exarg_T *eap, const char *cmd) + { + #ifndef PY_CAN_RECURSE + static int recursive = 0; +--- 716,722 ---- + * External interface + */ + static void +! DoPythonCommand(exarg_T *eap, const char *cmd, typval_T *rettv) + { + #ifndef PY_CAN_RECURSE + static int recursive = 0; +*************** +*** 639,646 **** + if (Python_Init()) + goto theend; + +! RangeStart = eap->line1; +! RangeEnd = eap->line2; + Python_Release_Vim(); /* leave vim */ + + #if defined(HAVE_LOCALE_H) || defined(X_LOCALE) +--- 746,761 ---- + if (Python_Init()) + goto theend; + +! if (rettv == NULL) +! { +! RangeStart = eap->line1; +! RangeEnd = eap->line2; +! } +! else +! { +! RangeStart = (PyInt) curwin->w_cursor.lnum; +! RangeEnd = RangeStart; +! } + Python_Release_Vim(); /* leave vim */ + + #if defined(HAVE_LOCALE_H) || defined(X_LOCALE) +*************** +*** 658,664 **** + + Python_RestoreThread(); /* enter python */ + +! PyRun_SimpleString((char *)(cmd)); + + Python_SaveThread(); /* leave python */ + +--- 773,795 ---- + + Python_RestoreThread(); /* enter python */ + +! if (rettv == NULL) +! PyRun_SimpleString((char *)(cmd)); +! else +! { +! PyObject *r; +! +! r = PyRun_String((char *)(cmd), Py_eval_input, globals, globals); +! if (r == NULL) +! EMSG(_("E858: Eval did not return a valid python object")); +! else +! { +! if (ConvertFromPyObject(r, rettv) == -1) +! EMSG(_("E859: Failed to convert returned python object to vim value")); +! Py_DECREF(r); +! } +! PyErr_Clear(); +! } + + Python_SaveThread(); /* leave python */ + +*************** +*** 680,686 **** + #ifndef PY_CAN_RECURSE + --recursive; + #endif +! return; /* keeps lint happy */ + } + + /* +--- 811,817 ---- + #ifndef PY_CAN_RECURSE + --recursive; + #endif +! return; + } + + /* +*************** +*** 695,703 **** + if (!eap->skip) + { + if (script == NULL) +! DoPythonCommand(eap, (char *)eap->arg); + else +! DoPythonCommand(eap, (char *)script); + } + vim_free(script); + } +--- 826,834 ---- + if (!eap->skip) + { + if (script == NULL) +! DoPythonCommand(eap, (char *)eap->arg, NULL); + else +! DoPythonCommand(eap, (char *)script, NULL); + } + vim_free(script); + } +*************** +*** 743,749 **** + *p++ = '\0'; + + /* Execute the file */ +! DoPythonCommand(eap, buffer); + } + + /****************************************************** +--- 874,880 ---- + *p++ = '\0'; + + /* Execute the file */ +! DoPythonCommand(eap, buffer, NULL); + } + + /****************************************************** +*************** +*** 765,778 **** + static int + OutputSetattr(PyObject *self, char *name, PyObject *val) + { +! if (val == NULL) { + PyErr_SetString(PyExc_AttributeError, _("can't delete OutputObject attributes")); + return -1; + } + + if (strcmp(name, "softspace") == 0) + { +! if (!PyInt_Check(val)) { + PyErr_SetString(PyExc_TypeError, _("softspace must be an integer")); + return -1; + } +--- 896,911 ---- + static int + OutputSetattr(PyObject *self, char *name, PyObject *val) + { +! if (val == NULL) +! { + PyErr_SetString(PyExc_AttributeError, _("can't delete OutputObject attributes")); + return -1; + } + + if (strcmp(name, "softspace") == 0) + { +! if (!PyInt_Check(val)) +! { + PyErr_SetString(PyExc_TypeError, _("softspace must be an integer")); + return -1; + } +*************** +*** 800,805 **** +--- 933,941 ---- + * 3. Implementation of the Vim module for Python + */ + ++ static PyObject *ConvertToPyObject(typval_T *); ++ static int ConvertFromPyObject(PyObject *, typval_T *); ++ + /* Window type - Implementation functions + * -------------------------------------- + */ +*************** +*** 1441,1446 **** +--- 1577,1748 ---- + return result; + } + ++ static void DictionaryDestructor(PyObject *); ++ static PyObject *DictionaryGetattr(PyObject *, char*); ++ ++ static PyMappingMethods DictionaryAsMapping = { ++ (PyInquiry) DictionaryLength, ++ (binaryfunc) DictionaryItem, ++ (objobjargproc) DictionaryAssItem, ++ }; ++ ++ static PyTypeObject DictionaryType = { ++ PyObject_HEAD_INIT(0) ++ 0, ++ "vimdictionary", ++ sizeof(DictionaryObject), ++ 0, ++ ++ (destructor) DictionaryDestructor, ++ (printfunc) 0, ++ (getattrfunc) DictionaryGetattr, ++ (setattrfunc) 0, ++ (cmpfunc) 0, ++ (reprfunc) 0, ++ ++ 0, /* as number */ ++ 0, /* as sequence */ ++ &DictionaryAsMapping, /* as mapping */ ++ ++ (hashfunc) 0, ++ (ternaryfunc) 0, ++ (reprfunc) 0, ++ }; ++ ++ static void ++ DictionaryDestructor(PyObject *self) ++ { ++ DictionaryObject *this = ((DictionaryObject *) (self)); ++ ++ pyll_remove(&this->ref, &lastdict); ++ dict_unref(this->dict); ++ ++ Py_DECREF(self); ++ } ++ ++ static PyObject * ++ DictionaryGetattr(PyObject *self, char *name) ++ { ++ return Py_FindMethod(DictionaryMethods, self, name); ++ } ++ ++ static void ListDestructor(PyObject *); ++ static PyObject *ListGetattr(PyObject *, char *); ++ ++ static PySequenceMethods ListAsSeq = { ++ (PyInquiry) ListLength, ++ (binaryfunc) 0, ++ (PyIntArgFunc) 0, ++ (PyIntArgFunc) ListItem, ++ (PyIntIntArgFunc) ListSlice, ++ (PyIntObjArgProc) ListAssItem, ++ (PyIntIntObjArgProc) ListAssSlice, ++ (objobjproc) 0, ++ #if PY_MAJOR_VERSION >= 2 ++ (binaryfunc) ListConcatInPlace, ++ 0, ++ #endif ++ }; ++ ++ static PyTypeObject ListType = { ++ PyObject_HEAD_INIT(0) ++ 0, ++ "vimlist", ++ sizeof(ListObject), ++ 0, ++ ++ (destructor) ListDestructor, ++ (printfunc) 0, ++ (getattrfunc) ListGetattr, ++ (setattrfunc) 0, ++ (cmpfunc) 0, ++ (reprfunc) 0, ++ ++ 0, /* as number */ ++ &ListAsSeq, /* as sequence */ ++ 0, /* as mapping */ ++ ++ (hashfunc) 0, ++ (ternaryfunc) 0, ++ (reprfunc) 0, ++ }; ++ ++ static void ++ ListDestructor(PyObject *self) ++ { ++ ListObject *this = ((ListObject *) (self)); ++ ++ pyll_remove(&this->ref, &lastlist); ++ list_unref(this->list); ++ ++ Py_DECREF(self); ++ } ++ ++ static PyObject * ++ ListGetattr(PyObject *self, char *name) ++ { ++ return Py_FindMethod(ListMethods, self, name); ++ } ++ ++ static void FunctionDestructor(PyObject *); ++ static PyObject *FunctionGetattr(PyObject *, char *); ++ ++ static PyTypeObject FunctionType = { ++ PyObject_HEAD_INIT(0) ++ 0, ++ "vimfunction", ++ sizeof(FunctionObject), ++ 0, ++ ++ (destructor) FunctionDestructor, ++ (printfunc) 0, ++ (getattrfunc) FunctionGetattr, ++ (setattrfunc) 0, ++ (cmpfunc) 0, ++ (reprfunc) 0, ++ ++ 0, /* as number */ ++ 0, /* as sequence */ ++ 0, /* as mapping */ ++ ++ (hashfunc) 0, ++ (ternaryfunc) FunctionCall, ++ (reprfunc) 0, ++ }; ++ ++ static void ++ FunctionDestructor(PyObject *self) ++ { ++ FunctionObject *this = (FunctionObject *) (self); ++ ++ func_unref(this->name); ++ PyMem_Del(this->name); ++ ++ Py_DECREF(self); ++ } ++ ++ static PyObject * ++ FunctionGetattr(PyObject *self, char *name) ++ { ++ FunctionObject *this = (FunctionObject *)(self); ++ ++ if (strcmp(name, "name") == 0) ++ return PyString_FromString((char *)(this->name)); ++ else ++ return Py_FindMethod(FunctionMethods, self, name); ++ } ++ ++ void ++ do_pyeval (char_u *str, typval_T *rettv) ++ { ++ DoPythonCommand(NULL, (char *) str, rettv); ++ switch(rettv->v_type) ++ { ++ case VAR_DICT: ++rettv->vval.v_dict->dv_refcount; break; ++ case VAR_LIST: ++rettv->vval.v_list->lv_refcount; break; ++ case VAR_FUNC: func_ref(rettv->vval.v_string); break; ++ } ++ } + + /* Don't generate a prototype for the next function, it generates an error on + * newer Python versions. */ +*************** +*** 1453,1458 **** +--- 1755,1766 ---- + } + #endif /* Python 1.4 */ + ++ void ++ set_ref_in_python (int copyID) ++ { ++ set_ref_in_py(copyID); ++ } ++ + static void + init_structs(void) + { +*** ../vim-7.3.568/src/if_python3.c 2012-02-04 20:17:21.000000000 +0100 +--- src/if_python3.c 2012-06-29 11:54:10.000000000 +0200 +*************** +*** 77,83 **** + + #define PyInt Py_ssize_t + #define PyString_Check(obj) PyUnicode_Check(obj) +! #define PyString_AsBytes(obj) PyUnicode_AsEncodedString(obj, (char *)ENC_OPT, CODEC_ERROR_HANDLER); + #define PyString_FreeBytes(obj) Py_XDECREF(bytes) + #define PyString_AsString(obj) PyBytes_AsString(obj) + #define PyString_Size(obj) PyBytes_GET_SIZE(bytes) +--- 77,83 ---- + + #define PyInt Py_ssize_t + #define PyString_Check(obj) PyUnicode_Check(obj) +! #define PyString_AsBytes(obj) PyUnicode_AsEncodedString(obj, (char *)ENC_OPT, CODEC_ERROR_HANDLER) + #define PyString_FreeBytes(obj) Py_XDECREF(bytes) + #define PyString_AsString(obj) PyBytes_AsString(obj) + #define PyString_Size(obj) PyBytes_GET_SIZE(bytes) +*************** +*** 109,114 **** +--- 109,115 ---- + # undef PyArg_ParseTuple + # define PyArg_ParseTuple py3_PyArg_ParseTuple + # define PyMem_Free py3_PyMem_Free ++ # define PyMem_Malloc py3_PyMem_Malloc + # define PyDict_SetItemString py3_PyDict_SetItemString + # define PyErr_BadArgument py3_PyErr_BadArgument + # define PyErr_Clear py3_PyErr_Clear +*************** +*** 128,141 **** +--- 129,155 ---- + # define PyList_New py3_PyList_New + # define PyList_SetItem py3_PyList_SetItem + # define PyList_Size py3_PyList_Size ++ # define PySequence_Check py3_PySequence_Check ++ # define PySequence_Size py3_PySequence_Size ++ # define PySequence_GetItem py3_PySequence_GetItem ++ # define PyTuple_Size py3_PyTuple_Size ++ # define PyTuple_GetItem py3_PyTuple_GetItem + # define PySlice_GetIndicesEx py3_PySlice_GetIndicesEx + # define PyImport_ImportModule py3_PyImport_ImportModule ++ # define PyImport_AddModule py3_PyImport_AddModule + # define PyObject_Init py3__PyObject_Init + # define PyDict_New py3_PyDict_New + # define PyDict_GetItemString py3_PyDict_GetItemString ++ # define PyDict_Next py3_PyDict_Next ++ # define PyMapping_Check py3_PyMapping_Check ++ # define PyMapping_Items py3_PyMapping_Items ++ # define PyIter_Next py3_PyIter_Next ++ # define PyObject_GetIter py3_PyObject_GetIter + # define PyModule_GetDict py3_PyModule_GetDict + #undef PyRun_SimpleString + # define PyRun_SimpleString py3_PyRun_SimpleString ++ #undef PyRun_String ++ # define PyRun_String py3_PyRun_String + # define PySys_SetObject py3_PySys_SetObject + # define PySys_SetArgv py3_PySys_SetArgv + # define PyType_Type (*py3_PyType_Type) +*************** +*** 147,152 **** +--- 161,167 ---- + # define Py_Finalize py3_Py_Finalize + # define Py_IsInitialized py3_Py_IsInitialized + # define _Py_NoneStruct (*py3__Py_NoneStruct) ++ # define _PyObject_NextNotImplemented (*py3__PyObject_NextNotImplemented) + # define PyModule_AddObject py3_PyModule_AddObject + # define PyImport_AppendInittab py3_PyImport_AppendInittab + # define _PyUnicode_AsString py3__PyUnicode_AsString +*************** +*** 154,161 **** +--- 169,181 ---- + # define PyUnicode_AsEncodedString py3_PyUnicode_AsEncodedString + # undef PyBytes_AsString + # define PyBytes_AsString py3_PyBytes_AsString ++ # undef PyBytes_FromString ++ # define PyBytes_FromString py3_PyBytes_FromString ++ # define PyFloat_FromDouble py3_PyFloat_FromDouble ++ # define PyFloat_AsDouble py3_PyFloat_AsDouble + # define PyObject_GenericGetAttr py3_PyObject_GenericGetAttr + # define PySlice_Type (*py3_PySlice_Type) ++ # define PyFloat_Type (*py3_PyFloat_Type) + # define PyErr_NewException py3_PyErr_NewException + # ifdef Py_DEBUG + # define _Py_NegativeRefcount py3__Py_NegativeRefcount +*************** +*** 174,179 **** +--- 194,202 ---- + # define PyUnicode_FromString py3_PyUnicode_FromString + # undef PyUnicode_Decode + # define PyUnicode_Decode py3_PyUnicode_Decode ++ # define PyType_IsSubtype py3_PyType_IsSubtype ++ # define PyCapsule_New py3_PyCapsule_New ++ # define PyCapsule_GetPointer py3_PyCapsule_GetPointer + + # ifdef Py_DEBUG + # undef PyObject_NEW +*************** +*** 194,215 **** +--- 217,250 ---- + static int (*py3_PySys_SetObject)(char *, PyObject *); + static PyObject* (*py3_PyList_Append)(PyObject *, PyObject *); + static Py_ssize_t (*py3_PyList_Size)(PyObject *); ++ static int (*py3_PySequence_Check)(PyObject *); ++ static Py_ssize_t (*py3_PySequence_Size)(PyObject *); ++ static PyObject* (*py3_PySequence_GetItem)(PyObject *, Py_ssize_t); ++ static Py_ssize_t (*py3_PyTuple_Size)(PyObject *); ++ static PyObject* (*py3_PyTuple_GetItem)(PyObject *, Py_ssize_t); ++ static int (*py3_PyMapping_Check)(PyObject *); ++ static PyObject* (*py3_PyMapping_Items)(PyObject *); + static int (*py3_PySlice_GetIndicesEx)(PyObject *r, Py_ssize_t length, + Py_ssize_t *start, Py_ssize_t *stop, Py_ssize_t *step, Py_ssize_t *slicelength); + static PyObject* (*py3_PyErr_NoMemory)(void); + static void (*py3_Py_Finalize)(void); + static void (*py3_PyErr_SetString)(PyObject *, const char *); + static int (*py3_PyRun_SimpleString)(char *); ++ static PyObject* (*py3_PyRun_String)(char *, int, PyObject *, PyObject *); + static PyObject* (*py3_PyList_GetItem)(PyObject *, Py_ssize_t); + static PyObject* (*py3_PyImport_ImportModule)(const char *); ++ static PyObject* (*py3_PyImport_AddModule)(const char *); + static int (*py3_PyErr_BadArgument)(void); + static PyTypeObject* py3_PyType_Type; + static PyObject* (*py3_PyErr_Occurred)(void); + static PyObject* (*py3_PyModule_GetDict)(PyObject *); + static int (*py3_PyList_SetItem)(PyObject *, Py_ssize_t, PyObject *); + static PyObject* (*py3_PyDict_GetItemString)(PyObject *, const char *); ++ static int (*py3_PyDict_Next)(PyObject *, Py_ssize_t *, PyObject **, PyObject **); + static PyObject* (*py3_PyLong_FromLong)(long); + static PyObject* (*py3_PyDict_New)(void); ++ static PyObject* (*py3_PyIter_Next)(PyObject *); ++ static PyObject* (*py3_PyObject_GetIter)(PyObject *); + static PyObject* (*py3_Py_BuildValue)(char *, ...); + static int (*py3_PyType_Ready)(PyTypeObject *type); + static int (*py3_PyDict_SetItemString)(PyObject *dp, char *key, PyObject *item); +*************** +*** 224,244 **** +--- 259,287 ---- + static int (*py3_PyArg_Parse)(PyObject *, char *, ...); + static int (*py3_PyArg_ParseTuple)(PyObject *, char *, ...); + static int (*py3_PyMem_Free)(void *); ++ static void* (*py3_PyMem_Malloc)(size_t); + static int (*py3_Py_IsInitialized)(void); + static void (*py3_PyErr_Clear)(void); + static PyObject*(*py3__PyObject_Init)(PyObject *, PyTypeObject *); ++ static iternextfunc py3__PyObject_NextNotImplemented; + static PyObject* py3__Py_NoneStruct; + static int (*py3_PyModule_AddObject)(PyObject *m, const char *name, PyObject *o); + static int (*py3_PyImport_AppendInittab)(const char *name, PyObject* (*initfunc)(void)); + static char* (*py3__PyUnicode_AsString)(PyObject *unicode); + static PyObject* (*py3_PyUnicode_AsEncodedString)(PyObject *unicode, const char* encoding, const char* errors); + static char* (*py3_PyBytes_AsString)(PyObject *bytes); ++ static PyObject* (*py3_PyBytes_FromString)(char *str); ++ static PyObject* (*py3_PyFloat_FromDouble)(double num); ++ static double (*py3_PyFloat_AsDouble)(PyObject *); + static PyObject* (*py3_PyObject_GenericGetAttr)(PyObject *obj, PyObject *name); + static PyObject* (*py3_PyModule_Create2)(struct PyModuleDef* module, int module_api_version); + static PyObject* (*py3_PyType_GenericAlloc)(PyTypeObject *type, Py_ssize_t nitems); + static PyObject* (*py3_PyType_GenericNew)(PyTypeObject *type, PyObject *args, PyObject *kwds); + static PyTypeObject* py3_PySlice_Type; ++ static PyTypeObject* py3_PyFloat_Type; + static PyObject* (*py3_PyErr_NewException)(char *name, PyObject *base, PyObject *dict); ++ static PyObject* (*py3_PyCapsule_New)(void *, char *, PyCapsule_Destructor); ++ static void* (*py3_PyCapsule_GetPointer)(PyObject *, char *); + # ifdef Py_DEBUG + static void (*py3__Py_NegativeRefcount)(const char *fname, int lineno, PyObject *op); + static Py_ssize_t* py3__Py_RefTotal; +*************** +*** 249,254 **** +--- 292,298 ---- + static void (*py3_PyObject_Free)(void*); + static void* (*py3_PyObject_Malloc)(size_t); + # endif ++ static int (*py3_PyType_IsSubtype)(PyTypeObject *, PyTypeObject *); + + static HINSTANCE hinstPy3 = 0; /* Instance of python.dll */ + +*************** +*** 280,304 **** +--- 324,361 ---- + {"Py_Initialize", (PYTHON_PROC*)&py3_Py_Initialize}, + {"PyArg_ParseTuple", (PYTHON_PROC*)&py3_PyArg_ParseTuple}, + {"PyMem_Free", (PYTHON_PROC*)&py3_PyMem_Free}, ++ {"PyMem_Malloc", (PYTHON_PROC*)&py3_PyMem_Malloc}, + {"PyList_New", (PYTHON_PROC*)&py3_PyList_New}, + {"PyGILState_Ensure", (PYTHON_PROC*)&py3_PyGILState_Ensure}, + {"PyGILState_Release", (PYTHON_PROC*)&py3_PyGILState_Release}, + {"PySys_SetObject", (PYTHON_PROC*)&py3_PySys_SetObject}, + {"PyList_Append", (PYTHON_PROC*)&py3_PyList_Append}, + {"PyList_Size", (PYTHON_PROC*)&py3_PyList_Size}, ++ {"PySequence_Check", (PYTHON_PROC*)&py3_PySequence_Check}, ++ {"PySequence_Size", (PYTHON_PROC*)&py3_PySequence_Size}, ++ {"PySequence_GetItem", (PYTHON_PROC*)&py3_PySequence_GetItem}, ++ {"PyTuple_Size", (PYTHON_PROC*)&py3_PyTuple_Size}, ++ {"PyTuple_GetItem", (PYTHON_PROC*)&py3_PyTuple_GetItem}, + {"PySlice_GetIndicesEx", (PYTHON_PROC*)&py3_PySlice_GetIndicesEx}, + {"PyErr_NoMemory", (PYTHON_PROC*)&py3_PyErr_NoMemory}, + {"Py_Finalize", (PYTHON_PROC*)&py3_Py_Finalize}, + {"PyErr_SetString", (PYTHON_PROC*)&py3_PyErr_SetString}, + {"PyRun_SimpleString", (PYTHON_PROC*)&py3_PyRun_SimpleString}, ++ {"PyRun_String", (PYTHON_PROC*)&py3_PyRun_String}, + {"PyList_GetItem", (PYTHON_PROC*)&py3_PyList_GetItem}, + {"PyImport_ImportModule", (PYTHON_PROC*)&py3_PyImport_ImportModule}, ++ {"PyImport_AddModule", (PYTHON_PROC*)&py3_PyImport_AddModule}, + {"PyErr_BadArgument", (PYTHON_PROC*)&py3_PyErr_BadArgument}, + {"PyType_Type", (PYTHON_PROC*)&py3_PyType_Type}, + {"PyErr_Occurred", (PYTHON_PROC*)&py3_PyErr_Occurred}, + {"PyModule_GetDict", (PYTHON_PROC*)&py3_PyModule_GetDict}, + {"PyList_SetItem", (PYTHON_PROC*)&py3_PyList_SetItem}, + {"PyDict_GetItemString", (PYTHON_PROC*)&py3_PyDict_GetItemString}, ++ {"PyDict_Next", (PYTHON_PROC*)&py3_PyDict_Next}, ++ {"PyMapping_Check", (PYTHON_PROC*)&py3_PyMapping_Check}, ++ {"PyMapping_Items", (PYTHON_PROC*)&py3_PyMapping_Items}, ++ {"PyIter_Next", (PYTHON_PROC*)&py3_PyIter_Next}, ++ {"PyObject_GetIter", (PYTHON_PROC*)&py3_PyObject_GetIter}, + {"PyLong_FromLong", (PYTHON_PROC*)&py3_PyLong_FromLong}, + {"PyDict_New", (PYTHON_PROC*)&py3_PyDict_New}, + {"Py_BuildValue", (PYTHON_PROC*)&py3_Py_BuildValue}, +*************** +*** 311,316 **** +--- 368,374 ---- + {"PyEval_SaveThread", (PYTHON_PROC*)&py3_PyEval_SaveThread}, + {"PyArg_Parse", (PYTHON_PROC*)&py3_PyArg_Parse}, + {"Py_IsInitialized", (PYTHON_PROC*)&py3_Py_IsInitialized}, ++ {"_PyObject_NextNotImplemented", (PYTHON_PROC*)&py3__PyObject_NextNotImplemented}, + {"_Py_NoneStruct", (PYTHON_PROC*)&py3__Py_NoneStruct}, + {"PyErr_Clear", (PYTHON_PROC*)&py3_PyErr_Clear}, + {"PyObject_Init", (PYTHON_PROC*)&py3__PyObject_Init}, +*************** +*** 318,328 **** +--- 376,390 ---- + {"PyImport_AppendInittab", (PYTHON_PROC*)&py3_PyImport_AppendInittab}, + {"_PyUnicode_AsString", (PYTHON_PROC*)&py3__PyUnicode_AsString}, + {"PyBytes_AsString", (PYTHON_PROC*)&py3_PyBytes_AsString}, ++ {"PyBytes_FromString", (PYTHON_PROC*)&py3_PyBytes_FromString}, ++ {"PyFloat_FromDouble", (PYTHON_PROC*)&py3_PyFloat_FromDouble}, ++ {"PyFloat_AsDouble", (PYTHON_PROC*)&py3_PyFloat_AsDouble}, + {"PyObject_GenericGetAttr", (PYTHON_PROC*)&py3_PyObject_GenericGetAttr}, + {"PyModule_Create2", (PYTHON_PROC*)&py3_PyModule_Create2}, + {"PyType_GenericAlloc", (PYTHON_PROC*)&py3_PyType_GenericAlloc}, + {"PyType_GenericNew", (PYTHON_PROC*)&py3_PyType_GenericNew}, + {"PySlice_Type", (PYTHON_PROC*)&py3_PySlice_Type}, ++ {"PyFloat_Type", (PYTHON_PROC*)&py3_PyFloat_Type}, + {"PyErr_NewException", (PYTHON_PROC*)&py3_PyErr_NewException}, + # ifdef Py_DEBUG + {"_Py_NegativeRefcount", (PYTHON_PROC*)&py3__Py_NegativeRefcount}, +*************** +*** 334,339 **** +--- 396,404 ---- + {"PyObject_Malloc", (PYTHON_PROC*)&py3_PyObject_Malloc}, + {"PyObject_Free", (PYTHON_PROC*)&py3_PyObject_Free}, + # endif ++ {"PyType_IsSubtype", (PYTHON_PROC*)&py3_PyType_IsSubtype}, ++ {"PyCapsule_New", (PYTHON_PROC*)&py3_PyCapsule_New}, ++ {"PyCapsule_GetPointer", (PYTHON_PROC*)&py3_PyCapsule_GetPointer}, + {"", NULL}, + }; + +*************** +*** 472,482 **** +--- 537,577 ---- + + static PyTypeObject RangeType; + ++ static int py3initialised = 0; ++ ++ #define PYINITIALISED py3initialised ++ ++ /* Add conversion from PyInt? */ ++ #define DICTKEY_GET(err) \ ++ if (PyBytes_Check(keyObject)) \ ++ key = (char_u *) PyBytes_AsString(keyObject); \ ++ else if (PyUnicode_Check(keyObject)) \ ++ { \ ++ bytes = PyString_AsBytes(keyObject); \ ++ if (bytes == NULL) \ ++ return err; \ ++ key = (char_u *) PyBytes_AsString(bytes); \ ++ if (key == NULL) \ ++ return err; \ ++ } \ ++ else \ ++ { \ ++ PyErr_SetString(PyExc_TypeError, _("only string keys are allowed")); \ ++ return err; \ ++ } ++ #define DICTKEY_UNREF \ ++ if (bytes != NULL) \ ++ Py_XDECREF(bytes); ++ ++ #define DICTKEY_DECL PyObject *bytes = NULL; ++ + /* + * Include the code shared with if_python.c + */ + #include "if_py_both.h" + ++ #define PY3OBJ_DELETED(obj) (obj->ob_base.ob_refcnt<=0) ++ + static void + call_PyObject_Free(void *p) + { +*************** +*** 506,511 **** +--- 601,608 ---- + static Py_ssize_t RangeStart; + static Py_ssize_t RangeEnd; + ++ static PyObject *globals; ++ + static int PythonIO_Init(void); + static void PythonIO_Fini(void); + PyMODINIT_FUNC Py3Init_vim(void); +*************** +*** 514,521 **** + * 1. Python interpreter main program. + */ + +- static int py3initialised = 0; +- + static PyGILState_STATE pygilstate = PyGILState_UNLOCKED; + + void +--- 611,616 ---- +*************** +*** 593,598 **** +--- 688,695 ---- + + PyImport_AppendInittab("vim", Py3Init_vim); + ++ globals = PyModule_GetDict(PyImport_AddModule("__main__")); ++ + /* Remove the element from sys.path that was added because of our + * argv[0] value in Py3Init_vim(). Previously we used an empty + * string, but dependinding on the OS we then get an empty entry or +*************** +*** 629,635 **** + * External interface + */ + static void +! DoPy3Command(exarg_T *eap, const char *cmd) + { + #if defined(MACOS) && !defined(MACOS_X_UNIX) + GrafPtr oldPort; +--- 726,732 ---- + * External interface + */ + static void +! DoPy3Command(exarg_T *eap, const char *cmd, typval_T *rettv) + { + #if defined(MACOS) && !defined(MACOS_X_UNIX) + GrafPtr oldPort; +*************** +*** 649,656 **** + if (Python3_Init()) + goto theend; + +! RangeStart = eap->line1; +! RangeEnd = eap->line2; + Python_Release_Vim(); /* leave vim */ + + #if defined(HAVE_LOCALE_H) || defined(X_LOCALE) +--- 746,761 ---- + if (Python3_Init()) + goto theend; + +! if (rettv == NULL) +! { +! RangeStart = eap->line1; +! RangeEnd = eap->line2; +! } +! else +! { +! RangeStart = (PyInt) curwin->w_cursor.lnum; +! RangeEnd = RangeStart; +! } + Python_Release_Vim(); /* leave vim */ + + #if defined(HAVE_LOCALE_H) || defined(X_LOCALE) +*************** +*** 674,680 **** + (char *)ENC_OPT, CODEC_ERROR_HANDLER); + cmdbytes = PyUnicode_AsEncodedString(cmdstr, "utf-8", CODEC_ERROR_HANDLER); + Py_XDECREF(cmdstr); +! PyRun_SimpleString(PyBytes_AsString(cmdbytes)); + Py_XDECREF(cmdbytes); + + PyGILState_Release(pygilstate); +--- 779,802 ---- + (char *)ENC_OPT, CODEC_ERROR_HANDLER); + cmdbytes = PyUnicode_AsEncodedString(cmdstr, "utf-8", CODEC_ERROR_HANDLER); + Py_XDECREF(cmdstr); +! if (rettv == NULL) +! PyRun_SimpleString(PyBytes_AsString(cmdbytes)); +! else +! { +! PyObject *r; +! +! r = PyRun_String(PyBytes_AsString(cmdbytes), Py_eval_input, +! globals, globals); +! if (r == NULL) +! EMSG(_("E860: Eval did not return a valid python 3 object")); +! else +! { +! if (ConvertFromPyObject(r, rettv) == -1) +! EMSG(_("E861: Failed to convert returned python 3 object to vim value")); +! Py_DECREF(r); +! } +! PyErr_Clear(); +! } + Py_XDECREF(cmdbytes); + + PyGILState_Release(pygilstate); +*************** +*** 709,717 **** + if (!eap->skip) + { + if (script == NULL) +! DoPy3Command(eap, (char *)eap->arg); + else +! DoPy3Command(eap, (char *)script); + } + vim_free(script); + } +--- 831,839 ---- + if (!eap->skip) + { + if (script == NULL) +! DoPy3Command(eap, (char *)eap->arg, NULL); + else +! DoPy3Command(eap, (char *)script, NULL); + } + vim_free(script); + } +*************** +*** 772,778 **** + + + /* Execute the file */ +! DoPy3Command(eap, buffer); + } + + /****************************************************** +--- 894,900 ---- + + + /* Execute the file */ +! DoPy3Command(eap, buffer, NULL); + } + + /****************************************************** +*************** +*** 802,815 **** + if (PyUnicode_Check(nameobj)) + name = _PyUnicode_AsString(nameobj); + +! if (val == NULL) { + PyErr_SetString(PyExc_AttributeError, _("can't delete OutputObject attributes")); + return -1; + } + + if (strcmp(name, "softspace") == 0) + { +! if (!PyLong_Check(val)) { + PyErr_SetString(PyExc_TypeError, _("softspace must be an integer")); + return -1; + } +--- 924,939 ---- + if (PyUnicode_Check(nameobj)) + name = _PyUnicode_AsString(nameobj); + +! if (val == NULL) +! { + PyErr_SetString(PyExc_AttributeError, _("can't delete OutputObject attributes")); + return -1; + } + + if (strcmp(name, "softspace") == 0) + { +! if (!PyLong_Check(val)) +! { + PyErr_SetString(PyExc_TypeError, _("softspace must be an integer")); + return -1; + } +*************** +*** 1030,1049 **** + static PyObject * + BufferSubscript(PyObject *self, PyObject* idx) + { +! if (PyLong_Check(idx)) { + long _idx = PyLong_AsLong(idx); + return BufferItem(self,_idx); +! } else if (PySlice_Check(idx)) { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count+1, + &start, &stop, +! &step, &slicelen) < 0) { + return NULL; + } + return BufferSlice(self, start, stop); +! } else { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return NULL; + } +--- 1154,1178 ---- + static PyObject * + BufferSubscript(PyObject *self, PyObject* idx) + { +! if (PyLong_Check(idx)) +! { + long _idx = PyLong_AsLong(idx); + return BufferItem(self,_idx); +! } else if (PySlice_Check(idx)) +! { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count+1, + &start, &stop, +! &step, &slicelen) < 0) +! { + return NULL; + } + return BufferSlice(self, start, stop); +! } +! else +! { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return NULL; + } +*************** +*** 1052,1075 **** + static Py_ssize_t + BufferAsSubscript(PyObject *self, PyObject* idx, PyObject* val) + { +! if (PyLong_Check(idx)) { + long n = PyLong_AsLong(idx); + return RBAsItem((BufferObject *)(self), n, val, 1, + (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count, + NULL); +! } else if (PySlice_Check(idx)) { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count+1, + &start, &stop, +! &step, &slicelen) < 0) { + return -1; + } + return RBAsSlice((BufferObject *)(self), start, stop, val, 1, + (PyInt)((BufferObject *)(self))->buf->b_ml.ml_line_count, + NULL); +! } else { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return -1; + } +--- 1181,1209 ---- + static Py_ssize_t + BufferAsSubscript(PyObject *self, PyObject* idx, PyObject* val) + { +! if (PyLong_Check(idx)) +! { + long n = PyLong_AsLong(idx); + return RBAsItem((BufferObject *)(self), n, val, 1, + (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count, + NULL); +! } else if (PySlice_Check(idx)) +! { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count+1, + &start, &stop, +! &step, &slicelen) < 0) +! { + return -1; + } + return RBAsSlice((BufferObject *)(self), start, stop, val, 1, + (PyInt)((BufferObject *)(self))->buf->b_ml.ml_line_count, + NULL); +! } +! else +! { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return -1; + } +*************** +*** 1142,1161 **** + static PyObject * + RangeSubscript(PyObject *self, PyObject* idx) + { +! if (PyLong_Check(idx)) { + long _idx = PyLong_AsLong(idx); + return RangeItem(self,_idx); +! } else if (PySlice_Check(idx)) { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + ((RangeObject *)(self))->end-((RangeObject *)(self))->start+1, + &start, &stop, +! &step, &slicelen) < 0) { + return NULL; + } + return RangeSlice(self, start, stop); +! } else { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return NULL; + } +--- 1276,1300 ---- + static PyObject * + RangeSubscript(PyObject *self, PyObject* idx) + { +! if (PyLong_Check(idx)) +! { + long _idx = PyLong_AsLong(idx); + return RangeItem(self,_idx); +! } else if (PySlice_Check(idx)) +! { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + ((RangeObject *)(self))->end-((RangeObject *)(self))->start+1, + &start, &stop, +! &step, &slicelen) < 0) +! { + return NULL; + } + return RangeSlice(self, start, stop); +! } +! else +! { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return NULL; + } +*************** +*** 1164,1183 **** + static Py_ssize_t + RangeAsSubscript(PyObject *self, PyObject *idx, PyObject *val) + { +! if (PyLong_Check(idx)) { + long n = PyLong_AsLong(idx); + return RangeAsItem(self, n, val); +! } else if (PySlice_Check(idx)) { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + ((RangeObject *)(self))->end-((RangeObject *)(self))->start+1, + &start, &stop, +! &step, &slicelen) < 0) { + return -1; + } + return RangeAsSlice(self, start, stop, val); +! } else { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return -1; + } +--- 1303,1327 ---- + static Py_ssize_t + RangeAsSubscript(PyObject *self, PyObject *idx, PyObject *val) + { +! if (PyLong_Check(idx)) +! { + long n = PyLong_AsLong(idx); + return RangeAsItem(self, n, val); +! } else if (PySlice_Check(idx)) +! { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + ((RangeObject *)(self))->end-((RangeObject *)(self))->start+1, + &start, &stop, +! &step, &slicelen) < 0) +! { + return -1; + } + return RangeAsSlice(self, start, stop, val); +! } +! else +! { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return -1; + } +*************** +*** 1390,1395 **** +--- 1534,1680 ---- + } + } + ++ /* Dictionary object - Definitions ++ */ ++ ++ static PyInt DictionaryLength(PyObject *); ++ ++ static PyMappingMethods DictionaryAsMapping = { ++ /* mp_length */ (lenfunc) DictionaryLength, ++ /* mp_subscript */ (binaryfunc) DictionaryItem, ++ /* mp_ass_subscript */ (objobjargproc) DictionaryAssItem, ++ }; ++ ++ static PyTypeObject DictionaryType; ++ ++ static void ++ DictionaryDestructor(PyObject *self) ++ { ++ DictionaryObject *this = (DictionaryObject *)(self); ++ ++ pyll_remove(&this->ref, &lastdict); ++ dict_unref(this->dict); ++ ++ Py_TYPE(self)->tp_free((PyObject*)self); ++ } ++ ++ /* List object - Definitions ++ */ ++ ++ static PyInt ListLength(PyObject *); ++ static PyObject *ListItem(PyObject *, Py_ssize_t); ++ ++ static PySequenceMethods ListAsSeq = { ++ (lenfunc) ListLength, /* sq_length, len(x) */ ++ (binaryfunc) 0, /* RangeConcat, sq_concat, x+y */ ++ (ssizeargfunc) 0, /* RangeRepeat, sq_repeat, x*n */ ++ (ssizeargfunc) ListItem, /* sq_item, x[i] */ ++ (void *) 0, /* was_sq_slice, x[i:j] */ ++ (ssizeobjargproc) ListAssItem, /* sq_as_item, x[i]=v */ ++ (void *) 0, /* was_sq_ass_slice, x[i:j]=v */ ++ 0, /* sq_contains */ ++ (binaryfunc) ListConcatInPlace,/* sq_inplace_concat */ ++ 0, /* sq_inplace_repeat */ ++ }; ++ ++ static PyObject *ListSubscript(PyObject *, PyObject *); ++ static Py_ssize_t ListAsSubscript(PyObject *, PyObject *, PyObject *); ++ ++ static PyMappingMethods ListAsMapping = { ++ /* mp_length */ (lenfunc) ListLength, ++ /* mp_subscript */ (binaryfunc) ListSubscript, ++ /* mp_ass_subscript */ (objobjargproc) ListAsSubscript, ++ }; ++ ++ static PyTypeObject ListType; ++ ++ static PyObject * ++ ListSubscript(PyObject *self, PyObject* idxObject) ++ { ++ if (PyLong_Check(idxObject)) ++ { ++ long idx = PyLong_AsLong(idxObject); ++ return ListItem(self, idx); ++ } ++ else if (PySlice_Check(idxObject)) ++ { ++ Py_ssize_t start, stop, step, slicelen; ++ ++ if (PySlice_GetIndicesEx(idxObject, ListLength(self), &start, &stop, ++ &step, &slicelen) < 0) ++ return NULL; ++ return ListSlice(self, start, stop); ++ } ++ else ++ { ++ PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); ++ return NULL; ++ } ++ } ++ ++ static Py_ssize_t ++ ListAsSubscript(PyObject *self, PyObject *idxObject, PyObject *obj) ++ { ++ if (PyLong_Check(idxObject)) ++ { ++ long idx = PyLong_AsLong(idxObject); ++ return ListAssItem(self, idx, obj); ++ } ++ else if (PySlice_Check(idxObject)) ++ { ++ Py_ssize_t start, stop, step, slicelen; ++ ++ if (PySlice_GetIndicesEx(idxObject, ListLength(self), &start, &stop, ++ &step, &slicelen) < 0) ++ return -1; ++ return ListAssSlice(self, start, stop, obj); ++ } ++ else ++ { ++ PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); ++ return -1; ++ } ++ } ++ ++ static void ++ ListDestructor(PyObject *self) ++ { ++ ListObject *this = (ListObject *)(self); ++ ++ pyll_remove(&this->ref, &lastlist); ++ list_unref(this->list); ++ ++ Py_TYPE(self)->tp_free((PyObject*)self); ++ } ++ ++ /* Function object - Definitions ++ */ ++ ++ static void ++ FunctionDestructor(PyObject *self) ++ { ++ FunctionObject *this = (FunctionObject *) (self); ++ ++ func_unref(this->name); ++ PyMem_Del(this->name); ++ ++ Py_TYPE(self)->tp_free((PyObject*)self); ++ } ++ ++ static PyObject * ++ FunctionGetattro(PyObject *self, PyObject *nameobj) ++ { ++ FunctionObject *this = (FunctionObject *)(self); ++ char *name = ""; ++ if (PyUnicode_Check(nameobj)) ++ name = _PyUnicode_AsString(nameobj); ++ ++ if (strcmp(name, "name") == 0) ++ return PyUnicode_FromString((char *)(this->name)); ++ ++ return PyObject_GenericGetAttr(self, nameobj); ++ } ++ + /* External interface + */ + +*************** +*** 1449,1454 **** +--- 1734,1742 ---- + PyType_Ready(&BufListType); + PyType_Ready(&WinListType); + PyType_Ready(&CurrentType); ++ PyType_Ready(&DictionaryType); ++ PyType_Ready(&ListType); ++ PyType_Ready(&FunctionType); + + /* Set sys.argv[] to avoid a crash in warn(). */ + PySys_SetArgv(1, argv); +*************** +*** 1517,1522 **** +--- 1805,1828 ---- + return result; + } + ++ void ++ do_py3eval (char_u *str, typval_T *rettv) ++ { ++ DoPy3Command(NULL, (char *) str, rettv); ++ switch(rettv->v_type) ++ { ++ case VAR_DICT: ++rettv->vval.v_dict->dv_refcount; break; ++ case VAR_LIST: ++rettv->vval.v_list->lv_refcount; break; ++ case VAR_FUNC: func_ref(rettv->vval.v_string); break; ++ } ++ } ++ ++ void ++ set_ref_in_python3 (int copyID) ++ { ++ set_ref_in_py(copyID); ++ } ++ + static void + init_structs(void) + { +*************** +*** 1598,1603 **** +--- 1904,1938 ---- + CurrentType.tp_flags = Py_TPFLAGS_DEFAULT; + CurrentType.tp_doc = "vim current object"; + ++ vim_memset(&DictionaryType, 0, sizeof(DictionaryType)); ++ DictionaryType.tp_name = "vim.dictionary"; ++ DictionaryType.tp_basicsize = sizeof(DictionaryObject); ++ DictionaryType.tp_dealloc = DictionaryDestructor; ++ DictionaryType.tp_as_mapping = &DictionaryAsMapping; ++ DictionaryType.tp_flags = Py_TPFLAGS_DEFAULT; ++ DictionaryType.tp_doc = "dictionary pushing modifications to vim structure"; ++ DictionaryType.tp_methods = DictionaryMethods; ++ ++ vim_memset(&ListType, 0, sizeof(ListType)); ++ ListType.tp_name = "vim.list"; ++ ListType.tp_dealloc = ListDestructor; ++ ListType.tp_basicsize = sizeof(ListObject); ++ ListType.tp_as_sequence = &ListAsSeq; ++ ListType.tp_as_mapping = &ListAsMapping; ++ ListType.tp_flags = Py_TPFLAGS_DEFAULT; ++ ListType.tp_doc = "list pushing modifications to vim structure"; ++ ListType.tp_methods = ListMethods; ++ ++ vim_memset(&FunctionType, 0, sizeof(FunctionType)); ++ FunctionType.tp_name = "vim.list"; ++ FunctionType.tp_basicsize = sizeof(FunctionObject); ++ FunctionType.tp_getattro = FunctionGetattro; ++ FunctionType.tp_dealloc = FunctionDestructor; ++ FunctionType.tp_call = FunctionCall; ++ FunctionType.tp_flags = Py_TPFLAGS_DEFAULT; ++ FunctionType.tp_doc = "object that calls vim function"; ++ FunctionType.tp_methods = FunctionMethods; ++ + vim_memset(&vimmodule, 0, sizeof(vimmodule)); + vimmodule.m_name = "vim"; + vimmodule.m_doc = vim_module_doc; +*** ../vim-7.3.568/src/proto/eval.pro 2011-09-14 16:52:02.000000000 +0200 +--- src/proto/eval.pro 2012-06-20 18:20:28.000000000 +0200 +*************** +*** 46,57 **** +--- 46,66 ---- + list_T *list_alloc __ARGS((void)); + void list_unref __ARGS((list_T *l)); + void list_free __ARGS((list_T *l, int recurse)); ++ listitem_T *listitem_alloc __ARGS((void)); ++ void listitem_remove __ARGS((list_T *l, listitem_T *item)); + dictitem_T *dict_lookup __ARGS((hashitem_T *hi)); ++ listitem_T *list_find __ARGS((list_T *l, long n)); + char_u *list_find_str __ARGS((list_T *l, long idx)); ++ void list_append __ARGS((list_T *l, listitem_T *item)); + int list_append_tv __ARGS((list_T *l, typval_T *tv)); + int list_append_dict __ARGS((list_T *list, dict_T *dict)); + int list_append_string __ARGS((list_T *l, char_u *str, int len)); ++ int list_insert_tv __ARGS((list_T *l, typval_T *tv, listitem_T *item)); ++ void list_remove __ARGS((list_T *l, listitem_T *item, listitem_T *item2)); + int garbage_collect __ARGS((void)); ++ void set_ref_in_ht __ARGS((hashtab_T *ht, int copyID)); ++ void set_ref_in_list __ARGS((list_T *l, int copyID)); ++ void set_ref_in_item __ARGS((typval_T *tv, int copyID)); + dict_T *dict_alloc __ARGS((void)); + void dict_unref __ARGS((dict_T *d)); + dictitem_T *dictitem_alloc __ARGS((char_u *key)); +*************** +*** 64,69 **** +--- 73,79 ---- + long get_dict_number __ARGS((dict_T *d, char_u *key)); + char_u *get_function_name __ARGS((expand_T *xp, int idx)); + char_u *get_expr_name __ARGS((expand_T *xp, int idx)); ++ int func_call __ARGS((char_u *name, typval_T *args, dict_T *selfdict, typval_T *rettv)); + long do_searchpair __ARGS((char_u *spat, char_u *mpat, char_u *epat, int dir, char_u *skip, int flags, pos_T *match_pos, linenr_T lnum_stop, long time_limit)); + void set_vim_var_nr __ARGS((int idx, long val)); + long get_vim_var_nr __ARGS((int idx)); +*************** +*** 94,99 **** +--- 104,111 ---- + void func_dump_profile __ARGS((FILE *fd)); + char_u *get_user_func_name __ARGS((expand_T *xp, int idx)); + void ex_delfunction __ARGS((exarg_T *eap)); ++ void func_unref __ARGS((char_u *name)); ++ void func_ref __ARGS((char_u *name)); + void ex_return __ARGS((exarg_T *eap)); + int do_return __ARGS((exarg_T *eap, int reanimate, int is_cmd, void *rettv)); + void discard_pending_return __ARGS((void *rettv)); +*** ../vim-7.3.568/src/proto/if_python.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/if_python.pro 2012-06-20 18:23:06.000000000 +0200 +*************** +*** 6,9 **** +--- 6,11 ---- + void ex_pyfile __ARGS((exarg_T *eap)); + void python_buffer_free __ARGS((buf_T *buf)); + void python_window_free __ARGS((win_T *win)); ++ void do_pyeval __ARGS((char_u *str, typval_T *rettv)); ++ void set_ref_in_python __ARGS((int copyID)); + /* vim: set ft=c : */ +*** ../vim-7.3.568/src/proto/if_python3.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/if_python3.pro 2012-06-20 18:34:26.000000000 +0200 +*************** +*** 6,9 **** +--- 6,11 ---- + void ex_py3file __ARGS((exarg_T *eap)); + void python3_buffer_free __ARGS((buf_T *buf)); + void python3_window_free __ARGS((win_T *win)); ++ void do_py3eval __ARGS((char_u *str, typval_T *rettv)); ++ void set_ref_in_python3 __ARGS((int copyID)); + /* vim: set ft=c : */ +*** ../vim-7.3.568/src/testdir/Make_amiga.mak 2012-04-05 16:56:38.000000000 +0200 +--- src/testdir/Make_amiga.mak 2012-06-20 18:43:05.000000000 +0200 +*************** +*** 14,19 **** +--- 14,20 ---- + # test27 can't edit file with "*" + # test52 only for Win32 + # test85 no Lua interface ++ # test86, 87 no Python interface + + SCRIPTS = test1.out test3.out test4.out test5.out test6.out \ + test7.out test8.out test9.out \ +*** ../vim-7.3.568/src/testdir/Make_dos.mak 2012-04-13 19:11:16.000000000 +0200 +--- src/testdir/Make_dos.mak 2012-06-20 18:43:45.000000000 +0200 +*************** +*** 30,36 **** + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out + + SCRIPTS32 = test50.out test70.out + +--- 30,36 ---- + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.568/src/testdir/Make_ming.mak 2012-04-13 19:11:16.000000000 +0200 +--- src/testdir/Make_ming.mak 2012-06-20 18:44:12.000000000 +0200 +*************** +*** 50,56 **** + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out + + SCRIPTS32 = test50.out test70.out + +--- 50,56 ---- + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.568/src/testdir/Make_os2.mak 2012-04-05 16:56:38.000000000 +0200 +--- src/testdir/Make_os2.mak 2012-06-20 18:44:32.000000000 +0200 +*************** +*** 14,19 **** +--- 14,20 ---- + # test27 can't edit file with "*" in file name + # test52 only for Win32 + # test85 no Lua interface ++ # test86, 87 no Python interface + + SCRIPTS = test1.out test3.out test4.out test5.out test6.out \ + test7.out test8.out test9.out \ +*** ../vim-7.3.568/src/testdir/Makefile 2012-04-05 16:56:38.000000000 +0200 +--- src/testdir/Makefile 2012-06-29 11:56:00.000000000 +0200 +*************** +*** 27,33 **** + test69.out test70.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out + + SCRIPTS_GUI = test16.out + +--- 27,33 ---- + test69.out test70.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out + + SCRIPTS_GUI = test16.out + +*** ../vim-7.3.568/src/testdir/test86.in 2012-06-20 20:19:31.000000000 +0200 +--- src/testdir/test86.in 2012-06-20 18:01:02.000000000 +0200 +*************** +*** 0 **** +--- 1,211 ---- ++ Tests for various python features. vim: set ft=vim : ++ ++ STARTTEST ++ :so small.vim ++ :if !has('python') | e! test.ok | wq! test.out | endif ++ :py import vim ++ :fun Test() ++ :let l = [] ++ :py l=vim.bindeval('l') ++ :py f=vim.bindeval('function("strlen")') ++ :" Extending List directly with different types ++ :py l.extend([1, "as'd", [1, 2, f, {'a': 1}]]) ++ :$put =string(l) ++ :$put =string(l[-1]) ++ :try ++ : $put =string(l[-4]) ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :" List assignment ++ :py l[0]=0 ++ :$put =string(l) ++ :py l[-2]=f ++ :$put =string(l) ++ :" ++ :" Extending Dictionary directly with different types ++ :let d = {} ++ :py d=vim.bindeval('d') ++ :py d['1']='asd' ++ :py d['b']=[1, 2, f] ++ :py d['-1']={'a': 1} ++ :let dkeys = [] ++ :py dk=vim.bindeval('dkeys') ++ :py dkeys=d.keys() ++ :py dkeys.sort() ++ :py dk.extend(dkeys) ++ :$put =string(dkeys) ++ :for [key, val] in sort(items(d)) ++ : $put =string(key) . ' : ' . string(val) ++ : unlet key val ++ :endfor ++ :" ++ :" removing items with del ++ :py del l[2] ++ :$put =string(l) ++ :let l = range(8) ++ :py l=vim.bindeval('l') ++ :try ++ : py del l[:3] ++ : py del l[1:] ++ :catch ++ : $put =v:exception ++ :endtry ++ :$put =string(l) ++ :" ++ :py del d['-1'] ++ :$put =string(d) ++ :" ++ :" removing items out of range: silently skip items that don't exist ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :" The following two ranges delete nothing as they match empty list: ++ :py del l[2:1] ++ :$put =string(l) ++ :py del l[2:2] ++ :$put =string(l) ++ :py del l[2:3] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py del l[2:4] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py del l[2:5] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py del l[2:6] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :" The following two ranges delete nothing as they match empty list: ++ :py del l[-1:2] ++ :$put =string(l) ++ :py del l[-2:2] ++ :$put =string(l) ++ :py del l[-3:2] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py del l[-4:2] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py del l[-5:2] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py del l[-6:2] ++ :$put =string(l) ++ :" ++ :" Slice assignment to a list ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py l[0:0]=['a'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py l[1:2]=['b'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py l[2:4]=['c'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py l[4:4]=['d'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py l[-1:2]=['e'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py l[-10:2]=['f'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py l[2:-10]=['g'] ++ :$put =string(l) ++ :let l = [] ++ :py l=vim.bindeval('l') ++ :py l[0:0]=['h'] ++ :$put =string(l) ++ :" ++ :" Locked variables ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :lockvar! l ++ :py l[2]='i' ++ :$put =string(l) ++ :unlockvar! l ++ :" ++ :" Function calls ++ :function New(...) ++ :return ['NewStart']+a:000+['NewEnd'] ++ :endfunction ++ :function DictNew(...) dict ++ :return ['DictNewStart']+a:000+['DictNewEnd', self] ++ :endfunction ++ :let l=[function('New'), function('DictNew')] ++ :py l=vim.bindeval('l') ++ :py l.extend(list(l[0](1, 2, 3))) ++ :$put =string(l) ++ :py l.extend(list(l[1](1, 2, 3, self={'a': 'b'}))) ++ :$put =string(l) ++ :py l.extend([l[0].name]) ++ :$put =string(l) ++ :try ++ : py l[1](1, 2, 3) ++ :catch ++ : $put =v:exception[:16] ++ :endtry ++ :delfunction New ++ :try ++ : py l[0](1, 2, 3) ++ :catch ++ : $put =v:exception[:16] ++ :endtry ++ :if has('float') ++ : let l=[0.0] ++ : py l=vim.bindeval('l') ++ : py l.extend([0.0]) ++ : $put =string(l) ++ :else ++ : $put ='[0.0, 0.0]' ++ :endif ++ :" ++ :" pyeval() ++ :let l=pyeval('range(3)') ++ :$put =string(l) ++ :let d=pyeval('{"a": "b", "c": 1, "d": ["e"]}') ++ :$put =sort(items(d)) ++ :try ++ : let undef=pyeval('undefined_name') ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :try ++ : let vim=pyeval('vim') ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :if has('float') ++ : let f=pyeval('0.0') ++ : $put =string(f) ++ :else ++ : $put ='0.0' ++ :endif ++ :endfun ++ :" ++ :call Test() ++ :" ++ :delfunc Test ++ :call garbagecollect(1) ++ :" ++ :/^start:/,$wq! test.out ++ ENDTEST ++ ++ start: +*** ../vim-7.3.568/src/testdir/test86.ok 2012-06-20 20:19:31.000000000 +0200 +--- src/testdir/test86.ok 2012-06-20 18:01:02.000000000 +0200 +*************** +*** 0 **** +--- 1,47 ---- ++ start: ++ [1, 'as''d', [1, 2, function('strlen'), {'a': 1}]] ++ [1, 2, function('strlen'), {'a': 1}] ++ Vim(put):E684: ++ [0, 'as''d', [1, 2, function('strlen'), {'a': 1}]] ++ [0, function('strlen'), [1, 2, function('strlen'), {'a': 1}]] ++ ['-1', '1', 'b'] ++ '-1' : {'a': 1} ++ '1' : 'asd' ++ 'b' : [1, 2, function('strlen')] ++ [0, function('strlen')] ++ [3] ++ {'1': 'asd', 'b': [1, 2, function('strlen')]} ++ [0, 1, 2, 3] ++ [0, 1, 2, 3] ++ [0, 1, 3] ++ [0, 1] ++ [0, 1] ++ [0, 1] ++ [0, 1, 2, 3] ++ [0, 1, 2, 3] ++ [0, 2, 3] ++ [2, 3] ++ [2, 3] ++ [2, 3] ++ ['a', 0, 1, 2, 3] ++ [0, 'b', 2, 3] ++ [0, 1, 'c'] ++ [0, 1, 2, 3, 'd'] ++ [0, 1, 2, 'e', 3] ++ ['f', 2, 3] ++ [0, 1, 'g', 2, 3] ++ ['h'] ++ [0, 1, 2, 3] ++ [function('New'), function('DictNew'), 'NewStart', 1, 2, 3, 'NewEnd'] ++ [function('New'), function('DictNew'), 'NewStart', 1, 2, 3, 'NewEnd', 'DictNewStart', 1, 2, 3, 'DictNewEnd', {'a': 'b'}] ++ [function('New'), function('DictNew'), 'NewStart', 1, 2, 3, 'NewEnd', 'DictNewStart', 1, 2, 3, 'DictNewEnd', {'a': 'b'}, 'New'] ++ Vim(python):E725: ++ Vim(python):E117: ++ [0.0, 0.0] ++ [0, 1, 2] ++ ['a', 'b'] ++ ['c', 1] ++ ['d', ['e']] ++ Vim(let):E858: ++ Vim(let):E859: ++ 0.0 +*** ../vim-7.3.568/src/testdir/test87.in 2012-06-20 20:19:31.000000000 +0200 +--- src/testdir/test87.in 2012-06-20 18:01:02.000000000 +0200 +*************** +*** 0 **** +--- 1,211 ---- ++ Tests for various python features. vim: set ft=vim : ++ ++ STARTTEST ++ :so small.vim ++ :if !has('python3') | e! test.ok | wq! test.out | endif ++ :py3 import vim ++ :fun Test() ++ :let l = [] ++ :py3 l=vim.bindeval('l') ++ :py3 f=vim.bindeval('function("strlen")') ++ :" Extending List directly with different types ++ :py3 l+=[1, "as'd", [1, 2, f, {'a': 1}]] ++ :$put =string(l) ++ :$put =string(l[-1]) ++ :try ++ : $put =string(l[-4]) ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :" List assignment ++ :py3 l[0]=0 ++ :$put =string(l) ++ :py3 l[-2]=f ++ :$put =string(l) ++ :" ++ :" Extending Dictionary directly with different types ++ :let d = {} ++ :py3 d=vim.bindeval('d') ++ :py3 d['1']='asd' ++ :py3 d['b']=[1, 2, f] ++ :py3 d['-1']={'a': 1} ++ :let dkeys = [] ++ :py3 dk=vim.bindeval('dkeys') ++ :py3 dkeys=d.keys() ++ :py3 dkeys.sort() ++ :py3 dk+=dkeys ++ :$put =string(dkeys) ++ :for [key, val] in sort(items(d)) ++ : $put =string(key) . ' : ' . string(val) ++ : unlet key val ++ :endfor ++ :" ++ :" removing items with del ++ :py3 del l[2] ++ :$put =string(l) ++ :let l = range(8) ++ :py3 l=vim.bindeval('l') ++ :try ++ : py3 del l[:3] ++ : py3 del l[1:] ++ :catch ++ : $put =v:exception ++ :endtry ++ :$put =string(l) ++ :" ++ :py3 del d['-1'] ++ :$put =string(d) ++ :" ++ :" removing items out of range: silently skip items that don't exist ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :" The following two ranges delete nothing as they match empty list: ++ :py3 del l[2:1] ++ :$put =string(l) ++ :py3 del l[2:2] ++ :$put =string(l) ++ :py3 del l[2:3] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 del l[2:4] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 del l[2:5] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 del l[2:6] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :" The following two ranges delete nothing as they match empty list: ++ :py3 del l[-1:2] ++ :$put =string(l) ++ :py3 del l[-2:2] ++ :$put =string(l) ++ :py3 del l[-3:2] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 del l[-4:2] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 del l[-5:2] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 del l[-6:2] ++ :$put =string(l) ++ :" ++ :" Slice assignment to a list ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 l[0:0]=['a'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 l[1:2]=['b'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 l[2:4]=['c'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 l[4:4]=['d'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 l[-1:2]=['e'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 l[-10:2]=['f'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 l[2:-10]=['g'] ++ :$put =string(l) ++ :let l = [] ++ :py3 l=vim.bindeval('l') ++ :py3 l[0:0]=['h'] ++ :$put =string(l) ++ :" ++ :" Locked variables ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :lockvar! l ++ :py3 l[2]='i' ++ :$put =string(l) ++ :unlockvar! l ++ :" ++ :" Function calls ++ :function New(...) ++ :return ['NewStart']+a:000+['NewEnd'] ++ :endfunction ++ :function DictNew(...) dict ++ :return ['DictNewStart']+a:000+['DictNewEnd', self] ++ :endfunction ++ :let l=[function('New'), function('DictNew')] ++ :py3 l=vim.bindeval('l') ++ :py3 l.extend(list(l[0](1, 2, 3))) ++ :$put =string(l) ++ :py3 l.extend(list(l[1](1, 2, 3, self={'a': 'b'}))) ++ :$put =string(l) ++ :py3 l+=[l[0].name] ++ :$put =string(l) ++ :try ++ : py3 l[1](1, 2, 3) ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :delfunction New ++ :try ++ : py3 l[0](1, 2, 3) ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :if has('float') ++ : let l=[0.0] ++ : py3 l=vim.bindeval('l') ++ : py3 l.extend([0.0]) ++ : $put =string(l) ++ :else ++ : $put ='[0.0, 0.0]' ++ :endif ++ :" ++ :" py3eval() ++ :let l=py3eval('[0, 1, 2]') ++ :$put =string(l) ++ :let d=py3eval('{"a": "b", "c": 1, "d": ["e"]}') ++ :$put =sort(items(d)) ++ :try ++ : let undef=py3eval('undefined_name') ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :try ++ : let vim=py3eval('vim') ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :if has('float') ++ : let f=py3eval('0.0') ++ : $put =string(f) ++ :else ++ : $put ='0.0' ++ :endif ++ :endfun ++ :" ++ :call Test() ++ :" ++ :delfunc Test ++ :call garbagecollect(1) ++ :" ++ :/^start:/,$wq! test.out ++ ENDTEST ++ ++ start: +*** ../vim-7.3.568/src/testdir/test87.ok 2012-06-20 20:19:31.000000000 +0200 +--- src/testdir/test87.ok 2012-06-20 18:01:02.000000000 +0200 +*************** +*** 0 **** +--- 1,47 ---- ++ start: ++ [1, 'as''d', [1, 2, function('strlen'), {'a': 1}]] ++ [1, 2, function('strlen'), {'a': 1}] ++ Vim(put):E684: ++ [0, 'as''d', [1, 2, function('strlen'), {'a': 1}]] ++ [0, function('strlen'), [1, 2, function('strlen'), {'a': 1}]] ++ ['-1', '1', 'b'] ++ '-1' : {'a': 1} ++ '1' : 'asd' ++ 'b' : [1, 2, function('strlen')] ++ [0, function('strlen')] ++ [3] ++ {'1': 'asd', 'b': [1, 2, function('strlen')]} ++ [0, 1, 2, 3] ++ [0, 1, 2, 3] ++ [0, 1, 3] ++ [0, 1] ++ [0, 1] ++ [0, 1] ++ [0, 1, 2, 3] ++ [0, 1, 2, 3] ++ [0, 2, 3] ++ [2, 3] ++ [2, 3] ++ [2, 3] ++ ['a', 0, 1, 2, 3] ++ [0, 'b', 2, 3] ++ [0, 1, 'c'] ++ [0, 1, 2, 3, 'd'] ++ [0, 1, 2, 'e', 3] ++ ['f', 2, 3] ++ [0, 1, 'g', 2, 3] ++ ['h'] ++ [0, 1, 2, 3] ++ [function('New'), function('DictNew'), 'NewStart', 1, 2, 3, 'NewEnd'] ++ [function('New'), function('DictNew'), 'NewStart', 1, 2, 3, 'NewEnd', 'DictNewStart', 1, 2, 3, 'DictNewEnd', {'a': 'b'}] ++ [function('New'), function('DictNew'), 'NewStart', 1, 2, 3, 'NewEnd', 'DictNewStart', 1, 2, 3, 'DictNewEnd', {'a': 'b'}, 'New'] ++ Vim(py3):E725: ++ Vim(py3):E117: ++ [0.0, 0.0] ++ [0, 1, 2] ++ ['a', 'b'] ++ ['c', 1] ++ ['d', ['e']] ++ Vim(let):E860: ++ Vim(let):E861: ++ 0.0 +*** ../vim-7.3.568/src/version.c 2012-06-29 12:35:40.000000000 +0200 +--- src/version.c 2012-06-29 12:47:03.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 569, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +69. Yahoo welcomes you with your own start page + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8fc85af8b38f0ca117565926ea2cb496318746ec Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:12 +0200 Subject: [PATCH 0314/3340] - patchlevel 570 --- 7.3.570 | 145 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 145 insertions(+) create mode 100644 7.3.570 diff --git a/7.3.570 b/7.3.570 new file mode 100644 index 00000000..c644194d --- /dev/null +++ b/7.3.570 @@ -0,0 +1,145 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.570 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.570 +Problem: ":vimgrep" does not obey 'wildignore'. +Solution: Apply 'wildignore' and 'suffixes' to ":vimgrep". (Ingo Karkat) +Files: src/ex_cmds2.c, src/proto/ex_cmds2.pro, src/quickfix.c, src/spell.c + + +*** ../vim-7.3.569/src/ex_cmds2.c 2012-06-20 15:48:53.000000000 +0200 +--- src/ex_cmds2.c 2012-06-29 12:43:34.000000000 +0200 +*************** +*** 1850,1871 **** + #if defined(FEAT_QUICKFIX) || defined(FEAT_SYN_HL) || defined(PROTO) + /* + * Parse a list of arguments (file names), expand them and return in +! * "fnames[fcountp]". + * Return FAIL or OK. + */ + int +! get_arglist_exp(str, fcountp, fnamesp) + char_u *str; + int *fcountp; + char_u ***fnamesp; + { + garray_T ga; + int i; + + if (get_arglist(&ga, str) == FAIL) + return FAIL; +! i = gen_expand_wildcards(ga.ga_len, (char_u **)ga.ga_data, +! fcountp, fnamesp, EW_FILE|EW_NOTFOUND); + ga_clear(&ga); + return i; + } +--- 1850,1877 ---- + #if defined(FEAT_QUICKFIX) || defined(FEAT_SYN_HL) || defined(PROTO) + /* + * Parse a list of arguments (file names), expand them and return in +! * "fnames[fcountp]". When "wig" is TRUE, removes files matching 'wildignore'. + * Return FAIL or OK. + */ + int +! get_arglist_exp(str, fcountp, fnamesp, wig) + char_u *str; + int *fcountp; + char_u ***fnamesp; ++ int wig; + { + garray_T ga; + int i; + + if (get_arglist(&ga, str) == FAIL) + return FAIL; +! if (wig == TRUE) +! i = expand_wildcards(ga.ga_len, (char_u **)ga.ga_data, +! fcountp, fnamesp, EW_FILE|EW_NOTFOUND); +! else +! i = gen_expand_wildcards(ga.ga_len, (char_u **)ga.ga_data, +! fcountp, fnamesp, EW_FILE|EW_NOTFOUND); +! + ga_clear(&ga); + return i; + } +*** ../vim-7.3.569/src/proto/ex_cmds2.pro 2011-05-19 18:26:34.000000000 +0200 +--- src/proto/ex_cmds2.pro 2012-06-29 12:43:49.000000000 +0200 +*************** +*** 42,48 **** + int check_fname __ARGS((void)); + int buf_write_all __ARGS((buf_T *buf, int forceit)); + int get_arglist __ARGS((garray_T *gap, char_u *str)); +! int get_arglist_exp __ARGS((char_u *str, int *fcountp, char_u ***fnamesp)); + void set_arglist __ARGS((char_u *str)); + void check_arg_idx __ARGS((win_T *win)); + void ex_args __ARGS((exarg_T *eap)); +--- 42,48 ---- + int check_fname __ARGS((void)); + int buf_write_all __ARGS((buf_T *buf, int forceit)); + int get_arglist __ARGS((garray_T *gap, char_u *str)); +! int get_arglist_exp __ARGS((char_u *str, int *fcountp, char_u ***fnamesp, int wig)); + void set_arglist __ARGS((char_u *str)); + void check_arg_idx __ARGS((win_T *win)); + void ex_args __ARGS((exarg_T *eap)); +*** ../vim-7.3.569/src/quickfix.c 2012-06-01 18:34:37.000000000 +0200 +--- src/quickfix.c 2012-06-29 12:43:49.000000000 +0200 +*************** +*** 3189,3195 **** + ; + + /* parse the list of arguments */ +! if (get_arglist_exp(p, &fcount, &fnames) == FAIL) + goto theend; + if (fcount == 0) + { +--- 3189,3195 ---- + ; + + /* parse the list of arguments */ +! if (get_arglist_exp(p, &fcount, &fnames, TRUE) == FAIL) + goto theend; + if (fcount == 0) + { +*** ../vim-7.3.569/src/spell.c 2012-06-01 17:49:51.000000000 +0200 +--- src/spell.c 2012-06-29 12:43:49.000000000 +0200 +*************** +*** 8553,8559 **** + } + + /* Expand all the remaining arguments (e.g., $VIMRUNTIME). */ +! if (get_arglist_exp(arg, &fcount, &fnames) == OK) + { + mkspell(fcount, fnames, ascii, eap->forceit, FALSE); + FreeWild(fcount, fnames); +--- 8553,8559 ---- + } + + /* Expand all the remaining arguments (e.g., $VIMRUNTIME). */ +! if (get_arglist_exp(arg, &fcount, &fnames, FALSE) == OK) + { + mkspell(fcount, fnames, ascii, eap->forceit, FALSE); + FreeWild(fcount, fnames); +*** ../vim-7.3.569/src/version.c 2012-06-29 12:54:32.000000000 +0200 +--- src/version.c 2012-06-29 12:56:12.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 570, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +70. ISDN lines are added to your house on a hourly basis + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3f7ecb034a506d0d6d81a8a2a56781ccc27e6e1f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:12 +0200 Subject: [PATCH 0315/3340] - patchlevel 571 --- 7.3.571 | 117 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 117 insertions(+) create mode 100644 7.3.571 diff --git a/7.3.571 b/7.3.571 new file mode 100644 index 00000000..ad62ffc2 --- /dev/null +++ b/7.3.571 @@ -0,0 +1,117 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.571 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.571 +Problem: Duplicated condition. +Solution: Remove one. (Dominique Pelle) +Files: src/os_win32.c + + +*** ../vim-7.3.570/src/os_win32.c 2012-02-29 13:58:43.000000000 +0100 +--- src/os_win32.c 2012-06-29 13:10:54.000000000 +0200 +*************** +*** 308,314 **** + # ifndef GETTEXT_DLL + # define GETTEXT_DLL "libintl.dll" + # endif +! /* Dummy funcitons */ + static char *null_libintl_gettext(const char *); + static char *null_libintl_textdomain(const char *); + static char *null_libintl_bindtextdomain(const char *, const char *); +--- 308,314 ---- + # ifndef GETTEXT_DLL + # define GETTEXT_DLL "libintl.dll" + # endif +! /* Dummy functions */ + static char *null_libintl_gettext(const char *); + static char *null_libintl_textdomain(const char *); + static char *null_libintl_bindtextdomain(const char *, const char *); +*************** +*** 1409,1415 **** + + + /* +! * mch_inchar(): low-level input funcion. + * Get one or more characters from the keyboard or the mouse. + * If time == 0, do not wait for characters. + * If time == n, wait a short time for characters. +--- 1409,1415 ---- + + + /* +! * mch_inchar(): low-level input function. + * Get one or more characters from the keyboard or the mouse. + * If time == 0, do not wait for characters. + * If time == n, wait a short time for characters. +*************** +*** 3451,3464 **** + * to avoid to perform a blocking read */ + ret = PeekNamedPipe(g_hChildStd_OUT_Rd, /* pipe to query */ + NULL, /* optional buffer */ +! 0, /* buffe size */ + NULL, /* number of read bytes */ + &availableBytes, /* available bytes total */ + NULL); /* byteLeft */ + + repeatCount = 0; + /* We got real data in the pipe, read it */ +! while (ret != 0 && availableBytes > 0 && availableBytes > 0) + { + repeatCount++; + toRead = +--- 3451,3464 ---- + * to avoid to perform a blocking read */ + ret = PeekNamedPipe(g_hChildStd_OUT_Rd, /* pipe to query */ + NULL, /* optional buffer */ +! 0, /* buffer size */ + NULL, /* number of read bytes */ + &availableBytes, /* available bytes total */ + NULL); /* byteLeft */ + + repeatCount = 0; + /* We got real data in the pipe, read it */ +! while (ret != 0 && availableBytes > 0) + { + repeatCount++; + toRead = +*************** +*** 3638,3644 **** + NULL, /* Process security attributes */ + NULL, /* Thread security attributes */ + +! // this command can be litigeous, handle inheritence was + // deactivated for pending temp file, but, if we deactivate + // it, the pipes don't work for some reason. + TRUE, /* Inherit handles, first deactivated, +--- 3638,3644 ---- + NULL, /* Process security attributes */ + NULL, /* Thread security attributes */ + +! // this command can be litigious, handle inheritance was + // deactivated for pending temp file, but, if we deactivate + // it, the pipes don't work for some reason. + TRUE, /* Inherit handles, first deactivated, +*** ../vim-7.3.570/src/version.c 2012-06-29 12:57:03.000000000 +0200 +--- src/version.c 2012-06-29 13:12:31.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 571, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +71. You wonder how people walk + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fd8def26d82c708861a5c6c4dfc3be4abae6524b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:12 +0200 Subject: [PATCH 0316/3340] - patchlevel 572 --- 7.3.572 | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.572 diff --git a/7.3.572 b/7.3.572 new file mode 100644 index 00000000..14fc127e --- /dev/null +++ b/7.3.572 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.572 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.572 +Problem: Duplicate statement in if and else. (Dominique Pelle) +Solution: Remove the condition and add a TODO. +Files: src/gui_xmebw.c + + +*** ../vim-7.3.571/src/gui_xmebw.c 2010-08-15 21:57:29.000000000 +0200 +--- src/gui_xmebw.c 2012-06-29 13:17:15.000000000 +0200 +*************** +*** 375,385 **** + + XGetGeometry(dpy, pix, &root, &x, &y, &width, &height, &border, &depth); + +! if (eb->enhancedbutton.label_location == (int)XmTOP +! || eb->enhancedbutton.label_location == (int)XmBOTTOM) +! shift = eb->primitive.shadow_thickness / 2; +! else +! shift = eb->primitive.shadow_thickness / 2; + + if (shift < 1) + shift = 1; +--- 375,382 ---- + + XGetGeometry(dpy, pix, &root, &x, &y, &width, &height, &border, &depth); + +! /* TODO: does the shift depend on label_location somehow? */ +! shift = eb->primitive.shadow_thickness / 2; + + if (shift < 1) + shift = 1; +*** ../vim-7.3.571/src/version.c 2012-06-29 13:13:59.000000000 +0200 +--- src/version.c 2012-06-29 13:18:41.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 572, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +72. Somebody at IRC just mentioned a way to obtain full motion video without + a PC using a wireless protocol called NTSC, you wonder how you never + heard about it + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f557e0849608a876464c91d393f79f584a6865eb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:13 +0200 Subject: [PATCH 0317/3340] - patchlevel 573 --- 7.3.573 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.573 diff --git a/7.3.573 b/7.3.573 new file mode 100644 index 00000000..7734a76a --- /dev/null +++ b/7.3.573 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.573 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.573 +Problem: Using array index before bounds checking. +Solution: Swap the parts of the condition. (Dominique Pelle) +Files: src/ops.c + + +*** ../vim-7.3.572/src/ops.c 2012-06-13 17:28:51.000000000 +0200 +--- src/ops.c 2012-06-29 13:27:11.000000000 +0200 +*************** +*** 6458,6464 **** + long chars = 0; + int is_word = 0; + +! for (i = 0; line[i] && i < limit; ) + { + if (is_word) + { +--- 6458,6464 ---- + long chars = 0; + int is_word = 0; + +! for (i = 0; i < limit && line[i] != NUL; ) + { + if (is_word) + { +*** ../vim-7.3.572/src/version.c 2012-06-29 13:19:23.000000000 +0200 +--- src/version.c 2012-06-29 13:27:59.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 573, + /**/ + +-- +"Thou shalt not follow the Null Pointer, for at its end Chaos and +Madness lie." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 81da0736128246bc9bf0a03f77b99af11b388502 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:13 +0200 Subject: [PATCH 0318/3340] - patchlevel 574 --- 7.3.574 | 88 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 88 insertions(+) create mode 100644 7.3.574 diff --git a/7.3.574 b/7.3.574 new file mode 100644 index 00000000..e23d818f --- /dev/null +++ b/7.3.574 @@ -0,0 +1,88 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.574 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.574 +Problem: When pasting a register in the search command line a CTRL-L + character is not pasted. (Dominique Pelle) +Solution: Escape the CTRL-L. (Christian Brabandt) +Files: src/ex_getln.c + + +*** ../vim-7.3.573/src/ex_getln.c 2012-06-06 12:02:57.000000000 +0200 +--- src/ex_getln.c 2012-06-29 13:39:03.000000000 +0200 +*************** +*** 3133,3139 **** + else + #endif + c = *s++; +! if (cv == Ctrl_V || c == ESC || c == Ctrl_C || c == CAR || c == NL + #ifdef UNIX + || c == intr_char + #endif +--- 3133,3140 ---- + else + #endif + c = *s++; +! if (cv == Ctrl_V || c == ESC || c == Ctrl_C +! || c == CAR || c == NL || c == Ctrl_L + #ifdef UNIX + || c == intr_char + #endif +*************** +*** 4692,4698 **** + if (tab[i].ic) + regmatch.rm_ic = TRUE; + ret = ExpandGeneric(xp, ®match, num_file, file, +! tab[i].func, tab[i].escaped); + break; + } + } +--- 4693,4699 ---- + if (tab[i].ic) + regmatch.rm_ic = TRUE; + ret = ExpandGeneric(xp, ®match, num_file, file, +! tab[i].func, tab[i].escaped); + break; + } + } +*************** +*** 5125,5131 **** + vim_free(matches); + } + if (ga.ga_len == 0) +! return FAIL; + + /* Sort and remove duplicates which can happen when specifying multiple + * directories in dirnames. */ +--- 5126,5132 ---- + vim_free(matches); + } + if (ga.ga_len == 0) +! return FAIL; + + /* Sort and remove duplicates which can happen when specifying multiple + * directories in dirnames. */ +*** ../vim-7.3.573/src/version.c 2012-06-29 13:34:15.000000000 +0200 +--- src/version.c 2012-06-29 13:38:22.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 574, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +73. You give your dog used motherboards instead of bones + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e69fffd93e9393ba481c38d6c3c57d55eb070722 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:13 +0200 Subject: [PATCH 0319/3340] - patchlevel 575 --- 7.3.575 | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 7.3.575 diff --git a/7.3.575 b/7.3.575 new file mode 100644 index 00000000..f5d80d72 --- /dev/null +++ b/7.3.575 @@ -0,0 +1,60 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.575 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.575 +Problem: "ygt" tries to yank instead of giving an error. (Daniel Mueller) +Solution: Check for a pending operator. +Files: src/normal.c + + +*** ../vim-7.3.574/src/normal.c 2012-06-06 16:12:54.000000000 +0200 +--- src/normal.c 2012-06-29 13:50:26.000000000 +0200 +*************** +*** 8393,8402 **** + + #ifdef FEAT_WINDOWS + case 't': +! goto_tabpage((int)cap->count0); + break; + case 'T': +! goto_tabpage(-(int)cap->count1); + break; + #endif + +--- 8393,8404 ---- + + #ifdef FEAT_WINDOWS + case 't': +! if (!checkclearop(oap)) +! goto_tabpage((int)cap->count0); + break; + case 'T': +! if (!checkclearop(oap)) +! goto_tabpage(-(int)cap->count1); + break; + #endif + +*** ../vim-7.3.574/src/version.c 2012-06-29 13:44:37.000000000 +0200 +--- src/version.c 2012-06-29 13:52:01.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 575, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +74. Your most erotic dreams are about cybersex + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d068b3cf20c7d670eb2f0367b377ed55af170222 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:13 +0200 Subject: [PATCH 0320/3340] - patchlevel 576 --- 7.3.576 | 255 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 255 insertions(+) create mode 100644 7.3.576 diff --git a/7.3.576 b/7.3.576 new file mode 100644 index 00000000..bc226d90 --- /dev/null +++ b/7.3.576 @@ -0,0 +1,255 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.576 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.576 +Problem: Formatting of lists inside comments is not right yet. +Solution: Use another solution and add a test. (Tor Perkins) +Files: src/edit.c, src/misc1.c, src/testdir/test68.in, + src/testdir/test69.ok + + +*** ../vim-7.3.575/src/edit.c 2012-06-20 22:55:56.000000000 +0200 +--- src/edit.c 2012-06-29 14:10:36.000000000 +0200 +*************** +*** 6320,6333 **** + if (!(flags & INSCHAR_COM_LIST)) + { + /* +! * This section is for numeric lists w/o comments. If comment +! * indents are needed with numeric lists (formatoptions=nq), +! * then the INSCHAR_COM_LIST flag will cause the corresponding +! * OPENLINE_COM_LIST flag to be passed through to open_line() +! * (as seen above)... + */ + if (second_indent < 0 && has_format_option(FO_Q_NUMBER)) +! second_indent = get_number_indent(curwin->w_cursor.lnum -1); + if (second_indent >= 0) + { + #ifdef FEAT_VREPLACE +--- 6320,6334 ---- + if (!(flags & INSCHAR_COM_LIST)) + { + /* +! * This section is for auto-wrap of numeric lists. When not +! * in insert mode (i.e. format_lines()), the INSCHAR_COM_LIST +! * flag will be set and open_line() will handle it (as seen +! * above). The code here (and in get_number_indent()) will +! * recognize comments if needed... + */ + if (second_indent < 0 && has_format_option(FO_Q_NUMBER)) +! second_indent = +! get_number_indent(curwin->w_cursor.lnum - 1); + if (second_indent >= 0) + { + #ifdef FEAT_VREPLACE +*************** +*** 6336,6342 **** +--- 6337,6367 ---- + FALSE, NUL, TRUE); + else + #endif ++ #ifdef FEAT_COMMENTS ++ if (leader_len > 0 && second_indent - leader_len > 0) ++ { ++ int i; ++ int padding = second_indent - leader_len; ++ ++ /* We started at the first_line of a numbered list ++ * that has a comment. the open_line() function has ++ * inserted the proper comment leader and positioned ++ * the cursor at the end of the split line. Now we ++ * add the additional whitespace needed after the ++ * comment leader for the numbered list. */ ++ for (i = 0; i < padding; i++) ++ { ++ ins_str((char_u *)" "); ++ changed_bytes(curwin->w_cursor.lnum, leader_len); ++ } ++ } ++ else ++ { ++ #endif + (void)set_indent(second_indent, SIN_CHANGED); ++ #ifdef FEAT_COMMENTS ++ } ++ #endif + } + } + first_line = FALSE; +*** ../vim-7.3.575/src/misc1.c 2012-06-20 17:56:06.000000000 +0200 +--- src/misc1.c 2012-06-29 14:10:12.000000000 +0200 +*************** +*** 424,491 **** + colnr_T col; + pos_T pos; + + if (lnum > curbuf->b_ml.ml_line_count) + return -1; + pos.lnum = 0; + + #ifdef FEAT_COMMENTS +! if (has_format_option(FO_Q_COMS) && has_format_option(FO_Q_NUMBER)) +! { +! regmatch_T regmatch; +! int lead_len; /* length of comment leader */ +! + lead_len = get_leader_len(ml_get(lnum), NULL, FALSE, TRUE); +- regmatch.regprog = vim_regcomp(curbuf->b_p_flp, RE_MAGIC); +- if (regmatch.regprog != NULL) +- { +- regmatch.rm_ic = FALSE; +- +- /* vim_regexec() expects a pointer to a line. This lets us +- * start matching for the flp beyond any comment leader... */ +- if (vim_regexec(®match, ml_get(lnum) + lead_len, (colnr_T)0)) +- { +- pos.lnum = lnum; +- pos.col = (colnr_T)(*regmatch.endp - ml_get(lnum)); +- #ifdef FEAT_VIRTUALEDIT +- pos.coladd = 0; + #endif +! } +! } +! vim_free(regmatch.regprog); +! } +! else + { +! /* +! * What follows is the orig code that is not "comment aware"... +! * +! * I'm not sure if regmmatch_T (multi-match) is needed in this case. +! * It may be true that this section would work properly using the +! * regmatch_T code above, in which case, these two separate sections +! * should be consolidated w/ FEAT_COMMENTS making lead_len > 0... +! */ +! #endif +! regmmatch_T regmatch; + +! regmatch.regprog = vim_regcomp(curbuf->b_p_flp, RE_MAGIC); +! +! if (regmatch.regprog != NULL) + { +! regmatch.rmm_ic = FALSE; +! regmatch.rmm_maxcol = 0; +! if (vim_regexec_multi(®match, curwin, curbuf, +! lnum, (colnr_T)0, NULL)) +! { +! pos.lnum = regmatch.endpos[0].lnum + lnum; +! pos.col = regmatch.endpos[0].col; + #ifdef FEAT_VIRTUALEDIT +! pos.coladd = 0; + #endif +- } +- vim_free(regmatch.regprog); + } +- #ifdef FEAT_COMMENTS + } +! #endif + + if (pos.lnum == 0 || *ml_get_pos(&pos) == NUL) + return -1; +--- 424,458 ---- + colnr_T col; + pos_T pos; + ++ regmatch_T regmatch; ++ int lead_len = 0; /* length of comment leader */ ++ + if (lnum > curbuf->b_ml.ml_line_count) + return -1; + pos.lnum = 0; + + #ifdef FEAT_COMMENTS +! /* In format_lines() (i.e. not insert mode), fo+=q is needed too... */ +! if ((State & INSERT) || has_format_option(FO_Q_COMS)) + lead_len = get_leader_len(ml_get(lnum), NULL, FALSE, TRUE); + #endif +! regmatch.regprog = vim_regcomp(curbuf->b_p_flp, RE_MAGIC); +! if (regmatch.regprog != NULL) + { +! regmatch.rm_ic = FALSE; + +! /* vim_regexec() expects a pointer to a line. This lets us +! * start matching for the flp beyond any comment leader... */ +! if (vim_regexec(®match, ml_get(lnum) + lead_len, (colnr_T)0)) + { +! pos.lnum = lnum; +! pos.col = (colnr_T)(*regmatch.endp - ml_get(lnum)); + #ifdef FEAT_VIRTUALEDIT +! pos.coladd = 0; + #endif + } + } +! vim_free(regmatch.regprog); + + if (pos.lnum == 0 || *ml_get_pos(&pos) == NUL) + return -1; +*** ../vim-7.3.575/src/testdir/test68.in 2012-06-13 17:28:51.000000000 +0200 +--- src/testdir/test68.in 2012-06-29 14:27:27.000000000 +0200 +*************** +*** 52,57 **** +--- 52,68 ---- + + STARTTEST + /^{/+1 ++ :set tw=5 fo=tcn comments=:# ++ A bjA b ++ ENDTEST ++ ++ { ++ 1 a ++ # 1 a ++ } ++ ++ STARTTEST ++ /^{/+1 + :set tw=5 fo=qn comments=:# + gwap + ENDTEST +*************** +*** 83,88 **** +--- 94,107 ---- + } + + STARTTEST ++ /^#/ ++ :setl tw=12 fo=tqnc comments=:# ++ A foobar ++ ENDTEST ++ ++ # 1 xxxxx ++ ++ STARTTEST + :g/^STARTTEST/.,/^ENDTEST/d + :1;/^Results/,$wq! test.out + ENDTEST +*** ../vim-7.3.575/src/version.c 2012-06-29 13:56:01.000000000 +0200 +--- src/version.c 2012-06-29 15:03:10.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 576, + /**/ + +-- +Proof techniques #2: Proof by Oddity. + SAMPLE: To prove that horses have an infinite number of legs. +(1) Horses have an even number of legs. +(2) They have two legs in back and fore legs in front. +(3) This makes a total of six legs, which certainly is an odd number of + legs for a horse. +(4) But the only number that is both odd and even is infinity. +(5) Therefore, horses must have an infinite number of legs. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6d814990306259676355d382ac1c563be13e37bc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:14 +0200 Subject: [PATCH 0321/3340] - patchlevel 577 --- 7.3.577 | 273 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 273 insertions(+) create mode 100644 7.3.577 diff --git a/7.3.577 b/7.3.577 new file mode 100644 index 00000000..2929b22d --- /dev/null +++ b/7.3.577 @@ -0,0 +1,273 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.577 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.577 +Problem: Size of memory does not fit in 32 bit unsigned. +Solution: Use Kbyte instead of byte. Call GlobalMemoryStatusEx() instead of + GlobalMemoryStatus() when available. +Files: src/misc2.c, src/option.c, src/os_amiga.c, src/os_msdos.c, + src/os_win16.c, src/os_win32.c + + +*** ../vim-7.3.576/src/misc2.c 2012-02-29 13:58:43.000000000 +0100 +--- src/misc2.c 2012-06-29 15:30:54.000000000 +0200 +*************** +*** 815,820 **** +--- 815,821 ---- + #else + # define KEEP_ROOM (2 * 8192L) + #endif ++ #define KEEP_ROOM_KB (KEEP_ROOM / 1024L) + + /* + * Note: if unsigned is 16 bits we can only allocate up to 64K with alloc(). +*************** +*** 940,946 **** + allocated = 0; + # endif + /* 3. check for available memory: call mch_avail_mem() */ +! if (mch_avail_mem(TRUE) < KEEP_ROOM && !releasing) + { + free((char *)p); /* System is low... no go! */ + p = NULL; +--- 941,947 ---- + allocated = 0; + # endif + /* 3. check for available memory: call mch_avail_mem() */ +! if (mch_avail_mem(TRUE) < KEEP_ROOM_KB && !releasing) + { + free((char *)p); /* System is low... no go! */ + p = NULL; +*** ../vim-7.3.576/src/option.c 2012-03-28 19:58:34.000000000 +0200 +--- src/option.c 2012-06-29 15:31:46.000000000 +0200 +*************** +*** 3154,3160 **** + { + #ifdef HAVE_AVAIL_MEM + /* Use amount of memory available at this moment. */ +! n = (mch_avail_mem(FALSE) >> 11); + #else + # ifdef HAVE_TOTAL_MEM + /* Use amount of memory available to Vim. */ +--- 3154,3160 ---- + { + #ifdef HAVE_AVAIL_MEM + /* Use amount of memory available at this moment. */ +! n = (mch_avail_mem(FALSE) >> 1); + #else + # ifdef HAVE_TOTAL_MEM + /* Use amount of memory available to Vim. */ +*************** +*** 6702,6708 **** + { + for (s = *varp; *s;) + { +! while(*s == ',' || *s == ' ') + s++; + if (!*s) + break; +--- 6702,6708 ---- + { + for (s = *varp; *s;) + { +! while (*s == ',' || *s == ' ') + s++; + if (!*s) + break; +*************** +*** 7391,7397 **** + new_unnamed |= CLIP_UNNAMED; + p += 7; + } +! else if (STRNCMP(p, "unnamedplus", 11) == 0 + && (p[11] == ',' || p[11] == NUL)) + { + new_unnamed |= CLIP_UNNAMED_PLUS; +--- 7391,7397 ---- + new_unnamed |= CLIP_UNNAMED; + p += 7; + } +! else if (STRNCMP(p, "unnamedplus", 11) == 0 + && (p[11] == ',' || p[11] == NUL)) + { + new_unnamed |= CLIP_UNNAMED_PLUS; +*** ../vim-7.3.576/src/os_amiga.c 2011-10-20 18:24:16.000000000 +0200 +--- src/os_amiga.c 2012-06-29 15:33:59.000000000 +0200 +*************** +*** 191,206 **** + } + + /* +! * Return amount of memory still available. + */ + long_u + mch_avail_mem(special) + int special; + { + #ifdef __amigaos4__ +! return (long_u)AvailMem(MEMF_ANY); + #else +! return (long_u)AvailMem(special ? (long)MEMF_CHIP : (long)MEMF_ANY); + #endif + } + +--- 191,206 ---- + } + + /* +! * Return amount of memory still available in Kbyte. + */ + long_u + mch_avail_mem(special) + int special; + { + #ifdef __amigaos4__ +! return (long_u)AvailMem(MEMF_ANY) >> 10; + #else +! return (long_u)(AvailMem(special ? (long)MEMF_CHIP : (long)MEMF_ANY)) >> 10; + #endif + } + +*** ../vim-7.3.576/src/os_msdos.c 2011-06-19 01:14:22.000000000 +0200 +--- src/os_msdos.c 2012-06-29 15:33:26.000000000 +0200 +*************** +*** 550,564 **** + #endif + + /* +! * Return amount of memory currently available. + */ + long_u + mch_avail_mem(int special) + { + #ifdef DJGPP +! return _go32_dpmi_remaining_virtual_memory(); + #else +! return coreleft(); + #endif + } + +--- 550,564 ---- + #endif + + /* +! * Return amount of memory currently available in Kbyte. + */ + long_u + mch_avail_mem(int special) + { + #ifdef DJGPP +! return _go32_dpmi_remaining_virtual_memory() >> 10; + #else +! return coreleft() >> 10; + #endif + } + +*** ../vim-7.3.576/src/os_win16.c 2011-10-20 18:24:16.000000000 +0200 +--- src/os_win16.c 2012-06-29 15:34:18.000000000 +0200 +*************** +*** 379,391 **** + + + /* +! * How much memory is available? + */ + long_u + mch_avail_mem( + int special) + { +! return GetFreeSpace(0); + } + + +--- 379,391 ---- + + + /* +! * How much memory is available in Kbyte? + */ + long_u + mch_avail_mem( + int special) + { +! return GetFreeSpace(0) >> 10; + } + + +*** ../vim-7.3.576/src/os_win32.c 2012-06-29 13:13:59.000000000 +0200 +--- src/os_win32.c 2012-06-29 15:39:52.000000000 +0200 +*************** +*** 4992,5009 **** + + + /* +! * How much memory is available? + * Return sum of available physical and page file memory. + */ + /*ARGSUSED*/ + long_u + mch_avail_mem(int special) + { +! MEMORYSTATUS ms; + +! ms.dwLength = sizeof(MEMORYSTATUS); +! GlobalMemoryStatus(&ms); +! return (long_u) (ms.dwAvailPhys + ms.dwAvailPageFile); + } + + #ifdef FEAT_MBYTE +--- 4992,5020 ---- + + + /* +! * How much memory is available in Kbyte? + * Return sum of available physical and page file memory. + */ + /*ARGSUSED*/ + long_u + mch_avail_mem(int special) + { +! if (g_PlatformId != VER_PLATFORM_WIN32_NT) +! { +! MEMORYSTATUS ms; + +! ms.dwLength = sizeof(MEMORYSTATUS); +! GlobalMemoryStatus(&ms); +! return (long_u)((ms.dwAvailPhys + ms.dwAvailPageFile) >> 10); +! } +! else +! { +! MEMORYSTATUSEX ms; +! +! ms.dwLength = sizeof(MEMORYSTATUSEX); +! GlobalMemoryStatusEx(&ms); +! return (long_u)((ms.ullAvailPhys + ms.ullAvailPageFile) >> 10); +! } + } + + #ifdef FEAT_MBYTE +*** ../vim-7.3.576/src/version.c 2012-06-29 15:04:34.000000000 +0200 +--- src/version.c 2012-06-29 15:45:44.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 577, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +75. You start wondering whether you could actually upgrade your brain + with a Pentium Pro microprocessor 80. The upgrade works just fine. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8c68f207358c0ffe2176303835db948532ad8ec5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:14 +0200 Subject: [PATCH 0322/3340] - patchlevel 578 --- 7.3.578 | 80 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 7.3.578 diff --git a/7.3.578 b/7.3.578 new file mode 100644 index 00000000..9b0aedd2 --- /dev/null +++ b/7.3.578 @@ -0,0 +1,80 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.578 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.578 +Problem: Misplaced declaration. +Solution: Move declaration to start of block. +Files: src/if_py_both.h + + +*** ../vim-7.3.577/src/if_py_both.h 2012-06-29 12:54:32.000000000 +0200 +--- src/if_py_both.h 2012-06-29 16:15:29.000000000 +0200 +*************** +*** 818,838 **** + + if (valObject == NULL) + { + if (di == NULL) + { + PyErr_SetString(PyExc_IndexError, _("no such key in dictionary")); + return -1; + } +! hashitem_T *hi = hash_find(&d->dv_hashtab, di->di_key); + hash_remove(&d->dv_hashtab, hi); + dictitem_free(di); + return 0; + } + + if (ConvertFromPyObject(valObject, &tv) == -1) +- { + return -1; +- } + + if (di == NULL) + { +--- 818,838 ---- + + if (valObject == NULL) + { ++ hashitem_T *hi; ++ + if (di == NULL) + { + PyErr_SetString(PyExc_IndexError, _("no such key in dictionary")); + return -1; + } +! hi = hash_find(&d->dv_hashtab, di->di_key); + hash_remove(&d->dv_hashtab, hi); + dictitem_free(di); + return 0; + } + + if (ConvertFromPyObject(valObject, &tv) == -1) + return -1; + + if (di == NULL) + { +*** ../vim-7.3.577/src/version.c 2012-06-29 15:51:26.000000000 +0200 +--- src/version.c 2012-06-29 16:18:10.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 578, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +77. The phone company asks you to test drive their new PBX system + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 36ff25c55099c1fbdf230f735d9149601587fb42 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:14 +0200 Subject: [PATCH 0323/3340] - patchlevel 579 --- 7.3.579 | 232 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 232 insertions(+) create mode 100644 7.3.579 diff --git a/7.3.579 b/7.3.579 new file mode 100644 index 00000000..ed618fe7 --- /dev/null +++ b/7.3.579 @@ -0,0 +1,232 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.579 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.579 (after 7.3.569) +Problem: Can't compile with Python 2.5. +Solution: Use PyCObject when Capsules are not available. +Files: src/if_py_both.h, src/if_python.c, src/if_python3.c + + +*** ../vim-7.3.578/src/if_py_both.h 2012-06-29 16:19:46.000000000 +0200 +--- src/if_py_both.h 2012-06-29 16:15:29.000000000 +0200 +*************** +*** 56,62 **** + /* name, function, calling, documentation */ + {"write", OutputWrite, 1, ""}, + {"writelines", OutputWritelines, 1, ""}, +! {"flush", OutputFlush, 1, ""}, + { NULL, NULL, 0, NULL} + }; + +--- 56,62 ---- + /* name, function, calling, documentation */ + {"write", OutputWrite, 1, ""}, + {"writelines", OutputWritelines, 1, ""}, +! {"flush", OutputFlush, 1, ""}, + { NULL, NULL, 0, NULL} + }; + +*************** +*** 506,513 **** + /* name, function, calling, documentation */ + {"command", VimCommand, 1, "Execute a Vim ex-mode command" }, + {"eval", VimEval, 1, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, 1, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, 1, "Screen string width, counts as having width 1"}, + { NULL, NULL, 0, NULL } + }; + +--- 506,513 ---- + /* name, function, calling, documentation */ + {"command", VimCommand, 1, "Execute a Vim ex-mode command" }, + {"eval", VimEval, 1, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, 1, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, 1, "Screen string width, counts as having width 1"}, + { NULL, NULL, 0, NULL } + }; + +*************** +*** 2432,2448 **** +--- 2432,2463 ---- + convert_dl(PyObject *obj, typval_T *tv, + pytotvfunc py_to_tv, PyObject *lookupDict) + { ++ # ifdef PY_USE_CAPSULE + PyObject *capsule; ++ # else ++ PyCObject *cobject; ++ # endif + char hexBuf[sizeof(void *) * 2 + 3]; + + sprintf(hexBuf, "%p", obj); + ++ # ifdef PY_USE_CAPSULE + capsule = PyDict_GetItemString(lookupDict, hexBuf); + if (capsule == NULL) ++ # else ++ cobject = (PyCObject *)PyDict_GetItemString(lookupDict, hexBuf); ++ if (cobject == NULL) ++ # endif + { ++ # ifdef PY_USE_CAPSULE + capsule = PyCapsule_New(tv, NULL, NULL); + PyDict_SetItemString(lookupDict, hexBuf, capsule); + Py_DECREF(capsule); ++ # else ++ cobject = PyCObject_FromVoidPtr(tv, NULL); ++ PyDict_SetItemString(lookupDict, hexBuf, cobject); ++ Py_DECREF(cobject); ++ # endif + if (py_to_tv(obj, tv, lookupDict) == -1) + { + tv->v_type = VAR_UNKNOWN; +*************** +*** 2458,2464 **** + } + else + { +! typval_T *v = PyCapsule_GetPointer(capsule, NULL); + copy_tv(v, tv); + } + return 0; +--- 2473,2485 ---- + } + else + { +! typval_T *v; +! +! # ifdef PY_USE_CAPSULE +! v = PyCapsule_GetPointer(capsule, NULL); +! # else +! v = PyCObject_AsVoidPtr(cobject); +! # endif + copy_tv(v, tv); + } + return 0; +*** ../vim-7.3.578/src/if_python.c 2012-06-29 12:54:32.000000000 +0200 +--- src/if_python.c 2012-06-29 16:17:44.000000000 +0200 +*************** +*** 71,76 **** +--- 71,80 ---- + # define PySequenceMethods Py_ssize_t + #endif + ++ #if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02070000 ++ # define PY_USE_CAPSULE ++ #endif ++ + #if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02050000 + # define PyInt Py_ssize_t + # define PyInquiry lenfunc +*************** +*** 220,227 **** + # define PyObject_Malloc dll_PyObject_Malloc + # define PyObject_Free dll_PyObject_Free + # endif +! # define PyCapsule_New dll_PyCapsule_New +! # define PyCapsule_GetPointer dll_PyCapsule_GetPointer + + /* + * Pointers for dynamic link +--- 224,236 ---- + # define PyObject_Malloc dll_PyObject_Malloc + # define PyObject_Free dll_PyObject_Free + # endif +! # ifdef PY_USE_CAPSULE +! # define PyCapsule_New dll_PyCapsule_New +! # define PyCapsule_GetPointer dll_PyCapsule_GetPointer +! # else +! # define PyCObject_FromVoidPtr dll_PyCObject_FromVoidPtr +! # define PyCObject_AsVoidPtr dll_PyCObject_AsVoidPtr +! # endif + + /* + * Pointers for dynamic link +*************** +*** 309,316 **** +--- 318,330 ---- + static void* (*dll_PyObject_Malloc)(size_t); + static void (*dll_PyObject_Free)(void*); + # endif ++ # ifdef PY_USE_CAPSULE + static PyObject* (*dll_PyCapsule_New)(void *, char *, PyCapsule_Destructor); + static void* (*dll_PyCapsule_GetPointer)(PyObject *, char *); ++ # else ++ static PyCObject* (*dll_PyCObject_FromVoidPtr)(void *cobj, void (*destr)(void *)); ++ static void* (*dll_PyCObject_AsVoidPtr)(PyCObject *); ++ # endif + + static HINSTANCE hinstPython = 0; /* Instance of python.dll */ + +*************** +*** 403,409 **** + {"PyType_Ready", (PYTHON_PROC*)&dll_PyType_Ready}, + {"Py_BuildValue", (PYTHON_PROC*)&dll_Py_BuildValue}, + {"Py_FindMethod", (PYTHON_PROC*)&dll_Py_FindMethod}, +! # if (PY_VERSION_HEX >= 0x02050000) && SIZEOF_SIZE_T != SIZEOF_INT + {"Py_InitModule4_64", (PYTHON_PROC*)&dll_Py_InitModule4}, + # else + {"Py_InitModule4", (PYTHON_PROC*)&dll_Py_InitModule4}, +--- 417,424 ---- + {"PyType_Ready", (PYTHON_PROC*)&dll_PyType_Ready}, + {"Py_BuildValue", (PYTHON_PROC*)&dll_Py_BuildValue}, + {"Py_FindMethod", (PYTHON_PROC*)&dll_Py_FindMethod}, +! # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02050000 \ +! && SIZEOF_SIZE_T != SIZEOF_INT + {"Py_InitModule4_64", (PYTHON_PROC*)&dll_Py_InitModule4}, + # else + {"Py_InitModule4", (PYTHON_PROC*)&dll_Py_InitModule4}, +*************** +*** 424,431 **** +--- 439,451 ---- + {"PyObject_Malloc", (PYTHON_PROC*)&dll_PyObject_Malloc}, + {"PyObject_Free", (PYTHON_PROC*)&dll_PyObject_Free}, + # endif ++ # ifdef PY_USE_CAPSULE + {"PyCapsule_New", (PYTHON_PROC*)&dll_PyCapsule_New}, + {"PyCapsule_GetPointer", (PYTHON_PROC*)&dll_PyCapsule_GetPointer}, ++ # else ++ {"PyCObject_FromVoidPtr", (PYTHON_PROC*)&dll_PyCObject_FromVoidPtr}, ++ {"PyCObject_AsVoidPtr", (PYTHON_PROC*)&dll_PyCObject_AsVoidPtr}, ++ # endif + {"", NULL}, + }; + +*** ../vim-7.3.578/src/if_python3.c 2012-06-29 12:54:32.000000000 +0200 +--- src/if_python3.c 2012-06-29 16:16:54.000000000 +0200 +*************** +*** 75,80 **** +--- 75,83 ---- + # define CODEC_ERROR_HANDLER NULL + #endif + ++ /* Python 3 does not support CObjects, always use Capsules */ ++ #define PY_USE_CAPSULE ++ + #define PyInt Py_ssize_t + #define PyString_Check(obj) PyUnicode_Check(obj) + #define PyString_AsBytes(obj) PyUnicode_AsEncodedString(obj, (char *)ENC_OPT, CODEC_ERROR_HANDLER) +*** ../vim-7.3.578/src/version.c 2012-06-29 16:19:46.000000000 +0200 +--- src/version.c 2012-06-29 16:21:25.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 579, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +78. You find yourself dialing IP numbers on the phone. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 77c235a20225daba3719b2c3ec76531a83f1903f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:15 +0200 Subject: [PATCH 0324/3340] - patchlevel 580 --- 7.3.580 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.580 diff --git a/7.3.580 b/7.3.580 new file mode 100644 index 00000000..c2c2a537 --- /dev/null +++ b/7.3.580 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.580 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.580 +Problem: Warning on 64 bit MS-Windows. +Solution: Add type cast. (Mike Williams) +Files: src/if_py_both.h + + +*** ../vim-7.3.579/src/if_py_both.h 2012-06-29 16:28:23.000000000 +0200 +--- src/if_py_both.h 2012-06-29 17:49:59.000000000 +0200 +*************** +*** 495,501 **** + if (!PyArg_ParseTuple(args, "s", &expr)) + return NULL; + +! return PyLong_FromLong(mb_string2cells((char_u *)expr, STRLEN(expr))); + } + + /* +--- 495,501 ---- + if (!PyArg_ParseTuple(args, "s", &expr)) + return NULL; + +! return PyLong_FromLong(mb_string2cells((char_u *)expr, (int)STRLEN(expr))); + } + + /* +*** ../vim-7.3.579/src/version.c 2012-06-29 16:28:23.000000000 +0200 +--- src/version.c 2012-06-29 17:50:36.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 580, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +79. All of your most erotic dreams have a scrollbar at the right side. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8e0a01c7c8cc81c3c0da3384159cf4f33dd3ab3c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:15 +0200 Subject: [PATCH 0325/3340] - patchlevel 581 --- 7.3.581 | 117 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 117 insertions(+) create mode 100644 7.3.581 diff --git a/7.3.581 b/7.3.581 new file mode 100644 index 00000000..55300303 --- /dev/null +++ b/7.3.581 @@ -0,0 +1,117 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.581 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.581 +Problem: Problems compiling with Python. +Solution: Pick UCS2 or UCS4 function at runtime. (lilydjwg) +Files: src/if_python.c + + +*** ../vim-7.3.580/src/if_python.c 2012-06-29 16:28:23.000000000 +0200 +--- src/if_python.c 2012-06-29 19:10:53.000000000 +0200 +*************** +*** 196,202 **** + # define PyString_Size dll_PyString_Size + # define PyString_Type (*dll_PyString_Type) + # define PyUnicode_Type (*dll_PyUnicode_Type) +! # define PyUnicodeUCS4_AsEncodedString (*dll_PyUnicodeUCS4_AsEncodedString) + # define PyFloat_AsDouble dll_PyFloat_AsDouble + # define PyFloat_FromDouble dll_PyFloat_FromDouble + # define PyFloat_Type (*dll_PyFloat_Type) +--- 196,203 ---- + # define PyString_Size dll_PyString_Size + # define PyString_Type (*dll_PyString_Type) + # define PyUnicode_Type (*dll_PyUnicode_Type) +! # undef PyUnicode_AsEncodedString +! # define PyUnicode_AsEncodedString py_PyUnicode_AsEncodedString + # define PyFloat_AsDouble dll_PyFloat_AsDouble + # define PyFloat_FromDouble dll_PyFloat_FromDouble + # define PyFloat_Type (*dll_PyFloat_Type) +*************** +*** 290,296 **** + static PyInt(*dll_PyString_Size)(PyObject *); + static PyTypeObject* dll_PyString_Type; + static PyTypeObject* dll_PyUnicode_Type; +! static PyObject *(*PyUnicodeUCS4_AsEncodedString)(PyObject *, char *, char *); + static double(*dll_PyFloat_AsDouble)(PyObject *); + static PyObject*(*dll_PyFloat_FromDouble)(double); + static PyTypeObject* dll_PyFloat_Type; +--- 291,297 ---- + static PyInt(*dll_PyString_Size)(PyObject *); + static PyTypeObject* dll_PyString_Type; + static PyTypeObject* dll_PyUnicode_Type; +! static PyObject *(*py_PyUnicode_AsEncodedString)(PyObject *, char *, char *); + static double(*dll_PyFloat_AsDouble)(PyObject *); + static PyObject*(*dll_PyFloat_FromDouble)(double); + static PyTypeObject* dll_PyFloat_Type; +*************** +*** 406,412 **** + {"PyString_Size", (PYTHON_PROC*)&dll_PyString_Size}, + {"PyString_Type", (PYTHON_PROC*)&dll_PyString_Type}, + {"PyUnicode_Type", (PYTHON_PROC*)&dll_PyUnicode_Type}, +- {"PyUnicodeUCS4_AsEncodedString", (PYTHON_PROC*)&dll_PyUnicodeUCS4_AsEncodedString}, + {"PyFloat_Type", (PYTHON_PROC*)&dll_PyFloat_Type}, + {"PyFloat_AsDouble", (PYTHON_PROC*)&dll_PyFloat_AsDouble}, + {"PyFloat_FromDouble", (PYTHON_PROC*)&dll_PyFloat_FromDouble}, +--- 407,412 ---- +*************** +*** 471,476 **** +--- 471,477 ---- + python_runtime_link_init(char *libname, int verbose) + { + int i; ++ void *ucs_as_encoded_string; + + #if !(defined(PY_NO_RTLD_GLOBAL) && defined(PY3_NO_RTLD_GLOBAL)) && defined(UNIX) && defined(FEAT_PYTHON3) + /* Can't have Python and Python3 loaded at the same time. +*************** +*** 506,511 **** +--- 507,531 ---- + return FAIL; + } + } ++ ++ /* Load unicode functions separately as only the ucs2 or the ucs4 functions ++ * will be present in the library. */ ++ ucs_as_encoded_string = symbol_from_dll(hinstPython, ++ "PyUnicodeUCS2_AsEncodedString"); ++ if (ucs_as_encoded_string == NULL) ++ ucs_as_encoded_string = symbol_from_dll(hinstPython, ++ "PyUnicodeUCS4_AsEncodedString"); ++ if (ucs_as_encoded_string != NULL) ++ py_PyUnicode_AsEncodedString = ucs_as_encoded_string; ++ else ++ { ++ close_dll(hinstPython); ++ hinstPython = 0; ++ if (verbose) ++ EMSG2(_(e_loadfunc), "PyUnicode_UCSX_*"); ++ return FAIL; ++ } ++ + return OK; + } + +*** ../vim-7.3.580/src/version.c 2012-06-29 17:51:58.000000000 +0200 +--- src/version.c 2012-06-29 19:13:47.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 581, + /**/ + +-- +ASCII stupid question, get a stupid ANSI. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 27421d43031fc5a714f338debc4908c595ba1bf9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:15 +0200 Subject: [PATCH 0326/3340] - patchlevel 582 --- 7.3.582 | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 7.3.582 diff --git a/7.3.582 b/7.3.582 new file mode 100644 index 00000000..4e118a7d --- /dev/null +++ b/7.3.582 @@ -0,0 +1,61 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.582 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.582 (after 7.3.576) +Problem: Missing parts of the test OK file. +Solution: Add the missing parts. +Files: src/testdir/test68.ok + + +*** ../vim-7.3.581/src/testdir/test68.ok 2012-06-13 17:28:51.000000000 +0200 +--- src/testdir/test68.ok 2012-06-29 15:00:13.000000000 +0200 +*************** +*** 35,40 **** +--- 35,48 ---- + + + { ++ 1 a ++ b ++ # 1 a ++ # b ++ } ++ ++ ++ { + # 1 a + # b + } +*************** +*** 48,50 **** +--- 56,62 ---- + + { 1aa ^^2bb } + ++ ++ # 1 xxxxx ++ # foobar ++ +*** ../vim-7.3.581/src/version.c 2012-06-29 19:14:48.000000000 +0200 +--- src/version.c 2012-06-29 23:57:43.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 582, + /**/ + +-- +If your nose runs, and your feet smell, you might be upside down. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 91585d4675a3d4329f25489f69496613272a2da7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:16 +0200 Subject: [PATCH 0327/3340] - patchlevel 583 --- 7.3.583 | 79 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 79 insertions(+) create mode 100644 7.3.583 diff --git a/7.3.583 b/7.3.583 new file mode 100644 index 00000000..2ea7f9d2 --- /dev/null +++ b/7.3.583 @@ -0,0 +1,79 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.583 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.583 +Problem: PyObject_NextNotImplemented is not defined before Python 2.7. + (Danek Duvall) +Solution: Add #ifdefs. +Files: src/if_python.c + + +*** ../vim-7.3.582/src/if_python.c 2012-06-29 19:14:48.000000000 +0200 +--- src/if_python.c 2012-06-30 12:59:38.000000000 +0200 +*************** +*** 214,220 **** + # define Py_Finalize dll_Py_Finalize + # define Py_IsInitialized dll_Py_IsInitialized + # define _PyObject_New dll__PyObject_New +! # define _PyObject_NextNotImplemented (*dll__PyObject_NextNotImplemented) + # define _Py_NoneStruct (*dll__Py_NoneStruct) + # define PyObject_Init dll__PyObject_Init + # define PyObject_GetIter dll_PyObject_GetIter +--- 214,222 ---- + # define Py_Finalize dll_Py_Finalize + # define Py_IsInitialized dll_Py_IsInitialized + # define _PyObject_New dll__PyObject_New +! # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02070000 +! # define _PyObject_NextNotImplemented (*dll__PyObject_NextNotImplemented) +! # endif + # define _Py_NoneStruct (*dll__Py_NoneStruct) + # define PyObject_Init dll__PyObject_Init + # define PyObject_GetIter dll_PyObject_GetIter +*************** +*** 310,316 **** +--- 312,320 ---- + static PyObject*(*dll__PyObject_New)(PyTypeObject *, PyObject *); + static PyObject*(*dll__PyObject_Init)(PyObject *, PyTypeObject *); + static PyObject* (*dll_PyObject_GetIter)(PyObject *); ++ # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02070000 + static iternextfunc dll__PyObject_NextNotImplemented; ++ # endif + static PyObject* dll__Py_NoneStruct; + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + static int (*dll_PyType_IsSubtype)(PyTypeObject *, PyTypeObject *); +*************** +*** 430,436 **** +--- 434,442 ---- + {"_PyObject_New", (PYTHON_PROC*)&dll__PyObject_New}, + {"PyObject_Init", (PYTHON_PROC*)&dll__PyObject_Init}, + {"PyObject_GetIter", (PYTHON_PROC*)&dll_PyObject_GetIter}, ++ # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02070000 + {"_PyObject_NextNotImplemented", (PYTHON_PROC*)&dll__PyObject_NextNotImplemented}, ++ # endif + {"_Py_NoneStruct", (PYTHON_PROC*)&dll__Py_NoneStruct}, + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + {"PyType_IsSubtype", (PYTHON_PROC*)&dll_PyType_IsSubtype}, +*** ../vim-7.3.582/src/version.c 2012-06-29 23:57:50.000000000 +0200 +--- src/version.c 2012-06-30 13:20:46.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 583, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +90. Instead of calling you to dinner, your spouse sends e-mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e1d7cbfaa895a982d1240576f518b73948b45b6b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:16 +0200 Subject: [PATCH 0328/3340] - patchlevel 584 --- 7.3.584 | 134 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 134 insertions(+) create mode 100644 7.3.584 diff --git a/7.3.584 b/7.3.584 new file mode 100644 index 00000000..d7f1bdeb --- /dev/null +++ b/7.3.584 @@ -0,0 +1,134 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.584 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.584 +Problem: PyCObject is not always defined. +Solution: Use PyObject instead. +Files: src/if_py_both.h, src/if_python.c + + +*** ../vim-7.3.583/src/if_py_both.h 2012-06-29 17:51:58.000000000 +0200 +--- src/if_py_both.h 2012-06-30 13:25:24.000000000 +0200 +*************** +*** 2432,2463 **** + convert_dl(PyObject *obj, typval_T *tv, + pytotvfunc py_to_tv, PyObject *lookupDict) + { +- # ifdef PY_USE_CAPSULE + PyObject *capsule; +- # else +- PyCObject *cobject; +- # endif + char hexBuf[sizeof(void *) * 2 + 3]; + + sprintf(hexBuf, "%p", obj); + + # ifdef PY_USE_CAPSULE + capsule = PyDict_GetItemString(lookupDict, hexBuf); +- if (capsule == NULL) + # else +! cobject = (PyCObject *)PyDict_GetItemString(lookupDict, hexBuf); +! if (cobject == NULL) + # endif + { + # ifdef PY_USE_CAPSULE + capsule = PyCapsule_New(tv, NULL, NULL); +- PyDict_SetItemString(lookupDict, hexBuf, capsule); +- Py_DECREF(capsule); + # else +! cobject = PyCObject_FromVoidPtr(tv, NULL); +! PyDict_SetItemString(lookupDict, hexBuf, cobject); +! Py_DECREF(cobject); + # endif + if (py_to_tv(obj, tv, lookupDict) == -1) + { + tv->v_type = VAR_UNKNOWN; +--- 2432,2456 ---- + convert_dl(PyObject *obj, typval_T *tv, + pytotvfunc py_to_tv, PyObject *lookupDict) + { + PyObject *capsule; + char hexBuf[sizeof(void *) * 2 + 3]; + + sprintf(hexBuf, "%p", obj); + + # ifdef PY_USE_CAPSULE + capsule = PyDict_GetItemString(lookupDict, hexBuf); + # else +! capsule = (PyObject *)PyDict_GetItemString(lookupDict, hexBuf); + # endif ++ if (capsule == NULL) + { + # ifdef PY_USE_CAPSULE + capsule = PyCapsule_New(tv, NULL, NULL); + # else +! capsule = PyCObject_FromVoidPtr(tv, NULL); + # endif ++ PyDict_SetItemString(lookupDict, hexBuf, capsule); ++ Py_DECREF(capsule); + if (py_to_tv(obj, tv, lookupDict) == -1) + { + tv->v_type = VAR_UNKNOWN; +*************** +*** 2478,2484 **** + # ifdef PY_USE_CAPSULE + v = PyCapsule_GetPointer(capsule, NULL); + # else +! v = PyCObject_AsVoidPtr(cobject); + # endif + copy_tv(v, tv); + } +--- 2471,2477 ---- + # ifdef PY_USE_CAPSULE + v = PyCapsule_GetPointer(capsule, NULL); + # else +! v = PyCObject_AsVoidPtr(capsule); + # endif + copy_tv(v, tv); + } +*** ../vim-7.3.583/src/if_python.c 2012-06-30 13:21:03.000000000 +0200 +--- src/if_python.c 2012-06-30 13:23:22.000000000 +0200 +*************** +*** 327,334 **** + static PyObject* (*dll_PyCapsule_New)(void *, char *, PyCapsule_Destructor); + static void* (*dll_PyCapsule_GetPointer)(PyObject *, char *); + # else +! static PyCObject* (*dll_PyCObject_FromVoidPtr)(void *cobj, void (*destr)(void *)); +! static void* (*dll_PyCObject_AsVoidPtr)(PyCObject *); + # endif + + static HINSTANCE hinstPython = 0; /* Instance of python.dll */ +--- 327,334 ---- + static PyObject* (*dll_PyCapsule_New)(void *, char *, PyCapsule_Destructor); + static void* (*dll_PyCapsule_GetPointer)(PyObject *, char *); + # else +! static PyObject* (*dll_PyCObject_FromVoidPtr)(void *cobj, void (*destr)(void *)); +! static void* (*dll_PyCObject_AsVoidPtr)(PyObject *); + # endif + + static HINSTANCE hinstPython = 0; /* Instance of python.dll */ +*** ../vim-7.3.583/src/version.c 2012-06-30 13:21:03.000000000 +0200 +--- src/version.c 2012-06-30 13:33:08.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 584, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +91. It's Saturday afternoon in the middle of May and you + are on computer. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b301d04303137d51da1b5d6b6d808928d3eb5b94 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 2 Jul 2012 11:22:16 +0200 Subject: [PATCH 0329/3340] - patchlevel 584 --- README.patches | 28 ++++++++++++++++++++++ vim.spec | 63 ++++++++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 89 insertions(+), 2 deletions(-) diff --git a/README.patches b/README.patches index c9045377..7bdc9a70 100644 --- a/README.patches +++ b/README.patches @@ -587,3 +587,31 @@ Individual patches for Vim 7.3: 1660 7.3.554 compiler warning for unused argument 7968 7.3.555 building on IBM z/OS fails 2194 7.3.556 compiler warnings on 64 bit Windows + 2958 7.3.557 crash when an autocommand wipes out a buffer when it is hidden + 2956 7.3.558 (after 7.3.552) memory access error + 3483 7.3.559 home_replace() does not work with 8.3 filename + 1551 7.3.560 get an error for a locked argument in extend() + 1511 7.3.561 refresh: always in a complete function breaks the "." command + 1659 7.3.562 ":profdel" works when the +profile feature is disabled + 2742 7.3.563 (after 7.3.557) can't build with tiny features + 1785 7.3.564 (after 7.3.559) warning for pointer conversion + 1806 7.3.565 can't generate proto file for Python 3 + 2363 7.3.566 (after 7.3.561) redo works incorrectly without refresh:always + 1739 7.3.567 missing copyright notice + 3890 7.3.568 bad indents for #ifdefs +133265 7.3.569 evaluating Vim expression in Python is insufficient + 4659 7.3.570 ":vimgrep" does not obey 'wildignore' + 3915 7.3.571 duplicated condition + 1915 7.3.572 duplicate statement in if and else + 1419 7.3.573 using array index before bounds checking + 2491 7.3.574 a CTRL-L character is not pasted on the search command line + 1586 7.3.575 "ygt" tries to yank instead of giving an error + 7301 7.3.576 formatting of lists inside comments is not right yet + 6542 7.3.577 size of memory does not fit in 32 bit unsigned + 2025 7.3.578 misplaced declaration. + 7644 7.3.579 (after 7.3.569) can't compile with Python 2.5 + 1517 7.3.580 warning on 64 bit MS-Windows + 4236 7.3.581 problems compiling with Python + 1342 7.3.582 missing pieces in test OK file + 3125 7.3.583 PyObject_NextNotImplemented is not defined before Python 2.7 + 4088 7.3.584 PyCObject is not always defined diff --git a/vim.spec b/vim.spec index 671cd9fe..3ba7437a 100644 --- a/vim.spec +++ b/vim.spec @@ -18,13 +18,13 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 556 +%define patchlevel 584 Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 2%{?dist} +Release: 1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -612,6 +612,34 @@ Patch553: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.553 Patch554: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.554 Patch555: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.555 Patch556: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.556 +Patch557: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.557 +Patch558: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.558 +Patch559: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.559 +Patch560: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.560 +Patch561: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.561 +Patch562: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.562 +Patch563: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.563 +Patch564: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.564 +Patch565: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.565 +Patch566: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.566 +Patch567: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.567 +Patch568: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.568 +Patch569: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.569 +Patch570: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.570 +Patch571: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.571 +Patch572: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.572 +Patch573: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.573 +Patch574: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.574 +Patch575: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.575 +Patch576: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.576 +Patch577: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.577 +Patch578: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.578 +Patch579: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.579 +Patch580: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.580 +Patch581: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.581 +Patch582: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.582 +Patch583: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.583 +Patch584: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.584 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1314,6 +1342,34 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch554 -p0 %patch555 -p0 %patch556 -p0 +%patch557 -p0 +%patch558 -p0 +%patch559 -p0 +%patch560 -p0 +%patch561 -p0 +%patch562 -p0 +%patch563 -p0 +%patch564 -p0 +%patch565 -p0 +%patch566 -p0 +%patch567 -p0 +%patch568 -p0 +%patch569 -p0 +%patch570 -p0 +%patch571 -p0 +%patch572 -p0 +%patch573 -p0 +%patch574 -p0 +%patch575 -p0 +%patch576 -p0 +%patch577 -p0 +%patch578 -p0 +%patch579 -p0 +%patch580 -p0 +%patch581 -p0 +%patch582 -p0 +%patch583 -p0 +%patch584 -p0 # install spell files @@ -1770,6 +1826,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Jul 02 2012 Karsten Hopp 7.3.584-1 +- patchlevel 584 + * Thu Jun 28 2012 Petr Pisar - 2:7.3.556-2 - Perl 5.16 rebuild From 01d20bd568195b853bdd7ab0e581bd58062c2d45 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= Date: Mon, 9 Jul 2012 17:16:09 +0200 Subject: [PATCH 0330/3340] Perl 5.16 rebuild --- vim.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vim.spec b/vim.spec index 3ba7437a..c5d3a3f0 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1%{?dist} +Release: 2%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -1826,6 +1826,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Jul 09 2012 Petr Pisar - 2:7.3.584-2 +- Perl 5.16 rebuild + * Mon Jul 02 2012 Karsten Hopp 7.3.584-1 - patchlevel 584 From 5e20649bdb9863658cf541ff0b0ed456d74d3698 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 10 Jul 2012 13:48:56 +0200 Subject: [PATCH 0331/3340] - patchlevel 585 --- 7.3.585 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.585 diff --git a/7.3.585 b/7.3.585 new file mode 100644 index 00000000..6509780c --- /dev/null +++ b/7.3.585 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.585 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.585 +Problem: Calling changed_bytes() too often. +Solution: Move changed_bytes() out of a loop. (Tor Perkins) +Files: src/edit.c + + +*** ../vim-7.3.584/src/edit.c 2012-06-29 15:04:34.000000000 +0200 +--- src/edit.c 2012-07-06 13:29:25.000000000 +0200 +*************** +*** 6350,6359 **** + * add the additional whitespace needed after the + * comment leader for the numbered list. */ + for (i = 0; i < padding; i++) +- { + ins_str((char_u *)" "); +! changed_bytes(curwin->w_cursor.lnum, leader_len); +! } + } + else + { +--- 6350,6357 ---- + * add the additional whitespace needed after the + * comment leader for the numbered list. */ + for (i = 0; i < padding; i++) + ins_str((char_u *)" "); +! changed_bytes(curwin->w_cursor.lnum, leader_len); + } + else + { +*** ../vim-7.3.584/src/version.c 2012-07-06 13:36:02.000000000 +0200 +--- src/version.c 2012-07-06 13:35:03.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 585, + /**/ + +-- +From "know your smileys": + :'-D Laughing so much that they're crying + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a43ee84194f1e1e61c944d49686e36b6b3ed34da Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 10 Jul 2012 13:48:56 +0200 Subject: [PATCH 0332/3340] - patchlevel 586 --- 7.3.586 | 103 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 103 insertions(+) create mode 100644 7.3.586 diff --git a/7.3.586 b/7.3.586 new file mode 100644 index 00000000..889ebd13 --- /dev/null +++ b/7.3.586 @@ -0,0 +1,103 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.586 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.586 +Problem: When compiling with Cygwin or MingW MEMORYSTATUSEX is not defined. +Solution: Set the default for WINVER to 0x0500. +Files: src/Make_ming.mak, src/Make_cyg.mak + + +*** ../vim-7.3.585/src/Make_ming.mak 2012-04-20 16:13:21.000000000 +0200 +--- src/Make_ming.mak 2012-06-30 21:23:55.000000000 +0200 +*************** +*** 52,58 **** + OLE=no + # Set the default $(WINVER) to make it work with pre-Win2k + ifndef WINVER +! WINVER = 0x0400 + endif + # Set to yes to enable Cscope support + CSCOPE=yes +--- 52,58 ---- + OLE=no + # Set the default $(WINVER) to make it work with pre-Win2k + ifndef WINVER +! WINVER = 0x0500 + endif + # Set to yes to enable Cscope support + CSCOPE=yes +*** ../vim-7.3.585/src/Make_cyg.mak 2011-09-30 16:56:00.000000000 +0200 +--- src/Make_cyg.mak 2012-06-30 21:23:42.000000000 +0200 +*************** +*** 1,6 **** + # + # Makefile for VIM on Win32, using Cygnus gcc +! # Last updated by Dan Sharp. Last Change: 2010 Nov 03 + # + # Also read INSTALLpc.txt! + # +--- 1,6 ---- + # + # Makefile for VIM on Win32, using Cygnus gcc +! # Last updated by Dan Sharp. Last Change: 2012 Jun 30 + # + # Also read INSTALLpc.txt! + # +*************** +*** 48,54 **** + # -L/lib/w32api to EXTRA_LIBS. + # POSTSCRIPT no or yes: set to yes for PostScript printing (no) + # FEATURES TINY, SMALL, NORMAL, BIG or HUGE (BIG) +! # WINVER Lowest Win32 version to support. (0x0400) + # CSCOPE no or yes: to include cscope interface support (yes) + # OPTIMIZE SPACE, SPEED, or MAXSPEED: set optimization level (MAXSPEED) + # NETBEANS no or yes: to include netbeans interface support (yes when GUI +--- 48,54 ---- + # -L/lib/w32api to EXTRA_LIBS. + # POSTSCRIPT no or yes: set to yes for PostScript printing (no) + # FEATURES TINY, SMALL, NORMAL, BIG or HUGE (BIG) +! # WINVER Lowest Win32 version to support. (0x0500) + # CSCOPE no or yes: to include cscope interface support (yes) + # OPTIMIZE SPACE, SPEED, or MAXSPEED: set optimization level (MAXSPEED) + # NETBEANS no or yes: to include netbeans interface support (yes when GUI +*************** +*** 85,91 **** + endif + + ifndef WINVER +! WINVER = 0x0400 + endif + + ifndef CSCOPE +--- 85,91 ---- + endif + + ifndef WINVER +! WINVER = 0x0500 + endif + + ifndef CSCOPE +*** ../vim-7.3.585/src/version.c 2012-07-06 13:36:36.000000000 +0200 +--- src/version.c 2012-07-06 13:39:41.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 586, + /**/ + +-- +From "know your smileys": + :-& Eating spaghetti + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e94e232d6a17003c39adc3e15d065a1cf3631dd8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 10 Jul 2012 13:48:57 +0200 Subject: [PATCH 0333/3340] - patchlevel 587 --- 7.3.587 | 84 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 7.3.587 diff --git a/7.3.587 b/7.3.587 new file mode 100644 index 00000000..22252318 --- /dev/null +++ b/7.3.587 @@ -0,0 +1,84 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.587 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.587 +Problem: Compiler warning for local var shadowing global var. +Solution: Rename the var and move it to an inner block. (Christian Brabandt) +Files: src/buffer.c + + +*** ../vim-7.3.586/src/buffer.c 2012-06-20 17:54:34.000000000 +0200 +--- src/buffer.c 2012-07-06 16:19:32.000000000 +0200 +*************** +*** 1363,1371 **** + int action; + { + buf_T *prevbuf; +- #ifdef FEAT_WINDOWS +- win_T *prevwin; +- #endif + int unload = (action == DOBUF_UNLOAD || action == DOBUF_DEL + || action == DOBUF_WIPE); + +--- 1363,1368 ---- +*************** +*** 1406,1412 **** + #endif + { + #ifdef FEAT_WINDOWS +! prevwin = curwin; + #endif + if (prevbuf == curbuf) + u_sync(FALSE); +--- 1403,1409 ---- + #endif + { + #ifdef FEAT_WINDOWS +! win_T *previouswin = curwin; + #endif + if (prevbuf == curbuf) + u_sync(FALSE); +*************** +*** 1415,1423 **** + && !P_HID(prevbuf) + && !bufIsChanged(prevbuf)) ? DOBUF_UNLOAD : 0, FALSE); + #ifdef FEAT_WINDOWS +! if (curwin != prevwin && win_valid(prevwin)) + /* autocommands changed curwin, Grr! */ +! curwin = prevwin; + #endif + } + } +--- 1412,1420 ---- + && !P_HID(prevbuf) + && !bufIsChanged(prevbuf)) ? DOBUF_UNLOAD : 0, FALSE); + #ifdef FEAT_WINDOWS +! if (curwin != previouswin && win_valid(previouswin)) + /* autocommands changed curwin, Grr! */ +! curwin = previouswin; + #endif + } + } +*** ../vim-7.3.586/src/version.c 2012-07-06 13:40:44.000000000 +0200 +--- src/version.c 2012-07-06 16:19:08.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 587, + /**/ + +-- +There's no place like $(HOME)! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5631075c461401bcd3f9355874f97086205af631 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 10 Jul 2012 13:48:57 +0200 Subject: [PATCH 0334/3340] - patchlevel 588 --- 7.3.588 | 85 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100644 7.3.588 diff --git a/7.3.588 b/7.3.588 new file mode 100644 index 00000000..6dfabd07 --- /dev/null +++ b/7.3.588 @@ -0,0 +1,85 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.588 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.588 +Problem: Crash on NULL pointer. +Solution: Fix the immediate problem by checking for NULL. (Lech Lorens) +Files: src/window.c + + +*** ../vim-7.3.587/src/window.c 2012-06-13 18:15:13.000000000 +0200 +--- src/window.c 2012-07-06 16:32:59.000000000 +0200 +*************** +*** 2184,2190 **** + } + + #ifdef FEAT_AUTOCMD +! if (win->w_closing || win->w_buffer->b_closing) + return; /* window is already being closed */ + if (win == aucmd_win) + { +--- 2184,2190 ---- + } + + #ifdef FEAT_AUTOCMD +! if (win->w_closing || (win->w_buffer != NULL && win->w_buffer->b_closing)) + return; /* window is already being closed */ + if (win == aucmd_win) + { +*************** +*** 3723,3729 **** + enter_tabpage(tp, old_curbuf, trigger_autocmds) + tabpage_T *tp; + buf_T *old_curbuf UNUSED; +! int trigger_autocmds UNUSED; + { + int old_off = tp->tp_firstwin->w_winrow; + win_T *next_prevwin = tp->tp_prevwin; +--- 3723,3729 ---- + enter_tabpage(tp, old_curbuf, trigger_autocmds) + tabpage_T *tp; + buf_T *old_curbuf UNUSED; +! int trigger_autocmds UNUSED; + { + int old_off = tp->tp_firstwin->w_winrow; + win_T *next_prevwin = tp->tp_prevwin; +*************** +*** 3868,3874 **** + void + goto_tabpage_tp(tp, trigger_autocmds) + tabpage_T *tp; +! int trigger_autocmds; + { + /* Don't repeat a message in another tab page. */ + set_keep_msg(NULL, 0); +--- 3868,3874 ---- + void + goto_tabpage_tp(tp, trigger_autocmds) + tabpage_T *tp; +! int trigger_autocmds; + { + /* Don't repeat a message in another tab page. */ + set_keep_msg(NULL, 0); +*** ../vim-7.3.587/src/version.c 2012-07-06 16:21:58.000000000 +0200 +--- src/version.c 2012-07-06 16:37:47.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 588, + /**/ + +-- +Momento mori, ergo carpe diem + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a5ba911ce95a2ab0031f33770cf28bb4f44cb09c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 10 Jul 2012 13:48:57 +0200 Subject: [PATCH 0335/3340] - patchlevel 589 --- 7.3.589 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.589 diff --git a/7.3.589 b/7.3.589 new file mode 100644 index 00000000..fdda2b95 --- /dev/null +++ b/7.3.589 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.589 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.589 +Problem: Crash when $HOME is not set. +Solution: Check for a NULL pointer. (Chris Webb) +Files: src/misc1.c + + +*** ../vim-7.3.588/src/misc1.c 2012-06-29 15:04:34.000000000 +0200 +--- src/misc1.c 2012-07-06 16:44:39.000000000 +0200 +*************** +*** 4496,4503 **** + #else + homedir_env_orig = homedir_env = mch_getenv((char_u *)"HOME"); + #endif + #if defined(FEAT_MODIFY_FNAME) || defined(WIN3264) +! if (vim_strchr(homedir_env, '~') != NULL) + { + int usedlen = 0; + int flen; +--- 4496,4507 ---- + #else + homedir_env_orig = homedir_env = mch_getenv((char_u *)"HOME"); + #endif ++ /* Empty is the same as not set. */ ++ if (homedir_env != NULL && *homedir_env == NUL) ++ homedir_env = NULL; ++ + #if defined(FEAT_MODIFY_FNAME) || defined(WIN3264) +! if (homedir_env != NULL && vim_strchr(homedir_env, '~') != NULL) + { + int usedlen = 0; + int flen; +*************** +*** 4513,4520 **** + } + #endif + +- if (homedir_env != NULL && *homedir_env == NUL) +- homedir_env = NULL; + if (homedir_env != NULL) + envlen = STRLEN(homedir_env); + +--- 4517,4522 ---- +*** ../vim-7.3.588/src/version.c 2012-07-06 16:39:43.000000000 +0200 +--- src/version.c 2012-07-06 16:45:18.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 589, + /**/ + +-- +I AM THANKFUL... +...for the taxes that I pay because it means that I am employed. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 717400180a51acb3ce487daceb4a928bdfdf8aa3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 10 Jul 2012 13:49:01 +0200 Subject: [PATCH 0336/3340] - patchlevel 590 --- 7.3.590 | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 7.3.590 diff --git a/7.3.590 b/7.3.590 new file mode 100644 index 00000000..4e524f79 --- /dev/null +++ b/7.3.590 @@ -0,0 +1,61 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.590 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.590 +Problem: The '< and '> marks cannot be set directly. +Solution: Allow setting '< and '>. (Christian Brabandt) +Files: src/mark.c + + +*** ../vim-7.3.589/src/mark.c 2011-02-25 15:11:17.000000000 +0100 +--- src/mark.c 2012-07-06 17:47:23.000000000 +0200 +*************** +*** 98,103 **** +--- 98,116 ---- + return OK; + } + ++ #ifdef FEAT_VISUAL ++ if (c == '<') ++ { ++ curbuf->b_visual.vi_start = *pos; ++ return OK; ++ } ++ if (c == '>') ++ { ++ curbuf->b_visual.vi_end = *pos; ++ return OK; ++ } ++ #endif ++ + #ifndef EBCDIC + if (c > 'z') /* some islower() and isupper() cannot handle + characters above 127 */ +*** ../vim-7.3.589/src/version.c 2012-07-06 16:49:37.000000000 +0200 +--- src/version.c 2012-07-06 17:49:00.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 590, + /**/ + +-- +The primary purpose of the DATA statement is to give names to constants; +instead of referring to pi as 3.141592653589793 at every appearance, the +variable PI can be given that value with a DATA statement and used instead +of the longer form of the constant. This also simplifies modifying the +program, should the value of pi change. + -- FORTRAN manual for Xerox Computers + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a64b1849a58dd4cf035e0016a062915341c7b5ac Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 10 Jul 2012 13:49:01 +0200 Subject: [PATCH 0337/3340] - patchlevel 591 --- 7.3.591 | 208 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 208 insertions(+) create mode 100644 7.3.591 diff --git a/7.3.591 b/7.3.591 new file mode 100644 index 00000000..180fe608 --- /dev/null +++ b/7.3.591 @@ -0,0 +1,208 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.591 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.591 +Problem: Can only move to a tab by absolute number. +Solution: Move a number of tabs to the left or the right. (Lech Lorens) +Files: runtime/doc/tabpage.txt, src/ex_cmds.h, src/ex_docmd.c, + src/testdir/test62.in, src/testdir/test62.ok, src/window.c + + +*** ../vim-7.3.590/runtime/doc/tabpage.txt 2010-08-15 21:57:17.000000000 +0200 +--- runtime/doc/tabpage.txt 2012-07-06 18:10:06.000000000 +0200 +*************** +*** 173,182 **** +--- 173,192 ---- + REORDERING TAB PAGES: + + :tabm[ove] [N] *:tabm* *:tabmove* ++ :[N]tabm[ove] + Move the current tab page to after tab page N. Use zero to + make the current tab page the first one. Without N the tab + page is made the last one. + ++ :tabm[ove] +[N] ++ :tabm[ove] -[N] ++ Move the current tab page N places to the right (with +) or to ++ the left (with -). ++ ++ Note that although it is possible to move a tab behind the N-th one by using ++ :Ntabmove, it is impossible to move it by N places by using :+Ntabmove. For ++ clarification what +N means in this context see |[range]|. ++ + + LOOPING OVER TAB PAGES: + +*** ../vim-7.3.590/src/ex_cmds.h 2012-05-18 18:47:11.000000000 +0200 +--- src/ex_cmds.h 2012-07-06 18:10:13.000000000 +0200 +*************** +*** 944,950 **** + EX(CMD_tabfirst, "tabfirst", ex_tabnext, + TRLBAR), + EX(CMD_tabmove, "tabmove", ex_tabmove, +! RANGE|NOTADR|ZEROR|COUNT|TRLBAR|ZEROR), + EX(CMD_tablast, "tablast", ex_tabnext, + TRLBAR), + EX(CMD_tabnext, "tabnext", ex_tabnext, +--- 944,950 ---- + EX(CMD_tabfirst, "tabfirst", ex_tabnext, + TRLBAR), + EX(CMD_tabmove, "tabmove", ex_tabmove, +! RANGE|NOTADR|ZEROR|EXTRA|NOSPC|TRLBAR), + EX(CMD_tablast, "tablast", ex_tabnext, + TRLBAR), + EX(CMD_tabnext, "tabnext", ex_tabnext, +*** ../vim-7.3.590/src/ex_docmd.c 2012-06-06 19:02:40.000000000 +0200 +--- src/ex_docmd.c 2012-07-06 18:16:25.000000000 +0200 +*************** +*** 7478,7484 **** + ex_tabmove(eap) + exarg_T *eap; + { +! tabpage_move(eap->addr_count == 0 ? 9999 : (int)eap->line2); + } + + /* +--- 7478,7519 ---- + ex_tabmove(eap) + exarg_T *eap; + { +! int tab_number = 9999; +! +! if (eap->arg && *eap->arg != NUL) +! { +! char_u *p = eap->arg; +! int relative = 0; /* argument +N/-N means: move N places to the +! * right/left relative to the current position. */ +! +! if (*eap->arg == '-') +! { +! relative = -1; +! p = eap->arg + 1; +! } +! else if (*eap->arg == '+') +! { +! relative = 1; +! p = eap->arg + 1; +! } +! else +! p = eap->arg; +! +! if (p == skipdigits(p)) +! { +! /* No numbers as argument. */ +! eap->errmsg = e_invarg; +! return; +! } +! +! tab_number = getdigits(&p); +! if (relative != 0) +! tab_number = tab_number * relative + tabpage_index(curtab) - 1;; +! } +! else if (eap->addr_count != 0) +! tab_number = eap->line2; +! +! tabpage_move(tab_number); + } + + /* +*** ../vim-7.3.590/src/testdir/test62.in 2012-03-07 22:55:17.000000000 +0100 +--- src/testdir/test62.in 2012-07-06 18:10:13.000000000 +0200 +*************** +*** 93,98 **** +--- 93,126 ---- + :endif + :" + :" ++ :for i in range(9) | tabnew | endfor ++ 1gt ++ Go=tabpagenr()  ++ :tabmove 5 ++ i=tabpagenr()  ++ :tabmove -2 ++ i=tabpagenr()  ++ :tabmove +4 ++ i=tabpagenr()  ++ :tabmove ++ i=tabpagenr()  ++ :tabmove -20 ++ i=tabpagenr()  ++ :tabmove +20 ++ i=tabpagenr()  ++ :3tabmove ++ i=tabpagenr()  ++ :7tabmove 5 ++ i=tabpagenr()  ++ :let a='No error caught.' ++ :try ++ :tabmove foo ++ :catch E474 ++ :let a='E474 caught.' ++ :endtry ++ i=a  ++ :" ++ :" + :/^Results/,$w! test.out + :qa! + ENDTEST +*** ../vim-7.3.590/src/testdir/test62.ok 2012-02-22 19:13:00.000000000 +0100 +--- src/testdir/test62.ok 2012-07-06 18:10:13.000000000 +0200 +*************** +*** 8,10 **** +--- 8,20 ---- + tab drop 1: pass + tab drop 2: pass + tab drop 3: pass ++ 1 ++ 6 ++ 4 ++ 8 ++ 10 ++ 1 ++ 10 ++ 4 ++ 6 ++ E474 caught. +*** ../vim-7.3.590/src/window.c 2012-07-06 16:39:43.000000000 +0200 +--- src/window.c 2012-07-06 18:10:13.000000000 +0200 +*************** +*** 3929,3935 **** + } + + /* Re-insert it at the specified position. */ +! if (n == 0) + { + curtab->tp_next = first_tabpage; + first_tabpage = curtab; +--- 3929,3935 ---- + } + + /* Re-insert it at the specified position. */ +! if (n <= 0) + { + curtab->tp_next = first_tabpage; + first_tabpage = curtab; +*** ../vim-7.3.590/src/version.c 2012-07-06 17:51:24.000000000 +0200 +--- src/version.c 2012-07-06 18:11:08.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 591, + /**/ + +-- +Bare feet magnetize sharp metal objects so they point upward from the +floor -- especially in the dark. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c54fbd2637e1bb182d923dcdfa7a8e14e8c29949 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 10 Jul 2012 13:49:02 +0200 Subject: [PATCH 0338/3340] - patchlevel 592 --- 7.3.592 | 126 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 126 insertions(+) create mode 100644 7.3.592 diff --git a/7.3.592 b/7.3.592 new file mode 100644 index 00000000..be13ef74 --- /dev/null +++ b/7.3.592 @@ -0,0 +1,126 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.592 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.592 +Problem: Vim on GTK does not support g:browsefilter. +Solution: Add a GtkFileFilter to the file chooser. (Christian Brabandt) +Files: src/gui_gtk.c + + +*** ../vim-7.3.591/src/gui_gtk.c 2012-06-06 16:14:36.000000000 +0200 +--- src/gui_gtk.c 2012-07-10 13:08:06.000000000 +0200 +*************** +*** 840,846 **** + char_u *dflt, + char_u *ext UNUSED, + char_u *initdir, +! char_u *filter UNUSED) + { + #ifdef USE_FILE_CHOOSER + GtkWidget *fc; +--- 840,846 ---- + char_u *dflt, + char_u *ext UNUSED, + char_u *initdir, +! char_u *filter) + { + #ifdef USE_FILE_CHOOSER + GtkWidget *fc; +*************** +*** 848,853 **** +--- 848,854 ---- + char_u dirbuf[MAXPATHL]; + guint log_handler; + const gchar *domain = "Gtk"; ++ GtkFileFilter *gfilter; + + title = CONVERT_TO_UTF8(title); + +*************** +*** 879,884 **** +--- 880,924 ---- + NULL); + gtk_file_chooser_set_current_folder(GTK_FILE_CHOOSER(fc), + (const gchar *)dirbuf); ++ ++ if (filter != NULL && *filter != NUL) ++ { ++ int i = 0; ++ char_u *patt; ++ char_u *p = filter; ++ ++ gfilter = gtk_file_filter_new(); ++ patt = alloc(STRLEN(filter)); ++ while (p != NULL && *p != NUL) ++ { ++ if (*p == '\n' || *p == ';' || *p == '\t') ++ { ++ STRNCPY(patt, filter, i); ++ patt[i] = '\0'; ++ if (*p == '\t') ++ gtk_file_filter_set_name(gfilter, (gchar *)patt); ++ else ++ { ++ gtk_file_filter_add_pattern(gfilter, (gchar *)patt); ++ if (*p == '\n') ++ { ++ gtk_file_chooser_add_filter((GtkFileChooser *)fc, ++ gfilter); ++ if (*(p + 1) != NUL) ++ gfilter = gtk_file_filter_new(); ++ } ++ } ++ filter = ++p; ++ i = 0; ++ } ++ else ++ { ++ p++; ++ i++; ++ } ++ } ++ vim_free(patt); ++ } + if (saving && dflt != NULL && *dflt != NUL) + gtk_file_chooser_set_current_name(GTK_FILE_CHOOSER(fc), (char *)dflt); + +*************** +*** 1304,1310 **** + gtk_widget_show(entry); + + /* Make Enter work like pressing OK. */ +! gtk_entry_set_activates_default(GTK_ENTRY(entry), TRUE); + + text = CONVERT_TO_UTF8(textfield); + gtk_entry_set_text(GTK_ENTRY(entry), (const char *)text); +--- 1344,1350 ---- + gtk_widget_show(entry); + + /* Make Enter work like pressing OK. */ +! gtk_entry_set_activates_default(GTK_ENTRY(entry), TRUE); + + text = CONVERT_TO_UTF8(textfield); + gtk_entry_set_text(GTK_ENTRY(entry), (const char *)text); +*** ../vim-7.3.591/src/version.c 2012-07-06 18:27:34.000000000 +0200 +--- src/version.c 2012-07-10 13:00:29.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 592, + /**/ + +-- +To be rich is not the end, but only a change of worries. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6f0e696bd31236099d4b17a3255bb66f58ee45c8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 10 Jul 2012 13:49:02 +0200 Subject: [PATCH 0339/3340] - patchlevel 592 --- README.patches | 8 ++++++++ vim.spec | 23 +++++++++++++++++++++-- 2 files changed, 29 insertions(+), 2 deletions(-) diff --git a/README.patches b/README.patches index 7bdc9a70..4be0aa9b 100644 --- a/README.patches +++ b/README.patches @@ -615,3 +615,11 @@ Individual patches for Vim 7.3: 1342 7.3.582 missing pieces in test OK file 3125 7.3.583 PyObject_NextNotImplemented is not defined before Python 2.7 4088 7.3.584 PyCObject is not always defined + 1696 7.3.585 calling changed_bytes() too often + 3055 7.3.586 MEMORYSTATUSEX not defined when compiling with Cygwin or MingW + 2248 7.3.587 compiler warning for local var shadowing global var + 2464 7.3.588 crash on NULL pointer + 1974 7.3.589 crash when $HOME is not set + 1804 7.3.590 the '< and '> marks cannot be set directly + 5247 7.3.591 can only move to a tab by absolute number + 3343 7.3.592 Vim on GTK does not support g:browsefilter diff --git a/vim.spec b/vim.spec index c5d3a3f0..303c1039 100644 --- a/vim.spec +++ b/vim.spec @@ -18,13 +18,13 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 584 +%define patchlevel 592 Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 2%{?dist} +Release: 1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -640,6 +640,14 @@ Patch581: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.581 Patch582: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.582 Patch583: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.583 Patch584: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.584 +Patch585: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.585 +Patch586: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.586 +Patch587: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.587 +Patch588: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.588 +Patch589: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.589 +Patch590: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.590 +Patch591: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.591 +Patch592: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.592 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1370,6 +1378,14 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch582 -p0 %patch583 -p0 %patch584 -p0 +%patch585 -p0 +%patch586 -p0 +%patch587 -p0 +%patch588 -p0 +%patch589 -p0 +%patch590 -p0 +%patch591 -p0 +%patch592 -p0 # install spell files @@ -1826,6 +1842,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Tue Jul 10 2012 Karsten Hopp 7.3.592-1 +- patchlevel 592 + * Mon Jul 09 2012 Petr Pisar - 2:7.3.584-2 - Perl 5.16 rebuild From ecceb619feed0245fd68e4a17e3d723ff5ce8811 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 10 Jul 2012 14:28:13 +0200 Subject: [PATCH 0340/3340] - patchlevel 593 --- 7.3.593 | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 7.3.593 diff --git a/7.3.593 b/7.3.593 new file mode 100644 index 00000000..b8f26748 --- /dev/null +++ b/7.3.593 @@ -0,0 +1,81 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.593 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.593 +Problem: No easy way to decide if b:browsefilter will work. +Solution: Add the browsefilter feature. +Files: src/gui_gtk.c, src/eval.c, src/vim.h + + +*** ../vim-7.3.592/src/gui_gtk.c 2012-07-10 13:12:46.000000000 +0200 +--- src/gui_gtk.c 2012-07-10 13:40:38.000000000 +0200 +*************** +*** 779,787 **** + /* + * Implementation of the file selector related stuff + */ +- #if GTK_CHECK_VERSION(2,4,0) +- # define USE_FILE_CHOOSER +- #endif + + #ifndef USE_FILE_CHOOSER + static void +--- 779,784 ---- +*** ../vim-7.3.592/src/eval.c 2012-06-29 12:54:32.000000000 +0200 +--- src/eval.c 2012-07-10 13:34:10.000000000 +0200 +*************** +*** 12044,12049 **** +--- 12044,12054 ---- + "all_builtin_terms", + # endif + #endif ++ #if defined(FEAT_BROWSE) && (defined(USE_FILE_CHOOSER) \ ++ || defined(FEAT_GUI_W32) \ ++ || defined(FEAT_GUI_MOTIF)) ++ "browsefilter", ++ #endif + #ifdef FEAT_BYTEOFF + "byte_offset", + #endif +*** ../vim-7.3.592/src/vim.h 2012-06-13 17:28:51.000000000 +0200 +--- src/vim.h 2012-07-10 13:30:44.000000000 +0200 +*************** +*** 2125,2130 **** +--- 2125,2136 ---- + # endif + #endif + ++ #if defined(FEAT_BROWSE) && defined(GTK_CHECK_VERSION) ++ # if GTK_CHECK_VERSION(2,4,0) ++ # define USE_FILE_CHOOSER ++ # endif ++ #endif ++ + #ifndef FEAT_NETBEANS_INTG + # undef NBDEBUG + #endif +*** ../vim-7.3.592/src/version.c 2012-07-10 13:12:46.000000000 +0200 +--- src/version.c 2012-07-10 13:34:50.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 593, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +102. When filling out your driver's license application, you give + your IP address. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b948c81154d3aeff010033ecb88c51488d91abc7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 10 Jul 2012 14:28:13 +0200 Subject: [PATCH 0341/3340] - patchlevel 594 --- 7.3.594 | 171 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 171 insertions(+) create mode 100644 7.3.594 diff --git a/7.3.594 b/7.3.594 new file mode 100644 index 00000000..3f7d3b26 --- /dev/null +++ b/7.3.594 @@ -0,0 +1,171 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.594 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.594 +Problem: The X command server doesn't work perfectly. It sends an empty + reply for as-keys requests. +Solution: Remove duplicate ga_init2(). Do not send a reply for as-keys + requests. (Brian Burns) +Files: src/if_xcmdsrv.c + + +*** ../vim-7.3.593/src/if_xcmdsrv.c 2010-08-15 21:57:27.000000000 +0200 +--- src/if_xcmdsrv.c 2012-07-10 14:15:59.000000000 +0200 +*************** +*** 655,661 **** + if (SendInit(dpy) < 0) + return NULL; + } +- ga_init2(&ga, 1, 100); + + /* + * Read the registry property. +--- 655,660 ---- +*************** +*** 1198,1206 **** + if ((*p == 'c' || *p == 'k') && (p[1] == 0)) + { + Window resWindow; +! char_u *name, *script, *serial, *end, *res; + Bool asKeys = *p == 'k'; +- garray_T reply; + char_u *enc; + + /* +--- 1197,1204 ---- + if ((*p == 'c' || *p == 'k') && (p[1] == 0)) + { + Window resWindow; +! char_u *name, *script, *serial, *end; + Bool asKeys = *p == 'k'; + char_u *enc; + + /* +*************** +*** 1256,1305 **** + if (script == NULL || name == NULL) + continue; + +! /* +! * Initialize the result property, so that we're ready at any +! * time if we need to return an error. +! */ +! if (resWindow != None) +! { +! ga_init2(&reply, 1, 100); + #ifdef FEAT_MBYTE +! ga_grow(&reply, 50 + STRLEN(p_enc)); +! sprintf(reply.ga_data, "%cr%c-E %s%c-s %s%c-r ", + 0, 0, p_enc, 0, serial, 0); +! reply.ga_len = 14 + STRLEN(p_enc) + STRLEN(serial); + #else +! ga_grow(&reply, 50); +! sprintf(reply.ga_data, "%cr%c-s %s%c-r ", 0, 0, serial, 0); +! reply.ga_len = 10 + STRLEN(serial); + #endif +! } +! res = NULL; +! if (serverName != NULL && STRICMP(name, serverName) == 0) +! { +! script = serverConvert(enc, script, &tofree); +! if (asKeys) +! server_to_input_buf(script); +! else +! res = eval_client_expr_to_string(script); +! vim_free(tofree); +! } +! if (resWindow != None) +! { +! if (res != NULL) +! ga_concat(&reply, res); +! else if (asKeys == 0) +! { +! ga_concat(&reply, (char_u *)_(e_invexprmsg)); +! ga_append(&reply, 0); +! ga_concat(&reply, (char_u *)"-c 1"); +! } +! ga_append(&reply, NUL); +! (void)AppendPropCarefully(dpy, resWindow, commProperty, +! reply.ga_data, reply.ga_len); +! ga_clear(&reply); +! } +! vim_free(res); + } + else if (*p == 'r' && p[1] == 0) + { +--- 1254,1305 ---- + if (script == NULL || name == NULL) + continue; + +! if (serverName != NULL && STRICMP(name, serverName) == 0) +! { +! script = serverConvert(enc, script, &tofree); +! if (asKeys) +! server_to_input_buf(script); +! else +! { +! char_u *res; +! +! res = eval_client_expr_to_string(script); +! if (resWindow != None) +! { +! garray_T reply; +! +! /* Initialize the result property. */ +! ga_init2(&reply, 1, 100); + #ifdef FEAT_MBYTE +! ga_grow(&reply, 50 + STRLEN(p_enc)); +! sprintf(reply.ga_data, "%cr%c-E %s%c-s %s%c-r ", + 0, 0, p_enc, 0, serial, 0); +! reply.ga_len = 14 + STRLEN(p_enc) + STRLEN(serial); + #else +! ga_grow(&reply, 50); +! sprintf(reply.ga_data, "%cr%c-s %s%c-r ", +! 0, 0, serial, 0); +! reply.ga_len = 10 + STRLEN(serial); + #endif +! +! /* Evaluate the expression and return the result. */ +! if (res != NULL) +! ga_concat(&reply, res); +! else +! { +! ga_concat(&reply, (char_u *)_(e_invexprmsg)); +! ga_append(&reply, 0); +! ga_concat(&reply, (char_u *)"-c 1"); +! } +! ga_append(&reply, NUL); +! (void)AppendPropCarefully(dpy, resWindow, commProperty, +! reply.ga_data, reply.ga_len); +! ga_clear(&reply); +! } +! vim_free(res); +! } +! vim_free(tofree); +! } + } + else if (*p == 'r' && p[1] == 0) + { +*** ../vim-7.3.593/src/version.c 2012-07-10 13:41:09.000000000 +0200 +--- src/version.c 2012-07-10 14:17:50.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 594, + /**/ + +-- +A meeting is an event at which the minutes are kept and the hours are lost. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2df84279c47e27ddc6b0716c50a312943eb68b7b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 10 Jul 2012 14:28:14 +0200 Subject: [PATCH 0342/3340] - patchlevel 594 --- README.patches | 2 ++ vim.spec | 9 ++++++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index 4be0aa9b..0d49d907 100644 --- a/README.patches +++ b/README.patches @@ -623,3 +623,5 @@ Individual patches for Vim 7.3: 1804 7.3.590 the '< and '> marks cannot be set directly 5247 7.3.591 can only move to a tab by absolute number 3343 7.3.592 Vim on GTK does not support g:browsefilter + 2237 7.3.593 no easy way to decide if b:browsefilter will work + 4873 7.3.594 the X command server sends an empty reply for as-keys requests diff --git a/vim.spec b/vim.spec index 303c1039..fb33ca5b 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 592 +%define patchlevel 594 Summary: The VIM editor URL: http://www.vim.org/ @@ -648,6 +648,8 @@ Patch589: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.589 Patch590: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.590 Patch591: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.591 Patch592: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.592 +Patch593: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.593 +Patch594: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.594 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1386,6 +1388,8 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch590 -p0 %patch591 -p0 %patch592 -p0 +%patch593 -p0 +%patch594 -p0 # install spell files @@ -1842,6 +1846,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Tue Jul 10 2012 Karsten Hopp 7.3.594-1 +- patchlevel 594 + * Tue Jul 10 2012 Karsten Hopp 7.3.592-1 - patchlevel 592 From 1e5db4ab93f598a779361816460746df1799cbc2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= Date: Wed, 11 Jul 2012 11:25:10 +0200 Subject: [PATCH 0343/3340] Perl 5.16 rebuild --- vim.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vim.spec b/vim.spec index fb33ca5b..df600176 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1%{?dist} +Release: 2%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -1846,6 +1846,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Wed Jul 11 2012 Petr Pisar - 2:7.3.594-2 +- Perl 5.16 rebuild + * Tue Jul 10 2012 Karsten Hopp 7.3.594-1 - patchlevel 594 From 9a4b3f454f136dad09b463e79e459116a5d374d5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 18 Jul 2012 10:58:05 +0200 Subject: [PATCH 0344/3340] - patchlevel 595 --- 7.3.595 | 154 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 154 insertions(+) create mode 100644 7.3.595 diff --git a/7.3.595 b/7.3.595 new file mode 100644 index 00000000..0fc9b522 --- /dev/null +++ b/7.3.595 @@ -0,0 +1,154 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.595 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.595 +Problem: The X command server responds slowly +Solution: Change the loop that waits for replies. (Brian Burns) +Files: src/if_xcmdsrv.c + + +*** ../vim-7.3.594/src/if_xcmdsrv.c 2012-07-10 14:25:00.000000000 +0200 +--- src/if_xcmdsrv.c 2012-07-10 14:44:13.000000000 +0200 +*************** +*** 572,632 **** + { + time_t start; + time_t now; +- time_t lastChk = 0; + XEvent event; +! XPropertyEvent *e = (XPropertyEvent *)&event; +! # define SEND_MSEC_POLL 50 + + time(&start); +! while (endCond(endData) == 0) + { + time(&now); + if (seconds >= 0 && (now - start) >= seconds) + break; +! if (now != lastChk) +! { +! lastChk = now; +! if (!WindowValid(dpy, w)) +! break; +! /* +! * Sometimes the PropertyChange event doesn't come. +! * This can be seen in eg: vim -c 'echo remote_expr("gvim", "3+2")' +! */ +! serverEventProc(dpy, NULL); +! } + if (localLoop) + { +- /* Just look out for the answer without calling back into Vim */ + #ifndef HAVE_SELECT +- struct pollfd fds; +- +- fds.fd = ConnectionNumber(dpy); +- fds.events = POLLIN; + if (poll(&fds, 1, SEND_MSEC_POLL) < 0) + break; + #else +! fd_set fds; +! struct timeval tv; +! +! tv.tv_sec = 0; +! tv.tv_usec = SEND_MSEC_POLL * 1000; +! FD_ZERO(&fds); +! FD_SET(ConnectionNumber(dpy), &fds); +! if (select(ConnectionNumber(dpy) + 1, &fds, NULL, NULL, &tv) < 0) + break; + #endif +- while (XEventsQueued(dpy, QueuedAfterReading) > 0) +- { +- XNextEvent(dpy, &event); +- if (event.type == PropertyNotify && e->window == commWindow) +- serverEventProc(dpy, &event); +- } + } + else + { + if (got_int) + break; +! ui_delay((long)SEND_MSEC_POLL, TRUE); + ui_breakcheck(); + } + } +--- 572,626 ---- + { + time_t start; + time_t now; + XEvent event; +! +! #define UI_MSEC_DELAY 50 +! #define SEND_MSEC_POLL 500 +! #ifndef HAVE_SELECT +! struct pollfd fds; +! +! fds.fd = ConnectionNumber(dpy); +! fds.events = POLLIN; +! #else +! fd_set fds; +! struct timeval tv; +! +! tv.tv_sec = 0; +! tv.tv_usec = SEND_MSEC_POLL * 1000; +! FD_ZERO(&fds); +! FD_SET(ConnectionNumber(dpy), &fds); +! #endif + + time(&start); +! while (TRUE) + { ++ while (XCheckWindowEvent(dpy, commWindow, PropertyChangeMask, &event)) ++ serverEventProc(dpy, &event); ++ ++ if (endCond(endData) != 0) ++ break; ++ if (!WindowValid(dpy, w)) ++ break; + time(&now); + if (seconds >= 0 && (now - start) >= seconds) + break; +! +! /* Just look out for the answer without calling back into Vim */ + if (localLoop) + { + #ifndef HAVE_SELECT + if (poll(&fds, 1, SEND_MSEC_POLL) < 0) + break; + #else +! if (select(FD_SETSIZE, &fds, NULL, NULL, &tv) < 0) + break; + #endif + } + else + { + if (got_int) + break; +! ui_delay((long)UI_MSEC_DELAY, TRUE); + ui_breakcheck(); + } + } +*** ../vim-7.3.594/src/version.c 2012-07-10 14:25:00.000000000 +0200 +--- src/version.c 2012-07-10 14:52:16.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 595, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +104. When people ask about the Presidential Election you ask "Which country?" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5fa01189ba44552f656ae663138c85354ca1f076 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 18 Jul 2012 10:58:05 +0200 Subject: [PATCH 0345/3340] - patchlevel 596 --- 7.3.596 | 171 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 171 insertions(+) create mode 100644 7.3.596 diff --git a/7.3.596 b/7.3.596 new file mode 100644 index 00000000..59513b2b --- /dev/null +++ b/7.3.596 @@ -0,0 +1,171 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.596 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.596 +Problem: Can't remove all signs for a file or buffer. +Solution: Support "*" for the sign id. (Christian Brabandt) +Files: runtime/doc/sign.txt, src/buffer.c, src/ex_cmds.c, + src/proto/buffer.pro + + +*** ../vim-7.3.595/runtime/doc/sign.txt 2010-08-15 21:57:17.000000000 +0200 +--- runtime/doc/sign.txt 2012-07-10 15:05:19.000000000 +0200 +*************** +*** 150,157 **** + Remove the previously placed sign {id} from file {fname}. + See remark above about {fname} |:sign-fname|. + + :sign unplace {id} buffer={nr} +! Same, but use buffer {nr}. + + :sign unplace {id} + Remove the previously placed sign {id} from all files it +--- 153,166 ---- + Remove the previously placed sign {id} from file {fname}. + See remark above about {fname} |:sign-fname|. + ++ :sign unplace * file={fname} ++ Remove all placed signs in file {fname}. ++ + :sign unplace {id} buffer={nr} +! Remove the previously placed sign {id} from buffer {nr}. +! +! :sign unplace * buffer={nr} +! Remove all placed signs in buffer {nr}. + + :sign unplace {id} + Remove the previously placed sign {id} from all files it +*** ../vim-7.3.595/src/buffer.c 2012-07-06 16:21:58.000000000 +0200 +--- src/buffer.c 2012-07-10 15:06:05.000000000 +0200 +*************** +*** 57,63 **** + + #if defined(FEAT_SIGNS) + static void insert_sign __ARGS((buf_T *buf, signlist_T *prev, signlist_T *next, int id, linenr_T lnum, int typenr)); +- static void buf_delete_signs __ARGS((buf_T *buf)); + #endif + + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +--- 57,62 ---- +*************** +*** 5537,5543 **** + /* + * Delete signs in buffer "buf". + */ +! static void + buf_delete_signs(buf) + buf_T *buf; + { +--- 5536,5542 ---- + /* + * Delete signs in buffer "buf". + */ +! void + buf_delete_signs(buf) + buf_T *buf; + { +*** ../vim-7.3.595/src/ex_cmds.c 2012-05-18 16:24:06.000000000 +0200 +--- src/ex_cmds.c 2012-07-10 15:14:22.000000000 +0200 +*************** +*** 6997,7002 **** +--- 6997,7012 ---- + lnum = atoi((char *)arg); + arg = skiptowhite(arg); + } ++ else if (STRNCMP(arg, "*", 1) == 0 && idx == SIGNCMD_UNPLACE) ++ { ++ if (id != -1) ++ { ++ EMSG(_(e_invarg)); ++ return; ++ } ++ id = -2; ++ arg = skiptowhite(arg + 1); ++ } + else if (STRNCMP(arg, "name=", 5) == 0) + { + arg += 5; +*************** +*** 7033,7039 **** + { + EMSG2(_("E158: Invalid buffer name: %s"), arg); + } +! else if (id <= 0) + { + if (lnum >= 0 || sign_name != NULL) + EMSG(_(e_invarg)); +--- 7043,7049 ---- + { + EMSG2(_("E158: Invalid buffer name: %s"), arg); + } +! else if (id <= 0 && !(idx == SIGNCMD_UNPLACE && id == -2)) + { + if (lnum >= 0 || sign_name != NULL) + EMSG(_(e_invarg)); +*************** +*** 7074,7084 **** + } + else if (idx == SIGNCMD_UNPLACE) + { +- /* ":sign unplace {id} file={fname}" */ + if (lnum >= 0 || sign_name != NULL) + EMSG(_(e_invarg)); + else + { + lnum = buf_delsign(buf, id); + update_debug_sign(buf, lnum); + } +--- 7084,7100 ---- + } + else if (idx == SIGNCMD_UNPLACE) + { + if (lnum >= 0 || sign_name != NULL) + EMSG(_(e_invarg)); ++ else if (id == -2) ++ { ++ /* ":sign unplace * file={fname}" */ ++ redraw_buf_later(buf, NOT_VALID); ++ buf_delete_signs(buf); ++ } + else + { ++ /* ":sign unplace {id} file={fname}" */ + lnum = buf_delsign(buf, id); + update_debug_sign(buf, lnum); + } +*** ../vim-7.3.595/src/proto/buffer.pro 2012-02-22 14:58:24.000000000 +0100 +--- src/proto/buffer.pro 2012-07-10 15:06:10.000000000 +0200 +*************** +*** 60,65 **** +--- 60,66 ---- + int buf_findsign_id __ARGS((buf_T *buf, linenr_T lnum)); + int buf_findsigntype_id __ARGS((buf_T *buf, linenr_T lnum, int typenr)); + int buf_signcount __ARGS((buf_T *buf, linenr_T lnum)); ++ void buf_delete_signs __ARGS((buf_T *buf)); + void buf_delete_all_signs __ARGS((void)); + void sign_list_placed __ARGS((buf_T *rbuf)); + void sign_mark_adjust __ARGS((linenr_T line1, linenr_T line2, long amount, long amount_after)); +*** ../vim-7.3.595/src/version.c 2012-07-10 14:56:42.000000000 +0200 +--- src/version.c 2012-07-10 15:16:40.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 596, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +105. When someone asks you for your address, you tell them your URL. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 049fe77ed13134a82bcc89757e3cbe81deafe406 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 18 Jul 2012 10:58:05 +0200 Subject: [PATCH 0346/3340] - patchlevel 597 --- 7.3.597 | 720 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 720 insertions(+) create mode 100644 7.3.597 diff --git a/7.3.597 b/7.3.597 new file mode 100644 index 00000000..2a4f0b3d --- /dev/null +++ b/7.3.597 @@ -0,0 +1,720 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.597 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.597 +Problem: 'clipboard' "autoselect" only applies to the * register. (Sergey + Vakulenko) +Solution: Make 'autoselect' work for the + register. (Christian Brabant) + Add the "autoselectplus" option in 'clipboard' and the "P" flag in + 'guioptions'. +Files: runtime/doc/options.txt, src/normal.c, src/ops.c, src/screen.c, + src/ui.c, src/globals.h, src/proto/ui.pro, src/option.h, src/gui.c + + +*** ../vim-7.3.596/runtime/doc/options.txt 2012-02-20 22:18:23.000000000 +0100 +--- runtime/doc/options.txt 2012-07-10 15:40:35.000000000 +0200 +*************** +*** 1437,1442 **** +--- 1452,1458 ---- + This option is a list of comma separated names. + These names are recognized: + ++ *clipboard-unnamed* + unnamed When included, Vim will use the clipboard register '*' + for all yank, delete, change and put operations which + would normally go to the unnamed register. When a +*************** +*** 1446,1460 **** + explicitly accessed using the "* notation. Also see + |gui-clipboard|. + + unnamedplus A variant of "unnamed" flag which uses the clipboard + register '+' (|quoteplus|) instead of register '*' for + all operations except yank. Yank shall copy the text + into register '+' and also into '*' when "unnamed" is + included. +! Only available with the |+x11| feature. + Availability can be checked with: > + if has('unnamedplus') + < + autoselect Works like the 'a' flag in 'guioptions': If present, + then whenever Visual mode is started, or the Visual + area extended, Vim tries to become the owner of the +--- 1462,1478 ---- + explicitly accessed using the "* notation. Also see + |gui-clipboard|. + ++ *clipboard-unnamedplus* + unnamedplus A variant of "unnamed" flag which uses the clipboard + register '+' (|quoteplus|) instead of register '*' for + all operations except yank. Yank shall copy the text + into register '+' and also into '*' when "unnamed" is + included. +! Only available with the |+X11| feature. + Availability can be checked with: > + if has('unnamedplus') + < ++ *clipboard-autoselect* + autoselect Works like the 'a' flag in 'guioptions': If present, + then whenever Visual mode is started, or the Visual + area extended, Vim tries to become the owner of the +*************** +*** 1466,1474 **** +--- 1484,1499 ---- + "autoselect" flag is used. + Also applies to the modeless selection. + ++ *clipboard-autoselectplus* ++ autoselectplus Like "autoselect" but using the + register instead of ++ the * register. Compare to the 'P' flag in ++ 'guioptions'. ++ ++ *clipboard-autoselectml* + autoselectml Like "autoselect", but for the modeless selection + only. Compare to the 'A' flag in 'guioptions'. + ++ *clipboard-html* + html When the clipboard contains HTML, use this when + pasting. When putting text on the clipboard, mark it + as HTML. This works to copy rendered HTML from +*************** +*** 1479,1484 **** +--- 1504,1510 ---- + Only supported for GTK version 2 and later. + Only available with the |+multi_byte| feature. + ++ *clipboard-exclude* + exclude:{pattern} + Defines a pattern that is matched against the name of + the terminal 'term'. If there is a match, no +*************** +*** 3547,3552 **** +--- 3600,3608 ---- + windowing system's global selection unless explicitly told to + by a yank or delete operation for the "* register. + The same applies to the modeless selection. ++ *'go-P'* ++ 'P' Like autoselect but using the "+ register instead of the "* ++ register. + *'go-A'* + 'A' Autoselect for the modeless selection. Like 'a', but only + applies to the modeless selection. +*** ../vim-7.3.596/src/normal.c 2012-06-29 13:56:01.000000000 +0200 +--- src/normal.c 2012-07-10 15:44:24.000000000 +0200 +*************** +*** 1451,1457 **** + * This could call do_pending_operator() recursively, but that's OK + * because gui_yank will be TRUE for the nested call. + */ +! if (clip_star.available + && oap->op_type != OP_NOP + && !gui_yank + # ifdef FEAT_VISUAL +--- 1451,1457 ---- + * This could call do_pending_operator() recursively, but that's OK + * because gui_yank will be TRUE for the nested call. + */ +! if ((clip_star.available || clip_plus.available) + && oap->op_type != OP_NOP + && !gui_yank + # ifdef FEAT_VISUAL +*** ../vim-7.3.596/src/ops.c 2012-06-29 13:34:15.000000000 +0200 +--- src/ops.c 2012-07-10 16:20:29.000000000 +0200 +*************** +*** 962,969 **** + * selection too. */ + if (name == '*' && clip_star.available) + { +! if (clip_isautosel()) +! clip_update_selection(); + may_get_selection(name); + } + #endif +--- 962,975 ---- + * selection too. */ + if (name == '*' && clip_star.available) + { +! if (clip_isautosel_star()) +! clip_update_selection(&clip_star); +! may_get_selection(name); +! } +! if (name == '+' && clip_plus.available) +! { +! if (clip_isautosel_plus()) +! clip_update_selection(&clip_plus); + may_get_selection(name); + } + #endif +*************** +*** 3190,3196 **** + + clip_own_selection(&clip_plus); + clip_gen_set_selection(&clip_plus); +! if (!clip_isautosel() && !did_star && curr == &(y_regs[PLUS_REGISTER])) + { + copy_yank_reg(&(y_regs[STAR_REGISTER])); + clip_own_selection(&clip_star); +--- 3196,3203 ---- + + clip_own_selection(&clip_plus); + clip_gen_set_selection(&clip_plus); +! if (!clip_isautosel_star() && !did_star +! && curr == &(y_regs[PLUS_REGISTER])) + { + copy_yank_reg(&(y_regs[STAR_REGISTER])); + clip_own_selection(&clip_star); +*** ../vim-7.3.596/src/screen.c 2012-06-13 18:06:32.000000000 +0200 +--- src/screen.c 2012-07-10 16:39:01.000000000 +0200 +*************** +*** 519,526 **** + # endif + # ifdef FEAT_CLIPBOARD + /* When Visual area changed, may have to update selection. */ +! if (clip_star.available && clip_isautosel()) +! clip_update_selection(); + # endif + #ifdef FEAT_GUI + /* Remove the cursor before starting to do anything, because +--- 519,528 ---- + # endif + # ifdef FEAT_CLIPBOARD + /* When Visual area changed, may have to update selection. */ +! if (clip_star.available && clip_isautosel_star()) +! clip_update_selection(&clip_star); +! if (clip_plus.available && clip_isautosel_plus()) +! clip_update_selection(&clip_plus); + # endif + #ifdef FEAT_GUI + /* Remove the cursor before starting to do anything, because +*************** +*** 814,821 **** + + #ifdef FEAT_CLIPBOARD + /* When Visual area changed, may have to update selection. */ +! if (clip_star.available && clip_isautosel()) +! clip_update_selection(); + #endif + + win_update(wp); +--- 816,825 ---- + + #ifdef FEAT_CLIPBOARD + /* When Visual area changed, may have to update selection. */ +! if (clip_star.available && clip_isautosel_star()) +! clip_update_selection(&clip_star); +! if (clip_plus.available && clip_isautosel_plus()) +! clip_update_selection(&clip_plus); + #endif + + win_update(wp); +*************** +*** 3000,3006 **** + area_highlighting = TRUE; + attr = hl_attr(HLF_V); + #if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) +! if (clip_star.available && !clip_star.owned && clip_isautosel()) + attr = hl_attr(HLF_VNC); + #endif + } +--- 3004,3013 ---- + area_highlighting = TRUE; + attr = hl_attr(HLF_V); + #if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) +! if ((clip_star.available && !clip_star.owned +! && clip_isautosel_star()) +! || (clip_plus.available && !clip_plus.owned +! && clip_isautosel_plus())) + attr = hl_attr(HLF_VNC); + #endif + } +*************** +*** 9060,9066 **** + || (wp != NULL && wp->w_width != Columns) + # endif + ) +! clip_clear_selection(); + else + clip_scroll_selection(-line_count); + #endif +--- 9067,9073 ---- + || (wp != NULL && wp->w_width != Columns) + # endif + ) +! clip_clear_selection(&clip_star); + else + clip_scroll_selection(-line_count); + #endif +*************** +*** 9281,9287 **** + || (wp != NULL && wp->w_width != Columns) + # endif + ) +! clip_clear_selection(); + else + clip_scroll_selection(line_count); + #endif +--- 9288,9294 ---- + || (wp != NULL && wp->w_width != Columns) + # endif + ) +! clip_clear_selection(&clip_star); + else + clip_scroll_selection(line_count); + #endif +*** ../vim-7.3.596/src/ui.c 2012-02-12 01:35:06.000000000 +0100 +--- src/ui.c 2012-07-10 16:43:17.000000000 +0200 +*************** +*** 381,386 **** +--- 381,388 ---- + + #if defined(FEAT_CLIPBOARD) || defined(PROTO) + ++ static void clip_copy_selection __ARGS((VimClipboard *clip)); ++ + /* + * Selection stuff using Visual mode, for cutting and pasting text to other + * windows. +*************** +*** 423,431 **** + * this is called whenever VIsual mode is ended. + */ + void +! clip_update_selection() + { +! pos_T start, end; + + /* If visual mode is only due to a redo command ("."), then ignore it */ + if (!redo_VIsual_busy && VIsual_active && (State & NORMAL)) +--- 425,434 ---- + * this is called whenever VIsual mode is ended. + */ + void +! clip_update_selection(clip) +! VimClipboard *clip; + { +! pos_T start, end; + + /* If visual mode is only due to a redo command ("."), then ignore it */ + if (!redo_VIsual_busy && VIsual_active && (State & NORMAL)) +*************** +*** 444,460 **** + start = curwin->w_cursor; + end = VIsual; + } +! if (!equalpos(clip_star.start, start) +! || !equalpos(clip_star.end, end) +! || clip_star.vmode != VIsual_mode) + { +! clip_clear_selection(); +! clip_star.start = start; +! clip_star.end = end; +! clip_star.vmode = VIsual_mode; +! clip_free_selection(&clip_star); +! clip_own_selection(&clip_star); +! clip_gen_set_selection(&clip_star); + } + } + } +--- 447,463 ---- + start = curwin->w_cursor; + end = VIsual; + } +! if (!equalpos(clip->start, start) +! || !equalpos(clip->end, end) +! || clip->vmode != VIsual_mode) + { +! clip_clear_selection(clip); +! clip->start = start; +! clip->end = end; +! clip->vmode = VIsual_mode; +! clip_free_selection(clip); +! clip_own_selection(clip); +! clip_gen_set_selection(clip); + } + } + } +*************** +*** 475,481 **** + int was_owned = cbd->owned; + + cbd->owned = (clip_gen_own_selection(cbd) == OK); +! if (!was_owned && cbd == &clip_star) + { + /* May have to show a different kind of highlighting for the + * selected area. There is no specific redraw command for this, +--- 478,484 ---- + int was_owned = cbd->owned; + + cbd->owned = (clip_gen_own_selection(cbd) == OK); +! if (!was_owned && (cbd == &clip_star || cbd == &clip_plus)) + { + /* May have to show a different kind of highlighting for the + * selected area. There is no specific redraw command for this, +*************** +*** 483,489 **** + if (cbd->owned + && (get_real_state() == VISUAL + || get_real_state() == SELECTMODE) +! && clip_isautosel() + && hl_attr(HLF_V) != hl_attr(HLF_VNC)) + redraw_curbuf_later(INVERTED_ALL); + } +--- 486,493 ---- + if (cbd->owned + && (get_real_state() == VISUAL + || get_real_state() == SELECTMODE) +! && (cbd == &clip_star ? clip_isautosel_star() +! : clip_isautosel_plus()) + && hl_attr(HLF_V) != hl_attr(HLF_VNC)) + redraw_curbuf_later(INVERTED_ALL); + } +*************** +*** 502,513 **** + #ifdef FEAT_X11 + int was_owned = cbd->owned; + #endif +! int visual_selection = (cbd == &clip_star); + + clip_free_selection(cbd); + cbd->owned = FALSE; + if (visual_selection) +! clip_clear_selection(); + clip_gen_lose_selection(cbd); + #ifdef FEAT_X11 + if (visual_selection) +--- 506,520 ---- + #ifdef FEAT_X11 + int was_owned = cbd->owned; + #endif +! int visual_selection = FALSE; +! +! if (cbd == &clip_star || cbd == &clip_plus) +! visual_selection = TRUE; + + clip_free_selection(cbd); + cbd->owned = FALSE; + if (visual_selection) +! clip_clear_selection(cbd); + clip_gen_lose_selection(cbd); + #ifdef FEAT_X11 + if (visual_selection) +*************** +*** 518,524 **** + if (was_owned + && (get_real_state() == VISUAL + || get_real_state() == SELECTMODE) +! && clip_isautosel() + && hl_attr(HLF_V) != hl_attr(HLF_VNC)) + { + update_curbuf(INVERTED_ALL); +--- 525,532 ---- + if (was_owned + && (get_real_state() == VISUAL + || get_real_state() == SELECTMODE) +! && (cbd == &clip_star ? +! clip_isautosel_star() : clip_isautosel_plus()) + && hl_attr(HLF_V) != hl_attr(HLF_VNC)) + { + update_curbuf(INVERTED_ALL); +*************** +*** 534,551 **** + #endif + } + +! void +! clip_copy_selection() +! { +! if (VIsual_active && (State & NORMAL) && clip_star.available) +! { +! if (clip_isautosel()) +! clip_update_selection(); +! clip_free_selection(&clip_star); +! clip_own_selection(&clip_star); +! if (clip_star.owned) +! clip_get_selection(&clip_star); +! clip_gen_set_selection(&clip_star); + } + } + +--- 542,559 ---- + #endif + } + +! static void +! clip_copy_selection(clip) +! VimClipboard *clip; +! { +! if (VIsual_active && (State & NORMAL) && clip->available) +! { +! clip_update_selection(clip); +! clip_free_selection(clip); +! clip_own_selection(clip); +! if (clip->owned) +! clip_get_selection(clip); +! clip_gen_set_selection(clip); + } + } + +*************** +*** 555,575 **** + void + clip_auto_select() + { +! if (clip_isautosel()) +! clip_copy_selection(); + } + + /* +! * Return TRUE if automatic selection of Visual area is desired. + */ + int +! clip_isautosel() + { + return ( + #ifdef FEAT_GUI + gui.in_use ? (vim_strchr(p_go, GO_ASEL) != NULL) : + #endif +! clip_autoselect); + } + + +--- 563,600 ---- + void + clip_auto_select() + { +! if (clip_isautosel_star()) +! clip_copy_selection(&clip_star); +! if (clip_isautosel_plus()) +! clip_copy_selection(&clip_plus); + } + + /* +! * Return TRUE if automatic selection of Visual area is desired for the * +! * register. + */ + int +! clip_isautosel_star() + { + return ( + #ifdef FEAT_GUI + gui.in_use ? (vim_strchr(p_go, GO_ASEL) != NULL) : + #endif +! clip_autoselect_star); +! } +! +! /* +! * Return TRUE if automatic selection of Visual area is desired for the + +! * register. +! */ +! int +! clip_isautosel_plus() +! { +! return ( +! #ifdef FEAT_GUI +! gui.in_use ? (vim_strchr(p_go, GO_ASELPLUS) != NULL) : +! #endif +! clip_autoselect_plus); + } + + +*************** +*** 657,663 **** + VimClipboard *cb = &clip_star; + + if (cb->state == SELECT_DONE) +! clip_clear_selection(); + + row = check_row(row); + col = check_col(col); +--- 682,688 ---- + VimClipboard *cb = &clip_star; + + if (cb->state == SELECT_DONE) +! clip_clear_selection(cb); + + row = check_row(row); + col = check_col(col); +*************** +*** 749,755 **** + printf("Selection ended: (%u,%u) to (%u,%u)\n", cb->start.lnum, + cb->start.col, cb->end.lnum, cb->end.col); + #endif +! if (clip_isautosel() + || ( + #ifdef FEAT_GUI + gui.in_use ? (vim_strchr(p_go, GO_ASELML) != NULL) : +--- 774,780 ---- + printf("Selection ended: (%u,%u) to (%u,%u)\n", cb->start.lnum, + cb->start.col, cb->end.lnum, cb->end.col); + #endif +! if (clip_isautosel_star() + || ( + #ifdef FEAT_GUI + gui.in_use ? (vim_strchr(p_go, GO_ASELML) != NULL) : +*************** +*** 932,947 **** + * Called from outside to clear selected region from the display + */ + void +! clip_clear_selection() + { +- VimClipboard *cb = &clip_star; + +! if (cb->state == SELECT_CLEARED) + return; + +! clip_invert_area((int)cb->start.lnum, cb->start.col, (int)cb->end.lnum, +! cb->end.col, CLIP_CLEAR); +! cb->state = SELECT_CLEARED; + } + + /* +--- 957,972 ---- + * Called from outside to clear selected region from the display + */ + void +! clip_clear_selection(cbd) +! VimClipboard *cbd; + { + +! if (cbd->state == SELECT_CLEARED) + return; + +! clip_invert_area((int)cbd->start.lnum, cbd->start.col, (int)cbd->end.lnum, +! cbd->end.col, CLIP_CLEAR); +! cbd->state = SELECT_CLEARED; + } + + /* +*************** +*** 954,960 **** + if (clip_star.state == SELECT_DONE + && row2 >= clip_star.start.lnum + && row1 <= clip_star.end.lnum) +! clip_clear_selection(); + } + + /* +--- 979,985 ---- + if (clip_star.state == SELECT_DONE + && row2 >= clip_star.start.lnum + && row1 <= clip_star.end.lnum) +! clip_clear_selection(&clip_star); + } + + /* +*** ../vim-7.3.596/src/globals.h 2012-06-29 12:35:40.000000000 +0200 +--- src/globals.h 2012-07-10 16:35:13.000000000 +0200 +*************** +*** 517,523 **** + # define CLIP_UNNAMED_PLUS 2 + EXTERN int clip_unnamed INIT(= 0); /* above two values or'ed */ + +! EXTERN int clip_autoselect INIT(= FALSE); + EXTERN int clip_autoselectml INIT(= FALSE); + EXTERN int clip_html INIT(= FALSE); + EXTERN regprog_T *clip_exclude_prog INIT(= NULL); +--- 517,524 ---- + # define CLIP_UNNAMED_PLUS 2 + EXTERN int clip_unnamed INIT(= 0); /* above two values or'ed */ + +! EXTERN int clip_autoselect_star INIT(= FALSE); +! EXTERN int clip_autoselect_plus INIT(= FALSE); + EXTERN int clip_autoselectml INIT(= FALSE); + EXTERN int clip_html INIT(= FALSE); + EXTERN regprog_T *clip_exclude_prog INIT(= NULL); +*** ../vim-7.3.596/src/proto/ui.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/ui.pro 2012-07-10 16:37:35.000000000 +0200 +*************** +*** 11,27 **** + void ui_new_shellsize __ARGS((void)); + void ui_breakcheck __ARGS((void)); + void clip_init __ARGS((int can_use)); +! void clip_update_selection __ARGS((void)); + void clip_own_selection __ARGS((VimClipboard *cbd)); + void clip_lose_selection __ARGS((VimClipboard *cbd)); +- void clip_copy_selection __ARGS((void)); + void clip_auto_select __ARGS((void)); +! int clip_isautosel __ARGS((void)); + void clip_modeless __ARGS((int button, int is_click, int is_drag)); + void clip_start_selection __ARGS((int col, int row, int repeated_click)); + void clip_process_selection __ARGS((int button, int col, int row, int_u repeated_click)); + void clip_may_redraw_selection __ARGS((int row, int col, int len)); +! void clip_clear_selection __ARGS((void)); + void clip_may_clear_selection __ARGS((int row1, int row2)); + void clip_scroll_selection __ARGS((int rows)); + void clip_copy_modeless_selection __ARGS((int both)); +--- 11,27 ---- + void ui_new_shellsize __ARGS((void)); + void ui_breakcheck __ARGS((void)); + void clip_init __ARGS((int can_use)); +! void clip_update_selection __ARGS((VimClipboard *clip)); + void clip_own_selection __ARGS((VimClipboard *cbd)); + void clip_lose_selection __ARGS((VimClipboard *cbd)); + void clip_auto_select __ARGS((void)); +! int clip_isautosel_star __ARGS((void)); +! int clip_isautosel_plus __ARGS((void)); + void clip_modeless __ARGS((int button, int is_click, int is_drag)); + void clip_start_selection __ARGS((int col, int row, int repeated_click)); + void clip_process_selection __ARGS((int button, int col, int row, int_u repeated_click)); + void clip_may_redraw_selection __ARGS((int row, int col, int len)); +! void clip_clear_selection __ARGS((VimClipboard *cbd)); + void clip_may_clear_selection __ARGS((int row1, int row2)); + void clip_scroll_selection __ARGS((int rows)); + void clip_copy_modeless_selection __ARGS((int both)); +*** ../vim-7.3.596/src/option.h 2012-06-06 16:12:54.000000000 +0200 +--- src/option.h 2012-07-10 15:54:32.000000000 +0200 +*************** +*** 229,234 **** +--- 229,235 ---- + #define GO_MENUS 'm' /* use menu bar */ + #define GO_NOSYSMENU 'M' /* don't source system menu */ + #define GO_POINTER 'p' /* pointer enter/leave callbacks */ ++ #define GO_ASELPLUS 'P' /* autoselectPlus */ + #define GO_RIGHT 'r' /* use right scrollbar */ + #define GO_VRIGHT 'R' /* right scrollbar with vert split */ + #define GO_TEAROFF 't' /* add tear-off menu items */ +*** ../vim-7.3.596/src/gui.c 2012-05-27 00:37:45.000000000 +0200 +--- src/gui.c 2012-07-10 16:43:34.000000000 +0200 +*************** +*** 3154,3160 **** + } + + if (clip_star.state != SELECT_CLEARED && !did_clip) +! clip_clear_selection(); + #endif + + /* Don't put events in the input queue now. */ +--- 3154,3160 ---- + } + + if (clip_star.state != SELECT_CLEARED && !did_clip) +! clip_clear_selection(&clip_star); + #endif + + /* Don't put events in the input queue now. */ +*** ../vim-7.3.596/src/version.c 2012-07-10 15:18:18.000000000 +0200 +--- src/version.c 2012-07-10 16:32:16.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 597, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +106. When told to "go to your room" you inform your parents that you + can't...because you were kicked out and banned. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7d168cd28c4ac684910dd836dcd2784ae4f48330 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 18 Jul 2012 10:58:06 +0200 Subject: [PATCH 0347/3340] - patchlevel 598 --- 7.3.598 | 73 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 7.3.598 diff --git a/7.3.598 b/7.3.598 new file mode 100644 index 00000000..3a38b4a7 --- /dev/null +++ b/7.3.598 @@ -0,0 +1,73 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.598 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.598 +Problem: Cannot act upon end of completion. (Taro Muraoka) +Solution: Add an autocommand event that is triggered when completion has + finished. (Idea by Florian Klein) +Files: src/edit.c, src/fileio.c, src/vim.h + + +*** ../vim-7.3.597/src/edit.c 2012-07-06 13:36:36.000000000 +0200 +--- src/edit.c 2012-07-10 17:02:37.000000000 +0200 +*************** +*** 3824,3829 **** +--- 3824,3834 ---- + if (want_cindent && in_cinkeys(KEY_COMPLETE, ' ', inindent(0))) + do_c_expr_indent(); + #endif ++ #ifdef FEAT_AUTOCMD ++ /* Trigger the CompleteDone event to give scripts a chance to act ++ * upon the completion. */ ++ apply_autocmds(EVENT_COMPLETEDONE, NULL, NULL, FALSE, curbuf); ++ #endif + } + } + +*** ../vim-7.3.597/src/fileio.c 2012-06-13 14:28:16.000000000 +0200 +--- src/fileio.c 2012-07-10 17:05:51.000000000 +0200 +*************** +*** 7643,7648 **** +--- 7643,7649 ---- + {"CmdwinEnter", EVENT_CMDWINENTER}, + {"CmdwinLeave", EVENT_CMDWINLEAVE}, + {"ColorScheme", EVENT_COLORSCHEME}, ++ {"CompleteDone", EVENT_COMPLETEDONE}, + {"CursorHold", EVENT_CURSORHOLD}, + {"CursorHoldI", EVENT_CURSORHOLDI}, + {"CursorMoved", EVENT_CURSORMOVED}, +*** ../vim-7.3.597/src/vim.h 2012-07-10 13:41:09.000000000 +0200 +--- src/vim.h 2012-07-10 17:06:24.000000000 +0200 +*************** +*** 1241,1246 **** +--- 1241,1247 ---- + EVENT_CMDWINENTER, /* after entering the cmdline window */ + EVENT_CMDWINLEAVE, /* before leaving the cmdline window */ + EVENT_COLORSCHEME, /* after loading a colorscheme */ ++ EVENT_COMPLETEDONE, /* after finishing insert complete */ + EVENT_FILEAPPENDPOST, /* after appending to a file */ + EVENT_FILEAPPENDPRE, /* before appending to a file */ + EVENT_FILEAPPENDCMD, /* append to a file using command */ +*** ../vim-7.3.597/src/version.c 2012-07-10 16:49:08.000000000 +0200 +--- src/version.c 2012-07-10 17:08:41.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 598, + /**/ + +-- +Laughing helps. It's like jogging on the inside. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 083102db980aa12b9596d8c142b900086c741ada Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 18 Jul 2012 10:58:06 +0200 Subject: [PATCH 0348/3340] - patchlevel 599 --- 7.3.599 | 107 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 107 insertions(+) create mode 100644 7.3.599 diff --git a/7.3.599 b/7.3.599 new file mode 100644 index 00000000..adfe6f99 --- /dev/null +++ b/7.3.599 @@ -0,0 +1,107 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.599 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.599 (after 7.3.597) +Problem: Missing change in one file. +Solution: Patch for changed clip_autoselect(). +Files: src/option.c + + +*** ../vim-7.3.598/src/option.c 2012-06-29 15:51:26.000000000 +0200 +--- src/option.c 2012-07-10 16:35:07.000000000 +0200 +*************** +*** 7377,7383 **** + check_clipboard_option() + { + int new_unnamed = 0; +! int new_autoselect = FALSE; + int new_autoselectml = FALSE; + int new_html = FALSE; + regprog_T *new_exclude_prog = NULL; +--- 7377,7384 ---- + check_clipboard_option() + { + int new_unnamed = 0; +! int new_autoselect_star = FALSE; +! int new_autoselect_plus = FALSE; + int new_autoselectml = FALSE; + int new_html = FALSE; + regprog_T *new_exclude_prog = NULL; +*************** +*** 7398,7410 **** + p += 11; + } + else if (STRNCMP(p, "autoselect", 10) == 0 +! && (p[10] == ',' || p[10] == NUL)) + { +! new_autoselect = TRUE; + p += 10; + } + else if (STRNCMP(p, "autoselectml", 12) == 0 +! && (p[12] == ',' || p[12] == NUL)) + { + new_autoselectml = TRUE; + p += 12; +--- 7399,7417 ---- + p += 11; + } + else if (STRNCMP(p, "autoselect", 10) == 0 +! && (p[10] == ',' || p[10] == NUL)) + { +! new_autoselect_star = TRUE; + p += 10; + } ++ else if (STRNCMP(p, "autoselectplus", 14) == 0 ++ && (p[14] == ',' || p[14] == NUL)) ++ { ++ new_autoselect_plus = TRUE; ++ p += 14; ++ } + else if (STRNCMP(p, "autoselectml", 12) == 0 +! && (p[12] == ',' || p[12] == NUL)) + { + new_autoselectml = TRUE; + p += 12; +*************** +*** 7433,7439 **** + if (errmsg == NULL) + { + clip_unnamed = new_unnamed; +! clip_autoselect = new_autoselect; + clip_autoselectml = new_autoselectml; + clip_html = new_html; + vim_free(clip_exclude_prog); +--- 7440,7447 ---- + if (errmsg == NULL) + { + clip_unnamed = new_unnamed; +! clip_autoselect_star = new_autoselect_star; +! clip_autoselect_plus = new_autoselect_plus; + clip_autoselectml = new_autoselectml; + clip_html = new_html; + vim_free(clip_exclude_prog); +*** ../vim-7.3.598/src/version.c 2012-07-10 17:14:50.000000000 +0200 +--- src/version.c 2012-07-10 18:30:17.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 599, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +108. While reading a magazine, you look for the Zoom icon for a better + look at a photograph. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 27ebb1b338c048845306844e82bfb3b6f2887c85 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 18 Jul 2012 10:58:06 +0200 Subject: [PATCH 0349/3340] - patchlevel 600 --- 7.3.600 | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 7.3.600 diff --git a/7.3.600 b/7.3.600 new file mode 100644 index 00000000..6504da01 --- /dev/null +++ b/7.3.600 @@ -0,0 +1,68 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.600 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.600 +Problem: is not expanded properly with DBCS encoding. +Solution: Skip over character instead of byte. (Yukihiro Nakadaira) +Files: src/ex_docmd.c + + +*** ../vim-7.3.599/src/ex_docmd.c 2012-07-06 18:27:34.000000000 +0200 +--- src/ex_docmd.c 2012-07-10 19:20:10.000000000 +0200 +*************** +*** 5845,5852 **** +--- 5845,5858 ---- + } + else + { ++ #ifdef FEAT_MBYTE ++ int charlen = (*mb_ptr2len)(p); ++ len += charlen; ++ p += charlen; ++ #else + ++len; + ++p; ++ #endif + } + } + +*************** +*** 5889,5895 **** + } + else + { +! *q++ = *p++; + } + } + *q++ = '"'; +--- 5895,5901 ---- + } + else + { +! MB_COPY_CHAR(p, q); + } + } + *q++ = '"'; +*** ../vim-7.3.599/src/version.c 2012-07-10 18:31:49.000000000 +0200 +--- src/version.c 2012-07-10 19:21:29.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 600, + /**/ + +-- +In a world without walls and borders, who needs windows and gates? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a5aa97965720a61ea16cfd0f50a81c7fdad5e62e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 18 Jul 2012 10:58:07 +0200 Subject: [PATCH 0350/3340] - patchlevel 601 --- 7.3.601 | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 7.3.601 diff --git a/7.3.601 b/7.3.601 new file mode 100644 index 00000000..b61a9331 --- /dev/null +++ b/7.3.601 @@ -0,0 +1,51 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.601 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.601 +Problem: Bad code style. +Solution: Insert space, remove parens. +Files: src/farsi.c + + +*** ../vim-7.3.600/src/farsi.c 2010-08-15 21:57:28.000000000 +0200 +--- src/farsi.c 2012-07-12 21:59:15.000000000 +0200 +*************** +*** 1813,1819 **** + ptr[i] = toF_leading(ptr[i]); + ++i; + +! while(canF_Rjoin(ptr[i]) && (i < llen)) + { + ptr[i] = toF_Rjoin(ptr[i]); + if (F_isterm(ptr[i]) || !F_isalpha(ptr[i])) +--- 1813,1819 ---- + ptr[i] = toF_leading(ptr[i]); + ++i; + +! while (canF_Rjoin(ptr[i]) && i < llen) + { + ptr[i] = toF_Rjoin(ptr[i]); + if (F_isterm(ptr[i]) || !F_isalpha(ptr[i])) +*** ../vim-7.3.600/src/version.c 2012-07-10 19:25:06.000000000 +0200 +--- src/version.c 2012-07-16 17:25:48.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 601, + /**/ + +-- +There are three kinds of persons: Those who can count and those who can't. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 51e5b2d3e901bd52f8b35d041ca3bc739febc772 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 18 Jul 2012 10:58:07 +0200 Subject: [PATCH 0351/3340] - patchlevel 602 --- 7.3.602 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.602 diff --git a/7.3.602 b/7.3.602 new file mode 100644 index 00000000..fd5f3cf4 --- /dev/null +++ b/7.3.602 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.602 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.602 +Problem: Missing files in distribution. +Solution: Update the list of files. +Files: Filelist + + +*** ../vim-7.3.601/Filelist 2011-10-20 16:35:25.000000000 +0200 +--- Filelist 2012-06-20 12:06:41.000000000 +0200 +*************** +*** 463,468 **** +--- 463,469 ---- + runtime/macros/hanoi/hanoi.vim \ + runtime/macros/hanoi/poster \ + runtime/macros/justify.vim \ ++ runtime/macros/less.bat \ + runtime/macros/less.sh \ + runtime/macros/less.vim \ + runtime/macros/life/click.me \ +*************** +*** 666,671 **** +--- 667,674 ---- + + # generic language files + LANG_GEN = \ ++ runtime/doc/*-de.1 \ ++ runtime/doc/*-de.UTF-8.1 \ + runtime/doc/*-fr.1 \ + runtime/doc/*-fr.UTF-8.1 \ + runtime/doc/*-it.1 \ +*** ../vim-7.3.601/src/version.c 2012-07-16 17:26:18.000000000 +0200 +--- src/version.c 2012-07-16 17:27:31.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 602, + /**/ + +-- +Never eat yellow snow. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 81373bd414e11fd1bfd6cd9d7728ae4e476aa920 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 18 Jul 2012 10:58:08 +0200 Subject: [PATCH 0352/3340] - patchlevel 603 --- 7.3.603 | 370 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 370 insertions(+) create mode 100644 7.3.603 diff --git a/7.3.603 b/7.3.603 new file mode 100644 index 00000000..00a024b0 --- /dev/null +++ b/7.3.603 @@ -0,0 +1,370 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.603 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.603 +Problem: It is possible to add replace builtin functions by calling + extend() on g:. +Solution: Add a flag to a dict to indicate it is a scope. Check for + existing functions. (ZyX) +Files: src/buffer.c, src/eval.c, src/proto/eval.pro, src/structs.h, + src/testdir/test34.in, src/testdir/test34.ok, src/window.c + + +*** ../vim-7.3.602/src/buffer.c 2012-07-10 15:18:18.000000000 +0200 +--- src/buffer.c 2012-07-16 16:52:58.000000000 +0200 +*************** +*** 1747,1753 **** + buf->b_wininfo->wi_win = curwin; + + #ifdef FEAT_EVAL +! init_var_dict(&buf->b_vars, &buf->b_bufvar); /* init b: variables */ + #endif + #ifdef FEAT_SYN_HL + hash_init(&buf->b_s.b_keywtab); +--- 1747,1754 ---- + buf->b_wininfo->wi_win = curwin; + + #ifdef FEAT_EVAL +! /* init b: variables */ +! init_var_dict(&buf->b_vars, &buf->b_bufvar, VAR_SCOPE); + #endif + #ifdef FEAT_SYN_HL + hash_init(&buf->b_s.b_keywtab); +*** ../vim-7.3.602/src/eval.c 2012-07-10 13:41:09.000000000 +0200 +--- src/eval.c 2012-07-16 17:18:11.000000000 +0200 +*************** +*** 850,857 **** + int i; + struct vimvar *p; + +! init_var_dict(&globvardict, &globvars_var); +! init_var_dict(&vimvardict, &vimvars_var); + vimvardict.dv_lock = VAR_FIXED; + hash_init(&compat_hashtab); + hash_init(&func_hashtab); +--- 850,857 ---- + int i; + struct vimvar *p; + +! init_var_dict(&globvardict, &globvars_var, VAR_DEF_SCOPE); +! init_var_dict(&vimvardict, &vimvars_var, VAR_SCOPE); + vimvardict.dv_lock = VAR_FIXED; + hash_init(&compat_hashtab); + hash_init(&func_hashtab); +*************** +*** 2725,2738 **** + lp->ll_dict = lp->ll_tv->vval.v_dict; + lp->ll_di = dict_find(lp->ll_dict, key, len); + +! /* When assigning to g: check that a function and variable name is +! * valid. */ +! if (rettv != NULL && lp->ll_dict == &globvardict) + { +! if (rettv->v_type == VAR_FUNC + && var_check_func_name(key, lp->ll_di == NULL)) +! return NULL; +! if (!valid_varname(key)) + return NULL; + } + +--- 2725,2750 ---- + lp->ll_dict = lp->ll_tv->vval.v_dict; + lp->ll_di = dict_find(lp->ll_dict, key, len); + +! /* When assigning to a scope dictionary check that a function and +! * variable name is valid (only variable name unless it is l: or +! * g: dictionary). Disallow overwriting a builtin function. */ +! if (rettv != NULL && lp->ll_dict->dv_scope != 0) + { +! int prevval; +! int wrong; +! +! if (len != -1) +! { +! prevval = key[len]; +! key[len] = NUL; +! } +! wrong = (lp->ll_dict->dv_scope == VAR_DEF_SCOPE +! && rettv->v_type == VAR_FUNC + && var_check_func_name(key, lp->ll_di == NULL)) +! || !valid_varname(key); +! if (len != -1) +! key[len] = prevval; +! if (wrong) + return NULL; + } + +*************** +*** 6951,6957 **** + d = (dict_T *)alloc(sizeof(dict_T)); + if (d != NULL) + { +! /* Add the list to the list of dicts for garbage collection. */ + if (first_dict != NULL) + first_dict->dv_used_prev = d; + d->dv_used_next = first_dict; +--- 6963,6969 ---- + d = (dict_T *)alloc(sizeof(dict_T)); + if (d != NULL) + { +! /* Add the dict to the list of dicts for garbage collection. */ + if (first_dict != NULL) + first_dict->dv_used_prev = d; + d->dv_used_next = first_dict; +*************** +*** 6960,6965 **** +--- 6972,6978 ---- + + hash_init(&d->dv_hashtab); + d->dv_lock = 0; ++ d->dv_scope = 0; + d->dv_refcount = 0; + d->dv_copyID = 0; + } +*************** +*** 10203,10208 **** +--- 10216,10234 ---- + { + --todo; + di1 = dict_find(d1, hi2->hi_key, -1); ++ if (d1->dv_scope != 0) ++ { ++ /* Disallow replacing a builtin function in l: and g:. ++ * Check the key to be valid when adding to any ++ * scope. */ ++ if (d1->dv_scope == VAR_DEF_SCOPE ++ && HI2DI(hi2)->di_tv.v_type == VAR_FUNC ++ && var_check_func_name(hi2->hi_key, ++ di1 == NULL)) ++ break; ++ if (!valid_varname(hi2->hi_key)) ++ break; ++ } + if (di1 == NULL) + { + di1 = dictitem_copy(HI2DI(hi2)); +*************** +*** 20027,20033 **** + { + sv = SCRIPT_SV(ga_scripts.ga_len + 1) = + (scriptvar_T *)alloc_clear(sizeof(scriptvar_T)); +! init_var_dict(&sv->sv_dict, &sv->sv_var); + ++ga_scripts.ga_len; + } + } +--- 20053,20059 ---- + { + sv = SCRIPT_SV(ga_scripts.ga_len + 1) = + (scriptvar_T *)alloc_clear(sizeof(scriptvar_T)); +! init_var_dict(&sv->sv_dict, &sv->sv_var, VAR_SCOPE); + ++ga_scripts.ga_len; + } + } +*************** +*** 20038,20049 **** + * point to it. + */ + void +! init_var_dict(dict, dict_var) + dict_T *dict; + dictitem_T *dict_var; + { + hash_init(&dict->dv_hashtab); + dict->dv_lock = 0; + dict->dv_refcount = DO_NOT_FREE_CNT; + dict->dv_copyID = 0; + dict_var->di_tv.vval.v_dict = dict; +--- 20064,20077 ---- + * point to it. + */ + void +! init_var_dict(dict, dict_var, scope) + dict_T *dict; + dictitem_T *dict_var; ++ int scope; + { + hash_init(&dict->dv_hashtab); + dict->dv_lock = 0; ++ dict->dv_scope = scope; + dict->dv_refcount = DO_NOT_FREE_CNT; + dict->dv_copyID = 0; + dict_var->di_tv.vval.v_dict = dict; +*************** +*** 22304,22310 **** + /* + * Init l: variables. + */ +! init_var_dict(&fc->l_vars, &fc->l_vars_var); + if (selfdict != NULL) + { + /* Set l:self to "selfdict". Use "name" to avoid a warning from +--- 22332,22338 ---- + /* + * Init l: variables. + */ +! init_var_dict(&fc->l_vars, &fc->l_vars_var, VAR_DEF_SCOPE); + if (selfdict != NULL) + { + /* Set l:self to "selfdict". Use "name" to avoid a warning from +*************** +*** 22325,22331 **** + * Set a:0 to "argcount". + * Set a:000 to a list with room for the "..." arguments. + */ +! init_var_dict(&fc->l_avars, &fc->l_avars_var); + add_nr_var(&fc->l_avars, &fc->fixvar[fixvar_idx++].var, "0", + (varnumber_T)(argcount - fp->uf_args.ga_len)); + /* Use "name" to avoid a warning from some compiler that checks the +--- 22353,22359 ---- + * Set a:0 to "argcount". + * Set a:000 to a list with room for the "..." arguments. + */ +! init_var_dict(&fc->l_avars, &fc->l_avars_var, VAR_SCOPE); + add_nr_var(&fc->l_avars, &fc->fixvar[fixvar_idx++].var, "0", + (varnumber_T)(argcount - fp->uf_args.ga_len)); + /* Use "name" to avoid a warning from some compiler that checks the +*** ../vim-7.3.602/src/proto/eval.pro 2012-06-29 12:54:32.000000000 +0200 +--- src/proto/eval.pro 2012-07-16 16:55:16.000000000 +0200 +*************** +*** 93,99 **** + char_u *get_tv_string_chk __ARGS((typval_T *varp)); + char_u *get_var_value __ARGS((char_u *name)); + void new_script_vars __ARGS((scid_T id)); +! void init_var_dict __ARGS((dict_T *dict, dictitem_T *dict_var)); + void vars_clear __ARGS((hashtab_T *ht)); + void copy_tv __ARGS((typval_T *from, typval_T *to)); + void ex_echo __ARGS((exarg_T *eap)); +--- 93,99 ---- + char_u *get_tv_string_chk __ARGS((typval_T *varp)); + char_u *get_var_value __ARGS((char_u *name)); + void new_script_vars __ARGS((scid_T id)); +! void init_var_dict __ARGS((dict_T *dict, dictitem_T *dict_var, int scope)); + void vars_clear __ARGS((hashtab_T *ht)); + void copy_tv __ARGS((typval_T *from, typval_T *to)); + void ex_echo __ARGS((exarg_T *eap)); +*** ../vim-7.3.602/src/structs.h 2012-06-06 19:02:40.000000000 +0200 +--- src/structs.h 2012-07-16 16:56:43.000000000 +0200 +*************** +*** 1106,1111 **** +--- 1106,1116 ---- + #define VAR_DICT 5 /* "v_dict" is used */ + #define VAR_FLOAT 6 /* "v_float" is used */ + ++ /* Values for "dv_scope". */ ++ #define VAR_SCOPE 1 /* a:, v:, s:, etc. scope dictionaries */ ++ #define VAR_DEF_SCOPE 2 /* l:, g: scope dictionaries: here funcrefs are not ++ allowed to mask existing functions */ ++ + /* Values for "v_lock". */ + #define VAR_LOCKED 1 /* locked with lock(), can use unlock() */ + #define VAR_FIXED 2 /* locked forever */ +*************** +*** 1181,1186 **** +--- 1186,1192 ---- + int dv_copyID; /* ID used by deepcopy() */ + dict_T *dv_copydict; /* copied dict used by deepcopy() */ + char dv_lock; /* zero, VAR_LOCKED, VAR_FIXED */ ++ char dv_scope; /* zero, VAR_SCOPE, VAR_DEF_SCOPE */ + dict_T *dv_used_next; /* next dict in used dicts list */ + dict_T *dv_used_prev; /* previous dict in used dicts list */ + }; +*** ../vim-7.3.602/src/testdir/test34.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test34.in 2012-07-16 16:51:29.000000000 +0200 +*************** +*** 1,5 **** +--- 1,6 ---- + Test for user functions. + Also test an mapping calling a function. ++ Also test that a builtin function cannot be replaced. + + STARTTEST + :so small.vim +*************** +*** 58,64 **** + ---*--- + (one + (two +! [(one again:$-5,$w! test.out + :delfunc Table + :delfunc Compute + :delfunc Expr1 +--- 59,68 ---- + ---*--- + (one + (two +! [(one again:call append(line('$'), max([1, 2, 3])) +! :call extend(g:, {'max': function('min')}) +! :call append(line('$'), max([1, 2, 3])) +! :$-7,$w! test.out + :delfunc Table + :delfunc Compute + :delfunc Expr1 +*** ../vim-7.3.602/src/testdir/test34.ok 2011-10-12 22:02:07.000000000 +0200 +--- src/testdir/test34.ok 2012-07-16 16:43:15.000000000 +0200 +*************** +*** 4,6 **** +--- 4,8 ---- + 1. one + 2. two + 1. one again ++ 3 ++ 3 +*** ../vim-7.3.602/src/window.c 2012-07-06 18:27:34.000000000 +0200 +--- src/window.c 2012-07-16 16:53:45.000000000 +0200 +*************** +*** 3468,3474 **** + # endif + #ifdef FEAT_EVAL + /* init t: variables */ +! init_var_dict(&tp->tp_vars, &tp->tp_winvar); + #endif + tp->tp_ch_used = p_ch; + } +--- 3468,3474 ---- + # endif + #ifdef FEAT_EVAL + /* init t: variables */ +! init_var_dict(&tp->tp_vars, &tp->tp_winvar, VAR_SCOPE); + #endif + tp->tp_ch_used = p_ch; + } +*************** +*** 4410,4416 **** + #endif + #ifdef FEAT_EVAL + /* init w: variables */ +! init_var_dict(&new_wp->w_vars, &new_wp->w_winvar); + #endif + #ifdef FEAT_FOLDING + foldInitWin(new_wp); +--- 4410,4416 ---- + #endif + #ifdef FEAT_EVAL + /* init w: variables */ +! init_var_dict(&new_wp->w_vars, &new_wp->w_winvar, VAR_SCOPE); + #endif + #ifdef FEAT_FOLDING + foldInitWin(new_wp); +*** ../vim-7.3.602/src/version.c 2012-07-16 17:27:57.000000000 +0200 +--- src/version.c 2012-07-16 17:29:06.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 603, + /**/ + +-- +Birthdays are healthy. The more you have them, the longer you live. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2a3f8b98bbfb8922c9b22438983d5b388287fdf6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 18 Jul 2012 10:58:08 +0200 Subject: [PATCH 0353/3340] - patchlevel 604 --- 7.3.604 | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 7.3.604 diff --git a/7.3.604 b/7.3.604 new file mode 100644 index 00000000..f7e63bd0 --- /dev/null +++ b/7.3.604 @@ -0,0 +1,60 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.604 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.604 +Problem: inputdialog() doesn't use the cancel argument in the console. + (David Fishburn) +Solution: Use the third argument. (Christian Brabant) +Files: src/eval.c + + +*** ../vim-7.3.603/src/eval.c 2012-07-16 17:31:48.000000000 +0200 +--- src/eval.c 2012-07-16 19:20:47.000000000 +0200 +*************** +*** 12940,12945 **** +--- 12940,12946 ---- + int xp_namelen; + long argt; + ++ /* input() with a third argument: completion */ + rettv->vval.v_string = NULL; + + xp_name = get_tv_string_buf_chk(&argvars[2], buf); +*************** +*** 12958,12963 **** +--- 12959,12969 ---- + rettv->vval.v_string = + getcmdline_prompt(inputsecret_flag ? NUL : '@', p, echo_attr, + xp_type, xp_arg); ++ if (rettv->vval.v_string == NULL ++ && argvars[1].v_type != VAR_UNKNOWN ++ && argvars[2].v_type != VAR_UNKNOWN) ++ rettv->vval.v_string = vim_strsave(get_tv_string_buf( ++ &argvars[2], buf)); + + vim_free(xp_arg); + +*** ../vim-7.3.603/src/version.c 2012-07-16 17:31:48.000000000 +0200 +--- src/version.c 2012-07-16 19:23:11.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 604, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +135. You cut classes or miss work so you can stay home and browse the web. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f26c8d0091b69c1a03ab2fa7f79da16088a4f1e1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 18 Jul 2012 10:58:12 +0200 Subject: [PATCH 0354/3340] - patchlevel 604 --- README.patches | 10 ++++++++++ vim.spec | 27 +++++++++++++++++++++++++-- 2 files changed, 35 insertions(+), 2 deletions(-) diff --git a/README.patches b/README.patches index 0d49d907..2cf3f4f9 100644 --- a/README.patches +++ b/README.patches @@ -625,3 +625,13 @@ Individual patches for Vim 7.3: 3343 7.3.592 Vim on GTK does not support g:browsefilter 2237 7.3.593 no easy way to decide if b:browsefilter will work 4873 7.3.594 the X command server sends an empty reply for as-keys requests + 3921 7.3.595 the X command server responds slowly + 4967 7.3.596 can't remove all signs for a file or buffer + 21669 7.3.597 'clipboard' "autoselect" only applies to the * register + 2635 7.3.598 cannot act upon end of insert mode completion + 3042 7.3.599 (after 7.3.597) missing change in one file + 1572 7.3.600 is not expanded properly with DBCS encoding + 1492 7.3.601 bad code style + 1532 7.3.602 missing files in distribution + 11248 7.3.603 it is possible to add or replace builtin functions + 1861 7.3.604 inputdialog() doesn't use the cancel argument in the console diff --git a/vim.spec b/vim.spec index df600176..24c5bfc1 100644 --- a/vim.spec +++ b/vim.spec @@ -18,13 +18,13 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 594 +%define patchlevel 604 Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 2%{?dist} +Release: 1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -650,6 +650,16 @@ Patch591: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.591 Patch592: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.592 Patch593: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.593 Patch594: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.594 +Patch595: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.595 +Patch596: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.596 +Patch597: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.597 +Patch598: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.598 +Patch599: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.599 +Patch600: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.600 +Patch601: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.601 +Patch602: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.602 +Patch603: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.603 +Patch604: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.604 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1390,6 +1400,16 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch592 -p0 %patch593 -p0 %patch594 -p0 +%patch595 -p0 +%patch596 -p0 +%patch597 -p0 +%patch598 -p0 +%patch599 -p0 +%patch600 -p0 +%patch601 -p0 +%patch602 -p0 +%patch603 -p0 +%patch604 -p0 # install spell files @@ -1846,6 +1866,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Wed Jul 18 2012 Karsten Hopp 7.3.604-1 +- patchlevel 604 + * Wed Jul 11 2012 Petr Pisar - 2:7.3.594-2 - Perl 5.16 rebuild From 48d1e3411746aee61a4160021cfb8d51074639e1 Mon Sep 17 00:00:00 2001 From: Daniel Mach Date: Mon, 23 Jul 2012 14:39:07 -0400 Subject: [PATCH 0355/3340] Reset content to fedora/master --- vim.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vim.spec b/vim.spec index fcb6cebf..24c5bfc1 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 2%{?dist} +Release: 1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 From e8f4d6140a0c3f144d7c31df1a31fe079ac39eef Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 11:32:07 +0200 Subject: [PATCH 0356/3340] drop vim-6.1-rh3.patch, bz #754801 --- vim-6.1-rh3.patch | 11 ----------- vim.spec | 24 ++++++++++++------------ 2 files changed, 12 insertions(+), 23 deletions(-) delete mode 100644 vim-6.1-rh3.patch diff --git a/vim-6.1-rh3.patch b/vim-6.1-rh3.patch deleted file mode 100644 index 5d3b8cfc..00000000 --- a/vim-6.1-rh3.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- vim61/runtime/scripts.vim.rh3 2003-02-12 13:00:49.000000000 +0100 -+++ vim61/runtime/scripts.vim 2003-02-12 13:01:37.000000000 +0100 -@@ -22,6 +22,8 @@ - endif - endif - -+set formatoptions=tcql nocindent comments& -+ - " Line continuation is used here, remove 'C' from 'cpoptions' - let s:cpo_save = &cpo - set cpo&vim diff --git a/vim.spec b/vim.spec index 24c5bfc1..7d50bfba 100644 --- a/vim.spec +++ b/vim.spec @@ -663,15 +663,14 @@ Patch604: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.604 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch -Patch3003: vim-6.1-rh3.patch -Patch3004: vim-7.0-rclocation.patch -Patch3006: vim-6.4-checkhl.patch -Patch3007: vim-7.3-fstabsyntax.patch -Patch3008: vim-7.0-warning.patch -Patch3009: vim-7.0-syncolor.patch -Patch3010: vim-7.0-specedit.patch -Patch3011: vim72-rh514717.patch -Patch3012: vim-7.3-bug816848.patch +Patch3003: vim-7.0-rclocation.patch +Patch3004: vim-6.4-checkhl.patch +Patch3005: vim-7.3-fstabsyntax.patch +Patch3006: vim-7.0-warning.patch +Patch3007: vim-7.0-syncolor.patch +Patch3008: vim-7.0-specedit.patch +Patch3009: vim72-rh514717.patch +Patch3010: vim-7.3-bug816848.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel ncurses-devel gettext perl-devel @@ -1421,14 +1420,12 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch3002 -p1 %patch3003 -p1 %patch3004 -p1 - +%patch3005 -p1 %patch3006 -p1 %patch3007 -p1 %patch3008 -p1 %patch3009 -p1 %patch3010 -p1 -%patch3011 -p1 -%patch3012 -p1 %build cp -f %{SOURCE5} . @@ -1866,6 +1863,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Aug 06 2012 Karsten Hopp 7.3.604-1 +- drop vim-6.1-rh3.patch, (bz #754801) + * Wed Jul 18 2012 Karsten Hopp 7.3.604-1 - patchlevel 604 From 0a3b5072e00b010bc41b94c36025d32b7ec3c1f2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:19 +0200 Subject: [PATCH 0357/3340] - patchlevel 605 --- 7.3.605 | 86 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 7.3.605 diff --git a/7.3.605 b/7.3.605 new file mode 100644 index 00000000..70338251 --- /dev/null +++ b/7.3.605 @@ -0,0 +1,86 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.605 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.605 (after 7.3.577) +Problem: MS-Windows: Can't compile with older compilers. (Titov Anatoly) +Solution: Add #ifdef for MEMORYSTATUSEX. +Files: src/os_win32.c + + +*** ../vim-7.3.604/src/os_win32.c 2012-06-29 15:51:26.000000000 +0200 +--- src/os_win32.c 2012-07-19 11:35:00.000000000 +0200 +*************** +*** 4999,5020 **** + long_u + mch_avail_mem(int special) + { +! if (g_PlatformId != VER_PLATFORM_WIN32_NT) +! { +! MEMORYSTATUS ms; +! +! ms.dwLength = sizeof(MEMORYSTATUS); +! GlobalMemoryStatus(&ms); +! return (long_u)((ms.dwAvailPhys + ms.dwAvailPageFile) >> 10); +! } +! else + { + MEMORYSTATUSEX ms; + + ms.dwLength = sizeof(MEMORYSTATUSEX); + GlobalMemoryStatusEx(&ms); + return (long_u)((ms.ullAvailPhys + ms.ullAvailPageFile) >> 10); + } + } + + #ifdef FEAT_MBYTE +--- 4999,5025 ---- + long_u + mch_avail_mem(int special) + { +! #ifdef MEMORYSTATUSEX +! PlatformId(); +! if (g_PlatformId == VER_PLATFORM_WIN32_NT) + { + MEMORYSTATUSEX ms; + ++ /* Need to use GlobalMemoryStatusEx() when there is more memory than ++ * what fits in 32 bits. But it's not always available. */ + ms.dwLength = sizeof(MEMORYSTATUSEX); + GlobalMemoryStatusEx(&ms); + return (long_u)((ms.ullAvailPhys + ms.ullAvailPageFile) >> 10); + } ++ else ++ #endif ++ { ++ MEMORYSTATUS ms; ++ ++ ms.dwLength = sizeof(MEMORYSTATUS); ++ GlobalMemoryStatus(&ms); ++ return (long_u)((ms.dwAvailPhys + ms.dwAvailPageFile) >> 10); ++ } + } + + #ifdef FEAT_MBYTE +*** ../vim-7.3.604/src/version.c 2012-07-16 19:27:25.000000000 +0200 +--- src/version.c 2012-07-19 11:36:12.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 605, + /**/ + +-- +Fingers not found - Pound head on keyboard to continue. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 97dc5af1a5d39fab0a68443df82b88146cab96f3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:20 +0200 Subject: [PATCH 0358/3340] - patchlevel 606 --- 7.3.606 | 76 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 7.3.606 diff --git a/7.3.606 b/7.3.606 new file mode 100644 index 00000000..2296653c --- /dev/null +++ b/7.3.606 @@ -0,0 +1,76 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.606 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.606 +Problem: CTRL-P completion has a problem with multi-byte characters. +Solution: Check for next character being NUL properly. (Yasuhiro Matsumoto) +Files: src/search.c, src/macros.h + + +*** ../vim-7.3.605/src/search.c 2012-06-06 16:12:54.000000000 +0200 +--- src/search.c 2012-07-19 17:09:20.000000000 +0200 +*************** +*** 5141,5147 **** + && !(compl_cont_status & CONT_SOL) + #endif + && *startp != NUL +! && *(p = startp + 1) != NUL) + goto search_line; + } + line_breakcheck(); +--- 5141,5147 ---- + && !(compl_cont_status & CONT_SOL) + #endif + && *startp != NUL +! && *(p = startp + MB_PTR2LEN(startp)) != NUL) + goto search_line; + } + line_breakcheck(); +*** ../vim-7.3.605/src/macros.h 2010-09-21 16:56:29.000000000 +0200 +--- src/macros.h 2012-07-19 17:08:38.000000000 +0200 +*************** +*** 259,264 **** +--- 259,266 ---- + * PTR2CHAR(): get character from pointer. + */ + #ifdef FEAT_MBYTE ++ /* Get the length of the character p points to */ ++ # define MB_PTR2LEN(p) (has_mbyte ? (*mb_ptr2len)(p) : 1) + /* Advance multi-byte pointer, skip over composing chars. */ + # define mb_ptr_adv(p) p += has_mbyte ? (*mb_ptr2len)(p) : 1 + /* Advance multi-byte pointer, do not skip over composing chars. */ +*************** +*** 272,277 **** +--- 274,280 ---- + # define MB_CHARLEN(p) (has_mbyte ? mb_charlen(p) : (int)STRLEN(p)) + # define PTR2CHAR(p) (has_mbyte ? mb_ptr2char(p) : (int)*(p)) + #else ++ # define MB_PTR2LEN(p) 1 + # define mb_ptr_adv(p) ++p + # define mb_cptr_adv(p) ++p + # define mb_ptr_back(s, p) --p +*** ../vim-7.3.605/src/version.c 2012-07-19 11:37:22.000000000 +0200 +--- src/version.c 2012-07-19 17:13:53.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 606, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +151. You find yourself engaged to someone you've never actually met, + except through e-mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0c0392228b94ba75cac7f689e1cbd29b63e3e281 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:20 +0200 Subject: [PATCH 0359/3340] - patchlevel 607 --- 7.3.607 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.607 diff --git a/7.3.607 b/7.3.607 new file mode 100644 index 00000000..4dbf559d --- /dev/null +++ b/7.3.607 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.607 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.607 +Problem: With an 8 color terminal the selected menu item is black on black, + because darkGrey as bg is the same as black. +Solution: Swap fg and bg colors. (James McCoy) +Files: src/syntax.c + + +*** ../vim-7.3.606/src/syntax.c 2012-06-01 13:18:48.000000000 +0200 +--- src/syntax.c 2012-07-19 17:34:42.000000000 +0200 +*************** +*** 6653,6660 **** + "PmenuThumb ctermbg=White guibg=White"), + CENT("Pmenu ctermbg=Magenta ctermfg=Black", + "Pmenu ctermbg=Magenta ctermfg=Black guibg=Magenta"), +! CENT("PmenuSel ctermbg=DarkGrey ctermfg=Black", +! "PmenuSel ctermbg=DarkGrey ctermfg=Black guibg=DarkGrey"), + #endif + CENT("Title term=bold ctermfg=LightMagenta", + "Title term=bold ctermfg=LightMagenta gui=bold guifg=Magenta"), +--- 6653,6660 ---- + "PmenuThumb ctermbg=White guibg=White"), + CENT("Pmenu ctermbg=Magenta ctermfg=Black", + "Pmenu ctermbg=Magenta ctermfg=Black guibg=Magenta"), +! CENT("PmenuSel ctermbg=Black ctermfg=DarkGrey", +! "PmenuSel ctermbg=Black ctermfg=DarkGrey guibg=DarkGrey"), + #endif + CENT("Title term=bold ctermfg=LightMagenta", + "Title term=bold ctermfg=LightMagenta gui=bold guifg=Magenta"), +*** ../vim-7.3.606/src/version.c 2012-07-19 17:18:21.000000000 +0200 +--- src/version.c 2012-07-19 17:38:05.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 607, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +152. You find yourself falling for someone you've never seen or hardly + know, but, boy can he/she TYPE!!!!!! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 90c6e3f340f594d45dc9c387e5244602c6eba8aa Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:21 +0200 Subject: [PATCH 0360/3340] - patchlevel 608 --- 7.3.608 | 119 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 119 insertions(+) create mode 100644 7.3.608 diff --git a/7.3.608 b/7.3.608 new file mode 100644 index 00000000..148bc494 --- /dev/null +++ b/7.3.608 @@ -0,0 +1,119 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.608 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.608 +Problem: winrestview() does not always restore the view correctly. +Solution: Call win_new_height() and win_new_width(). (Lech Lorens) +Files: src/eval.c, src/proto/window.pro, src/window.c + + +*** ../vim-7.3.607/src/eval.c 2012-07-16 19:27:25.000000000 +0200 +--- src/eval.c 2012-07-19 17:50:16.000000000 +0200 +*************** +*** 18601,18606 **** +--- 18601,18610 ---- + curwin->w_skipcol = get_dict_number(dict, (char_u *)"skipcol"); + + check_cursor(); ++ win_new_height(curwin, curwin->w_height); ++ # ifdef FEAT_VERTSPLIT ++ win_new_width(curwin, W_WIDTH(curwin)); ++ # endif + changed_window_setting(); + + if (curwin->w_topline == 0) +*** ../vim-7.3.607/src/proto/window.pro 2012-06-13 14:28:16.000000000 +0200 +--- src/proto/window.pro 2012-07-19 18:05:10.000000000 +0200 +*************** +*** 51,56 **** +--- 51,58 ---- + void win_setminheight __ARGS((void)); + void win_drag_status_line __ARGS((win_T *dragwin, int offset)); + void win_drag_vsep_line __ARGS((win_T *dragwin, int offset)); ++ void win_new_height __ARGS((win_T *wp, int height)); ++ void win_new_width __ARGS((win_T *wp, int width)); + void win_comp_scroll __ARGS((win_T *wp)); + void command_height __ARGS((void)); + void last_status __ARGS((int morewin)); +*** ../vim-7.3.607/src/window.c 2012-07-16 17:31:48.000000000 +0200 +--- src/window.c 2012-07-19 18:05:18.000000000 +0200 +*************** +*** 54,60 **** + static void frame_insert __ARGS((frame_T *before, frame_T *frp)); + static void frame_remove __ARGS((frame_T *frp)); + #ifdef FEAT_VERTSPLIT +- static void win_new_width __ARGS((win_T *wp, int width)); + static void win_goto_ver __ARGS((int up, long count)); + static void win_goto_hor __ARGS((int left, long count)); + #endif +--- 54,59 ---- +*************** +*** 71,77 **** + + static win_T *win_alloc __ARGS((win_T *after, int hidden)); + static void set_fraction __ARGS((win_T *wp)); +- static void win_new_height __ARGS((win_T *wp, int height)); + + #define URL_SLASH 1 /* path_is_url() has found "://" */ + #define URL_BACKSLASH 2 /* path_is_url() has found ":\\" */ +--- 70,75 ---- +*************** +*** 5557,5563 **** + * This takes care of the things inside the window, not what happens to the + * window position, the frame or to other windows. + */ +! static void + win_new_height(wp, height) + win_T *wp; + int height; +--- 5555,5561 ---- + * This takes care of the things inside the window, not what happens to the + * window position, the frame or to other windows. + */ +! void + win_new_height(wp, height) + win_T *wp; + int height; +*************** +*** 5697,5703 **** + /* + * Set the width of a window. + */ +! static void + win_new_width(wp, width) + win_T *wp; + int width; +--- 5695,5701 ---- + /* + * Set the width of a window. + */ +! void + win_new_width(wp, width) + win_T *wp; + int width; +*** ../vim-7.3.607/src/version.c 2012-07-19 17:39:01.000000000 +0200 +--- src/version.c 2012-07-19 17:53:37.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 608, + /**/ + +-- +Although the scythe isn't pre-eminent among the weapons of war, anyone who +has been on the wrong end of, say, a peasants' revolt will know that in +skilled hands it is fearsome. + -- (Terry Pratchett, Mort) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a4e9cd4a963645b9a32d69a7c4e576ea06377dad Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:21 +0200 Subject: [PATCH 0361/3340] - patchlevel 609 --- 7.3.609 | 251 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 251 insertions(+) create mode 100644 7.3.609 diff --git a/7.3.609 b/7.3.609 new file mode 100644 index 00000000..ed731f50 --- /dev/null +++ b/7.3.609 @@ -0,0 +1,251 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.609 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.609 +Problem: File names in :checkpath! output are garbled. +Solution: Check for \zs in the pattern. (Lech Lorens) +Files: src/search.c, src/testdir/test17.in, src/testdir/test17.ok + + +*** ../vim-7.3.608/src/search.c 2012-07-19 17:18:21.000000000 +0200 +--- src/search.c 2012-07-25 13:33:08.000000000 +0200 +*************** +*** 4740,4756 **** + * Isolate the file name. + * Include the surrounding "" or <> if present. + */ +! for (p = incl_regmatch.endp[0]; !vim_isfilec(*p); p++) +! ; +! for (i = 0; vim_isfilec(p[i]); i++) +! ; + if (i == 0) + { + /* Nothing found, use the rest of the line. */ + p = incl_regmatch.endp[0]; + i = (int)STRLEN(p); + } +! else + { + if (p[-1] == '"' || p[-1] == '<') + { +--- 4740,4772 ---- + * Isolate the file name. + * Include the surrounding "" or <> if present. + */ +! if (inc_opt != NULL +! && strstr((char *)inc_opt, "\\zs") != NULL) +! { +! /* pattern contains \zs, use the match */ +! p = incl_regmatch.startp[0]; +! i = (int)(incl_regmatch.endp[0] +! - incl_regmatch.startp[0]); +! } +! else +! { +! /* find the file name after the end of the match */ +! for (p = incl_regmatch.endp[0]; +! *p && !vim_isfilec(*p); p++) +! ; +! for (i = 0; vim_isfilec(p[i]); i++) +! ; +! } +! + if (i == 0) + { + /* Nothing found, use the rest of the line. */ + p = incl_regmatch.endp[0]; + i = (int)STRLEN(p); + } +! /* Avoid checking before the start of the line, can +! * happen if \zs appears in the regexp. */ +! else if (p > line) + { + if (p[-1] == '"' || p[-1] == '<') + { +*** ../vim-7.3.608/src/testdir/test17.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test17.in 2012-07-25 13:41:43.000000000 +0200 +*************** +*** 1,4 **** +! Tests for "gf" on ${VAR} + + STARTTEST + :so small.vim +--- 1,6 ---- +! Tests for: +! - "gf" on ${VAR}, +! - ":checkpath!" with various 'include' settings. + + STARTTEST + :so small.vim +*************** +*** 20,27 **** + :endif + gf + :w! test.out +! :qa! + ENDTEST + + ${CDIR}/test17a.in + $TDIR/test17a.in +--- 22,120 ---- + :endif + gf + :w! test.out +! :brewind + ENDTEST + + ${CDIR}/test17a.in + $TDIR/test17a.in ++ ++ STARTTEST ++ :" check for 'include' without \zs or \ze ++ :lang C ++ :!rm -f ./Xbase.a ++ :!rm -rf ./Xdir1 ++ :!mkdir -p Xdir1/dir2 ++ :e Xdir1/dir2/foo.a ++ i#include "bar.a" ++ :w ++ :e Xdir1/dir2/bar.a ++ i#include "baz.a" ++ :w ++ :e Xdir1/dir2/baz.a ++ i#include "foo.a" ++ :w ++ :e Xbase.a ++ :set path=Xdir1/dir2 ++ i#include  ++ :w ++ :redir! >>test.out ++ :checkpath! ++ :redir END ++ :brewind ++ ENDTEST ++ ++ STARTTEST ++ :" check for 'include' with \zs and \ze ++ :!rm -f ./Xbase.b ++ :!rm -rf ./Xdir1 ++ :!mkdir -p Xdir1/dir2 ++ :let &include='^\s*%inc\s*/\zs[^/]\+\ze' ++ :function! DotsToSlashes() ++ : return substitute(v:fname, '\.', '/', 'g') . '.b' ++ :endfunction ++ :let &includeexpr='DotsToSlashes()' ++ :e Xdir1/dir2/foo.b ++ i%inc /bar/ ++ :w ++ :e Xdir1/dir2/bar.b ++ i%inc /baz/ ++ :w ++ :e Xdir1/dir2/baz.b ++ i%inc /foo/ ++ :w ++ :e Xbase.b ++ :set path=Xdir1/dir2 ++ i%inc /foo/ ++ :w ++ :redir! >>test.out ++ :checkpath! ++ :redir END ++ :brewind ++ ENDTEST ++ ++ STARTTEST ++ :" check for 'include' with \zs and no \ze ++ :!rm -f ./Xbase.c ++ :!rm -rf ./Xdir1 ++ :!mkdir -p Xdir1/dir2 ++ :let &include='^\s*%inc\s*\%([[:upper:]][^[:space:]]*\s\+\)\?\zs\S\+\ze' ++ :function! StripNewlineChar() ++ : if v:fname =~ '\n$' ++ : return v:fname[:-2] ++ : endif ++ : return v:fname ++ :endfunction ++ :let &includeexpr='StripNewlineChar()' ++ :e Xdir1/dir2/foo.c ++ i%inc bar.c ++ :w ++ :e Xdir1/dir2/bar.c ++ i%inc baz.c ++ :w ++ :e Xdir1/dir2/baz.c ++ i%inc foo.c ++ :w ++ :e Xdir1/dir2/FALSE.c ++ i%inc foo.c ++ :w ++ :e Xbase.c ++ :set path=Xdir1/dir2 ++ i%inc FALSE.c foo.c ++ :w ++ :redir! >>test.out ++ :checkpath! ++ :redir END ++ :brewind ++ :q ++ ENDTEST ++ +*** ../vim-7.3.608/src/testdir/test17.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test17.ok 2012-07-25 13:45:37.000000000 +0200 +*************** +*** 1,3 **** +--- 1,33 ---- + This file is just to test "gf" in test 17. + The contents is not important. + Just testing! ++ ++ ++ --- Included files in path --- ++ Xdir1/dir2/foo.a ++ Xdir1/dir2/foo.a --> ++ Xdir1/dir2/bar.a ++ Xdir1/dir2/bar.a --> ++ Xdir1/dir2/baz.a ++ Xdir1/dir2/baz.a --> ++ "foo.a" (Already listed) ++ ++ ++ --- Included files in path --- ++ Xdir1/dir2/foo.b ++ Xdir1/dir2/foo.b --> ++ Xdir1/dir2/bar.b ++ Xdir1/dir2/bar.b --> ++ Xdir1/dir2/baz.b ++ Xdir1/dir2/baz.b --> ++ foo (Already listed) ++ ++ ++ --- Included files in path --- ++ Xdir1/dir2/foo.c ++ Xdir1/dir2/foo.c --> ++ Xdir1/dir2/bar.c ++ Xdir1/dir2/bar.c --> ++ Xdir1/dir2/baz.c ++ Xdir1/dir2/baz.c --> ++ foo.c^@ (Already listed) +*** ../vim-7.3.608/src/version.c 2012-07-19 18:05:40.000000000 +0200 +--- src/version.c 2012-07-25 13:38:54.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 609, + /**/ + +-- +"The question of whether computers can think is just like the question +of whether submarines can swim." -- Edsger W. Dijkstra + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0815f721cc0b517a9d41556b18adc449b1a0493d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:27 +0200 Subject: [PATCH 0362/3340] - patchlevel 610 --- 7.3.610 | 400 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 400 insertions(+) create mode 100644 7.3.610 diff --git a/7.3.610 b/7.3.610 new file mode 100644 index 00000000..5e48837f --- /dev/null +++ b/7.3.610 @@ -0,0 +1,400 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.610 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.610 +Problem: Cannot operate on the text that a search pattern matches. +Solution: Add the "gn" and "gN" commands. (Christian Brabandt) +Files: runtime/doc/index.txt, runtime/doc/visual.txt, src/normal.c, + src/proto/search.pro, src/search.c, src/testdir/test53.in, + src/testdir/test53.ok + + +*** ../vim-7.3.609/runtime/doc/index.txt 2010-08-15 21:57:18.000000000 +0200 +--- runtime/doc/index.txt 2012-07-25 14:27:20.000000000 +0200 +*************** +*** 719,726 **** +--- 719,729 ---- + |gH| gH start Select line mode + |gI| gI 2 like "I", but always start in column 1 + |gJ| gJ 2 join lines without inserting space ++ |gN| gN 1,2 find the previous match with the last used ++ search pattern and Visually select it + |gP| ["x]gP 2 put the text [from register x] before the + cursor N times, leave the cursor after it ++ |gQ| gQ switch to "Ex" mode with Vim editing + |gR| gR 2 enter Virtual Replace mode + |gU| gU{motion} 2 make Nmove text uppercase + |gV| gV don't reselect the previous Visual area +*************** +*** 750,755 **** +--- 753,760 ---- + lines down + |gk| gk 1 like "k", but when 'wrap' on go N screen + lines up ++ |gn| gn 1,2 find the next match with the last used ++ search pattern and Visually select it + |gm| gm 1 go to character at middle of the screenline + |go| go 1 cursor to byte N in the buffer + |gp| ["x]gp 2 put the text [from register x] after the +*** ../vim-7.3.609/runtime/doc/visual.txt 2010-08-15 21:57:16.000000000 +0200 +--- runtime/doc/visual.txt 2012-07-25 14:42:22.000000000 +0200 +*************** +*** 94,99 **** +--- 99,116 ---- + After using "p" or "P" in Visual mode the text that + was put will be selected. + ++ *gn* *v_gn* ++ gn Search forward for the last used search pattern, like ++ with `n`, and start Visual mode to select the match. ++ If the cursor is on the match, visually selects it. ++ If an operator is pending, operates on the match. ++ E.g., "dgn" deletes the text of the next match. ++ If Visual mode is active, extends the selection ++ until the end of the next match. ++ ++ *gN* *v_gN* ++ gN Like |gn| but searches backward, like with `N`. ++ + ** + Set the current cursor position. If Visual mode is + active it is stopped. Only when 'mouse' option is +*** ../vim-7.3.609/src/normal.c 2012-07-10 16:49:08.000000000 +0200 +--- src/normal.c 2012-07-25 14:31:40.000000000 +0200 +*************** +*** 1780,1789 **** + { + /* Prepare for redoing. Only use the nchar field for "r", + * otherwise it might be the second char of the operator. */ +! prep_redo(oap->regname, 0L, NUL, 'v', +! get_op_char(oap->op_type), +! get_extra_op_char(oap->op_type), +! oap->op_type == OP_REPLACE ? cap->nchar : NUL); + if (!redo_VIsual_busy) + { + redo_VIsual_mode = resel_VIsual_mode; +--- 1780,1797 ---- + { + /* Prepare for redoing. Only use the nchar field for "r", + * otherwise it might be the second char of the operator. */ +! if (cap->cmdchar == 'g' && (cap->nchar == 'n' +! || cap->nchar == 'N')) +! /* "gn" and "gN" are a bit different */ +! prep_redo(oap->regname, 0L, NUL, cap->cmdchar, cap->nchar, +! get_op_char(oap->op_type), +! get_extra_op_char(oap->op_type)); +! else +! prep_redo(oap->regname, 0L, NUL, 'v', +! get_op_char(oap->op_type), +! get_extra_op_char(oap->op_type), +! oap->op_type == OP_REPLACE +! ? cap->nchar : NUL); + if (!redo_VIsual_busy) + { + redo_VIsual_mode = resel_VIsual_mode; +*************** +*** 7987,7992 **** +--- 7995,8011 ---- + cap->arg = TRUE; + nv_visual(cap); + break; ++ ++ /* "gn", "gN" visually select next/previous search match ++ * "gn" selects next match ++ * "gN" selects previous match ++ */ ++ case 'N': ++ case 'n': ++ if (!current_search(cap->count1, cap->nchar == 'n')) ++ beep_flush(); ++ ++ break; + #endif /* FEAT_VISUAL */ + + /* +*** ../vim-7.3.609/src/proto/search.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/search.pro 2012-07-25 14:24:01.000000000 +0200 +*************** +*** 27,32 **** +--- 27,33 ---- + int end_word __ARGS((long count, int bigword, int stop, int empty)); + int bckend_word __ARGS((long count, int bigword, int eol)); + int current_word __ARGS((oparg_T *oap, long count, int include, int bigword)); ++ int current_search __ARGS((long count, int forward)); + int current_sent __ARGS((oparg_T *oap, long count, int include)); + int current_block __ARGS((oparg_T *oap, long count, int include, int what, int other)); + int current_tagblock __ARGS((oparg_T *oap, long count_arg, int include)); +*** ../vim-7.3.609/src/search.c 2012-07-25 13:46:25.000000000 +0200 +--- src/search.c 2012-07-25 14:54:28.000000000 +0200 +*************** +*** 3397,3402 **** +--- 3397,3547 ---- + return OK; + } + ++ #if defined(FEAT_VISUAL) || defined(PROTO) ++ /* ++ * Find next search match under cursor, cursor at end. ++ * Used while an operator is pending, and in Visual mode. ++ * TODO: redo only works when used in operator pending mode ++ */ ++ int ++ current_search(count, forward) ++ long count; ++ int forward; /* move forward or backwards */ ++ { ++ pos_T start_pos; /* position before the pattern */ ++ pos_T orig_pos; /* position of the cursor at beginning */ ++ pos_T pos; /* position after the pattern */ ++ int i; ++ int dir; ++ int result; /* result of various function calls */ ++ char_u old_p_ws = p_ws; ++ int visual_active = FALSE; ++ int flags = 0; ++ pos_T save_VIsual; ++ ++ ++ /* wrapping should not occur */ ++ p_ws = FALSE; ++ ++ /* Correct cursor when 'selection' is exclusive */ ++ if (VIsual_active && *p_sel == 'e' && lt(VIsual, curwin->w_cursor)) ++ dec_cursor(); ++ ++ if (VIsual_active) ++ { ++ orig_pos = curwin->w_cursor; ++ save_VIsual = VIsual; ++ visual_active = TRUE; ++ ++ /* just started visual selection, only one character */ ++ if (equalpos(VIsual, curwin->w_cursor)) ++ visual_active = FALSE; ++ ++ pos = curwin->w_cursor; ++ start_pos = VIsual; ++ ++ /* make sure, searching further will extend the match */ ++ if (VIsual_active) ++ { ++ if (forward) ++ incl(&pos); ++ else ++ decl(&pos); ++ } ++ } ++ else ++ orig_pos = pos = start_pos = curwin->w_cursor; ++ ++ /* ++ * The trick is to first search backwards and then search forward again, ++ * so that a match at the current cursor position will be correctly ++ * captured. ++ */ ++ for (i = 0; i < 2; i++) ++ { ++ if (i && count == 1) ++ flags = SEARCH_START; ++ ++ if (forward) ++ dir = i; ++ else ++ dir = !i; ++ result = searchit(curwin, curbuf, &pos, (dir ? FORWARD : BACKWARD), ++ spats[last_idx].pat, (long) (i ? count : 1), ++ SEARCH_KEEP | flags | (dir ? 0 : SEARCH_END), ++ RE_SEARCH, 0, NULL); ++ ++ /* First search may fail, but then start searching from the ++ * beginning of the file (cursor might be on the search match) ++ * except when Visual mode is active, so that extending the visual ++ * selection works. */ ++ if (!result && i) /* not found, abort */ ++ { ++ curwin->w_cursor = orig_pos; ++ if (VIsual_active) ++ VIsual = save_VIsual; ++ p_ws = old_p_ws; ++ return FAIL; ++ } ++ else if (!i && !result && !visual_active) ++ { ++ if (forward) /* try again from start of buffer */ ++ { ++ clearpos(&pos); ++ } ++ else /* try again from end of buffer */ ++ { ++ /* searching backwards, so set pos to last line and col */ ++ pos.lnum = curwin->w_buffer->b_ml.ml_line_count; ++ pos.col = STRLEN(ml_get(curwin->w_buffer->b_ml.ml_line_count)); ++ } ++ } ++ ++ } ++ ++ start_pos = pos; ++ flags = (forward ? SEARCH_END : 0); ++ ++ /* move to match */ ++ result = searchit(curwin, curbuf, &pos, (forward ? FORWARD : BACKWARD), ++ spats[last_idx].pat, 0L, flags | SEARCH_KEEP, RE_SEARCH, 0, NULL); ++ ++ if (!VIsual_active) ++ VIsual = start_pos; ++ ++ p_ws = old_p_ws; ++ curwin->w_cursor = pos; ++ VIsual_active = TRUE; ++ VIsual_mode = 'v'; ++ ++ if (VIsual_active) ++ { ++ redraw_curbuf_later(INVERTED); /* update the inversion */ ++ if (*p_sel == 'e' && ltoreq(VIsual, curwin->w_cursor)) ++ inc_cursor(); ++ } ++ ++ #ifdef FEAT_FOLDING ++ if (fdo_flags & FDO_SEARCH && KeyTyped) ++ foldOpenCursor(); ++ #endif ++ ++ may_start_select('c'); ++ #ifdef FEAT_MOUSE ++ setmouse(); ++ #endif ++ #ifdef FEAT_CLIPBOARD ++ /* Make sure the clipboard gets updated. Needed because start and ++ * end are still the same, and the selection needs to be owned */ ++ clip_star.vmode = NUL; ++ #endif ++ redraw_curbuf_later(INVERTED); ++ showmode(); ++ ++ return OK; ++ } ++ #endif /* FEAT_VISUAL */ ++ + /* + * Find sentence(s) under the cursor, cursor at end. + * When Visual active, extend it by one or more sentences. +*************** +*** 3420,3426 **** + + #ifdef FEAT_VISUAL + /* +! * When visual area is bigger than one character: Extend it. + */ + if (VIsual_active && !equalpos(start_pos, VIsual)) + { +--- 3565,3571 ---- + + #ifdef FEAT_VISUAL + /* +! * When the Visual area is bigger than one character: Extend it. + */ + if (VIsual_active && !equalpos(start_pos, VIsual)) + { +*************** +*** 3508,3515 **** + #endif + + /* +! * If cursor started on blank, check if it is just before the start of the +! * next sentence. + */ + while (c = gchar_pos(&pos), vim_iswhite(c)) /* vim_iswhite() is a macro */ + incl(&pos); +--- 3653,3660 ---- + #endif + + /* +! * If the cursor started on a blank, check if it is just before the start +! * of the next sentence. + */ + while (c = gchar_pos(&pos), vim_iswhite(c)) /* vim_iswhite() is a macro */ + incl(&pos); +*************** +*** 3558,3564 **** + #ifdef FEAT_VISUAL + if (VIsual_active) + { +! /* avoid getting stuck with "is" on a single space before a sent. */ + if (equalpos(start_pos, curwin->w_cursor)) + goto extend; + if (*p_sel == 'e') +--- 3703,3709 ---- + #ifdef FEAT_VISUAL + if (VIsual_active) + { +! /* Avoid getting stuck with "is" on a single space before a sentence. */ + if (equalpos(start_pos, curwin->w_cursor)) + goto extend; + if (*p_sel == 'e') +*** ../vim-7.3.609/src/testdir/test53.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test53.in 2012-07-25 15:01:34.000000000 +0200 +*************** +*** 28,33 **** +--- 28,40 ---- + :put =matchstr(\"abcd\", \".\", 0, -1) " a + :put =match(\"abcd\", \".\", 0, 5) " -1 + :put =match(\"abcd\", \".\", 0, -1) " 0 ++ /^foobar ++ gncsearchmatch/one\_s*two\_s ++ :1 ++ gnd ++ /[a]bcdx ++ :1 ++ 2gnd + :/^start:/,/^end:/wq! test.out + ENDTEST + +*************** +*** 45,48 **** +--- 52,60 ---- + -asdfXasdfasdf- + -asdXasdfasdf- + ++ SEARCH: ++ foobar ++ one ++ two ++ abcdx | abcdx | abcdx + end: +*** ../vim-7.3.609/src/testdir/test53.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test53.ok 2012-07-25 14:24:01.000000000 +0200 +*************** +*** 18,21 **** +--- 18,24 ---- + a + -1 + 0 ++ SEARCH: ++ searchmatch ++ abcdx | | abcdx + end: +*** ../vim-7.3.609/src/version.c 2012-07-25 13:46:25.000000000 +0200 +--- src/version.c 2012-07-25 15:03:43.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 610, + /**/ + +-- +Did you ever see a "Hit any key to continue" message in a music piece? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b051acf4d21730a8ce31c8427f0857c79b631b0a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:27 +0200 Subject: [PATCH 0363/3340] - patchlevel 611 --- 7.3.611 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.611 diff --git a/7.3.611 b/7.3.611 new file mode 100644 index 00000000..5e366a78 --- /dev/null +++ b/7.3.611 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.611 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.611 +Problem: Can't use Vim dictionary as self argument in Python. +Solution: Fix the check for the "self" argument. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.610/src/if_py_both.h 2012-06-30 13:34:29.000000000 +0200 +--- src/if_py_both.h 2012-07-25 15:32:10.000000000 +0200 +*************** +*** 1284,1292 **** + selfdictObject = PyDict_GetItemString(kwargs, "self"); + if (selfdictObject != NULL) + { +! if (!PyDict_Check(selfdictObject)) + { +! PyErr_SetString(PyExc_TypeError, _("'self' argument must be a dictionary")); + clear_tv(&args); + return NULL; + } +--- 1284,1293 ---- + selfdictObject = PyDict_GetItemString(kwargs, "self"); + if (selfdictObject != NULL) + { +! if (!PyMapping_Check(selfdictObject)) + { +! PyErr_SetString(PyExc_TypeError, +! _("'self' argument must be a dictionary")); + clear_tv(&args); + return NULL; + } +*** ../vim-7.3.610/src/version.c 2012-07-25 15:06:20.000000000 +0200 +--- src/version.c 2012-07-25 15:32:24.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 611, + /**/ + +-- +In Joseph Heller's novel "Catch-22", the main character tries to get out of a +war by proving he is crazy. But the mere fact he wants to get out of the war +only shows he isn't crazy -- creating the original "Catch-22". + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5335496f8da4264afd2d03c59f502651e1d91a86 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:28 +0200 Subject: [PATCH 0364/3340] - patchlevel 612 --- 7.3.612 | 83 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 7.3.612 diff --git a/7.3.612 b/7.3.612 new file mode 100644 index 00000000..7b2207ed --- /dev/null +++ b/7.3.612 @@ -0,0 +1,83 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.612 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.612 +Problem: Auto formatting messes up text when 'fo' contains "2". (ZyX) +Solution: Decrement "less_cols". (Tor Perkins) +Files: src/misc1.c, src/testdir/test68.in, src/testdir/test68.ok + + +*** ../vim-7.3.611/src/misc1.c 2012-07-06 16:49:37.000000000 +0200 +--- src/misc1.c 2012-07-25 16:03:58.000000000 +0200 +*************** +*** 1329,1334 **** +--- 1329,1335 ---- + for (i = 0; i < padding; i++) + { + STRCAT(leader, " "); ++ less_cols--; + newcol++; + } + } +*** ../vim-7.3.611/src/testdir/test68.in 2012-06-29 15:04:34.000000000 +0200 +--- src/testdir/test68.in 2012-07-25 15:57:06.000000000 +0200 +*************** +*** 94,99 **** +--- 94,109 ---- + } + + STARTTEST ++ /mno pqr/ ++ :setl tw=20 fo=an12wcq comments=s1:/*,mb:*,ex:*/ ++ A vwx yz ++ ENDTEST ++ ++ /* abc def ghi jkl ++ * mno pqr stu ++ */ ++ ++ STARTTEST + /^#/ + :setl tw=12 fo=tqnc comments=:# + A foobar +*** ../vim-7.3.611/src/testdir/test68.ok 2012-06-29 23:57:50.000000000 +0200 +--- src/testdir/test68.ok 2012-07-25 16:03:05.000000000 +0200 +*************** +*** 57,62 **** +--- 57,68 ---- + { 1aa ^^2bb } + + ++ /* abc def ghi jkl ++ * mno pqr stu ++ * vwx yz ++ */ ++ ++ + # 1 xxxxx + # foobar + +*** ../vim-7.3.611/src/version.c 2012-07-25 15:36:00.000000000 +0200 +--- src/version.c 2012-07-25 16:08:02.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 612, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +169. You hire a housekeeper for your home page. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c70f0167983fe48749ed938f92aec37915a1ed20 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:28 +0200 Subject: [PATCH 0365/3340] - patchlevel 613 --- 7.3.613 | 149 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 149 insertions(+) create mode 100644 7.3.613 diff --git a/7.3.613 b/7.3.613 new file mode 100644 index 00000000..520e87c3 --- /dev/null +++ b/7.3.613 @@ -0,0 +1,149 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.613 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.613 +Problem: Including Python's config.c in the build causes trouble. It is + not clear why it was there. +Solution: Omit the config file. (James McCoy) +Files: src/Makefile, src/auto/configure, src/configure.in + + +*** ../vim-7.3.612/src/Makefile 2012-06-20 18:39:12.000000000 +0200 +--- src/Makefile 2012-07-25 16:22:57.000000000 +0200 +*************** +*** 2559,2577 **** + objects/if_perlsfio.o: if_perlsfio.c + $(CCC) $(PERL_CFLAGS) -o $@ if_perlsfio.c + +- objects/py_config.o: $(PYTHON_CONFDIR)/config.c +- $(CCC) $(PYTHON_CFLAGS) -o $@ $(PYTHON_CONFDIR)/config.c \ +- -I$(PYTHON_CONFDIR) -DHAVE_CONFIG_H -DNO_MAIN +- + objects/py_getpath.o: $(PYTHON_CONFDIR)/getpath.c + $(CCC) $(PYTHON_CFLAGS) -o $@ $(PYTHON_CONFDIR)/getpath.c \ + -I$(PYTHON_CONFDIR) -DHAVE_CONFIG_H -DNO_MAIN \ + $(PYTHON_GETPATH_CFLAGS) + +- objects/py3_config.o: $(PYTHON3_CONFDIR)/config.c +- $(CCC) $(PYTHON3_CFLAGS) -o $@ $(PYTHON3_CONFDIR)/config.c \ +- -I$(PYTHON3_CONFDIR) -DHAVE_CONFIG_H -DNO_MAIN +- + objects/if_python.o: if_python.c if_py_both.h + $(CCC) $(PYTHON_CFLAGS) $(PYTHON_CFLAGS_EXTRA) -o $@ if_python.c + +--- 2559,2569 ---- +*** ../vim-7.3.612/src/auto/configure 2012-06-13 19:19:36.000000000 +0200 +--- src/auto/configure 2012-07-25 16:23:49.000000000 +0200 +*************** +*** 5357,5367 **** + PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\"" + fi + PYTHON_SRC="if_python.c" +! if test "x$MACOSX" = "xyes"; then +! PYTHON_OBJ="objects/if_python.o" +! else +! PYTHON_OBJ="objects/if_python.o objects/py_config.o" +! fi + if test "${vi_cv_var_python_version}" = "1.4"; then + PYTHON_OBJ="$PYTHON_OBJ objects/py_getpath.o" + fi +--- 5357,5363 ---- + PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\"" + fi + PYTHON_SRC="if_python.c" +! PYTHON_OBJ="objects/if_python.o" + if test "${vi_cv_var_python_version}" = "1.4"; then + PYTHON_OBJ="$PYTHON_OBJ objects/py_getpath.o" + fi +*************** +*** 5656,5666 **** + PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" + fi + PYTHON3_SRC="if_python3.c" +! if test "x$MACOSX" = "xyes"; then +! PYTHON3_OBJ="objects/if_python3.o" +! else +! PYTHON3_OBJ="objects/if_python3.o objects/py3_config.o" +! fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -pthread should be used" >&5 + $as_echo_n "checking if -pthread should be used... " >&6; } +--- 5652,5658 ---- + PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" + fi + PYTHON3_SRC="if_python3.c" +! PYTHON3_OBJ="objects/if_python3.o" + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -pthread should be used" >&5 + $as_echo_n "checking if -pthread should be used... " >&6; } +*** ../vim-7.3.612/src/configure.in 2012-06-13 19:19:36.000000000 +0200 +--- src/configure.in 2012-07-25 16:23:41.000000000 +0200 +*************** +*** 916,927 **** + PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\"" + fi + PYTHON_SRC="if_python.c" +! dnl For Mac OSX 10.2 config.o is included in the Python library. +! if test "x$MACOSX" = "xyes"; then +! PYTHON_OBJ="objects/if_python.o" +! else +! PYTHON_OBJ="objects/if_python.o objects/py_config.o" +! fi + if test "${vi_cv_var_python_version}" = "1.4"; then + PYTHON_OBJ="$PYTHON_OBJ objects/py_getpath.o" + fi +--- 916,922 ---- + PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\"" + fi + PYTHON_SRC="if_python.c" +! PYTHON_OBJ="objects/if_python.o" + if test "${vi_cv_var_python_version}" = "1.4"; then + PYTHON_OBJ="$PYTHON_OBJ objects/py_getpath.o" + fi +*************** +*** 1106,1117 **** + PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" + fi + PYTHON3_SRC="if_python3.c" +! dnl For Mac OSX 10.2 config.o is included in the Python library. +! if test "x$MACOSX" = "xyes"; then +! PYTHON3_OBJ="objects/if_python3.o" +! else +! PYTHON3_OBJ="objects/if_python3.o objects/py3_config.o" +! fi + + dnl On FreeBSD linking with "-pthread" is required to use threads. + dnl _THREAD_SAFE must be used for compiling then. +--- 1101,1107 ---- + PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" + fi + PYTHON3_SRC="if_python3.c" +! PYTHON3_OBJ="objects/if_python3.o" + + dnl On FreeBSD linking with "-pthread" is required to use threads. + dnl _THREAD_SAFE must be used for compiling then. +*** ../vim-7.3.612/src/version.c 2012-07-25 16:09:59.000000000 +0200 +--- src/version.c 2012-07-25 16:29:52.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 613, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +170. You introduce your wife as "my_lady@home.wife" and refer to your + children as "forked processes." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6867636db9a7395c15b0286b02a51de969283d0e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:28 +0200 Subject: [PATCH 0366/3340] - patchlevel 614 --- 7.3.614 | 176 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 176 insertions(+) create mode 100644 7.3.614 diff --git a/7.3.614 b/7.3.614 new file mode 100644 index 00000000..87d7a451 --- /dev/null +++ b/7.3.614 @@ -0,0 +1,176 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.614 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.614 +Problem: Number argument gets turned into a number while it should be a + string. +Solution: Add flag to the call_vim_function() call. (Yasuhiro Matsumoto) +Files: src/edit.c, src/eval.c, src/proto/eval.pro + + +*** ../vim-7.3.613/src/edit.c 2012-07-10 17:14:50.000000000 +0200 +--- src/edit.c 2012-07-25 16:40:07.000000000 +0200 +*************** +*** 3959,3965 **** + curbuf_save = curbuf; + + /* Call a function, which returns a list or dict. */ +! if (call_vim_function(funcname, 2, args, FALSE, &rettv) == OK) + { + switch (rettv.v_type) + { +--- 3959,3965 ---- + curbuf_save = curbuf; + + /* Call a function, which returns a list or dict. */ +! if (call_vim_function(funcname, 2, args, FALSE, FALSE, &rettv) == OK) + { + switch (rettv.v_type) + { +*** ../vim-7.3.613/src/eval.c 2012-07-19 18:05:40.000000000 +0200 +--- src/eval.c 2012-07-25 16:42:41.000000000 +0200 +*************** +*** 1564,1574 **** + * Returns OK or FAIL. + */ + int +! call_vim_function(func, argc, argv, safe, rettv) + char_u *func; + int argc; + char_u **argv; + int safe; /* use the sandbox */ + typval_T *rettv; + { + typval_T *argvars; +--- 1564,1575 ---- + * Returns OK or FAIL. + */ + int +! call_vim_function(func, argc, argv, safe, str_arg_only, rettv) + char_u *func; + int argc; + char_u **argv; + int safe; /* use the sandbox */ ++ int str_arg_only; /* all arguments are strings */ + typval_T *rettv; + { + typval_T *argvars; +*************** +*** 1593,1600 **** + continue; + } + +! /* Recognize a number argument, the others must be strings. */ +! vim_str2nr(argv[i], NULL, &len, TRUE, TRUE, &n, NULL); + if (len != 0 && len == (int)STRLEN(argv[i])) + { + argvars[i].v_type = VAR_NUMBER; +--- 1594,1604 ---- + continue; + } + +! if (str_arg_only) +! len = 0; +! else +! /* Recognize a number argument, the others must be strings. */ +! vim_str2nr(argv[i], NULL, &len, TRUE, TRUE, &n, NULL); + if (len != 0 && len == (int)STRLEN(argv[i])) + { + argvars[i].v_type = VAR_NUMBER; +*************** +*** 1646,1652 **** + typval_T rettv; + char_u *retval; + +! if (call_vim_function(func, argc, argv, safe, &rettv) == FAIL) + return NULL; + + retval = vim_strsave(get_tv_string(&rettv)); +--- 1650,1657 ---- + typval_T rettv; + char_u *retval; + +! /* All arguments are passed as strings, no conversion to number. */ +! if (call_vim_function(func, argc, argv, safe, TRUE, &rettv) == FAIL) + return NULL; + + retval = vim_strsave(get_tv_string(&rettv)); +*************** +*** 1671,1677 **** + typval_T rettv; + long retval; + +! if (call_vim_function(func, argc, argv, safe, &rettv) == FAIL) + return -1; + + retval = get_tv_number_chk(&rettv, NULL); +--- 1676,1683 ---- + typval_T rettv; + long retval; + +! /* All arguments are passed as strings, no conversion to number. */ +! if (call_vim_function(func, argc, argv, safe, TRUE, &rettv) == FAIL) + return -1; + + retval = get_tv_number_chk(&rettv, NULL); +*************** +*** 1694,1700 **** + { + typval_T rettv; + +! if (call_vim_function(func, argc, argv, safe, &rettv) == FAIL) + return NULL; + + if (rettv.v_type != VAR_LIST) +--- 1700,1707 ---- + { + typval_T rettv; + +! /* All arguments are passed as strings, no conversion to number. */ +! if (call_vim_function(func, argc, argv, safe, TRUE, &rettv) == FAIL) + return NULL; + + if (rettv.v_type != VAR_LIST) +*** ../vim-7.3.613/src/proto/eval.pro 2012-07-16 17:31:48.000000000 +0200 +--- src/proto/eval.pro 2012-07-25 16:42:59.000000000 +0200 +*************** +*** 23,29 **** + list_T *eval_spell_expr __ARGS((char_u *badword, char_u *expr)); + int get_spellword __ARGS((list_T *list, char_u **pp)); + typval_T *eval_expr __ARGS((char_u *arg, char_u **nextcmd)); +! int call_vim_function __ARGS((char_u *func, int argc, char_u **argv, int safe, typval_T *rettv)); + void *call_func_retstr __ARGS((char_u *func, int argc, char_u **argv, int safe)); + long call_func_retnr __ARGS((char_u *func, int argc, char_u **argv, int safe)); + void *call_func_retlist __ARGS((char_u *func, int argc, char_u **argv, int safe)); +--- 23,29 ---- + list_T *eval_spell_expr __ARGS((char_u *badword, char_u *expr)); + int get_spellword __ARGS((list_T *list, char_u **pp)); + typval_T *eval_expr __ARGS((char_u *arg, char_u **nextcmd)); +! int call_vim_function __ARGS((char_u *func, int argc, char_u **argv, int safe, int str_arg_only, typval_T *rettv)); + void *call_func_retstr __ARGS((char_u *func, int argc, char_u **argv, int safe)); + long call_func_retnr __ARGS((char_u *func, int argc, char_u **argv, int safe)); + void *call_func_retlist __ARGS((char_u *func, int argc, char_u **argv, int safe)); +*** ../vim-7.3.613/src/version.c 2012-07-25 16:32:03.000000000 +0200 +--- src/version.c 2012-07-25 16:46:11.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 614, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +171. You invent another person and chat with yourself in empty chat rooms. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 87a864567483145b8619cc33f8a51627f3d7d345 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:34 +0200 Subject: [PATCH 0367/3340] - patchlevel 615 --- 7.3.615 | 107 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 107 insertions(+) create mode 100644 7.3.615 diff --git a/7.3.615 b/7.3.615 new file mode 100644 index 00000000..96f6885f --- /dev/null +++ b/7.3.615 @@ -0,0 +1,107 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.615 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.615 +Problem: Completion for a user command does not recognize backslash before + a space. +Solution: Recognize escaped characters. (Yasuhiro Matsumoto) +Files: src/ex_docmd.c + + +*** ../vim-7.3.614/src/ex_docmd.c 2012-07-10 19:25:06.000000000 +0200 +--- src/ex_docmd.c 2012-07-25 17:10:16.000000000 +0200 +*************** +*** 3390,3401 **** + return NULL; + + /* Find start of last argument (argument just before cursor): */ +! p = buff + STRLEN(buff); +! while (p != arg && *p != ' ' && *p != TAB) +! p--; +! if (*p == ' ' || *p == TAB) +! p++; + xp->xp_pattern = p; + + if (ea.argt & XFILE) + { +--- 3390,3412 ---- + return NULL; + + /* Find start of last argument (argument just before cursor): */ +! p = buff; + xp->xp_pattern = p; ++ len = STRLEN(buff); ++ while (*p && p < buff + len) ++ { ++ if (*p == ' ' || *p == TAB) ++ { ++ /* argument starts after a space */ ++ xp->xp_pattern = ++p; ++ } ++ else ++ { ++ if (*p == '\\' && *(p + 1) != NUL) ++ ++p; /* skip over escaped character */ ++ mb_ptr_adv(p); ++ } ++ } + + if (ea.argt & XFILE) + { +*************** +*** 3821,3828 **** + if (compl == EXPAND_MAPPINGS) + return set_context_in_map_cmd(xp, (char_u *)"map", + arg, forceit, FALSE, FALSE, CMD_map); +! while ((xp->xp_pattern = vim_strchr(arg, ' ')) != NULL) +! arg = xp->xp_pattern + 1; + xp->xp_pattern = arg; + } + xp->xp_context = compl; +--- 3832,3853 ---- + if (compl == EXPAND_MAPPINGS) + return set_context_in_map_cmd(xp, (char_u *)"map", + arg, forceit, FALSE, FALSE, CMD_map); +! /* Find start of last argument. */ +! p = arg; +! while (*p) +! { +! if (*p == ' ') +! { +! /* argument starts after a space */ +! arg = p + 1; +! } +! else +! { +! if (*p == '\\' && *(p + 1) != NUL) +! ++p; /* skip over escaped character */ +! mb_ptr_adv(p); +! } +! } + xp->xp_pattern = arg; + } + xp->xp_context = compl; +*** ../vim-7.3.614/src/version.c 2012-07-25 16:46:59.000000000 +0200 +--- src/version.c 2012-07-25 17:17:05.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 615, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +172. You join listservers just for the extra e-mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d8a15919e50490b4ecf9942f3c901752967829be Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:34 +0200 Subject: [PATCH 0368/3340] - patchlevel 616 --- 7.3.616 | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 7.3.616 diff --git a/7.3.616 b/7.3.616 new file mode 100644 index 00000000..5898eafe --- /dev/null +++ b/7.3.616 @@ -0,0 +1,46 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.616 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.616 (after 7.3.610) +Problem: Can't compile without +visual. +Solution: Add #ifdef. +Files: src/normal.c + + +*** ../vim-7.3.615/src/normal.c 2012-07-25 15:06:20.000000000 +0200 +--- src/normal.c 2012-07-27 20:52:01.000000000 +0200 +*************** +*** 8002,8008 **** +--- 8002,8010 ---- + */ + case 'N': + case 'n': ++ #ifdef FEAT_VISUAL + if (!current_search(cap->count1, cap->nchar == 'n')) ++ #endif + beep_flush(); + + break; +*** ../vim-7.3.615/src/version.c 2012-07-25 17:22:17.000000000 +0200 +--- src/version.c 2012-07-27 20:52:58.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 616, + /**/ + +-- +The CIA drives around in cars with the "Intel inside" logo. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8859237c8d6ccc682ccd1181abf14b55556b6df7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:40 +0200 Subject: [PATCH 0369/3340] - patchlevel 617 --- 7.3.617 | 65 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 7.3.617 diff --git a/7.3.617 b/7.3.617 new file mode 100644 index 00000000..48062cd2 --- /dev/null +++ b/7.3.617 @@ -0,0 +1,65 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.617 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.617 (after 7.3.615) +Problem: Hang on completion. +Solution: Skip over the space. (Yasuhiro Matsumoto) +Files: src/ex_docmd.c + + +*** ../vim-7.3.616/src/ex_docmd.c 2012-07-25 17:22:17.000000000 +0200 +--- src/ex_docmd.c 2012-07-27 21:07:42.000000000 +0200 +*************** +*** 3837,3852 **** + while (*p) + { + if (*p == ' ') +- { + /* argument starts after a space */ + arg = p + 1; +! } +! else +! { +! if (*p == '\\' && *(p + 1) != NUL) +! ++p; /* skip over escaped character */ +! mb_ptr_adv(p); +! } + } + xp->xp_pattern = arg; + } +--- 3837,3847 ---- + while (*p) + { + if (*p == ' ') + /* argument starts after a space */ + arg = p + 1; +! else if (*p == '\\' && *(p + 1) != NUL) +! ++p; /* skip over escaped character */ +! mb_ptr_adv(p); + } + xp->xp_pattern = arg; + } +*** ../vim-7.3.616/src/version.c 2012-07-27 21:05:51.000000000 +0200 +--- src/version.c 2012-07-27 21:08:31.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 617, + /**/ + +-- +If Microsoft would build a car... +... You'd have to press the "Start" button to turn the engine off. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fa58768ca596166a6fa3f884f2aff866b01f1b8f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:40 +0200 Subject: [PATCH 0370/3340] - patchlevel 618 --- 7.3.618 | 367 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 367 insertions(+) create mode 100644 7.3.618 diff --git a/7.3.618 b/7.3.618 new file mode 100644 index 00000000..d0cc9c68 --- /dev/null +++ b/7.3.618 @@ -0,0 +1,367 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.618 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.618 (after 7.3.616) +Problem: Still doesn't compile with small features. +Solution: Move current_search() out of #ifdef. (Dominique Pelle) +Files: src/normal.c, src/search.c + + +*** ../vim-7.3.617/src/normal.c 2012-07-27 21:05:51.000000000 +0200 +--- src/normal.c 2012-07-28 13:34:13.000000000 +0200 +*************** +*** 7995,8000 **** +--- 7995,8001 ---- + cap->arg = TRUE; + nv_visual(cap); + break; ++ #endif /* FEAT_VISUAL */ + + /* "gn", "gN" visually select next/previous search match + * "gn" selects next match +*************** +*** 8006,8014 **** + if (!current_search(cap->count1, cap->nchar == 'n')) + #endif + beep_flush(); +- + break; +- #endif /* FEAT_VISUAL */ + + /* + * "gj" and "gk" two new funny movement keys -- up and down +--- 8007,8013 ---- +*** ../vim-7.3.617/src/search.c 2012-07-25 15:06:20.000000000 +0200 +--- src/search.c 2012-07-28 13:37:19.000000000 +0200 +*************** +*** 3397,3547 **** + return OK; + } + +- #if defined(FEAT_VISUAL) || defined(PROTO) +- /* +- * Find next search match under cursor, cursor at end. +- * Used while an operator is pending, and in Visual mode. +- * TODO: redo only works when used in operator pending mode +- */ +- int +- current_search(count, forward) +- long count; +- int forward; /* move forward or backwards */ +- { +- pos_T start_pos; /* position before the pattern */ +- pos_T orig_pos; /* position of the cursor at beginning */ +- pos_T pos; /* position after the pattern */ +- int i; +- int dir; +- int result; /* result of various function calls */ +- char_u old_p_ws = p_ws; +- int visual_active = FALSE; +- int flags = 0; +- pos_T save_VIsual; +- +- +- /* wrapping should not occur */ +- p_ws = FALSE; +- +- /* Correct cursor when 'selection' is exclusive */ +- if (VIsual_active && *p_sel == 'e' && lt(VIsual, curwin->w_cursor)) +- dec_cursor(); +- +- if (VIsual_active) +- { +- orig_pos = curwin->w_cursor; +- save_VIsual = VIsual; +- visual_active = TRUE; +- +- /* just started visual selection, only one character */ +- if (equalpos(VIsual, curwin->w_cursor)) +- visual_active = FALSE; +- +- pos = curwin->w_cursor; +- start_pos = VIsual; +- +- /* make sure, searching further will extend the match */ +- if (VIsual_active) +- { +- if (forward) +- incl(&pos); +- else +- decl(&pos); +- } +- } +- else +- orig_pos = pos = start_pos = curwin->w_cursor; +- +- /* +- * The trick is to first search backwards and then search forward again, +- * so that a match at the current cursor position will be correctly +- * captured. +- */ +- for (i = 0; i < 2; i++) +- { +- if (i && count == 1) +- flags = SEARCH_START; +- +- if (forward) +- dir = i; +- else +- dir = !i; +- result = searchit(curwin, curbuf, &pos, (dir ? FORWARD : BACKWARD), +- spats[last_idx].pat, (long) (i ? count : 1), +- SEARCH_KEEP | flags | (dir ? 0 : SEARCH_END), +- RE_SEARCH, 0, NULL); +- +- /* First search may fail, but then start searching from the +- * beginning of the file (cursor might be on the search match) +- * except when Visual mode is active, so that extending the visual +- * selection works. */ +- if (!result && i) /* not found, abort */ +- { +- curwin->w_cursor = orig_pos; +- if (VIsual_active) +- VIsual = save_VIsual; +- p_ws = old_p_ws; +- return FAIL; +- } +- else if (!i && !result && !visual_active) +- { +- if (forward) /* try again from start of buffer */ +- { +- clearpos(&pos); +- } +- else /* try again from end of buffer */ +- { +- /* searching backwards, so set pos to last line and col */ +- pos.lnum = curwin->w_buffer->b_ml.ml_line_count; +- pos.col = STRLEN(ml_get(curwin->w_buffer->b_ml.ml_line_count)); +- } +- } +- +- } +- +- start_pos = pos; +- flags = (forward ? SEARCH_END : 0); +- +- /* move to match */ +- result = searchit(curwin, curbuf, &pos, (forward ? FORWARD : BACKWARD), +- spats[last_idx].pat, 0L, flags | SEARCH_KEEP, RE_SEARCH, 0, NULL); +- +- if (!VIsual_active) +- VIsual = start_pos; +- +- p_ws = old_p_ws; +- curwin->w_cursor = pos; +- VIsual_active = TRUE; +- VIsual_mode = 'v'; +- +- if (VIsual_active) +- { +- redraw_curbuf_later(INVERTED); /* update the inversion */ +- if (*p_sel == 'e' && ltoreq(VIsual, curwin->w_cursor)) +- inc_cursor(); +- } +- +- #ifdef FEAT_FOLDING +- if (fdo_flags & FDO_SEARCH && KeyTyped) +- foldOpenCursor(); +- #endif +- +- may_start_select('c'); +- #ifdef FEAT_MOUSE +- setmouse(); +- #endif +- #ifdef FEAT_CLIPBOARD +- /* Make sure the clipboard gets updated. Needed because start and +- * end are still the same, and the selection needs to be owned */ +- clip_star.vmode = NUL; +- #endif +- redraw_curbuf_later(INVERTED); +- showmode(); +- +- return OK; +- } +- #endif /* FEAT_VISUAL */ +- + /* + * Find sentence(s) under the cursor, cursor at end. + * When Visual active, extend it by one or more sentences. +--- 3397,3402 ---- +*************** +*** 4670,4675 **** +--- 4525,4675 ---- + + #endif /* FEAT_TEXTOBJ */ + ++ #if defined(FEAT_VISUAL) || defined(PROTO) ++ /* ++ * Find next search match under cursor, cursor at end. ++ * Used while an operator is pending, and in Visual mode. ++ * TODO: redo only works when used in operator pending mode ++ */ ++ int ++ current_search(count, forward) ++ long count; ++ int forward; /* move forward or backwards */ ++ { ++ pos_T start_pos; /* position before the pattern */ ++ pos_T orig_pos; /* position of the cursor at beginning */ ++ pos_T pos; /* position after the pattern */ ++ int i; ++ int dir; ++ int result; /* result of various function calls */ ++ char_u old_p_ws = p_ws; ++ int visual_active = FALSE; ++ int flags = 0; ++ pos_T save_VIsual; ++ ++ ++ /* wrapping should not occur */ ++ p_ws = FALSE; ++ ++ /* Correct cursor when 'selection' is exclusive */ ++ if (VIsual_active && *p_sel == 'e' && lt(VIsual, curwin->w_cursor)) ++ dec_cursor(); ++ ++ if (VIsual_active) ++ { ++ orig_pos = curwin->w_cursor; ++ save_VIsual = VIsual; ++ visual_active = TRUE; ++ ++ /* just started visual selection, only one character */ ++ if (equalpos(VIsual, curwin->w_cursor)) ++ visual_active = FALSE; ++ ++ pos = curwin->w_cursor; ++ start_pos = VIsual; ++ ++ /* make sure, searching further will extend the match */ ++ if (VIsual_active) ++ { ++ if (forward) ++ incl(&pos); ++ else ++ decl(&pos); ++ } ++ } ++ else ++ orig_pos = pos = start_pos = curwin->w_cursor; ++ ++ /* ++ * The trick is to first search backwards and then search forward again, ++ * so that a match at the current cursor position will be correctly ++ * captured. ++ */ ++ for (i = 0; i < 2; i++) ++ { ++ if (i && count == 1) ++ flags = SEARCH_START; ++ ++ if (forward) ++ dir = i; ++ else ++ dir = !i; ++ result = searchit(curwin, curbuf, &pos, (dir ? FORWARD : BACKWARD), ++ spats[last_idx].pat, (long) (i ? count : 1), ++ SEARCH_KEEP | flags | (dir ? 0 : SEARCH_END), ++ RE_SEARCH, 0, NULL); ++ ++ /* First search may fail, but then start searching from the ++ * beginning of the file (cursor might be on the search match) ++ * except when Visual mode is active, so that extending the visual ++ * selection works. */ ++ if (!result && i) /* not found, abort */ ++ { ++ curwin->w_cursor = orig_pos; ++ if (VIsual_active) ++ VIsual = save_VIsual; ++ p_ws = old_p_ws; ++ return FAIL; ++ } ++ else if (!i && !result && !visual_active) ++ { ++ if (forward) /* try again from start of buffer */ ++ { ++ clearpos(&pos); ++ } ++ else /* try again from end of buffer */ ++ { ++ /* searching backwards, so set pos to last line and col */ ++ pos.lnum = curwin->w_buffer->b_ml.ml_line_count; ++ pos.col = STRLEN(ml_get(curwin->w_buffer->b_ml.ml_line_count)); ++ } ++ } ++ ++ } ++ ++ start_pos = pos; ++ flags = (forward ? SEARCH_END : 0); ++ ++ /* move to match */ ++ result = searchit(curwin, curbuf, &pos, (forward ? FORWARD : BACKWARD), ++ spats[last_idx].pat, 0L, flags | SEARCH_KEEP, RE_SEARCH, 0, NULL); ++ ++ if (!VIsual_active) ++ VIsual = start_pos; ++ ++ p_ws = old_p_ws; ++ curwin->w_cursor = pos; ++ VIsual_active = TRUE; ++ VIsual_mode = 'v'; ++ ++ if (VIsual_active) ++ { ++ redraw_curbuf_later(INVERTED); /* update the inversion */ ++ if (*p_sel == 'e' && ltoreq(VIsual, curwin->w_cursor)) ++ inc_cursor(); ++ } ++ ++ #ifdef FEAT_FOLDING ++ if (fdo_flags & FDO_SEARCH && KeyTyped) ++ foldOpenCursor(); ++ #endif ++ ++ may_start_select('c'); ++ #ifdef FEAT_MOUSE ++ setmouse(); ++ #endif ++ #ifdef FEAT_CLIPBOARD ++ /* Make sure the clipboard gets updated. Needed because start and ++ * end are still the same, and the selection needs to be owned */ ++ clip_star.vmode = NUL; ++ #endif ++ redraw_curbuf_later(INVERTED); ++ showmode(); ++ ++ return OK; ++ } ++ #endif /* FEAT_VISUAL */ ++ + #if defined(FEAT_LISP) || defined(FEAT_CINDENT) || defined(FEAT_TEXTOBJ) \ + || defined(PROTO) + /* +*** ../vim-7.3.617/src/version.c 2012-07-27 21:12:03.000000000 +0200 +--- src/version.c 2012-07-29 12:54:29.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 618, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +185. You order fast food over the Internet + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ae3ccc3237f908b7bc3df260e9e41100f994619b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:41 +0200 Subject: [PATCH 0371/3340] - patchlevel 619 --- 7.3.619 | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 7.3.619 diff --git a/7.3.619 b/7.3.619 new file mode 100644 index 00000000..1fedcc78 --- /dev/null +++ b/7.3.619 @@ -0,0 +1,50 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.619 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.619 +Problem: When executing a shell command Vim may become slow to respond. +Solution: Don't wait after every processed message. (idea by Yasuhiro + Matsumoto) +Files: src/os_win32.c + + +*** ../vim-7.3.618/src/os_win32.c 2012-07-19 11:37:22.000000000 +0200 +--- src/os_win32.c 2012-08-02 12:30:52.000000000 +0200 +*************** +*** 3319,3324 **** +--- 3319,3326 ---- + { + TranslateMessage(&msg); + pDispatchMessage(&msg); ++ delay = 1; ++ continue; + } + if (WaitForSingleObject(pi.hProcess, delay) != WAIT_TIMEOUT) + break; +*** ../vim-7.3.618/src/version.c 2012-07-29 12:55:21.000000000 +0200 +--- src/version.c 2012-08-02 12:29:08.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 619, + /**/ + +-- +Some of the well know MS-Windows errors: + EMULTI Multitasking attempted, system confused + EKEYBOARD Keyboard locked, try getting out of this one! + EXPLAIN Unexplained error, please tell us what happened + EFUTURE Reserved for our future mistakes + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9958606d51071a89fdc5d341ffab545541252186 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:41 +0200 Subject: [PATCH 0372/3340] - patchlevel 620 --- 7.3.620 | 163 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 163 insertions(+) create mode 100644 7.3.620 diff --git a/7.3.620 b/7.3.620 new file mode 100644 index 00000000..5890f15f --- /dev/null +++ b/7.3.620 @@ -0,0 +1,163 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.620 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.620 +Problem: Building with recent Ruby on Win32 doesn't work. +Solution: Add a separate argument for the API version. (Yasuhiro Matsumoto) +Files: src/Make_ming.mak, src/Make_mvc.mak + + +*** ../vim-7.3.619/src/Make_ming.mak 2012-07-06 13:40:44.000000000 +0200 +--- src/Make_ming.mak 2012-08-02 17:02:34.000000000 +0200 +*************** +*** 260,266 **** + # DYNAMIC_RUBY=yes (to load the Ruby DLL dynamically) + # RUBY_VER=[Ruby version, eg 16, 17] (default is 16) + # RUBY_VER_LONG=[Ruby version, eg 1.6, 1.7] (default is 1.6) +! # You must set RUBY_VER_LONG when change RUBY_VER. + #RUBY=c:/ruby + ifdef RUBY + ifndef DYNAMIC_RUBY +--- 260,268 ---- + # DYNAMIC_RUBY=yes (to load the Ruby DLL dynamically) + # RUBY_VER=[Ruby version, eg 16, 17] (default is 16) + # RUBY_VER_LONG=[Ruby version, eg 1.6, 1.7] (default is 1.6) +! # You must set RUBY_VER_LONG when changing RUBY_VER. +! # You must set RUBY_API_VER version to RUBY_VER_LONG. +! # Don't set ruby API version to RUBY_VER like 191. + #RUBY=c:/ruby + ifdef RUBY + ifndef DYNAMIC_RUBY +*************** +*** 273,278 **** +--- 275,283 ---- + ifndef RUBY_VER_LONG + RUBY_VER_LONG = 1.6 + endif ++ ifndef RUBY_API_VER ++ RUBY_API_VER = $(subst .,,$(RUBY_VER_LONG)) ++ endif + + ifndef RUBY_PLATFORM + ifeq ($(RUBY_VER), 16) +*************** +*** 288,296 **** + + ifndef RUBY_INSTALL_NAME + ifeq ($(RUBY_VER), 16) +! RUBY_INSTALL_NAME = mswin32-ruby$(RUBY_VER) + else +! RUBY_INSTALL_NAME = msvcrt-ruby$(RUBY_VER) + endif + endif + +--- 293,301 ---- + + ifndef RUBY_INSTALL_NAME + ifeq ($(RUBY_VER), 16) +! RUBY_INSTALL_NAME = mswin32-ruby$(RUBY_API_VER) + else +! RUBY_INSTALL_NAME = msvcrt-ruby$(RUBY_API_VER) + endif + endif + +*** ../vim-7.3.619/src/Make_mvc.mak 2012-02-22 16:01:53.000000000 +0100 +--- src/Make_mvc.mak 2012-08-02 17:42:31.000000000 +0200 +*************** +*** 63,68 **** +--- 63,70 ---- + # RUBY_VER=[Ruby version, eg 16, 17] (default is 18) + # RUBY_VER_LONG=[Ruby version, eg 1.6, 1.7] (default is 1.8) + # You must set RUBY_VER_LONG when change RUBY_VER. ++ # You must set RUBY_API_VER to RUBY_VER_LONG. ++ # Don't set ruby API version to RUBY_VER like 191. + # + # Tcl interface: + # TCL=[Path to Tcl directory] +*************** +*** 807,834 **** + !ifndef RUBY_VER_LONG + RUBY_VER_LONG = 1.8 + !endif + + !if $(RUBY_VER) >= 18 + !ifndef RUBY_PLATFORM + RUBY_PLATFORM = i386-mswin32 + !endif + !ifndef RUBY_INSTALL_NAME +! RUBY_INSTALL_NAME = msvcrt-ruby$(RUBY_VER) + !endif + !else + !ifndef RUBY_PLATFORM + RUBY_PLATFORM = i586-mswin32 + !endif + !ifndef RUBY_INSTALL_NAME +! RUBY_INSTALL_NAME = mswin32-ruby$(RUBY_VER) + !endif + !endif # $(RUBY_VER) >= 18 + + !message Ruby requested (version $(RUBY_VER)) - root dir is "$(RUBY)" + CFLAGS = $(CFLAGS) -DFEAT_RUBY + RUBY_OBJ = $(OUTDIR)\if_ruby.obj +! !if $(RUBY_VER) >= 190 +! RUBY_INC = /I "$(RUBY)\include\ruby-$(RUBY_VER_LONG)\$(RUBY_PLATFORM)" /I "$(RUBY)\include\ruby-$(RUBY_VER_LONG)" + !else + RUBY_INC = /I "$(RUBY)\lib\ruby\$(RUBY_VER_LONG)\$(RUBY_PLATFORM)" + !endif +--- 813,843 ---- + !ifndef RUBY_VER_LONG + RUBY_VER_LONG = 1.8 + !endif ++ !ifndef RUBY_API_VER ++ RUBY_API_VER = $(RUBY_VER_LONG:.=) ++ !endif + + !if $(RUBY_VER) >= 18 + !ifndef RUBY_PLATFORM + RUBY_PLATFORM = i386-mswin32 + !endif + !ifndef RUBY_INSTALL_NAME +! RUBY_INSTALL_NAME = msvcrt-ruby$(RUBY_API_VER) + !endif + !else + !ifndef RUBY_PLATFORM + RUBY_PLATFORM = i586-mswin32 + !endif + !ifndef RUBY_INSTALL_NAME +! RUBY_INSTALL_NAME = mswin32-ruby$(RUBY_API_VER) + !endif + !endif # $(RUBY_VER) >= 18 + + !message Ruby requested (version $(RUBY_VER)) - root dir is "$(RUBY)" + CFLAGS = $(CFLAGS) -DFEAT_RUBY + RUBY_OBJ = $(OUTDIR)\if_ruby.obj +! !if $(RUBY_VER) >= 19 +! RUBY_INC = /I "$(RUBY)\lib\ruby\$(RUBY_VER_LONG)\$(RUBY_PLATFORM)" /I "$(RUBY)\include\ruby-$(RUBY_VER_LONG)" /I "$(RUBY)\include\ruby-$(RUBY_VER_LONG)\$(RUBY_PLATFORM)" + !else + RUBY_INC = /I "$(RUBY)\lib\ruby\$(RUBY_VER_LONG)\$(RUBY_PLATFORM)" + !endif +*** ../vim-7.3.619/src/version.c 2012-08-02 12:31:40.000000000 +0200 +--- src/version.c 2012-08-02 21:20:28.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 620, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +199. You read this entire list of symptoms, looking for something + that doesn't describe you. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c5a20eef62f62bbcdc0656dc684caa9cccc50cf1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:42 +0200 Subject: [PATCH 0373/3340] - patchlevel 621 --- 7.3.621 | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 7.3.621 diff --git a/7.3.621 b/7.3.621 new file mode 100644 index 00000000..7e3fe2a5 --- /dev/null +++ b/7.3.621 @@ -0,0 +1,72 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.621 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.621 +Problem: Compiler warnings on 64 bit windows. +Solution: Add type casts. (Mike Williams) +Files: src/ex_docmd.c, src/search.c + + +*** ../vim-7.3.620/src/ex_docmd.c 2012-07-27 21:12:03.000000000 +0200 +--- src/ex_docmd.c 2012-08-02 21:19:22.000000000 +0200 +*************** +*** 3392,3398 **** + /* Find start of last argument (argument just before cursor): */ + p = buff; + xp->xp_pattern = p; +! len = STRLEN(buff); + while (*p && p < buff + len) + { + if (*p == ' ' || *p == TAB) +--- 3392,3398 ---- + /* Find start of last argument (argument just before cursor): */ + p = buff; + xp->xp_pattern = p; +! len = (int)STRLEN(buff); + while (*p && p < buff + len) + { + if (*p == ' ' || *p == TAB) +*** ../vim-7.3.620/src/search.c 2012-07-29 12:55:21.000000000 +0200 +--- src/search.c 2012-08-02 21:20:02.000000000 +0200 +*************** +*** 4621,4627 **** + { + /* searching backwards, so set pos to last line and col */ + pos.lnum = curwin->w_buffer->b_ml.ml_line_count; +! pos.col = STRLEN(ml_get(curwin->w_buffer->b_ml.ml_line_count)); + } + } + +--- 4621,4628 ---- + { + /* searching backwards, so set pos to last line and col */ + pos.lnum = curwin->w_buffer->b_ml.ml_line_count; +! pos.col = (colnr_T)STRLEN( +! ml_get(curwin->w_buffer->b_ml.ml_line_count)); + } + } + +*** ../vim-7.3.620/src/version.c 2012-08-02 21:21:43.000000000 +0200 +--- src/version.c 2012-08-02 21:23:13.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 621, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +200. You really believe in the concept of a "paperless" office. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f6534e6dcac7ef04469bc76955690854c77312d5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:47 +0200 Subject: [PATCH 0374/3340] - patchlevel 622 --- 7.3.622 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.622 diff --git a/7.3.622 b/7.3.622 new file mode 100644 index 00000000..a2c26014 --- /dev/null +++ b/7.3.622 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.622 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.622 +Problem: XPM library for Win32 can't be found. +Solution: Suggest using the one from the Vim ftp site. +Files: src/Make_mvc.mak + + +*** ../vim-7.3.621/src/Make_mvc.mak 2012-08-02 21:21:43.000000000 +0200 +--- src/Make_mvc.mak 2012-08-02 21:45:52.000000000 +0200 +*************** +*** 281,287 **** + + !ifdef XPM + # XPM - Include support for XPM signs +! # you can get xpm.lib from http://iamphet.nm.ru/xpm or create it yourself + XPM_OBJ = $(OBJDIR)/xpm_w32.obj + XPM_DEFS = -DFEAT_XPM_W32 + XPM_LIB = $(XPM)\lib\libXpm.lib +--- 281,291 ---- + + !ifdef XPM + # XPM - Include support for XPM signs +! # You need to download or build xpm.lib somehow. +! # You can get the most recent version of libXpm-*.zip from +! # http://cgit.freedesktop.org/xorg/lib/libXpm +! # from which you must build xpm.lib yourself +! # OR get and unpack: ftp://ftp.vim.org/pub/vim/pcextra/xpm.zip + XPM_OBJ = $(OBJDIR)/xpm_w32.obj + XPM_DEFS = -DFEAT_XPM_W32 + XPM_LIB = $(XPM)\lib\libXpm.lib +*** ../vim-7.3.621/src/version.c 2012-08-02 21:24:38.000000000 +0200 +--- src/version.c 2012-08-02 21:46:43.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 622, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +202. You're amazed to find out Spam is a food. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bbcf5841c53e6a71d1c9d61a7503f3c1eac90f76 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 14:10:48 +0200 Subject: [PATCH 0375/3340] - patchlevel 622 --- README.patches | 18 ++++++++++++++++++ vim.spec | 41 ++++++++++++++++++++++++++++++++++++++++- 2 files changed, 58 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index 2cf3f4f9..63d94e65 100644 --- a/README.patches +++ b/README.patches @@ -635,3 +635,21 @@ Individual patches for Vim 7.3: 1532 7.3.602 missing files in distribution 11248 7.3.603 it is possible to add or replace builtin functions 1861 7.3.604 inputdialog() doesn't use the cancel argument in the console + 2334 7.3.605 MS-Windows: Can't compile with older compilers + 2522 7.3.606 CTRL-P completion has a problem with multi-byte characters + 2139 7.3.607 with 8 color terminal selected menu item is black on black + 3847 7.3.608 winrestview() does not always restore the view correctly + 5843 7.3.609 file names in :checkpath! output are garbled + 12106 7.3.610 cannot operate on the text that a search pattern matches + 1895 7.3.611 can't use Vim dictionary as self argument in Python + 2081 7.3.612 auto formatting messes up text when 'fo' contains "2" + 6886 7.3.613 including Python's config.c in the build causes trouble + 5747 7.3.614 number arg gets turned into number while it should be string + 2915 7.3.615 completion does not recognized escaped spaces + 1289 7.3.616 (after 7.3.610) can't compile without +visual + 1781 7.3.617 (after 7.3.615) hang on completion + 10033 7.3.618 (after 7.3.616) still doesn't compile with small features + 1583 7.3.619 when executing a shell command Vim may become slow to respond + 4897 7.3.620 building with recent Ruby on Win32 doesn't work + 2259 7.3.621 compiler warnings on 64 bit windows + 1867 7.3.622 XPM library for Win32 can't be found diff --git a/vim.spec b/vim.spec index 7d50bfba..a3ff7d0d 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 604 +%define patchlevel 622 Summary: The VIM editor URL: http://www.vim.org/ @@ -660,6 +660,24 @@ Patch601: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.601 Patch602: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.602 Patch603: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.603 Patch604: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.604 +Patch605: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.605 +Patch606: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.606 +Patch607: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.607 +Patch608: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.608 +Patch609: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.609 +Patch610: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.610 +Patch611: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.611 +Patch612: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.612 +Patch613: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.613 +Patch614: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.614 +Patch615: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.615 +Patch616: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.616 +Patch617: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.617 +Patch618: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.618 +Patch619: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.619 +Patch620: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.620 +Patch621: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.621 +Patch622: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.622 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1409,6 +1427,24 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch602 -p0 %patch603 -p0 %patch604 -p0 +%patch605 -p0 +%patch606 -p0 +%patch607 -p0 +%patch608 -p0 +%patch609 -p0 +%patch610 -p0 +%patch611 -p0 +%patch612 -p0 +%patch613 -p0 +%patch614 -p0 +%patch615 -p0 +%patch616 -p0 +%patch617 -p0 +%patch618 -p0 +%patch619 -p0 +%patch620 -p0 +%patch621 -p0 +%patch622 -p0 # install spell files @@ -1863,6 +1899,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Aug 06 2012 Karsten Hopp 7.3.622-1 +- patchlevel 622 + * Mon Aug 06 2012 Karsten Hopp 7.3.604-1 - drop vim-6.1-rh3.patch, (bz #754801) From d484d1a1ac196c5b8850a8813403541a6d2263a1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 17:56:11 +0200 Subject: [PATCH 0376/3340] add epoch to spec.vim and automatic changelog entries --- vim-7.3-spec-epoch.patch | 18 ++++++++++++++++++ vim.spec | 7 ++++++- 2 files changed, 24 insertions(+), 1 deletion(-) create mode 100644 vim-7.3-spec-epoch.patch diff --git a/vim-7.3-spec-epoch.patch b/vim-7.3-spec-epoch.patch new file mode 100644 index 00000000..8305de73 --- /dev/null +++ b/vim-7.3-spec-epoch.patch @@ -0,0 +1,18 @@ +42a43 +> let epoch = "" +46a48 +> let epochline = -1 +53a56,58 +> elseif (epoch == "" && linestr =~? '^Epoch:') +> let epochline = line +> let epoch = substitute(strpart(linestr,6), '^[ ]*\([^ ]\+\)[ ]*$','\1','') +69a75 +> let epoch = s:ParseRpmVars(epoch, epochline) +92c98,102 +< let release_info = ver."-".rel +--- +> if (epoch == "") +> let release_info = ver."-".rel +> else +> let release_info = epoch.":".ver."-".rel +> endif diff --git a/vim.spec b/vim.spec index a3ff7d0d..6d569b27 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1%{?dist} +Release: 2%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -689,6 +689,7 @@ Patch3007: vim-7.0-syncolor.patch Patch3008: vim-7.0-specedit.patch Patch3009: vim72-rh514717.patch Patch3010: vim-7.3-bug816848.patch +Patch3011: vim-7.3-spec-epoch.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel ncurses-devel gettext perl-devel @@ -1462,6 +1463,7 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch3008 -p1 %patch3009 -p1 %patch3010 -p1 +%patch3011 -p1 %build cp -f %{SOURCE5} . @@ -1899,6 +1901,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Aug 06 2012 Karsten Hopp 2:7.3.622-2 +- add epoch to spec.vim and automatic changelog entries + * Mon Aug 06 2012 Karsten Hopp 7.3.622-1 - patchlevel 622 From dfd24f3f6d959e902c3ef18b2964c2ba6b7dac8a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 6 Aug 2012 18:46:02 +0200 Subject: [PATCH 0377/3340] update epoch patch --- vim-7.3-spec-epoch.patch | 64 +++++++++++++++++++++++++++++----------- 1 file changed, 46 insertions(+), 18 deletions(-) diff --git a/vim-7.3-spec-epoch.patch b/vim-7.3-spec-epoch.patch index 8305de73..398af28d 100644 --- a/vim-7.3-spec-epoch.patch +++ b/vim-7.3-spec-epoch.patch @@ -1,18 +1,46 @@ -42a43 -> let epoch = "" -46a48 -> let epochline = -1 -53a56,58 -> elseif (epoch == "" && linestr =~? '^Epoch:') -> let epochline = line -> let epoch = substitute(strpart(linestr,6), '^[ ]*\([^ ]\+\)[ ]*$','\1','') -69a75 -> let epoch = s:ParseRpmVars(epoch, epochline) -92c98,102 -< let release_info = ver."-".rel ---- -> if (epoch == "") -> let release_info = ver."-".rel -> else -> let release_info = epoch.":".ver."-".rel -> endif +--- vim73/runtime/ftplugin/spec.vim 2012-08-06 17:51:41.000000000 +0200 ++++ /tmp/spec.vim 2012-08-06 17:51:07.730701143 +0200 +@@ -40,10 +40,12 @@ + endif + let line = 0 + let name = "" ++ let epoch = "" + let ver = "" + let rel = "" + let nameline = -1 + let verline = -1 ++ let epochline = -1 + let relline = -1 + let chgline = -1 + while (line <= line("$")) +@@ -51,6 +53,9 @@ + if (name == "" && linestr =~? '^Name:') + let nameline = line + let name = substitute(strpart(linestr,5), '^[ ]*\([^ ]\+\)[ ]*$','\1','') ++ elseif (epoch == "" && linestr =~? '^Epoch:') ++ let epochline = line ++ let epoch = substitute(strpart(linestr,6), '^[ ]*\([^ ]\+\)[ ]*$','\1','') + elseif (ver == "" && linestr =~? '^Version:') + let verline = line + let ver = substitute(strpart(linestr,8), '^[ ]*\([^ ]\+\)[ ]*$','\1','') +@@ -67,6 +72,7 @@ + if (nameline != -1 && verline != -1 && relline != -1) + let include_release_info = 1 + let name = s:ParseRpmVars(name, nameline) ++ let epoch = s:ParseRpmVars(epoch, epochline) + let ver = s:ParseRpmVars(ver, verline) + let rel = s:ParseRpmVars(rel, relline) + else +@@ -89,7 +95,11 @@ + execute "language time C" + let parsed_format = "* ".strftime(format) + execute "language time " . save_time +- let release_info = ver."-".rel ++ if (epoch == "") ++ let release_info = ver."-".rel ++ else ++ let release_info = epoch.":".ver."-".rel ++ endif + let wrong_format = 0 + let wrong_release = 0 + let insert_line = 0 From b9b7f2ada7b5263d36b9eeab062923c8e8bab8b5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:45 +0200 Subject: [PATCH 0378/3340] - patchlevel 557 --- 7.3.557 | 99 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 99 insertions(+) create mode 100644 7.3.557 diff --git a/7.3.557 b/7.3.557 new file mode 100644 index 00000000..663c0720 --- /dev/null +++ b/7.3.557 @@ -0,0 +1,99 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.557 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.557 +Problem: Crash when an autocommand wipes out a buffer when it is hidden. +Solution: Restore the current window when needed. (Christian Brabandt) +Files: src/buffer.c + + +*** ../vim-7.3.556/src/buffer.c 2012-06-13 14:28:16.000000000 +0200 +--- src/buffer.c 2012-06-20 11:49:54.000000000 +0200 +*************** +*** 1363,1368 **** +--- 1363,1369 ---- + int action; + { + buf_T *prevbuf; ++ win_T *prevwin; + int unload = (action == DOBUF_UNLOAD || action == DOBUF_DEL + || action == DOBUF_WIPE); + +*************** +*** 1402,1423 **** + if (buf_valid(prevbuf)) + #endif + { + if (prevbuf == curbuf) + u_sync(FALSE); + close_buffer(prevbuf == curwin->w_buffer ? curwin : NULL, prevbuf, + unload ? action : (action == DOBUF_GOTO + && !P_HID(prevbuf) + && !bufIsChanged(prevbuf)) ? DOBUF_UNLOAD : 0, FALSE); + } + } + #ifdef FEAT_AUTOCMD + /* An autocommand may have deleted "buf", already entered it (e.g., when +! * it did ":bunload") or aborted the script processing! */ +! # ifdef FEAT_EVAL +! if (buf_valid(buf) && buf != curbuf && !aborting()) +! # else +! if (buf_valid(buf) && buf != curbuf) +! # endif + #endif + enter_buffer(buf); + } +--- 1403,1432 ---- + if (buf_valid(prevbuf)) + #endif + { ++ prevwin = curwin; + if (prevbuf == curbuf) + u_sync(FALSE); + close_buffer(prevbuf == curwin->w_buffer ? curwin : NULL, prevbuf, + unload ? action : (action == DOBUF_GOTO + && !P_HID(prevbuf) + && !bufIsChanged(prevbuf)) ? DOBUF_UNLOAD : 0, FALSE); ++ if (curwin != prevwin && win_valid(prevwin)) ++ /* autocommands changed curwin, Grr! */ ++ curwin = prevwin; + } + } + #ifdef FEAT_AUTOCMD + /* An autocommand may have deleted "buf", already entered it (e.g., when +! * it did ":bunload") or aborted the script processing! +! * If curwin->w_buffer is null, enter_buffer() will make it valid again */ +! if ((buf_valid(buf) && buf != curbuf +! #ifdef FEAT_EVAL +! && !aborting() +! #endif +! #ifdef FEAT_WINDOWS +! ) || curwin->w_buffer == NULL +! #endif +! ) + #endif + enter_buffer(buf); + } +*** ../vim-7.3.556/src/version.c 2012-06-14 20:59:20.000000000 +0200 +--- src/version.c 2012-06-20 11:53:56.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 557, + /**/ + +-- +Don't read everything you believe. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ea8c32a517b08b8e6b33682fb4e0011ef04dda2b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:45 +0200 Subject: [PATCH 0379/3340] - patchlevel 558 --- 7.3.558 | 90 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) create mode 100644 7.3.558 diff --git a/7.3.558 b/7.3.558 new file mode 100644 index 00000000..015bc37d --- /dev/null +++ b/7.3.558 @@ -0,0 +1,90 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.558 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.558 +Problem: Memory access error. (Gary Johnson) +Solution: Allocate one more byte. (Dominique Pelle) +Files: src/misc1.c + + +*** ../vim-7.3.557/src/misc1.c 2012-06-14 20:59:20.000000000 +0200 +--- src/misc1.c 2012-06-20 12:34:57.000000000 +0200 +*************** +*** 460,466 **** + * + * I'm not sure if regmmatch_T (multi-match) is needed in this case. + * It may be true that this section would work properly using the +! * regmatch_T code above, in which case, these two seperate sections + * should be consolidated w/ FEAT_COMMENTS making lead_len > 0... + */ + #endif +--- 460,466 ---- + * + * I'm not sure if regmmatch_T (multi-match) is needed in this case. + * It may be true that this section would work properly using the +! * regmatch_T code above, in which case, these two separate sections + * should be consolidated w/ FEAT_COMMENTS making lead_len > 0... + */ + #endif +*************** +*** 1053,1061 **** + } + if (lead_len) + { +! /* allocate buffer (may concatenate p_exta later) */ + leader = alloc(lead_len + lead_repl_len + extra_space + extra_len +! + (second_line_indent > 0 ? second_line_indent : 0)); + allocated = leader; /* remember to free it later */ + + if (leader == NULL) +--- 1053,1061 ---- + } + if (lead_len) + { +! /* allocate buffer (may concatenate p_extra later) */ + leader = alloc(lead_len + lead_repl_len + extra_space + extra_len +! + (second_line_indent > 0 ? second_line_indent : 0) + 1); + allocated = leader; /* remember to free it later */ + + if (leader == NULL) +*************** +*** 3342,3348 **** + buf = alloc(buflen); + else if (maxlen < 10) + { +! /* Need some more space. This migth happen when receiving a long + * escape sequence. */ + buflen += 100; + buf = vim_realloc(buf, buflen); +--- 3342,3348 ---- + buf = alloc(buflen); + else if (maxlen < 10) + { +! /* Need some more space. This might happen when receiving a long + * escape sequence. */ + buflen += 100; + buf = vim_realloc(buf, buflen); +*** ../vim-7.3.557/src/version.c 2012-06-20 11:54:55.000000000 +0200 +--- src/version.c 2012-06-20 12:36:29.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 558, + /**/ + +-- +George: "I just got a new set of golf clubs for my wife!" + John: "Great trade!" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 483b17cadf607ce02cfceace88ffde69f6c68db1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:46 +0200 Subject: [PATCH 0380/3340] - patchlevel 559 --- 7.3.559 | 131 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 131 insertions(+) create mode 100644 7.3.559 diff --git a/7.3.559 b/7.3.559 new file mode 100644 index 00000000..df767372 --- /dev/null +++ b/7.3.559 @@ -0,0 +1,131 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.559 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.559 +Problem: home_replace() does not work with 8.3 filename. +Solution: Make ":p" expand 8.3 name to full path. (Yasuhiro Matsumoto) +Files: src/eval.c, src/misc1.c + + +*** ../vim-7.3.558/src/eval.c 2012-06-13 14:28:16.000000000 +0200 +--- src/eval.c 2012-06-20 13:52:47.000000000 +0200 +*************** +*** 23554,23559 **** +--- 23554,23580 ---- + return -1; + } + ++ #ifdef WIN3264 ++ # if _WIN32_WINNT >= 0x0500 ++ if (vim_strchr(*fnamep, '~') != NULL) ++ { ++ /* Expand 8.3 filename to full path. Needed to make sure the same ++ * file does not have two different names. ++ * Note: problem does not occur if _WIN32_WINNT < 0x0500. */ ++ p = alloc(_MAX_PATH + 1); ++ if (p != NULL) ++ { ++ if (GetLongPathName(*fnamep, p, MAXPATHL)) ++ { ++ vim_free(*bufp); ++ *bufp = *fnamep = p; ++ } ++ else ++ vim_free(p); ++ } ++ } ++ # endif ++ #endif + /* Append a path separator to a directory. */ + if (mch_isdir(*fnamep)) + { +*** ../vim-7.3.558/src/misc1.c 2012-06-20 12:40:01.000000000 +0200 +--- src/misc1.c 2012-06-20 13:57:22.000000000 +0200 +*************** +*** 4499,4505 **** + { + size_t dirlen = 0, envlen = 0; + size_t len; +! char_u *homedir_env; + char_u *p; + + if (src == NULL) +--- 4499,4505 ---- + { + size_t dirlen = 0, envlen = 0; + size_t len; +! char_u *homedir_env, *homedir_env_orig; + char_u *p; + + if (src == NULL) +*************** +*** 4525,4533 **** + dirlen = STRLEN(homedir); + + #ifdef VMS +! homedir_env = mch_getenv((char_u *)"SYS$LOGIN"); + #else +! homedir_env = mch_getenv((char_u *)"HOME"); + #endif + + if (homedir_env != NULL && *homedir_env == NUL) +--- 4525,4548 ---- + dirlen = STRLEN(homedir); + + #ifdef VMS +! homedir_env_orig = homedir_env = mch_getenv((char_u *)"SYS$LOGIN"); + #else +! homedir_env_orig = homedir_env = mch_getenv((char_u *)"HOME"); +! #endif +! #if defined(FEAT_MODIFY_FNAME) || defined(WIN3264) +! if (vim_strchr(homedir_env, '~') != NULL) +! { +! int usedlen = 0; +! int flen; +! char_u *fbuf = NULL; +! +! flen = (int)STRLEN(homedir_env); +! (void)modify_fname(":p", &usedlen, &homedir_env, &fbuf, &flen); +! flen = (int)STRLEN(homedir_env); +! if (flen > 0 && vim_ispathsep(homedir_env[flen - 1])) +! /* Remove the trailing / that is added to a directory. */ +! homedir_env[flen - 1] = NUL; +! } + #endif + + if (homedir_env != NULL && *homedir_env == NUL) +*************** +*** 4585,4590 **** +--- 4600,4608 ---- + /* if (dstlen == 0) out of space, what to do??? */ + + *dst = NUL; ++ ++ if (homedir_env != homedir_env_orig) ++ vim_free(homedir_env); + } + + /* +*** ../vim-7.3.558/src/version.c 2012-06-20 12:40:01.000000000 +0200 +--- src/version.c 2012-06-20 14:02:11.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 559, + /**/ + +-- +The future isn't what it used to be. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8dc95434fca396a7a28ab32db84443b39ef53bfb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:46 +0200 Subject: [PATCH 0381/3340] - patchlevel 560 --- 7.3.560 | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 7.3.560 diff --git a/7.3.560 b/7.3.560 new file mode 100644 index 00000000..7f464111 --- /dev/null +++ b/7.3.560 @@ -0,0 +1,49 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.560 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.560 +Problem: Get an error for a locked argument in extend(). +Solution: Initialize the lock flag for a dictionary. (Yukihiro Nakadaira) +Files: src/eval.c + + +*** ../vim-7.3.559/src/eval.c 2012-06-20 14:02:23.000000000 +0200 +--- src/eval.c 2012-06-20 14:08:34.000000000 +0200 +*************** +*** 19981,19986 **** +--- 19981,19987 ---- + dictitem_T *dict_var; + { + hash_init(&dict->dv_hashtab); ++ dict->dv_lock = 0; + dict->dv_refcount = DO_NOT_FREE_CNT; + dict->dv_copyID = 0; + dict_var->di_tv.vval.v_dict = dict; +*** ../vim-7.3.559/src/version.c 2012-06-20 14:02:23.000000000 +0200 +--- src/version.c 2012-06-20 14:09:34.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 560, + /**/ + +-- +"Oh, no! NOT the Spanish Inquisition!" +"NOBODY expects the Spanish Inquisition!!!" + -- Monty Python sketch -- +"Oh, no! NOT another option!" +"EVERYBODY expects another option!!!" + -- Discussion in vim-dev mailing list -- + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1be8c13f3644184ad0519884cf7c80e924ade47a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:46 +0200 Subject: [PATCH 0382/3340] - patchlevel 561 --- 7.3.561 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.561 diff --git a/7.3.561 b/7.3.561 new file mode 100644 index 00000000..d51030c4 --- /dev/null +++ b/7.3.561 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.561 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.561 +Problem: Using refresh: always in a complete function breaks the "." + command. (Val Markovic) +Solution: Add match leader to the redo buffer. (Yasuhiro Matsumoto) +Files: src/edit.c + + +*** ../vim-7.3.560/src/edit.c 2012-06-13 17:28:51.000000000 +0200 +--- src/edit.c 2012-06-20 14:22:23.000000000 +0200 +*************** +*** 3467,3476 **** +--- 3467,3480 ---- + (*mb_char2bytes)(c, buf); + buf[cc] = NUL; + ins_char_bytes(buf, cc); ++ AppendToRedobuff(buf); + } + else + #endif ++ { + ins_char(c); ++ AppendCharToRedobuff(c); ++ } + + /* If we didn't complete finding matches we must search again. */ + if (ins_compl_need_restart()) +*** ../vim-7.3.560/src/version.c 2012-06-20 14:13:02.000000000 +0200 +--- src/version.c 2012-06-20 14:20:13.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 561, + /**/ + +-- +Microsoft is to software what McDonalds is to gourmet cooking + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8e9175c4b1fc501dc2a861fb7f9fe5940035a988 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:47 +0200 Subject: [PATCH 0383/3340] - patchlevel 562 --- 7.3.562 | 63 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 7.3.562 diff --git a/7.3.562 b/7.3.562 new file mode 100644 index 00000000..626de495 --- /dev/null +++ b/7.3.562 @@ -0,0 +1,63 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.562 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.562 +Problem: ":profdel" should not work when the +profile feature is disabled. +Solution: Call ex_ni(). (Yasuhiro Matsumoto) +Files: src/ex_cmds2.c + + +*** ../vim-7.3.561/src/ex_cmds2.c 2012-06-13 14:28:16.000000000 +0200 +--- src/ex_cmds2.c 2012-06-20 15:43:44.000000000 +0200 +*************** +*** 596,605 **** + garray_T *gap; + + gap = &dbg_breakp; +- #ifdef FEAT_PROFILE + if (eap->cmdidx == CMD_profdel) + gap = &prof_ga; + #endif + + if (vim_isdigit(*eap->arg)) + { +--- 596,610 ---- + garray_T *gap; + + gap = &dbg_breakp; + if (eap->cmdidx == CMD_profdel) ++ { ++ #ifdef FEAT_PROFILE + gap = &prof_ga; ++ #else ++ ex_ni(eap); ++ return; + #endif ++ } + + if (vim_isdigit(*eap->arg)) + { +*** ../vim-7.3.561/src/version.c 2012-06-20 14:26:30.000000000 +0200 +--- src/version.c 2012-06-20 15:44:00.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 562, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +42. Your virtual girlfriend finds a new net sweetheart with a larger bandwidth. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 15e9ce9c7fabde3ccde4db1ee73fc89a4c41598e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:47 +0200 Subject: [PATCH 0384/3340] - patchlevel 563 --- 7.3.563 | 97 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100644 7.3.563 diff --git a/7.3.563 b/7.3.563 new file mode 100644 index 00000000..c2ebf410 --- /dev/null +++ b/7.3.563 @@ -0,0 +1,97 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.563 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.563 (after 7.3.557) +Problem: Can't build with tiny features. +Solution: Add #ifdef. +Files: src/buffer.c + + +*** ../vim-7.3.562/src/buffer.c 2012-06-20 11:54:55.000000000 +0200 +--- src/buffer.c 2012-06-20 17:40:59.000000000 +0200 +*************** +*** 1363,1369 **** +--- 1363,1371 ---- + int action; + { + buf_T *prevbuf; ++ #ifdef FEAT_WINDOWS + win_T *prevwin; ++ #endif + int unload = (action == DOBUF_UNLOAD || action == DOBUF_DEL + || action == DOBUF_WIPE); + +*************** +*** 1403,1418 **** +--- 1405,1424 ---- + if (buf_valid(prevbuf)) + #endif + { ++ #ifdef FEAT_WINDOWS + prevwin = curwin; ++ #endif + if (prevbuf == curbuf) + u_sync(FALSE); + close_buffer(prevbuf == curwin->w_buffer ? curwin : NULL, prevbuf, + unload ? action : (action == DOBUF_GOTO + && !P_HID(prevbuf) + && !bufIsChanged(prevbuf)) ? DOBUF_UNLOAD : 0, FALSE); ++ #ifdef FEAT_WINDOWS + if (curwin != prevwin && win_valid(prevwin)) + /* autocommands changed curwin, Grr! */ + curwin = prevwin; ++ #endif + } + } + #ifdef FEAT_AUTOCMD +*************** +*** 1420,1431 **** + * it did ":bunload") or aborted the script processing! + * If curwin->w_buffer is null, enter_buffer() will make it valid again */ + if ((buf_valid(buf) && buf != curbuf +! #ifdef FEAT_EVAL + && !aborting() +! #endif +! #ifdef FEAT_WINDOWS + ) || curwin->w_buffer == NULL +! #endif + ) + #endif + enter_buffer(buf); +--- 1426,1437 ---- + * it did ":bunload") or aborted the script processing! + * If curwin->w_buffer is null, enter_buffer() will make it valid again */ + if ((buf_valid(buf) && buf != curbuf +! # ifdef FEAT_EVAL + && !aborting() +! # endif +! # ifdef FEAT_WINDOWS + ) || curwin->w_buffer == NULL +! # endif + ) + #endif + enter_buffer(buf); +*** ../vim-7.3.562/src/version.c 2012-06-20 15:48:53.000000000 +0200 +--- src/version.c 2012-06-20 17:54:01.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 563, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +45. You buy a Captain Kirk chair with a built-in keyboard and mouse. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ed059f5227691fc136091f07468e54b1d3656fa4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:47 +0200 Subject: [PATCH 0385/3340] - patchlevel 564 --- 7.3.564 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.564 diff --git a/7.3.564 b/7.3.564 new file mode 100644 index 00000000..e806b8e4 --- /dev/null +++ b/7.3.564 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.564 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.564 (after 7.3.559) +Problem: Warning for pointer conversion. +Solution: Add type cast. +Files: src/misc1.c + + +*** ../vim-7.3.563/src/misc1.c 2012-06-20 14:02:23.000000000 +0200 +--- src/misc1.c 2012-06-20 17:41:22.000000000 +0200 +*************** +*** 4537,4543 **** + char_u *fbuf = NULL; + + flen = (int)STRLEN(homedir_env); +! (void)modify_fname(":p", &usedlen, &homedir_env, &fbuf, &flen); + flen = (int)STRLEN(homedir_env); + if (flen > 0 && vim_ispathsep(homedir_env[flen - 1])) + /* Remove the trailing / that is added to a directory. */ +--- 4537,4544 ---- + char_u *fbuf = NULL; + + flen = (int)STRLEN(homedir_env); +! (void)modify_fname((char_u *)":p", &usedlen, +! &homedir_env, &fbuf, &flen); + flen = (int)STRLEN(homedir_env); + if (flen > 0 && vim_ispathsep(homedir_env[flen - 1])) + /* Remove the trailing / that is added to a directory. */ +*** ../vim-7.3.563/src/version.c 2012-06-20 17:54:34.000000000 +0200 +--- src/version.c 2012-06-20 17:55:26.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 564, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +46. Your wife makes a new rule: "The computer cannot come to bed." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 62adabf07cbb953c3f11066922f26679619e129f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:47 +0200 Subject: [PATCH 0386/3340] - patchlevel 565 --- 7.3.565 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.565 diff --git a/7.3.565 b/7.3.565 new file mode 100644 index 00000000..171520b3 --- /dev/null +++ b/7.3.565 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.566 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.566 +Problem: Can't generate proto file for Python 3. +Solution: Add PYTHON3_CFLAGS to LINT_CFLAGS. +Files: src/Makefile + + +*** ../vim-7.3.564/src/Makefile 2012-06-13 19:19:36.000000000 +0200 +--- src/Makefile 2012-06-20 18:36:14.000000000 +0200 +*************** +*** 1339,1345 **** + # with "-E". + OSDEF_CFLAGS = $(PRE_DEFS) $(POST_DEFS) + +! LINT_CFLAGS = -DLINT -I. $(PRE_DEFS) $(POST_DEFS) $(RUBY_CFLAGS) $(LUA_CFLAGS) $(PERL_CFLAGS) $(PYTHON_CFLAGS) -Dinline= -D__extension__= -Dalloca=alloca + + LINT_EXTRA = -DUSE_SNIFF -DHANGUL_INPUT -D"__attribute__(x)=" + +--- 1339,1345 ---- + # with "-E". + OSDEF_CFLAGS = $(PRE_DEFS) $(POST_DEFS) + +! LINT_CFLAGS = -DLINT -I. $(PRE_DEFS) $(POST_DEFS) $(RUBY_CFLAGS) $(LUA_CFLAGS) $(PERL_CFLAGS) $(PYTHON_CFLAGS) $(PYTHON3_CFLAGS) -Dinline= -D__extension__= -Dalloca=alloca + + LINT_EXTRA = -DUSE_SNIFF -DHANGUL_INPUT -D"__attribute__(x)=" + +*** ../vim-7.3.564/src/version.c 2012-06-20 17:56:06.000000000 +0200 +--- src/version.c 2012-06-20 18:39:04.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 565, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +47. You are so familiar with the WWW that you find the search engines useless. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a960691f22e0f946ec9fab0d58c8bc2322452157 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:48 +0200 Subject: [PATCH 0387/3340] - patchlevel 566 --- 7.3.566 | 83 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 7.3.566 diff --git a/7.3.566 b/7.3.566 new file mode 100644 index 00000000..a0600e81 --- /dev/null +++ b/7.3.566 @@ -0,0 +1,83 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.566 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.566 (after 7.3.561) +Problem: Redo after completion does not work correctly when refresh: always + is not used. (Raymond Ko) +Solution: Check the compl_opt_refresh_always flag. (Christian Brabandt) +Files: src/edit.c + + +*** ../vim-7.3.565/src/edit.c 2012-06-20 14:26:30.000000000 +0200 +--- src/edit.c 2012-06-20 22:52:03.000000000 +0200 +*************** +*** 3467,3479 **** + (*mb_char2bytes)(c, buf); + buf[cc] = NUL; + ins_char_bytes(buf, cc); +! AppendToRedobuff(buf); + } + else + #endif + { + ins_char(c); +! AppendCharToRedobuff(c); + } + + /* If we didn't complete finding matches we must search again. */ +--- 3467,3481 ---- + (*mb_char2bytes)(c, buf); + buf[cc] = NUL; + ins_char_bytes(buf, cc); +! if (compl_opt_refresh_always) +! AppendToRedobuff(buf); + } + else + #endif + { + ins_char(c); +! if (compl_opt_refresh_always) +! AppendCharToRedobuff(c); + } + + /* If we didn't complete finding matches we must search again. */ +*************** +*** 3481,3487 **** + ins_compl_restart(); + + /* When 'always' is set, don't reset compl_leader. While completing, +! * cursor don't point original position, changing compl_leader would + * break redo. */ + if (!compl_opt_refresh_always) + { +--- 3483,3489 ---- + ins_compl_restart(); + + /* When 'always' is set, don't reset compl_leader. While completing, +! * cursor doesn't point original position, changing compl_leader would + * break redo. */ + if (!compl_opt_refresh_always) + { +*** ../vim-7.3.565/src/version.c 2012-06-20 18:39:12.000000000 +0200 +--- src/version.c 2012-06-20 22:54:27.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 566, + /**/ + +-- +CVS sux, men don't like commitment + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ca3f180abf281cd3b9321283f7631d64098a483c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:48 +0200 Subject: [PATCH 0388/3340] - patchlevel 567 --- 7.3.567 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.567 diff --git a/7.3.567 b/7.3.567 new file mode 100644 index 00000000..62399f18 --- /dev/null +++ b/7.3.567 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.567 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.567 +Problem: Missing copyright notice. +Solution: Add Vim copyright notice. (Taro Muraoka) +Files: src/dehqx.py + + +*** ../vim-7.3.566/src/dehqx.py 2010-08-15 21:57:32.000000000 +0200 +--- src/dehqx.py 2012-06-29 11:27:41.000000000 +0200 +*************** +*** 1,7 **** + # Python script to get both the data and resource fork from a BinHex encoded + # file. +! # Author: Taro Muraoka +! # Last Change: 2003 Oct 25 + + import sys + import binhex +--- 1,10 ---- + # Python script to get both the data and resource fork from a BinHex encoded + # file. +! # Author: MURAOKA Taro +! # Last Change: 2012 Jun 29 +! # +! # Copyright (C) 2003,12 MURAOKA Taro +! # THIS FILE IS DISTRIBUTED UNDER THE VIM LICENSE. + + import sys + import binhex +*** ../vim-7.3.566/src/version.c 2012-06-20 22:55:56.000000000 +0200 +--- src/version.c 2012-06-29 11:45:36.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 567, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +66. You create a homepage with the impression to cure the afflicted...but + your hidden agenda is to receive more e-mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b5c41828238f8ca70aed913fec9b42440081890b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:48 +0200 Subject: [PATCH 0389/3340] - patchlevel 568 --- 7.3.568 | 138 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 138 insertions(+) create mode 100644 7.3.568 diff --git a/7.3.568 b/7.3.568 new file mode 100644 index 00000000..ef4fcfe5 --- /dev/null +++ b/7.3.568 @@ -0,0 +1,138 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.568 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.568 +Problem: Bad indents for #ifdefs. +Solution: Add and remove spaces. (Elias Diem) +Files: src/globals.h + + +*** ../vim-7.3.567/src/globals.h 2012-02-11 23:45:30.000000000 +0100 +--- src/globals.h 2012-06-29 12:32:14.000000000 +0200 +*************** +*** 513,520 **** + # define ONE_CLIPBOARD + # endif + +! #define CLIP_UNNAMED 1 +! #define CLIP_UNNAMED_PLUS 2 + EXTERN int clip_unnamed INIT(= 0); /* above two values or'ed */ + + EXTERN int clip_autoselect INIT(= FALSE); +--- 513,520 ---- + # define ONE_CLIPBOARD + # endif + +! # define CLIP_UNNAMED 1 +! # define CLIP_UNNAMED_PLUS 2 + EXTERN int clip_unnamed INIT(= 0); /* above two values or'ed */ + + EXTERN int clip_autoselect INIT(= FALSE); +*************** +*** 737,745 **** + #endif + + EXTERN pos_T saved_cursor /* w_cursor before formatting text. */ +! # ifdef DO_INIT + = INIT_POS_T(0, 0, 0) +! # endif + ; + + /* +--- 737,745 ---- + #endif + + EXTERN pos_T saved_cursor /* w_cursor before formatting text. */ +! #ifdef DO_INIT + = INIT_POS_T(0, 0, 0) +! #endif + ; + + /* +*************** +*** 807,815 **** + # endif + EXTERN int has_mbyte INIT(= 0); /* any multi-byte encoding */ + +! #if defined(WIN3264) && defined(FEAT_MBYTE) + EXTERN int wide_WindowProc INIT(= FALSE); /* use wide WindowProc() */ +! #endif + + /* + * To speed up BYTELEN() we fill a table with the byte lengths whenever +--- 807,815 ---- + # endif + EXTERN int has_mbyte INIT(= 0); /* any multi-byte encoding */ + +! # if defined(WIN3264) && defined(FEAT_MBYTE) + EXTERN int wide_WindowProc INIT(= FALSE); /* use wide WindowProc() */ +! # endif + + /* + * To speed up BYTELEN() we fill a table with the byte lengths whenever +*************** +*** 1099,1106 **** + EXTERN int save_p_ls INIT(= -1); /* Save 'laststatus' setting */ + EXTERN int save_p_wmh INIT(= -1); /* Save 'winminheight' setting */ + EXTERN int wild_menu_showing INIT(= 0); +! #define WM_SHOWN 1 /* wildmenu showing */ +! #define WM_SCROLLED 2 /* wildmenu showing with scroll */ + #endif + + #ifdef MSWIN +--- 1099,1106 ---- + EXTERN int save_p_ls INIT(= -1); /* Save 'laststatus' setting */ + EXTERN int save_p_wmh INIT(= -1); /* Save 'winminheight' setting */ + EXTERN int wild_menu_showing INIT(= 0); +! # define WM_SHOWN 1 /* wildmenu showing */ +! # define WM_SCROLLED 2 /* wildmenu showing with scroll */ + #endif + + #ifdef MSWIN +*************** +*** 1310,1318 **** + EXTERN Atom commProperty INIT(= None); + EXTERN char_u *serverDelayedStartName INIT(= NULL); + # else +! # ifdef PROTO + typedef int HWND; +! # endif + EXTERN HWND clientWindow INIT(= 0); + # endif + #endif +--- 1310,1318 ---- + EXTERN Atom commProperty INIT(= None); + EXTERN char_u *serverDelayedStartName INIT(= NULL); + # else +! # ifdef PROTO + typedef int HWND; +! # endif + EXTERN HWND clientWindow INIT(= 0); + # endif + #endif +*** ../vim-7.3.567/src/version.c 2012-06-29 11:46:28.000000000 +0200 +--- src/version.c 2012-06-29 12:34:21.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 568, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +67. Your hard drive crashes. You haven't logged in for two hours. You start + to twitch. You pick up the phone and manually dial your ISP's access + number. You try to hum to communicate with the modem. You succeed. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c73a339d4a5e1ccc26d15a82879f55dac01b83d2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:49 +0200 Subject: [PATCH 0390/3340] - patchlevel 569 --- 7.3.569 | 4762 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 4762 insertions(+) create mode 100644 7.3.569 diff --git a/7.3.569 b/7.3.569 new file mode 100644 index 00000000..435733fe --- /dev/null +++ b/7.3.569 @@ -0,0 +1,4762 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.569 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.569 +Problem: Evaluating Vim expression in Python is insufficient. +Solution: Add vim.bindeval(). Also add pyeval() and py3eval(). (ZyX) +Files: runtime/doc/eval.txt, runtime/doc/if_pyth.txt, src/eval.c, + src/if_lua.c, src/if_py_both.h, src/if_python.c, src/if_python3.c, + src/proto/eval.pro, src/proto/if_python.pro, + src/proto/if_python3.pro, src/testdir/Make_amiga.mak, + src/testdir/Make_dos.mak, src/testdir/Make_ming.mak, + src/testdir/Make_os2.mak, src/testdir/Makefile, + src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.568/runtime/doc/eval.txt 2012-03-07 19:16:49.000000000 +0100 +--- runtime/doc/eval.txt 2012-06-20 18:01:02.000000000 +0200 +*************** +*** 1836,1844 **** + localtime() Number current time + log( {expr}) Float natural logarithm (base e) of {expr} + log10( {expr}) Float logarithm of Float {expr} to base 10 + map( {expr}, {string}) List/Dict change each item in {expr} to {expr} + maparg( {name}[, {mode} [, {abbr} [, {dict}]]]) +! String rhs of mapping {name} in mode {mode} + mapcheck( {name}[, {mode} [, {abbr}]]) + String check for mappings matching {name} + match( {expr}, {pat}[, {start}[, {count}]]) +--- 1847,1857 ---- + localtime() Number current time + log( {expr}) Float natural logarithm (base e) of {expr} + log10( {expr}) Float logarithm of Float {expr} to base 10 ++ luaeval( {expr}[, {expr}]) any evaluate |Lua| expression + map( {expr}, {string}) List/Dict change each item in {expr} to {expr} + maparg( {name}[, {mode} [, {abbr} [, {dict}]]]) +! String or Dict +! rhs of mapping {name} in mode {mode} + mapcheck( {name}[, {mode} [, {abbr}]]) + String check for mappings matching {name} + match( {expr}, {pat}[, {start}[, {count}]]) +*************** +*** 1867,1872 **** +--- 1880,1887 ---- + prevnonblank( {lnum}) Number line nr of non-blank line <= {lnum} + printf( {fmt}, {expr1}...) String format text + pumvisible() Number whether popup menu is visible ++ pyeval( {expr}) any evaluate |Python| expression ++ py3eval( {expr}) any evaluate |python3| expression + range( {expr} [, {max} [, {stride}]]) + List items from {expr} to {max} + readfile( {fname} [, {binary} [, {max}]]) +*************** +*** 3980,3985 **** +--- 4003,4022 ---- + < -2.0 + {only available when compiled with the |+float| feature} + ++ luaeval({expr}[, {expr}]) *luaeval()* ++ Evaluate Lua expression {expr} and return its result converted ++ to Vim data structures. Second {expr} may hold additional ++ argument accessible as _A inside first {expr}. ++ Strings are returned as they are. ++ Boolean objects are converted to numbers. ++ Numbers are converted to |Float| values if vim was compiled ++ with |+float| and to numbers otherwise. ++ Dictionaries and lists obtained by vim.eval() are returned ++ as-is. ++ Other objects are returned as zero without any errors. ++ See |lua-luaeval| for more details. ++ {only available when compiled with the |+lua| feature} ++ + map({expr}, {string}) *map()* + {expr} must be a |List| or a |Dictionary|. + Replace each item in {expr} with the result of evaluating +*************** +*** 4574,4579 **** +--- 4612,4640 ---- + This can be used to avoid some things that would remove the + popup menu. + ++ *E860* *E861* ++ py3eval({expr}) *py3eval()* ++ Evaluate Python expression {expr} and return its result ++ converted to Vim data structures. ++ Numbers and strings are returned as they are (strings are ++ copied though, unicode strings are additionally converted to ++ 'encoding'). ++ Lists are represented as Vim |List| type. ++ Dictionaries are represented as Vim |Dictionary| type with ++ keys converted to strings. ++ {only available when compiled with the |+python3| feature} ++ ++ *E858* *E859* ++ pyeval({expr}) *pyeval()* ++ Evaluate Python expression {expr} and return its result ++ converted to Vim data structures. ++ Numbers and strings are returned as they are (strings are ++ copied though). ++ Lists are represented as Vim |List| type. ++ Dictionaries are represented as Vim |Dictionary| type with ++ keys converted to strings. ++ {only available when compiled with the |+python| feature} ++ + *E726* *E727* + range({expr} [, {max} [, {stride}]]) *range()* + Returns a |List| with Numbers: +*************** +*** 4807,4812 **** +--- 4868,4877 ---- + Search for regexp pattern {pattern}. The search starts at the + cursor position (you can use |cursor()| to set it). + ++ If there is no match a 0 is returned and the cursor doesn't ++ move. No error message is given. ++ When a match has been found its line number is returned. ++ + {flags} is a String, which can contain these character flags: + 'b' search backward instead of forward + 'c' accept a match at the cursor position +*** ../vim-7.3.568/runtime/doc/if_pyth.txt 2010-08-15 21:57:12.000000000 +0200 +--- runtime/doc/if_pyth.txt 2012-06-20 18:01:02.000000000 +0200 +*************** +*** 1,4 **** +! *if_pyth.txt* For Vim version 7.3. Last change: 2010 Aug 13 + + + VIM REFERENCE MANUAL by Paul Moore +--- 1,4 ---- +! *if_pyth.txt* For Vim version 7.3. Last change: 2012 Feb 04 + + + VIM REFERENCE MANUAL by Paul Moore +*************** +*** 6,18 **** + + The Python Interface to Vim *python* *Python* + +! 1. Commands |python-commands| +! 2. The vim module |python-vim| +! 3. Buffer objects |python-buffer| +! 4. Range objects |python-range| +! 5. Window objects |python-window| +! 6. Dynamic loading |python-dynamic| +! 7. Python 3 |python3| + + {Vi does not have any of these commands} + +--- 6,19 ---- + + The Python Interface to Vim *python* *Python* + +! 1. Commands |python-commands| +! 2. The vim module |python-vim| +! 3. Buffer objects |python-buffer| +! 4. Range objects |python-range| +! 5. Window objects |python-window| +! 6. pyeval(), py3eval() Vim functions |python-pyeval| +! 7. Dynamic loading |python-dynamic| +! 8. Python 3 |python3| + + {Vi does not have any of these commands} + +*************** +*** 150,155 **** +--- 151,172 ---- + [{'cmd': '/^eval_expr(arg, nextcmd)$/', 'static': 0, 'name': + 'eval_expr', 'kind': 'f', 'filename': './src/eval.c'}] + ++ vim.bindeval(str) *python-bindeval* ++ Like |python-eval|, but ++ 1. if expression evaluates to |List| or |Dictionary| it is returned as ++ vimlist or vimdictionary python type that are connected to original ++ list or dictionary. Thus modifications to these objects imply ++ modifications of the original. ++ 2. if expression evaluates to a function reference, then it returns ++ callable vimfunction object. Use self keyword argument to assign ++ |self| object for dictionary functions. ++ ++ Note: this function has the same behavior as |lua-eval| (except that ++ lua does not support running vim functions), |python-eval| is ++ kept for backwards compatibility in order not to make scripts ++ relying on outputs of vim.eval() being a copy of original or ++ vim.eval("1") returning a string. ++ + + + Error object of the "vim" module +*************** +*** 222,229 **** + - from indexing vim.buffers (|python-buffers|) + - from the "buffer" attribute of a window (|python-window|) + +! Buffer objects have one read-only attribute - name - the full file name for +! the buffer. They also have three methods (append, mark, and range; see below). + + You can also treat buffer objects as sequence objects. In this context, they + act as if they were lists (yes, they are mutable) of strings, with each +--- 239,247 ---- + - from indexing vim.buffers (|python-buffers|) + - from the "buffer" attribute of a window (|python-window|) + +! Buffer objects have two read-only attributes - name - the full file name for +! the buffer, and number - the buffer number. They also have three methods +! (append, mark, and range; see below). + + You can also treat buffer objects as sequence objects. In this context, they + act as if they were lists (yes, they are mutable) of strings, with each +*************** +*** 318,324 **** + The width attribute is writable only if the screen is split vertically. + + ============================================================================== +! 6. Dynamic loading *python-dynamic* + + On MS-Windows the Python library can be loaded dynamically. The |:version| + output then includes |+python/dyn|. +--- 336,348 ---- + The width attribute is writable only if the screen is split vertically. + + ============================================================================== +! 6. pyeval() and py3eval() Vim functions *python-pyeval* +! +! To facilitate bi-directional interface, you can use |pyeval()| and |py3eval()| +! functions to evaluate Python expressions and pass their values to VimL. +! +! ============================================================================== +! 7. Dynamic loading *python-dynamic* + + On MS-Windows the Python library can be loaded dynamically. The |:version| + output then includes |+python/dyn|. +*************** +*** 335,347 **** + sure edit "gvim.exe" and search for "python\d*.dll\c". + + ============================================================================== +! 7. Python 3 *python3* + + *:py3* *:python3* + The |:py3| and |:python3| commands work similar to |:python|. + *:py3file* + The |:py3file| command works similar to |:pyfile|. + + Vim can be built in four ways (:version output): + 1. No Python support (-python, -python3) + 2. Python 2 support only (+python or +python/dyn, -python3) +--- 359,372 ---- + sure edit "gvim.exe" and search for "python\d*.dll\c". + + ============================================================================== +! 8. Python 3 *python3* + + *:py3* *:python3* + The |:py3| and |:python3| commands work similar to |:python|. + *:py3file* + The |:py3file| command works similar to |:pyfile|. + ++ + Vim can be built in four ways (:version output): + 1. No Python support (-python, -python3) + 2. Python 2 support only (+python or +python/dyn, -python3) +*************** +*** 355,361 **** + When doing this on Linux/Unix systems and importing global symbols, this leads + to a crash when the second Python version is used. So either global symbols + are loaded but only one Python version is activated, or no global symbols are +! loaded. The latter makes Python's "import" fail on libaries that expect the + symbols to be provided by Vim. + *E836* *E837* + Vim's configuration script makes a guess for all libraries based on one +--- 380,386 ---- + When doing this on Linux/Unix systems and importing global symbols, this leads + to a crash when the second Python version is used. So either global symbols + are loaded but only one Python version is activated, or no global symbols are +! loaded. The latter makes Python's "import" fail on libraries that expect the + symbols to be provided by Vim. + *E836* *E837* + Vim's configuration script makes a guess for all libraries based on one +*************** +*** 377,382 **** +--- 402,419 ---- + 3. You undefine PY_NO_RTLD_GLOBAL in auto/config.h after configuration. This + may crash Vim though. + ++ *has-python* ++ You can test what Python version is available with: > ++ if has('python') ++ echo 'there is Python 2.x' ++ elseif has('python3') ++ echo 'there is Python 3.x' ++ endif ++ ++ Note however, that when Python 2 and 3 are both available and loaded ++ dynamically, these has() calls will try to load them. If only one can be ++ loaded at a time, just checking if Python 2 or 3 are available will prevent ++ the other one from being available. + + ============================================================================== + vim:tw=78:ts=8:ft=help:norl: +*** ../vim-7.3.568/src/eval.c 2012-06-20 14:13:02.000000000 +0200 +--- src/eval.c 2012-06-20 18:29:15.000000000 +0200 +*************** +*** 424,453 **** + static int get_lit_string_tv __ARGS((char_u **arg, typval_T *rettv, int evaluate)); + static int get_list_tv __ARGS((char_u **arg, typval_T *rettv, int evaluate)); + static int rettv_list_alloc __ARGS((typval_T *rettv)); +- static listitem_T *listitem_alloc __ARGS((void)); + static void listitem_free __ARGS((listitem_T *item)); +- static void listitem_remove __ARGS((list_T *l, listitem_T *item)); + static long list_len __ARGS((list_T *l)); + static int list_equal __ARGS((list_T *l1, list_T *l2, int ic, int recursive)); + static int dict_equal __ARGS((dict_T *d1, dict_T *d2, int ic, int recursive)); + static int tv_equal __ARGS((typval_T *tv1, typval_T *tv2, int ic, int recursive)); +- static listitem_T *list_find __ARGS((list_T *l, long n)); + static long list_find_nr __ARGS((list_T *l, long idx, int *errorp)); + static long list_idx_of_item __ARGS((list_T *l, listitem_T *item)); +- static void list_append __ARGS((list_T *l, listitem_T *item)); + static int list_append_number __ARGS((list_T *l, varnumber_T n)); +- static int list_insert_tv __ARGS((list_T *l, typval_T *tv, listitem_T *item)); + static int list_extend __ARGS((list_T *l1, list_T *l2, listitem_T *bef)); + static int list_concat __ARGS((list_T *l1, list_T *l2, typval_T *tv)); + static list_T *list_copy __ARGS((list_T *orig, int deep, int copyID)); +- static void list_remove __ARGS((list_T *l, listitem_T *item, listitem_T *item2)); + static char_u *list2string __ARGS((typval_T *tv, int copyID)); + static int list_join_inner __ARGS((garray_T *gap, list_T *l, char_u *sep, int echo_style, int copyID, garray_T *join_gap)); + static int list_join __ARGS((garray_T *gap, list_T *l, char_u *sep, int echo, int copyID)); + static int free_unref_items __ARGS((int copyID)); +- static void set_ref_in_ht __ARGS((hashtab_T *ht, int copyID)); +- static void set_ref_in_list __ARGS((list_T *l, int copyID)); +- static void set_ref_in_item __ARGS((typval_T *tv, int copyID)); + static int rettv_dict_alloc __ARGS((typval_T *rettv)); + static void dict_free __ARGS((dict_T *d, int recurse)); + static dictitem_T *dictitem_copy __ARGS((dictitem_T *org)); +--- 424,444 ---- +*************** +*** 654,659 **** +--- 645,656 ---- + static void f_prevnonblank __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_printf __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_pumvisible __ARGS((typval_T *argvars, typval_T *rettv)); ++ #ifdef FEAT_PYTHON3 ++ static void f_py3eval __ARGS((typval_T *argvars, typval_T *rettv)); ++ #endif ++ #ifdef FEAT_PYTHON ++ static void f_pyeval __ARGS((typval_T *argvars, typval_T *rettv)); ++ #endif + static void f_range __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_readfile __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_reltime __ARGS((typval_T *argvars, typval_T *rettv)); +*************** +*** 824,831 **** + static char_u *autoload_name __ARGS((char_u *name)); + static void cat_func_name __ARGS((char_u *buf, ufunc_T *fp)); + static void func_free __ARGS((ufunc_T *fp)); +- static void func_unref __ARGS((char_u *name)); +- static void func_ref __ARGS((char_u *name)); + static void call_user_func __ARGS((ufunc_T *fp, int argcount, typval_T *argvars, typval_T *rettv, linenr_T firstline, linenr_T lastline, dict_T *selfdict)); + static int can_free_funccal __ARGS((funccall_T *fc, int copyID)) ; + static void free_funccal __ARGS((funccall_T *fc, int free_val)); +--- 821,826 ---- +*************** +*** 5927,5933 **** + /* + * Allocate a list item. + */ +! static listitem_T * + listitem_alloc() + { + return (listitem_T *)alloc(sizeof(listitem_T)); +--- 5922,5928 ---- + /* + * Allocate a list item. + */ +! listitem_T * + listitem_alloc() + { + return (listitem_T *)alloc(sizeof(listitem_T)); +*************** +*** 5947,5953 **** + /* + * Remove a list item from a List and free it. Also clears the value. + */ +! static void + listitem_remove(l, item) + list_T *l; + listitem_T *item; +--- 5942,5948 ---- + /* + * Remove a list item from a List and free it. Also clears the value. + */ +! void + listitem_remove(l, item) + list_T *l; + listitem_T *item; +*************** +*** 6123,6129 **** + * A negative index is counted from the end; -1 is the last item. + * Returns NULL when "n" is out of range. + */ +! static listitem_T * + list_find(l, n) + list_T *l; + long n; +--- 6118,6124 ---- + * A negative index is counted from the end; -1 is the last item. + * Returns NULL when "n" is out of range. + */ +! listitem_T * + list_find(l, n) + list_T *l; + long n; +*************** +*** 6265,6271 **** + /* + * Append item "item" to the end of list "l". + */ +! static void + list_append(l, item) + list_T *l; + listitem_T *item; +--- 6260,6266 ---- + /* + * Append item "item" to the end of list "l". + */ +! void + list_append(l, item) + list_T *l; + listitem_T *item; +*************** +*** 6378,6384 **** + * If "item" is NULL append at the end. + * Return FAIL when out of memory. + */ +! static int + list_insert_tv(l, tv, item) + list_T *l; + typval_T *tv; +--- 6373,6379 ---- + * If "item" is NULL append at the end. + * Return FAIL when out of memory. + */ +! int + list_insert_tv(l, tv, item) + list_T *l; + typval_T *tv; +*************** +*** 6523,6529 **** + * Remove items "item" to "item2" from list "l". + * Does not free the listitem or the value! + */ +! static void + list_remove(l, item, item2) + list_T *l; + listitem_T *item; +--- 6518,6524 ---- + * Remove items "item" to "item2" from list "l". + * Does not free the listitem or the value! + */ +! void + list_remove(l, item, item2) + list_T *l; + listitem_T *item; +*************** +*** 6785,6790 **** +--- 6780,6793 ---- + set_ref_in_lua(copyID); + #endif + ++ #ifdef FEAT_PYTHON ++ set_ref_in_python(copyID); ++ #endif ++ ++ #ifdef FEAT_PYTHON3 ++ set_ref_in_python3(copyID); ++ #endif ++ + /* + * 2. Free lists and dictionaries that are not referenced. + */ +*************** +*** 6870,6876 **** + /* + * Mark all lists and dicts referenced through hashtab "ht" with "copyID". + */ +! static void + set_ref_in_ht(ht, copyID) + hashtab_T *ht; + int copyID; +--- 6873,6879 ---- + /* + * Mark all lists and dicts referenced through hashtab "ht" with "copyID". + */ +! void + set_ref_in_ht(ht, copyID) + hashtab_T *ht; + int copyID; +*************** +*** 6890,6896 **** + /* + * Mark all lists and dicts referenced through list "l" with "copyID". + */ +! static void + set_ref_in_list(l, copyID) + list_T *l; + int copyID; +--- 6893,6899 ---- + /* + * Mark all lists and dicts referenced through list "l" with "copyID". + */ +! void + set_ref_in_list(l, copyID) + list_T *l; + int copyID; +*************** +*** 6904,6910 **** + /* + * Mark all lists and dicts referenced through typval "tv" with "copyID". + */ +! static void + set_ref_in_item(tv, copyID) + typval_T *tv; + int copyID; +--- 6907,6913 ---- + /* + * Mark all lists and dicts referenced through typval "tv" with "copyID". + */ +! void + set_ref_in_item(tv, copyID) + typval_T *tv; + int copyID; +*************** +*** 7986,7991 **** +--- 7989,8000 ---- + {"prevnonblank", 1, 1, f_prevnonblank}, + {"printf", 2, 19, f_printf}, + {"pumvisible", 0, 0, f_pumvisible}, ++ #ifdef FEAT_PYTHON3 ++ {"py3eval", 1, 1, f_py3eval}, ++ #endif ++ #ifdef FEAT_PYTHON ++ {"pyeval", 1, 1, f_pyeval}, ++ #endif + {"range", 1, 3, f_range}, + {"readfile", 1, 3, f_readfile}, + {"reltime", 0, 2, f_reltime}, +*************** +*** 9150,9155 **** +--- 9159,9203 ---- + #endif + } + ++ int ++ func_call(name, args, selfdict, rettv) ++ char_u *name; ++ typval_T *args; ++ dict_T *selfdict; ++ typval_T *rettv; ++ { ++ listitem_T *item; ++ typval_T argv[MAX_FUNC_ARGS + 1]; ++ int argc = 0; ++ int dummy; ++ int r = 0; ++ ++ for (item = args->vval.v_list->lv_first; item != NULL; ++ item = item->li_next) ++ { ++ if (argc == MAX_FUNC_ARGS) ++ { ++ EMSG(_("E699: Too many arguments")); ++ break; ++ } ++ /* Make a copy of each argument. This is needed to be able to set ++ * v_lock to VAR_FIXED in the copy without changing the original list. ++ */ ++ copy_tv(&item->li_tv, &argv[argc++]); ++ } ++ ++ if (item == NULL) ++ r = call_func(name, (int)STRLEN(name), rettv, argc, argv, ++ curwin->w_cursor.lnum, curwin->w_cursor.lnum, ++ &dummy, TRUE, selfdict); ++ ++ /* Free the arguments. */ ++ while (argc > 0) ++ clear_tv(&argv[--argc]); ++ ++ return r; ++ } ++ + /* + * "call(func, arglist)" function + */ +*************** +*** 9159,9168 **** + typval_T *rettv; + { + char_u *func; +- typval_T argv[MAX_FUNC_ARGS + 1]; +- int argc = 0; +- listitem_T *item; +- int dummy; + dict_T *selfdict = NULL; + + if (argvars[1].v_type != VAR_LIST) +--- 9207,9212 ---- +*************** +*** 9190,9217 **** + selfdict = argvars[2].vval.v_dict; + } + +! for (item = argvars[1].vval.v_list->lv_first; item != NULL; +! item = item->li_next) +! { +! if (argc == MAX_FUNC_ARGS) +! { +! EMSG(_("E699: Too many arguments")); +! break; +! } +! /* Make a copy of each argument. This is needed to be able to set +! * v_lock to VAR_FIXED in the copy without changing the original list. +! */ +! copy_tv(&item->li_tv, &argv[argc++]); +! } +! +! if (item == NULL) +! (void)call_func(func, (int)STRLEN(func), rettv, argc, argv, +! curwin->w_cursor.lnum, curwin->w_cursor.lnum, +! &dummy, TRUE, selfdict); +! +! /* Free the arguments. */ +! while (argc > 0) +! clear_tv(&argv[--argc]); + } + + #ifdef FEAT_FLOAT +--- 9234,9240 ---- + selfdict = argvars[2].vval.v_dict; + } + +! (void)func_call(func, &argvars[1], selfdict, rettv); + } + + #ifdef FEAT_FLOAT +*************** +*** 14424,14429 **** +--- 14447,14486 ---- + #endif + } + ++ #ifdef FEAT_PYTHON3 ++ /* ++ * "py3eval()" function ++ */ ++ static void ++ f_py3eval(argvars, rettv) ++ typval_T *argvars; ++ typval_T *rettv; ++ { ++ char_u *str; ++ char_u buf[NUMBUFLEN]; ++ ++ str = get_tv_string_buf(&argvars[0], buf); ++ do_py3eval(str, rettv); ++ } ++ #endif ++ ++ #ifdef FEAT_PYTHON ++ /* ++ * "pyeval()" function ++ */ ++ static void ++ f_pyeval(argvars, rettv) ++ typval_T *argvars; ++ typval_T *rettv; ++ { ++ char_u *str; ++ char_u buf[NUMBUFLEN]; ++ ++ str = get_tv_string_buf(&argvars[0], buf); ++ do_pyeval(str, rettv); ++ } ++ #endif ++ + /* + * "range()" function + */ +*************** +*** 22139,22145 **** + * Unreference a Function: decrement the reference count and free it when it + * becomes zero. Only for numbered functions. + */ +! static void + func_unref(name) + char_u *name; + { +--- 22196,22202 ---- + * Unreference a Function: decrement the reference count and free it when it + * becomes zero. Only for numbered functions. + */ +! void + func_unref(name) + char_u *name; + { +*************** +*** 22163,22169 **** + /* + * Count a reference to a Function. + */ +! static void + func_ref(name) + char_u *name; + { +--- 22220,22226 ---- + /* + * Count a reference to a Function. + */ +! void + func_ref(name) + char_u *name; + { +*** ../vim-7.3.568/src/if_lua.c 2012-04-06 14:30:55.000000000 +0200 +--- src/if_lua.c 2012-06-20 18:16:33.000000000 +0200 +*************** +*** 199,207 **** + lua_Number (*dll_lua_tonumberx) (lua_State *L, int idx, int *isnum); + lua_Integer (*dll_lua_tointegerx) (lua_State *L, int idx, int *isnum); + void (*dll_lua_callk) (lua_State *L, int nargs, int nresults, int ctx, +! lua_CFunction k); + int (*dll_lua_pcallk) (lua_State *L, int nargs, int nresults, int errfunc, +! int ctx, lua_CFunction k); + void (*dll_lua_getglobal) (lua_State *L, const char *var); + void (*dll_lua_setglobal) (lua_State *L, const char *var); + #endif +--- 199,207 ---- + lua_Number (*dll_lua_tonumberx) (lua_State *L, int idx, int *isnum); + lua_Integer (*dll_lua_tointegerx) (lua_State *L, int idx, int *isnum); + void (*dll_lua_callk) (lua_State *L, int nargs, int nresults, int ctx, +! lua_CFunction k); + int (*dll_lua_pcallk) (lua_State *L, int nargs, int nresults, int errfunc, +! int ctx, lua_CFunction k); + void (*dll_lua_getglobal) (lua_State *L, const char *var); + void (*dll_lua_setglobal) (lua_State *L, const char *var); + #endif +*************** +*** 394,400 **** + luaL_typeerror (lua_State *L, int narg, const char *tname) + { + const char *msg = lua_pushfstring(L, "%s expected, got %s", +! tname, luaL_typename(L, narg)); + return luaL_argerror(L, narg, msg); + } + #endif +--- 394,400 ---- + luaL_typeerror (lua_State *L, int narg, const char *tname) + { + const char *msg = lua_pushfstring(L, "%s expected, got %s", +! tname, luaL_typename(L, narg)); + return luaL_argerror(L, narg, msg); + } + #endif +*************** +*** 646,786 **** + return 1; \ + } + +- +- /* adapted from eval.c */ +- +- #define listitem_alloc() (listitem_T *)alloc(sizeof(listitem_T)) +- +- static listitem_T * +- list_find (list_T *l, long n) +- { +- listitem_T *li; +- if (l == NULL || n < -l->lv_len || n >= l->lv_len) +- return NULL; +- if (n < 0) /* search backward? */ +- for (li = l->lv_last; n < -1; li = li->li_prev) +- n++; +- else /* search forward */ +- for (li = l->lv_first; n > 0; li = li->li_next) +- n--; +- return li; +- } +- +- static void +- list_remove (list_T *l, listitem_T *li) +- { +- listwatch_T *lw; +- --l->lv_len; +- /* fix watchers */ +- for (lw = l->lv_watch; lw != NULL; lw = lw->lw_next) +- if (lw->lw_item == li) +- lw->lw_item = li->li_next; +- /* fix list pointers */ +- if (li->li_next == NULL) /* last? */ +- l->lv_last = li->li_prev; +- else +- li->li_next->li_prev = li->li_prev; +- if (li->li_prev == NULL) /* first? */ +- l->lv_first = li->li_next; +- else +- li->li_prev->li_next = li->li_next; +- l->lv_idx_item = NULL; +- } +- +- static void +- list_append(list_T *l, listitem_T *item) +- { +- if (l->lv_last == NULL) /* empty list? */ +- l->lv_first = item; +- else +- l->lv_last->li_next = item; +- item->li_prev = l->lv_last; +- item->li_next = NULL; +- l->lv_last = item; +- ++l->lv_len; +- } +- +- static int +- list_insert_tv(list_T *l, typval_T *tv, listitem_T *item) +- { +- listitem_T *ni = listitem_alloc(); +- +- if (ni == NULL) +- return FAIL; +- copy_tv(tv, &ni->li_tv); +- if (item == NULL) +- list_append(l, ni); +- else +- { +- ni->li_prev = item->li_prev; +- ni->li_next = item; +- if (item->li_prev == NULL) +- { +- l->lv_first = ni; +- ++l->lv_idx; +- } +- else +- { +- item->li_prev->li_next = ni; +- l->lv_idx_item = NULL; +- } +- item->li_prev = ni; +- ++l->lv_len; +- } +- return OK; +- } +- +- /* set references */ +- +- static void set_ref_in_tv (typval_T *tv, int copyID); +- +- static void +- set_ref_in_dict(dict_T *d, int copyID) +- { +- hashtab_T *ht = &d->dv_hashtab; +- int n = ht->ht_used; +- hashitem_T *hi; +- for (hi = ht->ht_array; n > 0; ++hi) +- if (!HASHITEM_EMPTY(hi)) +- { +- dictitem_T *di = dict_lookup(hi); +- set_ref_in_tv(&di->di_tv, copyID); +- --n; +- } +- } +- +- static void +- set_ref_in_list(list_T *l, int copyID) +- { +- listitem_T *li; +- for (li = l->lv_first; li != NULL; li = li->li_next) +- set_ref_in_tv(&li->li_tv, copyID); +- } +- +- static void +- set_ref_in_tv(typval_T *tv, int copyID) +- { +- if (tv->v_type == VAR_LIST) +- { +- list_T *l = tv->vval.v_list; +- if (l != NULL && l->lv_copyID != copyID) +- { +- l->lv_copyID = copyID; +- set_ref_in_list(l, copyID); +- } +- } +- else if (tv->v_type == VAR_DICT) +- { +- dict_T *d = tv->vval.v_dict; +- if (d != NULL && d->dv_copyID != copyID) +- { +- d->dv_copyID = copyID; +- set_ref_in_dict(d, copyID); +- } +- } +- } +- +- + /* ======= List type ======= */ + + static luaV_List * +--- 646,651 ---- +*************** +*** 876,882 **** + if (li == NULL) return 0; + if (lua_isnil(L, 3)) /* remove? */ + { +! list_remove(l, li); + clear_tv(&li->li_tv); + vim_free(li); + } +--- 741,747 ---- + if (li == NULL) return 0; + if (lua_isnil(L, 3)) /* remove? */ + { +! list_remove(l, li, li); + clear_tv(&li->li_tv); + vim_free(li); + } +*************** +*** 904,911 **** + typval_T v; + lua_settop(L, 2); + luaV_totypval(L, 2, &v); +! copy_tv(&v, &li->li_tv); +! list_append(l, li); + } + lua_settop(L, 1); + return 1; +--- 769,775 ---- + typval_T v; + lua_settop(L, 2); + luaV_totypval(L, 2, &v); +! list_append_tv(l, &v); + } + lua_settop(L, 1); + return 1; +*************** +*** 1682,1688 **** + tv.vval.v_dict = (dict_T *) lua_touserdata(L, 4); /* key */ + } + lua_pop(L, 2); /* metatable and value */ +! set_ref_in_tv(&tv, copyID); + } + return 0; + } +--- 1546,1552 ---- + tv.vval.v_dict = (dict_T *) lua_touserdata(L, 4); /* key */ + } + lua_pop(L, 2); /* metatable and value */ +! set_ref_in_item(&tv, copyID); + } + return 0; + } +*** ../vim-7.3.568/src/if_py_both.h 2012-04-20 13:31:16.000000000 +0200 +--- src/if_py_both.h 2012-06-29 12:03:52.000000000 +0200 +*************** +*** 1,4 **** +! /* vi:set ts=8 sts=4 sw=4: + * + * VIM - Vi IMproved by Bram Moolenaar + * +--- 1,4 ---- +! /* vi:set ts=8 sts=4 sw=4 noet: + * + * VIM - Vi IMproved by Bram Moolenaar + * +*************** +*** 105,111 **** + return NULL; + Py_INCREF(list); + +! if (!PyList_Check(list)) { + PyErr_SetString(PyExc_TypeError, _("writelines() requires list of strings")); + Py_DECREF(list); + return NULL; +--- 105,112 ---- + return NULL; + Py_INCREF(list); + +! if (!PyList_Check(list)) +! { + PyErr_SetString(PyExc_TypeError, _("writelines() requires list of strings")); + Py_DECREF(list); + return NULL; +*************** +*** 119,125 **** + char *str = NULL; + PyInt len; + +! if (!PyArg_Parse(line, "et#", ENC_OPT, &str, &len)) { + PyErr_SetString(PyExc_TypeError, _("writelines() requires list of strings")); + Py_DECREF(list); + return NULL; +--- 120,127 ---- + char *str = NULL; + PyInt len; + +! if (!PyArg_Parse(line, "et#", ENC_OPT, &str, &len)) +! { + PyErr_SetString(PyExc_TypeError, _("writelines() requires list of strings")); + Py_DECREF(list); + return NULL; +*************** +*** 297,303 **** + { + PyObject *result; + PyObject *newObj; +! char ptrBuf[NUMBUFLEN]; + + /* Avoid infinite recursion */ + if (depth > 100) +--- 299,305 ---- + { + PyObject *result; + PyObject *newObj; +! char ptrBuf[sizeof(void *) * 2 + 3]; + + /* Avoid infinite recursion */ + if (depth > 100) +*************** +*** 312,320 **** + if ((our_tv->v_type == VAR_LIST && our_tv->vval.v_list != NULL) + || (our_tv->v_type == VAR_DICT && our_tv->vval.v_dict != NULL)) + { +! sprintf(ptrBuf, PRINTF_DECIMAL_LONG_U, +! our_tv->v_type == VAR_LIST ? (long_u)our_tv->vval.v_list +! : (long_u)our_tv->vval.v_dict); + result = PyDict_GetItemString(lookupDict, ptrBuf); + if (result != NULL) + { +--- 314,322 ---- + if ((our_tv->v_type == VAR_LIST && our_tv->vval.v_list != NULL) + || (our_tv->v_type == VAR_DICT && our_tv->vval.v_dict != NULL)) + { +! sprintf(ptrBuf, "%p", +! our_tv->v_type == VAR_LIST ? (void *)our_tv->vval.v_list +! : (void *)our_tv->vval.v_dict); + result = PyDict_GetItemString(lookupDict, ptrBuf); + if (result != NULL) + { +*************** +*** 374,509 **** + hashitem_T *hi; + dictitem_T *di; + +! PyDict_SetItemString(lookupDict, ptrBuf, result); + +! for (hi = ht->ht_array; todo > 0; ++hi) + { +! if (!HASHITEM_EMPTY(hi)) +! { +! --todo; +! +! di = dict_lookup(hi); +! newObj = VimToPython(&di->di_tv, depth + 1, lookupDict); +! PyDict_SetItemString(result, (char *)hi->hi_key, newObj); +! Py_DECREF(newObj); +! } + } + } + } +! else + { +! Py_INCREF(Py_None); +! result = Py_None; + } + +! return result; + } +- #endif + + static PyObject * +! VimEval(PyObject *self UNUSED, PyObject *args UNUSED) + { +! #ifdef FEAT_EVAL +! char *expr; +! typval_T *our_tv; +! PyObject *result; +! PyObject *lookup_dict; + +! if (!PyArg_ParseTuple(args, "s", &expr)) + return NULL; + +! Py_BEGIN_ALLOW_THREADS +! Python_Lock_Vim(); +! our_tv = eval_expr((char_u *)expr, NULL); +! +! Python_Release_Vim(); +! Py_END_ALLOW_THREADS +! +! if (our_tv == NULL) + { +! PyErr_SetVim(_("invalid expression")); + return NULL; + } + +- /* Convert the Vim type into a Python type. Create a dictionary that's +- * used to check for recursive loops. */ + lookup_dict = PyDict_New(); +! result = VimToPython(our_tv, 1, lookup_dict); + Py_DECREF(lookup_dict); + +! +! Py_BEGIN_ALLOW_THREADS +! Python_Lock_Vim(); +! free_tv(our_tv); +! Python_Release_Vim(); +! Py_END_ALLOW_THREADS +! +! return result; +! #else +! PyErr_SetVim(_("expressions disabled at compile time")); +! return NULL; +! #endif + } + +! /* +! * Vim module - Definitions +! */ +! +! static struct PyMethodDef VimMethods[] = { +! /* name, function, calling, documentation */ +! {"command", VimCommand, 1, "Execute a Vim ex-mode command" }, +! {"eval", VimEval, 1, "Evaluate an expression using Vim evaluator" }, +! { NULL, NULL, 0, NULL } + }; + + typedef struct + { + PyObject_HEAD +! buf_T *buf; +! } +! BufferObject; + +! #define INVALID_BUFFER_VALUE ((buf_T *)(-1)) +! +! /* +! * Buffer list object - Implementation +! */ + +! static PyInt +! BufListLength(PyObject *self UNUSED) + { +! buf_T *b = firstbuf; +! PyInt n = 0; + +! while (b) + { +! ++n; +! b = b->b_next; + } +! +! return n; + } + + static PyObject * +! BufListItem(PyObject *self UNUSED, PyInt n) + { +! buf_T *b; + +! for (b = firstbuf; b; b = b->b_next, --n) + { +! if (n == 0) +! return BufferNew(b); + } + +! PyErr_SetString(PyExc_IndexError, _("no such buffer")); +! return NULL; + } + +! typedef struct +! { +! PyObject_HEAD +! win_T *win; +! } WindowObject; + + #define INVALID_WINDOW_VALUE ((win_T *)(-1)) + +--- 376,1325 ---- + hashitem_T *hi; + dictitem_T *di; + +! PyDict_SetItemString(lookupDict, ptrBuf, result); +! +! for (hi = ht->ht_array; todo > 0; ++hi) +! { +! if (!HASHITEM_EMPTY(hi)) +! { +! --todo; +! +! di = dict_lookup(hi); +! newObj = VimToPython(&di->di_tv, depth + 1, lookupDict); +! PyDict_SetItemString(result, (char *)hi->hi_key, newObj); +! Py_DECREF(newObj); +! } +! } +! } +! } +! else +! { +! Py_INCREF(Py_None); +! result = Py_None; +! } +! +! return result; +! } +! #endif +! +! static PyObject * +! VimEval(PyObject *self UNUSED, PyObject *args UNUSED) +! { +! #ifdef FEAT_EVAL +! char *expr; +! typval_T *our_tv; +! PyObject *result; +! PyObject *lookup_dict; +! +! if (!PyArg_ParseTuple(args, "s", &expr)) +! return NULL; +! +! Py_BEGIN_ALLOW_THREADS +! Python_Lock_Vim(); +! our_tv = eval_expr((char_u *)expr, NULL); +! +! Python_Release_Vim(); +! Py_END_ALLOW_THREADS +! +! if (our_tv == NULL) +! { +! PyErr_SetVim(_("invalid expression")); +! return NULL; +! } +! +! /* Convert the Vim type into a Python type. Create a dictionary that's +! * used to check for recursive loops. */ +! lookup_dict = PyDict_New(); +! result = VimToPython(our_tv, 1, lookup_dict); +! Py_DECREF(lookup_dict); +! +! +! Py_BEGIN_ALLOW_THREADS +! Python_Lock_Vim(); +! free_tv(our_tv); +! Python_Release_Vim(); +! Py_END_ALLOW_THREADS +! +! return result; +! #else +! PyErr_SetVim(_("expressions disabled at compile time")); +! return NULL; +! #endif +! } +! +! static PyObject *ConvertToPyObject(typval_T *); +! +! static PyObject * +! VimEvalPy(PyObject *self UNUSED, PyObject *args UNUSED) +! { +! #ifdef FEAT_EVAL +! char *expr; +! typval_T *our_tv; +! PyObject *result; +! +! if (!PyArg_ParseTuple(args, "s", &expr)) +! return NULL; +! +! Py_BEGIN_ALLOW_THREADS +! Python_Lock_Vim(); +! our_tv = eval_expr((char_u *)expr, NULL); +! +! Python_Release_Vim(); +! Py_END_ALLOW_THREADS +! +! if (our_tv == NULL) +! { +! PyErr_SetVim(_("invalid expression")); +! return NULL; +! } +! +! result = ConvertToPyObject(our_tv); +! Py_BEGIN_ALLOW_THREADS +! Python_Lock_Vim(); +! free_tv(our_tv); +! Python_Release_Vim(); +! Py_END_ALLOW_THREADS +! +! return result; +! #else +! PyErr_SetVim(_("expressions disabled at compile time")); +! return NULL; +! #endif +! } +! +! static PyObject * +! VimStrwidth(PyObject *self UNUSED, PyObject *args) +! { +! char *expr; +! +! if (!PyArg_ParseTuple(args, "s", &expr)) +! return NULL; +! +! return PyLong_FromLong(mb_string2cells((char_u *)expr, STRLEN(expr))); +! } +! +! /* +! * Vim module - Definitions +! */ +! +! static struct PyMethodDef VimMethods[] = { +! /* name, function, calling, documentation */ +! {"command", VimCommand, 1, "Execute a Vim ex-mode command" }, +! {"eval", VimEval, 1, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, 1, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, 1, "Screen string width, counts as having width 1"}, +! { NULL, NULL, 0, NULL } +! }; +! +! typedef struct +! { +! PyObject_HEAD +! buf_T *buf; +! } BufferObject; +! +! #define INVALID_BUFFER_VALUE ((buf_T *)(-1)) +! +! /* +! * Buffer list object - Implementation +! */ +! +! static PyInt +! BufListLength(PyObject *self UNUSED) +! { +! buf_T *b = firstbuf; +! PyInt n = 0; +! +! while (b) +! { +! ++n; +! b = b->b_next; +! } +! +! return n; +! } +! +! static PyObject * +! BufListItem(PyObject *self UNUSED, PyInt n) +! { +! buf_T *b; +! +! for (b = firstbuf; b; b = b->b_next, --n) +! { +! if (n == 0) +! return BufferNew(b); +! } +! +! PyErr_SetString(PyExc_IndexError, _("no such buffer")); +! return NULL; +! } +! +! typedef struct +! { +! PyObject_HEAD +! win_T *win; +! } WindowObject; +! +! static int ConvertFromPyObject(PyObject *, typval_T *); +! static int _ConvertFromPyObject(PyObject *, typval_T *, PyObject *); +! +! typedef struct pylinkedlist_S { +! struct pylinkedlist_S *pll_next; +! struct pylinkedlist_S *pll_prev; +! PyObject *pll_obj; +! } pylinkedlist_T; +! +! static pylinkedlist_T *lastdict = NULL; +! static pylinkedlist_T *lastlist = NULL; +! +! static void +! pyll_remove(pylinkedlist_T *ref, pylinkedlist_T **last) +! { +! if (ref->pll_prev == NULL) +! { +! if (ref->pll_next == NULL) +! { +! *last = NULL; +! return; +! } +! } +! else +! ref->pll_prev->pll_next = ref->pll_next; +! +! if (ref->pll_next == NULL) +! *last = ref->pll_prev; +! else +! ref->pll_next->pll_prev = ref->pll_prev; +! } +! +! static void +! pyll_add(PyObject *self, pylinkedlist_T *ref, pylinkedlist_T **last) +! { +! if (*last == NULL) +! ref->pll_prev = NULL; +! else +! { +! (*last)->pll_next = ref; +! ref->pll_prev = *last; +! } +! ref->pll_next = NULL; +! ref->pll_obj = self; +! *last = ref; +! } +! +! static PyTypeObject DictionaryType; +! +! typedef struct +! { +! PyObject_HEAD +! dict_T *dict; +! pylinkedlist_T ref; +! } DictionaryObject; +! +! static PyObject * +! DictionaryNew(dict_T *dict) +! { +! DictionaryObject *self; +! +! self = PyObject_NEW(DictionaryObject, &DictionaryType); +! if (self == NULL) +! return NULL; +! self->dict = dict; +! ++dict->dv_refcount; +! +! pyll_add((PyObject *)(self), &self->ref, &lastdict); +! +! return (PyObject *)(self); +! } +! +! static int +! pydict_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) +! { +! dict_T *d; +! char_u *key; +! dictitem_T *di; +! PyObject *keyObject; +! PyObject *valObject; +! Py_ssize_t iter = 0; +! +! d = dict_alloc(); +! if (d == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! +! tv->v_type = VAR_DICT; +! tv->vval.v_dict = d; +! +! while (PyDict_Next(obj, &iter, &keyObject, &valObject)) +! { +! DICTKEY_DECL +! +! if (keyObject == NULL) +! return -1; +! if (valObject == NULL) +! return -1; +! +! DICTKEY_GET(-1) +! +! di = dictitem_alloc(key); +! +! DICTKEY_UNREF +! +! if (di == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! di->di_tv.v_lock = 0; +! +! if (_ConvertFromPyObject(valObject, &di->di_tv, lookupDict) == -1) +! { +! vim_free(di); +! return -1; +! } +! if (dict_add(d, di) == FAIL) +! { +! vim_free(di); +! PyErr_SetVim(_("failed to add key to dictionary")); +! return -1; +! } +! } +! return 0; +! } +! +! static int +! pymap_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) +! { +! dict_T *d; +! char_u *key; +! dictitem_T *di; +! PyObject *list; +! PyObject *litem; +! PyObject *keyObject; +! PyObject *valObject; +! Py_ssize_t lsize; +! +! d = dict_alloc(); +! if (d == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! +! tv->v_type = VAR_DICT; +! tv->vval.v_dict = d; +! +! list = PyMapping_Items(obj); +! lsize = PyList_Size(list); +! while (lsize--) +! { +! DICTKEY_DECL +! +! litem = PyList_GetItem(list, lsize); +! if (litem == NULL) +! { +! Py_DECREF(list); +! return -1; +! } +! +! keyObject = PyTuple_GetItem(litem, 0); +! if (keyObject == NULL) +! { +! Py_DECREF(list); +! Py_DECREF(litem); +! return -1; +! } +! +! DICTKEY_GET(-1) +! +! valObject = PyTuple_GetItem(litem, 1); +! if (valObject == NULL) +! { +! Py_DECREF(list); +! Py_DECREF(litem); +! return -1; +! } +! +! di = dictitem_alloc(key); +! +! DICTKEY_UNREF +! +! if (di == NULL) +! { +! Py_DECREF(list); +! Py_DECREF(litem); +! PyErr_NoMemory(); +! return -1; +! } +! di->di_tv.v_lock = 0; +! +! if (_ConvertFromPyObject(valObject, &di->di_tv, lookupDict) == -1) +! { +! vim_free(di); +! Py_DECREF(list); +! Py_DECREF(litem); +! return -1; +! } +! if (dict_add(d, di) == FAIL) +! { +! vim_free(di); +! Py_DECREF(list); +! Py_DECREF(litem); +! PyErr_SetVim(_("failed to add key to dictionary")); +! return -1; +! } +! Py_DECREF(litem); +! } +! Py_DECREF(list); +! return 0; +! } +! +! static PyInt +! DictionaryLength(PyObject *self) +! { +! return ((PyInt) ((((DictionaryObject *)(self))->dict->dv_hashtab.ht_used))); +! } +! +! static PyObject * +! DictionaryItem(PyObject *self, PyObject *keyObject) +! { +! char_u *key; +! dictitem_T *val; +! DICTKEY_DECL +! +! DICTKEY_GET(NULL) +! +! val = dict_find(((DictionaryObject *) (self))->dict, key, -1); +! +! DICTKEY_UNREF +! +! return ConvertToPyObject(&val->di_tv); +! } +! +! static PyInt +! DictionaryAssItem(PyObject *self, PyObject *keyObject, PyObject *valObject) +! { +! char_u *key; +! typval_T tv; +! dict_T *d = ((DictionaryObject *)(self))->dict; +! dictitem_T *di; +! DICTKEY_DECL +! +! if (d->dv_lock) +! { +! PyErr_SetVim(_("dict is locked")); +! return -1; +! } +! +! DICTKEY_GET(-1) +! +! di = dict_find(d, key, -1); +! +! if (valObject == NULL) +! { +! if (di == NULL) +! { +! PyErr_SetString(PyExc_IndexError, _("no such key in dictionary")); +! return -1; +! } +! hashitem_T *hi = hash_find(&d->dv_hashtab, di->di_key); +! hash_remove(&d->dv_hashtab, hi); +! dictitem_free(di); +! return 0; +! } +! +! if (ConvertFromPyObject(valObject, &tv) == -1) +! { +! return -1; +! } +! +! if (di == NULL) +! { +! di = dictitem_alloc(key); +! if (di == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! di->di_tv.v_lock = 0; +! +! if (dict_add(d, di) == FAIL) +! { +! vim_free(di); +! PyErr_SetVim(_("failed to add key to dictionary")); +! return -1; +! } +! } +! else +! clear_tv(&di->di_tv); +! +! DICTKEY_UNREF +! +! copy_tv(&tv, &di->di_tv); +! return 0; +! } +! +! static PyObject * +! DictionaryListKeys(PyObject *self) +! { +! dict_T *dict = ((DictionaryObject *)(self))->dict; +! long_u todo = dict->dv_hashtab.ht_used; +! Py_ssize_t i = 0; +! PyObject *r; +! hashitem_T *hi; +! +! r = PyList_New(todo); +! for (hi = dict->dv_hashtab.ht_array; todo > 0; ++hi) +! { +! if (!HASHITEM_EMPTY(hi)) +! { +! PyList_SetItem(r, i, PyBytes_FromString((char *)(hi->hi_key))); +! --todo; +! ++i; +! } +! } +! return r; +! } +! +! static struct PyMethodDef DictionaryMethods[] = { +! {"keys", (PyCFunction)DictionaryListKeys, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL } +! }; +! +! static PyTypeObject ListType; +! +! typedef struct +! { +! PyObject_HEAD +! list_T *list; +! pylinkedlist_T ref; +! } ListObject; +! +! static PyObject * +! ListNew(list_T *list) +! { +! ListObject *self; +! +! self = PyObject_NEW(ListObject, &ListType); +! if (self == NULL) +! return NULL; +! self->list = list; +! ++list->lv_refcount; +! +! pyll_add((PyObject *)(self), &self->ref, &lastlist); +! +! return (PyObject *)(self); +! } +! +! static int +! list_py_concat(list_T *l, PyObject *obj, PyObject *lookupDict) +! { +! Py_ssize_t i; +! Py_ssize_t lsize = PySequence_Size(obj); +! PyObject *litem; +! listitem_T *li; +! +! for(i=0; ili_tv.v_lock = 0; +! +! litem = PySequence_GetItem(obj, i); +! if (litem == NULL) +! return -1; +! if (_ConvertFromPyObject(litem, &li->li_tv, lookupDict) == -1) +! return -1; +! +! list_append(l, li); +! } +! return 0; +! } +! +! static int +! pyseq_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) +! { +! list_T *l; +! +! l = list_alloc(); +! if (l == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! +! tv->v_type = VAR_LIST; +! tv->vval.v_list = l; +! +! if (list_py_concat(l, obj, lookupDict) == -1) +! return -1; +! +! return 0; +! } +! +! static int +! pyiter_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) +! { +! PyObject *iterator = PyObject_GetIter(obj); +! PyObject *item; +! list_T *l; +! listitem_T *li; +! +! l = list_alloc(); +! +! if (l == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! +! tv->vval.v_list = l; +! tv->v_type = VAR_LIST; +! +! +! if (iterator == NULL) +! return -1; +! +! while ((item = PyIter_Next(obj))) +! { +! li = listitem_alloc(); +! if (li == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! li->li_tv.v_lock = 0; +! +! if (_ConvertFromPyObject(item, &li->li_tv, lookupDict) == -1) +! return -1; +! +! list_append(l, li); +! +! Py_DECREF(item); +! } +! +! Py_DECREF(iterator); +! return 0; +! } +! +! static PyInt +! ListLength(PyObject *self) +! { +! return ((PyInt) (((ListObject *) (self))->list->lv_len)); +! } +! +! static PyObject * +! ListItem(PyObject *self, Py_ssize_t index) +! { +! listitem_T *li; +! +! if (index>=ListLength(self)) +! { +! PyErr_SetString(PyExc_IndexError, "list index out of range"); +! return NULL; +! } +! li = list_find(((ListObject *) (self))->list, (long) index); +! if (li == NULL) +! { +! PyErr_SetVim(_("internal error: failed to get vim list item")); +! return NULL; +! } +! return ConvertToPyObject(&li->li_tv); +! } +! +! #define PROC_RANGE \ +! if (last < 0) {\ +! if (last < -size) \ +! last = 0; \ +! else \ +! last += size; \ +! } \ +! if (first < 0) \ +! first = 0; \ +! if (first > size) \ +! first = size; \ +! if (last > size) \ +! last = size; +! +! static PyObject * +! ListSlice(PyObject *self, Py_ssize_t first, Py_ssize_t last) +! { +! PyInt i; +! PyInt size = ListLength(self); +! PyInt n; +! PyObject *list; +! int reversed = 0; +! +! PROC_RANGE +! if (first >= last) +! first = last; +! +! n = last-first; +! list = PyList_New(n); +! if (list == NULL) +! return NULL; +! +! for (i = 0; i < n; ++i) +! { +! PyObject *item = ListItem(self, i); +! if (item == NULL) +! { +! Py_DECREF(list); +! return NULL; +! } +! +! if ((PyList_SetItem(list, ((reversed)?(n-i-1):(i)), item))) +! { +! Py_DECREF(item); +! Py_DECREF(list); +! return NULL; +! } +! } +! +! return list; +! } +! +! static int +! ListAssItem(PyObject *self, Py_ssize_t index, PyObject *obj) +! { +! typval_T tv; +! list_T *l = ((ListObject *) (self))->list; +! listitem_T *li; +! Py_ssize_t length = ListLength(self); +! +! if (l->lv_lock) +! { +! PyErr_SetVim(_("list is locked")); +! return -1; +! } +! if (index>length || (index==length && obj==NULL)) +! { +! PyErr_SetString(PyExc_IndexError, "list index out of range"); +! return -1; +! } +! +! if (obj == NULL) +! { +! li = list_find(l, (long) index); +! list_remove(l, li, li); +! clear_tv(&li->li_tv); +! vim_free(li); +! return 0; +! } +! +! if (ConvertFromPyObject(obj, &tv) == -1) +! return -1; +! +! if (index == length) +! { +! if (list_append_tv(l, &tv) == FAIL) +! { +! PyErr_SetVim(_("Failed to add item to list")); +! return -1; +! } +! } +! else +! { +! li = list_find(l, (long) index); +! clear_tv(&li->li_tv); +! copy_tv(&tv, &li->li_tv); +! } +! return 0; +! } +! +! static int +! ListAssSlice(PyObject *self, Py_ssize_t first, Py_ssize_t last, PyObject *obj) +! { +! PyInt size = ListLength(self); +! Py_ssize_t i; +! Py_ssize_t lsize; +! PyObject *litem; +! listitem_T *li; +! listitem_T *next; +! typval_T v; +! list_T *l = ((ListObject *) (self))->list; +! +! if (l->lv_lock) +! { +! PyErr_SetVim(_("list is locked")); +! return -1; +! } +! +! PROC_RANGE + +! if (first == size) +! li = NULL; +! else +! { +! li = list_find(l, (long) first); +! if (li == NULL) +! { +! PyErr_SetVim(_("internal error: no vim list item")); +! return -1; +! } +! if (last > first) +! { +! i = last - first; +! while (i-- && li != NULL) + { +! next = li->li_next; +! listitem_remove(l, li); +! li = next; + } + } + } +! +! if (obj == NULL) +! return 0; +! +! if (!PyList_Check(obj)) + { +! PyErr_SetString(PyExc_TypeError, _("can only assign lists to slice")); +! return -1; + } + +! lsize = PyList_Size(obj); +! +! for(i=0; ilist; +! PyObject *lookup_dict; + +! if (l->lv_lock) +! { +! PyErr_SetVim(_("list is locked")); + return NULL; ++ } + +! if (!PySequence_Check(obj)) + { +! PyErr_SetString(PyExc_TypeError, _("can only concatenate with lists")); + return NULL; + } + + lookup_dict = PyDict_New(); +! if (list_py_concat(l, obj, lookup_dict) == -1) +! { +! Py_DECREF(lookup_dict); +! return NULL; +! } + Py_DECREF(lookup_dict); + +! Py_INCREF(self); +! return self; + } + +! static struct PyMethodDef ListMethods[] = { +! {"extend", (PyCFunction)ListConcatInPlace, METH_O, ""}, +! { NULL, NULL, 0, NULL } + }; + + typedef struct + { + PyObject_HEAD +! char_u *name; +! } FunctionObject; + +! static PyTypeObject FunctionType; + +! static PyObject * +! FunctionNew(char_u *name) + { +! FunctionObject *self; + +! self = PyObject_NEW(FunctionObject, &FunctionType); +! if (self == NULL) +! return NULL; +! self->name = PyMem_New(char_u, STRLEN(name) + 1); +! if (self->name == NULL) + { +! PyErr_NoMemory(); +! return NULL; + } +! STRCPY(self->name, name); +! func_ref(name); +! return (PyObject *)(self); + } + + static PyObject * +! FunctionCall(PyObject *self, PyObject *argsObject, PyObject *kwargs) + { +! FunctionObject *this = (FunctionObject *)(self); +! char_u *name = this->name; +! typval_T args; +! typval_T selfdicttv; +! typval_T rettv; +! dict_T *selfdict = NULL; +! PyObject *selfdictObject; +! PyObject *result; +! int error; + +! if (ConvertFromPyObject(argsObject, &args) == -1) +! return NULL; +! +! if (kwargs != NULL) + { +! selfdictObject = PyDict_GetItemString(kwargs, "self"); +! if (selfdictObject != NULL) +! { +! if (!PyDict_Check(selfdictObject)) +! { +! PyErr_SetString(PyExc_TypeError, _("'self' argument must be a dictionary")); +! clear_tv(&args); +! return NULL; +! } +! if (ConvertFromPyObject(selfdictObject, &selfdicttv) == -1) +! return NULL; +! selfdict = selfdicttv.vval.v_dict; +! } + } + +! error = func_call(name, &args, selfdict, &rettv); +! if (error != OK) +! { +! result = NULL; +! PyErr_SetVim(_("failed to run function")); +! } +! else +! result = ConvertToPyObject(&rettv); +! +! /* FIXME Check what should really be cleared. */ +! clear_tv(&args); +! clear_tv(&rettv); +! /* +! * if (selfdict!=NULL) +! * clear_tv(selfdicttv); +! */ +! +! return result; + } + +! static struct PyMethodDef FunctionMethods[] = { +! {"__call__", (PyCFunction)FunctionCall, METH_VARARGS|METH_KEYWORDS, ""}, +! { NULL, NULL, 0, NULL } +! }; + + #define INVALID_WINDOW_VALUE ((win_T *)(-1)) + +*************** +*** 1567,1569 **** +--- 2383,2638 ---- + { NULL, NULL, 0, NULL } + }; + ++ static void ++ set_ref_in_py(const int copyID) ++ { ++ pylinkedlist_T *cur; ++ dict_T *dd; ++ list_T *ll; ++ ++ if (lastdict != NULL) ++ for(cur = lastdict ; cur != NULL ; cur = cur->pll_prev) ++ { ++ dd = ((DictionaryObject *) (cur->pll_obj))->dict; ++ if (dd->dv_copyID != copyID) ++ { ++ dd->dv_copyID = copyID; ++ set_ref_in_ht(&dd->dv_hashtab, copyID); ++ } ++ } ++ ++ if (lastlist != NULL) ++ for(cur = lastlist ; cur != NULL ; cur = cur->pll_prev) ++ { ++ ll = ((ListObject *) (cur->pll_obj))->list; ++ if (ll->lv_copyID != copyID) ++ { ++ ll->lv_copyID = copyID; ++ set_ref_in_list(ll, copyID); ++ } ++ } ++ } ++ ++ static int ++ set_string_copy(char_u *str, typval_T *tv) ++ { ++ tv->vval.v_string = vim_strsave(str); ++ if (tv->vval.v_string == NULL) ++ { ++ PyErr_NoMemory(); ++ return -1; ++ } ++ return 0; ++ } ++ ++ #ifdef FEAT_EVAL ++ typedef int (*pytotvfunc)(PyObject *, typval_T *, PyObject *); ++ ++ static int ++ convert_dl(PyObject *obj, typval_T *tv, ++ pytotvfunc py_to_tv, PyObject *lookupDict) ++ { ++ PyObject *capsule; ++ char hexBuf[sizeof(void *) * 2 + 3]; ++ ++ sprintf(hexBuf, "%p", obj); ++ ++ capsule = PyDict_GetItemString(lookupDict, hexBuf); ++ if (capsule == NULL) ++ { ++ capsule = PyCapsule_New(tv, NULL, NULL); ++ PyDict_SetItemString(lookupDict, hexBuf, capsule); ++ Py_DECREF(capsule); ++ if (py_to_tv(obj, tv, lookupDict) == -1) ++ { ++ tv->v_type = VAR_UNKNOWN; ++ return -1; ++ } ++ /* As we are not using copy_tv which increments reference count we must ++ * do it ourself. */ ++ switch(tv->v_type) ++ { ++ case VAR_DICT: ++tv->vval.v_dict->dv_refcount; break; ++ case VAR_LIST: ++tv->vval.v_list->lv_refcount; break; ++ } ++ } ++ else ++ { ++ typval_T *v = PyCapsule_GetPointer(capsule, NULL); ++ copy_tv(v, tv); ++ } ++ return 0; ++ } ++ ++ static int ++ ConvertFromPyObject(PyObject *obj, typval_T *tv) ++ { ++ PyObject *lookup_dict; ++ int r; ++ ++ lookup_dict = PyDict_New(); ++ r = _ConvertFromPyObject(obj, tv, lookup_dict); ++ Py_DECREF(lookup_dict); ++ return r; ++ } ++ ++ static int ++ _ConvertFromPyObject(PyObject *obj, typval_T *tv, PyObject *lookupDict) ++ { ++ if (obj->ob_type == &DictionaryType) ++ { ++ tv->v_type = VAR_DICT; ++ tv->vval.v_dict = (((DictionaryObject *)(obj))->dict); ++ ++tv->vval.v_dict->dv_refcount; ++ } ++ else if (obj->ob_type == &ListType) ++ { ++ tv->v_type = VAR_LIST; ++ tv->vval.v_list = (((ListObject *)(obj))->list); ++ ++tv->vval.v_list->lv_refcount; ++ } ++ else if (obj->ob_type == &FunctionType) ++ { ++ if (set_string_copy(((FunctionObject *) (obj))->name, tv) == -1) ++ return -1; ++ ++ tv->v_type = VAR_FUNC; ++ func_ref(tv->vval.v_string); ++ } ++ #if PY_MAJOR_VERSION >= 3 ++ else if (PyBytes_Check(obj)) ++ { ++ char_u *result = (char_u *) PyBytes_AsString(obj); ++ ++ if (result == NULL) ++ return -1; ++ ++ if (set_string_copy(result, tv) == -1) ++ return -1; ++ ++ tv->v_type = VAR_STRING; ++ } ++ else if (PyUnicode_Check(obj)) ++ { ++ PyObject *bytes; ++ char_u *result; ++ ++ bytes = PyString_AsBytes(obj); ++ if (bytes == NULL) ++ return -1; ++ ++ result = (char_u *) PyBytes_AsString(bytes); ++ if (result == NULL) ++ return -1; ++ ++ if (set_string_copy(result, tv) == -1) ++ { ++ Py_XDECREF(bytes); ++ return -1; ++ } ++ Py_XDECREF(bytes); ++ ++ tv->v_type = VAR_STRING; ++ } ++ #else ++ else if (PyUnicode_Check(obj)) ++ { ++ PyObject *bytes; ++ char_u *result; ++ ++ bytes = PyUnicode_AsEncodedString(obj, (char *)ENC_OPT, NULL); ++ if (bytes == NULL) ++ return -1; ++ ++ result=(char_u *) PyString_AsString(bytes); ++ if (result == NULL) ++ return -1; ++ ++ if (set_string_copy(result, tv) == -1) ++ { ++ Py_XDECREF(bytes); ++ return -1; ++ } ++ Py_XDECREF(bytes); ++ ++ tv->v_type = VAR_STRING; ++ } ++ else if (PyString_Check(obj)) ++ { ++ char_u *result = (char_u *) PyString_AsString(obj); ++ ++ if (result == NULL) ++ return -1; ++ ++ if (set_string_copy(result, tv) == -1) ++ return -1; ++ ++ tv->v_type = VAR_STRING; ++ } ++ else if (PyInt_Check(obj)) ++ { ++ tv->v_type = VAR_NUMBER; ++ tv->vval.v_number = (varnumber_T) PyInt_AsLong(obj); ++ } ++ #endif ++ else if (PyLong_Check(obj)) ++ { ++ tv->v_type = VAR_NUMBER; ++ tv->vval.v_number = (varnumber_T) PyLong_AsLong(obj); ++ } ++ else if (PyDict_Check(obj)) ++ return convert_dl(obj, tv, pydict_to_tv, lookupDict); ++ #ifdef FEAT_FLOAT ++ else if (PyFloat_Check(obj)) ++ { ++ tv->v_type = VAR_FLOAT; ++ tv->vval.v_float = (float_T) PyFloat_AsDouble(obj); ++ } ++ #endif ++ else if (PyIter_Check(obj)) ++ return convert_dl(obj, tv, pyiter_to_tv, lookupDict); ++ else if (PySequence_Check(obj)) ++ return convert_dl(obj, tv, pyseq_to_tv, lookupDict); ++ else if (PyMapping_Check(obj)) ++ return convert_dl(obj, tv, pymap_to_tv, lookupDict); ++ else ++ { ++ PyErr_SetString(PyExc_TypeError, _("unable to convert to vim structure")); ++ return -1; ++ } ++ return 0; ++ } ++ ++ static PyObject * ++ ConvertToPyObject(typval_T *tv) ++ { ++ if (tv == NULL) ++ { ++ PyErr_SetVim(_("NULL reference passed")); ++ return NULL; ++ } ++ switch (tv->v_type) ++ { ++ case VAR_STRING: ++ return PyBytes_FromString((char *) tv->vval.v_string); ++ case VAR_NUMBER: ++ return PyLong_FromLong((long) tv->vval.v_number); ++ #ifdef FEAT_FLOAT ++ case VAR_FLOAT: ++ return PyFloat_FromDouble((double) tv->vval.v_float); ++ #endif ++ case VAR_LIST: ++ return ListNew(tv->vval.v_list); ++ case VAR_DICT: ++ return DictionaryNew(tv->vval.v_dict); ++ case VAR_FUNC: ++ return FunctionNew(tv->vval.v_string); ++ case VAR_UNKNOWN: ++ Py_INCREF(Py_None); ++ return Py_None; ++ default: ++ PyErr_SetVim(_("internal error: invalid value type")); ++ return NULL; ++ } ++ } ++ #endif +*** ../vim-7.3.568/src/if_python.c 2011-08-28 16:00:14.000000000 +0200 +--- src/if_python.c 2012-06-29 12:47:48.000000000 +0200 +*************** +*** 1,4 **** +! /* vi:set ts=8 sts=4 sw=4: + * + * VIM - Vi IMproved by Bram Moolenaar + * +--- 1,4 ---- +! /* vi:set ts=8 sts=4 sw=4 noet: + * + * VIM - Vi IMproved by Bram Moolenaar + * +*************** +*** 56,61 **** +--- 56,63 ---- + + static void init_structs(void); + ++ #define PyBytes_FromString PyString_FromString ++ + /* No-op conversion functions, use with care! */ + #define PyString_AsBytes(obj) (obj) + #define PyString_FreeBytes(obj) +*************** +*** 122,132 **** +--- 124,136 ---- + /* This makes if_python.c compile without warnings against Python 2.5 + * on Win32 and Win64. */ + # undef PyRun_SimpleString ++ # undef PyRun_String + # undef PyArg_Parse + # undef PyArg_ParseTuple + # undef Py_BuildValue + # undef Py_InitModule4 + # undef Py_InitModule4_64 ++ # undef PyObject_CallMethod + + /* + * Wrapper defines +*************** +*** 134,139 **** +--- 138,144 ---- + # define PyArg_Parse dll_PyArg_Parse + # define PyArg_ParseTuple dll_PyArg_ParseTuple + # define PyMem_Free dll_PyMem_Free ++ # define PyMem_Malloc dll_PyMem_Malloc + # define PyDict_SetItemString dll_PyDict_SetItemString + # define PyErr_BadArgument dll_PyErr_BadArgument + # define PyErr_Clear dll_PyErr_Clear +*************** +*** 150,172 **** +--- 155,202 ---- + # endif + # define PyInt_AsLong dll_PyInt_AsLong + # define PyInt_FromLong dll_PyInt_FromLong ++ # define PyLong_AsLong dll_PyLong_AsLong ++ # define PyLong_FromLong dll_PyLong_FromLong + # define PyInt_Type (*dll_PyInt_Type) ++ # define PyLong_Type (*dll_PyLong_Type) + # define PyList_GetItem dll_PyList_GetItem + # define PyList_Append dll_PyList_Append + # define PyList_New dll_PyList_New + # define PyList_SetItem dll_PyList_SetItem + # define PyList_Size dll_PyList_Size + # define PyList_Type (*dll_PyList_Type) ++ # define PySequence_Check dll_PySequence_Check ++ # define PySequence_Size dll_PySequence_Size ++ # define PySequence_GetItem dll_PySequence_GetItem ++ # define PyTuple_Size dll_PyTuple_Size ++ # define PyTuple_GetItem dll_PyTuple_GetItem ++ # define PyTuple_Type (*dll_PyTuple_Type) + # define PyImport_ImportModule dll_PyImport_ImportModule + # define PyDict_New dll_PyDict_New + # define PyDict_GetItemString dll_PyDict_GetItemString ++ # define PyDict_Next dll_PyDict_Next ++ # ifdef PyMapping_Items ++ # define PY_NO_MAPPING_ITEMS ++ # else ++ # define PyMapping_Items dll_PyMapping_Items ++ # endif ++ # define PyObject_CallMethod dll_PyObject_CallMethod ++ # define PyMapping_Check dll_PyMapping_Check ++ # define PyIter_Next dll_PyIter_Next + # define PyModule_GetDict dll_PyModule_GetDict + # define PyRun_SimpleString dll_PyRun_SimpleString ++ # define PyRun_String dll_PyRun_String + # define PyString_AsString dll_PyString_AsString + # define PyString_FromString dll_PyString_FromString + # define PyString_FromStringAndSize dll_PyString_FromStringAndSize + # define PyString_Size dll_PyString_Size + # define PyString_Type (*dll_PyString_Type) ++ # define PyUnicode_Type (*dll_PyUnicode_Type) ++ # define PyUnicodeUCS4_AsEncodedString (*dll_PyUnicodeUCS4_AsEncodedString) ++ # define PyFloat_AsDouble dll_PyFloat_AsDouble ++ # define PyFloat_FromDouble dll_PyFloat_FromDouble ++ # define PyFloat_Type (*dll_PyFloat_Type) ++ # define PyImport_AddModule (*dll_PyImport_AddModule) + # define PySys_SetObject dll_PySys_SetObject + # define PySys_SetArgv dll_PySys_SetArgv + # define PyType_Type (*dll_PyType_Type) +*************** +*** 179,186 **** +--- 209,218 ---- + # define Py_Finalize dll_Py_Finalize + # define Py_IsInitialized dll_Py_IsInitialized + # define _PyObject_New dll__PyObject_New ++ # define _PyObject_NextNotImplemented (*dll__PyObject_NextNotImplemented) + # define _Py_NoneStruct (*dll__Py_NoneStruct) + # define PyObject_Init dll__PyObject_Init ++ # define PyObject_GetIter dll_PyObject_GetIter + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + # define PyType_IsSubtype dll_PyType_IsSubtype + # endif +*************** +*** 188,193 **** +--- 220,227 ---- + # define PyObject_Malloc dll_PyObject_Malloc + # define PyObject_Free dll_PyObject_Free + # endif ++ # define PyCapsule_New dll_PyCapsule_New ++ # define PyCapsule_GetPointer dll_PyCapsule_GetPointer + + /* + * Pointers for dynamic link +*************** +*** 195,200 **** +--- 229,235 ---- + static int(*dll_PyArg_Parse)(PyObject *, char *, ...); + static int(*dll_PyArg_ParseTuple)(PyObject *, char *, ...); + static int(*dll_PyMem_Free)(void *); ++ static void* (*dll_PyMem_Malloc)(size_t); + static int(*dll_PyDict_SetItemString)(PyObject *dp, char *key, PyObject *item); + static int(*dll_PyErr_BadArgument)(void); + static void(*dll_PyErr_Clear)(void); +*************** +*** 208,233 **** + # ifdef PY_CAN_RECURSE + static PyGILState_STATE (*dll_PyGILState_Ensure)(void); + static void (*dll_PyGILState_Release)(PyGILState_STATE); +! #endif + static long(*dll_PyInt_AsLong)(PyObject *); + static PyObject*(*dll_PyInt_FromLong)(long); + static PyTypeObject* dll_PyInt_Type; + static PyObject*(*dll_PyList_GetItem)(PyObject *, PyInt); + static PyObject*(*dll_PyList_Append)(PyObject *, PyObject *); + static PyObject*(*dll_PyList_New)(PyInt size); + static int(*dll_PyList_SetItem)(PyObject *, PyInt, PyObject *); + static PyInt(*dll_PyList_Size)(PyObject *); + static PyTypeObject* dll_PyList_Type; + static PyObject*(*dll_PyImport_ImportModule)(const char *); + static PyObject*(*dll_PyDict_New)(void); + static PyObject*(*dll_PyDict_GetItemString)(PyObject *, const char *); + static PyObject*(*dll_PyModule_GetDict)(PyObject *); + static int(*dll_PyRun_SimpleString)(char *); + static char*(*dll_PyString_AsString)(PyObject *); + static PyObject*(*dll_PyString_FromString)(const char *); + static PyObject*(*dll_PyString_FromStringAndSize)(const char *, PyInt); + static PyInt(*dll_PyString_Size)(PyObject *); + static PyTypeObject* dll_PyString_Type; + static int(*dll_PySys_SetObject)(char *, PyObject *); + static int(*dll_PySys_SetArgv)(int, char **); + static PyTypeObject* dll_PyType_Type; +--- 243,290 ---- + # ifdef PY_CAN_RECURSE + static PyGILState_STATE (*dll_PyGILState_Ensure)(void); + static void (*dll_PyGILState_Release)(PyGILState_STATE); +! # endif + static long(*dll_PyInt_AsLong)(PyObject *); + static PyObject*(*dll_PyInt_FromLong)(long); ++ static long(*dll_PyLong_AsLong)(PyObject *); ++ static PyObject*(*dll_PyLong_FromLong)(long); + static PyTypeObject* dll_PyInt_Type; ++ static PyTypeObject* dll_PyLong_Type; + static PyObject*(*dll_PyList_GetItem)(PyObject *, PyInt); + static PyObject*(*dll_PyList_Append)(PyObject *, PyObject *); + static PyObject*(*dll_PyList_New)(PyInt size); + static int(*dll_PyList_SetItem)(PyObject *, PyInt, PyObject *); + static PyInt(*dll_PyList_Size)(PyObject *); + static PyTypeObject* dll_PyList_Type; ++ static int (*dll_PySequence_Check)(PyObject *); ++ static PyInt(*dll_PySequence_Size)(PyObject *); ++ static PyObject*(*dll_PySequence_GetItem)(PyObject *, PyInt); ++ static PyInt(*dll_PyTuple_Size)(PyObject *); ++ static PyObject*(*dll_PyTuple_GetItem)(PyObject *, PyInt); ++ static PyTypeObject* dll_PyTuple_Type; + static PyObject*(*dll_PyImport_ImportModule)(const char *); + static PyObject*(*dll_PyDict_New)(void); + static PyObject*(*dll_PyDict_GetItemString)(PyObject *, const char *); ++ static int (*dll_PyDict_Next)(PyObject *, Py_ssize_t *, PyObject **, PyObject **); ++ # ifndef PY_NO_MAPPING_ITEMS ++ static PyObject* (*dll_PyMapping_Items)(PyObject *); ++ # endif ++ static PyObject* (*dll_PyObject_CallMethod)(PyObject *, char *, PyObject *); ++ static int (*dll_PyMapping_Check)(PyObject *); ++ static PyObject* (*dll_PyIter_Next)(PyObject *); + static PyObject*(*dll_PyModule_GetDict)(PyObject *); + static int(*dll_PyRun_SimpleString)(char *); ++ static PyObject *(*dll_PyRun_String)(char *, int, PyObject *, PyObject *); + static char*(*dll_PyString_AsString)(PyObject *); + static PyObject*(*dll_PyString_FromString)(const char *); + static PyObject*(*dll_PyString_FromStringAndSize)(const char *, PyInt); + static PyInt(*dll_PyString_Size)(PyObject *); + static PyTypeObject* dll_PyString_Type; ++ static PyTypeObject* dll_PyUnicode_Type; ++ static PyObject *(*PyUnicodeUCS4_AsEncodedString)(PyObject *, char *, char *); ++ static double(*dll_PyFloat_AsDouble)(PyObject *); ++ static PyObject*(*dll_PyFloat_FromDouble)(double); ++ static PyTypeObject* dll_PyFloat_Type; + static int(*dll_PySys_SetObject)(char *, PyObject *); + static int(*dll_PySys_SetArgv)(int, char **); + static PyTypeObject* dll_PyType_Type; +*************** +*** 235,246 **** +--- 292,306 ---- + static PyObject*(*dll_Py_BuildValue)(char *, ...); + static PyObject*(*dll_Py_FindMethod)(struct PyMethodDef[], PyObject *, char *); + static PyObject*(*dll_Py_InitModule4)(char *, struct PyMethodDef *, char *, PyObject *, int); ++ static PyObject*(*dll_PyImport_AddModule)(char *); + static void(*dll_Py_SetPythonHome)(char *home); + static void(*dll_Py_Initialize)(void); + static void(*dll_Py_Finalize)(void); + static int(*dll_Py_IsInitialized)(void); + static PyObject*(*dll__PyObject_New)(PyTypeObject *, PyObject *); + static PyObject*(*dll__PyObject_Init)(PyObject *, PyTypeObject *); ++ static PyObject* (*dll_PyObject_GetIter)(PyObject *); ++ static iternextfunc dll__PyObject_NextNotImplemented; + static PyObject* dll__Py_NoneStruct; + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + static int (*dll_PyType_IsSubtype)(PyTypeObject *, PyTypeObject *); +*************** +*** 249,254 **** +--- 309,316 ---- + static void* (*dll_PyObject_Malloc)(size_t); + static void (*dll_PyObject_Free)(void*); + # endif ++ static PyObject* (*dll_PyCapsule_New)(void *, char *, PyCapsule_Destructor); ++ static void* (*dll_PyCapsule_GetPointer)(PyObject *, char *); + + static HINSTANCE hinstPython = 0; /* Instance of python.dll */ + +*************** +*** 278,283 **** +--- 340,346 ---- + {"PyArg_Parse", (PYTHON_PROC*)&dll_PyArg_Parse}, + {"PyArg_ParseTuple", (PYTHON_PROC*)&dll_PyArg_ParseTuple}, + {"PyMem_Free", (PYTHON_PROC*)&dll_PyMem_Free}, ++ {"PyMem_Malloc", (PYTHON_PROC*)&dll_PyMem_Malloc}, + {"PyDict_SetItemString", (PYTHON_PROC*)&dll_PyDict_SetItemString}, + {"PyErr_BadArgument", (PYTHON_PROC*)&dll_PyErr_BadArgument}, + {"PyErr_Clear", (PYTHON_PROC*)&dll_PyErr_Clear}, +*************** +*** 294,316 **** +--- 357,402 ---- + # endif + {"PyInt_AsLong", (PYTHON_PROC*)&dll_PyInt_AsLong}, + {"PyInt_FromLong", (PYTHON_PROC*)&dll_PyInt_FromLong}, ++ {"PyLong_AsLong", (PYTHON_PROC*)&dll_PyLong_AsLong}, ++ {"PyLong_FromLong", (PYTHON_PROC*)&dll_PyLong_FromLong}, + {"PyInt_Type", (PYTHON_PROC*)&dll_PyInt_Type}, ++ {"PyLong_Type", (PYTHON_PROC*)&dll_PyLong_Type}, + {"PyList_GetItem", (PYTHON_PROC*)&dll_PyList_GetItem}, + {"PyList_Append", (PYTHON_PROC*)&dll_PyList_Append}, + {"PyList_New", (PYTHON_PROC*)&dll_PyList_New}, + {"PyList_SetItem", (PYTHON_PROC*)&dll_PyList_SetItem}, + {"PyList_Size", (PYTHON_PROC*)&dll_PyList_Size}, + {"PyList_Type", (PYTHON_PROC*)&dll_PyList_Type}, ++ {"PySequence_GetItem", (PYTHON_PROC*)&dll_PySequence_GetItem}, ++ {"PySequence_Size", (PYTHON_PROC*)&dll_PySequence_Size}, ++ {"PySequence_Check", (PYTHON_PROC*)&dll_PySequence_Check}, ++ {"PyTuple_GetItem", (PYTHON_PROC*)&dll_PyTuple_GetItem}, ++ {"PyTuple_Size", (PYTHON_PROC*)&dll_PyTuple_Size}, ++ {"PyTuple_Type", (PYTHON_PROC*)&dll_PyTuple_Type}, + {"PyImport_ImportModule", (PYTHON_PROC*)&dll_PyImport_ImportModule}, + {"PyDict_GetItemString", (PYTHON_PROC*)&dll_PyDict_GetItemString}, ++ {"PyDict_Next", (PYTHON_PROC*)&dll_PyDict_Next}, + {"PyDict_New", (PYTHON_PROC*)&dll_PyDict_New}, ++ # ifndef PY_NO_MAPPING_ITEMS ++ {"PyMapping_Items", (PYTHON_PROC*)&dll_PyMapping_Items}, ++ # endif ++ {"PyObject_CallMethod", (PYTHON_PROC*)&dll_PyObject_CallMethod}, ++ {"PyMapping_Check", (PYTHON_PROC*)&dll_PyMapping_Check}, ++ {"PyIter_Next", (PYTHON_PROC*)&dll_PyIter_Next}, + {"PyModule_GetDict", (PYTHON_PROC*)&dll_PyModule_GetDict}, + {"PyRun_SimpleString", (PYTHON_PROC*)&dll_PyRun_SimpleString}, ++ {"PyRun_String", (PYTHON_PROC*)&dll_PyRun_String}, + {"PyString_AsString", (PYTHON_PROC*)&dll_PyString_AsString}, + {"PyString_FromString", (PYTHON_PROC*)&dll_PyString_FromString}, + {"PyString_FromStringAndSize", (PYTHON_PROC*)&dll_PyString_FromStringAndSize}, + {"PyString_Size", (PYTHON_PROC*)&dll_PyString_Size}, + {"PyString_Type", (PYTHON_PROC*)&dll_PyString_Type}, ++ {"PyUnicode_Type", (PYTHON_PROC*)&dll_PyUnicode_Type}, ++ {"PyUnicodeUCS4_AsEncodedString", (PYTHON_PROC*)&dll_PyUnicodeUCS4_AsEncodedString}, ++ {"PyFloat_Type", (PYTHON_PROC*)&dll_PyFloat_Type}, ++ {"PyFloat_AsDouble", (PYTHON_PROC*)&dll_PyFloat_AsDouble}, ++ {"PyFloat_FromDouble", (PYTHON_PROC*)&dll_PyFloat_FromDouble}, ++ {"PyImport_AddModule", (PYTHON_PROC*)&dll_PyImport_AddModule}, + {"PySys_SetObject", (PYTHON_PROC*)&dll_PySys_SetObject}, + {"PySys_SetArgv", (PYTHON_PROC*)&dll_PySys_SetArgv}, + {"PyType_Type", (PYTHON_PROC*)&dll_PyType_Type}, +*************** +*** 328,333 **** +--- 414,421 ---- + {"Py_IsInitialized", (PYTHON_PROC*)&dll_Py_IsInitialized}, + {"_PyObject_New", (PYTHON_PROC*)&dll__PyObject_New}, + {"PyObject_Init", (PYTHON_PROC*)&dll__PyObject_Init}, ++ {"PyObject_GetIter", (PYTHON_PROC*)&dll_PyObject_GetIter}, ++ {"_PyObject_NextNotImplemented", (PYTHON_PROC*)&dll__PyObject_NextNotImplemented}, + {"_Py_NoneStruct", (PYTHON_PROC*)&dll__Py_NoneStruct}, + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + {"PyType_IsSubtype", (PYTHON_PROC*)&dll_PyType_IsSubtype}, +*************** +*** 336,341 **** +--- 424,431 ---- + {"PyObject_Malloc", (PYTHON_PROC*)&dll_PyObject_Malloc}, + {"PyObject_Free", (PYTHON_PROC*)&dll_PyObject_Free}, + # endif ++ {"PyCapsule_New", (PYTHON_PROC*)&dll_PyCapsule_New}, ++ {"PyCapsule_GetPointer", (PYTHON_PROC*)&dll_PyCapsule_GetPointer}, + {"", NULL}, + }; + +*************** +*** 434,443 **** +--- 524,548 ---- + + static PyObject *BufferNew (buf_T *); + static PyObject *WindowNew(win_T *); ++ static PyObject *DictionaryNew(dict_T *); + static PyObject *LineToString(const char *); + + static PyTypeObject RangeType; + ++ static int initialised = 0; ++ #define PYINITIALISED initialised ++ ++ /* Add conversion from PyInt? */ ++ #define DICTKEY_GET(err) \ ++ if (!PyString_Check(keyObject)) \ ++ { \ ++ PyErr_SetString(PyExc_TypeError, _("only string keys are allowed")); \ ++ return err; \ ++ } \ ++ key = (char_u *) PyString_AsString(keyObject); ++ #define DICTKEY_UNREF ++ #define DICTKEY_DECL ++ + /* + * Include the code shared with if_python3.c + */ +*************** +*** 451,456 **** +--- 556,563 ---- + static PyInt RangeStart; + static PyInt RangeEnd; + ++ static PyObject *globals; ++ + static void PythonIO_Flush(void); + static int PythonIO_Init(void); + static int PythonMod_Init(void); +*************** +*** 466,473 **** + * 1. Python interpreter main program. + */ + +- static int initialised = 0; +- + #if PYTHON_API_VERSION < 1007 /* Python 1.4 */ + typedef PyObject PyThreadState; + #endif +--- 573,578 ---- +*************** +*** 581,586 **** +--- 686,693 ---- + if (PythonMod_Init()) + goto fail; + ++ globals = PyModule_GetDict(PyImport_AddModule("__main__")); ++ + /* Remove the element from sys.path that was added because of our + * argv[0] value in PythonMod_Init(). Previously we used an empty + * string, but dependinding on the OS we then get an empty entry or +*************** +*** 609,615 **** + * External interface + */ + static void +! DoPythonCommand(exarg_T *eap, const char *cmd) + { + #ifndef PY_CAN_RECURSE + static int recursive = 0; +--- 716,722 ---- + * External interface + */ + static void +! DoPythonCommand(exarg_T *eap, const char *cmd, typval_T *rettv) + { + #ifndef PY_CAN_RECURSE + static int recursive = 0; +*************** +*** 639,646 **** + if (Python_Init()) + goto theend; + +! RangeStart = eap->line1; +! RangeEnd = eap->line2; + Python_Release_Vim(); /* leave vim */ + + #if defined(HAVE_LOCALE_H) || defined(X_LOCALE) +--- 746,761 ---- + if (Python_Init()) + goto theend; + +! if (rettv == NULL) +! { +! RangeStart = eap->line1; +! RangeEnd = eap->line2; +! } +! else +! { +! RangeStart = (PyInt) curwin->w_cursor.lnum; +! RangeEnd = RangeStart; +! } + Python_Release_Vim(); /* leave vim */ + + #if defined(HAVE_LOCALE_H) || defined(X_LOCALE) +*************** +*** 658,664 **** + + Python_RestoreThread(); /* enter python */ + +! PyRun_SimpleString((char *)(cmd)); + + Python_SaveThread(); /* leave python */ + +--- 773,795 ---- + + Python_RestoreThread(); /* enter python */ + +! if (rettv == NULL) +! PyRun_SimpleString((char *)(cmd)); +! else +! { +! PyObject *r; +! +! r = PyRun_String((char *)(cmd), Py_eval_input, globals, globals); +! if (r == NULL) +! EMSG(_("E858: Eval did not return a valid python object")); +! else +! { +! if (ConvertFromPyObject(r, rettv) == -1) +! EMSG(_("E859: Failed to convert returned python object to vim value")); +! Py_DECREF(r); +! } +! PyErr_Clear(); +! } + + Python_SaveThread(); /* leave python */ + +*************** +*** 680,686 **** + #ifndef PY_CAN_RECURSE + --recursive; + #endif +! return; /* keeps lint happy */ + } + + /* +--- 811,817 ---- + #ifndef PY_CAN_RECURSE + --recursive; + #endif +! return; + } + + /* +*************** +*** 695,703 **** + if (!eap->skip) + { + if (script == NULL) +! DoPythonCommand(eap, (char *)eap->arg); + else +! DoPythonCommand(eap, (char *)script); + } + vim_free(script); + } +--- 826,834 ---- + if (!eap->skip) + { + if (script == NULL) +! DoPythonCommand(eap, (char *)eap->arg, NULL); + else +! DoPythonCommand(eap, (char *)script, NULL); + } + vim_free(script); + } +*************** +*** 743,749 **** + *p++ = '\0'; + + /* Execute the file */ +! DoPythonCommand(eap, buffer); + } + + /****************************************************** +--- 874,880 ---- + *p++ = '\0'; + + /* Execute the file */ +! DoPythonCommand(eap, buffer, NULL); + } + + /****************************************************** +*************** +*** 765,778 **** + static int + OutputSetattr(PyObject *self, char *name, PyObject *val) + { +! if (val == NULL) { + PyErr_SetString(PyExc_AttributeError, _("can't delete OutputObject attributes")); + return -1; + } + + if (strcmp(name, "softspace") == 0) + { +! if (!PyInt_Check(val)) { + PyErr_SetString(PyExc_TypeError, _("softspace must be an integer")); + return -1; + } +--- 896,911 ---- + static int + OutputSetattr(PyObject *self, char *name, PyObject *val) + { +! if (val == NULL) +! { + PyErr_SetString(PyExc_AttributeError, _("can't delete OutputObject attributes")); + return -1; + } + + if (strcmp(name, "softspace") == 0) + { +! if (!PyInt_Check(val)) +! { + PyErr_SetString(PyExc_TypeError, _("softspace must be an integer")); + return -1; + } +*************** +*** 800,805 **** +--- 933,941 ---- + * 3. Implementation of the Vim module for Python + */ + ++ static PyObject *ConvertToPyObject(typval_T *); ++ static int ConvertFromPyObject(PyObject *, typval_T *); ++ + /* Window type - Implementation functions + * -------------------------------------- + */ +*************** +*** 1441,1446 **** +--- 1577,1748 ---- + return result; + } + ++ static void DictionaryDestructor(PyObject *); ++ static PyObject *DictionaryGetattr(PyObject *, char*); ++ ++ static PyMappingMethods DictionaryAsMapping = { ++ (PyInquiry) DictionaryLength, ++ (binaryfunc) DictionaryItem, ++ (objobjargproc) DictionaryAssItem, ++ }; ++ ++ static PyTypeObject DictionaryType = { ++ PyObject_HEAD_INIT(0) ++ 0, ++ "vimdictionary", ++ sizeof(DictionaryObject), ++ 0, ++ ++ (destructor) DictionaryDestructor, ++ (printfunc) 0, ++ (getattrfunc) DictionaryGetattr, ++ (setattrfunc) 0, ++ (cmpfunc) 0, ++ (reprfunc) 0, ++ ++ 0, /* as number */ ++ 0, /* as sequence */ ++ &DictionaryAsMapping, /* as mapping */ ++ ++ (hashfunc) 0, ++ (ternaryfunc) 0, ++ (reprfunc) 0, ++ }; ++ ++ static void ++ DictionaryDestructor(PyObject *self) ++ { ++ DictionaryObject *this = ((DictionaryObject *) (self)); ++ ++ pyll_remove(&this->ref, &lastdict); ++ dict_unref(this->dict); ++ ++ Py_DECREF(self); ++ } ++ ++ static PyObject * ++ DictionaryGetattr(PyObject *self, char *name) ++ { ++ return Py_FindMethod(DictionaryMethods, self, name); ++ } ++ ++ static void ListDestructor(PyObject *); ++ static PyObject *ListGetattr(PyObject *, char *); ++ ++ static PySequenceMethods ListAsSeq = { ++ (PyInquiry) ListLength, ++ (binaryfunc) 0, ++ (PyIntArgFunc) 0, ++ (PyIntArgFunc) ListItem, ++ (PyIntIntArgFunc) ListSlice, ++ (PyIntObjArgProc) ListAssItem, ++ (PyIntIntObjArgProc) ListAssSlice, ++ (objobjproc) 0, ++ #if PY_MAJOR_VERSION >= 2 ++ (binaryfunc) ListConcatInPlace, ++ 0, ++ #endif ++ }; ++ ++ static PyTypeObject ListType = { ++ PyObject_HEAD_INIT(0) ++ 0, ++ "vimlist", ++ sizeof(ListObject), ++ 0, ++ ++ (destructor) ListDestructor, ++ (printfunc) 0, ++ (getattrfunc) ListGetattr, ++ (setattrfunc) 0, ++ (cmpfunc) 0, ++ (reprfunc) 0, ++ ++ 0, /* as number */ ++ &ListAsSeq, /* as sequence */ ++ 0, /* as mapping */ ++ ++ (hashfunc) 0, ++ (ternaryfunc) 0, ++ (reprfunc) 0, ++ }; ++ ++ static void ++ ListDestructor(PyObject *self) ++ { ++ ListObject *this = ((ListObject *) (self)); ++ ++ pyll_remove(&this->ref, &lastlist); ++ list_unref(this->list); ++ ++ Py_DECREF(self); ++ } ++ ++ static PyObject * ++ ListGetattr(PyObject *self, char *name) ++ { ++ return Py_FindMethod(ListMethods, self, name); ++ } ++ ++ static void FunctionDestructor(PyObject *); ++ static PyObject *FunctionGetattr(PyObject *, char *); ++ ++ static PyTypeObject FunctionType = { ++ PyObject_HEAD_INIT(0) ++ 0, ++ "vimfunction", ++ sizeof(FunctionObject), ++ 0, ++ ++ (destructor) FunctionDestructor, ++ (printfunc) 0, ++ (getattrfunc) FunctionGetattr, ++ (setattrfunc) 0, ++ (cmpfunc) 0, ++ (reprfunc) 0, ++ ++ 0, /* as number */ ++ 0, /* as sequence */ ++ 0, /* as mapping */ ++ ++ (hashfunc) 0, ++ (ternaryfunc) FunctionCall, ++ (reprfunc) 0, ++ }; ++ ++ static void ++ FunctionDestructor(PyObject *self) ++ { ++ FunctionObject *this = (FunctionObject *) (self); ++ ++ func_unref(this->name); ++ PyMem_Del(this->name); ++ ++ Py_DECREF(self); ++ } ++ ++ static PyObject * ++ FunctionGetattr(PyObject *self, char *name) ++ { ++ FunctionObject *this = (FunctionObject *)(self); ++ ++ if (strcmp(name, "name") == 0) ++ return PyString_FromString((char *)(this->name)); ++ else ++ return Py_FindMethod(FunctionMethods, self, name); ++ } ++ ++ void ++ do_pyeval (char_u *str, typval_T *rettv) ++ { ++ DoPythonCommand(NULL, (char *) str, rettv); ++ switch(rettv->v_type) ++ { ++ case VAR_DICT: ++rettv->vval.v_dict->dv_refcount; break; ++ case VAR_LIST: ++rettv->vval.v_list->lv_refcount; break; ++ case VAR_FUNC: func_ref(rettv->vval.v_string); break; ++ } ++ } + + /* Don't generate a prototype for the next function, it generates an error on + * newer Python versions. */ +*************** +*** 1453,1458 **** +--- 1755,1766 ---- + } + #endif /* Python 1.4 */ + ++ void ++ set_ref_in_python (int copyID) ++ { ++ set_ref_in_py(copyID); ++ } ++ + static void + init_structs(void) + { +*** ../vim-7.3.568/src/if_python3.c 2012-02-04 20:17:21.000000000 +0100 +--- src/if_python3.c 2012-06-29 11:54:10.000000000 +0200 +*************** +*** 77,83 **** + + #define PyInt Py_ssize_t + #define PyString_Check(obj) PyUnicode_Check(obj) +! #define PyString_AsBytes(obj) PyUnicode_AsEncodedString(obj, (char *)ENC_OPT, CODEC_ERROR_HANDLER); + #define PyString_FreeBytes(obj) Py_XDECREF(bytes) + #define PyString_AsString(obj) PyBytes_AsString(obj) + #define PyString_Size(obj) PyBytes_GET_SIZE(bytes) +--- 77,83 ---- + + #define PyInt Py_ssize_t + #define PyString_Check(obj) PyUnicode_Check(obj) +! #define PyString_AsBytes(obj) PyUnicode_AsEncodedString(obj, (char *)ENC_OPT, CODEC_ERROR_HANDLER) + #define PyString_FreeBytes(obj) Py_XDECREF(bytes) + #define PyString_AsString(obj) PyBytes_AsString(obj) + #define PyString_Size(obj) PyBytes_GET_SIZE(bytes) +*************** +*** 109,114 **** +--- 109,115 ---- + # undef PyArg_ParseTuple + # define PyArg_ParseTuple py3_PyArg_ParseTuple + # define PyMem_Free py3_PyMem_Free ++ # define PyMem_Malloc py3_PyMem_Malloc + # define PyDict_SetItemString py3_PyDict_SetItemString + # define PyErr_BadArgument py3_PyErr_BadArgument + # define PyErr_Clear py3_PyErr_Clear +*************** +*** 128,141 **** +--- 129,155 ---- + # define PyList_New py3_PyList_New + # define PyList_SetItem py3_PyList_SetItem + # define PyList_Size py3_PyList_Size ++ # define PySequence_Check py3_PySequence_Check ++ # define PySequence_Size py3_PySequence_Size ++ # define PySequence_GetItem py3_PySequence_GetItem ++ # define PyTuple_Size py3_PyTuple_Size ++ # define PyTuple_GetItem py3_PyTuple_GetItem + # define PySlice_GetIndicesEx py3_PySlice_GetIndicesEx + # define PyImport_ImportModule py3_PyImport_ImportModule ++ # define PyImport_AddModule py3_PyImport_AddModule + # define PyObject_Init py3__PyObject_Init + # define PyDict_New py3_PyDict_New + # define PyDict_GetItemString py3_PyDict_GetItemString ++ # define PyDict_Next py3_PyDict_Next ++ # define PyMapping_Check py3_PyMapping_Check ++ # define PyMapping_Items py3_PyMapping_Items ++ # define PyIter_Next py3_PyIter_Next ++ # define PyObject_GetIter py3_PyObject_GetIter + # define PyModule_GetDict py3_PyModule_GetDict + #undef PyRun_SimpleString + # define PyRun_SimpleString py3_PyRun_SimpleString ++ #undef PyRun_String ++ # define PyRun_String py3_PyRun_String + # define PySys_SetObject py3_PySys_SetObject + # define PySys_SetArgv py3_PySys_SetArgv + # define PyType_Type (*py3_PyType_Type) +*************** +*** 147,152 **** +--- 161,167 ---- + # define Py_Finalize py3_Py_Finalize + # define Py_IsInitialized py3_Py_IsInitialized + # define _Py_NoneStruct (*py3__Py_NoneStruct) ++ # define _PyObject_NextNotImplemented (*py3__PyObject_NextNotImplemented) + # define PyModule_AddObject py3_PyModule_AddObject + # define PyImport_AppendInittab py3_PyImport_AppendInittab + # define _PyUnicode_AsString py3__PyUnicode_AsString +*************** +*** 154,161 **** +--- 169,181 ---- + # define PyUnicode_AsEncodedString py3_PyUnicode_AsEncodedString + # undef PyBytes_AsString + # define PyBytes_AsString py3_PyBytes_AsString ++ # undef PyBytes_FromString ++ # define PyBytes_FromString py3_PyBytes_FromString ++ # define PyFloat_FromDouble py3_PyFloat_FromDouble ++ # define PyFloat_AsDouble py3_PyFloat_AsDouble + # define PyObject_GenericGetAttr py3_PyObject_GenericGetAttr + # define PySlice_Type (*py3_PySlice_Type) ++ # define PyFloat_Type (*py3_PyFloat_Type) + # define PyErr_NewException py3_PyErr_NewException + # ifdef Py_DEBUG + # define _Py_NegativeRefcount py3__Py_NegativeRefcount +*************** +*** 174,179 **** +--- 194,202 ---- + # define PyUnicode_FromString py3_PyUnicode_FromString + # undef PyUnicode_Decode + # define PyUnicode_Decode py3_PyUnicode_Decode ++ # define PyType_IsSubtype py3_PyType_IsSubtype ++ # define PyCapsule_New py3_PyCapsule_New ++ # define PyCapsule_GetPointer py3_PyCapsule_GetPointer + + # ifdef Py_DEBUG + # undef PyObject_NEW +*************** +*** 194,215 **** +--- 217,250 ---- + static int (*py3_PySys_SetObject)(char *, PyObject *); + static PyObject* (*py3_PyList_Append)(PyObject *, PyObject *); + static Py_ssize_t (*py3_PyList_Size)(PyObject *); ++ static int (*py3_PySequence_Check)(PyObject *); ++ static Py_ssize_t (*py3_PySequence_Size)(PyObject *); ++ static PyObject* (*py3_PySequence_GetItem)(PyObject *, Py_ssize_t); ++ static Py_ssize_t (*py3_PyTuple_Size)(PyObject *); ++ static PyObject* (*py3_PyTuple_GetItem)(PyObject *, Py_ssize_t); ++ static int (*py3_PyMapping_Check)(PyObject *); ++ static PyObject* (*py3_PyMapping_Items)(PyObject *); + static int (*py3_PySlice_GetIndicesEx)(PyObject *r, Py_ssize_t length, + Py_ssize_t *start, Py_ssize_t *stop, Py_ssize_t *step, Py_ssize_t *slicelength); + static PyObject* (*py3_PyErr_NoMemory)(void); + static void (*py3_Py_Finalize)(void); + static void (*py3_PyErr_SetString)(PyObject *, const char *); + static int (*py3_PyRun_SimpleString)(char *); ++ static PyObject* (*py3_PyRun_String)(char *, int, PyObject *, PyObject *); + static PyObject* (*py3_PyList_GetItem)(PyObject *, Py_ssize_t); + static PyObject* (*py3_PyImport_ImportModule)(const char *); ++ static PyObject* (*py3_PyImport_AddModule)(const char *); + static int (*py3_PyErr_BadArgument)(void); + static PyTypeObject* py3_PyType_Type; + static PyObject* (*py3_PyErr_Occurred)(void); + static PyObject* (*py3_PyModule_GetDict)(PyObject *); + static int (*py3_PyList_SetItem)(PyObject *, Py_ssize_t, PyObject *); + static PyObject* (*py3_PyDict_GetItemString)(PyObject *, const char *); ++ static int (*py3_PyDict_Next)(PyObject *, Py_ssize_t *, PyObject **, PyObject **); + static PyObject* (*py3_PyLong_FromLong)(long); + static PyObject* (*py3_PyDict_New)(void); ++ static PyObject* (*py3_PyIter_Next)(PyObject *); ++ static PyObject* (*py3_PyObject_GetIter)(PyObject *); + static PyObject* (*py3_Py_BuildValue)(char *, ...); + static int (*py3_PyType_Ready)(PyTypeObject *type); + static int (*py3_PyDict_SetItemString)(PyObject *dp, char *key, PyObject *item); +*************** +*** 224,244 **** +--- 259,287 ---- + static int (*py3_PyArg_Parse)(PyObject *, char *, ...); + static int (*py3_PyArg_ParseTuple)(PyObject *, char *, ...); + static int (*py3_PyMem_Free)(void *); ++ static void* (*py3_PyMem_Malloc)(size_t); + static int (*py3_Py_IsInitialized)(void); + static void (*py3_PyErr_Clear)(void); + static PyObject*(*py3__PyObject_Init)(PyObject *, PyTypeObject *); ++ static iternextfunc py3__PyObject_NextNotImplemented; + static PyObject* py3__Py_NoneStruct; + static int (*py3_PyModule_AddObject)(PyObject *m, const char *name, PyObject *o); + static int (*py3_PyImport_AppendInittab)(const char *name, PyObject* (*initfunc)(void)); + static char* (*py3__PyUnicode_AsString)(PyObject *unicode); + static PyObject* (*py3_PyUnicode_AsEncodedString)(PyObject *unicode, const char* encoding, const char* errors); + static char* (*py3_PyBytes_AsString)(PyObject *bytes); ++ static PyObject* (*py3_PyBytes_FromString)(char *str); ++ static PyObject* (*py3_PyFloat_FromDouble)(double num); ++ static double (*py3_PyFloat_AsDouble)(PyObject *); + static PyObject* (*py3_PyObject_GenericGetAttr)(PyObject *obj, PyObject *name); + static PyObject* (*py3_PyModule_Create2)(struct PyModuleDef* module, int module_api_version); + static PyObject* (*py3_PyType_GenericAlloc)(PyTypeObject *type, Py_ssize_t nitems); + static PyObject* (*py3_PyType_GenericNew)(PyTypeObject *type, PyObject *args, PyObject *kwds); + static PyTypeObject* py3_PySlice_Type; ++ static PyTypeObject* py3_PyFloat_Type; + static PyObject* (*py3_PyErr_NewException)(char *name, PyObject *base, PyObject *dict); ++ static PyObject* (*py3_PyCapsule_New)(void *, char *, PyCapsule_Destructor); ++ static void* (*py3_PyCapsule_GetPointer)(PyObject *, char *); + # ifdef Py_DEBUG + static void (*py3__Py_NegativeRefcount)(const char *fname, int lineno, PyObject *op); + static Py_ssize_t* py3__Py_RefTotal; +*************** +*** 249,254 **** +--- 292,298 ---- + static void (*py3_PyObject_Free)(void*); + static void* (*py3_PyObject_Malloc)(size_t); + # endif ++ static int (*py3_PyType_IsSubtype)(PyTypeObject *, PyTypeObject *); + + static HINSTANCE hinstPy3 = 0; /* Instance of python.dll */ + +*************** +*** 280,304 **** +--- 324,361 ---- + {"Py_Initialize", (PYTHON_PROC*)&py3_Py_Initialize}, + {"PyArg_ParseTuple", (PYTHON_PROC*)&py3_PyArg_ParseTuple}, + {"PyMem_Free", (PYTHON_PROC*)&py3_PyMem_Free}, ++ {"PyMem_Malloc", (PYTHON_PROC*)&py3_PyMem_Malloc}, + {"PyList_New", (PYTHON_PROC*)&py3_PyList_New}, + {"PyGILState_Ensure", (PYTHON_PROC*)&py3_PyGILState_Ensure}, + {"PyGILState_Release", (PYTHON_PROC*)&py3_PyGILState_Release}, + {"PySys_SetObject", (PYTHON_PROC*)&py3_PySys_SetObject}, + {"PyList_Append", (PYTHON_PROC*)&py3_PyList_Append}, + {"PyList_Size", (PYTHON_PROC*)&py3_PyList_Size}, ++ {"PySequence_Check", (PYTHON_PROC*)&py3_PySequence_Check}, ++ {"PySequence_Size", (PYTHON_PROC*)&py3_PySequence_Size}, ++ {"PySequence_GetItem", (PYTHON_PROC*)&py3_PySequence_GetItem}, ++ {"PyTuple_Size", (PYTHON_PROC*)&py3_PyTuple_Size}, ++ {"PyTuple_GetItem", (PYTHON_PROC*)&py3_PyTuple_GetItem}, + {"PySlice_GetIndicesEx", (PYTHON_PROC*)&py3_PySlice_GetIndicesEx}, + {"PyErr_NoMemory", (PYTHON_PROC*)&py3_PyErr_NoMemory}, + {"Py_Finalize", (PYTHON_PROC*)&py3_Py_Finalize}, + {"PyErr_SetString", (PYTHON_PROC*)&py3_PyErr_SetString}, + {"PyRun_SimpleString", (PYTHON_PROC*)&py3_PyRun_SimpleString}, ++ {"PyRun_String", (PYTHON_PROC*)&py3_PyRun_String}, + {"PyList_GetItem", (PYTHON_PROC*)&py3_PyList_GetItem}, + {"PyImport_ImportModule", (PYTHON_PROC*)&py3_PyImport_ImportModule}, ++ {"PyImport_AddModule", (PYTHON_PROC*)&py3_PyImport_AddModule}, + {"PyErr_BadArgument", (PYTHON_PROC*)&py3_PyErr_BadArgument}, + {"PyType_Type", (PYTHON_PROC*)&py3_PyType_Type}, + {"PyErr_Occurred", (PYTHON_PROC*)&py3_PyErr_Occurred}, + {"PyModule_GetDict", (PYTHON_PROC*)&py3_PyModule_GetDict}, + {"PyList_SetItem", (PYTHON_PROC*)&py3_PyList_SetItem}, + {"PyDict_GetItemString", (PYTHON_PROC*)&py3_PyDict_GetItemString}, ++ {"PyDict_Next", (PYTHON_PROC*)&py3_PyDict_Next}, ++ {"PyMapping_Check", (PYTHON_PROC*)&py3_PyMapping_Check}, ++ {"PyMapping_Items", (PYTHON_PROC*)&py3_PyMapping_Items}, ++ {"PyIter_Next", (PYTHON_PROC*)&py3_PyIter_Next}, ++ {"PyObject_GetIter", (PYTHON_PROC*)&py3_PyObject_GetIter}, + {"PyLong_FromLong", (PYTHON_PROC*)&py3_PyLong_FromLong}, + {"PyDict_New", (PYTHON_PROC*)&py3_PyDict_New}, + {"Py_BuildValue", (PYTHON_PROC*)&py3_Py_BuildValue}, +*************** +*** 311,316 **** +--- 368,374 ---- + {"PyEval_SaveThread", (PYTHON_PROC*)&py3_PyEval_SaveThread}, + {"PyArg_Parse", (PYTHON_PROC*)&py3_PyArg_Parse}, + {"Py_IsInitialized", (PYTHON_PROC*)&py3_Py_IsInitialized}, ++ {"_PyObject_NextNotImplemented", (PYTHON_PROC*)&py3__PyObject_NextNotImplemented}, + {"_Py_NoneStruct", (PYTHON_PROC*)&py3__Py_NoneStruct}, + {"PyErr_Clear", (PYTHON_PROC*)&py3_PyErr_Clear}, + {"PyObject_Init", (PYTHON_PROC*)&py3__PyObject_Init}, +*************** +*** 318,328 **** +--- 376,390 ---- + {"PyImport_AppendInittab", (PYTHON_PROC*)&py3_PyImport_AppendInittab}, + {"_PyUnicode_AsString", (PYTHON_PROC*)&py3__PyUnicode_AsString}, + {"PyBytes_AsString", (PYTHON_PROC*)&py3_PyBytes_AsString}, ++ {"PyBytes_FromString", (PYTHON_PROC*)&py3_PyBytes_FromString}, ++ {"PyFloat_FromDouble", (PYTHON_PROC*)&py3_PyFloat_FromDouble}, ++ {"PyFloat_AsDouble", (PYTHON_PROC*)&py3_PyFloat_AsDouble}, + {"PyObject_GenericGetAttr", (PYTHON_PROC*)&py3_PyObject_GenericGetAttr}, + {"PyModule_Create2", (PYTHON_PROC*)&py3_PyModule_Create2}, + {"PyType_GenericAlloc", (PYTHON_PROC*)&py3_PyType_GenericAlloc}, + {"PyType_GenericNew", (PYTHON_PROC*)&py3_PyType_GenericNew}, + {"PySlice_Type", (PYTHON_PROC*)&py3_PySlice_Type}, ++ {"PyFloat_Type", (PYTHON_PROC*)&py3_PyFloat_Type}, + {"PyErr_NewException", (PYTHON_PROC*)&py3_PyErr_NewException}, + # ifdef Py_DEBUG + {"_Py_NegativeRefcount", (PYTHON_PROC*)&py3__Py_NegativeRefcount}, +*************** +*** 334,339 **** +--- 396,404 ---- + {"PyObject_Malloc", (PYTHON_PROC*)&py3_PyObject_Malloc}, + {"PyObject_Free", (PYTHON_PROC*)&py3_PyObject_Free}, + # endif ++ {"PyType_IsSubtype", (PYTHON_PROC*)&py3_PyType_IsSubtype}, ++ {"PyCapsule_New", (PYTHON_PROC*)&py3_PyCapsule_New}, ++ {"PyCapsule_GetPointer", (PYTHON_PROC*)&py3_PyCapsule_GetPointer}, + {"", NULL}, + }; + +*************** +*** 472,482 **** +--- 537,577 ---- + + static PyTypeObject RangeType; + ++ static int py3initialised = 0; ++ ++ #define PYINITIALISED py3initialised ++ ++ /* Add conversion from PyInt? */ ++ #define DICTKEY_GET(err) \ ++ if (PyBytes_Check(keyObject)) \ ++ key = (char_u *) PyBytes_AsString(keyObject); \ ++ else if (PyUnicode_Check(keyObject)) \ ++ { \ ++ bytes = PyString_AsBytes(keyObject); \ ++ if (bytes == NULL) \ ++ return err; \ ++ key = (char_u *) PyBytes_AsString(bytes); \ ++ if (key == NULL) \ ++ return err; \ ++ } \ ++ else \ ++ { \ ++ PyErr_SetString(PyExc_TypeError, _("only string keys are allowed")); \ ++ return err; \ ++ } ++ #define DICTKEY_UNREF \ ++ if (bytes != NULL) \ ++ Py_XDECREF(bytes); ++ ++ #define DICTKEY_DECL PyObject *bytes = NULL; ++ + /* + * Include the code shared with if_python.c + */ + #include "if_py_both.h" + ++ #define PY3OBJ_DELETED(obj) (obj->ob_base.ob_refcnt<=0) ++ + static void + call_PyObject_Free(void *p) + { +*************** +*** 506,511 **** +--- 601,608 ---- + static Py_ssize_t RangeStart; + static Py_ssize_t RangeEnd; + ++ static PyObject *globals; ++ + static int PythonIO_Init(void); + static void PythonIO_Fini(void); + PyMODINIT_FUNC Py3Init_vim(void); +*************** +*** 514,521 **** + * 1. Python interpreter main program. + */ + +- static int py3initialised = 0; +- + static PyGILState_STATE pygilstate = PyGILState_UNLOCKED; + + void +--- 611,616 ---- +*************** +*** 593,598 **** +--- 688,695 ---- + + PyImport_AppendInittab("vim", Py3Init_vim); + ++ globals = PyModule_GetDict(PyImport_AddModule("__main__")); ++ + /* Remove the element from sys.path that was added because of our + * argv[0] value in Py3Init_vim(). Previously we used an empty + * string, but dependinding on the OS we then get an empty entry or +*************** +*** 629,635 **** + * External interface + */ + static void +! DoPy3Command(exarg_T *eap, const char *cmd) + { + #if defined(MACOS) && !defined(MACOS_X_UNIX) + GrafPtr oldPort; +--- 726,732 ---- + * External interface + */ + static void +! DoPy3Command(exarg_T *eap, const char *cmd, typval_T *rettv) + { + #if defined(MACOS) && !defined(MACOS_X_UNIX) + GrafPtr oldPort; +*************** +*** 649,656 **** + if (Python3_Init()) + goto theend; + +! RangeStart = eap->line1; +! RangeEnd = eap->line2; + Python_Release_Vim(); /* leave vim */ + + #if defined(HAVE_LOCALE_H) || defined(X_LOCALE) +--- 746,761 ---- + if (Python3_Init()) + goto theend; + +! if (rettv == NULL) +! { +! RangeStart = eap->line1; +! RangeEnd = eap->line2; +! } +! else +! { +! RangeStart = (PyInt) curwin->w_cursor.lnum; +! RangeEnd = RangeStart; +! } + Python_Release_Vim(); /* leave vim */ + + #if defined(HAVE_LOCALE_H) || defined(X_LOCALE) +*************** +*** 674,680 **** + (char *)ENC_OPT, CODEC_ERROR_HANDLER); + cmdbytes = PyUnicode_AsEncodedString(cmdstr, "utf-8", CODEC_ERROR_HANDLER); + Py_XDECREF(cmdstr); +! PyRun_SimpleString(PyBytes_AsString(cmdbytes)); + Py_XDECREF(cmdbytes); + + PyGILState_Release(pygilstate); +--- 779,802 ---- + (char *)ENC_OPT, CODEC_ERROR_HANDLER); + cmdbytes = PyUnicode_AsEncodedString(cmdstr, "utf-8", CODEC_ERROR_HANDLER); + Py_XDECREF(cmdstr); +! if (rettv == NULL) +! PyRun_SimpleString(PyBytes_AsString(cmdbytes)); +! else +! { +! PyObject *r; +! +! r = PyRun_String(PyBytes_AsString(cmdbytes), Py_eval_input, +! globals, globals); +! if (r == NULL) +! EMSG(_("E860: Eval did not return a valid python 3 object")); +! else +! { +! if (ConvertFromPyObject(r, rettv) == -1) +! EMSG(_("E861: Failed to convert returned python 3 object to vim value")); +! Py_DECREF(r); +! } +! PyErr_Clear(); +! } + Py_XDECREF(cmdbytes); + + PyGILState_Release(pygilstate); +*************** +*** 709,717 **** + if (!eap->skip) + { + if (script == NULL) +! DoPy3Command(eap, (char *)eap->arg); + else +! DoPy3Command(eap, (char *)script); + } + vim_free(script); + } +--- 831,839 ---- + if (!eap->skip) + { + if (script == NULL) +! DoPy3Command(eap, (char *)eap->arg, NULL); + else +! DoPy3Command(eap, (char *)script, NULL); + } + vim_free(script); + } +*************** +*** 772,778 **** + + + /* Execute the file */ +! DoPy3Command(eap, buffer); + } + + /****************************************************** +--- 894,900 ---- + + + /* Execute the file */ +! DoPy3Command(eap, buffer, NULL); + } + + /****************************************************** +*************** +*** 802,815 **** + if (PyUnicode_Check(nameobj)) + name = _PyUnicode_AsString(nameobj); + +! if (val == NULL) { + PyErr_SetString(PyExc_AttributeError, _("can't delete OutputObject attributes")); + return -1; + } + + if (strcmp(name, "softspace") == 0) + { +! if (!PyLong_Check(val)) { + PyErr_SetString(PyExc_TypeError, _("softspace must be an integer")); + return -1; + } +--- 924,939 ---- + if (PyUnicode_Check(nameobj)) + name = _PyUnicode_AsString(nameobj); + +! if (val == NULL) +! { + PyErr_SetString(PyExc_AttributeError, _("can't delete OutputObject attributes")); + return -1; + } + + if (strcmp(name, "softspace") == 0) + { +! if (!PyLong_Check(val)) +! { + PyErr_SetString(PyExc_TypeError, _("softspace must be an integer")); + return -1; + } +*************** +*** 1030,1049 **** + static PyObject * + BufferSubscript(PyObject *self, PyObject* idx) + { +! if (PyLong_Check(idx)) { + long _idx = PyLong_AsLong(idx); + return BufferItem(self,_idx); +! } else if (PySlice_Check(idx)) { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count+1, + &start, &stop, +! &step, &slicelen) < 0) { + return NULL; + } + return BufferSlice(self, start, stop); +! } else { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return NULL; + } +--- 1154,1178 ---- + static PyObject * + BufferSubscript(PyObject *self, PyObject* idx) + { +! if (PyLong_Check(idx)) +! { + long _idx = PyLong_AsLong(idx); + return BufferItem(self,_idx); +! } else if (PySlice_Check(idx)) +! { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count+1, + &start, &stop, +! &step, &slicelen) < 0) +! { + return NULL; + } + return BufferSlice(self, start, stop); +! } +! else +! { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return NULL; + } +*************** +*** 1052,1075 **** + static Py_ssize_t + BufferAsSubscript(PyObject *self, PyObject* idx, PyObject* val) + { +! if (PyLong_Check(idx)) { + long n = PyLong_AsLong(idx); + return RBAsItem((BufferObject *)(self), n, val, 1, + (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count, + NULL); +! } else if (PySlice_Check(idx)) { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count+1, + &start, &stop, +! &step, &slicelen) < 0) { + return -1; + } + return RBAsSlice((BufferObject *)(self), start, stop, val, 1, + (PyInt)((BufferObject *)(self))->buf->b_ml.ml_line_count, + NULL); +! } else { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return -1; + } +--- 1181,1209 ---- + static Py_ssize_t + BufferAsSubscript(PyObject *self, PyObject* idx, PyObject* val) + { +! if (PyLong_Check(idx)) +! { + long n = PyLong_AsLong(idx); + return RBAsItem((BufferObject *)(self), n, val, 1, + (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count, + NULL); +! } else if (PySlice_Check(idx)) +! { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count+1, + &start, &stop, +! &step, &slicelen) < 0) +! { + return -1; + } + return RBAsSlice((BufferObject *)(self), start, stop, val, 1, + (PyInt)((BufferObject *)(self))->buf->b_ml.ml_line_count, + NULL); +! } +! else +! { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return -1; + } +*************** +*** 1142,1161 **** + static PyObject * + RangeSubscript(PyObject *self, PyObject* idx) + { +! if (PyLong_Check(idx)) { + long _idx = PyLong_AsLong(idx); + return RangeItem(self,_idx); +! } else if (PySlice_Check(idx)) { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + ((RangeObject *)(self))->end-((RangeObject *)(self))->start+1, + &start, &stop, +! &step, &slicelen) < 0) { + return NULL; + } + return RangeSlice(self, start, stop); +! } else { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return NULL; + } +--- 1276,1300 ---- + static PyObject * + RangeSubscript(PyObject *self, PyObject* idx) + { +! if (PyLong_Check(idx)) +! { + long _idx = PyLong_AsLong(idx); + return RangeItem(self,_idx); +! } else if (PySlice_Check(idx)) +! { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + ((RangeObject *)(self))->end-((RangeObject *)(self))->start+1, + &start, &stop, +! &step, &slicelen) < 0) +! { + return NULL; + } + return RangeSlice(self, start, stop); +! } +! else +! { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return NULL; + } +*************** +*** 1164,1183 **** + static Py_ssize_t + RangeAsSubscript(PyObject *self, PyObject *idx, PyObject *val) + { +! if (PyLong_Check(idx)) { + long n = PyLong_AsLong(idx); + return RangeAsItem(self, n, val); +! } else if (PySlice_Check(idx)) { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + ((RangeObject *)(self))->end-((RangeObject *)(self))->start+1, + &start, &stop, +! &step, &slicelen) < 0) { + return -1; + } + return RangeAsSlice(self, start, stop, val); +! } else { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return -1; + } +--- 1303,1327 ---- + static Py_ssize_t + RangeAsSubscript(PyObject *self, PyObject *idx, PyObject *val) + { +! if (PyLong_Check(idx)) +! { + long n = PyLong_AsLong(idx); + return RangeAsItem(self, n, val); +! } else if (PySlice_Check(idx)) +! { + Py_ssize_t start, stop, step, slicelen; + + if (PySlice_GetIndicesEx((PyObject *)idx, + ((RangeObject *)(self))->end-((RangeObject *)(self))->start+1, + &start, &stop, +! &step, &slicelen) < 0) +! { + return -1; + } + return RangeAsSlice(self, start, stop, val); +! } +! else +! { + PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return -1; + } +*************** +*** 1390,1395 **** +--- 1534,1680 ---- + } + } + ++ /* Dictionary object - Definitions ++ */ ++ ++ static PyInt DictionaryLength(PyObject *); ++ ++ static PyMappingMethods DictionaryAsMapping = { ++ /* mp_length */ (lenfunc) DictionaryLength, ++ /* mp_subscript */ (binaryfunc) DictionaryItem, ++ /* mp_ass_subscript */ (objobjargproc) DictionaryAssItem, ++ }; ++ ++ static PyTypeObject DictionaryType; ++ ++ static void ++ DictionaryDestructor(PyObject *self) ++ { ++ DictionaryObject *this = (DictionaryObject *)(self); ++ ++ pyll_remove(&this->ref, &lastdict); ++ dict_unref(this->dict); ++ ++ Py_TYPE(self)->tp_free((PyObject*)self); ++ } ++ ++ /* List object - Definitions ++ */ ++ ++ static PyInt ListLength(PyObject *); ++ static PyObject *ListItem(PyObject *, Py_ssize_t); ++ ++ static PySequenceMethods ListAsSeq = { ++ (lenfunc) ListLength, /* sq_length, len(x) */ ++ (binaryfunc) 0, /* RangeConcat, sq_concat, x+y */ ++ (ssizeargfunc) 0, /* RangeRepeat, sq_repeat, x*n */ ++ (ssizeargfunc) ListItem, /* sq_item, x[i] */ ++ (void *) 0, /* was_sq_slice, x[i:j] */ ++ (ssizeobjargproc) ListAssItem, /* sq_as_item, x[i]=v */ ++ (void *) 0, /* was_sq_ass_slice, x[i:j]=v */ ++ 0, /* sq_contains */ ++ (binaryfunc) ListConcatInPlace,/* sq_inplace_concat */ ++ 0, /* sq_inplace_repeat */ ++ }; ++ ++ static PyObject *ListSubscript(PyObject *, PyObject *); ++ static Py_ssize_t ListAsSubscript(PyObject *, PyObject *, PyObject *); ++ ++ static PyMappingMethods ListAsMapping = { ++ /* mp_length */ (lenfunc) ListLength, ++ /* mp_subscript */ (binaryfunc) ListSubscript, ++ /* mp_ass_subscript */ (objobjargproc) ListAsSubscript, ++ }; ++ ++ static PyTypeObject ListType; ++ ++ static PyObject * ++ ListSubscript(PyObject *self, PyObject* idxObject) ++ { ++ if (PyLong_Check(idxObject)) ++ { ++ long idx = PyLong_AsLong(idxObject); ++ return ListItem(self, idx); ++ } ++ else if (PySlice_Check(idxObject)) ++ { ++ Py_ssize_t start, stop, step, slicelen; ++ ++ if (PySlice_GetIndicesEx(idxObject, ListLength(self), &start, &stop, ++ &step, &slicelen) < 0) ++ return NULL; ++ return ListSlice(self, start, stop); ++ } ++ else ++ { ++ PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); ++ return NULL; ++ } ++ } ++ ++ static Py_ssize_t ++ ListAsSubscript(PyObject *self, PyObject *idxObject, PyObject *obj) ++ { ++ if (PyLong_Check(idxObject)) ++ { ++ long idx = PyLong_AsLong(idxObject); ++ return ListAssItem(self, idx, obj); ++ } ++ else if (PySlice_Check(idxObject)) ++ { ++ Py_ssize_t start, stop, step, slicelen; ++ ++ if (PySlice_GetIndicesEx(idxObject, ListLength(self), &start, &stop, ++ &step, &slicelen) < 0) ++ return -1; ++ return ListAssSlice(self, start, stop, obj); ++ } ++ else ++ { ++ PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); ++ return -1; ++ } ++ } ++ ++ static void ++ ListDestructor(PyObject *self) ++ { ++ ListObject *this = (ListObject *)(self); ++ ++ pyll_remove(&this->ref, &lastlist); ++ list_unref(this->list); ++ ++ Py_TYPE(self)->tp_free((PyObject*)self); ++ } ++ ++ /* Function object - Definitions ++ */ ++ ++ static void ++ FunctionDestructor(PyObject *self) ++ { ++ FunctionObject *this = (FunctionObject *) (self); ++ ++ func_unref(this->name); ++ PyMem_Del(this->name); ++ ++ Py_TYPE(self)->tp_free((PyObject*)self); ++ } ++ ++ static PyObject * ++ FunctionGetattro(PyObject *self, PyObject *nameobj) ++ { ++ FunctionObject *this = (FunctionObject *)(self); ++ char *name = ""; ++ if (PyUnicode_Check(nameobj)) ++ name = _PyUnicode_AsString(nameobj); ++ ++ if (strcmp(name, "name") == 0) ++ return PyUnicode_FromString((char *)(this->name)); ++ ++ return PyObject_GenericGetAttr(self, nameobj); ++ } ++ + /* External interface + */ + +*************** +*** 1449,1454 **** +--- 1734,1742 ---- + PyType_Ready(&BufListType); + PyType_Ready(&WinListType); + PyType_Ready(&CurrentType); ++ PyType_Ready(&DictionaryType); ++ PyType_Ready(&ListType); ++ PyType_Ready(&FunctionType); + + /* Set sys.argv[] to avoid a crash in warn(). */ + PySys_SetArgv(1, argv); +*************** +*** 1517,1522 **** +--- 1805,1828 ---- + return result; + } + ++ void ++ do_py3eval (char_u *str, typval_T *rettv) ++ { ++ DoPy3Command(NULL, (char *) str, rettv); ++ switch(rettv->v_type) ++ { ++ case VAR_DICT: ++rettv->vval.v_dict->dv_refcount; break; ++ case VAR_LIST: ++rettv->vval.v_list->lv_refcount; break; ++ case VAR_FUNC: func_ref(rettv->vval.v_string); break; ++ } ++ } ++ ++ void ++ set_ref_in_python3 (int copyID) ++ { ++ set_ref_in_py(copyID); ++ } ++ + static void + init_structs(void) + { +*************** +*** 1598,1603 **** +--- 1904,1938 ---- + CurrentType.tp_flags = Py_TPFLAGS_DEFAULT; + CurrentType.tp_doc = "vim current object"; + ++ vim_memset(&DictionaryType, 0, sizeof(DictionaryType)); ++ DictionaryType.tp_name = "vim.dictionary"; ++ DictionaryType.tp_basicsize = sizeof(DictionaryObject); ++ DictionaryType.tp_dealloc = DictionaryDestructor; ++ DictionaryType.tp_as_mapping = &DictionaryAsMapping; ++ DictionaryType.tp_flags = Py_TPFLAGS_DEFAULT; ++ DictionaryType.tp_doc = "dictionary pushing modifications to vim structure"; ++ DictionaryType.tp_methods = DictionaryMethods; ++ ++ vim_memset(&ListType, 0, sizeof(ListType)); ++ ListType.tp_name = "vim.list"; ++ ListType.tp_dealloc = ListDestructor; ++ ListType.tp_basicsize = sizeof(ListObject); ++ ListType.tp_as_sequence = &ListAsSeq; ++ ListType.tp_as_mapping = &ListAsMapping; ++ ListType.tp_flags = Py_TPFLAGS_DEFAULT; ++ ListType.tp_doc = "list pushing modifications to vim structure"; ++ ListType.tp_methods = ListMethods; ++ ++ vim_memset(&FunctionType, 0, sizeof(FunctionType)); ++ FunctionType.tp_name = "vim.list"; ++ FunctionType.tp_basicsize = sizeof(FunctionObject); ++ FunctionType.tp_getattro = FunctionGetattro; ++ FunctionType.tp_dealloc = FunctionDestructor; ++ FunctionType.tp_call = FunctionCall; ++ FunctionType.tp_flags = Py_TPFLAGS_DEFAULT; ++ FunctionType.tp_doc = "object that calls vim function"; ++ FunctionType.tp_methods = FunctionMethods; ++ + vim_memset(&vimmodule, 0, sizeof(vimmodule)); + vimmodule.m_name = "vim"; + vimmodule.m_doc = vim_module_doc; +*** ../vim-7.3.568/src/proto/eval.pro 2011-09-14 16:52:02.000000000 +0200 +--- src/proto/eval.pro 2012-06-20 18:20:28.000000000 +0200 +*************** +*** 46,57 **** +--- 46,66 ---- + list_T *list_alloc __ARGS((void)); + void list_unref __ARGS((list_T *l)); + void list_free __ARGS((list_T *l, int recurse)); ++ listitem_T *listitem_alloc __ARGS((void)); ++ void listitem_remove __ARGS((list_T *l, listitem_T *item)); + dictitem_T *dict_lookup __ARGS((hashitem_T *hi)); ++ listitem_T *list_find __ARGS((list_T *l, long n)); + char_u *list_find_str __ARGS((list_T *l, long idx)); ++ void list_append __ARGS((list_T *l, listitem_T *item)); + int list_append_tv __ARGS((list_T *l, typval_T *tv)); + int list_append_dict __ARGS((list_T *list, dict_T *dict)); + int list_append_string __ARGS((list_T *l, char_u *str, int len)); ++ int list_insert_tv __ARGS((list_T *l, typval_T *tv, listitem_T *item)); ++ void list_remove __ARGS((list_T *l, listitem_T *item, listitem_T *item2)); + int garbage_collect __ARGS((void)); ++ void set_ref_in_ht __ARGS((hashtab_T *ht, int copyID)); ++ void set_ref_in_list __ARGS((list_T *l, int copyID)); ++ void set_ref_in_item __ARGS((typval_T *tv, int copyID)); + dict_T *dict_alloc __ARGS((void)); + void dict_unref __ARGS((dict_T *d)); + dictitem_T *dictitem_alloc __ARGS((char_u *key)); +*************** +*** 64,69 **** +--- 73,79 ---- + long get_dict_number __ARGS((dict_T *d, char_u *key)); + char_u *get_function_name __ARGS((expand_T *xp, int idx)); + char_u *get_expr_name __ARGS((expand_T *xp, int idx)); ++ int func_call __ARGS((char_u *name, typval_T *args, dict_T *selfdict, typval_T *rettv)); + long do_searchpair __ARGS((char_u *spat, char_u *mpat, char_u *epat, int dir, char_u *skip, int flags, pos_T *match_pos, linenr_T lnum_stop, long time_limit)); + void set_vim_var_nr __ARGS((int idx, long val)); + long get_vim_var_nr __ARGS((int idx)); +*************** +*** 94,99 **** +--- 104,111 ---- + void func_dump_profile __ARGS((FILE *fd)); + char_u *get_user_func_name __ARGS((expand_T *xp, int idx)); + void ex_delfunction __ARGS((exarg_T *eap)); ++ void func_unref __ARGS((char_u *name)); ++ void func_ref __ARGS((char_u *name)); + void ex_return __ARGS((exarg_T *eap)); + int do_return __ARGS((exarg_T *eap, int reanimate, int is_cmd, void *rettv)); + void discard_pending_return __ARGS((void *rettv)); +*** ../vim-7.3.568/src/proto/if_python.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/if_python.pro 2012-06-20 18:23:06.000000000 +0200 +*************** +*** 6,9 **** +--- 6,11 ---- + void ex_pyfile __ARGS((exarg_T *eap)); + void python_buffer_free __ARGS((buf_T *buf)); + void python_window_free __ARGS((win_T *win)); ++ void do_pyeval __ARGS((char_u *str, typval_T *rettv)); ++ void set_ref_in_python __ARGS((int copyID)); + /* vim: set ft=c : */ +*** ../vim-7.3.568/src/proto/if_python3.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/if_python3.pro 2012-06-20 18:34:26.000000000 +0200 +*************** +*** 6,9 **** +--- 6,11 ---- + void ex_py3file __ARGS((exarg_T *eap)); + void python3_buffer_free __ARGS((buf_T *buf)); + void python3_window_free __ARGS((win_T *win)); ++ void do_py3eval __ARGS((char_u *str, typval_T *rettv)); ++ void set_ref_in_python3 __ARGS((int copyID)); + /* vim: set ft=c : */ +*** ../vim-7.3.568/src/testdir/Make_amiga.mak 2012-04-05 16:56:38.000000000 +0200 +--- src/testdir/Make_amiga.mak 2012-06-20 18:43:05.000000000 +0200 +*************** +*** 14,19 **** +--- 14,20 ---- + # test27 can't edit file with "*" + # test52 only for Win32 + # test85 no Lua interface ++ # test86, 87 no Python interface + + SCRIPTS = test1.out test3.out test4.out test5.out test6.out \ + test7.out test8.out test9.out \ +*** ../vim-7.3.568/src/testdir/Make_dos.mak 2012-04-13 19:11:16.000000000 +0200 +--- src/testdir/Make_dos.mak 2012-06-20 18:43:45.000000000 +0200 +*************** +*** 30,36 **** + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out + + SCRIPTS32 = test50.out test70.out + +--- 30,36 ---- + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.568/src/testdir/Make_ming.mak 2012-04-13 19:11:16.000000000 +0200 +--- src/testdir/Make_ming.mak 2012-06-20 18:44:12.000000000 +0200 +*************** +*** 50,56 **** + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out + + SCRIPTS32 = test50.out test70.out + +--- 50,56 ---- + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.568/src/testdir/Make_os2.mak 2012-04-05 16:56:38.000000000 +0200 +--- src/testdir/Make_os2.mak 2012-06-20 18:44:32.000000000 +0200 +*************** +*** 14,19 **** +--- 14,20 ---- + # test27 can't edit file with "*" in file name + # test52 only for Win32 + # test85 no Lua interface ++ # test86, 87 no Python interface + + SCRIPTS = test1.out test3.out test4.out test5.out test6.out \ + test7.out test8.out test9.out \ +*** ../vim-7.3.568/src/testdir/Makefile 2012-04-05 16:56:38.000000000 +0200 +--- src/testdir/Makefile 2012-06-29 11:56:00.000000000 +0200 +*************** +*** 27,33 **** + test69.out test70.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out + + SCRIPTS_GUI = test16.out + +--- 27,33 ---- + test69.out test70.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out + + SCRIPTS_GUI = test16.out + +*** ../vim-7.3.568/src/testdir/test86.in 2012-06-20 20:19:31.000000000 +0200 +--- src/testdir/test86.in 2012-06-20 18:01:02.000000000 +0200 +*************** +*** 0 **** +--- 1,211 ---- ++ Tests for various python features. vim: set ft=vim : ++ ++ STARTTEST ++ :so small.vim ++ :if !has('python') | e! test.ok | wq! test.out | endif ++ :py import vim ++ :fun Test() ++ :let l = [] ++ :py l=vim.bindeval('l') ++ :py f=vim.bindeval('function("strlen")') ++ :" Extending List directly with different types ++ :py l.extend([1, "as'd", [1, 2, f, {'a': 1}]]) ++ :$put =string(l) ++ :$put =string(l[-1]) ++ :try ++ : $put =string(l[-4]) ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :" List assignment ++ :py l[0]=0 ++ :$put =string(l) ++ :py l[-2]=f ++ :$put =string(l) ++ :" ++ :" Extending Dictionary directly with different types ++ :let d = {} ++ :py d=vim.bindeval('d') ++ :py d['1']='asd' ++ :py d['b']=[1, 2, f] ++ :py d['-1']={'a': 1} ++ :let dkeys = [] ++ :py dk=vim.bindeval('dkeys') ++ :py dkeys=d.keys() ++ :py dkeys.sort() ++ :py dk.extend(dkeys) ++ :$put =string(dkeys) ++ :for [key, val] in sort(items(d)) ++ : $put =string(key) . ' : ' . string(val) ++ : unlet key val ++ :endfor ++ :" ++ :" removing items with del ++ :py del l[2] ++ :$put =string(l) ++ :let l = range(8) ++ :py l=vim.bindeval('l') ++ :try ++ : py del l[:3] ++ : py del l[1:] ++ :catch ++ : $put =v:exception ++ :endtry ++ :$put =string(l) ++ :" ++ :py del d['-1'] ++ :$put =string(d) ++ :" ++ :" removing items out of range: silently skip items that don't exist ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :" The following two ranges delete nothing as they match empty list: ++ :py del l[2:1] ++ :$put =string(l) ++ :py del l[2:2] ++ :$put =string(l) ++ :py del l[2:3] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py del l[2:4] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py del l[2:5] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py del l[2:6] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :" The following two ranges delete nothing as they match empty list: ++ :py del l[-1:2] ++ :$put =string(l) ++ :py del l[-2:2] ++ :$put =string(l) ++ :py del l[-3:2] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py del l[-4:2] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py del l[-5:2] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py del l[-6:2] ++ :$put =string(l) ++ :" ++ :" Slice assignment to a list ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py l[0:0]=['a'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py l[1:2]=['b'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py l[2:4]=['c'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py l[4:4]=['d'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py l[-1:2]=['e'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py l[-10:2]=['f'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :py l[2:-10]=['g'] ++ :$put =string(l) ++ :let l = [] ++ :py l=vim.bindeval('l') ++ :py l[0:0]=['h'] ++ :$put =string(l) ++ :" ++ :" Locked variables ++ :let l = [0, 1, 2, 3] ++ :py l=vim.bindeval('l') ++ :lockvar! l ++ :py l[2]='i' ++ :$put =string(l) ++ :unlockvar! l ++ :" ++ :" Function calls ++ :function New(...) ++ :return ['NewStart']+a:000+['NewEnd'] ++ :endfunction ++ :function DictNew(...) dict ++ :return ['DictNewStart']+a:000+['DictNewEnd', self] ++ :endfunction ++ :let l=[function('New'), function('DictNew')] ++ :py l=vim.bindeval('l') ++ :py l.extend(list(l[0](1, 2, 3))) ++ :$put =string(l) ++ :py l.extend(list(l[1](1, 2, 3, self={'a': 'b'}))) ++ :$put =string(l) ++ :py l.extend([l[0].name]) ++ :$put =string(l) ++ :try ++ : py l[1](1, 2, 3) ++ :catch ++ : $put =v:exception[:16] ++ :endtry ++ :delfunction New ++ :try ++ : py l[0](1, 2, 3) ++ :catch ++ : $put =v:exception[:16] ++ :endtry ++ :if has('float') ++ : let l=[0.0] ++ : py l=vim.bindeval('l') ++ : py l.extend([0.0]) ++ : $put =string(l) ++ :else ++ : $put ='[0.0, 0.0]' ++ :endif ++ :" ++ :" pyeval() ++ :let l=pyeval('range(3)') ++ :$put =string(l) ++ :let d=pyeval('{"a": "b", "c": 1, "d": ["e"]}') ++ :$put =sort(items(d)) ++ :try ++ : let undef=pyeval('undefined_name') ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :try ++ : let vim=pyeval('vim') ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :if has('float') ++ : let f=pyeval('0.0') ++ : $put =string(f) ++ :else ++ : $put ='0.0' ++ :endif ++ :endfun ++ :" ++ :call Test() ++ :" ++ :delfunc Test ++ :call garbagecollect(1) ++ :" ++ :/^start:/,$wq! test.out ++ ENDTEST ++ ++ start: +*** ../vim-7.3.568/src/testdir/test86.ok 2012-06-20 20:19:31.000000000 +0200 +--- src/testdir/test86.ok 2012-06-20 18:01:02.000000000 +0200 +*************** +*** 0 **** +--- 1,47 ---- ++ start: ++ [1, 'as''d', [1, 2, function('strlen'), {'a': 1}]] ++ [1, 2, function('strlen'), {'a': 1}] ++ Vim(put):E684: ++ [0, 'as''d', [1, 2, function('strlen'), {'a': 1}]] ++ [0, function('strlen'), [1, 2, function('strlen'), {'a': 1}]] ++ ['-1', '1', 'b'] ++ '-1' : {'a': 1} ++ '1' : 'asd' ++ 'b' : [1, 2, function('strlen')] ++ [0, function('strlen')] ++ [3] ++ {'1': 'asd', 'b': [1, 2, function('strlen')]} ++ [0, 1, 2, 3] ++ [0, 1, 2, 3] ++ [0, 1, 3] ++ [0, 1] ++ [0, 1] ++ [0, 1] ++ [0, 1, 2, 3] ++ [0, 1, 2, 3] ++ [0, 2, 3] ++ [2, 3] ++ [2, 3] ++ [2, 3] ++ ['a', 0, 1, 2, 3] ++ [0, 'b', 2, 3] ++ [0, 1, 'c'] ++ [0, 1, 2, 3, 'd'] ++ [0, 1, 2, 'e', 3] ++ ['f', 2, 3] ++ [0, 1, 'g', 2, 3] ++ ['h'] ++ [0, 1, 2, 3] ++ [function('New'), function('DictNew'), 'NewStart', 1, 2, 3, 'NewEnd'] ++ [function('New'), function('DictNew'), 'NewStart', 1, 2, 3, 'NewEnd', 'DictNewStart', 1, 2, 3, 'DictNewEnd', {'a': 'b'}] ++ [function('New'), function('DictNew'), 'NewStart', 1, 2, 3, 'NewEnd', 'DictNewStart', 1, 2, 3, 'DictNewEnd', {'a': 'b'}, 'New'] ++ Vim(python):E725: ++ Vim(python):E117: ++ [0.0, 0.0] ++ [0, 1, 2] ++ ['a', 'b'] ++ ['c', 1] ++ ['d', ['e']] ++ Vim(let):E858: ++ Vim(let):E859: ++ 0.0 +*** ../vim-7.3.568/src/testdir/test87.in 2012-06-20 20:19:31.000000000 +0200 +--- src/testdir/test87.in 2012-06-20 18:01:02.000000000 +0200 +*************** +*** 0 **** +--- 1,211 ---- ++ Tests for various python features. vim: set ft=vim : ++ ++ STARTTEST ++ :so small.vim ++ :if !has('python3') | e! test.ok | wq! test.out | endif ++ :py3 import vim ++ :fun Test() ++ :let l = [] ++ :py3 l=vim.bindeval('l') ++ :py3 f=vim.bindeval('function("strlen")') ++ :" Extending List directly with different types ++ :py3 l+=[1, "as'd", [1, 2, f, {'a': 1}]] ++ :$put =string(l) ++ :$put =string(l[-1]) ++ :try ++ : $put =string(l[-4]) ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :" List assignment ++ :py3 l[0]=0 ++ :$put =string(l) ++ :py3 l[-2]=f ++ :$put =string(l) ++ :" ++ :" Extending Dictionary directly with different types ++ :let d = {} ++ :py3 d=vim.bindeval('d') ++ :py3 d['1']='asd' ++ :py3 d['b']=[1, 2, f] ++ :py3 d['-1']={'a': 1} ++ :let dkeys = [] ++ :py3 dk=vim.bindeval('dkeys') ++ :py3 dkeys=d.keys() ++ :py3 dkeys.sort() ++ :py3 dk+=dkeys ++ :$put =string(dkeys) ++ :for [key, val] in sort(items(d)) ++ : $put =string(key) . ' : ' . string(val) ++ : unlet key val ++ :endfor ++ :" ++ :" removing items with del ++ :py3 del l[2] ++ :$put =string(l) ++ :let l = range(8) ++ :py3 l=vim.bindeval('l') ++ :try ++ : py3 del l[:3] ++ : py3 del l[1:] ++ :catch ++ : $put =v:exception ++ :endtry ++ :$put =string(l) ++ :" ++ :py3 del d['-1'] ++ :$put =string(d) ++ :" ++ :" removing items out of range: silently skip items that don't exist ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :" The following two ranges delete nothing as they match empty list: ++ :py3 del l[2:1] ++ :$put =string(l) ++ :py3 del l[2:2] ++ :$put =string(l) ++ :py3 del l[2:3] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 del l[2:4] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 del l[2:5] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 del l[2:6] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :" The following two ranges delete nothing as they match empty list: ++ :py3 del l[-1:2] ++ :$put =string(l) ++ :py3 del l[-2:2] ++ :$put =string(l) ++ :py3 del l[-3:2] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 del l[-4:2] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 del l[-5:2] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 del l[-6:2] ++ :$put =string(l) ++ :" ++ :" Slice assignment to a list ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 l[0:0]=['a'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 l[1:2]=['b'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 l[2:4]=['c'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 l[4:4]=['d'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 l[-1:2]=['e'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 l[-10:2]=['f'] ++ :$put =string(l) ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :py3 l[2:-10]=['g'] ++ :$put =string(l) ++ :let l = [] ++ :py3 l=vim.bindeval('l') ++ :py3 l[0:0]=['h'] ++ :$put =string(l) ++ :" ++ :" Locked variables ++ :let l = [0, 1, 2, 3] ++ :py3 l=vim.bindeval('l') ++ :lockvar! l ++ :py3 l[2]='i' ++ :$put =string(l) ++ :unlockvar! l ++ :" ++ :" Function calls ++ :function New(...) ++ :return ['NewStart']+a:000+['NewEnd'] ++ :endfunction ++ :function DictNew(...) dict ++ :return ['DictNewStart']+a:000+['DictNewEnd', self] ++ :endfunction ++ :let l=[function('New'), function('DictNew')] ++ :py3 l=vim.bindeval('l') ++ :py3 l.extend(list(l[0](1, 2, 3))) ++ :$put =string(l) ++ :py3 l.extend(list(l[1](1, 2, 3, self={'a': 'b'}))) ++ :$put =string(l) ++ :py3 l+=[l[0].name] ++ :$put =string(l) ++ :try ++ : py3 l[1](1, 2, 3) ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :delfunction New ++ :try ++ : py3 l[0](1, 2, 3) ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :if has('float') ++ : let l=[0.0] ++ : py3 l=vim.bindeval('l') ++ : py3 l.extend([0.0]) ++ : $put =string(l) ++ :else ++ : $put ='[0.0, 0.0]' ++ :endif ++ :" ++ :" py3eval() ++ :let l=py3eval('[0, 1, 2]') ++ :$put =string(l) ++ :let d=py3eval('{"a": "b", "c": 1, "d": ["e"]}') ++ :$put =sort(items(d)) ++ :try ++ : let undef=py3eval('undefined_name') ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :try ++ : let vim=py3eval('vim') ++ :catch ++ : $put =v:exception[:13] ++ :endtry ++ :if has('float') ++ : let f=py3eval('0.0') ++ : $put =string(f) ++ :else ++ : $put ='0.0' ++ :endif ++ :endfun ++ :" ++ :call Test() ++ :" ++ :delfunc Test ++ :call garbagecollect(1) ++ :" ++ :/^start:/,$wq! test.out ++ ENDTEST ++ ++ start: +*** ../vim-7.3.568/src/testdir/test87.ok 2012-06-20 20:19:31.000000000 +0200 +--- src/testdir/test87.ok 2012-06-20 18:01:02.000000000 +0200 +*************** +*** 0 **** +--- 1,47 ---- ++ start: ++ [1, 'as''d', [1, 2, function('strlen'), {'a': 1}]] ++ [1, 2, function('strlen'), {'a': 1}] ++ Vim(put):E684: ++ [0, 'as''d', [1, 2, function('strlen'), {'a': 1}]] ++ [0, function('strlen'), [1, 2, function('strlen'), {'a': 1}]] ++ ['-1', '1', 'b'] ++ '-1' : {'a': 1} ++ '1' : 'asd' ++ 'b' : [1, 2, function('strlen')] ++ [0, function('strlen')] ++ [3] ++ {'1': 'asd', 'b': [1, 2, function('strlen')]} ++ [0, 1, 2, 3] ++ [0, 1, 2, 3] ++ [0, 1, 3] ++ [0, 1] ++ [0, 1] ++ [0, 1] ++ [0, 1, 2, 3] ++ [0, 1, 2, 3] ++ [0, 2, 3] ++ [2, 3] ++ [2, 3] ++ [2, 3] ++ ['a', 0, 1, 2, 3] ++ [0, 'b', 2, 3] ++ [0, 1, 'c'] ++ [0, 1, 2, 3, 'd'] ++ [0, 1, 2, 'e', 3] ++ ['f', 2, 3] ++ [0, 1, 'g', 2, 3] ++ ['h'] ++ [0, 1, 2, 3] ++ [function('New'), function('DictNew'), 'NewStart', 1, 2, 3, 'NewEnd'] ++ [function('New'), function('DictNew'), 'NewStart', 1, 2, 3, 'NewEnd', 'DictNewStart', 1, 2, 3, 'DictNewEnd', {'a': 'b'}] ++ [function('New'), function('DictNew'), 'NewStart', 1, 2, 3, 'NewEnd', 'DictNewStart', 1, 2, 3, 'DictNewEnd', {'a': 'b'}, 'New'] ++ Vim(py3):E725: ++ Vim(py3):E117: ++ [0.0, 0.0] ++ [0, 1, 2] ++ ['a', 'b'] ++ ['c', 1] ++ ['d', ['e']] ++ Vim(let):E860: ++ Vim(let):E861: ++ 0.0 +*** ../vim-7.3.568/src/version.c 2012-06-29 12:35:40.000000000 +0200 +--- src/version.c 2012-06-29 12:47:03.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 569, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +69. Yahoo welcomes you with your own start page + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9cb502da53e4c38b2a7f21883445cf17ec36ae08 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:49 +0200 Subject: [PATCH 0391/3340] - patchlevel 570 --- 7.3.570 | 145 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 145 insertions(+) create mode 100644 7.3.570 diff --git a/7.3.570 b/7.3.570 new file mode 100644 index 00000000..c644194d --- /dev/null +++ b/7.3.570 @@ -0,0 +1,145 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.570 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.570 +Problem: ":vimgrep" does not obey 'wildignore'. +Solution: Apply 'wildignore' and 'suffixes' to ":vimgrep". (Ingo Karkat) +Files: src/ex_cmds2.c, src/proto/ex_cmds2.pro, src/quickfix.c, src/spell.c + + +*** ../vim-7.3.569/src/ex_cmds2.c 2012-06-20 15:48:53.000000000 +0200 +--- src/ex_cmds2.c 2012-06-29 12:43:34.000000000 +0200 +*************** +*** 1850,1871 **** + #if defined(FEAT_QUICKFIX) || defined(FEAT_SYN_HL) || defined(PROTO) + /* + * Parse a list of arguments (file names), expand them and return in +! * "fnames[fcountp]". + * Return FAIL or OK. + */ + int +! get_arglist_exp(str, fcountp, fnamesp) + char_u *str; + int *fcountp; + char_u ***fnamesp; + { + garray_T ga; + int i; + + if (get_arglist(&ga, str) == FAIL) + return FAIL; +! i = gen_expand_wildcards(ga.ga_len, (char_u **)ga.ga_data, +! fcountp, fnamesp, EW_FILE|EW_NOTFOUND); + ga_clear(&ga); + return i; + } +--- 1850,1877 ---- + #if defined(FEAT_QUICKFIX) || defined(FEAT_SYN_HL) || defined(PROTO) + /* + * Parse a list of arguments (file names), expand them and return in +! * "fnames[fcountp]". When "wig" is TRUE, removes files matching 'wildignore'. + * Return FAIL or OK. + */ + int +! get_arglist_exp(str, fcountp, fnamesp, wig) + char_u *str; + int *fcountp; + char_u ***fnamesp; ++ int wig; + { + garray_T ga; + int i; + + if (get_arglist(&ga, str) == FAIL) + return FAIL; +! if (wig == TRUE) +! i = expand_wildcards(ga.ga_len, (char_u **)ga.ga_data, +! fcountp, fnamesp, EW_FILE|EW_NOTFOUND); +! else +! i = gen_expand_wildcards(ga.ga_len, (char_u **)ga.ga_data, +! fcountp, fnamesp, EW_FILE|EW_NOTFOUND); +! + ga_clear(&ga); + return i; + } +*** ../vim-7.3.569/src/proto/ex_cmds2.pro 2011-05-19 18:26:34.000000000 +0200 +--- src/proto/ex_cmds2.pro 2012-06-29 12:43:49.000000000 +0200 +*************** +*** 42,48 **** + int check_fname __ARGS((void)); + int buf_write_all __ARGS((buf_T *buf, int forceit)); + int get_arglist __ARGS((garray_T *gap, char_u *str)); +! int get_arglist_exp __ARGS((char_u *str, int *fcountp, char_u ***fnamesp)); + void set_arglist __ARGS((char_u *str)); + void check_arg_idx __ARGS((win_T *win)); + void ex_args __ARGS((exarg_T *eap)); +--- 42,48 ---- + int check_fname __ARGS((void)); + int buf_write_all __ARGS((buf_T *buf, int forceit)); + int get_arglist __ARGS((garray_T *gap, char_u *str)); +! int get_arglist_exp __ARGS((char_u *str, int *fcountp, char_u ***fnamesp, int wig)); + void set_arglist __ARGS((char_u *str)); + void check_arg_idx __ARGS((win_T *win)); + void ex_args __ARGS((exarg_T *eap)); +*** ../vim-7.3.569/src/quickfix.c 2012-06-01 18:34:37.000000000 +0200 +--- src/quickfix.c 2012-06-29 12:43:49.000000000 +0200 +*************** +*** 3189,3195 **** + ; + + /* parse the list of arguments */ +! if (get_arglist_exp(p, &fcount, &fnames) == FAIL) + goto theend; + if (fcount == 0) + { +--- 3189,3195 ---- + ; + + /* parse the list of arguments */ +! if (get_arglist_exp(p, &fcount, &fnames, TRUE) == FAIL) + goto theend; + if (fcount == 0) + { +*** ../vim-7.3.569/src/spell.c 2012-06-01 17:49:51.000000000 +0200 +--- src/spell.c 2012-06-29 12:43:49.000000000 +0200 +*************** +*** 8553,8559 **** + } + + /* Expand all the remaining arguments (e.g., $VIMRUNTIME). */ +! if (get_arglist_exp(arg, &fcount, &fnames) == OK) + { + mkspell(fcount, fnames, ascii, eap->forceit, FALSE); + FreeWild(fcount, fnames); +--- 8553,8559 ---- + } + + /* Expand all the remaining arguments (e.g., $VIMRUNTIME). */ +! if (get_arglist_exp(arg, &fcount, &fnames, FALSE) == OK) + { + mkspell(fcount, fnames, ascii, eap->forceit, FALSE); + FreeWild(fcount, fnames); +*** ../vim-7.3.569/src/version.c 2012-06-29 12:54:32.000000000 +0200 +--- src/version.c 2012-06-29 12:56:12.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 570, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +70. ISDN lines are added to your house on a hourly basis + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c6304a1315bc138477ef0348bedc8e77bd8d037f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:49 +0200 Subject: [PATCH 0392/3340] - patchlevel 571 --- 7.3.571 | 117 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 117 insertions(+) create mode 100644 7.3.571 diff --git a/7.3.571 b/7.3.571 new file mode 100644 index 00000000..ad62ffc2 --- /dev/null +++ b/7.3.571 @@ -0,0 +1,117 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.571 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.571 +Problem: Duplicated condition. +Solution: Remove one. (Dominique Pelle) +Files: src/os_win32.c + + +*** ../vim-7.3.570/src/os_win32.c 2012-02-29 13:58:43.000000000 +0100 +--- src/os_win32.c 2012-06-29 13:10:54.000000000 +0200 +*************** +*** 308,314 **** + # ifndef GETTEXT_DLL + # define GETTEXT_DLL "libintl.dll" + # endif +! /* Dummy funcitons */ + static char *null_libintl_gettext(const char *); + static char *null_libintl_textdomain(const char *); + static char *null_libintl_bindtextdomain(const char *, const char *); +--- 308,314 ---- + # ifndef GETTEXT_DLL + # define GETTEXT_DLL "libintl.dll" + # endif +! /* Dummy functions */ + static char *null_libintl_gettext(const char *); + static char *null_libintl_textdomain(const char *); + static char *null_libintl_bindtextdomain(const char *, const char *); +*************** +*** 1409,1415 **** + + + /* +! * mch_inchar(): low-level input funcion. + * Get one or more characters from the keyboard or the mouse. + * If time == 0, do not wait for characters. + * If time == n, wait a short time for characters. +--- 1409,1415 ---- + + + /* +! * mch_inchar(): low-level input function. + * Get one or more characters from the keyboard or the mouse. + * If time == 0, do not wait for characters. + * If time == n, wait a short time for characters. +*************** +*** 3451,3464 **** + * to avoid to perform a blocking read */ + ret = PeekNamedPipe(g_hChildStd_OUT_Rd, /* pipe to query */ + NULL, /* optional buffer */ +! 0, /* buffe size */ + NULL, /* number of read bytes */ + &availableBytes, /* available bytes total */ + NULL); /* byteLeft */ + + repeatCount = 0; + /* We got real data in the pipe, read it */ +! while (ret != 0 && availableBytes > 0 && availableBytes > 0) + { + repeatCount++; + toRead = +--- 3451,3464 ---- + * to avoid to perform a blocking read */ + ret = PeekNamedPipe(g_hChildStd_OUT_Rd, /* pipe to query */ + NULL, /* optional buffer */ +! 0, /* buffer size */ + NULL, /* number of read bytes */ + &availableBytes, /* available bytes total */ + NULL); /* byteLeft */ + + repeatCount = 0; + /* We got real data in the pipe, read it */ +! while (ret != 0 && availableBytes > 0) + { + repeatCount++; + toRead = +*************** +*** 3638,3644 **** + NULL, /* Process security attributes */ + NULL, /* Thread security attributes */ + +! // this command can be litigeous, handle inheritence was + // deactivated for pending temp file, but, if we deactivate + // it, the pipes don't work for some reason. + TRUE, /* Inherit handles, first deactivated, +--- 3638,3644 ---- + NULL, /* Process security attributes */ + NULL, /* Thread security attributes */ + +! // this command can be litigious, handle inheritance was + // deactivated for pending temp file, but, if we deactivate + // it, the pipes don't work for some reason. + TRUE, /* Inherit handles, first deactivated, +*** ../vim-7.3.570/src/version.c 2012-06-29 12:57:03.000000000 +0200 +--- src/version.c 2012-06-29 13:12:31.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 571, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +71. You wonder how people walk + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e663e54606ffc8a7f95863c2a875b11e82f1ceca Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:50 +0200 Subject: [PATCH 0393/3340] - patchlevel 572 --- 7.3.572 | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.572 diff --git a/7.3.572 b/7.3.572 new file mode 100644 index 00000000..14fc127e --- /dev/null +++ b/7.3.572 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.572 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.572 +Problem: Duplicate statement in if and else. (Dominique Pelle) +Solution: Remove the condition and add a TODO. +Files: src/gui_xmebw.c + + +*** ../vim-7.3.571/src/gui_xmebw.c 2010-08-15 21:57:29.000000000 +0200 +--- src/gui_xmebw.c 2012-06-29 13:17:15.000000000 +0200 +*************** +*** 375,385 **** + + XGetGeometry(dpy, pix, &root, &x, &y, &width, &height, &border, &depth); + +! if (eb->enhancedbutton.label_location == (int)XmTOP +! || eb->enhancedbutton.label_location == (int)XmBOTTOM) +! shift = eb->primitive.shadow_thickness / 2; +! else +! shift = eb->primitive.shadow_thickness / 2; + + if (shift < 1) + shift = 1; +--- 375,382 ---- + + XGetGeometry(dpy, pix, &root, &x, &y, &width, &height, &border, &depth); + +! /* TODO: does the shift depend on label_location somehow? */ +! shift = eb->primitive.shadow_thickness / 2; + + if (shift < 1) + shift = 1; +*** ../vim-7.3.571/src/version.c 2012-06-29 13:13:59.000000000 +0200 +--- src/version.c 2012-06-29 13:18:41.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 572, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +72. Somebody at IRC just mentioned a way to obtain full motion video without + a PC using a wireless protocol called NTSC, you wonder how you never + heard about it + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 19a29638fc521467ce1c8e49c4387c35bee9a025 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:50 +0200 Subject: [PATCH 0394/3340] - patchlevel 573 --- 7.3.573 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.573 diff --git a/7.3.573 b/7.3.573 new file mode 100644 index 00000000..7734a76a --- /dev/null +++ b/7.3.573 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.573 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.573 +Problem: Using array index before bounds checking. +Solution: Swap the parts of the condition. (Dominique Pelle) +Files: src/ops.c + + +*** ../vim-7.3.572/src/ops.c 2012-06-13 17:28:51.000000000 +0200 +--- src/ops.c 2012-06-29 13:27:11.000000000 +0200 +*************** +*** 6458,6464 **** + long chars = 0; + int is_word = 0; + +! for (i = 0; line[i] && i < limit; ) + { + if (is_word) + { +--- 6458,6464 ---- + long chars = 0; + int is_word = 0; + +! for (i = 0; i < limit && line[i] != NUL; ) + { + if (is_word) + { +*** ../vim-7.3.572/src/version.c 2012-06-29 13:19:23.000000000 +0200 +--- src/version.c 2012-06-29 13:27:59.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 573, + /**/ + +-- +"Thou shalt not follow the Null Pointer, for at its end Chaos and +Madness lie." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5b6e205026a5a7132ae92cc2e9339fb142502e96 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:50 +0200 Subject: [PATCH 0395/3340] - patchlevel 574 --- 7.3.574 | 88 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 88 insertions(+) create mode 100644 7.3.574 diff --git a/7.3.574 b/7.3.574 new file mode 100644 index 00000000..e23d818f --- /dev/null +++ b/7.3.574 @@ -0,0 +1,88 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.574 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.574 +Problem: When pasting a register in the search command line a CTRL-L + character is not pasted. (Dominique Pelle) +Solution: Escape the CTRL-L. (Christian Brabandt) +Files: src/ex_getln.c + + +*** ../vim-7.3.573/src/ex_getln.c 2012-06-06 12:02:57.000000000 +0200 +--- src/ex_getln.c 2012-06-29 13:39:03.000000000 +0200 +*************** +*** 3133,3139 **** + else + #endif + c = *s++; +! if (cv == Ctrl_V || c == ESC || c == Ctrl_C || c == CAR || c == NL + #ifdef UNIX + || c == intr_char + #endif +--- 3133,3140 ---- + else + #endif + c = *s++; +! if (cv == Ctrl_V || c == ESC || c == Ctrl_C +! || c == CAR || c == NL || c == Ctrl_L + #ifdef UNIX + || c == intr_char + #endif +*************** +*** 4692,4698 **** + if (tab[i].ic) + regmatch.rm_ic = TRUE; + ret = ExpandGeneric(xp, ®match, num_file, file, +! tab[i].func, tab[i].escaped); + break; + } + } +--- 4693,4699 ---- + if (tab[i].ic) + regmatch.rm_ic = TRUE; + ret = ExpandGeneric(xp, ®match, num_file, file, +! tab[i].func, tab[i].escaped); + break; + } + } +*************** +*** 5125,5131 **** + vim_free(matches); + } + if (ga.ga_len == 0) +! return FAIL; + + /* Sort and remove duplicates which can happen when specifying multiple + * directories in dirnames. */ +--- 5126,5132 ---- + vim_free(matches); + } + if (ga.ga_len == 0) +! return FAIL; + + /* Sort and remove duplicates which can happen when specifying multiple + * directories in dirnames. */ +*** ../vim-7.3.573/src/version.c 2012-06-29 13:34:15.000000000 +0200 +--- src/version.c 2012-06-29 13:38:22.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 574, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +73. You give your dog used motherboards instead of bones + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 245678e68db12dcf19b02afea6b4dab1fdeb711c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:51 +0200 Subject: [PATCH 0396/3340] - patchlevel 575 --- 7.3.575 | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 7.3.575 diff --git a/7.3.575 b/7.3.575 new file mode 100644 index 00000000..f5d80d72 --- /dev/null +++ b/7.3.575 @@ -0,0 +1,60 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.575 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.575 +Problem: "ygt" tries to yank instead of giving an error. (Daniel Mueller) +Solution: Check for a pending operator. +Files: src/normal.c + + +*** ../vim-7.3.574/src/normal.c 2012-06-06 16:12:54.000000000 +0200 +--- src/normal.c 2012-06-29 13:50:26.000000000 +0200 +*************** +*** 8393,8402 **** + + #ifdef FEAT_WINDOWS + case 't': +! goto_tabpage((int)cap->count0); + break; + case 'T': +! goto_tabpage(-(int)cap->count1); + break; + #endif + +--- 8393,8404 ---- + + #ifdef FEAT_WINDOWS + case 't': +! if (!checkclearop(oap)) +! goto_tabpage((int)cap->count0); + break; + case 'T': +! if (!checkclearop(oap)) +! goto_tabpage(-(int)cap->count1); + break; + #endif + +*** ../vim-7.3.574/src/version.c 2012-06-29 13:44:37.000000000 +0200 +--- src/version.c 2012-06-29 13:52:01.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 575, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +74. Your most erotic dreams are about cybersex + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2229f14429ab41aabf6267ce376359863dc95dcc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:51 +0200 Subject: [PATCH 0397/3340] - patchlevel 576 --- 7.3.576 | 255 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 255 insertions(+) create mode 100644 7.3.576 diff --git a/7.3.576 b/7.3.576 new file mode 100644 index 00000000..bc226d90 --- /dev/null +++ b/7.3.576 @@ -0,0 +1,255 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.576 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.576 +Problem: Formatting of lists inside comments is not right yet. +Solution: Use another solution and add a test. (Tor Perkins) +Files: src/edit.c, src/misc1.c, src/testdir/test68.in, + src/testdir/test69.ok + + +*** ../vim-7.3.575/src/edit.c 2012-06-20 22:55:56.000000000 +0200 +--- src/edit.c 2012-06-29 14:10:36.000000000 +0200 +*************** +*** 6320,6333 **** + if (!(flags & INSCHAR_COM_LIST)) + { + /* +! * This section is for numeric lists w/o comments. If comment +! * indents are needed with numeric lists (formatoptions=nq), +! * then the INSCHAR_COM_LIST flag will cause the corresponding +! * OPENLINE_COM_LIST flag to be passed through to open_line() +! * (as seen above)... + */ + if (second_indent < 0 && has_format_option(FO_Q_NUMBER)) +! second_indent = get_number_indent(curwin->w_cursor.lnum -1); + if (second_indent >= 0) + { + #ifdef FEAT_VREPLACE +--- 6320,6334 ---- + if (!(flags & INSCHAR_COM_LIST)) + { + /* +! * This section is for auto-wrap of numeric lists. When not +! * in insert mode (i.e. format_lines()), the INSCHAR_COM_LIST +! * flag will be set and open_line() will handle it (as seen +! * above). The code here (and in get_number_indent()) will +! * recognize comments if needed... + */ + if (second_indent < 0 && has_format_option(FO_Q_NUMBER)) +! second_indent = +! get_number_indent(curwin->w_cursor.lnum - 1); + if (second_indent >= 0) + { + #ifdef FEAT_VREPLACE +*************** +*** 6336,6342 **** +--- 6337,6367 ---- + FALSE, NUL, TRUE); + else + #endif ++ #ifdef FEAT_COMMENTS ++ if (leader_len > 0 && second_indent - leader_len > 0) ++ { ++ int i; ++ int padding = second_indent - leader_len; ++ ++ /* We started at the first_line of a numbered list ++ * that has a comment. the open_line() function has ++ * inserted the proper comment leader and positioned ++ * the cursor at the end of the split line. Now we ++ * add the additional whitespace needed after the ++ * comment leader for the numbered list. */ ++ for (i = 0; i < padding; i++) ++ { ++ ins_str((char_u *)" "); ++ changed_bytes(curwin->w_cursor.lnum, leader_len); ++ } ++ } ++ else ++ { ++ #endif + (void)set_indent(second_indent, SIN_CHANGED); ++ #ifdef FEAT_COMMENTS ++ } ++ #endif + } + } + first_line = FALSE; +*** ../vim-7.3.575/src/misc1.c 2012-06-20 17:56:06.000000000 +0200 +--- src/misc1.c 2012-06-29 14:10:12.000000000 +0200 +*************** +*** 424,491 **** + colnr_T col; + pos_T pos; + + if (lnum > curbuf->b_ml.ml_line_count) + return -1; + pos.lnum = 0; + + #ifdef FEAT_COMMENTS +! if (has_format_option(FO_Q_COMS) && has_format_option(FO_Q_NUMBER)) +! { +! regmatch_T regmatch; +! int lead_len; /* length of comment leader */ +! + lead_len = get_leader_len(ml_get(lnum), NULL, FALSE, TRUE); +- regmatch.regprog = vim_regcomp(curbuf->b_p_flp, RE_MAGIC); +- if (regmatch.regprog != NULL) +- { +- regmatch.rm_ic = FALSE; +- +- /* vim_regexec() expects a pointer to a line. This lets us +- * start matching for the flp beyond any comment leader... */ +- if (vim_regexec(®match, ml_get(lnum) + lead_len, (colnr_T)0)) +- { +- pos.lnum = lnum; +- pos.col = (colnr_T)(*regmatch.endp - ml_get(lnum)); +- #ifdef FEAT_VIRTUALEDIT +- pos.coladd = 0; + #endif +! } +! } +! vim_free(regmatch.regprog); +! } +! else + { +! /* +! * What follows is the orig code that is not "comment aware"... +! * +! * I'm not sure if regmmatch_T (multi-match) is needed in this case. +! * It may be true that this section would work properly using the +! * regmatch_T code above, in which case, these two separate sections +! * should be consolidated w/ FEAT_COMMENTS making lead_len > 0... +! */ +! #endif +! regmmatch_T regmatch; + +! regmatch.regprog = vim_regcomp(curbuf->b_p_flp, RE_MAGIC); +! +! if (regmatch.regprog != NULL) + { +! regmatch.rmm_ic = FALSE; +! regmatch.rmm_maxcol = 0; +! if (vim_regexec_multi(®match, curwin, curbuf, +! lnum, (colnr_T)0, NULL)) +! { +! pos.lnum = regmatch.endpos[0].lnum + lnum; +! pos.col = regmatch.endpos[0].col; + #ifdef FEAT_VIRTUALEDIT +! pos.coladd = 0; + #endif +- } +- vim_free(regmatch.regprog); + } +- #ifdef FEAT_COMMENTS + } +! #endif + + if (pos.lnum == 0 || *ml_get_pos(&pos) == NUL) + return -1; +--- 424,458 ---- + colnr_T col; + pos_T pos; + ++ regmatch_T regmatch; ++ int lead_len = 0; /* length of comment leader */ ++ + if (lnum > curbuf->b_ml.ml_line_count) + return -1; + pos.lnum = 0; + + #ifdef FEAT_COMMENTS +! /* In format_lines() (i.e. not insert mode), fo+=q is needed too... */ +! if ((State & INSERT) || has_format_option(FO_Q_COMS)) + lead_len = get_leader_len(ml_get(lnum), NULL, FALSE, TRUE); + #endif +! regmatch.regprog = vim_regcomp(curbuf->b_p_flp, RE_MAGIC); +! if (regmatch.regprog != NULL) + { +! regmatch.rm_ic = FALSE; + +! /* vim_regexec() expects a pointer to a line. This lets us +! * start matching for the flp beyond any comment leader... */ +! if (vim_regexec(®match, ml_get(lnum) + lead_len, (colnr_T)0)) + { +! pos.lnum = lnum; +! pos.col = (colnr_T)(*regmatch.endp - ml_get(lnum)); + #ifdef FEAT_VIRTUALEDIT +! pos.coladd = 0; + #endif + } + } +! vim_free(regmatch.regprog); + + if (pos.lnum == 0 || *ml_get_pos(&pos) == NUL) + return -1; +*** ../vim-7.3.575/src/testdir/test68.in 2012-06-13 17:28:51.000000000 +0200 +--- src/testdir/test68.in 2012-06-29 14:27:27.000000000 +0200 +*************** +*** 52,57 **** +--- 52,68 ---- + + STARTTEST + /^{/+1 ++ :set tw=5 fo=tcn comments=:# ++ A bjA b ++ ENDTEST ++ ++ { ++ 1 a ++ # 1 a ++ } ++ ++ STARTTEST ++ /^{/+1 + :set tw=5 fo=qn comments=:# + gwap + ENDTEST +*************** +*** 83,88 **** +--- 94,107 ---- + } + + STARTTEST ++ /^#/ ++ :setl tw=12 fo=tqnc comments=:# ++ A foobar ++ ENDTEST ++ ++ # 1 xxxxx ++ ++ STARTTEST + :g/^STARTTEST/.,/^ENDTEST/d + :1;/^Results/,$wq! test.out + ENDTEST +*** ../vim-7.3.575/src/version.c 2012-06-29 13:56:01.000000000 +0200 +--- src/version.c 2012-06-29 15:03:10.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 576, + /**/ + +-- +Proof techniques #2: Proof by Oddity. + SAMPLE: To prove that horses have an infinite number of legs. +(1) Horses have an even number of legs. +(2) They have two legs in back and fore legs in front. +(3) This makes a total of six legs, which certainly is an odd number of + legs for a horse. +(4) But the only number that is both odd and even is infinity. +(5) Therefore, horses must have an infinite number of legs. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 275da1f0fc6c7cbb4d1133d8a84a803ed0dea490 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:51 +0200 Subject: [PATCH 0398/3340] - patchlevel 577 --- 7.3.577 | 273 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 273 insertions(+) create mode 100644 7.3.577 diff --git a/7.3.577 b/7.3.577 new file mode 100644 index 00000000..2929b22d --- /dev/null +++ b/7.3.577 @@ -0,0 +1,273 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.577 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.577 +Problem: Size of memory does not fit in 32 bit unsigned. +Solution: Use Kbyte instead of byte. Call GlobalMemoryStatusEx() instead of + GlobalMemoryStatus() when available. +Files: src/misc2.c, src/option.c, src/os_amiga.c, src/os_msdos.c, + src/os_win16.c, src/os_win32.c + + +*** ../vim-7.3.576/src/misc2.c 2012-02-29 13:58:43.000000000 +0100 +--- src/misc2.c 2012-06-29 15:30:54.000000000 +0200 +*************** +*** 815,820 **** +--- 815,821 ---- + #else + # define KEEP_ROOM (2 * 8192L) + #endif ++ #define KEEP_ROOM_KB (KEEP_ROOM / 1024L) + + /* + * Note: if unsigned is 16 bits we can only allocate up to 64K with alloc(). +*************** +*** 940,946 **** + allocated = 0; + # endif + /* 3. check for available memory: call mch_avail_mem() */ +! if (mch_avail_mem(TRUE) < KEEP_ROOM && !releasing) + { + free((char *)p); /* System is low... no go! */ + p = NULL; +--- 941,947 ---- + allocated = 0; + # endif + /* 3. check for available memory: call mch_avail_mem() */ +! if (mch_avail_mem(TRUE) < KEEP_ROOM_KB && !releasing) + { + free((char *)p); /* System is low... no go! */ + p = NULL; +*** ../vim-7.3.576/src/option.c 2012-03-28 19:58:34.000000000 +0200 +--- src/option.c 2012-06-29 15:31:46.000000000 +0200 +*************** +*** 3154,3160 **** + { + #ifdef HAVE_AVAIL_MEM + /* Use amount of memory available at this moment. */ +! n = (mch_avail_mem(FALSE) >> 11); + #else + # ifdef HAVE_TOTAL_MEM + /* Use amount of memory available to Vim. */ +--- 3154,3160 ---- + { + #ifdef HAVE_AVAIL_MEM + /* Use amount of memory available at this moment. */ +! n = (mch_avail_mem(FALSE) >> 1); + #else + # ifdef HAVE_TOTAL_MEM + /* Use amount of memory available to Vim. */ +*************** +*** 6702,6708 **** + { + for (s = *varp; *s;) + { +! while(*s == ',' || *s == ' ') + s++; + if (!*s) + break; +--- 6702,6708 ---- + { + for (s = *varp; *s;) + { +! while (*s == ',' || *s == ' ') + s++; + if (!*s) + break; +*************** +*** 7391,7397 **** + new_unnamed |= CLIP_UNNAMED; + p += 7; + } +! else if (STRNCMP(p, "unnamedplus", 11) == 0 + && (p[11] == ',' || p[11] == NUL)) + { + new_unnamed |= CLIP_UNNAMED_PLUS; +--- 7391,7397 ---- + new_unnamed |= CLIP_UNNAMED; + p += 7; + } +! else if (STRNCMP(p, "unnamedplus", 11) == 0 + && (p[11] == ',' || p[11] == NUL)) + { + new_unnamed |= CLIP_UNNAMED_PLUS; +*** ../vim-7.3.576/src/os_amiga.c 2011-10-20 18:24:16.000000000 +0200 +--- src/os_amiga.c 2012-06-29 15:33:59.000000000 +0200 +*************** +*** 191,206 **** + } + + /* +! * Return amount of memory still available. + */ + long_u + mch_avail_mem(special) + int special; + { + #ifdef __amigaos4__ +! return (long_u)AvailMem(MEMF_ANY); + #else +! return (long_u)AvailMem(special ? (long)MEMF_CHIP : (long)MEMF_ANY); + #endif + } + +--- 191,206 ---- + } + + /* +! * Return amount of memory still available in Kbyte. + */ + long_u + mch_avail_mem(special) + int special; + { + #ifdef __amigaos4__ +! return (long_u)AvailMem(MEMF_ANY) >> 10; + #else +! return (long_u)(AvailMem(special ? (long)MEMF_CHIP : (long)MEMF_ANY)) >> 10; + #endif + } + +*** ../vim-7.3.576/src/os_msdos.c 2011-06-19 01:14:22.000000000 +0200 +--- src/os_msdos.c 2012-06-29 15:33:26.000000000 +0200 +*************** +*** 550,564 **** + #endif + + /* +! * Return amount of memory currently available. + */ + long_u + mch_avail_mem(int special) + { + #ifdef DJGPP +! return _go32_dpmi_remaining_virtual_memory(); + #else +! return coreleft(); + #endif + } + +--- 550,564 ---- + #endif + + /* +! * Return amount of memory currently available in Kbyte. + */ + long_u + mch_avail_mem(int special) + { + #ifdef DJGPP +! return _go32_dpmi_remaining_virtual_memory() >> 10; + #else +! return coreleft() >> 10; + #endif + } + +*** ../vim-7.3.576/src/os_win16.c 2011-10-20 18:24:16.000000000 +0200 +--- src/os_win16.c 2012-06-29 15:34:18.000000000 +0200 +*************** +*** 379,391 **** + + + /* +! * How much memory is available? + */ + long_u + mch_avail_mem( + int special) + { +! return GetFreeSpace(0); + } + + +--- 379,391 ---- + + + /* +! * How much memory is available in Kbyte? + */ + long_u + mch_avail_mem( + int special) + { +! return GetFreeSpace(0) >> 10; + } + + +*** ../vim-7.3.576/src/os_win32.c 2012-06-29 13:13:59.000000000 +0200 +--- src/os_win32.c 2012-06-29 15:39:52.000000000 +0200 +*************** +*** 4992,5009 **** + + + /* +! * How much memory is available? + * Return sum of available physical and page file memory. + */ + /*ARGSUSED*/ + long_u + mch_avail_mem(int special) + { +! MEMORYSTATUS ms; + +! ms.dwLength = sizeof(MEMORYSTATUS); +! GlobalMemoryStatus(&ms); +! return (long_u) (ms.dwAvailPhys + ms.dwAvailPageFile); + } + + #ifdef FEAT_MBYTE +--- 4992,5020 ---- + + + /* +! * How much memory is available in Kbyte? + * Return sum of available physical and page file memory. + */ + /*ARGSUSED*/ + long_u + mch_avail_mem(int special) + { +! if (g_PlatformId != VER_PLATFORM_WIN32_NT) +! { +! MEMORYSTATUS ms; + +! ms.dwLength = sizeof(MEMORYSTATUS); +! GlobalMemoryStatus(&ms); +! return (long_u)((ms.dwAvailPhys + ms.dwAvailPageFile) >> 10); +! } +! else +! { +! MEMORYSTATUSEX ms; +! +! ms.dwLength = sizeof(MEMORYSTATUSEX); +! GlobalMemoryStatusEx(&ms); +! return (long_u)((ms.ullAvailPhys + ms.ullAvailPageFile) >> 10); +! } + } + + #ifdef FEAT_MBYTE +*** ../vim-7.3.576/src/version.c 2012-06-29 15:04:34.000000000 +0200 +--- src/version.c 2012-06-29 15:45:44.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 577, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +75. You start wondering whether you could actually upgrade your brain + with a Pentium Pro microprocessor 80. The upgrade works just fine. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 03c1749a1a07ad0ca79e99de62a5ab01a8760125 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:52 +0200 Subject: [PATCH 0399/3340] - patchlevel 578 --- 7.3.578 | 80 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 7.3.578 diff --git a/7.3.578 b/7.3.578 new file mode 100644 index 00000000..9b0aedd2 --- /dev/null +++ b/7.3.578 @@ -0,0 +1,80 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.578 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.578 +Problem: Misplaced declaration. +Solution: Move declaration to start of block. +Files: src/if_py_both.h + + +*** ../vim-7.3.577/src/if_py_both.h 2012-06-29 12:54:32.000000000 +0200 +--- src/if_py_both.h 2012-06-29 16:15:29.000000000 +0200 +*************** +*** 818,838 **** + + if (valObject == NULL) + { + if (di == NULL) + { + PyErr_SetString(PyExc_IndexError, _("no such key in dictionary")); + return -1; + } +! hashitem_T *hi = hash_find(&d->dv_hashtab, di->di_key); + hash_remove(&d->dv_hashtab, hi); + dictitem_free(di); + return 0; + } + + if (ConvertFromPyObject(valObject, &tv) == -1) +- { + return -1; +- } + + if (di == NULL) + { +--- 818,838 ---- + + if (valObject == NULL) + { ++ hashitem_T *hi; ++ + if (di == NULL) + { + PyErr_SetString(PyExc_IndexError, _("no such key in dictionary")); + return -1; + } +! hi = hash_find(&d->dv_hashtab, di->di_key); + hash_remove(&d->dv_hashtab, hi); + dictitem_free(di); + return 0; + } + + if (ConvertFromPyObject(valObject, &tv) == -1) + return -1; + + if (di == NULL) + { +*** ../vim-7.3.577/src/version.c 2012-06-29 15:51:26.000000000 +0200 +--- src/version.c 2012-06-29 16:18:10.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 578, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +77. The phone company asks you to test drive their new PBX system + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From cfbb2dadc54e0be0f09c3635b13f9a15035494d0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:52 +0200 Subject: [PATCH 0400/3340] - patchlevel 579 --- 7.3.579 | 232 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 232 insertions(+) create mode 100644 7.3.579 diff --git a/7.3.579 b/7.3.579 new file mode 100644 index 00000000..ed618fe7 --- /dev/null +++ b/7.3.579 @@ -0,0 +1,232 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.579 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.579 (after 7.3.569) +Problem: Can't compile with Python 2.5. +Solution: Use PyCObject when Capsules are not available. +Files: src/if_py_both.h, src/if_python.c, src/if_python3.c + + +*** ../vim-7.3.578/src/if_py_both.h 2012-06-29 16:19:46.000000000 +0200 +--- src/if_py_both.h 2012-06-29 16:15:29.000000000 +0200 +*************** +*** 56,62 **** + /* name, function, calling, documentation */ + {"write", OutputWrite, 1, ""}, + {"writelines", OutputWritelines, 1, ""}, +! {"flush", OutputFlush, 1, ""}, + { NULL, NULL, 0, NULL} + }; + +--- 56,62 ---- + /* name, function, calling, documentation */ + {"write", OutputWrite, 1, ""}, + {"writelines", OutputWritelines, 1, ""}, +! {"flush", OutputFlush, 1, ""}, + { NULL, NULL, 0, NULL} + }; + +*************** +*** 506,513 **** + /* name, function, calling, documentation */ + {"command", VimCommand, 1, "Execute a Vim ex-mode command" }, + {"eval", VimEval, 1, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, 1, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, 1, "Screen string width, counts as having width 1"}, + { NULL, NULL, 0, NULL } + }; + +--- 506,513 ---- + /* name, function, calling, documentation */ + {"command", VimCommand, 1, "Execute a Vim ex-mode command" }, + {"eval", VimEval, 1, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, 1, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, 1, "Screen string width, counts as having width 1"}, + { NULL, NULL, 0, NULL } + }; + +*************** +*** 2432,2448 **** +--- 2432,2463 ---- + convert_dl(PyObject *obj, typval_T *tv, + pytotvfunc py_to_tv, PyObject *lookupDict) + { ++ # ifdef PY_USE_CAPSULE + PyObject *capsule; ++ # else ++ PyCObject *cobject; ++ # endif + char hexBuf[sizeof(void *) * 2 + 3]; + + sprintf(hexBuf, "%p", obj); + ++ # ifdef PY_USE_CAPSULE + capsule = PyDict_GetItemString(lookupDict, hexBuf); + if (capsule == NULL) ++ # else ++ cobject = (PyCObject *)PyDict_GetItemString(lookupDict, hexBuf); ++ if (cobject == NULL) ++ # endif + { ++ # ifdef PY_USE_CAPSULE + capsule = PyCapsule_New(tv, NULL, NULL); + PyDict_SetItemString(lookupDict, hexBuf, capsule); + Py_DECREF(capsule); ++ # else ++ cobject = PyCObject_FromVoidPtr(tv, NULL); ++ PyDict_SetItemString(lookupDict, hexBuf, cobject); ++ Py_DECREF(cobject); ++ # endif + if (py_to_tv(obj, tv, lookupDict) == -1) + { + tv->v_type = VAR_UNKNOWN; +*************** +*** 2458,2464 **** + } + else + { +! typval_T *v = PyCapsule_GetPointer(capsule, NULL); + copy_tv(v, tv); + } + return 0; +--- 2473,2485 ---- + } + else + { +! typval_T *v; +! +! # ifdef PY_USE_CAPSULE +! v = PyCapsule_GetPointer(capsule, NULL); +! # else +! v = PyCObject_AsVoidPtr(cobject); +! # endif + copy_tv(v, tv); + } + return 0; +*** ../vim-7.3.578/src/if_python.c 2012-06-29 12:54:32.000000000 +0200 +--- src/if_python.c 2012-06-29 16:17:44.000000000 +0200 +*************** +*** 71,76 **** +--- 71,80 ---- + # define PySequenceMethods Py_ssize_t + #endif + ++ #if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02070000 ++ # define PY_USE_CAPSULE ++ #endif ++ + #if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02050000 + # define PyInt Py_ssize_t + # define PyInquiry lenfunc +*************** +*** 220,227 **** + # define PyObject_Malloc dll_PyObject_Malloc + # define PyObject_Free dll_PyObject_Free + # endif +! # define PyCapsule_New dll_PyCapsule_New +! # define PyCapsule_GetPointer dll_PyCapsule_GetPointer + + /* + * Pointers for dynamic link +--- 224,236 ---- + # define PyObject_Malloc dll_PyObject_Malloc + # define PyObject_Free dll_PyObject_Free + # endif +! # ifdef PY_USE_CAPSULE +! # define PyCapsule_New dll_PyCapsule_New +! # define PyCapsule_GetPointer dll_PyCapsule_GetPointer +! # else +! # define PyCObject_FromVoidPtr dll_PyCObject_FromVoidPtr +! # define PyCObject_AsVoidPtr dll_PyCObject_AsVoidPtr +! # endif + + /* + * Pointers for dynamic link +*************** +*** 309,316 **** +--- 318,330 ---- + static void* (*dll_PyObject_Malloc)(size_t); + static void (*dll_PyObject_Free)(void*); + # endif ++ # ifdef PY_USE_CAPSULE + static PyObject* (*dll_PyCapsule_New)(void *, char *, PyCapsule_Destructor); + static void* (*dll_PyCapsule_GetPointer)(PyObject *, char *); ++ # else ++ static PyCObject* (*dll_PyCObject_FromVoidPtr)(void *cobj, void (*destr)(void *)); ++ static void* (*dll_PyCObject_AsVoidPtr)(PyCObject *); ++ # endif + + static HINSTANCE hinstPython = 0; /* Instance of python.dll */ + +*************** +*** 403,409 **** + {"PyType_Ready", (PYTHON_PROC*)&dll_PyType_Ready}, + {"Py_BuildValue", (PYTHON_PROC*)&dll_Py_BuildValue}, + {"Py_FindMethod", (PYTHON_PROC*)&dll_Py_FindMethod}, +! # if (PY_VERSION_HEX >= 0x02050000) && SIZEOF_SIZE_T != SIZEOF_INT + {"Py_InitModule4_64", (PYTHON_PROC*)&dll_Py_InitModule4}, + # else + {"Py_InitModule4", (PYTHON_PROC*)&dll_Py_InitModule4}, +--- 417,424 ---- + {"PyType_Ready", (PYTHON_PROC*)&dll_PyType_Ready}, + {"Py_BuildValue", (PYTHON_PROC*)&dll_Py_BuildValue}, + {"Py_FindMethod", (PYTHON_PROC*)&dll_Py_FindMethod}, +! # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02050000 \ +! && SIZEOF_SIZE_T != SIZEOF_INT + {"Py_InitModule4_64", (PYTHON_PROC*)&dll_Py_InitModule4}, + # else + {"Py_InitModule4", (PYTHON_PROC*)&dll_Py_InitModule4}, +*************** +*** 424,431 **** +--- 439,451 ---- + {"PyObject_Malloc", (PYTHON_PROC*)&dll_PyObject_Malloc}, + {"PyObject_Free", (PYTHON_PROC*)&dll_PyObject_Free}, + # endif ++ # ifdef PY_USE_CAPSULE + {"PyCapsule_New", (PYTHON_PROC*)&dll_PyCapsule_New}, + {"PyCapsule_GetPointer", (PYTHON_PROC*)&dll_PyCapsule_GetPointer}, ++ # else ++ {"PyCObject_FromVoidPtr", (PYTHON_PROC*)&dll_PyCObject_FromVoidPtr}, ++ {"PyCObject_AsVoidPtr", (PYTHON_PROC*)&dll_PyCObject_AsVoidPtr}, ++ # endif + {"", NULL}, + }; + +*** ../vim-7.3.578/src/if_python3.c 2012-06-29 12:54:32.000000000 +0200 +--- src/if_python3.c 2012-06-29 16:16:54.000000000 +0200 +*************** +*** 75,80 **** +--- 75,83 ---- + # define CODEC_ERROR_HANDLER NULL + #endif + ++ /* Python 3 does not support CObjects, always use Capsules */ ++ #define PY_USE_CAPSULE ++ + #define PyInt Py_ssize_t + #define PyString_Check(obj) PyUnicode_Check(obj) + #define PyString_AsBytes(obj) PyUnicode_AsEncodedString(obj, (char *)ENC_OPT, CODEC_ERROR_HANDLER) +*** ../vim-7.3.578/src/version.c 2012-06-29 16:19:46.000000000 +0200 +--- src/version.c 2012-06-29 16:21:25.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 579, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +78. You find yourself dialing IP numbers on the phone. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6db1a8bceb19f33985b6c78c909fb93da66606c5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:52 +0200 Subject: [PATCH 0401/3340] - patchlevel 580 --- 7.3.580 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.580 diff --git a/7.3.580 b/7.3.580 new file mode 100644 index 00000000..c2c2a537 --- /dev/null +++ b/7.3.580 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.580 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.580 +Problem: Warning on 64 bit MS-Windows. +Solution: Add type cast. (Mike Williams) +Files: src/if_py_both.h + + +*** ../vim-7.3.579/src/if_py_both.h 2012-06-29 16:28:23.000000000 +0200 +--- src/if_py_both.h 2012-06-29 17:49:59.000000000 +0200 +*************** +*** 495,501 **** + if (!PyArg_ParseTuple(args, "s", &expr)) + return NULL; + +! return PyLong_FromLong(mb_string2cells((char_u *)expr, STRLEN(expr))); + } + + /* +--- 495,501 ---- + if (!PyArg_ParseTuple(args, "s", &expr)) + return NULL; + +! return PyLong_FromLong(mb_string2cells((char_u *)expr, (int)STRLEN(expr))); + } + + /* +*** ../vim-7.3.579/src/version.c 2012-06-29 16:28:23.000000000 +0200 +--- src/version.c 2012-06-29 17:50:36.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 580, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +79. All of your most erotic dreams have a scrollbar at the right side. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f1fbcb2587a721e36085dc4b3e818d6bd2309b99 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:53 +0200 Subject: [PATCH 0402/3340] - patchlevel 581 --- 7.3.581 | 117 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 117 insertions(+) create mode 100644 7.3.581 diff --git a/7.3.581 b/7.3.581 new file mode 100644 index 00000000..55300303 --- /dev/null +++ b/7.3.581 @@ -0,0 +1,117 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.581 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.581 +Problem: Problems compiling with Python. +Solution: Pick UCS2 or UCS4 function at runtime. (lilydjwg) +Files: src/if_python.c + + +*** ../vim-7.3.580/src/if_python.c 2012-06-29 16:28:23.000000000 +0200 +--- src/if_python.c 2012-06-29 19:10:53.000000000 +0200 +*************** +*** 196,202 **** + # define PyString_Size dll_PyString_Size + # define PyString_Type (*dll_PyString_Type) + # define PyUnicode_Type (*dll_PyUnicode_Type) +! # define PyUnicodeUCS4_AsEncodedString (*dll_PyUnicodeUCS4_AsEncodedString) + # define PyFloat_AsDouble dll_PyFloat_AsDouble + # define PyFloat_FromDouble dll_PyFloat_FromDouble + # define PyFloat_Type (*dll_PyFloat_Type) +--- 196,203 ---- + # define PyString_Size dll_PyString_Size + # define PyString_Type (*dll_PyString_Type) + # define PyUnicode_Type (*dll_PyUnicode_Type) +! # undef PyUnicode_AsEncodedString +! # define PyUnicode_AsEncodedString py_PyUnicode_AsEncodedString + # define PyFloat_AsDouble dll_PyFloat_AsDouble + # define PyFloat_FromDouble dll_PyFloat_FromDouble + # define PyFloat_Type (*dll_PyFloat_Type) +*************** +*** 290,296 **** + static PyInt(*dll_PyString_Size)(PyObject *); + static PyTypeObject* dll_PyString_Type; + static PyTypeObject* dll_PyUnicode_Type; +! static PyObject *(*PyUnicodeUCS4_AsEncodedString)(PyObject *, char *, char *); + static double(*dll_PyFloat_AsDouble)(PyObject *); + static PyObject*(*dll_PyFloat_FromDouble)(double); + static PyTypeObject* dll_PyFloat_Type; +--- 291,297 ---- + static PyInt(*dll_PyString_Size)(PyObject *); + static PyTypeObject* dll_PyString_Type; + static PyTypeObject* dll_PyUnicode_Type; +! static PyObject *(*py_PyUnicode_AsEncodedString)(PyObject *, char *, char *); + static double(*dll_PyFloat_AsDouble)(PyObject *); + static PyObject*(*dll_PyFloat_FromDouble)(double); + static PyTypeObject* dll_PyFloat_Type; +*************** +*** 406,412 **** + {"PyString_Size", (PYTHON_PROC*)&dll_PyString_Size}, + {"PyString_Type", (PYTHON_PROC*)&dll_PyString_Type}, + {"PyUnicode_Type", (PYTHON_PROC*)&dll_PyUnicode_Type}, +- {"PyUnicodeUCS4_AsEncodedString", (PYTHON_PROC*)&dll_PyUnicodeUCS4_AsEncodedString}, + {"PyFloat_Type", (PYTHON_PROC*)&dll_PyFloat_Type}, + {"PyFloat_AsDouble", (PYTHON_PROC*)&dll_PyFloat_AsDouble}, + {"PyFloat_FromDouble", (PYTHON_PROC*)&dll_PyFloat_FromDouble}, +--- 407,412 ---- +*************** +*** 471,476 **** +--- 471,477 ---- + python_runtime_link_init(char *libname, int verbose) + { + int i; ++ void *ucs_as_encoded_string; + + #if !(defined(PY_NO_RTLD_GLOBAL) && defined(PY3_NO_RTLD_GLOBAL)) && defined(UNIX) && defined(FEAT_PYTHON3) + /* Can't have Python and Python3 loaded at the same time. +*************** +*** 506,511 **** +--- 507,531 ---- + return FAIL; + } + } ++ ++ /* Load unicode functions separately as only the ucs2 or the ucs4 functions ++ * will be present in the library. */ ++ ucs_as_encoded_string = symbol_from_dll(hinstPython, ++ "PyUnicodeUCS2_AsEncodedString"); ++ if (ucs_as_encoded_string == NULL) ++ ucs_as_encoded_string = symbol_from_dll(hinstPython, ++ "PyUnicodeUCS4_AsEncodedString"); ++ if (ucs_as_encoded_string != NULL) ++ py_PyUnicode_AsEncodedString = ucs_as_encoded_string; ++ else ++ { ++ close_dll(hinstPython); ++ hinstPython = 0; ++ if (verbose) ++ EMSG2(_(e_loadfunc), "PyUnicode_UCSX_*"); ++ return FAIL; ++ } ++ + return OK; + } + +*** ../vim-7.3.580/src/version.c 2012-06-29 17:51:58.000000000 +0200 +--- src/version.c 2012-06-29 19:13:47.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 581, + /**/ + +-- +ASCII stupid question, get a stupid ANSI. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 15dc315c15222b010279c946cb06c4e9be4420c9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:53 +0200 Subject: [PATCH 0403/3340] - patchlevel 582 --- 7.3.582 | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 7.3.582 diff --git a/7.3.582 b/7.3.582 new file mode 100644 index 00000000..4e118a7d --- /dev/null +++ b/7.3.582 @@ -0,0 +1,61 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.582 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.582 (after 7.3.576) +Problem: Missing parts of the test OK file. +Solution: Add the missing parts. +Files: src/testdir/test68.ok + + +*** ../vim-7.3.581/src/testdir/test68.ok 2012-06-13 17:28:51.000000000 +0200 +--- src/testdir/test68.ok 2012-06-29 15:00:13.000000000 +0200 +*************** +*** 35,40 **** +--- 35,48 ---- + + + { ++ 1 a ++ b ++ # 1 a ++ # b ++ } ++ ++ ++ { + # 1 a + # b + } +*************** +*** 48,50 **** +--- 56,62 ---- + + { 1aa ^^2bb } + ++ ++ # 1 xxxxx ++ # foobar ++ +*** ../vim-7.3.581/src/version.c 2012-06-29 19:14:48.000000000 +0200 +--- src/version.c 2012-06-29 23:57:43.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 582, + /**/ + +-- +If your nose runs, and your feet smell, you might be upside down. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1cdf84aa302c87dbe224f71b369eef64f93d37da Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:53 +0200 Subject: [PATCH 0404/3340] - patchlevel 583 --- 7.3.583 | 79 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 79 insertions(+) create mode 100644 7.3.583 diff --git a/7.3.583 b/7.3.583 new file mode 100644 index 00000000..2ea7f9d2 --- /dev/null +++ b/7.3.583 @@ -0,0 +1,79 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.583 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.583 +Problem: PyObject_NextNotImplemented is not defined before Python 2.7. + (Danek Duvall) +Solution: Add #ifdefs. +Files: src/if_python.c + + +*** ../vim-7.3.582/src/if_python.c 2012-06-29 19:14:48.000000000 +0200 +--- src/if_python.c 2012-06-30 12:59:38.000000000 +0200 +*************** +*** 214,220 **** + # define Py_Finalize dll_Py_Finalize + # define Py_IsInitialized dll_Py_IsInitialized + # define _PyObject_New dll__PyObject_New +! # define _PyObject_NextNotImplemented (*dll__PyObject_NextNotImplemented) + # define _Py_NoneStruct (*dll__Py_NoneStruct) + # define PyObject_Init dll__PyObject_Init + # define PyObject_GetIter dll_PyObject_GetIter +--- 214,222 ---- + # define Py_Finalize dll_Py_Finalize + # define Py_IsInitialized dll_Py_IsInitialized + # define _PyObject_New dll__PyObject_New +! # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02070000 +! # define _PyObject_NextNotImplemented (*dll__PyObject_NextNotImplemented) +! # endif + # define _Py_NoneStruct (*dll__Py_NoneStruct) + # define PyObject_Init dll__PyObject_Init + # define PyObject_GetIter dll_PyObject_GetIter +*************** +*** 310,316 **** +--- 312,320 ---- + static PyObject*(*dll__PyObject_New)(PyTypeObject *, PyObject *); + static PyObject*(*dll__PyObject_Init)(PyObject *, PyTypeObject *); + static PyObject* (*dll_PyObject_GetIter)(PyObject *); ++ # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02070000 + static iternextfunc dll__PyObject_NextNotImplemented; ++ # endif + static PyObject* dll__Py_NoneStruct; + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + static int (*dll_PyType_IsSubtype)(PyTypeObject *, PyTypeObject *); +*************** +*** 430,436 **** +--- 434,442 ---- + {"_PyObject_New", (PYTHON_PROC*)&dll__PyObject_New}, + {"PyObject_Init", (PYTHON_PROC*)&dll__PyObject_Init}, + {"PyObject_GetIter", (PYTHON_PROC*)&dll_PyObject_GetIter}, ++ # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02070000 + {"_PyObject_NextNotImplemented", (PYTHON_PROC*)&dll__PyObject_NextNotImplemented}, ++ # endif + {"_Py_NoneStruct", (PYTHON_PROC*)&dll__Py_NoneStruct}, + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + {"PyType_IsSubtype", (PYTHON_PROC*)&dll_PyType_IsSubtype}, +*** ../vim-7.3.582/src/version.c 2012-06-29 23:57:50.000000000 +0200 +--- src/version.c 2012-06-30 13:20:46.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 583, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +90. Instead of calling you to dinner, your spouse sends e-mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6d6458a13a7f9795769d3376cbdc57598775abac Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:54 +0200 Subject: [PATCH 0405/3340] - patchlevel 584 --- 7.3.584 | 134 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 134 insertions(+) create mode 100644 7.3.584 diff --git a/7.3.584 b/7.3.584 new file mode 100644 index 00000000..d7f1bdeb --- /dev/null +++ b/7.3.584 @@ -0,0 +1,134 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.584 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.584 +Problem: PyCObject is not always defined. +Solution: Use PyObject instead. +Files: src/if_py_both.h, src/if_python.c + + +*** ../vim-7.3.583/src/if_py_both.h 2012-06-29 17:51:58.000000000 +0200 +--- src/if_py_both.h 2012-06-30 13:25:24.000000000 +0200 +*************** +*** 2432,2463 **** + convert_dl(PyObject *obj, typval_T *tv, + pytotvfunc py_to_tv, PyObject *lookupDict) + { +- # ifdef PY_USE_CAPSULE + PyObject *capsule; +- # else +- PyCObject *cobject; +- # endif + char hexBuf[sizeof(void *) * 2 + 3]; + + sprintf(hexBuf, "%p", obj); + + # ifdef PY_USE_CAPSULE + capsule = PyDict_GetItemString(lookupDict, hexBuf); +- if (capsule == NULL) + # else +! cobject = (PyCObject *)PyDict_GetItemString(lookupDict, hexBuf); +! if (cobject == NULL) + # endif + { + # ifdef PY_USE_CAPSULE + capsule = PyCapsule_New(tv, NULL, NULL); +- PyDict_SetItemString(lookupDict, hexBuf, capsule); +- Py_DECREF(capsule); + # else +! cobject = PyCObject_FromVoidPtr(tv, NULL); +! PyDict_SetItemString(lookupDict, hexBuf, cobject); +! Py_DECREF(cobject); + # endif + if (py_to_tv(obj, tv, lookupDict) == -1) + { + tv->v_type = VAR_UNKNOWN; +--- 2432,2456 ---- + convert_dl(PyObject *obj, typval_T *tv, + pytotvfunc py_to_tv, PyObject *lookupDict) + { + PyObject *capsule; + char hexBuf[sizeof(void *) * 2 + 3]; + + sprintf(hexBuf, "%p", obj); + + # ifdef PY_USE_CAPSULE + capsule = PyDict_GetItemString(lookupDict, hexBuf); + # else +! capsule = (PyObject *)PyDict_GetItemString(lookupDict, hexBuf); + # endif ++ if (capsule == NULL) + { + # ifdef PY_USE_CAPSULE + capsule = PyCapsule_New(tv, NULL, NULL); + # else +! capsule = PyCObject_FromVoidPtr(tv, NULL); + # endif ++ PyDict_SetItemString(lookupDict, hexBuf, capsule); ++ Py_DECREF(capsule); + if (py_to_tv(obj, tv, lookupDict) == -1) + { + tv->v_type = VAR_UNKNOWN; +*************** +*** 2478,2484 **** + # ifdef PY_USE_CAPSULE + v = PyCapsule_GetPointer(capsule, NULL); + # else +! v = PyCObject_AsVoidPtr(cobject); + # endif + copy_tv(v, tv); + } +--- 2471,2477 ---- + # ifdef PY_USE_CAPSULE + v = PyCapsule_GetPointer(capsule, NULL); + # else +! v = PyCObject_AsVoidPtr(capsule); + # endif + copy_tv(v, tv); + } +*** ../vim-7.3.583/src/if_python.c 2012-06-30 13:21:03.000000000 +0200 +--- src/if_python.c 2012-06-30 13:23:22.000000000 +0200 +*************** +*** 327,334 **** + static PyObject* (*dll_PyCapsule_New)(void *, char *, PyCapsule_Destructor); + static void* (*dll_PyCapsule_GetPointer)(PyObject *, char *); + # else +! static PyCObject* (*dll_PyCObject_FromVoidPtr)(void *cobj, void (*destr)(void *)); +! static void* (*dll_PyCObject_AsVoidPtr)(PyCObject *); + # endif + + static HINSTANCE hinstPython = 0; /* Instance of python.dll */ +--- 327,334 ---- + static PyObject* (*dll_PyCapsule_New)(void *, char *, PyCapsule_Destructor); + static void* (*dll_PyCapsule_GetPointer)(PyObject *, char *); + # else +! static PyObject* (*dll_PyCObject_FromVoidPtr)(void *cobj, void (*destr)(void *)); +! static void* (*dll_PyCObject_AsVoidPtr)(PyObject *); + # endif + + static HINSTANCE hinstPython = 0; /* Instance of python.dll */ +*** ../vim-7.3.583/src/version.c 2012-06-30 13:21:03.000000000 +0200 +--- src/version.c 2012-06-30 13:33:08.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 584, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +91. It's Saturday afternoon in the middle of May and you + are on computer. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bf7002c416b3402cea987009b8409d4f7e32e9fe Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:54 +0200 Subject: [PATCH 0406/3340] - patchlevel 585 --- 7.3.585 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.585 diff --git a/7.3.585 b/7.3.585 new file mode 100644 index 00000000..6509780c --- /dev/null +++ b/7.3.585 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.585 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.585 +Problem: Calling changed_bytes() too often. +Solution: Move changed_bytes() out of a loop. (Tor Perkins) +Files: src/edit.c + + +*** ../vim-7.3.584/src/edit.c 2012-06-29 15:04:34.000000000 +0200 +--- src/edit.c 2012-07-06 13:29:25.000000000 +0200 +*************** +*** 6350,6359 **** + * add the additional whitespace needed after the + * comment leader for the numbered list. */ + for (i = 0; i < padding; i++) +- { + ins_str((char_u *)" "); +! changed_bytes(curwin->w_cursor.lnum, leader_len); +! } + } + else + { +--- 6350,6357 ---- + * add the additional whitespace needed after the + * comment leader for the numbered list. */ + for (i = 0; i < padding; i++) + ins_str((char_u *)" "); +! changed_bytes(curwin->w_cursor.lnum, leader_len); + } + else + { +*** ../vim-7.3.584/src/version.c 2012-07-06 13:36:02.000000000 +0200 +--- src/version.c 2012-07-06 13:35:03.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 585, + /**/ + +-- +From "know your smileys": + :'-D Laughing so much that they're crying + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7f05cd09dc3ecd98110d7c37e45edbd632fcfce3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:54 +0200 Subject: [PATCH 0407/3340] - patchlevel 586 --- 7.3.586 | 103 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 103 insertions(+) create mode 100644 7.3.586 diff --git a/7.3.586 b/7.3.586 new file mode 100644 index 00000000..889ebd13 --- /dev/null +++ b/7.3.586 @@ -0,0 +1,103 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.586 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.586 +Problem: When compiling with Cygwin or MingW MEMORYSTATUSEX is not defined. +Solution: Set the default for WINVER to 0x0500. +Files: src/Make_ming.mak, src/Make_cyg.mak + + +*** ../vim-7.3.585/src/Make_ming.mak 2012-04-20 16:13:21.000000000 +0200 +--- src/Make_ming.mak 2012-06-30 21:23:55.000000000 +0200 +*************** +*** 52,58 **** + OLE=no + # Set the default $(WINVER) to make it work with pre-Win2k + ifndef WINVER +! WINVER = 0x0400 + endif + # Set to yes to enable Cscope support + CSCOPE=yes +--- 52,58 ---- + OLE=no + # Set the default $(WINVER) to make it work with pre-Win2k + ifndef WINVER +! WINVER = 0x0500 + endif + # Set to yes to enable Cscope support + CSCOPE=yes +*** ../vim-7.3.585/src/Make_cyg.mak 2011-09-30 16:56:00.000000000 +0200 +--- src/Make_cyg.mak 2012-06-30 21:23:42.000000000 +0200 +*************** +*** 1,6 **** + # + # Makefile for VIM on Win32, using Cygnus gcc +! # Last updated by Dan Sharp. Last Change: 2010 Nov 03 + # + # Also read INSTALLpc.txt! + # +--- 1,6 ---- + # + # Makefile for VIM on Win32, using Cygnus gcc +! # Last updated by Dan Sharp. Last Change: 2012 Jun 30 + # + # Also read INSTALLpc.txt! + # +*************** +*** 48,54 **** + # -L/lib/w32api to EXTRA_LIBS. + # POSTSCRIPT no or yes: set to yes for PostScript printing (no) + # FEATURES TINY, SMALL, NORMAL, BIG or HUGE (BIG) +! # WINVER Lowest Win32 version to support. (0x0400) + # CSCOPE no or yes: to include cscope interface support (yes) + # OPTIMIZE SPACE, SPEED, or MAXSPEED: set optimization level (MAXSPEED) + # NETBEANS no or yes: to include netbeans interface support (yes when GUI +--- 48,54 ---- + # -L/lib/w32api to EXTRA_LIBS. + # POSTSCRIPT no or yes: set to yes for PostScript printing (no) + # FEATURES TINY, SMALL, NORMAL, BIG or HUGE (BIG) +! # WINVER Lowest Win32 version to support. (0x0500) + # CSCOPE no or yes: to include cscope interface support (yes) + # OPTIMIZE SPACE, SPEED, or MAXSPEED: set optimization level (MAXSPEED) + # NETBEANS no or yes: to include netbeans interface support (yes when GUI +*************** +*** 85,91 **** + endif + + ifndef WINVER +! WINVER = 0x0400 + endif + + ifndef CSCOPE +--- 85,91 ---- + endif + + ifndef WINVER +! WINVER = 0x0500 + endif + + ifndef CSCOPE +*** ../vim-7.3.585/src/version.c 2012-07-06 13:36:36.000000000 +0200 +--- src/version.c 2012-07-06 13:39:41.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 586, + /**/ + +-- +From "know your smileys": + :-& Eating spaghetti + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f6516a73f3ea52511d5ce2c29824f9b9b9c7b5ab Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:54 +0200 Subject: [PATCH 0408/3340] - patchlevel 587 --- 7.3.587 | 84 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 7.3.587 diff --git a/7.3.587 b/7.3.587 new file mode 100644 index 00000000..22252318 --- /dev/null +++ b/7.3.587 @@ -0,0 +1,84 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.587 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.587 +Problem: Compiler warning for local var shadowing global var. +Solution: Rename the var and move it to an inner block. (Christian Brabandt) +Files: src/buffer.c + + +*** ../vim-7.3.586/src/buffer.c 2012-06-20 17:54:34.000000000 +0200 +--- src/buffer.c 2012-07-06 16:19:32.000000000 +0200 +*************** +*** 1363,1371 **** + int action; + { + buf_T *prevbuf; +- #ifdef FEAT_WINDOWS +- win_T *prevwin; +- #endif + int unload = (action == DOBUF_UNLOAD || action == DOBUF_DEL + || action == DOBUF_WIPE); + +--- 1363,1368 ---- +*************** +*** 1406,1412 **** + #endif + { + #ifdef FEAT_WINDOWS +! prevwin = curwin; + #endif + if (prevbuf == curbuf) + u_sync(FALSE); +--- 1403,1409 ---- + #endif + { + #ifdef FEAT_WINDOWS +! win_T *previouswin = curwin; + #endif + if (prevbuf == curbuf) + u_sync(FALSE); +*************** +*** 1415,1423 **** + && !P_HID(prevbuf) + && !bufIsChanged(prevbuf)) ? DOBUF_UNLOAD : 0, FALSE); + #ifdef FEAT_WINDOWS +! if (curwin != prevwin && win_valid(prevwin)) + /* autocommands changed curwin, Grr! */ +! curwin = prevwin; + #endif + } + } +--- 1412,1420 ---- + && !P_HID(prevbuf) + && !bufIsChanged(prevbuf)) ? DOBUF_UNLOAD : 0, FALSE); + #ifdef FEAT_WINDOWS +! if (curwin != previouswin && win_valid(previouswin)) + /* autocommands changed curwin, Grr! */ +! curwin = previouswin; + #endif + } + } +*** ../vim-7.3.586/src/version.c 2012-07-06 13:40:44.000000000 +0200 +--- src/version.c 2012-07-06 16:19:08.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 587, + /**/ + +-- +There's no place like $(HOME)! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0830ea5af2e4133dd4a5b61b6005b3b123b23948 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:55 +0200 Subject: [PATCH 0409/3340] - patchlevel 588 --- 7.3.588 | 85 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100644 7.3.588 diff --git a/7.3.588 b/7.3.588 new file mode 100644 index 00000000..6dfabd07 --- /dev/null +++ b/7.3.588 @@ -0,0 +1,85 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.588 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.588 +Problem: Crash on NULL pointer. +Solution: Fix the immediate problem by checking for NULL. (Lech Lorens) +Files: src/window.c + + +*** ../vim-7.3.587/src/window.c 2012-06-13 18:15:13.000000000 +0200 +--- src/window.c 2012-07-06 16:32:59.000000000 +0200 +*************** +*** 2184,2190 **** + } + + #ifdef FEAT_AUTOCMD +! if (win->w_closing || win->w_buffer->b_closing) + return; /* window is already being closed */ + if (win == aucmd_win) + { +--- 2184,2190 ---- + } + + #ifdef FEAT_AUTOCMD +! if (win->w_closing || (win->w_buffer != NULL && win->w_buffer->b_closing)) + return; /* window is already being closed */ + if (win == aucmd_win) + { +*************** +*** 3723,3729 **** + enter_tabpage(tp, old_curbuf, trigger_autocmds) + tabpage_T *tp; + buf_T *old_curbuf UNUSED; +! int trigger_autocmds UNUSED; + { + int old_off = tp->tp_firstwin->w_winrow; + win_T *next_prevwin = tp->tp_prevwin; +--- 3723,3729 ---- + enter_tabpage(tp, old_curbuf, trigger_autocmds) + tabpage_T *tp; + buf_T *old_curbuf UNUSED; +! int trigger_autocmds UNUSED; + { + int old_off = tp->tp_firstwin->w_winrow; + win_T *next_prevwin = tp->tp_prevwin; +*************** +*** 3868,3874 **** + void + goto_tabpage_tp(tp, trigger_autocmds) + tabpage_T *tp; +! int trigger_autocmds; + { + /* Don't repeat a message in another tab page. */ + set_keep_msg(NULL, 0); +--- 3868,3874 ---- + void + goto_tabpage_tp(tp, trigger_autocmds) + tabpage_T *tp; +! int trigger_autocmds; + { + /* Don't repeat a message in another tab page. */ + set_keep_msg(NULL, 0); +*** ../vim-7.3.587/src/version.c 2012-07-06 16:21:58.000000000 +0200 +--- src/version.c 2012-07-06 16:37:47.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 588, + /**/ + +-- +Momento mori, ergo carpe diem + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5e4b4c991327ade288c7bd7b58691e168a51a586 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:55 +0200 Subject: [PATCH 0410/3340] - patchlevel 589 --- 7.3.589 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.589 diff --git a/7.3.589 b/7.3.589 new file mode 100644 index 00000000..fdda2b95 --- /dev/null +++ b/7.3.589 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.589 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.589 +Problem: Crash when $HOME is not set. +Solution: Check for a NULL pointer. (Chris Webb) +Files: src/misc1.c + + +*** ../vim-7.3.588/src/misc1.c 2012-06-29 15:04:34.000000000 +0200 +--- src/misc1.c 2012-07-06 16:44:39.000000000 +0200 +*************** +*** 4496,4503 **** + #else + homedir_env_orig = homedir_env = mch_getenv((char_u *)"HOME"); + #endif + #if defined(FEAT_MODIFY_FNAME) || defined(WIN3264) +! if (vim_strchr(homedir_env, '~') != NULL) + { + int usedlen = 0; + int flen; +--- 4496,4507 ---- + #else + homedir_env_orig = homedir_env = mch_getenv((char_u *)"HOME"); + #endif ++ /* Empty is the same as not set. */ ++ if (homedir_env != NULL && *homedir_env == NUL) ++ homedir_env = NULL; ++ + #if defined(FEAT_MODIFY_FNAME) || defined(WIN3264) +! if (homedir_env != NULL && vim_strchr(homedir_env, '~') != NULL) + { + int usedlen = 0; + int flen; +*************** +*** 4513,4520 **** + } + #endif + +- if (homedir_env != NULL && *homedir_env == NUL) +- homedir_env = NULL; + if (homedir_env != NULL) + envlen = STRLEN(homedir_env); + +--- 4517,4522 ---- +*** ../vim-7.3.588/src/version.c 2012-07-06 16:39:43.000000000 +0200 +--- src/version.c 2012-07-06 16:45:18.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 589, + /**/ + +-- +I AM THANKFUL... +...for the taxes that I pay because it means that I am employed. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 53ee8b2ebc099d9956730d5268d8ab7b81afdeb4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:55 +0200 Subject: [PATCH 0411/3340] - patchlevel 590 --- 7.3.590 | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 7.3.590 diff --git a/7.3.590 b/7.3.590 new file mode 100644 index 00000000..4e524f79 --- /dev/null +++ b/7.3.590 @@ -0,0 +1,61 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.590 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.590 +Problem: The '< and '> marks cannot be set directly. +Solution: Allow setting '< and '>. (Christian Brabandt) +Files: src/mark.c + + +*** ../vim-7.3.589/src/mark.c 2011-02-25 15:11:17.000000000 +0100 +--- src/mark.c 2012-07-06 17:47:23.000000000 +0200 +*************** +*** 98,103 **** +--- 98,116 ---- + return OK; + } + ++ #ifdef FEAT_VISUAL ++ if (c == '<') ++ { ++ curbuf->b_visual.vi_start = *pos; ++ return OK; ++ } ++ if (c == '>') ++ { ++ curbuf->b_visual.vi_end = *pos; ++ return OK; ++ } ++ #endif ++ + #ifndef EBCDIC + if (c > 'z') /* some islower() and isupper() cannot handle + characters above 127 */ +*** ../vim-7.3.589/src/version.c 2012-07-06 16:49:37.000000000 +0200 +--- src/version.c 2012-07-06 17:49:00.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 590, + /**/ + +-- +The primary purpose of the DATA statement is to give names to constants; +instead of referring to pi as 3.141592653589793 at every appearance, the +variable PI can be given that value with a DATA statement and used instead +of the longer form of the constant. This also simplifies modifying the +program, should the value of pi change. + -- FORTRAN manual for Xerox Computers + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 899dbbe57b91f6648602712a702ee3f8f5ff26ee Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:56 +0200 Subject: [PATCH 0412/3340] - patchlevel 591 --- 7.3.591 | 208 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 208 insertions(+) create mode 100644 7.3.591 diff --git a/7.3.591 b/7.3.591 new file mode 100644 index 00000000..180fe608 --- /dev/null +++ b/7.3.591 @@ -0,0 +1,208 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.591 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.591 +Problem: Can only move to a tab by absolute number. +Solution: Move a number of tabs to the left or the right. (Lech Lorens) +Files: runtime/doc/tabpage.txt, src/ex_cmds.h, src/ex_docmd.c, + src/testdir/test62.in, src/testdir/test62.ok, src/window.c + + +*** ../vim-7.3.590/runtime/doc/tabpage.txt 2010-08-15 21:57:17.000000000 +0200 +--- runtime/doc/tabpage.txt 2012-07-06 18:10:06.000000000 +0200 +*************** +*** 173,182 **** +--- 173,192 ---- + REORDERING TAB PAGES: + + :tabm[ove] [N] *:tabm* *:tabmove* ++ :[N]tabm[ove] + Move the current tab page to after tab page N. Use zero to + make the current tab page the first one. Without N the tab + page is made the last one. + ++ :tabm[ove] +[N] ++ :tabm[ove] -[N] ++ Move the current tab page N places to the right (with +) or to ++ the left (with -). ++ ++ Note that although it is possible to move a tab behind the N-th one by using ++ :Ntabmove, it is impossible to move it by N places by using :+Ntabmove. For ++ clarification what +N means in this context see |[range]|. ++ + + LOOPING OVER TAB PAGES: + +*** ../vim-7.3.590/src/ex_cmds.h 2012-05-18 18:47:11.000000000 +0200 +--- src/ex_cmds.h 2012-07-06 18:10:13.000000000 +0200 +*************** +*** 944,950 **** + EX(CMD_tabfirst, "tabfirst", ex_tabnext, + TRLBAR), + EX(CMD_tabmove, "tabmove", ex_tabmove, +! RANGE|NOTADR|ZEROR|COUNT|TRLBAR|ZEROR), + EX(CMD_tablast, "tablast", ex_tabnext, + TRLBAR), + EX(CMD_tabnext, "tabnext", ex_tabnext, +--- 944,950 ---- + EX(CMD_tabfirst, "tabfirst", ex_tabnext, + TRLBAR), + EX(CMD_tabmove, "tabmove", ex_tabmove, +! RANGE|NOTADR|ZEROR|EXTRA|NOSPC|TRLBAR), + EX(CMD_tablast, "tablast", ex_tabnext, + TRLBAR), + EX(CMD_tabnext, "tabnext", ex_tabnext, +*** ../vim-7.3.590/src/ex_docmd.c 2012-06-06 19:02:40.000000000 +0200 +--- src/ex_docmd.c 2012-07-06 18:16:25.000000000 +0200 +*************** +*** 7478,7484 **** + ex_tabmove(eap) + exarg_T *eap; + { +! tabpage_move(eap->addr_count == 0 ? 9999 : (int)eap->line2); + } + + /* +--- 7478,7519 ---- + ex_tabmove(eap) + exarg_T *eap; + { +! int tab_number = 9999; +! +! if (eap->arg && *eap->arg != NUL) +! { +! char_u *p = eap->arg; +! int relative = 0; /* argument +N/-N means: move N places to the +! * right/left relative to the current position. */ +! +! if (*eap->arg == '-') +! { +! relative = -1; +! p = eap->arg + 1; +! } +! else if (*eap->arg == '+') +! { +! relative = 1; +! p = eap->arg + 1; +! } +! else +! p = eap->arg; +! +! if (p == skipdigits(p)) +! { +! /* No numbers as argument. */ +! eap->errmsg = e_invarg; +! return; +! } +! +! tab_number = getdigits(&p); +! if (relative != 0) +! tab_number = tab_number * relative + tabpage_index(curtab) - 1;; +! } +! else if (eap->addr_count != 0) +! tab_number = eap->line2; +! +! tabpage_move(tab_number); + } + + /* +*** ../vim-7.3.590/src/testdir/test62.in 2012-03-07 22:55:17.000000000 +0100 +--- src/testdir/test62.in 2012-07-06 18:10:13.000000000 +0200 +*************** +*** 93,98 **** +--- 93,126 ---- + :endif + :" + :" ++ :for i in range(9) | tabnew | endfor ++ 1gt ++ Go=tabpagenr()  ++ :tabmove 5 ++ i=tabpagenr()  ++ :tabmove -2 ++ i=tabpagenr()  ++ :tabmove +4 ++ i=tabpagenr()  ++ :tabmove ++ i=tabpagenr()  ++ :tabmove -20 ++ i=tabpagenr()  ++ :tabmove +20 ++ i=tabpagenr()  ++ :3tabmove ++ i=tabpagenr()  ++ :7tabmove 5 ++ i=tabpagenr()  ++ :let a='No error caught.' ++ :try ++ :tabmove foo ++ :catch E474 ++ :let a='E474 caught.' ++ :endtry ++ i=a  ++ :" ++ :" + :/^Results/,$w! test.out + :qa! + ENDTEST +*** ../vim-7.3.590/src/testdir/test62.ok 2012-02-22 19:13:00.000000000 +0100 +--- src/testdir/test62.ok 2012-07-06 18:10:13.000000000 +0200 +*************** +*** 8,10 **** +--- 8,20 ---- + tab drop 1: pass + tab drop 2: pass + tab drop 3: pass ++ 1 ++ 6 ++ 4 ++ 8 ++ 10 ++ 1 ++ 10 ++ 4 ++ 6 ++ E474 caught. +*** ../vim-7.3.590/src/window.c 2012-07-06 16:39:43.000000000 +0200 +--- src/window.c 2012-07-06 18:10:13.000000000 +0200 +*************** +*** 3929,3935 **** + } + + /* Re-insert it at the specified position. */ +! if (n == 0) + { + curtab->tp_next = first_tabpage; + first_tabpage = curtab; +--- 3929,3935 ---- + } + + /* Re-insert it at the specified position. */ +! if (n <= 0) + { + curtab->tp_next = first_tabpage; + first_tabpage = curtab; +*** ../vim-7.3.590/src/version.c 2012-07-06 17:51:24.000000000 +0200 +--- src/version.c 2012-07-06 18:11:08.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 591, + /**/ + +-- +Bare feet magnetize sharp metal objects so they point upward from the +floor -- especially in the dark. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 423a92dbe6fbb1b0a522f2c038d680f3ef31d967 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:56 +0200 Subject: [PATCH 0413/3340] - patchlevel 592 --- 7.3.592 | 126 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 126 insertions(+) create mode 100644 7.3.592 diff --git a/7.3.592 b/7.3.592 new file mode 100644 index 00000000..be13ef74 --- /dev/null +++ b/7.3.592 @@ -0,0 +1,126 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.592 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.592 +Problem: Vim on GTK does not support g:browsefilter. +Solution: Add a GtkFileFilter to the file chooser. (Christian Brabandt) +Files: src/gui_gtk.c + + +*** ../vim-7.3.591/src/gui_gtk.c 2012-06-06 16:14:36.000000000 +0200 +--- src/gui_gtk.c 2012-07-10 13:08:06.000000000 +0200 +*************** +*** 840,846 **** + char_u *dflt, + char_u *ext UNUSED, + char_u *initdir, +! char_u *filter UNUSED) + { + #ifdef USE_FILE_CHOOSER + GtkWidget *fc; +--- 840,846 ---- + char_u *dflt, + char_u *ext UNUSED, + char_u *initdir, +! char_u *filter) + { + #ifdef USE_FILE_CHOOSER + GtkWidget *fc; +*************** +*** 848,853 **** +--- 848,854 ---- + char_u dirbuf[MAXPATHL]; + guint log_handler; + const gchar *domain = "Gtk"; ++ GtkFileFilter *gfilter; + + title = CONVERT_TO_UTF8(title); + +*************** +*** 879,884 **** +--- 880,924 ---- + NULL); + gtk_file_chooser_set_current_folder(GTK_FILE_CHOOSER(fc), + (const gchar *)dirbuf); ++ ++ if (filter != NULL && *filter != NUL) ++ { ++ int i = 0; ++ char_u *patt; ++ char_u *p = filter; ++ ++ gfilter = gtk_file_filter_new(); ++ patt = alloc(STRLEN(filter)); ++ while (p != NULL && *p != NUL) ++ { ++ if (*p == '\n' || *p == ';' || *p == '\t') ++ { ++ STRNCPY(patt, filter, i); ++ patt[i] = '\0'; ++ if (*p == '\t') ++ gtk_file_filter_set_name(gfilter, (gchar *)patt); ++ else ++ { ++ gtk_file_filter_add_pattern(gfilter, (gchar *)patt); ++ if (*p == '\n') ++ { ++ gtk_file_chooser_add_filter((GtkFileChooser *)fc, ++ gfilter); ++ if (*(p + 1) != NUL) ++ gfilter = gtk_file_filter_new(); ++ } ++ } ++ filter = ++p; ++ i = 0; ++ } ++ else ++ { ++ p++; ++ i++; ++ } ++ } ++ vim_free(patt); ++ } + if (saving && dflt != NULL && *dflt != NUL) + gtk_file_chooser_set_current_name(GTK_FILE_CHOOSER(fc), (char *)dflt); + +*************** +*** 1304,1310 **** + gtk_widget_show(entry); + + /* Make Enter work like pressing OK. */ +! gtk_entry_set_activates_default(GTK_ENTRY(entry), TRUE); + + text = CONVERT_TO_UTF8(textfield); + gtk_entry_set_text(GTK_ENTRY(entry), (const char *)text); +--- 1344,1350 ---- + gtk_widget_show(entry); + + /* Make Enter work like pressing OK. */ +! gtk_entry_set_activates_default(GTK_ENTRY(entry), TRUE); + + text = CONVERT_TO_UTF8(textfield); + gtk_entry_set_text(GTK_ENTRY(entry), (const char *)text); +*** ../vim-7.3.591/src/version.c 2012-07-06 18:27:34.000000000 +0200 +--- src/version.c 2012-07-10 13:00:29.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 592, + /**/ + +-- +To be rich is not the end, but only a change of worries. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 57ffee393b2154f13f28c003ee6b7bfc25210042 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:56 +0200 Subject: [PATCH 0414/3340] - patchlevel 593 --- 7.3.593 | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 7.3.593 diff --git a/7.3.593 b/7.3.593 new file mode 100644 index 00000000..b8f26748 --- /dev/null +++ b/7.3.593 @@ -0,0 +1,81 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.593 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.593 +Problem: No easy way to decide if b:browsefilter will work. +Solution: Add the browsefilter feature. +Files: src/gui_gtk.c, src/eval.c, src/vim.h + + +*** ../vim-7.3.592/src/gui_gtk.c 2012-07-10 13:12:46.000000000 +0200 +--- src/gui_gtk.c 2012-07-10 13:40:38.000000000 +0200 +*************** +*** 779,787 **** + /* + * Implementation of the file selector related stuff + */ +- #if GTK_CHECK_VERSION(2,4,0) +- # define USE_FILE_CHOOSER +- #endif + + #ifndef USE_FILE_CHOOSER + static void +--- 779,784 ---- +*** ../vim-7.3.592/src/eval.c 2012-06-29 12:54:32.000000000 +0200 +--- src/eval.c 2012-07-10 13:34:10.000000000 +0200 +*************** +*** 12044,12049 **** +--- 12044,12054 ---- + "all_builtin_terms", + # endif + #endif ++ #if defined(FEAT_BROWSE) && (defined(USE_FILE_CHOOSER) \ ++ || defined(FEAT_GUI_W32) \ ++ || defined(FEAT_GUI_MOTIF)) ++ "browsefilter", ++ #endif + #ifdef FEAT_BYTEOFF + "byte_offset", + #endif +*** ../vim-7.3.592/src/vim.h 2012-06-13 17:28:51.000000000 +0200 +--- src/vim.h 2012-07-10 13:30:44.000000000 +0200 +*************** +*** 2125,2130 **** +--- 2125,2136 ---- + # endif + #endif + ++ #if defined(FEAT_BROWSE) && defined(GTK_CHECK_VERSION) ++ # if GTK_CHECK_VERSION(2,4,0) ++ # define USE_FILE_CHOOSER ++ # endif ++ #endif ++ + #ifndef FEAT_NETBEANS_INTG + # undef NBDEBUG + #endif +*** ../vim-7.3.592/src/version.c 2012-07-10 13:12:46.000000000 +0200 +--- src/version.c 2012-07-10 13:34:50.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 593, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +102. When filling out your driver's license application, you give + your IP address. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From efc1cb1a3a4c65642e7fee2e17277c877f6e25f7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:57 +0200 Subject: [PATCH 0415/3340] - patchlevel 594 --- 7.3.594 | 171 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 171 insertions(+) create mode 100644 7.3.594 diff --git a/7.3.594 b/7.3.594 new file mode 100644 index 00000000..3f7d3b26 --- /dev/null +++ b/7.3.594 @@ -0,0 +1,171 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.594 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.594 +Problem: The X command server doesn't work perfectly. It sends an empty + reply for as-keys requests. +Solution: Remove duplicate ga_init2(). Do not send a reply for as-keys + requests. (Brian Burns) +Files: src/if_xcmdsrv.c + + +*** ../vim-7.3.593/src/if_xcmdsrv.c 2010-08-15 21:57:27.000000000 +0200 +--- src/if_xcmdsrv.c 2012-07-10 14:15:59.000000000 +0200 +*************** +*** 655,661 **** + if (SendInit(dpy) < 0) + return NULL; + } +- ga_init2(&ga, 1, 100); + + /* + * Read the registry property. +--- 655,660 ---- +*************** +*** 1198,1206 **** + if ((*p == 'c' || *p == 'k') && (p[1] == 0)) + { + Window resWindow; +! char_u *name, *script, *serial, *end, *res; + Bool asKeys = *p == 'k'; +- garray_T reply; + char_u *enc; + + /* +--- 1197,1204 ---- + if ((*p == 'c' || *p == 'k') && (p[1] == 0)) + { + Window resWindow; +! char_u *name, *script, *serial, *end; + Bool asKeys = *p == 'k'; + char_u *enc; + + /* +*************** +*** 1256,1305 **** + if (script == NULL || name == NULL) + continue; + +! /* +! * Initialize the result property, so that we're ready at any +! * time if we need to return an error. +! */ +! if (resWindow != None) +! { +! ga_init2(&reply, 1, 100); + #ifdef FEAT_MBYTE +! ga_grow(&reply, 50 + STRLEN(p_enc)); +! sprintf(reply.ga_data, "%cr%c-E %s%c-s %s%c-r ", + 0, 0, p_enc, 0, serial, 0); +! reply.ga_len = 14 + STRLEN(p_enc) + STRLEN(serial); + #else +! ga_grow(&reply, 50); +! sprintf(reply.ga_data, "%cr%c-s %s%c-r ", 0, 0, serial, 0); +! reply.ga_len = 10 + STRLEN(serial); + #endif +! } +! res = NULL; +! if (serverName != NULL && STRICMP(name, serverName) == 0) +! { +! script = serverConvert(enc, script, &tofree); +! if (asKeys) +! server_to_input_buf(script); +! else +! res = eval_client_expr_to_string(script); +! vim_free(tofree); +! } +! if (resWindow != None) +! { +! if (res != NULL) +! ga_concat(&reply, res); +! else if (asKeys == 0) +! { +! ga_concat(&reply, (char_u *)_(e_invexprmsg)); +! ga_append(&reply, 0); +! ga_concat(&reply, (char_u *)"-c 1"); +! } +! ga_append(&reply, NUL); +! (void)AppendPropCarefully(dpy, resWindow, commProperty, +! reply.ga_data, reply.ga_len); +! ga_clear(&reply); +! } +! vim_free(res); + } + else if (*p == 'r' && p[1] == 0) + { +--- 1254,1305 ---- + if (script == NULL || name == NULL) + continue; + +! if (serverName != NULL && STRICMP(name, serverName) == 0) +! { +! script = serverConvert(enc, script, &tofree); +! if (asKeys) +! server_to_input_buf(script); +! else +! { +! char_u *res; +! +! res = eval_client_expr_to_string(script); +! if (resWindow != None) +! { +! garray_T reply; +! +! /* Initialize the result property. */ +! ga_init2(&reply, 1, 100); + #ifdef FEAT_MBYTE +! ga_grow(&reply, 50 + STRLEN(p_enc)); +! sprintf(reply.ga_data, "%cr%c-E %s%c-s %s%c-r ", + 0, 0, p_enc, 0, serial, 0); +! reply.ga_len = 14 + STRLEN(p_enc) + STRLEN(serial); + #else +! ga_grow(&reply, 50); +! sprintf(reply.ga_data, "%cr%c-s %s%c-r ", +! 0, 0, serial, 0); +! reply.ga_len = 10 + STRLEN(serial); + #endif +! +! /* Evaluate the expression and return the result. */ +! if (res != NULL) +! ga_concat(&reply, res); +! else +! { +! ga_concat(&reply, (char_u *)_(e_invexprmsg)); +! ga_append(&reply, 0); +! ga_concat(&reply, (char_u *)"-c 1"); +! } +! ga_append(&reply, NUL); +! (void)AppendPropCarefully(dpy, resWindow, commProperty, +! reply.ga_data, reply.ga_len); +! ga_clear(&reply); +! } +! vim_free(res); +! } +! vim_free(tofree); +! } + } + else if (*p == 'r' && p[1] == 0) + { +*** ../vim-7.3.593/src/version.c 2012-07-10 13:41:09.000000000 +0200 +--- src/version.c 2012-07-10 14:17:50.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 594, + /**/ + +-- +A meeting is an event at which the minutes are kept and the hours are lost. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ffb01521d78eed238ca22fbb8161121afcfd08fc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:57 +0200 Subject: [PATCH 0416/3340] - patchlevel 595 --- 7.3.595 | 154 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 154 insertions(+) create mode 100644 7.3.595 diff --git a/7.3.595 b/7.3.595 new file mode 100644 index 00000000..0fc9b522 --- /dev/null +++ b/7.3.595 @@ -0,0 +1,154 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.595 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.595 +Problem: The X command server responds slowly +Solution: Change the loop that waits for replies. (Brian Burns) +Files: src/if_xcmdsrv.c + + +*** ../vim-7.3.594/src/if_xcmdsrv.c 2012-07-10 14:25:00.000000000 +0200 +--- src/if_xcmdsrv.c 2012-07-10 14:44:13.000000000 +0200 +*************** +*** 572,632 **** + { + time_t start; + time_t now; +- time_t lastChk = 0; + XEvent event; +! XPropertyEvent *e = (XPropertyEvent *)&event; +! # define SEND_MSEC_POLL 50 + + time(&start); +! while (endCond(endData) == 0) + { + time(&now); + if (seconds >= 0 && (now - start) >= seconds) + break; +! if (now != lastChk) +! { +! lastChk = now; +! if (!WindowValid(dpy, w)) +! break; +! /* +! * Sometimes the PropertyChange event doesn't come. +! * This can be seen in eg: vim -c 'echo remote_expr("gvim", "3+2")' +! */ +! serverEventProc(dpy, NULL); +! } + if (localLoop) + { +- /* Just look out for the answer without calling back into Vim */ + #ifndef HAVE_SELECT +- struct pollfd fds; +- +- fds.fd = ConnectionNumber(dpy); +- fds.events = POLLIN; + if (poll(&fds, 1, SEND_MSEC_POLL) < 0) + break; + #else +! fd_set fds; +! struct timeval tv; +! +! tv.tv_sec = 0; +! tv.tv_usec = SEND_MSEC_POLL * 1000; +! FD_ZERO(&fds); +! FD_SET(ConnectionNumber(dpy), &fds); +! if (select(ConnectionNumber(dpy) + 1, &fds, NULL, NULL, &tv) < 0) + break; + #endif +- while (XEventsQueued(dpy, QueuedAfterReading) > 0) +- { +- XNextEvent(dpy, &event); +- if (event.type == PropertyNotify && e->window == commWindow) +- serverEventProc(dpy, &event); +- } + } + else + { + if (got_int) + break; +! ui_delay((long)SEND_MSEC_POLL, TRUE); + ui_breakcheck(); + } + } +--- 572,626 ---- + { + time_t start; + time_t now; + XEvent event; +! +! #define UI_MSEC_DELAY 50 +! #define SEND_MSEC_POLL 500 +! #ifndef HAVE_SELECT +! struct pollfd fds; +! +! fds.fd = ConnectionNumber(dpy); +! fds.events = POLLIN; +! #else +! fd_set fds; +! struct timeval tv; +! +! tv.tv_sec = 0; +! tv.tv_usec = SEND_MSEC_POLL * 1000; +! FD_ZERO(&fds); +! FD_SET(ConnectionNumber(dpy), &fds); +! #endif + + time(&start); +! while (TRUE) + { ++ while (XCheckWindowEvent(dpy, commWindow, PropertyChangeMask, &event)) ++ serverEventProc(dpy, &event); ++ ++ if (endCond(endData) != 0) ++ break; ++ if (!WindowValid(dpy, w)) ++ break; + time(&now); + if (seconds >= 0 && (now - start) >= seconds) + break; +! +! /* Just look out for the answer without calling back into Vim */ + if (localLoop) + { + #ifndef HAVE_SELECT + if (poll(&fds, 1, SEND_MSEC_POLL) < 0) + break; + #else +! if (select(FD_SETSIZE, &fds, NULL, NULL, &tv) < 0) + break; + #endif + } + else + { + if (got_int) + break; +! ui_delay((long)UI_MSEC_DELAY, TRUE); + ui_breakcheck(); + } + } +*** ../vim-7.3.594/src/version.c 2012-07-10 14:25:00.000000000 +0200 +--- src/version.c 2012-07-10 14:52:16.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 595, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +104. When people ask about the Presidential Election you ask "Which country?" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4d084147605919a017826bb1500a77541a3a130d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:57 +0200 Subject: [PATCH 0417/3340] - patchlevel 596 --- 7.3.596 | 171 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 171 insertions(+) create mode 100644 7.3.596 diff --git a/7.3.596 b/7.3.596 new file mode 100644 index 00000000..59513b2b --- /dev/null +++ b/7.3.596 @@ -0,0 +1,171 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.596 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.596 +Problem: Can't remove all signs for a file or buffer. +Solution: Support "*" for the sign id. (Christian Brabandt) +Files: runtime/doc/sign.txt, src/buffer.c, src/ex_cmds.c, + src/proto/buffer.pro + + +*** ../vim-7.3.595/runtime/doc/sign.txt 2010-08-15 21:57:17.000000000 +0200 +--- runtime/doc/sign.txt 2012-07-10 15:05:19.000000000 +0200 +*************** +*** 150,157 **** + Remove the previously placed sign {id} from file {fname}. + See remark above about {fname} |:sign-fname|. + + :sign unplace {id} buffer={nr} +! Same, but use buffer {nr}. + + :sign unplace {id} + Remove the previously placed sign {id} from all files it +--- 153,166 ---- + Remove the previously placed sign {id} from file {fname}. + See remark above about {fname} |:sign-fname|. + ++ :sign unplace * file={fname} ++ Remove all placed signs in file {fname}. ++ + :sign unplace {id} buffer={nr} +! Remove the previously placed sign {id} from buffer {nr}. +! +! :sign unplace * buffer={nr} +! Remove all placed signs in buffer {nr}. + + :sign unplace {id} + Remove the previously placed sign {id} from all files it +*** ../vim-7.3.595/src/buffer.c 2012-07-06 16:21:58.000000000 +0200 +--- src/buffer.c 2012-07-10 15:06:05.000000000 +0200 +*************** +*** 57,63 **** + + #if defined(FEAT_SIGNS) + static void insert_sign __ARGS((buf_T *buf, signlist_T *prev, signlist_T *next, int id, linenr_T lnum, int typenr)); +- static void buf_delete_signs __ARGS((buf_T *buf)); + #endif + + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +--- 57,62 ---- +*************** +*** 5537,5543 **** + /* + * Delete signs in buffer "buf". + */ +! static void + buf_delete_signs(buf) + buf_T *buf; + { +--- 5536,5542 ---- + /* + * Delete signs in buffer "buf". + */ +! void + buf_delete_signs(buf) + buf_T *buf; + { +*** ../vim-7.3.595/src/ex_cmds.c 2012-05-18 16:24:06.000000000 +0200 +--- src/ex_cmds.c 2012-07-10 15:14:22.000000000 +0200 +*************** +*** 6997,7002 **** +--- 6997,7012 ---- + lnum = atoi((char *)arg); + arg = skiptowhite(arg); + } ++ else if (STRNCMP(arg, "*", 1) == 0 && idx == SIGNCMD_UNPLACE) ++ { ++ if (id != -1) ++ { ++ EMSG(_(e_invarg)); ++ return; ++ } ++ id = -2; ++ arg = skiptowhite(arg + 1); ++ } + else if (STRNCMP(arg, "name=", 5) == 0) + { + arg += 5; +*************** +*** 7033,7039 **** + { + EMSG2(_("E158: Invalid buffer name: %s"), arg); + } +! else if (id <= 0) + { + if (lnum >= 0 || sign_name != NULL) + EMSG(_(e_invarg)); +--- 7043,7049 ---- + { + EMSG2(_("E158: Invalid buffer name: %s"), arg); + } +! else if (id <= 0 && !(idx == SIGNCMD_UNPLACE && id == -2)) + { + if (lnum >= 0 || sign_name != NULL) + EMSG(_(e_invarg)); +*************** +*** 7074,7084 **** + } + else if (idx == SIGNCMD_UNPLACE) + { +- /* ":sign unplace {id} file={fname}" */ + if (lnum >= 0 || sign_name != NULL) + EMSG(_(e_invarg)); + else + { + lnum = buf_delsign(buf, id); + update_debug_sign(buf, lnum); + } +--- 7084,7100 ---- + } + else if (idx == SIGNCMD_UNPLACE) + { + if (lnum >= 0 || sign_name != NULL) + EMSG(_(e_invarg)); ++ else if (id == -2) ++ { ++ /* ":sign unplace * file={fname}" */ ++ redraw_buf_later(buf, NOT_VALID); ++ buf_delete_signs(buf); ++ } + else + { ++ /* ":sign unplace {id} file={fname}" */ + lnum = buf_delsign(buf, id); + update_debug_sign(buf, lnum); + } +*** ../vim-7.3.595/src/proto/buffer.pro 2012-02-22 14:58:24.000000000 +0100 +--- src/proto/buffer.pro 2012-07-10 15:06:10.000000000 +0200 +*************** +*** 60,65 **** +--- 60,66 ---- + int buf_findsign_id __ARGS((buf_T *buf, linenr_T lnum)); + int buf_findsigntype_id __ARGS((buf_T *buf, linenr_T lnum, int typenr)); + int buf_signcount __ARGS((buf_T *buf, linenr_T lnum)); ++ void buf_delete_signs __ARGS((buf_T *buf)); + void buf_delete_all_signs __ARGS((void)); + void sign_list_placed __ARGS((buf_T *rbuf)); + void sign_mark_adjust __ARGS((linenr_T line1, linenr_T line2, long amount, long amount_after)); +*** ../vim-7.3.595/src/version.c 2012-07-10 14:56:42.000000000 +0200 +--- src/version.c 2012-07-10 15:16:40.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 596, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +105. When someone asks you for your address, you tell them your URL. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 77fefb6645eafacfc70be15443361c9cc0948f65 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:58 +0200 Subject: [PATCH 0418/3340] - patchlevel 597 --- 7.3.597 | 720 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 720 insertions(+) create mode 100644 7.3.597 diff --git a/7.3.597 b/7.3.597 new file mode 100644 index 00000000..2a4f0b3d --- /dev/null +++ b/7.3.597 @@ -0,0 +1,720 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.597 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.597 +Problem: 'clipboard' "autoselect" only applies to the * register. (Sergey + Vakulenko) +Solution: Make 'autoselect' work for the + register. (Christian Brabant) + Add the "autoselectplus" option in 'clipboard' and the "P" flag in + 'guioptions'. +Files: runtime/doc/options.txt, src/normal.c, src/ops.c, src/screen.c, + src/ui.c, src/globals.h, src/proto/ui.pro, src/option.h, src/gui.c + + +*** ../vim-7.3.596/runtime/doc/options.txt 2012-02-20 22:18:23.000000000 +0100 +--- runtime/doc/options.txt 2012-07-10 15:40:35.000000000 +0200 +*************** +*** 1437,1442 **** +--- 1452,1458 ---- + This option is a list of comma separated names. + These names are recognized: + ++ *clipboard-unnamed* + unnamed When included, Vim will use the clipboard register '*' + for all yank, delete, change and put operations which + would normally go to the unnamed register. When a +*************** +*** 1446,1460 **** + explicitly accessed using the "* notation. Also see + |gui-clipboard|. + + unnamedplus A variant of "unnamed" flag which uses the clipboard + register '+' (|quoteplus|) instead of register '*' for + all operations except yank. Yank shall copy the text + into register '+' and also into '*' when "unnamed" is + included. +! Only available with the |+x11| feature. + Availability can be checked with: > + if has('unnamedplus') + < + autoselect Works like the 'a' flag in 'guioptions': If present, + then whenever Visual mode is started, or the Visual + area extended, Vim tries to become the owner of the +--- 1462,1478 ---- + explicitly accessed using the "* notation. Also see + |gui-clipboard|. + ++ *clipboard-unnamedplus* + unnamedplus A variant of "unnamed" flag which uses the clipboard + register '+' (|quoteplus|) instead of register '*' for + all operations except yank. Yank shall copy the text + into register '+' and also into '*' when "unnamed" is + included. +! Only available with the |+X11| feature. + Availability can be checked with: > + if has('unnamedplus') + < ++ *clipboard-autoselect* + autoselect Works like the 'a' flag in 'guioptions': If present, + then whenever Visual mode is started, or the Visual + area extended, Vim tries to become the owner of the +*************** +*** 1466,1474 **** +--- 1484,1499 ---- + "autoselect" flag is used. + Also applies to the modeless selection. + ++ *clipboard-autoselectplus* ++ autoselectplus Like "autoselect" but using the + register instead of ++ the * register. Compare to the 'P' flag in ++ 'guioptions'. ++ ++ *clipboard-autoselectml* + autoselectml Like "autoselect", but for the modeless selection + only. Compare to the 'A' flag in 'guioptions'. + ++ *clipboard-html* + html When the clipboard contains HTML, use this when + pasting. When putting text on the clipboard, mark it + as HTML. This works to copy rendered HTML from +*************** +*** 1479,1484 **** +--- 1504,1510 ---- + Only supported for GTK version 2 and later. + Only available with the |+multi_byte| feature. + ++ *clipboard-exclude* + exclude:{pattern} + Defines a pattern that is matched against the name of + the terminal 'term'. If there is a match, no +*************** +*** 3547,3552 **** +--- 3600,3608 ---- + windowing system's global selection unless explicitly told to + by a yank or delete operation for the "* register. + The same applies to the modeless selection. ++ *'go-P'* ++ 'P' Like autoselect but using the "+ register instead of the "* ++ register. + *'go-A'* + 'A' Autoselect for the modeless selection. Like 'a', but only + applies to the modeless selection. +*** ../vim-7.3.596/src/normal.c 2012-06-29 13:56:01.000000000 +0200 +--- src/normal.c 2012-07-10 15:44:24.000000000 +0200 +*************** +*** 1451,1457 **** + * This could call do_pending_operator() recursively, but that's OK + * because gui_yank will be TRUE for the nested call. + */ +! if (clip_star.available + && oap->op_type != OP_NOP + && !gui_yank + # ifdef FEAT_VISUAL +--- 1451,1457 ---- + * This could call do_pending_operator() recursively, but that's OK + * because gui_yank will be TRUE for the nested call. + */ +! if ((clip_star.available || clip_plus.available) + && oap->op_type != OP_NOP + && !gui_yank + # ifdef FEAT_VISUAL +*** ../vim-7.3.596/src/ops.c 2012-06-29 13:34:15.000000000 +0200 +--- src/ops.c 2012-07-10 16:20:29.000000000 +0200 +*************** +*** 962,969 **** + * selection too. */ + if (name == '*' && clip_star.available) + { +! if (clip_isautosel()) +! clip_update_selection(); + may_get_selection(name); + } + #endif +--- 962,975 ---- + * selection too. */ + if (name == '*' && clip_star.available) + { +! if (clip_isautosel_star()) +! clip_update_selection(&clip_star); +! may_get_selection(name); +! } +! if (name == '+' && clip_plus.available) +! { +! if (clip_isautosel_plus()) +! clip_update_selection(&clip_plus); + may_get_selection(name); + } + #endif +*************** +*** 3190,3196 **** + + clip_own_selection(&clip_plus); + clip_gen_set_selection(&clip_plus); +! if (!clip_isautosel() && !did_star && curr == &(y_regs[PLUS_REGISTER])) + { + copy_yank_reg(&(y_regs[STAR_REGISTER])); + clip_own_selection(&clip_star); +--- 3196,3203 ---- + + clip_own_selection(&clip_plus); + clip_gen_set_selection(&clip_plus); +! if (!clip_isautosel_star() && !did_star +! && curr == &(y_regs[PLUS_REGISTER])) + { + copy_yank_reg(&(y_regs[STAR_REGISTER])); + clip_own_selection(&clip_star); +*** ../vim-7.3.596/src/screen.c 2012-06-13 18:06:32.000000000 +0200 +--- src/screen.c 2012-07-10 16:39:01.000000000 +0200 +*************** +*** 519,526 **** + # endif + # ifdef FEAT_CLIPBOARD + /* When Visual area changed, may have to update selection. */ +! if (clip_star.available && clip_isautosel()) +! clip_update_selection(); + # endif + #ifdef FEAT_GUI + /* Remove the cursor before starting to do anything, because +--- 519,528 ---- + # endif + # ifdef FEAT_CLIPBOARD + /* When Visual area changed, may have to update selection. */ +! if (clip_star.available && clip_isautosel_star()) +! clip_update_selection(&clip_star); +! if (clip_plus.available && clip_isautosel_plus()) +! clip_update_selection(&clip_plus); + # endif + #ifdef FEAT_GUI + /* Remove the cursor before starting to do anything, because +*************** +*** 814,821 **** + + #ifdef FEAT_CLIPBOARD + /* When Visual area changed, may have to update selection. */ +! if (clip_star.available && clip_isautosel()) +! clip_update_selection(); + #endif + + win_update(wp); +--- 816,825 ---- + + #ifdef FEAT_CLIPBOARD + /* When Visual area changed, may have to update selection. */ +! if (clip_star.available && clip_isautosel_star()) +! clip_update_selection(&clip_star); +! if (clip_plus.available && clip_isautosel_plus()) +! clip_update_selection(&clip_plus); + #endif + + win_update(wp); +*************** +*** 3000,3006 **** + area_highlighting = TRUE; + attr = hl_attr(HLF_V); + #if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) +! if (clip_star.available && !clip_star.owned && clip_isautosel()) + attr = hl_attr(HLF_VNC); + #endif + } +--- 3004,3013 ---- + area_highlighting = TRUE; + attr = hl_attr(HLF_V); + #if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) +! if ((clip_star.available && !clip_star.owned +! && clip_isautosel_star()) +! || (clip_plus.available && !clip_plus.owned +! && clip_isautosel_plus())) + attr = hl_attr(HLF_VNC); + #endif + } +*************** +*** 9060,9066 **** + || (wp != NULL && wp->w_width != Columns) + # endif + ) +! clip_clear_selection(); + else + clip_scroll_selection(-line_count); + #endif +--- 9067,9073 ---- + || (wp != NULL && wp->w_width != Columns) + # endif + ) +! clip_clear_selection(&clip_star); + else + clip_scroll_selection(-line_count); + #endif +*************** +*** 9281,9287 **** + || (wp != NULL && wp->w_width != Columns) + # endif + ) +! clip_clear_selection(); + else + clip_scroll_selection(line_count); + #endif +--- 9288,9294 ---- + || (wp != NULL && wp->w_width != Columns) + # endif + ) +! clip_clear_selection(&clip_star); + else + clip_scroll_selection(line_count); + #endif +*** ../vim-7.3.596/src/ui.c 2012-02-12 01:35:06.000000000 +0100 +--- src/ui.c 2012-07-10 16:43:17.000000000 +0200 +*************** +*** 381,386 **** +--- 381,388 ---- + + #if defined(FEAT_CLIPBOARD) || defined(PROTO) + ++ static void clip_copy_selection __ARGS((VimClipboard *clip)); ++ + /* + * Selection stuff using Visual mode, for cutting and pasting text to other + * windows. +*************** +*** 423,431 **** + * this is called whenever VIsual mode is ended. + */ + void +! clip_update_selection() + { +! pos_T start, end; + + /* If visual mode is only due to a redo command ("."), then ignore it */ + if (!redo_VIsual_busy && VIsual_active && (State & NORMAL)) +--- 425,434 ---- + * this is called whenever VIsual mode is ended. + */ + void +! clip_update_selection(clip) +! VimClipboard *clip; + { +! pos_T start, end; + + /* If visual mode is only due to a redo command ("."), then ignore it */ + if (!redo_VIsual_busy && VIsual_active && (State & NORMAL)) +*************** +*** 444,460 **** + start = curwin->w_cursor; + end = VIsual; + } +! if (!equalpos(clip_star.start, start) +! || !equalpos(clip_star.end, end) +! || clip_star.vmode != VIsual_mode) + { +! clip_clear_selection(); +! clip_star.start = start; +! clip_star.end = end; +! clip_star.vmode = VIsual_mode; +! clip_free_selection(&clip_star); +! clip_own_selection(&clip_star); +! clip_gen_set_selection(&clip_star); + } + } + } +--- 447,463 ---- + start = curwin->w_cursor; + end = VIsual; + } +! if (!equalpos(clip->start, start) +! || !equalpos(clip->end, end) +! || clip->vmode != VIsual_mode) + { +! clip_clear_selection(clip); +! clip->start = start; +! clip->end = end; +! clip->vmode = VIsual_mode; +! clip_free_selection(clip); +! clip_own_selection(clip); +! clip_gen_set_selection(clip); + } + } + } +*************** +*** 475,481 **** + int was_owned = cbd->owned; + + cbd->owned = (clip_gen_own_selection(cbd) == OK); +! if (!was_owned && cbd == &clip_star) + { + /* May have to show a different kind of highlighting for the + * selected area. There is no specific redraw command for this, +--- 478,484 ---- + int was_owned = cbd->owned; + + cbd->owned = (clip_gen_own_selection(cbd) == OK); +! if (!was_owned && (cbd == &clip_star || cbd == &clip_plus)) + { + /* May have to show a different kind of highlighting for the + * selected area. There is no specific redraw command for this, +*************** +*** 483,489 **** + if (cbd->owned + && (get_real_state() == VISUAL + || get_real_state() == SELECTMODE) +! && clip_isautosel() + && hl_attr(HLF_V) != hl_attr(HLF_VNC)) + redraw_curbuf_later(INVERTED_ALL); + } +--- 486,493 ---- + if (cbd->owned + && (get_real_state() == VISUAL + || get_real_state() == SELECTMODE) +! && (cbd == &clip_star ? clip_isautosel_star() +! : clip_isautosel_plus()) + && hl_attr(HLF_V) != hl_attr(HLF_VNC)) + redraw_curbuf_later(INVERTED_ALL); + } +*************** +*** 502,513 **** + #ifdef FEAT_X11 + int was_owned = cbd->owned; + #endif +! int visual_selection = (cbd == &clip_star); + + clip_free_selection(cbd); + cbd->owned = FALSE; + if (visual_selection) +! clip_clear_selection(); + clip_gen_lose_selection(cbd); + #ifdef FEAT_X11 + if (visual_selection) +--- 506,520 ---- + #ifdef FEAT_X11 + int was_owned = cbd->owned; + #endif +! int visual_selection = FALSE; +! +! if (cbd == &clip_star || cbd == &clip_plus) +! visual_selection = TRUE; + + clip_free_selection(cbd); + cbd->owned = FALSE; + if (visual_selection) +! clip_clear_selection(cbd); + clip_gen_lose_selection(cbd); + #ifdef FEAT_X11 + if (visual_selection) +*************** +*** 518,524 **** + if (was_owned + && (get_real_state() == VISUAL + || get_real_state() == SELECTMODE) +! && clip_isautosel() + && hl_attr(HLF_V) != hl_attr(HLF_VNC)) + { + update_curbuf(INVERTED_ALL); +--- 525,532 ---- + if (was_owned + && (get_real_state() == VISUAL + || get_real_state() == SELECTMODE) +! && (cbd == &clip_star ? +! clip_isautosel_star() : clip_isautosel_plus()) + && hl_attr(HLF_V) != hl_attr(HLF_VNC)) + { + update_curbuf(INVERTED_ALL); +*************** +*** 534,551 **** + #endif + } + +! void +! clip_copy_selection() +! { +! if (VIsual_active && (State & NORMAL) && clip_star.available) +! { +! if (clip_isautosel()) +! clip_update_selection(); +! clip_free_selection(&clip_star); +! clip_own_selection(&clip_star); +! if (clip_star.owned) +! clip_get_selection(&clip_star); +! clip_gen_set_selection(&clip_star); + } + } + +--- 542,559 ---- + #endif + } + +! static void +! clip_copy_selection(clip) +! VimClipboard *clip; +! { +! if (VIsual_active && (State & NORMAL) && clip->available) +! { +! clip_update_selection(clip); +! clip_free_selection(clip); +! clip_own_selection(clip); +! if (clip->owned) +! clip_get_selection(clip); +! clip_gen_set_selection(clip); + } + } + +*************** +*** 555,575 **** + void + clip_auto_select() + { +! if (clip_isautosel()) +! clip_copy_selection(); + } + + /* +! * Return TRUE if automatic selection of Visual area is desired. + */ + int +! clip_isautosel() + { + return ( + #ifdef FEAT_GUI + gui.in_use ? (vim_strchr(p_go, GO_ASEL) != NULL) : + #endif +! clip_autoselect); + } + + +--- 563,600 ---- + void + clip_auto_select() + { +! if (clip_isautosel_star()) +! clip_copy_selection(&clip_star); +! if (clip_isautosel_plus()) +! clip_copy_selection(&clip_plus); + } + + /* +! * Return TRUE if automatic selection of Visual area is desired for the * +! * register. + */ + int +! clip_isautosel_star() + { + return ( + #ifdef FEAT_GUI + gui.in_use ? (vim_strchr(p_go, GO_ASEL) != NULL) : + #endif +! clip_autoselect_star); +! } +! +! /* +! * Return TRUE if automatic selection of Visual area is desired for the + +! * register. +! */ +! int +! clip_isautosel_plus() +! { +! return ( +! #ifdef FEAT_GUI +! gui.in_use ? (vim_strchr(p_go, GO_ASELPLUS) != NULL) : +! #endif +! clip_autoselect_plus); + } + + +*************** +*** 657,663 **** + VimClipboard *cb = &clip_star; + + if (cb->state == SELECT_DONE) +! clip_clear_selection(); + + row = check_row(row); + col = check_col(col); +--- 682,688 ---- + VimClipboard *cb = &clip_star; + + if (cb->state == SELECT_DONE) +! clip_clear_selection(cb); + + row = check_row(row); + col = check_col(col); +*************** +*** 749,755 **** + printf("Selection ended: (%u,%u) to (%u,%u)\n", cb->start.lnum, + cb->start.col, cb->end.lnum, cb->end.col); + #endif +! if (clip_isautosel() + || ( + #ifdef FEAT_GUI + gui.in_use ? (vim_strchr(p_go, GO_ASELML) != NULL) : +--- 774,780 ---- + printf("Selection ended: (%u,%u) to (%u,%u)\n", cb->start.lnum, + cb->start.col, cb->end.lnum, cb->end.col); + #endif +! if (clip_isautosel_star() + || ( + #ifdef FEAT_GUI + gui.in_use ? (vim_strchr(p_go, GO_ASELML) != NULL) : +*************** +*** 932,947 **** + * Called from outside to clear selected region from the display + */ + void +! clip_clear_selection() + { +- VimClipboard *cb = &clip_star; + +! if (cb->state == SELECT_CLEARED) + return; + +! clip_invert_area((int)cb->start.lnum, cb->start.col, (int)cb->end.lnum, +! cb->end.col, CLIP_CLEAR); +! cb->state = SELECT_CLEARED; + } + + /* +--- 957,972 ---- + * Called from outside to clear selected region from the display + */ + void +! clip_clear_selection(cbd) +! VimClipboard *cbd; + { + +! if (cbd->state == SELECT_CLEARED) + return; + +! clip_invert_area((int)cbd->start.lnum, cbd->start.col, (int)cbd->end.lnum, +! cbd->end.col, CLIP_CLEAR); +! cbd->state = SELECT_CLEARED; + } + + /* +*************** +*** 954,960 **** + if (clip_star.state == SELECT_DONE + && row2 >= clip_star.start.lnum + && row1 <= clip_star.end.lnum) +! clip_clear_selection(); + } + + /* +--- 979,985 ---- + if (clip_star.state == SELECT_DONE + && row2 >= clip_star.start.lnum + && row1 <= clip_star.end.lnum) +! clip_clear_selection(&clip_star); + } + + /* +*** ../vim-7.3.596/src/globals.h 2012-06-29 12:35:40.000000000 +0200 +--- src/globals.h 2012-07-10 16:35:13.000000000 +0200 +*************** +*** 517,523 **** + # define CLIP_UNNAMED_PLUS 2 + EXTERN int clip_unnamed INIT(= 0); /* above two values or'ed */ + +! EXTERN int clip_autoselect INIT(= FALSE); + EXTERN int clip_autoselectml INIT(= FALSE); + EXTERN int clip_html INIT(= FALSE); + EXTERN regprog_T *clip_exclude_prog INIT(= NULL); +--- 517,524 ---- + # define CLIP_UNNAMED_PLUS 2 + EXTERN int clip_unnamed INIT(= 0); /* above two values or'ed */ + +! EXTERN int clip_autoselect_star INIT(= FALSE); +! EXTERN int clip_autoselect_plus INIT(= FALSE); + EXTERN int clip_autoselectml INIT(= FALSE); + EXTERN int clip_html INIT(= FALSE); + EXTERN regprog_T *clip_exclude_prog INIT(= NULL); +*** ../vim-7.3.596/src/proto/ui.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/ui.pro 2012-07-10 16:37:35.000000000 +0200 +*************** +*** 11,27 **** + void ui_new_shellsize __ARGS((void)); + void ui_breakcheck __ARGS((void)); + void clip_init __ARGS((int can_use)); +! void clip_update_selection __ARGS((void)); + void clip_own_selection __ARGS((VimClipboard *cbd)); + void clip_lose_selection __ARGS((VimClipboard *cbd)); +- void clip_copy_selection __ARGS((void)); + void clip_auto_select __ARGS((void)); +! int clip_isautosel __ARGS((void)); + void clip_modeless __ARGS((int button, int is_click, int is_drag)); + void clip_start_selection __ARGS((int col, int row, int repeated_click)); + void clip_process_selection __ARGS((int button, int col, int row, int_u repeated_click)); + void clip_may_redraw_selection __ARGS((int row, int col, int len)); +! void clip_clear_selection __ARGS((void)); + void clip_may_clear_selection __ARGS((int row1, int row2)); + void clip_scroll_selection __ARGS((int rows)); + void clip_copy_modeless_selection __ARGS((int both)); +--- 11,27 ---- + void ui_new_shellsize __ARGS((void)); + void ui_breakcheck __ARGS((void)); + void clip_init __ARGS((int can_use)); +! void clip_update_selection __ARGS((VimClipboard *clip)); + void clip_own_selection __ARGS((VimClipboard *cbd)); + void clip_lose_selection __ARGS((VimClipboard *cbd)); + void clip_auto_select __ARGS((void)); +! int clip_isautosel_star __ARGS((void)); +! int clip_isautosel_plus __ARGS((void)); + void clip_modeless __ARGS((int button, int is_click, int is_drag)); + void clip_start_selection __ARGS((int col, int row, int repeated_click)); + void clip_process_selection __ARGS((int button, int col, int row, int_u repeated_click)); + void clip_may_redraw_selection __ARGS((int row, int col, int len)); +! void clip_clear_selection __ARGS((VimClipboard *cbd)); + void clip_may_clear_selection __ARGS((int row1, int row2)); + void clip_scroll_selection __ARGS((int rows)); + void clip_copy_modeless_selection __ARGS((int both)); +*** ../vim-7.3.596/src/option.h 2012-06-06 16:12:54.000000000 +0200 +--- src/option.h 2012-07-10 15:54:32.000000000 +0200 +*************** +*** 229,234 **** +--- 229,235 ---- + #define GO_MENUS 'm' /* use menu bar */ + #define GO_NOSYSMENU 'M' /* don't source system menu */ + #define GO_POINTER 'p' /* pointer enter/leave callbacks */ ++ #define GO_ASELPLUS 'P' /* autoselectPlus */ + #define GO_RIGHT 'r' /* use right scrollbar */ + #define GO_VRIGHT 'R' /* right scrollbar with vert split */ + #define GO_TEAROFF 't' /* add tear-off menu items */ +*** ../vim-7.3.596/src/gui.c 2012-05-27 00:37:45.000000000 +0200 +--- src/gui.c 2012-07-10 16:43:34.000000000 +0200 +*************** +*** 3154,3160 **** + } + + if (clip_star.state != SELECT_CLEARED && !did_clip) +! clip_clear_selection(); + #endif + + /* Don't put events in the input queue now. */ +--- 3154,3160 ---- + } + + if (clip_star.state != SELECT_CLEARED && !did_clip) +! clip_clear_selection(&clip_star); + #endif + + /* Don't put events in the input queue now. */ +*** ../vim-7.3.596/src/version.c 2012-07-10 15:18:18.000000000 +0200 +--- src/version.c 2012-07-10 16:32:16.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 597, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +106. When told to "go to your room" you inform your parents that you + can't...because you were kicked out and banned. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 019b29ff5384727d33d424088f386ce970e453a3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:58 +0200 Subject: [PATCH 0419/3340] - patchlevel 598 --- 7.3.598 | 73 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 7.3.598 diff --git a/7.3.598 b/7.3.598 new file mode 100644 index 00000000..3a38b4a7 --- /dev/null +++ b/7.3.598 @@ -0,0 +1,73 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.598 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.598 +Problem: Cannot act upon end of completion. (Taro Muraoka) +Solution: Add an autocommand event that is triggered when completion has + finished. (Idea by Florian Klein) +Files: src/edit.c, src/fileio.c, src/vim.h + + +*** ../vim-7.3.597/src/edit.c 2012-07-06 13:36:36.000000000 +0200 +--- src/edit.c 2012-07-10 17:02:37.000000000 +0200 +*************** +*** 3824,3829 **** +--- 3824,3834 ---- + if (want_cindent && in_cinkeys(KEY_COMPLETE, ' ', inindent(0))) + do_c_expr_indent(); + #endif ++ #ifdef FEAT_AUTOCMD ++ /* Trigger the CompleteDone event to give scripts a chance to act ++ * upon the completion. */ ++ apply_autocmds(EVENT_COMPLETEDONE, NULL, NULL, FALSE, curbuf); ++ #endif + } + } + +*** ../vim-7.3.597/src/fileio.c 2012-06-13 14:28:16.000000000 +0200 +--- src/fileio.c 2012-07-10 17:05:51.000000000 +0200 +*************** +*** 7643,7648 **** +--- 7643,7649 ---- + {"CmdwinEnter", EVENT_CMDWINENTER}, + {"CmdwinLeave", EVENT_CMDWINLEAVE}, + {"ColorScheme", EVENT_COLORSCHEME}, ++ {"CompleteDone", EVENT_COMPLETEDONE}, + {"CursorHold", EVENT_CURSORHOLD}, + {"CursorHoldI", EVENT_CURSORHOLDI}, + {"CursorMoved", EVENT_CURSORMOVED}, +*** ../vim-7.3.597/src/vim.h 2012-07-10 13:41:09.000000000 +0200 +--- src/vim.h 2012-07-10 17:06:24.000000000 +0200 +*************** +*** 1241,1246 **** +--- 1241,1247 ---- + EVENT_CMDWINENTER, /* after entering the cmdline window */ + EVENT_CMDWINLEAVE, /* before leaving the cmdline window */ + EVENT_COLORSCHEME, /* after loading a colorscheme */ ++ EVENT_COMPLETEDONE, /* after finishing insert complete */ + EVENT_FILEAPPENDPOST, /* after appending to a file */ + EVENT_FILEAPPENDPRE, /* before appending to a file */ + EVENT_FILEAPPENDCMD, /* append to a file using command */ +*** ../vim-7.3.597/src/version.c 2012-07-10 16:49:08.000000000 +0200 +--- src/version.c 2012-07-10 17:08:41.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 598, + /**/ + +-- +Laughing helps. It's like jogging on the inside. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b35e8f3fecd66f93f7b5a8aeb70ae31913a6b379 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:58 +0200 Subject: [PATCH 0420/3340] - patchlevel 599 --- 7.3.599 | 107 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 107 insertions(+) create mode 100644 7.3.599 diff --git a/7.3.599 b/7.3.599 new file mode 100644 index 00000000..adfe6f99 --- /dev/null +++ b/7.3.599 @@ -0,0 +1,107 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.599 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.599 (after 7.3.597) +Problem: Missing change in one file. +Solution: Patch for changed clip_autoselect(). +Files: src/option.c + + +*** ../vim-7.3.598/src/option.c 2012-06-29 15:51:26.000000000 +0200 +--- src/option.c 2012-07-10 16:35:07.000000000 +0200 +*************** +*** 7377,7383 **** + check_clipboard_option() + { + int new_unnamed = 0; +! int new_autoselect = FALSE; + int new_autoselectml = FALSE; + int new_html = FALSE; + regprog_T *new_exclude_prog = NULL; +--- 7377,7384 ---- + check_clipboard_option() + { + int new_unnamed = 0; +! int new_autoselect_star = FALSE; +! int new_autoselect_plus = FALSE; + int new_autoselectml = FALSE; + int new_html = FALSE; + regprog_T *new_exclude_prog = NULL; +*************** +*** 7398,7410 **** + p += 11; + } + else if (STRNCMP(p, "autoselect", 10) == 0 +! && (p[10] == ',' || p[10] == NUL)) + { +! new_autoselect = TRUE; + p += 10; + } + else if (STRNCMP(p, "autoselectml", 12) == 0 +! && (p[12] == ',' || p[12] == NUL)) + { + new_autoselectml = TRUE; + p += 12; +--- 7399,7417 ---- + p += 11; + } + else if (STRNCMP(p, "autoselect", 10) == 0 +! && (p[10] == ',' || p[10] == NUL)) + { +! new_autoselect_star = TRUE; + p += 10; + } ++ else if (STRNCMP(p, "autoselectplus", 14) == 0 ++ && (p[14] == ',' || p[14] == NUL)) ++ { ++ new_autoselect_plus = TRUE; ++ p += 14; ++ } + else if (STRNCMP(p, "autoselectml", 12) == 0 +! && (p[12] == ',' || p[12] == NUL)) + { + new_autoselectml = TRUE; + p += 12; +*************** +*** 7433,7439 **** + if (errmsg == NULL) + { + clip_unnamed = new_unnamed; +! clip_autoselect = new_autoselect; + clip_autoselectml = new_autoselectml; + clip_html = new_html; + vim_free(clip_exclude_prog); +--- 7440,7447 ---- + if (errmsg == NULL) + { + clip_unnamed = new_unnamed; +! clip_autoselect_star = new_autoselect_star; +! clip_autoselect_plus = new_autoselect_plus; + clip_autoselectml = new_autoselectml; + clip_html = new_html; + vim_free(clip_exclude_prog); +*** ../vim-7.3.598/src/version.c 2012-07-10 17:14:50.000000000 +0200 +--- src/version.c 2012-07-10 18:30:17.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 599, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +108. While reading a magazine, you look for the Zoom icon for a better + look at a photograph. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b1748bbd9361d3fd894c0ae8f515dec657387f05 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:58 +0200 Subject: [PATCH 0421/3340] - patchlevel 600 --- 7.3.600 | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 7.3.600 diff --git a/7.3.600 b/7.3.600 new file mode 100644 index 00000000..6504da01 --- /dev/null +++ b/7.3.600 @@ -0,0 +1,68 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.600 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.600 +Problem: is not expanded properly with DBCS encoding. +Solution: Skip over character instead of byte. (Yukihiro Nakadaira) +Files: src/ex_docmd.c + + +*** ../vim-7.3.599/src/ex_docmd.c 2012-07-06 18:27:34.000000000 +0200 +--- src/ex_docmd.c 2012-07-10 19:20:10.000000000 +0200 +*************** +*** 5845,5852 **** +--- 5845,5858 ---- + } + else + { ++ #ifdef FEAT_MBYTE ++ int charlen = (*mb_ptr2len)(p); ++ len += charlen; ++ p += charlen; ++ #else + ++len; + ++p; ++ #endif + } + } + +*************** +*** 5889,5895 **** + } + else + { +! *q++ = *p++; + } + } + *q++ = '"'; +--- 5895,5901 ---- + } + else + { +! MB_COPY_CHAR(p, q); + } + } + *q++ = '"'; +*** ../vim-7.3.599/src/version.c 2012-07-10 18:31:49.000000000 +0200 +--- src/version.c 2012-07-10 19:21:29.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 600, + /**/ + +-- +In a world without walls and borders, who needs windows and gates? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3f5cce6d270022218dc409ad34605694d9f77234 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:59 +0200 Subject: [PATCH 0422/3340] - patchlevel 601 --- 7.3.601 | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 7.3.601 diff --git a/7.3.601 b/7.3.601 new file mode 100644 index 00000000..b61a9331 --- /dev/null +++ b/7.3.601 @@ -0,0 +1,51 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.601 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.601 +Problem: Bad code style. +Solution: Insert space, remove parens. +Files: src/farsi.c + + +*** ../vim-7.3.600/src/farsi.c 2010-08-15 21:57:28.000000000 +0200 +--- src/farsi.c 2012-07-12 21:59:15.000000000 +0200 +*************** +*** 1813,1819 **** + ptr[i] = toF_leading(ptr[i]); + ++i; + +! while(canF_Rjoin(ptr[i]) && (i < llen)) + { + ptr[i] = toF_Rjoin(ptr[i]); + if (F_isterm(ptr[i]) || !F_isalpha(ptr[i])) +--- 1813,1819 ---- + ptr[i] = toF_leading(ptr[i]); + ++i; + +! while (canF_Rjoin(ptr[i]) && i < llen) + { + ptr[i] = toF_Rjoin(ptr[i]); + if (F_isterm(ptr[i]) || !F_isalpha(ptr[i])) +*** ../vim-7.3.600/src/version.c 2012-07-10 19:25:06.000000000 +0200 +--- src/version.c 2012-07-16 17:25:48.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 601, + /**/ + +-- +There are three kinds of persons: Those who can count and those who can't. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 40f992febd5bbfc86c97da74540f9ca1d70b58b7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:53:59 +0200 Subject: [PATCH 0423/3340] - patchlevel 602 --- 7.3.602 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.602 diff --git a/7.3.602 b/7.3.602 new file mode 100644 index 00000000..fd5f3cf4 --- /dev/null +++ b/7.3.602 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.602 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.602 +Problem: Missing files in distribution. +Solution: Update the list of files. +Files: Filelist + + +*** ../vim-7.3.601/Filelist 2011-10-20 16:35:25.000000000 +0200 +--- Filelist 2012-06-20 12:06:41.000000000 +0200 +*************** +*** 463,468 **** +--- 463,469 ---- + runtime/macros/hanoi/hanoi.vim \ + runtime/macros/hanoi/poster \ + runtime/macros/justify.vim \ ++ runtime/macros/less.bat \ + runtime/macros/less.sh \ + runtime/macros/less.vim \ + runtime/macros/life/click.me \ +*************** +*** 666,671 **** +--- 667,674 ---- + + # generic language files + LANG_GEN = \ ++ runtime/doc/*-de.1 \ ++ runtime/doc/*-de.UTF-8.1 \ + runtime/doc/*-fr.1 \ + runtime/doc/*-fr.UTF-8.1 \ + runtime/doc/*-it.1 \ +*** ../vim-7.3.601/src/version.c 2012-07-16 17:26:18.000000000 +0200 +--- src/version.c 2012-07-16 17:27:31.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 602, + /**/ + +-- +Never eat yellow snow. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 37f315b1ebf5004f7633960d6e938526a0d7e2a2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:00 +0200 Subject: [PATCH 0424/3340] - patchlevel 603 --- 7.3.603 | 370 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 370 insertions(+) create mode 100644 7.3.603 diff --git a/7.3.603 b/7.3.603 new file mode 100644 index 00000000..00a024b0 --- /dev/null +++ b/7.3.603 @@ -0,0 +1,370 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.603 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.603 +Problem: It is possible to add replace builtin functions by calling + extend() on g:. +Solution: Add a flag to a dict to indicate it is a scope. Check for + existing functions. (ZyX) +Files: src/buffer.c, src/eval.c, src/proto/eval.pro, src/structs.h, + src/testdir/test34.in, src/testdir/test34.ok, src/window.c + + +*** ../vim-7.3.602/src/buffer.c 2012-07-10 15:18:18.000000000 +0200 +--- src/buffer.c 2012-07-16 16:52:58.000000000 +0200 +*************** +*** 1747,1753 **** + buf->b_wininfo->wi_win = curwin; + + #ifdef FEAT_EVAL +! init_var_dict(&buf->b_vars, &buf->b_bufvar); /* init b: variables */ + #endif + #ifdef FEAT_SYN_HL + hash_init(&buf->b_s.b_keywtab); +--- 1747,1754 ---- + buf->b_wininfo->wi_win = curwin; + + #ifdef FEAT_EVAL +! /* init b: variables */ +! init_var_dict(&buf->b_vars, &buf->b_bufvar, VAR_SCOPE); + #endif + #ifdef FEAT_SYN_HL + hash_init(&buf->b_s.b_keywtab); +*** ../vim-7.3.602/src/eval.c 2012-07-10 13:41:09.000000000 +0200 +--- src/eval.c 2012-07-16 17:18:11.000000000 +0200 +*************** +*** 850,857 **** + int i; + struct vimvar *p; + +! init_var_dict(&globvardict, &globvars_var); +! init_var_dict(&vimvardict, &vimvars_var); + vimvardict.dv_lock = VAR_FIXED; + hash_init(&compat_hashtab); + hash_init(&func_hashtab); +--- 850,857 ---- + int i; + struct vimvar *p; + +! init_var_dict(&globvardict, &globvars_var, VAR_DEF_SCOPE); +! init_var_dict(&vimvardict, &vimvars_var, VAR_SCOPE); + vimvardict.dv_lock = VAR_FIXED; + hash_init(&compat_hashtab); + hash_init(&func_hashtab); +*************** +*** 2725,2738 **** + lp->ll_dict = lp->ll_tv->vval.v_dict; + lp->ll_di = dict_find(lp->ll_dict, key, len); + +! /* When assigning to g: check that a function and variable name is +! * valid. */ +! if (rettv != NULL && lp->ll_dict == &globvardict) + { +! if (rettv->v_type == VAR_FUNC + && var_check_func_name(key, lp->ll_di == NULL)) +! return NULL; +! if (!valid_varname(key)) + return NULL; + } + +--- 2725,2750 ---- + lp->ll_dict = lp->ll_tv->vval.v_dict; + lp->ll_di = dict_find(lp->ll_dict, key, len); + +! /* When assigning to a scope dictionary check that a function and +! * variable name is valid (only variable name unless it is l: or +! * g: dictionary). Disallow overwriting a builtin function. */ +! if (rettv != NULL && lp->ll_dict->dv_scope != 0) + { +! int prevval; +! int wrong; +! +! if (len != -1) +! { +! prevval = key[len]; +! key[len] = NUL; +! } +! wrong = (lp->ll_dict->dv_scope == VAR_DEF_SCOPE +! && rettv->v_type == VAR_FUNC + && var_check_func_name(key, lp->ll_di == NULL)) +! || !valid_varname(key); +! if (len != -1) +! key[len] = prevval; +! if (wrong) + return NULL; + } + +*************** +*** 6951,6957 **** + d = (dict_T *)alloc(sizeof(dict_T)); + if (d != NULL) + { +! /* Add the list to the list of dicts for garbage collection. */ + if (first_dict != NULL) + first_dict->dv_used_prev = d; + d->dv_used_next = first_dict; +--- 6963,6969 ---- + d = (dict_T *)alloc(sizeof(dict_T)); + if (d != NULL) + { +! /* Add the dict to the list of dicts for garbage collection. */ + if (first_dict != NULL) + first_dict->dv_used_prev = d; + d->dv_used_next = first_dict; +*************** +*** 6960,6965 **** +--- 6972,6978 ---- + + hash_init(&d->dv_hashtab); + d->dv_lock = 0; ++ d->dv_scope = 0; + d->dv_refcount = 0; + d->dv_copyID = 0; + } +*************** +*** 10203,10208 **** +--- 10216,10234 ---- + { + --todo; + di1 = dict_find(d1, hi2->hi_key, -1); ++ if (d1->dv_scope != 0) ++ { ++ /* Disallow replacing a builtin function in l: and g:. ++ * Check the key to be valid when adding to any ++ * scope. */ ++ if (d1->dv_scope == VAR_DEF_SCOPE ++ && HI2DI(hi2)->di_tv.v_type == VAR_FUNC ++ && var_check_func_name(hi2->hi_key, ++ di1 == NULL)) ++ break; ++ if (!valid_varname(hi2->hi_key)) ++ break; ++ } + if (di1 == NULL) + { + di1 = dictitem_copy(HI2DI(hi2)); +*************** +*** 20027,20033 **** + { + sv = SCRIPT_SV(ga_scripts.ga_len + 1) = + (scriptvar_T *)alloc_clear(sizeof(scriptvar_T)); +! init_var_dict(&sv->sv_dict, &sv->sv_var); + ++ga_scripts.ga_len; + } + } +--- 20053,20059 ---- + { + sv = SCRIPT_SV(ga_scripts.ga_len + 1) = + (scriptvar_T *)alloc_clear(sizeof(scriptvar_T)); +! init_var_dict(&sv->sv_dict, &sv->sv_var, VAR_SCOPE); + ++ga_scripts.ga_len; + } + } +*************** +*** 20038,20049 **** + * point to it. + */ + void +! init_var_dict(dict, dict_var) + dict_T *dict; + dictitem_T *dict_var; + { + hash_init(&dict->dv_hashtab); + dict->dv_lock = 0; + dict->dv_refcount = DO_NOT_FREE_CNT; + dict->dv_copyID = 0; + dict_var->di_tv.vval.v_dict = dict; +--- 20064,20077 ---- + * point to it. + */ + void +! init_var_dict(dict, dict_var, scope) + dict_T *dict; + dictitem_T *dict_var; ++ int scope; + { + hash_init(&dict->dv_hashtab); + dict->dv_lock = 0; ++ dict->dv_scope = scope; + dict->dv_refcount = DO_NOT_FREE_CNT; + dict->dv_copyID = 0; + dict_var->di_tv.vval.v_dict = dict; +*************** +*** 22304,22310 **** + /* + * Init l: variables. + */ +! init_var_dict(&fc->l_vars, &fc->l_vars_var); + if (selfdict != NULL) + { + /* Set l:self to "selfdict". Use "name" to avoid a warning from +--- 22332,22338 ---- + /* + * Init l: variables. + */ +! init_var_dict(&fc->l_vars, &fc->l_vars_var, VAR_DEF_SCOPE); + if (selfdict != NULL) + { + /* Set l:self to "selfdict". Use "name" to avoid a warning from +*************** +*** 22325,22331 **** + * Set a:0 to "argcount". + * Set a:000 to a list with room for the "..." arguments. + */ +! init_var_dict(&fc->l_avars, &fc->l_avars_var); + add_nr_var(&fc->l_avars, &fc->fixvar[fixvar_idx++].var, "0", + (varnumber_T)(argcount - fp->uf_args.ga_len)); + /* Use "name" to avoid a warning from some compiler that checks the +--- 22353,22359 ---- + * Set a:0 to "argcount". + * Set a:000 to a list with room for the "..." arguments. + */ +! init_var_dict(&fc->l_avars, &fc->l_avars_var, VAR_SCOPE); + add_nr_var(&fc->l_avars, &fc->fixvar[fixvar_idx++].var, "0", + (varnumber_T)(argcount - fp->uf_args.ga_len)); + /* Use "name" to avoid a warning from some compiler that checks the +*** ../vim-7.3.602/src/proto/eval.pro 2012-06-29 12:54:32.000000000 +0200 +--- src/proto/eval.pro 2012-07-16 16:55:16.000000000 +0200 +*************** +*** 93,99 **** + char_u *get_tv_string_chk __ARGS((typval_T *varp)); + char_u *get_var_value __ARGS((char_u *name)); + void new_script_vars __ARGS((scid_T id)); +! void init_var_dict __ARGS((dict_T *dict, dictitem_T *dict_var)); + void vars_clear __ARGS((hashtab_T *ht)); + void copy_tv __ARGS((typval_T *from, typval_T *to)); + void ex_echo __ARGS((exarg_T *eap)); +--- 93,99 ---- + char_u *get_tv_string_chk __ARGS((typval_T *varp)); + char_u *get_var_value __ARGS((char_u *name)); + void new_script_vars __ARGS((scid_T id)); +! void init_var_dict __ARGS((dict_T *dict, dictitem_T *dict_var, int scope)); + void vars_clear __ARGS((hashtab_T *ht)); + void copy_tv __ARGS((typval_T *from, typval_T *to)); + void ex_echo __ARGS((exarg_T *eap)); +*** ../vim-7.3.602/src/structs.h 2012-06-06 19:02:40.000000000 +0200 +--- src/structs.h 2012-07-16 16:56:43.000000000 +0200 +*************** +*** 1106,1111 **** +--- 1106,1116 ---- + #define VAR_DICT 5 /* "v_dict" is used */ + #define VAR_FLOAT 6 /* "v_float" is used */ + ++ /* Values for "dv_scope". */ ++ #define VAR_SCOPE 1 /* a:, v:, s:, etc. scope dictionaries */ ++ #define VAR_DEF_SCOPE 2 /* l:, g: scope dictionaries: here funcrefs are not ++ allowed to mask existing functions */ ++ + /* Values for "v_lock". */ + #define VAR_LOCKED 1 /* locked with lock(), can use unlock() */ + #define VAR_FIXED 2 /* locked forever */ +*************** +*** 1181,1186 **** +--- 1186,1192 ---- + int dv_copyID; /* ID used by deepcopy() */ + dict_T *dv_copydict; /* copied dict used by deepcopy() */ + char dv_lock; /* zero, VAR_LOCKED, VAR_FIXED */ ++ char dv_scope; /* zero, VAR_SCOPE, VAR_DEF_SCOPE */ + dict_T *dv_used_next; /* next dict in used dicts list */ + dict_T *dv_used_prev; /* previous dict in used dicts list */ + }; +*** ../vim-7.3.602/src/testdir/test34.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test34.in 2012-07-16 16:51:29.000000000 +0200 +*************** +*** 1,5 **** +--- 1,6 ---- + Test for user functions. + Also test an mapping calling a function. ++ Also test that a builtin function cannot be replaced. + + STARTTEST + :so small.vim +*************** +*** 58,64 **** + ---*--- + (one + (two +! [(one again:$-5,$w! test.out + :delfunc Table + :delfunc Compute + :delfunc Expr1 +--- 59,68 ---- + ---*--- + (one + (two +! [(one again:call append(line('$'), max([1, 2, 3])) +! :call extend(g:, {'max': function('min')}) +! :call append(line('$'), max([1, 2, 3])) +! :$-7,$w! test.out + :delfunc Table + :delfunc Compute + :delfunc Expr1 +*** ../vim-7.3.602/src/testdir/test34.ok 2011-10-12 22:02:07.000000000 +0200 +--- src/testdir/test34.ok 2012-07-16 16:43:15.000000000 +0200 +*************** +*** 4,6 **** +--- 4,8 ---- + 1. one + 2. two + 1. one again ++ 3 ++ 3 +*** ../vim-7.3.602/src/window.c 2012-07-06 18:27:34.000000000 +0200 +--- src/window.c 2012-07-16 16:53:45.000000000 +0200 +*************** +*** 3468,3474 **** + # endif + #ifdef FEAT_EVAL + /* init t: variables */ +! init_var_dict(&tp->tp_vars, &tp->tp_winvar); + #endif + tp->tp_ch_used = p_ch; + } +--- 3468,3474 ---- + # endif + #ifdef FEAT_EVAL + /* init t: variables */ +! init_var_dict(&tp->tp_vars, &tp->tp_winvar, VAR_SCOPE); + #endif + tp->tp_ch_used = p_ch; + } +*************** +*** 4410,4416 **** + #endif + #ifdef FEAT_EVAL + /* init w: variables */ +! init_var_dict(&new_wp->w_vars, &new_wp->w_winvar); + #endif + #ifdef FEAT_FOLDING + foldInitWin(new_wp); +--- 4410,4416 ---- + #endif + #ifdef FEAT_EVAL + /* init w: variables */ +! init_var_dict(&new_wp->w_vars, &new_wp->w_winvar, VAR_SCOPE); + #endif + #ifdef FEAT_FOLDING + foldInitWin(new_wp); +*** ../vim-7.3.602/src/version.c 2012-07-16 17:27:57.000000000 +0200 +--- src/version.c 2012-07-16 17:29:06.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 603, + /**/ + +-- +Birthdays are healthy. The more you have them, the longer you live. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f9641862c0011698bcc90ca0f3ee572f17c9a47b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:00 +0200 Subject: [PATCH 0425/3340] - patchlevel 604 --- 7.3.604 | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 7.3.604 diff --git a/7.3.604 b/7.3.604 new file mode 100644 index 00000000..f7e63bd0 --- /dev/null +++ b/7.3.604 @@ -0,0 +1,60 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.604 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.604 +Problem: inputdialog() doesn't use the cancel argument in the console. + (David Fishburn) +Solution: Use the third argument. (Christian Brabant) +Files: src/eval.c + + +*** ../vim-7.3.603/src/eval.c 2012-07-16 17:31:48.000000000 +0200 +--- src/eval.c 2012-07-16 19:20:47.000000000 +0200 +*************** +*** 12940,12945 **** +--- 12940,12946 ---- + int xp_namelen; + long argt; + ++ /* input() with a third argument: completion */ + rettv->vval.v_string = NULL; + + xp_name = get_tv_string_buf_chk(&argvars[2], buf); +*************** +*** 12958,12963 **** +--- 12959,12969 ---- + rettv->vval.v_string = + getcmdline_prompt(inputsecret_flag ? NUL : '@', p, echo_attr, + xp_type, xp_arg); ++ if (rettv->vval.v_string == NULL ++ && argvars[1].v_type != VAR_UNKNOWN ++ && argvars[2].v_type != VAR_UNKNOWN) ++ rettv->vval.v_string = vim_strsave(get_tv_string_buf( ++ &argvars[2], buf)); + + vim_free(xp_arg); + +*** ../vim-7.3.603/src/version.c 2012-07-16 17:31:48.000000000 +0200 +--- src/version.c 2012-07-16 19:23:11.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 604, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +135. You cut classes or miss work so you can stay home and browse the web. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fe5e7bf2d66733bf978f0b4ea94ef63480293ca1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:00 +0200 Subject: [PATCH 0426/3340] - patchlevel 605 --- 7.3.605 | 86 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 7.3.605 diff --git a/7.3.605 b/7.3.605 new file mode 100644 index 00000000..70338251 --- /dev/null +++ b/7.3.605 @@ -0,0 +1,86 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.605 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.605 (after 7.3.577) +Problem: MS-Windows: Can't compile with older compilers. (Titov Anatoly) +Solution: Add #ifdef for MEMORYSTATUSEX. +Files: src/os_win32.c + + +*** ../vim-7.3.604/src/os_win32.c 2012-06-29 15:51:26.000000000 +0200 +--- src/os_win32.c 2012-07-19 11:35:00.000000000 +0200 +*************** +*** 4999,5020 **** + long_u + mch_avail_mem(int special) + { +! if (g_PlatformId != VER_PLATFORM_WIN32_NT) +! { +! MEMORYSTATUS ms; +! +! ms.dwLength = sizeof(MEMORYSTATUS); +! GlobalMemoryStatus(&ms); +! return (long_u)((ms.dwAvailPhys + ms.dwAvailPageFile) >> 10); +! } +! else + { + MEMORYSTATUSEX ms; + + ms.dwLength = sizeof(MEMORYSTATUSEX); + GlobalMemoryStatusEx(&ms); + return (long_u)((ms.ullAvailPhys + ms.ullAvailPageFile) >> 10); + } + } + + #ifdef FEAT_MBYTE +--- 4999,5025 ---- + long_u + mch_avail_mem(int special) + { +! #ifdef MEMORYSTATUSEX +! PlatformId(); +! if (g_PlatformId == VER_PLATFORM_WIN32_NT) + { + MEMORYSTATUSEX ms; + ++ /* Need to use GlobalMemoryStatusEx() when there is more memory than ++ * what fits in 32 bits. But it's not always available. */ + ms.dwLength = sizeof(MEMORYSTATUSEX); + GlobalMemoryStatusEx(&ms); + return (long_u)((ms.ullAvailPhys + ms.ullAvailPageFile) >> 10); + } ++ else ++ #endif ++ { ++ MEMORYSTATUS ms; ++ ++ ms.dwLength = sizeof(MEMORYSTATUS); ++ GlobalMemoryStatus(&ms); ++ return (long_u)((ms.dwAvailPhys + ms.dwAvailPageFile) >> 10); ++ } + } + + #ifdef FEAT_MBYTE +*** ../vim-7.3.604/src/version.c 2012-07-16 19:27:25.000000000 +0200 +--- src/version.c 2012-07-19 11:36:12.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 605, + /**/ + +-- +Fingers not found - Pound head on keyboard to continue. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4fd8e176f9acebdbb44031bcaa7d5803913e450d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:00 +0200 Subject: [PATCH 0427/3340] - patchlevel 606 --- 7.3.606 | 76 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 7.3.606 diff --git a/7.3.606 b/7.3.606 new file mode 100644 index 00000000..2296653c --- /dev/null +++ b/7.3.606 @@ -0,0 +1,76 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.606 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.606 +Problem: CTRL-P completion has a problem with multi-byte characters. +Solution: Check for next character being NUL properly. (Yasuhiro Matsumoto) +Files: src/search.c, src/macros.h + + +*** ../vim-7.3.605/src/search.c 2012-06-06 16:12:54.000000000 +0200 +--- src/search.c 2012-07-19 17:09:20.000000000 +0200 +*************** +*** 5141,5147 **** + && !(compl_cont_status & CONT_SOL) + #endif + && *startp != NUL +! && *(p = startp + 1) != NUL) + goto search_line; + } + line_breakcheck(); +--- 5141,5147 ---- + && !(compl_cont_status & CONT_SOL) + #endif + && *startp != NUL +! && *(p = startp + MB_PTR2LEN(startp)) != NUL) + goto search_line; + } + line_breakcheck(); +*** ../vim-7.3.605/src/macros.h 2010-09-21 16:56:29.000000000 +0200 +--- src/macros.h 2012-07-19 17:08:38.000000000 +0200 +*************** +*** 259,264 **** +--- 259,266 ---- + * PTR2CHAR(): get character from pointer. + */ + #ifdef FEAT_MBYTE ++ /* Get the length of the character p points to */ ++ # define MB_PTR2LEN(p) (has_mbyte ? (*mb_ptr2len)(p) : 1) + /* Advance multi-byte pointer, skip over composing chars. */ + # define mb_ptr_adv(p) p += has_mbyte ? (*mb_ptr2len)(p) : 1 + /* Advance multi-byte pointer, do not skip over composing chars. */ +*************** +*** 272,277 **** +--- 274,280 ---- + # define MB_CHARLEN(p) (has_mbyte ? mb_charlen(p) : (int)STRLEN(p)) + # define PTR2CHAR(p) (has_mbyte ? mb_ptr2char(p) : (int)*(p)) + #else ++ # define MB_PTR2LEN(p) 1 + # define mb_ptr_adv(p) ++p + # define mb_cptr_adv(p) ++p + # define mb_ptr_back(s, p) --p +*** ../vim-7.3.605/src/version.c 2012-07-19 11:37:22.000000000 +0200 +--- src/version.c 2012-07-19 17:13:53.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 606, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +151. You find yourself engaged to someone you've never actually met, + except through e-mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 662b6670ea7f747d135c63b5f75d0b4b49591adf Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:01 +0200 Subject: [PATCH 0428/3340] - patchlevel 607 --- 7.3.607 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.607 diff --git a/7.3.607 b/7.3.607 new file mode 100644 index 00000000..4dbf559d --- /dev/null +++ b/7.3.607 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.607 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.607 +Problem: With an 8 color terminal the selected menu item is black on black, + because darkGrey as bg is the same as black. +Solution: Swap fg and bg colors. (James McCoy) +Files: src/syntax.c + + +*** ../vim-7.3.606/src/syntax.c 2012-06-01 13:18:48.000000000 +0200 +--- src/syntax.c 2012-07-19 17:34:42.000000000 +0200 +*************** +*** 6653,6660 **** + "PmenuThumb ctermbg=White guibg=White"), + CENT("Pmenu ctermbg=Magenta ctermfg=Black", + "Pmenu ctermbg=Magenta ctermfg=Black guibg=Magenta"), +! CENT("PmenuSel ctermbg=DarkGrey ctermfg=Black", +! "PmenuSel ctermbg=DarkGrey ctermfg=Black guibg=DarkGrey"), + #endif + CENT("Title term=bold ctermfg=LightMagenta", + "Title term=bold ctermfg=LightMagenta gui=bold guifg=Magenta"), +--- 6653,6660 ---- + "PmenuThumb ctermbg=White guibg=White"), + CENT("Pmenu ctermbg=Magenta ctermfg=Black", + "Pmenu ctermbg=Magenta ctermfg=Black guibg=Magenta"), +! CENT("PmenuSel ctermbg=Black ctermfg=DarkGrey", +! "PmenuSel ctermbg=Black ctermfg=DarkGrey guibg=DarkGrey"), + #endif + CENT("Title term=bold ctermfg=LightMagenta", + "Title term=bold ctermfg=LightMagenta gui=bold guifg=Magenta"), +*** ../vim-7.3.606/src/version.c 2012-07-19 17:18:21.000000000 +0200 +--- src/version.c 2012-07-19 17:38:05.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 607, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +152. You find yourself falling for someone you've never seen or hardly + know, but, boy can he/she TYPE!!!!!! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d46efc300963a83ad8d50831fd2cd59da5ee8ddc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:01 +0200 Subject: [PATCH 0429/3340] - patchlevel 608 --- 7.3.608 | 119 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 119 insertions(+) create mode 100644 7.3.608 diff --git a/7.3.608 b/7.3.608 new file mode 100644 index 00000000..148bc494 --- /dev/null +++ b/7.3.608 @@ -0,0 +1,119 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.608 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.608 +Problem: winrestview() does not always restore the view correctly. +Solution: Call win_new_height() and win_new_width(). (Lech Lorens) +Files: src/eval.c, src/proto/window.pro, src/window.c + + +*** ../vim-7.3.607/src/eval.c 2012-07-16 19:27:25.000000000 +0200 +--- src/eval.c 2012-07-19 17:50:16.000000000 +0200 +*************** +*** 18601,18606 **** +--- 18601,18610 ---- + curwin->w_skipcol = get_dict_number(dict, (char_u *)"skipcol"); + + check_cursor(); ++ win_new_height(curwin, curwin->w_height); ++ # ifdef FEAT_VERTSPLIT ++ win_new_width(curwin, W_WIDTH(curwin)); ++ # endif + changed_window_setting(); + + if (curwin->w_topline == 0) +*** ../vim-7.3.607/src/proto/window.pro 2012-06-13 14:28:16.000000000 +0200 +--- src/proto/window.pro 2012-07-19 18:05:10.000000000 +0200 +*************** +*** 51,56 **** +--- 51,58 ---- + void win_setminheight __ARGS((void)); + void win_drag_status_line __ARGS((win_T *dragwin, int offset)); + void win_drag_vsep_line __ARGS((win_T *dragwin, int offset)); ++ void win_new_height __ARGS((win_T *wp, int height)); ++ void win_new_width __ARGS((win_T *wp, int width)); + void win_comp_scroll __ARGS((win_T *wp)); + void command_height __ARGS((void)); + void last_status __ARGS((int morewin)); +*** ../vim-7.3.607/src/window.c 2012-07-16 17:31:48.000000000 +0200 +--- src/window.c 2012-07-19 18:05:18.000000000 +0200 +*************** +*** 54,60 **** + static void frame_insert __ARGS((frame_T *before, frame_T *frp)); + static void frame_remove __ARGS((frame_T *frp)); + #ifdef FEAT_VERTSPLIT +- static void win_new_width __ARGS((win_T *wp, int width)); + static void win_goto_ver __ARGS((int up, long count)); + static void win_goto_hor __ARGS((int left, long count)); + #endif +--- 54,59 ---- +*************** +*** 71,77 **** + + static win_T *win_alloc __ARGS((win_T *after, int hidden)); + static void set_fraction __ARGS((win_T *wp)); +- static void win_new_height __ARGS((win_T *wp, int height)); + + #define URL_SLASH 1 /* path_is_url() has found "://" */ + #define URL_BACKSLASH 2 /* path_is_url() has found ":\\" */ +--- 70,75 ---- +*************** +*** 5557,5563 **** + * This takes care of the things inside the window, not what happens to the + * window position, the frame or to other windows. + */ +! static void + win_new_height(wp, height) + win_T *wp; + int height; +--- 5555,5561 ---- + * This takes care of the things inside the window, not what happens to the + * window position, the frame or to other windows. + */ +! void + win_new_height(wp, height) + win_T *wp; + int height; +*************** +*** 5697,5703 **** + /* + * Set the width of a window. + */ +! static void + win_new_width(wp, width) + win_T *wp; + int width; +--- 5695,5701 ---- + /* + * Set the width of a window. + */ +! void + win_new_width(wp, width) + win_T *wp; + int width; +*** ../vim-7.3.607/src/version.c 2012-07-19 17:39:01.000000000 +0200 +--- src/version.c 2012-07-19 17:53:37.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 608, + /**/ + +-- +Although the scythe isn't pre-eminent among the weapons of war, anyone who +has been on the wrong end of, say, a peasants' revolt will know that in +skilled hands it is fearsome. + -- (Terry Pratchett, Mort) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a2a199005acc3bcb57ea4cd62079c044da0f9a81 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:01 +0200 Subject: [PATCH 0430/3340] - patchlevel 609 --- 7.3.609 | 251 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 251 insertions(+) create mode 100644 7.3.609 diff --git a/7.3.609 b/7.3.609 new file mode 100644 index 00000000..ed731f50 --- /dev/null +++ b/7.3.609 @@ -0,0 +1,251 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.609 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.609 +Problem: File names in :checkpath! output are garbled. +Solution: Check for \zs in the pattern. (Lech Lorens) +Files: src/search.c, src/testdir/test17.in, src/testdir/test17.ok + + +*** ../vim-7.3.608/src/search.c 2012-07-19 17:18:21.000000000 +0200 +--- src/search.c 2012-07-25 13:33:08.000000000 +0200 +*************** +*** 4740,4756 **** + * Isolate the file name. + * Include the surrounding "" or <> if present. + */ +! for (p = incl_regmatch.endp[0]; !vim_isfilec(*p); p++) +! ; +! for (i = 0; vim_isfilec(p[i]); i++) +! ; + if (i == 0) + { + /* Nothing found, use the rest of the line. */ + p = incl_regmatch.endp[0]; + i = (int)STRLEN(p); + } +! else + { + if (p[-1] == '"' || p[-1] == '<') + { +--- 4740,4772 ---- + * Isolate the file name. + * Include the surrounding "" or <> if present. + */ +! if (inc_opt != NULL +! && strstr((char *)inc_opt, "\\zs") != NULL) +! { +! /* pattern contains \zs, use the match */ +! p = incl_regmatch.startp[0]; +! i = (int)(incl_regmatch.endp[0] +! - incl_regmatch.startp[0]); +! } +! else +! { +! /* find the file name after the end of the match */ +! for (p = incl_regmatch.endp[0]; +! *p && !vim_isfilec(*p); p++) +! ; +! for (i = 0; vim_isfilec(p[i]); i++) +! ; +! } +! + if (i == 0) + { + /* Nothing found, use the rest of the line. */ + p = incl_regmatch.endp[0]; + i = (int)STRLEN(p); + } +! /* Avoid checking before the start of the line, can +! * happen if \zs appears in the regexp. */ +! else if (p > line) + { + if (p[-1] == '"' || p[-1] == '<') + { +*** ../vim-7.3.608/src/testdir/test17.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test17.in 2012-07-25 13:41:43.000000000 +0200 +*************** +*** 1,4 **** +! Tests for "gf" on ${VAR} + + STARTTEST + :so small.vim +--- 1,6 ---- +! Tests for: +! - "gf" on ${VAR}, +! - ":checkpath!" with various 'include' settings. + + STARTTEST + :so small.vim +*************** +*** 20,27 **** + :endif + gf + :w! test.out +! :qa! + ENDTEST + + ${CDIR}/test17a.in + $TDIR/test17a.in +--- 22,120 ---- + :endif + gf + :w! test.out +! :brewind + ENDTEST + + ${CDIR}/test17a.in + $TDIR/test17a.in ++ ++ STARTTEST ++ :" check for 'include' without \zs or \ze ++ :lang C ++ :!rm -f ./Xbase.a ++ :!rm -rf ./Xdir1 ++ :!mkdir -p Xdir1/dir2 ++ :e Xdir1/dir2/foo.a ++ i#include "bar.a" ++ :w ++ :e Xdir1/dir2/bar.a ++ i#include "baz.a" ++ :w ++ :e Xdir1/dir2/baz.a ++ i#include "foo.a" ++ :w ++ :e Xbase.a ++ :set path=Xdir1/dir2 ++ i#include  ++ :w ++ :redir! >>test.out ++ :checkpath! ++ :redir END ++ :brewind ++ ENDTEST ++ ++ STARTTEST ++ :" check for 'include' with \zs and \ze ++ :!rm -f ./Xbase.b ++ :!rm -rf ./Xdir1 ++ :!mkdir -p Xdir1/dir2 ++ :let &include='^\s*%inc\s*/\zs[^/]\+\ze' ++ :function! DotsToSlashes() ++ : return substitute(v:fname, '\.', '/', 'g') . '.b' ++ :endfunction ++ :let &includeexpr='DotsToSlashes()' ++ :e Xdir1/dir2/foo.b ++ i%inc /bar/ ++ :w ++ :e Xdir1/dir2/bar.b ++ i%inc /baz/ ++ :w ++ :e Xdir1/dir2/baz.b ++ i%inc /foo/ ++ :w ++ :e Xbase.b ++ :set path=Xdir1/dir2 ++ i%inc /foo/ ++ :w ++ :redir! >>test.out ++ :checkpath! ++ :redir END ++ :brewind ++ ENDTEST ++ ++ STARTTEST ++ :" check for 'include' with \zs and no \ze ++ :!rm -f ./Xbase.c ++ :!rm -rf ./Xdir1 ++ :!mkdir -p Xdir1/dir2 ++ :let &include='^\s*%inc\s*\%([[:upper:]][^[:space:]]*\s\+\)\?\zs\S\+\ze' ++ :function! StripNewlineChar() ++ : if v:fname =~ '\n$' ++ : return v:fname[:-2] ++ : endif ++ : return v:fname ++ :endfunction ++ :let &includeexpr='StripNewlineChar()' ++ :e Xdir1/dir2/foo.c ++ i%inc bar.c ++ :w ++ :e Xdir1/dir2/bar.c ++ i%inc baz.c ++ :w ++ :e Xdir1/dir2/baz.c ++ i%inc foo.c ++ :w ++ :e Xdir1/dir2/FALSE.c ++ i%inc foo.c ++ :w ++ :e Xbase.c ++ :set path=Xdir1/dir2 ++ i%inc FALSE.c foo.c ++ :w ++ :redir! >>test.out ++ :checkpath! ++ :redir END ++ :brewind ++ :q ++ ENDTEST ++ +*** ../vim-7.3.608/src/testdir/test17.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test17.ok 2012-07-25 13:45:37.000000000 +0200 +*************** +*** 1,3 **** +--- 1,33 ---- + This file is just to test "gf" in test 17. + The contents is not important. + Just testing! ++ ++ ++ --- Included files in path --- ++ Xdir1/dir2/foo.a ++ Xdir1/dir2/foo.a --> ++ Xdir1/dir2/bar.a ++ Xdir1/dir2/bar.a --> ++ Xdir1/dir2/baz.a ++ Xdir1/dir2/baz.a --> ++ "foo.a" (Already listed) ++ ++ ++ --- Included files in path --- ++ Xdir1/dir2/foo.b ++ Xdir1/dir2/foo.b --> ++ Xdir1/dir2/bar.b ++ Xdir1/dir2/bar.b --> ++ Xdir1/dir2/baz.b ++ Xdir1/dir2/baz.b --> ++ foo (Already listed) ++ ++ ++ --- Included files in path --- ++ Xdir1/dir2/foo.c ++ Xdir1/dir2/foo.c --> ++ Xdir1/dir2/bar.c ++ Xdir1/dir2/bar.c --> ++ Xdir1/dir2/baz.c ++ Xdir1/dir2/baz.c --> ++ foo.c^@ (Already listed) +*** ../vim-7.3.608/src/version.c 2012-07-19 18:05:40.000000000 +0200 +--- src/version.c 2012-07-25 13:38:54.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 609, + /**/ + +-- +"The question of whether computers can think is just like the question +of whether submarines can swim." -- Edsger W. Dijkstra + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1dbb48c0811cdf460129a7488e0e53bbb73766db Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:02 +0200 Subject: [PATCH 0431/3340] - patchlevel 610 --- 7.3.610 | 400 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 400 insertions(+) create mode 100644 7.3.610 diff --git a/7.3.610 b/7.3.610 new file mode 100644 index 00000000..5e48837f --- /dev/null +++ b/7.3.610 @@ -0,0 +1,400 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.610 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.610 +Problem: Cannot operate on the text that a search pattern matches. +Solution: Add the "gn" and "gN" commands. (Christian Brabandt) +Files: runtime/doc/index.txt, runtime/doc/visual.txt, src/normal.c, + src/proto/search.pro, src/search.c, src/testdir/test53.in, + src/testdir/test53.ok + + +*** ../vim-7.3.609/runtime/doc/index.txt 2010-08-15 21:57:18.000000000 +0200 +--- runtime/doc/index.txt 2012-07-25 14:27:20.000000000 +0200 +*************** +*** 719,726 **** +--- 719,729 ---- + |gH| gH start Select line mode + |gI| gI 2 like "I", but always start in column 1 + |gJ| gJ 2 join lines without inserting space ++ |gN| gN 1,2 find the previous match with the last used ++ search pattern and Visually select it + |gP| ["x]gP 2 put the text [from register x] before the + cursor N times, leave the cursor after it ++ |gQ| gQ switch to "Ex" mode with Vim editing + |gR| gR 2 enter Virtual Replace mode + |gU| gU{motion} 2 make Nmove text uppercase + |gV| gV don't reselect the previous Visual area +*************** +*** 750,755 **** +--- 753,760 ---- + lines down + |gk| gk 1 like "k", but when 'wrap' on go N screen + lines up ++ |gn| gn 1,2 find the next match with the last used ++ search pattern and Visually select it + |gm| gm 1 go to character at middle of the screenline + |go| go 1 cursor to byte N in the buffer + |gp| ["x]gp 2 put the text [from register x] after the +*** ../vim-7.3.609/runtime/doc/visual.txt 2010-08-15 21:57:16.000000000 +0200 +--- runtime/doc/visual.txt 2012-07-25 14:42:22.000000000 +0200 +*************** +*** 94,99 **** +--- 99,116 ---- + After using "p" or "P" in Visual mode the text that + was put will be selected. + ++ *gn* *v_gn* ++ gn Search forward for the last used search pattern, like ++ with `n`, and start Visual mode to select the match. ++ If the cursor is on the match, visually selects it. ++ If an operator is pending, operates on the match. ++ E.g., "dgn" deletes the text of the next match. ++ If Visual mode is active, extends the selection ++ until the end of the next match. ++ ++ *gN* *v_gN* ++ gN Like |gn| but searches backward, like with `N`. ++ + ** + Set the current cursor position. If Visual mode is + active it is stopped. Only when 'mouse' option is +*** ../vim-7.3.609/src/normal.c 2012-07-10 16:49:08.000000000 +0200 +--- src/normal.c 2012-07-25 14:31:40.000000000 +0200 +*************** +*** 1780,1789 **** + { + /* Prepare for redoing. Only use the nchar field for "r", + * otherwise it might be the second char of the operator. */ +! prep_redo(oap->regname, 0L, NUL, 'v', +! get_op_char(oap->op_type), +! get_extra_op_char(oap->op_type), +! oap->op_type == OP_REPLACE ? cap->nchar : NUL); + if (!redo_VIsual_busy) + { + redo_VIsual_mode = resel_VIsual_mode; +--- 1780,1797 ---- + { + /* Prepare for redoing. Only use the nchar field for "r", + * otherwise it might be the second char of the operator. */ +! if (cap->cmdchar == 'g' && (cap->nchar == 'n' +! || cap->nchar == 'N')) +! /* "gn" and "gN" are a bit different */ +! prep_redo(oap->regname, 0L, NUL, cap->cmdchar, cap->nchar, +! get_op_char(oap->op_type), +! get_extra_op_char(oap->op_type)); +! else +! prep_redo(oap->regname, 0L, NUL, 'v', +! get_op_char(oap->op_type), +! get_extra_op_char(oap->op_type), +! oap->op_type == OP_REPLACE +! ? cap->nchar : NUL); + if (!redo_VIsual_busy) + { + redo_VIsual_mode = resel_VIsual_mode; +*************** +*** 7987,7992 **** +--- 7995,8011 ---- + cap->arg = TRUE; + nv_visual(cap); + break; ++ ++ /* "gn", "gN" visually select next/previous search match ++ * "gn" selects next match ++ * "gN" selects previous match ++ */ ++ case 'N': ++ case 'n': ++ if (!current_search(cap->count1, cap->nchar == 'n')) ++ beep_flush(); ++ ++ break; + #endif /* FEAT_VISUAL */ + + /* +*** ../vim-7.3.609/src/proto/search.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/search.pro 2012-07-25 14:24:01.000000000 +0200 +*************** +*** 27,32 **** +--- 27,33 ---- + int end_word __ARGS((long count, int bigword, int stop, int empty)); + int bckend_word __ARGS((long count, int bigword, int eol)); + int current_word __ARGS((oparg_T *oap, long count, int include, int bigword)); ++ int current_search __ARGS((long count, int forward)); + int current_sent __ARGS((oparg_T *oap, long count, int include)); + int current_block __ARGS((oparg_T *oap, long count, int include, int what, int other)); + int current_tagblock __ARGS((oparg_T *oap, long count_arg, int include)); +*** ../vim-7.3.609/src/search.c 2012-07-25 13:46:25.000000000 +0200 +--- src/search.c 2012-07-25 14:54:28.000000000 +0200 +*************** +*** 3397,3402 **** +--- 3397,3547 ---- + return OK; + } + ++ #if defined(FEAT_VISUAL) || defined(PROTO) ++ /* ++ * Find next search match under cursor, cursor at end. ++ * Used while an operator is pending, and in Visual mode. ++ * TODO: redo only works when used in operator pending mode ++ */ ++ int ++ current_search(count, forward) ++ long count; ++ int forward; /* move forward or backwards */ ++ { ++ pos_T start_pos; /* position before the pattern */ ++ pos_T orig_pos; /* position of the cursor at beginning */ ++ pos_T pos; /* position after the pattern */ ++ int i; ++ int dir; ++ int result; /* result of various function calls */ ++ char_u old_p_ws = p_ws; ++ int visual_active = FALSE; ++ int flags = 0; ++ pos_T save_VIsual; ++ ++ ++ /* wrapping should not occur */ ++ p_ws = FALSE; ++ ++ /* Correct cursor when 'selection' is exclusive */ ++ if (VIsual_active && *p_sel == 'e' && lt(VIsual, curwin->w_cursor)) ++ dec_cursor(); ++ ++ if (VIsual_active) ++ { ++ orig_pos = curwin->w_cursor; ++ save_VIsual = VIsual; ++ visual_active = TRUE; ++ ++ /* just started visual selection, only one character */ ++ if (equalpos(VIsual, curwin->w_cursor)) ++ visual_active = FALSE; ++ ++ pos = curwin->w_cursor; ++ start_pos = VIsual; ++ ++ /* make sure, searching further will extend the match */ ++ if (VIsual_active) ++ { ++ if (forward) ++ incl(&pos); ++ else ++ decl(&pos); ++ } ++ } ++ else ++ orig_pos = pos = start_pos = curwin->w_cursor; ++ ++ /* ++ * The trick is to first search backwards and then search forward again, ++ * so that a match at the current cursor position will be correctly ++ * captured. ++ */ ++ for (i = 0; i < 2; i++) ++ { ++ if (i && count == 1) ++ flags = SEARCH_START; ++ ++ if (forward) ++ dir = i; ++ else ++ dir = !i; ++ result = searchit(curwin, curbuf, &pos, (dir ? FORWARD : BACKWARD), ++ spats[last_idx].pat, (long) (i ? count : 1), ++ SEARCH_KEEP | flags | (dir ? 0 : SEARCH_END), ++ RE_SEARCH, 0, NULL); ++ ++ /* First search may fail, but then start searching from the ++ * beginning of the file (cursor might be on the search match) ++ * except when Visual mode is active, so that extending the visual ++ * selection works. */ ++ if (!result && i) /* not found, abort */ ++ { ++ curwin->w_cursor = orig_pos; ++ if (VIsual_active) ++ VIsual = save_VIsual; ++ p_ws = old_p_ws; ++ return FAIL; ++ } ++ else if (!i && !result && !visual_active) ++ { ++ if (forward) /* try again from start of buffer */ ++ { ++ clearpos(&pos); ++ } ++ else /* try again from end of buffer */ ++ { ++ /* searching backwards, so set pos to last line and col */ ++ pos.lnum = curwin->w_buffer->b_ml.ml_line_count; ++ pos.col = STRLEN(ml_get(curwin->w_buffer->b_ml.ml_line_count)); ++ } ++ } ++ ++ } ++ ++ start_pos = pos; ++ flags = (forward ? SEARCH_END : 0); ++ ++ /* move to match */ ++ result = searchit(curwin, curbuf, &pos, (forward ? FORWARD : BACKWARD), ++ spats[last_idx].pat, 0L, flags | SEARCH_KEEP, RE_SEARCH, 0, NULL); ++ ++ if (!VIsual_active) ++ VIsual = start_pos; ++ ++ p_ws = old_p_ws; ++ curwin->w_cursor = pos; ++ VIsual_active = TRUE; ++ VIsual_mode = 'v'; ++ ++ if (VIsual_active) ++ { ++ redraw_curbuf_later(INVERTED); /* update the inversion */ ++ if (*p_sel == 'e' && ltoreq(VIsual, curwin->w_cursor)) ++ inc_cursor(); ++ } ++ ++ #ifdef FEAT_FOLDING ++ if (fdo_flags & FDO_SEARCH && KeyTyped) ++ foldOpenCursor(); ++ #endif ++ ++ may_start_select('c'); ++ #ifdef FEAT_MOUSE ++ setmouse(); ++ #endif ++ #ifdef FEAT_CLIPBOARD ++ /* Make sure the clipboard gets updated. Needed because start and ++ * end are still the same, and the selection needs to be owned */ ++ clip_star.vmode = NUL; ++ #endif ++ redraw_curbuf_later(INVERTED); ++ showmode(); ++ ++ return OK; ++ } ++ #endif /* FEAT_VISUAL */ ++ + /* + * Find sentence(s) under the cursor, cursor at end. + * When Visual active, extend it by one or more sentences. +*************** +*** 3420,3426 **** + + #ifdef FEAT_VISUAL + /* +! * When visual area is bigger than one character: Extend it. + */ + if (VIsual_active && !equalpos(start_pos, VIsual)) + { +--- 3565,3571 ---- + + #ifdef FEAT_VISUAL + /* +! * When the Visual area is bigger than one character: Extend it. + */ + if (VIsual_active && !equalpos(start_pos, VIsual)) + { +*************** +*** 3508,3515 **** + #endif + + /* +! * If cursor started on blank, check if it is just before the start of the +! * next sentence. + */ + while (c = gchar_pos(&pos), vim_iswhite(c)) /* vim_iswhite() is a macro */ + incl(&pos); +--- 3653,3660 ---- + #endif + + /* +! * If the cursor started on a blank, check if it is just before the start +! * of the next sentence. + */ + while (c = gchar_pos(&pos), vim_iswhite(c)) /* vim_iswhite() is a macro */ + incl(&pos); +*************** +*** 3558,3564 **** + #ifdef FEAT_VISUAL + if (VIsual_active) + { +! /* avoid getting stuck with "is" on a single space before a sent. */ + if (equalpos(start_pos, curwin->w_cursor)) + goto extend; + if (*p_sel == 'e') +--- 3703,3709 ---- + #ifdef FEAT_VISUAL + if (VIsual_active) + { +! /* Avoid getting stuck with "is" on a single space before a sentence. */ + if (equalpos(start_pos, curwin->w_cursor)) + goto extend; + if (*p_sel == 'e') +*** ../vim-7.3.609/src/testdir/test53.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test53.in 2012-07-25 15:01:34.000000000 +0200 +*************** +*** 28,33 **** +--- 28,40 ---- + :put =matchstr(\"abcd\", \".\", 0, -1) " a + :put =match(\"abcd\", \".\", 0, 5) " -1 + :put =match(\"abcd\", \".\", 0, -1) " 0 ++ /^foobar ++ gncsearchmatch/one\_s*two\_s ++ :1 ++ gnd ++ /[a]bcdx ++ :1 ++ 2gnd + :/^start:/,/^end:/wq! test.out + ENDTEST + +*************** +*** 45,48 **** +--- 52,60 ---- + -asdfXasdfasdf- + -asdXasdfasdf- + ++ SEARCH: ++ foobar ++ one ++ two ++ abcdx | abcdx | abcdx + end: +*** ../vim-7.3.609/src/testdir/test53.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test53.ok 2012-07-25 14:24:01.000000000 +0200 +*************** +*** 18,21 **** +--- 18,24 ---- + a + -1 + 0 ++ SEARCH: ++ searchmatch ++ abcdx | | abcdx + end: +*** ../vim-7.3.609/src/version.c 2012-07-25 13:46:25.000000000 +0200 +--- src/version.c 2012-07-25 15:03:43.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 610, + /**/ + +-- +Did you ever see a "Hit any key to continue" message in a music piece? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 40e011c429ab0ef16106dbb6468137826686806b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:02 +0200 Subject: [PATCH 0432/3340] - patchlevel 611 --- 7.3.611 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.611 diff --git a/7.3.611 b/7.3.611 new file mode 100644 index 00000000..5e366a78 --- /dev/null +++ b/7.3.611 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.611 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.611 +Problem: Can't use Vim dictionary as self argument in Python. +Solution: Fix the check for the "self" argument. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.610/src/if_py_both.h 2012-06-30 13:34:29.000000000 +0200 +--- src/if_py_both.h 2012-07-25 15:32:10.000000000 +0200 +*************** +*** 1284,1292 **** + selfdictObject = PyDict_GetItemString(kwargs, "self"); + if (selfdictObject != NULL) + { +! if (!PyDict_Check(selfdictObject)) + { +! PyErr_SetString(PyExc_TypeError, _("'self' argument must be a dictionary")); + clear_tv(&args); + return NULL; + } +--- 1284,1293 ---- + selfdictObject = PyDict_GetItemString(kwargs, "self"); + if (selfdictObject != NULL) + { +! if (!PyMapping_Check(selfdictObject)) + { +! PyErr_SetString(PyExc_TypeError, +! _("'self' argument must be a dictionary")); + clear_tv(&args); + return NULL; + } +*** ../vim-7.3.610/src/version.c 2012-07-25 15:06:20.000000000 +0200 +--- src/version.c 2012-07-25 15:32:24.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 611, + /**/ + +-- +In Joseph Heller's novel "Catch-22", the main character tries to get out of a +war by proving he is crazy. But the mere fact he wants to get out of the war +only shows he isn't crazy -- creating the original "Catch-22". + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 675724fbab92a1e80de5090449a6f31947bd81b2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:02 +0200 Subject: [PATCH 0433/3340] - patchlevel 612 --- 7.3.612 | 83 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 7.3.612 diff --git a/7.3.612 b/7.3.612 new file mode 100644 index 00000000..7b2207ed --- /dev/null +++ b/7.3.612 @@ -0,0 +1,83 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.612 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.612 +Problem: Auto formatting messes up text when 'fo' contains "2". (ZyX) +Solution: Decrement "less_cols". (Tor Perkins) +Files: src/misc1.c, src/testdir/test68.in, src/testdir/test68.ok + + +*** ../vim-7.3.611/src/misc1.c 2012-07-06 16:49:37.000000000 +0200 +--- src/misc1.c 2012-07-25 16:03:58.000000000 +0200 +*************** +*** 1329,1334 **** +--- 1329,1335 ---- + for (i = 0; i < padding; i++) + { + STRCAT(leader, " "); ++ less_cols--; + newcol++; + } + } +*** ../vim-7.3.611/src/testdir/test68.in 2012-06-29 15:04:34.000000000 +0200 +--- src/testdir/test68.in 2012-07-25 15:57:06.000000000 +0200 +*************** +*** 94,99 **** +--- 94,109 ---- + } + + STARTTEST ++ /mno pqr/ ++ :setl tw=20 fo=an12wcq comments=s1:/*,mb:*,ex:*/ ++ A vwx yz ++ ENDTEST ++ ++ /* abc def ghi jkl ++ * mno pqr stu ++ */ ++ ++ STARTTEST + /^#/ + :setl tw=12 fo=tqnc comments=:# + A foobar +*** ../vim-7.3.611/src/testdir/test68.ok 2012-06-29 23:57:50.000000000 +0200 +--- src/testdir/test68.ok 2012-07-25 16:03:05.000000000 +0200 +*************** +*** 57,62 **** +--- 57,68 ---- + { 1aa ^^2bb } + + ++ /* abc def ghi jkl ++ * mno pqr stu ++ * vwx yz ++ */ ++ ++ + # 1 xxxxx + # foobar + +*** ../vim-7.3.611/src/version.c 2012-07-25 15:36:00.000000000 +0200 +--- src/version.c 2012-07-25 16:08:02.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 612, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +169. You hire a housekeeper for your home page. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 89ade8c0932fe4ccfa6eb4b4a44c84a64d2ab81d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:03 +0200 Subject: [PATCH 0434/3340] - patchlevel 613 --- 7.3.613 | 149 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 149 insertions(+) create mode 100644 7.3.613 diff --git a/7.3.613 b/7.3.613 new file mode 100644 index 00000000..520e87c3 --- /dev/null +++ b/7.3.613 @@ -0,0 +1,149 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.613 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.613 +Problem: Including Python's config.c in the build causes trouble. It is + not clear why it was there. +Solution: Omit the config file. (James McCoy) +Files: src/Makefile, src/auto/configure, src/configure.in + + +*** ../vim-7.3.612/src/Makefile 2012-06-20 18:39:12.000000000 +0200 +--- src/Makefile 2012-07-25 16:22:57.000000000 +0200 +*************** +*** 2559,2577 **** + objects/if_perlsfio.o: if_perlsfio.c + $(CCC) $(PERL_CFLAGS) -o $@ if_perlsfio.c + +- objects/py_config.o: $(PYTHON_CONFDIR)/config.c +- $(CCC) $(PYTHON_CFLAGS) -o $@ $(PYTHON_CONFDIR)/config.c \ +- -I$(PYTHON_CONFDIR) -DHAVE_CONFIG_H -DNO_MAIN +- + objects/py_getpath.o: $(PYTHON_CONFDIR)/getpath.c + $(CCC) $(PYTHON_CFLAGS) -o $@ $(PYTHON_CONFDIR)/getpath.c \ + -I$(PYTHON_CONFDIR) -DHAVE_CONFIG_H -DNO_MAIN \ + $(PYTHON_GETPATH_CFLAGS) + +- objects/py3_config.o: $(PYTHON3_CONFDIR)/config.c +- $(CCC) $(PYTHON3_CFLAGS) -o $@ $(PYTHON3_CONFDIR)/config.c \ +- -I$(PYTHON3_CONFDIR) -DHAVE_CONFIG_H -DNO_MAIN +- + objects/if_python.o: if_python.c if_py_both.h + $(CCC) $(PYTHON_CFLAGS) $(PYTHON_CFLAGS_EXTRA) -o $@ if_python.c + +--- 2559,2569 ---- +*** ../vim-7.3.612/src/auto/configure 2012-06-13 19:19:36.000000000 +0200 +--- src/auto/configure 2012-07-25 16:23:49.000000000 +0200 +*************** +*** 5357,5367 **** + PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\"" + fi + PYTHON_SRC="if_python.c" +! if test "x$MACOSX" = "xyes"; then +! PYTHON_OBJ="objects/if_python.o" +! else +! PYTHON_OBJ="objects/if_python.o objects/py_config.o" +! fi + if test "${vi_cv_var_python_version}" = "1.4"; then + PYTHON_OBJ="$PYTHON_OBJ objects/py_getpath.o" + fi +--- 5357,5363 ---- + PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\"" + fi + PYTHON_SRC="if_python.c" +! PYTHON_OBJ="objects/if_python.o" + if test "${vi_cv_var_python_version}" = "1.4"; then + PYTHON_OBJ="$PYTHON_OBJ objects/py_getpath.o" + fi +*************** +*** 5656,5666 **** + PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" + fi + PYTHON3_SRC="if_python3.c" +! if test "x$MACOSX" = "xyes"; then +! PYTHON3_OBJ="objects/if_python3.o" +! else +! PYTHON3_OBJ="objects/if_python3.o objects/py3_config.o" +! fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -pthread should be used" >&5 + $as_echo_n "checking if -pthread should be used... " >&6; } +--- 5652,5658 ---- + PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" + fi + PYTHON3_SRC="if_python3.c" +! PYTHON3_OBJ="objects/if_python3.o" + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -pthread should be used" >&5 + $as_echo_n "checking if -pthread should be used... " >&6; } +*** ../vim-7.3.612/src/configure.in 2012-06-13 19:19:36.000000000 +0200 +--- src/configure.in 2012-07-25 16:23:41.000000000 +0200 +*************** +*** 916,927 **** + PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\"" + fi + PYTHON_SRC="if_python.c" +! dnl For Mac OSX 10.2 config.o is included in the Python library. +! if test "x$MACOSX" = "xyes"; then +! PYTHON_OBJ="objects/if_python.o" +! else +! PYTHON_OBJ="objects/if_python.o objects/py_config.o" +! fi + if test "${vi_cv_var_python_version}" = "1.4"; then + PYTHON_OBJ="$PYTHON_OBJ objects/py_getpath.o" + fi +--- 916,922 ---- + PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\"" + fi + PYTHON_SRC="if_python.c" +! PYTHON_OBJ="objects/if_python.o" + if test "${vi_cv_var_python_version}" = "1.4"; then + PYTHON_OBJ="$PYTHON_OBJ objects/py_getpath.o" + fi +*************** +*** 1106,1117 **** + PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" + fi + PYTHON3_SRC="if_python3.c" +! dnl For Mac OSX 10.2 config.o is included in the Python library. +! if test "x$MACOSX" = "xyes"; then +! PYTHON3_OBJ="objects/if_python3.o" +! else +! PYTHON3_OBJ="objects/if_python3.o objects/py3_config.o" +! fi + + dnl On FreeBSD linking with "-pthread" is required to use threads. + dnl _THREAD_SAFE must be used for compiling then. +--- 1101,1107 ---- + PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" + fi + PYTHON3_SRC="if_python3.c" +! PYTHON3_OBJ="objects/if_python3.o" + + dnl On FreeBSD linking with "-pthread" is required to use threads. + dnl _THREAD_SAFE must be used for compiling then. +*** ../vim-7.3.612/src/version.c 2012-07-25 16:09:59.000000000 +0200 +--- src/version.c 2012-07-25 16:29:52.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 613, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +170. You introduce your wife as "my_lady@home.wife" and refer to your + children as "forked processes." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From abe28fd6ba728cbcc6eeb0f6593e6efb1b8e096f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:03 +0200 Subject: [PATCH 0435/3340] - patchlevel 614 --- 7.3.614 | 176 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 176 insertions(+) create mode 100644 7.3.614 diff --git a/7.3.614 b/7.3.614 new file mode 100644 index 00000000..87d7a451 --- /dev/null +++ b/7.3.614 @@ -0,0 +1,176 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.614 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.614 +Problem: Number argument gets turned into a number while it should be a + string. +Solution: Add flag to the call_vim_function() call. (Yasuhiro Matsumoto) +Files: src/edit.c, src/eval.c, src/proto/eval.pro + + +*** ../vim-7.3.613/src/edit.c 2012-07-10 17:14:50.000000000 +0200 +--- src/edit.c 2012-07-25 16:40:07.000000000 +0200 +*************** +*** 3959,3965 **** + curbuf_save = curbuf; + + /* Call a function, which returns a list or dict. */ +! if (call_vim_function(funcname, 2, args, FALSE, &rettv) == OK) + { + switch (rettv.v_type) + { +--- 3959,3965 ---- + curbuf_save = curbuf; + + /* Call a function, which returns a list or dict. */ +! if (call_vim_function(funcname, 2, args, FALSE, FALSE, &rettv) == OK) + { + switch (rettv.v_type) + { +*** ../vim-7.3.613/src/eval.c 2012-07-19 18:05:40.000000000 +0200 +--- src/eval.c 2012-07-25 16:42:41.000000000 +0200 +*************** +*** 1564,1574 **** + * Returns OK or FAIL. + */ + int +! call_vim_function(func, argc, argv, safe, rettv) + char_u *func; + int argc; + char_u **argv; + int safe; /* use the sandbox */ + typval_T *rettv; + { + typval_T *argvars; +--- 1564,1575 ---- + * Returns OK or FAIL. + */ + int +! call_vim_function(func, argc, argv, safe, str_arg_only, rettv) + char_u *func; + int argc; + char_u **argv; + int safe; /* use the sandbox */ ++ int str_arg_only; /* all arguments are strings */ + typval_T *rettv; + { + typval_T *argvars; +*************** +*** 1593,1600 **** + continue; + } + +! /* Recognize a number argument, the others must be strings. */ +! vim_str2nr(argv[i], NULL, &len, TRUE, TRUE, &n, NULL); + if (len != 0 && len == (int)STRLEN(argv[i])) + { + argvars[i].v_type = VAR_NUMBER; +--- 1594,1604 ---- + continue; + } + +! if (str_arg_only) +! len = 0; +! else +! /* Recognize a number argument, the others must be strings. */ +! vim_str2nr(argv[i], NULL, &len, TRUE, TRUE, &n, NULL); + if (len != 0 && len == (int)STRLEN(argv[i])) + { + argvars[i].v_type = VAR_NUMBER; +*************** +*** 1646,1652 **** + typval_T rettv; + char_u *retval; + +! if (call_vim_function(func, argc, argv, safe, &rettv) == FAIL) + return NULL; + + retval = vim_strsave(get_tv_string(&rettv)); +--- 1650,1657 ---- + typval_T rettv; + char_u *retval; + +! /* All arguments are passed as strings, no conversion to number. */ +! if (call_vim_function(func, argc, argv, safe, TRUE, &rettv) == FAIL) + return NULL; + + retval = vim_strsave(get_tv_string(&rettv)); +*************** +*** 1671,1677 **** + typval_T rettv; + long retval; + +! if (call_vim_function(func, argc, argv, safe, &rettv) == FAIL) + return -1; + + retval = get_tv_number_chk(&rettv, NULL); +--- 1676,1683 ---- + typval_T rettv; + long retval; + +! /* All arguments are passed as strings, no conversion to number. */ +! if (call_vim_function(func, argc, argv, safe, TRUE, &rettv) == FAIL) + return -1; + + retval = get_tv_number_chk(&rettv, NULL); +*************** +*** 1694,1700 **** + { + typval_T rettv; + +! if (call_vim_function(func, argc, argv, safe, &rettv) == FAIL) + return NULL; + + if (rettv.v_type != VAR_LIST) +--- 1700,1707 ---- + { + typval_T rettv; + +! /* All arguments are passed as strings, no conversion to number. */ +! if (call_vim_function(func, argc, argv, safe, TRUE, &rettv) == FAIL) + return NULL; + + if (rettv.v_type != VAR_LIST) +*** ../vim-7.3.613/src/proto/eval.pro 2012-07-16 17:31:48.000000000 +0200 +--- src/proto/eval.pro 2012-07-25 16:42:59.000000000 +0200 +*************** +*** 23,29 **** + list_T *eval_spell_expr __ARGS((char_u *badword, char_u *expr)); + int get_spellword __ARGS((list_T *list, char_u **pp)); + typval_T *eval_expr __ARGS((char_u *arg, char_u **nextcmd)); +! int call_vim_function __ARGS((char_u *func, int argc, char_u **argv, int safe, typval_T *rettv)); + void *call_func_retstr __ARGS((char_u *func, int argc, char_u **argv, int safe)); + long call_func_retnr __ARGS((char_u *func, int argc, char_u **argv, int safe)); + void *call_func_retlist __ARGS((char_u *func, int argc, char_u **argv, int safe)); +--- 23,29 ---- + list_T *eval_spell_expr __ARGS((char_u *badword, char_u *expr)); + int get_spellword __ARGS((list_T *list, char_u **pp)); + typval_T *eval_expr __ARGS((char_u *arg, char_u **nextcmd)); +! int call_vim_function __ARGS((char_u *func, int argc, char_u **argv, int safe, int str_arg_only, typval_T *rettv)); + void *call_func_retstr __ARGS((char_u *func, int argc, char_u **argv, int safe)); + long call_func_retnr __ARGS((char_u *func, int argc, char_u **argv, int safe)); + void *call_func_retlist __ARGS((char_u *func, int argc, char_u **argv, int safe)); +*** ../vim-7.3.613/src/version.c 2012-07-25 16:32:03.000000000 +0200 +--- src/version.c 2012-07-25 16:46:11.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 614, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +171. You invent another person and chat with yourself in empty chat rooms. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9041a7506fd45a80cfb3e3e5fa59633d2c43c32f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:03 +0200 Subject: [PATCH 0436/3340] - patchlevel 615 --- 7.3.615 | 107 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 107 insertions(+) create mode 100644 7.3.615 diff --git a/7.3.615 b/7.3.615 new file mode 100644 index 00000000..96f6885f --- /dev/null +++ b/7.3.615 @@ -0,0 +1,107 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.615 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.615 +Problem: Completion for a user command does not recognize backslash before + a space. +Solution: Recognize escaped characters. (Yasuhiro Matsumoto) +Files: src/ex_docmd.c + + +*** ../vim-7.3.614/src/ex_docmd.c 2012-07-10 19:25:06.000000000 +0200 +--- src/ex_docmd.c 2012-07-25 17:10:16.000000000 +0200 +*************** +*** 3390,3401 **** + return NULL; + + /* Find start of last argument (argument just before cursor): */ +! p = buff + STRLEN(buff); +! while (p != arg && *p != ' ' && *p != TAB) +! p--; +! if (*p == ' ' || *p == TAB) +! p++; + xp->xp_pattern = p; + + if (ea.argt & XFILE) + { +--- 3390,3412 ---- + return NULL; + + /* Find start of last argument (argument just before cursor): */ +! p = buff; + xp->xp_pattern = p; ++ len = STRLEN(buff); ++ while (*p && p < buff + len) ++ { ++ if (*p == ' ' || *p == TAB) ++ { ++ /* argument starts after a space */ ++ xp->xp_pattern = ++p; ++ } ++ else ++ { ++ if (*p == '\\' && *(p + 1) != NUL) ++ ++p; /* skip over escaped character */ ++ mb_ptr_adv(p); ++ } ++ } + + if (ea.argt & XFILE) + { +*************** +*** 3821,3828 **** + if (compl == EXPAND_MAPPINGS) + return set_context_in_map_cmd(xp, (char_u *)"map", + arg, forceit, FALSE, FALSE, CMD_map); +! while ((xp->xp_pattern = vim_strchr(arg, ' ')) != NULL) +! arg = xp->xp_pattern + 1; + xp->xp_pattern = arg; + } + xp->xp_context = compl; +--- 3832,3853 ---- + if (compl == EXPAND_MAPPINGS) + return set_context_in_map_cmd(xp, (char_u *)"map", + arg, forceit, FALSE, FALSE, CMD_map); +! /* Find start of last argument. */ +! p = arg; +! while (*p) +! { +! if (*p == ' ') +! { +! /* argument starts after a space */ +! arg = p + 1; +! } +! else +! { +! if (*p == '\\' && *(p + 1) != NUL) +! ++p; /* skip over escaped character */ +! mb_ptr_adv(p); +! } +! } + xp->xp_pattern = arg; + } + xp->xp_context = compl; +*** ../vim-7.3.614/src/version.c 2012-07-25 16:46:59.000000000 +0200 +--- src/version.c 2012-07-25 17:17:05.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 615, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +172. You join listservers just for the extra e-mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6de293c6c89bb2e02d6bf2018556c44eadae0067 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:04 +0200 Subject: [PATCH 0437/3340] - patchlevel 616 --- 7.3.616 | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 7.3.616 diff --git a/7.3.616 b/7.3.616 new file mode 100644 index 00000000..5898eafe --- /dev/null +++ b/7.3.616 @@ -0,0 +1,46 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.616 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.616 (after 7.3.610) +Problem: Can't compile without +visual. +Solution: Add #ifdef. +Files: src/normal.c + + +*** ../vim-7.3.615/src/normal.c 2012-07-25 15:06:20.000000000 +0200 +--- src/normal.c 2012-07-27 20:52:01.000000000 +0200 +*************** +*** 8002,8008 **** +--- 8002,8010 ---- + */ + case 'N': + case 'n': ++ #ifdef FEAT_VISUAL + if (!current_search(cap->count1, cap->nchar == 'n')) ++ #endif + beep_flush(); + + break; +*** ../vim-7.3.615/src/version.c 2012-07-25 17:22:17.000000000 +0200 +--- src/version.c 2012-07-27 20:52:58.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 616, + /**/ + +-- +The CIA drives around in cars with the "Intel inside" logo. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a777fa1a07bbec34f67dd951c6a9e40d4a6d0d3e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:04 +0200 Subject: [PATCH 0438/3340] - patchlevel 617 --- 7.3.617 | 65 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 7.3.617 diff --git a/7.3.617 b/7.3.617 new file mode 100644 index 00000000..48062cd2 --- /dev/null +++ b/7.3.617 @@ -0,0 +1,65 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.617 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.617 (after 7.3.615) +Problem: Hang on completion. +Solution: Skip over the space. (Yasuhiro Matsumoto) +Files: src/ex_docmd.c + + +*** ../vim-7.3.616/src/ex_docmd.c 2012-07-25 17:22:17.000000000 +0200 +--- src/ex_docmd.c 2012-07-27 21:07:42.000000000 +0200 +*************** +*** 3837,3852 **** + while (*p) + { + if (*p == ' ') +- { + /* argument starts after a space */ + arg = p + 1; +! } +! else +! { +! if (*p == '\\' && *(p + 1) != NUL) +! ++p; /* skip over escaped character */ +! mb_ptr_adv(p); +! } + } + xp->xp_pattern = arg; + } +--- 3837,3847 ---- + while (*p) + { + if (*p == ' ') + /* argument starts after a space */ + arg = p + 1; +! else if (*p == '\\' && *(p + 1) != NUL) +! ++p; /* skip over escaped character */ +! mb_ptr_adv(p); + } + xp->xp_pattern = arg; + } +*** ../vim-7.3.616/src/version.c 2012-07-27 21:05:51.000000000 +0200 +--- src/version.c 2012-07-27 21:08:31.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 617, + /**/ + +-- +If Microsoft would build a car... +... You'd have to press the "Start" button to turn the engine off. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 30f24ce2a7e537c9cf55f91e7b1f17101a88d53d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:04 +0200 Subject: [PATCH 0439/3340] - patchlevel 618 --- 7.3.618 | 367 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 367 insertions(+) create mode 100644 7.3.618 diff --git a/7.3.618 b/7.3.618 new file mode 100644 index 00000000..d0cc9c68 --- /dev/null +++ b/7.3.618 @@ -0,0 +1,367 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.618 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.618 (after 7.3.616) +Problem: Still doesn't compile with small features. +Solution: Move current_search() out of #ifdef. (Dominique Pelle) +Files: src/normal.c, src/search.c + + +*** ../vim-7.3.617/src/normal.c 2012-07-27 21:05:51.000000000 +0200 +--- src/normal.c 2012-07-28 13:34:13.000000000 +0200 +*************** +*** 7995,8000 **** +--- 7995,8001 ---- + cap->arg = TRUE; + nv_visual(cap); + break; ++ #endif /* FEAT_VISUAL */ + + /* "gn", "gN" visually select next/previous search match + * "gn" selects next match +*************** +*** 8006,8014 **** + if (!current_search(cap->count1, cap->nchar == 'n')) + #endif + beep_flush(); +- + break; +- #endif /* FEAT_VISUAL */ + + /* + * "gj" and "gk" two new funny movement keys -- up and down +--- 8007,8013 ---- +*** ../vim-7.3.617/src/search.c 2012-07-25 15:06:20.000000000 +0200 +--- src/search.c 2012-07-28 13:37:19.000000000 +0200 +*************** +*** 3397,3547 **** + return OK; + } + +- #if defined(FEAT_VISUAL) || defined(PROTO) +- /* +- * Find next search match under cursor, cursor at end. +- * Used while an operator is pending, and in Visual mode. +- * TODO: redo only works when used in operator pending mode +- */ +- int +- current_search(count, forward) +- long count; +- int forward; /* move forward or backwards */ +- { +- pos_T start_pos; /* position before the pattern */ +- pos_T orig_pos; /* position of the cursor at beginning */ +- pos_T pos; /* position after the pattern */ +- int i; +- int dir; +- int result; /* result of various function calls */ +- char_u old_p_ws = p_ws; +- int visual_active = FALSE; +- int flags = 0; +- pos_T save_VIsual; +- +- +- /* wrapping should not occur */ +- p_ws = FALSE; +- +- /* Correct cursor when 'selection' is exclusive */ +- if (VIsual_active && *p_sel == 'e' && lt(VIsual, curwin->w_cursor)) +- dec_cursor(); +- +- if (VIsual_active) +- { +- orig_pos = curwin->w_cursor; +- save_VIsual = VIsual; +- visual_active = TRUE; +- +- /* just started visual selection, only one character */ +- if (equalpos(VIsual, curwin->w_cursor)) +- visual_active = FALSE; +- +- pos = curwin->w_cursor; +- start_pos = VIsual; +- +- /* make sure, searching further will extend the match */ +- if (VIsual_active) +- { +- if (forward) +- incl(&pos); +- else +- decl(&pos); +- } +- } +- else +- orig_pos = pos = start_pos = curwin->w_cursor; +- +- /* +- * The trick is to first search backwards and then search forward again, +- * so that a match at the current cursor position will be correctly +- * captured. +- */ +- for (i = 0; i < 2; i++) +- { +- if (i && count == 1) +- flags = SEARCH_START; +- +- if (forward) +- dir = i; +- else +- dir = !i; +- result = searchit(curwin, curbuf, &pos, (dir ? FORWARD : BACKWARD), +- spats[last_idx].pat, (long) (i ? count : 1), +- SEARCH_KEEP | flags | (dir ? 0 : SEARCH_END), +- RE_SEARCH, 0, NULL); +- +- /* First search may fail, but then start searching from the +- * beginning of the file (cursor might be on the search match) +- * except when Visual mode is active, so that extending the visual +- * selection works. */ +- if (!result && i) /* not found, abort */ +- { +- curwin->w_cursor = orig_pos; +- if (VIsual_active) +- VIsual = save_VIsual; +- p_ws = old_p_ws; +- return FAIL; +- } +- else if (!i && !result && !visual_active) +- { +- if (forward) /* try again from start of buffer */ +- { +- clearpos(&pos); +- } +- else /* try again from end of buffer */ +- { +- /* searching backwards, so set pos to last line and col */ +- pos.lnum = curwin->w_buffer->b_ml.ml_line_count; +- pos.col = STRLEN(ml_get(curwin->w_buffer->b_ml.ml_line_count)); +- } +- } +- +- } +- +- start_pos = pos; +- flags = (forward ? SEARCH_END : 0); +- +- /* move to match */ +- result = searchit(curwin, curbuf, &pos, (forward ? FORWARD : BACKWARD), +- spats[last_idx].pat, 0L, flags | SEARCH_KEEP, RE_SEARCH, 0, NULL); +- +- if (!VIsual_active) +- VIsual = start_pos; +- +- p_ws = old_p_ws; +- curwin->w_cursor = pos; +- VIsual_active = TRUE; +- VIsual_mode = 'v'; +- +- if (VIsual_active) +- { +- redraw_curbuf_later(INVERTED); /* update the inversion */ +- if (*p_sel == 'e' && ltoreq(VIsual, curwin->w_cursor)) +- inc_cursor(); +- } +- +- #ifdef FEAT_FOLDING +- if (fdo_flags & FDO_SEARCH && KeyTyped) +- foldOpenCursor(); +- #endif +- +- may_start_select('c'); +- #ifdef FEAT_MOUSE +- setmouse(); +- #endif +- #ifdef FEAT_CLIPBOARD +- /* Make sure the clipboard gets updated. Needed because start and +- * end are still the same, and the selection needs to be owned */ +- clip_star.vmode = NUL; +- #endif +- redraw_curbuf_later(INVERTED); +- showmode(); +- +- return OK; +- } +- #endif /* FEAT_VISUAL */ +- + /* + * Find sentence(s) under the cursor, cursor at end. + * When Visual active, extend it by one or more sentences. +--- 3397,3402 ---- +*************** +*** 4670,4675 **** +--- 4525,4675 ---- + + #endif /* FEAT_TEXTOBJ */ + ++ #if defined(FEAT_VISUAL) || defined(PROTO) ++ /* ++ * Find next search match under cursor, cursor at end. ++ * Used while an operator is pending, and in Visual mode. ++ * TODO: redo only works when used in operator pending mode ++ */ ++ int ++ current_search(count, forward) ++ long count; ++ int forward; /* move forward or backwards */ ++ { ++ pos_T start_pos; /* position before the pattern */ ++ pos_T orig_pos; /* position of the cursor at beginning */ ++ pos_T pos; /* position after the pattern */ ++ int i; ++ int dir; ++ int result; /* result of various function calls */ ++ char_u old_p_ws = p_ws; ++ int visual_active = FALSE; ++ int flags = 0; ++ pos_T save_VIsual; ++ ++ ++ /* wrapping should not occur */ ++ p_ws = FALSE; ++ ++ /* Correct cursor when 'selection' is exclusive */ ++ if (VIsual_active && *p_sel == 'e' && lt(VIsual, curwin->w_cursor)) ++ dec_cursor(); ++ ++ if (VIsual_active) ++ { ++ orig_pos = curwin->w_cursor; ++ save_VIsual = VIsual; ++ visual_active = TRUE; ++ ++ /* just started visual selection, only one character */ ++ if (equalpos(VIsual, curwin->w_cursor)) ++ visual_active = FALSE; ++ ++ pos = curwin->w_cursor; ++ start_pos = VIsual; ++ ++ /* make sure, searching further will extend the match */ ++ if (VIsual_active) ++ { ++ if (forward) ++ incl(&pos); ++ else ++ decl(&pos); ++ } ++ } ++ else ++ orig_pos = pos = start_pos = curwin->w_cursor; ++ ++ /* ++ * The trick is to first search backwards and then search forward again, ++ * so that a match at the current cursor position will be correctly ++ * captured. ++ */ ++ for (i = 0; i < 2; i++) ++ { ++ if (i && count == 1) ++ flags = SEARCH_START; ++ ++ if (forward) ++ dir = i; ++ else ++ dir = !i; ++ result = searchit(curwin, curbuf, &pos, (dir ? FORWARD : BACKWARD), ++ spats[last_idx].pat, (long) (i ? count : 1), ++ SEARCH_KEEP | flags | (dir ? 0 : SEARCH_END), ++ RE_SEARCH, 0, NULL); ++ ++ /* First search may fail, but then start searching from the ++ * beginning of the file (cursor might be on the search match) ++ * except when Visual mode is active, so that extending the visual ++ * selection works. */ ++ if (!result && i) /* not found, abort */ ++ { ++ curwin->w_cursor = orig_pos; ++ if (VIsual_active) ++ VIsual = save_VIsual; ++ p_ws = old_p_ws; ++ return FAIL; ++ } ++ else if (!i && !result && !visual_active) ++ { ++ if (forward) /* try again from start of buffer */ ++ { ++ clearpos(&pos); ++ } ++ else /* try again from end of buffer */ ++ { ++ /* searching backwards, so set pos to last line and col */ ++ pos.lnum = curwin->w_buffer->b_ml.ml_line_count; ++ pos.col = STRLEN(ml_get(curwin->w_buffer->b_ml.ml_line_count)); ++ } ++ } ++ ++ } ++ ++ start_pos = pos; ++ flags = (forward ? SEARCH_END : 0); ++ ++ /* move to match */ ++ result = searchit(curwin, curbuf, &pos, (forward ? FORWARD : BACKWARD), ++ spats[last_idx].pat, 0L, flags | SEARCH_KEEP, RE_SEARCH, 0, NULL); ++ ++ if (!VIsual_active) ++ VIsual = start_pos; ++ ++ p_ws = old_p_ws; ++ curwin->w_cursor = pos; ++ VIsual_active = TRUE; ++ VIsual_mode = 'v'; ++ ++ if (VIsual_active) ++ { ++ redraw_curbuf_later(INVERTED); /* update the inversion */ ++ if (*p_sel == 'e' && ltoreq(VIsual, curwin->w_cursor)) ++ inc_cursor(); ++ } ++ ++ #ifdef FEAT_FOLDING ++ if (fdo_flags & FDO_SEARCH && KeyTyped) ++ foldOpenCursor(); ++ #endif ++ ++ may_start_select('c'); ++ #ifdef FEAT_MOUSE ++ setmouse(); ++ #endif ++ #ifdef FEAT_CLIPBOARD ++ /* Make sure the clipboard gets updated. Needed because start and ++ * end are still the same, and the selection needs to be owned */ ++ clip_star.vmode = NUL; ++ #endif ++ redraw_curbuf_later(INVERTED); ++ showmode(); ++ ++ return OK; ++ } ++ #endif /* FEAT_VISUAL */ ++ + #if defined(FEAT_LISP) || defined(FEAT_CINDENT) || defined(FEAT_TEXTOBJ) \ + || defined(PROTO) + /* +*** ../vim-7.3.617/src/version.c 2012-07-27 21:12:03.000000000 +0200 +--- src/version.c 2012-07-29 12:54:29.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 618, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +185. You order fast food over the Internet + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f5c8f33187c459bf990af96902d4c1f4294e1bb5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:05 +0200 Subject: [PATCH 0440/3340] - patchlevel 619 --- 7.3.619 | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 7.3.619 diff --git a/7.3.619 b/7.3.619 new file mode 100644 index 00000000..1fedcc78 --- /dev/null +++ b/7.3.619 @@ -0,0 +1,50 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.619 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.619 +Problem: When executing a shell command Vim may become slow to respond. +Solution: Don't wait after every processed message. (idea by Yasuhiro + Matsumoto) +Files: src/os_win32.c + + +*** ../vim-7.3.618/src/os_win32.c 2012-07-19 11:37:22.000000000 +0200 +--- src/os_win32.c 2012-08-02 12:30:52.000000000 +0200 +*************** +*** 3319,3324 **** +--- 3319,3326 ---- + { + TranslateMessage(&msg); + pDispatchMessage(&msg); ++ delay = 1; ++ continue; + } + if (WaitForSingleObject(pi.hProcess, delay) != WAIT_TIMEOUT) + break; +*** ../vim-7.3.618/src/version.c 2012-07-29 12:55:21.000000000 +0200 +--- src/version.c 2012-08-02 12:29:08.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 619, + /**/ + +-- +Some of the well know MS-Windows errors: + EMULTI Multitasking attempted, system confused + EKEYBOARD Keyboard locked, try getting out of this one! + EXPLAIN Unexplained error, please tell us what happened + EFUTURE Reserved for our future mistakes + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From de19434fbcf72591f0b8386d5d9d65cae12d9f90 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:05 +0200 Subject: [PATCH 0441/3340] - patchlevel 620 --- 7.3.620 | 163 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 163 insertions(+) create mode 100644 7.3.620 diff --git a/7.3.620 b/7.3.620 new file mode 100644 index 00000000..5890f15f --- /dev/null +++ b/7.3.620 @@ -0,0 +1,163 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.620 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.620 +Problem: Building with recent Ruby on Win32 doesn't work. +Solution: Add a separate argument for the API version. (Yasuhiro Matsumoto) +Files: src/Make_ming.mak, src/Make_mvc.mak + + +*** ../vim-7.3.619/src/Make_ming.mak 2012-07-06 13:40:44.000000000 +0200 +--- src/Make_ming.mak 2012-08-02 17:02:34.000000000 +0200 +*************** +*** 260,266 **** + # DYNAMIC_RUBY=yes (to load the Ruby DLL dynamically) + # RUBY_VER=[Ruby version, eg 16, 17] (default is 16) + # RUBY_VER_LONG=[Ruby version, eg 1.6, 1.7] (default is 1.6) +! # You must set RUBY_VER_LONG when change RUBY_VER. + #RUBY=c:/ruby + ifdef RUBY + ifndef DYNAMIC_RUBY +--- 260,268 ---- + # DYNAMIC_RUBY=yes (to load the Ruby DLL dynamically) + # RUBY_VER=[Ruby version, eg 16, 17] (default is 16) + # RUBY_VER_LONG=[Ruby version, eg 1.6, 1.7] (default is 1.6) +! # You must set RUBY_VER_LONG when changing RUBY_VER. +! # You must set RUBY_API_VER version to RUBY_VER_LONG. +! # Don't set ruby API version to RUBY_VER like 191. + #RUBY=c:/ruby + ifdef RUBY + ifndef DYNAMIC_RUBY +*************** +*** 273,278 **** +--- 275,283 ---- + ifndef RUBY_VER_LONG + RUBY_VER_LONG = 1.6 + endif ++ ifndef RUBY_API_VER ++ RUBY_API_VER = $(subst .,,$(RUBY_VER_LONG)) ++ endif + + ifndef RUBY_PLATFORM + ifeq ($(RUBY_VER), 16) +*************** +*** 288,296 **** + + ifndef RUBY_INSTALL_NAME + ifeq ($(RUBY_VER), 16) +! RUBY_INSTALL_NAME = mswin32-ruby$(RUBY_VER) + else +! RUBY_INSTALL_NAME = msvcrt-ruby$(RUBY_VER) + endif + endif + +--- 293,301 ---- + + ifndef RUBY_INSTALL_NAME + ifeq ($(RUBY_VER), 16) +! RUBY_INSTALL_NAME = mswin32-ruby$(RUBY_API_VER) + else +! RUBY_INSTALL_NAME = msvcrt-ruby$(RUBY_API_VER) + endif + endif + +*** ../vim-7.3.619/src/Make_mvc.mak 2012-02-22 16:01:53.000000000 +0100 +--- src/Make_mvc.mak 2012-08-02 17:42:31.000000000 +0200 +*************** +*** 63,68 **** +--- 63,70 ---- + # RUBY_VER=[Ruby version, eg 16, 17] (default is 18) + # RUBY_VER_LONG=[Ruby version, eg 1.6, 1.7] (default is 1.8) + # You must set RUBY_VER_LONG when change RUBY_VER. ++ # You must set RUBY_API_VER to RUBY_VER_LONG. ++ # Don't set ruby API version to RUBY_VER like 191. + # + # Tcl interface: + # TCL=[Path to Tcl directory] +*************** +*** 807,834 **** + !ifndef RUBY_VER_LONG + RUBY_VER_LONG = 1.8 + !endif + + !if $(RUBY_VER) >= 18 + !ifndef RUBY_PLATFORM + RUBY_PLATFORM = i386-mswin32 + !endif + !ifndef RUBY_INSTALL_NAME +! RUBY_INSTALL_NAME = msvcrt-ruby$(RUBY_VER) + !endif + !else + !ifndef RUBY_PLATFORM + RUBY_PLATFORM = i586-mswin32 + !endif + !ifndef RUBY_INSTALL_NAME +! RUBY_INSTALL_NAME = mswin32-ruby$(RUBY_VER) + !endif + !endif # $(RUBY_VER) >= 18 + + !message Ruby requested (version $(RUBY_VER)) - root dir is "$(RUBY)" + CFLAGS = $(CFLAGS) -DFEAT_RUBY + RUBY_OBJ = $(OUTDIR)\if_ruby.obj +! !if $(RUBY_VER) >= 190 +! RUBY_INC = /I "$(RUBY)\include\ruby-$(RUBY_VER_LONG)\$(RUBY_PLATFORM)" /I "$(RUBY)\include\ruby-$(RUBY_VER_LONG)" + !else + RUBY_INC = /I "$(RUBY)\lib\ruby\$(RUBY_VER_LONG)\$(RUBY_PLATFORM)" + !endif +--- 813,843 ---- + !ifndef RUBY_VER_LONG + RUBY_VER_LONG = 1.8 + !endif ++ !ifndef RUBY_API_VER ++ RUBY_API_VER = $(RUBY_VER_LONG:.=) ++ !endif + + !if $(RUBY_VER) >= 18 + !ifndef RUBY_PLATFORM + RUBY_PLATFORM = i386-mswin32 + !endif + !ifndef RUBY_INSTALL_NAME +! RUBY_INSTALL_NAME = msvcrt-ruby$(RUBY_API_VER) + !endif + !else + !ifndef RUBY_PLATFORM + RUBY_PLATFORM = i586-mswin32 + !endif + !ifndef RUBY_INSTALL_NAME +! RUBY_INSTALL_NAME = mswin32-ruby$(RUBY_API_VER) + !endif + !endif # $(RUBY_VER) >= 18 + + !message Ruby requested (version $(RUBY_VER)) - root dir is "$(RUBY)" + CFLAGS = $(CFLAGS) -DFEAT_RUBY + RUBY_OBJ = $(OUTDIR)\if_ruby.obj +! !if $(RUBY_VER) >= 19 +! RUBY_INC = /I "$(RUBY)\lib\ruby\$(RUBY_VER_LONG)\$(RUBY_PLATFORM)" /I "$(RUBY)\include\ruby-$(RUBY_VER_LONG)" /I "$(RUBY)\include\ruby-$(RUBY_VER_LONG)\$(RUBY_PLATFORM)" + !else + RUBY_INC = /I "$(RUBY)\lib\ruby\$(RUBY_VER_LONG)\$(RUBY_PLATFORM)" + !endif +*** ../vim-7.3.619/src/version.c 2012-08-02 12:31:40.000000000 +0200 +--- src/version.c 2012-08-02 21:20:28.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 620, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +199. You read this entire list of symptoms, looking for something + that doesn't describe you. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 70b8457282cf704a2788cc05dbcdc8c14d814fcc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:05 +0200 Subject: [PATCH 0442/3340] - patchlevel 621 --- 7.3.621 | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 7.3.621 diff --git a/7.3.621 b/7.3.621 new file mode 100644 index 00000000..7e3fe2a5 --- /dev/null +++ b/7.3.621 @@ -0,0 +1,72 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.621 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.621 +Problem: Compiler warnings on 64 bit windows. +Solution: Add type casts. (Mike Williams) +Files: src/ex_docmd.c, src/search.c + + +*** ../vim-7.3.620/src/ex_docmd.c 2012-07-27 21:12:03.000000000 +0200 +--- src/ex_docmd.c 2012-08-02 21:19:22.000000000 +0200 +*************** +*** 3392,3398 **** + /* Find start of last argument (argument just before cursor): */ + p = buff; + xp->xp_pattern = p; +! len = STRLEN(buff); + while (*p && p < buff + len) + { + if (*p == ' ' || *p == TAB) +--- 3392,3398 ---- + /* Find start of last argument (argument just before cursor): */ + p = buff; + xp->xp_pattern = p; +! len = (int)STRLEN(buff); + while (*p && p < buff + len) + { + if (*p == ' ' || *p == TAB) +*** ../vim-7.3.620/src/search.c 2012-07-29 12:55:21.000000000 +0200 +--- src/search.c 2012-08-02 21:20:02.000000000 +0200 +*************** +*** 4621,4627 **** + { + /* searching backwards, so set pos to last line and col */ + pos.lnum = curwin->w_buffer->b_ml.ml_line_count; +! pos.col = STRLEN(ml_get(curwin->w_buffer->b_ml.ml_line_count)); + } + } + +--- 4621,4628 ---- + { + /* searching backwards, so set pos to last line and col */ + pos.lnum = curwin->w_buffer->b_ml.ml_line_count; +! pos.col = (colnr_T)STRLEN( +! ml_get(curwin->w_buffer->b_ml.ml_line_count)); + } + } + +*** ../vim-7.3.620/src/version.c 2012-08-02 21:21:43.000000000 +0200 +--- src/version.c 2012-08-02 21:23:13.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 621, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +200. You really believe in the concept of a "paperless" office. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3caf57bc247c09afdecddc1b905955db074ce514 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:06 +0200 Subject: [PATCH 0443/3340] - patchlevel 622 --- 7.3.622 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.622 diff --git a/7.3.622 b/7.3.622 new file mode 100644 index 00000000..a2c26014 --- /dev/null +++ b/7.3.622 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.622 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.622 +Problem: XPM library for Win32 can't be found. +Solution: Suggest using the one from the Vim ftp site. +Files: src/Make_mvc.mak + + +*** ../vim-7.3.621/src/Make_mvc.mak 2012-08-02 21:21:43.000000000 +0200 +--- src/Make_mvc.mak 2012-08-02 21:45:52.000000000 +0200 +*************** +*** 281,287 **** + + !ifdef XPM + # XPM - Include support for XPM signs +! # you can get xpm.lib from http://iamphet.nm.ru/xpm or create it yourself + XPM_OBJ = $(OBJDIR)/xpm_w32.obj + XPM_DEFS = -DFEAT_XPM_W32 + XPM_LIB = $(XPM)\lib\libXpm.lib +--- 281,291 ---- + + !ifdef XPM + # XPM - Include support for XPM signs +! # You need to download or build xpm.lib somehow. +! # You can get the most recent version of libXpm-*.zip from +! # http://cgit.freedesktop.org/xorg/lib/libXpm +! # from which you must build xpm.lib yourself +! # OR get and unpack: ftp://ftp.vim.org/pub/vim/pcextra/xpm.zip + XPM_OBJ = $(OBJDIR)/xpm_w32.obj + XPM_DEFS = -DFEAT_XPM_W32 + XPM_LIB = $(XPM)\lib\libXpm.lib +*** ../vim-7.3.621/src/version.c 2012-08-02 21:24:38.000000000 +0200 +--- src/version.c 2012-08-02 21:46:43.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 622, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +202. You're amazed to find out Spam is a food. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 43b081ac954ae1f274a6902e98f4d47440d52b4f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:06 +0200 Subject: [PATCH 0444/3340] - patchlevel 623 --- 7.3.623 | 92 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 92 insertions(+) create mode 100644 7.3.623 diff --git a/7.3.623 b/7.3.623 new file mode 100644 index 00000000..72aea71f --- /dev/null +++ b/7.3.623 @@ -0,0 +1,92 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.623 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.623 +Problem: Perl 5.14 commands crash Vim on MS-Windows. +Solution: Use perl_get_sv() instead of GvSV(). (Raymond Ko) +Files: src/if_perl.xs + + +*** ../vim-7.3.622/src/if_perl.xs 2012-03-16 19:34:43.000000000 +0100 +--- src/if_perl.xs 2012-08-08 13:15:29.000000000 +0200 +*************** +*** 76,81 **** +--- 76,87 ---- + # define EXTERN_C + #endif + ++ #if (PERL_REVISION == 5) && (PERL_VERSION >= 14) && defined(_MSC_VER) ++ /* Using PL_errgv to get the error message after perl_eval_sv() causes a crash ++ * with MSVC and Perl version 5.14. */ ++ # define AVOID_PL_ERRGV ++ #endif ++ + /* Compatibility hacks over */ + + static PerlInterpreter *perl_interp = NULL; +*************** +*** 796,802 **** +--- 802,812 ---- + + SvREFCNT_dec(sv); + ++ #ifdef AVOID_PL_ERRGV ++ err = SvPV(perl_get_sv("@", GV_ADD), length); ++ #else + err = SvPV(GvSV(PL_errgv), length); ++ #endif + + FREETMPS; + LEAVE; +*************** +*** 866,872 **** +--- 876,886 ---- + sv_catpvn(sv, "}", 1); + perl_eval_sv(sv, G_DISCARD | G_NOARGS); + SvREFCNT_dec(sv); ++ #ifdef AVOID_PL_ERRGV ++ str = SvPV(perl_get_sv("@", GV_ADD), length); ++ #else + str = SvPV(GvSV(PL_errgv), length); ++ #endif + if (length) + goto err; + +*************** +*** 880,886 **** +--- 894,904 ---- + sv_setpv(GvSV(PL_defgv), (char *)ml_get(i)); + PUSHMARK(sp); + perl_call_pv("VIM::perldo", G_SCALAR | G_EVAL); ++ #ifdef AVOID_PL_ERRGV ++ str = SvPV(perl_get_sv("@", GV_ADD), length); ++ #else + str = SvPV(GvSV(PL_errgv), length); ++ #endif + if (length) + break; + SPAGAIN; +*** ../vim-7.3.622/src/version.c 2012-08-02 21:48:20.000000000 +0200 +--- src/version.c 2012-08-08 13:08:10.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 623, + /**/ + +-- +Don't be humble ... you're not that great. + -- Golda Meir + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b4d2b52e62bb7a266ce3c0e3ef1ffcee3275ec6e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:06 +0200 Subject: [PATCH 0445/3340] - patchlevel 624 --- 7.3.624 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.624 diff --git a/7.3.624 b/7.3.624 new file mode 100644 index 00000000..f1150b63 --- /dev/null +++ b/7.3.624 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.624 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.624 +Problem: When cancelling input() it returns the third argument. That should + only happen for inputdialog(). +Solution: Check if inputdialog() was used. (Hirohito Higashi) +Files: src/eval.c + + +*** ../vim-7.3.623/src/eval.c 2012-07-25 16:46:59.000000000 +0200 +--- src/eval.c 2012-08-08 14:31:48.000000000 +0200 +*************** +*** 12966,12972 **** + rettv->vval.v_string = + getcmdline_prompt(inputsecret_flag ? NUL : '@', p, echo_attr, + xp_type, xp_arg); +! if (rettv->vval.v_string == NULL + && argvars[1].v_type != VAR_UNKNOWN + && argvars[2].v_type != VAR_UNKNOWN) + rettv->vval.v_string = vim_strsave(get_tv_string_buf( +--- 12966,12972 ---- + rettv->vval.v_string = + getcmdline_prompt(inputsecret_flag ? NUL : '@', p, echo_attr, + xp_type, xp_arg); +! if (inputdialog && rettv->vval.v_string == NULL + && argvars[1].v_type != VAR_UNKNOWN + && argvars[2].v_type != VAR_UNKNOWN) + rettv->vval.v_string = vim_strsave(get_tv_string_buf( +*** ../vim-7.3.623/src/version.c 2012-08-08 13:17:26.000000000 +0200 +--- src/version.c 2012-08-08 14:28:46.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 624, + /**/ + +-- +Your fault: core dumped + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3c319db2bca36c14e7c772d494899393677f30cb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:07 +0200 Subject: [PATCH 0446/3340] - patchlevel 625 --- 7.3.625 | 140 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 140 insertions(+) create mode 100644 7.3.625 diff --git a/7.3.625 b/7.3.625 new file mode 100644 index 00000000..5334bc8f --- /dev/null +++ b/7.3.625 @@ -0,0 +1,140 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.625 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.625 +Problem: "gn" does not handle zero-width matches correctly. +Solution: Handle zero-width patterns specially. (Christian Brabandt) +Files: src/search.c + + +*** ../vim-7.3.624/src/search.c 2012-08-02 21:24:38.000000000 +0200 +--- src/search.c 2012-08-08 15:25:12.000000000 +0200 +*************** +*** 4546,4551 **** +--- 4546,4554 ---- + int visual_active = FALSE; + int flags = 0; + pos_T save_VIsual; ++ regmmatch_T regmatch; ++ int nmatched = 0; ++ int zerowidth = FALSE; + + + /* wrapping should not occur */ +*************** +*** 4581,4603 **** + orig_pos = pos = start_pos = curwin->w_cursor; + + /* + * The trick is to first search backwards and then search forward again, + * so that a match at the current cursor position will be correctly + * captured. + */ + for (i = 0; i < 2; i++) + { +- if (i && count == 1) +- flags = SEARCH_START; +- + if (forward) + dir = i; + else + dir = !i; + result = searchit(curwin, curbuf, &pos, (dir ? FORWARD : BACKWARD), + spats[last_idx].pat, (long) (i ? count : 1), +! SEARCH_KEEP | flags | (dir ? 0 : SEARCH_END), +! RE_SEARCH, 0, NULL); + + /* First search may fail, but then start searching from the + * beginning of the file (cursor might be on the search match) +--- 4584,4625 ---- + orig_pos = pos = start_pos = curwin->w_cursor; + + /* ++ * Check for zero-width pattern. ++ */ ++ if (search_regcomp(spats[last_idx].pat, RE_SEARCH, RE_SEARCH, ++ ((SEARCH_HIS + SEARCH_KEEP)), ®match) == FAIL) ++ return FAIL; ++ ++ /* Zero-width pattern should match somewhere, then we can check if start ++ * and end are in the same position. */ ++ nmatched = vim_regexec_multi(®match, curwin, curbuf, ++ curwin->w_cursor.lnum, (colnr_T)0, NULL); ++ if (called_emsg) ++ return FAIL; ++ if (nmatched && regmatch.startpos[0].lnum == regmatch.endpos[0].lnum ++ && regmatch.endpos[0].col == regmatch.startpos[0].col) ++ zerowidth = TRUE; ++ vim_free(regmatch.regprog); ++ ++ /* + * The trick is to first search backwards and then search forward again, + * so that a match at the current cursor position will be correctly + * captured. + */ + for (i = 0; i < 2; i++) + { + if (forward) + dir = i; + else + dir = !i; ++ ++ flags = 0; ++ if (!dir && !zerowidth) ++ flags = SEARCH_END; ++ + result = searchit(curwin, curbuf, &pos, (dir ? FORWARD : BACKWARD), + spats[last_idx].pat, (long) (i ? count : 1), +! SEARCH_KEEP | flags, RE_SEARCH, 0, NULL); + + /* First search may fail, but then start searching from the + * beginning of the file (cursor might be on the search match) +*************** +*** 4629,4638 **** + } + + start_pos = pos; +! flags = (forward ? SEARCH_END : 0); + +! /* move to match */ +! result = searchit(curwin, curbuf, &pos, (forward ? FORWARD : BACKWARD), + spats[last_idx].pat, 0L, flags | SEARCH_KEEP, RE_SEARCH, 0, NULL); + + if (!VIsual_active) +--- 4651,4662 ---- + } + + start_pos = pos; +! flags = forward ? SEARCH_END : 0; + +! /* move to match, except for zero-width matches, in which case, we are +! * already on the next match */ +! if (!zerowidth) +! result = searchit(curwin, curbuf, &pos, (forward ? FORWARD : BACKWARD), + spats[last_idx].pat, 0L, flags | SEARCH_KEEP, RE_SEARCH, 0, NULL); + + if (!VIsual_active) +*** ../vim-7.3.624/src/version.c 2012-08-08 14:33:16.000000000 +0200 +--- src/version.c 2012-08-08 15:21:53.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 625, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +222. You send more than 20 personal e-mails a day. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7643fc95949d2e7c6c4fde9d9921bfcb7962a470 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:07 +0200 Subject: [PATCH 0447/3340] - patchlevel 626 --- 7.3.626 | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 7.3.626 diff --git a/7.3.626 b/7.3.626 new file mode 100644 index 00000000..33b15456 --- /dev/null +++ b/7.3.626 @@ -0,0 +1,49 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.626 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.626 +Problem: Python interface doesn't build with Python 2.4 or older. +Solution: Define Py_ssize_t. (Benjamin Bannier) +Files: src/if_py_both.h + + +*** ../vim-7.3.625/src/if_py_both.h 2012-07-25 15:36:00.000000000 +0200 +--- src/if_py_both.h 2012-08-08 15:53:24.000000000 +0200 +*************** +*** 12,17 **** +--- 12,21 ---- + * Common code for if_python.c and if_python3.c. + */ + ++ #if PY_VERSION_HEX < 0x02050000 ++ typedef int Py_ssize_t; /* Python 2.4 and earlier don't have this type. */ ++ #endif ++ + #ifdef FEAT_MBYTE + # define ENC_OPT p_enc + #else +*** ../vim-7.3.625/src/version.c 2012-08-08 15:27:54.000000000 +0200 +--- src/version.c 2012-08-08 15:52:07.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 626, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +224. You set up your own Web page. You set up a Web page for each + of your kids... and your pets. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1a294534394eb3f5926b60e0eef5a0fa8ec57842 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:07 +0200 Subject: [PATCH 0448/3340] - patchlevel 627 --- 7.3.627 | 102 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 102 insertions(+) create mode 100644 7.3.627 diff --git a/7.3.627 b/7.3.627 new file mode 100644 index 00000000..97a0298d --- /dev/null +++ b/7.3.627 @@ -0,0 +1,102 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.627 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.627 +Problem: When using the "n" flag with the ":s" command a \= substitution + will not be evaluated. +Solution: Do perform the evaluation, so that a function can be invoked at + every matching position without changing the text. (Christian + Brabandt) +Files: src/ex_cmds.c + + +*** ../vim-7.3.626/src/ex_cmds.c 2012-07-10 15:18:18.000000000 +0200 +--- src/ex_cmds.c 2012-08-08 16:44:16.000000000 +0200 +*************** +*** 4264,4269 **** +--- 4264,4272 ---- + int endcolumn = FALSE; /* cursor in last column when done */ + pos_T old_cursor = curwin->w_cursor; + int start_nsubs; ++ #ifdef FEAT_EVAL ++ int save_ma = 0; ++ #endif + + cmd = eap->arg; + if (!global_busy) +*************** +*** 4668,4674 **** + } + sub_nsubs++; + did_sub = TRUE; +! goto skip; + } + + if (do_ask) +--- 4671,4682 ---- + } + sub_nsubs++; + did_sub = TRUE; +! #ifdef FEAT_EVAL +! /* Skip the substitution, unless an expression is used, +! * then it is evaluated in the sandbox. */ +! if (!(sub[0] == '\\' && sub[1] == '=')) +! #endif +! goto skip; + } + + if (do_ask) +*************** +*** 4840,4849 **** +--- 4848,4874 ---- + /* + * 3. substitute the string. + */ ++ #ifdef FEAT_EVAL ++ if (do_count) ++ { ++ /* prevent accidently changing the buffer by a function */ ++ save_ma = curbuf->b_p_ma; ++ curbuf->b_p_ma = FALSE; ++ sandbox++; ++ } ++ #endif + /* get length of substitution part */ + sublen = vim_regsub_multi(®match, + sub_firstlnum - regmatch.startpos[0].lnum, + sub, sub_firstline, FALSE, p_magic, TRUE); ++ #ifdef FEAT_EVAL ++ if (do_count) ++ { ++ curbuf->b_p_ma = save_ma; ++ sandbox--; ++ goto skip; ++ } ++ #endif + + /* When the match included the "$" of the last line it may + * go beyond the last line of the buffer. */ +*** ../vim-7.3.626/src/version.c 2012-08-08 16:05:03.000000000 +0200 +--- src/version.c 2012-08-08 16:48:45.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 627, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +225. You sign up for free subscriptions for all the computer magazines + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a02917d843437bbe6084375f1258029a6bbbe644 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:08 +0200 Subject: [PATCH 0449/3340] - patchlevel 628 --- 7.3.628 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 7.3.628 diff --git a/7.3.628 b/7.3.628 new file mode 100644 index 00000000..bab31479 --- /dev/null +++ b/7.3.628 @@ -0,0 +1,54 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.628 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.628 +Problem: ":open" does not allow for a !, which results in a confusing error + message. (Shawn Wilson) +Solution: Allow ! on ":open". (Christian Brabandt) +Files: src/ex_cmds.h + + +*** ../vim-7.3.627/src/ex_cmds.h 2012-07-06 18:27:34.000000000 +0200 +--- src/ex_cmds.h 2012-08-08 17:15:45.000000000 +0200 +*************** +*** 662,668 **** + EX(CMD_nunmenu, "nunmenu", ex_menu, + EXTRA|TRLBAR|NOTRLCOM|USECTRLV|CMDWIN), + EX(CMD_open, "open", ex_open, +! RANGE|EXTRA), + EX(CMD_oldfiles, "oldfiles", ex_oldfiles, + BANG|TRLBAR|SBOXOK|CMDWIN), + EX(CMD_omap, "omap", ex_map, +--- 662,668 ---- + EX(CMD_nunmenu, "nunmenu", ex_menu, + EXTRA|TRLBAR|NOTRLCOM|USECTRLV|CMDWIN), + EX(CMD_open, "open", ex_open, +! RANGE|BANG|EXTRA), + EX(CMD_oldfiles, "oldfiles", ex_oldfiles, + BANG|TRLBAR|SBOXOK|CMDWIN), + EX(CMD_omap, "omap", ex_map, +*** ../vim-7.3.627/src/version.c 2012-08-08 16:50:40.000000000 +0200 +--- src/version.c 2012-08-08 17:30:14.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 628, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +226. You sit down at the computer right after dinner and your spouse + says "See you in the morning." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d62601a4b2f2af03e27843248beac64ceda22523 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:08 +0200 Subject: [PATCH 0450/3340] - patchlevel 629 --- 7.3.629 | 437 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 437 insertions(+) create mode 100644 7.3.629 diff --git a/7.3.629 b/7.3.629 new file mode 100644 index 00000000..8e26dd49 --- /dev/null +++ b/7.3.629 @@ -0,0 +1,437 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.629 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.629 +Problem: There is no way to make 'shiftwidth' follow 'tabstop'. +Solution: When 'shiftwidth' is zero use the value of 'tabstop'. (Christian + Brabandt) +Files: src/edit.c, src/ex_getln.c, src/fold.c, src/misc1.c, src/ops.c, + src/option.c, src/proto/option.pro + + +*** ../vim-7.3.628/src/edit.c 2012-07-25 16:46:59.000000000 +0200 +--- src/edit.c 2012-08-08 17:55:37.000000000 +0200 +*************** +*** 8899,8907 **** + + *inserted_space_p = FALSE; + if (p_sta && in_indent) +! ts = curbuf->b_p_sw; + else +! ts = curbuf->b_p_sts; + /* Compute the virtual column where we want to be. Since + * 'showbreak' may get in the way, need to get the last column of + * the previous character. */ +--- 8899,8907 ---- + + *inserted_space_p = FALSE; + if (p_sta && in_indent) +! ts = (int)get_sw_value(); + else +! ts = (int)curbuf->b_p_sts; + /* Compute the virtual column where we want to be. Since + * 'showbreak' may get in the way, need to get the last column of + * the previous character. */ +*************** +*** 9589,9595 **** + * When nothing special, insert TAB like a normal character + */ + if (!curbuf->b_p_et +! && !(p_sta && ind && curbuf->b_p_ts != curbuf->b_p_sw) + && curbuf->b_p_sts == 0) + return TRUE; + +--- 9589,9595 ---- + * When nothing special, insert TAB like a normal character + */ + if (!curbuf->b_p_et +! && !(p_sta && ind && curbuf->b_p_ts != get_sw_value()) + && curbuf->b_p_sts == 0) + return TRUE; + +*************** +*** 9605,9611 **** + AppendToRedobuff((char_u *)"\t"); + + if (p_sta && ind) /* insert tab in indent, use 'shiftwidth' */ +! temp = (int)curbuf->b_p_sw; + else if (curbuf->b_p_sts > 0) /* use 'softtabstop' when set */ + temp = (int)curbuf->b_p_sts; + else /* otherwise use 'tabstop' */ +--- 9605,9611 ---- + AppendToRedobuff((char_u *)"\t"); + + if (p_sta && ind) /* insert tab in indent, use 'shiftwidth' */ +! temp = (int)get_sw_value(); + else if (curbuf->b_p_sts > 0) /* use 'softtabstop' when set */ + temp = (int)curbuf->b_p_sts; + else /* otherwise use 'tabstop' */ +*** ../vim-7.3.628/src/ex_getln.c 2012-06-29 13:44:37.000000000 +0200 +--- src/ex_getln.c 2012-08-08 17:39:40.000000000 +0200 +*************** +*** 2268,2277 **** + + if (c1 == Ctrl_T) + { + p = (char_u *)line_ga.ga_data; + p[line_ga.ga_len] = NUL; + indent = get_indent_str(p, 8); +! indent += curbuf->b_p_sw - indent % curbuf->b_p_sw; + add_indent: + while (get_indent_str(p, 8) < indent) + { +--- 2268,2279 ---- + + if (c1 == Ctrl_T) + { ++ long sw = get_sw_value(); ++ + p = (char_u *)line_ga.ga_data; + p[line_ga.ga_len] = NUL; + indent = get_indent_str(p, 8); +! indent += sw - indent % sw; + add_indent: + while (get_indent_str(p, 8) < indent) + { +*************** +*** 2323,2329 **** + p[line_ga.ga_len] = NUL; + indent = get_indent_str(p, 8); + --indent; +! indent -= indent % curbuf->b_p_sw; + } + while (get_indent_str(p, 8) > indent) + { +--- 2325,2331 ---- + p[line_ga.ga_len] = NUL; + indent = get_indent_str(p, 8); + --indent; +! indent -= indent % get_sw_value(); + } + while (get_indent_str(p, 8) > indent) + { +*** ../vim-7.3.628/src/fold.c 2012-02-29 19:19:57.000000000 +0100 +--- src/fold.c 2012-08-08 17:40:11.000000000 +0200 +*************** +*** 3025,3031 **** + flp->lvl = -1; + } + else +! flp->lvl = get_indent_buf(buf, lnum) / buf->b_p_sw; + if (flp->lvl > flp->wp->w_p_fdn) + { + flp->lvl = flp->wp->w_p_fdn; +--- 3025,3031 ---- + flp->lvl = -1; + } + else +! flp->lvl = get_indent_buf(buf, lnum) / get_sw_value(); + if (flp->lvl > flp->wp->w_p_fdn) + { + flp->lvl = flp->wp->w_p_fdn; +*** ../vim-7.3.628/src/misc1.c 2012-07-25 16:09:59.000000000 +0200 +--- src/misc1.c 2012-08-08 17:43:07.000000000 +0200 +*************** +*** 1389,1397 **** + #ifdef FEAT_SMARTINDENT + if (did_si) + { + if (p_sr) +! newindent -= newindent % (int)curbuf->b_p_sw; +! newindent += (int)curbuf->b_p_sw; + } + #endif + /* Copy the indent */ +--- 1389,1399 ---- + #ifdef FEAT_SMARTINDENT + if (did_si) + { ++ int sw = (int)get_sw_value(); ++ + if (p_sr) +! newindent -= newindent % sw; +! newindent += sw; + } + #endif + /* Copy the indent */ +*************** +*** 6461,6471 **** + int + get_c_indent() + { + /* + * spaces from a block's opening brace the prevailing indent for that + * block should be + */ +! int ind_level = curbuf->b_p_sw; + + /* + * spaces from the edge of the line an open brace that's at the end of a +--- 6463,6476 ---- + int + get_c_indent() + { ++ int sw = (int)get_sw_value(); ++ + /* + * spaces from a block's opening brace the prevailing indent for that + * block should be + */ +! +! int ind_level = sw; + + /* + * spaces from the edge of the line an open brace that's at the end of a +*************** +*** 6512,6523 **** + /* + * spaces from the switch() indent a "case xx" label should be located + */ +! int ind_case = curbuf->b_p_sw; + + /* + * spaces from the "case xx:" code after a switch() should be located + */ +! int ind_case_code = curbuf->b_p_sw; + + /* + * lineup break at end of case in switch() with case label +--- 6517,6528 ---- + /* + * spaces from the switch() indent a "case xx" label should be located + */ +! int ind_case = sw; + + /* + * spaces from the "case xx:" code after a switch() should be located + */ +! int ind_case_code = sw; + + /* + * lineup break at end of case in switch() with case label +*************** +*** 6528,6572 **** + * spaces from the class declaration indent a scope declaration label + * should be located + */ +! int ind_scopedecl = curbuf->b_p_sw; + + /* + * spaces from the scope declaration label code should be located + */ +! int ind_scopedecl_code = curbuf->b_p_sw; + + /* + * amount K&R-style parameters should be indented + */ +! int ind_param = curbuf->b_p_sw; + + /* + * amount a function type spec should be indented + */ +! int ind_func_type = curbuf->b_p_sw; + + /* + * amount a cpp base class declaration or constructor initialization + * should be indented + */ +! int ind_cpp_baseclass = curbuf->b_p_sw; + + /* + * additional spaces beyond the prevailing indent a continuation line + * should be located + */ +! int ind_continuation = curbuf->b_p_sw; + + /* + * spaces from the indent of the line with an unclosed parentheses + */ +! int ind_unclosed = curbuf->b_p_sw * 2; + + /* + * spaces from the indent of the line with an unclosed parentheses, which + * itself is also unclosed + */ +! int ind_unclosed2 = curbuf->b_p_sw; + + /* + * suppress ignoring spaces from the indent of a line starting with an +--- 6533,6577 ---- + * spaces from the class declaration indent a scope declaration label + * should be located + */ +! int ind_scopedecl = sw; + + /* + * spaces from the scope declaration label code should be located + */ +! int ind_scopedecl_code = sw; + + /* + * amount K&R-style parameters should be indented + */ +! int ind_param = sw; + + /* + * amount a function type spec should be indented + */ +! int ind_func_type = sw; + + /* + * amount a cpp base class declaration or constructor initialization + * should be indented + */ +! int ind_cpp_baseclass = sw; + + /* + * additional spaces beyond the prevailing indent a continuation line + * should be located + */ +! int ind_continuation = sw; + + /* + * spaces from the indent of the line with an unclosed parentheses + */ +! int ind_unclosed = sw * 2; + + /* + * spaces from the indent of the line with an unclosed parentheses, which + * itself is also unclosed + */ +! int ind_unclosed2 = sw; + + /* + * suppress ignoring spaces from the indent of a line starting with an +*************** +*** 6719,6730 **** + if (*options == 's') /* "2s" means two times 'shiftwidth' */ + { + if (options == digits) +! n = curbuf->b_p_sw; /* just "s" is one 'shiftwidth' */ + else + { +! n *= curbuf->b_p_sw; + if (divider) +! n += (curbuf->b_p_sw * fraction + divider / 2) / divider; + } + ++options; + } +--- 6724,6735 ---- + if (*options == 's') /* "2s" means two times 'shiftwidth' */ + { + if (options == digits) +! n = sw; /* just "s" is one 'shiftwidth' */ + else + { +! n *= sw; + if (divider) +! n += (sw * fraction + divider / 2) / divider; + } + ++options; + } +*** ../vim-7.3.628/src/ops.c 2012-07-10 16:49:08.000000000 +0200 +--- src/ops.c 2012-08-08 17:34:28.000000000 +0200 +*************** +*** 332,338 **** + { + int count; + int i, j; +! int p_sw = (int)curbuf->b_p_sw; + + count = get_indent(); /* get current indent */ + +--- 332,338 ---- + { + int count; + int i, j; +! int p_sw = (int)get_sw_value(); + + count = get_indent(); /* get current indent */ + +*************** +*** 388,394 **** + int total; + char_u *newp, *oldp; + int oldcol = curwin->w_cursor.col; +! int p_sw = (int)curbuf->b_p_sw; + int p_ts = (int)curbuf->b_p_ts; + struct block_def bd; + int incr; +--- 388,394 ---- + int total; + char_u *newp, *oldp; + int oldcol = curwin->w_cursor.col; +! int p_sw = (int)get_sw_value(); + int p_ts = (int)curbuf->b_p_ts; + struct block_def bd; + int incr; +*** ../vim-7.3.628/src/option.c 2012-07-10 18:31:49.000000000 +0200 +--- src/option.c 2012-08-08 17:45:01.000000000 +0200 +*************** +*** 8125,8131 **** + need_mouse_correct = TRUE; + #endif + +! if (curbuf->b_p_sw <= 0) + { + errmsg = e_positive; + curbuf->b_p_sw = curbuf->b_p_ts; +--- 8125,8131 ---- + need_mouse_correct = TRUE; + #endif + +! if (curbuf->b_p_sw < 0) + { + errmsg = e_positive; + curbuf->b_p_sw = curbuf->b_p_ts; +*************** +*** 11419,11421 **** +--- 11419,11431 ---- + { + return check_opt_strings(p, p_ff_values, FALSE); + } ++ ++ /* ++ * Return the effective shiftwidth value for current buffer, using the ++ * 'tabstop' value when 'shiftwidth' is zero. ++ */ ++ long ++ get_sw_value() ++ { ++ return curbuf->b_p_sw ? curbuf->b_p_sw : curbuf->b_p_ts; ++ } +*** ../vim-7.3.628/src/proto/option.pro 2011-01-22 00:11:42.000000000 +0100 +--- src/proto/option.pro 2012-08-08 17:34:33.000000000 +0200 +*************** +*** 56,59 **** +--- 56,60 ---- + void save_file_ff __ARGS((buf_T *buf)); + int file_ff_differs __ARGS((buf_T *buf, int ignore_empty)); + int check_ff_value __ARGS((char_u *p)); ++ long get_sw_value __ARGS((void)); + /* vim: set ft=c : */ +*** ../vim-7.3.628/src/version.c 2012-08-08 17:31:36.000000000 +0200 +--- src/version.c 2012-08-08 17:57:48.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 629, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +228. You spend Saturday night making the counter on your home page + pass that 2000 mark. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 57f7ff88b01e8dc2d6bebea1f1d4d58aac354789 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:08 +0200 Subject: [PATCH 0451/3340] - patchlevel 630 --- 7.3.630 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.630 diff --git a/7.3.630 b/7.3.630 new file mode 100644 index 00000000..d89cfbfe --- /dev/null +++ b/7.3.630 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.630 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.630 +Problem: "|" does not behave correctly when 'virtualedit' is set. +Solution: Call validate_virtcol(). (David Bürgin) +Files: src/normal.c + + +*** ../vim-7.3.629/src/normal.c 2012-07-29 12:55:21.000000000 +0200 +--- src/normal.c 2012-08-15 13:20:13.000000000 +0200 +*************** +*** 7786,7792 **** +--- 7786,7795 ---- + * virtualedit. Recalculate curwin->w_cursor to avoid bad hilighting. + */ + if (c == Ctrl_V && (ve_flags & VE_BLOCK) && gchar_cursor() == TAB) ++ { ++ validate_virtcol(); + coladvance(curwin->w_virtcol); ++ } + #endif + VIsual = curwin->w_cursor; + +*** ../vim-7.3.629/src/version.c 2012-08-08 18:01:00.000000000 +0200 +--- src/version.c 2012-08-15 13:30:30.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 630, + /**/ + +-- +"Marriage is when a man and woman become as one; the trouble starts +when they try to decide which one" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 82ff66e6320902e8f7e3cd65d577d89fd6a682bf Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:09 +0200 Subject: [PATCH 0452/3340] - patchlevel 631 --- 7.3.631 | 322 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 322 insertions(+) create mode 100644 7.3.631 diff --git a/7.3.631 b/7.3.631 new file mode 100644 index 00000000..b7bff4fc --- /dev/null +++ b/7.3.631 @@ -0,0 +1,322 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.631 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.631 +Problem: Cannot complete user names. +Solution: Add user name completion. (Dominique Pelle) +Files: runtime/doc/map.txt, src/auto/configure, src/config.h.in, + src/configure.in, src/ex_docmd.c, src/ex_getln.c, + src/misc1.c, src/misc2.c, src/proto/misc1.pro, src/vim.h + + +*** ../vim-7.3.630/runtime/doc/map.txt 2012-04-30 18:48:38.000000000 +0200 +--- runtime/doc/map.txt 2012-08-15 13:46:34.000000000 +0200 +*************** +*** 1227,1232 **** +--- 1244,1250 ---- + -complete=syntax syntax file names |'syntax'| + -complete=tag tags + -complete=tag_listfiles tags, file names are shown when CTRL-D is hit ++ -complete=user user names + -complete=var user variables + -complete=custom,{func} custom completion, defined via {func} + -complete=customlist,{func} custom completion, defined via {func} +*** ../vim-7.3.630/src/auto/configure 2012-07-25 16:32:03.000000000 +0200 +--- src/auto/configure 2012-08-15 13:48:06.000000000 +0200 +*************** +*** 10631,10637 **** + fi + + for ac_func in bcmp fchdir fchown fsync getcwd getpseudotty \ +! getpwnam getpwuid getrlimit gettimeofday getwd lstat memcmp \ + memset mkdtemp nanosleep opendir putenv qsort readlink select setenv \ + setpgid setsid sigaltstack sigstack sigset sigsetjmp sigaction \ + sigvec strcasecmp strerror strftime stricmp strncasecmp \ +--- 10631,10637 ---- + fi + + for ac_func in bcmp fchdir fchown fsync getcwd getpseudotty \ +! getpwent getpwnam getpwuid getrlimit gettimeofday getwd lstat memcmp \ + memset mkdtemp nanosleep opendir putenv qsort readlink select setenv \ + setpgid setsid sigaltstack sigstack sigset sigsetjmp sigaction \ + sigvec strcasecmp strerror strftime stricmp strncasecmp \ +*** ../vim-7.3.630/src/config.h.in 2012-02-05 22:51:27.000000000 +0100 +--- src/config.h.in 2012-08-15 13:46:35.000000000 +0200 +*************** +*** 161,166 **** +--- 161,167 ---- + #undef HAVE_FSYNC + #undef HAVE_GETCWD + #undef HAVE_GETPSEUDOTTY ++ #undef HAVE_GETPWENT + #undef HAVE_GETPWNAM + #undef HAVE_GETPWUID + #undef HAVE_GETRLIMIT +*** ../vim-7.3.630/src/configure.in 2012-07-25 16:32:03.000000000 +0200 +--- src/configure.in 2012-08-15 13:46:35.000000000 +0200 +*************** +*** 2994,3000 **** + dnl Check for functions in one big call, to reduce the size of configure. + dnl Can only be used for functions that do not require any include. + AC_CHECK_FUNCS(bcmp fchdir fchown fsync getcwd getpseudotty \ +! getpwnam getpwuid getrlimit gettimeofday getwd lstat memcmp \ + memset mkdtemp nanosleep opendir putenv qsort readlink select setenv \ + setpgid setsid sigaltstack sigstack sigset sigsetjmp sigaction \ + sigvec strcasecmp strerror strftime stricmp strncasecmp \ +--- 2994,3000 ---- + dnl Check for functions in one big call, to reduce the size of configure. + dnl Can only be used for functions that do not require any include. + AC_CHECK_FUNCS(bcmp fchdir fchown fsync getcwd getpseudotty \ +! getpwent getpwnam getpwuid getrlimit gettimeofday getwd lstat memcmp \ + memset mkdtemp nanosleep opendir putenv qsort readlink select setenv \ + setpgid setsid sigaltstack sigstack sigset sigsetjmp sigaction \ + sigvec strcasecmp strerror strftime stricmp strncasecmp \ +*** ../vim-7.3.630/src/ex_docmd.c 2012-08-02 21:24:38.000000000 +0200 +--- src/ex_docmd.c 2012-08-15 13:54:29.000000000 +0200 +*************** +*** 3515,3520 **** +--- 3515,3537 ---- + #endif + } + } ++ #if defined(FEAT_CMDL_COMPL) ++ /* Check for user names */ ++ if (*xp->xp_pattern == '~') ++ { ++ for (p = xp->xp_pattern + 1; *p != NUL && *p != '/'; ++p) ++ ; ++ /* Complete ~user only if it partially matches a user name. ++ * A full match ~user will be replaced by user's home ++ * directory i.e. something like ~user -> /home/user/ */ ++ if (*p == NUL && p > xp->xp_pattern + 1 ++ && match_user(xp->xp_pattern + 1) == 1) ++ { ++ xp->xp_context = EXPAND_USER; ++ ++xp->xp_pattern; ++ } ++ } ++ #endif + } + + /* +*************** +*** 5396,5401 **** +--- 5413,5419 ---- + #endif + {EXPAND_TAGS, "tag"}, + {EXPAND_TAGS_LISTFILES, "tag_listfiles"}, ++ {EXPAND_USER, "user"}, + {EXPAND_USER_VARS, "var"}, + {0, NULL} + }; +*** ../vim-7.3.630/src/ex_getln.c 2012-08-08 18:01:00.000000000 +0200 +--- src/ex_getln.c 2012-08-15 13:46:35.000000000 +0200 +*************** +*** 4336,4341 **** +--- 4336,4342 ---- + * EXPAND_EXPRESSION Complete internal or user defined function/variable + * names in expressions, eg :while s^I + * EXPAND_ENV_VARS Complete environment variable names ++ * EXPAND_USER Complete user names + */ + static void + set_expand_context(xp) +*************** +*** 4681,4686 **** +--- 4682,4688 ---- + {EXPAND_LOCALES, get_locales, TRUE, FALSE}, + #endif + {EXPAND_ENV_VARS, get_env_name, TRUE, TRUE}, ++ {EXPAND_USER, get_users, TRUE, FALSE}, + }; + int i; + +*** ../vim-7.3.630/src/misc1.c 2012-08-08 18:01:00.000000000 +0200 +--- src/misc1.c 2012-08-15 13:57:53.000000000 +0200 +*************** +*** 18,23 **** +--- 18,28 ---- + static char_u *remove_tail __ARGS((char_u *p, char_u *pend, char_u *name)); + static int copy_indent __ARGS((int size, char_u *src)); + ++ /* All user names (for ~user completion as done by shell). */ ++ #if defined(FEAT_CMDL_COMPL) || defined(PROTO) ++ static garray_T ga_users; ++ #endif ++ + /* + * Count the size (in window cells) of the indent in the current line. + */ +*************** +*** 3782,3787 **** +--- 3787,3800 ---- + { + vim_free(homedir); + } ++ ++ # ifdef FEAT_CMDL_COMPL ++ void ++ free_users() ++ { ++ ga_clear_strings(&ga_users); ++ } ++ # endif + #endif + + /* +*************** +*** 4451,4456 **** +--- 4464,4543 ---- + return name; + # endif + } ++ ++ /* ++ * Find all user names for user completion. ++ * Done only once and then cached. ++ */ ++ static void ++ init_users() { ++ static int lazy_init_done = FALSE; ++ ++ if (lazy_init_done) ++ return; ++ ++ lazy_init_done = TRUE; ++ ga_init2(&ga_users, sizeof(char_u *), 20); ++ ++ # if defined(HAVE_GETPWENT) && defined(HAVE_PWD_H) ++ { ++ char_u* user; ++ struct passwd* pw; ++ ++ setpwent(); ++ while ((pw = getpwent()) != NULL) ++ /* pw->pw_name shouldn't be NULL but just in case... */ ++ if (pw->pw_name != NULL) ++ { ++ if (ga_grow(&ga_users, 1) == FAIL) ++ break; ++ user = vim_strsave((char_u*)pw->pw_name); ++ if (user == NULL) ++ break; ++ ((char_u **)(ga_users.ga_data))[ga_users.ga_len++] = user; ++ } ++ endpwent(); ++ } ++ # endif ++ } ++ ++ /* ++ * Function given to ExpandGeneric() to obtain an user names. ++ */ ++ char_u* ++ get_users(xp, idx) ++ expand_T *xp UNUSED; ++ int idx; ++ { ++ init_users(); ++ if (idx < ga_users.ga_len) ++ return ((char_u **)ga_users.ga_data)[idx]; ++ return NULL; ++ } ++ ++ /* ++ * Check whether name matches a user name. Return: ++ * 0 if name does not match any user name. ++ * 1 if name partially matches the beginning of a user name. ++ * 2 is name fully matches a user name. ++ */ ++ int match_user(name) ++ char_u* name; ++ { ++ int i; ++ int n = (int)STRLEN(name); ++ int result = 0; ++ ++ init_users(); ++ for (i = 0; i < ga_users.ga_len; i++) ++ { ++ if (STRCMP(((char_u **)ga_users.ga_data)[i], name) == 0) ++ return 2; /* full match */ ++ if (STRNCMP(((char_u **)ga_users.ga_data)[i], name, n) == 0) ++ result = 1; /* partial match */ ++ } ++ return result; ++ } + #endif + + /* +*** ../vim-7.3.630/src/misc2.c 2012-06-29 15:51:26.000000000 +0200 +--- src/misc2.c 2012-08-15 13:46:35.000000000 +0200 +*************** +*** 1110,1115 **** +--- 1110,1118 ---- + free_all_marks(); + alist_clear(&global_alist); + free_homedir(); ++ # if defined(FEAT_CMDL_COMPL) ++ free_users(); ++ # endif + free_search_patterns(); + free_old_sub(); + free_last_insert(); +*** ../vim-7.3.630/src/proto/misc1.pro 2012-06-06 16:12:54.000000000 +0200 +--- src/proto/misc1.pro 2012-08-15 13:46:35.000000000 +0200 +*************** +*** 50,55 **** +--- 50,56 ---- + void vim_beep __ARGS((void)); + void init_homedir __ARGS((void)); + void free_homedir __ARGS((void)); ++ void free_users __ARGS((void)); + char_u *expand_env_save __ARGS((char_u *src)); + char_u *expand_env_save_opt __ARGS((char_u *src, int one)); + void expand_env __ARGS((char_u *src, char_u *dst, int dstlen)); +*************** +*** 57,62 **** +--- 58,65 ---- + char_u *vim_getenv __ARGS((char_u *name, int *mustfree)); + void vim_setenv __ARGS((char_u *name, char_u *val)); + char_u *get_env_name __ARGS((expand_T *xp, int idx)); ++ char_u *get_users __ARGS((expand_T *xp, int idx)); ++ int match_user __ARGS((char_u* name)); + void home_replace __ARGS((buf_T *buf, char_u *src, char_u *dst, int dstlen, int one)); + char_u *home_replace_save __ARGS((buf_T *buf, char_u *src)); + int fullpathcmp __ARGS((char_u *s1, char_u *s2, int checkname)); +*** ../vim-7.3.630/src/vim.h 2012-07-10 17:14:50.000000000 +0200 +--- src/vim.h 2012-08-15 13:46:35.000000000 +0200 +*************** +*** 782,787 **** +--- 782,788 ---- + #define EXPAND_OWNSYNTAX 39 + #define EXPAND_LOCALES 40 + #define EXPAND_HISTORY 41 ++ #define EXPAND_USER 42 + + /* Values for exmode_active (0 is no exmode) */ + #define EXMODE_NORMAL 1 +*** ../vim-7.3.630/src/version.c 2012-08-15 13:30:55.000000000 +0200 +--- src/version.c 2012-08-15 14:01:12.000000000 +0200 +*************** +*** 716,717 **** +--- 716,719 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 631, + /**/ + +-- +"Marriage is the process of finding out what kind of man your wife +would have preferred" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 76628d32ca28d579aeac57b1568745bd4717e650 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:09 +0200 Subject: [PATCH 0453/3340] - patchlevel 632 --- 7.3.632 | 537 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 537 insertions(+) create mode 100644 7.3.632 diff --git a/7.3.632 b/7.3.632 new file mode 100644 index 00000000..9e38969e --- /dev/null +++ b/7.3.632 @@ -0,0 +1,537 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.632 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.632 +Problem: Cannot select beyond 222 columns with the mouse in xterm. +Solution: Add support for SGR mouse tracking. (Hayaki Saito) +Files: runtime/doc/options.txt, src/feature.h, src/keymap.h, src/misc2.c, + src/option.h, src/os_unix.c, src/term.c, src/version.c + + +*** ../vim-7.3.631/runtime/doc/options.txt 2012-07-10 16:49:08.000000000 +0200 +--- runtime/doc/options.txt 2012-08-15 16:04:26.000000000 +0200 +*************** +*** 7383,7388 **** +--- 7424,7435 ---- + jsbterm JSB term mouse handling. + *pterm-mouse* + pterm QNX pterm mouse handling. ++ *urxvt-mouse* ++ urxvt Mouse handling for the urxvt (rxvt-unicode) terminal. ++ *sgr-mouse* ++ sgr Mouse handling for the terminal that emits SGR-styled ++ mouse reporting. Works with xterm version 277 or ++ later. + + The mouse handling must be enabled at compile time |+mouse_xterm| + |+mouse_dec| |+mouse_netterm|. +*************** +*** 7395,7400 **** +--- 7442,7448 ---- + or "xterm2" already. The main use of this option is to set it to + "xterm", when the terminal name doesn't start with "xterm", but it can + handle xterm mouse codes. ++ The "sgr" value will be set if the xterm version is 277 or later. + The "xterm2" value will be set if the xterm version is reported to be + 95 or higher. This only works when compiled with the |+termresponse| + feature and if |t_RV| is set to the escape sequence to request the +*** ../vim-7.3.631/src/feature.h 2012-04-25 16:50:44.000000000 +0200 +--- src/feature.h 2012-08-15 15:46:07.000000000 +0200 +*************** +*** 1056,1061 **** +--- 1056,1064 ---- + # ifdef FEAT_BIG + # define FEAT_MOUSE_URXVT + # endif ++ # ifdef FEAT_BIG ++ # define FEAT_MOUSE_SGR ++ # endif + # if defined(FEAT_NORMAL) && (defined(MSDOS) || defined(WIN3264)) + # define DOS_MOUSE + # endif +*************** +*** 1077,1082 **** +--- 1080,1090 ---- + # define FEAT_MOUSE_XTERM + #endif + ++ /* sgr is a small variation of mouse_xterm, and shares its code */ ++ #if defined(FEAT_MOUSE_SGR) && !defined(FEAT_MOUSE_XTERM) ++ # define FEAT_MOUSE_XTERM ++ #endif ++ + /* Define FEAT_MOUSE when any of the above is defined or FEAT_GUI. */ + #if !defined(FEAT_MOUSE_TTY) \ + && (defined(FEAT_MOUSE_XTERM) \ +*************** +*** 1087,1093 **** + || defined(FEAT_MOUSE_JSB) \ + || defined(FEAT_MOUSE_PTERM) \ + || defined(FEAT_SYSMOUSE) \ +! || defined(FEAT_MOUSE_URXVT)) + # define FEAT_MOUSE_TTY /* include non-GUI mouse support */ + #endif + #if !defined(FEAT_MOUSE) && (defined(FEAT_MOUSE_TTY) || defined(FEAT_GUI)) +--- 1095,1102 ---- + || defined(FEAT_MOUSE_JSB) \ + || defined(FEAT_MOUSE_PTERM) \ + || defined(FEAT_SYSMOUSE) \ +! || defined(FEAT_MOUSE_URXVT) \ +! || defined(FEAT_MOUSE_SGR)) + # define FEAT_MOUSE_TTY /* include non-GUI mouse support */ + #endif + #if !defined(FEAT_MOUSE) && (defined(FEAT_MOUSE_TTY) || defined(FEAT_GUI)) +*** ../vim-7.3.631/src/keymap.h 2012-01-20 17:15:47.000000000 +0100 +--- src/keymap.h 2012-08-15 15:46:07.000000000 +0200 +*************** +*** 110,115 **** +--- 110,118 ---- + /* Used for the urxvt mouse. */ + #define KS_URXVT_MOUSE 238 + ++ /* Used for the sgr mouse. */ ++ #define KS_SGR_MOUSE 237 ++ + /* + * Filler used after KS_SPECIAL and others + */ +*************** +*** 412,417 **** +--- 415,421 ---- + #define K_JSBTERM_MOUSE TERMCAP2KEY(KS_JSBTERM_MOUSE, KE_FILLER) + #define K_PTERM_MOUSE TERMCAP2KEY(KS_PTERM_MOUSE, KE_FILLER) + #define K_URXVT_MOUSE TERMCAP2KEY(KS_URXVT_MOUSE, KE_FILLER) ++ #define K_SGR_MOUSE TERMCAP2KEY(KS_SGR_MOUSE, KE_FILLER) + + #define K_SELECT TERMCAP2KEY(KS_SELECT, KE_FILLER) + #define K_TEAROFF TERMCAP2KEY(KS_TEAROFF, KE_FILLER) +*** ../vim-7.3.631/src/misc2.c 2012-08-15 14:04:50.000000000 +0200 +--- src/misc2.c 2012-08-15 15:46:07.000000000 +0200 +*************** +*** 2433,2438 **** +--- 2433,2441 ---- + #ifdef FEAT_MOUSE_URXVT + {K_URXVT_MOUSE, (char_u *)"UrxvtMouse"}, + #endif ++ #ifdef FEAT_MOUSE_SGR ++ {K_SGR_MOUSE, (char_u *)"SgrMouse"}, ++ #endif + {K_LEFTMOUSE, (char_u *)"LeftMouse"}, + {K_LEFTMOUSE_NM, (char_u *)"LeftMouseNM"}, + {K_LEFTDRAG, (char_u *)"LeftDrag"}, +*** ../vim-7.3.631/src/option.h 2012-07-10 16:49:08.000000000 +0200 +--- src/option.h 2012-08-15 15:46:07.000000000 +0200 +*************** +*** 822,828 **** + EXTERN char_u *p_ttym; /* 'ttymouse' */ + EXTERN unsigned ttym_flags; + # ifdef IN_OPTION_C +! static char *(p_ttym_values[]) = {"xterm", "xterm2", "dec", "netterm", "jsbterm", "pterm", "urxvt", NULL}; + # endif + # define TTYM_XTERM 0x01 + # define TTYM_XTERM2 0x02 +--- 822,828 ---- + EXTERN char_u *p_ttym; /* 'ttymouse' */ + EXTERN unsigned ttym_flags; + # ifdef IN_OPTION_C +! static char *(p_ttym_values[]) = {"xterm", "xterm2", "dec", "netterm", "jsbterm", "pterm", "urxvt", "sgr", NULL}; + # endif + # define TTYM_XTERM 0x01 + # define TTYM_XTERM2 0x02 +*************** +*** 831,836 **** +--- 831,837 ---- + # define TTYM_JSBTERM 0x10 + # define TTYM_PTERM 0x20 + # define TTYM_URXVT 0x40 ++ # define TTYM_SGR 0x80 + #endif + EXTERN char_u *p_udir; /* 'undodir' */ + EXTERN long p_ul; /* 'undolevels' */ +*** ../vim-7.3.631/src/os_unix.c 2012-04-20 15:55:10.000000000 +0200 +--- src/os_unix.c 2012-08-15 16:06:54.000000000 +0200 +*************** +*** 2159,2168 **** +--- 2159,2171 ---- + * Return 1 for "xterm". + * Return 2 for "xterm2". + * Return 3 for "urxvt". ++ * Return 4 for "sgr". + */ + int + use_xterm_mouse() + { ++ if (ttym_flags == TTYM_SGR) ++ return 4; + if (ttym_flags == TTYM_URXVT) + return 3; + if (ttym_flags == TTYM_XTERM2) +*************** +*** 3339,3345 **** + xterm_mouse_vers = use_xterm_mouse(); + + # ifdef FEAT_MOUSE_URXVT +! if (ttym_flags == TTYM_URXVT) { + out_str_nf((char_u *) + (on + ? IF_EB("\033[?1015h", ESC_STR "[?1015h") +--- 3342,3349 ---- + xterm_mouse_vers = use_xterm_mouse(); + + # ifdef FEAT_MOUSE_URXVT +! if (ttym_flags == TTYM_URXVT) +! { + out_str_nf((char_u *) + (on + ? IF_EB("\033[?1015h", ESC_STR "[?1015h") +*************** +*** 3348,3353 **** +--- 3352,3368 ---- + } + # endif + ++ # ifdef FEAT_MOUSE_SGR ++ if (ttym_flags == TTYM_SGR) ++ { ++ out_str_nf((char_u *) ++ (on ++ ? IF_EB("\033[?1006h", ESC_STR "[?1006h") ++ : IF_EB("\033[?1006l", ESC_STR "[?1006l"))); ++ ison = on; ++ } ++ # endif ++ + if (xterm_mouse_vers > 0) + { + if (on) /* enable mouse events, use mouse tracking if available */ +*************** +*** 3577,3582 **** +--- 3592,3618 ---- + else + del_mouse_termcode(KS_URXVT_MOUSE); + # endif ++ # ifdef FEAT_MOUSE_SGR ++ /* same as the dec mouse */ ++ if (use_xterm_mouse() == 4 ++ # ifdef FEAT_GUI ++ && !gui.in_use ++ # endif ++ ) ++ { ++ set_mouse_termcode(KS_SGR_MOUSE, (char_u *)(term_is_8bit(T_NAME) ++ ? IF_EB("\233<", CSI_STR "<") ++ : IF_EB("\033[<", ESC_STR "[<"))); ++ ++ if (*p_mouse != NUL) ++ { ++ mch_setmouse(FALSE); ++ setmouse(); ++ } ++ } ++ else ++ del_mouse_termcode(KS_SGR_MOUSE); ++ # endif + } + #endif + +*** ../vim-7.3.631/src/term.c 2012-02-05 22:05:44.000000000 +0100 +--- src/term.c 2012-08-15 16:14:09.000000000 +0200 +*************** +*** 1997,2002 **** +--- 1997,2003 ---- + # define HMT_JSBTERM 8 + # define HMT_PTERM 16 + # define HMT_URXVT 32 ++ # define HMT_SGR 64 + static int has_mouse_termcode = 0; + # endif + +*************** +*** 2037,2042 **** +--- 2038,2048 ---- + has_mouse_termcode |= HMT_URXVT; + else + # endif ++ # ifdef FEAT_MOUSE_SGR ++ if (n == KS_SGR_MOUSE) ++ has_mouse_termcode |= HMT_SGR; ++ else ++ # endif + has_mouse_termcode |= HMT_NORMAL; + # endif + } +*************** +*** 2079,2084 **** +--- 2085,2095 ---- + has_mouse_termcode &= ~HMT_URXVT; + else + # endif ++ # ifdef FEAT_MOUSE_SGR ++ if (n == KS_SGR_MOUSE) ++ has_mouse_termcode &= ~HMT_SGR; ++ else ++ # endif + has_mouse_termcode &= ~HMT_NORMAL; + # endif + } +*************** +*** 4023,4029 **** + #ifdef FEAT_TERMRESPONSE + if (key_name[0] == NUL + /* URXVT mouse uses [#;#;#M, but we are matching [ */ +! || key_name[0] == KS_URXVT_MOUSE) + { + /* Check for xterm version string: "[>{x};{vers};{y}c". Also + * eat other possible responses to t_RV, rxvt returns +--- 4034,4041 ---- + #ifdef FEAT_TERMRESPONSE + if (key_name[0] == NUL + /* URXVT mouse uses [#;#;#M, but we are matching [ */ +! || key_name[0] == KS_URXVT_MOUSE +! || key_name[0] == KS_SGR_MOUSE) + { + /* Check for xterm version string: "[>{x};{vers};{y}c". Also + * eat other possible responses to t_RV, rxvt returns +*************** +*** 4061,4066 **** +--- 4073,4088 ---- + + if (tp[1 + (tp[0] != CSI)] == '>' && j == 2) + { ++ # ifdef TTYM_SGR ++ if (extra >= 277 ++ # ifdef TTYM_URXVT ++ && ttym_flags != TTYM_URXVT ++ # endif ++ ) ++ set_option_value((char_u *)"ttym", 0L, ++ (char_u *)"sgr", 0); ++ else ++ # endif + /* if xterm version >= 95 use mouse dragging */ + if (extra >= 95 + # ifdef TTYM_URXVT +*************** +*** 4147,4167 **** + /* + * If it is a mouse click, get the coordinates. + */ +! if (key_name[0] == (int)KS_MOUSE + # ifdef FEAT_MOUSE_JSB +! || key_name[0] == (int)KS_JSBTERM_MOUSE + # endif + # ifdef FEAT_MOUSE_NET +! || key_name[0] == (int)KS_NETTERM_MOUSE + # endif + # ifdef FEAT_MOUSE_DEC +! || key_name[0] == (int)KS_DEC_MOUSE + # endif + # ifdef FEAT_MOUSE_PTERM +! || key_name[0] == (int)KS_PTERM_MOUSE + # endif + # ifdef FEAT_MOUSE_URXVT +! || key_name[0] == (int)KS_URXVT_MOUSE + # endif + ) + { +--- 4169,4192 ---- + /* + * If it is a mouse click, get the coordinates. + */ +! if (key_name[0] == KS_MOUSE + # ifdef FEAT_MOUSE_JSB +! || key_name[0] == KS_JSBTERM_MOUSE + # endif + # ifdef FEAT_MOUSE_NET +! || key_name[0] == KS_NETTERM_MOUSE + # endif + # ifdef FEAT_MOUSE_DEC +! || key_name[0] == KS_DEC_MOUSE + # endif + # ifdef FEAT_MOUSE_PTERM +! || key_name[0] == KS_PTERM_MOUSE + # endif + # ifdef FEAT_MOUSE_URXVT +! || key_name[0] == KS_URXVT_MOUSE +! # endif +! # ifdef FEAT_MOUSE_SGR +! || key_name[0] == KS_SGR_MOUSE + # endif + ) + { +*************** +*** 4243,4250 **** + } + } + +! # ifdef FEAT_MOUSE_URXVT +! if (key_name[0] == (int)KS_URXVT_MOUSE) + { + for (;;) + { +--- 4268,4276 ---- + } + } + +! # if defined(FEAT_MOUSE_URXVT) || defined(FEAT_MOUSE_SGR) +! if (key_name[0] == KS_URXVT_MOUSE +! || key_name[0] == KS_SGR_MOUSE) + { + for (;;) + { +*************** +*** 4256,4261 **** +--- 4282,4301 ---- + * ^-- row + * ^----- column + * ^-------- code ++ * ++ * SGR 1006 mouse reporting mode: ++ * Almost identical to xterm mouse mode, except the values ++ * are decimal instead of bytes. ++ * ++ * \033[<%d;%d;%dM ++ * ^-- row ++ * ^----- column ++ * ^-------- code ++ * ++ * \033[<%d;%d;%dm : mouse release event ++ * ^-- row ++ * ^----- column ++ * ^-------- code + */ + p = tp + slen; + +*************** +*** 4263,4294 **** + if (*p++ != ';') + return -1; + + mouse_col = getdigits(&p) - 1; + if (*p++ != ';') + return -1; + + mouse_row = getdigits(&p) - 1; +! if (*p++ != 'M') + return -1; + + slen += (int)(p - (tp + slen)); + + /* skip this one if next one has same code (like xterm + * case) */ + j = termcodes[idx].len; +! if (STRNCMP(tp, tp + slen, (size_t)j) == 0) { +! /* check if the command is complete by looking for the +! * M */ + int slen2; + int cmd_complete = 0; +! for (slen2 = slen; slen2 < len; slen2++) { +! if (tp[slen2] == 'M') { + cmd_complete = 1; + break; + } + } + p += j; +! if (cmd_complete && getdigits(&p) == mouse_code) { + slen += j; /* skip the \033[ */ + continue; + } +--- 4303,4348 ---- + if (*p++ != ';') + return -1; + ++ /* when mouse reporting is SGR, add 32 to mouse code */ ++ if (key_name[0] == KS_SGR_MOUSE) ++ mouse_code += 32; ++ + mouse_col = getdigits(&p) - 1; + if (*p++ != ';') + return -1; + + mouse_row = getdigits(&p) - 1; +! if (key_name[0] == KS_SGR_MOUSE && *p == 'm') +! mouse_code |= MOUSE_RELEASE; +! else if (*p != 'M') + return -1; ++ p++; + + slen += (int)(p - (tp + slen)); + + /* skip this one if next one has same code (like xterm + * case) */ + j = termcodes[idx].len; +! if (STRNCMP(tp, tp + slen, (size_t)j) == 0) +! { + int slen2; + int cmd_complete = 0; +! +! /* check if the command is complete by looking for the +! * 'M' */ +! for (slen2 = slen; slen2 < len; slen2++) +! { +! if (tp[slen2] == 'M' +! || (key_name[0] == KS_SGR_MOUSE +! && tp[slen2] == 'm')) +! { + cmd_complete = 1; + break; + } + } + p += j; +! if (cmd_complete && getdigits(&p) == mouse_code) +! { + slen += j; /* skip the \033[ */ + continue; + } +*************** +*** 4302,4307 **** +--- 4356,4364 ---- + #ifdef FEAT_MOUSE_URXVT + || key_name[0] == (int)KS_URXVT_MOUSE + #endif ++ #ifdef FEAT_MOUSE_SGR ++ || key_name[0] == KS_SGR_MOUSE ++ #endif + ) + { + # if !defined(MSWIN) && !defined(MSDOS) +*** ../vim-7.3.631/src/version.c 2012-08-15 14:04:50.000000000 +0200 +--- src/version.c 2012-08-15 15:47:30.000000000 +0200 +*************** +*** 384,389 **** +--- 384,394 ---- + # else + "-mouse_urxvt", + # endif ++ # ifdef FEAT_MOUSE_SGR ++ "+mouse_sgr", ++ # else ++ "-mouse_sgr", ++ # endif + #endif + #ifdef __QNX__ + # ifdef FEAT_MOUSE_PTERM +*** ../vim-7.3.631/src/version.c 2012-08-15 14:04:50.000000000 +0200 +--- src/version.c 2012-08-15 15:47:30.000000000 +0200 +*************** +*** 716,717 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 632, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +243. You unsuccessfully try to download a pizza from www.dominos.com. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4fb6367dc251f5076a410b1a93ac0a5e635e0abe Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:09 +0200 Subject: [PATCH 0454/3340] - patchlevel 633 --- 7.3.633 | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 7.3.633 diff --git a/7.3.633 b/7.3.633 new file mode 100644 index 00000000..899ccb38 --- /dev/null +++ b/7.3.633 @@ -0,0 +1,81 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.633 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.633 +Problem: Selection remains displayed as selected after selecting another + text. +Solution: Call xterm_update() before select(). (Andrew Pimlott) +Files: src/os_unix.c + + +*** ../vim-7.3.632/src/os_unix.c 2012-08-15 16:20:59.000000000 +0200 +--- src/os_unix.c 2012-08-15 17:15:58.000000000 +0200 +*************** +*** 5196,5201 **** +--- 5196,5205 ---- + FD_SET(ConnectionNumber(xterm_dpy), &rfds); + if (maxfd < ConnectionNumber(xterm_dpy)) + maxfd = ConnectionNumber(xterm_dpy); ++ ++ /* An event may have already been read but not handled. In ++ * particulary, XFlush may cause this. */ ++ xterm_update(); + } + # endif + # ifdef FEAT_MOUSE_GPM +*************** +*** 5216,5229 **** + maxfd = xsmp_icefd; + } + # endif +! #ifdef FEAT_NETBEANS_INTG + if (nb_fd != -1) + { + FD_SET(nb_fd, &rfds); + if (maxfd < nb_fd) + maxfd = nb_fd; + } +! #endif + + # ifdef OLD_VMS + /* Old VMS as v6.2 and older have broken select(). It waits more than +--- 5220,5233 ---- + maxfd = xsmp_icefd; + } + # endif +! # ifdef FEAT_NETBEANS_INTG + if (nb_fd != -1) + { + FD_SET(nb_fd, &rfds); + if (maxfd < nb_fd) + maxfd = nb_fd; + } +! # endif + + # ifdef OLD_VMS + /* Old VMS as v6.2 and older have broken select(). It waits more than +*** ../vim-7.3.632/src/version.c 2012-08-15 16:20:59.000000000 +0200 +--- src/version.c 2012-08-15 17:22:17.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 633, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +245. You use Real Audio to listen to a radio station from a distant + city rather than turn on your stereo system. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 527e55d16d1424ca989367251470f32e62da99cc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:10 +0200 Subject: [PATCH 0455/3340] - patchlevel 634 --- 7.3.634 | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 7.3.634 diff --git a/7.3.634 b/7.3.634 new file mode 100644 index 00000000..3262bab3 --- /dev/null +++ b/7.3.634 @@ -0,0 +1,57 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.634 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.634 +Problem: Month/Day format for undo is confusing. (Marcin Szamotulski) +Solution: Always use Year/Month/Day, should work for everybody. +Files: src/undo.c + + +*** ../vim-7.3.633/src/undo.c 2012-06-01 13:46:06.000000000 +0200 +--- src/undo.c 2012-08-23 12:43:24.000000000 +0200 +*************** +*** 2880,2890 **** + if (time(NULL) - tt < (60L * 60L * 12L)) + /* within 12 hours */ + (void)strftime((char *)buf, buflen, "%H:%M:%S", curtime); +- else if (time(NULL) - tt < (60L * 60L * 24L * 180L)) +- /* within 6 months */ +- (void)strftime((char *)buf, buflen, "%m/%d %H:%M:%S", curtime); + else +! /* long ago */ + (void)strftime((char *)buf, buflen, "%Y/%m/%d %H:%M:%S", curtime); + } + else +--- 2880,2887 ---- + if (time(NULL) - tt < (60L * 60L * 12L)) + /* within 12 hours */ + (void)strftime((char *)buf, buflen, "%H:%M:%S", curtime); + else +! /* longer ago */ + (void)strftime((char *)buf, buflen, "%Y/%m/%d %H:%M:%S", curtime); + } + else +*** ../vim-7.3.633/src/version.c 2012-08-15 17:26:53.000000000 +0200 +--- src/version.c 2012-08-23 12:58:36.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 634, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +10E. You start counting in hex. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b23fd3f8f7e4286158d21ba90ad6b40466e78d40 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:10 +0200 Subject: [PATCH 0456/3340] - patchlevel 635 --- 7.3.635 | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 7.3.635 diff --git a/7.3.635 b/7.3.635 new file mode 100644 index 00000000..4a677025 --- /dev/null +++ b/7.3.635 @@ -0,0 +1,50 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.635 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.635 +Problem: Issue 21: System call during startup sets 'lines' to a wrong + value. (Karl Yngve) +Solution: Don't set the shell size while the GUI is still starting up. + (Christian Brabandt) +Files: src/ui.c + + +*** ../vim-7.3.634/src/ui.c 2012-07-10 16:49:08.000000000 +0200 +--- src/ui.c 2012-08-23 13:25:26.000000000 +0200 +*************** +*** 298,303 **** +--- 298,306 ---- + int retval; + + #ifdef FEAT_GUI ++ if (gui.starting) ++ /* possibly a system call during startup, check later */ ++ return OK; + if (gui.in_use) + retval = gui_get_shellsize(); + else +*** ../vim-7.3.634/src/version.c 2012-08-23 12:58:56.000000000 +0200 +--- src/version.c 2012-08-23 13:27:00.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 635, + /**/ + +-- +ARTHUR: This new learning amazes me, Sir Bedevere. Explain again how sheep's + bladders may be employed to prevent earthquakes. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2e6f436bf80bad14fe81ba4803f324921b5d0b10 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:10 +0200 Subject: [PATCH 0457/3340] - patchlevel 636 --- 7.3.636 | 148 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 148 insertions(+) create mode 100644 7.3.636 diff --git a/7.3.636 b/7.3.636 new file mode 100644 index 00000000..453a7fc9 --- /dev/null +++ b/7.3.636 @@ -0,0 +1,148 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.636 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.636 (after 7.3.625) +Problem: Not all zero-width matches handled correctly for "gn". +Solution: Move zero-width detection to a separate function. (Christian + Brabandt) +Files: src/search.c + + +*** ../vim-7.3.635/src/search.c 2012-08-08 15:27:54.000000000 +0200 +--- src/search.c 2012-08-23 15:52:50.000000000 +0200 +*************** +*** 4526,4531 **** +--- 4526,4533 ---- + #endif /* FEAT_TEXTOBJ */ + + #if defined(FEAT_VISUAL) || defined(PROTO) ++ static int is_zerowidth __ARGS((char_u *pattern)); ++ + /* + * Find next search match under cursor, cursor at end. + * Used while an operator is pending, and in Visual mode. +*************** +*** 4546,4556 **** + int visual_active = FALSE; + int flags = 0; + pos_T save_VIsual; +- regmmatch_T regmatch; +- int nmatched = 0; + int zerowidth = FALSE; + +- + /* wrapping should not occur */ + p_ws = FALSE; + +--- 4548,4555 ---- +*************** +*** 4583,4606 **** + else + orig_pos = pos = start_pos = curwin->w_cursor; + +! /* +! * Check for zero-width pattern. +! */ +! if (search_regcomp(spats[last_idx].pat, RE_SEARCH, RE_SEARCH, +! ((SEARCH_HIS + SEARCH_KEEP)), ®match) == FAIL) + return FAIL; + +- /* Zero-width pattern should match somewhere, then we can check if start +- * and end are in the same position. */ +- nmatched = vim_regexec_multi(®match, curwin, curbuf, +- curwin->w_cursor.lnum, (colnr_T)0, NULL); +- if (called_emsg) +- return FAIL; +- if (nmatched && regmatch.startpos[0].lnum == regmatch.endpos[0].lnum +- && regmatch.endpos[0].col == regmatch.startpos[0].col) +- zerowidth = TRUE; +- vim_free(regmatch.regprog); +- + /* + * The trick is to first search backwards and then search forward again, + * so that a match at the current cursor position will be correctly +--- 4582,4592 ---- + else + orig_pos = pos = start_pos = curwin->w_cursor; + +! /* Is the pattern is zero-width? */ +! zerowidth = is_zerowidth(spats[last_idx].pat); +! if (zerowidth == -1) + return FAIL; + + /* + * The trick is to first search backwards and then search forward again, + * so that a match at the current cursor position will be correctly +*************** +*** 4693,4698 **** +--- 4679,4721 ---- + + return OK; + } ++ ++ /* ++ * Check if the pattern is zero-width. ++ * Returns TRUE, FALSE or -1 for failure. ++ */ ++ static int ++ is_zerowidth(pattern) ++ char_u *pattern; ++ { ++ regmmatch_T regmatch; ++ int nmatched = 0; ++ int result = -1; ++ pos_T pos; ++ ++ if (search_regcomp(pattern, RE_SEARCH, RE_SEARCH, ++ SEARCH_KEEP, ®match) == FAIL) ++ return -1; ++ ++ /* move to match */ ++ clearpos(&pos); ++ if (searchit(curwin, curbuf, &pos, FORWARD, spats[last_idx].pat, 1, ++ SEARCH_KEEP, RE_SEARCH, 0, NULL) != FAIL) ++ { ++ /* Zero-width pattern should match somewhere, then we can check if ++ * start and end are in the same position. */ ++ nmatched = vim_regexec_multi(®match, curwin, curbuf, ++ pos.lnum, (colnr_T)0, NULL); ++ ++ if (!called_emsg) ++ result = (nmatched != 0 ++ && regmatch.startpos[0].lnum == regmatch.endpos[0].lnum ++ && regmatch.startpos[0].col == regmatch.endpos[0].col); ++ } ++ ++ vim_free(regmatch.regprog); ++ return result; ++ } + #endif /* FEAT_VISUAL */ + + #if defined(FEAT_LISP) || defined(FEAT_CINDENT) || defined(FEAT_TEXTOBJ) \ +*** ../vim-7.3.635/src/version.c 2012-08-23 13:28:50.000000000 +0200 +--- src/version.c 2012-08-23 15:25:23.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 636, + /**/ + +-- +Edison's greatest achievement came in 1879, when he invented the +electric company. Edison's design was a brilliant adaptation of the +simple electrical circuit: the electric company sends electricity +through a wire to a customer, then immediately gets the electricity +back through another wire + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 47f669a6906724c6060c7e1839c8c9b373b3909f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:11 +0200 Subject: [PATCH 0458/3340] - patchlevel 637 --- 7.3.637 | 94 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 94 insertions(+) create mode 100644 7.3.637 diff --git a/7.3.637 b/7.3.637 new file mode 100644 index 00000000..f7f1d903 --- /dev/null +++ b/7.3.637 @@ -0,0 +1,94 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.637 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.637 +Problem: Cannot catch the error caused by a foldopen when there is no fold. + (ZyX, Issue 48) +Solution: Do not break out of the loop early when inside try/catch. + (Christian Brabandt) Except when there is a syntax error. +Files: src/ex_docmd.c, src/globals.h + + +*** ../vim-7.3.636/src/ex_docmd.c 2012-08-15 14:04:50.000000000 +0200 +--- src/ex_docmd.c 2012-08-23 18:39:08.000000000 +0200 +*************** +*** 1295,1301 **** + && cstack.cs_trylevel == 0 + #endif + ) +! && !(did_emsg && used_getline + && (getline_equal(fgetline, cookie, getexmodeline) + || getline_equal(fgetline, cookie, getexline))) + && (next_cmdline != NULL +--- 1295,1308 ---- + && cstack.cs_trylevel == 0 + #endif + ) +! && !(did_emsg +! #ifdef FEAT_EVAL +! /* Keep going when inside try/catch, so that the error can be +! * dealth with, except when it is a syntax error, it may cause +! * the :endtry to be missed. */ +! && (cstack.cs_trylevel == 0 || did_emsg_syntax) +! #endif +! && used_getline + && (getline_equal(fgetline, cookie, getexmodeline) + || getline_equal(fgetline, cookie, getexline))) + && (next_cmdline != NULL +*************** +*** 1305,1310 **** +--- 1312,1318 ---- + || (flags & DOCMD_REPEAT))); + + vim_free(cmdline_copy); ++ did_emsg_syntax = FALSE; + #ifdef FEAT_EVAL + free_cmdlines(&lines_ga); + ga_clear(&lines_ga); +*************** +*** 2137,2142 **** +--- 2145,2151 ---- + if (!sourcing) + append_command(*cmdlinep); + errormsg = IObuff; ++ did_emsg_syntax = TRUE; + } + goto doend; + } +*** ../vim-7.3.636/src/globals.h 2012-07-10 16:49:08.000000000 +0200 +--- src/globals.h 2012-08-23 18:29:09.000000000 +0200 +*************** +*** 183,188 **** +--- 183,190 ---- + #endif + EXTERN int did_emsg; /* set by emsg() when the message + is displayed or thrown */ ++ EXTERN int did_emsg_syntax; /* did_emsg set because of a ++ syntax error */ + EXTERN int called_emsg; /* always set by emsg() */ + EXTERN int ex_exitval INIT(= 0); /* exit value for ex mode */ + EXTERN int emsg_on_display INIT(= FALSE); /* there is an error message */ +*** ../vim-7.3.636/src/version.c 2012-08-23 15:53:00.000000000 +0200 +--- src/version.c 2012-08-23 17:59:12.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 637, + /**/ + +-- +GOD: That is your purpose Arthur ... the Quest for the Holy Grail ... + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ea042019e92c60a21ce89b7c78352f93b5f9cf81 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:11 +0200 Subject: [PATCH 0459/3340] - patchlevel 638 --- 7.3.638 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.638 diff --git a/7.3.638 b/7.3.638 new file mode 100644 index 00000000..f88a9399 --- /dev/null +++ b/7.3.638 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.638 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.638 +Problem: Unecessary redraw of the previous character. +Solution: Check if the character is double-width. (Jon Long) +Files: src/screen.c + + +*** ../vim-7.3.637/src/screen.c 2012-07-10 16:49:08.000000000 +0200 +--- src/screen.c 2012-08-23 18:49:33.000000000 +0200 +*************** +*** 5332,5339 **** + && (ScreenLinesUC[off_from] != ScreenLinesUC[off_to] + || (ScreenLinesUC[off_from] != 0 + && comp_char_differs(off_from, off_to)) +! || (cols > 1 && ScreenLines[off_from + 1] +! != ScreenLines[off_to + 1]))) + #endif + )) + return TRUE; +--- 5332,5340 ---- + && (ScreenLinesUC[off_from] != ScreenLinesUC[off_to] + || (ScreenLinesUC[off_from] != 0 + && comp_char_differs(off_from, off_to)) +! || ((*mb_off2cells)(off_from, off_from + cols) > 1 +! && ScreenLines[off_from + 1] +! != ScreenLines[off_to + 1]))) + #endif + )) + return TRUE; +*** ../vim-7.3.637/src/version.c 2012-08-23 18:43:06.000000000 +0200 +--- src/version.c 2012-08-23 18:47:11.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 638, + /**/ + +-- +There is a fine line between courage and foolishness. +Unfortunately, it's not a fence. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2301591f7131a2efd8fc9d3656e461ecf6a2c0f8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 11:54:11 +0200 Subject: [PATCH 0460/3340] - patchlevel 638 --- README.patches | 82 ++++++++++++++++++++++++ vim.spec | 169 ++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 250 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index c9045377..dfe8b806 100644 --- a/README.patches +++ b/README.patches @@ -587,3 +587,85 @@ Individual patches for Vim 7.3: 1660 7.3.554 compiler warning for unused argument 7968 7.3.555 building on IBM z/OS fails 2194 7.3.556 compiler warnings on 64 bit Windows + 2958 7.3.557 crash when an autocommand wipes out a buffer when it is hidden + 2956 7.3.558 (after 7.3.552) memory access error + 3483 7.3.559 home_replace() does not work with 8.3 filename + 1551 7.3.560 get an error for a locked argument in extend() + 1511 7.3.561 refresh: always in a complete function breaks the "." command + 1659 7.3.562 ":profdel" works when the +profile feature is disabled + 2742 7.3.563 (after 7.3.557) can't build with tiny features + 1785 7.3.564 (after 7.3.559) warning for pointer conversion + 1806 7.3.565 can't generate proto file for Python 3 + 2363 7.3.566 (after 7.3.561) redo works incorrectly without refresh:always + 1739 7.3.567 missing copyright notice + 3890 7.3.568 bad indents for #ifdefs +133265 7.3.569 evaluating Vim expression in Python is insufficient + 4659 7.3.570 ":vimgrep" does not obey 'wildignore' + 3915 7.3.571 duplicated condition + 1915 7.3.572 duplicate statement in if and else + 1419 7.3.573 using array index before bounds checking + 2491 7.3.574 a CTRL-L character is not pasted on the search command line + 1586 7.3.575 "ygt" tries to yank instead of giving an error + 7301 7.3.576 formatting of lists inside comments is not right yet + 6542 7.3.577 size of memory does not fit in 32 bit unsigned + 2025 7.3.578 misplaced declaration. + 7644 7.3.579 (after 7.3.569) can't compile with Python 2.5 + 1517 7.3.580 warning on 64 bit MS-Windows + 4236 7.3.581 problems compiling with Python + 1342 7.3.582 missing pieces in test OK file + 3125 7.3.583 PyObject_NextNotImplemented is not defined before Python 2.7 + 4088 7.3.584 PyCObject is not always defined + 1696 7.3.585 calling changed_bytes() too often + 3055 7.3.586 MEMORYSTATUSEX not defined when compiling with Cygwin or MingW + 2248 7.3.587 compiler warning for local var shadowing global var + 2464 7.3.588 crash on NULL pointer + 1974 7.3.589 crash when $HOME is not set + 1804 7.3.590 the '< and '> marks cannot be set directly + 5247 7.3.591 can only move to a tab by absolute number + 3343 7.3.592 Vim on GTK does not support g:browsefilter + 2237 7.3.593 no easy way to decide if b:browsefilter will work + 4873 7.3.594 the X command server sends an empty reply for as-keys requests + 3921 7.3.595 the X command server responds slowly + 4967 7.3.596 can't remove all signs for a file or buffer + 21669 7.3.597 'clipboard' "autoselect" only applies to the * register + 2635 7.3.598 cannot act upon end of insert mode completion + 3042 7.3.599 (after 7.3.597) missing change in one file + 1572 7.3.600 is not expanded properly with DBCS encoding + 1492 7.3.601 bad code style + 1532 7.3.602 missing files in distribution + 11248 7.3.603 it is possible to add or replace builtin functions + 1861 7.3.604 inputdialog() doesn't use the cancel argument in the console + 2334 7.3.605 MS-Windows: Can't compile with older compilers + 2522 7.3.606 CTRL-P completion has a problem with multi-byte characters + 2139 7.3.607 with 8 color terminal selected menu item is black on black + 3847 7.3.608 winrestview() does not always restore the view correctly + 5843 7.3.609 file names in :checkpath! output are garbled + 12106 7.3.610 cannot operate on the text that a search pattern matches + 1895 7.3.611 can't use Vim dictionary as self argument in Python + 2081 7.3.612 auto formatting messes up text when 'fo' contains "2" + 6886 7.3.613 including Python's config.c in the build causes trouble + 5747 7.3.614 number arg gets turned into number while it should be string + 2915 7.3.615 completion does not recognized escaped spaces + 1289 7.3.616 (after 7.3.610) can't compile without +visual + 1781 7.3.617 (after 7.3.615) hang on completion + 10033 7.3.618 (after 7.3.616) still doesn't compile with small features + 1583 7.3.619 when executing a shell command Vim may become slow to respond + 4897 7.3.620 building with recent Ruby on Win32 doesn't work + 2259 7.3.621 compiler warnings on 64 bit windows + 1867 7.3.622 XPM library for Win32 can't be found + 2426 7.3.623 Perl 5.14 commands crash Vim on MS-Windows + 1800 7.3.624 when cancelling input() it returns the third argument + 4327 7.3.625 "gn" does not handle zero-width matches correctly + 1500 7.3.626 Python interface doesn't build with Python 2.4 or older + 2803 7.3.627 expression not evaluated when using "n" flag with ":s" + 1802 7.3.628 ":open!" results in a confusing error message + 12019 7.3.629 there is no way to make 'shiftwidth' follow 'tabstop' + 1487 7.3.630 "|" does not behave correctly when 'virtualedit' is set + 10100 7.3.631 cannot complete user names + 14770 7.3.632 cannot select beyond 222 columns with the mouse in xterm + 2238 7.3.633 selection remains highlighted after selecting another text + 1884 7.3.634 Month/Day format for undo is confusing + 1586 7.3.635 system call during startup sets 'lines' to a wrong value + 4539 7.3.636 (after 7.3.625) "gn" fails for some zero-width matches + 3117 7.3.637 cannot catch error caused by a foldopen when there is no fold + 1783 7.3.638 unecessary redraw of the previous character diff --git a/vim.spec b/vim.spec index b3b5975c..734689a9 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 556 +%define patchlevel 638 Summary: The VIM editor URL: http://www.vim.org/ @@ -612,6 +612,88 @@ Patch553: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.553 Patch554: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.554 Patch555: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.555 Patch556: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.556 +Patch557: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.557 +Patch558: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.558 +Patch559: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.559 +Patch560: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.560 +Patch561: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.561 +Patch562: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.562 +Patch563: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.563 +Patch564: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.564 +Patch565: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.565 +Patch566: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.566 +Patch567: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.567 +Patch568: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.568 +Patch569: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.569 +Patch570: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.570 +Patch571: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.571 +Patch572: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.572 +Patch573: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.573 +Patch574: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.574 +Patch575: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.575 +Patch576: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.576 +Patch577: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.577 +Patch578: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.578 +Patch579: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.579 +Patch580: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.580 +Patch581: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.581 +Patch582: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.582 +Patch583: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.583 +Patch584: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.584 +Patch585: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.585 +Patch586: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.586 +Patch587: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.587 +Patch588: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.588 +Patch589: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.589 +Patch590: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.590 +Patch591: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.591 +Patch592: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.592 +Patch593: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.593 +Patch594: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.594 +Patch595: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.595 +Patch596: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.596 +Patch597: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.597 +Patch598: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.598 +Patch599: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.599 +Patch600: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.600 +Patch601: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.601 +Patch602: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.602 +Patch603: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.603 +Patch604: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.604 +Patch605: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.605 +Patch606: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.606 +Patch607: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.607 +Patch608: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.608 +Patch609: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.609 +Patch610: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.610 +Patch611: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.611 +Patch612: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.612 +Patch613: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.613 +Patch614: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.614 +Patch615: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.615 +Patch616: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.616 +Patch617: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.617 +Patch618: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.618 +Patch619: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.619 +Patch620: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.620 +Patch621: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.621 +Patch622: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.622 +Patch623: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.623 +Patch624: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.624 +Patch625: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.625 +Patch626: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.626 +Patch627: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.627 +Patch628: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.628 +Patch629: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.629 +Patch630: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.630 +Patch631: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.631 +Patch632: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.632 +Patch633: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.633 +Patch634: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.634 +Patch635: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.635 +Patch636: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.636 +Patch637: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.637 +Patch638: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.638 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1314,6 +1396,88 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch554 -p0 %patch555 -p0 %patch556 -p0 +%patch557 -p0 +%patch558 -p0 +%patch559 -p0 +%patch560 -p0 +%patch561 -p0 +%patch562 -p0 +%patch563 -p0 +%patch564 -p0 +%patch565 -p0 +%patch566 -p0 +%patch567 -p0 +%patch568 -p0 +%patch569 -p0 +%patch570 -p0 +%patch571 -p0 +%patch572 -p0 +%patch573 -p0 +%patch574 -p0 +%patch575 -p0 +%patch576 -p0 +%patch577 -p0 +%patch578 -p0 +%patch579 -p0 +%patch580 -p0 +%patch581 -p0 +%patch582 -p0 +%patch583 -p0 +%patch584 -p0 +%patch585 -p0 +%patch586 -p0 +%patch587 -p0 +%patch588 -p0 +%patch589 -p0 +%patch590 -p0 +%patch591 -p0 +%patch592 -p0 +%patch593 -p0 +%patch594 -p0 +%patch595 -p0 +%patch596 -p0 +%patch597 -p0 +%patch598 -p0 +%patch599 -p0 +%patch600 -p0 +%patch601 -p0 +%patch602 -p0 +%patch603 -p0 +%patch604 -p0 +%patch605 -p0 +%patch606 -p0 +%patch607 -p0 +%patch608 -p0 +%patch609 -p0 +%patch610 -p0 +%patch611 -p0 +%patch612 -p0 +%patch613 -p0 +%patch614 -p0 +%patch615 -p0 +%patch616 -p0 +%patch617 -p0 +%patch618 -p0 +%patch619 -p0 +%patch620 -p0 +%patch621 -p0 +%patch622 -p0 +%patch623 -p0 +%patch624 -p0 +%patch625 -p0 +%patch626 -p0 +%patch627 -p0 +%patch628 -p0 +%patch629 -p0 +%patch630 -p0 +%patch631 -p0 +%patch632 -p0 +%patch633 -p0 +%patch634 -p0 +%patch635 -p0 +%patch636 -p0 +%patch637 -p0 +%patch638 -p0 # install spell files @@ -1770,6 +1934,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Tue Aug 28 2012 Karsten Hopp 7.3.638-1 +- patchlevel 638 + * Mon Jun 18 2012 Karsten Hopp 7.3.556-1 - patchlevel 556 From c8d55a4ffc9503371b9738188e056eba33134f47 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 15:34:04 +0200 Subject: [PATCH 0461/3340] fix some man page typos (#668894, #675480) own usr/share/vim/vimfiles/doc/tags (#845564) add path to csope database (#844843) --- vim-7.3-manpage-typo-668894-675480.patch | 21 +++++++++++++++++++++ vim.spec | 11 ++++++++++- vimrc | 2 +- 3 files changed, 32 insertions(+), 2 deletions(-) create mode 100644 vim-7.3-manpage-typo-668894-675480.patch diff --git a/vim-7.3-manpage-typo-668894-675480.patch b/vim-7.3-manpage-typo-668894-675480.patch new file mode 100644 index 00000000..cb4ccd13 --- /dev/null +++ b/vim-7.3-manpage-typo-668894-675480.patch @@ -0,0 +1,21 @@ +diff -up vim73/runtime/doc/vim.1.668894 vim73/runtime/doc/vim.1 +--- vim73/runtime/doc/vim.1.668894 2010-05-15 13:04:00.000000000 +0200 ++++ vim73/runtime/doc/vim.1 2012-08-28 12:41:36.000000000 +0200 +@@ -73,7 +73,7 @@ To edit a file that starts with a dash, + .TP + \- + The file to edit is read from stdin. Commands are read from stderr, which +-should be a tty. ++should be a TTY. + .TP + \-t {tag} + The file to edit and the initial cursor position depends on a "tag", a sort +@@ -321,7 +321,7 @@ When N is omitted, open one tab page for + \-R + Read-only mode. + The 'readonly' option will be set. +-You can still edit the buffer, but will be prevented from accidently ++You can still edit the buffer, but will be prevented from accidentally + overwriting a file. + If you do want to overwrite a file, add an exclamation mark to the Ex command, + as in ":w!". diff --git a/vim.spec b/vim.spec index 734689a9..779849f1 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1%{?dist} +Release: 2%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -706,6 +706,7 @@ Patch3009: vim-7.0-syncolor.patch Patch3010: vim-7.0-specedit.patch Patch3011: vim72-rh514717.patch Patch3012: vim-7.3-bug816848.patch +Patch3013: vim-7.3-manpage-typo-668894-675480.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel ncurses-devel gettext perl-devel @@ -1497,6 +1498,7 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch3010 -p1 %patch3011 -p1 %patch3012 -p1 +%patch3013 -p1 %build cp -f %{SOURCE5} . @@ -1732,6 +1734,7 @@ done for i in rvim.1 gvim.1 gvimdiff.1; do echo ".so man1/vim.1" > $RPM_BUILD_ROOT/%{_mandir}/man1/$i done +touch $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/doc/tags %post X11 touch --no-create %{_datadir}/icons/hicolor @@ -1904,6 +1907,7 @@ rm -rf $RPM_BUILD_ROOT %dir %{_datadir}/%{name}/vimfiles/colors %dir %{_datadir}/%{name}/vimfiles/compiler %dir %{_datadir}/%{name}/vimfiles/doc +%ghost %{_datadir}/%{name}/vimfiles/doc/tags %dir %{_datadir}/%{name}/vimfiles/ftdetect %dir %{_datadir}/%{name}/vimfiles/ftplugin %dir %{_datadir}/%{name}/vimfiles/indent @@ -1934,6 +1938,11 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Tue Aug 28 2012 Karsten Hopp 7.3.638-2 +- fix some man page typos (#668894, #675480) +- own usr/share/vim/vimfiles/doc/tags (#845564) +- add path to csope database (#844843) + * Tue Aug 28 2012 Karsten Hopp 7.3.638-1 - patchlevel 638 diff --git a/vimrc b/vimrc index b02134df..6707ae49 100644 --- a/vimrc +++ b/vimrc @@ -36,7 +36,7 @@ if has("cscope") && filereadable("/usr/bin/cscope") set nocsverb " add any database in current directory if filereadable("cscope.out") - cs add cscope.out + cs add $PWD/cscope.out " else add database pointed to by environment elseif $CSCOPE_DB != "" cs add $CSCOPE_DB From ea9a3fafd36ff315cf259abc4c2b2891af6b437c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 15:41:54 +0200 Subject: [PATCH 0462/3340] merge --- README.patches | 3 --- 1 file changed, 3 deletions(-) diff --git a/README.patches b/README.patches index a559c7e3..dfe8b806 100644 --- a/README.patches +++ b/README.patches @@ -653,8 +653,6 @@ Individual patches for Vim 7.3: 4897 7.3.620 building with recent Ruby on Win32 doesn't work 2259 7.3.621 compiler warnings on 64 bit windows 1867 7.3.622 XPM library for Win32 can't be found -<<<<<<< HEAD -======= 2426 7.3.623 Perl 5.14 commands crash Vim on MS-Windows 1800 7.3.624 when cancelling input() it returns the third argument 4327 7.3.625 "gn" does not handle zero-width matches correctly @@ -671,4 +669,3 @@ Individual patches for Vim 7.3: 4539 7.3.636 (after 7.3.625) "gn" fails for some zero-width matches 3117 7.3.637 cannot catch error caused by a foldopen when there is no fold 1783 7.3.638 unecessary redraw of the previous character ->>>>>>> c8d55a4ffc9503371b9738188e056eba33134f47 From b1eab68a30942481addb68ff67a0053e59e99de2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 15:45:04 +0200 Subject: [PATCH 0463/3340] drop obsolete patch --- vim.spec | 1 - 1 file changed, 1 deletion(-) diff --git a/vim.spec b/vim.spec index ea4ed683..7fb28618 100644 --- a/vim.spec +++ b/vim.spec @@ -1490,7 +1490,6 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch3002 -p1 %patch3003 -p1 %patch3004 -p1 -%patch3005 -p1 %patch3006 -p1 %patch3007 -p1 %patch3008 -p1 From 517e7e4e7369de56a2c72afd605f59dbadc24384 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 28 Aug 2012 15:58:20 +0200 Subject: [PATCH 0464/3340] cleanup patches --- vim.spec | 2 -- 1 file changed, 2 deletions(-) diff --git a/vim.spec b/vim.spec index 7fb28618..527c445e 100644 --- a/vim.spec +++ b/vim.spec @@ -697,7 +697,6 @@ Patch638: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.638 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch -Patch3003: vim-6.1-rh3.patch Patch3004: vim-7.0-rclocation.patch Patch3006: vim-6.4-checkhl.patch Patch3007: vim-7.3-fstabsyntax.patch @@ -1488,7 +1487,6 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch3000 -p1 %patch3002 -p1 -%patch3003 -p1 %patch3004 -p1 %patch3006 -p1 %patch3007 -p1 From 4f5437d4db243474369fd3ce59fce0a0d8b2ab3f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 3 Sep 2012 12:44:22 +0200 Subject: [PATCH 0465/3340] - patchlevel 639 --- 7.3.639 | 846 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 846 insertions(+) create mode 100644 7.3.639 diff --git a/7.3.639 b/7.3.639 new file mode 100644 index 00000000..359dc6d8 --- /dev/null +++ b/7.3.639 @@ -0,0 +1,846 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.639 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.639 +Problem: It's not easy to build Vim on Windows with XPM support. +Solution: Include the required files, they are quite small. Update the + MSVC makefile to use them. Binary files are in the next patch. + (Sergey Khorev) +Files: src/xpm/COPYRIGHT, src/xpm/README.txt, src/xpm/include/simx.h, + src/xpm/include/xpm.h, src/Make_mvc.mak, src/bigvim.bat, + src/bigvim64.bat, Filelist + + +*** ../vim-7.3.638/src/xpm/COPYRIGHT 1970-01-01 01:00:00.000000000 +0100 +--- src/xpm/COPYRIGHT 1998-03-19 23:51:00.000000000 +0100 +*************** +*** 0 **** +--- 1,31 ---- ++ /* ++ * Copyright (C) 1989-95 GROUPE BULL ++ * ++ * Permission is hereby granted, free of charge, to any person obtaining a copy ++ * of this software and associated documentation files (the "Software"), to ++ * deal in the Software without restriction, including without limitation the ++ * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or ++ * sell copies of the Software, and to permit persons to whom the Software is ++ * furnished to do so, subject to the following conditions: ++ * ++ * The above copyright notice and this permission notice shall be included in ++ * all copies or substantial portions of the Software. ++ * ++ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR ++ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, ++ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL ++ * GROUPE BULL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN ++ * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN ++ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ++ * ++ * Except as contained in this notice, the name of GROUPE BULL shall not be ++ * used in advertising or otherwise to promote the sale, use or other dealings ++ * in this Software without prior written authorization from GROUPE BULL. ++ */ ++ ++ Arnaud LE HORS BULL Research FRANCE -- Koala Project ++ (XPM - X PixMap format version 2 & 3) ++ Internet: lehors@sophia.inria.fr ++ Surface Mail: Arnaud LE HORS, INRIA - Sophia Antipolis, ++ 2004, route des Lucioles, 06565 Valbonne Cedex -- FRANCE ++ Voice phone: (33) 93.65.77.71, Fax: (33) 93 65 77 66, Telex: 97 00 50 F +*** ../vim-7.3.638/src/xpm/README.txt 1970-01-01 01:00:00.000000000 +0100 +--- src/xpm/README.txt 2012-08-29 13:29:17.000000000 +0200 +*************** +*** 0 **** +--- 1,23 ---- ++ This is XPM library compiled for Windows which is intended for use with Vim ++ 'signs' feature. ++ ++ Libraries in x86 directory were compiled with MSVC6 and MinGW. Proposed ++ commands to compile Vim are: ++ ++ Any version of MSVC starting from version 6.0: ++ nmake -f Make_mvc.mak GUI=yes CSCOPE=yes NETBEANS=yes XPM=e:\hg\xpm\x86 ++ ++ MinGW: ++ mingw32-make -f Make_ming.mak GUI=yes CSCOPE=yes XPM=e:/hg/xpm/x86 ++ ++ Microsoft Visual C++ on x64 (tested with versions 2008 and 2010): ++ nmake -f Make_mvc.mak GUI=yes CSCOPE=yes XPM=E:\HG\xpm\x64 ++ ++ To test, open some file in Vim and execute commands below: ++ :exe 'sign define vimxpm icon='.$VIMRUNTIME.'\\vim32x32.xpm' ++ :exe 'sign place 1 line=1 name=vimxpm file='.expand('%:p') ++ ++ ++ See COPYRIGHT for XPM licence. ++ ++ If you have questions please email sergey.khorev@gmail.com. +*** ../vim-7.3.638/src/xpm/include/simx.h 1970-01-01 01:00:00.000000000 +0100 +--- src/xpm/include/simx.h 1998-03-19 23:51:00.000000000 +0100 +*************** +*** 0 **** +--- 1,139 ---- ++ /* ++ * Copyright (C) 1989-95 GROUPE BULL ++ * ++ * Permission is hereby granted, free of charge, to any person obtaining a copy ++ * of this software and associated documentation files (the "Software"), to ++ * deal in the Software without restriction, including without limitation the ++ * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or ++ * sell copies of the Software, and to permit persons to whom the Software is ++ * furnished to do so, subject to the following conditions: ++ * ++ * The above copyright notice and this permission notice shall be included in ++ * all copies or substantial portions of the Software. ++ * ++ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR ++ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, ++ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL ++ * GROUPE BULL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN ++ * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN ++ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ++ * ++ * Except as contained in this notice, the name of GROUPE BULL shall not be ++ * used in advertising or otherwise to promote the sale, use or other dealings ++ * in this Software without prior written authorization from GROUPE BULL. ++ */ ++ ++ /*****************************************************************************\ ++ * simx.h: 0.1a * ++ * * ++ * This emulates some Xlib functionality for MSW. It's not a general solution, * ++ * it is close related to XPM-lib. It is only intended to satisfy what is need * ++ * there. Thus allowing to read XPM files under MS windows. * ++ * * ++ * Developed by HeDu 3/94 (hedu@cul-ipn.uni-kiel.de) * ++ \*****************************************************************************/ ++ ++ ++ #ifndef _SIMX_H ++ #define _SIMX_H ++ ++ #ifdef FOR_MSW ++ ++ #include "windows.h" /* MS windows GDI types */ ++ ++ /* ++ * minimal portability layer between ansi and KR C ++ */ ++ /* this comes from xpm.h, and is here again, to avoid complicated ++ includes, since this is included from xpm.h */ ++ /* these defines get undefed at the end of this file */ ++ #if __STDC__ || defined(__cplusplus) || defined(c_plusplus) ++ /* ANSI || C++ */ ++ #define FUNC(f, t, p) extern t f p ++ #define LFUNC(f, t, p) static t f p ++ #else /* k&R */ ++ #define FUNC(f, t, p) extern t f() ++ #define LFUNC(f, t, p) static t f() ++ #endif ++ ++ ++ FUNC(boundCheckingMalloc, void *, (long s)); ++ FUNC(boundCheckingCalloc, void *, (long num, long s)); ++ FUNC(boundCheckingRealloc, void *, (void *p, long s)); ++ ++ /* define MSW types for X window types, ++ I don't know much about MSW, but the following defines do the job */ ++ ++ typedef HDC Display; /* this should be similar */ ++ typedef void *Screen; /* not used */ ++ typedef void *Visual; /* not used yet, is for GRAY, COLOR, ++ * MONO */ ++ ++ typedef void *Colormap; /* should be COLORPALETTE, not done ++ * yet */ ++ ++ typedef COLORREF Pixel; ++ ++ #define PIXEL_ALREADY_TYPEDEFED /* to let xpm.h know about it */ ++ ++ typedef struct { ++ Pixel pixel; ++ BYTE red, green, blue; ++ } XColor; ++ ++ typedef struct { ++ HBITMAP bitmap; ++ unsigned int width; ++ unsigned int height; ++ unsigned int depth; ++ } XImage; ++ ++ #if defined(__cplusplus) || defined(c_plusplus) ++ extern "C" { ++ #endif ++ /* some replacements for X... functions */ ++ ++ /* XDefaultXXX */ ++ FUNC(XDefaultVisual, Visual *, (Display *display, Screen *screen)); ++ FUNC(XDefaultScreen, Screen *, (Display *d)); ++ FUNC(XDefaultColormap, Colormap *, (Display *display, Screen *screen)); ++ FUNC(XDefaultDepth, int, (Display *d, Screen *s)); ++ ++ /* color related */ ++ FUNC(XParseColor, int, (Display *, Colormap *, char *, XColor *)); ++ FUNC(XAllocColor, int, (Display *, Colormap *, XColor *)); ++ FUNC(XQueryColors, void, (Display *display, Colormap *colormap, ++ XColor *xcolors, int ncolors)); ++ FUNC(XFreeColors, int, (Display *d, Colormap cmap, ++ unsigned long pixels[], ++ int npixels, unsigned long planes)); ++ /* XImage */ ++ FUNC(XCreateImage, XImage *, (Display *, Visual *, int depth, int format, ++ int x, int y, int width, int height, ++ int pad, int foo)); ++ ++ /* free and destroy bitmap */ ++ FUNC(XDestroyImage, void /* ? */ , (XImage *)); ++ /* free only, bitmap remains */ ++ FUNC(XImageFree, void, (XImage *)); ++ #if defined(__cplusplus) || defined(c_plusplus) ++ } /* end of extern "C" */ ++ #endif /* cplusplus */ ++ ++ #define ZPixmap 1 /* not really used */ ++ #define XYBitmap 1 /* not really used */ ++ ++ #ifndef True ++ #define True 1 ++ #define False 0 ++ #endif ++ #ifndef Bool ++ typedef BOOL Bool; /* take MSW bool */ ++ #endif ++ /* make these local here, simx.c gets the same from xpm.h */ ++ #undef LFUNC ++ #undef FUNC ++ ++ #endif /* def FOR_MSW */ ++ ++ #endif /* _SIMX_H */ +*** ../vim-7.3.638/src/xpm/include/xpm.h 1970-01-01 01:00:00.000000000 +0100 +--- src/xpm/include/xpm.h 1998-03-19 23:51:00.000000000 +0100 +*************** +*** 0 **** +--- 1,501 ---- ++ /* ++ * Copyright (C) 1989-95 GROUPE BULL ++ * ++ * Permission is hereby granted, free of charge, to any person obtaining a copy ++ * of this software and associated documentation files (the "Software"), to ++ * deal in the Software without restriction, including without limitation the ++ * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or ++ * sell copies of the Software, and to permit persons to whom the Software is ++ * furnished to do so, subject to the following conditions: ++ * ++ * The above copyright notice and this permission notice shall be included in ++ * all copies or substantial portions of the Software. ++ * ++ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR ++ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, ++ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL ++ * GROUPE BULL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN ++ * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN ++ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ++ * ++ * Except as contained in this notice, the name of GROUPE BULL shall not be ++ * used in advertising or otherwise to promote the sale, use or other dealings ++ * in this Software without prior written authorization from GROUPE BULL. ++ */ ++ ++ /*****************************************************************************\ ++ * xpm.h: * ++ * * ++ * XPM library * ++ * Include file * ++ * * ++ * Developed by Arnaud Le Hors * ++ \*****************************************************************************/ ++ ++ /* ++ * The code related to FOR_MSW has been added by ++ * HeDu (hedu@cul-ipn.uni-kiel.de) 4/94 ++ */ ++ ++ /* ++ * The code related to AMIGA has been added by ++ * Lorens Younes (d93-hyo@nada.kth.se) 4/96 ++ */ ++ ++ #ifndef XPM_h ++ #define XPM_h ++ ++ /* ++ * first some identification numbers: ++ * the version and revision numbers are determined with the following rule: ++ * SO Major number = LIB minor version number. ++ * SO Minor number = LIB sub-minor version number. ++ * e.g: Xpm version 3.2f ++ * we forget the 3 which is the format number, 2 gives 2, and f gives 6. ++ * thus we have XpmVersion = 2 and XpmRevision = 6 ++ * which gives SOXPMLIBREV = 2.6 ++ * ++ * Then the XpmIncludeVersion number is built from these numbers. ++ */ ++ #define XpmFormat 3 ++ #define XpmVersion 4 ++ #define XpmRevision 11 ++ #define XpmIncludeVersion ((XpmFormat * 100 + XpmVersion) * 100 + XpmRevision) ++ ++ #ifndef XPM_NUMBERS ++ ++ #ifdef FOR_MSW ++ # define SYSV /* uses memcpy string.h etc. */ ++ # include ++ # include "simx.h" /* defines some X stuff using MSW types */ ++ #define NEED_STRCASECMP /* at least for MSVC++ */ ++ #else /* FOR_MSW */ ++ # ifdef AMIGA ++ # include "amigax.h" ++ # else /* not AMIGA */ ++ # include ++ # include ++ # endif /* not AMIGA */ ++ #endif /* FOR_MSW */ ++ ++ /* let's define Pixel if it is not done yet */ ++ #if ! defined(_XtIntrinsic_h) && ! defined(PIXEL_ALREADY_TYPEDEFED) ++ typedef unsigned long Pixel; /* Index into colormap */ ++ # define PIXEL_ALREADY_TYPEDEFED ++ #endif ++ ++ /* make sure we know whether function prototypes are needed or not */ ++ #ifndef NeedFunctionPrototypes ++ # if defined(__STDC__) || defined(__cplusplus) || defined(c_plusplus) ++ # define NeedFunctionPrototypes 1 ++ # else ++ # define NeedFunctionPrototypes 0 ++ # endif ++ #endif ++ ++ ++ /* Return ErrorStatus codes: ++ * null if full success ++ * positive if partial success ++ * negative if failure ++ */ ++ ++ #define XpmColorError 1 ++ #define XpmSuccess 0 ++ #define XpmOpenFailed -1 ++ #define XpmFileInvalid -2 ++ #define XpmNoMemory -3 ++ #define XpmColorFailed -4 ++ ++ typedef struct { ++ char *name; /* Symbolic color name */ ++ char *value; /* Color value */ ++ Pixel pixel; /* Color pixel */ ++ } XpmColorSymbol; ++ ++ typedef struct { ++ char *name; /* name of the extension */ ++ unsigned int nlines; /* number of lines in this extension */ ++ char **lines; /* pointer to the extension array of strings */ ++ } XpmExtension; ++ ++ typedef struct { ++ char *string; /* characters string */ ++ char *symbolic; /* symbolic name */ ++ char *m_color; /* monochrom default */ ++ char *g4_color; /* 4 level grayscale default */ ++ char *g_color; /* other level grayscale default */ ++ char *c_color; /* color default */ ++ } XpmColor; ++ ++ typedef struct { ++ unsigned int width; /* image width */ ++ unsigned int height; /* image height */ ++ unsigned int cpp; /* number of characters per pixel */ ++ unsigned int ncolors; /* number of colors */ ++ XpmColor *colorTable; /* list of related colors */ ++ unsigned int *data; /* image data */ ++ } XpmImage; ++ ++ typedef struct { ++ unsigned long valuemask; /* Specifies which attributes are defined */ ++ char *hints_cmt; /* Comment of the hints section */ ++ char *colors_cmt; /* Comment of the colors section */ ++ char *pixels_cmt; /* Comment of the pixels section */ ++ unsigned int x_hotspot; /* Returns the x hotspot's coordinate */ ++ unsigned int y_hotspot; /* Returns the y hotspot's coordinate */ ++ unsigned int nextensions; /* number of extensions */ ++ XpmExtension *extensions; /* pointer to array of extensions */ ++ } XpmInfo; ++ ++ typedef int (*XpmAllocColorFunc)( ++ #if NeedFunctionPrototypes ++ Display* /* display */, ++ Colormap /* colormap */, ++ char* /* colorname */, ++ XColor* /* xcolor */, ++ void* /* closure */ ++ #endif ++ ); ++ ++ typedef int (*XpmFreeColorsFunc)( ++ #if NeedFunctionPrototypes ++ Display* /* display */, ++ Colormap /* colormap */, ++ Pixel* /* pixels */, ++ int /* npixels */, ++ void* /* closure */ ++ #endif ++ ); ++ ++ typedef struct { ++ unsigned long valuemask; /* Specifies which attributes are ++ defined */ ++ ++ Visual *visual; /* Specifies the visual to use */ ++ Colormap colormap; /* Specifies the colormap to use */ ++ unsigned int depth; /* Specifies the depth */ ++ unsigned int width; /* Returns the width of the created ++ pixmap */ ++ unsigned int height; /* Returns the height of the created ++ pixmap */ ++ unsigned int x_hotspot; /* Returns the x hotspot's ++ coordinate */ ++ unsigned int y_hotspot; /* Returns the y hotspot's ++ coordinate */ ++ unsigned int cpp; /* Specifies the number of char per ++ pixel */ ++ Pixel *pixels; /* List of used color pixels */ ++ unsigned int npixels; /* Number of used pixels */ ++ XpmColorSymbol *colorsymbols; /* List of color symbols to override */ ++ unsigned int numsymbols; /* Number of symbols */ ++ char *rgb_fname; /* RGB text file name */ ++ unsigned int nextensions; /* Number of extensions */ ++ XpmExtension *extensions; /* List of extensions */ ++ ++ unsigned int ncolors; /* Number of colors */ ++ XpmColor *colorTable; /* List of colors */ ++ /* 3.2 backward compatibility code */ ++ char *hints_cmt; /* Comment of the hints section */ ++ char *colors_cmt; /* Comment of the colors section */ ++ char *pixels_cmt; /* Comment of the pixels section */ ++ /* end 3.2 bc */ ++ unsigned int mask_pixel; /* Color table index of transparent ++ color */ ++ ++ /* Color Allocation Directives */ ++ Bool exactColors; /* Only use exact colors for visual */ ++ unsigned int closeness; /* Allowable RGB deviation */ ++ unsigned int red_closeness; /* Allowable red deviation */ ++ unsigned int green_closeness; /* Allowable green deviation */ ++ unsigned int blue_closeness; /* Allowable blue deviation */ ++ int color_key; /* Use colors from this color set */ ++ ++ Pixel *alloc_pixels; /* Returns the list of alloc'ed color ++ pixels */ ++ int nalloc_pixels; /* Returns the number of alloc'ed ++ color pixels */ ++ ++ Bool alloc_close_colors; /* Specify whether close colors should ++ be allocated using XAllocColor ++ or not */ ++ int bitmap_format; /* Specify the format of 1bit depth ++ images: ZPixmap or XYBitmap */ ++ ++ /* Color functions */ ++ XpmAllocColorFunc alloc_color; /* Application color allocator */ ++ XpmFreeColorsFunc free_colors; /* Application color de-allocator */ ++ void *color_closure; /* Application private data to pass to ++ alloc_color and free_colors */ ++ ++ } XpmAttributes; ++ ++ /* XpmAttributes value masks bits */ ++ #define XpmVisual (1L<<0) ++ #define XpmColormap (1L<<1) ++ #define XpmDepth (1L<<2) ++ #define XpmSize (1L<<3) /* width & height */ ++ #define XpmHotspot (1L<<4) /* x_hotspot & y_hotspot */ ++ #define XpmCharsPerPixel (1L<<5) ++ #define XpmColorSymbols (1L<<6) ++ #define XpmRgbFilename (1L<<7) ++ /* 3.2 backward compatibility code */ ++ #define XpmInfos (1L<<8) ++ #define XpmReturnInfos XpmInfos ++ /* end 3.2 bc */ ++ #define XpmReturnPixels (1L<<9) ++ #define XpmExtensions (1L<<10) ++ #define XpmReturnExtensions XpmExtensions ++ ++ #define XpmExactColors (1L<<11) ++ #define XpmCloseness (1L<<12) ++ #define XpmRGBCloseness (1L<<13) ++ #define XpmColorKey (1L<<14) ++ ++ #define XpmColorTable (1L<<15) ++ #define XpmReturnColorTable XpmColorTable ++ ++ #define XpmReturnAllocPixels (1L<<16) ++ #define XpmAllocCloseColors (1L<<17) ++ #define XpmBitmapFormat (1L<<18) ++ ++ #define XpmAllocColor (1L<<19) ++ #define XpmFreeColors (1L<<20) ++ #define XpmColorClosure (1L<<21) ++ ++ ++ /* XpmInfo value masks bits */ ++ #define XpmComments XpmInfos ++ #define XpmReturnComments XpmComments ++ ++ /* XpmAttributes mask_pixel value when there is no mask */ ++ #ifndef FOR_MSW ++ #define XpmUndefPixel 0x80000000 ++ #else ++ /* int is only 16 bit for MSW */ ++ #define XpmUndefPixel 0x8000 ++ #endif ++ ++ /* ++ * color keys for visual type, they must fit along with the number key of ++ * each related element in xpmColorKeys[] defined in XpmI.h ++ */ ++ #define XPM_MONO 2 ++ #define XPM_GREY4 3 ++ #define XPM_GRAY4 3 ++ #define XPM_GREY 4 ++ #define XPM_GRAY 4 ++ #define XPM_COLOR 5 ++ ++ ++ /* macros for forward declarations of functions with prototypes */ ++ #if NeedFunctionPrototypes ++ #define FUNC(f, t, p) extern t f p ++ #define LFUNC(f, t, p) static t f p ++ #else ++ #define FUNC(f, t, p) extern t f() ++ #define LFUNC(f, t, p) static t f() ++ #endif ++ ++ ++ /* ++ * functions declarations ++ */ ++ ++ #ifdef __cplusplus ++ extern "C" { ++ #endif ++ ++ /* FOR_MSW, all ..Pixmap.. are excluded, only the ..XImage.. are used */ ++ /* Same for Amiga! */ ++ ++ #if !defined(FOR_MSW) && !defined(AMIGA) ++ FUNC(XpmCreatePixmapFromData, int, (Display *display, ++ Drawable d, ++ char **data, ++ Pixmap *pixmap_return, ++ Pixmap *shapemask_return, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmCreateDataFromPixmap, int, (Display *display, ++ char ***data_return, ++ Pixmap pixmap, ++ Pixmap shapemask, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmReadFileToPixmap, int, (Display *display, ++ Drawable d, ++ char *filename, ++ Pixmap *pixmap_return, ++ Pixmap *shapemask_return, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmWriteFileFromPixmap, int, (Display *display, ++ char *filename, ++ Pixmap pixmap, ++ Pixmap shapemask, ++ XpmAttributes *attributes)); ++ #endif ++ ++ FUNC(XpmCreateImageFromData, int, (Display *display, ++ char **data, ++ XImage **image_return, ++ XImage **shapemask_return, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmCreateDataFromImage, int, (Display *display, ++ char ***data_return, ++ XImage *image, ++ XImage *shapeimage, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmReadFileToImage, int, (Display *display, ++ char *filename, ++ XImage **image_return, ++ XImage **shapeimage_return, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmWriteFileFromImage, int, (Display *display, ++ char *filename, ++ XImage *image, ++ XImage *shapeimage, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmCreateImageFromBuffer, int, (Display *display, ++ char *buffer, ++ XImage **image_return, ++ XImage **shapemask_return, ++ XpmAttributes *attributes)); ++ #if !defined(FOR_MSW) && !defined(AMIGA) ++ FUNC(XpmCreatePixmapFromBuffer, int, (Display *display, ++ Drawable d, ++ char *buffer, ++ Pixmap *pixmap_return, ++ Pixmap *shapemask_return, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmCreateBufferFromImage, int, (Display *display, ++ char **buffer_return, ++ XImage *image, ++ XImage *shapeimage, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmCreateBufferFromPixmap, int, (Display *display, ++ char **buffer_return, ++ Pixmap pixmap, ++ Pixmap shapemask, ++ XpmAttributes *attributes)); ++ #endif ++ FUNC(XpmReadFileToBuffer, int, (char *filename, char **buffer_return)); ++ FUNC(XpmWriteFileFromBuffer, int, (char *filename, char *buffer)); ++ ++ FUNC(XpmReadFileToData, int, (char *filename, char ***data_return)); ++ FUNC(XpmWriteFileFromData, int, (char *filename, char **data)); ++ ++ FUNC(XpmAttributesSize, int, ()); ++ FUNC(XpmFreeAttributes, void, (XpmAttributes *attributes)); ++ FUNC(XpmFreeExtensions, void, (XpmExtension *extensions, ++ int nextensions)); ++ ++ FUNC(XpmFreeXpmImage, void, (XpmImage *image)); ++ FUNC(XpmFreeXpmInfo, void, (XpmInfo *info)); ++ FUNC(XpmGetErrorString, char *, (int errcode)); ++ FUNC(XpmLibraryVersion, int, ()); ++ ++ /* XpmImage functions */ ++ FUNC(XpmReadFileToXpmImage, int, (char *filename, ++ XpmImage *image, ++ XpmInfo *info)); ++ ++ FUNC(XpmWriteFileFromXpmImage, int, (char *filename, ++ XpmImage *image, ++ XpmInfo *info)); ++ #if !defined(FOR_MSW) && !defined(AMIGA) ++ FUNC(XpmCreatePixmapFromXpmImage, int, (Display *display, ++ Drawable d, ++ XpmImage *image, ++ Pixmap *pixmap_return, ++ Pixmap *shapemask_return, ++ XpmAttributes *attributes)); ++ #endif ++ FUNC(XpmCreateImageFromXpmImage, int, (Display *display, ++ XpmImage *image, ++ XImage **image_return, ++ XImage **shapeimage_return, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmCreateXpmImageFromImage, int, (Display *display, ++ XImage *image, ++ XImage *shapeimage, ++ XpmImage *xpmimage, ++ XpmAttributes *attributes)); ++ #if !defined(FOR_MSW) && !defined(AMIGA) ++ FUNC(XpmCreateXpmImageFromPixmap, int, (Display *display, ++ Pixmap pixmap, ++ Pixmap shapemask, ++ XpmImage *xpmimage, ++ XpmAttributes *attributes)); ++ #endif ++ FUNC(XpmCreateDataFromXpmImage, int, (char ***data_return, ++ XpmImage *image, ++ XpmInfo *info)); ++ ++ FUNC(XpmCreateXpmImageFromData, int, (char **data, ++ XpmImage *image, ++ XpmInfo *info)); ++ ++ FUNC(XpmCreateXpmImageFromBuffer, int, (char *buffer, ++ XpmImage *image, ++ XpmInfo *info)); ++ ++ FUNC(XpmCreateBufferFromXpmImage, int, (char **buffer_return, ++ XpmImage *image, ++ XpmInfo *info)); ++ ++ FUNC(XpmGetParseError, int, (char *filename, ++ int *linenum_return, ++ int *charnum_return)); ++ ++ FUNC(XpmFree, void, (void *ptr)); ++ ++ #ifdef __cplusplus ++ } /* for C++ V2.0 */ ++ #endif ++ ++ ++ /* backward compatibility */ ++ ++ /* for version 3.0c */ ++ #define XpmPixmapColorError XpmColorError ++ #define XpmPixmapSuccess XpmSuccess ++ #define XpmPixmapOpenFailed XpmOpenFailed ++ #define XpmPixmapFileInvalid XpmFileInvalid ++ #define XpmPixmapNoMemory XpmNoMemory ++ #define XpmPixmapColorFailed XpmColorFailed ++ ++ #define XpmReadPixmapFile(dpy, d, file, pix, mask, att) \ ++ XpmReadFileToPixmap(dpy, d, file, pix, mask, att) ++ #define XpmWritePixmapFile(dpy, file, pix, mask, att) \ ++ XpmWriteFileFromPixmap(dpy, file, pix, mask, att) ++ ++ /* for version 3.0b */ ++ #define PixmapColorError XpmColorError ++ #define PixmapSuccess XpmSuccess ++ #define PixmapOpenFailed XpmOpenFailed ++ #define PixmapFileInvalid XpmFileInvalid ++ #define PixmapNoMemory XpmNoMemory ++ #define PixmapColorFailed XpmColorFailed ++ ++ #define ColorSymbol XpmColorSymbol ++ ++ #define XReadPixmapFile(dpy, d, file, pix, mask, att) \ ++ XpmReadFileToPixmap(dpy, d, file, pix, mask, att) ++ #define XWritePixmapFile(dpy, file, pix, mask, att) \ ++ XpmWriteFileFromPixmap(dpy, file, pix, mask, att) ++ #define XCreatePixmapFromData(dpy, d, data, pix, mask, att) \ ++ XpmCreatePixmapFromData(dpy, d, data, pix, mask, att) ++ #define XCreateDataFromPixmap(dpy, data, pix, mask, att) \ ++ XpmCreateDataFromPixmap(dpy, data, pix, mask, att) ++ ++ #endif /* XPM_NUMBERS */ ++ #endif +*** ../vim-7.3.638/src/Make_mvc.mak 2012-08-02 21:48:20.000000000 +0200 +--- src/Make_mvc.mak 2012-08-29 13:46:05.000000000 +0200 +*************** +*** 89,94 **** +--- 89,96 ---- + # Netbeans Support: NETBEANS=[yes or no] (default is yes if GUI is yes) + # + # XPM Image Support: XPM=[path to XPM directory] ++ # Default is "xpm", using the files included in the distribution. ++ # Use "no" to disable this feature. + # + # Optimization: OPTIMIZE=[SPACE, SPEED, MAXSPEED] (default is MAXSPEED) + # +*************** +*** 279,295 **** + NETBEANS_LIB = WSock32.lib + !endif + +! !ifdef XPM + # XPM - Include support for XPM signs +! # You need to download or build xpm.lib somehow. +! # You can get the most recent version of libXpm-*.zip from +! # http://cgit.freedesktop.org/xorg/lib/libXpm +! # from which you must build xpm.lib yourself +! # OR get and unpack: ftp://ftp.vim.org/pub/vim/pcextra/xpm.zip + XPM_OBJ = $(OBJDIR)/xpm_w32.obj + XPM_DEFS = -DFEAT_XPM_W32 + XPM_LIB = $(XPM)\lib\libXpm.lib +! XPM_INC = -I $(XPM)\include + !endif + !endif + +--- 281,301 ---- + NETBEANS_LIB = WSock32.lib + !endif + +! !ifndef XPM +! # XPM is not set, use the included xpm files, depending on the architecture. +! !if ("$(CPU)" == "AMD64") || ("$(CPU)" == "IA64") +! XPM = xpm\x64 +! !else +! XPM = xpm\x86 +! !endif +! !endif +! !if "$(XPM)" != "no" + # XPM - Include support for XPM signs +! # See the xpm directory for more information. + XPM_OBJ = $(OBJDIR)/xpm_w32.obj + XPM_DEFS = -DFEAT_XPM_W32 + XPM_LIB = $(XPM)\lib\libXpm.lib +! XPM_INC = -I $(XPM)\include -I $(XPM)\..\include + !endif + !endif + +*** ../vim-7.3.638/src/bigvim.bat 2010-08-15 21:57:29.000000000 +0200 +--- src/bigvim.bat 2012-08-29 13:46:18.000000000 +0200 +*************** +*** 1,3 **** + :: command to build big Vim with OLE, Perl, Python, Ruby and Tcl +! nmake -f Make_mvc.mak GUI=yes OLE=yes PERL=E:\perl512 DYNAMIC_PERL=yes PERL_VER=512 PYTHON=e:\python27 DYNAMIC_PYTHON=yes PYTHON_VER=27 PYTHON3=e:\python31 DYNAMIC_PYTHON3=yes PYTHON3_VER=31 RUBY=e:\ruby191 DYNAMIC_RUBY=yes RUBY_VER=191 RUBY_VER_LONG=1.9.1 TCL=e:\tcl DYNAMIC_TCL=yes %1 IME=yes CSCOPE=yes XPM=e:\xpm + +--- 1,5 ---- + :: command to build big Vim with OLE, Perl, Python, Ruby and Tcl +! SET VCDIR="C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\bin\" +! SET TOOLDIR=E:\ +! %VCDIR%nmake -f Make_mvc.mak GUI=yes OLE=yes PERL=E:\perl514 DYNAMIC_PERL=yes PERL_VER=514 PYTHON=%TOOLDIR%python27 DYNAMIC_PYTHON=yes PYTHON_VER=27 PYTHON3=%TOOLDIR%python32 DYNAMIC_PYTHON3=yes PYTHON3_VER=32 RUBY=%TOOLDIR%ruby192 DYNAMIC_RUBY=yes RUBY_VER=192 RUBY_VER_LONG=1.9.2 TCL=%TOOLDIR%tcl TCL_VER=85 TCL_VER_LONG=8.5 DYNAMIC_TCL=yes %1 IME=yes CSCOPE=yes + +*** ../vim-7.3.638/src/bigvim64.bat 2012-08-29 14:16:38.000000000 +0200 +--- src/bigvim64.bat 2012-08-29 13:46:35.000000000 +0200 +*************** +*** 0 **** +--- 1,6 ---- ++ :: command to build big Vim 64 bit with OLE, Perl, Python, Ruby and Tcl ++ :: First run: %VCDIR%\vcvarsall.bat x86_amd64 ++ SET VCDIR="C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\" ++ SET TOOLDIR=E:\ ++ %VCDIR%\bin\nmake -f Make_mvc.mak CPU=AMD64 GUI=yes OLE=yes PERL=E:\perl514 DYNAMIC_PERL=yes PERL_VER=514 PYTHON=%TOOLDIR%python27 DYNAMIC_PYTHON=yes PYTHON_VER=27 PYTHON3=%TOOLDIR%python32 DYNAMIC_PYTHON3=yes PYTHON3_VER=32 RUBY=%TOOLDIR%ruby192 DYNAMIC_RUBY=yes RUBY_VER=192 RUBY_VER_LONG=1.9.2 TCL=%TOOLDIR%tcl TCL_VER=85 TCL_VER_LONG=8.5 DYNAMIC_TCL=yes %1 IME=yes CSCOPE=yes ++ +*** ../vim-7.3.638/Filelist 2012-07-16 17:27:57.000000000 +0200 +--- Filelist 2012-08-29 13:53:52.000000000 +0200 +*************** +*** 349,354 **** +--- 349,360 ---- + src/vim*.ico \ + src/vim.tlb \ + src/vimtbar.lib \ ++ src/xpm/COPYRIGHT \ ++ src/xpm/README.txt \ ++ src/xpm/include/*.h \ ++ src/xpm/x64/lib/libXpm.lib \ ++ src/xpm/x86/lib/libXpm.a \ ++ src/xpm/x86/lib/libXpm.lib \ + src/vimtbar.dll \ + nsis/icons/*.bmp \ + nsis/icons/*.ico \ +*** ../vim-7.3.638/src/version.c 2012-08-29 14:17:51.000000000 +0200 +--- src/version.c 2012-08-29 14:14:19.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 639, + /**/ + +-- +A successful man is one who makes more money than his wife can spend. +A successful woman is one who can find such a man. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 520ee8d5cb7725314a2509f1f9540f063e6d9827 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 3 Sep 2012 12:44:23 +0200 Subject: [PATCH 0466/3340] - patchlevel 640 --- 7.3.640 | Bin 0 -> 455297 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 7.3.640 diff --git a/7.3.640 b/7.3.640 new file mode 100644 index 0000000000000000000000000000000000000000..984df6400779e68332e9e016d04f19445b940e0b GIT binary patch literal 455297 zcmeEvi+2=7_J2)gfB(W(>m%0&JCt@|e{8mgr=}+-tF`)?C0nXv({*0$WHLQE zQLgPz?i?MfOeJ?#Yob?r2i7E4ZK>3DRrV+IyQ{Uzo?kA>0A%B06g*WMeqi6^_yha; z`yLn@-GTqxCdb!|jqbS5PutKROe^2FB#atP9vj`UWXY0ZX{)g@xpjACs*)_%D#;yz z%H5Z&?;f2>j+giIChx7*p5pbb?5WiD@2HOK2f*}H(poY(T~F3`SH_d06UlONsxn!w zmFtz{BnExWk|j&-z4zYanl%sX86Cf$lR)pl1MM5MxMyH}_x;^H_jmUsyL&cvcW>&M0dFO-W+VJj&maI-bfYAtqp5DH70~Thr+2J4g`_Wnwi~jtJ7a)GWdXU7zKOLRv|IGhQ z>@*QSnMuO`J5LbrKRw0{kXFB6Vb$yi|6#At1LTswgM&kwGSuBuEM+WJ)6>e{!IY{h zM8>bx^IG1rin=nG(lS%wG*i=aj#bPlgMGgZrSzs9-Abz&3s~A<_h5fGIh!uohHff@ zeY<`iPRV6-$IfSR%3#VY4yJTFidrhAjZ!Wvb8f0rpQRN_j#|pg`bLZHPiLKCNjFN0 zNYXT!2Oa|L?zarPl+70`WpKTKSl3)wf39d1bC#}%#1Z#TFr)Q)Ni%XKEvF3j45qZa zTU>syC(^X_1*cHbONONkuG{7mjBQ&(8KqUl)Url4Thf)`>iA@>GBt$)^%5_(O*=GA z$*LKrpk@kg1&}#M;Z>Nbm+Pa$gX^#jkg;w{GxlIAQ^c#ze@)vX3tK7bRwk|GRAqF$ zysI)aQ68^^s#{bXyJY5yrIMh5l;-yjFQ8>_m6Wt*7)3o>@Ww}WgXl=A!!R7*cFAFVgirqHZ zCP6RP%kDJl(d@id$mKOoDgip{$(GEFW0msCc&Ph&az-wnR}LUV=6;@?>aPDsSQnz?yHQ6a`sJ*YsfcW**}FB2m4zd z@AZ+VBD3rdDxly^Tj9f^73!L$>{T zx>DOOTehP*Ju#x~t_(jlI@xqw1QW z<~3z=Wh9i+r>Xgp3HF>Gn+}t4Usg|Bs#+{4yK0sFVJy?h>t?!?R;DJZ;RUnL(u$g< zWpqW`AE`y3rRP=6E@c&GbmFOShWSiUwM^AevbA!gtU|7kFP3s?WwKJ64r4iL+H_1c zr(~;Rk#;#+#?;k;=xQc!IccR>-V-isU0ThUc`KXY)z}a!Y+c&P7IjNC zl=N76I9&a8THeU01uLhhzn`v!yK$Y7)$_TWUR2Vx>fZ3UtTRf6?wAEjNmoX9MewrO zl9h8DbV;QW!Lv$5!^)IwUeB;_u`Xv6ayd=(x~E!;3|}d4TZUS4INsVYo|7(^PC?Hq`Q7EGMk8rD z$T?r)c)gJ{%g7t5VJnaBu9U;9e4S(GExTx1%A>nS>*3++*VIBTqgx`+{xB`|YiZTi zbGGQT_0dGla!SRb$!oJNny4E^%Pgrpu`imKv9d-+6=cy9P0XrVE-h)hH=1Y`RL9O} zqUWNC`HX3nEJ0EmqKS4clQwLfV-7?Tbvw~66((yW~rzdMP+ijHaQldAxqQLyk0bw-&DrN zB8;}*%9b=eZHXS*5T1GcmZ_;3+ZH`E5KYYKx|&x7f%QZa^R`(m$@$zHO|;F7ZDa&d zuZ<=a%tE?giNWrVCKm0InYG1Wua72{^n6|`3c6hvO>`WqV3h5C-hRL#!XR8tf>_Xf)e_piP@6wFho3rFAFpI+m5jnFKmveI&7< z+PO?g6MfqkULgAmY17t?wCIF&(L~L0N~$S%!un{Ut{1JmAv&QynrP^TrsYH@tc@mS zoUCEF3wAUyYihYdLA0|cnrLOy1uWTou%n5&yq-4=LDU-}iAB}couXkW_3C)JUJXeJ zNVIZURdoD@u;|fWOq+S9po^vqL=&y7s%A2R`qo7gb9pW6WCh*!MHBN{*0!b0+#gM} zOGYuR3nsNbnpiM0W>(E9g>tPLGuf1#?Xrj49qDO*M>6BFg|V3&#+r{JifZ+oJcrJ|j-rR>@pO?1*ZGo2CR zxi*sMsQIFr$!C>PZFu)+ct6wcsD+%RIfAIyhh^!0C#~8gs~{$Ce>73E9KDbi)YlhH z)Qw^$n-g@qE}Ccw8l(_+ZhMib3~s^z8N-y2QLXUx3gh)x)YCfd17 zAyW|3VM91^Js4EBm{Ii6aZKOPsI1q`Tqd7OrxmkWZ`xq4H?nz6wx+(QTj_$OY~4LNRgVa1>z!OKoiS`jDUFTT<>9ahx85n{>{2#c zQnoy`ziErTA)PO3MboyG-PMW8{*g*}FTFuGv{KGaE5p^=#MJ0mc+#8zd9Ud-EjfMr5fwZM+R!%D@db##g^L}g~?WnqH zmNaE}cXhZrR*vkg1~k>mTWa1`Y#gsOHGM!!JC>D8mqdEgLBxQTRUIQ=)D*2eQmHrf z&46xX^jtBkDqB!?6R8atre@$oIWtAZ*HBH)ild4<`lcUccOXl z1}sM_mhz<%ADtHIIn!2)YT8kDOxMQt@2ytDtZE=t8U6Iirv*C|l~4%2zVTPSkN`7C!$O zC|KEi32XJP^613Wj%qEumJbv)E1OY^mST^Nx2k_JU(7hRl~XoX_m^9gU(!o?tB@@! z>e%RTi~5(cSzXOQQmu}SR3>WC{ww7*&B*7nic={M?{=nl?hN;jqo-BJkn&#>@i=)S z?_kZ_I$e8ux;i=)W=I20$#OJRPb-DdsrvrS)ku0;RWg=VvP+IqsEmwGkBd!fw3xK2 zSVlITGn|5iYu%W%s^l!g%4V~cglk=`w5k+!&2chLUc&LI*EG24v{H1^>5`du>!&_F zT^=vjqKEKlO))e(ZE2=k!A!MQnW{I_V_H+}f^C^OO?8W&tc_0WY5|#1?5vS9oKjxS zO?LoW?9XjQGmEOBY9$57^z~Y0I?~m)Vx(0|%Voq&Ya!3uN>*1b&DITBv!?z4gp)N2 zPLa>n7P~`RvGSRcnJF5IQ{6jKskO+%%A47Oo=z)mI@4Ax$JTATkXQ8T$gY-o6~6t6{kE|-d}!n_vmDZux%yh=(eR>4sT0~(-K?BXRJaYS4u0{ z-PNgj^Rb()6t%3L%jb9&Ed(hJP{9jI`jv1tpy?q@9wHRx)GgisqUY6g^uqjf`2~>vt>hprGglQ*$)KQn)(eWVu$E z2%jGnl&of&cD4wCsZyC}L5Kwn$z>90WsFW02FX755FFFauHT6JADH-`}HeD3bW4qRstdgOr z1w*l=c$*%Zo(kXcmK4XboSbf0ytvj~;3#R;&KI*ecl~PFJV!}8#gdgXGJ@|wuxXw{ zj-uN|!^r20lKNXV&{2$%re-y(AfZ}HIgXOGGr5vk%Hlq1Vt99DM8(Nqc$6I_i(7Zw z6_s1}mZR9EeBRbAcUHC>XGbY%g}iBMDz1noc8*o|1{Z>TljFFd-Mni@u{>VkSIOB* zeRDRwvsN8P6d({I0PwcCQXcW(g;GA9bqYmgdLp1SGSC`ro2U}>9ky0IZ3om+M7cMwVL*PD9zvDZz7qX=e@d_#S=#E;swqI)MgCxrJ>h!3Kg#Mn` zSw*}xFXjNV4sTn=s&zo(d24wGbX_W( zJiQ1M?v7@+R&)4ZWEh2?_giwQ-kYLp%&{|#W8bPOU-7Klr;jleUsyZ zeN)gM>)yk$*7ppq>lql>Fxb=GJJ{1RFt{$D?@`i<`J8HKN(;?1-o|~CTy+YTDlQk* z#yN#%D|I<{_Dzl#EBhjE4_j{hqt)67p1HD&St*Y|X~)$ck;*hxp`hhOyUY!0B`!+~ z==LDmRsV5w3Zg{Qyi!~suRh3Jofr{$BX+7@8!k^(hQ}w}Nj6Y4^QP(Os;htHYQF_& zprB+5S)-)eMUbtpPS--Y&Z{tr_SI&ZqP?n0&aLGYC#RW?Q7F1o>hj8iu0CKuV@LE& zi-P?Gujp-)<7&NL8{IKouS{(j{XJi7z>)k|z#t~9w}lwa$T<%~zk+QAu=Y)YR|X<} zh>c3mhQ1!pM&)`!2z_~o5cV-WMhJbD{*90c_BTQl_8KAdI6F@Wef72&VXx9N_+|4k zGR9tt5q6lp86#`iM?CglG4de$Dn`|L0DGl_ zOvec6B5~5i|KV?(bdorU@#h%n;{Wl!h{WXkBGN?`$zR0dUBoQpZ-}|le**tXpiwi_ z;c~E-hqzo0DCfuiLoGzF#AWZfIsWk6uakNBIdlekBu&h%Az4bUC)bm! z$yH=2SqefWi%BQxBni^NsZZnuD!o2Hh1bY`0@J1BI9V>~c@epuT*dQT?((8`az|Um z+MiM&X{V&yUQlVPzuQK!haMlZjuzV9Ukq)RFDUs8B#tLc9Uv8t`=@#U-o+N*K? z2)lvH%6OMCENHJndI{<9hbfm{LZ-Z=-svR`AAX=->JJxUf1pZhdllrLwOzT+MtE!T zv$pGhhqmjLnic)56+6`ZvsNrR;fHI*UhZ_@(xyF^)~US`tGAyOZ-=`7PbuDB-iopR zXXV_X?*5;ZbBDV7e^$;N>hAxqQ_j7V!RF7JyBM;cHFt-)f7aYZC;We=xqIaf1TL-P z`_tVST}EB_$JvKp#tp)Mt1|MXt=fOqRsLC5`Db0_7P`X!c3tJmU!?x~^_eg2(c*t! z-}!s%6#Qe^*)idn$jqt^1z(Am2+T{NLn_=tt@)$d>;| z&6a5NddC~g+Oc(!(HIn3%`@g8Ye^~|9pB4Ontb+f4 z%(vVXX%b(l11m}M|JSV(u0XN+dpYeZU0!3<>)HSNmJwH^kbZ^s6W_-dqU_?I*6QMt zit}EHKY?w=f1|^`mWr-IDcDzw6>9sQqOPA1)Rz@VSE}3VW#(xpi(FeIv{8d@F58W{ zoRV}n!yuN|P;Pu66?_A_y3H!TGRDm$_zs(iE3vm|Wwa8CbL;Dyz? zH5Bb;8jAGt4aIs{|0wT{QHPkQfTvyGtTv4p&nijSEcyEPm$YXJ>F57oLz9-8+phhK zYsTWfOY@j3HU^O1GF{sMJ{G~3kYYYJ9|&ui2Q3O*Jn1YnYS7iBZ!RL-DhKU$Jj0)` zHNcY9$wzCMOwC$T-SMROoPzfe1)+uRg`V#2{{H@CvS;l&{7EMHM-)cr;fDzO>&lJJ zuWu!UJx@efGg7Mz*Y{N9EBPHEgv~B?Uu9UbI=PIj8L8};-j&+oMotn!?&P0m2nK~L zORvF4MFNp*2HNp2a@eg)MZzLNNOGC;#G1(wILGzERRDc$DIxSj2^lAZD9gH)HT%Ml z%Xn3n62gv0AzS3hz5wKfC}bqh6d~lcs|Zn04MO~~TjcooRfIelg^T3JTXR$bxq&yP z7H&)e%|3nwfao{+>JHdOJT z1ad>GMk53I<`n=g0N^{V03&Uo?*Q_HYX~vAM9B*;(HMHLix4_5A=@oqHvM?FwDCoj2l|@IJ$7E2~JU>6Cg6AN1Ff@B|0(>fy!Q9hS_?ps3E$j9S3-FIU#$N3%GXU!pZFTazf~55;Ep; zipboDJ^vwdUU4LWJ&=+ndguWexY(YNsyPGj`H3Y@yXG#N{tX=&_nD%7oDYN2q6!vTTME{POUQO z-1d}W(z$xdH0j(kDaWRBW2tR6Vv;s(uy<`bzYhIk(gr(W&<6Xs>kfJVF$LO4q)a-` zIS7*H@ij0)EIPkE)oIZNyFf2MD6wf{X@MSMbM@smZ7gbmg4!JE#P1CM{by{Nz1jlK zqBCr^8^52%rs>-@ZHQ`)rM8*0@l47w5o4OP!J9S1W>=}(f5*OLGY{~NCL}?!gpj-W zQwgNQpC$+)ckrh@UL0*e%;k~vuU;%W2o?fS-3?$qaZZNf39JKrCQj~@AnwACQTJiQ z6J!!hwYXRWk-HmOWsHR)PVT%JyM&wB`w6lFa(!1F?@LxEM;4O>eW(EO3dIBzIiW4$ z35^zo1|bnzl_?-&%i?5N`YLu{$?Bv-$X)lL$i*wCk}IdkT`Q-EPUq}Y(!_7)mWS1? z>ci@zoX8ZA(LZQ|{Y3={>9oNIx$^qmV6O=lAtxD&!>^tNz ztEfZj@6_$TdyLI+Qr*W%bpt2TZksmfS1I}`hUGB1%cS#@F?xu-Uf)L>fN#(@QZP0q zCY{q$$*wzeLCY5~BR;JU6ljBez+-76jtU$CDZgOS`4x&8XD?Z_v4XuU>SxA9jb;)c z!Beqm_Bw6QQz?2>Q29t|k{w=zI`BDxtdC$GJjV`aV?^dbXU0;=*ff2Mo$L%$PgJLm zHrRJS`E=*bt~=-~9~4=!BdFN(?JD*SpFIiueu|2*!wXwhB;!^DrM%$vdp*_7XV3;d zgZA~Z1JSO(pAgb7ro;P$5HN)VVMhoded6(DZ<4Htx#_E8g!J&_jWKt!rDKGw;c*Dq zSh?XB-c%A#pkx#qC$ZmLMSjEHUr4sr7m?CP7rCLfoPD;89lM4dxXM}Dy>g1IoZ=*D zf`KI;LG4c^(PLlW=LF|}^%`e*-5&jnq!h5Ucl^G#X=9-~en6BwO{a~=FV{d8Xh8AY-OwsyLuA~wkaV%xPB5wZBC?&sl6dEoaTDh+$wy6kke%x8 z;G6<07%_XY*=yhx2f?i7rk8tDn;iggX`So@6Fg^z&9RHU>;UNH4Euuq z(`4VU7fp7NGrqGOps^SKWYKw*T`=WROV2{)Gl$t3E6&caFX@NV0UDXNQ%Scxmu`Y_ zb6Tfhpr+EA)EuI6PO@uu{hsV4u3IWE_P3njoLWU2F*?IOj@6gb8FnT% z-DA>*#o5s8D#1uNje{xvrqdl3PO+QVt95WU)^MX6+W`mpiOpdB=d2~c*|O;M4TzlM ztyT%)`)xNsgc1UgctWe6;c+f|`5y@i3iM&b6W9x1Pvaa6nY*D?#`yFsB%%c!WI-SD zBVO((*UwWt@l6v}Ys@eo6rpAA0yLJ0kwlt{5ZhCoe1%!YIR*H|GpVE$r@KL>e+OT9 z7oB;QUH~l!$#<#RMbF*YIhCLd_D^=QqnCY(S^9eY8lJFZb#iKvN@w=3BGVnc?6fW2fWG z>No1Nkx%Kgp(R7$UKLKaEVec5r=q&c+E>>=b+58$V=Ma7YlYv`o7&@Az+J|hiU#Yc zgi0GLQe46Vuh20tT!@3n=QZHK^h$b&ovtrKBUhQUu>~@Z+kY(@A~+P^N{B_dQRiEX zXRzJCPDI_#W;TOhKj1R~vs`Q_o!>ziDflG zruY#gFZB-|AOb%#as!?BCb@jXY~%Z+IEmeYy}>Q@rR0_o{xOe5$y$=BDfqVJ4&iRY*e#O7Op1e1?a_X_)C4ZIt z1E7?L9}x@oWTMrA{e*~x95}xBSOtOO&(s6;8+X!UZaUW1!(=FsJk3thbC8#ts;~=Hm=#q3v&YULP$hb- zeWgSt+T?qWzen*3Zc!_C5}SU`^}!vnE8Cu0g-3|Htbrf7#RB_E(iwIl27#&GMQ7OA z*fba9Wv8-}H@IzXw|Kdui2WC~SkDO}@I(xVce9|Dp~rv6W^g($go^tJ;d3}a91QzK zJ_{gG@M)P4)7*WAC?KEtMWKA|!u-K3PLTWjN9=y+cRbd?Bc@M+?8YO6_5`WMTzQ5b zK&)6=>1&>BL7zu7P7&R}AmoUJRzC7M2#WR39*+Dw{;J%9xuM89)$XGt|C0CRY1V(66gaE$ze-@CXG5S17Ovaz+z<>}!Fqx5| zkdIu~Y2y_k+H?v&Ah-J<16~5A{6TESkAcw6*^q8=ZXl%cmxNU0bA##iVr5=o0uV<^ z?5`r#rt^BrVJG7TUm51N@=bGK0kKovU=A`b|NH@rniCzb+K@PoV$bn$!3K%ptSLdZ zgQReVmLR(kD@X$Y$DVFrKJS%}yyHPJaT2?F0lB(w1-Ux5oGhFqgn#;W&FIMDeRPJf zi|itRg7?`N@pueUX*dKgvLV;UV^Ty7gy11J1gdz9pN!!UX%jtOVt*$*djuhxq3|Rs z5I9XnN<0QiL>BZUJHBc#&Mz|&FxUtjiUiNAu`i3qkPbX{guTvAu|q!QN{PwgLM3AF z>6iF0{bU6_=i_aZcpNHJB0n69;r1IP{(^n?%YGjXhlvQ{1TEM=jE-O2>K^*-Gd|jg zMB_lA(x6@-&=Bay^ZxmxenemO5pR`<9E|LQ7g#Su`-0PH40MC=5d9}TzR_(pArHu$02Lk$+ziBH z{0xE+(#g(TN5A#)@)8eF9b~Frn;4$lFN)wbKzK^R$ngo>OW__h9^=dj#J)U3zr)Jq z!v9%5EN|*jehTePS@vFeIlZvl>reWEL==bB!8wc59e>W!_t@XAqVoaFk0mCD3r!;I z{QV*yxWT~1vfC}}pv2=)p%QV0Cx(!7iNCYAe@$NxU}Awq;BcW5ajEB*SQ>n+FM#%? zMB_lA0#&=8)!`;*P6QTOpm5)V*eJluHs#ch3YFJK{z076&*FUqfS1(f|m1n;!ZDd)B8T_O`@K zHPI1P^#C1x-QB0BJUYVi$ODH8(a}9#*8t=O_B=cBxR2N&mr4#5;sX34!ee#iHT1w< zAMGZICT=T&jBXV#POvdTdIle+hkdj)5{(0eO8aHFb>~v_0{h5E)FmPZ3zc^-N5smA zz+N0+hq`>cZ4!?|k)6Y1)hTbO!q5y&2BV^bwVLP6xBvXa{{!~nDErbMt#O(A>ZZZM ze#-AWc;)?M8+&WDH(tM&m>e$D9)9Z+1D8Z_=)2cG?W57>C7!q&3W`41fCog5bM!Sj zn|BEk8hjEHaN$XS3*xxngKyn_-NQZ}o0WKg3gh7*+GoHW>}>w20G?YOpu%{#6^q9p z)gaKnrpA`~c#Gu92B0w7+E6v=MS6jq#eJO1J$@xI0T;&X<(QcLyui6F>_zsLkGM-B z0xZn*alIFh@vSEqC7mrV-Rh6NxZ>xxfShmwl0B{n{o%i#9>4mrK5y*VE3!Zi6&ifp zcllC6ioW}2_OAfqS&7KOLepn`s6hH5dxO2lzVK0R6}L_TE>t9Tzj1HA(l_asV^8~d zzmj+yDpVrBit^Y4J8G_a#77&FXyU#q$R4oA5af+jjh|!s71py->aK-7bVNc!hBs(9#`� zC|>95+?@)q0m9u)F>69GDZ2>)RRmP^=c88*Zb(CPTj+gR| z+-J4%t{XDUD3r&>s>7lR0kZ+wRlTAj!2~e`EfPfMu5E|WA|Wsw!4iVa4aCbPe=kG4 zEA??&Qqr1X6!mODeriM0#Ob*A6$5;)246D3$65H`;M*#0H$@_41H!RGL)k56d17R& zQqy)2}_?)9MfLY|+At_R!F1b;r=o>4{-7G&EHip0177_YVzM zt51zqLNREi8!tbQp>eTC4t!5494ja*8Y_sTyCrNiR=|dHm4gwA+&AglEV;D_$N5

L<0{a4_-@`qUqU%A_@pW3O#wm^r%pw2S_^M<-T zggfl*AzTt@4tVZC*SGX+=g|^05 z1McC346RJBphCsv+r?6hhOpC4skoPUOZvAgvxGgaR*t< zzUb)w58s=hcBtnA^o1MPN4|h9>W*WQ=;jJ3{?3DbOW$E9*)jim07r!g94;hbWBcUq zbhkhLJJ#^gxUM%L0*Ge-{RR3Of)yR79X>;)Jlb0Q<5$TfvD(J6_H{xrPvSTAsSM zXpw$PMcv#}Cb;3HQ6hjMpa z0UX*5)F=G zH{VXklTo-9jiyI$hn;p5GSX~}4E^GEFvTcji#*vofIJn2jO2-0E?J$tgOIy$WfN>q zi#(M(2(hDZksL8NPu@WYJuCsev59o~{Ru+oF+hHYixLQ~m*{djw~`S0H>so0j?&N^ z`sGUKheRP;G>4r4mTWTlcgs8tD zq>MWisi)Fze#KT3ay4#IE>S}a%j(sHY>L9QX!37X6HREarHNwAWU-(or@o#&Ds3=0qVwVhr7bHiD#YJWhba|W+yeKm4_ zIaq|$r*AY>ZW?NS?;CXPo?do4bZ()n zFmKRJmuyhotxg4c>Ffl9vW(HoP8+@K(_VJEmt8dQpU&@$b=`rDbL%dhVP_U~(L)p} zESD@0K(BZ}!HWC6+(l=ffnF-7F7ypMtl#DkXeq-u2AY?10vermlxt0Q(OIEw-C#4; zYS>WC+X)8>^(PjBkYG4vt!B@`S{bU2c&_J>ezvo|z+xBKL3Wa!6&l)yk}*PbI-gzU z(gDhRF<8Sx3wR?MTT{^akCN?Yu>YnFcAlM}AAz3pWMeZK6F(6!#m zEsi4@Q#a$U*vTikaVPo{8u$jCH=qyAskXVc++fK>bzzGc%(cD;#)_xd$!_F#dV0*D z^BGtxw#sSxVV(y+fe8#)T}K{Y1#(u|MRr7`Gwfobi$3=|b^%(Vyny;Ic)ja)ajS{j z(c$%5Oqf@6bGuJIRrQo2UqF>77tk{z2X;|tUW0o@G_S$t)FJh881)W44zpfJr?@3e z5DL?3+_NSKg%yH)gdL=OgxmCdVDsStFdu+@)!`avu=5_kwQ)Ctd*kpN0Q|LaH-F7b-5e)eV<6Xm@3F*X}wQni#H*RcljZXn1$IHZ?R^sSQoyj*;9wQrS5=Q6bX) zL)r4E`mneD(E}|lI2;iRb?##c%=QNR1XO$mixoE`_?(_Yr7(}@`9h|MMNP+w_n=?~ zAo(-G2wWI%baD%Gc4FZIV9wABe1V0P=c&{_UgRA8Dg`qEo6gbqQ@ay{fHS;~(SZ3D zHv^f|xz6|3SWoYh^L&?}jYS(pX}gDRc$J-8X3<7w8SGCE=w0-}Hg?gXbD3p2J$eTskAQEU zj7_t@aHETEc6bpQ%Pw~8N#gH!i9MLo*O@T9P>|?BqxdWgM0{RnNaH(m2nH1E@p+4VK3sc$TMHf$_wZesJ( zx58{i)B?-NA=E)GFS59sA+cP9g~<#%+(~EHw+m|QU@!X=Re(VcJ>u2pCZWX7y+-ho zQDPVUhO3wCq;pwz5w$!d>t#}avcq&X0ooVFVQzJR+RNr#*BD*&bYjWsBnIFhJ*s!H z3&PCjbKX~eD}sF~x;@Z$hwcU^7Q7f$7t5I2N3uGuMe*HkM~GoY#a}S#TtXPv9CIm* zTc()Yj6qsAtY*hNBc3jLI_B1S$?BwMoCLeK`*hgAtwLwabhC@>FrR1La1?T%x`}<= zMQ7+yNUE@F*YW!xJHg&#-=PV7Af}$+gHX@<1Kqw6kjgTA1q-z0FS5>Dv@ut+gI#wh zsI=_rXX#OU8L#x*H2b2LeX7&>Kg0xO>U6#mV<*^WVs+|epRyD5sCaQj1JAIUo)Oh% z7uksgyiG!O2m3Jt@h4mq$r%Ab(u=zboZ}mhReS|)TG!Qs zO6N2!m z0-9LruzwT_oD|x?@x$hFd~Fs|+Yooeg4qBz^Ec5&u(e|+={I~K2_^WG=_Gv*n`9yB z!C(evTnWN$%AntzATVy=H@pdgYcOsRB@F2vX`mz7`JU_jaYK{olO9??uJV8*?dEA{a-C%s9G(w*z zWGfX`HLkH1jv@pOPH)5$#I{E`_5=z-X>Mp$P)-&kf}1hKNxw4U3EF-lV?ZHuH?+zZ zCVg>o=S>UAO}qii(16bG*8l{!MhLCS5jDE`u0>>7j2%YV1^&dY~#m*CXKoRQQUYsn_@@#i}Xfx#(O!H;vSR4sm2M+m!tT36&w{# zk-p#uE^vhO7j}^SqXVZf!jOG~y9~gLUr4Obp!R3eiC;>aZxRn&Tu~%oVn_oMpCIR`s`LAlW~rU;{=JD@de!v;W@i z6}6FdotGarksUVZ+#)$HMA`=)5b!=mGb1@C+xDu0?+{^k{ur1KiP_$vnU_bz&b9Y)9e;Hj+! za@$)rhcU++Hk+08-f9h_JHNR~-O0DeW*7a29mJMb5CyvkR*T83Zer)V=(E_hh<}IG zP3Ylg`5p&xe41TRudow$i1uF*G-nX2q=4idjIk5!B0G9HS|%?lzM%=+i}RFib= zxs3?V&E!sg60uOF^G=MdOLlH*IC(@`rv$X#^yA(7|~_DpoJH?g;B^c{Yt$%lQ0eZ{^7 zPA_|%oumh`&IQ{EGWG%1l@_a8s^9{Hh|D1L<}WA-d? zYez5QfF23~Zh*5ZAx(-WtoZOZ0Iv}VLfBWi7^y#uixx61aUj_VUw_RmSk5A18O-m>@Tz?w#MO?g(yO5Ly)= z>T>hlo#fhB9zN#SJDu#~jI)< zQ!{C!w9NMa){c)|P+$tt&=Ceg|sqF=g~c9$ZxE_&!` zvC#0vZ~9tZN!iitNETcWlu=K0>vV2cCtoa+IQ2~NigI$e2^)%=#Qf&8*Ue|O+!=KX zdDLB8*-5avL+n%R@`Ce7-0gclZDxhHS%c11z+~i!PMv!cg)3T|rlIukyyx2nPSm`* z>>_*C>zNsL5^iOE>hXaAClL6tT|f>zNl&UchK=z|y)I!#vRF<0i95qiQuufBNb?G? z0@CJVVi3X^G}!UL{0xFWD8R#A<`o@4!c93lu~>jZ-AAncILQ$r0ZyklT_<>iSbwn& z$lF0&Op7xo?yyHXfaAm^kD_pqDHnL`fkgrQT3P1H;P*{r$8hW=@Rr70H14uZIF`fx zrAWrIEd99gi}!yBY2rCV%jfrEZX;L&(QrPLAnb2m#_UZ`h+$s<0`oUP65iohSBG0M z_^S{Fo8YpdHe0;N5kv~Fa&*4KZ6tjc(IQidyGz-~gB~9HdxzUf++&Jvf}AA1LCg3(AP zAzS&(C(<*s)I`NerEuUaA0Y?Ow|J}_C%h;(v?&I@poDP5v+k9$6r`hIZA3|skNAoZ z=YS}}4Q;Z2Nn{T%nIoOyB6uqU`34#TSA+2|G(wv)1T^;y7VV`=lp%VFXDhs2i_oSF z0Uf((5xI#zyMleToV_ERKu<31Cj3^JJNo6T_AFPhdRW+~KpmqOm!n)&rNKVIN_v9M z?W42!Ibh-!_rv?>QT_{YVIO^!|Gp!9QC)ai*%jJ0l1R9($LdAhc1bmfs z(L=D6;tCqjfT73T6~H_05&{IrhP-g5W6v+>4D`a#BZ)oGqN2}92kL^$i?+b$OaPZQ z=y8D~s>6p{G}2w0*u1zX=S)u26cNx-^Ogj8Knfin9CW?I#iTW<DgP9V_5Teiggu zVI2E6)svkt00@tsSMv^?nj8(oaNG) zrOW7?mITCZI;W+$RuDD@&!nEfEIM89@<|D^QHp3N`=andEKi-pxv3Or@bw6JQpJUV zNx+Ar_JyKwP&Nx{dtcC_AUsYSUvux`$O3&ra!L^Tp8PmMLO6hwULYBK-b=rZ zt73#ZAV`oWK!C!n;~qQ;kCF6rOza~Qg!`A05DYiH66AVJT3H~}f5aUSKS+==!<*g; z$xiu?-+GVB`Ipl>n4{EP7oNOO*sNMwhUJ|HxMWzO)h+5fs^R| zcRM%?*i@l6d@oHS8`!a;?|1_piU6Rn+ZCkvXiu>3==pnnJkecZK*D%9ukoESZC*pa zfV_yKW(3!m4p3n{Z0P;+*eBO-fkLH=SCIIC3gba1*~eRV@A8C??XMx7z zF*q^`oG;0MBPj&HggwgO=pY{Bs%WszVqYwy7wTMbj|b0oaB-8>BfriH+C9F&USZ$% zE%u7%4wDfiWXSSSxHc4e*o3g>D(tgc1E{X^K@P?<;V0N4xQ31V%-xR)QV6KscLg-Y zK7&6qx91sTX9PfnyB_MBzCkAYlpefmi;vhL=PaPYc-&!O44sL<8V}N!1HNFO7>fX? zFdj_1;^Lb__y)tT*<6=j+@M4QP%95I!3JYa`xRfvj?oW)>*oaTwg`agfB|{AUY&*~ zety#`-4%|zx3}ouVBRol^E;CseWpTB`FYbhnK{5j7t;@AlXU9kvHbXy;u`hkht0jqnt%ki5g`FneN>9@7==(n6N{QIcYa$> zBA<0woR85L9eT<~q=zIXhYOV`ye6VY(dlLS5B4(qB!CGOPXrFfpQ!5!P*7KpQiUr; zi9zVQDLM+&Yk+v!NjC?Nc-h5JRLU+6xc1th%dqPv zPA@Tj@Q*IioQ)hWA6u0-;}5v zFjS`SljzbZ{a1Dcdm(`MnM4#WiJKkJBCuHrB*{9YZWjpfctZ&7CNNjwe}Y9Y?v{9dImEn)}b0mO?E zk%NVLRd`r*dzF5D=OXxnaHWu2r9dWKECvkOgo{O&wf%dEV3>FA`Ip4KhxiYoX$Er#!4ijo#*mWZPdMW#gJ?|sZhQw^= zI#DbJgxpNOVz1M$1DGF4OzAu^&_v-p(QRUqHlAj$_=s#qB66@$6NT?Y6p65jJzHR} z1`ywrh#ZWAuro4B5M{ID;?b$8$?~u(cY;h2maI;?11tzIAf98%j^l2QLxOnOF?s^u z#c+A%9TFFiB5p908+=sYtP=qfATVMmbaHx8Efp1EvlFV^`a;fe z@@dmnq$N)%bwj3tpU)b1w)xW1s8wxi}$WiX}b!XPLF z&|fGy*-SyrDbf)h_kJgv^Juj;;yyoYg`B=!)(sr*uCSBGKCgG(c;U~hIi7RMRBs#j z=6C_Wwher9ynuJd+O17wtY!4RN$%T*ziln=7^}F$+oRcet&q!W%HTS$+syLRZfl}m zsZF%>zZmk#s0p8pyr;r$A$wDyNYPD^NVm-`AlHT?1!PY+(sjocLKl#sDA_5&xP6nn znOnxHbv*N=fCERFi$AKtwCIQj)7%!d%2VL^BiW3{9SSzp#cgJ*JVkljxnLW-)@cH- zRgMt~3RF@$ObWz=NMUnD(1K)v10}0iFwCsZXC=R8@hB`?aoLPpgP$xJW{C%Uv}x~ov!aE&zD`d z@L1=Dp6>4c{{CdLr)Pbyh?BnT783T-%8d@iK2AEwY3cU~UlI(3wr-!w5y)1)?C=>o z_F{~Xtdx5oX|?lAQN?kxgu@!kePRTJWdw*j6!*2k(8_rRK$P7ddf z^AN!e-1DXyMyy(7O5c8&NtCb!Akz_l`xk9+1zTxT45_dvJ+y{8zIx?mF! z_)4fb%w7b5cTLh@4LZM%UGxgup4z~^VQ&jn?_1@Edr=NX4yQ>8PJVbxkS);X;!m)> z@!jKrY}_FB4xk(HgacfDMoD5D7m|(jg`m*BMfhF2@QJ2D07s;C@0NdH>C$rr-i zEyd-0<=seM9emRFc!y&d1fYinRLGIOD{6MQmwv)#d_-uGB5<%4UiEkGt&P^*Eezin zT>4uS;gkEwXCUysUj%V*pR$YY!4IFe3%L^1A!2YPBGO zDXzVmkW3V=MSde!6EYcvi!89nk3N4j=0Fs(MUL#i)wsHfLbk}0eFDe}QOFi~-gXTk zt1jaN5w*-*L&$HVa4quNcMUY8qJS-`NZ$oylmEpQS+e8s)cDR7n^tmojZxk|;Bjz(bErHz7YI4E$fL`b#WFtseo>{e< z3&mxG{8qwwZEjKWJ_+N7Rs~~;p$8&>t)?}Obm-wL07Q-G`6~c~A6a^F86n-c*Sk!c z^=k=nBwV{Tqs)nG3HehLuGRRxaVs;cMY#Gz!@wPj>!VLOO9da|wn5 zzI2a-aYL(tfh@OnIU$CG^;WGG1(%i+^4Mj{1u5>of^u;fN)KX@{!l_+YJs8WmZOKR zpltSji^Bgin+5n=zN@`2Iajp#ksF0!HYYy34%rgDogn5gd&!T7ScB0Q@jfibHo+Y# z%|L%@hHp9Wb<-JkihFcAYtqJIdJeekBHvt^w9!S+fj?sVAtQwmNMk$p7&B}(IV4;y z;f!2-%w0SoK!|XIxcow;#S^M7?%#00p5Wp?-vq2(ILYfr=T&wL%7u&fCipW$6nz^} z3wRVgA)??4L`JbWuXQu*6!+uv8a6;Lay>3?+RC-02JVJ^!db3a$-SS5kFNKM&$pfn zZ8kDJH}4lM(5LR4S6Iz!A^D|Qr1yG&Ivuw z7gaiU9nY`hr^##?&nzCu?0UX~OVarqJ4Vl7a;tQ1F(0^9=sd5sJ|I2O8c?<%j=bhX zw#Z8WdpXXqv+x8r3?uKKvZuP}h2M9;xsoIabmS4)<=J4DACX<2bt^0&WtX322id!c zID5tG`e1K~(fI-6h}tE7+S-Y+To4$`A62`Bf!f_d=S%#%#m}UYvOiw*#{61uDE)o~ z0zDzd{L%ggf$UQRlw;m^>4KE~0+c|@EYbB8M@^))%% z!j^En<8q4yDu;uMgQgsV4Ms<}&E_X4GYr$C=6Oq_Ff+i8BS9$KWXi|4{l|a$kI>f^ z0PJrtn#Bgh4dN;nTu?lL3-Vh=&J_{dyT&k#fCg*EDibHWkTG(1L#vF%_1K+QS?kEo z&m6`2S&ApD4L#xcqADTJL z1b7KQZ1ea(LTIDV1Dwc?m zM4IqVe9W*@-O$wjJAMubQ;1=e9@ua<|CD-?E8nMFD~ARndl83dmLaN04qJ*7ZwgS!1QDbCFI!RBCI74_qX!0xlBd<-;%t&%k5gH~docRmUslHF*arLbOie$R15Z zp!0XobNGZkvPDqk--S(xLfgJAB3xr3ENVhTt>ZCl*06T6)4SQXpfk5b_`gEv6o`R? z0UW;u^mOp0(oRngX%1H zs}ef-ZF>Sr-#jdB>IyJ{cns1T!Y=wYo$dE~f*ai+TqQnB95}khiD*2=Wjzca`;flk zuupwd_7{$bORr=^R~7qfzZbJ~?(yGV?e!u9OF-aIp>D)^pRdkE&(WiIDgne#Bq9e3 zsaJu$`32tiFq>s>1`uIzguuZb{HuSUyMiKK%w%$v;Fc$$M0kZ{nEBbG!7IhO=z}@coHpbmqe3# z?SVJPy|9x-%g>)b9eu*bexq{3B(p5YLArc_;?H%-Rr_U-BiI;5R zw_!DN_BI@xvTu_fv#=#*J4JJFN(4GHd<{MCg{V^Kl?#4K z$Wv^NJ$IXr$l&DwK`NF9=u#+_yYqm4&R*}_9YB0fB1+Bj0A=z`n5TK0WA8q=B7lc; zPXw`53l=C8%e?}R+)ZDnANZJEvd5)vd7waFw;X|8q^}j|b3WqT5>cp@BW!R7kB>yk zF7~(!Iz}i=VO*^|21buzVn@jB@NM7@SzhLJf76JCmCxDH{yz4_{oa5*BJtYkp1ZR} z%xfQSx5N{w=gk%p!S52H=Ha#oopR7G2H~!!e*dK3l0V3tyPH}fG{xO8_rMx4+;0&OKj^lIrT`sjaJPefxc@C6SX3kzhvCV_9)s zlx^~=+HM(BnO{evSLlI2RQ{91o+IodNa zR*j5=S_gYZ#MbhT=+>UmHN)wliWuFp33g^v7tkdfVWfMyuuy6WJ}FvfM%!I@!nLj^M5?3lgy=}zpmnkGSY>p0 zr%@tbpk^6RPCHf}C|AnGO|O)DD_C8P_4W+?kEE?y+dB<$)Vo;P>YRo3dB>W3EW>RBO$HYGXj2QDdD-ml2v(Cw-3U?ljGgT|Oq-^k}BVDXuUyx>e_ zfSpY?f|T5;y$%wcXg#SOOu^L`dS>LfdZ+N{S=BWku%38CEF{Fk^Mn|3dUObFKA8Xd8#D$p|zfJ2n`&llneKdw%M>*fp5 z=g0ZtqwTo5MqNGMYQdp4AOB#-v^k-lODX@`-0$698 z6)Xg(9~|VLCA|>Mz~hkg{|(_0r>FkUgh!elTQ^)>YW<`6zWX13>d_TXJpIU%t!?cc zon6bim$$sSy*ygkIo?0gGuF3x%hp%64ZOai_q9z!gZV;aZS)0ubu5ugWwN5x$?32>xk7z5wrKf-6;{4X zdfO+$E7WJB>e34J+4v)JYSoez>e}cX4eF?zTubLcbMzs}J~c5u&pD$xcO%X?QZRxt z`G~x#W)e5qa`Fyn9AYClbo2ouY6G>ogvwVmARg>!MA4462k8d;(ADzBRVamR&QxWd zusY_7C4KY7k~NKDN!tQPY5Bd&GdGRHl+qk^AVPa=aI7Zr!UBrxNtMMt`4 z2|odkjL%s)ogwv#C*+h?@(KAEs3eQCn#}Q=NJ;kZ`U3+lsUzu=lT*}TLbLatc)Oaw z(G-rXqGXU~CiL2qF**Glv|kHb{i06Dt72r`Ip(DyOcOQ)<_Jr2S}o?qYdO zecm`WBB$gODFu_e)UR}}vWX7E7Nz8LM>?f;sc*umhOrTK4(D4@sQT(q2U+KEN>0Dj zm|CiSh8F6SoLX=fAFwRct;VsiRavGDV(o!xsF~|tQ=f5TsnAClWdG8rLaj=+8d2P_ z#GsCO)J~pLhp;V%1zng9#CbD3EYvkeWFRb-h6F7_!=fd`VgzB*BZWzVcDyHt7Rf#| zJlcNZ^YuQSbI{2T9BwlZYfbi{JLYve!Jw&1yLz$n_xP+9@P8CLTs0$b^g zi`O)Y#U1m+;KoNM+CVj8vPHAXm;RMnBmwFwxXz!@}jCdZmv@G@K@ z70YBP@ni~yOgEAqw-j2yOl66>GH*`h`jni40^3R0Dm?dh{V=B-+gN-}$I>kfl4NTR zc2h|`+s&k7yakF~52ByjA0|tx-JFYvoL)edAl+6HYhFi3xqgEk_mlZl*q0;wtgJ1M ztY$&4E-s^PEL_< zAl~CW`aP!CTm7QGG~Qyozu_g^J3vq1Oz1T$4&kGjsx5>mBL;h^I;eh8pX)&CEB>sH zILmzm(x5)#owz*ME~n;_!dy~W=cw~_taVp=Kwdds2hLN0{daflVr?ziJ zW&c2ZQjSdH=Ag^lQs>rFBI~%`J-q;n;yE4KLuhh!Bje`Dk>zkw4?jNPI(M7Cgh5fV zwzkno`2Z~J;k{$?5UG$5c{#lWf|GAHuS?76;p?Ds5T+yOAV1!&Cfn6f^!yZFc^Lhp zy+VC3-e}8T(KSHeaVoCg^ypuLd#2k1hq_8P3`+36kM<$lt%D?>dh z^uBL+`9&5Tz;}OPGNHYSd^og!hJ2*(kjF04NX*`aA+16U21-MMj-)YT|3OJX;m4(E`T56vEp0pW|NNn9Bh4!@`c;~5H4PCo~q4+xFUPs^#d z8e!n+R|qFvbVO3L0nN(OIameR(XKuwRi2NaM@h@6JdH5>$R;+6qa(rtcnyx@#Y7i> zj3)0e!a{TY17TR|fTX(GXRlB{jH&~A;$EUD`#M@!kRZ<9rm77C8pg<`q?%FZ)F(KQ zg3v>lEVHpaIjUH#ZVwLHHF-wQKC}&NOf`tm9Sg)AeG9}LYpxe}bYR|gN87FH;@{Ni zo7CYO)x?q!G9=ry+OY=)L+yLi_ggVuqjV=w&P({`SMHz5VAhoS303%g4yGMoinb3O z`ea}88v2(e2S+RO<a27RV|45jhDRt)yP}Tw{#P)Y26m-n6`imhM=0fEI9Cifx3kvFg{vlVlhW%c@2> zy-xkE&XUb+W!h&pCPAz6(Gp7k458q?tIbVsu{|Pmj z4zeZzFotPwlOZuebhGM!+nFP45dVj;m#^s@ahlHgQTYdJmVGWQr~dY5`5>#hoR60O zc|OLM`*QF>H3w=pYHSUgA?7MWK~8gx-Jz=%a#-?T)%JUqrqD(J%1KkvHS+3uplO_r ztxyxM-B^`F+@>bh!?Y}dx2r2`@eGZC=0hvguZtrJ_R%LQ_d5dznh^vB(PrO8&h|M2 zl4HeTyo;!uGOw}7bREwjb0khU&`eUGta~4edP6y~wn4JoJ4YZ(SonzKFXT&tr57+RN+!!>f!W{t%uIoTSMll@^ixwA1RCwtJv*|1icYqmHF z?oZw%h0mB-^DD4N?cJ)o6O4|ezn;ZKshXUj5Y@>Y%U_m4l_qyBurCZTkFdb>i|@Zu zy^A*jOYX2Ba~d2el<8x26ed|}^zmWwQg!Tv1_o#J!-x)H)Uc43tD$g)@OV8DRyN)f zlBcd0@>FGkkSEvNB>t*)FIE>9s?*o2!}Ha|yp41JceUl#5&QFO@nUpt2%(du5`3o4 zym}uWqr&NN8z@tuEbh4Cf~Ld!07n=@NCUIXh7j%I(6sjJ`@`yldseIEO(D`}3a?<% z>yZ=qNF7n{%VXD7PiwUpEa8m9T9)9$Xbz{&s6*PAT@+A zg@RK*se`N4$8P>5Y=gi-tj{btHqaYF*hN4cJig@)uZ~Cf$w85>S#U>QuX;>fmOuYh z9dni8DmEjkCxK?!S!NH@4wP(A9g#mg>Y<)@Qe{25-u-Vn6tAZFqC6l^>~M)NeF4Wu z=iVK5+K8(rsCLO+Z}z)9EtJOFb>8%_H}0k5&{B34y@L_amcf z#^vFIDL6tIsz5Q}YY5>EV|NKB>MB7RpcMA2(E6dDV2+Y+`*>E=XfFsi`)Xr%pI2 z^7g2==BaU1pR_!vcB>0-c$hyrOm0NpXU(F0EG{O*^&|2FdB`P_2s62VC*7xhRPV@7 zeurLn zPv=PDej(?a2nv0VsEIbWooInBz&KX@i;Sg_esOg1h(8U|xFMnG<=$1xK zIK(@+9z3UeEYQfkmk`hNZ&D{c%35LN4{kQSxwZ@L_Al_4Oev>CJI(88MR~Cgbgim9qWdRE1RRamCbP*3i+B>Hb)aHo1@8< z&C%@2=2&6n@|Df8+{*Tq&9UOjmX*!1ym1m`32N-5g>I}eJj!b0w2*{1#1VJ!1l5%} zqWk%tv2CP(POR?j8Co;iGc-2RGg=;E@gN<0TXX%pT2iF`U3zBCEwkL!vNC_ht$)uc zU)`IIBAt$6Dw9sxiIjzXaMq<`RDvU*g*b|pt>sZiJjTg$J4J5X;Oy49!KLIHs>7&r zgBdkRdy3_ar=Gq^h{vqjvI$~8W4g#iE0RygBdJo3^gW_=wY2T<|FLaLiw-d#SF6fB zebwkp(IH2ijH-vkbDRK2GHt_#v2ySDXn$qrhJT|LGQaw{WVu38I;OtEIyan}sJ&B_ zXX7Tzm#fPI<=%=T!n1BbRm~uZ~gKM$;ILuEs*5Irf947zUYH+pj0rzSE9M8SC*C1cE*5(i;*%SbW^~qpB+#3OK&PzQR0E(pL`vHK|M}1xctgUV*@iR5h z+WMh5FVz5Njq}$UXlQ6qT;e5ECu@MUd8DMj4glo3R2PCn zuLgi(_ht^hj`6s9oe%aR76-)L9RP4o_) z01!`FeHj#ZDIhR}FTFgj-aCM{vm^ix{pg(ma47Q9064D2Wr2})03`PDvH@_Y?TrC& zoX6n+NHp-B0dO3n+#3Lj2P5AL0CeK~H~^Fe!>$STk z##vvlgEi3F*NcY2qXB?49(@!5NH6S{0f1DTA8LTL#X(1P9BSGQh)V^;6$9ed2E@G-5Z4zF zw=E!UG$3wgK%ATi0HogLKmZ_352k|xj|ByO92EFPP~h31z>7hFzXS#T5fG^M1qHqv z07xC@`vHK|ah?ncJRKDHZBXEapunGl0)Gn#Y=E@8$Nfp?9uRp$K-{eXaCm@s2f*R^ z-4_t|NI+bBK-?1nadtplDj=>H5VtlU?xldZz5qBpw`~D%cy6x-#O(-(dpjUb?hgu_ z4hlRL6!>va;1@xGXM+MS1_08~_e%gE4Sl}{1ggD3fm1<&M}q=S1_hoD3j8)G@Ip}F z&q0B|1pwj^Hb6Cq$IaHa&ku-O5)gMwK-^scarXtpJrWSt9uW6LK%5;AmkNNxb1MeG z;mvzCAZ~p?TyH?!D*I^@r0oE?lseAo0 zDDZ3mAa>Q|4*`JA{>@J{(AwfqoPX2+Ym0;ZD7B{sSQ{fJuHFj(rM;08L4jWd06K|Z z3;?A9T?+t2)3^@0ojk7Iz9&kvFaQo)N4EvQA%ph@z+nsS(SW!W0deU7IBX|A7XXKH z^aaEX2gJP|0EazUxi0|Fd0mbLhn@-mrJd0;0f6)hUa0}rzJj!c`mY*b?JG!o|9b-f z(MPHGYk;*$JMY!W8fb0e^j>`#0O-VdAvpAE04Rzy2O8BpuHKXg*=(%A)fNX&=dU%m z+8RQg-&%vKjSu;IpaxePAI6zS1K*^u!})TEbh>>w6KlptUmYLrA1e!wc(14o5B5}s z#hR`CW0irjSkp5kR#(d9fylskS*(Vr@fJ>PY-o79SUu2FDJMsJcCwE_+jjEb{_@aJ zj~FZWjBPCs42ad`9%ioY8S2{^86Dm}Bv$tf3=ZQ@U*ABPgH{di?BUc_4Uai6u$NOW4-OASxAt$|JUk?FJ==%4B62;i zm4~>YjcpYJ&Xve+?b+5Z`d=F!-6_&Tef>Q{XdkIz&e+!Bq4LhY@^(RSIN9O&klp3W z`A;|hS;l|5_)jPQ>EJ)@{HKlowDO-8{zLzEJAXK?ZjP&)gKq* zIWA@|99NeU$Z>UXTwNSj7su7b zadmNAT^twVJ2|dSj;oX7>U8dLT%8fpFK90tsGY?$JNSlwQ^jo4v*t%ZQ;mToj=sh*e~4I z2|khBIy_e4j&4g&|IpZ`;n88??MD&=c+D7*=pQX_8tw1hCSt>VTb#Z-);~yZaI9P& z(eFO|^n%BFMz?W?NM5%u#0|F}sb0~GOjo+&pbPFd;C1>x_M%s3FZy$SJ#mNMZTQ?U zx7^f&^bU^>jr9*~6Vc((q0Ixs+nv&Ir_#H1xOW)6oao)!Gg=ufkB^l_w5PAkJ# zY?)^^M@k~5eRq8^%XgNlFARwM`e9R~L!FXWL?Tc5aqy6}1%XMmI zbgg@Zy@z`ZTN$L{;Hs~bD1$chz)oJ3`>}@bxV7dci~L>wf)B-A_v~78d7x&XmfP#( zR1;|*aGg3UkH79-Vy%Bj{wDR8!R)%T`YT6vj~AgH#^dBS@*B@38N*TU8zE}uCTWHU z=`Zw}HL$4Vy1V3If3>{#52&|yotjbC)J6AN2vL%s;S+n;sZa28ukj47);8LYq&Csv zIQ0Wm`s*ulZ@u-FaqV{v4b@Nd$o>8A_^#1)c+S2e-EoKhDv;gXcWXOK?C!Y-<^x>U z+zd7SuDkz!^Rt?V9x{axmo7C=w;y}VT>iJT=x@^5U3VQ;KCWwT*NWiTb#-Y20qnZF zs|v}eTo;MJzMSjg@wj^dtv5+$De1UO#$0SQHexO5x_mzG zUf_Vh*H~Arf_5a=`5WDH&q0BV>z;r9dG`Y9P}gf61?*ma8EPY3*VE%&jSJD++w0!s zkL~}m6#p5an>U-USbx9ShPQ1q-}RxPA%j0MQvJ%D+}PNdaesUq+Av+WW5*8n0#e1V zo4vq4{|Vb)u3NYeI~A^b`|Y>g3%u~V@iT+=;b#UNz|RbN2R}3DUHr_TL-?6NNANR) zj^Sqp9mmfITD%yWOs92%%Jo5 znL!uvGlFis5yIZClb7*xuTh$x@iT+2;%5e3!_N%*9X~T@20tT6?Z(dx+KZnVbO1jy zXc9jo=%$;XEWmZ@UHsf@blr#WGlP!cX9gX^&kQ<_pBZ!#KQriK{LG+J_?bbc@iT+I z#Lo!2|{bO}E*2s0}4(W_tZGf~&@ zGlPD^&j|9*sf0YQW_&Xa%;|iYn(3E68S!jezTCK`G0`NU37Z40`bK@@&*F@_=quZs zwOLlzd~-v2QGMYXg4IPiA)yD!b?S7@K&>vQPkmh+RoqdRg_o`N-BvTOaA}~_j67|2 zxJ~ksZ~h?G-X`ueUn<%yc9mzwc4Rv~}zy=d3eMP<(6)Qta$%R{7D z(BtI$zFxVl&G)*t$z53wK?rq3?J~zY`THt=FZ2G0?;Y&eZgO6EMVeFof5`XDnW0ce zeUCi2LE%&W7LuTa9tSz_d)V`E7J5_m6o%WSqo^JB>1HQ(NFB)p*0d~Ld`N*lbqgvi^ zwQC&pll%%ca9y`be&Czxs~PpPuZraHRpuIORDR~m;#=~dZx|nu6Qp6*b+l$No0%=Y z*M=n7tr_t>!aB=SbwbWS1(wIDnO<|Y>?$>3cbj@wK|`JEuXsI!u(H`w@BJEBdUFxLy(RShJPLYokM>n3OBpa7UE%iqY0wTgtjtPrW^lvl_L zow=k?Ekve`C3H!L=-5i0ColExWJ@e0SO@vH9F8%ZH1C82O|0bS6wb=@V6`kH)L~#g zW7!u-D@+xSa8e%W7+t>^2R`vp0CNK2kY$D&1IfBg1 zg+$XFA=Xn^%N!w|Cm&4TttDS+ju5NKw{ec3s}SiW%~Kd!_^+}5F#IrP84~g|{6De(BK%Mh77~i^7uZku zbL=Pl8TJ$YYx3i?UVcH|CGdVm-X?fIA#V%3C&_EUdz`!_c;6@QMtJd-gv1EE)8v&C z@V~?U!|+2DGV%@oUiM#ve;4@`@Ncmf@Hf~C^bYm{JWgI5wvUo;$vh#3$=5Vbhyn7o z%oC!YeAYZ6Hj}S3PmmhAkk~j+Q2!7TBlCoKiSEjYc|yFv-ox{Rc#gfN=LxZfy%*;R z@eFwtum$!4n`JMsP;rSyF;9p%d2uoyA>WclAy$&FsZoe0$=A{-#B%akjY4#huhb|+ zJNY&?3hL-WVx&=sM=4BBGz#%Bdk;4X@c?^a3#pmC7aN7Rhr9~dyVwit?d$~><~5Md zMj>t{FT{9mB;S(xLM$d<(|jQokgsLF5cA1r%@<-W`AYMlxDU~6ga{D%M&`qs4_(O# z_%SSFh=3o9Bs_fhv4p`80soKWSA@qL3PS|Kv1Y@|20vE!$S?d@@o81tv)OKAUx zM&gj*%^=#L42c%LgGFgbSbTv+Yeq>}cKrJ14m%xk3Xh<}{3%kxC z(E{&T@>=j>l@Sspc(Gg#iH-1LU=4{8ct0htoPhr$_8*2HCkiM7{8-wf1n^_!kNm@r znGBu>{Lr(Dyu*Kx{e;J!REShi(sC{&mMjng+gTyev_J@$&IyT@1wvr85E9k`AzmY2 zX@L;fRtt%Z3s@>9Bt{kpGOdk@Um!>yENXp$5L*Z-PcIMx%M9dpfgttl$m{}EH;cS3 z5Tw`|SzRE+I>IVopCvD3gs^295=$1cV)l?|TFCm=L!xCN>st>AYaweL4~f!3A)>_C zxDfW$z#UmA1U6!k&xNcu9r;`+#4-*&y^yt&BcBV|(h2gpP>?}RM%kXW)vkd@t#Xj;TpfkUEY5wrv1uC+*zdd83_En=%XA+d20+qVvh zkwvUu7x`SIRg)s8i&$PMB;*urP%F%vgu+BB?5IJH$th^w6YXje%BW95G4;o9t%yNi z@Pj!yeKU57Z8>%0VtGaFwpXZ$@!J;5U)1i+FniO8(1{gl&-nGQnz2NKc2)igMa-}W zuzQKULQTD?j%YRJjbsaHeRE@~SMAc4WKs=eohYn!sXa*1$s^8*)IQ2C+JobT^KRX$ z_vdIu=8l)5z}&Jygsz(-uImUn#r0}^C$-;A_8R+Hdo8IiZ-P;$&+*S0=z_lFXk5OA zxilG4z&~d=lvBb+xJ)bqKoX z<#hONd2*@Rt&XUxsa|yvB{`mIP)Ad8>Lzsrmrlk=KlWoguanbn;gqmJPQM&lp+3_w zzNOx=)q%ORgtOHFURvAgK$uQg)VaqI)qah}W0g}mwTl|cE?Z8{MdR7UjYsWLXQ|0d zkeL%S9zep)p6rkbCm1jpfPsyv3TeTAvw0mGyTW7J+ho6NzXTIo(59lkrq+V>l7e>7 zFlm8yytG^;lfz+FJFLDS2yIfU&)APWL#O%4D{iBs;YDG26Be|LaT+6rR>zAufclgW zaFD~(PJQDxQT9?3{e+w7T?@ormFvY_eHbL}S~FkV)zK*KYWur7eXBbBH#M9vpeBzi<8yxrdgMXyINRb4b$FFYUU=`pTQew=~1t1u6P$2&AVPa^-OH@-qw6 zuUbVYP2I`i;BJng>6i6XLr4;Ct=uCoWBuo7!y~)WaDbUa^iK^TeSG_XI(k#WrNxNE zx|~fKWKbKbhP#{9m+}LQu{u4y0Y;*^Mn;iEmw3xv+wrV5t-56il*z+mYY5R`PEH+B z=he?|c({7k8%UFjDO5wXazgSm?7mgg#3TX^D3iyjc~f1xaV0i_G`G6($4HZnI%RFL zaO#AbT8BwVmHRIWr#Xp_iO28eS52xE|4ad)Jc1} zd)4K2=&y7stLmeHG`XyJ8f_9zT~+%NTU;WR?{GkwJXSlcU+A6v5jpA7u)6>UkVzw5 z(jhcuIQeC45OZ~%&z$1{%H)wMX_xoGvuXlUc}>Iy4IE%5k#$Gw{zL8?mG2F?Jo%18 zWZltTxn$&>r2H}bS4^UGlA9bRa3<F*nKWw)}FAOOv}D9#AF^f;eu2d*HsOdxU2ju=cTx!*RH-IJ;vOaE->Tu^0uXO_Tg_9;=CJ~=Wd((Vg9bSin zeqB3i#-RdeQgJ5Yj*t&ka=k9?Zf8&d#$-VX$?Y9`&-7j+H$KUMOt4jE9B43R7E(@-;VpZo&Tc1>0%9WtOMnQV-Ow7ibGqTXNRnbRqq zDqtqDlTyX>04}~k?f;vb;GLLv3PB)~26-^ol7`x?jxNC7i_U4xAp&L+vGdRn(()_v zXnK9KOB--#0GTwbhuri^_BNc>=+xwKhX<6&gV;esNDKeSiHGI!ZV&MfhX|NSBpY+p z3LR7@?lazuuN)#^CJ~ZwF7fYOS@o5hV52im17y;kGzz%3={{_I=>k6D&;T-NSTMWQ zsos;9o>d>Y#5E2PFq4Q6#oRvpf$|8pK6QF;IW&Mw8cuy1LYNl9sq^Y=NS$?wv=(lDd73I+K^5KJFoY;}8Kei4Zb$*GTHn&GHa7 z0(FvMXEq6#NyJ8)_f>pG9Z;8XVydaw9ft$Zq++S(b~y1-b<#6#U;`ZvAd`lD2v0jb zCQmKc>?YUi@PIOTWJl0#-zSQ4KhAM=KINpt1kPmQ%-F;HSzb|B|LS4>;4pzRnfQdy zZQ<%eb^h-Vg3@WK4;&_NCKI3Oxr3_uwnKjKPY>}|hX|NSg!rdhs~hF#a<6Cnzss4Y z17-3chT?sY_uisro^(^R9U@>R5r!?jL^UD*B@g}GrS>>f08J`HQ5!;7QozYm6Y$z4(A0r)#s~J08J|7%sq|oH~EdZY}r}m0%>xwEALJS##t zfZGebBEL}AyhDlny~+jB>h{n>>Ztq*0z106>SUD*q{+phg14&VuktJT#dZ(- z=PDamlMMlAx6_pe(bQk56V;C@kC8IOyEo=WR_f}{OvZm58v778dYZ;CU7PbGU+b!?TkF* z-5I#f*&GGR^ixKLj%a94H~rh zH@xbdFK=*Y0GTv=3gM=v-jfGfAcUvWd($BTW)g=DqC6z8EcI>*%aaZhIFpGZJ2%Ok z`g$(JaCM6EibDjX+*Tgbj4@5)Kb2lZOL# zmnW}u+^#-#dA$w~D3iC{;EiwT@@`wv2{If|CJ*AUZh9SSAB7OD&Zhj-Ne?KK2ay1m zr!K3B0f;VCnb#a9a3&Mt-Y!#KQa^5oB&}wu4;?0OCi4x0`KtWl1@AtRg1!$pz)T_} z8QdgW1iOsG0>)%P z_QGW?9(y6;vbH!ZU`!Utbh{zEK_c~Mp`nZsJak+BW%j%?eQ(u0rxd8gO z_}0bcMi#1{yz6E8ho%DOqwX=N4Ns~cAVH*atUlIM;Cxib?6|3_z4AMG0bd_g$yYTQ zNFNy@FD_Z`lOM~Uy$5GEJDWZP^l|qa+=MzPPk85@ZJG+4j|!b*0Oyc55<_J~F;=a>?q1IxRml_H94YWFUQHh<&-_+vR0> z37^GO6aGze0rYVpF6DAxkh|qs^}Wlz&Dq=`oR5l6uw1JA^d@x%@?1LEE=>i_M}I96*aa6T$zy2iwz0jd{ju;xm5LoeCH*|DeA)B>1@{$&PTRhoE(vF%b zk7z1zJ}N#9b*T^DaR-`em3cuk0rN2-+vqa;AD!ntf>u+S37C%wQ4F^ccFJGXXZYAp zr>f3qE`UBRzW8ucm0!yV`OZr&H|%^bLpUE5a+xkweI3`J}N$&a;Zz@ z`T5Fo!uPah0_I~vRfEfXMSgOlcO&~n%>>NHghZ*!lxNkUmEQB39hwT9kNTBCRcF*6 z%@AGF6)Zo{TmXGsi1@n6KEAaqzx6OLX(nJkCZu6q=FszR85`k;G!rl%^IL-{&;Mm< z(`xhuI>YLFO$O3OhJ3P{tonXM3PX#g&UZczB$$s0NnW=ds!NZ{Q}}vMQ}5SQ;Cxi* zS8x-RN7Z+!^)54_nSlA25UqBZ>V5U`YL5`k2F(P_$Ak>B%e+G!P*V^-)7gDfQ-SkQ zAw1_&Us6}pVF)K_sywN=0Q$I)3wOEll>A!#ZXCv6(PSWfWQb6^Wc8UmroQo>tf==j z8Au-)UnRNZTj$7c(Rg&G)kRGO&PRn{yGwn(UH<0XoLuN^V-w8Bg#5S5lpk%BM=+x4 zR3Fw<;CxhktL{?O$Ir-jFjLXgq^1Jrqe3X(ZHn^pU2-2@PEGC8RN#D6$gX=*om#WV zvznF@nhBVX2{B5SDc>pI?A`MDR5JndG4VZt%Z%@o)7}ZKyr!wZ`KS=Qcd6l&JnmhO zsSh<3I3E>XYr0f*;CA^hW8C;ja{=^m@im0YmHQu-r@a%O8zA$9X#{XSDkSk-sx5z0 zpL?IpW10$_kBZOEU8<1N>YBHQ$!aQaJ}N%taH(pKI;B4Jo`G%ETmXGs$Sk_M+)HkK z+gK3p(@em8Oz1;!QEvx!OQ)}0-q_4phqEO$+Lklro(K%LEHMe#Vi$UBtOi;V!(ZAu#8O{EyqxOK1 zzC80X){$L+u7er%4wOJ>ZoB5zu43t%V)uMXU6KdXPpvMsps85x`jX{EZ1s#o$OEt5 z4gC;0*%8gHUB%M3GwyLjG;#|*RnR|6-$~i zyk|D*1NGs&TV1j`uF16vS^E0NQ&lI`&uZ#+5BF!ytzF7ONX_#iMAynwm;>uP-vY5i zl4z~1WnRZt%lrMCYTCP>+M%hnt62JY$vstDEq|0>jk$?FrY{)!FcH-I8E@J7sF}Ir3g*oy)@3z%aO|4zS zk{%V8Dz9yS*}K`D*UZ`_ENKsLnfWav2+;){(!|;YEPe9ko`1hIt}ZQeiSn>!)~;Vk z@0|Cwkze1n9iQiN%?No#bFt9%H3(k7y1m4ff3EXxb*bZ;Tf2m%Pbxf*^(*zQ`ob%h zrm6|ou41ve@pQ-X$A=et*P^#OO2i1}%QCNGowIqNPS24)c_b6MG_!UQOWzy1RopG7 z)HmMzuF=%mRV=pVJ!6*od0g#7yU}(0x~A4HV@Z#W_wj6#hhOs?3d`e~Tf2;<&n4Z~ z^wc7G#(OX*uV^ZkyS{4TWvu&TUsRvI{)C%jbwYD%*RiBt!kcAz9GgcT2{(0BvuoF~ z^ueb)zW1mD^E?tDw?Zr$FKq2nmUIcZrIp9jW%Z>;%)LWXYnQS(HS;tlHTBxqZEjiD zYGUm=mOfQ=+l2b#_Hoat&#RhPyNo4G9&RbuZ7zAvGv$YxSi6c<<|_7|s~$6!SeG@k zb_q+LmAOgEWAZGYEI2iKSW~go^|c1y8uo)#JNn%EQQvE3?Gl!hRJadij+|cPkv(d3 zH2D$Amn5%Xol`oYercWK6`^=oGiz6{*pD@upZe-{Ry(3!w}K`+Ygms$cv2eG5F(xM zlq>bGoIFH3hK?K3WLoV~;G1^{Aule1NFS0GUXADU!86Zw@o9(rQT`@>M0e=({azpGOouA0zXTK|gXT%lE~M5G+gH4DLOU3?ISiB2XaKf&BW zmtP&%v0bVy2CsENLow6=`OA9st-4e#hB~9kgfxr6t6c{mUQ`nW2vt;ZPK?RX)AA_6C*4}^8sX_iwa;^M{E$wLm&lc2QdH}S zYOFHayHyA1|-?}2X=3JpoYm=mU^;I>mwYgOa@mORjcIS0X$8-*^P+V*76k_Gd z4N+@DOWsNqqRC`B8nakGHtE`3*=*aEhIFN)Q9Bzeq#T5CGiMc|$$Tasi(91imh{{k zh|W?jo6Z$dX$JW2rQ_MS9nV>$6W_SEJef+{sca%`Rdul&_q&qOoSiGBZRfsmb9pHn z&z4e!l2uh!Y~0UVv3x38ipJBHN7=ps=_=T{Sg82JQHrLmH9clsF3-mcnRq^#x2oFM4QAfT*s*xpPM0i?hIs?hkt$_lsYo$mLF2!1 zYk4f5h-C^%+o~#MHt**m(LypFFYtY6IX3PuD-|-iVlr8@92L;U-L7J;5Q%3>X^Slh z7&p7~iA*kADn%`AU%+>}6ieoc`M9N3LL0YpRw-Lb#`2k@F{^6jz_{ODvSZP>osC+n z%Kmm3PZbN%c)?(#d2d7E2SRwreR`(R?wLPsK|N(3S&?l)6fGwqPf+NsHBn z8#kAiViCI(x2nb=jJsXAd^#3MBqGjzBw^fNR?1`|iFmGLIp!sd zyWQE09ZBS4QA-=0Fm890Vs;{%E=B0JaVu|?6462=RZQTXwoqX}x{K*_sT7OZmbP1A z++JQPrb|&f7O|?E0!!a zLQ%gLj@VWv9Zx5d$+Uy3-x4BGE0@ouQ<ChBJsSPE+tb=f_2(i#J1A$WF!+W7i#hnOiy5mU1DwHCTVk)bjfvalXh^niQk0(+|J7cj; z5aZ^uTq15K3#p>zSPC)jcII=rXgrsRS!6%NxVO9zO(zp}A#GKyiWv9vRytXV#dC#( zMW#G>0%1T(R=gOslhJgZA@xVSl9elFv$c2L?hi7&2Lt`LuBvjq>TrqT*lB!<^E zn{`lZ$i#@LXeDBWNG@6^IT*)GfdR@}nQXS0Ntbk{$b5kTSsu01*|eR_aWpl(^zvjW z8_mZvd>i%^406I$lU5;~Ybs`pu_f*=V7VvAm{Qd~qbB(R2$iaerAXl}ThXk%;A3kumOeN3w-zA(hKn+O~{wJ8vbUsZ=gmC|ESu)p?Gc z$z(B|DV5@kFz8*eXu23pl%f`!r!j9vbD2aWo{RC#Zu4d~Zx`%zD$h5UnKyHZNHUg* zAyYj&mv@;rGsRdgnJpFhW~X^Gor>CtT&~17JItH;bTX31#GayUH*Xdqscb19%ka%M z^JXcVNM%cpLcWxY#yQ1qf91ss@kGq#ymtF5uT;v|cAiVw?XSFKF&c}cxqiC+m6yrJ zvY7awB;EeXvvcW8(&lH+AF2gk$5b{H~qC2&nDt2dKG$h zF7wx3Ay-T#bDY^_{@RO{N<}-xFUm51?d6K`LL|m7$})fL+4)R5TCzDq{@TkFqPbWu z!Z&@jmr3PIIgBfKV!mR=GKFX|n&+q4<*z+EpGm~h{4~4#wU4;s(q`4t<`D!m+EX31^BEMt4lEiYEcmaz))NH4}_M+)hu~6V7JN>nn zh@?u92)Ei!f9>V%eBMrQtL^lqnMp+>nOKIOW~aaQim_}qTHwrf`fD$e%EjUle#JWd zwUkbwUGZCl5Z1>k*B$G`Soc^HQUwi3vB$s!Zd%M5(V%dBV+e3KN z?f%-!=2C^Cli7A(Zu5y!GM>)zLuvQdUcOjJWs3Yb+x@kd%G=RwlpjjFzxIlSTqKv| z$Jy?yy;2POO*&0q?G+2Td^W;;P@BK@QhB?SOK>05=C3_FkuIh(oMfB7_A>EUAz9$e zw)tx>nk=Rh5iVw%zxHyeL@u7-3TpG$UOX0$Ml;+F+I&SR6r!a_tiTVY&0l*-I~unm z+-lqWwO5K{Qjr9=+BRS96|=c?+;$#{FVJxj6T=t^V4}#A0^V=DxPoUwg?^G?UMBSJLXQy;3rh zEu^^Y@;b5!%$1!X&S=ofi^*inPGBlncQ2}=WJgk^l%1jb1~q486X|?D zQ;b-yIX(liJfBWxi=R6Y`o*-lLLHUqF(Q%c73r2Q;#dIc~U_{j%qJdf-N!!tMCYmQu?c#TNx)d!Gvqes(-kxhQo=qkr z1&&~rcAkzFqS0s~X4PyVbjRY+VkQ@{wDCnFcO|PB&1X}osBM`x84Xltrcg>pbJ+|) zJ-!WyNXd@bsbbWs+HW+tIV+kf*l{~rv|O`}24Z+{O5}9JEn6yme zk_M_XQc4zLX*&*3uUWlaxlFE*ik9*g8=^Fc@nSqyO6AiQnWr@GMYHjQolj>hGFoZe z!y!c~nU6&x)+`&01uIcVXVU3(*7BOTG-6p^j1{x#e6nCw4PWy8%GUC#WMoyjcX+gK zObm?=t}z03j0~HBSRTW5vRrX4MKc|3H~Rv|hqm_*_4z^_Ofs^0ba)VP z`N-ZIW(1x)J4Oa^8rw5g?j0P_C!ih4SOmRD-hxI}F4c~a!Nh2}T+Q}hmNu>GORO1A zKQ_GSmB*XlTH8B1mv?u!bS$UKs%vd&>FVlgYU*rn?c_kHDDRW|ZxQOqeNU9+7uU0H zYdEi#S2(Cvkl*WbUhV#}v}uW<>=h2@$MYRkWZGF`NyIB>00(XMJHtZAKO9+8d>uKP z<@hyo1(^hZLoQ~s8~+w`|9|8N+~ORXfSxmRIDBp=wN5DQtR|S0C0K^9$@>&hBHfa(+n63e~SpI5+J|wbjaHFGH3C!855mpSI^x*1MBWmY`c|yG6 z$9cp(;2^Jf@zwXjUJ48AK%GdlV9jEEPpprXUn>s`kF4J@GPr)Af75!mOA=3rCvN~; z9j2MRMrLWB3D znrT-PX*s2?s!Q@hO8ugaK==8i+@pS-gGi3NRg}}V`XeQ$p>R*gU-2ALz3OVZL0wgs z1Ja79-`%uO z$^Tnv{X?hqfX*+RqPfr(SGI z%c-#k5#yH|)E<->ic7M1QxG|Iv*Eta-l4?$=8XnAa`=}~>-1!{KRKPaa{a*sL_s@y2|sH>szM^kbt-AGF1A0$aeZtYDe zIrV&_^N3cc6O~4^$tnHJrq%Z<-BH+VnKnwwsZ#K82M@7-ql-c%=bi!NUEPHKfZSh-FIPv@E~_RA?U!y(^wo<+4o!DHJ? zkIi1c;pLZJRD1BvJa;2#+0gYDCJl^G7Z@gGZ+KtBq(TX*2g9Uu2HFe5fyk zey7xX+B?05`VHMppuLPocmTqq-tTFRu(i@8_o%ZWw5-Yv81_Qr=yh_<4|06!+)X-S z1bUyU`y?rM=7U5rHoW|z+Ji2VA0iYW^Fu_Jzz-4XM)@H^?;rH&g-K@=KMtrY;;xL8 ztZ-jO0@2WI&7BF&sjL^L4-#dHtI)!Y@@&7Ui^R2#6?wZ zw(7idLChc;LKuKB163E)5qT0H2kZ94<-)+y1c7ePycl;}$?B)nfxj%pe4{E>>?oOF zoFR~mbyWk&BO{du)KBU|^_@$E=59EGkq-}m9b|tu508{x8|HrDV=PTv9l!F3+P%i3 z`vQ*~4k%O3o<`fMYIp^M;9q-fCupnXz|9dGM!cEu=K)W;A*7}3E4R3ec9!~z8#eSxiXq9yv9s&AkJ|V^zU@Je>_A-XQ<;!tAvngmHsj{EPBZ4;i*&r}jCK z-^fJIdym%WmggyTUi~4zy0QAi$XX;E;f(T7-BsUv_2XTyZ}#vmIVtKI7Gj}(gD4Mh zFviIa#esuCPj))wshSX&A2l&BVQPlJDykVm=2hJweB42+F2PE0%nuH*ENBQ(_m8*n z5qYH#Q)j10Lc%r|+|4!BiA922ov*30^B%joTAA{!!y}YYnfMI1A%q1t5>XTK*BjNh zE|Y9G!4ZypWd4aA>Iwyd@_9I9f38qJ&Jm(GQXaw%WTJndx@BmFIlF~M;D!y!)v2DL zzJc;+bZfbHo8Bvg+-x*rr;@Rp#VeDQohz5W+PkuIWpgyTvN@UZ1-bt8iuiRXG~ z^Dqj%x?HgR3-jZ&d%gZR*z6)>dPi`a0gG?w`Y59$dX$YWf=1 zaI@}G!%nK#)!U`Uj6t47@9p#un2yc1b+>Ge5K#w*zM$UrDyAbn4n{lR{yQ6Y(8+uM zzuCBR9@2ldb!V-n6**~k#Ny*4bs*Mkp~J<3`DkTcN*$nDphYc~!fUDvUMyZ7_J$*Z z>IMk*+pu!cD-{1KbC=pnslKT8z=#S)?J$`ez`!3SP3{X4e z56_HeIHCD-#C&yWPRoCJ;egyBpF29`M^HtfTQ29Fmko1_=@9O?nP)sOVdW8tu@P{&~hUE4RBEl$iz(Y$U#6QhRhbfa}*Y`ac~r~NqJ*%NlNVQ^@N zA6F+nc^nqczwje{F(QX#4_zJeBkRPeF2Ml1KH{9M)Tp03>K*p^PA>77AFPA>zcY9^ z@5O&Qcsz?O?(f&3N6z%FL_xaTw(OY=faE~-FbX0C|M+-jwpzZQ?*j&`7AVAQe z(uf{KXm1Sz&)-}&S%4j>jbrl7<{ddXDZgr_fhO16*W6)a916LyUFE}`g(!iuODCt3 z>UVW6jt#l@u;IH`UPC_)$ibYP9B3}N{Pz&*jB)k~^+| zDRQt|TT00(%HNdE9~Z-|1T~nd zx_EP+i8nrZqf7{SXrB7C=<;9$2aZt2#ELgQ@#vABIv@|J3+hLg2@?izgfpgcc)0FV zP93W}@SIB{h0}0^GE(GSO^kp@@u{`)k~;4pLU{@t!Hfj;wq~`Er%Eg3M=q6)W#Js4 zkt%Oc>T*7zetXKhTTRMv;0R`GIwXIUzst)m z^LD2d@eICJ?Z)QOau3!;>@bb3-Q$DPd#gNW-LSdOvo#Htcd+K&PdzI$cc!yWet?-H zynBc423)Uh`4qD!A$P{y3cG@Ec(`-La7dU_*2wtg&E-)&W$rQ;@%kojm&|gLrZdf* zf5x2UCNn$!j5*6qX14qpbC#RTG-mC(l=T(|&b>{;<3oM4mDWGBCEqhJFx;#6)M|FY zHf$cN^i;Y!`rF&k@(26Jdi5FruDYYq&HEPGX~Da;_RcmAa|G`e3UwHQcW1+*y0WUb z5V%9PBkk%g1YoRXrw>_g9f0FcvRm(Uv<~o`GQeRpf~{Wp30j!5=T1Q1tQ1S^HfIH( zT|IF+EW4utaCnth1;8P`mjmGNq74SXp-Xxr01olV{q=yp8pI$VkNJT0sv4t={0J+l z&m1(~e<1%mGkch$x_9<%A>Gpdvspdny_4-~G6oSV+63xee77a+#qvt%$(A>7dvf{P zH_Pb-a&oc!LrvIfM(s|k8MRAJ=Tho$Y=t^Hsy>SoaS^V@=i73!QC>w=sXgs#LhX@z z)UGfNw6EKq&~yD%ui6C(1>SQ=HK=#gjQTt!r)l*@Yl8o8-)6FaP}iX`@st>w{w&9W zsV&SbhiMAUf>D@@VTcaXNjIh|yjz6K%RnP zB!jF?18ut?#Rlpccz%~2daY-mzprWC$Y6YQba)g)Ms#>!cr?+|KTz(&Wnnm99vmLs z2|qTs9SSaS6yX9_kN5VL$HuBraD?)zntBZnghiV0aCqtPzqn(DuFiDcHxIp4LkQg* zocyXO4dtE4$c~Z0p33kztZ&glyQ%yPZyxJDL&uU_*Z@7}puy>vI9xN-(+sg{WK|xJ zpFg@vALEMZMjKG(6oKcFNDA)uHy?rx58Z#mt|}Zrtc43#EYE^aZx_rHOFjQtvErqN z+<5e^CZDD^=L$4wfTdUz$c%@lnL0yqLS24os~Z!^>cIg%SeL12p$Av`YX`6Zm$qG+yKRsSqcG?$y*7WIJBv=(rS z@(dk3p+$=UL|%|ztG)N}g|mH0X)PpT?R*x;8tdqD26`h`S4R7Xw&+PsBw{7wu|gIa z3!FE5WvA{9j6=YZl}*}-v~9;Mvy(7Tc`I8;rR-=n2bAtR3`og}+o_0M%A^7DbSVa^ zXhqVAQY@Q_0Oj^H1}JAGld)tZQiucObU+58XceM%Bo~iofS|68YJou;Hqfqbq-U&* zD$4b58toa~xwbqy);~NXa4_~in$Wd&wi^?=1w5gnO-{5wxOx*h^^@*aw3~HC_l)il z99M5fhv7s1?gQ4FX21X$nK)kK%;?aF2}qM?od)mMzKN;dK?jIG^-i-eHpy>*yy8dJ ziBcVFfCgMYvfc*k9}Pm>i0nD986{pP%9gMYPx^7b2+?D`;9#_)_&o0%90ue~K3u(O z#B53Kt^@o(F4@oVb9P4s~oPnFKw>Kx>z}@T;rh9^yAo$jr;9D2VYybGm(x$On9(_M=y)X{(YgaFBmOP;y$_hq(Z~RExjg@`Ki{9GtV&Uq= z&sZo}o`W2<&23Q!s25r+uie`?HWybo=9bs)MNQ9@yXK=@s6qqSj4K%3OUbFo4zvb5 zOS#)Q>7{0ZOX$m|2BTxV$%zp>2t(T~aw@WpTGEv{ODc=yp7~4URHRu>+D&pQ@}Qiw zo00l|dESV6f>R&MpC7?7r0%Nq`wj_BbC}1Sh7cMLe1BaaPhxLP^R!frF^mL(UeXc;BdS70Zf2faLCXCX;5za`Er-8bF>fjw}LLPC6)l*<+2hx+Kp7tS5 zxNY*P+H*R;>$m<>=Obo#BOpi3ZJMuX=R)#c==TsV(&R$k4cC+xgr-oIfoBZL_ zsCZ+n4xTp5jBv*LV{y01ykG|v-%%+KVVXqW%C0UOvPRA&o(4^@JhP~Ow=34#($!&1 zqUQ1>>P6>k8@PIND175%xVlp)>|sIP((CF?p|Dg@M|{9~V?PEF^;t-Wo1OU<{>(Oo zdT5RioemC7wB8H~E!-8HWCz@TXD)#`-#=#G_^Ce3|72`N9JPA^K7P|p7TZN||8A5~ z*ItlcMBR=Qbp|)vD5E=I`K3IgPO6_=<_d?&<4kR53y1GJ*rCg8&hgS5j=NthWIbJ> zmdMfFk58!546g012=06#Pb&69d(iX+mo3jg8?Qy1x1WHD2k6jqP*Nq zhD^vLOdtxn>=guru&@S*Wa8p3t_cYV<1mVd3W9>-gBVco!Apg6s{gTjK2_b{*L(+X zz3chidwb7f=Q~yX?&|99PgixT9b5W#4n(Bl} zq@3+L8_G%~{a%1HOeEo8FjcA4UUZE)3n(XO_5-+b$Pkv3G+3qRD??;M*glB8^bvq7 z-cT;@ja5qR6pi)PS&teb8^W??&rtM!l~U`Wi10)xFJE8B>+=I1!Y~1gc}{0QS@Ndb zql+P+f%H3geg5%n(!^}jSF4qpXy%90<{?Qw7FX(-Ae~3oK|q4*>|8S;tbN%1^Nu(? zKX_6s*EKa0l)4+rm1)PY=0VO+8yXwJa^8i5yb0Lo8)8VFavAG^2} zC+qMS8+siTW@o9erIxO~_`(Y>Q1RJ&(S>7_U#hR@@6dL7P@lU$s*h0qxfm5EYWRFK zZ|2ap$GJ87t5Q^K0dj6jhVreonXP)X9n?eZ%XQ)P$=oGFdJJ6^!KZ)dA5pDe=%7CN z??nvrt4Gd1B<@dhlirVXPv$0Ps4xvb6s@wEpM{c-@|*l`BmMdeL+9#|nlXSN{l6i( zBm=BnGdE&JRMFH1J@l-3(H2weRb7-(2HF_-92_(88fODM8A(G+3=J)pcJ`R5&yZr& zx-=4lNB~$b%2b@X4Pgo6KGNdHWHGjhBU?8~iDA-7;s}-!AuMg7jLe9u8Mz5+#=5wg z(O9i!ESjPRoSD?a10|Q7Wo9=TmS5g~k8U_&yP*K|Lez%hzFWGmXyQ^h@ zRMS=ctG>zq8?U26OMH1tZ2uIbXExc)Q%7Z&Ln^I9)?RQh(2kn9NYpfYi%uje4fV6f@Y(#8_%3Mwap~;plWj zvfj)at}HHxU5SaM-UfMSih4;5^-4*-!X#!cS?kv74det<3$T!|GP5J=ecaqxDc3#V;I#Ef(Lf!hiHWNIS6`4 zzfE6wj_hD`0HI1aJqjD^4epWV$NJ|-^pz^k6ai)?5JbK3YH;Xmx9l&xwv(>8Z0K7A zCgNjCND%~-)PGC~eK{HtSG!87?QhaIe|FCSEHq+5$pdgvS>3X~L~l>iM<+N%x0fG= z&R2Lj8pYT|mUMbQ9io#iD;w`YU^?FsFy@Mzr#?^D-=Iq#PPo%UU^-u(atn@LMV^n) z1wHh*%P2aFqrQ2&2!hPbvX4I0ryuk%!qFxIllgK4^g#}~5vnHLv)01~*K-I=6ms0* zofX_r5ndlqc70YKi$b}vhc$5%sVx~^jO%fR7u}$OK6!7g(?>H6Ba`{cF3-&E9H7yb zt@=loZ-L>H=WO0%a1_-)zW9VJf;9k4bZ+nKYuu8jOhVI2O3oeSl>G1Xlm2$qG^gOt z8$Rhy@4S!~-ROP!jSj4L%S}TjrI{rK zmj~W5{*-!(Zfw$LXF3I^V}?<*UvJ4-Gj=A0KCcJptp3=;`mJFV71}#QA=ll;(qAlG zLhrkb`jBB{GGCrBfaTuBY}Y@%<}IxL+%PhkFGp6{oLZ{K^p9IT8UAAUM6vT$lCKS& z?pds_=p(x5a!xm=+j6_;?I3hVm3pE=+1m_fMX)D#&WA7z?!Mk#nJs-g*7oel*#vx_ z%;}%^8|eAOuWj$1fAm?dg~{M|`$RnWouz!TzT~^mmwp%eU@E3yfzPI#?Ync`dw1KS z1wQ(#WJnDS*9#A}1H7K^es=c#w;We90) zNekdkh`tITE$srVzdEc1nwz~|i4kfeFvBXTn&la5V6*Dd172kZp|wIO{nbRJ78v*_ zMq0VU;f)EUb{aZ#Uf8KLuBB)+fm5j@P-*mH9;x7O@nWoq13J*T}V}^FheQ&C`cKo3<^d+&A@mIQih}nD?v*C5Tp!A za|(1NPY7!tSjn3=Q>lL$S_tTJtwU#L;`ywhyj532l~ejNLkW=+mbbov`7jRBG3c`1 zr$8YUe`~f7XE6tr5S-j}QT3->6s#n6?@8WQ6z zLt{f&wW&~nirk~rOk=zhB`ue8?Odhi;Lz|kLvq<%r8fyPt!yKdxqzO%4e>;~|BH#$kK9CzIM46dxXlw|h!&set2Xqh?_m$9PT!h``t&~+_f8QQR4WpxctHojVCu_AX6P>SCb z9<=bs|1kVs{@)UC&L81Xi6=1;Uh3sY6w(qW&=JO#!yHkBO)to=ILwe3p8H4)&}4~q z!PWo;yXjgsEF8UfLM3aJ z(M6?f^r|^gi-;iy>BfkH$syj6L{v&lbJWw&(kQMZ#$X8fnjFK^AZ%o}Ht2koim5u> zRMMg60Pv#s@Jr%;*bQ&3<*QL#Tpmc!w(;C zxikHU29~K@Z3-6N+aGO}yVxN;T%X#ghf;K?v#yhht#u9hsB;I~Nd+p-uTb*HFttSG zoDC?^V)S~j6yzn`M~3v+%8JHKIc(!gU! zw`O-OsFS+oQ#7zt^%Gt^cKU0E*5h{N+mmL#Y0dDhW*1*h&(BhRTM}2qTjCiizJX?s zb91y)fqp`}H|Ud|J4{r26#tCiCFXHDRGpw3Rr;nLN-x*Pv6JLhZ%omU{#oDb*C%M; z&novQE=?0OOy_ax>@;zLZX}TSF>_0&Z|ZkxNDqPWf*zv+wg+@*V_iEH->j38&`;=- z1YNFLQk{Fu}i8<+Qoyp_Y9`Fy@_f|->b^h04o64tc0CF|^k8jr`eh+ zw&Bma7Syeqpeh?drZ_PK$RJ_I(k?LwXSwh4QX+(9DU^(qe7-^-vA9htMEKg4FIVr; zH}N*4kcv~`IYg%GBitbQ=W69@?j?Sndo>DqQG^Ofm+8HQP_c&f(cC?W`*D%iB9k&f zmoxe%oF>$A-^7;bxBK-N4babUKA>`|nHD3Re_t%Oo%&`=?J_EWBtgS_BYZbVLzn`5 zQ=FT)EZz^~gS{8#ROoF^q+h?o3D|B#fid@7_5=+#N}8*XwOSJCf7n54Aa8%l!kMMQ zOI*;@lA0Xe9ixt@m^U99plfIf%yBjnUw9*)Lo3=V&jhXlK(Sm8<|^$tJ?A!v*8n{e zqY-!(E!TsXwV$EM@!VQwH9oy>q_$hbTy27G#M8_5iC{C?f^d?^V2Cq-z~E-u@3~Os zh8v=v(e5hO?x_aav%o6>-I!uZcc6cs^u4E3e7QNDV9S=%pCZkVuo5_C0fQwVJPgHX zjwzUzHc?o8mkIcc6T>(W!hbs7=$sSP!_M#eu=^D@A!SyxMO{8KumKN@W!_2*6A~LZ z_jx`ZODbt`Yw^Bi$fx7Vxdj1+j4o2`h ze5k@gWtgwqcy$CUXJ>r7h5J~14=;8s;d3zZWxSv;s-y-ZdQ|4u@qT^M9at>f8oWQ} z=F1GqJ(OCmf9#u^qC*=ouyqkD{Xwj&vJ@f@*N7MAql+N?z)fCYM6l4W$8!*$n1Hj~ z-(l&;QzoQ~#SdtlHYiye^-X_1{Yb`5z7o~j%R+HY zEfrTn9v3$7l9$8s2e?IQV`{@DJ(N~9$wXJA8k;?T0qJTN$2 zn*p-+q-vs=W|9Gdr9}u&UuYxK;%XYN<^ zYj`QT3Q=G|Q!tl`i8Dk6eZ+n&_3XorIFSBJdI*ifW~E|m{|(n5Vx5AOIWbB>Si;e^ zBH3)<8EJY3lQSyKljrE{d!uSXWTmpM7*KG|>uvs-1wb8pb4k6BdNC!gF`7f`jFO6E zXwWya@TtO;ypHL`3Q2;7VM8DDJ({3lT%2dA@LC+&oVCYS(C0)RK$JjFrQ+&HYlHqG zOU0g~d0dJ)!7DG4zPenGEv;q+jVEE%s}{&85z6`k75Zuy=%0|I z+pFBTT=)bHKQFBTO@m#ae1KoA;2&D9a@8!@^hj(87}LqRcFH$VUchmfB|POkUQP;h zDoMw=rw8>g24`wh>SdOLFK^UCI94=M2X9|Q)qoQXmVCx&B7MwrhrY-66CBs?I@Bxz z`F&$d;boAG&*J5psh>tv7_rX~Df*HVqfhWVL~Tsb6_=LZt$8LcpX=H{r+5;wxRfXh zwvS}yK3b#hZd|MGj$~A=zBpN*nW&Gz56M8hw|a9Gjw)bOvO=CDd*`zSInvNl?wXI$ z1J`mXDzwkxN8!t`@walR_!m4Pk7l>F&GGb9h6>T_)=hI@?J}zLXd5;%4iwis_TFTG z&GoLi&;bV%h?5f2Ah6$I+77`!UPYj<+$NAHHvuraQ5R(A2Z+ydoKNvc33W`@z)Pn- zv25gM>(y2H0BpjEw?SZsQ|LIW@vIG+>OL3Di+X6#7%**a%Efl$*QXBIFG z=ZG|qz+CsU)?*d&rJIDUyP`b(+=vQ{@jKYErGcP^FcVKkp>;{n!GFnwrsBSc9^-Ka z##n+5{#|~#T>`7UWTpo^jnbemXO^-#np_*&{(N#hdSR#|6(yTwic1Dubqcnu3LC9>?S3vt!RR;|{`!M#ex+u~d z@L4!>DpX=Pa$!+4vui68~-$bdKg>@x?G8)K{_OBh#r3)TQttT zg9_<~fv1)<`A;a~#3}Yaiq{6|hj}|%&?Can3Gt|9|As;`+fCiO%jTVKn92cRDo(Bj zH7g%*0;Y#>SZRbP0Is5cysVT0ygtTAbPbIn#+XGmMi~<=Q%LCwM(shS;9vEy#IfNu zLLdZ%c+ak6+gk7Oc7H}~srvB26UWzC_&y6X4 z&G}kgVM$k2*q`AU0Maz3`k>*6l0{(W+bA1&0T(sPL|Ib7u#&3*Tksr2x`)a{S@FX1 z5@kZp!-g`+|0K!BD^z?P&V-bc1#gKws<6^r@K3Xrad-^D_$C z*$5i7M1M!$KkM>Y6Jen8^9j}&=^^}?KBq6~bC(fDKsbQT&x!HiwhLXSk7;<7hZ710 z0_gmlf^Nol1btS2`q)elBfk)GOow?JRjw*r+g|^iNuTP&F01}Vk~D<=Tm|2Zo4Fj-#ZN-sQi2Yy||9j=xu#Ye+LO@Icdj!-0b)S4gpktKCBupdRu=wbM{u3uf}8y zq6+1OIzgU9BLF)A-L(4kH|SH&fWvab#zgA*mbIJOx5=oLF9>bMp&-8a&4K{>5sd&F zg*l`@o}hnTgu6Eh>rC2kRprO(;@-~1>PBB%qd#&TPFdeEOyq;=3XmC>v=~@Z^pRI- z%;o!s$-}v(_n0lhtYbaU^3Oe`)}Pj zydvd*7a88a#bk>YSB9-rG{WbqGPm`|be;}$yDdnUP08*l0d@P~&TrCr{RMq?5BCFt z9yXli0M9(?L3mo9Tcb~SI8Pc*K|Figk*#hz5bHnFg-shgeBT>BvCZj4T>y~bV!CNq zU#6dSyPOk@m|!wrhS=4(8PWxPf`*@Q8S4xqllgMQ^^cq5eEMqpV=mib!^T9u{P zQ^AIcS({z1)rL#nE_$nni+p#GSUVCf=T^hXbbydIvaL&{cm(({{_p@AjQ}f#b>eY- zMSqra$HN;YrH4v}15XO4reFPE)VB9U!L3e8UvH=PA9K2lUmtQ{I$wp@t2MVEgzaMe%M1FF%XzQS z%*6LK!V^|k<1%=y#L5?hKRYybRq1lRm`1P$*}2O8M&Q@65k7Fi61#^+^{4tHw-t7n zw4Nww1;9t#R?vqh(TCY5oL1;Jd`#tQ1Nilb@@jxKpws#)eWOQRPRbirCJcGd)R)`4 zduy*XTZbwl(5Jpy^QRwtpI~IxxI5-*`x^qkL?bwLL3%X$vOb5?VY?{mQIl4ENkiZa z-ED|I`ei|?-f0KNq6$;_8UoTp_z?Jkk%!OvBVsDw0~VCjUv~6wG{PG(-b!D)dm5eg zl>J9j_J)$O0~h3$U4OfxhORU?g^wB)o2h(d$4P`Md=_l1dD-Q<*Kje7PYwVN?&g-H z5j{XRUB(8($Yj3k_`$LxdFY*e`k=nxGOjX=@~+t{c`*Ck9Q7z&*`U968MhinCiCTp zhn5~!r623h^t<{Cm-7w7$#gz_A7<{{O;m>--0-5EnD8HB_(0`X6JfTGtNPWIF5nsj(xQ zX1I0&R}(c9gp*v)9mo?W}TcRTOS8k7F7@?tFbm3J2bO7rT=$G)$3*Xr(lIb)*Qur=Vx znD?{fQSw!_)nObSuC7*>lP!9LqnkNNA^Orq)x7iBt%Q}$AN6(`=_hX+>kH-#s1R`|jxj-*=(sZt#6~28Hjd zTP*MArlw6T&70~Q+q&9Ubat$2Z^mJzZ+bU$b+mP?XkXcepM1Y8ZtY5C+FR4@&E{a! z|7&L|lkG}%q##Jra^fijcP*%E+1tKyZgMVix|H15b(vaCOBI0kh;+)Z*sq0Iowh zf}5r^2>B{;sCg~JMA*f!zR35a1#ZAh11{R~G@R6Dvvc*(JW!Y=-N_&v2c` zriUDpV#RE7vs`B3zPYtQpG1bIl8lr`nx~S4yDsw;NO{SL@$=^EF90<$tv+O`bSkL_ zOf^m=^?Ppgh^f=5q&~)Fg_#^Lj+2YK85e#Z*@6|*_#hb3d>UBfVj6h2A{~>0qH>1; z;5Z1rcQOo(5pKr69n=H+rm}D4&3u0etenMtNPa@B#~;s9o~^1O2aY4RJIqH~+R2xJ zw1-Wfc+eDsdYHQp_kQrtiPK=5`^8vs$0jSL04~GPV@%Q4#tK1|F|@jz zsLf7RtEt=8s;P}#YHDP)sxkW~w4U4Mf3UqHtX2r?^=C8aJ@*8_tRU9lk!S6~FVP4F z8rCa)ihf+-wGodS8-&|g@1^%>{299L8sW9Kg%E!JowZ#0VGv_U(U<1_bGysdV)A1m zjsxc_!JhQE2H)%#8nQI*Cty1zI8c&Wy8iqoB$03E5wKt1QfqYQ8A(vT;!zo?%l$Uy2OV$ zTR?^r^MJGT&|i(-3NJZ(ySL;5%$qi~t<7xNy{)HvFMCI{X5bx1=mF#L`+8vnK9$Su z-T6v?uA7a-vp$TXq;_wUJPa9(+;?v2dli4esEMBqU#!LZpmFFs->5kCvL!CtE~Ny) zrYWJYI}dJWt9FOEgfFLdH!kse4l-(Y`yZ=y;}Z2wv~IYnf<1mZAOrN4O1HiUCqKU! zO8lps+I>$v0RLAeDjm-R!HN;MfeoAv)3 zmHYpQ6LmdWfyU2JzN1!;u7LDW|830~P8dgNSX5Eu&Z;d|zPZ?Rdut;e4@T>r0Vs=ybDq6)aS+hi<&Z1}%SPc=qi)O>yF zQGLMGac-xlVwgZrr5`)~uE$+IYdhz5YO4NuvmSoIRX1_vi~xb_*NkqdrQ$6-f~%$C z6`2I9M`C{Xzc4s3@CjJ?z$Xg_^JtcMhUBMWSbpFW9#RHAL8$pZ@uFgaD5-ecE8&in zR4jdHGW}5t4gB3r^D&du?Nn4fM2Gc_zq+dCO2haYHB^f$^Ju70Kz+3dYN&vPK|?ie zwjFKEQBkdLZaGvf|9emu3nuXYrlMM=b-aqGB?&fA2u)C3-O38TYiiH&h*CyfUHDAn zqIy0iHmAgo%PDcqQ|8eGLf9#>{tAob2=&8XLm2P}G8k0)%1b)9e~D51ZX%cThzAYh0-bm{zw?S5d}C42=z8 zWrS2%JVB`~f|fHWmeZ8qVk#>5h{LpHoa4}#LuLb$dN9ohEUN~?Nj+yF2)bAW%)Auh zeH@$_Q*PzTTQgOuyUlu5t~XKCr>82_8Kh$wBYD_-UY)AcKZ10Ds{v?O^nqPOO$cjx zU@>V77TazbYKX^jRnd7^Y_sW>s|<#Z{^1TX=R204rz-U-z^&%Ir(E8!*G7Ye@K#yV zX+vZ~SiRY(0DV18sSMicHbZXvbfxxs=)y)D20I;@4v#%S%8*W^8`JTWAV?YLMhpvm z4n$Cny)!K&$+dMrp6NDxV742=z8&6BNGY6A?*o#V}y9B!8DnJ4EewhiVhU?5|l z6W7mGYQM4Jg;5rkF@v;dWUf+4;PK44Y`L80CY5>&Nqd_nkTX{~snmubT}TuDGl@I8 zAYmXu7As#EA{)Z$vLLP${gT9u9{_u|X~kVnD)k1yaJQ)oee@)3O9m-JYNPW{Vzve; zL#m^HFhn+>I)BWe0#0v}<(>1m>;3P$#pBZid%0m9J;0(7E-vI{Cz}p>9EL_{V7baY z#3pp)W+6d0YH-UTe=XM+`{&WyZ4oxgt#42T7HnBB8e)M*jB9)ja4eKsHT^$@{%^>xze$< z#`VVuzOTVQmpb`f&DS$bW75#$k8lD=1}rd-rmK`G~xP++eInt>*ze%qHV6;TfkCc3>gD5`);ARv z*oJLAxiEkY=0Rcms>gg_M71%qh# zMJ6Xe3JDs!=pi;w7;{^z*3Q+ zg1Bk*B%X*^yh+n^1TRdED<~Ahga}phr*hZTdjX`ii)lJ7d_tOHZ-p;^I0AY8A%Y68NkaEto|U?gZ1!t zIT~}>Gw4^JlYz#&S`FP9* zd8Y;?PhwE=@#{gZkCbAM~eF8SqxK3R!>7mu|z3WuUzTrW@ zC6!c4Vkjr5qhi>Qj#h|e!&xu9m|7=R&5YCgscihO7fKGyf=+;auuB-L7xhg(U24!L z@gvLV%ehX*eRlCmyFLr+v-{vB@}Rz)dqh+dECuaUn3#l8I@C&qEFA>u^COcU+x^9q zi7nSR_UhA6H&V;>r+XPO+QV!1{$v*?0j(dq(+y^SQpaYlHoUwsqi-_k3|FBr9T8*C zz<3TCQ}l`Rks#w(6|(`R0i~fNhK3TKhSt-my+gvtacLxm0S&Zrl&Ls%8^RLCZEjRO zU|m$|V>PN0x-s+Ee2}IvV^m2DlSJ}Cu#^a4*$8E1N?c88oT#QOnxrq*=rgccvbhS@ znKz)@c~9-wv+Lzjlp2b{&5E;bh}#uj(e-iu!HBOj&L8KK`kZ0G_%;j9Rriz8sNyx8 zD)#P}78z{%V8WOVCvnFM(I^{148M!KiAaNz?aEze@=St;C&R=1kiHs$hJ8tNiStP| z0*3VSxn!3fq2b2O=vEriH!2b|vKV`dA^mGCK_gGXwz09~`IX%PbX4&|sBd7{A9oCP z8as6O_^q)zt-s|}6*yF6!Na}@gY*g&sxf(UIB>Zd*+a z&z6PTfH1!oA9;1l zTV~9q6Le)xAOF<6657CV{R>FY&@7BX#^$5o2T^GnOKz1024HHr{uYDsq&p}bSwk1( z;~llV9%DN{cSP$oUq~>@{hPblF`0@tZ4LS)25mm~P=*Sf%59-_d}INgO&@|*cE7m+Rwu_2*R3<4ZR{1dQWv{o<6-Nzsev?&=q|Nb%UtP(nb9Xf1ghU{k}(5%1J2f4W{v$rJxUj zz_MUDK5QD_Xt1XfbfCu^mC3qS*H_)3PwKI(e3cYufb|0}zc(&L!Iuv`WpQj58vV?9 z69W|r$4y4z8q~w0*_D`sh2`j&(qF*$B1eG)d!1t)@NL1do`}_^>D`F3>hw3xR}H|G zDA_O@C<&!1Y(n~@3d^s5tgw`csQvhO)PCC(Rg9U7Df%iZ_hKkq)TUV*vuQ4fDSiVI zQ+u6ndL(9()MsNhO-5bIUSMXW{rKlf%Z}%gcuW#g{7BD4zpoUF-7%#{DxE~Xbfdpk z+LETLZ0WXC+0wy#wrLRkp%aC5JSoUs3+k$sdX2Na*ZKNHwNkKXB70NZ&)X1YpMDQ- zBEiT|-3fTjb&@o7{l`K9GyHQ=U&PB|1UIC>Auxw3E47eK{J* z)xZY@ZduaFeR_PB%mJh%(*Y9ByQ?P~l!Q3!97apZ|F*p*S!s>~7P=8iowV49U-O4E?jN8Vk*rtEgW3!_rwCJXb zC^J*-0~Pyv2_y+Jv9XQBge=eMgD+>0i8X77jNMA7kzAGvD{J`$=ngI%&Ia~lnSvI~ zCFjq0yxD`DpLskgnyh}G8$OGz+k8G+u;=OpeU(Sk{rERQhn{oB&s4NzP2a?&G|p>C zf(|ajk4v!?!~rtY5!^SVA-cCwVReiOGs_<4T=O3045kRCQL&f}rW0vwPkA}M$#p{8 zH)BdIq5L}D?XFAi;|k#C`S`~@*nx$09(OqX@plE6jwO9BnlP58LKP>DE%8b=ar+)8 z%O9N<=}B&8)etErXc+MN3=QEt5mzE?tQQYbsW6!eE0L%vKCXl0m(3d6poR3zCZ2AL9!&47P@gYMH&G9usvIZR~0H zf@y4L5TU7wk-w~GH8@0*4Jhx@00)l;6vWfJFGmgsS= zq$!55&%r3J?VHIbgxnqw8RLAB0i(y}j+PnSeLtp@eY`TjGSnlZu^j?|T#!K&L&$jCGh{xWJ)(y)AI2(CEMd5*TR+KI8nd)MBWv4<>Yh}=HL zy9A!4Mitv7)?WzJ4y*_~+t8FzKJ7D6$Q|R80>Kg^7z!u|-Ymp{MdaQI>fXq7HCWBMO_<6vDx`Y+>IwbowJxT*hL`7xUB6nUGj$g#HeNKEc4H#vj zlk# zvb+PpAXmze3vfsP^`eprug=ortnQad#jd_5WlfvfH_@Y5q?5h4`x{LsdohfpuvUw} zydE;9?72SBoJzC^{tD6`ll#o_c{w*RLDwIS_f@6n7fIKVkFwGpe6VfAJykK-)p zfqd3c9 zfS^}E&Wl8I3M#u)aPz8O@%kgY400J`uipoz!y+eT448CT#dmpSl|j8s@i3B2ZRJMB zmfu-{MJGwn!M>O+;tUb70x>{gSuZsCigd<#RH+(=_O4X8muLgXaX%0M&^~x>8D%iFT#w0lK_ac+1u8P1b*}r; z$sH*05-j~aTo?R0AOA2s(^>Rc)6TQy6sYABZ9ibs%o($iB-#`X01?Y=fatrN`wJ@; zo|4%@1e7_HAx*_p1jT*#R;A%ChR}dq33l-gd)T}W#~sNXtVs7r_70W?xIuKHB;tZ= zcu?E!I!Jv?-X7H5myI%zJ z6B-HUACLn#p}c;L1Ti#_QN`Kwsj0!!P0*+l# zJ{9vcAADf)B;(dgO*GwQ?wV8V^yqS~Lu!WuIuILd)k>>Mni+}>9)34<&aa#$6@oxl zxx3{z{6RyLYbn1HFd(xEP<~}n)~?4(73R58CsBI20CIC~bmt7^SJjIG4dI1ehg7mX zj=4Wu)M(bcb5JhsK!b)r;9;LbHM5KrW2D+;QJBr3Zl`<|o|2E<7m-7W3wqpk&N!O0 zC%IXVR~o5$$HU1~MEU`G4Ho@lvUu5=aaFAv@7xXur|A=LR(k0j9INL$?~E|Wd^-qt z-g5(3S5!#eyCwyHG>0($?<^p47)1FT_vSHCpPW70yMa9$7a3B`zh^URGW|5m)?5m#5d zY5LIJRIP&vZ`YkC|16Y1P?#w1sl;)Zml&Z;4niEcZ-Tln@}QcjFHYBIJlm>z^+%g^ z!Xpt}WX5&j2_PKJ9@3l^V-Ja^+ulb)Xf)R((BJ9wJ@cdd3=+Y<-D4u3Js?28#jGqA-(#JD`^HltzL-(b2;NJem0qF4t@lcW)^_Jw_Vn!GHU(L* zO0a$4R_U>RJ*eLS9Ygj}R5+4CU_xJ=Fe9Q7)(VtTFZHd_$9$aDI2P0S3_y!d7$=LL z_OieKd+2+8;~#F%IW`O?m(-KrKRGT6D6ik60V+;* z>dBi)1bHasee{OuF7-s){(aUP`htfKCsqhd<(n~VBhSfFpQjQ1HJx-><7U8#Ej@3J zm`<*jf~VK^^toIBVj?gN#{dwJV28?zk}o*ec4@p#inp)P2(XJFp|O>13*83gT@71Z z362|p$K1-%`6c=oU7zMO=c^_^CiB&eA8I*Xj~2c~hZehRZyGjv&4oZm%9fnn!bETf z1rq(GzDW65ZrSOS;hb4gcyS*i;}TiWdtG#Xrc-#nTSqVsWIPWbG1}eI>mmIUefETh zlL6DlB%t(;K3cW{>?|h2D?Di5)JJsD=ON&SroW1c0U3A$t8aCr8#?wRMDF)*X;RT(iFL%3quNyvb6oWvp zO=^Qg>9p^YcedbKAR57KDpoE!tUuhp*)!y<=bKVF>vt&gxE`Yq=x0~VI$nCpIh6tC z8Ka?k!a^GL@O@&6DlTOZ^cAP{RvyG7;#MN_`q3bopoy zUUt4%8IQws2}pTY_pZKf=hZ5{cw1cj;PBZv=8OJDU#IU@dfNPuN$hs6aHi@JeY(>1 z^+IP2BbwGfX4xL6;~Zk0{`5sX!0&3q`0mUx1^R{&Zco*e}ofXp-60Ps5i5LaE;x_LCEVri_xzpl|8z zZEg#1HYv@QzVS>^@up*^Xj?}!U7PPnq1O$YxYF@XQE`(aOM_DL=-xRqz$uf5&3Ys$=OV}IDRnfIq603Y<4#3h1|aC~d~Ju|C@W6;PPgid^JQMim&TGW zttDU9lzg!^wT>F=<{v5}ng%;?bfM{*8o=ucbOke9m0Rz*SpJ^VC%NL(!-W@d3dz$ z%XRPW+qq{qo8U!%^6#K_Dq-Y`>2LlWMtAX{t=s2Xe>Xs~B+$i6S{jf)serMjYF8wns{ovpkASBMxU2b z2O0n=8yKuXFC#eR2uWLi%Zcjiw@n-B(5xDz9>+n;ZBp&1QR>AYU7)N;FNar8hk}G5 z#iXx5`F)TwBuRb55ZMrB$cRsd^%nuka)XaXCMrco(G}i$2Qo+7)5VGCfFNZ^h4iPO z{3b{lNE2-opQO|roHTj!4oPv@B&Ajc=>qAYjN1&24PotbcSNb&B%IviK#Nbq%iB<+ zA11@vnxS+CTS(UWlgUcqaEgON8B&>=gi?3oq|00BK#JJPKb=tOxgcFgdV3N|{VPZp zNROx52}5KQ%wKp_V*&%rr#^b)bjqx~^ zhs9}dIbbMnB@p$`hRBAnx}%XQFf2Wx85IxIhVOhPV@Ww-sIg@!R~hCgCTdQx=GxuF}2aL_5C-;7B~YTF`sZ3 zX-?l`if|DNSrAiGjF)rS$wL{kfp35KyTqXMKxRkH^M|$S?np+JfBt}4K{i5uMAd|O zeRcEtjDabB{qO=zOAYDs^92JdU;`N70eo>sDnZ}rLA2u`z-PX}$oMSxCN7?T5nK+8 z?J&9>o^H~~&3M9gwVeuck{E9na?9~L@DhW#w)o~cADWRD z)t~aviQ(T1k$!!WFVW?42eVDlBvPm;+X7;>?$h0;Lb* zV*UC{M22SJ-?2zPjb{L#!;8QbcP*$hc9VLNbyRG@1K$nFS(LAOSr0K}f%RV-01Od% zBQZ2_ioaQ75XQtQj~kapVi=K~ObsfJ!FK_d1QTwPgweG*IT^NzBU?8~iDB4C;s}-! zL4LT=K{~X8m&1X6SSv9l z0N{E_U>srOWui5lGkzN4*Q*2kFNP4CT06)i>Ov$z2iIF5x_M2zji24_XKNOGC@d|I zk0j_yB|2a`ml>%c~rB^i)B=**a60Frq<>Aa(4cNy4p*wE#SNr@qKfEQdT ziTfl33;~x$Vi=P!!y08OPTYpDgf~dS)2q~UK?nf6K0HBH=8&y&vO)!fA3CVSaB44E zc_|UXauUi&Jf`A{#BJUBuFlrg>DKk@6k_YwVXY3=|BR11X?VxABHYG70~-|UAPqVX zCGaA~5DbQ_gDoDsP|N~;F8ICyybJ^I4ki`r?pjcnpdmWQCVdLc^Dzb!G>n&-omA+m z7wc@WHVIibh=h;ho!Sx@3v8uA2gKd7b}Bp{5O*~`ahHy>u*>J>{T5+2m|dXX>DOOD z$Q_uKU7$bhrwfp1DJtRwg~76Vyb1~j>Ijn!f160x(Qi;;hF4H=js`voH87?tQ3dnd zZvxx8`c;oT09}s?ZLsCBCf14v*+Aan(?mPRSs(54LU5t(QgQ#pF2N^1l+u^0YIFCs zQekznl?p5CTvi9+YINjl42_+dp{sS$@hmMyAr{*7HP)587U-)m6XfB=b5PcJ1+N^Z zVlPU+6|fq8+7@s_vXM1rHs@O^Bb<6p?1Z(wb}Dv4OBUiJ#xU>G_*gtMCIo3E(ZomR?qLG!peFoq+%&5{w0DXrY;kOg^6NT zk9hFhj2+L{v$Y;P2DuN4^{-GwPG#7{gbxC1_g&+Wemw?C19>%yHysv%5qLRISM8n$ zLdLh}fqEvp9F6yG@?aa5;N&U&GZ8D-fryv)^T6bYtf#}U0U=@^PDrqyiK$5y&c|Yf zD1b4gVG$J~Gp6p1+SllK=mua|Of^NV6D9=jg*}|kh>{^OOnp2xx4WgksJkQCTkMt~ zK;7L^-Mnpe^R_Ae*Tlszvv?0>v596K#K1j*k?=95;?Z1nMvt;SBO4{&akKGc*;<3= zsPAPj-Wx0i@6FtFnYc*JIG1Iouw8l_u5ZnL7{5BUcZ-;71$|u94zUXZ6A0!h4c;?C zz;Dt+(2i(?+weI=A?IVfD8I@vY+4wRk9E{Qb!}ikpR}!sqH)a=zsRIYHK}pBniQF; zs(Sx$d?+@|7*2m({G10;DV0Fy2jO7&#l;8dBhS6{s0;EmJ}-pGhXlZC8+EWPbXs4f zZve00RoFO2MPNFP0dXzC0v#+|Q?ASVdiU~!R8OIs7^3^7W!yP;5oeGGlvLvtRU4NZkqn8i?pDh zO+vSWo^EQ1KkuSP8I+HJ@#Ak`29!E@FM3ap(g+>*uzqTCWI`X>Le5q_o%%jqd#lyM zif7;mhS1lsIQn<<&FJw>FT0#~Er3Bv1Sa$43fZ6Kp=kaUd-8MI^4jcKNb~PtJP02c{6aZif0ZeU`4!S1#u(hLh=h zIYM^3IllRXe(wR74KFAWn8=r*ph@lNY+8RvBX7EVyc8f9FsWz637FK`lK$gyeW}?q zoHmX3{0Y$5g(OqKt0e>z{OfyFTJ_>bDIi)A^c)VV_QC z=!^8VKKh7<^Q_@yI$xfG1(g()njP0?mwEX34XRmb{WJ zfRom)gQ9C)`pas!IW;>3VCW>*$J3qyd9>|Ghv~#~lOJ&!6sDmNn9A3n0(rDk|JD2d zu77dao-}L%c|_n7sWo2K})AFBWD%A|U3`1#Fb-&T~8!%E*8b6M$!IaT{ z6&zIXEB94$Q7CQjtI%4|pg-NlZEwgTc{{e=rR01q*}w6q}>l!Qj3C z3=Rl41T0OA(Fouqpb$)+pwyEF;RXdR49kJVa*3g_f$2QTIRYP`H%(CL8AqkSQdkbm zApp1+9ollmgaYc=0e3=J0eG8Bhn*B{C|82o8l~nKa96q9u|h7ZQ4Cc>aOhYZ*c`-q z|Bf1gs`=;wjSkhGjsm3ysG5&5Bt<=3qg<$(lXoCZ^t1lfBxgfd1F=&OeHm#UGTJ6O zw_N*7o}|=0a<5u8Z?w;nNlImcbRo6bK1r#)LApR)pmx&{V9L%1DMM1!Z%@MELy$6% zCd#OPG(y&#~`rk2pvm%zF}GP{JX6a|GRypIIv%5@5j0!H_~ zp}y6Spi6-y!-m9WhLcTJYPNa%jQv-+yziT))T0LdRW4^J;ce6Wu1&+*8pf_Roauu*AjAtF`Xr1nAR$@7*Q3*vdLD9sPgcvf z_CK-2j2Oal&5f~5Ul<}AQ0+g)i{)*>ZtimX`@n9vp7(oY$jFsu;G)w2-7etZ{WISk zXEs@yWqElxOV!lgWn1pl688tRXzAP zmN5at;r@JqK9|CE2r%!T2w95fN!6q_>ZcLu%V+O?(opeC}uzD>QLpb?F60*mHHe>@PzT7@Y4AT~K zJgR2HoRFFxX;;?C$B}A1P}wV2>fpy{fqnr&>0sc*2?*bc*Yb6F+&A>#3I?r}H@G<5 zpukR=fxQ_799~EO3vvdd<{R9~oXEY%;1KsZQjbI*ME48qob zD=uXqaP54J3m-}VXfOm$k4Ej78PY>hbmfIeKmE*ZXLba#g4ua}-ivMf4>BByKDb~* zax)wBj%-B5H^3m+kT#xYHnMvr?FGESrjr2P5PXP>Fo2f;-Xe3+jdL3(tGSEr(HCdw zGc)y(>3U#l@0888UC8i!92a0{>G$}SZC8f!&$3IMkG(Jg2Z6xjm@!vC+@uH|EDhc& z9S2?jlj=#NcL*LUJmR1n>{uv{3j!#xD#uYi$Hpi{n!^y^O$ z8R2d_AL*wr7#E65S2ojJ;L=%G69gzDnke5A2f7Jeu$}TP6H^QHCzywmQV|$>+5iJ^ zJTYEQZG2e|;R*9vmS#91R{5Gey9w#T472GEvy-Fi}|KVYS`{!7ZXc zB!=D;-(7YL;S?FcPb1W*0N_|rrsC9X2uoO8fjs~p%z7BJ^sWVUxe2Or9decPY6Mh9 z*dgsD2C*wSc_|UXG7`$jOqM0 z{YgON-iSBoqZoOEa<861*SNS33%+|U)=q_eZ29eGD2;$KnQE4#G{Y}gI3+5k;nIo+ zP@G+Z>`%h9@Bs}QxIQn?f?PwlNDPfAptA@AAtPlVU%jE45HK1I>;MLSV|fwEXOmrN zD*ihHFHITBF9aZI0Gn&Zc(I3~ulGiQ;Q9(RI+>ee!C!qdQdH;y?CWT5Qacqg^$w`u zoE~SE8?ubGWvK8k9!Du+I>a??m;vbX5O@X8JGb}{?9&Nzw%<7j39qhzzm z%^g&nKC4_CMfI&wasW8r_t6W z(+r03f~VMr6^ni;^+C31o`Opl0JYM1vCtW(Aw3x5XpD;M;=nw6$A=j12lA0UBePyM z4~3p3g`NYi@G$2KEe1npqL~L#SnbIroAr2%N!kI|b-SDk3azVk7BUq47gv!Xb$H{z z7D$cNPU+0qjHW}+;|)d&6!UdLYDaoH*{nxnOWs^An}q^9?aeQNA;$6PbkpkJ=*P=q zB+$$SYb5Y6i-{o6OCRES0S765tzLV8UVk@>e@wAjCy+1wj{S#5#Ds-UZUmMH-S^LCkgEB0^xR;wYB%rx3JU6 z2T#zxft5sny5?_TL9Id4MbO8W@6#tejBF6tv6kp9DkdmEFV5~z7v|CjFv@9*%UvPLp$if8yLxDM&gENg_(0|7;pt)gKrK`LRDo{4rjN|1z zz56%%*5zbpF$f0A<`I?*Qj0*bK}G)7qc2yuh1Fl19Ostckz6PnbfSmpdQ^Wl*C}e$ zC`ty%=IMHocep&l44_Z+_xhbam+@i4C?|rqhIk3A%`TYqb3Jr^w}(1RQXup9t6~qorVoWel|VIQ4W4Flvi zf!Ma2q#h|5Gq=XDy=C}*BZiGm8$K7rrU%R?SA)?B}*t{<3#x&KhMh zI2PY0177idyETaI`EIf3Wl=f*4HO%f#=^>2VoL$-CvTz6Hy6;fcIQ7GgJ27j!S5Cj z7W^)`)R%m>aIkRt;8#R?nsq}g-MYr1HTcB<-J0eVEv>Dq(`}s& zp&WNQ5HicqvS-(>?%g?G7y7@M;`=^2xU3cZ+qZY`y(RoCjKrjQt7J^`G_2@Kx35U8 zYzMlmMOp}8P4n~O&aTci={2qG%}r068hU@e69C)l=C16TOvmaqYb1-?fY@xt=`}5_ z9cx-Tnwu6jC0kb6epuDC5S@r3`rvNH44vU_S=HRt(UR$E?Obj7QGD(lPC+*5O;2N& zZoWQkx9ZJd%^wb%bKBnhUcTXl;6H=TrE9; z7Aakvx2%ia2d)8^ya-_yu zVHsrviAPUCfP(tc9RT9^LEWnpU{}eLV!50X*nFsa`Co)v<-U}u+DmCYYB&Ov@V_xt zUny-!t>`@_qt8mILsF)jOr{H^)Pc02nd&hntGol)+e0-S36U!yW^{$vY%X{XHme1Stb)q7PwU4rssIrTF3`rCtfr1=2$Y z(g2Wt$AXk0Wu)&xc_T;}NE3aiPZ=T`!urry_CuN@X5R>{uiV_EZvncyZYZ6$4CKzO zejK*z&IKt$YE+d_YAQ}8yuA}h5!;>mgi>8Wx{&mCCzSeUkS>rOkMZM%$cC`?!9g6I z2@rDY1SSJstVc_B>BB+FK$@8M`Wr)JL)f60gf6^1RjDY7VGb_Kb>YV8O6@ds@87T^q~Ebt zhcc9(h2ICndQUy#W08JX>vI#xQvQB}R^W7SA_Ji%dtazbHt?}If0r0!2qbJ&MS%O* zR;?0^RVuNlrWeZbPh&d_hoxQlinv+YF111bpod_< z3P`{hqY@nU-<}wnC z1^HEi#h4ly)Q;CmYb4dkzry5_-$z*L1N3{@5r|xd0*hM6ek?YQEMz<)OF`fRWibBL ziNPP0k%I6mXrf0Ux8T*$2FMx_h!VqSeaRVB2wu76(nt)w1KgvGDo)*ou!Qm6Dykls z9#_+I6I5bb+#|faSz$m4KL(V<{x@~s;vQ9z^xcyTAxLzhjw>pwQR6O(V!}09bl+SE zK?Ox1it8dq7$h2!IGHG@>;{q$#^WfWAPOk1sKnrki^PaRo~P;``<`D_U(O^0y6@}0 z-}jx-P^V9K^}V~gx-K}rXjbu|>MTsTo_KSQ9_GT&n zWF6(7Yyi+l`6qV**u94G^qv?PRR|*C{jl8i|h9P4doXE(qtr%CTl7GY#&9dt0> zA={2oI|TD-NE&k$<$F-Y9#o;X5`P4mCthYjd2Fv;gJQy~@b7>NbVuv+6typ)eCuW; zKzVx?@WkwD5tLt_OVQBWYKq!xDBoI3QF|@rTNlvK+#1LjQ#6wJn9U=<@($te+J(AfjmxHty6M^p!N@>meF2TBoPt@o@IS(RhaEQlE- zVi4sjPLDj?QyM?^8pW@;SKH`V^{;?GFG&!wNMye>erx#Y&g+uqI)-_~O)^c5@i|GE zp*B%2i?RhVX>Cr$1;cZNth8Wi0alzg;t5TL=CmoN=LyLX982QS@mwJzjczS6_LVp2S8#jwEFzWf36}?40pQrpASljNd?!U83(@`tl}-waprC@r2}k_)?;j{Vn5LAne3 zA|50!7XMMHFc3?4W;nWa*S|q53^rT!nJ#dJlU#X1&QGWVf3}{7Voo`?*<{wSZH#{* z2Td>W!29_a9pQ-zFGhe98Xi56#`ziOu^=Tw7kT1gJ{=Ou?8YPUio}S(p^xQxl-_%g ze~hIZmvqjxZ9Gq1Z$hq#ZFKpbkW$2u@z{7pxq=K0xzhV|`A+^KmKI*K@kqR)T(O{) zd+D6pcxdf43u|I2;o%#P#4E~E4)39Lzo9&j(TR}M8Q9fBe!QmG(Sno~?a%TzbSxxX zY$uaME6Ni5!I0%s^IzH$QmwP8Bu-Iw7=%GUi@&;={z+ejggb0PiB?J`B*vC6RNBD)EYnUo5d@$6_qyH#Sd+ zSJYhC3PYZC^x<~?G$a%mXFL+EC`%RD(gra)5M$|nwaAtZ!&u78wx}Z7Rg|NOY^mgt zalGSH*OS$giqLn60N9NaS{nxVibl{ zFWFQQrzkrW+rol@$Bx2~kcMnZH9%Io_VN1VHZBHTv51VcliIMu%FAPP^lmQ1#-VeA zI)BDER8cOS&BkQ;XL@_*e7_>nx3&~kk}JmIRY@*4CQ>|l|E7?R-?HhfQLC4&PGU(1LBk9Wx}&&*RF(@H7alI~NDVw{yLIAmi^}?FjV&-L%mt2w zBz%{?s%;DDoPt2@j6G6?xo|2#bMhzj!?nF3UDoDz&y3*^?2#eLANdTQpLI_d4nsDf zL@R15H8tjjLoH9xhYMl}PuheMt*CQ~rL_3S0zUCdEa49};nl>n5QV?uJRPQ=LsEXv zCRL7Md_bs&RW~47Q+)2eSUTs3)_Pctjd}I3s!NA4FE6I(nUHRlrJ1aU)!2|1Zxuef zxp(tOtWEE*$<(DqJhumAU2zK%ALp;;tO(gP+H?}DsCJ8r)+0VRp9kr^kZ_|-DA9^C z6!xc-6Ayj0{4abaqQzmKc+Q%0=!*dvH#p4~6aCrh$Fz6pX)G<&KMjs7ZOm#Dc zUwu*0Gq-0St_y?js7)r3iV7|sJAA?K;leZb#L_u;wGyjnB}FkS4ClQ8xhJ}}iy1d{ zq-dqg)CAYGPfoH)%ySigDHNyRT-^q6c5?+V#MSMN1YfU()zse|Fo0yZd%MxVvHbgWX*(;Q!5iyB2lM zsc&3S_ds3!19kN^b@hL$tNT-3-J&}8)GVy4udBP}fd?L_xgvtab@huMsB3s&@$#Db z6@OY%_orpcix4cXt3!d}j})-320?4aWb!@gXDsZ_XL{ ze+wTqzwoD@-!jwx?1tMc`SV7LDf%BG>GA(*=spM%@gz8yuqb5z9wxvu|DL0-jp2RC z-{Mcc0U{p4Te#{!-)({sv^x2-b>`}|b>_-}pfF}d{2K|Utq=$*o*@oZNGn0Q0|#MM zXPmL*M-@~BCQUZOyyeVKHc7FY_z+D#7s)Uqs`y_n_5fWXi55Ec#g!fSW_8IU&MIO8D>(jm2?NT^+^X_;=!1hdTV=mj(^P+oe-IWU!us)uF0Ejp3>C5!XoA(Wl zPk4ExCzr|g_}Ab^+C`8MY!niLzIJt$n&3+au%iJ1Jv(}fBFMWA4Z!O<`(GA}8#D4Q zaA&S}pi5GaOn0rrucNhd|%% zAt;o2b6+etj2T4T@Zt-PckZ%H*PhAQcPT4g+go;Idv_s<1feZL5A1#)>4FK zaiBGnS{&$9Lbf`;=1+C?4|H~i_l?`KnGD)yRc1%$K)3aK?q7u%+tt};wr-YjF7IaR z=H~A1-fiyX$$?CEkGx=-qE7xrr=D%2&30I0WE6X1N7Y3i0$mcH5pI52kL3Q{W#GQY zXc8ahCx}E=Yt7U1@%>zsyKDcM<e0ZqM9dD# z^A}G)wGlT_^I>U(@@;&Mq7M9NtHLb}LeA#4^Jtr122r$^&o#F3nZ2!ahzhwsV8{AN z{kQV?wN#+*!8tIHI!Hdg`&Np|MLvPQr+l(jLKV^Dd-yCBXabRWs*TUUDA_!U+W0Kc zzsdUnpQC&mEN=|YfA+bpTX@W(wy#4dg3WMdU7`-uU{LFn@8GkL!hje;sLT*wH28k{ z)h$|=sDn>aREBf|FQ5RY>v@8r-ARg?DjWGS<#{N39gp89(N{}-8u@bnJYUa$p`NR4 zW1$fm`Er)O7UOJ!yhXh54J@>kZsXHc$mmRC8=rlRzS7pucg(1DK550$c$_|nzi|{A zXo&JWK?V95To}_qlQNXh&2TSkn_HSnx*Ilp9_P^}@SqGu)jZk+E{x&PCKzZkJi!N& zJlfP`14V70N1N8#cUYY=1Gm#YX#OQk?m8ZAg7^pGh;6V~t~}cGko_cFG#=-}T9P3? zJCE{P_9j`byXBKS5v-q6-CWeJlYIC6s%`8@n|#H zJX+S=?_u|aqUQOOZ+(cO=6O8Y3}zjoHt=Y(TwlS$3Qw5o-1U@)W3i@c8sfKreI7;4 zX}y_WSB1a@l)sUp=1SbsQZ_(glHldag#MF0c)p(Vl;{0CK8Ny)n_>PfDaOPa`Nuc;ybR@N9iQXT7F+Lx z))NvNtxYHqk3wMpy?7(#Ti4h!uSIK7zI8p1HVbcsM^*8~x7ye|b;8J_tMPl<2t+g$+#&CjVmJn&WPPgj9S@wYNx1Hz6Ce%XuCg1<> z1g*D0U{kx4wKk0YDPd@#Y98aSU1tj}v8a@!sAZKFF3Ue*3~9ey&!f${c8oULu|k(z z@}}5W3DIT9@MyD+moXY~(Ode8YA@bQd9>NCFwL^Ul<3&}DwMAIAx%t?E1uS7`Z6^3 zjLpt3uvaYEA4(x%Zv1ZQzrE7IoH@{q=ZHz!@-T^^!uJSf`Dn$exJT+C(4yi{`!PXCL!=D4+nuE z4tj?V6$L?lzpmUxiql}ox;#PqXE_qhJ#q32IhB_vWSsH>tye0})*=%GxHHD%u=Y zc>5~F6%ai&(alDVu(upMYCK};Gx|qmk z8sWE#Ur&dn#;!{);xYfF8cS^MT8cWVd7>o&Kgcv%ffab5x}K*fPnY-u8+(K&QZy`b zAlUDDqB)VoHua;d&du|5wI0^h8s!;w**rO4ND6FIHs~h|Sjy8$k3COE_@I8R=fjOO z;^X4WpnmD!MG+N3yyHRzIa)OSjUqbYF+_Wk6unYOg-z9SfzEy4@!Kh?Xa#YTj4zZS z29hM>NgDa5EPujNsI03V6?|2p$YN_z)kp;wCrj^B6syt@4_+JZL5k>-?-dw8d;~pG zkNUMFrHkgq%2(Jt%MzCAL%S;e?XUA@A+5;IqHkw>M5Ei00>eERX!N5B^}zNk_B|@l zB|c-#?wzME=rZm!cTj#dn$-JwN&z|+A0|@ zt7La36nOthhjqDLx`nkIET z*ky>$>T4q%aiGk!@7<`O0-aNs4@e&gWp`JKhFI2|aNd^5W#dwTPV$(=F{SGadK|Ob z766Cp{QO$V^HDqZSH%X|h{Ke?DfLy%20g(-P8ywk7rLN|q9k47pBc8e%D(#x4mM?)zHEBazusxa_JW#9 zZfxTq8{I=k{o|B=c2kN!Ej1MMuaMVhwgQS0E$}?K?tt zhwa~q;l>9l?yBeGt5?!Vhrj<%!m*(vE`wJ1y02763OK37@D-9x6eW2d<(JBc42$Q8 zOP$~YG2~f3$fFf@Nx~-O_WL0|P%b0H7CTmhEFCXZ%mx`mwh?~oG9IY7ONwW^X7#;% zKvpYT-1wN)Wf1pRx>DP=20?@U%k^5GE|I5E)>Whb(f5|BlGQ(YWWIE|4{Mr-W^k#{ zk#5&RQoHr1Xz1^n_Ywd3Cuk>03CbXHpLG3G=?>5VRYGg#lSYpuDcW4w2-~_;AV&-R zQ3gdh{fHwS(6!5EDSSRzi`)WqU?p90sj_@r`qb3`gUXg#rnjw46{fe1lcjw;TA>EY zd31Gh{kpctd31H~6jMP&-BmD+J*KHdqj*gTr7RvW+) zYP$&&2~3uJLOgvd@ymyV1v^BOmXI8Avz^Df_($acw4~7tRTQ;UOMB2HPOQ2l#x{M~ zU)=_n;2|Dc>Sn*}Z^C*`(eR6Q50|O;6D0VxBSHV!nkD#PSX~pL9eC`&Y~uK04!&-R z^8Bw-74s!R1Rm$FVtz=*=$vjmTCE?oENj7N2zka^S%$W+Vu-_IPxD1-EU8oxB0o>A zoVdoeQxV%69Ms*GXS%maIjGS9P6t!MSIt%MC?wvE=#f*Q4Q(df)F%A}#)|Y;QZE5q zvF*k(G_XX>K>r!ZlT_G3XRw#sSp;PkIL+{AlYEBv@ef)@?B|l5$C(F>BTQ3ap9apU zEZ>`ID|ws?SLT5Hd$x*;3?9$9r@!W&ezo%-Gw<*1{#zr-!7j2rm_jN&tyZZOd?=wh zT50p7hhFs1YYCOQhu_iw{*W*tubno0B4I@6J1v%`A)sGj?k!WP?6jc|%ar$!HZ)b{ zV*bT*ZuXX|7JY@Ge7Vo*aJfs*up5X=qqO0FmAmxYk}fdqIX16(h$m+`OjQ*Q(UJ-m z*6zdjTOU|H+eN%{wu`vThjq?&?5ExSD;@Tq;V9hJoG$v%RHe#$r_F*&_4$)FYbw?8 zOS&X8$+IVl*h#;JnFLv2J|wPkr)!^JeJf9Ft2Dxi2+wcD0*W&sP}K4S_)#;Tm9d~Q zv$a2$?auVrFq9b~J=^+VKix8pN;8)pv1ydKgj7C}XF$RDwLXfuFWc3V+Yv(WSZ^;D z4<2$Bi~}NiPrl#*Ci=!0;amN8ggA;_?iR79{0(vj3gbS9`}S)V z*0g3_s+XEDQTSzYNn-X-v`&_dY;%Q%&)U@$lN0Iw%haV_2F@0R|V?MpNJe=9-Jgg;DG0~ zr5aay$rO$7Sz#TtRnbqF0~D>VlD)l!@RgLrvnipG=Zb`z5g)1 z1sbMLC9^G6aW)Giz>smP<6N{>VOOlCs8xu$D!B^V1iJAdJ!#q+@)9QkWCqN8F1mbH|EkjcukN(_AIwR96Nr&6i1>Hc$EnC}I)3 ziCw$glAvLirIX>9>G%U%V*G(;l|Nufd&eKJL={L;M>*m|6*~B&J8OU?00l=U1%P9W zJBxuG;Er?34gj(0LXgxhLV=F>D(RSTO)a#&ix$P29Y=Rt=Xr4W1YrParg&?5hRle=k)r+gmpajM%b;_@=X_=PWoAv2M1%rJbcdC&v`ns z+r?bZKPSRjq~&D>fh}m(}+#iNF%mrSni?Pj&ix|e}ew0Fm{ExBF$D2rXo5r zpme2bq?0zV|JFFNVo8VVutdNRnM~x!R~c<5`$a?}t{Bm?xGp-m)0KX6>@8Hp<%1zSNZsnBO3jsY`QDITDQ%f7s(+p9PKGt=4B$Y6x zH5N0=UrM*T1u1rd=X1gi0i9=gJW;E=Tb$##6|uXtXybfz1ekgD1^~tT(ej1DxQ|^U z>IGxSJaE2or{!)5EEi8%uP5DAo?E%xZA0`%k_xM4CuFhnf#qT3$#iyi8dz-$o2o(X zcy2q7XS+CA8j{7!6>5kF z;Vl&OtD^?6w%N)QvEq4bp>o&ID*0q>tI{bv#;2V;31lUk;+!{sGXkaFVp535XwY)& zJeAC2{H1oY7s&g6ik(!?lm88F(jY4S3*4l*KP<~0@|+>Z55kcfDw=6SN321G3PZ4x zfb}nJ#9)FlT<-Op9s1bwgXmJiacns68A1&8e~aK;!ZBy6J;R5NdNvS$<3stP7wh5E z<&F!LNjfOu`8YSta_AdpIabV@vm85!KK6mN6;8f~KC5ss`7ICLGuwS{@jRQyW;^8c z>1@Zdp~=~fX~V~6U!7}X&)EMq*9I!%&tHXU!{=ukIZTJ=KgYEZxwRQjaCQaF>|ev9 znaSC~150@NI9^XN*Jf);9u4@?Ar&6@gw+Rl@Q5v+X+e-U4?*HG7F?A7h7L_k?7k## zrYO*9FId4Q$B_}?C$I3~%i%r;hRrrn&RsM^BL7OWOcF>Ao4q0=^B_XxAbNhb~Q*(!<#DsjL_(Zug)m=EXfPtim<4f9}b zL5ePeHuqFao<~!3Iks6g^60?rt6N>#0sa7qk?b)33_@hK>R#aRH$Zv5$m4v@9xVKx zvA_y(w^dWLC9T&G!o(0^?tvJc63j}bBrpsW@Jj?hpHn`i7D!ng(crPw3jg}qfXdx7ZA27!fXt*_6NVqJ4 zP>Pi#j@st&sF-i!DTo-)7uxLbRZ5l5$xTa>@VOjQNv>ngAk!+I>UfAQ3KccNgKzTN zIev?xwps}Oo}s9kqP7~!SHaDDTWt&F5s;=lZf{T&sYTRwzs6kPV&31vKAeS2TvLjMvl8%VH|5vy+wqtk0cTTLWr~K^ zNB|v@Wev4C7LUF_zDjAE%W6_Ie49q!CkD$P`27J5?d7-2d9;mwhSX;6))bBMw_t1F zLz#TQ%9)!jAPiWcygiv8f5+Wgq7}F1OfNaHaiNV zHaJ8-LgrDlZXQA~UDF7u7O|=P zTCj9Gz+J{sP{lbgv+`BIrsMG(pSjWA8*9aHu=4=!VU1N1T8F;b!f)%r{sY?+{8J)D zAKH$%w@48OE%~WM2%-GPP|1T=PL6(;4BR2bHMpc}ot|)3ijHc&Xz{P4#chT;VA2Lg zjkR^{O=}%m`Ts%#-(_#oF)SNpl>#@81jy1~`Y0l$Vjy}bNnrh=i zR-+7xJZ;rU8fr@?8`oi~?x)Df2DI@oHn=z4xwqwhiZ;|?SvZBIuQg+{ zWq9aRg3!Hh%g1<|R1nU>(R5kc7(e)IqtEGIJ z_93{5@?|`hwr#HL6PPOnDRHai3g{eJY_BrLR{Cb8pNr)9ny|3U`ul8((z2u+&hdG- z*1$3PCCO!szp-ttS2MzB_j&Sr_S}l?m569YS`WhiyJ&(4@?W5J1lrYirT&iNW z>ndpyrV=37S^e5v{4?hkA@)wmE-)zaAT>&1$Q_vS6rd(r&7-SoRnIHG7G&J2T4f=w zs!a9aJ%r}z?d=EkqR@}{Yj3oay`p6Wog=xfQ4 zl@=DxUR+ZON~@rZD_8EV>R&~Nz%$!Y*}r_+qFiBli5+Py(EBl(&cW_>rBG;c-%wS| zm>lA>)hoADX8Ha0m3ynQbV*5#D-;7IphAYfx2wyHbt_Jlb!*GE@o7sTR8q9J3LSn* z0zgSeTjn9)j2z))Xv;u$)C0bqwIK`>sU|l^u>!{Ck;WQ;z>YLSLkL&+d>lkyITR82 zGCd0A^ zVn!KQX?&IQ0mywG#@8y!^T$X~iA=SZqV{Sm&6EcTL*G03E0B@8K@gOu-~6L(Vfqxy z-9&2w6twWQC~AdWUQlVGe^j)7BkR-pb!3@z2R2Au{U4S0y*w;x6mxAUeZNFoq?M23 zi`2=lhvB3!0$00e5H#;$!9hRA4y}=GN5O$si{rpW!Em?Rz+00%w!rRvqMq(F3NqLb zK1iTBPov3Ts@vW3&$f-(#)opVoPeXODjoa*niM&r_$T;GtKFhP(~dOQ9Y^{{C`pyB zYj@Ihno$zhm7$M5u!#2UwG%o<)Td)K{j(^tP;o-JPAfOoW)w_ofZiWX)?zbcY?xLe z-H(D1KH%trHmoNdAag_#@Tz5X6q`)1qQ)PL^^(qQ7=fjzT$F|f=HMS35@$Ej%%D3ixhvM7|q8)c)WwKG((ffX=BAP8N zbPU;wWA47q=PIz--(q)KIha915Zmf^wp-M;ffoxXUJ7}PesuAi#e*xw#Yj2EW3=BT z5TglUe)yR*%tN+7)3@}{$UH`4F4C*Q+LtrUG12x~D{BO14g}F<*9HfCs)OI=G5VKH zCzHwNFM1ndmftQuu3#WdgcCEPG+sHbp7Zs5*b55rS;#fvqUeM!KlL~nK|~00_$m-O zDO(psd*$+jPWgxuYq03`&7!y6MQ{8;(JP%RezohL6KgqJ{MDwFk(8$kIsGbk?x!s* zd@Cx@8UGCeNm7Std+Gr8)QRbP>J;|W*|MkZlVOazJJ+;2m_)nWFJx#Wn*r9*6b&z) zg}E>rTkO3ezVrm{ups@eO{uZ?2N;8zn2oKJ|0%qU*C0ME>Rs>4w|3cQ#ReipProU* zSqF=d2&0B4+GW3W>Q?XC{gw(eY-2}l^X2SFNBVsF!CV^QJkgX$rqQ88!7@OLjZL0t71y`a`u1~d|yA^1nEQRBGF4!Y(xBGS&9yc6FcDfU1Nv0)q}S3&NjhK|(!$(s|ELk}ixw z5xUS)>C&09C|zM^&{(+1jwj%ALcN9DN~Ew8*JdF$TT$$*x;g+;^KrAAvizX{wSD!AI@A?zdkp;((JffY)M0F~hKos_H<;}U1+ zUH(oEZL)6gQ0}%Az1@m(L$&mJo@h^0f_Q1SB-Y3xX*a9vxK0Xa7fl-C%Ly$d3KJWg zko+ndoY0Pf4f8w|x?SF}S&^raojy1=+Ntoo4=(uKVu&u;V7Y_e?xR3FQ7e|Gk-vJd zu*ri*HY=E-;T_nP0xDrdzbgW|sEN%08x^K39i$WYvfZx0&r>!lU9y=cJ&!L%!`myM zV3bEAxLW0@uvT+!q!A0HXhk>BxGQu3#ZBmCwvV7O?39OI!2yMZ+6)#c?ezCuW%`u-K7^ZF?f7dRFy9-8hMwl6v@7 zGSs)8u8k3m*tW2f4+co$C;f;m6rD&oOoM1Z02kBt>>Q)}x=nf#U2DgJSX8M4~p0ESS7m&vqEpZnM zx_xF)`OKi1#&dX#3+~{8>e}YPK^=v0Qc~ot?yRbX-}# z$Y_RL->p8e<+QZS_RiFzL7u|--N?4OouLVlL2YNR7JkjH*!=hmc7 z7@p#>4nKDau7G~j@;IHA`Reji)?d8Sh5t2^vWAwnPJGKzvnzv0#cR_mRegxR#iT}e zS^E&U(h`km9^-wwAKKX!$V6AoMo;oU#`>fi#POw6(;jj3bly`Fjh<*s(a@`jt5J$e zMW_}QLZFO%MIv#Y?2S)WuD%+5_)a}ftfUK;BJO{%o{s~2oM==Ei3*N3kCJh7IvChh zB6d43;K}ll@B(heVc)I4g0!R~eqmCwE=m7FUt>l&iu`{-Q?3J=U#2O;p6&|qohyXv zZ@m9z#3W6)HY%};@4m70{>>lQL}8b3+tWCY{qhW4Ur`zSFAC0gK|`Qh!WpZM%)glt?I{vNQRf8MZu?;cG}3(h}-mZdpoS7514_9Hd~G+z|Luw9hm1YEP2^S>p}&$7cc7v390iGr7`5)l9*=FZ z;{hb5qi^i^j`1PECY8e-C|VuRYJuZNXq3xc1L7}feprj3TDwsJG^;ZY&8$@ z5Jvd=M9CqZe6l}B@I-nUBq!vbj@f+kH1d$$6h}Bez=yDDLX(~*am_4MunLx9aR;p=uABy=kaS>N%l?|pzqQ<(v~zVd=RZHwh`PRxeD?)e=_aZD)%lDd&Y#ENnBt9 z{!BK&cw5_qS3A|GXh^Kr{xTEh5r;mKsaR*H;_BE`WT?#k3RDfns7lT1-4ca{#WIs` zvlIKz`t?#cyTY(K@-l!lanE#*jid77ey zV(qUl&lLrA>Cof7Jz}^PVovZOmKL963W-l=_()5uq6FNmr43A=i&>Wn!=IKJF-@Bm zEBB6lJKVS6VbGNzT?Y_;mBAvL+CFcvbIsLW! z=ewAV^Id~%oA0pS`g>Q7r+@FV+3UmTq7SUQ-PK~t?G7Og1+d`1(zld?w%2{WJXBaj1bsR z*T><34fW!Xz8N8VXM|8;X3+7OL0``d5<4;SxDxO?MX_euwh~KLyTltntO0mte(W4( zhh}0ZR$W07tx3fY?L?e2XolMSi1Zr#z<{lY-ZOx7REjOZ@H##U#42Bq5? zcbc>@qrR2QR@JO@4voB__kQ<9y(XEh>oz{Uejq0fh}L)Q&UD9JqFKjEy)n;4&NC7` z95wfB*IcAX!J}764a`-U?o2MTs$# z**eV+)v8Q?F5A0DojDb^f;SvC%^#MpA)4KOlRi`DSTq;uS@P^>u-zPs((oDy6zg5NT9jQg$F;D}(z#=Syk}kCvfely9kY zzG`4#2@;P^g-K-IA@p=mjEkKS1{^dw3$U1>st@7=s4xIKlcGDicV0N;$K))9NzNbh z8T!KBs_6}goQ=HBC?xvD_N(JRya`b;}F|vF~$j{ z3T^8uRfR2x^$Ob`UPm_wxk}qe;~#TpIOw-(V|(kMC4D57K6pXlT`BK%-nPPv_Dq#F zaA|hE#1PSSb!{R_lhz-~pm9bJI5KK*A#JJ>&Z5CB)(At|Y)H6#{^CtAc_h?;#I%b5}{VcW- zzB(h0XwT~75J|sG3;Nau#5UgjGlSriO&{Rm&tWq1iM~uv%txc{L4L!V@g;5=ziu0Mv)s7my#J$Y3i#v9J{=2X+6vGF(s&I!|S8gP=UU zm4?300own2qyZp17UgMw4ZciwYnSKWdIuT!|9k_%cHx!q{MPg zCEY);|Ep;oIktiSmNtZCMRyQ>*DlRzBQ$~CL7*{bZ9V_wcM#Zm*3Aa2dk|1*L;L*} zLT~v!grGbJ+mlz>L@?j~?M(#5gA=Q;iNL#KaB@{*6S?po-9%dKY8_T}@qi|e+YN%N zQWx^dj8rr&;0b|Fi6+-8kig;z0~RV}#{X%I=Laa86%m41b9UW^_ktGSB}z&S>LSvGM#B?zwEv?wM}+ zW z=pcOu3L|vUw8GJ3ap8U;=N$c0q?oJ+W9iA^)u_HR$^$XOxt3BW?x7(bOiNwGFruiK ziZ?3^MmrAkeAJIM=pwyu^$?P3!rNaVvd;K8{mny6^tg9AwvWq>~+7<7W&7Cv|H zZuJj*r6Dr5#+I^pEPTy zU57Ywc(rk0h2{_>A7SNSAIc!3=gG?A$_?-lOoG$(JjLVuj#P>AyQ_KpcTWDjbv1Hu zO>n=|9hNG70q;kGcXd5awYP@!IsQNpEG+8Dr?icDjGV797@NXu43lwMH>2%&YE7kB zh0wFH*Z(YHaHz3@YPHNIKCA}rpy;V8jNlf^1Arl?{NvJ()zXhKXUSH5W0=Jc>mXeg z!WhPTa&^V*6j&>_>s2eJ#9C?aa=U0jRD%v6aU<`~mA4G=abOebI`^E21jdr@ZWG}S zS?)9?A|fThSJXujFMZvPtcVWC@+v|Y??NO53m~{E&_KV_2@J*1@8Nx}cZ;l#?&op( zA&xIa!z*mxz)&Z+N1;Y8qUI<{NwNw^w$3bSQLF6XBh&Na_fj-LN6|21FzpVC9PjAaz~Mx{@)uV8Hd+lKMlEKj{S6J(IsTl-`Ka&dqG@5B%|mCo z5^J*F-5~K$iQERy_ojth(DI1 zVccwhSJguK_4szH#W2*6$ibSz{92k4D|=vESq`B{e;`NtQKcBONglsj7VUWUyM6W$ zjxNf1GPi#EUZv#&HPHZS0>0_c!u(TiajZx%Ztzeo{isFqju?5I&KIxcYN{^g>^&fX z)(8$eMTL#G)d+tnjo2ZLC5P@tG}aL=K@mU_7xqJ7C8%*7D6JvF@kqF@2O)I?;kVUE zP(_PAx^lx7u}3 z4HO23C${`JhG0Q}M|q4s)Y;TQlPY@3Uxv(hd&&!aeMibnS%vi?Ew4MrcT zq+a4O>5R;ZeLM_2&&D^B0zrVzTAGQw^>|2VV|X|h2Z5H+D{crCzRIk`T7^@Y_C+72 z-~^mzAskkWQgm6&)aC9&haS|~_)+c-5h}ELZ(_9=^;<8*L5ePKhSU@v&m|lAqX8bf zm;coQwMZBV(z)W+Ge{fq30F*UjG-~SsF3Q94CA6xI|w>z4iA(kTxzib=LHCL7=ro| z@A1P)Sv+FVV`%ums%oBs8dC6;-UnM-ZaZErBA~F)6Q2pPjmqTp3JjQGaHZk&3{aEZyI#EPwi~1(uOz^0z z>^kjZ-hOqaLxwj#z1>bEdbrY1Rt(kkSkcVD(eBDUnrA0V2ptW3x|!Y#?>Sl^bc4>m zL$1$?WQkq1b8T0uuyvVYJA6}Z5-kAicE~vcsLrbnKG`u5?^ZsLtj0KkR+Qip(<@F_ z&UaI+L;NDZV;uRIu_^Dwg~JTwF*3UDA< zrVR5|a3IYLj63L%v&DkjyaqY+<0{n_a?)Put&~1;?LNX&11XHAl6P}_fQICFAjVxL z@QURdYvM(j3PmH8&MT*ZBH6%nHO1~E8)C-F91rp2?A%kbTe;zXAwJsG5-^`>3-QZS zG>q#xq)iUo#y`_!Gn(K>aTWz<7qKbC=jqE74fo5!h5GxYb%tqRAX+Vm;1IDCq5*n8 zR#Mr9i>fTTrF_hrq=$vnsgPrehOI^`npoWi=^Qvn!w>pePr~6E2CXb7cDCzMvOhp^1*v~6!aqe{7n9B7EOX8fhY0D4UT8fI{Oe}_1X?2TP$Vb9CZ%i4#mHP2`Eg6 zut$VC@IL-(7DX!aWR0lNN3p3Ch7u?ty8+Uu_6-fmScqs;2`3toF%sEwSmkMukT^+= zf@AJRnW2L^`gHv82Ydl_k$7Oe<1B4s%97-gTE=hG1cW^SVD6743vrG;rWM{;fC0 zG#FzZo{p~6bEhD0H4olr?t4)Da+>~JXRd2o&9shnH z+*9E`KUm?=H~X(oROpRXg`x8vnu`f9e5G+tHd#DDix zI=Nc@+y~NIb6j$|FvpdMKb_-bWar61xJBA-lfc?$Ie}q(G;Qc~ED{&w!5iaTH>K6JoNmv4mlsZ)`>Lp zXZ}0?=)vT54&^N#`h$n?UAf&hzjAaLKp)Ip?0n zQV(HDY1l&^YVy!353TVKZs;_{CJ$})5H4Hv>!KZ9-J5Wx* zX3EjXTC36%?pgFgKSYh>!2(uFvL}93g;pp}1h*UU$GLSy6|@>oSQU?kz-zgC)Llq+ z+s?R*sW^FcQm(k|oGA#4M;0}GB+?Auuo4M2K=pC=rUV7h5VUom=fzCU^|gznR_o;v zUMmoV*k#0h&kS<~HpGekd~sORoJxtHCv zr!UiQwr=g()wgx)*1m1IJ$)Jfx^>qJTel5lx9;lPJx#*%>JDRf_wDM;^$v6aQNNIhAvXh#Ya-CSEZdm(3mO(m)#l3*tUrXJvmU@~@-M@3a z8aFju1!Grm{UAEQuT}B*bub7cK0kyCxtEVMQ(=B}iY9QQd3b=wDf%zOsprG|1OGsU z`E(TaoWMj|1zuE&CT^gE9eke0ucsj%Pd4)T{v;LtN|$k1(wGZUG||E5DKZV!0}vI0 z{WS2gikNEy&}of}j0!(3X0pbf(Nv6ah~aodWf-kf5AkY&bAWOTAiVg5qv>!fC)8E$ zX0hBQ(bU(%Bra3kY0YHyB z6-|_H2Pb&~#$PW!)zQ&``|7i}$vP|6dvO_@04pDiLzE<+;(h#iIsd?4JSukm@&n%~0bRu1r4NY=)g$l6f@ z^VKIBV!X-U+50(nZsw`>N*?>8%`h@J$*;EOn62)VaHI7|Tg~GPwu3lZlO7W@-tco+ ziBgH#`qm_*5P7r}EiFxsb=5JuhjYY0pNv6nfKdk8&Lm`?{{Y?4Mk|0;}Ejf;<6x#~I}j`59r{xu#i z!BgSUcF@~8a4p|yhO*(VAZ`RjeicGm4DPAYP6xca5g+xT&1FsqX_JRaZP{-1ax1w$ z@h!W|D?k)Kkl>K>K-i(hP&}NJg`mYC7|LA8%-#3JGCeJXXXfr3zPabuY`!zMztVaj zAcFM4mh}w8fvhgV#_nF-o}d!(NKY=4?eX7=wGa>?rnyk0IAK)=u31V@m~78gB0w0b5|GSQ&^{d5lRE$P67Q-QZUqL~ z2flUl8kGufUJG$>ikjDxm{PN-(;hWN%@0w&Wj;mC4U})02ZIl1s&gr8R%-_ya0T>{liQAL#+~jl2g}UHX={gwvc}vo#zb2IdyR*=~R2qzH)EXMr@7!_k|hn?v+wBF&7pg@2`7k&TH3GAx%>vMY_6` z3U99GLn{ZWvf^@M!pYdJ9H6aN%kFE;l@j)53FGx9|{z3s69)Nnm;p z@qUQFUYzyXwLDczN1%gElS=4q;h`<+3P=DjV+8n<10Hd}(*hKq%sOb2qgOSnnACx+ z3)b~e@s|Ba&#Rr?UE6Cm_w8!SW_z;+&OLj(d$X%MySg*m{j2}@c<;K*uHNh(d|BPq zov{e;3KgM{Y~#STZ5iR+ye@UeAF#D$Ng#-W6I74DlfhC@AxcdOz2U=TDbYZ3T4WW5 zprB+!aZztU_~lVhl)RN}N85r;USW26sM|x}|L9k!fGf1yL!}lcnMwbx#R+Sl)9lw# z3f`ND0O;c6rnxMS8Z>itVl*UXR(O7^Ytel7M9Z(zh<*AjAXbt z9@6H%U2D5u$aZG;JeA4zclGv|4ck|5>Mf;gdxhnwv3{wpMn&TC4Ejar*;309MuRLz zbj*@D!r}f;5jye4!-EE-52l@|WJR)iS@z8PSBOjnZ=sd26&Ck>4hG2xA1Cp+jU)c< z*W^0102e%Z?S<@wp6Qk^!B?9*u(#3o_@3JYhRWMiXpb8KR}RX7+;e(e79q0uD}nm0 zy|VQ7d!;xU#Suh}{L{c)d?2|(CD8J9xMv;W;lDch4lj!3s{pfxF@cA8_{Y<*2QCAT z^Fdv^z>S4b3{@!tv8@_KP*~MIt}wWX#ZHwrn5*^#57Q4=Akw;mSh@t#E>;f-bcr5Z zgn_CNO05EZ02i$Ux=UK}V_MhaDKVQ*`Z9;-KR2I?k3@K8&S!*lV%3yKiIi>Kz5R|% zK?ok)H0dL8w(i*8+n0fFc1y@?jVE$(aDAvzG$bUksj%N+!Pt=L+>Y%@@DN zJ?u+2l+xL}!aB0N!BRCvhox24HGHXMM7Jz3h3Efo9hQdp?9OSr-@;BEVK_^oGr0N9 zRq!ZwD}#053>8Gq8xo4bVJ)d9pG$#bYXvYwC?&>Rm1Ken(yqYd)(&_s;vxH{G2G0* z3chJ<0bGyi#KQ)tGwdZ}ENcLVb)C1RHT8Ti{|_gd=t#Rcs?TpV)$rgVRUbD+pcYsh zf`%v#0lgnW&?v>j-)qG=W$Eb$0y;oLXCVC8HMN3+1M~(#iLRrs^emnDj0+DKV6zM z-!6QcP`?z7SWmJ%PJ=2>&ZDx;f|Dn9FjMMQFOdBt`rki@UZKbPWj|zKjG(O+9%7-4Msu4 z76>G4_g1St5Vgrd7aWBYFklV03$_{s`4^w5wD&-EwC8TP%Hj>SnRs0ldoI`jis?U5 zJlW*#x30LS#92~eMr9wLwdQ4TJE-Pl;2~44{G@(+=Y?&@*8onzj#x`He1=A?xRtF5 zoFIX&v!-TbtBy6mm2J(aQ`|Jhofw_5HeIlZ7U0ao3d#yE?|)!+#-rjh@Fay+`_;B+ zM8x>l*b(^ULSqjfr_ZKu%*F4EUVPnT&7!}Ufu3!>yZW-3{{ET=w$K5VB?K_B@f^m)Qj^z?%_7r_5WIGHSlW-?ZWw7J8Y>qwieW$rWX z%JeI}Tjs>G=y;hEisC|W>-L&U&H;B>+!VAEAD1)nU}Du?H{qKD%9F;>*_1a{<^&ttKmG6V6EaMCD! z^w_$!FLr2KiT~yWLsDQ)A$l>Eq}#ccck%N*LBT;8OWygzI5_9HtV6 zbyUws9v5qxVI4eTrB)xQ%Z^y(Bt*QfiuE0LBob~5$h=l*t73A|(|5(emP)ijI$gal z2ojMGnn7TCg0hI>+}-!TXHDUng*Dk1gQO3hUm{OeEMHQJVSVv7N0-mM2NMso%CN?C zvTTA<1nTp%!CeN$c+|!eYmom#g9`I2jp5V9tUODkezqAo=DCQ68{->Azn2Iw5*F=E zH}Xe&Z;J^@P?Y8ZW*s#3_c!vn+zri*{L!2I&9n79C>&`g00LT&_wgAh)$(8?PY&=u zcprZaNh99BvTfb~fA}m#NwwxtoYZm7g}EFgIEwa4D?|f#c|Xf(h%Soof(T-ZYM!Ti z+=iaJkp@?ax9c2#lA?*$1l-|4;g`oDsff3KrLdWCD9JE$v|~flmkMm34?$?p-CFm!!RADPlP%DcQhWPGx>1W?S{Yx=c(*dYW@4J zyXcr+D)1Cf@(Dvg7#7#{m*|I=jW|~8c0KdJ8XnsrX6zn(;tBId^do&qUz%mOr2W9~`=$x9R8whs zUrZGlLSZ@*#%$WO$!tj&b2}a4DIsC#oxATgS&7aU`JDM%!kG2+X_uNa;uH8OH<>4; zGw4%9{uoN1V&;gyGSyu93q#>K6--f9?fOiH|~N!R)F z=NmqfFy@Xs?l62JVa%O(-f0*_RBdgo5=(#h!ygQPmoVnud+#+2uJFQz3yoNlShQ%7 zsVFn1uC7i@w$7S0%iLII%#tNbM23I)^5y2vGGiJV8q9(+V^*$QX&x*y=HZ7QHp|P5 zX=-XR50@F!($Zp9l^N64)@B|nGp4=0-E1f`=FvwVHP4h8Q(0LlG}^j#>&%WaW1e{8 z3A3xrm<<~?m|U5*>KkRoJpJ_3hW3{k^UO2P7|NF!^Vh%r)zG0bW1f5NIYS?o8PnO> zsir!&ZQEw(3)QE(W+DDFG+t)RjvYG;{j1EFuC6Xa&^mbe<(CZ)mKoF2(}Q!TF@1e~ zM$EnS_xBqcP=C%|{{GYbH|ho5;6;0O4by(Kf^yD{3w2gF9ZGvKQjv=kjL>eRRBN1&)f*`6n^GbfS==M?o1kU^UXJ#KO*Q0 z{LCVNXYe!20FL8l9s>9ceg+aGd=5YJD8PT=XPyLzMfHN&4Dbj1%vOLG@iRLB{*0g5 zg?$3cWIvqFe8W=@n!n>KmgjSZ4g#L)qVEkIN*eQWW22#uB}~7cLaOt0{%?l9MDUmV zC0{i3twuS=7YtoW8uKP}s2R#-jMb`O_yZ(7$Nzx(^(P2FM}stIcnt6NF9YgY;J}>K^;`dtoEQ2wZNzaQmRA1K&~b@@h7x@sde>|)^tD8N zpWZd}(=1~aFUDv&0EqTIX80J=yvO@?7={O6y0n2V8NLAU{XRZ!$|{Um`q~b2eT6YE zy+j3bXN56$(>r&YC19)ZVLohHD~#bIHG9m)3S%C8aJzXP0niA$XkG${4f8XTvmjkC zdlmcyb1M&ocMlkP#{nPW>m|N`I(=GU%*)7*#v~1mqDus9!_)%wEe-RxhW7#fC!e9O z4ZmAqOh13J+wezl`1mdVlmBV>E5tb7NADYk=L??VZ{f3QwtyegkDvwcQlOFlGARkB z3p`@d07ur)adQjk*K>S|zcjS~Pu1`_vru9hV;)4%&$4_q&NimGi$6212#eZoG*2Lw z?6*$=`kqcdZ#riivjLtz%}auVFYrH2KT;gs@PK)JwlP`y6#cn>wlROBgEVgF?b*ik z(I6c%bW{^zw$O28NN1Z>^=eZeeQoGFd{>%-E&x78Q+&+OB}uof-SDtnwj>N6nr+N2 z{5F4T_+#XM;?Mk!`v2hbf2N~`$C2g&e?sRC3tqXjHT;8yV;+}*@CPwq=2RN9n2&{9 z0dHl#xw~syrlorzW14$%U9Svep5ED&%b4a@20C|jW}!pZ{Q5vPV_Gs@FJ??jSN|&m z8Pn3;x$R~A?b)_7v%R@{S8vaDBS`S)sjlAcOwP1qdtd7@FAQY6_q^8IyWO;QZqMW- z5|sLK*~~zH#%$Z!yREmoGnX-~z1hxg{O#Ex*48ynutNUfsx~H?ptm@3Z+}_*0 zJ=2rz-L7xhOh&^W+u8YYmxMjh-SuiFe0U<;+4EvXzht-V?9zlAJ5gu}-I(bNu{WYD zk~K1uw|1Bj#M`EU>?;GkUHyv8)^b%Q)3?5>=VbvlzPv}%cJ0zsz1v^RXiZjkWiu~i zySBY-R(GSO+RUqavzh*!X8&SmS5N;7z1d#VzO%PKrx8$H`J;6ftoTzWf9v(HeW|nm z+R(-Naf$x3RR39~|18&kR_H$s`cI?$qsbO4uEmOLu?8?WxEd5!gW_sXTn&n= zL2)%Gt_H=`V3R8@`&V%_Dy~Mw)u^}{6<4F;YE)c}imOp^H3AE!tNeW?)7{)2!`$tw(XL z&Ft#!Y2DeiV@Gd~S=;sEPF-mP(v?L)EF%Jib)@*!mP-RM^97Qk31k-zh26@bZ+7zQ zi(f~=Ye2U#m&tU?N+Dl;p1bV2)!o&T=`rg%U(EF6I?cMyY;SLmS(n+~HLxqTFl&II zQ82!mXh^7~zS|X0U)B#~`?@ps#n(l@h4R~Xus&bZw$_la8tS{Qhv>LG9yms!`$v`dY;0ZDcXnq&HRVl48K6)`yoD03@9gW`)A{tyu0FFq)46Tu`hgugOkXBD zV5FnhcMt3`>w90@ZrAQUZ75{Ap|^jJZfqNR_jGC>ZtUE?y*s0!c6e;;?AdPP`G)P! zboTGeba$JLU74PqPUFT)XzH-t^!N0>X5wugM$D$p9pFk%-;Z(*)k2-O!wd!L6I{Y^`ExLq0apK08O z;(@?bg=k(YgxhC@Apfoq7=a2ww^|_xZz}|vNFhi}D+KLng`i=g5Ok&$f@q0Ckn~gt z@|_Ans#76R-m&1p5DH$G4Rz{Y6-H!AZ78m(EeNws7R1%Pf+9U;!GKr9qHSovE7FNJ zG~gBUdp0!Sh19ly|J(F&p06oSPlh2YshA$X@$2y7{Z)_4e3`7{iEGZlhC zYlU#jrVw;T6oM;Dg=7?1P>hX9-;1*o3qk%z@T@c$gaH()^bl0%G)(NRN)2FqL?N)P6sq$OjQeO9ZrBupP>Dk8Jp`8? z8uq-0c6taZ$NF`*hX`CI4Wxqs1Ov;49t+^90K#*Njc_i2aQCXA!o9L!z{>$I2fQ5c za=^<0F9*C(%U86O9;)`xJP*O{fW`yQN})OrHF&7WLu)*=-b3J0Xft4Pr z_Ru^J)p%%uhw41k;30@#DZVuxTJIq+mGtZL9@^=lJ`e5o5Df+pEG11XEF}vb3!&gC z+0ZiqJQqL+IB5h9csbx@u&Qi?fR_Va4tP1><$xFRl8T_xL)9Ld=b;)8E$~pChZ;Nt zYZ;1fjfd8IXtRf&_s~ucflZ}pcYBBi19&iihXM%Zlcu6m0R$h)hMo)Hqz5_R<$#w1 zUSVn}1`c?Izhy%MUJiJn5uo2IJyh+Xc^<0q&;k$Dd8oldO&(g~q4gfx>>+T=G+(%G zRjAKHyFEmM0X!JMLjgP%z*7M{6F@M|Gy|ISAP2l0@N&S*0WSx<9Po;NM#akkFZgO2 zSm~i^56$xsSZ*3`frsim)Zn2e53TV~Dd`hju@_0y$^#ZM9?0yeE-9!&+>nNldu$w$ zG_e;=)1T#506$2hKs;Y)uMh;{Ehe*4LOveemr&{O%oI`iD_Cp6DFvQiqqsg(M&(w~ z?2JD%#pCgG`6wc@(Vxrq=d6hs4Vmeg5Do~P85y5y`+&1Q13aKmx8`UeBtrVT`;_&7Fz7Pe{FBsk?q}uC=vuwj-n(nhlu^#I(vc~ za7@%O0vLi3 z|BiW;c<16lL-R3}GLJo8MbKK56tg8TS_;!8K`s%-Bo9NlR+3)PRwG5Lt0{WCilRS5 z;I5G)=n;;>@x!_P+q}$$H31Ca%*L`@Wvl1|Hgc5Z?;1IRMsr6s`zrT^2e|K zP9!-ZE6oM$IH`{>;o1)>Ia;7Q&yZ^)9 zyZA?0T>s;<$r6G@H|lDmrERKfiz1ki5E8NF$=;LfjY|Nl7y~R2%&o~TmlpdCBmtH+ ziVA9rSZ%E(V%1jVF1%hd|Jd*KK6804yWwK>`~CbrFCR5NJI`FsoH;Xd=FGVe$R+VE z`Pa5xk}6~3SUtIffyM!Brhm=L;Rbqp7=fec+PhqX*im>@7*blutzv4sm{vLt>c@q9 z-8zTPUs96<#+qdHy-cc)(0IU;Z;jHrfF=ii7&`=L->!SLVKR-_eP`Egub+f(9EZ{g zX|s|K_Ns*&pahC;8V{g;akF3gOn3ytbIiYPd;NqsnOOH~!vz1D&*jC}cBlvZ(ptFU zrc&Eb9#)Lvi*^hOMHwifr}{}Wzd znL;n8r015H3|)&)q@@<%Gly_H2Q&EcCODTiRYT8R*U8HVi}NqIw4sj$ z`0Vdx#MjwAqgUipDcRg?5 z=kqOi-JbE2z8CB^bX_2(bEdPvgl(r`*IE*n2s-1foX>J&DRNAjoWfv0A)g#JA65`K zogSgPI^EXK0tC8d(r&NCE)w7~&jO1jahYEgrSQY>Mj@_s}FW zz4#=>((u|eS9jwXVY+h zdr{2z5Jw81uuN`mq6M|QG0Mw57B9aL;$>?yEx2m3P_Oi41HtS0ibl!JzOG6?j2now53T~-YTwKRz^>=aMSJK}AhRlqK z0Aaxe7*bU~y8QfYTG?wDi?8F~=o%2M0-_@%scsg=_DZiL(8zoUA5W{r-?6~j>_drS7|qa@tc{j6Z{czC zf(RrsrZIn0hknWW;arZ8ZFU5E_kpXIYhblJ3xkQB0D~?EyqNO*s+^D5MG@P9+!;70 zdn|#U=6QI614kB>u@uP+Sr7i28AY5-1kO?dSDr%xec{z`rJ* zMREouafBZcAJK_!H@1S}5;b-+{LhlNY2xKgoB0uFT}%|n<4A+4epiOmEntNBe%1$iI*^|4Q7*rqu*D$Un*S*Ht zn-usWv(`G+*Z@DS4W6*Snzh8t0<|#GTA`Oj+el6_10Y?nQhL9I&NH>AXN8j|bL^75 z^oVPCOWl47A0wyj^NqaJ4cjd78b_BUW1;~=_}Y2?cfG|Henkt5!S#%|s%e0qF=IUE z-w%2_N&xBg7)!+xT1j-D$>&vMQ~@Sh#iFCn&{!6y&Qtr-;sk2tJZn`hMt7j zb-SY&vr}Szvr09~sF**Xl3eFa?=S5A&8xPJWmi~_ho1P=Q@>fc?%Cfy{aownw)Qn0 zYdgDIet#f8Q8-i_8Xuh8wR_LreXk7v;o#2wJ4Q#+nedj#@47cd$I)g zXq`5IgMjs?@-i6`O=%z}X6o!}1ze#^5lbC=1&VSKoa>9F-n# z?ycA6fBfGjQCu@QBTKZ&;ie_J^5G@Yz$eK5Xgs0w(@S)f{4?_^jxN#Fi?^3(h{SuQ zDm?J`QCC%3N>Z{4acQNrR0}I1>cU|Qu7g>taqbrww zY+Xr+R-_)}g6P#PXvHI?BlJ+F3O{U=>4MDRFc7qHsUdjCU>7MXe2fi{J>uYw;XE22 zo5<&e4(5l|I~=yD-|0wS*@$tz^43gerF-OV_$w} z!Ro9o<4xpUVqw@1+A`p68;bdfL*(iU?MCyv2aCgnO*=_R$NZ-6BZK3n0ZJejtkpfT zxP7ul28V~oc6t)E=kI$~G*1qV9K0LR^Xis%SJ-4ZQ*cQMS6Ws5x8U-ZjKZO_k4G+0 z)kM$Lp1Tw~D{Crp>u!!(caaEAN}2sR1(*w_OA$Fama7sHNm|)CMI_{>0MU9bW2FO! zL5`GdenMsV5=^rzT9VzHg*jw&+9E!;fzR)M7zxJU?9p#5!@F zA9Lp?5SNJa2dZR8M4b!#tb$;t&Y|#7BhGKNlc=6ralTI`krNRo(e-O*XKt%oBDiw8 zaSJaOgPU5#S;Ry>#mhbznu^o>M7LksUY^*nh@a?29ML27UE-_5;-4?b2*UesF?}^P zg9(O?oWr$8x!9~pJ0#BkLh-NKe@7d6w!li$;ju>y7_5eSoZ`OO$ExS&)|| z{k-(YdR~f<2mb~9L21_{s{1kNzPC=fkd&S!Rp2@;N208@FL^q_KMbjmy||RN!}lfm znitnaNnGI9F;DR7u|I_$G0Du5{k?oeEx@<6#TNZc$u z#RZ8?k`5`JyQND8+L0Dy^KNzF4Q3ZZXy0zbml@!&Q{V&L?VlFGU!dS<=Yi`rs5jav zh<`$gh<1{6c>*;=q{(fNB94#>p(7u>AVSH^kp!hr(lK+SQ2<$JciCxl$3!|~jxD>2HA7BvrDhhidhnYd@82s{KtrcfzLPp=g!zS(uaanFci5_JAv;y2pqo+<7MQ zlAWQ4+S=(zkSQbHlnyY2)g0Bk6K}~W8Fp;T&}4CN*#7Nh*P{9H!e0Bc&Asi-AB^lB zoY*|pgGeyj$ngVxWdqx~!K3LPZmtk&1M~$fqGU|9dkFeJzEg9Pg^964>Qgj7oG;`R zYue5RWV!HAVPtUJTHR7rMIn(dMDzQHcIG34#m{!b=9#fgd1+N9XNgZVGEfS*L-kgJe7oxfJV7*RY*sW zg0md-fb=OJ%P~&8L0asjzf6RNlFt4%7-xUg^pDIKyOvwUrOOq@gCjhZ3rt=Op8Yt7 zkhGSn)$^U=N})FQGf?3ib71#@3E1k%ht`P-e>9bTULa3_&z7wy3(uEu;ukKG@5}MQ ziOH$~Ef$y!UG1G!G<0?}Gq#d|s`Q0oJ*sBIHjJops9o)h1j7OG^`nfnU}sa9|1YNl zcDs7ju6~SSj?$Nq(XpY6!cS57Om$NQ#c+L7^%g{$+7Ta}QuwS;(p>p-P8iX))2*8$ z80{_Mp-N|JW(tB|5AfMu$lkB>8>FGKi@o_N9sd+KL+iUG*8K2fTW9NJGeUBW^XW z&1RP9?p;K<(iNtpBLb?p5aiS1N?m}@Ku?{Pg}E^9(3CGUe~90d(M=DVfVQ%Qqd0s} zEcrP;r|W(aA&?P7>rpG`8N>sY8*=`^(;RP8oADI zKyi>?k!-DaSD^wPJm{iS9!|aeE(|$BgK9~T=On|h`~u3tExnp-Hf4z~^oT=`3(>JFs0;LdM&(kj zt?g#S{Ftu5u~5*U&vJF1M&s~g#;=gGOuKRZH(eH*g9SA1x_?m@I43F^SEMQCAJY}s zYnbZzKKTW0!_13cfxzFBebSLe3gLHvoBTjQC&fa`HaRcgFh-+<^`-BA0-bAsys(OGBULvirtBbIyU&QLOuGl!)VZ;$Mqsu;tyVK$*$fuS# zSGjm&e!or&%7*$lc0pe1hJUOY(v&DRPKY;2r(ycl#+m?sS4@$(?bQZ9ejG&)HpW-bN)8j%XjYs)yWlj|KS5Z-Fr_WFga!%^@P?kxOV^Eba*?FlRR0b}=&$Lbwalbh~FNgg}iHNX2z)$eE zNJq3Lz%SNYaQJpYoZu&F;}J3cs9MuVySXwBx<-whPS9kO?rG)rC;Omzo?DQ}EdN9m zB&95SqR4t@5OS49N0XggK6U+5#rte6_1)sQzq6TUoP#9=@4L#LSfse8T^xT8vvF3G z^ae;gq=pPU&aVNy6JR3t{XZayJ82r^?pz{Eetr^+7krp0`qoo}cww_zryHOHq~}9Z z7oXGL0{rOjr4F5#FPZ^Aqd$Xj!Xe8n@0iPS_lh-Dorq#aspO$ixidNTA_E`%O^bQW zg@8qKVAZp6@Hw-I*oPt~9?VwpXw7%uDYpDq8%1FSL8LK$w`iMPqxoFt4&hp)#D&#- zihpaip+dEJa@I3X-d|{*@GB67I1i4*(%oX4DssfTy&`Az55J&GmyFV1wH^E(Q8UQi7HsW; z`18Uu`2zpjZWWhNIedK%orJXsE*cy=BQCUHy`^uUaN{}$!<{+AS+*6hT_}?C8Y=Hn zhyc<0JzEkz3Nf@^zAOz{)q?d2$ZL!71Cr-KN0bedn0u?Ql7 z<}3aQv3gWsISSqoC$Ry*M(e#o5iVU%I~N_-!R3xSP~bCAR6Orq{vcd^PD=**@l}s5 zs0AGbxCE#KT7vr)IP`bLQ3dW%-1EYugQOOUgB9;Fgr!p~>{RA!tKl9Or{xN6|e?@u4g@<2j`U>Jh^pjtfhgMq^5XNNU9ANwMN%7T_0_Ztk=fGGwE#ZAWgM~+=6CL zxk=DVvpB#&I~$~M>Mkf3Ou=<3mxi7!NsRi%$GjYN_FQt$B=!3TGEW0`iRV%`qR-=e zAW_FpVrq6{TDI6%&HOq_rz<5>juun$6>$uujD zXt0XnLo!~1fNi^+gGGKpqf84WFYpgMNz`eyDe+(tA{0~QM1g%;7xPc(Mk|LAxD>~` zF`<~4|Gh@D2Wdczl7cDpUEo*UWsi5$ZHt%}7c?j6sU(J$OsHPUO`Xvrs8^EtqJ%;# z2W@SI>Bw8!))8K~wPE9z;u7*IzMVr=#qslN_s`GVKR>pA&cZl?PE1suY~D_rcUT`$ zI&`{YjpCx^^A#VhJdPKhzz)d)pjnvfmC|>Kf1_)$S8BOzf$IWyEt@7mM>Nz-iKjFS z(GY}b5RNMVqoF2BfDHzjc0@x#N|><|z!k#=(Bwey6Ig7T1d2|=FWU)zIW_nh@dZ^Y zrE^C3MEd@+G;JBP+-(Ps#F0=2Ze*L;<0?^{`HhnX&xrSARq80Mp>xWfX2=Z}rUtsA@>6pP4P9h{q9BIw z3q$6Vv*~H2(c|cP7oRoBu#_NEtXg?~f`y7|u1nmQTyM*!w0e&e8rDcWR2RK*coqjZ zabDg~?-jpwi5nB*4H84>j?JY(N|4l>)t#4>I6~e!kyVS`moovi(rHC%8NyzeM->X{i!37KcMzskz&4O;o3KCCAZxE|0pliTE z@4uIl6s2H!?EvW?y z-VKccCXRPg#Chq%fsC^hf{TrqG)U6RDilgeVa%&p4YLdn4>(jY3KLHz*s_{ZxRL5m z+c=`Y7kbGm$?n71!p|v>+S}!&W;eB?H+ac^lFg8+7dBsx?R{313QYu=#x~vZ$=1yt zJAKcJ=0?CkSBWc>B+nifeK?;NT4Y(}8~>Lg3g_7E54y%}|5CMhX|9wALGL}Jn=mUr zq3K3eRv`nW7 zrUy?NcM&XDa#S*mzm#ymUc;!p%B4-r*JyEty*ElDUBk-RQa-RQx{r$8bsR^;ym&(a zkBqw0)iMV3NE#;FMEi3jMbw;gBrVrT!4P_6ld(C6iuqbSmD7^9(pV-y%m9mdaZc?L z?mdKzN@cJ(;8&9;3eKBgb>Ql>62eso;^ z#YR3C_dy8^w%KX{*v(6PreC)*A^wi49V1TstQvC1=wq|`tGx=+Wxd9-GEA4m>sXN; zEAiys+ug|(hIkp5a5ow)n&oq0aq~A6N+rOLi?SrA0Ken_9wx$M*m_ldb?y=Yeu>zl zIlcZTmCpdVo|rwu&fwsCCir`v31PS_2WKVbf2T>J`nHgu1=-$DO5!Bc$-&skfxd$B z{0fxWNXkm1Oni<;t#g$BKM$*sTlkvxEpYz0Yq^g{H++lRQ{M9tSoBi|w?ST1G3V zI4}Mw{!R12zP#n%s@(}IBwe==`Q13G9_WC0$!upW^XtB+={y3`EW-KQ4L~NK=wV!M%bQq zwukLxkMGLwM(~IM#Cn(<7|%}(j7#Ihy?OWsX9EX@c0q-Fbm!Rc*u*5;mP^OBZKnTa zqIiRvDr4+PQu>9NhK%CL|7sFRfGNX+LdjWvkNFsTipuQqN#}1t>7G|6B7l^9d&Imw zZQe39x?#F(bFwLB{{HSeFuSFVb~$dmTDVs{^?RZ0s^UO&_7>ltkAER3La?Cr5|Sjwzx-ZZecQbn`qaI; z@g4W-68z-7rp>R+tN8F<-F(A+y7&|K>EeC&X{+`Z?$gceHg96ie*KI6deIcRFQ5x8 zH*ed_oA`S`+xgcw>bGCrZvZ}hzXs@m2eiS}#s{?FK0oz<{`~6)we6KS`Jir5%mkUH zgERK)wV*b>Pd%iw^7)5AbVQ`n_UkE=L7cN+KQ*tuhc(^&^kH3o#lyP#?GGEvu`eFh zkn*EH(W&CipXixe)1)DJvdQFp{}G+YKY7ITGLrB_39e=*fd{xHzs$C|7S^oXQl|kI9PRU|fKIBk zujqP|vBOlKek$!N&=L%2?B~1LSETI<98X-mV`C!~YBHPCk4$mmN2a*_4&b4nk@C@I zV8q*al5lRflVH3tx^o7s`(v2NJ{zW+68t+I|)_o9MPT>OePrQIWkqaA{ZFS zk4)wZ&OGG4wIW3Wxq#6L9&uGwBQxQFje&eLM9V5tV8Gzc6L+N$Kra8bco6JTKB!qD zQg>gsg;?Hp9z2LIAs?ORfGcHSVE54Qj-n&pGd}_&yMyC0pz)T$;i7VkYumX=N4fMn zcCe5iog5k)b)?B4$Op$q$l9$he`u2FV9Db<3x~$@=I6l3j)9%UiGh*9gVbblaB?sC zLy)#`2gmJ{p3$L#wswn*$X9|OnIA;Z9GLr{loKGArJ(kdpnUvpDj?X4X?4@^n5+{Z z^o$nr6QlIa813D)n}&nqBbod`XFG$1vEmTbiVs`ICU%)0{XM|Rq{PlWE1JoiD>_)v z{v1ri<^_zDI@Y>P_M{POyH7e{sb;cA&ZDI-2SpHAR;yVlReSEzNJ&~gPm9m?l1~9X zSA<;*%=qVC<>$#xTO5z^^H}yE!Kv3;|4yxJb>b-mAe39c)Y@6rAsv%i>S9_S+qJ&q zEo$;u?7^iBc9kI8WbE+ZS`3y-L5h7&%ouFwmb3;x%q1yAbg)X(!l^*Pf4mhIo_k$Vs=-Gh6AWYXVG*%eXR`4)8a`Uogw2 z#kJZ$EhFWcdgY~8Ivs{Xlexo>if^TI%?w8XOOi<-3WRcV;y9=~ycT1IUX_vz==;tt zMoHX`+83YFqu{9kpPit~l~_H$M%F({NU3kt_~mEp#>~BdE%Z2C$5@1XlH7!6022GE z*$uJUD(Rqlj-TUN=3#4SL#BVBRvcpkkZ$uEvI4j)m8vkLOm&_rzXBUiQUS8R71qK? zN7vgWK7cOii@0}%PFK5j^G2=Ik=C7V>8h;FWkyyM=jCPQH^#LePffuNr1YvX&ibll6x<+V|eJ*t!;2O`!Qv-Y!9=aj1g^D7{`!wpVVN;a7E2TmW zy612bs9ND?3=(0Op}R!7cmY29fa;RQ?)$3Ua&H4KPc%Zvs*`}v59MbFT;cjk-u%|_ zxtILfDw7;k!or*SO0r%JtdVVd=1;kn5b-O8G(Z2=Nc91}DNa@QnX1ivO+Xm#hcd;Y z{i0kIPf%kZi0Tz_O^ahq5@n8?9$atf-hviXZ*f1Mk^}tcHYL_9^KTuPy$Q_rH)`Ma z0X_?NQc^v+A4A;0%T_%v_cro!2hE1l8q=T_x;&R74uu^34YNea?UTGb5mcHUIwN!o z=pD)_)BKvbrJEL0F1IRl73UzRnKigtKgJ$w6(z#4k~1nwRP9Y^4* z(mwIFqvi>5LL94oj9=b}W6ZILPfnE+x^k&HjeA7ZCvt?N?^~4MU48=DDU>*{5a36Z z*3>P!XE_u!{_CFN?v5bxiRsFo+I`erDw7{&(>=d)={AcvDBHEX%%}@zgtY((Tg!NP zBRO+FEbCH>LqY!Pf;({420wF9zE1uTomKe>4g-@9P|yVzP2jD10-F^|H^a*Z{k*)b z9tuV)w5lvG*OICTmJ;t;0G3oPGiEIyC8Dz!Obuh1&nXyT@uDDX=z=42>cj+}#gZ|M zx`00o_cgG_a%oi_l*p{ec*#JaKgdEhOL#}Z093~+L_9gS6 z2G5vxVTRd^kQ$d;FhMhqs5aoJn~4iXn_EmF{DU1p!kAEN#Z_|3D*mG&03~YQzh)v5 zlQI9iV!4j{L;OvNWqb5*;^IP{i^#RTJXw`CYX>H{pOrRRUt&`(5w;ji1n+U<8k#&zT zToyN!YC-9_5Xx)HT;M}Y8QhZ}7)AUe1e|}Wd0Q^s z{M0k>IawGi4DD>j1z7V_%}-3eu)X;=&40vE_^~H;HS2%bV^7PZNw(yP$>t{}*%OnL zfQ1%?}6oI`$GB>2Q4KubV`UFj&epFWjI?cWGp=Aibms z91CSCH`t`-g(|(;X<=24lkIiTCwh9{l846r*^ryUJb zB)a=0!agxM#qm1bqH_ zsi&T5UbX6({X-)w*RE19r$nC_{gf^p&d(FyVka> zY-wHD(%Rh8`fN+fvn?&FTJ+PrqNTN^<(`!*S2o|Giq$Qxt5>#ku3X*G+`9JJ)m_iF zcDSlo-O>V}oDTun(u^dkz4hs~w$;rmSFT)n&x+<>J~ueAbMJ5OS<(EA6egNS3F_Cb zX*WsqC{N4Ht*veCos)rL6U#NPNWZvy@s`MBV^R63qN(<1IF?o*c*}JpGl@QH{Th_o zrT^#bRYz|w7q?`&NJLeR7e~)K`XcGLwSKMqN_DwAyEYxmMy&N~r2N2Dc5ONpO<3z& z*M}l~y7s>Ht)A|MyRF`MIALjt1R9BEsi_5EibSkLIF-~jqiM=cbxTRg`ZW-xs8kJg zJheU)&){d2{w7mqfKyg)ZzO5i0vcCGGFB#*%9tTA$Xpn;Su5ESOBvi62@DOe6Tew2 zoyzvPGH%;!AodJK&Pt}!y%uCN>({LB`aN}}I;tvk2h`ET>&(|aba=mzT7aGs@kq9t zNXbDOtv$WH)=pP%TKmG;Udv4&twce4Jo%#Ws5RnBTOG?KveuqiEXse^A zFPXHYVz{fs+Hk5TY$?rg_m@OZPcH^BD)r4>A3L+DM31F4%w32ABv`3QPj+8khRi%xfqcO zs%Tk#(EC431B}K(M{@;oTOylCSR3=ZTp+h)dLtQY^Wdl}wLRP&i(BLQiK06>5|4zf z#KhnsPjX)}Vnq&lE9vRW#;wHIu)D?fzFc?A3J(|ExNFbEv7AigJ#}Yt*{n4=I_BO4 z+q1D~uaz4vy60_sHr^e#azmr9xB<*1Vp%IQxZhp(nn)sNZQVOma6_^t+Lw-43B-AF z)v_kmouSTmx|8GG$t@usKZl-}Y=4~P4#?mrYKJk7?#$+XqCckq=VPyTo}RkPNU z+?%50)$Zg(Z#ZFvC&mtVfbWUN!d7^AaHktJYx;U4F>7f5*n|f+eZAS3H9R!xMM7V; zw~yNGa<|);>rPX8n>Rh3q;xmyu_hZ&My<%$#GqQA6qT;Yrs4@JoFCfb!A`CZTkXW) zp;mYOxxQ>KrMnmFHMv|mYi-?|A9OFg9pQLfj@DZDaCL;^y>htLy2q;{98dLFTZYDl z^WLiZ!g4mWxyPU*+?SC!YIBcSM>y3Zk1kNUwsb%RNFJk!(Uj)$ZwFB-G#t)a;i1Xjd**6KG@6rR>ZvIj z?+sg>^gJDpCSx%8P<*Lb1rNy~|{#tT(8 zq9(2fRncrVL5+8MkQ>cOpgO!w8!ysI?x9#BvI` zZJut#atf+84^;73cfv{!PK=GY=X^&zp-7>_(|A0g2(-fkZak@|s>1_SyjM+|)!xQ? z)wEgd0XGp*aD%J1U36J;yr|sdSJ0;GX0iiF8taSmOaVk%`F3yvEbP zL?){iYY$42eTqWcJyj)BibC7HB~pq)+dXY0GYLuTT^?|gnLfEzb$L426A4T5>GHJE z6Uj(|>+-bG6YY_t+vNebCl-|-+C7c;#By>Lw0j!wjl|`mw5H-iuUvc9c&h4+CFO$A z>4B;@mXb?Mr>7si@rbOd(*tgAIwl9I)ia}dGhsQjt)98ro5@HjY4yzJzJzLHb;XCQ z?BHroReebX?rKlteZ2|UMu(^8eZ74WstymXQr$6$-8N4fsctn;Z62snVKwG$p2kzT zZb?3Cy=~;ul6=;Bph}11a;@z2%&2s@S1x3oo;jFKWMzppp2pK^9b4@g*>o}~+g{`8 zMmm|2(5~@xJl&%RvDFK0k0QiYPyf=rePL_7I59r#-upY!Y7JfOp{fkHRPY4to?c|a zig?;RKxM*;c-lSP$f(tLwTC`4$*5c}x;z-nBy+OuE)UK#y^$X4`TX#(hh^=^^rhm~ zrorJ6?=qc@D{5==U@99|)Yj&~RJKo%`dUvnvVDrw*LpghO({}e>p@jEmF=;z6N953 zhN~kNRb;r@(|9hb$Z)j>++3_XZ575~6XV|fq4PoG)Zu|DmsXRb!_$vkMoo?mH@Isf zk=}@v94l1t_-iAHNX**2cWAQUA)mF$TsUK8hj*n0ce)8{ZBL>nZKVhI!i+kYL=ECW2Ytt)-Do!wKbCFEaiVlrb9FRIAy^%g^WNhco!O0=_9^Dzu^hB*_ zK0jX3qt1A5xSLKb6-{-<(}{#NJh(qUx+_27LUw1eJDRa}j!leC4h_3`{m!0nG-6HW z2PgODhuv&7mgA&gAYRYF8p1?y+)%!`0wS#=~(dJ~WZvF)`#hsC6a#vI%SF-m#ry zz?&PNJ>9XK6&;*-rSkaL)q{DwsgTcC!C6l(m$CK?4vkLk7@KfU+OFPMA|}VEvVVQx zCDKEag+m+1y!h-(_axPEsREyU*?81S4IUV+GDfLfJZfzmn>7Tw z17l*3UWyP}Hz19MVN?Gx6w3o=D%3hkX z65WYzYt!K9t}4_`Ut?6Z3U`pQl2}M-L97&)q^#atCZXD`kRGJ0zFa~=RkcUybU0?^ z#t!VNimNOpmL%6In9OA|DJwTPK6q$w>)xSp*Lsw;!nsJ&+B`8hIypW#ksoynPVhOC zwiY6%v=vQv=M)Q7Nk?fbp2&r*g~%*zC8O!A6(5FZsgiusR!?`b&)PJ&Yu9kTa-~UI zJ>dwpkv)40RR$w%^+Zxh`MC<^rmfyY54gg7ezfZ6OgfvS&AuA{khXH!o)k9x!F^+u zkY}uLG7(n;QbkmhvBHoQrH6Kn0{V&}%UCgp;^ctlD!J^874Plqwo>_#vC+uhq20SZ zY-+|zc1JRjOsg>i87q^C_gdYfg`wXU^VQ(bWO`EywN==stQAfq;#9v`9b8nEwPL*) znW6fUmbK!MZrWO_FRxiEnMkNLziJnzLN!!hyOAN8u~Le+3lA43-Iq!^D;!NJ&ZGLap0i>Z-Aw>dK?*r59*xO<67yC$ z$&jNb1NrRe?%}ZmRn~``6;EkoR>wuoO7=!GkU5X;+?(Ikjf0OHTRE#In@cE?sEV$f zmCZ(CifG+qhAS)F_H5j3btD|NBFRXv)ib((aCm6f`Ze3eM`9BbWA47CtXwvow6=|pY%1>DnV)oD zF{Z7)WG;-anXz?Ny4p&w>A}fYs+hGq3d4?q+VOaqz)zP4id#9sP~+FqZMl|{)^Kma^5`hE z#=CpN7F`~?ZouPx$zIE?FwvUpNhWc17zT|KNd3S8^4h*^4qdENv+%UJHq#xp26m54jCd}J!Z9n`o$j?l+r~!} zHLY)3zou<{d;2Tv*MwYMjwY;dE|IZ9J-d+S;P}Y;_DSe`wCtx6Yg^Z^Y3=IjT;JN# zw!XEsYyBF>^=@x>q}QsVDMH-=p<&i;&DuZpYTAUT$UKmBwqh2 zjthDOR5nXY=pmu#6JCoevedHBRpGo&k$ z?2c$946RJ#82Gf6ibP4X;+Cp0Hn8XwI&Lq+vVEOyz*GQ4`mAWCJEEtF@7F?qYm<`FisY)Gsa(g$;bHTulShw zVARJpPx=^t{Z$|1rx5d2T!**(8h*;h_zC_WALB=1hq^;d`PjqaGaut0iyJ;x|8NZ} z`VeCs|J2fdwe(Lt^Ra;W4`1+mG4s)X@_jK|%^}96EUBrvmOY?odNF&5HBg-o=#}WdViv0D&{g9g zzF)n%DvWj&4c7(Pma2-c3o|p-HDVWHa;mBP-HP+Mg<5S@wy3)L)j}G$)wHs{qh9W< z8M5z1)2pgB+^zJ1zY`z0fIeAu_V7nFvme#W2L5-bnJuJt{GR@@z9RD9G3*M!z`d#ZZ{NGhayaUaJJ5yS`r5&_lgT7bI#=Fq{(9Pe)?eZNfPW}MC z2>y%PPSw-@;%@whFsJ@exzu@Eep}_zTR5WlpQ(C!JKd%q6;rD!rruKJ>kf4))Pzs} zZ`X3YOZO}Pf6$A)txDf*6=(0*#mwzBY;UCxrD!bsJ?P=yiCYcR++8@vxvl==k1D{9 z!{%MM5mJM3CrZP&S1?^rt=P133l-Gv;o-5Jq*cWR{^xnPsje<2wc2d;GOxay{l%qt z=2nLD7OGH^v-RqXo}a9^+LwhC3abF1lb|wJQK9prr%vZ58+fBYj2DOEn^voH>d-mV zhNY&jBSD9}x&u9Am&&)J2eu}+f!t2ATeQ=3j|f>!cTA~a2Ms96s>FDTaZeF{lQ@Kf&vDuzr{L|30xjpwYrUHhtRl6qgI}7{s+9h@l zF*V+I2TNs8q-%6V&%;9j51&RvGK2}igJR8%xtCY%%I_%d3F*M7`5>Kt;tk{0*dnH?HO~KC&zLx(vM<#5 zI2te4Ge)ry=z%_MwdUcG{a(P}cvS0dIFa%GJIM&x9=el^2tV?(JIRO;GNC)kh^AZb zBqJhYcU8|=Ip8lWW$YD|c_EAw2^E(zCcaTQ0ZTQ6qt`LSBz8OtB0N<+VO|oSS#PhmFB-p5!BF*{U@ z&}uyj5IR*R{Z#D{CZl-mPI6Lcp;LE~6M4j2cajqXBK}rAXC;=zKN>MDRQ83i)Pg#1 zHZt}M;&dQPgckuNrq zqgwG5{}`BR;B$vV4GvThc!dY{t;!+Drl-N8_Z+S3xFanEaEpY9=yz73w6rim8V1P@?|E}P{Y`Ut%f+}_-mo28sv7-Mi8_y@DjqE zVe}+@G%?0rBpLu+$XGeOOh?G!N9|XHOOtVPU}mFUDWaN875}zV0qg@59qDI29na=z zA7hA=9`wY7V!!pt*ypt>s5}U9G26t;FNT8sTM?HQK_6?yMKR+mEau;0LW>JEZQ@__ z?P2xJUkLDWq)8l)hA3`2O}KjcDNz>Ssrf^!|RS0sckMVQ_?mS&7SO>_aS7s0aY*dCL{rx|0*DUp}# z)W0#to{*^sz$(jAEMjnOb&TIIsT6=O^Zaf<-N6 z7#tep{o^!o>icZuQ6XB!@L0snm zaga}oBeh#L@VRkuQ{kj6-a|jI4xB|$%4NkRFKyRR6~#>uGj=irK;1up)g*)6*bw1UC^@#j(1_ zHi~0$AJb4pL(8d@#_R=g!7p2PHM|0dZ^CGnQ=#SkGPY|_9NDN_*5hQFrwW^j;?MZx zXg=p?UJvrLm}$h6b`2`R)%BR!3yvbl5UvyRyN>bWW}Jx9aJ z0z1kd9&w%ihx#PRV+tygm&8t3&-HKF3Y;`4l3(m52S_u+bpyY8|aYl6t!sW1A@rvEOAH*sTqe zhLBw{&BQZQVGHTEE1uyt8R!rXxHLSP%CQtlz6|Ub2%UdMT)`G>9b1dP=6K~umrd|L~fRbXGm&LagyiE@;iz^8HTod50^D-EbxxzEzh6?_EvYwy( zIX@}hd{&f;Kj$;zt-{0nWYWh^zU0%%_aP!^4KQ1S3`Oxic)1IUek!K;w0IAZWW`i* z194bE!th2#{BzOJGD^_gG0VH>yBDPedhv^X04;l=fd1V&5 z;{3Hxv+5Ml^X)o?ZNSqh$M))e$DTMw^oF$*f$i!TpJR-@B46KTi~*V;(?Y%??-CXrMqUT8* z6{Z+5g0#DVHI>V^pO<~fLSwS{b6)QDYqVmm2GMr=e*=;(ELI<$cXAy#2<|6Xer6B> z<^j?1#l&=q8&Peo4+2L#E5)S^7!k%? zf<{njt&e&Sv56@2Z^SV$;2J2L>G9N!}T874_UliXa6o;>f z5D#+IP&~uiML2YV4v~)ydgmzr_BZ|tz#-MC^+D80z5*_ZV~q(La1LG&&tle0!(~e| zA(^Z7X>{|e{4ac_&jy|UMU_Op8dslju6C5X)&ds8QBudXL_T*(c{;E4p-w#FgP%Xx zZFTA!BA@wY?6OYL&^sS!pdcQF*O z0p&OO4RM8kY?lP7;6XkL$~iGK>I|LfBoc_mYJF-pFkadu-V`6$RcU4y*#Lws>A@k< zrhwr?zvHJDS5N?GTTLn8mA}DH^kMWg@ydwf3}SmP4Pec%aoW?n5~le5sPi=k6p9)^;cPYhC;dKiXK)O{`(H@XkQJ?A-c% zo886x70f~EVP%X`=U`x()cUY2;Q1~8oS%NyhV$pDCggGx#KTk$GZ|04xcnf$W|!+w z<&aCx^idPuR4-c_RUR3q)H%*SaiQSZL;Pr6umS-PV$}K|7{IIqH-37~QlZJRhOv43XGfXNnRWA#N+yZpaI3 zeVAi-_VM%LXv&6FlL&ITdx&GUP3qz_Kh6Ik-m^=#DdIxD8de!+*GY}o&ufWy!_z9h z_|waFMZKybWCBs$YK{3NRiwnrtVg`nJZM+6T~&lk?!I7AvS&lP_<$duu*>l`R6%4z zR}kyge%vGYxPd^A#?LB-FGP7D-_h85fHASJm-` zTc1P6xFTpBY6S{}I}RClC)TNV7FKQm?gT5y?C#aW7VxN2#m&s!2mAAcUc~4@QzJrg z%SkgLI#^hxbR&#rM4LNmw9$-c?@%A4W<)LH^Py*RfAYzj9X!sX3LYF(40~*zs+tiv z3JRPVpHnLvxMq2EY4d7$u>9`A4S>pr|3NL{wij?!uj+1bD@S*6<;@`rXYeMRyIF3- zMqC5Xnx~H25W$hep%ras62SSpf1>I)LIWF{uT#Mj62TZ^xXBqvyYz%(gDBf$rD3~(Tng4 z{I5T;_a1!?vX7nMY~-W)x2JT1Nm*Bs((g)fZco_T+}o2pg@U1jMw^+g*kp{FnckeV zcAWlg)aP8q^ggw~)Gxo9?0WjDWBfTH{tcnMW9e+!YlX|ME1yIh@cajqj@^|heC)N4q zJI;BwYR*FbAnpeBBfhLOmUh;eSHrffpvdI{)tJPNOs z0PrjKGbTzZ`$El&sanRw+xIiZ-^Mu-6J&wrWmg7p{&PGFwm3$@NaBmwJB z7<*hTVL-t`yOo%J6tJqC3)P7er#Oe4=WrHL({`ac`9FTi82<)`4JCH_A@)F7d*y=@ zcpa_h5G>RYIRXQ9bYO(IrjC9~)Yq|{Y!BPh&PLcIseC}oKwT|ByI{-KHgU6ye+#K~ zfY0(jLw1X6hENS-IW5;#+8t8?KEsb-QbW+a9Qq1Xa_p5EPLp_lW0ee9nPDc>vOpUh z$RK6y&Nj;8OTFb^4Dgu-WV*yM#r+;Mv}#Qd4t9LGKQUW4W@XRUk_Ozpjk1+ zON*(i?Es^&$qQ+rMJj4ILC}aO{FImZ>CkhiiK-uXiI-}&Yf(Os41u=FGSDWbUfRw} zHFT+=KF*~=%|?4jb25cxR0wTWV6Ncp$!oHG^nEW7wXvUdH9X9x#g%(j zG#?1GiMRMk{wAiAxEbPS@M4Jz;&mu31^DcX(3(`Y<{l&k_-yocvtk7@+$1`i7q~9P z)pLN)K7wl19cE>s=K?|(}qz5fEnQ%PG7Hb(wUJ(bO*o>thTdTMisPuCiR0Mca2@KNdALQqENfRciF(rE zmb=R1tMSXH*1mIlQfVv%S=hXR)5l#*kS>?x8-GKoI|Ld3j4{?hOE8BbRU2icqm|4{ z>Q(Z!-N)E!`rhNyl}`Ai;zW?~S)Zxtq|em!mdPOIeT=nIQ{r=zVM&dy;MX;BR}Qj7 z4Pz@QW2Q#lQ`fP<8b<7X9ot=_EB`+=8Vvq%4I{;lI>zVCcX8BY5Ep8g($NuLnhZ;7 zbp@+y8Oasv*xFiMead_ttYsu14Kndst=7*Gr)n9ohjmPxu4N=`t7GE5TCFT1-mhhJ zXsKh~pyg~}bm!Rc7)&Jg<`K_?$@uE*aTze3$vEsZ?&1P%8}cMa$2X;Wb3}X=^kZ+7 zdXUTgjBVZ5WOOdX`8IKr)|z$V3tk!yH5MBsnSCoSf@zsV4YcsTPZf0WYieWduVrkV zxFpxi(r_pk;K$O7X!>6dwV+)!#pV(|y|9&2q_?1Nl6_d<=H%XW6U*cN1TTv(c)3^XsG`>fiq>IaSM>LrojyMn`&#^{#`r+SV=x z`0PrMiI}2|3JX98f13FTD8)bn72HHlBLO-cs_ef4d?t=gYsIx<1iKJ4!x%4PfiDp@ zt~#_zd)A4$;-jQN2{xwRz@)d?0H0az!yy?uB79n0TQnicysSnIO_5d~R9!Lo?6y}a z4Nk4cimff=RAyB=th_AVl$r36m&M7fQ;qbbL#dTtCm>Cg;uxQK8elVLy`)(zE1!pw ztgG@lSLJh3b;eekRoon*egPEE{zMWnG@sFR@K+nq^EoI-QExRgnrO-?C@G0kKq~0# zEnW)pe+T%?Byn%1oMT*|?dwqVC1oimT227bO$50`8o#6@0=k+ON1N7(BeZky(q>Gb zqvC{`dh?Bv6TG%4Kw2nrSJ6EwBpsb_0Au>$=mG}(iXyh4qZqpOrK7B;Bkn$E#7D$2 zh^wH0)@*2tG+E_-F22x^LKTK)&*o60lUD0(oi)venFVG>6-k8}ox0}Gq&`-W`4;sP zvcz4~Z}wGpE1SeIKD`Xv0$zSb^eZKBppSLpl1_fiwFZj6NFGQog3i^C$f^`0P95X& z4l>TFl`r*!u6kLldN?UyVYZjQm5$}_aYg_A^0WkPZrf78&AQG)TB=tzXmw+$qsh2o z6G)_8b61KI!SsL z;GRwP%2&B2RGZ)nt_BO$e~O=i=q5%CDD=Z1@eYzoB6K=~j9-KlnO+56!2<_b$nc-g z4}o~Ajtv^_lb`WP<(6Q#`z_TNHgCJk8!y?fkReLg#9wN4 zO+WW**mn3eXhpxy$mjf;3+DgyYlwcaNGGmer0d~xi*zAzYLNy>d}CgJQl}H8JZ4oL zV~c#G@I<^LG@TcN&OZxE#pGrZsPuzSf|A_#H5jsgk51w^`M2cEaak=E!FA$N;Xxs3i`dh*~xpL5~BN zB7cht?W>czwWb$R2(wOHD)N7b3-#;7C7eaypmiJ|E^&cKEElnQrNg0RO5>SStu>29 zRKw>I4G!Lf+JFWn7!i*14Z#96?O?6A#OI!`<7IJ;Ph$X>?@x^Ze&Z+m>h+}$rk1!6 z2=E(=d6`tB_(^{^pB5iV+l$(SxFFsn=5>X*wnDtir^Tmrj?#W!ssqm);4=qQ<4r5X z8?|Us%-3z$YIyX`p>|cypcSg(bE(jC&M_tnDfAe^h9O7={0gC^cs&4lx?*TahaH>2 zS>Qk({;Q9$#4k?GyI=ys=NkC85YW4M3E3SSJ7t@x&~jdC;FtRo3KEEEKo3tl>A?xb zY?~g43ZkHFSkccG`4qZYd=Q{GQ7Vqd=@x*NGz{mmFcj;k5Sa<_(x3cb?izV16!$5_3Ph3NU{e^Vac&$7 zwW*95gWV|L9{#d`SmXuMjymHM@1>cg_gUh)%9}$i=qHWR(*wLz^AayTB4sQJOr@I) z5wu*LAz_z02eemlO&Fx>L!7#U^jFG7VErM*BG6#oL^}wKK4cn^xh%p@nz~6>Q&!2p zuq7;Cn_>dG&$2EkDrvb34A^iD9%R4tF_xvao-sB*P;SOOZXJ8Ur(yr2kFgY$AOVbm zr0mnZLnAOF>mo&{q=d1cG$e}v*t5oCuGe) z;uDTrPf`j7S{WlVL%9Q5WX6%}ZxjF8vQC`a3Nc4J{wybf2mUnS&ocaJ#-9+3{c4T4 zkZc2setc;JU$)s{m*!t5W&?Z{qIxV*%dx<==dfg18<1daM9RyQGE6B^N{Qy2R&XI% zi-1J6YdF+cxQ`Y+r@37{pFSMgT(f@}{{NzX|3g%}Uhd^t29SsuS_`A0&1l#{J;4o_ zN-uA;o3yvnZwkw0#Q}ay&{|H_2lz3?%5Dx>dc{E_VxIpK-U}3v5a2toQBSK78g5c3 zD5pZ(He%xLBD3Y^2$bhMpp>Jb0%~uDsHkRtP<8QMs>9j(I`K_0YPTJ7wY^T9Gp7@2 z(CNo-NWHs;L(2<)AN)Ys589BMDn68;==b@Eaq$jh}2 zjl8s}k(X+fA(n>9WANer4eul{ISR7>!?ZOnhYglA&>((Y+5nSf78s)-^ZOXdtb=6o zA#+094E2*B+iSj(!l|n0Q=gpGL8&1v*>t+dk*kR~@6$_%xME)KSpi9>%t8C`n>A8j zNG}wy4UyJOjU?-UDU(;;3ah?j;)wXLMh$9u6sBh4pOnK=3E7GI@_ z*@uuGdJN^T`>A%cgyHf8|8|`cJO%hnM9CtXu(B-c=B3W6V|YR_%ts%)-9U;@mB4R4 z37IJj3`xdy1*#F?a_0_*n#EWAg6#Oe_V}i4385xfb(yZmTar28HE1J}su3)`@R-^HMN5!EYE!AYOo$4?3;DdKOU1DG09K zzL2Rt50_8@Ir~QC>>GkbJTK?`y}Xq3%O6RQTj_9;m+R?f`2KDZs+a1;g^hA_Z=z3n z9=mrVTpDDH;sORG=wh5Jq%CqDxc4$~S>3h7F|RuGWqd@gK#0whIi=d?c=%By+h)C*dWX%M<*B>2pkOL_75Q#a|0qdZ)oHYY7*Z zbi=C9?qQA~ol|m4Si~xU;k!nJ2~7)W1&doP$)&t%PIclmE(7JM=~RuDib6&yE1EEe zAwFxreo$))!2&~;-{aTS^ON=~bRZS;G;6=UXI{fb49Sl!(pBLRmlrW&;_B6L3yfQJ z)ncjlYV?Ys-vayGyRm5p9%OSDM3uJ5(97ame*G!C9IRmQAeXxwol3P;6Wh3o{|AC=-5xCX@gSGG zoHRq#`NXFWZ4#&KaxlurgIw-%kbc{6u6gPKzgofDM$?dQv*< zHLCJ9_E@ddWv_D?Zb|jQS|4h}Bg)V5cO0g_q+NtZW|Y;nbagUuwx(Kr(!7-ffT-?W z@`=Q%OzLFfLxYO}gp=Ppq3ZJD*=;>rCrK;X$dV0Kd zOKV!)JAUGD9%@Cpdyrq@k;b%mlCHY(^t)1=O8Rbt+a^9QUgI-oSpWYkgV0z}{AZ1@mnAcsm19v?mGwTZqqq40UfvVGj@T$wdC1tFnQC-9y7W zio5OV@o?KvSHnPhgmx}xuchrSI)$oR`g+$?n%_z*T~cj^GBf{Y53HRvDB?}^_MmA` z{6l}FBsr$z%5x2X8Wc~rEYJ7sEre)4WeHeN@2amtiV&v zP>SwpTu)UaMBIr$T)9~-B4F?qvS>N17aH{}Xix$JN&dRZjsN`+mKr#I`nQnrfj)#P zfj8Y?7Z*v7MlZ=b{D!Tz{$87y+M@O9diMFW3~viuYASh3SsaHvFPIdU#CroT{Zvdz zr#N5*rLhP29JwI`*&1V^2>CCVn;<(tNYZ?4joK-|UsOLxkZmgH!ki`U`XCVr^0VTc z92_TKfwfh-(81{bD)=m%Q0lQn5*}%yI8bRFzx%+%P(g2ISe*xM>Hffd0P(mUpu1u~ zLk&9jmH&^nH*t@u$lk{*r0GNrkkO2yGEQcu9Z_7!o)AZFx;x#Sq?0s@1Q&=gG!O_$ zOu7Lb#ju7>8x&OB5qA_^k;RQXPt`y6d){-Z`YzqA*WY(O)iYAL_kB;*ty@*MwsQ`$ zQA&>yb`Fd57_}LF-PtDAm9o z^-jx5wl6eM`3jb_jk$Cbd|4f*&w;$EC7YJxe3uBAcB|Q?La6f&WI37YDlPac7}`7?hY5#}P~`%po9 z#epoBM|Bp+&mG8ePp!W5nN4&CwR*x)?p4dzgb;UCVT7cSXw2m@DQ{E>p-%mQOtPN; zc9jq-^(+&UnzAB4y-5i9qehm?Caem|8)nj~LphNOz~zO(bUB%*K`RR=6Uqr)P002F zzMNFN^>6`YLOH3^gp@}LgmPlJnHOLtl#?spXTg^WjBp1@Ut1u>b|la+FU@47{Z z2Q;pnNaVHo79pYzTse6Iw+OM_fh$$%(RJ*;1@_{7WKg~jD|G6atj1A1FfHwBY zpf?&Of1MGG@gkHH0)Lx9t;QZhzi++D)XkIp9L7=Qo&dOj$SX$z+~A<9P&r{!$>zp{5= z&z2M;0~_cV$3}AuLS6hTj$@GiYhWXyEA4~jFy2brGVA0#`16}#Q4uy@o78*v(s?I2 zuYQvA>RokMeNugkdKPo|d2lZhZ}e$v^4YDLJ|5_oB-%UGf>V~cIqOHOA zKwUGC?OY*m#GG1CbrQ-?H?}M>o6e*e#n&nw*T{Ntjm%XH^TT1peN_Eal^p`RqJUJ_ zk;0OcI;_4h$1riSqf%X$xej1$sf-PHu^}6~)FU^@VlO_4w3lTk{%qPs@_r}nn>=aX zyr!N~H$4tcwcx$dqtVKf%ykTJS4T-Dxzx+XyTe*}9Uc7O80HQf!NB}B^*P5O;QB2#*TW(Z43Ha*Vn#y6aMLV z8Gp^H*XYGxAK|Mz`KtVquXgd(n8xO)@|P+KXZ=Uo(6&S{-4JqDrS-o{^MN*FFw^_t zJPjK|rQ@ME{+c^A5sb z0SohJgg-r(wu5u_h3?j#rOMOl_50OV_OqIrpy$&2cnOMwcU=<|(-wtL&U`G!S9sui zM{$P1P7NP&1U4T#JonHS|yjL0$ux*6V8&yw8S8tpyB) z=&TLAA%+{o*4&iVhgMi%= zY>nFmQ*NuoS!baz@O#yWOeG-PRU{s#GVE3{D1RG}=k6*hdA7KUX)9`xIyI<{IQOXN z{3pUHl8=DF2M6y1u~}BN0u>n>iNgb29 z8FlQQq6E<$b2o_xlxKzf&0#axY!q{+f&dpi9K4Tb8&@?D?qjeP@7^K#-E9-sUW(cG z7~UFXmt9-NX0jvW_TQUEr_<>P`|oIaDzh6lSocj0569D)XnOzHXgV@7HDk5gDBASd zH!>xLx6;lA{cSctTwXt?cRdSJbBXjpn1whP**!A7d9r6BBZl2Rc{gO!)6bi&rLBdH zr5UfgUe1_yjXRdvH!@{4t`);u$yOb2%xsOOXEM{1&ujB_%!sDP)0y<(vwPB`8LL^$ zjE+qFsa4^IrZ(rQ@LzaUSj{eD)kK6+tHSbE)Cy-PX`c=w1z1vo4m|=YKuP;_I30eM z8N}+q`z{`{Z#V~j0H;ge(!)x8RLU*u+!++&emz7+(xsMl=u6OqRnMaiWI2gyfsA=M zkfmgzLsnmCkO}2P-d80=+aIiD(&6#0Dj^y$p3oy$7HA*OK|rDG(-;%V?q5w;qgU7H zvgLzQEAo|UAs)m)K(G9iN*mud^_2#hP&RROy+(*?yggknN);rXdc1WRmbo<&)vjDg z%Fltk>XG@sUUV~0#$&IbsDF6tRk8OgO4^eHZ`}jwzYSxeeOVd zI`e#XY-(g?$Ie~5_v{^i;o#{0XD9ac4}`Zwp6uEbjl~naeaTeM<4lGfUZ*kSLjjrJPV01!cB%y^kyOYF_1UHDK-w#ML{zHt59oc!d8zZE$tg-(~wv3*pSFF6-f1aRys0P zjYp;xFmKNELGxs&US5Y5Os6_2e@27Zf2&+*w$x$udF2}Q9sXT{X=%7qojjnv>DU}< zo*|{vW~3IPEdB$_CZw=K7i;bHH>1adN6S707{P#GJ7hjq-KpN5{&yt|;l-+1Ey>xokQVA8nSnxGqm-ZwmJ7=Ka+!Nj zz9aLo8l3R2k-2r+Oj+?7j#&o5Oc3L8US%L%SOlX%g~D~LePr*$%dTek7c!qhtvr)m zF7wb%tI?*>=slBLxg0$Cp(v7}8pN~(wZeKYQhJoqvsdczlB?JxRwh(8Bo`dZve4#a z_nfpol!L97LTQ+e1`i7(bD~L|f&TrC3OO(2$u70H|GoirO}#6xt6cbY`GZ_Ut5w(3 z$1<;uG^sP{u(}Xb*VHxUcMZt-KrJz|>Rmk1D){f9*F7rpXa=X{Vf8V6kEoYCUXj@- z^NG#!u=Z8Kj^;n?{$Xqx3ja8qy4ThO)v#2;o2V z8LSy!tz42>D)W(Qb@2|;w}Aypy(Z@L23tcn6HrUaQBQR()4+OYq^X2s`y4q&$&uYA ztm;GW%-GA!8C1@o3cQ6nh2#4LuVMTxnnPNvN~!+g;ZUWGDNNW6gYup&k!%^BP{-*T zB;OAuk-de8y}Ljv_T**ORO2O3VYp5Nbpi{rzv!xYnX4idCgh+(|58z?m-`>>gRLjD zigTt~uTk%+Yw8nco%V|BDhNQWX19wgv+A`%GNdGdmxl@;kD;=2f%cO+d zZV7DGRCi)WgR~is^cQq1-Vfn?Cbc2EpimGSQj`{6q4~z_5qlh(U3j(&P;tbNqZSR1 z9Jn+xq;+M+foK-A# zlO^+!5JZM#zHc)m(&(oSmsYZ=FDQhuX~<}Z9B85Cu8=2qq+=={?S?J9P$w6*E=BcU zO&{cgO)3Y?o#X22{(n+YbYjd@#eJ)~ScB(Y1Iud<%C9>2s$Viotxk1fT7BH9PGn-} zQ!#YNp$);kCfm}36@`TwOD+V|{2DbU7Y?ZJ&q$)fM>~3~BP#B!(T@mIOX&+`Ez{kd9)niF?|$1rtVeoScnu%I~yY%{rkR zgOkfk*i~&E+f~4tSe;N;3s?VIX*}WHU1^*_-dkxn+bhi|W~VlIStlf{X!FoUo-ADb z*S%{S51Ri|mo7iV><)wIDm^lQoqiq%kY;)SmWQfQKUT^761dNNDX<}B_GB=IhT0ii zn$kFR6|2(D?!O<^whp`Kf7z(fLyxD_;^t5@S|)}QvsqGXUlk)Sr=9A%Y3!~?L-i4i zjMTBhH_!WFGb0-3zgV?{LxCV|fvuw$f>C)fjzRGT%j~9L>E!=yH)Y@+d7U;PY1PD@ znPafXK94Yva|e4f1s_)r&^r_8bo-Yo(^ZXF;9tgOIb76X7M^MJgYf&hho4p_J=UOPk}YjHM+F2RBX2k(L(Iw5-n_3wA2d&}*@P%A>2$ls=> zG5<5=Q&<6eD zdB4Ui@NRuVU3o%muKoNJF|D`6qglV0L)Nxpo;Rl4z+k22meJ- zN9AcX+i2Hb;|c}qd ze52sBM?hpmo>Ip)!T+m~>hTDOpk6UI3%O9RD9*v#Jj(4Fk(a+=a#QA1JBSTfvHsqe zwZ3J2^VZ41^`S^|eW<%@eJBzQtq(qC+F`cR~AeJDDxzGHnTnq1$sJ`^2Xzjl2n z+V5J5vgnL4FESf%Cl0S%2dBK65AH?x-(8-c$xKeOCV+=kSgI#P|H#Z<(iafJn?^?_ zHcyXC%uJ0;rzd#r-5hpqjts^u%s{j{3b2Ej-RWtwl&pccan|BBF6|>9GziB9*&d|cVQHCh& zG|&aBq0wwUY)X%(M>BfGz8!tR^sZ-}YxaMrE78>2*4#p?_I#9EUEx*x#;_0y*0m8z zt=c~gf9lRqa?$>2oWs5JZy~DnW;pi#g(WOC>-;<+psRVX%_&is6<_=7hkzcs-475Q z+49mz2XN;Wwq!BiQ-ptevlY9s8ha?Z}~x@eW>$(kd#kf z<%IX7e()ocOJCjakFCaOPDjxDLGIoG)$dk6Ks?j!et;;Zzxe^8=B@S%e8?}b(GQRd zv&|0_kJIG`hyhj7FYrk}K+ffEKTsq-?FWe0C};g3b#tHdgC(h_{UEi}xBXzLWBAw) z63tzHO!ykK~iUP%ny>EUM>6y>|1`Ym{6#X{2(#JR^RwW-tdFOIjiNE z-8(|b&IXCs`vGFMu+|R{55C?nFzE+~JU-zEh^HR&14IwlR}EOXQk6mMytA0W$o!4DMgQy%k! zq_4~wKS*jz@A*c4<5TfxYG|1uW;NiaKeXwd?VlUjr`a*@=M>y?|dV#`9acG@`fKI z-e$lY;nJaO|9^{L;H`dvclrg^`vuxZN)>?H4%i2Z+^$89zY0ng99$QV)E@ zH}a$(B(3zH@`KbXE3f;(lGG3UAhG@>KlX#v>3{79OY5oE{2~?m(X&IzZiCZTulkXS zr&90uL86wZPyHZiW$BV1B<-|Z_k%<}D`1kt5lTKhmj7z}0`Kw*Twd7**pB!?>L$GKC$Mk%!O~#rBR@#W>lc2IcvH$(S<#lzH9sk$dRs}TM|m6DnqBLK*r35UB3VwE_o?+l>~-KusR!c( zY<9g6WRU~`Cxy!ith9uh2Ok-O%uIX#-geN63y)?paobg;=ezM&AF0p0oN+T_?kDFs-UClBRPrd+D; z*nto3Ur|@o`+Rj#eM)W!?VuLbMb^Fo6s|MjeSD4jm}8$k0JQ@lpxZ>g{)8BoXUO1} z5HD-IP-n(q1_J`7p~xo0KmRG=krP+cb)7omI)Ur*1nRpGV#`DHkNizu+e@*>x4^_4 z!15J}2$`>!dA|0gJo^I0wrEgEi&~vMfI~*u1m=e$B3ui$B(1e?ZSUo;tVE|_*Q+WbvF+kI>gs> zsI26J@^{?@>nB_eI>}Y5*d+1a{|@UPLj2<&(BTsz6oO?!A^!buJ{fxd{V*#i#F{m0 z=--DQ<|CkM*Rq|KrAtxsg=lJm7K{+Bt?;`lM0-0Q(dg{trNsaIhlfX&#SJbT=E~aL z4WHmb#N%=Lx3{;K{;jUYKuw7Lewg4AVo(?I#*G{4Z&QdvLqqiU6HmY@mJm-r4edE0 zwr_{?LLo**M(E$sQPy*~c}+e4kFM_A$**v1jLUlOUakuh6R$jUM=yuh{MrI%ozPKag8&`ApM^2@A4A&=lkm*jE$I68+PN9Xb5=qvbf^i}*g zdKy2DzJVV{&*DeX6)W&L5<{5X0HKaS4f$I%>q6s@ac zRb}-Geth>;{5X0VKaReEA4kvP$I*B2T@G{5vHI>^ow>9>Sx^t%kR|3x@%D1$yu^*fODmVu2X%Z zKG0Q}GJJ+aIqHmBlvmA1U{RjuhEXqn(EXI0Q>S!R-@;`^@Yks4<`gZb-HA`#`JT_ zd^ePXgs{Jf>PPwMGjwgEd{cjl)S|kgvnbDQNHxz|AOnH%_Wc~UAMYrPWXB0&t%a17vIpcuI>Zsq7ncroSZYZXGQ$id8QWqLO0d z?}=g%O)lbtWb8!2hD}hc#?@;S#WSfNDGD16>U)Zk;`=ugMLDXA6or~UnoK7DlM)r@b&YE&vP8j zh0Khg(jpF*=_q5w4^y0)s=UE*$d_=<9u(w;kzPhnD9D#r_&VgvA2<&A@>`BWJ{gk< z3I+M3Vi=_9ru>{B)lj4Ugrcx@MpYpwRwDWVU9Cs-U5c(o6ncw6u@+JIhYX5#MBxZ5 zC@e(bS0*UfkuF73xQe2lv-_KEK zgwJsFwMs!1A0=HW#6G?Xn_qi4dZAK?T^#+cQivTKy;XX?o%9vTr@Y7 za3wp93$h2ijeHey2RRD4NsdA;T!;tB-Y^{W21Rv1hzP~to)axRDB#@tKNPDE2(gZ0 za5)W2&OrgM!_5?fYt#mc!Q9PhzDj=vo35u-&cB2;*&jf_{C*gJng!ntf zrUF8&qS(QJ5U}|W6mm8o#O)kC84%(&j>6h7Ixv)HK!{}=Js+S$xctY3fFR37sJL(r z&R4I)zBxq|B$ENjpimI4ej#;s1=-YhqEHdX01u^#IL4eop&*>b66hfizr@!eUcuvQ zkPIBrC?F`R;WGu}-k_)@M=KOvi6|WG1Vuff?^1L%qHuZ|6l)R1fIBGK5ydb(C@e(r z6%L97qL@qvMG8@TGJ;|&qL>r~#WRRv9uO3};R^;I=b)HE6a(U*IEW}57NexeTMWlf zB918tx(USbSwUeVj?p;2ZHQyO92D{b;!ssbX(RqA$Km>v=0`#HF+$BJ4hr(E6clijn4xR!K_Q-_m=zRcEj>uiXE2KmiWJ<-Pz;V{V7ezL zo(T%_78)eSGsARkDkubI%|UT6D9E}ria039Hc(K=lR-h&s8PT{L1Pn?Z%~kVY!q)$ z2u#~ixWhO$|`m(85H$Zu<(j&tE<@hRZy(e zmM(&#y^76;1%*|`Cc%OtQN>F3LGeU-e0=gioXm)FTnz0V%cM8$o7|h`s2JLv9?6I; zW0T|Q%*ON%9TS_g)6Zom$7a&Pq2DYrlkia|Ht!yr$&9DP=8*}pDU(i*hsU#Nu?c$L zyEwI(iOBp8CL$0T?(^KPVk(xZPBRx$Cq{g%RL~3keub4_t zXGJPKGP*mJ-MLewMy5ud9~s&`HYHLc<7xZJ@t6JB_=|HyvB~ir>51vd9b#~LboUtk z8JXCXM$#M;gX3fS)6waXXT{+7j^xN_S`3Wr=VwI({~6gcNyRVrO^%L^%#2Nl{;`?N z^BX5;(xQKCA_J}VeWHJC$HdsK-5Gj{{`8Kq>^?h>{I{J;{@Ypd`U;BPA)!#bd^^R( z#ee80;y>&M<-cQ-)9INE7X)8%NbPzqJF;(NdTb&s`bVZGCnrSz$gcE6W<-pSO{6D8 za%`V2!z7+aS3!!~)rS8pR2BPAN{Ii|m4^Q?HHH7;Izn-J+Z3Zp$1(HboQW4MGA8o; z2=cmXcP279Ju=QwPCdPEaw4*OZ0F9&36UH*Fu?_p9NC|q;EFc0Ta4?!MBna_y<=i* z|K#-ZqGw{q*vJIxM`DsQwtI3S{rryf0YNf!c32*=+tI=QwDUi0{7)W!m?UeRtw8&(f3$Z z3(IO@SuHH9g=Mv{ECx2StY((g%(9wURN8r)}a5Pdd6{KHz&kIeD~x`hC8}lBV!XY&rVKH3THnO8%Hx^ zL~Lw2{p|GE=w1<>+_6jd-O;gq)Pkew^pt7)h*JZPj!f_64w0gEUx*uaKT`OM8Z!N5 zIu81S`wc{O|Ho1E>KsLX&dn2dxNRe5U$dW^dXUk{>4}-K@x3B4IX$s+eDZ*P8tzm^ zcTbK^qL&k+yGN!o)9LI?T0};6q`9YgHak83{DH~I9fCh}$hCe-dVuiw$i(RG^o}lk z5_jOw(Y+!(HuGFIEyC%sU1`zvLUuYW99?qPL}u){Y?{ltYkX{!i-MQbZM&9E6I9rU z!(k(A+M53w^EN`L+!EY|IW1Zr+tQ@2!l3Baht|U;TuA0$46TwsktK$F1^i3N!|D@S zwdzzKW>>+?*1US(zW8*gK3fArmbL7gsZ$-vtbi@8!_}SY%8Tk$!G4y^2Y4+QrqD{~ z-8=`9=VySGeJp(iX^6-%1mk?(SV>i<=(%9HE3oPDEknlMTwYz@Q$M6#y%>vMnSVg- zJF`sACo1I0YW!o#V=9+bmtA1CeyTo{^HnmhuE}F+Hgo$5c|*PCvhH^>DCc7pG2G6o zugJojBSm(J6;LOvB_sUaU>SE|t6GH9F8R(Hbp$qd)oFD@=4-fwHWcw6dTFU#*pB_n zO1Usm(Wx%JoR$lLH6DH)^EZ0=S@k*J}N!@)ypZV4q|wpFx2R@%kTrV&wJnXC_PU{$e>?8B<} zC<=$KI*NTc^)6k-G(z#RV;WJcI@SrSd~?mA9WJggw3nscB!I;JhrWCRJibgz_ zyy^`?!@+=#?wU^Xl02sV2mx)XPGOC+s!VG%HJaC(HB+0Gf}T22AKp1Oj%PrCDM2iC zz#5OSlE&drd(}}_ZhewBMqLKoV40_~0_JsSjagn*Z@z%S)B#mwYZd2_cXDBq7lDW_ zQMg}Ofir6e^74in^^^T{FyM*+6ntmc);5qvWd+_7!WMZ{UdD2*wi#6LMgy3eh<)G6 z3cZ^y?o(&#Vm8g#r~}ANLtj`~!9Ai7A@zxT6Wb;xz5nWr0N^Gfi#G9&dk)B}HmzWe z4k$MdHOb||{E_~0mR&d%@ zT;8Q%!*5TQ+Zik0^Q7mGg#z`4`K>$mf(a_WP6`Gd_g7Tf@H6R~YwS%IQL z*e*YkpLg55Cf!(oa`SK;hV2+4sQk+T<#;Rong^7dhdpa&@u<(#d-4*t49ruGYA%p& zF7{mP;`zJ$>7F{9hUHEKfZQ}Tvc{(sgs6P}kfXZFbD9Q_o5tRH_=O^{H;q`M8?JcDo^V>Ih(NBKFJd z{zD$0mZv6c-WJUR%FSbEKj!&nQtBIQXPfjgIs%lN#}0r@2l<@*RDJ)r&7)l~1i;)x zcK>6)MKLbVqwSj{^+nAD&dtQ^%1}7VYUE0OY3Opj>64XB?GqF5sxD z@&}zDaBe1!``AtDHhEsX4X36ir)ohnfpar)D9`>jW*@G4&O!TB(*SbQ;A+&)>d4CH z;SJ3sSE<`5KyDgLSUZbUUYFO@&p5(qxc6u-kZvxH3p%-KQ685c<9L?guG3r~-CUU7 zuB_mrc0#DD>h>TPgjKxC3O*`_9ipD6Lk`{z%>&BK!}$<9#Z=c`oVGCOsZTWzC^rvB!73~GKp-}g z9*}3-Z6fxX5P)*?VD7^%(0%Iddz~%g0nG!-&BN}E&AY3$4_;YJK6^C{AU6%#h4$lZ zslQjgWz+U(8bEFuPLSHAsZPls9>-3kNl%{AOyJy1Y&h9n_>e$+gm+&r9| zs;t1E5J7#dzO2BOsbQ)!nhBhniDNx>FC|ZIQD-s7EikWXCU9;h_Q~wtMqTKaA3S0c zYxS2MC^rx1Y3=!udiAgJRh&09DL$ZyfVqkAdh2Y78`PY-jBQ&(4QncZZYq40+TBg} zG%W%c+ICF?$W6m3H%B#nL!PVIX(#uR<^kpA#oWBN2jvMI?J^0<4>c1wHxpZujufxR ztLpk~Hd7teOyJy19Lln*xOz){eHZq}O`7Us%>>TP>>(!RK2&+WXqIojWD}R@$rey< z9(GdgLVZSlB#${h{{PZEpxithcyzwUf8L>>L2Ysx)MeOSY7^xrnhBhniL>_3r<8BqBNzT- zQ`K=z1<*~!p*p)4cyxN8!a@5;)7XKhbNsi#lcM@MtiG2YI=G9P3#2U7j8nhL&)u_?AVXHg89P2b7zKg-e^Kep@ZiIlm$=6{rBZsW{kbQ{}IB%Hud#RHz4M z3tS-GT;ohbv@PN6AIO=W_ z*U1~|LwVRHKB$R+xrw`os0S?KpqhIwZqvFo4InoSyDxTn(Mk2;2Aj4`(*SbQpowGC zmTp(a5;kqWrUB%p?Qzl6eE4aog_u&2uWBM-ZX(V~+3CsrOx(GCB`;_qU~b~Li3G3BfB z>Kf;=aEe=HX15&0D74_!|zk8Qx=>2b7yPO*~W6 zI@HxY+ilvArUB%pK{?A#?)la7=#w^WLel_p({P5)rnTQG-;UTcIj4C*xp~;wvU%#- zQUR?c^K|mOCIaRr!u60%lvkVY#-Yjr5vxiFfVqhWT*U0IR_DrP!n)K8~%>&BK!|s~RQ}L$4@%fkyA0rYTj64&O2m#H6}Q)cyvp#tZj;xwyGt$b8{3q>H4WA%%n0_UMZ z`Ol`RWAZEc4L0fxxlYff25ddN5hZIjj8>b(5W zxp1rAHDn+?WO(Vc$#=`k@&}x*C?tH@Z~^piasJ%qJ}HmLFL4CkaBK8x8R0xsoZ_~r z@`E~c0cx{`dat1Z=b=Im%BHIK?^Tzb`x}oLDsUbu&d%G^zwcM)aLFV(WSD??m^guM zGq=apaa0|{oH9(nJWS}Q+f^|mPpV^3YBf}uGh6^YTpatiQ>~Y0)$y$k>PLnOoQI0z z^EP!vexc5FIjBDyDsUbuRC;Zy{6_u~b8gD1*9{jy4;MNMHdlQs=eJ=)-aM_kWVir& zxH$c9b01XiOsOAj>Qd}GVJ~Ores$;p=~!cL zGfcodOz17xOm%UvLH=T=nKDekJWS}1+sxIgR-vkz%#Il%P#z-GL~P>NLsicGXL-ah z0rN1Sgl$*C7WtF<5K1g2QTd+X0_fr5JcXUA{7lZu`E3sFWy1x~!-bBE%~hYu@8xO7 zVw8HtZ~^piq5Nxe*T}DLQjR@7^_igp=b^&Vg-zWf-@nzlnyqdaDsUbu6m)E={8GKT z-nnCQhhDKJoQDc+7n`ass2d@i0W*cX)=+`-P@(&7Qy5IS|7*Aadbl{)W^>i0&IGRXhqo- zQT_0UJO|bB0{3gf1<=FAVIn(Oc}9Jec-p3_QnDmAC_P^L0DR#y!dKo1u>QZ{#+x~g7-dc5H-*V|Ww^H9HWQRO-LnflGS9e>*A^pB0=38F_zA-V%)|WN#eAYk{_0$+oHk6r zJWQz5*=fpmpOL4X?pNi!;R5L4LOspqs`oa?c??xdhUF)Q3!sPlBXP}~SYEzI9!KLW zaDO#i06ko&13J>pZ(i=0Ppj7r6EF`G%5^qV&ZqzCSo2Yr3==R96Nfr&X7}@Q!8xW~ z%Eklu?5BqbC2*S=NXWC!8QDFC37CfowLqJx=I)liIKLcih634zU-V4${!6AFb@+7nRc@Bi27E&f|0MOi0YIf1L-D{u>iYAo$8kt zT+}Z#m2e&^&tgseZ+KB&c0R0HG}PirEUA;)=P1c<9~I%25B zvsgNh>e>^Td+zU0$~DQpY`DeKSUMDLZ#qW8ci=#>AI>vN#gs*w0h%s4FUew}X4daEs@%q>5~}gUA+n z4ufEm=iBs-Cc!)}h$pgo=}f3gFRBISV(LSNT0D&&<{HB1_oFNxaW6AE0y=nS_e7DzmK15wG)Z%$8nGmweNqw_Ko^q~R zRqONfg!2>>Ph(BPlRqEW?p*8sw_z5~V#(-^ooN5ADO@p68a2e?IV_o_vUkC^Wy$5H zAwFw}#S>Ukx_34k`Pn@O0(P46nBf*rV96|tle_Dstm4x~x8No^yZQa53feydR#*>cenC<@e9rX+N#{ z-Y|=2vSh{0t`zFV-C4)ZPc_b*gDF;)%x$)o*yL4s@v3Lecnn?C5St1vfJB}a8 zykQnkV95-g-EpgH4NIKoD&&`jT0DUzqa@Dyr#`)#t%aG|t8#{|r?3u7vSf6R4-`Tz z;(=!M)!oJ<7~Z2{el6;$4%r4-$wZmWq}Tp6X)U?r^IVm7Lm}|J4HNqu@~;~C-xkZ~ znJSiYkh7-_g@WqaV);BPg*F>L)M{3Ka0`Z7TE{~yg*F3jd`}4s@0?B>9W_B$5LRjs zUm2dsOwVMnRf@omZ7Y3|Z5X>Reymy@ckGznXOiQY>~Ln1v~O)u5I(xwDI8aJWKlo} zMWxL1UsDPQ>ignS;F+#o_7awSR~<%wYf9lUldT_%6X1!iD}f&=fx$b47@o-P+q^ry zF&^HS9-W-tF(ZaEu0PkWAC6eVYx}Kee^<(4TLPq)ygt;`WtrQp1HF+Reb;p(X+`6) zUTdge3&eG|B@$2ZJ@@5Qs(;WTb0Mzl9ew>h39DeD!ga4T9831-d#)QDv3P&XD(G&z z?)6*YR3u?J?2fo@x2C$g`YpCZ;=0imiATCEZJWe(r)i)!GGJ{UaTiZVPqZsy6%0|h z82wf(o(fwI!y2yJ%>${yK?_DsT$ek-gWX}Ppo8wd*V`TM=6g`+cHL`Bh5NfKt?BN% z(;AKShAlRh;=0k^6OKkKV?M=wt3TYGvW&L7>sHc=cg4Fb+s2CPZtFl_GG?)6yz554 z)zg*evmAz4T(>(S$)1>1FwNq=mrTW?R>4?{>t0iQFdnxyrag70zqc=Ju|XFXJZbg! zhr2D?#*6E2^I&(h*Mij-&*fNG%!1(n_vLU`cg%ui7}w>Fa9?u3D%gr~-Ah`jfq|rD zn~!nb9kf!Zc*Js9l<@#!kuJJly4H8Z`@=nSzqla}TD?8dFyA!xOkBcSBeAZ8#fA)A zH#+*0-ASuptj2Y(buc;Dqwl$HbcCb*JyyY>jq6@pA{8F6w22$no%UF7xXUs|Z(O&U zQ}OOWy5+juZ>0u%lDKXx`{6FDzrU}?VoNur`?PSE6^#$}X-w&t8ID+q-mav^lAIb=!qH@mZI)MQ5}QbQT+t4km9?RyB+ax zw|)U73NF^$*JU|vGr75agR!Vpu-4?dhi*DCV7Ux9xd834{&?InCY@ZjT4LcuzeR>% z+}HbhBi$C6eR5szi1qi!t%4ya*S)q#q&H$|(@?HE?a4$eX&GZtu3P<9Z@edF(f6Um z`)G;w^+))wi`E+H4TmkZG3CC|6YYufjdstC$Uu^Bw7G9Y(0!7qR`-p8L<%_@dA_5? zeIqdtN2W%e?`U@4i1hR%_(qfaMo%Q%#Wxz=HxdJVy?mp=ePbXI9poEpT{l|#27CMX zhU^T@C{Fi^mZrtG1@&P5>IwTnc*ps{%~(M-|&=3cb87WT_A%=okE+ZK)S;^Pi-DX zcUOYnQk$nh2Kxs2y|#G@Bpi$JTWa$ZNHW#W@3qZSAcKASZM1m`q`OPMzcx>SBvV~n z+uA$@5{~t9{cQ6TNGzrw!(AY$0bL1OJp~d==xW>QDUeuvfL~IpS5$vDmwBtFK%yyr zN3EXn=ueXouTC1l#qEW7#t)AlO!&m~%)sxr$ z_#hKnJmnGZPjCt?p7MwfM7YFTJmt}!Nb);s@uU&$>Ec$|;wg~cNH4d_7EginClXw9 zT08|39~k7i*5WCU-bjp}ufq=-*?iw1ME zl0968&7Kk&2#2{0n>{5G8SLX;r`eNuPj{4ion}vo41@=`?lgN!B!STYW!F<8Js3*U z4Nr+g2IE|zn>{6x>Ko)z_oST+>o(KmDUonex0xnSiG=%fn`!ctNU}?}nI=z(bfs%V6iC1BR2x0z(HGa9YNMw-V!gUkZS<5!DyloxMo)S4#dW9J=*euq?o%5* z#gW1?2`WgVr#NE0x=(HN6i2L=+p$MbZ@+Fa4W817#&wHn@DxWhp<7IYr#yNGbc<>5 zlt(0eWNAS7ts_~@6rI=HyERPE=tl05B79f zwy{Rn-Hx7AYQQR(Z*<+m`rJUjRc;p8ZzZDrgOrTHl&_9^49Ofcjx7(uwJyE(_G!aT#eW`e_1-p(s+jkKMt)66} zo9>pL=MP%_(Nq@!O3wlZt?u4|m<=c~nMrg-1{hFkl1D3coP`o|yrk8e8i*6S#LPZv z#llg3I9>sAJzUC)MY~zDZR^s7=;-O{PLc59Nl(XMG8LwKrIxG0@i;$pnJO9SOGK=q zDPen}D>`5qGn%ffAhSIKmfNzX3(+zdOGE(}@ysL>eS>kUV13iYNm>zn9BhM}uDc!a zu5iLCnCNuhOQzyIR>5ee>t0K|HypRfjHl~*(uxiYbX%wbCF)vpU#g35x=1N2(HkAG z+~z-Bh?bsMcNl#=aS&muFTuIovwd$6n5DzjpP zWsF#_$zH2qew6PGADr5^F+H+lQI#+!zTz2@0d=HX7(5Mw4j3@ zH5-2>+`Oi~*0n2#0LKav_95k`+OQE0aFlbBcq=?PXd^h-RVwB15qnq<2H;Ug1F^qc zPM|skCkp5ONF*#*!VLq=@FU>xP$?&p*uNrE_|8z$Jup%v^Z3qC5{Y6|pPEAqI+R4> zAf5W$50W-Pe=3c%_f`?;iGB?VQKQXdlq+`FB)Yvyh?vG9iE^dBqe_U3N8bP1*QGqH zEY}`4n_uWy~Q%B|nu>)R5 zhQ?ruuZ|3zKxMFwEKdMiCrIrOExnFibMQIMIzfl|VTGYi(4l6SovLGBA~4ZW$Ieoi zh){{{181a`>Z1{;RaF8n9}b%M?ZE}okSWN#{51rZP{yh+3ImRjP`I^)7h;$ovUEJ_2kX zu+E@5J*4; zQNPKfDyJ5k)U5hJext6b(>*c|jYze)1UZ?Wed*m^7 zCUZO4fS%u8VJ!JwLT8FDyEBz5lc|I= zQ&F9%lqXY3ohj16YaRGn0dj>4vgdA!gS{TPCQP6!|q z*ATKo9#_Z93ovaEMjv6iE=aA5-KtQFV7DryK?E~{b%In!V5=}F=&UtNEC#6sK}Jxl zs9+B)b>yUtf%jCfY0EmXzJd)M21PfVn~}s_*@+j%rs^MhZnXZN_s;xNJiO}#F)gwa zqm%olrqeSs^$(dFu&5%$I9e+lqEdj79%xOVOLuH(3~| zz_7@1#0izTvI4^$^j_*?i#%PLqcM5_B9_>vfmj5-qQqrCIULLtb{y)&u+L2A6=U4p zmSc|n*jKb$TPKY)HaU0?1L4bVpSV(|<+qQ^t4oSb1L2V>>BtoZVCsuU)Hm?zer zmSOtaJPxTllui>O9BH0XU#X+&l|WIV7}8W$V7!L!OqV)6m9Uef!{7)(Q76+L97e*PLtZhnX zKFg26IHtp`E9LQ+A4CcyKB`VNhmLh!YL*c-Z3ZdVS0K zj^{?#x2z9EBI`qu*bGM;=j56asYKLT-@NMu*UYscnHaR(TfpI{m52=_ExXHy^xqZU z815TLS?imhv?r)2s|dYH>VBgm88bQkqp4|IORJu)^3=4Fr>5j-5w9De)ZCOz6u3gk z$tk9ibp9N!3=z<$m7COL@Nt93N(B6a$?5-mR&!KcYTqLBnNSq-5j7VLtwJTv1l1f( z=ioHL!U%O0CI^Ak1~YIq{yMU2oOjKrcwuu0!`SZ(dLbHm(D4zj!w`2nWVAcKyk-o7 ze_`jB$K|kWX~y#~9LU3YSb*apJOWxRUeFTVxOv!K%6CJdN)*1yfBK887SxAwkxq4& z{3zo!;Vr;0l$?s9;SO;7H#`w3SESGY{Y8_w?Z+u|D5wl{E-;}#dti$P0x+JaEB z!Qp7IE0k<-blMu;Gs$Bu0;*K0l@@#xpEVyw9rU6|@dCzLLwgF-1I!)u2>&XK=?$Yr(X`;GIu=q#X{PC%@w2;|+e{-ps*VMiF}(dL z&7paO0l>qMPT;-l@6zC!s9r9_D@-HTdBfD@YWA<2^u&Zxysmy@Z`*dNk8c{`ssF9h=zIKQcZ(IckPN&N0l*YwGun&5W9!58;o-8;vb3ZO-1WmV3Xt zrGly_Ldo6_3*4?yviHNPdBHJ+3FU?x&6Pq#QO1tZhI77&09%^_@Fx9@2I7-jsy9Wu zT8Dymgpy0lXl#9cfM|fg^v+U{fAb z^&pvE$DlJv&y7{LAQ|!I6+3hoaCZ_UW6&6i21U=r{*m#q9ratM_H|EBPfm-iQ~M&5 zq!0j*X`^1%G1tXahH8M@Q2$GX)VW5CJxs5loki=3WIu zxcU9%R=@%G>^RY49oGM%A+zM?SlI*EUc*BQ2qwkyYk1VD7e2!Xe|pAX2WRs}Ctg{B zLPuD(`{p(Em{gb?nKsXBc+O84e=f}@Y#=G$Rj-s=Fhie>ekrBS$j`cM>9~f#%VkdU z=DaqBE*wG5$&Vh|NHZ%6aKM8AlzU}|*UC`i5bl2Qept{mA1c_P>IzsAWwoP~ItU}%p6;NDxEHvJ7f5-54OJ0Aexy#z z*LT~s?B+FQSrKb&?)5v=K(}~aKXWz_ygVDD&Zx5)*b_n%F_TrKyMo7kMQX6lMuR-s zqL_tB{5P!D9h`#W_3Ri)ji)ozGi}Pi;kp^>g~L`P5$Uyb@3y|h^oXuSt(4W@Gmy00 zoumuVZ}lZoVIWMu>AIb=Qpr>tw;f%n3o&TL22u$i?B3M{NLs1EegfzY*L8Q$N)2=m z6mm#U$^evTa_rgZk?H5Rq^D=bCMWRzurlyx#$#MJ)r4s`*+5tdzM_t<3k}<=4^L2bF{~b69;T zy-`ZN%>UgW3*81nc3Pc*Wg}Aq(b5tAXpA+oQQf$!+z^X85J-|YVw+R8aBXeMu_FnO zfE;L@;&;DSJPb2~JcQz}FAurU*&wV{KdECd`DC6Be#8*4Kk5GV@({}@ym;@7hfk=? z2oK6*jgQ!(&3LZ5NHhoqZOC-h8A9M(d*4i`Rk;x(PDwRUUA!z1VnxVm?lkI^}}%rcoDsM+A^ zck{72oN&q9{7DCdYQKi|L%s3uT9U-BKGuT!Wll&;N9KX9`7L zQa@J1*sv)bzg>^Kd|vFmH8H$P_n6#@n#&@bcS+GtEN(jRh|KrbDn~Lp7P%qd7aQe{8LUK z9Z!}&{((q*w&aaU94U4n%gIz1fV}QNmg-X2!aNQ%pV3wDck_uQLN%+As9U9E(n|Au zK#03gZ*&(>E}NmHLNq&YN*xG56k)9ib^#X#_g=SB=h$)sWa-Dx-9ca z`6dnl=j6hR@=cLR%KS}oesid<{V&-D?8vW_^EmnV+PYwN6`hBylk;7CC00Sl4i7ue zLY{9@IXVlOlSkD%bQUs~`HMWNz72G$-(~_x<^%Ps%;O+nE-QcJ1HIdxa*rvULtVT{ zveJ)W&e-vweUr>T9jf6a+M!MMh9R9hu9ipFi)<&xxGPhRy}xRitD+;CHw|yMw*irX ze5_jL2Lhey@QbxZ7>)LEpz|i&wq!0=jb+^Jg$$$LM{eq9(USM_;3EyRK%HDnXfJ!$H?Eo`?$GUc~s2>`m*X% zb5<0kOvUP~2-tJuXNH$6E@POP!}y&`ws7L5LSI3lSLwOjZhYKufCSU;xmW-m0@Yj$ z14?rMxA1bS?8n5XKEGTp)X0=r{EkTw%8f|y8N|b> zi*halLwROEVusgd#o1nHM9*z6&23Uw_BEE9>)?wBf$A&y{U+z(8Z*P=vzQ2GW^9fx z+Ufb9{jl2>`U`1kimw_t%$TP29X5XapeC6bZN2cn!9OM8km^MtX^n zncbVlCo_dVdL}aI=?O91m6_bvKe9JndJBCRJQ^Ivrza2aOs{YWv&4ct0%3rOr@{%^ z!VuEA$6jU>+1}<}kGxlpB7eJGkfSq%Qlm)qz8+8%0uLh{CwLKP8{xsA5CyN%=m{-h zsaY=+txLX(%I63rx5bgNJm&`qjQqq860cl-uo|z>s18|gE@z`J_7=E9rN1ywh1M>IO;lH^@F6Y<8|N2_evw}uRj95l=73?g^-su z+&uaJdfI3T!4(Q^p&Mf(C#PrXyAMv)heT-W)IPm~x~{(I;pV;dA+yVc z2_ojSf5lc6ro7fLCN(l&ClAx%)h*SS-5gcdE1@zBhb?kmp8Xp(9ibC>H%*o2t1T=j zU`m`>zD~_&ZeCOGyqHx#$a#4J3t{q@n$5&yexO>;S9IYonH#8HA&+gU5Mmu;R>)&< z^pkmcst%OnDwkQdt|EJrYbx#$kyWqZxGhcE zY`u|(yM{zF!TA+H+t7?UpFqK2#*Y-{y9u ztU6+zl_riC<+Z{CW2t++&opITo<-5FkT-5#QxCznxaF$+kYm-n+Po3RT(l?-XD>0D z$dh*+j`BeboPn(qT@^yd_Es3Ee4}uYwi%cuuU25JYZe965j`w1d!3jgVRc02$3rz+ zhUC$g1XXMJPLg?foNCR&HY}UH-lP_x1PmYRGB2;tt$aV#+HgE3bN$uwa7KantkwcR~QwaHO0lAQ^g8~jMuuxGfN3OXbBB<>Vs_nNFYWpqf;!Td_ zwE&Ji*2ThPYq`DzZWoIEE}`LO67Z&6mX$@&vh0Ss`x(H#uw6 zz+hH=t984fQjo2~i#i#UdAXnqROXVQx^;ia{71KmcIh*_hoJ{hAw+hmk(*D3>SA1s zf1z?eDswN@{=dqj7l};D`J2iV2-+tAvmIiEJpLprC;}00JE{^JHa)(D4#2K#QeVs5IFzSo8E=I=M(!%~2jLhw zG?DoOI0Ath5u+LrY*O#Z`IVN;1=U4Y2ccCseo>2=welz_Jy#rBwx`-rYpT`7TgV%w zkn@49@~Aq`Y9hCw?|hZ}&Udo%658;p@-k{C~zQsBJA+uC1#;esuc>@dct3X^K zZ>+RpG8eCwC%3CbF2QcRC!YnJ{fo1JGr`XBQ2n(08M6EFWvd>Rd3Ag{Ka8sv?}REc zb-GZ`#=2)vY!QN#R1t*?~}6`7DPTYxFc8a*2Xk^$(aSc zeI{+JFn6CR+}%^Siy+_8OR$ytyMSC8t^C7^>`Oo)Q0&IMq+lWgc1_UNZA{^2!63$A zb&QNol+fkjQo)cBDb$gLg3X1G5r(G5H~`(1Y_%7`_mYl$a&_Wtho>-+e8t>+SH zozoE?^G*QZl015@?OBi>T7c2$qWSW5K-Ll8DXENOnQ^q*1kG|W7g=XCcj;XRXM$LG z1;1B{xy43TH{Hb@$dl-liG>U~2T+-Jtb-MFH_R8npSc5!n`xAsY*{mmV#&^8Yr!4- zG|LOKWoyLO&3fljz&?;xxbsT2$k#o+-ELRx;t2%V$7ySkm`iRI_i*!?H32QdU^UhF zuT*2ujsdTbyq=91ehePqiT#Ed1btiit2wmsUJE?6wxqwlb;$fnOR_Tm%vG+UrD zY?qFWJG(|5B!vj#UIka>`8%_!?Toky#GFHFZz|p+6?8786ZNR>_w~#bb+yvw^46~v zv=BPYi8A5tJfnIDq&wn})y8*0OwST~@g5Evo8Dt+A8b%iG}y)`0-o@2-Hn1;_;v)GQBIt1V|fRFQ67l;`D|aNq_Y|zwkbx%!fyG%n+yD zSaHew#63k8fB}+U*dOHAlO;O)uidy^ZruL#-i`PN$TgFrgO>5+Q0DOPm_$JN4K@^D zE9sZY5#EamY0$Am&J$GsGX_$>6kn%b;=Mdz353lw9AXh0q-w!{*@u~iL_td=2!=d> zoX%`(RPCoqVE_SXg1JD?bAi^`LVv9FvaMHTBT+CLSl&K2$RCNT0!WeSoyWIk1SAV) zl*+q0UA_2%zS{2P(}qscV9GB_#L#;6e3t%7f5$Y|gm};pkS#k@6Azzy&zREpR{h$T|pPc$KngWOKH5Y5RfjI6Blz|iGN!`e}P7h zCI##m1SBgl{IWwxn8G3TvkE#FIVv8BN{oT7rtX2(AvNW(V*Gs!$x=83;UdD3hs4Ea zyz=QCMG2`SdEwV!4w3?^KOB;JMNoBI`RE~?3v*48LaLI0IsjSxuq7Tp;Yae+DP>i|@=pTx@Rt@sRvM|{7j*H#mOnhw8%Al~*nz!o2>tVjr?Icw5$ z9?Hv-$7>XKF*RrX8xO>e9{EynnLhNnDi!w>aU?^%y!8xeq}R=oG*&J2x}nAdh@+m9 z6PYP(@wq9T+O;>)Xg2NU|AL+n>XNCJmPF&`#`;FHsWs=vExS^?Qpni~@guO&d~j$R zns@BpnP@bVZGq^z-5n|T44Vo%KHSv2w`otJ(M+{-j$kFW?&(N(BpS`;wnnqL9pxnX z-&9*p!j8o59ZkCvQr_9P83Ip6Y}*s4!p3AOJ8#ixitlPSwaWjOnjT>q=HE!6jt#NZgo?hCFRrzz>xhv7JWAE;SPd*EJ zn;PrtUToZK$}%w(+A}X%%KCSJ;rE)xM@KVbQX>sN_Ki;t0iJM5Znpyi1EVht9Li1( zj1Io!QrOqZpUSZKr3n}oYpMZEnXZfkl?lcwq#2d5X;hZZ)k$Rrhcc78S#_zVwzdRr z^MPL5)Vy~OVgr#|+js0tsQZ5KhnCjX-5BJgd<4iJm#m35O|~{q7Q)agqHnih>qZ5l zClS3COMN@>R@mTe6rqs5U9Q;_%Ff4kXVfB?3Tw*^d2cMHEh8@DvH8B*6R=wrQt4sy z1?-?tt2-lZ`Nc@S5H{Gr7NHnHaMGvs{ZoZv^ym((Heel%peg>;YA6Bt@?MwW1-x;M zHVm#H<9W~bm?@7hOy8Jvff;NP%KWxKEpyLEt#yi4-#kZq{*WjY$pz-Z1h4%&yD- z4G`pvJ6`4Dj?akMszMm!xccLw87qh;4h0@ui)B?I5GsTrE|KecOjw62a|&`ElJI zSaPENQ$^(K!(;F9ZbmLijjoWstsoH-5Rn$HBWpS=(fs$u}*Qvh17Ss2~PKxm8 zfn`46UUW1EsqOE-{pR}}WW??4~E+n2M8!iISG7ktd&!SPI=l+i(^U7LkSWT~@ z`RKemCMO3^8a&qv;cgZ?rMGMg*jB1jny&wUbV}nzb>FA-yRhv1^#4xjf5xZC|DDn- zYrPLgA^+p2bekCw=lK8te2X}rz|NT`zeJqI^SsY<_g}*<{VC5~@MUDsr=w=(duOUP z=JH}XbtX3#%Mm$fI!a>U%SBFJHrCOQ0r~uA)lYHmeyV8u&RsiD2Y-S0f9_&$MA${w z=>xd;&lxobK9nn!VcI*Zq)Grnp@*_~Q=LL?DELywJAX4P%(<>h+#}T0DuATb-%|E8YXT%o?gCC z6j=3{<%Y3WB`#Jnwz<9>g2h^LWVvCS_yKz8Z922uFvM#r<@fcs_&ZWw`vID)o-OVz zHw?OmHyOVsig&np12#l|Qz?rz91B}~R$&;+c&C>OyI9K~i5kYQeCY}?Phju6Aqod3 zzJ$dH(mP1G;7eJEB#SWVTGTK$D~l-1_+m7>A2f_ZDqXQwKVNDXqYoN}m{)RSfSVR2 z_^4qVQpa5}g5vaI!x(+kFxDzSOz^>r5u`J#&_77>Z)EW>Btx0TrwI44j{6!`j{hYz znNKVA#0t8*913nXl@^F2E`S|S)*x}kCYrq(&@7~wDNnG!1fT|lXE^N!Jf~uj( zqmDnL_$P*cs_{>~RYGK`*dxz|P zGnri`6_{KVz!@=H!>Vn__6~$}tCybwZ&hmQ#lK9F3Z9GwZ=!tnN%>JmJi+$LvRREztPNJE3&f)t&C_(_^Pv zT*KOvRTcCqd+}o=hlj{n44}X=YbiM``%x+s*jPW-Nt!7{SY6N*<%yS|8F34f5?X%bEmCGFyErb46amtZ+f4&*JGxTEyjw!Sd{0)bt}gp3<|(XU-}M1 z3`?~##fzO`on1X6+puDDx)7crb+fq(ourx6bJl4ydwjDI3bgmE$JL;RQDs=TU`s(# zlk7f|?3QY>J9@+dBY?+rA8>_`y^@z+$biBv<~BN??3M|#J1mtc8pz~Mq*A1<1UFL; zDx!MKDzc*k2gwmL2iS!MRv&Ak0rLcG(im%?L3tr&yzIuYt3fD7#0*vtlquO;B~G%K zRLBR2S*Za;U%s!zj8!51)#QE+xnBfT37lIoL);EY6VI6OixPvG)G_0?B|0t(lQLO4 zFi+Lz8zmY`jXrQc1$+(Qq7pO2C+_EiVNLY$u>QH){pxeS=(PLE+uCPgsjssL^c3e@ zo({DNLnpaOeAd?>uE7eX)>~qzN@(&Xl@he87tT7E*rAY#PmR(NoEpt#Vj)&E2iGNO)}R)QOqxJZ?IWm0l~{O? z=V4&d*h#YrMa0C7QXGxE(a*_Cjh!^B)kY6HS;I>gm+3CCwi}3>s*NV5TouiTk4r2w zWj&JOxrt$7d9Gcd_sg$K$r73SoPrZ6jv7g60qp*rpy-xsvf#|3vn*8Lyz( z6TGEkzk)Lr#MYq>J>(?V>|r|$#Qw~5dE41e&Ng0ByLbb6h8?~@Qx!&^;^NaQ8M6wA zSnMuSTztA$Vpe(nJMAnmtAhSJ9m`Ci20eOT0qX(fWRH>4iG%NTAjGP*+eXfIIs?F< zGn{5AIVTy;=aUGw|9h6W21VYISGWtKI09}i`uz$N&?a-uY%{VCApVR5`adPU;vCbD z%0y0tNuRcsr+q`rCKc8ySy3lx)^Ue2neqm47K1E%uY%65k;=imjdFkXz=R}e*1?MO zKTv@Rn*9&%{T*l@RFmNa55!H-t>!agg3p|ZW5zL~mm{V*Vmj};M<(pv$9s8Oz+o4B zeDTqYS;D~FYL?&%z=up6%YcuR>)&1LgKn*x8DtCAY2r3QFYUa^F*`lI=1jKH38@-vB8cSBq$ToKu+Xc~@#7$5m~n{qqYGZn%j^_W7($>UPK^P~@BEsodo$vVk{ zkChU`CWnzZ!?R-PlF(6fkxm62#5jF2F!FB=6 z2kZf4=b4~F~;e5D*IXz~Lw$4Fxl{g=g8>c~b zi7!h)%bzZTza-}c?l5vPA+V7JI4}>Y@r9^W4ldWb93_^i3van+=fgMN8M+KEf#)j( z3VH~bPYBXi2-*+BnOo80i|HowRTe7fCZ56#;*9i3{eBso$dsY9N>y4F@0RlZUx_`l zi#J5mGlc9hlc-2F*(GWU!7MclO5(fRX#^WAh{WZDf#DMZdIAC18?xD4he&rH2GA+t zZN4)t?n#?n+*r`>xEu_8@1_X@xQUhLfWgG&`IS@)!tD%A+ zSH(0dvG5J5dy{x)UvGn$>BCF89{+5|4!vLT8T!Fu=*N}5-;Cp*YW&lWey8< z|Csov4gaL^PY+lSm9iixbijT|#oRIZ2G6d(d5>ujxAWK&YPF_)s}`117=u(Udtyi| z#0sTH;vo>vVNWE!Cw&6x^Vt(gbp=Rb8$^;K?1`f)9iL#b^&hC#FDIu=To>m;)?#J- zxKP3twe+dU@S$Mi)cGEI5w=-7C+>jjJdYh|K5340VXvA_BVxJ}G1VLs=a?kNB)i-v zI$RtoGVsmSAilPigFu`6kml`hX4|5=1IgBTVB5g{3Obh! z8OAnx*W^otwF|wJkVjO5xB#$@B$zX8W-ZFE=aOr=7U?dwDd$DXgPHa&!>afyIhMad z%g#)zy}^2xi^JNsHcQGlp3v0oOed93{#eMh;R})$njcjOO4~sx#zeMv%Bs>ldglVz zCumBIuLDzVX-M)V3|-Uv+z!Mk;q$P|mvy_}O!=l;eS`QKah2HG@r-Jc9T}nYz#llr*Qc^UFGMjvCqPQ-D%lJxDWTq+t@UEUvk-|0f%wh3IG_P?bQWni#dH=pT?H5zl!Yr>QH*0 zA3e@jQkHr56{6TWpwv!#z=A|=&yD;ZsNtf9a z8n>#L#Q2oY8<-dASn#yv14qoevEog6>x8;!NM0374IHi#NaGa+l@T-OPp*|HeHAi{ z-AqCt7Mi3nLtJwcJW!(fe(T+@eeT!G?w4>%GzV~fSTp-hxL^Es>XO9Ya2a#rs{0v< zNQa0qqcWmRSbHM|d;5qPFT20eYY`V13i4pdAEd9{PciF#{xPCCjN(J@^M;$CY>_4a z#CJ)m!~GJs-A}Vr|BTRAD#7Fy%kg03Z;3Ke31#PU+$|h&rh8v+st+9b&lVX*s)A-K zzy+HTw@SoZvb@Tupt+;is%GepSsO8oNCnOPmNzw;HES5hTH|0ab7ro4F$mKg6T)?J z=v^}&F$@=QLFM8-6&Ct3leo@{l4i}i2#oh}t3G|aLxXj%2h%BRt%d~4#TOx`BceG6 z(@V*Dka3?%c9Q*|SXklTyA`XT1IQ6TLF*`^3(2}FUJod*xj}q6N&m$M@pis*CCw`D zy`kMm&pgYbi+i$NZ<-1ISV~SwTHo*?y})UddBCtKy z5~zsFg($V%52fmeVeD!UA6L*>@NMsDo<)=^gHcK}h%>k&MZwj$A`RhvHsY8K>VPUV zrs5Vn2w*HRsQQT?7)vw+?+1QoRnXiPIY;jJ2K3(X6gd*!!yC{h|A6lKaRa(X59l5_ zpv?{9#w6Y3ieauQyqe>?8M&pNdvcdS^MEM&*Z8m)wFp^K>y_^UHwrm{hNcbM#0Y7%f$ zMRp-Jr{#wxn$6=M*pK|LEqB^NhF3vz1o&Ry9q}+{+R`h z$f-p=FD`Ee zqX`IdDgl&-(PPnP1zmbMWEjt&zzUk5@V8-;Y{R#@M*=l) z#FuIx%?3#n5_Xu_8P#9)&%mdX+(>suw{Ra~C z5u|M5zHS%*j^!IhI}0u<=#uzO&Ii3L#aHt0!{j8BRfn;|usVc{eF_IRZ&z>fS;0yw z{9;BM+oWUbz+EBVfmMe{Fj3-2B0&5E{++Dzt$%&-%yAJVqeUN zD0Hh*<4FbeQp%3uB)9W9H;%puX+ld&3`K{oDs0J8gJAb8nWf?_H&%S<#vTb9hSW)5 zhf=amE8I&su8Fd8g!{Ux=f}8NF{gFeB26Cdn`B(88^>;%)FS{_DWxy)k^31d)tR0s zH5jC?)SxS+x=G^QQe9@+A%)e<1ml8uY#!i@<&efC*Br9t3#k6gCV~ zn!2u8*gs(y<^{i&EF=!nqc^_9*=lF$nV z4p&$$7n-=I=(P9%Pf;z=!jlz2>W1e7BOv7K!h@YIgVu9Le+Od#Ocso>bcCCWHQT&I z#r4p|Tf#ndvX})JbcA76DgM&jByM|+a~)G@MRX7H0MZW+@_??rv7!m}=d_q97 zph7-mH=ZFJLcUu}h@4~^1aXzV-SDulRyR2scAjtx<8QQv!h!NDMo4@vK0ns}085qp zlSrc8K#vkN-b6RV4e^#&f|3wJj|L@hCA2x5*ZBfmAQ^I}mPE(VwLn;!R|koN!wSf# zL`J;+M2)WspDEIC>K$w(R=(GR;;Wz0>vX-CUvJ3F&=d4N{nsJDEZ1kfYYgn|?n`Ga{wY2DQf6cdkQ}2E1E9+hi49x4sFBPetK)@ZnL}2hp6kms zf&K4}u^~y9qutV_<5Jh=C&wwV>#7Rry;Qmp$}bkvaGhDTWP&&zy@Mm!jP!iv$Muky zBRj^1(plLKw_(Z5NXE(}n-X=pU3zRrCkCzI7e>@?fqBrR&_!}xb@@?N8csDoV6fR1La~zh zPVoE#h7p(dnIAAps^e7B1=RPE<+pOXOHzkogDx&{Qt_UfqgZ|MgZNmc{uoy)rN>jK zvm~*{Fkrq=a8PAZvvAVF=|(_mzm|&gJdL20)q{sDtAw>d zkX_cxvgNj*<`c6mq0oEXibFsg@6}QU7;PY5w9Bte9TN+TU|V*~=+pubROLXu8Bs zR#4Zo66zX^;93TNhjvqgxYP&rlp6d4&Zad&P6!GJ5%_l50gjAy5DlsX8tX;`B;b$M!aioFENZ`5%?QzfvRPU<|FLI$4G-KROQ-SNr>_W@j2MlRoRvKTvAjU zvR%uJiv_w(&Ym)Iy364Vqm!jAov25W6>_w;$h;M4V|K@Wh1eslMt&}?8&Pn!QZaJU z(atW;r1?hx_6dtG!3kldTI*p2T5Ok+vkY4++3ipuom-3&>(+>`TtIRjSzEG_b2Uat zYK*|G#{9Hd7Z#Vm3}ZhWGr|`4#8>pWxFKF!BW^)bM~=8b&MROFeNrO6roSu8w5wt9 zHGSY~ezcPngR0Urzb}%jcY#TKy@JkdXZ~=Q`8O5xMN?Tq@@rw(1)YQlB3Ws+CM+&s zlwJ#qIX#>TLLU6@&vKi^;J+9J(2hd5Ul|r>!s0wR;*T`nM&}H&!8e4|-DxUcBjyum zwTZH;l_I!F&UQFww#7Yk%8WQ0DcBvq6L$jrArtE^VHNS|2U+J`btpMI#U1o&E6uls zLKxI)vX`uhr?~hmeT9CA5@bxba%BxOENk$KJpiY#-3F+&6xeC-7yMknQ<>COh9+su zV7Wfb8%qraww3OC*?qlM*OLv_)|j$|Es4easFLKFTSQ7I>YOYUpRgJyhTn9Ax*HG5=ly39&NOdfgi4xxiphyh>OENltwj zmYnt2P+~A1DYS)%Zv#sPQxwqsSHlUpk9`5basd2 z75lip=vS>F@7i6S5h`9zF(}4ES3AZ`Na+R-oM3=bmNJsIoIU`MkiXJ-S8e2hr>5dh zNoSwSu!#YZU)xLhbkwnqv_JYPnomKCU!1L=FT`A;4{|%SFMfOw7C$CdQVg3=6?Ryd z(H!3d5u1szgI;eh&6g+0iHM8t0S}u1j7K@T93}+3gP2+PB2h*xaom8(*=t}6wfFLl z2ur1N@Q~7GR%Piku~6o#fiCr zfrYAioM$BP*%7pgFuW5=<&d&X;&p7I=Y)OyInOg0%QfMI3pJDz&dHY1e6lixe)P|^ zRtOGg9u7^*j;|!=S^qXZ=WgSzdt{nW7A=+DiO!XCAF=^ZEKApTds1rT&}>LxI!Yz2 zl3-IYuh1Y3ITDe34R2mj!J8Gd%DVT_{Qd|zMp&F>Us7RNwp2r5jQid`w5Srd!YZ~T zSuR~Y=#AJNcZf@-R`?r;9khe_X zW94cX>vq$*&$grByGyR<*b~cF+StCakAIv(Chdc&90zxU3yKU^;glW2c9Fl z#J%h6jvS_|xLF=1dnfD^@{SF<3|E=(!&J&1Jk((T@vro&$xge}Czz%36PtN^68pK_ z*7Y)H@iKy5<~R}xi!R)Ux+}c+(SG6AiW{8@ionly2CFJ89iHR4y^>A~m_gvRf)Es5 zAmFr=K{NgG@$58MUq06soB)r1Nmotrbzd{px{kl!#klMuCoVnM`{%!uTreL3VS8EWdXIF6BE3A1G^V9* z9$ypRoE%=xv&K&xMTbLZ8s^i+y5%Q5+8X6Qs%U#%E+rPSM-jw7#AW(KeB<@{q^cKE z24|_1PBBC= z`NTZpg6EQ~h`b3wh;hQKMW+)qjrN$=iIN^IZs!TqGfHbo2flafonc|R#vW8XMk zIAwmfi+=!(>syt)SjWSwQG~aa9>q~b8w>S3xBYFENQa{QXS%u+dK@ZwvC`QRhHfu4 zj2G3>iMvEGPBGc#a7mfNd-dO5z@{b{P<-R7wn4 zp)SI?^K<;;3k6xu=*uc^j1MH&n?m;xFwQ3W4>*#ooUYL=l@ zsv5+ftx3GNm>K>eIZc%f;+!>vba8U_coqa~Y3YbBw~d%p)>5rLubBSqZ&aF%>K7*7 zVc?g}Cu>8@7B^kCICFr?8^j+O$)ylmoIMxLpao!ye*#Vro{f@`TJW7&fFA@V#no_w zIEQy8>@J>*pt(;nyO>|#-C^-sfVIx-T*(f(fG&{ies-7YG?kIFryR`DG&$i;xUg+A z>o~iXpn#){aY=!#=JHFQV8(nEIq4WVi702RsR?A1-1(33ESKE*7|r+81UnQ15EdWP zd{X`3^0C{@D*S-VVR0_qiN3G)G}0Nu01BFCu>nfXL(+_e#pQpZU(uzK!>0J+RbesD z%C?ZVKu4PU4c)yK~Y#+0+d`=P{SfE@u+PB+jzBYHn*-T=p88G`E8Wn;Teha`sk|v#*K^l-O#O z+)H8cnjgJ}v9Ds7&r#*Gdw}d%$Yp$@xzU4Uhg`*N)w;`c8G4~`0uW;~Twv2nZwCOc zC^e=PJ2NIl_~3TN4Dq#Lu&bX^L)>x`JQczd7Ma$BBo8!ZbcUpdkW!=1jT;TgYh9@^ z<;Jm}b;*jS^Iq(G%2Q#?0E-sRg-US|Ez#t+x)>uvC6ap%F}U;Wh7>h(yqel^m?`48!hCk|&k z@zwERyqN~Z21hf`9f&^@f0^%BhG9GlD;sbl@>%?4n#B(`xy$08OPZCd{EYrm7KPC_ zav4JToy8%F&(CWUl1niBdvOkcoyJW6C-iKULS3uw(SMEMuRO$K<&wQ}4MdLgrsna_ zg~<``NtJwVR|z@G!@}_-P4aNS@_Zc-CyMVH7Pncf_$)bD1G`pbSbXI_2N+G#l`l@4 zu{^e;ln%(P>lNsJzsi*gi`xmZUon^|OK)m1$*bB&_Ss5pbVj!N*>9lclNn&33dsy) zeDG=j;AsGi#MnbH_>83tssk}qDLW2@#2_XG-tuQgomLA1t4&(1`s4_3NXn3Nnjh|i zLt(6&$`pJHTV@oJ12#;YhS(5Cjx%CbiMi5M%?t$cB)dZHF>AU#fq_rhQ;uGQum?G{!pX#kyHxj`G)7CbnSoxB>4zU4uO^?I|+UIi78{EqWIa6hlL*5jT zEOJJuf}mjO@k)6EC?+h}D}@CSpRiy?2@A4-5IR8fJC~s~^E;On=1A*VgobGKY_-qv zmMz;6l}@qcFn7tZ-=_vTEL|n*o_1a?W37NDNbaNy@#8;}t*DR^1D#UdieT8!1OJg6 z>>1sHc$U6B@SM^qaKu}X=$3m7_ch|i0NJ}ElIM;IvJ8Cp!{jW(gAByV50kySoSd?- zxC9I#e-D5S4cqBb*7uZa1DyF5j>C>E;~;-aa@@H4^*i^At_3nEaItbd-iJx!oPto~o&`Lz;3c({9Pt`N|BJ{ug>CJgh4qn}h$j$| z;6icF^0Wr@Cf7P}kmjLcwMfhiKnQq{@z7i--jL!K;#{h;+@cxA}d ziVjK@el0!_pNs!2CRPCd2zC?VD|&yR!(+(el7k?{3Vz>%U`Y9VBIY{K)iw}FR#L>? zf?iY9H4EQkKuN)Z=B3eXNMFyWvBN?D^Z}YQYw|BDQb-nLd1I^b`1nQTCunmxq}_U#Ma5s6y@^Ag zDe~Gb!W&!gL%g2Ok)5!cZv>>0RTbKUF2WDVPJ%KBgnWw&DS=?#85W876TOoe^QtaB zQB~Jc2#-@Fr4aeT06z~+N*lDSZRbky?h`)R*A?xD@}wt0LBrE0>1^pkynOt`rKtmR z)G!sZHIIyV#7ouC!pCpWt*|tHP>d*J)w%=XlI~r@ctmAGqTn2rRt8ur2;vW7X3X;P zLA411se<`%qwxG(_w2)=s}l2r0|9A*(+-kjZ`vW`I~kTfc{Q+l=vU&a$G!HGcEtK< zUgu(O3(|g6N^#(d))UA`4;Ddj40PH(AMZT;dz;{y zvMJ9q>AxZZYEQK9YHOEt{bHg5Vjx%G)Rt^<-JL?tBVD2@pRB<~DB}y2wP{Zx*}kJm zXNJs*3xY@0Ed{)?Zq~2CgfY-JIc#aO0!8k=rA?ey3!6NtQupxhGK#Plsfl+aQmwn% z60)@E4E}!e1~OC z4!@wS5#m2+kFaUOmVndI2c_idV3}v&SV(Y1ck~L?p`hdnOAn?Cut`8bregf>2|U+< zdX0d6uaM-5#SIr>;qa|WiBrEA$yE`<*r=`r#VBHX2DFPm6r%?t>i!>~2MgcB_eqZc z>qFOnfFi3(iqlB?r4sCYUq6c3MTQ~X`~eXlMn=51$S~I7QlxskSi9>>4I|}CS7>C= z!Cj?>(WMRm+;oc3qfY?^bVsEuHZt&!!iFNh#NmZ4`Fltv%M7DOrPBm|YT1c=z_Rsw zBR{V2Og*&@FIr|&i?8V(dPzeE1eu;1)dSDF%Dq`|Z2HaEz`+B4w!iP$jb|wyU}#i~ zUq|u_0nauB{Y*tqE;bl&S3ZX_ZvBq;fWI{(&cm+YV{%%=O;kIla!w1d1Ge%*9ooWI zinn1;RxD`vrQ8;tFW;Mm!u_-vJ9ywZpJhX2K+NFXCz}99sQd!YMt&V}zYz3=NH-9- zM*tHu`iuV&s~_({WMUm~yHZMin}ppU&RDgKs+%&!bukwqJ5^0~DoJ)KL3S!dcB+l+ zRN5*fJGGtcRK2)?M?lEnm)Lu?eXhM)mY&>^4iO$M;OdD>Y|k+Ymmi@%Gz%%ZcG zBU=d&v3pG|E|N9|VS)ntz)#KNzbs@;r*0!k8Win!gK%hT;lgpT%v%LMkPC8s%s6y-SurpRe-EA&GfInC)p zKfwEpi61I*Ncrm?u^uC*xgNk<4gQrypb?mJeCyXX4OgiZH*B!Kbj9tq@xRqK6+gP$j>r=0))-eJ+?)*OI{vb_iZ z_CV0PD!QjIUrSvhU9Q%@3FxC-e0HQot&coa*?iayzuF@%1Hm_1F>V#k5?rxp=4Z<` zc!go3mWAf>!X&fG|8CD$2gNxri$~aeK+LZ3NNX+%05*cJRvgs9TIb_rV7$Vv|7P(T zUH`d{RiYhTm*vrxyd{6N%knq^nvcYHO57sXi1(`-y_)N{GScPNU2=#t{cdq>bR&|X zxBN^8$qxb{9EqKDZP5cBea&B&nx+UR_+NzF@+8MdmxoYH_Y@_e_2S~w)#59!G`=k$ zK>IW}5c!;+V!EfehGMb}g%-i8NuTrVFAL%R`92I}1fD>yp}f-n^t~t%CD&lq%BWZ8 zOB188hxekHR*rLRsRr3GGQ^sb$`C(b)b4^C$a?t6pvihet9?R{BUN_%1&mca%lAq zkFFb^JhEP8TF=D#`}^bZ!LfMer9;Ek@YoSKPLtzDCI?4H@%PB!*pckukxUM;-wuzy zkOetimG$e_F9AjUH^R}($V7ZJBmcjnHQ60MK77a;9`)C(wW+CjZEAdEWN>Uq(*v#l E25b$a9RL6T literal 0 HcmV?d00001 From 9b3d87d6869a94bfbeddcfc3ba5c4cba9b84e880 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 3 Sep 2012 12:44:24 +0200 Subject: [PATCH 0467/3340] - patchlevel 641 --- 7.3.641 | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 7.3.641 diff --git a/7.3.641 b/7.3.641 new file mode 100644 index 00000000..daacdb4f --- /dev/null +++ b/7.3.641 @@ -0,0 +1,68 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.641 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.641 +Problem: ":mkview" uses ":normal" instead of ":normal!" for folds. (Dan) +Solution: Add the bang. (Christian Brabandt) +Files: src/fold.c + + +*** ../vim-7.3.640/src/fold.c 2012-08-08 18:01:00.000000000 +0200 +--- src/fold.c 2012-08-29 15:17:39.000000000 +0200 +*************** +*** 3373,3379 **** + /* open nested folds while this fold is open */ + if (fprintf(fd, "%ld", fp->fd_top + off) < 0 + || put_eol(fd) == FAIL +! || put_line(fd, "normal zo") == FAIL) + return FAIL; + if (put_foldopen_recurse(fd, wp, &fp->fd_nested, + off + fp->fd_top) +--- 3373,3379 ---- + /* open nested folds while this fold is open */ + if (fprintf(fd, "%ld", fp->fd_top + off) < 0 + || put_eol(fd) == FAIL +! || put_line(fd, "normal! zo") == FAIL) + return FAIL; + if (put_foldopen_recurse(fd, wp, &fp->fd_nested, + off + fp->fd_top) +*************** +*** 3417,3423 **** + { + if (fprintf(fd, "%ld", fp->fd_top + off) < 0 + || put_eol(fd) == FAIL +! || fprintf(fd, "normal z%c", + fp->fd_flags == FD_CLOSED ? 'c' : 'o') < 0 + || put_eol(fd) == FAIL) + return FAIL; +--- 3417,3423 ---- + { + if (fprintf(fd, "%ld", fp->fd_top + off) < 0 + || put_eol(fd) == FAIL +! || fprintf(fd, "normal! z%c", + fp->fd_flags == FD_CLOSED ? 'c' : 'o') < 0 + || put_eol(fd) == FAIL) + return FAIL; +*** ../vim-7.3.640/src/version.c 2012-08-29 14:23:06.000000000 +0200 +--- src/version.c 2012-08-29 15:18:26.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 641, + /**/ + +-- +You cannot propel yourself forward by patting yourself on the back. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bb79499ba1a58f0105996f131f81a95bfeff152d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 3 Sep 2012 12:44:24 +0200 Subject: [PATCH 0468/3340] - patchlevel 642 --- 7.3.642 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.642 diff --git a/7.3.642 b/7.3.642 new file mode 100644 index 00000000..ddc40321 --- /dev/null +++ b/7.3.642 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.642 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.642 +Problem: Segfault with specific autocommands. Was OK after 7.3.449 and + before 7.3.545. (Richard Brown) +Solution: Pass TRUE for abort_if_last in the call to close_buffer(). + (Christian Brabandt) +Files: src/window.c + + +*** ../vim-7.3.641/src/window.c 2012-07-19 18:05:40.000000000 +0200 +--- src/window.c 2012-08-29 15:42:15.000000000 +0200 +*************** +*** 2269,2275 **** + #ifdef FEAT_AUTOCMD + win->w_closing = TRUE; + #endif +! close_buffer(win, win->w_buffer, free_buf ? DOBUF_UNLOAD : 0, FALSE); + #ifdef FEAT_AUTOCMD + if (win_valid(win)) + win->w_closing = FALSE; +--- 2269,2275 ---- + #ifdef FEAT_AUTOCMD + win->w_closing = TRUE; + #endif +! close_buffer(win, win->w_buffer, free_buf ? DOBUF_UNLOAD : 0, TRUE); + #ifdef FEAT_AUTOCMD + if (win_valid(win)) + win->w_closing = FALSE; +*** ../vim-7.3.641/src/version.c 2012-08-29 15:22:14.000000000 +0200 +--- src/version.c 2012-08-29 15:49:52.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 642, + /**/ + +-- +The psychic said, "God bless you." I said, "I didn't sneeze." She +looked deep into my eyes and said, "You will, eventually." And, damn +if she wasn't right. Two days later, I sneezed. --Ellen Degeneres + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 51cb4bcc8c65fb84e8d598a1d3349d4f03240f4c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 3 Sep 2012 12:44:24 +0200 Subject: [PATCH 0469/3340] - patchlevel 643 --- 7.3.643 | 73 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 7.3.643 diff --git a/7.3.643 b/7.3.643 new file mode 100644 index 00000000..c2f700c5 --- /dev/null +++ b/7.3.643 @@ -0,0 +1,73 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.643 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.643 (after 7.3.635) +Problem: MS-Windows: When starting gvim maximized 'lines' and 'columns' are + wrong. (Christian Robinson) +Solution: Move the check for gui.starting from ui_get_shellsize() to + check_shellsize(). +Files: src/ui.c, src/term.c + + +*** ../vim-7.3.642/src/ui.c 2012-08-23 13:28:50.000000000 +0200 +--- src/ui.c 2012-08-29 16:20:04.000000000 +0200 +*************** +*** 298,306 **** + int retval; + + #ifdef FEAT_GUI +- if (gui.starting) +- /* possibly a system call during startup, check later */ +- return OK; + if (gui.in_use) + retval = gui_get_shellsize(); + else +--- 298,303 ---- +*** ../vim-7.3.642/src/term.c 2012-08-15 16:20:59.000000000 +0200 +--- src/term.c 2012-08-29 16:22:25.000000000 +0200 +*************** +*** 3006,3012 **** + int old_Rows = Rows; + int old_Columns = Columns; + +! if (!exiting) + { + (void)ui_get_shellsize(); + check_shellsize(); +--- 3006,3018 ---- + int old_Rows = Rows; + int old_Columns = Columns; + +! if (!exiting +! #ifdef FEAT_GUI +! /* Do not get the size when executing a shell command during +! * startup. */ +! && !gui.starting +! #endif +! ) + { + (void)ui_get_shellsize(); + check_shellsize(); +*** ../vim-7.3.642/src/version.c 2012-08-29 15:50:22.000000000 +0200 +--- src/version.c 2012-08-29 16:25:42.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 643, + /**/ + +-- +Eight Megabytes And Continually Swapping. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3d8454e5a4b5104ba9551692a6b7e1e722846e89 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 3 Sep 2012 12:44:25 +0200 Subject: [PATCH 0470/3340] - patchlevel 644 --- 7.3.644 | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 7.3.644 diff --git a/7.3.644 b/7.3.644 new file mode 100644 index 00000000..6f2630cc --- /dev/null +++ b/7.3.644 @@ -0,0 +1,72 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.644 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.644 +Problem: Dead code for BeOS GUI. +Solution: Remove unused __BEOS__ stuff. +Files: src/gui.c + + +*** ../vim-7.3.643/src/gui.c 2012-07-10 16:49:08.000000000 +0200 +--- src/gui.c 2012-08-29 16:28:46.000000000 +0200 +*************** +*** 37,44 **** + static void gui_set_bg_color __ARGS((char_u *name)); + static win_T *xy2win __ARGS((int x, int y)); + +! #if defined(UNIX) && !defined(__BEOS__) && !defined(MACOS_X) \ +! && !defined(__APPLE__) + # define MAY_FORK + static void gui_do_fork __ARGS((void)); + +--- 37,43 ---- + static void gui_set_bg_color __ARGS((char_u *name)); + static win_T *xy2win __ARGS((int x, int y)); + +! #if defined(UNIX) && !defined(MACOS_X) && !defined(__APPLE__) + # define MAY_FORK + static void gui_do_fork __ARGS((void)); + +*************** +*** 784,794 **** + gui_exit(rc) + int rc; + { +- #ifndef __BEOS__ + /* don't free the fonts, it leads to a BUS error + * richard@whitequeen.com Jul 99 */ + free_highlight_fonts(); +- #endif + gui.in_use = FALSE; + gui_mch_exit(rc); + } +--- 783,791 ---- +*** ../vim-7.3.643/src/version.c 2012-08-29 16:26:01.000000000 +0200 +--- src/version.c 2012-08-29 16:33:30.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 644, + /**/ + +-- +E M A C S +s e l o h +c t t n i +a a t f +p r t +e o + l + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a5040f589e2b40e65dd344b94c32c1c5aa76da06 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 3 Sep 2012 12:44:25 +0200 Subject: [PATCH 0471/3340] - patchlevel 645 --- 7.3.645 | 118 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 118 insertions(+) create mode 100644 7.3.645 diff --git a/7.3.645 b/7.3.645 new file mode 100644 index 00000000..40d8ee0b --- /dev/null +++ b/7.3.645 @@ -0,0 +1,118 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.645 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.645 +Problem: No tests for patch 7.3.625 and 7.3.637. +Solution: Add more tests for the "gn" command and try/catch. (Christian + Brabandt) +Files: src/testdir/test53.in, src/testdir/test53.ok, + src/testdir/test55.in, src/testdir/test55.ok + + +*** ../vim-7.3.644/src/testdir/test53.in 2012-07-25 15:06:20.000000000 +0200 +--- src/testdir/test53.in 2012-08-29 16:37:44.000000000 +0200 +*************** +*** 34,40 **** + gnd + /[a]bcdx + :1 +! 2gnd + :/^start:/,/^end:/wq! test.out + ENDTEST + +--- 34,46 ---- + gnd + /[a]bcdx + :1 +! 2gnd/join +! /$ +! 0gnd +! /\>\zs +! 0gnd/^ +! gnd$h/\zs +! gnd + :/^start:/,/^end:/wq! test.out + ENDTEST + +*************** +*** 57,60 **** +--- 63,70 ---- + one + two + abcdx | abcdx | abcdx ++ join ++ lines ++ zero width pattern ++ delete first and last chars + end: +*** ../vim-7.3.644/src/testdir/test53.ok 2012-07-25 15:06:20.000000000 +0200 +--- src/testdir/test53.ok 2012-08-29 16:37:48.000000000 +0200 +*************** +*** 21,24 **** +--- 21,27 ---- + SEARCH: + searchmatch + abcdx | | abcdx ++ join lines ++ zerowidth pattern ++ elete first and last char + end: +*** ../vim-7.3.644/src/testdir/test55.in 2012-05-18 12:06:58.000000000 +0200 +--- src/testdir/test55.in 2012-08-29 16:50:51.000000000 +0200 +*************** +*** 378,383 **** +--- 378,393 ---- + :unlet dict + :call garbagecollect(1) + :" ++ :" test for patch 7.3.637 ++ :let a = 'No error caught' ++ :try|foldopen|catch|let a = matchstr(v:exception,'^[^ ]*')|endtry ++ o=a :" ++ :lang C ++ :redir => a ++ :try|foobar|catch|let a = matchstr(v:exception,'^[^ ]*')|endtry ++ :redir END ++ o=a :" ++ :" + :/^start:/,$wq! test.out + ENDTEST + +*** ../vim-7.3.644/src/testdir/test55.ok 2012-05-18 12:06:58.000000000 +0200 +--- src/testdir/test55.ok 2012-08-29 16:51:15.000000000 +0200 +*************** +*** 115,117 **** +--- 115,123 ---- + {'a': {'b': 'B'}} + Vim(call):E737: a + {'a': {'b': 'B'}} ++ Vim(foldopen):E490: ++ ++ ++ Error detected while processing : ++ E492: Not an editor command: foobar|catch|let a = matchstr(v:exception,'^[^ ]*')|endtry ++ +*** ../vim-7.3.644/src/version.c 2012-08-29 16:34:23.000000000 +0200 +--- src/version.c 2012-08-29 16:37:20.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 645, + /**/ + +-- +TALL KNIGHT OF NI: Ni! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4fc8774b08f357c8a22fc412dfde74f5d1e5e01d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 3 Sep 2012 12:44:25 +0200 Subject: [PATCH 0472/3340] - patchlevel 646 --- 7.3.646 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.646 diff --git a/7.3.646 b/7.3.646 new file mode 100644 index 00000000..3e507a79 --- /dev/null +++ b/7.3.646 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.646 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.646 +Problem: When reloading a buffer the undo file becomes unusable unless ":w" + is executed. (Dmitri Frank) +Solution: After reloading the buffer write the undo file. (Christian + Brabandt) +Files: src/fileio.c + + +*** ../vim-7.3.645/src/fileio.c 2012-07-10 17:14:50.000000000 +0200 +--- src/fileio.c 2012-08-29 18:19:44.000000000 +0200 +*************** +*** 7060,7067 **** +--- 7060,7082 ---- + } + + if (reload) ++ { + /* Reload the buffer. */ + buf_reload(buf, orig_mode); ++ #ifdef FEAT_PERSISTENT_UNDO ++ if (buf->b_p_udf && buf->b_ffname != NULL) ++ { ++ char_u hash[UNDO_HASH_SIZE]; ++ buf_T *save_curbuf = curbuf; ++ ++ /* Any existing undo file is unusable, write it now. */ ++ curbuf = buf; ++ u_compute_hash(hash); ++ u_write_undo(NULL, FALSE, buf, hash); ++ curbuf = save_curbuf; ++ } ++ #endif ++ } + + #ifdef FEAT_AUTOCMD + /* Trigger FileChangedShell when the file was changed in any way. */ +*** ../vim-7.3.645/src/version.c 2012-08-29 16:55:09.000000000 +0200 +--- src/version.c 2012-08-29 18:21:07.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 646, + /**/ + +-- + An extraordinary TALL KNIGHT in all black (possibly John with Mike on his + shoulders) walks out from the dark trees. He is extremely fierce and + gruesome countenance. He walks towards KING ARTHUR and PATSY, who are + wazzing like mad. (Salopian slang, meaning very scared. almost to the + point of wetting oneself, e.g. before an important football match or + prior to a postering. Salopian slang meaning a beating by the school + praeposters. Sorry about the Salopian slant to this stage direction - Ed.) + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 52f4b22b0b9705f0d0890e142268406603a55644 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 3 Sep 2012 12:44:26 +0200 Subject: [PATCH 0473/3340] - patchlevel 646 --- README.patches | 8 ++++++++ vim.spec | 23 +++++++++++++++++++++-- 2 files changed, 29 insertions(+), 2 deletions(-) diff --git a/README.patches b/README.patches index dfe8b806..477c90a2 100644 --- a/README.patches +++ b/README.patches @@ -669,3 +669,11 @@ Individual patches for Vim 7.3: 4539 7.3.636 (after 7.3.625) "gn" fails for some zero-width matches 3117 7.3.637 cannot catch error caused by a foldopen when there is no fold 1783 7.3.638 unecessary redraw of the previous character + 31440 7.3.639 it's not easy to build Vim on Windows with XPM support +455297 7.3.640 binary files for 7.3.639 + 2219 7.3.641 ":mkview" uses ":normal" instead of ":normal!" for folds + 1810 7.3.642 segfault with specific autocommands + 2060 7.3.643 MS-Windows: 'lines' is wrong when starting up maximized + 1925 7.3.644 dead code for BeOS GUI + 2910 7.3.645 no tests for patch 7.3.625 and 7.3.637 + 2353 7.3.646 undo file unusable after reloading a buffer diff --git a/vim.spec b/vim.spec index 527c445e..32fa4ff6 100644 --- a/vim.spec +++ b/vim.spec @@ -18,13 +18,13 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 638 +%define patchlevel 646 Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 2%{?dist} +Release: 1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -694,6 +694,14 @@ Patch635: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.635 Patch636: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.636 Patch637: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.637 Patch638: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.638 +Patch639: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.639 +Patch640: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.640 +Patch641: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.641 +Patch642: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.642 +Patch643: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.643 +Patch644: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.644 +Patch645: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.645 +Patch646: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.646 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1478,6 +1486,14 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch636 -p0 %patch637 -p0 %patch638 -p0 +%patch639 -p0 +%patch640 -p0 +%patch641 -p0 +%patch642 -p0 +%patch643 -p0 +%patch644 -p0 +%patch645 -p0 +%patch646 -p0 # install spell files @@ -1935,6 +1951,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Sep 03 2012 Karsten Hopp 7.3.646-1 +- patchlevel 646 + * Tue Aug 28 2012 Karsten Hopp 7.3.638-2 - fix some man page typos (#668894, #675480) - own usr/share/vim/vimfiles/doc/tags (#845564) From 7ae6defe1d406045b43b861bb8843efa597d5858 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:35:39 +0200 Subject: [PATCH 0474/3340] - patchlevel 639 --- 7.3.639 | 846 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 846 insertions(+) create mode 100644 7.3.639 diff --git a/7.3.639 b/7.3.639 new file mode 100644 index 00000000..359dc6d8 --- /dev/null +++ b/7.3.639 @@ -0,0 +1,846 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.639 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.639 +Problem: It's not easy to build Vim on Windows with XPM support. +Solution: Include the required files, they are quite small. Update the + MSVC makefile to use them. Binary files are in the next patch. + (Sergey Khorev) +Files: src/xpm/COPYRIGHT, src/xpm/README.txt, src/xpm/include/simx.h, + src/xpm/include/xpm.h, src/Make_mvc.mak, src/bigvim.bat, + src/bigvim64.bat, Filelist + + +*** ../vim-7.3.638/src/xpm/COPYRIGHT 1970-01-01 01:00:00.000000000 +0100 +--- src/xpm/COPYRIGHT 1998-03-19 23:51:00.000000000 +0100 +*************** +*** 0 **** +--- 1,31 ---- ++ /* ++ * Copyright (C) 1989-95 GROUPE BULL ++ * ++ * Permission is hereby granted, free of charge, to any person obtaining a copy ++ * of this software and associated documentation files (the "Software"), to ++ * deal in the Software without restriction, including without limitation the ++ * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or ++ * sell copies of the Software, and to permit persons to whom the Software is ++ * furnished to do so, subject to the following conditions: ++ * ++ * The above copyright notice and this permission notice shall be included in ++ * all copies or substantial portions of the Software. ++ * ++ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR ++ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, ++ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL ++ * GROUPE BULL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN ++ * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN ++ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ++ * ++ * Except as contained in this notice, the name of GROUPE BULL shall not be ++ * used in advertising or otherwise to promote the sale, use or other dealings ++ * in this Software without prior written authorization from GROUPE BULL. ++ */ ++ ++ Arnaud LE HORS BULL Research FRANCE -- Koala Project ++ (XPM - X PixMap format version 2 & 3) ++ Internet: lehors@sophia.inria.fr ++ Surface Mail: Arnaud LE HORS, INRIA - Sophia Antipolis, ++ 2004, route des Lucioles, 06565 Valbonne Cedex -- FRANCE ++ Voice phone: (33) 93.65.77.71, Fax: (33) 93 65 77 66, Telex: 97 00 50 F +*** ../vim-7.3.638/src/xpm/README.txt 1970-01-01 01:00:00.000000000 +0100 +--- src/xpm/README.txt 2012-08-29 13:29:17.000000000 +0200 +*************** +*** 0 **** +--- 1,23 ---- ++ This is XPM library compiled for Windows which is intended for use with Vim ++ 'signs' feature. ++ ++ Libraries in x86 directory were compiled with MSVC6 and MinGW. Proposed ++ commands to compile Vim are: ++ ++ Any version of MSVC starting from version 6.0: ++ nmake -f Make_mvc.mak GUI=yes CSCOPE=yes NETBEANS=yes XPM=e:\hg\xpm\x86 ++ ++ MinGW: ++ mingw32-make -f Make_ming.mak GUI=yes CSCOPE=yes XPM=e:/hg/xpm/x86 ++ ++ Microsoft Visual C++ on x64 (tested with versions 2008 and 2010): ++ nmake -f Make_mvc.mak GUI=yes CSCOPE=yes XPM=E:\HG\xpm\x64 ++ ++ To test, open some file in Vim and execute commands below: ++ :exe 'sign define vimxpm icon='.$VIMRUNTIME.'\\vim32x32.xpm' ++ :exe 'sign place 1 line=1 name=vimxpm file='.expand('%:p') ++ ++ ++ See COPYRIGHT for XPM licence. ++ ++ If you have questions please email sergey.khorev@gmail.com. +*** ../vim-7.3.638/src/xpm/include/simx.h 1970-01-01 01:00:00.000000000 +0100 +--- src/xpm/include/simx.h 1998-03-19 23:51:00.000000000 +0100 +*************** +*** 0 **** +--- 1,139 ---- ++ /* ++ * Copyright (C) 1989-95 GROUPE BULL ++ * ++ * Permission is hereby granted, free of charge, to any person obtaining a copy ++ * of this software and associated documentation files (the "Software"), to ++ * deal in the Software without restriction, including without limitation the ++ * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or ++ * sell copies of the Software, and to permit persons to whom the Software is ++ * furnished to do so, subject to the following conditions: ++ * ++ * The above copyright notice and this permission notice shall be included in ++ * all copies or substantial portions of the Software. ++ * ++ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR ++ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, ++ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL ++ * GROUPE BULL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN ++ * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN ++ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ++ * ++ * Except as contained in this notice, the name of GROUPE BULL shall not be ++ * used in advertising or otherwise to promote the sale, use or other dealings ++ * in this Software without prior written authorization from GROUPE BULL. ++ */ ++ ++ /*****************************************************************************\ ++ * simx.h: 0.1a * ++ * * ++ * This emulates some Xlib functionality for MSW. It's not a general solution, * ++ * it is close related to XPM-lib. It is only intended to satisfy what is need * ++ * there. Thus allowing to read XPM files under MS windows. * ++ * * ++ * Developed by HeDu 3/94 (hedu@cul-ipn.uni-kiel.de) * ++ \*****************************************************************************/ ++ ++ ++ #ifndef _SIMX_H ++ #define _SIMX_H ++ ++ #ifdef FOR_MSW ++ ++ #include "windows.h" /* MS windows GDI types */ ++ ++ /* ++ * minimal portability layer between ansi and KR C ++ */ ++ /* this comes from xpm.h, and is here again, to avoid complicated ++ includes, since this is included from xpm.h */ ++ /* these defines get undefed at the end of this file */ ++ #if __STDC__ || defined(__cplusplus) || defined(c_plusplus) ++ /* ANSI || C++ */ ++ #define FUNC(f, t, p) extern t f p ++ #define LFUNC(f, t, p) static t f p ++ #else /* k&R */ ++ #define FUNC(f, t, p) extern t f() ++ #define LFUNC(f, t, p) static t f() ++ #endif ++ ++ ++ FUNC(boundCheckingMalloc, void *, (long s)); ++ FUNC(boundCheckingCalloc, void *, (long num, long s)); ++ FUNC(boundCheckingRealloc, void *, (void *p, long s)); ++ ++ /* define MSW types for X window types, ++ I don't know much about MSW, but the following defines do the job */ ++ ++ typedef HDC Display; /* this should be similar */ ++ typedef void *Screen; /* not used */ ++ typedef void *Visual; /* not used yet, is for GRAY, COLOR, ++ * MONO */ ++ ++ typedef void *Colormap; /* should be COLORPALETTE, not done ++ * yet */ ++ ++ typedef COLORREF Pixel; ++ ++ #define PIXEL_ALREADY_TYPEDEFED /* to let xpm.h know about it */ ++ ++ typedef struct { ++ Pixel pixel; ++ BYTE red, green, blue; ++ } XColor; ++ ++ typedef struct { ++ HBITMAP bitmap; ++ unsigned int width; ++ unsigned int height; ++ unsigned int depth; ++ } XImage; ++ ++ #if defined(__cplusplus) || defined(c_plusplus) ++ extern "C" { ++ #endif ++ /* some replacements for X... functions */ ++ ++ /* XDefaultXXX */ ++ FUNC(XDefaultVisual, Visual *, (Display *display, Screen *screen)); ++ FUNC(XDefaultScreen, Screen *, (Display *d)); ++ FUNC(XDefaultColormap, Colormap *, (Display *display, Screen *screen)); ++ FUNC(XDefaultDepth, int, (Display *d, Screen *s)); ++ ++ /* color related */ ++ FUNC(XParseColor, int, (Display *, Colormap *, char *, XColor *)); ++ FUNC(XAllocColor, int, (Display *, Colormap *, XColor *)); ++ FUNC(XQueryColors, void, (Display *display, Colormap *colormap, ++ XColor *xcolors, int ncolors)); ++ FUNC(XFreeColors, int, (Display *d, Colormap cmap, ++ unsigned long pixels[], ++ int npixels, unsigned long planes)); ++ /* XImage */ ++ FUNC(XCreateImage, XImage *, (Display *, Visual *, int depth, int format, ++ int x, int y, int width, int height, ++ int pad, int foo)); ++ ++ /* free and destroy bitmap */ ++ FUNC(XDestroyImage, void /* ? */ , (XImage *)); ++ /* free only, bitmap remains */ ++ FUNC(XImageFree, void, (XImage *)); ++ #if defined(__cplusplus) || defined(c_plusplus) ++ } /* end of extern "C" */ ++ #endif /* cplusplus */ ++ ++ #define ZPixmap 1 /* not really used */ ++ #define XYBitmap 1 /* not really used */ ++ ++ #ifndef True ++ #define True 1 ++ #define False 0 ++ #endif ++ #ifndef Bool ++ typedef BOOL Bool; /* take MSW bool */ ++ #endif ++ /* make these local here, simx.c gets the same from xpm.h */ ++ #undef LFUNC ++ #undef FUNC ++ ++ #endif /* def FOR_MSW */ ++ ++ #endif /* _SIMX_H */ +*** ../vim-7.3.638/src/xpm/include/xpm.h 1970-01-01 01:00:00.000000000 +0100 +--- src/xpm/include/xpm.h 1998-03-19 23:51:00.000000000 +0100 +*************** +*** 0 **** +--- 1,501 ---- ++ /* ++ * Copyright (C) 1989-95 GROUPE BULL ++ * ++ * Permission is hereby granted, free of charge, to any person obtaining a copy ++ * of this software and associated documentation files (the "Software"), to ++ * deal in the Software without restriction, including without limitation the ++ * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or ++ * sell copies of the Software, and to permit persons to whom the Software is ++ * furnished to do so, subject to the following conditions: ++ * ++ * The above copyright notice and this permission notice shall be included in ++ * all copies or substantial portions of the Software. ++ * ++ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR ++ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, ++ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL ++ * GROUPE BULL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN ++ * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN ++ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ++ * ++ * Except as contained in this notice, the name of GROUPE BULL shall not be ++ * used in advertising or otherwise to promote the sale, use or other dealings ++ * in this Software without prior written authorization from GROUPE BULL. ++ */ ++ ++ /*****************************************************************************\ ++ * xpm.h: * ++ * * ++ * XPM library * ++ * Include file * ++ * * ++ * Developed by Arnaud Le Hors * ++ \*****************************************************************************/ ++ ++ /* ++ * The code related to FOR_MSW has been added by ++ * HeDu (hedu@cul-ipn.uni-kiel.de) 4/94 ++ */ ++ ++ /* ++ * The code related to AMIGA has been added by ++ * Lorens Younes (d93-hyo@nada.kth.se) 4/96 ++ */ ++ ++ #ifndef XPM_h ++ #define XPM_h ++ ++ /* ++ * first some identification numbers: ++ * the version and revision numbers are determined with the following rule: ++ * SO Major number = LIB minor version number. ++ * SO Minor number = LIB sub-minor version number. ++ * e.g: Xpm version 3.2f ++ * we forget the 3 which is the format number, 2 gives 2, and f gives 6. ++ * thus we have XpmVersion = 2 and XpmRevision = 6 ++ * which gives SOXPMLIBREV = 2.6 ++ * ++ * Then the XpmIncludeVersion number is built from these numbers. ++ */ ++ #define XpmFormat 3 ++ #define XpmVersion 4 ++ #define XpmRevision 11 ++ #define XpmIncludeVersion ((XpmFormat * 100 + XpmVersion) * 100 + XpmRevision) ++ ++ #ifndef XPM_NUMBERS ++ ++ #ifdef FOR_MSW ++ # define SYSV /* uses memcpy string.h etc. */ ++ # include ++ # include "simx.h" /* defines some X stuff using MSW types */ ++ #define NEED_STRCASECMP /* at least for MSVC++ */ ++ #else /* FOR_MSW */ ++ # ifdef AMIGA ++ # include "amigax.h" ++ # else /* not AMIGA */ ++ # include ++ # include ++ # endif /* not AMIGA */ ++ #endif /* FOR_MSW */ ++ ++ /* let's define Pixel if it is not done yet */ ++ #if ! defined(_XtIntrinsic_h) && ! defined(PIXEL_ALREADY_TYPEDEFED) ++ typedef unsigned long Pixel; /* Index into colormap */ ++ # define PIXEL_ALREADY_TYPEDEFED ++ #endif ++ ++ /* make sure we know whether function prototypes are needed or not */ ++ #ifndef NeedFunctionPrototypes ++ # if defined(__STDC__) || defined(__cplusplus) || defined(c_plusplus) ++ # define NeedFunctionPrototypes 1 ++ # else ++ # define NeedFunctionPrototypes 0 ++ # endif ++ #endif ++ ++ ++ /* Return ErrorStatus codes: ++ * null if full success ++ * positive if partial success ++ * negative if failure ++ */ ++ ++ #define XpmColorError 1 ++ #define XpmSuccess 0 ++ #define XpmOpenFailed -1 ++ #define XpmFileInvalid -2 ++ #define XpmNoMemory -3 ++ #define XpmColorFailed -4 ++ ++ typedef struct { ++ char *name; /* Symbolic color name */ ++ char *value; /* Color value */ ++ Pixel pixel; /* Color pixel */ ++ } XpmColorSymbol; ++ ++ typedef struct { ++ char *name; /* name of the extension */ ++ unsigned int nlines; /* number of lines in this extension */ ++ char **lines; /* pointer to the extension array of strings */ ++ } XpmExtension; ++ ++ typedef struct { ++ char *string; /* characters string */ ++ char *symbolic; /* symbolic name */ ++ char *m_color; /* monochrom default */ ++ char *g4_color; /* 4 level grayscale default */ ++ char *g_color; /* other level grayscale default */ ++ char *c_color; /* color default */ ++ } XpmColor; ++ ++ typedef struct { ++ unsigned int width; /* image width */ ++ unsigned int height; /* image height */ ++ unsigned int cpp; /* number of characters per pixel */ ++ unsigned int ncolors; /* number of colors */ ++ XpmColor *colorTable; /* list of related colors */ ++ unsigned int *data; /* image data */ ++ } XpmImage; ++ ++ typedef struct { ++ unsigned long valuemask; /* Specifies which attributes are defined */ ++ char *hints_cmt; /* Comment of the hints section */ ++ char *colors_cmt; /* Comment of the colors section */ ++ char *pixels_cmt; /* Comment of the pixels section */ ++ unsigned int x_hotspot; /* Returns the x hotspot's coordinate */ ++ unsigned int y_hotspot; /* Returns the y hotspot's coordinate */ ++ unsigned int nextensions; /* number of extensions */ ++ XpmExtension *extensions; /* pointer to array of extensions */ ++ } XpmInfo; ++ ++ typedef int (*XpmAllocColorFunc)( ++ #if NeedFunctionPrototypes ++ Display* /* display */, ++ Colormap /* colormap */, ++ char* /* colorname */, ++ XColor* /* xcolor */, ++ void* /* closure */ ++ #endif ++ ); ++ ++ typedef int (*XpmFreeColorsFunc)( ++ #if NeedFunctionPrototypes ++ Display* /* display */, ++ Colormap /* colormap */, ++ Pixel* /* pixels */, ++ int /* npixels */, ++ void* /* closure */ ++ #endif ++ ); ++ ++ typedef struct { ++ unsigned long valuemask; /* Specifies which attributes are ++ defined */ ++ ++ Visual *visual; /* Specifies the visual to use */ ++ Colormap colormap; /* Specifies the colormap to use */ ++ unsigned int depth; /* Specifies the depth */ ++ unsigned int width; /* Returns the width of the created ++ pixmap */ ++ unsigned int height; /* Returns the height of the created ++ pixmap */ ++ unsigned int x_hotspot; /* Returns the x hotspot's ++ coordinate */ ++ unsigned int y_hotspot; /* Returns the y hotspot's ++ coordinate */ ++ unsigned int cpp; /* Specifies the number of char per ++ pixel */ ++ Pixel *pixels; /* List of used color pixels */ ++ unsigned int npixels; /* Number of used pixels */ ++ XpmColorSymbol *colorsymbols; /* List of color symbols to override */ ++ unsigned int numsymbols; /* Number of symbols */ ++ char *rgb_fname; /* RGB text file name */ ++ unsigned int nextensions; /* Number of extensions */ ++ XpmExtension *extensions; /* List of extensions */ ++ ++ unsigned int ncolors; /* Number of colors */ ++ XpmColor *colorTable; /* List of colors */ ++ /* 3.2 backward compatibility code */ ++ char *hints_cmt; /* Comment of the hints section */ ++ char *colors_cmt; /* Comment of the colors section */ ++ char *pixels_cmt; /* Comment of the pixels section */ ++ /* end 3.2 bc */ ++ unsigned int mask_pixel; /* Color table index of transparent ++ color */ ++ ++ /* Color Allocation Directives */ ++ Bool exactColors; /* Only use exact colors for visual */ ++ unsigned int closeness; /* Allowable RGB deviation */ ++ unsigned int red_closeness; /* Allowable red deviation */ ++ unsigned int green_closeness; /* Allowable green deviation */ ++ unsigned int blue_closeness; /* Allowable blue deviation */ ++ int color_key; /* Use colors from this color set */ ++ ++ Pixel *alloc_pixels; /* Returns the list of alloc'ed color ++ pixels */ ++ int nalloc_pixels; /* Returns the number of alloc'ed ++ color pixels */ ++ ++ Bool alloc_close_colors; /* Specify whether close colors should ++ be allocated using XAllocColor ++ or not */ ++ int bitmap_format; /* Specify the format of 1bit depth ++ images: ZPixmap or XYBitmap */ ++ ++ /* Color functions */ ++ XpmAllocColorFunc alloc_color; /* Application color allocator */ ++ XpmFreeColorsFunc free_colors; /* Application color de-allocator */ ++ void *color_closure; /* Application private data to pass to ++ alloc_color and free_colors */ ++ ++ } XpmAttributes; ++ ++ /* XpmAttributes value masks bits */ ++ #define XpmVisual (1L<<0) ++ #define XpmColormap (1L<<1) ++ #define XpmDepth (1L<<2) ++ #define XpmSize (1L<<3) /* width & height */ ++ #define XpmHotspot (1L<<4) /* x_hotspot & y_hotspot */ ++ #define XpmCharsPerPixel (1L<<5) ++ #define XpmColorSymbols (1L<<6) ++ #define XpmRgbFilename (1L<<7) ++ /* 3.2 backward compatibility code */ ++ #define XpmInfos (1L<<8) ++ #define XpmReturnInfos XpmInfos ++ /* end 3.2 bc */ ++ #define XpmReturnPixels (1L<<9) ++ #define XpmExtensions (1L<<10) ++ #define XpmReturnExtensions XpmExtensions ++ ++ #define XpmExactColors (1L<<11) ++ #define XpmCloseness (1L<<12) ++ #define XpmRGBCloseness (1L<<13) ++ #define XpmColorKey (1L<<14) ++ ++ #define XpmColorTable (1L<<15) ++ #define XpmReturnColorTable XpmColorTable ++ ++ #define XpmReturnAllocPixels (1L<<16) ++ #define XpmAllocCloseColors (1L<<17) ++ #define XpmBitmapFormat (1L<<18) ++ ++ #define XpmAllocColor (1L<<19) ++ #define XpmFreeColors (1L<<20) ++ #define XpmColorClosure (1L<<21) ++ ++ ++ /* XpmInfo value masks bits */ ++ #define XpmComments XpmInfos ++ #define XpmReturnComments XpmComments ++ ++ /* XpmAttributes mask_pixel value when there is no mask */ ++ #ifndef FOR_MSW ++ #define XpmUndefPixel 0x80000000 ++ #else ++ /* int is only 16 bit for MSW */ ++ #define XpmUndefPixel 0x8000 ++ #endif ++ ++ /* ++ * color keys for visual type, they must fit along with the number key of ++ * each related element in xpmColorKeys[] defined in XpmI.h ++ */ ++ #define XPM_MONO 2 ++ #define XPM_GREY4 3 ++ #define XPM_GRAY4 3 ++ #define XPM_GREY 4 ++ #define XPM_GRAY 4 ++ #define XPM_COLOR 5 ++ ++ ++ /* macros for forward declarations of functions with prototypes */ ++ #if NeedFunctionPrototypes ++ #define FUNC(f, t, p) extern t f p ++ #define LFUNC(f, t, p) static t f p ++ #else ++ #define FUNC(f, t, p) extern t f() ++ #define LFUNC(f, t, p) static t f() ++ #endif ++ ++ ++ /* ++ * functions declarations ++ */ ++ ++ #ifdef __cplusplus ++ extern "C" { ++ #endif ++ ++ /* FOR_MSW, all ..Pixmap.. are excluded, only the ..XImage.. are used */ ++ /* Same for Amiga! */ ++ ++ #if !defined(FOR_MSW) && !defined(AMIGA) ++ FUNC(XpmCreatePixmapFromData, int, (Display *display, ++ Drawable d, ++ char **data, ++ Pixmap *pixmap_return, ++ Pixmap *shapemask_return, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmCreateDataFromPixmap, int, (Display *display, ++ char ***data_return, ++ Pixmap pixmap, ++ Pixmap shapemask, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmReadFileToPixmap, int, (Display *display, ++ Drawable d, ++ char *filename, ++ Pixmap *pixmap_return, ++ Pixmap *shapemask_return, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmWriteFileFromPixmap, int, (Display *display, ++ char *filename, ++ Pixmap pixmap, ++ Pixmap shapemask, ++ XpmAttributes *attributes)); ++ #endif ++ ++ FUNC(XpmCreateImageFromData, int, (Display *display, ++ char **data, ++ XImage **image_return, ++ XImage **shapemask_return, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmCreateDataFromImage, int, (Display *display, ++ char ***data_return, ++ XImage *image, ++ XImage *shapeimage, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmReadFileToImage, int, (Display *display, ++ char *filename, ++ XImage **image_return, ++ XImage **shapeimage_return, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmWriteFileFromImage, int, (Display *display, ++ char *filename, ++ XImage *image, ++ XImage *shapeimage, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmCreateImageFromBuffer, int, (Display *display, ++ char *buffer, ++ XImage **image_return, ++ XImage **shapemask_return, ++ XpmAttributes *attributes)); ++ #if !defined(FOR_MSW) && !defined(AMIGA) ++ FUNC(XpmCreatePixmapFromBuffer, int, (Display *display, ++ Drawable d, ++ char *buffer, ++ Pixmap *pixmap_return, ++ Pixmap *shapemask_return, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmCreateBufferFromImage, int, (Display *display, ++ char **buffer_return, ++ XImage *image, ++ XImage *shapeimage, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmCreateBufferFromPixmap, int, (Display *display, ++ char **buffer_return, ++ Pixmap pixmap, ++ Pixmap shapemask, ++ XpmAttributes *attributes)); ++ #endif ++ FUNC(XpmReadFileToBuffer, int, (char *filename, char **buffer_return)); ++ FUNC(XpmWriteFileFromBuffer, int, (char *filename, char *buffer)); ++ ++ FUNC(XpmReadFileToData, int, (char *filename, char ***data_return)); ++ FUNC(XpmWriteFileFromData, int, (char *filename, char **data)); ++ ++ FUNC(XpmAttributesSize, int, ()); ++ FUNC(XpmFreeAttributes, void, (XpmAttributes *attributes)); ++ FUNC(XpmFreeExtensions, void, (XpmExtension *extensions, ++ int nextensions)); ++ ++ FUNC(XpmFreeXpmImage, void, (XpmImage *image)); ++ FUNC(XpmFreeXpmInfo, void, (XpmInfo *info)); ++ FUNC(XpmGetErrorString, char *, (int errcode)); ++ FUNC(XpmLibraryVersion, int, ()); ++ ++ /* XpmImage functions */ ++ FUNC(XpmReadFileToXpmImage, int, (char *filename, ++ XpmImage *image, ++ XpmInfo *info)); ++ ++ FUNC(XpmWriteFileFromXpmImage, int, (char *filename, ++ XpmImage *image, ++ XpmInfo *info)); ++ #if !defined(FOR_MSW) && !defined(AMIGA) ++ FUNC(XpmCreatePixmapFromXpmImage, int, (Display *display, ++ Drawable d, ++ XpmImage *image, ++ Pixmap *pixmap_return, ++ Pixmap *shapemask_return, ++ XpmAttributes *attributes)); ++ #endif ++ FUNC(XpmCreateImageFromXpmImage, int, (Display *display, ++ XpmImage *image, ++ XImage **image_return, ++ XImage **shapeimage_return, ++ XpmAttributes *attributes)); ++ ++ FUNC(XpmCreateXpmImageFromImage, int, (Display *display, ++ XImage *image, ++ XImage *shapeimage, ++ XpmImage *xpmimage, ++ XpmAttributes *attributes)); ++ #if !defined(FOR_MSW) && !defined(AMIGA) ++ FUNC(XpmCreateXpmImageFromPixmap, int, (Display *display, ++ Pixmap pixmap, ++ Pixmap shapemask, ++ XpmImage *xpmimage, ++ XpmAttributes *attributes)); ++ #endif ++ FUNC(XpmCreateDataFromXpmImage, int, (char ***data_return, ++ XpmImage *image, ++ XpmInfo *info)); ++ ++ FUNC(XpmCreateXpmImageFromData, int, (char **data, ++ XpmImage *image, ++ XpmInfo *info)); ++ ++ FUNC(XpmCreateXpmImageFromBuffer, int, (char *buffer, ++ XpmImage *image, ++ XpmInfo *info)); ++ ++ FUNC(XpmCreateBufferFromXpmImage, int, (char **buffer_return, ++ XpmImage *image, ++ XpmInfo *info)); ++ ++ FUNC(XpmGetParseError, int, (char *filename, ++ int *linenum_return, ++ int *charnum_return)); ++ ++ FUNC(XpmFree, void, (void *ptr)); ++ ++ #ifdef __cplusplus ++ } /* for C++ V2.0 */ ++ #endif ++ ++ ++ /* backward compatibility */ ++ ++ /* for version 3.0c */ ++ #define XpmPixmapColorError XpmColorError ++ #define XpmPixmapSuccess XpmSuccess ++ #define XpmPixmapOpenFailed XpmOpenFailed ++ #define XpmPixmapFileInvalid XpmFileInvalid ++ #define XpmPixmapNoMemory XpmNoMemory ++ #define XpmPixmapColorFailed XpmColorFailed ++ ++ #define XpmReadPixmapFile(dpy, d, file, pix, mask, att) \ ++ XpmReadFileToPixmap(dpy, d, file, pix, mask, att) ++ #define XpmWritePixmapFile(dpy, file, pix, mask, att) \ ++ XpmWriteFileFromPixmap(dpy, file, pix, mask, att) ++ ++ /* for version 3.0b */ ++ #define PixmapColorError XpmColorError ++ #define PixmapSuccess XpmSuccess ++ #define PixmapOpenFailed XpmOpenFailed ++ #define PixmapFileInvalid XpmFileInvalid ++ #define PixmapNoMemory XpmNoMemory ++ #define PixmapColorFailed XpmColorFailed ++ ++ #define ColorSymbol XpmColorSymbol ++ ++ #define XReadPixmapFile(dpy, d, file, pix, mask, att) \ ++ XpmReadFileToPixmap(dpy, d, file, pix, mask, att) ++ #define XWritePixmapFile(dpy, file, pix, mask, att) \ ++ XpmWriteFileFromPixmap(dpy, file, pix, mask, att) ++ #define XCreatePixmapFromData(dpy, d, data, pix, mask, att) \ ++ XpmCreatePixmapFromData(dpy, d, data, pix, mask, att) ++ #define XCreateDataFromPixmap(dpy, data, pix, mask, att) \ ++ XpmCreateDataFromPixmap(dpy, data, pix, mask, att) ++ ++ #endif /* XPM_NUMBERS */ ++ #endif +*** ../vim-7.3.638/src/Make_mvc.mak 2012-08-02 21:48:20.000000000 +0200 +--- src/Make_mvc.mak 2012-08-29 13:46:05.000000000 +0200 +*************** +*** 89,94 **** +--- 89,96 ---- + # Netbeans Support: NETBEANS=[yes or no] (default is yes if GUI is yes) + # + # XPM Image Support: XPM=[path to XPM directory] ++ # Default is "xpm", using the files included in the distribution. ++ # Use "no" to disable this feature. + # + # Optimization: OPTIMIZE=[SPACE, SPEED, MAXSPEED] (default is MAXSPEED) + # +*************** +*** 279,295 **** + NETBEANS_LIB = WSock32.lib + !endif + +! !ifdef XPM + # XPM - Include support for XPM signs +! # You need to download or build xpm.lib somehow. +! # You can get the most recent version of libXpm-*.zip from +! # http://cgit.freedesktop.org/xorg/lib/libXpm +! # from which you must build xpm.lib yourself +! # OR get and unpack: ftp://ftp.vim.org/pub/vim/pcextra/xpm.zip + XPM_OBJ = $(OBJDIR)/xpm_w32.obj + XPM_DEFS = -DFEAT_XPM_W32 + XPM_LIB = $(XPM)\lib\libXpm.lib +! XPM_INC = -I $(XPM)\include + !endif + !endif + +--- 281,301 ---- + NETBEANS_LIB = WSock32.lib + !endif + +! !ifndef XPM +! # XPM is not set, use the included xpm files, depending on the architecture. +! !if ("$(CPU)" == "AMD64") || ("$(CPU)" == "IA64") +! XPM = xpm\x64 +! !else +! XPM = xpm\x86 +! !endif +! !endif +! !if "$(XPM)" != "no" + # XPM - Include support for XPM signs +! # See the xpm directory for more information. + XPM_OBJ = $(OBJDIR)/xpm_w32.obj + XPM_DEFS = -DFEAT_XPM_W32 + XPM_LIB = $(XPM)\lib\libXpm.lib +! XPM_INC = -I $(XPM)\include -I $(XPM)\..\include + !endif + !endif + +*** ../vim-7.3.638/src/bigvim.bat 2010-08-15 21:57:29.000000000 +0200 +--- src/bigvim.bat 2012-08-29 13:46:18.000000000 +0200 +*************** +*** 1,3 **** + :: command to build big Vim with OLE, Perl, Python, Ruby and Tcl +! nmake -f Make_mvc.mak GUI=yes OLE=yes PERL=E:\perl512 DYNAMIC_PERL=yes PERL_VER=512 PYTHON=e:\python27 DYNAMIC_PYTHON=yes PYTHON_VER=27 PYTHON3=e:\python31 DYNAMIC_PYTHON3=yes PYTHON3_VER=31 RUBY=e:\ruby191 DYNAMIC_RUBY=yes RUBY_VER=191 RUBY_VER_LONG=1.9.1 TCL=e:\tcl DYNAMIC_TCL=yes %1 IME=yes CSCOPE=yes XPM=e:\xpm + +--- 1,5 ---- + :: command to build big Vim with OLE, Perl, Python, Ruby and Tcl +! SET VCDIR="C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\bin\" +! SET TOOLDIR=E:\ +! %VCDIR%nmake -f Make_mvc.mak GUI=yes OLE=yes PERL=E:\perl514 DYNAMIC_PERL=yes PERL_VER=514 PYTHON=%TOOLDIR%python27 DYNAMIC_PYTHON=yes PYTHON_VER=27 PYTHON3=%TOOLDIR%python32 DYNAMIC_PYTHON3=yes PYTHON3_VER=32 RUBY=%TOOLDIR%ruby192 DYNAMIC_RUBY=yes RUBY_VER=192 RUBY_VER_LONG=1.9.2 TCL=%TOOLDIR%tcl TCL_VER=85 TCL_VER_LONG=8.5 DYNAMIC_TCL=yes %1 IME=yes CSCOPE=yes + +*** ../vim-7.3.638/src/bigvim64.bat 2012-08-29 14:16:38.000000000 +0200 +--- src/bigvim64.bat 2012-08-29 13:46:35.000000000 +0200 +*************** +*** 0 **** +--- 1,6 ---- ++ :: command to build big Vim 64 bit with OLE, Perl, Python, Ruby and Tcl ++ :: First run: %VCDIR%\vcvarsall.bat x86_amd64 ++ SET VCDIR="C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\" ++ SET TOOLDIR=E:\ ++ %VCDIR%\bin\nmake -f Make_mvc.mak CPU=AMD64 GUI=yes OLE=yes PERL=E:\perl514 DYNAMIC_PERL=yes PERL_VER=514 PYTHON=%TOOLDIR%python27 DYNAMIC_PYTHON=yes PYTHON_VER=27 PYTHON3=%TOOLDIR%python32 DYNAMIC_PYTHON3=yes PYTHON3_VER=32 RUBY=%TOOLDIR%ruby192 DYNAMIC_RUBY=yes RUBY_VER=192 RUBY_VER_LONG=1.9.2 TCL=%TOOLDIR%tcl TCL_VER=85 TCL_VER_LONG=8.5 DYNAMIC_TCL=yes %1 IME=yes CSCOPE=yes ++ +*** ../vim-7.3.638/Filelist 2012-07-16 17:27:57.000000000 +0200 +--- Filelist 2012-08-29 13:53:52.000000000 +0200 +*************** +*** 349,354 **** +--- 349,360 ---- + src/vim*.ico \ + src/vim.tlb \ + src/vimtbar.lib \ ++ src/xpm/COPYRIGHT \ ++ src/xpm/README.txt \ ++ src/xpm/include/*.h \ ++ src/xpm/x64/lib/libXpm.lib \ ++ src/xpm/x86/lib/libXpm.a \ ++ src/xpm/x86/lib/libXpm.lib \ + src/vimtbar.dll \ + nsis/icons/*.bmp \ + nsis/icons/*.ico \ +*** ../vim-7.3.638/src/version.c 2012-08-29 14:17:51.000000000 +0200 +--- src/version.c 2012-08-29 14:14:19.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 639, + /**/ + +-- +A successful man is one who makes more money than his wife can spend. +A successful woman is one who can find such a man. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6baa4a8fb168772b6fe2da3e10efabe07b129890 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:35:42 +0200 Subject: [PATCH 0475/3340] - patchlevel 640 --- 7.3.640 | Bin 0 -> 455297 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 7.3.640 diff --git a/7.3.640 b/7.3.640 new file mode 100644 index 0000000000000000000000000000000000000000..984df6400779e68332e9e016d04f19445b940e0b GIT binary patch literal 455297 zcmeEvi+2=7_J2)gfB(W(>m%0&JCt@|e{8mgr=}+-tF`)?C0nXv({*0$WHLQE zQLgPz?i?MfOeJ?#Yob?r2i7E4ZK>3DRrV+IyQ{Uzo?kA>0A%B06g*WMeqi6^_yha; z`yLn@-GTqxCdb!|jqbS5PutKROe^2FB#atP9vj`UWXY0ZX{)g@xpjACs*)_%D#;yz z%H5Z&?;f2>j+giIChx7*p5pbb?5WiD@2HOK2f*}H(poY(T~F3`SH_d06UlONsxn!w zmFtz{BnExWk|j&-z4zYanl%sX86Cf$lR)pl1MM5MxMyH}_x;^H_jmUsyL&cvcW>&M0dFO-W+VJj&maI-bfYAtqp5DH70~Thr+2J4g`_Wnwi~jtJ7a)GWdXU7zKOLRv|IGhQ z>@*QSnMuO`J5LbrKRw0{kXFB6Vb$yi|6#At1LTswgM&kwGSuBuEM+WJ)6>e{!IY{h zM8>bx^IG1rin=nG(lS%wG*i=aj#bPlgMGgZrSzs9-Abz&3s~A<_h5fGIh!uohHff@ zeY<`iPRV6-$IfSR%3#VY4yJTFidrhAjZ!Wvb8f0rpQRN_j#|pg`bLZHPiLKCNjFN0 zNYXT!2Oa|L?zarPl+70`WpKTKSl3)wf39d1bC#}%#1Z#TFr)Q)Ni%XKEvF3j45qZa zTU>syC(^X_1*cHbONONkuG{7mjBQ&(8KqUl)Url4Thf)`>iA@>GBt$)^%5_(O*=GA z$*LKrpk@kg1&}#M;Z>Nbm+Pa$gX^#jkg;w{GxlIAQ^c#ze@)vX3tK7bRwk|GRAqF$ zysI)aQ68^^s#{bXyJY5yrIMh5l;-yjFQ8>_m6Wt*7)3o>@Ww}WgXl=A!!R7*cFAFVgirqHZ zCP6RP%kDJl(d@id$mKOoDgip{$(GEFW0msCc&Ph&az-wnR}LUV=6;@?>aPDsSQnz?yHQ6a`sJ*YsfcW**}FB2m4zd z@AZ+VBD3rdDxly^Tj9f^73!L$>{T zx>DOOTehP*Ju#x~t_(jlI@xqw1QW z<~3z=Wh9i+r>Xgp3HF>Gn+}t4Usg|Bs#+{4yK0sFVJy?h>t?!?R;DJZ;RUnL(u$g< zWpqW`AE`y3rRP=6E@c&GbmFOShWSiUwM^AevbA!gtU|7kFP3s?WwKJ64r4iL+H_1c zr(~;Rk#;#+#?;k;=xQc!IccR>-V-isU0ThUc`KXY)z}a!Y+c&P7IjNC zl=N76I9&a8THeU01uLhhzn`v!yK$Y7)$_TWUR2Vx>fZ3UtTRf6?wAEjNmoX9MewrO zl9h8DbV;QW!Lv$5!^)IwUeB;_u`Xv6ayd=(x~E!;3|}d4TZUS4INsVYo|7(^PC?Hq`Q7EGMk8rD z$T?r)c)gJ{%g7t5VJnaBu9U;9e4S(GExTx1%A>nS>*3++*VIBTqgx`+{xB`|YiZTi zbGGQT_0dGla!SRb$!oJNny4E^%Pgrpu`imKv9d-+6=cy9P0XrVE-h)hH=1Y`RL9O} zqUWNC`HX3nEJ0EmqKS4clQwLfV-7?Tbvw~66((yW~rzdMP+ijHaQldAxqQLyk0bw-&DrN zB8;}*%9b=eZHXS*5T1GcmZ_;3+ZH`E5KYYKx|&x7f%QZa^R`(m$@$zHO|;F7ZDa&d zuZ<=a%tE?giNWrVCKm0InYG1Wua72{^n6|`3c6hvO>`WqV3h5C-hRL#!XR8tf>_Xf)e_piP@6wFho3rFAFpI+m5jnFKmveI&7< z+PO?g6MfqkULgAmY17t?wCIF&(L~L0N~$S%!un{Ut{1JmAv&QynrP^TrsYH@tc@mS zoUCEF3wAUyYihYdLA0|cnrLOy1uWTou%n5&yq-4=LDU-}iAB}couXkW_3C)JUJXeJ zNVIZURdoD@u;|fWOq+S9po^vqL=&y7s%A2R`qo7gb9pW6WCh*!MHBN{*0!b0+#gM} zOGYuR3nsNbnpiM0W>(E9g>tPLGuf1#?Xrj49qDO*M>6BFg|V3&#+r{JifZ+oJcrJ|j-rR>@pO?1*ZGo2CR zxi*sMsQIFr$!C>PZFu)+ct6wcsD+%RIfAIyhh^!0C#~8gs~{$Ce>73E9KDbi)YlhH z)Qw^$n-g@qE}Ccw8l(_+ZhMib3~s^z8N-y2QLXUx3gh)x)YCfd17 zAyW|3VM91^Js4EBm{Ii6aZKOPsI1q`Tqd7OrxmkWZ`xq4H?nz6wx+(QTj_$OY~4LNRgVa1>z!OKoiS`jDUFTT<>9ahx85n{>{2#c zQnoy`ziErTA)PO3MboyG-PMW8{*g*}FTFuGv{KGaE5p^=#MJ0mc+#8zd9Ud-EjfMr5fwZM+R!%D@db##g^L}g~?WnqH zmNaE}cXhZrR*vkg1~k>mTWa1`Y#gsOHGM!!JC>D8mqdEgLBxQTRUIQ=)D*2eQmHrf z&46xX^jtBkDqB!?6R8atre@$oIWtAZ*HBH)ild4<`lcUccOXl z1}sM_mhz<%ADtHIIn!2)YT8kDOxMQt@2ytDtZE=t8U6Iirv*C|l~4%2zVTPSkN`7C!$O zC|KEi32XJP^613Wj%qEumJbv)E1OY^mST^Nx2k_JU(7hRl~XoX_m^9gU(!o?tB@@! z>e%RTi~5(cSzXOQQmu}SR3>WC{ww7*&B*7nic={M?{=nl?hN;jqo-BJkn&#>@i=)S z?_kZ_I$e8ux;i=)W=I20$#OJRPb-DdsrvrS)ku0;RWg=VvP+IqsEmwGkBd!fw3xK2 zSVlITGn|5iYu%W%s^l!g%4V~cglk=`w5k+!&2chLUc&LI*EG24v{H1^>5`du>!&_F zT^=vjqKEKlO))e(ZE2=k!A!MQnW{I_V_H+}f^C^OO?8W&tc_0WY5|#1?5vS9oKjxS zO?LoW?9XjQGmEOBY9$57^z~Y0I?~m)Vx(0|%Voq&Ya!3uN>*1b&DITBv!?z4gp)N2 zPLa>n7P~`RvGSRcnJF5IQ{6jKskO+%%A47Oo=z)mI@4Ax$JTATkXQ8T$gY-o6~6t6{kE|-d}!n_vmDZux%yh=(eR>4sT0~(-K?BXRJaYS4u0{ z-PNgj^Rb()6t%3L%jb9&Ed(hJP{9jI`jv1tpy?q@9wHRx)GgisqUY6g^uqjf`2~>vt>hprGglQ*$)KQn)(eWVu$E z2%jGnl&of&cD4wCsZyC}L5Kwn$z>90WsFW02FX755FFFauHT6JADH-`}HeD3bW4qRstdgOr z1w*l=c$*%Zo(kXcmK4XboSbf0ytvj~;3#R;&KI*ecl~PFJV!}8#gdgXGJ@|wuxXw{ zj-uN|!^r20lKNXV&{2$%re-y(AfZ}HIgXOGGr5vk%Hlq1Vt99DM8(Nqc$6I_i(7Zw z6_s1}mZR9EeBRbAcUHC>XGbY%g}iBMDz1noc8*o|1{Z>TljFFd-Mni@u{>VkSIOB* zeRDRwvsN8P6d({I0PwcCQXcW(g;GA9bqYmgdLp1SGSC`ro2U}>9ky0IZ3om+M7cMwVL*PD9zvDZz7qX=e@d_#S=#E;swqI)MgCxrJ>h!3Kg#Mn` zSw*}xFXjNV4sTn=s&zo(d24wGbX_W( zJiQ1M?v7@+R&)4ZWEh2?_giwQ-kYLp%&{|#W8bPOU-7Klr;jleUsyZ zeN)gM>)yk$*7ppq>lql>Fxb=GJJ{1RFt{$D?@`i<`J8HKN(;?1-o|~CTy+YTDlQk* z#yN#%D|I<{_Dzl#EBhjE4_j{hqt)67p1HD&St*Y|X~)$ck;*hxp`hhOyUY!0B`!+~ z==LDmRsV5w3Zg{Qyi!~suRh3Jofr{$BX+7@8!k^(hQ}w}Nj6Y4^QP(Os;htHYQF_& zprB+5S)-)eMUbtpPS--Y&Z{tr_SI&ZqP?n0&aLGYC#RW?Q7F1o>hj8iu0CKuV@LE& zi-P?Gujp-)<7&NL8{IKouS{(j{XJi7z>)k|z#t~9w}lwa$T<%~zk+QAu=Y)YR|X<} zh>c3mhQ1!pM&)`!2z_~o5cV-WMhJbD{*90c_BTQl_8KAdI6F@Wef72&VXx9N_+|4k zGR9tt5q6lp86#`iM?CglG4de$Dn`|L0DGl_ zOvec6B5~5i|KV?(bdorU@#h%n;{Wl!h{WXkBGN?`$zR0dUBoQpZ-}|le**tXpiwi_ z;c~E-hqzo0DCfuiLoGzF#AWZfIsWk6uakNBIdlekBu&h%Az4bUC)bm! z$yH=2SqefWi%BQxBni^NsZZnuD!o2Hh1bY`0@J1BI9V>~c@epuT*dQT?((8`az|Um z+MiM&X{V&yUQlVPzuQK!haMlZjuzV9Ukq)RFDUs8B#tLc9Uv8t`=@#U-o+N*K? z2)lvH%6OMCENHJndI{<9hbfm{LZ-Z=-svR`AAX=->JJxUf1pZhdllrLwOzT+MtE!T zv$pGhhqmjLnic)56+6`ZvsNrR;fHI*UhZ_@(xyF^)~US`tGAyOZ-=`7PbuDB-iopR zXXV_X?*5;ZbBDV7e^$;N>hAxqQ_j7V!RF7JyBM;cHFt-)f7aYZC;We=xqIaf1TL-P z`_tVST}EB_$JvKp#tp)Mt1|MXt=fOqRsLC5`Db0_7P`X!c3tJmU!?x~^_eg2(c*t! z-}!s%6#Qe^*)idn$jqt^1z(Am2+T{NLn_=tt@)$d>;| z&6a5NddC~g+Oc(!(HIn3%`@g8Ye^~|9pB4Ontb+f4 z%(vVXX%b(l11m}M|JSV(u0XN+dpYeZU0!3<>)HSNmJwH^kbZ^s6W_-dqU_?I*6QMt zit}EHKY?w=f1|^`mWr-IDcDzw6>9sQqOPA1)Rz@VSE}3VW#(xpi(FeIv{8d@F58W{ zoRV}n!yuN|P;Pu66?_A_y3H!TGRDm$_zs(iE3vm|Wwa8CbL;Dyz? zH5Bb;8jAGt4aIs{|0wT{QHPkQfTvyGtTv4p&nijSEcyEPm$YXJ>F57oLz9-8+phhK zYsTWfOY@j3HU^O1GF{sMJ{G~3kYYYJ9|&ui2Q3O*Jn1YnYS7iBZ!RL-DhKU$Jj0)` zHNcY9$wzCMOwC$T-SMROoPzfe1)+uRg`V#2{{H@CvS;l&{7EMHM-)cr;fDzO>&lJJ zuWu!UJx@efGg7Mz*Y{N9EBPHEgv~B?Uu9UbI=PIj8L8};-j&+oMotn!?&P0m2nK~L zORvF4MFNp*2HNp2a@eg)MZzLNNOGC;#G1(wILGzERRDc$DIxSj2^lAZD9gH)HT%Ml z%Xn3n62gv0AzS3hz5wKfC}bqh6d~lcs|Zn04MO~~TjcooRfIelg^T3JTXR$bxq&yP z7H&)e%|3nwfao{+>JHdOJT z1ad>GMk53I<`n=g0N^{V03&Uo?*Q_HYX~vAM9B*;(HMHLix4_5A=@oqHvM?FwDCoj2l|@IJ$7E2~JU>6Cg6AN1Ff@B|0(>fy!Q9hS_?ps3E$j9S3-FIU#$N3%GXU!pZFTazf~55;Ep; zipboDJ^vwdUU4LWJ&=+ndguWexY(YNsyPGj`H3Y@yXG#N{tX=&_nD%7oDYN2q6!vTTME{POUQO z-1d}W(z$xdH0j(kDaWRBW2tR6Vv;s(uy<`bzYhIk(gr(W&<6Xs>kfJVF$LO4q)a-` zIS7*H@ij0)EIPkE)oIZNyFf2MD6wf{X@MSMbM@smZ7gbmg4!JE#P1CM{by{Nz1jlK zqBCr^8^52%rs>-@ZHQ`)rM8*0@l47w5o4OP!J9S1W>=}(f5*OLGY{~NCL}?!gpj-W zQwgNQpC$+)ckrh@UL0*e%;k~vuU;%W2o?fS-3?$qaZZNf39JKrCQj~@AnwACQTJiQ z6J!!hwYXRWk-HmOWsHR)PVT%JyM&wB`w6lFa(!1F?@LxEM;4O>eW(EO3dIBzIiW4$ z35^zo1|bnzl_?-&%i?5N`YLu{$?Bv-$X)lL$i*wCk}IdkT`Q-EPUq}Y(!_7)mWS1? z>ci@zoX8ZA(LZQ|{Y3={>9oNIx$^qmV6O=lAtxD&!>^tNz ztEfZj@6_$TdyLI+Qr*W%bpt2TZksmfS1I}`hUGB1%cS#@F?xu-Uf)L>fN#(@QZP0q zCY{q$$*wzeLCY5~BR;JU6ljBez+-76jtU$CDZgOS`4x&8XD?Z_v4XuU>SxA9jb;)c z!Beqm_Bw6QQz?2>Q29t|k{w=zI`BDxtdC$GJjV`aV?^dbXU0;=*ff2Mo$L%$PgJLm zHrRJS`E=*bt~=-~9~4=!BdFN(?JD*SpFIiueu|2*!wXwhB;!^DrM%$vdp*_7XV3;d zgZA~Z1JSO(pAgb7ro;P$5HN)VVMhoded6(DZ<4Htx#_E8g!J&_jWKt!rDKGw;c*Dq zSh?XB-c%A#pkx#qC$ZmLMSjEHUr4sr7m?CP7rCLfoPD;89lM4dxXM}Dy>g1IoZ=*D zf`KI;LG4c^(PLlW=LF|}^%`e*-5&jnq!h5Ucl^G#X=9-~en6BwO{a~=FV{d8Xh8AY-OwsyLuA~wkaV%xPB5wZBC?&sl6dEoaTDh+$wy6kke%x8 z;G6<07%_XY*=yhx2f?i7rk8tDn;iggX`So@6Fg^z&9RHU>;UNH4Euuq z(`4VU7fp7NGrqGOps^SKWYKw*T`=WROV2{)Gl$t3E6&caFX@NV0UDXNQ%Scxmu`Y_ zb6Tfhpr+EA)EuI6PO@uu{hsV4u3IWE_P3njoLWU2F*?IOj@6gb8FnT% z-DA>*#o5s8D#1uNje{xvrqdl3PO+QVt95WU)^MX6+W`mpiOpdB=d2~c*|O;M4TzlM ztyT%)`)xNsgc1UgctWe6;c+f|`5y@i3iM&b6W9x1Pvaa6nY*D?#`yFsB%%c!WI-SD zBVO((*UwWt@l6v}Ys@eo6rpAA0yLJ0kwlt{5ZhCoe1%!YIR*H|GpVE$r@KL>e+OT9 z7oB;QUH~l!$#<#RMbF*YIhCLd_D^=QqnCY(S^9eY8lJFZb#iKvN@w=3BGVnc?6fW2fWG z>No1Nkx%Kgp(R7$UKLKaEVec5r=q&c+E>>=b+58$V=Ma7YlYv`o7&@Az+J|hiU#Yc zgi0GLQe46Vuh20tT!@3n=QZHK^h$b&ovtrKBUhQUu>~@Z+kY(@A~+P^N{B_dQRiEX zXRzJCPDI_#W;TOhKj1R~vs`Q_o!>ziDflG zruY#gFZB-|AOb%#as!?BCb@jXY~%Z+IEmeYy}>Q@rR0_o{xOe5$y$=BDfqVJ4&iRY*e#O7Op1e1?a_X_)C4ZIt z1E7?L9}x@oWTMrA{e*~x95}xBSOtOO&(s6;8+X!UZaUW1!(=FsJk3thbC8#ts;~=Hm=#q3v&YULP$hb- zeWgSt+T?qWzen*3Zc!_C5}SU`^}!vnE8Cu0g-3|Htbrf7#RB_E(iwIl27#&GMQ7OA z*fba9Wv8-}H@IzXw|Kdui2WC~SkDO}@I(xVce9|Dp~rv6W^g($go^tJ;d3}a91QzK zJ_{gG@M)P4)7*WAC?KEtMWKA|!u-K3PLTWjN9=y+cRbd?Bc@M+?8YO6_5`WMTzQ5b zK&)6=>1&>BL7zu7P7&R}AmoUJRzC7M2#WR39*+Dw{;J%9xuM89)$XGt|C0CRY1V(66gaE$ze-@CXG5S17Ovaz+z<>}!Fqx5| zkdIu~Y2y_k+H?v&Ah-J<16~5A{6TESkAcw6*^q8=ZXl%cmxNU0bA##iVr5=o0uV<^ z?5`r#rt^BrVJG7TUm51N@=bGK0kKovU=A`b|NH@rniCzb+K@PoV$bn$!3K%ptSLdZ zgQReVmLR(kD@X$Y$DVFrKJS%}yyHPJaT2?F0lB(w1-Ux5oGhFqgn#;W&FIMDeRPJf zi|itRg7?`N@pueUX*dKgvLV;UV^Ty7gy11J1gdz9pN!!UX%jtOVt*$*djuhxq3|Rs z5I9XnN<0QiL>BZUJHBc#&Mz|&FxUtjiUiNAu`i3qkPbX{guTvAu|q!QN{PwgLM3AF z>6iF0{bU6_=i_aZcpNHJB0n69;r1IP{(^n?%YGjXhlvQ{1TEM=jE-O2>K^*-Gd|jg zMB_lA(x6@-&=Bay^ZxmxenemO5pR`<9E|LQ7g#Su`-0PH40MC=5d9}TzR_(pArHu$02Lk$+ziBH z{0xE+(#g(TN5A#)@)8eF9b~Frn;4$lFN)wbKzK^R$ngo>OW__h9^=dj#J)U3zr)Jq z!v9%5EN|*jehTePS@vFeIlZvl>reWEL==bB!8wc59e>W!_t@XAqVoaFk0mCD3r!;I z{QV*yxWT~1vfC}}pv2=)p%QV0Cx(!7iNCYAe@$NxU}Awq;BcW5ajEB*SQ>n+FM#%? zMB_lA0#&=8)!`;*P6QTOpm5)V*eJluHs#ch3YFJK{z076&*FUqfS1(f|m1n;!ZDd)B8T_O`@K zHPI1P^#C1x-QB0BJUYVi$ODH8(a}9#*8t=O_B=cBxR2N&mr4#5;sX34!ee#iHT1w< zAMGZICT=T&jBXV#POvdTdIle+hkdj)5{(0eO8aHFb>~v_0{h5E)FmPZ3zc^-N5smA zz+N0+hq`>cZ4!?|k)6Y1)hTbO!q5y&2BV^bwVLP6xBvXa{{!~nDErbMt#O(A>ZZZM ze#-AWc;)?M8+&WDH(tM&m>e$D9)9Z+1D8Z_=)2cG?W57>C7!q&3W`41fCog5bM!Sj zn|BEk8hjEHaN$XS3*xxngKyn_-NQZ}o0WKg3gh7*+GoHW>}>w20G?YOpu%{#6^q9p z)gaKnrpA`~c#Gu92B0w7+E6v=MS6jq#eJO1J$@xI0T;&X<(QcLyui6F>_zsLkGM-B z0xZn*alIFh@vSEqC7mrV-Rh6NxZ>xxfShmwl0B{n{o%i#9>4mrK5y*VE3!Zi6&ifp zcllC6ioW}2_OAfqS&7KOLepn`s6hH5dxO2lzVK0R6}L_TE>t9Tzj1HA(l_asV^8~d zzmj+yDpVrBit^Y4J8G_a#77&FXyU#q$R4oA5af+jjh|!s71py->aK-7bVNc!hBs(9#`� zC|>95+?@)q0m9u)F>69GDZ2>)RRmP^=c88*Zb(CPTj+gR| z+-J4%t{XDUD3r&>s>7lR0kZ+wRlTAj!2~e`EfPfMu5E|WA|Wsw!4iVa4aCbPe=kG4 zEA??&Qqr1X6!mODeriM0#Ob*A6$5;)246D3$65H`;M*#0H$@_41H!RGL)k56d17R& zQqy)2}_?)9MfLY|+At_R!F1b;r=o>4{-7G&EHip0177_YVzM zt51zqLNREi8!tbQp>eTC4t!5494ja*8Y_sTyCrNiR=|dHm4gwA+&AglEV;D_$N5

L<0{a4_-@`qUqU%A_@pW3O#wm^r%pw2S_^M<-T zggfl*AzTt@4tVZC*SGX+=g|^05 z1McC346RJBphCsv+r?6hhOpC4skoPUOZvAgvxGgaR*t< zzUb)w58s=hcBtnA^o1MPN4|h9>W*WQ=;jJ3{?3DbOW$E9*)jim07r!g94;hbWBcUq zbhkhLJJ#^gxUM%L0*Ge-{RR3Of)yR79X>;)Jlb0Q<5$TfvD(J6_H{xrPvSTAsSM zXpw$PMcv#}Cb;3HQ6hjMpa z0UX*5)F=G zH{VXklTo-9jiyI$hn;p5GSX~}4E^GEFvTcji#*vofIJn2jO2-0E?J$tgOIy$WfN>q zi#(M(2(hDZksL8NPu@WYJuCsev59o~{Ru+oF+hHYixLQ~m*{djw~`S0H>so0j?&N^ z`sGUKheRP;G>4r4mTWTlcgs8tD zq>MWisi)Fze#KT3ay4#IE>S}a%j(sHY>L9QX!37X6HREarHNwAWU-(or@o#&Ds3=0qVwVhr7bHiD#YJWhba|W+yeKm4_ zIaq|$r*AY>ZW?NS?;CXPo?do4bZ()n zFmKRJmuyhotxg4c>Ffl9vW(HoP8+@K(_VJEmt8dQpU&@$b=`rDbL%dhVP_U~(L)p} zESD@0K(BZ}!HWC6+(l=ffnF-7F7ypMtl#DkXeq-u2AY?10vermlxt0Q(OIEw-C#4; zYS>WC+X)8>^(PjBkYG4vt!B@`S{bU2c&_J>ezvo|z+xBKL3Wa!6&l)yk}*PbI-gzU z(gDhRF<8Sx3wR?MTT{^akCN?Yu>YnFcAlM}AAz3pWMeZK6F(6!#m zEsi4@Q#a$U*vTikaVPo{8u$jCH=qyAskXVc++fK>bzzGc%(cD;#)_xd$!_F#dV0*D z^BGtxw#sSxVV(y+fe8#)T}K{Y1#(u|MRr7`Gwfobi$3=|b^%(Vyny;Ic)ja)ajS{j z(c$%5Oqf@6bGuJIRrQo2UqF>77tk{z2X;|tUW0o@G_S$t)FJh881)W44zpfJr?@3e z5DL?3+_NSKg%yH)gdL=OgxmCdVDsStFdu+@)!`avu=5_kwQ)Ctd*kpN0Q|LaH-F7b-5e)eV<6Xm@3F*X}wQni#H*RcljZXn1$IHZ?R^sSQoyj*;9wQrS5=Q6bX) zL)r4E`mneD(E}|lI2;iRb?##c%=QNR1XO$mixoE`_?(_Yr7(}@`9h|MMNP+w_n=?~ zAo(-G2wWI%baD%Gc4FZIV9wABe1V0P=c&{_UgRA8Dg`qEo6gbqQ@ay{fHS;~(SZ3D zHv^f|xz6|3SWoYh^L&?}jYS(pX}gDRc$J-8X3<7w8SGCE=w0-}Hg?gXbD3p2J$eTskAQEU zj7_t@aHETEc6bpQ%Pw~8N#gH!i9MLo*O@T9P>|?BqxdWgM0{RnNaH(m2nH1E@p+4VK3sc$TMHf$_wZesJ( zx58{i)B?-NA=E)GFS59sA+cP9g~<#%+(~EHw+m|QU@!X=Re(VcJ>u2pCZWX7y+-ho zQDPVUhO3wCq;pwz5w$!d>t#}avcq&X0ooVFVQzJR+RNr#*BD*&bYjWsBnIFhJ*s!H z3&PCjbKX~eD}sF~x;@Z$hwcU^7Q7f$7t5I2N3uGuMe*HkM~GoY#a}S#TtXPv9CIm* zTc()Yj6qsAtY*hNBc3jLI_B1S$?BwMoCLeK`*hgAtwLwabhC@>FrR1La1?T%x`}<= zMQ7+yNUE@F*YW!xJHg&#-=PV7Af}$+gHX@<1Kqw6kjgTA1q-z0FS5>Dv@ut+gI#wh zsI=_rXX#OU8L#x*H2b2LeX7&>Kg0xO>U6#mV<*^WVs+|epRyD5sCaQj1JAIUo)Oh% z7uksgyiG!O2m3Jt@h4mq$r%Ab(u=zboZ}mhReS|)TG!Qs zO6N2!m z0-9LruzwT_oD|x?@x$hFd~Fs|+Yooeg4qBz^Ec5&u(e|+={I~K2_^WG=_Gv*n`9yB z!C(evTnWN$%AntzATVy=H@pdgYcOsRB@F2vX`mz7`JU_jaYK{olO9??uJV8*?dEA{a-C%s9G(w*z zWGfX`HLkH1jv@pOPH)5$#I{E`_5=z-X>Mp$P)-&kf}1hKNxw4U3EF-lV?ZHuH?+zZ zCVg>o=S>UAO}qii(16bG*8l{!MhLCS5jDE`u0>>7j2%YV1^&dY~#m*CXKoRQQUYsn_@@#i}Xfx#(O!H;vSR4sm2M+m!tT36&w{# zk-p#uE^vhO7j}^SqXVZf!jOG~y9~gLUr4Obp!R3eiC;>aZxRn&Tu~%oVn_oMpCIR`s`LAlW~rU;{=JD@de!v;W@i z6}6FdotGarksUVZ+#)$HMA`=)5b!=mGb1@C+xDu0?+{^k{ur1KiP_$vnU_bz&b9Y)9e;Hj+! za@$)rhcU++Hk+08-f9h_JHNR~-O0DeW*7a29mJMb5CyvkR*T83Zer)V=(E_hh<}IG zP3Ylg`5p&xe41TRudow$i1uF*G-nX2q=4idjIk5!B0G9HS|%?lzM%=+i}RFib= zxs3?V&E!sg60uOF^G=MdOLlH*IC(@`rv$X#^yA(7|~_DpoJH?g;B^c{Yt$%lQ0eZ{^7 zPA_|%oumh`&IQ{EGWG%1l@_a8s^9{Hh|D1L<}WA-d? zYez5QfF23~Zh*5ZAx(-WtoZOZ0Iv}VLfBWi7^y#uixx61aUj_VUw_RmSk5A18O-m>@Tz?w#MO?g(yO5Ly)= z>T>hlo#fhB9zN#SJDu#~jI)< zQ!{C!w9NMa){c)|P+$tt&=Ceg|sqF=g~c9$ZxE_&!` zvC#0vZ~9tZN!iitNETcWlu=K0>vV2cCtoa+IQ2~NigI$e2^)%=#Qf&8*Ue|O+!=KX zdDLB8*-5avL+n%R@`Ce7-0gclZDxhHS%c11z+~i!PMv!cg)3T|rlIukyyx2nPSm`* z>>_*C>zNsL5^iOE>hXaAClL6tT|f>zNl&UchK=z|y)I!#vRF<0i95qiQuufBNb?G? z0@CJVVi3X^G}!UL{0xFWD8R#A<`o@4!c93lu~>jZ-AAncILQ$r0ZyklT_<>iSbwn& z$lF0&Op7xo?yyHXfaAm^kD_pqDHnL`fkgrQT3P1H;P*{r$8hW=@Rr70H14uZIF`fx zrAWrIEd99gi}!yBY2rCV%jfrEZX;L&(QrPLAnb2m#_UZ`h+$s<0`oUP65iohSBG0M z_^S{Fo8YpdHe0;N5kv~Fa&*4KZ6tjc(IQidyGz-~gB~9HdxzUf++&Jvf}AA1LCg3(AP zAzS&(C(<*s)I`NerEuUaA0Y?Ow|J}_C%h;(v?&I@poDP5v+k9$6r`hIZA3|skNAoZ z=YS}}4Q;Z2Nn{T%nIoOyB6uqU`34#TSA+2|G(wv)1T^;y7VV`=lp%VFXDhs2i_oSF z0Uf((5xI#zyMleToV_ERKu<31Cj3^JJNo6T_AFPhdRW+~KpmqOm!n)&rNKVIN_v9M z?W42!Ibh-!_rv?>QT_{YVIO^!|Gp!9QC)ai*%jJ0l1R9($LdAhc1bmfs z(L=D6;tCqjfT73T6~H_05&{IrhP-g5W6v+>4D`a#BZ)oGqN2}92kL^$i?+b$OaPZQ z=y8D~s>6p{G}2w0*u1zX=S)u26cNx-^Ogj8Knfin9CW?I#iTW<DgP9V_5Teiggu zVI2E6)svkt00@tsSMv^?nj8(oaNG) zrOW7?mITCZI;W+$RuDD@&!nEfEIM89@<|D^QHp3N`=andEKi-pxv3Or@bw6JQpJUV zNx+Ar_JyKwP&Nx{dtcC_AUsYSUvux`$O3&ra!L^Tp8PmMLO6hwULYBK-b=rZ zt73#ZAV`oWK!C!n;~qQ;kCF6rOza~Qg!`A05DYiH66AVJT3H~}f5aUSKS+==!<*g; z$xiu?-+GVB`Ipl>n4{EP7oNOO*sNMwhUJ|HxMWzO)h+5fs^R| zcRM%?*i@l6d@oHS8`!a;?|1_piU6Rn+ZCkvXiu>3==pnnJkecZK*D%9ukoESZC*pa zfV_yKW(3!m4p3n{Z0P;+*eBO-fkLH=SCIIC3gba1*~eRV@A8C??XMx7z zF*q^`oG;0MBPj&HggwgO=pY{Bs%WszVqYwy7wTMbj|b0oaB-8>BfriH+C9F&USZ$% zE%u7%4wDfiWXSSSxHc4e*o3g>D(tgc1E{X^K@P?<;V0N4xQ31V%-xR)QV6KscLg-Y zK7&6qx91sTX9PfnyB_MBzCkAYlpefmi;vhL=PaPYc-&!O44sL<8V}N!1HNFO7>fX? zFdj_1;^Lb__y)tT*<6=j+@M4QP%95I!3JYa`xRfvj?oW)>*oaTwg`agfB|{AUY&*~ zety#`-4%|zx3}ouVBRol^E;CseWpTB`FYbhnK{5j7t;@AlXU9kvHbXy;u`hkht0jqnt%ki5g`FneN>9@7==(n6N{QIcYa$> zBA<0woR85L9eT<~q=zIXhYOV`ye6VY(dlLS5B4(qB!CGOPXrFfpQ!5!P*7KpQiUr; zi9zVQDLM+&Yk+v!NjC?Nc-h5JRLU+6xc1th%dqPv zPA@Tj@Q*IioQ)hWA6u0-;}5v zFjS`SljzbZ{a1Dcdm(`MnM4#WiJKkJBCuHrB*{9YZWjpfctZ&7CNNjwe}Y9Y?v{9dImEn)}b0mO?E zk%NVLRd`r*dzF5D=OXxnaHWu2r9dWKECvkOgo{O&wf%dEV3>FA`Ip4KhxiYoX$Er#!4ijo#*mWZPdMW#gJ?|sZhQw^= zI#DbJgxpNOVz1M$1DGF4OzAu^&_v-p(QRUqHlAj$_=s#qB66@$6NT?Y6p65jJzHR} z1`ywrh#ZWAuro4B5M{ID;?b$8$?~u(cY;h2maI;?11tzIAf98%j^l2QLxOnOF?s^u z#c+A%9TFFiB5p908+=sYtP=qfATVMmbaHx8Efp1EvlFV^`a;fe z@@dmnq$N)%bwj3tpU)b1w)xW1s8wxi}$WiX}b!XPLF z&|fGy*-SyrDbf)h_kJgv^Juj;;yyoYg`B=!)(sr*uCSBGKCgG(c;U~hIi7RMRBs#j z=6C_Wwher9ynuJd+O17wtY!4RN$%T*ziln=7^}F$+oRcet&q!W%HTS$+syLRZfl}m zsZF%>zZmk#s0p8pyr;r$A$wDyNYPD^NVm-`AlHT?1!PY+(sjocLKl#sDA_5&xP6nn znOnxHbv*N=fCERFi$AKtwCIQj)7%!d%2VL^BiW3{9SSzp#cgJ*JVkljxnLW-)@cH- zRgMt~3RF@$ObWz=NMUnD(1K)v10}0iFwCsZXC=R8@hB`?aoLPpgP$xJW{C%Uv}x~ov!aE&zD`d z@L1=Dp6>4c{{CdLr)Pbyh?BnT783T-%8d@iK2AEwY3cU~UlI(3wr-!w5y)1)?C=>o z_F{~Xtdx5oX|?lAQN?kxgu@!kePRTJWdw*j6!*2k(8_rRK$P7ddf z^AN!e-1DXyMyy(7O5c8&NtCb!Akz_l`xk9+1zTxT45_dvJ+y{8zIx?mF! z_)4fb%w7b5cTLh@4LZM%UGxgup4z~^VQ&jn?_1@Edr=NX4yQ>8PJVbxkS);X;!m)> z@!jKrY}_FB4xk(HgacfDMoD5D7m|(jg`m*BMfhF2@QJ2D07s;C@0NdH>C$rr-i zEyd-0<=seM9emRFc!y&d1fYinRLGIOD{6MQmwv)#d_-uGB5<%4UiEkGt&P^*Eezin zT>4uS;gkEwXCUysUj%V*pR$YY!4IFe3%L^1A!2YPBGO zDXzVmkW3V=MSde!6EYcvi!89nk3N4j=0Fs(MUL#i)wsHfLbk}0eFDe}QOFi~-gXTk zt1jaN5w*-*L&$HVa4quNcMUY8qJS-`NZ$oylmEpQS+e8s)cDR7n^tmojZxk|;Bjz(bErHz7YI4E$fL`b#WFtseo>{e< z3&mxG{8qwwZEjKWJ_+N7Rs~~;p$8&>t)?}Obm-wL07Q-G`6~c~A6a^F86n-c*Sk!c z^=k=nBwV{Tqs)nG3HehLuGRRxaVs;cMY#Gz!@wPj>!VLOO9da|wn5 zzI2a-aYL(tfh@OnIU$CG^;WGG1(%i+^4Mj{1u5>of^u;fN)KX@{!l_+YJs8WmZOKR zpltSji^Bgin+5n=zN@`2Iajp#ksF0!HYYy34%rgDogn5gd&!T7ScB0Q@jfibHo+Y# z%|L%@hHp9Wb<-JkihFcAYtqJIdJeekBHvt^w9!S+fj?sVAtQwmNMk$p7&B}(IV4;y z;f!2-%w0SoK!|XIxcow;#S^M7?%#00p5Wp?-vq2(ILYfr=T&wL%7u&fCipW$6nz^} z3wRVgA)??4L`JbWuXQu*6!+uv8a6;Lay>3?+RC-02JVJ^!db3a$-SS5kFNKM&$pfn zZ8kDJH}4lM(5LR4S6Iz!A^D|Qr1yG&Ivuw z7gaiU9nY`hr^##?&nzCu?0UX~OVarqJ4Vl7a;tQ1F(0^9=sd5sJ|I2O8c?<%j=bhX zw#Z8WdpXXqv+x8r3?uKKvZuP}h2M9;xsoIabmS4)<=J4DACX<2bt^0&WtX322id!c zID5tG`e1K~(fI-6h}tE7+S-Y+To4$`A62`Bf!f_d=S%#%#m}UYvOiw*#{61uDE)o~ z0zDzd{L%ggf$UQRlw;m^>4KE~0+c|@EYbB8M@^))%% z!j^En<8q4yDu;uMgQgsV4Ms<}&E_X4GYr$C=6Oq_Ff+i8BS9$KWXi|4{l|a$kI>f^ z0PJrtn#Bgh4dN;nTu?lL3-Vh=&J_{dyT&k#fCg*EDibHWkTG(1L#vF%_1K+QS?kEo z&m6`2S&ApD4L#xcqADTJL z1b7KQZ1ea(LTIDV1Dwc?m zM4IqVe9W*@-O$wjJAMubQ;1=e9@ua<|CD-?E8nMFD~ARndl83dmLaN04qJ*7ZwgS!1QDbCFI!RBCI74_qX!0xlBd<-;%t&%k5gH~docRmUslHF*arLbOie$R15Z zp!0XobNGZkvPDqk--S(xLfgJAB3xr3ENVhTt>ZCl*06T6)4SQXpfk5b_`gEv6o`R? z0UW;u^mOp0(oRngX%1H zs}ef-ZF>Sr-#jdB>IyJ{cns1T!Y=wYo$dE~f*ai+TqQnB95}khiD*2=Wjzca`;flk zuupwd_7{$bORr=^R~7qfzZbJ~?(yGV?e!u9OF-aIp>D)^pRdkE&(WiIDgne#Bq9e3 zsaJu$`32tiFq>s>1`uIzguuZb{HuSUyMiKK%w%$v;Fc$$M0kZ{nEBbG!7IhO=z}@coHpbmqe3# z?SVJPy|9x-%g>)b9eu*bexq{3B(p5YLArc_;?H%-Rr_U-BiI;5R zw_!DN_BI@xvTu_fv#=#*J4JJFN(4GHd<{MCg{V^Kl?#4K z$Wv^NJ$IXr$l&DwK`NF9=u#+_yYqm4&R*}_9YB0fB1+Bj0A=z`n5TK0WA8q=B7lc; zPXw`53l=C8%e?}R+)ZDnANZJEvd5)vd7waFw;X|8q^}j|b3WqT5>cp@BW!R7kB>yk zF7~(!Iz}i=VO*^|21buzVn@jB@NM7@SzhLJf76JCmCxDH{yz4_{oa5*BJtYkp1ZR} z%xfQSx5N{w=gk%p!S52H=Ha#oopR7G2H~!!e*dK3l0V3tyPH}fG{xO8_rMx4+;0&OKj^lIrT`sjaJPefxc@C6SX3kzhvCV_9)s zlx^~=+HM(BnO{evSLlI2RQ{91o+IodNa zR*j5=S_gYZ#MbhT=+>UmHN)wliWuFp33g^v7tkdfVWfMyuuy6WJ}FvfM%!I@!nLj^M5?3lgy=}zpmnkGSY>p0 zr%@tbpk^6RPCHf}C|AnGO|O)DD_C8P_4W+?kEE?y+dB<$)Vo;P>YRo3dB>W3EW>RBO$HYGXj2QDdD-ml2v(Cw-3U?ljGgT|Oq-^k}BVDXuUyx>e_ zfSpY?f|T5;y$%wcXg#SOOu^L`dS>LfdZ+N{S=BWku%38CEF{Fk^Mn|3dUObFKA8Xd8#D$p|zfJ2n`&llneKdw%M>*fp5 z=g0ZtqwTo5MqNGMYQdp4AOB#-v^k-lODX@`-0$698 z6)Xg(9~|VLCA|>Mz~hkg{|(_0r>FkUgh!elTQ^)>YW<`6zWX13>d_TXJpIU%t!?cc zon6bim$$sSy*ygkIo?0gGuF3x%hp%64ZOai_q9z!gZV;aZS)0ubu5ugWwN5x$?32>xk7z5wrKf-6;{4X zdfO+$E7WJB>e34J+4v)JYSoez>e}cX4eF?zTubLcbMzs}J~c5u&pD$xcO%X?QZRxt z`G~x#W)e5qa`Fyn9AYClbo2ouY6G>ogvwVmARg>!MA4462k8d;(ADzBRVamR&QxWd zusY_7C4KY7k~NKDN!tQPY5Bd&GdGRHl+qk^AVPa=aI7Zr!UBrxNtMMt`4 z2|odkjL%s)ogwv#C*+h?@(KAEs3eQCn#}Q=NJ;kZ`U3+lsUzu=lT*}TLbLatc)Oaw z(G-rXqGXU~CiL2qF**Glv|kHb{i06Dt72r`Ip(DyOcOQ)<_Jr2S}o?qYdO zecm`WBB$gODFu_e)UR}}vWX7E7Nz8LM>?f;sc*umhOrTK4(D4@sQT(q2U+KEN>0Dj zm|CiSh8F6SoLX=fAFwRct;VsiRavGDV(o!xsF~|tQ=f5TsnAClWdG8rLaj=+8d2P_ z#GsCO)J~pLhp;V%1zng9#CbD3EYvkeWFRb-h6F7_!=fd`VgzB*BZWzVcDyHt7Rf#| zJlcNZ^YuQSbI{2T9BwlZYfbi{JLYve!Jw&1yLz$n_xP+9@P8CLTs0$b^g zi`O)Y#U1m+;KoNM+CVj8vPHAXm;RMnBmwFwxXz!@}jCdZmv@G@K@ z70YBP@ni~yOgEAqw-j2yOl66>GH*`h`jni40^3R0Dm?dh{V=B-+gN-}$I>kfl4NTR zc2h|`+s&k7yakF~52ByjA0|tx-JFYvoL)edAl+6HYhFi3xqgEk_mlZl*q0;wtgJ1M ztY$&4E-s^PEL_< zAl~CW`aP!CTm7QGG~Qyozu_g^J3vq1Oz1T$4&kGjsx5>mBL;h^I;eh8pX)&CEB>sH zILmzm(x5)#owz*ME~n;_!dy~W=cw~_taVp=Kwdds2hLN0{daflVr?ziJ zW&c2ZQjSdH=Ag^lQs>rFBI~%`J-q;n;yE4KLuhh!Bje`Dk>zkw4?jNPI(M7Cgh5fV zwzkno`2Z~J;k{$?5UG$5c{#lWf|GAHuS?76;p?Ds5T+yOAV1!&Cfn6f^!yZFc^Lhp zy+VC3-e}8T(KSHeaVoCg^ypuLd#2k1hq_8P3`+36kM<$lt%D?>dh z^uBL+`9&5Tz;}OPGNHYSd^og!hJ2*(kjF04NX*`aA+16U21-MMj-)YT|3OJX;m4(E`T56vEp0pW|NNn9Bh4!@`c;~5H4PCo~q4+xFUPs^#d z8e!n+R|qFvbVO3L0nN(OIameR(XKuwRi2NaM@h@6JdH5>$R;+6qa(rtcnyx@#Y7i> zj3)0e!a{TY17TR|fTX(GXRlB{jH&~A;$EUD`#M@!kRZ<9rm77C8pg<`q?%FZ)F(KQ zg3v>lEVHpaIjUH#ZVwLHHF-wQKC}&NOf`tm9Sg)AeG9}LYpxe}bYR|gN87FH;@{Ni zo7CYO)x?q!G9=ry+OY=)L+yLi_ggVuqjV=w&P({`SMHz5VAhoS303%g4yGMoinb3O z`ea}88v2(e2S+RO<a27RV|45jhDRt)yP}Tw{#P)Y26m-n6`imhM=0fEI9Cifx3kvFg{vlVlhW%c@2> zy-xkE&XUb+W!h&pCPAz6(Gp7k458q?tIbVsu{|Pmj z4zeZzFotPwlOZuebhGM!+nFP45dVj;m#^s@ahlHgQTYdJmVGWQr~dY5`5>#hoR60O zc|OLM`*QF>H3w=pYHSUgA?7MWK~8gx-Jz=%a#-?T)%JUqrqD(J%1KkvHS+3uplO_r ztxyxM-B^`F+@>bh!?Y}dx2r2`@eGZC=0hvguZtrJ_R%LQ_d5dznh^vB(PrO8&h|M2 zl4HeTyo;!uGOw}7bREwjb0khU&`eUGta~4edP6y~wn4JoJ4YZ(SonzKFXT&tr57+RN+!!>f!W{t%uIoTSMll@^ixwA1RCwtJv*|1icYqmHF z?oZw%h0mB-^DD4N?cJ)o6O4|ezn;ZKshXUj5Y@>Y%U_m4l_qyBurCZTkFdb>i|@Zu zy^A*jOYX2Ba~d2el<8x26ed|}^zmWwQg!Tv1_o#J!-x)H)Uc43tD$g)@OV8DRyN)f zlBcd0@>FGkkSEvNB>t*)FIE>9s?*o2!}Ha|yp41JceUl#5&QFO@nUpt2%(du5`3o4 zym}uWqr&NN8z@tuEbh4Cf~Ld!07n=@NCUIXh7j%I(6sjJ`@`yldseIEO(D`}3a?<% z>yZ=qNF7n{%VXD7PiwUpEa8m9T9)9$Xbz{&s6*PAT@+A zg@RK*se`N4$8P>5Y=gi-tj{btHqaYF*hN4cJig@)uZ~Cf$w85>S#U>QuX;>fmOuYh z9dni8DmEjkCxK?!S!NH@4wP(A9g#mg>Y<)@Qe{25-u-Vn6tAZFqC6l^>~M)NeF4Wu z=iVK5+K8(rsCLO+Z}z)9EtJOFb>8%_H}0k5&{B34y@L_amcf z#^vFIDL6tIsz5Q}YY5>EV|NKB>MB7RpcMA2(E6dDV2+Y+`*>E=XfFsi`)Xr%pI2 z^7g2==BaU1pR_!vcB>0-c$hyrOm0NpXU(F0EG{O*^&|2FdB`P_2s62VC*7xhRPV@7 zeurLn zPv=PDej(?a2nv0VsEIbWooInBz&KX@i;Sg_esOg1h(8U|xFMnG<=$1xK zIK(@+9z3UeEYQfkmk`hNZ&D{c%35LN4{kQSxwZ@L_Al_4Oev>CJI(88MR~Cgbgim9qWdRE1RRamCbP*3i+B>Hb)aHo1@8< z&C%@2=2&6n@|Df8+{*Tq&9UOjmX*!1ym1m`32N-5g>I}eJj!b0w2*{1#1VJ!1l5%} zqWk%tv2CP(POR?j8Co;iGc-2RGg=;E@gN<0TXX%pT2iF`U3zBCEwkL!vNC_ht$)uc zU)`IIBAt$6Dw9sxiIjzXaMq<`RDvU*g*b|pt>sZiJjTg$J4J5X;Oy49!KLIHs>7&r zgBdkRdy3_ar=Gq^h{vqjvI$~8W4g#iE0RygBdJo3^gW_=wY2T<|FLaLiw-d#SF6fB zebwkp(IH2ijH-vkbDRK2GHt_#v2ySDXn$qrhJT|LGQaw{WVu38I;OtEIyan}sJ&B_ zXX7Tzm#fPI<=%=T!n1BbRm~uZ~gKM$;ILuEs*5Irf947zUYH+pj0rzSE9M8SC*C1cE*5(i;*%SbW^~qpB+#3OK&PzQR0E(pL`vHK|M}1xctgUV*@iR5h z+WMh5FVz5Njq}$UXlQ6qT;e5ECu@MUd8DMj4glo3R2PCn zuLgi(_ht^hj`6s9oe%aR76-)L9RP4o_) z01!`FeHj#ZDIhR}FTFgj-aCM{vm^ix{pg(ma47Q9064D2Wr2})03`PDvH@_Y?TrC& zoX6n+NHp-B0dO3n+#3Lj2P5AL0CeK~H~^Fe!>$STk z##vvlgEi3F*NcY2qXB?49(@!5NH6S{0f1DTA8LTL#X(1P9BSGQh)V^;6$9ed2E@G-5Z4zF zw=E!UG$3wgK%ATi0HogLKmZ_352k|xj|ByO92EFPP~h31z>7hFzXS#T5fG^M1qHqv z07xC@`vHK|ah?ncJRKDHZBXEapunGl0)Gn#Y=E@8$Nfp?9uRp$K-{eXaCm@s2f*R^ z-4_t|NI+bBK-?1nadtplDj=>H5VtlU?xldZz5qBpw`~D%cy6x-#O(-(dpjUb?hgu_ z4hlRL6!>va;1@xGXM+MS1_08~_e%gE4Sl}{1ggD3fm1<&M}q=S1_hoD3j8)G@Ip}F z&q0B|1pwj^Hb6Cq$IaHa&ku-O5)gMwK-^scarXtpJrWSt9uW6LK%5;AmkNNxb1MeG z;mvzCAZ~p?TyH?!D*I^@r0oE?lseAo0 zDDZ3mAa>Q|4*`JA{>@J{(AwfqoPX2+Ym0;ZD7B{sSQ{fJuHFj(rM;08L4jWd06K|Z z3;?A9T?+t2)3^@0ojk7Iz9&kvFaQo)N4EvQA%ph@z+nsS(SW!W0deU7IBX|A7XXKH z^aaEX2gJP|0EazUxi0|Fd0mbLhn@-mrJd0;0f6)hUa0}rzJj!c`mY*b?JG!o|9b-f z(MPHGYk;*$JMY!W8fb0e^j>`#0O-VdAvpAE04Rzy2O8BpuHKXg*=(%A)fNX&=dU%m z+8RQg-&%vKjSu;IpaxePAI6zS1K*^u!})TEbh>>w6KlptUmYLrA1e!wc(14o5B5}s z#hR`CW0irjSkp5kR#(d9fylskS*(Vr@fJ>PY-o79SUu2FDJMsJcCwE_+jjEb{_@aJ zj~FZWjBPCs42ad`9%ioY8S2{^86Dm}Bv$tf3=ZQ@U*ABPgH{di?BUc_4Uai6u$NOW4-OASxAt$|JUk?FJ==%4B62;i zm4~>YjcpYJ&Xve+?b+5Z`d=F!-6_&Tef>Q{XdkIz&e+!Bq4LhY@^(RSIN9O&klp3W z`A;|hS;l|5_)jPQ>EJ)@{HKlowDO-8{zLzEJAXK?ZjP&)gKq* zIWA@|99NeU$Z>UXTwNSj7su7b zadmNAT^twVJ2|dSj;oX7>U8dLT%8fpFK90tsGY?$JNSlwQ^jo4v*t%ZQ;mToj=sh*e~4I z2|khBIy_e4j&4g&|IpZ`;n88??MD&=c+D7*=pQX_8tw1hCSt>VTb#Z-);~yZaI9P& z(eFO|^n%BFMz?W?NM5%u#0|F}sb0~GOjo+&pbPFd;C1>x_M%s3FZy$SJ#mNMZTQ?U zx7^f&^bU^>jr9*~6Vc((q0Ixs+nv&Ir_#H1xOW)6oao)!Gg=ufkB^l_w5PAkJ# zY?)^^M@k~5eRq8^%XgNlFARwM`e9R~L!FXWL?Tc5aqy6}1%XMmI zbgg@Zy@z`ZTN$L{;Hs~bD1$chz)oJ3`>}@bxV7dci~L>wf)B-A_v~78d7x&XmfP#( zR1;|*aGg3UkH79-Vy%Bj{wDR8!R)%T`YT6vj~AgH#^dBS@*B@38N*TU8zE}uCTWHU z=`Zw}HL$4Vy1V3If3>{#52&|yotjbC)J6AN2vL%s;S+n;sZa28ukj47);8LYq&Csv zIQ0Wm`s*ulZ@u-FaqV{v4b@Nd$o>8A_^#1)c+S2e-EoKhDv;gXcWXOK?C!Y-<^x>U z+zd7SuDkz!^Rt?V9x{axmo7C=w;y}VT>iJT=x@^5U3VQ;KCWwT*NWiTb#-Y20qnZF zs|v}eTo;MJzMSjg@wj^dtv5+$De1UO#$0SQHexO5x_mzG zUf_Vh*H~Arf_5a=`5WDH&q0BV>z;r9dG`Y9P}gf61?*ma8EPY3*VE%&jSJD++w0!s zkL~}m6#p5an>U-USbx9ShPQ1q-}RxPA%j0MQvJ%D+}PNdaesUq+Av+WW5*8n0#e1V zo4vq4{|Vb)u3NYeI~A^b`|Y>g3%u~V@iT+=;b#UNz|RbN2R}3DUHr_TL-?6NNANR) zj^Sqp9mmfITD%yWOs92%%Jo5 znL!uvGlFis5yIZClb7*xuTh$x@iT+2;%5e3!_N%*9X~T@20tT6?Z(dx+KZnVbO1jy zXc9jo=%$;XEWmZ@UHsf@blr#WGlP!cX9gX^&kQ<_pBZ!#KQriK{LG+J_?bbc@iT+I z#Lo!2|{bO}E*2s0}4(W_tZGf~&@ zGlPD^&j|9*sf0YQW_&Xa%;|iYn(3E68S!jezTCK`G0`NU37Z40`bK@@&*F@_=quZs zwOLlzd~-v2QGMYXg4IPiA)yD!b?S7@K&>vQPkmh+RoqdRg_o`N-BvTOaA}~_j67|2 zxJ~ksZ~h?G-X`ueUn<%yc9mzwc4Rv~}zy=d3eMP<(6)Qta$%R{7D z(BtI$zFxVl&G)*t$z53wK?rq3?J~zY`THt=FZ2G0?;Y&eZgO6EMVeFof5`XDnW0ce zeUCi2LE%&W7LuTa9tSz_d)V`E7J5_m6o%WSqo^JB>1HQ(NFB)p*0d~Ld`N*lbqgvi^ zwQC&pll%%ca9y`be&Czxs~PpPuZraHRpuIORDR~m;#=~dZx|nu6Qp6*b+l$No0%=Y z*M=n7tr_t>!aB=SbwbWS1(wIDnO<|Y>?$>3cbj@wK|`JEuXsI!u(H`w@BJEBdUFxLy(RShJPLYokM>n3OBpa7UE%iqY0wTgtjtPrW^lvl_L zow=k?Ekve`C3H!L=-5i0ColExWJ@e0SO@vH9F8%ZH1C82O|0bS6wb=@V6`kH)L~#g zW7!u-D@+xSa8e%W7+t>^2R`vp0CNK2kY$D&1IfBg1 zg+$XFA=Xn^%N!w|Cm&4TttDS+ju5NKw{ec3s}SiW%~Kd!_^+}5F#IrP84~g|{6De(BK%Mh77~i^7uZku zbL=Pl8TJ$YYx3i?UVcH|CGdVm-X?fIA#V%3C&_EUdz`!_c;6@QMtJd-gv1EE)8v&C z@V~?U!|+2DGV%@oUiM#ve;4@`@Ncmf@Hf~C^bYm{JWgI5wvUo;$vh#3$=5Vbhyn7o z%oC!YeAYZ6Hj}S3PmmhAkk~j+Q2!7TBlCoKiSEjYc|yFv-ox{Rc#gfN=LxZfy%*;R z@eFwtum$!4n`JMsP;rSyF;9p%d2uoyA>WclAy$&FsZoe0$=A{-#B%akjY4#huhb|+ zJNY&?3hL-WVx&=sM=4BBGz#%Bdk;4X@c?^a3#pmC7aN7Rhr9~dyVwit?d$~><~5Md zMj>t{FT{9mB;S(xLM$d<(|jQokgsLF5cA1r%@<-W`AYMlxDU~6ga{D%M&`qs4_(O# z_%SSFh=3o9Bs_fhv4p`80soKWSA@qL3PS|Kv1Y@|20vE!$S?d@@o81tv)OKAUx zM&gj*%^=#L42c%LgGFgbSbTv+Yeq>}cKrJ14m%xk3Xh<}{3%kxC z(E{&T@>=j>l@Sspc(Gg#iH-1LU=4{8ct0htoPhr$_8*2HCkiM7{8-wf1n^_!kNm@r znGBu>{Lr(Dyu*Kx{e;J!REShi(sC{&mMjng+gTyev_J@$&IyT@1wvr85E9k`AzmY2 zX@L;fRtt%Z3s@>9Bt{kpGOdk@Um!>yENXp$5L*Z-PcIMx%M9dpfgttl$m{}EH;cS3 z5Tw`|SzRE+I>IVopCvD3gs^295=$1cV)l?|TFCm=L!xCN>st>AYaweL4~f!3A)>_C zxDfW$z#UmA1U6!k&xNcu9r;`+#4-*&y^yt&BcBV|(h2gpP>?}RM%kXW)vkd@t#Xj;TpfkUEY5wrv1uC+*zdd83_En=%XA+d20+qVvh zkwvUu7x`SIRg)s8i&$PMB;*urP%F%vgu+BB?5IJH$th^w6YXje%BW95G4;o9t%yNi z@Pj!yeKU57Z8>%0VtGaFwpXZ$@!J;5U)1i+FniO8(1{gl&-nGQnz2NKc2)igMa-}W zuzQKULQTD?j%YRJjbsaHeRE@~SMAc4WKs=eohYn!sXa*1$s^8*)IQ2C+JobT^KRX$ z_vdIu=8l)5z}&Jygsz(-uImUn#r0}^C$-;A_8R+Hdo8IiZ-P;$&+*S0=z_lFXk5OA zxilG4z&~d=lvBb+xJ)bqKoX z<#hONd2*@Rt&XUxsa|yvB{`mIP)Ad8>Lzsrmrlk=KlWoguanbn;gqmJPQM&lp+3_w zzNOx=)q%ORgtOHFURvAgK$uQg)VaqI)qah}W0g}mwTl|cE?Z8{MdR7UjYsWLXQ|0d zkeL%S9zep)p6rkbCm1jpfPsyv3TeTAvw0mGyTW7J+ho6NzXTIo(59lkrq+V>l7e>7 zFlm8yytG^;lfz+FJFLDS2yIfU&)APWL#O%4D{iBs;YDG26Be|LaT+6rR>zAufclgW zaFD~(PJQDxQT9?3{e+w7T?@ormFvY_eHbL}S~FkV)zK*KYWur7eXBbBH#M9vpeBzi<8yxrdgMXyINRb4b$FFYUU=`pTQew=~1t1u6P$2&AVPa^-OH@-qw6 zuUbVYP2I`i;BJng>6i6XLr4;Ct=uCoWBuo7!y~)WaDbUa^iK^TeSG_XI(k#WrNxNE zx|~fKWKbKbhP#{9m+}LQu{u4y0Y;*^Mn;iEmw3xv+wrV5t-56il*z+mYY5R`PEH+B z=he?|c({7k8%UFjDO5wXazgSm?7mgg#3TX^D3iyjc~f1xaV0i_G`G6($4HZnI%RFL zaO#AbT8BwVmHRIWr#Xp_iO28eS52xE|4ad)Jc1} zd)4K2=&y7stLmeHG`XyJ8f_9zT~+%NTU;WR?{GkwJXSlcU+A6v5jpA7u)6>UkVzw5 z(jhcuIQeC45OZ~%&z$1{%H)wMX_xoGvuXlUc}>Iy4IE%5k#$Gw{zL8?mG2F?Jo%18 zWZltTxn$&>r2H}bS4^UGlA9bRa3<F*nKWw)}FAOOv}D9#AF^f;eu2d*HsOdxU2ju=cTx!*RH-IJ;vOaE->Tu^0uXO_Tg_9;=CJ~=Wd((Vg9bSin zeqB3i#-RdeQgJ5Yj*t&ka=k9?Zf8&d#$-VX$?Y9`&-7j+H$KUMOt4jE9B43R7E(@-;VpZo&Tc1>0%9WtOMnQV-Ow7ibGqTXNRnbRqq zDqtqDlTyX>04}~k?f;vb;GLLv3PB)~26-^ol7`x?jxNC7i_U4xAp&L+vGdRn(()_v zXnK9KOB--#0GTwbhuri^_BNc>=+xwKhX<6&gV;esNDKeSiHGI!ZV&MfhX|NSBpY+p z3LR7@?lazuuN)#^CJ~ZwF7fYOS@o5hV52im17y;kGzz%3={{_I=>k6D&;T-NSTMWQ zsos;9o>d>Y#5E2PFq4Q6#oRvpf$|8pK6QF;IW&Mw8cuy1LYNl9sq^Y=NS$?wv=(lDd73I+K^5KJFoY;}8Kei4Zb$*GTHn&GHa7 z0(FvMXEq6#NyJ8)_f>pG9Z;8XVydaw9ft$Zq++S(b~y1-b<#6#U;`ZvAd`lD2v0jb zCQmKc>?YUi@PIOTWJl0#-zSQ4KhAM=KINpt1kPmQ%-F;HSzb|B|LS4>;4pzRnfQdy zZQ<%eb^h-Vg3@WK4;&_NCKI3Oxr3_uwnKjKPY>}|hX|NSg!rdhs~hF#a<6Cnzss4Y z17-3chT?sY_uisro^(^R9U@>R5r!?jL^UD*B@g}GrS>>f08J`HQ5!;7QozYm6Y$z4(A0r)#s~J08J|7%sq|oH~EdZY}r}m0%>xwEALJS##t zfZGebBEL}AyhDlny~+jB>h{n>>Ztq*0z106>SUD*q{+phg14&VuktJT#dZ(- z=PDamlMMlAx6_pe(bQk56V;C@kC8IOyEo=WR_f}{OvZm58v778dYZ;CU7PbGU+b!?TkF* z-5I#f*&GGR^ixKLj%a94H~rh zH@xbdFK=*Y0GTv=3gM=v-jfGfAcUvWd($BTW)g=DqC6z8EcI>*%aaZhIFpGZJ2%Ok z`g$(JaCM6EibDjX+*Tgbj4@5)Kb2lZOL# zmnW}u+^#-#dA$w~D3iC{;EiwT@@`wv2{If|CJ*AUZh9SSAB7OD&Zhj-Ne?KK2ay1m zr!K3B0f;VCnb#a9a3&Mt-Y!#KQa^5oB&}wu4;?0OCi4x0`KtWl1@AtRg1!$pz)T_} z8QdgW1iOsG0>)%P z_QGW?9(y6;vbH!ZU`!Utbh{zEK_c~Mp`nZsJak+BW%j%?eQ(u0rxd8gO z_}0bcMi#1{yz6E8ho%DOqwX=N4Ns~cAVH*atUlIM;Cxib?6|3_z4AMG0bd_g$yYTQ zNFNy@FD_Z`lOM~Uy$5GEJDWZP^l|qa+=MzPPk85@ZJG+4j|!b*0Oyc55<_J~F;=a>?q1IxRml_H94YWFUQHh<&-_+vR0> z37^GO6aGze0rYVpF6DAxkh|qs^}Wlz&Dq=`oR5l6uw1JA^d@x%@?1LEE=>i_M}I96*aa6T$zy2iwz0jd{ju;xm5LoeCH*|DeA)B>1@{$&PTRhoE(vF%b zk7z1zJ}N#9b*T^DaR-`em3cuk0rN2-+vqa;AD!ntf>u+S37C%wQ4F^ccFJGXXZYAp zr>f3qE`UBRzW8ucm0!yV`OZr&H|%^bLpUE5a+xkweI3`J}N$&a;Zz@ z`T5Fo!uPah0_I~vRfEfXMSgOlcO&~n%>>NHghZ*!lxNkUmEQB39hwT9kNTBCRcF*6 z%@AGF6)Zo{TmXGsi1@n6KEAaqzx6OLX(nJkCZu6q=FszR85`k;G!rl%^IL-{&;Mm< z(`xhuI>YLFO$O3OhJ3P{tonXM3PX#g&UZczB$$s0NnW=ds!NZ{Q}}vMQ}5SQ;Cxi* zS8x-RN7Z+!^)54_nSlA25UqBZ>V5U`YL5`k2F(P_$Ak>B%e+G!P*V^-)7gDfQ-SkQ zAw1_&Us6}pVF)K_sywN=0Q$I)3wOEll>A!#ZXCv6(PSWfWQb6^Wc8UmroQo>tf==j z8Au-)UnRNZTj$7c(Rg&G)kRGO&PRn{yGwn(UH<0XoLuN^V-w8Bg#5S5lpk%BM=+x4 zR3Fw<;CxhktL{?O$Ir-jFjLXgq^1Jrqe3X(ZHn^pU2-2@PEGC8RN#D6$gX=*om#WV zvznF@nhBVX2{B5SDc>pI?A`MDR5JndG4VZt%Z%@o)7}ZKyr!wZ`KS=Qcd6l&JnmhO zsSh<3I3E>XYr0f*;CA^hW8C;ja{=^m@im0YmHQu-r@a%O8zA$9X#{XSDkSk-sx5z0 zpL?IpW10$_kBZOEU8<1N>YBHQ$!aQaJ}N%taH(pKI;B4Jo`G%ETmXGs$Sk_M+)HkK z+gK3p(@em8Oz1;!QEvx!OQ)}0-q_4phqEO$+Lklro(K%LEHMe#Vi$UBtOi;V!(ZAu#8O{EyqxOK1 zzC80X){$L+u7er%4wOJ>ZoB5zu43t%V)uMXU6KdXPpvMsps85x`jX{EZ1s#o$OEt5 z4gC;0*%8gHUB%M3GwyLjG;#|*RnR|6-$~i zyk|D*1NGs&TV1j`uF16vS^E0NQ&lI`&uZ#+5BF!ytzF7ONX_#iMAynwm;>uP-vY5i zl4z~1WnRZt%lrMCYTCP>+M%hnt62JY$vstDEq|0>jk$?FrY{)!FcH-I8E@J7sF}Ir3g*oy)@3z%aO|4zS zk{%V8Dz9yS*}K`D*UZ`_ENKsLnfWav2+;){(!|;YEPe9ko`1hIt}ZQeiSn>!)~;Vk z@0|Cwkze1n9iQiN%?No#bFt9%H3(k7y1m4ff3EXxb*bZ;Tf2m%Pbxf*^(*zQ`ob%h zrm6|ou41ve@pQ-X$A=et*P^#OO2i1}%QCNGowIqNPS24)c_b6MG_!UQOWzy1RopG7 z)HmMzuF=%mRV=pVJ!6*od0g#7yU}(0x~A4HV@Z#W_wj6#hhOs?3d`e~Tf2;<&n4Z~ z^wc7G#(OX*uV^ZkyS{4TWvu&TUsRvI{)C%jbwYD%*RiBt!kcAz9GgcT2{(0BvuoF~ z^ueb)zW1mD^E?tDw?Zr$FKq2nmUIcZrIp9jW%Z>;%)LWXYnQS(HS;tlHTBxqZEjiD zYGUm=mOfQ=+l2b#_Hoat&#RhPyNo4G9&RbuZ7zAvGv$YxSi6c<<|_7|s~$6!SeG@k zb_q+LmAOgEWAZGYEI2iKSW~go^|c1y8uo)#JNn%EQQvE3?Gl!hRJadij+|cPkv(d3 zH2D$Amn5%Xol`oYercWK6`^=oGiz6{*pD@upZe-{Ry(3!w}K`+Ygms$cv2eG5F(xM zlq>bGoIFH3hK?K3WLoV~;G1^{Aule1NFS0GUXADU!86Zw@o9(rQT`@>M0e=({azpGOouA0zXTK|gXT%lE~M5G+gH4DLOU3?ISiB2XaKf&BW zmtP&%v0bVy2CsENLow6=`OA9st-4e#hB~9kgfxr6t6c{mUQ`nW2vt;ZPK?RX)AA_6C*4}^8sX_iwa;^M{E$wLm&lc2QdH}S zYOFHayHyA1|-?}2X=3JpoYm=mU^;I>mwYgOa@mORjcIS0X$8-*^P+V*76k_Gd z4N+@DOWsNqqRC`B8nakGHtE`3*=*aEhIFN)Q9Bzeq#T5CGiMc|$$Tasi(91imh{{k zh|W?jo6Z$dX$JW2rQ_MS9nV>$6W_SEJef+{sca%`Rdul&_q&qOoSiGBZRfsmb9pHn z&z4e!l2uh!Y~0UVv3x38ipJBHN7=ps=_=T{Sg82JQHrLmH9clsF3-mcnRq^#x2oFM4QAfT*s*xpPM0i?hIs?hkt$_lsYo$mLF2!1 zYk4f5h-C^%+o~#MHt**m(LypFFYtY6IX3PuD-|-iVlr8@92L;U-L7J;5Q%3>X^Slh z7&p7~iA*kADn%`AU%+>}6ieoc`M9N3LL0YpRw-Lb#`2k@F{^6jz_{ODvSZP>osC+n z%Kmm3PZbN%c)?(#d2d7E2SRwreR`(R?wLPsK|N(3S&?l)6fGwqPf+NsHBn z8#kAiViCI(x2nb=jJsXAd^#3MBqGjzBw^fNR?1`|iFmGLIp!sd zyWQE09ZBS4QA-=0Fm890Vs;{%E=B0JaVu|?6462=RZQTXwoqX}x{K*_sT7OZmbP1A z++JQPrb|&f7O|?E0!!a zLQ%gLj@VWv9Zx5d$+Uy3-x4BGE0@ouQ<ChBJsSPE+tb=f_2(i#J1A$WF!+W7i#hnOiy5mU1DwHCTVk)bjfvalXh^niQk0(+|J7cj; z5aZ^uTq15K3#p>zSPC)jcII=rXgrsRS!6%NxVO9zO(zp}A#GKyiWv9vRytXV#dC#( zMW#G>0%1T(R=gOslhJgZA@xVSl9elFv$c2L?hi7&2Lt`LuBvjq>TrqT*lB!<^E zn{`lZ$i#@LXeDBWNG@6^IT*)GfdR@}nQXS0Ntbk{$b5kTSsu01*|eR_aWpl(^zvjW z8_mZvd>i%^406I$lU5;~Ybs`pu_f*=V7VvAm{Qd~qbB(R2$iaerAXl}ThXk%;A3kumOeN3w-zA(hKn+O~{wJ8vbUsZ=gmC|ESu)p?Gc z$z(B|DV5@kFz8*eXu23pl%f`!r!j9vbD2aWo{RC#Zu4d~Zx`%zD$h5UnKyHZNHUg* zAyYj&mv@;rGsRdgnJpFhW~X^Gor>CtT&~17JItH;bTX31#GayUH*Xdqscb19%ka%M z^JXcVNM%cpLcWxY#yQ1qf91ss@kGq#ymtF5uT;v|cAiVw?XSFKF&c}cxqiC+m6yrJ zvY7awB;EeXvvcW8(&lH+AF2gk$5b{H~qC2&nDt2dKG$h zF7wx3Ay-T#bDY^_{@RO{N<}-xFUm51?d6K`LL|m7$})fL+4)R5TCzDq{@TkFqPbWu z!Z&@jmr3PIIgBfKV!mR=GKFX|n&+q4<*z+EpGm~h{4~4#wU4;s(q`4t<`D!m+EX31^BEMt4lEiYEcmaz))NH4}_M+)hu~6V7JN>nn zh@?u92)Ei!f9>V%eBMrQtL^lqnMp+>nOKIOW~aaQim_}qTHwrf`fD$e%EjUle#JWd zwUkbwUGZCl5Z1>k*B$G`Soc^HQUwi3vB$s!Zd%M5(V%dBV+e3KN z?f%-!=2C^Cli7A(Zu5y!GM>)zLuvQdUcOjJWs3Yb+x@kd%G=RwlpjjFzxIlSTqKv| z$Jy?yy;2POO*&0q?G+2Td^W;;P@BK@QhB?SOK>05=C3_FkuIh(oMfB7_A>EUAz9$e zw)tx>nk=Rh5iVw%zxHyeL@u7-3TpG$UOX0$Ml;+F+I&SR6r!a_tiTVY&0l*-I~unm z+-lqWwO5K{Qjr9=+BRS96|=c?+;$#{FVJxj6T=t^V4}#A0^V=DxPoUwg?^G?UMBSJLXQy;3rh zEu^^Y@;b5!%$1!X&S=ofi^*inPGBlncQ2}=WJgk^l%1jb1~q486X|?D zQ;b-yIX(liJfBWxi=R6Y`o*-lLLHUqF(Q%c73r2Q;#dIc~U_{j%qJdf-N!!tMCYmQu?c#TNx)d!Gvqes(-kxhQo=qkr z1&&~rcAkzFqS0s~X4PyVbjRY+VkQ@{wDCnFcO|PB&1X}osBM`x84Xltrcg>pbJ+|) zJ-!WyNXd@bsbbWs+HW+tIV+kf*l{~rv|O`}24Z+{O5}9JEn6yme zk_M_XQc4zLX*&*3uUWlaxlFE*ik9*g8=^Fc@nSqyO6AiQnWr@GMYHjQolj>hGFoZe z!y!c~nU6&x)+`&01uIcVXVU3(*7BOTG-6p^j1{x#e6nCw4PWy8%GUC#WMoyjcX+gK zObm?=t}z03j0~HBSRTW5vRrX4MKc|3H~Rv|hqm_*_4z^_Ofs^0ba)VP z`N-ZIW(1x)J4Oa^8rw5g?j0P_C!ih4SOmRD-hxI}F4c~a!Nh2}T+Q}hmNu>GORO1A zKQ_GSmB*XlTH8B1mv?u!bS$UKs%vd&>FVlgYU*rn?c_kHDDRW|ZxQOqeNU9+7uU0H zYdEi#S2(Cvkl*WbUhV#}v}uW<>=h2@$MYRkWZGF`NyIB>00(XMJHtZAKO9+8d>uKP z<@hyo1(^hZLoQ~s8~+w`|9|8N+~ORXfSxmRIDBp=wN5DQtR|S0C0K^9$@>&hBHfa(+n63e~SpI5+J|wbjaHFGH3C!855mpSI^x*1MBWmY`c|yG6 z$9cp(;2^Jf@zwXjUJ48AK%GdlV9jEEPpprXUn>s`kF4J@GPr)Af75!mOA=3rCvN~; z9j2MRMrLWB3D znrT-PX*s2?s!Q@hO8ugaK==8i+@pS-gGi3NRg}}V`XeQ$p>R*gU-2ALz3OVZL0wgs z1Ja79-`%uO z$^Tnv{X?hqfX*+RqPfr(SGI z%c-#k5#yH|)E<->ic7M1QxG|Iv*Eta-l4?$=8XnAa`=}~>-1!{KRKPaa{a*sL_s@y2|sH>szM^kbt-AGF1A0$aeZtYDe zIrV&_^N3cc6O~4^$tnHJrq%Z<-BH+VnKnwwsZ#K82M@7-ql-c%=bi!NUEPHKfZSh-FIPv@E~_RA?U!y(^wo<+4o!DHJ? zkIi1c;pLZJRD1BvJa;2#+0gYDCJl^G7Z@gGZ+KtBq(TX*2g9Uu2HFe5fyk zey7xX+B?05`VHMppuLPocmTqq-tTFRu(i@8_o%ZWw5-Yv81_Qr=yh_<4|06!+)X-S z1bUyU`y?rM=7U5rHoW|z+Ji2VA0iYW^Fu_Jzz-4XM)@H^?;rH&g-K@=KMtrY;;xL8 ztZ-jO0@2WI&7BF&sjL^L4-#dHtI)!Y@@&7Ui^R2#6?wZ zw(7idLChc;LKuKB163E)5qT0H2kZ94<-)+y1c7ePycl;}$?B)nfxj%pe4{E>>?oOF zoFR~mbyWk&BO{du)KBU|^_@$E=59EGkq-}m9b|tu508{x8|HrDV=PTv9l!F3+P%i3 z`vQ*~4k%O3o<`fMYIp^M;9q-fCupnXz|9dGM!cEu=K)W;A*7}3E4R3ec9!~z8#eSxiXq9yv9s&AkJ|V^zU@Je>_A-XQ<;!tAvngmHsj{EPBZ4;i*&r}jCK z-^fJIdym%WmggyTUi~4zy0QAi$XX;E;f(T7-BsUv_2XTyZ}#vmIVtKI7Gj}(gD4Mh zFviIa#esuCPj))wshSX&A2l&BVQPlJDykVm=2hJweB42+F2PE0%nuH*ENBQ(_m8*n z5qYH#Q)j10Lc%r|+|4!BiA922ov*30^B%joTAA{!!y}YYnfMI1A%q1t5>XTK*BjNh zE|Y9G!4ZypWd4aA>Iwyd@_9I9f38qJ&Jm(GQXaw%WTJndx@BmFIlF~M;D!y!)v2DL zzJc;+bZfbHo8Bvg+-x*rr;@Rp#VeDQohz5W+PkuIWpgyTvN@UZ1-bt8iuiRXG~ z^Dqj%x?HgR3-jZ&d%gZR*z6)>dPi`a0gG?w`Y59$dX$YWf=1 zaI@}G!%nK#)!U`Uj6t47@9p#un2yc1b+>Ge5K#w*zM$UrDyAbn4n{lR{yQ6Y(8+uM zzuCBR9@2ldb!V-n6**~k#Ny*4bs*Mkp~J<3`DkTcN*$nDphYc~!fUDvUMyZ7_J$*Z z>IMk*+pu!cD-{1KbC=pnslKT8z=#S)?J$`ez`!3SP3{X4e z56_HeIHCD-#C&yWPRoCJ;egyBpF29`M^HtfTQ29Fmko1_=@9O?nP)sOVdW8tu@P{&~hUE4RBEl$iz(Y$U#6QhRhbfa}*Y`ac~r~NqJ*%NlNVQ^@N zA6F+nc^nqczwje{F(QX#4_zJeBkRPeF2Ml1KH{9M)Tp03>K*p^PA>77AFPA>zcY9^ z@5O&Qcsz?O?(f&3N6z%FL_xaTw(OY=faE~-FbX0C|M+-jwpzZQ?*j&`7AVAQe z(uf{KXm1Sz&)-}&S%4j>jbrl7<{ddXDZgr_fhO16*W6)a916LyUFE}`g(!iuODCt3 z>UVW6jt#l@u;IH`UPC_)$ibYP9B3}N{Pz&*jB)k~^+| zDRQt|TT00(%HNdE9~Z-|1T~nd zx_EP+i8nrZqf7{SXrB7C=<;9$2aZt2#ELgQ@#vABIv@|J3+hLg2@?izgfpgcc)0FV zP93W}@SIB{h0}0^GE(GSO^kp@@u{`)k~;4pLU{@t!Hfj;wq~`Er%Eg3M=q6)W#Js4 zkt%Oc>T*7zetXKhTTRMv;0R`GIwXIUzst)m z^LD2d@eICJ?Z)QOau3!;>@bb3-Q$DPd#gNW-LSdOvo#Htcd+K&PdzI$cc!yWet?-H zynBc423)Uh`4qD!A$P{y3cG@Ec(`-La7dU_*2wtg&E-)&W$rQ;@%kojm&|gLrZdf* zf5x2UCNn$!j5*6qX14qpbC#RTG-mC(l=T(|&b>{;<3oM4mDWGBCEqhJFx;#6)M|FY zHf$cN^i;Y!`rF&k@(26Jdi5FruDYYq&HEPGX~Da;_RcmAa|G`e3UwHQcW1+*y0WUb z5V%9PBkk%g1YoRXrw>_g9f0FcvRm(Uv<~o`GQeRpf~{Wp30j!5=T1Q1tQ1S^HfIH( zT|IF+EW4utaCnth1;8P`mjmGNq74SXp-Xxr01olV{q=yp8pI$VkNJT0sv4t={0J+l z&m1(~e<1%mGkch$x_9<%A>Gpdvspdny_4-~G6oSV+63xee77a+#qvt%$(A>7dvf{P zH_Pb-a&oc!LrvIfM(s|k8MRAJ=Tho$Y=t^Hsy>SoaS^V@=i73!QC>w=sXgs#LhX@z z)UGfNw6EKq&~yD%ui6C(1>SQ=HK=#gjQTt!r)l*@Yl8o8-)6FaP}iX`@st>w{w&9W zsV&SbhiMAUf>D@@VTcaXNjIh|yjz6K%RnP zB!jF?18ut?#Rlpccz%~2daY-mzprWC$Y6YQba)g)Ms#>!cr?+|KTz(&Wnnm99vmLs z2|qTs9SSaS6yX9_kN5VL$HuBraD?)zntBZnghiV0aCqtPzqn(DuFiDcHxIp4LkQg* zocyXO4dtE4$c~Z0p33kztZ&glyQ%yPZyxJDL&uU_*Z@7}puy>vI9xN-(+sg{WK|xJ zpFg@vALEMZMjKG(6oKcFNDA)uHy?rx58Z#mt|}Zrtc43#EYE^aZx_rHOFjQtvErqN z+<5e^CZDD^=L$4wfTdUz$c%@lnL0yqLS24os~Z!^>cIg%SeL12p$Av`YX`6Zm$qG+yKRsSqcG?$y*7WIJBv=(rS z@(dk3p+$=UL|%|ztG)N}g|mH0X)PpT?R*x;8tdqD26`h`S4R7Xw&+PsBw{7wu|gIa z3!FE5WvA{9j6=YZl}*}-v~9;Mvy(7Tc`I8;rR-=n2bAtR3`og}+o_0M%A^7DbSVa^ zXhqVAQY@Q_0Oj^H1}JAGld)tZQiucObU+58XceM%Bo~iofS|68YJou;Hqfqbq-U&* zD$4b58toa~xwbqy);~NXa4_~in$Wd&wi^?=1w5gnO-{5wxOx*h^^@*aw3~HC_l)il z99M5fhv7s1?gQ4FX21X$nK)kK%;?aF2}qM?od)mMzKN;dK?jIG^-i-eHpy>*yy8dJ ziBcVFfCgMYvfc*k9}Pm>i0nD986{pP%9gMYPx^7b2+?D`;9#_)_&o0%90ue~K3u(O z#B53Kt^@o(F4@oVb9P4s~oPnFKw>Kx>z}@T;rh9^yAo$jr;9D2VYybGm(x$On9(_M=y)X{(YgaFBmOP;y$_hq(Z~RExjg@`Ki{9GtV&Uq= z&sZo}o`W2<&23Q!s25r+uie`?HWybo=9bs)MNQ9@yXK=@s6qqSj4K%3OUbFo4zvb5 zOS#)Q>7{0ZOX$m|2BTxV$%zp>2t(T~aw@WpTGEv{ODc=yp7~4URHRu>+D&pQ@}Qiw zo00l|dESV6f>R&MpC7?7r0%Nq`wj_BbC}1Sh7cMLe1BaaPhxLP^R!frF^mL(UeXc;BdS70Zf2faLCXCX;5za`Er-8bF>fjw}LLPC6)l*<+2hx+Kp7tS5 zxNY*P+H*R;>$m<>=Obo#BOpi3ZJMuX=R)#c==TsV(&R$k4cC+xgr-oIfoBZL_ zsCZ+n4xTp5jBv*LV{y01ykG|v-%%+KVVXqW%C0UOvPRA&o(4^@JhP~Ow=34#($!&1 zqUQ1>>P6>k8@PIND175%xVlp)>|sIP((CF?p|Dg@M|{9~V?PEF^;t-Wo1OU<{>(Oo zdT5RioemC7wB8H~E!-8HWCz@TXD)#`-#=#G_^Ce3|72`N9JPA^K7P|p7TZN||8A5~ z*ItlcMBR=Qbp|)vD5E=I`K3IgPO6_=<_d?&<4kR53y1GJ*rCg8&hgS5j=NthWIbJ> zmdMfFk58!546g012=06#Pb&69d(iX+mo3jg8?Qy1x1WHD2k6jqP*Nq zhD^vLOdtxn>=guru&@S*Wa8p3t_cYV<1mVd3W9>-gBVco!Apg6s{gTjK2_b{*L(+X zz3chidwb7f=Q~yX?&|99PgixT9b5W#4n(Bl} zq@3+L8_G%~{a%1HOeEo8FjcA4UUZE)3n(XO_5-+b$Pkv3G+3qRD??;M*glB8^bvq7 z-cT;@ja5qR6pi)PS&teb8^W??&rtM!l~U`Wi10)xFJE8B>+=I1!Y~1gc}{0QS@Ndb zql+P+f%H3geg5%n(!^}jSF4qpXy%90<{?Qw7FX(-Ae~3oK|q4*>|8S;tbN%1^Nu(? zKX_6s*EKa0l)4+rm1)PY=0VO+8yXwJa^8i5yb0Lo8)8VFavAG^2} zC+qMS8+siTW@o9erIxO~_`(Y>Q1RJ&(S>7_U#hR@@6dL7P@lU$s*h0qxfm5EYWRFK zZ|2ap$GJ87t5Q^K0dj6jhVreonXP)X9n?eZ%XQ)P$=oGFdJJ6^!KZ)dA5pDe=%7CN z??nvrt4Gd1B<@dhlirVXPv$0Ps4xvb6s@wEpM{c-@|*l`BmMdeL+9#|nlXSN{l6i( zBm=BnGdE&JRMFH1J@l-3(H2weRb7-(2HF_-92_(88fODM8A(G+3=J)pcJ`R5&yZr& zx-=4lNB~$b%2b@X4Pgo6KGNdHWHGjhBU?8~iDA-7;s}-!AuMg7jLe9u8Mz5+#=5wg z(O9i!ESjPRoSD?a10|Q7Wo9=TmS5g~k8U_&yP*K|Lez%hzFWGmXyQ^h@ zRMS=ctG>zq8?U26OMH1tZ2uIbXExc)Q%7Z&Ln^I9)?RQh(2kn9NYpfYi%uje4fV6f@Y(#8_%3Mwap~;plWj zvfj)at}HHxU5SaM-UfMSih4;5^-4*-!X#!cS?kv74det<3$T!|GP5J=ecaqxDc3#V;I#Ef(Lf!hiHWNIS6`4 zzfE6wj_hD`0HI1aJqjD^4epWV$NJ|-^pz^k6ai)?5JbK3YH;Xmx9l&xwv(>8Z0K7A zCgNjCND%~-)PGC~eK{HtSG!87?QhaIe|FCSEHq+5$pdgvS>3X~L~l>iM<+N%x0fG= z&R2Lj8pYT|mUMbQ9io#iD;w`YU^?FsFy@Mzr#?^D-=Iq#PPo%UU^-u(atn@LMV^n) z1wHh*%P2aFqrQ2&2!hPbvX4I0ryuk%!qFxIllgK4^g#}~5vnHLv)01~*K-I=6ms0* zofX_r5ndlqc70YKi$b}vhc$5%sVx~^jO%fR7u}$OK6!7g(?>H6Ba`{cF3-&E9H7yb zt@=loZ-L>H=WO0%a1_-)zW9VJf;9k4bZ+nKYuu8jOhVI2O3oeSl>G1Xlm2$qG^gOt z8$Rhy@4S!~-ROP!jSj4L%S}TjrI{rK zmj~W5{*-!(Zfw$LXF3I^V}?<*UvJ4-Gj=A0KCcJptp3=;`mJFV71}#QA=ll;(qAlG zLhrkb`jBB{GGCrBfaTuBY}Y@%<}IxL+%PhkFGp6{oLZ{K^p9IT8UAAUM6vT$lCKS& z?pds_=p(x5a!xm=+j6_;?I3hVm3pE=+1m_fMX)D#&WA7z?!Mk#nJs-g*7oel*#vx_ z%;}%^8|eAOuWj$1fAm?dg~{M|`$RnWouz!TzT~^mmwp%eU@E3yfzPI#?Ync`dw1KS z1wQ(#WJnDS*9#A}1H7K^es=c#w;We90) zNekdkh`tITE$srVzdEc1nwz~|i4kfeFvBXTn&la5V6*Dd172kZp|wIO{nbRJ78v*_ zMq0VU;f)EUb{aZ#Uf8KLuBB)+fm5j@P-*mH9;x7O@nWoq13J*T}V}^FheQ&C`cKo3<^d+&A@mIQih}nD?v*C5Tp!A za|(1NPY7!tSjn3=Q>lL$S_tTJtwU#L;`ywhyj532l~ejNLkW=+mbbov`7jRBG3c`1 zr$8YUe`~f7XE6tr5S-j}QT3->6s#n6?@8WQ6z zLt{f&wW&~nirk~rOk=zhB`ue8?Odhi;Lz|kLvq<%r8fyPt!yKdxqzO%4e>;~|BH#$kK9CzIM46dxXlw|h!&set2Xqh?_m$9PT!h``t&~+_f8QQR4WpxctHojVCu_AX6P>SCb z9<=bs|1kVs{@)UC&L81Xi6=1;Uh3sY6w(qW&=JO#!yHkBO)to=ILwe3p8H4)&}4~q z!PWo;yXjgsEF8UfLM3aJ z(M6?f^r|^gi-;iy>BfkH$syj6L{v&lbJWw&(kQMZ#$X8fnjFK^AZ%o}Ht2koim5u> zRMMg60Pv#s@Jr%;*bQ&3<*QL#Tpmc!w(;C zxikHU29~K@Z3-6N+aGO}yVxN;T%X#ghf;K?v#yhht#u9hsB;I~Nd+p-uTb*HFttSG zoDC?^V)S~j6yzn`M~3v+%8JHKIc(!gU! zw`O-OsFS+oQ#7zt^%Gt^cKU0E*5h{N+mmL#Y0dDhW*1*h&(BhRTM}2qTjCiizJX?s zb91y)fqp`}H|Ud|J4{r26#tCiCFXHDRGpw3Rr;nLN-x*Pv6JLhZ%omU{#oDb*C%M; z&novQE=?0OOy_ax>@;zLZX}TSF>_0&Z|ZkxNDqPWf*zv+wg+@*V_iEH->j38&`;=- z1YNFLQk{Fu}i8<+Qoyp_Y9`Fy@_f|->b^h04o64tc0CF|^k8jr`eh+ zw&Bma7Syeqpeh?drZ_PK$RJ_I(k?LwXSwh4QX+(9DU^(qe7-^-vA9htMEKg4FIVr; zH}N*4kcv~`IYg%GBitbQ=W69@?j?Sndo>DqQG^Ofm+8HQP_c&f(cC?W`*D%iB9k&f zmoxe%oF>$A-^7;bxBK-N4babUKA>`|nHD3Re_t%Oo%&`=?J_EWBtgS_BYZbVLzn`5 zQ=FT)EZz^~gS{8#ROoF^q+h?o3D|B#fid@7_5=+#N}8*XwOSJCf7n54Aa8%l!kMMQ zOI*;@lA0Xe9ixt@m^U99plfIf%yBjnUw9*)Lo3=V&jhXlK(Sm8<|^$tJ?A!v*8n{e zqY-!(E!TsXwV$EM@!VQwH9oy>q_$hbTy27G#M8_5iC{C?f^d?^V2Cq-z~E-u@3~Os zh8v=v(e5hO?x_aav%o6>-I!uZcc6cs^u4E3e7QNDV9S=%pCZkVuo5_C0fQwVJPgHX zjwzUzHc?o8mkIcc6T>(W!hbs7=$sSP!_M#eu=^D@A!SyxMO{8KumKN@W!_2*6A~LZ z_jx`ZODbt`Yw^Bi$fx7Vxdj1+j4o2`h ze5k@gWtgwqcy$CUXJ>r7h5J~14=;8s;d3zZWxSv;s-y-ZdQ|4u@qT^M9at>f8oWQ} z=F1GqJ(OCmf9#u^qC*=ouyqkD{Xwj&vJ@f@*N7MAql+N?z)fCYM6l4W$8!*$n1Hj~ z-(l&;QzoQ~#SdtlHYiye^-X_1{Yb`5z7o~j%R+HY zEfrTn9v3$7l9$8s2e?IQV`{@DJ(N~9$wXJA8k;?T0qJTN$2 zn*p-+q-vs=W|9Gdr9}u&UuYxK;%XYN<^ zYj`QT3Q=G|Q!tl`i8Dk6eZ+n&_3XorIFSBJdI*ifW~E|m{|(n5Vx5AOIWbB>Si;e^ zBH3)<8EJY3lQSyKljrE{d!uSXWTmpM7*KG|>uvs-1wb8pb4k6BdNC!gF`7f`jFO6E zXwWya@TtO;ypHL`3Q2;7VM8DDJ({3lT%2dA@LC+&oVCYS(C0)RK$JjFrQ+&HYlHqG zOU0g~d0dJ)!7DG4zPenGEv;q+jVEE%s}{&85z6`k75Zuy=%0|I z+pFBTT=)bHKQFBTO@m#ae1KoA;2&D9a@8!@^hj(87}LqRcFH$VUchmfB|POkUQP;h zDoMw=rw8>g24`wh>SdOLFK^UCI94=M2X9|Q)qoQXmVCx&B7MwrhrY-66CBs?I@Bxz z`F&$d;boAG&*J5psh>tv7_rX~Df*HVqfhWVL~Tsb6_=LZt$8LcpX=H{r+5;wxRfXh zwvS}yK3b#hZd|MGj$~A=zBpN*nW&Gz56M8hw|a9Gjw)bOvO=CDd*`zSInvNl?wXI$ z1J`mXDzwkxN8!t`@walR_!m4Pk7l>F&GGb9h6>T_)=hI@?J}zLXd5;%4iwis_TFTG z&GoLi&;bV%h?5f2Ah6$I+77`!UPYj<+$NAHHvuraQ5R(A2Z+ydoKNvc33W`@z)Pn- zv25gM>(y2H0BpjEw?SZsQ|LIW@vIG+>OL3Di+X6#7%**a%Efl$*QXBIFG z=ZG|qz+CsU)?*d&rJIDUyP`b(+=vQ{@jKYErGcP^FcVKkp>;{n!GFnwrsBSc9^-Ka z##n+5{#|~#T>`7UWTpo^jnbemXO^-#np_*&{(N#hdSR#|6(yTwic1Dubqcnu3LC9>?S3vt!RR;|{`!M#ex+u~d z@L4!>DpX=Pa$!+4vui68~-$bdKg>@x?G8)K{_OBh#r3)TQttT zg9_<~fv1)<`A;a~#3}Yaiq{6|hj}|%&?Can3Gt|9|As;`+fCiO%jTVKn92cRDo(Bj zH7g%*0;Y#>SZRbP0Is5cysVT0ygtTAbPbIn#+XGmMi~<=Q%LCwM(shS;9vEy#IfNu zLLdZ%c+ak6+gk7Oc7H}~srvB26UWzC_&y6X4 z&G}kgVM$k2*q`AU0Maz3`k>*6l0{(W+bA1&0T(sPL|Ib7u#&3*Tksr2x`)a{S@FX1 z5@kZp!-g`+|0K!BD^z?P&V-bc1#gKws<6^r@K3Xrad-^D_$C z*$5i7M1M!$KkM>Y6Jen8^9j}&=^^}?KBq6~bC(fDKsbQT&x!HiwhLXSk7;<7hZ710 z0_gmlf^Nol1btS2`q)elBfk)GOow?JRjw*r+g|^iNuTP&F01}Vk~D<=Tm|2Zo4Fj-#ZN-sQi2Yy||9j=xu#Ye+LO@Icdj!-0b)S4gpktKCBupdRu=wbM{u3uf}8y zq6+1OIzgU9BLF)A-L(4kH|SH&fWvab#zgA*mbIJOx5=oLF9>bMp&-8a&4K{>5sd&F zg*l`@o}hnTgu6Eh>rC2kRprO(;@-~1>PBB%qd#&TPFdeEOyq;=3XmC>v=~@Z^pRI- z%;o!s$-}v(_n0lhtYbaU^3Oe`)}Pj zydvd*7a88a#bk>YSB9-rG{WbqGPm`|be;}$yDdnUP08*l0d@P~&TrCr{RMq?5BCFt z9yXli0M9(?L3mo9Tcb~SI8Pc*K|Figk*#hz5bHnFg-shgeBT>BvCZj4T>y~bV!CNq zU#6dSyPOk@m|!wrhS=4(8PWxPf`*@Q8S4xqllgMQ^^cq5eEMqpV=mib!^T9u{P zQ^AIcS({z1)rL#nE_$nni+p#GSUVCf=T^hXbbydIvaL&{cm(({{_p@AjQ}f#b>eY- zMSqra$HN;YrH4v}15XO4reFPE)VB9U!L3e8UvH=PA9K2lUmtQ{I$wp@t2MVEgzaMe%M1FF%XzQS z%*6LK!V^|k<1%=y#L5?hKRYybRq1lRm`1P$*}2O8M&Q@65k7Fi61#^+^{4tHw-t7n zw4Nww1;9t#R?vqh(TCY5oL1;Jd`#tQ1Nilb@@jxKpws#)eWOQRPRbirCJcGd)R)`4 zduy*XTZbwl(5Jpy^QRwtpI~IxxI5-*`x^qkL?bwLL3%X$vOb5?VY?{mQIl4ENkiZa z-ED|I`ei|?-f0KNq6$;_8UoTp_z?Jkk%!OvBVsDw0~VCjUv~6wG{PG(-b!D)dm5eg zl>J9j_J)$O0~h3$U4OfxhORU?g^wB)o2h(d$4P`Md=_l1dD-Q<*Kje7PYwVN?&g-H z5j{XRUB(8($Yj3k_`$LxdFY*e`k=nxGOjX=@~+t{c`*Ck9Q7z&*`U968MhinCiCTp zhn5~!r623h^t<{Cm-7w7$#gz_A7<{{O;m>--0-5EnD8HB_(0`X6JfTGtNPWIF5nsj(xQ zX1I0&R}(c9gp*v)9mo?W}TcRTOS8k7F7@?tFbm3J2bO7rT=$G)$3*Xr(lIb)*Qur=Vx znD?{fQSw!_)nObSuC7*>lP!9LqnkNNA^Orq)x7iBt%Q}$AN6(`=_hX+>kH-#s1R`|jxj-*=(sZt#6~28Hjd zTP*MArlw6T&70~Q+q&9Ubat$2Z^mJzZ+bU$b+mP?XkXcepM1Y8ZtY5C+FR4@&E{a! z|7&L|lkG}%q##Jra^fijcP*%E+1tKyZgMVix|H15b(vaCOBI0kh;+)Z*sq0Iowh zf}5r^2>B{;sCg~JMA*f!zR35a1#ZAh11{R~G@R6Dvvc*(JW!Y=-N_&v2c` zriUDpV#RE7vs`B3zPYtQpG1bIl8lr`nx~S4yDsw;NO{SL@$=^EF90<$tv+O`bSkL_ zOf^m=^?Ppgh^f=5q&~)Fg_#^Lj+2YK85e#Z*@6|*_#hb3d>UBfVj6h2A{~>0qH>1; z;5Z1rcQOo(5pKr69n=H+rm}D4&3u0etenMtNPa@B#~;s9o~^1O2aY4RJIqH~+R2xJ zw1-Wfc+eDsdYHQp_kQrtiPK=5`^8vs$0jSL04~GPV@%Q4#tK1|F|@jz zsLf7RtEt=8s;P}#YHDP)sxkW~w4U4Mf3UqHtX2r?^=C8aJ@*8_tRU9lk!S6~FVP4F z8rCa)ihf+-wGodS8-&|g@1^%>{299L8sW9Kg%E!JowZ#0VGv_U(U<1_bGysdV)A1m zjsxc_!JhQE2H)%#8nQI*Cty1zI8c&Wy8iqoB$03E5wKt1QfqYQ8A(vT;!zo?%l$Uy2OV$ zTR?^r^MJGT&|i(-3NJZ(ySL;5%$qi~t<7xNy{)HvFMCI{X5bx1=mF#L`+8vnK9$Su z-T6v?uA7a-vp$TXq;_wUJPa9(+;?v2dli4esEMBqU#!LZpmFFs->5kCvL!CtE~Ny) zrYWJYI}dJWt9FOEgfFLdH!kse4l-(Y`yZ=y;}Z2wv~IYnf<1mZAOrN4O1HiUCqKU! zO8lps+I>$v0RLAeDjm-R!HN;MfeoAv)3 zmHYpQ6LmdWfyU2JzN1!;u7LDW|830~P8dgNSX5Eu&Z;d|zPZ?Rdut;e4@T>r0Vs=ybDq6)aS+hi<&Z1}%SPc=qi)O>yF zQGLMGac-xlVwgZrr5`)~uE$+IYdhz5YO4NuvmSoIRX1_vi~xb_*NkqdrQ$6-f~%$C z6`2I9M`C{Xzc4s3@CjJ?z$Xg_^JtcMhUBMWSbpFW9#RHAL8$pZ@uFgaD5-ecE8&in zR4jdHGW}5t4gB3r^D&du?Nn4fM2Gc_zq+dCO2haYHB^f$^Ju70Kz+3dYN&vPK|?ie zwjFKEQBkdLZaGvf|9emu3nuXYrlMM=b-aqGB?&fA2u)C3-O38TYiiH&h*CyfUHDAn zqIy0iHmAgo%PDcqQ|8eGLf9#>{tAob2=&8XLm2P}G8k0)%1b)9e~D51ZX%cThzAYh0-bm{zw?S5d}C42=z8 zWrS2%JVB`~f|fHWmeZ8qVk#>5h{LpHoa4}#LuLb$dN9ohEUN~?Nj+yF2)bAW%)Auh zeH@$_Q*PzTTQgOuyUlu5t~XKCr>82_8Kh$wBYD_-UY)AcKZ10Ds{v?O^nqPOO$cjx zU@>V77TazbYKX^jRnd7^Y_sW>s|<#Z{^1TX=R204rz-U-z^&%Ir(E8!*G7Ye@K#yV zX+vZ~SiRY(0DV18sSMicHbZXvbfxxs=)y)D20I;@4v#%S%8*W^8`JTWAV?YLMhpvm z4n$Cny)!K&$+dMrp6NDxV742=z8&6BNGY6A?*o#V}y9B!8DnJ4EewhiVhU?5|l z6W7mGYQM4Jg;5rkF@v;dWUf+4;PK44Y`L80CY5>&Nqd_nkTX{~snmubT}TuDGl@I8 zAYmXu7As#EA{)Z$vLLP${gT9u9{_u|X~kVnD)k1yaJQ)oee@)3O9m-JYNPW{Vzve; zL#m^HFhn+>I)BWe0#0v}<(>1m>;3P$#pBZid%0m9J;0(7E-vI{Cz}p>9EL_{V7baY z#3pp)W+6d0YH-UTe=XM+`{&WyZ4oxgt#42T7HnBB8e)M*jB9)ja4eKsHT^$@{%^>xze$< z#`VVuzOTVQmpb`f&DS$bW75#$k8lD=1}rd-rmK`G~xP++eInt>*ze%qHV6;TfkCc3>gD5`);ARv z*oJLAxiEkY=0Rcms>gg_M71%qh# zMJ6Xe3JDs!=pi;w7;{^z*3Q+ zg1Bk*B%X*^yh+n^1TRdED<~Ahga}phr*hZTdjX`ii)lJ7d_tOHZ-p;^I0AY8A%Y68NkaEto|U?gZ1!t zIT~}>Gw4^JlYz#&S`FP9* zd8Y;?PhwE=@#{gZkCbAM~eF8SqxK3R!>7mu|z3WuUzTrW@ zC6!c4Vkjr5qhi>Qj#h|e!&xu9m|7=R&5YCgscihO7fKGyf=+;auuB-L7xhg(U24!L z@gvLV%ehX*eRlCmyFLr+v-{vB@}Rz)dqh+dECuaUn3#l8I@C&qEFA>u^COcU+x^9q zi7nSR_UhA6H&V;>r+XPO+QV!1{$v*?0j(dq(+y^SQpaYlHoUwsqi-_k3|FBr9T8*C zz<3TCQ}l`Rks#w(6|(`R0i~fNhK3TKhSt-my+gvtacLxm0S&Zrl&Ls%8^RLCZEjRO zU|m$|V>PN0x-s+Ee2}IvV^m2DlSJ}Cu#^a4*$8E1N?c88oT#QOnxrq*=rgccvbhS@ znKz)@c~9-wv+Lzjlp2b{&5E;bh}#uj(e-iu!HBOj&L8KK`kZ0G_%;j9Rriz8sNyx8 zD)#P}78z{%V8WOVCvnFM(I^{148M!KiAaNz?aEze@=St;C&R=1kiHs$hJ8tNiStP| z0*3VSxn!3fq2b2O=vEriH!2b|vKV`dA^mGCK_gGXwz09~`IX%PbX4&|sBd7{A9oCP z8as6O_^q)zt-s|}6*yF6!Na}@gY*g&sxf(UIB>Zd*+a z&z6PTfH1!oA9;1l zTV~9q6Le)xAOF<6657CV{R>FY&@7BX#^$5o2T^GnOKz1024HHr{uYDsq&p}bSwk1( z;~llV9%DN{cSP$oUq~>@{hPblF`0@tZ4LS)25mm~P=*Sf%59-_d}INgO&@|*cE7m+Rwu_2*R3<4ZR{1dQWv{o<6-Nzsev?&=q|Nb%UtP(nb9Xf1ghU{k}(5%1J2f4W{v$rJxUj zz_MUDK5QD_Xt1XfbfCu^mC3qS*H_)3PwKI(e3cYufb|0}zc(&L!Iuv`WpQj58vV?9 z69W|r$4y4z8q~w0*_D`sh2`j&(qF*$B1eG)d!1t)@NL1do`}_^>D`F3>hw3xR}H|G zDA_O@C<&!1Y(n~@3d^s5tgw`csQvhO)PCC(Rg9U7Df%iZ_hKkq)TUV*vuQ4fDSiVI zQ+u6ndL(9()MsNhO-5bIUSMXW{rKlf%Z}%gcuW#g{7BD4zpoUF-7%#{DxE~Xbfdpk z+LETLZ0WXC+0wy#wrLRkp%aC5JSoUs3+k$sdX2Na*ZKNHwNkKXB70NZ&)X1YpMDQ- zBEiT|-3fTjb&@o7{l`K9GyHQ=U&PB|1UIC>Auxw3E47eK{J* z)xZY@ZduaFeR_PB%mJh%(*Y9ByQ?P~l!Q3!97apZ|F*p*S!s>~7P=8iowV49U-O4E?jN8Vk*rtEgW3!_rwCJXb zC^J*-0~Pyv2_y+Jv9XQBge=eMgD+>0i8X77jNMA7kzAGvD{J`$=ngI%&Ia~lnSvI~ zCFjq0yxD`DpLskgnyh}G8$OGz+k8G+u;=OpeU(Sk{rERQhn{oB&s4NzP2a?&G|p>C zf(|ajk4v!?!~rtY5!^SVA-cCwVReiOGs_<4T=O3045kRCQL&f}rW0vwPkA}M$#p{8 zH)BdIq5L}D?XFAi;|k#C`S`~@*nx$09(OqX@plE6jwO9BnlP58LKP>DE%8b=ar+)8 z%O9N<=}B&8)etErXc+MN3=QEt5mzE?tQQYbsW6!eE0L%vKCXl0m(3d6poR3zCZ2AL9!&47P@gYMH&G9usvIZR~0H zf@y4L5TU7wk-w~GH8@0*4Jhx@00)l;6vWfJFGmgsS= zq$!55&%r3J?VHIbgxnqw8RLAB0i(y}j+PnSeLtp@eY`TjGSnlZu^j?|T#!K&L&$jCGh{xWJ)(y)AI2(CEMd5*TR+KI8nd)MBWv4<>Yh}=HL zy9A!4Mitv7)?WzJ4y*_~+t8FzKJ7D6$Q|R80>Kg^7z!u|-Ymp{MdaQI>fXq7HCWBMO_<6vDx`Y+>IwbowJxT*hL`7xUB6nUGj$g#HeNKEc4H#vj zlk# zvb+PpAXmze3vfsP^`eprug=ortnQad#jd_5WlfvfH_@Y5q?5h4`x{LsdohfpuvUw} zydE;9?72SBoJzC^{tD6`ll#o_c{w*RLDwIS_f@6n7fIKVkFwGpe6VfAJykK-)p zfqd3c9 zfS^}E&Wl8I3M#u)aPz8O@%kgY400J`uipoz!y+eT448CT#dmpSl|j8s@i3B2ZRJMB zmfu-{MJGwn!M>O+;tUb70x>{gSuZsCigd<#RH+(=_O4X8muLgXaX%0M&^~x>8D%iFT#w0lK_ac+1u8P1b*}r; z$sH*05-j~aTo?R0AOA2s(^>Rc)6TQy6sYABZ9ibs%o($iB-#`X01?Y=fatrN`wJ@; zo|4%@1e7_HAx*_p1jT*#R;A%ChR}dq33l-gd)T}W#~sNXtVs7r_70W?xIuKHB;tZ= zcu?E!I!Jv?-X7H5myI%zJ z6B-HUACLn#p}c;L1Ti#_QN`Kwsj0!!P0*+l# zJ{9vcAADf)B;(dgO*GwQ?wV8V^yqS~Lu!WuIuILd)k>>Mni+}>9)34<&aa#$6@oxl zxx3{z{6RyLYbn1HFd(xEP<~}n)~?4(73R58CsBI20CIC~bmt7^SJjIG4dI1ehg7mX zj=4Wu)M(bcb5JhsK!b)r;9;LbHM5KrW2D+;QJBr3Zl`<|o|2E<7m-7W3wqpk&N!O0 zC%IXVR~o5$$HU1~MEU`G4Ho@lvUu5=aaFAv@7xXur|A=LR(k0j9INL$?~E|Wd^-qt z-g5(3S5!#eyCwyHG>0($?<^p47)1FT_vSHCpPW70yMa9$7a3B`zh^URGW|5m)?5m#5d zY5LIJRIP&vZ`YkC|16Y1P?#w1sl;)Zml&Z;4niEcZ-Tln@}QcjFHYBIJlm>z^+%g^ z!Xpt}WX5&j2_PKJ9@3l^V-Ja^+ulb)Xf)R((BJ9wJ@cdd3=+Y<-D4u3Js?28#jGqA-(#JD`^HltzL-(b2;NJem0qF4t@lcW)^_Jw_Vn!GHU(L* zO0a$4R_U>RJ*eLS9Ygj}R5+4CU_xJ=Fe9Q7)(VtTFZHd_$9$aDI2P0S3_y!d7$=LL z_OieKd+2+8;~#F%IW`O?m(-KrKRGT6D6ik60V+;* z>dBi)1bHasee{OuF7-s){(aUP`htfKCsqhd<(n~VBhSfFpQjQ1HJx-><7U8#Ej@3J zm`<*jf~VK^^toIBVj?gN#{dwJV28?zk}o*ec4@p#inp)P2(XJFp|O>13*83gT@71Z z362|p$K1-%`6c=oU7zMO=c^_^CiB&eA8I*Xj~2c~hZehRZyGjv&4oZm%9fnn!bETf z1rq(GzDW65ZrSOS;hb4gcyS*i;}TiWdtG#Xrc-#nTSqVsWIPWbG1}eI>mmIUefETh zlL6DlB%t(;K3cW{>?|h2D?Di5)JJsD=ON&SroW1c0U3A$t8aCr8#?wRMDF)*X;RT(iFL%3quNyvb6oWvp zO=^Qg>9p^YcedbKAR57KDpoE!tUuhp*)!y<=bKVF>vt&gxE`Yq=x0~VI$nCpIh6tC z8Ka?k!a^GL@O@&6DlTOZ^cAP{RvyG7;#MN_`q3bopoy zUUt4%8IQws2}pTY_pZKf=hZ5{cw1cj;PBZv=8OJDU#IU@dfNPuN$hs6aHi@JeY(>1 z^+IP2BbwGfX4xL6;~Zk0{`5sX!0&3q`0mUx1^R{&Zco*e}ofXp-60Ps5i5LaE;x_LCEVri_xzpl|8z zZEg#1HYv@QzVS>^@up*^Xj?}!U7PPnq1O$YxYF@XQE`(aOM_DL=-xRqz$uf5&3Ys$=OV}IDRnfIq603Y<4#3h1|aC~d~Ju|C@W6;PPgid^JQMim&TGW zttDU9lzg!^wT>F=<{v5}ng%;?bfM{*8o=ucbOke9m0Rz*SpJ^VC%NL(!-W@d3dz$ z%XRPW+qq{qo8U!%^6#K_Dq-Y`>2LlWMtAX{t=s2Xe>Xs~B+$i6S{jf)serMjYF8wns{ovpkASBMxU2b z2O0n=8yKuXFC#eR2uWLi%Zcjiw@n-B(5xDz9>+n;ZBp&1QR>AYU7)N;FNar8hk}G5 z#iXx5`F)TwBuRb55ZMrB$cRsd^%nuka)XaXCMrco(G}i$2Qo+7)5VGCfFNZ^h4iPO z{3b{lNE2-opQO|roHTj!4oPv@B&Ajc=>qAYjN1&24PotbcSNb&B%IviK#Nbq%iB<+ zA11@vnxS+CTS(UWlgUcqaEgON8B&>=gi?3oq|00BK#JJPKb=tOxgcFgdV3N|{VPZp zNROx52}5KQ%wKp_V*&%rr#^b)bjqx~^ zhs9}dIbbMnB@p$`hRBAnx}%XQFf2Wx85IxIhVOhPV@Ww-sIg@!R~hCgCTdQx=GxuF}2aL_5C-;7B~YTF`sZ3 zX-?l`if|DNSrAiGjF)rS$wL{kfp35KyTqXMKxRkH^M|$S?np+JfBt}4K{i5uMAd|O zeRcEtjDabB{qO=zOAYDs^92JdU;`N70eo>sDnZ}rLA2u`z-PX}$oMSxCN7?T5nK+8 z?J&9>o^H~~&3M9gwVeuck{E9na?9~L@DhW#w)o~cADWRD z)t~aviQ(T1k$!!WFVW?42eVDlBvPm;+X7;>?$h0;Lb* zV*UC{M22SJ-?2zPjb{L#!;8QbcP*$hc9VLNbyRG@1K$nFS(LAOSr0K}f%RV-01Od% zBQZ2_ioaQ75XQtQj~kapVi=K~ObsfJ!FK_d1QTwPgweG*IT^NzBU?8~iDB4C;s}-! zL4LT=K{~X8m&1X6SSv9l z0N{E_U>srOWui5lGkzN4*Q*2kFNP4CT06)i>Ov$z2iIF5x_M2zji24_XKNOGC@d|I zk0j_yB|2a`ml>%c~rB^i)B=**a60Frq<>Aa(4cNy4p*wE#SNr@qKfEQdT ziTfl33;~x$Vi=P!!y08OPTYpDgf~dS)2q~UK?nf6K0HBH=8&y&vO)!fA3CVSaB44E zc_|UXauUi&Jf`A{#BJUBuFlrg>DKk@6k_YwVXY3=|BR11X?VxABHYG70~-|UAPqVX zCGaA~5DbQ_gDoDsP|N~;F8ICyybJ^I4ki`r?pjcnpdmWQCVdLc^Dzb!G>n&-omA+m z7wc@WHVIibh=h;ho!Sx@3v8uA2gKd7b}Bp{5O*~`ahHy>u*>J>{T5+2m|dXX>DOOD z$Q_uKU7$bhrwfp1DJtRwg~76Vyb1~j>Ijn!f160x(Qi;;hF4H=js`voH87?tQ3dnd zZvxx8`c;oT09}s?ZLsCBCf14v*+Aan(?mPRSs(54LU5t(QgQ#pF2N^1l+u^0YIFCs zQekznl?p5CTvi9+YINjl42_+dp{sS$@hmMyAr{*7HP)587U-)m6XfB=b5PcJ1+N^Z zVlPU+6|fq8+7@s_vXM1rHs@O^Bb<6p?1Z(wb}Dv4OBUiJ#xU>G_*gtMCIo3E(ZomR?qLG!peFoq+%&5{w0DXrY;kOg^6NT zk9hFhj2+L{v$Y;P2DuN4^{-GwPG#7{gbxC1_g&+Wemw?C19>%yHysv%5qLRISM8n$ zLdLh}fqEvp9F6yG@?aa5;N&U&GZ8D-fryv)^T6bYtf#}U0U=@^PDrqyiK$5y&c|Yf zD1b4gVG$J~Gp6p1+SllK=mua|Of^NV6D9=jg*}|kh>{^OOnp2xx4WgksJkQCTkMt~ zK;7L^-Mnpe^R_Ae*Tlszvv?0>v596K#K1j*k?=95;?Z1nMvt;SBO4{&akKGc*;<3= zsPAPj-Wx0i@6FtFnYc*JIG1Iouw8l_u5ZnL7{5BUcZ-;71$|u94zUXZ6A0!h4c;?C zz;Dt+(2i(?+weI=A?IVfD8I@vY+4wRk9E{Qb!}ikpR}!sqH)a=zsRIYHK}pBniQF; zs(Sx$d?+@|7*2m({G10;DV0Fy2jO7&#l;8dBhS6{s0;EmJ}-pGhXlZC8+EWPbXs4f zZve00RoFO2MPNFP0dXzC0v#+|Q?ASVdiU~!R8OIs7^3^7W!yP;5oeGGlvLvtRU4NZkqn8i?pDh zO+vSWo^EQ1KkuSP8I+HJ@#Ak`29!E@FM3ap(g+>*uzqTCWI`X>Le5q_o%%jqd#lyM zif7;mhS1lsIQn<<&FJw>FT0#~Er3Bv1Sa$43fZ6Kp=kaUd-8MI^4jcKNb~PtJP02c{6aZif0ZeU`4!S1#u(hLh=h zIYM^3IllRXe(wR74KFAWn8=r*ph@lNY+8RvBX7EVyc8f9FsWz637FK`lK$gyeW}?q zoHmX3{0Y$5g(OqKt0e>z{OfyFTJ_>bDIi)A^c)VV_QC z=!^8VKKh7<^Q_@yI$xfG1(g()njP0?mwEX34XRmb{WJ zfRom)gQ9C)`pas!IW;>3VCW>*$J3qyd9>|Ghv~#~lOJ&!6sDmNn9A3n0(rDk|JD2d zu77dao-}L%c|_n7sWo2K})AFBWD%A|U3`1#Fb-&T~8!%E*8b6M$!IaT{ z6&zIXEB94$Q7CQjtI%4|pg-NlZEwgTc{{e=rR01q*}w6q}>l!Qj3C z3=Rl41T0OA(Fouqpb$)+pwyEF;RXdR49kJVa*3g_f$2QTIRYP`H%(CL8AqkSQdkbm zApp1+9ollmgaYc=0e3=J0eG8Bhn*B{C|82o8l~nKa96q9u|h7ZQ4Cc>aOhYZ*c`-q z|Bf1gs`=;wjSkhGjsm3ysG5&5Bt<=3qg<$(lXoCZ^t1lfBxgfd1F=&OeHm#UGTJ6O zw_N*7o}|=0a<5u8Z?w;nNlImcbRo6bK1r#)LApR)pmx&{V9L%1DMM1!Z%@MELy$6% zCd#OPG(y&#~`rk2pvm%zF}GP{JX6a|GRypIIv%5@5j0!H_~ zp}y6Spi6-y!-m9WhLcTJYPNa%jQv-+yziT))T0LdRW4^J;ce6Wu1&+*8pf_Roauu*AjAtF`Xr1nAR$@7*Q3*vdLD9sPgcvf z_CK-2j2Oal&5f~5Ul<}AQ0+g)i{)*>ZtimX`@n9vp7(oY$jFsu;G)w2-7etZ{WISk zXEs@yWqElxOV!lgWn1pl688tRXzAP zmN5at;r@JqK9|CE2r%!T2w95fN!6q_>ZcLu%V+O?(opeC}uzD>QLpb?F60*mHHe>@PzT7@Y4AT~K zJgR2HoRFFxX;;?C$B}A1P}wV2>fpy{fqnr&>0sc*2?*bc*Yb6F+&A>#3I?r}H@G<5 zpukR=fxQ_799~EO3vvdd<{R9~oXEY%;1KsZQjbI*ME48qob zD=uXqaP54J3m-}VXfOm$k4Ej78PY>hbmfIeKmE*ZXLba#g4ua}-ivMf4>BByKDb~* zax)wBj%-B5H^3m+kT#xYHnMvr?FGESrjr2P5PXP>Fo2f;-Xe3+jdL3(tGSEr(HCdw zGc)y(>3U#l@0888UC8i!92a0{>G$}SZC8f!&$3IMkG(Jg2Z6xjm@!vC+@uH|EDhc& z9S2?jlj=#NcL*LUJmR1n>{uv{3j!#xD#uYi$Hpi{n!^y^O$ z8R2d_AL*wr7#E65S2ojJ;L=%G69gzDnke5A2f7Jeu$}TP6H^QHCzywmQV|$>+5iJ^ zJTYEQZG2e|;R*9vmS#91R{5Gey9w#T472GEvy-Fi}|KVYS`{!7ZXc zB!=D;-(7YL;S?FcPb1W*0N_|rrsC9X2uoO8fjs~p%z7BJ^sWVUxe2Or9decPY6Mh9 z*dgsD2C*wSc_|UXG7`$jOqM0 z{YgON-iSBoqZoOEa<861*SNS33%+|U)=q_eZ29eGD2;$KnQE4#G{Y}gI3+5k;nIo+ zP@G+Z>`%h9@Bs}QxIQn?f?PwlNDPfAptA@AAtPlVU%jE45HK1I>;MLSV|fwEXOmrN zD*ihHFHITBF9aZI0Gn&Zc(I3~ulGiQ;Q9(RI+>ee!C!qdQdH;y?CWT5Qacqg^$w`u zoE~SE8?ubGWvK8k9!Du+I>a??m;vbX5O@X8JGb}{?9&Nzw%<7j39qhzzm z%^g&nKC4_CMfI&wasW8r_t6W z(+r03f~VMr6^ni;^+C31o`Opl0JYM1vCtW(Aw3x5XpD;M;=nw6$A=j12lA0UBePyM z4~3p3g`NYi@G$2KEe1npqL~L#SnbIroAr2%N!kI|b-SDk3azVk7BUq47gv!Xb$H{z z7D$cNPU+0qjHW}+;|)d&6!UdLYDaoH*{nxnOWs^An}q^9?aeQNA;$6PbkpkJ=*P=q zB+$$SYb5Y6i-{o6OCRES0S765tzLV8UVk@>e@wAjCy+1wj{S#5#Ds-UZUmMH-S^LCkgEB0^xR;wYB%rx3JU6 z2T#zxft5sny5?_TL9Id4MbO8W@6#tejBF6tv6kp9DkdmEFV5~z7v|CjFv@9*%UvPLp$if8yLxDM&gENg_(0|7;pt)gKrK`LRDo{4rjN|1z zz56%%*5zbpF$f0A<`I?*Qj0*bK}G)7qc2yuh1Fl19Ostckz6PnbfSmpdQ^Wl*C}e$ zC`ty%=IMHocep&l44_Z+_xhbam+@i4C?|rqhIk3A%`TYqb3Jr^w}(1RQXup9t6~qorVoWel|VIQ4W4Flvi zf!Ma2q#h|5Gq=XDy=C}*BZiGm8$K7rrU%R?SA)?B}*t{<3#x&KhMh zI2PY0177idyETaI`EIf3Wl=f*4HO%f#=^>2VoL$-CvTz6Hy6;fcIQ7GgJ27j!S5Cj z7W^)`)R%m>aIkRt;8#R?nsq}g-MYr1HTcB<-J0eVEv>Dq(`}s& zp&WNQ5HicqvS-(>?%g?G7y7@M;`=^2xU3cZ+qZY`y(RoCjKrjQt7J^`G_2@Kx35U8 zYzMlmMOp}8P4n~O&aTci={2qG%}r068hU@e69C)l=C16TOvmaqYb1-?fY@xt=`}5_ z9cx-Tnwu6jC0kb6epuDC5S@r3`rvNH44vU_S=HRt(UR$E?Obj7QGD(lPC+*5O;2N& zZoWQkx9ZJd%^wb%bKBnhUcTXl;6H=TrE9; z7Aakvx2%ia2d)8^ya-_yu zVHsrviAPUCfP(tc9RT9^LEWnpU{}eLV!50X*nFsa`Co)v<-U}u+DmCYYB&Ov@V_xt zUny-!t>`@_qt8mILsF)jOr{H^)Pc02nd&hntGol)+e0-S36U!yW^{$vY%X{XHme1Stb)q7PwU4rssIrTF3`rCtfr1=2$Y z(g2Wt$AXk0Wu)&xc_T;}NE3aiPZ=T`!urry_CuN@X5R>{uiV_EZvncyZYZ6$4CKzO zejK*z&IKt$YE+d_YAQ}8yuA}h5!;>mgi>8Wx{&mCCzSeUkS>rOkMZM%$cC`?!9g6I z2@rDY1SSJstVc_B>BB+FK$@8M`Wr)JL)f60gf6^1RjDY7VGb_Kb>YV8O6@ds@87T^q~Ebt zhcc9(h2ICndQUy#W08JX>vI#xQvQB}R^W7SA_Ji%dtazbHt?}If0r0!2qbJ&MS%O* zR;?0^RVuNlrWeZbPh&d_hoxQlinv+YF111bpod_< z3P`{hqY@nU-<}wnC z1^HEi#h4ly)Q;CmYb4dkzry5_-$z*L1N3{@5r|xd0*hM6ek?YQEMz<)OF`fRWibBL ziNPP0k%I6mXrf0Ux8T*$2FMx_h!VqSeaRVB2wu76(nt)w1KgvGDo)*ou!Qm6Dykls z9#_+I6I5bb+#|faSz$m4KL(V<{x@~s;vQ9z^xcyTAxLzhjw>pwQR6O(V!}09bl+SE zK?Ox1it8dq7$h2!IGHG@>;{q$#^WfWAPOk1sKnrki^PaRo~P;``<`D_U(O^0y6@}0 z-}jx-P^V9K^}V~gx-K}rXjbu|>MTsTo_KSQ9_GT&n zWF6(7Yyi+l`6qV**u94G^qv?PRR|*C{jl8i|h9P4doXE(qtr%CTl7GY#&9dt0> zA={2oI|TD-NE&k$<$F-Y9#o;X5`P4mCthYjd2Fv;gJQy~@b7>NbVuv+6typ)eCuW; zKzVx?@WkwD5tLt_OVQBWYKq!xDBoI3QF|@rTNlvK+#1LjQ#6wJn9U=<@($te+J(AfjmxHty6M^p!N@>meF2TBoPt@o@IS(RhaEQlE- zVi4sjPLDj?QyM?^8pW@;SKH`V^{;?GFG&!wNMye>erx#Y&g+uqI)-_~O)^c5@i|GE zp*B%2i?RhVX>Cr$1;cZNth8Wi0alzg;t5TL=CmoN=LyLX982QS@mwJzjczS6_LVp2S8#jwEFzWf36}?40pQrpASljNd?!U83(@`tl}-waprC@r2}k_)?;j{Vn5LAne3 zA|50!7XMMHFc3?4W;nWa*S|q53^rT!nJ#dJlU#X1&QGWVf3}{7Voo`?*<{wSZH#{* z2Td>W!29_a9pQ-zFGhe98Xi56#`ziOu^=Tw7kT1gJ{=Ou?8YPUio}S(p^xQxl-_%g ze~hIZmvqjxZ9Gq1Z$hq#ZFKpbkW$2u@z{7pxq=K0xzhV|`A+^KmKI*K@kqR)T(O{) zd+D6pcxdf43u|I2;o%#P#4E~E4)39Lzo9&j(TR}M8Q9fBe!QmG(Sno~?a%TzbSxxX zY$uaME6Ni5!I0%s^IzH$QmwP8Bu-Iw7=%GUi@&;={z+ejggb0PiB?J`B*vC6RNBD)EYnUo5d@$6_qyH#Sd+ zSJYhC3PYZC^x<~?G$a%mXFL+EC`%RD(gra)5M$|nwaAtZ!&u78wx}Z7Rg|NOY^mgt zalGSH*OS$giqLn60N9NaS{nxVibl{ zFWFQQrzkrW+rol@$Bx2~kcMnZH9%Io_VN1VHZBHTv51VcliIMu%FAPP^lmQ1#-VeA zI)BDER8cOS&BkQ;XL@_*e7_>nx3&~kk}JmIRY@*4CQ>|l|E7?R-?HhfQLC4&PGU(1LBk9Wx}&&*RF(@H7alI~NDVw{yLIAmi^}?FjV&-L%mt2w zBz%{?s%;DDoPt2@j6G6?xo|2#bMhzj!?nF3UDoDz&y3*^?2#eLANdTQpLI_d4nsDf zL@R15H8tjjLoH9xhYMl}PuheMt*CQ~rL_3S0zUCdEa49};nl>n5QV?uJRPQ=LsEXv zCRL7Md_bs&RW~47Q+)2eSUTs3)_Pctjd}I3s!NA4FE6I(nUHRlrJ1aU)!2|1Zxuef zxp(tOtWEE*$<(DqJhumAU2zK%ALp;;tO(gP+H?}DsCJ8r)+0VRp9kr^kZ_|-DA9^C z6!xc-6Ayj0{4abaqQzmKc+Q%0=!*dvH#p4~6aCrh$Fz6pX)G<&KMjs7ZOm#Dc zUwu*0Gq-0St_y?js7)r3iV7|sJAA?K;leZb#L_u;wGyjnB}FkS4ClQ8xhJ}}iy1d{ zq-dqg)CAYGPfoH)%ySigDHNyRT-^q6c5?+V#MSMN1YfU()zse|Fo0yZd%MxVvHbgWX*(;Q!5iyB2lM zsc&3S_ds3!19kN^b@hL$tNT-3-J&}8)GVy4udBP}fd?L_xgvtab@huMsB3s&@$#Db z6@OY%_orpcix4cXt3!d}j})-320?4aWb!@gXDsZ_XL{ ze+wTqzwoD@-!jwx?1tMc`SV7LDf%BG>GA(*=spM%@gz8yuqb5z9wxvu|DL0-jp2RC z-{Mcc0U{p4Te#{!-)({sv^x2-b>`}|b>_-}pfF}d{2K|Utq=$*o*@oZNGn0Q0|#MM zXPmL*M-@~BCQUZOyyeVKHc7FY_z+D#7s)Uqs`y_n_5fWXi55Ec#g!fSW_8IU&MIO8D>(jm2?NT^+^X_;=!1hdTV=mj(^P+oe-IWU!us)uF0Ejp3>C5!XoA(Wl zPk4ExCzr|g_}Ab^+C`8MY!niLzIJt$n&3+au%iJ1Jv(}fBFMWA4Z!O<`(GA}8#D4Q zaA&S}pi5GaOn0rrucNhd|%% zAt;o2b6+etj2T4T@Zt-PckZ%H*PhAQcPT4g+go;Idv_s<1feZL5A1#)>4FK zaiBGnS{&$9Lbf`;=1+C?4|H~i_l?`KnGD)yRc1%$K)3aK?q7u%+tt};wr-YjF7IaR z=H~A1-fiyX$$?CEkGx=-qE7xrr=D%2&30I0WE6X1N7Y3i0$mcH5pI52kL3Q{W#GQY zXc8ahCx}E=Yt7U1@%>zsyKDcM<e0ZqM9dD# z^A}G)wGlT_^I>U(@@;&Mq7M9NtHLb}LeA#4^Jtr122r$^&o#F3nZ2!ahzhwsV8{AN z{kQV?wN#+*!8tIHI!Hdg`&Np|MLvPQr+l(jLKV^Dd-yCBXabRWs*TUUDA_!U+W0Kc zzsdUnpQC&mEN=|YfA+bpTX@W(wy#4dg3WMdU7`-uU{LFn@8GkL!hje;sLT*wH28k{ z)h$|=sDn>aREBf|FQ5RY>v@8r-ARg?DjWGS<#{N39gp89(N{}-8u@bnJYUa$p`NR4 zW1$fm`Er)O7UOJ!yhXh54J@>kZsXHc$mmRC8=rlRzS7pucg(1DK550$c$_|nzi|{A zXo&JWK?V95To}_qlQNXh&2TSkn_HSnx*Ilp9_P^}@SqGu)jZk+E{x&PCKzZkJi!N& zJlfP`14V70N1N8#cUYY=1Gm#YX#OQk?m8ZAg7^pGh;6V~t~}cGko_cFG#=-}T9P3? zJCE{P_9j`byXBKS5v-q6-CWeJlYIC6s%`8@n|#H zJX+S=?_u|aqUQOOZ+(cO=6O8Y3}zjoHt=Y(TwlS$3Qw5o-1U@)W3i@c8sfKreI7;4 zX}y_WSB1a@l)sUp=1SbsQZ_(glHldag#MF0c)p(Vl;{0CK8Ny)n_>PfDaOPa`Nuc;ybR@N9iQXT7F+Lx z))NvNtxYHqk3wMpy?7(#Ti4h!uSIK7zI8p1HVbcsM^*8~x7ye|b;8J_tMPl<2t+g$+#&CjVmJn&WPPgj9S@wYNx1Hz6Ce%XuCg1<> z1g*D0U{kx4wKk0YDPd@#Y98aSU1tj}v8a@!sAZKFF3Ue*3~9ey&!f${c8oULu|k(z z@}}5W3DIT9@MyD+moXY~(Ode8YA@bQd9>NCFwL^Ul<3&}DwMAIAx%t?E1uS7`Z6^3 zjLpt3uvaYEA4(x%Zv1ZQzrE7IoH@{q=ZHz!@-T^^!uJSf`Dn$exJT+C(4yi{`!PXCL!=D4+nuE z4tj?V6$L?lzpmUxiql}ox;#PqXE_qhJ#q32IhB_vWSsH>tye0})*=%GxHHD%u=Y zc>5~F6%ai&(alDVu(upMYCK};Gx|qmk z8sWE#Ur&dn#;!{);xYfF8cS^MT8cWVd7>o&Kgcv%ffab5x}K*fPnY-u8+(K&QZy`b zAlUDDqB)VoHua;d&du|5wI0^h8s!;w**rO4ND6FIHs~h|Sjy8$k3COE_@I8R=fjOO z;^X4WpnmD!MG+N3yyHRzIa)OSjUqbYF+_Wk6unYOg-z9SfzEy4@!Kh?Xa#YTj4zZS z29hM>NgDa5EPujNsI03V6?|2p$YN_z)kp;wCrj^B6syt@4_+JZL5k>-?-dw8d;~pG zkNUMFrHkgq%2(Jt%MzCAL%S;e?XUA@A+5;IqHkw>M5Ei00>eERX!N5B^}zNk_B|@l zB|c-#?wzME=rZm!cTj#dn$-JwN&z|+A0|@ zt7La36nOthhjqDLx`nkIET z*ky>$>T4q%aiGk!@7<`O0-aNs4@e&gWp`JKhFI2|aNd^5W#dwTPV$(=F{SGadK|Ob z766Cp{QO$V^HDqZSH%X|h{Ke?DfLy%20g(-P8ywk7rLN|q9k47pBc8e%D(#x4mM?)zHEBazusxa_JW#9 zZfxTq8{I=k{o|B=c2kN!Ej1MMuaMVhwgQS0E$}?K?tt zhwa~q;l>9l?yBeGt5?!Vhrj<%!m*(vE`wJ1y02763OK37@D-9x6eW2d<(JBc42$Q8 zOP$~YG2~f3$fFf@Nx~-O_WL0|P%b0H7CTmhEFCXZ%mx`mwh?~oG9IY7ONwW^X7#;% zKvpYT-1wN)Wf1pRx>DP=20?@U%k^5GE|I5E)>Whb(f5|BlGQ(YWWIE|4{Mr-W^k#{ zk#5&RQoHr1Xz1^n_Ywd3Cuk>03CbXHpLG3G=?>5VRYGg#lSYpuDcW4w2-~_;AV&-R zQ3gdh{fHwS(6!5EDSSRzi`)WqU?p90sj_@r`qb3`gUXg#rnjw46{fe1lcjw;TA>EY zd31Gh{kpctd31H~6jMP&-BmD+J*KHdqj*gTr7RvW+) zYP$&&2~3uJLOgvd@ymyV1v^BOmXI8Avz^Df_($acw4~7tRTQ;UOMB2HPOQ2l#x{M~ zU)=_n;2|Dc>Sn*}Z^C*`(eR6Q50|O;6D0VxBSHV!nkD#PSX~pL9eC`&Y~uK04!&-R z^8Bw-74s!R1Rm$FVtz=*=$vjmTCE?oENj7N2zka^S%$W+Vu-_IPxD1-EU8oxB0o>A zoVdoeQxV%69Ms*GXS%maIjGS9P6t!MSIt%MC?wvE=#f*Q4Q(df)F%A}#)|Y;QZE5q zvF*k(G_XX>K>r!ZlT_G3XRw#sSp;PkIL+{AlYEBv@ef)@?B|l5$C(F>BTQ3ap9apU zEZ>`ID|ws?SLT5Hd$x*;3?9$9r@!W&ezo%-Gw<*1{#zr-!7j2rm_jN&tyZZOd?=wh zT50p7hhFs1YYCOQhu_iw{*W*tubno0B4I@6J1v%`A)sGj?k!WP?6jc|%ar$!HZ)b{ zV*bT*ZuXX|7JY@Ge7Vo*aJfs*up5X=qqO0FmAmxYk}fdqIX16(h$m+`OjQ*Q(UJ-m z*6zdjTOU|H+eN%{wu`vThjq?&?5ExSD;@Tq;V9hJoG$v%RHe#$r_F*&_4$)FYbw?8 zOS&X8$+IVl*h#;JnFLv2J|wPkr)!^JeJf9Ft2Dxi2+wcD0*W&sP}K4S_)#;Tm9d~Q zv$a2$?auVrFq9b~J=^+VKix8pN;8)pv1ydKgj7C}XF$RDwLXfuFWc3V+Yv(WSZ^;D z4<2$Bi~}NiPrl#*Ci=!0;amN8ggA;_?iR79{0(vj3gbS9`}S)V z*0g3_s+XEDQTSzYNn-X-v`&_dY;%Q%&)U@$lN0Iw%haV_2F@0R|V?MpNJe=9-Jgg;DG0~ zr5aay$rO$7Sz#TtRnbqF0~D>VlD)l!@RgLrvnipG=Zb`z5g)1 z1sbMLC9^G6aW)Giz>smP<6N{>VOOlCs8xu$D!B^V1iJAdJ!#q+@)9QkWCqN8F1mbH|EkjcukN(_AIwR96Nr&6i1>Hc$EnC}I)3 ziCw$glAvLirIX>9>G%U%V*G(;l|Nufd&eKJL={L;M>*m|6*~B&J8OU?00l=U1%P9W zJBxuG;Er?34gj(0LXgxhLV=F>D(RSTO)a#&ix$P29Y=Rt=Xr4W1YrParg&?5hRle=k)r+gmpajM%b;_@=X_=PWoAv2M1%rJbcdC&v`ns z+r?bZKPSRjq~&D>fh}m(}+#iNF%mrSni?Pj&ix|e}ew0Fm{ExBF$D2rXo5r zpme2bq?0zV|JFFNVo8VVutdNRnM~x!R~c<5`$a?}t{Bm?xGp-m)0KX6>@8Hp<%1zSNZsnBO3jsY`QDITDQ%f7s(+p9PKGt=4B$Y6x zH5N0=UrM*T1u1rd=X1gi0i9=gJW;E=Tb$##6|uXtXybfz1ekgD1^~tT(ej1DxQ|^U z>IGxSJaE2or{!)5EEi8%uP5DAo?E%xZA0`%k_xM4CuFhnf#qT3$#iyi8dz-$o2o(X zcy2q7XS+CA8j{7!6>5kF z;Vl&OtD^?6w%N)QvEq4bp>o&ID*0q>tI{bv#;2V;31lUk;+!{sGXkaFVp535XwY)& zJeAC2{H1oY7s&g6ik(!?lm88F(jY4S3*4l*KP<~0@|+>Z55kcfDw=6SN321G3PZ4x zfb}nJ#9)FlT<-Op9s1bwgXmJiacns68A1&8e~aK;!ZBy6J;R5NdNvS$<3stP7wh5E z<&F!LNjfOu`8YSta_AdpIabV@vm85!KK6mN6;8f~KC5ss`7ICLGuwS{@jRQyW;^8c z>1@Zdp~=~fX~V~6U!7}X&)EMq*9I!%&tHXU!{=ukIZTJ=KgYEZxwRQjaCQaF>|ev9 znaSC~150@NI9^XN*Jf);9u4@?Ar&6@gw+Rl@Q5v+X+e-U4?*HG7F?A7h7L_k?7k## zrYO*9FId4Q$B_}?C$I3~%i%r;hRrrn&RsM^BL7OWOcF>Ao4q0=^B_XxAbNhb~Q*(!<#DsjL_(Zug)m=EXfPtim<4f9}b zL5ePeHuqFao<~!3Iks6g^60?rt6N>#0sa7qk?b)33_@hK>R#aRH$Zv5$m4v@9xVKx zvA_y(w^dWLC9T&G!o(0^?tvJc63j}bBrpsW@Jj?hpHn`i7D!ng(crPw3jg}qfXdx7ZA27!fXt*_6NVqJ4 zP>Pi#j@st&sF-i!DTo-)7uxLbRZ5l5$xTa>@VOjQNv>ngAk!+I>UfAQ3KccNgKzTN zIev?xwps}Oo}s9kqP7~!SHaDDTWt&F5s;=lZf{T&sYTRwzs6kPV&31vKAeS2TvLjMvl8%VH|5vy+wqtk0cTTLWr~K^ zNB|v@Wev4C7LUF_zDjAE%W6_Ie49q!CkD$P`27J5?d7-2d9;mwhSX;6))bBMw_t1F zLz#TQ%9)!jAPiWcygiv8f5+Wgq7}F1OfNaHaiNV zHaJ8-LgrDlZXQA~UDF7u7O|=P zTCj9Gz+J{sP{lbgv+`BIrsMG(pSjWA8*9aHu=4=!VU1N1T8F;b!f)%r{sY?+{8J)D zAKH$%w@48OE%~WM2%-GPP|1T=PL6(;4BR2bHMpc}ot|)3ijHc&Xz{P4#chT;VA2Lg zjkR^{O=}%m`Ts%#-(_#oF)SNpl>#@81jy1~`Y0l$Vjy}bNnrh=i zR-+7xJZ;rU8fr@?8`oi~?x)Df2DI@oHn=z4xwqwhiZ;|?SvZBIuQg+{ zWq9aRg3!Hh%g1<|R1nU>(R5kc7(e)IqtEGIJ z_93{5@?|`hwr#HL6PPOnDRHai3g{eJY_BrLR{Cb8pNr)9ny|3U`ul8((z2u+&hdG- z*1$3PCCO!szp-ttS2MzB_j&Sr_S}l?m569YS`WhiyJ&(4@?W5J1lrYirT&iNW z>ndpyrV=37S^e5v{4?hkA@)wmE-)zaAT>&1$Q_vS6rd(r&7-SoRnIHG7G&J2T4f=w zs!a9aJ%r}z?d=EkqR@}{Yj3oay`p6Wog=xfQ4 zl@=DxUR+ZON~@rZD_8EV>R&~Nz%$!Y*}r_+qFiBli5+Py(EBl(&cW_>rBG;c-%wS| zm>lA>)hoADX8Ha0m3ynQbV*5#D-;7IphAYfx2wyHbt_Jlb!*GE@o7sTR8q9J3LSn* z0zgSeTjn9)j2z))Xv;u$)C0bqwIK`>sU|l^u>!{Ck;WQ;z>YLSLkL&+d>lkyITR82 zGCd0A^ zVn!KQX?&IQ0mywG#@8y!^T$X~iA=SZqV{Sm&6EcTL*G03E0B@8K@gOu-~6L(Vfqxy z-9&2w6twWQC~AdWUQlVGe^j)7BkR-pb!3@z2R2Au{U4S0y*w;x6mxAUeZNFoq?M23 zi`2=lhvB3!0$00e5H#;$!9hRA4y}=GN5O$si{rpW!Em?Rz+00%w!rRvqMq(F3NqLb zK1iTBPov3Ts@vW3&$f-(#)opVoPeXODjoa*niM&r_$T;GtKFhP(~dOQ9Y^{{C`pyB zYj@Ihno$zhm7$M5u!#2UwG%o<)Td)K{j(^tP;o-JPAfOoW)w_ofZiWX)?zbcY?xLe z-H(D1KH%trHmoNdAag_#@Tz5X6q`)1qQ)PL^^(qQ7=fjzT$F|f=HMS35@$Ej%%D3ixhvM7|q8)c)WwKG((ffX=BAP8N zbPU;wWA47q=PIz--(q)KIha915Zmf^wp-M;ffoxXUJ7}PesuAi#e*xw#Yj2EW3=BT z5TglUe)yR*%tN+7)3@}{$UH`4F4C*Q+LtrUG12x~D{BO14g}F<*9HfCs)OI=G5VKH zCzHwNFM1ndmftQuu3#WdgcCEPG+sHbp7Zs5*b55rS;#fvqUeM!KlL~nK|~00_$m-O zDO(psd*$+jPWgxuYq03`&7!y6MQ{8;(JP%RezohL6KgqJ{MDwFk(8$kIsGbk?x!s* zd@Cx@8UGCeNm7Std+Gr8)QRbP>J;|W*|MkZlVOazJJ+;2m_)nWFJx#Wn*r9*6b&z) zg}E>rTkO3ezVrm{ups@eO{uZ?2N;8zn2oKJ|0%qU*C0ME>Rs>4w|3cQ#ReipProU* zSqF=d2&0B4+GW3W>Q?XC{gw(eY-2}l^X2SFNBVsF!CV^QJkgX$rqQ88!7@OLjZL0t71y`a`u1~d|yA^1nEQRBGF4!Y(xBGS&9yc6FcDfU1Nv0)q}S3&NjhK|(!$(s|ELk}ixw z5xUS)>C&09C|zM^&{(+1jwj%ALcN9DN~Ew8*JdF$TT$$*x;g+;^KrAAvizX{wSD!AI@A?zdkp;((JffY)M0F~hKos_H<;}U1+ zUH(oEZL)6gQ0}%Az1@m(L$&mJo@h^0f_Q1SB-Y3xX*a9vxK0Xa7fl-C%Ly$d3KJWg zko+ndoY0Pf4f8w|x?SF}S&^raojy1=+Ntoo4=(uKVu&u;V7Y_e?xR3FQ7e|Gk-vJd zu*ri*HY=E-;T_nP0xDrdzbgW|sEN%08x^K39i$WYvfZx0&r>!lU9y=cJ&!L%!`myM zV3bEAxLW0@uvT+!q!A0HXhk>BxGQu3#ZBmCwvV7O?39OI!2yMZ+6)#c?ezCuW%`u-K7^ZF?f7dRFy9-8hMwl6v@7 zGSs)8u8k3m*tW2f4+co$C;f;m6rD&oOoM1Z02kBt>>Q)}x=nf#U2DgJSX8M4~p0ESS7m&vqEpZnM zx_xF)`OKi1#&dX#3+~{8>e}YPK^=v0Qc~ot?yRbX-}# z$Y_RL->p8e<+QZS_RiFzL7u|--N?4OouLVlL2YNR7JkjH*!=hmc7 z7@p#>4nKDau7G~j@;IHA`Reji)?d8Sh5t2^vWAwnPJGKzvnzv0#cR_mRegxR#iT}e zS^E&U(h`km9^-wwAKKX!$V6AoMo;oU#`>fi#POw6(;jj3bly`Fjh<*s(a@`jt5J$e zMW_}QLZFO%MIv#Y?2S)WuD%+5_)a}ftfUK;BJO{%o{s~2oM==Ei3*N3kCJh7IvChh zB6d43;K}ll@B(heVc)I4g0!R~eqmCwE=m7FUt>l&iu`{-Q?3J=U#2O;p6&|qohyXv zZ@m9z#3W6)HY%};@4m70{>>lQL}8b3+tWCY{qhW4Ur`zSFAC0gK|`Qh!WpZM%)glt?I{vNQRf8MZu?;cG}3(h}-mZdpoS7514_9Hd~G+z|Luw9hm1YEP2^S>p}&$7cc7v390iGr7`5)l9*=FZ z;{hb5qi^i^j`1PECY8e-C|VuRYJuZNXq3xc1L7}feprj3TDwsJG^;ZY&8$@ z5Jvd=M9CqZe6l}B@I-nUBq!vbj@f+kH1d$$6h}Bez=yDDLX(~*am_4MunLx9aR;p=uABy=kaS>N%l?|pzqQ<(v~zVd=RZHwh`PRxeD?)e=_aZD)%lDd&Y#ENnBt9 z{!BK&cw5_qS3A|GXh^Kr{xTEh5r;mKsaR*H;_BE`WT?#k3RDfns7lT1-4ca{#WIs` zvlIKz`t?#cyTY(K@-l!lanE#*jid77ey zV(qUl&lLrA>Cof7Jz}^PVovZOmKL963W-l=_()5uq6FNmr43A=i&>Wn!=IKJF-@Bm zEBB6lJKVS6VbGNzT?Y_;mBAvL+CFcvbIsLW! z=ewAV^Id~%oA0pS`g>Q7r+@FV+3UmTq7SUQ-PK~t?G7Og1+d`1(zld?w%2{WJXBaj1bsR z*T><34fW!Xz8N8VXM|8;X3+7OL0``d5<4;SxDxO?MX_euwh~KLyTltntO0mte(W4( zhh}0ZR$W07tx3fY?L?e2XolMSi1Zr#z<{lY-ZOx7REjOZ@H##U#42Bq5? zcbc>@qrR2QR@JO@4voB__kQ<9y(XEh>oz{Uejq0fh}L)Q&UD9JqFKjEy)n;4&NC7` z95wfB*IcAX!J}764a`-U?o2MTs$# z**eV+)v8Q?F5A0DojDb^f;SvC%^#MpA)4KOlRi`DSTq;uS@P^>u-zPs((oDy6zg5NT9jQg$F;D}(z#=Syk}kCvfely9kY zzG`4#2@;P^g-K-IA@p=mjEkKS1{^dw3$U1>st@7=s4xIKlcGDicV0N;$K))9NzNbh z8T!KBs_6}goQ=HBC?xvD_N(JRya`b;}F|vF~$j{ z3T^8uRfR2x^$Ob`UPm_wxk}qe;~#TpIOw-(V|(kMC4D57K6pXlT`BK%-nPPv_Dq#F zaA|hE#1PSSb!{R_lhz-~pm9bJI5KK*A#JJ>&Z5CB)(At|Y)H6#{^CtAc_h?;#I%b5}{VcW- zzB(h0XwT~75J|sG3;Nau#5UgjGlSriO&{Rm&tWq1iM~uv%txc{L4L!V@g;5=ziu0Mv)s7my#J$Y3i#v9J{=2X+6vGF(s&I!|S8gP=UU zm4?300own2qyZp17UgMw4ZciwYnSKWdIuT!|9k_%cHx!q{MPg zCEY);|Ep;oIktiSmNtZCMRyQ>*DlRzBQ$~CL7*{bZ9V_wcM#Zm*3Aa2dk|1*L;L*} zLT~v!grGbJ+mlz>L@?j~?M(#5gA=Q;iNL#KaB@{*6S?po-9%dKY8_T}@qi|e+YN%N zQWx^dj8rr&;0b|Fi6+-8kig;z0~RV}#{X%I=Laa86%m41b9UW^_ktGSB}z&S>LSvGM#B?zwEv?wM}+ zW z=pcOu3L|vUw8GJ3ap8U;=N$c0q?oJ+W9iA^)u_HR$^$XOxt3BW?x7(bOiNwGFruiK ziZ?3^MmrAkeAJIM=pwyu^$?P3!rNaVvd;K8{mny6^tg9AwvWq>~+7<7W&7Cv|H zZuJj*r6Dr5#+I^pEPTy zU57Ywc(rk0h2{_>A7SNSAIc!3=gG?A$_?-lOoG$(JjLVuj#P>AyQ_KpcTWDjbv1Hu zO>n=|9hNG70q;kGcXd5awYP@!IsQNpEG+8Dr?icDjGV797@NXu43lwMH>2%&YE7kB zh0wFH*Z(YHaHz3@YPHNIKCA}rpy;V8jNlf^1Arl?{NvJ()zXhKXUSH5W0=Jc>mXeg z!WhPTa&^V*6j&>_>s2eJ#9C?aa=U0jRD%v6aU<`~mA4G=abOebI`^E21jdr@ZWG}S zS?)9?A|fThSJXujFMZvPtcVWC@+v|Y??NO53m~{E&_KV_2@J*1@8Nx}cZ;l#?&op( zA&xIa!z*mxz)&Z+N1;Y8qUI<{NwNw^w$3bSQLF6XBh&Na_fj-LN6|21FzpVC9PjAaz~Mx{@)uV8Hd+lKMlEKj{S6J(IsTl-`Ka&dqG@5B%|mCo z5^J*F-5~K$iQERy_ojth(DI1 zVccwhSJguK_4szH#W2*6$ibSz{92k4D|=vESq`B{e;`NtQKcBONglsj7VUWUyM6W$ zjxNf1GPi#EUZv#&HPHZS0>0_c!u(TiajZx%Ztzeo{isFqju?5I&KIxcYN{^g>^&fX z)(8$eMTL#G)d+tnjo2ZLC5P@tG}aL=K@mU_7xqJ7C8%*7D6JvF@kqF@2O)I?;kVUE zP(_PAx^lx7u}3 z4HO23C${`JhG0Q}M|q4s)Y;TQlPY@3Uxv(hd&&!aeMibnS%vi?Ew4MrcT zq+a4O>5R;ZeLM_2&&D^B0zrVzTAGQw^>|2VV|X|h2Z5H+D{crCzRIk`T7^@Y_C+72 z-~^mzAskkWQgm6&)aC9&haS|~_)+c-5h}ELZ(_9=^;<8*L5ePKhSU@v&m|lAqX8bf zm;coQwMZBV(z)W+Ge{fq30F*UjG-~SsF3Q94CA6xI|w>z4iA(kTxzib=LHCL7=ro| z@A1P)Sv+FVV`%ums%oBs8dC6;-UnM-ZaZErBA~F)6Q2pPjmqTp3JjQGaHZk&3{aEZyI#EPwi~1(uOz^0z z>^kjZ-hOqaLxwj#z1>bEdbrY1Rt(kkSkcVD(eBDUnrA0V2ptW3x|!Y#?>Sl^bc4>m zL$1$?WQkq1b8T0uuyvVYJA6}Z5-kAicE~vcsLrbnKG`u5?^ZsLtj0KkR+Qip(<@F_ z&UaI+L;NDZV;uRIu_^Dwg~JTwF*3UDA< zrVR5|a3IYLj63L%v&DkjyaqY+<0{n_a?)Put&~1;?LNX&11XHAl6P}_fQICFAjVxL z@QURdYvM(j3PmH8&MT*ZBH6%nHO1~E8)C-F91rp2?A%kbTe;zXAwJsG5-^`>3-QZS zG>q#xq)iUo#y`_!Gn(K>aTWz<7qKbC=jqE74fo5!h5GxYb%tqRAX+Vm;1IDCq5*n8 zR#Mr9i>fTTrF_hrq=$vnsgPrehOI^`npoWi=^Qvn!w>pePr~6E2CXb7cDCzMvOhp^1*v~6!aqe{7n9B7EOX8fhY0D4UT8fI{Oe}_1X?2TP$Vb9CZ%i4#mHP2`Eg6 zut$VC@IL-(7DX!aWR0lNN3p3Ch7u?ty8+Uu_6-fmScqs;2`3toF%sEwSmkMukT^+= zf@AJRnW2L^`gHv82Ydl_k$7Oe<1B4s%97-gTE=hG1cW^SVD6743vrG;rWM{;fC0 zG#FzZo{p~6bEhD0H4olr?t4)Da+>~JXRd2o&9shnH z+*9E`KUm?=H~X(oROpRXg`x8vnu`f9e5G+tHd#DDix zI=Nc@+y~NIb6j$|FvpdMKb_-bWar61xJBA-lfc?$Ie}q(G;Qc~ED{&w!5iaTH>K6JoNmv4mlsZ)`>Lp zXZ}0?=)vT54&^N#`h$n?UAf&hzjAaLKp)Ip?0n zQV(HDY1l&^YVy!353TVKZs;_{CJ$})5H4Hv>!KZ9-J5Wx* zX3EjXTC36%?pgFgKSYh>!2(uFvL}93g;pp}1h*UU$GLSy6|@>oSQU?kz-zgC)Llq+ z+s?R*sW^FcQm(k|oGA#4M;0}GB+?Auuo4M2K=pC=rUV7h5VUom=fzCU^|gznR_o;v zUMmoV*k#0h&kS<~HpGekd~sORoJxtHCv zr!UiQwr=g()wgx)*1m1IJ$)Jfx^>qJTel5lx9;lPJx#*%>JDRf_wDM;^$v6aQNNIhAvXh#Ya-CSEZdm(3mO(m)#l3*tUrXJvmU@~@-M@3a z8aFju1!Grm{UAEQuT}B*bub7cK0kyCxtEVMQ(=B}iY9QQd3b=wDf%zOsprG|1OGsU z`E(TaoWMj|1zuE&CT^gE9eke0ucsj%Pd4)T{v;LtN|$k1(wGZUG||E5DKZV!0}vI0 z{WS2gikNEy&}of}j0!(3X0pbf(Nv6ah~aodWf-kf5AkY&bAWOTAiVg5qv>!fC)8E$ zX0hBQ(bU(%Bra3kY0YHyB z6-|_H2Pb&~#$PW!)zQ&``|7i}$vP|6dvO_@04pDiLzE<+;(h#iIsd?4JSukm@&n%~0bRu1r4NY=)g$l6f@ z^VKIBV!X-U+50(nZsw`>N*?>8%`h@J$*;EOn62)VaHI7|Tg~GPwu3lZlO7W@-tco+ ziBgH#`qm_*5P7r}EiFxsb=5JuhjYY0pNv6nfKdk8&Lm`?{{Y?4Mk|0;}Ejf;<6x#~I}j`59r{xu#i z!BgSUcF@~8a4p|yhO*(VAZ`RjeicGm4DPAYP6xca5g+xT&1FsqX_JRaZP{-1ax1w$ z@h!W|D?k)Kkl>K>K-i(hP&}NJg`mYC7|LA8%-#3JGCeJXXXfr3zPabuY`!zMztVaj zAcFM4mh}w8fvhgV#_nF-o}d!(NKY=4?eX7=wGa>?rnyk0IAK)=u31V@m~78gB0w0b5|GSQ&^{d5lRE$P67Q-QZUqL~ z2flUl8kGufUJG$>ikjDxm{PN-(;hWN%@0w&Wj;mC4U})02ZIl1s&gr8R%-_ya0T>{liQAL#+~jl2g}UHX={gwvc}vo#zb2IdyR*=~R2qzH)EXMr@7!_k|hn?v+wBF&7pg@2`7k&TH3GAx%>vMY_6` z3U99GLn{ZWvf^@M!pYdJ9H6aN%kFE;l@j)53FGx9|{z3s69)Nnm;p z@qUQFUYzyXwLDczN1%gElS=4q;h`<+3P=DjV+8n<10Hd}(*hKq%sOb2qgOSnnACx+ z3)b~e@s|Ba&#Rr?UE6Cm_w8!SW_z;+&OLj(d$X%MySg*m{j2}@c<;K*uHNh(d|BPq zov{e;3KgM{Y~#STZ5iR+ye@UeAF#D$Ng#-W6I74DlfhC@AxcdOz2U=TDbYZ3T4WW5 zprB+!aZztU_~lVhl)RN}N85r;USW26sM|x}|L9k!fGf1yL!}lcnMwbx#R+Sl)9lw# z3f`ND0O;c6rnxMS8Z>itVl*UXR(O7^Ytel7M9Z(zh<*AjAXbt z9@6H%U2D5u$aZG;JeA4zclGv|4ck|5>Mf;gdxhnwv3{wpMn&TC4Ejar*;309MuRLz zbj*@D!r}f;5jye4!-EE-52l@|WJR)iS@z8PSBOjnZ=sd26&Ck>4hG2xA1Cp+jU)c< z*W^0102e%Z?S<@wp6Qk^!B?9*u(#3o_@3JYhRWMiXpb8KR}RX7+;e(e79q0uD}nm0 zy|VQ7d!;xU#Suh}{L{c)d?2|(CD8J9xMv;W;lDch4lj!3s{pfxF@cA8_{Y<*2QCAT z^Fdv^z>S4b3{@!tv8@_KP*~MIt}wWX#ZHwrn5*^#57Q4=Akw;mSh@t#E>;f-bcr5Z zgn_CNO05EZ02i$Ux=UK}V_MhaDKVQ*`Z9;-KR2I?k3@K8&S!*lV%3yKiIi>Kz5R|% zK?ok)H0dL8w(i*8+n0fFc1y@?jVE$(aDAvzG$bUksj%N+!Pt=L+>Y%@@DN zJ?u+2l+xL}!aB0N!BRCvhox24HGHXMM7Jz3h3Efo9hQdp?9OSr-@;BEVK_^oGr0N9 zRq!ZwD}#053>8Gq8xo4bVJ)d9pG$#bYXvYwC?&>Rm1Ken(yqYd)(&_s;vxH{G2G0* z3chJ<0bGyi#KQ)tGwdZ}ENcLVb)C1RHT8Ti{|_gd=t#Rcs?TpV)$rgVRUbD+pcYsh zf`%v#0lgnW&?v>j-)qG=W$Eb$0y;oLXCVC8HMN3+1M~(#iLRrs^emnDj0+DKV6zM z-!6QcP`?z7SWmJ%PJ=2>&ZDx;f|Dn9FjMMQFOdBt`rki@UZKbPWj|zKjG(O+9%7-4Msu4 z76>G4_g1St5Vgrd7aWBYFklV03$_{s`4^w5wD&-EwC8TP%Hj>SnRs0ldoI`jis?U5 zJlW*#x30LS#92~eMr9wLwdQ4TJE-Pl;2~44{G@(+=Y?&@*8onzj#x`He1=A?xRtF5 zoFIX&v!-TbtBy6mm2J(aQ`|Jhofw_5HeIlZ7U0ao3d#yE?|)!+#-rjh@Fay+`_;B+ zM8x>l*b(^ULSqjfr_ZKu%*F4EUVPnT&7!}Ufu3!>yZW-3{{ET=w$K5VB?K_B@f^m)Qj^z?%_7r_5WIGHSlW-?ZWw7J8Y>qwieW$rWX z%JeI}Tjs>G=y;hEisC|W>-L&U&H;B>+!VAEAD1)nU}Du?H{qKD%9F;>*_1a{<^&ttKmG6V6EaMCD! z^w_$!FLr2KiT~yWLsDQ)A$l>Eq}#ccck%N*LBT;8OWygzI5_9HtV6 zbyUws9v5qxVI4eTrB)xQ%Z^y(Bt*QfiuE0LBob~5$h=l*t73A|(|5(emP)ijI$gal z2ojMGnn7TCg0hI>+}-!TXHDUng*Dk1gQO3hUm{OeEMHQJVSVv7N0-mM2NMso%CN?C zvTTA<1nTp%!CeN$c+|!eYmom#g9`I2jp5V9tUODkezqAo=DCQ68{->Azn2Iw5*F=E zH}Xe&Z;J^@P?Y8ZW*s#3_c!vn+zri*{L!2I&9n79C>&`g00LT&_wgAh)$(8?PY&=u zcprZaNh99BvTfb~fA}m#NwwxtoYZm7g}EFgIEwa4D?|f#c|Xf(h%Soof(T-ZYM!Ti z+=iaJkp@?ax9c2#lA?*$1l-|4;g`oDsff3KrLdWCD9JE$v|~flmkMm34?$?p-CFm!!RADPlP%DcQhWPGx>1W?S{Yx=c(*dYW@4J zyXcr+D)1Cf@(Dvg7#7#{m*|I=jW|~8c0KdJ8XnsrX6zn(;tBId^do&qUz%mOr2W9~`=$x9R8whs zUrZGlLSZ@*#%$WO$!tj&b2}a4DIsC#oxATgS&7aU`JDM%!kG2+X_uNa;uH8OH<>4; zGw4%9{uoN1V&;gyGSyu93q#>K6--f9?fOiH|~N!R)F z=NmqfFy@Xs?l62JVa%O(-f0*_RBdgo5=(#h!ygQPmoVnud+#+2uJFQz3yoNlShQ%7 zsVFn1uC7i@w$7S0%iLII%#tNbM23I)^5y2vGGiJV8q9(+V^*$QX&x*y=HZ7QHp|P5 zX=-XR50@F!($Zp9l^N64)@B|nGp4=0-E1f`=FvwVHP4h8Q(0LlG}^j#>&%WaW1e{8 z3A3xrm<<~?m|U5*>KkRoJpJ_3hW3{k^UO2P7|NF!^Vh%r)zG0bW1f5NIYS?o8PnO> zsir!&ZQEw(3)QE(W+DDFG+t)RjvYG;{j1EFuC6Xa&^mbe<(CZ)mKoF2(}Q!TF@1e~ zM$EnS_xBqcP=C%|{{GYbH|ho5;6;0O4by(Kf^yD{3w2gF9ZGvKQjv=kjL>eRRBN1&)f*`6n^GbfS==M?o1kU^UXJ#KO*Q0 z{LCVNXYe!20FL8l9s>9ceg+aGd=5YJD8PT=XPyLzMfHN&4Dbj1%vOLG@iRLB{*0g5 zg?$3cWIvqFe8W=@n!n>KmgjSZ4g#L)qVEkIN*eQWW22#uB}~7cLaOt0{%?l9MDUmV zC0{i3twuS=7YtoW8uKP}s2R#-jMb`O_yZ(7$Nzx(^(P2FM}stIcnt6NF9YgY;J}>K^;`dtoEQ2wZNzaQmRA1K&~b@@h7x@sde>|)^tD8N zpWZd}(=1~aFUDv&0EqTIX80J=yvO@?7={O6y0n2V8NLAU{XRZ!$|{Um`q~b2eT6YE zy+j3bXN56$(>r&YC19)ZVLohHD~#bIHG9m)3S%C8aJzXP0niA$XkG${4f8XTvmjkC zdlmcyb1M&ocMlkP#{nPW>m|N`I(=GU%*)7*#v~1mqDus9!_)%wEe-RxhW7#fC!e9O z4ZmAqOh13J+wezl`1mdVlmBV>E5tb7NADYk=L??VZ{f3QwtyegkDvwcQlOFlGARkB z3p`@d07ur)adQjk*K>S|zcjS~Pu1`_vru9hV;)4%&$4_q&NimGi$6212#eZoG*2Lw z?6*$=`kqcdZ#riivjLtz%}auVFYrH2KT;gs@PK)JwlP`y6#cn>wlROBgEVgF?b*ik z(I6c%bW{^zw$O28NN1Z>^=eZeeQoGFd{>%-E&x78Q+&+OB}uof-SDtnwj>N6nr+N2 z{5F4T_+#XM;?Mk!`v2hbf2N~`$C2g&e?sRC3tqXjHT;8yV;+}*@CPwq=2RN9n2&{9 z0dHl#xw~syrlorzW14$%U9Svep5ED&%b4a@20C|jW}!pZ{Q5vPV_Gs@FJ??jSN|&m z8Pn3;x$R~A?b)_7v%R@{S8vaDBS`S)sjlAcOwP1qdtd7@FAQY6_q^8IyWO;QZqMW- z5|sLK*~~zH#%$Z!yREmoGnX-~z1hxg{O#Ex*48ynutNUfsx~H?ptm@3Z+}_*0 zJ=2rz-L7xhOh&^W+u8YYmxMjh-SuiFe0U<;+4EvXzht-V?9zlAJ5gu}-I(bNu{WYD zk~K1uw|1Bj#M`EU>?;GkUHyv8)^b%Q)3?5>=VbvlzPv}%cJ0zsz1v^RXiZjkWiu~i zySBY-R(GSO+RUqavzh*!X8&SmS5N;7z1d#VzO%PKrx8$H`J;6ftoTzWf9v(HeW|nm z+R(-Naf$x3RR39~|18&kR_H$s`cI?$qsbO4uEmOLu?8?WxEd5!gW_sXTn&n= zL2)%Gt_H=`V3R8@`&V%_Dy~Mw)u^}{6<4F;YE)c}imOp^H3AE!tNeW?)7{)2!`$tw(XL z&Ft#!Y2DeiV@Gd~S=;sEPF-mP(v?L)EF%Jib)@*!mP-RM^97Qk31k-zh26@bZ+7zQ zi(f~=Ye2U#m&tU?N+Dl;p1bV2)!o&T=`rg%U(EF6I?cMyY;SLmS(n+~HLxqTFl&II zQ82!mXh^7~zS|X0U)B#~`?@ps#n(l@h4R~Xus&bZw$_la8tS{Qhv>LG9yms!`$v`dY;0ZDcXnq&HRVl48K6)`yoD03@9gW`)A{tyu0FFq)46Tu`hgugOkXBD zV5FnhcMt3`>w90@ZrAQUZ75{Ap|^jJZfqNR_jGC>ZtUE?y*s0!c6e;;?AdPP`G)P! zboTGeba$JLU74PqPUFT)XzH-t^!N0>X5wugM$D$p9pFk%-;Z(*)k2-O!wd!L6I{Y^`ExLq0apK08O z;(@?bg=k(YgxhC@Apfoq7=a2ww^|_xZz}|vNFhi}D+KLng`i=g5Ok&$f@q0Ckn~gt z@|_Ans#76R-m&1p5DH$G4Rz{Y6-H!AZ78m(EeNws7R1%Pf+9U;!GKr9qHSovE7FNJ zG~gBUdp0!Sh19ly|J(F&p06oSPlh2YshA$X@$2y7{Z)_4e3`7{iEGZlhC zYlU#jrVw;T6oM;Dg=7?1P>hX9-;1*o3qk%z@T@c$gaH()^bl0%G)(NRN)2FqL?N)P6sq$OjQeO9ZrBupP>Dk8Jp`8? z8uq-0c6taZ$NF`*hX`CI4Wxqs1Ov;49t+^90K#*Njc_i2aQCXA!o9L!z{>$I2fQ5c za=^<0F9*C(%U86O9;)`xJP*O{fW`yQN})OrHF&7WLu)*=-b3J0Xft4Pr z_Ru^J)p%%uhw41k;30@#DZVuxTJIq+mGtZL9@^=lJ`e5o5Df+pEG11XEF}vb3!&gC z+0ZiqJQqL+IB5h9csbx@u&Qi?fR_Va4tP1><$xFRl8T_xL)9Ld=b;)8E$~pChZ;Nt zYZ;1fjfd8IXtRf&_s~ucflZ}pcYBBi19&iihXM%Zlcu6m0R$h)hMo)Hqz5_R<$#w1 zUSVn}1`c?Izhy%MUJiJn5uo2IJyh+Xc^<0q&;k$Dd8oldO&(g~q4gfx>>+T=G+(%G zRjAKHyFEmM0X!JMLjgP%z*7M{6F@M|Gy|ISAP2l0@N&S*0WSx<9Po;NM#akkFZgO2 zSm~i^56$xsSZ*3`frsim)Zn2e53TV~Dd`hju@_0y$^#ZM9?0yeE-9!&+>nNldu$w$ zG_e;=)1T#506$2hKs;Y)uMh;{Ehe*4LOveemr&{O%oI`iD_Cp6DFvQiqqsg(M&(w~ z?2JD%#pCgG`6wc@(Vxrq=d6hs4Vmeg5Do~P85y5y`+&1Q13aKmx8`UeBtrVT`;_&7Fz7Pe{FBsk?q}uC=vuwj-n(nhlu^#I(vc~ za7@%O0vLi3 z|BiW;c<16lL-R3}GLJo8MbKK56tg8TS_;!8K`s%-Bo9NlR+3)PRwG5Lt0{WCilRS5 z;I5G)=n;;>@x!_P+q}$$H31Ca%*L`@Wvl1|Hgc5Z?;1IRMsr6s`zrT^2e|K zP9!-ZE6oM$IH`{>;o1)>Ia;7Q&yZ^)9 zyZA?0T>s;<$r6G@H|lDmrERKfiz1ki5E8NF$=;LfjY|Nl7y~R2%&o~TmlpdCBmtH+ ziVA9rSZ%E(V%1jVF1%hd|Jd*KK6804yWwK>`~CbrFCR5NJI`FsoH;Xd=FGVe$R+VE z`Pa5xk}6~3SUtIffyM!Brhm=L;Rbqp7=fec+PhqX*im>@7*blutzv4sm{vLt>c@q9 z-8zTPUs96<#+qdHy-cc)(0IU;Z;jHrfF=ii7&`=L->!SLVKR-_eP`Egub+f(9EZ{g zX|s|K_Ns*&pahC;8V{g;akF3gOn3ytbIiYPd;NqsnOOH~!vz1D&*jC}cBlvZ(ptFU zrc&Eb9#)Lvi*^hOMHwifr}{}Wzd znL;n8r015H3|)&)q@@<%Gly_H2Q&EcCODTiRYT8R*U8HVi}NqIw4sj$ z`0Vdx#MjwAqgUipDcRg?5 z=kqOi-JbE2z8CB^bX_2(bEdPvgl(r`*IE*n2s-1foX>J&DRNAjoWfv0A)g#JA65`K zogSgPI^EXK0tC8d(r&NCE)w7~&jO1jahYEgrSQY>Mj@_s}FW zz4#=>((u|eS9jwXVY+h zdr{2z5Jw81uuN`mq6M|QG0Mw57B9aL;$>?yEx2m3P_Oi41HtS0ibl!JzOG6?j2now53T~-YTwKRz^>=aMSJK}AhRlqK z0Aaxe7*bU~y8QfYTG?wDi?8F~=o%2M0-_@%scsg=_DZiL(8zoUA5W{r-?6~j>_drS7|qa@tc{j6Z{czC zf(RrsrZIn0hknWW;arZ8ZFU5E_kpXIYhblJ3xkQB0D~?EyqNO*s+^D5MG@P9+!;70 zdn|#U=6QI614kB>u@uP+Sr7i28AY5-1kO?dSDr%xec{z`rJ* zMREouafBZcAJK_!H@1S}5;b-+{LhlNY2xKgoB0uFT}%|n<4A+4epiOmEntNBe%1$iI*^|4Q7*rqu*D$Un*S*Ht zn-usWv(`G+*Z@DS4W6*Snzh8t0<|#GTA`Oj+el6_10Y?nQhL9I&NH>AXN8j|bL^75 z^oVPCOWl47A0wyj^NqaJ4cjd78b_BUW1;~=_}Y2?cfG|Henkt5!S#%|s%e0qF=IUE z-w%2_N&xBg7)!+xT1j-D$>&vMQ~@Sh#iFCn&{!6y&Qtr-;sk2tJZn`hMt7j zb-SY&vr}Szvr09~sF**Xl3eFa?=S5A&8xPJWmi~_ho1P=Q@>fc?%Cfy{aownw)Qn0 zYdgDIet#f8Q8-i_8Xuh8wR_LreXk7v;o#2wJ4Q#+nedj#@47cd$I)g zXq`5IgMjs?@-i6`O=%z}X6o!}1ze#^5lbC=1&VSKoa>9F-n# z?ycA6fBfGjQCu@QBTKZ&;ie_J^5G@Yz$eK5Xgs0w(@S)f{4?_^jxN#Fi?^3(h{SuQ zDm?J`QCC%3N>Z{4acQNrR0}I1>cU|Qu7g>taqbrww zY+Xr+R-_)}g6P#PXvHI?BlJ+F3O{U=>4MDRFc7qHsUdjCU>7MXe2fi{J>uYw;XE22 zo5<&e4(5l|I~=yD-|0wS*@$tz^43gerF-OV_$w} z!Ro9o<4xpUVqw@1+A`p68;bdfL*(iU?MCyv2aCgnO*=_R$NZ-6BZK3n0ZJejtkpfT zxP7ul28V~oc6t)E=kI$~G*1qV9K0LR^Xis%SJ-4ZQ*cQMS6Ws5x8U-ZjKZO_k4G+0 z)kM$Lp1Tw~D{Crp>u!!(caaEAN}2sR1(*w_OA$Fama7sHNm|)CMI_{>0MU9bW2FO! zL5`GdenMsV5=^rzT9VzHg*jw&+9E!;fzR)M7zxJU?9p#5!@F zA9Lp?5SNJa2dZR8M4b!#tb$;t&Y|#7BhGKNlc=6ralTI`krNRo(e-O*XKt%oBDiw8 zaSJaOgPU5#S;Ry>#mhbznu^o>M7LksUY^*nh@a?29ML27UE-_5;-4?b2*UesF?}^P zg9(O?oWr$8x!9~pJ0#BkLh-NKe@7d6w!li$;ju>y7_5eSoZ`OO$ExS&)|| z{k-(YdR~f<2mb~9L21_{s{1kNzPC=fkd&S!Rp2@;N208@FL^q_KMbjmy||RN!}lfm znitnaNnGI9F;DR7u|I_$G0Du5{k?oeEx@<6#TNZc$u z#RZ8?k`5`JyQND8+L0Dy^KNzF4Q3ZZXy0zbml@!&Q{V&L?VlFGU!dS<=Yi`rs5jav zh<`$gh<1{6c>*;=q{(fNB94#>p(7u>AVSH^kp!hr(lK+SQ2<$JciCxl$3!|~jxD>2HA7BvrDhhidhnYd@82s{KtrcfzLPp=g!zS(uaanFci5_JAv;y2pqo+<7MQ zlAWQ4+S=(zkSQbHlnyY2)g0Bk6K}~W8Fp;T&}4CN*#7Nh*P{9H!e0Bc&Asi-AB^lB zoY*|pgGeyj$ngVxWdqx~!K3LPZmtk&1M~$fqGU|9dkFeJzEg9Pg^964>Qgj7oG;`R zYue5RWV!HAVPtUJTHR7rMIn(dMDzQHcIG34#m{!b=9#fgd1+N9XNgZVGEfS*L-kgJe7oxfJV7*RY*sW zg0md-fb=OJ%P~&8L0asjzf6RNlFt4%7-xUg^pDIKyOvwUrOOq@gCjhZ3rt=Op8Yt7 zkhGSn)$^U=N})FQGf?3ib71#@3E1k%ht`P-e>9bTULa3_&z7wy3(uEu;ukKG@5}MQ ziOH$~Ef$y!UG1G!G<0?}Gq#d|s`Q0oJ*sBIHjJops9o)h1j7OG^`nfnU}sa9|1YNl zcDs7ju6~SSj?$Nq(XpY6!cS57Om$NQ#c+L7^%g{$+7Ta}QuwS;(p>p-P8iX))2*8$ z80{_Mp-N|JW(tB|5AfMu$lkB>8>FGKi@o_N9sd+KL+iUG*8K2fTW9NJGeUBW^XW z&1RP9?p;K<(iNtpBLb?p5aiS1N?m}@Ku?{Pg}E^9(3CGUe~90d(M=DVfVQ%Qqd0s} zEcrP;r|W(aA&?P7>rpG`8N>sY8*=`^(;RP8oADI zKyi>?k!-DaSD^wPJm{iS9!|aeE(|$BgK9~T=On|h`~u3tExnp-Hf4z~^oT=`3(>JFs0;LdM&(kj zt?g#S{Ftu5u~5*U&vJF1M&s~g#;=gGOuKRZH(eH*g9SA1x_?m@I43F^SEMQCAJY}s zYnbZzKKTW0!_13cfxzFBebSLe3gLHvoBTjQC&fa`HaRcgFh-+<^`-BA0-bAsys(OGBULvirtBbIyU&QLOuGl!)VZ;$Mqsu;tyVK$*$fuS# zSGjm&e!or&%7*$lc0pe1hJUOY(v&DRPKY;2r(ycl#+m?sS4@$(?bQZ9ejG&)HpW-bN)8j%XjYs)yWlj|KS5Z-Fr_WFga!%^@P?kxOV^Eba*?FlRR0b}=&$Lbwalbh~FNgg}iHNX2z)$eE zNJq3Lz%SNYaQJpYoZu&F;}J3cs9MuVySXwBx<-whPS9kO?rG)rC;Omzo?DQ}EdN9m zB&95SqR4t@5OS49N0XggK6U+5#rte6_1)sQzq6TUoP#9=@4L#LSfse8T^xT8vvF3G z^ae;gq=pPU&aVNy6JR3t{XZayJ82r^?pz{Eetr^+7krp0`qoo}cww_zryHOHq~}9Z z7oXGL0{rOjr4F5#FPZ^Aqd$Xj!Xe8n@0iPS_lh-Dorq#aspO$ixidNTA_E`%O^bQW zg@8qKVAZp6@Hw-I*oPt~9?VwpXw7%uDYpDq8%1FSL8LK$w`iMPqxoFt4&hp)#D&#- zihpaip+dEJa@I3X-d|{*@GB67I1i4*(%oX4DssfTy&`Az55J&GmyFV1wH^E(Q8UQi7HsW; z`18Uu`2zpjZWWhNIedK%orJXsE*cy=BQCUHy`^uUaN{}$!<{+AS+*6hT_}?C8Y=Hn zhyc<0JzEkz3Nf@^zAOz{)q?d2$ZL!71Cr-KN0bedn0u?Ql7 z<}3aQv3gWsISSqoC$Ry*M(e#o5iVU%I~N_-!R3xSP~bCAR6Orq{vcd^PD=**@l}s5 zs0AGbxCE#KT7vr)IP`bLQ3dW%-1EYugQOOUgB9;Fgr!p~>{RA!tKl9Or{xN6|e?@u4g@<2j`U>Jh^pjtfhgMq^5XNNU9ANwMN%7T_0_Ztk=fGGwE#ZAWgM~+=6CL zxk=DVvpB#&I~$~M>Mkf3Ou=<3mxi7!NsRi%$GjYN_FQt$B=!3TGEW0`iRV%`qR-=e zAW_FpVrq6{TDI6%&HOq_rz<5>juun$6>$uujD zXt0XnLo!~1fNi^+gGGKpqf84WFYpgMNz`eyDe+(tA{0~QM1g%;7xPc(Mk|LAxD>~` zF`<~4|Gh@D2Wdczl7cDpUEo*UWsi5$ZHt%}7c?j6sU(J$OsHPUO`Xvrs8^EtqJ%;# z2W@SI>Bw8!))8K~wPE9z;u7*IzMVr=#qslN_s`GVKR>pA&cZl?PE1suY~D_rcUT`$ zI&`{YjpCx^^A#VhJdPKhzz)d)pjnvfmC|>Kf1_)$S8BOzf$IWyEt@7mM>Nz-iKjFS z(GY}b5RNMVqoF2BfDHzjc0@x#N|><|z!k#=(Bwey6Ig7T1d2|=FWU)zIW_nh@dZ^Y zrE^C3MEd@+G;JBP+-(Ps#F0=2Ze*L;<0?^{`HhnX&xrSARq80Mp>xWfX2=Z}rUtsA@>6pP4P9h{q9BIw z3q$6Vv*~H2(c|cP7oRoBu#_NEtXg?~f`y7|u1nmQTyM*!w0e&e8rDcWR2RK*coqjZ zabDg~?-jpwi5nB*4H84>j?JY(N|4l>)t#4>I6~e!kyVS`moovi(rHC%8NyzeM->X{i!37KcMzskz&4O;o3KCCAZxE|0pliTE z@4uIl6s2H!?EvW?y z-VKccCXRPg#Chq%fsC^hf{TrqG)U6RDilgeVa%&p4YLdn4>(jY3KLHz*s_{ZxRL5m z+c=`Y7kbGm$?n71!p|v>+S}!&W;eB?H+ac^lFg8+7dBsx?R{313QYu=#x~vZ$=1yt zJAKcJ=0?CkSBWc>B+nifeK?;NT4Y(}8~>Lg3g_7E54y%}|5CMhX|9wALGL}Jn=mUr zq3K3eRv`nW7 zrUy?NcM&XDa#S*mzm#ymUc;!p%B4-r*JyEty*ElDUBk-RQa-RQx{r$8bsR^;ym&(a zkBqw0)iMV3NE#;FMEi3jMbw;gBrVrT!4P_6ld(C6iuqbSmD7^9(pV-y%m9mdaZc?L z?mdKzN@cJ(;8&9;3eKBgb>Ql>62eso;^ z#YR3C_dy8^w%KX{*v(6PreC)*A^wi49V1TstQvC1=wq|`tGx=+Wxd9-GEA4m>sXN; zEAiys+ug|(hIkp5a5ow)n&oq0aq~A6N+rOLi?SrA0Ken_9wx$M*m_ldb?y=Yeu>zl zIlcZTmCpdVo|rwu&fwsCCir`v31PS_2WKVbf2T>J`nHgu1=-$DO5!Bc$-&skfxd$B z{0fxWNXkm1Oni<;t#g$BKM$*sTlkvxEpYz0Yq^g{H++lRQ{M9tSoBi|w?ST1G3V zI4}Mw{!R12zP#n%s@(}IBwe==`Q13G9_WC0$!upW^XtB+={y3`EW-KQ4L~NK=wV!M%bQq zwukLxkMGLwM(~IM#Cn(<7|%}(j7#Ihy?OWsX9EX@c0q-Fbm!Rc*u*5;mP^OBZKnTa zqIiRvDr4+PQu>9NhK%CL|7sFRfGNX+LdjWvkNFsTipuQqN#}1t>7G|6B7l^9d&Imw zZQe39x?#F(bFwLB{{HSeFuSFVb~$dmTDVs{^?RZ0s^UO&_7>ltkAER3La?Cr5|Sjwzx-ZZecQbn`qaI; z@g4W-68z-7rp>R+tN8F<-F(A+y7&|K>EeC&X{+`Z?$gceHg96ie*KI6deIcRFQ5x8 zH*ed_oA`S`+xgcw>bGCrZvZ}hzXs@m2eiS}#s{?FK0oz<{`~6)we6KS`Jir5%mkUH zgERK)wV*b>Pd%iw^7)5AbVQ`n_UkE=L7cN+KQ*tuhc(^&^kH3o#lyP#?GGEvu`eFh zkn*EH(W&CipXixe)1)DJvdQFp{}G+YKY7ITGLrB_39e=*fd{xHzs$C|7S^oXQl|kI9PRU|fKIBk zujqP|vBOlKek$!N&=L%2?B~1LSETI<98X-mV`C!~YBHPCk4$mmN2a*_4&b4nk@C@I zV8q*al5lRflVH3tx^o7s`(v2NJ{zW+68t+I|)_o9MPT>OePrQIWkqaA{ZFS zk4)wZ&OGG4wIW3Wxq#6L9&uGwBQxQFje&eLM9V5tV8Gzc6L+N$Kra8bco6JTKB!qD zQg>gsg;?Hp9z2LIAs?ORfGcHSVE54Qj-n&pGd}_&yMyC0pz)T$;i7VkYumX=N4fMn zcCe5iog5k)b)?B4$Op$q$l9$he`u2FV9Db<3x~$@=I6l3j)9%UiGh*9gVbblaB?sC zLy)#`2gmJ{p3$L#wswn*$X9|OnIA;Z9GLr{loKGArJ(kdpnUvpDj?X4X?4@^n5+{Z z^o$nr6QlIa813D)n}&nqBbod`XFG$1vEmTbiVs`ICU%)0{XM|Rq{PlWE1JoiD>_)v z{v1ri<^_zDI@Y>P_M{POyH7e{sb;cA&ZDI-2SpHAR;yVlReSEzNJ&~gPm9m?l1~9X zSA<;*%=qVC<>$#xTO5z^^H}yE!Kv3;|4yxJb>b-mAe39c)Y@6rAsv%i>S9_S+qJ&q zEo$;u?7^iBc9kI8WbE+ZS`3y-L5h7&%ouFwmb3;x%q1yAbg)X(!l^*Pf4mhIo_k$Vs=-Gh6AWYXVG*%eXR`4)8a`Uogw2 z#kJZ$EhFWcdgY~8Ivs{Xlexo>if^TI%?w8XOOi<-3WRcV;y9=~ycT1IUX_vz==;tt zMoHX`+83YFqu{9kpPit~l~_H$M%F({NU3kt_~mEp#>~BdE%Z2C$5@1XlH7!6022GE z*$uJUD(Rqlj-TUN=3#4SL#BVBRvcpkkZ$uEvI4j)m8vkLOm&_rzXBUiQUS8R71qK? zN7vgWK7cOii@0}%PFK5j^G2=Ik=C7V>8h;FWkyyM=jCPQH^#LePffuNr1YvX&ibll6x<+V|eJ*t!;2O`!Qv-Y!9=aj1g^D7{`!wpVVN;a7E2TmW zy612bs9ND?3=(0Op}R!7cmY29fa;RQ?)$3Ua&H4KPc%Zvs*`}v59MbFT;cjk-u%|_ zxtILfDw7;k!or*SO0r%JtdVVd=1;kn5b-O8G(Z2=Nc91}DNa@QnX1ivO+Xm#hcd;Y z{i0kIPf%kZi0Tz_O^ahq5@n8?9$atf-hviXZ*f1Mk^}tcHYL_9^KTuPy$Q_rH)`Ma z0X_?NQc^v+A4A;0%T_%v_cro!2hE1l8q=T_x;&R74uu^34YNea?UTGb5mcHUIwN!o z=pD)_)BKvbrJEL0F1IRl73UzRnKigtKgJ$w6(z#4k~1nwRP9Y^4* z(mwIFqvi>5LL94oj9=b}W6ZILPfnE+x^k&HjeA7ZCvt?N?^~4MU48=DDU>*{5a36Z z*3>P!XE_u!{_CFN?v5bxiRsFo+I`erDw7{&(>=d)={AcvDBHEX%%}@zgtY((Tg!NP zBRO+FEbCH>LqY!Pf;({420wF9zE1uTomKe>4g-@9P|yVzP2jD10-F^|H^a*Z{k*)b z9tuV)w5lvG*OICTmJ;t;0G3oPGiEIyC8Dz!Obuh1&nXyT@uDDX=z=42>cj+}#gZ|M zx`00o_cgG_a%oi_l*p{ec*#JaKgdEhOL#}Z093~+L_9gS6 z2G5vxVTRd^kQ$d;FhMhqs5aoJn~4iXn_EmF{DU1p!kAEN#Z_|3D*mG&03~YQzh)v5 zlQI9iV!4j{L;OvNWqb5*;^IP{i^#RTJXw`CYX>H{pOrRRUt&`(5w;ji1n+U<8k#&zT zToyN!YC-9_5Xx)HT;M}Y8QhZ}7)AUe1e|}Wd0Q^s z{M0k>IawGi4DD>j1z7V_%}-3eu)X;=&40vE_^~H;HS2%bV^7PZNw(yP$>t{}*%OnL zfQ1%?}6oI`$GB>2Q4KubV`UFj&epFWjI?cWGp=Aibms z91CSCH`t`-g(|(;X<=24lkIiTCwh9{l846r*^ryUJb zB)a=0!agxM#qm1bqH_ zsi&T5UbX6({X-)w*RE19r$nC_{gf^p&d(FyVka> zY-wHD(%Rh8`fN+fvn?&FTJ+PrqNTN^<(`!*S2o|Giq$Qxt5>#ku3X*G+`9JJ)m_iF zcDSlo-O>V}oDTun(u^dkz4hs~w$;rmSFT)n&x+<>J~ueAbMJ5OS<(EA6egNS3F_Cb zX*WsqC{N4Ht*veCos)rL6U#NPNWZvy@s`MBV^R63qN(<1IF?o*c*}JpGl@QH{Th_o zrT^#bRYz|w7q?`&NJLeR7e~)K`XcGLwSKMqN_DwAyEYxmMy&N~r2N2Dc5ONpO<3z& z*M}l~y7s>Ht)A|MyRF`MIALjt1R9BEsi_5EibSkLIF-~jqiM=cbxTRg`ZW-xs8kJg zJheU)&){d2{w7mqfKyg)ZzO5i0vcCGGFB#*%9tTA$Xpn;Su5ESOBvi62@DOe6Tew2 zoyzvPGH%;!AodJK&Pt}!y%uCN>({LB`aN}}I;tvk2h`ET>&(|aba=mzT7aGs@kq9t zNXbDOtv$WH)=pP%TKmG;Udv4&twce4Jo%#Ws5RnBTOG?KveuqiEXse^A zFPXHYVz{fs+Hk5TY$?rg_m@OZPcH^BD)r4>A3L+DM31F4%w32ABv`3QPj+8khRi%xfqcO zs%Tk#(EC431B}K(M{@;oTOylCSR3=ZTp+h)dLtQY^Wdl}wLRP&i(BLQiK06>5|4zf z#KhnsPjX)}Vnq&lE9vRW#;wHIu)D?fzFc?A3J(|ExNFbEv7AigJ#}Yt*{n4=I_BO4 z+q1D~uaz4vy60_sHr^e#azmr9xB<*1Vp%IQxZhp(nn)sNZQVOma6_^t+Lw-43B-AF z)v_kmouSTmx|8GG$t@usKZl-}Y=4~P4#?mrYKJk7?#$+XqCckq=VPyTo}RkPNU z+?%50)$Zg(Z#ZFvC&mtVfbWUN!d7^AaHktJYx;U4F>7f5*n|f+eZAS3H9R!xMM7V; zw~yNGa<|);>rPX8n>Rh3q;xmyu_hZ&My<%$#GqQA6qT;Yrs4@JoFCfb!A`CZTkXW) zp;mYOxxQ>KrMnmFHMv|mYi-?|A9OFg9pQLfj@DZDaCL;^y>htLy2q;{98dLFTZYDl z^WLiZ!g4mWxyPU*+?SC!YIBcSM>y3Zk1kNUwsb%RNFJk!(Uj)$ZwFB-G#t)a;i1Xjd**6KG@6rR>ZvIj z?+sg>^gJDpCSx%8P<*Lb1rNy~|{#tT(8 zq9(2fRncrVL5+8MkQ>cOpgO!w8!ysI?x9#BvI` zZJut#atf+84^;73cfv{!PK=GY=X^&zp-7>_(|A0g2(-fkZak@|s>1_SyjM+|)!xQ? z)wEgd0XGp*aD%J1U36J;yr|sdSJ0;GX0iiF8taSmOaVk%`F3yvEbP zL?){iYY$42eTqWcJyj)BibC7HB~pq)+dXY0GYLuTT^?|gnLfEzb$L426A4T5>GHJE z6Uj(|>+-bG6YY_t+vNebCl-|-+C7c;#By>Lw0j!wjl|`mw5H-iuUvc9c&h4+CFO$A z>4B;@mXb?Mr>7si@rbOd(*tgAIwl9I)ia}dGhsQjt)98ro5@HjY4yzJzJzLHb;XCQ z?BHroReebX?rKlteZ2|UMu(^8eZ74WstymXQr$6$-8N4fsctn;Z62snVKwG$p2kzT zZb?3Cy=~;ul6=;Bph}11a;@z2%&2s@S1x3oo;jFKWMzppp2pK^9b4@g*>o}~+g{`8 zMmm|2(5~@xJl&%RvDFK0k0QiYPyf=rePL_7I59r#-upY!Y7JfOp{fkHRPY4to?c|a zig?;RKxM*;c-lSP$f(tLwTC`4$*5c}x;z-nBy+OuE)UK#y^$X4`TX#(hh^=^^rhm~ zrorJ6?=qc@D{5==U@99|)Yj&~RJKo%`dUvnvVDrw*LpghO({}e>p@jEmF=;z6N953 zhN~kNRb;r@(|9hb$Z)j>++3_XZ575~6XV|fq4PoG)Zu|DmsXRb!_$vkMoo?mH@Isf zk=}@v94l1t_-iAHNX**2cWAQUA)mF$TsUK8hj*n0ce)8{ZBL>nZKVhI!i+kYL=ECW2Ytt)-Do!wKbCFEaiVlrb9FRIAy^%g^WNhco!O0=_9^Dzu^hB*_ zK0jX3qt1A5xSLKb6-{-<(}{#NJh(qUx+_27LUw1eJDRa}j!leC4h_3`{m!0nG-6HW z2PgODhuv&7mgA&gAYRYF8p1?y+)%!`0wS#=~(dJ~WZvF)`#hsC6a#vI%SF-m#ry zz?&PNJ>9XK6&;*-rSkaL)q{DwsgTcC!C6l(m$CK?4vkLk7@KfU+OFPMA|}VEvVVQx zCDKEag+m+1y!h-(_axPEsREyU*?81S4IUV+GDfLfJZfzmn>7Tw z17l*3UWyP}Hz19MVN?Gx6w3o=D%3hkX z65WYzYt!K9t}4_`Ut?6Z3U`pQl2}M-L97&)q^#atCZXD`kRGJ0zFa~=RkcUybU0?^ z#t!VNimNOpmL%6In9OA|DJwTPK6q$w>)xSp*Lsw;!nsJ&+B`8hIypW#ksoynPVhOC zwiY6%v=vQv=M)Q7Nk?fbp2&r*g~%*zC8O!A6(5FZsgiusR!?`b&)PJ&Yu9kTa-~UI zJ>dwpkv)40RR$w%^+Zxh`MC<^rmfyY54gg7ezfZ6OgfvS&AuA{khXH!o)k9x!F^+u zkY}uLG7(n;QbkmhvBHoQrH6Kn0{V&}%UCgp;^ctlD!J^874Plqwo>_#vC+uhq20SZ zY-+|zc1JRjOsg>i87q^C_gdYfg`wXU^VQ(bWO`EywN==stQAfq;#9v`9b8nEwPL*) znW6fUmbK!MZrWO_FRxiEnMkNLziJnzLN!!hyOAN8u~Le+3lA43-Iq!^D;!NJ&ZGLap0i>Z-Aw>dK?*r59*xO<67yC$ z$&jNb1NrRe?%}ZmRn~``6;EkoR>wuoO7=!GkU5X;+?(Ikjf0OHTRE#In@cE?sEV$f zmCZ(CifG+qhAS)F_H5j3btD|NBFRXv)ib((aCm6f`Ze3eM`9BbWA47CtXwvow6=|pY%1>DnV)oD zF{Z7)WG;-anXz?Ny4p&w>A}fYs+hGq3d4?q+VOaqz)zP4id#9sP~+FqZMl|{)^Kma^5`hE z#=CpN7F`~?ZouPx$zIE?FwvUpNhWc17zT|KNd3S8^4h*^4qdENv+%UJHq#xp26m54jCd}J!Z9n`o$j?l+r~!} zHLY)3zou<{d;2Tv*MwYMjwY;dE|IZ9J-d+S;P}Y;_DSe`wCtx6Yg^Z^Y3=IjT;JN# zw!XEsYyBF>^=@x>q}QsVDMH-=p<&i;&DuZpYTAUT$UKmBwqh2 zjthDOR5nXY=pmu#6JCoevedHBRpGo&k$ z?2c$946RJ#82Gf6ibP4X;+Cp0Hn8XwI&Lq+vVEOyz*GQ4`mAWCJEEtF@7F?qYm<`FisY)Gsa(g$;bHTulShw zVARJpPx=^t{Z$|1rx5d2T!**(8h*;h_zC_WALB=1hq^;d`PjqaGaut0iyJ;x|8NZ} z`VeCs|J2fdwe(Lt^Ra;W4`1+mG4s)X@_jK|%^}96EUBrvmOY?odNF&5HBg-o=#}WdViv0D&{g9g zzF)n%DvWj&4c7(Pma2-c3o|p-HDVWHa;mBP-HP+Mg<5S@wy3)L)j}G$)wHs{qh9W< z8M5z1)2pgB+^zJ1zY`z0fIeAu_V7nFvme#W2L5-bnJuJt{GR@@z9RD9G3*M!z`d#ZZ{NGhayaUaJJ5yS`r5&_lgT7bI#=Fq{(9Pe)?eZNfPW}MC z2>y%PPSw-@;%@whFsJ@exzu@Eep}_zTR5WlpQ(C!JKd%q6;rD!rruKJ>kf4))Pzs} zZ`X3YOZO}Pf6$A)txDf*6=(0*#mwzBY;UCxrD!bsJ?P=yiCYcR++8@vxvl==k1D{9 z!{%MM5mJM3CrZP&S1?^rt=P133l-Gv;o-5Jq*cWR{^xnPsje<2wc2d;GOxay{l%qt z=2nLD7OGH^v-RqXo}a9^+LwhC3abF1lb|wJQK9prr%vZ58+fBYj2DOEn^voH>d-mV zhNY&jBSD9}x&u9Am&&)J2eu}+f!t2ATeQ=3j|f>!cTA~a2Ms96s>FDTaZeF{lQ@Kf&vDuzr{L|30xjpwYrUHhtRl6qgI}7{s+9h@l zF*V+I2TNs8q-%6V&%;9j51&RvGK2}igJR8%xtCY%%I_%d3F*M7`5>Kt;tk{0*dnH?HO~KC&zLx(vM<#5 zI2te4Ge)ry=z%_MwdUcG{a(P}cvS0dIFa%GJIM&x9=el^2tV?(JIRO;GNC)kh^AZb zBqJhYcU8|=Ip8lWW$YD|c_EAw2^E(zCcaTQ0ZTQ6qt`LSBz8OtB0N<+VO|oSS#PhmFB-p5!BF*{U@ z&}uyj5IR*R{Z#D{CZl-mPI6Lcp;LE~6M4j2cajqXBK}rAXC;=zKN>MDRQ83i)Pg#1 zHZt}M;&dQPgckuNrq zqgwG5{}`BR;B$vV4GvThc!dY{t;!+Drl-N8_Z+S3xFanEaEpY9=yz73w6rim8V1P@?|E}P{Y`Ut%f+}_-mo28sv7-Mi8_y@DjqE zVe}+@G%?0rBpLu+$XGeOOh?G!N9|XHOOtVPU}mFUDWaN875}zV0qg@59qDI29na=z zA7hA=9`wY7V!!pt*ypt>s5}U9G26t;FNT8sTM?HQK_6?yMKR+mEau;0LW>JEZQ@__ z?P2xJUkLDWq)8l)hA3`2O}KjcDNz>Ssrf^!|RS0sckMVQ_?mS&7SO>_aS7s0aY*dCL{rx|0*DUp}# z)W0#to{*^sz$(jAEMjnOb&TIIsT6=O^Zaf<-N6 z7#tep{o^!o>icZuQ6XB!@L0snm zaga}oBeh#L@VRkuQ{kj6-a|jI4xB|$%4NkRFKyRR6~#>uGj=irK;1up)g*)6*bw1UC^@#j(1_ zHi~0$AJb4pL(8d@#_R=g!7p2PHM|0dZ^CGnQ=#SkGPY|_9NDN_*5hQFrwW^j;?MZx zXg=p?UJvrLm}$h6b`2`R)%BR!3yvbl5UvyRyN>bWW}Jx9aJ z0z1kd9&w%ihx#PRV+tygm&8t3&-HKF3Y;`4l3(m52S_u+bpyY8|aYl6t!sW1A@rvEOAH*sTqe zhLBw{&BQZQVGHTEE1uyt8R!rXxHLSP%CQtlz6|Ub2%UdMT)`G>9b1dP=6K~umrd|L~fRbXGm&LagyiE@;iz^8HTod50^D-EbxxzEzh6?_EvYwy( zIX@}hd{&f;Kj$;zt-{0nWYWh^zU0%%_aP!^4KQ1S3`Oxic)1IUek!K;w0IAZWW`i* z194bE!th2#{BzOJGD^_gG0VH>yBDPedhv^X04;l=fd1V&5 z;{3Hxv+5Ml^X)o?ZNSqh$M))e$DTMw^oF$*f$i!TpJR-@B46KTi~*V;(?Y%??-CXrMqUT8* z6{Z+5g0#DVHI>V^pO<~fLSwS{b6)QDYqVmm2GMr=e*=;(ELI<$cXAy#2<|6Xer6B> z<^j?1#l&=q8&Peo4+2L#E5)S^7!k%? zf<{njt&e&Sv56@2Z^SV$;2J2L>G9N!}T874_UliXa6o;>f z5D#+IP&~uiML2YV4v~)ydgmzr_BZ|tz#-MC^+D80z5*_ZV~q(La1LG&&tle0!(~e| zA(^Z7X>{|e{4ac_&jy|UMU_Op8dslju6C5X)&ds8QBudXL_T*(c{;E4p-w#FgP%Xx zZFTA!BA@wY?6OYL&^sS!pdcQF*O z0p&OO4RM8kY?lP7;6XkL$~iGK>I|LfBoc_mYJF-pFkadu-V`6$RcU4y*#Lws>A@k< zrhwr?zvHJDS5N?GTTLn8mA}DH^kMWg@ydwf3}SmP4Pec%aoW?n5~le5sPi=k6p9)^;cPYhC;dKiXK)O{`(H@XkQJ?A-c% zo886x70f~EVP%X`=U`x()cUY2;Q1~8oS%NyhV$pDCggGx#KTk$GZ|04xcnf$W|!+w z<&aCx^idPuR4-c_RUR3q)H%*SaiQSZL;Pr6umS-PV$}K|7{IIqH-37~QlZJRhOv43XGfXNnRWA#N+yZpaI3 zeVAi-_VM%LXv&6FlL&ITdx&GUP3qz_Kh6Ik-m^=#DdIxD8de!+*GY}o&ufWy!_z9h z_|waFMZKybWCBs$YK{3NRiwnrtVg`nJZM+6T~&lk?!I7AvS&lP_<$duu*>l`R6%4z zR}kyge%vGYxPd^A#?LB-FGP7D-_h85fHASJm-` zTc1P6xFTpBY6S{}I}RClC)TNV7FKQm?gT5y?C#aW7VxN2#m&s!2mAAcUc~4@QzJrg z%SkgLI#^hxbR&#rM4LNmw9$-c?@%A4W<)LH^Py*RfAYzj9X!sX3LYF(40~*zs+tiv z3JRPVpHnLvxMq2EY4d7$u>9`A4S>pr|3NL{wij?!uj+1bD@S*6<;@`rXYeMRyIF3- zMqC5Xnx~H25W$hep%ras62SSpf1>I)LIWF{uT#Mj62TZ^xXBqvyYz%(gDBf$rD3~(Tng4 z{I5T;_a1!?vX7nMY~-W)x2JT1Nm*Bs((g)fZco_T+}o2pg@U1jMw^+g*kp{FnckeV zcAWlg)aP8q^ggw~)Gxo9?0WjDWBfTH{tcnMW9e+!YlX|ME1yIh@cajqj@^|heC)N4q zJI;BwYR*FbAnpeBBfhLOmUh;eSHrffpvdI{)tJPNOs z0PrjKGbTzZ`$El&sanRw+xIiZ-^Mu-6J&wrWmg7p{&PGFwm3$@NaBmwJB z7<*hTVL-t`yOo%J6tJqC3)P7er#Oe4=WrHL({`ac`9FTi82<)`4JCH_A@)F7d*y=@ zcpa_h5G>RYIRXQ9bYO(IrjC9~)Yq|{Y!BPh&PLcIseC}oKwT|ByI{-KHgU6ye+#K~ zfY0(jLw1X6hENS-IW5;#+8t8?KEsb-QbW+a9Qq1Xa_p5EPLp_lW0ee9nPDc>vOpUh z$RK6y&Nj;8OTFb^4Dgu-WV*yM#r+;Mv}#Qd4t9LGKQUW4W@XRUk_Ozpjk1+ zON*(i?Es^&$qQ+rMJj4ILC}aO{FImZ>CkhiiK-uXiI-}&Yf(Os41u=FGSDWbUfRw} zHFT+=KF*~=%|?4jb25cxR0wTWV6Ncp$!oHG^nEW7wXvUdH9X9x#g%(j zG#?1GiMRMk{wAiAxEbPS@M4Jz;&mu31^DcX(3(`Y<{l&k_-yocvtk7@+$1`i7q~9P z)pLN)K7wl19cE>s=K?|(}qz5fEnQ%PG7Hb(wUJ(bO*o>thTdTMisPuCiR0Mca2@KNdALQqENfRciF(rE zmb=R1tMSXH*1mIlQfVv%S=hXR)5l#*kS>?x8-GKoI|Ld3j4{?hOE8BbRU2icqm|4{ z>Q(Z!-N)E!`rhNyl}`Ai;zW?~S)Zxtq|em!mdPOIeT=nIQ{r=zVM&dy;MX;BR}Qj7 z4Pz@QW2Q#lQ`fP<8b<7X9ot=_EB`+=8Vvq%4I{;lI>zVCcX8BY5Ep8g($NuLnhZ;7 zbp@+y8Oasv*xFiMead_ttYsu14Kndst=7*Gr)n9ohjmPxu4N=`t7GE5TCFT1-mhhJ zXsKh~pyg~}bm!Rc7)&Jg<`K_?$@uE*aTze3$vEsZ?&1P%8}cMa$2X;Wb3}X=^kZ+7 zdXUTgjBVZ5WOOdX`8IKr)|z$V3tk!yH5MBsnSCoSf@zsV4YcsTPZf0WYieWduVrkV zxFpxi(r_pk;K$O7X!>6dwV+)!#pV(|y|9&2q_?1Nl6_d<=H%XW6U*cN1TTv(c)3^XsG`>fiq>IaSM>LrojyMn`&#^{#`r+SV=x z`0PrMiI}2|3JX98f13FTD8)bn72HHlBLO-cs_ef4d?t=gYsIx<1iKJ4!x%4PfiDp@ zt~#_zd)A4$;-jQN2{xwRz@)d?0H0az!yy?uB79n0TQnicysSnIO_5d~R9!Lo?6y}a z4Nk4cimff=RAyB=th_AVl$r36m&M7fQ;qbbL#dTtCm>Cg;uxQK8elVLy`)(zE1!pw ztgG@lSLJh3b;eekRoon*egPEE{zMWnG@sFR@K+nq^EoI-QExRgnrO-?C@G0kKq~0# zEnW)pe+T%?Byn%1oMT*|?dwqVC1oimT227bO$50`8o#6@0=k+ON1N7(BeZky(q>Gb zqvC{`dh?Bv6TG%4Kw2nrSJ6EwBpsb_0Au>$=mG}(iXyh4qZqpOrK7B;Bkn$E#7D$2 zh^wH0)@*2tG+E_-F22x^LKTK)&*o60lUD0(oi)venFVG>6-k8}ox0}Gq&`-W`4;sP zvcz4~Z}wGpE1SeIKD`Xv0$zSb^eZKBppSLpl1_fiwFZj6NFGQog3i^C$f^`0P95X& z4l>TFl`r*!u6kLldN?UyVYZjQm5$}_aYg_A^0WkPZrf78&AQG)TB=tzXmw+$qsh2o z6G)_8b61KI!SsL z;GRwP%2&B2RGZ)nt_BO$e~O=i=q5%CDD=Z1@eYzoB6K=~j9-KlnO+56!2<_b$nc-g z4}o~Ajtv^_lb`WP<(6Q#`z_TNHgCJk8!y?fkReLg#9wN4 zO+WW**mn3eXhpxy$mjf;3+DgyYlwcaNGGmer0d~xi*zAzYLNy>d}CgJQl}H8JZ4oL zV~c#G@I<^LG@TcN&OZxE#pGrZsPuzSf|A_#H5jsgk51w^`M2cEaak=E!FA$N;Xxs3i`dh*~xpL5~BN zB7cht?W>czwWb$R2(wOHD)N7b3-#;7C7eaypmiJ|E^&cKEElnQrNg0RO5>SStu>29 zRKw>I4G!Lf+JFWn7!i*14Z#96?O?6A#OI!`<7IJ;Ph$X>?@x^Ze&Z+m>h+}$rk1!6 z2=E(=d6`tB_(^{^pB5iV+l$(SxFFsn=5>X*wnDtir^Tmrj?#W!ssqm);4=qQ<4r5X z8?|Us%-3z$YIyX`p>|cypcSg(bE(jC&M_tnDfAe^h9O7={0gC^cs&4lx?*TahaH>2 zS>Qk({;Q9$#4k?GyI=ys=NkC85YW4M3E3SSJ7t@x&~jdC;FtRo3KEEEKo3tl>A?xb zY?~g43ZkHFSkccG`4qZYd=Q{GQ7Vqd=@x*NGz{mmFcj;k5Sa<_(x3cb?izV16!$5_3Ph3NU{e^Vac&$7 zwW*95gWV|L9{#d`SmXuMjymHM@1>cg_gUh)%9}$i=qHWR(*wLz^AayTB4sQJOr@I) z5wu*LAz_z02eemlO&Fx>L!7#U^jFG7VErM*BG6#oL^}wKK4cn^xh%p@nz~6>Q&!2p zuq7;Cn_>dG&$2EkDrvb34A^iD9%R4tF_xvao-sB*P;SOOZXJ8Ur(yr2kFgY$AOVbm zr0mnZLnAOF>mo&{q=d1cG$e}v*t5oCuGe) z;uDTrPf`j7S{WlVL%9Q5WX6%}ZxjF8vQC`a3Nc4J{wybf2mUnS&ocaJ#-9+3{c4T4 zkZc2setc;JU$)s{m*!t5W&?Z{qIxV*%dx<==dfg18<1daM9RyQGE6B^N{Qy2R&XI% zi-1J6YdF+cxQ`Y+r@37{pFSMgT(f@}{{NzX|3g%}Uhd^t29SsuS_`A0&1l#{J;4o_ zN-uA;o3yvnZwkw0#Q}ay&{|H_2lz3?%5Dx>dc{E_VxIpK-U}3v5a2toQBSK78g5c3 zD5pZ(He%xLBD3Y^2$bhMpp>Jb0%~uDsHkRtP<8QMs>9j(I`K_0YPTJ7wY^T9Gp7@2 z(CNo-NWHs;L(2<)AN)Ys589BMDn68;==b@Eaq$jh}2 zjl8s}k(X+fA(n>9WANer4eul{ISR7>!?ZOnhYglA&>((Y+5nSf78s)-^ZOXdtb=6o zA#+094E2*B+iSj(!l|n0Q=gpGL8&1v*>t+dk*kR~@6$_%xME)KSpi9>%t8C`n>A8j zNG}wy4UyJOjU?-UDU(;;3ah?j;)wXLMh$9u6sBh4pOnK=3E7GI@_ z*@uuGdJN^T`>A%cgyHf8|8|`cJO%hnM9CtXu(B-c=B3W6V|YR_%ts%)-9U;@mB4R4 z37IJj3`xdy1*#F?a_0_*n#EWAg6#Oe_V}i4385xfb(yZmTar28HE1J}su3)`@R-^HMN5!EYE!AYOo$4?3;DdKOU1DG09K zzL2Rt50_8@Ir~QC>>GkbJTK?`y}Xq3%O6RQTj_9;m+R?f`2KDZs+a1;g^hA_Z=z3n z9=mrVTpDDH;sORG=wh5Jq%CqDxc4$~S>3h7F|RuGWqd@gK#0whIi=d?c=%By+h)C*dWX%M<*B>2pkOL_75Q#a|0qdZ)oHYY7*Z zbi=C9?qQA~ol|m4Si~xU;k!nJ2~7)W1&doP$)&t%PIclmE(7JM=~RuDib6&yE1EEe zAwFxreo$))!2&~;-{aTS^ON=~bRZS;G;6=UXI{fb49Sl!(pBLRmlrW&;_B6L3yfQJ z)ncjlYV?Ys-vayGyRm5p9%OSDM3uJ5(97ame*G!C9IRmQAeXxwol3P;6Wh3o{|AC=-5xCX@gSGG zoHRq#`NXFWZ4#&KaxlurgIw-%kbc{6u6gPKzgofDM$?dQv*< zHLCJ9_E@ddWv_D?Zb|jQS|4h}Bg)V5cO0g_q+NtZW|Y;nbagUuwx(Kr(!7-ffT-?W z@`=Q%OzLFfLxYO}gp=Ppq3ZJD*=;>rCrK;X$dV0Kd zOKV!)JAUGD9%@Cpdyrq@k;b%mlCHY(^t)1=O8Rbt+a^9QUgI-oSpWYkgV0z}{AZ1@mnAcsm19v?mGwTZqqq40UfvVGj@T$wdC1tFnQC-9y7W zio5OV@o?KvSHnPhgmx}xuchrSI)$oR`g+$?n%_z*T~cj^GBf{Y53HRvDB?}^_MmA` z{6l}FBsr$z%5x2X8Wc~rEYJ7sEre)4WeHeN@2amtiV&v zP>SwpTu)UaMBIr$T)9~-B4F?qvS>N17aH{}Xix$JN&dRZjsN`+mKr#I`nQnrfj)#P zfj8Y?7Z*v7MlZ=b{D!Tz{$87y+M@O9diMFW3~viuYASh3SsaHvFPIdU#CroT{Zvdz zr#N5*rLhP29JwI`*&1V^2>CCVn;<(tNYZ?4joK-|UsOLxkZmgH!ki`U`XCVr^0VTc z92_TKfwfh-(81{bD)=m%Q0lQn5*}%yI8bRFzx%+%P(g2ISe*xM>Hffd0P(mUpu1u~ zLk&9jmH&^nH*t@u$lk{*r0GNrkkO2yGEQcu9Z_7!o)AZFx;x#Sq?0s@1Q&=gG!O_$ zOu7Lb#ju7>8x&OB5qA_^k;RQXPt`y6d){-Z`YzqA*WY(O)iYAL_kB;*ty@*MwsQ`$ zQA&>yb`Fd57_}LF-PtDAm9o z^-jx5wl6eM`3jb_jk$Cbd|4f*&w;$EC7YJxe3uBAcB|Q?La6f&WI37YDlPac7}`7?hY5#}P~`%po9 z#epoBM|Bp+&mG8ePp!W5nN4&CwR*x)?p4dzgb;UCVT7cSXw2m@DQ{E>p-%mQOtPN; zc9jq-^(+&UnzAB4y-5i9qehm?Caem|8)nj~LphNOz~zO(bUB%*K`RR=6Uqr)P002F zzMNFN^>6`YLOH3^gp@}LgmPlJnHOLtl#?spXTg^WjBp1@Ut1u>b|la+FU@47{Z z2Q;pnNaVHo79pYzTse6Iw+OM_fh$$%(RJ*;1@_{7WKg~jD|G6atj1A1FfHwBY zpf?&Of1MGG@gkHH0)Lx9t;QZhzi++D)XkIp9L7=Qo&dOj$SX$z+~A<9P&r{!$>zp{5= z&z2M;0~_cV$3}AuLS6hTj$@GiYhWXyEA4~jFy2brGVA0#`16}#Q4uy@o78*v(s?I2 zuYQvA>RokMeNugkdKPo|d2lZhZ}e$v^4YDLJ|5_oB-%UGf>V~cIqOHOA zKwUGC?OY*m#GG1CbrQ-?H?}M>o6e*e#n&nw*T{Ntjm%XH^TT1peN_Eal^p`RqJUJ_ zk;0OcI;_4h$1riSqf%X$xej1$sf-PHu^}6~)FU^@VlO_4w3lTk{%qPs@_r}nn>=aX zyr!N~H$4tcwcx$dqtVKf%ykTJS4T-Dxzx+XyTe*}9Uc7O80HQf!NB}B^*P5O;QB2#*TW(Z43Ha*Vn#y6aMLV z8Gp^H*XYGxAK|Mz`KtVquXgd(n8xO)@|P+KXZ=Uo(6&S{-4JqDrS-o{^MN*FFw^_t zJPjK|rQ@ME{+c^A5sb z0SohJgg-r(wu5u_h3?j#rOMOl_50OV_OqIrpy$&2cnOMwcU=<|(-wtL&U`G!S9sui zM{$P1P7NP&1U4T#JonHS|yjL0$ux*6V8&yw8S8tpyB) z=&TLAA%+{o*4&iVhgMi%= zY>nFmQ*NuoS!baz@O#yWOeG-PRU{s#GVE3{D1RG}=k6*hdA7KUX)9`xIyI<{IQOXN z{3pUHl8=DF2M6y1u~}BN0u>n>iNgb29 z8FlQQq6E<$b2o_xlxKzf&0#axY!q{+f&dpi9K4Tb8&@?D?qjeP@7^K#-E9-sUW(cG z7~UFXmt9-NX0jvW_TQUEr_<>P`|oIaDzh6lSocj0569D)XnOzHXgV@7HDk5gDBASd zH!>xLx6;lA{cSctTwXt?cRdSJbBXjpn1whP**!A7d9r6BBZl2Rc{gO!)6bi&rLBdH zr5UfgUe1_yjXRdvH!@{4t`);u$yOb2%xsOOXEM{1&ujB_%!sDP)0y<(vwPB`8LL^$ zjE+qFsa4^IrZ(rQ@LzaUSj{eD)kK6+tHSbE)Cy-PX`c=w1z1vo4m|=YKuP;_I30eM z8N}+q`z{`{Z#V~j0H;ge(!)x8RLU*u+!++&emz7+(xsMl=u6OqRnMaiWI2gyfsA=M zkfmgzLsnmCkO}2P-d80=+aIiD(&6#0Dj^y$p3oy$7HA*OK|rDG(-;%V?q5w;qgU7H zvgLzQEAo|UAs)m)K(G9iN*mud^_2#hP&RROy+(*?yggknN);rXdc1WRmbo<&)vjDg z%Fltk>XG@sUUV~0#$&IbsDF6tRk8OgO4^eHZ`}jwzYSxeeOVd zI`e#XY-(g?$Ie~5_v{^i;o#{0XD9ac4}`Zwp6uEbjl~naeaTeM<4lGfUZ*kSLjjrJPV01!cB%y^kyOYF_1UHDK-w#ML{zHt59oc!d8zZE$tg-(~wv3*pSFF6-f1aRys0P zjYp;xFmKNELGxs&US5Y5Os6_2e@27Zf2&+*w$x$udF2}Q9sXT{X=%7qojjnv>DU}< zo*|{vW~3IPEdB$_CZw=K7i;bHH>1adN6S707{P#GJ7hjq-KpN5{&yt|;l-+1Ey>xokQVA8nSnxGqm-ZwmJ7=Ka+!Nj zz9aLo8l3R2k-2r+Oj+?7j#&o5Oc3L8US%L%SOlX%g~D~LePr*$%dTek7c!qhtvr)m zF7wb%tI?*>=slBLxg0$Cp(v7}8pN~(wZeKYQhJoqvsdczlB?JxRwh(8Bo`dZve4#a z_nfpol!L97LTQ+e1`i7(bD~L|f&TrC3OO(2$u70H|GoirO}#6xt6cbY`GZ_Ut5w(3 z$1<;uG^sP{u(}Xb*VHxUcMZt-KrJz|>Rmk1D){f9*F7rpXa=X{Vf8V6kEoYCUXj@- z^NG#!u=Z8Kj^;n?{$Xqx3ja8qy4ThO)v#2;o2V z8LSy!tz42>D)W(Qb@2|;w}Aypy(Z@L23tcn6HrUaQBQR()4+OYq^X2s`y4q&$&uYA ztm;GW%-GA!8C1@o3cQ6nh2#4LuVMTxnnPNvN~!+g;ZUWGDNNW6gYup&k!%^BP{-*T zB;OAuk-de8y}Ljv_T**ORO2O3VYp5Nbpi{rzv!xYnX4idCgh+(|58z?m-`>>gRLjD zigTt~uTk%+Yw8nco%V|BDhNQWX19wgv+A`%GNdGdmxl@;kD;=2f%cO+d zZV7DGRCi)WgR~is^cQq1-Vfn?Cbc2EpimGSQj`{6q4~z_5qlh(U3j(&P;tbNqZSR1 z9Jn+xq;+M+foK-A# zlO^+!5JZM#zHc)m(&(oSmsYZ=FDQhuX~<}Z9B85Cu8=2qq+=={?S?J9P$w6*E=BcU zO&{cgO)3Y?o#X22{(n+YbYjd@#eJ)~ScB(Y1Iud<%C9>2s$Viotxk1fT7BH9PGn-} zQ!#YNp$);kCfm}36@`TwOD+V|{2DbU7Y?ZJ&q$)fM>~3~BP#B!(T@mIOX&+`Ez{kd9)niF?|$1rtVeoScnu%I~yY%{rkR zgOkfk*i~&E+f~4tSe;N;3s?VIX*}WHU1^*_-dkxn+bhi|W~VlIStlf{X!FoUo-ADb z*S%{S51Ri|mo7iV><)wIDm^lQoqiq%kY;)SmWQfQKUT^761dNNDX<}B_GB=IhT0ii zn$kFR6|2(D?!O<^whp`Kf7z(fLyxD_;^t5@S|)}QvsqGXUlk)Sr=9A%Y3!~?L-i4i zjMTBhH_!WFGb0-3zgV?{LxCV|fvuw$f>C)fjzRGT%j~9L>E!=yH)Y@+d7U;PY1PD@ znPafXK94Yva|e4f1s_)r&^r_8bo-Yo(^ZXF;9tgOIb76X7M^MJgYf&hho4p_J=UOPk}YjHM+F2RBX2k(L(Iw5-n_3wA2d&}*@P%A>2$ls=> zG5<5=Q&<6eD zdB4Ui@NRuVU3o%muKoNJF|D`6qglV0L)Nxpo;Rl4z+k22meJ- zN9AcX+i2Hb;|c}qd ze52sBM?hpmo>Ip)!T+m~>hTDOpk6UI3%O9RD9*v#Jj(4Fk(a+=a#QA1JBSTfvHsqe zwZ3J2^VZ41^`S^|eW<%@eJBzQtq(qC+F`cR~AeJDDxzGHnTnq1$sJ`^2Xzjl2n z+V5J5vgnL4FESf%Cl0S%2dBK65AH?x-(8-c$xKeOCV+=kSgI#P|H#Z<(iafJn?^?_ zHcyXC%uJ0;rzd#r-5hpqjts^u%s{j{3b2Ej-RWtwl&pccan|BBF6|>9GziB9*&d|cVQHCh& zG|&aBq0wwUY)X%(M>BfGz8!tR^sZ-}YxaMrE78>2*4#p?_I#9EUEx*x#;_0y*0m8z zt=c~gf9lRqa?$>2oWs5JZy~DnW;pi#g(WOC>-;<+psRVX%_&is6<_=7hkzcs-475Q z+49mz2XN;Wwq!BiQ-ptevlY9s8ha?Z}~x@eW>$(kd#kf z<%IX7e()ocOJCjakFCaOPDjxDLGIoG)$dk6Ks?j!et;;Zzxe^8=B@S%e8?}b(GQRd zv&|0_kJIG`hyhj7FYrk}K+ffEKTsq-?FWe0C};g3b#tHdgC(h_{UEi}xBXzLWBAw) z63tzHO!ykK~iUP%ny>EUM>6y>|1`Ym{6#X{2(#JR^RwW-tdFOIjiNE z-8(|b&IXCs`vGFMu+|R{55C?nFzE+~JU-zEh^HR&14IwlR}EOXQk6mMytA0W$o!4DMgQy%k! zq_4~wKS*jz@A*c4<5TfxYG|1uW;NiaKeXwd?VlUjr`a*@=M>y?|dV#`9acG@`fKI z-e$lY;nJaO|9^{L;H`dvclrg^`vuxZN)>?H4%i2Z+^$89zY0ng99$QV)E@ zH}a$(B(3zH@`KbXE3f;(lGG3UAhG@>KlX#v>3{79OY5oE{2~?m(X&IzZiCZTulkXS zr&90uL86wZPyHZiW$BV1B<-|Z_k%<}D`1kt5lTKhmj7z}0`Kw*Twd7**pB!?>L$GKC$Mk%!O~#rBR@#W>lc2IcvH$(S<#lzH9sk$dRs}TM|m6DnqBLK*r35UB3VwE_o?+l>~-KusR!c( zY<9g6WRU~`Cxy!ith9uh2Ok-O%uIX#-geN63y)?paobg;=ezM&AF0p0oN+T_?kDFs-UClBRPrd+D; z*nto3Ur|@o`+Rj#eM)W!?VuLbMb^Fo6s|MjeSD4jm}8$k0JQ@lpxZ>g{)8BoXUO1} z5HD-IP-n(q1_J`7p~xo0KmRG=krP+cb)7omI)Ur*1nRpGV#`DHkNizu+e@*>x4^_4 z!15J}2$`>!dA|0gJo^I0wrEgEi&~vMfI~*u1m=e$B3ui$B(1e?ZSUo;tVE|_*Q+WbvF+kI>gs> zsI26J@^{?@>nB_eI>}Y5*d+1a{|@UPLj2<&(BTsz6oO?!A^!buJ{fxd{V*#i#F{m0 z=--DQ<|CkM*Rq|KrAtxsg=lJm7K{+Bt?;`lM0-0Q(dg{trNsaIhlfX&#SJbT=E~aL z4WHmb#N%=Lx3{;K{;jUYKuw7Lewg4AVo(?I#*G{4Z&QdvLqqiU6HmY@mJm-r4edE0 zwr_{?LLo**M(E$sQPy*~c}+e4kFM_A$**v1jLUlOUakuh6R$jUM=yuh{MrI%ozPKag8&`ApM^2@A4A&=lkm*jE$I68+PN9Xb5=qvbf^i}*g zdKy2DzJVV{&*DeX6)W&L5<{5X0HKaS4f$I%>q6s@ac zRb}-Geth>;{5X0VKaReEA4kvP$I*B2T@G{5vHI>^ow>9>Sx^t%kR|3x@%D1$yu^*fODmVu2X%Z zKG0Q}GJJ+aIqHmBlvmA1U{RjuhEXqn(EXI0Q>S!R-@;`^@Yks4<`gZb-HA`#`JT_ zd^ePXgs{Jf>PPwMGjwgEd{cjl)S|kgvnbDQNHxz|AOnH%_Wc~UAMYrPWXB0&t%a17vIpcuI>Zsq7ncroSZYZXGQ$id8QWqLO0d z?}=g%O)lbtWb8!2hD}hc#?@;S#WSfNDGD16>U)Zk;`=ugMLDXA6or~UnoK7DlM)r@b&YE&vP8j zh0Khg(jpF*=_q5w4^y0)s=UE*$d_=<9u(w;kzPhnD9D#r_&VgvA2<&A@>`BWJ{gk< z3I+M3Vi=_9ru>{B)lj4Ugrcx@MpYpwRwDWVU9Cs-U5c(o6ncw6u@+JIhYX5#MBxZ5 zC@e(bS0*UfkuF73xQe2lv-_KEK zgwJsFwMs!1A0=HW#6G?Xn_qi4dZAK?T^#+cQivTKy;XX?o%9vTr@Y7 za3wp93$h2ijeHey2RRD4NsdA;T!;tB-Y^{W21Rv1hzP~to)axRDB#@tKNPDE2(gZ0 za5)W2&OrgM!_5?fYt#mc!Q9PhzDj=vo35u-&cB2;*&jf_{C*gJng!ntf zrUF8&qS(QJ5U}|W6mm8o#O)kC84%(&j>6h7Ixv)HK!{}=Js+S$xctY3fFR37sJL(r z&R4I)zBxq|B$ENjpimI4ej#;s1=-YhqEHdX01u^#IL4eop&*>b66hfizr@!eUcuvQ zkPIBrC?F`R;WGu}-k_)@M=KOvi6|WG1Vuff?^1L%qHuZ|6l)R1fIBGK5ydb(C@e(r z6%L97qL@qvMG8@TGJ;|&qL>r~#WRRv9uO3};R^;I=b)HE6a(U*IEW}57NexeTMWlf zB918tx(USbSwUeVj?p;2ZHQyO92D{b;!ssbX(RqA$Km>v=0`#HF+$BJ4hr(E6clijn4xR!K_Q-_m=zRcEj>uiXE2KmiWJ<-Pz;V{V7ezL zo(T%_78)eSGsARkDkubI%|UT6D9E}ria039Hc(K=lR-h&s8PT{L1Pn?Z%~kVY!q)$ z2u#~ixWhO$|`m(85H$Zu<(j&tE<@hRZy(e zmM(&#y^76;1%*|`Cc%OtQN>F3LGeU-e0=gioXm)FTnz0V%cM8$o7|h`s2JLv9?6I; zW0T|Q%*ON%9TS_g)6Zom$7a&Pq2DYrlkia|Ht!yr$&9DP=8*}pDU(i*hsU#Nu?c$L zyEwI(iOBp8CL$0T?(^KPVk(xZPBRx$Cq{g%RL~3keub4_t zXGJPKGP*mJ-MLewMy5ud9~s&`HYHLc<7xZJ@t6JB_=|HyvB~ir>51vd9b#~LboUtk z8JXCXM$#M;gX3fS)6waXXT{+7j^xN_S`3Wr=VwI({~6gcNyRVrO^%L^%#2Nl{;`?N z^BX5;(xQKCA_J}VeWHJC$HdsK-5Gj{{`8Kq>^?h>{I{J;{@Ypd`U;BPA)!#bd^^R( z#ee80;y>&M<-cQ-)9INE7X)8%NbPzqJF;(NdTb&s`bVZGCnrSz$gcE6W<-pSO{6D8 za%`V2!z7+aS3!!~)rS8pR2BPAN{Ii|m4^Q?HHH7;Izn-J+Z3Zp$1(HboQW4MGA8o; z2=cmXcP279Ju=QwPCdPEaw4*OZ0F9&36UH*Fu?_p9NC|q;EFc0Ta4?!MBna_y<=i* z|K#-ZqGw{q*vJIxM`DsQwtI3S{rryf0YNf!c32*=+tI=QwDUi0{7)W!m?UeRtw8&(f3$Z z3(IO@SuHH9g=Mv{ECx2StY((g%(9wURN8r)}a5Pdd6{KHz&kIeD~x`hC8}lBV!XY&rVKH3THnO8%Hx^ zL~Lw2{p|GE=w1<>+_6jd-O;gq)Pkew^pt7)h*JZPj!f_64w0gEUx*uaKT`OM8Z!N5 zIu81S`wc{O|Ho1E>KsLX&dn2dxNRe5U$dW^dXUk{>4}-K@x3B4IX$s+eDZ*P8tzm^ zcTbK^qL&k+yGN!o)9LI?T0};6q`9YgHak83{DH~I9fCh}$hCe-dVuiw$i(RG^o}lk z5_jOw(Y+!(HuGFIEyC%sU1`zvLUuYW99?qPL}u){Y?{ltYkX{!i-MQbZM&9E6I9rU z!(k(A+M53w^EN`L+!EY|IW1Zr+tQ@2!l3Baht|U;TuA0$46TwsktK$F1^i3N!|D@S zwdzzKW>>+?*1US(zW8*gK3fArmbL7gsZ$-vtbi@8!_}SY%8Tk$!G4y^2Y4+QrqD{~ z-8=`9=VySGeJp(iX^6-%1mk?(SV>i<=(%9HE3oPDEknlMTwYz@Q$M6#y%>vMnSVg- zJF`sACo1I0YW!o#V=9+bmtA1CeyTo{^HnmhuE}F+Hgo$5c|*PCvhH^>DCc7pG2G6o zugJojBSm(J6;LOvB_sUaU>SE|t6GH9F8R(Hbp$qd)oFD@=4-fwHWcw6dTFU#*pB_n zO1Usm(Wx%JoR$lLH6DH)^EZ0=S@k*J}N!@)ypZV4q|wpFx2R@%kTrV&wJnXC_PU{$e>?8B<} zC<=$KI*NTc^)6k-G(z#RV;WJcI@SrSd~?mA9WJggw3nscB!I;JhrWCRJibgz_ zyy^`?!@+=#?wU^Xl02sV2mx)XPGOC+s!VG%HJaC(HB+0Gf}T22AKp1Oj%PrCDM2iC zz#5OSlE&drd(}}_ZhewBMqLKoV40_~0_JsSjagn*Z@z%S)B#mwYZd2_cXDBq7lDW_ zQMg}Ofir6e^74in^^^T{FyM*+6ntmc);5qvWd+_7!WMZ{UdD2*wi#6LMgy3eh<)G6 z3cZ^y?o(&#Vm8g#r~}ANLtj`~!9Ai7A@zxT6Wb;xz5nWr0N^Gfi#G9&dk)B}HmzWe z4k$MdHOb||{E_~0mR&d%@ zT;8Q%!*5TQ+Zik0^Q7mGg#z`4`K>$mf(a_WP6`Gd_g7Tf@H6R~YwS%IQL z*e*YkpLg55Cf!(oa`SK;hV2+4sQk+T<#;Rong^7dhdpa&@u<(#d-4*t49ruGYA%p& zF7{mP;`zJ$>7F{9hUHEKfZQ}Tvc{(sgs6P}kfXZFbD9Q_o5tRH_=O^{H;q`M8?JcDo^V>Ih(NBKFJd z{zD$0mZv6c-WJUR%FSbEKj!&nQtBIQXPfjgIs%lN#}0r@2l<@*RDJ)r&7)l~1i;)x zcK>6)MKLbVqwSj{^+nAD&dtQ^%1}7VYUE0OY3Opj>64XB?GqF5sxD z@&}zDaBe1!``AtDHhEsX4X36ir)ohnfpar)D9`>jW*@G4&O!TB(*SbQ;A+&)>d4CH z;SJ3sSE<`5KyDgLSUZbUUYFO@&p5(qxc6u-kZvxH3p%-KQ685c<9L?guG3r~-CUU7 zuB_mrc0#DD>h>TPgjKxC3O*`_9ipD6Lk`{z%>&BK!}$<9#Z=c`oVGCOsZTWzC^rvB!73~GKp-}g z9*}3-Z6fxX5P)*?VD7^%(0%Iddz~%g0nG!-&BN}E&AY3$4_;YJK6^C{AU6%#h4$lZ zslQjgWz+U(8bEFuPLSHAsZPls9>-3kNl%{AOyJy1Y&h9n_>e$+gm+&r9| zs;t1E5J7#dzO2BOsbQ)!nhBhniDNx>FC|ZIQD-s7EikWXCU9;h_Q~wtMqTKaA3S0c zYxS2MC^rx1Y3=!udiAgJRh&09DL$ZyfVqkAdh2Y78`PY-jBQ&(4QncZZYq40+TBg} zG%W%c+ICF?$W6m3H%B#nL!PVIX(#uR<^kpA#oWBN2jvMI?J^0<4>c1wHxpZujufxR ztLpk~Hd7teOyJy19Lln*xOz){eHZq}O`7Us%>>TP>>(!RK2&+WXqIojWD}R@$rey< z9(GdgLVZSlB#${h{{PZEpxithcyzwUf8L>>L2Ysx)MeOSY7^xrnhBhniL>_3r<8BqBNzT- zQ`K=z1<*~!p*p)4cyxN8!a@5;)7XKhbNsi#lcM@MtiG2YI=G9P3#2U7j8nhL&)u_?AVXHg89P2b7zKg-e^Kep@ZiIlm$=6{rBZsW{kbQ{}IB%Hud#RHz4M z3tS-GT;ohbv@PN6AIO=W_ z*U1~|LwVRHKB$R+xrw`os0S?KpqhIwZqvFo4InoSyDxTn(Mk2;2Aj4`(*SbQpowGC zmTp(a5;kqWrUB%p?Qzl6eE4aog_u&2uWBM-ZX(V~+3CsrOx(GCB`;_qU~b~Li3G3BfB z>Kf;=aEe=HX15&0D74_!|zk8Qx=>2b7yPO*~W6 zI@HxY+ilvArUB%pK{?A#?)la7=#w^WLel_p({P5)rnTQG-;UTcIj4C*xp~;wvU%#- zQUR?c^K|mOCIaRr!u60%lvkVY#-Yjr5vxiFfVqhWT*U0IR_DrP!n)K8~%>&BK!|s~RQ}L$4@%fkyA0rYTj64&O2m#H6}Q)cyvp#tZj;xwyGt$b8{3q>H4WA%%n0_UMZ z`Ol`RWAZEc4L0fxxlYff25ddN5hZIjj8>b(5W zxp1rAHDn+?WO(Vc$#=`k@&}x*C?tH@Z~^piasJ%qJ}HmLFL4CkaBK8x8R0xsoZ_~r z@`E~c0cx{`dat1Z=b=Im%BHIK?^Tzb`x}oLDsUbu&d%G^zwcM)aLFV(WSD??m^guM zGq=apaa0|{oH9(nJWS}Q+f^|mPpV^3YBf}uGh6^YTpatiQ>~Y0)$y$k>PLnOoQI0z z^EP!vexc5FIjBDyDsUbuRC;Zy{6_u~b8gD1*9{jy4;MNMHdlQs=eJ=)-aM_kWVir& zxH$c9b01XiOsOAj>Qd}GVJ~Ores$;p=~!cL zGfcodOz17xOm%UvLH=T=nKDekJWS}1+sxIgR-vkz%#Il%P#z-GL~P>NLsicGXL-ah z0rN1Sgl$*C7WtF<5K1g2QTd+X0_fr5JcXUA{7lZu`E3sFWy1x~!-bBE%~hYu@8xO7 zVw8HtZ~^piq5Nxe*T}DLQjR@7^_igp=b^&Vg-zWf-@nzlnyqdaDsUbu6m)E={8GKT z-nnCQhhDKJoQDc+7n`ass2d@i0W*cX)=+`-P@(&7Qy5IS|7*Aadbl{)W^>i0&IGRXhqo- zQT_0UJO|bB0{3gf1<=FAVIn(Oc}9Jec-p3_QnDmAC_P^L0DR#y!dKo1u>QZ{#+x~g7-dc5H-*V|Ww^H9HWQRO-LnflGS9e>*A^pB0=38F_zA-V%)|WN#eAYk{_0$+oHk6r zJWQz5*=fpmpOL4X?pNi!;R5L4LOspqs`oa?c??xdhUF)Q3!sPlBXP}~SYEzI9!KLW zaDO#i06ko&13J>pZ(i=0Ppj7r6EF`G%5^qV&ZqzCSo2Yr3==R96Nfr&X7}@Q!8xW~ z%Eklu?5BqbC2*S=NXWC!8QDFC37CfowLqJx=I)liIKLcih634zU-V4${!6AFb@+7nRc@Bi27E&f|0MOi0YIf1L-D{u>iYAo$8kt zT+}Z#m2e&^&tgseZ+KB&c0R0HG}PirEUA;)=P1c<9~I%25B zvsgNh>e>^Td+zU0$~DQpY`DeKSUMDLZ#qW8ci=#>AI>vN#gs*w0h%s4FUew}X4daEs@%q>5~}gUA+n z4ufEm=iBs-Cc!)}h$pgo=}f3gFRBISV(LSNT0D&&<{HB1_oFNxaW6AE0y=nS_e7DzmK15wG)Z%$8nGmweNqw_Ko^q~R zRqONfg!2>>Ph(BPlRqEW?p*8sw_z5~V#(-^ooN5ADO@p68a2e?IV_o_vUkC^Wy$5H zAwFw}#S>Ukx_34k`Pn@O0(P46nBf*rV96|tle_Dstm4x~x8No^yZQa53feydR#*>cenC<@e9rX+N#{ z-Y|=2vSh{0t`zFV-C4)ZPc_b*gDF;)%x$)o*yL4s@v3Lecnn?C5St1vfJB}a8 zykQnkV95-g-EpgH4NIKoD&&`jT0DUzqa@Dyr#`)#t%aG|t8#{|r?3u7vSf6R4-`Tz z;(=!M)!oJ<7~Z2{el6;$4%r4-$wZmWq}Tp6X)U?r^IVm7Lm}|J4HNqu@~;~C-xkZ~ znJSiYkh7-_g@WqaV);BPg*F>L)M{3Ka0`Z7TE{~yg*F3jd`}4s@0?B>9W_B$5LRjs zUm2dsOwVMnRf@omZ7Y3|Z5X>Reymy@ckGznXOiQY>~Ln1v~O)u5I(xwDI8aJWKlo} zMWxL1UsDPQ>ignS;F+#o_7awSR~<%wYf9lUldT_%6X1!iD}f&=fx$b47@o-P+q^ry zF&^HS9-W-tF(ZaEu0PkWAC6eVYx}Kee^<(4TLPq)ygt;`WtrQp1HF+Reb;p(X+`6) zUTdge3&eG|B@$2ZJ@@5Qs(;WTb0Mzl9ew>h39DeD!ga4T9831-d#)QDv3P&XD(G&z z?)6*YR3u?J?2fo@x2C$g`YpCZ;=0imiATCEZJWe(r)i)!GGJ{UaTiZVPqZsy6%0|h z82wf(o(fwI!y2yJ%>${yK?_DsT$ek-gWX}Ppo8wd*V`TM=6g`+cHL`Bh5NfKt?BN% z(;AKShAlRh;=0k^6OKkKV?M=wt3TYGvW&L7>sHc=cg4Fb+s2CPZtFl_GG?)6yz554 z)zg*evmAz4T(>(S$)1>1FwNq=mrTW?R>4?{>t0iQFdnxyrag70zqc=Ju|XFXJZbg! zhr2D?#*6E2^I&(h*Mij-&*fNG%!1(n_vLU`cg%ui7}w>Fa9?u3D%gr~-Ah`jfq|rD zn~!nb9kf!Zc*Js9l<@#!kuJJly4H8Z`@=nSzqla}TD?8dFyA!xOkBcSBeAZ8#fA)A zH#+*0-ASuptj2Y(buc;Dqwl$HbcCb*JyyY>jq6@pA{8F6w22$no%UF7xXUs|Z(O&U zQ}OOWy5+juZ>0u%lDKXx`{6FDzrU}?VoNur`?PSE6^#$}X-w&t8ID+q-mav^lAIb=!qH@mZI)MQ5}QbQT+t4km9?RyB+ax zw|)U73NF^$*JU|vGr75agR!Vpu-4?dhi*DCV7Ux9xd834{&?InCY@ZjT4LcuzeR>% z+}HbhBi$C6eR5szi1qi!t%4ya*S)q#q&H$|(@?HE?a4$eX&GZtu3P<9Z@edF(f6Um z`)G;w^+))wi`E+H4TmkZG3CC|6YYufjdstC$Uu^Bw7G9Y(0!7qR`-p8L<%_@dA_5? zeIqdtN2W%e?`U@4i1hR%_(qfaMo%Q%#Wxz=HxdJVy?mp=ePbXI9poEpT{l|#27CMX zhU^T@C{Fi^mZrtG1@&P5>IwTnc*ps{%~(M-|&=3cb87WT_A%=okE+ZK)S;^Pi-DX zcUOYnQk$nh2Kxs2y|#G@Bpi$JTWa$ZNHW#W@3qZSAcKASZM1m`q`OPMzcx>SBvV~n z+uA$@5{~t9{cQ6TNGzrw!(AY$0bL1OJp~d==xW>QDUeuvfL~IpS5$vDmwBtFK%yyr zN3EXn=ueXouTC1l#qEW7#t)AlO!&m~%)sxr$ z_#hKnJmnGZPjCt?p7MwfM7YFTJmt}!Nb);s@uU&$>Ec$|;wg~cNH4d_7EginClXw9 zT08|39~k7i*5WCU-bjp}ufq=-*?iw1ME zl0968&7Kk&2#2{0n>{5G8SLX;r`eNuPj{4ion}vo41@=`?lgN!B!STYW!F<8Js3*U z4Nr+g2IE|zn>{6x>Ko)z_oST+>o(KmDUonex0xnSiG=%fn`!ctNU}?}nI=z(bfs%V6iC1BR2x0z(HGa9YNMw-V!gUkZS<5!DyloxMo)S4#dW9J=*euq?o%5* z#gW1?2`WgVr#NE0x=(HN6i2L=+p$MbZ@+Fa4W817#&wHn@DxWhp<7IYr#yNGbc<>5 zlt(0eWNAS7ts_~@6rI=HyERPE=tl05B79f zwy{Rn-Hx7AYQQR(Z*<+m`rJUjRc;p8ZzZDrgOrTHl&_9^49Ofcjx7(uwJyE(_G!aT#eW`e_1-p(s+jkKMt)66} zo9>pL=MP%_(Nq@!O3wlZt?u4|m<=c~nMrg-1{hFkl1D3coP`o|yrk8e8i*6S#LPZv z#llg3I9>sAJzUC)MY~zDZR^s7=;-O{PLc59Nl(XMG8LwKrIxG0@i;$pnJO9SOGK=q zDPen}D>`5qGn%ffAhSIKmfNzX3(+zdOGE(}@ysL>eS>kUV13iYNm>zn9BhM}uDc!a zu5iLCnCNuhOQzyIR>5ee>t0K|HypRfjHl~*(uxiYbX%wbCF)vpU#g35x=1N2(HkAG z+~z-Bh?bsMcNl#=aS&muFTuIovwd$6n5DzjpP zWsF#_$zH2qew6PGADr5^F+H+lQI#+!zTz2@0d=HX7(5Mw4j3@ zH5-2>+`Oi~*0n2#0LKav_95k`+OQE0aFlbBcq=?PXd^h-RVwB15qnq<2H;Ug1F^qc zPM|skCkp5ONF*#*!VLq=@FU>xP$?&p*uNrE_|8z$Jup%v^Z3qC5{Y6|pPEAqI+R4> zAf5W$50W-Pe=3c%_f`?;iGB?VQKQXdlq+`FB)Yvyh?vG9iE^dBqe_U3N8bP1*QGqH zEY}`4n_uWy~Q%B|nu>)R5 zhQ?ruuZ|3zKxMFwEKdMiCrIrOExnFibMQIMIzfl|VTGYi(4l6SovLGBA~4ZW$Ieoi zh){{{181a`>Z1{;RaF8n9}b%M?ZE}okSWN#{51rZP{yh+3ImRjP`I^)7h;$ovUEJ_2kX zu+E@5J*4; zQNPKfDyJ5k)U5hJext6b(>*c|jYze)1UZ?Wed*m^7 zCUZO4fS%u8VJ!JwLT8FDyEBz5lc|I= zQ&F9%lqXY3ohj16YaRGn0dj>4vgdA!gS{TPCQP6!|q z*ATKo9#_Z93ovaEMjv6iE=aA5-KtQFV7DryK?E~{b%In!V5=}F=&UtNEC#6sK}Jxl zs9+B)b>yUtf%jCfY0EmXzJd)M21PfVn~}s_*@+j%rs^MhZnXZN_s;xNJiO}#F)gwa zqm%olrqeSs^$(dFu&5%$I9e+lqEdj79%xOVOLuH(3~| zz_7@1#0izTvI4^$^j_*?i#%PLqcM5_B9_>vfmj5-qQqrCIULLtb{y)&u+L2A6=U4p zmSc|n*jKb$TPKY)HaU0?1L4bVpSV(|<+qQ^t4oSb1L2V>>BtoZVCsuU)Hm?zer zmSOtaJPxTllui>O9BH0XU#X+&l|WIV7}8W$V7!L!OqV)6m9Uef!{7)(Q76+L97e*PLtZhnX zKFg26IHtp`E9LQ+A4CcyKB`VNhmLh!YL*c-Z3ZdVS0K zj^{?#x2z9EBI`qu*bGM;=j56asYKLT-@NMu*UYscnHaR(TfpI{m52=_ExXHy^xqZU z815TLS?imhv?r)2s|dYH>VBgm88bQkqp4|IORJu)^3=4Fr>5j-5w9De)ZCOz6u3gk z$tk9ibp9N!3=z<$m7COL@Nt93N(B6a$?5-mR&!KcYTqLBnNSq-5j7VLtwJTv1l1f( z=ioHL!U%O0CI^Ak1~YIq{yMU2oOjKrcwuu0!`SZ(dLbHm(D4zj!w`2nWVAcKyk-o7 ze_`jB$K|kWX~y#~9LU3YSb*apJOWxRUeFTVxOv!K%6CJdN)*1yfBK887SxAwkxq4& z{3zo!;Vr;0l$?s9;SO;7H#`w3SESGY{Y8_w?Z+u|D5wl{E-;}#dti$P0x+JaEB z!Qp7IE0k<-blMu;Gs$Bu0;*K0l@@#xpEVyw9rU6|@dCzLLwgF-1I!)u2>&XK=?$Yr(X`;GIu=q#X{PC%@w2;|+e{-ps*VMiF}(dL z&7paO0l>qMPT;-l@6zC!s9r9_D@-HTdBfD@YWA<2^u&Zxysmy@Z`*dNk8c{`ssF9h=zIKQcZ(IckPN&N0l*YwGun&5W9!58;o-8;vb3ZO-1WmV3Xt zrGly_Ldo6_3*4?yviHNPdBHJ+3FU?x&6Pq#QO1tZhI77&09%^_@Fx9@2I7-jsy9Wu zT8Dymgpy0lXl#9cfM|fg^v+U{fAb z^&pvE$DlJv&y7{LAQ|!I6+3hoaCZ_UW6&6i21U=r{*m#q9ratM_H|EBPfm-iQ~M&5 zq!0j*X`^1%G1tXahH8M@Q2$GX)VW5CJxs5loki=3WIu zxcU9%R=@%G>^RY49oGM%A+zM?SlI*EUc*BQ2qwkyYk1VD7e2!Xe|pAX2WRs}Ctg{B zLPuD(`{p(Em{gb?nKsXBc+O84e=f}@Y#=G$Rj-s=Fhie>ekrBS$j`cM>9~f#%VkdU z=DaqBE*wG5$&Vh|NHZ%6aKM8AlzU}|*UC`i5bl2Qept{mA1c_P>IzsAWwoP~ItU}%p6;NDxEHvJ7f5-54OJ0Aexy#z z*LT~s?B+FQSrKb&?)5v=K(}~aKXWz_ygVDD&Zx5)*b_n%F_TrKyMo7kMQX6lMuR-s zqL_tB{5P!D9h`#W_3Ri)ji)ozGi}Pi;kp^>g~L`P5$Uyb@3y|h^oXuSt(4W@Gmy00 zoumuVZ}lZoVIWMu>AIb=Qpr>tw;f%n3o&TL22u$i?B3M{NLs1EegfzY*L8Q$N)2=m z6mm#U$^evTa_rgZk?H5Rq^D=bCMWRzurlyx#$#MJ)r4s`*+5tdzM_t<3k}<=4^L2bF{~b69;T zy-`ZN%>UgW3*81nc3Pc*Wg}Aq(b5tAXpA+oQQf$!+z^X85J-|YVw+R8aBXeMu_FnO zfE;L@;&;DSJPb2~JcQz}FAurU*&wV{KdECd`DC6Be#8*4Kk5GV@({}@ym;@7hfk=? z2oK6*jgQ!(&3LZ5NHhoqZOC-h8A9M(d*4i`Rk;x(PDwRUUA!z1VnxVm?lkI^}}%rcoDsM+A^ zck{72oN&q9{7DCdYQKi|L%s3uT9U-BKGuT!Wll&;N9KX9`7L zQa@J1*sv)bzg>^Kd|vFmH8H$P_n6#@n#&@bcS+GtEN(jRh|KrbDn~Lp7P%qd7aQe{8LUK z9Z!}&{((q*w&aaU94U4n%gIz1fV}QNmg-X2!aNQ%pV3wDck_uQLN%+As9U9E(n|Au zK#03gZ*&(>E}NmHLNq&YN*xG56k)9ib^#X#_g=SB=h$)sWa-Dx-9ca z`6dnl=j6hR@=cLR%KS}oesid<{V&-D?8vW_^EmnV+PYwN6`hBylk;7CC00Sl4i7ue zLY{9@IXVlOlSkD%bQUs~`HMWNz72G$-(~_x<^%Ps%;O+nE-QcJ1HIdxa*rvULtVT{ zveJ)W&e-vweUr>T9jf6a+M!MMh9R9hu9ipFi)<&xxGPhRy}xRitD+;CHw|yMw*irX ze5_jL2Lhey@QbxZ7>)LEpz|i&wq!0=jb+^Jg$$$LM{eq9(USM_;3EyRK%HDnXfJ!$H?Eo`?$GUc~s2>`m*X% zb5<0kOvUP~2-tJuXNH$6E@POP!}y&`ws7L5LSI3lSLwOjZhYKufCSU;xmW-m0@Yj$ z14?rMxA1bS?8n5XKEGTp)X0=r{EkTw%8f|y8N|b> zi*halLwROEVusgd#o1nHM9*z6&23Uw_BEE9>)?wBf$A&y{U+z(8Z*P=vzQ2GW^9fx z+Ufb9{jl2>`U`1kimw_t%$TP29X5XapeC6bZN2cn!9OM8km^MtX^n zncbVlCo_dVdL}aI=?O91m6_bvKe9JndJBCRJQ^Ivrza2aOs{YWv&4ct0%3rOr@{%^ z!VuEA$6jU>+1}<}kGxlpB7eJGkfSq%Qlm)qz8+8%0uLh{CwLKP8{xsA5CyN%=m{-h zsaY=+txLX(%I63rx5bgNJm&`qjQqq860cl-uo|z>s18|gE@z`J_7=E9rN1ywh1M>IO;lH^@F6Y<8|N2_evw}uRj95l=73?g^-su z+&uaJdfI3T!4(Q^p&Mf(C#PrXyAMv)heT-W)IPm~x~{(I;pV;dA+yVc z2_ojSf5lc6ro7fLCN(l&ClAx%)h*SS-5gcdE1@zBhb?kmp8Xp(9ibC>H%*o2t1T=j zU`m`>zD~_&ZeCOGyqHx#$a#4J3t{q@n$5&yexO>;S9IYonH#8HA&+gU5Mmu;R>)&< z^pkmcst%OnDwkQdt|EJrYbx#$kyWqZxGhcE zY`u|(yM{zF!TA+H+t7?UpFqK2#*Y-{y9u ztU6+zl_riC<+Z{CW2t++&opITo<-5FkT-5#QxCznxaF$+kYm-n+Po3RT(l?-XD>0D z$dh*+j`BeboPn(qT@^yd_Es3Ee4}uYwi%cuuU25JYZe965j`w1d!3jgVRc02$3rz+ zhUC$g1XXMJPLg?foNCR&HY}UH-lP_x1PmYRGB2;tt$aV#+HgE3bN$uwa7KantkwcR~QwaHO0lAQ^g8~jMuuxGfN3OXbBB<>Vs_nNFYWpqf;!Td_ zwE&Ji*2ThPYq`DzZWoIEE}`LO67Z&6mX$@&vh0Ss`x(H#uw6 zz+hH=t984fQjo2~i#i#UdAXnqROXVQx^;ia{71KmcIh*_hoJ{hAw+hmk(*D3>SA1s zf1z?eDswN@{=dqj7l};D`J2iV2-+tAvmIiEJpLprC;}00JE{^JHa)(D4#2K#QeVs5IFzSo8E=I=M(!%~2jLhw zG?DoOI0Ath5u+LrY*O#Z`IVN;1=U4Y2ccCseo>2=welz_Jy#rBwx`-rYpT`7TgV%w zkn@49@~Aq`Y9hCw?|hZ}&Udo%658;p@-k{C~zQsBJA+uC1#;esuc>@dct3X^K zZ>+RpG8eCwC%3CbF2QcRC!YnJ{fo1JGr`XBQ2n(08M6EFWvd>Rd3Ag{Ka8sv?}REc zb-GZ`#=2)vY!QN#R1t*?~}6`7DPTYxFc8a*2Xk^$(aSc zeI{+JFn6CR+}%^Siy+_8OR$ytyMSC8t^C7^>`Oo)Q0&IMq+lWgc1_UNZA{^2!63$A zb&QNol+fkjQo)cBDb$gLg3X1G5r(G5H~`(1Y_%7`_mYl$a&_Wtho>-+e8t>+SH zozoE?^G*QZl015@?OBi>T7c2$qWSW5K-Ll8DXENOnQ^q*1kG|W7g=XCcj;XRXM$LG z1;1B{xy43TH{Hb@$dl-liG>U~2T+-Jtb-MFH_R8npSc5!n`xAsY*{mmV#&^8Yr!4- zG|LOKWoyLO&3fljz&?;xxbsT2$k#o+-ELRx;t2%V$7ySkm`iRI_i*!?H32QdU^UhF zuT*2ujsdTbyq=91ehePqiT#Ed1btiit2wmsUJE?6wxqwlb;$fnOR_Tm%vG+UrD zY?qFWJG(|5B!vj#UIka>`8%_!?Toky#GFHFZz|p+6?8786ZNR>_w~#bb+yvw^46~v zv=BPYi8A5tJfnIDq&wn})y8*0OwST~@g5Evo8Dt+A8b%iG}y)`0-o@2-Hn1;_;v)GQBIt1V|fRFQ67l;`D|aNq_Y|zwkbx%!fyG%n+yD zSaHew#63k8fB}+U*dOHAlO;O)uidy^ZruL#-i`PN$TgFrgO>5+Q0DOPm_$JN4K@^D zE9sZY5#EamY0$Am&J$GsGX_$>6kn%b;=Mdz353lw9AXh0q-w!{*@u~iL_td=2!=d> zoX%`(RPCoqVE_SXg1JD?bAi^`LVv9FvaMHTBT+CLSl&K2$RCNT0!WeSoyWIk1SAV) zl*+q0UA_2%zS{2P(}qscV9GB_#L#;6e3t%7f5$Y|gm};pkS#k@6Azzy&zREpR{h$T|pPc$KngWOKH5Y5RfjI6Blz|iGN!`e}P7h zCI##m1SBgl{IWwxn8G3TvkE#FIVv8BN{oT7rtX2(AvNW(V*Gs!$x=83;UdD3hs4Ea zyz=QCMG2`SdEwV!4w3?^KOB;JMNoBI`RE~?3v*48LaLI0IsjSxuq7Tp;Yae+DP>i|@=pTx@Rt@sRvM|{7j*H#mOnhw8%Al~*nz!o2>tVjr?Icw5$ z9?Hv-$7>XKF*RrX8xO>e9{EynnLhNnDi!w>aU?^%y!8xeq}R=oG*&J2x}nAdh@+m9 z6PYP(@wq9T+O;>)Xg2NU|AL+n>XNCJmPF&`#`;FHsWs=vExS^?Qpni~@guO&d~j$R zns@BpnP@bVZGq^z-5n|T44Vo%KHSv2w`otJ(M+{-j$kFW?&(N(BpS`;wnnqL9pxnX z-&9*p!j8o59ZkCvQr_9P83Ip6Y}*s4!p3AOJ8#ixitlPSwaWjOnjT>q=HE!6jt#NZgo?hCFRrzz>xhv7JWAE;SPd*EJ zn;PrtUToZK$}%w(+A}X%%KCSJ;rE)xM@KVbQX>sN_Ki;t0iJM5Znpyi1EVht9Li1( zj1Io!QrOqZpUSZKr3n}oYpMZEnXZfkl?lcwq#2d5X;hZZ)k$Rrhcc78S#_zVwzdRr z^MPL5)Vy~OVgr#|+js0tsQZ5KhnCjX-5BJgd<4iJm#m35O|~{q7Q)agqHnih>qZ5l zClS3COMN@>R@mTe6rqs5U9Q;_%Ff4kXVfB?3Tw*^d2cMHEh8@DvH8B*6R=wrQt4sy z1?-?tt2-lZ`Nc@S5H{Gr7NHnHaMGvs{ZoZv^ym((Heel%peg>;YA6Bt@?MwW1-x;M zHVm#H<9W~bm?@7hOy8Jvff;NP%KWxKEpyLEt#yi4-#kZq{*WjY$pz-Z1h4%&yD- z4G`pvJ6`4Dj?akMszMm!xccLw87qh;4h0@ui)B?I5GsTrE|KecOjw62a|&`ElJI zSaPENQ$^(K!(;F9ZbmLijjoWstsoH-5Rn$HBWpS=(fs$u}*Qvh17Ss2~PKxm8 zfn`46UUW1EsqOE-{pR}}WW??4~E+n2M8!iISG7ktd&!SPI=l+i(^U7LkSWT~@ z`RKemCMO3^8a&qv;cgZ?rMGMg*jB1jny&wUbV}nzb>FA-yRhv1^#4xjf5xZC|DDn- zYrPLgA^+p2bekCw=lK8te2X}rz|NT`zeJqI^SsY<_g}*<{VC5~@MUDsr=w=(duOUP z=JH}XbtX3#%Mm$fI!a>U%SBFJHrCOQ0r~uA)lYHmeyV8u&RsiD2Y-S0f9_&$MA${w z=>xd;&lxobK9nn!VcI*Zq)Grnp@*_~Q=LL?DELywJAX4P%(<>h+#}T0DuATb-%|E8YXT%o?gCC z6j=3{<%Y3WB`#Jnwz<9>g2h^LWVvCS_yKz8Z922uFvM#r<@fcs_&ZWw`vID)o-OVz zHw?OmHyOVsig&np12#l|Qz?rz91B}~R$&;+c&C>OyI9K~i5kYQeCY}?Phju6Aqod3 zzJ$dH(mP1G;7eJEB#SWVTGTK$D~l-1_+m7>A2f_ZDqXQwKVNDXqYoN}m{)RSfSVR2 z_^4qVQpa5}g5vaI!x(+kFxDzSOz^>r5u`J#&_77>Z)EW>Btx0TrwI44j{6!`j{hYz znNKVA#0t8*913nXl@^F2E`S|S)*x}kCYrq(&@7~wDNnG!1fT|lXE^N!Jf~uj( zqmDnL_$P*cs_{>~RYGK`*dxz|P zGnri`6_{KVz!@=H!>Vn__6~$}tCybwZ&hmQ#lK9F3Z9GwZ=!tnN%>JmJi+$LvRREztPNJE3&f)t&C_(_^Pv zT*KOvRTcCqd+}o=hlj{n44}X=YbiM``%x+s*jPW-Nt!7{SY6N*<%yS|8F34f5?X%bEmCGFyErb46amtZ+f4&*JGxTEyjw!Sd{0)bt}gp3<|(XU-}M1 z3`?~##fzO`on1X6+puDDx)7crb+fq(ourx6bJl4ydwjDI3bgmE$JL;RQDs=TU`s(# zlk7f|?3QY>J9@+dBY?+rA8>_`y^@z+$biBv<~BN??3M|#J1mtc8pz~Mq*A1<1UFL; zDx!MKDzc*k2gwmL2iS!MRv&Ak0rLcG(im%?L3tr&yzIuYt3fD7#0*vtlquO;B~G%K zRLBR2S*Za;U%s!zj8!51)#QE+xnBfT37lIoL);EY6VI6OixPvG)G_0?B|0t(lQLO4 zFi+Lz8zmY`jXrQc1$+(Qq7pO2C+_EiVNLY$u>QH){pxeS=(PLE+uCPgsjssL^c3e@ zo({DNLnpaOeAd?>uE7eX)>~qzN@(&Xl@he87tT7E*rAY#PmR(NoEpt#Vj)&E2iGNO)}R)QOqxJZ?IWm0l~{O? z=V4&d*h#YrMa0C7QXGxE(a*_Cjh!^B)kY6HS;I>gm+3CCwi}3>s*NV5TouiTk4r2w zWj&JOxrt$7d9Gcd_sg$K$r73SoPrZ6jv7g60qp*rpy-xsvf#|3vn*8Lyz( z6TGEkzk)Lr#MYq>J>(?V>|r|$#Qw~5dE41e&Ng0ByLbb6h8?~@Qx!&^;^NaQ8M6wA zSnMuSTztA$Vpe(nJMAnmtAhSJ9m`Ci20eOT0qX(fWRH>4iG%NTAjGP*+eXfIIs?F< zGn{5AIVTy;=aUGw|9h6W21VYISGWtKI09}i`uz$N&?a-uY%{VCApVR5`adPU;vCbD z%0y0tNuRcsr+q`rCKc8ySy3lx)^Ue2neqm47K1E%uY%65k;=imjdFkXz=R}e*1?MO zKTv@Rn*9&%{T*l@RFmNa55!H-t>!agg3p|ZW5zL~mm{V*Vmj};M<(pv$9s8Oz+o4B zeDTqYS;D~FYL?&%z=up6%YcuR>)&1LgKn*x8DtCAY2r3QFYUa^F*`lI=1jKH38@-vB8cSBq$ToKu+Xc~@#7$5m~n{qqYGZn%j^_W7($>UPK^P~@BEsodo$vVk{ zkChU`CWnzZ!?R-PlF(6fkxm62#5jF2F!FB=6 z2kZf4=b4~F~;e5D*IXz~Lw$4Fxl{g=g8>c~b zi7!h)%bzZTza-}c?l5vPA+V7JI4}>Y@r9^W4ldWb93_^i3van+=fgMN8M+KEf#)j( z3VH~bPYBXi2-*+BnOo80i|HowRTe7fCZ56#;*9i3{eBso$dsY9N>y4F@0RlZUx_`l zi#J5mGlc9hlc-2F*(GWU!7MclO5(fRX#^WAh{WZDf#DMZdIAC18?xD4he&rH2GA+t zZN4)t?n#?n+*r`>xEu_8@1_X@xQUhLfWgG&`IS@)!tD%A+ zSH(0dvG5J5dy{x)UvGn$>BCF89{+5|4!vLT8T!Fu=*N}5-;Cp*YW&lWey8< z|Csov4gaL^PY+lSm9iixbijT|#oRIZ2G6d(d5>ujxAWK&YPF_)s}`117=u(Udtyi| z#0sTH;vo>vVNWE!Cw&6x^Vt(gbp=Rb8$^;K?1`f)9iL#b^&hC#FDIu=To>m;)?#J- zxKP3twe+dU@S$Mi)cGEI5w=-7C+>jjJdYh|K5340VXvA_BVxJ}G1VLs=a?kNB)i-v zI$RtoGVsmSAilPigFu`6kml`hX4|5=1IgBTVB5g{3Obh! z8OAnx*W^otwF|wJkVjO5xB#$@B$zX8W-ZFE=aOr=7U?dwDd$DXgPHa&!>afyIhMad z%g#)zy}^2xi^JNsHcQGlp3v0oOed93{#eMh;R})$njcjOO4~sx#zeMv%Bs>ldglVz zCumBIuLDzVX-M)V3|-Uv+z!Mk;q$P|mvy_}O!=l;eS`QKah2HG@r-Jc9T}nYz#llr*Qc^UFGMjvCqPQ-D%lJxDWTq+t@UEUvk-|0f%wh3IG_P?bQWni#dH=pT?H5zl!Yr>QH*0 zA3e@jQkHr56{6TWpwv!#z=A|=&yD;ZsNtf9a z8n>#L#Q2oY8<-dASn#yv14qoevEog6>x8;!NM0374IHi#NaGa+l@T-OPp*|HeHAi{ z-AqCt7Mi3nLtJwcJW!(fe(T+@eeT!G?w4>%GzV~fSTp-hxL^Es>XO9Ya2a#rs{0v< zNQa0qqcWmRSbHM|d;5qPFT20eYY`V13i4pdAEd9{PciF#{xPCCjN(J@^M;$CY>_4a z#CJ)m!~GJs-A}Vr|BTRAD#7Fy%kg03Z;3Ke31#PU+$|h&rh8v+st+9b&lVX*s)A-K zzy+HTw@SoZvb@Tupt+;is%GepSsO8oNCnOPmNzw;HES5hTH|0ab7ro4F$mKg6T)?J z=v^}&F$@=QLFM8-6&Ct3leo@{l4i}i2#oh}t3G|aLxXj%2h%BRt%d~4#TOx`BceG6 z(@V*Dka3?%c9Q*|SXklTyA`XT1IQ6TLF*`^3(2}FUJod*xj}q6N&m$M@pis*CCw`D zy`kMm&pgYbi+i$NZ<-1ISV~SwTHo*?y})UddBCtKy z5~zsFg($V%52fmeVeD!UA6L*>@NMsDo<)=^gHcK}h%>k&MZwj$A`RhvHsY8K>VPUV zrs5Vn2w*HRsQQT?7)vw+?+1QoRnXiPIY;jJ2K3(X6gd*!!yC{h|A6lKaRa(X59l5_ zpv?{9#w6Y3ieauQyqe>?8M&pNdvcdS^MEM&*Z8m)wFp^K>y_^UHwrm{hNcbM#0Y7%f$ zMRp-Jr{#wxn$6=M*pK|LEqB^NhF3vz1o&Ry9q}+{+R`h z$f-p=FD`Ee zqX`IdDgl&-(PPnP1zmbMWEjt&zzUk5@V8-;Y{R#@M*=l) z#FuIx%?3#n5_Xu_8P#9)&%mdX+(>suw{Ra~C z5u|M5zHS%*j^!IhI}0u<=#uzO&Ii3L#aHt0!{j8BRfn;|usVc{eF_IRZ&z>fS;0yw z{9;BM+oWUbz+EBVfmMe{Fj3-2B0&5E{++Dzt$%&-%yAJVqeUN zD0Hh*<4FbeQp%3uB)9W9H;%puX+ld&3`K{oDs0J8gJAb8nWf?_H&%S<#vTb9hSW)5 zhf=amE8I&su8Fd8g!{Ux=f}8NF{gFeB26Cdn`B(88^>;%)FS{_DWxy)k^31d)tR0s zH5jC?)SxS+x=G^QQe9@+A%)e<1ml8uY#!i@<&efC*Br9t3#k6gCV~ zn!2u8*gs(y<^{i&EF=!nqc^_9*=lF$nV z4p&$$7n-=I=(P9%Pf;z=!jlz2>W1e7BOv7K!h@YIgVu9Le+Od#Ocso>bcCCWHQT&I z#r4p|Tf#ndvX})JbcA76DgM&jByM|+a~)G@MRX7H0MZW+@_??rv7!m}=d_q97 zph7-mH=ZFJLcUu}h@4~^1aXzV-SDulRyR2scAjtx<8QQv!h!NDMo4@vK0ns}085qp zlSrc8K#vkN-b6RV4e^#&f|3wJj|L@hCA2x5*ZBfmAQ^I}mPE(VwLn;!R|koN!wSf# zL`J;+M2)WspDEIC>K$w(R=(GR;;Wz0>vX-CUvJ3F&=d4N{nsJDEZ1kfYYgn|?n`Ga{wY2DQf6cdkQ}2E1E9+hi49x4sFBPetK)@ZnL}2hp6kms zf&K4}u^~y9qutV_<5Jh=C&wwV>#7Rry;Qmp$}bkvaGhDTWP&&zy@Mm!jP!iv$Muky zBRj^1(plLKw_(Z5NXE(}n-X=pU3zRrCkCzI7e>@?fqBrR&_!}xb@@?N8csDoV6fR1La~zh zPVoE#h7p(dnIAAps^e7B1=RPE<+pOXOHzkogDx&{Qt_UfqgZ|MgZNmc{uoy)rN>jK zvm~*{Fkrq=a8PAZvvAVF=|(_mzm|&gJdL20)q{sDtAw>d zkX_cxvgNj*<`c6mq0oEXibFsg@6}QU7;PY5w9Bte9TN+TU|V*~=+pubROLXu8Bs zR#4Zo66zX^;93TNhjvqgxYP&rlp6d4&Zad&P6!GJ5%_l50gjAy5DlsX8tX;`B;b$M!aioFENZ`5%?QzfvRPU<|FLI$4G-KROQ-SNr>_W@j2MlRoRvKTvAjU zvR%uJiv_w(&Ym)Iy364Vqm!jAov25W6>_w;$h;M4V|K@Wh1eslMt&}?8&Pn!QZaJU z(atW;r1?hx_6dtG!3kldTI*p2T5Ok+vkY4++3ipuom-3&>(+>`TtIRjSzEG_b2Uat zYK*|G#{9Hd7Z#Vm3}ZhWGr|`4#8>pWxFKF!BW^)bM~=8b&MROFeNrO6roSu8w5wt9 zHGSY~ezcPngR0Urzb}%jcY#TKy@JkdXZ~=Q`8O5xMN?Tq@@rw(1)YQlB3Ws+CM+&s zlwJ#qIX#>TLLU6@&vKi^;J+9J(2hd5Ul|r>!s0wR;*T`nM&}H&!8e4|-DxUcBjyum zwTZH;l_I!F&UQFww#7Yk%8WQ0DcBvq6L$jrArtE^VHNS|2U+J`btpMI#U1o&E6uls zLKxI)vX`uhr?~hmeT9CA5@bxba%BxOENk$KJpiY#-3F+&6xeC-7yMknQ<>COh9+su zV7Wfb8%qraww3OC*?qlM*OLv_)|j$|Es4easFLKFTSQ7I>YOYUpRgJyhTn9Ax*HG5=ly39&NOdfgi4xxiphyh>OENltwj zmYnt2P+~A1DYS)%Zv#sPQxwqsSHlUpk9`5basd2 z75lip=vS>F@7i6S5h`9zF(}4ES3AZ`Na+R-oM3=bmNJsIoIU`MkiXJ-S8e2hr>5dh zNoSwSu!#YZU)xLhbkwnqv_JYPnomKCU!1L=FT`A;4{|%SFMfOw7C$CdQVg3=6?Ryd z(H!3d5u1szgI;eh&6g+0iHM8t0S}u1j7K@T93}+3gP2+PB2h*xaom8(*=t}6wfFLl z2ur1N@Q~7GR%Piku~6o#fiCr zfrYAioM$BP*%7pgFuW5=<&d&X;&p7I=Y)OyInOg0%QfMI3pJDz&dHY1e6lixe)P|^ zRtOGg9u7^*j;|!=S^qXZ=WgSzdt{nW7A=+DiO!XCAF=^ZEKApTds1rT&}>LxI!Yz2 zl3-IYuh1Y3ITDe34R2mj!J8Gd%DVT_{Qd|zMp&F>Us7RNwp2r5jQid`w5Srd!YZ~T zSuR~Y=#AJNcZf@-R`?r;9khe_X zW94cX>vq$*&$grByGyR<*b~cF+StCakAIv(Chdc&90zxU3yKU^;glW2c9Fl z#J%h6jvS_|xLF=1dnfD^@{SF<3|E=(!&J&1Jk((T@vro&$xge}Czz%36PtN^68pK_ z*7Y)H@iKy5<~R}xi!R)Ux+}c+(SG6AiW{8@ionly2CFJ89iHR4y^>A~m_gvRf)Es5 zAmFr=K{NgG@$58MUq06soB)r1Nmotrbzd{px{kl!#klMuCoVnM`{%!uTreL3VS8EWdXIF6BE3A1G^V9* z9$ypRoE%=xv&K&xMTbLZ8s^i+y5%Q5+8X6Qs%U#%E+rPSM-jw7#AW(KeB<@{q^cKE z24|_1PBBC= z`NTZpg6EQ~h`b3wh;hQKMW+)qjrN$=iIN^IZs!TqGfHbo2flafonc|R#vW8XMk zIAwmfi+=!(>syt)SjWSwQG~aa9>q~b8w>S3xBYFENQa{QXS%u+dK@ZwvC`QRhHfu4 zj2G3>iMvEGPBGc#a7mfNd-dO5z@{b{P<-R7wn4 zp)SI?^K<;;3k6xu=*uc^j1MH&n?m;xFwQ3W4>*#ooUYL=l@ zsv5+ftx3GNm>K>eIZc%f;+!>vba8U_coqa~Y3YbBw~d%p)>5rLubBSqZ&aF%>K7*7 zVc?g}Cu>8@7B^kCICFr?8^j+O$)ylmoIMxLpao!ye*#Vro{f@`TJW7&fFA@V#no_w zIEQy8>@J>*pt(;nyO>|#-C^-sfVIx-T*(f(fG&{ies-7YG?kIFryR`DG&$i;xUg+A z>o~iXpn#){aY=!#=JHFQV8(nEIq4WVi702RsR?A1-1(33ESKE*7|r+81UnQ15EdWP zd{X`3^0C{@D*S-VVR0_qiN3G)G}0Nu01BFCu>nfXL(+_e#pQpZU(uzK!>0J+RbesD z%C?ZVKu4PU4c)yK~Y#+0+d`=P{SfE@u+PB+jzBYHn*-T=p88G`E8Wn;Teha`sk|v#*K^l-O#O z+)H8cnjgJ}v9Ds7&r#*Gdw}d%$Yp$@xzU4Uhg`*N)w;`c8G4~`0uW;~Twv2nZwCOc zC^e=PJ2NIl_~3TN4Dq#Lu&bX^L)>x`JQczd7Ma$BBo8!ZbcUpdkW!=1jT;TgYh9@^ z<;Jm}b;*jS^Iq(G%2Q#?0E-sRg-US|Ez#t+x)>uvC6ap%F}U;Wh7>h(yqel^m?`48!hCk|&k z@zwERyqN~Z21hf`9f&^@f0^%BhG9GlD;sbl@>%?4n#B(`xy$08OPZCd{EYrm7KPC_ zav4JToy8%F&(CWUl1niBdvOkcoyJW6C-iKULS3uw(SMEMuRO$K<&wQ}4MdLgrsna_ zg~<``NtJwVR|z@G!@}_-P4aNS@_Zc-CyMVH7Pncf_$)bD1G`pbSbXI_2N+G#l`l@4 zu{^e;ln%(P>lNsJzsi*gi`xmZUon^|OK)m1$*bB&_Ss5pbVj!N*>9lclNn&33dsy) zeDG=j;AsGi#MnbH_>83tssk}qDLW2@#2_XG-tuQgomLA1t4&(1`s4_3NXn3Nnjh|i zLt(6&$`pJHTV@oJ12#;YhS(5Cjx%CbiMi5M%?t$cB)dZHF>AU#fq_rhQ;uGQum?G{!pX#kyHxj`G)7CbnSoxB>4zU4uO^?I|+UIi78{EqWIa6hlL*5jT zEOJJuf}mjO@k)6EC?+h}D}@CSpRiy?2@A4-5IR8fJC~s~^E;On=1A*VgobGKY_-qv zmMz;6l}@qcFn7tZ-=_vTEL|n*o_1a?W37NDNbaNy@#8;}t*DR^1D#UdieT8!1OJg6 z>>1sHc$U6B@SM^qaKu}X=$3m7_ch|i0NJ}ElIM;IvJ8Cp!{jW(gAByV50kySoSd?- zxC9I#e-D5S4cqBb*7uZa1DyF5j>C>E;~;-aa@@H4^*i^At_3nEaItbd-iJx!oPto~o&`Lz;3c({9Pt`N|BJ{ug>CJgh4qn}h$j$| z;6icF^0Wr@Cf7P}kmjLcwMfhiKnQq{@z7i--jL!K;#{h;+@cxA}d ziVjK@el0!_pNs!2CRPCd2zC?VD|&yR!(+(el7k?{3Vz>%U`Y9VBIY{K)iw}FR#L>? zf?iY9H4EQkKuN)Z=B3eXNMFyWvBN?D^Z}YQYw|BDQb-nLd1I^b`1nQTCunmxq}_U#Ma5s6y@^Ag zDe~Gb!W&!gL%g2Ok)5!cZv>>0RTbKUF2WDVPJ%KBgnWw&DS=?#85W876TOoe^QtaB zQB~Jc2#-@Fr4aeT06z~+N*lDSZRbky?h`)R*A?xD@}wt0LBrE0>1^pkynOt`rKtmR z)G!sZHIIyV#7ouC!pCpWt*|tHP>d*J)w%=XlI~r@ctmAGqTn2rRt8ur2;vW7X3X;P zLA411se<`%qwxG(_w2)=s}l2r0|9A*(+-kjZ`vW`I~kTfc{Q+l=vU&a$G!HGcEtK< zUgu(O3(|g6N^#(d))UA`4;Ddj40PH(AMZT;dz;{y zvMJ9q>AxZZYEQK9YHOEt{bHg5Vjx%G)Rt^<-JL?tBVD2@pRB<~DB}y2wP{Zx*}kJm zXNJs*3xY@0Ed{)?Zq~2CgfY-JIc#aO0!8k=rA?ey3!6NtQupxhGK#Plsfl+aQmwn% z60)@E4E}!e1~OC z4!@wS5#m2+kFaUOmVndI2c_idV3}v&SV(Y1ck~L?p`hdnOAn?Cut`8bregf>2|U+< zdX0d6uaM-5#SIr>;qa|WiBrEA$yE`<*r=`r#VBHX2DFPm6r%?t>i!>~2MgcB_eqZc z>qFOnfFi3(iqlB?r4sCYUq6c3MTQ~X`~eXlMn=51$S~I7QlxskSi9>>4I|}CS7>C= z!Cj?>(WMRm+;oc3qfY?^bVsEuHZt&!!iFNh#NmZ4`Fltv%M7DOrPBm|YT1c=z_Rsw zBR{V2Og*&@FIr|&i?8V(dPzeE1eu;1)dSDF%Dq`|Z2HaEz`+B4w!iP$jb|wyU}#i~ zUq|u_0nauB{Y*tqE;bl&S3ZX_ZvBq;fWI{(&cm+YV{%%=O;kIla!w1d1Ge%*9ooWI zinn1;RxD`vrQ8;tFW;Mm!u_-vJ9ywZpJhX2K+NFXCz}99sQd!YMt&V}zYz3=NH-9- zM*tHu`iuV&s~_({WMUm~yHZMin}ppU&RDgKs+%&!bukwqJ5^0~DoJ)KL3S!dcB+l+ zRN5*fJGGtcRK2)?M?lEnm)Lu?eXhM)mY&>^4iO$M;OdD>Y|k+Ymmi@%Gz%%ZcG zBU=d&v3pG|E|N9|VS)ntz)#KNzbs@;r*0!k8Win!gK%hT;lgpT%v%LMkPC8s%s6y-SurpRe-EA&GfInC)p zKfwEpi61I*Ncrm?u^uC*xgNk<4gQrypb?mJeCyXX4OgiZH*B!Kbj9tq@xRqK6+gP$j>r=0))-eJ+?)*OI{vb_iZ z_CV0PD!QjIUrSvhU9Q%@3FxC-e0HQot&coa*?iayzuF@%1Hm_1F>V#k5?rxp=4Z<` zc!go3mWAf>!X&fG|8CD$2gNxri$~aeK+LZ3NNX+%05*cJRvgs9TIb_rV7$Vv|7P(T zUH`d{RiYhTm*vrxyd{6N%knq^nvcYHO57sXi1(`-y_)N{GScPNU2=#t{cdq>bR&|X zxBN^8$qxb{9EqKDZP5cBea&B&nx+UR_+NzF@+8MdmxoYH_Y@_e_2S~w)#59!G`=k$ zK>IW}5c!;+V!EfehGMb}g%-i8NuTrVFAL%R`92I}1fD>yp}f-n^t~t%CD&lq%BWZ8 zOB188hxekHR*rLRsRr3GGQ^sb$`C(b)b4^C$a?t6pvihet9?R{BUN_%1&mca%lAq zkFFb^JhEP8TF=D#`}^bZ!LfMer9;Ek@YoSKPLtzDCI?4H@%PB!*pckukxUM;-wuzy zkOetimG$e_F9AjUH^R}($V7ZJBmcjnHQ60MK77a;9`)C(wW+CjZEAdEWN>Uq(*v#l E25b$a9RL6T literal 0 HcmV?d00001 From 3cdf729f5f63fa78a75f073923f400bdd42ea298 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:35:44 +0200 Subject: [PATCH 0476/3340] - patchlevel 641 --- 7.3.641 | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 7.3.641 diff --git a/7.3.641 b/7.3.641 new file mode 100644 index 00000000..daacdb4f --- /dev/null +++ b/7.3.641 @@ -0,0 +1,68 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.641 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.641 +Problem: ":mkview" uses ":normal" instead of ":normal!" for folds. (Dan) +Solution: Add the bang. (Christian Brabandt) +Files: src/fold.c + + +*** ../vim-7.3.640/src/fold.c 2012-08-08 18:01:00.000000000 +0200 +--- src/fold.c 2012-08-29 15:17:39.000000000 +0200 +*************** +*** 3373,3379 **** + /* open nested folds while this fold is open */ + if (fprintf(fd, "%ld", fp->fd_top + off) < 0 + || put_eol(fd) == FAIL +! || put_line(fd, "normal zo") == FAIL) + return FAIL; + if (put_foldopen_recurse(fd, wp, &fp->fd_nested, + off + fp->fd_top) +--- 3373,3379 ---- + /* open nested folds while this fold is open */ + if (fprintf(fd, "%ld", fp->fd_top + off) < 0 + || put_eol(fd) == FAIL +! || put_line(fd, "normal! zo") == FAIL) + return FAIL; + if (put_foldopen_recurse(fd, wp, &fp->fd_nested, + off + fp->fd_top) +*************** +*** 3417,3423 **** + { + if (fprintf(fd, "%ld", fp->fd_top + off) < 0 + || put_eol(fd) == FAIL +! || fprintf(fd, "normal z%c", + fp->fd_flags == FD_CLOSED ? 'c' : 'o') < 0 + || put_eol(fd) == FAIL) + return FAIL; +--- 3417,3423 ---- + { + if (fprintf(fd, "%ld", fp->fd_top + off) < 0 + || put_eol(fd) == FAIL +! || fprintf(fd, "normal! z%c", + fp->fd_flags == FD_CLOSED ? 'c' : 'o') < 0 + || put_eol(fd) == FAIL) + return FAIL; +*** ../vim-7.3.640/src/version.c 2012-08-29 14:23:06.000000000 +0200 +--- src/version.c 2012-08-29 15:18:26.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 641, + /**/ + +-- +You cannot propel yourself forward by patting yourself on the back. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 82d202215dc4f4c85b3c81a425539aa4c473989f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:35:45 +0200 Subject: [PATCH 0477/3340] - patchlevel 642 --- 7.3.642 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.642 diff --git a/7.3.642 b/7.3.642 new file mode 100644 index 00000000..ddc40321 --- /dev/null +++ b/7.3.642 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.642 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.642 +Problem: Segfault with specific autocommands. Was OK after 7.3.449 and + before 7.3.545. (Richard Brown) +Solution: Pass TRUE for abort_if_last in the call to close_buffer(). + (Christian Brabandt) +Files: src/window.c + + +*** ../vim-7.3.641/src/window.c 2012-07-19 18:05:40.000000000 +0200 +--- src/window.c 2012-08-29 15:42:15.000000000 +0200 +*************** +*** 2269,2275 **** + #ifdef FEAT_AUTOCMD + win->w_closing = TRUE; + #endif +! close_buffer(win, win->w_buffer, free_buf ? DOBUF_UNLOAD : 0, FALSE); + #ifdef FEAT_AUTOCMD + if (win_valid(win)) + win->w_closing = FALSE; +--- 2269,2275 ---- + #ifdef FEAT_AUTOCMD + win->w_closing = TRUE; + #endif +! close_buffer(win, win->w_buffer, free_buf ? DOBUF_UNLOAD : 0, TRUE); + #ifdef FEAT_AUTOCMD + if (win_valid(win)) + win->w_closing = FALSE; +*** ../vim-7.3.641/src/version.c 2012-08-29 15:22:14.000000000 +0200 +--- src/version.c 2012-08-29 15:49:52.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 642, + /**/ + +-- +The psychic said, "God bless you." I said, "I didn't sneeze." She +looked deep into my eyes and said, "You will, eventually." And, damn +if she wasn't right. Two days later, I sneezed. --Ellen Degeneres + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e1ac2e7f4b185d50983852f1b01bd6be84472dda Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:35:47 +0200 Subject: [PATCH 0478/3340] - patchlevel 643 --- 7.3.643 | 73 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 7.3.643 diff --git a/7.3.643 b/7.3.643 new file mode 100644 index 00000000..c2f700c5 --- /dev/null +++ b/7.3.643 @@ -0,0 +1,73 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.643 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.643 (after 7.3.635) +Problem: MS-Windows: When starting gvim maximized 'lines' and 'columns' are + wrong. (Christian Robinson) +Solution: Move the check for gui.starting from ui_get_shellsize() to + check_shellsize(). +Files: src/ui.c, src/term.c + + +*** ../vim-7.3.642/src/ui.c 2012-08-23 13:28:50.000000000 +0200 +--- src/ui.c 2012-08-29 16:20:04.000000000 +0200 +*************** +*** 298,306 **** + int retval; + + #ifdef FEAT_GUI +- if (gui.starting) +- /* possibly a system call during startup, check later */ +- return OK; + if (gui.in_use) + retval = gui_get_shellsize(); + else +--- 298,303 ---- +*** ../vim-7.3.642/src/term.c 2012-08-15 16:20:59.000000000 +0200 +--- src/term.c 2012-08-29 16:22:25.000000000 +0200 +*************** +*** 3006,3012 **** + int old_Rows = Rows; + int old_Columns = Columns; + +! if (!exiting) + { + (void)ui_get_shellsize(); + check_shellsize(); +--- 3006,3018 ---- + int old_Rows = Rows; + int old_Columns = Columns; + +! if (!exiting +! #ifdef FEAT_GUI +! /* Do not get the size when executing a shell command during +! * startup. */ +! && !gui.starting +! #endif +! ) + { + (void)ui_get_shellsize(); + check_shellsize(); +*** ../vim-7.3.642/src/version.c 2012-08-29 15:50:22.000000000 +0200 +--- src/version.c 2012-08-29 16:25:42.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 643, + /**/ + +-- +Eight Megabytes And Continually Swapping. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2c2b50510c793297c3a3f5720705082b5bf2de00 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:35:48 +0200 Subject: [PATCH 0479/3340] - patchlevel 644 --- 7.3.644 | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 7.3.644 diff --git a/7.3.644 b/7.3.644 new file mode 100644 index 00000000..6f2630cc --- /dev/null +++ b/7.3.644 @@ -0,0 +1,72 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.644 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.644 +Problem: Dead code for BeOS GUI. +Solution: Remove unused __BEOS__ stuff. +Files: src/gui.c + + +*** ../vim-7.3.643/src/gui.c 2012-07-10 16:49:08.000000000 +0200 +--- src/gui.c 2012-08-29 16:28:46.000000000 +0200 +*************** +*** 37,44 **** + static void gui_set_bg_color __ARGS((char_u *name)); + static win_T *xy2win __ARGS((int x, int y)); + +! #if defined(UNIX) && !defined(__BEOS__) && !defined(MACOS_X) \ +! && !defined(__APPLE__) + # define MAY_FORK + static void gui_do_fork __ARGS((void)); + +--- 37,43 ---- + static void gui_set_bg_color __ARGS((char_u *name)); + static win_T *xy2win __ARGS((int x, int y)); + +! #if defined(UNIX) && !defined(MACOS_X) && !defined(__APPLE__) + # define MAY_FORK + static void gui_do_fork __ARGS((void)); + +*************** +*** 784,794 **** + gui_exit(rc) + int rc; + { +- #ifndef __BEOS__ + /* don't free the fonts, it leads to a BUS error + * richard@whitequeen.com Jul 99 */ + free_highlight_fonts(); +- #endif + gui.in_use = FALSE; + gui_mch_exit(rc); + } +--- 783,791 ---- +*** ../vim-7.3.643/src/version.c 2012-08-29 16:26:01.000000000 +0200 +--- src/version.c 2012-08-29 16:33:30.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 644, + /**/ + +-- +E M A C S +s e l o h +c t t n i +a a t f +p r t +e o + l + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3497045fbeaaab8b4d12de2f6b4a531a733d4b87 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:35:49 +0200 Subject: [PATCH 0480/3340] - patchlevel 645 --- 7.3.645 | 118 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 118 insertions(+) create mode 100644 7.3.645 diff --git a/7.3.645 b/7.3.645 new file mode 100644 index 00000000..40d8ee0b --- /dev/null +++ b/7.3.645 @@ -0,0 +1,118 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.645 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.645 +Problem: No tests for patch 7.3.625 and 7.3.637. +Solution: Add more tests for the "gn" command and try/catch. (Christian + Brabandt) +Files: src/testdir/test53.in, src/testdir/test53.ok, + src/testdir/test55.in, src/testdir/test55.ok + + +*** ../vim-7.3.644/src/testdir/test53.in 2012-07-25 15:06:20.000000000 +0200 +--- src/testdir/test53.in 2012-08-29 16:37:44.000000000 +0200 +*************** +*** 34,40 **** + gnd + /[a]bcdx + :1 +! 2gnd + :/^start:/,/^end:/wq! test.out + ENDTEST + +--- 34,46 ---- + gnd + /[a]bcdx + :1 +! 2gnd/join +! /$ +! 0gnd +! /\>\zs +! 0gnd/^ +! gnd$h/\zs +! gnd + :/^start:/,/^end:/wq! test.out + ENDTEST + +*************** +*** 57,60 **** +--- 63,70 ---- + one + two + abcdx | abcdx | abcdx ++ join ++ lines ++ zero width pattern ++ delete first and last chars + end: +*** ../vim-7.3.644/src/testdir/test53.ok 2012-07-25 15:06:20.000000000 +0200 +--- src/testdir/test53.ok 2012-08-29 16:37:48.000000000 +0200 +*************** +*** 21,24 **** +--- 21,27 ---- + SEARCH: + searchmatch + abcdx | | abcdx ++ join lines ++ zerowidth pattern ++ elete first and last char + end: +*** ../vim-7.3.644/src/testdir/test55.in 2012-05-18 12:06:58.000000000 +0200 +--- src/testdir/test55.in 2012-08-29 16:50:51.000000000 +0200 +*************** +*** 378,383 **** +--- 378,393 ---- + :unlet dict + :call garbagecollect(1) + :" ++ :" test for patch 7.3.637 ++ :let a = 'No error caught' ++ :try|foldopen|catch|let a = matchstr(v:exception,'^[^ ]*')|endtry ++ o=a :" ++ :lang C ++ :redir => a ++ :try|foobar|catch|let a = matchstr(v:exception,'^[^ ]*')|endtry ++ :redir END ++ o=a :" ++ :" + :/^start:/,$wq! test.out + ENDTEST + +*** ../vim-7.3.644/src/testdir/test55.ok 2012-05-18 12:06:58.000000000 +0200 +--- src/testdir/test55.ok 2012-08-29 16:51:15.000000000 +0200 +*************** +*** 115,117 **** +--- 115,123 ---- + {'a': {'b': 'B'}} + Vim(call):E737: a + {'a': {'b': 'B'}} ++ Vim(foldopen):E490: ++ ++ ++ Error detected while processing : ++ E492: Not an editor command: foobar|catch|let a = matchstr(v:exception,'^[^ ]*')|endtry ++ +*** ../vim-7.3.644/src/version.c 2012-08-29 16:34:23.000000000 +0200 +--- src/version.c 2012-08-29 16:37:20.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 645, + /**/ + +-- +TALL KNIGHT OF NI: Ni! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 78bfc2ab393e0c3da3638f5f372fe4e80da14466 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:35:50 +0200 Subject: [PATCH 0481/3340] - patchlevel 646 --- 7.3.646 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.646 diff --git a/7.3.646 b/7.3.646 new file mode 100644 index 00000000..3e507a79 --- /dev/null +++ b/7.3.646 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.646 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.646 +Problem: When reloading a buffer the undo file becomes unusable unless ":w" + is executed. (Dmitri Frank) +Solution: After reloading the buffer write the undo file. (Christian + Brabandt) +Files: src/fileio.c + + +*** ../vim-7.3.645/src/fileio.c 2012-07-10 17:14:50.000000000 +0200 +--- src/fileio.c 2012-08-29 18:19:44.000000000 +0200 +*************** +*** 7060,7067 **** +--- 7060,7082 ---- + } + + if (reload) ++ { + /* Reload the buffer. */ + buf_reload(buf, orig_mode); ++ #ifdef FEAT_PERSISTENT_UNDO ++ if (buf->b_p_udf && buf->b_ffname != NULL) ++ { ++ char_u hash[UNDO_HASH_SIZE]; ++ buf_T *save_curbuf = curbuf; ++ ++ /* Any existing undo file is unusable, write it now. */ ++ curbuf = buf; ++ u_compute_hash(hash); ++ u_write_undo(NULL, FALSE, buf, hash); ++ curbuf = save_curbuf; ++ } ++ #endif ++ } + + #ifdef FEAT_AUTOCMD + /* Trigger FileChangedShell when the file was changed in any way. */ +*** ../vim-7.3.645/src/version.c 2012-08-29 16:55:09.000000000 +0200 +--- src/version.c 2012-08-29 18:21:07.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 646, + /**/ + +-- + An extraordinary TALL KNIGHT in all black (possibly John with Mike on his + shoulders) walks out from the dark trees. He is extremely fierce and + gruesome countenance. He walks towards KING ARTHUR and PATSY, who are + wazzing like mad. (Salopian slang, meaning very scared. almost to the + point of wetting oneself, e.g. before an important football match or + prior to a postering. Salopian slang meaning a beating by the school + praeposters. Sorry about the Salopian slant to this stage direction - Ed.) + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 124d85309fad82f6227b0d09c35a5676541d0ff1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:35:52 +0200 Subject: [PATCH 0482/3340] - patchlevel 647 --- 7.3.647 | 178 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 178 insertions(+) create mode 100644 7.3.647 diff --git a/7.3.647 b/7.3.647 new file mode 100644 index 00000000..d1c524f8 --- /dev/null +++ b/7.3.647 @@ -0,0 +1,178 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.647 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.647 +Problem: "gnd" doesn't work correctly in Visual mode. +Solution: Handle Visual mode differently in "gn". (Christian Brabandt) +Files: src/search.c, src/testdir/test53.in, src/testdir/test53.ok + + +*** ../vim-7.3.646/src/search.c 2012-08-23 15:53:00.000000000 +0200 +--- src/search.c 2012-09-05 12:11:58.000000000 +0200 +*************** +*** 4545,4551 **** + int dir; + int result; /* result of various function calls */ + char_u old_p_ws = p_ws; +- int visual_active = FALSE; + int flags = 0; + pos_T save_VIsual; + int zerowidth = FALSE; +--- 4545,4550 ---- +*************** +*** 4561,4571 **** + { + orig_pos = curwin->w_cursor; + save_VIsual = VIsual; +- visual_active = TRUE; +- +- /* just started visual selection, only one character */ +- if (equalpos(VIsual, curwin->w_cursor)) +- visual_active = FALSE; + + pos = curwin->w_cursor; + start_pos = VIsual; +--- 4560,4565 ---- +*************** +*** 4619,4625 **** + p_ws = old_p_ws; + return FAIL; + } +! else if (!i && !result && !visual_active) + { + if (forward) /* try again from start of buffer */ + { +--- 4613,4619 ---- + p_ws = old_p_ws; + return FAIL; + } +! else if (!i && !result) + { + if (forward) /* try again from start of buffer */ + { +*************** +*** 4691,4697 **** + regmmatch_T regmatch; + int nmatched = 0; + int result = -1; +! pos_T pos; + + if (search_regcomp(pattern, RE_SEARCH, RE_SEARCH, + SEARCH_KEEP, ®match) == FAIL) +--- 4685,4692 ---- + regmmatch_T regmatch; + int nmatched = 0; + int result = -1; +! pos_T pos; +! int save_called_emsg = called_emsg; + + if (search_regcomp(pattern, RE_SEARCH, RE_SEARCH, + SEARCH_KEEP, ®match) == FAIL) +*************** +*** 4704,4718 **** + { + /* Zero-width pattern should match somewhere, then we can check if + * start and end are in the same position. */ + nmatched = vim_regexec_multi(®match, curwin, curbuf, + pos.lnum, (colnr_T)0, NULL); + + if (!called_emsg) + result = (nmatched != 0 +! && regmatch.startpos[0].lnum == regmatch.endpos[0].lnum +! && regmatch.startpos[0].col == regmatch.endpos[0].col); + } + + vim_free(regmatch.regprog); + return result; + } +--- 4699,4715 ---- + { + /* Zero-width pattern should match somewhere, then we can check if + * start and end are in the same position. */ ++ called_emsg = FALSE; + nmatched = vim_regexec_multi(®match, curwin, curbuf, + pos.lnum, (colnr_T)0, NULL); + + if (!called_emsg) + result = (nmatched != 0 +! && regmatch.startpos[0].lnum == regmatch.endpos[0].lnum +! && regmatch.startpos[0].col == regmatch.endpos[0].col); + } + ++ called_emsg |= save_called_emsg; + vim_free(regmatch.regprog); + return result; + } +*** ../vim-7.3.646/src/testdir/test53.in 2012-08-29 16:55:09.000000000 +0200 +--- src/testdir/test53.in 2012-09-05 12:12:03.000000000 +0200 +*************** +*** 40,46 **** + /\>\zs + 0gnd/^ + gnd$h/\zs +! gnd + :/^start:/,/^end:/wq! test.out + ENDTEST + +--- 40,47 ---- + /\>\zs + 0gnd/^ + gnd$h/\zs +! gnd/[u]niquepattern/s +! vlgnd + :/^start:/,/^end:/wq! test.out + ENDTEST + +*************** +*** 67,70 **** +--- 68,72 ---- + lines + zero width pattern + delete first and last chars ++ uniquepattern uniquepattern + end: +*** ../vim-7.3.646/src/testdir/test53.ok 2012-08-29 16:55:09.000000000 +0200 +--- src/testdir/test53.ok 2012-09-05 12:12:08.000000000 +0200 +*************** +*** 24,27 **** +--- 24,28 ---- + join lines + zerowidth pattern + elete first and last char ++ uniquepattern + end: +*** ../vim-7.3.646/src/version.c 2012-08-29 18:50:50.000000000 +0200 +--- src/version.c 2012-09-05 12:13:37.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 647, + /**/ + +-- + ** Hello and Welcome to the Psychiatric Hotline ** +If you are obsessive-compulsive, please press 1 repeatedly. +If you are co-dependent, please ask someone to press 2. +If you have multiple personalities, please press 3, 4, 5 and 6. +If you are paranoid-delusional, we know who you are and what you want + - just stay on the line so we can trace the call. +If you are schizophrenic, listen carefully and a little voice will + tell you which number to press next. +If you are manic-depressive, it doesn't matter which number you press + - no one will answer. +If you suffer from panic attacks, push every button you can find. +If you are sane, please hold on - we have the rest of humanity on the + other line and they desparately want to ask you a few questions. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 80d3d2b2b844cb92b2785e7a61fb04d3b700f1e0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:35:53 +0200 Subject: [PATCH 0483/3340] - patchlevel 648 --- 7.3.648 | 131 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 131 insertions(+) create mode 100644 7.3.648 diff --git a/7.3.648 b/7.3.648 new file mode 100644 index 00000000..f51d99d6 --- /dev/null +++ b/7.3.648 @@ -0,0 +1,131 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.648 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.648 +Problem: Crash when using a very long file name. (ZyX) +Solution: Properly check length of buffer space. +Files: src/buffer.c + + +*** ../vim-7.3.647/src/buffer.c 2012-07-16 17:31:48.000000000 +0200 +--- src/buffer.c 2012-09-05 13:17:38.000000000 +0200 +*************** +*** 3234,3245 **** + { + /* format: "fname + (path) (1 of 2) - VIM" */ + + if (curbuf->b_fname == NULL) +! vim_strncpy(buf, (char_u *)_("[No Name]"), IOSIZE - 100); + else + { + p = transstr(gettail(curbuf->b_fname)); +! vim_strncpy(buf, p, IOSIZE - 100); + vim_free(p); + } + +--- 3234,3248 ---- + { + /* format: "fname + (path) (1 of 2) - VIM" */ + ++ #define SPACE_FOR_FNAME (IOSIZE - 100) ++ #define SPACE_FOR_DIR (IOSIZE - 20) ++ #define SPACE_FOR_ARGNR (IOSIZE - 10) /* at least room for " - VIM" */ + if (curbuf->b_fname == NULL) +! vim_strncpy(buf, (char_u *)_("[No Name]"), SPACE_FOR_FNAME); + else + { + p = transstr(gettail(curbuf->b_fname)); +! vim_strncpy(buf, p, SPACE_FOR_FNAME); + vim_free(p); + } + +*************** +*** 3263,3269 **** + buf[off++] = ' '; + buf[off++] = '('; + home_replace(curbuf, curbuf->b_ffname, +! buf + off, IOSIZE - off, TRUE); + #ifdef BACKSLASH_IN_FILENAME + /* avoid "c:/name" to be reduced to "c" */ + if (isalpha(buf[off]) && buf[off + 1] == ':') +--- 3266,3272 ---- + buf[off++] = ' '; + buf[off++] = '('; + home_replace(curbuf, curbuf->b_ffname, +! buf + off, SPACE_FOR_DIR - off, TRUE); + #ifdef BACKSLASH_IN_FILENAME + /* avoid "c:/name" to be reduced to "c" */ + if (isalpha(buf[off]) && buf[off + 1] == ':') +*************** +*** 3274,3291 **** + if (p == buf + off) + /* must be a help buffer */ + vim_strncpy(buf + off, (char_u *)_("help"), +! (size_t)(IOSIZE - off - 1)); + else + *p = NUL; + +! /* translate unprintable chars */ +! p = transstr(buf + off); +! vim_strncpy(buf + off, p, (size_t)(IOSIZE - off - 1)); +! vim_free(p); + STRCAT(buf, ")"); + } + +! append_arg_number(curwin, buf, IOSIZE, FALSE); + + #if defined(FEAT_CLIENTSERVER) + if (serverName != NULL) +--- 3277,3304 ---- + if (p == buf + off) + /* must be a help buffer */ + vim_strncpy(buf + off, (char_u *)_("help"), +! (size_t)(SPACE_FOR_DIR - off - 1)); + else + *p = NUL; + +! /* Translate unprintable chars and concatenate. Keep some +! * room for the server name. When there is no room (very long +! * file name) use (...). */ +! if (off < SPACE_FOR_DIR) +! { +! p = transstr(buf + off); +! vim_strncpy(buf + off, p, (size_t)(SPACE_FOR_DIR - off)); +! vim_free(p); +! } +! else +! { +! vim_strncpy(buf + off, (char_u *)"...", +! (size_t)(SPACE_FOR_ARGNR - off)); +! } + STRCAT(buf, ")"); + } + +! append_arg_number(curwin, buf, SPACE_FOR_ARGNR, FALSE); + + #if defined(FEAT_CLIENTSERVER) + if (serverName != NULL) +*** ../vim-7.3.647/src/version.c 2012-09-05 12:16:40.000000000 +0200 +--- src/version.c 2012-09-05 13:29:53.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 648, + /**/ + +-- +Q: How does a UNIX Guru do Sex ? +A: unzip;strip;touch;finger;mount;fsck;more;yes;umount;sleep + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3b1accda94edfa004edd38e05190d48d9ffbf793 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:35:54 +0200 Subject: [PATCH 0484/3340] - patchlevel 649 --- 7.3.649 | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 7.3.649 diff --git a/7.3.649 b/7.3.649 new file mode 100644 index 00000000..50c7ce81 --- /dev/null +++ b/7.3.649 @@ -0,0 +1,68 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.649 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.649 +Problem: When 'clipboard' is set to "unnamed" small deletes end up in the + numbered registers. (Ingo Karkat) +Solution: Use the original register name to decide whether to put a delete + in a numbered register. (Christian Brabandt) +Files: src/ops.c + + +*** ../vim-7.3.648/src/ops.c 2012-08-08 18:01:00.000000000 +0200 +--- src/ops.c 2012-09-05 14:13:32.000000000 +0200 +*************** +*** 1623,1628 **** +--- 1623,1629 ---- + #endif + linenr_T old_lcount = curbuf->b_ml.ml_line_count; + int did_yank = FALSE; ++ int orig_regname = oap->regname; + + if (curbuf->b_ml.ml_flags & ML_EMPTY) /* nothing to do */ + return OK; +*************** +*** 1715,1722 **** + /* + * Put deleted text into register 1 and shift number registers if the + * delete contains a line break, or when a regname has been specified. + */ +! if (oap->regname != 0 || oap->motion_type == MLINE + || oap->line_count > 1 || oap->use_reg_one) + { + y_current = &y_regs[9]; +--- 1716,1725 ---- + /* + * Put deleted text into register 1 and shift number registers if the + * delete contains a line break, or when a regname has been specified. ++ * Use the register name from before adjust_clip_reg() may have ++ * changed it. + */ +! if (orig_regname != 0 || oap->motion_type == MLINE + || oap->line_count > 1 || oap->use_reg_one) + { + y_current = &y_regs[9]; +*** ../vim-7.3.648/src/version.c 2012-09-05 13:30:22.000000000 +0200 +--- src/version.c 2012-09-05 14:17:55.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 649, + /**/ + +-- +'I generally avoid temptation unless I can't resist it." + -- Mae West + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ac867048b81b7b489d67845495c97b862497460f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:35:56 +0200 Subject: [PATCH 0485/3340] - patchlevel 650 --- 7.3.650 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.650 diff --git a/7.3.650 b/7.3.650 new file mode 100644 index 00000000..0937c126 --- /dev/null +++ b/7.3.650 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.650 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.650 +Problem: Completion after ":help \{-" gives an error message and messes up + the command line. +Solution: Cancel the tag search if the pattern can't be compiled. (Yasuhiro + Matsumoto) +Files: src/tag.c + + +*** ../vim-7.3.649/src/tag.c 2012-01-10 22:26:12.000000000 +0100 +--- src/tag.c 2012-09-05 14:56:52.000000000 +0200 +*************** +*** 1443,1448 **** +--- 1443,1450 ---- + orgpat.len = p_tl; + + prepare_pats(&orgpat, has_re); ++ if (has_re && orgpat.regmatch.regprog == NULL) ++ goto findtag_end; + + #ifdef FEAT_TAG_BINS + /* This is only to avoid a compiler warning for using search_info +*** ../vim-7.3.649/src/version.c 2012-09-05 14:18:42.000000000 +0200 +--- src/version.c 2012-09-05 15:01:07.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 650, + /**/ + +-- +GUARD #1: What, ridden on a horse? +ARTHUR: Yes! +GUARD #1: You're using coconuts! +ARTHUR: What? +GUARD #1: You've got two empty halves of coconut and you're bangin' 'em + together. + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 178c7e1e299a287395d0c4df42ae79e93b90a133 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:35:57 +0200 Subject: [PATCH 0486/3340] - patchlevel 651 --- 7.3.651 | 99 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 99 insertions(+) create mode 100644 7.3.651 diff --git a/7.3.651 b/7.3.651 new file mode 100644 index 00000000..0a724246 --- /dev/null +++ b/7.3.651 @@ -0,0 +1,99 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.651 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.651 +Problem: Completion after ":help \{-" gives an error message. +Solution: Prepend a backslash. +Files: src/ex_cmds.c + + +*** ../vim-7.3.650/src/ex_cmds.c 2012-08-08 16:50:40.000000000 +0200 +--- src/ex_cmds.c 2012-09-05 15:10:13.000000000 +0200 +*************** +*** 4851,4857 **** + #ifdef FEAT_EVAL + if (do_count) + { +! /* prevent accidently changing the buffer by a function */ + save_ma = curbuf->b_p_ma; + curbuf->b_p_ma = FALSE; + sandbox++; +--- 4851,4857 ---- + #ifdef FEAT_EVAL + if (do_count) + { +! /* prevent accidentally changing the buffer by a function */ + save_ma = curbuf->b_p_ma; + curbuf->b_p_ma = FALSE; + sandbox++; +*************** +*** 5264,5270 **** + * is assumed to be 'p' if missing. + * + * This is implemented in two passes: first we scan the file for the pattern and +! * set a mark for each line that (not) matches. secondly we execute the command + * for each line that has a mark. This is required because after deleting + * lines we do not know where to search for the next match. + */ +--- 5264,5270 ---- + * is assumed to be 'p' if missing. + * + * This is implemented in two passes: first we scan the file for the pattern and +! * set a mark for each line that (not) matches. Secondly we execute the command + * for each line that has a mark. This is required because after deleting + * lines we do not know where to search for the next match. + */ +*************** +*** 5896,5904 **** + } + else + { +! /* replace "[:...:]" with "\[:...:]"; "[+...]" with "\[++...]" */ +! if (arg[0] == '[' && (arg[1] == ':' +! || (arg[1] == '+' && arg[2] == '+'))) + *d++ = '\\'; + + for (s = arg; *s; ++s) +--- 5896,5909 ---- + } + else + { +! /* Replace: +! * "[:...:]" with "\[:...:]" +! * "[++...]" with "\[++...]" +! * "\{" with "\\{" +! */ +! if ((arg[0] == '[' && (arg[1] == ':' +! || (arg[1] == '+' && arg[2] == '+'))) +! || (arg[0] == '\\' && arg[1] == '{')) + *d++ = '\\'; + + for (s = arg; *s; ++s) +*** ../vim-7.3.650/src/version.c 2012-09-05 15:03:27.000000000 +0200 +--- src/version.c 2012-09-05 15:12:51.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 651, + /**/ + +-- +GUARD #1: Where'd you get the coconut? +ARTHUR: We found them. +GUARD #1: Found them? In Mercea? The coconut's tropical! +ARTHUR: What do you mean? +GUARD #1: Well, this is a temperate zone. + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2f1ae71d7c6788a251af977500559cc0bbd5c91a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:35:58 +0200 Subject: [PATCH 0487/3340] - patchlevel 652 --- 7.3.652 | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 7.3.652 diff --git a/7.3.652 b/7.3.652 new file mode 100644 index 00000000..e05a9dad --- /dev/null +++ b/7.3.652 @@ -0,0 +1,72 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.652 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.652 +Problem: Workaround for Python crash isn't perfect. +Solution: Change the type of the length argument. (Sean Estabrooks) +Files: src/if_py_both.h + + +*** ../vim-7.3.651/src/if_py_both.h 2012-08-08 16:05:03.000000000 +0200 +--- src/if_py_both.h 2012-09-05 17:15:31.000000000 +0200 +*************** +*** 74,91 **** + static PyObject * + OutputWrite(PyObject *self, PyObject *args) + { +! int len; + char *str = NULL; + int error = ((OutputObject *)(self))->error; + + if (!PyArg_ParseTuple(args, "et#", ENC_OPT, &str, &len)) + return NULL; + +- /* TODO: This works around a gcc optimizer problem and avoids Vim +- * from crashing. Should find a real solution. */ +- if (str == NULL) +- return NULL; +- + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + writer((writefn)(error ? emsg : msg), (char_u *)str, len); +--- 74,86 ---- + static PyObject * + OutputWrite(PyObject *self, PyObject *args) + { +! Py_ssize_t len; + char *str = NULL; + int error = ((OutputObject *)(self))->error; + + if (!PyArg_ParseTuple(args, "et#", ENC_OPT, &str, &len)) + return NULL; + + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + writer((writefn)(error ? emsg : msg), (char_u *)str, len); +*** ../vim-7.3.651/src/version.c 2012-09-05 15:15:01.000000000 +0200 +--- src/version.c 2012-09-05 17:27:46.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 652, + /**/ + +-- +GUARD #2: It could be carried by an African swallow! +GUARD #1: Oh, yeah, an African swallow maybe, but not a European swallow, + that's my point. +GUARD #2: Oh, yeah, I agree with that... + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From cf60b7952ce144f72fe599e6d1ec19f97d078dfb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:35:59 +0200 Subject: [PATCH 0488/3340] - patchlevel 653 --- 7.3.653 | 280 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 280 insertions(+) create mode 100644 7.3.653 diff --git a/7.3.653 b/7.3.653 new file mode 100644 index 00000000..7a0691e2 --- /dev/null +++ b/7.3.653 @@ -0,0 +1,280 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.653 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.653 +Problem: MingW needs build rule for included XPM files. Object directory + for 32 and 64 builds is the same, also for MSVC. +Solution: Add MingW build rule to use included XPM files. Add the CPU or + architecture to the object directory name. (Sergey Khorev) +Files: src/Make_ming.mak, src/Make_mvc.mak, src/xpm/README.txt + + +*** ../vim-7.3.652/src/Make_ming.mak 2012-08-02 21:21:43.000000000 +0200 +--- src/Make_ming.mak 2012-09-05 17:43:11.000000000 +0200 +*************** +*** 1,14 **** +! # Makefile for VIM on Win32, using 'EGCS/mingw32 1.1.2'. + # Info at http://www.mingw.org +! # Also requires 'GNU make 3.77', which you can get through a link +! # to 'JanJaap's page from the above page. + # Get missing libraries from http://gnuwin32.sf.net. + # + # Tested on Win32 NT 4 and Win95. + # +! # To make everything, just 'make -f Make_ming.mak' +! # To make just e.g. gvim.exe, 'make -f Make_ming.mak gvim.exe' +! # After a run, you can 'make -f Make_ming.mak clean' to clean up + # + # NOTE: Sometimes 'GNU Make' will stop after building vimrun.exe -- I think + # it's just run out of memory or something. Run again, and it will continue +--- 1,15 ---- +! # Makefile for VIM on Win32 +! # + # Info at http://www.mingw.org +! # Alternative x86 and 64-builds: http://mingw-w64.sourceforge.net +! # Also requires GNU make, which you can download from the same sites. + # Get missing libraries from http://gnuwin32.sf.net. + # + # Tested on Win32 NT 4 and Win95. + # +! # To make everything, just 'make -f Make_ming.mak'. +! # To make just e.g. gvim.exe, 'make -f Make_ming.mak gvim.exe'. +! # After a run, you can 'make -f Make_ming.mak clean' to clean up. + # + # NOTE: Sometimes 'GNU Make' will stop after building vimrun.exe -- I think + # it's just run out of memory or something. Run again, and it will continue +*************** +*** 20,27 **** + # "make mpress" uses the MPRESS compressor for 32- and 64-bit EXEs: + # http://www.matcode.com/mpress.htm + # +! # Maintained by Ron Aaron +! # updated 2003 Jan 20 + + #>>>>> choose options: + # set to yes for a debug build +--- 21,28 ---- + # "make mpress" uses the MPRESS compressor for 32- and 64-bit EXEs: + # http://www.matcode.com/mpress.htm + # +! # Maintained by Ron Aaron et al. +! # Updated 2012 Sep 5. + + #>>>>> choose options: + # set to yes for a debug build +*************** +*** 31,62 **** + # set to yes to make gvim, no for vim + GUI=yes + # FEATURES=[TINY | SMALL | NORMAL | BIG | HUGE] +! # set to TINY to make minimal version (few features) + FEATURES=BIG +! # set to one of i386, i486, i586, i686 as the minimum target processor + ARCH=i386 +! # set to yes to cross-compile from unix; no=native Windows + CROSS=no +! # set to path to iconv.h and libiconv.a to enable using 'iconv.dll' + #ICONV="." + ICONV=yes + GETTEXT=yes +! # set to yes to include multibyte support + MBYTE=yes +! # set to yes to include IME support + IME=yes + DYNAMIC_IME=yes +! # set to yes to enable writing a postscript file with :hardcopy + POSTSCRIPT=no +! # set to yes to enable OLE support + OLE=no +! # Set the default $(WINVER) to make it work with pre-Win2k + ifndef WINVER + WINVER = 0x0500 + endif +! # Set to yes to enable Cscope support + CSCOPE=yes +! # Set to yes to enable Netbeans support + NETBEANS=$(GUI) + + +--- 32,64 ---- + # set to yes to make gvim, no for vim + GUI=yes + # FEATURES=[TINY | SMALL | NORMAL | BIG | HUGE] +! # Set to TINY to make minimal version (few features). + FEATURES=BIG +! # Set to one of i386, i486, i586, i686 as the minimum target processor. +! # For amd64/x64 architecture set ARCH=x86-64 . + ARCH=i386 +! # Set to yes to cross-compile from unix; no=native Windows. + CROSS=no +! # Set to path to iconv.h and libiconv.a to enable using 'iconv.dll'. + #ICONV="." + ICONV=yes + GETTEXT=yes +! # Set to yes to include multibyte support. + MBYTE=yes +! # Set to yes to include IME support. + IME=yes + DYNAMIC_IME=yes +! # Set to yes to enable writing a postscript file with :hardcopy. + POSTSCRIPT=no +! # Set to yes to enable OLE support. + OLE=no +! # Set the default $(WINVER) to make it work with pre-Win2k. + ifndef WINVER + WINVER = 0x0500 + endif +! # Set to yes to enable Cscope support. + CSCOPE=yes +! # Set to yes to enable Netbeans support. + NETBEANS=$(GUI) + + +*************** +*** 431,441 **** + endif + endif + +- ifdef XPM + # Only allow XPM for a GUI build. + ifeq (yes, $(GUI)) +! CFLAGS += -DFEAT_XPM_W32 -I $(XPM)/include + endif + endif + + ifeq ($(DEBUG),yes) +--- 433,464 ---- + endif + endif + + # Only allow XPM for a GUI build. + ifeq (yes, $(GUI)) +! +! ifndef XPM +! ifeq ($(ARCH),i386) +! XPM = xpm/x86 +! endif +! ifeq ($(ARCH),i486) +! XPM = xpm/x86 +! endif +! ifeq ($(ARCH),i586) +! XPM = xpm/x86 +! endif +! ifeq ($(ARCH),i686) +! XPM = xpm/x86 + endif ++ ifeq ($(ARCH),x86-64) ++ XPM = xpm/x64 ++ endif ++ endif ++ ifdef XPM ++ ifneq ($(XPM),no) ++ CFLAGS += -DFEAT_XPM_W32 -I $(XPM)/include -I $(XPM)/../include ++ endif ++ endif ++ + endif + + ifeq ($(DEBUG),yes) +*************** +*** 565,574 **** + DEFINES += $(DEF_GUI) + OBJ += $(GUIOBJ) + LFLAGS += -mwindows +! OUTDIR = gobj$(DEBUG_SUFFIX)$(MZSCHEME_SUFFIX) + else + TARGET := vim$(DEBUG_SUFFIX).exe +! OUTDIR = obj$(DEBUG_SUFFIX)$(MZSCHEME_SUFFIX) + endif + + ifdef GETTEXT +--- 588,597 ---- + DEFINES += $(DEF_GUI) + OBJ += $(GUIOBJ) + LFLAGS += -mwindows +! OUTDIR = gobj$(DEBUG_SUFFIX)$(MZSCHEME_SUFFIX)$(ARCH) + else + TARGET := vim$(DEBUG_SUFFIX).exe +! OUTDIR = obj$(DEBUG_SUFFIX)$(MZSCHEME_SUFFIX)$(ARCH) + endif + + ifdef GETTEXT +*** ../vim-7.3.652/src/Make_mvc.mak 2012-08-29 14:18:26.000000000 +0200 +--- src/Make_mvc.mak 2012-09-05 17:33:56.000000000 +0200 +*************** +*** 213,218 **** +--- 213,219 ---- + # We're on Windows 95 + CPU = i386 + !endif # !PROCESSOR_ARCHITECTURE ++ OBJDIR = $(OBJDIR)$(CPU) + + # Build a retail version by default + +*************** +*** 283,292 **** + + !ifndef XPM + # XPM is not set, use the included xpm files, depending on the architecture. +! !if ("$(CPU)" == "AMD64") || ("$(CPU)" == "IA64") + XPM = xpm\x64 +! !else + XPM = xpm\x86 + !endif + !endif + !if "$(XPM)" != "no" +--- 284,295 ---- + + !ifndef XPM + # XPM is not set, use the included xpm files, depending on the architecture. +! !if "$(CPU)" == "AMD64" + XPM = xpm\x64 +! !elseif "$(CPU)" == "i386" + XPM = xpm\x86 ++ !else ++ XPM = no + !endif + !endif + !if "$(XPM)" != "no" +*** ../vim-7.3.652/src/xpm/README.txt 2012-08-29 14:18:26.000000000 +0200 +--- src/xpm/README.txt 2012-09-05 17:35:34.000000000 +0200 +*************** +*** 10,15 **** +--- 10,18 ---- + MinGW: + mingw32-make -f Make_ming.mak GUI=yes CSCOPE=yes XPM=e:/hg/xpm/x86 + ++ MinGW 64 for x64: ++ mingw32-make -f Make_ming.mak GUI=yes ARCH=x86-64 XPM=E:\HG\xpm\x64 ++ + Microsoft Visual C++ on x64 (tested with versions 2008 and 2010): + nmake -f Make_mvc.mak GUI=yes CSCOPE=yes XPM=E:\HG\xpm\x64 + +*** ../vim-7.3.652/src/version.c 2012-09-05 17:28:08.000000000 +0200 +--- src/version.c 2012-09-05 17:53:15.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 653, + /**/ + +-- +GUARD #2: Wait a minute -- supposing two swallows carried it together? +GUARD #1: No, they'd have to have it on a line. +GUARD #2: Well, simple! They'd just use a standard creeper! +GUARD #1: What, held under the dorsal guiding feathers? +GUARD #2: Well, why not? + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6a926c03e975064eea5a2acfcd6ce21d297cc328 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:01 +0200 Subject: [PATCH 0489/3340] - patchlevel 654 --- 7.3.654 | 150 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 150 insertions(+) create mode 100644 7.3.654 diff --git a/7.3.654 b/7.3.654 new file mode 100644 index 00000000..dca5aa7c --- /dev/null +++ b/7.3.654 @@ -0,0 +1,150 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.654 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.654 +Problem: When creating a Vim dictionary from Python objects an empty key + might be used. +Solution: Do not use empty keys, throw an IndexError. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.653/src/if_py_both.h 2012-09-05 17:28:08.000000000 +0200 +--- src/if_py_both.h 2012-09-05 18:35:18.000000000 +0200 +*************** +*** 607,612 **** +--- 607,620 ---- + + static PyTypeObject DictionaryType; + ++ #define DICTKEY_GET_NOTEMPTY(err) \ ++ DICTKEY_GET(err) \ ++ if (*key == NUL) \ ++ { \ ++ PyErr_SetString(PyExc_ValueError, _("empty keys are not allowed")); \ ++ return err; \ ++ } ++ + typedef struct + { + PyObject_HEAD +*************** +*** 659,665 **** + if (valObject == NULL) + return -1; + +! DICTKEY_GET(-1) + + di = dictitem_alloc(key); + +--- 667,673 ---- + if (valObject == NULL) + return -1; + +! DICTKEY_GET_NOTEMPTY(-1) + + di = dictitem_alloc(key); + +*************** +*** 730,736 **** + return -1; + } + +! DICTKEY_GET(-1) + + valObject = PyTuple_GetItem(litem, 1); + if (valObject == NULL) +--- 738,744 ---- + return -1; + } + +! DICTKEY_GET_NOTEMPTY(-1) + + valObject = PyTuple_GetItem(litem, 1); + if (valObject == NULL) +*************** +*** 784,799 **** + DictionaryItem(PyObject *self, PyObject *keyObject) + { + char_u *key; +! dictitem_T *val; + DICTKEY_DECL + +! DICTKEY_GET(NULL) + +! val = dict_find(((DictionaryObject *) (self))->dict, key, -1); + + DICTKEY_UNREF + +! return ConvertToPyObject(&val->di_tv); + } + + static PyInt +--- 792,813 ---- + DictionaryItem(PyObject *self, PyObject *keyObject) + { + char_u *key; +! dictitem_T *di; + DICTKEY_DECL + +! DICTKEY_GET_NOTEMPTY(NULL) +! +! di = dict_find(((DictionaryObject *) (self))->dict, key, -1); + +! if (di == NULL) +! { +! PyErr_SetString(PyExc_IndexError, _("no such key in dictionary")); +! return NULL; +! } + + DICTKEY_UNREF + +! return ConvertToPyObject(&di->di_tv); + } + + static PyInt +*************** +*** 811,817 **** + return -1; + } + +! DICTKEY_GET(-1) + + di = dict_find(d, key, -1); + +--- 825,831 ---- + return -1; + } + +! DICTKEY_GET_NOTEMPTY(-1) + + di = dict_find(d, key, -1); + +*** ../vim-7.3.653/src/version.c 2012-09-05 17:57:34.000000000 +0200 +--- src/version.c 2012-09-05 18:38:43.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 654, + /**/ + +-- +MORTICIAN: What? +CUSTOMER: Nothing -- here's your nine pence. +DEAD PERSON: I'm not dead! +MORTICIAN: Here -- he says he's not dead! +CUSTOMER: Yes, he is. +DEAD PERSON: I'm not! + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0de8951db5aea1a2b52750925b8d975f411868f5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:03 +0200 Subject: [PATCH 0490/3340] - patchlevel 655 --- 7.3.655 | Bin 0 -> 88812 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 7.3.655 diff --git a/7.3.655 b/7.3.655 new file mode 100644 index 0000000000000000000000000000000000000000..fc656ebe7ed47a917e7aa665cdc510e9ecbaad1c GIT binary patch literal 88812 zcmd3Pi+fZ>(sxfXkbvk!Ma5lTnbpw+QAoHZ>h5O91ST3ZD^b{$Rfc4Mk=%B2M!;n? zAqio22qNMYSMi=05LAqSNS>$aAN!tPRrfh(lA!Lp>%L!)hCX$=`}DQCs=BJWz4zhx zi@EOSJF_n~?&xFEG_i(%|<8|zfZ&8SV?NUz-_qOLmF>x7^6^LU+}Q1&SN3GR-!I&f>&`y(Og7)2 z>+N|sUbnJ#VN-99m+kQ$YCqVQeK_uA4|uEkx-z+*N8%lOGx`3k_q(UtH$7Azq|0Y| z`gdpZ4>k96^mgWY_Bv#aZ1yt6mk-}759 zzP~rW@4yW?B3`Hn(9 zm+6YD>GVFu0P(L z>+jF?>{+>RYj0POf!jssroSuIkF|!vEX*x>sfvE?oG)0}sSku3YtEuKOV!skN)FmwLhK+Pc*b)iyj- zyDnZ=|M1%ShwJKA*18a1QM92&qmlpr=Vc@RFXt;J^k+N0YxK`^blB*hPX5gN#GjXF+|2w#gZCKw zXZS^9X8tJxHsjB$i;baEblezv`)>E=qhA>_;}0LDOUCd!sQZ8T@250i3{N~b=by-p zG+-h(&&U4<`nosev)QKJuHJlmW>;6%Y*$G00WaHwCEgE6()04UT?H@Ozcu$#)*R^T zZt2N+0Ths}*)YHs6H2nZue&Lq&3M_3h26Wec_5taecdhHnLYB+neS%2NM*dt+*#Zk z&2XTvyWh)qWcsrm-F?9~?CI3c&yhiE8@zCJMqxAG`Cmbyb7zq^ z2l~37$R6;vdih+>9{04ZH{a>vPq!epIU7o{IqNlbdjLzd)7eaCHjhV?2+S*kkk0h) z-P+YF=@4(}@v`|IB*T-8Fh;HnfC&HqUbxnw@__r#q4zzzd&95ssKbxwmQ4S?&?BN5 zueXpxj?G!GIiK&%+jej7>u$~M%4hNi?QY^q#lKHwGo3(}?Y%)K2Qb&a0mPp!0VrH| zK%d&P>xoRa_S5F9XCF~RJZ;{H{Q(I8LEHWG{>*hHV(j&UyLt;folSeQ9s6=Ud$we{ zx_UdxVNG+up2{k4dn&s-Q|R)Z$@Ld9UH;?Nj(j%T<3FadecoRGNmgoirq67bX&{eg zdlDbE@jn)_`GXSgH{1Qi-EX$*6t^8^r)oBflKZ`U??Jx@x8-wQ7JVO@;%?eKlj$mG z4+fu?i6@UCq~S8S`7RZDJbO^kN!b_NSe5}@PowY4UT7_i;+2)XZj*7F%lZxFn@e47 z?fUiW4!#B+qkl?JYm`xlb&zP!&RE>7Gosc z)7zfenx-K>yDUv3Tuf7uOWu<-!Y5yTgogNw2q4GPG!}g-&4YXalOK6{m{4$eI zC)?+$Sd51Mj;2>BuyDz8$vu2iUK1Wo?!+q|O>UQeCwWv_5UQ@5JhiAWrVgq? z1KulXDm_+{rsCs$RC;U?6(8TrqZ=2Ym^6=Wtda6iYj0@_mD06Hxid+n^fD?wzP*J< z8>Q(<9&KEPv`L;aHQvog5vL(OT0_Oh6L?Bc@$qGVETht6)l{scQUw(se~^kzcTs6$ zl!{GpnR2zyKKDEi1=AK^k9hPBm0nturcxf2ZBHy~rD7@(r?Ex+gVfPZ<`Eu9Q%T;J zQi*tshN+|zar)&4Xo$~8(lqu&EoS3jD~&CFrG*Fiqi9Qn|G|?{RA3M<>o9Kyt6LlR zHT2f;0-sA$v8j(r8y8WrX>SXa8Zph94j_gq(U1%&9+&7N#&lL+QmGQ1R*gC%A{~s# z5^2Q*f6CW*nx|t+b%s#shBS{h$#kM3AEg2Qgs;&6e_BDs%EHPtl^(~S_&uT>L8Z!8 z=>Y8v6k(@mlT1+_ZIYSE6LefZSiX|Ov!ueifl7a@$6Aij2n|Gxj0p|IXr#eDL}E0| z?-*lRskEvbxb*g*$k(QorpGup*_{(neb!U5B#62_R?h%xk4#28>B#$4T5Y0QI0{{;nr z`Tsj(%&o?lsG%?XDE}jfe&R=aDvVhyN!L}nOk512p9Imfesn?9CB4Uw{oapl^J6sb zN9WITS)TR39f>#?!UAJVrHT46;EyAnbgskt$j5XS6@STe7}f^9&X5F#dSDli}B2)Elo zmo)Mo^~KN!kcaIA2p~drVHO0Szu38;kT8viFIPq|M?e<_Axs_O)0J~nF-#a@_0E|l zL=vLOl@V00JcOx15Q~)&(1V}>gRmP^z8~UJCu4fcAT(r*<9mcu|AmDCbMZ|JSHzq0 z8wy=RN6af;ZFV<{$%n%x@jEQ0+8jx*O5y3A-*5}Kq zbxiz}{j3X(rmZnN)(BW;G(0QeZ1NwgmBy=$S*AiWV+{HLoI-M2@|j?p9^|tJqQ+pa z9RR^`EWra&P}D_!tCfm0oZu5tq2gq^dM_raWa_vm^i+)A;6d4usMwll^Ik|&sc{*K z@^-aQX?v~g*mXPwioLOw#yXa4p|J;fI8CJ+6!lZ-Z`CyB&A%Z{rF|gPr@g!C__W=n zTKS(spASVebpwBZ#L@ly1&DF%*&oMf_}7)FF-UZtr0;n&m1skY>4yh^G)7a29r9R8 zCEDuvwA614_GH&MDy6G+XRfxj8rwb(2~OG8D|L&ld4Wr?qf%0YiddpWgi}QLpDpx5 z4#KSGdopRdw(5cS_O>nY2hudXYT=4_znAfH9W8WKMB?!W;w^NoJNxWk;=hak4fF^` z;B3ND4n;4~m!{&O!~uXmNeI<}=*0w`FvjfWQ5sIr+s0tcxUC(n#b}PiXn4UqP#|ON zQVtK&wdLp^p?RsaBhf}9d>X{r)rbKHwYj>PN>73VybV(>O=GQzJ`l{y@N$um&dpS+ z(h|}%L|3)HOp=N`?A?qmJf zsc7Fl527hl#h4~mS@@Bx&j6y_LRlvhF#*W1ZkJe1gpj{Ii}jkVt%@wwwvl~T@) zX>>@sg~m1sn>y-(-A%b8g{4}f4^T=;4vPZul)qb5!-{yc`Cx+&ee0?I&}AksLa={(~xu2 zQDcuBN~FQ^d<5m>N*MeYo#(?e!~@Y}jLvV4(pdXEi-lxO z$!PD4(eOHLbxP0+CLB1LnhLvuP-t`um3nJhsMNcpnMxZlP4>!+PgkZAJ86ioM8JC0 zOOb8p<54v14WO{np~T)Kjcwv-x`IllsMwk4+CoLXibeJo25vxj@j;o96=_ubRh^4z zpykFSABiUJ5&RfI{ieJP7`M-W3QH*hhAr|}`0OQ=HWW!m_?k?5o#QQ3YM*C^B-z04 z@8`E$D?1a7>B_D|I?1Eagw8&!-_eMCr!w`(p+tRwK0!r4Pf@8e(Us&QRZ@#lTZ?9C z9IA3nFn$Wn{omC`d&u?$I$*RV!lS7boryN!fgSQ~EV0crcIZ*CnV|47r7Zq#MlD(^ zy~Iu`wJl3y@2cYg)NM*R)?q$};TYS9*)rC#MEXZJvsNlqV&dKF7Ob7UrN33D>22B9 zuxMp(TOlpAqBI}|+2F=*t8;mE1hfR?j_{EN{$M|U5Z>>sjKFSqAIe;6p)1&0nzy&h zKnz#4Qn5YS#}kWmj)#^Xq!wu!OC|b%FH=-{ERmwp#yA>*DxTjG`< zpVnos%dfIEvD2-=a49scsi?>oQp@>5nyvt`--8N2(M)59s&3@bP1UL9?d@qQ-oBeh zH!Zpc!cnoTDBYYT>^e7hfX|F16+2&Rnqhq?orm^!ni3nKhN0D~QOUi}_w9j8_V_VUw zjcFRAQ+`$;BL0Cd0ZZVGEfh$gUUQ+9^{C>oRPov8fGhnXn(KrxlVVC*3{UbgIx+LN z>Vf1^u9(_i{g~+Wa;noPfY8KVrfFsww z1#Q(lFrQCE`Ah|0h%AVj1(DlKMQub_dwSPO!RgF=V>VP7p*{Clb|Y#C{4h9=s1ebQ zjehMz7e(Cr{XU~gZ$uowOcx@?+@Sf35f#fv%`Fv1c)6&l^*L+$vci}NccPStBVM!mxr{)`Tr#AG9`NsT8qBT{<{90lN!u1J%s4)<5 zH-ZxsHeX?2^EC!GU*FEfZu{(48N>Z^*lh?1WL{j4O~!lyQxk;$7@Hhov6M{~k!4v3 zvscm)k@C7Agjs3K^vVc$D?8^yp&=BnF#TS>E8F8hj=A3C00O~*bl*V-LYn@*e6Gja zZ9y*ApIs7{t0%~YG(U%tN061M!4)kuMgXEujR}r5|CIyz1AU>Ryt%meGMInT>CXP$ zxn6LB8XO&?LS<*pA`nPrynjU?P`74%**Tw%AB`_C*Odn_j`tuCP%*nPcmIONe4)vT z0D&2wvPX9=Tu&en{h9KBW!1)XK@9g}!T^yahNS@)%B2BVCuz3A0I*Xc#gE2lgg>uT zW?PR0MpKC{dyI?yH@@JJGL3KOyIo4qi!9bK{tSG&gARMDP zGDC=Ulrtw&+SljA<03wCu{Jx`HcpBvGkqGFV z85NBtaBT5eg%BnDE-EybjPR5tfT*+${j^!xPEeB|_8ZYSEH@AuXA^Wrv!@dEt-@*6 z@wwIrk1I23Sn;WQN&u87B$ z;#_Spzo)&1Lt__D(^xu^u3W?)fMwzjq&-8C27bSv-$C`;g%;h8Mszh(X_bn~tYBtr z5g)Y;INU;Gi}}rTB^o=#m%y3bEMkNM!d`Bn(thOxsR$wwXXy?d^p4&z9sA-gh}m*okAmH z-k$Q;_wU!Y?@)Lv3P zTd4h6G7?{Y8l&MGm4}%vM{Ndfu(H&(JnY0w%5VB|)e)ZFL}Oj6A`qBX3m5AB3PUSO z5Z4i`MpUqR5!LHJh4n= zBQ12v@upj-D8(MB;)xryg()hvfB{Vk1Bz29eBMX0Z?{DF2v6{P0V8@!w;^FkWerkk zBbfGlt%zG754>3p7+W!VV|VduniQBOU3mkv4|IiBTiGAKYS&)`GKsF{KxAF)Or*i< zL+DmaiMVb)wjR*j%{2D1Wz|y+JpJOWIC<7VmPuBfuB^oAeszjUJ=JL%Yr+!VjdT7~ zqF$yqc7Y=X6YHGpFBK4c3zj;IX~~mTAf2SK=*kAZ)PILew6meFMADTho`f1fiYIIE z;gLwPfzRz{9LKgN>NnGv_d5{^oQph0V>|eZ>hvRCqS0G~#7CBhFn;1`9V%I@X@Jsn zMcDIH^Y-05nyhZeR&p~>(6`FVi^wDmS#CW~@=$o#`2$Vzf6sY$^X2~ljXPxPLAKK|N$1nN3vGAb36mx7@k$;&v z20wu@y&i8YV~s>X_~n@6IT+v2IrG2E9Ip$SV9%L1`jG20zR#4WnawVHGg;x;Z1>#E z@e5@oBhbif5J)c#sH1QlKF136RB)?~bDjN0RZ_3d7|*2wY*mH*uej2G7GK;UYV_`m zJpPlXygN*KgPfoTiXJMI?3ip{Gq>kI6 zotp|5E84rUrKVhcV2ICxSO9(y+4|LlsFBt26vzW`B|L`Mh^6bHe43`x0wIBFd74jv z3<6P|O4NH>l|pZ&k{}GwT{HsWoxESRn@-g6X=Mu@2vj?%6r~SHIB%R@;aKcK8j5|* zR9ZyCNuK66l{NV!U3n-0_0c1dl&C6?DupDe<(RfsTAvP|T( z!IC56wa65damFSTGX4>f49T}3U^{IOv4>KLwGmyzT2MoKVlDJGzR(16F2)ySym25! zm!XuVYbXr{XIUK&pnm*KnkLcjpGO?$ZTneeLDOJ+-P+w$e6$TLe58TD zLmyv@NFOgww8rS#>c?=Td9hI>H3fc)u0YdGzwcO<5gvF9yvjw0z(84m-AV8yT?E^O zemmDnCFoWf@7KT;wntj1^t8-qaAG`&Wvy}yEMGatm5!3Nj1jX5aFB+Htj(v(P_?qn zM>%gvA9$-2Kb5uqLc~`omMY5pu8q;uExWOt+fk~Bu^RY7fj^@XR=y61o6jYYos}L! zW8AE@iU}zyi6~PljWv22z4>M(YB$9bqIqYR+O_afqp>!gra`{K*F<(Ss(8GEFU9CP z8a{+t?Y67=kj2WU+>DLUcRT=md`7wnN-}hquZkuJPxBi(YvVylcD`$?B%|==vogwj zc?2Ecrt9#cN?=As12G!T>sD!N_JTfzkiyJ%9qF?fF6pGkCNapvigCmEnTODor(D;g zD^JE~xJtWT<`E_q5ZGCac&Pu6x#}WQ5ewnf3fup(-}&R8rczT)jIPxK=ZU&SQw@!6 z=IP(LQDESjpt&PrA@sAxk56HgIz(R4&R1papaBfs%X9~i@1~(gUx1X5zO~~Cr3INc z*6_uj?4^_xAc|{>qcCO{Bw38Ui|!2%TnJO0^J?w#DlJObg%d6-82=wHYmRBaABdRN zp9hP}=E0)b^PtG15DkfrxScI`%}T`+|Kng|JM_r?8=P^5bdywuF;gA~8>Mdw`~^=u zW3eez)a_DniT!w)KEg2<+U z&%b!Dn?Rn`QUr$cx6RoZ_VYinK#wK(sKtE_+c{)AR4-Hrl>g{U70Q%h%UKhs*)92* z(+8$1DeQ6}WXtEyL$l|OU(C#zGiNcgr_IQnI=mtji=+gzXi?Y*zYOhj32l{b|EWhH zJoXd*K?RJ8)fNlpQi4yWxJnuQeYrh>&2fv7ce;gsrupZr#C+GA`fZx0qHaC3-|M6OYprIO>Krj)H4yu(-Nbp=j8lh6oAv-G8FJ;jIQxfY%-!8il>r1HSn;< zuP2xDu;?)f0S*@FFUcJ|w3|*KmjWHV82JAl` zDJ-??F=Sh#3)Gc%*kO)J8V7lw6_wo5;}8nBCfcA(-AGrU`wuGK17qdgf(>p+Dvd5W zoC3Gx!5*?AO=CCGN&XhA1(rb7sB$Z0yC7(W7{*0nSN zBY}>;Qi1o|@zwn|K^av}YfDi&flqEnJwB06Kr&IP#?JW(cB>=kzK#^m$XXMgunj{z zsA{s6sM8^#z;=RW#*s?9Xg&@^Q1Agr>~Dwq;oEXb1*tiB8nu{$Y9vo?QNf2|Di{#S>`j5#jYl#aeF!e^ZJ2T0tOol$S>! z;veC2Agxb{cJQHu7kM!bnYR~Ae=73ZtyEgeM+DInXoQA%G6L<~$bLSD)Q9jeFGg?j z0G0^)>jUA*%W?vY13`DRZCkk|+{ob_Zr>}lCel_*4T36geqejs6KygDV6%svL1yA~ zd!iAY^zz>@Ert`&eoRuSMma!aSNJmJHD43XE=k2G9o1rxL6bB}lAEbmg#r{-FWub? zDi^&mGyAa3RKpWIp{P4erKcKGRN4m}Ri`b-6Ld=3>dPKPQCHY{+k;1bqwSXosMw3A zF{gHfHR!^6$HLc#d&+f^-#uysDjgW~)GcVZ_7vE^iF@_Cv8AZaq@01d%6%V+(I_3$ zmhl9=tFaI|f2LaWc5&j`mDr0;yBH`4{s1f^HpwSJq@IFR#Xxf%LtFAlh`UwY+9OMv z8~D7{U~Qq&-PmhRdy5-sn5VoL=FCSZ(2}_rb#JSrDe&9YiDp^<%8Z$7tx$ zDpSA#mgpf5@fX#i3!kQ;m#U4&UyGb5M#o`~ty-;%Aw7X*HXY~joIU#kcTFRDq};$_ zDt%4Vf6;V2m%0*rL5zH?1KmPHzXxf%QMt(Hq;kRuy)KJcm%DAxZ-S3tN#e{-XXka7 z`)_z+gIQucBvU?GBYeV5{Nfxv!V`|xkP3unE2adLh}~M2LwhyIZS!Yq zjE?hhe-(@MqL8Lo*-0wl*pY_a>OPvJ;$j-0v1BAz(!nyPVkF3dl}*JvfJE)$wz-l1 zl&;zNN6or3)Fy*=?sytQ?UxwRuKjd3&N0x3I1nrlVq^;3~+NWgJ5KNQ-NhSKI^u!__aa=E>^3%cDWUs6!vAEQzBeeGO|-_RJz1%!XY3b zXhc9)eK;WlEPz@br!)K=W+4`X96WTzX!zcUF^BGx#T27q46QY1uZ}H6e=l4CG%l1b zBqHb*H0Y|2b862CS_1ppYIrZgX4V6H|g5wtj4%PMHPa|pq`H5GJ zyjD{Ov;LeyoRL#Wbj+Z)cP!25ocX3onI27W;=VmifW z_&F;~8i!)#eLq4ww(2@j)Iodh4)XJ(oDm@d$HhCzL zq|2D(RJth@OSQ_}M&&SvMP_{nO9I?7C^xhd^gX77tT#DlqVM^vOaUB|6;qf2BlL}H zNoms(QF9c|@G>T0G(}LXfj16a?sl|GH9TJB8U+JG!3i;XBb7Mh-Ascxaq@8skU&wV zYPhqVTL&j({Q>0aca^ZPMy+tbf>HO!xDpFEf^nd;Iwf(wqUF-Za=;~?Ixqz=N2WYj zueu&;q2hcRIFvYq0q!Ds75lV3tv7z6=nL z@8!vvgS*oeUD^cCC0#!{wzeZ`c$_Y3Q9Qv#?THz6zF*4~!AjYv&Oq(*j84XUbf|Ua zLi5*{c9`r!uBC39Koey#J!)%KzKnQ+&nWp2lJDv01EIE3abGPJo9xLerl!mltR0@% zrcDgZHlHd8;T@iM)=di8al%ufq(s)NgV;en3;GC@(%FP4?O;sbONjYQuzh2nkaO%2 zOrc}CRmE1liPKx#K^8b@U$|v=6pG=xZa`N9p$95gcmh(fKC| zhyhgp6R)}jriPNxF66!{*+X>qrztmU=N{G&g7tTQQNR`2y!IDM_VfP=C{6N1p`CH;NhHYzGBv@)6Vq{&1AHALL<-arv$j zTPiIGZ9KY%j6919$@Vlr?!=}8Dd>;q_SXr2%;TCCN0eo&1*~4H zmL!|bjT+a}bj3oLDk{bRPDE@tu~>OOIwj&c>6b9AfvG0XFwLgnM8ZAS>NDsFdB04b z?{d!}BR){D*eN`std8k@lx|3qDL$;O8n8b;f0KLDS1sX~t9ui!ZT*7^9bpnBad zVD2ZgKWM|OIt*_>^^{63Unqh!f|VgyGxP{VhalS`YFqK*P5u^%>a4ZZv30<*DSC_i zhPZViEC%YU34D)kKI<_TTopNH(PEa)oefuvUk1l+u8r_+M6Vqy$KCQ;P?7%{Pg-jw z;((3p(cK6i7pqXoC7g(#OHi*x_3~PJIYz^O^S3N~8&FNg6FGm=aTDXWBJs5h&rI^& z;ufX&hWRa_;(t6Xni8YoJAOv7sDF%x_y3Gi(FPFBm!&T-cY&kr?v9t*Z@SVjPkl>R z;02%FN56`k0lGaP40QCA+V=?^Ng)&*Y+l4X1z*I5A_JfX%X`4g$JkCI3Js#TC}$x@w180zSR2TEvaIwlRokPq8)4jtm~sI;qn1CGyi|4iwi+pd%`hDj2C zEkoF-W9p`j>quaqpz4@jw)Y<3PtkeEWtX=IHSKB?AZo7wkkS?r0*GKA9je1gixNPx zlIKEtaMa}%Ekpf8cH9^Z&ShE_ec}t}mu=^;dIg*CO7mqeOPlU~)PG=Xu8KiUl zD8*9|wmNpN;?a%bd5?-4qXN|q*;p+P+8-O`z$I968*99T?M-w?3l*DTrhydLZ}41W zpMh-gyhL7$kRD>)U&|wQyCe;5F*QjlHp2^??ud92r3xs2x-hI}gv)M+X<8=ph!bQ=27a*TTm6{88B z*y>(@4v;Pi5lB4oxRYMVl0u=^CvyVk0L#zKzFEux93ou57|dwl3;w_#2^mvP>F@-d zwO0OkBW#+=Ev1Vr>M4Omn{H3+<%t?6ge*FrH6av3XS6I`yfT}xzA=+{f=9J$glD8{ ziVMUkAJDDrZfNF2rFK!6Pq|)VyUs8?2s2h8PjE>;X>|in=^QN^5FXagVP0AJiuN>5 z&=s58N7_HPBJdU{792qaIHR#f9rB@I-?m>yBixrCRr1ch36k|D z!2{0z<+kgYzgQ0xcl^Zr-(KfE=C89ZfEzIS-WYLuAhKE>vvx5`Df}a%Mk#b6VoZF2 zT3+K{y12lI6J;J)V9bshV_?L*v&I-ccbhtn3cRAThLsLzXJ`D5dJI{Z(>xpeq7+*8SGII4nwnW*8T73wk}YWUj3qW9*x_uB*Wnz0~y zdA`fVuLV&+@0SWJt#U=Js&Xa0T;=l6M^(l^Z$E1I<0@AvxF1s|7rAOR*pC{TsCGs2 zJAQP*0tfuv0%QJ13c5>lqp+Jt#oviBaC;Ut^tHTDOQd^ma5hOi>PNFT`d$6ajqd%1 zn2XVPOg)4~4PA;E18;Lt!&iOiq8j(DJ8N9Ze$4Y@f4$39<7GbpTS)yBhE=RF zc$d|;AlMZKqX&(_*NeV|cUgr&^IK!^E~{^0JEJf-QPmhW4Sn10!+`wtEwrBWE!-a| ztkaLd_l3Tl%aM+?&?>VObUmkbfO9!~MS!PV)C;zP;?`OENp`dV1iUHRS^z?uWp4{W zf5M)#K#NirxNz1a+gy+c7am~j#N&ZVkVd~w-r+b4CcHN^Ej4%y@Iam zm))~*=8&+_)!=&f)>)9Hvmj2)uAYGqARpF%a`t4s&|CuqMwH#+1|GqEYg1XSxlJbj zT$To5_bdo3h&8y9X?QjWzP)ConwSmxZWf3~W`m%XS6&u>JR9`&EKpQOBGd;r&4MhQ z1%a=z;A>6r@fh5&qW7ri4Jsyd!OE7c+u91AScA6Z4rIIfSLXWjnU!@$?nX)WbhZ_| z@Qc;384X=lq~+S1Tbj0RYi~-gT)QE#5tWk5Oi{y^tOR!$J^y^JyYKm}*{*Dd_oQ6> z=7aS6_R)Q>yD#JAc6DV_P4-19+m-c#N3XZ5cYij2{TpYrAT@&x-#Al#%~6?SC~FgI z?G0~;ODW@ED9-krEvFeeKPEA2xgTf#I=uEWXQFNQVzao?Gh(u+eLC&#u zh(n7!fscHJKjY#m67GO^h+zECjMJWx128IqE@=vZqaj{09h z(yv9zgl#z3_t=L)!$wUi;#ffhAu)s+(HQ6_IIg_D%SC-V7p2(b zutI46#uqgRz2)y|%5EfhTxPnzEvbNa zukAxQmTOZO@GXM)w*M<0d@uK^vE$hUUiXaM2d8_%7Btt+0$coFerNl4b~W7Z_P^NG z#CiAZoelk{8#y{&e8>7*oITzaosF~`2YG4?kH8=O5onVbj%V6k0(%7dQ@iB;54+b&C;MDJZ#_Od4OfL47MFKxM-5^!1oDEb5DkjNuEQLXCO~Z!|mqoqI*$DS|IT zni&dnZI75yeK#3Bh(G{Fkc2b5D?vKS!#9PBlZ0)J!QDf+g_MRGD#246i_vhm)hd{X z3r{kZgDUu+L?i!vjHa3m9fglb*j9zMD>_;gqp7Fix%OHLZfuJ@n1ZqJ;ba3$2u7X| z=1|-sLhXpBy(kUy$pRmPC2|pQXad6BLNgt0O~i5BdJgx6$^m{De$`}{R?rMVnW#p{5EuYvCG~y zS4N!q!uCZzCm(hlG4_IdK1Ne_lsCN~#z;YPhiyyui1xxXx=8MSwVrY0o`Lea0>K;? zZstjzbheB!ntBrIJh%dLW&t$BUq%YJBX9r-^p;n96RLmkA8I{MSf3!;a2RgWF{n%o z+VTHmJQ<@Y8TC3Ia8+o5~-iMx36KEG4sBgj#NkC}mppBhc6uIJYZzeQ2r znjimYNk1z3`?$T8PSCLUvVF>qxVw0yg@(EkH87i>IZ#*;gZP7+HSCQ(TFCGcEo95` z){9iK8D7lX-NNqTPgSiN7TZKD3pj$2TM=o1F4ut+N>k~t)lj^B9g};2z84v5 z;m1l){H6?l-Sz~nVmIglIsX^@5fuc=Wfwmy} zTnlp33}7qziP1HB9rZ$C^iR9KRSk~|tu)q%$=g&@&#!r6 z$6EC1F-2{Q9=}n4bAeyuNj^ODisEup zM%iNQUB#%$8}NrS>Zal=m~+sigIRnIRbnKl1K`USCZrMpL4td!!i{`%{$qq5q8nzXdCV z$^Q`}ylW(Fk=#((Qt>z+qifApWmNs9 zq2u4w5k8DWZ>#<@cFh|cG6CXxPdR3cV38-9BYe4VHy^1oNx2tMT8!0b z1@=6_pWD4qdbF9wGBUAHv)05i)bAtLS9V;Fh)Vb}uK_PFYyD8CalMZV+0aAZX*Nx~ zk&i@gGCWBi``fto?I%1zqYg_3hX?+3e4*R##H!Oa1J@8v{9f~g6X)hCN-h(JDWWxC z)26!J9(8?_O1S5MvE`q{{nRaY0aF+5z)TcR#^^bv3WH5tXg6(TYe&;vX&T!KGg26W zI;GgOz)QFDk!S@rZXRut8(f3J!VBFxG8$w-At@?FoZGz;w6+Hdx1r0=$l4H8Vf_r* z6P2z++|Cm|LW4qzAcCpAa77#K;s=A zUlpVhdI$m^_JYWkUr42LBPkGQ}pj)^DA<)DxGI;0drmaEhPq zkgHuq_=^o18Q{R@v-!9#qZX)yhR{c_O$M`S@4+jk)!3JY(3?P-kR_lKbpsuz_f=(; zp;auCFQ}Oyghttigd7H@Q}2C$6DK0}e9Gbk8FYRx-2u0e)|&_q@)^`{afR>pUY0I8 z9-~Q@;W-G^Ij_AvLes&j&|wUZ$T*K%C1u5?kK4o@e1Wb!Z;P7XBdN7zx3b~`!0->) ze{NE^ZVwtMR}kCnr4ytm1h1%y$Vot z#W&8a2yRTIy3$lfQYKOxsEu#Fjs|yGsW(=c8zU(bQXtoc@L`LcScta4sNPLLxUHIx z&4W-9+HmuXshn>_9}t)7y-;mL`>(GWlJROI>U?|#PaoZ2M1Akx&g|}7Pu4uYyEosR z@o1FKY(STAt4w>KNTxEYD`zRK2If1i28EbGsDe~p{?Z{;%X z<;z9wSOU(hF_EK22o8B-*);iIu%5xgWDBG{mU0_ zndd(FfUng3uzz_1Pt9|x)}qv{cP7y1^PSo?U$7TYM9qBv!of%Ft&dUDUFEc{>Fp{% z&!DgK&1d`s)xIkC%4(+?zr&BwC)K`o`geZH7Zu_%RWqC{PR- zY!uoNHVShY8-*0jMqyxKqp+IMD1vmKQ4I(e2WCeDRR_XB0daBU*A$rY4hnSU;^-Dl z0X<*`MHjg^bb&Pmy30YK4ea9RJWT-|6$eE}x;S)#H3d4=L7^4w;^<;cF_*@MoDr0r zMInSWHm;}Ji}N=@Vu5NcrmA4F00gT5L1zI7#0rpF0D;{LP+I^&0|dV*D17PwGNCde zcn@a{L6}1!#9jgugq6Gc{cCMN6wKAQur8P?>Ef87Jj_-I!3l%-TK7ZvXhC&!gDWw^ z;aU5DjX^gDxr)$-&Q^yl^n_tJvpUe%o$-1LInCrw&0chc2xRuXBM39D*PN|IE7^SI zTNK^ze6DAYd)n5U?{x8}TM*lv4JFx} zbt;KcRG{041Ge^qec67i(wXb;@5^*#=hT`k)1-7ab}n2I-<#>*>t%NN=V9(JY(wpJ z6c*Pt)XS-vyJp1diX65(HWo>ET1sC+i%)e$hOHU~Nb>)Z&LWV-4*OXb<~j=lvXT9E z;flCj=-6+N)G?w%EFN`Nr>S(X2BL{m>ZkD#Wb7B}cwjf-Jb(v9ye8uK!;vKX3(RYd z@X_RQ7AfEWL~s?&@Euy<52&;N)a-ZsmB_|;kUy?WcW^Ns;qTKl*2S;#C7!(5dD$4k z?O+Z3K{~cs{6$xae92p!rc!ldeO-Y+g;2!GD3o7%2fWGK!eaZbc;&07p*<+fQu#3+ z1SrT8T$D1(<4uk&bzZ2wUxE7`cdWa5>Etj2PnUsVL*f#!n%HsDRD|})0q~T~hDuG< zk2FR9zHmj{ipiU*d6F*erV~_JL06u6`st@zsnk)Eq#u;J=V==A9)gT@0=*kW_fv5V ze3p~h|mM+I7EnB0ZuX}V@dE6od-(!pULb`!Z^ow}?3v}v;0Z$@2yHA$a+> z;d8@B`6Bvy+Pf)Dr903+@9_8`%kEK8yvZMlH1M~t@P`q5wI?AifZEiX@<1(+p%v&9)4O_lS@0_*^UWgx> zvYISB5HaRnYj_E+85f0s>c9zt>d)|J{*7#p_&1spWII-q<|7}vqrw4mehdL9PRS>Y zVZ7A92xvuNXt~BfIO$suP6`9rq%jap`W8f!!ay=<3{}^+bCEI*!zc9n(M6bbNrxjxX`W;7rtHDD{B zO#pzh37a<9cuS9$&G)z`u`7VWOBn!W2jx4mwQUd`8GkPhR8y|E8*gZ^)&nzk;|ume zz`1r~QRRRF5DW2oDs5flFlFiSB_e0^{Uh;clawR7nc%@Pk&$~seH^yIw(yO2k{&yVeZ9=EAM8ip3S^@{(#;@FUCe{{{xk@(CYhXVtDoH+Bt|}*im4c zm~-_xwP_)WHO+r*`C;sTj`w|U3xs)WNY7~wV&i;Gj$TER3VzMxNsiTpYI5?DISh` z^J#Da7ChQLGi9QcN*fO#ISqD zBd%&rE~D`pFGi(}2^v~ZL&anqmnTy(nUL@Mcx$d$7?(+0$J!Skpd)zDq7|`37Nud# z1&QGPSq#JzKGg)vX{DcD@?&C(qj%dPD8&MVsImVmsz{dlO#EpP^^YS^tZZ~mKmkGM z?^|l?ih(-<>7?tSS#+MG!8H7GXco)9Jj_P3Xi+&jo=x!}h*6jXAYKf82+hv0OtA{S zTeD@>F80x(VW+tY8lbNwB2qTjmf$RgHkD3?X(KEWp|RggIs{skumPgp!` zQQLz59{LqhpnPwglls9}EUqx-ZY#BL*f%UWLlCr)0-nZ2a|lW&wKeM1S0}wKkTfi4 zrm;UlQE`B;EZF~tW=I<*f8`J%QnbhwDua<`8vBzb{C>gyyK!IV0Mt4TM?{`cOg8Yz zB#ot#e4@Z_C#h(xcH$6D@`2|=%qtFwacl*pfGAEq=j~qt7;r?oV=)~~NB9ITjV^~1R*lwWF-WmOI&&pkWh{FQq;LHrTAPB z32PWnf>J^df*P*Qu%5-2o^X%AY=Qz97rkK&p*-K))thh5=X>*b+FI!7$oBUm`ea|W zXHzEEmF<*;k?YE~^t_nq%E{vsy<4)~z4?QF2{xro65rm}tz{ZDf)r7{n6ycC)C0Q+ zB8&-HQ9@K{%|)OtZKF`#v{865ve9q+sHj#el!LVVm2X>#@PC2kF|+X9s0fNR1{V<; zgFrxI@P?r=9G_@xF2-5VQP~y|7AFg0cU$I+fQf)v5o{4KuaU7(kR?Tbe2b8I1N0Px zUv7^OimEL9oIN6pk$`(DyLT;J0Rv5m$ue&w3E1$_9d?uU6hG3rR z+|=GXhcW&2_k*={W#qV4BxTP~=h_Ykq9E~%c*!DWSn>W+-0%#e3iLU-eaHn|SsgxV zK>$rlr+&uH0W3pjD~!3{ZV32CB-qac65c^RE9ZicK8nauoDE9ppv>RE{-9Dzb&@(1 zqoblIt9qNF%%%72r5bQeo9g?(8Dd;>v?q4P=)3krVmEFU=#=>V65lQHWfI>j@dqUS zg2W$`co#~lMb18Ze@~I$!lNgTFw&O`I!f(wtp)t~L5V2L~g23=%THWB>_?~iDIr5gCV z!bYg}-77kXX)69j?syy5+pKUH8>nxxnn&&wA8V?_?k=!JRYRkrrSl~J17Eb7iqLW6 zNy2TfPIqyVzL6@0#mX{}&@&A7HFrYgf*K{>f^(1AM*9fR#6kemt(5#DzFV1ds_FNw6Z83^rH|0_o`L?H4DB2!NCUTrNL_LSXp6 zy|4SJY^D=Lj^Ov**}Of$e111naMrK&A3LRPWrvqmRJw3QTt<2hJNN7D5B2Np_AoGA{<)>gTg=rG+5Q*gTw9<{znF+5>RjsR(_aQp*y=%DubOReA# zW=8-gpD3R(a}s!vsxuPX{Zpp7SfD}cLV;Z@ajag zT>C7@xe_i{Zci-p>nGPxH}H@cEtX((0HcZ8XI0eTR66uUNk-HrNJBC*!yMCTp$u~1 zH|xCwT!mo_kK>MlW6pV2k>x^cy%)&uLU{5PT^zyjg73xW)ny(}s~&?T`A1;Nx5?dHoFdXW|vygp0V~sn#cLD)6DR@#ikOIf^tV(ZX$>4G*|s~??hK1 zCMN{$E)1zWZo8kPcSAxYw=CiE8A>5X&|RvF&D zvgl1{ZMZ&1qjl@9w>$E}6>&S5{#J~y|A_0Zm47yco{rw`zI?X7KmJfh{GR*z?=g9^ za?eXiJU=!>+;iRe?2T2=4fQLf${xcz#f%RV7y z8bhn}E&4)X{_IgSt`u4gMR!cd3g*Ivc(>0e$DFUcEOaVzF5V$tSL{L!~0@ONW zHYg~(!($RvMleg9HHU`(7-1IL(b1gBNI*=v5GLM~R|`%_TnO*v%B#&jaX|pd>w@xO zP7fAAArNZ1AZn*w0skhPSs6nINPk~G*W)>FF_NZ?Spx(C$95VVWQHCrf@};kQqAE# z28*jam7I~y0AbzD0Ey3k39b?{%0A@Ah%peCJ5m&4S&*Jh;78RRYi&94s;+0s=vkk7 zRY$7N_er1Ghv##>yPn@&=;?5PKJBg0QP=-3&TJO0i0AhN>bnR(MMF2#uP%4@ree}~ z!mXj%G&JL|7)10UyUM_M%tb@<0KCaSR7t}&sklu3Hyzqwrxh3a;V>5~j73FPZ-(ju zE?BTkw4@9zWP~{MCeH%x zW|>};k2F?fV7oVAApbnqN@Kr6p**>8MI5@nW4-V@@aZdSHquzix>yhrYmm<`jqoVH z#?!4G{9Ox-RHIuWe60nh#Y&3dvSP34?|eK(V|#cS1-%S@2p1D+PmNYGoIq;DMr9G$ z`>Jgb_UhEI^Be2vfJ&RhkI3z!&H<+FNoBf~5I@zS}1;IqF1s`WYy^!opDgF@~q=MY$1?Tm>yN{ce-6_p4)!itNBX|Acs|b`*ny{SY_gYMhHn%Ml?AwwYnj?w>{iCyVxQ;D(`CQJ zKCfAWi$09+xqkh6s5%&PzkOd{ujcvVe_PM!PT@H$SOJmID&6}k>@F@t7J*MW!xXv7*8aAKS(Ko`DEnDQ@efIs6cJ}7& z^HWbfCGQW~XEzIdO~`HAwn+lg!$@QP^e0?zf!S!Y?ARf$ybZl!0na`6oThls0y3G5 z0zS5Yjt&+2(iax6a7A4I({$jh5O(j@wMXAsKrUw|_caUHx6h)25ew+)(PI-nW&wSD zVs>EobqnaXW_A3o1r!SEppiecfCC4hgn)@=0WZCzXoAmMz~BG=cTF*60XN@{ggz_(^=>3UTU4nKvdQYn~H{1kTFrn}`9oRL~v zGKqYHpGHr+!oI~%VIMizCHxdN;b2$rQyAPaBhU}{Y4ke>o5oLJ*DQ<=<0mj4aj;?h z6n4zPM)6bF>kd}LPhsy`*y6>iNXTbgqGR}JqR$=dRs0n8rGveOpTfR%uv7Rc?5cyk ziJ!nKt>}Q?!B0SeSstIpPk=YObnoLQpd}7;20sBUb)b*&6VUw@bjKZ#AQ|(ZOY$jx z0$Srh@Cc&w<6#Gy#7|Ns9q1f>0!lm31^fi`qyv48pMaimAP{Cc75?Ht-{B{zIvwZ= zegfL(Kv(e-P~L(ZX=V;s0G;D$rB`U!Wdm(!=j@n+P3Oc0oDkf|oBj*q8iIiw3JKK`p&_Qi{9FfZL2<(k+2nRzThjtGKu=gEaKW<_7-mBX*y*?B0p3C(E zf9pE`6ARnt+Cg8sRMU2UHT10yvW}f;+Ck3KFzba>Y-KTqzvOW{z4(+(*U#@;TH$>Q zq4WGD!?zhk8LqU`eU|>`D-JZx=NZCqW9C8Vt849D(u=EN4m3t1>Yrw@gG|%6tR%yo z4m6UsMwNG42wmVawj-81(3!YJFtsk5E@5NVx+GV93gY(`l+4+|O1m_rX0@Veccu6| z)Uyt9kv@T57BBP1B-B41dfHHr=5_ zI2SF%2}Ah}3%HYyG5ib|!yi}>z4v=@(rOHU<_h}e_m=SD3l8)xzi;Uh_UjemmaYcr z+y+&p6u%%S`J}nYLRRzJvyCt33gDI^k%+nu!iBWgcQRzN+gU8<7{DYz@1V2kdwcnb z7^L!GL^ag*#8 zna->yi8}UX@?Jh$=+Byty}cd1T^TQHntJn@F8uA;Ef;KQ%HDiWf39nvX*!tcF{w;` z-{#(~&TLP(`^=^;v{bu!Q*S=o@9F3FWO6h+%n`A4&@*0NS>S*tBj%UZ2vt=6(uYgwzctkqi9 zYAs9CuhFvBXjyBttTpzXmbFI9TBBvH(X!TPS!=W`O}JLeTB~KP)w0%VS!-<)Eo-fo zwN}eot7Wa#vNXjyEo+^YwNA@gr)90vvewy@TGl!(Yn_(0PRr6)>$R-)TGo0kYrU4W zUdvjqWv#avw5;`7)_N^VVH>op4O-R)Eo+08wL#0;pk-~)vNqU!TGj?FOCRdBta>f0 zUdyW2vg)<0dM&G7%c|G1>TPx{%l_4}8nmniEvrGxYS6M8w5$d#t3k_Z(6Sm(3YM$< z{ZqE9t9QTI+uM^p*qPmL(!HK6qn4h|T&Cx#Y^TY+2ty8C*Ik(xvpt>JylJ(Oja`NQ zy{0v@zeme#&35`W=kgD+uLKdWIJ<( z?hs;DfE1(AFg8(0&`N!_7*HSD3i-aStbOp?qVIzG+h?4M?$N$hNPrFXS@9tTZcDDS z#~*<$xgHNnZ{21~uHQTO6f|MGdpkNZ{kb0VMCQfJ3%!czp2)m-Q2t1Rp6u#ug@+zN z=Ba#Um$7(U|G{T$TiP;R*`S&7B(n^$ppJM7YS@oU-b`(DPRB!)5-PoS$J($rk+?wg^?8++CPLHjbo=%(2@7Vrq zrhjj?tIKT7WqW!u#?6yMnx3dR=<93Hw|*1>*&{;KXbkd5jX^A|F$iom26tr| z1HG#;5J4IfcGyN?WniOVA#D^4zeeSnVH*w73cG2cL0U9UfjFYj7`zy23|7M$!v#DV zYx85UbXORZIW#8bHa3bQWgEp^Vm1oT6&e+)&PIc@a_^Xh25F(bpuieG22ZsLgLe{* z;X)^kLCCE!T(hMyXh~^IMA9}2hmdCh~ULWAziW23w~5&Ckho$el{AUA#%PXtkL%32VC8PzBUX*ozME=FyFAT2ch6e>Pb{KwzVS^7gH|;?f2Lk|0PTShHjU8(1(E3aO$H z$c997Yxda$t@RCLbJ;GdL1|T#dMVYc!3q|+Rp9eE^N+os?>RH`Je%EU-~Q}xTEpx- zbHALKIrBZ|=m=M=S9x)j7nij%N?hf|h4`if)>t2`wM$sN^)*{xyY(Hjz9H+QG0!{W zc|Y~MSFD$9!0Q@$ag`TWd2wYE)HUS|QT%u*v$gg4n|=OvpZ}Q8Kjib%nE%I&|Hr5P zA6I-ols}E~r_t(Mb=&-DAh4xdVSQoitGB*p>ua~ZW7aoheKh8IXFTtxo)>n$bVauG&q>#MiEX6tLWzGK!mWPLQ|d1pNDr=ItU^(rr}^5QBluJYmn zD68vfePQdXx4vfUYq!2*);DB*H0F6{JnyHT_lor@FRt?9Dle|`;zDvr*VFpK)>m(R z&DPg$eaEa1me3>@0*p<2XRH?v>@ES^iVuGwwj_XC2?O9(d^j!2R{(A$4A2Ad;lw9j zfh~|QAl<|VoT+>*2e<|3uSlASoqqWcoUGxW&2y*|YUsghwbF9NfXY)GPM|nldU06s z0)(X(g5Wa$4X{AZm11z|3gCen`k~#wr|FHc_eIW+u*F+MWf_F69|Q=tVrAfG=)Bm4vF=)QQdk zPt@wifudWU+FDM(%JJn!;e9Dkls71rr$4J@XEDjkAw|o%W~crCWcF|#q?4J#8Qwzt zuAD?YU?l2VnW&{QSHN;(mr!T*>;_%|h|&@}M5kEvY8)o)8CAlj2DOR%tWP!vvMkdT zB2Ruc#gU- z#@8}ZVm*zc1YA=BYK@<2R%3sD9Z)V)Am3$&`0 z@_$fwqm=(mAVE2oh4kG>$3DvMu7Lbc7mce~wyBecrI|S8gUtz4x0y|O1ml#C1t0(u zi!@plE`Ir#3B_iCVCt=v&5giz0Hk`NbW3G-K18q$cPpxHsL$vo20Eclg|t!rrGPrE zzN!k*H)>{`ItT4GcVN$InzHJT0JsJ#qBLDOl1Nk@i8KQ{`+*OGi+tCqbBHh5XYnSg z3RPYR7g$tAN$za(WGt|+Nqvx3xjmFWvOSncMSa7MnxDYs{ca&Pp+DK}hCIl7>wi?fMHk2f9k9AOKxUZ~C(lO#^L zz6h|wvoQ9k&hspg@lQ~`ucDr(?)CM;SE><6tq$wL0t6A7f2H`ZFdco}KFodkSJ5KO_K}*@&9u5=vd~5s>U~Y>a)>7S>=-2=j0SQ9Wy!Z2OurjZO3(~XCj?A- z#VOYg-MR-O?J()YIyyp+IZbR`rbqJKXYBUCejSXBvs_s$(%1l7mAP1?5yo_Cv`)R1 zoSRW`$LclEfR)v#@)`bnyEd)fQ-yBHzME$Joznoblh<3TxCLmr?G~*n1E%x>lGMy9 zS){Q@ZHOk;{a9!CEmmzVjqLxdjm!DwOT01`=@D|F3cGYIpqMX2nMaKvoFQH?NSe`e zdxGtS4h=;qcdDn2azph|%Fzcrp+huLDQQ)KZix>XH~dvmYz9_o^I2>kYXjwWu0+P^ zhvTgLZ|6#!!VJ1AupSAoO`Xy-Ll+J#s5ndB@d6uu0u; zx3a}L%wMQWc1BNn}J{fLOcSar++0J~BPH$hGUasaIU~@;~ zYAm>YwY!*G)uir>s;f=vjvJ0rw$Z4*ZWMWDJv4A!dmT)}DnOEQ$Cpv= z)oM(h&#)=xMfE$hoG(*17K7IdatTx--Nx<0w8Y-Uw1b`;Ds&-VZ+4w4EqkxB?t(MXmE^G`NSg7H2x58TxMGF*gtLMlEITlhF!8o z=j8|MXyvkeP|eaAPqx+_h@<))$TjOOM+!}}c{k;c?F)W{0`!%js$CeBtEH*ORpwMN zjh8hZquk&IRZ!X-nc1XJl`guCJ6LgVD^^$ZMSuq`hB%-mSWGvMj65Vq51OG{IP>r% z#fYAcHL0;-btTrMzKVrf)K{o!k5&+f!Mn(L0YkMf42n5hy_ta#-ab3zS=3~TZx1VzKKGQIWO!2#g zd(<8=*0628{K^-!EL7#;p$3?s%_V-Ox3WigE7OC65_pO|3RUw5`LN13Q!L$a-q-$F zn^y0rxlM9@uvQc?qY8AKJ_f$>t{_Yk#r+*^S$u`PGIU4V$0Zvi0e0 zjZO8x8%++oucv#5I#XTUCwpFft?!LfCq|AB^zYlh^H9r+(F3tvyW@NICfeJ6^V@?j zv>yKT<8QrESG(@$v0uLY((nK9rt`$w`pu`zf6o5Ffus|75cjtS1J5sHcnl1TA4V8e zFLJ7n8!2`jTYbKe)ibykHH!tW9CSh3;o^sk7Z!;GINlYis~k311aAN9OTa60x8wsKky{PKd&$X==W6``E!Uxi~RZT zD$Q4#tu&(Otg8d;sGy_H*+dE$bxEbZ@j}s7{rEW>G}^h;SK2gN&|&PP7H6NeR>c~u zfiR%@9^tY&7aLi2y0F-Yz^kvU)v+FHAdLQ6ZJJ86HuQldCMP&ymSI%HhreKNEzFRU zuM08culdt92b$CFU_JMFPgSQf{63;<7M&l6r9 zT4}@}J%@E=oJhzBc2}H)ScyVm*1>6zES%xiv5jbPHb~?#{IN75)&!M`)~DS0?7~vU zADo8dnv6I|BoB&$L~_I*RBcDbRP*OWA)5k@bKpeh!1HcTa+o#Frks>JIGo(qnR>0g z_f)da*>~XZ?xf37>>Q91x%mc(CvmJ^CnGBl-A*F-E?mX~$-d+X_xafL#QmNffeZ0vPvJelCCuu@d55-K2FxMJ@5#Qg&V+sRAc=2T#Tmo2VvT{I!4pG z7SZ(nswHX$5x{Z$yk-f+&a2FYl9fuma#Si|49bfU>I|d@;a`li>?QqUInB5$%-y%1 zlj2AiqPu$oYSvgF$IlA%mO8Dz4651J^?{l0?p+j6H*rvnsM%M&P%uJG}c2@}OrF=q7SF?FJ=7XGx(sVQC$81eExXso0T@|J2_C?@Ej#alcsp+)(M6|O1 z$b9y=EOZOUB9GC;tOw>ZF?*@_cBIDLT4p@(IRcmXt5KPd;1sb62~oF8+1Fs`t&+08 zUq)HjTQlb940~lpF4yjlA06qdkdQKL4TM1 zZ*kCByt%Tz;#dH%HHUw{;QMXT&A&PzT$>>S=@Dsh(Ex~}A;>S#e2}Taff39auxUV` z@JfiYA&!qYE5Q^ej(v>kV|@h}6~^tc@^$3R&^?$Q!$T+_Y~2-d!_?>> z6=Ju6k!ld@MMVHR+gvFX0o<&+(qT9xOaJOi0fbCFty4I61|9W@Rb>TvV>!~lV6O}~ z5Q}MEoIo)%f}E|~3?M*^+RJ8y2X=W&7a#fsEtR9YgrQHwhaQoy_$y(kr}$8kd`12e zhOQAG-qPhO21mkBQ}Lmvm265@zQUBOe1#oW@nIb0E3l*zhH(`ic3$~v zP@9#kre3~+7bjn#(MiHE{^En0die^eFA0OiRq^rMkk5R$)uB*)t-TP;)e#KLvr^P% z=m;=bpd&!IT8A3UXr&y7bp*U%=m>an&|UyVB|_Od4-QuU)}04hc`#6dHGspx3Pa+B zKsptj?}b2h7P{FB!HW($)C)mJbJux65bNZ%Jgtb?En+_(y-UykS6;a+p1BxE@04=R86Nx3E3&|qxOI;6t=s3&=< zrKfZF;9%Q;TYOQ_`lZWV9*V-uEyG-G4)vzeoqhJ_yo*mPIpp@(kM(+p8gP4cp0K=NQ z0DRzMOUa?C1qT^p9+f%FC)5mHeLmF3E0cncJJ$Mu+`{e#LUf+*W58I*`&-eu(x)JI zPR$l`aPe!@G)=oeRi#t4v!Xtru}mj*I9e&xC@4A{d0?^4gL(&9eLS`a(dR9e0N|Lq z@L%y^(??$AmHFGrSG14F@j+8c9~m*uKfUm|GJsm^tG9MP8Rhg%C!w5LO^eU@sjE;< zw7A%nvb&^L{H}~*$5L`PIt)oy?Lh8IRXswPYR6FjVZ?+MelT`+rdbdF(kH`1ox`cJ zMo1S}@J*Yy6f;C*!N2jC!x~!4t#@_hVOj87w30v^dCRSL?D^{2YR92(MH3kJ-~XdF zL7c3%K!>W&m0QR-4btp?IgYxd3pda&|DeO+AfhgnWZ7Pd5$oVJ1HjJr5sh$`hkcE3 z7D!Z9;XNOk>IB_P`DLQE0N1d56z_V|h6-pnR3=23R~N~9-92C*7?6qUWr9G%J0nYgehP+YiaryB*IBQ;UFsfQmcPK8F$RIv6MkBOODVso0vN`MOcIps zg6d&665|V)R10rbF;opq2gt|A`4wv)<-4kaz8hVGy3Uv!D0{vfLABD4sk!Iklsf=L zi4`DWX8;yEP!px;*j9epn+!yo)Qyofl&b_|qtaC$Ge-qB&U1UKr3Uk(kE*}Gq&KP! zRZIF+eVT`(L0$JMpynRrEBUyZWC}V}-=zM|{VB;pjC#<`1k^))-lV=mJE37JO4+9w zt`*$Z1m%wtFA4*K#$%D@fPgS$Oq*hn<`7N%T)rnL*A;0*tuhhy0oN))*)X_V1*mNU zDk{SeSE_l32~rb?DDN&!fl{ z#k@g9F)!Zdin_lr7%*<3)bUC{5F9+#^)Oi1jk%w|Y~W|*CN-N@Ukb=gcOG*`LX`QX z^j?he1L__+t@G%kJgU+BDp@e>&Q+(C7j=hM6H zZt2e8PU*=VWqLBvq;7;L16x3*Fqhtzp8TV~C!yAKj?T)Li@q;vjy`LnJYB@u!hkB; zD7TLR1J>j-R_O%zWEaz_pbF}e$BvW5sPI~T7ZXhMd1_KTp#Yoc5q2JdP}+G1R2og- z6u>l+wYXbl^|`)CeLSG<80a3fYk4LJSf%V^Xa(q=w#OK!?A{uhrp!vrKB0xtCiVWv zCfhaY0(St8lexX%vcdcS;|&>1P+KPTDC?Zn3l(*@s$O#fsR&W#32Atoa?REACiw)7 z$)dyFG6@vdHM1&1G_g;oAm=_%svwl9stOpwDo}}@O@sAJh zR>|I``O*3CyLpB9Hmx5?i!Sxnv$3&Oh>6z&WT?V35>))KQH%gPtu8kTQj5+(u_F!( zmm+MK8DtfBIMy{Q<^@0*fYH_pfdLQDut5OQK`k(MK`r9gPwGJ^So0aEW^04G2iON7 zU{Sh>YdVVf%D=7S9U+~92@fcT!Iy977QAf77SsJU9xY%h_kW({p8zGnZU94(bT)dj^G^IW-8BSM%p{yv8FXJU31u)4 z=f{Rlz%%1tHEFtoKDwSpzvj2X(g3P7MYnLf5mO~MWd~zfV1Lh`iF7H-YuB1&qw&7T zhCqlW7Rjlw3jiH(;Z?eHcNpTsN_@!l#rr}Y# z7ElHCwVoe5YcOcujKL93LwfZXm(Q`+)awWO?$;A{ zgH`nazWb?={t%)+q0#6FZkDNMLaI4G74kxoF@9xLg%+7^^WS?*$ZrpjUQA@6SP<3B zu}}s76qu%#;en95P+m2SM|6)e@o}IzM44YzF?f^y0b0(hALDbYQbI3Frc50|lv!-$ zZjdwY=gs`!h6f8d8Vj-?Z=Im?8C@w6u*nB~5;YYfQPUw84CH6Ta0F^=&MA0^PMDg* z5T^lIs;M|-ag)RY5)Pr4BAg9+oyC@rCu)8v{R>r~>>}^%Rqi%N)4^>Zx|4w>_1(y0 z-g)K|9&<*0nyXw<+)?$Jh^(Nz3cgmhtI62n0M4kLkYk#pOazR2Y-;zg!{OZqTgJhN ze}mEoGrU_e9ljKz%*z33!@cyA3Cc5P8<*z4;Z8xhH`R9>9hhQR=izLd)C7*T=C*iu zQCfXQxi=#Wf5o*iYx2bH=o;4y!FXMeIw7~KJJlrM+FWJMSQTEE395H1)Sf~2zQWN} zY5JSU(oCqY(_tLt<(%bpLsV{oG2GGPs?aFedbQ#5DR(~_aXLtOI>U%$?4&o;yN|1x zwa~YT|G5}gbp{X4HB=BSoS_&NVgA<@@lZ_t(UE7@4=dyA)K%m+4^_;fB7fkseGHOe zGQ+aVgnE5znm(e}rfxe>)jvV~TGcsSzYCS!YN{gasDiqx>FNy2s+q$%9>kbqVXA0` zE>8I!y0X@w*BNx$X$KBs`@z>~r{k30!=2_;D!xvAOZhz|eHN!Iqc@;l z7Ne#6Db7b^2p+{EjkrX|A|3Ij7$1^b4XtK|0?3i3AC#?OS&N7Cejr~Gk!I=pc{flH zzv9CaFFvMy!4OT-Ia^LFQZJ%MAjyzMlbmaGzH(6=l<4!z*3bE;IY zHNvpr=rq?P4UMa>0$6wx{P%JI7cozK5k$n^vIMk_0sXDiqCvf@w}K3-t&agw9%sf{ zJp>xQ!Mgt*f0&i>3EDV;Kkuoz$5_H8cet2acDRP7V~_Bub{sdxzl=OiImo|&S$0t< z?1yp6J+GN%^J0%m8UMr<`Xyh6+3eUX8hEz?pB&w>eh#~gj^V0q+9&8-x=NLfbrtE*}<7CdIR)AD4T+tf~D^u5r2S44%b z#waJ3>0p%dFmu3k?JmSOXJU`5Gjv*g?vb}k*bQc)jH^*M)EOah(NIjyBq$%PXbZ*E zw1fNexcU$@BoGF>VG_KgpNL5P7!k$Zao#MtEUrme&=SEuVF5MuMH)riC_&lXwO+@L zGKXzKGc}{kv6`xrkx+#dlBe&Qi=6dR!ii2z!it4DrxVDpDRrCIk(Dw~1(=`XC0YbK zDn3??tIHj6y}>3ZzZM6YDBZ!s0ZKKuTC@iTD)75-cM$@?7^NuPU1Eb6W|!bu!}bh6 z6!wcZ=h82DYzU^49PRIz$psY1w-)ym{QiP}!*^9qwHcMy$9JFEZ{05?1$#vb-!B16 z<_t@-v<-77(@{)Rnc;j34f3jh(xV}IA9A1Xsx#4A^?oZX?btga&_7I;_!_?hKnxtl z@`rFLRJWJ{VT0Wvl`;o8-XAioJQe(^5tbuvmW=ouQINWcRqO1D2w&T@Y&Ki`V4x!!b{iEtjmteq#cWk{ow{i%=WRiV^yB>- zqKQ2?NARuIlWj)9HEM3TZysY!U-yl=cW=>`Rk3wy$NdW#iQ@hri`J^C;{Im@d6e=a z0WgGE?2pyBn-<~j@|NtnTq|zZ9?Gs%S0u_0%$^Ws^zkoB*>p9A5&LSH>7)v+vLdmC z+-t@SXOedlcMr}5J61PS29GS+G?*PC$(M6Ew>Km8s?aH^!Bd!1?{gVutMv-y zQdb(($nBTUZEC6&%o32rzZT`DX_Y=V`?E0@OPe;Trdq+Qa8#j9w#cHKyn2;MAq&k% zk46o#%;CZ1F-HIJV4rSKA4zoSS@Gk-AonX>jG;c1t-+>tKEh;)v9sBqsY0D(kK7x1 z$mt4?M4T;!r5Sl_PggJiC5PJRZ+zxlS<0XRFK$|(n&mtHge5bsrceQH6*`1}0fGg` zmqC{3WFJrz;$uDGafv)8am`O~yWm{Nj-gPNmF9Va8=e6kpe9&26Ye88yv&M4Z%9KJ z%2k9az?mr%;fmoU?W}-CwFy@Mn-Jl=NH23KawFEs&^iui)B%7g3k}x+K&5d2z|<%S z2Xqbyt6BAq*t@cI4$;J@%o|~+O)&TbCpVo^#t{Ix1m(LRkO!m4{2+Q852E}&!Vqpq zmaD6L77MG{!|EDuccybfG|?chap1ajFhS18B10%j_kk`IeITXE#m{7_6R(^ZZzlArOZCNd!F;S$J8IAmwa7+&xzpsX} zEnx{^pnJ9@qJXmIe@Q=kd?-Hq)we~^2{tVLC*5F!nNU|tq{Q}7i@T6TVW?e|C@uSDImUKt}L zWrQAcEW5y0GzaTVM>?Bl#ZNFJR6)HX?=)ED=S@%gDoO82TjP{JP@kZD3uCFSs@an; zGRCS5uy^Xo!OKJy=$bUG80;j*uS7NzZWsS`oHqThSie}<8S&G-f%5XA=KJo2#8b8S zD&-f70NGVqP#QH5s&+zwhn?#B#mB0K7PSY}SOs&H95t??POO)b&Mgs?E~^RLQX|mX z<{Fq1e9&P~GqBaF@UXyVJKFcPb{uq`=t_1&PyW%--Y&PtIogwi@?+=dzzKjAQ_fMS zyH6b*N)8_#Vv#bW+aE*Hl+*8=+~S;MP`d-05~4ttiHr!ouCUUskTDl~#<2VjI8e}e zv%(0-Dp*Fw$u{VyYgX8`snUMWRod?#d*0iX#&U8?&_tyVw6t!}p*uk%4h!QgfI|hH ze(PfkD-uX^HZ)dc(C$VzXVB@lVKh-?q-N=c^{Sg%4QG&zY6vj?iN&T$Z)xS1L5Kdb z*x=^rt_@XQsPaM|tu|4gvOc^IOYV@K6(1|L)Lv+^6sW$Mt~R)QHD^PYK55ia2AwCg z3dx|8SYq;e+4@++m*lE0EHNYYGUGY4F>dy2oymXXA2Nau-e)TDU zSz)rLk5|~a^yLbZfx5B6L|qj!)vFDemeBVhlV1HPWa_uF#-uq=BWU@c^P=^gvR`Ss z#-yfCYQ%nL&{6N#m`SM+D&4BC+6a~RoA1Z(7YUG{Lm%F6q_XMj`%SLuz55*pb_s)y zx@c3Wzuj+hy>Y)OcG&|a)!+j**X#o(CVljPiAlE}a2#0p3_9xj2TWa7JZJ(Rf6#<& zwZ7-<*B%>2lQxjP@ItRxuexTvr&c-+>?y*6`$J}&>Fz_OB$fBPpLpKytar)7Vo5&e zJoK=`sP&+euwlP_*l}QNH(2c#bKbzlVSj6;El!$LbqbO@j}=<&Po$fiq_@5 z2#`?EmBMv#DxC-EJ+93ya<>Ea>!ml&55*O@F3_OG&JV>ExNfQBxgP;4(&=LSa=tV6 z+`*g1e@+>D?qX*W&d4-~#YYozGU@t82XUa(v7fJdCJvmoIctJS1s^z)*a|X{IH=fq zJ2LMnQDsSDkItk!H3S{~X&keK%JwO?CbD++p#e-;Im zF&;10uuQC!J3QcJkMiKWd0|3U*_mQOA|)Y^8WCsWJXaI~&G#(LAp-U2A^v%&vo9@b zJv~_u?`!KRH#v~%9USn2V9Oqj`F@^vG+(VI#Q!FWWG6pEHsIW^S3KY7YM;KH6o zaSTuJJ>Hq>InX!gn%IX2hr5jbH*N4)K@$;;KQ+W@+6LU@@Bn`8PL?ggio!?^W!e-^ zcEZkyWYN;kRX}yPoVJ19;sBOtVd#IX(>1dB)~x-O@^bl&TN;YxPJ}oRZ2W>GgSPug z4IE?|SS}y%SvZh{ayayI?*FQ-)F)yE2YCMuJA=fPL!l#HJm5HQ>bORjGF4^&q= z)qw}th!>oe4dHW~sHWMbb#(+Cn7hM95o8PEA{+w8)R+H?51SSr7Jo<-1oOd13ndpg z-dyJOCY*o7@wt-aSWu$pO7|A;n{of%-txm@9pVB%6%vxoUoBo$&*e;^4~Wx3x2-Gdl7UaxItwfeLRFR)&pYOLQP3l>`A zyGVPph)+gBmCj!{#wN*Uh%880W1ewk=2itSy);11~ zbhBC%48!3lfr!P=Wv3ORkeH{0*VMCMN`gHMVFBP^z}cVjRyvrOA$sRU;YY3l1klI7 zK{h}nsd4b3zDKgDScEAc-G;H)qPY1X*5o!uw{ecc1L!qoi5eytUO8Iglz%hAKo)+F zG}st^hT?So*pGT|aca^zidd&hVx`p_KHR0-K;e{>xLKFjr0%-+;cH2`YOczcJ2LUr z!Q>9r$UwP)9-uSc6U+kC-!hzu!A-0JHxT8Q73P^59x1wwR~$t7@MeIqxq{m0=PP-K zfeu46PzeC4MS)ugsb18LGY^Nk*6JAL_OU)%C^q8E_yv)2t;?7n%o=b_TfFKEWKUOI zU9YGK(ZnNwdF2j9jtKB~LVa6_Ec44@vlo?xL?QMQ(IhCDmalZp4^|o+-aph}E`%ua z-(W8Tf|j8CNigX)G_ycPa9=?EEkU`(XgC|@<<_xwN6dXF*4xINlXZUvosJ0PxRa(Q z5|j&CJ+`b98Hj}1G$YyQnGD&oVN>jGQb>U${|X;ai*l z0P@g&~8EMB`bPVuTmPA4%Sn~#A zts~0vC71)BNCJ-99EWt<1ho3f+eq9a7yMpO-=IE1^B4;=={`*}P@GL4BcrQ~H9>CU zfp|du-KQqFjdClir1PUq>f$KlUk>uacPs+IvKcUQja%J3BZj(HtH>m5PswGHFEN|IrO`=-gELg4YMzJIzcB6Yl`Xa!6 z0fZGlQZ%C23$}JX%toP>OudB%n*pr&d+uYPk~8Q#^_{F&{aPp5SSEF!HK`k;>JpY9R^%7% zDqexBAvb20$ST&!RG`l+lYcpV=_6IkF?Cq!scCb5Im<xEt;I8dqcW z@g_CyLR!YQhza*;RR-`Tv1E0sIrRx+4GMHd{Syxkpr#|fD&lnDucE>uIme7qZcije zxt&m?x@xevM*-ZHXtth$pN><$gYg}_KeLV^LENxl5^A6dF8_1SJfkBhAwk8GB@jQy zl|i0c0glsJg|q6<7?U#?hiUzOE00*&BSzUbrb~JU&JG{Bd-=M+7@7+*5`3-T=iK5~ zo7dGX-Am?S4CKH!O&jH2fhxUJEU4~#0&11lcD(aED;eS;z4$rD{OaxRJefQ?0NWUw zUUW_j_74pwQ>pN;!fV#1);Ocirju_tC*SBD3UB677<+v)b6 z2;+q#ygs}(_0r4XXT!h8<)m)?+7w4|)~xLcoBuoFbC3fbK-O$P+%;=c&XTpM@Y{5U@J@x1 zyxn0tNlwsd(fV70tdvGxVW470USa5*W0QwJS|Ek!gHt*R3!}nJZ_SN-(Oa(X$L1$N`3EXcLu8vsUNb0Ut zy^52Wq=qp)snS5uytdHApkc++mqA=`xV>N4MC$K0RrMm1(@L#?HpqtWB=;Tm>+_3D zGY{FY*KF9SMUK|dz{q{0$90j>`AWBJB6ZfLVqG9`_!ch%#y_28WWcek4xE@$sE?$UH_gILgJ`;%->* zbzv4Bj#HI{z(MhoIGyu6zHlkCyi{!loE(hUAtMfg4tjAm=nE6VK?Lnb^EokoR!R}i zMO65dVE`W;;!YE-Jx7oB4jw<+ogO%00)|fX!3=RZ_HbE-k1gjw(q$&jd>+rzBjNpn z;eq5R3^#{6-EeZCD?Hd8?(XeNE?vKVeR$KRx{==gjoUUowdv`tTk2B7C+bF$!{BCb zI*O)zi;x-ByxneX--J zY}?$hVcX`-VSM6jC16W<%-BmE;J}S)ajn+2@j4k)5eZU0vN$ Date: Fri, 5 Oct 2012 00:36:04 +0200 Subject: [PATCH 0491/3340] - patchlevel 656 --- 7.3.656 | 84 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 7.3.656 diff --git a/7.3.656 b/7.3.656 new file mode 100644 index 00000000..a9d768b6 --- /dev/null +++ b/7.3.656 @@ -0,0 +1,84 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.656 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.656 +Problem: Internal error in :pyeval. +Solution: Handle failed object conversion. (ZyX) +Files: src/if_python.c, src/if_python3.c + + +*** ../vim-7.3.655/src/if_python.c 2012-06-30 13:34:29.000000000 +0200 +--- src/if_python.c 2012-09-05 18:52:50.000000000 +0200 +*************** +*** 1025,1032 **** + + static PySequenceMethods BufferAsSeq = { + (PyInquiry) BufferLength, /* sq_length, len(x) */ +! (binaryfunc) 0, /* BufferConcat, */ /* sq_concat, x+y */ +! (PyIntArgFunc) 0, /* BufferRepeat, */ /* sq_repeat, x*n */ + (PyIntArgFunc) BufferItem, /* sq_item, x[i] */ + (PyIntIntArgFunc) BufferSlice, /* sq_slice, x[i:j] */ + (PyIntObjArgProc) BufferAssItem, /* sq_ass_item, x[i]=v */ +--- 1025,1032 ---- + + static PySequenceMethods BufferAsSeq = { + (PyInquiry) BufferLength, /* sq_length, len(x) */ +! (binaryfunc) 0, /* BufferConcat, sq_concat, x+y */ +! (PyIntArgFunc) 0, /* BufferRepeat, sq_repeat, x*n */ + (PyIntArgFunc) BufferItem, /* sq_item, x[i] */ + (PyIntIntArgFunc) BufferSlice, /* sq_slice, x[i:j] */ + (PyIntObjArgProc) BufferAssItem, /* sq_ass_item, x[i]=v */ +*************** +*** 1787,1792 **** +--- 1787,1796 ---- + case VAR_DICT: ++rettv->vval.v_dict->dv_refcount; break; + case VAR_LIST: ++rettv->vval.v_list->lv_refcount; break; + case VAR_FUNC: func_ref(rettv->vval.v_string); break; ++ case VAR_UNKNOWN: ++ rettv->v_type = VAR_NUMBER; ++ rettv->vval.v_number = 0; ++ break; + } + } + +*** ../vim-7.3.655/src/if_python3.c 2012-06-29 16:28:23.000000000 +0200 +--- src/if_python3.c 2012-09-05 18:52:50.000000000 +0200 +*************** +*** 1817,1822 **** +--- 1817,1826 ---- + case VAR_DICT: ++rettv->vval.v_dict->dv_refcount; break; + case VAR_LIST: ++rettv->vval.v_list->lv_refcount; break; + case VAR_FUNC: func_ref(rettv->vval.v_string); break; ++ case VAR_UNKNOWN: ++ rettv->v_type = VAR_NUMBER; ++ rettv->vval.v_number = 0; ++ break; + } + } + +*** ../vim-7.3.655/src/version.c 2012-09-05 18:48:22.000000000 +0200 +--- src/version.c 2012-09-05 18:53:20.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 656, + /**/ + +-- +DEAD PERSON: I'm getting better! +CUSTOMER: No, you're not -- you'll be stone dead in a moment. +MORTICIAN: Oh, I can't take him like that -- it's against regulations. + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 47ba3180f84755545459582eb1cc6ffab56e949d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:06 +0200 Subject: [PATCH 0492/3340] - patchlevel 657 --- 7.3.657 | 195 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 195 insertions(+) create mode 100644 7.3.657 diff --git a/7.3.657 b/7.3.657 new file mode 100644 index 00000000..158acbdc --- /dev/null +++ b/7.3.657 @@ -0,0 +1,195 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.657 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.657 +Problem: Python bindings silently truncate string values containing NUL. +Solution: Fail when a string contains NUL. (ZyX) +Files: src/if_python.c, src/if_python3.c + + +*** ../vim-7.3.656/src/if_python.c 2012-09-05 18:54:37.000000000 +0200 +--- src/if_python.c 2012-09-05 19:02:07.000000000 +0200 +*************** +*** 191,196 **** +--- 191,197 ---- + # define PyRun_SimpleString dll_PyRun_SimpleString + # define PyRun_String dll_PyRun_String + # define PyString_AsString dll_PyString_AsString ++ # define PyString_AsStringAndSize dll_PyString_AsStringAndSize + # define PyString_FromString dll_PyString_FromString + # define PyString_FromStringAndSize dll_PyString_FromStringAndSize + # define PyString_Size dll_PyString_Size +*************** +*** 288,293 **** +--- 289,295 ---- + static int(*dll_PyRun_SimpleString)(char *); + static PyObject *(*dll_PyRun_String)(char *, int, PyObject *, PyObject *); + static char*(*dll_PyString_AsString)(PyObject *); ++ static int(*dll_PyString_AsStringAndSize)(PyObject *, char **, int *); + static PyObject*(*dll_PyString_FromString)(const char *); + static PyObject*(*dll_PyString_FromStringAndSize)(const char *, PyInt); + static PyInt(*dll_PyString_Size)(PyObject *); +*************** +*** 406,411 **** +--- 408,414 ---- + {"PyRun_SimpleString", (PYTHON_PROC*)&dll_PyRun_SimpleString}, + {"PyRun_String", (PYTHON_PROC*)&dll_PyRun_String}, + {"PyString_AsString", (PYTHON_PROC*)&dll_PyString_AsString}, ++ {"PyString_AsStringAndSize", (PYTHON_PROC*)&dll_PyString_AsStringAndSize}, + {"PyString_FromString", (PYTHON_PROC*)&dll_PyString_FromString}, + {"PyString_FromStringAndSize", (PYTHON_PROC*)&dll_PyString_FromStringAndSize}, + {"PyString_Size", (PYTHON_PROC*)&dll_PyString_Size}, +*************** +*** 578,591 **** + static int initialised = 0; + #define PYINITIALISED initialised + +- /* Add conversion from PyInt? */ + #define DICTKEY_GET(err) \ + if (!PyString_Check(keyObject)) \ + { \ + PyErr_SetString(PyExc_TypeError, _("only string keys are allowed")); \ + return err; \ + } \ +! key = (char_u *) PyString_AsString(keyObject); + #define DICTKEY_UNREF + #define DICTKEY_DECL + +--- 581,595 ---- + static int initialised = 0; + #define PYINITIALISED initialised + + #define DICTKEY_GET(err) \ + if (!PyString_Check(keyObject)) \ + { \ + PyErr_SetString(PyExc_TypeError, _("only string keys are allowed")); \ + return err; \ + } \ +! if (PyString_AsStringAndSize(keyObject, (char **) &key, NULL) == -1) \ +! return err; +! + #define DICTKEY_UNREF + #define DICTKEY_DECL + +*** ../vim-7.3.656/src/if_python3.c 2012-09-05 18:54:37.000000000 +0200 +--- src/if_python3.c 2012-09-05 19:02:07.000000000 +0200 +*************** +*** 172,177 **** +--- 172,178 ---- + # define PyUnicode_AsEncodedString py3_PyUnicode_AsEncodedString + # undef PyBytes_AsString + # define PyBytes_AsString py3_PyBytes_AsString ++ # define PyBytes_AsStringAndSize py3_PyBytes_AsStringAndSize + # undef PyBytes_FromString + # define PyBytes_FromString py3_PyBytes_FromString + # define PyFloat_FromDouble py3_PyFloat_FromDouble +*************** +*** 273,278 **** +--- 274,280 ---- + static char* (*py3__PyUnicode_AsString)(PyObject *unicode); + static PyObject* (*py3_PyUnicode_AsEncodedString)(PyObject *unicode, const char* encoding, const char* errors); + static char* (*py3_PyBytes_AsString)(PyObject *bytes); ++ static int (*py3_PyBytes_AsStringAndSize)(PyObject *bytes, char **buffer, int *length); + static PyObject* (*py3_PyBytes_FromString)(char *str); + static PyObject* (*py3_PyFloat_FromDouble)(double num); + static double (*py3_PyFloat_AsDouble)(PyObject *); +*************** +*** 379,384 **** +--- 381,387 ---- + {"PyImport_AppendInittab", (PYTHON_PROC*)&py3_PyImport_AppendInittab}, + {"_PyUnicode_AsString", (PYTHON_PROC*)&py3__PyUnicode_AsString}, + {"PyBytes_AsString", (PYTHON_PROC*)&py3_PyBytes_AsString}, ++ {"PyBytes_AsStringAndSize", (PYTHON_PROC*)&py3_PyBytes_AsStringAndSize}, + {"PyBytes_FromString", (PYTHON_PROC*)&py3_PyBytes_FromString}, + {"PyFloat_FromDouble", (PYTHON_PROC*)&py3_PyFloat_FromDouble}, + {"PyFloat_AsDouble", (PYTHON_PROC*)&py3_PyFloat_AsDouble}, +*************** +*** 544,560 **** + + #define PYINITIALISED py3initialised + +! /* Add conversion from PyInt? */ + #define DICTKEY_GET(err) \ + if (PyBytes_Check(keyObject)) \ +! key = (char_u *) PyBytes_AsString(keyObject); \ + else if (PyUnicode_Check(keyObject)) \ + { \ + bytes = PyString_AsBytes(keyObject); \ + if (bytes == NULL) \ + return err; \ +! key = (char_u *) PyBytes_AsString(bytes); \ +! if (key == NULL) \ + return err; \ + } \ + else \ +--- 547,566 ---- + + #define PYINITIALISED py3initialised + +! #define DICTKEY_DECL PyObject *bytes = NULL; +! + #define DICTKEY_GET(err) \ + if (PyBytes_Check(keyObject)) \ +! { \ +! if (PyBytes_AsStringAndSize(keyObject, (char **) &key, NULL) == -1) \ +! return err; \ +! } \ + else if (PyUnicode_Check(keyObject)) \ + { \ + bytes = PyString_AsBytes(keyObject); \ + if (bytes == NULL) \ + return err; \ +! if (PyBytes_AsStringAndSize(bytes, (char **) &key, NULL) == -1) \ + return err; \ + } \ + else \ +*************** +*** 562,573 **** + PyErr_SetString(PyExc_TypeError, _("only string keys are allowed")); \ + return err; \ + } + #define DICTKEY_UNREF \ + if (bytes != NULL) \ + Py_XDECREF(bytes); + +- #define DICTKEY_DECL PyObject *bytes = NULL; +- + /* + * Include the code shared with if_python.c + */ +--- 568,578 ---- + PyErr_SetString(PyExc_TypeError, _("only string keys are allowed")); \ + return err; \ + } ++ + #define DICTKEY_UNREF \ + if (bytes != NULL) \ + Py_XDECREF(bytes); + + /* + * Include the code shared with if_python.c + */ +*** ../vim-7.3.656/src/version.c 2012-09-05 18:54:37.000000000 +0200 +--- src/version.c 2012-09-05 19:03:03.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 657, + /**/ + +-- +Have you heard about the new Barbie doll? It's called Divorce +Barbie. It comes with all of Ken's stuff. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9b20d1e8263447bbef97ba3fec7afaa13ded97f9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:08 +0200 Subject: [PATCH 0493/3340] - patchlevel 658 --- 7.3.658 | 159 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 159 insertions(+) create mode 100644 7.3.658 diff --git a/7.3.658 b/7.3.658 new file mode 100644 index 00000000..eeec4687 --- /dev/null +++ b/7.3.658 @@ -0,0 +1,159 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.658 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.658 +Problem: NUL bytes truncate strings when converted from Python. +Solution: Handle truncation as an error. (ZyX) +Files: src/if_py_both.h, src/if_python3.c + + +*** ../vim-7.3.657/src/if_py_both.h 2012-09-05 18:45:24.000000000 +0200 +--- src/if_py_both.h 2012-09-05 19:05:27.000000000 +0200 +*************** +*** 2530,2537 **** + #if PY_MAJOR_VERSION >= 3 + else if (PyBytes_Check(obj)) + { +! char_u *result = (char_u *) PyBytes_AsString(obj); + + if (result == NULL) + return -1; + +--- 2530,2539 ---- + #if PY_MAJOR_VERSION >= 3 + else if (PyBytes_Check(obj)) + { +! char_u *result; + ++ if (PyString_AsStringAndSize(obj, (char **) &result, NULL) == -1) ++ return -1; + if (result == NULL) + return -1; + +*************** +*** 2549,2555 **** + if (bytes == NULL) + return -1; + +! result = (char_u *) PyBytes_AsString(bytes); + if (result == NULL) + return -1; + +--- 2551,2558 ---- + if (bytes == NULL) + return -1; + +! if(PyString_AsStringAndSize(bytes, (char **) &result, NULL) == -1) +! return -1; + if (result == NULL) + return -1; + +*************** +*** 2572,2578 **** + if (bytes == NULL) + return -1; + +! result=(char_u *) PyString_AsString(bytes); + if (result == NULL) + return -1; + +--- 2575,2582 ---- + if (bytes == NULL) + return -1; + +! if(PyString_AsStringAndSize(bytes, (char **) &result, NULL) == -1) +! return -1; + if (result == NULL) + return -1; + +*************** +*** 2587,2594 **** + } + else if (PyString_Check(obj)) + { +! char_u *result = (char_u *) PyString_AsString(obj); + + if (result == NULL) + return -1; + +--- 2591,2600 ---- + } + else if (PyString_Check(obj)) + { +! char_u *result; + ++ if(PyString_AsStringAndSize(obj, (char **) &result, NULL) == -1) ++ return -1; + if (result == NULL) + return -1; + +*** ../vim-7.3.657/src/if_python3.c 2012-09-05 19:03:51.000000000 +0200 +--- src/if_python3.c 2012-09-05 19:05:27.000000000 +0200 +*************** +*** 85,90 **** +--- 85,91 ---- + #define PyString_AsString(obj) PyBytes_AsString(obj) + #define PyString_Size(obj) PyBytes_GET_SIZE(bytes) + #define PyString_FromString(repr) PyUnicode_FromString(repr) ++ #define PyString_AsStringAndSize(obj, buffer, len) PyBytes_AsStringAndSize(obj, buffer, len) + + #if defined(DYNAMIC_PYTHON3) || defined(PROTO) + +*************** +*** 552,558 **** + #define DICTKEY_GET(err) \ + if (PyBytes_Check(keyObject)) \ + { \ +! if (PyBytes_AsStringAndSize(keyObject, (char **) &key, NULL) == -1) \ + return err; \ + } \ + else if (PyUnicode_Check(keyObject)) \ +--- 553,559 ---- + #define DICTKEY_GET(err) \ + if (PyBytes_Check(keyObject)) \ + { \ +! if (PyString_AsStringAndSize(keyObject, (char **) &key, NULL) == -1) \ + return err; \ + } \ + else if (PyUnicode_Check(keyObject)) \ +*************** +*** 560,566 **** + bytes = PyString_AsBytes(keyObject); \ + if (bytes == NULL) \ + return err; \ +! if (PyBytes_AsStringAndSize(bytes, (char **) &key, NULL) == -1) \ + return err; \ + } \ + else \ +--- 561,567 ---- + bytes = PyString_AsBytes(keyObject); \ + if (bytes == NULL) \ + return err; \ +! if (PyString_AsStringAndSize(bytes, (char **) &key, NULL) == -1) \ + return err; \ + } \ + else \ +*** ../vim-7.3.657/src/version.c 2012-09-05 19:03:51.000000000 +0200 +--- src/version.c 2012-09-05 19:07:40.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 658, + /**/ + +-- +You know you use Vim too much when you have this alias in your +~/.bashrc file: alias :e=/bin/vim (Eljay Love-Jensen) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fe41c018b6a71ec2516b4284e3596eecd8bee2c4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:09 +0200 Subject: [PATCH 0494/3340] - patchlevel 659 --- 7.3.659 | 295 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 295 insertions(+) create mode 100644 7.3.659 diff --git a/7.3.659 b/7.3.659 new file mode 100644 index 00000000..2a30e67c --- /dev/null +++ b/7.3.659 @@ -0,0 +1,295 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.659 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.659 +Problem: Recent Python changes are not tested. +Solution: Add tests for Python bindings. (ZyX) +Files: src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.658/src/testdir/test86.in 2012-06-29 12:54:32.000000000 +0200 +--- src/testdir/test86.in 2012-09-05 19:11:36.000000000 +0200 +*************** +*** 176,203 **** + :else + : $put ='[0.0, 0.0]' + :endif + :" + :" pyeval() + :let l=pyeval('range(3)') + :$put =string(l) + :let d=pyeval('{"a": "b", "c": 1, "d": ["e"]}') + :$put =sort(items(d)) +- :try +- : let undef=pyeval('undefined_name') +- :catch +- : $put =v:exception[:13] +- :endtry +- :try +- : let vim=pyeval('vim') +- :catch +- : $put =v:exception[:13] +- :endtry + :if has('float') + : let f=pyeval('0.0') + : $put =string(f) + :else + : $put ='0.0' + :endif + :endfun + :" + :call Test() +--- 176,237 ---- + :else + : $put ='[0.0, 0.0]' + :endif ++ :let messages=[] ++ :py < Date: Fri, 5 Oct 2012 00:36:10 +0200 Subject: [PATCH 0495/3340] - patchlevel 660 --- 7.3.660 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.660 diff --git a/7.3.660 b/7.3.660 new file mode 100644 index 00000000..9c54170b --- /dev/null +++ b/7.3.660 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.660 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.660 +Problem: ":help !" jumps to help for ":!". +Solution: Adjust check for tag header line. (Andy Wokula) +Files: src/tag.c + + +*** ../vim-7.3.659/src/tag.c 2012-09-05 15:03:27.000000000 +0200 +--- src/tag.c 2012-09-12 18:10:01.000000000 +0200 +*************** +*** 1797,1803 **** + */ + if (state == TS_START) + { +! if (STRNCMP(lbuf, "!_TAG_", 6) <= 0) + { + /* + * Read header line. +--- 1797,1803 ---- + */ + if (state == TS_START) + { +! if (STRNCMP(lbuf, "!_TAG_", 6) == 0) + { + /* + * Read header line. +*** ../vim-7.3.659/src/version.c 2012-09-05 19:17:37.000000000 +0200 +--- src/version.c 2012-09-12 18:18:30.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 660, + /**/ + +-- +Q: How does a UNIX Guru pick up a girl? +A: look; grep; which; eval; nice; uname; talk; date; + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2d4727e894eed03a7ff97a662cec0e4dd7d725c4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:12 +0200 Subject: [PATCH 0496/3340] - patchlevel 661 --- 7.3.661 | 160 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 160 insertions(+) create mode 100644 7.3.661 diff --git a/7.3.661 b/7.3.661 new file mode 100644 index 00000000..3193e016 --- /dev/null +++ b/7.3.661 @@ -0,0 +1,160 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.661 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.661 (after 7.3.652) +Problem: SEGV in Python code. +Solution: Initialize len to zero. Use the right function depending on + version. (Maxim Philippov) +Files: src/if_py_both.h, src/if_python.c, src/if_python3.c + + +*** ../vim-7.3.660/src/if_py_both.h 2012-09-05 19:09:06.000000000 +0200 +--- src/if_py_both.h 2012-09-12 19:50:07.000000000 +0200 +*************** +*** 74,80 **** + static PyObject * + OutputWrite(PyObject *self, PyObject *args) + { +! Py_ssize_t len; + char *str = NULL; + int error = ((OutputObject *)(self))->error; + +--- 74,80 ---- + static PyObject * + OutputWrite(PyObject *self, PyObject *args) + { +! Py_ssize_t len = 0; + char *str = NULL; + int error = ((OutputObject *)(self))->error; + +*** ../vim-7.3.660/src/if_python.c 2012-09-05 19:03:51.000000000 +0200 +--- src/if_python.c 2012-09-12 19:52:10.000000000 +0200 +*************** +*** 44,51 **** + # undef _XOPEN_SOURCE /* pyconfig.h defines it as well. */ + #endif + +- #define PY_SSIZE_T_CLEAN +- + #include + #if defined(MACOS) && !defined(MACOS_X_UNIX) + # include "macglue.h" +--- 44,49 ---- +*************** +*** 54,59 **** +--- 52,61 ---- + #undef main /* Defined in python.h - aargh */ + #undef HAVE_FCNTL_H /* Clash with os_win32.h */ + ++ #if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02050000 ++ # define PY_SSIZE_T_CLEAN ++ #endif ++ + static void init_structs(void); + + #define PyBytes_FromString PyString_FromString +*************** +*** 358,365 **** +--- 360,374 ---- + PYTHON_PROC *ptr; + } python_funcname_table[] = + { ++ #ifndef PY_SSIZE_T_CLEAN + {"PyArg_Parse", (PYTHON_PROC*)&dll_PyArg_Parse}, + {"PyArg_ParseTuple", (PYTHON_PROC*)&dll_PyArg_ParseTuple}, ++ {"Py_BuildValue", (PYTHON_PROC*)&dll_Py_BuildValue}, ++ #else ++ {"_PyArg_Parse_SizeT", (PYTHON_PROC*)&dll_PyArg_Parse}, ++ {"_PyArg_ParseTuple_SizeT", (PYTHON_PROC*)&dll_PyArg_ParseTuple}, ++ {"_Py_BuildValue_SizeT", (PYTHON_PROC*)&dll_Py_BuildValue}, ++ #endif + {"PyMem_Free", (PYTHON_PROC*)&dll_PyMem_Free}, + {"PyMem_Malloc", (PYTHON_PROC*)&dll_PyMem_Malloc}, + {"PyDict_SetItemString", (PYTHON_PROC*)&dll_PyDict_SetItemString}, +*************** +*** 422,428 **** + {"PySys_SetArgv", (PYTHON_PROC*)&dll_PySys_SetArgv}, + {"PyType_Type", (PYTHON_PROC*)&dll_PyType_Type}, + {"PyType_Ready", (PYTHON_PROC*)&dll_PyType_Ready}, +- {"Py_BuildValue", (PYTHON_PROC*)&dll_Py_BuildValue}, + {"Py_FindMethod", (PYTHON_PROC*)&dll_Py_FindMethod}, + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02050000 \ + && SIZEOF_SIZE_T != SIZEOF_INT +--- 431,436 ---- +*** ../vim-7.3.660/src/if_python3.c 2012-09-05 19:09:06.000000000 +0200 +--- src/if_python3.c 2012-09-12 19:52:10.000000000 +0200 +*************** +*** 42,49 **** + # undef _DEBUG + #endif + +- #define PY_SSIZE_T_CLEAN +- + #ifdef F_BLANK + # undef F_BLANK + #endif +--- 42,47 ---- +*************** +*** 66,71 **** +--- 64,73 ---- + #undef main /* Defined in python.h - aargh */ + #undef HAVE_FCNTL_H /* Clash with os_win32.h */ + ++ #if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02050000 ++ # define PY_SSIZE_T_CLEAN ++ #endif ++ + static void init_structs(void); + + /* The "surrogateescape" error handler is new in Python 3.1 */ +*************** +*** 328,334 **** +--- 330,342 ---- + {"PySys_SetArgv", (PYTHON_PROC*)&py3_PySys_SetArgv}, + {"Py_SetPythonHome", (PYTHON_PROC*)&py3_Py_SetPythonHome}, + {"Py_Initialize", (PYTHON_PROC*)&py3_Py_Initialize}, ++ #ifndef PY_SSIZE_T_CLEAN + {"PyArg_ParseTuple", (PYTHON_PROC*)&py3_PyArg_ParseTuple}, ++ {"Py_BuildValue", (PYTHON_PROC*)&py3_Py_BuildValue}, ++ #else ++ {"_PyArg_ParseTuple_SizeT", (PYTHON_PROC*)&py3_PyArg_ParseTuple}, ++ {"_Py_BuildValue_SizeT", (PYTHON_PROC*)&py3_Py_BuildValue}, ++ #endif + {"PyMem_Free", (PYTHON_PROC*)&py3_PyMem_Free}, + {"PyMem_Malloc", (PYTHON_PROC*)&py3_PyMem_Malloc}, + {"PyList_New", (PYTHON_PROC*)&py3_PyList_New}, +*************** +*** 364,370 **** + {"PyObject_GetIter", (PYTHON_PROC*)&py3_PyObject_GetIter}, + {"PyLong_FromLong", (PYTHON_PROC*)&py3_PyLong_FromLong}, + {"PyDict_New", (PYTHON_PROC*)&py3_PyDict_New}, +- {"Py_BuildValue", (PYTHON_PROC*)&py3_Py_BuildValue}, + {"PyType_Ready", (PYTHON_PROC*)&py3_PyType_Ready}, + {"PyDict_SetItemString", (PYTHON_PROC*)&py3_PyDict_SetItemString}, + {"PyLong_AsLong", (PYTHON_PROC*)&py3_PyLong_AsLong}, +--- 372,377 ---- +*** ../vim-7.3.660/src/version.c 2012-09-12 18:19:39.000000000 +0200 +--- src/version.c 2012-09-12 19:53:52.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 661, + /**/ + +-- +Courtroom Quote #19: +Q: Doctor, how many autopsies have you performed on dead people? +A: All my autopsies have been performed on dead people. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2367c99d6fd6b90d4a91a2f6d9abf6d1bb03c1b3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:13 +0200 Subject: [PATCH 0497/3340] - patchlevel 662 --- 7.3.662 | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 7.3.662 diff --git a/7.3.662 b/7.3.662 new file mode 100644 index 00000000..609e0c5f --- /dev/null +++ b/7.3.662 @@ -0,0 +1,81 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.662 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.662 +Problem: Can't build Ruby interface with Ruby 1.9.3. +Solution: Add missing functions. (V. Ondruch) +Files: src/if_ruby.c + + +*** ../vim-7.3.661/src/if_ruby.c 2012-04-25 12:28:05.000000000 +0200 +--- src/if_ruby.c 2012-09-18 16:31:45.000000000 +0200 +*************** +*** 178,183 **** +--- 178,186 ---- + #define rb_hash_new dll_rb_hash_new + #define rb_inspect dll_rb_inspect + #define rb_int2inum dll_rb_int2inum ++ #define rb_fix2int dll_rb_fix2int ++ #define rb_num2int dll_rb_num2int ++ #define rb_num2uint dll_rb_num2uint + #define rb_lastline_get dll_rb_lastline_get + #define rb_lastline_set dll_rb_lastline_set + #define rb_load_protect dll_rb_load_protect +*************** +*** 268,274 **** + static VALUE (*dll_rb_hash_new) (void); + static VALUE (*dll_rb_inspect) (VALUE); + static VALUE (*dll_rb_int2inum) (long); +! static VALUE (*dll_rb_int2inum) (long); + static VALUE (*dll_rb_lastline_get) (void); + static void (*dll_rb_lastline_set) (VALUE); + static void (*dll_rb_load_protect) (VALUE, int, int*); +--- 271,279 ---- + static VALUE (*dll_rb_hash_new) (void); + static VALUE (*dll_rb_inspect) (VALUE); + static VALUE (*dll_rb_int2inum) (long); +! static long (*dll_rb_fix2int) (VALUE); +! static long (*dll_rb_num2int) (VALUE); +! static unsigned long (*dll_rb_num2uint) (VALUE); + static VALUE (*dll_rb_lastline_get) (void); + static void (*dll_rb_lastline_set) (VALUE); + static void (*dll_rb_load_protect) (VALUE, int, int*); +*************** +*** 377,382 **** +--- 382,390 ---- + {"rb_hash_new", (RUBY_PROC*)&dll_rb_hash_new}, + {"rb_inspect", (RUBY_PROC*)&dll_rb_inspect}, + {"rb_int2inum", (RUBY_PROC*)&dll_rb_int2inum}, ++ {"rb_fix2int", (RUBY_PROC*)&dll_rb_fix2int}, ++ {"rb_num2int", (RUBY_PROC*)&dll_rb_num2int}, ++ {"rb_num2uint", (RUBY_PROC*)&dll_rb_num2uint}, + {"rb_lastline_get", (RUBY_PROC*)&dll_rb_lastline_get}, + {"rb_lastline_set", (RUBY_PROC*)&dll_rb_lastline_set}, + {"rb_load_protect", (RUBY_PROC*)&dll_rb_load_protect}, +*** ../vim-7.3.661/src/version.c 2012-09-12 20:21:38.000000000 +0200 +--- src/version.c 2012-09-18 16:35:53.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 662, + /**/ + +-- +FATHER: We are here today to witness the union of two young people in the + joyful bond of the holy wedlock. Unfortunately, one of them, my son + Herbert, has just fallen to his death. + [Murmurs from CROWD; the BRIDE smiles with relief, coughs.] + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f01402f883613f72e0b8d84bb98e84a671548d10 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:14 +0200 Subject: [PATCH 0498/3340] - patchlevel 663 --- 7.3.663 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 7.3.663 diff --git a/7.3.663 b/7.3.663 new file mode 100644 index 00000000..a6154f48 --- /dev/null +++ b/7.3.663 @@ -0,0 +1,54 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.663 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.663 +Problem: End of color scheme name not clear in E185. (Aaron Lewis) +Solution: Put the name in single quotes. +Files: src/ex_docmd.c + + +*** ../vim-7.3.662/src/ex_docmd.c 2012-08-23 18:43:06.000000000 +0200 +--- src/ex_docmd.c 2012-09-14 20:49:29.000000000 +0200 +*************** +*** 6466,6472 **** + #endif + } + else if (load_colors(eap->arg) == FAIL) +! EMSG2(_("E185: Cannot find color scheme %s"), eap->arg); + } + + static void +--- 6466,6472 ---- + #endif + } + else if (load_colors(eap->arg) == FAIL) +! EMSG2(_("E185: Cannot find color scheme '%s'"), eap->arg); + } + + static void +*** ../vim-7.3.662/src/version.c 2012-09-18 16:36:26.000000000 +0200 +--- src/version.c 2012-09-18 16:44:57.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 663, + /**/ + +-- +Yesterday is history. +Tomorrow is a mystery. +Today is a gift. +That's why it is called 'present'. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3392e4c142565babe8743748c96fbaf36849ec67 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:15 +0200 Subject: [PATCH 0499/3340] - patchlevel 664 --- 7.3.664 | 78 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) create mode 100644 7.3.664 diff --git a/7.3.664 b/7.3.664 new file mode 100644 index 00000000..b83c3822 --- /dev/null +++ b/7.3.664 @@ -0,0 +1,78 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.664 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.664 +Problem: Buffer overflow in unescaping text. (Raymond Ko) +Solution: Limit check for multi-byte character to 4 bytes. +Files: src/mbyte.c + + +*** ../vim-7.3.663/src/mbyte.c 2012-06-01 17:46:52.000000000 +0200 +--- src/mbyte.c 2012-09-18 17:53:05.000000000 +0200 +*************** +*** 3793,3805 **** + mb_unescape(pp) + char_u **pp; + { +! static char_u buf[MB_MAXBYTES + 1]; +! int n, m = 0; + char_u *str = *pp; + + /* Must translate K_SPECIAL KS_SPECIAL KE_FILLER to K_SPECIAL and CSI +! * KS_EXTRA KE_CSI to CSI. */ +! for (n = 0; str[n] != NUL && m <= MB_MAXBYTES; ++n) + { + if (str[n] == K_SPECIAL + && str[n + 1] == KS_SPECIAL +--- 3793,3807 ---- + mb_unescape(pp) + char_u **pp; + { +! static char_u buf[6]; +! int n; +! int m = 0; + char_u *str = *pp; + + /* Must translate K_SPECIAL KS_SPECIAL KE_FILLER to K_SPECIAL and CSI +! * KS_EXTRA KE_CSI to CSI. +! * Maximum length of a utf-8 character is 4 bytes. */ +! for (n = 0; str[n] != NUL && m < 4; ++n) + { + if (str[n] == K_SPECIAL + && str[n + 1] == KS_SPECIAL +*************** +*** 3836,3841 **** +--- 3838,3847 ---- + *pp = str + n + 1; + return buf; + } ++ ++ /* Bail out quickly for ASCII. */ ++ if (buf[0] < 128) ++ break; + } + return NULL; + } +*** ../vim-7.3.663/src/version.c 2012-09-18 16:47:00.000000000 +0200 +--- src/version.c 2012-09-18 18:01:14.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 664, + /**/ + +-- +There are three kinds of people: Those who can count & those who can't. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 00b5f7694e8641411baa7369c6e4f7a8c3af334a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:17 +0200 Subject: [PATCH 0500/3340] - patchlevel 665 --- 7.3.665 | 80 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 7.3.665 diff --git a/7.3.665 b/7.3.665 new file mode 100644 index 00000000..2f6c30e0 --- /dev/null +++ b/7.3.665 @@ -0,0 +1,80 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.665 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.665 +Problem: MSVC 11 is not supported. +Solution: Recognize MSVC 11. (Raymond Ko) +Files: src/Make_mvc.mak + + +*** ../vim-7.3.664/src/Make_mvc.mak 2012-09-05 17:57:34.000000000 +0200 +--- src/Make_mvc.mak 2012-09-18 18:24:48.000000000 +0200 +*************** +*** 395,400 **** +--- 395,403 ---- + !if "$(_NMAKE_VER)" == "10.00.30319.01" + MSVCVER = 10.0 + !endif ++ !if "$(_NMAKE_VER)" == "11.00.50727.1" ++ MSVCVER = 11.0 ++ !endif + !endif + + # Abort bulding VIM if version of VC is unrecognised. +*************** +*** 409,415 **** + !endif + + # Convert processor ID to MVC-compatible number +! !if ("$(MSVCVER)" != "8.0") && ("$(MSVCVER)" != "9.0") && ("$(MSVCVER)" != "10.0") + !if "$(CPUNR)" == "i386" + CPUARG = /G3 + !elseif "$(CPUNR)" == "i486" +--- 412,418 ---- + !endif + + # Convert processor ID to MVC-compatible number +! !if ("$(MSVCVER)" != "8.0") && ("$(MSVCVER)" != "9.0") && ("$(MSVCVER)" != "10.0") && ("$(MSVCVER)" != "11.0") + !if "$(CPUNR)" == "i386" + CPUARG = /G3 + !elseif "$(CPUNR)" == "i486" +*************** +*** 443,449 **** + OPTFLAG = /Ox + !endif + +! !if ("$(MSVCVER)" == "8.0") || ("$(MSVCVER)" == "9.0") || ("$(MSVCVER)" == "10.0") + # Use link time code generation if not worried about size + !if "$(OPTIMIZE)" != "SPACE" + OPTFLAG = $(OPTFLAG) /GL +--- 446,452 ---- + OPTFLAG = /Ox + !endif + +! !if ("$(MSVCVER)" == "8.0") || ("$(MSVCVER)" == "9.0") || ("$(MSVCVER)" == "10.0") || ("$(MSVCVER)" == "11.0") + # Use link time code generation if not worried about size + !if "$(OPTIMIZE)" != "SPACE" + OPTFLAG = $(OPTFLAG) /GL +*** ../vim-7.3.664/src/version.c 2012-09-18 18:03:33.000000000 +0200 +--- src/version.c 2012-09-18 18:26:16.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 665, + /**/ + +-- +There are 10 kinds of people: Those who understand binary and those who don't. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c20a119355848384b48af2cced5eee5edcb207ba Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:18 +0200 Subject: [PATCH 0501/3340] - patchlevel 666 --- 7.3.666 | 95 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 95 insertions(+) create mode 100644 7.3.666 diff --git a/7.3.666 b/7.3.666 new file mode 100644 index 00000000..42900d18 --- /dev/null +++ b/7.3.666 @@ -0,0 +1,95 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.6 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.666 +Problem: With MSVC 11 Win32.mak is not found. +Solution: Add the SDK_INCLUDE_DIR variable. (Raymond Ko) +Files: src/Make_mvc.mak + + +*** ../vim-7.3.665/src/Make_mvc.mak 2012-09-18 18:27:07.000000000 +0200 +--- src/Make_mvc.mak 2012-09-18 21:58:09.000000000 +0200 +*************** +*** 1,7 **** + # Makefile for Vim on Win32 (Windows NT/2000/XP/2003 and Windows 95/98/Me) + # and Win64, using the Microsoft Visual C++ compilers. Known to work with + # VC5, VC6 (VS98), VC7.0 (VS2002), VC7.1 (VS2003), VC8 (VS2005), +! # VC9 (VS2008), and VC10 (VS2010). + # + # To build using other Windows compilers, see INSTALLpc.txt + # +--- 1,7 ---- + # Makefile for Vim on Win32 (Windows NT/2000/XP/2003 and Windows 95/98/Me) + # and Win64, using the Microsoft Visual C++ compilers. Known to work with + # VC5, VC6 (VS98), VC7.0 (VS2002), VC7.1 (VS2003), VC8 (VS2005), +! # VC9 (VS2008), VC10 (VS2010) and VC11 (VS2012) + # + # To build using other Windows compilers, see INSTALLpc.txt + # +*************** +*** 15,20 **** +--- 15,23 ---- + # This will build the console version of Vim with no additional interfaces. + # To add features, define any of the following: + # ++ # For MSVC 11 you need to specify where the Win32.mak file is, e.g.: ++ # SDK_INCLUDE_DIR="C:\Program Files\Microsoft SDKs\Windows\v7.1\Include" ++ # + # !!!! After changing features do "nmake clean" first !!!! + # + # Feature Set: FEATURES=[TINY, SMALL, NORMAL, BIG, HUGE] (default is BIG) +*************** +*** 227,233 **** +--- 230,241 ---- + + # Get all sorts of useful, standard macros from the Platform SDK. + ++ !ifdef SDK_INCLUDE_DIR ++ !include $(SDK_INCLUDE_DIR)\Win32.mak ++ !else + !include ++ !endif ++ + + # Flag to turn on Win64 compatibility warnings for VC7.x and VC8. + WP64CHECK = /Wp64 +*************** +*** 911,917 **** + + # Report link time code generation progress if used. + !ifdef NODEBUG +! !if ("$(MSVCVER)" == "8.0") || ("$(MSVCVER)" == "9.0") || ("$(MSVCVER)" == "10.0") + !if "$(OPTIMIZE)" != "SPACE" + LINKARGS1 = $(LINKARGS1) /LTCG:STATUS + !endif +--- 919,925 ---- + + # Report link time code generation progress if used. + !ifdef NODEBUG +! !if ("$(MSVCVER)" == "8.0") || ("$(MSVCVER)" == "9.0") || ("$(MSVCVER)" == "10.0") || ("$(MSVCVER)" == "11.0") + !if "$(OPTIMIZE)" != "SPACE" + LINKARGS1 = $(LINKARGS1) /LTCG:STATUS + !endif +*** ../vim-7.3.665/src/version.c 2012-09-18 18:27:07.000000000 +0200 +--- src/version.c 2012-09-18 21:58:44.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 666, + /**/ + +-- +Be nice to your kids... they'll be the ones choosing your nursing home. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a5914e45ed30d969bc82d3c9ebd599fb8e0eb68d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:19 +0200 Subject: [PATCH 0502/3340] - patchlevel 667 --- 7.3.667 | 86 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 7.3.667 diff --git a/7.3.667 b/7.3.667 new file mode 100644 index 00000000..3f9f0247 --- /dev/null +++ b/7.3.667 @@ -0,0 +1,86 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.667 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.667 +Problem: Unused variables in Perl interface. +Solution: Adjust #ifdefs. +Files: src/if_perl.xs + + +*** ../vim-7.3.666/src/if_perl.xs 2012-08-08 13:17:26.000000000 +0200 +--- src/if_perl.xs 2012-09-21 12:39:29.000000000 +0200 +*************** +*** 315,320 **** +--- 315,323 ---- + static void (*Perl_sv_free2)(pTHX_ SV*); + static void (*Perl_sys_init)(int* argc, char*** argv); + static void (*Perl_sys_term)(void); ++ static void (*Perl_call_list)(pTHX_ I32, AV*); ++ # if (PERL_REVISION == 5) && (PERL_VERSION >= 14) ++ # else + static SV** (*Perl_ISv_ptr)(register PerlInterpreter*); + static SV*** (*Perl_Istack_max_ptr)(register PerlInterpreter*); + static SV*** (*Perl_Istack_base_ptr)(register PerlInterpreter*); +*************** +*** 326,341 **** + static I32** (*Perl_Imarkstack_max_ptr)(register PerlInterpreter*); + static SV*** (*Perl_Istack_sp_ptr)(register PerlInterpreter*); + static OP** (*Perl_Iop_ptr)(register PerlInterpreter*); +- static void (*Perl_call_list)(pTHX_ I32, AV*); + static I32* (*Perl_Iscopestack_ix_ptr)(register PerlInterpreter*); + static AV** (*Perl_Iunitcheckav_ptr)(register PerlInterpreter*); + #endif + + static GV** (*Perl_Idefgv_ptr)(register PerlInterpreter*); + static GV** (*Perl_Ierrgv_ptr)(register PerlInterpreter*); + static SV* (*Perl_Isv_yes_ptr)(register PerlInterpreter*); +- static void (*boot_DynaLoader)_((pTHX_ CV*)); + static perl_key* (*Perl_Gthr_key_ptr)_((pTHX)); + + /* + * Table of name to function pointer of perl. +--- 329,347 ---- + static I32** (*Perl_Imarkstack_max_ptr)(register PerlInterpreter*); + static SV*** (*Perl_Istack_sp_ptr)(register PerlInterpreter*); + static OP** (*Perl_Iop_ptr)(register PerlInterpreter*); + static I32* (*Perl_Iscopestack_ix_ptr)(register PerlInterpreter*); + static AV** (*Perl_Iunitcheckav_ptr)(register PerlInterpreter*); ++ # endif + #endif + ++ #if (PERL_REVISION == 5) && (PERL_VERSION >= 14) ++ #else + static GV** (*Perl_Idefgv_ptr)(register PerlInterpreter*); + static GV** (*Perl_Ierrgv_ptr)(register PerlInterpreter*); + static SV* (*Perl_Isv_yes_ptr)(register PerlInterpreter*); + static perl_key* (*Perl_Gthr_key_ptr)_((pTHX)); ++ #endif ++ static void (*boot_DynaLoader)_((pTHX_ CV*)); + + /* + * Table of name to function pointer of perl. +*** ../vim-7.3.666/src/version.c 2012-09-18 22:00:02.000000000 +0200 +--- src/version.c 2012-09-21 12:40:57.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 667, + /**/ + +-- +Two cows are standing together in a field. One asks the other: +"So what do you think about this Mad Cow Disease?" +The other replies: "That doesn't concern me. I'm a helicopter." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0b5d9f76928dbd2bd1ceaa8487ee3f679b040aa3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:21 +0200 Subject: [PATCH 0503/3340] - patchlevel 668 --- 7.3.668 | 84 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 7.3.668 diff --git a/7.3.668 b/7.3.668 new file mode 100644 index 00000000..4ddf2063 --- /dev/null +++ b/7.3.668 @@ -0,0 +1,84 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.668 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.668 +Problem: Building with Perl loaded dynamically still uses static library. +Solution: Adjust use of PL_thr_key. (Ken Takata) +Files: src/if_perl.xs + + +*** ../vim-7.3.667/src/if_perl.xs 2012-09-21 12:42:38.000000000 +0200 +--- src/if_perl.xs 2012-09-21 12:47:55.000000000 +0200 +*************** +*** 155,161 **** + # define Perl_set_context dll_Perl_set_context + # if (PERL_REVISION == 5) && (PERL_VERSION >= 14) + # define Perl_sv_2bool_flags dll_Perl_sv_2bool_flags +! # define Perl_xs_apiversion_bootcheck dll_Perl_xs_apiversion_bootcheck + # else + # define Perl_sv_2bool dll_Perl_sv_2bool + # endif +--- 155,161 ---- + # define Perl_set_context dll_Perl_set_context + # if (PERL_REVISION == 5) && (PERL_VERSION >= 14) + # define Perl_sv_2bool_flags dll_Perl_sv_2bool_flags +! # define Perl_xs_apiversion_bootcheck dll_Perl_xs_apiversion_bootcheck + # else + # define Perl_sv_2bool dll_Perl_sv_2bool + # endif +*************** +*** 225,230 **** +--- 225,233 ---- + # define Perl_call_list dll_Perl_call_list + # define Perl_Iscopestack_ix_ptr dll_Perl_Iscopestack_ix_ptr + # define Perl_Iunitcheckav_ptr dll_Perl_Iunitcheckav_ptr ++ # if (PERL_REVISION == 5) && (PERL_VERSION >= 14) ++ # define PL_thr_key *dll_PL_thr_key ++ # endif + + /* + * Declare HANDLE for perl.dll and function pointers. +*************** +*** 335,340 **** +--- 338,344 ---- + #endif + + #if (PERL_REVISION == 5) && (PERL_VERSION >= 14) ++ static perl_key* dll_PL_thr_key; + #else + static GV** (*Perl_Idefgv_ptr)(register PerlInterpreter*); + static GV** (*Perl_Ierrgv_ptr)(register PerlInterpreter*); +*************** +*** 453,458 **** +--- 457,463 ---- + # endif + #endif + #if (PERL_REVISION == 5) && (PERL_VERSION >= 14) ++ {"PL_thr_key", (PERL_PROC*)&dll_PL_thr_key}, + #else + {"Perl_Idefgv_ptr", (PERL_PROC*)&Perl_Idefgv_ptr}, + {"Perl_Ierrgv_ptr", (PERL_PROC*)&Perl_Ierrgv_ptr}, +*** ../vim-7.3.667/src/version.c 2012-09-21 12:42:38.000000000 +0200 +--- src/version.c 2012-09-21 12:49:06.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 668, + /**/ + +-- +Michael: There is no such thing as a dump question. +Bernard: Sure there is. For example "what is a core dump?" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0125f497fe89fc4308d0b81343a083c636edb525 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:22 +0200 Subject: [PATCH 0504/3340] - patchlevel 669 --- 7.3.669 | 128 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 128 insertions(+) create mode 100644 7.3.669 diff --git a/7.3.669 b/7.3.669 new file mode 100644 index 00000000..7fb19402 --- /dev/null +++ b/7.3.669 @@ -0,0 +1,128 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.669 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.669 +Problem: When building with Cygwin loading Python dynamically fails. +Solution: Use DLLLIBRARY instead of INSTSONAME. (Ken Takata) +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.668/src/configure.in 2012-08-15 14:04:50.000000000 +0200 +--- src/configure.in 2012-09-21 12:52:32.000000000 +0200 +*************** +*** 889,894 **** +--- 889,895 ---- + @echo "python_LIBS='$(LIBS)'" + @echo "python_SYSLIBS='$(SYSLIBS)'" + @echo "python_LINKFORSHARED='$(LINKFORSHARED)'" ++ @echo "python_DLLLIBRARY='$(DLLLIBRARY)'" + @echo "python_INSTSONAME='$(INSTSONAME)'" + eof + dnl -- delete the lines from make about Entering/Leaving directory +*************** +*** 909,914 **** +--- 910,918 ---- + fi + ]) + ++ if test "X$python_DLLLIBRARY" != "X"; then ++ python_INSTSONAME="$python_DLLLIBRARY" ++ fi + PYTHON_LIBS="${vi_cv_path_python_plibs}" + if test "${vi_cv_path_python_pfx}" = "${vi_cv_path_python_epfx}"; then + PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\"" +*************** +*** 1082,1087 **** +--- 1086,1092 ---- + @echo "python3_BASEMODLIBS='$(BASEMODLIBS)'" + @echo "python3_LIBS='$(LIBS)'" + @echo "python3_SYSLIBS='$(SYSLIBS)'" ++ @echo "python3_DLLLIBRARY='$(DLLLIBRARY)'" + @echo "python3_INSTSONAME='$(INSTSONAME)'" + eof + dnl -- delete the lines from make about Entering/Leaving directory +*************** +*** 1094,1099 **** +--- 1099,1107 ---- + vi_cv_path_python3_plibs=`echo $vi_cv_path_python3_plibs | sed s/-lffi//` + ]) + ++ if test "X$python3_DLLLIBRARY" != "X"; then ++ python3_INSTSONAME="$python3_DLLLIBRARY" ++ fi + PYTHON3_LIBS="${vi_cv_path_python3_plibs}" + if test "${vi_cv_path_python3_pfx}" = "${vi_cv_path_python3_epfx}"; then + PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" +*** ../vim-7.3.668/src/auto/configure 2012-08-15 14:04:50.000000000 +0200 +--- src/auto/configure 2012-09-21 13:06:09.000000000 +0200 +*************** +*** 5330,5335 **** +--- 5330,5336 ---- + @echo "python_LIBS='$(LIBS)'" + @echo "python_SYSLIBS='$(SYSLIBS)'" + @echo "python_LINKFORSHARED='$(LINKFORSHARED)'" ++ @echo "python_DLLLIBRARY='$(DLLLIBRARY)'" + @echo "python_INSTSONAME='$(INSTSONAME)'" + eof + eval "`cd ${PYTHON_CONFDIR} && make -f "${tmp_mkf}" __ | sed '/ directory /d'`" +*************** +*** 5350,5355 **** +--- 5351,5359 ---- + fi + + ++ if test "X$python_DLLLIBRARY" != "X"; then ++ python_INSTSONAME="$python_DLLLIBRARY" ++ fi + PYTHON_LIBS="${vi_cv_path_python_plibs}" + if test "${vi_cv_path_python_pfx}" = "${vi_cv_path_python_epfx}"; then + PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\"" +*************** +*** 5633,5638 **** +--- 5637,5643 ---- + @echo "python3_BASEMODLIBS='$(BASEMODLIBS)'" + @echo "python3_LIBS='$(LIBS)'" + @echo "python3_SYSLIBS='$(SYSLIBS)'" ++ @echo "python3_DLLLIBRARY='$(DLLLIBRARY)'" + @echo "python3_INSTSONAME='$(INSTSONAME)'" + eof + eval "`cd ${PYTHON3_CONFDIR} && make -f "${tmp_mkf}" __ | sed '/ directory /d'`" +*************** +*** 5645,5650 **** +--- 5650,5658 ---- + fi + + ++ if test "X$python3_DLLLIBRARY" != "X"; then ++ python3_INSTSONAME="$python3_DLLLIBRARY" ++ fi + PYTHON3_LIBS="${vi_cv_path_python3_plibs}" + if test "${vi_cv_path_python3_pfx}" = "${vi_cv_path_python3_epfx}"; then + PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" +*** ../vim-7.3.668/src/version.c 2012-09-21 12:50:44.000000000 +0200 +--- src/version.c 2012-09-21 12:54:42.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 669, + /**/ + +-- +TALL KNIGHT: We are now no longer the Knights Who Say Ni! +ONE KNIGHT: Ni! +OTHERS: Sh! +ONE KNIGHT: (whispers) Sorry. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c76da71ee900ba9698a1cca4e84b05338843abf0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:23 +0200 Subject: [PATCH 0505/3340] - patchlevel 670 --- 7.3.670 | 88 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 88 insertions(+) create mode 100644 7.3.670 diff --git a/7.3.670 b/7.3.670 new file mode 100644 index 00000000..91b4caa9 --- /dev/null +++ b/7.3.670 @@ -0,0 +1,88 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.670 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.670 +Problem: Python: memory leaks when there are exceptions. +Solution: Add DICTKEY_UNREF in the right places. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.669/src/if_py_both.h 2012-09-12 20:21:38.000000000 +0200 +--- src/if_py_both.h 2012-09-21 13:32:13.000000000 +0200 +*************** +*** 799,812 **** + + di = dict_find(((DictionaryObject *) (self))->dict, key, -1); + + if (di == NULL) + { + PyErr_SetString(PyExc_IndexError, _("no such key in dictionary")); + return NULL; + } + +- DICTKEY_UNREF +- + return ConvertToPyObject(&di->di_tv); + } + +--- 799,812 ---- + + di = dict_find(((DictionaryObject *) (self))->dict, key, -1); + ++ DICTKEY_UNREF ++ + if (di == NULL) + { + PyErr_SetString(PyExc_IndexError, _("no such key in dictionary")); + return NULL; + } + + return ConvertToPyObject(&di->di_tv); + } + +*************** +*** 835,840 **** +--- 835,841 ---- + + if (di == NULL) + { ++ DICTKEY_UNREF + PyErr_SetString(PyExc_IndexError, _("no such key in dictionary")); + return -1; + } +*************** +*** 859,864 **** +--- 860,866 ---- + + if (dict_add(d, di) == FAIL) + { ++ DICTKEY_UNREF + vim_free(di); + PyErr_SetVim(_("failed to add key to dictionary")); + return -1; +*** ../vim-7.3.669/src/version.c 2012-09-21 13:26:44.000000000 +0200 +--- src/version.c 2012-09-21 13:42:43.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 670, + /**/ + +-- +TALL KNIGHT: Firstly. You must get us another shrubbery! +OTHER KNIGHTS: More shrubberies! More shrubberies for the ex-Knights of Ni! +ARTHUR: Not another shrubbery - + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 62c2fb821acac642f45ecb141d694a2add3052ad Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:24 +0200 Subject: [PATCH 0506/3340] - patchlevel 671 --- 7.3.671 | 311 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 311 insertions(+) create mode 100644 7.3.671 diff --git a/7.3.671 b/7.3.671 new file mode 100644 index 00000000..c47e6f33 --- /dev/null +++ b/7.3.671 @@ -0,0 +1,311 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.671 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.671 +Problem: More Python code can be shared between Python 2 and 3. +Solution: Move code to if_py_both.h. (ZyX) +Files: src/if_py_both.h, src/if_python.c, src/if_python3.c + + +*** ../vim-7.3.670/src/if_py_both.h 2012-09-21 13:43:09.000000000 +0200 +--- src/if_py_both.h 2012-09-21 13:45:02.000000000 +0200 +*************** +*** 71,76 **** +--- 71,101 ---- + /* Output buffer management + */ + ++ static int ++ OutputSetattr(PyObject *self, char *name, PyObject *val) ++ { ++ if (val == NULL) ++ { ++ PyErr_SetString(PyExc_AttributeError, _("can't delete OutputObject attributes")); ++ return -1; ++ } ++ ++ if (strcmp(name, "softspace") == 0) ++ { ++ if (!PyInt_Check(val)) ++ { ++ PyErr_SetString(PyExc_TypeError, _("softspace must be an integer")); ++ return -1; ++ } ++ ++ ((OutputObject *)(self))->softspace = PyInt_AsLong(val); ++ return 0; ++ } ++ ++ PyErr_SetString(PyExc_AttributeError, _("invalid attribute")); ++ return -1; ++ } ++ + static PyObject * + OutputWrite(PyObject *self, PyObject *args) + { +*** ../vim-7.3.670/src/if_python.c 2012-09-12 20:21:38.000000000 +0200 +--- src/if_python.c 2012-09-21 13:45:02.000000000 +0200 +*************** +*** 951,981 **** + return Py_FindMethod(OutputMethods, self, name); + } + +- static int +- OutputSetattr(PyObject *self, char *name, PyObject *val) +- { +- if (val == NULL) +- { +- PyErr_SetString(PyExc_AttributeError, _("can't delete OutputObject attributes")); +- return -1; +- } +- +- if (strcmp(name, "softspace") == 0) +- { +- if (!PyInt_Check(val)) +- { +- PyErr_SetString(PyExc_TypeError, _("softspace must be an integer")); +- return -1; +- } +- +- ((OutputObject *)(self))->softspace = PyInt_AsLong(val); +- return 0; +- } +- +- PyErr_SetString(PyExc_AttributeError, _("invalid attribute")); +- return -1; +- } +- + /***************/ + + static int +--- 951,956 ---- +*** ../vim-7.3.670/src/if_python3.c 2012-09-12 20:21:38.000000000 +0200 +--- src/if_python3.c 2012-09-21 13:45:02.000000000 +0200 +*************** +*** 88,93 **** +--- 88,96 ---- + #define PyString_Size(obj) PyBytes_GET_SIZE(bytes) + #define PyString_FromString(repr) PyUnicode_FromString(repr) + #define PyString_AsStringAndSize(obj, buffer, len) PyBytes_AsStringAndSize(obj, buffer, len) ++ #define PyInt_Check(obj) PyLong_Check(obj) ++ #define PyInt_FromLong(i) PyLong_FromLong(i) ++ #define PyInt_AsLong(obj) PyLong_AsLong(obj) + + #if defined(DYNAMIC_PYTHON3) || defined(PROTO) + +*************** +*** 586,591 **** +--- 589,599 ---- + */ + #include "if_py_both.h" + ++ #define GET_ATTR_STRING(name, nameobj) \ ++ char *name = ""; \ ++ if(PyUnicode_Check(nameobj)) \ ++ name = _PyUnicode_AsString(nameobj) ++ + #define PY3OBJ_DELETED(obj) (obj->ob_base.ob_refcnt<=0) + + static void +*************** +*** 923,931 **** + static PyObject * + OutputGetattro(PyObject *self, PyObject *nameobj) + { +! char *name = ""; +! if (PyUnicode_Check(nameobj)) +! name = _PyUnicode_AsString(nameobj); + + if (strcmp(name, "softspace") == 0) + return PyLong_FromLong(((OutputObject *)(self))->softspace); +--- 931,937 ---- + static PyObject * + OutputGetattro(PyObject *self, PyObject *nameobj) + { +! GET_ATTR_STRING(name, nameobj); + + if (strcmp(name, "softspace") == 0) + return PyLong_FromLong(((OutputObject *)(self))->softspace); +*************** +*** 936,965 **** + static int + OutputSetattro(PyObject *self, PyObject *nameobj, PyObject *val) + { +! char *name = ""; +! if (PyUnicode_Check(nameobj)) +! name = _PyUnicode_AsString(nameobj); +! +! if (val == NULL) +! { +! PyErr_SetString(PyExc_AttributeError, _("can't delete OutputObject attributes")); +! return -1; +! } + +! if (strcmp(name, "softspace") == 0) +! { +! if (!PyLong_Check(val)) +! { +! PyErr_SetString(PyExc_TypeError, _("softspace must be an integer")); +! return -1; +! } +! +! ((OutputObject *)(self))->softspace = PyLong_AsLong(val); +! return 0; +! } +! +! PyErr_SetString(PyExc_AttributeError, _("invalid attribute")); +! return -1; + } + + /***************/ +--- 942,950 ---- + static int + OutputSetattro(PyObject *self, PyObject *nameobj, PyObject *val) + { +! GET_ATTR_STRING(name, nameobj); + +! return OutputSetattr(self, name, val); + } + + /***************/ +*************** +*** 1091,1099 **** + { + BufferObject *this = (BufferObject *)(self); + +! char *name = ""; +! if (PyUnicode_Check(nameobj)) +! name = _PyUnicode_AsString(nameobj); + + if (CheckBuffer(this)) + return NULL; +--- 1076,1082 ---- + { + BufferObject *this = (BufferObject *)(self); + +! GET_ATTR_STRING(name, nameobj); + + if (CheckBuffer(this)) + return NULL; +*************** +*** 1257,1265 **** + static PyObject * + RangeGetattro(PyObject *self, PyObject *nameobj) + { +! char *name = ""; +! if (PyUnicode_Check(nameobj)) +! name = _PyUnicode_AsString(nameobj); + + if (strcmp(name, "start") == 0) + return Py_BuildValue("n", ((RangeObject *)(self))->start - 1); +--- 1240,1246 ---- + static PyObject * + RangeGetattro(PyObject *self, PyObject *nameobj) + { +! GET_ATTR_STRING(name, nameobj); + + if (strcmp(name, "start") == 0) + return Py_BuildValue("n", ((RangeObject *)(self))->start - 1); +*************** +*** 1430,1439 **** + { + WindowObject *this = (WindowObject *)(self); + +! char *name = ""; +! if (PyUnicode_Check(nameobj)) +! name = _PyUnicode_AsString(nameobj); +! + + if (CheckWindow(this)) + return NULL; +--- 1411,1417 ---- + { + WindowObject *this = (WindowObject *)(self); + +! GET_ATTR_STRING(name, nameobj); + + if (CheckWindow(this)) + return NULL; +*************** +*** 1461,1470 **** + static int + WindowSetattro(PyObject *self, PyObject *nameobj, PyObject *val) + { +! char *name = ""; +! +! if (PyUnicode_Check(nameobj)) +! name = _PyUnicode_AsString(nameobj); + + return WindowSetattr(self, name, val); + } +--- 1439,1445 ---- + static int + WindowSetattro(PyObject *self, PyObject *nameobj, PyObject *val) + { +! GET_ATTR_STRING(name, nameobj); + + return WindowSetattr(self, name, val); + } +*************** +*** 1508,1516 **** + static PyObject * + CurrentGetattro(PyObject *self UNUSED, PyObject *nameobj) + { +! char *name = ""; +! if (PyUnicode_Check(nameobj)) +! name = _PyUnicode_AsString(nameobj); + + if (strcmp(name, "buffer") == 0) + return (PyObject *)BufferNew(curbuf); +--- 1483,1489 ---- + static PyObject * + CurrentGetattro(PyObject *self UNUSED, PyObject *nameobj) + { +! GET_ATTR_STRING(name, nameobj); + + if (strcmp(name, "buffer") == 0) + return (PyObject *)BufferNew(curbuf); +*************** +*** 1681,1689 **** + FunctionGetattro(PyObject *self, PyObject *nameobj) + { + FunctionObject *this = (FunctionObject *)(self); +! char *name = ""; +! if (PyUnicode_Check(nameobj)) +! name = _PyUnicode_AsString(nameobj); + + if (strcmp(name, "name") == 0) + return PyUnicode_FromString((char *)(this->name)); +--- 1654,1661 ---- + FunctionGetattro(PyObject *self, PyObject *nameobj) + { + FunctionObject *this = (FunctionObject *)(self); +! +! GET_ATTR_STRING(name, nameobj); + + if (strcmp(name, "name") == 0) + return PyUnicode_FromString((char *)(this->name)); +*** ../vim-7.3.670/src/version.c 2012-09-21 13:43:09.000000000 +0200 +--- src/version.c 2012-09-21 13:45:28.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 671, + /**/ + +-- +The war between Emacs and Vi is over. Vi has won with 3 to 1. + http://www.ssc.com/lg/issue30/raymond.html + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8b653467651852339d9a58421a7c8bc8eca1c6b1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:26 +0200 Subject: [PATCH 0507/3340] - patchlevel 672 --- 7.3.672 | 699 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 699 insertions(+) create mode 100644 7.3.672 diff --git a/7.3.672 b/7.3.672 new file mode 100644 index 00000000..b43b0f15 --- /dev/null +++ b/7.3.672 @@ -0,0 +1,699 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.672 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.672 +Problem: Not possible to lock/unlock lists in Python interface. +Solution: Add .locked and .scope attributes. (ZyX) +Files: runtime/doc/if_pyth.txt, src/if_py_both.h, src/if_python.c, + src/if_python3.c, src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.671/runtime/doc/if_pyth.txt 2012-06-29 12:54:32.000000000 +0200 +--- runtime/doc/if_pyth.txt 2012-09-21 13:49:14.000000000 +0200 +*************** +*** 27,33 **** + + *:python* *:py* *E205* *E263* *E264* + :[range]py[thon] {stmt} +! Execute Python statement {stmt}. + + :[range]py[thon] << {endmarker} + {script} +--- 27,35 ---- + + *:python* *:py* *E205* *E263* *E264* + :[range]py[thon] {stmt} +! Execute Python statement {stmt}. A simple check if +! the `:python` command is working: > +! :python print "Hello" + + :[range]py[thon] << {endmarker} + {script} +*************** +*** 157,162 **** +--- 159,184 ---- + vimlist or vimdictionary python type that are connected to original + list or dictionary. Thus modifications to these objects imply + modifications of the original. ++ ++ Additionally, vimlist and vimdictionary type have read-write ++ `.locked` attribute that returns ++ Value Meaning ~ ++ zero Variable is not locked ++ vim.VAR_LOCKED Variable is locked, but can be unlocked ++ vim.VAR_FIXED Variable is locked and can’t be unlocked ++ integer constants. If variable is not fixed, you can do ++ `var.locked=True` to lock it and `var.locked=False` to unlock. ++ There is no recursive locking like |:lockvar|! does. There is also ++ no way to lock a specific key or check whether it is locked (in any ++ case these locks are ignored by anything except |:let|: |extend()| ++ does not care, neither does python interface). ++ ++ Vimdictionary type also supports `.scope` attribute which is one of ++ Value Meaning ~ ++ zero Dictionary is not a scope one ++ vim.VAR_DEF_SCOPE Function-local or global scope dictionary ++ vim.VAR_SCOPE Other scope dictionary ++ + 2. if expression evaluates to a function reference, then it returns + callable vimfunction object. Use self keyword argument to assign + |self| object for dictionary functions. +*************** +*** 362,369 **** + 8. Python 3 *python3* + + *:py3* *:python3* +! The |:py3| and |:python3| commands work similar to |:python|. +! *:py3file* + The |:py3file| command works similar to |:pyfile|. + + +--- 384,393 ---- + 8. Python 3 *python3* + + *:py3* *:python3* +! The |:py3| and |:python3| commands work similar to |:python|. A simple check +! if the `:py3` command is wrong: > +! :py3 print("Hello") +! < *:py3file* + The |:py3file| command works similar to |:pyfile|. + + +*** ../vim-7.3.671/src/if_py_both.h 2012-09-21 13:45:57.000000000 +0200 +--- src/if_py_both.h 2012-09-21 13:49:14.000000000 +0200 +*************** +*** 808,813 **** +--- 808,851 ---- + } + + static PyInt ++ DictionarySetattr(DictionaryObject *self, char *name, PyObject *val) ++ { ++ if (val == NULL) ++ { ++ PyErr_SetString(PyExc_AttributeError, _("Cannot delete DictionaryObject attributes")); ++ return -1; ++ } ++ ++ if (strcmp(name, "locked") == 0) ++ { ++ if (self->dict->dv_lock == VAR_FIXED) ++ { ++ PyErr_SetString(PyExc_TypeError, _("Cannot modify fixed dictionary")); ++ return -1; ++ } ++ else ++ { ++ if (!PyBool_Check(val)) ++ { ++ PyErr_SetString(PyExc_TypeError, _("Only boolean objects are allowed")); ++ return -1; ++ } ++ ++ if (val == Py_True) ++ self->dict->dv_lock = VAR_LOCKED; ++ else ++ self->dict->dv_lock = 0; ++ } ++ return 0; ++ } ++ else ++ { ++ PyErr_SetString(PyExc_AttributeError, _("Cannot set this attribute")); ++ return -1; ++ } ++ } ++ ++ static PyInt + DictionaryLength(PyObject *self) + { + return ((PyInt) ((((DictionaryObject *)(self))->dict->dv_hashtab.ht_used))); +*************** +*** 1271,1276 **** +--- 1309,1352 ---- + return self; + } + ++ static int ++ ListSetattr(ListObject *self, char *name, PyObject *val) ++ { ++ if (val == NULL) ++ { ++ PyErr_SetString(PyExc_AttributeError, _("Cannot delete DictionaryObject attributes")); ++ return -1; ++ } ++ ++ if (strcmp(name, "locked") == 0) ++ { ++ if (self->list->lv_lock == VAR_FIXED) ++ { ++ PyErr_SetString(PyExc_TypeError, _("Cannot modify fixed list")); ++ return -1; ++ } ++ else ++ { ++ if (!PyBool_Check(val)) ++ { ++ PyErr_SetString(PyExc_TypeError, _("Only boolean objects are allowed")); ++ return -1; ++ } ++ ++ if (val == Py_True) ++ self->list->lv_lock = VAR_LOCKED; ++ else ++ self->list->lv_lock = 0; ++ } ++ return 0; ++ } ++ else ++ { ++ PyErr_SetString(PyExc_AttributeError, _("Cannot set this attribute")); ++ return -1; ++ } ++ } ++ + static struct PyMethodDef ListMethods[] = { + {"extend", (PyCFunction)ListConcatInPlace, METH_O, ""}, + { NULL, NULL, 0, NULL } +*** ../vim-7.3.671/src/if_python.c 2012-09-21 13:45:57.000000000 +0200 +--- src/if_python.c 2012-09-21 13:49:14.000000000 +0200 +*************** +*** 163,168 **** +--- 163,169 ---- + # define PyInt_FromLong dll_PyInt_FromLong + # define PyLong_AsLong dll_PyLong_AsLong + # define PyLong_FromLong dll_PyLong_FromLong ++ # define PyBool_Type (*dll_PyBool_Type) + # define PyInt_Type (*dll_PyInt_Type) + # define PyLong_Type (*dll_PyLong_Type) + # define PyList_GetItem dll_PyList_GetItem +*************** +*** 221,226 **** +--- 222,229 ---- + # define _PyObject_NextNotImplemented (*dll__PyObject_NextNotImplemented) + # endif + # define _Py_NoneStruct (*dll__Py_NoneStruct) ++ # define _Py_ZeroStruct (*dll__Py_ZeroStruct) ++ # define _Py_TrueStruct (*dll__Py_TrueStruct) + # define PyObject_Init dll__PyObject_Init + # define PyObject_GetIter dll_PyObject_GetIter + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 +*************** +*** 263,268 **** +--- 266,272 ---- + static PyObject*(*dll_PyInt_FromLong)(long); + static long(*dll_PyLong_AsLong)(PyObject *); + static PyObject*(*dll_PyLong_FromLong)(long); ++ static PyTypeObject* dll_PyBool_Type; + static PyTypeObject* dll_PyInt_Type; + static PyTypeObject* dll_PyLong_Type; + static PyObject*(*dll_PyList_GetItem)(PyObject *, PyInt); +*************** +*** 320,325 **** +--- 324,331 ---- + static iternextfunc dll__PyObject_NextNotImplemented; + # endif + static PyObject* dll__Py_NoneStruct; ++ static PyObject* _Py_ZeroStruct; ++ static PyObject* dll__Py_TrueStruct; + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + static int (*dll_PyType_IsSubtype)(PyTypeObject *, PyTypeObject *); + # endif +*************** +*** 389,394 **** +--- 395,401 ---- + {"PyInt_FromLong", (PYTHON_PROC*)&dll_PyInt_FromLong}, + {"PyLong_AsLong", (PYTHON_PROC*)&dll_PyLong_AsLong}, + {"PyLong_FromLong", (PYTHON_PROC*)&dll_PyLong_FromLong}, ++ {"PyBool_Type", (PYTHON_PROC*)&dll_PyBool_Type}, + {"PyInt_Type", (PYTHON_PROC*)&dll_PyInt_Type}, + {"PyLong_Type", (PYTHON_PROC*)&dll_PyLong_Type}, + {"PyList_GetItem", (PYTHON_PROC*)&dll_PyList_GetItem}, +*************** +*** 449,454 **** +--- 456,463 ---- + {"_PyObject_NextNotImplemented", (PYTHON_PROC*)&dll__PyObject_NextNotImplemented}, + # endif + {"_Py_NoneStruct", (PYTHON_PROC*)&dll__Py_NoneStruct}, ++ {"_Py_ZeroStruct", (PYTHON_PROC*)&dll__Py_ZeroStruct}, ++ {"_Py_TrueStruct", (PYTHON_PROC*)&dll__Py_TrueStruct}, + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + {"PyType_IsSubtype", (PYTHON_PROC*)&dll_PyType_IsSubtype}, + # endif +*************** +*** 1563,1568 **** +--- 1572,1581 ---- + PyDict_SetItemString(dict, "buffers", (PyObject *)(void *)&TheBufferList); + PyDict_SetItemString(dict, "current", (PyObject *)(void *)&TheCurrent); + PyDict_SetItemString(dict, "windows", (PyObject *)(void *)&TheWindowList); ++ PyDict_SetItemString(dict, "VAR_LOCKED", PyInt_FromLong(VAR_LOCKED)); ++ PyDict_SetItemString(dict, "VAR_FIXED", PyInt_FromLong(VAR_FIXED)); ++ PyDict_SetItemString(dict, "VAR_SCOPE", PyInt_FromLong(VAR_SCOPE)); ++ PyDict_SetItemString(dict, "VAR_DEF_SCOPE", PyInt_FromLong(VAR_DEF_SCOPE)); + + if (PyErr_Occurred()) + return -1; +*************** +*** 1629,1635 **** + (destructor) DictionaryDestructor, + (printfunc) 0, + (getattrfunc) DictionaryGetattr, +! (setattrfunc) 0, + (cmpfunc) 0, + (reprfunc) 0, + +--- 1642,1648 ---- + (destructor) DictionaryDestructor, + (printfunc) 0, + (getattrfunc) DictionaryGetattr, +! (setattrfunc) DictionarySetattr, + (cmpfunc) 0, + (reprfunc) 0, + +*************** +*** 1656,1661 **** +--- 1669,1681 ---- + static PyObject * + DictionaryGetattr(PyObject *self, char *name) + { ++ DictionaryObject *this = ((DictionaryObject *) (self)); ++ ++ if (strcmp(name, "locked") == 0) ++ return PyInt_FromLong(this->dict->dv_lock); ++ else if (strcmp(name, "scope") == 0) ++ return PyInt_FromLong(this->dict->dv_scope); ++ + return Py_FindMethod(DictionaryMethods, self, name); + } + +*************** +*** 1687,1693 **** + (destructor) ListDestructor, + (printfunc) 0, + (getattrfunc) ListGetattr, +! (setattrfunc) 0, + (cmpfunc) 0, + (reprfunc) 0, + +--- 1707,1713 ---- + (destructor) ListDestructor, + (printfunc) 0, + (getattrfunc) ListGetattr, +! (setattrfunc) ListSetattr, + (cmpfunc) 0, + (reprfunc) 0, + +*************** +*** 1714,1719 **** +--- 1734,1742 ---- + static PyObject * + ListGetattr(PyObject *self, char *name) + { ++ if (strcmp(name, "locked") == 0) ++ return PyInt_FromLong(((ListObject *)(self))->list->lv_lock); ++ + return Py_FindMethod(ListMethods, self, name); + } + +*** ../vim-7.3.671/src/if_python3.c 2012-09-21 13:45:57.000000000 +0200 +--- src/if_python3.c 2012-09-21 13:49:14.000000000 +0200 +*************** +*** 161,167 **** + # define PyRun_String py3_PyRun_String + # define PySys_SetObject py3_PySys_SetObject + # define PySys_SetArgv py3_PySys_SetArgv +- # define PyType_Type (*py3_PyType_Type) + # define PyType_Ready py3_PyType_Ready + #undef Py_BuildValue + # define Py_BuildValue py3_Py_BuildValue +--- 161,166 ---- +*************** +*** 170,175 **** +--- 169,176 ---- + # define Py_Finalize py3_Py_Finalize + # define Py_IsInitialized py3_Py_IsInitialized + # define _Py_NoneStruct (*py3__Py_NoneStruct) ++ # define _Py_FalseStruct (*py3__Py_FalseStruct) ++ # define _Py_TrueStruct (*py3__Py_TrueStruct) + # define _PyObject_NextNotImplemented (*py3__PyObject_NextNotImplemented) + # define PyModule_AddObject py3_PyModule_AddObject + # define PyImport_AppendInittab py3_PyImport_AppendInittab +*************** +*** 184,191 **** +--- 185,194 ---- + # define PyFloat_FromDouble py3_PyFloat_FromDouble + # define PyFloat_AsDouble py3_PyFloat_AsDouble + # define PyObject_GenericGetAttr py3_PyObject_GenericGetAttr ++ # define PyType_Type (*py3_PyType_Type) + # define PySlice_Type (*py3_PySlice_Type) + # define PyFloat_Type (*py3_PyFloat_Type) ++ # define PyBool_Type (*py3_PyBool_Type) + # define PyErr_NewException py3_PyErr_NewException + # ifdef Py_DEBUG + # define _Py_NegativeRefcount py3__Py_NegativeRefcount +*************** +*** 245,251 **** + static PyObject* (*py3_PyImport_ImportModule)(const char *); + static PyObject* (*py3_PyImport_AddModule)(const char *); + static int (*py3_PyErr_BadArgument)(void); +- static PyTypeObject* py3_PyType_Type; + static PyObject* (*py3_PyErr_Occurred)(void); + static PyObject* (*py3_PyModule_GetDict)(PyObject *); + static int (*py3_PyList_SetItem)(PyObject *, Py_ssize_t, PyObject *); +--- 248,253 ---- +*************** +*** 275,280 **** +--- 277,284 ---- + static PyObject*(*py3__PyObject_Init)(PyObject *, PyTypeObject *); + static iternextfunc py3__PyObject_NextNotImplemented; + static PyObject* py3__Py_NoneStruct; ++ static PyObject* py3__Py_FalseStruct; ++ static PyObject* py3__Py_TrueStruct; + static int (*py3_PyModule_AddObject)(PyObject *m, const char *name, PyObject *o); + static int (*py3_PyImport_AppendInittab)(const char *name, PyObject* (*initfunc)(void)); + static char* (*py3__PyUnicode_AsString)(PyObject *unicode); +*************** +*** 288,295 **** +--- 292,301 ---- + static PyObject* (*py3_PyModule_Create2)(struct PyModuleDef* module, int module_api_version); + static PyObject* (*py3_PyType_GenericAlloc)(PyTypeObject *type, Py_ssize_t nitems); + static PyObject* (*py3_PyType_GenericNew)(PyTypeObject *type, PyObject *args, PyObject *kwds); ++ static PyTypeObject* py3_PyType_Type; + static PyTypeObject* py3_PySlice_Type; + static PyTypeObject* py3_PyFloat_Type; ++ static PyTypeObject* py3_PyBool_Type; + static PyObject* (*py3_PyErr_NewException)(char *name, PyObject *base, PyObject *dict); + static PyObject* (*py3_PyCapsule_New)(void *, char *, PyCapsule_Destructor); + static void* (*py3_PyCapsule_GetPointer)(PyObject *, char *); +*************** +*** 363,369 **** + {"PyImport_ImportModule", (PYTHON_PROC*)&py3_PyImport_ImportModule}, + {"PyImport_AddModule", (PYTHON_PROC*)&py3_PyImport_AddModule}, + {"PyErr_BadArgument", (PYTHON_PROC*)&py3_PyErr_BadArgument}, +- {"PyType_Type", (PYTHON_PROC*)&py3_PyType_Type}, + {"PyErr_Occurred", (PYTHON_PROC*)&py3_PyErr_Occurred}, + {"PyModule_GetDict", (PYTHON_PROC*)&py3_PyModule_GetDict}, + {"PyList_SetItem", (PYTHON_PROC*)&py3_PyList_SetItem}, +--- 369,374 ---- +*************** +*** 386,391 **** +--- 391,398 ---- + {"Py_IsInitialized", (PYTHON_PROC*)&py3_Py_IsInitialized}, + {"_PyObject_NextNotImplemented", (PYTHON_PROC*)&py3__PyObject_NextNotImplemented}, + {"_Py_NoneStruct", (PYTHON_PROC*)&py3__Py_NoneStruct}, ++ {"_Py_FalseStruct", (PYTHON_PROC*)&py3__Py_FalseStruct}, ++ {"_Py_TrueStruct", (PYTHON_PROC*)&py3__Py_TrueStruct}, + {"PyErr_Clear", (PYTHON_PROC*)&py3_PyErr_Clear}, + {"PyObject_Init", (PYTHON_PROC*)&py3__PyObject_Init}, + {"PyModule_AddObject", (PYTHON_PROC*)&py3_PyModule_AddObject}, +*************** +*** 400,407 **** +--- 407,416 ---- + {"PyModule_Create2", (PYTHON_PROC*)&py3_PyModule_Create2}, + {"PyType_GenericAlloc", (PYTHON_PROC*)&py3_PyType_GenericAlloc}, + {"PyType_GenericNew", (PYTHON_PROC*)&py3_PyType_GenericNew}, ++ {"PyType_Type", (PYTHON_PROC*)&py3_PyType_Type}, + {"PySlice_Type", (PYTHON_PROC*)&py3_PySlice_Type}, + {"PyFloat_Type", (PYTHON_PROC*)&py3_PyFloat_Type}, ++ {"PyBool_Type", (PYTHON_PROC*)&py3_PyBool_Type}, + {"PyErr_NewException", (PYTHON_PROC*)&py3_PyErr_NewException}, + # ifdef Py_DEBUG + {"_Py_NegativeRefcount", (PYTHON_PROC*)&py3__Py_NegativeRefcount}, +*************** +*** 1534,1539 **** +--- 1543,1570 ---- + /* mp_ass_subscript */ (objobjargproc) DictionaryAssItem, + }; + ++ static PyObject * ++ DictionaryGetattro(PyObject *self, PyObject *nameobj) ++ { ++ DictionaryObject *this = ((DictionaryObject *) (self)); ++ ++ GET_ATTR_STRING(name, nameobj); ++ ++ if (strcmp(name, "locked") == 0) ++ return PyLong_FromLong(this->dict->dv_lock); ++ else if (strcmp(name, "scope") == 0) ++ return PyLong_FromLong(this->dict->dv_scope); ++ ++ return PyObject_GenericGetAttr(self, nameobj); ++ } ++ ++ static int ++ DictionarySetattro(PyObject *self, PyObject *nameobj, PyObject *val) ++ { ++ GET_ATTR_STRING(name, nameobj); ++ return DictionarySetattr((DictionaryObject *) self, name, val); ++ } ++ + static PyTypeObject DictionaryType; + + static void +*************** +*** 1625,1630 **** +--- 1656,1679 ---- + } + } + ++ static PyObject * ++ ListGetattro(PyObject *self, PyObject *nameobj) ++ { ++ GET_ATTR_STRING(name, nameobj); ++ ++ if (strcmp(name, "locked") == 0) ++ return PyLong_FromLong(((ListObject *) (self))->list->lv_lock); ++ ++ return PyObject_GenericGetAttr(self, nameobj); ++ } ++ ++ static int ++ ListSetattro(PyObject *self, PyObject *nameobj, PyObject *val) ++ { ++ GET_ATTR_STRING(name, nameobj); ++ return ListSetattr((ListObject *) self, name, val); ++ } ++ + static void + ListDestructor(PyObject *self) + { +*************** +*** 1713,1718 **** +--- 1762,1768 ---- + PyMODINIT_FUNC Py3Init_vim(void) + { + PyObject *mod; ++ PyObject *tmp; + /* The special value is removed from sys.path in Python3_Init(). */ + static wchar_t *(argv[2]) = {L"/must>not&exist/foo", NULL}; + +*************** +*** 1744,1749 **** +--- 1794,1809 ---- + Py_INCREF((PyObject *)(void *)&TheWindowList); + PyModule_AddObject(mod, "windows", (PyObject *)(void *)&TheWindowList); + ++ #define ADD_INT_CONSTANT(name, value) \ ++ tmp = PyLong_FromLong(value); \ ++ Py_INCREF(tmp); \ ++ PyModule_AddObject(mod, name, tmp) ++ ++ ADD_INT_CONSTANT("VAR_LOCKED", VAR_LOCKED); ++ ADD_INT_CONSTANT("VAR_FIXED", VAR_FIXED); ++ ADD_INT_CONSTANT("VAR_SCOPE", VAR_SCOPE); ++ ADD_INT_CONSTANT("VAR_DEF_SCOPE", VAR_DEF_SCOPE); ++ + if (PyErr_Occurred()) + return NULL; + +*************** +*** 1899,1904 **** +--- 1959,1966 ---- + vim_memset(&DictionaryType, 0, sizeof(DictionaryType)); + DictionaryType.tp_name = "vim.dictionary"; + DictionaryType.tp_basicsize = sizeof(DictionaryObject); ++ DictionaryType.tp_getattro = DictionaryGetattro; ++ DictionaryType.tp_setattro = DictionarySetattro; + DictionaryType.tp_dealloc = DictionaryDestructor; + DictionaryType.tp_as_mapping = &DictionaryAsMapping; + DictionaryType.tp_flags = Py_TPFLAGS_DEFAULT; +*************** +*** 1909,1914 **** +--- 1971,1978 ---- + ListType.tp_name = "vim.list"; + ListType.tp_dealloc = ListDestructor; + ListType.tp_basicsize = sizeof(ListObject); ++ ListType.tp_getattro = ListGetattro; ++ ListType.tp_setattro = ListSetattro; + ListType.tp_as_sequence = &ListAsSeq; + ListType.tp_as_mapping = &ListAsMapping; + ListType.tp_flags = Py_TPFLAGS_DEFAULT; +*** ../vim-7.3.671/src/testdir/test86.in 2012-09-05 19:17:37.000000000 +0200 +--- src/testdir/test86.in 2012-09-21 13:49:14.000000000 +0200 +*************** +*** 211,216 **** +--- 211,251 ---- + m.extend([e.__class__.__name__]) + EOF + :$put =messages ++ :unlet messages ++ :" locked and scope attributes ++ :let d={} | let dl={} | lockvar dl ++ :for s in split("d dl v: g:") ++ : let name=tr(s, ':', 's') ++ : execute 'py '.name.'=vim.bindeval("'.s.'")' ++ : let toput=s.' : '.join(map(['locked', 'scope'], 'v:val.":".pyeval(name.".".v:val)'), ';') ++ : $put =toput ++ :endfor ++ :silent! let d.abc=1 ++ :silent! let dl.abc=1 ++ :py d.locked=True ++ :py dl.locked=False ++ :silent! let d.def=1 ++ :silent! let dl.def=1 ++ :put ='d:'.string(d) ++ :put ='dl:'.string(dl) ++ :unlet d dl ++ : ++ :let l=[] | let ll=[] | lockvar ll ++ :for s in split("l ll") ++ : let name=tr(s, ':', 's') ++ : execute 'py '.name.'=vim.bindeval("'.s.'")' ++ : let toput=s.' : locked:'.pyeval(name.'.locked') ++ : $put =toput ++ :endfor ++ :silent! call extend(l, [0]) ++ :silent! call extend(ll, [0]) ++ :py l.locked=True ++ :py ll.locked=False ++ :silent! call extend(l, [1]) ++ :silent! call extend(ll, [1]) ++ :put ='l:'.string(l) ++ :put ='ll:'.string(ll) ++ :unlet l ll + :" + :" pyeval() + :let l=pyeval('range(3)') +*************** +*** 240,245 **** +--- 275,281 ---- + :call garbagecollect(1) + :" + :/^start:/,$wq! test.out ++ :call getchar() + ENDTEST + + start: +*** ../vim-7.3.671/src/testdir/test86.ok 2012-09-05 19:17:37.000000000 +0200 +--- src/testdir/test86.ok 2012-09-21 13:49:14.000000000 +0200 +*************** +*** 44,49 **** +--- 44,59 ---- + ValueError + TypeError + TypeError ++ d : locked:0;scope:0 ++ dl : locked:1;scope:0 ++ v: : locked:2;scope:1 ++ g: : locked:0;scope:2 ++ d:{'abc': 1} ++ dl:{'def': 1} ++ l : locked:0 ++ ll : locked:1 ++ l:[0] ++ ll:[1] + [0, 1, 2] + ['a', 'b'] + ['c', 1] +*** ../vim-7.3.671/src/testdir/test87.in 2012-09-05 19:17:37.000000000 +0200 +--- src/testdir/test87.in 2012-09-21 13:49:14.000000000 +0200 +*************** +*** 211,216 **** +--- 211,251 ---- + m.extend([e.__class__.__name__]) + EOF + :$put =messages ++ :unlet messages ++ :" locked and scope attributes ++ :let d={} | let dl={} | lockvar dl ++ :for s in split("d dl v: g:") ++ : let name=tr(s, ':', 's') ++ : execute 'py3 '.name.'=vim.bindeval("'.s.'")' ++ : let toput=s.' : '.join(map(['locked', 'scope'], 'v:val.":".py3eval(name.".".v:val)'), ';') ++ : $put =toput ++ :endfor ++ :silent! let d.abc=1 ++ :silent! let dl.abc=1 ++ :py3 d.locked=True ++ :py3 dl.locked=False ++ :silent! let d.def=1 ++ :silent! let dl.def=1 ++ :put ='d:'.string(d) ++ :put ='dl:'.string(dl) ++ :unlet d dl ++ : ++ :let l=[] | let ll=[] | lockvar ll ++ :for s in split("l ll") ++ : let name=tr(s, ':', 's') ++ : execute 'py3 '.name.'=vim.bindeval("'.s.'")' ++ : let toput=s.' : locked:'.py3eval(name.'.locked') ++ : $put =toput ++ :endfor ++ :silent! call extend(l, [0]) ++ :silent! call extend(ll, [0]) ++ :py3 l.locked=True ++ :py3 ll.locked=False ++ :silent! call extend(l, [1]) ++ :silent! call extend(ll, [1]) ++ :put ='l:'.string(l) ++ :put ='ll:'.string(ll) ++ :unlet l ll + :" + :" py3eval() + :let l=py3eval('[0, 1, 2]') +*** ../vim-7.3.671/src/testdir/test87.ok 2012-09-05 19:17:37.000000000 +0200 +--- src/testdir/test87.ok 2012-09-21 13:49:14.000000000 +0200 +*************** +*** 44,49 **** +--- 44,59 ---- + ValueError + TypeError + TypeError ++ d : locked:0;scope:0 ++ dl : locked:1;scope:0 ++ v: : locked:2;scope:1 ++ g: : locked:0;scope:2 ++ d:{'abc': 1} ++ dl:{'def': 1} ++ l : locked:0 ++ ll : locked:1 ++ l:[0] ++ ll:[1] + [0, 1, 2] + ['a', 'b'] + ['c', 1] +*** ../vim-7.3.671/src/version.c 2012-09-21 13:45:57.000000000 +0200 +--- src/version.c 2012-09-21 13:48:18.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 672, + /**/ + +-- +Vi beats Emacs to death, and then again! + http://linuxtoday.com/stories/5764.html + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 53f5541a7a577cc33fa7ea3275138797d1cc3dcc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:27 +0200 Subject: [PATCH 0508/3340] - patchlevel 673 --- 7.3.673 | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 7.3.673 diff --git a/7.3.673 b/7.3.673 new file mode 100644 index 00000000..8ab41a33 --- /dev/null +++ b/7.3.673 @@ -0,0 +1,64 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.673 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.673 +Problem: Using "gN" while 'selection' is "exclusive" misses one character. + (Ben Fritz) +Solution: Check the direction when compensating for exclusive selection. + (Christian Brabandt) +Files: src/search.c + + +*** ../vim-7.3.672/src/search.c 2012-09-05 12:16:39.000000000 +0200 +--- src/search.c 2012-10-03 13:28:49.000000000 +0200 +*************** +*** 4650,4657 **** + if (VIsual_active) + { + redraw_curbuf_later(INVERTED); /* update the inversion */ +! if (*p_sel == 'e' && ltoreq(VIsual, curwin->w_cursor)) +! inc_cursor(); + } + + #ifdef FEAT_FOLDING +--- 4650,4664 ---- + if (VIsual_active) + { + redraw_curbuf_later(INVERTED); /* update the inversion */ +! if (*p_sel == 'e') +! { +! /* Correction for exclusive selection depends on the direction. */ +! if (forward && ltoreq(VIsual, curwin->w_cursor)) +! inc_cursor(); +! else if (!forward && ltoreq(curwin->w_cursor, VIsual)) +! inc(&VIsual); +! } +! + } + + #ifdef FEAT_FOLDING +*** ../vim-7.3.672/src/version.c 2012-09-21 14:00:05.000000000 +0200 +--- src/version.c 2012-10-03 13:31:45.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 673, + /**/ + +-- +You can be stopped by the police for biking over 65 miles per hour. +You are not allowed to walk across a street on your hands. + [real standing laws in Connecticut, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d09d5af6e2dcb1749a27bc326a60a9721d0f4044 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:28 +0200 Subject: [PATCH 0509/3340] - patchlevel 674 --- 7.3.674 | 286 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 286 insertions(+) create mode 100644 7.3.674 diff --git a/7.3.674 b/7.3.674 new file mode 100644 index 00000000..ea3dc8d2 --- /dev/null +++ b/7.3.674 @@ -0,0 +1,286 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.674 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.674 +Problem: Can't compile with Lua/dyn on Cygwin. +Solution: Adjust configure to use the right library name. (Ken Takata) +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.673/src/configure.in 2012-09-21 13:26:44.000000000 +0200 +--- src/configure.in 2012-10-03 14:39:42.000000000 +0200 +*************** +*** 455,485 **** + + LUA_INC= + if test "X$vi_cv_path_lua_pfx" != "X"; then + AC_MSG_CHECKING(if lua.h can be found in $vi_cv_path_lua_pfx/include) + if test -f $vi_cv_path_lua_pfx/include/lua.h; then + AC_MSG_RESULT(yes) + else + AC_MSG_RESULT(no) +! dnl -- try to find Lua executable +! AC_PATH_PROG(vi_cv_path_lua, lua) +! if test "X$vi_cv_path_lua" != "X"; then +! dnl -- find Lua version +! AC_CACHE_CHECK(Lua version, vi_cv_version_lua, +! [ vi_cv_version_lua=`${vi_cv_path_lua} -e "print(_VERSION)" | sed 's/.* //'` ]) +! AC_MSG_CHECKING(if lua.h can be found in $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua) +! if test -f $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua/lua.h; then +! AC_MSG_RESULT(yes) +! LUA_INC=/lua$vi_cv_version_lua +! else +! AC_MSG_RESULT(no) +! vi_cv_path_lua_pfx= +! fi + fi + fi + fi + + if test "X$vi_cv_path_lua_pfx" != "X"; then +! if test "X$vi_cv_version_lua" != "X"; then + dnl Test alternate location using version + LUA_LIBS="-L${vi_cv_path_lua_pfx}/lib -llua$vi_cv_version_lua" + else +--- 455,485 ---- + + LUA_INC= + if test "X$vi_cv_path_lua_pfx" != "X"; then ++ dnl -- try to find Lua executable ++ AC_PATH_PROG(vi_cv_path_lua, lua) ++ if test "X$vi_cv_path_lua" != "X"; then ++ dnl -- find Lua version ++ AC_CACHE_CHECK(Lua version, vi_cv_version_lua, ++ [ vi_cv_version_lua=`${vi_cv_path_lua} -e "print(_VERSION)" | sed 's/.* //'` ]) ++ fi + AC_MSG_CHECKING(if lua.h can be found in $vi_cv_path_lua_pfx/include) + if test -f $vi_cv_path_lua_pfx/include/lua.h; then + AC_MSG_RESULT(yes) + else + AC_MSG_RESULT(no) +! AC_MSG_CHECKING(if lua.h can be found in $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua) +! if test -f $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua/lua.h; then +! AC_MSG_RESULT(yes) +! LUA_INC=/lua$vi_cv_version_lua +! else +! AC_MSG_RESULT(no) +! vi_cv_path_lua_pfx= + fi + fi + fi + + if test "X$vi_cv_path_lua_pfx" != "X"; then +! if test "X$LUA_INC" != "X"; then + dnl Test alternate location using version + LUA_LIBS="-L${vi_cv_path_lua_pfx}/lib -llua$vi_cv_version_lua" + else +*************** +*** 491,507 **** + LUA_PRO="if_lua.pro" + AC_DEFINE(FEAT_LUA) + if test "$enable_luainterp" = "dynamic"; then +! dnl Determine the SONAME for the current version, but fallback to +! dnl liblua${vi_cv_version_lua}.so if no SONAME-versioned file is found. +! for i in 0 1 2 3 4 5 6 7 8 9; do +! if test -f "${vi_cv_path_lua_pfx}/lib/liblua${vi_cv_version_lua}.so.$i"; then +! LUA_SONAME=".$i" +! break +! fi +! done + AC_DEFINE(DYNAMIC_LUA) + LUA_LIBS="" +! LUA_CFLAGS="-DDYNAMIC_LUA_DLL=\\\"liblua${vi_cv_version_lua}.so$LUA_SONAME\\\" $LUA_CFLAGS" + fi + fi + if test "$fail_if_missing" = "yes" -a -z "$LUA_SRC"; then +--- 491,512 ---- + LUA_PRO="if_lua.pro" + AC_DEFINE(FEAT_LUA) + if test "$enable_luainterp" = "dynamic"; then +! if test -f "${vi_cv_path_lua_pfx}/bin/cyglua-${vi_cv_version_lua}.dll"; then +! vi_cv_dll_name_lua="cyglua-${vi_cv_version_lua}.dll" +! else +! dnl Determine the SONAME for the current version, but fallback to +! dnl liblua${vi_cv_version_lua}.so if no SONAME-versioned file is found. +! for i in 0 1 2 3 4 5 6 7 8 9; do +! if test -f "${vi_cv_path_lua_pfx}/lib/liblua${vi_cv_version_lua}.so.$i"; then +! LUA_SONAME=".$i" +! break +! fi +! done +! vi_cv_dll_name_lua="liblua${vi_cv_version_lua}.so$LUA_SONAME" +! fi + AC_DEFINE(DYNAMIC_LUA) + LUA_LIBS="" +! LUA_CFLAGS="-DDYNAMIC_LUA_DLL=\\\"${vi_cv_dll_name_lua}\\\" $LUA_CFLAGS" + fi + fi + if test "$fail_if_missing" = "yes" -a -z "$LUA_SRC"; then +*** ../vim-7.3.673/src/auto/configure 2012-09-21 13:26:44.000000000 +0200 +--- src/auto/configure 2012-10-03 14:42:13.000000000 +0200 +*************** +*** 4648,4662 **** + + LUA_INC= + if test "X$vi_cv_path_lua_pfx" != "X"; then +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking if lua.h can be found in $vi_cv_path_lua_pfx/include" >&5 +! $as_echo_n "checking if lua.h can be found in $vi_cv_path_lua_pfx/include... " >&6; } +! if test -f $vi_cv_path_lua_pfx/include/lua.h; then +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +! $as_echo "yes" >&6; } +! else +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +! $as_echo "no" >&6; } +! # Extract the first word of "lua", so it can be a program name with args. + set dummy lua; ac_word=$2 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 + $as_echo_n "checking for $ac_word... " >&6; } +--- 4648,4654 ---- + + LUA_INC= + if test "X$vi_cv_path_lua_pfx" != "X"; then +! # Extract the first word of "lua", so it can be a program name with args. + set dummy lua; ac_word=$2 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 + $as_echo_n "checking for $ac_word... " >&6; } +*************** +*** 4696,4703 **** + fi + + +! if test "X$vi_cv_path_lua" != "X"; then +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking Lua version" >&5 + $as_echo_n "checking Lua version... " >&6; } + if test "${vi_cv_version_lua+set}" = set; then : + $as_echo_n "(cached) " >&6 +--- 4688,4695 ---- + fi + + +! if test "X$vi_cv_path_lua" != "X"; then +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking Lua version" >&5 + $as_echo_n "checking Lua version... " >&6; } + if test "${vi_cv_version_lua+set}" = set; then : + $as_echo_n "(cached) " >&6 +*************** +*** 4706,4728 **** + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_version_lua" >&5 + $as_echo "$vi_cv_version_lua" >&6; } +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking if lua.h can be found in $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua" >&5 + $as_echo_n "checking if lua.h can be found in $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua... " >&6; } +! if test -f $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua/lua.h; then +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 + $as_echo "yes" >&6; } +! LUA_INC=/lua$vi_cv_version_lua +! else +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 + $as_echo "no" >&6; } +! vi_cv_path_lua_pfx= +! fi + fi + fi + fi + + if test "X$vi_cv_path_lua_pfx" != "X"; then +! if test "X$vi_cv_version_lua" != "X"; then + LUA_LIBS="-L${vi_cv_path_lua_pfx}/lib -llua$vi_cv_version_lua" + else + LUA_LIBS="-L${vi_cv_path_lua_pfx}/lib -llua" +--- 4698,4728 ---- + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_version_lua" >&5 + $as_echo "$vi_cv_version_lua" >&6; } +! fi +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking if lua.h can be found in $vi_cv_path_lua_pfx/include" >&5 +! $as_echo_n "checking if lua.h can be found in $vi_cv_path_lua_pfx/include... " >&6; } +! if test -f $vi_cv_path_lua_pfx/include/lua.h; then +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +! $as_echo "yes" >&6; } +! else +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +! $as_echo "no" >&6; } +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking if lua.h can be found in $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua" >&5 + $as_echo_n "checking if lua.h can be found in $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua... " >&6; } +! if test -f $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua/lua.h; then +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 + $as_echo "yes" >&6; } +! LUA_INC=/lua$vi_cv_version_lua +! else +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 + $as_echo "no" >&6; } +! vi_cv_path_lua_pfx= + fi + fi + fi + + if test "X$vi_cv_path_lua_pfx" != "X"; then +! if test "X$LUA_INC" != "X"; then + LUA_LIBS="-L${vi_cv_path_lua_pfx}/lib -llua$vi_cv_version_lua" + else + LUA_LIBS="-L${vi_cv_path_lua_pfx}/lib -llua" +*************** +*** 4734,4749 **** + $as_echo "#define FEAT_LUA 1" >>confdefs.h + + if test "$enable_luainterp" = "dynamic"; then +! for i in 0 1 2 3 4 5 6 7 8 9; do +! if test -f "${vi_cv_path_lua_pfx}/lib/liblua${vi_cv_version_lua}.so.$i"; then +! LUA_SONAME=".$i" +! break +! fi +! done + $as_echo "#define DYNAMIC_LUA 1" >>confdefs.h + + LUA_LIBS="" +! LUA_CFLAGS="-DDYNAMIC_LUA_DLL=\\\"liblua${vi_cv_version_lua}.so$LUA_SONAME\\\" $LUA_CFLAGS" + fi + fi + if test "$fail_if_missing" = "yes" -a -z "$LUA_SRC"; then +--- 4734,4754 ---- + $as_echo "#define FEAT_LUA 1" >>confdefs.h + + if test "$enable_luainterp" = "dynamic"; then +! if test -f "${vi_cv_path_lua_pfx}/bin/cyglua-${vi_cv_version_lua}.dll"; then +! vi_cv_dll_name_lua="cyglua-${vi_cv_version_lua}.dll" +! else +! for i in 0 1 2 3 4 5 6 7 8 9; do +! if test -f "${vi_cv_path_lua_pfx}/lib/liblua${vi_cv_version_lua}.so.$i"; then +! LUA_SONAME=".$i" +! break +! fi +! done +! vi_cv_dll_name_lua="liblua${vi_cv_version_lua}.so$LUA_SONAME" +! fi + $as_echo "#define DYNAMIC_LUA 1" >>confdefs.h + + LUA_LIBS="" +! LUA_CFLAGS="-DDYNAMIC_LUA_DLL=\\\"${vi_cv_dll_name_lua}\\\" $LUA_CFLAGS" + fi + fi + if test "$fail_if_missing" = "yes" -a -z "$LUA_SRC"; then +*** ../vim-7.3.673/src/version.c 2012-10-03 13:35:45.000000000 +0200 +--- src/version.c 2012-10-03 14:44:56.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 674, + /**/ + +-- +The Law, in its majestic equality, forbids the rich, as well as the +poor, to sleep under the bridges, to beg in the streets, and to steal +bread. -- Anatole France + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bfd8a19b3724af380eb520dd580216149c8a5141 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:30 +0200 Subject: [PATCH 0510/3340] - patchlevel 675 --- 7.3.675 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.675 diff --git a/7.3.675 b/7.3.675 new file mode 100644 index 00000000..7106917f --- /dev/null +++ b/7.3.675 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.675 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.675 +Problem: Using uninitialized memory with very long file name. +Solution: Put NUL after text when it is truncated. (ZyX) +Files: src/buffer.c + + +*** ../vim-7.3.674/src/buffer.c 2012-09-05 13:30:22.000000000 +0200 +--- src/buffer.c 2012-10-03 16:25:12.000000000 +0200 +*************** +*** 3058,3064 **** + + *p++ = '"'; + if (buf_spname(curbuf) != NULL) +! STRCPY(p, buf_spname(curbuf)); + else + { + if (!fullname && curbuf->b_fname != NULL) +--- 3058,3064 ---- + + *p++ = '"'; + if (buf_spname(curbuf) != NULL) +! vim_strncpy(p, buf_spname(curbuf), IOSIZE - (p - buffer) - 1); + else + { + if (!fullname && curbuf->b_fname != NULL) +*** ../vim-7.3.674/src/version.c 2012-10-03 14:48:03.000000000 +0200 +--- src/version.c 2012-10-03 16:29:28.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 675, + /**/ + +-- +It is illegal to rob a bank and then shoot at the bank teller with a water +pistol. + [real standing law in Louisana, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d4a36b0c9d3facb2f6b079d32fe92336e13b74a8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:31 +0200 Subject: [PATCH 0511/3340] - patchlevel 676 --- 7.3.676 | 77 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 77 insertions(+) create mode 100644 7.3.676 diff --git a/7.3.676 b/7.3.676 new file mode 100644 index 00000000..40d6f3d0 --- /dev/null +++ b/7.3.676 @@ -0,0 +1,77 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.676 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.676 +Problem: Ruby compilation on Windows 32 bit doesn't work. +Solution: Only use some functions for 64 bit. (Ken Takata) +Files: src/if_ruby.c + + +*** ../vim-7.3.675/src/if_ruby.c 2012-09-18 16:36:26.000000000 +0200 +--- src/if_ruby.c 2012-10-03 17:55:58.000000000 +0200 +*************** +*** 178,186 **** +--- 178,188 ---- + #define rb_hash_new dll_rb_hash_new + #define rb_inspect dll_rb_inspect + #define rb_int2inum dll_rb_int2inum ++ #if SIZEOF_INT < SIZEOF_LONG /* 64 bits only */ + #define rb_fix2int dll_rb_fix2int + #define rb_num2int dll_rb_num2int + #define rb_num2uint dll_rb_num2uint ++ #endif + #define rb_lastline_get dll_rb_lastline_get + #define rb_lastline_set dll_rb_lastline_set + #define rb_load_protect dll_rb_load_protect +*************** +*** 271,279 **** +--- 273,283 ---- + static VALUE (*dll_rb_hash_new) (void); + static VALUE (*dll_rb_inspect) (VALUE); + static VALUE (*dll_rb_int2inum) (long); ++ #if SIZEOF_INT < SIZEOF_LONG /* 64 bits only */ + static long (*dll_rb_fix2int) (VALUE); + static long (*dll_rb_num2int) (VALUE); + static unsigned long (*dll_rb_num2uint) (VALUE); ++ #endif + static VALUE (*dll_rb_lastline_get) (void); + static void (*dll_rb_lastline_set) (VALUE); + static void (*dll_rb_load_protect) (VALUE, int, int*); +*************** +*** 382,390 **** +--- 386,396 ---- + {"rb_hash_new", (RUBY_PROC*)&dll_rb_hash_new}, + {"rb_inspect", (RUBY_PROC*)&dll_rb_inspect}, + {"rb_int2inum", (RUBY_PROC*)&dll_rb_int2inum}, ++ #if SIZEOF_INT < SIZEOF_LONG /* 64 bits only */ + {"rb_fix2int", (RUBY_PROC*)&dll_rb_fix2int}, + {"rb_num2int", (RUBY_PROC*)&dll_rb_num2int}, + {"rb_num2uint", (RUBY_PROC*)&dll_rb_num2uint}, ++ #endif + {"rb_lastline_get", (RUBY_PROC*)&dll_rb_lastline_get}, + {"rb_lastline_set", (RUBY_PROC*)&dll_rb_lastline_set}, + {"rb_load_protect", (RUBY_PROC*)&dll_rb_load_protect}, +*** ../vim-7.3.675/src/version.c 2012-10-03 17:12:43.000000000 +0200 +--- src/version.c 2012-10-03 17:52:11.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 676, + /**/ + +-- +Why don't cannibals eat clowns? +Because they taste funny. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fdc6798bb926a67bd64e06e7f743fa32dbb92047 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:32 +0200 Subject: [PATCH 0512/3340] - patchlevel 677 --- 7.3.677 | 268 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 268 insertions(+) create mode 100644 7.3.677 diff --git a/7.3.677 b/7.3.677 new file mode 100644 index 00000000..bf6e91f5 --- /dev/null +++ b/7.3.677 @@ -0,0 +1,268 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.677 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.677 +Problem: buf_spname() is used inconsistently. +Solution: Make the return type a char_u pointer. Check the size of the + returned string. +Files: src/buffer.c, src/proto/buffer.pro, src/ex_cmds2.c, + src/ex_docmd.c, src/memline.c, src/screen.c + + +*** ../vim-7.3.676/src/buffer.c 2012-10-03 17:12:43.000000000 +0200 +--- src/buffer.c 2012-10-03 18:14:34.000000000 +0200 +*************** +*** 2635,2641 **** + continue; + msg_putchar('\n'); + if (buf_spname(buf) != NULL) +! STRCPY(NameBuff, buf_spname(buf)); + else + home_replace(buf, buf->b_fname, NameBuff, MAXPATHL, TRUE); + +--- 2635,2641 ---- + continue; + msg_putchar('\n'); + if (buf_spname(buf) != NULL) +! vim_strncpy(NameBuff, buf_spname(buf), MAXPATHL - 1); + else + home_replace(buf, buf->b_fname, NameBuff, MAXPATHL, TRUE); + +*************** +*** 3350,3356 **** + else + { + if (buf_spname(curbuf) != NULL) +! i_name = (char_u *)buf_spname(curbuf); + else /* use file name only in icon */ + i_name = gettail(curbuf->b_ffname); + *i_str = NUL; +--- 3350,3356 ---- + else + { + if (buf_spname(curbuf) != NULL) +! i_name = buf_spname(curbuf); + else /* use file name only in icon */ + i_name = gettail(curbuf->b_ffname); + *i_str = NUL; +*************** +*** 3766,3772 **** + case STL_FILENAME: + fillable = FALSE; /* don't change ' ' to fillchar */ + if (buf_spname(wp->w_buffer) != NULL) +! STRCPY(NameBuff, buf_spname(wp->w_buffer)); + else + { + t = (opt == STL_FULLPATH) ? wp->w_buffer->b_ffname +--- 3766,3772 ---- + case STL_FILENAME: + fillable = FALSE; /* don't change ' ' to fillchar */ + if (buf_spname(wp->w_buffer) != NULL) +! vim_strncpy(NameBuff, buf_spname(wp->w_buffer), MAXPATHL - 1); + else + { + t = (opt == STL_FULLPATH) ? wp->w_buffer->b_ffname +*************** +*** 5244,5250 **** + * Return special buffer name. + * Returns NULL when the buffer has a normal file name. + */ +! char * + buf_spname(buf) + buf_T *buf; + { +--- 5244,5250 ---- + * Return special buffer name. + * Returns NULL when the buffer has a normal file name. + */ +! char_u * + buf_spname(buf) + buf_T *buf; + { +*************** +*** 5263,5271 **** + goto win_found; + win_found: + if (win != NULL && win->w_llist_ref != NULL) +! return _(msg_loclist); + else +! return _(msg_qflist); + } + #endif + #ifdef FEAT_QUICKFIX +--- 5263,5271 ---- + goto win_found; + win_found: + if (win != NULL && win->w_llist_ref != NULL) +! return (char_u *)_(msg_loclist); + else +! return (char_u *)_(msg_qflist); + } + #endif + #ifdef FEAT_QUICKFIX +*************** +*** 5274,5285 **** + if (bt_nofile(buf)) + { + if (buf->b_sfname != NULL) +! return (char *)buf->b_sfname; +! return _("[Scratch]"); + } + #endif + if (buf->b_fname == NULL) +! return _("[No Name]"); + return NULL; + } + +--- 5274,5285 ---- + if (bt_nofile(buf)) + { + if (buf->b_sfname != NULL) +! return buf->b_sfname; +! return (char_u *)_("[Scratch]"); + } + #endif + if (buf->b_fname == NULL) +! return (char_u *)_("[No Name]"); + return NULL; + } + +*** ../vim-7.3.676/src/proto/buffer.pro 2012-07-10 15:18:18.000000000 +0200 +--- src/proto/buffer.pro 2012-10-03 18:17:58.000000000 +0200 +*************** +*** 51,57 **** + void do_modelines __ARGS((int flags)); + int read_viminfo_bufferlist __ARGS((vir_T *virp, int writing)); + void write_viminfo_bufferlist __ARGS((FILE *fp)); +! char *buf_spname __ARGS((buf_T *buf)); + void buf_addsign __ARGS((buf_T *buf, int id, linenr_T lnum, int typenr)); + linenr_T buf_change_sign_type __ARGS((buf_T *buf, int markId, int typenr)); + int buf_getsigntype __ARGS((buf_T *buf, linenr_T lnum, int type)); +--- 51,57 ---- + void do_modelines __ARGS((int flags)); + int read_viminfo_bufferlist __ARGS((vir_T *virp, int writing)); + void write_viminfo_bufferlist __ARGS((FILE *fp)); +! char_u *buf_spname __ARGS((buf_T *buf)); + void buf_addsign __ARGS((buf_T *buf, int id, linenr_T lnum, int typenr)); + linenr_T buf_change_sign_type __ARGS((buf_T *buf, int markId, int typenr)); + int buf_getsigntype __ARGS((buf_T *buf, linenr_T lnum, int type)); +*** ../vim-7.3.676/src/ex_cmds2.c 2012-06-29 12:57:03.000000000 +0200 +--- src/ex_cmds2.c 2012-10-03 18:15:26.000000000 +0200 +*************** +*** 1688,1695 **** + msg_didout = FALSE; + } + if (EMSG2(_("E162: No write since last change for buffer \"%s\""), +! buf_spname(buf) != NULL ? (char_u *)buf_spname(buf) : +! buf->b_fname)) + { + save = no_wait_return; + no_wait_return = FALSE; +--- 1688,1694 ---- + msg_didout = FALSE; + } + if (EMSG2(_("E162: No write since last change for buffer \"%s\""), +! buf_spname(buf) != NULL ? buf_spname(buf) : buf->b_fname)) + { + save = no_wait_return; + no_wait_return = FALSE; +*** ../vim-7.3.676/src/ex_docmd.c 2012-09-18 16:47:00.000000000 +0200 +--- src/ex_docmd.c 2012-10-03 18:15:47.000000000 +0200 +*************** +*** 7602,7608 **** + msg_putchar(bufIsChanged(wp->w_buffer) ? '+' : ' '); + msg_putchar(' '); + if (buf_spname(wp->w_buffer) != NULL) +! STRCPY(IObuff, buf_spname(wp->w_buffer)); + else + home_replace(wp->w_buffer, wp->w_buffer->b_fname, + IObuff, IOSIZE, TRUE); +--- 7602,7608 ---- + msg_putchar(bufIsChanged(wp->w_buffer) ? '+' : ' '); + msg_putchar(' '); + if (buf_spname(wp->w_buffer) != NULL) +! vim_strncpy(IObuff, buf_spname(wp->w_buffer), IOSIZE - 1); + else + home_replace(wp->w_buffer, wp->w_buffer->b_fname, + IObuff, IOSIZE, TRUE); +*** ../vim-7.3.676/src/memline.c 2011-10-26 11:44:15.000000000 +0200 +--- src/memline.c 2012-10-03 18:18:23.000000000 +0200 +*************** +*** 780,788 **** + need_wait_return = TRUE; /* call wait_return later */ + ++no_wait_return; + (void)EMSG2(_("E303: Unable to open swap file for \"%s\", recovery impossible"), +! buf_spname(buf) != NULL +! ? (char_u *)buf_spname(buf) +! : buf->b_fname); + --no_wait_return; + } + +--- 780,786 ---- + need_wait_return = TRUE; /* call wait_return later */ + ++no_wait_return; + (void)EMSG2(_("E303: Unable to open swap file for \"%s\", recovery impossible"), +! buf_spname(buf) != NULL ? buf_spname(buf) : buf->b_fname); + --no_wait_return; + } + +*************** +*** 1315,1321 **** + smsg((char_u *)_("Using swap file \"%s\""), NameBuff); + + if (buf_spname(curbuf) != NULL) +! STRCPY(NameBuff, buf_spname(curbuf)); + else + home_replace(NULL, curbuf->b_ffname, NameBuff, MAXPATHL, TRUE); + smsg((char_u *)_("Original file \"%s\""), NameBuff); +--- 1313,1319 ---- + smsg((char_u *)_("Using swap file \"%s\""), NameBuff); + + if (buf_spname(curbuf) != NULL) +! vim_strncpy(NameBuff, buf_spname(curbuf), MAXPATHL - 1); + else + home_replace(NULL, curbuf->b_ffname, NameBuff, MAXPATHL, TRUE); + smsg((char_u *)_("Original file \"%s\""), NameBuff); +*** ../vim-7.3.676/src/screen.c 2012-08-23 18:55:50.000000000 +0200 +--- src/screen.c 2012-10-03 18:17:25.000000000 +0200 +*************** +*** 9876,9882 **** + buf_T *buf; + { + if (buf_spname(buf) != NULL) +! STRCPY(NameBuff, buf_spname(buf)); + else + home_replace(buf, buf->b_fname, NameBuff, MAXPATHL, TRUE); + trans_characters(NameBuff, MAXPATHL); +--- 9876,9882 ---- + buf_T *buf; + { + if (buf_spname(buf) != NULL) +! vim_strncpy(NameBuff, buf_spname(buf), MAXPATHL - 1); + else + home_replace(buf, buf->b_fname, NameBuff, MAXPATHL, TRUE); + trans_characters(NameBuff, MAXPATHL); +*** ../vim-7.3.676/src/version.c 2012-10-03 18:06:55.000000000 +0200 +--- src/version.c 2012-10-03 18:22:18.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 677, + /**/ + +-- +bashian roulette: +$ ((RANDOM%6)) || rm -rf ~ + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 65f419e2c4b5ac9cdebdc22927b61051f1cf306c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:33 +0200 Subject: [PATCH 0513/3340] - patchlevel 678 --- 7.3.678 | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 7.3.678 diff --git a/7.3.678 b/7.3.678 new file mode 100644 index 00000000..5f20da01 --- /dev/null +++ b/7.3.678 @@ -0,0 +1,72 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.678 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.678 +Problem: Ruby .so name may not be correct. +Solution: Use the LIBRUBY_SO entry from the config. (Vit Ondruch) +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.677/src/configure.in 2012-10-03 14:48:03.000000000 +0200 +--- src/configure.in 2012-10-03 18:38:24.000000000 +0200 +*************** +*** 1487,1493 **** + RUBY_PRO="if_ruby.pro" + AC_DEFINE(FEAT_RUBY) + if test "$enable_rubyinterp" = "dynamic"; then +! libruby=`$vi_cv_path_ruby -r rbconfig -e 'printf "lib%s.%s\n", Config::CONFIG[["RUBY_SO_NAME"]], Config::CONFIG[["DLEXT"]]'` + AC_DEFINE(DYNAMIC_RUBY) + RUBY_CFLAGS="-DDYNAMIC_RUBY_DLL=\\\"$libruby\\\" -DDYNAMIC_RUBY_VER=$rubyversion $RUBY_CFLAGS" + RUBY_LIBS= +--- 1487,1493 ---- + RUBY_PRO="if_ruby.pro" + AC_DEFINE(FEAT_RUBY) + if test "$enable_rubyinterp" = "dynamic"; then +! libruby=`$vi_cv_path_ruby -r rbconfig -e 'puts Config::CONFIG[["LIBRUBY_SO"]]'` + AC_DEFINE(DYNAMIC_RUBY) + RUBY_CFLAGS="-DDYNAMIC_RUBY_DLL=\\\"$libruby\\\" -DDYNAMIC_RUBY_VER=$rubyversion $RUBY_CFLAGS" + RUBY_LIBS= +*** ../vim-7.3.677/src/auto/configure 2012-10-03 14:48:03.000000000 +0200 +--- src/auto/configure 2012-10-03 18:40:48.000000000 +0200 +*************** +*** 6376,6382 **** + $as_echo "#define FEAT_RUBY 1" >>confdefs.h + + if test "$enable_rubyinterp" = "dynamic"; then +! libruby=`$vi_cv_path_ruby -r rbconfig -e 'printf "lib%s.%s\n", Config::CONFIG["RUBY_SO_NAME"], Config::CONFIG["DLEXT"]'` + $as_echo "#define DYNAMIC_RUBY 1" >>confdefs.h + + RUBY_CFLAGS="-DDYNAMIC_RUBY_DLL=\\\"$libruby\\\" -DDYNAMIC_RUBY_VER=$rubyversion $RUBY_CFLAGS" +--- 6376,6382 ---- + $as_echo "#define FEAT_RUBY 1" >>confdefs.h + + if test "$enable_rubyinterp" = "dynamic"; then +! libruby=`$vi_cv_path_ruby -r rbconfig -e 'puts Config::CONFIG["LIBRUBY_SO"]'` + $as_echo "#define DYNAMIC_RUBY 1" >>confdefs.h + + RUBY_CFLAGS="-DDYNAMIC_RUBY_DLL=\\\"$libruby\\\" -DDYNAMIC_RUBY_VER=$rubyversion $RUBY_CFLAGS" +*** ../vim-7.3.677/src/version.c 2012-10-03 18:24:55.000000000 +0200 +--- src/version.c 2012-10-03 18:49:09.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 678, + /**/ + +-- +Snoring is prohibited unless all bedroom windows are closed and securely +locked. + [real standing law in Massachusetts, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ce843e570699a7aff5ecd58e2c96cfce0b80fab6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:35 +0200 Subject: [PATCH 0514/3340] - patchlevel 679 --- 7.3.679 | 230 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 230 insertions(+) create mode 100644 7.3.679 diff --git a/7.3.679 b/7.3.679 new file mode 100644 index 00000000..f95bf5ea --- /dev/null +++ b/7.3.679 @@ -0,0 +1,230 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.679 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.679 +Problem: Ruby detection uses Config, newer Ruby versions use RbConfig. +Solution: Detect the need to use RbConfig. (Vit Ondruch) +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.678/src/configure.in 2012-10-03 18:49:55.000000000 +0200 +--- src/configure.in 2012-10-03 18:50:48.000000000 +0200 +*************** +*** 1442,1465 **** + AC_MSG_CHECKING(Ruby version) + if $vi_cv_path_ruby -e '(VERSION rescue RUBY_VERSION) >= "1.6.0" or exit 1' >/dev/null 2>/dev/null; then + AC_MSG_RESULT(OK) + AC_MSG_CHECKING(Ruby header files) +! rubyhdrdir=`$vi_cv_path_ruby -r mkmf -e 'print Config::CONFIG[["rubyhdrdir"]] || Config::CONFIG[["archdir"]] || $hdrdir' 2>/dev/null` + if test "X$rubyhdrdir" != "X"; then + AC_MSG_RESULT($rubyhdrdir) + RUBY_CFLAGS="-I$rubyhdrdir" +! rubyarch=`$vi_cv_path_ruby -r rbconfig -e 'print Config::CONFIG[["arch"]]'` + if test -d "$rubyhdrdir/$rubyarch"; then + RUBY_CFLAGS="$RUBY_CFLAGS -I$rubyhdrdir/$rubyarch" + fi +! rubyversion=`$vi_cv_path_ruby -r rbconfig -e 'print Config::CONFIG[["ruby_version"]].gsub(/\./, "")[[0,2]]'` + RUBY_CFLAGS="$RUBY_CFLAGS -DRUBY_VERSION=$rubyversion" +! rubylibs=`$vi_cv_path_ruby -r rbconfig -e 'print Config::CONFIG[["LIBS"]]'` + if test "X$rubylibs" != "X"; then + RUBY_LIBS="$rubylibs" + fi +! librubyarg=`$vi_cv_path_ruby -r rbconfig -e 'print Config.expand(Config::CONFIG[["LIBRUBYARG"]])'` +! librubya=`$vi_cv_path_ruby -r rbconfig -e 'print Config.expand(Config::CONFIG[["LIBRUBY_A"]])'` +! rubylibdir=`$vi_cv_path_ruby -r rbconfig -e 'print Config.expand(Config::CONFIG[["libdir"]])'` + if test -f "$rubylibdir/$librubya"; then + librubyarg="$librubyarg" + RUBY_LIBS="$RUBY_LIBS -L$rubylibdir" +--- 1442,1471 ---- + AC_MSG_CHECKING(Ruby version) + if $vi_cv_path_ruby -e '(VERSION rescue RUBY_VERSION) >= "1.6.0" or exit 1' >/dev/null 2>/dev/null; then + AC_MSG_RESULT(OK) ++ AC_MSG_CHECKING(Ruby rbconfig) ++ ruby_rbconfig="RbConfig" ++ if ! $vi_cv_path_ruby -r rbconfig -e 'RbConfig' >/dev/null 2>/dev/null; then ++ ruby_rbconfig="Config" ++ fi ++ AC_MSG_RESULT($ruby_rbconfig) + AC_MSG_CHECKING(Ruby header files) +! rubyhdrdir=`$vi_cv_path_ruby -r mkmf -e "print $ruby_rbconfig::CONFIG[['rubyhdrdir']] || $ruby_rbconfig::CONFIG[['archdir']] || \\$hdrdir" 2>/dev/null` + if test "X$rubyhdrdir" != "X"; then + AC_MSG_RESULT($rubyhdrdir) + RUBY_CFLAGS="-I$rubyhdrdir" +! rubyarch=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG[['arch']]"` + if test -d "$rubyhdrdir/$rubyarch"; then + RUBY_CFLAGS="$RUBY_CFLAGS -I$rubyhdrdir/$rubyarch" + fi +! rubyversion=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG[['ruby_version']].gsub(/\./, '')[[0,2]]"` + RUBY_CFLAGS="$RUBY_CFLAGS -DRUBY_VERSION=$rubyversion" +! rubylibs=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG[['LIBS']]"` + if test "X$rubylibs" != "X"; then + RUBY_LIBS="$rubylibs" + fi +! librubyarg=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG[['LIBRUBYARG']])"` +! librubya=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG[['LIBRUBY_A']])"` +! rubylibdir=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG[['libdir']])"` + if test -f "$rubylibdir/$librubya"; then + librubyarg="$librubyarg" + RUBY_LIBS="$RUBY_LIBS -L$rubylibdir" +*************** +*** 1472,1478 **** + if test "X$librubyarg" != "X"; then + RUBY_LIBS="$librubyarg $RUBY_LIBS" + fi +! rubyldflags=`$vi_cv_path_ruby -r rbconfig -e 'print Config::CONFIG[["LDFLAGS"]]'` + if test "X$rubyldflags" != "X"; then + dnl Ruby on Mac OS X 10.5 adds "-arch" flags but these should only + dnl be included if requested by passing --with-mac-arch to +--- 1478,1484 ---- + if test "X$librubyarg" != "X"; then + RUBY_LIBS="$librubyarg $RUBY_LIBS" + fi +! rubyldflags=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG[['LDFLAGS']]"` + if test "X$rubyldflags" != "X"; then + dnl Ruby on Mac OS X 10.5 adds "-arch" flags but these should only + dnl be included if requested by passing --with-mac-arch to +*************** +*** 1487,1493 **** + RUBY_PRO="if_ruby.pro" + AC_DEFINE(FEAT_RUBY) + if test "$enable_rubyinterp" = "dynamic"; then +! libruby=`$vi_cv_path_ruby -r rbconfig -e 'puts Config::CONFIG[["LIBRUBY_SO"]]'` + AC_DEFINE(DYNAMIC_RUBY) + RUBY_CFLAGS="-DDYNAMIC_RUBY_DLL=\\\"$libruby\\\" -DDYNAMIC_RUBY_VER=$rubyversion $RUBY_CFLAGS" + RUBY_LIBS= +--- 1493,1499 ---- + RUBY_PRO="if_ruby.pro" + AC_DEFINE(FEAT_RUBY) + if test "$enable_rubyinterp" = "dynamic"; then +! libruby=`$vi_cv_path_ruby -r rbconfig -e "puts $ruby_rbconfig::CONFIG[['LIBRUBY_SO']]"` + AC_DEFINE(DYNAMIC_RUBY) + RUBY_CFLAGS="-DDYNAMIC_RUBY_DLL=\\\"$libruby\\\" -DDYNAMIC_RUBY_VER=$rubyversion $RUBY_CFLAGS" + RUBY_LIBS= +*** ../vim-7.3.678/src/auto/configure 2012-10-03 18:49:55.000000000 +0200 +--- src/auto/configure 2012-10-03 18:51:38.000000000 +0200 +*************** +*** 6332,6357 **** + if $vi_cv_path_ruby -e '(VERSION rescue RUBY_VERSION) >= "1.6.0" or exit 1' >/dev/null 2>/dev/null; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: OK" >&5 + $as_echo "OK" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking Ruby header files" >&5 + $as_echo_n "checking Ruby header files... " >&6; } +! rubyhdrdir=`$vi_cv_path_ruby -r mkmf -e 'print Config::CONFIG["rubyhdrdir"] || Config::CONFIG["archdir"] || $hdrdir' 2>/dev/null` + if test "X$rubyhdrdir" != "X"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $rubyhdrdir" >&5 + $as_echo "$rubyhdrdir" >&6; } + RUBY_CFLAGS="-I$rubyhdrdir" +! rubyarch=`$vi_cv_path_ruby -r rbconfig -e 'print Config::CONFIG["arch"]'` + if test -d "$rubyhdrdir/$rubyarch"; then + RUBY_CFLAGS="$RUBY_CFLAGS -I$rubyhdrdir/$rubyarch" + fi +! rubyversion=`$vi_cv_path_ruby -r rbconfig -e 'print Config::CONFIG["ruby_version"].gsub(/\./, "")[0,2]'` + RUBY_CFLAGS="$RUBY_CFLAGS -DRUBY_VERSION=$rubyversion" +! rubylibs=`$vi_cv_path_ruby -r rbconfig -e 'print Config::CONFIG["LIBS"]'` + if test "X$rubylibs" != "X"; then + RUBY_LIBS="$rubylibs" + fi +! librubyarg=`$vi_cv_path_ruby -r rbconfig -e 'print Config.expand(Config::CONFIG["LIBRUBYARG"])'` +! librubya=`$vi_cv_path_ruby -r rbconfig -e 'print Config.expand(Config::CONFIG["LIBRUBY_A"])'` +! rubylibdir=`$vi_cv_path_ruby -r rbconfig -e 'print Config.expand(Config::CONFIG["libdir"])'` + if test -f "$rubylibdir/$librubya"; then + librubyarg="$librubyarg" + RUBY_LIBS="$RUBY_LIBS -L$rubylibdir" +--- 6332,6365 ---- + if $vi_cv_path_ruby -e '(VERSION rescue RUBY_VERSION) >= "1.6.0" or exit 1' >/dev/null 2>/dev/null; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: OK" >&5 + $as_echo "OK" >&6; } ++ { $as_echo "$as_me:${as_lineno-$LINENO}: checking Ruby rbconfig" >&5 ++ $as_echo_n "checking Ruby rbconfig... " >&6; } ++ ruby_rbconfig="RbConfig" ++ if ! $vi_cv_path_ruby -r rbconfig -e 'RbConfig' >/dev/null 2>/dev/null; then ++ ruby_rbconfig="Config" ++ fi ++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ruby_rbconfig" >&5 ++ $as_echo "$ruby_rbconfig" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking Ruby header files" >&5 + $as_echo_n "checking Ruby header files... " >&6; } +! rubyhdrdir=`$vi_cv_path_ruby -r mkmf -e "print $ruby_rbconfig::CONFIG['rubyhdrdir'] || $ruby_rbconfig::CONFIG['archdir'] || \\$hdrdir" 2>/dev/null` + if test "X$rubyhdrdir" != "X"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $rubyhdrdir" >&5 + $as_echo "$rubyhdrdir" >&6; } + RUBY_CFLAGS="-I$rubyhdrdir" +! rubyarch=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG['arch']"` + if test -d "$rubyhdrdir/$rubyarch"; then + RUBY_CFLAGS="$RUBY_CFLAGS -I$rubyhdrdir/$rubyarch" + fi +! rubyversion=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG['ruby_version'].gsub(/\./, '')[0,2]"` + RUBY_CFLAGS="$RUBY_CFLAGS -DRUBY_VERSION=$rubyversion" +! rubylibs=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG['LIBS']"` + if test "X$rubylibs" != "X"; then + RUBY_LIBS="$rubylibs" + fi +! librubyarg=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG['LIBRUBYARG'])"` +! librubya=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG['LIBRUBY_A'])"` +! rubylibdir=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG['libdir'])"` + if test -f "$rubylibdir/$librubya"; then + librubyarg="$librubyarg" + RUBY_LIBS="$RUBY_LIBS -L$rubylibdir" +*************** +*** 6363,6369 **** + if test "X$librubyarg" != "X"; then + RUBY_LIBS="$librubyarg $RUBY_LIBS" + fi +! rubyldflags=`$vi_cv_path_ruby -r rbconfig -e 'print Config::CONFIG["LDFLAGS"]'` + if test "X$rubyldflags" != "X"; then + rubyldflags=`echo "$rubyldflags" | sed -e 's/-arch\ ppc//' -e 's/-arch\ i386//' -e 's/-arch\ x86_64//'` + if test "X$rubyldflags" != "X"; then +--- 6371,6377 ---- + if test "X$librubyarg" != "X"; then + RUBY_LIBS="$librubyarg $RUBY_LIBS" + fi +! rubyldflags=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG['LDFLAGS']"` + if test "X$rubyldflags" != "X"; then + rubyldflags=`echo "$rubyldflags" | sed -e 's/-arch\ ppc//' -e 's/-arch\ i386//' -e 's/-arch\ x86_64//'` + if test "X$rubyldflags" != "X"; then +*************** +*** 6376,6382 **** + $as_echo "#define FEAT_RUBY 1" >>confdefs.h + + if test "$enable_rubyinterp" = "dynamic"; then +! libruby=`$vi_cv_path_ruby -r rbconfig -e 'puts Config::CONFIG["LIBRUBY_SO"]'` + $as_echo "#define DYNAMIC_RUBY 1" >>confdefs.h + + RUBY_CFLAGS="-DDYNAMIC_RUBY_DLL=\\\"$libruby\\\" -DDYNAMIC_RUBY_VER=$rubyversion $RUBY_CFLAGS" +--- 6384,6390 ---- + $as_echo "#define FEAT_RUBY 1" >>confdefs.h + + if test "$enable_rubyinterp" = "dynamic"; then +! libruby=`$vi_cv_path_ruby -r rbconfig -e "puts $ruby_rbconfig::CONFIG['LIBRUBY_SO']"` + $as_echo "#define DYNAMIC_RUBY 1" >>confdefs.h + + RUBY_CFLAGS="-DDYNAMIC_RUBY_DLL=\\\"$libruby\\\" -DDYNAMIC_RUBY_VER=$rubyversion $RUBY_CFLAGS" +*** ../vim-7.3.678/src/version.c 2012-10-03 18:49:55.000000000 +0200 +--- src/version.c 2012-10-03 21:08:31.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 679, + /**/ + +-- +Close your shells, or I'll kill -9 you +Tomorrow I'll quota you +Remember the disks'll always be full +And then while I'm away +I'll write ~ everyday +And I'll send-pr all my buggings to you. + [ CVS log "Beatles style" for FreeBSD ports/INDEX, Satoshi Asami ] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5247819f1f832bbdffcd62aa66240b83527aa6b8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:36 +0200 Subject: [PATCH 0515/3340] - patchlevel 680 --- 7.3.680 | 70 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 7.3.680 diff --git a/7.3.680 b/7.3.680 new file mode 100644 index 00000000..537eb587 --- /dev/null +++ b/7.3.680 @@ -0,0 +1,70 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.680 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.680 +Problem: Some files missing in the list of distributed files. +Solution: Add lines for new files. +Files: Filelist + + +*** ../vim-7.3.679/Filelist 2012-08-29 14:18:26.000000000 +0200 +--- Filelist 2012-09-21 14:53:59.000000000 +0200 +*************** +*** 261,266 **** +--- 261,267 ---- + src/Make_mvc.mak \ + src/Make_w16.mak \ + src/bigvim.bat \ ++ src/bigvim64.bat \ + src/msvcsetup.bat \ + src/msvc2008.bat \ + src/msvc2010.bat \ +*************** +*** 352,357 **** +--- 353,359 ---- + src/xpm/COPYRIGHT \ + src/xpm/README.txt \ + src/xpm/include/*.h \ ++ src/xpm/x64/lib/libXpm.a \ + src/xpm/x64/lib/libXpm.lib \ + src/xpm/x86/lib/libXpm.a \ + src/xpm/x86/lib/libXpm.lib \ +*************** +*** 692,697 **** +--- 694,700 ---- + runtime/tutor/tutor.utf-8 \ + runtime/tutor/tutor.?? \ + runtime/tutor/tutor.??.* \ ++ runtime/tutor/tutor.??_??.* \ + runtime/tutor/tutor.bar \ + runtime/tutor/tutor.bar.* \ + runtime/spell/README.txt \ +*** ../vim-7.3.679/src/version.c 2012-10-03 21:09:33.000000000 +0200 +--- src/version.c 2012-10-03 21:32:38.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 680, + /**/ + +-- +So when I saw the post to comp.editors, I rushed over to the FTP site to +grab it. So I yank apart the tarball, light x candles, where x= the +vim version multiplied by the md5sum of the source divided by the MAC of +my NIC (8A3FA78155A8A1D346C3C4A), put on black robes, dim the lights, +wave a dead chicken over the hard drive, and summon the power of GNU GCC +with the magic words "make config ; make!". + [Jason Spence, compiling Vim 5.0] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 29cb0acafb18882a87d5c04ca1c1067fa4570d06 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:37 +0200 Subject: [PATCH 0516/3340] - patchlevel 681 --- 7.3.681 | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 7.3.681 diff --git a/7.3.681 b/7.3.681 new file mode 100644 index 00000000..7794ce09 --- /dev/null +++ b/7.3.681 @@ -0,0 +1,64 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.681 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.681 (after 7.3.680) +Problem: List of distributed files picks up backup files. +Solution: Make tutor patterns more specific. +Files: Filelist + + +*** ../vim-7.3.680/Filelist 2012-10-03 21:33:37.000000000 +0200 +--- Filelist 2012-10-03 21:44:29.000000000 +0200 +*************** +*** 693,702 **** + runtime/tutor/Makefile \ + runtime/tutor/tutor.utf-8 \ + runtime/tutor/tutor.?? \ +! runtime/tutor/tutor.??.* \ +! runtime/tutor/tutor.??_??.* \ + runtime/tutor/tutor.bar \ +! runtime/tutor/tutor.bar.* \ + runtime/spell/README.txt \ + runtime/spell/??/*.diff \ + runtime/spell/??/main.aap \ +--- 693,709 ---- + runtime/tutor/Makefile \ + runtime/tutor/tutor.utf-8 \ + runtime/tutor/tutor.?? \ +! runtime/tutor/tutor.??.utf-8 \ +! runtime/tutor/tutor.??.euc \ +! runtime/tutor/tutor.??.sjis \ +! runtime/tutor/tutor.??.iso9 \ +! runtime/tutor/tutor.??.big5 \ +! runtime/tutor/tutor.??.cp1250 \ +! runtime/tutor/tutor.??.cp1251 \ +! runtime/tutor/tutor.??.cp737 \ +! runtime/tutor/tutor.??_??.utf-8 \ + runtime/tutor/tutor.bar \ +! runtime/tutor/tutor.bar.utf-8 \ + runtime/spell/README.txt \ + runtime/spell/??/*.diff \ + runtime/spell/??/main.aap \ +*** ../vim-7.3.680/src/version.c 2012-10-03 21:33:37.000000000 +0200 +--- src/version.c 2012-10-03 21:48:04.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 681, + /**/ + +-- +Zen Microsystems: we're the om in .commmmmmmmm + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e873ec2d9e2ca7e534df8c22307baff458535cc7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:39 +0200 Subject: [PATCH 0517/3340] - patchlevel 682 --- 7.3.682 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.682 diff --git a/7.3.682 b/7.3.682 new file mode 100644 index 00000000..a8e133e7 --- /dev/null +++ b/7.3.682 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.682 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.682 (after 7.3.677) +Problem: Compiler complains about incompatible types. +Solution: Remove type casts. (hint by Danek Duvall) +Files: src/edit.c + + +*** ../vim-7.3.681/src/edit.c 2012-08-08 18:01:00.000000000 +0200 +--- src/edit.c 2012-10-04 22:33:22.000000000 +0200 +*************** +*** 4194,4201 **** + ins_buf->b_fname == NULL + ? buf_spname(ins_buf) + : ins_buf->b_sfname == NULL +! ? (char *)ins_buf->b_fname +! : (char *)ins_buf->b_sfname); + (void)msg_trunc_attr(IObuff, TRUE, hl_attr(HLF_R)); + } + else if (*e_cpt == NUL) +--- 4194,4201 ---- + ins_buf->b_fname == NULL + ? buf_spname(ins_buf) + : ins_buf->b_sfname == NULL +! ? ins_buf->b_fname +! : ins_buf->b_sfname); + (void)msg_trunc_attr(IObuff, TRUE, hl_attr(HLF_R)); + } + else if (*e_cpt == NUL) +*** ../vim-7.3.681/src/version.c 2012-10-03 21:48:38.000000000 +0200 +--- src/version.c 2012-10-04 22:36:15.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 682, + /**/ + +-- +Dogs must have a permit signed by the mayor in order to congregate in groups +of three or more on private property. + [real standing law in Oklahoma, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From acfd5fdb8c92736ff4c370c28d59d0ff0e714d0b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 00:36:41 +0200 Subject: [PATCH 0518/3340] - patchlevel 682 --- README.patches | 44 +++++++++++++++++++++++ vim.spec | 95 ++++++++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 137 insertions(+), 2 deletions(-) diff --git a/README.patches b/README.patches index dfe8b806..cb9e52ec 100644 --- a/README.patches +++ b/README.patches @@ -669,3 +669,47 @@ Individual patches for Vim 7.3: 4539 7.3.636 (after 7.3.625) "gn" fails for some zero-width matches 3117 7.3.637 cannot catch error caused by a foldopen when there is no fold 1783 7.3.638 unecessary redraw of the previous character + 31440 7.3.639 it's not easy to build Vim on Windows with XPM support +455297 7.3.640 binary files for 7.3.639 + 2219 7.3.641 ":mkview" uses ":normal" instead of ":normal!" for folds + 1810 7.3.642 segfault with specific autocommands + 2060 7.3.643 MS-Windows: 'lines' is wrong when starting up maximized + 1925 7.3.644 dead code for BeOS GUI + 2910 7.3.645 no tests for patch 7.3.625 and 7.3.637 + 2353 7.3.646 undo file unusable after reloading a buffer + 5213 7.3.647 "gnd" doesn't work correctly in Visual mode + 3831 7.3.648 crash when using a very long file name + 2256 7.3.649 with 'clipboard' set to "unnamed" small deletes go to "1 + 1679 7.3.650 Completing ":help \{-" gives error and messes up command line + 3120 7.3.651 Completing ":help \{-" gives error message + 2304 7.3.652 workaround for Python crash isn't perfect + 7986 7.3.653 lacking XPM support for MingW, 32 and 64 objects mixed up + 3301 7.3.654 creating Vim dictionary from Python an empty key might be used + 88812 7.3.655 64 bit MingW xpm .a file is missing + 3106 7.3.656 internal error in :pyeval + 6680 7.3.657 Python bindings silently truncate string values containing NUL + 4244 7.3.658 NUL bytes truncate strings when converted from Python + 6242 7.3.659 recent Python changes are not tested + 1448 7.3.660 ":help !" jumps to help for ":!" + 5339 7.3.661 (after 7.3.652) SEGV in Python code + 3126 7.3.662 can't build Ruby interface with Ruby 1.9.3 + 1498 7.3.663 end of color scheme name not clear in E185 + 2171 7.3.664 buffer overflow in unescaping multi-byte characters + 2414 7.3.665 MSVC 11 is not supported + 3195 7.3.666 Win32.mak can't be found + 3213 7.3.667 unused variables in Perl interface + 2763 7.3.668 loading Perl dynamically still uses static library + 4757 7.3.669 when building with Cygwin loading Python dynamically fails + 2318 7.3.670 tiny memory leak when throwing exception in Python + 8213 7.3.671 more Python code can be shared between Python 2 and 3 + 22436 7.3.672 not possible to lock/unlock lists in Python interface + 1967 7.3.673 "gN" while 'selection' is "exclusive" misses one character + 10873 7.3.674 can't compile with Lua/dyn on Cygwin + 1597 7.3.675 accessing uninitialized memory with a very long file name + 2721 7.3.676 Ruby compilation on Windows 32 bit doesn't work + 8428 7.3.677 buf_spname() is used inconsistently + 2887 7.3.678 Ruby .so name may not be correct + 11455 7.3.679 Ruby detection uses Config, newer Ruby versions use RbConfig + 2190 7.3.680 some files missing in the list of distributed files + 2014 7.3.681 list of distributed files picks up backup files + 1791 7.3.682 (after 7.3.677) compiler complains about incompatible types diff --git a/vim.spec b/vim.spec index 527c445e..f65aa0c9 100644 --- a/vim.spec +++ b/vim.spec @@ -18,13 +18,13 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 638 +%define patchlevel 682 Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 2%{?dist} +Release: 1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -694,6 +694,50 @@ Patch635: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.635 Patch636: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.636 Patch637: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.637 Patch638: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.638 +Patch639: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.639 +Patch640: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.640 +Patch641: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.641 +Patch642: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.642 +Patch643: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.643 +Patch644: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.644 +Patch645: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.645 +Patch646: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.646 +Patch647: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.647 +Patch648: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.648 +Patch649: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.649 +Patch650: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.650 +Patch651: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.651 +Patch652: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.652 +Patch653: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.653 +Patch654: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.654 +Patch655: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.655 +Patch656: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.656 +Patch657: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.657 +Patch658: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.658 +Patch659: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.659 +Patch660: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.660 +Patch661: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.661 +Patch662: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.662 +Patch663: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.663 +Patch664: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.664 +Patch665: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.665 +Patch666: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.666 +Patch667: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.667 +Patch668: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.668 +Patch669: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.669 +Patch670: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.670 +Patch671: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.671 +Patch672: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.672 +Patch673: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.673 +Patch674: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.674 +Patch675: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.675 +Patch676: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.676 +Patch677: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.677 +Patch678: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.678 +Patch679: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.679 +Patch680: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.680 +Patch681: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.681 +Patch682: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.682 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1478,6 +1522,50 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch636 -p0 %patch637 -p0 %patch638 -p0 +%patch639 -p0 +%patch640 -p0 +%patch641 -p0 +%patch642 -p0 +%patch643 -p0 +%patch644 -p0 +%patch645 -p0 +%patch646 -p0 +%patch647 -p0 +%patch648 -p0 +%patch649 -p0 +%patch650 -p0 +%patch651 -p0 +%patch652 -p0 +%patch653 -p0 +%patch654 -p0 +%patch655 -p0 +%patch656 -p0 +%patch657 -p0 +%patch658 -p0 +%patch659 -p0 +%patch660 -p0 +%patch661 -p0 +%patch662 -p0 +%patch663 -p0 +%patch664 -p0 +%patch665 -p0 +%patch666 -p0 +%patch667 -p0 +%patch668 -p0 +%patch669 -p0 +%patch670 -p0 +%patch671 -p0 +%patch672 -p0 +%patch673 -p0 +%patch674 -p0 +%patch675 -p0 +%patch676 -p0 +%patch677 -p0 +%patch678 -p0 +%patch679 -p0 +%patch680 -p0 +%patch681 -p0 +%patch682 -p0 # install spell files @@ -1935,6 +2023,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Fri Oct 05 2012 Karsten Hopp 7.3.682-1 +- patchlevel 682 + * Tue Aug 28 2012 Karsten Hopp 7.3.638-2 - fix some man page typos (#668894, #675480) - own usr/share/vim/vimfiles/doc/tags (#845564) From 20a9c5ed5805cc84ca54cc020e2cc0e57d434c18 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 5 Oct 2012 01:10:55 +0200 Subject: [PATCH 0519/3340] use --enable-rubyinterp=dynamic and --enable-pythoninterp=dynamic --- vim.spec | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/vim.spec b/vim.spec index f65aa0c9..927813fc 100644 --- a/vim.spec +++ b/vim.spec @@ -1596,7 +1596,9 @@ mv -f Makefile.tmp Makefile export CFLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2" export CXXFLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2" -%configure --with-features=huge --enable-pythoninterp --enable-perlinterp \ +%configure --with-features=huge \ + --enable-pythoninterp=dynamic \ + --enable-perlinterp \ --disable-tclinterp --with-x=yes \ --enable-xim --enable-multibyte \ --with-tlib=ncurses \ @@ -1614,7 +1616,7 @@ export CXXFLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_ --disable-selinux \ %endif %if "%{withruby}" == "1" - --enable-rubyinterp \ + --enable-rubyinterp=dynamic \ %else --disable-rubyinterp \ %endif @@ -1623,8 +1625,11 @@ make VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} %{?_smp_mflags} cp vim gvim make clean -%configure --prefix=%{_prefix} --with-features=huge --enable-pythoninterp \ - --enable-perlinterp --disable-tclinterp --with-x=no \ +%configure --prefix=%{_prefix} --with-features=huge \ + --enable-pythoninterp=dynamic \ + --enable-perlinterp \ + --disable-tclinterp \ + --with-x=no \ --enable-gui=no --exec-prefix=%{_prefix} --enable-multibyte \ --enable-cscope --with-modified-by="" \ --with-tlib=ncurses \ @@ -1640,7 +1645,7 @@ make clean --disable-selinux \ %endif %if "%{withruby}" == "1" - --enable-rubyinterp \ + --enable-rubyinterp=dynamic \ %else --disable-rubyinterp \ %endif @@ -2025,6 +2030,7 @@ rm -rf $RPM_BUILD_ROOT %changelog * Fri Oct 05 2012 Karsten Hopp 7.3.682-1 - patchlevel 682 +- use --enable-rubyinterp=dynamic and --enable-pythoninterp=dynamic * Tue Aug 28 2012 Karsten Hopp 7.3.638-2 - fix some man page typos (#668894, #675480) From 4e9c0a0e1c3a92a9685d2da1d7d6fc2e6f3fa97f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Oct 2012 12:16:58 +0200 Subject: [PATCH 0520/3340] remove erroneous cd command --- vim-update.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/vim-update.sh b/vim-update.sh index dd8c34ba..6ef30d8b 100755 --- a/vim-update.sh +++ b/vim-update.sh @@ -2,7 +2,6 @@ debug="" #debug="echo" -cd $HOME/src/fedora/rpms/vim/master/ LANG=C SPEC=vim.spec From 09c09e364a9f1385725fe66c0d179b704b588f5f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Oct 2012 12:17:36 +0200 Subject: [PATCH 0521/3340] - patchlevel 683 --- 7.3.683 | 88 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 88 insertions(+) create mode 100644 7.3.683 diff --git a/7.3.683 b/7.3.683 new file mode 100644 index 00000000..b26d3980 --- /dev/null +++ b/7.3.683 @@ -0,0 +1,88 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.683 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.683 +Problem: ":python" may crash when vimbindeval() returns None. +Solution: Check for v_string to be NULL. (Yukihiro Nakadaira) +Files: src/if_py_both.h + + +*** ../vim-7.3.682/src/if_py_both.h 2012-09-21 14:00:05.000000000 +0200 +--- src/if_py_both.h 2012-10-05 21:05:06.000000000 +0200 +*************** +*** 351,357 **** + + if (our_tv->v_type == VAR_STRING) + { +! result = Py_BuildValue("s", our_tv->vval.v_string); + } + else if (our_tv->v_type == VAR_NUMBER) + { +--- 351,358 ---- + + if (our_tv->v_type == VAR_STRING) + { +! result = Py_BuildValue("s", our_tv->vval.v_string == NULL +! ? "" : (char *)our_tv->vval.v_string); + } + else if (our_tv->v_type == VAR_NUMBER) + { +*************** +*** 2751,2757 **** + switch (tv->v_type) + { + case VAR_STRING: +! return PyBytes_FromString((char *) tv->vval.v_string); + case VAR_NUMBER: + return PyLong_FromLong((long) tv->vval.v_number); + #ifdef FEAT_FLOAT +--- 2752,2759 ---- + switch (tv->v_type) + { + case VAR_STRING: +! return PyBytes_FromString(tv->vval.v_string == NULL +! ? "" : (char *)tv->vval.v_string); + case VAR_NUMBER: + return PyLong_FromLong((long) tv->vval.v_number); + #ifdef FEAT_FLOAT +*************** +*** 2763,2769 **** + case VAR_DICT: + return DictionaryNew(tv->vval.v_dict); + case VAR_FUNC: +! return FunctionNew(tv->vval.v_string); + case VAR_UNKNOWN: + Py_INCREF(Py_None); + return Py_None; +--- 2765,2772 ---- + case VAR_DICT: + return DictionaryNew(tv->vval.v_dict); + case VAR_FUNC: +! return FunctionNew(tv->vval.v_string == NULL +! ? (char_u *)"" : tv->vval.v_string); + case VAR_UNKNOWN: + Py_INCREF(Py_None); + return Py_None; +*** ../vim-7.3.682/src/version.c 2012-10-04 22:38:32.000000000 +0200 +--- src/version.c 2012-10-05 21:04:19.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 683, + /**/ + +-- +SIGIRO -- irony detected (iron core dumped) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 502c3c420f25bd847e42b74518095d02c4b65a25 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Oct 2012 12:17:37 +0200 Subject: [PATCH 0522/3340] - patchlevel 684 --- 7.3.684 | 132 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 132 insertions(+) create mode 100644 7.3.684 diff --git a/7.3.684 b/7.3.684 new file mode 100644 index 00000000..0e9119be --- /dev/null +++ b/7.3.684 @@ -0,0 +1,132 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.684 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.684 +Problem: "make test" does not delete lua.vim. +Solution: Add lua.vim to the clean target. (Simon Ruderich) +Files: src/testdir/Makefile, src/testdir/Make_dos.mak, + src/testdir/Make_ming.mak, src/testdir/Make_vms.mms + + +*** ../vim-7.3.683/src/testdir/Makefile 2012-06-29 12:54:32.000000000 +0200 +--- src/testdir/Makefile 2012-10-06 19:04:54.000000000 +0200 +*************** +*** 48,57 **** + $(SCRIPTS) $(SCRIPTS_GUI): $(VIMPROG) + + clean: +! -rm -rf *.out *.failed *.rej *.orig test.log tiny.vim small.vim mbyte.vim mzscheme.vim test.ok X* valgrind.* viminfo + + test1.out: test1.in +! -rm -f $*.failed tiny.vim small.vim mbyte.vim mzscheme.vim test.ok X* viminfo + $(VALGRIND) $(VIMPROG) -u unix.vim -U NONE --noplugin -s dotest.in $*.in + @/bin/sh -c "if diff test.out $*.ok; \ + then mv -f test.out $*.out; \ +--- 48,57 ---- + $(SCRIPTS) $(SCRIPTS_GUI): $(VIMPROG) + + clean: +! -rm -rf *.out *.failed *.rej *.orig test.log tiny.vim small.vim mbyte.vim mzscheme.vim lua.vim test.ok X* valgrind.* viminfo + + test1.out: test1.in +! -rm -f $*.failed tiny.vim small.vim mbyte.vim mzscheme.vim lua.vim test.ok X* viminfo + $(VALGRIND) $(VIMPROG) -u unix.vim -U NONE --noplugin -s dotest.in $*.in + @/bin/sh -c "if diff test.out $*.ok; \ + then mv -f test.out $*.out; \ +*************** +*** 73,79 **** + fi \ + else echo $* NO OUTPUT >>test.log; \ + fi" +! # -rm -rf X* test.ok viminfo + + test49.out: test49.vim + +--- 73,79 ---- + fi \ + else echo $* NO OUTPUT >>test.log; \ + fi" +! -rm -rf X* test.ok viminfo + + test49.out: test49.vim + +*** ../vim-7.3.683/src/testdir/Make_dos.mak 2012-06-29 12:54:32.000000000 +0200 +--- src/testdir/Make_dos.mak 2012-10-06 19:04:02.000000000 +0200 +*************** +*** 62,67 **** +--- 62,68 ---- + -if exist tiny.vim del tiny.vim + -if exist mbyte.vim del mbyte.vim + -if exist mzscheme.vim del mzscheme.vim ++ -if exist lua.vim del lua.vim + -del X* + -if exist viminfo del viminfo + +*** ../vim-7.3.683/src/testdir/Make_ming.mak 2012-06-29 12:54:32.000000000 +0200 +--- src/testdir/Make_ming.mak 2012-10-06 19:04:08.000000000 +0200 +*************** +*** 85,90 **** +--- 85,91 ---- + -$(DEL) tiny.vim + -$(DEL) mbyte.vim + -$(DEL) mzscheme.vim ++ -$(DEL) lua.vim + -$(DEL) X* + -$(DEL) viminfo + +*** ../vim-7.3.683/src/testdir/Make_vms.mms 2012-04-05 16:56:38.000000000 +0200 +--- src/testdir/Make_vms.mms 2012-10-06 19:04:34.000000000 +0200 +*************** +*** 4,10 **** + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2012 Apr 05 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +--- 4,10 ---- + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2012 Oct 06 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +*************** +*** 184,188 **** +--- 184,189 ---- + -@ if "''F$SEARCH("small.vim")'" .NES. "" then delete/noconfirm/nolog small.vim.* + -@ if "''F$SEARCH("mbyte.vim")'" .NES. "" then delete/noconfirm/nolog mbyte.vim.* + -@ if "''F$SEARCH("mzscheme.vim")'" .NES. "" then delete/noconfirm/nolog mzscheme.vim.* ++ -@ if "''F$SEARCH("lua.vim")'" .NES. "" then delete/noconfirm/nolog lua.vim.* + -@ if "''F$SEARCH("viminfo.*")'" .NES. "" then delete/noconfirm/nolog viminfo.*.* + +*** ../vim-7.3.683/src/version.c 2012-10-05 21:30:04.000000000 +0200 +--- src/version.c 2012-10-06 18:59:40.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 684, + /**/ + +-- +ERIC IDLE PLAYED: THE DEAD COLLECTOR, MR BINT (A VILLAGE NE'ER-DO -WELL VERY + KEEN ON BURNING WITCHES), SIR ROBIN, THE GUARD WHO DOESN'T + HICOUGH BUT TRIES TO GET THINGS STRAIGHT, CONCORDE (SIR + LAUNCELOT'S TRUSTY STEED), ROGER THE SHRUBBER (A SHRUBBER), + BROTHER MAYNARD + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8eff41f5c8c251f66eb8c016064da695219321bb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Oct 2012 12:17:38 +0200 Subject: [PATCH 0523/3340] - patchlevel 685 --- 7.3.685 | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 7.3.685 diff --git a/7.3.685 b/7.3.685 new file mode 100644 index 00000000..58cf4e94 --- /dev/null +++ b/7.3.685 @@ -0,0 +1,64 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.685 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.685 +Problem: No test for what patch 7.3.673 fixes. +Solution: Add a test. (Christian Brabandt) +Files: src/testdir/test53.in, src/testdir/test53.ok + + +*** ../vim-7.3.684/src/testdir/test53.in 2012-09-05 12:16:40.000000000 +0200 +--- src/testdir/test53.in 2012-10-11 03:31:27.000000000 +0200 +*************** +*** 42,47 **** +--- 42,50 ---- + gnd$h/\zs + gnd/[u]niquepattern/s + vlgnd ++ /mother ++ :set selection=exclusive ++ $cgNmongoose + :/^start:/,/^end:/wq! test.out + ENDTEST + +*************** +*** 69,72 **** +--- 72,76 ---- + zero width pattern + delete first and last chars + uniquepattern uniquepattern ++ my very excellent mother just served us nachos + end: +*** ../vim-7.3.684/src/testdir/test53.ok 2012-09-05 12:16:40.000000000 +0200 +--- src/testdir/test53.ok 2012-10-11 03:31:33.000000000 +0200 +*************** +*** 25,28 **** +--- 25,29 ---- + zerowidth pattern + elete first and last char + uniquepattern ++ my very excellent mongoose just served us nachos + end: +*** ../vim-7.3.684/src/version.c 2012-10-06 19:10:29.000000000 +0200 +--- src/version.c 2012-10-11 03:34:06.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 685, + /**/ + +-- +FATAL ERROR! SYSTEM HALTED! - Press any key to continue doing nothing. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1efe4be0e9093209d21a226c71d3dd100dd1e94c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Oct 2012 12:17:39 +0200 Subject: [PATCH 0524/3340] - patchlevel 686 --- 7.3.686 | 63 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 7.3.686 diff --git a/7.3.686 b/7.3.686 new file mode 100644 index 00000000..81d23696 --- /dev/null +++ b/7.3.686 @@ -0,0 +1,63 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.686 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.686 +Problem: Using CTRL-\ e mappings is useful also when entering an + expression, but it doesn't work. (Marcin Szamotulski) +Solution: Allow using CTRL-\ e when entering an expression if it was not + typed. +Files: src/ex_getln.c + + +*** ../vim-7.3.685/src/ex_getln.c 2012-08-15 14:04:50.000000000 +0200 +--- src/ex_getln.c 2012-10-11 03:54:04.000000000 +0200 +*************** +*** 667,675 **** + c = plain_vgetc(); + --no_mapping; + --allow_keys; +! /* CTRL-\ e doesn't work when obtaining an expression. */ +! if (c != Ctrl_N && c != Ctrl_G +! && (c != 'e' || ccline.cmdfirstc == '=')) + { + vungetc(c); + c = Ctrl_BSL; +--- 667,676 ---- + c = plain_vgetc(); + --no_mapping; + --allow_keys; +! /* CTRL-\ e doesn't work when obtaining an expression, unless it +! * is in a mapping. */ +! if (c != Ctrl_N && c != Ctrl_G && (c != 'e' +! || (ccline.cmdfirstc == '=' && KeyTyped))) + { + vungetc(c); + c = Ctrl_BSL; +*** ../vim-7.3.685/src/version.c 2012-10-11 03:35:38.000000000 +0200 +--- src/version.c 2012-10-11 04:03:19.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 686, + /**/ + +-- +(letter from Mark to Mike, about the film's probable certificate) + I would like to get back to the Censor and agree to lose the shits, take + the odd Jesus Christ out and lose Oh fuck off, but to retain 'fart in + your general direction', 'castanets of your testicles' and 'oral sex' + and ask him for an 'A' rating on that basis. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 168a9aaaf2c9945afb2d72ee6cda6a23f95aae6d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Oct 2012 12:17:40 +0200 Subject: [PATCH 0525/3340] - patchlevel 687 --- 7.3.687 | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 7.3.687 diff --git a/7.3.687 b/7.3.687 new file mode 100644 index 00000000..a98c3631 --- /dev/null +++ b/7.3.687 @@ -0,0 +1,44 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.687 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.687 +Problem: Test 16 fails when $DISPLAY is not set. +Solution: Skip the test when $DISPLAY is not set. +Files: src/testdir/test16.in + + +*** ../vim-7.3.686/src/testdir/test16.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test16.in 2012-10-11 04:02:11.000000000 +0200 +*************** +*** 2,7 **** +--- 2,8 ---- + For KDE set a font, empty 'guifont' may cause a hang. + + STARTTEST ++ :if $DISPLAY == "" | e! test.ok | wq! test.out | endif + :set exrc secure + :if has("gui_kde") + : set guifont=Courier\ 10\ Pitch/8/-1/5/50/0/0/0/0/0 +*** ../vim-7.3.686/src/version.c 2012-10-11 04:04:32.000000000 +0200 +--- src/version.c 2012-10-11 04:31:10.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 687, + /**/ + +-- +A fool must search for a greater fool to find admiration. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2c69c3db69e59012b4c14af12df4b5ebea74f974 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Oct 2012 12:17:41 +0200 Subject: [PATCH 0526/3340] - patchlevel 688 --- 7.3.688 | 150 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 150 insertions(+) create mode 100644 7.3.688 diff --git a/7.3.688 b/7.3.688 new file mode 100644 index 00000000..56f00249 --- /dev/null +++ b/7.3.688 @@ -0,0 +1,150 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.688 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.688 +Problem: Python 3.3 is not supported. +Solution: Add Python 3.3 support (Ken Takata) +Files: src/if_python3.c + + +*** ../vim-7.3.687/src/if_python3.c 2012-09-21 14:00:05.000000000 +0200 +--- src/if_python3.c 2012-10-14 03:19:53.000000000 +0200 +*************** +*** 174,180 **** + # define _PyObject_NextNotImplemented (*py3__PyObject_NextNotImplemented) + # define PyModule_AddObject py3_PyModule_AddObject + # define PyImport_AppendInittab py3_PyImport_AppendInittab +! # define _PyUnicode_AsString py3__PyUnicode_AsString + # undef PyUnicode_AsEncodedString + # define PyUnicode_AsEncodedString py3_PyUnicode_AsEncodedString + # undef PyBytes_AsString +--- 174,185 ---- + # define _PyObject_NextNotImplemented (*py3__PyObject_NextNotImplemented) + # define PyModule_AddObject py3_PyModule_AddObject + # define PyImport_AppendInittab py3_PyImport_AppendInittab +! # if PY_VERSION_HEX >= 0x030300f0 +! # undef _PyUnicode_AsString +! # define _PyUnicode_AsString py3_PyUnicode_AsUTF8String +! # else +! # define _PyUnicode_AsString py3__PyUnicode_AsString +! # endif + # undef PyUnicode_AsEncodedString + # define PyUnicode_AsEncodedString py3_PyUnicode_AsEncodedString + # undef PyBytes_AsString +*************** +*** 281,287 **** +--- 286,296 ---- + static PyObject* py3__Py_TrueStruct; + static int (*py3_PyModule_AddObject)(PyObject *m, const char *name, PyObject *o); + static int (*py3_PyImport_AppendInittab)(const char *name, PyObject* (*initfunc)(void)); ++ #if PY_VERSION_HEX >= 0x030300f0 ++ static char* (*py3_PyUnicode_AsUTF8String)(PyObject *unicode); ++ #else + static char* (*py3__PyUnicode_AsString)(PyObject *unicode); ++ #endif + static PyObject* (*py3_PyUnicode_AsEncodedString)(PyObject *unicode, const char* encoding, const char* errors); + static char* (*py3_PyBytes_AsString)(PyObject *bytes); + static int (*py3_PyBytes_AsStringAndSize)(PyObject *bytes, char **buffer, int *length); +*************** +*** 397,403 **** +--- 406,416 ---- + {"PyObject_Init", (PYTHON_PROC*)&py3__PyObject_Init}, + {"PyModule_AddObject", (PYTHON_PROC*)&py3_PyModule_AddObject}, + {"PyImport_AppendInittab", (PYTHON_PROC*)&py3_PyImport_AppendInittab}, ++ #if PY_VERSION_HEX >= 0x030300f0 ++ {"PyUnicode_AsUTF8String", (PYTHON_PROC*)&py3_PyUnicode_AsUTF8String}, ++ #else + {"_PyUnicode_AsString", (PYTHON_PROC*)&py3__PyUnicode_AsString}, ++ #endif + {"PyBytes_AsString", (PYTHON_PROC*)&py3_PyBytes_AsString}, + {"PyBytes_AsStringAndSize", (PYTHON_PROC*)&py3_PyBytes_AsStringAndSize}, + {"PyBytes_FromString", (PYTHON_PROC*)&py3_PyBytes_FromString}, +*************** +*** 490,495 **** +--- 503,514 ---- + + /* Load unicode functions separately as only the ucs2 or the ucs4 functions + * will be present in the library. */ ++ #if PY_VERSION_HEX >= 0x030300f0 ++ ucs_from_string = symbol_from_dll(hinstPy3, "PyUnicode_FromString"); ++ ucs_decode = symbol_from_dll(hinstPy3, "PyUnicode_Decode"); ++ ucs_as_encoded_string = symbol_from_dll(hinstPy3, ++ "PyUnicode_AsEncodedString"); ++ #else + ucs_from_string = symbol_from_dll(hinstPy3, "PyUnicodeUCS2_FromString"); + ucs_decode = symbol_from_dll(hinstPy3, + "PyUnicodeUCS2_Decode"); +*************** +*** 504,509 **** +--- 523,529 ---- + ucs_as_encoded_string = symbol_from_dll(hinstPy3, + "PyUnicodeUCS4_AsEncodedString"); + } ++ #endif + if (ucs_from_string && ucs_decode && ucs_as_encoded_string) + { + py3_PyUnicode_FromString = ucs_from_string; +*************** +*** 600,607 **** + + #define GET_ATTR_STRING(name, nameobj) \ + char *name = ""; \ +! if(PyUnicode_Check(nameobj)) \ +! name = _PyUnicode_AsString(nameobj) + + #define PY3OBJ_DELETED(obj) (obj->ob_base.ob_refcnt<=0) + +--- 620,627 ---- + + #define GET_ATTR_STRING(name, nameobj) \ + char *name = ""; \ +! if (PyUnicode_Check(nameobj)) \ +! name = _PyUnicode_AsString(nameobj) + + #define PY3OBJ_DELETED(obj) (obj->ob_base.ob_refcnt<=0) + +*************** +*** 704,709 **** +--- 724,731 ---- + Py_SetPythonHome(PYTHON3_HOME); + #endif + ++ PyImport_AppendInittab("vim", Py3Init_vim); ++ + #if !defined(MACOS) || defined(MACOS_X_UNIX) + Py_Initialize(); + #else +*************** +*** 719,726 **** + if (PythonIO_Init()) + goto fail; + +- PyImport_AppendInittab("vim", Py3Init_vim); +- + globals = PyModule_GetDict(PyImport_AddModule("__main__")); + + /* Remove the element from sys.path that was added because of our +--- 741,746 ---- +*** ../vim-7.3.687/src/version.c 2012-10-11 04:44:26.000000000 +0200 +--- src/version.c 2012-10-14 03:00:57.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 688, + /**/ + +-- +The problem with political jokes is that they get elected. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 641e09a2cd8afab91d142760ddcc8b19e54f049b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Oct 2012 12:17:42 +0200 Subject: [PATCH 0527/3340] - patchlevel 689 --- 7.3.689 | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 7.3.689 diff --git a/7.3.689 b/7.3.689 new file mode 100644 index 00000000..ae8e60d0 --- /dev/null +++ b/7.3.689 @@ -0,0 +1,72 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.689 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.689 +Problem: MzScheme and Lua may use a NULL string. +Solution: Use an empty string instead of NULL. (Yukihiro Nakadaira) +Files: src/if_lua.c, src/if_mzsch.c + + +*** ../vim-7.3.688/src/if_lua.c 2012-06-29 12:54:32.000000000 +0200 +--- src/if_lua.c 2012-10-14 03:33:32.000000000 +0200 +*************** +*** 464,470 **** + switch (tv->v_type) + { + case VAR_STRING: +! lua_pushstring(L, (char *) tv->vval.v_string); + break; + case VAR_NUMBER: + lua_pushinteger(L, (int) tv->vval.v_number); +--- 464,471 ---- + switch (tv->v_type) + { + case VAR_STRING: +! lua_pushstring(L, tv->vval.v_string == NULL +! ? "" : (char *)tv->vval.v_string); + break; + case VAR_NUMBER: + lua_pushinteger(L, (int) tv->vval.v_number); +*** ../vim-7.3.688/src/if_mzsch.c 2012-02-12 01:55:50.000000000 +0100 +--- src/if_mzsch.c 2012-10-14 03:33:32.000000000 +0200 +*************** +*** 2649,2655 **** + new_value = FALSE; + else if (vim_value->v_type == VAR_STRING) + { +! result = scheme_make_string((char *)vim_value->vval.v_string); + MZ_GC_CHECK(); + } + else if (vim_value->v_type == VAR_NUMBER) +--- 2649,2656 ---- + new_value = FALSE; + else if (vim_value->v_type == VAR_STRING) + { +! result = scheme_make_string(vim_value->vval.v_string == NULL +! ? "" : (char *)vim_value->vval.v_string); + MZ_GC_CHECK(); + } + else if (vim_value->v_type == VAR_NUMBER) +*** ../vim-7.3.688/src/version.c 2012-10-14 03:22:49.000000000 +0200 +--- src/version.c 2012-10-14 03:33:49.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 689, + /**/ + +-- +Computers make very fast, very accurate, mistakes. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1068bbab081dd8e8aaf8ff9488f2a34f6d63cac7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Oct 2012 12:17:43 +0200 Subject: [PATCH 0528/3340] - patchlevel 690 --- 7.3.690 | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 7.3.690 diff --git a/7.3.690 b/7.3.690 new file mode 100644 index 00000000..c638e26f --- /dev/null +++ b/7.3.690 @@ -0,0 +1,68 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.690 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.690 +Problem: When the current directory name is exactly the maximum path length + Vim may crash. +Solution: Only add "/" when there is room. (Danek Duvall) +Files: src/os_unix.c + + +*** ../vim-7.3.689/src/os_unix.c 2012-08-15 17:26:53.000000000 +0200 +--- src/os_unix.c 2012-10-14 04:28:40.000000000 +0200 +*************** +*** 2512,2526 **** + } + + l = STRLEN(buf); +! if (l >= len) +! retval = FAIL; + #ifndef VMS +! else +! { +! if (l > 0 && buf[l - 1] != '/' && *fname != NUL + && STRCMP(fname, ".") != 0) +! STRCAT(buf, "/"); +! } + #endif + } + +--- 2512,2523 ---- + } + + l = STRLEN(buf); +! if (l >= len - 1) +! retval = FAIL; /* no space for trailing "/" */ + #ifndef VMS +! else if (l > 0 && buf[l - 1] != '/' && *fname != NUL + && STRCMP(fname, ".") != 0) +! STRCAT(buf, "/"); + #endif + } + +*** ../vim-7.3.689/src/version.c 2012-10-14 03:41:54.000000000 +0200 +--- src/version.c 2012-10-14 04:26:17.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 690, + /**/ + +-- +SOLDIER: What? Ridden on a horse? +ARTHUR: Yes! +SOLDIER: You're using coconuts! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4113cca262782e7714173a132b5d76a2e78c1f08 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Oct 2012 12:17:44 +0200 Subject: [PATCH 0529/3340] - patchlevel 691 --- 7.3.691 | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 7.3.691 diff --git a/7.3.691 b/7.3.691 new file mode 100644 index 00000000..6f44b5cf --- /dev/null +++ b/7.3.691 @@ -0,0 +1,61 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.691 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.691 +Problem: State specific to the Python thread is discarded. +Solution: Keep state between threads. (Paul) +Files: src/if_python.c + + +*** ../vim-7.3.690/src/if_python.c 2012-09-21 14:00:05.000000000 +0200 +--- src/if_python.c 2012-10-14 05:19:44.000000000 +0200 +*************** +*** 740,748 **** + #else + PyMac_Initialize(); + #endif +! /* initialise threads */ + PyEval_InitThreads(); +! + #ifdef DYNAMIC_PYTHON + get_exceptions(); + #endif +--- 740,750 ---- + #else + PyMac_Initialize(); + #endif +! /* Initialise threads and save the state using PyGILState_Ensure. +! * Without this call, thread-specific state (such as the system trace +! * hook), will be lost between invocations of Python code. */ + PyEval_InitThreads(); +! pygilstate = PyGILState_Ensure(); + #ifdef DYNAMIC_PYTHON + get_exceptions(); + #endif +*** ../vim-7.3.690/src/version.c 2012-10-14 04:35:16.000000000 +0200 +--- src/version.c 2012-10-14 05:14:35.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 691, + /**/ + +-- +ARTHUR: The swallow may fly south with the sun, or the house martin or the + plover seek warmer hot lands in winter, yet these are not strangers to + our land. +SOLDIER: Are you suggesting coconuts migrate? + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4f07895ef68e8386da75867fdb9d987059286e27 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Oct 2012 12:17:46 +0200 Subject: [PATCH 0530/3340] - patchlevel 691 --- README.patches | 9 +++++++++ vim.spec | 23 ++++++++++++++++++++++- 2 files changed, 31 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index cb9e52ec..dc198b3a 100644 --- a/README.patches +++ b/README.patches @@ -713,3 +713,12 @@ Individual patches for Vim 7.3: 2190 7.3.680 some files missing in the list of distributed files 2014 7.3.681 list of distributed files picks up backup files 1791 7.3.682 (after 7.3.677) compiler complains about incompatible types + 2578 7.3.683 ":python" may crash when vimbindeval() returns None + 4714 7.3.684 "make test" does not delete lua.vim + 1827 7.3.685 no test for what patch 7.3.673 fixes + 2226 7.3.686 cannot use CTRL-\ e mapping when entering an expression + 1386 7.3.687 test 16 fails when $DISPLAY is not set + 5283 7.3.688 Python 3.3 is not supported + 2266 7.3.689 MzScheme and Lua may use a NULL string + 1806 7.3.690 crash with directory name equal to maximum path length + 1910 7.3.691 state specific to the Python thread is discarded diff --git a/vim.spec b/vim.spec index 7720f248..8bf941f9 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 682 +%define patchlevel 691 Summary: The VIM editor URL: http://www.vim.org/ @@ -738,6 +738,15 @@ Patch679: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.679 Patch680: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.680 Patch681: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.681 Patch682: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.682 +Patch683: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.683 +Patch684: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.684 +Patch685: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.685 +Patch686: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.686 +Patch687: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.687 +Patch688: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.688 +Patch689: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.689 +Patch690: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.690 +Patch691: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.691 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1566,6 +1575,15 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch680 -p0 %patch681 -p0 %patch682 -p0 +%patch683 -p0 +%patch684 -p0 +%patch685 -p0 +%patch686 -p0 +%patch687 -p0 +%patch688 -p0 +%patch689 -p0 +%patch690 -p0 +%patch691 -p0 # install spell files @@ -2028,6 +2046,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Oct 15 2012 Karsten Hopp 7.3.691-1 +- patchlevel 691 + * Fri Oct 05 2012 Karsten Hopp 7.3.682-1 - patchlevel 682 - use --enable-rubyinterp=dynamic and --enable-pythoninterp=dynamic From 9f6726f3abb1617d2371e44cacc8e5586f05963c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:12:56 +0200 Subject: [PATCH 0531/3340] - patchlevel 692 --- 7.3.692 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.692 diff --git a/7.3.692 b/7.3.692 new file mode 100644 index 00000000..67016efc --- /dev/null +++ b/7.3.692 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.692 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.692 +Problem: Can't build GTK version with GTK 2.0. +Solution: Put GtkFileFilter declaration in the right place. (Yegappan + Lakshmanan) +Files: src/gui_gtk.c + + +*** ../vim-7.3.691/src/gui_gtk.c 2012-07-10 13:41:09.000000000 +0200 +--- src/gui_gtk.c 2012-10-18 05:12:34.000000000 +0200 +*************** +*** 845,851 **** + char_u dirbuf[MAXPATHL]; + guint log_handler; + const gchar *domain = "Gtk"; +- GtkFileFilter *gfilter; + + title = CONVERT_TO_UTF8(title); + +--- 845,850 ---- +*************** +*** 883,888 **** +--- 882,888 ---- + int i = 0; + char_u *patt; + char_u *p = filter; ++ GtkFileFilter *gfilter; + + gfilter = gtk_file_filter_new(); + patt = alloc(STRLEN(filter)); +*** ../vim-7.3.691/src/version.c 2012-10-14 05:20:05.000000000 +0200 +--- src/version.c 2012-10-18 05:13:55.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 692, + /**/ + +-- +"The future's already arrived - it's just not evenly distributed yet." + -- William Gibson + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ccd1ffc6d800fca189f1c85d4b07ee5a93edd957 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:12:57 +0200 Subject: [PATCH 0532/3340] - patchlevel 693 --- 7.3.693 | 165 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 165 insertions(+) create mode 100644 7.3.693 diff --git a/7.3.693 b/7.3.693 new file mode 100644 index 00000000..c3b6b808 --- /dev/null +++ b/7.3.693 @@ -0,0 +1,165 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.693 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.693 +Problem: Can't make 'softtabstop' follow 'shiftwidth'. +Solution: When 'softtabstop' is negative use the value of 'shiftwidth'. + (so8res) +Files: src/edit.c, src/option.c, src/proto/option.pro + + +*** ../vim-7.3.692/src/edit.c 2012-10-04 22:38:32.000000000 +0200 +--- src/edit.c 2012-10-21 00:01:53.000000000 +0200 +*************** +*** 8885,8891 **** + */ + if ( mode == BACKSPACE_CHAR + && ((p_sta && in_indent) +! || (curbuf->b_p_sts != 0 + && curwin->w_cursor.col > 0 + && (*(ml_get_cursor() - 1) == TAB + || (*(ml_get_cursor() - 1) == ' ' +--- 8885,8891 ---- + */ + if ( mode == BACKSPACE_CHAR + && ((p_sta && in_indent) +! || (get_sts_value() != 0 + && curwin->w_cursor.col > 0 + && (*(ml_get_cursor() - 1) == TAB + || (*(ml_get_cursor() - 1) == ' ' +*************** +*** 8901,8907 **** + if (p_sta && in_indent) + ts = (int)get_sw_value(); + else +! ts = (int)curbuf->b_p_sts; + /* Compute the virtual column where we want to be. Since + * 'showbreak' may get in the way, need to get the last column of + * the previous character. */ +--- 8901,8907 ---- + if (p_sta && in_indent) + ts = (int)get_sw_value(); + else +! ts = (int)get_sts_value(); + /* Compute the virtual column where we want to be. Since + * 'showbreak' may get in the way, need to get the last column of + * the previous character. */ +*************** +*** 9590,9596 **** + */ + if (!curbuf->b_p_et + && !(p_sta && ind && curbuf->b_p_ts != get_sw_value()) +! && curbuf->b_p_sts == 0) + return TRUE; + + if (stop_arrow() == FAIL) +--- 9590,9596 ---- + */ + if (!curbuf->b_p_et + && !(p_sta && ind && curbuf->b_p_ts != get_sw_value()) +! && get_sts_value() == 0) + return TRUE; + + if (stop_arrow() == FAIL) +*************** +*** 9606,9613 **** + + if (p_sta && ind) /* insert tab in indent, use 'shiftwidth' */ + temp = (int)get_sw_value(); +! else if (curbuf->b_p_sts > 0) /* use 'softtabstop' when set */ +! temp = (int)curbuf->b_p_sts; + else /* otherwise use 'tabstop' */ + temp = (int)curbuf->b_p_ts; + temp -= get_nolist_virtcol() % temp; +--- 9606,9613 ---- + + if (p_sta && ind) /* insert tab in indent, use 'shiftwidth' */ + temp = (int)get_sw_value(); +! else if (curbuf->b_p_sts != 0) /* use 'softtabstop' when set */ +! temp = (int)get_sts_value(); + else /* otherwise use 'tabstop' */ + temp = (int)curbuf->b_p_ts; + temp -= get_nolist_virtcol() % temp; +*************** +*** 9635,9641 **** + /* + * When 'expandtab' not set: Replace spaces by TABs where possible. + */ +! if (!curbuf->b_p_et && (curbuf->b_p_sts || (p_sta && ind))) + { + char_u *ptr; + #ifdef FEAT_VREPLACE +--- 9635,9641 ---- + /* + * When 'expandtab' not set: Replace spaces by TABs where possible. + */ +! if (!curbuf->b_p_et && (get_sts_value() || (p_sta && ind))) + { + char_u *ptr; + #ifdef FEAT_VREPLACE +*** ../vim-7.3.692/src/option.c 2012-08-08 18:01:00.000000000 +0200 +--- src/option.c 2012-10-21 00:05:06.000000000 +0200 +*************** +*** 8509,8519 **** + p_window = Rows - 1; + } + +- if (curbuf->b_p_sts < 0) +- { +- errmsg = e_positive; +- curbuf->b_p_sts = 0; +- } + if (curbuf->b_p_ts <= 0) + { + errmsg = e_positive; +--- 8509,8514 ---- +*************** +*** 11429,11431 **** +--- 11424,11436 ---- + { + return curbuf->b_p_sw ? curbuf->b_p_sw : curbuf->b_p_ts; + } ++ ++ /* ++ * Return the effective softtabstop value for the current buffer, using the ++ * 'tabstop' value when 'softtabstop' is negative. ++ */ ++ long ++ get_sts_value() ++ { ++ return curbuf->b_p_sts < 0 ? get_sw_value() : curbuf->b_p_sts; ++ } +*** ../vim-7.3.692/src/proto/option.pro 2012-08-08 18:01:00.000000000 +0200 +--- src/proto/option.pro 2012-10-21 00:01:59.000000000 +0200 +*************** +*** 57,60 **** +--- 57,61 ---- + int file_ff_differs __ARGS((buf_T *buf, int ignore_empty)); + int check_ff_value __ARGS((char_u *p)); + long get_sw_value __ARGS((void)); ++ long get_sts_value __ARGS((void)); + /* vim: set ft=c : */ +*** ../vim-7.3.692/src/version.c 2012-10-18 05:18:27.000000000 +0200 +--- src/version.c 2012-10-21 00:07:19.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 693, + /**/ + +-- +FIRST VILLAGER: We have found a witch. May we burn her? + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 85476a029cdde08b3605e27d8bde6a494e499efd Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:00 +0200 Subject: [PATCH 0533/3340] - patchlevel 694 --- 7.3.694 | 139 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 139 insertions(+) create mode 100644 7.3.694 diff --git a/7.3.694 b/7.3.694 new file mode 100644 index 00000000..89b4bcf7 --- /dev/null +++ b/7.3.694 @@ -0,0 +1,139 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.694 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.694 +Problem: Now that 'shiftwidth' may use the value of 'tabstop' it is not so + easy to use in indent files. +Solution: Add the shiftwidth() function. (so8res) +Files: runtime/doc/eval.txt, src/eval.c + + +*** ../vim-7.3.693/runtime/doc/eval.txt 2012-06-29 12:54:32.000000000 +0200 +--- runtime/doc/eval.txt 2012-10-21 00:43:22.000000000 +0200 +*************** +*** 1921,1926 **** +--- 1932,1938 ---- + shellescape( {string} [, {special}]) + String escape {string} for use as shell + command argument ++ shiftwidth() Number effective value of 'shiftwidth' + simplify( {filename}) String simplify filename as much as possible + sin( {expr}) Float sine of {expr} + sinh( {expr}) Float hyperbolic sine of {expr} +*************** +*** 3732,3741 **** + Like |input()|, but when the GUI is running and text dialogs + are supported, a dialog window pops up to input the text. + Example: > +! :let n = inputdialog("value for shiftwidth", &sw) +! :if n != "" +! : let &sw = n +! :endif + < When the dialog is cancelled {cancelreturn} is returned. When + omitted an empty string is returned. + Hitting works like pressing the OK button. Hitting +--- 3755,3764 ---- + Like |input()|, but when the GUI is running and text dialogs + are supported, a dialog window pops up to input the text. + Example: > +! :let n = inputdialog("value for shiftwidth", shiftwidth()) +! :if n != "" +! : let &sw = n +! :endif + < When the dialog is cancelled {cancelreturn} is returned. When + omitted an empty string is returned. + Hitting works like pressing the OK button. Hitting +*************** +*** 5308,5313 **** +--- 5332,5354 ---- + :call system("chmod +w -- " . shellescape(expand("%"))) + + ++ shiftwidth() *shiftwidth()* ++ Returns the effective value of 'shiftwidth'. This is the ++ 'shiftwidth' value unless it is zero, in which case it is the ++ 'tabstop' value. To be backwards compatible in indent ++ plugins, use this: > ++ if exists('*shiftwidth') ++ func s:sw() ++ return shiftwidth() ++ endfunc ++ else ++ func s:sw() ++ return &sw ++ endfunc ++ endif ++ < And then use s:sw() instead of &sw. ++ ++ + simplify({filename}) *simplify()* + Simplify the file name as much as possible without changing + the meaning. Shortcuts (on MS-Windows) or symbolic links (on +*** ../vim-7.3.693/src/eval.c 2012-08-08 14:33:16.000000000 +0200 +--- src/eval.c 2012-10-21 00:29:15.000000000 +0200 +*************** +*** 687,692 **** +--- 687,693 ---- + static void f_settabwinvar __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_setwinvar __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_shellescape __ARGS((typval_T *argvars, typval_T *rettv)); ++ static void f_shiftwidth __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_simplify __ARGS((typval_T *argvars, typval_T *rettv)); + #ifdef FEAT_FLOAT + static void f_sin __ARGS((typval_T *argvars, typval_T *rettv)); +*************** +*** 8051,8056 **** +--- 8052,8058 ---- + {"settabwinvar", 4, 4, f_settabwinvar}, + {"setwinvar", 3, 3, f_setwinvar}, + {"shellescape", 1, 2, f_shellescape}, ++ {"shiftwidth", 0, 0, f_shiftwidth}, + {"simplify", 1, 1, f_simplify}, + #ifdef FEAT_FLOAT + {"sin", 1, 1, f_sin}, +*************** +*** 16652,16657 **** +--- 16654,16670 ---- + } + + /* ++ * shiftwidth() function ++ */ ++ static void ++ f_shiftwidth(argvars, rettv) ++ typval_T *argvars; ++ typval_T *rettv; ++ { ++ rettv->vval.v_number = get_sw_value(); ++ } ++ ++ /* + * "simplify()" function + */ + static void +*** ../vim-7.3.693/src/version.c 2012-10-21 00:10:29.000000000 +0200 +--- src/version.c 2012-10-21 00:30:27.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 694, + /**/ + +-- +CRONE: Who sent you? +ARTHUR: The Knights Who Say GNU! +CRONE: Aaaagh! (she looks around in rear) No! We have no licenses here. + "Monty Python and the Holy editor wars" PYTHON (MONTY) SOFTWARE LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d8bb874c67835f7521d36a2937abc40e71f88c26 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:01 +0200 Subject: [PATCH 0534/3340] - patchlevel 695 --- 7.3.695 | 129 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 129 insertions(+) create mode 100644 7.3.695 diff --git a/7.3.695 b/7.3.695 new file mode 100644 index 00000000..32010535 --- /dev/null +++ b/7.3.695 @@ -0,0 +1,129 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.695 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.695 +Problem: Balloon cannot show multi-byte text. +Solution: Properly deal with multi-byte characters. (Dominique Pelle) +Files: src/gui_beval.c, src/ui.c + + +*** ../vim-7.3.694/src/gui_beval.c 2010-08-15 21:57:28.000000000 +0200 +--- src/gui_beval.c 2012-10-21 00:54:19.000000000 +0200 +*************** +*** 359,365 **** + } + } + +! col = vcol2col(wp, lnum, col) - 1; + + if (VIsual_active + && wp->w_buffer == curwin->w_buffer +--- 359,365 ---- + } + } + +! col = vcol2col(wp, lnum, col); + + if (VIsual_active + && wp->w_buffer == curwin->w_buffer +*************** +*** 377,384 **** + return FAIL; + + lbuf = ml_get_buf(curwin->w_buffer, VIsual.lnum, FALSE); +! lbuf = vim_strnsave(lbuf + spos->col, +! epos->col - spos->col + (*p_sel != 'e')); + lnum = spos->lnum; + col = spos->col; + } +--- 377,386 ---- + return FAIL; + + lbuf = ml_get_buf(curwin->w_buffer, VIsual.lnum, FALSE); +! len = epos->col - spos->col; +! if (*p_sel != 'e') +! len += MB_PTR2LEN(lbuf + epos->col); +! lbuf = vim_strnsave(lbuf + spos->col, len); + lnum = spos->lnum; + col = spos->col; + } +*** ../vim-7.3.694/src/ui.c 2012-08-29 16:26:01.000000000 +0200 +--- src/ui.c 2012-10-21 00:50:17.000000000 +0200 +*************** +*** 98,104 **** + #endif + + /* +! * ui_inchar(): low level input funcion. + * Get characters from the keyboard. + * Return the number of characters that are available. + * If "wtime" == 0 do not wait for characters. +--- 98,104 ---- + #endif + + /* +! * ui_inchar(): low level input function. + * Get characters from the keyboard. + * Return the number of characters that are available. + * If "wtime" == 0 do not wait for characters. +*************** +*** 493,499 **** + } + } + #else +! /* Only own the clibpard when we didn't own it yet. */ + if (!cbd->owned && cbd->available) + cbd->owned = (clip_gen_own_selection(cbd) == OK); + #endif +--- 493,499 ---- + } + } + #else +! /* Only own the clipboard when we didn't own it yet. */ + if (!cbd->owned && cbd->available) + cbd->owned = (clip_gen_own_selection(cbd) == OK); + #endif +*************** +*** 3132,3138 **** + char_u *start; + + start = ptr = ml_get_buf(wp->w_buffer, lnum, FALSE); +! while (count <= vcol && *ptr != NUL) + { + count += win_lbr_chartabsize(wp, ptr, count, NULL); + mb_ptr_adv(ptr); +--- 3132,3138 ---- + char_u *start; + + start = ptr = ml_get_buf(wp->w_buffer, lnum, FALSE); +! while (count < vcol && *ptr != NUL) + { + count += win_lbr_chartabsize(wp, ptr, count, NULL); + mb_ptr_adv(ptr); +*** ../vim-7.3.694/src/version.c 2012-10-21 00:44:59.000000000 +0200 +--- src/version.c 2012-10-21 00:50:32.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 695, + /**/ + +-- +BEDEVERE: Why do you think she is a witch? +SECOND VILLAGER: She turned me into a newt. +BEDEVERE: A newt? +SECOND VILLAGER: (After looking at himself for some time) I got better. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bcbedee75ec8a21f8dfbe4d3e16f65b2f2fd3831 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:02 +0200 Subject: [PATCH 0535/3340] - patchlevel 696 --- 7.3.696 | 89 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) create mode 100644 7.3.696 diff --git a/7.3.696 b/7.3.696 new file mode 100644 index 00000000..9084022e --- /dev/null +++ b/7.3.696 @@ -0,0 +1,89 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.696 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.696 +Problem: Message about added spell language can be wrong. +Solution: Give correct message. Add g:menutrans_set_lang_to to allow for + translation. (Jiri Sedlak) +Files: runtime/menu.vim + + +*** ../vim-7.3.695/runtime/menu.vim 2010-08-15 21:57:11.000000000 +0200 +--- runtime/menu.vim 2012-10-21 01:17:27.000000000 +0200 +*************** +*** 434,439 **** +--- 434,443 ---- + let enc = &enc + endif + ++ if !exists("g:menutrans_set_lang_to") ++ let g:menutrans_set_lang_to = 'Set language to' ++ endif ++ + let found = 0 + let s = globpath(&rtp, "spell/*." . enc . ".spl") + if s != "" +*************** +*** 441,448 **** + for f in split(s, "\n") + let nm = substitute(f, '.*spell[/\\]\(..\)\.[^/\\]*\.spl', '\1', "") + if nm != "en" && nm !~ '/' + let found += 1 +! let menuname = '&Tools.&Spelling.Set\ language\ to\ "' . nm . '"' + exe 'an 40.335.' . n . ' ' . menuname . ' :set spl=' . nm . ' spell' + let s:undo_spellang += ['aun ' . menuname] + endif +--- 445,453 ---- + for f in split(s, "\n") + let nm = substitute(f, '.*spell[/\\]\(..\)\.[^/\\]*\.spl', '\1', "") + if nm != "en" && nm !~ '/' ++ let _nm = nm + let found += 1 +! let menuname = '&Tools.&Spelling.' . escape(g:menutrans_set_lang_to, "\\. \t|") . '\ "' . nm . '"' + exe 'an 40.335.' . n . ' ' . menuname . ' :set spl=' . nm . ' spell' + let s:undo_spellang += ['aun ' . menuname] + endif +*************** +*** 452,458 **** + if found == 0 + echomsg "Could not find other spell files" + elseif found == 1 +! echomsg "Found spell file " . nm + else + echomsg "Found " . found . " more spell files" + endif +--- 457,463 ---- + if found == 0 + echomsg "Could not find other spell files" + elseif found == 1 +! echomsg "Found spell file " . _nm + else + echomsg "Found " . found . " more spell files" + endif +*** ../vim-7.3.695/src/version.c 2012-10-21 00:58:34.000000000 +0200 +--- src/version.c 2012-10-21 01:15:00.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 696, + /**/ + +-- +BEDEVERE: And what do you burn, apart from witches? +FOURTH VILLAGER: ... Wood? +BEDEVERE: So why do witches burn? +SECOND VILLAGER: (pianissimo) ... Because they're made of wood...? + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a50f2d86707f2743927ab8eebc4b439bf7304b51 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:03 +0200 Subject: [PATCH 0536/3340] - patchlevel 697 --- 7.3.697 | 188 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 188 insertions(+) create mode 100644 7.3.697 diff --git a/7.3.697 b/7.3.697 new file mode 100644 index 00000000..b8d7814a --- /dev/null +++ b/7.3.697 @@ -0,0 +1,188 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.697 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.697 +Problem: Leaking resources when setting GUI font. +Solution: Free the font. (Ken Takata) +Files: src/syntax.c + + +*** ../vim-7.3.696/src/syntax.c 2012-07-19 17:39:01.000000000 +0200 +--- src/syntax.c 2012-10-21 01:37:19.000000000 +0200 +*************** +*** 105,111 **** + # ifdef FEAT_XFONTSET + static GuiFontset fontset_name2handle __ARGS((char_u *name, int fixed_width)); + # endif +! static void hl_do_font __ARGS((int idx, char_u *arg, int do_normal, int do_menu, int do_tooltip)); + #endif + + /* +--- 105,111 ---- + # ifdef FEAT_XFONTSET + static GuiFontset fontset_name2handle __ARGS((char_u *name, int fixed_width)); + # endif +! static void hl_do_font __ARGS((int idx, char_u *arg, int do_normal, int do_menu, int do_tooltip, int free_font)); + #endif + + /* +*************** +*** 7259,7272 **** + HL_TABLE()[idx].sg_fontset = NOFONTSET; + # endif + hl_do_font(idx, arg, is_normal_group, is_menu_group, +! is_tooltip_group); + + # ifdef FEAT_XFONTSET + if (HL_TABLE()[idx].sg_fontset != NOFONTSET) + { +! /* New fontset was accepted. Free the old one, if there was +! * one. +! */ + gui_mch_free_fontset(temp_sg_fontset); + vim_free(HL_TABLE()[idx].sg_font_name); + HL_TABLE()[idx].sg_font_name = vim_strsave(arg); +--- 7259,7271 ---- + HL_TABLE()[idx].sg_fontset = NOFONTSET; + # endif + hl_do_font(idx, arg, is_normal_group, is_menu_group, +! is_tooltip_group, FALSE); + + # ifdef FEAT_XFONTSET + if (HL_TABLE()[idx].sg_fontset != NOFONTSET) + { +! /* New fontset was accepted. Free the old one, if there +! * was one. */ + gui_mch_free_fontset(temp_sg_fontset); + vim_free(HL_TABLE()[idx].sg_font_name); + HL_TABLE()[idx].sg_font_name = vim_strsave(arg); +*************** +*** 7277,7284 **** + if (HL_TABLE()[idx].sg_font != NOFONT) + { + /* New font was accepted. Free the old one, if there was +! * one. +! */ + gui_mch_free_font(temp_sg_font); + vim_free(HL_TABLE()[idx].sg_font_name); + HL_TABLE()[idx].sg_font_name = vim_strsave(arg); +--- 7276,7282 ---- + if (HL_TABLE()[idx].sg_font != NOFONT) + { + /* New font was accepted. Free the old one, if there was +! * one. */ + gui_mch_free_font(temp_sg_font); + vim_free(HL_TABLE()[idx].sg_font_name); + HL_TABLE()[idx].sg_font_name = vim_strsave(arg); +*************** +*** 8064,8075 **** + * Get the font or fontset for one highlight group. + */ + static void +! hl_do_font(idx, arg, do_normal, do_menu, do_tooltip) + int idx; + char_u *arg; + int do_normal; /* set normal font */ + int do_menu UNUSED; /* set menu font */ + int do_tooltip UNUSED; /* set tooltip font */ + { + # ifdef FEAT_XFONTSET + /* If 'guifontset' is not empty, first try using the name as a +--- 8062,8074 ---- + * Get the font or fontset for one highlight group. + */ + static void +! hl_do_font(idx, arg, do_normal, do_menu, do_tooltip, free_font) + int idx; + char_u *arg; + int do_normal; /* set normal font */ + int do_menu UNUSED; /* set menu font */ + int do_tooltip UNUSED; /* set tooltip font */ ++ int free_font; /* free current font/fontset */ + { + # ifdef FEAT_XFONTSET + /* If 'guifontset' is not empty, first try using the name as a +*************** +*** 8083,8088 **** +--- 8082,8089 ---- + || do_tooltip + # endif + ) ++ if (free_fontset) ++ gui_mch_free_fontset(HL_TABLE()[idx].sg_fontset); + HL_TABLE()[idx].sg_fontset = fontset_name2handle(arg, 0 + # ifdef FONTSET_ALWAYS + || do_menu +*************** +*** 8093,8100 **** + ); + if (HL_TABLE()[idx].sg_fontset != NOFONTSET) + { +! /* If it worked and it's the Normal group, use it as the +! * normal fontset. Same for the Menu group. */ + if (do_normal) + gui_init_font(arg, TRUE); + # if (defined(FEAT_GUI_MOTIF) || defined(FEAT_GUI_ATHENA)) && defined(FEAT_MENU) +--- 8094,8101 ---- + ); + if (HL_TABLE()[idx].sg_fontset != NOFONTSET) + { +! /* If it worked and it's the Normal group, use it as the normal +! * fontset. Same for the Menu group. */ + if (do_normal) + gui_init_font(arg, TRUE); + # if (defined(FEAT_GUI_MOTIF) || defined(FEAT_GUI_ATHENA)) && defined(FEAT_MENU) +*************** +*** 8126,8131 **** +--- 8127,8134 ---- + else + # endif + { ++ if (free_font) ++ gui_mch_free_font(HL_TABLE()[idx].sg_font); + HL_TABLE()[idx].sg_font = font_name2handle(arg); + /* If it worked and it's the Normal group, use it as the + * normal font. Same for the Menu group. */ +*************** +*** 9162,9168 **** + if (HL_TABLE()[idx].sg_font_name != NULL) + { + hl_do_font(idx, HL_TABLE()[idx].sg_font_name, FALSE, do_menu, +! do_tooltip); + didit = TRUE; + } + if (HL_TABLE()[idx].sg_gui_fg_name != NULL) +--- 9165,9171 ---- + if (HL_TABLE()[idx].sg_font_name != NULL) + { + hl_do_font(idx, HL_TABLE()[idx].sg_font_name, FALSE, do_menu, +! do_tooltip, TRUE); + didit = TRUE; + } + if (HL_TABLE()[idx].sg_gui_fg_name != NULL) +*** ../vim-7.3.696/src/version.c 2012-10-21 01:21:53.000000000 +0200 +--- src/version.c 2012-10-21 01:27:55.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 697, + /**/ + +-- +BEDEVERE: Wait. Wait ... tell me, what also floats on water? +ALL: Bread? No, no, no. Apples .... gravy ... very small rocks ... +ARTHUR: A duck. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3ce828eae7a4e2cf34b791ff8c60c8aef5cd408f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:05 +0200 Subject: [PATCH 0537/3340] - patchlevel 698 --- 7.3.698 | 84 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 7.3.698 diff --git a/7.3.698 b/7.3.698 new file mode 100644 index 00000000..57b37d6c --- /dev/null +++ b/7.3.698 @@ -0,0 +1,84 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.698 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.698 +Problem: Python 3 does not preserve state beween commands. +Solution: Preserve the state. (Paul Ollis) +Files: src/if_python.c, src/if_python3.c + + +*** ../vim-7.3.697/src/if_python.c 2012-10-14 05:20:05.000000000 +0200 +--- src/if_python.c 2012-10-21 01:44:10.000000000 +0200 +*************** +*** 740,748 **** + #else + PyMac_Initialize(); + #endif +! /* Initialise threads and save the state using PyGILState_Ensure. +! * Without this call, thread-specific state (such as the system trace +! * hook), will be lost between invocations of Python code. */ + PyEval_InitThreads(); + pygilstate = PyGILState_Ensure(); + #ifdef DYNAMIC_PYTHON +--- 740,749 ---- + #else + PyMac_Initialize(); + #endif +! /* Initialise threads, and save the state using PyGILState_Ensure. +! * Without the call to PyGILState_Ensure, thread specific state (such +! * as the system trace hook), will be lost between invocations of +! * Python code. */ + PyEval_InitThreads(); + pygilstate = PyGILState_Ensure(); + #ifdef DYNAMIC_PYTHON +*** ../vim-7.3.697/src/if_python3.c 2012-10-14 03:22:49.000000000 +0200 +--- src/if_python3.c 2012-10-21 01:44:37.000000000 +0200 +*************** +*** 731,738 **** + #else + PyMac_Initialize(); + #endif +! /* initialise threads, must be after Py_Initialize() */ + PyEval_InitThreads(); + + #ifdef DYNAMIC_PYTHON3 + get_py3_exceptions(); +--- 731,742 ---- + #else + PyMac_Initialize(); + #endif +! /* Initialise threads, and save the state using PyGILState_Ensure. +! * Without the call to PyGILState_Ensure, thread specific state (such +! * as the system trace hook), will be lost between invocations of +! * Python code. */ + PyEval_InitThreads(); ++ pygilstate = PyGILState_Ensure(); + + #ifdef DYNAMIC_PYTHON3 + get_py3_exceptions(); +*** ../vim-7.3.697/src/version.c 2012-10-21 01:40:24.000000000 +0200 +--- src/version.c 2012-10-21 01:42:44.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 698, + /**/ + +-- +ALL: A witch! A witch! +WITCH: It's a fair cop. +ALL: Burn her! Burn her! Let's make her into a ladder. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 30230d1aaa3a82f6887030806b00e44f97787701 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:05 +0200 Subject: [PATCH 0538/3340] - patchlevel 699 --- 7.3.699 | 86 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 7.3.699 diff --git a/7.3.699 b/7.3.699 new file mode 100644 index 00000000..6efc8695 --- /dev/null +++ b/7.3.699 @@ -0,0 +1,86 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.699 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.699 +Problem: When 'ttymouse' is set to "sgr" manually, it is overruled by + automatic detection. +Solution: Do not use automatic detection when 'ttymouse' was set manually. + (Hayaki Saito) +Files: src/term.c + + +*** ../vim-7.3.698/src/term.c 2012-08-29 16:26:01.000000000 +0200 +--- src/term.c 2012-10-21 02:07:25.000000000 +0200 +*************** +*** 4079,4102 **** + + if (tp[1 + (tp[0] != CSI)] == '>' && j == 2) + { + # ifdef TTYM_SGR +! if (extra >= 277 +! # ifdef TTYM_URXVT +! && ttym_flags != TTYM_URXVT +! # endif +! ) +! set_option_value((char_u *)"ttym", 0L, + (char_u *)"sgr", 0); +! else + # endif +! /* if xterm version >= 95 use mouse dragging */ +! if (extra >= 95 +! # ifdef TTYM_URXVT +! && ttym_flags != TTYM_URXVT +! # endif +! ) +! set_option_value((char_u *)"ttym", 0L, + (char_u *)"xterm2", 0); + /* if xterm version >= 141 try to get termcap codes */ + if (extra >= 141) + { +--- 4079,4100 ---- + + if (tp[1 + (tp[0] != CSI)] == '>' && j == 2) + { ++ /* Only set 'ttymouse' automatically if it was not set ++ * by the user already. */ ++ if (!option_was_set((char_u *)"ttym")) ++ { + # ifdef TTYM_SGR +! if (extra >= 277) +! set_option_value((char_u *)"ttym", 0L, + (char_u *)"sgr", 0); +! else + # endif +! /* if xterm version >= 95 use mouse dragging */ +! if (extra >= 95) +! set_option_value((char_u *)"ttym", 0L, + (char_u *)"xterm2", 0); ++ } ++ + /* if xterm version >= 141 try to get termcap codes */ + if (extra >= 141) + { +*** ../vim-7.3.698/src/version.c 2012-10-21 01:46:56.000000000 +0200 +--- src/version.c 2012-10-21 02:09:17.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 699, + /**/ + +-- +Never under any circumstances take a sleeping pill +and a laxative on the same night. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d22fb15cafb718e1b19c6721c49ea1b55c1777fc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:07 +0200 Subject: [PATCH 0539/3340] - patchlevel 700 --- 7.3.700 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.700 diff --git a/7.3.700 b/7.3.700 new file mode 100644 index 00000000..a1b530eb --- /dev/null +++ b/7.3.700 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.700 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.700 +Problem: Cannot detect URXVT and SGR mouse support. +Solution: add +mouse_urxvt and +mouse_sgr. (Hayaki Saito) +Files: src/feature.h, src/eval.c + + +*** ../vim-7.3.699/src/feature.h 2012-08-15 16:20:59.000000000 +0200 +--- src/feature.h 2012-10-21 02:13:36.000000000 +0200 +*************** +*** 1038,1045 **** +--- 1038,1047 ---- + * +mouse_gpm Unix only: Include code for Linux console mouse + * handling. + * +mouse_pterm PTerm mouse support for QNX ++ * +mouse_sgr Unix only: Include code for for SGR-styled mouse. + * +mouse_sysmouse Unix only: Include code for FreeBSD and DragonFly + * console mouse handling. ++ * +mouse_urxvt Unix only: Include code for for urxvt mosue handling. + * +mouse Any mouse support (any of the above enabled). + */ + /* OS/2 and Amiga console have no mouse support */ +*** ../vim-7.3.699/src/eval.c 2012-10-21 00:44:59.000000000 +0200 +--- src/eval.c 2012-10-21 02:12:48.000000000 +0200 +*************** +*** 12276,12284 **** +--- 12276,12290 ---- + # ifdef FEAT_MOUSE_PTERM + "mouse_pterm", + # endif ++ # ifdef FEAT_MOUSE_SGR ++ "mouse_sgr", ++ # endif + # ifdef FEAT_SYSMOUSE + "mouse_sysmouse", + # endif ++ # ifdef FEAT_MOUSE_URXVT ++ "mouse_urxvt", ++ # endif + # ifdef FEAT_MOUSE_XTERM + "mouse_xterm", + # endif +*** ../vim-7.3.699/src/version.c 2012-10-21 02:10:20.000000000 +0200 +--- src/version.c 2012-10-21 02:15:32.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 700, + /**/ + +-- +If you had to identify, in one word, the reason why the +human race has not achieved, and never will achieve, its +full potential, that word would be "meetings." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f615fd9a421702b061d1ecfd6d8b1b46b7c21b26 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:09 +0200 Subject: [PATCH 0540/3340] - patchlevel 701 --- 7.3.701 | 83 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 7.3.701 diff --git a/7.3.701 b/7.3.701 new file mode 100644 index 00000000..1c17aab6 --- /dev/null +++ b/7.3.701 @@ -0,0 +1,83 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.701 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.701 +Problem: MS-Windows: Crash with stack overflow when setting 'encoding'. +Solution: Handle that loading the iconv library may be called recursively. + (Jiri Sedlak) +Files: src/os_win32.c + + +*** ../vim-7.3.700/src/os_win32.c 2012-08-02 12:31:40.000000000 +0200 +--- src/os_win32.c 2012-10-21 02:35:21.000000000 +0200 +*************** +*** 288,305 **** + vimLoadLib(char *name) + { + HINSTANCE dll = NULL; +! char old_dir[MAXPATHL]; + + if (exe_path == NULL) + get_exe_name(); +! if (exe_path != NULL && mch_dirname(old_dir, MAXPATHL) == OK) + { + /* Change directory to where the executable is, both to make sure we + * find a .dll there and to avoid looking for a .dll in the current + * directory. */ +! mch_chdir(exe_path); + dll = LoadLibrary(name); +- mch_chdir(old_dir); + } + return dll; + } +--- 288,313 ---- + vimLoadLib(char *name) + { + HINSTANCE dll = NULL; +! TCHAR old_dir[MAXPATHL]; + ++ /* NOTE: Do not use mch_dirname() and mch_chdir() here, they may call ++ * vimLoadLib() recursively, which causes a stack overflow. */ + if (exe_path == NULL) + get_exe_name(); +! if (exe_path != NULL && GetCurrentDirectory(MAXPATHL, old_dir) != 0) + { + /* Change directory to where the executable is, both to make sure we + * find a .dll there and to avoid looking for a .dll in the current + * directory. */ +! SetCurrentDirectory(exe_path); +! dll = LoadLibrary(name); +! SetCurrentDirectory(old_dir); +! } +! else +! { +! /* We are not able to change directory to where the executable is, try +! * to load library anyway. */ + dll = LoadLibrary(name); + } + return dll; + } +*** ../vim-7.3.700/src/version.c 2012-10-21 02:17:28.000000000 +0200 +--- src/version.c 2012-10-21 02:35:48.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 701, + /**/ + +-- +BEDEVERE: And that, my lord, is how we know the Earth to be banana-shaped. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 026474bdc05a79a725d82cfe41781cc403d1324b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:12 +0200 Subject: [PATCH 0541/3340] - patchlevel 702 --- 7.3.702 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.702 diff --git a/7.3.702 b/7.3.702 new file mode 100644 index 00000000..d36f96c7 --- /dev/null +++ b/7.3.702 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.702 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.702 +Problem: Nmake from VS6 service pack 6 is not recognized. +Solution: Detect the version number. (Jiri Sedlak) +Files: src/Make_mvc.mak + + +*** ../vim-7.3.701/src/Make_mvc.mak 2012-09-18 22:00:02.000000000 +0200 +--- src/Make_mvc.mak 2012-10-21 02:38:21.000000000 +0200 +*************** +*** 373,378 **** +--- 373,382 ---- + MSVCVER = 6.0 + CPU = ix86 + !endif ++ !if "$(_NMAKE_VER)" == "6.00.9782.0" ++ MSVCVER = 6.0 ++ CPU = ix86 ++ !endif + !if "$(_NMAKE_VER)" == "7.00.9466" + MSVCVER = 7.0 + !endif +*** ../vim-7.3.701/src/version.c 2012-10-21 02:37:02.000000000 +0200 +--- src/version.c 2012-10-21 02:40:00.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 702, + /**/ + +-- +Back off man, I'm a scientist. + -- Peter, Ghostbusters + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6fe298c7d2fd6c1a49ba746165127f0f043f6b04 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:13 +0200 Subject: [PATCH 0542/3340] - patchlevel 703 --- 7.3.703 | 97 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100644 7.3.703 diff --git a/7.3.703 b/7.3.703 new file mode 100644 index 00000000..c9f0c8a9 --- /dev/null +++ b/7.3.703 @@ -0,0 +1,97 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.703 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.703 +Problem: When 'undofile' is reset the hash is computed unnecessarily. +Solution: Only compute the hash when the option was set. (Christian Brabandt) +Files: src/option.c + + +*** ../vim-7.3.702/src/option.c 2012-10-21 00:10:29.000000000 +0200 +--- src/option.c 2012-10-21 03:42:10.000000000 +0200 +*************** +*** 7573,7596 **** + /* 'undofile' */ + else if ((int *)varp == &curbuf->b_p_udf || (int *)varp == &p_udf) + { +! char_u hash[UNDO_HASH_SIZE]; +! buf_T *save_curbuf = curbuf; +! +! for (curbuf = firstbuf; curbuf != NULL; curbuf = curbuf->b_next) + { +! /* When 'undofile' is set globally: for every buffer, otherwise +! * only for the current buffer: Try to read in the undofile, if +! * one exists and the buffer wasn't changed and the buffer was +! * loaded. */ +! if ((curbuf == save_curbuf +! || (opt_flags & OPT_GLOBAL) || opt_flags == 0) +! && !curbufIsChanged() && curbuf->b_ml.ml_mfp != NULL) + { +! u_compute_hash(hash); +! u_read_undo(NULL, hash, curbuf->b_fname); + } + } +- curbuf = save_curbuf; + } + #endif + +--- 7573,7602 ---- + /* 'undofile' */ + else if ((int *)varp == &curbuf->b_p_udf || (int *)varp == &p_udf) + { +! /* Only take action when the option was set. When reset we do not +! * delete the undo file, the option may be set again without making +! * any changes in between. */ +! if (curbuf->b_p_udf || p_udf) + { +! char_u hash[UNDO_HASH_SIZE]; +! buf_T *save_curbuf = curbuf; +! +! for (curbuf = firstbuf; curbuf != NULL; curbuf = curbuf->b_next) + { +! /* When 'undofile' is set globally: for every buffer, otherwise +! * only for the current buffer: Try to read in the undofile, +! * if one exists, the buffer wasn't changed and the buffer was +! * loaded */ +! if ((curbuf == save_curbuf +! || (opt_flags & OPT_GLOBAL) || opt_flags == 0) +! && !curbufIsChanged() && curbuf->b_ml.ml_mfp != NULL) +! { +! u_compute_hash(hash); +! u_read_undo(NULL, hash, curbuf->b_fname); +! } + } ++ curbuf = save_curbuf; + } + } + #endif + +*** ../vim-7.3.702/src/version.c 2012-10-21 02:41:04.000000000 +0200 +--- src/version.c 2012-10-21 03:43:29.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 703, + /**/ + +-- +Scientists decoded the first message from an alien civilization: + SIMPLY SEND 6 TIMES 10 TO THE 50 ATOMS OF HYDROGEN TO THE STAR +SYSTEM AT THE TOP OF THE LIST, CROSS OFF THAT STAR SYSTEM, THEN PUT +YOUR STAR SYSTEM AT THE BOTTOM OF THE LIST AND SEND IT TO 100 OTHER +STAR SYSTEMS. WITHIN ONE TENTH GALACTIC ROTATION YOU WILL RECEIVE +ENOUGH HYDROGREN TO POWER YOUR CIVILIZATION UNTIL ENTROPY REACHES ITS +MAXIMUM! IT REALLY WORKS! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8880eecd4e082cac07f4eeef48f6e9fa81e874e2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:14 +0200 Subject: [PATCH 0543/3340] - patchlevel 704 --- 7.3.704 | 90 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) create mode 100644 7.3.704 diff --git a/7.3.704 b/7.3.704 new file mode 100644 index 00000000..3b262bc4 --- /dev/null +++ b/7.3.704 @@ -0,0 +1,90 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.704 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.704 +Problem: Repeating "cgn" does not always work correctly. +Solution: Also fetch the operator character. (Christian Brabandt) +Files: src/normal.c + + +*** ../vim-7.3.703/src/normal.c 2012-08-15 13:30:55.000000000 +0200 +--- src/normal.c 2012-10-21 03:51:38.000000000 +0200 +*************** +*** 960,967 **** + #ifdef FEAT_CMDL_INFO + need_flushbuf |= add_to_showcmd(ca.nchar); + #endif + if (ca.nchar == 'r' || ca.nchar == '\'' || ca.nchar == '`' +! || ca.nchar == Ctrl_BSL) + { + cp = &ca.extra_char; /* need to get a third character */ + if (ca.nchar != 'r') +--- 960,970 ---- + #ifdef FEAT_CMDL_INFO + need_flushbuf |= add_to_showcmd(ca.nchar); + #endif ++ /* For "gn" from redo, need to get one more char to determine the ++ * operator */ + if (ca.nchar == 'r' || ca.nchar == '\'' || ca.nchar == '`' +! || ca.nchar == Ctrl_BSL +! || ((ca.nchar == 'n' || ca.nchar == 'N') && !stuff_empty())) + { + cp = &ca.extra_char; /* need to get a third character */ + if (ca.nchar != 'r') +*************** +*** 1083,1088 **** +--- 1086,1093 ---- + ca.nchar = ca.extra_char; + idx = find_command(ca.cmdchar); + } ++ else if (ca.nchar == 'n' || ca.nchar == 'N') ++ ca.oap->op_type = get_op_type(*cp, NUL); + else if (*cp == Ctrl_BSL) + { + long towait = (p_ttm >= 0 ? p_ttm : p_tm); +*************** +*** 8009,8015 **** + #ifdef FEAT_VISUAL + if (!current_search(cap->count1, cap->nchar == 'n')) + #endif +! beep_flush(); + break; + + /* +--- 8014,8020 ---- + #ifdef FEAT_VISUAL + if (!current_search(cap->count1, cap->nchar == 'n')) + #endif +! clearopbeep(oap); + break; + + /* +*** ../vim-7.3.703/src/version.c 2012-10-21 03:45:57.000000000 +0200 +--- src/version.c 2012-10-21 03:53:51.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 704, + /**/ + +-- +The word "leader" is derived from the word "lead", as in the material that +bullets are made out of. The term "leader" was popularized at about the same +time as the invention of firearms. It grew out of the observation that the +person in charge of every organization was the person whom everyone wanted to +fill with hot lead. + I don't recomment this; it's just a point of historical interest. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 355fcbd83ec2e6e172f5a79ccee22421f4929ab3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:15 +0200 Subject: [PATCH 0544/3340] - patchlevel 705 --- 7.3.705 | 122 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 122 insertions(+) create mode 100644 7.3.705 diff --git a/7.3.705 b/7.3.705 new file mode 100644 index 00000000..6a642e58 --- /dev/null +++ b/7.3.705 @@ -0,0 +1,122 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.705 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.705 +Problem: Mouse features are not sorted properly. (Tony Mechelynck) +Solution: Put the mouse features in alphabetical order. +Files: src/version.c + + +*** ../vim-7.3.704/src/version.c 2012-10-21 03:54:27.000000000 +0200 +--- src/version.c 2012-10-21 03:59:04.000000000 +0200 +*************** +*** 348,353 **** +--- 348,354 ---- + # else + "-mouse", + #endif ++ + #if defined(UNIX) || defined(VMS) + # ifdef FEAT_MOUSE_DEC + "+mouse_dec", +*************** +*** 369,402 **** + # else + "-mouse_netterm", + # endif + # ifdef FEAT_SYSMOUSE + "+mouse_sysmouse", + # else + "-mouse_sysmouse", + # endif +- # ifdef FEAT_MOUSE_XTERM +- "+mouse_xterm", +- # else +- "-mouse_xterm", +- # endif + # ifdef FEAT_MOUSE_URXVT + "+mouse_urxvt", + # else + "-mouse_urxvt", + # endif +! # ifdef FEAT_MOUSE_SGR +! "+mouse_sgr", +! # else +! "-mouse_sgr", +! # endif +! #endif +! #ifdef __QNX__ +! # ifdef FEAT_MOUSE_PTERM +! "+mouse_pterm", + # else +! "-mouse_pterm", + # endif + #endif + #ifdef FEAT_MBYTE_IME + # ifdef DYNAMIC_IME + "+multi_byte_ime/dyn", +--- 370,408 ---- + # else + "-mouse_netterm", + # endif ++ #endif ++ ++ #ifdef __QNX__ ++ # ifdef FEAT_MOUSE_PTERM ++ "+mouse_pterm", ++ # else ++ "-mouse_pterm", ++ # endif ++ #endif ++ ++ #if defined(UNIX) || defined(VMS) ++ # ifdef FEAT_MOUSE_SGR ++ "+mouse_sgr", ++ # else ++ "-mouse_sgr", ++ # endif + # ifdef FEAT_SYSMOUSE + "+mouse_sysmouse", + # else + "-mouse_sysmouse", + # endif + # ifdef FEAT_MOUSE_URXVT + "+mouse_urxvt", + # else + "-mouse_urxvt", + # endif +! # ifdef FEAT_MOUSE_XTERM +! "+mouse_xterm", + # else +! "-mouse_xterm", + # endif + #endif ++ + #ifdef FEAT_MBYTE_IME + # ifdef DYNAMIC_IME + "+multi_byte_ime/dyn", +*** ../vim-7.3.704/src/version.c 2012-10-21 03:54:27.000000000 +0200 +--- src/version.c 2012-10-21 03:59:04.000000000 +0200 +*************** +*** 721,722 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 705, + /**/ + +-- +Are leaders born or made? And if they're made, can we return them under +warranty? + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1fcea193967774d9c76105f2a558b43ba722a476 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:16 +0200 Subject: [PATCH 0545/3340] - patchlevel 706 --- 7.3.706 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.706 diff --git a/7.3.706 b/7.3.706 new file mode 100644 index 00000000..acf74262 --- /dev/null +++ b/7.3.706 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.706 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.706 (after 7.3.697) +Problem: Can't build Motif version. +Solution: Fix wrongly named variable. (Ike Devolder) +Files: src/syntax.c + + +*** ../vim-7.3.705/src/syntax.c 2012-10-21 01:40:24.000000000 +0200 +--- src/syntax.c 2012-10-21 21:22:46.000000000 +0200 +*************** +*** 8082,8088 **** + || do_tooltip + # endif + ) +! if (free_fontset) + gui_mch_free_fontset(HL_TABLE()[idx].sg_fontset); + HL_TABLE()[idx].sg_fontset = fontset_name2handle(arg, 0 + # ifdef FONTSET_ALWAYS +--- 8082,8088 ---- + || do_tooltip + # endif + ) +! if (free_font) + gui_mch_free_fontset(HL_TABLE()[idx].sg_fontset); + HL_TABLE()[idx].sg_fontset = fontset_name2handle(arg, 0 + # ifdef FONTSET_ALWAYS +*** ../vim-7.3.705/src/version.c 2012-10-21 04:00:03.000000000 +0200 +--- src/version.c 2012-10-21 21:25:07.000000000 +0200 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 706, + /**/ + +-- +"You're fired." (1980) +"You're laid off." (1985) +"You're downsized." (1990) +"You're rightsized." (1992) + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fc76dde3e77f2092f5442146b76cce9fd31feb7f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:20 +0200 Subject: [PATCH 0546/3340] - patchlevel 707 --- 7.3.707 | 127 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 127 insertions(+) create mode 100644 7.3.707 diff --git a/7.3.707 b/7.3.707 new file mode 100644 index 00000000..a541b2e9 --- /dev/null +++ b/7.3.707 @@ -0,0 +1,127 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.707 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.707 (after 7.3.701) +Problem: Problems loading a library for a file name with non-latin + characters. +Solution: Use wide system functions when possible. (Ken Takata) +Files: src/os_win32.c, src/os_win32.h + + +*** ../vim-7.3.706/src/os_win32.c 2012-10-21 02:37:02.000000000 +0200 +--- src/os_win32.c 2012-10-21 21:33:58.000000000 +0200 +*************** +*** 287,313 **** + HINSTANCE + vimLoadLib(char *name) + { +! HINSTANCE dll = NULL; +! TCHAR old_dir[MAXPATHL]; + + /* NOTE: Do not use mch_dirname() and mch_chdir() here, they may call + * vimLoadLib() recursively, which causes a stack overflow. */ + if (exe_path == NULL) + get_exe_name(); +! if (exe_path != NULL && GetCurrentDirectory(MAXPATHL, old_dir) != 0) + { +! /* Change directory to where the executable is, both to make sure we +! * find a .dll there and to avoid looking for a .dll in the current +! * directory. */ +! SetCurrentDirectory(exe_path); +! dll = LoadLibrary(name); +! SetCurrentDirectory(old_dir); +! } +! else +! { +! /* We are not able to change directory to where the executable is, try +! * to load library anyway. */ +! dll = LoadLibrary(name); + } + return dll; + } +--- 287,326 ---- + HINSTANCE + vimLoadLib(char *name) + { +! HINSTANCE dll = NULL; +! char old_dir[MAXPATHL]; + + /* NOTE: Do not use mch_dirname() and mch_chdir() here, they may call + * vimLoadLib() recursively, which causes a stack overflow. */ + if (exe_path == NULL) + get_exe_name(); +! if (exe_path != NULL) + { +! #ifdef FEAT_MBYTE +! WCHAR old_dirw[MAXPATHL]; +! +! if (GetCurrentDirectoryW(MAXPATHL, old_dirw) != 0) +! { +! /* Change directory to where the executable is, both to make +! * sure we find a .dll there and to avoid looking for a .dll +! * in the current directory. */ +! SetCurrentDirectory(exe_path); +! dll = LoadLibrary(name); +! SetCurrentDirectoryW(old_dirw); +! return dll; +! } +! /* Retry with non-wide function (for Windows 98). */ +! if (GetLastError() == ERROR_CALL_NOT_IMPLEMENTED) +! #endif +! if (GetCurrentDirectory(MAXPATHL, old_dir) != 0) +! { +! /* Change directory to where the executable is, both to make +! * sure we find a .dll there and to avoid looking for a .dll +! * in the current directory. */ +! SetCurrentDirectory(exe_path); +! dll = LoadLibrary(name); +! SetCurrentDirectory(old_dir); +! } + } + return dll; + } +*** ../vim-7.3.706/src/os_win32.h 2011-08-10 17:07:56.000000000 +0200 +--- src/os_win32.h 2012-10-21 21:33:30.000000000 +0200 +*************** +*** 108,114 **** + */ + #define CMDBUFFSIZE 1024 /* size of the command processing buffer */ + +! /* _MAX_PATH is only 256 (stdlib.h), but we want more for the 'path' option, + * thus use a larger number. */ + #define MAXPATHL 1024 + +--- 108,114 ---- + */ + #define CMDBUFFSIZE 1024 /* size of the command processing buffer */ + +! /* _MAX_PATH is only 260 (stdlib.h), but we want more for the 'path' option, + * thus use a larger number. */ + #define MAXPATHL 1024 + +*** ../vim-7.3.706/src/version.c 2012-10-21 21:25:17.000000000 +0200 +--- src/version.c 2012-10-21 21:37:52.000000000 +0200 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 707, + /**/ + +-- +Our job was to build a computer information system for the branch banks. We +were the perfect people for the job: Dean had seen a computer once, and I had +heard Dean talk about it. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4b72b19a9c9c82234d49793c29dbb0514a5ccb44 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:21 +0200 Subject: [PATCH 0547/3340] - patchlevel 708 --- 7.3.708 | 107 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 107 insertions(+) create mode 100644 7.3.708 diff --git a/7.3.708 b/7.3.708 new file mode 100644 index 00000000..644930d1 --- /dev/null +++ b/7.3.708 @@ -0,0 +1,107 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.708 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.708 +Problem: Filler lines above the first line may be hidden when opening Vim. +Solution: Change how topfill is computed. (Christian Brabandt) +Files: src/diff.c, src/testdir/test47.in, src/testdir/test47.ok + + +*** ../vim-7.3.707/src/diff.c 2012-05-18 18:47:11.000000000 +0200 +--- src/diff.c 2012-10-21 22:08:44.000000000 +0200 +*************** +*** 615,625 **** + #endif + /* A change may have made filler lines invalid, need to take care + * of that for other windows. */ +! if (wp != curwin && wp->w_topfill > 0) + { +- n = diff_check(wp, wp->w_topline); + if (wp->w_topfill > n) + wp->w_topfill = (n < 0 ? 0 : n); + } + } + } +--- 615,627 ---- + #endif + /* A change may have made filler lines invalid, need to take care + * of that for other windows. */ +! n = diff_check(wp, wp->w_topline); +! if ((wp != curwin && wp->w_topfill > 0) || n > 0) + { + if (wp->w_topfill > n) + wp->w_topfill = (n < 0 ? 0 : n); ++ else if (n > 0 && n > wp->w_topfill) ++ wp->w_topfill = n; + } + } + } +*** ../vim-7.3.707/src/testdir/test47.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test47.in 2012-10-21 22:08:44.000000000 +0200 +*************** +*** 36,42 **** + :call append("$", two) + :call append("$", three) + :$-2,$w! test.out +! :unlet one two three + :qa! + ENDTEST + +--- 36,57 ---- + :call append("$", two) + :call append("$", three) + :$-2,$w! test.out +! :" Test that diffing shows correct filler lines +! :diffoff! +! :windo :bw! +! :enew +! :put =range(4,10) +! :1d _ +! :vnew +! :put =range(1,10) +! :1d _ +! :windo :diffthis +! :wincmd h +! :let w0=line('w0') +! :enew +! :put =w0 +! :.w >> test.out +! :unlet! one two three w0 + :qa! + ENDTEST + +*** ../vim-7.3.707/src/testdir/test47.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test47.ok 2012-10-21 22:08:44.000000000 +0200 +*************** +*** 1,3 **** +--- 1,4 ---- + 2-4-5-6-8-9 + 1-2-4-5-8 + 2-3-4-5-6-7-8 ++ 1 +*** ../vim-7.3.707/src/version.c 2012-10-21 21:38:42.000000000 +0200 +--- src/version.c 2012-10-21 22:10:42.000000000 +0200 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 708, + /**/ + +-- +At some point in the project somebody will start whining about the need to +determine the project "requirements". This involves interviewing people who +don't know what they want but, curiously, know exactly when they need it. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 699b89753ee3d3579e8d3bc7c66bcf41ab5d7cb0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:22 +0200 Subject: [PATCH 0548/3340] - patchlevel 709 --- 7.3.709 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.709 diff --git a/7.3.709 b/7.3.709 new file mode 100644 index 00000000..40c837fc --- /dev/null +++ b/7.3.709 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.709 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.709 +Problem: Compiler warning for unused argument. +Solution: Add UNUSED. +Files: src/eval.c + + +*** ../vim-7.3.708/src/eval.c 2012-10-21 02:17:28.000000000 +0200 +--- src/eval.c 2012-10-21 23:53:32.000000000 +0200 +*************** +*** 16664,16670 **** + */ + static void + f_shiftwidth(argvars, rettv) +! typval_T *argvars; + typval_T *rettv; + { + rettv->vval.v_number = get_sw_value(); +--- 16664,16670 ---- + */ + static void + f_shiftwidth(argvars, rettv) +! typval_T *argvars UNUSED; + typval_T *rettv; + { + rettv->vval.v_number = get_sw_value(); +*** ../vim-7.3.708/src/version.c 2012-10-21 22:18:17.000000000 +0200 +--- src/version.c 2012-10-21 23:55:01.000000000 +0200 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 709, + /**/ + +-- +The only way the average employee can speak to an executive is by taking a +second job as a golf caddie. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2a4610ed67bcc5bd9ae18fbf4a7253c0a9eae7c7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:22 +0200 Subject: [PATCH 0549/3340] - patchlevel 710 --- 7.3.710 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.710 diff --git a/7.3.710 b/7.3.710 new file mode 100644 index 00000000..bfefea36 --- /dev/null +++ b/7.3.710 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.710 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.710 (after 7.3.704) +Problem: Patch 7.3.704 breaks "fn". +Solution: Add check for ca.cmdchar. (Christian Brabandt) +Files: src/normal.c + + +*** ../vim-7.3.709/src/normal.c 2012-10-21 03:54:27.000000000 +0200 +--- src/normal.c 2012-10-23 05:02:27.000000000 +0200 +*************** +*** 1086,1092 **** + ca.nchar = ca.extra_char; + idx = find_command(ca.cmdchar); + } +! else if (ca.nchar == 'n' || ca.nchar == 'N') + ca.oap->op_type = get_op_type(*cp, NUL); + else if (*cp == Ctrl_BSL) + { +--- 1086,1092 ---- + ca.nchar = ca.extra_char; + idx = find_command(ca.cmdchar); + } +! else if ((ca.nchar == 'n' || ca.nchar == 'N') && ca.cmdchar == 'g') + ca.oap->op_type = get_op_type(*cp, NUL); + else if (*cp == Ctrl_BSL) + { +*** ../vim-7.3.709/src/version.c 2012-10-21 23:55:59.000000000 +0200 +--- src/version.c 2012-10-23 04:59:21.000000000 +0200 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 710, + /**/ + +-- +The budget process was invented by an alien race of sadistic beings who +resemble large cats. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4367eaabdfc5594ff8efda16e33a242fc4561472 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:28 +0200 Subject: [PATCH 0550/3340] - patchlevel 711 --- 7.3.711 | 178 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 178 insertions(+) create mode 100644 7.3.711 diff --git a/7.3.711 b/7.3.711 new file mode 100644 index 00000000..74ef3cbc --- /dev/null +++ b/7.3.711 @@ -0,0 +1,178 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.711 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.711 (after 7.3.688) +Problem: vim.current.buffer is not available. (lilydjwg) +Solution: Use py3_PyUnicode_AsUTF8 instead of py3_PyUnicode_AsUTF8String. + (Ken Takata) +Files: src/if_python3.c + + +*** ../vim-7.3.710/src/if_python3.c 2012-10-21 01:46:56.000000000 +0200 +--- src/if_python3.c 2012-10-23 05:15:31.000000000 +0200 +*************** +*** 176,182 **** + # define PyImport_AppendInittab py3_PyImport_AppendInittab + # if PY_VERSION_HEX >= 0x030300f0 + # undef _PyUnicode_AsString +! # define _PyUnicode_AsString py3_PyUnicode_AsUTF8String + # else + # define _PyUnicode_AsString py3__PyUnicode_AsString + # endif +--- 176,182 ---- + # define PyImport_AppendInittab py3_PyImport_AppendInittab + # if PY_VERSION_HEX >= 0x030300f0 + # undef _PyUnicode_AsString +! # define _PyUnicode_AsString py3_PyUnicode_AsUTF8 + # else + # define _PyUnicode_AsString py3__PyUnicode_AsString + # endif +*************** +*** 286,296 **** + static PyObject* py3__Py_TrueStruct; + static int (*py3_PyModule_AddObject)(PyObject *m, const char *name, PyObject *o); + static int (*py3_PyImport_AppendInittab)(const char *name, PyObject* (*initfunc)(void)); +! #if PY_VERSION_HEX >= 0x030300f0 +! static char* (*py3_PyUnicode_AsUTF8String)(PyObject *unicode); +! #else + static char* (*py3__PyUnicode_AsString)(PyObject *unicode); +! #endif + static PyObject* (*py3_PyUnicode_AsEncodedString)(PyObject *unicode, const char* encoding, const char* errors); + static char* (*py3_PyBytes_AsString)(PyObject *bytes); + static int (*py3_PyBytes_AsStringAndSize)(PyObject *bytes, char **buffer, int *length); +--- 286,296 ---- + static PyObject* py3__Py_TrueStruct; + static int (*py3_PyModule_AddObject)(PyObject *m, const char *name, PyObject *o); + static int (*py3_PyImport_AppendInittab)(const char *name, PyObject* (*initfunc)(void)); +! # if PY_VERSION_HEX >= 0x030300f0 +! static char* (*py3_PyUnicode_AsUTF8)(PyObject *unicode); +! # else + static char* (*py3__PyUnicode_AsString)(PyObject *unicode); +! # endif + static PyObject* (*py3_PyUnicode_AsEncodedString)(PyObject *unicode, const char* encoding, const char* errors); + static char* (*py3_PyBytes_AsString)(PyObject *bytes); + static int (*py3_PyBytes_AsStringAndSize)(PyObject *bytes, char **buffer, int *length); +*************** +*** 348,360 **** + {"PySys_SetArgv", (PYTHON_PROC*)&py3_PySys_SetArgv}, + {"Py_SetPythonHome", (PYTHON_PROC*)&py3_Py_SetPythonHome}, + {"Py_Initialize", (PYTHON_PROC*)&py3_Py_Initialize}, +! #ifndef PY_SSIZE_T_CLEAN + {"PyArg_ParseTuple", (PYTHON_PROC*)&py3_PyArg_ParseTuple}, + {"Py_BuildValue", (PYTHON_PROC*)&py3_Py_BuildValue}, +! #else + {"_PyArg_ParseTuple_SizeT", (PYTHON_PROC*)&py3_PyArg_ParseTuple}, + {"_Py_BuildValue_SizeT", (PYTHON_PROC*)&py3_Py_BuildValue}, +! #endif + {"PyMem_Free", (PYTHON_PROC*)&py3_PyMem_Free}, + {"PyMem_Malloc", (PYTHON_PROC*)&py3_PyMem_Malloc}, + {"PyList_New", (PYTHON_PROC*)&py3_PyList_New}, +--- 348,360 ---- + {"PySys_SetArgv", (PYTHON_PROC*)&py3_PySys_SetArgv}, + {"Py_SetPythonHome", (PYTHON_PROC*)&py3_Py_SetPythonHome}, + {"Py_Initialize", (PYTHON_PROC*)&py3_Py_Initialize}, +! # ifndef PY_SSIZE_T_CLEAN + {"PyArg_ParseTuple", (PYTHON_PROC*)&py3_PyArg_ParseTuple}, + {"Py_BuildValue", (PYTHON_PROC*)&py3_Py_BuildValue}, +! # else + {"_PyArg_ParseTuple_SizeT", (PYTHON_PROC*)&py3_PyArg_ParseTuple}, + {"_Py_BuildValue_SizeT", (PYTHON_PROC*)&py3_Py_BuildValue}, +! # endif + {"PyMem_Free", (PYTHON_PROC*)&py3_PyMem_Free}, + {"PyMem_Malloc", (PYTHON_PROC*)&py3_PyMem_Malloc}, + {"PyList_New", (PYTHON_PROC*)&py3_PyList_New}, +*************** +*** 406,416 **** + {"PyObject_Init", (PYTHON_PROC*)&py3__PyObject_Init}, + {"PyModule_AddObject", (PYTHON_PROC*)&py3_PyModule_AddObject}, + {"PyImport_AppendInittab", (PYTHON_PROC*)&py3_PyImport_AppendInittab}, +! #if PY_VERSION_HEX >= 0x030300f0 +! {"PyUnicode_AsUTF8String", (PYTHON_PROC*)&py3_PyUnicode_AsUTF8String}, +! #else + {"_PyUnicode_AsString", (PYTHON_PROC*)&py3__PyUnicode_AsString}, +! #endif + {"PyBytes_AsString", (PYTHON_PROC*)&py3_PyBytes_AsString}, + {"PyBytes_AsStringAndSize", (PYTHON_PROC*)&py3_PyBytes_AsStringAndSize}, + {"PyBytes_FromString", (PYTHON_PROC*)&py3_PyBytes_FromString}, +--- 406,416 ---- + {"PyObject_Init", (PYTHON_PROC*)&py3__PyObject_Init}, + {"PyModule_AddObject", (PYTHON_PROC*)&py3_PyModule_AddObject}, + {"PyImport_AppendInittab", (PYTHON_PROC*)&py3_PyImport_AppendInittab}, +! # if PY_VERSION_HEX >= 0x030300f0 +! {"PyUnicode_AsUTF8", (PYTHON_PROC*)&py3_PyUnicode_AsUTF8}, +! # else + {"_PyUnicode_AsString", (PYTHON_PROC*)&py3__PyUnicode_AsString}, +! # endif + {"PyBytes_AsString", (PYTHON_PROC*)&py3_PyBytes_AsString}, + {"PyBytes_AsStringAndSize", (PYTHON_PROC*)&py3_PyBytes_AsStringAndSize}, + {"PyBytes_FromString", (PYTHON_PROC*)&py3_PyBytes_FromString}, +*************** +*** 503,514 **** + + /* Load unicode functions separately as only the ucs2 or the ucs4 functions + * will be present in the library. */ +! #if PY_VERSION_HEX >= 0x030300f0 + ucs_from_string = symbol_from_dll(hinstPy3, "PyUnicode_FromString"); + ucs_decode = symbol_from_dll(hinstPy3, "PyUnicode_Decode"); + ucs_as_encoded_string = symbol_from_dll(hinstPy3, + "PyUnicode_AsEncodedString"); +! #else + ucs_from_string = symbol_from_dll(hinstPy3, "PyUnicodeUCS2_FromString"); + ucs_decode = symbol_from_dll(hinstPy3, + "PyUnicodeUCS2_Decode"); +--- 503,514 ---- + + /* Load unicode functions separately as only the ucs2 or the ucs4 functions + * will be present in the library. */ +! # if PY_VERSION_HEX >= 0x030300f0 + ucs_from_string = symbol_from_dll(hinstPy3, "PyUnicode_FromString"); + ucs_decode = symbol_from_dll(hinstPy3, "PyUnicode_Decode"); + ucs_as_encoded_string = symbol_from_dll(hinstPy3, + "PyUnicode_AsEncodedString"); +! # else + ucs_from_string = symbol_from_dll(hinstPy3, "PyUnicodeUCS2_FromString"); + ucs_decode = symbol_from_dll(hinstPy3, + "PyUnicodeUCS2_Decode"); +*************** +*** 523,529 **** + ucs_as_encoded_string = symbol_from_dll(hinstPy3, + "PyUnicodeUCS4_AsEncodedString"); + } +! #endif + if (ucs_from_string && ucs_decode && ucs_as_encoded_string) + { + py3_PyUnicode_FromString = ucs_from_string; +--- 523,529 ---- + ucs_as_encoded_string = symbol_from_dll(hinstPy3, + "PyUnicodeUCS4_AsEncodedString"); + } +! # endif + if (ucs_from_string && ucs_decode && ucs_as_encoded_string) + { + py3_PyUnicode_FromString = ucs_from_string; +*** ../vim-7.3.710/src/version.c 2012-10-23 05:08:49.000000000 +0200 +--- src/version.c 2012-10-23 05:14:27.000000000 +0200 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 711, + /**/ + +-- +The fastest way to get an engineer to solve a problem is to declare that the +problem is unsolvable. No engineer can walk away from an unsolvable problem +until it's solved. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b925d98c69730ff0218e6d7695a68eb447dd6cc2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:29 +0200 Subject: [PATCH 0551/3340] - patchlevel 712 --- 7.3.712 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.712 diff --git a/7.3.712 b/7.3.712 new file mode 100644 index 00000000..2ca9fb9a --- /dev/null +++ b/7.3.712 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.712 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.712 +Problem: Nmake from VS2010 SP1 is not recognized. +Solution: Add the version number. (Ken Takata) +Files: src/Make_mvc.mak + + +*** ../vim-7.3.711/src/Make_mvc.mak 2012-10-21 02:41:04.000000000 +0200 +--- src/Make_mvc.mak 2012-10-23 05:33:33.000000000 +0200 +*************** +*** 407,412 **** +--- 407,415 ---- + !if "$(_NMAKE_VER)" == "10.00.30319.01" + MSVCVER = 10.0 + !endif ++ !if "$(_NMAKE_VER)" == "10.00.40219.01" ++ MSVCVER = 10.0 ++ !endif + !if "$(_NMAKE_VER)" == "11.00.50727.1" + MSVCVER = 11.0 + !endif +*** ../vim-7.3.711/src/version.c 2012-10-23 05:17:33.000000000 +0200 +--- src/version.c 2012-10-23 05:34:24.000000000 +0200 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 712, + /**/ + +-- +Engineers are widely recognized as superior marriage material: intelligent, +dependable, employed, honest, and handy around the house. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 32cfa5ae4064caf65352946f3a17947b69d1b323 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 23 Oct 2012 12:13:33 +0200 Subject: [PATCH 0552/3340] - patchlevel 712 --- README.patches | 21 +++++++++++++++++++++ vim.spec | 47 ++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 67 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index dc198b3a..c407164b 100644 --- a/README.patches +++ b/README.patches @@ -722,3 +722,24 @@ Individual patches for Vim 7.3: 2266 7.3.689 MzScheme and Lua may use a NULL string 1806 7.3.690 crash with directory name equal to maximum path length 1910 7.3.691 state specific to the Python thread is discarded + 1598 7.3.692 can't build GTK version with GTK 2.0 + 5071 7.3.693 can't make 'softtabstop' follow 'shiftwidth' + 4631 7.3.694 'shiftwidth' is not so easy to use in indent files + 3710 7.3.695 balloon cannot show multi-byte text + 2994 7.3.696 message about added spell language can be wrong + 6108 7.3.697 leaking resources when setting GUI font + 2742 7.3.698 Python 3 does not preserve state beween commands + 2522 7.3.699 manually set 'ttymouse' is overruled by automatic detection + 2214 7.3.700 cannot detect URXVT and SGR mouse support + 2616 7.3.701 MS-Windows: Crash with stack overflow when setting 'encoding' + 1352 7.3.702 nmake from VS6 service pack 6 is not recognized + 3326 7.3.703 when 'undofile' is reset the hash is computed unnecessarily + 2906 7.3.704 repeating "cgn" does not always work correctly + 2581 7.3.705 mouse features are not in alphabetical order + 1638 7.3.706 (after 7.3.697) can't build Motif version + 4088 7.3.707 (after 7.3.701) library name with non-latin characters fails + 3001 7.3.708 filler lines above the first line may be hidden + 1513 7.3.709 compiler warning for unused argument + 1685 7.3.710 (after 7.3.704) "fn" is broken + 7579 7.3.711 (after 7.3.688) vim.current.buffer is not available + 1474 7.3.712 nmake from VS2010 SP1 is not recognized diff --git a/vim.spec b/vim.spec index 8bf941f9..80801bb1 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 691 +%define patchlevel 712 Summary: The VIM editor URL: http://www.vim.org/ @@ -747,6 +747,27 @@ Patch688: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.688 Patch689: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.689 Patch690: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.690 Patch691: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.691 +Patch692: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.692 +Patch693: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.693 +Patch694: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.694 +Patch695: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.695 +Patch696: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.696 +Patch697: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.697 +Patch698: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.698 +Patch699: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.699 +Patch700: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.700 +Patch701: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.701 +Patch702: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.702 +Patch703: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.703 +Patch704: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.704 +Patch705: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.705 +Patch706: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.706 +Patch707: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.707 +Patch708: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.708 +Patch709: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.709 +Patch710: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.710 +Patch711: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.711 +Patch712: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.712 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1584,6 +1605,27 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch689 -p0 %patch690 -p0 %patch691 -p0 +%patch692 -p0 +%patch693 -p0 +%patch694 -p0 +%patch695 -p0 +%patch696 -p0 +%patch697 -p0 +%patch698 -p0 +%patch699 -p0 +%patch700 -p0 +%patch701 -p0 +%patch702 -p0 +%patch703 -p0 +%patch704 -p0 +%patch705 -p0 +%patch706 -p0 +%patch707 -p0 +%patch708 -p0 +%patch709 -p0 +%patch710 -p0 +%patch711 -p0 +%patch712 -p0 # install spell files @@ -2046,6 +2088,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Tue Oct 23 2012 Karsten Hopp 7.3.712-1 +- patchlevel 712 + * Mon Oct 15 2012 Karsten Hopp 7.3.691-1 - patchlevel 691 From 92c34514b4fef6b9100bd975085347e32929765d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:26:53 +0100 Subject: [PATCH 0553/3340] fix vim.csh syntax --- vim.spec | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/vim.spec b/vim.spec index 927813fc..cb99c211 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1%{?dist} +Release: 2%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -1775,8 +1775,11 @@ if [ -n "\$BASH_VERSION" -o -n "\$KSH_VERSION" -o -n "\$ZSH_VERSION" ]; then fi EOF cat >$RPM_BUILD_ROOT/%{_sysconfdir}/profile.d/vim.csh < 100 ) then + alias vi vim + endif +endif EOF chmod 0644 $RPM_BUILD_ROOT/%{_sysconfdir}/profile.d/* install -p -m644 %{SOURCE4} $RPM_BUILD_ROOT/%{_sysconfdir}/vimrc @@ -2028,6 +2031,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Nov 12 2012 Karsten Hopp 7.3.682-2 +- fix vim.csh syntax + * Fri Oct 05 2012 Karsten Hopp 7.3.682-1 - patchlevel 682 - use --enable-rubyinterp=dynamic and --enable-pythoninterp=dynamic From dc681d156f2d8280be3c1d94fa8d49ace08c0a60 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:30:14 +0100 Subject: [PATCH 0554/3340] - patchlevel 683 --- 7.3.683 | 88 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 88 insertions(+) create mode 100644 7.3.683 diff --git a/7.3.683 b/7.3.683 new file mode 100644 index 00000000..b26d3980 --- /dev/null +++ b/7.3.683 @@ -0,0 +1,88 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.683 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.683 +Problem: ":python" may crash when vimbindeval() returns None. +Solution: Check for v_string to be NULL. (Yukihiro Nakadaira) +Files: src/if_py_both.h + + +*** ../vim-7.3.682/src/if_py_both.h 2012-09-21 14:00:05.000000000 +0200 +--- src/if_py_both.h 2012-10-05 21:05:06.000000000 +0200 +*************** +*** 351,357 **** + + if (our_tv->v_type == VAR_STRING) + { +! result = Py_BuildValue("s", our_tv->vval.v_string); + } + else if (our_tv->v_type == VAR_NUMBER) + { +--- 351,358 ---- + + if (our_tv->v_type == VAR_STRING) + { +! result = Py_BuildValue("s", our_tv->vval.v_string == NULL +! ? "" : (char *)our_tv->vval.v_string); + } + else if (our_tv->v_type == VAR_NUMBER) + { +*************** +*** 2751,2757 **** + switch (tv->v_type) + { + case VAR_STRING: +! return PyBytes_FromString((char *) tv->vval.v_string); + case VAR_NUMBER: + return PyLong_FromLong((long) tv->vval.v_number); + #ifdef FEAT_FLOAT +--- 2752,2759 ---- + switch (tv->v_type) + { + case VAR_STRING: +! return PyBytes_FromString(tv->vval.v_string == NULL +! ? "" : (char *)tv->vval.v_string); + case VAR_NUMBER: + return PyLong_FromLong((long) tv->vval.v_number); + #ifdef FEAT_FLOAT +*************** +*** 2763,2769 **** + case VAR_DICT: + return DictionaryNew(tv->vval.v_dict); + case VAR_FUNC: +! return FunctionNew(tv->vval.v_string); + case VAR_UNKNOWN: + Py_INCREF(Py_None); + return Py_None; +--- 2765,2772 ---- + case VAR_DICT: + return DictionaryNew(tv->vval.v_dict); + case VAR_FUNC: +! return FunctionNew(tv->vval.v_string == NULL +! ? (char_u *)"" : tv->vval.v_string); + case VAR_UNKNOWN: + Py_INCREF(Py_None); + return Py_None; +*** ../vim-7.3.682/src/version.c 2012-10-04 22:38:32.000000000 +0200 +--- src/version.c 2012-10-05 21:04:19.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 683, + /**/ + +-- +SIGIRO -- irony detected (iron core dumped) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ea05e50e6d79075f578912bff7d0f5d71fde47d4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:30:16 +0100 Subject: [PATCH 0555/3340] - patchlevel 684 --- 7.3.684 | 132 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 132 insertions(+) create mode 100644 7.3.684 diff --git a/7.3.684 b/7.3.684 new file mode 100644 index 00000000..0e9119be --- /dev/null +++ b/7.3.684 @@ -0,0 +1,132 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.684 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.684 +Problem: "make test" does not delete lua.vim. +Solution: Add lua.vim to the clean target. (Simon Ruderich) +Files: src/testdir/Makefile, src/testdir/Make_dos.mak, + src/testdir/Make_ming.mak, src/testdir/Make_vms.mms + + +*** ../vim-7.3.683/src/testdir/Makefile 2012-06-29 12:54:32.000000000 +0200 +--- src/testdir/Makefile 2012-10-06 19:04:54.000000000 +0200 +*************** +*** 48,57 **** + $(SCRIPTS) $(SCRIPTS_GUI): $(VIMPROG) + + clean: +! -rm -rf *.out *.failed *.rej *.orig test.log tiny.vim small.vim mbyte.vim mzscheme.vim test.ok X* valgrind.* viminfo + + test1.out: test1.in +! -rm -f $*.failed tiny.vim small.vim mbyte.vim mzscheme.vim test.ok X* viminfo + $(VALGRIND) $(VIMPROG) -u unix.vim -U NONE --noplugin -s dotest.in $*.in + @/bin/sh -c "if diff test.out $*.ok; \ + then mv -f test.out $*.out; \ +--- 48,57 ---- + $(SCRIPTS) $(SCRIPTS_GUI): $(VIMPROG) + + clean: +! -rm -rf *.out *.failed *.rej *.orig test.log tiny.vim small.vim mbyte.vim mzscheme.vim lua.vim test.ok X* valgrind.* viminfo + + test1.out: test1.in +! -rm -f $*.failed tiny.vim small.vim mbyte.vim mzscheme.vim lua.vim test.ok X* viminfo + $(VALGRIND) $(VIMPROG) -u unix.vim -U NONE --noplugin -s dotest.in $*.in + @/bin/sh -c "if diff test.out $*.ok; \ + then mv -f test.out $*.out; \ +*************** +*** 73,79 **** + fi \ + else echo $* NO OUTPUT >>test.log; \ + fi" +! # -rm -rf X* test.ok viminfo + + test49.out: test49.vim + +--- 73,79 ---- + fi \ + else echo $* NO OUTPUT >>test.log; \ + fi" +! -rm -rf X* test.ok viminfo + + test49.out: test49.vim + +*** ../vim-7.3.683/src/testdir/Make_dos.mak 2012-06-29 12:54:32.000000000 +0200 +--- src/testdir/Make_dos.mak 2012-10-06 19:04:02.000000000 +0200 +*************** +*** 62,67 **** +--- 62,68 ---- + -if exist tiny.vim del tiny.vim + -if exist mbyte.vim del mbyte.vim + -if exist mzscheme.vim del mzscheme.vim ++ -if exist lua.vim del lua.vim + -del X* + -if exist viminfo del viminfo + +*** ../vim-7.3.683/src/testdir/Make_ming.mak 2012-06-29 12:54:32.000000000 +0200 +--- src/testdir/Make_ming.mak 2012-10-06 19:04:08.000000000 +0200 +*************** +*** 85,90 **** +--- 85,91 ---- + -$(DEL) tiny.vim + -$(DEL) mbyte.vim + -$(DEL) mzscheme.vim ++ -$(DEL) lua.vim + -$(DEL) X* + -$(DEL) viminfo + +*** ../vim-7.3.683/src/testdir/Make_vms.mms 2012-04-05 16:56:38.000000000 +0200 +--- src/testdir/Make_vms.mms 2012-10-06 19:04:34.000000000 +0200 +*************** +*** 4,10 **** + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2012 Apr 05 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +--- 4,10 ---- + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2012 Oct 06 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +*************** +*** 184,188 **** +--- 184,189 ---- + -@ if "''F$SEARCH("small.vim")'" .NES. "" then delete/noconfirm/nolog small.vim.* + -@ if "''F$SEARCH("mbyte.vim")'" .NES. "" then delete/noconfirm/nolog mbyte.vim.* + -@ if "''F$SEARCH("mzscheme.vim")'" .NES. "" then delete/noconfirm/nolog mzscheme.vim.* ++ -@ if "''F$SEARCH("lua.vim")'" .NES. "" then delete/noconfirm/nolog lua.vim.* + -@ if "''F$SEARCH("viminfo.*")'" .NES. "" then delete/noconfirm/nolog viminfo.*.* + +*** ../vim-7.3.683/src/version.c 2012-10-05 21:30:04.000000000 +0200 +--- src/version.c 2012-10-06 18:59:40.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 684, + /**/ + +-- +ERIC IDLE PLAYED: THE DEAD COLLECTOR, MR BINT (A VILLAGE NE'ER-DO -WELL VERY + KEEN ON BURNING WITCHES), SIR ROBIN, THE GUARD WHO DOESN'T + HICOUGH BUT TRIES TO GET THINGS STRAIGHT, CONCORDE (SIR + LAUNCELOT'S TRUSTY STEED), ROGER THE SHRUBBER (A SHRUBBER), + BROTHER MAYNARD + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 693ccd771489bd7f8e5e94221e258175d12039ba Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:30:17 +0100 Subject: [PATCH 0556/3340] - patchlevel 685 --- 7.3.685 | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 7.3.685 diff --git a/7.3.685 b/7.3.685 new file mode 100644 index 00000000..58cf4e94 --- /dev/null +++ b/7.3.685 @@ -0,0 +1,64 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.685 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.685 +Problem: No test for what patch 7.3.673 fixes. +Solution: Add a test. (Christian Brabandt) +Files: src/testdir/test53.in, src/testdir/test53.ok + + +*** ../vim-7.3.684/src/testdir/test53.in 2012-09-05 12:16:40.000000000 +0200 +--- src/testdir/test53.in 2012-10-11 03:31:27.000000000 +0200 +*************** +*** 42,47 **** +--- 42,50 ---- + gnd$h/\zs + gnd/[u]niquepattern/s + vlgnd ++ /mother ++ :set selection=exclusive ++ $cgNmongoose + :/^start:/,/^end:/wq! test.out + ENDTEST + +*************** +*** 69,72 **** +--- 72,76 ---- + zero width pattern + delete first and last chars + uniquepattern uniquepattern ++ my very excellent mother just served us nachos + end: +*** ../vim-7.3.684/src/testdir/test53.ok 2012-09-05 12:16:40.000000000 +0200 +--- src/testdir/test53.ok 2012-10-11 03:31:33.000000000 +0200 +*************** +*** 25,28 **** +--- 25,29 ---- + zerowidth pattern + elete first and last char + uniquepattern ++ my very excellent mongoose just served us nachos + end: +*** ../vim-7.3.684/src/version.c 2012-10-06 19:10:29.000000000 +0200 +--- src/version.c 2012-10-11 03:34:06.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 685, + /**/ + +-- +FATAL ERROR! SYSTEM HALTED! - Press any key to continue doing nothing. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9bf779c9b3963230e654b8fadd6fa5a7c22db773 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:30:17 +0100 Subject: [PATCH 0557/3340] - patchlevel 686 --- 7.3.686 | 63 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 7.3.686 diff --git a/7.3.686 b/7.3.686 new file mode 100644 index 00000000..81d23696 --- /dev/null +++ b/7.3.686 @@ -0,0 +1,63 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.686 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.686 +Problem: Using CTRL-\ e mappings is useful also when entering an + expression, but it doesn't work. (Marcin Szamotulski) +Solution: Allow using CTRL-\ e when entering an expression if it was not + typed. +Files: src/ex_getln.c + + +*** ../vim-7.3.685/src/ex_getln.c 2012-08-15 14:04:50.000000000 +0200 +--- src/ex_getln.c 2012-10-11 03:54:04.000000000 +0200 +*************** +*** 667,675 **** + c = plain_vgetc(); + --no_mapping; + --allow_keys; +! /* CTRL-\ e doesn't work when obtaining an expression. */ +! if (c != Ctrl_N && c != Ctrl_G +! && (c != 'e' || ccline.cmdfirstc == '=')) + { + vungetc(c); + c = Ctrl_BSL; +--- 667,676 ---- + c = plain_vgetc(); + --no_mapping; + --allow_keys; +! /* CTRL-\ e doesn't work when obtaining an expression, unless it +! * is in a mapping. */ +! if (c != Ctrl_N && c != Ctrl_G && (c != 'e' +! || (ccline.cmdfirstc == '=' && KeyTyped))) + { + vungetc(c); + c = Ctrl_BSL; +*** ../vim-7.3.685/src/version.c 2012-10-11 03:35:38.000000000 +0200 +--- src/version.c 2012-10-11 04:03:19.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 686, + /**/ + +-- +(letter from Mark to Mike, about the film's probable certificate) + I would like to get back to the Censor and agree to lose the shits, take + the odd Jesus Christ out and lose Oh fuck off, but to retain 'fart in + your general direction', 'castanets of your testicles' and 'oral sex' + and ask him for an 'A' rating on that basis. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4a262023893540c39a1a288facf7cbcd03c7b61f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:30:23 +0100 Subject: [PATCH 0558/3340] - patchlevel 687 --- 7.3.687 | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 7.3.687 diff --git a/7.3.687 b/7.3.687 new file mode 100644 index 00000000..a98c3631 --- /dev/null +++ b/7.3.687 @@ -0,0 +1,44 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.687 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.687 +Problem: Test 16 fails when $DISPLAY is not set. +Solution: Skip the test when $DISPLAY is not set. +Files: src/testdir/test16.in + + +*** ../vim-7.3.686/src/testdir/test16.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test16.in 2012-10-11 04:02:11.000000000 +0200 +*************** +*** 2,7 **** +--- 2,8 ---- + For KDE set a font, empty 'guifont' may cause a hang. + + STARTTEST ++ :if $DISPLAY == "" | e! test.ok | wq! test.out | endif + :set exrc secure + :if has("gui_kde") + : set guifont=Courier\ 10\ Pitch/8/-1/5/50/0/0/0/0/0 +*** ../vim-7.3.686/src/version.c 2012-10-11 04:04:32.000000000 +0200 +--- src/version.c 2012-10-11 04:31:10.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 687, + /**/ + +-- +A fool must search for a greater fool to find admiration. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9994857b77af9c454c2cd8121ec1e4ac649c132a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:09 +0100 Subject: [PATCH 0559/3340] - patchlevel 688 --- 7.3.688 | 150 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 150 insertions(+) create mode 100644 7.3.688 diff --git a/7.3.688 b/7.3.688 new file mode 100644 index 00000000..56f00249 --- /dev/null +++ b/7.3.688 @@ -0,0 +1,150 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.688 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.688 +Problem: Python 3.3 is not supported. +Solution: Add Python 3.3 support (Ken Takata) +Files: src/if_python3.c + + +*** ../vim-7.3.687/src/if_python3.c 2012-09-21 14:00:05.000000000 +0200 +--- src/if_python3.c 2012-10-14 03:19:53.000000000 +0200 +*************** +*** 174,180 **** + # define _PyObject_NextNotImplemented (*py3__PyObject_NextNotImplemented) + # define PyModule_AddObject py3_PyModule_AddObject + # define PyImport_AppendInittab py3_PyImport_AppendInittab +! # define _PyUnicode_AsString py3__PyUnicode_AsString + # undef PyUnicode_AsEncodedString + # define PyUnicode_AsEncodedString py3_PyUnicode_AsEncodedString + # undef PyBytes_AsString +--- 174,185 ---- + # define _PyObject_NextNotImplemented (*py3__PyObject_NextNotImplemented) + # define PyModule_AddObject py3_PyModule_AddObject + # define PyImport_AppendInittab py3_PyImport_AppendInittab +! # if PY_VERSION_HEX >= 0x030300f0 +! # undef _PyUnicode_AsString +! # define _PyUnicode_AsString py3_PyUnicode_AsUTF8String +! # else +! # define _PyUnicode_AsString py3__PyUnicode_AsString +! # endif + # undef PyUnicode_AsEncodedString + # define PyUnicode_AsEncodedString py3_PyUnicode_AsEncodedString + # undef PyBytes_AsString +*************** +*** 281,287 **** +--- 286,296 ---- + static PyObject* py3__Py_TrueStruct; + static int (*py3_PyModule_AddObject)(PyObject *m, const char *name, PyObject *o); + static int (*py3_PyImport_AppendInittab)(const char *name, PyObject* (*initfunc)(void)); ++ #if PY_VERSION_HEX >= 0x030300f0 ++ static char* (*py3_PyUnicode_AsUTF8String)(PyObject *unicode); ++ #else + static char* (*py3__PyUnicode_AsString)(PyObject *unicode); ++ #endif + static PyObject* (*py3_PyUnicode_AsEncodedString)(PyObject *unicode, const char* encoding, const char* errors); + static char* (*py3_PyBytes_AsString)(PyObject *bytes); + static int (*py3_PyBytes_AsStringAndSize)(PyObject *bytes, char **buffer, int *length); +*************** +*** 397,403 **** +--- 406,416 ---- + {"PyObject_Init", (PYTHON_PROC*)&py3__PyObject_Init}, + {"PyModule_AddObject", (PYTHON_PROC*)&py3_PyModule_AddObject}, + {"PyImport_AppendInittab", (PYTHON_PROC*)&py3_PyImport_AppendInittab}, ++ #if PY_VERSION_HEX >= 0x030300f0 ++ {"PyUnicode_AsUTF8String", (PYTHON_PROC*)&py3_PyUnicode_AsUTF8String}, ++ #else + {"_PyUnicode_AsString", (PYTHON_PROC*)&py3__PyUnicode_AsString}, ++ #endif + {"PyBytes_AsString", (PYTHON_PROC*)&py3_PyBytes_AsString}, + {"PyBytes_AsStringAndSize", (PYTHON_PROC*)&py3_PyBytes_AsStringAndSize}, + {"PyBytes_FromString", (PYTHON_PROC*)&py3_PyBytes_FromString}, +*************** +*** 490,495 **** +--- 503,514 ---- + + /* Load unicode functions separately as only the ucs2 or the ucs4 functions + * will be present in the library. */ ++ #if PY_VERSION_HEX >= 0x030300f0 ++ ucs_from_string = symbol_from_dll(hinstPy3, "PyUnicode_FromString"); ++ ucs_decode = symbol_from_dll(hinstPy3, "PyUnicode_Decode"); ++ ucs_as_encoded_string = symbol_from_dll(hinstPy3, ++ "PyUnicode_AsEncodedString"); ++ #else + ucs_from_string = symbol_from_dll(hinstPy3, "PyUnicodeUCS2_FromString"); + ucs_decode = symbol_from_dll(hinstPy3, + "PyUnicodeUCS2_Decode"); +*************** +*** 504,509 **** +--- 523,529 ---- + ucs_as_encoded_string = symbol_from_dll(hinstPy3, + "PyUnicodeUCS4_AsEncodedString"); + } ++ #endif + if (ucs_from_string && ucs_decode && ucs_as_encoded_string) + { + py3_PyUnicode_FromString = ucs_from_string; +*************** +*** 600,607 **** + + #define GET_ATTR_STRING(name, nameobj) \ + char *name = ""; \ +! if(PyUnicode_Check(nameobj)) \ +! name = _PyUnicode_AsString(nameobj) + + #define PY3OBJ_DELETED(obj) (obj->ob_base.ob_refcnt<=0) + +--- 620,627 ---- + + #define GET_ATTR_STRING(name, nameobj) \ + char *name = ""; \ +! if (PyUnicode_Check(nameobj)) \ +! name = _PyUnicode_AsString(nameobj) + + #define PY3OBJ_DELETED(obj) (obj->ob_base.ob_refcnt<=0) + +*************** +*** 704,709 **** +--- 724,731 ---- + Py_SetPythonHome(PYTHON3_HOME); + #endif + ++ PyImport_AppendInittab("vim", Py3Init_vim); ++ + #if !defined(MACOS) || defined(MACOS_X_UNIX) + Py_Initialize(); + #else +*************** +*** 719,726 **** + if (PythonIO_Init()) + goto fail; + +- PyImport_AppendInittab("vim", Py3Init_vim); +- + globals = PyModule_GetDict(PyImport_AddModule("__main__")); + + /* Remove the element from sys.path that was added because of our +--- 741,746 ---- +*** ../vim-7.3.687/src/version.c 2012-10-11 04:44:26.000000000 +0200 +--- src/version.c 2012-10-14 03:00:57.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 688, + /**/ + +-- +The problem with political jokes is that they get elected. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d2a9d3847a0cd623a8a0d37cf2f01cd2e182bc10 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:10 +0100 Subject: [PATCH 0560/3340] - patchlevel 689 --- 7.3.689 | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 7.3.689 diff --git a/7.3.689 b/7.3.689 new file mode 100644 index 00000000..ae8e60d0 --- /dev/null +++ b/7.3.689 @@ -0,0 +1,72 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.689 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.689 +Problem: MzScheme and Lua may use a NULL string. +Solution: Use an empty string instead of NULL. (Yukihiro Nakadaira) +Files: src/if_lua.c, src/if_mzsch.c + + +*** ../vim-7.3.688/src/if_lua.c 2012-06-29 12:54:32.000000000 +0200 +--- src/if_lua.c 2012-10-14 03:33:32.000000000 +0200 +*************** +*** 464,470 **** + switch (tv->v_type) + { + case VAR_STRING: +! lua_pushstring(L, (char *) tv->vval.v_string); + break; + case VAR_NUMBER: + lua_pushinteger(L, (int) tv->vval.v_number); +--- 464,471 ---- + switch (tv->v_type) + { + case VAR_STRING: +! lua_pushstring(L, tv->vval.v_string == NULL +! ? "" : (char *)tv->vval.v_string); + break; + case VAR_NUMBER: + lua_pushinteger(L, (int) tv->vval.v_number); +*** ../vim-7.3.688/src/if_mzsch.c 2012-02-12 01:55:50.000000000 +0100 +--- src/if_mzsch.c 2012-10-14 03:33:32.000000000 +0200 +*************** +*** 2649,2655 **** + new_value = FALSE; + else if (vim_value->v_type == VAR_STRING) + { +! result = scheme_make_string((char *)vim_value->vval.v_string); + MZ_GC_CHECK(); + } + else if (vim_value->v_type == VAR_NUMBER) +--- 2649,2656 ---- + new_value = FALSE; + else if (vim_value->v_type == VAR_STRING) + { +! result = scheme_make_string(vim_value->vval.v_string == NULL +! ? "" : (char *)vim_value->vval.v_string); + MZ_GC_CHECK(); + } + else if (vim_value->v_type == VAR_NUMBER) +*** ../vim-7.3.688/src/version.c 2012-10-14 03:22:49.000000000 +0200 +--- src/version.c 2012-10-14 03:33:49.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 689, + /**/ + +-- +Computers make very fast, very accurate, mistakes. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 10632fe285c1ac1a2c1385f60bf79dabe8a40e1f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:10 +0100 Subject: [PATCH 0561/3340] - patchlevel 690 --- 7.3.690 | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 7.3.690 diff --git a/7.3.690 b/7.3.690 new file mode 100644 index 00000000..c638e26f --- /dev/null +++ b/7.3.690 @@ -0,0 +1,68 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.690 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.690 +Problem: When the current directory name is exactly the maximum path length + Vim may crash. +Solution: Only add "/" when there is room. (Danek Duvall) +Files: src/os_unix.c + + +*** ../vim-7.3.689/src/os_unix.c 2012-08-15 17:26:53.000000000 +0200 +--- src/os_unix.c 2012-10-14 04:28:40.000000000 +0200 +*************** +*** 2512,2526 **** + } + + l = STRLEN(buf); +! if (l >= len) +! retval = FAIL; + #ifndef VMS +! else +! { +! if (l > 0 && buf[l - 1] != '/' && *fname != NUL + && STRCMP(fname, ".") != 0) +! STRCAT(buf, "/"); +! } + #endif + } + +--- 2512,2523 ---- + } + + l = STRLEN(buf); +! if (l >= len - 1) +! retval = FAIL; /* no space for trailing "/" */ + #ifndef VMS +! else if (l > 0 && buf[l - 1] != '/' && *fname != NUL + && STRCMP(fname, ".") != 0) +! STRCAT(buf, "/"); + #endif + } + +*** ../vim-7.3.689/src/version.c 2012-10-14 03:41:54.000000000 +0200 +--- src/version.c 2012-10-14 04:26:17.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 690, + /**/ + +-- +SOLDIER: What? Ridden on a horse? +ARTHUR: Yes! +SOLDIER: You're using coconuts! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d7a5bb4908e30ba56b0dfa2fb48b5330c699f57e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:11 +0100 Subject: [PATCH 0562/3340] - patchlevel 691 --- 7.3.691 | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 7.3.691 diff --git a/7.3.691 b/7.3.691 new file mode 100644 index 00000000..6f44b5cf --- /dev/null +++ b/7.3.691 @@ -0,0 +1,61 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.691 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.691 +Problem: State specific to the Python thread is discarded. +Solution: Keep state between threads. (Paul) +Files: src/if_python.c + + +*** ../vim-7.3.690/src/if_python.c 2012-09-21 14:00:05.000000000 +0200 +--- src/if_python.c 2012-10-14 05:19:44.000000000 +0200 +*************** +*** 740,748 **** + #else + PyMac_Initialize(); + #endif +! /* initialise threads */ + PyEval_InitThreads(); +! + #ifdef DYNAMIC_PYTHON + get_exceptions(); + #endif +--- 740,750 ---- + #else + PyMac_Initialize(); + #endif +! /* Initialise threads and save the state using PyGILState_Ensure. +! * Without this call, thread-specific state (such as the system trace +! * hook), will be lost between invocations of Python code. */ + PyEval_InitThreads(); +! pygilstate = PyGILState_Ensure(); + #ifdef DYNAMIC_PYTHON + get_exceptions(); + #endif +*** ../vim-7.3.690/src/version.c 2012-10-14 04:35:16.000000000 +0200 +--- src/version.c 2012-10-14 05:14:35.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 691, + /**/ + +-- +ARTHUR: The swallow may fly south with the sun, or the house martin or the + plover seek warmer hot lands in winter, yet these are not strangers to + our land. +SOLDIER: Are you suggesting coconuts migrate? + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0445d52e42defb8418850ee39b925e9c7228336f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:12 +0100 Subject: [PATCH 0563/3340] - patchlevel 692 --- 7.3.692 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.692 diff --git a/7.3.692 b/7.3.692 new file mode 100644 index 00000000..67016efc --- /dev/null +++ b/7.3.692 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.692 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.692 +Problem: Can't build GTK version with GTK 2.0. +Solution: Put GtkFileFilter declaration in the right place. (Yegappan + Lakshmanan) +Files: src/gui_gtk.c + + +*** ../vim-7.3.691/src/gui_gtk.c 2012-07-10 13:41:09.000000000 +0200 +--- src/gui_gtk.c 2012-10-18 05:12:34.000000000 +0200 +*************** +*** 845,851 **** + char_u dirbuf[MAXPATHL]; + guint log_handler; + const gchar *domain = "Gtk"; +- GtkFileFilter *gfilter; + + title = CONVERT_TO_UTF8(title); + +--- 845,850 ---- +*************** +*** 883,888 **** +--- 882,888 ---- + int i = 0; + char_u *patt; + char_u *p = filter; ++ GtkFileFilter *gfilter; + + gfilter = gtk_file_filter_new(); + patt = alloc(STRLEN(filter)); +*** ../vim-7.3.691/src/version.c 2012-10-14 05:20:05.000000000 +0200 +--- src/version.c 2012-10-18 05:13:55.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 692, + /**/ + +-- +"The future's already arrived - it's just not evenly distributed yet." + -- William Gibson + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1a1f48f28a1ecfe2a2dd20fa7847a038fe852418 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:12 +0100 Subject: [PATCH 0564/3340] - patchlevel 693 --- 7.3.693 | 165 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 165 insertions(+) create mode 100644 7.3.693 diff --git a/7.3.693 b/7.3.693 new file mode 100644 index 00000000..c3b6b808 --- /dev/null +++ b/7.3.693 @@ -0,0 +1,165 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.693 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.693 +Problem: Can't make 'softtabstop' follow 'shiftwidth'. +Solution: When 'softtabstop' is negative use the value of 'shiftwidth'. + (so8res) +Files: src/edit.c, src/option.c, src/proto/option.pro + + +*** ../vim-7.3.692/src/edit.c 2012-10-04 22:38:32.000000000 +0200 +--- src/edit.c 2012-10-21 00:01:53.000000000 +0200 +*************** +*** 8885,8891 **** + */ + if ( mode == BACKSPACE_CHAR + && ((p_sta && in_indent) +! || (curbuf->b_p_sts != 0 + && curwin->w_cursor.col > 0 + && (*(ml_get_cursor() - 1) == TAB + || (*(ml_get_cursor() - 1) == ' ' +--- 8885,8891 ---- + */ + if ( mode == BACKSPACE_CHAR + && ((p_sta && in_indent) +! || (get_sts_value() != 0 + && curwin->w_cursor.col > 0 + && (*(ml_get_cursor() - 1) == TAB + || (*(ml_get_cursor() - 1) == ' ' +*************** +*** 8901,8907 **** + if (p_sta && in_indent) + ts = (int)get_sw_value(); + else +! ts = (int)curbuf->b_p_sts; + /* Compute the virtual column where we want to be. Since + * 'showbreak' may get in the way, need to get the last column of + * the previous character. */ +--- 8901,8907 ---- + if (p_sta && in_indent) + ts = (int)get_sw_value(); + else +! ts = (int)get_sts_value(); + /* Compute the virtual column where we want to be. Since + * 'showbreak' may get in the way, need to get the last column of + * the previous character. */ +*************** +*** 9590,9596 **** + */ + if (!curbuf->b_p_et + && !(p_sta && ind && curbuf->b_p_ts != get_sw_value()) +! && curbuf->b_p_sts == 0) + return TRUE; + + if (stop_arrow() == FAIL) +--- 9590,9596 ---- + */ + if (!curbuf->b_p_et + && !(p_sta && ind && curbuf->b_p_ts != get_sw_value()) +! && get_sts_value() == 0) + return TRUE; + + if (stop_arrow() == FAIL) +*************** +*** 9606,9613 **** + + if (p_sta && ind) /* insert tab in indent, use 'shiftwidth' */ + temp = (int)get_sw_value(); +! else if (curbuf->b_p_sts > 0) /* use 'softtabstop' when set */ +! temp = (int)curbuf->b_p_sts; + else /* otherwise use 'tabstop' */ + temp = (int)curbuf->b_p_ts; + temp -= get_nolist_virtcol() % temp; +--- 9606,9613 ---- + + if (p_sta && ind) /* insert tab in indent, use 'shiftwidth' */ + temp = (int)get_sw_value(); +! else if (curbuf->b_p_sts != 0) /* use 'softtabstop' when set */ +! temp = (int)get_sts_value(); + else /* otherwise use 'tabstop' */ + temp = (int)curbuf->b_p_ts; + temp -= get_nolist_virtcol() % temp; +*************** +*** 9635,9641 **** + /* + * When 'expandtab' not set: Replace spaces by TABs where possible. + */ +! if (!curbuf->b_p_et && (curbuf->b_p_sts || (p_sta && ind))) + { + char_u *ptr; + #ifdef FEAT_VREPLACE +--- 9635,9641 ---- + /* + * When 'expandtab' not set: Replace spaces by TABs where possible. + */ +! if (!curbuf->b_p_et && (get_sts_value() || (p_sta && ind))) + { + char_u *ptr; + #ifdef FEAT_VREPLACE +*** ../vim-7.3.692/src/option.c 2012-08-08 18:01:00.000000000 +0200 +--- src/option.c 2012-10-21 00:05:06.000000000 +0200 +*************** +*** 8509,8519 **** + p_window = Rows - 1; + } + +- if (curbuf->b_p_sts < 0) +- { +- errmsg = e_positive; +- curbuf->b_p_sts = 0; +- } + if (curbuf->b_p_ts <= 0) + { + errmsg = e_positive; +--- 8509,8514 ---- +*************** +*** 11429,11431 **** +--- 11424,11436 ---- + { + return curbuf->b_p_sw ? curbuf->b_p_sw : curbuf->b_p_ts; + } ++ ++ /* ++ * Return the effective softtabstop value for the current buffer, using the ++ * 'tabstop' value when 'softtabstop' is negative. ++ */ ++ long ++ get_sts_value() ++ { ++ return curbuf->b_p_sts < 0 ? get_sw_value() : curbuf->b_p_sts; ++ } +*** ../vim-7.3.692/src/proto/option.pro 2012-08-08 18:01:00.000000000 +0200 +--- src/proto/option.pro 2012-10-21 00:01:59.000000000 +0200 +*************** +*** 57,60 **** +--- 57,61 ---- + int file_ff_differs __ARGS((buf_T *buf, int ignore_empty)); + int check_ff_value __ARGS((char_u *p)); + long get_sw_value __ARGS((void)); ++ long get_sts_value __ARGS((void)); + /* vim: set ft=c : */ +*** ../vim-7.3.692/src/version.c 2012-10-18 05:18:27.000000000 +0200 +--- src/version.c 2012-10-21 00:07:19.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 693, + /**/ + +-- +FIRST VILLAGER: We have found a witch. May we burn her? + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8277de545859cc235e1dfe0d70c883c44f6eb4c5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:13 +0100 Subject: [PATCH 0565/3340] - patchlevel 694 --- 7.3.694 | 139 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 139 insertions(+) create mode 100644 7.3.694 diff --git a/7.3.694 b/7.3.694 new file mode 100644 index 00000000..89b4bcf7 --- /dev/null +++ b/7.3.694 @@ -0,0 +1,139 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.694 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.694 +Problem: Now that 'shiftwidth' may use the value of 'tabstop' it is not so + easy to use in indent files. +Solution: Add the shiftwidth() function. (so8res) +Files: runtime/doc/eval.txt, src/eval.c + + +*** ../vim-7.3.693/runtime/doc/eval.txt 2012-06-29 12:54:32.000000000 +0200 +--- runtime/doc/eval.txt 2012-10-21 00:43:22.000000000 +0200 +*************** +*** 1921,1926 **** +--- 1932,1938 ---- + shellescape( {string} [, {special}]) + String escape {string} for use as shell + command argument ++ shiftwidth() Number effective value of 'shiftwidth' + simplify( {filename}) String simplify filename as much as possible + sin( {expr}) Float sine of {expr} + sinh( {expr}) Float hyperbolic sine of {expr} +*************** +*** 3732,3741 **** + Like |input()|, but when the GUI is running and text dialogs + are supported, a dialog window pops up to input the text. + Example: > +! :let n = inputdialog("value for shiftwidth", &sw) +! :if n != "" +! : let &sw = n +! :endif + < When the dialog is cancelled {cancelreturn} is returned. When + omitted an empty string is returned. + Hitting works like pressing the OK button. Hitting +--- 3755,3764 ---- + Like |input()|, but when the GUI is running and text dialogs + are supported, a dialog window pops up to input the text. + Example: > +! :let n = inputdialog("value for shiftwidth", shiftwidth()) +! :if n != "" +! : let &sw = n +! :endif + < When the dialog is cancelled {cancelreturn} is returned. When + omitted an empty string is returned. + Hitting works like pressing the OK button. Hitting +*************** +*** 5308,5313 **** +--- 5332,5354 ---- + :call system("chmod +w -- " . shellescape(expand("%"))) + + ++ shiftwidth() *shiftwidth()* ++ Returns the effective value of 'shiftwidth'. This is the ++ 'shiftwidth' value unless it is zero, in which case it is the ++ 'tabstop' value. To be backwards compatible in indent ++ plugins, use this: > ++ if exists('*shiftwidth') ++ func s:sw() ++ return shiftwidth() ++ endfunc ++ else ++ func s:sw() ++ return &sw ++ endfunc ++ endif ++ < And then use s:sw() instead of &sw. ++ ++ + simplify({filename}) *simplify()* + Simplify the file name as much as possible without changing + the meaning. Shortcuts (on MS-Windows) or symbolic links (on +*** ../vim-7.3.693/src/eval.c 2012-08-08 14:33:16.000000000 +0200 +--- src/eval.c 2012-10-21 00:29:15.000000000 +0200 +*************** +*** 687,692 **** +--- 687,693 ---- + static void f_settabwinvar __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_setwinvar __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_shellescape __ARGS((typval_T *argvars, typval_T *rettv)); ++ static void f_shiftwidth __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_simplify __ARGS((typval_T *argvars, typval_T *rettv)); + #ifdef FEAT_FLOAT + static void f_sin __ARGS((typval_T *argvars, typval_T *rettv)); +*************** +*** 8051,8056 **** +--- 8052,8058 ---- + {"settabwinvar", 4, 4, f_settabwinvar}, + {"setwinvar", 3, 3, f_setwinvar}, + {"shellescape", 1, 2, f_shellescape}, ++ {"shiftwidth", 0, 0, f_shiftwidth}, + {"simplify", 1, 1, f_simplify}, + #ifdef FEAT_FLOAT + {"sin", 1, 1, f_sin}, +*************** +*** 16652,16657 **** +--- 16654,16670 ---- + } + + /* ++ * shiftwidth() function ++ */ ++ static void ++ f_shiftwidth(argvars, rettv) ++ typval_T *argvars; ++ typval_T *rettv; ++ { ++ rettv->vval.v_number = get_sw_value(); ++ } ++ ++ /* + * "simplify()" function + */ + static void +*** ../vim-7.3.693/src/version.c 2012-10-21 00:10:29.000000000 +0200 +--- src/version.c 2012-10-21 00:30:27.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 694, + /**/ + +-- +CRONE: Who sent you? +ARTHUR: The Knights Who Say GNU! +CRONE: Aaaagh! (she looks around in rear) No! We have no licenses here. + "Monty Python and the Holy editor wars" PYTHON (MONTY) SOFTWARE LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 230110ad552bca5312604c1faf5e65db9c80c60a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:13 +0100 Subject: [PATCH 0566/3340] - patchlevel 695 --- 7.3.695 | 129 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 129 insertions(+) create mode 100644 7.3.695 diff --git a/7.3.695 b/7.3.695 new file mode 100644 index 00000000..32010535 --- /dev/null +++ b/7.3.695 @@ -0,0 +1,129 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.695 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.695 +Problem: Balloon cannot show multi-byte text. +Solution: Properly deal with multi-byte characters. (Dominique Pelle) +Files: src/gui_beval.c, src/ui.c + + +*** ../vim-7.3.694/src/gui_beval.c 2010-08-15 21:57:28.000000000 +0200 +--- src/gui_beval.c 2012-10-21 00:54:19.000000000 +0200 +*************** +*** 359,365 **** + } + } + +! col = vcol2col(wp, lnum, col) - 1; + + if (VIsual_active + && wp->w_buffer == curwin->w_buffer +--- 359,365 ---- + } + } + +! col = vcol2col(wp, lnum, col); + + if (VIsual_active + && wp->w_buffer == curwin->w_buffer +*************** +*** 377,384 **** + return FAIL; + + lbuf = ml_get_buf(curwin->w_buffer, VIsual.lnum, FALSE); +! lbuf = vim_strnsave(lbuf + spos->col, +! epos->col - spos->col + (*p_sel != 'e')); + lnum = spos->lnum; + col = spos->col; + } +--- 377,386 ---- + return FAIL; + + lbuf = ml_get_buf(curwin->w_buffer, VIsual.lnum, FALSE); +! len = epos->col - spos->col; +! if (*p_sel != 'e') +! len += MB_PTR2LEN(lbuf + epos->col); +! lbuf = vim_strnsave(lbuf + spos->col, len); + lnum = spos->lnum; + col = spos->col; + } +*** ../vim-7.3.694/src/ui.c 2012-08-29 16:26:01.000000000 +0200 +--- src/ui.c 2012-10-21 00:50:17.000000000 +0200 +*************** +*** 98,104 **** + #endif + + /* +! * ui_inchar(): low level input funcion. + * Get characters from the keyboard. + * Return the number of characters that are available. + * If "wtime" == 0 do not wait for characters. +--- 98,104 ---- + #endif + + /* +! * ui_inchar(): low level input function. + * Get characters from the keyboard. + * Return the number of characters that are available. + * If "wtime" == 0 do not wait for characters. +*************** +*** 493,499 **** + } + } + #else +! /* Only own the clibpard when we didn't own it yet. */ + if (!cbd->owned && cbd->available) + cbd->owned = (clip_gen_own_selection(cbd) == OK); + #endif +--- 493,499 ---- + } + } + #else +! /* Only own the clipboard when we didn't own it yet. */ + if (!cbd->owned && cbd->available) + cbd->owned = (clip_gen_own_selection(cbd) == OK); + #endif +*************** +*** 3132,3138 **** + char_u *start; + + start = ptr = ml_get_buf(wp->w_buffer, lnum, FALSE); +! while (count <= vcol && *ptr != NUL) + { + count += win_lbr_chartabsize(wp, ptr, count, NULL); + mb_ptr_adv(ptr); +--- 3132,3138 ---- + char_u *start; + + start = ptr = ml_get_buf(wp->w_buffer, lnum, FALSE); +! while (count < vcol && *ptr != NUL) + { + count += win_lbr_chartabsize(wp, ptr, count, NULL); + mb_ptr_adv(ptr); +*** ../vim-7.3.694/src/version.c 2012-10-21 00:44:59.000000000 +0200 +--- src/version.c 2012-10-21 00:50:32.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 695, + /**/ + +-- +BEDEVERE: Why do you think she is a witch? +SECOND VILLAGER: She turned me into a newt. +BEDEVERE: A newt? +SECOND VILLAGER: (After looking at himself for some time) I got better. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4cabe65c092f8bdfcc84b7265e16ad7deecd7111 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:14 +0100 Subject: [PATCH 0567/3340] - patchlevel 696 --- 7.3.696 | 89 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) create mode 100644 7.3.696 diff --git a/7.3.696 b/7.3.696 new file mode 100644 index 00000000..9084022e --- /dev/null +++ b/7.3.696 @@ -0,0 +1,89 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.696 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.696 +Problem: Message about added spell language can be wrong. +Solution: Give correct message. Add g:menutrans_set_lang_to to allow for + translation. (Jiri Sedlak) +Files: runtime/menu.vim + + +*** ../vim-7.3.695/runtime/menu.vim 2010-08-15 21:57:11.000000000 +0200 +--- runtime/menu.vim 2012-10-21 01:17:27.000000000 +0200 +*************** +*** 434,439 **** +--- 434,443 ---- + let enc = &enc + endif + ++ if !exists("g:menutrans_set_lang_to") ++ let g:menutrans_set_lang_to = 'Set language to' ++ endif ++ + let found = 0 + let s = globpath(&rtp, "spell/*." . enc . ".spl") + if s != "" +*************** +*** 441,448 **** + for f in split(s, "\n") + let nm = substitute(f, '.*spell[/\\]\(..\)\.[^/\\]*\.spl', '\1', "") + if nm != "en" && nm !~ '/' + let found += 1 +! let menuname = '&Tools.&Spelling.Set\ language\ to\ "' . nm . '"' + exe 'an 40.335.' . n . ' ' . menuname . ' :set spl=' . nm . ' spell' + let s:undo_spellang += ['aun ' . menuname] + endif +--- 445,453 ---- + for f in split(s, "\n") + let nm = substitute(f, '.*spell[/\\]\(..\)\.[^/\\]*\.spl', '\1', "") + if nm != "en" && nm !~ '/' ++ let _nm = nm + let found += 1 +! let menuname = '&Tools.&Spelling.' . escape(g:menutrans_set_lang_to, "\\. \t|") . '\ "' . nm . '"' + exe 'an 40.335.' . n . ' ' . menuname . ' :set spl=' . nm . ' spell' + let s:undo_spellang += ['aun ' . menuname] + endif +*************** +*** 452,458 **** + if found == 0 + echomsg "Could not find other spell files" + elseif found == 1 +! echomsg "Found spell file " . nm + else + echomsg "Found " . found . " more spell files" + endif +--- 457,463 ---- + if found == 0 + echomsg "Could not find other spell files" + elseif found == 1 +! echomsg "Found spell file " . _nm + else + echomsg "Found " . found . " more spell files" + endif +*** ../vim-7.3.695/src/version.c 2012-10-21 00:58:34.000000000 +0200 +--- src/version.c 2012-10-21 01:15:00.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 696, + /**/ + +-- +BEDEVERE: And what do you burn, apart from witches? +FOURTH VILLAGER: ... Wood? +BEDEVERE: So why do witches burn? +SECOND VILLAGER: (pianissimo) ... Because they're made of wood...? + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From cb6b9638e2127bb108feb7571b9f63bc6db9f381 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:15 +0100 Subject: [PATCH 0568/3340] - patchlevel 697 --- 7.3.697 | 188 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 188 insertions(+) create mode 100644 7.3.697 diff --git a/7.3.697 b/7.3.697 new file mode 100644 index 00000000..b8d7814a --- /dev/null +++ b/7.3.697 @@ -0,0 +1,188 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.697 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.697 +Problem: Leaking resources when setting GUI font. +Solution: Free the font. (Ken Takata) +Files: src/syntax.c + + +*** ../vim-7.3.696/src/syntax.c 2012-07-19 17:39:01.000000000 +0200 +--- src/syntax.c 2012-10-21 01:37:19.000000000 +0200 +*************** +*** 105,111 **** + # ifdef FEAT_XFONTSET + static GuiFontset fontset_name2handle __ARGS((char_u *name, int fixed_width)); + # endif +! static void hl_do_font __ARGS((int idx, char_u *arg, int do_normal, int do_menu, int do_tooltip)); + #endif + + /* +--- 105,111 ---- + # ifdef FEAT_XFONTSET + static GuiFontset fontset_name2handle __ARGS((char_u *name, int fixed_width)); + # endif +! static void hl_do_font __ARGS((int idx, char_u *arg, int do_normal, int do_menu, int do_tooltip, int free_font)); + #endif + + /* +*************** +*** 7259,7272 **** + HL_TABLE()[idx].sg_fontset = NOFONTSET; + # endif + hl_do_font(idx, arg, is_normal_group, is_menu_group, +! is_tooltip_group); + + # ifdef FEAT_XFONTSET + if (HL_TABLE()[idx].sg_fontset != NOFONTSET) + { +! /* New fontset was accepted. Free the old one, if there was +! * one. +! */ + gui_mch_free_fontset(temp_sg_fontset); + vim_free(HL_TABLE()[idx].sg_font_name); + HL_TABLE()[idx].sg_font_name = vim_strsave(arg); +--- 7259,7271 ---- + HL_TABLE()[idx].sg_fontset = NOFONTSET; + # endif + hl_do_font(idx, arg, is_normal_group, is_menu_group, +! is_tooltip_group, FALSE); + + # ifdef FEAT_XFONTSET + if (HL_TABLE()[idx].sg_fontset != NOFONTSET) + { +! /* New fontset was accepted. Free the old one, if there +! * was one. */ + gui_mch_free_fontset(temp_sg_fontset); + vim_free(HL_TABLE()[idx].sg_font_name); + HL_TABLE()[idx].sg_font_name = vim_strsave(arg); +*************** +*** 7277,7284 **** + if (HL_TABLE()[idx].sg_font != NOFONT) + { + /* New font was accepted. Free the old one, if there was +! * one. +! */ + gui_mch_free_font(temp_sg_font); + vim_free(HL_TABLE()[idx].sg_font_name); + HL_TABLE()[idx].sg_font_name = vim_strsave(arg); +--- 7276,7282 ---- + if (HL_TABLE()[idx].sg_font != NOFONT) + { + /* New font was accepted. Free the old one, if there was +! * one. */ + gui_mch_free_font(temp_sg_font); + vim_free(HL_TABLE()[idx].sg_font_name); + HL_TABLE()[idx].sg_font_name = vim_strsave(arg); +*************** +*** 8064,8075 **** + * Get the font or fontset for one highlight group. + */ + static void +! hl_do_font(idx, arg, do_normal, do_menu, do_tooltip) + int idx; + char_u *arg; + int do_normal; /* set normal font */ + int do_menu UNUSED; /* set menu font */ + int do_tooltip UNUSED; /* set tooltip font */ + { + # ifdef FEAT_XFONTSET + /* If 'guifontset' is not empty, first try using the name as a +--- 8062,8074 ---- + * Get the font or fontset for one highlight group. + */ + static void +! hl_do_font(idx, arg, do_normal, do_menu, do_tooltip, free_font) + int idx; + char_u *arg; + int do_normal; /* set normal font */ + int do_menu UNUSED; /* set menu font */ + int do_tooltip UNUSED; /* set tooltip font */ ++ int free_font; /* free current font/fontset */ + { + # ifdef FEAT_XFONTSET + /* If 'guifontset' is not empty, first try using the name as a +*************** +*** 8083,8088 **** +--- 8082,8089 ---- + || do_tooltip + # endif + ) ++ if (free_fontset) ++ gui_mch_free_fontset(HL_TABLE()[idx].sg_fontset); + HL_TABLE()[idx].sg_fontset = fontset_name2handle(arg, 0 + # ifdef FONTSET_ALWAYS + || do_menu +*************** +*** 8093,8100 **** + ); + if (HL_TABLE()[idx].sg_fontset != NOFONTSET) + { +! /* If it worked and it's the Normal group, use it as the +! * normal fontset. Same for the Menu group. */ + if (do_normal) + gui_init_font(arg, TRUE); + # if (defined(FEAT_GUI_MOTIF) || defined(FEAT_GUI_ATHENA)) && defined(FEAT_MENU) +--- 8094,8101 ---- + ); + if (HL_TABLE()[idx].sg_fontset != NOFONTSET) + { +! /* If it worked and it's the Normal group, use it as the normal +! * fontset. Same for the Menu group. */ + if (do_normal) + gui_init_font(arg, TRUE); + # if (defined(FEAT_GUI_MOTIF) || defined(FEAT_GUI_ATHENA)) && defined(FEAT_MENU) +*************** +*** 8126,8131 **** +--- 8127,8134 ---- + else + # endif + { ++ if (free_font) ++ gui_mch_free_font(HL_TABLE()[idx].sg_font); + HL_TABLE()[idx].sg_font = font_name2handle(arg); + /* If it worked and it's the Normal group, use it as the + * normal font. Same for the Menu group. */ +*************** +*** 9162,9168 **** + if (HL_TABLE()[idx].sg_font_name != NULL) + { + hl_do_font(idx, HL_TABLE()[idx].sg_font_name, FALSE, do_menu, +! do_tooltip); + didit = TRUE; + } + if (HL_TABLE()[idx].sg_gui_fg_name != NULL) +--- 9165,9171 ---- + if (HL_TABLE()[idx].sg_font_name != NULL) + { + hl_do_font(idx, HL_TABLE()[idx].sg_font_name, FALSE, do_menu, +! do_tooltip, TRUE); + didit = TRUE; + } + if (HL_TABLE()[idx].sg_gui_fg_name != NULL) +*** ../vim-7.3.696/src/version.c 2012-10-21 01:21:53.000000000 +0200 +--- src/version.c 2012-10-21 01:27:55.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 697, + /**/ + +-- +BEDEVERE: Wait. Wait ... tell me, what also floats on water? +ALL: Bread? No, no, no. Apples .... gravy ... very small rocks ... +ARTHUR: A duck. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7221f65f9f050dd1266ef1d8c2eb4bc45531f747 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:15 +0100 Subject: [PATCH 0569/3340] - patchlevel 698 --- 7.3.698 | 84 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 7.3.698 diff --git a/7.3.698 b/7.3.698 new file mode 100644 index 00000000..57b37d6c --- /dev/null +++ b/7.3.698 @@ -0,0 +1,84 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.698 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.698 +Problem: Python 3 does not preserve state beween commands. +Solution: Preserve the state. (Paul Ollis) +Files: src/if_python.c, src/if_python3.c + + +*** ../vim-7.3.697/src/if_python.c 2012-10-14 05:20:05.000000000 +0200 +--- src/if_python.c 2012-10-21 01:44:10.000000000 +0200 +*************** +*** 740,748 **** + #else + PyMac_Initialize(); + #endif +! /* Initialise threads and save the state using PyGILState_Ensure. +! * Without this call, thread-specific state (such as the system trace +! * hook), will be lost between invocations of Python code. */ + PyEval_InitThreads(); + pygilstate = PyGILState_Ensure(); + #ifdef DYNAMIC_PYTHON +--- 740,749 ---- + #else + PyMac_Initialize(); + #endif +! /* Initialise threads, and save the state using PyGILState_Ensure. +! * Without the call to PyGILState_Ensure, thread specific state (such +! * as the system trace hook), will be lost between invocations of +! * Python code. */ + PyEval_InitThreads(); + pygilstate = PyGILState_Ensure(); + #ifdef DYNAMIC_PYTHON +*** ../vim-7.3.697/src/if_python3.c 2012-10-14 03:22:49.000000000 +0200 +--- src/if_python3.c 2012-10-21 01:44:37.000000000 +0200 +*************** +*** 731,738 **** + #else + PyMac_Initialize(); + #endif +! /* initialise threads, must be after Py_Initialize() */ + PyEval_InitThreads(); + + #ifdef DYNAMIC_PYTHON3 + get_py3_exceptions(); +--- 731,742 ---- + #else + PyMac_Initialize(); + #endif +! /* Initialise threads, and save the state using PyGILState_Ensure. +! * Without the call to PyGILState_Ensure, thread specific state (such +! * as the system trace hook), will be lost between invocations of +! * Python code. */ + PyEval_InitThreads(); ++ pygilstate = PyGILState_Ensure(); + + #ifdef DYNAMIC_PYTHON3 + get_py3_exceptions(); +*** ../vim-7.3.697/src/version.c 2012-10-21 01:40:24.000000000 +0200 +--- src/version.c 2012-10-21 01:42:44.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 698, + /**/ + +-- +ALL: A witch! A witch! +WITCH: It's a fair cop. +ALL: Burn her! Burn her! Let's make her into a ladder. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f543e93c5c68d4ad5a1931cff6e8eb8ca2074d30 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:16 +0100 Subject: [PATCH 0570/3340] - patchlevel 699 --- 7.3.699 | 86 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 7.3.699 diff --git a/7.3.699 b/7.3.699 new file mode 100644 index 00000000..6efc8695 --- /dev/null +++ b/7.3.699 @@ -0,0 +1,86 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.699 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.699 +Problem: When 'ttymouse' is set to "sgr" manually, it is overruled by + automatic detection. +Solution: Do not use automatic detection when 'ttymouse' was set manually. + (Hayaki Saito) +Files: src/term.c + + +*** ../vim-7.3.698/src/term.c 2012-08-29 16:26:01.000000000 +0200 +--- src/term.c 2012-10-21 02:07:25.000000000 +0200 +*************** +*** 4079,4102 **** + + if (tp[1 + (tp[0] != CSI)] == '>' && j == 2) + { + # ifdef TTYM_SGR +! if (extra >= 277 +! # ifdef TTYM_URXVT +! && ttym_flags != TTYM_URXVT +! # endif +! ) +! set_option_value((char_u *)"ttym", 0L, + (char_u *)"sgr", 0); +! else + # endif +! /* if xterm version >= 95 use mouse dragging */ +! if (extra >= 95 +! # ifdef TTYM_URXVT +! && ttym_flags != TTYM_URXVT +! # endif +! ) +! set_option_value((char_u *)"ttym", 0L, + (char_u *)"xterm2", 0); + /* if xterm version >= 141 try to get termcap codes */ + if (extra >= 141) + { +--- 4079,4100 ---- + + if (tp[1 + (tp[0] != CSI)] == '>' && j == 2) + { ++ /* Only set 'ttymouse' automatically if it was not set ++ * by the user already. */ ++ if (!option_was_set((char_u *)"ttym")) ++ { + # ifdef TTYM_SGR +! if (extra >= 277) +! set_option_value((char_u *)"ttym", 0L, + (char_u *)"sgr", 0); +! else + # endif +! /* if xterm version >= 95 use mouse dragging */ +! if (extra >= 95) +! set_option_value((char_u *)"ttym", 0L, + (char_u *)"xterm2", 0); ++ } ++ + /* if xterm version >= 141 try to get termcap codes */ + if (extra >= 141) + { +*** ../vim-7.3.698/src/version.c 2012-10-21 01:46:56.000000000 +0200 +--- src/version.c 2012-10-21 02:09:17.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 699, + /**/ + +-- +Never under any circumstances take a sleeping pill +and a laxative on the same night. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 84943edde851d4d4807dc567e148cf3e8b7845a9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:17 +0100 Subject: [PATCH 0571/3340] - patchlevel 700 --- 7.3.700 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.700 diff --git a/7.3.700 b/7.3.700 new file mode 100644 index 00000000..a1b530eb --- /dev/null +++ b/7.3.700 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.700 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.700 +Problem: Cannot detect URXVT and SGR mouse support. +Solution: add +mouse_urxvt and +mouse_sgr. (Hayaki Saito) +Files: src/feature.h, src/eval.c + + +*** ../vim-7.3.699/src/feature.h 2012-08-15 16:20:59.000000000 +0200 +--- src/feature.h 2012-10-21 02:13:36.000000000 +0200 +*************** +*** 1038,1045 **** +--- 1038,1047 ---- + * +mouse_gpm Unix only: Include code for Linux console mouse + * handling. + * +mouse_pterm PTerm mouse support for QNX ++ * +mouse_sgr Unix only: Include code for for SGR-styled mouse. + * +mouse_sysmouse Unix only: Include code for FreeBSD and DragonFly + * console mouse handling. ++ * +mouse_urxvt Unix only: Include code for for urxvt mosue handling. + * +mouse Any mouse support (any of the above enabled). + */ + /* OS/2 and Amiga console have no mouse support */ +*** ../vim-7.3.699/src/eval.c 2012-10-21 00:44:59.000000000 +0200 +--- src/eval.c 2012-10-21 02:12:48.000000000 +0200 +*************** +*** 12276,12284 **** +--- 12276,12290 ---- + # ifdef FEAT_MOUSE_PTERM + "mouse_pterm", + # endif ++ # ifdef FEAT_MOUSE_SGR ++ "mouse_sgr", ++ # endif + # ifdef FEAT_SYSMOUSE + "mouse_sysmouse", + # endif ++ # ifdef FEAT_MOUSE_URXVT ++ "mouse_urxvt", ++ # endif + # ifdef FEAT_MOUSE_XTERM + "mouse_xterm", + # endif +*** ../vim-7.3.699/src/version.c 2012-10-21 02:10:20.000000000 +0200 +--- src/version.c 2012-10-21 02:15:32.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 700, + /**/ + +-- +If you had to identify, in one word, the reason why the +human race has not achieved, and never will achieve, its +full potential, that word would be "meetings." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bd2c9e61d9e665d6683bd8c0f698473d60f9714f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:18 +0100 Subject: [PATCH 0572/3340] - patchlevel 701 --- 7.3.701 | 83 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 7.3.701 diff --git a/7.3.701 b/7.3.701 new file mode 100644 index 00000000..1c17aab6 --- /dev/null +++ b/7.3.701 @@ -0,0 +1,83 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.701 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.701 +Problem: MS-Windows: Crash with stack overflow when setting 'encoding'. +Solution: Handle that loading the iconv library may be called recursively. + (Jiri Sedlak) +Files: src/os_win32.c + + +*** ../vim-7.3.700/src/os_win32.c 2012-08-02 12:31:40.000000000 +0200 +--- src/os_win32.c 2012-10-21 02:35:21.000000000 +0200 +*************** +*** 288,305 **** + vimLoadLib(char *name) + { + HINSTANCE dll = NULL; +! char old_dir[MAXPATHL]; + + if (exe_path == NULL) + get_exe_name(); +! if (exe_path != NULL && mch_dirname(old_dir, MAXPATHL) == OK) + { + /* Change directory to where the executable is, both to make sure we + * find a .dll there and to avoid looking for a .dll in the current + * directory. */ +! mch_chdir(exe_path); + dll = LoadLibrary(name); +- mch_chdir(old_dir); + } + return dll; + } +--- 288,313 ---- + vimLoadLib(char *name) + { + HINSTANCE dll = NULL; +! TCHAR old_dir[MAXPATHL]; + ++ /* NOTE: Do not use mch_dirname() and mch_chdir() here, they may call ++ * vimLoadLib() recursively, which causes a stack overflow. */ + if (exe_path == NULL) + get_exe_name(); +! if (exe_path != NULL && GetCurrentDirectory(MAXPATHL, old_dir) != 0) + { + /* Change directory to where the executable is, both to make sure we + * find a .dll there and to avoid looking for a .dll in the current + * directory. */ +! SetCurrentDirectory(exe_path); +! dll = LoadLibrary(name); +! SetCurrentDirectory(old_dir); +! } +! else +! { +! /* We are not able to change directory to where the executable is, try +! * to load library anyway. */ + dll = LoadLibrary(name); + } + return dll; + } +*** ../vim-7.3.700/src/version.c 2012-10-21 02:17:28.000000000 +0200 +--- src/version.c 2012-10-21 02:35:48.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 701, + /**/ + +-- +BEDEVERE: And that, my lord, is how we know the Earth to be banana-shaped. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ddebdfa97ab3d1b44b57345e69d45bdc83e2378e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:18 +0100 Subject: [PATCH 0573/3340] - patchlevel 702 --- 7.3.702 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.702 diff --git a/7.3.702 b/7.3.702 new file mode 100644 index 00000000..d36f96c7 --- /dev/null +++ b/7.3.702 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.702 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.702 +Problem: Nmake from VS6 service pack 6 is not recognized. +Solution: Detect the version number. (Jiri Sedlak) +Files: src/Make_mvc.mak + + +*** ../vim-7.3.701/src/Make_mvc.mak 2012-09-18 22:00:02.000000000 +0200 +--- src/Make_mvc.mak 2012-10-21 02:38:21.000000000 +0200 +*************** +*** 373,378 **** +--- 373,382 ---- + MSVCVER = 6.0 + CPU = ix86 + !endif ++ !if "$(_NMAKE_VER)" == "6.00.9782.0" ++ MSVCVER = 6.0 ++ CPU = ix86 ++ !endif + !if "$(_NMAKE_VER)" == "7.00.9466" + MSVCVER = 7.0 + !endif +*** ../vim-7.3.701/src/version.c 2012-10-21 02:37:02.000000000 +0200 +--- src/version.c 2012-10-21 02:40:00.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 702, + /**/ + +-- +Back off man, I'm a scientist. + -- Peter, Ghostbusters + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0514b9cb03abdab73356627b6b11ff86a2ae7ce3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:19 +0100 Subject: [PATCH 0574/3340] - patchlevel 703 --- 7.3.703 | 97 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100644 7.3.703 diff --git a/7.3.703 b/7.3.703 new file mode 100644 index 00000000..c9f0c8a9 --- /dev/null +++ b/7.3.703 @@ -0,0 +1,97 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.703 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.703 +Problem: When 'undofile' is reset the hash is computed unnecessarily. +Solution: Only compute the hash when the option was set. (Christian Brabandt) +Files: src/option.c + + +*** ../vim-7.3.702/src/option.c 2012-10-21 00:10:29.000000000 +0200 +--- src/option.c 2012-10-21 03:42:10.000000000 +0200 +*************** +*** 7573,7596 **** + /* 'undofile' */ + else if ((int *)varp == &curbuf->b_p_udf || (int *)varp == &p_udf) + { +! char_u hash[UNDO_HASH_SIZE]; +! buf_T *save_curbuf = curbuf; +! +! for (curbuf = firstbuf; curbuf != NULL; curbuf = curbuf->b_next) + { +! /* When 'undofile' is set globally: for every buffer, otherwise +! * only for the current buffer: Try to read in the undofile, if +! * one exists and the buffer wasn't changed and the buffer was +! * loaded. */ +! if ((curbuf == save_curbuf +! || (opt_flags & OPT_GLOBAL) || opt_flags == 0) +! && !curbufIsChanged() && curbuf->b_ml.ml_mfp != NULL) + { +! u_compute_hash(hash); +! u_read_undo(NULL, hash, curbuf->b_fname); + } + } +- curbuf = save_curbuf; + } + #endif + +--- 7573,7602 ---- + /* 'undofile' */ + else if ((int *)varp == &curbuf->b_p_udf || (int *)varp == &p_udf) + { +! /* Only take action when the option was set. When reset we do not +! * delete the undo file, the option may be set again without making +! * any changes in between. */ +! if (curbuf->b_p_udf || p_udf) + { +! char_u hash[UNDO_HASH_SIZE]; +! buf_T *save_curbuf = curbuf; +! +! for (curbuf = firstbuf; curbuf != NULL; curbuf = curbuf->b_next) + { +! /* When 'undofile' is set globally: for every buffer, otherwise +! * only for the current buffer: Try to read in the undofile, +! * if one exists, the buffer wasn't changed and the buffer was +! * loaded */ +! if ((curbuf == save_curbuf +! || (opt_flags & OPT_GLOBAL) || opt_flags == 0) +! && !curbufIsChanged() && curbuf->b_ml.ml_mfp != NULL) +! { +! u_compute_hash(hash); +! u_read_undo(NULL, hash, curbuf->b_fname); +! } + } ++ curbuf = save_curbuf; + } + } + #endif + +*** ../vim-7.3.702/src/version.c 2012-10-21 02:41:04.000000000 +0200 +--- src/version.c 2012-10-21 03:43:29.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 703, + /**/ + +-- +Scientists decoded the first message from an alien civilization: + SIMPLY SEND 6 TIMES 10 TO THE 50 ATOMS OF HYDROGEN TO THE STAR +SYSTEM AT THE TOP OF THE LIST, CROSS OFF THAT STAR SYSTEM, THEN PUT +YOUR STAR SYSTEM AT THE BOTTOM OF THE LIST AND SEND IT TO 100 OTHER +STAR SYSTEMS. WITHIN ONE TENTH GALACTIC ROTATION YOU WILL RECEIVE +ENOUGH HYDROGREN TO POWER YOUR CIVILIZATION UNTIL ENTROPY REACHES ITS +MAXIMUM! IT REALLY WORKS! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 27e8012277f786a1258876bbe0931bd6cc3f5d60 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:19 +0100 Subject: [PATCH 0575/3340] - patchlevel 704 --- 7.3.704 | 90 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) create mode 100644 7.3.704 diff --git a/7.3.704 b/7.3.704 new file mode 100644 index 00000000..3b262bc4 --- /dev/null +++ b/7.3.704 @@ -0,0 +1,90 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.704 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.704 +Problem: Repeating "cgn" does not always work correctly. +Solution: Also fetch the operator character. (Christian Brabandt) +Files: src/normal.c + + +*** ../vim-7.3.703/src/normal.c 2012-08-15 13:30:55.000000000 +0200 +--- src/normal.c 2012-10-21 03:51:38.000000000 +0200 +*************** +*** 960,967 **** + #ifdef FEAT_CMDL_INFO + need_flushbuf |= add_to_showcmd(ca.nchar); + #endif + if (ca.nchar == 'r' || ca.nchar == '\'' || ca.nchar == '`' +! || ca.nchar == Ctrl_BSL) + { + cp = &ca.extra_char; /* need to get a third character */ + if (ca.nchar != 'r') +--- 960,970 ---- + #ifdef FEAT_CMDL_INFO + need_flushbuf |= add_to_showcmd(ca.nchar); + #endif ++ /* For "gn" from redo, need to get one more char to determine the ++ * operator */ + if (ca.nchar == 'r' || ca.nchar == '\'' || ca.nchar == '`' +! || ca.nchar == Ctrl_BSL +! || ((ca.nchar == 'n' || ca.nchar == 'N') && !stuff_empty())) + { + cp = &ca.extra_char; /* need to get a third character */ + if (ca.nchar != 'r') +*************** +*** 1083,1088 **** +--- 1086,1093 ---- + ca.nchar = ca.extra_char; + idx = find_command(ca.cmdchar); + } ++ else if (ca.nchar == 'n' || ca.nchar == 'N') ++ ca.oap->op_type = get_op_type(*cp, NUL); + else if (*cp == Ctrl_BSL) + { + long towait = (p_ttm >= 0 ? p_ttm : p_tm); +*************** +*** 8009,8015 **** + #ifdef FEAT_VISUAL + if (!current_search(cap->count1, cap->nchar == 'n')) + #endif +! beep_flush(); + break; + + /* +--- 8014,8020 ---- + #ifdef FEAT_VISUAL + if (!current_search(cap->count1, cap->nchar == 'n')) + #endif +! clearopbeep(oap); + break; + + /* +*** ../vim-7.3.703/src/version.c 2012-10-21 03:45:57.000000000 +0200 +--- src/version.c 2012-10-21 03:53:51.000000000 +0200 +*************** +*** 721,722 **** +--- 721,724 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 704, + /**/ + +-- +The word "leader" is derived from the word "lead", as in the material that +bullets are made out of. The term "leader" was popularized at about the same +time as the invention of firearms. It grew out of the observation that the +person in charge of every organization was the person whom everyone wanted to +fill with hot lead. + I don't recomment this; it's just a point of historical interest. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 236ab8e89c65489f3edd6aa37e501c792ec2ccaf Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:20 +0100 Subject: [PATCH 0576/3340] - patchlevel 705 --- 7.3.705 | 122 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 122 insertions(+) create mode 100644 7.3.705 diff --git a/7.3.705 b/7.3.705 new file mode 100644 index 00000000..6a642e58 --- /dev/null +++ b/7.3.705 @@ -0,0 +1,122 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.705 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.705 +Problem: Mouse features are not sorted properly. (Tony Mechelynck) +Solution: Put the mouse features in alphabetical order. +Files: src/version.c + + +*** ../vim-7.3.704/src/version.c 2012-10-21 03:54:27.000000000 +0200 +--- src/version.c 2012-10-21 03:59:04.000000000 +0200 +*************** +*** 348,353 **** +--- 348,354 ---- + # else + "-mouse", + #endif ++ + #if defined(UNIX) || defined(VMS) + # ifdef FEAT_MOUSE_DEC + "+mouse_dec", +*************** +*** 369,402 **** + # else + "-mouse_netterm", + # endif + # ifdef FEAT_SYSMOUSE + "+mouse_sysmouse", + # else + "-mouse_sysmouse", + # endif +- # ifdef FEAT_MOUSE_XTERM +- "+mouse_xterm", +- # else +- "-mouse_xterm", +- # endif + # ifdef FEAT_MOUSE_URXVT + "+mouse_urxvt", + # else + "-mouse_urxvt", + # endif +! # ifdef FEAT_MOUSE_SGR +! "+mouse_sgr", +! # else +! "-mouse_sgr", +! # endif +! #endif +! #ifdef __QNX__ +! # ifdef FEAT_MOUSE_PTERM +! "+mouse_pterm", + # else +! "-mouse_pterm", + # endif + #endif + #ifdef FEAT_MBYTE_IME + # ifdef DYNAMIC_IME + "+multi_byte_ime/dyn", +--- 370,408 ---- + # else + "-mouse_netterm", + # endif ++ #endif ++ ++ #ifdef __QNX__ ++ # ifdef FEAT_MOUSE_PTERM ++ "+mouse_pterm", ++ # else ++ "-mouse_pterm", ++ # endif ++ #endif ++ ++ #if defined(UNIX) || defined(VMS) ++ # ifdef FEAT_MOUSE_SGR ++ "+mouse_sgr", ++ # else ++ "-mouse_sgr", ++ # endif + # ifdef FEAT_SYSMOUSE + "+mouse_sysmouse", + # else + "-mouse_sysmouse", + # endif + # ifdef FEAT_MOUSE_URXVT + "+mouse_urxvt", + # else + "-mouse_urxvt", + # endif +! # ifdef FEAT_MOUSE_XTERM +! "+mouse_xterm", + # else +! "-mouse_xterm", + # endif + #endif ++ + #ifdef FEAT_MBYTE_IME + # ifdef DYNAMIC_IME + "+multi_byte_ime/dyn", +*** ../vim-7.3.704/src/version.c 2012-10-21 03:54:27.000000000 +0200 +--- src/version.c 2012-10-21 03:59:04.000000000 +0200 +*************** +*** 721,722 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 705, + /**/ + +-- +Are leaders born or made? And if they're made, can we return them under +warranty? + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 34c276b318601c9ac3c97d59d305756d937229ef Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:21 +0100 Subject: [PATCH 0577/3340] - patchlevel 706 --- 7.3.706 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.706 diff --git a/7.3.706 b/7.3.706 new file mode 100644 index 00000000..acf74262 --- /dev/null +++ b/7.3.706 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.706 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.706 (after 7.3.697) +Problem: Can't build Motif version. +Solution: Fix wrongly named variable. (Ike Devolder) +Files: src/syntax.c + + +*** ../vim-7.3.705/src/syntax.c 2012-10-21 01:40:24.000000000 +0200 +--- src/syntax.c 2012-10-21 21:22:46.000000000 +0200 +*************** +*** 8082,8088 **** + || do_tooltip + # endif + ) +! if (free_fontset) + gui_mch_free_fontset(HL_TABLE()[idx].sg_fontset); + HL_TABLE()[idx].sg_fontset = fontset_name2handle(arg, 0 + # ifdef FONTSET_ALWAYS +--- 8082,8088 ---- + || do_tooltip + # endif + ) +! if (free_font) + gui_mch_free_fontset(HL_TABLE()[idx].sg_fontset); + HL_TABLE()[idx].sg_fontset = fontset_name2handle(arg, 0 + # ifdef FONTSET_ALWAYS +*** ../vim-7.3.705/src/version.c 2012-10-21 04:00:03.000000000 +0200 +--- src/version.c 2012-10-21 21:25:07.000000000 +0200 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 706, + /**/ + +-- +"You're fired." (1980) +"You're laid off." (1985) +"You're downsized." (1990) +"You're rightsized." (1992) + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a62c20480736415ac0e446f303129af0c90a88fc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:22 +0100 Subject: [PATCH 0578/3340] - patchlevel 707 --- 7.3.707 | 127 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 127 insertions(+) create mode 100644 7.3.707 diff --git a/7.3.707 b/7.3.707 new file mode 100644 index 00000000..a541b2e9 --- /dev/null +++ b/7.3.707 @@ -0,0 +1,127 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.707 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.707 (after 7.3.701) +Problem: Problems loading a library for a file name with non-latin + characters. +Solution: Use wide system functions when possible. (Ken Takata) +Files: src/os_win32.c, src/os_win32.h + + +*** ../vim-7.3.706/src/os_win32.c 2012-10-21 02:37:02.000000000 +0200 +--- src/os_win32.c 2012-10-21 21:33:58.000000000 +0200 +*************** +*** 287,313 **** + HINSTANCE + vimLoadLib(char *name) + { +! HINSTANCE dll = NULL; +! TCHAR old_dir[MAXPATHL]; + + /* NOTE: Do not use mch_dirname() and mch_chdir() here, they may call + * vimLoadLib() recursively, which causes a stack overflow. */ + if (exe_path == NULL) + get_exe_name(); +! if (exe_path != NULL && GetCurrentDirectory(MAXPATHL, old_dir) != 0) + { +! /* Change directory to where the executable is, both to make sure we +! * find a .dll there and to avoid looking for a .dll in the current +! * directory. */ +! SetCurrentDirectory(exe_path); +! dll = LoadLibrary(name); +! SetCurrentDirectory(old_dir); +! } +! else +! { +! /* We are not able to change directory to where the executable is, try +! * to load library anyway. */ +! dll = LoadLibrary(name); + } + return dll; + } +--- 287,326 ---- + HINSTANCE + vimLoadLib(char *name) + { +! HINSTANCE dll = NULL; +! char old_dir[MAXPATHL]; + + /* NOTE: Do not use mch_dirname() and mch_chdir() here, they may call + * vimLoadLib() recursively, which causes a stack overflow. */ + if (exe_path == NULL) + get_exe_name(); +! if (exe_path != NULL) + { +! #ifdef FEAT_MBYTE +! WCHAR old_dirw[MAXPATHL]; +! +! if (GetCurrentDirectoryW(MAXPATHL, old_dirw) != 0) +! { +! /* Change directory to where the executable is, both to make +! * sure we find a .dll there and to avoid looking for a .dll +! * in the current directory. */ +! SetCurrentDirectory(exe_path); +! dll = LoadLibrary(name); +! SetCurrentDirectoryW(old_dirw); +! return dll; +! } +! /* Retry with non-wide function (for Windows 98). */ +! if (GetLastError() == ERROR_CALL_NOT_IMPLEMENTED) +! #endif +! if (GetCurrentDirectory(MAXPATHL, old_dir) != 0) +! { +! /* Change directory to where the executable is, both to make +! * sure we find a .dll there and to avoid looking for a .dll +! * in the current directory. */ +! SetCurrentDirectory(exe_path); +! dll = LoadLibrary(name); +! SetCurrentDirectory(old_dir); +! } + } + return dll; + } +*** ../vim-7.3.706/src/os_win32.h 2011-08-10 17:07:56.000000000 +0200 +--- src/os_win32.h 2012-10-21 21:33:30.000000000 +0200 +*************** +*** 108,114 **** + */ + #define CMDBUFFSIZE 1024 /* size of the command processing buffer */ + +! /* _MAX_PATH is only 256 (stdlib.h), but we want more for the 'path' option, + * thus use a larger number. */ + #define MAXPATHL 1024 + +--- 108,114 ---- + */ + #define CMDBUFFSIZE 1024 /* size of the command processing buffer */ + +! /* _MAX_PATH is only 260 (stdlib.h), but we want more for the 'path' option, + * thus use a larger number. */ + #define MAXPATHL 1024 + +*** ../vim-7.3.706/src/version.c 2012-10-21 21:25:17.000000000 +0200 +--- src/version.c 2012-10-21 21:37:52.000000000 +0200 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 707, + /**/ + +-- +Our job was to build a computer information system for the branch banks. We +were the perfect people for the job: Dean had seen a computer once, and I had +heard Dean talk about it. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bbd61e3e1c3b798793eb0da2b47aeaf95bb7512a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:23 +0100 Subject: [PATCH 0579/3340] - patchlevel 708 --- 7.3.708 | 107 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 107 insertions(+) create mode 100644 7.3.708 diff --git a/7.3.708 b/7.3.708 new file mode 100644 index 00000000..644930d1 --- /dev/null +++ b/7.3.708 @@ -0,0 +1,107 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.708 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.708 +Problem: Filler lines above the first line may be hidden when opening Vim. +Solution: Change how topfill is computed. (Christian Brabandt) +Files: src/diff.c, src/testdir/test47.in, src/testdir/test47.ok + + +*** ../vim-7.3.707/src/diff.c 2012-05-18 18:47:11.000000000 +0200 +--- src/diff.c 2012-10-21 22:08:44.000000000 +0200 +*************** +*** 615,625 **** + #endif + /* A change may have made filler lines invalid, need to take care + * of that for other windows. */ +! if (wp != curwin && wp->w_topfill > 0) + { +- n = diff_check(wp, wp->w_topline); + if (wp->w_topfill > n) + wp->w_topfill = (n < 0 ? 0 : n); + } + } + } +--- 615,627 ---- + #endif + /* A change may have made filler lines invalid, need to take care + * of that for other windows. */ +! n = diff_check(wp, wp->w_topline); +! if ((wp != curwin && wp->w_topfill > 0) || n > 0) + { + if (wp->w_topfill > n) + wp->w_topfill = (n < 0 ? 0 : n); ++ else if (n > 0 && n > wp->w_topfill) ++ wp->w_topfill = n; + } + } + } +*** ../vim-7.3.707/src/testdir/test47.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test47.in 2012-10-21 22:08:44.000000000 +0200 +*************** +*** 36,42 **** + :call append("$", two) + :call append("$", three) + :$-2,$w! test.out +! :unlet one two three + :qa! + ENDTEST + +--- 36,57 ---- + :call append("$", two) + :call append("$", three) + :$-2,$w! test.out +! :" Test that diffing shows correct filler lines +! :diffoff! +! :windo :bw! +! :enew +! :put =range(4,10) +! :1d _ +! :vnew +! :put =range(1,10) +! :1d _ +! :windo :diffthis +! :wincmd h +! :let w0=line('w0') +! :enew +! :put =w0 +! :.w >> test.out +! :unlet! one two three w0 + :qa! + ENDTEST + +*** ../vim-7.3.707/src/testdir/test47.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test47.ok 2012-10-21 22:08:44.000000000 +0200 +*************** +*** 1,3 **** +--- 1,4 ---- + 2-4-5-6-8-9 + 1-2-4-5-8 + 2-3-4-5-6-7-8 ++ 1 +*** ../vim-7.3.707/src/version.c 2012-10-21 21:38:42.000000000 +0200 +--- src/version.c 2012-10-21 22:10:42.000000000 +0200 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 708, + /**/ + +-- +At some point in the project somebody will start whining about the need to +determine the project "requirements". This involves interviewing people who +don't know what they want but, curiously, know exactly when they need it. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0176f636657a4f24d47a9b75dff0eb9569523192 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:24 +0100 Subject: [PATCH 0580/3340] - patchlevel 709 --- 7.3.709 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.709 diff --git a/7.3.709 b/7.3.709 new file mode 100644 index 00000000..40c837fc --- /dev/null +++ b/7.3.709 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.709 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.709 +Problem: Compiler warning for unused argument. +Solution: Add UNUSED. +Files: src/eval.c + + +*** ../vim-7.3.708/src/eval.c 2012-10-21 02:17:28.000000000 +0200 +--- src/eval.c 2012-10-21 23:53:32.000000000 +0200 +*************** +*** 16664,16670 **** + */ + static void + f_shiftwidth(argvars, rettv) +! typval_T *argvars; + typval_T *rettv; + { + rettv->vval.v_number = get_sw_value(); +--- 16664,16670 ---- + */ + static void + f_shiftwidth(argvars, rettv) +! typval_T *argvars UNUSED; + typval_T *rettv; + { + rettv->vval.v_number = get_sw_value(); +*** ../vim-7.3.708/src/version.c 2012-10-21 22:18:17.000000000 +0200 +--- src/version.c 2012-10-21 23:55:01.000000000 +0200 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 709, + /**/ + +-- +The only way the average employee can speak to an executive is by taking a +second job as a golf caddie. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 976f905879598d629264375cb7eb19f84e1149ae Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:24 +0100 Subject: [PATCH 0581/3340] - patchlevel 710 --- 7.3.710 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.710 diff --git a/7.3.710 b/7.3.710 new file mode 100644 index 00000000..bfefea36 --- /dev/null +++ b/7.3.710 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.710 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.710 (after 7.3.704) +Problem: Patch 7.3.704 breaks "fn". +Solution: Add check for ca.cmdchar. (Christian Brabandt) +Files: src/normal.c + + +*** ../vim-7.3.709/src/normal.c 2012-10-21 03:54:27.000000000 +0200 +--- src/normal.c 2012-10-23 05:02:27.000000000 +0200 +*************** +*** 1086,1092 **** + ca.nchar = ca.extra_char; + idx = find_command(ca.cmdchar); + } +! else if (ca.nchar == 'n' || ca.nchar == 'N') + ca.oap->op_type = get_op_type(*cp, NUL); + else if (*cp == Ctrl_BSL) + { +--- 1086,1092 ---- + ca.nchar = ca.extra_char; + idx = find_command(ca.cmdchar); + } +! else if ((ca.nchar == 'n' || ca.nchar == 'N') && ca.cmdchar == 'g') + ca.oap->op_type = get_op_type(*cp, NUL); + else if (*cp == Ctrl_BSL) + { +*** ../vim-7.3.709/src/version.c 2012-10-21 23:55:59.000000000 +0200 +--- src/version.c 2012-10-23 04:59:21.000000000 +0200 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 710, + /**/ + +-- +The budget process was invented by an alien race of sadistic beings who +resemble large cats. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 02743bf889aa902421206491aa0dea33a02cd048 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:25 +0100 Subject: [PATCH 0582/3340] - patchlevel 711 --- 7.3.711 | 178 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 178 insertions(+) create mode 100644 7.3.711 diff --git a/7.3.711 b/7.3.711 new file mode 100644 index 00000000..74ef3cbc --- /dev/null +++ b/7.3.711 @@ -0,0 +1,178 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.711 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.711 (after 7.3.688) +Problem: vim.current.buffer is not available. (lilydjwg) +Solution: Use py3_PyUnicode_AsUTF8 instead of py3_PyUnicode_AsUTF8String. + (Ken Takata) +Files: src/if_python3.c + + +*** ../vim-7.3.710/src/if_python3.c 2012-10-21 01:46:56.000000000 +0200 +--- src/if_python3.c 2012-10-23 05:15:31.000000000 +0200 +*************** +*** 176,182 **** + # define PyImport_AppendInittab py3_PyImport_AppendInittab + # if PY_VERSION_HEX >= 0x030300f0 + # undef _PyUnicode_AsString +! # define _PyUnicode_AsString py3_PyUnicode_AsUTF8String + # else + # define _PyUnicode_AsString py3__PyUnicode_AsString + # endif +--- 176,182 ---- + # define PyImport_AppendInittab py3_PyImport_AppendInittab + # if PY_VERSION_HEX >= 0x030300f0 + # undef _PyUnicode_AsString +! # define _PyUnicode_AsString py3_PyUnicode_AsUTF8 + # else + # define _PyUnicode_AsString py3__PyUnicode_AsString + # endif +*************** +*** 286,296 **** + static PyObject* py3__Py_TrueStruct; + static int (*py3_PyModule_AddObject)(PyObject *m, const char *name, PyObject *o); + static int (*py3_PyImport_AppendInittab)(const char *name, PyObject* (*initfunc)(void)); +! #if PY_VERSION_HEX >= 0x030300f0 +! static char* (*py3_PyUnicode_AsUTF8String)(PyObject *unicode); +! #else + static char* (*py3__PyUnicode_AsString)(PyObject *unicode); +! #endif + static PyObject* (*py3_PyUnicode_AsEncodedString)(PyObject *unicode, const char* encoding, const char* errors); + static char* (*py3_PyBytes_AsString)(PyObject *bytes); + static int (*py3_PyBytes_AsStringAndSize)(PyObject *bytes, char **buffer, int *length); +--- 286,296 ---- + static PyObject* py3__Py_TrueStruct; + static int (*py3_PyModule_AddObject)(PyObject *m, const char *name, PyObject *o); + static int (*py3_PyImport_AppendInittab)(const char *name, PyObject* (*initfunc)(void)); +! # if PY_VERSION_HEX >= 0x030300f0 +! static char* (*py3_PyUnicode_AsUTF8)(PyObject *unicode); +! # else + static char* (*py3__PyUnicode_AsString)(PyObject *unicode); +! # endif + static PyObject* (*py3_PyUnicode_AsEncodedString)(PyObject *unicode, const char* encoding, const char* errors); + static char* (*py3_PyBytes_AsString)(PyObject *bytes); + static int (*py3_PyBytes_AsStringAndSize)(PyObject *bytes, char **buffer, int *length); +*************** +*** 348,360 **** + {"PySys_SetArgv", (PYTHON_PROC*)&py3_PySys_SetArgv}, + {"Py_SetPythonHome", (PYTHON_PROC*)&py3_Py_SetPythonHome}, + {"Py_Initialize", (PYTHON_PROC*)&py3_Py_Initialize}, +! #ifndef PY_SSIZE_T_CLEAN + {"PyArg_ParseTuple", (PYTHON_PROC*)&py3_PyArg_ParseTuple}, + {"Py_BuildValue", (PYTHON_PROC*)&py3_Py_BuildValue}, +! #else + {"_PyArg_ParseTuple_SizeT", (PYTHON_PROC*)&py3_PyArg_ParseTuple}, + {"_Py_BuildValue_SizeT", (PYTHON_PROC*)&py3_Py_BuildValue}, +! #endif + {"PyMem_Free", (PYTHON_PROC*)&py3_PyMem_Free}, + {"PyMem_Malloc", (PYTHON_PROC*)&py3_PyMem_Malloc}, + {"PyList_New", (PYTHON_PROC*)&py3_PyList_New}, +--- 348,360 ---- + {"PySys_SetArgv", (PYTHON_PROC*)&py3_PySys_SetArgv}, + {"Py_SetPythonHome", (PYTHON_PROC*)&py3_Py_SetPythonHome}, + {"Py_Initialize", (PYTHON_PROC*)&py3_Py_Initialize}, +! # ifndef PY_SSIZE_T_CLEAN + {"PyArg_ParseTuple", (PYTHON_PROC*)&py3_PyArg_ParseTuple}, + {"Py_BuildValue", (PYTHON_PROC*)&py3_Py_BuildValue}, +! # else + {"_PyArg_ParseTuple_SizeT", (PYTHON_PROC*)&py3_PyArg_ParseTuple}, + {"_Py_BuildValue_SizeT", (PYTHON_PROC*)&py3_Py_BuildValue}, +! # endif + {"PyMem_Free", (PYTHON_PROC*)&py3_PyMem_Free}, + {"PyMem_Malloc", (PYTHON_PROC*)&py3_PyMem_Malloc}, + {"PyList_New", (PYTHON_PROC*)&py3_PyList_New}, +*************** +*** 406,416 **** + {"PyObject_Init", (PYTHON_PROC*)&py3__PyObject_Init}, + {"PyModule_AddObject", (PYTHON_PROC*)&py3_PyModule_AddObject}, + {"PyImport_AppendInittab", (PYTHON_PROC*)&py3_PyImport_AppendInittab}, +! #if PY_VERSION_HEX >= 0x030300f0 +! {"PyUnicode_AsUTF8String", (PYTHON_PROC*)&py3_PyUnicode_AsUTF8String}, +! #else + {"_PyUnicode_AsString", (PYTHON_PROC*)&py3__PyUnicode_AsString}, +! #endif + {"PyBytes_AsString", (PYTHON_PROC*)&py3_PyBytes_AsString}, + {"PyBytes_AsStringAndSize", (PYTHON_PROC*)&py3_PyBytes_AsStringAndSize}, + {"PyBytes_FromString", (PYTHON_PROC*)&py3_PyBytes_FromString}, +--- 406,416 ---- + {"PyObject_Init", (PYTHON_PROC*)&py3__PyObject_Init}, + {"PyModule_AddObject", (PYTHON_PROC*)&py3_PyModule_AddObject}, + {"PyImport_AppendInittab", (PYTHON_PROC*)&py3_PyImport_AppendInittab}, +! # if PY_VERSION_HEX >= 0x030300f0 +! {"PyUnicode_AsUTF8", (PYTHON_PROC*)&py3_PyUnicode_AsUTF8}, +! # else + {"_PyUnicode_AsString", (PYTHON_PROC*)&py3__PyUnicode_AsString}, +! # endif + {"PyBytes_AsString", (PYTHON_PROC*)&py3_PyBytes_AsString}, + {"PyBytes_AsStringAndSize", (PYTHON_PROC*)&py3_PyBytes_AsStringAndSize}, + {"PyBytes_FromString", (PYTHON_PROC*)&py3_PyBytes_FromString}, +*************** +*** 503,514 **** + + /* Load unicode functions separately as only the ucs2 or the ucs4 functions + * will be present in the library. */ +! #if PY_VERSION_HEX >= 0x030300f0 + ucs_from_string = symbol_from_dll(hinstPy3, "PyUnicode_FromString"); + ucs_decode = symbol_from_dll(hinstPy3, "PyUnicode_Decode"); + ucs_as_encoded_string = symbol_from_dll(hinstPy3, + "PyUnicode_AsEncodedString"); +! #else + ucs_from_string = symbol_from_dll(hinstPy3, "PyUnicodeUCS2_FromString"); + ucs_decode = symbol_from_dll(hinstPy3, + "PyUnicodeUCS2_Decode"); +--- 503,514 ---- + + /* Load unicode functions separately as only the ucs2 or the ucs4 functions + * will be present in the library. */ +! # if PY_VERSION_HEX >= 0x030300f0 + ucs_from_string = symbol_from_dll(hinstPy3, "PyUnicode_FromString"); + ucs_decode = symbol_from_dll(hinstPy3, "PyUnicode_Decode"); + ucs_as_encoded_string = symbol_from_dll(hinstPy3, + "PyUnicode_AsEncodedString"); +! # else + ucs_from_string = symbol_from_dll(hinstPy3, "PyUnicodeUCS2_FromString"); + ucs_decode = symbol_from_dll(hinstPy3, + "PyUnicodeUCS2_Decode"); +*************** +*** 523,529 **** + ucs_as_encoded_string = symbol_from_dll(hinstPy3, + "PyUnicodeUCS4_AsEncodedString"); + } +! #endif + if (ucs_from_string && ucs_decode && ucs_as_encoded_string) + { + py3_PyUnicode_FromString = ucs_from_string; +--- 523,529 ---- + ucs_as_encoded_string = symbol_from_dll(hinstPy3, + "PyUnicodeUCS4_AsEncodedString"); + } +! # endif + if (ucs_from_string && ucs_decode && ucs_as_encoded_string) + { + py3_PyUnicode_FromString = ucs_from_string; +*** ../vim-7.3.710/src/version.c 2012-10-23 05:08:49.000000000 +0200 +--- src/version.c 2012-10-23 05:14:27.000000000 +0200 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 711, + /**/ + +-- +The fastest way to get an engineer to solve a problem is to declare that the +problem is unsolvable. No engineer can walk away from an unsolvable problem +until it's solved. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From af81361af1dda70743a304d9d23b8b7283115668 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:26 +0100 Subject: [PATCH 0583/3340] - patchlevel 712 --- 7.3.712 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.712 diff --git a/7.3.712 b/7.3.712 new file mode 100644 index 00000000..2ca9fb9a --- /dev/null +++ b/7.3.712 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.712 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.712 +Problem: Nmake from VS2010 SP1 is not recognized. +Solution: Add the version number. (Ken Takata) +Files: src/Make_mvc.mak + + +*** ../vim-7.3.711/src/Make_mvc.mak 2012-10-21 02:41:04.000000000 +0200 +--- src/Make_mvc.mak 2012-10-23 05:33:33.000000000 +0200 +*************** +*** 407,412 **** +--- 407,415 ---- + !if "$(_NMAKE_VER)" == "10.00.30319.01" + MSVCVER = 10.0 + !endif ++ !if "$(_NMAKE_VER)" == "10.00.40219.01" ++ MSVCVER = 10.0 ++ !endif + !if "$(_NMAKE_VER)" == "11.00.50727.1" + MSVCVER = 11.0 + !endif +*** ../vim-7.3.711/src/version.c 2012-10-23 05:17:33.000000000 +0200 +--- src/version.c 2012-10-23 05:34:24.000000000 +0200 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 712, + /**/ + +-- +Engineers are widely recognized as superior marriage material: intelligent, +dependable, employed, honest, and handy around the house. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 722559bee4cd503ffd3d755dc1f7c5970dd84297 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:31:27 +0100 Subject: [PATCH 0584/3340] - patchlevel 712 --- README.patches | 30 +++++ vim-update.sh | 2 +- vim.spec | 347 ++++++++++++++++++++++++++++++++++++++++++++++++- 3 files changed, 376 insertions(+), 3 deletions(-) diff --git a/README.patches b/README.patches index cb9e52ec..c407164b 100644 --- a/README.patches +++ b/README.patches @@ -713,3 +713,33 @@ Individual patches for Vim 7.3: 2190 7.3.680 some files missing in the list of distributed files 2014 7.3.681 list of distributed files picks up backup files 1791 7.3.682 (after 7.3.677) compiler complains about incompatible types + 2578 7.3.683 ":python" may crash when vimbindeval() returns None + 4714 7.3.684 "make test" does not delete lua.vim + 1827 7.3.685 no test for what patch 7.3.673 fixes + 2226 7.3.686 cannot use CTRL-\ e mapping when entering an expression + 1386 7.3.687 test 16 fails when $DISPLAY is not set + 5283 7.3.688 Python 3.3 is not supported + 2266 7.3.689 MzScheme and Lua may use a NULL string + 1806 7.3.690 crash with directory name equal to maximum path length + 1910 7.3.691 state specific to the Python thread is discarded + 1598 7.3.692 can't build GTK version with GTK 2.0 + 5071 7.3.693 can't make 'softtabstop' follow 'shiftwidth' + 4631 7.3.694 'shiftwidth' is not so easy to use in indent files + 3710 7.3.695 balloon cannot show multi-byte text + 2994 7.3.696 message about added spell language can be wrong + 6108 7.3.697 leaking resources when setting GUI font + 2742 7.3.698 Python 3 does not preserve state beween commands + 2522 7.3.699 manually set 'ttymouse' is overruled by automatic detection + 2214 7.3.700 cannot detect URXVT and SGR mouse support + 2616 7.3.701 MS-Windows: Crash with stack overflow when setting 'encoding' + 1352 7.3.702 nmake from VS6 service pack 6 is not recognized + 3326 7.3.703 when 'undofile' is reset the hash is computed unnecessarily + 2906 7.3.704 repeating "cgn" does not always work correctly + 2581 7.3.705 mouse features are not in alphabetical order + 1638 7.3.706 (after 7.3.697) can't build Motif version + 4088 7.3.707 (after 7.3.701) library name with non-latin characters fails + 3001 7.3.708 filler lines above the first line may be hidden + 1513 7.3.709 compiler warning for unused argument + 1685 7.3.710 (after 7.3.704) "fn" is broken + 7579 7.3.711 (after 7.3.688) vim.current.buffer is not available + 1474 7.3.712 nmake from VS2010 SP1 is not recognized diff --git a/vim-update.sh b/vim-update.sh index dd8c34ba..9d87b8fe 100755 --- a/vim-update.sh +++ b/vim-update.sh @@ -2,7 +2,7 @@ debug="" #debug="echo" -cd $HOME/src/fedora/rpms/vim/master/ +cd `dirname $0` LANG=C SPEC=vim.spec diff --git a/vim.spec b/vim.spec index cb99c211..51da0f69 100644 --- a/vim.spec +++ b/vim.spec @@ -18,13 +18,13 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 682 +%define patchlevel 712 Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 2%{?dist} +Release: 1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -738,6 +738,176 @@ Patch679: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.679 Patch680: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.680 Patch681: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.681 Patch682: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.682 +Patch683: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.683 +Patch684: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.684 +Patch685: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.685 +Patch686: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.686 +Patch687: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.687 +Patch688: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.688 +Patch689: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.689 +Patch690: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.690 +Patch691: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.691 +Patch692: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.692 +Patch693: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.693 +Patch694: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.694 +Patch695: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.695 +Patch696: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.696 +Patch697: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.697 +Patch698: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.698 +Patch699: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.699 +Patch700: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.700 +Patch701: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.701 +Patch702: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.702 +Patch703: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.703 +Patch704: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.704 +Patch705: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.705 +Patch706: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.706 +Patch707: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.707 +Patch708: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.708 +Patch709: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.709 +Patch710: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.710 +Patch711: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.711 +Patch712: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.712 +Patch683: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.683 +Patch684: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.684 +Patch685: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.685 +Patch686: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.686 +Patch687: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.687 +Patch688: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.688 +Patch689: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.689 +Patch690: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.690 +Patch691: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.691 +Patch692: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.692 +Patch693: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.693 +Patch694: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.694 +Patch695: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.695 +Patch696: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.696 +Patch697: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.697 +Patch698: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.698 +Patch699: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.699 +Patch700: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.700 +Patch701: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.701 +Patch702: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.702 +Patch703: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.703 +Patch704: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.704 +Patch705: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.705 +Patch706: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.706 +Patch707: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.707 +Patch708: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.708 +Patch709: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.709 +Patch710: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.710 +Patch711: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.711 +Patch712: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.712 +Patch684: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.684 +Patch685: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.685 +Patch686: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.686 +Patch687: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.687 +Patch688: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.688 +Patch689: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.689 +Patch690: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.690 +Patch691: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.691 +Patch692: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.692 +Patch693: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.693 +Patch694: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.694 +Patch695: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.695 +Patch696: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.696 +Patch697: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.697 +Patch698: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.698 +Patch699: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.699 +Patch700: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.700 +Patch701: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.701 +Patch702: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.702 +Patch703: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.703 +Patch704: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.704 +Patch705: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.705 +Patch706: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.706 +Patch707: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.707 +Patch708: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.708 +Patch709: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.709 +Patch710: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.710 +Patch711: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.711 +Patch712: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.712 +Patch685: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.685 +Patch686: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.686 +Patch687: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.687 +Patch688: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.688 +Patch689: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.689 +Patch690: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.690 +Patch691: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.691 +Patch692: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.692 +Patch693: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.693 +Patch694: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.694 +Patch695: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.695 +Patch696: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.696 +Patch697: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.697 +Patch698: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.698 +Patch699: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.699 +Patch700: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.700 +Patch701: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.701 +Patch702: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.702 +Patch703: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.703 +Patch704: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.704 +Patch705: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.705 +Patch706: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.706 +Patch707: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.707 +Patch708: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.708 +Patch709: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.709 +Patch710: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.710 +Patch711: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.711 +Patch712: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.712 +Patch686: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.686 +Patch687: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.687 +Patch688: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.688 +Patch689: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.689 +Patch690: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.690 +Patch691: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.691 +Patch692: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.692 +Patch693: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.693 +Patch694: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.694 +Patch695: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.695 +Patch696: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.696 +Patch697: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.697 +Patch698: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.698 +Patch699: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.699 +Patch700: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.700 +Patch701: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.701 +Patch702: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.702 +Patch703: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.703 +Patch704: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.704 +Patch705: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.705 +Patch706: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.706 +Patch707: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.707 +Patch708: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.708 +Patch709: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.709 +Patch710: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.710 +Patch711: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.711 +Patch712: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.712 +Patch687: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.687 +Patch688: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.688 +Patch689: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.689 +Patch690: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.690 +Patch691: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.691 +Patch692: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.692 +Patch693: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.693 +Patch694: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.694 +Patch695: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.695 +Patch696: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.696 +Patch697: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.697 +Patch698: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.698 +Patch699: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.699 +Patch700: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.700 +Patch701: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.701 +Patch702: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.702 +Patch703: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.703 +Patch704: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.704 +Patch705: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.705 +Patch706: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.706 +Patch707: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.707 +Patch708: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.708 +Patch709: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.709 +Patch710: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.710 +Patch711: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.711 +Patch712: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.712 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1566,6 +1736,176 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch680 -p0 %patch681 -p0 %patch682 -p0 +%patch683 -p0 +%patch684 -p0 +%patch685 -p0 +%patch686 -p0 +%patch687 -p0 +%patch688 -p0 +%patch689 -p0 +%patch690 -p0 +%patch691 -p0 +%patch692 -p0 +%patch693 -p0 +%patch694 -p0 +%patch695 -p0 +%patch696 -p0 +%patch697 -p0 +%patch698 -p0 +%patch699 -p0 +%patch700 -p0 +%patch701 -p0 +%patch702 -p0 +%patch703 -p0 +%patch704 -p0 +%patch705 -p0 +%patch706 -p0 +%patch707 -p0 +%patch708 -p0 +%patch709 -p0 +%patch710 -p0 +%patch711 -p0 +%patch712 -p0 +%patch683 -p0 +%patch684 -p0 +%patch685 -p0 +%patch686 -p0 +%patch687 -p0 +%patch688 -p0 +%patch689 -p0 +%patch690 -p0 +%patch691 -p0 +%patch692 -p0 +%patch693 -p0 +%patch694 -p0 +%patch695 -p0 +%patch696 -p0 +%patch697 -p0 +%patch698 -p0 +%patch699 -p0 +%patch700 -p0 +%patch701 -p0 +%patch702 -p0 +%patch703 -p0 +%patch704 -p0 +%patch705 -p0 +%patch706 -p0 +%patch707 -p0 +%patch708 -p0 +%patch709 -p0 +%patch710 -p0 +%patch711 -p0 +%patch712 -p0 +%patch684 -p0 +%patch685 -p0 +%patch686 -p0 +%patch687 -p0 +%patch688 -p0 +%patch689 -p0 +%patch690 -p0 +%patch691 -p0 +%patch692 -p0 +%patch693 -p0 +%patch694 -p0 +%patch695 -p0 +%patch696 -p0 +%patch697 -p0 +%patch698 -p0 +%patch699 -p0 +%patch700 -p0 +%patch701 -p0 +%patch702 -p0 +%patch703 -p0 +%patch704 -p0 +%patch705 -p0 +%patch706 -p0 +%patch707 -p0 +%patch708 -p0 +%patch709 -p0 +%patch710 -p0 +%patch711 -p0 +%patch712 -p0 +%patch685 -p0 +%patch686 -p0 +%patch687 -p0 +%patch688 -p0 +%patch689 -p0 +%patch690 -p0 +%patch691 -p0 +%patch692 -p0 +%patch693 -p0 +%patch694 -p0 +%patch695 -p0 +%patch696 -p0 +%patch697 -p0 +%patch698 -p0 +%patch699 -p0 +%patch700 -p0 +%patch701 -p0 +%patch702 -p0 +%patch703 -p0 +%patch704 -p0 +%patch705 -p0 +%patch706 -p0 +%patch707 -p0 +%patch708 -p0 +%patch709 -p0 +%patch710 -p0 +%patch711 -p0 +%patch712 -p0 +%patch686 -p0 +%patch687 -p0 +%patch688 -p0 +%patch689 -p0 +%patch690 -p0 +%patch691 -p0 +%patch692 -p0 +%patch693 -p0 +%patch694 -p0 +%patch695 -p0 +%patch696 -p0 +%patch697 -p0 +%patch698 -p0 +%patch699 -p0 +%patch700 -p0 +%patch701 -p0 +%patch702 -p0 +%patch703 -p0 +%patch704 -p0 +%patch705 -p0 +%patch706 -p0 +%patch707 -p0 +%patch708 -p0 +%patch709 -p0 +%patch710 -p0 +%patch711 -p0 +%patch712 -p0 +%patch687 -p0 +%patch688 -p0 +%patch689 -p0 +%patch690 -p0 +%patch691 -p0 +%patch692 -p0 +%patch693 -p0 +%patch694 -p0 +%patch695 -p0 +%patch696 -p0 +%patch697 -p0 +%patch698 -p0 +%patch699 -p0 +%patch700 -p0 +%patch701 -p0 +%patch702 -p0 +%patch703 -p0 +%patch704 -p0 +%patch705 -p0 +%patch706 -p0 +%patch707 -p0 +%patch708 -p0 +%patch709 -p0 +%patch710 -p0 +%patch711 -p0 +%patch712 -p0 # install spell files @@ -2031,6 +2371,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Nov 12 2012 Karsten Hopp 7.3.712-1 +- patchlevel 712 + * Mon Nov 12 2012 Karsten Hopp 7.3.682-2 - fix vim.csh syntax From e725645fa86f7860e40b572b9017f147d246f19f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 15:33:42 +0100 Subject: [PATCH 0585/3340] fix cut&paste error --- vim.spec | 280 ------------------------------------------------------- 1 file changed, 280 deletions(-) diff --git a/vim.spec b/vim.spec index 51da0f69..64189630 100644 --- a/vim.spec +++ b/vim.spec @@ -768,146 +768,6 @@ Patch709: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.709 Patch710: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.710 Patch711: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.711 Patch712: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.712 -Patch683: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.683 -Patch684: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.684 -Patch685: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.685 -Patch686: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.686 -Patch687: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.687 -Patch688: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.688 -Patch689: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.689 -Patch690: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.690 -Patch691: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.691 -Patch692: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.692 -Patch693: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.693 -Patch694: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.694 -Patch695: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.695 -Patch696: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.696 -Patch697: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.697 -Patch698: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.698 -Patch699: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.699 -Patch700: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.700 -Patch701: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.701 -Patch702: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.702 -Patch703: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.703 -Patch704: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.704 -Patch705: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.705 -Patch706: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.706 -Patch707: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.707 -Patch708: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.708 -Patch709: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.709 -Patch710: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.710 -Patch711: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.711 -Patch712: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.712 -Patch684: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.684 -Patch685: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.685 -Patch686: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.686 -Patch687: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.687 -Patch688: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.688 -Patch689: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.689 -Patch690: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.690 -Patch691: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.691 -Patch692: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.692 -Patch693: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.693 -Patch694: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.694 -Patch695: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.695 -Patch696: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.696 -Patch697: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.697 -Patch698: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.698 -Patch699: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.699 -Patch700: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.700 -Patch701: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.701 -Patch702: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.702 -Patch703: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.703 -Patch704: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.704 -Patch705: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.705 -Patch706: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.706 -Patch707: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.707 -Patch708: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.708 -Patch709: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.709 -Patch710: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.710 -Patch711: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.711 -Patch712: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.712 -Patch685: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.685 -Patch686: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.686 -Patch687: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.687 -Patch688: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.688 -Patch689: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.689 -Patch690: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.690 -Patch691: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.691 -Patch692: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.692 -Patch693: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.693 -Patch694: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.694 -Patch695: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.695 -Patch696: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.696 -Patch697: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.697 -Patch698: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.698 -Patch699: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.699 -Patch700: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.700 -Patch701: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.701 -Patch702: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.702 -Patch703: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.703 -Patch704: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.704 -Patch705: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.705 -Patch706: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.706 -Patch707: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.707 -Patch708: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.708 -Patch709: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.709 -Patch710: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.710 -Patch711: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.711 -Patch712: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.712 -Patch686: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.686 -Patch687: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.687 -Patch688: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.688 -Patch689: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.689 -Patch690: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.690 -Patch691: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.691 -Patch692: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.692 -Patch693: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.693 -Patch694: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.694 -Patch695: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.695 -Patch696: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.696 -Patch697: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.697 -Patch698: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.698 -Patch699: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.699 -Patch700: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.700 -Patch701: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.701 -Patch702: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.702 -Patch703: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.703 -Patch704: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.704 -Patch705: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.705 -Patch706: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.706 -Patch707: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.707 -Patch708: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.708 -Patch709: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.709 -Patch710: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.710 -Patch711: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.711 -Patch712: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.712 -Patch687: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.687 -Patch688: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.688 -Patch689: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.689 -Patch690: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.690 -Patch691: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.691 -Patch692: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.692 -Patch693: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.693 -Patch694: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.694 -Patch695: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.695 -Patch696: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.696 -Patch697: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.697 -Patch698: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.698 -Patch699: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.699 -Patch700: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.700 -Patch701: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.701 -Patch702: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.702 -Patch703: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.703 -Patch704: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.704 -Patch705: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.705 -Patch706: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.706 -Patch707: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.707 -Patch708: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.708 -Patch709: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.709 -Patch710: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.710 -Patch711: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.711 -Patch712: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.712 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1766,146 +1626,6 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch710 -p0 %patch711 -p0 %patch712 -p0 -%patch683 -p0 -%patch684 -p0 -%patch685 -p0 -%patch686 -p0 -%patch687 -p0 -%patch688 -p0 -%patch689 -p0 -%patch690 -p0 -%patch691 -p0 -%patch692 -p0 -%patch693 -p0 -%patch694 -p0 -%patch695 -p0 -%patch696 -p0 -%patch697 -p0 -%patch698 -p0 -%patch699 -p0 -%patch700 -p0 -%patch701 -p0 -%patch702 -p0 -%patch703 -p0 -%patch704 -p0 -%patch705 -p0 -%patch706 -p0 -%patch707 -p0 -%patch708 -p0 -%patch709 -p0 -%patch710 -p0 -%patch711 -p0 -%patch712 -p0 -%patch684 -p0 -%patch685 -p0 -%patch686 -p0 -%patch687 -p0 -%patch688 -p0 -%patch689 -p0 -%patch690 -p0 -%patch691 -p0 -%patch692 -p0 -%patch693 -p0 -%patch694 -p0 -%patch695 -p0 -%patch696 -p0 -%patch697 -p0 -%patch698 -p0 -%patch699 -p0 -%patch700 -p0 -%patch701 -p0 -%patch702 -p0 -%patch703 -p0 -%patch704 -p0 -%patch705 -p0 -%patch706 -p0 -%patch707 -p0 -%patch708 -p0 -%patch709 -p0 -%patch710 -p0 -%patch711 -p0 -%patch712 -p0 -%patch685 -p0 -%patch686 -p0 -%patch687 -p0 -%patch688 -p0 -%patch689 -p0 -%patch690 -p0 -%patch691 -p0 -%patch692 -p0 -%patch693 -p0 -%patch694 -p0 -%patch695 -p0 -%patch696 -p0 -%patch697 -p0 -%patch698 -p0 -%patch699 -p0 -%patch700 -p0 -%patch701 -p0 -%patch702 -p0 -%patch703 -p0 -%patch704 -p0 -%patch705 -p0 -%patch706 -p0 -%patch707 -p0 -%patch708 -p0 -%patch709 -p0 -%patch710 -p0 -%patch711 -p0 -%patch712 -p0 -%patch686 -p0 -%patch687 -p0 -%patch688 -p0 -%patch689 -p0 -%patch690 -p0 -%patch691 -p0 -%patch692 -p0 -%patch693 -p0 -%patch694 -p0 -%patch695 -p0 -%patch696 -p0 -%patch697 -p0 -%patch698 -p0 -%patch699 -p0 -%patch700 -p0 -%patch701 -p0 -%patch702 -p0 -%patch703 -p0 -%patch704 -p0 -%patch705 -p0 -%patch706 -p0 -%patch707 -p0 -%patch708 -p0 -%patch709 -p0 -%patch710 -p0 -%patch711 -p0 -%patch712 -p0 -%patch687 -p0 -%patch688 -p0 -%patch689 -p0 -%patch690 -p0 -%patch691 -p0 -%patch692 -p0 -%patch693 -p0 -%patch694 -p0 -%patch695 -p0 -%patch696 -p0 -%patch697 -p0 -%patch698 -p0 -%patch699 -p0 -%patch700 -p0 -%patch701 -p0 -%patch702 -p0 -%patch703 -p0 -%patch704 -p0 -%patch705 -p0 -%patch706 -p0 -%patch707 -p0 -%patch708 -p0 -%patch709 -p0 -%patch710 -p0 -%patch711 -p0 -%patch712 -p0 # install spell files From 591a8c1546c59e258d14fc8a914867920041ba7a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 12 Nov 2012 16:43:21 +0100 Subject: [PATCH 0586/3340] Reset content to Fedora branch --- vim.spec | 39 +++++++++++++++++---------------------- 1 file changed, 17 insertions(+), 22 deletions(-) diff --git a/vim.spec b/vim.spec index 7d7be9f7..64189630 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 2%{?dist} +Release: 1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -797,6 +797,7 @@ Requires: desktop-file-utils BuildRequires: desktop-file-utils >= %{desktop_file_utils_version} %endif Epoch: 2 +Conflicts: filesystem < 3 %description VIM (VIsual editor iMproved) is an updated and improved version of the @@ -836,6 +837,7 @@ many different languages. Summary: A minimal version of the VIM editor Group: Applications/Editors Provides: vi = %{version}-%{release} +Provides: /bin/vi %description minimal VIM (VIsual editor iMproved) is an updated and improved version of the @@ -1731,7 +1733,6 @@ make VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} %{?_smp_mflags} %install rm -rf $RPM_BUILD_ROOT -mkdir -p $RPM_BUILD_ROOT/bin mkdir -p $RPM_BUILD_ROOT/%{_bindir} mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/{after,autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/after/{autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} @@ -1747,12 +1748,12 @@ rm -f README*.info cd src -make install DESTDIR=$RPM_BUILD_ROOT BINDIR=/bin VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} -make installgtutorbin DESTDIR=$RPM_BUILD_ROOT BINDIR=/bin VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} -mv $RPM_BUILD_ROOT/bin/xxd $RPM_BUILD_ROOT/%{_bindir}/xxd -mv $RPM_BUILD_ROOT/bin/gvimtutor $RPM_BUILD_ROOT/%{_bindir}/gvimtutor +make install DESTDIR=$RPM_BUILD_ROOT BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} +make installgtutorbin DESTDIR=$RPM_BUILD_ROOT BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} mkdir -p $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/{16x16,32x32,48x48,64x64}/apps -install -m755 gvim $RPM_BUILD_ROOT/%{_bindir}/gvim +install -m755 vim $RPM_BUILD_ROOT%{_bindir}/vi +install -m755 enhanced-vim $RPM_BUILD_ROOT%{_bindir}/vim +install -m755 gvim $RPM_BUILD_ROOT%{_bindir}/gvim install -p -m644 %{SOURCE7} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/16x16/apps/gvim.png install -p -m644 %{SOURCE8} \ @@ -1761,17 +1762,12 @@ install -p -m644 %{SOURCE9} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/48x48/apps/gvim.png install -p -m644 %{SOURCE10} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/64x64/apps/gvim.png -install -m755 enhanced-vim $RPM_BUILD_ROOT/%{_bindir}/vim ( cd $RPM_BUILD_ROOT - mv ./bin/vimtutor ./%{_bindir}/vimtutor - mv ./bin/vim ./bin/vi - rm -f ./bin/rvim - ln -sf vi ./bin/ex - ln -sf vi ./bin/rvi - ln -sf vi ./bin/rview - ln -sf vi ./bin/view - ln -sf vim ./%{_bindir}/ex + ln -sf vi ./%{_bindir}/rvi + ln -sf vi ./%{_bindir}/rview + ln -sf vi ./%{_bindir}/view + ln -sf vi ./%{_bindir}/ex ln -sf vim ./%{_bindir}/rvim ln -sf vim ./%{_bindir}/vimdiff perl -pi -e "s,$RPM_BUILD_ROOT,," .%{_mandir}/man1/vim.1 .%{_mandir}/man1/vimtutor.1 @@ -2038,18 +2034,17 @@ rm -rf $RPM_BUILD_ROOT %files minimal %defattr(-,root,root) %config(noreplace) %{_sysconfdir}/virc -/bin/ex -/bin/vi -/bin/view -/bin/rvi -/bin/rview +%{_bindir}/ex +%{_bindir}/vi +%{_bindir}/view +%{_bindir}/rvi +%{_bindir}/rview %files enhanced %defattr(-,root,root) %{_bindir}/vim %{_bindir}/rvim %{_bindir}/vimdiff -%{_bindir}/ex %{_bindir}/vimtutor %config(noreplace) %{_sysconfdir}/profile.d/vim.* %{_mandir}/man1/rvim.* From 9220d88a4efbb3db21ac2e480e39174bdbf32a78 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 13 Nov 2012 12:03:38 +0100 Subject: [PATCH 0587/3340] sync with F18 --- vim.spec | 39 ++++++++++++++++++++++----------------- 1 file changed, 22 insertions(+), 17 deletions(-) diff --git a/vim.spec b/vim.spec index 64189630..7d7be9f7 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1%{?dist} +Release: 2%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -797,7 +797,6 @@ Requires: desktop-file-utils BuildRequires: desktop-file-utils >= %{desktop_file_utils_version} %endif Epoch: 2 -Conflicts: filesystem < 3 %description VIM (VIsual editor iMproved) is an updated and improved version of the @@ -837,7 +836,6 @@ many different languages. Summary: A minimal version of the VIM editor Group: Applications/Editors Provides: vi = %{version}-%{release} -Provides: /bin/vi %description minimal VIM (VIsual editor iMproved) is an updated and improved version of the @@ -1733,6 +1731,7 @@ make VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} %{?_smp_mflags} %install rm -rf $RPM_BUILD_ROOT +mkdir -p $RPM_BUILD_ROOT/bin mkdir -p $RPM_BUILD_ROOT/%{_bindir} mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/{after,autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/after/{autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} @@ -1748,12 +1747,12 @@ rm -f README*.info cd src -make install DESTDIR=$RPM_BUILD_ROOT BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} -make installgtutorbin DESTDIR=$RPM_BUILD_ROOT BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} +make install DESTDIR=$RPM_BUILD_ROOT BINDIR=/bin VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} +make installgtutorbin DESTDIR=$RPM_BUILD_ROOT BINDIR=/bin VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} +mv $RPM_BUILD_ROOT/bin/xxd $RPM_BUILD_ROOT/%{_bindir}/xxd +mv $RPM_BUILD_ROOT/bin/gvimtutor $RPM_BUILD_ROOT/%{_bindir}/gvimtutor mkdir -p $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/{16x16,32x32,48x48,64x64}/apps -install -m755 vim $RPM_BUILD_ROOT%{_bindir}/vi -install -m755 enhanced-vim $RPM_BUILD_ROOT%{_bindir}/vim -install -m755 gvim $RPM_BUILD_ROOT%{_bindir}/gvim +install -m755 gvim $RPM_BUILD_ROOT/%{_bindir}/gvim install -p -m644 %{SOURCE7} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/16x16/apps/gvim.png install -p -m644 %{SOURCE8} \ @@ -1762,12 +1761,17 @@ install -p -m644 %{SOURCE9} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/48x48/apps/gvim.png install -p -m644 %{SOURCE10} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/64x64/apps/gvim.png +install -m755 enhanced-vim $RPM_BUILD_ROOT/%{_bindir}/vim ( cd $RPM_BUILD_ROOT - ln -sf vi ./%{_bindir}/rvi - ln -sf vi ./%{_bindir}/rview - ln -sf vi ./%{_bindir}/view - ln -sf vi ./%{_bindir}/ex + mv ./bin/vimtutor ./%{_bindir}/vimtutor + mv ./bin/vim ./bin/vi + rm -f ./bin/rvim + ln -sf vi ./bin/ex + ln -sf vi ./bin/rvi + ln -sf vi ./bin/rview + ln -sf vi ./bin/view + ln -sf vim ./%{_bindir}/ex ln -sf vim ./%{_bindir}/rvim ln -sf vim ./%{_bindir}/vimdiff perl -pi -e "s,$RPM_BUILD_ROOT,," .%{_mandir}/man1/vim.1 .%{_mandir}/man1/vimtutor.1 @@ -2034,17 +2038,18 @@ rm -rf $RPM_BUILD_ROOT %files minimal %defattr(-,root,root) %config(noreplace) %{_sysconfdir}/virc -%{_bindir}/ex -%{_bindir}/vi -%{_bindir}/view -%{_bindir}/rvi -%{_bindir}/rview +/bin/ex +/bin/vi +/bin/view +/bin/rvi +/bin/rview %files enhanced %defattr(-,root,root) %{_bindir}/vim %{_bindir}/rvim %{_bindir}/vimdiff +%{_bindir}/ex %{_bindir}/vimtutor %config(noreplace) %{_sysconfdir}/profile.d/vim.* %{_mandir}/man1/rvim.* From 44bbabe7f363af1f846e00f9d3296c9681e5d0db Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 13 Nov 2012 18:59:25 +0100 Subject: [PATCH 0588/3340] disable erroneous test83 --- vim-7.3-test83.patch | 12 ++++++++++++ vim.spec | 46 +++++++++++++++++++++++++------------------- 2 files changed, 38 insertions(+), 20 deletions(-) create mode 100644 vim-7.3-test83.patch diff --git a/vim-7.3-test83.patch b/vim-7.3-test83.patch new file mode 100644 index 00000000..0187ec4f --- /dev/null +++ b/vim-7.3-test83.patch @@ -0,0 +1,12 @@ +diff -up vim73/src/testdir/Makefile.test83 vim73/src/testdir/Makefile +--- vim73/src/testdir/Makefile.test83 2012-11-13 17:51:38.493046031 +0100 ++++ vim73/src/testdir/Makefile 2012-11-13 17:51:52.216052356 +0100 +@@ -26,7 +26,7 @@ SCRIPTS = test1.out test2.out test3.out + test64.out test65.out test66.out test67.out test68.out \ + test69.out test70.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ +- test79.out test80.out test81.out test82.out test83.out \ ++ test79.out test80.out test81.out test82.out \ + test84.out test85.out test86.out test87.out + + SCRIPTS_GUI = test16.out diff --git a/vim.spec b/vim.spec index 7d7be9f7..f736cedd 100644 --- a/vim.spec +++ b/vim.spec @@ -780,6 +780,7 @@ Patch3010: vim-7.0-specedit.patch Patch3011: vim72-rh514717.patch Patch3012: vim-7.3-bug816848.patch Patch3013: vim-7.3-manpage-typo-668894-675480.patch +Patch3014: vim-7.3-test83.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel ncurses-devel gettext perl-devel @@ -797,6 +798,7 @@ Requires: desktop-file-utils BuildRequires: desktop-file-utils >= %{desktop_file_utils_version} %endif Epoch: 2 +Conflicts: filesystem < 3 %description VIM (VIsual editor iMproved) is an updated and improved version of the @@ -836,6 +838,7 @@ many different languages. Summary: A minimal version of the VIM editor Group: Applications/Editors Provides: vi = %{version}-%{release} +Provides: /bin/vi %description minimal VIM (VIsual editor iMproved) is an updated and improved version of the @@ -1642,6 +1645,7 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch3011 -p1 %patch3012 -p1 %patch3013 -p1 +%patch3014 -p1 %build cp -f %{SOURCE5} . @@ -1730,8 +1734,6 @@ perl -pi -e "s/\/etc\/vimrc/\/etc\/virc/" os_unix.h make VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} %{?_smp_mflags} %install -rm -rf $RPM_BUILD_ROOT -mkdir -p $RPM_BUILD_ROOT/bin mkdir -p $RPM_BUILD_ROOT/%{_bindir} mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/{after,autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/after/{autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} @@ -1747,11 +1749,13 @@ rm -f README*.info cd src -make install DESTDIR=$RPM_BUILD_ROOT BINDIR=/bin VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} -make installgtutorbin DESTDIR=$RPM_BUILD_ROOT BINDIR=/bin VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} -mv $RPM_BUILD_ROOT/bin/xxd $RPM_BUILD_ROOT/%{_bindir}/xxd -mv $RPM_BUILD_ROOT/bin/gvimtutor $RPM_BUILD_ROOT/%{_bindir}/gvimtutor +make install DESTDIR=$RPM_BUILD_ROOT BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} +make installgtutorbin DESTDIR=$RPM_BUILD_ROOT BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} +#mv $RPM_BUILD_ROOT/bin/xxd $RPM_BUILD_ROOT/%{_bindir}/xxd +#mv $RPM_BUILD_ROOT/bin/gvimtutor $RPM_BUILD_ROOT/%{_bindir}/gvimtutor mkdir -p $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/{16x16,32x32,48x48,64x64}/apps +install -m755 vim $RPM_BUILD_ROOT%{_bindir}/vi +install -m755 enhanced-vim $RPM_BUILD_ROOT%{_bindir}/vim install -m755 gvim $RPM_BUILD_ROOT/%{_bindir}/gvim install -p -m644 %{SOURCE7} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/16x16/apps/gvim.png @@ -1764,14 +1768,10 @@ install -p -m644 %{SOURCE10} \ install -m755 enhanced-vim $RPM_BUILD_ROOT/%{_bindir}/vim ( cd $RPM_BUILD_ROOT - mv ./bin/vimtutor ./%{_bindir}/vimtutor - mv ./bin/vim ./bin/vi - rm -f ./bin/rvim - ln -sf vi ./bin/ex - ln -sf vi ./bin/rvi - ln -sf vi ./bin/rview - ln -sf vi ./bin/view - ln -sf vim ./%{_bindir}/ex + ln -sf vi .%{_bindir}/ex + ln -sf vi .%{_bindir}/rvi + ln -sf vi .%{_bindir}/rview + ln -sf vi .%{_bindir}/view ln -sf vim ./%{_bindir}/rvim ln -sf vim ./%{_bindir}/vimdiff perl -pi -e "s,$RPM_BUILD_ROOT,," .%{_mandir}/man1/vim.1 .%{_mandir}/man1/vimtutor.1 @@ -1847,6 +1847,10 @@ endif EOF chmod 0644 $RPM_BUILD_ROOT/%{_sysconfdir}/profile.d/* install -p -m644 %{SOURCE4} $RPM_BUILD_ROOT/%{_sysconfdir}/vimrc +%if %{?rhel}%{!?rhel:0} >= 6 +perl -pi -e "s,augroup fedora,augroup redhat,g" $RPM_BUILD_ROOT/%{_sysconfdir}/vimrc +%endif + install -p -m644 %{SOURCE4} $RPM_BUILD_ROOT/%{_sysconfdir}/virc (cd $RPM_BUILD_ROOT/%{_datadir}/%{name}/%{vimdir}/doc; gzip -9 *.txt @@ -2038,18 +2042,17 @@ rm -rf $RPM_BUILD_ROOT %files minimal %defattr(-,root,root) %config(noreplace) %{_sysconfdir}/virc -/bin/ex -/bin/vi -/bin/view -/bin/rvi -/bin/rview +%{_bindir}/ex +%{_bindir}/vi +%{_bindir}/view +%{_bindir}/rvi +%{_bindir}/rview %files enhanced %defattr(-,root,root) %{_bindir}/vim %{_bindir}/rvim %{_bindir}/vimdiff -%{_bindir}/ex %{_bindir}/vimtutor %config(noreplace) %{_sysconfdir}/profile.d/vim.* %{_mandir}/man1/rvim.* @@ -2096,6 +2099,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Tue Nov 13 2012 Karsten Hopp 7.3.712-2 +- disable erroneous test83 + * Mon Nov 12 2012 Karsten Hopp 7.3.712-1 - patchlevel 712 From 181a3ebe98ae0bbd51acfde7ce191920c81e10d7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 13 Nov 2012 19:00:31 +0100 Subject: [PATCH 0589/3340] bump release --- vim.spec | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/vim.spec b/vim.spec index f736cedd..b01dc180 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 2%{?dist} +Release: 3%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -2099,7 +2099,8 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog -* Tue Nov 13 2012 Karsten Hopp 7.3.712-2 +* Tue Nov 13 2012 7.3.%{nil}712-3 +* Tue Nov 13 2012 Karsten Hopp 7.3.712-3 - disable erroneous test83 * Mon Nov 12 2012 Karsten Hopp 7.3.712-1 From 88ac8848145af3946f865f339f1c181758b91c1b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 20 Nov 2012 17:31:16 +0100 Subject: [PATCH 0590/3340] - patchlevel 713 --- 7.3.713 | 114 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 114 insertions(+) create mode 100644 7.3.713 diff --git a/7.3.713 b/7.3.713 new file mode 100644 index 00000000..e195bf73 --- /dev/null +++ b/7.3.713 @@ -0,0 +1,114 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.713 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.713 +Problem: printf() can only align to bytes, not characters. +Solution: Add the "S" item. (Christian Brabandt) +Files: runtime/doc/eval.txt, src/message.c + + +*** ../vim-7.3.712/runtime/doc/eval.txt 2012-10-21 00:44:59.000000000 +0200 +--- runtime/doc/eval.txt 2012-11-14 18:00:40.000000000 +0100 +*************** +*** 4427,4432 **** +--- 4451,4457 ---- + + Often used items are: + %s string ++ %6S string right-aligned in 6 display cells + %6s string right-aligned in 6 bytes + %.9s string truncated to 9 bytes + %c single byte +*************** +*** 4541,4546 **** +--- 4566,4575 ---- + s The text of the String argument is used. If a + precision is specified, no more bytes than the number + specified are used. ++ S The text of the String argument is used. If a ++ precision is specified, no more display cells than the ++ number specified are used. Without the |+multi_byte| ++ feature works just like 's'. + + *printf-f* *E807* + f The Float argument is converted into a string of the +*** ../vim-7.3.712/src/message.c 2012-03-28 16:49:25.000000000 +0200 +--- src/message.c 2012-11-14 17:58:25.000000000 +0100 +*************** +*** 4290,4295 **** +--- 4290,4296 ---- + case '%': + case 'c': + case 's': ++ case 'S': + length_modifier = '\0'; + str_arg_l = 1; + switch (fmt_spec) +*************** +*** 4318,4323 **** +--- 4319,4325 ---- + } + + case 's': ++ case 'S': + str_arg = + #ifndef HAVE_STDARG_H + (char *)get_a_arg(arg_idx); +*************** +*** 4354,4359 **** +--- 4356,4379 ---- + str_arg_l = (q == NULL) ? precision + : (size_t)(q - str_arg); + } ++ #ifdef FEAT_MBYTE ++ if (fmt_spec == 'S') ++ { ++ if (min_field_width != 0) ++ min_field_width += STRLEN(str_arg) ++ - mb_string2cells((char_u *)str_arg, -1); ++ if (precision) ++ { ++ char_u *p1 = (char_u *)str_arg; ++ size_t i; ++ ++ for (i = 0; i < precision && *p1; i++) ++ p1 += mb_ptr2len(p1); ++ ++ str_arg_l = precision = p1 - (char_u *)str_arg; ++ } ++ } ++ #endif + break; + + default: +*** ../vim-7.3.712/src/version.c 2012-10-23 05:35:30.000000000 +0200 +--- src/version.c 2012-11-14 17:54:12.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 713, + /**/ + +-- +In many of the more relaxed civilizations on the Outer Eastern Rim of the +Galaxy, "The Hitchhiker's Guide to the Galaxy" has already supplanted the +great "Encyclopedia Galactica" as the standard repository of all knowledge +and wisdom, for though it has many omissions and contains much that is +apocryphal, or at least wildly inaccurate, it scores over the older, more +pedestrian work in two important respects. +First, it is slightly cheaper; and second, it has the words "DON'T PANIC" +inscribed in large friendly letters on its cover. + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From febd3051312dc2ad7cc436078272da1137b5ebbb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 20 Nov 2012 17:31:17 +0100 Subject: [PATCH 0591/3340] - patchlevel 714 --- 7.3.714 | 62 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 7.3.714 diff --git a/7.3.714 b/7.3.714 new file mode 100644 index 00000000..97cafb06 --- /dev/null +++ b/7.3.714 @@ -0,0 +1,62 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.714 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.714 +Problem: Inconsistency: :set can be used in the sandbox, but :setlocal and + :setglobal cannot. (Michael Henry) +Solution: Fix the flags for :setlocal and :setglobal. (Christian Brabandt) +Files: src/ex_cmds.h + + +*** ../vim-7.3.713/src/ex_cmds.h 2012-08-08 17:31:36.000000000 +0200 +--- src/ex_cmds.h 2012-11-14 20:41:28.000000000 +0100 +*************** +*** 832,840 **** + EX(CMD_setfiletype, "setfiletype", ex_setfiletype, + TRLBAR|EXTRA|NEEDARG|CMDWIN), + EX(CMD_setglobal, "setglobal", ex_set, +! TRLBAR|EXTRA|CMDWIN), + EX(CMD_setlocal, "setlocal", ex_set, +! TRLBAR|EXTRA|CMDWIN), + EX(CMD_sfind, "sfind", ex_splitview, + BANG|FILE1|RANGE|NOTADR|EDITCMD|ARGOPT|TRLBAR), + EX(CMD_sfirst, "sfirst", ex_rewind, +--- 832,840 ---- + EX(CMD_setfiletype, "setfiletype", ex_setfiletype, + TRLBAR|EXTRA|NEEDARG|CMDWIN), + EX(CMD_setglobal, "setglobal", ex_set, +! TRLBAR|EXTRA|CMDWIN|SBOXOK), + EX(CMD_setlocal, "setlocal", ex_set, +! TRLBAR|EXTRA|CMDWIN|SBOXOK), + EX(CMD_sfind, "sfind", ex_splitview, + BANG|FILE1|RANGE|NOTADR|EDITCMD|ARGOPT|TRLBAR), + EX(CMD_sfirst, "sfirst", ex_rewind, +*** ../vim-7.3.713/src/version.c 2012-11-14 18:10:49.000000000 +0100 +--- src/version.c 2012-11-14 20:43:01.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 714, + /**/ + +-- +"So this is it," said Arthur, "we are going to die." +"Yes," said Ford, "except...no! Wait a minute!" He suddenly lunged across +the chamber at something behind Arthur's line of vision. "What's this +switch?" he cried. +"What? Where?" cried Arthur, twisting around. +"No, I was only fooling," said Ford, "we are going to die after all." + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8eff73a0c2663448d0f148936484a762f807b229 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 20 Nov 2012 17:31:18 +0100 Subject: [PATCH 0592/3340] - patchlevel 715 --- 7.3.715 | 234 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 234 insertions(+) create mode 100644 7.3.715 diff --git a/7.3.715 b/7.3.715 new file mode 100644 index 00000000..0542c431 --- /dev/null +++ b/7.3.715 @@ -0,0 +1,234 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.715 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.715 +Problem: Crash when calling setloclist() in BufUnload autocmd. (Marcin + Szamotulski) +Solution: Set w_llist to NULL when it was freed. Also add a test. + (Christian Brabandt) +Files: src/quickfix.c, src/testdir/test49.ok, src/testdir/test49.vim + + +*** ../vim-7.3.714/src/quickfix.c 2012-06-29 12:57:03.000000000 +0200 +--- src/quickfix.c 2012-11-14 22:33:20.000000000 +0100 +*************** +*** 107,113 **** + }; + + static int qf_init_ext __ARGS((qf_info_T *qi, char_u *efile, buf_T *buf, typval_T *tv, char_u *errorformat, int newlist, linenr_T lnumfirst, linenr_T lnumlast, char_u *qf_title)); +! static void qf_new_list __ARGS((qf_info_T *qi, char_u *qf_title)); + static void ll_free_all __ARGS((qf_info_T **pqi)); + static int qf_add_entry __ARGS((qf_info_T *qi, qfline_T **prevp, char_u *dir, char_u *fname, int bufnum, char_u *mesg, long lnum, int col, int vis_col, char_u *pattern, int nr, int type, int valid)); + static qf_info_T *ll_new_list __ARGS((void)); +--- 107,113 ---- + }; + + static int qf_init_ext __ARGS((qf_info_T *qi, char_u *efile, buf_T *buf, typval_T *tv, char_u *errorformat, int newlist, linenr_T lnumfirst, linenr_T lnumlast, char_u *qf_title)); +! static void qf_new_list __ARGS((qf_info_T *qi, char_u *qf_title, win_T *wp)); + static void ll_free_all __ARGS((qf_info_T **pqi)); + static int qf_add_entry __ARGS((qf_info_T *qi, qfline_T **prevp, char_u *dir, char_u *fname, int bufnum, char_u *mesg, long lnum, int col, int vis_col, char_u *pattern, int nr, int type, int valid)); + static qf_info_T *ll_new_list __ARGS((void)); +*************** +*** 266,272 **** + + if (newlist || qi->qf_curlist == qi->qf_listcount) + /* make place for a new list */ +! qf_new_list(qi, qf_title); + else if (qi->qf_lists[qi->qf_curlist].qf_count > 0) + /* Adding to existing list, find last entry. */ + for (qfprev = qi->qf_lists[qi->qf_curlist].qf_start; +--- 266,272 ---- + + if (newlist || qi->qf_curlist == qi->qf_listcount) + /* make place for a new list */ +! qf_new_list(qi, qf_title, curwin); + else if (qi->qf_lists[qi->qf_curlist].qf_count > 0) + /* Adding to existing list, find last entry. */ + for (qfprev = qi->qf_lists[qi->qf_curlist].qf_start; +*************** +*** 885,893 **** + * Prepare for adding a new quickfix list. + */ + static void +! qf_new_list(qi, qf_title) + qf_info_T *qi; + char_u *qf_title; + { + int i; + +--- 885,894 ---- + * Prepare for adding a new quickfix list. + */ + static void +! qf_new_list(qi, qf_title, wp) + qf_info_T *qi; + char_u *qf_title; ++ win_T *wp; + { + int i; + +*************** +*** 897,903 **** +--- 898,908 ---- + * way with ":grep'. + */ + while (qi->qf_listcount > qi->qf_curlist + 1) ++ { ++ if (wp != NULL && wp->w_llist == qi) ++ wp->w_llist = NULL; + qf_free(qi, --qi->qf_listcount); ++ } + + /* + * When the stack is full, remove to oldest entry +*************** +*** 905,910 **** +--- 910,917 ---- + */ + if (qi->qf_listcount == LISTCOUNT) + { ++ if (wp != NULL && wp->w_llist == qi) ++ wp->w_llist = NULL; + qf_free(qi, 0); + for (i = 1; i < LISTCOUNT; ++i) + qi->qf_lists[i - 1] = qi->qf_lists[i]; +*************** +*** 3181,3187 **** + eap->cmdidx != CMD_vimgrepadd && eap->cmdidx != CMD_lvimgrepadd) + || qi->qf_curlist == qi->qf_listcount) + /* make place for a new list */ +! qf_new_list(qi, *eap->cmdlinep); + else if (qi->qf_lists[qi->qf_curlist].qf_count > 0) + /* Adding to existing list, find last entry. */ + for (prevp = qi->qf_lists[qi->qf_curlist].qf_start; +--- 3188,3194 ---- + eap->cmdidx != CMD_vimgrepadd && eap->cmdidx != CMD_lvimgrepadd) + || qi->qf_curlist == qi->qf_listcount) + /* make place for a new list */ +! qf_new_list(qi, *eap->cmdlinep, curwin); + else if (qi->qf_lists[qi->qf_curlist].qf_count > 0) + /* Adding to existing list, find last entry. */ + for (prevp = qi->qf_lists[qi->qf_curlist].qf_start; +*************** +*** 3747,3753 **** + + if (action == ' ' || qi->qf_curlist == qi->qf_listcount) + /* make place for a new list */ +! qf_new_list(qi, title); + else if (action == 'a' && qi->qf_lists[qi->qf_curlist].qf_count > 0) + /* Adding to existing list, find last entry. */ + for (prevp = qi->qf_lists[qi->qf_curlist].qf_start; +--- 3754,3760 ---- + + if (action == ' ' || qi->qf_curlist == qi->qf_listcount) + /* make place for a new list */ +! qf_new_list(qi, title, wp); + else if (action == 'a' && qi->qf_lists[qi->qf_curlist].qf_count > 0) + /* Adding to existing list, find last entry. */ + for (prevp = qi->qf_lists[qi->qf_curlist].qf_start; +*************** +*** 4029,4035 **** + #endif + + /* create a new quickfix list */ +! qf_new_list(qi, *eap->cmdlinep); + + /* Go through all directories in 'runtimepath' */ + p = p_rtp; +--- 4036,4042 ---- + #endif + + /* create a new quickfix list */ +! qf_new_list(qi, *eap->cmdlinep, wp); + + /* Go through all directories in 'runtimepath' */ + p = p_rtp; +*** ../vim-7.3.714/src/testdir/test49.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test49.ok 2012-11-14 22:26:13.000000000 +0100 +*************** +*** 85,92 **** + *** Test 83: OK (2835) + *** Test 84: OK (934782101) + *** Test 85: OK (198689) +! --- Test 86: All tests were run with throwing exceptions on error. + The $VIMNOERRTHROW control is not configured. +! --- Test 86: All tests were run with throwing exceptions on interrupt. + The $VIMNOINTTHROW control is not configured. +! *** Test 86: OK (50443995) +--- 85,94 ---- + *** Test 83: OK (2835) + *** Test 84: OK (934782101) + *** Test 85: OK (198689) +! --- Test 86: No Crash for vimgrep on BufUnload +! *** Test 86: OK (0) +! --- Test 87: All tests were run with throwing exceptions on error. + The $VIMNOERRTHROW control is not configured. +! --- Test 87: All tests were run with throwing exceptions on interrupt. + The $VIMNOINTTHROW control is not configured. +! *** Test 87: OK (50443995) +*** ../vim-7.3.714/src/testdir/test49.vim 2010-09-29 16:55:45.000000000 +0200 +--- src/testdir/test49.vim 2012-11-14 22:26:13.000000000 +0100 +*************** +*** 9603,9611 **** + + Xcheck 198689 + + + "------------------------------------------------------------------------------- +! " Test 86: $VIMNOERRTHROW and $VIMNOINTTHROW support {{{1 + " + " It is possible to configure Vim for throwing exceptions on error + " or interrupt, controlled by variables $VIMNOERRTHROW and +--- 9603,9630 ---- + + Xcheck 198689 + ++ "------------------------------------------------------------------------------- ++ " Test 86 setloclist crash {{{1 ++ " ++ " Executing a setloclist() on BufUnload shouldn't crash Vim ++ "------------------------------------------------------------------------------- ++ ++ func F ++ au BufUnload * :call setloclist(0, [{'bufnr':1, 'lnum':1, 'col':1, 'text': 'tango down'}]) ++ ++ :lvimgrep /.*/ * ++ endfunc ++ ++ XpathINIT ++ ++ ExecAsScript F ++ ++ delfunction F ++ Xout "No Crash for vimgrep on BufUnload" ++ Xcheck 0 + + "------------------------------------------------------------------------------- +! " Test 87: $VIMNOERRTHROW and $VIMNOINTTHROW support {{{1 + " + " It is possible to configure Vim for throwing exceptions on error + " or interrupt, controlled by variables $VIMNOERRTHROW and +*** ../vim-7.3.714/src/version.c 2012-11-14 20:52:22.000000000 +0100 +--- src/version.c 2012-11-14 22:36:45.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 715, + /**/ + +-- +One difference between a man and a machine is that a machine is quiet +when well oiled. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f977c88cb1679286f726d64774638eee6f7270a3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 20 Nov 2012 17:31:20 +0100 Subject: [PATCH 0593/3340] - patchlevel 715 --- README.patches | 3 +++ vim.spec | 11 ++++++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index c407164b..4ba7007c 100644 --- a/README.patches +++ b/README.patches @@ -743,3 +743,6 @@ Individual patches for Vim 7.3: 1685 7.3.710 (after 7.3.704) "fn" is broken 7579 7.3.711 (after 7.3.688) vim.current.buffer is not available 1474 7.3.712 nmake from VS2010 SP1 is not recognized + 3513 7.3.713 printf() can only align to bytes, not characters + 2296 7.3.714 :setlocal and :setglobal do not work in the sandbox + 8244 7.3.715 crash when calling setloclist() in BufUnload autocmd diff --git a/vim.spec b/vim.spec index 80801bb1..dc21e213 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 712 +%define patchlevel 715 Summary: The VIM editor URL: http://www.vim.org/ @@ -768,6 +768,9 @@ Patch709: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.709 Patch710: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.710 Patch711: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.711 Patch712: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.712 +Patch713: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.713 +Patch714: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.714 +Patch715: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.715 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1626,6 +1629,9 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch710 -p0 %patch711 -p0 %patch712 -p0 +%patch713 -p0 +%patch714 -p0 +%patch715 -p0 # install spell files @@ -2088,6 +2094,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Tue Nov 20 2012 Karsten Hopp 7.3.715-1 +- patchlevel 715 + * Tue Oct 23 2012 Karsten Hopp 7.3.712-1 - patchlevel 712 From 5fda7d71dc8eb1784342fb9a4e1fa9bce8f8cc9f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:39 +0100 Subject: [PATCH 0594/3340] - patchlevel 716 --- 7.3.716 | 70 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 7.3.716 diff --git a/7.3.716 b/7.3.716 new file mode 100644 index 00000000..90f90d53 --- /dev/null +++ b/7.3.716 @@ -0,0 +1,70 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.716 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.716 +Problem: Error on exit when using Python 3. +Solution: Remove PythonIO_Fini(). (Roland Puntaier) +Files: src/if_python3.c + + +*** ../vim-7.3.715/src/if_python3.c 2012-10-23 05:17:33.000000000 +0200 +--- src/if_python3.c 2012-11-20 10:59:54.000000000 +0100 +*************** +*** 657,663 **** + static PyObject *globals; + + static int PythonIO_Init(void); +- static void PythonIO_Fini(void); + PyMODINIT_FUNC Py3Init_vim(void); + + /****************************************************** +--- 657,662 ---- +*************** +*** 685,691 **** + // acquire lock before finalizing + pygilstate = PyGILState_Ensure(); + +- PythonIO_Fini(); + Py_Finalize(); + } + +--- 684,689 ---- +*************** +*** 989,1001 **** + return PythonIO_Init_io(); + } + +- static void +- PythonIO_Fini(void) +- { +- PySys_SetObject("stdout", NULL); +- PySys_SetObject("stderr", NULL); +- } +- + /****************************************************** + * 3. Implementation of the Vim module for Python + */ +--- 987,992 ---- +*** ../vim-7.3.715/src/version.c 2012-11-14 22:38:04.000000000 +0100 +--- src/version.c 2012-11-15 21:40:47.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 716, + /**/ + +-- +Nothing is fool-proof to a sufficiently talented fool. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3566ab741195352abe5f6a09ff5a46e8a5decc6b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:41 +0100 Subject: [PATCH 0595/3340] - patchlevel 717 --- 7.3.717 | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.717 diff --git a/7.3.717 b/7.3.717 new file mode 100644 index 00000000..02751c6c --- /dev/null +++ b/7.3.717 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.717 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.717 +Problem: When changing the font size, only MS-Windows limits the window + size. +Solution: Also limit the window size on other systems. (Roland Puntaier) +Files: src/gui.c + + +*** ../vim-7.3.716/src/gui.c 2012-08-29 16:34:23.000000000 +0200 +--- src/gui.c 2012-11-20 12:01:08.000000000 +0100 +*************** +*** 905,917 **** + # endif + gui_mch_set_font(gui.norm_font); + #endif +! gui_set_shellsize(FALSE, +! #ifdef MSWIN +! TRUE +! #else +! FALSE +! #endif +! , RESIZE_BOTH); + } + + return ret; +--- 905,911 ---- + # endif + gui_mch_set_font(gui.norm_font); + #endif +! gui_set_shellsize(FALSE, TRUE, RESIZE_BOTH); + } + + return ret; +*** ../vim-7.3.716/src/version.c 2012-11-20 11:02:49.000000000 +0100 +--- src/version.c 2012-11-20 12:02:04.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 717, + /**/ + +-- +The 50-50-90 rule: Anytime you have a 50-50 chance of getting +something right, there's a 90% probability you'll get it wrong. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 954b0f096656076fe7ba6b323ae78abbebb0dab3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:42 +0100 Subject: [PATCH 0596/3340] - patchlevel 718 --- 7.3.718 | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 7.3.718 diff --git a/7.3.718 b/7.3.718 new file mode 100644 index 00000000..f8f82f4b --- /dev/null +++ b/7.3.718 @@ -0,0 +1,49 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.718 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.718 +Problem: When re-using the current buffer the buffer-local options stay. +Solution: Re-initialize the buffer-local options. (Christian Brabandt) +Files: src/buffer.c + + +*** ../vim-7.3.717/src/buffer.c 2012-10-03 18:24:55.000000000 +0200 +--- src/buffer.c 2012-11-17 14:11:35.000000000 +0100 +*************** +*** 1702,1707 **** +--- 1702,1712 ---- + #endif + /* buf->b_nwindows = 0; why was this here? */ + free_buffer_stuff(buf, FALSE); /* delete local variables et al. */ ++ ++ /* Init the options. */ ++ buf->b_p_initialized = FALSE; ++ buf_copy_options(buf, BCO_ENTER); ++ + #ifdef FEAT_KEYMAP + /* need to reload lmaps and set b:keymap_name */ + curbuf->b_kmap_state |= KEYMAP_INIT; +*** ../vim-7.3.717/src/version.c 2012-11-20 12:03:02.000000000 +0100 +--- src/version.c 2012-11-20 12:16:35.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 718, + /**/ + +-- +Latest survey shows that 3 out of 4 people make up 75% of the +world's population. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 67b9f0c173f3425a668f2be6a66eaa3f82e0b428 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:43 +0100 Subject: [PATCH 0597/3340] - patchlevel 719 --- 7.3.719 | 849 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 849 insertions(+) create mode 100644 7.3.719 diff --git a/7.3.719 b/7.3.719 new file mode 100644 index 00000000..05295f9c --- /dev/null +++ b/7.3.719 @@ -0,0 +1,849 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.719 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.719 +Problem: Cannot run new version of cproto, it fails on missing include + files. +Solution: Add lots of #ifndef PROTO +Files: src/os_amiga.c, src/os_amiga.h, src/gui_w16.c, src/gui_w48.c, + src/gui_w32.c, src/vimio.h, src/os_msdos.c, src/os_msdos.h, + src/os_win16.h, src/os_win16.c, src/os_win32.h, src/os_win32.c, + src/os_mswin.c, src/gui_photon.c, src/os_unix.h, src/os_beos.c, + src/os_beos.h + + +*** ../vim-7.3.718/src/os_amiga.c 2012-06-29 15:51:26.000000000 +0200 +--- src/os_amiga.c 2012-11-20 15:47:31.000000000 +0100 +*************** +*** 22,27 **** +--- 22,30 ---- + #undef TRUE /* will be redefined by exec/types.h */ + #undef FALSE + ++ /* cproto fails on missing include files, skip them */ ++ #ifndef PROTO ++ + #ifndef LATTICE + # include + # include +*************** +*** 55,60 **** +--- 58,65 ---- + # include + #endif + ++ #endif /* PROTO */ ++ + /* + * At this point TRUE and FALSE are defined as 1L and 0L, but we want 1 and 0. + */ +*************** +*** 283,289 **** + #endif + } + +! #include + + /* + * Check_win checks whether we have an interactive window. +--- 288,296 ---- + #endif + } + +! #ifndef PROTO +! # include +! #endif + + /* + * Check_win checks whether we have an interactive window. +*************** +*** 1002,1008 **** + * Heavely modified by mool. + */ + +! #include + + /* + * try to get the real window size +--- 1009,1017 ---- + * Heavely modified by mool. + */ + +! #ifndef PROTO +! # include +! #endif + + /* + * try to get the real window size +*************** +*** 1129,1137 **** + * say 'oml lib:amiga.lib -r sendpacket.o' + */ + + /* #include */ + /* #include */ +! #include + + /* + * Function - dos_packet written by Phil Lindsay, Carolyn Scheppner, and Andy +--- 1138,1148 ---- + * say 'oml lib:amiga.lib -r sendpacket.o' + */ + ++ #ifndef PROTO + /* #include */ + /* #include */ +! # include +! #endif + + /* + * Function - dos_packet written by Phil Lindsay, Carolyn Scheppner, and Andy +*** ../vim-7.3.718/src/os_amiga.h 2010-08-15 21:57:25.000000000 +0200 +--- src/os_amiga.h 2012-11-20 15:46:37.000000000 +0100 +*************** +*** 56,61 **** +--- 56,64 ---- + # define TEMPNAMELEN 12 + #endif + ++ /* cproto fails on missing include files */ ++ #ifndef PROTO ++ + #include + #include + #include +*************** +*** 67,72 **** +--- 70,77 ---- + # include + #endif + ++ #endif /* PROTO */ ++ + #define FNAME_ILLEGAL ";*?`#%" /* illegal characters in a file name */ + + /* +*************** +*** 85,90 **** +--- 90,96 ---- + # include + #endif + ++ #ifndef PROTO + /* + * arpbase.h must be included before functions.h + */ +*************** +*** 92,97 **** +--- 98,105 ---- + # include + #endif + ++ #endif /* PROTO */ ++ + /* + * This won't be needed if you have a version of Lattice 4.01 without broken + * break signal handling. +*** ../vim-7.3.718/src/gui_w16.c 2012-02-04 22:01:44.000000000 +0100 +--- src/gui_w16.c 2012-11-20 15:55:04.000000000 +0100 +*************** +*** 1521,1527 **** + + + #if defined(FEAT_TOOLBAR) || defined(PROTO) +! #include "gui_w3~1.h" + /* + * Create the toolbar, initially unpopulated. + * (just like the menu, there are no defaults, it's all +--- 1521,1532 ---- + + + #if defined(FEAT_TOOLBAR) || defined(PROTO) +! +! /* cproto fails on missing include files */ +! #ifndef PROTO +! # include "gui_w3~1.h" +! #endif +! + /* + * Create the toolbar, initially unpopulated. + * (just like the menu, there are no defaults, it's all +*** ../vim-7.3.718/src/gui_w48.c 2012-01-20 20:54:15.000000000 +0100 +--- src/gui_w48.c 2012-11-20 15:53:49.000000000 +0100 +*************** +*** 25,30 **** +--- 25,34 ---- + #ifdef DEBUG + # include + #endif ++ ++ /* cproto fails on missing include files */ ++ #ifndef PROTO ++ + #ifndef __MINGW32__ + # include + #endif +*************** +*** 44,49 **** +--- 48,55 ---- + # include "glbl_ime.h" + #endif + ++ #endif /* PROTO */ ++ + #ifdef FEAT_MENU + # define MENUHINTS /* show menu hints in command line */ + #endif +*** ../vim-7.3.718/src/gui_w32.c 2012-01-04 20:29:18.000000000 +0100 +--- src/gui_w32.c 2012-11-20 15:56:31.000000000 +0100 +*************** +*** 198,208 **** + static UINT_PTR BevalTimerId = 0; + static DWORD LastActivity = 0; + + /* + * excerpts from headers since this may not be presented + * in the extremely old compilers + */ +! #include + + typedef struct _DllVersionInfo + { +--- 198,214 ---- + static UINT_PTR BevalTimerId = 0; + static DWORD LastActivity = 0; + ++ ++ /* cproto fails on missing include files */ ++ #ifndef PROTO ++ + /* + * excerpts from headers since this may not be presented + * in the extremely old compilers + */ +! # include +! +! #endif + + typedef struct _DllVersionInfo + { +*************** +*** 213,219 **** + DWORD dwPlatformID; + } DLLVERSIONINFO; + +! #include + + typedef struct tagTOOLINFOA_NEW + { +--- 219,227 ---- + DWORD dwPlatformID; + } DLLVERSIONINFO; + +! #ifndef PROTO +! # include +! #endif + + typedef struct tagTOOLINFOA_NEW + { +*** ../vim-7.3.718/src/vimio.h 2010-08-15 21:57:28.000000000 +0200 +--- src/vimio.h 2012-11-20 15:57:19.000000000 +0100 +*************** +*** 13,16 **** + # define _CRT_NONSTDC_NO_DEPRECATE + #endif + +! #include +--- 13,19 ---- + # define _CRT_NONSTDC_NO_DEPRECATE + #endif + +! /* cproto fails on missing include files */ +! #ifndef PROTO +! # include +! #endif +*** ../vim-7.3.718/src/os_msdos.c 2012-06-29 15:51:26.000000000 +0200 +--- src/os_msdos.c 2012-11-20 15:59:18.000000000 +0100 +*************** +*** 23,29 **** + + #include "vim.h" + +! #include + + /* + * MS-DOS only code, not used for Win16. +--- 23,32 ---- + + #include "vim.h" + +! /* cproto fails on missing include files */ +! #ifndef PROTO +! # include +! #endif + + /* + * MS-DOS only code, not used for Win16. +*************** +*** 31,47 **** + #ifndef WIN16 + + +! #include +! #ifdef DJGPP +! # include +! # include +! # include +! # include +! # ifdef FEAT_CLIPBOARD +! # include + # endif +- #else +- # include + #endif + + #if defined(DJGPP) || defined(PROTO) +--- 34,52 ---- + #ifndef WIN16 + + +! #ifndef PROTO +! # include +! # ifdef DJGPP +! # include +! # include +! # include +! # include +! # ifdef FEAT_CLIPBOARD +! # include +! # endif +! # else +! # include + # endif + #endif + + #if defined(DJGPP) || defined(PROTO) +*************** +*** 2130,2137 **** + + #undef setlocale + +! #include +! #include + #include + + #define UPCASE (__dj_ISALNUM | __dj_ISALPHA | __dj_ISGRAPH | __dj_ISPRINT | __dj_ISUPPER) +--- 2135,2144 ---- + + #undef setlocale + +! #ifndef PROTO +! # include +! # include +! #endif + #include + + #define UPCASE (__dj_ISALNUM | __dj_ISALPHA | __dj_ISGRAPH | __dj_ISPRINT | __dj_ISUPPER) +*** ../vim-7.3.718/src/os_msdos.h 2010-08-15 21:57:25.000000000 +0200 +--- src/os_msdos.h 2012-11-20 15:57:48.000000000 +0100 +*************** +*** 53,61 **** + + #define FNAME_ILLEGAL "\"*?><|" /* illegal characters in a file name */ + +! #include +! #include +! #include + + #ifdef DJGPP + # include +--- 53,64 ---- + + #define FNAME_ILLEGAL "\"*?><|" /* illegal characters in a file name */ + +! /* cproto fails on missing include files */ +! #ifndef PROTO +! # include +! # include +! # include +! #endif + + #ifdef DJGPP + # include +*** ../vim-7.3.718/src/os_win16.h 2010-08-15 21:57:25.000000000 +0200 +--- src/os_win16.h 2012-11-20 16:00:33.000000000 +0100 +*************** +*** 63,78 **** + + #include + #include +- #include +- #include + +! #ifndef STRICT +! # define STRICT +! #endif +! #ifndef COBJMACROS +! # define COBJMACROS /* For OLE: Enable "friendlier" access to objects */ +! #endif +! #include + + /* + * plenty of memory, use large buffers +--- 63,83 ---- + + #include + #include + +! /* cproto fails on missing include files */ +! #ifndef PROTO +! # include +! # include +! +! # ifndef STRICT +! # define STRICT +! # endif +! # ifndef COBJMACROS +! # define COBJMACROS /* For OLE: Enable "friendlier" access to objects */ +! # endif +! # include +! +! #endif /* PROTO */ + + /* + * plenty of memory, use large buffers +*** ../vim-7.3.718/src/os_win16.c 2012-06-29 15:51:26.000000000 +0200 +--- src/os_win16.c 2012-11-20 16:01:50.000000000 +0100 +*************** +*** 22,37 **** + + #include "vim.h" + +! #include + #include + #include + #include + #include +- #include + +! #undef chdir +! #include +! #include /* required for FindExecutable() */ + + + /* Record all output and all keyboard & mouse input */ +--- 22,44 ---- + + #include "vim.h" + +! /* cproto fails on missing include files */ +! #ifndef PROTO +! # include +! #endif +! + #include + #include + #include + #include + +! #ifndef PROTO +! # include +! +! # undef chdir +! # include +! # include /* required for FindExecutable() */ +! #endif + + + /* Record all output and all keyboard & mouse input */ +*** ../vim-7.3.718/src/os_win32.h 2012-10-21 21:38:42.000000000 +0200 +--- src/os_win32.h 2012-11-20 16:09:59.000000000 +0100 +*************** +*** 12,18 **** + + #include "os_dos.h" /* common MS-DOS and Win32 stuff */ + #ifndef __CYGWIN__ +! #include /* for _mkdir() */ + #endif + + /* Stop the VC2005 compiler from nagging. */ +--- 12,21 ---- + + #include "os_dos.h" /* common MS-DOS and Win32 stuff */ + #ifndef __CYGWIN__ +! /* cproto fails on missing include files */ +! # ifndef PROTO +! # include /* for _mkdir() */ +! # endif + #endif + + /* Stop the VC2005 compiler from nagging. */ +*************** +*** 101,107 **** + #ifndef COBJMACROS + # define COBJMACROS /* For OLE: Enable "friendlier" access to objects */ + #endif +! #include + + /* + * Win32 has plenty of memory, use large buffers +--- 104,112 ---- + #ifndef COBJMACROS + # define COBJMACROS /* For OLE: Enable "friendlier" access to objects */ + #endif +! #ifndef PROTO +! # include +! #endif + + /* + * Win32 has plenty of memory, use large buffers +*************** +*** 194,199 **** +--- 199,206 ---- + # define vim_mkdir(x, y) mch_mkdir(x) + #endif + ++ #ifndef PROTO ++ + /* Enable common dialogs input unicode from IME if posible. */ + #ifdef FEAT_MBYTE + /* The variables are defined in os_win32.c. */ +*************** +*** 207,209 **** +--- 214,218 ---- + # define pIsDialogMessage IsDialogMessage + # define pPeekMessage PeekMessage + #endif ++ ++ #endif /* PROTO */ +*** ../vim-7.3.718/src/os_win32.c 2012-10-21 21:38:42.000000000 +0200 +--- src/os_win32.c 2012-11-20 16:12:09.000000000 +0100 +*************** +*** 29,35 **** + #include + #include + #include +! #include + + #undef chdir + #ifdef __GNUC__ +--- 29,39 ---- + #include + #include + #include +! +! /* cproto fails on missing include files */ +! #ifndef PROTO +! # include +! #endif + + #undef chdir + #ifdef __GNUC__ +*************** +*** 40,47 **** + # include + #endif + +! #if defined(FEAT_TITLE) && !defined(FEAT_GUI_W32) +! # include + #endif + + #ifdef __MINGW32__ +--- 44,53 ---- + # include + #endif + +! #ifndef PROTO +! # if defined(FEAT_TITLE) && !defined(FEAT_GUI_W32) +! # include +! # endif + #endif + + #ifdef __MINGW32__ +*************** +*** 125,130 **** +--- 131,137 ---- + typedef int WORD; + typedef int WCHAR; + typedef void VOID; ++ typedef int BY_HANDLE_FILE_INFORMATION; + #endif + + #ifndef FEAT_GUI_W32 +*************** +*** 152,157 **** +--- 159,166 ---- + # define wcsicmp(a, b) wcscmpi((a), (b)) + #endif + ++ #ifndef PROTO ++ + /* Enable common dialogs input unicode from IME if posible. */ + #ifdef FEAT_MBYTE + LRESULT (WINAPI *pDispatchMessage)(LPMSG) = DispatchMessage; +*************** +*** 160,165 **** +--- 169,176 ---- + BOOL (WINAPI *pPeekMessage)(LPMSG, HWND, UINT, UINT, UINT) = PeekMessage; + #endif + ++ #endif /* PROTO */ ++ + #ifndef FEAT_GUI_W32 + /* Win32 Console handles for input and output */ + static HANDLE g_hConIn = INVALID_HANDLE_VALUE; +*************** +*** 453,459 **** + DWORD g_PlatformId; + + #ifdef HAVE_ACL +! # include + /* + * These are needed to dynamically load the ADVAPI DLL, which is not + * implemented under Windows 95 (and causes VIM to crash) +--- 464,473 ---- + DWORD g_PlatformId; + + #ifdef HAVE_ACL +! # ifndef PROTO +! # include +! # endif +! + /* + * These are needed to dynamically load the ADVAPI DLL, which is not + * implemented under Windows 95 (and causes VIM to crash) +*************** +*** 1658,1665 **** + #endif /* FEAT_GUI_W32 */ + } + +! #ifndef __MINGW32__ +! # include /* required for FindExecutable() */ + #endif + + /* +--- 1672,1681 ---- + #endif /* FEAT_GUI_W32 */ + } + +! #ifndef PROTO +! # ifndef __MINGW32__ +! # include /* required for FindExecutable() */ +! # endif + #endif + + /* +*** ../vim-7.3.718/src/os_mswin.c 2011-11-30 13:42:40.000000000 +0100 +--- src/os_mswin.c 2012-11-20 16:15:05.000000000 +0100 +*************** +*** 26,38 **** + + #ifdef WIN16 + # define SHORT_FNAME /* always 8.3 file name */ +! # include + # include + #endif + #include + #include + #include +! #include + + #undef chdir + #ifdef __GNUC__ +--- 26,43 ---- + + #ifdef WIN16 + # define SHORT_FNAME /* always 8.3 file name */ +! /* cproto fails on missing include files */ +! # ifndef PROTO +! # include +! # endif + # include + #endif + #include + #include + #include +! #ifndef PROTO +! # include +! #endif + + #undef chdir + #ifdef __GNUC__ +*************** +*** 43,62 **** + # include + #endif + +! #if defined(FEAT_TITLE) && !defined(FEAT_GUI_W32) +! # include +! #endif +! +! #if defined(FEAT_PRINTER) && !defined(FEAT_POSTSCRIPT) +! # include +! # ifdef WIN3264 +! # include +! # else +! # include + # endif +! # include + #endif + + #ifdef __MINGW32__ + # ifndef FROM_LEFT_1ST_BUTTON_PRESSED + # define FROM_LEFT_1ST_BUTTON_PRESSED 0x0001 +--- 48,70 ---- + # include + #endif + +! #ifndef PROTO +! # if defined(FEAT_TITLE) && !defined(FEAT_GUI_W32) +! # include + # endif +! +! # if defined(FEAT_PRINTER) && !defined(FEAT_POSTSCRIPT) +! # include +! # ifdef WIN3264 +! # include +! # else +! # include +! # endif +! # include + #endif + ++ #endif /* PROTO */ ++ + #ifdef __MINGW32__ + # ifndef FROM_LEFT_1ST_BUTTON_PRESSED + # define FROM_LEFT_1ST_BUTTON_PRESSED 0x0001 +*************** +*** 2410,2416 **** + + + #if defined(FEAT_SHORTCUT) || defined(PROTO) +! # include + + /* + * When "fname" is the name of a shortcut (*.lnk) resolve the file it points +--- 2418,2426 ---- + + + #if defined(FEAT_SHORTCUT) || defined(PROTO) +! # ifndef PROTO +! # include +! # endif + + /* + * When "fname" is the name of a shortcut (*.lnk) resolve the file it points +*** ../vim-7.3.718/src/gui_photon.c 2011-09-14 16:04:52.000000000 +0200 +--- src/gui_photon.c 2012-11-20 16:16:11.000000000 +0100 +*************** +*** 13,20 **** + + #include "vim.h" + +! #ifdef FEAT_TOOLBAR +! # include + #endif + + #if !defined(__QNX__) +--- 13,23 ---- + + #include "vim.h" + +! /* cproto fails on missing include files */ +! #ifndef PROTO +! # ifdef FEAT_TOOLBAR +! # include +! # endif + #endif + + #if !defined(__QNX__) +*** ../vim-7.3.718/src/os_unix.h 2011-02-25 15:17:14.000000000 +0100 +--- src/os_unix.h 2012-11-20 16:51:06.000000000 +0100 +*************** +*** 198,203 **** +--- 198,206 ---- + # define HAVE_TOTAL_MEM + #endif + ++ ++ #ifndef PROTO ++ + #ifdef VMS + # include + # include +*************** +*** 226,232 **** +--- 229,239 ---- + # ifdef FEAT_GUI_GTK + # include "gui_gtk_vms.h" + # endif ++ #endif + ++ #endif /* PROTO */ ++ ++ #ifdef VMS + typedef struct dsc$descriptor DESC; + #endif + +*** ../vim-7.3.718/src/os_beos.c 2010-08-15 21:57:28.000000000 +0200 +--- src/os_beos.c 2012-11-20 16:22:17.000000000 +0100 +*************** +*** 13,19 **** + + #include + #include +! #include + #include "vim.h" + + #if USE_THREAD_FOR_INPUT_WITH_TIMEOUT +--- 13,22 ---- + + #include + #include +! #ifndef PROTO +! # include +! #endif +! + #include "vim.h" + + #if USE_THREAD_FOR_INPUT_WITH_TIMEOUT +*** ../vim-7.3.718/src/os_beos.h 2010-08-15 21:57:32.000000000 +0200 +--- src/os_beos.h 2012-11-20 16:22:48.000000000 +0100 +*************** +*** 22,25 **** + + /* select emulation */ + +! #include /* for typedefs and #defines only */ +--- 22,27 ---- + + /* select emulation */ + +! #ifndef PROTO +! # include /* for typedefs and #defines only */ +! #endif +*** ../vim-7.3.718/src/version.c 2012-11-20 12:16:54.000000000 +0100 +--- src/version.c 2012-11-20 16:32:18.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 719, + /**/ + +-- +George: "I just got a new set of golf clubs for my wife!" + John: "Great trade!" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8e98a1d1b84de7fa1de90419e48c4b2f2c3952b6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:44 +0100 Subject: [PATCH 0598/3340] - patchlevel 720 --- 7.3.720 | 226 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 226 insertions(+) create mode 100644 7.3.720 diff --git a/7.3.720 b/7.3.720 new file mode 100644 index 00000000..90bb099e --- /dev/null +++ b/7.3.720 @@ -0,0 +1,226 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.720 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.720 +Problem: Proto files are outdated. +Solution: Update the newly generated proto files. +Files: src/proto/digraph.pro, src/proto/fold.pro, src/proto/misc1.pro, + src/proto/move.pro, src/proto/screen.pro, src/proto/search.pro, + src/proto/os_win32.pro, src/proto/os_mswin.pro, + src/proto/os_beos.pro + +*** ../vim-7.3.719/src/proto/digraph.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/digraph.pro 2012-11-20 16:51:45.000000000 +0100 +*************** +*** 1,7 **** + /* digraph.c */ + int do_digraph __ARGS((int c)); + int get_digraph __ARGS((int cmdline)); +! int getdigraph __ARGS((int char1, int char2, int meta)); + void putdigraph __ARGS((char_u *str)); + void listdigraphs __ARGS((void)); + char_u *keymap_init __ARGS((void)); +--- 1,7 ---- + /* digraph.c */ + int do_digraph __ARGS((int c)); + int get_digraph __ARGS((int cmdline)); +! int getdigraph __ARGS((int char1, int char2, int meta_char)); + void putdigraph __ARGS((char_u *str)); + void listdigraphs __ARGS((void)); + char_u *keymap_init __ARGS((void)); +*** ../vim-7.3.719/src/proto/fold.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/fold.pro 2012-11-20 16:51:49.000000000 +0100 +*************** +*** 27,33 **** + void foldUpdate __ARGS((win_T *wp, linenr_T top, linenr_T bot)); + void foldUpdateAll __ARGS((win_T *win)); + int foldMoveTo __ARGS((int updown, int dir, long count)); +! void foldInitWin __ARGS((win_T *newwin)); + int find_wl_entry __ARGS((win_T *win, linenr_T lnum)); + void foldAdjustVisual __ARGS((void)); + void foldAdjustCursor __ARGS((void)); +--- 27,33 ---- + void foldUpdate __ARGS((win_T *wp, linenr_T top, linenr_T bot)); + void foldUpdateAll __ARGS((win_T *win)); + int foldMoveTo __ARGS((int updown, int dir, long count)); +! void foldInitWin __ARGS((win_T *new_win)); + int find_wl_entry __ARGS((win_T *win, linenr_T lnum)); + void foldAdjustVisual __ARGS((void)); + void foldAdjustCursor __ARGS((void)); +*** ../vim-7.3.719/src/proto/misc1.pro 2012-08-15 14:04:50.000000000 +0200 +--- src/proto/misc1.pro 2012-11-20 16:51:56.000000000 +0100 +*************** +*** 5,12 **** + int get_indent_str __ARGS((char_u *ptr, int ts)); + int set_indent __ARGS((int size, int flags)); + int get_number_indent __ARGS((linenr_T lnum)); +! int open_line __ARGS((int dir, int flags, int old_indent)); +! int get_leader_len __ARGS((char_u *line, char_u **flags, int backward, int do_skip_space)); + int get_last_leader_offset __ARGS((char_u *line, char_u **flags)); + int plines __ARGS((linenr_T lnum)); + int plines_win __ARGS((win_T *wp, linenr_T lnum, int winheight)); +--- 5,12 ---- + int get_indent_str __ARGS((char_u *ptr, int ts)); + int set_indent __ARGS((int size, int flags)); + int get_number_indent __ARGS((linenr_T lnum)); +! int open_line __ARGS((int dir, int flags, int second_line_indent)); +! int get_leader_len __ARGS((char_u *line, char_u **flags, int backward, int include_space)); + int get_last_leader_offset __ARGS((char_u *line, char_u **flags)); + int plines __ARGS((linenr_T lnum)); + int plines_win __ARGS((win_T *wp, linenr_T lnum, int winheight)); +*************** +*** 59,65 **** + void vim_setenv __ARGS((char_u *name, char_u *val)); + char_u *get_env_name __ARGS((expand_T *xp, int idx)); + char_u *get_users __ARGS((expand_T *xp, int idx)); +! int match_user __ARGS((char_u* name)); + void home_replace __ARGS((buf_T *buf, char_u *src, char_u *dst, int dstlen, int one)); + char_u *home_replace_save __ARGS((buf_T *buf, char_u *src)); + int fullpathcmp __ARGS((char_u *s1, char_u *s2, int checkname)); +--- 59,65 ---- + void vim_setenv __ARGS((char_u *name, char_u *val)); + char_u *get_env_name __ARGS((expand_T *xp, int idx)); + char_u *get_users __ARGS((expand_T *xp, int idx)); +! int match_user __ARGS((char_u *name)); + void home_replace __ARGS((buf_T *buf, char_u *src, char_u *dst, int dstlen, int one)); + char_u *home_replace_save __ARGS((buf_T *buf, char_u *src)); + int fullpathcmp __ARGS((char_u *s1, char_u *s2, int checkname)); +*** ../vim-7.3.719/src/proto/move.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/move.pro 2012-11-20 16:51:57.000000000 +0100 +*************** +*** 24,30 **** + int curwin_col_off __ARGS((void)); + int win_col_off2 __ARGS((win_T *wp)); + int curwin_col_off2 __ARGS((void)); +! void curs_columns __ARGS((int scroll)); + void scrolldown __ARGS((long line_count, int byfold)); + void scrollup __ARGS((long line_count, int byfold)); + void check_topfill __ARGS((win_T *wp, int down)); +--- 24,30 ---- + int curwin_col_off __ARGS((void)); + int win_col_off2 __ARGS((win_T *wp)); + int curwin_col_off2 __ARGS((void)); +! void curs_columns __ARGS((int may_scroll)); + void scrolldown __ARGS((long line_count, int byfold)); + void scrollup __ARGS((long line_count, int byfold)); + void check_topfill __ARGS((win_T *wp, int down)); +*** ../vim-7.3.719/src/proto/screen.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/screen.pro 2012-11-20 16:52:01.000000000 +0100 +*************** +*** 31,38 **** + void screen_draw_rectangle __ARGS((int row, int col, int height, int width, int invert)); + void screen_fill __ARGS((int start_row, int end_row, int start_col, int end_col, int c1, int c2, int attr)); + void check_for_delay __ARGS((int check_msg_scroll)); +! int screen_valid __ARGS((int clear)); +! void screenalloc __ARGS((int clear)); + void free_screenlines __ARGS((void)); + void screenclear __ARGS((void)); + int can_clear __ARGS((char_u *p)); +--- 31,38 ---- + void screen_draw_rectangle __ARGS((int row, int col, int height, int width, int invert)); + void screen_fill __ARGS((int start_row, int end_row, int start_col, int end_col, int c1, int c2, int attr)); + void check_for_delay __ARGS((int check_msg_scroll)); +! int screen_valid __ARGS((int doclear)); +! void screenalloc __ARGS((int doclear)); + void free_screenlines __ARGS((void)); + void screenclear __ARGS((void)); + int can_clear __ARGS((char_u *p)); +*** ../vim-7.3.719/src/proto/search.pro 2012-07-25 15:06:20.000000000 +0200 +--- src/proto/search.pro 2012-11-20 16:52:01.000000000 +0100 +*************** +*** 27,38 **** + int end_word __ARGS((long count, int bigword, int stop, int empty)); + int bckend_word __ARGS((long count, int bigword, int eol)); + int current_word __ARGS((oparg_T *oap, long count, int include, int bigword)); +- int current_search __ARGS((long count, int forward)); + int current_sent __ARGS((oparg_T *oap, long count, int include)); + int current_block __ARGS((oparg_T *oap, long count, int include, int what, int other)); + int current_tagblock __ARGS((oparg_T *oap, long count_arg, int include)); + int current_par __ARGS((oparg_T *oap, long count, int include, int type)); + int current_quote __ARGS((oparg_T *oap, long count, int include, int quotechar)); + int linewhite __ARGS((linenr_T lnum)); + void find_pattern_in_path __ARGS((char_u *ptr, int dir, int len, int whole, int skip_comments, int type, long count, int action, linenr_T start_lnum, linenr_T end_lnum)); + int read_viminfo_search_pattern __ARGS((vir_T *virp, int force)); +--- 27,38 ---- + int end_word __ARGS((long count, int bigword, int stop, int empty)); + int bckend_word __ARGS((long count, int bigword, int eol)); + int current_word __ARGS((oparg_T *oap, long count, int include, int bigword)); + int current_sent __ARGS((oparg_T *oap, long count, int include)); + int current_block __ARGS((oparg_T *oap, long count, int include, int what, int other)); + int current_tagblock __ARGS((oparg_T *oap, long count_arg, int include)); + int current_par __ARGS((oparg_T *oap, long count, int include, int type)); + int current_quote __ARGS((oparg_T *oap, long count, int include, int quotechar)); ++ int current_search __ARGS((long count, int forward)); + int linewhite __ARGS((linenr_T lnum)); + void find_pattern_in_path __ARGS((char_u *ptr, int dir, int len, int whole, int skip_comments, int type, long count, int action, linenr_T start_lnum, linenr_T end_lnum)); + int read_viminfo_search_pattern __ARGS((vir_T *virp, int force)); +*** ../vim-7.3.719/src/proto/os_win32.pro 2011-05-05 18:31:54.000000000 +0200 +--- src/proto/os_win32.pro 2012-11-20 16:52:13.000000000 +0100 +*************** +*** 22,28 **** + int mch_isdir __ARGS((char_u *name)); + int mch_mkdir __ARGS((char_u *name)); + int mch_is_linked __ARGS((char_u *fname)); +! int win32_fileinfo __ARGS((char_u *name, BY_HANDLE_FILE_INFORMATION *lpFileInfo)); + int mch_writable __ARGS((char_u *name)); + int mch_can_exe __ARGS((char_u *name)); + int mch_nodetype __ARGS((char_u *name)); +--- 22,28 ---- + int mch_isdir __ARGS((char_u *name)); + int mch_mkdir __ARGS((char_u *name)); + int mch_is_linked __ARGS((char_u *fname)); +! int win32_fileinfo __ARGS((char_u *fname, BY_HANDLE_FILE_INFORMATION *info)); + int mch_writable __ARGS((char_u *name)); + int mch_can_exe __ARGS((char_u *name)); + int mch_nodetype __ARGS((char_u *name)); +*** ../vim-7.3.719/src/proto/os_mswin.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/os_mswin.pro 2012-11-20 16:52:14.000000000 +0100 +*************** +*** 28,38 **** + void WideCharToMultiByte_alloc __ARGS((UINT cp, DWORD flags, LPCWSTR in, int inlen, LPSTR *out, int *outlen, LPCSTR def, LPBOOL useddef)); + int clip_mch_own_selection __ARGS((VimClipboard *cbd)); + void clip_mch_lose_selection __ARGS((VimClipboard *cbd)); + short_u *enc_to_utf16 __ARGS((char_u *str, int *lenp)); + char_u *utf16_to_enc __ARGS((short_u *str, int *lenp)); +- void clip_mch_request_selection __ARGS((VimClipboard *cbd)); + void acp_to_enc __ARGS((char_u *str, int str_size, char_u **out, int *outlen)); +- void clip_mch_set_selection __ARGS((VimClipboard *cbd)); + void DumpPutS __ARGS((const char *psz)); + int mch_get_winpos __ARGS((int *x, int *y)); + void mch_set_winpos __ARGS((int x, int y)); +--- 28,38 ---- + void WideCharToMultiByte_alloc __ARGS((UINT cp, DWORD flags, LPCWSTR in, int inlen, LPSTR *out, int *outlen, LPCSTR def, LPBOOL useddef)); + int clip_mch_own_selection __ARGS((VimClipboard *cbd)); + void clip_mch_lose_selection __ARGS((VimClipboard *cbd)); ++ void clip_mch_request_selection __ARGS((VimClipboard *cbd)); ++ void clip_mch_set_selection __ARGS((VimClipboard *cbd)); + short_u *enc_to_utf16 __ARGS((char_u *str, int *lenp)); + char_u *utf16_to_enc __ARGS((short_u *str, int *lenp)); + void acp_to_enc __ARGS((char_u *str, int str_size, char_u **out, int *outlen)); + void DumpPutS __ARGS((const char *psz)); + int mch_get_winpos __ARGS((int *x, int *y)); + void mch_set_winpos __ARGS((int x, int y)); +*** ../vim-7.3.719/src/version.c 2012-11-20 16:53:34.000000000 +0100 +--- src/version.c 2012-11-20 16:55:09.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 720, + /**/ + +-- +Light travels faster than sound. This is why some people +appear bright until you hear them speak + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7d5dcd840f33a384779bac06ca962e3c68bd093d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:45 +0100 Subject: [PATCH 0599/3340] - patchlevel 721 --- 7.3.721 | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 7.3.721 diff --git a/7.3.721 b/7.3.721 new file mode 100644 index 00000000..d9a139f2 --- /dev/null +++ b/7.3.721 @@ -0,0 +1,60 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.721 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.721 +Problem: Ruby interface defines local functions globally. +Solution: Make the functions static. +Files: src/if_ruby.c + + +*** ../vim-7.3.720/src/if_ruby.c 2012-10-03 18:06:55.000000000 +0200 +--- src/if_ruby.c 2012-11-20 15:35:46.000000000 +0100 +*************** +*** 336,346 **** + #endif + + #ifdef RUBY19_OR_LATER +! SIGNED_VALUE rb_num2long_stub(VALUE x) + { + return dll_rb_num2long(x); + } +! VALUE rb_int2big_stub(SIGNED_VALUE x) + { + return dll_rb_int2big(x); + } +--- 336,346 ---- + #endif + + #ifdef RUBY19_OR_LATER +! static SIGNED_VALUE rb_num2long_stub(VALUE x) + { + return dll_rb_num2long(x); + } +! static VALUE rb_int2big_stub(SIGNED_VALUE x) + { + return dll_rb_int2big(x); + } +*** ../vim-7.3.720/src/version.c 2012-11-20 16:56:49.000000000 +0100 +--- src/version.c 2012-11-20 16:58:32.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 721, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +39. You move into a new house and decide to Netscape before you landscape. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0b8066b747f1456a30a8bb1378a49efe8e8f0971 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:46 +0100 Subject: [PATCH 0600/3340] - patchlevel 722 --- 7.3.722 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.722 diff --git a/7.3.722 b/7.3.722 new file mode 100644 index 00000000..d2d421d6 --- /dev/null +++ b/7.3.722 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.722 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.722 +Problem: Perl flags may contain "-g", which breaks "make proto". +Solution: Filter out the "-g" flag for cproto. (Ken Takata) +Files: src/Makefile + + +*** ../vim-7.3.721/src/Makefile 2012-07-25 16:32:03.000000000 +0200 +--- src/Makefile 2012-11-20 17:02:22.000000000 +0100 +*************** +*** 1753,1762 **** + # Filter out arguments that cproto doesn't support. + # Don't pass "-pthread" to cproto, it sees it as a list of individual flags. + # Don't pass "-fstack-protector" to cproto, for the same reason. + # The -E"gcc -E" argument must be separate to avoid problems with shell + # quoting. + CPROTO = cproto $(PROTO_FLAGS) -DPROTO \ +! `echo '$(LINT_CFLAGS)' | sed -e 's/-pthread//g' -e 's/-fstack-protector//g'` + + ### Would be nice if this would work for "normal" make. + ### Currently it only works for (Free)BSD make. +--- 1753,1763 ---- + # Filter out arguments that cproto doesn't support. + # Don't pass "-pthread" to cproto, it sees it as a list of individual flags. + # Don't pass "-fstack-protector" to cproto, for the same reason. ++ # Don't pass "-g" to cproto. + # The -E"gcc -E" argument must be separate to avoid problems with shell + # quoting. + CPROTO = cproto $(PROTO_FLAGS) -DPROTO \ +! `echo '$(LINT_CFLAGS)' | sed -e 's/-pthread//g' -e 's/-fstack-protector//g' -e 's/\ -g\ / /g'` + + ### Would be nice if this would work for "normal" make. + ### Currently it only works for (Free)BSD make. +*** ../vim-7.3.721/src/version.c 2012-11-20 16:59:09.000000000 +0100 +--- src/version.c 2012-11-20 17:02:54.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 722, + /**/ + +-- +The future isn't what it used to be. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6d2b8d40b7db0999a8bca99160a28b7c0737a3f8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:47 +0100 Subject: [PATCH 0601/3340] - patchlevel 723 --- 7.3.723 | 264 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 264 insertions(+) create mode 100644 7.3.723 diff --git a/7.3.723 b/7.3.723 new file mode 100644 index 00000000..b977e755 --- /dev/null +++ b/7.3.723 @@ -0,0 +1,264 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.723 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.723 +Problem: Various tiny problems. +Solution: Various tiny fixes. +Files: src/gui_mac.c, src/xpm_w32.c, src/netbeans.c, src/sha256.c, + src/if_sniff.c, README.txt + + +*** ../vim-7.3.722/src/gui_mac.c 2011-12-14 15:07:11.000000000 +0100 +--- src/gui_mac.c 2012-06-20 18:16:12.000000000 +0200 +*************** +*** 5728,5734 **** + case VIM_QUESTION: useIcon = kNoteIcon; break; + case VIM_WARNING: useIcon = kCautionIcon; break; + case VIM_ERROR: useIcon = kStopIcon; break; +! default: useIcon = kStopIcon; + } + AppendDITL(theDialog, iconDITL, overlayDITL); + ReleaseResource(iconDITL); +--- 5728,5734 ---- + case VIM_QUESTION: useIcon = kNoteIcon; break; + case VIM_WARNING: useIcon = kCautionIcon; break; + case VIM_ERROR: useIcon = kStopIcon; break; +! default: useIcon = kStopIcon; + } + AppendDITL(theDialog, iconDITL, overlayDITL); + ReleaseResource(iconDITL); +*** ../vim-7.3.722/src/xpm_w32.c 2012-02-05 00:47:56.000000000 +0100 +--- src/xpm_w32.c 2012-08-02 21:46:20.000000000 +0200 +*************** +*** 55,61 **** + return -1; + if (shp == NULL) + { +! if (img) + XDestroyImage(img); + return -1; + } +--- 55,61 ---- + return -1; + if (shp == NULL) + { +! if (img) + XDestroyImage(img); + return -1; + } +*** ../vim-7.3.722/src/netbeans.c 2012-04-20 19:47:00.000000000 +0200 +--- src/netbeans.c 2012-06-20 19:56:18.000000000 +0200 +*************** +*** 978,984 **** + buf_list_used = 0; + + /* free the queued key commands */ +! while(key_node != NULL && key_node != &keyHead) + { + keyQ_T *next = key_node->next; + vim_free(key_node->keystr); +--- 978,984 ---- + buf_list_used = 0; + + /* free the queued key commands */ +! while (key_node != NULL && key_node != &keyHead) + { + keyQ_T *next = key_node->next; + vim_free(key_node->keystr); +*************** +*** 993,999 **** + } + + /* free the queued netbeans commands */ +! while(cmd_node != NULL && cmd_node != &head) + { + queue_T *next = cmd_node->next; + vim_free(cmd_node->buffer); +--- 993,999 ---- + } + + /* free the queued netbeans commands */ +! while (cmd_node != NULL && cmd_node != &head) + { + queue_T *next = cmd_node->next; + vim_free(cmd_node->buffer); +*** ../vim-7.3.722/src/sha256.c 2010-08-15 21:57:25.000000000 +0200 +--- src/sha256.c 2012-03-18 21:35:07.000000000 +0100 +*************** +*** 7,15 **** + * See README.txt for an overview of the Vim source code. + * + * FIPS-180-2 compliant SHA-256 implementation +! * GPL by Christophe Devine. + * Modified for md5deep, in public domain. + * Modified For Vim, Mohsin Ahmed, http://www.cs.albany.edu/~mosh + * + * Vim specific notes: + * Functions exported by this file: +--- 7,17 ---- + * See README.txt for an overview of the Vim source code. + * + * FIPS-180-2 compliant SHA-256 implementation +! * GPL by Christophe Devine, applies to older version. + * Modified for md5deep, in public domain. + * Modified For Vim, Mohsin Ahmed, http://www.cs.albany.edu/~mosh ++ * Mohsin Ahmed states this work is distributed under the VIM License or GPL, ++ * at your choice. + * + * Vim specific notes: + * Functions exported by this file: +*** ../vim-7.3.722/src/if_sniff.c 2010-12-17 18:06:00.000000000 +0100 +--- src/if_sniff.c 2012-06-20 19:56:09.000000000 +0200 +*************** +*** 449,455 **** + if (!sniff_cmd) + { + struct sn_cmd_list *list = sniff_cmd_ext; +! while(list) + { + if (!strcmp(cmd, list->sniff_cmd->cmd_name)) + { +--- 449,455 ---- + if (!sniff_cmd) + { + struct sn_cmd_list *list = sniff_cmd_ext; +! while (list) + { + if (!strcmp(cmd, list->sniff_cmd->cmd_name)) + { +*************** +*** 479,485 **** + /* unescape message text */ + char *p = msg; + char *end = p+strlen(msg); +! while(*p) + { + if (*p == '\\') + mch_memmove(p,p+1,end-p); +--- 479,485 ---- + /* unescape message text */ + char *p = msg; + char *end = p+strlen(msg); +! while (*p) + { + if (*p == '\\') + mch_memmove(p,p+1,end-p); +*************** +*** 489,495 **** + SNIFF_TRACE1("request def = %s\n",def); + SNIFF_TRACE1("request msg = %s\n",msg); + +! while(list && list->next_cmd) + list = list->next_cmd; + if (!list) + sniff_cmd_ext = cmd_node; +--- 489,495 ---- + SNIFF_TRACE1("request def = %s\n",def); + SNIFF_TRACE1("request msg = %s\n",msg); + +! while (list && list->next_cmd) + list = list->next_cmd; + if (!list) + sniff_cmd_ext = cmd_node; +*************** +*** 628,634 **** + gui_mch_wait_for_chars(0L); + #endif + #ifdef WIN32 +! while(sniffBufStart != NULL) + { + struct sniffBufNode *node = sniffBufStart; + sniffBufStart = sniffBufStart->next; +--- 628,634 ---- + gui_mch_wait_for_chars(0L); + #endif + #ifdef WIN32 +! while (sniffBufStart != NULL) + { + struct sniffBufNode *node = sniffBufStart; + sniffBufStart = sniffBufStart->next; +*************** +*** 789,795 **** + command = buffer[0]; + arguments = &buffer[1]; + token = strtok(arguments, sniff_rq_sep); +! while(argc <3) + { + if (token) + { +--- 789,795 ---- + command = buffer[0]; + arguments = &buffer[1]; + token = strtok(arguments, sniff_rq_sep); +! while (argc <3) + { + if (token) + { +*************** +*** 925,931 **** + default : + break; + } +! while(argc) + vim_free(argv[--argc]); + } + +--- 925,931 ---- + default : + break; + } +! while (argc) + vim_free(argv[--argc]); + } + +*** ../vim-7.3.722/README.txt 2010-08-15 21:56:43.000000000 +0200 +--- README.txt 2012-10-28 18:58:18.000000000 +0100 +*************** +*** 97,103 **** + If you have problems, have a look at the Vim FAQ: + http://vimdoc.sf.net/vimfaq.html + +! Send bug reports to: + Bram Moolenaar + + There are several mailing lists for Vim, see http://www.vim.org/maillist.php. +--- 97,107 ---- + If you have problems, have a look at the Vim FAQ: + http://vimdoc.sf.net/vimfaq.html + +! If you still have problems, use one of the maillists to discuss t with Vim +! users and developers: +! http://www.vim.org/maillist.php +! +! If nothing else works, report bugs directly: + Bram Moolenaar + + There are several mailing lists for Vim, see http://www.vim.org/maillist.php. +*** ../vim-7.3.722/src/version.c 2012-11-20 17:03:23.000000000 +0100 +--- src/version.c 2012-11-20 17:14:09.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 723, + /**/ + +-- +"Oh, no! NOT the Spanish Inquisition!" +"NOBODY expects the Spanish Inquisition!!!" + -- Monty Python sketch -- +"Oh, no! NOT another option!" +"EVERYBODY expects another option!!!" + -- Discussion in vim-dev mailing list -- + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6a9a084f9b108ec286d0f3c960793b5b2d041a6b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:48 +0100 Subject: [PATCH 0602/3340] - patchlevel 724 --- 7.3.724 | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 7.3.724 diff --git a/7.3.724 b/7.3.724 new file mode 100644 index 00000000..d58a50b0 --- /dev/null +++ b/7.3.724 @@ -0,0 +1,50 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.724 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.724 +Problem: Building with Ruby and Tcl on MS-Windows 64 bit does not work. +Solution: Remove Ruby and Tcl from the big MS-Windows build. +Files: src/bigvim64.bat + + +*** ../vim-7.3.723/src/bigvim64.bat 2012-08-29 14:18:26.000000000 +0200 +--- src/bigvim64.bat 2012-08-29 17:32:55.000000000 +0200 +*************** +*** 1,6 **** + :: command to build big Vim 64 bit with OLE, Perl, Python, Ruby and Tcl + :: First run: %VCDIR%\vcvarsall.bat x86_amd64 + SET VCDIR="C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\" + SET TOOLDIR=E:\ +! %VCDIR%\bin\nmake -f Make_mvc.mak CPU=AMD64 GUI=yes OLE=yes PERL=E:\perl514 DYNAMIC_PERL=yes PERL_VER=514 PYTHON=%TOOLDIR%python27 DYNAMIC_PYTHON=yes PYTHON_VER=27 PYTHON3=%TOOLDIR%python32 DYNAMIC_PYTHON3=yes PYTHON3_VER=32 RUBY=%TOOLDIR%ruby192 DYNAMIC_RUBY=yes RUBY_VER=192 RUBY_VER_LONG=1.9.2 TCL=%TOOLDIR%tcl TCL_VER=85 TCL_VER_LONG=8.5 DYNAMIC_TCL=yes %1 IME=yes CSCOPE=yes + +--- 1,7 ---- + :: command to build big Vim 64 bit with OLE, Perl, Python, Ruby and Tcl + :: First run: %VCDIR%\vcvarsall.bat x86_amd64 ++ :: Ruby and Tcl are excluded, doesn't seem to work. + SET VCDIR="C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\" + SET TOOLDIR=E:\ +! %VCDIR%\bin\nmake -f Make_mvc.mak CPU=AMD64 GUI=yes OLE=yes PERL=E:\perl514 DYNAMIC_PERL=yes PERL_VER=514 PYTHON=%TOOLDIR%python27 DYNAMIC_PYTHON=yes PYTHON_VER=27 PYTHON3=%TOOLDIR%python32 DYNAMIC_PYTHON3=yes PYTHON3_VER=32 %1 IME=yes CSCOPE=yes + +*** ../vim-7.3.723/src/version.c 2012-11-20 17:18:56.000000000 +0100 +--- src/version.c 2012-11-20 17:20:51.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 724, + /**/ + +-- +Microsoft is to software what McDonalds is to gourmet cooking + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 73c4a232993b102de0c7fe1246a64d19e7b27229 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:49 +0100 Subject: [PATCH 0603/3340] - patchlevel 725 --- 7.3.725 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.725 diff --git a/7.3.725 b/7.3.725 new file mode 100644 index 00000000..a8d20f86 --- /dev/null +++ b/7.3.725 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.725 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.725 +Problem: :aboveleft and :belowright have no effect on :copen. +Solution: Check for cmdmod.split. (Christian Brabandt) +Files: src/quickfix.c + + +*** ../vim-7.3.724/src/quickfix.c 2012-11-14 22:38:04.000000000 +0100 +--- src/quickfix.c 2012-11-20 17:51:59.000000000 +0100 +*************** +*** 2347,2354 **** + /* The current window becomes the previous window afterwards. */ + win = curwin; + +! if (eap->cmdidx == CMD_copen || eap->cmdidx == CMD_cwindow) +! /* Create the new window at the very bottom. */ + win_goto(lastwin); + if (win_split(height, WSP_BELOW | WSP_NEWLOC) == FAIL) + return; /* not enough room for window */ +--- 2347,2356 ---- + /* The current window becomes the previous window afterwards. */ + win = curwin; + +! if ((eap->cmdidx == CMD_copen || eap->cmdidx == CMD_cwindow) +! && cmdmod.split == 0) +! /* Create the new window at the very bottom, except when +! * :belowright or :aboveleft is used. */ + win_goto(lastwin); + if (win_split(height, WSP_BELOW | WSP_NEWLOC) == FAIL) + return; /* not enough room for window */ +*** ../vim-7.3.724/src/version.c 2012-11-20 17:21:29.000000000 +0100 +--- src/version.c 2012-11-20 17:50:30.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 725, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +40. You tell the cab driver you live at + http://123.elm.street/house/bluetrim.html +41. You actually try that 123.elm.street address. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 45437dae794fa921b3a8878ed4783740a05a7a6a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:50 +0100 Subject: [PATCH 0604/3340] - patchlevel 726 --- 7.3.726 | 66 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) create mode 100644 7.3.726 diff --git a/7.3.726 b/7.3.726 new file mode 100644 index 00000000..93507536 --- /dev/null +++ b/7.3.726 @@ -0,0 +1,66 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.726 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.726 +Problem: Typos and duplicate info in README. +Solution: Fix the text. +Files: README.txt + + +*** ../vim-7.3.725/README.txt 2012-11-20 17:18:56.000000000 +0100 +--- README.txt 2012-11-21 12:28:58.000000000 +0100 +*************** +*** 97,111 **** + If you have problems, have a look at the Vim FAQ: + http://vimdoc.sf.net/vimfaq.html + +! If you still have problems, use one of the maillists to discuss t with Vim +! users and developers: + http://www.vim.org/maillist.php + + If nothing else works, report bugs directly: + Bram Moolenaar + +- There are several mailing lists for Vim, see http://www.vim.org/maillist.php. +- + + MAIN AUTHOR + +--- 97,109 ---- + If you have problems, have a look at the Vim FAQ: + http://vimdoc.sf.net/vimfaq.html + +! If you still have problems or any other questions, use one of the mailing +! lists to discuss them with Vim users and developers: + http://www.vim.org/maillist.php + + If nothing else works, report bugs directly: + Bram Moolenaar + + + MAIN AUTHOR + +*** ../vim-7.3.725/src/version.c 2012-11-20 17:55:06.000000000 +0100 +--- src/version.c 2012-11-23 21:44:38.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 726, + /**/ + +-- +Q: Should I clean my house or work on Vim? +A: Whatever contains more bugs. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a1e0feaf116f560494360448cf3129e274c66358 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:51 +0100 Subject: [PATCH 0605/3340] - patchlevel 727 --- 7.3.727 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.727 diff --git a/7.3.727 b/7.3.727 new file mode 100644 index 00000000..02ea4212 --- /dev/null +++ b/7.3.727 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.727 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.727 +Problem: Can't always find Win32.mak when building GvimExt. +Solution: Use same mechanism as in Make_mvc.mak. (Cade Foster) +Files: src/GvimExt/Makefile + + +*** ../vim-7.3.726/src/GvimExt/Makefile 2010-08-15 21:57:29.000000000 +0200 +--- src/GvimExt/Makefile 2012-11-21 19:53:02.000000000 +0100 +*************** +*** 10,16 **** + NODEBUG = 1 + !endif + +! !include + + all: gvimext.dll + +--- 10,20 ---- + NODEBUG = 1 + !endif + +! !ifdef SDK_INCLUDE_DIR +! !include $(SDK_INCLUDE_DIR)\Win32.mak +! !else +! !include +! !endif + + all: gvimext.dll + +*** ../vim-7.3.726/src/version.c 2012-11-23 21:45:20.000000000 +0100 +--- src/version.c 2012-11-23 21:46:35.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 727, + /**/ + +-- +Time is money. Especially if you make clocks. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 30a10f835ff863e6ee0397c048032c1d18aee2d0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:52 +0100 Subject: [PATCH 0606/3340] - patchlevel 728 --- 7.3.728 | 191 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 191 insertions(+) create mode 100644 7.3.728 diff --git a/7.3.728 b/7.3.728 new file mode 100644 index 00000000..bdb0219f --- /dev/null +++ b/7.3.728 @@ -0,0 +1,191 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.728 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.728 +Problem: Cannot compile with MzScheme interface on Ubuntu 12.10. +Solution: Find the collects directory under /usr/share. +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.727/src/configure.in 2012-10-03 21:09:33.000000000 +0200 +--- src/configure.in 2012-11-23 21:51:39.000000000 +0100 +*************** +*** 650,666 **** + MZSCHEME_LIBS="${MZSCHEME_LIBS} -R ${vi_cv_path_mzscheme_pfx}/lib" + fi + fi + if test -d $vi_cv_path_mzscheme_pfx/lib/plt/collects; then +! SCHEME_COLLECTS=lib/plt/ + else + if test -d $vi_cv_path_mzscheme_pfx/lib/racket/collects; then +! SCHEME_COLLECTS=lib/racket/ + fi + fi +! if test -f "${vi_cv_path_mzscheme_pfx}/${SCHEME_COLLECTS}collects/scheme/base.ss" ; then + MZSCHEME_EXTRA="mzscheme_base.c" + else +! if test -f "${vi_cv_path_mzscheme_pfx}/${SCHEME_COLLECTS}collects/scheme/base.rkt" ; then + MZSCHEME_EXTRA="mzscheme_base.c" + fi + fi +--- 650,679 ---- + MZSCHEME_LIBS="${MZSCHEME_LIBS} -R ${vi_cv_path_mzscheme_pfx}/lib" + fi + fi ++ ++ AC_MSG_CHECKING(for racket collects directory) + if test -d $vi_cv_path_mzscheme_pfx/lib/plt/collects; then +! SCHEME_COLLECTS=$vi_cv_path_mzscheme_pfx/lib/plt/ + else + if test -d $vi_cv_path_mzscheme_pfx/lib/racket/collects; then +! SCHEME_COLLECTS=$vi_cv_path_mzscheme_pfx/lib/racket/ +! else +! if test -d $vi_cv_path_mzscheme_pfx/share/racket/collects; then +! SCHEME_COLLECTS=$vi_cv_path_mzscheme_pfx/share/racket/ +! fi + fi + fi +! if test "X$SCHEME_COLLECTS" != "X" ; then +! AC_MSG_RESULT(${SCHEME_COLLECTS}) +! else +! AC_MSG_RESULT(not found) +! fi +! +! AC_MSG_CHECKING(for mzscheme_base.c) +! if test -f "${SCHEME_COLLECTS}collects/scheme/base.ss" ; then + MZSCHEME_EXTRA="mzscheme_base.c" + else +! if test -f "${SCHEME_COLLECTS}collects/scheme/base.rkt" ; then + MZSCHEME_EXTRA="mzscheme_base.c" + fi + fi +*************** +*** 668,676 **** + dnl need to generate bytecode for MzScheme base + MZSCHEME_CFLAGS="${MZSCHEME_CFLAGS} -DINCLUDE_MZSCHEME_BASE" + MZSCHEME_MZC="${vi_cv_path_mzscheme_pfx}/bin/mzc" + fi + MZSCHEME_CFLAGS="${MZSCHEME_CFLAGS} -I${SCHEME_INC} \ +! -DMZSCHEME_COLLECTS='\"${vi_cv_path_mzscheme_pfx}/${SCHEME_COLLECTS}collects\"'" + MZSCHEME_SRC="if_mzsch.c" + MZSCHEME_OBJ="objects/if_mzsch.o" + MZSCHEME_PRO="if_mzsch.pro" +--- 681,693 ---- + dnl need to generate bytecode for MzScheme base + MZSCHEME_CFLAGS="${MZSCHEME_CFLAGS} -DINCLUDE_MZSCHEME_BASE" + MZSCHEME_MZC="${vi_cv_path_mzscheme_pfx}/bin/mzc" ++ AC_MSG_RESULT(needed) ++ else ++ AC_MSG_RESULT(not needed) + fi ++ + MZSCHEME_CFLAGS="${MZSCHEME_CFLAGS} -I${SCHEME_INC} \ +! -DMZSCHEME_COLLECTS='\"${SCHEME_COLLECTS}collects\"'" + MZSCHEME_SRC="if_mzsch.c" + MZSCHEME_OBJ="objects/if_mzsch.o" + MZSCHEME_PRO="if_mzsch.pro" +*** ../vim-7.3.727/src/auto/configure 2012-10-03 21:09:33.000000000 +0200 +--- src/auto/configure 2012-11-23 21:51:42.000000000 +0100 +*************** +*** 4957,4982 **** + MZSCHEME_LIBS="${MZSCHEME_LIBS} -R ${vi_cv_path_mzscheme_pfx}/lib" + fi + fi + if test -d $vi_cv_path_mzscheme_pfx/lib/plt/collects; then +! SCHEME_COLLECTS=lib/plt/ + else + if test -d $vi_cv_path_mzscheme_pfx/lib/racket/collects; then +! SCHEME_COLLECTS=lib/racket/ + fi + fi +! if test -f "${vi_cv_path_mzscheme_pfx}/${SCHEME_COLLECTS}collects/scheme/base.ss" ; then + MZSCHEME_EXTRA="mzscheme_base.c" + else +! if test -f "${vi_cv_path_mzscheme_pfx}/${SCHEME_COLLECTS}collects/scheme/base.rkt" ; then + MZSCHEME_EXTRA="mzscheme_base.c" + fi + fi + if test "X$MZSCHEME_EXTRA" != "X" ; then + MZSCHEME_CFLAGS="${MZSCHEME_CFLAGS} -DINCLUDE_MZSCHEME_BASE" + MZSCHEME_MZC="${vi_cv_path_mzscheme_pfx}/bin/mzc" + fi + MZSCHEME_CFLAGS="${MZSCHEME_CFLAGS} -I${SCHEME_INC} \ +! -DMZSCHEME_COLLECTS='\"${vi_cv_path_mzscheme_pfx}/${SCHEME_COLLECTS}collects\"'" + MZSCHEME_SRC="if_mzsch.c" + MZSCHEME_OBJ="objects/if_mzsch.o" + MZSCHEME_PRO="if_mzsch.pro" +--- 4957,5005 ---- + MZSCHEME_LIBS="${MZSCHEME_LIBS} -R ${vi_cv_path_mzscheme_pfx}/lib" + fi + fi ++ ++ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for racket collects directory" >&5 ++ $as_echo_n "checking for racket collects directory... " >&6; } + if test -d $vi_cv_path_mzscheme_pfx/lib/plt/collects; then +! SCHEME_COLLECTS=$vi_cv_path_mzscheme_pfx/lib/plt/ + else + if test -d $vi_cv_path_mzscheme_pfx/lib/racket/collects; then +! SCHEME_COLLECTS=$vi_cv_path_mzscheme_pfx/lib/racket/ +! else +! if test -d $vi_cv_path_mzscheme_pfx/share/racket/collects; then +! SCHEME_COLLECTS=$vi_cv_path_mzscheme_pfx/share/racket/ +! fi + fi + fi +! if test "X$SCHEME_COLLECTS" != "X" ; then +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${SCHEME_COLLECTS}" >&5 +! $as_echo "${SCHEME_COLLECTS}" >&6; } +! else +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 +! $as_echo "not found" >&6; } +! fi +! +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mzscheme_base.c" >&5 +! $as_echo_n "checking for mzscheme_base.c... " >&6; } +! if test -f "${SCHEME_COLLECTS}collects/scheme/base.ss" ; then + MZSCHEME_EXTRA="mzscheme_base.c" + else +! if test -f "${SCHEME_COLLECTS}collects/scheme/base.rkt" ; then + MZSCHEME_EXTRA="mzscheme_base.c" + fi + fi + if test "X$MZSCHEME_EXTRA" != "X" ; then + MZSCHEME_CFLAGS="${MZSCHEME_CFLAGS} -DINCLUDE_MZSCHEME_BASE" + MZSCHEME_MZC="${vi_cv_path_mzscheme_pfx}/bin/mzc" ++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: needed" >&5 ++ $as_echo "needed" >&6; } ++ else ++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: not needed" >&5 ++ $as_echo "not needed" >&6; } + fi ++ + MZSCHEME_CFLAGS="${MZSCHEME_CFLAGS} -I${SCHEME_INC} \ +! -DMZSCHEME_COLLECTS='\"${SCHEME_COLLECTS}collects\"'" + MZSCHEME_SRC="if_mzsch.c" + MZSCHEME_OBJ="objects/if_mzsch.o" + MZSCHEME_PRO="if_mzsch.pro" +*** ../vim-7.3.727/src/version.c 2012-11-23 21:47:18.000000000 +0100 +--- src/version.c 2012-11-23 21:54:13.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 728, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +60. As your car crashes through the guardrail on a mountain road, your first + instinct is to search for the "back" button. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3f7a203944d215bf2d79f9f315823fa1863a897e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:53 +0100 Subject: [PATCH 0607/3340] - patchlevel 729 --- 7.3.729 | 62 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 7.3.729 diff --git a/7.3.729 b/7.3.729 new file mode 100644 index 00000000..ffd9c85e --- /dev/null +++ b/7.3.729 @@ -0,0 +1,62 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.729 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.729 +Problem: Building with Ruby fails on some systems. +Solution: Remove "static" and add #ifndef PROTO. (Ken Takata) +Files: src/if_ruby.c + + +*** ../vim-7.3.728/src/if_ruby.c 2012-11-20 16:59:09.000000000 +0100 +--- src/if_ruby.c 2012-11-24 13:32:06.000000000 +0100 +*************** +*** 335,346 **** + static void* (*ruby_process_options)(int, char**); + #endif + +! #ifdef RUBY19_OR_LATER +! static SIGNED_VALUE rb_num2long_stub(VALUE x) + { + return dll_rb_num2long(x); + } +! static VALUE rb_int2big_stub(SIGNED_VALUE x) + { + return dll_rb_int2big(x); + } +--- 335,346 ---- + static void* (*ruby_process_options)(int, char**); + #endif + +! #if defined(RUBY19_OR_LATER) && !defined(PROTO) +! SIGNED_VALUE rb_num2long_stub(VALUE x) + { + return dll_rb_num2long(x); + } +! VALUE rb_int2big_stub(SIGNED_VALUE x) + { + return dll_rb_int2big(x); + } +*** ../vim-7.3.728/src/version.c 2012-11-23 21:54:43.000000000 +0100 +--- src/version.c 2012-11-24 13:34:20.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 729, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +64. The remote to the T.V. is missing...and you don't even care. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ce26e1d6db2eef88e01ba5734485b61e6bb26d44 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:54 +0100 Subject: [PATCH 0608/3340] - patchlevel 730 --- 7.3.730 | 86 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 7.3.730 diff --git a/7.3.730 b/7.3.730 new file mode 100644 index 00000000..29cebe10 --- /dev/null +++ b/7.3.730 @@ -0,0 +1,86 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.730 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.730 +Problem: Crash in PHP file when using syntastic. (Ike Devolder) +Solution: Avoid using NULL pointer. (Christian Brabandt) +Files: src/quickfix.c + + +*** ../vim-7.3.729/src/quickfix.c 2012-11-20 17:55:06.000000000 +0100 +--- src/quickfix.c 2012-11-28 15:20:21.000000000 +0100 +*************** +*** 898,908 **** + * way with ":grep'. + */ + while (qi->qf_listcount > qi->qf_curlist + 1) +- { +- if (wp != NULL && wp->w_llist == qi) +- wp->w_llist = NULL; + qf_free(qi, --qi->qf_listcount); +- } + + /* + * When the stack is full, remove to oldest entry +--- 898,904 ---- +*************** +*** 910,917 **** + */ + if (qi->qf_listcount == LISTCOUNT) + { +- if (wp != NULL && wp->w_llist == qi) +- wp->w_llist = NULL; + qf_free(qi, 0); + for (i = 1; i < LISTCOUNT; ++i) + qi->qf_lists[i - 1] = qi->qf_lists[i]; +--- 906,911 ---- +*************** +*** 2135,2143 **** + while (qi->qf_lists[idx].qf_count) + { + qfp = qi->qf_lists[idx].qf_start->qf_next; +! vim_free(qi->qf_lists[idx].qf_start->qf_text); +! vim_free(qi->qf_lists[idx].qf_start->qf_pattern); +! vim_free(qi->qf_lists[idx].qf_start); + qi->qf_lists[idx].qf_start = qfp; + --qi->qf_lists[idx].qf_count; + } +--- 2129,2140 ---- + while (qi->qf_lists[idx].qf_count) + { + qfp = qi->qf_lists[idx].qf_start->qf_next; +! if (qi->qf_lists[idx].qf_title != NULL) +! { +! vim_free(qi->qf_lists[idx].qf_start->qf_text); +! vim_free(qi->qf_lists[idx].qf_start->qf_pattern); +! vim_free(qi->qf_lists[idx].qf_start); +! } + qi->qf_lists[idx].qf_start = qfp; + --qi->qf_lists[idx].qf_count; + } +*** ../vim-7.3.729/src/version.c 2012-11-24 13:38:56.000000000 +0100 +--- src/version.c 2012-11-28 15:16:16.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 730, + /**/ + + +-- +hundred-and-one symptoms of being an internet addict: +89. In addition to your e-mail address being on your business + cards you even have your own domain. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d766ee9073b4e57ee33468b9a0455c287973e368 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:55 +0100 Subject: [PATCH 0609/3340] - patchlevel 731 --- 7.3.731 | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 7.3.731 diff --git a/7.3.731 b/7.3.731 new file mode 100644 index 00000000..d1a0c236 --- /dev/null +++ b/7.3.731 @@ -0,0 +1,81 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.731 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.731 +Problem: Py3Init_vim() is exported uneccessarily. +Solution: Make it static. (Ken Takata) +Files: src/if_python3.c + + +*** ../vim-7.3.730/src/if_python3.c 2012-11-20 11:02:49.000000000 +0100 +--- src/if_python3.c 2012-11-28 15:32:00.000000000 +0100 +*************** +*** 657,663 **** + static PyObject *globals; + + static int PythonIO_Init(void); +! PyMODINIT_FUNC Py3Init_vim(void); + + /****************************************************** + * 1. Python interpreter main program. +--- 657,663 ---- + static PyObject *globals; + + static int PythonIO_Init(void); +! static PyObject *Py3Init_vim(void); + + /****************************************************** + * 1. Python interpreter main program. +*************** +*** 1773,1780 **** + + static struct PyModuleDef vimmodule; + +! #ifndef PROTO +! PyMODINIT_FUNC Py3Init_vim(void) + { + PyObject *mod; + PyObject *tmp; +--- 1773,1780 ---- + + static struct PyModuleDef vimmodule; + +! static PyObject * +! Py3Init_vim(void) + { + PyObject *mod; + PyObject *tmp; +*************** +*** 1824,1830 **** + + return mod; + } +- #endif + + /************************************************************************* + * 4. Utility functions for handling the interface between Vim and Python. +--- 1824,1829 ---- +*** ../vim-7.3.730/src/version.c 2012-11-28 15:25:28.000000000 +0100 +--- src/version.c 2012-11-28 15:30:47.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 731, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +90. Instead of calling you to dinner, your spouse sends e-mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a35cc376abad96184a6307c15b57f07143128fa5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:56 +0100 Subject: [PATCH 0610/3340] - patchlevel 732 --- 7.3.732 | 130 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 130 insertions(+) create mode 100644 7.3.732 diff --git a/7.3.732 b/7.3.732 new file mode 100644 index 00000000..39a32648 --- /dev/null +++ b/7.3.732 @@ -0,0 +1,130 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.732 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.732 +Problem: Compiler warnings for function arguments. +Solution: Use inteptr_t instead of long. +Files: src/if_mzsch.c + + +*** ../vim-7.3.731/src/if_mzsch.c 2012-10-14 03:41:54.000000000 +0200 +--- src/if_mzsch.c 2012-11-24 14:00:31.000000000 +0100 +*************** +*** 142,148 **** + static int do_mzscheme_command(exarg_T *, void *, Scheme_Closed_Prim *what); + static void startup_mzscheme(void); + static char *string_to_line(Scheme_Object *obj); +! static void do_output(char *mesg, long len); + static void do_printf(char *format, ...); + static void do_flush(void); + static Scheme_Object *_apply_thunk_catch_exceptions( +--- 142,148 ---- + static int do_mzscheme_command(exarg_T *, void *, Scheme_Closed_Prim *what); + static void startup_mzscheme(void); + static char *string_to_line(Scheme_Object *obj); +! static void do_output(char *mesg, intptr_t len); + static void do_printf(char *format, ...); + static void do_flush(void); + static Scheme_Object *_apply_thunk_catch_exceptions( +*************** +*** 1349,1356 **** + } + + static void +! do_output(char *mesg, long len UNUSED) + { + do_intrnl_output(mesg, 0); + } + +--- 1349,1357 ---- + } + + static void +! do_output(char *mesg, intptr_t len UNUSED) + { ++ /* TODO: use len, the string may not be NUL terminated */ + do_intrnl_output(mesg, 0); + } + +*************** +*** 1370,1376 **** + do_flush(void) + { + char *buff; +! long length; + + buff = scheme_get_sized_string_output(curerr, &length); + MZ_GC_CHECK(); +--- 1371,1377 ---- + do_flush(void) + { + char *buff; +! intptr_t length; + + buff = scheme_get_sized_string_output(curerr, &length); + MZ_GC_CHECK(); +*************** +*** 2588,2594 **** + { + char *scheme_str = NULL; + char *vim_str = NULL; +! long len; + int i; + + scheme_str = scheme_display_to_string(obj, &len); +--- 2589,2595 ---- + { + char *scheme_str = NULL; + char *vim_str = NULL; +! intptr_t len; + int i; + + scheme_str = scheme_display_to_string(obj, &len); +*************** +*** 2597,2606 **** + * are replacing a single line, and we must replace it with + * a single line. + */ +! if (memchr(scheme_str, '\n', len)) + scheme_signal_error(_("string cannot contain newlines")); + +! vim_str = (char *)alloc(len + 1); + + /* Create a copy of the string, with internal nulls replaced by + * newline characters, as is the vim convention. +--- 2598,2607 ---- + * are replacing a single line, and we must replace it with + * a single line. + */ +! if (memchr(scheme_str, '\n', (size_t)len)) + scheme_signal_error(_("string cannot contain newlines")); + +! vim_str = (char *)alloc((int)(len + 1)); + + /* Create a copy of the string, with internal nulls replaced by + * newline characters, as is the vim convention. +*** ../vim-7.3.731/src/version.c 2012-11-28 15:33:10.000000000 +0100 +--- src/version.c 2012-11-28 15:34:30.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 732, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +91. It's Saturday afternoon in the middle of May and you + are on computer. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 17c8eede02c105bce1c2642d027b62b2eec05975 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:57 +0100 Subject: [PATCH 0611/3340] - patchlevel 733 --- 7.3.733 | 118 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 118 insertions(+) create mode 100644 7.3.733 diff --git a/7.3.733 b/7.3.733 new file mode 100644 index 00000000..0c0a998f --- /dev/null +++ b/7.3.733 @@ -0,0 +1,118 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.733 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.733 +Problem: Tests fail when including MzScheme. +Solution: Change #ifdefs for vim_main2(). +Files: src/main.c + + +*** ../vim-7.3.732/src/main.c 2012-04-25 18:24:24.000000000 +0200 +--- src/main.c 2012-11-24 14:26:56.000000000 +0100 +*************** +*** 147,154 **** + #define ME_INVALID_ARG 5 + }; + +- #ifndef NO_VIM_MAIN /* skip this for unittests */ + #ifndef PROTO /* don't want a prototype for main() */ + int + # ifdef VIMDLL + _export +--- 147,154 ---- + #define ME_INVALID_ARG 5 + }; + + #ifndef PROTO /* don't want a prototype for main() */ ++ #ifndef NO_VIM_MAIN /* skip this for unittests */ + int + # ifdef VIMDLL + _export +*************** +*** 570,584 **** + return mzscheme_main(2, args); + } + } + +! int vim_main2(int argc, char **argv) + { + char_u *fname = (char_u *)argv[0]; + mparm_T params; + + memcpy(¶ms, argv[1], sizeof(params)); + #endif + + /* Execute --cmd arguments. */ + exe_pre_commands(¶ms); + +--- 570,596 ---- + return mzscheme_main(2, args); + } + } ++ #endif ++ #endif /* NO_VIM_MAIN */ + +! /* vim_main2() needs to be produced when FEAT_MZSCHEME is defined even when +! * NO_VIM_MAIN is defined. */ +! #ifdef FEAT_MZSCHEME +! int +! vim_main2(int argc UNUSED, char **argv UNUSED) + { ++ # ifndef NO_VIM_MAIN + char_u *fname = (char_u *)argv[0]; + mparm_T params; + + memcpy(¶ms, argv[1], sizeof(params)); ++ # else ++ return 0; ++ } ++ # endif + #endif + ++ #ifndef NO_VIM_MAIN + /* Execute --cmd arguments. */ + exe_pre_commands(¶ms); + +*************** +*** 999,1006 **** + + return 0; + } +- #endif /* PROTO */ + #endif /* NO_VIM_MAIN */ + + /* + * Main loop: Execute Normal mode commands until exiting Vim. +--- 1011,1018 ---- + + return 0; + } + #endif /* NO_VIM_MAIN */ ++ #endif /* PROTO */ + + /* + * Main loop: Execute Normal mode commands until exiting Vim. +*** ../vim-7.3.732/src/version.c 2012-11-28 15:37:46.000000000 +0100 +--- src/version.c 2012-11-28 15:54:07.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 733, + /**/ + +-- +From "know your smileys": + :^[/ mean-smiley-with-cigarette + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bfeacfafb20c42995e089fe27f438a50a8002e8e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:58 +0100 Subject: [PATCH 0612/3340] - patchlevel 734 --- 7.3.734 | 125 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 125 insertions(+) create mode 100644 7.3.734 diff --git a/7.3.734 b/7.3.734 new file mode 100644 index 00000000..1b4d16f5 --- /dev/null +++ b/7.3.734 @@ -0,0 +1,125 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.734 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.734 +Problem: Cannot put help files in a sub-directory. +Solution: Make :helptags work for sub-directories. (Charles Campbell) +Files: src/ex_cmds.c + + +*** ../vim-7.3.733/src/ex_cmds.c 2012-09-05 15:15:01.000000000 +0200 +--- src/ex_cmds.c 2012-11-28 15:59:58.000000000 +0100 +*************** +*** 6344,6353 **** + } + + #ifdef FEAT_MULTI_LANG +! /* Get a list of all files in the directory. */ + STRCPY(NameBuff, dirname); + add_pathsep(NameBuff); +! STRCAT(NameBuff, "*"); + if (gen_expand_wildcards(1, &NameBuff, &filecount, &files, + EW_FILE|EW_SILENT) == FAIL + || filecount == 0) +--- 6344,6353 ---- + } + + #ifdef FEAT_MULTI_LANG +! /* Get a list of all files in the help directory and in subdirectories. */ + STRCPY(NameBuff, dirname); + add_pathsep(NameBuff); +! STRCAT(NameBuff, "**"); + if (gen_expand_wildcards(1, &NameBuff, &filecount, &files, + EW_FILE|EW_SILENT) == FAIL + || filecount == 0) +*************** +*** 6436,6443 **** + helptags_one(dir, ext, tagfname, add_help_tags) + char_u *dir; /* doc directory */ + char_u *ext; /* suffix, ".txt", ".itx", ".frx", etc. */ +! char_u *tagfname; /* "tags" for English, "tags-fr" for French. */ +! int add_help_tags; /* add "help-tags" tag */ + { + FILE *fd_tags; + FILE *fd; +--- 6436,6443 ---- + helptags_one(dir, ext, tagfname, add_help_tags) + char_u *dir; /* doc directory */ + char_u *ext; /* suffix, ".txt", ".itx", ".frx", etc. */ +! char_u *tagfname; /* "tags" for English, "tags-fr" for French. */ +! int add_help_tags; /* add "help-tags" tag */ + { + FILE *fd_tags; + FILE *fd; +*************** +*** 6449,6454 **** +--- 6449,6455 ---- + char_u *s; + int i; + char_u *fname; ++ int dirlen; + # ifdef FEAT_MBYTE + int utf8 = MAYBE; + int this_utf8; +*************** +*** 6459,6467 **** + /* + * Find all *.txt files. + */ + STRCPY(NameBuff, dir); +! add_pathsep(NameBuff); +! STRCAT(NameBuff, "*"); + STRCAT(NameBuff, ext); + if (gen_expand_wildcards(1, &NameBuff, &filecount, &files, + EW_FILE|EW_SILENT) == FAIL +--- 6460,6468 ---- + /* + * Find all *.txt files. + */ ++ dirlen = STRLEN(dir); + STRCPY(NameBuff, dir); +! STRCAT(NameBuff, "/**/*"); + STRCAT(NameBuff, ext); + if (gen_expand_wildcards(1, &NameBuff, &filecount, &files, + EW_FILE|EW_SILENT) == FAIL +*************** +*** 6522,6528 **** + EMSG2(_("E153: Unable to open %s for reading"), files[fi]); + continue; + } +! fname = gettail(files[fi]); + + # ifdef FEAT_MBYTE + firstline = TRUE; +--- 6523,6529 ---- + EMSG2(_("E153: Unable to open %s for reading"), files[fi]); + continue; + } +! fname = files[fi] + dirlen + 1; + + # ifdef FEAT_MBYTE + firstline = TRUE; +*** ../vim-7.3.733/src/version.c 2012-11-28 15:55:37.000000000 +0100 +--- src/version.c 2012-11-28 15:58:26.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 734, + /**/ + +-- +From "know your smileys": + y:-) Bad toupee + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4dcbec5a6ba3f23b8ff37eb9232ff4a904eedf03 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:10:59 +0100 Subject: [PATCH 0613/3340] - patchlevel 735 --- 7.3.735 | 100 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 100 insertions(+) create mode 100644 7.3.735 diff --git a/7.3.735 b/7.3.735 new file mode 100644 index 00000000..808bd298 --- /dev/null +++ b/7.3.735 @@ -0,0 +1,100 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.735 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.735 +Problem: Cannot build Ruby 1.9 with MingW or Cygwin. +Solution: Add another include directory. (Ken Takata) +Files: src/Make_cyg.mak, src/Make_ming.mak + + +*** ../vim-7.3.734/src/Make_cyg.mak 2012-07-06 13:40:44.000000000 +0200 +--- src/Make_cyg.mak 2012-11-28 16:14:41.000000000 +0100 +*************** +*** 21,27 **** + # TCL_VER define to version of TCL being used (83) + # DYNAMIC_TCL no or yes: use yes to load the TCL DLL dynamically (yes) + # RUBY define to path to Ruby dir to get Ruby support (not defined) +! # RUBY_VER define to version of Ruby being used (16) + # DYNAMIC_RUBY no or yes: use yes to load the Ruby DLL dynamically (yes) + # MZSCHEME define to path to MzScheme dir to get MZSCHEME support (not defined) + # MZSCHEME_VER define to version of MzScheme being used (209_000) +--- 21,31 ---- + # TCL_VER define to version of TCL being used (83) + # DYNAMIC_TCL no or yes: use yes to load the TCL DLL dynamically (yes) + # RUBY define to path to Ruby dir to get Ruby support (not defined) +! # RUBY_VER define to version of Ruby being used (16) +! # RUBY_VER_LONG same, but in format with dot. (1.6) +! # You must set RUBY_VER_LONG when changing RUBY_VER. +! # You must set RUBY_API_VER version to RUBY_VER_LONG. +! # Don't set ruby API version to RUBY_VER like 191. + # DYNAMIC_RUBY no or yes: use yes to load the Ruby DLL dynamically (yes) + # MZSCHEME define to path to MzScheme dir to get MZSCHEME support (not defined) + # MZSCHEME_VER define to version of MzScheme being used (209_000) +*************** +*** 217,224 **** +--- 221,235 ---- + endif + endif + ++ ifeq (19, $(word 1,$(sort 19 $(RUBY_VER)))) ++ RUBY_19_OR_LATER = 1 ++ endif ++ + DEFINES += -DFEAT_RUBY + INCLUDES += -I$(RUBY)/lib/ruby/$(RUBY_VER_LONG)/$(RUBY_PLATFORM) ++ ifdef RUBY_19_OR_LATER ++ INCLUDES += -I$(RUBY)/include/ruby-$(RUBY_VER_LONG) -I$(RUBY)/include/ruby-$(RUBY_VER_LONG)/$(RUBY_PLATFORM) ++ endif + EXTRA_OBJS += $(OUTDIR)/if_ruby.o + + ifeq (yes, $(DYNAMIC_RUBY)) +*** ../vim-7.3.734/src/Make_ming.mak 2012-09-05 17:57:34.000000000 +0200 +--- src/Make_ming.mak 2012-11-28 16:14:16.000000000 +0100 +*************** +*** 301,307 **** + endif + endif + +! RUBYINC =-I $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/$(RUBY_PLATFORM) -I $(RUBY)/include/ruby-$(RUBY_VER_LONG) -I $(RUBY)/include/ruby-$(RUBY_VER_LONG)/$(RUBY_PLATFORM) + ifeq (no, $(DYNAMIC_RUBY)) + RUBYLIB = -L$(RUBY)/lib -l$(RUBY_INSTALL_NAME) + endif +--- 301,314 ---- + endif + endif + +! ifeq (19, $(word 1,$(sort 19 $(RUBY_VER)))) +! RUBY_19_OR_LATER = 1 +! endif +! +! RUBYINC = -I $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/$(RUBY_PLATFORM) +! ifdef RUBY_19_OR_LATER +! RUBYINC += -I $(RUBY)/include/ruby-$(RUBY_VER_LONG) -I $(RUBY)/include/ruby-$(RUBY_VER_LONG)/$(RUBY_PLATFORM) +! endif + ifeq (no, $(DYNAMIC_RUBY)) + RUBYLIB = -L$(RUBY)/lib -l$(RUBY_INSTALL_NAME) + endif +*** ../vim-7.3.734/src/version.c 2012-11-28 16:06:13.000000000 +0100 +--- src/version.c 2012-11-28 16:16:28.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 735, + /**/ + +-- +From "know your smileys": + :----} You lie like Pinocchio + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 009ecdc89dd7f80055cbcfd17bda16acc3b1dbe4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:00 +0100 Subject: [PATCH 0614/3340] - patchlevel 736 --- 7.3.736 | 258 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 258 insertions(+) create mode 100644 7.3.736 diff --git a/7.3.736 b/7.3.736 new file mode 100644 index 00000000..fa1fceba --- /dev/null +++ b/7.3.736 @@ -0,0 +1,258 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.736 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.736 +Problem: File name completion in input() escapes white space. (Frederic + Hardy) +Solution: Do not escape white space. (Christian Brabandt) +Files: src/ex_getln.c + + +*** ../vim-7.3.735/src/ex_getln.c 2012-10-11 04:04:32.000000000 +0200 +--- src/ex_getln.c 2012-11-28 16:42:12.000000000 +0100 +*************** +*** 102,108 **** + static void redrawcmdprompt __ARGS((void)); + static void cursorcmd __ARGS((void)); + static int ccheck_abbr __ARGS((int)); +! static int nextwild __ARGS((expand_T *xp, int type, int options)); + static void escape_fname __ARGS((char_u **pp)); + static int showmatches __ARGS((expand_T *xp, int wildmenu)); + static void set_expand_context __ARGS((expand_T *xp)); +--- 102,108 ---- + static void redrawcmdprompt __ARGS((void)); + static void cursorcmd __ARGS((void)); + static int ccheck_abbr __ARGS((int)); +! static int nextwild __ARGS((expand_T *xp, int type, int options, int escape)); + static void escape_fname __ARGS((char_u **pp)); + static int showmatches __ARGS((expand_T *xp, int wildmenu)); + static void set_expand_context __ARGS((expand_T *xp)); +*************** +*** 810,818 **** + did_wild_list = TRUE; + } + if (wim_flags[wim_index] & WIM_LONGEST) +! res = nextwild(&xpc, WILD_LONGEST, WILD_NO_BEEP); + else if (wim_flags[wim_index] & WIM_FULL) +! res = nextwild(&xpc, WILD_NEXT, WILD_NO_BEEP); + else + res = OK; /* don't insert 'wildchar' now */ + } +--- 810,820 ---- + did_wild_list = TRUE; + } + if (wim_flags[wim_index] & WIM_LONGEST) +! res = nextwild(&xpc, WILD_LONGEST, WILD_NO_BEEP, +! firstc != '@'); + else if (wim_flags[wim_index] & WIM_FULL) +! res = nextwild(&xpc, WILD_NEXT, WILD_NO_BEEP, +! firstc != '@'); + else + res = OK; /* don't insert 'wildchar' now */ + } +*************** +*** 823,831 **** + /* if 'wildmode' first contains "longest", get longest + * common part */ + if (wim_flags[0] & WIM_LONGEST) +! res = nextwild(&xpc, WILD_LONGEST, WILD_NO_BEEP); + else +! res = nextwild(&xpc, WILD_EXPAND_KEEP, WILD_NO_BEEP); + + /* if interrupted while completing, behave like it failed */ + if (got_int) +--- 825,835 ---- + /* if 'wildmode' first contains "longest", get longest + * common part */ + if (wim_flags[0] & WIM_LONGEST) +! res = nextwild(&xpc, WILD_LONGEST, WILD_NO_BEEP, +! firstc != '@'); + else +! res = nextwild(&xpc, WILD_EXPAND_KEEP, WILD_NO_BEEP, +! firstc != '@'); + + /* if interrupted while completing, behave like it failed */ + if (got_int) +*************** +*** 860,866 **** + int p_wmnu_save = p_wmnu; + p_wmnu = 0; + #endif +! nextwild(&xpc, WILD_PREV, 0); /* remove match */ + #ifdef FEAT_WILDMENU + p_wmnu = p_wmnu_save; + #endif +--- 864,871 ---- + int p_wmnu_save = p_wmnu; + p_wmnu = 0; + #endif +! /* remove match */ +! nextwild(&xpc, WILD_PREV, 0, firstc != '@'); + #ifdef FEAT_WILDMENU + p_wmnu = p_wmnu_save; + #endif +*************** +*** 874,882 **** + redrawcmd(); + did_wild_list = TRUE; + if (wim_flags[wim_index] & WIM_LONGEST) +! nextwild(&xpc, WILD_LONGEST, WILD_NO_BEEP); + else if (wim_flags[wim_index] & WIM_FULL) +! nextwild(&xpc, WILD_NEXT, WILD_NO_BEEP); + } + else + vim_beep(); +--- 879,889 ---- + redrawcmd(); + did_wild_list = TRUE; + if (wim_flags[wim_index] & WIM_LONGEST) +! nextwild(&xpc, WILD_LONGEST, WILD_NO_BEEP, +! firstc != '@'); + else if (wim_flags[wim_index] & WIM_FULL) +! nextwild(&xpc, WILD_NEXT, WILD_NO_BEEP, +! firstc != '@'); + } + else + vim_beep(); +*************** +*** 899,907 **** + /* goes to last match, in a clumsy way */ + if (c == K_S_TAB && KeyTyped) + { +! if (nextwild(&xpc, WILD_EXPAND_KEEP, 0) == OK +! && nextwild(&xpc, WILD_PREV, 0) == OK +! && nextwild(&xpc, WILD_PREV, 0) == OK) + goto cmdline_changed; + } + +--- 906,914 ---- + /* goes to last match, in a clumsy way */ + if (c == K_S_TAB && KeyTyped) + { +! if (nextwild(&xpc, WILD_EXPAND_KEEP, 0, firstc != '@') == OK +! && nextwild(&xpc, WILD_PREV, 0, firstc != '@') == OK +! && nextwild(&xpc, WILD_PREV, 0, firstc != '@') == OK) + goto cmdline_changed; + } + +*************** +*** 1418,1424 **** + goto cmdline_not_changed; + + case Ctrl_A: /* all matches */ +! if (nextwild(&xpc, WILD_ALL, 0) == FAIL) + break; + goto cmdline_changed; + +--- 1425,1431 ---- + goto cmdline_not_changed; + + case Ctrl_A: /* all matches */ +! if (nextwild(&xpc, WILD_ALL, 0, firstc != '@') == FAIL) + break; + goto cmdline_changed; + +*************** +*** 1454,1460 **** + #endif + + /* completion: longest common part */ +! if (nextwild(&xpc, WILD_LONGEST, 0) == FAIL) + break; + goto cmdline_changed; + +--- 1461,1467 ---- + #endif + + /* completion: longest common part */ +! if (nextwild(&xpc, WILD_LONGEST, 0, firstc != '@') == FAIL) + break; + goto cmdline_changed; + +*************** +*** 1462,1469 **** + case Ctrl_P: /* previous match */ + if (xpc.xp_numfiles > 0) + { +! if (nextwild(&xpc, (c == Ctrl_P) ? WILD_PREV : WILD_NEXT, 0) +! == FAIL) + break; + goto cmdline_changed; + } +--- 1469,1476 ---- + case Ctrl_P: /* previous match */ + if (xpc.xp_numfiles > 0) + { +! if (nextwild(&xpc, (c == Ctrl_P) ? WILD_PREV : WILD_NEXT, +! 0, firstc != '@') == FAIL) + break; + goto cmdline_changed; + } +*************** +*** 3338,3347 **** + * normal character (instead of being expanded). This allows :s/^I^D etc. + */ + static int +! nextwild(xp, type, options) + expand_T *xp; + int type; + int options; /* extra options for ExpandOne() */ + { + int i, j; + char_u *p1; +--- 3345,3355 ---- + * normal character (instead of being expanded). This allows :s/^I^D etc. + */ + static int +! nextwild(xp, type, options, escape) + expand_T *xp; + int type; + int options; /* extra options for ExpandOne() */ ++ int escape; /* if TRUE, escape the returned matches */ + { + int i, j; + char_u *p1; +*************** +*** 3390,3396 **** + else + { + int use_options = options | +! WILD_HOME_REPLACE|WILD_ADD_SLASH|WILD_SILENT|WILD_ESCAPE; + + if (p_wic) + use_options += WILD_ICASE; +--- 3398,3406 ---- + else + { + int use_options = options | +! WILD_HOME_REPLACE|WILD_ADD_SLASH|WILD_SILENT; +! if (escape) +! use_options |= WILD_ESCAPE; + + if (p_wic) + use_options += WILD_ICASE; +*** ../vim-7.3.735/src/version.c 2012-11-28 16:18:26.000000000 +0100 +--- src/version.c 2012-11-28 16:30:45.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 736, + /**/ + +-- +From "know your smileys": + ;-0 Can't find shift key + ,-9 Kann Umschalttaste nicht finden + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 493964e6c35ba920fa25dd0f89268731a50d6c1f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:01 +0100 Subject: [PATCH 0615/3340] - patchlevel 737 --- 7.3.737 | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 7.3.737 diff --git a/7.3.737 b/7.3.737 new file mode 100644 index 00000000..44aeafa5 --- /dev/null +++ b/7.3.737 @@ -0,0 +1,49 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.737 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.737 +Problem: When using do_cmdline() recursively did_endif is not reset, + causing messages to be overwritten. +Solution: Reset did_endif. (Christian Brabandt) +Files: src/ex_docmd.c + + +*** ../vim-7.3.736/src/ex_docmd.c 2012-10-03 18:24:55.000000000 +0200 +--- src/ex_docmd.c 2012-11-28 17:25:27.000000000 +0100 +*************** +*** 1536,1541 **** +--- 1536,1543 ---- + if_level = 0; + #endif + ++ did_endif = FALSE; /* in case do_cmdline used recursively */ ++ + --call_depth; + return retval; + } +*** ../vim-7.3.736/src/version.c 2012-11-28 16:49:53.000000000 +0100 +--- src/version.c 2012-11-28 17:33:54.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 737, + /**/ + +-- +From "know your smileys": + :-) Funny + |-) Funny Oriental + (-: Funny Australian + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a34cda23ed87e4072c0741da3b5893e87e06def8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:02 +0100 Subject: [PATCH 0616/3340] - patchlevel 738 --- 7.3.738 | 142 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 142 insertions(+) create mode 100644 7.3.738 diff --git a/7.3.738 b/7.3.738 new file mode 100644 index 00000000..59adfc53 --- /dev/null +++ b/7.3.738 @@ -0,0 +1,142 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.738 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.738 (after 7.3.730) +Problem: Unused function argument. +Solution: Remove it. (Christian Brabandt) +Files: src/quickfix.c + + +*** ../vim-7.3.737/src/quickfix.c 2012-11-28 15:25:28.000000000 +0100 +--- src/quickfix.c 2012-11-28 17:36:26.000000000 +0100 +*************** +*** 107,113 **** + }; + + static int qf_init_ext __ARGS((qf_info_T *qi, char_u *efile, buf_T *buf, typval_T *tv, char_u *errorformat, int newlist, linenr_T lnumfirst, linenr_T lnumlast, char_u *qf_title)); +! static void qf_new_list __ARGS((qf_info_T *qi, char_u *qf_title, win_T *wp)); + static void ll_free_all __ARGS((qf_info_T **pqi)); + static int qf_add_entry __ARGS((qf_info_T *qi, qfline_T **prevp, char_u *dir, char_u *fname, int bufnum, char_u *mesg, long lnum, int col, int vis_col, char_u *pattern, int nr, int type, int valid)); + static qf_info_T *ll_new_list __ARGS((void)); +--- 107,113 ---- + }; + + static int qf_init_ext __ARGS((qf_info_T *qi, char_u *efile, buf_T *buf, typval_T *tv, char_u *errorformat, int newlist, linenr_T lnumfirst, linenr_T lnumlast, char_u *qf_title)); +! static void qf_new_list __ARGS((qf_info_T *qi, char_u *qf_title)); + static void ll_free_all __ARGS((qf_info_T **pqi)); + static int qf_add_entry __ARGS((qf_info_T *qi, qfline_T **prevp, char_u *dir, char_u *fname, int bufnum, char_u *mesg, long lnum, int col, int vis_col, char_u *pattern, int nr, int type, int valid)); + static qf_info_T *ll_new_list __ARGS((void)); +*************** +*** 266,272 **** + + if (newlist || qi->qf_curlist == qi->qf_listcount) + /* make place for a new list */ +! qf_new_list(qi, qf_title, curwin); + else if (qi->qf_lists[qi->qf_curlist].qf_count > 0) + /* Adding to existing list, find last entry. */ + for (qfprev = qi->qf_lists[qi->qf_curlist].qf_start; +--- 266,272 ---- + + if (newlist || qi->qf_curlist == qi->qf_listcount) + /* make place for a new list */ +! qf_new_list(qi, qf_title); + else if (qi->qf_lists[qi->qf_curlist].qf_count > 0) + /* Adding to existing list, find last entry. */ + for (qfprev = qi->qf_lists[qi->qf_curlist].qf_start; +*************** +*** 885,894 **** + * Prepare for adding a new quickfix list. + */ + static void +! qf_new_list(qi, qf_title, wp) + qf_info_T *qi; + char_u *qf_title; +- win_T *wp; + { + int i; + +--- 885,893 ---- + * Prepare for adding a new quickfix list. + */ + static void +! qf_new_list(qi, qf_title) + qf_info_T *qi; + char_u *qf_title; + { + int i; + +*************** +*** 3187,3193 **** + eap->cmdidx != CMD_vimgrepadd && eap->cmdidx != CMD_lvimgrepadd) + || qi->qf_curlist == qi->qf_listcount) + /* make place for a new list */ +! qf_new_list(qi, *eap->cmdlinep, curwin); + else if (qi->qf_lists[qi->qf_curlist].qf_count > 0) + /* Adding to existing list, find last entry. */ + for (prevp = qi->qf_lists[qi->qf_curlist].qf_start; +--- 3186,3192 ---- + eap->cmdidx != CMD_vimgrepadd && eap->cmdidx != CMD_lvimgrepadd) + || qi->qf_curlist == qi->qf_listcount) + /* make place for a new list */ +! qf_new_list(qi, *eap->cmdlinep); + else if (qi->qf_lists[qi->qf_curlist].qf_count > 0) + /* Adding to existing list, find last entry. */ + for (prevp = qi->qf_lists[qi->qf_curlist].qf_start; +*************** +*** 3753,3759 **** + + if (action == ' ' || qi->qf_curlist == qi->qf_listcount) + /* make place for a new list */ +! qf_new_list(qi, title, wp); + else if (action == 'a' && qi->qf_lists[qi->qf_curlist].qf_count > 0) + /* Adding to existing list, find last entry. */ + for (prevp = qi->qf_lists[qi->qf_curlist].qf_start; +--- 3752,3758 ---- + + if (action == ' ' || qi->qf_curlist == qi->qf_listcount) + /* make place for a new list */ +! qf_new_list(qi, title); + else if (action == 'a' && qi->qf_lists[qi->qf_curlist].qf_count > 0) + /* Adding to existing list, find last entry. */ + for (prevp = qi->qf_lists[qi->qf_curlist].qf_start; +*************** +*** 4035,4041 **** + #endif + + /* create a new quickfix list */ +! qf_new_list(qi, *eap->cmdlinep, wp); + + /* Go through all directories in 'runtimepath' */ + p = p_rtp; +--- 4034,4040 ---- + #endif + + /* create a new quickfix list */ +! qf_new_list(qi, *eap->cmdlinep); + + /* Go through all directories in 'runtimepath' */ + p = p_rtp; +*** ../vim-7.3.737/src/version.c 2012-11-28 17:34:43.000000000 +0100 +--- src/version.c 2012-11-28 17:37:20.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 738, + /**/ + +-- +From "know your smileys": + :-H Is missing teeth + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d5cd99b5a1f9377c8047d9397e589e0855c7d5db Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:03 +0100 Subject: [PATCH 0617/3340] - patchlevel 739 --- 7.3.739 | 86 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 7.3.739 diff --git a/7.3.739 b/7.3.739 new file mode 100644 index 00000000..88a81f38 --- /dev/null +++ b/7.3.739 @@ -0,0 +1,86 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.739 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.739 +Problem: Computing number of lines may have an integer overflow. +Solution: Check for MAXCOL explicitly. (Dominique Pelle) +Files: src/move.c + + +*** ../vim-7.3.738/src/move.c 2012-03-28 14:19:46.000000000 +0200 +--- src/move.c 2012-11-28 18:15:42.000000000 +0100 +*************** +*** 2576,2582 **** + else + topline_back(lp); + h2 = lp->height; +! if (h2 + h1 > min_height) + { + *lp = loff0; /* no overlap */ + return; +--- 2576,2582 ---- + else + topline_back(lp); + h2 = lp->height; +! if (h2 == MAXCOL || h2 + h1 > min_height) + { + *lp = loff0; /* no overlap */ + return; +*************** +*** 2588,2594 **** + else + topline_back(lp); + h3 = lp->height; +! if (h3 + h2 > min_height) + { + *lp = loff0; /* no overlap */ + return; +--- 2588,2594 ---- + else + topline_back(lp); + h3 = lp->height; +! if (h3 == MAXCOL || h3 + h2 > min_height) + { + *lp = loff0; /* no overlap */ + return; +*************** +*** 2600,2606 **** + else + topline_back(lp); + h4 = lp->height; +! if (h4 + h3 + h2 > min_height || h3 + h2 + h1 > min_height) + *lp = loff1; /* 1 line overlap */ + else + *lp = loff2; /* 2 lines overlap */ +--- 2600,2606 ---- + else + topline_back(lp); + h4 = lp->height; +! if (h4 == MAXCOL || h4 + h3 + h2 > min_height || h3 + h2 + h1 > min_height) + *lp = loff1; /* 1 line overlap */ + else + *lp = loff2; /* 2 lines overlap */ +*** ../vim-7.3.738/src/version.c 2012-11-28 17:41:55.000000000 +0100 +--- src/version.c 2012-11-28 18:16:40.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 739, + /**/ + +-- +From "know your smileys": + !-| I-am-a-Cylon-Centurian-with-one-red-eye-bouncing-back-and-forth + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5b33a384250fc3ce46b481be87107c595ea1cd83 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:04 +0100 Subject: [PATCH 0618/3340] - patchlevel 740 --- 7.3.740 | 168 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 168 insertions(+) create mode 100644 7.3.740 diff --git a/7.3.740 b/7.3.740 new file mode 100644 index 00000000..80c7609e --- /dev/null +++ b/7.3.740 @@ -0,0 +1,168 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.740 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.740 +Problem: IOC tool complains about undefined behavior for int. +Solution: Change to unsigned int. (Dominique Pelle) +Files: src/hashtab.c, src/misc2.c + + +*** ../vim-7.3.739/src/hashtab.c 2010-08-15 21:57:25.000000000 +0200 +--- src/hashtab.c 2012-11-28 18:27:46.000000000 +0100 +*************** +*** 138,144 **** + hash_T perturb; + hashitem_T *freeitem; + hashitem_T *hi; +! int idx; + + #ifdef HT_DEBUG + ++hash_count_lookup; +--- 138,144 ---- + hash_T perturb; + hashitem_T *freeitem; + hashitem_T *hi; +! unsigned idx; + + #ifdef HT_DEBUG + ++hash_count_lookup; +*************** +*** 150,156 **** + * - skip over a removed item + * - return if the item matches + */ +! idx = (int)(hash & ht->ht_mask); + hi = &ht->ht_array[idx]; + + if (hi->hi_key == NULL) +--- 150,156 ---- + * - skip over a removed item + * - return if the item matches + */ +! idx = (unsigned)(hash & ht->ht_mask); + hi = &ht->ht_array[idx]; + + if (hi->hi_key == NULL) +*************** +*** 176,182 **** + #ifdef HT_DEBUG + ++hash_count_perturb; /* count a "miss" for hashtab lookup */ + #endif +! idx = (int)((idx << 2) + idx + perturb + 1); + hi = &ht->ht_array[idx & ht->ht_mask]; + if (hi->hi_key == NULL) + return freeitem == NULL ? hi : freeitem; +--- 176,182 ---- + #ifdef HT_DEBUG + ++hash_count_perturb; /* count a "miss" for hashtab lookup */ + #endif +! idx = (unsigned)((idx << 2U) + idx + perturb + 1U); + hi = &ht->ht_array[idx & ht->ht_mask]; + if (hi->hi_key == NULL) + return freeitem == NULL ? hi : freeitem; +*************** +*** 342,348 **** + hashitem_T temparray[HT_INIT_SIZE]; + hashitem_T *oldarray, *newarray; + hashitem_T *olditem, *newitem; +! int newi; + int todo; + long_u oldsize, newsize; + long_u minsize; +--- 342,348 ---- + hashitem_T temparray[HT_INIT_SIZE]; + hashitem_T *oldarray, *newarray; + hashitem_T *olditem, *newitem; +! unsigned newi; + int todo; + long_u oldsize, newsize; + long_u minsize; +*************** +*** 448,460 **** + * the algorithm to find an item in hash_lookup(). But we only + * need to search for a NULL key, thus it's simpler. + */ +! newi = (int)(olditem->hi_hash & newmask); + newitem = &newarray[newi]; + + if (newitem->hi_key != NULL) + for (perturb = olditem->hi_hash; ; perturb >>= PERTURB_SHIFT) + { +! newi = (int)((newi << 2) + newi + perturb + 1); + newitem = &newarray[newi & newmask]; + if (newitem->hi_key == NULL) + break; +--- 448,460 ---- + * the algorithm to find an item in hash_lookup(). But we only + * need to search for a NULL key, thus it's simpler. + */ +! newi = (unsigned)(olditem->hi_hash & newmask); + newitem = &newarray[newi]; + + if (newitem->hi_key != NULL) + for (perturb = olditem->hi_hash; ; perturb >>= PERTURB_SHIFT) + { +! newi = (unsigned)((newi << 2U) + newi + perturb + 1U); + newitem = &newarray[newi & newmask]; + if (newitem->hi_key == NULL) + break; +*** ../vim-7.3.739/src/misc2.c 2012-08-15 16:20:59.000000000 +0200 +--- src/misc2.c 2012-11-28 18:27:46.000000000 +0100 +*************** +*** 3860,3866 **** + ush temp; \ + \ + temp = (ush)keys[2] | 2; \ +! t = (int)(((unsigned)(temp * (temp ^ 1)) >> 8) & 0xff); \ + } + + /* +--- 3860,3866 ---- + ush temp; \ + \ + temp = (ush)keys[2] | 2; \ +! t = (int)(((unsigned)(temp * (temp ^ 1U)) >> 8) & 0xff); \ + } + + /* +*************** +*** 4002,4008 **** + ush temp; + + temp = (ush)keys[2] | 2; +! temp = (int)(((unsigned)(temp * (temp ^ 1)) >> 8) & 0xff); + UPDATE_KEYS_ZIP(*p ^= temp); + } + else +--- 4002,4008 ---- + ush temp; + + temp = (ush)keys[2] | 2; +! temp = (int)(((unsigned)(temp * (temp ^ 1U)) >> 8) & 0xff); + UPDATE_KEYS_ZIP(*p ^= temp); + } + else +*** ../vim-7.3.739/src/version.c 2012-11-28 18:22:04.000000000 +0100 +--- src/version.c 2012-11-28 18:28:00.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 740, + /**/ + +-- +From "know your smileys": + ~#:-( I just washed my hair, and I can't do nuthin' with it. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5b71a1eff19aeedefa9d193c29b438df5c47a78d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:05 +0100 Subject: [PATCH 0619/3340] - patchlevel 741 --- 7.3.741 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.741 diff --git a/7.3.741 b/7.3.741 new file mode 100644 index 00000000..d7f5c899 --- /dev/null +++ b/7.3.741 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.741 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.741 (after 7.3.737) +Problem: Tiny build fails. +Solution: Move #ifdef. (Ike Devolder) +Files: src/ex_docmd.c + + +*** ../vim-7.3.740/src/ex_docmd.c 2012-11-28 17:34:43.000000000 +0100 +--- src/ex_docmd.c 2012-11-28 19:09:39.000000000 +0100 +*************** +*** 1534,1542 **** + * ":endif" (could be ":if x | foo | endif"). + */ + if_level = 0; +- #endif + + did_endif = FALSE; /* in case do_cmdline used recursively */ + + --call_depth; + return retval; +--- 1534,1542 ---- + * ":endif" (could be ":if x | foo | endif"). + */ + if_level = 0; + + did_endif = FALSE; /* in case do_cmdline used recursively */ ++ #endif + + --call_depth; + return retval; +*** ../vim-7.3.740/src/version.c 2012-11-28 18:31:49.000000000 +0100 +--- src/version.c 2012-11-28 19:09:15.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 741, + /**/ + +-- +From "know your smileys": + :-O>-o Smiley American tourist (note big mouth and camera) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7e2ed2f64942b48f95f1148b8cc6439fe8298d66 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:06 +0100 Subject: [PATCH 0620/3340] - patchlevel 742 --- 7.3.742 | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 7.3.742 diff --git a/7.3.742 b/7.3.742 new file mode 100644 index 00000000..7bf6963b --- /dev/null +++ b/7.3.742 @@ -0,0 +1,44 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.742 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.742 +Problem: Leaking memory when :vimgrep restores the directory. +Solution: Free the allocated memory. (Christian Brabandt) +Files: src/quickfix.c + + +*** ../vim-7.3.741/src/quickfix.c 2012-11-28 17:41:55.000000000 +0100 +--- src/quickfix.c 2012-11-28 22:09:40.000000000 +0100 +*************** +*** 3515,3520 **** +--- 3515,3521 ---- + ea.cmdidx = (curwin->w_localdir == NULL) ? CMD_cd : CMD_lcd; + ex_cd(&ea); + } ++ vim_free(dirname_now); + } + } + +*** ../vim-7.3.741/src/version.c 2012-11-28 19:10:51.000000000 +0100 +--- src/version.c 2012-11-28 22:11:50.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 742, + /**/ + +-- +How many light bulbs does it take to change a person? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ee0e8388b2bcb25e3ee8829381552dd26b589881 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:07 +0100 Subject: [PATCH 0621/3340] - patchlevel 743 --- 7.3.743 | 66 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) create mode 100644 7.3.743 diff --git a/7.3.743 b/7.3.743 new file mode 100644 index 00000000..f91a6569 --- /dev/null +++ b/7.3.743 @@ -0,0 +1,66 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.743 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.743 (after 7.3.741) +Problem: Tiny build still fails. +Solution: Add #else in the right place. +Files: src/ex_docmd.c + + +*** ../vim-7.3.742/src/ex_docmd.c 2012-11-28 19:10:51.000000000 +0100 +--- src/ex_docmd.c 2012-11-28 22:14:21.000000000 +0100 +*************** +*** 1528,1541 **** + } + } + +! #ifndef FEAT_EVAL + /* + * Reset if_level, in case a sourced script file contains more ":if" than + * ":endif" (could be ":if x | foo | endif"). + */ + if_level = 0; +- +- did_endif = FALSE; /* in case do_cmdline used recursively */ + #endif + + --call_depth; +--- 1528,1541 ---- + } + } + +! #ifdef FEAT_EVAL +! did_endif = FALSE; /* in case do_cmdline used recursively */ +! #else + /* + * Reset if_level, in case a sourced script file contains more ":if" than + * ":endif" (could be ":if x | foo | endif"). + */ + if_level = 0; + #endif + + --call_depth; +*** ../vim-7.3.742/src/version.c 2012-11-28 22:12:40.000000000 +0100 +--- src/version.c 2012-11-28 22:15:15.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 743, + /**/ + +-- +From "know your smileys": + :-)-O Smiling doctor with stethoscope + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0cf2a3c1919464c9181dd4293d21f6d5c0c6028b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:08 +0100 Subject: [PATCH 0622/3340] - patchlevel 744 --- 7.3.744 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.744 diff --git a/7.3.744 b/7.3.744 new file mode 100644 index 00000000..518617ad --- /dev/null +++ b/7.3.744 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.744 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.744 +Problem: 64 bit compiler warning. +Solution: Add type cast. (Mike Williams) +Files: src/ex_cmds.c + + +*** ../vim-7.3.743/src/ex_cmds.c 2012-11-28 16:06:13.000000000 +0100 +--- src/ex_cmds.c 2012-11-29 20:08:10.000000000 +0100 +*************** +*** 6460,6466 **** + /* + * Find all *.txt files. + */ +! dirlen = STRLEN(dir); + STRCPY(NameBuff, dir); + STRCAT(NameBuff, "/**/*"); + STRCAT(NameBuff, ext); +--- 6460,6466 ---- + /* + * Find all *.txt files. + */ +! dirlen = (int)STRLEN(dir); + STRCPY(NameBuff, dir); + STRCAT(NameBuff, "/**/*"); + STRCAT(NameBuff, ext); +*** ../vim-7.3.743/src/version.c 2012-11-28 23:03:02.000000000 +0100 +--- src/version.c 2012-11-29 20:08:37.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 744, + /**/ + +-- +From "know your smileys": + *<|:-) Santa Claus (Ho Ho Ho) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d09cc44bba64d85124a630587e54979c35213443 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:09 +0100 Subject: [PATCH 0623/3340] - patchlevel 745 --- 7.3.745 | 87 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 87 insertions(+) create mode 100644 7.3.745 diff --git a/7.3.745 b/7.3.745 new file mode 100644 index 00000000..2ef2483b --- /dev/null +++ b/7.3.745 @@ -0,0 +1,87 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.745 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.745 +Problem: Automatically setting 'ttymouse' doesn't work. +Solution: Reset the "option was set" flag when using the default. +Files: src/option.c, src/proto/option.pro, src/term.c + + +*** ../vim-7.3.744/src/option.c 2012-10-21 03:45:57.000000000 +0200 +--- src/option.c 2012-12-03 20:07:32.000000000 +0100 +*************** +*** 11179,11184 **** +--- 11179,11197 ---- + } + + /* ++ * Reset the flag indicating option "name" was set. ++ */ ++ void ++ reset_option_was_set(name) ++ char_u *name; ++ { ++ int idx = findoption(name); ++ ++ if (idx >= 0) ++ options[idx].flags &= ~P_WAS_SET; ++ } ++ ++ /* + * compatible_set() - Called when 'compatible' has been set or unset. + * + * When 'compatible' set: Set all relevant options (those that have the P_VIM) +*** ../vim-7.3.744/src/proto/option.pro 2012-10-21 00:10:29.000000000 +0200 +--- src/proto/option.pro 2012-12-03 20:08:36.000000000 +0100 +*************** +*** 52,57 **** +--- 52,58 ---- + void vimrc_found __ARGS((char_u *fname, char_u *envname)); + void change_compatible __ARGS((int on)); + int option_was_set __ARGS((char_u *name)); ++ void reset_option_was_set __ARGS((char_u *name)); + int can_bs __ARGS((int what)); + void save_file_ff __ARGS((buf_T *buf)); + int file_ff_differs __ARGS((buf_T *buf, int ignore_empty)); +*** ../vim-7.3.744/src/term.c 2012-10-21 02:10:20.000000000 +0200 +--- src/term.c 2012-12-03 20:09:28.000000000 +0100 +*************** +*** 1864,1870 **** +--- 1864,1875 ---- + } + # endif + if (p != NULL) ++ { + set_option_value((char_u *)"ttym", 0L, p, 0); ++ /* Reset the WAS_SET flag, 'ttymouse' can be set to "sgr" or ++ * "xterm2" in check_termcode(). */ ++ reset_option_was_set((char_u *)"ttym"); ++ } + if (p == NULL + # ifdef FEAT_GUI + || gui.in_use +*** ../vim-7.3.744/src/version.c 2012-11-29 20:09:55.000000000 +0100 +--- src/version.c 2012-12-05 14:39:33.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 745, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +97. Your mother tells you to remember something, and you look for + a File/Save command. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 152f0f572ade93ee9e9d57542a9ff42ed1ba2760 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:10 +0100 Subject: [PATCH 0624/3340] - patchlevel 746 --- 7.3.746 | 96 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 96 insertions(+) create mode 100644 7.3.746 diff --git a/7.3.746 b/7.3.746 new file mode 100644 index 00000000..f5b4cfad --- /dev/null +++ b/7.3.746 @@ -0,0 +1,96 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.746 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.746 +Problem: Memory leaks when using location lists. +Solution: Set qf_title to something. (Christian Brabandt) +Files: src/eval.c, src/quickfix.c + + +*** ../vim-7.3.745/src/eval.c 2012-10-21 23:55:59.000000000 +0200 +--- src/eval.c 2012-12-05 14:47:56.000000000 +0100 +*************** +*** 16292,16298 **** + action = *act; + } + +! if (l != NULL && set_errorlist(wp, l, action, NULL) == OK) + rettv->vval.v_number = 0; + } + #endif +--- 16292,16299 ---- + action = *act; + } + +! if (l != NULL && set_errorlist(wp, l, action, +! (char_u *)(wp == NULL ? "setqflist()" : "setloclist()")) == OK) + rettv->vval.v_number = 0; + } + #endif +*** ../vim-7.3.745/src/quickfix.c 2012-11-28 22:12:40.000000000 +0100 +--- src/quickfix.c 2012-12-05 14:51:52.000000000 +0100 +*************** +*** 2124,2138 **** + int idx; + { + qfline_T *qfp; + + while (qi->qf_lists[idx].qf_count) + { + qfp = qi->qf_lists[idx].qf_start->qf_next; +! if (qi->qf_lists[idx].qf_title != NULL) + { + vim_free(qi->qf_lists[idx].qf_start->qf_text); + vim_free(qi->qf_lists[idx].qf_start->qf_pattern); + vim_free(qi->qf_lists[idx].qf_start); + } + qi->qf_lists[idx].qf_start = qfp; + --qi->qf_lists[idx].qf_count; +--- 2124,2145 ---- + int idx; + { + qfline_T *qfp; ++ int stop = FALSE; + + while (qi->qf_lists[idx].qf_count) + { + qfp = qi->qf_lists[idx].qf_start->qf_next; +! if (qi->qf_lists[idx].qf_title != NULL && !stop) + { + vim_free(qi->qf_lists[idx].qf_start->qf_text); ++ stop = (qi->qf_lists[idx].qf_start == qfp); + vim_free(qi->qf_lists[idx].qf_start->qf_pattern); + vim_free(qi->qf_lists[idx].qf_start); ++ if (stop) ++ /* Somehow qf_count may have an incorrect value, set it to 1 ++ * to avoid crashing when it's wrong. ++ * TODO: Avoid qf_count being incorrect. */ ++ qi->qf_lists[idx].qf_count = 1; + } + qi->qf_lists[idx].qf_start = qfp; + --qi->qf_lists[idx].qf_count; +*** ../vim-7.3.745/src/version.c 2012-12-05 14:42:56.000000000 +0100 +--- src/version.c 2012-12-05 15:15:45.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 746, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +98. The Alta Vista administrators ask you what sites are missing + in their index files. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2ddae5093a4604272e68f2a8e1ac4b71ffa4f929 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:11 +0100 Subject: [PATCH 0625/3340] - patchlevel 747 --- 7.3.747 | 67 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 7.3.747 diff --git a/7.3.747 b/7.3.747 new file mode 100644 index 00000000..158c233b --- /dev/null +++ b/7.3.747 @@ -0,0 +1,67 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.747 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.747 +Problem: When characters are concealed text aligned with tabs are no longer + aligned, e.g. at ":help :index". +Solution: Compensate space for tabs for concealed characters. (Dominique + Pelle) +Files: src/screen.c + + +*** ../vim-7.3.746/src/screen.c 2012-10-03 18:24:55.000000000 +0200 +--- src/screen.c 2012-12-05 15:22:03.000000000 +0100 +*************** +*** 4269,4275 **** + { + /* tab amount depends on current column */ + n_extra = (int)wp->w_buffer->b_p_ts +! - VCOL_HLC % (int)wp->w_buffer->b_p_ts - 1; + #ifdef FEAT_MBYTE + mb_utf8 = FALSE; /* don't draw as UTF-8 */ + #endif +--- 4269,4288 ---- + { + /* tab amount depends on current column */ + n_extra = (int)wp->w_buffer->b_p_ts +! - vcol % (int)wp->w_buffer->b_p_ts - 1; +! #ifdef FEAT_CONCEAL +! /* Tab alignment should be identical regardless of +! * 'conceallevel' value. So tab compensates of all +! * previous concealed characters, and thus resets vcol_off +! * and boguscols accumulated so far in the line. Note that +! * the tab can be longer than 'tabstop' when there +! * are concealed characters. */ +! n_extra += vcol_off; +! vcol -= vcol_off; +! vcol_off = 0; +! col -= boguscols; +! boguscols = 0; +! #endif + #ifdef FEAT_MBYTE + mb_utf8 = FALSE; /* don't draw as UTF-8 */ + #endif +*** ../vim-7.3.746/src/version.c 2012-12-05 15:16:42.000000000 +0100 +--- src/version.c 2012-12-05 15:22:27.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 747, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +99. The hum of a cooling fan and the click of keys is comforting to you. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9fcb8d7a9ba63bb90cd5df727d182e002550aa40 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:12 +0100 Subject: [PATCH 0626/3340] - patchlevel 748 --- 7.3.748 | 473 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 473 insertions(+) create mode 100644 7.3.748 diff --git a/7.3.748 b/7.3.748 new file mode 100644 index 00000000..3148bd5b --- /dev/null +++ b/7.3.748 @@ -0,0 +1,473 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.748 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.748 +Problem: Cannot properly test conceal mode. +Solution: Add the screencol() and screenrow() functions. Use them in + test88. (Simon Ruderich) +Files: runtime/doc/eval.txt, src/eval.c, src/proto/screen.pro, + src/screen.c, src/testdir/Make_amiga.mak, + src/testdir/Make_dos.mak, src/testdir/Make_ming.mak, + src/testdir/Make_os2.mak, src/testdir/Make_vms.mms + src/testdir/Makefile, src/testdir/test88.in, + src/testdir/test88.ok + + +*** ../vim-7.3.747/runtime/doc/eval.txt 2012-11-14 18:10:49.000000000 +0100 +--- runtime/doc/eval.txt 2012-12-05 15:45:34.000000000 +0100 +*************** +*** 1892,1897 **** +--- 1903,1910 ---- + resolve( {filename}) String get filename a shortcut points to + reverse( {list}) List reverse {list} in-place + round( {expr}) Float round off {expr} ++ screencol() Number current cursor column ++ screenrow() Number current cursor row + search( {pattern} [, {flags} [, {stopline} [, {timeout}]]]) + Number search for {pattern} + searchdecl( {name} [, {global} [, {thisblock}]]) +*************** +*** 4848,4862 **** + echo round(-4.5) + < -5.0 + {only available when compiled with the |+float| feature} +! +! + search({pattern} [, {flags} [, {stopline} [, {timeout}]]]) *search()* + Search for regexp pattern {pattern}. The search starts at the + cursor position (you can use |cursor()| to set it). + + If there is no match a 0 is returned and the cursor doesn't + move. No error message is given. +- When a match has been found its line number is returned. + + {flags} is a String, which can contain these character flags: + 'b' search backward instead of forward +--- 4874,4907 ---- + echo round(-4.5) + < -5.0 + {only available when compiled with the |+float| feature} +! +! screencol() *screencol()* +! The result is a Number, which is the current screen column of +! the cursor. The leftmost column has number 1. +! This function is mainly used for testing. +! +! Note: Always returns the current screen column, thus if used +! in a command (e.g. ":echo screencol()") it will return the +! column inside the command line, which is 1 when the command is +! executed. To get the cursor position in the file use one of +! the following mappings: > +! nnoremap GG ":echom ".screencol()."\n" +! nnoremap GG :echom screencol() +! < +! screenrow() *screenrow()* +! The result is a Number, which is the current screen row of the +! cursor. The top line has number one. +! This function is mainly used for testing. +! +! Note: Same restrictions as with |screencol()|. +! + search({pattern} [, {flags} [, {stopline} [, {timeout}]]]) *search()* + Search for regexp pattern {pattern}. The search starts at the + cursor position (you can use |cursor()| to set it). + ++ When a match has been found its line number is returned. + If there is no match a 0 is returned and the cursor doesn't + move. No error message is given. + + {flags} is a String, which can contain these character flags: + 'b' search backward instead of forward +*** ../vim-7.3.747/src/eval.c 2012-12-05 15:16:42.000000000 +0100 +--- src/eval.c 2012-12-05 16:03:23.000000000 +0100 +*************** +*** 668,673 **** +--- 668,675 ---- + #ifdef FEAT_FLOAT + static void f_round __ARGS((typval_T *argvars, typval_T *rettv)); + #endif ++ static void f_screencol __ARGS((typval_T *argvars, typval_T *rettv)); ++ static void f_screenrow __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_search __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_searchdecl __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_searchpair __ARGS((typval_T *argvars, typval_T *rettv)); +*************** +*** 8033,8038 **** +--- 8035,8042 ---- + #ifdef FEAT_FLOAT + {"round", 1, 1, f_round}, + #endif ++ {"screencol", 0, 0, f_screencol}, ++ {"screenrow", 0, 0, f_screenrow}, + {"search", 1, 4, f_search}, + {"searchdecl", 1, 3, f_searchdecl}, + {"searchpair", 3, 7, f_searchpair}, +*************** +*** 15725,15730 **** +--- 15729,15758 ---- + #endif + + /* ++ * "screencol()" function ++ * ++ * First column is 1 to be consistent with virtcol(). ++ */ ++ static void ++ f_screencol(argvars, rettv) ++ typval_T *argvars UNUSED; ++ typval_T *rettv; ++ { ++ rettv->vval.v_number = screen_screencol() + 1; ++ } ++ ++ /* ++ * "screenrow()" function ++ */ ++ static void ++ f_screenrow(argvars, rettv) ++ typval_T *argvars UNUSED; ++ typval_T *rettv; ++ { ++ rettv->vval.v_number = screen_screenrow() + 1; ++ } ++ ++ /* + * "search()" function + */ + static void +*** ../vim-7.3.747/src/proto/screen.pro 2012-11-20 16:56:49.000000000 +0100 +--- src/proto/screen.pro 2012-12-05 15:57:35.000000000 +0100 +*************** +*** 50,53 **** +--- 50,55 ---- + int messaging __ARGS((void)); + void showruler __ARGS((int always)); + int number_width __ARGS((win_T *wp)); ++ int screen_screencol __ARGS((void)); ++ int screen_screenrow __ARGS((void)); + /* vim: set ft=c : */ +*** ../vim-7.3.747/src/screen.c 2012-12-05 15:32:24.000000000 +0100 +--- src/screen.c 2012-12-05 15:58:02.000000000 +0100 +*************** +*** 10264,10266 **** +--- 10264,10286 ---- + return n; + } + #endif ++ ++ /* ++ * Return the current cursor column. This is the actual position on the ++ * screen. First column is 0. ++ */ ++ int ++ screen_screencol() ++ { ++ return screen_cur_col; ++ } ++ ++ /* ++ * Return the current cursor row. This is the actual position on the screen. ++ * First row is 0. ++ */ ++ int ++ screen_screenrow() ++ { ++ return screen_cur_row; ++ } +*** ../vim-7.3.747/src/testdir/Make_amiga.mak 2012-06-29 12:54:32.000000000 +0200 +--- src/testdir/Make_amiga.mak 2012-12-05 16:00:14.000000000 +0100 +*************** +*** 31,37 **** + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out test83.out test84.out + + .SUFFIXES: .in .out + +--- 31,37 ---- + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out test83.out test84.out test88.out + + .SUFFIXES: .in .out + +*************** +*** 135,137 **** +--- 135,138 ---- + test82.out: test82.in + test83.out: test83.in + test84.out: test84.in ++ test88.out: test88.in +*** ../vim-7.3.747/src/testdir/Make_dos.mak 2012-10-06 19:10:29.000000000 +0200 +--- src/testdir/Make_dos.mak 2012-12-05 16:00:29.000000000 +0100 +*************** +*** 30,36 **** + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out + + SCRIPTS32 = test50.out test70.out + +--- 30,36 ---- + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out test88.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.747/src/testdir/Make_ming.mak 2012-10-06 19:10:29.000000000 +0200 +--- src/testdir/Make_ming.mak 2012-12-05 16:00:40.000000000 +0100 +*************** +*** 50,56 **** + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out + + SCRIPTS32 = test50.out test70.out + +--- 50,56 ---- + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out test88.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.747/src/testdir/Make_os2.mak 2012-06-29 12:54:32.000000000 +0200 +--- src/testdir/Make_os2.mak 2012-12-05 16:00:50.000000000 +0100 +*************** +*** 31,37 **** + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out test83.out test84.out + + .SUFFIXES: .in .out + +--- 31,37 ---- + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out test83.out test84.out test88.out + + .SUFFIXES: .in .out + +*** ../vim-7.3.747/src/testdir/Make_vms.mms 2012-10-06 19:10:29.000000000 +0200 +--- src/testdir/Make_vms.mms 2012-12-05 16:01:03.000000000 +0100 +*************** +*** 4,10 **** + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2012 Oct 06 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +--- 4,10 ---- + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2012 Dec 05 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +*************** +*** 76,82 **** + test66.out test67.out test68.out test69.out \ + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ +! test82.out test83.out test84.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +--- 76,82 ---- + test66.out test67.out test68.out test69.out \ + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ +! test82.out test83.out test84.out test88.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +*** ../vim-7.3.747/src/testdir/Makefile 2012-10-06 19:10:29.000000000 +0200 +--- src/testdir/Makefile 2012-12-05 15:59:02.000000000 +0100 +*************** +*** 13,19 **** + + SCRIPTS = test1.out test2.out test3.out test4.out test5.out test6.out \ + test7.out test8.out test9.out test10.out test11.out \ +! test12.out test13.out test14.out test15.out test17.out \ + test18.out test19.out test20.out test21.out test22.out \ + test23.out test24.out test25.out test26.out test27.out \ + test28.out test29.out test30.out test31.out test32.out \ +--- 13,19 ---- + + SCRIPTS = test1.out test2.out test3.out test4.out test5.out test6.out \ + test7.out test8.out test9.out test10.out test11.out \ +! test12.out test13.out test14.out test15.out test17.out \ + test18.out test19.out test20.out test21.out test22.out \ + test23.out test24.out test25.out test26.out test27.out \ + test28.out test29.out test30.out test31.out test32.out \ +*************** +*** 27,33 **** + test69.out test70.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out + + SCRIPTS_GUI = test16.out + +--- 27,33 ---- + test69.out test70.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out test88.out + + SCRIPTS_GUI = test16.out + +*** ../vim-7.3.747/src/testdir/test88.in 2012-12-05 16:08:56.000000000 +0100 +--- src/testdir/test88.in 2012-12-05 15:40:05.000000000 +0100 +*************** +*** 0 **** +--- 1,85 ---- ++ vim: set ft=vim ++ ++ Tests for correct display (cursor column position) with +conceal and ++ tabulators. ++ ++ STARTTEST ++ :so small.vim ++ :if !has('conceal') ++ e! test.ok ++ wq! test.out ++ :endif ++ :" Conceal settings. ++ :set conceallevel=2 ++ :set concealcursor=nc ++ :syntax match test /|/ conceal ++ :" Save current cursor position. Only works in mode, can't be used ++ :" with :normal because it moves the cursor to the command line. Thanks to ZyX ++ :" for the idea to use an mapping. ++ :let positions = [] ++ :nnoremap GG ":let positions += ['".screenrow().":".screencol()."']\n" ++ :" Start test. ++ /^start: ++ :normal ztj ++ GGk ++ :" We should end up in the same column when running these commands on the two ++ :" lines. ++ :normal ft ++ GGk ++ :normal $ ++ GGk ++ :normal 0j ++ GGk ++ :normal ft ++ GGk ++ :normal $ ++ GGk ++ :normal 0j0j ++ GGk ++ :" Same for next test block. ++ :normal ft ++ GGk ++ :normal $ ++ GGk ++ :normal 0j ++ GGk ++ :normal ft ++ GGk ++ :normal $ ++ GGk ++ :normal 0j0j ++ GGk ++ :" And check W with multiple tabs and conceals in a line. ++ :normal W ++ GGk ++ :normal W ++ GGk ++ :normal W ++ GGk ++ :normal $ ++ GGk ++ :normal 0j ++ GGk ++ :normal W ++ GGk ++ :normal W ++ GGk ++ :normal W ++ GGk ++ :normal $ ++ GGk ++ :" Display result. ++ :call append('$', 'end:') ++ :call append('$', positions) ++ :/^end/,$wq! test.out ++ ENDTEST ++ ++ start: ++ .concealed. text ++ |concealed| text ++ ++ .concealed. text ++ |concealed| text ++ ++ .a. .b. .c. .d. ++ |a| |b| |c| |d| +*** ../vim-7.3.747/src/testdir/test88.ok 2012-12-05 16:08:56.000000000 +0100 +--- src/testdir/test88.ok 2012-12-05 15:40:05.000000000 +0100 +*************** +*** 0 **** +--- 1,23 ---- ++ end: ++ 2:1 ++ 2:17 ++ 2:20 ++ 3:1 ++ 3:17 ++ 3:20 ++ 5:8 ++ 5:25 ++ 5:28 ++ 6:8 ++ 6:25 ++ 6:28 ++ 8:1 ++ 8:9 ++ 8:17 ++ 8:25 ++ 8:27 ++ 9:1 ++ 9:9 ++ 9:17 ++ 9:25 ++ 9:26 +*** ../vim-7.3.747/src/version.c 2012-12-05 15:32:24.000000000 +0100 +--- src/version.c 2012-12-05 16:07:46.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 748, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +101. U can read htis w/o ny porblm and cant figur eout Y its evn listd. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5f7d04a86244f591014693eeb25ad35cf43b590d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:13 +0100 Subject: [PATCH 0627/3340] - patchlevel 749 --- 7.3.749 | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.749 diff --git a/7.3.749 b/7.3.749 new file mode 100644 index 00000000..69030830 --- /dev/null +++ b/7.3.749 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.749 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.749 +Problem: Python interface doesn't build without the multi-byte feature. +Solution: Add #ifdef. (Ken Takata) +Files: src/if_py_both.h + + +*** ../vim-7.3.748/src/if_py_both.h 2012-10-05 21:30:04.000000000 +0200 +--- src/if_py_both.h 2012-12-05 16:27:20.000000000 +0100 +*************** +*** 520,526 **** + if (!PyArg_ParseTuple(args, "s", &expr)) + return NULL; + +! return PyLong_FromLong(mb_string2cells((char_u *)expr, (int)STRLEN(expr))); + } + + /* +--- 520,532 ---- + if (!PyArg_ParseTuple(args, "s", &expr)) + return NULL; + +! return PyLong_FromLong( +! #ifdef FEAT_MBYTE +! mb_string2cells((char_u *)expr, (int)STRLEN(expr)) +! #else +! STRLEN(expr) +! #endif +! ); + } + + /* +*** ../vim-7.3.748/src/version.c 2012-12-05 16:10:21.000000000 +0100 +--- src/version.c 2012-12-05 16:29:27.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 749, + /**/ + +-- +Contrary to popular belief, Unix is user friendly. +It just happens to be selective about who it makes friends with. + -- Dave Parnas + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b1cb5a3527114b05ae504dbe3c8fca1d2dc97694 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:14 +0100 Subject: [PATCH 0628/3340] - patchlevel 750 --- 7.3.750 | 83 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 7.3.750 diff --git a/7.3.750 b/7.3.750 new file mode 100644 index 00000000..d6d70fe3 --- /dev/null +++ b/7.3.750 @@ -0,0 +1,83 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.750 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.750 +Problem: The justify macro does not always work correctly. +Solution: Fix off-by-one error (James McCoy) +Files: runtime/macros/justify.vim + + +*** ../vim-7.3.749/runtime/macros/justify.vim 2010-08-15 21:57:19.000000000 +0200 +--- runtime/macros/justify.vim 2012-12-05 16:58:40.000000000 +0100 +*************** +*** 1,4 **** +! " Function to left and rigt align text. + " + " Written by: Preben "Peppe" Guldberg + " Created: 980806 14:13 (or around that time anyway) +--- 1,4 ---- +! " Function to left and right align text. + " + " Written by: Preben "Peppe" Guldberg + " Created: 980806 14:13 (or around that time anyway) +*************** +*** 256,273 **** + let str = substitute(str, '\s\+$', '', '') + let str = substitute(str, '^\s\+', '', '') + let str = substitute(str, '\s\+', ' ', 'g') +! " Use substitute() hack to get strlen in characters instead of bytes +! let str_n = strlen(substitute(str, '.', 'x', 'g')) + + " Possible addition of space after punctuation + if exists("join_str") + let str = substitute(str, join_str, '\1 ', 'g') + endif +! let join_n = strlen(substitute(str, '.', 'x', 'g')) - str_n + + " Can extraspaces be added? + " Note that str_n may be less than strlen(str) [joinspaces above] +! if strlen(substitute(str, '.', 'x', 'g')) < tw - indent_n && str_n > 0 + " How many spaces should be added + let s_add = tw - str_n - indent_n - join_n + let s_nr = strlen(substitute(str, '\S', '', 'g') ) - join_n +--- 256,272 ---- + let str = substitute(str, '\s\+$', '', '') + let str = substitute(str, '^\s\+', '', '') + let str = substitute(str, '\s\+', ' ', 'g') +! let str_n = strdisplaywidth(str) + + " Possible addition of space after punctuation + if exists("join_str") + let str = substitute(str, join_str, '\1 ', 'g') + endif +! let join_n = strdisplaywidth(str) - str_n + + " Can extraspaces be added? + " Note that str_n may be less than strlen(str) [joinspaces above] +! if strdisplaywidth(str) <= tw - indent_n && str_n > 0 + " How many spaces should be added + let s_add = tw - str_n - indent_n - join_n + let s_nr = strlen(substitute(str, '\S', '', 'g') ) - join_n +*** ../vim-7.3.749/src/version.c 2012-12-05 16:30:03.000000000 +0100 +--- src/version.c 2012-12-05 17:01:02.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 750, + /**/ + +-- +To be rich is not the end, but only a change of worries. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 011c1b828615bc14109f09c88d91888206422d3f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:15 +0100 Subject: [PATCH 0629/3340] - patchlevel 751 --- 7.3.751 | 103 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 103 insertions(+) create mode 100644 7.3.751 diff --git a/7.3.751 b/7.3.751 new file mode 100644 index 00000000..d990a2f7 --- /dev/null +++ b/7.3.751 @@ -0,0 +1,103 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.751 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.751 +Problem: Test 61 is flaky, it fails once in a while. +Solution: When it fails retry once. +Files: src/testdir/Makefile + + +*** ../vim-7.3.750/src/testdir/Makefile 2012-12-05 16:10:21.000000000 +0100 +--- src/testdir/Makefile 2012-12-05 18:17:03.000000000 +0100 +*************** +*** 47,58 **** + + $(SCRIPTS) $(SCRIPTS_GUI): $(VIMPROG) + + clean: +! -rm -rf *.out *.failed *.rej *.orig test.log tiny.vim small.vim mbyte.vim mzscheme.vim lua.vim test.ok X* valgrind.* viminfo + + test1.out: test1.in +! -rm -f $*.failed tiny.vim small.vim mbyte.vim mzscheme.vim lua.vim test.ok X* viminfo +! $(VALGRIND) $(VIMPROG) -u unix.vim -U NONE --noplugin -s dotest.in $*.in + @/bin/sh -c "if diff test.out $*.ok; \ + then mv -f test.out $*.out; \ + else echo; \ +--- 47,62 ---- + + $(SCRIPTS) $(SCRIPTS_GUI): $(VIMPROG) + ++ RM_ON_RUN = test.out X* viminfo ++ RM_ON_START = tiny.vim small.vim mbyte.vim mzscheme.vim lua.vim test.ok ++ RUN_VIM = $(VALGRIND) $(VIMPROG) -u unix.vim -U NONE --noplugin -s dotest.in ++ + clean: +! -rm -rf *.out *.failed *.rej *.orig test.log $(RM_ON_RUN) $(RM_ON_START) valgrind.* + + test1.out: test1.in +! -rm -rf $*.failed $(RM_ON_RUN) $(RM_ON_START) +! $(RUN_VIM) $*.in + @/bin/sh -c "if diff test.out $*.ok; \ + then mv -f test.out $*.out; \ + else echo; \ +*************** +*** 61,71 **** + -rm -rf X* viminfo + + .in.out: +! -rm -rf $*.failed test.ok test.out X* viminfo + cp $*.ok test.ok + # Sleep a moment to avoid that the xterm title is messed up + @-sleep .2 +! -$(VALGRIND) $(VIMPROG) -u unix.vim -U NONE --noplugin -s dotest.in $*.in + @/bin/sh -c "if test -f test.out; then\ + if diff test.out $*.ok; \ + then mv -f test.out $*.out; \ +--- 65,86 ---- + -rm -rf X* viminfo + + .in.out: +! -rm -rf $*.failed test.ok $(RM_ON_RUN) + cp $*.ok test.ok + # Sleep a moment to avoid that the xterm title is messed up + @-sleep .2 +! -$(RUN_VIM) $*.in +! +! # For flaky tests retry one time. +! @/bin/sh -c "if test -f test.out -a $* = test61; then \ +! if diff test.out $*.ok; \ +! then echo flaky test ok first time; \ +! else rm -rf $*.failed $(RM_ON_RUN); \ +! $(RUN_VIM) $*.in; \ +! fi \ +! fi" +! +! # Check if the test.out file matches test.ok. + @/bin/sh -c "if test -f test.out; then\ + if diff test.out $*.ok; \ + then mv -f test.out $*.out; \ +*** ../vim-7.3.750/src/version.c 2012-12-05 17:03:17.000000000 +0100 +--- src/version.c 2012-12-05 18:10:49.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 751, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +103. When you find yourself in the "Computer" section of Barnes & Noble + enjoying yourself. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bf2758706ae43114dfa456a4942a0252e39a9549 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:16 +0100 Subject: [PATCH 0630/3340] - patchlevel 752 --- 7.3.752 | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 7.3.752 diff --git a/7.3.752 b/7.3.752 new file mode 100644 index 00000000..f9cd46b7 --- /dev/null +++ b/7.3.752 @@ -0,0 +1,68 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.752 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.752 +Problem: Test 49 script file doesn't fold properly. +Solution: Add a colon. +Files: src/testdir/test49.vim + + +*** ../vim-7.3.751/src/testdir/test49.vim 2012-11-14 22:38:04.000000000 +0100 +--- src/testdir/test49.vim 2012-11-23 22:08:37.000000000 +0100 +*************** +*** 1,6 **** + " Vim script language tests + " Author: Servatius Brandt +! " Last Change: 2010 Sep 29 + + "------------------------------------------------------------------------------- + " Test environment {{{1 +--- 1,6 ---- + " Vim script language tests + " Author: Servatius Brandt +! " Last Change: 2012 Nov 23 + + "------------------------------------------------------------------------------- + " Test environment {{{1 +*************** +*** 9604,9610 **** + Xcheck 198689 + + "------------------------------------------------------------------------------- +! " Test 86 setloclist crash {{{1 + " + " Executing a setloclist() on BufUnload shouldn't crash Vim + "------------------------------------------------------------------------------- +--- 9604,9610 ---- + Xcheck 198689 + + "------------------------------------------------------------------------------- +! " Test 86: setloclist crash {{{1 + " + " Executing a setloclist() on BufUnload shouldn't crash Vim + "------------------------------------------------------------------------------- +*** ../vim-7.3.751/src/version.c 2012-12-05 18:21:28.000000000 +0100 +--- src/version.c 2012-12-05 18:59:50.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 752, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +106. When told to "go to your room" you inform your parents that you + can't...because you were kicked out and banned. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b8fc4b030a6ee2b7c92c364f19eb7ab7ae6dd83a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:17 +0100 Subject: [PATCH 0631/3340] - patchlevel 753 --- 7.3.753 | 103 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 103 insertions(+) create mode 100644 7.3.753 diff --git a/7.3.753 b/7.3.753 new file mode 100644 index 00000000..f6ae2305 --- /dev/null +++ b/7.3.753 @@ -0,0 +1,103 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.753 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.753 +Problem: When there is a QuitPre autocommand using ":q" twice does not work + for exiting when there are more files to edit. +Solution: Do not decrement quitmore in an autocommand. (Techlive Zheng) +Files: src/ex_docmd.c, src/fileio.c, src/proto/fileio.pro + + +*** ../vim-7.3.752/src/ex_docmd.c 2012-11-28 23:03:02.000000000 +0100 +--- src/ex_docmd.c 2012-12-05 19:07:01.000000000 +0100 +*************** +*** 1729,1739 **** + ++ex_nesting_level; + #endif + +! /* when not editing the last file :q has to be typed twice */ + if (quitmore + #ifdef FEAT_EVAL + /* avoid that a function call in 'statusline' does this */ + && !getline_equal(fgetline, cookie, get_func_line) + #endif + ) + --quitmore; +--- 1729,1741 ---- + ++ex_nesting_level; + #endif + +! /* When the last file has not been edited :q has to be typed twice. */ + if (quitmore + #ifdef FEAT_EVAL + /* avoid that a function call in 'statusline' does this */ + && !getline_equal(fgetline, cookie, get_func_line) ++ /* avoid that an autocommand, e.g. QuitPre, does this */ ++ && !getline_equal(fgetline, cookie, getnextac) + #endif + ) + --quitmore; +*** ../vim-7.3.752/src/fileio.c 2012-08-29 18:50:50.000000000 +0200 +--- src/fileio.c 2012-12-05 19:08:17.000000000 +0100 +*************** +*** 7774,7780 **** + static int event_ignored __ARGS((event_T event)); + static int au_get_grouparg __ARGS((char_u **argp)); + static int do_autocmd_event __ARGS((event_T event, char_u *pat, int nested, char_u *cmd, int forceit, int group)); +- static char_u *getnextac __ARGS((int c, void *cookie, int indent)); + static int apply_autocmds_group __ARGS((event_T event, char_u *fname, char_u *fname_io, int force, int group, buf_T *buf, exarg_T *eap)); + static void auto_next_pat __ARGS((AutoPatCmd *apc, int stop_at_last)); + +--- 7774,7779 ---- +*************** +*** 9613,9619 **** + * Called by do_cmdline() to get the next line for ":if". + * Returns allocated string, or NULL for end of autocommands. + */ +! static char_u * + getnextac(c, cookie, indent) + int c UNUSED; + void *cookie; +--- 9612,9618 ---- + * Called by do_cmdline() to get the next line for ":if". + * Returns allocated string, or NULL for end of autocommands. + */ +! char_u * + getnextac(c, cookie, indent) + int c UNUSED; + void *cookie; +*** ../vim-7.3.752/src/proto/fileio.pro 2012-02-29 18:22:03.000000000 +0100 +--- src/proto/fileio.pro 2012-12-05 19:08:24.000000000 +0100 +*************** +*** 47,52 **** +--- 47,53 ---- + int has_insertcharpre __ARGS((void)); + void block_autocmds __ARGS((void)); + void unblock_autocmds __ARGS((void)); ++ char_u *getnextac __ARGS((int c, void *cookie, int indent)); + int has_autocmd __ARGS((event_T event, char_u *sfname, buf_T *buf)); + char_u *get_augroup_name __ARGS((expand_T *xp, int idx)); + char_u *set_context_in_autocmd __ARGS((expand_T *xp, char_u *arg, int doautocmd)); +*** ../vim-7.3.752/src/version.c 2012-12-05 19:00:03.000000000 +0100 +--- src/version.c 2012-12-05 19:08:34.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 753, + /**/ + +-- +Laughing helps. It's like jogging on the inside. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f3967167998b449acbb8f7ed099123f609c0719e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:18 +0100 Subject: [PATCH 0632/3340] - patchlevel 754 --- 7.3.754 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.754 diff --git a/7.3.754 b/7.3.754 new file mode 100644 index 00000000..7584429e --- /dev/null +++ b/7.3.754 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.754 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.754 +Problem: Latest nmake is not recognized. +Solution: Add nmake version 11.00.51106.1. (Raymond Ko) +Files: src/Make_mvc.mak + + +*** ../vim-7.3.753/src/Make_mvc.mak 2012-10-23 05:35:30.000000000 +0200 +--- src/Make_mvc.mak 2012-12-06 21:27:56.000000000 +0100 +*************** +*** 413,418 **** +--- 413,421 ---- + !if "$(_NMAKE_VER)" == "11.00.50727.1" + MSVCVER = 11.0 + !endif ++ !if "$(_NMAKE_VER)" == "11.00.51106.1" ++ MSVCVER = 11.0 ++ !endif + !endif + + # Abort bulding VIM if version of VC is unrecognised. +*** ../vim-7.3.753/src/version.c 2012-12-05 19:13:11.000000000 +0100 +--- src/version.c 2012-12-06 21:29:12.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 754, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +116. You are living with your boyfriend who networks your respective + computers so you can sit in separate rooms and email each other + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 33cb5f36eefdff971d004ed8bb8416e69f1acd6d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:19 +0100 Subject: [PATCH 0633/3340] - patchlevel 755 --- 7.3.755 | 137 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 137 insertions(+) create mode 100644 7.3.755 diff --git a/7.3.755 b/7.3.755 new file mode 100644 index 00000000..89e424dd --- /dev/null +++ b/7.3.755 @@ -0,0 +1,137 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.755 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.755 +Problem: Autoconf doesn't find Python 3 if it's called "python". +Solution: Search for "python2" and "python3" first, then "python". +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.754/src/configure.in 2012-11-23 21:54:43.000000000 +0100 +--- src/configure.in 2012-12-09 15:41:59.000000000 +0100 +*************** +*** 838,844 **** + AC_MSG_RESULT($enable_pythoninterp) + if test "$enable_pythoninterp" = "yes" -o "$enable_pythoninterp" = "dynamic"; then + dnl -- find the python executable +! AC_PATH_PROG(vi_cv_path_python, python) + if test "X$vi_cv_path_python" != "X"; then + + dnl -- get its version number +--- 838,844 ---- + AC_MSG_RESULT($enable_pythoninterp) + if test "$enable_pythoninterp" = "yes" -o "$enable_pythoninterp" = "dynamic"; then + dnl -- find the python executable +! AC_PATH_PROGS(vi_cv_path_python, python2 python) + if test "X$vi_cv_path_python" != "X"; then + + dnl -- get its version number +*************** +*** 1028,1034 **** + AC_MSG_RESULT($enable_python3interp) + if test "$enable_python3interp" = "yes" -o "$enable_python3interp" = "dynamic"; then + dnl -- find the python3 executable +! AC_PATH_PROG(vi_cv_path_python3, python3) + if test "X$vi_cv_path_python3" != "X"; then + + dnl -- get its version number +--- 1028,1034 ---- + AC_MSG_RESULT($enable_python3interp) + if test "$enable_python3interp" = "yes" -o "$enable_python3interp" = "dynamic"; then + dnl -- find the python3 executable +! AC_PATH_PROGS(vi_cv_path_python3, python3 python) + if test "X$vi_cv_path_python3" != "X"; then + + dnl -- get its version number +*** ../vim-7.3.754/src/auto/configure 2012-11-23 21:54:43.000000000 +0100 +--- src/auto/configure 2012-12-12 14:23:46.000000000 +0100 +*************** +*** 5214,5221 **** + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_pythoninterp" >&5 + $as_echo "$enable_pythoninterp" >&6; } + if test "$enable_pythoninterp" = "yes" -o "$enable_pythoninterp" = "dynamic"; then +! # Extract the first word of "python", so it can be a program name with args. +! set dummy python; ac_word=$2 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 + $as_echo_n "checking for $ac_word... " >&6; } + if test "${ac_cv_path_vi_cv_path_python+set}" = set; then : +--- 5214,5223 ---- + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_pythoninterp" >&5 + $as_echo "$enable_pythoninterp" >&6; } + if test "$enable_pythoninterp" = "yes" -o "$enable_pythoninterp" = "dynamic"; then +! for ac_prog in python2 python +! do +! # Extract the first word of "$ac_prog", so it can be a program name with args. +! set dummy $ac_prog; ac_word=$2 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 + $as_echo_n "checking for $ac_word... " >&6; } + if test "${ac_cv_path_vi_cv_path_python+set}" = set; then : +*************** +*** 5254,5259 **** +--- 5256,5264 ---- + fi + + ++ test -n "$vi_cv_path_python" && break ++ done ++ + if test "X$vi_cv_path_python" != "X"; then + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python version" >&5 +*************** +*** 5509,5516 **** + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_python3interp" >&5 + $as_echo "$enable_python3interp" >&6; } + if test "$enable_python3interp" = "yes" -o "$enable_python3interp" = "dynamic"; then +! # Extract the first word of "python3", so it can be a program name with args. +! set dummy python3; ac_word=$2 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 + $as_echo_n "checking for $ac_word... " >&6; } + if test "${ac_cv_path_vi_cv_path_python3+set}" = set; then : +--- 5514,5523 ---- + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_python3interp" >&5 + $as_echo "$enable_python3interp" >&6; } + if test "$enable_python3interp" = "yes" -o "$enable_python3interp" = "dynamic"; then +! for ac_prog in python3 python +! do +! # Extract the first word of "$ac_prog", so it can be a program name with args. +! set dummy $ac_prog; ac_word=$2 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 + $as_echo_n "checking for $ac_word... " >&6; } + if test "${ac_cv_path_vi_cv_path_python3+set}" = set; then : +*************** +*** 5549,5554 **** +--- 5556,5564 ---- + fi + + ++ test -n "$vi_cv_path_python3" && break ++ done ++ + if test "X$vi_cv_path_python3" != "X"; then + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python version" >&5 +*** ../vim-7.3.754/src/version.c 2012-12-06 21:30:24.000000000 +0100 +--- src/version.c 2012-12-12 14:23:14.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 755, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +145. You e-mail your boss, informing him you'll be late. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 97760f0588fdcf8ef222466c8a7c2eef6f871a38 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:20 +0100 Subject: [PATCH 0634/3340] - patchlevel 756 --- 7.3.756 | 107 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 107 insertions(+) create mode 100644 7.3.756 diff --git a/7.3.756 b/7.3.756 new file mode 100644 index 00000000..95d862e0 --- /dev/null +++ b/7.3.756 @@ -0,0 +1,107 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.756 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.756 +Problem: A location list can get a wrong count in :lvimgrep. +Solution: Check if the list was changed by autocommands. (mostly by + Christian Brabandt) +Files: src/quickfic.c + + +*** ../vim-7.3.755/src/quickfix.c 2012-12-05 15:16:42.000000000 +0100 +--- src/quickfix.c 2012-12-12 15:50:08.000000000 +0100 +*************** +*** 3109,3114 **** +--- 3109,3117 ---- + char_u *p; + int fi; + qf_info_T *qi = &ql_info; ++ #ifdef FEAT_AUTOCMD ++ qfline_T *cur_qf_start; ++ #endif + qfline_T *prevp = NULL; + long lnum; + buf_T *buf; +*************** +*** 3218,3223 **** +--- 3221,3232 ---- + * ":lcd %:p:h" changes the meaning of short path names. */ + mch_dirname(dirname_start, MAXPATHL); + ++ #ifdef FEAT_AUTOCMD ++ /* Remeber the value of qf_start, so that we can check for autocommands ++ * changing the current quickfix list. */ ++ cur_qf_start = qi->qf_lists[qi->qf_curlist].qf_start; ++ #endif ++ + seconds = (time_t)0; + for (fi = 0; fi < fcount && !got_int && tomatch > 0; ++fi) + { +*************** +*** 3273,3278 **** +--- 3282,3309 ---- + /* Use existing, loaded buffer. */ + using_dummy = FALSE; + ++ #ifdef FEAT_AUTOCMD ++ if (cur_qf_start != qi->qf_lists[qi->qf_curlist].qf_start) ++ { ++ int idx; ++ ++ /* Autocommands changed the quickfix list. Find the one we were ++ * using and restore it. */ ++ for (idx = 0; idx < LISTCOUNT; ++idx) ++ if (cur_qf_start == qi->qf_lists[idx].qf_start) ++ { ++ qi->qf_curlist = idx; ++ break; ++ } ++ if (idx == LISTCOUNT) ++ { ++ /* List cannot be found, create a new one. */ ++ qf_new_list(qi, *eap->cmdlinep); ++ cur_qf_start = qi->qf_lists[qi->qf_curlist].qf_start; ++ } ++ } ++ #endif ++ + if (buf == NULL) + { + if (!got_int) +*************** +*** 3324,3329 **** +--- 3355,3363 ---- + if (got_int) + break; + } ++ #ifdef FEAT_AUTOCMD ++ cur_qf_start = qi->qf_lists[qi->qf_curlist].qf_start; ++ #endif + + if (using_dummy) + { +*** ../vim-7.3.755/src/version.c 2012-12-12 14:25:01.000000000 +0100 +--- src/version.c 2012-12-12 15:35:58.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 756, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +146. You experience ACTUAL physical withdrawal symptoms when away + from your 'puter and the net. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c7c67b8b20985755d44004f588e2661cf0f6e518 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:21 +0100 Subject: [PATCH 0635/3340] - patchlevel 757 --- 7.3.757 | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 7.3.757 diff --git a/7.3.757 b/7.3.757 new file mode 100644 index 00000000..e7b7698c --- /dev/null +++ b/7.3.757 @@ -0,0 +1,51 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.757 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.757 +Problem: Issue 96: May access freed memory when a put command triggers + autocommands. (Dominique Pelle) +Solution: Call u_save() before getting y_array. +Files: src/ops.c + + +*** ../vim-7.3.756/src/ops.c 2012-09-05 14:18:42.000000000 +0200 +--- src/ops.c 2012-12-12 16:03:35.000000000 +0100 +*************** +*** 3351,3356 **** +--- 3351,3362 ---- + return; + } + ++ #ifdef FEAT_AUTOCMD ++ /* Autocommands may be executed when saving lines for undo, which may make ++ * y_array invalid. Start undo now to avoid that. */ ++ u_save(curwin->w_cursor.lnum, curwin->w_cursor.lnum + 1); ++ #endif ++ + if (insert_string != NULL) + { + y_type = MCHAR; +*** ../vim-7.3.756/src/version.c 2012-12-12 15:55:16.000000000 +0100 +--- src/version.c 2012-12-12 16:06:47.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 757, + /**/ + +-- +We are the Borg of GNU GPL. We will assimilate your source code. +Resistance is futile. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 08872916c46aacb22a85c27e0f9da16efb4e642f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:22 +0100 Subject: [PATCH 0636/3340] - patchlevel 758 --- 7.3.758 | 78 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) create mode 100644 7.3.758 diff --git a/7.3.758 b/7.3.758 new file mode 100644 index 00000000..49febd82 --- /dev/null +++ b/7.3.758 @@ -0,0 +1,78 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.758 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.758 +Problem: Matchit plugin does not handle space in #ifdef. +Solution: Change matching pattern to allow spaces. (Mike Morearty) +Files: runtime/macros/matchit.vim + + +*** ../vim-7.3.757/runtime/macros/matchit.vim 2010-08-15 21:57:19.000000000 +0200 +--- runtime/macros/matchit.vim 2012-12-12 16:34:11.000000000 +0100 +*************** +*** 131,137 **** + " let default = substitute(escape(&mps, '[$^.*~\\/?]'), '[,:]\+', + " \ '\\|', 'g').'\|\/\*\|\*\/\|#if\>\|#ifdef\>\|#else\>\|#elif\>\|#endif\>' + let default = escape(&mps, '[$^.*~\\/?]') . (strlen(&mps) ? "," : "") . +! \ '\/\*:\*\/,#if\%(def\)\=:#else\>:#elif\>:#endif\>' + " s:all = pattern with all the keywords + let match_words = match_words . (strlen(match_words) ? "," : "") . default + if match_words !~ s:notslash . '\\\d' +--- 131,137 ---- + " let default = substitute(escape(&mps, '[$^.*~\\/?]'), '[,:]\+', + " \ '\\|', 'g').'\|\/\*\|\*\/\|#if\>\|#ifdef\>\|#else\>\|#elif\>\|#endif\>' + let default = escape(&mps, '[$^.*~\\/?]') . (strlen(&mps) ? "," : "") . +! \ '\/\*:\*\/,#\s*if\%(def\)\=:#\s*else\>:#\s*elif\>:#\s*endif\>' + " s:all = pattern with all the keywords + let match_words = match_words . (strlen(match_words) ? "," : "") . default + if match_words !~ s:notslash . '\\\d' +*************** +*** 649,655 **** + " s:all regexp based on s:pat and the default groups + " This part is copied and slightly modified from s:Match_wrapper(). + let default = escape(&mps, '[$^.*~\\/?]') . (strlen(&mps) ? "," : "") . +! \ '\/\*:\*\/,#if\%(def\)\=:#else\>:#elif\>:#endif\>' + " Allow b:match_words = "GetVimMatchWords()" . + if b:match_words =~ ":" + let match_words = b:match_words +--- 649,655 ---- + " s:all regexp based on s:pat and the default groups + " This part is copied and slightly modified from s:Match_wrapper(). + let default = escape(&mps, '[$^.*~\\/?]') . (strlen(&mps) ? "," : "") . +! \ '\/\*:\*\/,#\s*if\%(def\)\=:#\s*else\>:#\s*elif\>:#\s*endif\>' + " Allow b:match_words = "GetVimMatchWords()" . + if b:match_words =~ ":" + let match_words = b:match_words +*************** +*** 808,812 **** +--- 808,813 ---- + endfun + + let &cpo = s:save_cpo ++ unlet s:save_cpo + + " vim:sts=2:sw=2: +*** ../vim-7.3.757/src/version.c 2012-12-12 16:11:28.000000000 +0100 +--- src/version.c 2012-12-12 16:41:40.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 758, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +147. You finally give up smoking...because it made the monitor dirty. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 652f5e06decc70ec9ad48f9120d77384b9d7db5e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:23 +0100 Subject: [PATCH 0637/3340] - patchlevel 759 --- 7.3.759 | 106 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 106 insertions(+) create mode 100644 7.3.759 diff --git a/7.3.759 b/7.3.759 new file mode 100644 index 00000000..02739266 --- /dev/null +++ b/7.3.759 @@ -0,0 +1,106 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.759 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.759 +Problem: MS-Windows: Updating the tabline is slow when there are many tabs. +Solution: Disable redrawing while performing the update. (Arseny Kapoulkine) +Files: src/gui_w48.c + + +*** ../vim-7.3.758/src/gui_w48.c 2012-11-20 16:53:34.000000000 +0100 +--- src/gui_w48.c 2012-12-12 17:10:21.000000000 +0100 +*************** +*** 2452,2458 **** + TCITEM tie; + int nr = 0; + int curtabidx = 0; +- RECT rc; + #ifdef FEAT_MBYTE + static int use_unicode = FALSE; + int uu; +--- 2452,2457 ---- +*************** +*** 2479,2491 **** + tie.mask = TCIF_TEXT; + tie.iImage = -1; + + /* Add a label for each tab page. They all contain the same text area. */ + for (tp = first_tabpage; tp != NULL; tp = tp->tp_next, ++nr) + { + if (tp == curtab) + curtabidx = nr; + +! if (!TabCtrl_GetItemRect(s_tabhwnd, nr, &rc)) + { + /* Add the tab */ + tie.pszText = "-Empty-"; +--- 2478,2493 ---- + tie.mask = TCIF_TEXT; + tie.iImage = -1; + ++ /* Disable redraw for tab updates to eliminate O(N^2) draws. */ ++ SendMessage(s_tabhwnd, WM_SETREDRAW, (WPARAM)FALSE, 0); ++ + /* Add a label for each tab page. They all contain the same text area. */ + for (tp = first_tabpage; tp != NULL; tp = tp->tp_next, ++nr) + { + if (tp == curtab) + curtabidx = nr; + +! if (nr >= TabCtrl_GetItemCount(s_tabhwnd)) + { + /* Add the tab */ + tie.pszText = "-Empty-"; +*************** +*** 2519,2529 **** + } + + /* Remove any old labels. */ +! while (TabCtrl_GetItemRect(s_tabhwnd, nr, &rc)) + TabCtrl_DeleteItem(s_tabhwnd, nr); + + if (TabCtrl_GetCurSel(s_tabhwnd) != curtabidx) + TabCtrl_SetCurSel(s_tabhwnd, curtabidx); + } + + /* +--- 2521,2534 ---- + } + + /* Remove any old labels. */ +! while (nr < TabCtrl_GetItemCount(s_tabhwnd)) + TabCtrl_DeleteItem(s_tabhwnd, nr); + + if (TabCtrl_GetCurSel(s_tabhwnd) != curtabidx) + TabCtrl_SetCurSel(s_tabhwnd, curtabidx); ++ ++ /* Re-enable redraw. This should trigger a repaint. */ ++ SendMessage(s_tabhwnd, WM_SETREDRAW, (WPARAM)TRUE, 0); + } + + /* +*** ../vim-7.3.758/src/version.c 2012-12-12 16:43:52.000000000 +0100 +--- src/version.c 2012-12-12 17:10:46.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 759, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +148. You find it easier to dial-up the National Weather Service + Weather/your_town/now.html than to simply look out the window. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c106bdf5f5f6acc159e551a5eeea02e8ff5e7cda Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:24 +0100 Subject: [PATCH 0638/3340] - patchlevel 760 --- 7.3.760 | 99 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 99 insertions(+) create mode 100644 7.3.760 diff --git a/7.3.760 b/7.3.760 new file mode 100644 index 00000000..bdc4b793 --- /dev/null +++ b/7.3.760 @@ -0,0 +1,99 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.760 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.760 +Problem: dv_ deletes the white space before the line. +Solution: Move the cursor to the first non-white. (Christian Brabandt) +Files: src/normal.c, src/testdir/test19.in, src/testdir/test19.ok + + +*** ../vim-7.3.759/src/normal.c 2012-10-23 05:08:49.000000000 +0200 +--- src/normal.c 2012-12-12 17:23:00.000000000 +0100 +*************** +*** 8628,8634 **** + cap->oap->motion_type = MLINE; + if (cursor_down(cap->count1 - 1L, cap->oap->op_type == OP_NOP) == FAIL) + clearopbeep(cap->oap); +! else if ( cap->oap->op_type == OP_DELETE + || cap->oap->op_type == OP_LSHIFT + || cap->oap->op_type == OP_RSHIFT) + beginline(BL_SOL | BL_FIX); +--- 8628,8636 ---- + cap->oap->motion_type = MLINE; + if (cursor_down(cap->count1 - 1L, cap->oap->op_type == OP_NOP) == FAIL) + clearopbeep(cap->oap); +! else if ( (cap->oap->op_type == OP_DELETE /* only with linewise motions */ +! && cap->oap->motion_force != 'v' +! && cap->oap->motion_force != Ctrl_V) + || cap->oap->op_type == OP_LSHIFT + || cap->oap->op_type == OP_RSHIFT) + beginline(BL_SOL | BL_FIX); +*** ../vim-7.3.759/src/testdir/test19.in 2011-09-08 23:22:35.000000000 +0200 +--- src/testdir/test19.in 2012-12-12 17:19:36.000000000 +0100 +*************** +*** 1,4 **** +--- 1,5 ---- + Tests for "r" with 'smarttab' and 'expandtab' set/not set. ++ Also test that dv_ works correctly + + STARTTEST + :so small.vim +*************** +*** 16,22 **** + :" Test that copyindent works with expandtab set + :set expandtab smartindent copyindent ts=8 sw=8 sts=8 + o{ +! x:?^start?,$w! test.out + :qa! + ENDTEST + +--- 17,25 ---- + :" Test that copyindent works with expandtab set + :set expandtab smartindent copyindent ts=8 sw=8 sts=8 + o{ +! x:set nosol +! /Second line/ +! fwdv_:?^start?,$w! test.out + :qa! + ENDTEST + +*************** +*** 27,29 **** +--- 30,33 ---- + a cde + f ghi + test text ++ Second line beginning with whitespace +*** ../vim-7.3.759/src/testdir/test19.ok 2011-09-07 19:58:04.000000000 +0200 +--- src/testdir/test19.ok 2012-12-12 17:19:36.000000000 +0100 +*************** +*** 7,9 **** +--- 7,10 ---- + test text + { + x ++ with whitespace +*** ../vim-7.3.759/src/version.c 2012-12-12 17:12:21.000000000 +0100 +--- src/version.c 2012-12-12 17:20:47.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 760, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +149. You find your computer sexier than your girlfriend + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2e6fe65aefcd3b27194005c9769f362e764519c8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:25 +0100 Subject: [PATCH 0639/3340] - patchlevel 761 --- 7.3.761 | 93 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 93 insertions(+) create mode 100644 7.3.761 diff --git a/7.3.761 b/7.3.761 new file mode 100644 index 00000000..8b159bec --- /dev/null +++ b/7.3.761 @@ -0,0 +1,93 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.761 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.761 +Problem: In Visual mode a "-p does not work. (Marcin Szamotulski) +Solution: Avoid writing to "- before putting it. (Christian Brabandt) +Files: src/normal.c, src/testdir/test48.in, src/testdir/test48.ok + + +*** ../vim-7.3.760/src/normal.c 2012-12-12 17:33:26.000000000 +0100 +--- src/normal.c 2012-12-12 18:11:06.000000000 +0100 +*************** +*** 9412,9425 **** + # ifdef FEAT_CLIPBOARD + adjust_clip_reg(®name); + # endif +! if (regname == 0 || regname == '"' || VIM_ISDIGIT(regname) + # ifdef FEAT_CLIPBOARD + || (clip_unnamed && (regname == '*' || regname == '+')) + # endif + + ) + { +! /* the delete is going to overwrite the register we want to + * put, save it first. */ + reg1 = get_register(regname, TRUE); + } +--- 9412,9426 ---- + # ifdef FEAT_CLIPBOARD + adjust_clip_reg(®name); + # endif +! if (regname == 0 || regname == '"' +! || VIM_ISDIGIT(regname) || regname == '-' + # ifdef FEAT_CLIPBOARD + || (clip_unnamed && (regname == '*' || regname == '+')) + # endif + + ) + { +! /* The delete is going to overwrite the register we want to + * put, save it first. */ + reg1 = get_register(regname, TRUE); + } +*** ../vim-7.3.760/src/testdir/test48.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test48.in 2012-12-12 18:09:21.000000000 +0100 +*************** +*** 54,61 **** +--- 54,65 ---- + ^O3li4li4li <-- should show the name of a noted text editor + ^o4li4li4li <-- and its version number-dd + :" ++ :" Test for yanking and pasting using the small delete register ++ gg/^foo ++ dewve"-p + :wq! test.out + ENDTEST ++ foo, bar + keyword keyw + all your base are belong to us + 1 2 3 4 5 6 +*** ../vim-7.3.760/src/testdir/test48.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test48.ok 2012-12-12 18:09:25.000000000 +0100 +*************** +*** 1,3 **** +--- 1,4 ---- ++ , foo + keyword keyword + all your base + are belong to vim +*** ../vim-7.3.760/src/version.c 2012-12-12 17:33:26.000000000 +0100 +--- src/version.c 2012-12-12 18:19:51.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 761, + /**/ + +-- +You are not really successful until someone claims he sat +beside you in school. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ef7793c94fb8ea1b6cbbd08e576b191a1e58b8d9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:26 +0100 Subject: [PATCH 0640/3340] - patchlevel 762 --- 7.3.762 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.762 diff --git a/7.3.762 b/7.3.762 new file mode 100644 index 00000000..56007717 --- /dev/null +++ b/7.3.762 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.762 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.762 (after 7.3.759) +Problem: On some systems the tabline is not redrawn. +Solution: Call RedrawWindow(). (Charles Peacech) +Files: src/gui_w48.c + + +*** ../vim-7.3.761/src/gui_w48.c 2012-12-12 17:12:21.000000000 +0100 +--- src/gui_w48.c 2012-12-16 12:45:47.000000000 +0100 +*************** +*** 2527,2534 **** + if (TabCtrl_GetCurSel(s_tabhwnd) != curtabidx) + TabCtrl_SetCurSel(s_tabhwnd, curtabidx); + +! /* Re-enable redraw. This should trigger a repaint. */ + SendMessage(s_tabhwnd, WM_SETREDRAW, (WPARAM)TRUE, 0); + } + + /* +--- 2527,2536 ---- + if (TabCtrl_GetCurSel(s_tabhwnd) != curtabidx) + TabCtrl_SetCurSel(s_tabhwnd, curtabidx); + +! /* Re-enable redraw and redraw. */ + SendMessage(s_tabhwnd, WM_SETREDRAW, (WPARAM)TRUE, 0); ++ RedrawWindow(s_tabhwnd, NULL, NULL, ++ RDW_ERASE | RDW_FRAME | RDW_INVALIDATE | RDW_ALLCHILDREN); + } + + /* +*** ../vim-7.3.761/src/version.c 2012-12-12 18:20:28.000000000 +0100 +--- src/version.c 2012-12-16 12:46:44.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 762, + /**/ + +-- +"The question of whether computers can think is just like the question +of whether submarines can swim." -- Edsger W. Dijkstra + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f7e856499b70be2979966f2d124b618c3837524e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:27 +0100 Subject: [PATCH 0641/3340] - patchlevel 763 --- 7.3.763 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.763 diff --git a/7.3.763 b/7.3.763 new file mode 100644 index 00000000..0a308b1d --- /dev/null +++ b/7.3.763 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.763 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.763 +Problem: Jumping to a mark does not open a fold if it is in the same line. + (Wiktor Ruben) +Solution: Also compare the column after the jump. (Christian Brabandt) +Files: src/normal.c + + +*** ../vim-7.3.762/src/normal.c 2012-12-12 18:20:28.000000000 +0100 +--- src/normal.c 2013-01-11 22:02:30.000000000 +0100 +*************** +*** 7523,7529 **** + pos_T *pos; + int c; + #ifdef FEAT_FOLDING +! linenr_T lnum = curwin->w_cursor.lnum; + int old_KeyTyped = KeyTyped; /* getting file may reset it */ + #endif + +--- 7523,7529 ---- + pos_T *pos; + int c; + #ifdef FEAT_FOLDING +! pos_T old_cursor = curwin->w_cursor; + int old_KeyTyped = KeyTyped; /* getting file may reset it */ + #endif + +*************** +*** 7552,7558 **** + #endif + #ifdef FEAT_FOLDING + if (cap->oap->op_type == OP_NOP +! && (pos == (pos_T *)-1 || lnum != curwin->w_cursor.lnum) + && (fdo_flags & FDO_MARK) + && old_KeyTyped) + foldOpenCursor(); +--- 7552,7558 ---- + #endif + #ifdef FEAT_FOLDING + if (cap->oap->op_type == OP_NOP +! && (pos == (pos_T *)-1 || !equalpos(old_cursor, *pos)) + && (fdo_flags & FDO_MARK) + && old_KeyTyped) + foldOpenCursor(); +*** ../vim-7.3.762/src/version.c 2012-12-16 12:50:33.000000000 +0100 +--- src/version.c 2013-01-17 13:23:27.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 763, + /**/ + +-- +This is an airconditioned room, do not open Windows. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7e89c651b1f131b8ac95cafe094cf97671017d9c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:28 +0100 Subject: [PATCH 0642/3340] - patchlevel 764 --- 7.3.764 | 175 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 175 insertions(+) create mode 100644 7.3.764 diff --git a/7.3.764 b/7.3.764 new file mode 100644 index 00000000..f08bd1dc --- /dev/null +++ b/7.3.764 @@ -0,0 +1,175 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.764 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.764 +Problem: Not all message translation files are installed. +Solution: Also install the converted files. +Files: src/po/Makefile + + +*** ../vim-7.3.763/src/po/Makefile 2010-08-15 21:57:26.000000000 +0200 +--- src/po/Makefile 2013-01-17 13:30:30.000000000 +0100 +*************** +*** 20,25 **** +--- 20,26 ---- + ko \ + ko.UTF-8 \ + nb \ ++ nl \ + no \ + pl \ + pt_BR \ +*************** +*** 33,38 **** +--- 34,49 ---- + zh_TW \ + zh_TW.UTF-8 + ++ CONVERTED = \ ++ cs.cp1250 \ ++ ja.sjis \ ++ pl.cp1250 \ ++ pl.UTF-8 \ ++ ru.cp1251 \ ++ sk.cp1250 \ ++ uk.cp1251 \ ++ zh_CN.cp936 ++ + MOFILES = \ + af.mo \ + ca.mo \ +*************** +*** 49,54 **** +--- 60,66 ---- + ko.mo \ + ko.UTF-8.mo \ + nb.mo \ ++ nl.mo \ + no.mo \ + pl.mo \ + pt_BR.mo \ +*************** +*** 62,68 **** + zh_TW.UTF-8.mo \ + zh_TW.mo + +! CONVERTED = \ + cs.cp1250.mo \ + ja.sjis.mo \ + pl.cp1250.mo \ +--- 74,80 ---- + zh_TW.UTF-8.mo \ + zh_TW.mo + +! MOCONVERTED = \ + cs.cp1250.mo \ + ja.sjis.mo \ + pl.cp1250.mo \ +*************** +*** 88,93 **** +--- 100,106 ---- + ko.ck \ + ko.UTF-8.ck \ + nb.ck \ ++ nl.ck \ + no.ck \ + pl.ck \ + pt_BR.ck \ +*************** +*** 123,129 **** + + .SUFFIXES: + .SUFFIXES: .po .mo .pot .ck +! .PHONY: all install uninstall prefixcheck converted check clean checkclean distclean update-po $(LANGUAGES) + + .po.mo: + $(MSGFMT) -o $@ $< +--- 136,142 ---- + + .SUFFIXES: + .SUFFIXES: .po .mo .pot .ck +! .PHONY: all install uninstall prefixcheck converted check clean checkclean distclean update-po $(LANGUAGES) $(CONVERTED) + + .po.mo: + $(MSGFMT) -o $@ $< +*************** +*** 132,144 **** + $(VIM) -u NONE -e -X -S check.vim -c "if error == 0 | q | endif" -c cq $< + touch $@ + +! all: $(MOFILES) + + check: $(CHECKFILES) + +! install: $(MOFILES) + @$(MAKE) prefixcheck +! for lang in $(LANGUAGES); do \ + dir=$(LOCALEDIR)/$$lang/; \ + if test ! -x "$$dir"; then \ + mkdir $$dir; chmod 755 $$dir; \ +--- 145,157 ---- + $(VIM) -u NONE -e -X -S check.vim -c "if error == 0 | q | endif" -c cq $< + touch $@ + +! all: $(MOFILES) $(MOCONVERTED) + + check: $(CHECKFILES) + +! install: $(MOFILES) $(MOCONVERTED) + @$(MAKE) prefixcheck +! for lang in $(LANGUAGES) $(CONVERTED); do \ + dir=$(LOCALEDIR)/$$lang/; \ + if test ! -x "$$dir"; then \ + mkdir $$dir; chmod 755 $$dir; \ +*************** +*** 155,167 **** + + uninstall: + @$(MAKE) prefixcheck +! for cat in $(MOFILES); do \ + cat=`basename $$cat`; \ + lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \ + rm -f $(LOCALEDIR)/$$lang/LC_MESSAGES/$(PACKAGE).mo; \ + done + +! converted: $(CONVERTED) + + # Norwegian/Bokmal: "nb" is an alias for "no". + # Copying the file is not efficient, but I don't know of another way to make +--- 168,180 ---- + + uninstall: + @$(MAKE) prefixcheck +! for cat in $(MOFILES) $(MOCONVERTED); do \ + cat=`basename $$cat`; \ + lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \ + rm -f $(LOCALEDIR)/$$lang/LC_MESSAGES/$(PACKAGE).mo; \ + done + +! converted: $(MOCONVERTED) + + # Norwegian/Bokmal: "nb" is an alias for "no". + # Copying the file is not efficient, but I don't know of another way to make +*** ../vim-7.3.763/src/version.c 2013-01-17 13:24:00.000000000 +0100 +--- src/version.c 2013-01-17 13:25:41.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 764, + /**/ + +-- +The software said it requires Windows 95 or better, so I installed Linux. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 96eb039f02e7c738b33f8999604945f76f8ed9e2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:29 +0100 Subject: [PATCH 0643/3340] - patchlevel 765 --- 7.3.765 | 98 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 98 insertions(+) create mode 100644 7.3.765 diff --git a/7.3.765 b/7.3.765 new file mode 100644 index 00000000..c76e6bd1 --- /dev/null +++ b/7.3.765 @@ -0,0 +1,98 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.765 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.765 +Problem: Segfault when doing "cclose" on BufUnload in a python function. + (Sean Reifschneider) +Solution: Skip window with NULL buffer. (Christian Brabandt) +Files: src/main.c, src/window.c + + +*** ../vim-7.3.764/src/main.c 2012-11-28 15:55:37.000000000 +0100 +--- src/main.c 2013-01-17 13:46:57.000000000 +0100 +*************** +*** 1376,1381 **** +--- 1376,1384 ---- + for (wp = (tp == curtab) + ? firstwin : tp->tp_firstwin; wp != NULL; wp = wp->w_next) + { ++ if (wp->w_buffer == NULL) ++ /* Autocmd must have close the buffer already, skip. */ ++ continue; + buf = wp->w_buffer; + if (buf->b_changedtick != -1) + { +*** ../vim-7.3.764/src/window.c 2012-08-29 15:50:22.000000000 +0200 +--- src/window.c 2013-01-17 13:53:10.000000000 +0100 +*************** +*** 2276,2284 **** + #endif + } + + /* Autocommands may have closed the window already, or closed the only + * other window or moved to another tab page. */ +! if (!win_valid(win) || last_window() || curtab != prev_curtab + || close_last_window_tabpage(win, free_buf, prev_curtab)) + return; + +--- 2276,2290 ---- + #endif + } + ++ if (only_one_window() && win_valid(win) && win->w_buffer == NULL ++ && (last_window() || curtab != prev_curtab ++ || close_last_window_tabpage(win, free_buf, prev_curtab))) ++ /* Autocommands have close all windows, quit now. */ ++ getout(0); ++ + /* Autocommands may have closed the window already, or closed the only + * other window or moved to another tab page. */ +! else if (!win_valid(win) || last_window() || curtab != prev_curtab + || close_last_window_tabpage(win, free_buf, prev_curtab)) + return; + +*************** +*** 6282,6288 **** + return FALSE; + + for (wp = firstwin; wp != NULL; wp = wp->w_next) +! if ((!((wp->w_buffer->b_help && !curbuf->b_help) + # ifdef FEAT_QUICKFIX + || wp->w_p_pvw + # endif +--- 6288,6295 ---- + return FALSE; + + for (wp = firstwin; wp != NULL; wp = wp->w_next) +! if (wp->w_buffer != NULL +! && (!((wp->w_buffer->b_help && !curbuf->b_help) + # ifdef FEAT_QUICKFIX + || wp->w_p_pvw + # endif +*** ../vim-7.3.764/src/version.c 2013-01-17 13:35:13.000000000 +0100 +--- src/version.c 2013-01-17 13:56:56.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 765, + /**/ + +-- + He was not in the least bit scared to be mashed into a pulp + Or to have his eyes gouged out and his elbows broken; + To have his kneecaps split and his body burned away + And his limbs all hacked and mangled, brave Sir Robin. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 53d5fbd419d6a7926c205ca16f6636f14a938bbf Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:30 +0100 Subject: [PATCH 0644/3340] - patchlevel 766 --- 7.3.766 | 74 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 7.3.766 diff --git a/7.3.766 b/7.3.766 new file mode 100644 index 00000000..2f2c1f16 --- /dev/null +++ b/7.3.766 @@ -0,0 +1,74 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.766 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.766 +Problem: ":help cpo-*" jumps to the wrong place. +Solution: Make it equivalent to ":help cpo-star". +Files: src/ex_cmds.c + + +*** ../vim-7.3.765/src/ex_cmds.c 2012-11-29 20:09:55.000000000 +0100 +--- src/ex_cmds.c 2013-01-17 14:05:45.000000000 +0100 +*************** +*** 5849,5862 **** + int i; + static char *(mtable[]) = {"*", "g*", "[*", "]*", ":*", + "/*", "/\\*", "\"*", "**", +! "/\\(\\)", + "?", ":?", "?", "g?", "g?g?", "g??", "z?", + "/\\?", "/\\z(\\)", "\\=", ":s\\=", + "[count]", "[quotex]", "[range]", + "[pattern]", "\\|", "\\%$"}; + static char *(rtable[]) = {"star", "gstar", "[star", "]star", ":star", + "/star", "/\\\\star", "quotestar", "starstar", +! "/\\\\(\\\\)", + "?", ":?", "?", "g?", "g?g?", "g??", "z?", + "/\\\\?", "/\\\\z(\\\\)", "\\\\=", ":s\\\\=", + "\\[count]", "\\[quotex]", "\\[range]", +--- 5849,5862 ---- + int i; + static char *(mtable[]) = {"*", "g*", "[*", "]*", ":*", + "/*", "/\\*", "\"*", "**", +! "cpo-*", "/\\(\\)", + "?", ":?", "?", "g?", "g?g?", "g??", "z?", + "/\\?", "/\\z(\\)", "\\=", ":s\\=", + "[count]", "[quotex]", "[range]", + "[pattern]", "\\|", "\\%$"}; + static char *(rtable[]) = {"star", "gstar", "[star", "]star", ":star", + "/star", "/\\\\star", "quotestar", "starstar", +! "cpo-star", "/\\\\(\\\\)", + "?", ":?", "?", "g?", "g?g?", "g??", "z?", + "/\\\\?", "/\\\\z(\\\\)", "\\\\=", ":s\\\\=", + "\\[count]", "\\[quotex]", "\\[range]", +*** ../vim-7.3.765/src/version.c 2013-01-17 13:59:56.000000000 +0100 +--- src/version.c 2013-01-17 14:09:04.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 766, + /**/ + +-- +The greatest lies of all time: + (1) The check is in the mail. + (2) We have a really challenging assignment for you. + (3) I love you. + (4) All bugs have been fixed. + (5) This won't hurt a bit. + (6) Honey, I just need to debug this program and be home in 5 minutes. + (7) I have just sent you an e-mail about that. + (8) Of course I'll respect you in the morning. + (9) I'm from the government, and I'm here to help you. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ea0b275c62aea9d1b8174e385012e2e038538b9a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:31 +0100 Subject: [PATCH 0645/3340] - patchlevel 767 --- 7.3.767 | 120 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 120 insertions(+) create mode 100644 7.3.767 diff --git a/7.3.767 b/7.3.767 new file mode 100644 index 00000000..89ce19e4 --- /dev/null +++ b/7.3.767 @@ -0,0 +1,120 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.767 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.767 +Problem: (Win32) The _errno used for iconv may be the wrong one. +Solution: Use the _errno from iconv.dll. (Ken Takata) +Files: src/mbyte.c + + +*** ../vim-7.3.766/src/mbyte.c 2012-09-18 18:03:33.000000000 +0200 +--- src/mbyte.c 2013-01-17 14:33:42.000000000 +0100 +*************** +*** 3242,3248 **** + + /* + * Version of strnicmp() that handles multi-byte characters. +! * Needed for Big5, Sjift-JIS and UTF-8 encoding. Other DBCS encodings can + * probably use strnicmp(), because there are no ASCII characters in the + * second byte. + * Returns zero if s1 and s2 are equal (ignoring case), the difference between +--- 3242,3248 ---- + + /* + * Version of strnicmp() that handles multi-byte characters. +! * Needed for Big5, Shift-JIS and UTF-8 encoding. Other DBCS encodings can + * probably use strnicmp(), because there are no ASCII characters in the + * second byte. + * Returns zero if s1 and s2 are equal (ignoring case), the difference between +*************** +*** 4294,4299 **** +--- 4294,4337 ---- + # endif + + /* ++ * Get the address of 'funcname' which is imported by 'hInst' DLL. ++ */ ++ static void * ++ get_iconv_import_func(HINSTANCE hInst, const char *funcname) ++ { ++ PBYTE pImage = (PBYTE)hInst; ++ PIMAGE_DOS_HEADER pDOS = (PIMAGE_DOS_HEADER)hInst; ++ PIMAGE_NT_HEADERS pPE; ++ PIMAGE_IMPORT_DESCRIPTOR pImpDesc; ++ PIMAGE_THUNK_DATA pIAT; /* Import Address Table */ ++ PIMAGE_THUNK_DATA pINT; /* Import Name Table */ ++ PIMAGE_IMPORT_BY_NAME pImpName; ++ ++ if (pDOS->e_magic != IMAGE_DOS_SIGNATURE) ++ return NULL; ++ pPE = (PIMAGE_NT_HEADERS)(pImage + pDOS->e_lfanew); ++ if (pPE->Signature != IMAGE_NT_SIGNATURE) ++ return NULL; ++ pImpDesc = (PIMAGE_IMPORT_DESCRIPTOR)(pImage ++ + pPE->OptionalHeader.DataDirectory[IMAGE_DIRECTORY_ENTRY_IMPORT] ++ .VirtualAddress); ++ for (; pImpDesc->FirstThunk; ++pImpDesc) ++ { ++ pIAT = (PIMAGE_THUNK_DATA)(pImage + pImpDesc->FirstThunk); ++ pINT = (PIMAGE_THUNK_DATA)(pImage + pImpDesc->OriginalFirstThunk); ++ for (; pIAT->u1.Function; ++pIAT, ++pINT) ++ { ++ if (IMAGE_SNAP_BY_ORDINAL(pINT->u1.Ordinal)) ++ continue; ++ pImpName = (PIMAGE_IMPORT_BY_NAME)(pImage + pINT->u1.AddressOfData); ++ if (strcmp(pImpName->Name, funcname) == 0) ++ return (void *)pIAT->u1.Function; ++ } ++ } ++ return NULL; ++ } ++ ++ /* + * Try opening the iconv.dll and return TRUE if iconv() can be used. + */ + int +*************** +*** 4326,4332 **** + iconv_open = (void *)GetProcAddress(hIconvDLL, "libiconv_open"); + iconv_close = (void *)GetProcAddress(hIconvDLL, "libiconv_close"); + iconvctl = (void *)GetProcAddress(hIconvDLL, "libiconvctl"); +! iconv_errno = (void *)GetProcAddress(hMsvcrtDLL, "_errno"); + if (iconv == NULL || iconv_open == NULL || iconv_close == NULL + || iconvctl == NULL || iconv_errno == NULL) + { +--- 4364,4372 ---- + iconv_open = (void *)GetProcAddress(hIconvDLL, "libiconv_open"); + iconv_close = (void *)GetProcAddress(hIconvDLL, "libiconv_close"); + iconvctl = (void *)GetProcAddress(hIconvDLL, "libiconvctl"); +! iconv_errno = get_iconv_import_func(hIconvDLL, "_errno"); +! if (iconv_errno == NULL) +! iconv_errno = (void *)GetProcAddress(hMsvcrtDLL, "_errno"); + if (iconv == NULL || iconv_open == NULL || iconv_close == NULL + || iconvctl == NULL || iconv_errno == NULL) + { +*** ../vim-7.3.766/src/version.c 2013-01-17 14:09:39.000000000 +0100 +--- src/version.c 2013-01-17 14:34:19.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 767, + /**/ + +-- +FIRST HEAD: Oh! quick! get the sword out I want to cut his head off. +THIRD HEAD: Oh, cut your own head off. +SECOND HEAD: Yes - do us all a favour. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 99db9aaa786e51c27eeac7452cc76eb0582007fe Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:32 +0100 Subject: [PATCH 0646/3340] - patchlevel 768 --- 7.3.768 | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 7.3.768 diff --git a/7.3.768 b/7.3.768 new file mode 100644 index 00000000..3eadd536 --- /dev/null +++ b/7.3.768 @@ -0,0 +1,68 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.768 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.768 +Problem: settabvar() and setwinvar() may move the cursor. +Solution: Save and restore the cursor position when appropriate. (idea by + Yasuhiro Matsumoto) +Files: src/edit.c + + +*** ../vim-7.3.767/src/edit.c 2012-10-21 00:10:29.000000000 +0200 +--- src/edit.c 2013-01-17 15:32:10.000000000 +0100 +*************** +*** 372,377 **** +--- 372,379 ---- + */ + if (cmdchar != 'r' && cmdchar != 'v') + { ++ pos_T save_cursor = curwin->w_cursor; ++ + # ifdef FEAT_EVAL + if (cmdchar == 'R') + ptr = (char_u *)"r"; +*************** +*** 382,387 **** +--- 384,402 ---- + set_vim_var_string(VV_INSERTMODE, ptr, 1); + # endif + apply_autocmds(EVENT_INSERTENTER, NULL, NULL, FALSE, curbuf); ++ ++ /* Since Insert mode was not started yet a call to check_cursor_col() ++ * may have moved the cursor, especially with the "A" command. */ ++ if (curwin->w_cursor.col != save_cursor.col ++ && curwin->w_cursor.lnum == save_cursor.lnum) ++ { ++ int save_state = State; ++ ++ curwin->w_cursor = save_cursor; ++ State = INSERT; ++ check_cursor_col(); ++ State = save_state; ++ } + } + #endif + +*** ../vim-7.3.767/src/version.c 2013-01-17 14:39:43.000000000 +0100 +--- src/version.c 2013-01-17 15:10:48.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 768, + /**/ + +-- +Life would be so much easier if we could just look at the source code. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5386764db4239e75e344b9915a7d07f5f955825d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:33 +0100 Subject: [PATCH 0647/3340] - patchlevel 769 --- 7.3.769 | 450 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 450 insertions(+) create mode 100644 7.3.769 diff --git a/7.3.769 b/7.3.769 new file mode 100644 index 00000000..aac4579f --- /dev/null +++ b/7.3.769 @@ -0,0 +1,450 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.769 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.769 +Problem: 'matchpairs' does not work with multi-byte characters. +Solution: Make it work. (Christian Brabandt) +Files: src/misc1.c, src/option.c, src/proto/option.pro, src/search.c, + src/testdir/test69.in, src/testdir/test69.ok + + +*** ../vim-7.3.768/src/misc1.c 2012-08-15 14:04:50.000000000 +0200 +--- src/misc1.c 2013-01-17 15:55:09.000000000 +0100 +*************** +*** 2288,2301 **** + */ + if (p_sm && (State & INSERT) + && msg_silent == 0 +- #ifdef FEAT_MBYTE +- && charlen == 1 +- #endif + #ifdef FEAT_INS_EXPAND + && !ins_compl_active() + #endif + ) +! showmatch(c); + + #ifdef FEAT_RIGHTLEFT + if (!p_ri || (State & REPLACE_FLAG)) +--- 2288,2305 ---- + */ + if (p_sm && (State & INSERT) + && msg_silent == 0 + #ifdef FEAT_INS_EXPAND + && !ins_compl_active() + #endif + ) +! { +! #ifdef FEAT_MBYTE +! if (has_mbyte) +! showmatch(mb_ptr2char(buf)); +! else +! #endif +! showmatch(c); +! } + + #ifdef FEAT_RIGHTLEFT + if (!p_ri || (State & REPLACE_FLAG)) +*** ../vim-7.3.768/src/option.c 2012-12-05 14:42:56.000000000 +0100 +--- src/option.c 2013-01-17 16:38:42.000000000 +0100 +*************** +*** 6149,6164 **** + /* 'matchpairs' */ + else if (gvarp == &p_mps) + { +! /* Check for "x:y,x:y" */ +! for (p = *varp; *p != NUL; p += 4) + { +! if (p[1] != ':' || p[2] == NUL || (p[3] != NUL && p[3] != ',')) + { +! errmsg = e_invarg; +! break; + } +- if (p[3] == NUL) +- break; + } + } + +--- 6149,6194 ---- + /* 'matchpairs' */ + else if (gvarp == &p_mps) + { +! #ifdef FEAT_MBYTE +! if (has_mbyte) + { +! for (p = *varp; *p != NUL; ++p) + { +! int x2,x3 = -1; +! +! if (*p != NUL) +! p += mb_ptr2len(p); +! if (*p != NUL) +! x2 = *p++; +! if (*p != NUL) +! { +! x3 = mb_ptr2char(p); +! p += mb_ptr2len(p); +! } +! if (x2 != ':' || x2 == -1 || x3 == -1 +! || (*p != NUL && *p != ',')) +! { +! errmsg = e_invarg; +! break; +! } +! if (*p == NUL) +! break; +! } +! } +! else +! #endif +! { +! /* Check for "x:y,x:y" */ +! for (p = *varp; *p != NUL; p += 4) +! { +! if (p[1] != ':' || p[2] == NUL || (p[3] != NUL && p[3] != ',')) +! { +! errmsg = e_invarg; +! break; +! } +! if (p[3] == NUL) +! break; + } + } + } + +*************** +*** 11453,11455 **** +--- 11483,11583 ---- + { + return curbuf->b_p_sts < 0 ? get_sw_value() : curbuf->b_p_sts; + } ++ ++ /* ++ * Check matchpairs option for "*initc". ++ * If there is a match set "*initc" to the matching character and "*findc" to ++ * the opposite character. Set "*backwards" to the direction. ++ * When "switchit" is TRUE swap the direction. ++ */ ++ void ++ find_mps_values(initc, findc, backwards, switchit) ++ int *initc; ++ int *findc; ++ int *backwards; ++ int switchit; ++ { ++ char_u *ptr; ++ ++ ptr = curbuf->b_p_mps; ++ while (*ptr != NUL) ++ { ++ #ifdef FEAT_MBYTE ++ if (has_mbyte) ++ { ++ char_u *prev; ++ ++ if (mb_ptr2char(ptr) == *initc) ++ { ++ if (switchit) ++ { ++ *findc = *initc; ++ *initc = mb_ptr2char(ptr + mb_ptr2len(ptr) + 1); ++ *backwards = TRUE; ++ } ++ else ++ { ++ *findc = mb_ptr2char(ptr + mb_ptr2len(ptr) + 1); ++ *backwards = FALSE; ++ } ++ return; ++ } ++ prev = ptr; ++ ptr += mb_ptr2len(ptr) + 1; ++ if (mb_ptr2char(ptr) == *initc) ++ { ++ if (switchit) ++ { ++ *findc = *initc; ++ *initc = mb_ptr2char(prev); ++ *backwards = FALSE; ++ } ++ else ++ { ++ *findc = mb_ptr2char(prev); ++ *backwards = TRUE; ++ } ++ return; ++ } ++ ptr += mb_ptr2len(ptr); ++ } ++ else ++ #endif ++ { ++ if (*ptr == *initc) ++ { ++ if (switchit) ++ { ++ *backwards = TRUE; ++ *findc = *initc; ++ *initc = ptr[2]; ++ } ++ else ++ { ++ *backwards = FALSE; ++ *findc = ptr[2]; ++ } ++ return; ++ } ++ ptr += 2; ++ if (*ptr == *initc) ++ { ++ if (switchit) ++ { ++ *backwards = FALSE; ++ *findc = *initc; ++ *initc = ptr[-2]; ++ } ++ else ++ { ++ *backwards = TRUE; ++ *findc = ptr[-2]; ++ } ++ return; ++ } ++ ++ptr; ++ } ++ if (*ptr == ',') ++ ++ptr; ++ } ++ } +*** ../vim-7.3.768/src/proto/option.pro 2012-12-05 14:42:56.000000000 +0100 +--- src/proto/option.pro 2013-01-17 16:39:30.000000000 +0100 +*************** +*** 59,62 **** +--- 59,63 ---- + int check_ff_value __ARGS((char_u *p)); + long get_sw_value __ARGS((void)); + long get_sts_value __ARGS((void)); ++ void find_mps_values __ARGS((int *initc, int *findc, int *backwards, int switchit)); + /* vim: set ft=c : */ +*** ../vim-7.3.768/src/search.c 2012-10-03 13:35:45.000000000 +0200 +--- src/search.c 2013-01-17 16:50:12.000000000 +0100 +*************** +*** 1786,1813 **** + } + else if (initc != '#' && initc != NUL) + { +! /* 'matchpairs' is "x:y,x:y" */ +! for (ptr = curbuf->b_p_mps; *ptr; ptr += 2) +! { +! if (*ptr == initc) +! { +! findc = initc; +! initc = ptr[2]; +! backwards = TRUE; +! break; +! } +! ptr += 2; +! if (*ptr == initc) +! { +! findc = initc; +! initc = ptr[-2]; +! backwards = FALSE; +! break; +! } +! if (ptr[1] != ',') +! break; +! } +! if (!findc) /* invalid initc! */ + return NULL; + } + /* +--- 1786,1793 ---- + } + else if (initc != '#' && initc != NUL) + { +! find_mps_values(&initc, &findc, &backwards, TRUE); +! if (findc == NUL) + return NULL; + } + /* +*************** +*** 1886,1921 **** + --pos.col; + for (;;) + { +! initc = linep[pos.col]; + if (initc == NUL) + break; + +! for (ptr = curbuf->b_p_mps; *ptr; ++ptr) +! { +! if (*ptr == initc) +! { +! findc = ptr[2]; +! backwards = FALSE; +! break; +! } +! ptr += 2; +! if (*ptr == initc) +! { +! findc = ptr[-2]; +! backwards = TRUE; +! break; +! } +! if (!*++ptr) +! break; +! } + if (findc) + break; +! #ifdef FEAT_MBYTE +! if (has_mbyte) +! pos.col += (*mb_ptr2len)(linep + pos.col); +! else +! #endif +! ++pos.col; + } + if (!findc) + { +--- 1866,1879 ---- + --pos.col; + for (;;) + { +! initc = PTR2CHAR(linep + pos.col); + if (initc == NUL) + break; + +! find_mps_values(&initc, &findc, &backwards, FALSE); + if (findc) + break; +! pos.col += MB_PTR2LEN(linep + pos.col); + } + if (!findc) + { +*************** +*** 2260,2266 **** + * inquote if the number of quotes in a line is even, unless this + * line or the previous one ends in a '\'. Complicated, isn't it? + */ +! switch (c = linep[pos.col]) + { + case NUL: + /* at end of line without trailing backslash, reset inquote */ +--- 2218,2225 ---- + * inquote if the number of quotes in a line is even, unless this + * line or the previous one ends in a '\'. Complicated, isn't it? + */ +! c = PTR2CHAR(linep + pos.col); +! switch (c) + { + case NUL: + /* at end of line without trailing backslash, reset inquote */ +*************** +*** 2469,2488 **** + * Only show match for chars in the 'matchpairs' option. + */ + /* 'matchpairs' is "x:y,x:y" */ +! for (p = curbuf->b_p_mps; *p != NUL; p += 2) + { + #ifdef FEAT_RIGHTLEFT +! if (*p == c && (curwin->w_p_rl ^ p_ri)) +! break; + #endif +! p += 2; +! if (*p == c + #ifdef FEAT_RIGHTLEFT + && !(curwin->w_p_rl ^ p_ri) + #endif + ) + break; +! if (p[1] != ',') + return; + } + +--- 2428,2450 ---- + * Only show match for chars in the 'matchpairs' option. + */ + /* 'matchpairs' is "x:y,x:y" */ +! for (p = curbuf->b_p_mps; *p != NUL; ++p) + { ++ if (PTR2CHAR(p) == c + #ifdef FEAT_RIGHTLEFT +! && (curwin->w_p_rl ^ p_ri) + #endif +! ) +! break; +! p += MB_PTR2LEN(p) + 1; +! if (PTR2CHAR(p) == c + #ifdef FEAT_RIGHTLEFT + && !(curwin->w_p_rl ^ p_ri) + #endif + ) + break; +! p += MB_PTR2LEN(p); +! if (*p == NUL) + return; + } + +*** ../vim-7.3.768/src/testdir/test69.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test69.in 2013-01-17 15:55:09.000000000 +0100 +*************** +*** 1,4 **** +--- 1,5 ---- + Test for multi-byte text formatting. ++ Also test, that 'mps' with multibyte chars works. + + STARTTEST + :so mbyte.vim +*************** +*** 134,139 **** +--- 135,149 ---- + } + + STARTTEST ++ /^{/+1 ++ :set mps+=u2018:u2019 ++ d% ++ ENDTEST ++ ++ { ++ ‘ two three ’ four ++ } ++ STARTTEST + :g/^STARTTEST/.,/^ENDTEST/d + :1;/^Results/,$wq! test.out + ENDTEST +*** ../vim-7.3.768/src/testdir/test69.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test69.ok 2013-01-17 15:55:09.000000000 +0100 +*************** +*** 140,142 **** +--- 140,146 ---- + a + } + ++ ++ { ++ four ++ } +*** ../vim-7.3.768/src/version.c 2013-01-17 15:36:54.000000000 +0100 +--- src/version.c 2013-01-17 15:55:49.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 769, + /**/ + +-- +Microsoft's definition of a boolean: TRUE, FALSE, MAYBE +"Embrace and extend"...? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e9d15a70a524d7b9cfd4ffa59d9e29a5ea03f051 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:34 +0100 Subject: [PATCH 0648/3340] - patchlevel 770 --- 7.3.770 | 136 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 136 insertions(+) create mode 100644 7.3.770 diff --git a/7.3.770 b/7.3.770 new file mode 100644 index 00000000..366ca0e2 --- /dev/null +++ b/7.3.770 @@ -0,0 +1,136 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.770 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.770 +Problem: Vim.h indentation is inconsistent. +Solution: Adjust the indentation. (Elias Diem) +Files: src/vim.h + + +*** ../vim-7.3.769/src/vim.h 2012-08-15 14:04:50.000000000 +0200 +--- src/vim.h 2013-01-17 17:12:54.000000000 +0100 +*************** +*** 104,110 **** + # endif + #endif + #if defined(MACOS_X) || defined(MACOS_CLASSIC) +! # define MACOS + #endif + #if defined(MACOS_X) && defined(MACOS_CLASSIC) + Error: To compile for both MACOS X and Classic use a Classic Carbon +--- 104,110 ---- + # endif + #endif + #if defined(MACOS_X) || defined(MACOS_CLASSIC) +! # define MACOS + #endif + #if defined(MACOS_X) && defined(MACOS_CLASSIC) + Error: To compile for both MACOS X and Classic use a Classic Carbon +*************** +*** 490,496 **** + # include + # endif + # if defined(HAVE_STRINGS_H) && !defined(NO_STRINGS_WITH_STRING_H) +! # include + # endif + # ifdef HAVE_STAT_H + # include +--- 490,496 ---- + # include + # endif + # if defined(HAVE_STRINGS_H) && !defined(NO_STRINGS_WITH_STRING_H) +! # include + # endif + # ifdef HAVE_STAT_H + # include +*************** +*** 515,536 **** + # include + #endif + +! # if defined(HAVE_SYS_SELECT_H) && \ + (!defined(HAVE_SYS_TIME_H) || defined(SYS_SELECT_WITH_SYS_TIME)) +! # include +! # endif + +! # ifndef HAVE_SELECT +! # ifdef HAVE_SYS_POLL_H +! # include + # define HAVE_POLL +- # else +- # ifdef HAVE_POLL_H +- # include +- # define HAVE_POLL +- # endif + # endif + # endif + + /* ================ end of the header file puzzle =============== */ + +--- 515,536 ---- + # include + #endif + +! #if defined(HAVE_SYS_SELECT_H) && \ + (!defined(HAVE_SYS_TIME_H) || defined(SYS_SELECT_WITH_SYS_TIME)) +! # include +! #endif + +! #ifndef HAVE_SELECT +! # ifdef HAVE_SYS_POLL_H +! # include +! # define HAVE_POLL +! # else +! # ifdef HAVE_POLL_H +! # include + # define HAVE_POLL + # endif + # endif ++ #endif + + /* ================ end of the header file puzzle =============== */ + +*************** +*** 1877,1884 **** + /* VIM_ATOM_NAME is the older Vim-specific selection type for X11. Still + * supported for when a mix of Vim versions is used. VIMENC_ATOM_NAME includes + * the encoding to support Vims using different 'encoding' values. */ +! #define VIM_ATOM_NAME "_VIM_TEXT" +! #define VIMENC_ATOM_NAME "_VIMENC_TEXT" + + /* Selection states for modeless selection */ + # define SELECT_CLEARED 0 +--- 1877,1884 ---- + /* VIM_ATOM_NAME is the older Vim-specific selection type for X11. Still + * supported for when a mix of Vim versions is used. VIMENC_ATOM_NAME includes + * the encoding to support Vims using different 'encoding' values. */ +! # define VIM_ATOM_NAME "_VIM_TEXT" +! # define VIMENC_ATOM_NAME "_VIMENC_TEXT" + + /* Selection states for modeless selection */ + # define SELECT_CLEARED 0 +*** ../vim-7.3.769/src/version.c 2013-01-17 17:01:57.000000000 +0100 +--- src/version.c 2013-01-17 17:16:45.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 770, + /**/ + +-- +FIRST HEAD: All right! All right! We'll kill him first and then have tea and + biscuits. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7a407322fb8c255e77ca3f3c911e18fb404ac92e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:36 +0100 Subject: [PATCH 0649/3340] - patchlevel 771 --- 7.3.771 | 74 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 7.3.771 diff --git a/7.3.771 b/7.3.771 new file mode 100644 index 00000000..1d8e9888 --- /dev/null +++ b/7.3.771 @@ -0,0 +1,74 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.771 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.771 (after 7.3.769) +Problem: Uninitialized variable. (Yasuhiro Matsumoto) +Solution: Set x2 to -1. +Files: src/option.c + + +*** ../vim-7.3.770/src/option.c 2013-01-17 17:01:56.000000000 +0100 +--- src/option.c 2013-01-17 17:31:56.000000000 +0100 +*************** +*** 6154,6160 **** + { + for (p = *varp; *p != NUL; ++p) + { +! int x2,x3 = -1; + + if (*p != NUL) + p += mb_ptr2len(p); +--- 6154,6161 ---- + { + for (p = *varp; *p != NUL; ++p) + { +! int x2 = -1; +! int x3 = -1; + + if (*p != NUL) + p += mb_ptr2len(p); +*************** +*** 6165,6172 **** + x3 = mb_ptr2char(p); + p += mb_ptr2len(p); + } +! if (x2 != ':' || x2 == -1 || x3 == -1 +! || (*p != NUL && *p != ',')) + { + errmsg = e_invarg; + break; +--- 6166,6172 ---- + x3 = mb_ptr2char(p); + p += mb_ptr2len(p); + } +! if (x2 != ':' || x3 == -1 || (*p != NUL && *p != ',')) + { + errmsg = e_invarg; + break; +*** ../vim-7.3.770/src/version.c 2013-01-17 17:17:21.000000000 +0100 +--- src/version.c 2013-01-17 17:37:24.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 771, + /**/ + +-- + GALAHAD turns back. We see from his POV the lovely ZOOT standing by him + smiling enchantingly and a number of equally delectable GIRLIES draped + around in the seductively poulticed room. They look at him smilingly and + wave. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a43378749ae230a6ea4cdc82d0e30e4704922c78 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:37 +0100 Subject: [PATCH 0650/3340] - patchlevel 772 --- 7.3.772 | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 7.3.772 diff --git a/7.3.772 b/7.3.772 new file mode 100644 index 00000000..c58ff406 --- /dev/null +++ b/7.3.772 @@ -0,0 +1,51 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.772 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.772 +Problem: Cursor is at the wrong location and below the end of the file + after doing substitutions with confirm flag: %s/x/y/c + (Dominique Pelle) +Solution: Update the cursor position. (Christian Brabandt & Dominique) +Files: src/ex_cmds.c + + +*** ../vim-7.3.771/src/ex_cmds.c 2013-01-17 14:09:39.000000000 +0100 +--- src/ex_cmds.c 2013-01-17 18:31:38.000000000 +0100 +*************** +*** 5200,5205 **** +--- 5200,5211 ---- + EMSG2(_(e_patnotf2), get_search_pat()); + } + ++ #ifdef FEAT_FOLDING ++ if (do_ask && hasAnyFolding(curwin)) ++ /* Cursor position may require updating */ ++ changed_window_setting(); ++ #endif ++ + vim_free(regmatch.regprog); + } + +*** ../vim-7.3.771/src/version.c 2013-01-17 17:37:31.000000000 +0100 +--- src/version.c 2013-01-17 18:32:56.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 772, + /**/ + +-- +Linux is just like a wigwam: no Windows, no Gates and an Apache inside. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From dc4cd9f115b22b7063451fe9b47ed705f905516b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:38 +0100 Subject: [PATCH 0651/3340] - patchlevel 773 --- 7.3.773 | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 7.3.773 diff --git a/7.3.773 b/7.3.773 new file mode 100644 index 00000000..225eef24 --- /dev/null +++ b/7.3.773 @@ -0,0 +1,45 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.773 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.773 (after 7.3.767) +Problem: Crash when OriginalFirstThunk is zero. +Solution: Skip items with OriginalFirstThunk not set. (Ken Takata) +Files: src/mbyte.c + + +*** ../vim-7.3.772/src/mbyte.c 2013-01-17 14:39:43.000000000 +0100 +--- src/mbyte.c 2013-01-19 13:59:21.000000000 +0100 +*************** +*** 4317,4322 **** +--- 4317,4324 ---- + .VirtualAddress); + for (; pImpDesc->FirstThunk; ++pImpDesc) + { ++ if (!pImpDesc->OriginalFirstThunk) ++ continue; + pIAT = (PIMAGE_THUNK_DATA)(pImage + pImpDesc->FirstThunk); + pINT = (PIMAGE_THUNK_DATA)(pImage + pImpDesc->OriginalFirstThunk); + for (; pIAT->u1.Function; ++pIAT, ++pINT) +*** ../vim-7.3.772/src/version.c 2013-01-17 18:33:58.000000000 +0100 +--- src/version.c 2013-01-19 14:01:50.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 773, + /**/ + +-- +Experience is what you get when you don't get what you want. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f20505ddbee1c0bf9e392dc07b2cb0ceaeadc331 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:39 +0100 Subject: [PATCH 0652/3340] - patchlevel 774 --- 7.3.774 | 84 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 7.3.774 diff --git a/7.3.774 b/7.3.774 new file mode 100644 index 00000000..5e36ffd8 --- /dev/null +++ b/7.3.774 @@ -0,0 +1,84 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.774 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.774 +Problem: Tiny GUI version misses console dialog feature. +Solution: Define FEAT_CON_DIALOG when apprpriate. (Christian Brabandt) +Files: src/feature.h, src/gui.h + + +*** ../vim-7.3.773/src/feature.h 2012-10-21 02:17:28.000000000 +0200 +--- src/feature.h 2013-01-23 13:33:52.000000000 +0100 +*************** +*** 792,797 **** +--- 792,806 ---- + #endif + + /* ++ * On some systems, when we compile with the GUI, we always use it. On Mac ++ * there is no terminal version, and on Windows we can't figure out how to ++ * fork one off with :gui. ++ */ ++ #if defined(FEAT_GUI_MSWIN) || (defined(FEAT_GUI_MAC) && !defined(MACOS_X_UNIX)) ++ # define ALWAYS_USE_GUI ++ #endif ++ ++ /* + * +dialog_gui Use GUI dialog. + * +dialog_con May use Console dialog. + * When none of these defined there is no dialog support. +*************** +*** 820,825 **** +--- 829,837 ---- + || defined(FEAT_GUI_GTK) || defined(FEAT_GUI_MSWIN) \ + || defined(FEAT_GUI_PHOTON) || defined(FEAT_GUI_MAC)) + # define FEAT_GUI_TEXTDIALOG ++ # ifndef ALWAYS_USE_GUI ++ # define FEAT_CON_DIALOG ++ # endif + #endif + + /* Mac specific thing: Codewarrior interface. */ +*** ../vim-7.3.773/src/gui.h 2011-06-26 04:48:56.000000000 +0200 +--- src/gui.h 2013-01-23 13:33:24.000000000 +0100 +*************** +*** 59,73 **** + #endif + + /* +- * On some systems, when we compile with the GUI, we always use it. On Mac +- * there is no terminal version, and on Windows we can't figure out how to +- * fork one off with :gui. +- */ +- #if defined(FEAT_GUI_MSWIN) || (defined(FEAT_GUI_MAC) && !defined(MACOS_X_UNIX)) +- # define ALWAYS_USE_GUI +- #endif +- +- /* + * On some systems scrolling needs to be done right away instead of in the + * main loop. + */ +--- 59,64 ---- +*** ../vim-7.3.773/src/version.c 2013-01-19 14:01:57.000000000 +0100 +--- src/version.c 2013-01-23 13:38:12.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 774, + /**/ + +-- +Overflow on /dev/null, please empty the bit bucket. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 549678a5b6da40ccc612df16e126612479366824 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:40 +0100 Subject: [PATCH 0653/3340] - patchlevel 775 --- 7.3.775 | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 7.3.775 diff --git a/7.3.775 b/7.3.775 new file mode 100644 index 00000000..a70a7b34 --- /dev/null +++ b/7.3.775 @@ -0,0 +1,72 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.775 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.775 +Problem: Cygwin and Mingw builds miss dependency on gui_w48.c. +Solution: Add a build rule. (Ken Takata) +Files: src/Make_cyg.mak, src/Make_ming.mak + + +*** ../vim-7.3.774/src/Make_cyg.mak 2012-11-28 16:18:26.000000000 +0100 +--- src/Make_cyg.mak 2013-01-23 13:53:48.000000000 +0100 +*************** +*** 600,605 **** +--- 600,608 ---- + $(OUTDIR)/ex_eval.o: ex_eval.c $(INCL) ex_cmds.h + $(CC) -c $(CFLAGS) ex_eval.c -o $(OUTDIR)/ex_eval.o + ++ $(OUTDIR)/gui_w32.o: gui_w32.c gui_w48.c $(INCL) ++ $(CC) -c $(CFLAGS) gui_w32.c -o $(OUTDIR)/gui_w32.o ++ + $(OUTDIR)/if_cscope.o: if_cscope.c $(INCL) if_cscope.h + $(CC) -c $(CFLAGS) if_cscope.c -o $(OUTDIR)/if_cscope.o + +*** ../vim-7.3.774/src/Make_ming.mak 2012-11-28 16:18:26.000000000 +0100 +--- src/Make_ming.mak 2013-01-23 13:53:48.000000000 +0100 +*************** +*** 731,736 **** +--- 731,739 ---- + $(OUTDIR)/ex_eval.o: ex_eval.c $(INCL) ex_cmds.h + $(CC) -c $(CFLAGS) ex_eval.c -o $(OUTDIR)/ex_eval.o + ++ $(OUTDIR)/gui_w32.o: gui_w32.c gui_w48.c $(INCL) ++ $(CC) -c $(CFLAGS) gui_w32.c -o $(OUTDIR)/gui_w32.o ++ + $(OUTDIR)/if_cscope.o: if_cscope.c $(INCL) if_cscope.h + $(CC) -c $(CFLAGS) if_cscope.c -o $(OUTDIR)/if_cscope.o + +*** ../vim-7.3.774/src/version.c 2013-01-23 13:40:54.000000000 +0100 +--- src/version.c 2013-01-23 13:53:34.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 775, + /**/ + +-- + ** Hello and Welcome to the Psychiatric Hotline ** +If you are obsessive-compulsive, please press 1 repeatedly. +If you are co-dependent, please ask someone to press 2. +If you have multiple personalities, please press 3, 4, 5 and 6. +If you are paranoid-delusional, we know who you are and what you want + - just stay on the line so we can trace the call. +If you are schizophrenic, listen carefully and a little voice will + tell you which number to press next. +If you are manic-depressive, it doesn't matter which number you press + - no one will answer. +If you suffer from panic attacks, push every button you can find. +If you are sane, please hold on - we have the rest of humanity on the + other line and they desparately want to ask you a few questions. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 94a1f8fbe690a57247b2adffb48eab005b5fa43c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:41 +0100 Subject: [PATCH 0654/3340] - patchlevel 776 --- 7.3.776 | 435 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 435 insertions(+) create mode 100644 7.3.776 diff --git a/7.3.776 b/7.3.776 new file mode 100644 index 00000000..fb052168 --- /dev/null +++ b/7.3.776 @@ -0,0 +1,435 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.776 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.776 +Problem: ml_get error when searching, caused by curwin not matching curbuf. +Solution: Avoid changing curbuf. (Lech Lorens) +Files: src/charset.c, src/eval.c, src/mark.c, src/proto/charset.pro, + src/proto/mark.pro, src/regexp.c, src/syntax.c + + +*** ../vim-7.3.775/src/charset.c 2012-05-25 11:56:06.000000000 +0200 +--- src/charset.c 2013-01-23 15:43:37.000000000 +0100 +*************** +*** 905,910 **** +--- 905,918 ---- + vim_iswordc(c) + int c; + { ++ return vim_iswordc_buf(c, curbuf); ++ } ++ ++ int ++ vim_iswordc_buf(c, buf) ++ int c; ++ buf_T *buf; ++ { + #ifdef FEAT_MBYTE + if (c >= 0x100) + { +*************** +*** 914,920 **** + return utf_class(c) >= 2; + } + #endif +! return (c > 0 && c < 0x100 && GET_CHARTAB(curbuf, c) != 0); + } + + /* +--- 922,928 ---- + return utf_class(c) >= 2; + } + #endif +! return (c > 0 && c < 0x100 && GET_CHARTAB(buf, c) != 0); + } + + /* +*************** +*** 933,939 **** + + #if defined(FEAT_SYN_HL) || defined(PROTO) + int +! vim_iswordc_buf(p, buf) + char_u *p; + buf_T *buf; + { +--- 941,947 ---- + + #if defined(FEAT_SYN_HL) || defined(PROTO) + int +! vim_iswordp_buf(p, buf) + char_u *p; + buf_T *buf; + { +*** ../vim-7.3.775/src/eval.c 2012-12-05 16:10:21.000000000 +0100 +--- src/eval.c 2013-01-23 14:24:08.000000000 +0100 +*************** +*** 18884,18890 **** + #endif + if (name[0] == '\'') /* mark */ + { +! pp = getmark_fnum(name[1], FALSE, fnum); + if (pp == NULL || pp == (pos_T *)-1 || pp->lnum <= 0) + return NULL; + return pp; +--- 18884,18890 ---- + #endif + if (name[0] == '\'') /* mark */ + { +! pp = getmark_buf_fnum(curbuf, name[1], FALSE, fnum); + if (pp == NULL || pp == (pos_T *)-1 || pp->lnum <= 0) + return NULL; + return pp; +*** ../vim-7.3.775/src/mark.c 2012-07-06 17:51:24.000000000 +0200 +--- src/mark.c 2013-01-23 14:24:16.000000000 +0100 +*************** +*** 304,310 **** + #endif + + /* +! * Find mark "c". + * If "changefile" is TRUE it's allowed to edit another file for '0, 'A, etc. + * If "fnum" is not NULL store the fnum there for '0, 'A etc., don't edit + * another file. +--- 304,310 ---- + #endif + + /* +! * Find mark "c" in buffer pointed to by "buf". + * If "changefile" is TRUE it's allowed to edit another file for '0, 'A, etc. + * If "fnum" is not NULL store the fnum there for '0, 'A etc., don't edit + * another file. +*************** +*** 315,329 **** + * - -1 if mark is in other file and jumped there (only if changefile is TRUE) + */ + pos_T * + getmark(c, changefile) + int c; + int changefile; + { +! return getmark_fnum(c, changefile, NULL); + } + + pos_T * +! getmark_fnum(c, changefile, fnum) + int c; + int changefile; + int *fnum; +--- 315,339 ---- + * - -1 if mark is in other file and jumped there (only if changefile is TRUE) + */ + pos_T * ++ getmark_buf(buf, c, changefile) ++ buf_T *buf; ++ int c; ++ int changefile; ++ { ++ return getmark_buf_fnum(buf, c, changefile, NULL); ++ } ++ ++ pos_T * + getmark(c, changefile) + int c; + int changefile; + { +! return getmark_buf_fnum(curbuf, c, changefile, NULL); + } + + pos_T * +! getmark_buf_fnum(buf, c, changefile, fnum) +! buf_T *buf; + int c; + int changefile; + int *fnum; +*************** +*** 351,365 **** + posp = &pos_copy; /* w_pcmark may be changed soon */ + } + else if (c == '"') /* to pos when leaving buffer */ +! posp = &(curbuf->b_last_cursor); + else if (c == '^') /* to where Insert mode stopped */ +! posp = &(curbuf->b_last_insert); + else if (c == '.') /* to where last change was made */ +! posp = &(curbuf->b_last_change); + else if (c == '[') /* to start of previous operator */ +! posp = &(curbuf->b_op_start); + else if (c == ']') /* to end of previous operator */ +! posp = &(curbuf->b_op_end); + else if (c == '{' || c == '}') /* to previous/next paragraph */ + { + pos_T pos; +--- 361,375 ---- + posp = &pos_copy; /* w_pcmark may be changed soon */ + } + else if (c == '"') /* to pos when leaving buffer */ +! posp = &(buf->b_last_cursor); + else if (c == '^') /* to where Insert mode stopped */ +! posp = &(buf->b_last_insert); + else if (c == '.') /* to where last change was made */ +! posp = &(buf->b_last_change); + else if (c == '[') /* to start of previous operator */ +! posp = &(buf->b_op_start); + else if (c == ']') /* to end of previous operator */ +! posp = &(buf->b_op_end); + else if (c == '{' || c == '}') /* to previous/next paragraph */ + { + pos_T pos; +*************** +*** 395,402 **** + #ifdef FEAT_VISUAL + else if (c == '<' || c == '>') /* start/end of visual area */ + { +! startp = &curbuf->b_visual.vi_start; +! endp = &curbuf->b_visual.vi_end; + if ((c == '<') == lt(*startp, *endp)) + posp = startp; + else +--- 405,412 ---- + #ifdef FEAT_VISUAL + else if (c == '<' || c == '>') /* start/end of visual area */ + { +! startp = &buf->b_visual.vi_start; +! endp = &buf->b_visual.vi_end; + if ((c == '<') == lt(*startp, *endp)) + posp = startp; + else +*************** +*** 404,410 **** + /* + * For Visual line mode, set mark at begin or end of line + */ +! if (curbuf->b_visual.vi_mode == 'V') + { + pos_copy = *posp; + posp = &pos_copy; +--- 414,420 ---- + /* + * For Visual line mode, set mark at begin or end of line + */ +! if (buf->b_visual.vi_mode == 'V') + { + pos_copy = *posp; + posp = &pos_copy; +*************** +*** 420,426 **** + #endif + else if (ASCII_ISLOWER(c)) /* normal named mark */ + { +! posp = &(curbuf->b_namedm[c - 'a']); + } + else if (ASCII_ISUPPER(c) || VIM_ISDIGIT(c)) /* named file mark */ + { +--- 430,436 ---- + #endif + else if (ASCII_ISLOWER(c)) /* normal named mark */ + { +! posp = &(buf->b_namedm[c - 'a']); + } + else if (ASCII_ISUPPER(c) || VIM_ISDIGIT(c)) /* named file mark */ + { +*************** +*** 435,441 **** + + if (fnum != NULL) + *fnum = namedfm[c].fmark.fnum; +! else if (namedfm[c].fmark.fnum != curbuf->b_fnum) + { + /* mark is in another file */ + posp = &pos_copy; +--- 445,451 ---- + + if (fnum != NULL) + *fnum = namedfm[c].fmark.fnum; +! else if (namedfm[c].fmark.fnum != buf->b_fnum) + { + /* mark is in another file */ + posp = &pos_copy; +*** ../vim-7.3.775/src/proto/charset.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/charset.pro 2013-01-23 15:43:25.000000000 +0100 +*************** +*** 19,26 **** + int win_linetabsize __ARGS((win_T *wp, char_u *p, colnr_T len)); + int vim_isIDc __ARGS((int c)); + int vim_iswordc __ARGS((int c)); + int vim_iswordp __ARGS((char_u *p)); +! int vim_iswordc_buf __ARGS((char_u *p, buf_T *buf)); + int vim_isfilec __ARGS((int c)); + int vim_isfilec_or_wc __ARGS((int c)); + int vim_isprintc __ARGS((int c)); +--- 19,27 ---- + int win_linetabsize __ARGS((win_T *wp, char_u *p, colnr_T len)); + int vim_isIDc __ARGS((int c)); + int vim_iswordc __ARGS((int c)); ++ int vim_iswordc_buf __ARGS((int c, buf_T *buf)); + int vim_iswordp __ARGS((char_u *p)); +! int vim_iswordp_buf __ARGS((char_u *p, buf_T *buf)); + int vim_isfilec __ARGS((int c)); + int vim_isfilec_or_wc __ARGS((int c)); + int vim_isprintc __ARGS((int c)); +*** ../vim-7.3.775/src/proto/mark.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/mark.pro 2013-01-23 14:24:23.000000000 +0100 +*************** +*** 5,12 **** + void checkpcmark __ARGS((void)); + pos_T *movemark __ARGS((int count)); + pos_T *movechangelist __ARGS((int count)); + pos_T *getmark __ARGS((int c, int changefile)); +! pos_T *getmark_fnum __ARGS((int c, int changefile, int *fnum)); + pos_T *getnextmark __ARGS((pos_T *startpos, int dir, int begin_line)); + void fmarks_check_names __ARGS((buf_T *buf)); + int check_mark __ARGS((pos_T *pos)); +--- 5,13 ---- + void checkpcmark __ARGS((void)); + pos_T *movemark __ARGS((int count)); + pos_T *movechangelist __ARGS((int count)); ++ pos_T *getmark_buf __ARGS((buf_T *buf, int c, int changefile)); + pos_T *getmark __ARGS((int c, int changefile)); +! pos_T *getmark_buf_fnum __ARGS((buf_T *buf, int c, int changefile, int *fnum)); + pos_T *getnextmark __ARGS((pos_T *startpos, int dir, int begin_line)); + void fmarks_check_names __ARGS((buf_T *buf)); + int check_mark __ARGS((pos_T *pos)); +*** ../vim-7.3.775/src/regexp.c 2011-07-20 17:58:14.000000000 +0200 +--- src/regexp.c 2013-01-23 14:19:15.000000000 +0100 +*************** +*** 3623,3629 **** + proftime_T *tm; /* timeout limit or NULL */ + { + long r; +- buf_T *save_curbuf = curbuf; + + reg_match = NULL; + reg_mmatch = rmp; +--- 3623,3628 ---- +*************** +*** 3638,3647 **** + #endif + ireg_maxcol = rmp->rmm_maxcol; + +- /* Need to switch to buffer "buf" to make vim_iswordc() work. */ +- curbuf = buf; + r = vim_regexec_both(NULL, col, tm); +- curbuf = save_curbuf; + + return r; + } +--- 3637,3643 ---- +*************** +*** 4185,4191 **** + int cmp = OPERAND(scan)[1]; + pos_T *pos; + +! pos = getmark(mark, FALSE); + if (pos == NULL /* mark doesn't exist */ + || pos->lnum <= 0 /* mark isn't set (in curbuf) */ + || (pos->lnum == reglnum + reg_firstlnum +--- 4181,4187 ---- + int cmp = OPERAND(scan)[1]; + pos_T *pos; + +! pos = getmark_buf(reg_buf, mark, FALSE); + if (pos == NULL /* mark doesn't exist */ + || pos->lnum <= 0 /* mark isn't set (in curbuf) */ + || (pos->lnum == reglnum + reg_firstlnum +*************** +*** 4315,4322 **** + #endif + else + { +! if (!vim_iswordc(c) +! || (reginput > regline && vim_iswordc(reginput[-1]))) + status = RA_NOMATCH; + } + break; +--- 4311,4318 ---- + #endif + else + { +! if (!vim_iswordc_buf(c, reg_buf) +! || (reginput > regline && vim_iswordc_buf(reginput[-1], reg_buf))) + status = RA_NOMATCH; + } + break; +*************** +*** 4339,4346 **** + #endif + else + { +! if (!vim_iswordc(reginput[-1]) +! || (reginput[0] != NUL && vim_iswordc(c))) + status = RA_NOMATCH; + } + break; /* Matched with EOW */ +--- 4335,4342 ---- + #endif + else + { +! if (!vim_iswordc_buf(reginput[-1], reg_buf) +! || (reginput[0] != NUL && vim_iswordc_buf(c, reg_buf))) + status = RA_NOMATCH; + } + break; /* Matched with EOW */ +*** ../vim-7.3.775/src/syntax.c 2012-10-21 21:25:17.000000000 +0200 +--- src/syntax.c 2013-01-23 14:19:15.000000000 +0100 +*************** +*** 1954,1962 **** + if (do_keywords) + { + line = syn_getcurline(); +! if (vim_iswordc_buf(line + current_col, syn_buf) + && (current_col == 0 +! || !vim_iswordc_buf(line + current_col - 1 + #ifdef FEAT_MBYTE + - (has_mbyte + ? (*mb_head_off)(line, line + current_col - 1) +--- 1954,1962 ---- + if (do_keywords) + { + line = syn_getcurline(); +! if (vim_iswordp_buf(line + current_col, syn_buf) + && (current_col == 0 +! || !vim_iswordp_buf(line + current_col - 1 + #ifdef FEAT_MBYTE + - (has_mbyte + ? (*mb_head_off)(line, line + current_col - 1) +*************** +*** 3280,3286 **** + #endif + ++kwlen; + } +! while (vim_iswordc_buf(kwp + kwlen, syn_buf)); + + if (kwlen > MAXKEYWLEN) + return 0; +--- 3280,3286 ---- + #endif + ++kwlen; + } +! while (vim_iswordp_buf(kwp + kwlen, syn_buf)); + + if (kwlen > MAXKEYWLEN) + return 0; +*** ../vim-7.3.775/src/version.c 2013-01-23 13:55:16.000000000 +0100 +--- src/version.c 2013-01-23 14:19:44.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 776, + /**/ + +-- +Q: How does a UNIX Guru do Sex ? +A: unzip;strip;touch;finger;mount;fsck;more;yes;umount;sleep + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 73cf9d2373a8406d5de74adf65f0e454d850970f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:42 +0100 Subject: [PATCH 0655/3340] - patchlevel 777 --- 7.3.777 | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.777 diff --git a/7.3.777 b/7.3.777 new file mode 100644 index 00000000..53a2acf2 --- /dev/null +++ b/7.3.777 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.777 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.777 +Problem: When building with Gnome locale gets reset. +Solution: Set locale after gnome_program_init(). (Christian Brabandt) +Files: src/gui_gtk_x11.c + + +*** ../vim-7.3.776/src/gui_gtk_x11.c 2012-05-18 17:03:14.000000000 +0200 +--- src/gui_gtk_x11.c 2013-01-23 15:58:14.000000000 +0100 +*************** +*** 3130,3137 **** +--- 3130,3145 ---- + * exits on failure, but that's a non-issue because we already called + * gtk_init_check() in gui_mch_init_check(). */ + if (using_gnome) ++ { + gnome_program_init(VIMPACKAGE, VIM_VERSION_SHORT, + LIBGNOMEUI_MODULE, gui_argc, gui_argv, NULL); ++ # if defined(FEAT_FLOAT) && defined(LC_NUMERIC) ++ /* Make sure strtod() uses a decimal point, not a comma. Gnome init ++ * may change it. */ ++ if (setlocale(LC_NUMERIC, NULL) != (char *) "C") ++ setlocale(LC_NUMERIC, "C"); ++ # endif ++ } + #endif + vim_free(gui_argv); + gui_argv = NULL; +*** ../vim-7.3.776/src/version.c 2013-01-23 15:53:08.000000000 +0100 +--- src/version.c 2013-01-23 15:56:21.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 777, + /**/ + +-- + [clop clop] +GUARD #1: Halt! Who goes there? +ARTHUR: It is I, Arthur, son of Uther Pendragon, from the castle of + Camelot. King of the Britons, defeator of the Saxons, sovereign of + all England! +GUARD #1: Pull the other one! + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 51f6af431ca65084c91fdd14ee39205519a36d7d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:43 +0100 Subject: [PATCH 0656/3340] - patchlevel 778 --- 7.3.778 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.778 diff --git a/7.3.778 b/7.3.778 new file mode 100644 index 00000000..62a8a91d --- /dev/null +++ b/7.3.778 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.778 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.778 +Problem: Compiler error for adding up two pointers. (Titov Anatoly) +Solution: Add a type cast. (Ken Takata) +Files: src/mbyte.c + + +*** ../vim-7.3.777/src/mbyte.c 2013-01-19 14:01:57.000000000 +0100 +--- src/mbyte.c 2013-01-23 16:18:02.000000000 +0100 +*************** +*** 4325,4331 **** + { + if (IMAGE_SNAP_BY_ORDINAL(pINT->u1.Ordinal)) + continue; +! pImpName = (PIMAGE_IMPORT_BY_NAME)(pImage + pINT->u1.AddressOfData); + if (strcmp(pImpName->Name, funcname) == 0) + return (void *)pIAT->u1.Function; + } +--- 4325,4332 ---- + { + if (IMAGE_SNAP_BY_ORDINAL(pINT->u1.Ordinal)) + continue; +! pImpName = (PIMAGE_IMPORT_BY_NAME)(pImage +! + (UINT_PTR)(pINT->u1.AddressOfData)); + if (strcmp(pImpName->Name, funcname) == 0) + return (void *)pIAT->u1.Function; + } +*** ../vim-7.3.777/src/version.c 2013-01-23 16:00:05.000000000 +0100 +--- src/version.c 2013-01-23 16:18:40.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 778, + /**/ + +-- +'I generally avoid temptation unless I can't resist it." + -- Mae West + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0960a43fbbaad6a6dbbdccfa32030ba8ef101e2a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:44 +0100 Subject: [PATCH 0657/3340] - patchlevel 779 --- 7.3.779 | 86 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 7.3.779 diff --git a/7.3.779 b/7.3.779 new file mode 100644 index 00000000..3bd4e881 --- /dev/null +++ b/7.3.779 @@ -0,0 +1,86 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.779 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.779 +Problem: Backwards search lands in wrong place when started on a multibyte + character. +Solution: Do not set extra_col for a backwards search. (Sung Pae) +Files: src/search.c, src/testdir/test44.in, src/testdir/test44.ok + + +*** ../vim-7.3.778/src/search.c 2013-01-17 17:01:57.000000000 +0100 +--- src/search.c 2013-01-23 16:27:35.000000000 +0100 +*************** +*** 572,578 **** + extra_col = 0; + #ifdef FEAT_MBYTE + /* Watch out for the "col" being MAXCOL - 2, used in a closed fold. */ +! else if (has_mbyte && pos->lnum >= 1 && pos->lnum <= buf->b_ml.ml_line_count + && pos->col < MAXCOL - 2) + { + ptr = ml_get_buf(buf, pos->lnum, FALSE) + pos->col; +--- 572,579 ---- + extra_col = 0; + #ifdef FEAT_MBYTE + /* Watch out for the "col" being MAXCOL - 2, used in a closed fold. */ +! else if (dir != BACKWARD && has_mbyte +! && pos->lnum >= 1 && pos->lnum <= buf->b_ml.ml_line_count + && pos->col < MAXCOL - 2) + { + ptr = ml_get_buf(buf, pos->lnum, FALSE) + pos->col; +*** ../vim-7.3.778/src/testdir/test44.in 2011-07-20 17:58:14.000000000 +0200 +--- src/testdir/test44.in 2013-01-23 16:22:38.000000000 +0100 +*************** +*** 29,34 **** +--- 29,37 ---- + x/\%d21879b + x/ [[=A=]]* [[=B=]]* [[=C=]]* [[=D=]]* [[=E=]]* [[=F=]]* [[=G=]]* [[=H=]]* [[=I=]]* [[=J=]]* [[=K=]]* [[=L=]]* [[=M=]]* [[=N=]]* [[=O=]]* [[=P=]]* [[=Q=]]* [[=R=]]* [[=S=]]* [[=T=]]* [[=U=]]* [[=V=]]* [[=W=]]* [[=X=]]* [[=Y=]]* [[=Z=]]*/e + x/ [[=a=]]* [[=b=]]* [[=c=]]* [[=d=]]* [[=e=]]* [[=f=]]* [[=g=]]* [[=h=]]* [[=i=]]* [[=j=]]* [[=k=]]* [[=l=]]* [[=m=]]* [[=n=]]* [[=o=]]* [[=p=]]* [[=q=]]* [[=r=]]* [[=s=]]* [[=t=]]* [[=u=]]* [[=v=]]* [[=w=]]* [[=x=]]* [[=y=]]* [[=z=]]*/e ++ x:" Test backwards search from a multi-byte char ++ /x ++ x?. + x:?^1?,$w! test.out + :e! test.out + G:put =matchstr(\"×בגד\", \".\", 0, 2) " ב +*************** +*** 57,59 **** +--- 60,63 ---- + g aå•·bb + h AÀÃÂÃÄÅĀĂĄÇǞǠẢ BḂḆ CÇĆĈĊČ DÄŽÄḊḎḠEÈÉÊËĒĔĖĘĚẺẼ FḞ GĜĞĠĢǤǦǴḠ HĤĦḢḦḨ IÃŒÃÃŽÃĨĪĬĮİÇỈ JÄ´ KĶǨḰḴ LĹĻĽĿÅḺ MḾṀ NÑŃŅŇṄṈ OÃ’Ã“Ã”Ã•Ã–Ã˜ÅŒÅŽÅÆ Ç‘ǪǬỎ PṔṖ Q RŔŖŘṘṞ SŚŜŞŠṠ TŢŤŦṪṮ UÙÚÛÜŨŪŬŮŰŲƯǓỦ Vá¹¼ WŴẀẂẄẆ XẊẌ YÃŶŸẎỲỶỸ ZŹŻŽƵáºáº” + i aàáâãäåÄăąǎǟǡả bḃḇ cÃ§Ä‡Ä‰Ä‹Ä dÄđḋá¸á¸‘ eèéêëēĕėęěẻẽ fḟ gÄğġģǥǧǵḡ hĥħḣḧḩẖ iìíîïĩīĭįÇỉ jĵǰ kķǩḱḵ lĺļľŀłḻ mḿṠnñńņňʼnṅṉ oòóôõöøÅÅőơǒǫǭỠpṕṗ q rŕŗřṙṟ sÅ›Åşšṡ tţťŧṫṯẗ uùúûüũūŭůűųưǔủ vá¹½ wŵáºáºƒáº…ẇẘ xẋẠyýÿŷáºáº™á»³á»·á»¹ zźżžƶẑẕ ++ j 0123â¤x +*** ../vim-7.3.778/src/testdir/test44.ok 2011-07-20 17:58:14.000000000 +0200 +--- src/testdir/test44.ok 2013-01-23 16:22:38.000000000 +0100 +*************** +*** 16,21 **** +--- 16,22 ---- + g abb + h AÀÃÂÃÄÅĀĂĄÇǞǠẢ BḂḆ CÇĆĈĊČ DÄŽÄḊḎḠEÈÉÊËĒĔĖĘĚẺẼ FḞ GĜĞĠĢǤǦǴḠ HĤĦḢḦḨ IÃŒÃÃŽÃĨĪĬĮİÇỈ JÄ´ KĶǨḰḴ LĹĻĽĿÅḺ MḾṀ NÑŃŅŇṄṈ OÃ’Ã“Ã”Ã•Ã–Ã˜ÅŒÅŽÅÆ Ç‘ǪǬỎ PṔṖ Q RŔŖŘṘṞ SŚŜŞŠṠ TŢŤŦṪṮ UÙÚÛÜŨŪŬŮŰŲƯǓỦ Vá¹¼ WŴẀẂẄẆ XẊẌ YÃŶŸẎỲỶỸ ZŹŻŽƵẠ+ i aàáâãäåÄăąǎǟǡả bḃḇ cÃ§Ä‡Ä‰Ä‹Ä dÄđḋá¸á¸‘ eèéêëēĕėęěẻẽ fḟ gÄğġģǥǧǵḡ hĥħḣḧḩẖ iìíîïĩīĭįÇỉ jĵǰ kķǩḱḵ lĺļľŀłḻ mḿṠnñńņňʼnṅṉ oòóôõöøÅÅőơǒǫǭỠpṕṗ q rŕŗřṙṟ sÅ›Åşšṡ tţťŧṫṯẗ uùúûüũūŭůűųưǔủ vá¹½ wŵáºáºƒáº…ẇẘ xẋẠyýÿŷáºáº™á»³á»·á»¹ zźżžƶẑ ++ j 012⤠+ ב + בג + × +*** ../vim-7.3.778/src/version.c 2013-01-23 16:19:17.000000000 +0100 +--- src/version.c 2013-01-23 16:39:23.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 779, + /**/ + +-- +Veni, Vidi, Video -- I came, I saw, I taped what I saw. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 99be62d747cd8ed1d59a2bd14cc155d83fb01e5f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:45 +0100 Subject: [PATCH 0658/3340] - patchlevel 780 --- 7.3.780 | 193 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 193 insertions(+) create mode 100644 7.3.780 diff --git a/7.3.780 b/7.3.780 new file mode 100644 index 00000000..40d317b4 --- /dev/null +++ b/7.3.780 @@ -0,0 +1,193 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.780 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.780 +Problem: char2nr() and nr2char() always use 'encoding'. +Solution: Add argument to use utf-8 characters. (Yasuhiro Matsumoto) +Files: runtime/doc/eval.txt, src/eval.c + + +*** ../vim-7.3.779/runtime/doc/eval.txt 2012-12-05 16:10:21.000000000 +0100 +--- runtime/doc/eval.txt 2013-01-23 17:00:52.000000000 +0100 +*************** +*** 1705,1711 **** + any call {func} with arguments {arglist} + ceil( {expr}) Float round {expr} up + changenr() Number current change number +! char2nr( {expr}) Number ASCII value of first char in {expr} + cindent( {lnum}) Number C indent for line {lnum} + clearmatches() none clear all matches + col( {expr}) Number column nr of cursor or mark +--- 1716,1722 ---- + any call {func} with arguments {arglist} + ceil( {expr}) Float round {expr} up + changenr() Number current change number +! char2nr( {expr}[, {utf8}]) Number ASCII/UTF8 value of first char in {expr} + cindent( {lnum}) Number C indent for line {lnum} + clearmatches() none clear all matches + col( {expr}) Number column nr of cursor or mark +*************** +*** 1862,1868 **** + mode( [expr]) String current editing mode + mzeval( {expr}) any evaluate |MzScheme| expression + nextnonblank( {lnum}) Number line nr of non-blank line >= {lnum} +! nr2char( {expr}) String single char with ASCII value {expr} + or( {expr}, {expr}) Number bitwise OR + pathshorten( {expr}) String shorten directory names in a path + pow( {x}, {y}) Float {x} to the power of {y} +--- 1873,1879 ---- + mode( [expr]) String current editing mode + mzeval( {expr}) any evaluate |MzScheme| expression + nextnonblank( {lnum}) Number line nr of non-blank line >= {lnum} +! nr2char( {expr}[, {utf8}]) String single char with ASCII/UTF8 value {expr} + or( {expr}, {expr}) Number bitwise OR + pathshorten( {expr}) String shorten directory names in a path + pow( {x}, {y}) Float {x} to the power of {y} +*************** +*** 2282,2295 **** + redo it is the number of the redone change. After undo it is + one less than the number of the undone change. + +! char2nr({expr}) *char2nr()* + Return number value of the first char in {expr}. Examples: > + char2nr(" ") returns 32 + char2nr("ABC") returns 65 +! < The current 'encoding' is used. Example for "utf-8": > + char2nr("á") returns 225 + char2nr("á"[0]) returns 195 +! < |nr2char()| does the opposite. + + cindent({lnum}) *cindent()* + Get the amount of indent for line {lnum} according the C +--- 2294,2310 ---- + redo it is the number of the redone change. After undo it is + one less than the number of the undone change. + +! char2nr({expr}[, {utf8}]) *char2nr()* + Return number value of the first char in {expr}. Examples: > + char2nr(" ") returns 32 + char2nr("ABC") returns 65 +! < When {utf8} is omitted or zero, the current 'encoding' is used. +! Example for "utf-8": > + char2nr("á") returns 225 + char2nr("á"[0]) returns 195 +! < With {utf8} set to 1, always treat as utf-8 characters. +! A combining character is a separate character. +! |nr2char()| does the opposite. + + cindent({lnum}) *cindent()* + Get the amount of indent for line {lnum} according the C +*** ../vim-7.3.779/src/eval.c 2013-01-23 15:53:08.000000000 +0100 +--- src/eval.c 2013-01-23 16:57:48.000000000 +0100 +*************** +*** 7854,7860 **** + {"ceil", 1, 1, f_ceil}, + #endif + {"changenr", 0, 0, f_changenr}, +! {"char2nr", 1, 1, f_char2nr}, + {"cindent", 1, 1, f_cindent}, + {"clearmatches", 0, 0, f_clearmatches}, + {"col", 1, 1, f_col}, +--- 7854,7860 ---- + {"ceil", 1, 1, f_ceil}, + #endif + {"changenr", 0, 0, f_changenr}, +! {"char2nr", 1, 2, f_char2nr}, + {"cindent", 1, 1, f_cindent}, + {"clearmatches", 0, 0, f_clearmatches}, + {"col", 1, 1, f_col}, +*************** +*** 8003,8009 **** + {"mzeval", 1, 1, f_mzeval}, + #endif + {"nextnonblank", 1, 1, f_nextnonblank}, +! {"nr2char", 1, 1, f_nr2char}, + {"or", 2, 2, f_or}, + {"pathshorten", 1, 1, f_pathshorten}, + #ifdef FEAT_FLOAT +--- 8003,8009 ---- + {"mzeval", 1, 1, f_mzeval}, + #endif + {"nextnonblank", 1, 1, f_nextnonblank}, +! {"nr2char", 1, 2, f_nr2char}, + {"or", 2, 2, f_or}, + {"pathshorten", 1, 1, f_pathshorten}, + #ifdef FEAT_FLOAT +*************** +*** 9303,9309 **** + { + #ifdef FEAT_MBYTE + if (has_mbyte) +! rettv->vval.v_number = (*mb_ptr2char)(get_tv_string(&argvars[0])); + else + #endif + rettv->vval.v_number = get_tv_string(&argvars[0])[0]; +--- 9303,9319 ---- + { + #ifdef FEAT_MBYTE + if (has_mbyte) +! { +! int utf8 = 0; +! +! if (argvars[1].v_type != VAR_UNKNOWN) +! utf8 = get_tv_number_chk(&argvars[1], NULL); +! +! if (utf8) +! rettv->vval.v_number = (*utf_ptr2char)(get_tv_string(&argvars[0])); +! else +! rettv->vval.v_number = (*mb_ptr2char)(get_tv_string(&argvars[0])); +! } + else + #endif + rettv->vval.v_number = get_tv_string(&argvars[0])[0]; +*************** +*** 14360,14366 **** + + #ifdef FEAT_MBYTE + if (has_mbyte) +! buf[(*mb_char2bytes)((int)get_tv_number(&argvars[0]), buf)] = NUL; + else + #endif + { +--- 14370,14385 ---- + + #ifdef FEAT_MBYTE + if (has_mbyte) +! { +! int utf8 = 0; +! +! if (argvars[1].v_type != VAR_UNKNOWN) +! utf8 = get_tv_number_chk(&argvars[1], NULL); +! if (utf8) +! buf[(*utf_char2bytes)((int)get_tv_number(&argvars[0]), buf)] = NUL; +! else +! buf[(*mb_char2bytes)((int)get_tv_number(&argvars[0]), buf)] = NUL; +! } + else + #endif + { +*** ../vim-7.3.779/src/version.c 2013-01-23 16:43:07.000000000 +0100 +--- src/version.c 2013-01-23 17:06:36.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 780, + /**/ + +-- +A real patriot is the fellow who gets a parking ticket and rejoices +that the system works. + + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c5bd7e029adc8f7872014c7bd512d8a3e82cae78 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:46 +0100 Subject: [PATCH 0659/3340] - patchlevel 781 --- 7.3.781 | 185 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 185 insertions(+) create mode 100644 7.3.781 diff --git a/7.3.781 b/7.3.781 new file mode 100644 index 00000000..516ee829 --- /dev/null +++ b/7.3.781 @@ -0,0 +1,185 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.781 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.781 +Problem: Drawing with 'guifontwide' can be slow. +Solution: Draw multiple characters at a time. (Taro Muraoka) +Files: src/gui.c + + +*** ../vim-7.3.780/src/gui.c 2012-11-20 12:03:02.000000000 +0100 +--- src/gui.c 2013-01-23 17:28:48.000000000 +0100 +*************** +*** 2380,2386 **** + int cl; /* byte length of current char */ + int comping; /* current char is composing */ + int scol = col; /* screen column */ +! int dowide; /* use 'guifontwide' */ + + /* Break the string at a composing character, it has to be drawn on + * top of the previous character. */ +--- 2380,2388 ---- + int cl; /* byte length of current char */ + int comping; /* current char is composing */ + int scol = col; /* screen column */ +! int curr_wide; /* use 'guifontwide' */ +! int prev_wide = FALSE; +! int wide_changed; + + /* Break the string at a composing character, it has to be drawn on + * top of the previous character. */ +*************** +*** 2395,2403 **** + && fontset == NOFONTSET + # endif + && gui.wide_font != NOFONT) +! dowide = TRUE; + else +! dowide = FALSE; + comping = utf_iscomposing(c); + if (!comping) /* count cells from non-composing chars */ + cells += cn; +--- 2397,2405 ---- + && fontset == NOFONTSET + # endif + && gui.wide_font != NOFONT) +! curr_wide = TRUE; + else +! curr_wide = FALSE; + comping = utf_iscomposing(c); + if (!comping) /* count cells from non-composing chars */ + cells += cn; +*************** +*** 2405,2413 **** + if (cl == 0) /* hit end of string */ + len = i + cl; /* len must be wrong "cannot happen" */ + +! /* print the string so far if it's the last character or there is + * a composing character. */ +! if (i + cl >= len || (comping && i > start) || dowide + # if defined(FEAT_GUI_X11) + || (cn > 1 + # ifdef FEAT_XFONTSET +--- 2407,2417 ---- + if (cl == 0) /* hit end of string */ + len = i + cl; /* len must be wrong "cannot happen" */ + +! wide_changed = curr_wide != prev_wide; +! +! /* Print the string so far if it's the last character or there is + * a composing character. */ +! if (i + cl >= len || (comping && i > start) || wide_changed + # if defined(FEAT_GUI_X11) + || (cn > 1 + # ifdef FEAT_XFONTSET +*************** +*** 2419,2443 **** + # endif + ) + { +! if (comping || dowide) + thislen = i - start; + else + thislen = i - start + cl; + if (thislen > 0) + { + gui_mch_draw_string(gui.row, scol, s + start, thislen, + draw_flags); + start += thislen; + } + scol += cells; + cells = 0; +! if (dowide) + { +! gui_mch_set_font(gui.wide_font); +! gui_mch_draw_string(gui.row, scol - cn, +! s + start, cl, draw_flags); +! gui_mch_set_font(font); +! start += cl; + } + + # if defined(FEAT_GUI_X11) +--- 2423,2450 ---- + # endif + ) + { +! if (comping || wide_changed) + thislen = i - start; + else + thislen = i - start + cl; + if (thislen > 0) + { ++ if (prev_wide) ++ gui_mch_set_font(gui.wide_font); + gui_mch_draw_string(gui.row, scol, s + start, thislen, + draw_flags); ++ if (prev_wide) ++ gui_mch_set_font(font); + start += thislen; + } + scol += cells; + cells = 0; +! /* Adjust to not draw a character which width is changed +! * against with last one. */ +! if (wide_changed && !comping) + { +! scol -= cn; +! cl = 0; + } + + # if defined(FEAT_GUI_X11) +*************** +*** 2447,2453 **** + # ifdef FEAT_XFONTSET + && fontset == NOFONTSET + # endif +! && !dowide) + gui_mch_draw_string(gui.row, scol - 1, (char_u *)" ", + 1, draw_flags); + # endif +--- 2454,2460 ---- + # ifdef FEAT_XFONTSET + && fontset == NOFONTSET + # endif +! && !wide_changed) + gui_mch_draw_string(gui.row, scol - 1, (char_u *)" ", + 1, draw_flags); + # endif +*************** +*** 2465,2470 **** +--- 2472,2478 ---- + # endif + start = i + cl; + } ++ prev_wide = curr_wide; + } + /* The stuff below assumes "len" is the length in screen columns. */ + len = scol - col; +*** ../vim-7.3.780/src/version.c 2013-01-23 17:15:25.000000000 +0100 +--- src/version.c 2013-01-23 17:28:17.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 781, + /**/ + +-- +GUARD #1: Where'd you get the coconut? +ARTHUR: We found them. +GUARD #1: Found them? In Mercea? The coconut's tropical! +ARTHUR: What do you mean? +GUARD #1: Well, this is a temperate zone. + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1c29cedeb1b65dcf7baa1f8b56fa9ec1cbe9456d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:47 +0100 Subject: [PATCH 0660/3340] - patchlevel 782 --- 7.3.782 | 171 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 171 insertions(+) create mode 100644 7.3.782 diff --git a/7.3.782 b/7.3.782 new file mode 100644 index 00000000..11d26b15 --- /dev/null +++ b/7.3.782 @@ -0,0 +1,171 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.782 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.782 +Problem: Windows: IME composition may use a wrong font. +Solution: Use 'guifontwide' for IME when it is set. (Taro Muraoka) +Files: runtime/doc/options.txt, src/gui.c, src/gui_w48.c, + src/proto/gui_w16.pro, src/proto/gui_w32.pro + + +*** ../vim-7.3.781/runtime/doc/options.txt 2012-08-15 16:20:59.000000000 +0200 +--- runtime/doc/options.txt 2013-01-23 18:24:48.000000000 +0100 +*************** +*** 3518,3523 **** +--- 3560,3569 ---- + to set 'guifontwide' at all unless you want to override the choice + made by Pango/Xft. + ++ Windows +multibyte only: *guifontwide_win_mbyte* ++ ++ If set and vaild, 'guifontwide' is used for IME instead of 'guifont'. ++ + *'guiheadroom'* *'ghr'* + 'guiheadroom' 'ghr' number (default 50) + global +*** ../vim-7.3.781/src/gui.c 2013-01-23 17:43:52.000000000 +0100 +--- src/gui.c 2013-01-23 18:24:48.000000000 +0100 +*************** +*** 1002,1007 **** +--- 1002,1010 ---- + else + #endif + gui.wide_font = font; ++ #ifdef FEAT_GUI_MSWIN ++ gui_mch_wide_font_changed(); ++ #endif + return OK; + } + #endif +*** ../vim-7.3.781/src/gui_w48.c 2012-12-16 12:50:33.000000000 +0100 +--- src/gui_w48.c 2013-01-23 18:32:45.000000000 +0100 +*************** +*** 323,332 **** +--- 323,337 ---- + + /* + * For control IME. ++ * ++ * These LOGFONT used for IME. + */ + #ifdef FEAT_MBYTE + # ifdef USE_IM_CONTROL ++ /* holds LOGFONT for 'guifontwide' if available, otherwise 'guifont' */ + static LOGFONT norm_logfont; ++ /* holds LOGFONT for 'guifont' always. */ ++ static LOGFONT sub_logfont; + # endif + #endif + +*************** +*** 3090,3095 **** +--- 3095,3133 ---- + return res; + } + ++ ++ #ifdef FEAT_MBYTE_IME ++ /* ++ * Set correct LOGFONT to IME. Use 'guifontwide' if available, otherwise use ++ * 'guifont' ++ */ ++ static void ++ update_im_font() ++ { ++ LOGFONT lf_wide; ++ ++ if (p_guifontwide != NULL && *p_guifontwide != NUL ++ && get_logfont(&lf_wide, p_guifontwide, NULL, TRUE) == OK) ++ norm_logfont = lf_wide; ++ else ++ norm_logfont = sub_logfont; ++ im_set_font(&norm_logfont); ++ } ++ #endif ++ ++ #ifdef FEAT_MBYTE ++ /* ++ * Handler of gui.wide_font (p_guifontwide) changed notification. ++ */ ++ void ++ gui_mch_wide_font_changed() ++ { ++ # ifdef FEAT_MBYTE_IME ++ update_im_font(); ++ # endif ++ } ++ #endif ++ + /* + * Initialise vim to use the font with the given name. + * Return FAIL if the font could not be loaded, OK otherwise. +*************** +*** 3112,3120 **** + font_name = lf.lfFaceName; + #if defined(FEAT_MBYTE_IME) || defined(GLOBAL_IME) + norm_logfont = lf; + #endif + #ifdef FEAT_MBYTE_IME +! im_set_font(&lf); + #endif + gui_mch_free_font(gui.norm_font); + gui.norm_font = font; +--- 3150,3159 ---- + font_name = lf.lfFaceName; + #if defined(FEAT_MBYTE_IME) || defined(GLOBAL_IME) + norm_logfont = lf; ++ sub_logfont = lf; + #endif + #ifdef FEAT_MBYTE_IME +! update_im_font(); + #endif + gui_mch_free_font(gui.norm_font); + gui.norm_font = font; +*** ../vim-7.3.781/src/proto/gui_w16.pro 2011-01-17 20:08:03.000000000 +0100 +--- src/proto/gui_w16.pro 2013-01-23 18:24:48.000000000 +0100 +*************** +*** 50,55 **** +--- 50,56 ---- + void gui_mch_insert_lines __ARGS((int row, int num_lines)); + void gui_mch_exit __ARGS((int rc)); + int gui_mch_init_font __ARGS((char_u *font_name, int fontset)); ++ void gui_mch_wide_font_changed __ARGS((void)); + int gui_mch_maximized __ARGS((void)); + void gui_mch_newfont __ARGS((void)); + void gui_mch_settitle __ARGS((char_u *title, char_u *icon)); +*** ../vim-7.3.781/src/proto/gui_w32.pro 2011-01-17 20:08:03.000000000 +0100 +--- src/proto/gui_w32.pro 2013-01-23 18:24:48.000000000 +0100 +*************** +*** 50,55 **** +--- 50,56 ---- + void gui_mch_insert_lines __ARGS((int row, int num_lines)); + void gui_mch_exit __ARGS((int rc)); + int gui_mch_init_font __ARGS((char_u *font_name, int fontset)); ++ void gui_mch_wide_font_changed __ARGS((void)); + int gui_mch_maximized __ARGS((void)); + void gui_mch_newfont __ARGS((void)); + void gui_mch_settitle __ARGS((char_u *title, char_u *icon)); +*** ../vim-7.3.781/src/version.c 2013-01-23 17:43:52.000000000 +0100 +--- src/version.c 2013-01-23 18:25:33.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 782, + /**/ + +-- +"A mouse can be just as dangerous as a bullet or a bomb." + (US Representative Lamar Smith, R-Texas) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 717dfd8462d528e05d515d5cc7b7c96e5d959d83 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:48 +0100 Subject: [PATCH 0661/3340] - patchlevel 783 --- 7.3.783 | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 7.3.783 diff --git a/7.3.783 b/7.3.783 new file mode 100644 index 00000000..57f97841 --- /dev/null +++ b/7.3.783 @@ -0,0 +1,44 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.783 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.783 +Problem: Crash when mark is not set. (Dominique Pelle) +Solution: Check for NULL. +Files: src/normal.c + + +*** ../vim-7.3.782/src/normal.c 2013-01-17 13:24:00.000000000 +0100 +--- src/normal.c 2013-01-24 20:57:53.000000000 +0100 +*************** +*** 7552,7557 **** +--- 7552,7558 ---- + #endif + #ifdef FEAT_FOLDING + if (cap->oap->op_type == OP_NOP ++ && pos != NULL + && (pos == (pos_T *)-1 || !equalpos(old_cursor, *pos)) + && (fdo_flags & FDO_MARK) + && old_KeyTyped) +*** ../vim-7.3.782/src/version.c 2013-01-23 18:37:31.000000000 +0100 +--- src/version.c 2013-01-24 20:58:36.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 783, + /**/ + +-- +Shit makes the flowers grow and that's beautiful + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f33758ecf45aff293696df76df2a9affa2eeeb4f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:49 +0100 Subject: [PATCH 0662/3340] - patchlevel 784 --- 7.3.784 | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.784 diff --git a/7.3.784 b/7.3.784 new file mode 100644 index 00000000..eb30c07b --- /dev/null +++ b/7.3.784 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.784 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.784 (after 7.3.781) +Problem: Error when 'guifontwide' has a comma. +Solution: Use gui.wide_font. (Taro Muraoka) +Files: src/gui_w48.c + + +*** ../vim-7.3.783/src/gui_w48.c 2013-01-23 18:37:31.000000000 +0100 +--- src/gui_w48.c 2013-01-25 19:26:23.000000000 +0100 +*************** +*** 3107,3113 **** + LOGFONT lf_wide; + + if (p_guifontwide != NULL && *p_guifontwide != NUL +! && get_logfont(&lf_wide, p_guifontwide, NULL, TRUE) == OK) + norm_logfont = lf_wide; + else + norm_logfont = sub_logfont; +--- 3107,3114 ---- + LOGFONT lf_wide; + + if (p_guifontwide != NULL && *p_guifontwide != NUL +! && gui.wide_font != NOFONT +! && GetObject((HFONT)gui.wide_font, sizeof(lf_wide), &lf_wide)) + norm_logfont = lf_wide; + else + norm_logfont = sub_logfont; +*** ../vim-7.3.783/src/version.c 2013-01-24 21:00:15.000000000 +0100 +--- src/version.c 2013-01-25 19:27:52.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 784, + /**/ + +-- +CUSTOMER: You're not fooling anyone y'know. Look, isn't there something + you can do? +DEAD PERSON: I feel happy... I feel happy. + [whop] +CUSTOMER: Ah, thanks very much. +MORTICIAN: Not at all. See you on Thursday. +CUSTOMER: Right. + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b0193dbecffb8237bfc299adcb592411adb25a5a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:50 +0100 Subject: [PATCH 0663/3340] - patchlevel 785 --- 7.3.785 | 104 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 104 insertions(+) create mode 100644 7.3.785 diff --git a/7.3.785 b/7.3.785 new file mode 100644 index 00000000..e640b717 --- /dev/null +++ b/7.3.785 @@ -0,0 +1,104 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.785 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.785 (after 7.3.776) +Problem: Crash with specific use of search pattern. +Solution: Initialize reg_buf to curbuf. +Files: src/regexp.c + + +*** ../vim-7.3.784/src/regexp.c 2013-01-23 15:53:08.000000000 +0100 +--- src/regexp.c 2013-01-25 20:04:14.000000000 +0100 +*************** +*** 3413,3419 **** + * reg_startpos reg_mmatch->startpos + * reg_endpos reg_mmatch->endpos + * reg_win NULL window in which to search +! * reg_buf buffer in which to search + * reg_firstlnum first line in which to search + * reg_maxline 0 last line nr + * reg_line_lbr FALSE or TRUE FALSE +--- 3413,3419 ---- + * reg_startpos reg_mmatch->startpos + * reg_endpos reg_mmatch->endpos + * reg_win NULL window in which to search +! * reg_buf curbuf buffer in which to search + * reg_firstlnum first line in which to search + * reg_maxline 0 last line nr + * reg_line_lbr FALSE or TRUE FALSE +*************** +*** 3571,3576 **** +--- 3571,3577 ---- + reg_mmatch = NULL; + reg_maxline = 0; + reg_line_lbr = FALSE; ++ reg_buf = curbuf; + reg_win = NULL; + ireg_ic = rmp->rm_ic; + #ifdef FEAT_MBYTE +*************** +*** 3595,3600 **** +--- 3596,3602 ---- + reg_mmatch = NULL; + reg_maxline = 0; + reg_line_lbr = TRUE; ++ reg_buf = curbuf; + reg_win = NULL; + ireg_ic = rmp->rm_ic; + #ifdef FEAT_MBYTE +*************** +*** 4311,4318 **** + #endif + else + { +! if (!vim_iswordc_buf(c, reg_buf) +! || (reginput > regline && vim_iswordc_buf(reginput[-1], reg_buf))) + status = RA_NOMATCH; + } + break; +--- 4313,4320 ---- + #endif + else + { +! if (!vim_iswordc_buf(c, reg_buf) || (reginput > regline +! && vim_iswordc_buf(reginput[-1], reg_buf))) + status = RA_NOMATCH; + } + break; +*************** +*** 7135,7140 **** +--- 7137,7143 ---- + reg_match = rmp; + reg_mmatch = NULL; + reg_maxline = 0; ++ reg_buf = curbuf; + return vim_regsub_both(source, dest, copy, magic, backslash); + } + #endif +*** ../vim-7.3.784/src/version.c 2013-01-25 19:28:34.000000000 +0100 +--- src/version.c 2013-01-25 20:09:30.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 785, + /**/ + +-- +ARTHUR: Well, I can't just call you `Man'. +DENNIS: Well, you could say `Dennis'. +ARTHUR: Well, I didn't know you were called `Dennis.' +DENNIS: Well, you didn't bother to find out, did you? + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 86a5dbbe04de3b6b5345b818f376998b48b4b23a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:11:52 +0100 Subject: [PATCH 0664/3340] - patchlevel 785 --- README.patches | 70 ++++++++++++++++++++++++ vim.spec | 145 ++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 214 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index 4ba7007c..b186397c 100644 --- a/README.patches +++ b/README.patches @@ -746,3 +746,73 @@ Individual patches for Vim 7.3: 3513 7.3.713 printf() can only align to bytes, not characters 2296 7.3.714 :setlocal and :setglobal do not work in the sandbox 8244 7.3.715 crash when calling setloclist() in BufUnload autocmd + 1857 7.3.716 error on exit when using Python 3 + 1581 7.3.717 when changing font size only MS-Windows limits window size + 1559 7.3.718 when re-using the current buffer the buffer-local options stay + 18500 7.3.719 cannot run new version of cproto + 11303 7.3.720 proto files are outdated + 1624 7.3.721 Ruby interface defines local functions globally + 2244 7.3.722 Perl flags may contain "-g", which breaks "make proto" + 7337 7.3.723 various tiny problem. + 2294 7.3.724 building with Ruby and Tcl on MS-Windows 64 bit does not work + 2064 7.3.725 :aboveleft and :belowright have no effect on :copen + 1900 7.3.726 typos and duplicate info in README + 1405 7.3.727 can't always find Win32.mak when building GvimExt + 7176 7.3.728 cannot compile with MzScheme interface on Ubuntu 12.10 + 1763 7.3.729 building with Ruby fails on some systems + 2575 7.3.730 crash in PHP file when using syntastic + 2188 7.3.731 Py3Init_vim() is exported uneccessarily + 3772 7.3.732 compiler warnings for function arguments + 2735 7.3.733 tests fail when including MzScheme + 3680 7.3.734 cannot put help files in a sub-directory + 3694 7.3.735 cannot build Ruby 1.9 with MingW or Cygwin + 7558 7.3.736 file name completion in input() escapes white space + 1380 7.3.737 when using do_cmdline() recursively did_endif is not reset + 5106 7.3.738 (after 7.3.730) unused function argument + 2326 7.3.739 computing number of lines may have an integer overflow + 4818 7.3.740 IOC tool complains about undefined behavior for int + 1576 7.3.741 (after 7.3.737) tiny build fails + 1302 7.3.742 leaking memory when :vimgrep restores the directory + 1773 7.3.743 (after 7.3.741) tiny build still fails + 1467 7.3.744 64 bit compiler warning + 2697 7.3.745 automatically setting 'ttymouse' doesn't work + 2902 7.3.746 memory leaks when using location lists + 2285 7.3.747 tab alignment does not work when characters are concealed + 14505 7.3.748 no tests for conceal mode + 1675 7.3.749 cannot build Python interface without multi-byte feature + 3050 7.3.750 the justify macro does not always work correctly + 3267 7.3.751 test 61 is flaky, it fails once in a while + 2410 7.3.752 test 49 script file doesn't fold properly + 3777 7.3.753 ":q" twice does not work when there is a QuitPre autocommand + 1488 7.3.754 latest nmake is not recognized + 5332 7.3.755 autoconf doesn't find Python 3 if it's called "python" + 2957 7.3.756 a location list can get a wrong count in :lvimgrep + 1549 7.3.757 issue 96: access freed memory if put command triggers autocmd + 3173 7.3.758 matchit plugin does not handle space in #ifdef + 3080 7.3.759 MS-Windows: Updating tabline is slow when there are many tabs + 3055 7.3.760 dv_ deletes the white space before the line + 2828 7.3.761 in Visual mode a "-p does not work + 1798 7.3.762 (after 7.3.759) on some systems the tabline is not redraw. + 2044 7.3.763 jumping to a mark does not open fold if it is in the same line + 4060 7.3.764 not all message translation files are installed + 3254 7.3.765 segfault when doing "cclose" on BufUnload in a python function + 2865 7.3.766 ":help cpo-*" jumps to the wrong place + 4437 7.3.767 (Win32) The _errno used for iconv may be the wrong one + 1979 7.3.768 settabvar() and setwinvar() may move the cursor + 9748 7.3.769 'matchpairs' does not work with multi-byte characters + 3912 7.3.770 vim.h indentation is inconsistent + 2074 7.3.771 (after 7.3.769) uninitialized variable + 1539 7.3.772 cursor at wrong location after doing %s/x/y/c + 1496 7.3.773 (after 7.3.767) crash when OriginalFirstThunk is zero + 2567 7.3.774 tiny GUI version misses console dialog feature + 2761 7.3.775 Cygwin and Mingw builds miss dependency on gui_w48.c + 12411 7.3.776 ml_get error when searching, caused by curwin/curbuf mismatch + 2035 7.3.777 when building with Gnome locale gets reset + 1664 7.3.778 compiler error for adding up two pointers + 4570 7.3.779 backwards search lands in wrong place when on a multibyte char + 6443 7.3.780 char2nr() and nr2char() always use 'encoding' + 5262 7.3.781 drawing with 'guifontwide' can be slow + 4964 7.3.782 Windows: IME composition may use a wrong font + 1329 7.3.783 crash when mark is not set + 1914 7.3.784 (after 7.3.781) error when 'guifontwide' has a comma + 3145 7.3.785 (after 7.3.776) crash with specific use of search pattern diff --git a/vim.spec b/vim.spec index dc21e213..ae40afc7 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 715 +%define patchlevel 785 Summary: The VIM editor URL: http://www.vim.org/ @@ -771,6 +771,76 @@ Patch712: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.712 Patch713: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.713 Patch714: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.714 Patch715: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.715 +Patch716: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.716 +Patch717: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.717 +Patch718: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.718 +Patch719: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.719 +Patch720: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.720 +Patch721: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.721 +Patch722: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.722 +Patch723: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.723 +Patch724: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.724 +Patch725: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.725 +Patch726: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.726 +Patch727: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.727 +Patch728: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.728 +Patch729: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.729 +Patch730: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.730 +Patch731: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.731 +Patch732: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.732 +Patch733: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.733 +Patch734: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.734 +Patch735: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.735 +Patch736: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.736 +Patch737: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.737 +Patch738: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.738 +Patch739: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.739 +Patch740: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.740 +Patch741: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.741 +Patch742: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.742 +Patch743: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.743 +Patch744: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.744 +Patch745: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.745 +Patch746: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.746 +Patch747: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.747 +Patch748: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.748 +Patch749: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.749 +Patch750: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.750 +Patch751: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.751 +Patch752: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.752 +Patch753: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.753 +Patch754: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.754 +Patch755: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.755 +Patch756: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.756 +Patch757: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.757 +Patch758: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.758 +Patch759: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.759 +Patch760: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.760 +Patch761: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.761 +Patch762: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.762 +Patch763: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.763 +Patch764: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.764 +Patch765: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.765 +Patch766: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.766 +Patch767: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.767 +Patch768: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.768 +Patch769: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.769 +Patch770: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.770 +Patch771: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.771 +Patch772: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.772 +Patch773: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.773 +Patch774: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.774 +Patch775: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.775 +Patch776: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.776 +Patch777: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.777 +Patch778: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.778 +Patch779: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.779 +Patch780: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.780 +Patch781: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.781 +Patch782: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.782 +Patch783: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.783 +Patch784: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.784 +Patch785: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.785 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1632,6 +1702,76 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch713 -p0 %patch714 -p0 %patch715 -p0 +%patch716 -p0 +%patch717 -p0 +%patch718 -p0 +%patch719 -p0 +%patch720 -p0 +%patch721 -p0 +%patch722 -p0 +%patch723 -p0 +%patch724 -p0 +%patch725 -p0 +%patch726 -p0 +%patch727 -p0 +%patch728 -p0 +%patch729 -p0 +%patch730 -p0 +%patch731 -p0 +%patch732 -p0 +%patch733 -p0 +%patch734 -p0 +%patch735 -p0 +%patch736 -p0 +%patch737 -p0 +%patch738 -p0 +%patch739 -p0 +%patch740 -p0 +%patch741 -p0 +%patch742 -p0 +%patch743 -p0 +%patch744 -p0 +%patch745 -p0 +%patch746 -p0 +%patch747 -p0 +%patch748 -p0 +%patch749 -p0 +%patch750 -p0 +%patch751 -p0 +%patch752 -p0 +%patch753 -p0 +%patch754 -p0 +%patch755 -p0 +%patch756 -p0 +%patch757 -p0 +%patch758 -p0 +%patch759 -p0 +%patch760 -p0 +%patch761 -p0 +%patch762 -p0 +%patch763 -p0 +%patch764 -p0 +%patch765 -p0 +%patch766 -p0 +%patch767 -p0 +%patch768 -p0 +%patch769 -p0 +%patch770 -p0 +%patch771 -p0 +%patch772 -p0 +%patch773 -p0 +%patch774 -p0 +%patch775 -p0 +%patch776 -p0 +%patch777 -p0 +%patch778 -p0 +%patch779 -p0 +%patch780 -p0 +%patch781 -p0 +%patch782 -p0 +%patch783 -p0 +%patch784 -p0 +%patch785 -p0 # install spell files @@ -2094,6 +2234,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Jan 28 2013 Karsten Hopp 7.3.785-1 +- patchlevel 785 + * Tue Nov 20 2012 Karsten Hopp 7.3.715-1 - patchlevel 715 From a373b6ca89135b455ec12cd2c9268218ed7c26e5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 12:13:22 +0100 Subject: [PATCH 0665/3340] upstream pushed a fixed version of that patch --- 7.3.336 | 212 ++++++++++++++++++++++++++++---------------------------- 1 file changed, 106 insertions(+), 106 deletions(-) diff --git a/7.3.336 b/7.3.336 index f1a92c61..902f578c 100644 --- a/7.3.336 +++ b/7.3.336 @@ -880,7 +880,7 @@ Files: src/tag.c, src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak, *** 0 **** --- 1,2 ---- + !_TAG_FILE_ENCODING cp932 // -+ ‚`‚a‚b Xtags2.txt /‚`‚a‚b ++ ‚`‚a‚b Xtags2.txt /‚`‚a‚b *** ../vim-7.3.335/src/testdir/test83-tags3 2011-10-12 19:49:38.000000000 +0200 --- src/testdir/test83-tags3 2011-10-12 19:35:42.000000000 +0200 *************** @@ -888,106 +888,106 @@ Files: src/tag.c, src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak, --- 1,102 ---- + !_TAG_FILE_SORTED 1 // + !_TAG_FILE_ENCODING cp932 // -+ abc1 Xtags3.txt /‚`‚a‚b -+ abc2 Xtags3.txt /‚`‚a‚b -+ abc3 Xtags3.txt /‚`‚a‚b -+ abc4 Xtags3.txt /‚`‚a‚b -+ abc5 Xtags3.txt /‚`‚a‚b -+ abc6 Xtags3.txt /‚`‚a‚b -+ abc7 Xtags3.txt /‚`‚a‚b -+ abc8 Xtags3.txt /‚`‚a‚b -+ abc9 Xtags3.txt /‚`‚a‚b -+ abc10 Xtags3.txt /‚`‚a‚b -+ abc11 Xtags3.txt /‚`‚a‚b -+ abc12 Xtags3.txt /‚`‚a‚b -+ abc13 Xtags3.txt /‚`‚a‚b -+ abc14 Xtags3.txt /‚`‚a‚b -+ abc15 Xtags3.txt /‚`‚a‚b -+ abc16 Xtags3.txt /‚`‚a‚b -+ abc17 Xtags3.txt /‚`‚a‚b -+ abc18 Xtags3.txt /‚`‚a‚b -+ abc19 Xtags3.txt /‚`‚a‚b -+ abc20 Xtags3.txt /‚`‚a‚b -+ abc21 Xtags3.txt /‚`‚a‚b -+ abc22 Xtags3.txt /‚`‚a‚b -+ abc23 Xtags3.txt /‚`‚a‚b -+ abc24 Xtags3.txt /‚`‚a‚b -+ abc25 Xtags3.txt /‚`‚a‚b -+ abc26 Xtags3.txt /‚`‚a‚b -+ abc27 Xtags3.txt /‚`‚a‚b -+ abc28 Xtags3.txt /‚`‚a‚b -+ abc29 Xtags3.txt /‚`‚a‚b -+ abc30 Xtags3.txt /‚`‚a‚b -+ abc31 Xtags3.txt /‚`‚a‚b -+ abc32 Xtags3.txt /‚`‚a‚b -+ abc33 Xtags3.txt /‚`‚a‚b -+ abc34 Xtags3.txt /‚`‚a‚b -+ abc35 Xtags3.txt /‚`‚a‚b -+ abc36 Xtags3.txt /‚`‚a‚b -+ abc37 Xtags3.txt /‚`‚a‚b -+ abc38 Xtags3.txt /‚`‚a‚b -+ abc39 Xtags3.txt /‚`‚a‚b -+ abc40 Xtags3.txt /‚`‚a‚b -+ abc41 Xtags3.txt /‚`‚a‚b -+ abc42 Xtags3.txt /‚`‚a‚b -+ abc43 Xtags3.txt /‚`‚a‚b -+ abc44 Xtags3.txt /‚`‚a‚b -+ abc45 Xtags3.txt /‚`‚a‚b -+ abc46 Xtags3.txt /‚`‚a‚b -+ abc47 Xtags3.txt /‚`‚a‚b -+ abc48 Xtags3.txt /‚`‚a‚b -+ abc49 Xtags3.txt /‚`‚a‚b -+ abc50 Xtags3.txt /‚`‚a‚b -+ abc51 Xtags3.txt /‚`‚a‚b -+ abc52 Xtags3.txt /‚`‚a‚b -+ abc53 Xtags3.txt /‚`‚a‚b -+ abc54 Xtags3.txt /‚`‚a‚b -+ abc55 Xtags3.txt /‚`‚a‚b -+ abc56 Xtags3.txt /‚`‚a‚b -+ abc57 Xtags3.txt /‚`‚a‚b -+ abc58 Xtags3.txt /‚`‚a‚b -+ abc59 Xtags3.txt /‚`‚a‚b -+ abc60 Xtags3.txt /‚`‚a‚b -+ abc61 Xtags3.txt /‚`‚a‚b -+ abc62 Xtags3.txt /‚`‚a‚b -+ abc63 Xtags3.txt /‚`‚a‚b -+ abc64 Xtags3.txt /‚`‚a‚b -+ abc65 Xtags3.txt /‚`‚a‚b -+ abc66 Xtags3.txt /‚`‚a‚b -+ abc67 Xtags3.txt /‚`‚a‚b -+ abc68 Xtags3.txt /‚`‚a‚b -+ abc69 Xtags3.txt /‚`‚a‚b -+ abc70 Xtags3.txt /‚`‚a‚b -+ abc71 Xtags3.txt /‚`‚a‚b -+ abc72 Xtags3.txt /‚`‚a‚b -+ abc73 Xtags3.txt /‚`‚a‚b -+ abc74 Xtags3.txt /‚`‚a‚b -+ abc75 Xtags3.txt /‚`‚a‚b -+ abc76 Xtags3.txt /‚`‚a‚b -+ abc77 Xtags3.txt /‚`‚a‚b -+ abc78 Xtags3.txt /‚`‚a‚b -+ abc79 Xtags3.txt /‚`‚a‚b -+ abc80 Xtags3.txt /‚`‚a‚b -+ abc81 Xtags3.txt /‚`‚a‚b -+ abc82 Xtags3.txt /‚`‚a‚b -+ abc83 Xtags3.txt /‚`‚a‚b -+ abc84 Xtags3.txt /‚`‚a‚b -+ abc85 Xtags3.txt /‚`‚a‚b -+ abc86 Xtags3.txt /‚`‚a‚b -+ abc87 Xtags3.txt /‚`‚a‚b -+ abc88 Xtags3.txt /‚`‚a‚b -+ abc89 Xtags3.txt /‚`‚a‚b -+ abc90 Xtags3.txt /‚`‚a‚b -+ abc91 Xtags3.txt /‚`‚a‚b -+ abc92 Xtags3.txt /‚`‚a‚b -+ abc93 Xtags3.txt /‚`‚a‚b -+ abc94 Xtags3.txt /‚`‚a‚b -+ abc95 Xtags3.txt /‚`‚a‚b -+ abc96 Xtags3.txt /‚`‚a‚b -+ abc97 Xtags3.txt /‚`‚a‚b -+ abc98 Xtags3.txt /‚`‚a‚b -+ abc99 Xtags3.txt /‚`‚a‚b -+ abc100 Xtags3.txt /‚`‚a‚b ++ abc1 Xtags3.txt /‚`‚a‚b ++ abc2 Xtags3.txt /‚`‚a‚b ++ abc3 Xtags3.txt /‚`‚a‚b ++ abc4 Xtags3.txt /‚`‚a‚b ++ abc5 Xtags3.txt /‚`‚a‚b ++ abc6 Xtags3.txt /‚`‚a‚b ++ abc7 Xtags3.txt /‚`‚a‚b ++ abc8 Xtags3.txt /‚`‚a‚b ++ abc9 Xtags3.txt /‚`‚a‚b ++ abc10 Xtags3.txt /‚`‚a‚b ++ abc11 Xtags3.txt /‚`‚a‚b ++ abc12 Xtags3.txt /‚`‚a‚b ++ abc13 Xtags3.txt /‚`‚a‚b ++ abc14 Xtags3.txt /‚`‚a‚b ++ abc15 Xtags3.txt /‚`‚a‚b ++ abc16 Xtags3.txt /‚`‚a‚b ++ abc17 Xtags3.txt /‚`‚a‚b ++ abc18 Xtags3.txt /‚`‚a‚b ++ abc19 Xtags3.txt /‚`‚a‚b ++ abc20 Xtags3.txt /‚`‚a‚b ++ abc21 Xtags3.txt /‚`‚a‚b ++ abc22 Xtags3.txt /‚`‚a‚b ++ abc23 Xtags3.txt /‚`‚a‚b ++ abc24 Xtags3.txt /‚`‚a‚b ++ abc25 Xtags3.txt /‚`‚a‚b ++ abc26 Xtags3.txt /‚`‚a‚b ++ abc27 Xtags3.txt /‚`‚a‚b ++ abc28 Xtags3.txt /‚`‚a‚b ++ abc29 Xtags3.txt /‚`‚a‚b ++ abc30 Xtags3.txt /‚`‚a‚b ++ abc31 Xtags3.txt /‚`‚a‚b ++ abc32 Xtags3.txt /‚`‚a‚b ++ abc33 Xtags3.txt /‚`‚a‚b ++ abc34 Xtags3.txt /‚`‚a‚b ++ abc35 Xtags3.txt /‚`‚a‚b ++ abc36 Xtags3.txt /‚`‚a‚b ++ abc37 Xtags3.txt /‚`‚a‚b ++ abc38 Xtags3.txt /‚`‚a‚b ++ abc39 Xtags3.txt /‚`‚a‚b ++ abc40 Xtags3.txt /‚`‚a‚b ++ abc41 Xtags3.txt /‚`‚a‚b ++ abc42 Xtags3.txt /‚`‚a‚b ++ abc43 Xtags3.txt /‚`‚a‚b ++ abc44 Xtags3.txt /‚`‚a‚b ++ abc45 Xtags3.txt /‚`‚a‚b ++ abc46 Xtags3.txt /‚`‚a‚b ++ abc47 Xtags3.txt /‚`‚a‚b ++ abc48 Xtags3.txt /‚`‚a‚b ++ abc49 Xtags3.txt /‚`‚a‚b ++ abc50 Xtags3.txt /‚`‚a‚b ++ abc51 Xtags3.txt /‚`‚a‚b ++ abc52 Xtags3.txt /‚`‚a‚b ++ abc53 Xtags3.txt /‚`‚a‚b ++ abc54 Xtags3.txt /‚`‚a‚b ++ abc55 Xtags3.txt /‚`‚a‚b ++ abc56 Xtags3.txt /‚`‚a‚b ++ abc57 Xtags3.txt /‚`‚a‚b ++ abc58 Xtags3.txt /‚`‚a‚b ++ abc59 Xtags3.txt /‚`‚a‚b ++ abc60 Xtags3.txt /‚`‚a‚b ++ abc61 Xtags3.txt /‚`‚a‚b ++ abc62 Xtags3.txt /‚`‚a‚b ++ abc63 Xtags3.txt /‚`‚a‚b ++ abc64 Xtags3.txt /‚`‚a‚b ++ abc65 Xtags3.txt /‚`‚a‚b ++ abc66 Xtags3.txt /‚`‚a‚b ++ abc67 Xtags3.txt /‚`‚a‚b ++ abc68 Xtags3.txt /‚`‚a‚b ++ abc69 Xtags3.txt /‚`‚a‚b ++ abc70 Xtags3.txt /‚`‚a‚b ++ abc71 Xtags3.txt /‚`‚a‚b ++ abc72 Xtags3.txt /‚`‚a‚b ++ abc73 Xtags3.txt /‚`‚a‚b ++ abc74 Xtags3.txt /‚`‚a‚b ++ abc75 Xtags3.txt /‚`‚a‚b ++ abc76 Xtags3.txt /‚`‚a‚b ++ abc77 Xtags3.txt /‚`‚a‚b ++ abc78 Xtags3.txt /‚`‚a‚b ++ abc79 Xtags3.txt /‚`‚a‚b ++ abc80 Xtags3.txt /‚`‚a‚b ++ abc81 Xtags3.txt /‚`‚a‚b ++ abc82 Xtags3.txt /‚`‚a‚b ++ abc83 Xtags3.txt /‚`‚a‚b ++ abc84 Xtags3.txt /‚`‚a‚b ++ abc85 Xtags3.txt /‚`‚a‚b ++ abc86 Xtags3.txt /‚`‚a‚b ++ abc87 Xtags3.txt /‚`‚a‚b ++ abc88 Xtags3.txt /‚`‚a‚b ++ abc89 Xtags3.txt /‚`‚a‚b ++ abc90 Xtags3.txt /‚`‚a‚b ++ abc91 Xtags3.txt /‚`‚a‚b ++ abc92 Xtags3.txt /‚`‚a‚b ++ abc93 Xtags3.txt /‚`‚a‚b ++ abc94 Xtags3.txt /‚`‚a‚b ++ abc95 Xtags3.txt /‚`‚a‚b ++ abc96 Xtags3.txt /‚`‚a‚b ++ abc97 Xtags3.txt /‚`‚a‚b ++ abc98 Xtags3.txt /‚`‚a‚b ++ abc99 Xtags3.txt /‚`‚a‚b ++ abc100 Xtags3.txt /‚`‚a‚b *** ../vim-7.3.335/src/testdir/test83.in 2011-10-12 19:49:38.000000000 +0200 --- src/testdir/test83.in 2011-10-12 19:40:47.000000000 +0200 *************** @@ -1030,8 +1030,8 @@ Files: src/tag.c, src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak, + :new + :set tags=test83-tags2 + :let v:errmsg = '' -+ :tag /.BC -+ :if v:errmsg =~ 'E426:' || getline('.') != 'ABC' ++ :tag /.BC ++ :if v:errmsg =~ 'E426:' || getline('.') != 'ABC' + : close + : put ='case2: failed' + :else @@ -1044,7 +1044,7 @@ Files: src/tag.c, src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak, + :set tags=test83-tags3 + :let v:errmsg = '' + :tag abc50 -+ :if v:errmsg =~ 'E426:' || getline('.') != 'ABC' ++ :if v:errmsg =~ 'E426:' || getline('.') != 'ABC' + : close + : put ='case3: failed' + :else @@ -1060,10 +1060,10 @@ Files: src/tag.c, src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak, + abcdefghijklmnopqrs + + text for tags2 -+ ABC ++ ABC + + text for tags3 -+ ABC ++ ABC + + tags1 + !_TAG_FILE_ENCODING utf-8 // From be6f54b13e94321f2288dcba66fa82a4ec842846 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 28 Jan 2013 14:02:43 +0100 Subject: [PATCH 0666/3340] fix broken upstream patch --- 7.3.780 | 304 +++++++++++++++++++++----------------------------------- 1 file changed, 111 insertions(+), 193 deletions(-) diff --git a/7.3.780 b/7.3.780 index 40d317b4..a4f40e3a 100644 --- a/7.3.780 +++ b/7.3.780 @@ -1,193 +1,111 @@ -To: vim_dev@googlegroups.com -Subject: Patch 7.3.780 -Fcc: outbox -From: Bram Moolenaar -Mime-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit ------------- - -Patch 7.3.780 -Problem: char2nr() and nr2char() always use 'encoding'. -Solution: Add argument to use utf-8 characters. (Yasuhiro Matsumoto) -Files: runtime/doc/eval.txt, src/eval.c - - -*** ../vim-7.3.779/runtime/doc/eval.txt 2012-12-05 16:10:21.000000000 +0100 ---- runtime/doc/eval.txt 2013-01-23 17:00:52.000000000 +0100 -*************** -*** 1705,1711 **** - any call {func} with arguments {arglist} - ceil( {expr}) Float round {expr} up - changenr() Number current change number -! char2nr( {expr}) Number ASCII value of first char in {expr} - cindent( {lnum}) Number C indent for line {lnum} - clearmatches() none clear all matches - col( {expr}) Number column nr of cursor or mark ---- 1716,1722 ---- - any call {func} with arguments {arglist} - ceil( {expr}) Float round {expr} up - changenr() Number current change number -! char2nr( {expr}[, {utf8}]) Number ASCII/UTF8 value of first char in {expr} - cindent( {lnum}) Number C indent for line {lnum} - clearmatches() none clear all matches - col( {expr}) Number column nr of cursor or mark -*************** -*** 1862,1868 **** - mode( [expr]) String current editing mode - mzeval( {expr}) any evaluate |MzScheme| expression - nextnonblank( {lnum}) Number line nr of non-blank line >= {lnum} -! nr2char( {expr}) String single char with ASCII value {expr} - or( {expr}, {expr}) Number bitwise OR - pathshorten( {expr}) String shorten directory names in a path - pow( {x}, {y}) Float {x} to the power of {y} ---- 1873,1879 ---- - mode( [expr]) String current editing mode - mzeval( {expr}) any evaluate |MzScheme| expression - nextnonblank( {lnum}) Number line nr of non-blank line >= {lnum} -! nr2char( {expr}[, {utf8}]) String single char with ASCII/UTF8 value {expr} - or( {expr}, {expr}) Number bitwise OR - pathshorten( {expr}) String shorten directory names in a path - pow( {x}, {y}) Float {x} to the power of {y} -*************** -*** 2282,2295 **** - redo it is the number of the redone change. After undo it is - one less than the number of the undone change. - -! char2nr({expr}) *char2nr()* - Return number value of the first char in {expr}. Examples: > - char2nr(" ") returns 32 - char2nr("ABC") returns 65 -! < The current 'encoding' is used. Example for "utf-8": > - char2nr("á") returns 225 - char2nr("á"[0]) returns 195 -! < |nr2char()| does the opposite. - - cindent({lnum}) *cindent()* - Get the amount of indent for line {lnum} according the C ---- 2294,2310 ---- - redo it is the number of the redone change. After undo it is - one less than the number of the undone change. - -! char2nr({expr}[, {utf8}]) *char2nr()* - Return number value of the first char in {expr}. Examples: > - char2nr(" ") returns 32 - char2nr("ABC") returns 65 -! < When {utf8} is omitted or zero, the current 'encoding' is used. -! Example for "utf-8": > - char2nr("á") returns 225 - char2nr("á"[0]) returns 195 -! < With {utf8} set to 1, always treat as utf-8 characters. -! A combining character is a separate character. -! |nr2char()| does the opposite. - - cindent({lnum}) *cindent()* - Get the amount of indent for line {lnum} according the C -*** ../vim-7.3.779/src/eval.c 2013-01-23 15:53:08.000000000 +0100 ---- src/eval.c 2013-01-23 16:57:48.000000000 +0100 -*************** -*** 7854,7860 **** - {"ceil", 1, 1, f_ceil}, - #endif - {"changenr", 0, 0, f_changenr}, -! {"char2nr", 1, 1, f_char2nr}, - {"cindent", 1, 1, f_cindent}, - {"clearmatches", 0, 0, f_clearmatches}, - {"col", 1, 1, f_col}, ---- 7854,7860 ---- - {"ceil", 1, 1, f_ceil}, - #endif - {"changenr", 0, 0, f_changenr}, -! {"char2nr", 1, 2, f_char2nr}, - {"cindent", 1, 1, f_cindent}, - {"clearmatches", 0, 0, f_clearmatches}, - {"col", 1, 1, f_col}, -*************** -*** 8003,8009 **** - {"mzeval", 1, 1, f_mzeval}, - #endif - {"nextnonblank", 1, 1, f_nextnonblank}, -! {"nr2char", 1, 1, f_nr2char}, - {"or", 2, 2, f_or}, - {"pathshorten", 1, 1, f_pathshorten}, - #ifdef FEAT_FLOAT ---- 8003,8009 ---- - {"mzeval", 1, 1, f_mzeval}, - #endif - {"nextnonblank", 1, 1, f_nextnonblank}, -! {"nr2char", 1, 2, f_nr2char}, - {"or", 2, 2, f_or}, - {"pathshorten", 1, 1, f_pathshorten}, - #ifdef FEAT_FLOAT -*************** -*** 9303,9309 **** - { - #ifdef FEAT_MBYTE - if (has_mbyte) -! rettv->vval.v_number = (*mb_ptr2char)(get_tv_string(&argvars[0])); - else - #endif - rettv->vval.v_number = get_tv_string(&argvars[0])[0]; ---- 9303,9319 ---- - { - #ifdef FEAT_MBYTE - if (has_mbyte) -! { -! int utf8 = 0; -! -! if (argvars[1].v_type != VAR_UNKNOWN) -! utf8 = get_tv_number_chk(&argvars[1], NULL); -! -! if (utf8) -! rettv->vval.v_number = (*utf_ptr2char)(get_tv_string(&argvars[0])); -! else -! rettv->vval.v_number = (*mb_ptr2char)(get_tv_string(&argvars[0])); -! } - else - #endif - rettv->vval.v_number = get_tv_string(&argvars[0])[0]; -*************** -*** 14360,14366 **** - - #ifdef FEAT_MBYTE - if (has_mbyte) -! buf[(*mb_char2bytes)((int)get_tv_number(&argvars[0]), buf)] = NUL; - else - #endif - { ---- 14370,14385 ---- - - #ifdef FEAT_MBYTE - if (has_mbyte) -! { -! int utf8 = 0; -! -! if (argvars[1].v_type != VAR_UNKNOWN) -! utf8 = get_tv_number_chk(&argvars[1], NULL); -! if (utf8) -! buf[(*utf_char2bytes)((int)get_tv_number(&argvars[0]), buf)] = NUL; -! else -! buf[(*mb_char2bytes)((int)get_tv_number(&argvars[0]), buf)] = NUL; -! } - else - #endif - { -*** ../vim-7.3.779/src/version.c 2013-01-23 16:43:07.000000000 +0100 ---- src/version.c 2013-01-23 17:06:36.000000000 +0100 -*************** -*** 727,728 **** ---- 727,730 ---- - { /* Add new patch number below this line */ -+ /**/ -+ 780, - /**/ - --- -A real patriot is the fellow who gets a parking ticket and rejoices -that the system works. - - - /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ -/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ -\\\ an exciting new programming language -- http://www.Zimbu.org /// - \\\ help me help AIDS victims -- http://ICCF-Holland.org /// +diff -up vim73/runtime/doc/eval.txt.780 vim73/runtime/doc/eval.txt +--- vim73/runtime/doc/eval.txt.780 2013-01-28 13:41:04.000000000 +0100 ++++ runtime/doc/eval.txt 2013-01-28 13:44:58.000000000 +0100 +@@ -1705,7 +1705,7 @@ call( {func}, {arglist} [, {dict}]) + any call {func} with arguments {arglist} + ceil( {expr}) Float round {expr} up + changenr() Number current change number +-char2nr( {expr}) Number ASCII value of first char in {expr} ++char2nr( {expr}[, {utf8}]) Number ASCII/UTF8 value of first char in {expr} + cindent( {lnum}) Number C indent for line {lnum} + clearmatches() none clear all matches + col( {expr}) Number column nr of cursor or mark +@@ -1862,7 +1862,7 @@ mkdir( {name} [, {path} [, {prot}]]) + mode( [expr]) String current editing mode + mzeval( {expr}) any evaluate |MzScheme| expression + nextnonblank( {lnum}) Number line nr of non-blank line >= {lnum} +-nr2char( {expr}) String single char with ASCII value {expr} ++nr2char( {expr}[, {utf8}]) String single char with ASCII/UTF8 value {expr} + or( {expr}, {expr}) Number bitwise OR + pathshorten( {expr}) String shorten directory names in a path + pow( {x}, {y}) Float {x} to the power of {y} +@@ -2282,13 +2282,17 @@ changenr() *changenr()* + redo it is the number of the redone change. After undo it is + one less than the number of the undone change. + +-char2nr({expr}) *char2nr()* ++char2nr({expr}[, {utf8}]) **char2nr()* + Return number value of the first char in {expr}. Examples: > + char2nr(" ") returns 32 + char2nr("ABC") returns 65 +-< The current 'encoding' is used. Example for "utf-8": > ++< When {utf8} is omitted or zero, the current 'encoding' is ++used. ++ Example for "utf-8": > + char2nr("á") returns 225 + char2nr("á"[0]) returns 195 ++ With {utf8} set to 1, always treat as utf-8 characters. ++ A combining character is a separate character. + < |nr2char()| does the opposite. + + cindent({lnum}) *cindent()* +diff -up vim73/src/eval.c.780 vim73/src/eval.c +--- vim73/src/eval.c.780 2013-01-28 13:41:04.000000000 +0100 ++++ src/eval.c 2013-01-28 13:41:04.000000000 +0100 +@@ -7854,7 +7854,7 @@ static struct fst + {"ceil", 1, 1, f_ceil}, + #endif + {"changenr", 0, 0, f_changenr}, +- {"char2nr", 1, 1, f_char2nr}, ++ {"char2nr", 1, 2, f_char2nr}, + {"cindent", 1, 1, f_cindent}, + {"clearmatches", 0, 0, f_clearmatches}, + {"col", 1, 1, f_col}, +@@ -8003,7 +8003,7 @@ static struct fst + {"mzeval", 1, 1, f_mzeval}, + #endif + {"nextnonblank", 1, 1, f_nextnonblank}, +- {"nr2char", 1, 1, f_nr2char}, ++ {"nr2char", 1, 2, f_nr2char}, + {"or", 2, 2, f_or}, + {"pathshorten", 1, 1, f_pathshorten}, + #ifdef FEAT_FLOAT +@@ -9303,7 +9303,17 @@ f_char2nr(argvars, rettv) + { + #ifdef FEAT_MBYTE + if (has_mbyte) +- rettv->vval.v_number = (*mb_ptr2char)(get_tv_string(&argvars[0])); ++ { ++ int utf8 = 0; ++ ++ if (argvars[1].v_type != VAR_UNKNOWN) ++ utf8 = get_tv_number_chk(&argvars[1], NULL); ++ ++ if (utf8) ++ rettv->vval.v_number = (*utf_ptr2char)(get_tv_string(&argvars[0])); ++ else ++ rettv->vval.v_number = (*mb_ptr2char)(get_tv_string(&argvars[0])); ++ } + else + #endif + rettv->vval.v_number = get_tv_string(&argvars[0])[0]; +@@ -14360,7 +14370,16 @@ f_nr2char(argvars, rettv) + + #ifdef FEAT_MBYTE + if (has_mbyte) +- buf[(*mb_char2bytes)((int)get_tv_number(&argvars[0]), buf)] = NUL; ++ { ++ int utf8 = 0; ++ ++ if (argvars[1].v_type != VAR_UNKNOWN) ++ utf8 = get_tv_number_chk(&argvars[1], NULL); ++ if (utf8) ++ buf[(*utf_char2bytes)((int)get_tv_number(&argvars[0]), buf)] = NUL; ++ else ++ buf[(*mb_char2bytes)((int)get_tv_number(&argvars[0]), buf)] = NUL; ++ } + else + #endif + { +diff -up vim73/src/version.c.780 vim73/src/version.c +--- vim73/src/version.c.780 2013-01-28 13:41:04.000000000 +0100 ++++ src/version.c 2013-01-28 13:41:04.000000000 +0100 +@@ -726,6 +726,8 @@ static char *(features[]) = + static int included_patches[] = + { /* Add new patch number below this line */ + /**/ ++ 780, ++/**/ + 779, + /**/ + 778, From bb2da1284dd6b0ba38905f4a9413e13c5c927c56 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 29 Jan 2013 15:48:10 +0100 Subject: [PATCH 0667/3340] add nl.po add several translations --- nl.po | 8207 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ vim.spec | 11 + 2 files changed, 8218 insertions(+) create mode 100644 nl.po diff --git a/nl.po b/nl.po new file mode 100644 index 00000000..23dc99e9 --- /dev/null +++ b/nl.po @@ -0,0 +1,8207 @@ +# Dutch Translation for Vim vim:set foldmethod=marker: +# Do ":help uganda" in Vim to read copying and usage conditions. +# Do ":help credits" in Vim to see a list of people who contributed. +# Previous-Translator(s): +# highlight: oplichten +# Erwin Poeze , 2011, 2012. +msgid "" +msgstr "" +"Project-Id-Version: vim 7.3\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2011-05-29 07:43+0200\n" +"PO-Revision-Date: 2012-03-28 08:07+0200\n" +"Last-Translator: YOUR NAME \n" +"Language-Team: Dutch \n" +"Language: nl\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" + +#: blowfish.c:418 +msgid "E831: bf_key_init() called with empty password" +msgstr "E831: bf_key_init() uitgevoerd met leeg wachtwoord" + +#: blowfish.c:513 +msgid "E820: sizeof(uint32_t) != 4" +msgstr "E820: sizeof(uint32_t) != 4" + +#: blowfish.c:532 +msgid "E817: Blowfish big/little endian use wrong" +msgstr "E817: gebruik Blowfish big/little endian is onjuist" + +#: blowfish.c:645 +msgid "E818: sha256 test failed" +msgstr "E818: sha256 test mislukt" + +#: blowfish.c:650 +msgid "E819: Blowfish test failed" +msgstr "E819: Blowfish test mislukt" + +#: buffer.c:103 +msgid "E82: Cannot allocate any buffer, exiting..." +msgstr "E82: kan geen buffer aanmaken, beëindigen..." + +#: buffer.c:106 +msgid "E83: Cannot allocate buffer, using other one..." +msgstr "E83: kan geen buffer aanmaken, een andere wordt gebruikt..." + +#: buffer.c:879 +msgid "E515: No buffers were unloaded" +msgstr "E515: geen van de buffers is gelost" + +#: buffer.c:881 +msgid "E516: No buffers were deleted" +msgstr "E516: geen van de buffers is verwijderd" + +#: buffer.c:883 +msgid "E517: No buffers were wiped out" +msgstr "E517: geen van de buffers is gewist" + +#: buffer.c:891 +msgid "1 buffer unloaded" +msgstr "1 buffer gelost" + +#: buffer.c:893 +#, c-format +msgid "%d buffers unloaded" +msgstr "%d buffers gelost" + +#: buffer.c:898 +msgid "1 buffer deleted" +msgstr "1 buffer verwijderd" + +#: buffer.c:900 +#, c-format +msgid "%d buffers deleted" +msgstr "%d buffers verwijderd" + +#: buffer.c:905 +msgid "1 buffer wiped out" +msgstr "1 buffer gewist" + +#: buffer.c:907 +#, c-format +msgid "%d buffers wiped out" +msgstr "%d buffers gewist" + +#: buffer.c:965 +msgid "E84: No modified buffer found" +msgstr "E84: geen aangepast buffer gevonden" + +#. back where we started, didn't find anything. +#: buffer.c:1004 +msgid "E85: There is no listed buffer" +msgstr "E85: er is geen vermelde buffer" + +#: buffer.c:1016 +#, c-format +msgid "E86: Buffer %ld does not exist" +msgstr "E86: Buffer %ld bestaat niet" + +#: buffer.c:1019 +msgid "E87: Cannot go beyond last buffer" +msgstr "E87: kan niet voorbij het laatste buffer komen" + +#: buffer.c:1021 +msgid "E88: Cannot go before first buffer" +msgstr "E88: kan niet vóór het eerste buffer komen" + +#: buffer.c:1063 +#, c-format +msgid "E89: No write since last change for buffer %ld (add ! to override)" +msgstr "E89: niets opgeslagen sinds laatste wijziging van buffer %ld (voeg ! toe om te forceren)" + +#: buffer.c:1080 +msgid "E90: Cannot unload last buffer" +msgstr "E90: kan laatste buffer niet legen" + +#: buffer.c:1657 +msgid "W14: Warning: List of file names overflow" +msgstr "W14: waarschuwing: lijst met bestandsnamen is vol" + +#: buffer.c:1856 +#: quickfix.c:3626 +#, c-format +msgid "E92: Buffer %ld not found" +msgstr "E92: buffer %ld niet gevonden" + +#: buffer.c:2131 +#, c-format +msgid "E93: More than one match for %s" +msgstr "E93: %s meermaals gevonden" + +#: buffer.c:2133 +#, c-format +msgid "E94: No matching buffer for %s" +msgstr "E94: geen overeenkomstig buffer voor %s" + +#: buffer.c:2585 +#, c-format +msgid "line %ld" +msgstr "regel %ld" + +#: buffer.c:2672 +msgid "E95: Buffer with this name already exists" +msgstr "E95: buffer met deze naam bestaat al" + +#: buffer.c:2999 +msgid " [Modified]" +msgstr " [Gewijzigd]" + +#: buffer.c:3004 +msgid "[Not edited]" +msgstr "[Niet bewerkt]" + +#: buffer.c:3009 +msgid "[New file]" +msgstr "[Nieuw bestand]" + +#: buffer.c:3010 +msgid "[Read errors]" +msgstr "[Leesfouten]" + +#: buffer.c:3012 +#: fileio.c:2429 +#: netbeans.c:3848 +msgid "[readonly]" +msgstr "[alleen-lezen]" + +#: buffer.c:3035 +#, c-format +msgid "1 line --%d%%--" +msgstr "1 regel --%d%%--" + +#: buffer.c:3038 +#, c-format +msgid "%ld lines --%d%%--" +msgstr "%ld regels --%d%%--" + +#: buffer.c:3045 +#, c-format +msgid "line %ld of %ld --%d%%-- col " +msgstr "regel %ld van %ld --%d%%-- kol " + +#: buffer.c:3166 +#: buffer.c:5132 +#: memline.c:1783 +msgid "[No Name]" +msgstr "[Geen naam]" + +#. must be a help buffer +#: buffer.c:3204 +msgid "help" +msgstr "hulp" + +#: buffer.c:3832 +#: screen.c:6091 +msgid "[Help]" +msgstr "[Hulp]" + +#: buffer.c:3866 +#: screen.c:6097 +msgid "[Preview]" +msgstr "[Voorvertoning]" + +#: buffer.c:4188 +msgid "All" +msgstr "Alles" + +#: buffer.c:4188 +msgid "Bot" +msgstr "Bodem" + +#: buffer.c:4191 +msgid "Top" +msgstr "Top" + +#: buffer.c:5067 +#, c-format +msgid "" +"\n" +"# Buffer list:\n" +msgstr "" +"\n" +"# Bufferlijst:\n" + +#: buffer.c:5116 +msgid "[Location List]" +msgstr "[Locatielijst]" + +#: buffer.c:5118 +msgid "[Quickfix list]" +msgstr "[Quickfix-lijst]" + +#: buffer.c:5128 +msgid "[Scratch]" +msgstr "[Klad]" + +#: buffer.c:5445 +msgid "" +"\n" +"--- Signs ---" +msgstr "" +"\n" +"--- Tekens ---" + +#: buffer.c:5455 +#, c-format +msgid "Signs for %s:" +msgstr "Tekens voor %s:" + +#: buffer.c:5461 +#, c-format +msgid " line=%ld id=%d name=%s" +msgstr " regel=%ld id=%d naam=%s" + +#: diff.c:141 +#, c-format +msgid "E96: Can not diff more than %ld buffers" +msgstr "E96: kan niet meer dan %ld buffers vergelijken" + +#: diff.c:777 +msgid "E810: Cannot read or write temp files" +msgstr "E810: kan tijdelijke bestand niet lezen of opslaan" + +#: diff.c:778 +msgid "E97: Cannot create diffs" +msgstr "E97: kan geen verschillen genereren" + +#: diff.c:901 +msgid "Patch file" +msgstr "Patch-bestand" + +#: diff.c:1005 +msgid "E816: Cannot read patch output" +msgstr "E816: kan patch-uitvoer niet lezen" + +#: diff.c:1236 +msgid "E98: Cannot read diff output" +msgstr "E98: kan diff-uitvoer niet lezen" + +#: diff.c:2095 +msgid "E99: Current buffer is not in diff mode" +msgstr "E99: huidige buffer is niet in diff-modus" + +#: diff.c:2114 +msgid "E793: No other buffer in diff mode is modifiable" +msgstr "E793: geen ander buffer in diff-modus is bewerkbaar" + +#: diff.c:2116 +msgid "E100: No other buffer in diff mode" +msgstr "E100: geen ander buffer in diff-modus" + +#: diff.c:2126 +msgid "E101: More than two buffers in diff mode, don't know which one to use" +msgstr "E101: meer dan twee buffers in diff-modus, weet niet welke gebruikt moet worden" + +#: diff.c:2149 +#, c-format +msgid "E102: Can't find buffer \"%s\"" +msgstr "E102: kan buffer \"%s\" niet vinden" + +#: diff.c:2157 +#, c-format +msgid "E103: Buffer \"%s\" is not in diff mode" +msgstr "E103: buffer \"%s\" is niet in diff-modus" + +#: diff.c:2201 +msgid "E787: Buffer changed unexpectedly" +msgstr "E787: buffer is onverwacht gewijzigd" + +#: digraph.c:2214 +msgid "E104: Escape not allowed in digraph" +msgstr "E104: Escape in digraph niet toegestaan" + +#: digraph.c:2407 +msgid "E544: Keymap file not found" +msgstr "E544: bestand met toetsbindingen niet gevonden" + +#: digraph.c:2434 +msgid "E105: Using :loadkeymap not in a sourced file" +msgstr "E105: Gebruik van :loadkeymap niet in een 'sourced' bestand" + +#: digraph.c:2473 +msgid "E791: Empty keymap entry" +msgstr "E791: toetsbinding leeg" + +#: edit.c:42 +msgid " Keyword completion (^N^P)" +msgstr " trefwoordvoltooiing (^N^P)" + +#. ctrl_x_mode == 0, ^P/^N compl. +#: edit.c:43 +msgid " ^X mode (^]^D^E^F^I^K^L^N^O^Ps^U^V^Y)" +msgstr " ^X-modus (^]^D^E^F^I^K^L^N^O^Ps^U^V^Y)" + +#: edit.c:45 +msgid " Whole line completion (^L^N^P)" +msgstr " gehele-regelvoltooiing (^L^N^P)" + +#: edit.c:46 +msgid " File name completion (^F^N^P)" +msgstr " bestandsnaamvoltooiing (^F^N^P)" + +#: edit.c:47 +msgid " Tag completion (^]^N^P)" +msgstr " tag-voltooiing (^]^N^P)" + +#: edit.c:48 +msgid " Path pattern completion (^N^P)" +msgstr " Padpatroonvoltooiing (^N^P)" + +#: edit.c:49 +msgid " Definition completion (^D^N^P)" +msgstr " definitievoltooiiing (^D^N^P)" + +#: edit.c:51 +msgid " Dictionary completion (^K^N^P)" +msgstr " Dictionaryvoltooiing (^K^N^P)" + +#: edit.c:52 +msgid " Thesaurus completion (^T^N^P)" +msgstr " Thesaurusvoltooiing (^T^N^P)" + +#: edit.c:53 +msgid " Command-line completion (^V^N^P)" +msgstr " opdrachtregelvoltooiing (^V^N^P)" + +#: edit.c:54 +msgid " User defined completion (^U^N^P)" +msgstr " gebruikergedefinieerde voltooiing (^U^N^P)" + +#: edit.c:55 +msgid " Omni completion (^O^N^P)" +msgstr " omni-voltooiing (^O^N^P)" + +#: edit.c:56 +msgid " Spelling suggestion (s^N^P)" +msgstr " spellingsuggestie (s^N^P)" + +#: edit.c:57 +msgid " Keyword Local completion (^N^P)" +msgstr " lokaal-trefwoordvoltooiing (^N^P)" + +#: edit.c:60 +msgid "Hit end of paragraph" +msgstr "Einde van paragraaf" + +#: edit.c:2042 +msgid "'dictionary' option is empty" +msgstr "'Dictionary'-optie is leeg" + +#: edit.c:2043 +msgid "'thesaurus' option is empty" +msgstr "'thesaurus'-optie is leeg" + +#: edit.c:3009 +#, c-format +msgid "Scanning dictionary: %s" +msgstr "Doorzoeken Dictionary: %s" + +#: edit.c:3494 +msgid " (insert) Scroll (^E/^Y)" +msgstr " (invoegen) scroll (^E/^Y)" + +#: edit.c:3496 +msgid " (replace) Scroll (^E/^Y)" +msgstr " (vervangen) scroll (^E/^Y)" + +#: edit.c:3973 +#, c-format +msgid "Scanning: %s" +msgstr "doorzoeken: %s" + +#: edit.c:4008 +msgid "Scanning tags." +msgstr "Doorzoeken tags." + +#: edit.c:5021 +msgid " Adding" +msgstr " toevoegen" + +#. showmode might reset the internal line pointers, so it must +#. * be called before line = ml_get(), or when this address is no +#. * longer needed. -- Acevedo. +#. +#: edit.c:5068 +msgid "-- Searching..." +msgstr "-- doorzoeken..." + +#: edit.c:5128 +msgid "Back at original" +msgstr "Terug naar origineel" + +#: edit.c:5133 +msgid "Word from other line" +msgstr "Woord uit andere regel" + +#: edit.c:5138 +msgid "The only match" +msgstr "Het enige resultaat" + +#: edit.c:5203 +#, c-format +msgid "match %d of %d" +msgstr "resultaat %d van %d" + +#: edit.c:5207 +#, c-format +msgid "match %d" +msgstr "resultaat %d" + +#: eval.c:96 +msgid "E18: Unexpected characters in :let" +msgstr "E18: onverwachte tekens in :let" + +#: eval.c:97 +#, c-format +msgid "E684: list index out of range: %ld" +msgstr "E684: lijstindex buiten bereik: %ld" + +#: eval.c:98 +#, c-format +msgid "E121: Undefined variable: %s" +msgstr "E121: ongedefinieerde variabele: %s" + +#: eval.c:99 +msgid "E111: Missing ']'" +msgstr "E111: ontbrekende ']'" + +#: eval.c:100 +#, c-format +msgid "E686: Argument of %s must be a List" +msgstr "E686: argument van %s moet een List zijn" + +#: eval.c:101 +#, c-format +msgid "E712: Argument of %s must be a List or Dictionary" +msgstr "E712: argument van %s moet een List of Dictionary zijn" + +#: eval.c:102 +msgid "E713: Cannot use empty key for Dictionary" +msgstr "E713: kan geen leeg trefwoord als Dictionary gebruiken" + +#: eval.c:103 +msgid "E714: List required" +msgstr "E714: List is vereist" + +#: eval.c:104 +msgid "E715: Dictionary required" +msgstr "E715: Dictionary is vereist" + +#: eval.c:105 +#, c-format +msgid "E118: Too many arguments for function: %s" +msgstr "E118: te veel argumenten voor functie: %s" + +#: eval.c:106 +#, c-format +msgid "E716: Key not present in Dictionary: %s" +msgstr "E716: trefwoord niet aangetroffen in Dictionary: %s" + +#: eval.c:107 +#, c-format +msgid "E122: Function %s already exists, add ! to replace it" +msgstr "E122: function %s bestaat reeds, voeg ! toe om te vervangen" + +#: eval.c:108 +msgid "E717: Dictionary entry already exists" +msgstr "E717: woord bestaat al in Dictionary" + +#: eval.c:109 +msgid "E718: Funcref required" +msgstr "E718: Funcref is vereist" + +#: eval.c:110 +msgid "E719: Cannot use [:] with a Dictionary" +msgstr "E719: kan [:] niet met een Dictionary gebruiken" + +#: eval.c:111 +#, c-format +msgid "E734: Wrong variable type for %s=" +msgstr "E734: onjuist type variabele voor %s=" + +#: eval.c:112 +#, c-format +msgid "E130: Unknown function: %s" +msgstr "E130: onbekende functie: %s" + +#: eval.c:113 +#, c-format +msgid "E461: Illegal variable name: %s" +msgstr "E461: ongeldige variabelenaam: %s" + +#: eval.c:1931 +msgid "E687: Less targets than List items" +msgstr "E687: minder doelen dan Listitems" + +#: eval.c:1936 +msgid "E688: More targets than List items" +msgstr "E688: meer doelen dan Listitems" + +#: eval.c:2022 +msgid "Double ; in list of variables" +msgstr "Dubbele ; in variabelenlijst" + +#: eval.c:2241 +#, c-format +msgid "E738: Can't list variables for %s" +msgstr "E738: kan variabelen voor %s niet tonen" + +#: eval.c:2587 +msgid "E689: Can only index a List or Dictionary" +msgstr "E689: alleen een List of Dictionary kan geïndexeerd worden" + +#: eval.c:2593 +msgid "E708: [:] must come last" +msgstr "E708: [:] moet als laatste staan" + +#: eval.c:2645 +msgid "E709: [:] requires a List value" +msgstr "E709: [:] vereist een Listwaarde" + +#: eval.c:2881 +msgid "E710: List value has more items than target" +msgstr "E710: Listwaarde heeft meer value has more items than target" + +#: eval.c:2885 +msgid "E711: List value has not enough items" +msgstr "E711: Listwaarde heeft onvoldoende items" + +#: eval.c:3120 +msgid "E690: Missing \"in\" after :for" +msgstr "E690: \"in\" ontbreekt na :for" + +#: eval.c:3353 +#, c-format +msgid "E107: Missing parentheses: %s" +msgstr "E107: ontbrekende haakjes: %s" + +#: eval.c:3592 +#, c-format +msgid "E108: No such variable: \"%s\"" +msgstr "E108: onbekende variabele: \"%s\"" + +#: eval.c:3679 +msgid "E743: variable nested too deep for (un)lock" +msgstr "E743: variabele is te diep genest om te beveiligen" + +#: eval.c:4027 +msgid "E109: Missing ':' after '?'" +msgstr "E109: ':' ontbreekt na '?'" + +#: eval.c:4329 +msgid "E691: Can only compare List with List" +msgstr "E691: List kan alleen met een Lijst worden vergeleken" + +#: eval.c:4331 +msgid "E692: Invalid operation for Lists" +msgstr "E692: ongeldige bewerking voor Listen" + +#: eval.c:4358 +msgid "E735: Can only compare Dictionary with Dictionary" +msgstr "E735: Dictionary kan alleen met Woordenboek worden vergeleken" + +#: eval.c:4360 +msgid "E736: Invalid operation for Dictionary" +msgstr "E736: ongeldige bewerking voor Dictionary" + +#: eval.c:4380 +msgid "E693: Can only compare Funcref with Funcref" +msgstr "E693: Funcref kan alleen met Funcref worden vergeleken" + +#: eval.c:4382 +msgid "E694: Invalid operation for Funcrefs" +msgstr "E694: ongeldige bewerking voor Funcrefs" + +#: eval.c:4802 +msgid "E804: Cannot use '%' with Float" +msgstr "E804: '%' kan niet met Float worden gebruikt" + +#: eval.c:5022 +msgid "E110: Missing ')'" +msgstr "E110: ')' ontbreekt" + +#: eval.c:5174 +msgid "E695: Cannot index a Funcref" +msgstr "E695: een Funcref kan niet geïndexeerd worden" + +#: eval.c:5431 +#, c-format +msgid "E112: Option name missing: %s" +msgstr "E112: optienaam ontbreekt: %s" + +#: eval.c:5449 +#, c-format +msgid "E113: Unknown option: %s" +msgstr "E113: onbekende optie: %s" + +#: eval.c:5515 +#, c-format +msgid "E114: Missing quote: %s" +msgstr "E114: ontbrekend aanhaalteken: %s" + +#: eval.c:5651 +#, c-format +msgid "E115: Missing quote: %s" +msgstr "E115: ontbrekend aanhaalteken: %s" + +#: eval.c:5730 +#, c-format +msgid "E696: Missing comma in List: %s" +msgstr "E696: komma ontbreekt in List: %s" + +#: eval.c:5738 +#, c-format +msgid "E697: Missing end of List ']': %s" +msgstr "E697: einde van List ']' ontbreekt: %s" + +#: eval.c:7230 +#, c-format +msgid "E720: Missing colon in Dictionary: %s" +msgstr "E720: dubbelepunt in Dictionary ontbreekt: %s" + +#: eval.c:7259 +#, c-format +msgid "E721: Duplicate key in Dictionary: \"%s\"" +msgstr "E721: dubbele sleutel in Dictionary: \"%s\"" + +#: eval.c:7279 +#, c-format +msgid "E722: Missing comma in Dictionary: %s" +msgstr "E722: komma ontbreekt in Dictionary: %s" + +#: eval.c:7287 +#, c-format +msgid "E723: Missing end of Dictionary '}': %s" +msgstr "E723: einde van Dictionary '}' ontbreekt: %s" + +#: eval.c:7325 +msgid "E724: variable nested too deep for displaying" +msgstr "E724: variabele is te diep genest om te tonen" + +#: eval.c:8059 +#, c-format +msgid "E740: Too many arguments for function %s" +msgstr "E740: teveel argumenten voor functie %s" + +#: eval.c:8061 +#, c-format +msgid "E116: Invalid arguments for function %s" +msgstr "E116: ongeldige argumenten voor functie %s" + +#: eval.c:8270 +#, c-format +msgid "E117: Unknown function: %s" +msgstr "E117: onbekende functie: %s" + +#: eval.c:8276 +#, c-format +msgid "E119: Not enough arguments for function: %s" +msgstr "E119: onvoldoende argumenten voor functie: %s" + +#: eval.c:8280 +#, c-format +msgid "E120: Using not in a script context: %s" +msgstr "E120: gebruik van buiten een scriptcontext: %s" + +#: eval.c:8284 +#, c-format +msgid "E725: Calling dict function without Dictionary: %s" +msgstr "E725: dict-functie aanroep zonder Dictionary: %s" + +#: eval.c:8357 +msgid "E808: Number or Float required" +msgstr "E808: Number of Float vereist" + +#: eval.c:8949 +msgid "E699: Too many arguments" +msgstr "E699:teveel argumenten" + +#: eval.c:9118 +msgid "E785: complete() can only be used in Insert mode" +msgstr "E785: complete() kan alleen in Invoegmodus worden gebruikt" + +#. +#. * Yes this is ugly, I don't particularly like it either. But doing it +#. * this way has the compelling advantage that translations need not to +#. * be touched at all. See below what 'ok' and 'ync' are used for. +#. +#: eval.c:9218 +#: gui.c:4876 +#: gui_gtk.c:2144 +#: os_mswin.c:598 +msgid "&Ok" +msgstr "&Ok" + +#: eval.c:9914 +#, c-format +msgid "E737: Key already exists: %s" +msgstr "E737: sleutel bestaat al: %s" + +#: eval.c:10506 +#, c-format +msgid "+-%s%3ld lines: " +msgstr "+-%s%3ld regels: " + +#: eval.c:10594 +#, c-format +msgid "E700: Unknown function: %s" +msgstr "E700: onbekende functie: %s" + +#: eval.c:12620 +msgid "" +"&OK\n" +"&Cancel" +msgstr "" +"&OK\n" +"&Annuleren" + +#: eval.c:12702 +msgid "called inputrestore() more often than inputsave()" +msgstr "inputrestore() vaker aangeroepen dan inputsave()" + +#: eval.c:12836 +msgid "E786: Range not allowed" +msgstr "E786: bereik niet toegestaan" + +#: eval.c:13036 +msgid "E701: Invalid type for len()" +msgstr "E701: ongeldig type voor len()" + +#: eval.c:14063 +msgid "E726: Stride is zero" +msgstr "E726: stap is nul" + +#: eval.c:14065 +msgid "E727: Start past end" +msgstr "E727: start na einde" + +#: eval.c:14118 +#: eval.c:17978 +msgid "" +msgstr "" + +#: eval.c:14352 +msgid "E240: No connection to Vim server" +msgstr "E240: geen verbinding met Vim-server" + +#: eval.c:14400 +#, c-format +msgid "E241: Unable to send to %s" +msgstr "E241: verzenden naar %s onmogelijk" + +#: eval.c:14547 +msgid "E277: Unable to read a server reply" +msgstr "E277: lezen van serverantwoord onmogelijk" + +#: eval.c:14797 +msgid "E655: Too many symbolic links (cycle?)" +msgstr "E655: teveel symbolische koppelingen (oneindige lus?)" + +#: eval.c:15527 +msgid "E258: Unable to send to client" +msgstr "E258: verzenden nar client onmogelijk" + +#: eval.c:16294 +msgid "E702: Sort compare function failed" +msgstr "E702: sorteer-vergelijkfunctie mislukt" + +#: eval.c:16619 +msgid "(Invalid)" +msgstr "(ongeldig)" + +#: eval.c:17104 +msgid "E677: Error writing temp file" +msgstr "E677: opslaan van temp-bestand is mislukt" + +#: eval.c:19007 +msgid "E805: Using a Float as a Number" +msgstr "E805: een Float wordt als Number gebruikt" + +#: eval.c:19011 +msgid "E703: Using a Funcref as a Number" +msgstr "E703: een Funcref wordt als Number gebruikt" + +#: eval.c:19019 +msgid "E745: Using a List as a Number" +msgstr "E745: List wordt als een Number gebruikt" + +#: eval.c:19022 +msgid "E728: Using a Dictionary as a Number" +msgstr "E728: Dictionary gebruiken als een Number" + +#: eval.c:19125 +msgid "E729: using Funcref as a String" +msgstr "E729: Funcref gebruiken als een String" + +#: eval.c:19128 +msgid "E730: using List as a String" +msgstr "E730: List gebruiken als een String" + +#: eval.c:19131 +msgid "E731: using Dictionary as a String" +msgstr "E731: Dictionary gebruiken als een String" + +#: eval.c:19135 +msgid "E806: using Float as a String" +msgstr "E806: Float gebruiken als een String" + +#: eval.c:19505 +#, c-format +msgid "E704: Funcref variable name must start with a capital: %s" +msgstr "E704: variabelenaam van Funcref moet beginnen met een hoofdletter: %s" + +#: eval.c:19513 +#, c-format +msgid "E705: Variable name conflicts with existing function: %s" +msgstr "E705: variablenaam botst met bestaande functie: %s" + +#: eval.c:19538 +#, c-format +msgid "E706: Variable type mismatch for: %s" +msgstr "E706: variabelesoort past niet bij: %s" + +#: eval.c:19647 +#, c-format +msgid "E795: Cannot delete variable %s" +msgstr "E795: kan variabele %s niet verwijderen" + +#: eval.c:19664 +#, c-format +msgid "E741: Value is locked: %s" +msgstr "E741: waarde is geblokkeerd: %s" + +#: eval.c:19665 +#: eval.c:19671 +#: message.c:2132 +#: os_mswin.c:2258 +msgid "Unknown" +msgstr "Onbekend" + +#: eval.c:19670 +#, c-format +msgid "E742: Cannot change value of %s" +msgstr "E742: kan waarde van %s niet veranderen" + +#: eval.c:19755 +msgid "E698: variable nested too deep for making a copy" +msgstr "E698: variabele te diep genest om een kopie te maken" + +#: eval.c:20228 +#, c-format +msgid "E123: Undefined function: %s" +msgstr "E123: ongedefinieerde functie: %s" + +#: eval.c:20241 +#, c-format +msgid "E124: Missing '(': %s" +msgstr "E124: ontbrekende '(': %s" + +#: eval.c:20297 +#, c-format +msgid "E125: Illegal argument: %s" +msgstr "E125: ongeldig argument: %s" + +#: eval.c:20407 +msgid "E126: Missing :endfunction" +msgstr "E126: ontbrekende :endfunction" + +#: eval.c:20544 +#, c-format +msgid "E707: Function name conflicts with variable: %s" +msgstr "E707: functienaam botst met variabele: %s" + +#: eval.c:20559 +#, c-format +msgid "E127: Cannot redefine function %s: It is in use" +msgstr "E127: kan functie %s niet opnieuw definiëren, het is in gebruik" + +#: eval.c:20624 +#, c-format +msgid "E746: Function name does not match script file name: %s" +msgstr "E746: functienaam komt niet overeen met bestandsnaam van het script: %s" + +#: eval.c:20742 +msgid "E129: Function name required" +msgstr "E129: functienaam is vereist" + +#: eval.c:20862 +#, c-format +msgid "E128: Function name must start with a capital or contain a colon: %s" +msgstr "E128: functionnaam moet met een hoofdletter beginnen of een dubbelepunt bevatten: %s" + +#: eval.c:21394 +#, c-format +msgid "E131: Cannot delete function %s: It is in use" +msgstr "E131: functie %s wordt gebruikt en kan niet worden verwijderd" + +#: eval.c:21514 +msgid "E132: Function call depth is higher than 'maxfuncdepth'" +msgstr "E132: diepte functieaanroep overstijgt 'maxfuncdepth'" + +#: eval.c:21653 +#, c-format +msgid "calling %s" +msgstr "%s aanroepen" + +#: eval.c:21745 +#, c-format +msgid "%s aborted" +msgstr "%s afgebroken" + +#: eval.c:21747 +#, c-format +msgid "%s returning #%ld" +msgstr "%s komt terug met de waarde #%ld" + +#: eval.c:21763 +#, c-format +msgid "%s returning %s" +msgstr "%s komt terug met de waarde %s" + +#: eval.c:21787 +#: ex_cmds2.c:3233 +#, c-format +msgid "continuing in %s" +msgstr "voortzetten in %s" + +#: eval.c:21906 +msgid "E133: :return not inside a function" +msgstr "E133: :return niet binnen een functie" + +#: eval.c:22319 +msgid "" +"\n" +"# global variables:\n" +msgstr "" +"\n" +"# globale variabelen:\n" + +#: eval.c:22436 +msgid "" +"\n" +"\tLast set from " +msgstr "" +"\n" +"\tLaatst ingesteld door " + +#: eval.c:22456 +msgid "No old files" +msgstr "Geen oudere bestanden" + +#: ex_cmds.c:101 +#, c-format +msgid "<%s>%s%s %d, Hex %02x, Octal %03o" +msgstr "<%s>%s%s %d, Hex %02x, Octal %03o" + +#: ex_cmds.c:128 +#, c-format +msgid "> %d, Hex %04x, Octal %o" +msgstr "> %d, Hex %04x, Octal %o" + +#: ex_cmds.c:129 +#, c-format +msgid "> %d, Hex %08x, Octal %o" +msgstr "> %d, Hex %08x, Octal %o" + +#: ex_cmds.c:739 +msgid "E134: Move lines into themselves" +msgstr "E134: verplaats regels in zichzelf" + +#: ex_cmds.c:808 +msgid "1 line moved" +msgstr "1 regel verplaatst" + +#: ex_cmds.c:810 +#, c-format +msgid "%ld lines moved" +msgstr "%ld regels verplaatst" + +#: ex_cmds.c:1305 +#, c-format +msgid "%ld lines filtered" +msgstr "%ld regels gefilterd" + +#: ex_cmds.c:1329 +msgid "E135: *Filter* Autocommands must not change current buffer" +msgstr "E135: *Filter* Autocommands mogen huidige buffer niet wijzigen" + +#: ex_cmds.c:1414 +msgid "[No write since last change]\n" +msgstr "[Niets opgeslagen sinds laatste wijziging]\n" + +#: ex_cmds.c:1672 +#, c-format +msgid "%sviminfo: %s in line: " +msgstr "%sviminfo: %s in regel: " + +#: ex_cmds.c:1680 +msgid "E136: viminfo: Too many errors, skipping rest of file" +msgstr "E136: viminfo: teveel fouten, restand van bestand overgeslagen" + +#: ex_cmds.c:1709 +#, c-format +msgid "Reading viminfo file \"%s\"%s%s%s" +msgstr "Inlezen viminfo-bestand \"%s\"%s%s%s" + +#: ex_cmds.c:1711 +msgid " info" +msgstr " info" + +#: ex_cmds.c:1712 +msgid " marks" +msgstr " markering" + +#: ex_cmds.c:1713 +msgid " oldfiles" +msgstr " oud-bestanden" + +#: ex_cmds.c:1714 +msgid " FAILED" +msgstr " MISLUKT" + +#. avoid a wait_return for this message, it's annoying +#: ex_cmds.c:1810 +#, c-format +msgid "E137: Viminfo file is not writable: %s" +msgstr "E137: viminfo-bestand is niet schrijfbaar: %s" + +#: ex_cmds.c:1963 +#, c-format +msgid "E138: Can't write viminfo file %s!" +msgstr "E138: kan niet naar viminfo-bestand %s schrijven!" + +#: ex_cmds.c:1973 +#, c-format +msgid "Writing viminfo file \"%s\"" +msgstr "viminfo-bestand \"%s\" opslaan" + +#. Write the info: +#: ex_cmds.c:2081 +#, c-format +msgid "# This viminfo file was generated by Vim %s.\n" +msgstr "# Dit viminfo-bestand is aangemaakt door Vim %s.\n" + +#: ex_cmds.c:2083 +#, c-format +msgid "" +"# You may edit it if you're careful!\n" +"\n" +msgstr "" +"# Bewerken is toegestaan, maar doe het met aandacht!\n" +"\n" + +#: ex_cmds.c:2085 +#, c-format +msgid "# Value of 'encoding' when this file was written\n" +msgstr "# Waarde van 'encoding' bij het opslaan van dit bestand\n" + +#: ex_cmds.c:2185 +msgid "Illegal starting char" +msgstr "Ongeldig startteken" + +#: ex_cmds.c:2551 +#: ex_cmds2.c:1478 +msgid "Save As" +msgstr "Opslaan als" + +#: ex_cmds.c:2628 +msgid "Write partial file?" +msgstr "Gedeeltelijk bestand opslaan?" + +#: ex_cmds.c:2635 +msgid "E140: Use ! to write partial buffer" +msgstr "E140: gebruik ! om gedeeltelijk buffer op te slaan" + +#: ex_cmds.c:2777 +#, c-format +msgid "Overwrite existing file \"%s\"?" +msgstr "Bestaand bestand \"%s\" overschrijven?" + +#: ex_cmds.c:2820 +#, c-format +msgid "Swap file \"%s\" exists, overwrite anyway?" +msgstr "Wisselbestand \"%s\" bestaat, toch overschrijven?" + +#: ex_cmds.c:2833 +#, c-format +msgid "E768: Swap file exists: %s (:silent! overrides)" +msgstr "E768: wisselbestand bestaat: %s (:silent! overschrijft)" + +#: ex_cmds.c:2901 +#, c-format +msgid "E141: No file name for buffer %ld" +msgstr "E141: buffer %ld heeft geen bestandsnaam" + +#: ex_cmds.c:2940 +msgid "E142: File not written: Writing is disabled by 'write' option" +msgstr "E142: bestand is niet opgeslagen: opslaan is uitgeschakeld door 'write'-optie" + +#: ex_cmds.c:2970 +#, c-format +msgid "" +"'readonly' option is set for \"%s\".\n" +"Do you wish to write anyway?" +msgstr "" +"'alleen-lezen'-optie is inschakeld voor \"%s\".\n" +"Toch opslaan?" + +#: ex_cmds.c:2973 +#, c-format +msgid "" +"File permissions of \"%s\" are read-only.\n" +"It may still be possible to write it.\n" +"Do you wish to try?" +msgstr "" +"Bestandsrechten van \"%s\" zijn alleen-lezen.\n" +"Mogelijk kan er toch naar weggeschreven worden.\n" +"Proberen op te slaan?" + +#: ex_cmds.c:2990 +#, c-format +msgid "E505: \"%s\" is read-only (add ! to override)" +msgstr "E505: \"%s\" is alleen-lezen (voeg ! toe om te overschrijven)" + +#: ex_cmds.c:3177 +msgid "Edit File" +msgstr "Bestand bewerken" + +#: ex_cmds.c:3860 +#, c-format +msgid "E143: Autocommands unexpectedly deleted new buffer %s" +msgstr "E143: 'Autocommands' hebben het nieuwe buffer %s onverwacht verwijderd" + +#: ex_cmds.c:4076 +msgid "E144: non-numeric argument to :z" +msgstr "E144: niet-numeriek argument voor :z" + +#: ex_cmds.c:4175 +msgid "E145: Shell commands not allowed in rvim" +msgstr "E145: in rvim zijn shell-opdrachten zijn niet toegestaan" + +#: ex_cmds.c:4276 +msgid "E146: Regular expressions can't be delimited by letters" +msgstr "E146: reguliere expressies kunnen niet begrensd worden door letters" + +#: ex_cmds.c:4736 +#, c-format +msgid "replace with %s (y/n/a/q/l/^E/^Y)?" +msgstr "vervang door %s (y/n/a/q/l/^E/^Y)?" + +#: ex_cmds.c:5181 +msgid "(Interrupted) " +msgstr "(Onderbroken) " + +#: ex_cmds.c:5186 +msgid "1 match" +msgstr "1 overeenkomst" + +#: ex_cmds.c:5186 +msgid "1 substitution" +msgstr "1 vervanging" + +#: ex_cmds.c:5189 +#, c-format +msgid "%ld matches" +msgstr "%ld overeenkomsten" + +#: ex_cmds.c:5189 +#, c-format +msgid "%ld substitutions" +msgstr "%ld vervangingen" + +#: ex_cmds.c:5194 +msgid " on 1 line" +msgstr " op 1 regel" + +#: ex_cmds.c:5197 +#, c-format +msgid " on %ld lines" +msgstr " op %ld regels" + +#: ex_cmds.c:5244 +msgid "E147: Cannot do :global recursive" +msgstr "E147: kan :global niet recursief uitvoeren" + +#: ex_cmds.c:5277 +msgid "E148: Regular expression missing from global" +msgstr "E148: reguliere expressies ontbreken bij global" + +#: ex_cmds.c:5326 +#, c-format +msgid "Pattern found in every line: %s" +msgstr "Patroon aangetroffen in iedere regel: %s" + +#: ex_cmds.c:5413 +#, c-format +msgid "" +"\n" +"# Last Substitute String:\n" +"$" +msgstr "" +"\n" +"# Laatst vervangingsstring:\n" +"$" + +#: ex_cmds.c:5526 +msgid "E478: Don't panic!" +msgstr "E478: geen paniek!" + +#: ex_cmds.c:5572 +#, c-format +msgid "E661: Sorry, no '%s' help for %s" +msgstr "E661: helaas, geen '%s'-hulp voor %s" + +#: ex_cmds.c:5575 +#, c-format +msgid "E149: Sorry, no help for %s" +msgstr "E149: helaas, geen hulp voor %s" + +#: ex_cmds.c:5617 +#, c-format +msgid "Sorry, help file \"%s\" not found" +msgstr "helaas, hulpbestand \"%s\" is niet gevonden" + +#: ex_cmds.c:6195 +#, c-format +msgid "E150: Not a directory: %s" +msgstr "E150: geen map: %s" + +#: ex_cmds.c:6338 +#, c-format +msgid "E152: Cannot open %s for writing" +msgstr "E152: kan %s niet openen om naar te schrijven" + +#: ex_cmds.c:6375 +#, c-format +msgid "E153: Unable to open %s for reading" +msgstr "E153: kan %s niet openen om uit te lezen" + +#: ex_cmds.c:6411 +#, c-format +msgid "E670: Mix of help file encodings within a language: %s" +msgstr "E670: mengelmoes van hulpbestandcoderingen binnen een taal: %s" + +#: ex_cmds.c:6489 +#, c-format +msgid "E154: Duplicate tag \"%s\" in file %s/%s" +msgstr "E154: dubbele tag \"%s\" in bestand %s/%s" + +#: ex_cmds.c:6625 +#, c-format +msgid "E160: Unknown sign command: %s" +msgstr "E160: onbekende opdracht voor margetekens: %s" + +#: ex_cmds.c:6642 +msgid "E156: Missing sign name" +msgstr "E156: ontbrekende naam margeteken" + +#: ex_cmds.c:6688 +msgid "E612: Too many signs defined" +msgstr "E612: teveel margetekens gedefinieerd" + +#: ex_cmds.c:6756 +#, c-format +msgid "E239: Invalid sign text: %s" +msgstr "E239: ongeldige tekst margeteken: %s" + +#: ex_cmds.c:6787 +#: ex_cmds.c:6962 +#, c-format +msgid "E155: Unknown sign: %s" +msgstr "E155: onbekend margeteken: %s" + +#: ex_cmds.c:6820 +msgid "E159: Missing sign number" +msgstr "E159: ontbrekend nummer margeteken" + +#: ex_cmds.c:6902 +#, c-format +msgid "E158: Invalid buffer name: %s" +msgstr "E158: ongeldige buffernaam: %s" + +#: ex_cmds.c:6941 +#, c-format +msgid "E157: Invalid sign ID: %ld" +msgstr "E157: ongeldige id margeteken: %ld" + +#: ex_cmds.c:7011 +msgid " (NOT FOUND)" +msgstr " (NIET GEVONDEN)" + +#: ex_cmds.c:7013 +msgid " (not supported)" +msgstr "(niet ondersteund)" + +#: ex_cmds.c:7137 +msgid "[Deleted]" +msgstr "[Verwijderd]" + +#: ex_cmds2.c:138 +msgid "Entering Debug mode. Type \"cont\" to continue." +msgstr "Debug-modus gestart. Typ \"cont\" om verder te gaan." + +#: ex_cmds2.c:142 +#: ex_docmd.c:1094 +#, c-format +msgid "line %ld: %s" +msgstr "regel %ld: %s" + +#: ex_cmds2.c:144 +#, c-format +msgid "cmd: %s" +msgstr "cmd: %s" + +#: ex_cmds2.c:344 +#, c-format +msgid "Breakpoint in \"%s%s\" line %ld" +msgstr "'Breakpoint' in \"%s%s\" regel %ld" + +#: ex_cmds2.c:656 +#, c-format +msgid "E161: Breakpoint not found: %s" +msgstr "E161: 'Breakpoint' niet gevonden: %s" + +#: ex_cmds2.c:692 +msgid "No breakpoints defined" +msgstr "Geen 'breakpoints' opgegeven" + +#: ex_cmds2.c:697 +#, c-format +msgid "%3d %s %s line %ld" +msgstr "%3d %s %s regel %ld" + +#: ex_cmds2.c:1095 +msgid "E750: First use \":profile start {fname}\"" +msgstr "E750: gebruik eerst \":profile start {fname}\"" + +#: ex_cmds2.c:1503 +#, c-format +msgid "Save changes to \"%s\"?" +msgstr "veranderingen opslaan in \"%s\"?" + +#: ex_cmds2.c:1505 +#: ex_docmd.c:10880 +msgid "Untitled" +msgstr "naamloos" + +#: ex_cmds2.c:1634 +#, c-format +msgid "E162: No write since last change for buffer \"%s\"" +msgstr "E162: niets opgeslagen sinds laatste wijziging van buffer \"%s\"" + +#: ex_cmds2.c:1705 +msgid "Warning: Entered other buffer unexpectedly (check autocommands)" +msgstr "Waarschuwing: onverwacht ander buffer binnengegaan (controleer 'autocommands')" + +#: ex_cmds2.c:2149 +msgid "E163: There is only one file to edit" +msgstr "E163: slechts een bestand beschikbaar voor bewerking" + +#: ex_cmds2.c:2151 +msgid "E164: Cannot go before first file" +msgstr "E164: kan niet verder terug dan eerste bestand" + +#: ex_cmds2.c:2153 +msgid "E165: Cannot go beyond last file" +msgstr "E165: kan niet verder dan laatste bestand" + +#: ex_cmds2.c:2583 +#, c-format +msgid "E666: compiler not supported: %s" +msgstr "E666: compiler niet ondersteund: %s" + +#: ex_cmds2.c:2684 +#, c-format +msgid "Searching for \"%s\" in \"%s\"" +msgstr "Naar \"%s\" in \"%s\" zoeken" + +#: ex_cmds2.c:2711 +#, c-format +msgid "Searching for \"%s\"" +msgstr "Naar \"%s\" zoeken" + +#: ex_cmds2.c:2737 +#, c-format +msgid "not found in 'runtimepath': \"%s\"" +msgstr "niet gevonden in 'runtimepath': \"%s\"" + +#: ex_cmds2.c:2772 +msgid "Source Vim script" +msgstr "Vim-script laden" + +#: ex_cmds2.c:2962 +#, c-format +msgid "Cannot source a directory: \"%s\"" +msgstr "kan geen map laden: \"%s\"" + +#: ex_cmds2.c:3019 +#, c-format +msgid "could not source \"%s\"" +msgstr "kan \"%s\" niet laden" + +#: ex_cmds2.c:3021 +#, c-format +msgid "line %ld: could not source \"%s\"" +msgstr "regel %ld: kan \"%s\" niet laden" + +#: ex_cmds2.c:3037 +#, c-format +msgid "sourcing \"%s\"" +msgstr "\"%s\" laden" + +#: ex_cmds2.c:3039 +#, c-format +msgid "line %ld: sourcing \"%s\"" +msgstr "regel %ld: \"%s\" laden" + +#: ex_cmds2.c:3231 +#, c-format +msgid "finished sourcing %s" +msgstr "laden van %s afgerond" + +#: ex_cmds2.c:3315 +msgid "modeline" +msgstr "modusregel" + +#: ex_cmds2.c:3317 +msgid "--cmd argument" +msgstr "argument van --cmd" + +#: ex_cmds2.c:3319 +msgid "-c argument" +msgstr "argument van -c" + +#: ex_cmds2.c:3321 +msgid "environment variable" +msgstr "omgevingsvariabele" + +#: ex_cmds2.c:3323 +msgid "error handler" +msgstr "foutafhandeling" + +#: ex_cmds2.c:3615 +msgid "W15: Warning: Wrong line separator, ^M may be missing" +msgstr "W15: waarschuwing: ongeldige regelscheiding, ^M kan ontbreken" + +#: ex_cmds2.c:3748 +msgid "E167: :scriptencoding used outside of a sourced file" +msgstr "E167: :scriptencoding buiten een geladen bestand gebruikt" + +#: ex_cmds2.c:3781 +msgid "E168: :finish used outside of a sourced file" +msgstr "E168: :finish buiten een geladen bestand gebruikt" + +#: ex_cmds2.c:4103 +#, c-format +msgid "Current %slanguage: \"%s\"" +msgstr "Huidige %s-taal: \"%s\"" + +#: ex_cmds2.c:4120 +#, c-format +msgid "E197: Cannot set language to \"%s\"" +msgstr "E197: taal kan niet ingesteld worden op \"%s\"" + +#: ex_docmd.c:639 +msgid "Entering Ex mode. Type \"visual\" to go to Normal mode." +msgstr "Ex-modus betreden. Typ \"visual\" om naar de Normaal-modus te gaan." + +#: ex_docmd.c:694 +msgid "E501: At end-of-file" +msgstr "E501: bij bestandseinde" + +#: ex_docmd.c:793 +msgid "E169: Command too recursive" +msgstr "E169: opdracht te recursief" + +#: ex_docmd.c:1372 +#, c-format +msgid "E605: Exception not caught: %s" +msgstr "E605: uitzondering niet afgevangen: %s" + +#: ex_docmd.c:1460 +msgid "End of sourced file" +msgstr "Einde van geladen bestand" + +#: ex_docmd.c:1461 +msgid "End of function" +msgstr "Einde van functie" + +#: ex_docmd.c:2109 +msgid "E464: Ambiguous use of user-defined command" +msgstr "E464: dubbelzinnig gebruik van gebruikergedefinieerde opdracht" + +#: ex_docmd.c:2123 +msgid "E492: Not an editor command" +msgstr "E492: geen editor-opdracht" + +#: ex_docmd.c:2255 +msgid "E493: Backwards range given" +msgstr "E493: Teruggaand bereik opgegeven" + +#: ex_docmd.c:2259 +msgid "Backwards range given, OK to swap" +msgstr "Teruggaand bereik opgegeven, wisselen is toegestaan" + +#: ex_docmd.c:2322 +msgid "E494: Use w or w>>" +msgstr "E494: w of w>> gebruiken" + +#: ex_docmd.c:4095 +msgid "E319: Sorry, the command is not available in this version" +msgstr "E319: Helaas, in deze versie is de opdracht niet beschikbaar" + +#: ex_docmd.c:4444 +msgid "E172: Only one file name allowed" +msgstr "E172: slechts een bestandsnaam toegestaan" + +#: ex_docmd.c:5056 +msgid "1 more file to edit. Quit anyway?" +msgstr "1 bestand wacht nog op bewerking. Toch stoppen?" + +#: ex_docmd.c:5059 +#, c-format +msgid "%d more files to edit. Quit anyway?" +msgstr "%d bestanden wachten nog op bewerking. Toch stoppen?" + +#: ex_docmd.c:5066 +msgid "E173: 1 more file to edit" +msgstr "E173: 1 bestand wacht op bewerking" + +#: ex_docmd.c:5068 +#, c-format +msgid "E173: %ld more files to edit" +msgstr "E173: %ld bestanden wachten op bewerking" + +#: ex_docmd.c:5162 +msgid "E174: Command already exists: add ! to replace it" +msgstr "E174: opdracht bestaat al: voeg ! toe om het te vervangen" + +#: ex_docmd.c:5284 +msgid "" +"\n" +" Name Args Range Complete Definition" +msgstr "" +"\n" +" Naam Args Berk. Compleet Definitie" + +#: ex_docmd.c:5377 +msgid "No user-defined commands found" +msgstr "Geen gebruikergedefinieerde opdrachten gevonden" + +#: ex_docmd.c:5409 +msgid "E175: No attribute specified" +msgstr "E175: geen attribute opgegeven" + +#: ex_docmd.c:5461 +msgid "E176: Invalid number of arguments" +msgstr "E176: ongeldig aantal argumenten" + +#: ex_docmd.c:5476 +msgid "E177: Count cannot be specified twice" +msgstr "E177: aantal kan niet tweemaal worden opgegeven" + +#: ex_docmd.c:5486 +msgid "E178: Invalid default value for count" +msgstr "E178: ongeldige standaardwaarde voor aantal" + +#: ex_docmd.c:5514 +msgid "E179: argument required for -complete" +msgstr "E179: argument vereist voor -complete" + +#: ex_docmd.c:5526 +#, c-format +msgid "E181: Invalid attribute: %s" +msgstr "E181: ongeldig attribute: %s" + +#: ex_docmd.c:5572 +msgid "E182: Invalid command name" +msgstr "E182: ongeldige opdrachtnaam" + +#: ex_docmd.c:5587 +msgid "E183: User defined commands must start with an uppercase letter" +msgstr "E183: door gebruiker gedefinieerde opdrachten moet een een hoofdletter beginnen" + +#: ex_docmd.c:5655 +#, c-format +msgid "E184: No such user-defined command: %s" +msgstr "E184: deze door gebruiker gedefinieerde opdracht bestaat niet: %s" + +#: ex_docmd.c:6207 +#, c-format +msgid "E180: Invalid complete value: %s" +msgstr "E180: ongeldige voltooiingswaarde: %s" + +#: ex_docmd.c:6218 +msgid "E468: Completion argument only allowed for custom completion" +msgstr "E468: argument voor voltooiing alleen toegestaan bij aangepaste voltooiing" + +#: ex_docmd.c:6226 +msgid "E467: Custom completion requires a function argument" +msgstr "E467: aangepaste voltooiing vereist een functieargument" + +#: ex_docmd.c:6262 +msgid "unknown" +msgstr "onbekend" + +#: ex_docmd.c:6266 +#, c-format +msgid "E185: Cannot find color scheme %s" +msgstr "E185: kan kleurenschema %s niet vinden" + +#: ex_docmd.c:6274 +msgid "Greetings, Vim user!" +msgstr "Gegroet, Vim-gebruiker!" + +#: ex_docmd.c:6492 +msgid "E784: Cannot close last tab page" +msgstr "E784: laatste tabpagina kan niet afgesloten worden" + +#: ex_docmd.c:6534 +msgid "Already only one tab page" +msgstr "Reeds beperkt tot één tabpagina" + +#: ex_docmd.c:7221 +msgid "Edit File in new window" +msgstr "Bestand in nieuw venster bewerken" + +#: ex_docmd.c:7347 +#, c-format +msgid "Tab page %d" +msgstr "Tabpagina %d" + +#: ex_docmd.c:7739 +msgid "No swap file" +msgstr "Geen wisselbestand" + +#: ex_docmd.c:7844 +msgid "Append File" +msgstr "Bestand toevoegen" + +#: ex_docmd.c:7943 +msgid "E747: Cannot change directory, buffer is modified (add ! to override)" +msgstr "E747: kan niet van map veranderen, buffer is gewijzigd (voeg ! toe om te forceren)" + +#: ex_docmd.c:7952 +msgid "E186: No previous directory" +msgstr "E186: geen voorgaande map" + +#: ex_docmd.c:8033 +msgid "E187: Unknown" +msgstr "E187: onbekend" + +#: ex_docmd.c:8128 +msgid "E465: :winsize requires two number arguments" +msgstr "E465: :winsize vereist twee getallen als argument" + +#: ex_docmd.c:8190 +#, c-format +msgid "Window position: X %d, Y %d" +msgstr "Vensterpositie: X %d, Y %d" + +#: ex_docmd.c:8195 +msgid "E188: Obtaining window position not implemented for this platform" +msgstr "E188: verkrijgen van vensterpositie is voor dit platform niet geïmplementeerd" + +#: ex_docmd.c:8205 +msgid "E466: :winpos requires two number arguments" +msgstr "E466: :winpos vereist twee getallen als argument" + +#: ex_docmd.c:8565 +msgid "Save Redirection" +msgstr "'Redirection' opslaan" + +#: ex_docmd.c:8796 +msgid "Save View" +msgstr "Beeld opslaan" + +#: ex_docmd.c:8797 +msgid "Save Session" +msgstr "Sessie opslaan" + +#: ex_docmd.c:8799 +msgid "Save Setup" +msgstr "Instellingen opslaan" + +#: ex_docmd.c:8955 +#, c-format +msgid "E739: Cannot create directory: %s" +msgstr "E739: kan map %s niet aanmaken" + +#: ex_docmd.c:8984 +#, c-format +msgid "E189: \"%s\" exists (add ! to override)" +msgstr "E189: \"%s\" bestaat al (voeg ! toe om te forceren)" + +#: ex_docmd.c:8989 +#, c-format +msgid "E190: Cannot open \"%s\" for writing" +msgstr "E190: \"%s\" kan niet worden beschreven" + +#. set mark +#: ex_docmd.c:9013 +msgid "E191: Argument must be a letter or forward/backward quote" +msgstr "E191: argument moet een letter zijn of een aanhaalteken, voor of achterwaarts" + +#: ex_docmd.c:9060 +msgid "E192: Recursive use of :normal too deep" +msgstr "E192: recursief gebruik van :normal gaat te diep" + +#: ex_docmd.c:9659 +msgid "E809: #< is not available without the +eval feature" +msgstr "E809: #< is zonder de +eval-functionaliteit niet beschikbaar" + +#: ex_docmd.c:9668 +msgid "E194: No alternate file name to substitute for '#'" +msgstr "E194: er is geen wisselende bestandsnaam beschikbaar om '#' te vervangen" + +#: ex_docmd.c:9709 +msgid "E495: no autocommand file name to substitute for \"\"" +msgstr "E495: er is geen 'autocommand'-bestandsnaam om \"\" te vervangen" + +#: ex_docmd.c:9718 +msgid "E496: no autocommand buffer number to substitute for \"\"" +msgstr "E496: er is geen 'autocommand'-buffernummer om \"\" te vervangen" + +#: ex_docmd.c:9729 +msgid "E497: no autocommand match name to substitute for \"\"" +msgstr "E497: er is geen 'autocommand'-naamovereenkomst om \"\" te vervangen" + +#: ex_docmd.c:9739 +msgid "E498: no :source file name to substitute for \"\"" +msgstr "E498: er is geen :source-bestandsnaam om \"\" te vervangen" + +#: ex_docmd.c:9781 +#, no-c-format +msgid "E499: Empty file name for '%' or '#', only works with \":p:h\"" +msgstr "E499: lege bestandsnaam voor '%' of '#', werkt alleen samen met \":p:h\"" + +#: ex_docmd.c:9783 +msgid "E500: Evaluates to an empty string" +msgstr "E500: resulteert in een lege string" + +#: ex_docmd.c:10860 +msgid "E195: Cannot open viminfo file for reading" +msgstr "E195: het 'viminfo'-bestand kan niet worden gelezen" + +#: ex_docmd.c:11048 +msgid "E196: No digraphs in this version" +msgstr "E196: deze versie bevat geen 'digraphs'" + +#: ex_eval.c:441 +msgid "E608: Cannot :throw exceptions with 'Vim' prefix" +msgstr "E608: :throw exceptions met 'Vim' als voorvoegsel zijn niet mogelijk" + +#. always scroll up, don't overwrite +#: ex_eval.c:534 +#, c-format +msgid "Exception thrown: %s" +msgstr "Geworpen uitzondering: %s" + +#: ex_eval.c:588 +#, c-format +msgid "Exception finished: %s" +msgstr "Afgeronde uitzondering: %s" + +#: ex_eval.c:589 +#, c-format +msgid "Exception discarded: %s" +msgstr "Afgedankte uitzondering: %s" + +#: ex_eval.c:635 +#: ex_eval.c:687 +#, c-format +msgid "%s, line %ld" +msgstr "%s, regel %ld" + +#. always scroll up, don't overwrite +#: ex_eval.c:657 +#, c-format +msgid "Exception caught: %s" +msgstr "Gevangen uitzondering: %s" + +#: ex_eval.c:737 +#, c-format +msgid "%s made pending" +msgstr "%s aanhanging gemaakt" + +#: ex_eval.c:740 +#, c-format +msgid "%s resumed" +msgstr "%s voortgezet" + +#: ex_eval.c:744 +#, c-format +msgid "%s discarded" +msgstr "%s afgedankt" + +#: ex_eval.c:771 +msgid "Exception" +msgstr "Uitzondering" + +#: ex_eval.c:777 +msgid "Error and interrupt" +msgstr "Fout en onderbreken" + +#: ex_eval.c:779 +#: gui.c:4875 +#: gui_xmdlg.c:689 +#: gui_xmdlg.c:808 +#: os_mswin.c:597 +msgid "Error" +msgstr "Fout" + +#. if (pending & CSTP_INTERRUPT) +#: ex_eval.c:781 +msgid "Interrupt" +msgstr "Onderbreken" + +#: ex_eval.c:873 +msgid "E579: :if nesting too deep" +msgstr "E579: te diepe :if-nesting" + +#: ex_eval.c:910 +msgid "E580: :endif without :if" +msgstr "E580: :endif zonder :if" + +#: ex_eval.c:955 +msgid "E581: :else without :if" +msgstr "E581: :else zonder :if" + +#: ex_eval.c:958 +msgid "E582: :elseif without :if" +msgstr "E582: :elseif zonder :if" + +#: ex_eval.c:965 +msgid "E583: multiple :else" +msgstr "E583: meerdere :else" + +#: ex_eval.c:968 +msgid "E584: :elseif after :else" +msgstr "E584: :elseif na :else" + +#: ex_eval.c:1035 +msgid "E585: :while/:for nesting too deep" +msgstr "E585: te diepe :while/:for-nesting" + +#: ex_eval.c:1133 +msgid "E586: :continue without :while or :for" +msgstr "E586: :continue zonder :while of :for" + +#: ex_eval.c:1172 +msgid "E587: :break without :while or :for" +msgstr "E587: :break zonder :while of :for" + +#: ex_eval.c:1222 +msgid "E732: Using :endfor with :while" +msgstr "E732: gebruik van :endfor met :while" + +#: ex_eval.c:1224 +msgid "E733: Using :endwhile with :for" +msgstr "E733: gebruik van :endwhile met :for" + +#: ex_eval.c:1399 +msgid "E601: :try nesting too deep" +msgstr "E601: te diepe :try-nesting" + +#: ex_eval.c:1479 +msgid "E603: :catch without :try" +msgstr "E603: :catch zonder :try" + +#. Give up for a ":catch" after ":finally" and ignore it. +#. * Just parse. +#: ex_eval.c:1498 +msgid "E604: :catch after :finally" +msgstr "E604: :catch na :finally" + +#: ex_eval.c:1632 +msgid "E606: :finally without :try" +msgstr "E606: :finally zonder :try" + +#. Give up for a multiple ":finally" and ignore it. +#: ex_eval.c:1652 +msgid "E607: multiple :finally" +msgstr "E607: meerdere :finally" + +#: ex_eval.c:1762 +msgid "E602: :endtry without :try" +msgstr "E602: :endtry zonder :try" + +#: ex_eval.c:2267 +msgid "E193: :endfunction not inside a function" +msgstr "E193: :endfunction niet binnen een functie" + +#: ex_getln.c:2010 +msgid "E788: Not allowed to edit another buffer now" +msgstr "E788: nu een andere buffer bewerken is niet toegestaan" + +#: ex_getln.c:2025 +msgid "E811: Not allowed to change buffer information now" +msgstr "E811: nu bufferinformatie wijzigen is niet toegestaan" + +#: ex_getln.c:3923 +msgid "tagname" +msgstr "tagnaam" + +#: ex_getln.c:3926 +msgid " kind file\n" +msgstr "soor bestand\n" + +#: ex_getln.c:5708 +msgid "'history' option is zero" +msgstr "'history'-optie is nul" + +#: ex_getln.c:5979 +#, c-format +msgid "" +"\n" +"# %s History (newest to oldest):\n" +msgstr "" +"\n" +"# %s Historie (jongste naar oudste):\n" + +#: ex_getln.c:5980 +msgid "Command Line" +msgstr "Opdrachtregel" + +#: ex_getln.c:5981 +msgid "Search String" +msgstr "Zoekstring" + +#: ex_getln.c:5982 +msgid "Expression" +msgstr "Expressie" + +#: ex_getln.c:5983 +msgid "Input Line" +msgstr "Invoerregel" + +#: ex_getln.c:6021 +msgid "E198: cmd_pchar beyond the command length" +msgstr "E198: cmd_pchar is langer dan toegestaan voor een opdracht" + +#: ex_getln.c:6222 +msgid "E199: Active window or buffer deleted" +msgstr "E199: actieve venster of buffer verwijderd" + +#: fileio.c:158 +msgid "E812: Autocommands changed buffer or buffer name" +msgstr "E812: buffer of buffernaam gewijzigd door autocommands" + +#: fileio.c:418 +msgid "Illegal file name" +msgstr "Ongeldige bestandsnaam" + +#: fileio.c:447 +#: fileio.c:601 +#: fileio.c:3542 +#: fileio.c:3593 +msgid "is a directory" +msgstr "is een map" + +#: fileio.c:449 +msgid "is not a file" +msgstr "is geen bestand" + +#: fileio.c:462 +msgid "is a device (disabled with 'opendevice' option)" +msgstr "is een apparaat (uitgeschakeld door optie 'opendevice'" + +#: fileio.c:642 +#: fileio.c:4848 +msgid "[New File]" +msgstr "[Nieuw bestand]" + +#: fileio.c:645 +msgid "[New DIRECTORY]" +msgstr "[Nieuwe MAP]" + +#: fileio.c:679 +#: fileio.c:682 +msgid "[File too big]" +msgstr "Bestand te groot" + +#: fileio.c:684 +msgid "[Permission Denied]" +msgstr "[Geen rechten]" + +#: fileio.c:817 +msgid "E200: *ReadPre autocommands made the file unreadable" +msgstr "E200: *ReadPre autocommands hebben het bestand niet-leesbaar gemaakt" + +#: fileio.c:819 +msgid "E201: *ReadPre autocommands must not change current buffer" +msgstr "E201: *ReadPre autocommands mogen huidige buffer niet wijzigen" + +#: fileio.c:840 +msgid "Vim: Reading from stdin...\n" +msgstr "Vim: lezen van standaardinvoer...\n" + +#: fileio.c:846 +msgid "Reading from stdin..." +msgstr "Lezen van standaardinvoer..." + +#. Re-opening the original file failed! +#: fileio.c:1145 +msgid "E202: Conversion made file unreadable!" +msgstr "E202: bestand niet-leesbaar gemaakt door conversatie" + +#: fileio.c:2400 +msgid "[fifo/socket]" +msgstr "[fifo/socket]" + +#: fileio.c:2407 +msgid "[fifo]" +msgstr "[fifo]" + +#: fileio.c:2414 +msgid "[socket]" +msgstr "[socket]" + +#: fileio.c:2422 +msgid "[character special]" +msgstr "[karakter speciaal]" + +#: fileio.c:2429 +#: netbeans.c:3848 +msgid "[RO]" +msgstr "[RO]" + +#: fileio.c:2439 +msgid "[CR missing]" +msgstr "[CR ontbreekt]" + +#: fileio.c:2444 +msgid "[long lines split]" +msgstr "[lange regels gesplitst]" + +#: fileio.c:2450 +#: fileio.c:4832 +msgid "[NOT converted]" +msgstr "[NIET omgezet]" + +#: fileio.c:2455 +#: fileio.c:4837 +msgid "[converted]" +msgstr "[omgezet]" + +#: fileio.c:2462 +#: fileio.c:4862 +msgid "[crypted]" +msgstr "[versleuteld]" + +#: fileio.c:2470 +#, c-format +msgid "[CONVERSION ERROR in line %ld]" +msgstr "[OMZETFOUT in regel %ld]" + +#: fileio.c:2476 +#, c-format +msgid "[ILLEGAL BYTE in line %ld]" +msgstr "[ONGELDIGE BYTE in regel %ld]" + +#: fileio.c:2483 +msgid "[READ ERRORS]" +msgstr "[LEESFOUTEN]" + +#: fileio.c:2775 +msgid "Can't find temp file for conversion" +msgstr "Tijdelijk bestand voor conversie ontbreekt" + +#: fileio.c:2782 +msgid "Conversion with 'charconvert' failed" +msgstr "Conversatie met 'charconvert' is mislukt" + +#: fileio.c:2785 +msgid "can't read output of 'charconvert'" +msgstr "uitvoer van 'charconvert' kan niet worden gelezen" + +#: fileio.c:2852 +msgid "E821: File is encrypted with unknown method" +msgstr "E821: bestand is met onbekende methode versleuteld" + +#: fileio.c:3387 +msgid "E676: No matching autocommands for acwrite buffer" +msgstr "E676: geen overeenkomende autocommands voor 'acwrite'-buffer" + +#: fileio.c:3422 +msgid "E203: Autocommands deleted or unloaded buffer to be written" +msgstr "E203: autocommands hebben buffer verwijderd of gelost die moest worden opgeslagen" + +#: fileio.c:3445 +msgid "E204: Autocommand changed number of lines in unexpected way" +msgstr "E204: autocommand heeft op onverwachte wijze het aantal regels gewijzigd" + +#: fileio.c:3485 +msgid "NetBeans disallows writes of unmodified buffers" +msgstr "Netbeans staat het opslaan van onveranderde buffers niet toe" + +#: fileio.c:3493 +msgid "Partial writes disallowed for NetBeans buffers" +msgstr "Deelopslag voor buffers van Netbeans niet toegestaan" + +#: fileio.c:3548 +#: fileio.c:3566 +msgid "is not a file or writable device" +msgstr "is geen bestand of schrijfbaar apparaat" + +#: fileio.c:3577 +msgid "writing to device disabled with 'opendevice' option" +msgstr "het schrijven naar apparaat is uitgeschakeld met optie 'opendevice'" + +#: fileio.c:3619 +#: netbeans.c:3913 +msgid "is read-only (add ! to override)" +msgstr "is alleen-lezen (voeg ! toe om te schrijven)" + +#: fileio.c:3983 +msgid "E506: Can't write to backup file (add ! to override)" +msgstr "E506: kan niet naar back-upbestand schrijven (voeg hiervoor ! toe)" + +#: fileio.c:3995 +msgid "E507: Close error for backup file (add ! to override)" +msgstr "E507: fout tijdens afsluiten van back-upbestand (voeg ! om toch af te sluiten)" + +#: fileio.c:3997 +msgid "E508: Can't read file for backup (add ! to override)" +msgstr "E508: kan bestand voor back-up niet lezen (voeg ! toe om toch te lezen)" + +#: fileio.c:4016 +msgid "E509: Cannot create backup file (add ! to override)" +msgstr "E509: kan back-upbestand niet aanmaken (voeg ! toe om dit toch aan te maken)" + +#: fileio.c:4118 +msgid "E510: Can't make backup file (add ! to override)" +msgstr "E510: kan back-upbestand niet maken (voeg ! toe om dit toch te maken)" + +#: fileio.c:4180 +msgid "E460: The resource fork would be lost (add ! to override)" +msgstr "E460: de afsplitsing van middelen zou verloren gaan (voeg ! toe om dit toch te doen)" + +#: fileio.c:4289 +msgid "E214: Can't find temp file for writing" +msgstr "E214: kan tijdelijk bestand voor wegschrijven niet vinden" + +#: fileio.c:4307 +msgid "E213: Cannot convert (add ! to write without conversion)" +msgstr "E213: kan niet omzetten (voeg ! toe om zonder omzetting op te slaan)" + +#: fileio.c:4342 +msgid "E166: Can't open linked file for writing" +msgstr "E166: kan niet schrijven naar gekoppeld bestand" + +#: fileio.c:4346 +msgid "E212: Can't open file for writing" +msgstr "E212: kan niet schrijven naar bestand" + +#: fileio.c:4648 +msgid "E667: Fsync failed" +msgstr "E667: fsync is mislukt" + +#: fileio.c:4687 +msgid "E512: Close failed" +msgstr "E512: Afsluiten is mislukt" + +#: fileio.c:4739 +msgid "E513: write error, conversion failed (make 'fenc' empty to override)" +msgstr "E513: schrijffout waarbij omzetting is mislukt (leeg 'fenc' om te overschrijven)" + +#: fileio.c:4744 +#, c-format +msgid "E513: write error, conversion failed in line %ld (make 'fenc' empty to override)" +msgstr "E513: schrijffout waarbij omzetting in regel %ld is mislukt (leeg 'fenc' om te overschrijven)" + +#: fileio.c:4753 +msgid "E514: write error (file system full?)" +msgstr "E514: schrijffout (is bestandssysteem vol?)" + +#: fileio.c:4821 +msgid " CONVERSION ERROR" +msgstr " OMZETTINGFOUT" + +#: fileio.c:4826 +#, c-format +msgid " in line %ld;" +msgstr " in regel %ld;" + +#: fileio.c:4843 +msgid "[Device]" +msgstr "[Apparaat]" + +#: fileio.c:4848 +msgid "[New]" +msgstr "[Nieuw]" + +#: fileio.c:4870 +msgid " [a]" +msgstr " [a]" + +#: fileio.c:4870 +msgid " appended" +msgstr " toegevoegd" + +#: fileio.c:4872 +msgid " [w]" +msgstr " [w]" + +#: fileio.c:4872 +msgid " written" +msgstr " opgeslagen" + +#: fileio.c:4927 +msgid "E205: Patchmode: can't save original file" +msgstr "E205: patch-modus: kan oorspronkelijke bestand niet opslaan" + +#: fileio.c:4950 +msgid "E206: patchmode: can't touch empty original file" +msgstr "E206: patch-modus: kan oorspronkelijk leeg bestand niet aanraken" + +#: fileio.c:4965 +msgid "E207: Can't delete backup file" +msgstr "E207: back-upbestand kan niet worden verwijderd" + +#: fileio.c:5031 +msgid "" +"\n" +"WARNING: Original file may be lost or damaged\n" +msgstr "" +"\n" +"WAARSCHUWING: oorspronkelijk bestand kan verloren gaan of beschadigen\n" + +#: fileio.c:5033 +msgid "don't quit the editor until the file is successfully written!" +msgstr "verlaat vim niet voordat het bestand volledig opgeslagen is!" + +#: fileio.c:5189 +msgid "[dos]" +msgstr "[dos]" + +#: fileio.c:5189 +msgid "[dos format]" +msgstr "[dos-format]" + +#: fileio.c:5196 +msgid "[mac]" +msgstr "[mac]" + +#: fileio.c:5196 +msgid "[mac format]" +msgstr "[mac-format]" + +#: fileio.c:5203 +msgid "[unix]" +msgstr "[unix]" + +#: fileio.c:5203 +msgid "[unix format]" +msgstr "[unix-format]" + +#: fileio.c:5236 +msgid "1 line, " +msgstr "1 regel, " + +#: fileio.c:5238 +#, c-format +msgid "%ld lines, " +msgstr "%ld regels, " + +#: fileio.c:5241 +msgid "1 character" +msgstr "1 teken" + +#: fileio.c:5245 +#, c-format +msgid "%lld characters" +msgstr "%lld tekens" + +#: fileio.c:5247 +#, c-format +msgid "%ld characters" +msgstr "%ld tekens" + +#: fileio.c:5259 +#: netbeans.c:3853 +msgid "[noeol]" +msgstr "[noeol]" + +#: fileio.c:5259 +#: netbeans.c:3854 +msgid "[Incomplete last line]" +msgstr "[Laatste regel onvolledig]" + +#. don't overwrite messages here +#. must give this prompt +#. don't use emsg() here, don't want to flush the buffers +#: fileio.c:5278 +msgid "WARNING: The file has been changed since reading it!!!" +msgstr "WAARSCHUWING: het bestand is na het laden gewijzigd!!!" + +#: fileio.c:5280 +msgid "Do you really want to write to it" +msgstr "Wilt u er zeker naar schrijven" + +#: fileio.c:6639 +#, c-format +msgid "E208: Error writing to \"%s\"" +msgstr "E208: schrijven naar \"%s\" is mislukt" + +#: fileio.c:6646 +#, c-format +msgid "E209: Error closing \"%s\"" +msgstr "E209: afsluiten van \"%s\" is mislukt" + +#: fileio.c:6649 +#, c-format +msgid "E210: Error reading \"%s\"" +msgstr "E210: lezen van \"%s\" is mislukt" + +#: fileio.c:6911 +msgid "E246: FileChangedShell autocommand deleted buffer" +msgstr "E246: buffer verwijderd door 'autocommand' FileChangedShell" + +#: fileio.c:6926 +#, c-format +msgid "E211: File \"%s\" no longer available" +msgstr "E211: bestand \"%s\" is niet meer beschikbaar" + +#: fileio.c:6941 +#, c-format +msgid "W12: Warning: File \"%s\" has changed and the buffer was changed in Vim as well" +msgstr "W12: waarschuwing: bestand \"%s\" en de buffer zijn gewijzigd in Vim " + +#: fileio.c:6942 +msgid "See \":help W12\" for more info." +msgstr "Lees \":help W12\" voor meer informatie." + +#: fileio.c:6946 +#, c-format +msgid "W11: Warning: File \"%s\" has changed since editing started" +msgstr "W11: waarschuwing: bestand \"%s\" is gewijzigd sinds het begin van het bewerken" + +#: fileio.c:6947 +msgid "See \":help W11\" for more info." +msgstr "Lees \":help W11\" voor meer informatie." + +#: fileio.c:6951 +#, c-format +msgid "W16: Warning: Mode of file \"%s\" has changed since editing started" +msgstr "W16: waarschuwing: rechten van bestand \"%s\" zijn gewijzigd sinds het begin van het bewerken" + +#: fileio.c:6952 +msgid "See \":help W16\" for more info." +msgstr "Lees \":help W16\" voor meer informatie" + +#: fileio.c:6967 +#, c-format +msgid "W13: Warning: File \"%s\" has been created after editing started" +msgstr "W13: waarschuwing: na het begin van het bewerken van bestand \"%s\" is deze ook elders aangemaakt" + +#: fileio.c:6997 +msgid "Warning" +msgstr "Waarschuwing" + +#: fileio.c:6998 +msgid "" +"&OK\n" +"&Load File" +msgstr "" +"&OK\n" +"Bestand &Laden" + +#: fileio.c:7121 +#, c-format +msgid "E462: Could not prepare for reloading \"%s\"" +msgstr "E462: het voorbereiden van \"%s\" voor het opnieuw laden is mislukt" + +#: fileio.c:7140 +#, c-format +msgid "E321: Could not reload \"%s\"" +msgstr "E321: kan \"%s\" niet opnieuw laden" + +#: fileio.c:7754 +msgid "--Deleted--" +msgstr "--Verwijderd--" + +#: fileio.c:7907 +#, c-format +msgid "auto-removing autocommand: %s " +msgstr "automatisch verwijderen 'autocommand': %s " + +#. the group doesn't exist +#: fileio.c:7953 +#, c-format +msgid "E367: No such group: \"%s\"" +msgstr "E367: groep \"%s\" bestaat niet" + +#: fileio.c:8100 +#, c-format +msgid "E215: Illegal character after *: %s" +msgstr "E215: ongeldig teken na *: %s" + +#: fileio.c:8112 +#, c-format +msgid "E216: No such event: %s" +msgstr "E216: onbekend 'event': %s" + +#: fileio.c:8114 +#, c-format +msgid "E216: No such group or event: %s" +msgstr "E216: onbekende groep of 'event': %s" + +#. Highlight title +#: fileio.c:8325 +msgid "" +"\n" +"--- Auto-Commands ---" +msgstr "" +"\n" +"--- Auto-Commands ---" + +#: fileio.c:8561 +#, c-format +msgid "E680: : invalid buffer number " +msgstr "E680: : ongeldig buffernummer " + +#: fileio.c:8658 +msgid "E217: Can't execute autocommands for ALL events" +msgstr "E217: autocommands kunnen niet voor alle 'events' worden uitgevoerd" + +#: fileio.c:8681 +msgid "No matching autocommands" +msgstr "Geen overeenkomstige autocommands" + +#: fileio.c:9130 +msgid "E218: autocommand nesting too deep" +msgstr "E218: hierarchie van aanroepen autocommands te diep" + +#: fileio.c:9483 +#, c-format +msgid "%s Auto commands for \"%s\"" +msgstr "%s 'Auto commands' voor \"%s\"" + +#: fileio.c:9493 +#, c-format +msgid "Executing %s" +msgstr "%s uitvoeren" + +#: fileio.c:9562 +#, c-format +msgid "autocommand %s" +msgstr "autocommand %s" + +#: fileio.c:10252 +msgid "E219: Missing {." +msgstr "E219: ontbrekende {." + +#: fileio.c:10254 +msgid "E220: Missing }." +msgstr "E220: ontbrekende }." + +#: fold.c:68 +msgid "E490: No fold found" +msgstr "E490: geen vouw gevonden" + +#: fold.c:593 +msgid "E350: Cannot create fold with current 'foldmethod'" +msgstr "E350: kan geen vouw aanmaken met huidige 'vouwmethode'" + +#: fold.c:595 +msgid "E351: Cannot delete fold with current 'foldmethod'" +msgstr "E351: kan geen vouw verwijderen met huidige 'vouwmethode'" + +#: fold.c:1998 +#, c-format +msgid "+--%3ld lines folded " +msgstr "+--%3ld regels gevouwen " + +#: getchar.c:252 +msgid "E222: Add to read buffer" +msgstr "E222: aan leesbuffer toevoegen" + +#: getchar.c:2418 +msgid "E223: recursive mapping" +msgstr "E223: recursieve toewijzing" + +#: getchar.c:3404 +#, c-format +msgid "E224: global abbreviation already exists for %s" +msgstr "E224: algemene afkorting bestaat al voor %s" + +#: getchar.c:3407 +#, c-format +msgid "E225: global mapping already exists for %s" +msgstr "E225: er bestaat al een algemene toewijzing voor %s" + +#: getchar.c:3539 +#, c-format +msgid "E226: abbreviation already exists for %s" +msgstr "E226: er bestaat al een afkorting voor %s" + +#: getchar.c:3542 +#, c-format +msgid "E227: mapping already exists for %s" +msgstr "E227: toewijzing bestaat al voor %s" + +#: getchar.c:3610 +msgid "No abbreviation found" +msgstr "Geen afkorting gevonden" + +#: getchar.c:3612 +msgid "No mapping found" +msgstr "Geen toewijzing gevonden" + +#: getchar.c:4725 +msgid "E228: makemap: Illegal mode" +msgstr "E228: makemap: ongeldige modus" + +#: gui.c:226 +msgid "E229: Cannot start the GUI" +msgstr "E229: de GUI kan niet worden gestart" + +#: gui.c:361 +#, c-format +msgid "E230: Cannot read from \"%s\"" +msgstr "E230: kan niet gelezen worden uit \"%s\"" + +#: gui.c:487 +msgid "E665: Cannot start GUI, no valid font found" +msgstr "E665: de GUI kan niet gestart worden, er is geen geldig lettertype gevonden" + +#: gui.c:492 +msgid "E231: 'guifontwide' invalid" +msgstr "E231: 'guifontwide' ongeldig" + +#: gui.c:598 +msgid "E599: Value of 'imactivatekey' is invalid" +msgstr "E599: waarde van 'imactivatekey' is ongeldig" + +#: gui.c:4528 +#, c-format +msgid "E254: Cannot allocate color %s" +msgstr "E254: kan de kleur %s niet reserveren" + +#: gui.c:5112 +msgid "No match at cursor, finding next" +msgstr "Op cursorpositie is geen overeenkomst: de volgende zoeken" + +#: gui_at_fs.c:300 +msgid " " +msgstr " " + +#: gui_at_fs.c:1133 +#, c-format +msgid "E616: vim_SelFile: can't get font %s" +msgstr "E616: vim_SelFile: lettertype %s niet gevonden" + +#: gui_at_fs.c:2767 +msgid "E614: vim_SelFile: can't return to current directory" +msgstr "E614: vim_SelFile: teruggaan naar huidige map is niet mogelijk" + +#: gui_at_fs.c:2787 +msgid "Pathname:" +msgstr "Padnaam:" + +#: gui_at_fs.c:2793 +msgid "E615: vim_SelFile: can't get current directory" +msgstr "E615: vim_SelFile: vaststellen huidige map is niet mogelijk" + +#: gui_at_fs.c:2801 +#: gui_xmdlg.c:931 +msgid "OK" +msgstr "Ok" + +#: gui_at_fs.c:2801 +#: gui_gtk.c:2818 +#: gui_xmdlg.c:940 +msgid "Cancel" +msgstr "Annuleren" + +#: gui_at_sb.c:490 +msgid "Scrollbar Widget: Could not get geometry of thumb pixmap." +msgstr "Scrollbar-widget: vaststellen afmetingen van miniaturenkaart niet mogelijk." + +#: gui_athena.c:2160 +#: gui_motif.c:2588 +msgid "Vim dialog" +msgstr "Vim-dialoog" + +#: gui_beval.c:202 +#: gui_w32.c:4740 +msgid "E232: Cannot create BalloonEval with both message and callback" +msgstr "E232: aanmaken 'BalloonEval' met zowel een bericht als een 'callback' is niet mogelijk" + +#: gui_gtk.c:1694 +msgid "Vim dialog..." +msgstr "Vim-dialoog..." + +#: gui_gtk.c:2145 +#: message.c:3654 +msgid "" +"&Yes\n" +"&No\n" +"&Cancel" +msgstr "" +"&Ja\n" +"&Nee\n" +"&Annuleren" + +#: gui_gtk.c:2343 +msgid "Input _Methods" +msgstr "Invoer_wijzen" + +#: gui_gtk.c:2621 +#: gui_motif.c:3761 +msgid "VIM - Search and Replace..." +msgstr "VIM - zoeken en vervangen..." + +#: gui_gtk.c:2629 +#: gui_motif.c:3763 +msgid "VIM - Search..." +msgstr "VIM - zoeken..." + +#: gui_gtk.c:2661 +#: gui_motif.c:3872 +msgid "Find what:" +msgstr "Zoek naar:" + +#: gui_gtk.c:2679 +#: gui_motif.c:3905 +msgid "Replace with:" +msgstr "Vervang door:" + +#. whole word only button +#: gui_gtk.c:2711 +#: gui_motif.c:4026 +msgid "Match whole word only" +msgstr "Alleen volledig woord" + +#. match case button +#: gui_gtk.c:2722 +#: gui_motif.c:4038 +msgid "Match case" +msgstr "Hoofdlettergevoelig" + +#: gui_gtk.c:2732 +#: gui_motif.c:3977 +msgid "Direction" +msgstr "Richting" + +#. 'Up' and 'Down' buttons +#: gui_gtk.c:2744 +#: gui_motif.c:3990 +msgid "Up" +msgstr "Opwaarts" + +#: gui_gtk.c:2748 +#: gui_motif.c:3999 +msgid "Down" +msgstr "Neerwaarts" + +#: gui_gtk.c:2770 +#: gui_gtk.c:2772 +msgid "Find Next" +msgstr "Volgende zoeken" + +#: gui_gtk.c:2789 +#: gui_gtk.c:2791 +msgid "Replace" +msgstr "Vervangen" + +#: gui_gtk.c:2802 +#: gui_gtk.c:2804 +msgid "Replace All" +msgstr "Alles vervangen" + +#: gui_gtk_x11.c:2432 +msgid "Vim: Received \"die\" request from session manager\n" +msgstr "Vim: \"die\"-verzoek van sessiebeheerder ontvangen\n" + +#: gui_gtk_x11.c:3259 +msgid "Close" +msgstr "Sluiten" + +#: gui_gtk_x11.c:3260 +#: gui_w48.c:2374 +msgid "New tab" +msgstr "Nieuw tabblad" + +#: gui_gtk_x11.c:3261 +msgid "Open Tab..." +msgstr "Tabblad openen..." + +#: gui_gtk_x11.c:4092 +msgid "Vim: Main window unexpectedly destroyed\n" +msgstr "Vim: hoofdvenster onverwacht gesloten\n" + +#: gui_gtk_x11.c:4807 +msgid "Font Selection" +msgstr "Lettertypeselectie" + +#: gui_motif.c:2355 +msgid "&Filter" +msgstr "&Filter" + +#: gui_motif.c:2356 +#: gui_motif.c:3840 +msgid "&Cancel" +msgstr "&Annuleren" + +#: gui_motif.c:2357 +msgid "Directories" +msgstr "Mappen" + +#: gui_motif.c:2358 +msgid "Filter" +msgstr "Filter" + +#: gui_motif.c:2359 +msgid "&Help" +msgstr "&Hulp" + +#: gui_motif.c:2360 +msgid "Files" +msgstr "Bestanden" + +#: gui_motif.c:2361 +msgid "&OK" +msgstr "&Ok" + +#: gui_motif.c:2362 +msgid "Selection" +msgstr "Selectie" + +#: gui_motif.c:3792 +msgid "Find &Next" +msgstr "&Volgende zoeken" + +#: gui_motif.c:3807 +msgid "&Replace" +msgstr "Ve&rvangen" + +#: gui_motif.c:3818 +msgid "Replace &All" +msgstr "&Alles vervangen" + +#: gui_motif.c:3829 +msgid "&Undo" +msgstr "&Herstellen" + +#: gui_riscos.c:953 +#, c-format +msgid "E610: Can't load Zap font '%s'" +msgstr "E610: Zap-lettertype '%s' kan niet worden geladen" + +#: gui_riscos.c:1052 +#, c-format +msgid "E611: Can't use font %s" +msgstr "E611: lettertype %s kan niet worden gebruikt" + +#: gui_riscos.c:3282 +msgid "" +"\n" +"Sending message to terminate child process.\n" +msgstr "" +"\n" +"Bericht versturen om kindproces te beëindigen.\n" + +#: gui_w32.c:1178 +#, c-format +msgid "E671: Cannot find window title \"%s\"" +msgstr "E671: kan venstertitel \"%s\" niet vinden" + +#: gui_w32.c:1191 +#, c-format +msgid "E243: Argument not supported: \"-%s\"; Use the OLE version." +msgstr "E243: argument niet ondersteund: \"-%s\"; gebruik de OLE-versie." + +#: gui_w32.c:1432 +msgid "E672: Unable to open window inside MDI application" +msgstr "E672: kan geen venster binnen MDI-applicatie openen" + +#: gui_w48.c:2373 +msgid "Close tab" +msgstr "Tabblad sluiten" + +#: gui_w48.c:2376 +msgid "Open tab..." +msgstr "Tabblad openen..." + +#: gui_w48.c:2632 +msgid "Find string (use '\\\\' to find a '\\')" +msgstr "Tekenreeks zoeken (gebruik '\\\\' om een '\\' te vinden)" + +#: gui_w48.c:2668 +msgid "Find & Replace (use '\\\\' to find a '\\')" +msgstr "Zoeken & vervangen (gebruik '\\\\' om een '\\' te vinden')" + +#. We fake this: Use a filter that doesn't select anything and a default +#. * file name that won't be used. +#: gui_w48.c:3462 +msgid "Not Used" +msgstr "Niet gebruikt" + +#: gui_w48.c:3463 +msgid "Directory\t*.nothing\n" +msgstr "Map\t*.niets\n" + +#: gui_x11.c:1545 +msgid "Vim E458: Cannot allocate colormap entry, some colors may be incorrect" +msgstr "E458: kan geen kleur toewijzen, sommige kleuren kunnen onjuist zijn" + +#: gui_x11.c:2137 +#, c-format +msgid "E250: Fonts for the following charsets are missing in fontset %s:" +msgstr "E250: lettertypen voor de volgende tekenverzamelingen ontbreken in verzameling %s:" + +#: gui_x11.c:2180 +#, c-format +msgid "E252: Fontset name: %s" +msgstr "E252: naam lettertypeverzameling: %s" + +#: gui_x11.c:2181 +#, c-format +msgid "Font '%s' is not fixed-width" +msgstr "Lettertype '%s' heeft geen vaste breedte" + +#: gui_x11.c:2200 +#, c-format +msgid "E253: Fontset name: %s\n" +msgstr "E253: naam lettertypeverzameling: %s\n" + +#: gui_x11.c:2201 +#, c-format +msgid "Font0: %s\n" +msgstr "Font0: %s\n" + +#: gui_x11.c:2202 +#, c-format +msgid "Font1: %s\n" +msgstr "Font1: %s\n" + +#: gui_x11.c:2203 +#, c-format +msgid "Font%ld width is not twice that of font0\n" +msgstr "Breedte font%ld is niet het dubbele van font0\n" + +#: gui_x11.c:2204 +#, c-format +msgid "Font0 width: %ld\n" +msgstr "Font0-breedte: %ld\n" + +#: gui_x11.c:2205 +#, c-format +msgid "" +"Font1 width: %ld\n" +"\n" +msgstr "" +"Font1-breedte: %ld\n" +"\n" + +#: gui_xmdlg.c:690 +#: gui_xmdlg.c:809 +msgid "Invalid font specification" +msgstr "Onjuiste specificatie van lettertype" + +#: gui_xmdlg.c:691 +#: gui_xmdlg.c:810 +msgid "&Dismiss" +msgstr "&Afwijzen" + +#: gui_xmdlg.c:700 +msgid "no specific match" +msgstr "geen specifieke overeenkomst" + +#: gui_xmdlg.c:909 +msgid "Vim - Font Selector" +msgstr "Vim - Lettertypekiezer" + +#: gui_xmdlg.c:978 +msgid "Name:" +msgstr "Naam:" + +#. create toggle button +#: gui_xmdlg.c:1018 +msgid "Show size in Points" +msgstr "Grootte in punten tonen" + +#: gui_xmdlg.c:1037 +msgid "Encoding:" +msgstr "Codering:" + +#: gui_xmdlg.c:1083 +msgid "Font:" +msgstr "Lettertype:" + +#: gui_xmdlg.c:1116 +msgid "Style:" +msgstr "Stijl:" + +#: gui_xmdlg.c:1148 +msgid "Size:" +msgstr "Grootte:" + +#: hangulin.c:610 +msgid "E256: Hangul automata ERROR" +msgstr "E256: 'Hangul automata'-fout" + +#: hardcopy.c:210 +msgid "E550: Missing colon" +msgstr "E550: dubbelepunt ontbreekt" + +#: hardcopy.c:222 +msgid "E551: Illegal component" +msgstr "E551: ongeldige component" + +#: hardcopy.c:230 +msgid "E552: digit expected" +msgstr "E552: cijfer verwacht" + +#: hardcopy.c:501 +#, c-format +msgid "Page %d" +msgstr "Pagina %d" + +#: hardcopy.c:658 +msgid "No text to be printed" +msgstr "Geen tekst om af te drukken" + +#: hardcopy.c:736 +#, c-format +msgid "Printing page %d (%d%%)" +msgstr "Afdrukken van pagina %d (%d%%)" + +#: hardcopy.c:748 +#, c-format +msgid " Copy %d of %d" +msgstr "Kopie %d van %d" + +#: hardcopy.c:806 +#, c-format +msgid "Printed: %s" +msgstr "Afgedrukt: %s" + +#: hardcopy.c:814 +msgid "Printing aborted" +msgstr "Afdrukken afgebroken" + +#: hardcopy.c:1469 +msgid "E455: Error writing to PostScript output file" +msgstr "E455: wegschrijven Postscript-uitvoerbestand is mislukt" + +#: hardcopy.c:1931 +#, c-format +msgid "E624: Can't open file \"%s\"" +msgstr "E624: openen bestand \"%s\" is mislukt" + +#: hardcopy.c:1941 +#: hardcopy.c:2822 +#, c-format +msgid "E457: Can't read PostScript resource file \"%s\"" +msgstr "E457: kan 'Postscript resource'-bestand \"%s\" niet lezen" + +#: hardcopy.c:1957 +#, c-format +msgid "E618: file \"%s\" is not a PostScript resource file" +msgstr "E618L bestand \"%s\" is geen 'Postscript resource'-bestand" + +#: hardcopy.c:1975 +#: hardcopy.c:1994 +#: hardcopy.c:2037 +#, c-format +msgid "E619: file \"%s\" is not a supported PostScript resource file" +msgstr "E619: bestand \"%s\" is geen ondersteund 'Postscript resource'-bestand" + +#: hardcopy.c:2056 +#, c-format +msgid "E621: \"%s\" resource file has wrong version" +msgstr "E621: 'resource'-bestand \"%s\" heeft verkeerde versie" + +#: hardcopy.c:2543 +msgid "E673: Incompatible multi-byte encoding and character set." +msgstr "E673: Multi-byte-codering en de tekenverzameling zijn onverenigbaar." + +#: hardcopy.c:2560 +msgid "E674: printmbcharset cannot be empty with multi-byte encoding." +msgstr "E674: printmbcharset mag bij multi-byte-codering niet leeg zijn." + +#: hardcopy.c:2578 +msgid "E675: No default font specified for multi-byte printing." +msgstr "E675: geen standaard lettertype opgegeven voor multi-byte-afdrukken." + +#: hardcopy.c:2771 +msgid "E324: Can't open PostScript output file" +msgstr "E324: openen van PostScript-uitoverbestand is mislukt" + +#: hardcopy.c:2808 +#, c-format +msgid "E456: Can't open file \"%s\"" +msgstr "E456: Bestand \"%s\" kan niet worden geopend" + +#: hardcopy.c:2942 +msgid "E456: Can't find PostScript resource file \"prolog.ps\"" +msgstr "E456: 'PostScript resource'-bestand \"prolog.ps\" is niet gevonden" + +#: hardcopy.c:2955 +msgid "E456: Can't find PostScript resource file \"cidfont.ps\"" +msgstr "E456: 'PostScript resource'-bestand \"cidfont.ps\" is niet gevonden" + +#: hardcopy.c:2993 +#: hardcopy.c:3015 +#: hardcopy.c:3044 +#, c-format +msgid "E456: Can't find PostScript resource file \"%s.ps\"" +msgstr "E456: 'PostScript resource'-bestand \"%s.ps\" is niet gevonden" + +#: hardcopy.c:3031 +#, c-format +msgid "E620: Unable to convert to print encoding \"%s\"" +msgstr "E620: omzetten naar afdrukcodering \"%s\" is mislukt" + +#: hardcopy.c:3285 +msgid "Sending to printer..." +msgstr "Naar printer versturen..." + +#: hardcopy.c:3289 +msgid "E365: Failed to print PostScript file" +msgstr "E365: Afdrukken van PostScript-bestand is mislukt" + +#: hardcopy.c:3291 +msgid "Print job sent." +msgstr "Afdrukopdracht verzonden" + +#: if_cscope.c:77 +msgid "Add a new database" +msgstr "Nieuwe databank toevoegen" + +#: if_cscope.c:79 +msgid "Query for a pattern" +msgstr "Naar een patroon zoeken" + +#: if_cscope.c:81 +msgid "Show this message" +msgstr "Dit bericht tonen" + +#: if_cscope.c:83 +msgid "Kill a connection" +msgstr "Een verbinding verbreken" + +#: if_cscope.c:85 +msgid "Reinit all connections" +msgstr "Alle verbindingen opnieuw initialiseren" + +#: if_cscope.c:87 +msgid "Show connections" +msgstr "Verbindingen tonen" + +#: if_cscope.c:95 +#, c-format +msgid "E560: Usage: cs[cope] %s" +msgstr "E560: Gebruik: cs[cope] %s" + +#: if_cscope.c:236 +msgid "This cscope command does not support splitting the window.\n" +msgstr "Deze cscope-opdracht ondersteunt niet het splitsen van het venster.\n" + +#: if_cscope.c:287 +msgid "E562: Usage: cstag " +msgstr "E562: Gebruik: cstag " + +#: if_cscope.c:345 +msgid "E257: cstag: tag not found" +msgstr "E257: cstag: tag is gevonden" + +#: if_cscope.c:515 +#, c-format +msgid "E563: stat(%s) error: %d" +msgstr "E563: bevraag((%s) fout: %d" + +#: if_cscope.c:525 +msgid "E563: stat error" +msgstr "E563: bevragingsfout" + +#: if_cscope.c:622 +#, c-format +msgid "E564: %s is not a directory or a valid cscope database" +msgstr "E564: %s is geen map of een geldige cscope-databank" + +#: if_cscope.c:640 +#, c-format +msgid "Added cscope database %s" +msgstr "cscope-databank %s toegevoegd" + +#: if_cscope.c:695 +#, c-format +msgid "E262: error reading cscope connection %ld" +msgstr "E262: lezen van cscope-verbinding %ld is mislukt" + +#: if_cscope.c:802 +msgid "E561: unknown cscope search type" +msgstr "E561: soort cscope-zoekopdracht is onbekend" + +#: if_cscope.c:866 +#: if_cscope.c:905 +msgid "E566: Could not create cscope pipes" +msgstr "E566: aanmaken cscopei-pijp is mislukt" + +#: if_cscope.c:882 +msgid "E622: Could not fork for cscope" +msgstr "E622: nieuw cscope-proces beginnen is mislukt" + +#: if_cscope.c:992 +#: if_cscope.c:1029 +msgid "cs_create_connection exec failed" +msgstr "uitvoering cs_create_connection is mislukt" + +#: if_cscope.c:1002 +#: if_cscope.c:1042 +msgid "cs_create_connection: fdopen for to_fp failed" +msgstr "cs_create_connection: fdopen voor to_fp is mislukt" + +#: if_cscope.c:1004 +#: if_cscope.c:1046 +msgid "cs_create_connection: fdopen for fr_fp failed" +msgstr "cs_create_connection: fdopen voor fr_fp is mislukt" + +#: if_cscope.c:1030 +msgid "E623: Could not spawn cscope process" +msgstr "E623: voortbrengen cscope-proces is mislukt" + +#: if_cscope.c:1074 +msgid "E567: no cscope connections" +msgstr "E567: geen cscope-verbindingen" + +#: if_cscope.c:1155 +#, c-format +msgid "E469: invalid cscopequickfix flag %c for %c" +msgstr "E469: cscopequickfix-vlag %c voor %c is ongeldig" + +#: if_cscope.c:1218 +#, c-format +msgid "E259: no matches found for cscope query %s of %s" +msgstr "E259: cscope-zoekopdracht %s van %s leverde geen resultaten" + +#: if_cscope.c:1324 +msgid "cscope commands:\n" +msgstr "cscope-opdrachten:\n" + +#: if_cscope.c:1333 +#, c-format +msgid "%-5s: %s%*s (Usage: %s)" +msgstr "%-5s: %s%*s (Gebruik: %s)" + +#: if_cscope.c:1338 +msgid "" +"\n" +" c: Find functions calling this function\n" +" d: Find functions called by this function\n" +" e: Find this egrep pattern\n" +" f: Find this file\n" +" g: Find this definition\n" +" i: Find files #including this file\n" +" s: Find this C symbol\n" +" t: Find assignments to\n" +msgstr "" +"\n" +" c: zoek functies die deze functie aanroepen\n" +" d: zoek functies die door deze functie worden aangeroepen\n" +" e: zoek op dit egrep-patroon\n" +" f: zoek dit bestand\n" +" g: zoek deze definitie\n" +" i: zoek bestanden #inclusief dit bestand\n" +" s: zoek dit C-symbool\n" +" t: zoek toekenningen aan\n" + +#: if_cscope.c:1426 +#, c-format +msgid "E625: cannot open cscope database: %s" +msgstr "E625: openen is mislukt van cscope-databank: %s" + +#: if_cscope.c:1444 +msgid "E626: cannot get cscope database information" +msgstr "E626: opvragen cscope-databankinformatie is mislukt" + +#: if_cscope.c:1469 +msgid "E568: duplicate cscope database not added" +msgstr "E568: dubbele cscope-databank is niet toegevoegd" + +#: if_cscope.c:1614 +#, c-format +msgid "E261: cscope connection %s not found" +msgstr "E261: cscope-verbinding %s is niet gevonden" + +#: if_cscope.c:1648 +#, c-format +msgid "cscope connection %s closed" +msgstr "cscope-verbinding %s is verbroken" + +#. should not reach here +#: if_cscope.c:1788 +msgid "E570: fatal error in cs_manage_matches" +msgstr "E570: fatale fout in cs_manage_matches" + +#: if_cscope.c:2050 +#, c-format +msgid "Cscope tag: %s" +msgstr "Cscope-tag: %s" + +#: if_cscope.c:2072 +msgid "" +"\n" +" # line" +msgstr "" +"\n" +" # regel" + +#: if_cscope.c:2074 +msgid "filename / context / line\n" +msgstr "bestandsnaam / context / regel\n" + +#: if_cscope.c:2186 +#, c-format +msgid "E609: Cscope error: %s" +msgstr "E609: Cscope-fout: %s" + +#: if_cscope.c:2459 +msgid "All cscope databases reset" +msgstr "Alle cscope-databanken opnieuw ingesteld" + +#: if_cscope.c:2526 +msgid "no cscope connections\n" +msgstr "geen cscope-verbindingen\n" + +#: if_cscope.c:2530 +msgid " # pid database name prepend path\n" +msgstr " # pid databanknaam padvoorvoegsel\n" + +#: if_mzsch.c:1038 +msgid "E815: Sorry, this command is disabled, the MzScheme libraries could not be loaded." +msgstr "E815: helaas, deze opdracht is uitgeschakeld. De MzScheme-bibliotheken kunnen niet geladen worden." + +#: if_mzsch.c:1425 +#: if_python.c:1271 +#: if_tcl.c:1404 +msgid "invalid expression" +msgstr "ongeldige uitdrukking" + +#: if_mzsch.c:1433 +#: if_python.c:1290 +#: if_tcl.c:1409 +msgid "expressions disabled at compile time" +msgstr "tijdens compileren zijn de expressies uitgeschakeld" + +#: if_mzsch.c:1522 +msgid "hidden option" +msgstr "verborgen optie" + +#: if_mzsch.c:1524 +#: if_tcl.c:501 +msgid "unknown option" +msgstr "onbekende optie" + +#: if_mzsch.c:1683 +msgid "window index is out of range" +msgstr "vensterindex valt buiten het bereik" + +#: if_mzsch.c:1843 +msgid "couldn't open buffer" +msgstr "buffer openen is mislukt" + +#: if_mzsch.c:2123 +#: if_mzsch.c:2153 +#: if_mzsch.c:2250 +#: if_mzsch.c:2314 +#: if_mzsch.c:2435 +#: if_mzsch.c:2492 +#: if_python.c:2508 +#: if_python.c:2542 +#: if_python.c:2601 +#: if_python.c:2668 +#: if_python.c:2790 +#: if_python.c:2842 +#: if_tcl.c:684 +#: if_tcl.c:729 +#: if_tcl.c:803 +#: if_tcl.c:875 +#: if_tcl.c:2017 +msgid "cannot save undo information" +msgstr "herstelinformatie kan niet worden opgeslagen" + +#: if_mzsch.c:2128 +#: if_mzsch.c:2258 +#: if_mzsch.c:2328 +#: if_python.c:2510 +#: if_python.c:2608 +#: if_python.c:2679 +msgid "cannot delete line" +msgstr "regel kan niet worden verwijderd" + +#: if_mzsch.c:2159 +#: if_mzsch.c:2343 +#: if_python.c:2547 +#: if_python.c:2695 +#: if_tcl.c:690 +#: if_tcl.c:2039 +msgid "cannot replace line" +msgstr "regel kan niet worden vervangen" + +#: if_mzsch.c:2358 +#: if_mzsch.c:2441 +#: if_mzsch.c:2502 +#: if_python.c:2713 +#: if_python.c:2792 +#: if_python.c:2850 +msgid "cannot insert line" +msgstr "regel kan niet worden ingevoegd" + +#: if_mzsch.c:2593 +#: if_python.c:2962 +msgid "string cannot contain newlines" +msgstr "tekenreeks kan geen regeleinden bevatten" + +#: if_mzsch.c:3034 +msgid "Vim error: ~a" +msgstr "Vim-fout: ~a" + +#: if_mzsch.c:3067 +msgid "Vim error" +msgstr "Vim-fout" + +#: if_mzsch.c:3133 +msgid "buffer is invalid" +msgstr "buffer is ongeldig" + +#: if_mzsch.c:3142 +msgid "window is invalid" +msgstr "venster is ongeldig" + +#: if_mzsch.c:3162 +msgid "linenr out of range" +msgstr "regelnummer buiten het bereik" + +#: if_mzsch.c:3313 +#: if_mzsch.c:3355 +msgid "not allowed in the Vim sandbox" +msgstr "niet toegestaan in de Vim-zandbak" + +#: if_python.c:517 +msgid "E263: Sorry, this command is disabled, the Python library could not be loaded." +msgstr "E263: helaas, deze opdracht is uitgeschakeld. De Python-bibliotheek kan niet worden geladen." + +#: if_python.c:583 +msgid "E659: Cannot invoke Python recursively" +msgstr "E659: Python kan niet recursief worden aangeroepen" + +#: if_python.c:776 +msgid "can't delete OutputObject attributes" +msgstr "attributen van OutputObject kunnen niet worden verwijderd" + +#: if_python.c:783 +msgid "softspace must be an integer" +msgstr "zachte spatie moet een geheel getal zijn" + +#: if_python.c:791 +msgid "invalid attribute" +msgstr "ongeldig attribuut" + +#: if_python.c:830 +#: if_python.c:844 +msgid "writelines() requires list of strings" +msgstr "writelines() vereist een lijst met tekenreeksen" + +#: if_python.c:970 +msgid "E264: Python: Error initialising I/O objects" +msgstr "E264: Python: initialiseren I/O-objecten is mislukt" + +#: if_python.c:1303 +msgid "attempt to refer to deleted buffer" +msgstr "poging om naar een verwijderd buffer te verwijzen" + +#: if_python.c:1318 +#: if_python.c:1359 +#: if_python.c:1423 +#: if_tcl.c:1216 +msgid "line number out of range" +msgstr "regelnummer valt buiten het bereik" + +#: if_python.c:1558 +#, c-format +msgid "" +msgstr "" + +#: if_python.c:1649 +#: if_tcl.c:836 +msgid "invalid mark name" +msgstr "naam markering ongeldig" + +#: if_python.c:1927 +msgid "no such buffer" +msgstr "onbekende buffer" + +#: if_python.c:2015 +msgid "attempt to refer to deleted window" +msgstr "poging om naar een verwijderd venster te verwijzen" + +#: if_python.c:2060 +msgid "readonly attribute" +msgstr "alleen-lezen attribuut" + +#: if_python.c:2074 +msgid "cursor position outside buffer" +msgstr "cursorpositie valt buiten buffer" + +#: if_python.c:2157 +#, c-format +msgid "" +msgstr "" + +#: if_python.c:2169 +#, c-format +msgid "" +msgstr "" + +#: if_python.c:2172 +#, c-format +msgid "" +msgstr "" + +#: if_python.c:2246 +msgid "no such window" +msgstr "onbekend venster" + +#: if_ruby.c:554 +msgid "E265: $_ must be an instance of String" +msgstr "E265: $_ moet een instantie van String zijn" + +#: if_ruby.c:630 +msgid "E266: Sorry, this command is disabled, the Ruby library could not be loaded." +msgstr "E266: helaas, deze opdracht is uitgeschakeld. De Ruby-bibliotheek kan niet worden geladen." + +#: if_ruby.c:662 +msgid "E267: unexpected return" +msgstr "E267: onverwacht resultaat" + +#: if_ruby.c:665 +msgid "E268: unexpected next" +msgstr "E268: onverwachte volgende" + +#: if_ruby.c:668 +msgid "E269: unexpected break" +msgstr "E269: onverwachte onderbreking" + +#: if_ruby.c:671 +msgid "E270: unexpected redo" +msgstr "E270: onverwachte herstelopdracht" + +#: if_ruby.c:674 +msgid "E271: retry outside of rescue clause" +msgstr "E271: hernieuwde poging buiten de reddingsclausule" + +#: if_ruby.c:686 +msgid "E272: unhandled exception" +msgstr "E272: niet-afgehandelde uitzondering" + +#: if_ruby.c:701 +#, c-format +msgid "E273: unknown longjmp status %d" +msgstr "E273: onbekende longjmp-status %d" + +#: if_sniff.c:64 +msgid "Toggle implementation/definition" +msgstr "Implementatie/definitie wisselen" + +#: if_sniff.c:65 +msgid "Show base class of" +msgstr "Toon basisklasse van" + +#: if_sniff.c:66 +msgid "Show overridden member function" +msgstr "Toon overschreven member-functie" + +#: if_sniff.c:67 +msgid "Retrieve from file" +msgstr "Uit bestand halen" + +#: if_sniff.c:68 +msgid "Retrieve from project" +msgstr "Uit project halen" + +#: if_sniff.c:70 +msgid "Retrieve from all projects" +msgstr "Uit alle projecten halen" + +#: if_sniff.c:71 +msgid "Retrieve" +msgstr "Ophalen" + +#: if_sniff.c:72 +msgid "Show source of" +msgstr "Toon broncode van" + +#: if_sniff.c:73 +msgid "Find symbol" +msgstr "Zoek symbool" + +#: if_sniff.c:74 +msgid "Browse class" +msgstr "Bekijk klasse" + +#: if_sniff.c:75 +msgid "Show class in hierarchy" +msgstr "Toon klasse in hierarchie" + +#: if_sniff.c:76 +msgid "Show class in restricted hierarchy" +msgstr "Toon klasse in beperkte hierarchie" + +#: if_sniff.c:77 +msgid "Xref refers to" +msgstr "Xref verwijst naar" + +#: if_sniff.c:78 +msgid "Xref referred by" +msgstr "Xref wordt naar verwezen door" + +#: if_sniff.c:79 +msgid "Xref has a" +msgstr "Xref heeft een" + +#: if_sniff.c:80 +msgid "Xref used by" +msgstr "Xref gebruikt door" + +#: if_sniff.c:81 +msgid "Show docu of" +msgstr "Toon documentatie van" + +#: if_sniff.c:82 +msgid "Generate docu for" +msgstr "Genereer documentatie voor" + +#: if_sniff.c:94 +msgid "Cannot connect to SNiFF+. Check environment (sniffemacs must be found in $PATH).\n" +msgstr "Verbinden met SNiFF+ is mislukt. Controleer omgevingsvariabelen (sniffemacs moet in $PATH staan).\n" + +#: if_sniff.c:422 +msgid "E274: Sniff: Error during read. Disconnected" +msgstr "E274: Sniff: leesfout. Verbroken" + +#: if_sniff.c:550 +msgid "SNiFF+ is currently " +msgstr "SNiFF+ is momenteel " + +#: if_sniff.c:552 +msgid "not " +msgstr "niet " + +#: if_sniff.c:553 +msgid "connected" +msgstr "verbonden" + +#: if_sniff.c:589 +#, c-format +msgid "E275: Unknown SNiFF+ request: %s" +msgstr "E275: onbekend SNiFF+-verzoek: %s" + +#: if_sniff.c:602 +msgid "E276: Error connecting to SNiFF+" +msgstr "E276: verbinden met SNiFF+ is mislukt" + +#: if_sniff.c:1013 +msgid "E278: SNiFF+ not connected" +msgstr "E278: SNiFF+ niet verbonden" + +#: if_sniff.c:1022 +msgid "E279: Not a SNiFF+ buffer" +msgstr "E279: geen SNiFF+-buffer" + +#: if_sniff.c:1089 +msgid "Sniff: Error during write. Disconnected" +msgstr "Sniff: schrijven is mislukt. Verbroken" + +#: if_tcl.c:419 +msgid "invalid buffer number" +msgstr "buffernummer is ongeldig" + +#: if_tcl.c:465 +#: if_tcl.c:935 +#: if_tcl.c:1115 +msgid "not implemented yet" +msgstr "nog niet geïmplementeerd" + +#. ??? +#: if_tcl.c:774 +msgid "cannot set line(s)" +msgstr "kan regel(s) niet instellen" + +#: if_tcl.c:845 +msgid "mark not set" +msgstr "markering niet ingesteld" + +#: if_tcl.c:852 +#: if_tcl.c:1071 +#, c-format +msgid "row %d column %d" +msgstr "rij %d kolom %d" + +#: if_tcl.c:884 +msgid "cannot insert/append line" +msgstr "invoegen/toevoegen regel is mislukt" + +#: if_tcl.c:1270 +msgid "unknown flag: " +msgstr "unbekende instelling: " + +#: if_tcl.c:1340 +msgid "unknown vimOption" +msgstr "onbekende vim-optie" + +#: if_tcl.c:1425 +msgid "keyboard interrupt" +msgstr "toetsenbord-interrupt" + +#: if_tcl.c:1430 +msgid "vim error" +msgstr "vim-fout" + +#: if_tcl.c:1474 +msgid "cannot create buffer/window command: object is being deleted" +msgstr "aanmaken buffer-/vensteropdracht is mislukt: object wordt verwijderd" + +#: if_tcl.c:1550 +msgid "cannot register callback command: buffer/window is already being deleted" +msgstr " kan 'callback'-opdracht niet registreren: buffer/venster is reeds verwijderd" + +#. This should never happen. Famous last word? +#: if_tcl.c:1569 +msgid "E280: TCL FATAL ERROR: reflist corrupt!? Please report this to vim-dev@vim.org" +msgstr "E280: TCL FATALE FOUT: reflist misschien corrupt!? Meld dit a.u.b. aan vim-dev@vim.org" + +#: if_tcl.c:1570 +msgid "cannot register callback command: buffer/window reference not found" +msgstr "'callback'-opdracht kan niet worden geregistreerd: buffer-/vensterreferentie ontbreekt" + +#: if_tcl.c:1742 +msgid "E571: Sorry, this command is disabled: the Tcl library could not be loaded." +msgstr "E571: Helaas, deze opdracht is uitgeschakeld: het laden van de Tcl-bibliotheek is mislukt." + +#: if_tcl.c:1904 +msgid "E281: TCL ERROR: exit code is not int!? Please report this to vim-dev@vim.org" +msgstr "E281: Tcl-fout: afsluitcode is geen geheel getal!? Meld dit a.u.b. aan vim-dev@vim.org" + +#: if_tcl.c:1909 +#, c-format +msgid "E572: exit code %d" +msgstr "E572: afsluitcode %d" + +#: if_tcl.c:2025 +msgid "cannot get line" +msgstr "kan regel niet verkrijgen" + +#: if_xcmdsrv.c:218 +msgid "Unable to register a command server name" +msgstr "Het registreren van een opdrachtservernaam is mislukt" + +#: if_xcmdsrv.c:477 +msgid "E248: Failed to send command to the destination program" +msgstr "E248: versturen van opdracht naar het doelprogramma is mislukt" + +#: if_xcmdsrv.c:750 +#, c-format +msgid "E573: Invalid server id used: %s" +msgstr "E573: ongeldige server-id gebruikt: %s" + +#: if_xcmdsrv.c:1131 +msgid "E251: VIM instance registry property is badly formed. Deleted!" +msgstr "E251: registereigenschap van VIM-instantie is misvormd. Verwijderd!" + +#: main.c:138 +msgid "Unknown option argument" +msgstr "Onbekend optieargument" + +#: main.c:140 +msgid "Too many edit arguments" +msgstr "Teveel bewerkargumenten" + +#: main.c:142 +msgid "Argument missing after" +msgstr "Argument ontbreekt na" + +#: main.c:144 +msgid "Garbage after option argument" +msgstr "Rommel na optieargument" + +#: main.c:146 +msgid "Too many \"+command\", \"-c command\" or \"--cmd command\" arguments" +msgstr "Teveel \"+opdracht\", \"-c opdracht\" of \"--cmd opdracht\"-argumenten" + +#: main.c:148 +msgid "Invalid argument for" +msgstr "Ongeldig argument voor" + +#: main.c:517 +#, c-format +msgid "%d files to edit\n" +msgstr "%d bestanden om te bewerken\n" + +#: main.c:942 +msgid "netbeans is not supported with this GUI\n" +msgstr "Netbeans wordt door deze GUI niet ondersteund\n" + +#: main.c:1531 +msgid "This Vim was not compiled with the diff feature." +msgstr "Deze Vim is niet met de diff-functionaliteit gecompileerd" + +#: main.c:1633 +msgid "'-nb' cannot be used: not enabled at compile time\n" +msgstr "'-nb' kan niet worden gebruikt: was tijdens compilatie niet ingeschakeld\n" + +#: main.c:2165 +msgid "Attempt to open script file again: \"" +msgstr "Poging scriptbestand wederom te openen: \"" + +#: main.c:2174 +msgid "Cannot open for reading: \"" +msgstr "Openen om te lezen is mislukt: \"" + +#: main.c:2228 +msgid "Cannot open for script output: \"" +msgstr "Openen voor script-uitvoer is mislukt: \"" + +#: main.c:2394 +msgid "Vim: Error: Failure to start gvim from NetBeans\n" +msgstr "Vim: Fout: gvim starten vanuit Netbeans is mislukt\n" + +#: main.c:2399 +msgid "Vim: Warning: Output is not to a terminal\n" +msgstr "Vim: Waarschuwing: Uitvoer gaan niet naar een terminal\n" + +#: main.c:2401 +msgid "Vim: Warning: Input is not from a terminal\n" +msgstr "Vim: Waarschuwing: Invoer komt niet van een terminal\n" + +#. just in case.. +#: main.c:2718 +msgid "pre-vimrc command line" +msgstr "pre-vimrc-opdracjtregel" + +#: main.c:2815 +#, c-format +msgid "E282: Cannot read from \"%s\"" +msgstr "E282: Kan niet lezen vanuit \"%s\"" + +#: main.c:3032 +msgid "" +"\n" +"More info with: \"vim -h\"\n" +msgstr "" +"\n" +"Meer informatie via: \"vim -h\"\n" + +#: main.c:3065 +msgid "[file ..] edit specified file(s)" +msgstr "[bestand ..] bewerk opgegeven bestand(en)" + +#: main.c:3066 +msgid "- read text from stdin" +msgstr "- lees tekst vanuit stdin" + +#: main.c:3067 +msgid "-t tag edit file where tag is defined" +msgstr "-t tag bewerk bestand waar tag is gedefinieerd" + +#: main.c:3069 +msgid "-q [errorfile] edit file with first error" +msgstr "-q [foutbestand] bewerk bestand dat eerste fout bevat" + +#: main.c:3078 +msgid "" +"\n" +"\n" +"usage:" +msgstr "" +"\n" +"\n" +"Gebruik:" + +#: main.c:3081 +msgid " vim [arguments] " +msgstr " vim [argumenten] " + +#: main.c:3085 +msgid "" +"\n" +" or:" +msgstr "" +"\n" +" of:" + +#: main.c:3088 +msgid "" +"\n" +"Where case is ignored prepend / to make flag upper case" +msgstr "" +"\n" +"Daar waar hoofdletters genegeerd worden kan met / vlag in hoofdletters gezet worden" + +#: main.c:3091 +msgid "" +"\n" +"\n" +"Arguments:\n" +msgstr "" +"\n" +"\n" +"Argumenten:\n" + +#: main.c:3092 +msgid "--\t\t\tOnly file names after this" +msgstr "--\t\t\tHierna alleen bestandsnamen" + +#: main.c:3094 +msgid "--literal\t\tDon't expand wildcards" +msgstr "--literal\t\tJokertekens niet vervangen" + +#: main.c:3097 +msgid "-register\t\tRegister this gvim for OLE" +msgstr "-register\t\tDeze gvim voor OLE registreren" + +#: main.c:3098 +msgid "-unregister\t\tUnregister gvim for OLE" +msgstr "-unregister\t\tgvim afmelden voor OLE" + +#: main.c:3101 +msgid "-g\t\t\tRun using GUI (like \"gvim\")" +msgstr "-g\t\t\tMet GUI opstarten (zoals \"gvim\")" + +#: main.c:3102 +msgid "-f or --nofork\tForeground: Don't fork when starting GUI" +msgstr "-f of --nofork\tVoorgrond: niet afsplitsen tijdens opstarten GUI" + +#: main.c:3104 +msgid "-v\t\t\tVi mode (like \"vi\")" +msgstr "-v\t\t\tVi-modus (zoals \"vi\")" + +#: main.c:3105 +msgid "-e\t\t\tEx mode (like \"ex\")" +msgstr "-e\t\t\tEx-modus (zoals \"ex\")" + +#: main.c:3106 +msgid "-s\t\t\tSilent (batch) mode (only for \"ex\")" +msgstr "-s\t\t\tStille (bulk)modus (alleen bij \"ex\")" + +#: main.c:3108 +msgid "-d\t\t\tDiff mode (like \"vimdiff\")" +msgstr "-d\t\t\tDiff-modus (zoals \"vimdiff\")" + +#: main.c:3110 +msgid "-y\t\t\tEasy mode (like \"evim\", modeless)" +msgstr "-y\t\t\tEenvoudige modus (zoals \"evim\", zonder modus)" + +#: main.c:3111 +msgid "-R\t\t\tReadonly mode (like \"view\")" +msgstr "-R\t\t\tAlleen-lezen modus (zoals \"view\")" + +#: main.c:3112 +msgid "-Z\t\t\tRestricted mode (like \"rvim\")" +msgstr "-Z\t\t\tBeperkte modus (zoals \"rvim\")" + +#: main.c:3113 +msgid "-m\t\t\tModifications (writing files) not allowed" +msgstr "-m\t\t\tAanpassingen (bestanden opslaan) niet toegestaan" + +#: main.c:3114 +msgid "-M\t\t\tModifications in text not allowed" +msgstr "-M\t\t\tTekstuele aanpassingen niet toegestaan" + +#: main.c:3115 +msgid "-b\t\t\tBinary mode" +msgstr "-b\t\t\tBinaire modus" + +#: main.c:3117 +msgid "-l\t\t\tLisp mode" +msgstr "-l\t\t\tLisp-modus" + +#: main.c:3119 +msgid "-C\t\t\tCompatible with Vi: 'compatible'" +msgstr "-C\t\t\tUitwisselbaar met Vi: 'compatible'" + +#: main.c:3120 +msgid "-N\t\t\tNot fully Vi compatible: 'nocompatible'" +msgstr "-N\t\t\tNiet volledig met Vi uitwisselbaar: 'nocompatible'" + +#: main.c:3121 +msgid "-V[N][fname]\t\tBe verbose [level N] [log messages to fname]" +msgstr "-V[N][fname]\t\tWees uitbundig [niveau N] [schrijf berichten naar fname]" + +#: main.c:3123 +msgid "-D\t\t\tDebugging mode" +msgstr "-D\t\t\tFoutopspoormodus" + +#: main.c:3125 +msgid "-n\t\t\tNo swap file, use memory only" +msgstr "-n\t\t\tGeen wisselbestand, alleen geheugen gebruiken" + +#: main.c:3126 +msgid "-r\t\t\tList swap files and exit" +msgstr "-r\t\t\tWisselbestanden tonen en stoppen" + +#: main.c:3127 +msgid "-r (with file name)\tRecover crashed session" +msgstr "-r (bestandsnaam)\tHerstel ontspoorde sessie" + +#: main.c:3128 +msgid "-L\t\t\tSame as -r" +msgstr "-L\t\t\tGelijk aan -r" + +#: main.c:3130 +msgid "-f\t\t\tDon't use newcli to open window" +msgstr "-f\t\t\tGebruik geen newcli om venster te openen" + +#: main.c:3131 +msgid "-dev \t\tUse for I/O" +msgstr "-dev \t\tGebruik voor in- en uitvoer" + +#: main.c:3134 +msgid "-A\t\t\tstart in Arabic mode" +msgstr "-A\t\t\tIn Arabische modus starten" + +#: main.c:3137 +msgid "-H\t\t\tStart in Hebrew mode" +msgstr "-H\t\t\tIn Hebrewsche modus starten" + +#: main.c:3140 +msgid "-F\t\t\tStart in Farsi mode" +msgstr "-F\t\t\tIn Perzische modus starten" + +#: main.c:3142 +msgid "-T \tSet terminal type to " +msgstr "-T \tTerminalsoort op instellen" + +#: main.c:3143 +msgid "-u \t\tUse instead of any .vimrc" +msgstr "-u \t\tGebruik in plaats van enige .vimrc" + +#: main.c:3145 +msgid "-U \t\tUse instead of any .gvimrc" +msgstr "-U \t\tGebruik in plaats van enige .gvimrc" + +#: main.c:3147 +msgid "--noplugin\t\tDon't load plugin scripts" +msgstr "--noplugin\t\tGeen plugin-scripts laden" + +#: main.c:3149 +msgid "-p[N]\t\tOpen N tab pages (default: one for each file)" +msgstr "-p[N]\t\tN tabpagina's openen (standaard: 1 per bestand)" + +#: main.c:3150 +msgid "-o[N]\t\tOpen N windows (default: one for each file)" +msgstr "-o[N]\t\tN vensters openen (standaard: 1 per bestand)" + +#: main.c:3151 +msgid "-O[N]\t\tLike -o but split vertically" +msgstr "-O[N]\t\tGelijk aan -o maar vertikaal gesplitst" + +#: main.c:3153 +msgid "+\t\t\tStart at end of file" +msgstr "+\t\t\tAan einde van bestand beginnen" + +#: main.c:3154 +msgid "+\t\tStart at line " +msgstr "+\t\tOp regel beginnen" + +#: main.c:3155 +msgid "--cmd \tExecute before loading any vimrc file" +msgstr "--cmd \tOpdracht uitvoeren voor enige vimrc-bestand" + +#: main.c:3156 +msgid "-c \t\tExecute after loading the first file" +msgstr "-c \t\tOpdracht uitvoeren na eerste bestand" + +#: main.c:3157 +msgid "-S \t\tSource file after loading the first file" +msgstr "" + +#: main.c:3158 +msgid "-s \tRead Normal mode commands from file " +msgstr "" + +#: main.c:3159 +msgid "-w \tAppend all typed commands to file " +msgstr "" + +#: main.c:3160 +msgid "-W \tWrite all typed commands to file " +msgstr "" + +#: main.c:3162 +msgid "-x\t\t\tEdit encrypted files" +msgstr "" + +#: main.c:3166 +msgid "-display \tConnect vim to this particular X-server" +msgstr "" + +#: main.c:3168 +msgid "-X\t\t\tDo not connect to X server" +msgstr "" + +#: main.c:3171 +msgid "--remote \tEdit in a Vim server if possible" +msgstr "" + +#: main.c:3172 +msgid "--remote-silent Same, don't complain if there is no server" +msgstr "" + +#: main.c:3173 +msgid "--remote-wait As --remote but wait for files to have been edited" +msgstr "" + +#: main.c:3174 +msgid "--remote-wait-silent Same, don't complain if there is no server" +msgstr "" + +#: main.c:3176 +msgid "--remote-tab[-wait][-silent] As --remote but use tab page per file" +msgstr "" + +#: main.c:3178 +msgid "--remote-send \tSend to a Vim server and exit" +msgstr "" + +#: main.c:3179 +msgid "--remote-expr \tEvaluate in a Vim server and print result" +msgstr "" + +#: main.c:3180 +msgid "--serverlist\t\tList available Vim server names and exit" +msgstr "" + +#: main.c:3181 +msgid "--servername \tSend to/become the Vim server " +msgstr "" + +#: main.c:3184 +msgid "--startuptime \tWrite startup timing messages to " +msgstr "" + +#: main.c:3187 +msgid "-i \t\tUse instead of .viminfo" +msgstr "" + +#: main.c:3189 +msgid "-h or --help\tPrint Help (this message) and exit" +msgstr "-h of --help\tDit bericht tonen en stoppen" + +#: main.c:3190 +msgid "--version\t\tPrint version information and exit" +msgstr "--version\t\tVersieinformatie tonen en stoppen" + +#: main.c:3194 +msgid "" +"\n" +"Arguments recognised by gvim (Motif version):\n" +msgstr "" + +#: main.c:3198 +msgid "" +"\n" +"Arguments recognised by gvim (neXtaw version):\n" +msgstr "" + +#: main.c:3200 +msgid "" +"\n" +"Arguments recognised by gvim (Athena version):\n" +msgstr "" + +#: main.c:3204 +msgid "-display \tRun vim on " +msgstr "" + +#: main.c:3205 +msgid "-iconic\t\tStart vim iconified" +msgstr "" + +#: main.c:3207 +msgid "-name \t\tUse resource as if vim was " +msgstr "" + +#: main.c:3208 +msgid "\t\t\t (Unimplemented)\n" +msgstr "" + +#: main.c:3210 +msgid "-background \tUse for the background (also: -bg)" +msgstr "" + +#: main.c:3211 +msgid "-foreground \tUse for normal text (also: -fg)" +msgstr "" + +#: main.c:3212 +#: main.c:3232 +msgid "-font \t\tUse for normal text (also: -fn)" +msgstr "" + +#: main.c:3213 +msgid "-boldfont \tUse for bold text" +msgstr "" + +#: main.c:3214 +msgid "-italicfont \tUse for italic text" +msgstr "" + +#: main.c:3215 +#: main.c:3233 +msgid "-geometry \tUse for initial geometry (also: -geom)" +msgstr "" + +#: main.c:3216 +msgid "-borderwidth \tUse a border width of (also: -bw)" +msgstr "" + +#: main.c:3217 +msgid "-scrollbarwidth Use a scrollbar width of (also: -sw)" +msgstr "" + +#: main.c:3219 +msgid "-menuheight \tUse a menu bar height of (also: -mh)" +msgstr "" + +#: main.c:3221 +#: main.c:3234 +msgid "-reverse\t\tUse reverse video (also: -rv)" +msgstr "" + +#: main.c:3222 +msgid "+reverse\t\tDon't use reverse video (also: +rv)" +msgstr "" + +#: main.c:3223 +msgid "-xrm \tSet the specified resource" +msgstr "" + +#: main.c:3226 +msgid "" +"\n" +"Arguments recognised by gvim (RISC OS version):\n" +msgstr "" + +#: main.c:3227 +msgid "--columns \tInitial width of window in columns" +msgstr "" + +#: main.c:3228 +msgid "--rows \tInitial height of window in rows" +msgstr "" + +#: main.c:3231 +msgid "" +"\n" +"Arguments recognised by gvim (GTK+ version):\n" +msgstr "" + +#: main.c:3235 +msgid "-display \tRun vim on (also: --display)" +msgstr "" + +#: main.c:3237 +msgid "--role \tSet a unique role to identify the main window" +msgstr "" + +#: main.c:3239 +msgid "--socketid \tOpen Vim inside another GTK widget" +msgstr "" + +#: main.c:3242 +msgid "-P \tOpen Vim inside parent application" +msgstr "" + +#: main.c:3243 +msgid "--windowid \tOpen Vim inside another win32 widget" +msgstr "" + +#: main.c:3587 +msgid "No display" +msgstr "" + +#. Failed to send, abort. +#: main.c:3602 +msgid ": Send failed.\n" +msgstr "" + +#. Let vim start normally. +#: main.c:3608 +msgid ": Send failed. Trying to execute locally\n" +msgstr "" + +#: main.c:3646 +#: main.c:3667 +#, c-format +msgid "%d of %d edited" +msgstr "" + +#: main.c:3689 +msgid "No display: Send expression failed.\n" +msgstr "" + +#: main.c:3701 +msgid ": Send expression failed.\n" +msgstr "" + +#: mark.c:761 +msgid "No marks set" +msgstr "" + +#: mark.c:763 +#, c-format +msgid "E283: No marks matching \"%s\"" +msgstr "" + +#. Highlight title +#: mark.c:774 +msgid "" +"\n" +"mark line col file/text" +msgstr "" + +#. Highlight title +#: mark.c:896 +msgid "" +"\n" +" jump line col file/text" +msgstr "" + +#. Highlight title +#: mark.c:943 +msgid "" +"\n" +"change line col text" +msgstr "" + +#: mark.c:1437 +#, c-format +msgid "" +"\n" +"# File marks:\n" +msgstr "" + +#. Write the jumplist with -' +#: mark.c:1472 +#, c-format +msgid "" +"\n" +"# Jumplist (newest first):\n" +msgstr "" + +#: mark.c:1573 +#, c-format +msgid "" +"\n" +"# History of marks within files (newest to oldest):\n" +msgstr "" + +#: mark.c:1677 +msgid "Missing '>'" +msgstr "" + +#: mbyte.c:550 +msgid "E543: Not a valid codepage" +msgstr "" + +#: mbyte.c:5540 +msgid "E284: Cannot set IC values" +msgstr "" + +#: mbyte.c:5692 +msgid "E285: Failed to create input context" +msgstr "" + +#: mbyte.c:5850 +msgid "E286: Failed to open input method" +msgstr "" + +#: mbyte.c:5863 +msgid "E287: Warning: Could not set destroy callback to IM" +msgstr "" + +#: mbyte.c:5869 +msgid "E288: input method doesn't support any style" +msgstr "" + +#: mbyte.c:5928 +msgid "E289: input method doesn't support my preedit type" +msgstr "" + +#: mbyte.c:6004 +msgid "E290: over-the-spot style requires fontset" +msgstr "" + +#: mbyte.c:6040 +msgid "E291: Your GTK+ is older than 1.2.3. Status area disabled" +msgstr "" + +#: mbyte.c:6351 +msgid "E292: Input Method Server is not running" +msgstr "" + +#: memfile.c:502 +msgid "E293: block was not locked" +msgstr "" + +#: memfile.c:1045 +msgid "E294: Seek error in swap file read" +msgstr "" + +#: memfile.c:1050 +msgid "E295: Read error in swap file" +msgstr "" + +#: memfile.c:1102 +msgid "E296: Seek error in swap file write" +msgstr "" + +#: memfile.c:1120 +msgid "E297: Write error in swap file" +msgstr "" + +#: memfile.c:1317 +msgid "E300: Swap file already exists (symlink attack?)" +msgstr "" + +#: memline.c:312 +msgid "E298: Didn't get block nr 0?" +msgstr "E298: Ophalen blok nummer 0 mislukt?" + +#: memline.c:359 +msgid "E298: Didn't get block nr 1?" +msgstr "E298: Ophalen blok nummer 1 mislukt?" + +#: memline.c:377 +msgid "E298: Didn't get block nr 2?" +msgstr "E298: Ophalen blok nummer 2 mislukt?" + +#. could not (re)open the swap file, what can we do???? +#: memline.c:490 +msgid "E301: Oops, lost the swap file!!!" +msgstr "E301: Helaas, wisselbestand is verdwenen!!!" + +#: memline.c:502 +msgid "E302: Could not rename swap file" +msgstr "" + +#: memline.c:592 +#, c-format +msgid "E303: Unable to open swap file for \"%s\", recovery impossible" +msgstr "" + +#: memline.c:703 +msgid "E304: ml_upd_block0(): Didn't get block 0??" +msgstr "" + +#: memline.c:905 +#, c-format +msgid "E305: No swap file found for %s" +msgstr "" + +#: memline.c:915 +msgid "Enter number of swap file to use (0 to quit): " +msgstr "Typ het nummer van het wisselbestand om te gebruiken (0 om te stoppen): " + +#: memline.c:960 +#, c-format +msgid "E306: Cannot open %s" +msgstr "" + +#: memline.c:982 +msgid "Unable to read block 0 from " +msgstr "" + +#: memline.c:985 +msgid "" +"\n" +"Maybe no changes were made or Vim did not update the swap file." +msgstr "" + +#: memline.c:995 +#: memline.c:1012 +msgid " cannot be used with this version of Vim.\n" +msgstr "" + +#: memline.c:997 +msgid "Use Vim version 3.0.\n" +msgstr "" + +#: memline.c:1003 +#, c-format +msgid "E307: %s does not look like a Vim swap file" +msgstr "" + +#: memline.c:1016 +msgid " cannot be used on this computer.\n" +msgstr "" + +#: memline.c:1018 +msgid "The file was created on " +msgstr "" + +#: memline.c:1022 +msgid "" +",\n" +"or the file has been damaged." +msgstr "" + +#: memline.c:1040 +msgid " has been damaged (page size is smaller than minimum value).\n" +msgstr "" + +#: memline.c:1072 +#, c-format +msgid "Using swap file \"%s\"" +msgstr "Toepassen van wisselbestand \"%s\"" + +#: memline.c:1078 +#, c-format +msgid "Original file \"%s\"" +msgstr "Oorspronkelijke bestand \"%s\"" + +#: memline.c:1091 +msgid "E308: Warning: Original file may have been changed" +msgstr "" + +#: memline.c:1161 +#, c-format +msgid "E309: Unable to read block 1 from %s" +msgstr "" + +#: memline.c:1165 +msgid "???MANY LINES MISSING" +msgstr "" + +#: memline.c:1181 +msgid "???LINE COUNT WRONG" +msgstr "" + +#: memline.c:1188 +msgid "???EMPTY BLOCK" +msgstr "" + +#: memline.c:1214 +msgid "???LINES MISSING" +msgstr "" + +#: memline.c:1246 +#, c-format +msgid "E310: Block 1 ID wrong (%s not a .swp file?)" +msgstr "" + +#: memline.c:1251 +msgid "???BLOCK MISSING" +msgstr "" + +#: memline.c:1267 +msgid "??? from here until ???END lines may be messed up" +msgstr "" + +#: memline.c:1283 +msgid "??? from here until ???END lines may have been inserted/deleted" +msgstr "" + +#: memline.c:1303 +msgid "???END" +msgstr "" + +#: memline.c:1366 +msgid "E311: Recovery Interrupted" +msgstr "" + +#: memline.c:1371 +msgid "E312: Errors detected while recovering; look for lines starting with ???" +msgstr "" + +#: memline.c:1373 +msgid "See \":help E312\" for more information." +msgstr "" + +#: memline.c:1380 +msgid "Recovery completed. You should check if everything is OK." +msgstr "Herstel is afgerond. Controleer of het resultaat juist is." + +#: memline.c:1381 +msgid "" +"\n" +"(You might want to write out this file under another name\n" +msgstr "" +"\n" +"(Een advies is dit bestand onder een andere naam op te slaan\n" + +#: memline.c:1382 +msgid "and run diff with the original file to check for changes)" +msgstr "en met 'diff' te controleren op wijzigingen)" + +#: memline.c:1385 +msgid "Recovery completed. Buffer contents equals file contents." +msgstr "Herstel is afgerond. Inhoud van het buffer komt overeen met de bestandsinhoud." + +#: memline.c:1386 +msgid "" +"\n" +"You may want to delete the .swp file now.\n" +"\n" +msgstr "" +"\n" +"Het .swp-bestand kan nu verwijderd worden.\n" +"\n" + +#. use msg() to start the scrolling properly +#: memline.c:1462 +msgid "Swap files found:" +msgstr "Gevonden wisselbestanden:" + +#: memline.c:1649 +msgid " In current directory:\n" +msgstr " In huidige map:\n" + +#: memline.c:1651 +msgid " Using specified name:\n" +msgstr " Gebruikt opgegeven naam:\n" + +#: memline.c:1655 +msgid " In directory " +msgstr " In map " + +#: memline.c:1673 +msgid " -- none --\n" +msgstr " -- geen --\n" + +#: memline.c:1748 +msgid " owned by: " +msgstr " eigenaar: " + +#: memline.c:1750 +msgid " dated: " +msgstr " datum: " + +#: memline.c:1754 +#: memline.c:3794 +msgid " dated: " +msgstr " datum: " + +#: memline.c:1773 +msgid " [from Vim version 3.0]" +msgstr " [van Vim-versie 3.0]" + +#: memline.c:1777 +msgid " [does not look like a Vim swap file]" +msgstr " [lijkt geen Vvim-wisselbestand te zijn]" + +#: memline.c:1781 +msgid " file name: " +msgstr " bestandsnaam: " + +#: memline.c:1787 +msgid "" +"\n" +" modified: " +msgstr "" +"\n" +" bewerkt: " + +#: memline.c:1788 +msgid "YES" +msgstr "JA" + +#: memline.c:1788 +msgid "no" +msgstr "nee" + +#: memline.c:1792 +msgid "" +"\n" +" user name: " +msgstr "" +"\n" +" gebruikersnaam: " + +#: memline.c:1799 +msgid " host name: " +msgstr " host-naam:" + +#: memline.c:1801 +msgid "" +"\n" +" host name: " +msgstr "" +"\n" +" host-naam: " + +#: memline.c:1807 +msgid "" +"\n" +" process ID: " +msgstr "" +"\n" +" proces-id: " + +#: memline.c:1813 +msgid " (still running)" +msgstr " (nog actief)" + +#: memline.c:1825 +msgid "" +"\n" +" [not usable with this version of Vim]" +msgstr "" +"\n" +" [onbruikbaar met deze versie van Vim]" + +#: memline.c:1828 +msgid "" +"\n" +" [not usable on this computer]" +msgstr "" +"\n" +" [onbruikbaar op deze computer]" + +#: memline.c:1833 +msgid " [cannot be read]" +msgstr " [lezen is onmogelijk]" + +#: memline.c:1837 +msgid " [cannot be opened]" +msgstr " [openen is onmogelijk]" + +#: memline.c:2027 +msgid "E313: Cannot preserve, there is no swap file" +msgstr "E313: kan niet worden behouden, want er is geen wisselbestand" + +#: memline.c:2080 +msgid "File preserved" +msgstr "Bestand behouden" + +#: memline.c:2082 +msgid "E314: Preserve failed" +msgstr "E314: behouden is mislukt" + +#: memline.c:2159 +#, c-format +msgid "E315: ml_get: invalid lnum: %ld" +msgstr "" + +#: memline.c:2194 +#, c-format +msgid "E316: ml_get: cannot find line %ld" +msgstr "" + +#: memline.c:2608 +msgid "E317: pointer block id wrong 3" +msgstr "" + +#: memline.c:2688 +msgid "stack_idx should be 0" +msgstr "" + +#: memline.c:2750 +msgid "E318: Updated too many blocks?" +msgstr "" + +#: memline.c:2930 +msgid "E317: pointer block id wrong 4" +msgstr "" + +#: memline.c:2957 +msgid "deleted block 1?" +msgstr "" + +#: memline.c:3164 +#, c-format +msgid "E320: Cannot find line %ld" +msgstr "" + +#: memline.c:3413 +msgid "E317: pointer block id wrong" +msgstr "" + +#: memline.c:3429 +msgid "pe_line_count is zero" +msgstr "" + +#: memline.c:3458 +#, c-format +msgid "E322: line number out of range: %ld past the end" +msgstr "" + +#: memline.c:3462 +#, c-format +msgid "E323: line count wrong in block %ld" +msgstr "" + +#: memline.c:3511 +msgid "Stack size increases" +msgstr "" + +#: memline.c:3558 +msgid "E317: pointer block id wrong 2" +msgstr "" + +#: memline.c:3595 +#, c-format +msgid "E773: Symlink loop for \"%s\"" +msgstr "E773: Symbolische koppelingslus voor \"%s\"" + +#: memline.c:3784 +msgid "E325: ATTENTION" +msgstr "E325: OPGELET" + +#: memline.c:3785 +msgid "" +"\n" +"Found a swap file by the name \"" +msgstr "" +"\n" +"Er is een wisselbestand aangetroffen met de naam \"" + +#: memline.c:3789 +msgid "While opening file \"" +msgstr "bij het openen van bestand \"" + +#: memline.c:3802 +msgid " NEWER than swap file!\n" +msgstr " NIEUWER dan het wisselbestand!\n" + +#. Some of these messages are long to allow translation to +#. * other languages. +#: memline.c:3806 +msgid "" +"\n" +"(1) Another program may be editing the same file.\n" +" If this is the case, be careful not to end up with two\n" +" different instances of the same file when making changes.\n" +msgstr "" +"\n" +"(1) Mogelijk wordt dit bestand met een ander programma bewerkt.\n" +" Als dit het geval is, pas dan op niet met twee verschillende\n" +" versies van hetzelfde bestand te eindigen bij het bewerken.\n" + +#: memline.c:3807 +msgid " Quit, or continue with caution.\n" +msgstr " Stop of ga aandachtig verder.\n" + +#: memline.c:3808 +msgid "" +"\n" +"(2) An edit session for this file crashed.\n" +msgstr "" +"\n" +"(2) Een sessie waarin dit bestand werd bewerkt is onverhoeds gestopt.\n" + +#: memline.c:3809 +msgid " If this is the case, use \":recover\" or \"vim -r " +msgstr " Als dit het geval is, gebruikt dan \":recover\" of \"vim -r " + +#: memline.c:3811 +msgid "" +"\"\n" +" to recover the changes (see \":help recovery\").\n" +msgstr "" +"\"\n" +" om de aanpassingen te herstellen (zie \":help recovery\").\n" + +#: memline.c:3812 +msgid " If you did this already, delete the swap file \"" +msgstr " Als dit al gedaan is, verwijder dan het wisselbestand \"" + +#: memline.c:3814 +msgid "" +"\"\n" +" to avoid this message.\n" +msgstr "" +"\"\n" +" om dit bericht te voorkomen.\n" + +#: memline.c:4233 +#: memline.c:4237 +msgid "Swap file \"" +msgstr "Wisselbestand \"" + +#: memline.c:4234 +#: memline.c:4240 +msgid "\" already exists!" +msgstr "\" bestaat al!" + +#: memline.c:4243 +msgid "VIM - ATTENTION" +msgstr "VIM - OPGELET" + +#: memline.c:4245 +msgid "Swap file already exists!" +msgstr "Wisselbestand bestaat reeds." + +#: memline.c:4249 +msgid "" +"&Open Read-Only\n" +"&Edit anyway\n" +"&Recover\n" +"&Quit\n" +"&Abort" +msgstr "" +"Alleen-lezen &openen\n" +"Toch b&ewerken\n" +"He&rstellen\n" +"&Stoppen\n" +"&Afbreken" + +#: memline.c:4251 +msgid "" +"&Open Read-Only\n" +"&Edit anyway\n" +"&Recover\n" +"&Delete it\n" +"&Quit\n" +"&Abort" +msgstr "" +"Alleen-lezen &openen\n" +"Toch b&ewerken\n" +"He&rstellen\n" +"Verwij&deren\n" +"&Stoppen\n" +"&Afbreken" + +#: memline.c:4322 +msgid "E326: Too many swap files found" +msgstr "E326: teveel wisselbestanden aangetroffen" + +#: menu.c:67 +msgid "E327: Part of menu-item path is not sub-menu" +msgstr "E327: deel van menu-itempad is geen submenu" + +#: menu.c:68 +msgid "E328: Menu only exists in another mode" +msgstr "E328: menu bestaat alleen in andere modus" + +#: menu.c:69 +#, c-format +msgid "E329: No menu \"%s\"" +msgstr "E329: geen menu \"%s\"" + +#. Only a mnemonic or accelerator is not valid. +#: menu.c:480 +msgid "E792: Empty menu name" +msgstr "E792: menunaam is leeg" + +#: menu.c:498 +msgid "E330: Menu path must not lead to a sub-menu" +msgstr "" + +#: menu.c:537 +msgid "E331: Must not add menu items directly to menu bar" +msgstr "" + +#: menu.c:543 +msgid "E332: Separator cannot be part of a menu path" +msgstr "" + +#. Now we have found the matching menu, and we list the mappings +#. Highlight title +#: menu.c:1112 +msgid "" +"\n" +"--- Menus ---" +msgstr "" + +#: menu.c:2146 +msgid "Tear off this menu" +msgstr "" + +#: menu.c:2211 +msgid "E333: Menu path must lead to a menu item" +msgstr "" + +#: menu.c:2231 +#, c-format +msgid "E334: Menu not found: %s" +msgstr "" + +#: menu.c:2313 +#, c-format +msgid "E335: Menu not defined for %s mode" +msgstr "" + +#: menu.c:2351 +msgid "E336: Menu path must lead to a sub-menu" +msgstr "" + +#: menu.c:2372 +msgid "E337: Menu not found - check menu names" +msgstr "" + +#: message.c:462 +#, c-format +msgid "Error detected while processing %s:" +msgstr "Fout opgetreden tijdens verwerken van %s:" + +#: message.c:487 +#, c-format +msgid "line %4ld:" +msgstr "regel %4ld:" + +#: message.c:685 +#, c-format +msgid "E354: Invalid register name: '%s'" +msgstr "" + +#: message.c:833 +msgid "Messages maintainer: Bram Moolenaar " +msgstr "Vertaald door: Erwin Poeze " + +#: message.c:1090 +msgid "Interrupt: " +msgstr "" + +#: message.c:1092 +msgid "Press ENTER or type command to continue" +msgstr "Toets ENTER of typ een opdracht om verder te gaan" + +#: message.c:2139 +#, c-format +msgid "%s line %ld" +msgstr "%s regel %ld" + +#: message.c:2839 +msgid "-- More --" +msgstr "-- meer --" + +#: message.c:2845 +msgid " SPACE/d/j: screen/page/line down, b/u/k: up, q: quit " +msgstr "" + +#: message.c:3637 +#: message.c:3652 +msgid "Question" +msgstr "Vraag" + +#: message.c:3639 +msgid "" +"&Yes\n" +"&No" +msgstr "" + +#: message.c:3672 +msgid "" +"&Yes\n" +"&No\n" +"Save &All\n" +"&Discard All\n" +"&Cancel" +msgstr "" + +#: message.c:3713 +msgid "Select Directory dialog" +msgstr "" + +#: message.c:3715 +msgid "Save File dialog" +msgstr "" + +#: message.c:3717 +msgid "Open File dialog" +msgstr "" + +#. TODO: non-GUI file selector here +#: message.c:3817 +msgid "E338: Sorry, no file browser in console mode" +msgstr "" + +#: message.c:3848 +msgid "E766: Insufficient arguments for printf()" +msgstr "" + +#: message.c:3924 +msgid "E807: Expected Float argument for printf()" +msgstr "" + +#: message.c:4812 +msgid "E767: Too many arguments to printf()" +msgstr "" + +#: misc1.c:2984 +msgid "W10: Warning: Changing a readonly file" +msgstr "" + +#: misc1.c:3278 +msgid "Type number and or click with mouse (empty cancels): " +msgstr "" + +#: misc1.c:3280 +msgid "Type number and (empty cancels): " +msgstr "" + +#: misc1.c:3332 +msgid "1 more line" +msgstr "1 regel meer" + +#: misc1.c:3334 +msgid "1 line less" +msgstr "1 regel minder" + +#: misc1.c:3339 +#, c-format +msgid "%ld more lines" +msgstr "%ld regels meer" + +#: misc1.c:3341 +#, c-format +msgid "%ld fewer lines" +msgstr "%ld regels minder" + +#: misc1.c:3344 +msgid " (Interrupted)" +msgstr " (onderbroken)" + +#: misc1.c:3409 +msgid "Beep!" +msgstr "biep!" + +#: misc1.c:8394 +msgid "Vim: preserving files...\n" +msgstr "" + +#. close all memfiles, without deleting +#: misc1.c:8404 +msgid "Vim: Finished.\n" +msgstr "" + +#: misc2.c:771 +#: misc2.c:787 +#, c-format +msgid "ERROR: " +msgstr "" + +#: misc2.c:791 +#, c-format +msgid "" +"\n" +"[bytes] total alloc-freed %lu-%lu, in use %lu, peak use %lu\n" +msgstr "" + +#: misc2.c:793 +#, c-format +msgid "" +"[calls] total re/malloc()'s %lu, total free()'s %lu\n" +"\n" +msgstr "" + +#: misc2.c:848 +msgid "E340: Line is becoming too long" +msgstr "" + +#: misc2.c:892 +#, c-format +msgid "E341: Internal error: lalloc(%ld, )" +msgstr "" + +#: misc2.c:1006 +#, c-format +msgid "E342: Out of memory! (allocating %lu bytes)" +msgstr "" + +#: misc2.c:3087 +#, c-format +msgid "Calling shell to execute: \"%s\"" +msgstr "" + +#: misc2.c:3356 +msgid "E545: Missing colon" +msgstr "" + +#: misc2.c:3358 +#: misc2.c:3385 +msgid "E546: Illegal mode" +msgstr "" + +#: misc2.c:3424 +msgid "E547: Illegal mouseshape" +msgstr "" + +#: misc2.c:3464 +msgid "E548: digit expected" +msgstr "" + +#: misc2.c:3469 +msgid "E549: Illegal percentage" +msgstr "" + +#: misc2.c:3864 +msgid "Enter encryption key: " +msgstr "" + +#: misc2.c:3865 +msgid "Enter same key again: " +msgstr "" + +#: misc2.c:3876 +msgid "Keys don't match!" +msgstr "" + +#: misc2.c:4418 +#, c-format +msgid "E343: Invalid path: '**[number]' must be at the end of the path or be followed by '%s'." +msgstr "" + +#: misc2.c:5713 +#, c-format +msgid "E344: Can't find directory \"%s\" in cdpath" +msgstr "" + +#: misc2.c:5716 +#, c-format +msgid "E345: Can't find file \"%s\" in path" +msgstr "" + +#: misc2.c:5722 +#, c-format +msgid "E346: No more directory \"%s\" found in cdpath" +msgstr "" + +#: misc2.c:5725 +#, c-format +msgid "E347: No more file \"%s\" found in path" +msgstr "" + +#: netbeans.c:390 +msgid "Cannot connect to Netbeans #2" +msgstr "" + +#: netbeans.c:400 +msgid "Cannot connect to Netbeans" +msgstr "" + +#: netbeans.c:445 +#, c-format +msgid "E668: Wrong access mode for NetBeans connection info file: \"%s\"" +msgstr "" + +#: netbeans.c:798 +msgid "read from Netbeans socket" +msgstr "" + +#: netbeans.c:1950 +#, c-format +msgid "E658: NetBeans connection lost for buffer %ld" +msgstr "" + +#: netbeans.c:2976 +msgid "E511: netbeans already connected" +msgstr "" + +#: netbeans.c:3911 +msgid "E505: " +msgstr "" + +#: normal.c:186 +msgid "E349: No identifier under cursor" +msgstr "" + +#: normal.c:2206 +msgid "E774: 'operatorfunc' is empty" +msgstr "" + +#: normal.c:2225 +msgid "E775: Eval feature not available" +msgstr "" + +#: normal.c:3240 +msgid "Warning: terminal cannot highlight" +msgstr "waarschuwing: terminal kan niet oplichten" + +#: normal.c:3535 +msgid "E348: No string under cursor" +msgstr "" + +#: normal.c:4887 +msgid "E352: Cannot erase folds with current 'foldmethod'" +msgstr "" + +#: normal.c:7449 +msgid "E664: changelist is empty" +msgstr "E664: wijzigingslijst is leeg" + +#: normal.c:7451 +msgid "E662: At start of changelist" +msgstr "E662: begin van wijzigingslijst" + +#: normal.c:7453 +msgid "E663: At end of changelist" +msgstr "E663: einde van wijzigingslijst" + +#: normal.c:8854 +msgid "Type :quit to exit Vim" +msgstr "Typ :quit om Vim te verlaten" + +#: ops.c:293 +#, c-format +msgid "1 line %sed 1 time" +msgstr "1 regel %sed 1 maal" + +#: ops.c:295 +#, c-format +msgid "1 line %sed %d times" +msgstr "1 regel %sed %d maal" + +#: ops.c:300 +#, c-format +msgid "%ld lines %sed 1 time" +msgstr "%ld regels %sed 1 maal" + +#: ops.c:303 +#, c-format +msgid "%ld lines %sed %d times" +msgstr "%ld regels %sed %d maal" + +#: ops.c:691 +#, c-format +msgid "%ld lines to indent... " +msgstr "%ld in te springen regels... " + +#: ops.c:742 +msgid "1 line indented " +msgstr "1 regel ingesprongen " + +#: ops.c:744 +#, c-format +msgid "%ld lines indented " +msgstr "%ld regels ingesprongen " + +#: ops.c:1170 +msgid "E748: No previously used register" +msgstr "" + +#. must display the prompt +#: ops.c:1741 +msgid "cannot yank; delete anyway" +msgstr "kopiëren niet mogelijk; toch verwijderd" + +#: ops.c:2338 +msgid "1 line changed" +msgstr "1 regel gewijzigd" + +#: ops.c:2340 +#, c-format +msgid "%ld lines changed" +msgstr "%ld regels gewijzigd" + +#: ops.c:2795 +#, c-format +msgid "freeing %ld lines" +msgstr "" + +#: ops.c:3080 +msgid "block of 1 line yanked" +msgstr "blok van 1 regel gekopieerd" + +#: ops.c:3083 +msgid "1 line yanked" +msgstr "1 regel gekopieerd" + +#: ops.c:3087 +#, c-format +msgid "block of %ld lines yanked" +msgstr "blok van %ld regels gekopieerd" + +#: ops.c:3090 +#, c-format +msgid "%ld lines yanked" +msgstr "%ld regels gekopieerd" + +#: ops.c:3385 +#, c-format +msgid "E353: Nothing in register %s" +msgstr "E353: niets in register %s" + +#. Highlight title +#: ops.c:3977 +msgid "" +"\n" +"--- Registers ---" +msgstr "" +"\n" +"--- Registers ---" + +#: ops.c:5351 +msgid "Illegal register name" +msgstr "ongeldige registernaam" + +#: ops.c:5447 +#, c-format +msgid "" +"\n" +"# Registers:\n" +msgstr "" +"\n" +"# Registers:\n" + +#: ops.c:5504 +#, c-format +msgid "E574: Unknown register type %d" +msgstr "" + +#: ops.c:6445 +#, c-format +msgid "%ld Cols; " +msgstr "%ld koln; " + +#: ops.c:6454 +#, c-format +msgid "Selected %s%ld of %ld Lines; %ld of %ld Words; %ld of %ld Bytes" +msgstr "geselecteerd %s%ld van %ld regels; %ld van %ld woorden; %ld van %ld bytes" + +#: ops.c:6461 +#, c-format +msgid "Selected %s%ld of %ld Lines; %ld of %ld Words; %ld of %ld Chars; %ld of %ld Bytes" +msgstr "geselecteerd %s%ld van %ld regels; %ld van %ld woorden; %ld van %ld rekens; %ld van %ld bytes" + +#: ops.c:6480 +#, c-format +msgid "Col %s of %s; Line %ld of %ld; Word %ld of %ld; Byte %ld of %ld" +msgstr "kol %s van %s; regel %ld van %ld; woord %ld van %ld; byte %ld van %ld" + +#: ops.c:6488 +#, c-format +msgid "Col %s of %s; Line %ld of %ld; Word %ld of %ld; Char %ld of %ld; Byte %ld of %ld" +msgstr "kol %s van %s; regel %ld van %ld; woord %ld van %ld; teken %ld van %ld; byte %ld van %ld" + +#: ops.c:6500 +#, c-format +msgid "(+%ld for BOM)" +msgstr "(+%ld voor BOD)" + +#: option.c:1991 +msgid "%<%f%h%m%=Page %N" +msgstr "%<%f%h%m%=pagina %N" + +#: option.c:2565 +msgid "Thanks for flying Vim" +msgstr "Dank voor het gebruik van Vim" + +#: option.c:4179 +#: option.c:4322 +msgid "E518: Unknown option" +msgstr "E518: onbekende optie" + +#: option.c:4192 +msgid "E519: Option not supported" +msgstr "E519: optie niet ondersteund" + +#: option.c:4230 +msgid "E520: Not allowed in a modeline" +msgstr "" + +#: option.c:4448 +msgid "E521: Number required after =" +msgstr "" + +#: option.c:4773 +#: option.c:5579 +msgid "E522: Not found in termcap" +msgstr "" + +#: option.c:4890 +#, c-format +msgid "E539: Illegal character <%s>" +msgstr "" + +#: option.c:5571 +msgid "E529: Cannot set 'term' to empty string" +msgstr "" + +#: option.c:5574 +msgid "E530: Cannot change term in GUI" +msgstr "" + +#: option.c:5576 +msgid "E531: Use \":gui\" to start the GUI" +msgstr "" + +#: option.c:5605 +msgid "E589: 'backupext' and 'patchmode' are equal" +msgstr "" + +#: option.c:5833 +msgid "E617: Cannot be changed in the GTK+ 2 GUI" +msgstr "" + +#: option.c:6015 +msgid "E524: Missing colon" +msgstr "" + +#: option.c:6017 +msgid "E525: Zero length string" +msgstr "" + +#: option.c:6100 +#, c-format +msgid "E526: Missing number after <%s>" +msgstr "" + +#: option.c:6114 +msgid "E527: Missing comma" +msgstr "" + +#: option.c:6121 +msgid "E528: Must specify a ' value" +msgstr "" + +#: option.c:6170 +msgid "E595: contains unprintable or wide character" +msgstr "" + +#: option.c:6214 +msgid "E596: Invalid font(s)" +msgstr "" + +#: option.c:6223 +msgid "E597: can't select fontset" +msgstr "" + +#: option.c:6225 +msgid "E598: Invalid fontset" +msgstr "" + +#: option.c:6233 +msgid "E533: can't select wide font" +msgstr "" + +#: option.c:6235 +msgid "E534: Invalid wide font" +msgstr "" + +#: option.c:6564 +#, c-format +msgid "E535: Illegal character after <%c>" +msgstr "E535: ongeldig teken na <%c>" + +#: option.c:6688 +msgid "E536: comma required" +msgstr "E536: komma is vereist" + +#: option.c:6698 +#, c-format +msgid "E537: 'commentstring' must be empty or contain %s" +msgstr "E537: 'commentstring' moet leeg zijn of het volgende bevatten: %s" + +#: option.c:6779 +msgid "E538: No mouse support" +msgstr "E538: geen muisondersteuning" + +#: option.c:7104 +msgid "E540: Unclosed expression sequence" +msgstr "E540: ongepaarde expressie-volgorde" + +#: option.c:7108 +msgid "E541: too many items" +msgstr "E541: teveel items" + +#: option.c:7110 +msgid "E542: unbalanced groups" +msgstr "E542: ongepaarde groepen" + +#: option.c:7461 +msgid "E590: A preview window already exists" +msgstr "E590: een voorvertoningsvenster bestaat al" + +#: option.c:7716 +msgid "W17: Arabic requires UTF-8, do ':set encoding=utf-8'" +msgstr "W17: Arabisch vereist UTF-8, typ ':set encoding=utf-8'" + +#: option.c:8172 +#, c-format +msgid "E593: Need at least %d lines" +msgstr "E593: vereist minstens %d regels" + +#: option.c:8182 +#, c-format +msgid "E594: Need at least %d columns" +msgstr "E594: vereist minstens %d kolommen" + +#: option.c:8501 +#, c-format +msgid "E355: Unknown option: %s" +msgstr "E355: onbekende optie: %s" + +#. There's another character after zeros or the string +#. * is empty. In both cases, we are trying to set a +#. * num option using a string. +#: option.c:8533 +#, c-format +msgid "E521: Number required: &%s = '%s'" +msgstr "E521: 'Number' vereist: &%s = '%s'" + +#: option.c:8657 +msgid "" +"\n" +"--- Terminal codes ---" +msgstr "" +"\n" +"--- Terminal-codes ---" + +#: option.c:8659 +msgid "" +"\n" +"--- Global option values ---" +msgstr "" +"\n" +"--- Globale optiewaarden ---" + +#: option.c:8661 +msgid "" +"\n" +"--- Local option values ---" +msgstr "" +"\n" +"--- Lokale optiewaarden ---" + +#: option.c:8663 +msgid "" +"\n" +"--- Options ---" +msgstr "" +"\n" +"--- Opties ---" + +#: option.c:9489 +msgid "E356: get_varp ERROR" +msgstr "" + +#: option.c:10604 +#, c-format +msgid "E357: 'langmap': Matching character missing for %s" +msgstr "" + +#: option.c:10628 +#, c-format +msgid "E358: 'langmap': Extra characters after semicolon: %s" +msgstr "" + +#: os_amiga.c:278 +msgid "cannot open " +msgstr "gefaald tijden openen van " + +#: os_amiga.c:313 +msgid "VIM: Can't open window!\n" +msgstr "VIM: kan venster niet openen!\n" + +#: os_amiga.c:340 +msgid "Need Amigados version 2.04 or later\n" +msgstr "Vereist Amigados versie 2.04 of nieuwer\n" + +#: os_amiga.c:346 +#, c-format +msgid "Need %s version %ld\n" +msgstr "Vereist %s versie %ld\n" + +#: os_amiga.c:419 +msgid "Cannot open NIL:\n" +msgstr "" + +#: os_amiga.c:437 +msgid "Cannot create " +msgstr "Gefaald tijdens aanmaken van " + +#: os_amiga.c:943 +#, c-format +msgid "Vim exiting with %d\n" +msgstr "Vim stoppen met %d\n" + +#: os_amiga.c:979 +msgid "cannot change console mode ?!\n" +msgstr "" + +#: os_amiga.c:1057 +msgid "mch_get_shellsize: not a console??\n" +msgstr "" + +#. if Vim opened a window: Executing a shell may cause crashes +#: os_amiga.c:1212 +msgid "E360: Cannot execute shell with -f option" +msgstr "" + +#: os_amiga.c:1253 +#: os_amiga.c:1343 +msgid "Cannot execute " +msgstr "" + +#: os_amiga.c:1256 +#: os_amiga.c:1353 +msgid "shell " +msgstr "" + +#: os_amiga.c:1276 +#: os_amiga.c:1378 +msgid " returned\n" +msgstr "" + +#: os_amiga.c:1540 +msgid "ANCHOR_BUF_SIZE too small." +msgstr "" + +#: os_amiga.c:1544 +msgid "I/O ERROR" +msgstr "" + +#: os_mswin.c:595 +msgid "Message" +msgstr "" + +#: os_mswin.c:710 +msgid "'columns' is not 80, cannot execute external commands" +msgstr "" + +#: os_mswin.c:2143 +msgid "E237: Printer selection failed" +msgstr "" + +#: os_mswin.c:2183 +#, c-format +msgid "to %s on %s" +msgstr "" + +#: os_mswin.c:2198 +#, c-format +msgid "E613: Unknown printer font: %s" +msgstr "" + +#: os_mswin.c:2247 +#: os_mswin.c:2257 +#, c-format +msgid "E238: Print error: %s" +msgstr "" + +#: os_mswin.c:2285 +#, c-format +msgid "Printing '%s'" +msgstr "" + +#: os_mswin.c:3461 +#, c-format +msgid "E244: Illegal charset name \"%s\" in font name \"%s\"" +msgstr "" + +#: os_mswin.c:3471 +#, c-format +msgid "E245: Illegal char '%c' in font name \"%s\"" +msgstr "" + +#: os_riscos.c:1263 +msgid "E366: Invalid 'osfiletype' option - using Text" +msgstr "" + +#: os_unix.c:1083 +msgid "Vim: Double signal, exiting\n" +msgstr "Vim: dubbel signaal, stoppen\n" + +#: os_unix.c:1089 +#, c-format +msgid "Vim: Caught deadly signal %s\n" +msgstr "Vim: fataal signaal gevangen %s\n" + +#: os_unix.c:1092 +#, c-format +msgid "Vim: Caught deadly signal\n" +msgstr "Vim: fataal signaal gevangen\n" + +#: os_unix.c:1430 +#, c-format +msgid "Opening the X display took %ld msec" +msgstr "Openen van X-display vereiste %ld ms" + +#: os_unix.c:1457 +msgid "" +"\n" +"Vim: Got X error\n" +msgstr "" + +#: os_unix.c:1568 +msgid "Testing the X display failed" +msgstr "" + +#: os_unix.c:1708 +msgid "Opening the X display timed out" +msgstr "" + +#: os_unix.c:2682 +#: os_unix.c:2689 +msgid "" +"\n" +"Could not get security context for " +msgstr "" + +#: os_unix.c:2699 +msgid "" +"\n" +"Could not set security context for " +msgstr "" + +#: os_unix.c:3718 +#: os_unix.c:4643 +msgid "" +"\n" +"Cannot execute shell " +msgstr "" + +#: os_unix.c:3766 +msgid "" +"\n" +"Cannot execute shell sh\n" +msgstr "" + +#: os_unix.c:3770 +#: os_unix.c:4649 +msgid "" +"\n" +"shell returned " +msgstr "" + +#: os_unix.c:3914 +msgid "" +"\n" +"Cannot create pipes\n" +msgstr "" + +#: os_unix.c:3928 +#: os_unix.c:4192 +msgid "" +"\n" +"Cannot fork\n" +msgstr "" + +#: os_unix.c:4656 +msgid "" +"\n" +"Command terminated\n" +msgstr "" + +#: os_unix.c:4957 +#: os_unix.c:5122 +#: os_unix.c:6852 +msgid "XSMP lost ICE connection" +msgstr "" + +#: os_unix.c:6252 +#: os_unix.c:6355 +#, c-format +msgid "dlerror = \"%s\"" +msgstr "" + +#: os_unix.c:6437 +msgid "Opening the X display failed" +msgstr "" + +#: os_unix.c:6761 +msgid "XSMP handling save-yourself request" +msgstr "" + +#: os_unix.c:6875 +msgid "XSMP opening connection" +msgstr "" + +#: os_unix.c:6894 +msgid "XSMP ICE connection watch failed" +msgstr "" + +#: os_unix.c:6918 +#, c-format +msgid "XSMP SmcOpenConnection failed: %s" +msgstr "" + +#: os_vms_mms.c:60 +msgid "At line" +msgstr "Bij regel" + +#: os_w32exe.c:89 +msgid "Could not load vim32.dll!" +msgstr "" + +#: os_w32exe.c:89 +#: os_w32exe.c:100 +msgid "VIM Error" +msgstr "Vim-fout" + +#: os_w32exe.c:99 +msgid "Could not fix up function pointers to the DLL!" +msgstr "" + +#: os_win16.c:342 +#: os_win32.c:3399 +#, c-format +msgid "shell returned %d" +msgstr "" + +#: os_win32.c:2856 +#, c-format +msgid "Vim: Caught %s event\n" +msgstr "" + +#: os_win32.c:2858 +msgid "close" +msgstr "sluiten" + +#: os_win32.c:2860 +msgid "logoff" +msgstr "uitloggen" + +#: os_win32.c:2861 +msgid "shutdown" +msgstr "afsluiten" + +#: os_win32.c:3351 +msgid "E371: Command not found" +msgstr "E371: opdracht niet gevonden" + +#: os_win32.c:3364 +msgid "" +"VIMRUN.EXE not found in your $PATH.\n" +"External commands will not pause after completion.\n" +"See :help win32-vimrun for more information." +msgstr "" + +#: os_win32.c:3367 +msgid "Vim Warning" +msgstr "Vim-waarschuwing" + +#: quickfix.c:330 +#, c-format +msgid "E372: Too many %%%c in format string" +msgstr "" + +#: quickfix.c:343 +#, c-format +msgid "E373: Unexpected %%%c in format string" +msgstr "" + +#: quickfix.c:405 +msgid "E374: Missing ] in format string" +msgstr "" + +#: quickfix.c:419 +#, c-format +msgid "E375: Unsupported %%%c in format string" +msgstr "" + +#: quickfix.c:439 +#, c-format +msgid "E376: Invalid %%%c in format string prefix" +msgstr "" + +#: quickfix.c:447 +#, c-format +msgid "E377: Invalid %%%c in format string" +msgstr "" + +#: quickfix.c:473 +msgid "E378: 'errorformat' contains no pattern" +msgstr "" + +#: quickfix.c:706 +msgid "E379: Missing or empty directory name" +msgstr "" + +#: quickfix.c:1408 +msgid "E553: No more items" +msgstr "" + +#: quickfix.c:1830 +#, c-format +msgid "(%d of %d)%s%s: " +msgstr "" + +#: quickfix.c:1832 +msgid " (line deleted)" +msgstr "" + +#: quickfix.c:2055 +msgid "E380: At bottom of quickfix stack" +msgstr "" + +#: quickfix.c:2064 +msgid "E381: At top of quickfix stack" +msgstr "" + +#: quickfix.c:2078 +#, c-format +msgid "error list %d of %d; %d errors" +msgstr "" + +#: quickfix.c:2664 +msgid "E382: Cannot write, 'buftype' option is set" +msgstr "" + +#: quickfix.c:3068 +msgid "E683: File name missing or invalid pattern" +msgstr "" + +#: quickfix.c:3166 +#, c-format +msgid "Cannot open file \"%s\"" +msgstr "" + +#: quickfix.c:3703 +msgid "E681: Buffer is not loaded" +msgstr "E681: buffer is niet geladen" + +#: quickfix.c:3764 +msgid "E777: String or List expected" +msgstr "" + +#: regexp.c:331 +#, c-format +msgid "E369: invalid item in %s%%[]" +msgstr "" + +#: regexp.c:1059 +#: regexp.c:1077 +msgid "E339: Pattern too long" +msgstr "" + +#: regexp.c:1234 +msgid "E50: Too many \\z(" +msgstr "" + +#: regexp.c:1245 +#, c-format +msgid "E51: Too many %s(" +msgstr "" + +#: regexp.c:1302 +msgid "E52: Unmatched \\z(" +msgstr "E52: \\z( is niet gepaard" + +#: regexp.c:1306 +#, c-format +msgid "E53: Unmatched %s%%(" +msgstr "E53: %s%%( is niet gepaard" + +#: regexp.c:1308 +#, c-format +msgid "E54: Unmatched %s(" +msgstr "E54: %s( is niet gepaard" + +#: regexp.c:1313 +#, c-format +msgid "E55: Unmatched %s)" +msgstr "E55: %s) is ongepaard" + +#: regexp.c:1531 +#, c-format +msgid "E59: invalid character after %s@" +msgstr "" + +#: regexp.c:1565 +#, c-format +msgid "E60: Too many complex %s{...}s" +msgstr "" + +#: regexp.c:1581 +#, c-format +msgid "E61: Nested %s*" +msgstr "E61: geneste %s*" + +#: regexp.c:1584 +#, c-format +msgid "E62: Nested %s%c" +msgstr "E62: geneste %s%c" + +#: regexp.c:1704 +msgid "E63: invalid use of \\_" +msgstr "E63: onjuist gebruikt van \\_" + +#: regexp.c:1760 +#, c-format +msgid "E64: %s%c follows nothing" +msgstr "E64: %s%c volgt op niets" + +#: regexp.c:1816 +msgid "E65: Illegal back reference" +msgstr "E65: ongeldige terugverwijzing" + +#: regexp.c:1829 +msgid "E66: \\z( not allowed here" +msgstr "E66: \\z( hier niet toegestaan" + +#: regexp.c:1848 +msgid "E67: \\z1 et al. not allowed here" +msgstr "E67: \\z1 en andere hier niet toegestaan" + +#: regexp.c:1860 +msgid "E68: Invalid character after \\z" +msgstr "E68: ongeldig teken na \\z" + +#: regexp.c:1912 +#, c-format +msgid "E69: Missing ] after %s%%[" +msgstr "E69: ontbrekende ] na %s%%[" + +#: regexp.c:1928 +#, c-format +msgid "E70: Empty %s%%[]" +msgstr "E70: leeg %s%%[]" + +#: regexp.c:1973 +#, c-format +msgid "E678: Invalid character after %s%%[dxouU]" +msgstr "E678: onjuist teken na %s%%[dxouU]" + +#: regexp.c:2044 +#, c-format +msgid "E71: Invalid character after %s%%" +msgstr "E71: onjuist teken na %s%%" + +#: regexp.c:2337 +#, c-format +msgid "E769: Missing ] after %s[" +msgstr "E769: ontbrekende ] na %s[" + +#: regexp.c:3033 +#, c-format +msgid "E554: Syntax error in %s{...}" +msgstr "E554: Syntaxfout in %s{...}" + +#: regexp.c:3876 +msgid "External submatches:\n" +msgstr "" + +#: screen.c:9356 +msgid " VREPLACE" +msgstr "" + +#: screen.c:9360 +msgid " REPLACE" +msgstr " VERVANGEN" + +#: screen.c:9365 +msgid " REVERSE" +msgstr "" + +#: screen.c:9367 +msgid " INSERT" +msgstr " INVOEGEN" + +#: screen.c:9370 +msgid " (insert)" +msgstr " (invoegen)" + +#: screen.c:9372 +msgid " (replace)" +msgstr " (vervangen)" + +#: screen.c:9374 +msgid " (vreplace)" +msgstr "" + +#: screen.c:9377 +msgid " Hebrew" +msgstr "" + +#: screen.c:9388 +msgid " Arabic" +msgstr "" + +#: screen.c:9391 +msgid " (lang)" +msgstr "" + +#: screen.c:9395 +msgid " (paste)" +msgstr "" + +#: screen.c:9408 +msgid " VISUAL" +msgstr " VISUEEL" + +#: screen.c:9409 +msgid " VISUAL LINE" +msgstr " VISUELE REGEL" + +#: screen.c:9410 +msgid " VISUAL BLOCK" +msgstr " VISUEEL BLOK" + +#: screen.c:9411 +msgid " SELECT" +msgstr " SELECTEREN" + +#: screen.c:9412 +msgid " SELECT LINE" +msgstr " REGELSELECTIE" + +#: screen.c:9413 +msgid " SELECT BLOCK" +msgstr " BLOKSELECTIE" + +#: screen.c:9429 +#: screen.c:9495 +msgid "recording" +msgstr "opnemen" + +#: search.c:562 +#, c-format +msgid "E383: Invalid search string: %s" +msgstr "E383: ongeldige zoekstring: %s" + +#: search.c:983 +#, c-format +msgid "E384: search hit TOP without match for: %s" +msgstr "E384: TOP bereikt zonder overeenkomst voor: %s" + +#: search.c:986 +#, c-format +msgid "E385: search hit BOTTOM without match for: %s" +msgstr "E385: BODEM bereikt zonder overeenkomst voor: %s" + +#: search.c:1418 +msgid "E386: Expected '?' or '/' after ';'" +msgstr "E386: verwachte '?' of '/' na ';'" + +#: search.c:4691 +msgid " (includes previously listed match)" +msgstr " (bevat eerder getoonde overeenkomst)" + +#. cursor at status line +#: search.c:4711 +msgid "--- Included files " +msgstr "--- bevatte bestanden " + +#: search.c:4713 +msgid "not found " +msgstr "niet gevonden " + +#: search.c:4714 +msgid "in path ---\n" +msgstr "in pad ---\n" + +#: search.c:4771 +msgid " (Already listed)" +msgstr " (Reeds getoond)" + +#: search.c:4773 +msgid " NOT FOUND" +msgstr " NIET GEVONDEN" + +#: search.c:4827 +#, c-format +msgid "Scanning included file: %s" +msgstr "" + +#: search.c:4836 +#, c-format +msgid "Searching included file %s" +msgstr "" + +#: search.c:5059 +msgid "E387: Match is on current line" +msgstr "" + +#: search.c:5203 +msgid "All included files were found" +msgstr "" + +#: search.c:5205 +msgid "No included files" +msgstr "" + +#: search.c:5221 +msgid "E388: Couldn't find definition" +msgstr "" + +#: search.c:5223 +msgid "E389: Couldn't find pattern" +msgstr "E389: kan zoekpatroon niet vinden" + +#: search.c:5401 +msgid "Substitute " +msgstr "Vervangen " + +#: search.c:5414 +#, c-format +msgid "" +"\n" +"# Last %sSearch Pattern:\n" +"~" +msgstr "" +"\n" +"# Laatste %szoekpatroon:\n" +"~" + +#: spell.c:984 +msgid "E759: Format error in spell file" +msgstr "" + +#: spell.c:985 +msgid "E758: Truncated spell file" +msgstr "" + +#: spell.c:986 +#, c-format +msgid "Trailing text in %s line %d: %s" +msgstr "" + +#: spell.c:987 +#, c-format +msgid "Affix name too long in %s line %d: %s" +msgstr "" + +#: spell.c:988 +msgid "E761: Format error in affix file FOL, LOW or UPP" +msgstr "" + +#: spell.c:989 +msgid "E762: Character in FOL, LOW or UPP is out of range" +msgstr "" + +#: spell.c:990 +msgid "Compressing word tree..." +msgstr "" + +#: spell.c:2146 +msgid "E756: Spell checking is not enabled" +msgstr "" + +#: spell.c:2499 +#, c-format +msgid "Warning: Cannot find word list \"%s.%s.spl\" or \"%s.ascii.spl\"" +msgstr "" + +#: spell.c:2773 +#, c-format +msgid "Reading spell file \"%s\"" +msgstr "" + +#: spell.c:2805 +msgid "E757: This does not look like a spell file" +msgstr "" + +#: spell.c:2811 +msgid "E771: Old spell file, needs to be updated" +msgstr "" + +#: spell.c:2816 +msgid "E772: Spell file is for newer version of Vim" +msgstr "" + +#: spell.c:2919 +msgid "E770: Unsupported section in spell file" +msgstr "" + +#: spell.c:4320 +#, c-format +msgid "Warning: region %s not supported" +msgstr "" + +#: spell.c:5207 +#, c-format +msgid "Reading affix file %s ..." +msgstr "" + +#: spell.c:5255 +#: spell.c:6599 +#: spell.c:7178 +#, c-format +msgid "Conversion failure for word in %s line %d: %s" +msgstr "" + +#: spell.c:5303 +#: spell.c:7213 +#, c-format +msgid "Conversion in %s not supported: from %s to %s" +msgstr "" + +#: spell.c:5307 +#: spell.c:7218 +#, c-format +msgid "Conversion in %s not supported" +msgstr "" + +#: spell.c:5320 +#, c-format +msgid "Invalid value for FLAG in %s line %d: %s" +msgstr "" + +#: spell.c:5333 +#, c-format +msgid "FLAG after using flags in %s line %d: %s" +msgstr "" + +#: spell.c:5424 +#, c-format +msgid "Defining COMPOUNDFORBIDFLAG after PFX item may give wrong results in %s line %d" +msgstr "" + +#: spell.c:5433 +#, c-format +msgid "Defining COMPOUNDPERMITFLAG after PFX item may give wrong results in %s line %d" +msgstr "" + +#: spell.c:5454 +#, c-format +msgid "Wrong COMPOUNDRULES value in %s line %d: %s" +msgstr "" + +#: spell.c:5481 +#, c-format +msgid "Wrong COMPOUNDWORDMAX value in %s line %d: %s" +msgstr "" + +#: spell.c:5489 +#, c-format +msgid "Wrong COMPOUNDMIN value in %s line %d: %s" +msgstr "" + +#: spell.c:5497 +#, c-format +msgid "Wrong COMPOUNDSYLMAX value in %s line %d: %s" +msgstr "" + +#: spell.c:5519 +#, c-format +msgid "Wrong CHECKCOMPOUNDPATTERN value in %s line %d: %s" +msgstr "" + +#: spell.c:5585 +#, c-format +msgid "Different combining flag in continued affix block in %s line %d: %s" +msgstr "" + +#: spell.c:5588 +#, c-format +msgid "Duplicate affix in %s line %d: %s" +msgstr "" + +#: spell.c:5610 +#, c-format +msgid "Affix also used for BAD/RARE/KEEPCASE/NEEDAFFIX/NEEDCOMPOUND/NOSUGGEST in %s line %d: %s" +msgstr "" + +#: spell.c:5634 +#, c-format +msgid "Expected Y or N in %s line %d: %s" +msgstr "" + +#: spell.c:5718 +#, c-format +msgid "Broken condition in %s line %d: %s" +msgstr "" + +#: spell.c:5866 +#, c-format +msgid "Expected REP(SAL) count in %s line %d" +msgstr "" + +#: spell.c:5901 +#, c-format +msgid "Expected MAP count in %s line %d" +msgstr "" + +#: spell.c:5920 +#, c-format +msgid "Duplicate character in MAP in %s line %d" +msgstr "" + +#: spell.c:5977 +#, c-format +msgid "Unrecognized or duplicate item in %s line %d: %s" +msgstr "" + +#: spell.c:6005 +#, c-format +msgid "Missing FOL/LOW/UPP line in %s" +msgstr "" + +#: spell.c:6031 +msgid "COMPOUNDSYLMAX used without SYLLABLE" +msgstr "" + +#: spell.c:6049 +msgid "Too many postponed prefixes" +msgstr "" + +#: spell.c:6051 +msgid "Too many compound flags" +msgstr "" + +#: spell.c:6053 +msgid "Too many postponed prefixes and/or compound flags" +msgstr "" + +#: spell.c:6065 +#, c-format +msgid "Missing SOFO%s line in %s" +msgstr "" + +#: spell.c:6068 +#, c-format +msgid "Both SAL and SOFO lines in %s" +msgstr "" + +#: spell.c:6175 +#, c-format +msgid "Flag is not a number in %s line %d: %s" +msgstr "" + +#: spell.c:6178 +#, c-format +msgid "Illegal flag in %s line %d: %s" +msgstr "" + +#: spell.c:6395 +#: spell.c:6408 +#, c-format +msgid "%s value differs from what is used in another .aff file" +msgstr "" + +#: spell.c:6560 +#, c-format +msgid "Reading dictionary file %s ..." +msgstr "" + +#: spell.c:6569 +#, c-format +msgid "E760: No word count in %s" +msgstr "" + +#: spell.c:6640 +#, c-format +msgid "line %6d, word %6d - %s" +msgstr "" + +#: spell.c:6664 +#, c-format +msgid "Duplicate word in %s line %d: %s" +msgstr "" + +#: spell.c:6667 +#, c-format +msgid "First duplicate word in %s line %d: %s" +msgstr "" + +#: spell.c:6722 +#, c-format +msgid "%d duplicate word(s) in %s" +msgstr "" + +#: spell.c:6724 +#, c-format +msgid "Ignored %d word(s) with non-ASCII characters in %s" +msgstr "" + +#: spell.c:7147 +#, c-format +msgid "Reading word file %s ..." +msgstr "" + +#: spell.c:7197 +#, c-format +msgid "Duplicate /encoding= line ignored in %s line %d: %s" +msgstr "" + +#: spell.c:7200 +#, c-format +msgid "/encoding= line after word ignored in %s line %d: %s" +msgstr "" + +#: spell.c:7227 +#, c-format +msgid "Duplicate /regions= line ignored in %s line %d: %s" +msgstr "" + +#: spell.c:7233 +#, c-format +msgid "Too many regions in %s line %d: %s" +msgstr "" + +#: spell.c:7247 +#, c-format +msgid "/ line ignored in %s line %d: %s" +msgstr "" + +#: spell.c:7277 +#, c-format +msgid "Invalid region nr in %s line %d: %s" +msgstr "" + +#: spell.c:7285 +#, c-format +msgid "Unrecognized flags in %s line %d: %s" +msgstr "" + +#: spell.c:7315 +#, c-format +msgid "Ignored %d words with non-ASCII characters" +msgstr "" + +#: spell.c:7776 +#, c-format +msgid "Compressed %d of %d nodes; %d (%d%%) remaining" +msgstr "" + +#: spell.c:8567 +msgid "Reading back spell file..." +msgstr "" + +#. +#. * Go through the trie of good words, soundfold each word and add it to +#. * the soundfold trie. +#. +#: spell.c:8588 +msgid "Performing soundfolding..." +msgstr "" + +#: spell.c:8601 +#, c-format +msgid "Number of words after soundfolding: %ld" +msgstr "" + +#: spell.c:8726 +#, c-format +msgid "Total number of words: %d" +msgstr "" + +#: spell.c:8943 +#, c-format +msgid "Writing suggestion file %s ..." +msgstr "" + +#: spell.c:9004 +#: spell.c:9265 +#, c-format +msgid "Estimated runtime memory use: %d bytes" +msgstr "" + +#: spell.c:9136 +msgid "E751: Output file name must not have region name" +msgstr "" + +#: spell.c:9138 +msgid "E754: Only up to 8 regions supported" +msgstr "" + +#: spell.c:9168 +#, c-format +msgid "E755: Invalid region in %s" +msgstr "" + +#: spell.c:9239 +msgid "Warning: both compounding and NOBREAK specified" +msgstr "" + +#: spell.c:9258 +#, c-format +msgid "Writing spell file %s ..." +msgstr "" + +#: spell.c:9263 +msgid "Done!" +msgstr "" + +#: spell.c:9390 +#, c-format +msgid "E765: 'spellfile' does not have %ld entries" +msgstr "" + +#: spell.c:9435 +#, c-format +msgid "Word removed from %s" +msgstr "" + +#: spell.c:9480 +#, c-format +msgid "Word added to %s" +msgstr "" + +#: spell.c:9799 +msgid "E763: Word characters differ between spell files" +msgstr "" + +#: spell.c:10177 +msgid "Sorry, no suggestions" +msgstr "" + +#: spell.c:10181 +#, c-format +msgid "Sorry, only %ld suggestions" +msgstr "" + +#. for when 'cmdheight' > 1 +#. avoid more prompt +#: spell.c:10202 +#, c-format +msgid "Change \"%.*s\" to:" +msgstr "" + +#: spell.c:10242 +#, c-format +msgid " < \"%.*s\"" +msgstr "" + +#: spell.c:10420 +msgid "E752: No previous spell replacement" +msgstr "" + +#: spell.c:10470 +#, c-format +msgid "E753: Not found: %s" +msgstr "" + +#: spell.c:10890 +#, c-format +msgid "E778: This does not look like a .sug file: %s" +msgstr "" + +#: spell.c:10897 +#, c-format +msgid "E779: Old .sug file, needs to be updated: %s" +msgstr "" + +#: spell.c:10903 +#, c-format +msgid "E780: .sug file is for newer version of Vim: %s" +msgstr "" + +#: spell.c:10913 +#, c-format +msgid "E781: .sug file doesn't match .spl file: %s" +msgstr "" + +#: spell.c:10926 +#, c-format +msgid "E782: error while reading .sug file: %s" +msgstr "" + +#. This should have been checked when generating the .spl +#. * file. +#: spell.c:13623 +msgid "E783: duplicate char in MAP entry" +msgstr "" + +#: syntax.c:3321 +#: syntax.c:3346 +#: syntax.c:3372 +#, c-format +msgid "E390: Illegal argument: %s" +msgstr "" + +#: syntax.c:3571 +#, c-format +msgid "E391: No such syntax cluster: %s" +msgstr "" + +#: syntax.c:3730 +msgid "No Syntax items defined for this buffer" +msgstr "" + +#: syntax.c:3738 +msgid "syncing on C-style comments" +msgstr "" + +#: syntax.c:3746 +msgid "no syncing" +msgstr "" + +#: syntax.c:3749 +msgid "syncing starts " +msgstr "" + +#: syntax.c:3751 +#: syntax.c:3827 +msgid " lines before top line" +msgstr "" + +#: syntax.c:3756 +msgid "" +"\n" +"--- Syntax sync items ---" +msgstr "" + +#: syntax.c:3761 +msgid "" +"\n" +"syncing on items" +msgstr "" + +#: syntax.c:3767 +msgid "" +"\n" +"--- Syntax items ---" +msgstr "" + +#: syntax.c:3790 +#, c-format +msgid "E392: No such syntax cluster: %s" +msgstr "" + +#: syntax.c:3817 +msgid "minimal " +msgstr "" + +#: syntax.c:3824 +msgid "maximal " +msgstr "" + +#: syntax.c:3836 +msgid "; match " +msgstr "" + +#: syntax.c:3838 +msgid " line breaks" +msgstr "" + +#: syntax.c:4480 +msgid "E395: contains argument not accepted here" +msgstr "" + +#: syntax.c:4491 +msgid "E396: containedin argument not accepted here" +msgstr "" + +#: syntax.c:4535 +msgid "E393: group[t]here not accepted here" +msgstr "" + +#: syntax.c:4559 +#, c-format +msgid "E394: Didn't find region item for %s" +msgstr "" + +#: syntax.c:4636 +msgid "E397: Filename required" +msgstr "" + +#: syntax.c:4759 +#, c-format +msgid "E789: Missing ']': %s" +msgstr "" + +#: syntax.c:5004 +#, c-format +msgid "E398: Missing '=': %s" +msgstr "" + +#: syntax.c:5166 +#, c-format +msgid "E399: Not enough arguments: syntax region %s" +msgstr "" + +#: syntax.c:5500 +msgid "E400: No cluster specified" +msgstr "" + +#: syntax.c:5537 +#, c-format +msgid "E401: Pattern delimiter not found: %s" +msgstr "" + +#: syntax.c:5612 +#, c-format +msgid "E402: Garbage after pattern: %s" +msgstr "" + +#: syntax.c:5701 +msgid "E403: syntax sync: line continuations pattern specified twice" +msgstr "" + +#: syntax.c:5758 +#, c-format +msgid "E404: Illegal arguments: %s" +msgstr "" + +#: syntax.c:5808 +#, c-format +msgid "E405: Missing equal sign: %s" +msgstr "" + +#: syntax.c:5814 +#, c-format +msgid "E406: Empty argument: %s" +msgstr "" + +#: syntax.c:5840 +#, c-format +msgid "E407: %s not allowed here" +msgstr "" + +#: syntax.c:5847 +#, c-format +msgid "E408: %s must be first in contains list" +msgstr "" + +#: syntax.c:5917 +#, c-format +msgid "E409: Unknown group name: %s" +msgstr "" + +#: syntax.c:6153 +#, c-format +msgid "E410: Invalid :syntax subcommand: %s" +msgstr "" + +#: syntax.c:6702 +msgid "E679: recursive loop loading syncolor.vim" +msgstr "" + +#: syntax.c:6829 +#, c-format +msgid "E411: highlight group not found: %s" +msgstr "" + +#: syntax.c:6853 +#, c-format +msgid "E412: Not enough arguments: \":highlight link %s\"" +msgstr "" + +#: syntax.c:6860 +#, c-format +msgid "E413: Too many arguments: \":highlight link %s\"" +msgstr "" + +#: syntax.c:6880 +msgid "E414: group has settings, highlight link ignored" +msgstr "" + +#: syntax.c:7012 +#, c-format +msgid "E415: unexpected equal sign: %s" +msgstr "" + +#: syntax.c:7048 +#, c-format +msgid "E416: missing equal sign: %s" +msgstr "" + +#: syntax.c:7076 +#, c-format +msgid "E417: missing argument: %s" +msgstr "" + +#: syntax.c:7113 +#, c-format +msgid "E418: Illegal value: %s" +msgstr "" + +#: syntax.c:7232 +msgid "E419: FG color unknown" +msgstr "" + +#: syntax.c:7243 +msgid "E420: BG color unknown" +msgstr "" + +#: syntax.c:7304 +#, c-format +msgid "E421: Color name or number not recognized: %s" +msgstr "" + +#: syntax.c:7537 +#, c-format +msgid "E422: terminal code too long: %s" +msgstr "" + +#: syntax.c:7584 +#, c-format +msgid "E423: Illegal argument: %s" +msgstr "" + +#: syntax.c:8145 +msgid "E424: Too many different highlighting attributes in use" +msgstr "" + +#: syntax.c:8894 +msgid "E669: Unprintable character in group name" +msgstr "" + +#: syntax.c:8903 +msgid "W18: Invalid character in group name" +msgstr "" + +#: tag.c:85 +msgid "E555: at bottom of tag stack" +msgstr "" + +#: tag.c:86 +msgid "E556: at top of tag stack" +msgstr "" + +#: tag.c:435 +msgid "E425: Cannot go before first matching tag" +msgstr "" + +#: tag.c:584 +#, c-format +msgid "E426: tag not found: %s" +msgstr "E426: tag niet gevonden: %s" + +#: tag.c:617 +msgid " # pri kind tag" +msgstr "" + +#: tag.c:620 +msgid "file\n" +msgstr "" + +#: tag.c:954 +msgid "E427: There is only one matching tag" +msgstr "" + +#: tag.c:956 +msgid "E428: Cannot go beyond last matching tag" +msgstr "" + +#: tag.c:980 +#, c-format +msgid "File \"%s\" does not exist" +msgstr "" + +#. Give an indication of the number of matching tags +#: tag.c:992 +#, c-format +msgid "tag %d of %d%s" +msgstr "" + +#: tag.c:995 +msgid " or more" +msgstr "" + +#: tag.c:997 +msgid " Using tag with different case!" +msgstr "" + +#: tag.c:1052 +#, c-format +msgid "E429: File \"%s\" does not exist" +msgstr "" + +#. Highlight title +#: tag.c:1120 +msgid "" +"\n" +" # TO tag FROM line in file/text" +msgstr "" + +#: tag.c:1547 +#, c-format +msgid "Searching tags file %s" +msgstr "" + +#: tag.c:1738 +#, c-format +msgid "E430: Tag file path truncated for %s\n" +msgstr "" + +#: tag.c:2389 +#, c-format +msgid "E431: Format error in tags file \"%s\"" +msgstr "" + +#: tag.c:2393 +#, c-format +msgid "Before byte %ld" +msgstr "" + +#: tag.c:2426 +#, c-format +msgid "E432: Tags file not sorted: %s" +msgstr "" + +#. never opened any tags file +#: tag.c:2470 +msgid "E433: No tags file" +msgstr "E433: geen tags-bestand" + +#: tag.c:2749 +msgid "Ignoring long line in tags file" +msgstr "" + +#: tag.c:3258 +msgid "E434: Can't find tag pattern" +msgstr "" + +#: tag.c:3269 +msgid "E435: Couldn't find tag, just guessing!" +msgstr "" + +#: term.c:1793 +msgid "' not known. Available builtin terminals are:" +msgstr "" + +#: term.c:1817 +msgid "defaulting to '" +msgstr "" + +#: term.c:2172 +msgid "E557: Cannot open termcap file" +msgstr "" + +#: term.c:2176 +msgid "E558: Terminal entry not found in terminfo" +msgstr "" + +#: term.c:2178 +msgid "E559: Terminal entry not found in termcap" +msgstr "" + +#: term.c:2337 +#, c-format +msgid "E436: No \"%s\" entry in termcap" +msgstr "" + +#: term.c:2814 +msgid "E437: terminal capability \"cm\" required" +msgstr "" + +#. Highlight title +#: term.c:5283 +msgid "" +"\n" +"--- Terminal keys ---" +msgstr "" + +#: ui.c:284 +msgid "new shell started\n" +msgstr "" + +#: ui.c:1886 +msgid "Vim: Error reading input, exiting...\n" +msgstr "Vim: lezen van de invoer is mislukt. Stoppen...\n" + +#: ui.c:2409 +msgid "Used CUT_BUFFER0 instead of empty selection" +msgstr "" + +#. must display the prompt +#: undo.c:654 +msgid "No undo possible; continue anyway" +msgstr "" + +#. magic at start of header +#. magic after last header +#. magic at start of entry +#. magic after last entry +#. 2-byte undofile version number +#. idem, encrypted +#: undo.c:675 +#, c-format +msgid "E828: Cannot open undo file for writing: %s" +msgstr "" + +#: undo.c:784 +#, c-format +msgid "E825: Corrupted undo file (%s): %s" +msgstr "" + +#: undo.c:1195 +msgid "Cannot write undo file in any directory in 'undodir'" +msgstr "" + +#: undo.c:1243 +#, c-format +msgid "Will not overwrite with undo file, cannot read: %s" +msgstr "" + +#: undo.c:1265 +#, c-format +msgid "Will not overwrite, this is not an undo file: %s" +msgstr "" + +#: undo.c:1282 +msgid "Skipping undo file write, noting to undo" +msgstr "" + +#: undo.c:1297 +#, c-format +msgid "Writing undo file: %s" +msgstr "" + +#: undo.c:1387 +#, c-format +msgid "E829: write error in undo file: %s" +msgstr "" + +#: undo.c:1467 +#, c-format +msgid "Not reading undo file, owner differs: %s" +msgstr "" + +#: undo.c:1481 +#, c-format +msgid "Reading undo file: %s" +msgstr "" + +#: undo.c:1489 +#, c-format +msgid "E822: Cannot open undo file for reading: %s" +msgstr "" + +#: undo.c:1499 +#, c-format +msgid "E823: Not an undo file: %s" +msgstr "" + +#: undo.c:1508 +#, c-format +msgid "E832: Non-encrypted file has encrypted undo file: %s" +msgstr "" + +#: undo.c:1514 +#, c-format +msgid "E826: Undo file decryption failed: %s" +msgstr "" + +#: undo.c:1518 +#, c-format +msgid "E827: Undo file is encrypted: %s" +msgstr "" + +#: undo.c:1524 +#, c-format +msgid "E824: Incompatible undo file: %s" +msgstr "" + +#: undo.c:1542 +msgid "File contents changed, cannot use undo info" +msgstr "" + +#: undo.c:1707 +#, c-format +msgid "Finished reading undo file %s" +msgstr "" + +#: undo.c:1803 +#: undo.c:2011 +msgid "Already at oldest change" +msgstr "Reeds de laatste wijziging" + +#: undo.c:1818 +#: undo.c:2013 +msgid "Already at newest change" +msgstr "Reeds de nieuwste wijziging" + +#: undo.c:2004 +#, c-format +msgid "E830: Undo number %ld not found" +msgstr "E830: Ongedaan-nummer %ld niet gevonden" + +#: undo.c:2177 +msgid "E438: u_undo: line numbers wrong" +msgstr "E438: u_undo: regelnummers onjuist" + +#: undo.c:2415 +msgid "more line" +msgstr "extra regel" + +#: undo.c:2417 +msgid "more lines" +msgstr "extra regel" + +#: undo.c:2419 +msgid "line less" +msgstr "regel minder" + +#: undo.c:2421 +msgid "fewer lines" +msgstr "regels minder" + +#: undo.c:2426 +msgid "change" +msgstr "wijziging" + +#: undo.c:2428 +msgid "changes" +msgstr "wijzigingen" + +#: undo.c:2452 +#, c-format +msgid "%ld %s; %s #%ld %s" +msgstr "%ld %s; %s #%ld %s" + +#: undo.c:2455 +msgid "before" +msgstr "voor" + +#: undo.c:2455 +msgid "after" +msgstr "na" + +#: undo.c:2562 +msgid "Nothing to undo" +msgstr "Niets om ongedaan te maken" + +#: undo.c:2568 +msgid "number changes time" +msgstr "aantal wijzign tijd" + +#: undo.c:2601 +#, c-format +msgid "%ld seconds ago" +msgstr "%ld seconden geleden" + +#: undo.c:2616 +msgid "E790: undojoin is not allowed after undo" +msgstr "" + +#: undo.c:2666 +msgid "E439: undo list corrupt" +msgstr "" + +#: undo.c:2698 +msgid "E440: undo line missing" +msgstr "" + +#. Only MS VC 4.1 and earlier can do Win32s +#: version.c:775 +msgid "" +"\n" +"MS-Windows 16/32-bit GUI version" +msgstr "" +"\n" +"MS-Windows 16/32-bit GUI-versie" + +#: version.c:778 +msgid "" +"\n" +"MS-Windows 64-bit GUI version" +msgstr "" +"\n" +"MS-Windows 64-bit GUI-versie" + +#: version.c:780 +msgid "" +"\n" +"MS-Windows 32-bit GUI version" +msgstr "" +"\n" +"MS-Windows 32-bit GUIversie" + +#: version.c:784 +msgid " in Win32s mode" +msgstr " in Win32s-modus" + +#: version.c:786 +msgid " with OLE support" +msgstr "met OLE-ondersteuning" + +#: version.c:790 +msgid "" +"\n" +"MS-Windows 64-bit console version" +msgstr "" +"\n" +"MS-Windows 64-bit console-versie" + +#: version.c:792 +msgid "" +"\n" +"MS-Windows 32-bit console version" +msgstr "" +"\n" +"MS-Windows 32-bit console-versie" + +#: version.c:797 +msgid "" +"\n" +"MS-Windows 16-bit version" +msgstr "" +"\n" +"MS-Windows 16-bit-versie" + +#: version.c:801 +msgid "" +"\n" +"32-bit MS-DOS version" +msgstr "" +"\n" +"32-bit MS-DOS-versie" + +#: version.c:803 +msgid "" +"\n" +"16-bit MS-DOS version" +msgstr "" +"\n" +"16-bit MS-DOS-versie" + +#: version.c:809 +msgid "" +"\n" +"MacOS X (unix) version" +msgstr "" +"\n" +"MacOS X (unix)-versie" + +#: version.c:811 +msgid "" +"\n" +"MacOS X-versie" +msgstr "" +"\n" +"MacOS X version" + +#: version.c:814 +msgid "" +"\n" +"MacOS version" +msgstr "" +"\n" +"MacOS-versie" + +#: version.c:819 +msgid "" +"\n" +"RISC OS version" +msgstr "" +"\n" +"RISC OS-versie" + +#: version.c:822 +msgid "" +"\n" +"OpenVMS version" +msgstr "" +"\n" +"OpenVMS-versie" + +#: version.c:837 +msgid "" +"\n" +"Included patches: " +msgstr "" +"\n" +"Inclusief 'patches': " + +#: version.c:864 +msgid "" +"\n" +"Extra patches: " +msgstr "" +"\n" +"Extra 'patches': " + +#: version.c:876 +#: version.c:1240 +msgid "Modified by " +msgstr "Aangepast door " + +#: version.c:883 +msgid "" +"\n" +"Compiled " +msgstr "" +"\n" +"Gecompileerd " + +#: version.c:886 +msgid "by " +msgstr "door " + +#: version.c:898 +msgid "" +"\n" +"Huge version " +msgstr "" +"\n" +"Enorme versie " + +#: version.c:901 +msgid "" +"\n" +"Big version " +msgstr "" +"\n" +"Grote versie " + +#: version.c:904 +msgid "" +"\n" +"Normal version " +msgstr "" +"\n" +"Normale versie " + +#: version.c:907 +msgid "" +"\n" +"Small version " +msgstr "" +"\n" +"Kleine versie " + +#: version.c:909 +msgid "" +"\n" +"Tiny version " +msgstr "" +"\n" +"Mini versie " + +#: version.c:915 +msgid "without GUI." +msgstr "" + +#: version.c:920 +msgid "with GTK2-GNOME GUI." +msgstr "" + +#: version.c:922 +msgid "with GTK-GNOME GUI." +msgstr "" + +#: version.c:926 +msgid "with GTK2 GUI." +msgstr "" + +#: version.c:928 +msgid "with GTK GUI." +msgstr "" + +#: version.c:933 +msgid "with X11-Motif GUI." +msgstr "" + +#: version.c:937 +msgid "with X11-neXtaw GUI." +msgstr "" + +#: version.c:939 +msgid "with X11-Athena GUI." +msgstr "" + +#: version.c:943 +msgid "with Photon GUI." +msgstr "" + +#: version.c:946 +msgid "with GUI." +msgstr "" + +#: version.c:949 +msgid "with Carbon GUI." +msgstr "" + +#: version.c:952 +msgid "with Cocoa GUI." +msgstr "" + +#: version.c:955 +msgid "with (classic) GUI." +msgstr "" + +#: version.c:965 +msgid " Features included (+) or not (-):\n" +msgstr "" + +#: version.c:977 +msgid " system vimrc file: \"" +msgstr "" + +#: version.c:982 +msgid " user vimrc file: \"" +msgstr "" + +#: version.c:987 +msgid " 2nd user vimrc file: \"" +msgstr "" + +#: version.c:992 +msgid " 3rd user vimrc file: \"" +msgstr "" + +#: version.c:997 +msgid " user exrc file: \"" +msgstr "" + +#: version.c:1002 +msgid " 2nd user exrc file: \"" +msgstr "" + +#: version.c:1008 +msgid " system gvimrc file: \"" +msgstr "" + +#: version.c:1012 +msgid " user gvimrc file: \"" +msgstr "" + +#: version.c:1016 +msgid "2nd user gvimrc file: \"" +msgstr "" + +#: version.c:1021 +msgid "3rd user gvimrc file: \"" +msgstr "" + +#: version.c:1028 +msgid " system menu file: \"" +msgstr "" + +#: version.c:1036 +msgid " fall-back for $VIM: \"" +msgstr "" + +#: version.c:1042 +msgid " f-b for $VIMRUNTIME: \"" +msgstr "" + +#: version.c:1046 +msgid "Compilation: " +msgstr "Compilatie: " + +#: version.c:1052 +msgid "Compiler: " +msgstr "Compiler: " + +#: version.c:1057 +msgid "Linking: " +msgstr "Linking: " + +#: version.c:1062 +msgid " DEBUG BUILD" +msgstr " DEBUG BUILD" + +#: version.c:1101 +msgid "VIM - Vi IMproved" +msgstr "VIM - Vi IMproved" + +#: version.c:1103 +msgid "version " +msgstr "versie " + +#: version.c:1104 +msgid "by Bram Moolenaar et al." +msgstr "door Bram Moolenaar en anderen" + +#: version.c:1108 +msgid "Vim is open source and freely distributable" +msgstr "Vim is open-source en vrij verspreidbaar" + +#: version.c:1110 +msgid "Help poor children in Uganda!" +msgstr "Help arme kinderen in Uganda!" + +#: version.c:1111 +msgid "type :help iccf for information " +msgstr "typ :help iccf voor informatie" + +#: version.c:1113 +msgid "type :q to exit" +msgstr "typ :q om te stoppen" + +#: version.c:1114 +msgid "type :help or for on-line help" +msgstr "typ :help of voor on-line hulp" + +#: version.c:1115 +msgid "type :help version7 for version info" +msgstr "typ :help version7 voor versieinformatie" + +#: version.c:1118 +msgid "Running in Vi compatible mode" +msgstr "wordt uitgevoerd in Vi compatible-modus" + +#: version.c:1119 +msgid "type :set nocp for Vim defaults" +msgstr "typ :set nocp voor standaardinstellingen van Vim" + +#: version.c:1120 +msgid "type :help cp-default for info on this" +msgstr "typ :help cp-default voor informatie hierover" + +#: version.c:1135 +msgid "menu Help->Orphans for information " +msgstr "menu Help->Orphans voor informatie" + +#: version.c:1137 +msgid "Running modeless, typed text is inserted" +msgstr "" + +#: version.c:1138 +msgid "menu Edit->Global Settings->Toggle Insert Mode " +msgstr "" + +#: version.c:1139 +msgid " for two modes " +msgstr "" + +#: version.c:1143 +msgid "menu Edit->Global Settings->Toggle Vi Compatible" +msgstr "" + +#: version.c:1144 +msgid " for Vim defaults " +msgstr "" + +#: version.c:1191 +msgid "Sponsor Vim development!" +msgstr "Ondersteun de ontwikkeling van Vim!" + +#: version.c:1192 +msgid "Become a registered Vim user!" +msgstr "Word een geregistreerde Vim-gebruiker!" + +#: version.c:1195 +msgid "type :help sponsor for information " +msgstr "typ :help sponsor voor informatie " + +#: version.c:1196 +msgid "type :help register for information " +msgstr "typ :help register voor informatie " + +#: version.c:1198 +msgid "menu Help->Sponsor/Register for information " +msgstr "menu Help->Sponsor/Register voor informatie " + +#: version.c:1208 +msgid "WARNING: Windows 95/98/ME detected" +msgstr "Waarschuwing: Windows 95/98/ME gedetecteerd" + +#: version.c:1211 +msgid "type :help windows95 for info on this" +msgstr "typ :help windows95 voor informatie hierover" + +#: window.c:88 +msgid "Already only one window" +msgstr "Reeds beperkt tot een venster" + +#: window.c:237 +msgid "E441: There is no preview window" +msgstr "E441: er is geen voorvertoningsvenster" + +#: window.c:672 +msgid "E442: Can't split topleft and botright at the same time" +msgstr "E442: kan linkerbovenzijde en rechteronderzijde niet gelijktijdig splitsen" + +#: window.c:1491 +msgid "E443: Cannot rotate when another window is split" +msgstr "" + +#: window.c:2120 +msgid "E444: Cannot close last window" +msgstr "E444: sluiten laatste venster is mislukt" + +#: window.c:2127 +msgid "E813: Cannot close autocmd window" +msgstr "E813: sluiten autocmd-venster is mislukt" + +#: window.c:2132 +msgid "E814: Cannot close window, only autocmd window would remain" +msgstr "E814: venster kan niet sluiten want autocmd-venster blijft als enige achter" + +#: window.c:3195 +msgid "E445: Other window contains changes" +msgstr "E445: ander venster blijft achter" + +#: window.c:5885 +msgid "E446: No file name under cursor" +msgstr "E446: cursor staat niet op een bestandsnaam" + +#: window.c:6022 +#, c-format +msgid "E447: Can't find file \"%s\" in path" +msgstr "E447: bestand \"%s\" niet in pad gevonden" + +#: if_perl.xs:434 +#: globals.h:1427 +#, c-format +msgid "E370: Could not load library %s" +msgstr "E370: laden van bibliotheek %s is mislukt" + +#: if_perl.xs:685 +msgid "Sorry, this command is disabled: the Perl library could not be loaded." +msgstr "" + +#: if_perl.xs:742 +msgid "E299: Perl evaluation forbidden in sandbox without the Safe module" +msgstr "" + +#: GvimExt/gvimext.cpp:587 +msgid "Edit with &multiple Vims" +msgstr "" + +#: GvimExt/gvimext.cpp:593 +msgid "Edit with single &Vim" +msgstr "" + +#: GvimExt/gvimext.cpp:602 +msgid "Diff with Vim" +msgstr "" + +#: GvimExt/gvimext.cpp:615 +msgid "Edit with &Vim" +msgstr "" + +#. Now concatenate +#: GvimExt/gvimext.cpp:637 +msgid "Edit with existing Vim - " +msgstr "" + +#: GvimExt/gvimext.cpp:752 +msgid "Edits the selected file(s) with Vim" +msgstr "" + +#: GvimExt/gvimext.cpp:891 +#: GvimExt/gvimext.cpp:972 +msgid "Error creating process: Check if gvim is in your path!" +msgstr "" + +#: GvimExt/gvimext.cpp:892 +#: GvimExt/gvimext.cpp:906 +#: GvimExt/gvimext.cpp:973 +msgid "gvimext.dll error" +msgstr "" + +#: GvimExt/gvimext.cpp:905 +msgid "Path length too long!" +msgstr "" + +#: globals.h:1182 +msgid "--No lines in buffer--" +msgstr "-- geen regels in buffer --" + +#. +#. * The error messages that can be shared are included here. +#. * Excluded are errors that are only used once and debugging messages. +#. +#: globals.h:1381 +msgid "E470: Command aborted" +msgstr "E470: opdracht afgebroken" + +#: globals.h:1382 +msgid "E471: Argument required" +msgstr "E471: Argument vereist" + +#: globals.h:1383 +msgid "E10: \\ should be followed by /, ? or &" +msgstr "E10: \\ moet worden gevolgd door /, ? of &" + +#: globals.h:1385 +msgid "E11: Invalid in command-line window; executes, CTRL-C quits" +msgstr "E11: ongeldig in opdrachtregelvenster; voert uit, CTRL-C stopt" + +#: globals.h:1387 +msgid "E12: Command not allowed from exrc/vimrc in current dir or tag search" +msgstr "" + +#: globals.h:1389 +msgid "E171: Missing :endif" +msgstr "" + +#: globals.h:1390 +msgid "E600: Missing :endtry" +msgstr "" + +#: globals.h:1391 +msgid "E170: Missing :endwhile" +msgstr "" + +#: globals.h:1392 +msgid "E170: Missing :endfor" +msgstr "" + +#: globals.h:1393 +msgid "E588: :endwhile without :while" +msgstr "" + +#: globals.h:1394 +msgid "E588: :endfor without :for" +msgstr "" + +#: globals.h:1396 +msgid "E13: File exists (add ! to override)" +msgstr "" + +#: globals.h:1397 +msgid "E472: Command failed" +msgstr "" + +#: globals.h:1399 +#, c-format +msgid "E234: Unknown fontset: %s" +msgstr "" + +#: globals.h:1403 +#, c-format +msgid "E235: Unknown font: %s" +msgstr "" + +#: globals.h:1406 +#, c-format +msgid "E236: Font \"%s\" is not fixed-width" +msgstr "" + +#: globals.h:1408 +msgid "E473: Internal error" +msgstr "E473: interne fout" + +#: globals.h:1409 +msgid "Interrupted" +msgstr "onderbroken" + +#: globals.h:1410 +msgid "E14: Invalid address" +msgstr "E14: ongeldig adres" + +#: globals.h:1411 +msgid "E474: Invalid argument" +msgstr "E474: ongeldig argument" + +#: globals.h:1412 +#, c-format +msgid "E475: Invalid argument: %s" +msgstr "E475: ongeldig argument: %s" + +#: globals.h:1414 +#, c-format +msgid "E15: Invalid expression: %s" +msgstr "E15: ongeldige expressie: %s" + +#: globals.h:1416 +msgid "E16: Invalid range" +msgstr "E16: ongeldig bereik" + +#: globals.h:1417 +msgid "E476: Invalid command" +msgstr "E476: ongeldige opdracht" + +#: globals.h:1419 +#, c-format +msgid "E17: \"%s\" is a directory" +msgstr "" + +#: globals.h:1422 +#, c-format +msgid "E364: Library call failed for \"%s()\"" +msgstr "" + +#: globals.h:1428 +#, c-format +msgid "E448: Could not load library function %s" +msgstr "" + +#: globals.h:1430 +msgid "E19: Mark has invalid line number" +msgstr "E19: markering heeft een ongeldig regelnummer" + +#: globals.h:1431 +msgid "E20: Mark not set" +msgstr "E20: Markering is niet ingesteld" + +#: globals.h:1432 +msgid "E21: Cannot make changes, 'modifiable' is off" +msgstr "E21: kan geen veranderingen maken, 'modifiable' is uitgeschakeld" + +#: globals.h:1433 +msgid "E22: Scripts nested too deep" +msgstr "E22: scripts " + +#: globals.h:1434 +msgid "E23: No alternate file" +msgstr "" + +#: globals.h:1435 +msgid "E24: No such abbreviation" +msgstr "" + +#: globals.h:1436 +msgid "E477: No ! allowed" +msgstr "" + +#: globals.h:1438 +msgid "E25: GUI cannot be used: Not enabled at compile time" +msgstr "" + +#: globals.h:1441 +msgid "E26: Hebrew cannot be used: Not enabled at compile time\n" +msgstr "" + +#: globals.h:1444 +msgid "E27: Farsi cannot be used: Not enabled at compile time\n" +msgstr "" + +#: globals.h:1447 +msgid "E800: Arabic cannot be used: Not enabled at compile time\n" +msgstr "" + +#: globals.h:1450 +#, c-format +msgid "E28: No such highlight group name: %s" +msgstr "E28: naam van deze oplichtgroep is onbekend: %s" + +#: globals.h:1452 +msgid "E29: No inserted text yet" +msgstr "" + +#: globals.h:1453 +msgid "E30: No previous command line" +msgstr "" + +#: globals.h:1454 +msgid "E31: No such mapping" +msgstr "" + +#: globals.h:1455 +msgid "E479: No match" +msgstr "E479: geen overeenkomst" + +#: globals.h:1456 +#, c-format +msgid "E480: No match: %s" +msgstr "E480: geen overeenkomst: %s" + +#: globals.h:1457 +msgid "E32: No file name" +msgstr "E32: geen bestandsnaam" + +#: globals.h:1458 +msgid "E33: No previous substitute regular expression" +msgstr "E33: geen eerdere reguliere expressie substitutie" + +#: globals.h:1459 +msgid "E34: No previous command" +msgstr "E34: geen eerdere opdracht" + +#: globals.h:1460 +msgid "E35: No previous regular expression" +msgstr "E35: geen eerdere reguliere expressie" + +#: globals.h:1461 +msgid "E481: No range allowed" +msgstr "E481: een bereik is niet toegestaan" + +#: globals.h:1463 +msgid "E36: Not enough room" +msgstr "E36: onvoldoende ruimte" + +#: globals.h:1466 +#, c-format +msgid "E247: no registered server named \"%s\"" +msgstr "E247: \"%s\" niet gevonden als geregistreerde server" + +#: globals.h:1468 +#, c-format +msgid "E482: Can't create file %s" +msgstr "E482: aanmaken bestand %s is mislukt" + +#: globals.h:1469 +msgid "E483: Can't get temp file name" +msgstr "E483: bepalen naam tijdelijk bestand is mislukt" + +#: globals.h:1470 +#, c-format +msgid "E484: Can't open file %s" +msgstr "E484: openen bestand %s is mislukt" + +#: globals.h:1471 +#, c-format +msgid "E485: Can't read file %s" +msgstr "E485: lezen bestand %s is mislukt" + +#: globals.h:1472 +msgid "E37: No write since last change (add ! to override)" +msgstr "E37: niets opgeslagen sinds laatste wijziging (voeg ! toe om te forceren)" + +#: globals.h:1473 +msgid "E38: Null argument" +msgstr "E38: leeg argument (null)" + +#: globals.h:1475 +msgid "E39: Number expected" +msgstr "E39: getal verwacht" + +#: globals.h:1478 +#, c-format +msgid "E40: Can't open errorfile %s" +msgstr "E40: openen foutenbestand %s is mislukt" + +#: globals.h:1481 +msgid "E233: cannot open display" +msgstr "E233: openen scherm is mislukt" + +#: globals.h:1483 +msgid "E41: Out of memory!" +msgstr "E41: te weinig geheugen!" + +#: globals.h:1485 +msgid "Pattern not found" +msgstr "patroon niet gevonden" + +#: globals.h:1487 +#, c-format +msgid "E486: Pattern not found: %s" +msgstr "E486: patroon niet gevonden: %s" + +#: globals.h:1488 +msgid "E487: Argument must be positive" +msgstr "E487: argument moet positief zijn" + +#: globals.h:1490 +msgid "E459: Cannot go back to previous directory" +msgstr "E459: kan niet terug naar vorig Dictionary" + +#: globals.h:1494 +msgid "E42: No Errors" +msgstr "E42: geen fouten" + +#: globals.h:1495 +msgid "E776: No location list" +msgstr "" + +#: globals.h:1497 +msgid "E43: Damaged match string" +msgstr "E43: beschadigde zoekstring" + +#: globals.h:1498 +msgid "E44: Corrupted regexp program" +msgstr "E44: regexp-programma is misvormd" + +#: globals.h:1499 +msgid "E45: 'readonly' option is set (add ! to override)" +msgstr "E45: 'alleen-lezen'-optie is ingeschakeld (voeg ! toe om te overschrijven)" + +#: globals.h:1501 +#, c-format +msgid "E46: Cannot change read-only variable \"%s\"" +msgstr "E46: kan alleen-lezenvariabele \"%s\" niet veranderen" + +#: globals.h:1502 +#, c-format +msgid "E794: Cannot set variable in the sandbox: \"%s\"" +msgstr "E794: kan variabele niet instellen in de zandbak: \"%s\"" + +#: globals.h:1505 +msgid "E47: Error while reading errorfile" +msgstr "E47: fout tijdens lezen foutenbestand" + +#: globals.h:1508 +msgid "E48: Not allowed in sandbox" +msgstr "E48: niet toegestaan in zandbak" + +#: globals.h:1510 +msgid "E523: Not allowed here" +msgstr "E523: hier niet toegestaan" + +#: globals.h:1513 +msgid "E359: Screen mode setting not supported" +msgstr "E359: instelling schermmodus niet ondersteund" + +#: globals.h:1515 +msgid "E49: Invalid scroll size" +msgstr "E49: ongeldige scroll-grootte" + +#: globals.h:1516 +msgid "E91: 'shell' option is empty" +msgstr "E91: 'shell'-optie is leeg" + +#: globals.h:1518 +msgid "E255: Couldn't read in sign data!" +msgstr "" + +#: globals.h:1520 +msgid "E72: Close error on swap file" +msgstr "" + +#: globals.h:1521 +msgid "E73: tag stack empty" +msgstr "" + +#: globals.h:1522 +msgid "E74: Command too complex" +msgstr "E74: opdracht te ingewikkeld" + +#: globals.h:1523 +msgid "E75: Name too long" +msgstr "E75: te lange naam" + +#: globals.h:1524 +msgid "E76: Too many [" +msgstr "E76: teveel [" + +#: globals.h:1525 +msgid "E77: Too many file names" +msgstr "E77: teveel bestandsnamen" + +#: globals.h:1526 +msgid "E488: Trailing characters" +msgstr "E488: nakomende tekens" + +#: globals.h:1527 +msgid "E78: Unknown mark" +msgstr "E78: onbekende markering" + +#: globals.h:1528 +msgid "E79: Cannot expand wildcards" +msgstr "E79: vervangen jokertekens is mislukt" + +#: globals.h:1530 +msgid "E591: 'winheight' cannot be smaller than 'winminheight'" +msgstr "E591: 'winheight' kan niet kleiner zijn dan 'winminheight'" + +#: globals.h:1532 +msgid "E592: 'winwidth' cannot be smaller than 'winminwidth'" +msgstr "E592: 'winwidth' kan niet kleiner zijn dan 'winminwidth'" + +#: globals.h:1535 +msgid "E80: Error while writing" +msgstr "E80: opslaan is mislukt" + +#: globals.h:1536 +msgid "Zero count" +msgstr "Aantal is nul" + +#: globals.h:1538 +msgid "E81: Using not in a script context" +msgstr "E81: wordt buiten de scriptcontext gebruikt" + +#: globals.h:1541 +msgid "E449: Invalid expression received" +msgstr "E449: ontvangen expressie is ongeldig" + +#: globals.h:1544 +msgid "E463: Region is guarded, cannot modify" +msgstr "E463: Regio is bescherm en kan niet worden veranderd" + +#: globals.h:1545 +msgid "E744: NetBeans does not allow changes in read-only files" +msgstr "E744: NetBeans staat geen veranderingen in alleen-lezenbestanden toe" + +#: globals.h:1547 +#, c-format +msgid "E685: Internal error: %s" +msgstr "E685: interne fout: %s" + +#: globals.h:1548 +msgid "E363: pattern uses more memory than 'maxmempattern'" +msgstr "E363: patroon gebruikt meer geheugen dan 'maxmempattern'" + +#: globals.h:1549 +msgid "E749: empty buffer" +msgstr "E749: leeg buffer" + +#: globals.h:1552 +msgid "E682: Invalid search pattern or delimiter" +msgstr "E682: zoekpatroon of scheidingsteken is ongeldig" + +#: globals.h:1554 +msgid "E139: File is loaded in another buffer" +msgstr "E139: bestand is in een ander buffer geladen" + +#: globals.h:1557 +#, c-format +msgid "E764: Option '%s' is not set" +msgstr "E764: Optie '%s' is niet ingesteld" + +#: globals.h:1564 +msgid "search hit TOP, continuing at BOTTOM" +msgstr "zoeken bereikte TOP, verder vanaf BODEM" + +#: globals.h:1565 +msgid "search hit BOTTOM, continuing at TOP" +msgstr "zoeken bereikte BODEM, verder vanaf TOP" + diff --git a/vim.spec b/vim.spec index ae40afc7..af2a1c29 100644 --- a/vim.spec +++ b/vim.spec @@ -42,6 +42,7 @@ Source13: vim-spell-files.tar.bz2 %endif Source14: spec-template Source15: spec-template.new +Source16: nl.po Patch2002: vim-7.0-fixkeys.patch Patch2003: vim-6.2-specsyntax.patch @@ -1793,6 +1794,7 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %build cp -f %{SOURCE5} . +cp -f %{SOURCE16} src/po/ cd src autoconf @@ -2080,6 +2082,7 @@ rm -rf $RPM_BUILD_ROOT %lang(af) %{_datadir}/%{name}/%{vimdir}/lang/af %lang(ca) %{_datadir}/%{name}/%{vimdir}/lang/ca %lang(cs) %{_datadir}/%{name}/%{vimdir}/lang/cs +%lang(cs.cp1250) %{_datadir}/%{name}/%{vimdir}/lang/cs.cp1250 %lang(de) %{_datadir}/%{name}/%{vimdir}/lang/de %lang(en_GB) %{_datadir}/%{name}/%{vimdir}/lang/en_GB %lang(eo) %{_datadir}/%{name}/%{vimdir}/lang/eo @@ -2089,18 +2092,26 @@ rm -rf $RPM_BUILD_ROOT %lang(ga) %{_datadir}/%{name}/%{vimdir}/lang/ga %lang(it) %{_datadir}/%{name}/%{vimdir}/lang/it %lang(ja) %{_datadir}/%{name}/%{vimdir}/lang/ja +%lang(ja.sjis) %{_datadir}/%{name}/%{vimdir}/lang/ja.sjis %lang(ko) %{_datadir}/%{name}/%{vimdir}/lang/ko %lang(ko) %{_datadir}/%{name}/%{vimdir}/lang/ko.UTF-8 %lang(nb) %{_datadir}/%{name}/%{vimdir}/lang/nb +%lang(nl) %{_datadir}/%{name}/%{vimdir}/lang/nl %lang(no) %{_datadir}/%{name}/%{vimdir}/lang/no %lang(pl) %{_datadir}/%{name}/%{vimdir}/lang/pl +%lang(pl.UTF-8) %{_datadir}/%{name}/%{vimdir}/lang/pl.UTF-8 +%lang(pl.cp1250) %{_datadir}/%{name}/%{vimdir}/lang/pl.cp1250 %lang(pt_BR) %{_datadir}/%{name}/%{vimdir}/lang/pt_BR %lang(ru) %{_datadir}/%{name}/%{vimdir}/lang/ru +%lang(ru.cp1251) %{_datadir}/%{name}/%{vimdir}/lang/ru.cp1251 %lang(sk) %{_datadir}/%{name}/%{vimdir}/lang/sk +%lang(sk.cp1250) %{_datadir}/%{name}/%{vimdir}/lang/sk.cp1250 %lang(sv) %{_datadir}/%{name}/%{vimdir}/lang/sv %lang(uk) %{_datadir}/%{name}/%{vimdir}/lang/uk +%lang(uk.cp1251) %{_datadir}/%{name}/%{vimdir}/lang/uk.cp1251 %lang(vi) %{_datadir}/%{name}/%{vimdir}/lang/vi %lang(zh_CN) %{_datadir}/%{name}/%{vimdir}/lang/zh_CN +%lang(zh_CN.cp936) %{_datadir}/%{name}/%{vimdir}/lang/zh_CN.cp936 %lang(zh_TW) %{_datadir}/%{name}/%{vimdir}/lang/zh_TW %lang(zh_CN.UTF-8) %{_datadir}/%{name}/%{vimdir}/lang/zh_CN.UTF-8 %lang(zh_TW.UTF-8) %{_datadir}/%{name}/%{vimdir}/lang/zh_TW.UTF-8 From 402e05d61c48fcacaa4f5451dbce62f42f3407fe Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 31 Jan 2013 12:11:55 +0100 Subject: [PATCH 0668/3340] - patchlevel 786 --- 7.3.786 | 93 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 93 insertions(+) create mode 100644 7.3.786 diff --git a/7.3.786 b/7.3.786 new file mode 100644 index 00000000..a6988219 --- /dev/null +++ b/7.3.786 @@ -0,0 +1,93 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.786 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.786 +Problem: Python threads don't run in the background (issue 103). +Solution: Move the statements to manipulate thread state. +Files: src/if_python.c + + +*** ../vim-7.3.785/src/if_python.c 2012-10-21 01:46:56.000000000 +0200 +--- src/if_python.c 2013-01-30 11:38:06.000000000 +0100 +*************** +*** 740,751 **** + #else + PyMac_Initialize(); + #endif +! /* Initialise threads, and save the state using PyGILState_Ensure. +! * Without the call to PyGILState_Ensure, thread specific state (such +! * as the system trace hook), will be lost between invocations of +! * Python code. */ + PyEval_InitThreads(); +- pygilstate = PyGILState_Ensure(); + #ifdef DYNAMIC_PYTHON + get_exceptions(); + #endif +--- 740,750 ---- + #else + PyMac_Initialize(); + #endif +! /* Initialise threads, and below save the state using +! * PyGILState_Ensure. Without the call to PyGILState_Ensure, thread +! * specific state (such as the system trace hook), will be lost +! * between invocations of Python code. */ + PyEval_InitThreads(); + #ifdef DYNAMIC_PYTHON + get_exceptions(); + #endif +*************** +*** 756,761 **** +--- 755,764 ---- + if (PythonMod_Init()) + goto fail; + ++ /* The first python thread is vim's, release the lock. */ ++ Python_SaveThread(); ++ pygilstate = PyGILState_Ensure(); ++ + globals = PyModule_GetDict(PyImport_AddModule("__main__")); + + /* Remove the element from sys.path that was added because of our +*************** +*** 764,771 **** + * the current directory in sys.path. */ + PyRun_SimpleString("import sys; sys.path = filter(lambda x: x != '/must>not&exist', sys.path)"); + +! /* the first python thread is vim's, release the lock */ +! Python_SaveThread(); + + initialised = 1; + } +--- 767,773 ---- + * the current directory in sys.path. */ + PyRun_SimpleString("import sys; sys.path = filter(lambda x: x != '/must>not&exist', sys.path)"); + +! PyGILState_Release(pygilstate); + + initialised = 1; + } +*** ../vim-7.3.785/src/version.c 2013-01-25 20:10:58.000000000 +0100 +--- src/version.c 2013-01-30 11:44:04.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 786, + /**/ + +-- +ARTHUR: I command you as King of the Britons to stand aside! +BLACK KNIGHT: I move for no man. + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e26d45efd4d30e04dbc00f4a417bbcf76985542f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 31 Jan 2013 12:11:56 +0100 Subject: [PATCH 0669/3340] - patchlevel 787 --- 7.3.787 | 161 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 161 insertions(+) create mode 100644 7.3.787 diff --git a/7.3.787 b/7.3.787 new file mode 100644 index 00000000..0d705c73 --- /dev/null +++ b/7.3.787 @@ -0,0 +1,161 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.787 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.787 +Problem: With 'relativenumber' set it is not possible to see the absolute + line number. +Solution: For the cursor line show the absolute line number instead of a + zero. (Nazri Ramliy) +Files: src/screen.c + + +*** ../vim-7.3.786/src/screen.c 2012-12-05 16:10:21.000000000 +0100 +--- src/screen.c 2013-01-30 12:29:33.000000000 +0100 +*************** +*** 2319,2324 **** +--- 2319,2325 ---- + { + int w = number_width(wp); + long num; ++ char *fmt = "%*ld "; + + if (len > w + 1) + len = w + 1; +*************** +*** 2327,2336 **** + /* 'number' */ + num = (long)lnum; + else + /* 'relativenumber', don't use negative numbers */ + num = labs((long)get_cursor_rel_lnum(wp, lnum)); + +! sprintf((char *)buf, "%*ld ", w, num); + #ifdef FEAT_RIGHTLEFT + if (wp->w_p_rl) + /* the line number isn't reversed */ +--- 2328,2344 ---- + /* 'number' */ + num = (long)lnum; + else ++ { + /* 'relativenumber', don't use negative numbers */ + num = labs((long)get_cursor_rel_lnum(wp, lnum)); ++ if (num == 0) ++ { ++ num = lnum; ++ fmt = "%-*ld "; ++ } ++ } + +! sprintf((char *)buf, fmt, w, num); + #ifdef FEAT_RIGHTLEFT + if (wp->w_p_rl) + /* the line number isn't reversed */ +*************** +*** 3484,3498 **** + ) + { + long num; + + if (wp->w_p_nu) + /* 'number' */ + num = (long)lnum; + else + /* 'relativenumber', don't use negative numbers */ + num = labs((long)get_cursor_rel_lnum(wp, lnum)); + +! sprintf((char *)extra, "%*ld ", + number_width(wp), num); + if (wp->w_skipcol > 0) + for (p_extra = extra; *p_extra == ' '; ++p_extra) +--- 3492,3514 ---- + ) + { + long num; ++ char *fmt = "%*ld "; + + if (wp->w_p_nu) + /* 'number' */ + num = (long)lnum; + else ++ { + /* 'relativenumber', don't use negative numbers */ + num = labs((long)get_cursor_rel_lnum(wp, lnum)); ++ if (num == 0) ++ { ++ num = lnum; ++ fmt = "%-*ld "; ++ } ++ } + +! sprintf((char *)extra, fmt, + number_width(wp), num); + if (wp->w_skipcol > 0) + for (p_extra = extra; *p_extra == ' '; ++p_extra) +*************** +*** 3513,3519 **** + * the current line differently. + * TODO: Can we use CursorLine instead of CursorLineNr + * when CursorLineNr isn't set? */ +! if (wp->w_p_cul && lnum == wp->w_cursor.lnum) + char_attr = hl_attr(HLF_CLN); + #endif + } +--- 3529,3536 ---- + * the current line differently. + * TODO: Can we use CursorLine instead of CursorLineNr + * when CursorLineNr isn't set? */ +! if ((wp->w_p_cul || wp->w_p_rnu) +! && lnum == wp->w_cursor.lnum) + char_attr = hl_attr(HLF_CLN); + #endif + } +*************** +*** 10238,10249 **** + int n; + linenr_T lnum; + +! if (wp->w_p_nu) +! /* 'number' */ +! lnum = wp->w_buffer->b_ml.ml_line_count; +! else +! /* 'relativenumber' */ +! lnum = wp->w_height; + + if (lnum == wp->w_nrwidth_line_count) + return wp->w_nrwidth_width; +--- 10255,10261 ---- + int n; + linenr_T lnum; + +! lnum = wp->w_buffer->b_ml.ml_line_count; + + if (lnum == wp->w_nrwidth_line_count) + return wp->w_nrwidth_width; +*** ../vim-7.3.786/src/version.c 2013-01-30 11:44:33.000000000 +0100 +--- src/version.c 2013-01-30 12:25:10.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 787, + /**/ + +-- +ARTHUR: A scratch? Your arm's off! +BLACK KNIGHT: No, it isn't. +ARTHUR: Well, what's that then? +BLACK KNIGHT: I've had worse. + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9109f2c58a052d28942cd4b730bba5fecc368c20 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 31 Jan 2013 12:11:56 +0100 Subject: [PATCH 0670/3340] - patchlevel 788 --- 7.3.788 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.788 diff --git a/7.3.788 b/7.3.788 new file mode 100644 index 00000000..99c08ce0 --- /dev/null +++ b/7.3.788 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.788 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.788 +Problem: When only using patches build fails on missing nl.po. +Solution: Create an empty nl.po file. +Files: src/po/Makefile + + +*** ../vim-7.3.787/src/po/Makefile 2013-01-17 13:35:13.000000000 +0100 +--- src/po/Makefile 2013-01-30 12:50:41.000000000 +0100 +*************** +*** 176,181 **** +--- 176,185 ---- + + converted: $(MOCONVERTED) + ++ # nl.po was added later, if it does not exist use an empty file. ++ nl.po: ++ touch nl.po ++ + # Norwegian/Bokmal: "nb" is an alias for "no". + # Copying the file is not efficient, but I don't know of another way to make + # this work. +*** ../vim-7.3.787/src/version.c 2013-01-30 12:31:32.000000000 +0100 +--- src/version.c 2013-01-30 12:45:32.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 788, + /**/ + +-- +"It's so simple to be wise. Just think of something stupid to say +and then don't say it." -- Sam Levenson + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6eaecdf60a7a93dc90fd9e89d632b3ea339bf330 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 31 Jan 2013 12:11:57 +0100 Subject: [PATCH 0671/3340] - patchlevel 789 --- 7.3.789 | 185 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 185 insertions(+) create mode 100644 7.3.789 diff --git a/7.3.789 b/7.3.789 new file mode 100644 index 00000000..d935b785 --- /dev/null +++ b/7.3.789 @@ -0,0 +1,185 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.789 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.789 (after 7.3.776) +Problem: "\k" in regexp does not work in other window. +Solution: Use the right buffer. (Yukihiro Nakadaira) +Files: src/mbyte.c, src/proto/mbyte.pro, src/regexp.c + + +*** ../vim-7.3.788/src/mbyte.c 2013-01-23 16:19:17.000000000 +0100 +--- src/mbyte.c 2013-01-30 13:53:07.000000000 +0100 +*************** +*** 869,879 **** + mb_get_class(p) + char_u *p; + { + if (MB_BYTE2LEN(p[0]) == 1) + { + if (p[0] == NUL || vim_iswhite(p[0])) + return 0; +! if (vim_iswordc(p[0])) + return 2; + return 1; + } +--- 869,887 ---- + mb_get_class(p) + char_u *p; + { ++ return mb_get_class_buf(p, curbuf); ++ } ++ ++ int ++ mb_get_class_buf(p, buf) ++ char_u *p; ++ buf_T *buf; ++ { + if (MB_BYTE2LEN(p[0]) == 1) + { + if (p[0] == NUL || vim_iswhite(p[0])) + return 0; +! if (vim_iswordc_buf(p[0], buf)) + return 2; + return 1; + } +*** ../vim-7.3.788/src/proto/mbyte.pro 2011-08-10 13:21:30.000000000 +0200 +--- src/proto/mbyte.pro 2013-01-30 13:53:27.000000000 +0100 +*************** +*** 4,9 **** +--- 4,10 ---- + int bomb_size __ARGS((void)); + void remove_bom __ARGS((char_u *s)); + int mb_get_class __ARGS((char_u *p)); ++ int mb_get_class_buf __ARGS((char_u *p, buf_T *buf)); + int dbcs_class __ARGS((unsigned lead, unsigned trail)); + int latin_char2len __ARGS((int c)); + int latin_char2bytes __ARGS((int c, char_u *buf)); +*** ../vim-7.3.788/src/regexp.c 2013-01-25 20:10:58.000000000 +0100 +--- src/regexp.c 2013-01-30 13:55:39.000000000 +0100 +*************** +*** 4013,4020 **** + reg_prev_class() + { + if (reginput > regline) +! return mb_get_class(reginput - 1 +! - (*mb_head_off)(regline, reginput - 1)); + return -1; + } + +--- 4013,4020 ---- + reg_prev_class() + { + if (reginput > regline) +! return mb_get_class_buf(reginput - 1 +! - (*mb_head_off)(regline, reginput - 1), reg_buf); + return -1; + } + +*************** +*** 4304,4310 **** + int this_class; + + /* Get class of current and previous char (if it exists). */ +! this_class = mb_get_class(reginput); + if (this_class <= 1) + status = RA_NOMATCH; /* not on a word at all */ + else if (reg_prev_class() == this_class) +--- 4304,4310 ---- + int this_class; + + /* Get class of current and previous char (if it exists). */ +! this_class = mb_get_class_buf(reginput, reg_buf); + if (this_class <= 1) + status = RA_NOMATCH; /* not on a word at all */ + else if (reg_prev_class() == this_class) +*************** +*** 4328,4334 **** + int this_class, prev_class; + + /* Get class of current and previous char (if it exists). */ +! this_class = mb_get_class(reginput); + prev_class = reg_prev_class(); + if (this_class == prev_class + || prev_class == 0 || prev_class == 1) +--- 4328,4334 ---- + int this_class, prev_class; + + /* Get class of current and previous char (if it exists). */ +! this_class = mb_get_class_buf(reginput, reg_buf); + prev_class = reg_prev_class(); + if (this_class == prev_class + || prev_class == 0 || prev_class == 1) +*************** +*** 4365,4378 **** + break; + + case KWORD: +! if (!vim_iswordp(reginput)) + status = RA_NOMATCH; + else + ADVANCE_REGINPUT(); + break; + + case SKWORD: +! if (VIM_ISDIGIT(*reginput) || !vim_iswordp(reginput)) + status = RA_NOMATCH; + else + ADVANCE_REGINPUT(); +--- 4365,4378 ---- + break; + + case KWORD: +! if (!vim_iswordp_buf(reginput, reg_buf)) + status = RA_NOMATCH; + else + ADVANCE_REGINPUT(); + break; + + case SKWORD: +! if (VIM_ISDIGIT(*reginput) || !vim_iswordp_buf(reginput, reg_buf)) + status = RA_NOMATCH; + else + ADVANCE_REGINPUT(); +*************** +*** 5734,5740 **** + case SKWORD + ADD_NL: + while (count < maxcount) + { +! if (vim_iswordp(scan) && (testval || !VIM_ISDIGIT(*scan))) + { + mb_ptr_adv(scan); + } +--- 5734,5741 ---- + case SKWORD + ADD_NL: + while (count < maxcount) + { +! if (vim_iswordp_buf(scan, reg_buf) +! && (testval || !VIM_ISDIGIT(*scan))) + { + mb_ptr_adv(scan); + } +*** ../vim-7.3.788/src/version.c 2013-01-30 12:50:50.000000000 +0100 +--- src/version.c 2013-01-30 13:58:07.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 789, + /**/ + +-- +MARTHA'S WAY: Don't throw out all that leftover wine. Freeze into ice cubes + for future use in casseroles and sauces. +MY WAY: What leftover wine? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 69fe8f3e3a7c31a2e304747e14806b54a93e6ded Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 31 Jan 2013 12:11:58 +0100 Subject: [PATCH 0672/3340] - patchlevel 790 --- 7.3.790 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.790 diff --git a/7.3.790 b/7.3.790 new file mode 100644 index 00000000..a2bf0c6c --- /dev/null +++ b/7.3.790 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.790 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.790 +Problem: After reloading a buffer the modelines are not processed. +Solution: call do_modelines(). (Ken Takata) +Files: src/fileio.c + + +*** ../vim-7.3.789/src/fileio.c 2012-12-05 19:13:11.000000000 +0100 +--- src/fileio.c 2013-01-30 14:08:21.000000000 +0100 +*************** +*** 7243,7248 **** +--- 7243,7251 ---- + * reset it, might have had a read error. */ + if (orig_mode == curbuf->b_orig_mode) + curbuf->b_p_ro |= old_ro; ++ ++ /* Modelines must override settings done by autocommands. */ ++ do_modelines(0); + } + + /* restore curwin/curbuf and a few other things */ +*** ../vim-7.3.789/src/version.c 2013-01-30 13:59:31.000000000 +0100 +--- src/version.c 2013-01-30 14:02:30.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 790, + /**/ + +-- +BLACK KNIGHT: Come on you pansy! + [hah] [parry thrust] + [ARTHUR chops the BLACK KNIGHT's right arm off] +ARTHUR: Victory is mine! [kneeling] + We thank thee Lord, that in thy merc- + [Black Knight kicks Arthur in the head while he is praying] + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4b8a0ca237023bcddeef06e70b9c347c214373fc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 31 Jan 2013 12:11:59 +0100 Subject: [PATCH 0673/3340] - patchlevel 791 --- 7.3.791 | 2124 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 2124 insertions(+) create mode 100644 7.3.791 diff --git a/7.3.791 b/7.3.791 new file mode 100644 index 00000000..0b984b73 --- /dev/null +++ b/7.3.791 @@ -0,0 +1,2124 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.791 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.791 +Problem: MzScheme interface doesn't work propely. +Solution: Make it work better. (Sergey Khorev) +Files: runtime/doc/if_mzsch.txt, src/configure.in, src/auto/configure, + src/eval.c, src/if_mzsch.c, src/if_mzsch.h, src/Make_ming.mak, + src/Make_mvc.mak, src/os_unix.c, src/proto/eval.pro, + src/testdir/test70.in, src/testdir/test70.ok + + +*** ../vim-7.3.790/runtime/doc/if_mzsch.txt 2010-08-15 21:57:14.000000000 +0200 +--- runtime/doc/if_mzsch.txt 2013-01-30 14:26:44.000000000 +0100 +*************** +*** 11,17 **** + 3. Threads |mzscheme-threads| + 4. Vim access from MzScheme |mzscheme-vim| + 5. mzeval() Vim function |mzscheme-mzeval| +! 6. Dynamic loading |mzscheme-dynamic| + + {Vi does not have any of these commands} + +--- 11,18 ---- + 3. Threads |mzscheme-threads| + 4. Vim access from MzScheme |mzscheme-vim| + 5. mzeval() Vim function |mzscheme-mzeval| +! 6. Using Function references |mzscheme-funcref| +! 7. Dynamic loading |mzscheme-dynamic| + + {Vi does not have any of these commands} + +*************** +*** 21,30 **** + Based on the work of Brent Fulgham. + Dynamic loading added by Sergey Khorev + +! For downloading MzScheme and other info: +! http://www.plt-scheme.org/software/mzscheme/ + +! Note: On FreeBSD you should use the "drscheme" port. + + ============================================================================== + 1. Commands *mzscheme-commands* +--- 22,38 ---- + Based on the work of Brent Fulgham. + Dynamic loading added by Sergey Khorev + +! MzScheme and PLT Scheme names have been rebranded as Racket. For more +! information please check http://racket-lang.org + +! Futures and places of Racket version 5.x up to and including 5.3.1 do not +! work correctly with processes created by Vim. +! The simplest solution is to build Racket on your own with these features +! disabled: > +! ./configure --disable-futures --disable-places --prefix=your-install-prefix +! +! To speed up the process, you might also want to use --disable-gracket and +! --disable-docs + + ============================================================================== + 1. Commands *mzscheme-commands* +*************** +*** 155,162 **** + (eval {expr-string}) Evaluate the vim expression into + respective MzScheme object: |Lists| are + represented as Scheme lists, +! |Dictionaries| as hash tables. +! NOTE the name clashes with MzScheme eval + (range-start) Start/End of the range passed with + (range-end) the Scheme command. + (beep) beep +--- 163,173 ---- + (eval {expr-string}) Evaluate the vim expression into + respective MzScheme object: |Lists| are + represented as Scheme lists, +! |Dictionaries| as hash tables, +! |Funcref|s as functions (see also +! |mzscheme-funcref|) +! NOTE the name clashes with MzScheme eval, +! use module qualifiers to overcome this. + (range-start) Start/End of the range passed with + (range-end) the Scheme command. + (beep) beep +*************** +*** 237,243 **** + evaluate MzScheme expressions and pass their values to VimL. + + ============================================================================== +! 6. Dynamic loading *mzscheme-dynamic* *E815* + + On MS-Windows the MzScheme libraries can be loaded dynamically. The |:version| + output then includes |+mzscheme/dyn|. +--- 248,270 ---- + evaluate MzScheme expressions and pass their values to VimL. + + ============================================================================== +! 6. Using Function references *mzscheme-funcref* +! +! MzScheme interface allows use of |Funcref|s so you can call Vim functions +! directly from Scheme. For instance: > +! function! MyAdd2(arg) +! return a:arg + 2 +! endfunction +! mz (define f2 (vim-eval "function(\"MyAdd2\")")) +! mz (f2 7) +! < or : > +! :mz (define indent (vim-eval "function('indent')")) +! " return Vim indent for line 12 +! :mz (indent 12) +! < +! +! ============================================================================== +! 7. Dynamic loading *mzscheme-dynamic* *E815* + + On MS-Windows the MzScheme libraries can be loaded dynamically. The |:version| + output then includes |+mzscheme/dyn|. +*** ../vim-7.3.790/src/configure.in 2012-12-12 14:25:01.000000000 +0100 +--- src/configure.in 2013-01-30 14:26:44.000000000 +0100 +*************** +*** 617,623 **** + + if test "X$vi_cv_path_mzscheme_pfx" != "X"; then + if test "x$MACOSX" = "xyes"; then +! MZSCHEME_LIBS="-framework PLT_MzScheme" + elif test -f "${vi_cv_path_mzscheme_pfx}/lib/libmzscheme3m.a"; then + MZSCHEME_LIBS="${vi_cv_path_mzscheme_pfx}/lib/libmzscheme3m.a" + MZSCHEME_CFLAGS="-DMZ_PRECISE_GC" +--- 617,624 ---- + + if test "X$vi_cv_path_mzscheme_pfx" != "X"; then + if test "x$MACOSX" = "xyes"; then +! MZSCHEME_LIBS="-framework Racket" +! MZSCHEME_CFLAGS="-DMZ_PRECISE_GC" + elif test -f "${vi_cv_path_mzscheme_pfx}/lib/libmzscheme3m.a"; then + MZSCHEME_LIBS="${vi_cv_path_mzscheme_pfx}/lib/libmzscheme3m.a" + MZSCHEME_CFLAGS="-DMZ_PRECISE_GC" +*************** +*** 660,665 **** +--- 661,670 ---- + else + if test -d $vi_cv_path_mzscheme_pfx/share/racket/collects; then + SCHEME_COLLECTS=$vi_cv_path_mzscheme_pfx/share/racket/ ++ else ++ if test -d $vi_cv_path_mzscheme_pfx/collects; then ++ SCHEME_COLLECTS=$vi_cv_path_mzscheme_pfx/ ++ fi + fi + fi + fi +*** ../vim-7.3.790/src/auto/configure 2012-12-12 14:25:01.000000000 +0100 +--- src/auto/configure 2013-01-30 14:27:31.000000000 +0100 +*************** +*** 4927,4933 **** + + if test "X$vi_cv_path_mzscheme_pfx" != "X"; then + if test "x$MACOSX" = "xyes"; then +! MZSCHEME_LIBS="-framework PLT_MzScheme" + elif test -f "${vi_cv_path_mzscheme_pfx}/lib/libmzscheme3m.a"; then + MZSCHEME_LIBS="${vi_cv_path_mzscheme_pfx}/lib/libmzscheme3m.a" + MZSCHEME_CFLAGS="-DMZ_PRECISE_GC" +--- 4927,4934 ---- + + if test "X$vi_cv_path_mzscheme_pfx" != "X"; then + if test "x$MACOSX" = "xyes"; then +! MZSCHEME_LIBS="-framework Racket" +! MZSCHEME_CFLAGS="-DMZ_PRECISE_GC" + elif test -f "${vi_cv_path_mzscheme_pfx}/lib/libmzscheme3m.a"; then + MZSCHEME_LIBS="${vi_cv_path_mzscheme_pfx}/lib/libmzscheme3m.a" + MZSCHEME_CFLAGS="-DMZ_PRECISE_GC" +*************** +*** 4968,4973 **** +--- 4969,4978 ---- + else + if test -d $vi_cv_path_mzscheme_pfx/share/racket/collects; then + SCHEME_COLLECTS=$vi_cv_path_mzscheme_pfx/share/racket/ ++ else ++ if test -d $vi_cv_path_mzscheme_pfx/collects; then ++ SCHEME_COLLECTS=$vi_cv_path_mzscheme_pfx/ ++ fi + fi + fi + fi +*** ../vim-7.3.790/src/eval.c 2013-01-23 17:15:25.000000000 +0100 +--- src/eval.c 2013-01-30 14:33:00.000000000 +0100 +*************** +*** 14333,14338 **** +--- 14333,14354 ---- + str = get_tv_string_buf(&argvars[0], buf); + do_mzeval(str, rettv); + } ++ ++ void ++ mzscheme_call_vim(name, args, rettv) ++ char_u *name; ++ typval_T *args; ++ typval_T *rettv; ++ { ++ typval_T argvars[3]; ++ ++ argvars[0].v_type = VAR_STRING; ++ argvars[0].vval.v_string = name; ++ copy_tv(args, &argvars[1]); ++ argvars[2].v_type = VAR_UNKNOWN; ++ f_call(argvars, rettv); ++ clear_tv(&argvars[1]); ++ } + #endif + + /* +*** ../vim-7.3.790/src/if_mzsch.c 2012-11-28 15:37:46.000000000 +0100 +--- src/if_mzsch.c 2013-01-30 14:34:37.000000000 +0100 +*************** +*** 1,11 **** + /* vi:set ts=8 sts=4 sw=4: + * + * MzScheme interface by Sergey Khorev +! * Original work by Brent Fulgham + * (Based on lots of help from Matthew Flatt) + * +- * TODO Convert byte-strings to char strings? +- * + * This consists of six parts: + * 1. MzScheme interpreter main program + * 2. Routines that handle the external interface between MzScheme and +--- 1,9 ---- + /* vi:set ts=8 sts=4 sw=4: + * + * MzScheme interface by Sergey Khorev +! * Based on work by Brent Fulgham + * (Based on lots of help from Matthew Flatt) + * + * This consists of six parts: + * 1. MzScheme interpreter main program + * 2. Routines that handle the external interface between MzScheme and +*************** +*** 142,148 **** + static int do_mzscheme_command(exarg_T *, void *, Scheme_Closed_Prim *what); + static void startup_mzscheme(void); + static char *string_to_line(Scheme_Object *obj); +! static void do_output(char *mesg, intptr_t len); + static void do_printf(char *format, ...); + static void do_flush(void); + static Scheme_Object *_apply_thunk_catch_exceptions( +--- 140,151 ---- + static int do_mzscheme_command(exarg_T *, void *, Scheme_Closed_Prim *what); + static void startup_mzscheme(void); + static char *string_to_line(Scheme_Object *obj); +! #if MZSCHEME_VERSION_MAJOR >= 500 +! # define OUTPUT_LEN_TYPE intptr_t +! #else +! # define OUTPUT_LEN_TYPE long +! #endif +! static void do_output(char *mesg, OUTPUT_LEN_TYPE len); + static void do_printf(char *format, ...); + static void do_flush(void); + static Scheme_Object *_apply_thunk_catch_exceptions( +*************** +*** 166,175 **** + static int mzscheme_env_main(Scheme_Env *env, int argc, char **argv); + static int mzscheme_init(void); + #ifdef FEAT_EVAL +! static Scheme_Object *vim_to_mzscheme(typval_T *vim_value, int depth, + Scheme_Hash_Table *visited); +! static int mzscheme_to_vim(Scheme_Object *obj, typval_T *tv, int depth, + Scheme_Hash_Table *visited); + #endif + + #ifdef MZ_PRECISE_GC +--- 169,181 ---- + static int mzscheme_env_main(Scheme_Env *env, int argc, char **argv); + static int mzscheme_init(void); + #ifdef FEAT_EVAL +! static Scheme_Object *vim_to_mzscheme(typval_T *vim_value); +! static Scheme_Object *vim_to_mzscheme_impl(typval_T *vim_value, int depth, + Scheme_Hash_Table *visited); +! static int mzscheme_to_vim(Scheme_Object *obj, typval_T *tv); +! static int mzscheme_to_vim_impl(Scheme_Object *obj, typval_T *tv, int depth, + Scheme_Hash_Table *visited); ++ static Scheme_Object *vim_funcref(void *data, int argc, Scheme_Object **argv); + #endif + + #ifdef MZ_PRECISE_GC +*************** +*** 183,188 **** +--- 189,201 ---- + } + static int buffer_fixup_proc(void *obj) + { ++ /* apparently not needed as the object will be uncollectable while ++ * the buffer is alive ++ */ ++ /* ++ vim_mz_buffer* buf = (vim_mz_buffer*) obj; ++ buf->buf->b_mzscheme_ref = GC_fixup_self(obj); ++ */ + return buffer_size_proc(obj); + } + static int window_size_proc(void *obj UNUSED) +*************** +*** 195,206 **** + } + static int window_fixup_proc(void *obj) + { + return window_size_proc(obj); + } + #endif + + #ifdef DYNAMIC_MZSCHEME +- + static Scheme_Object *dll_scheme_eof; + static Scheme_Object *dll_scheme_false; + static Scheme_Object *dll_scheme_void; +--- 208,233 ---- + } + static int window_fixup_proc(void *obj) + { ++ /* apparently not needed as the object will be uncollectable while ++ * the window is alive ++ */ ++ /* ++ vim_mz_window* win = (vim_mz_window*) obj; ++ win->win->w_mzscheme_ref = GC_fixup_self(obj); ++ */ + return window_size_proc(obj); + } ++ /* with precise GC, w_mzscheme_ref and b_mzscheme_ref are immobile boxes ++ * containing pointers to a window/buffer ++ * with conservative GC these are simply pointers*/ ++ # define WINDOW_REF(win) *(vim_mz_window **)((win)->w_mzscheme_ref) ++ # define BUFFER_REF(buf) *(vim_mz_buffer **)((buf)->b_mzscheme_ref) ++ #else ++ # define WINDOW_REF(win) (vim_mz_window *)((win)->w_mzscheme_ref) ++ # define BUFFER_REF(buf) (vim_mz_buffer *)((buf)->b_mzscheme_ref) + #endif + + #ifdef DYNAMIC_MZSCHEME + static Scheme_Object *dll_scheme_eof; + static Scheme_Object *dll_scheme_false; + static Scheme_Object *dll_scheme_void; +*************** +*** 319,324 **** +--- 346,352 ---- + (Scheme_Object *s); + static Scheme_Object *(*dll_scheme_char_string_to_path) + (Scheme_Object *s); ++ static void *(*dll_scheme_set_collects_path)(Scheme_Object *p); + # endif + static Scheme_Hash_Table *(*dll_scheme_make_hash_table)(int type); + static void (*dll_scheme_hash_set)(Scheme_Hash_Table *table, +*************** +*** 378,388 **** + # endif + # define scheme_gc_ptr_ok dll_scheme_gc_ptr_ok + # if MZSCHEME_VERSION_MAJOR < 299 +! # define scheme_get_sized_string_output dll_scheme_get_sized_string_output + # else + # define scheme_get_sized_byte_string_output \ + dll_scheme_get_sized_byte_string_output +! # define scheme_get_param dll_scheme_get_param + # endif + # define scheme_intern_symbol dll_scheme_intern_symbol + # define scheme_lookup_global dll_scheme_lookup_global +--- 406,416 ---- + # endif + # define scheme_gc_ptr_ok dll_scheme_gc_ptr_ok + # if MZSCHEME_VERSION_MAJOR < 299 +! # define scheme_get_sized_byte_string_output dll_scheme_get_sized_string_output + # else + # define scheme_get_sized_byte_string_output \ + dll_scheme_get_sized_byte_string_output +! # define scheme_get_param dll_scheme_get_param + # endif + # define scheme_intern_symbol dll_scheme_intern_symbol + # define scheme_lookup_global dll_scheme_lookup_global +*************** +*** 391,398 **** + # define scheme_make_pair dll_scheme_make_pair + # define scheme_make_prim_w_arity dll_scheme_make_prim_w_arity + # if MZSCHEME_VERSION_MAJOR < 299 +! # define scheme_make_string dll_scheme_make_string +! # define scheme_make_string_output_port dll_scheme_make_string_output_port + # else + # define scheme_make_byte_string dll_scheme_make_byte_string + # define scheme_make_byte_string_output_port \ +--- 419,426 ---- + # define scheme_make_pair dll_scheme_make_pair + # define scheme_make_prim_w_arity dll_scheme_make_prim_w_arity + # if MZSCHEME_VERSION_MAJOR < 299 +! # define scheme_make_byte_string dll_scheme_make_string +! # define scheme_make_byte_string_output_port dll_scheme_make_string_output_port + # else + # define scheme_make_byte_string dll_scheme_make_byte_string + # define scheme_make_byte_string_output_port \ +*************** +*** 421,426 **** +--- 449,455 ---- + dll_scheme_char_string_to_byte_string + # define scheme_char_string_to_path \ + dll_scheme_char_string_to_path ++ # define scheme_set_collects_path dll_scheme_set_collects_path + # endif + # define scheme_make_hash_table dll_scheme_make_hash_table + # define scheme_hash_set dll_scheme_hash_set +*************** +*** 529,534 **** +--- 558,564 ---- + {"scheme_char_string_to_byte_string", + (void **)&dll_scheme_char_string_to_byte_string}, + {"scheme_char_string_to_path", (void **)&dll_scheme_char_string_to_path}, ++ {"scheme_set_collects_path", (void **)&dll_scheme_set_collects_path}, + # endif + {"scheme_make_hash_table", (void **)&dll_scheme_make_hash_table}, + {"scheme_hash_set", (void **)&dll_scheme_hash_set}, +*************** +*** 625,635 **** + } + #endif /* DYNAMIC_MZSCHEME */ + + /* need to put it here for dynamic stuff to work */ + #if defined(INCLUDE_MZSCHEME_BASE) + # include "mzscheme_base.c" + #elif MZSCHEME_VERSION_MAJOR >= 400 +! # error MzScheme 4.x must include mzscheme_base.c, for MinGW32 you need to define MZSCHEME_GENERATE_BASE=yes + #endif + + /* +--- 655,694 ---- + } + #endif /* DYNAMIC_MZSCHEME */ + ++ #if MZSCHEME_VERSION_MAJOR < 299 ++ # define GUARANTEED_STRING_ARG(proc, num) GUARANTEE_STRING(proc, num) ++ #else ++ static Scheme_Object * ++ guaranteed_byte_string_arg(char *proc, int num, int argc, Scheme_Object **argv) ++ { ++ if (SCHEME_BYTE_STRINGP(argv[num])) ++ { ++ return argv[num]; ++ } ++ else if (SCHEME_CHAR_STRINGP(argv[num])) ++ { ++ Scheme_Object *tmp = NULL; ++ MZ_GC_DECL_REG(2); ++ MZ_GC_VAR_IN_REG(0, argv[num]); ++ MZ_GC_VAR_IN_REG(1, tmp); ++ MZ_GC_REG(); ++ tmp = scheme_char_string_to_byte_string(argv[num]); ++ MZ_GC_UNREG(); ++ return tmp; ++ } ++ else ++ scheme_wrong_type(proc, "string", num, argc, argv); ++ /* unreachable */ ++ return scheme_void; ++ } ++ # define GUARANTEED_STRING_ARG(proc, num) guaranteed_byte_string_arg(proc, num, argc, argv) ++ #endif ++ + /* need to put it here for dynamic stuff to work */ + #if defined(INCLUDE_MZSCHEME_BASE) + # include "mzscheme_base.c" + #elif MZSCHEME_VERSION_MAJOR >= 400 +! # error MzScheme >=4 must include mzscheme_base.c, for MinGW32 you need to define MZSCHEME_GENERATE_BASE=yes + #endif + + /* +*************** +*** 861,866 **** +--- 920,930 ---- + scheme_set_stack_base(stack_base, 1); + #endif + ++ #ifndef TRAMPOLINED_MZVIM_STARTUP ++ /* in newer versions of precise GC the initial env has been created */ ++ environment = scheme_basic_env(); ++ #endif ++ + MZ_REGISTER_STATIC(environment); + MZ_REGISTER_STATIC(curout); + MZ_REGISTER_STATIC(curerr); +*************** +*** 869,878 **** + MZ_REGISTER_STATIC(exn_message); + MZ_REGISTER_STATIC(vim_exn); + +- #ifndef TRAMPOLINED_MZVIM_STARTUP +- /* in newer versions of precise GC the initial env has been created */ +- environment = scheme_basic_env(); +- #endif + MZ_GC_CHECK(); + + #ifdef INCLUDE_MZSCHEME_BASE +--- 933,938 ---- +*************** +*** 909,923 **** + Scheme_Object *coll_byte_string = NULL; + Scheme_Object *coll_char_string = NULL; + Scheme_Object *coll_path = NULL; +- Scheme_Object *coll_pair = NULL; +- Scheme_Config *config = NULL; + +! MZ_GC_DECL_REG(5); + MZ_GC_VAR_IN_REG(0, coll_byte_string); + MZ_GC_VAR_IN_REG(1, coll_char_string); + MZ_GC_VAR_IN_REG(2, coll_path); +- MZ_GC_VAR_IN_REG(3, coll_pair); +- MZ_GC_VAR_IN_REG(4, config); + MZ_GC_REG(); + coll_byte_string = scheme_make_byte_string(MZSCHEME_COLLECTS); + MZ_GC_CHECK(); +--- 969,979 ---- + Scheme_Object *coll_byte_string = NULL; + Scheme_Object *coll_char_string = NULL; + Scheme_Object *coll_path = NULL; + +! MZ_GC_DECL_REG(3); + MZ_GC_VAR_IN_REG(0, coll_byte_string); + MZ_GC_VAR_IN_REG(1, coll_char_string); + MZ_GC_VAR_IN_REG(2, coll_path); + MZ_GC_REG(); + coll_byte_string = scheme_make_byte_string(MZSCHEME_COLLECTS); + MZ_GC_CHECK(); +*************** +*** 925,935 **** + MZ_GC_CHECK(); + coll_path = scheme_char_string_to_path(coll_char_string); + MZ_GC_CHECK(); +! coll_pair = scheme_make_pair(coll_path, scheme_null); +! MZ_GC_CHECK(); +! config = scheme_config; +! MZ_GC_CHECK(); +! scheme_set_param(config, MZCONFIG_COLLECTION_PATHS, coll_pair); + MZ_GC_CHECK(); + MZ_GC_UNREG(); + } +--- 981,987 ---- + MZ_GC_CHECK(); + coll_path = scheme_char_string_to_path(coll_char_string); + MZ_GC_CHECK(); +! scheme_set_collects_path(coll_path); + MZ_GC_CHECK(); + MZ_GC_UNREG(); + } +*************** +*** 944,954 **** + MZ_GC_VAR_IN_REG(1, coll_pair); + MZ_GC_VAR_IN_REG(2, config); + MZ_GC_REG(); +! coll_string = scheme_make_string(MZSCHEME_COLLECTS); + MZ_GC_CHECK(); + coll_pair = scheme_make_pair(coll_string, scheme_null); + MZ_GC_CHECK(); +! config = scheme_config; + MZ_GC_CHECK(); + scheme_set_param(config, MZCONFIG_COLLECTION_PATHS, coll_pair); + MZ_GC_CHECK(); +--- 996,1006 ---- + MZ_GC_VAR_IN_REG(1, coll_pair); + MZ_GC_VAR_IN_REG(2, config); + MZ_GC_REG(); +! coll_string = scheme_make_byte_string(MZSCHEME_COLLECTS); + MZ_GC_CHECK(); + coll_pair = scheme_make_pair(coll_string, scheme_null); + MZ_GC_CHECK(); +! config = scheme_current_config(); + MZ_GC_CHECK(); + scheme_set_param(config, MZCONFIG_COLLECTION_PATHS, coll_pair); + MZ_GC_CHECK(); +*************** +*** 991,997 **** + MZ_GC_VAR_IN_REG(3, guard); + MZ_GC_VAR_IN_REG(4, config); + MZ_GC_REG(); +! config = scheme_config; + MZ_GC_CHECK(); + args[0] = scheme_get_param(config, MZCONFIG_SECURITY_GUARD); + MZ_GC_CHECK(); +--- 1043,1049 ---- + MZ_GC_VAR_IN_REG(3, guard); + MZ_GC_VAR_IN_REG(4, config); + MZ_GC_REG(); +! config = scheme_current_config(); + MZ_GC_CHECK(); + args[0] = scheme_get_param(config, MZCONFIG_SECURITY_GUARD); + MZ_GC_CHECK(); +*************** +*** 1055,1066 **** + MZ_GC_DECL_REG(1); + MZ_GC_VAR_IN_REG(0, config); + MZ_GC_REG(); +! config = scheme_config; + MZ_GC_CHECK(); + /* recreate ports each call effectively clearing these ones */ +! curout = scheme_make_string_output_port(); + MZ_GC_CHECK(); +! curerr = scheme_make_string_output_port(); + MZ_GC_CHECK(); + scheme_set_param(config, MZCONFIG_OUTPUT_PORT, curout); + MZ_GC_CHECK(); +--- 1107,1118 ---- + MZ_GC_DECL_REG(1); + MZ_GC_VAR_IN_REG(0, config); + MZ_GC_REG(); +! config = scheme_current_config(); + MZ_GC_CHECK(); + /* recreate ports each call effectively clearing these ones */ +! curout = scheme_make_byte_string_output_port(); + MZ_GC_CHECK(); +! curerr = scheme_make_byte_string_output_port(); + MZ_GC_CHECK(); + scheme_set_param(config, MZCONFIG_OUTPUT_PORT, curout); + MZ_GC_CHECK(); +*************** +*** 1149,1161 **** + { + if (buf->b_mzscheme_ref) + { +! vim_mz_buffer *bp; + +! bp = buf->b_mzscheme_ref; + bp->buf = INVALID_BUFFER_VALUE; +! buf->b_mzscheme_ref = NULL; + scheme_gc_ptr_ok(bp); + MZ_GC_CHECK(); + } + } + +--- 1201,1221 ---- + { + if (buf->b_mzscheme_ref) + { +! vim_mz_buffer *bp = NULL; +! MZ_GC_DECL_REG(1); +! MZ_GC_VAR_IN_REG(0, bp); +! MZ_GC_REG(); + +! bp = BUFFER_REF(buf); + bp->buf = INVALID_BUFFER_VALUE; +! #ifndef MZ_PRECISE_GC + scheme_gc_ptr_ok(bp); ++ #else ++ scheme_free_immobile_box(buf->b_mzscheme_ref); ++ #endif ++ buf->b_mzscheme_ref = NULL; + MZ_GC_CHECK(); ++ MZ_GC_UNREG(); + } + } + +*************** +*** 1167,1178 **** + { + if (win->w_mzscheme_ref) + { +! vim_mz_window *wp; +! wp = win->w_mzscheme_ref; + wp->win = INVALID_WINDOW_VALUE; +! win->w_mzscheme_ref = NULL; + scheme_gc_ptr_ok(wp); + MZ_GC_CHECK(); + } + } + +--- 1227,1246 ---- + { + if (win->w_mzscheme_ref) + { +! vim_mz_window *wp = NULL; +! MZ_GC_DECL_REG(1); +! MZ_GC_VAR_IN_REG(0, wp); +! MZ_GC_REG(); +! wp = WINDOW_REF(win); + wp->win = INVALID_WINDOW_VALUE; +! #ifndef MZ_PRECISE_GC + scheme_gc_ptr_ok(wp); ++ #else ++ scheme_free_immobile_box(win->w_mzscheme_ref); ++ #endif ++ win->w_mzscheme_ref = NULL; + MZ_GC_CHECK(); ++ MZ_GC_UNREG(); + } + } + +*************** +*** 1349,1355 **** + } + + static void +! do_output(char *mesg, intptr_t len UNUSED) + { + /* TODO: use len, the string may not be NUL terminated */ + do_intrnl_output(mesg, 0); +--- 1417,1423 ---- + } + + static void +! do_output(char *mesg, OUTPUT_LEN_TYPE len UNUSED) + { + /* TODO: use len, the string may not be NUL terminated */ + do_intrnl_output(mesg, 0); +*************** +*** 1371,1379 **** + do_flush(void) + { + char *buff; +! intptr_t length; + +! buff = scheme_get_sized_string_output(curerr, &length); + MZ_GC_CHECK(); + if (length) + { +--- 1439,1447 ---- + do_flush(void) + { + char *buff; +! OUTPUT_LEN_TYPE length; + +! buff = scheme_get_sized_byte_string_output(curerr, &length); + MZ_GC_CHECK(); + if (length) + { +*************** +*** 1381,1387 **** + return; + } + +! buff = scheme_get_sized_string_output(curout, &length); + MZ_GC_CHECK(); + if (length) + do_output(buff, length); +--- 1449,1455 ---- + return; + } + +! buff = scheme_get_sized_byte_string_output(curout, &length); + MZ_GC_CHECK(); + if (length) + do_output(buff, length); +*************** +*** 1398,1409 **** + vim_command(void *data, int argc, Scheme_Object **argv) + { + Vim_Prim *prim = (Vim_Prim *)data; +! char *cmd = SCHEME_STR_VAL(GUARANTEE_STRING(prim->name, 0)); + + /* may be use do_cmdline_cmd? */ +! do_cmdline((char_u *)cmd, NULL, NULL, DOCMD_NOWAIT|DOCMD_VERBOSE); + update_screen(VALID); + + raise_if_error(); + return scheme_void; + } +--- 1466,1482 ---- + vim_command(void *data, int argc, Scheme_Object **argv) + { + Vim_Prim *prim = (Vim_Prim *)data; +! Scheme_Object *cmd = NULL; +! MZ_GC_DECL_REG(1); +! MZ_GC_VAR_IN_REG(0, cmd); +! MZ_GC_REG(); +! cmd = GUARANTEED_STRING_ARG(prim->name, 0); + + /* may be use do_cmdline_cmd? */ +! do_cmdline(BYTE_STRING_VALUE(cmd), NULL, NULL, DOCMD_NOWAIT|DOCMD_VERBOSE); + update_screen(VALID); + ++ MZ_GC_UNREG(); + raise_if_error(); + return scheme_void; + } +*************** +*** 1414,1439 **** + { + #ifdef FEAT_EVAL + Vim_Prim *prim = (Vim_Prim *)data; +! char *expr; +! Scheme_Object *result; +! /* hash table to store visited values to avoid infinite loops */ +! Scheme_Hash_Table *visited = NULL; + typval_T *vim_result; +! +! MZ_GC_DECL_REG(1); +! MZ_GC_VAR_IN_REG(0, visited); + MZ_GC_REG(); + +! visited = scheme_make_hash_table(SCHEME_hash_ptr); +! MZ_GC_CHECK(); +! +! expr = SCHEME_STR_VAL(GUARANTEE_STRING(prim->name, 0)); +! vim_result = eval_expr((char_u *)expr, NULL); + + if (vim_result == NULL) + raise_vim_exn(_("invalid expression")); + +! result = vim_to_mzscheme(vim_result, 1, visited); + free_tv(vim_result); + + MZ_GC_UNREG(); +--- 1487,1508 ---- + { + #ifdef FEAT_EVAL + Vim_Prim *prim = (Vim_Prim *)data; +! Scheme_Object *result = NULL; + typval_T *vim_result; +! Scheme_Object *expr = NULL; +! MZ_GC_DECL_REG(2); +! MZ_GC_VAR_IN_REG(0, result); +! MZ_GC_VAR_IN_REG(1, expr); + MZ_GC_REG(); ++ expr = GUARANTEED_STRING_ARG(prim->name, 0); + +! vim_result = eval_expr(BYTE_STRING_VALUE(expr), NULL); + + if (vim_result == NULL) + raise_vim_exn(_("invalid expression")); + +! result = vim_to_mzscheme(vim_result); +! MZ_GC_CHECK(); + free_tv(vim_result); + + MZ_GC_UNREG(); +*************** +*** 1474,1489 **** + get_option(void *data, int argc, Scheme_Object **argv) + { + Vim_Prim *prim = (Vim_Prim *)data; +- char_u *name; + long value; + char *strval; + int rc; +! Scheme_Object *rval; + int opt_flags = 0; + buf_T *save_curb = curbuf; + win_T *save_curw = curwin; + +! name = (char_u *)SCHEME_STR_VAL(GUARANTEE_STRING(prim->name, 0)); + + if (argc > 1) + { +--- 1543,1563 ---- + get_option(void *data, int argc, Scheme_Object **argv) + { + Vim_Prim *prim = (Vim_Prim *)data; + long value; + char *strval; + int rc; +! Scheme_Object *rval = NULL; +! Scheme_Object *name = NULL; + int opt_flags = 0; + buf_T *save_curb = curbuf; + win_T *save_curw = curwin; + +! MZ_GC_DECL_REG(2); +! MZ_GC_VAR_IN_REG(0, rval); +! MZ_GC_VAR_IN_REG(1, name); +! MZ_GC_REG(); +! +! name = GUARANTEED_STRING_ARG(prim->name, 0); + + if (argc > 1) + { +*************** +*** 1513,1535 **** + scheme_wrong_type(prim->name, "vim-buffer/window", 1, argc, argv); + } + +! rc = get_option_value(name, &value, (char_u **)&strval, opt_flags); + curbuf = save_curb; + curwin = save_curw; + + switch (rc) + { + case 1: + return scheme_make_integer_value(value); + case 0: +! rval = scheme_make_string(strval); + MZ_GC_CHECK(); + vim_free(strval); + return rval; + case -1: + case -2: + raise_vim_exn(_("hidden option")); + case -3: + raise_vim_exn(_("unknown option")); + } + /* unreachable */ +--- 1587,1613 ---- + scheme_wrong_type(prim->name, "vim-buffer/window", 1, argc, argv); + } + +! rc = get_option_value(BYTE_STRING_VALUE(name), &value, (char_u **)&strval, opt_flags); + curbuf = save_curb; + curwin = save_curw; + + switch (rc) + { + case 1: ++ MZ_GC_UNREG(); + return scheme_make_integer_value(value); + case 0: +! rval = scheme_make_byte_string(strval); + MZ_GC_CHECK(); + vim_free(strval); ++ MZ_GC_UNREG(); + return rval; + case -1: + case -2: ++ MZ_GC_UNREG(); + raise_vim_exn(_("hidden option")); + case -3: ++ MZ_GC_UNREG(); + raise_vim_exn(_("unknown option")); + } + /* unreachable */ +*************** +*** 1540,1552 **** + static Scheme_Object * + set_option(void *data, int argc, Scheme_Object **argv) + { +! char_u *cmd; + int opt_flags = 0; + buf_T *save_curb = curbuf; + win_T *save_curw = curwin; + Vim_Prim *prim = (Vim_Prim *)data; + +- GUARANTEE_STRING(prim->name, 0); + if (argc > 1) + { + if (M_global == NULL) +--- 1618,1635 ---- + static Scheme_Object * + set_option(void *data, int argc, Scheme_Object **argv) + { +! char_u *command = NULL; + int opt_flags = 0; + buf_T *save_curb = curbuf; + win_T *save_curw = curwin; + Vim_Prim *prim = (Vim_Prim *)data; ++ Scheme_Object *cmd = NULL; ++ ++ MZ_GC_DECL_REG(1); ++ MZ_GC_VAR_IN_REG(0, cmd); ++ MZ_GC_REG(); ++ cmd = GUARANTEED_STRING_ARG(prim->name, 0); + + if (argc > 1) + { + if (M_global == NULL) +*************** +*** 1575,1583 **** + } + + /* do_set can modify cmd, make copy */ +! cmd = vim_strsave((char_u *)SCHEME_STR_VAL(argv[0])); +! do_set(cmd, opt_flags); +! vim_free(cmd); + update_screen(NOT_VALID); + curbuf = save_curb; + curwin = save_curw; +--- 1658,1667 ---- + } + + /* do_set can modify cmd, make copy */ +! command = vim_strsave(BYTE_STRING_VALUE(cmd)); +! MZ_GC_UNREG(); +! do_set(command, opt_flags); +! vim_free(command); + update_screen(NOT_VALID); + curbuf = save_curb; + curwin = save_curw; +*************** +*** 1639,1645 **** + + MZ_GC_DECL_REG(1); + MZ_GC_VAR_IN_REG(0, self); +- MZ_GC_REG(); + + /* We need to handle deletion of windows underneath us. + * If we add a "w_mzscheme_ref" field to the win_T structure, +--- 1723,1728 ---- +*************** +*** 1650,1667 **** + * object, and reject them if the win_T *field is invalid. + */ + if (win->w_mzscheme_ref != NULL) +! return win->w_mzscheme_ref; + +! self = scheme_malloc_fail_ok(scheme_malloc, sizeof(vim_mz_window)); + vim_memset(self, 0, sizeof(vim_mz_window)); + scheme_dont_gc_ptr(self); /* because win isn't visible to GC */ + MZ_GC_CHECK(); +- win->w_mzscheme_ref = self; + self->win = win; + self->so.type = mz_window_type; + + MZ_GC_UNREG(); +! return (Scheme_Object *)(self); + } + + /* (get-win-num [window]) */ +--- 1733,1756 ---- + * object, and reject them if the win_T *field is invalid. + */ + if (win->w_mzscheme_ref != NULL) +! return (Scheme_Object *)WINDOW_REF(win); + +! MZ_GC_REG(); +! self = scheme_malloc_fail_ok(scheme_malloc_tagged, sizeof(vim_mz_window)); + vim_memset(self, 0, sizeof(vim_mz_window)); ++ #ifndef MZ_PRECISE_GC + scheme_dont_gc_ptr(self); /* because win isn't visible to GC */ ++ #else ++ win->w_mzscheme_ref = scheme_malloc_immobile_box(NULL); ++ #endif ++ MZ_GC_CHECK(); ++ WINDOW_REF(win) = self; + MZ_GC_CHECK(); + self->win = win; + self->so.type = mz_window_type; + + MZ_GC_UNREG(); +! return (Scheme_Object *)self; + } + + /* (get-win-num [window]) */ +*************** +*** 1837,1858 **** + mzscheme_open_buffer(void *data, int argc, Scheme_Object **argv) + { + Vim_Prim *prim = (Vim_Prim *)data; +- char_u *fname; + int num = 0; +! Scheme_Object *onum; + + #ifdef HAVE_SANDBOX + sandbox_check(); + #endif +- fname = (char_u *)SCHEME_STR_VAL(GUARANTEE_STRING(prim->name, 0)); + /* TODO make open existing file */ +! num = buflist_add(fname, BLN_LISTED | BLN_CURBUF); + + if (num == 0) + raise_vim_exn(_("couldn't open buffer")); + + onum = scheme_make_integer(num); +! return get_buffer_by_num(data, 1, &onum); + } + + /* (get-buff-by-num {buffernum}) */ +--- 1926,1956 ---- + mzscheme_open_buffer(void *data, int argc, Scheme_Object **argv) + { + Vim_Prim *prim = (Vim_Prim *)data; + int num = 0; +! Scheme_Object *onum = NULL; +! Scheme_Object *buf = NULL; +! Scheme_Object *fname; +! +! MZ_GC_DECL_REG(3); +! MZ_GC_VAR_IN_REG(0, onum); +! MZ_GC_VAR_IN_REG(1, buf); +! MZ_GC_VAR_IN_REG(2, fname); +! MZ_GC_REG(); +! fname = GUARANTEED_STRING_ARG(prim->name, 0); + + #ifdef HAVE_SANDBOX + sandbox_check(); + #endif + /* TODO make open existing file */ +! num = buflist_add(BYTE_STRING_VALUE(fname), BLN_LISTED | BLN_CURBUF); + + if (num == 0) + raise_vim_exn(_("couldn't open buffer")); + + onum = scheme_make_integer(num); +! buf = get_buffer_by_num(data, 1, &onum); +! MZ_GC_UNREG(); +! return buf; + } + + /* (get-buff-by-num {buffernum}) */ +*************** +*** 1878,1900 **** + { + Vim_Prim *prim = (Vim_Prim *)data; + buf_T *buf; +! char_u *fname; + +! fname = (char_u *)SCHEME_STR_VAL(GUARANTEE_STRING(prim->name, 0)); + + for (buf = firstbuf; buf; buf = buf->b_next) + if (buf->b_ffname == NULL || buf->b_sfname == NULL) + /* empty string */ + { +! if (fname[0] == NUL) +! return buffer_new(buf); + } +! else if (!fnamecmp(buf->b_ffname, fname) +! || !fnamecmp(buf->b_sfname, fname)) + /* either short or long filename matches */ +! return buffer_new(buf); + +! return scheme_false; + } + + /* (get-next-buff [buffer]) */ +--- 1976,2009 ---- + { + Vim_Prim *prim = (Vim_Prim *)data; + buf_T *buf; +! Scheme_Object *buffer = NULL; +! Scheme_Object *fname = NULL; + +! MZ_GC_DECL_REG(2); +! MZ_GC_VAR_IN_REG(0, buffer); +! MZ_GC_VAR_IN_REG(1, fname); +! MZ_GC_REG(); +! fname = GUARANTEED_STRING_ARG(prim->name, 0); +! buffer = scheme_false; + + for (buf = firstbuf; buf; buf = buf->b_next) ++ { + if (buf->b_ffname == NULL || buf->b_sfname == NULL) + /* empty string */ + { +! if (BYTE_STRING_VALUE(fname)[0] == NUL) +! buffer = buffer_new(buf); + } +! else if (!fnamecmp(buf->b_ffname, BYTE_STRING_VALUE(fname)) +! || !fnamecmp(buf->b_sfname, BYTE_STRING_VALUE(fname))) +! { + /* either short or long filename matches */ +! buffer = buffer_new(buf); +! } +! } + +! MZ_GC_UNREG(); +! return buffer; + } + + /* (get-next-buff [buffer]) */ +*************** +*** 1951,1957 **** + Vim_Prim *prim = (Vim_Prim *)data; + vim_mz_buffer *buf = get_buffer_arg(prim->name, 0, argc, argv); + +! return scheme_make_string((char *)buf->buf->b_ffname); + } + + /* (curr-buff) */ +--- 2060,2066 ---- + Vim_Prim *prim = (Vim_Prim *)data; + vim_mz_buffer *buf = get_buffer_arg(prim->name, 0, argc, argv); + +! return scheme_make_byte_string((char *)buf->buf->b_ffname); + } + + /* (curr-buff) */ +*************** +*** 1968,1992 **** + + MZ_GC_DECL_REG(1); + MZ_GC_VAR_IN_REG(0, self); +- MZ_GC_REG(); + + /* We need to handle deletion of buffers underneath us. + * If we add a "b_mzscheme_ref" field to the buf_T structure, + * then we can get at it in buf_freeall() in vim. + */ + if (buf->b_mzscheme_ref) +! return buf->b_mzscheme_ref; + +! self = scheme_malloc_fail_ok(scheme_malloc, sizeof(vim_mz_buffer)); + vim_memset(self, 0, sizeof(vim_mz_buffer)); +! scheme_dont_gc_ptr(self); /* because buf isn't visible to GC */ + MZ_GC_CHECK(); +- buf->b_mzscheme_ref = self; + self->buf = buf; + self->so.type = mz_buffer_type; + + MZ_GC_UNREG(); +! return (Scheme_Object *)(self); + } + + /* +--- 2077,2106 ---- + + MZ_GC_DECL_REG(1); + MZ_GC_VAR_IN_REG(0, self); + + /* We need to handle deletion of buffers underneath us. + * If we add a "b_mzscheme_ref" field to the buf_T structure, + * then we can get at it in buf_freeall() in vim. + */ + if (buf->b_mzscheme_ref) +! return (Scheme_Object *)BUFFER_REF(buf); + +! MZ_GC_REG(); +! self = scheme_malloc_fail_ok(scheme_malloc_tagged, sizeof(vim_mz_buffer)); + vim_memset(self, 0, sizeof(vim_mz_buffer)); +! #ifndef MZ_PRECISE_GC +! scheme_dont_gc_ptr(self); /* because buf isn't visible to GC */ +! #else +! buf->b_mzscheme_ref = scheme_malloc_immobile_box(NULL); +! #endif +! MZ_GC_CHECK(); +! BUFFER_REF(buf) = self; + MZ_GC_CHECK(); + self->buf = buf; + self->so.type = mz_buffer_type; + + MZ_GC_UNREG(); +! return (Scheme_Object *)self; + } + + /* +*************** +*** 2023,2029 **** + line = ml_get_buf(buf->buf, (linenr_T)linenr, FALSE); + + raise_if_error(); +! return scheme_make_string((char *)line); + } + + +--- 2137,2143 ---- + line = ml_get_buf(buf->buf, (linenr_T)linenr, FALSE); + + raise_if_error(); +! return scheme_make_byte_string((char *)line); + } + + +*************** +*** 2066,2072 **** + + for (i = n; i >= 0; --i) + { +! Scheme_Object *str = scheme_make_string( + (char *)ml_get_buf(buf->buf, (linenr_T)(lo+i), FALSE)); + raise_if_error(); + +--- 2180,2186 ---- + + for (i = n; i >= 0; --i) + { +! Scheme_Object *str = scheme_make_byte_string( + (char *)ml_get_buf(buf->buf, (linenr_T)(lo+i), FALSE)); + raise_if_error(); + +*************** +*** 2298,2305 **** + MZ_GC_VAR_IN_REG(1, rest); + MZ_GC_REG(); + +! array = (char **)alloc(new_len * sizeof(char *)); +! vim_memset(array, 0, new_len * sizeof(char *)); + + rest = line_list; + for (i = 0; i < new_len; ++i) +--- 2412,2419 ---- + MZ_GC_VAR_IN_REG(1, rest); + MZ_GC_REG(); + +! array = (char **)alloc((new_len+1)* sizeof(char *)); +! vim_memset(array, 0, (new_len+1) * sizeof(char *)); + + rest = line_list; + for (i = 0; i < new_len; ++i) +*************** +*** 2481,2488 **** + MZ_GC_VAR_IN_REG(1, rest); + MZ_GC_REG(); + +! array = (char **)alloc(size * sizeof(char *)); +! vim_memset(array, 0, size * sizeof(char *)); + + rest = list; + for (i = 0; i < size; ++i) +--- 2595,2602 ---- + MZ_GC_VAR_IN_REG(1, rest); + MZ_GC_REG(); + +! array = (char **)alloc((size+1) * sizeof(char *)); +! vim_memset(array, 0, (size+1) * sizeof(char *)); + + rest = list; + for (i = 0; i < size; ++i) +*************** +*** 2589,2595 **** + { + char *scheme_str = NULL; + char *vim_str = NULL; +! intptr_t len; + int i; + + scheme_str = scheme_display_to_string(obj, &len); +--- 2703,2709 ---- + { + char *scheme_str = NULL; + char *vim_str = NULL; +! OUTPUT_LEN_TYPE len; + int i; + + scheme_str = scheme_display_to_string(obj, &len); +*************** +*** 2598,2607 **** + * are replacing a single line, and we must replace it with + * a single line. + */ +! if (memchr(scheme_str, '\n', (size_t)len)) + scheme_signal_error(_("string cannot contain newlines")); + +! vim_str = (char *)alloc((int)(len + 1)); + + /* Create a copy of the string, with internal nulls replaced by + * newline characters, as is the vim convention. +--- 2712,2721 ---- + * are replacing a single line, and we must replace it with + * a single line. + */ +! if (memchr(scheme_str, '\n', len)) + scheme_signal_error(_("string cannot contain newlines")); + +! vim_str = (char *)alloc(len + 1); + + /* Create a copy of the string, with internal nulls replaced by + * newline characters, as is the vim convention. +*************** +*** 2625,2637 **** + * Convert Vim value into MzScheme, adopted from if_python.c + */ + static Scheme_Object * +! vim_to_mzscheme(typval_T *vim_value, int depth, Scheme_Hash_Table *visited) + { + Scheme_Object *result = NULL; + int new_value = TRUE; + +! MZ_GC_DECL_REG(1); + MZ_GC_VAR_IN_REG(0, result); + MZ_GC_REG(); + + /* Avoid infinite recursion */ +--- 2739,2773 ---- + * Convert Vim value into MzScheme, adopted from if_python.c + */ + static Scheme_Object * +! vim_to_mzscheme(typval_T *vim_value) +! { +! Scheme_Object *result = NULL; +! /* hash table to store visited values to avoid infinite loops */ +! Scheme_Hash_Table *visited = NULL; +! +! MZ_GC_DECL_REG(2); +! MZ_GC_VAR_IN_REG(0, result); +! MZ_GC_VAR_IN_REG(1, visited); +! MZ_GC_REG(); +! +! visited = scheme_make_hash_table(SCHEME_hash_ptr); +! MZ_GC_CHECK(); +! +! result = vim_to_mzscheme_impl(vim_value, 1, visited); +! +! MZ_GC_UNREG(); +! return result; +! } +! +! static Scheme_Object * +! vim_to_mzscheme_impl(typval_T *vim_value, int depth, Scheme_Hash_Table *visited) + { + Scheme_Object *result = NULL; + int new_value = TRUE; + +! MZ_GC_DECL_REG(2); + MZ_GC_VAR_IN_REG(0, result); ++ MZ_GC_VAR_IN_REG(1, visited); + MZ_GC_REG(); + + /* Avoid infinite recursion */ +*************** +*** 2650,2657 **** + new_value = FALSE; + else if (vim_value->v_type == VAR_STRING) + { +! result = scheme_make_string(vim_value->vval.v_string == NULL +! ? "" : (char *)vim_value->vval.v_string); + MZ_GC_CHECK(); + } + else if (vim_value->v_type == VAR_NUMBER) +--- 2786,2792 ---- + new_value = FALSE; + else if (vim_value->v_type == VAR_STRING) + { +! result = scheme_make_byte_string((char *)vim_value->vval.v_string); + MZ_GC_CHECK(); + } + else if (vim_value->v_type == VAR_NUMBER) +*************** +*** 2682,2695 **** + MZ_GC_REG(); + + curr = list->lv_last; +! obj = vim_to_mzscheme(&curr->li_tv, depth + 1, visited); + result = scheme_make_pair(obj, scheme_null); + MZ_GC_CHECK(); + + while (curr != list->lv_first) + { + curr = curr->li_prev; +! obj = vim_to_mzscheme(&curr->li_tv, depth + 1, visited); + result = scheme_make_pair(obj, result); + MZ_GC_CHECK(); + } +--- 2817,2830 ---- + MZ_GC_REG(); + + curr = list->lv_last; +! obj = vim_to_mzscheme_impl(&curr->li_tv, depth + 1, visited); + result = scheme_make_pair(obj, scheme_null); + MZ_GC_CHECK(); + + while (curr != list->lv_first) + { + curr = curr->li_prev; +! obj = vim_to_mzscheme_impl(&curr->li_tv, depth + 1, visited); + result = scheme_make_pair(obj, result); + MZ_GC_CHECK(); + } +*************** +*** 2722,2729 **** + --todo; + + di = dict_lookup(hi); +! obj = vim_to_mzscheme(&di->di_tv, depth + 1, visited); +! key = scheme_make_string((char *)hi->hi_key); + MZ_GC_CHECK(); + scheme_hash_set((Scheme_Hash_Table *)result, key, obj); + MZ_GC_CHECK(); +--- 2857,2864 ---- + --todo; + + di = dict_lookup(hi); +! obj = vim_to_mzscheme_impl(&di->di_tv, depth + 1, visited); +! key = scheme_make_byte_string((char *)hi->hi_key); + MZ_GC_CHECK(); + scheme_hash_set((Scheme_Hash_Table *)result, key, obj); + MZ_GC_CHECK(); +*************** +*** 2732,2737 **** +--- 2867,2888 ---- + } + MZ_GC_UNREG(); + } ++ else if (vim_value->v_type == VAR_FUNC) ++ { ++ Scheme_Object *funcname = NULL; ++ ++ MZ_GC_DECL_REG(1); ++ MZ_GC_VAR_IN_REG(0, funcname); ++ MZ_GC_REG(); ++ ++ funcname = scheme_make_byte_string((char *)vim_value->vval.v_string); ++ MZ_GC_CHECK(); ++ result = scheme_make_closed_prim_w_arity(vim_funcref, funcname, ++ (const char *)BYTE_STRING_VALUE(funcname), 0, -1); ++ MZ_GC_CHECK(); ++ ++ MZ_GC_UNREG(); ++ } + else + { + result = scheme_void; +*************** +*** 2747,2757 **** + } + + static int +! mzscheme_to_vim(Scheme_Object *obj, typval_T *tv, int depth, + Scheme_Hash_Table *visited) + { + int status = OK; + typval_T *found; + MZ_GC_CHECK(); + if (depth > 100) /* limit the deepest recursion level */ + { +--- 2898,2939 ---- + } + + static int +! mzscheme_to_vim(Scheme_Object *obj, typval_T *tv) +! { +! int i, status; +! Scheme_Hash_Table *visited = NULL; +! +! MZ_GC_DECL_REG(2); +! MZ_GC_VAR_IN_REG(0, obj); +! MZ_GC_VAR_IN_REG(1, visited); +! MZ_GC_REG(); +! +! visited = scheme_make_hash_table(SCHEME_hash_ptr); +! MZ_GC_CHECK(); +! +! status = mzscheme_to_vim_impl(obj, tv, 1, visited); +! for (i = 0; i < visited->size; ++i) +! { +! /* free up remembered objects */ +! if (visited->vals[i] != NULL) +! free_tv((typval_T *)visited->vals[i]); +! } +! +! MZ_GC_UNREG(); +! return status; +! } +! static int +! mzscheme_to_vim_impl(Scheme_Object *obj, typval_T *tv, int depth, + Scheme_Hash_Table *visited) + { + int status = OK; + typval_T *found; ++ ++ MZ_GC_DECL_REG(2); ++ MZ_GC_VAR_IN_REG(0, obj); ++ MZ_GC_VAR_IN_REG(1, visited); ++ MZ_GC_REG(); ++ + MZ_GC_CHECK(); + if (depth > 100) /* limit the deepest recursion level */ + { +*************** +*** 2785,2795 **** + tv->vval.v_float = SCHEME_DBL_VAL(obj); + } + # endif +! else if (SCHEME_STRINGP(obj)) + { + tv->v_type = VAR_STRING; +! tv->vval.v_string = vim_strsave((char_u *)SCHEME_STR_VAL(obj)); + } + else if (SCHEME_VECTORP(obj) || SCHEME_NULLP(obj) + || SCHEME_PAIRP(obj) || SCHEME_MUTABLE_PAIRP(obj)) + { +--- 2967,2991 ---- + tv->vval.v_float = SCHEME_DBL_VAL(obj); + } + # endif +! else if (SCHEME_BYTE_STRINGP(obj)) + { + tv->v_type = VAR_STRING; +! tv->vval.v_string = vim_strsave(BYTE_STRING_VALUE(obj)); + } ++ # if MZSCHEME_VERSION_MAJOR >= 299 ++ else if (SCHEME_CHAR_STRINGP(obj)) ++ { ++ Scheme_Object *tmp = NULL; ++ MZ_GC_DECL_REG(1); ++ MZ_GC_VAR_IN_REG(0, tmp); ++ MZ_GC_REG(); ++ ++ tmp = scheme_char_string_to_byte_string(obj); ++ tv->v_type = VAR_STRING; ++ tv->vval.v_string = vim_strsave(BYTE_STRING_VALUE(tmp)); ++ MZ_GC_UNREG(); ++ } ++ #endif + else if (SCHEME_VECTORP(obj) || SCHEME_NULLP(obj) + || SCHEME_PAIRP(obj) || SCHEME_MUTABLE_PAIRP(obj)) + { +*************** +*** 2829,2835 **** + for (i = 0; i < SCHEME_VEC_SIZE(obj); ++i) + { + cval = SCHEME_VEC_ELS(obj)[i]; +! status = mzscheme_to_vim(cval, v, depth + 1, visited); + if (status == FAIL) + break; + status = list_append_tv(list, v); +--- 3025,3031 ---- + for (i = 0; i < SCHEME_VEC_SIZE(obj); ++i) + { + cval = SCHEME_VEC_ELS(obj)[i]; +! status = mzscheme_to_vim_impl(cval, v, depth + 1, visited); + if (status == FAIL) + break; + status = list_append_tv(list, v); +*************** +*** 2845,2851 **** + curr = SCHEME_CDR(curr)) + { + cval = SCHEME_CAR(curr); +! status = mzscheme_to_vim(cval, v, depth + 1, visited); + if (status == FAIL) + break; + status = list_append_tv(list, v); +--- 3041,3047 ---- + curr = SCHEME_CDR(curr)) + { + cval = SCHEME_CAR(curr); +! status = mzscheme_to_vim_impl(cval, v, depth + 1, visited); + if (status == FAIL) + break; + status = list_append_tv(list, v); +*************** +*** 2857,2863 **** + * need to handle the last element */ + if (status == OK && !SCHEME_NULLP(curr)) + { +! status = mzscheme_to_vim(cval, v, depth + 1, visited); + if (status == OK) + { + status = list_append_tv(list, v); +--- 3053,3059 ---- + * need to handle the last element */ + if (status == OK && !SCHEME_NULLP(curr)) + { +! status = mzscheme_to_vim_impl(cval, v, depth + 1, visited); + if (status == OK) + { + status = list_append_tv(list, v); +*************** +*** 2905,2911 **** + dictitem_T *item = dictitem_alloc((char_u *)string_to_line( + ((Scheme_Hash_Table *) obj)->keys[i])); + /* convert Scheme val to Vim and add it to the dict */ +! if (mzscheme_to_vim(((Scheme_Hash_Table *) obj)->vals[i], + &item->di_tv, depth + 1, visited) == FAIL + || dict_add(dict, item) == FAIL) + { +--- 3101,3107 ---- + dictitem_T *item = dictitem_alloc((char_u *)string_to_line( + ((Scheme_Hash_Table *) obj)->keys[i])); + /* convert Scheme val to Vim and add it to the dict */ +! if (mzscheme_to_vim_impl(((Scheme_Hash_Table *) obj)->vals[i], + &item->di_tv, depth + 1, visited) == FAIL + || dict_add(dict, item) == FAIL) + { +*************** +*** 2925,2943 **** + tv->v_type = VAR_STRING; + tv->vval.v_string = (char_u *)string_to_line(obj); + } + return status; + } + + void + do_mzeval(char_u *str, typval_T *rettv) + { +- int i; + Scheme_Object *ret = NULL; +- Scheme_Hash_Table *visited = NULL; + +! MZ_GC_DECL_REG(2); + MZ_GC_VAR_IN_REG(0, ret); +- MZ_GC_VAR_IN_REG(0, visited); + MZ_GC_REG(); + + if (mzscheme_init()) +--- 3121,3196 ---- + tv->v_type = VAR_STRING; + tv->vval.v_string = (char_u *)string_to_line(obj); + } ++ MZ_GC_UNREG(); + return status; + } + ++ /* Scheme prim procedure wrapping Vim funcref */ ++ static Scheme_Object * ++ vim_funcref(void *name, int argc, Scheme_Object **argv) ++ { ++ int i; ++ typval_T args; ++ int status = OK; ++ Scheme_Object *result = NULL; ++ list_T *list = list_alloc(); ++ ++ MZ_GC_DECL_REG(1); ++ MZ_GC_VAR_IN_REG(0, result); ++ MZ_GC_REG(); ++ ++ result = scheme_void; ++ if (list == NULL) ++ status = FAIL; ++ else ++ { ++ args.v_type = VAR_LIST; ++ args.vval.v_list = list; ++ ++list->lv_refcount; ++ for (i = 0; status == OK && i < argc; ++i) ++ { ++ typval_T *v = (typval_T *)alloc(sizeof(typval_T)); ++ if (v == NULL) ++ status = FAIL; ++ else ++ { ++ status = mzscheme_to_vim(argv[i], v); ++ if (status == OK) ++ { ++ status = list_append_tv(list, v); ++ clear_tv(v); ++ } ++ vim_free(v); ++ } ++ } ++ if (status == OK) ++ { ++ typval_T ret; ++ ret.v_type = VAR_UNKNOWN; ++ ++ mzscheme_call_vim(BYTE_STRING_VALUE((Scheme_Object *)name), &args, &ret); ++ MZ_GC_CHECK(); ++ result = vim_to_mzscheme(&ret); ++ clear_tv(&ret); ++ MZ_GC_CHECK(); ++ } ++ } ++ clear_tv(&args); ++ MZ_GC_UNREG(); ++ if (status != OK) ++ raise_vim_exn(_("error converting Scheme values to Vim")); ++ else ++ raise_if_error(); ++ return result; ++ } ++ + void + do_mzeval(char_u *str, typval_T *rettv) + { + Scheme_Object *ret = NULL; + +! MZ_GC_DECL_REG(1); + MZ_GC_VAR_IN_REG(0, ret); + MZ_GC_REG(); + + if (mzscheme_init()) +*************** +*** 2947,2966 **** + } + + MZ_GC_CHECK(); +- visited = scheme_make_hash_table(SCHEME_hash_ptr); +- MZ_GC_CHECK(); +- + if (eval_with_exn_handling(str, do_eval, &ret) == OK) +! mzscheme_to_vim(ret, rettv, 1, visited); +! +! for (i = 0; i < visited->size; ++i) +! { +! /* free up remembered objects */ +! if (visited->vals[i] != NULL) +! { +! free_tv((typval_T *)visited->vals[i]); +! } +! } + + MZ_GC_UNREG(); + } +--- 3200,3207 ---- + } + + MZ_GC_CHECK(); + if (eval_with_exn_handling(str, do_eval, &ret) == OK) +! mzscheme_to_vim(ret, rettv); + + MZ_GC_UNREG(); + } +*************** +*** 3043,3079 **** + char *fmt = _("Vim error: ~a"); + Scheme_Object *argv[2] = {NULL, NULL}; + Scheme_Object *exn = NULL; + +! MZ_GC_DECL_REG(4); + MZ_GC_ARRAY_VAR_IN_REG(0, argv, 2); + MZ_GC_VAR_IN_REG(3, exn); + MZ_GC_REG(); + + if (add_info != NULL) + { + char *c_string = NULL; +- Scheme_Object *byte_string = NULL; + Scheme_Object *info = NULL; + + MZ_GC_DECL_REG(3); + MZ_GC_VAR_IN_REG(0, c_string); +- MZ_GC_VAR_IN_REG(1, byte_string); + MZ_GC_VAR_IN_REG(2, info); + MZ_GC_REG(); + +! info = scheme_make_string(add_info); + MZ_GC_CHECK(); +! c_string = scheme_format(fmt, STRLEN(fmt), 1, &info, NULL); + MZ_GC_CHECK(); +! byte_string = scheme_make_string(c_string); + MZ_GC_CHECK(); + argv[0] = scheme_byte_string_to_char_string(byte_string); +- MZ_GC_CHECK(); + SCHEME_SET_IMMUTABLE(argv[0]); + MZ_GC_UNREG(); + } + else +! argv[0] = scheme_make_string(_("Vim error")); + MZ_GC_CHECK(); + + #if MZSCHEME_VERSION_MAJOR < 360 +--- 3284,3324 ---- + char *fmt = _("Vim error: ~a"); + Scheme_Object *argv[2] = {NULL, NULL}; + Scheme_Object *exn = NULL; ++ Scheme_Object *byte_string = NULL; + +! MZ_GC_DECL_REG(5); + MZ_GC_ARRAY_VAR_IN_REG(0, argv, 2); + MZ_GC_VAR_IN_REG(3, exn); ++ MZ_GC_VAR_IN_REG(4, byte_string); + MZ_GC_REG(); + + if (add_info != NULL) + { + char *c_string = NULL; + Scheme_Object *info = NULL; + + MZ_GC_DECL_REG(3); + MZ_GC_VAR_IN_REG(0, c_string); + MZ_GC_VAR_IN_REG(2, info); + MZ_GC_REG(); + +! info = scheme_make_byte_string(add_info); + MZ_GC_CHECK(); +! c_string = scheme_format_utf8(fmt, STRLEN(fmt), 1, &info, NULL); + MZ_GC_CHECK(); +! byte_string = scheme_make_byte_string(c_string); + MZ_GC_CHECK(); + argv[0] = scheme_byte_string_to_char_string(byte_string); + SCHEME_SET_IMMUTABLE(argv[0]); + MZ_GC_UNREG(); + } + else +! { +! byte_string = scheme_make_byte_string(_("Vim error")); +! MZ_GC_CHECK(); +! argv[0] = scheme_byte_string_to_char_string(byte_string); +! MZ_GC_CHECK(); +! } + MZ_GC_CHECK(); + + #if MZSCHEME_VERSION_MAJOR < 360 +*************** +*** 3264,3270 **** + if (curbuf->b_mzscheme_ref == NULL) + return (vim_mz_buffer *)buffer_new(curbuf); + else +! return (vim_mz_buffer *)curbuf->b_mzscheme_ref; + } + + /* return MzScheme wrapper for curwin */ +--- 3509,3515 ---- + if (curbuf->b_mzscheme_ref == NULL) + return (vim_mz_buffer *)buffer_new(curbuf); + else +! return BUFFER_REF(curbuf); + } + + /* return MzScheme wrapper for curwin */ +*************** +*** 3274,3280 **** + if (curwin->w_mzscheme_ref == NULL) + return (vim_mz_window *)window_new(curwin); + else +! return (vim_mz_window *)curwin->w_mzscheme_ref; + } + + static void +--- 3519,3525 ---- + if (curwin->w_mzscheme_ref == NULL) + return (vim_mz_window *)window_new(curwin); + else +! return WINDOW_REF(curwin); + } + + static void +*** ../vim-7.3.790/src/if_mzsch.h 2010-08-15 21:57:29.000000000 +0200 +--- src/if_mzsch.h 2013-01-30 14:26:44.000000000 +0100 +*************** +*** 7,12 **** +--- 7,13 ---- + #ifdef __MINGW32__ + /* Hack to engage Cygwin-specific settings */ + # define __CYGWIN32__ ++ # include + #endif + + /* #ifdef needed for "make depend" */ +*************** +*** 20,50 **** + #endif + + #if MZSCHEME_VERSION_MAJOR >= 299 +- /* macros to be compatible with 20x versions */ +- # define scheme_config scheme_current_config() +- # define scheme_make_string scheme_make_byte_string +- # define scheme_make_string_output_port scheme_make_byte_string_output_port +- # define scheme_get_sized_string_output scheme_get_sized_byte_string_output +- # define scheme_write_string scheme_write_byte_string +- # define scheme_make_sized_string scheme_make_sized_byte_string +- + # define SCHEME_STRINGP(obj) (SCHEME_BYTE_STRINGP(obj) || SCHEME_CHAR_STRINGP(obj)) +! # define SCHEME_STR_VAL(obj) SCHEME_BYTE_STR_VAL( \ +! (SCHEME_BYTE_STRINGP(obj) ? obj : scheme_char_string_to_byte_string(obj))) +! # define GUARANTEE_STRING(fname, argnum) GUARANTEE_TYPE(fname, argnum, SCHEME_STRINGP, "string") +! +! # ifdef scheme_format +! # undef scheme_format + # endif +- # define scheme_format scheme_format_utf8 + +- # define SCHEME_GET_BYTE_STRING(obj) (SCHEME_BYTE_STRINGP(obj) ? obj : \ +- scheme_char_string_to_byte_string(obj)) +- #else +- # define SCHEME_GET_BYTE_STRING(obj) (obj) + # define SCHEME_BYTE_STRLEN_VAL SCHEME_STRLEN_VAL +! # define SCHEME_BYTE_STR_VAL SCHEME_STR_VAL + # define scheme_byte_string_to_char_string(obj) (obj) + #endif + + /* Precise GC macros */ +--- 21,44 ---- + #endif + + #if MZSCHEME_VERSION_MAJOR >= 299 + # define SCHEME_STRINGP(obj) (SCHEME_BYTE_STRINGP(obj) || SCHEME_CHAR_STRINGP(obj)) +! # define BYTE_STRING_VALUE(obj) ((char_u *)SCHEME_BYTE_STR_VAL(obj)) +! #else +! /* macros for compatibility with older versions */ +! # define scheme_current_config() scheme_config +! # define scheme_make_sized_byte_string scheme_make_sized_string +! # define scheme_format_utf8 scheme_format +! # ifndef DYNAMIC_MZSCHEME +! /* for dynamic MzScheme there will be separate definitions in if_mzsch.c */ +! # define scheme_get_sized_byte_string_output scheme_get_sized_string_output +! # define scheme_make_byte_string scheme_make_string +! # define scheme_make_byte_string_output_port scheme_make_string_output_port + # endif + + # define SCHEME_BYTE_STRLEN_VAL SCHEME_STRLEN_VAL +! # define BYTE_STRING_VALUE(obj) ((char_u *)SCHEME_STR_VAL(obj)) + # define scheme_byte_string_to_char_string(obj) (obj) ++ # define SCHEME_BYTE_STRINGP SCHEME_STRINGP + #endif + + /* Precise GC macros */ +*** ../vim-7.3.790/src/Make_ming.mak 2013-01-23 13:55:16.000000000 +0100 +--- src/Make_ming.mak 2013-01-30 14:26:44.000000000 +0100 +*************** +*** 384,389 **** +--- 384,392 ---- + ifeq (yes, $(DYNAMIC_MZSCHEME)) + CFLAGS += -DDYNAMIC_MZSCHEME -DDYNAMIC_MZSCH_DLL=\"lib$(MZSCHEME_MAIN_LIB)$(MZSCHEME_VER).dll\" -DDYNAMIC_MZGC_DLL=\"libmzgc$(MZSCHEME_VER).dll\" + endif ++ ifeq (yes, "$(MZSCHEME_DEBUG)") ++ CFLAGS += -DMZSCHEME_FORCE_GC ++ endif + endif + + ifdef RUBY +*** ../vim-7.3.790/src/Make_mvc.mak 2012-12-06 21:30:24.000000000 +0100 +--- src/Make_mvc.mak 2013-01-30 14:26:44.000000000 +0100 +*************** +*** 1096,1102 **** + $(OUTDIR)/if_perlsfio.obj: $(OUTDIR) if_perlsfio.c $(INCL) + $(CC) $(CFLAGS) $(PERL_INC) if_perlsfio.c + +! $(OUTDIR)/if_mzsch.obj: $(OUTDIR) if_mzsch.c $(INCL) $(MZSCHEME_EXTRA_DEP) + $(CC) $(CFLAGS) if_mzsch.c \ + -DMZSCHEME_COLLECTS=\"$(MZSCHEME:\=\\)\\collects\" + mzscheme_base.c: +--- 1096,1102 ---- + $(OUTDIR)/if_perlsfio.obj: $(OUTDIR) if_perlsfio.c $(INCL) + $(CC) $(CFLAGS) $(PERL_INC) if_perlsfio.c + +! $(OUTDIR)/if_mzsch.obj: $(OUTDIR) if_mzsch.c if_mzsch.h $(INCL) $(MZSCHEME_EXTRA_DEP) + $(CC) $(CFLAGS) if_mzsch.c \ + -DMZSCHEME_COLLECTS=\"$(MZSCHEME:\=\\)\\collects\" + mzscheme_base.c: +*** ../vim-7.3.790/src/os_unix.c 2012-10-14 04:35:16.000000000 +0200 +--- src/os_unix.c 2013-01-30 14:26:44.000000000 +0100 +*************** +*** 278,284 **** + #ifdef SIGBUS + {SIGBUS, "BUS", TRUE}, + #endif +! #ifdef SIGSEGV + {SIGSEGV, "SEGV", TRUE}, + #endif + #ifdef SIGSYS +--- 278,285 ---- + #ifdef SIGBUS + {SIGBUS, "BUS", TRUE}, + #endif +! #if defined(SIGSEGV) && !defined(FEAT_MZSCHEME) +! /* MzScheme uses SEGV in its garbage collector */ + {SIGSEGV, "SEGV", TRUE}, + #endif + #ifdef SIGSYS +*************** +*** 3778,3784 **** + # endif + if (wait_pid == 0) + { +! /* Wait for 1/100 sec before trying again. */ + mch_delay(10L, TRUE); + continue; + } +--- 3779,3785 ---- + # endif + if (wait_pid == 0) + { +! /* Wait for 10 msec before trying again. */ + mch_delay(10L, TRUE); + continue; + } +*************** +*** 4797,4803 **** + { + /* LINTED avoid "bitwise operation on signed value" */ + retval = WEXITSTATUS(status); +! if (retval && !emsg_silent) + { + if (retval == EXEC_FAILED) + { +--- 4798,4804 ---- + { + /* LINTED avoid "bitwise operation on signed value" */ + retval = WEXITSTATUS(status); +! if (retval != 0 && !emsg_silent) + { + if (retval == EXEC_FAILED) + { +*** ../vim-7.3.790/src/proto/eval.pro 2012-07-25 16:46:59.000000000 +0200 +--- src/proto/eval.pro 2013-01-30 14:32:04.000000000 +0100 +*************** +*** 74,79 **** +--- 74,80 ---- + char_u *get_function_name __ARGS((expand_T *xp, int idx)); + char_u *get_expr_name __ARGS((expand_T *xp, int idx)); + int func_call __ARGS((char_u *name, typval_T *args, dict_T *selfdict, typval_T *rettv)); ++ void mzscheme_call_vim __ARGS((char_u *name, typval_T *args, typval_T *rettv)); + long do_searchpair __ARGS((char_u *spat, char_u *mpat, char_u *epat, int dir, char_u *skip, int flags, pos_T *match_pos, linenr_T lnum_stop, long time_limit)); + void set_vim_var_nr __ARGS((int idx, long val)); + long get_vim_var_nr __ARGS((int idx)); +*** ../vim-7.3.790/src/testdir/test70.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test70.in 2013-01-30 14:50:02.000000000 +0100 +*************** +*** 38,49 **** + :" circular list (at the same time test lists containing lists) + :mz (set-car! (cddr l) l) + :let l2 = mzeval("h")["list"] +! :if l2[2] == l2 + :let res = "OK" + :else +! :let res = "FAILED" + :endif + :call setline(search("^3"), "circular test " . res) + :?^1?,$w! test.out + :qa! + ENDTEST +--- 38,60 ---- + :" circular list (at the same time test lists containing lists) + :mz (set-car! (cddr l) l) + :let l2 = mzeval("h")["list"] +! :" bug: this returns item2, but it should be l2 +! :if l2[2] == "item2" + :let res = "OK" + :else +! :let res = "FAILED: " . l2[2] + :endif + :call setline(search("^3"), "circular test " . res) ++ :" funcrefs ++ :mz (define vim:max (vim-eval "function('max')")) ++ :mz (define m (vim:max '(1 100 8))) ++ :let m = mzeval('m') ++ :if m == 100 ++ :let fref_res = "OK" ++ :else ++ :let fref_res = "FAILED: " . m ++ :end ++ :call append(line('$'), 'funcrefs '. fref_res) + :?^1?,$w! test.out + :qa! + ENDTEST +*** ../vim-7.3.790/src/testdir/test70.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test70.ok 2013-01-30 14:26:44.000000000 +0100 +*************** +*** 3,5 **** +--- 3,6 ---- + 2 line 2 + dictionary with list OK + circular test OK ++ funcrefs OK +*** ../vim-7.3.790/src/version.c 2013-01-30 14:13:52.000000000 +0100 +--- src/version.c 2013-01-30 14:52:31.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 791, + /**/ + + +-- +5 out of 4 people have trouble with fractions. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 41c58d657d3103bcf64323875518a9c6d2a92bd2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 31 Jan 2013 12:11:59 +0100 Subject: [PATCH 0674/3340] - patchlevel 792 --- 7.3.792 | 131 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 131 insertions(+) create mode 100644 7.3.792 diff --git a/7.3.792 b/7.3.792 new file mode 100644 index 00000000..cddcc62e --- /dev/null +++ b/7.3.792 @@ -0,0 +1,131 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.792 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.792 +Problem: ":substitute" works differently without confirmation. +Solution: Do not change the text when asking for confirmation, only display + it. +Files: src/ex_cmds.c + + +*** ../vim-7.3.791/src/ex_cmds.c 2013-01-17 18:33:58.000000000 +0100 +--- src/ex_cmds.c 2013-01-30 16:01:58.000000000 +0100 +*************** +*** 4727,4732 **** +--- 4727,4734 ---- + } + else + { ++ char_u *orig_line = NULL; ++ int len_change = 0; + #ifdef FEAT_FOLDING + int save_p_fen = curwin->w_p_fen; + +*************** +*** 4737,4745 **** + temp = RedrawingDisabled; + RedrawingDisabled = 0; + + search_match_lines = regmatch.endpos[0].lnum + - regmatch.startpos[0].lnum; +! search_match_endcol = regmatch.endpos[0].col; + highlight_match = TRUE; + + update_topline(); +--- 4739,4781 ---- + temp = RedrawingDisabled; + RedrawingDisabled = 0; + ++ if (new_start != NULL) ++ { ++ /* There already was a substitution, we would ++ * like to show this to the user. We cannot ++ * really update the line, it would change ++ * what matches. Temporarily replace the line ++ * and change it back afterwards. */ ++ orig_line = vim_strsave(ml_get(lnum)); ++ if (orig_line != NULL) ++ { ++ char_u *new_line = concat_str(new_start, ++ sub_firstline + copycol); ++ ++ if (new_line == NULL) ++ { ++ vim_free(orig_line); ++ orig_line = NULL; ++ } ++ else ++ { ++ /* Position the cursor relative to the ++ * end of the line, the previous ++ * substitute may have inserted or ++ * deleted characters before the ++ * cursor. */ ++ len_change = STRLEN(new_line) ++ - STRLEN(orig_line); ++ curwin->w_cursor.col += len_change; ++ ml_replace(lnum, new_line, FALSE); ++ } ++ } ++ } ++ + search_match_lines = regmatch.endpos[0].lnum + - regmatch.startpos[0].lnum; +! search_match_endcol = regmatch.endpos[0].col +! + len_change; + highlight_match = TRUE; + + update_topline(); +*************** +*** 4781,4786 **** +--- 4817,4826 ---- + msg_didout = FALSE; /* don't scroll up */ + msg_col = 0; + gotocmdline(TRUE); ++ ++ /* restore the line */ ++ if (orig_line != NULL) ++ ml_replace(lnum, orig_line, FALSE); + } + + need_wait_return = FALSE; /* no hit-return prompt */ +*************** +*** 5045,5058 **** + * The check for nmatch_tl is needed for when multi-line + * matching must replace the lines before trying to do another + * match, otherwise "\@<=" won't work. +- * When asking the user we like to show the already replaced +- * text, but don't do it when "\<@=" or "\<@!" is used, it +- * changes what matches. + * When the match starts below where we start searching also + * need to replace the line first (using \zs after \n). + */ + if (lastone +- || (do_ask && !re_lookbehind(regmatch.regprog)) + || nmatch_tl > 0 + || (nmatch = vim_regexec_multi(®match, curwin, + curbuf, sub_firstlnum, +--- 5085,5094 ---- +*** ../vim-7.3.791/src/version.c 2013-01-30 14:55:35.000000000 +0100 +--- src/version.c 2013-01-30 16:25:36.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 792, + /**/ + +-- +Trees moving back and forth is what makes the wind blow. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 917cd9ef4ca9cb08bbf7eb3afeb40293f879dcbb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 31 Jan 2013 12:12:00 +0100 Subject: [PATCH 0675/3340] - patchlevel 793 --- 7.3.793 | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 7.3.793 diff --git a/7.3.793 b/7.3.793 new file mode 100644 index 00000000..b188d9d1 --- /dev/null +++ b/7.3.793 @@ -0,0 +1,72 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.793 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.793 (after 7.3.792) +Problem: New interactive :substutite behavior is not tested. +Solution: Add tests. (Christian Brabandt) +Files: src/testdir/test80.in, src/testdir/test80.ok + + +*** ../vim-7.3.792/src/testdir/test80.in 2011-06-19 04:31:54.000000000 +0200 +--- src/testdir/test80.in 2013-01-30 17:00:54.000000000 +0100 +*************** +*** 144,149 **** +--- 144,164 ---- + TEST_8: + + STARTTEST ++ :set magic& ++ :set cpo& ++ :$put =\"\n\nTEST_8:\" ++ :$put =',,X' ++ :s/\(^\|,\)\ze\(,\|X\)/\1N/g ++ :$put =',,Y' ++ :s/\(^\|,\)\ze\(,\|Y\)/\1N/gc ++ a:$put =',,Z' ++ :s/\(^\|,\)\ze\(,\|Z\)/\1N/gc ++ yy/^TEST_9 ++ ENDTEST ++ ++ TEST_9: ++ ++ STARTTEST + :/^Results/,$wq! test.out + ENDTEST + +*** ../vim-7.3.792/src/testdir/test80.ok 2011-06-19 04:31:54.000000000 +0200 +--- src/testdir/test80.ok 2013-01-30 16:46:39.000000000 +0100 +*************** +*** 99,101 **** +--- 99,107 ---- + A A + B + B ++ ++ ++ TEST_8: ++ N,,NX ++ N,,NY ++ N,,NZ +*** ../vim-7.3.792/src/version.c 2013-01-30 16:30:19.000000000 +0100 +--- src/version.c 2013-01-30 17:01:33.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 793, + /**/ + +-- +The early bird gets the worm. The second mouse gets the cheese. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4e4882d20d0469d9618605c6453a0c348df05478 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 31 Jan 2013 12:12:01 +0100 Subject: [PATCH 0676/3340] - patchlevel 794 --- 7.3.794 | 75 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 75 insertions(+) create mode 100644 7.3.794 diff --git a/7.3.794 b/7.3.794 new file mode 100644 index 00000000..62263f63 --- /dev/null +++ b/7.3.794 @@ -0,0 +1,75 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.794 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.794 +Problem: Tiny build fails. (Tony Mechelynck) +Solution: Adjust #ifdefs. +Files: src/charset.c + + +*** ../vim-7.3.793/src/charset.c 2013-01-23 15:53:08.000000000 +0100 +--- src/charset.c 2013-01-30 17:08:05.000000000 +0100 +*************** +*** 939,957 **** + return GET_CHARTAB(curbuf, *p) != 0; + } + +- #if defined(FEAT_SYN_HL) || defined(PROTO) + int + vim_iswordp_buf(p, buf) + char_u *p; + buf_T *buf; + { +! # ifdef FEAT_MBYTE + if (has_mbyte && MB_BYTE2LEN(*p) > 1) + return mb_get_class(p) >= 2; +! # endif + return (GET_CHARTAB(buf, *p) != 0); + } +- #endif + + /* + * return TRUE if 'c' is a valid file-name character +--- 939,955 ---- + return GET_CHARTAB(curbuf, *p) != 0; + } + + int + vim_iswordp_buf(p, buf) + char_u *p; + buf_T *buf; + { +! #ifdef FEAT_MBYTE + if (has_mbyte && MB_BYTE2LEN(*p) > 1) + return mb_get_class(p) >= 2; +! #endif + return (GET_CHARTAB(buf, *p) != 0); + } + + /* + * return TRUE if 'c' is a valid file-name character +*** ../vim-7.3.793/src/version.c 2013-01-30 17:03:25.000000000 +0100 +--- src/version.c 2013-01-30 17:28:04.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 794, + /**/ + +-- +LAUNCELOT: I am, sir. I am a Knight of King Arthur. +FATHER: 'Mm ... very nice castle, Camelot ... very good pig country.... + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6053b4e14242c5dc9e7930a1374aeebf13314de7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 31 Jan 2013 12:12:02 +0100 Subject: [PATCH 0677/3340] - patchlevel 795 --- 7.3.795 | 212 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 212 insertions(+) create mode 100644 7.3.795 diff --git a/7.3.795 b/7.3.795 new file mode 100644 index 00000000..283fd8db --- /dev/null +++ b/7.3.795 @@ -0,0 +1,212 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.795 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.795 +Problem: MzScheme does not build with tiny features. +Solution: Add #ifdefs. Also add UNUSED to avoid warnings. And change + library ordering. +Files: src/if_mzsch.c, src/Makefile + + +*** ../vim-7.3.794/src/if_mzsch.c 2013-01-30 14:55:35.000000000 +0100 +--- src/if_mzsch.c 2013-01-30 17:23:07.000000000 +0100 +*************** +*** 1483,1489 **** + + /* (eval {expr-string}) */ + static Scheme_Object * +! vim_eval(void *data, int argc, Scheme_Object **argv) + { + #ifdef FEAT_EVAL + Vim_Prim *prim = (Vim_Prim *)data; +--- 1483,1489 ---- + + /* (eval {expr-string}) */ + static Scheme_Object * +! vim_eval(void *data UNUSED, int argc UNUSED, Scheme_Object **argv UNUSED) + { + #ifdef FEAT_EVAL + Vim_Prim *prim = (Vim_Prim *)data; +*************** +*** 1686,1695 **** + static Scheme_Object * + get_window_count(void *data UNUSED, int argc UNUSED, Scheme_Object **argv UNUSED) + { +- win_T *w; + int n = 0; + + for (w = firstwin; w != NULL; w = w->w_next) + ++n; + return scheme_make_integer(n); + } +--- 1686,1697 ---- + static Scheme_Object * + get_window_count(void *data UNUSED, int argc UNUSED, Scheme_Object **argv UNUSED) + { + int n = 0; ++ #ifdef FEAT_WINDOWS ++ win_T *w; + + for (w = firstwin; w != NULL; w = w->w_next) ++ #endif + ++n; + return scheme_make_integer(n); + } +*************** +*** 1701,1712 **** + Vim_Prim *prim = (Vim_Prim *)data; + vim_mz_buffer *buf; + Scheme_Object *list; +! win_T *w; + + buf = get_buffer_arg(prim->name, 0, argc, argv); + list = scheme_null; + +! for (w = firstwin; w != NULL; w = w->w_next) + if (w->w_buffer == buf->buf) + { + list = scheme_make_pair(window_new(w), list); +--- 1703,1716 ---- + Vim_Prim *prim = (Vim_Prim *)data; + vim_mz_buffer *buf; + Scheme_Object *list; +! win_T *w = firstwin; + + buf = get_buffer_arg(prim->name, 0, argc, argv); + list = scheme_null; + +! #ifdef FEAT_WINDOWS +! for ( ; w != NULL; w = w->w_next) +! #endif + if (w->w_buffer == buf->buf) + { + list = scheme_make_pair(window_new(w), list); +*************** +*** 1755,1768 **** + + /* (get-win-num [window]) */ + static Scheme_Object * +! get_window_num(void *data, int argc, Scheme_Object **argv) + { + Vim_Prim *prim = (Vim_Prim *)data; + win_T *win = get_window_arg(prim->name, 0, argc, argv)->win; +- int nr = 1; + win_T *wp; + + for (wp = firstwin; wp != win; wp = wp->w_next) + ++nr; + + return scheme_make_integer(nr); +--- 1759,1774 ---- + + /* (get-win-num [window]) */ + static Scheme_Object * +! get_window_num(void *data UNUSED, int argc UNUSED, Scheme_Object **argv UNUSED) + { ++ int nr = 1; ++ #ifdef FEAT_WINDOWS + Vim_Prim *prim = (Vim_Prim *)data; + win_T *win = get_window_arg(prim->name, 0, argc, argv)->win; + win_T *wp; + + for (wp = firstwin; wp != win; wp = wp->w_next) ++ #endif + ++nr; + + return scheme_make_integer(nr); +*************** +*** 1773,1786 **** + get_window_by_num(void *data, int argc, Scheme_Object **argv) + { + Vim_Prim *prim = (Vim_Prim *)data; +! win_T *win; + int fnum; + + fnum = SCHEME_INT_VAL(GUARANTEE_INTEGER(prim->name, 0)); + if (fnum < 1) + scheme_signal_error(_("window index is out of range")); + +! for (win = firstwin; win != NULL; win = win->w_next, --fnum) + if (fnum == 1) /* to be 1-based */ + return window_new(win); + +--- 1779,1794 ---- + get_window_by_num(void *data, int argc, Scheme_Object **argv) + { + Vim_Prim *prim = (Vim_Prim *)data; +! win_T *win = firstwin; + int fnum; + + fnum = SCHEME_INT_VAL(GUARANTEE_INTEGER(prim->name, 0)); + if (fnum < 1) + scheme_signal_error(_("window index is out of range")); + +! #ifdef FEAT_WINDOWS +! for ( ; win != NULL; win = win->w_next, --fnum) +! #endif + if (fnum == 1) /* to be 1-based */ + return window_new(win); + +*** ../vim-7.3.794/src/Makefile 2012-11-20 17:03:23.000000000 +0100 +--- src/Makefile 2013-01-30 17:34:55.000000000 +0100 +*************** +*** 1345,1350 **** +--- 1345,1352 ---- + + DEPEND_CFLAGS = -DPROTO -DDEPEND -DFEAT_GUI $(LINT_CFLAGS) + ++ # Note: MZSCHEME_LIBS must come before LIBS, because LIBS adds -lm which is ++ # needed by racket. + ALL_LIB_DIRS = $(GUI_LIBS_DIR) $(X_LIBS_DIR) + ALL_LIBS = \ + $(GUI_LIBS1) \ +*************** +*** 1353,1362 **** + $(X_PRE_LIBS) \ + $(X_LIBS) \ + $(X_EXTRA_LIBS) \ + $(LIBS) \ + $(EXTRA_LIBS) \ + $(LUA_LIBS) \ +- $(MZSCHEME_LIBS) \ + $(PERL_LIBS) \ + $(PYTHON_LIBS) \ + $(PYTHON3_LIBS) \ +--- 1355,1364 ---- + $(X_PRE_LIBS) \ + $(X_LIBS) \ + $(X_EXTRA_LIBS) \ ++ $(MZSCHEME_LIBS) \ + $(LIBS) \ + $(EXTRA_LIBS) \ + $(LUA_LIBS) \ + $(PERL_LIBS) \ + $(PYTHON_LIBS) \ + $(PYTHON3_LIBS) \ +*** ../vim-7.3.794/src/version.c 2013-01-30 17:30:14.000000000 +0100 +--- src/version.c 2013-01-30 17:38:25.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 795, + /**/ + +-- +GUEST: He's killed the best man! +SECOND GUEST: (holding a limp WOMAN) He's killed my auntie. +FATHER: No, please! This is supposed to be a happy occasion! Let's + not bicker and argue about who killed who ... + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f6463ab671a18854f86a76c0dc43283b0a8c8567 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 31 Jan 2013 12:12:03 +0100 Subject: [PATCH 0678/3340] - patchlevel 796 --- 7.3.796 | Bin 0 -> 3027 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 7.3.796 diff --git a/7.3.796 b/7.3.796 new file mode 100644 index 0000000000000000000000000000000000000000..333600dfb2fe8d4e67bf81ff057d4f47b5e91083 GIT binary patch literal 3027 zcmcImZExE)5Z>1a*nfCx3~1t5qGdaAtS&wh0e z*^Zs0K(}E844KEf5uhxd^XQOY7I^0D%UB6GU=;EoM-fD5XJF`8c8 zYqqwX!{IQ1$n`)xI)_qZ0rn)#a4JN~IHeN5n*IB1zV|rOzd5H##@r7~szmSrzE^cR zf@{XL+nbJA0L>mX8K*Si?=Xz1R7~$)_YU2iCq7BJ8Zqe}@SzA39tGGLB-(M8mgB72 zdLhLiWmy0KCGz>E&%cxq3Z{@*pQr{!nsA1JWc1#1x+2ZBH4!+a_Y8?fD4=5oMKcDf zP$FK*!+Ix{iP8z>#{B{1q26!~lawiY8KC5lNEWfju{W&Pon}ghiL~El%S-sHWO45} zPPtr$=aGjba|_tF$g;k*TGg++Ro|^w;n#z$R#5l7>U?3d>Q}1;$(J!O|LGUF`ZMY`8?hPKz7LbuPfGqTut^!$D&djw zFySf*89v{9DQbiZZEBH643n7Zc@WA)h?(+Gnw3kri=%JY)mZ5rwWWshs`R2= zHG{3~z<=4UUIVvQ^(!^sFZzywwjgZHfh9M+gKp2XnY%!dwnzHADj!&g)~g$H`rZrr zCdkd@FU}?cMJ{a$U#^OJrI8Q=DoaMk!P&mK#({~E`FGn49H9Mk+X41|+H*E>X@8cX z+iPF-X8b`!ZWepuRmjau7YTn5dU5|>pf98s(C-A*t)S6b37nY}uR-toTNU5md4k>& zYSlUP)_3FoviIK^TMxz9_f|(xGidlhqyEC0`P_P4YA5hpLG8x|SF_fvG;2#fSVDc_ z!`E4Tg`q8|v3(NoJR2~H0ZYXMI!;vaJ}48DHD&uTtJ&JFIHo+y#Bp2~&SATEbZ`~m zBLkHTF_R2hgmelmOsR9GiYA%!L~w`^^h97PavovK#5iSUkm{H@RzH9{F&*V827-r{ zJ!XhSI>m&AsTkgSz%?HUsdG*>OQ#hG&Ss2R1=$oz@P)D?CI?LF3Sz2oXQtbTrYYmb zI^$%>sE$3u{`oYQSuPbuQe@~{oqyba2ixBFu8#K)pfdByDY}HcY zJbz!huBE(Ryg1DZ(@ Date: Thu, 31 Jan 2013 12:12:03 +0100 Subject: [PATCH 0679/3340] - patchlevel 797 --- 7.3.797 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.797 diff --git a/7.3.797 b/7.3.797 new file mode 100644 index 00000000..09d638a6 --- /dev/null +++ b/7.3.797 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.797 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.797 (after 7.3.792) +Problem: Compiler warning for size_t to int conversion. (Skeept) +Solution: Add type casts. +Files: src/ex_cmds.c + + +*** ../vim-7.3.796/src/ex_cmds.c 2013-01-30 16:30:19.000000000 +0100 +--- src/ex_cmds.c 2013-01-30 21:52:17.000000000 +0100 +*************** +*** 4764,4771 **** + * substitute may have inserted or + * deleted characters before the + * cursor. */ +! len_change = STRLEN(new_line) +! - STRLEN(orig_line); + curwin->w_cursor.col += len_change; + ml_replace(lnum, new_line, FALSE); + } +--- 4764,4771 ---- + * substitute may have inserted or + * deleted characters before the + * cursor. */ +! len_change = (int)STRLEN(new_line) +! - (int)STRLEN(orig_line); + curwin->w_cursor.col += len_change; + ml_replace(lnum, new_line, FALSE); + } +*** ../vim-7.3.796/src/version.c 2013-01-30 21:55:22.000000000 +0100 +--- src/version.c 2013-01-30 21:53:17.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 797, + /**/ + +-- + [SIR LAUNCELOT runs back up the stairs, grabs a rope + of the wall and swings out over the heads of the CROWD in a + swashbuckling manner towards a large window. He stops just short + of the window and is left swing pathetically back and forth.] +LAUNCELOT: Excuse me ... could somebody give me a push ... + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 93b11c4c89cc2aaef077aa21a23095f1208f139f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 31 Jan 2013 12:12:05 +0100 Subject: [PATCH 0680/3340] - patchlevel 797 --- README.patches | 12 ++++++++++++ vim.spec | 29 ++++++++++++++++++++++++++++- 2 files changed, 40 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index b186397c..c32f02dc 100644 --- a/README.patches +++ b/README.patches @@ -816,3 +816,15 @@ Individual patches for Vim 7.3: 1329 7.3.783 crash when mark is not set 1914 7.3.784 (after 7.3.781) error when 'guifontwide' has a comma 3145 7.3.785 (after 7.3.776) crash with specific use of search pattern + 2928 7.3.786 Python threads don't run in the background (issue 103) + 4304 7.3.787 with 'relativenumber' can't see the absolute line number + 1481 7.3.788 when only using patches build fails on missing nl.po + 5078 7.3.789 (after 7.3.776) "\k" in regexp does not work in other window + 1727 7.3.790 after reloading a buffer the modelines are not processed + 61514 7.3.791 MzScheme interface doesn't work propely + 4000 7.3.792 ":substitute" works differently without confirmation + 1768 7.3.793 (after 7.3.792) new :substutite behavior is not tested + 1999 7.3.794 tiny build fails + 5967 7.3.795 MzScheme does not build with tiny features + 3027 7.3.796 "/[^\n]" does match at a line break + 2040 7.3.797 (after 7.3.792) compiler warning for size_t to int conversion diff --git a/vim.spec b/vim.spec index af2a1c29..da4aaeeb 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 785 +%define patchlevel 797 Summary: The VIM editor URL: http://www.vim.org/ @@ -842,6 +842,18 @@ Patch782: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.782 Patch783: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.783 Patch784: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.784 Patch785: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.785 +Patch786: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.786 +Patch787: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.787 +Patch788: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.788 +Patch789: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.789 +Patch790: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.790 +Patch791: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.791 +Patch792: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.792 +Patch793: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.793 +Patch794: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.794 +Patch795: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.795 +Patch796: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.796 +Patch797: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.797 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1773,6 +1785,18 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch783 -p0 %patch784 -p0 %patch785 -p0 +%patch786 -p0 +%patch787 -p0 +%patch788 -p0 +%patch789 -p0 +%patch790 -p0 +%patch791 -p0 +%patch792 -p0 +%patch793 -p0 +%patch794 -p0 +%patch795 -p0 +%patch796 -p0 +%patch797 -p0 # install spell files @@ -2245,6 +2269,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Thu Jan 31 2013 Karsten Hopp 7.3.797-1 +- patchlevel 797 + * Mon Jan 28 2013 Karsten Hopp 7.3.785-1 - patchlevel 785 From 2a1fde9bf45a6105e75dd48695365b4115a3af46 Mon Sep 17 00:00:00 2001 From: Toshio Kuratomi Date: Fri, 15 Feb 2013 14:20:22 -0800 Subject: [PATCH 0681/3340] Only use --vendor for desktop-file-install on F18 or less --- vim.spec | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/vim.spec b/vim.spec index da4aaeeb..966d1a5f 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1%{?dist} +Release: 2%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -1954,7 +1954,10 @@ install -p -m644 %{SOURCE10} \ ln -sf gvim ./%{_bindir}/vimx %if "%{desktop_file}" == "1" mkdir -p $RPM_BUILD_ROOT/%{_datadir}/applications - desktop-file-install --vendor fedora \ + desktop-file-install \ + %if 0%{?fedora} && 0%{?fedora} < 19 + --vendor fedora \ + %endif --dir $RPM_BUILD_ROOT/%{_datadir}/applications \ %{SOURCE3} # --add-category "Development;TextEditor;X-Red-Hat-Base" D\ @@ -2269,6 +2272,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Fri Feb 15 2013 Toshio Kuratomi - 7.3.797-2 +- Only use --vendor for desktop-file-install on F18 or less + * Thu Jan 31 2013 Karsten Hopp 7.3.797-1 - patchlevel 797 From 6fb3cf1498c80b18e8fa0c541fb41f22c88edccb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:37:49 +0100 Subject: [PATCH 0682/3340] - patchlevel 798 --- 7.3.798 | 103 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 103 insertions(+) create mode 100644 7.3.798 diff --git a/7.3.798 b/7.3.798 new file mode 100644 index 00000000..2133f753 --- /dev/null +++ b/7.3.798 @@ -0,0 +1,103 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.798 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.798 (after 7.3.791) +Problem: MzScheme: circular list does not work correctly. +Solution: Separate Mac-specific code from generic code. (Sergey Khorev) +Files: src/if_mzsch.c, src/testdir/test70.in + + +*** ../vim-7.3.797/src/if_mzsch.c 2013-01-30 17:41:43.000000000 +0100 +--- src/if_mzsch.c 2013-01-31 21:00:02.000000000 +0100 +*************** +*** 965,970 **** +--- 965,971 ---- + #ifdef MZSCHEME_COLLECTS + /* setup 'current-library-collection-paths' parameter */ + # if MZSCHEME_VERSION_MAJOR >= 299 ++ # ifdef MACOS + { + Scheme_Object *coll_byte_string = NULL; + Scheme_Object *coll_char_string = NULL; +*************** +*** 985,990 **** +--- 986,1021 ---- + MZ_GC_CHECK(); + MZ_GC_UNREG(); + } ++ # else ++ { ++ Scheme_Object *coll_byte_string = NULL; ++ Scheme_Object *coll_char_string = NULL; ++ Scheme_Object *coll_path = NULL; ++ Scheme_Object *coll_pair = NULL; ++ Scheme_Config *config = NULL; ++ ++ MZ_GC_DECL_REG(5); ++ MZ_GC_VAR_IN_REG(0, coll_byte_string); ++ MZ_GC_VAR_IN_REG(1, coll_char_string); ++ MZ_GC_VAR_IN_REG(2, coll_path); ++ MZ_GC_VAR_IN_REG(3, coll_pair); ++ MZ_GC_VAR_IN_REG(4, config); ++ MZ_GC_REG(); ++ coll_byte_string = scheme_make_byte_string(MZSCHEME_COLLECTS); ++ MZ_GC_CHECK(); ++ coll_char_string = scheme_byte_string_to_char_string(coll_byte_string); ++ MZ_GC_CHECK(); ++ coll_path = scheme_char_string_to_path(coll_char_string); ++ MZ_GC_CHECK(); ++ coll_pair = scheme_make_pair(coll_path, scheme_null); ++ MZ_GC_CHECK(); ++ config = scheme_current_config(); ++ MZ_GC_CHECK(); ++ scheme_set_param(config, MZCONFIG_COLLECTION_PATHS, coll_pair); ++ MZ_GC_CHECK(); ++ MZ_GC_UNREG(); ++ } ++ # endif + # else + { + Scheme_Object *coll_string = NULL; +*** ../vim-7.3.797/src/testdir/test70.in 2013-01-30 14:55:35.000000000 +0100 +--- src/testdir/test70.in 2013-01-31 21:00:06.000000000 +0100 +*************** +*** 38,45 **** + :" circular list (at the same time test lists containing lists) + :mz (set-car! (cddr l) l) + :let l2 = mzeval("h")["list"] +! :" bug: this returns item2, but it should be l2 +! :if l2[2] == "item2" + :let res = "OK" + :else + :let res = "FAILED: " . l2[2] +--- 38,44 ---- + :" circular list (at the same time test lists containing lists) + :mz (set-car! (cddr l) l) + :let l2 = mzeval("h")["list"] +! :if l2[2] == l2 + :let res = "OK" + :else + :let res = "FAILED: " . l2[2] +*** ../vim-7.3.797/src/version.c 2013-01-30 21:55:45.000000000 +0100 +--- src/version.c 2013-01-31 21:01:48.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 798, + /**/ + +-- +Be nice to your kids... they'll be the ones choosing your nursing home. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fdbbb8a8736157579bee84ace3620599fed3fd3b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:37:50 +0100 Subject: [PATCH 0683/3340] - patchlevel 799 --- 7.3.799 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.799 diff --git a/7.3.799 b/7.3.799 new file mode 100644 index 00000000..941203e8 --- /dev/null +++ b/7.3.799 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.799 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.799 +Problem: The color column is not correct when entering a buffer. (Ben + Fritz) +Solution: Call check_colorcolumn() if 'textwidth' changed. (Christian + Brabandt) +Files: src/buffer.c + + +*** ../vim-7.3.798/src/buffer.c 2012-11-20 12:16:54.000000000 +0100 +--- src/buffer.c 2013-02-06 11:52:54.000000000 +0100 +*************** +*** 1441,1446 **** +--- 1441,1448 ---- + enter_buffer(buf) + buf_T *buf; + { ++ long old_tw = curbuf->b_p_tw; ++ + /* Copy buffer and window local option values. Not for a help buffer. */ + buf_copy_options(buf, BCO_ENTER | BCO_NOHELP); + if (!buf->b_help) +*************** +*** 1464,1469 **** +--- 1466,1473 ---- + + #ifdef FEAT_SYN_HL + curwin->w_s = &(buf->b_s); ++ if (old_tw != buf->b_p_tw) ++ check_colorcolumn(curwin); + #endif + + /* Cursor on first line by default. */ +*** ../vim-7.3.798/src/version.c 2013-01-31 21:09:10.000000000 +0100 +--- src/version.c 2013-02-06 11:55:06.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 799, + /**/ + +-- +I wonder, do vegetarians eat fruit bats? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a2079e03752a7cc479b7bf7c7ea4284ea8509822 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:37:51 +0100 Subject: [PATCH 0684/3340] - patchlevel 800 --- 7.3.800 | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 7.3.800 diff --git a/7.3.800 b/7.3.800 new file mode 100644 index 00000000..5e07e248 --- /dev/null +++ b/7.3.800 @@ -0,0 +1,64 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.800 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.800 +Problem: The " mark is not adjusted when inserting lines. (Roland Eggner) +Solution: Adjust the line number. (Christian Brabandt) +Files: src/mark.c + + +*** ../vim-7.3.799/src/mark.c 2013-01-23 15:53:08.000000000 +0100 +--- src/mark.c 2013-02-06 12:29:46.000000000 +0100 +*************** +*** 1047,1052 **** +--- 1047,1053 ---- + #ifdef FEAT_WINDOWS + tabpage_T *tab; + #endif ++ static pos_T initpos = INIT_POS_T(1, 0, 0); + + if (line2 < line1 && amount_after == 0L) /* nothing to do */ + return; +*************** +*** 1072,1077 **** +--- 1073,1083 ---- + /* last change position */ + one_adjust(&(curbuf->b_last_change.lnum)); + ++ /* last cursor position, if it was set */ ++ if (!equalpos(curbuf->b_last_cursor, initpos)) ++ one_adjust(&(curbuf->b_last_cursor.lnum)); ++ ++ + #ifdef FEAT_JUMPLIST + /* list of change positions */ + for (i = 0; i < curbuf->b_changelistlen; ++i) +*** ../vim-7.3.799/src/version.c 2013-02-06 12:14:36.000000000 +0100 +--- src/version.c 2013-02-06 12:31:15.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 800, + /**/ + +-- +ARTHUR: What does it say? +BROTHER MAYNARD: It reads ... "Here may be found the last words of Joseph of + Aramathea." "He who is valorous and pure of heart may find + the Holy Grail in the aaaaarrrrrrggghhh..." +ARTHUR: What? +BROTHER MAYNARD: "The Aaaaarrrrrrggghhh..." + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a136cf47c6e0bc5e58a3ab119e9f0f1cd1d1f174 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:37:52 +0100 Subject: [PATCH 0685/3340] - patchlevel 801 --- 7.3.801 | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 7.3.801 diff --git a/7.3.801 b/7.3.801 new file mode 100644 index 00000000..d9247ad3 --- /dev/null +++ b/7.3.801 @@ -0,0 +1,61 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.801 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.801 +Problem: ":window set nu?" displays the cursor line. (Nazri Ramliy) +Solution: Do not update the cursor line when conceallevel is zero or the + screen has scrolled. (partly by Christian Brabandt) +Files: src/window.c + + +*** ../vim-7.3.800/src/window.c 2013-01-17 13:59:56.000000000 +0100 +--- src/window.c 2013-02-06 13:28:10.000000000 +0100 +*************** +*** 3991,3999 **** + + #ifdef FEAT_CONCEAL + /* Conceal cursor line in previous window, unconceal in current window. */ +! if (win_valid(owp)) + update_single_line(owp, owp->w_cursor.lnum); +! update_single_line(curwin, curwin->w_cursor.lnum); + #endif + } + +--- 3991,4000 ---- + + #ifdef FEAT_CONCEAL + /* Conceal cursor line in previous window, unconceal in current window. */ +! if (win_valid(owp) && owp->w_p_cole > 0 && !msg_scrolled) + update_single_line(owp, owp->w_cursor.lnum); +! if (curwin->w_p_cole > 0 && !msg_scrolled) +! need_cursor_line_redraw = TRUE; + #endif + } + +*** ../vim-7.3.800/src/version.c 2013-02-06 12:33:15.000000000 +0100 +--- src/version.c 2013-02-06 13:32:28.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 801, + /**/ + +-- +ARTHUR: But if he was dying, he wouldn't bother to carve + "Aaaaarrrrrrggghhh". He'd just say it. +BROTHER MAYNARD: It's down there carved in stone. +GALAHAD: Perhaps he was dictating. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c3bdb205f5d55bbbc5a951c215783a5e9b828593 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:37:53 +0100 Subject: [PATCH 0686/3340] - patchlevel 802 --- 7.3.802 | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 7.3.802 diff --git a/7.3.802 b/7.3.802 new file mode 100644 index 00000000..7b1b62fd --- /dev/null +++ b/7.3.802 @@ -0,0 +1,50 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.802 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.802 +Problem: After setting 'isk' to a value ending in a comma appending to the + option fails. +Solution: Disallow a trailing comma for 'isk' and similar options. +Files: src/charset.c + + +*** ../vim-7.3.801/src/charset.c 2013-01-30 17:30:14.000000000 +0100 +--- src/charset.c 2013-02-06 16:20:01.000000000 +0100 +*************** +*** 284,290 **** +--- 284,295 ---- + } + ++c; + } ++ ++ c = *p; + p = skip_to_option_part(p); ++ if (c == ',' && *p == NUL) ++ /* Trailing comma is not allowed. */ ++ return FAIL; + } + } + chartab_initialized = TRUE; +*** ../vim-7.3.801/src/version.c 2013-02-06 13:37:58.000000000 +0100 +--- src/version.c 2013-02-06 16:21:18.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 802, + /**/ + +-- +Dreams are free, but there's a small charge for alterations. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0d6172b64463ae83e27f67ddf63f12891e11fa79 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:37:54 +0100 Subject: [PATCH 0687/3340] - patchlevel 803 --- 7.3.803 | 106 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 106 insertions(+) create mode 100644 7.3.803 diff --git a/7.3.803 b/7.3.803 new file mode 100644 index 00000000..27944f35 --- /dev/null +++ b/7.3.803 @@ -0,0 +1,106 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.803 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.803 (after 7.3.792) +Problem: Substitute with confirmation and then "q" does not replace + anything. (John McGowan) +Solution: Do not break the loop, skip to the end. +Files: src/ex_cmds.c, src/testdir/test80.in, src/testdir/test80.ok + + +*** ../vim-7.3.802/src/ex_cmds.c 2013-01-30 21:55:45.000000000 +0100 +--- src/ex_cmds.c 2013-02-06 18:13:52.000000000 +0100 +*************** +*** 4878,4884 **** + goto skip; + } + if (got_quit) +! break; + } + + /* Move the cursor to the start of the match, so that we can +--- 4878,4884 ---- + goto skip; + } + if (got_quit) +! goto skip; + } + + /* Move the cursor to the start of the match, so that we can +*** ../vim-7.3.802/src/testdir/test80.in 2013-01-30 17:03:25.000000000 +0100 +--- src/testdir/test80.in 2013-02-06 18:21:07.000000000 +0100 +*************** +*** 153,164 **** + :s/\(^\|,\)\ze\(,\|Y\)/\1N/gc + a:$put =',,Z' + :s/\(^\|,\)\ze\(,\|Z\)/\1N/gc +! yy/^TEST_9 + ENDTEST + + TEST_9: + + STARTTEST + :/^Results/,$wq! test.out + ENDTEST + +--- 153,175 ---- + :s/\(^\|,\)\ze\(,\|Y\)/\1N/gc + a:$put =',,Z' + :s/\(^\|,\)\ze\(,\|Z\)/\1N/gc +! yy/^TEST_9: + ENDTEST + + TEST_9: + + STARTTEST ++ :set magic& ++ :set cpo& ++ :$put =\"\n\nTEST_9:\" ++ :$put ='xxx' ++ :s/x/X/gc ++ yyq/^TEST_10: ++ ENDTEST ++ ++ TEST_10: ++ ++ STARTTEST + :/^Results/,$wq! test.out + ENDTEST + +*** ../vim-7.3.802/src/testdir/test80.ok 2013-01-30 17:03:25.000000000 +0100 +--- src/testdir/test80.ok 2013-02-06 18:21:16.000000000 +0100 +*************** +*** 105,107 **** +--- 105,111 ---- + N,,NX + N,,NY + N,,NZ ++ ++ ++ TEST_9: ++ XXx +*** ../vim-7.3.802/src/version.c 2013-02-06 16:26:20.000000000 +0100 +--- src/version.c 2013-02-06 18:14:42.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 803, + /**/ + +-- +To the optimist, the glass is half full. +To the pessimist, the glass is half empty. +To the engineer, the glass is twice as big as it needs to be. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0194ec7a2f2820281a3d3a0c4e32059a74b7c12e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:37:55 +0100 Subject: [PATCH 0688/3340] - patchlevel 804 --- 7.3.804 | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 7.3.804 diff --git a/7.3.804 b/7.3.804 new file mode 100644 index 00000000..b9a7f9ca --- /dev/null +++ b/7.3.804 @@ -0,0 +1,46 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.804 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.804 (after 7.3.799) +Problem: Compiler warning for tiny build. (Tony Mechelynck) +Solution: Add #ifdefs around variable. +Files: src/buffer.c + + +*** ../vim-7.3.803/src/buffer.c 2013-02-06 12:14:36.000000000 +0100 +--- src/buffer.c 2013-02-06 18:42:05.000000000 +0100 +*************** +*** 1441,1447 **** +--- 1441,1449 ---- + enter_buffer(buf) + buf_T *buf; + { ++ #ifdef FEAT_SYN_HL + long old_tw = curbuf->b_p_tw; ++ #endif + + /* Copy buffer and window local option values. Not for a help buffer. */ + buf_copy_options(buf, BCO_ENTER | BCO_NOHELP); +*** ../vim-7.3.803/src/version.c 2013-02-06 18:23:58.000000000 +0100 +--- src/version.c 2013-02-06 18:42:59.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 804, + /**/ + +-- +Sorry, no fortune today. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c91c20960ec03f1563e27a2dad877551afa4b93e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:37:56 +0100 Subject: [PATCH 0689/3340] - patchlevel 805 --- 7.3.805 | 99 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 99 insertions(+) create mode 100644 7.3.805 diff --git a/7.3.805 b/7.3.805 new file mode 100644 index 00000000..5604ccee --- /dev/null +++ b/7.3.805 @@ -0,0 +1,99 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.805 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.805 +Problem: Lua version 5.2 is not detected properly on Arch Linux. +Solution: Adjust autoconf. (lilydjwg) +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.804/src/configure.in 2013-01-30 14:55:34.000000000 +0100 +--- src/configure.in 2013-02-06 19:22:17.000000000 +0100 +*************** +*** 496,508 **** + else + dnl Determine the SONAME for the current version, but fallback to + dnl liblua${vi_cv_version_lua}.so if no SONAME-versioned file is found. +! for i in 0 1 2 3 4 5 6 7 8 9; do +! if test -f "${vi_cv_path_lua_pfx}/lib/liblua${vi_cv_version_lua}.so.$i"; then +! LUA_SONAME=".$i" +! break +! fi + done +- vi_cv_dll_name_lua="liblua${vi_cv_version_lua}.so$LUA_SONAME" + fi + AC_DEFINE(DYNAMIC_LUA) + LUA_LIBS="" +--- 496,510 ---- + else + dnl Determine the SONAME for the current version, but fallback to + dnl liblua${vi_cv_version_lua}.so if no SONAME-versioned file is found. +! for LUA_SOVER in "${vi_cv_version_lua}.so" ".so.${vi_cv_version_lua}"; do +! for i in 0 1 2 3 4 5 6 7 8 9; do +! if test -f "${vi_cv_path_lua_pfx}/lib/liblua${LUA_SOVER}.$i"; then +! LUA_SONAME=".$i" +! break +! fi +! done +! vi_cv_dll_name_lua="liblua${LUA_SOVER}$LUA_SONAME" + done + fi + AC_DEFINE(DYNAMIC_LUA) + LUA_LIBS="" +*** ../vim-7.3.804/src/auto/configure 2013-01-30 14:55:34.000000000 +0100 +--- src/auto/configure 2013-02-06 19:24:11.000000000 +0100 +*************** +*** 4737,4749 **** + if test -f "${vi_cv_path_lua_pfx}/bin/cyglua-${vi_cv_version_lua}.dll"; then + vi_cv_dll_name_lua="cyglua-${vi_cv_version_lua}.dll" + else +! for i in 0 1 2 3 4 5 6 7 8 9; do +! if test -f "${vi_cv_path_lua_pfx}/lib/liblua${vi_cv_version_lua}.so.$i"; then +! LUA_SONAME=".$i" +! break +! fi + done +- vi_cv_dll_name_lua="liblua${vi_cv_version_lua}.so$LUA_SONAME" + fi + $as_echo "#define DYNAMIC_LUA 1" >>confdefs.h + +--- 4737,4751 ---- + if test -f "${vi_cv_path_lua_pfx}/bin/cyglua-${vi_cv_version_lua}.dll"; then + vi_cv_dll_name_lua="cyglua-${vi_cv_version_lua}.dll" + else +! for LUA_SOVER in "${vi_cv_version_lua}.so" ".so.${vi_cv_version_lua}"; do +! for i in 0 1 2 3 4 5 6 7 8 9; do +! if test -f "${vi_cv_path_lua_pfx}/lib/liblua${LUA_SOVER}.$i"; then +! LUA_SONAME=".$i" +! break +! fi +! done +! vi_cv_dll_name_lua="liblua${LUA_SOVER}$LUA_SONAME" + done + fi + $as_echo "#define DYNAMIC_LUA 1" >>confdefs.h + +*** ../vim-7.3.804/src/version.c 2013-02-06 18:44:57.000000000 +0100 +--- src/version.c 2013-02-06 19:26:37.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 805, + /**/ + +-- +Permission is granted to read this message out aloud on Kings Cross Road, +London, under the condition that the orator is properly dressed. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a23bd4ee3c14240ad1939a4602e8905381d9b3fc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:37:57 +0100 Subject: [PATCH 0690/3340] - patchlevel 806 --- 7.3.806 | 171 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 171 insertions(+) create mode 100644 7.3.806 diff --git a/7.3.806 b/7.3.806 new file mode 100644 index 00000000..a28cd5b1 --- /dev/null +++ b/7.3.806 @@ -0,0 +1,171 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.806 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.806 +Problem: Compiler warnings in Perl code when building with Visual studio + 2012. (skeept) +Solution: Add type casts. (Christian Brabandt, 2013 Jan 30) +Files: src/if_perl.xs + + +*** ../vim-7.3.805/src/if_perl.xs 2012-09-21 12:50:44.000000000 +0200 +--- src/if_perl.xs 2013-02-06 19:55:12.000000000 +0100 +*************** +*** 1048,1054 **** + { + SV *sv = ST(i); + if (SvIOK(sv)) +! b = SvIV(ST(i)); + else + { + char_u *pat; +--- 1048,1054 ---- + { + SV *sv = ST(i); + if (SvIOK(sv)) +! b = (int) SvIV(ST(i)); + else + { + char_u *pat; +*************** +*** 1091,1097 **** + { + for (i = 0; i < items; i++) + { +! w = SvIV(ST(i)); + vimwin = win_find_nr(w); + if (vimwin) + XPUSHs(newWINrv(newSV(0), vimwin)); +--- 1091,1097 ---- + { + for (i = 0; i < items; i++) + { +! w = (int) SvIV(ST(i)); + vimwin = win_find_nr(w); + if (vimwin) + XPUSHs(newWINrv(newSV(0), vimwin)); +*************** +*** 1154,1161 **** + + if (!win_valid(win)) + win = curwin; +! lnum = SvIV(ST(1)); +! col = SvIV(ST(2)); + win->w_cursor.lnum = lnum; + win->w_cursor.col = col; + check_cursor(); /* put cursor on an existing line */ +--- 1154,1161 ---- + + if (!win_valid(win)) + win = curwin; +! lnum = (int) SvIV(ST(1)); +! col = (int) SvIV(ST(2)); + win->w_cursor.lnum = lnum; + win->w_cursor.col = col; + check_cursor(); /* put cursor on an existing line */ +*************** +*** 1216,1222 **** + { + for (i = 1; i < items; i++) + { +! lnum = SvIV(ST(i)); + if (lnum > 0 && lnum <= vimbuf->b_ml.ml_line_count) + { + line = ml_get_buf(vimbuf, lnum, FALSE); +--- 1216,1222 ---- + { + for (i = 1; i < items; i++) + { +! lnum = (long) SvIV(ST(i)); + if (lnum > 0 && lnum <= vimbuf->b_ml.ml_line_count) + { + line = ml_get_buf(vimbuf, lnum, FALSE); +*************** +*** 1239,1245 **** + if (items < 3) + croak("Usage: VIBUF::Set(vimbuf, lnum, @lines)"); + +! lnum = SvIV(ST(1)); + for(i = 2; i < items; i++, lnum++) + { + line = SvPV(ST(i),PL_na); +--- 1239,1245 ---- + if (items < 3) + croak("Usage: VIBUF::Set(vimbuf, lnum, @lines)"); + +! lnum = (long) SvIV(ST(1)); + for(i = 2; i < items; i++, lnum++) + { + line = SvPV(ST(i),PL_na); +*************** +*** 1274,1286 **** + { + if (items == 2) + { +! lnum = SvIV(ST(1)); + count = 1; + } + else if (items == 3) + { +! lnum = SvIV(ST(1)); +! count = 1 + SvIV(ST(2)) - lnum; + if (count == 0) + count = 1; + if (count < 0) +--- 1274,1286 ---- + { + if (items == 2) + { +! lnum = (long) SvIV(ST(1)); + count = 1; + } + else if (items == 3) + { +! lnum = (long) SvIV(ST(1)); +! count = (long) 1 + SvIV(ST(2)) - lnum; + if (count == 0) + count = 1; + if (count < 0) +*************** +*** 1331,1337 **** + if (items < 3) + croak("Usage: VIBUF::Append(vimbuf, lnum, @lines)"); + +! lnum = SvIV(ST(1)); + for (i = 2; i < items; i++, lnum++) + { + line = SvPV(ST(i),PL_na); +--- 1331,1337 ---- + if (items < 3) + croak("Usage: VIBUF::Append(vimbuf, lnum, @lines)"); + +! lnum = (long) SvIV(ST(1)); + for (i = 2; i < items; i++, lnum++) + { + line = SvPV(ST(i),PL_na); +*** ../vim-7.3.805/src/version.c 2013-02-06 19:49:38.000000000 +0100 +--- src/version.c 2013-02-06 19:58:16.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 806, + /**/ + +-- +BRIDGEKEEPER: What is your favorite colour? +LAUNCELOT: Blue. +BRIDGEKEEPER: Right. Off you go. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4ba41e25ac02cc13706a3b9dbf3bf67776885aac Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:37:58 +0100 Subject: [PATCH 0691/3340] - patchlevel 807 --- 7.3.807 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.807 diff --git a/7.3.807 b/7.3.807 new file mode 100644 index 00000000..95fbbcba --- /dev/null +++ b/7.3.807 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.807 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.807 +Problem: Popup menu does not work properly with the preview window, folds + and 'cursorcolumn'. +Solution: Redraw the popup menu after redrawing windows. (Christian + Brabandt) +Files: src/screen.c + + +*** ../vim-7.3.806/src/screen.c 2013-01-30 12:31:32.000000000 +0100 +--- src/screen.c 2013-02-13 11:59:23.000000000 +0100 +*************** +*** 548,553 **** +--- 548,558 ---- + #if defined(FEAT_SEARCH_EXTRA) + end_search_hl(); + #endif ++ #ifdef FEAT_INS_EXPAND ++ /* May need to redraw the popup menu. */ ++ if (pum_visible()) ++ pum_redraw(); ++ #endif + + #ifdef FEAT_WINDOWS + /* Reset b_mod_set flags. Going through all windows is probably faster +*** ../vim-7.3.806/src/version.c 2013-02-06 19:58:38.000000000 +0100 +--- src/version.c 2013-02-13 12:00:55.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 807, + /**/ + +-- +A special cleaning ordinance bans housewives from hiding dirt and dust under a +rug in a dwelling. + [real standing law in Pennsylvania, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ab8882d30829360139584db0426f25cfb589a97a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:38:00 +0100 Subject: [PATCH 0692/3340] - patchlevel 808 --- 7.3.808 | 289 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 289 insertions(+) create mode 100644 7.3.808 diff --git a/7.3.808 b/7.3.808 new file mode 100644 index 00000000..a63e7731 --- /dev/null +++ b/7.3.808 @@ -0,0 +1,289 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.808 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.808 +Problem: Python threads still do not work properly. +Solution: Fix both Python 2 and 3. Add tests. (Ken Takata) +Files: src/if_python.c, src/if_python3.c, src/testdir/test86.in, + src/testdir/test86.ok, src/testdir/test87.in, + src/testdir/test87.ok + + +*** ../vim-7.3.807/src/if_python.c 2013-01-30 11:44:33.000000000 +0100 +--- src/if_python.c 2013-02-13 14:07:28.000000000 +0100 +*************** +*** 741,747 **** + PyMac_Initialize(); + #endif + /* Initialise threads, and below save the state using +! * PyGILState_Ensure. Without the call to PyGILState_Ensure, thread + * specific state (such as the system trace hook), will be lost + * between invocations of Python code. */ + PyEval_InitThreads(); +--- 741,747 ---- + PyMac_Initialize(); + #endif + /* Initialise threads, and below save the state using +! * PyEval_SaveThread. Without the call to PyEval_SaveThread, thread + * specific state (such as the system trace hook), will be lost + * between invocations of Python code. */ + PyEval_InitThreads(); +*************** +*** 755,764 **** + if (PythonMod_Init()) + goto fail; + +- /* The first python thread is vim's, release the lock. */ +- Python_SaveThread(); +- pygilstate = PyGILState_Ensure(); +- + globals = PyModule_GetDict(PyImport_AddModule("__main__")); + + /* Remove the element from sys.path that was added because of our +--- 755,760 ---- +*************** +*** 767,773 **** + * the current directory in sys.path. */ + PyRun_SimpleString("import sys; sys.path = filter(lambda x: x != '/must>not&exist', sys.path)"); + +! PyGILState_Release(pygilstate); + + initialised = 1; + } +--- 763,776 ---- + * the current directory in sys.path. */ + PyRun_SimpleString("import sys; sys.path = filter(lambda x: x != '/must>not&exist', sys.path)"); + +! /* lock is created and acquired in PyEval_InitThreads() and thread +! * state is created in Py_Initialize() +! * there _PyGILState_NoteThreadState() also sets gilcounter to 1 +! * (python must have threads enabled!) +! * so the following does both: unlock GIL and save thread state in TLS +! * without deleting thread state +! */ +! PyEval_SaveThread(); + + initialised = 1; + } +*** ../vim-7.3.807/src/if_python3.c 2012-11-28 15:33:10.000000000 +0100 +--- src/if_python3.c 2013-02-13 14:07:28.000000000 +0100 +*************** +*** 729,741 **** + #else + PyMac_Initialize(); + #endif +! /* Initialise threads, and save the state using PyGILState_Ensure. +! * Without the call to PyGILState_Ensure, thread specific state (such +! * as the system trace hook), will be lost between invocations of +! * Python code. */ + PyEval_InitThreads(); +- pygilstate = PyGILState_Ensure(); +- + #ifdef DYNAMIC_PYTHON3 + get_py3_exceptions(); + #endif +--- 729,739 ---- + #else + PyMac_Initialize(); + #endif +! /* Initialise threads, and below save the state using +! * PyEval_SaveThread. Without the call to PyEval_SaveThread, thread +! * specific state (such as the system trace hook), will be lost +! * between invocations of Python code. */ + PyEval_InitThreads(); + #ifdef DYNAMIC_PYTHON3 + get_py3_exceptions(); + #endif +*************** +*** 754,766 **** + */ + PyRun_SimpleString("import vim; import sys; sys.path = list(filter(lambda x: not x.endswith('must>not&exist'), sys.path))"); + +! // lock is created and acquired in PyEval_InitThreads() and thread +! // state is created in Py_Initialize() +! // there _PyGILState_NoteThreadState() also sets gilcounter to 1 +! // (python must have threads enabled!) +! // so the following does both: unlock GIL and save thread state in TLS +! // without deleting thread state +! PyGILState_Release(pygilstate); + + py3initialised = 1; + } +--- 752,765 ---- + */ + PyRun_SimpleString("import vim; import sys; sys.path = list(filter(lambda x: not x.endswith('must>not&exist'), sys.path))"); + +! /* lock is created and acquired in PyEval_InitThreads() and thread +! * state is created in Py_Initialize() +! * there _PyGILState_NoteThreadState() also sets gilcounter to 1 +! * (python must have threads enabled!) +! * so the following does both: unlock GIL and save thread state in TLS +! * without deleting thread state +! */ +! PyEval_SaveThread(); + + py3initialised = 1; + } +*** ../vim-7.3.807/src/testdir/test86.in 2012-09-21 14:00:05.000000000 +0200 +--- src/testdir/test86.in 2013-02-13 13:58:25.000000000 +0100 +*************** +*** 267,272 **** +--- 267,320 ---- + : $put =toput + : endtry + :endfor ++ :" ++ :" threading ++ :let l = [0] ++ :py l=vim.bindeval('l') ++ :py < 8 # check if the background thread is working ++ :$put =string(l) ++ :" ++ :" settrace ++ :let l = [] ++ :py l=vim.bindeval('l') ++ :py < 8 # check if the background thread is working ++ :$put =string(l) ++ :" ++ :" settrace ++ :let l = [] ++ :py3 l=vim.bindeval('l') ++ :py3 < Date: Mon, 18 Feb 2013 15:38:01 +0100 Subject: [PATCH 0693/3340] - patchlevel 809 --- 7.3.809 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.809 diff --git a/7.3.809 b/7.3.809 new file mode 100644 index 00000000..ef27688f --- /dev/null +++ b/7.3.809 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.809 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.809 +Problem: The dosinst.c program has a buffer overflow. (Thomas Gwae) +Solution: Ignore $VIMRUNTIME if it is too long. +Files: src/dosinst.c + + +*** ../vim-7.3.808/src/dosinst.c 2010-08-15 21:57:28.000000000 +0200 +--- src/dosinst.c 2013-02-13 14:34:25.000000000 +0100 +*************** +*** 375,381 **** + + /* First get $VIMRUNTIME. If it's set, remove the tail. */ + vim = getenv("VIMRUNTIME"); +! if (vim != NULL && *vim != 0) + { + strcpy(buf, vim); + remove_tail(buf); +--- 375,381 ---- + + /* First get $VIMRUNTIME. If it's set, remove the tail. */ + vim = getenv("VIMRUNTIME"); +! if (vim != NULL && *vim != 0 && strlen(vim) < BUFSIZE) + { + strcpy(buf, vim); + remove_tail(buf); +*** ../vim-7.3.808/src/version.c 2013-02-13 14:17:00.000000000 +0100 +--- src/version.c 2013-02-13 14:36:33.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 809, + /**/ + +-- +"I know that there are people who don't love their fellow man, +and I hate those people!" - Tom Lehrer + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5e08dfa4ccef538fe33dbbd9937e8c88ffce5208 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:38:03 +0100 Subject: [PATCH 0694/3340] - patchlevel 810 --- 7.3.810 | 259 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 259 insertions(+) create mode 100644 7.3.810 diff --git a/7.3.810 b/7.3.810 new file mode 100644 index 00000000..60c633ac --- /dev/null +++ b/7.3.810 @@ -0,0 +1,259 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.810 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.810 +Problem: 'relativenumber is reset unexpectedly. (François Ingelrest) +Solution: After an option was reset also reset the global value. Add a test. + (Christian Brabandt) +Files: src/option.c, src/testdir/Make_amiga.mak, + src/testdir/Make_dos.mak, src/testdir/Make_ming.mak, + src/testdir/Make_os2.mak, src/testdir/Make_vms.mms, + src/testdir/Makefile, src/testdir/test89.in, + src/testdir/test89.ok + + +*** ../vim-7.3.809/src/option.c 2013-01-17 17:37:31.000000000 +0100 +--- src/option.c 2013-02-13 15:40:12.000000000 +0100 +*************** +*** 7109,7115 **** + return errmsg; + } + +! #ifdef FEAT_SYN_HL + /* + * Simple int comparison function for use with qsort() + */ +--- 7109,7115 ---- + return errmsg; + } + +! #if defined(FEAT_SYN_HL) || defined(PROTO) + /* + * Simple int comparison function for use with qsort() + */ +*************** +*** 7630,7646 **** + } + #endif + +! /* 'list', 'number' */ +! else if ((int *)varp == &curwin->w_p_list +! || (int *)varp == &curwin->w_p_nu + || (int *)varp == &curwin->w_p_rnu) + { + /* If 'number' is set, reset 'relativenumber'. */ + /* If 'relativenumber' is set, reset 'number'. */ + if ((int *)varp == &curwin->w_p_nu && curwin->w_p_nu) + curwin->w_p_rnu = FALSE; + if ((int *)varp == &curwin->w_p_rnu && curwin->w_p_rnu) + curwin->w_p_nu = FALSE; + } + + else if ((int *)varp == &curbuf->b_p_ro) +--- 7630,7651 ---- + } + #endif + +! /* 'number', 'relativenumber' */ +! else if ((int *)varp == &curwin->w_p_nu + || (int *)varp == &curwin->w_p_rnu) + { + /* If 'number' is set, reset 'relativenumber'. */ + /* If 'relativenumber' is set, reset 'number'. */ + if ((int *)varp == &curwin->w_p_nu && curwin->w_p_nu) ++ { + curwin->w_p_rnu = FALSE; ++ curwin->w_allbuf_opt.wo_rnu = FALSE; ++ } + if ((int *)varp == &curwin->w_p_rnu && curwin->w_p_rnu) ++ { + curwin->w_p_nu = FALSE; ++ curwin->w_allbuf_opt.wo_nu = FALSE; ++ } + } + + else if ((int *)varp == &curbuf->b_p_ro) +*** ../vim-7.3.809/src/testdir/Make_amiga.mak 2012-12-05 16:10:21.000000000 +0100 +--- src/testdir/Make_amiga.mak 2013-02-13 15:01:32.000000000 +0100 +*************** +*** 31,37 **** + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out test83.out test84.out test88.out + + .SUFFIXES: .in .out + +--- 31,38 ---- + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out test83.out test84.out test88.out \ +! test89.out + + .SUFFIXES: .in .out + +*************** +*** 136,138 **** +--- 137,140 ---- + test83.out: test83.in + test84.out: test84.in + test88.out: test88.in ++ test89.out: test89.in +*** ../vim-7.3.809/src/testdir/Make_dos.mak 2012-12-05 16:10:21.000000000 +0100 +--- src/testdir/Make_dos.mak 2013-02-13 15:00:59.000000000 +0100 +*************** +*** 30,36 **** + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out test88.out + + SCRIPTS32 = test50.out test70.out + +--- 30,37 ---- + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out test88.out \ +! test89.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.809/src/testdir/Make_ming.mak 2012-12-05 16:10:21.000000000 +0100 +--- src/testdir/Make_ming.mak 2013-02-13 15:01:16.000000000 +0100 +*************** +*** 50,56 **** + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out test88.out + + SCRIPTS32 = test50.out test70.out + +--- 50,57 ---- + test68.out test69.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out test88.out \ +! test89.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.809/src/testdir/Make_os2.mak 2012-12-05 16:10:21.000000000 +0100 +--- src/testdir/Make_os2.mak 2013-02-13 15:00:59.000000000 +0100 +*************** +*** 31,37 **** + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out test83.out test84.out test88.out + + .SUFFIXES: .in .out + +--- 31,38 ---- + test66.out test67.out test68.out test69.out test70.out \ + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ +! test81.out test82.out test83.out test84.out test88.out \ +! test89.out + + .SUFFIXES: .in .out + +*** ../vim-7.3.809/src/testdir/Make_vms.mms 2012-12-05 16:10:21.000000000 +0100 +--- src/testdir/Make_vms.mms 2013-02-13 15:00:59.000000000 +0100 +*************** +*** 76,82 **** + test66.out test67.out test68.out test69.out \ + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ +! test82.out test83.out test84.out test88.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +--- 76,82 ---- + test66.out test67.out test68.out test69.out \ + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ +! test82.out test83.out test84.out test88.out test89.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +*** ../vim-7.3.809/src/testdir/Makefile 2012-12-05 18:21:28.000000000 +0100 +--- src/testdir/Makefile 2013-02-13 15:00:59.000000000 +0100 +*************** +*** 27,33 **** + test69.out test70.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out test88.out + + SCRIPTS_GUI = test16.out + +--- 27,34 ---- + test69.out test70.out test71.out test72.out test73.out \ + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ +! test84.out test85.out test86.out test87.out test88.out \ +! test89.out + + SCRIPTS_GUI = test16.out + +*** ../vim-7.3.809/src/testdir/test89.in 2013-02-13 15:43:44.000000000 +0100 +--- src/testdir/test89.in 2013-02-13 15:07:28.000000000 +0100 +*************** +*** 0 **** +--- 1,15 ---- ++ Some tests for setting 'number' and 'relativenumber' ++ ++ STARTTEST ++ :set hidden nocp nu rnu ++ :redir @a | set nu? rnu? | redir END ++ :e! xx ++ :redir @b | set nu? rnu? | redir END ++ :e! # ++ :$put ='results:' ++ :$put a ++ :$put b ++ :/^results/,$w! test.out ++ :q! ++ ENDTEST ++ +*** ../vim-7.3.809/src/testdir/test89.ok 2013-02-13 15:43:44.000000000 +0100 +--- src/testdir/test89.ok 2013-02-13 15:08:05.000000000 +0100 +*************** +*** 0 **** +--- 1,7 ---- ++ results: ++ ++ nonumber ++ relativenumber ++ ++ nonumber ++ relativenumber +*** ../vim-7.3.809/src/version.c 2013-02-13 14:36:39.000000000 +0100 +--- src/version.c 2013-02-13 15:42:18.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 810, + /**/ + +-- +A law to reduce crime states: "It is mandatory for a motorist with criminal +intentions to stop at the city limits and telephone the chief of police as he +is entering the town. + [real standing law in Washington, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 91a6a7037e643d9f844d7bf6113e80852f646dd4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:38:05 +0100 Subject: [PATCH 0695/3340] - patchlevel 811 --- 7.3.811 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.811 diff --git a/7.3.811 b/7.3.811 new file mode 100644 index 00000000..657b3e0c --- /dev/null +++ b/7.3.811 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.811 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.811 +Problem: Useless termresponse parsing for SGR mouse. +Solution: Skip the parsing. (Hayaki Saito) +Files: src/term.c + + +*** ../vim-7.3.810/src/term.c 2012-12-05 14:42:56.000000000 +0100 +--- src/term.c 2013-02-13 15:49:24.000000000 +0100 +*************** +*** 4045,4052 **** + #ifdef FEAT_TERMRESPONSE + if (key_name[0] == NUL + /* URXVT mouse uses [#;#;#M, but we are matching [ */ +! || key_name[0] == KS_URXVT_MOUSE +! || key_name[0] == KS_SGR_MOUSE) + { + /* Check for xterm version string: "[>{x};{vers};{y}c". Also + * eat other possible responses to t_RV, rxvt returns +--- 4045,4051 ---- + #ifdef FEAT_TERMRESPONSE + if (key_name[0] == NUL + /* URXVT mouse uses [#;#;#M, but we are matching [ */ +! || key_name[0] == KS_URXVT_MOUSE) + { + /* Check for xterm version string: "[>{x};{vers};{y}c". Also + * eat other possible responses to t_RV, rxvt returns +*** ../vim-7.3.810/src/version.c 2013-02-13 15:44:22.000000000 +0100 +--- src/version.c 2013-02-13 15:50:27.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 811, + /**/ + +-- +No children may attend school with their breath smelling of "wild onions." + [real standing law in West Virginia, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 35e78d71226d959f0eb0a9fcc12f4d0a38bc716c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:38:06 +0100 Subject: [PATCH 0696/3340] - patchlevel 812 --- 7.3.812 | 86 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 7.3.812 diff --git a/7.3.812 b/7.3.812 new file mode 100644 index 00000000..83b9d2f8 --- /dev/null +++ b/7.3.812 @@ -0,0 +1,86 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.812 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.812 +Problem: When 'indentexpr' moves the cursor "curswant" not restored. +Solution: Restore "curswant". (Sung Pae) +Files: src/misc1.c + + +*** ../vim-7.3.811/src/misc1.c 2013-01-17 17:01:56.000000000 +0100 +--- src/misc1.c 2013-02-13 16:04:08.000000000 +0100 +*************** +*** 8809,8820 **** + get_expr_indent() + { + int indent; +! pos_T pos; + int save_State; + int use_sandbox = was_set_insecurely((char_u *)"indentexpr", + OPT_LOCAL); + +! pos = curwin->w_cursor; + set_vim_var_nr(VV_LNUM, curwin->w_cursor.lnum); + if (use_sandbox) + ++sandbox; +--- 8809,8826 ---- + get_expr_indent() + { + int indent; +! pos_T save_pos; +! colnr_T save_curswant; +! int save_set_curswant; + int save_State; + int use_sandbox = was_set_insecurely((char_u *)"indentexpr", + OPT_LOCAL); + +! /* Save and restore cursor position and curswant, in case it was changed +! * via :normal commands */ +! save_pos = curwin->w_cursor; +! save_curswant = curwin->w_curswant; +! save_set_curswant = curwin->w_set_curswant; + set_vim_var_nr(VV_LNUM, curwin->w_cursor.lnum); + if (use_sandbox) + ++sandbox; +*************** +*** 8829,8835 **** + * command. */ + save_State = State; + State = INSERT; +! curwin->w_cursor = pos; + check_cursor(); + State = save_State; + +--- 8835,8843 ---- + * command. */ + save_State = State; + State = INSERT; +! curwin->w_cursor = save_pos; +! curwin->w_curswant = save_curswant; +! curwin->w_set_curswant = save_set_curswant; + check_cursor(); + State = save_State; + +*** ../vim-7.3.811/src/version.c 2013-02-13 15:53:15.000000000 +0100 +--- src/version.c 2013-02-13 16:01:52.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 812, + /**/ + +-- +Living on Earth includes an annual free trip around the Sun. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 09b60b4a8f7bcfa832b311c3b8d21c2dd9d97fda Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:38:07 +0100 Subject: [PATCH 0697/3340] - patchlevel 813 --- 7.3.813 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.813 diff --git a/7.3.813 b/7.3.813 new file mode 100644 index 00000000..de1a0a99 --- /dev/null +++ b/7.3.813 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.813 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.813 +Problem: The CompleteDone event is not triggered when there are no pattern + matches. (Jianjun Mao) +Solution: Trigger the event. (Christian Brabandt) +Files: src/edit.c + + +*** ../vim-7.3.812/src/edit.c 2013-01-17 15:36:54.000000000 +0100 +--- src/edit.c 2013-02-13 16:25:35.000000000 +0100 +*************** +*** 3846,3851 **** +--- 3846,3857 ---- + #endif + } + } ++ #ifdef FEAT_AUTOCMD ++ else if (ctrl_x_mode == CTRL_X_LOCAL_MSG) ++ /* Trigger the CompleteDone event to give scripts a chance to act ++ * upon the (possibly failed) completion. */ ++ apply_autocmds(EVENT_COMPLETEDONE, NULL, NULL, FALSE, curbuf); ++ #endif + + /* reset continue_* if we left expansion-mode, if we stay they'll be + * (re)set properly in ins_complete() */ +*** ../vim-7.3.812/src/version.c 2013-02-13 16:10:13.000000000 +0100 +--- src/version.c 2013-02-13 16:23:50.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 813, + /**/ + +-- +FROG: How you English say: I one more time, mac, I unclog my nose towards + you, sons of a window-dresser, so, you think you could out-clever us + French fellows with your silly knees-bent creeping about advancing + behaviour. (blows a raspberry) I wave my private parts at your aunties, + you brightly-coloured, mealy-templed, cranberry-smelling, electric + donkey-bottom biters. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0aa87c5e8b85f7db789d6b79eb34e533bf8454cc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:38:08 +0100 Subject: [PATCH 0698/3340] - patchlevel 814 --- 7.3.814 | 146 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 146 insertions(+) create mode 100644 7.3.814 diff --git a/7.3.814 b/7.3.814 new file mode 100644 index 00000000..28d2acb5 --- /dev/null +++ b/7.3.814 @@ -0,0 +1,146 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.814 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.814 +Problem: Can't input multibyte characters on Win32 console if 'encoding' is + different from current codepage. +Solution: Use convert_input_safe() instead of convert_input(). Make + string_convert_ext() return an error for incomplete input. (Ken + Takata) +Files: src/mbyte.c, src/os_win32.c + + +*** ../vim-7.3.813/src/mbyte.c 2013-01-30 13:59:31.000000000 +0100 +--- src/mbyte.c 2013-02-13 16:38:25.000000000 +0100 +*************** +*** 6256,6263 **** + if (vcp->vc_cpfrom == 0) + tmp_len = utf8_to_utf16(ptr, len, NULL, NULL); + else +! tmp_len = MultiByteToWideChar(vcp->vc_cpfrom, 0, +! ptr, len, 0, 0); + tmp = (short_u *)alloc(sizeof(short_u) * tmp_len); + if (tmp == NULL) + break; +--- 6256,6278 ---- + if (vcp->vc_cpfrom == 0) + tmp_len = utf8_to_utf16(ptr, len, NULL, NULL); + else +! { +! tmp_len = MultiByteToWideChar(vcp->vc_cpfrom, +! unconvlenp ? MB_ERR_INVALID_CHARS : 0, +! ptr, len, 0, 0); +! if (tmp_len == 0 +! && GetLastError() == ERROR_NO_UNICODE_TRANSLATION) +! { +! if (lenp != NULL) +! *lenp = 0; +! if (unconvlenp != NULL) +! *unconvlenp = len; +! retval = alloc(1); +! if (retval) +! retval[0] = NUL; +! return retval; +! } +! } + tmp = (short_u *)alloc(sizeof(short_u) * tmp_len); + if (tmp == NULL) + break; +*** ../vim-7.3.813/src/os_win32.c 2012-11-20 16:53:34.000000000 +0100 +--- src/os_win32.c 2013-02-13 16:41:05.000000000 +0100 +*************** +*** 1466,1471 **** +--- 1466,1476 ---- + #define TYPEAHEADLEN 20 + static char_u typeahead[TYPEAHEADLEN]; /* previously typed bytes. */ + static int typeaheadlen = 0; ++ #ifdef FEAT_MBYTE ++ static char_u *rest = NULL; /* unconverted rest of previous read */ ++ static int restlen = 0; ++ int unconverted; ++ #endif + + /* First use any typeahead that was kept because "buf" was too small. */ + if (typeaheadlen > 0) +*************** +*** 1569,1574 **** +--- 1574,1606 ---- + + c = tgetch(&modifiers, &ch2); + ++ #ifdef FEAT_MBYTE ++ /* stolen from fill_input_buf() in ui.c */ ++ if (rest != NULL) ++ { ++ /* Use remainder of previous call, starts with an invalid ++ * character that may become valid when reading more. */ ++ if (restlen > TYPEAHEADLEN - typeaheadlen) ++ unconverted = TYPEAHEADLEN - typeaheadlen; ++ else ++ unconverted = restlen; ++ mch_memmove(typeahead + typeaheadlen, rest, unconverted); ++ if (unconverted == restlen) ++ { ++ vim_free(rest); ++ rest = NULL; ++ } ++ else ++ { ++ restlen -= unconverted; ++ mch_memmove(rest, rest + unconverted, restlen); ++ } ++ typeaheadlen += unconverted; ++ } ++ else ++ unconverted = 0; ++ #endif ++ + if (typebuf_changed(tb_change_cnt)) + { + /* "buf" may be invalid now if a client put something in the +*************** +*** 1604,1611 **** + * when 'tenc' is set. */ + if (input_conv.vc_type != CONV_NONE + && (ch2 == NUL || c != K_NUL)) +! n = convert_input(typeahead + typeaheadlen, n, +! TYPEAHEADLEN - typeaheadlen); + #endif + + /* Use the ALT key to set the 8th bit of the character +--- 1636,1647 ---- + * when 'tenc' is set. */ + if (input_conv.vc_type != CONV_NONE + && (ch2 == NUL || c != K_NUL)) +! { +! typeaheadlen -= unconverted; +! n = convert_input_safe(typeahead + typeaheadlen, +! n + unconverted, TYPEAHEADLEN - typeaheadlen, +! rest == NULL ? &rest : NULL, &restlen); +! } + #endif + + /* Use the ALT key to set the 8th bit of the character +*** ../vim-7.3.813/src/version.c 2013-02-13 16:30:17.000000000 +0100 +--- src/version.c 2013-02-13 16:47:50.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 814, + /**/ + +-- +SIGIRO -- irony detected (iron core dumped) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6fd135fdb8da1975e245676592685bc21d4359d9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:38:09 +0100 Subject: [PATCH 0699/3340] - patchlevel 815 --- 7.3.815 | 168 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 168 insertions(+) create mode 100644 7.3.815 diff --git a/7.3.815 b/7.3.815 new file mode 100644 index 00000000..f97dcbc8 --- /dev/null +++ b/7.3.815 @@ -0,0 +1,168 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.815 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.815 +Problem: Building with Cygwin and Ruby doesn't work. +Solution: Copy some things from the MingW build file. (Ken Takata) +Files: src/Make_cyg.mak + + +*** ../vim-7.3.814/src/Make_cyg.mak 2013-01-23 13:55:16.000000000 +0100 +--- src/Make_cyg.mak 2013-02-13 17:03:23.000000000 +0100 +*************** +*** 47,54 **** + # (i386) + # USEDLL no or yes: set to yes to use the Runtime library DLL (no) + # For USEDLL=yes the cygwin1.dll is required to run Vim. +! # "no" does not work with latest version of Cygwin, use +! # Make_ming.mak instead. Or set CC to gcc-3 and add + # -L/lib/w32api to EXTRA_LIBS. + # POSTSCRIPT no or yes: set to yes for PostScript printing (no) + # FEATURES TINY, SMALL, NORMAL, BIG or HUGE (BIG) +--- 47,54 ---- + # (i386) + # USEDLL no or yes: set to yes to use the Runtime library DLL (no) + # For USEDLL=yes the cygwin1.dll is required to run Vim. +! # For "no" the mingw-gcc-g++ package or the mingw64-i686-gcc-g++ +! # package is required to complie Vim. Or set CC to gcc-3 and add + # -L/lib/w32api to EXTRA_LIBS. + # POSTSCRIPT no or yes: set to yes for PostScript printing (no) + # FEATURES TINY, SMALL, NORMAL, BIG or HUGE (BIG) +*************** +*** 114,122 **** + INCLUDES = -march=$(ARCH) -Iproto + + #>>>>> name of the compiler and linker, name of lib directory +! CROSS_COMPILE = + CC = gcc + RC = windres + + ############################## + # DYNAMIC_PERL=yes and no both work +--- 114,130 ---- + INCLUDES = -march=$(ARCH) -Iproto + + #>>>>> name of the compiler and linker, name of lib directory +! ifeq (yes, $(USEDLL)) +! # CROSS_COMPILE is used for the gvimext DLL. +! CROSS_COMPILE = i686-pc-mingw32- + CC = gcc + RC = windres ++ else ++ # i686-pc-mingw32-gcc, i686-w64-mingw32-gcc or gcc-3 can be used. ++ CROSS_COMPILE = i686-pc-mingw32- ++ CC = $(CROSS_COMPILE)gcc ++ RC = $(CROSS_COMPILE)windres ++ endif + + ############################## + # DYNAMIC_PERL=yes and no both work +*************** +*** 193,223 **** + ############################## + ifdef RUBY + + ifndef RUBY_VER +! RUBY_VER=16 + endif +- + ifndef RUBY_VER_LONG +! RUBY_VER_LONG=1.6 + endif +! +! ifndef DYNAMIC_RUBY +! DYNAMIC_RUBY = yes + endif + +- ifeq ($(RUBY_VER), 16) + ifndef RUBY_PLATFORM + RUBY_PLATFORM = i586-mswin32 +- endif +- ifndef RUBY_INSTALL_NAME +- RUBY_INSTALL_NAME = mswin32-ruby$(RUBY_VER) +- endif + else +! ifndef RUBY_PLATFORM + RUBY_PLATFORM = i386-mswin32 + endif + ifndef RUBY_INSTALL_NAME +! RUBY_INSTALL_NAME = msvcrt-ruby$(RUBY_VER) + endif + endif + +--- 201,237 ---- + ############################## + ifdef RUBY + ++ ifndef DYNAMIC_RUBY ++ DYNAMIC_RUBY=yes ++ endif ++ # Set default value + ifndef RUBY_VER +! RUBY_VER = 16 + endif + ifndef RUBY_VER_LONG +! RUBY_VER_LONG = 1.6 + endif +! ifndef RUBY_API_VER +! RUBY_API_VER = $(subst .,,$(RUBY_VER_LONG)) + endif + + ifndef RUBY_PLATFORM ++ ifeq ($(RUBY_VER), 16) + RUBY_PLATFORM = i586-mswin32 + else +! ifneq ($(wildcard $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/i386-mingw32),) +! RUBY_PLATFORM = i386-mingw32 +! else + RUBY_PLATFORM = i386-mswin32 + endif ++ endif ++ endif ++ + ifndef RUBY_INSTALL_NAME +! ifeq ($(RUBY_VER), 16) +! RUBY_INSTALL_NAME = mswin32-ruby$(RUBY_API_VER) +! else +! RUBY_INSTALL_NAME = msvcrt-ruby$(RUBY_API_VER) + endif + endif + +*************** +*** 226,231 **** +--- 240,249 ---- + endif + + DEFINES += -DFEAT_RUBY ++ ifneq ($(findstring w64-mingw32,$(CC)),) ++ # A workaround for mingw-w64 ++ DEFINES += -DHAVE_STRUCT_TIMESPEC -DHAVE_STRUCT_TIMEZONE ++ endif + INCLUDES += -I$(RUBY)/lib/ruby/$(RUBY_VER_LONG)/$(RUBY_PLATFORM) + ifdef RUBY_19_OR_LATER + INCLUDES += -I$(RUBY)/include/ruby-$(RUBY_VER_LONG) -I$(RUBY)/include/ruby-$(RUBY_VER_LONG)/$(RUBY_PLATFORM) +*** ../vim-7.3.814/src/version.c 2013-02-13 16:49:54.000000000 +0100 +--- src/version.c 2013-02-13 17:03:36.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 815, + /**/ + +-- +ARTHUR: If you do not open these doors, we will take this castle by force ... + [A bucket of slops land on ARTHUR. He tries to retain his dignity.] + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 109cc86794de9e43a7163c5b28170eb0ca3ea102 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:38:10 +0100 Subject: [PATCH 0700/3340] - patchlevel 816 --- 7.3.816 | 368 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 368 insertions(+) create mode 100644 7.3.816 diff --git a/7.3.816 b/7.3.816 new file mode 100644 index 00000000..6e9f125d --- /dev/null +++ b/7.3.816 @@ -0,0 +1,368 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.816 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.816 +Problem: Can't compute a hash. +Solution: Add the sha256() function. (Tyru, Hirohito Higashi) +Files: runtime/doc/eval.txt, src/eval.c, src/proto/sha256.pro, + src/sha256.c, src/testdir/test90.in, src/testdir/test90.ok, + src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak, + src/testdir/Make_ming.mak, src/testdir/Make_os2.mak, + src/testdir/Make_vms.mms, src/testdir/Makefile + +*** ../vim-7.3.815/runtime/doc/eval.txt 2013-01-23 17:15:25.000000000 +0100 +--- runtime/doc/eval.txt 2013-02-13 17:32:52.000000000 +0100 +*************** +*** 1920,1925 **** +--- 1931,1937 ---- + settabwinvar( {tabnr}, {winnr}, {varname}, {val}) set {varname} in window + {winnr} in tab page {tabnr} to {val} + setwinvar( {nr}, {varname}, {val}) set {varname} in window {nr} to {val} ++ sha256( {string}) String SHA256 checksum of {string} + shellescape( {string} [, {special}]) + String escape {string} for use as shell + command argument +*************** +*** 5312,5317 **** +--- 5337,5347 ---- + :call setwinvar(1, "&list", 0) + :call setwinvar(2, "myvar", "foobar") + ++ sha256({string}) *sha256()* ++ Returns a String with 64 hex charactes, which is the SHA256 ++ checksum of {string}. ++ {only available when compiled with the |+cryptv| feature} ++ + shellescape({string} [, {special}]) *shellescape()* + Escape {string} for use as a shell command argument. + On MS-Windows and MS-DOS, when 'shellslash' is not set, it +*** ../vim-7.3.815/src/eval.c 2013-01-30 14:55:34.000000000 +0100 +--- src/eval.c 2013-02-13 17:24:40.000000000 +0100 +*************** +*** 688,693 **** +--- 688,696 ---- + static void f_settabvar __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_settabwinvar __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_setwinvar __ARGS((typval_T *argvars, typval_T *rettv)); ++ #ifdef FEAT_CRYPT ++ static void f_sha256 __ARGS((typval_T *argvars, typval_T *rettv)); ++ #endif /* FEAT_CRYPT */ + static void f_shellescape __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_shiftwidth __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_simplify __ARGS((typval_T *argvars, typval_T *rettv)); +*************** +*** 8055,8060 **** +--- 8058,8066 ---- + {"settabvar", 3, 3, f_settabvar}, + {"settabwinvar", 4, 4, f_settabwinvar}, + {"setwinvar", 3, 3, f_setwinvar}, ++ #ifdef FEAT_CRYPT ++ {"sha256", 1, 1, f_sha256}, ++ #endif + {"shellescape", 1, 2, f_shellescape}, + {"shiftwidth", 0, 0, f_shiftwidth}, + {"simplify", 1, 1, f_simplify}, +*************** +*** 16710,16715 **** +--- 16716,16739 ---- + } + } + ++ #ifdef FEAT_CRYPT ++ /* ++ * "sha256({string})" function ++ */ ++ static void ++ f_sha256(argvars, rettv) ++ typval_T *argvars; ++ typval_T *rettv; ++ { ++ char_u *p; ++ ++ p = get_tv_string(&argvars[0]); ++ rettv->vval.v_string = vim_strsave( ++ sha256_bytes(p, (int)STRLEN(p), NULL, 0)); ++ rettv->v_type = VAR_STRING; ++ } ++ #endif /* FEAT_CRYPT */ ++ + /* + * "shellescape({string})" function + */ +*** ../vim-7.3.815/src/proto/sha256.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/sha256.pro 2013-02-13 17:25:08.000000000 +0100 +*************** +*** 2,7 **** +--- 2,8 ---- + void sha256_start __ARGS((context_sha256_T *ctx)); + void sha256_update __ARGS((context_sha256_T *ctx, char_u *input, UINT32_T length)); + void sha256_finish __ARGS((context_sha256_T *ctx, char_u digest[32])); ++ char_u *sha256_bytes __ARGS((char_u *buf, int buf_len, char_u *salt, int salt_len)); + char_u *sha256_key __ARGS((char_u *buf, char_u *salt, int salt_len)); + int sha256_self_test __ARGS((void)); + void sha2_seed __ARGS((char_u *header, int header_len, char_u *salt, int salt_len)); +*** ../vim-7.3.815/src/sha256.c 2012-11-20 17:18:56.000000000 +0100 +--- src/sha256.c 2013-02-13 17:25:04.000000000 +0100 +*************** +*** 273,286 **** + #endif /* FEAT_CRYPT || FEAT_PERSISTENT_UNDO */ + + #if defined(FEAT_CRYPT) || defined(PROTO) +- static char_u *sha256_bytes __ARGS((char_u *buf, int buf_len, char_u *salt, int salt_len)); + static unsigned int get_some_time __ARGS((void)); + + /* + * Returns hex digest of "buf[buf_len]" in a static array. + * if "salt" is not NULL also do "salt[salt_len]". + */ +! static char_u * + sha256_bytes(buf, buf_len, salt, salt_len) + char_u *buf; + int buf_len; +--- 273,285 ---- + #endif /* FEAT_CRYPT || FEAT_PERSISTENT_UNDO */ + + #if defined(FEAT_CRYPT) || defined(PROTO) + static unsigned int get_some_time __ARGS((void)); + + /* + * Returns hex digest of "buf[buf_len]" in a static array. + * if "salt" is not NULL also do "salt[salt_len]". + */ +! char_u * + sha256_bytes(buf, buf_len, salt, salt_len) + char_u *buf; + int buf_len; +*** ../vim-7.3.815/src/testdir/test90.in 2013-02-13 17:33:42.000000000 +0100 +--- src/testdir/test90.in 2013-02-13 17:20:13.000000000 +0100 +*************** +*** 0 **** +--- 1,53 ---- ++ Tests for sha256() function. vim: set ft=vim et ts=2 sw=2 : ++ ++ STARTTEST ++ :so small.vim ++ :if !has('cryptv') || !exists('*sha256') ++ e! test.ok ++ wq! test.out ++ :endif ++ :" ++ :let testcase='test for empty string: ' ++ :if sha256("") ==# 'e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855' ++ : let res='ok' ++ :else ++ : let res='ng' ++ :endif ++ :$put =testcase.res ++ :" ++ :let testcase='test for 1 char: ' ++ :if sha256("a") ==# 'ca978112ca1bbdcafac231b39a23dc4da786eff8147c4e72b9807785afee48bb' ++ : let res='ok' ++ :else ++ : let res='ng' ++ :endif ++ :$put =testcase.res ++ :" ++ :let testcase='test for 3 chars: ' ++ :if sha256("abc") ==# 'ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad' ++ : let res='ok' ++ :else ++ : let res='ng' ++ :endif ++ :$put =testcase.res ++ :" ++ :let testcase='test for contains meta char: ' ++ :if sha256("foo\nbar") ==# '807eff6267f3f926a21d234f7b0cf867a86f47e07a532f15e8cc39ed110ca776' ++ : let res='ok' ++ :else ++ : let res='ng' ++ :endif ++ :$put =testcase.res ++ :" ++ :let testcase='test for contains non-ascii char: ' ++ :if sha256("\xde\xad\xbe\xef") ==# '5f78c33274e43fa9de5659265c1d917e25c03722dcb0b8d27db8d5feaa813953' ++ : let res='ok' ++ :else ++ : let res='ng' ++ :endif ++ :$put =testcase.res ++ " ++ :/^start:/,$wq! test.out ++ ENDTEST ++ ++ start: +*** ../vim-7.3.815/src/testdir/test90.ok 2013-02-13 17:33:42.000000000 +0100 +--- src/testdir/test90.ok 2013-02-13 17:20:36.000000000 +0100 +*************** +*** 0 **** +--- 1,6 ---- ++ start: ++ test for empty string: ok ++ test for 1 char: ok ++ test for 3 chars: ok ++ test for contains meta char: ok ++ test for contains non-ascii char: ok +*** ../vim-7.3.815/src/testdir/Make_amiga.mak 2013-02-13 15:44:22.000000000 +0100 +--- src/testdir/Make_amiga.mak 2013-02-13 17:21:15.000000000 +0100 +*************** +*** 32,38 **** + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out + + .SUFFIXES: .in .out + +--- 32,38 ---- + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out test90.out + + .SUFFIXES: .in .out + +*************** +*** 138,140 **** +--- 138,141 ---- + test84.out: test84.in + test88.out: test88.in + test89.out: test89.in ++ test90.out: test90.in +*** ../vim-7.3.815/src/testdir/Make_dos.mak 2013-02-13 15:44:22.000000000 +0100 +--- src/testdir/Make_dos.mak 2013-02-13 17:21:22.000000000 +0100 +*************** +*** 31,37 **** + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out + + SCRIPTS32 = test50.out test70.out + +--- 31,37 ---- + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.815/src/testdir/Make_ming.mak 2013-02-13 15:44:22.000000000 +0100 +--- src/testdir/Make_ming.mak 2013-02-13 17:21:24.000000000 +0100 +*************** +*** 51,57 **** + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out + + SCRIPTS32 = test50.out test70.out + +--- 51,57 ---- + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.815/src/testdir/Make_os2.mak 2013-02-13 15:44:22.000000000 +0100 +--- src/testdir/Make_os2.mak 2013-02-13 17:21:27.000000000 +0100 +*************** +*** 32,38 **** + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out + + .SUFFIXES: .in .out + +--- 32,38 ---- + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out test90.out + + .SUFFIXES: .in .out + +*** ../vim-7.3.815/src/testdir/Make_vms.mms 2013-02-13 15:44:22.000000000 +0100 +--- src/testdir/Make_vms.mms 2013-02-13 17:21:32.000000000 +0100 +*************** +*** 4,10 **** + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2012 Dec 05 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +--- 4,10 ---- + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2013 Feb 13 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +*************** +*** 76,82 **** + test66.out test67.out test68.out test69.out \ + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ +! test82.out test83.out test84.out test88.out test89.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +--- 76,83 ---- + test66.out test67.out test68.out test69.out \ + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ +! test82.out test83.out test84.out test88.out test89.out \ +! test90.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +*** ../vim-7.3.815/src/testdir/Makefile 2013-02-13 15:44:22.000000000 +0100 +--- src/testdir/Makefile 2013-02-13 17:20:58.000000000 +0100 +*************** +*** 28,34 **** + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out + + SCRIPTS_GUI = test16.out + +--- 28,34 ---- + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out + + SCRIPTS_GUI = test16.out + +*** ../vim-7.3.815/src/version.c 2013-02-13 17:06:06.000000000 +0100 +--- src/version.c 2013-02-13 17:33:04.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 816, + /**/ + +-- + Another bucket of what can only be described as human ordure hits ARTHUR. +ARTHUR: ... Right! (to the KNIGHTS) That settles it! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 115413a8522123277597fba5ceff77642da73a6b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:38:11 +0100 Subject: [PATCH 0701/3340] - patchlevel 817 --- 7.3.817 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.817 diff --git a/7.3.817 b/7.3.817 new file mode 100644 index 00000000..d869fea4 --- /dev/null +++ b/7.3.817 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.817 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.817 +Problem: Test 89 fails with tiny and small features. +Solution: Add sourcing small.vim. +Files: src/testdir/test89.in + + +*** ../vim-7.3.816/src/testdir/test89.in 2013-02-13 15:44:22.000000000 +0100 +--- src/testdir/test89.in 2013-02-14 20:06:53.000000000 +0100 +*************** +*** 1,6 **** +--- 1,7 ---- + Some tests for setting 'number' and 'relativenumber' + + STARTTEST ++ :so small.vim + :set hidden nocp nu rnu + :redir @a | set nu? rnu? | redir END + :e! xx +*** ../vim-7.3.816/src/version.c 2013-02-13 17:34:59.000000000 +0100 +--- src/version.c 2013-02-14 20:10:00.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 817, + /**/ + +-- +INSPECTOR END OF FILM: Move along. There's nothing to see! Keep moving! + [Suddenly he notices the cameras.] +INSPECTOR END OF FILM: (to Camera) All right, put that away sonny. + [He walks over to it and puts his hand over the lens.] + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3ad6546ff0546fb0f9cc9942d59050ed89d3517d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:38:12 +0100 Subject: [PATCH 0702/3340] - patchlevel 818 --- 7.3.818 | 133 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 133 insertions(+) create mode 100644 7.3.818 diff --git a/7.3.818 b/7.3.818 new file mode 100644 index 00000000..6ff3788e --- /dev/null +++ b/7.3.818 @@ -0,0 +1,133 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.818 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.818 +Problem: When test 40 fails because of a bad build it may leave files + behind that cause it to fail later. +Solution: Let the file names start with "X". +Files: src/testdir/test40.in + + +*** ../vim-7.3.817/src/testdir/test40.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test40.in 2013-02-14 20:56:45.000000000 +0100 +*************** +*** 3,20 **** + STARTTEST + :so small.vim + :/^start/,$w! Xxx " write lines below to Xxx +! :au BufReadCmd testA 0r Xxx|$del +! :e testA " will read text of Xxd instead +! :au BufWriteCmd testA call append(line("$"), "write") + :w " will append a line to the file +! :r testA " should not read anything + : " now we have: + : " 1 start of Xxx + : " 2 test40 + : " 3 end of Xxx + : " 4 write +! :au FileReadCmd testB '[r Xxx +! :2r testB " will read Xxx below line 2 instead + : " 1 start of Xxx + : " 2 test40 + : " 3 start of Xxx +--- 3,20 ---- + STARTTEST + :so small.vim + :/^start/,$w! Xxx " write lines below to Xxx +! :au BufReadCmd XtestA 0r Xxx|$del +! :e XtestA " will read text of Xxd instead +! :au BufWriteCmd XtestA call append(line("$"), "write") + :w " will append a line to the file +! :r XtestA " should not read anything + : " now we have: + : " 1 start of Xxx + : " 2 test40 + : " 3 end of Xxx + : " 4 write +! :au FileReadCmd XtestB '[r Xxx +! :2r XtestB " will read Xxx below line 2 instead + : " 1 start of Xxx + : " 2 test40 + : " 3 start of Xxx +*************** +*** 22,31 **** + : " 5 end of Xxx + : " 6 end of Xxx + : " 7 write +! :au FileWriteCmd testC '[,']copy $ + 4GA1 +! :4,5w testC " will copy lines 4 and 5 to the end +! :r testC " should not read anything + : " 1 start of Xxx + : " 2 test40 + : " 3 start of Xxx +--- 22,31 ---- + : " 5 end of Xxx + : " 6 end of Xxx + : " 7 write +! :au FileWriteCmd XtestC '[,']copy $ + 4GA1 +! :4,5w XtestC " will copy lines 4 and 5 to the end +! :r XtestC " should not read anything + : " 1 start of Xxx + : " 2 test40 + : " 3 start of Xxx +*************** +*** 35,48 **** + : " 7 write + : " 8 test401 + : " 9 end of Xxx +! :au FILEAppendCmd testD '[,']w! test.out +! :w >>testD " will write all lines to test.out +! :$r testD " should not read anything + :$w >>test.out " append "end of Xxx" to test.out +! :au BufReadCmd testE 0r test.out|$del +! :sp testE " split window with test.out + 5Goasdf:" +! :au BufWriteCmd testE w! test.out + :wall " will write other window to test.out + : " 1 start of Xxx + : " 2 test40 +--- 35,48 ---- + : " 7 write + : " 8 test401 + : " 9 end of Xxx +! :au FILEAppendCmd XtestD '[,']w! test.out +! :w >>XtestD " will write all lines to test.out +! :$r XtestD " should not read anything + :$w >>test.out " append "end of Xxx" to test.out +! :au BufReadCmd XtestE 0r test.out|$del +! :sp XtestE " split window with test.out + 5Goasdf:" +! :au BufWriteCmd XtestE w! test.out + :wall " will write other window to test.out + : " 1 start of Xxx + : " 2 test40 +*** ../vim-7.3.817/src/version.c 2013-02-14 20:10:28.000000000 +0100 +--- src/version.c 2013-02-14 20:57:44.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 818, + /**/ + +-- +JOHN CLEESE PLAYED: SECOND SOLDIER WITH A KEEN INTEREST IN BIRDS, LARGE MAN + WITH DEAD BODY, BLACK KNIGHT, MR NEWT (A VILLAGE + BLACKSMITH INTERESTED IN BURNING WITCHES), A QUITE + EXTRAORDINARILY RUDE FRENCHMAN, TIM THE WIZARD, SIR + LAUNCELOT + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ca3f591609105bcc53cdd25a69e364910d198fdf Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:38:13 +0100 Subject: [PATCH 0703/3340] - patchlevel 819 --- 7.3.819 | 682 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 682 insertions(+) create mode 100644 7.3.819 diff --git a/7.3.819 b/7.3.819 new file mode 100644 index 00000000..3f036c91 --- /dev/null +++ b/7.3.819 @@ -0,0 +1,682 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.819 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.819 +Problem: Compiling without +eval and with Python isn't working. +Solution: Add the eval feature when building with Python. +Files: src/if_py_both.h, src/feature.h, src/eval.c, src/ex_docmd.c, + src/normal.c, src/gui_gtk_x11.c + + +*** ../vim-7.3.818/src/if_py_both.h 2012-12-05 16:30:03.000000000 +0100 +--- src/if_py_both.h 2013-02-14 19:22:59.000000000 +0100 +*************** +*** 310,316 **** + return result; + } + +- #ifdef FEAT_EVAL + /* + * Function to translate a typval_T into a PyObject; this will recursively + * translate lists/dictionaries into their Python equivalents. +--- 310,315 ---- +*************** +*** 425,436 **** + + return result; + } +- #endif + + static PyObject * + VimEval(PyObject *self UNUSED, PyObject *args UNUSED) + { +- #ifdef FEAT_EVAL + char *expr; + typval_T *our_tv; + PyObject *result; +--- 424,433 ---- +*************** +*** 466,475 **** + Py_END_ALLOW_THREADS + + return result; +- #else +- PyErr_SetVim(_("expressions disabled at compile time")); +- return NULL; +- #endif + } + + static PyObject *ConvertToPyObject(typval_T *); +--- 463,468 ---- +*************** +*** 477,483 **** + static PyObject * + VimEvalPy(PyObject *self UNUSED, PyObject *args UNUSED) + { +- #ifdef FEAT_EVAL + char *expr; + typval_T *our_tv; + PyObject *result; +--- 470,475 ---- +*************** +*** 506,515 **** + Py_END_ALLOW_THREADS + + return result; +- #else +- PyErr_SetVim(_("expressions disabled at compile time")); +- return NULL; +- #endif + } + + static PyObject * +--- 498,503 ---- +*************** +*** 946,952 **** + } + + static PyObject * +! DictionaryListKeys(PyObject *self) + { + dict_T *dict = ((DictionaryObject *)(self))->dict; + long_u todo = dict->dv_hashtab.ht_used; +--- 934,940 ---- + } + + static PyObject * +! DictionaryListKeys(PyObject *self UNUSED) + { + dict_T *dict = ((DictionaryObject *)(self))->dict; + long_u todo = dict->dv_hashtab.ht_used; +*************** +*** 2549,2555 **** + return 0; + } + +- #ifdef FEAT_EVAL + typedef int (*pytotvfunc)(PyObject *, typval_T *, PyObject *); + + static int +--- 2537,2542 ---- +*************** +*** 2781,2784 **** + return NULL; + } + } +- #endif +--- 2768,2770 ---- +*** ../vim-7.3.818/src/feature.h 2013-01-23 13:40:54.000000000 +0100 +--- src/feature.h 2013-02-14 19:25:33.000000000 +0100 +*************** +*** 392,397 **** +--- 392,404 ---- + #endif + + /* ++ * +python and +python3 require FEAT_EVAL. ++ */ ++ #if !defined(FEAT_EVAL) && (defined(FEAT_PYTHON3) || defined(FEAT_PYTHON)) ++ # define FEAT_EVAL ++ #endif ++ ++ /* + * +profile Profiling for functions and scripts. + */ + #if defined(FEAT_HUGE) \ +*** ../vim-7.3.818/src/eval.c 2013-02-13 17:34:59.000000000 +0100 +--- src/eval.c 2013-02-14 19:38:09.000000000 +0100 +*************** +*** 917,923 **** +--- 917,925 ---- + hash_clear(&compat_hashtab); + + free_scriptnames(); ++ # if defined(FEAT_CMDL_COMPL) + free_locales(); ++ # endif + + /* global variables */ + vars_clear(&globvarht); +*************** +*** 1561,1568 **** + } + + +- #if (defined(FEAT_USR_CMDS) && defined(FEAT_CMDL_COMPL)) \ +- || defined(FEAT_COMPL_FUNC) || defined(PROTO) + /* + * Call some vimL function and return the result in "*rettv". + * Uses argv[argc] for the function arguments. Only Number and String +--- 1563,1568 ---- +*************** +*** 1640,1692 **** + return ret; + } + +- # if (defined(FEAT_USR_CMDS) && defined(FEAT_CMDL_COMPL)) || defined(PROTO) + /* +! * Call vimL function "func" and return the result as a string. +! * Returns NULL when calling the function fails. + * Uses argv[argc] for the function arguments. + */ +! void * +! call_func_retstr(func, argc, argv, safe) + char_u *func; + int argc; + char_u **argv; + int safe; /* use the sandbox */ + { + typval_T rettv; +! char_u *retval; + + /* All arguments are passed as strings, no conversion to number. */ + if (call_vim_function(func, argc, argv, safe, TRUE, &rettv) == FAIL) +! return NULL; + +! retval = vim_strsave(get_tv_string(&rettv)); + clear_tv(&rettv); + return retval; + } +- # endif + +! # if defined(FEAT_COMPL_FUNC) || defined(PROTO) + /* +! * Call vimL function "func" and return the result as a number. +! * Returns -1 when calling the function fails. + * Uses argv[argc] for the function arguments. + */ +! long +! call_func_retnr(func, argc, argv, safe) + char_u *func; + int argc; + char_u **argv; + int safe; /* use the sandbox */ + { + typval_T rettv; +! long retval; + + /* All arguments are passed as strings, no conversion to number. */ + if (call_vim_function(func, argc, argv, safe, TRUE, &rettv) == FAIL) +! return -1; + +! retval = get_tv_number_chk(&rettv, NULL); + clear_tv(&rettv); + return retval; + } +--- 1640,1693 ---- + return ret; + } + + /* +! * Call vimL function "func" and return the result as a number. +! * Returns -1 when calling the function fails. + * Uses argv[argc] for the function arguments. + */ +! long +! call_func_retnr(func, argc, argv, safe) + char_u *func; + int argc; + char_u **argv; + int safe; /* use the sandbox */ + { + typval_T rettv; +! long retval; + + /* All arguments are passed as strings, no conversion to number. */ + if (call_vim_function(func, argc, argv, safe, TRUE, &rettv) == FAIL) +! return -1; + +! retval = get_tv_number_chk(&rettv, NULL); + clear_tv(&rettv); + return retval; + } + +! #if (defined(FEAT_USR_CMDS) && defined(FEAT_CMDL_COMPL)) \ +! || defined(FEAT_COMPL_FUNC) || defined(PROTO) +! +! # if (defined(FEAT_USR_CMDS) && defined(FEAT_CMDL_COMPL)) || defined(PROTO) + /* +! * Call vimL function "func" and return the result as a string. +! * Returns NULL when calling the function fails. + * Uses argv[argc] for the function arguments. + */ +! void * +! call_func_retstr(func, argc, argv, safe) + char_u *func; + int argc; + char_u **argv; + int safe; /* use the sandbox */ + { + typval_T rettv; +! char_u *retval; + + /* All arguments are passed as strings, no conversion to number. */ + if (call_vim_function(func, argc, argv, safe, TRUE, &rettv) == FAIL) +! return NULL; + +! retval = vim_strsave(get_tv_string(&rettv)); + clear_tv(&rettv); + return retval; + } +*************** +*** 1720,1726 **** + } + #endif + +- + /* + * Save the current function call pointer, and set it to NULL. + * Used when executing autocommands and for ":source". +--- 1721,1726 ---- +*************** +*** 9330,9336 **** + */ + static void + f_cindent(argvars, rettv) +! typval_T *argvars; + typval_T *rettv; + { + #ifdef FEAT_CINDENT +--- 9330,9336 ---- + */ + static void + f_cindent(argvars, rettv) +! typval_T *argvars UNUSED; + typval_T *rettv; + { + #ifdef FEAT_CINDENT +*************** +*** 10379,10387 **** + + static void + findfilendir(argvars, rettv, find_what) +! typval_T *argvars; + typval_T *rettv; +! int find_what; + { + #ifdef FEAT_SEARCHPATH + char_u *fname; +--- 10379,10387 ---- + + static void + findfilendir(argvars, rettv, find_what) +! typval_T *argvars UNUSED; + typval_T *rettv; +! int find_what UNUSED; + { + #ifdef FEAT_SEARCHPATH + char_u *fname; +*************** +*** 10751,10759 **** + */ + static void + foldclosed_both(argvars, rettv, end) +! typval_T *argvars; + typval_T *rettv; +! int end; + { + #ifdef FEAT_FOLDING + linenr_T lnum; +--- 10751,10759 ---- + */ + static void + foldclosed_both(argvars, rettv, end) +! typval_T *argvars UNUSED; + typval_T *rettv; +! int end UNUSED; + { + #ifdef FEAT_FOLDING + linenr_T lnum; +*************** +*** 10802,10809 **** + */ + static void + f_foldlevel(argvars, rettv) +! typval_T *argvars; +! typval_T *rettv; + { + #ifdef FEAT_FOLDING + linenr_T lnum; +--- 10802,10809 ---- + */ + static void + f_foldlevel(argvars, rettv) +! typval_T *argvars UNUSED; +! typval_T *rettv UNUSED; + { + #ifdef FEAT_FOLDING + linenr_T lnum; +*************** +*** 11583,11589 **** + static void + f_getmatches(argvars, rettv) + typval_T *argvars UNUSED; +! typval_T *rettv; + { + #ifdef FEAT_SEARCH_EXTRA + dict_T *dict; +--- 11583,11589 ---- + static void + f_getmatches(argvars, rettv) + typval_T *argvars UNUSED; +! typval_T *rettv UNUSED; + { + #ifdef FEAT_SEARCH_EXTRA + dict_T *dict; +*************** +*** 13589,13595 **** + */ + static void + f_lispindent(argvars, rettv) +! typval_T *argvars; + typval_T *rettv; + { + #ifdef FEAT_LISP +--- 13589,13595 ---- + */ + static void + f_lispindent(argvars, rettv) +! typval_T *argvars UNUSED; + typval_T *rettv; + { + #ifdef FEAT_LISP +*************** +*** 13983,13990 **** + */ + static void + f_matchadd(argvars, rettv) +! typval_T *argvars; +! typval_T *rettv; + { + #ifdef FEAT_SEARCH_EXTRA + char_u buf[NUMBUFLEN]; +--- 13983,13990 ---- + */ + static void + f_matchadd(argvars, rettv) +! typval_T *argvars UNUSED; +! typval_T *rettv UNUSED; + { + #ifdef FEAT_SEARCH_EXTRA + char_u buf[NUMBUFLEN]; +*************** +*** 14021,14027 **** + */ + static void + f_matcharg(argvars, rettv) +! typval_T *argvars; + typval_T *rettv; + { + if (rettv_list_alloc(rettv) == OK) +--- 14021,14027 ---- + */ + static void + f_matcharg(argvars, rettv) +! typval_T *argvars UNUSED; + typval_T *rettv; + { + if (rettv_list_alloc(rettv) == OK) +*************** +*** 14053,14060 **** + */ + static void + f_matchdelete(argvars, rettv) +! typval_T *argvars; +! typval_T *rettv; + { + #ifdef FEAT_SEARCH_EXTRA + rettv->vval.v_number = match_delete(curwin, +--- 14053,14060 ---- + */ + static void + f_matchdelete(argvars, rettv) +! typval_T *argvars UNUSED; +! typval_T *rettv UNUSED; + { + #ifdef FEAT_SEARCH_EXTRA + rettv->vval.v_number = match_delete(curwin, +*************** +*** 14871,14878 **** + */ + static void + f_reltime(argvars, rettv) +! typval_T *argvars; +! typval_T *rettv; + { + #ifdef FEAT_RELTIME + proftime_T res; +--- 14871,14878 ---- + */ + static void + f_reltime(argvars, rettv) +! typval_T *argvars UNUSED; +! typval_T *rettv UNUSED; + { + #ifdef FEAT_RELTIME + proftime_T res; +*************** +*** 14920,14926 **** + */ + static void + f_reltimestr(argvars, rettv) +! typval_T *argvars; + typval_T *rettv; + { + #ifdef FEAT_RELTIME +--- 14920,14926 ---- + */ + static void + f_reltimestr(argvars, rettv) +! typval_T *argvars UNUSED; + typval_T *rettv; + { + #ifdef FEAT_RELTIME +*************** +*** 15965,15971 **** + int flags; /* SP_SETPCMARK and other SP_ values */ + pos_T *match_pos; + linenr_T lnum_stop; /* stop at this line if not zero */ +! long time_limit; /* stop after this many msec */ + { + char_u *save_cpo; + char_u *pat, *pat2 = NULL, *pat3 = NULL; +--- 15965,15971 ---- + int flags; /* SP_SETPCMARK and other SP_ values */ + pos_T *match_pos; + linenr_T lnum_stop; /* stop at this line if not zero */ +! long time_limit UNUSED; /* stop after this many msec */ + { + char_u *save_cpo; + char_u *pat, *pat2 = NULL, *pat3 = NULL; +*************** +*** 16390,16397 **** + */ + static void + f_setmatches(argvars, rettv) +! typval_T *argvars; +! typval_T *rettv; + { + #ifdef FEAT_SEARCH_EXTRA + list_T *l; +--- 16390,16397 ---- + */ + static void + f_setmatches(argvars, rettv) +! typval_T *argvars UNUSED; +! typval_T *rettv UNUSED; + { + #ifdef FEAT_SEARCH_EXTRA + list_T *l; +*************** +*** 18463,18469 **** + */ + static void + f_undofile(argvars, rettv) +! typval_T *argvars; + typval_T *rettv; + { + rettv->v_type = VAR_STRING; +--- 18463,18469 ---- + */ + static void + f_undofile(argvars, rettv) +! typval_T *argvars UNUSED; + typval_T *rettv; + { + rettv->v_type = VAR_STRING; +*** ../vim-7.3.818/src/ex_docmd.c 2012-12-05 19:13:11.000000000 +0100 +--- src/ex_docmd.c 2013-02-14 20:50:56.000000000 +0100 +*************** +*** 1734,1739 **** +--- 1734,1741 ---- + #ifdef FEAT_EVAL + /* avoid that a function call in 'statusline' does this */ + && !getline_equal(fgetline, cookie, get_func_line) ++ #endif ++ #ifdef FEAT_AUTOCMD + /* avoid that an autocommand, e.g. QuitPre, does this */ + && !getline_equal(fgetline, cookie, getnextac) + #endif +*************** +*** 5375,5381 **** +--- 5377,5385 ---- + #endif + return FAIL; + } ++ #endif + ++ #if defined(FEAT_USR_CMDS) || defined(FEAT_EVAL) || defined(PROTO) + /* + * List of names for completion for ":command" with the EXPAND_ flag. + * Must be alphabetical for completion. +*************** +*** 5430,5436 **** +--- 5434,5442 ---- + {EXPAND_USER_VARS, "var"}, + {0, NULL} + }; ++ #endif + ++ #if defined(FEAT_USR_CMDS) || defined(PROTO) + static void + uc_list(name, name_len) + char_u *name; +*************** +*** 6375,6384 **** + int vallen; + int *complp; + long *argt; +! char_u **compl_arg; + { + char_u *arg = NULL; + size_t arglen = 0; + int i; + int valend = vallen; + +--- 6381,6392 ---- + int vallen; + int *complp; + long *argt; +! char_u **compl_arg UNUSED; + { + char_u *arg = NULL; ++ # if defined(FEAT_EVAL) && defined(FEAT_CMDL_COMPL) + size_t arglen = 0; ++ # endif + int i; + int valend = vallen; + +*************** +*** 6388,6394 **** +--- 6396,6404 ---- + if (value[i] == ',') + { + arg = &value[i + 1]; ++ # if defined(FEAT_EVAL) && defined(FEAT_CMDL_COMPL) + arglen = vallen - i - 1; ++ # endif + valend = i; + break; + } +*** ../vim-7.3.818/src/normal.c 2013-01-24 21:00:15.000000000 +0100 +--- src/normal.c 2013-02-14 19:33:36.000000000 +0100 +*************** +*** 2292,2298 **** +--- 2292,2300 ---- + { + #ifdef FEAT_EVAL + char_u *(argv[1]); ++ # ifdef FEAT_VIRTUALEDIT + int save_virtual_op = virtual_op; ++ # endif + + if (*p_opfunc == NUL) + EMSG(_("E774: 'operatorfunc' is empty")); +*************** +*** 2312,2324 **** +--- 2314,2330 ---- + else + argv[0] = (char_u *)"char"; + ++ # ifdef FEAT_VIRTUALEDIT + /* Reset virtual_op so that 'virtualedit' can be changed in the + * function. */ + virtual_op = MAYBE; ++ # endif + + (void)call_func_retnr(p_opfunc, 1, argv, FALSE); + ++ # ifdef FEAT_VIRTUALEDIT + virtual_op = save_virtual_op; ++ # endif + } + #else + EMSG(_("E775: Eval feature not available")); +*** ../vim-7.3.818/src/gui_gtk_x11.c 2013-01-23 16:00:05.000000000 +0100 +--- src/gui_gtk_x11.c 2013-02-14 19:38:42.000000000 +0100 +*************** +*** 5164,5171 **** + return FAIL; + } + +! #if defined(FEAT_TITLE) \ +! || defined(PROTO) + /* + * Return the text window-id and display. Only required for X-based GUI's + */ +--- 5164,5170 ---- + return FAIL; + } + +! #if defined(FEAT_TITLE) || defined(FEAT_EVAL) || defined(PROTO) + /* + * Return the text window-id and display. Only required for X-based GUI's + */ +*** ../vim-7.3.818/src/version.c 2013-02-14 20:58:30.000000000 +0100 +--- src/version.c 2013-02-14 22:09:41.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 819, + /**/ + +-- +(letter from Mark to Mike, about the film's probable certificate) + For an 'A' we would have to: Lose as many shits as possible; Take Jesus + Christ out, if possible; Loose "I fart in your general direction"; Lose + "the oral sex"; Lose "oh, fuck off"; Lose "We make castanets out of your + testicles" + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c05c4819884004c502e80ebe1475f1318e2e05f3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:38:14 +0100 Subject: [PATCH 0704/3340] - patchlevel 820 --- 7.3.820 | 137 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 137 insertions(+) create mode 100644 7.3.820 diff --git a/7.3.820 b/7.3.820 new file mode 100644 index 00000000..df273ab7 --- /dev/null +++ b/7.3.820 @@ -0,0 +1,137 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.820 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.820 +Problem: Build errors and warnings when building with small features and + Lua, Perl or Ruby. +Solution: Add #ifdefs and UNUSED. +Files: src/if_perl.xs, src/if_lua.c, src/if_ruby.c + + +*** ../vim-7.3.819/src/if_perl.xs 2013-02-06 19:58:38.000000000 +0100 +--- src/if_perl.xs 2013-02-14 19:16:00.000000000 +0100 +*************** +*** 600,608 **** + */ + char_u * + eval_to_string(arg, nextcmd, dolist) +! char_u *arg; +! char_u **nextcmd; +! int dolist; + { + return NULL; + } +--- 600,608 ---- + */ + char_u * + eval_to_string(arg, nextcmd, dolist) +! char_u *arg UNUSED; +! char_u **nextcmd UNUSED; +! int dolist UNUSED; + { + return NULL; + } +*** ../vim-7.3.819/src/if_lua.c 2012-10-14 03:41:54.000000000 +0200 +--- src/if_lua.c 2013-02-14 19:15:29.000000000 +0100 +*************** +*** 845,852 **** + } + + static int +! luaV_dict_iter (lua_State *L) + { + hashitem_T *hi = (hashitem_T *) lua_touserdata(L, lua_upvalueindex(2)); + int n = lua_tointeger(L, lua_upvalueindex(3)); + dictitem_T *di; +--- 845,853 ---- + } + + static int +! luaV_dict_iter (lua_State *L UNUSED) + { ++ #ifdef FEAT_EVAL + hashitem_T *hi = (hashitem_T *) lua_touserdata(L, lua_upvalueindex(2)); + int n = lua_tointeger(L, lua_upvalueindex(3)); + dictitem_T *di; +*************** +*** 860,865 **** +--- 861,869 ---- + lua_pushinteger(L, n - 1); + lua_replace(L, lua_upvalueindex(3)); + return 2; ++ #else ++ return 0; ++ #endif + } + + static int +*** ../vim-7.3.819/src/if_ruby.c 2012-11-24 13:38:56.000000000 +0100 +--- src/if_ruby.c 2013-02-14 22:18:50.000000000 +0100 +*************** +*** 1210,1230 **** + return height; + } + +! static VALUE window_width(VALUE self) + { +! win_T *win = get_win(self); +! +! return INT2NUM(win->w_width); + } + +! static VALUE window_set_width(VALUE self, VALUE width) + { + win_T *win = get_win(self); + win_T *savewin = curwin; + + curwin = win; + win_setwidth(NUM2INT(width)); + curwin = savewin; + return width; + } + +--- 1210,1230 ---- + return height; + } + +! static VALUE window_width(VALUE self UNUSED) + { +! return INT2NUM(W_WIDTH(get_win(self))); + } + +! static VALUE window_set_width(VALUE self UNUSED, VALUE width) + { ++ #ifdef FEAT_VERTSPLIT + win_T *win = get_win(self); + win_T *savewin = curwin; + + curwin = win; + win_setwidth(NUM2INT(width)); + curwin = savewin; ++ #endif + return width; + } + +*** ../vim-7.3.819/src/version.c 2013-02-14 22:11:31.000000000 +0100 +--- src/version.c 2013-02-14 22:19:09.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 820, + /**/ + +-- +Did Adam and Eve have navels? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9b71e616be5646a7faf99457a880791c11643cb2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:38:15 +0100 Subject: [PATCH 0705/3340] - patchlevel 821 --- 7.3.821 | 76 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 7.3.821 diff --git a/7.3.821 b/7.3.821 new file mode 100644 index 00000000..13dc3bab --- /dev/null +++ b/7.3.821 @@ -0,0 +1,76 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.821 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.821 +Problem: Build with OLE and Cygwin is broken. (Steve Hall) +Solution: Select static or shared stdc library. (Ken Takata) +Files: src/Make_cyg.mak + + +*** ../vim-7.3.820/src/Make_cyg.mak 2013-02-13 17:06:06.000000000 +0100 +--- src/Make_cyg.mak 2013-02-16 18:09:49.000000000 +0100 +*************** +*** 106,111 **** +--- 106,118 ---- + OPTIMIZE = MAXSPEED + endif + ++ ++ # Link against the shared version of libstdc++ by default. Set ++ # STATIC_STDCPLUS to "yes" to link against static version instead. ++ ifndef STATIC_STDCPLUS ++ STATIC_STDCPLUS=no ++ endif ++ + ### See feature.h for a list of optionals. + ### Any other defines can be included here. + +*************** +*** 478,484 **** + ifeq (yes, $(OLE)) + DEFINES += -DFEAT_OLE + EXTRA_OBJS += $(OUTDIR)/if_ole.o +! EXTRA_LIBS += -loleaut32 -lstdc++ + endif + + ############################## +--- 485,496 ---- + ifeq (yes, $(OLE)) + DEFINES += -DFEAT_OLE + EXTRA_OBJS += $(OUTDIR)/if_ole.o +! EXTRA_LIBS += -loleaut32 +! ifeq (yes, $(STATIC_STDCPLUS)) +! EXTRA_LIBS += -Wl,-Bstatic -lstdc++ -lsupc++ -Wl,-Bdynamic +! else +! EXTRA_LIBS += -lstdc++ +! endif + endif + + ############################## +*** ../vim-7.3.820/src/version.c 2013-02-14 22:19:47.000000000 +0100 +--- src/version.c 2013-02-16 18:11:52.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 821, + /**/ + +-- +ARTHUR: It is I, Arthur, son of Uther Pendragon, from the castle of Camelot. + King of all Britons, defeator of the Saxons, sovereign of all England! + [Pause] +SOLDIER: Get away! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 965fba8223a331edca9dc0220289a80dce919307 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:38:16 +0100 Subject: [PATCH 0706/3340] - patchlevel 822 --- 7.3.822 | 159 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 159 insertions(+) create mode 100644 7.3.822 diff --git a/7.3.822 b/7.3.822 new file mode 100644 index 00000000..0f9e0d91 --- /dev/null +++ b/7.3.822 @@ -0,0 +1,159 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.822 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.822 (after 7.3.799) +Problem: Crash when accessing freed buffer. +Solution: Get 'textwidth' in caller of enter_buffer(). (Christian Brabandt) +Files: src/buffer.c + + +*** ../vim-7.3.821/src/buffer.c 2013-02-06 18:44:57.000000000 +0100 +--- src/buffer.c 2013-02-17 15:10:44.000000000 +0100 +*************** +*** 82,87 **** +--- 82,90 ---- + #ifdef FEAT_AUTOCMD + buf_T *old_curbuf; + #endif ++ #ifdef FEAT_SYN_HL ++ long old_tw = curbuf->b_p_tw; ++ #endif + + /* + * The 'readonly' flag is only set when BF_NEVERLOADED is being reset. +*************** +*** 113,118 **** +--- 116,125 ---- + } + EMSG(_("E83: Cannot allocate buffer, using other one...")); + enter_buffer(curbuf); ++ #ifdef FEAT_SYN_HL ++ if (old_tw != curbuf->b_p_tw) ++ check_colorcolumn(curwin); ++ #endif + return FAIL; + } + +*************** +*** 786,791 **** +--- 793,801 ---- + # if defined(FEAT_AUTOCMD) && defined(FEAT_EVAL) + cleanup_T cs; + # endif ++ #ifdef FEAT_SYN_HL ++ long old_tw = curbuf->b_p_tw; ++ #endif + + if (swap_exists_action == SEA_QUIT) + { +*************** +*** 804,810 **** +--- 814,826 ---- + if (!buf_valid(old_curbuf) || old_curbuf == curbuf) + old_curbuf = buflist_new(NULL, NULL, 1L, BLN_CURBUF | BLN_LISTED); + if (old_curbuf != NULL) ++ { + enter_buffer(old_curbuf); ++ #ifdef FEAT_SYN_HL ++ if (old_tw != curbuf->b_p_tw) ++ check_colorcolumn(curwin); ++ #endif ++ } + /* If "old_curbuf" is NULL we are in big trouble here... */ + + # if defined(FEAT_AUTOCMD) && defined(FEAT_EVAL) +*************** +*** 1364,1369 **** +--- 1380,1388 ---- + buf_T *prevbuf; + int unload = (action == DOBUF_UNLOAD || action == DOBUF_DEL + || action == DOBUF_WIPE); ++ #ifdef FEAT_SYN_HL ++ long old_tw = curbuf->b_p_tw; ++ #endif + + setpcmark(); + if (!cmdmod.keepalt) +*************** +*** 1430,1450 **** + # endif + ) + #endif + enter_buffer(buf); + } + + /* + * Enter a new current buffer. +! * Old curbuf must have been abandoned already! + */ + void + enter_buffer(buf) + buf_T *buf; + { +- #ifdef FEAT_SYN_HL +- long old_tw = curbuf->b_p_tw; +- #endif +- + /* Copy buffer and window local option values. Not for a help buffer. */ + buf_copy_options(buf, BCO_ENTER | BCO_NOHELP); + if (!buf->b_help) +--- 1449,1472 ---- + # endif + ) + #endif ++ { + enter_buffer(buf); ++ #ifdef FEAT_SYN_HL ++ if (old_tw != curbuf->b_p_tw) ++ check_colorcolumn(curwin); ++ #endif ++ } + } + + /* + * Enter a new current buffer. +! * Old curbuf must have been abandoned already! This also means "curbuf" may +! * be pointing to freed memory. + */ + void + enter_buffer(buf) + buf_T *buf; + { + /* Copy buffer and window local option values. Not for a help buffer. */ + buf_copy_options(buf, BCO_ENTER | BCO_NOHELP); + if (!buf->b_help) +*************** +*** 1468,1475 **** + + #ifdef FEAT_SYN_HL + curwin->w_s = &(buf->b_s); +- if (old_tw != buf->b_p_tw) +- check_colorcolumn(curwin); + #endif + + /* Cursor on first line by default. */ +--- 1490,1495 ---- +*** ../vim-7.3.821/src/version.c 2013-02-16 18:16:11.000000000 +0100 +--- src/version.c 2013-02-17 15:35:41.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 822, + /**/ + +-- +Clothes make the man. Naked people have little or no influence on society. + -- Mark Twain (Samuel Clemens) (1835-1910) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bcafa0577881c5a20b889f85dd6c7f9315386af1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 18 Feb 2013 15:38:18 +0100 Subject: [PATCH 0707/3340] - patchlevel 822 --- README.patches | 26 +++++++++++++++++++++++ vim.spec | 57 ++++++++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 81 insertions(+), 2 deletions(-) diff --git a/README.patches b/README.patches index c32f02dc..d50252b1 100644 --- a/README.patches +++ b/README.patches @@ -299,6 +299,7 @@ Individual patches for Vim 7.3: 4017 7.3.265 storing search pattern in history without separator check 1677 7.3.266 in Gvim with iBus typing space in Insert mode doesn't work 1784 7.3.267 Ruby on Mac OS X 10.7 may crash + 2093 7.3.268 Vim freezes when executing an external command with zsh 2871 7.3.269 'shellcmdflag' only works with one flag 1514 7.3.270 illegal memory access 12980 7.3.271 code not following Vim coding style @@ -828,3 +829,28 @@ Individual patches for Vim 7.3: 5967 7.3.795 MzScheme does not build with tiny features 3027 7.3.796 "/[^\n]" does match at a line break 2040 7.3.797 (after 7.3.792) compiler warning for size_t to int conversion + 3208 7.3.798 (after 7.3.791) MzScheme: circular list works wrong + 1666 7.3.799 the color column is not correct when entering a buffer + 2085 7.3.800 the " mark is not adjusted when inserting lines + 2053 7.3.801 ":window set nu?" displays the cursor line + 1426 7.3.802 no error when setting 'isk' to a value ending in a comma + 2523 7.3.803 (after 7.3.792) ":s/a/b/gc" is a no-op when typing 'q' + 1373 7.3.804 (after 7.3.799) compiler warning for tiny build + 3434 7.3.805 Lua version 5.2 is not detected properly on Arch Linux + 4287 7.3.806 compiler warnings in Perl code when using Visual studio 2012 + 1620 7.3.807 popup menu does not work properly in some situations + 8219 7.3.808 Python threads still do not work properly + 1609 7.3.809 the dosinst.c program has a buffer overflow + 8532 7.3.810 'relativenumber is reset unexpectedly + 1867 7.3.811 useless termresponse parsing for SGR mouse + 2481 7.3.812 when 'indentexpr' moves the cursor "curswant" not restored + 2028 7.3.813 the CompleteDone event is not always triggered + 4425 7.3.814 Win32 console: problem if 'enc' differs from current codepage + 4694 7.3.815 building with Cygwin and Ruby doesn't work + 12480 7.3.816 can't compute a hash + 1567 7.3.817 test 89 fails with tiny and small features + 4236 7.3.818 when test 40 fails it may leave files behind + 16345 7.3.819 (CORRECTED) compiling without +eval and Python isn't working + 3295 7.3.820 errors when building with small features and Lua, Perl or Ruby + 2199 7.3.821 build with OLE and Cygwin is broken + 4013 7.3.822 (after 7.3.799) crash when accessing freed buffer diff --git a/vim.spec b/vim.spec index 966d1a5f..a29ca949 100644 --- a/vim.spec +++ b/vim.spec @@ -18,13 +18,13 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 797 +%define patchlevel 822 Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 2%{?dist} +Release: 1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -854,6 +854,31 @@ Patch794: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.794 Patch795: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.795 Patch796: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.796 Patch797: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.797 +Patch798: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.798 +Patch799: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.799 +Patch800: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.800 +Patch801: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.801 +Patch802: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.802 +Patch803: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.803 +Patch804: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.804 +Patch805: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.805 +Patch806: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.806 +Patch807: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.807 +Patch808: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.808 +Patch809: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.809 +Patch810: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.810 +Patch811: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.811 +Patch812: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.812 +Patch813: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.813 +Patch814: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.814 +Patch815: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.815 +Patch816: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.816 +Patch817: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.817 +Patch818: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.818 +Patch819: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.819 +Patch820: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.820 +Patch821: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.821 +Patch822: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.822 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1797,6 +1822,31 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch795 -p0 %patch796 -p0 %patch797 -p0 +%patch798 -p0 +%patch799 -p0 +%patch800 -p0 +%patch801 -p0 +%patch802 -p0 +%patch803 -p0 +%patch804 -p0 +%patch805 -p0 +%patch806 -p0 +%patch807 -p0 +%patch808 -p0 +%patch809 -p0 +%patch810 -p0 +%patch811 -p0 +%patch812 -p0 +%patch813 -p0 +%patch814 -p0 +%patch815 -p0 +%patch816 -p0 +%patch817 -p0 +%patch818 -p0 +%patch819 -p0 +%patch820 -p0 +%patch821 -p0 +%patch822 -p0 # install spell files @@ -2272,6 +2322,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Feb 18 2013 Karsten Hopp 7.3.822-1 +- patchlevel 822 + * Fri Feb 15 2013 Toshio Kuratomi - 7.3.797-2 - Only use --vendor for desktop-file-install on F18 or less From dd001f38af3869c615af6fe8beb4ca9b77ccc747 Mon Sep 17 00:00:00 2001 From: Daniel Mach Date: Thu, 14 Mar 2013 10:58:07 -0400 Subject: [PATCH 0708/3340] Reset content to fedora/f19 --- vim-7.3-test83.patch | 12 ------------ vim.spec | 29 +++++++++-------------------- 2 files changed, 9 insertions(+), 32 deletions(-) delete mode 100644 vim-7.3-test83.patch diff --git a/vim-7.3-test83.patch b/vim-7.3-test83.patch deleted file mode 100644 index 0187ec4f..00000000 --- a/vim-7.3-test83.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -up vim73/src/testdir/Makefile.test83 vim73/src/testdir/Makefile ---- vim73/src/testdir/Makefile.test83 2012-11-13 17:51:38.493046031 +0100 -+++ vim73/src/testdir/Makefile 2012-11-13 17:51:52.216052356 +0100 -@@ -26,7 +26,7 @@ SCRIPTS = test1.out test2.out test3.out - test64.out test65.out test66.out test67.out test68.out \ - test69.out test70.out test71.out test72.out test73.out \ - test74.out test75.out test76.out test77.out test78.out \ -- test79.out test80.out test81.out test82.out test83.out \ -+ test79.out test80.out test81.out test82.out \ - test84.out test85.out test86.out test87.out - - SCRIPTS_GUI = test16.out diff --git a/vim.spec b/vim.spec index 9e5f9d16..a29ca949 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 3%{?dist} +Release: 1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -891,7 +891,6 @@ Patch3010: vim-7.0-specedit.patch Patch3011: vim72-rh514717.patch Patch3012: vim-7.3-bug816848.patch Patch3013: vim-7.3-manpage-typo-668894-675480.patch -Patch3014: vim-7.3-test83.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel ncurses-devel gettext perl-devel @@ -1866,7 +1865,6 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch3011 -p1 %patch3012 -p1 %patch3013 -p1 -%patch3014 -p1 %build cp -f %{SOURCE5} . @@ -1956,6 +1954,7 @@ perl -pi -e "s/\/etc\/vimrc/\/etc\/virc/" os_unix.h make VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} %{?_smp_mflags} %install +rm -rf $RPM_BUILD_ROOT mkdir -p $RPM_BUILD_ROOT/%{_bindir} mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/{after,autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/after/{autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} @@ -1973,12 +1972,10 @@ rm -f README*.info cd src make install DESTDIR=$RPM_BUILD_ROOT BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} make installgtutorbin DESTDIR=$RPM_BUILD_ROOT BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} -#mv $RPM_BUILD_ROOT/bin/xxd $RPM_BUILD_ROOT/%{_bindir}/xxd -#mv $RPM_BUILD_ROOT/bin/gvimtutor $RPM_BUILD_ROOT/%{_bindir}/gvimtutor mkdir -p $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/{16x16,32x32,48x48,64x64}/apps install -m755 vim $RPM_BUILD_ROOT%{_bindir}/vi install -m755 enhanced-vim $RPM_BUILD_ROOT%{_bindir}/vim -install -m755 gvim $RPM_BUILD_ROOT/%{_bindir}/gvim +install -m755 gvim $RPM_BUILD_ROOT%{_bindir}/gvim install -p -m644 %{SOURCE7} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/16x16/apps/gvim.png install -p -m644 %{SOURCE8} \ @@ -1987,13 +1984,12 @@ install -p -m644 %{SOURCE9} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/48x48/apps/gvim.png install -p -m644 %{SOURCE10} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/64x64/apps/gvim.png -install -m755 enhanced-vim $RPM_BUILD_ROOT/%{_bindir}/vim ( cd $RPM_BUILD_ROOT - ln -sf vi .%{_bindir}/ex - ln -sf vi .%{_bindir}/rvi - ln -sf vi .%{_bindir}/rview - ln -sf vi .%{_bindir}/view + ln -sf vi ./%{_bindir}/rvi + ln -sf vi ./%{_bindir}/rview + ln -sf vi ./%{_bindir}/view + ln -sf vi ./%{_bindir}/ex ln -sf vim ./%{_bindir}/rvim ln -sf vim ./%{_bindir}/vimdiff perl -pi -e "s,$RPM_BUILD_ROOT,," .%{_mandir}/man1/vim.1 .%{_mandir}/man1/vimtutor.1 @@ -2064,18 +2060,11 @@ if [ -n "\$BASH_VERSION" -o -n "\$KSH_VERSION" -o -n "\$ZSH_VERSION" ]; then fi EOF cat >$RPM_BUILD_ROOT/%{_sysconfdir}/profile.d/vim.csh < 100 ) then - alias vi vim - endif -endif +[ -x /%{_bindir}/id ] || exit +[ \`/%{_bindir}/id -u\` -gt 200 ] && alias vi vim EOF chmod 0644 $RPM_BUILD_ROOT/%{_sysconfdir}/profile.d/* install -p -m644 %{SOURCE4} $RPM_BUILD_ROOT/%{_sysconfdir}/vimrc -%if %{?rhel}%{!?rhel:0} >= 6 -perl -pi -e "s,augroup fedora,augroup redhat,g" $RPM_BUILD_ROOT/%{_sysconfdir}/vimrc -%endif - install -p -m644 %{SOURCE4} $RPM_BUILD_ROOT/%{_sysconfdir}/virc (cd $RPM_BUILD_ROOT/%{_datadir}/%{name}/%{vimdir}/doc; gzip -9 *.txt From cf355aa88e19da8d881cad5ab9c2d1d12d174071 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:01:58 +0200 Subject: [PATCH 0709/3340] - patchlevel 823 --- 7.3.823 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.823 diff --git a/7.3.823 b/7.3.823 new file mode 100644 index 00000000..59a36014 --- /dev/null +++ b/7.3.823 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.823 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.823 (after 7.3.821) +Problem: Building with Cygwin: '-lsupc++' is not needed. +Solution: Remove it. (Ken Takata) +Files: src/Make_cyg.mak + + +*** ../vim-7.3.822/src/Make_cyg.mak 2013-02-16 18:16:11.000000000 +0100 +--- src/Make_cyg.mak 2013-02-17 15:04:05.000000000 +0100 +*************** +*** 1,6 **** + # + # Makefile for VIM on Win32, using Cygnus gcc +! # Last updated by Dan Sharp. Last Change: 2012 Jun 30 + # + # Also read INSTALLpc.txt! + # +--- 1,6 ---- + # + # Makefile for VIM on Win32, using Cygnus gcc +! # Last updated by Dan Sharp. Last Change: 2013 Feb 17 + # + # Also read INSTALLpc.txt! + # +*************** +*** 487,493 **** + EXTRA_OBJS += $(OUTDIR)/if_ole.o + EXTRA_LIBS += -loleaut32 + ifeq (yes, $(STATIC_STDCPLUS)) +! EXTRA_LIBS += -Wl,-Bstatic -lstdc++ -lsupc++ -Wl,-Bdynamic + else + EXTRA_LIBS += -lstdc++ + endif +--- 487,493 ---- + EXTRA_OBJS += $(OUTDIR)/if_ole.o + EXTRA_LIBS += -loleaut32 + ifeq (yes, $(STATIC_STDCPLUS)) +! EXTRA_LIBS += -Wl,-Bstatic -lstdc++ -Wl,-Bdynamic + else + EXTRA_LIBS += -lstdc++ + endif +*** ../vim-7.3.822/src/version.c 2013-02-17 15:45:34.000000000 +0100 +--- src/version.c 2013-02-20 13:33:42.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 823, + /**/ + +-- +ARTHUR: Now stand aside worthy adversary. +BLACK KNIGHT: (Glancing at his shoulder) 'Tis but a scratch. +ARTHUR: A scratch? Your arm's off. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 075a8f851d16906841abee4dce5bbbd3695b2d1a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:01:59 +0200 Subject: [PATCH 0710/3340] - patchlevel 824 --- 7.3.824 | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 7.3.824 diff --git a/7.3.824 b/7.3.824 new file mode 100644 index 00000000..7881aed0 --- /dev/null +++ b/7.3.824 @@ -0,0 +1,49 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.824 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.824 +Problem: Can redefine builtin functions. (ZyX) +Solution: Disallow adding a function to g:. +Files: src/eval.c + + +*** ../vim-7.3.823/src/eval.c 2013-02-14 22:11:31.000000000 +0100 +--- src/eval.c 2013-02-20 15:17:50.000000000 +0100 +*************** +*** 21164,21169 **** +--- 21164,21172 ---- + if (arg[j] != NUL) + emsg_funcname((char *)e_invarg2, arg); + } ++ /* Disallow using the g: dict. */ ++ if (fudi.fd_dict != NULL && fudi.fd_dict->dv_scope == VAR_DEF_SCOPE) ++ EMSG(_("E862: Cannot use g: here")); + } + + /* +*** ../vim-7.3.823/src/version.c 2013-02-20 13:34:14.000000000 +0100 +--- src/version.c 2013-02-20 14:11:01.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 824, + /**/ + +-- +ARTHUR: You are indeed brave Sir knight, but the fight is mine. +BLACK KNIGHT: Had enough? +ARTHUR: You stupid bastard. You havn't got any arms left. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b5ebfe20ebf948a5143c7ae0862efbc7dbd2d11f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:01:59 +0200 Subject: [PATCH 0711/3340] - patchlevel 825 --- 7.3.825 | 125 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 125 insertions(+) create mode 100644 7.3.825 diff --git a/7.3.825 b/7.3.825 new file mode 100644 index 00000000..6a8c29b1 --- /dev/null +++ b/7.3.825 @@ -0,0 +1,125 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.825 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.825 +Problem: With Python errors are not always clear. +Solution: Print the stack trace, unless :silent is used. (ZyX) +Files: src/if_python3.c, src/if_python.c + + +*** ../vim-7.3.824/src/if_python3.c 2013-02-13 14:17:00.000000000 +0100 +--- src/if_python3.c 2013-02-20 15:26:03.000000000 +0100 +*************** +*** 122,127 **** +--- 122,128 ---- + # define PyDict_SetItemString py3_PyDict_SetItemString + # define PyErr_BadArgument py3_PyErr_BadArgument + # define PyErr_Clear py3_PyErr_Clear ++ # define PyErr_PrintEx py3_PyErr_PrintEx + # define PyErr_NoMemory py3_PyErr_NoMemory + # define PyErr_Occurred py3_PyErr_Occurred + # define PyErr_SetNone py3_PyErr_SetNone +*************** +*** 279,284 **** +--- 280,286 ---- + static void* (*py3_PyMem_Malloc)(size_t); + static int (*py3_Py_IsInitialized)(void); + static void (*py3_PyErr_Clear)(void); ++ static void (*py3_PyErr_PrintEx)(int); + static PyObject*(*py3__PyObject_Init)(PyObject *, PyTypeObject *); + static iternextfunc py3__PyObject_NextNotImplemented; + static PyObject* py3__Py_NoneStruct; +*************** +*** 403,408 **** +--- 405,411 ---- + {"_Py_FalseStruct", (PYTHON_PROC*)&py3__Py_FalseStruct}, + {"_Py_TrueStruct", (PYTHON_PROC*)&py3__Py_TrueStruct}, + {"PyErr_Clear", (PYTHON_PROC*)&py3_PyErr_Clear}, ++ {"PyErr_PrintEx", (PYTHON_PROC*)&py3_PyErr_PrintEx}, + {"PyObject_Init", (PYTHON_PROC*)&py3__PyObject_Init}, + {"PyModule_AddObject", (PYTHON_PROC*)&py3_PyModule_AddObject}, + {"PyImport_AppendInittab", (PYTHON_PROC*)&py3_PyImport_AppendInittab}, +*************** +*** 842,848 **** +--- 845,855 ---- + r = PyRun_String(PyBytes_AsString(cmdbytes), Py_eval_input, + globals, globals); + if (r == NULL) ++ { ++ if (PyErr_Occurred() && !msg_silent) ++ PyErr_PrintEx(0); + EMSG(_("E860: Eval did not return a valid python 3 object")); ++ } + else + { + if (ConvertFromPyObject(r, rettv) == -1) +*** ../vim-7.3.824/src/if_python.c 2013-02-13 14:17:00.000000000 +0100 +--- src/if_python.c 2013-02-20 15:26:03.000000000 +0100 +*************** +*** 148,153 **** +--- 148,154 ---- + # define PyDict_SetItemString dll_PyDict_SetItemString + # define PyErr_BadArgument dll_PyErr_BadArgument + # define PyErr_Clear dll_PyErr_Clear ++ # define PyErr_PrintEx dll_PyErr_PrintEx + # define PyErr_NoMemory dll_PyErr_NoMemory + # define PyErr_Occurred dll_PyErr_Occurred + # define PyErr_SetNone dll_PyErr_SetNone +*************** +*** 251,256 **** +--- 252,258 ---- + static int(*dll_PyDict_SetItemString)(PyObject *dp, char *key, PyObject *item); + static int(*dll_PyErr_BadArgument)(void); + static void(*dll_PyErr_Clear)(void); ++ static void(*dll_PyErr_PrintEx)(int); + static PyObject*(*dll_PyErr_NoMemory)(void); + static PyObject*(*dll_PyErr_Occurred)(void); + static void(*dll_PyErr_SetNone)(PyObject *); +*************** +*** 380,385 **** +--- 382,388 ---- + {"PyDict_SetItemString", (PYTHON_PROC*)&dll_PyDict_SetItemString}, + {"PyErr_BadArgument", (PYTHON_PROC*)&dll_PyErr_BadArgument}, + {"PyErr_Clear", (PYTHON_PROC*)&dll_PyErr_Clear}, ++ {"PyErr_PrintEx", (PYTHON_PROC*)&dll_PyErr_PrintEx}, + {"PyErr_NoMemory", (PYTHON_PROC*)&dll_PyErr_NoMemory}, + {"PyErr_Occurred", (PYTHON_PROC*)&dll_PyErr_Occurred}, + {"PyErr_SetNone", (PYTHON_PROC*)&dll_PyErr_SetNone}, +*************** +*** 856,862 **** +--- 859,869 ---- + + r = PyRun_String((char *)(cmd), Py_eval_input, globals, globals); + if (r == NULL) ++ { ++ if (PyErr_Occurred() && !msg_silent) ++ PyErr_PrintEx(0); + EMSG(_("E858: Eval did not return a valid python object")); ++ } + else + { + if (ConvertFromPyObject(r, rettv) == -1) +*** ../vim-7.3.824/src/version.c 2013-02-20 15:19:38.000000000 +0100 +--- src/version.c 2013-02-20 15:27:20.000000000 +0100 +*************** +*** 727,728 **** +--- 727,730 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 825, + /**/ + +-- +ARTHUR: What are you going to do. bleed on me? + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 787ee8378abfb9a2ad01e3f25f323bdc6d39cab4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:00 +0200 Subject: [PATCH 0712/3340] - patchlevel 826 --- 7.3.826 | 155 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 155 insertions(+) create mode 100644 7.3.826 diff --git a/7.3.826 b/7.3.826 new file mode 100644 index 00000000..2235e228 --- /dev/null +++ b/7.3.826 @@ -0,0 +1,155 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.826 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.826 +Problem: List of features in :version output is hard to read. +Solution: Make columns. (Nazri Ramliy) +Files: src/version.c + + +*** ../vim-7.3.825/src/version.c 2013-02-20 16:09:35.000000000 +0100 +--- src/version.c 2013-02-20 16:27:44.000000000 +0100 +*************** +*** 34,39 **** +--- 34,42 ---- + # if (defined(VMS) && defined(VAXC)) || defined(PROTO) + char longVersion[sizeof(VIM_VERSION_LONG_DATE) + sizeof(__DATE__) + + sizeof(__TIME__) + 3]; ++ ++ static void list_features __ARGS((void)); ++ + void + make_version() + { +*************** +*** 2435,2440 **** +--- 2440,2513 ---- + } + } + ++ /* ++ * List all features aligned in columns, dictionary style. ++ */ ++ static void ++ list_features() ++ { ++ int i; ++ int ncol; ++ int nrow; ++ int nfeat = 0; ++ int width = 0; ++ ++ /* Find the length of the longest feature name, use that + 1 as the column ++ * width */ ++ for (i = 0; features[i] != NULL; ++i) ++ { ++ int l = STRLEN(features[i]); ++ ++ if (l > width) ++ width = l; ++ ++nfeat; ++ } ++ width += 1; ++ ++ if (Columns < width) ++ { ++ /* Not enough screen columns - show one per line */ ++ for (i = 0; features[i] != NULL; ++i) ++ { ++ version_msg(features[i]); ++ if (msg_col > 0) ++ msg_putchar('\n'); ++ } ++ return; ++ } ++ ++ ncol = (int) Columns / width; ++ /* The rightmost column doesn't need a separator. ++ * Sacrifice it to fit in one more column if possible. */ ++ if (Columns % width == width - 1) ++ ncol++; ++ ++ nrow = nfeat / ncol + (nfeat % ncol ? 1 : 0); ++ ++ for (i = 0; !got_int && i < nrow * ncol; ++i) ++ { ++ int idx = (i / ncol) + (i % ncol) * nrow; ++ ++ if (idx < nfeat) ++ { ++ int last_col = (i + 1) % ncol == 0; ++ ++ msg_puts((char_u *)features[idx]); ++ if (last_col) ++ { ++ if (msg_col > 0) ++ msg_putchar('\n'); ++ } ++ else ++ { ++ while (msg_col % width) ++ msg_putchar(' '); ++ } ++ } ++ else ++ msg_putchar('\n'); ++ } ++ } + void + list_version() + { +*************** +*** 2632,2646 **** + #endif + version_msg(_(" Features included (+) or not (-):\n")); + +! /* print all the features */ +! for (i = 0; features[i] != NULL; ++i) +! { +! version_msg(features[i]); +! if (msg_col > 0) +! version_msg(" "); +! } + +- version_msg("\n"); + #ifdef SYS_VIMRC_FILE + version_msg(_(" system vimrc file: \"")); + version_msg(SYS_VIMRC_FILE); +--- 2705,2712 ---- + #endif + version_msg(_(" Features included (+) or not (-):\n")); + +! list_features(); + + #ifdef SYS_VIMRC_FILE + version_msg(_(" system vimrc file: \"")); + version_msg(SYS_VIMRC_FILE); +*** ../vim-7.3.825/src/version.c 2013-02-20 16:09:35.000000000 +0100 +--- src/version.c 2013-02-20 16:27:44.000000000 +0100 +*************** +*** 727,728 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 826, + /**/ + +-- +Mrs Abbott: I'm a paediatrician. + Basil: Feet? +Mrs Abbott: Children. + Sybil: Oh, Basil! + Basil: Well, children have feet, don't they? That's how they move + around, my dear. You must take a look next time, it's most + interesting. (Fawlty Towers) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From cf2fbf49a973b7a12fbf0ffc66c3d3bb72abede1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:01 +0200 Subject: [PATCH 0713/3340] - patchlevel 827 --- 7.3.827 | 94 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 94 insertions(+) create mode 100644 7.3.827 diff --git a/7.3.827 b/7.3.827 new file mode 100644 index 00000000..d37e30f2 --- /dev/null +++ b/7.3.827 @@ -0,0 +1,94 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.827 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.827 (after 7.3.825) +Problem: Python tests fail. +Solution: Adjust the output for the stack trace. +Files: src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.ok + + +*** ../vim-7.3.826/src/testdir/test86.in 2013-02-13 14:17:00.000000000 +0100 +--- src/testdir/test86.in 2013-02-17 21:16:13.000000000 +0100 +*************** +*** 1,5 **** +--- 1,11 ---- + Tests for various python features. vim: set ft=vim : + ++ NOTE: This will cause errors when run under valgrind. ++ This would require recompiling Python with: ++ ./configure --without-pymalloc ++ See http://svn.python.org/view/python/trunk/Misc/README.valgrind?view=markup ++ ++ + STARTTEST + :so small.vim + :if !has('python') | e! test.ok | wq! test.out | endif +*** ../vim-7.3.826/src/testdir/test86.ok 2013-02-13 14:17:00.000000000 +0100 +--- src/testdir/test86.ok 2013-02-20 16:33:20.000000000 +0100 +*************** +*** 61,67 **** + 0.0 + "\0": Vim(let):E859: + {"\0": 1}: Vim(let):E859: +! undefined_name: Vim(let):E858: + vim: Vim(let):E859: + [1] + [1, 10, 11, 10, 11, 10, 11, 10, 11, 10, 11, 10, 1] +--- 61,67 ---- + 0.0 + "\0": Vim(let):E859: + {"\0": 1}: Vim(let):E859: +! undefined_name: Vim(let):Trace + vim: Vim(let):E859: + [1] + [1, 10, 11, 10, 11, 10, 11, 10, 11, 10, 11, 10, 1] +*** ../vim-7.3.826/src/testdir/test87.ok 2013-02-13 14:17:00.000000000 +0100 +--- src/testdir/test87.ok 2013-02-20 16:33:31.000000000 +0100 +*************** +*** 61,67 **** + 0.0 + "\0": Vim(let):E861: + {"\0": 1}: Vim(let):E861: +! undefined_name: Vim(let):E860: + vim: Vim(let):E861: + [1] + [1, 10, 11, 10, 11, 10, 11, 10, 11, 10, 11, 10, 1] +--- 61,67 ---- + 0.0 + "\0": Vim(let):E861: + {"\0": 1}: Vim(let):E861: +! undefined_name: Vim(let):Trace + vim: Vim(let):E861: + [1] + [1, 10, 11, 10, 11, 10, 11, 10, 11, 10, 11, 10, 1] +*** ../vim-7.3.826/src/version.c 2013-02-20 16:46:52.000000000 +0100 +--- src/version.c 2013-02-20 16:48:39.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 827, + /**/ + +-- +Any resemblance between the above views and those of my employer, my terminal, +or the view out my window are purely coincidental. Any resemblance between +the above and my own views is non-deterministic. The question of the +existence of views in the absence of anyone to hold them is left as an +exercise for the reader. The question of the existence of the reader is left +as an exercise for the second god coefficient. (A discussion of +non-orthogonal, non-integral polytheism is beyond the scope of this article.) + (Ralph Jennings) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From aeecf43da818a9aa6c2a6271a09bb920a6c3db0c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:01 +0200 Subject: [PATCH 0714/3340] - patchlevel 828 --- 7.3.828 | 131 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 131 insertions(+) create mode 100644 7.3.828 diff --git a/7.3.828 b/7.3.828 new file mode 100644 index 00000000..cdcb950f --- /dev/null +++ b/7.3.828 @@ -0,0 +1,131 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.828 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.828 +Problem: Mappings are not aware of wildmenu mode. +Solution: Add wildmenumode(). (Christian Brabandt) +Files: src/eval.c, runtime/doc/eval.txt + + +*** ../vim-7.3.827/src/eval.c 2013-02-20 15:19:38.000000000 +0100 +--- src/eval.c 2013-02-20 17:45:19.000000000 +0100 +*************** +*** 751,756 **** +--- 751,757 ---- + static void f_values __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_virtcol __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_visualmode __ARGS((typval_T *argvars, typval_T *rettv)); ++ static void f_wildmenumode __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_winbufnr __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_wincol __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_winheight __ARGS((typval_T *argvars, typval_T *rettv)); +*************** +*** 8121,8126 **** +--- 8122,8128 ---- + {"values", 1, 1, f_values}, + {"virtcol", 1, 1, f_virtcol}, + {"visualmode", 0, 1, f_visualmode}, ++ {"wildmenumode", 0, 0, f_wildmenumode}, + {"winbufnr", 1, 1, f_winbufnr}, + {"wincol", 0, 0, f_wincol}, + {"winheight", 1, 1, f_winheight}, +*************** +*** 18576,18581 **** +--- 18578,18597 ---- + #endif + } + ++ /* ++ * "wildmenumode()" function ++ */ ++ static void ++ f_wildmenumode(argvars, rettv) ++ typval_T *argvars UNUSED; ++ typval_T *rettv UNUSED; ++ { ++ #ifdef FEAT_WILDMENU ++ if (wild_menu_showing) ++ rettv->vval.v_number = 1; ++ #endif ++ } ++ + /* + * "winbufnr(nr)" function + */ +*** ../vim-7.3.827/runtime/doc/eval.txt 2013-02-13 17:34:59.000000000 +0100 +--- runtime/doc/eval.txt 2013-02-20 17:43:23.000000000 +0100 +*************** +*** 1974,1986 **** + toupper( {expr}) String the String {expr} switched to uppercase + tr( {src}, {fromstr}, {tostr}) String translate chars of {src} in {fromstr} + to chars in {tostr} +! trunc( {expr} Float truncate Float {expr} + type( {name}) Number type of variable {name} + undofile( {name}) String undo file name for {name} + undotree() List undo file tree + values( {dict}) List values in {dict} + virtcol( {expr}) Number screen column of cursor or mark + visualmode( [expr]) String last visual mode used + winbufnr( {nr}) Number buffer number of window {nr} + wincol() Number window column of the cursor + winheight( {nr}) Number height of window {nr} +--- 1986,1999 ---- + toupper( {expr}) String the String {expr} switched to uppercase + tr( {src}, {fromstr}, {tostr}) String translate chars of {src} in {fromstr} + to chars in {tostr} +! trunc( {expr}) Float truncate Float {expr} + type( {name}) Number type of variable {name} + undofile( {name}) String undo file name for {name} + undotree() List undo file tree + values( {dict}) List values in {dict} + virtcol( {expr}) Number screen column of cursor or mark + visualmode( [expr]) String last visual mode used ++ wildmenumode() Number whether 'wildmenu' mode is active + winbufnr( {nr}) Number buffer number of window {nr} + wincol() Number window column of the cursor + winheight( {nr}) Number height of window {nr} +*************** +*** 6121,6126 **** +--- 6163,6180 ---- + Dictionary or Float is not a Number or String, thus does not + cause the mode to be cleared. + ++ wildmenumode() *wildmenumode()* ++ Returns non-zero when the wildmenu is active and zero ++ otherwise. See 'wildmenu' and 'wildmode'. ++ This can be used in mappings to handle the 'wildcharm' option ++ gracefully. (Makes only sense with |mapmode-c| mappings). ++ ++ For example to make work like in wildmode, use: > ++ :cnoremap wildmenumode() ? "\\" : "\" ++ < ++ (Note, this needs the 'wildcharm' option set appropriately). ++ ++ + *winbufnr()* + winbufnr({nr}) The result is a Number, which is the number of the buffer + associated with window {nr}. When {nr} is zero, the number of +*** ../vim-7.3.827/src/version.c 2013-02-20 16:54:24.000000000 +0100 +--- src/version.c 2013-02-20 17:41:17.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 828, + /**/ + +-- +"Beware of bugs in the above code; I have only proved +it correct, not tried it." -- Donald Knuth + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e68389f0810785ffba6c7c8ea0ece8ecf257c48f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:02 +0200 Subject: [PATCH 0715/3340] - patchlevel 829 --- 7.3.829 | 83 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 7.3.829 diff --git a/7.3.829 b/7.3.829 new file mode 100644 index 00000000..4cd795fa --- /dev/null +++ b/7.3.829 @@ -0,0 +1,83 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.829 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.829 +Problem: When compiled with the +rightleft feature 'showmatch' also shows a + match for the opening paren. When 'revins' is set the screen may + scroll. +Solution: Only check the opening paren when the +rightleft feature was + enabled. Do not show a match that is not visible. (partly by + Christian Brabandt) +Files: src/search.c + + +*** ../vim-7.3.828/src/search.c 2013-01-23 16:43:07.000000000 +0100 +--- src/search.c 2013-02-20 18:33:33.000000000 +0100 +*************** +*** 2431,2442 **** + /* 'matchpairs' is "x:y,x:y" */ + for (p = curbuf->b_p_mps; *p != NUL; ++p) + { +- if (PTR2CHAR(p) == c + #ifdef FEAT_RIGHTLEFT +! && (curwin->w_p_rl ^ p_ri) +! #endif +! ) + break; + p += MB_PTR2LEN(p) + 1; + if (PTR2CHAR(p) == c + #ifdef FEAT_RIGHTLEFT +--- 2431,2440 ---- + /* 'matchpairs' is "x:y,x:y" */ + for (p = curbuf->b_p_mps; *p != NUL; ++p) + { + #ifdef FEAT_RIGHTLEFT +! if (PTR2CHAR(p) == c && (curwin->w_p_rl ^ p_ri)) + break; ++ #endif + p += MB_PTR2LEN(p) + 1; + if (PTR2CHAR(p) == c + #ifdef FEAT_RIGHTLEFT +*************** +*** 2451,2457 **** + + if ((lpos = findmatch(NULL, NUL)) == NULL) /* no match, so beep */ + vim_beep(); +! else if (lpos->lnum >= curwin->w_topline) + { + if (!curwin->w_p_wrap) + getvcol(curwin, lpos, NULL, &vcol, NULL); +--- 2449,2455 ---- + + if ((lpos = findmatch(NULL, NUL)) == NULL) /* no match, so beep */ + vim_beep(); +! else if (lpos->lnum >= curwin->w_topline && lpos->lnum < curwin->w_botline) + { + if (!curwin->w_p_wrap) + getvcol(curwin, lpos, NULL, &vcol, NULL); +*** ../vim-7.3.828/src/version.c 2013-02-20 17:58:01.000000000 +0100 +--- src/version.c 2013-02-20 18:35:12.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 829, + /**/ + +-- +BLACK KNIGHT: The Black Knight always triumphs. Have at you! + ARTHUR takes his last leg off. The BLACK KNIGHT's body lands upright. +BLACK KNIGHT: All right, we'll call it a draw. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From dd7ab95564450d68215e902a16ad7f8377390494 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:02 +0200 Subject: [PATCH 0716/3340] - patchlevel 830 --- 7.3.830 | 88 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 88 insertions(+) create mode 100644 7.3.830 diff --git a/7.3.830 b/7.3.830 new file mode 100644 index 00000000..be9edebf --- /dev/null +++ b/7.3.830 @@ -0,0 +1,88 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.830 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.830 +Problem: :mksession confuses bytes, columns and characters when positioning + the cursor. +Solution: Use w_virtcol with "|" instead of w_cursor.col with "l". +Files: src/ex_docmd.c + + +*** ../vim-7.3.829/src/ex_docmd.c 2013-02-14 22:11:31.000000000 +0100 +--- src/ex_docmd.c 2013-02-20 19:13:21.000000000 +0100 +*************** +*** 10829,10852 **** + { + if (fprintf(fd, + "let s:c = %ld - ((%ld * winwidth(0) + %ld) / %ld)", +! (long)wp->w_cursor.col, +! (long)(wp->w_cursor.col - wp->w_leftcol), + (long)wp->w_width / 2, (long)wp->w_width) < 0 + || put_eol(fd) == FAIL + || put_line(fd, "if s:c > 0") == FAIL + || fprintf(fd, +! " exe 'normal! 0' . s:c . 'lzs' . (%ld - s:c) . 'l'", +! (long)wp->w_cursor.col) < 0 + || put_eol(fd) == FAIL + || put_line(fd, "else") == FAIL +! || fprintf(fd, " normal! 0%dl", wp->w_cursor.col) < 0 + || put_eol(fd) == FAIL + || put_line(fd, "endif") == FAIL) + return FAIL; + } + else + { +! if (fprintf(fd, "normal! 0%dl", wp->w_cursor.col) < 0 + || put_eol(fd) == FAIL) + return FAIL; + } +--- 10829,10852 ---- + { + if (fprintf(fd, + "let s:c = %ld - ((%ld * winwidth(0) + %ld) / %ld)", +! (long)wp->w_virtcol + 1, +! (long)(wp->w_virtcol - wp->w_leftcol), + (long)wp->w_width / 2, (long)wp->w_width) < 0 + || put_eol(fd) == FAIL + || put_line(fd, "if s:c > 0") == FAIL + || fprintf(fd, +! " exe 'normal! ' . s:c . '|zs' . %ld . '|'", +! (long)wp->w_virtcol + 1) < 0 + || put_eol(fd) == FAIL + || put_line(fd, "else") == FAIL +! || fprintf(fd, " normal! %d|", wp->w_virtcol + 1) < 0 + || put_eol(fd) == FAIL + || put_line(fd, "endif") == FAIL) + return FAIL; + } + else + { +! if (fprintf(fd, "normal! 0%d|", wp->w_virtcol + 1) < 0 + || put_eol(fd) == FAIL) + return FAIL; + } +*** ../vim-7.3.829/src/version.c 2013-02-20 18:39:07.000000000 +0100 +--- src/version.c 2013-02-20 19:14:18.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 830, + /**/ + +-- +Westheimer's Discovery: + A couple of months in the laboratory can + frequently save a couple of hours in the library. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a2599182a773a68bc3d2df714518f7b3143534c9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:03 +0200 Subject: [PATCH 0717/3340] - patchlevel 831 --- 7.3.831 | 609 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 609 insertions(+) create mode 100644 7.3.831 diff --git a/7.3.831 b/7.3.831 new file mode 100644 index 00000000..431b588a --- /dev/null +++ b/7.3.831 @@ -0,0 +1,609 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.831 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.831 +Problem: Clumsy to handle the situation that a variable does not exist. +Solution: Add default value to getbufvar() et al. (Shougo Matsushita, + Hirohito Higashi) +Files: runtime/doc/eval.txt, src/eval.c src/testdir/test91.in, + src/testdir/test91.ok, src/testdir/Make_amiga.mak, + src/testdir/Make_dos.mak, src/testdir/Make_ming.mak, + src/testdir/Make_os2.mak, src/testdir/Make_vms.mms, + src/testdir/Makefile + + +*** ../vim-7.3.830/runtime/doc/eval.txt 2013-02-20 17:58:01.000000000 +0100 +--- runtime/doc/eval.txt 2013-02-20 20:53:50.000000000 +0100 +*************** +*** 1761,1772 **** + foldtextresult( {lnum}) String text for closed fold at {lnum} + foreground( ) Number bring the Vim window to the foreground + function( {name}) Funcref reference to function {name} +! garbagecollect( [at_exit]) none free memory, breaking cyclic references + get( {list}, {idx} [, {def}]) any get item {idx} from {list} or {def} + get( {dict}, {key} [, {def}]) any get item {key} from {dict} or {def} + getbufline( {expr}, {lnum} [, {end}]) + List lines {lnum} to {end} of buffer {expr} +! getbufvar( {expr}, {varname}) any variable {varname} in buffer {expr} + getchar( [expr]) Number get one character from the user + getcharmod( ) Number modifiers for the last typed character + getcmdline() String return the current command-line +--- 1772,1784 ---- + foldtextresult( {lnum}) String text for closed fold at {lnum} + foreground( ) Number bring the Vim window to the foreground + function( {name}) Funcref reference to function {name} +! garbagecollect( [{atexit}]) none free memory, breaking cyclic references + get( {list}, {idx} [, {def}]) any get item {idx} from {list} or {def} + get( {dict}, {key} [, {def}]) any get item {key} from {dict} or {def} + getbufline( {expr}, {lnum} [, {end}]) + List lines {lnum} to {end} of buffer {expr} +! getbufvar( {expr}, {varname} [, {def}]) +! any variable {varname} in buffer {expr} + getchar( [expr]) Number get one character from the user + getcharmod( ) Number modifiers for the last typed character + getcmdline() String return the current command-line +*************** +*** 1787,1798 **** + getqflist() List list of quickfix items + getreg( [{regname} [, 1]]) String contents of register + getregtype( [{regname}]) String type of register +! gettabvar( {nr}, {varname}) any variable {varname} in tab {nr} +! gettabwinvar( {tabnr}, {winnr}, {name}) + any {name} in {winnr} in tab page {tabnr} + getwinposx() Number X coord in pixels of GUI Vim window + getwinposy() Number Y coord in pixels of GUI Vim window +! getwinvar( {nr}, {varname}) any variable {varname} in window {nr} + glob( {expr} [, {nosuf} [, {list}]]) + any expand file wildcards in {expr} + globpath( {path}, {expr} [, {flag}]) +--- 1799,1812 ---- + getqflist() List list of quickfix items + getreg( [{regname} [, 1]]) String contents of register + getregtype( [{regname}]) String type of register +! gettabvar( {nr}, {varname} [, {def}]) +! any variable {varname} in tab {nr} or {def} +! gettabwinvar( {tabnr}, {winnr}, {name} [, {def}]) + any {name} in {winnr} in tab page {tabnr} + getwinposx() Number X coord in pixels of GUI Vim window + getwinposy() Number Y coord in pixels of GUI Vim window +! getwinvar( {nr}, {varname} [, {def}]) +! any variable {varname} in window {nr} + glob( {expr} [, {nosuf} [, {list}]]) + any expand file wildcards in {expr} + globpath( {path}, {expr} [, {flag}]) +*************** +*** 3131,3137 **** + Example: > + :let lines = getbufline(bufnr("myfile"), 1, "$") + +! getbufvar({expr}, {varname}) *getbufvar()* + The result is the value of option or local buffer variable + {varname} in buffer {expr}. Note that the name without "b:" + must be used. +--- 3146,3152 ---- + Example: > + :let lines = getbufline(bufnr("myfile"), 1, "$") + +! getbufvar({expr}, {varname} [, {def}]) *getbufvar()* + The result is the value of option or local buffer variable + {varname} in buffer {expr}. Note that the name without "b:" + must be used. +*************** +*** 3141,3148 **** + doesn't work for a global variable, window-local variable or + window-local option. + For the use of {expr}, see |bufname()| above. +! When the buffer or variable doesn't exist an empty string is +! returned, there is no error message. + Examples: > + :let bufmodified = getbufvar(1, "&mod") + :echo "todo myvar = " . getbufvar("todo", "myvar") +--- 3156,3163 ---- + doesn't work for a global variable, window-local variable or + window-local option. + For the use of {expr}, see |bufname()| above. +! When the buffer or variable doesn't exist {def} or an empty +! string is returned, there is no error message. + Examples: > + :let bufmodified = getbufvar(1, "&mod") + :echo "todo myvar = " . getbufvar("todo", "myvar") +*************** +*** 3414,3439 **** + is one character with value 0x16. + If {regname} is not specified, |v:register| is used. + +! gettabvar({tabnr}, {varname}) *gettabvar()* + Get the value of a tab-local variable {varname} in tab page + {tabnr}. |t:var| + Tabs are numbered starting with one. + Note that the name without "t:" must be used. + +! gettabwinvar({tabnr}, {winnr}, {varname}) *gettabwinvar()* + Get the value of window-local variable {varname} in window + {winnr} in tab page {tabnr}. + When {varname} starts with "&" get the value of a window-local + option. + Tabs are numbered starting with one. For the current tabpage + use |getwinvar()|. + When {winnr} is zero the current window is used. + This also works for a global option, buffer-local option and + window-local option, but it doesn't work for a global variable + or buffer-local variable. +! When {varname} is empty a dictionary with all window-local +! variables is returned. +! Note that {varname} must be the name without "w:". + Examples: > + :let list_is_on = gettabwinvar(1, 2, '&list') + :echo "myvar = " . gettabwinvar(3, 1, 'myvar') +--- 3434,3463 ---- + is one character with value 0x16. + If {regname} is not specified, |v:register| is used. + +! gettabvar({tabnr}, {varname} [, {def}]) *gettabvar()* + Get the value of a tab-local variable {varname} in tab page + {tabnr}. |t:var| + Tabs are numbered starting with one. + Note that the name without "t:" must be used. ++ When the tab or variable doesn't exist {def} or an empty ++ string is returned, there is no error message. + +! gettabwinvar({tabnr}, {winnr}, {varname} [, {def}]) *gettabwinvar()* + Get the value of window-local variable {varname} in window + {winnr} in tab page {tabnr}. + When {varname} starts with "&" get the value of a window-local + option. ++ When {varname} is empty a dictionary with all window-local ++ variables is returned. ++ Note that {varname} must be the name without "w:". + Tabs are numbered starting with one. For the current tabpage + use |getwinvar()|. + When {winnr} is zero the current window is used. + This also works for a global option, buffer-local option and + window-local option, but it doesn't work for a global variable + or buffer-local variable. +! When the tab, window or variable doesn't exist {def} or an +! empty string is returned, there is no error message. + Examples: > + :let list_is_on = gettabwinvar(1, 2, '&list') + :echo "myvar = " . gettabwinvar(3, 1, 'myvar') +*************** +*** 3448,3454 **** + the top of the GUI Vim window. The result will be -1 if the + information is not available. + +! getwinvar({winnr}, {varname}) *getwinvar()* + Like |gettabwinvar()| for the current tabpage. + Examples: > + :let list_is_on = getwinvar(2, '&list') +--- 3472,3478 ---- + the top of the GUI Vim window. The result will be -1 if the + information is not available. + +! getwinvar({winnr}, {varname} [, {def}]) *getwinvar()* + Like |gettabwinvar()| for the current tabpage. + Examples: > + :let list_is_on = getwinvar(2, '&list') +*** ../vim-7.3.830/src/eval.c 2013-02-20 17:58:01.000000000 +0100 +--- src/eval.c 2013-02-20 20:52:09.000000000 +0100 +*************** +*** 7916,7922 **** + {"garbagecollect", 0, 1, f_garbagecollect}, + {"get", 2, 3, f_get}, + {"getbufline", 2, 3, f_getbufline}, +! {"getbufvar", 2, 2, f_getbufvar}, + {"getchar", 0, 1, f_getchar}, + {"getcharmod", 0, 0, f_getcharmod}, + {"getcmdline", 0, 0, f_getcmdline}, +--- 7916,7922 ---- + {"garbagecollect", 0, 1, f_garbagecollect}, + {"get", 2, 3, f_get}, + {"getbufline", 2, 3, f_getbufline}, +! {"getbufvar", 2, 3, f_getbufvar}, + {"getchar", 0, 1, f_getchar}, + {"getcharmod", 0, 0, f_getcharmod}, + {"getcmdline", 0, 0, f_getcmdline}, +*************** +*** 7936,7946 **** + {"getqflist", 0, 0, f_getqflist}, + {"getreg", 0, 2, f_getreg}, + {"getregtype", 0, 1, f_getregtype}, +! {"gettabvar", 2, 2, f_gettabvar}, +! {"gettabwinvar", 3, 3, f_gettabwinvar}, + {"getwinposx", 0, 0, f_getwinposx}, + {"getwinposy", 0, 0, f_getwinposy}, +! {"getwinvar", 2, 2, f_getwinvar}, + {"glob", 1, 3, f_glob}, + {"globpath", 2, 3, f_globpath}, + {"has", 1, 1, f_has}, +--- 7936,7946 ---- + {"getqflist", 0, 0, f_getqflist}, + {"getreg", 0, 2, f_getreg}, + {"getregtype", 0, 1, f_getregtype}, +! {"gettabvar", 2, 3, f_gettabvar}, +! {"gettabwinvar", 3, 4, f_gettabwinvar}, + {"getwinposx", 0, 0, f_getwinposx}, + {"getwinposy", 0, 0, f_getwinposy}, +! {"getwinvar", 2, 3, f_getwinvar}, + {"glob", 1, 3, f_glob}, + {"globpath", 2, 3, f_globpath}, + {"has", 1, 1, f_has}, +*************** +*** 11115,11122 **** + ++emsg_off; + buf = get_buf_tv(&argvars[0]); + +! rettv->v_type = VAR_STRING; +! rettv->vval.v_string = NULL; + + if (buf != NULL && varname != NULL) + { +--- 11115,11128 ---- + ++emsg_off; + buf = get_buf_tv(&argvars[0]); + +! if (argvars[2].v_type != VAR_UNKNOWN) +! /* set the default value */ +! copy_tv(&argvars[2], rettv); +! else +! { +! rettv->v_type = VAR_STRING; +! rettv->vval.v_string = NULL; +! } + + if (buf != NULL && varname != NULL) + { +*************** +*** 11785,11791 **** +--- 11791,11801 ---- + v = find_var_in_ht(&tp->tp_vars.dv_hashtab, varname, FALSE); + if (v != NULL) + copy_tv(&v->di_tv, rettv); ++ else if (argvars[2].v_type != VAR_UNKNOWN) ++ copy_tv(&argvars[2], rettv); + } ++ else if (argvars[2].v_type != VAR_UNKNOWN) ++ copy_tv(&argvars[2], rettv); + } + + /* +*************** +*** 11907,11914 **** + varname = get_tv_string_chk(&argvars[off + 1]); + ++emsg_off; + +! rettv->v_type = VAR_STRING; +! rettv->vval.v_string = NULL; + + if (win != NULL && varname != NULL) + { +--- 11917,11930 ---- + varname = get_tv_string_chk(&argvars[off + 1]); + ++emsg_off; + +! if (argvars[off + 2].v_type != VAR_UNKNOWN) +! /* set the default return value */ +! copy_tv(&argvars[off + 2], rettv); +! else +! { +! rettv->v_type = VAR_STRING; +! rettv->vval.v_string = NULL; +! } + + if (win != NULL && varname != NULL) + { +*** ../vim-7.3.830/src/testdir/test91.in 2013-02-20 21:09:20.000000000 +0100 +--- src/testdir/test91.in 2013-02-20 20:57:49.000000000 +0100 +*************** +*** 0 **** +--- 1,98 ---- ++ Tests for getbufvar(), getwinvar(), gettabvar() and gettabwinvar(). ++ vim: set ft=vim : ++ ++ STARTTEST ++ :so small.vim ++ :" ++ :" test for getbufvar() ++ :let b:var_num = 1234 ++ :let def_num = 5678 ++ :$put =string(getbufvar(1, 'var_num')) ++ :$put =string(getbufvar(1, 'var_num', def_num)) ++ :$put =string(getbufvar(1, '')) ++ :$put =string(getbufvar(1, '', def_num)) ++ :unlet b:var_num ++ :$put =string(getbufvar(1, 'var_num', def_num)) ++ :$put =string(getbufvar(1, '')) ++ :$put =string(getbufvar(1, '', def_num)) ++ :$put =string(getbufvar(9, '')) ++ :$put =string(getbufvar(9, '', def_num)) ++ :unlet def_num ++ :$put =string(getbufvar(1, '&autoindent')) ++ :$put =string(getbufvar(1, '&autoindent', 1)) ++ :" ++ :" test for getwinvar() ++ :let w:var_str = "Dance" ++ :let def_str = "Chance" ++ :$put =string(getwinvar(1, 'var_str')) ++ :$put =string(getwinvar(1, 'var_str', def_str)) ++ :$put =string(getwinvar(1, '')) ++ :$put =string(getwinvar(1, '', def_str)) ++ :unlet w:var_str ++ :$put =string(getwinvar(1, 'var_str', def_str)) ++ :$put =string(getwinvar(1, '')) ++ :$put =string(getwinvar(1, '', def_str)) ++ :$put =string(getwinvar(9, '')) ++ :$put =string(getwinvar(9, '', def_str)) ++ :$put =string(getwinvar(1, '&nu')) ++ :$put =string(getwinvar(1, '&nu', 1)) ++ :unlet def_str ++ :" ++ :" test for gettabvar() ++ :tabnew ++ :tabnew ++ :let t:var_list = [1, 2, 3] ++ :let def_list = [4, 5, 6, 7] ++ :tabrewind ++ :$put =string(gettabvar(3, 'var_list')) ++ :$put =string(gettabvar(3, 'var_list', def_list)) ++ :$put =string(gettabvar(3, '')) ++ :$put =string(gettabvar(3, '', def_list)) ++ :tablast ++ :unlet t:var_list ++ :tabrewind ++ :$put =string(gettabvar(3, 'var_list', def_list)) ++ :$put =string(gettabvar(9, '')) ++ :$put =string(gettabvar(9, '', def_list)) ++ :$put =string(gettabvar(3, '&nu')) ++ :$put =string(gettabvar(3, '&nu', def_list)) ++ :unlet def_list ++ :tabonly ++ :" ++ :" test for gettabwinvar() ++ :tabnew ++ :tabnew ++ :tabprev ++ :split ++ :split ++ :wincmd w ++ :vert split ++ :wincmd w ++ :let w:var_dict = {'dict': 'tabwin'} ++ :let def_dict = {'dict2': 'newval'} ++ :wincmd b ++ :tabrewind ++ :$put =string(gettabwinvar(2, 3, 'var_dict')) ++ :$put =string(gettabwinvar(2, 3, 'var_dict', def_dict)) ++ :$put =string(gettabwinvar(2, 3, '')) ++ :$put =string(gettabwinvar(2, 3, '', def_dict)) ++ :tabnext ++ :3wincmd w ++ :unlet w:var_dict ++ :tabrewind ++ :$put =string(gettabwinvar(2, 3, 'var_dict', def_dict)) ++ :$put =string(gettabwinvar(2, 3, '')) ++ :$put =string(gettabwinvar(2, 3, '', def_dict)) ++ :$put =string(gettabwinvar(2, 9, '')) ++ :$put =string(gettabwinvar(2, 9, '', def_dict)) ++ :$put =string(gettabwinvar(9, 3, '')) ++ :$put =string(gettabwinvar(9, 3, '', def_dict)) ++ :unlet def_dict ++ :$put =string(gettabwinvar(2, 3, '&nux')) ++ :$put =string(gettabwinvar(2, 3, '&nux', 1)) ++ :tabonly ++ :" ++ :/^start/,$wq! test.out ++ ENDTEST ++ ++ start: +*** ../vim-7.3.830/src/testdir/test91.ok 2013-02-20 21:09:20.000000000 +0100 +--- src/testdir/test91.ok 2013-02-20 20:57:45.000000000 +0100 +*************** +*** 0 **** +--- 1,45 ---- ++ start: ++ 1234 ++ 1234 ++ {'var_num': 1234} ++ {'var_num': 1234} ++ 5678 ++ {} ++ {} ++ '' ++ 5678 ++ 0 ++ 0 ++ 'Dance' ++ 'Dance' ++ {'var_str': 'Dance'} ++ {'var_str': 'Dance'} ++ 'Chance' ++ {} ++ {} ++ '' ++ 'Chance' ++ 0 ++ 0 ++ [1, 2, 3] ++ [1, 2, 3] ++ '' ++ [4, 5, 6, 7] ++ [4, 5, 6, 7] ++ '' ++ [4, 5, 6, 7] ++ '' ++ [4, 5, 6, 7] ++ {'dict': 'tabwin'} ++ {'dict': 'tabwin'} ++ {'var_dict': {'dict': 'tabwin'}} ++ {'var_dict': {'dict': 'tabwin'}} ++ {'dict2': 'newval'} ++ {} ++ {} ++ '' ++ {'dict2': 'newval'} ++ '' ++ {'dict2': 'newval'} ++ '' ++ 1 +*** ../vim-7.3.830/src/testdir/Make_amiga.mak 2013-02-13 17:34:59.000000000 +0100 +--- src/testdir/Make_amiga.mak 2013-02-20 20:21:03.000000000 +0100 +*************** +*** 32,38 **** + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out test90.out + + .SUFFIXES: .in .out + +--- 32,38 ---- + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out test90.out test91.out + + .SUFFIXES: .in .out + +*************** +*** 139,141 **** +--- 139,142 ---- + test88.out: test88.in + test89.out: test89.in + test90.out: test90.in ++ test91.out: test91.in +*** ../vim-7.3.830/src/testdir/Make_dos.mak 2013-02-13 17:34:59.000000000 +0100 +--- src/testdir/Make_dos.mak 2013-02-20 20:21:13.000000000 +0100 +*************** +*** 31,37 **** + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out + + SCRIPTS32 = test50.out test70.out + +--- 31,37 ---- + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out test91.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.830/src/testdir/Make_ming.mak 2013-02-13 17:34:59.000000000 +0100 +--- src/testdir/Make_ming.mak 2013-02-20 20:21:19.000000000 +0100 +*************** +*** 51,57 **** + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out + + SCRIPTS32 = test50.out test70.out + +--- 51,57 ---- + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out test91.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.830/src/testdir/Make_os2.mak 2013-02-13 17:34:59.000000000 +0100 +--- src/testdir/Make_os2.mak 2013-02-20 20:21:25.000000000 +0100 +*************** +*** 32,38 **** + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out test90.out + + .SUFFIXES: .in .out + +--- 32,38 ---- + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out test90.out test91.out + + .SUFFIXES: .in .out + +*** ../vim-7.3.830/src/testdir/Make_vms.mms 2013-02-13 17:34:59.000000000 +0100 +--- src/testdir/Make_vms.mms 2013-02-20 20:21:31.000000000 +0100 +*************** +*** 4,10 **** + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2013 Feb 13 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +--- 4,10 ---- + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2013 Feb 20 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +*************** +*** 77,83 **** + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ + test82.out test83.out test84.out test88.out test89.out \ +! test90.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +--- 77,83 ---- + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ + test82.out test83.out test84.out test88.out test89.out \ +! test90.out test91.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +*** ../vim-7.3.830/src/testdir/Makefile 2013-02-13 17:34:59.000000000 +0100 +--- src/testdir/Makefile 2013-02-20 20:21:47.000000000 +0100 +*************** +*** 28,34 **** + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out + + SCRIPTS_GUI = test16.out + +--- 28,34 ---- + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out test91.out + + SCRIPTS_GUI = test16.out + +*** ../vim-7.3.830/src/version.c 2013-02-20 19:26:24.000000000 +0100 +--- src/version.c 2013-02-20 21:08:40.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 831, + /**/ + +-- + | + +Ceci n'est pas une pipe. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8a98aa1d989cb04cc5c2d5ed64e8ace17702f75c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:04 +0200 Subject: [PATCH 0718/3340] - patchlevel 832 --- 7.3.832 | 66 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) create mode 100644 7.3.832 diff --git a/7.3.832 b/7.3.832 new file mode 100644 index 00000000..1a389406 --- /dev/null +++ b/7.3.832 @@ -0,0 +1,66 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.832 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.832 +Problem: Compiler warning. +Solution: Add type cast. (Mike Williams) +Files: src/version.c + + +*** ../vim-7.3.831/src/version.c 2013-02-20 21:11:14.000000000 +0100 +--- src/version.c 2013-02-26 11:21:41.000000000 +0100 +*************** +*** 2466,2472 **** + * width */ + for (i = 0; features[i] != NULL; ++i) + { +! int l = STRLEN(features[i]); + + if (l > width) + width = l; +--- 2468,2474 ---- + * width */ + for (i = 0; features[i] != NULL; ++i) + { +! int l = (int)STRLEN(features[i]); + + if (l > width) + width = l; +*************** +*** 2518,2523 **** +--- 2520,2526 ---- + msg_putchar('\n'); + } + } ++ + void + list_version() + { +*** ../vim-7.3.831/src/version.c 2013-02-20 21:11:14.000000000 +0100 +--- src/version.c 2013-02-26 11:21:41.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 832, + /**/ + +-- +Engineers are always delighted to share wisdom, even in areas in which they +have no experience whatsoever. Their logic provides them with inherent +insight into any field of expertise. This can be a problem when dealing with +the illogical people who believe that knowledge can only be derived through +experience. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1ae198ba72b760669e489a1fb9c99539941c6630 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:04 +0200 Subject: [PATCH 0719/3340] - patchlevel 833 --- 7.3.833 | 118 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 118 insertions(+) create mode 100644 7.3.833 diff --git a/7.3.833 b/7.3.833 new file mode 100644 index 00000000..b28af4f9 --- /dev/null +++ b/7.3.833 @@ -0,0 +1,118 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.833 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.833 +Problem: In the terminal the scroll wheel always scrolls the active window. +Solution: Scroll the window under the mouse pointer, like in the GUI. + (Bradie Rao) +Files: src/edit.c, src/normal.c + + +*** ../vim-7.3.832/src/edit.c 2013-02-13 16:30:17.000000000 +0100 +--- src/edit.c 2013-02-26 11:20:31.000000000 +0100 +*************** +*** 9139,9147 **** + + tpos = curwin->w_cursor; + +! # if defined(FEAT_GUI) && defined(FEAT_WINDOWS) +! /* Currently the mouse coordinates are only known in the GUI. */ +! if (gui.in_use && mouse_row >= 0 && mouse_col >= 0) + { + int row, col; + +--- 9139,9146 ---- + + tpos = curwin->w_cursor; + +! # ifdef FEAT_WINDOWS +! if (mouse_row >= 0 && mouse_col >= 0) + { + int row, col; + +*************** +*** 9191,9197 **** + # endif + } + +! # if defined(FEAT_GUI) && defined(FEAT_WINDOWS) + curwin->w_redr_status = TRUE; + + curwin = old_curwin; +--- 9190,9196 ---- + # endif + } + +! # ifdef FEAT_WINDOWS + curwin->w_redr_status = TRUE; + + curwin = old_curwin; +*** ../vim-7.3.832/src/normal.c 2013-02-14 22:11:31.000000000 +0100 +--- src/normal.c 2013-02-26 11:20:31.000000000 +0100 +*************** +*** 4649,4659 **** + nv_mousescroll(cap) + cmdarg_T *cap; + { +! # if defined(FEAT_GUI) && defined(FEAT_WINDOWS) + win_T *old_curwin = curwin; + +! /* Currently we only get the mouse coordinates in the GUI. */ +! if (gui.in_use && mouse_row >= 0 && mouse_col >= 0) + { + int row, col; + +--- 4649,4658 ---- + nv_mousescroll(cap) + cmdarg_T *cap; + { +! # ifdef FEAT_WINDOWS + win_T *old_curwin = curwin; + +! if (mouse_row >= 0 && mouse_col >= 0) + { + int row, col; + +*************** +*** 4698,4704 **** + } + # endif + +! # if defined(FEAT_GUI) && defined(FEAT_WINDOWS) + curwin->w_redr_status = TRUE; + + curwin = old_curwin; +--- 4697,4703 ---- + } + # endif + +! # ifdef FEAT_WINDOWS + curwin->w_redr_status = TRUE; + + curwin = old_curwin; +*** ../vim-7.3.832/src/version.c 2013-02-26 11:25:28.000000000 +0100 +--- src/version.c 2013-02-26 13:28:51.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 833, + /**/ + +-- +Female engineers become irresistible at the age of consent and remain that +way until about thirty minutes after their clinical death. Longer if it's a +warm day. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1ce0605ae6e613b953803959d7519168bf8f2a00 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:05 +0200 Subject: [PATCH 0720/3340] - patchlevel 834 --- 7.3.834 | 83 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 7.3.834 diff --git a/7.3.834 b/7.3.834 new file mode 100644 index 00000000..b95610e8 --- /dev/null +++ b/7.3.834 @@ -0,0 +1,83 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.834 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.834 +Problem: Ruby 2.0 has a few API changes. +Solution: Add handling of Ruby 2.0. (Yasuhiro Matsumoto) +Files: src/if_ruby.c + + +*** ../vim-7.3.833/src/if_ruby.c 2013-02-14 22:19:47.000000000 +0100 +--- src/if_ruby.c 2013-02-26 13:41:24.000000000 +0100 +*************** +*** 189,195 **** +--- 189,197 ---- + #ifndef RUBY19_OR_LATER + #define rb_num2long dll_rb_num2long + #endif ++ #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER <= 19 + #define rb_num2ulong dll_rb_num2ulong ++ #endif + #define rb_obj_alloc dll_rb_obj_alloc + #define rb_obj_as_string dll_rb_obj_as_string + #define rb_obj_id dll_rb_obj_id +*************** +*** 344,349 **** +--- 346,362 ---- + { + return dll_rb_int2big(x); + } ++ #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 20 ++ VALUE ++ rb_float_new_in_heap(double d) ++ { ++ return dll_rb_float_new(d); ++ } ++ unsigned long rb_num2ulong(VALUE x) ++ { ++ return (long)RSHIFT((SIGNED_VALUE)(x),1); ++ } ++ #endif + #endif + + static HINSTANCE hinstRuby = NULL; /* Instance of ruby.dll */ +*************** +*** 434,440 **** +--- 447,457 ---- + #endif + #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + {"rb_string_value_ptr", (RUBY_PROC*)&dll_rb_string_value_ptr}, ++ # if DYNAMIC_RUBY_VER <= 19 + {"rb_float_new", (RUBY_PROC*)&dll_rb_float_new}, ++ # else ++ {"rb_float_new_in_heap", (RUBY_PROC*)&dll_rb_float_new}, ++ # endif + {"rb_ary_new", (RUBY_PROC*)&dll_rb_ary_new}, + {"rb_ary_push", (RUBY_PROC*)&dll_rb_ary_push}, + #endif +*** ../vim-7.3.833/src/version.c 2013-02-26 13:30:28.000000000 +0100 +--- src/version.c 2013-02-26 13:33:34.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 834, + /**/ + +-- +An alien life briefly visits earth. Just before departing it leaves a +message in the dust on the back of a white van. The world is shocked +and wants to know what it means. After months of studies the worlds +best linguistic scientists are able to decipher the message: "Wash me!". + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f4766d776c326603764f32316ebf99456ff0eebb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:06 +0200 Subject: [PATCH 0721/3340] - patchlevel 835 --- 7.3.835 | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 7.3.835 diff --git a/7.3.835 b/7.3.835 new file mode 100644 index 00000000..61991bb9 --- /dev/null +++ b/7.3.835 @@ -0,0 +1,60 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.835 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.835 +Problem: "xxd -i" fails on an empty file. +Solution: Do output the closing } for an empty file. (partly by Lawrence + Woodman) +Files: src/xxd/xxd.c + + +*** ../vim-7.3.834/src/xxd/xxd.c 2011-04-11 21:35:03.000000000 +0200 +--- src/xxd/xxd.c 2013-02-26 14:08:48.000000000 +0100 +*************** +*** 729,737 **** + if (c == EOF && ferror(fp)) + die(2); + +! if (p) +! if (fputs("\n};\n" + 3 * (fp == stdin), fpo) == EOF) +! die(3); + + if (fp != stdin) + { +--- 729,738 ---- + if (c == EOF && ferror(fp)) + die(2); + +! if (p && fputs("\n", fpo) == EOF) +! die(3); +! if (fputs("};\n" + 3 * (fp == stdin), fpo) == EOF) +! die(3); + + if (fp != stdin) + { +*** ../vim-7.3.834/src/version.c 2013-02-26 13:41:31.000000000 +0100 +--- src/version.c 2013-02-26 14:11:21.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 835, + /**/ + +-- +For society, it's probably a good thing that engineers value function over +appearance. For example, you wouldn't want engineers to build nuclear power +plants that only _look_ like they would keep all the radiation inside. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e373ee4808a75f0938a2d32ada796190c5b54b30 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:06 +0200 Subject: [PATCH 0722/3340] - patchlevel 836 --- 7.3.836 | 2071 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 2071 insertions(+) create mode 100644 7.3.836 diff --git a/7.3.836 b/7.3.836 new file mode 100644 index 00000000..712e2b3d --- /dev/null +++ b/7.3.836 @@ -0,0 +1,2071 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.836 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.836 +Problem: Clipboard does not work on Win32 when compiled with Cygwin. +Solution: Move the Win32 clipboard code to a separate file and use it when + building with os_unix.c. (Frodak Baksik, Ken Takata) +Files: src/Make_bc5.mak, src/Make_cyg.mak, src/Make_ivc.mak, + src/Make_ming.mak, src/Make_mvc.mak, src/Make_w16.mak, + src/Makefile, src/config.h.in, src/configure.in, + src/auto/configure, src/feature.h, src/globals.h, src/mbyte.c, + src/os_mswin.c, src/os_unix.c, src/os_win32.c, src/proto.h, + src/proto/os_mswin.pro, src/proto/winclip.pro, src/term.c, + src/vim.h, src/winclip.c + + +*** ../vim-7.3.835/src/Make_bc5.mak 2010-08-15 21:57:32.000000000 +0200 +--- src/Make_bc5.mak 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 694,700 **** + + !if ($(OSTYPE)==WIN32) + vimobj = $(vimobj) \ +! $(OBJDIR)\os_win32.obj $(OBJDIR)\os_mswin.obj + !elif ($(OSTYPE)==DOS16) + vimobj = $(vimobj) \ + $(OBJDIR)\os_msdos.obj +--- 694,700 ---- + + !if ($(OSTYPE)==WIN32) + vimobj = $(vimobj) \ +! $(OBJDIR)\os_win32.obj $(OBJDIR)\os_mswin.obj $(OBJDIR)\winclip.obj + !elif ($(OSTYPE)==DOS16) + vimobj = $(vimobj) \ + $(OBJDIR)\os_msdos.obj +*** ../vim-7.3.835/src/Make_cyg.mak 2013-02-20 13:34:14.000000000 +0100 +--- src/Make_cyg.mak 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 547,552 **** +--- 547,553 ---- + $(OUTDIR)/option.o \ + $(OUTDIR)/os_win32.o \ + $(OUTDIR)/os_mswin.o \ ++ $(OUTDIR)/winclip.o \ + $(OUTDIR)/pathdef.o \ + $(OUTDIR)/popupmnu.o \ + $(OUTDIR)/quickfix.o \ +*** ../vim-7.3.835/src/Make_ivc.mak 2010-08-15 21:57:28.000000000 +0200 +--- src/Make_ivc.mak 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 241,246 **** +--- 241,247 ---- + "$(INTDIR)/ops.obj" \ + "$(INTDIR)/option.obj" \ + "$(INTDIR)/os_mswin.obj" \ ++ "$(INTDIR)/winclip.obj" \ + "$(INTDIR)/os_win32.obj" \ + "$(INTDIR)/popupmnu.obj" \ + "$(INTDIR)/quickfix.obj" \ +*************** +*** 600,605 **** +--- 601,610 ---- + # End Source File + # Begin Source File + ++ SOURCE=.\winclip.c ++ # End Source File ++ # Begin Source File ++ + SOURCE=.\os_win32.c + # End Source File + # Begin Source File +*** ../vim-7.3.835/src/Make_ming.mak 2013-01-30 14:55:35.000000000 +0100 +--- src/Make_ming.mak 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 523,528 **** +--- 523,529 ---- + $(OUTDIR)/option.o \ + $(OUTDIR)/os_win32.o \ + $(OUTDIR)/os_mswin.o \ ++ $(OUTDIR)/winclip.o \ + $(OUTDIR)/pathdef.o \ + $(OUTDIR)/popupmnu.o \ + $(OUTDIR)/quickfix.o \ +*** ../vim-7.3.835/src/Make_mvc.mak 2013-01-30 14:55:35.000000000 +0100 +--- src/Make_mvc.mak 2013-02-26 14:29:05.000000000 +0100 +*************** +*** 543,548 **** +--- 543,549 ---- + $(OUTDIR)\ops.obj \ + $(OUTDIR)\option.obj \ + $(OUTDIR)\os_mswin.obj \ ++ $(OUTDIR)\winclip.obj \ + $(OUTDIR)\os_win32.obj \ + $(OUTDIR)\pathdef.obj \ + $(OUTDIR)\popupmnu.obj \ +*************** +*** 1149,1154 **** +--- 1150,1157 ---- + + $(OUTDIR)/os_mswin.obj: $(OUTDIR) os_mswin.c $(INCL) + ++ $(OUTDIR)/winclip.obj: $(OUTDIR) winclip.c $(INCL) ++ + $(OUTDIR)/os_win32.obj: $(OUTDIR) os_win32.c $(INCL) os_win32.h + + $(OUTDIR)/os_w32exe.obj: $(OUTDIR) os_w32exe.c $(INCL) +*************** +*** 1256,1261 **** +--- 1259,1265 ---- + proto/ops.pro \ + proto/option.pro \ + proto/os_mswin.pro \ ++ proto/winclip.pro \ + proto/os_win32.pro \ + proto/popupmnu.pro \ + proto/quickfix.pro \ +*** ../vim-7.3.835/src/Make_w16.mak 2010-08-15 21:57:27.000000000 +0200 +--- src/Make_w16.mak 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 107,112 **** +--- 107,113 ---- + $(INTDIR)\os_win16.obj\ + $(INTDIR)\os_msdos.obj\ + $(INTDIR)\os_mswin.obj\ ++ $(INTDIR)\winclip.obj\ + $(INTDIR)\popupmnu.obj\ + $(INTDIR)\quickfix.obj\ + $(INTDIR)\regexp.obj\ +*** ../vim-7.3.835/src/Makefile 2013-01-30 17:41:43.000000000 +0100 +--- src/Makefile 2013-02-26 14:54:51.000000000 +0100 +*************** +*** 1638,1644 **** + RSRC_DIR = os_mac_rsrc + + PRO_MANUAL = os_amiga.pro os_msdos.pro os_win16.pro os_win32.pro \ +! os_mswin.pro os_beos.pro os_vms.pro $(PERL_PRO) + + # Default target is making the executable and tools + all: $(VIMTARGET) $(TOOLS) languages $(GUI_BUNDLE) +--- 1638,1644 ---- + RSRC_DIR = os_mac_rsrc + + PRO_MANUAL = os_amiga.pro os_msdos.pro os_win16.pro os_win32.pro \ +! os_mswin.pro winclip.pro os_beos.pro os_vms.pro $(PERL_PRO) + + # Default target is making the executable and tools + all: $(VIMTARGET) $(TOOLS) languages $(GUI_BUNDLE) +*************** +*** 1792,1797 **** +--- 1792,1801 ---- + $(CPROTO) -DWIN16 -DWIN32 -UHAVE_CONFIG_H $< > proto/$@ + echo "/* vim: set ft=c : */" >> proto/$@ + ++ winclip.pro: winclip.c ++ $(CPROTO) -DWIN16 -DWIN32 -UHAVE_CONFIG_H $< > proto/$@ ++ echo "/* vim: set ft=c : */" >> proto/$@ ++ + os_beos.pro: os_beos.c + $(CPROTO) -D__BEOS__ -UHAVE_CONFIG_H $< > proto/$@ + echo "/* vim: set ft=c : */" >> proto/$@ +*************** +*** 2642,2647 **** +--- 2646,2657 ---- + objects/os_unix.o: os_unix.c + $(CCC) -o $@ os_unix.c + ++ objects/os_mswin.o: os_mswin.c ++ $(CCC) -o $@ os_mswin.c ++ ++ objects/winclip.o: winclip.c ++ $(CCC) -o $@ winclip.c ++ + objects/pathdef.o: auto/pathdef.c + $(CCC) -o $@ auto/pathdef.c + +*************** +*** 2970,2975 **** +--- 2980,2989 ---- + ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \ + gui_beval.h proto/gui_beval.pro ex_cmds.h proto.h globals.h farsi.h \ + arabic.h version.h ++ objects/winclip.o: winclip.c vimio.h vim.h auto/config.h feature.h os_unix.h \ ++ auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \ ++ regexp.h gui.h ex_cmds.h proto.h globals.h farsi.h arabic.h \ ++ proto/winclip.pro + objects/window.o: window.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \ + ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \ + gui_beval.h proto/gui_beval.pro ex_cmds.h proto.h globals.h farsi.h \ +*** ../vim-7.3.835/src/config.h.in 2012-08-15 14:04:50.000000000 +0200 +--- src/config.h.in 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 439,441 **** +--- 439,444 ---- + + /* Define if fcntl()'s F_SETFD command knows about FD_CLOEXEC */ + #undef HAVE_FD_CLOEXEC ++ ++ /* Define if you want Cygwin to use the WIN32 clipboard, not compatible with X11*/ ++ #undef FEAT_CYGWIN_WIN32_CLIPBOARD +*** ../vim-7.3.835/src/configure.in 2013-02-06 19:49:37.000000000 +0100 +--- src/configure.in 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 2474,2479 **** +--- 2474,2494 ---- + dnl end of GUI-checking + dnl --------------------------------------------------------------------------- + ++ dnl Check for Cygwin, which needs an extra source file if not using X11 ++ AC_MSG_CHECKING(for CYGWIN environment) ++ case `uname` in ++ CYGWIN*) CYGWIN=yes; AC_MSG_RESULT(yes) ++ AC_MSG_CHECKING(for CYGWIN clipboard support) ++ if test "x$with_x" = "xno" ; then ++ OS_EXTRA_SRC=winclip.c; OS_EXTRA_OBJ=objects/winclip.o ++ AC_MSG_RESULT(yes) ++ AC_DEFINE(FEAT_CYGWIN_WIN32_CLIPBOARD) ++ else ++ AC_MSG_RESULT(no - using X11) ++ fi ;; ++ ++ *) CYGWIN=no; AC_MSG_RESULT(no);; ++ esac + + dnl Only really enable hangul input when GUI and XFONTSET are available + if test "$enable_hangulinput" = "yes"; then +*** ../vim-7.3.835/src/auto/configure 2013-02-06 19:49:38.000000000 +0100 +--- src/auto/configure 2013-02-26 14:22:16.000000000 +0100 +*************** +*** 8846,8851 **** +--- 8846,8872 ---- + + + ++ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGWIN environment" >&5 ++ $as_echo_n "checking for CYGWIN environment... " >&6; } ++ case `uname` in ++ CYGWIN*) CYGWIN=yes; { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 ++ $as_echo "yes" >&6; } ++ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGWIN clipboard support" >&5 ++ $as_echo_n "checking for CYGWIN clipboard support... " >&6; } ++ if test "x$with_x" = "xno" ; then ++ OS_EXTRA_SRC=winclip.c; OS_EXTRA_OBJ=objects/winclip.o ++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 ++ $as_echo "yes" >&6; } ++ $as_echo "#define FEAT_CYGWIN_WIN32_CLIPBOARD 1" >>confdefs.h ++ ++ else ++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no - using X11" >&5 ++ $as_echo "no - using X11" >&6; } ++ fi ;; ++ ++ *) CYGWIN=no; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 ++ $as_echo "no" >&6; };; ++ esac + + if test "$enable_hangulinput" = "yes"; then + if test "x$GUITYPE" = "xNONE"; then +*** ../vim-7.3.835/src/feature.h 2013-02-14 22:11:31.000000000 +0100 +--- src/feature.h 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 1129,1134 **** +--- 1129,1139 ---- + * +xterm_clipboard Unix only: Include code for handling the clipboard + * in an xterm like in the GUI. + */ ++ ++ #ifdef FEAT_CYGWIN_WIN32_CLIPBOARD ++ # define FEAT_CLIPBOARD ++ #endif ++ + #ifdef FEAT_GUI + # ifndef FEAT_CLIPBOARD + # define FEAT_CLIPBOARD +*** ../vim-7.3.835/src/globals.h 2012-08-23 18:43:06.000000000 +0200 +--- src/globals.h 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 802,808 **** + EXTERN int enc_unicode INIT(= 0); /* 2: UCS-2 or UTF-16, 4: UCS-4 */ + EXTERN int enc_utf8 INIT(= FALSE); /* UTF-8 encoded Unicode */ + EXTERN int enc_latin1like INIT(= TRUE); /* 'encoding' is latin1 comp. */ +! # ifdef WIN3264 + /* Codepage nr of 'encoding'. Negative means it's not been set yet, zero + * means 'encoding' is not a valid codepage. */ + EXTERN int enc_codepage INIT(= -1); +--- 802,808 ---- + EXTERN int enc_unicode INIT(= 0); /* 2: UCS-2 or UTF-16, 4: UCS-4 */ + EXTERN int enc_utf8 INIT(= FALSE); /* UTF-8 encoded Unicode */ + EXTERN int enc_latin1like INIT(= TRUE); /* 'encoding' is latin1 comp. */ +! # if defined(WIN3264) || defined(FEAT_CYGWIN_WIN32_CLIPBOARD) + /* Codepage nr of 'encoding'. Negative means it's not been set yet, zero + * means 'encoding' is not a valid codepage. */ + EXTERN int enc_codepage INIT(= -1); +*** ../vim-7.3.835/src/mbyte.c 2013-02-13 16:49:54.000000000 +0100 +--- src/mbyte.c 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 613,619 **** + enc_dbcs = enc_dbcs_new; + has_mbyte = (enc_dbcs != 0 || enc_utf8); + +! #ifdef WIN3264 + enc_codepage = encname2codepage(p_enc); + enc_latin9 = (STRCMP(p_enc, "iso-8859-15") == 0); + #endif +--- 613,619 ---- + enc_dbcs = enc_dbcs_new; + has_mbyte = (enc_dbcs != 0 || enc_utf8); + +! #if defined(WIN3264) || defined(FEAT_CYGWIN_WIN32_CLIPBOARD) + enc_codepage = encname2codepage(p_enc); + enc_latin9 = (STRCMP(p_enc, "iso-8859-15") == 0); + #endif +*************** +*** 4089,4095 **** + return enc_canonize((char_u *)buf); + } + +! #if defined(WIN3264) || defined(PROTO) + /* + * Convert an encoding name to an MS-Windows codepage. + * Returns zero if no codepage can be figured out. +--- 4089,4095 ---- + return enc_canonize((char_u *)buf); + } + +! #if defined(WIN3264) || defined(PROTO) || defined(FEAT_CYGWIN_WIN32_CLIPBOARD) + /* + * Convert an encoding name to an MS-Windows codepage. + * Returns zero if no codepage can be figured out. +*** ../vim-7.3.835/src/os_mswin.c 2012-11-20 16:53:34.000000000 +0100 +--- src/os_mswin.c 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 905,1640 **** + } + #endif + +- #if defined(FEAT_MBYTE) || defined(PROTO) +- /* +- * Convert an UTF-8 string to UTF-16. +- * "instr[inlen]" is the input. "inlen" is in bytes. +- * When "outstr" is NULL only return the number of UTF-16 words produced. +- * Otherwise "outstr" must be a buffer of sufficient size. +- * Returns the number of UTF-16 words produced. +- */ +- int +- utf8_to_utf16(char_u *instr, int inlen, short_u *outstr, int *unconvlenp) +- { +- int outlen = 0; +- char_u *p = instr; +- int todo = inlen; +- int l; +- int ch; +- +- while (todo > 0) +- { +- /* Only convert if we have a complete sequence. */ +- l = utf_ptr2len_len(p, todo); +- if (l > todo) +- { +- /* Return length of incomplete sequence. */ +- if (unconvlenp != NULL) +- *unconvlenp = todo; +- break; +- } +- +- ch = utf_ptr2char(p); +- if (ch >= 0x10000) +- { +- /* non-BMP character, encoding with surrogate pairs */ +- ++outlen; +- if (outstr != NULL) +- { +- *outstr++ = (0xD800 - (0x10000 >> 10)) + (ch >> 10); +- *outstr++ = 0xDC00 | (ch & 0x3FF); +- } +- } +- else if (outstr != NULL) +- *outstr++ = ch; +- ++outlen; +- p += l; +- todo -= l; +- } +- +- return outlen; +- } +- +- /* +- * Convert an UTF-16 string to UTF-8. +- * The input is "instr[inlen]" with "inlen" in number of UTF-16 words. +- * When "outstr" is NULL only return the required number of bytes. +- * Otherwise "outstr" must be a buffer of sufficient size. +- * Return the number of bytes produced. +- */ +- int +- utf16_to_utf8(short_u *instr, int inlen, char_u *outstr) +- { +- int outlen = 0; +- int todo = inlen; +- short_u *p = instr; +- int l; +- int ch, ch2; +- +- while (todo > 0) +- { +- ch = *p; +- if (ch >= 0xD800 && ch <= 0xDBFF && todo > 1) +- { +- /* surrogate pairs handling */ +- ch2 = p[1]; +- if (ch2 >= 0xDC00 && ch2 <= 0xDFFF) +- { +- ch = ((ch - 0xD800) << 10) + (ch2 & 0x3FF) + 0x10000; +- ++p; +- --todo; +- } +- } +- if (outstr != NULL) +- { +- l = utf_char2bytes(ch, outstr); +- outstr += l; +- } +- else +- l = utf_char2len(ch); +- ++p; +- outlen += l; +- --todo; +- } +- +- return outlen; +- } +- +- /* +- * Call MultiByteToWideChar() and allocate memory for the result. +- * Returns the result in "*out[*outlen]" with an extra zero appended. +- * "outlen" is in words. +- */ +- void +- MultiByteToWideChar_alloc(UINT cp, DWORD flags, +- LPCSTR in, int inlen, +- LPWSTR *out, int *outlen) +- { +- *outlen = MultiByteToWideChar(cp, flags, in, inlen, 0, 0); +- /* Add one one word to avoid a zero-length alloc(). */ +- *out = (LPWSTR)alloc(sizeof(WCHAR) * (*outlen + 1)); +- if (*out != NULL) +- { +- MultiByteToWideChar(cp, flags, in, inlen, *out, *outlen); +- (*out)[*outlen] = 0; +- } +- } +- +- /* +- * Call WideCharToMultiByte() and allocate memory for the result. +- * Returns the result in "*out[*outlen]" with an extra NUL appended. +- */ +- void +- WideCharToMultiByte_alloc(UINT cp, DWORD flags, +- LPCWSTR in, int inlen, +- LPSTR *out, int *outlen, +- LPCSTR def, LPBOOL useddef) +- { +- *outlen = WideCharToMultiByte(cp, flags, in, inlen, NULL, 0, def, useddef); +- /* Add one one byte to avoid a zero-length alloc(). */ +- *out = alloc((unsigned)*outlen + 1); +- if (*out != NULL) +- { +- WideCharToMultiByte(cp, flags, in, inlen, *out, *outlen, def, useddef); +- (*out)[*outlen] = 0; +- } +- } +- +- #endif /* FEAT_MBYTE */ +- +- #ifdef FEAT_CLIPBOARD +- /* +- * Clipboard stuff, for cutting and pasting text to other windows. +- */ +- +- /* Type used for the clipboard type of Vim's data. */ +- typedef struct +- { +- int type; /* MCHAR, MBLOCK or MLINE */ +- int txtlen; /* length of CF_TEXT in bytes */ +- int ucslen; /* length of CF_UNICODETEXT in words */ +- int rawlen; /* length of clip_star.format_raw, including encoding, +- excluding terminating NUL */ +- } VimClipType_t; +- +- /* +- * Make vim the owner of the current selection. Return OK upon success. +- */ +- /*ARGSUSED*/ +- int +- clip_mch_own_selection(VimClipboard *cbd) +- { +- /* +- * Never actually own the clipboard. If another application sets the +- * clipboard, we don't want to think that we still own it. +- */ +- return FAIL; +- } +- +- /* +- * Make vim NOT the owner of the current selection. +- */ +- /*ARGSUSED*/ +- void +- clip_mch_lose_selection(VimClipboard *cbd) +- { +- /* Nothing needs to be done here */ +- } +- +- /* +- * Copy "str[*size]" into allocated memory, changing CR-NL to NL. +- * Return the allocated result and the size in "*size". +- * Returns NULL when out of memory. +- */ +- static char_u * +- crnl_to_nl(const char_u *str, int *size) +- { +- int pos = 0; +- int str_len = *size; +- char_u *ret; +- char_u *retp; +- +- /* Avoid allocating zero bytes, it generates an error message. */ +- ret = lalloc((long_u)(str_len == 0 ? 1 : str_len), TRUE); +- if (ret != NULL) +- { +- retp = ret; +- for (pos = 0; pos < str_len; ++pos) +- { +- if (str[pos] == '\r' && str[pos + 1] == '\n') +- { +- ++pos; +- --(*size); +- } +- *retp++ = str[pos]; +- } +- } +- +- return ret; +- } +- +- /* +- * Wait for another process to Close the Clipboard. +- * Returns TRUE for success. +- */ +- static int +- vim_open_clipboard(void) +- { +- int delay = 10; +- +- while (!OpenClipboard(NULL)) +- { +- if (delay > 500) +- return FALSE; /* waited too long, give up */ +- Sleep(delay); +- delay *= 2; /* wait for 10, 20, 40, 80, etc. msec */ +- } +- return TRUE; +- } +- +- /* +- * Get the current selection and put it in the clipboard register. +- * +- * NOTE: Must use GlobalLock/Unlock here to ensure Win32s compatibility. +- * On NT/W95 the clipboard data is a fixed global memory object and +- * so its handle = its pointer. +- * On Win32s, however, co-operation with the Win16 system means that +- * the clipboard data is moveable and its handle is not a pointer at all, +- * so we can't just cast the return value of GetClipboardData to (char_u*). +- * +- */ +- void +- clip_mch_request_selection(VimClipboard *cbd) +- { +- VimClipType_t metadata = { -1, -1, -1, -1 }; +- HGLOBAL hMem = NULL; +- char_u *str = NULL; +- #if defined(FEAT_MBYTE) && defined(WIN3264) +- char_u *to_free = NULL; +- #endif +- #ifdef FEAT_MBYTE +- HGLOBAL rawh = NULL; +- #endif +- int str_size = 0; +- int maxlen; +- size_t n; +- +- /* +- * Don't pass GetActiveWindow() as an argument to OpenClipboard() because +- * then we can't paste back into the same window for some reason - webb. +- */ +- if (!vim_open_clipboard()) +- return; +- +- /* Check for vim's own clipboard format first. This only gets the type of +- * the data, still need to use CF_UNICODETEXT or CF_TEXT for the text. */ +- if (IsClipboardFormatAvailable(cbd->format)) +- { +- VimClipType_t *meta_p; +- HGLOBAL meta_h; +- +- /* We have metadata on the clipboard; try to get it. */ +- if ((meta_h = GetClipboardData(cbd->format)) != NULL +- && (meta_p = (VimClipType_t *)GlobalLock(meta_h)) != NULL) +- { +- /* The size of "VimClipType_t" changed, "rawlen" was added later. +- * Only copy what is available for backwards compatibility. */ +- n = sizeof(VimClipType_t); +- if (GlobalSize(meta_h) < n) +- n = GlobalSize(meta_h); +- memcpy(&metadata, meta_p, n); +- GlobalUnlock(meta_h); +- } +- } +- +- #ifdef FEAT_MBYTE +- /* Check for Vim's raw clipboard format first. This is used without +- * conversion, but only if 'encoding' matches. */ +- if (IsClipboardFormatAvailable(cbd->format_raw) +- && metadata.rawlen > (int)STRLEN(p_enc)) +- { +- /* We have raw data on the clipboard; try to get it. */ +- if ((rawh = GetClipboardData(cbd->format_raw)) != NULL) +- { +- char_u *rawp; +- +- rawp = (char_u *)GlobalLock(rawh); +- if (rawp != NULL && STRCMP(p_enc, rawp) == 0) +- { +- n = STRLEN(p_enc) + 1; +- str = rawp + n; +- str_size = (int)(metadata.rawlen - n); +- } +- else +- { +- GlobalUnlock(rawh); +- rawh = NULL; +- } +- } +- } +- if (str == NULL) +- { +- #endif +- +- #if defined(FEAT_MBYTE) && defined(WIN3264) +- /* Try to get the clipboard in Unicode if it's not an empty string. */ +- if (IsClipboardFormatAvailable(CF_UNICODETEXT) && metadata.ucslen != 0) +- { +- HGLOBAL hMemW; +- +- if ((hMemW = GetClipboardData(CF_UNICODETEXT)) != NULL) +- { +- WCHAR *hMemWstr = (WCHAR *)GlobalLock(hMemW); +- +- /* Use the length of our metadata if possible, but limit it to the +- * GlobalSize() for safety. */ +- maxlen = (int)(GlobalSize(hMemW) / sizeof(WCHAR)); +- if (metadata.ucslen >= 0) +- { +- if (metadata.ucslen > maxlen) +- str_size = maxlen; +- else +- str_size = metadata.ucslen; +- } +- else +- { +- for (str_size = 0; str_size < maxlen; ++str_size) +- if (hMemWstr[str_size] == NUL) +- break; +- } +- to_free = str = utf16_to_enc((short_u *)hMemWstr, &str_size); +- GlobalUnlock(hMemW); +- } +- } +- else +- #endif +- /* Get the clipboard in the Active codepage. */ +- if (IsClipboardFormatAvailable(CF_TEXT)) +- { +- if ((hMem = GetClipboardData(CF_TEXT)) != NULL) +- { +- str = (char_u *)GlobalLock(hMem); +- +- /* The length is either what our metadata says or the strlen(). +- * But limit it to the GlobalSize() for safety. */ +- maxlen = (int)GlobalSize(hMem); +- if (metadata.txtlen >= 0) +- { +- if (metadata.txtlen > maxlen) +- str_size = maxlen; +- else +- str_size = metadata.txtlen; +- } +- else +- { +- for (str_size = 0; str_size < maxlen; ++str_size) +- if (str[str_size] == NUL) +- break; +- } +- +- # if defined(FEAT_MBYTE) && defined(WIN3264) +- /* The text is in the active codepage. Convert to 'encoding', +- * going through UTF-16. */ +- acp_to_enc(str, str_size, &to_free, &maxlen); +- if (to_free != NULL) +- { +- str_size = maxlen; +- str = to_free; +- } +- # endif +- } +- } +- #ifdef FEAT_MBYTE +- } +- #endif +- +- if (str != NULL && *str != NUL) +- { +- char_u *temp_clipboard; +- +- /* If the type is not known detect it. */ +- if (metadata.type == -1) +- metadata.type = MAUTO; +- +- /* Translate into . */ +- temp_clipboard = crnl_to_nl(str, &str_size); +- if (temp_clipboard != NULL) +- { +- clip_yank_selection(metadata.type, temp_clipboard, str_size, cbd); +- vim_free(temp_clipboard); +- } +- } +- +- /* unlock the global object */ +- if (hMem != NULL) +- GlobalUnlock(hMem); +- #ifdef FEAT_MBYTE +- if (rawh != NULL) +- GlobalUnlock(rawh); +- #endif +- CloseClipboard(); +- #if defined(FEAT_MBYTE) && defined(WIN3264) +- vim_free(to_free); +- #endif +- } +- +- /* +- * Send the current selection to the clipboard. +- */ +- void +- clip_mch_set_selection(VimClipboard *cbd) +- { +- char_u *str = NULL; +- VimClipType_t metadata; +- long_u txtlen; +- HGLOBAL hMemRaw = NULL; +- HGLOBAL hMem = NULL; +- HGLOBAL hMemVim = NULL; +- # if defined(FEAT_MBYTE) && defined(WIN3264) +- HGLOBAL hMemW = NULL; +- # endif +- +- /* If the '*' register isn't already filled in, fill it in now */ +- cbd->owned = TRUE; +- clip_get_selection(cbd); +- cbd->owned = FALSE; +- +- /* Get the text to be put on the clipboard, with CR-LF. */ +- metadata.type = clip_convert_selection(&str, &txtlen, cbd); +- if (metadata.type < 0) +- return; +- metadata.txtlen = (int)txtlen; +- metadata.ucslen = 0; +- metadata.rawlen = 0; +- +- #ifdef FEAT_MBYTE +- /* Always set the raw bytes: 'encoding', NUL and the text. This is used +- * when copy/paste from/to Vim with the same 'encoding', so that illegal +- * bytes can also be copied and no conversion is needed. */ +- { +- LPSTR lpszMemRaw; +- +- metadata.rawlen = (int)(txtlen + STRLEN(p_enc) + 1); +- hMemRaw = (LPSTR)GlobalAlloc(GMEM_MOVEABLE | GMEM_DDESHARE, +- metadata.rawlen + 1); +- lpszMemRaw = (LPSTR)GlobalLock(hMemRaw); +- if (lpszMemRaw != NULL) +- { +- STRCPY(lpszMemRaw, p_enc); +- memcpy(lpszMemRaw + STRLEN(p_enc) + 1, str, txtlen + 1); +- GlobalUnlock(hMemRaw); +- } +- else +- metadata.rawlen = 0; +- } +- #endif +- +- # if defined(FEAT_MBYTE) && defined(WIN3264) +- { +- WCHAR *out; +- int len = metadata.txtlen; +- +- /* Convert the text to UTF-16. This is put on the clipboard as +- * CF_UNICODETEXT. */ +- out = (WCHAR *)enc_to_utf16(str, &len); +- if (out != NULL) +- { +- WCHAR *lpszMemW; +- +- /* Convert the text for CF_TEXT to Active codepage. Otherwise it's +- * p_enc, which has no relation to the Active codepage. */ +- metadata.txtlen = WideCharToMultiByte(GetACP(), 0, out, len, +- NULL, 0, 0, 0); +- vim_free(str); +- str = (char_u *)alloc((unsigned)(metadata.txtlen == 0 ? 1 +- : metadata.txtlen)); +- if (str == NULL) +- { +- vim_free(out); +- return; /* out of memory */ +- } +- WideCharToMultiByte(GetACP(), 0, out, len, +- str, metadata.txtlen, 0, 0); +- +- /* Allocate memory for the UTF-16 text, add one NUL word to +- * terminate the string. */ +- hMemW = (LPSTR)GlobalAlloc(GMEM_MOVEABLE | GMEM_DDESHARE, +- (len + 1) * sizeof(WCHAR)); +- lpszMemW = (WCHAR *)GlobalLock(hMemW); +- if (lpszMemW != NULL) +- { +- memcpy(lpszMemW, out, len * sizeof(WCHAR)); +- lpszMemW[len] = NUL; +- GlobalUnlock(hMemW); +- } +- vim_free(out); +- metadata.ucslen = len; +- } +- } +- # endif +- +- /* Allocate memory for the text, add one NUL byte to terminate the string. +- */ +- hMem = GlobalAlloc(GMEM_MOVEABLE | GMEM_DDESHARE, metadata.txtlen + 1); +- { +- LPSTR lpszMem = (LPSTR)GlobalLock(hMem); +- +- if (lpszMem) +- { +- vim_strncpy(lpszMem, str, metadata.txtlen); +- GlobalUnlock(hMem); +- } +- } +- +- /* Set up metadata: */ +- { +- VimClipType_t *lpszMemVim = NULL; +- +- hMemVim = GlobalAlloc(GMEM_MOVEABLE|GMEM_DDESHARE, +- sizeof(VimClipType_t)); +- lpszMemVim = (VimClipType_t *)GlobalLock(hMemVim); +- memcpy(lpszMemVim, &metadata, sizeof(metadata)); +- GlobalUnlock(hMemVim); +- } +- +- /* +- * Open the clipboard, clear it and put our text on it. +- * Always set our Vim format. Put Unicode and plain text on it. +- * +- * Don't pass GetActiveWindow() as an argument to OpenClipboard() +- * because then we can't paste back into the same window for some +- * reason - webb. +- */ +- if (vim_open_clipboard()) +- { +- if (EmptyClipboard()) +- { +- SetClipboardData(cbd->format, hMemVim); +- hMemVim = 0; +- # if defined(FEAT_MBYTE) && defined(WIN3264) +- if (hMemW != NULL) +- { +- if (SetClipboardData(CF_UNICODETEXT, hMemW) != NULL) +- hMemW = NULL; +- } +- # endif +- /* Always use CF_TEXT. On Win98 Notepad won't obtain the +- * CF_UNICODETEXT text, only CF_TEXT. */ +- SetClipboardData(CF_TEXT, hMem); +- hMem = 0; +- } +- CloseClipboard(); +- } +- +- vim_free(str); +- /* Free any allocations we didn't give to the clipboard: */ +- if (hMemRaw) +- GlobalFree(hMemRaw); +- if (hMem) +- GlobalFree(hMem); +- # if defined(FEAT_MBYTE) && defined(WIN3264) +- if (hMemW) +- GlobalFree(hMemW); +- # endif +- if (hMemVim) +- GlobalFree(hMemVim); +- } +- +- #endif /* FEAT_CLIPBOARD */ +- +- #if defined(FEAT_MBYTE) || defined(PROTO) +- /* +- * Note: the following two functions are only guaranteed to work when using +- * valid MS-Windows codepages or when iconv() is available. +- */ +- +- /* +- * Convert "str" from 'encoding' to UTF-16. +- * Input in "str" with length "*lenp". When "lenp" is NULL, use strlen(). +- * Output is returned as an allocated string. "*lenp" is set to the length of +- * the result. A trailing NUL is always added. +- * Returns NULL when out of memory. +- */ +- short_u * +- enc_to_utf16(char_u *str, int *lenp) +- { +- vimconv_T conv; +- WCHAR *ret; +- char_u *allocbuf = NULL; +- int len_loc; +- int length; +- +- if (lenp == NULL) +- { +- len_loc = (int)STRLEN(str) + 1; +- lenp = &len_loc; +- } +- +- if (enc_codepage > 0) +- { +- /* We can do any CP### -> UTF-16 in one pass, and we can do it +- * without iconv() (convert_* may need iconv). */ +- MultiByteToWideChar_alloc(enc_codepage, 0, str, *lenp, &ret, &length); +- } +- else +- { +- /* Use "latin1" by default, we might be called before we have p_enc +- * set up. Convert to utf-8 first, works better with iconv(). Does +- * nothing if 'encoding' is "utf-8". */ +- conv.vc_type = CONV_NONE; +- if (convert_setup(&conv, p_enc ? p_enc : (char_u *)"latin1", +- (char_u *)"utf-8") == FAIL) +- return NULL; +- if (conv.vc_type != CONV_NONE) +- { +- str = allocbuf = string_convert(&conv, str, lenp); +- if (str == NULL) +- return NULL; +- } +- convert_setup(&conv, NULL, NULL); +- +- length = utf8_to_utf16(str, *lenp, NULL, NULL); +- ret = (WCHAR *)alloc((unsigned)((length + 1) * sizeof(WCHAR))); +- if (ret != NULL) +- { +- utf8_to_utf16(str, *lenp, (short_u *)ret, NULL); +- ret[length] = 0; +- } +- +- vim_free(allocbuf); +- } +- +- *lenp = length; +- return (short_u *)ret; +- } +- +- /* +- * Convert an UTF-16 string to 'encoding'. +- * Input in "str" with length (counted in wide characters) "*lenp". When +- * "lenp" is NULL, use wcslen(). +- * Output is returned as an allocated string. If "*lenp" is not NULL it is +- * set to the length of the result. +- * Returns NULL when out of memory. +- */ +- char_u * +- utf16_to_enc(short_u *str, int *lenp) +- { +- vimconv_T conv; +- char_u *utf8_str = NULL, *enc_str = NULL; +- int len_loc; +- +- if (lenp == NULL) +- { +- len_loc = (int)wcslen(str) + 1; +- lenp = &len_loc; +- } +- +- if (enc_codepage > 0) +- { +- /* We can do any UTF-16 -> CP### in one pass. */ +- int length; +- +- WideCharToMultiByte_alloc(enc_codepage, 0, str, *lenp, +- (LPSTR *)&enc_str, &length, 0, 0); +- *lenp = length; +- return enc_str; +- } +- +- /* Avoid allocating zero bytes, it generates an error message. */ +- utf8_str = alloc(utf16_to_utf8(str, *lenp == 0 ? 1 : *lenp, NULL)); +- if (utf8_str != NULL) +- { +- *lenp = utf16_to_utf8(str, *lenp, utf8_str); +- +- /* We might be called before we have p_enc set up. */ +- conv.vc_type = CONV_NONE; +- convert_setup(&conv, (char_u *)"utf-8", +- p_enc? p_enc: (char_u *)"latin1"); +- if (conv.vc_type == CONV_NONE) +- { +- /* p_enc is utf-8, so we're done. */ +- enc_str = utf8_str; +- } +- else +- { +- enc_str = string_convert(&conv, utf8_str, lenp); +- vim_free(utf8_str); +- } +- +- convert_setup(&conv, NULL, NULL); +- } +- +- return enc_str; +- } +- #endif /* FEAT_MBYTE */ +- +- #if (defined(FEAT_MBYTE) && defined(WIN3264)) || defined(PROTO) +- /* +- * Convert from the active codepage to 'encoding'. +- * Input is "str[str_size]". +- * The result is in allocated memory: "out[outlen]". With terminating NUL. +- */ +- void +- acp_to_enc(str, str_size, out, outlen) +- char_u *str; +- int str_size; +- char_u **out; +- int *outlen; +- +- { +- LPWSTR widestr; +- +- MultiByteToWideChar_alloc(GetACP(), 0, str, str_size, &widestr, outlen); +- if (widestr != NULL) +- { +- ++*outlen; /* Include the 0 after the string */ +- *out = utf16_to_enc((short_u *)widestr, outlen); +- vim_free(widestr); +- } +- } +- #endif +- +- + /* + * Debugging helper: expose the MCH_WRITE_DUMP stuff to other modules + */ +--- 905,910 ---- +*** ../vim-7.3.835/src/os_unix.c 2013-01-30 14:55:35.000000000 +0100 +--- src/os_unix.c 2013-02-26 14:31:32.000000000 +0100 +*************** +*** 61,66 **** +--- 61,71 ---- + # include + # include /* for cygwin_conv_to_posix_path() and/or + * for cygwin_conv_path() */ ++ # ifdef FEAT_CYGWIN_WIN32_CLIPBOARD ++ # define WIN32_LEAN_AND_MEAN ++ # include ++ # include "winclip.pro" ++ # endif + # endif + #endif + +*************** +*** 1223,1228 **** +--- 1228,1236 ---- + #ifdef MACOS_CONVERT + mac_conv_init(); + #endif ++ #ifdef FEAT_CYGWIN_WIN32_CLIPBOARD ++ win_clip_init(); ++ #endif + } + + static void +*** ../vim-7.3.835/src/os_win32.c 2013-02-13 16:49:54.000000000 +0100 +--- src/os_win32.c 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 1851,1866 **** + set_option_value((char_u *)"grepprg", 0, (char_u *)"grep -n", 0); + + #ifdef FEAT_CLIPBOARD +! clip_init(TRUE); +! +! /* +! * Vim's own clipboard format recognises whether the text is char, line, +! * or rectangular block. Only useful for copying between two Vims. +! * "VimClipboard" was used for previous versions, using the first +! * character to specify MCHAR, MLINE or MBLOCK. +! */ +! clip_star.format = RegisterClipboardFormat("VimClipboard2"); +! clip_star.format_raw = RegisterClipboardFormat("VimRawBytes"); + #endif + } + +--- 1851,1857 ---- + set_option_value((char_u *)"grepprg", 0, (char_u *)"grep -n", 0); + + #ifdef FEAT_CLIPBOARD +! win_clip_init(); + #endif + } + +*************** +*** 2345,2360 **** + #endif + + #ifdef FEAT_CLIPBOARD +! clip_init(TRUE); +! +! /* +! * Vim's own clipboard format recognises whether the text is char, line, or +! * rectangular block. Only useful for copying between two Vims. +! * "VimClipboard" was used for previous versions, using the first +! * character to specify MCHAR, MLINE or MBLOCK. +! */ +! clip_star.format = RegisterClipboardFormat("VimClipboard2"); +! clip_star.format_raw = RegisterClipboardFormat("VimRawBytes"); + #endif + + /* This will be NULL on anything but NT 4.0 */ +--- 2336,2342 ---- + #endif + + #ifdef FEAT_CLIPBOARD +! win_clip_init(); + #endif + + /* This will be NULL on anything but NT 4.0 */ +*** ../vim-7.3.835/src/proto.h 2011-05-10 16:41:13.000000000 +0200 +--- src/proto.h 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 47,56 **** +--- 47,58 ---- + typedef int LPBOOL; + # include "os_win16.pro" + # include "os_mswin.pro" ++ # include "winclip.pro" + # endif + # ifdef WIN3264 + # include "os_win32.pro" + # include "os_mswin.pro" ++ # include "winclip.pro" + # if (defined(__GNUC__) && !defined(__MINGW32__)) \ + || (defined(__BORLANDC__) && __BORLANDC__ < 0x502) + extern int _stricoll __ARGS((char *a, char *b)); +*** ../vim-7.3.835/src/proto/os_mswin.pro 2012-11-20 16:56:49.000000000 +0100 +--- src/proto/os_mswin.pro 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 22,38 **** + int can_end_termcap_mode __ARGS((int give_msg)); + int mch_screenmode __ARGS((char_u *arg)); + int mch_libcall __ARGS((char_u *libname, char_u *funcname, char_u *argstring, int argint, char_u **string_result, int *number_result)); +- int utf8_to_utf16 __ARGS((char_u *instr, int inlen, short_u *outstr, int *unconvlenp)); +- int utf16_to_utf8 __ARGS((short_u *instr, int inlen, char_u *outstr)); +- void MultiByteToWideChar_alloc __ARGS((UINT cp, DWORD flags, LPCSTR in, int inlen, LPWSTR *out, int *outlen)); +- void WideCharToMultiByte_alloc __ARGS((UINT cp, DWORD flags, LPCWSTR in, int inlen, LPSTR *out, int *outlen, LPCSTR def, LPBOOL useddef)); +- int clip_mch_own_selection __ARGS((VimClipboard *cbd)); +- void clip_mch_lose_selection __ARGS((VimClipboard *cbd)); +- void clip_mch_request_selection __ARGS((VimClipboard *cbd)); +- void clip_mch_set_selection __ARGS((VimClipboard *cbd)); +- short_u *enc_to_utf16 __ARGS((char_u *str, int *lenp)); +- char_u *utf16_to_enc __ARGS((short_u *str, int *lenp)); +- void acp_to_enc __ARGS((char_u *str, int str_size, char_u **out, int *outlen)); + void DumpPutS __ARGS((const char *psz)); + int mch_get_winpos __ARGS((int *x, int *y)); + void mch_set_winpos __ARGS((int x, int y)); +--- 22,27 ---- +*** ../vim-7.3.835/src/proto/winclip.pro 2013-02-26 14:55:20.000000000 +0100 +--- src/proto/winclip.pro 2013-02-26 14:32:52.000000000 +0100 +*************** +*** 0 **** +--- 1,14 ---- ++ /* winclip.c */ ++ int utf8_to_utf16 __ARGS((char_u *instr, int inlen, short_u *outstr, int *unconvlenp)); ++ int utf16_to_utf8 __ARGS((short_u *instr, int inlen, char_u *outstr)); ++ void MultiByteToWideChar_alloc __ARGS((UINT cp, DWORD flags, LPCSTR in, int inlen, LPWSTR *out, int *outlen)); ++ void WideCharToMultiByte_alloc __ARGS((UINT cp, DWORD flags, LPCWSTR in, int inlen, LPSTR *out, int *outlen, LPCSTR def, LPBOOL useddef)); ++ void win_clip_init __ARGS((void)); ++ int clip_mch_own_selection __ARGS((VimClipboard *cbd)); ++ void clip_mch_lose_selection __ARGS((VimClipboard *cbd)); ++ void clip_mch_request_selection __ARGS((VimClipboard *cbd)); ++ void clip_mch_set_selection __ARGS((VimClipboard *cbd)); ++ short_u *enc_to_utf16 __ARGS((char_u *str, int *lenp)); ++ char_u *utf16_to_enc __ARGS((short_u *str, int *lenp)); ++ void acp_to_enc __ARGS((char_u *str, int str_size, char_u **out, int *outlen)); ++ /* vim: set ft=c : */ +*** ../vim-7.3.835/src/term.c 2013-02-13 15:53:15.000000000 +0100 +--- src/term.c 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 1853,1859 **** +--- 1853,1861 ---- + # ifdef FEAT_GUI + if (!gui.in_use) + # endif ++ # ifndef FEAT_CYGWIN_WIN32_CLIPBOARD + clip_init(FALSE); ++ # endif + # endif + if (use_xterm_like_mouse(term)) + { +*** ../vim-7.3.835/src/vim.h 2013-01-17 17:17:21.000000000 +0100 +--- src/vim.h 2013-02-26 14:18:19.000000000 +0100 +*************** +*** 1927,1933 **** + GdkAtom gtk_sel_atom; /* PRIMARY/CLIPBOARD selection ID */ + # endif + +! # ifdef MSWIN + int_u format; /* Vim's own special clipboard format */ + int_u format_raw; /* Vim's raw text clipboard format */ + # endif +--- 1927,1933 ---- + GdkAtom gtk_sel_atom; /* PRIMARY/CLIPBOARD selection ID */ + # endif + +! # if defined(MSWIN) || defined(FEAT_CYGWIN_WIN32_CLIPBOARD) + int_u format; /* Vim's own special clipboard format */ + int_u format_raw; /* Vim's raw text clipboard format */ + # endif +*** ../vim-7.3.835/src/winclip.c 2013-02-26 14:55:20.000000000 +0100 +--- src/winclip.c 2013-02-26 14:32:42.000000000 +0100 +*************** +*** 0 **** +--- 1,798 ---- ++ /* vi:set ts=8 sts=4 sw=4: ++ * ++ * VIM - Vi IMproved by Bram Moolenaar ++ * ++ * Do ":help uganda" in Vim to read copying and usage conditions. ++ * Do ":help credits" in Vim to see a list of people who contributed. ++ * See README.txt for an overview of the Vim source code. ++ */ ++ ++ /* ++ * winclip.c ++ * ++ * Routines common to both Win16 and Win32 for clipboard handling. ++ * Also used by Cygwin, using os_unix.c. ++ */ ++ ++ #ifdef WIN16 ++ # ifdef __BORLANDC__ ++ # pragma warn -par ++ # pragma warn -ucp ++ # pragma warn -use ++ # pragma warn -aus ++ # endif ++ #endif ++ ++ #include "vimio.h" ++ #include "vim.h" ++ ++ /* ++ * Compile only the clipboard handling features when compiling for cygwin ++ * posix environment. ++ */ ++ #ifdef FEAT_CYGWIN_WIN32_CLIPBOARD ++ # define WIN3264 ++ # define WIN32_LEAN_AND_MEAN ++ # include ++ # include "winclip.pro" ++ #endif ++ ++ /* ++ * When generating prototypes for Win32 on Unix, these lines make the syntax ++ * errors disappear. They do not need to be correct. ++ */ ++ #ifdef PROTO ++ #define WINAPI ++ #define WINBASEAPI ++ typedef int DWORD; ++ typedef int LPBOOL; ++ typedef int LPCSTR; ++ typedef int LPCWSTR; ++ typedef int LPSTR; ++ typedef int LPWSTR; ++ typedef int UINT; ++ #endif ++ ++ #if defined(FEAT_MBYTE) || defined(PROTO) ++ /* ++ * Convert an UTF-8 string to UTF-16. ++ * "instr[inlen]" is the input. "inlen" is in bytes. ++ * When "outstr" is NULL only return the number of UTF-16 words produced. ++ * Otherwise "outstr" must be a buffer of sufficient size. ++ * Returns the number of UTF-16 words produced. ++ */ ++ int ++ utf8_to_utf16(char_u *instr, int inlen, short_u *outstr, int *unconvlenp) ++ { ++ int outlen = 0; ++ char_u *p = instr; ++ int todo = inlen; ++ int l; ++ int ch; ++ ++ while (todo > 0) ++ { ++ /* Only convert if we have a complete sequence. */ ++ l = utf_ptr2len_len(p, todo); ++ if (l > todo) ++ { ++ /* Return length of incomplete sequence. */ ++ if (unconvlenp != NULL) ++ *unconvlenp = todo; ++ break; ++ } ++ ++ ch = utf_ptr2char(p); ++ if (ch >= 0x10000) ++ { ++ /* non-BMP character, encoding with surrogate pairs */ ++ ++outlen; ++ if (outstr != NULL) ++ { ++ *outstr++ = (0xD800 - (0x10000 >> 10)) + (ch >> 10); ++ *outstr++ = 0xDC00 | (ch & 0x3FF); ++ } ++ } ++ else if (outstr != NULL) ++ *outstr++ = ch; ++ ++outlen; ++ p += l; ++ todo -= l; ++ } ++ ++ return outlen; ++ } ++ ++ /* ++ * Convert an UTF-16 string to UTF-8. ++ * The input is "instr[inlen]" with "inlen" in number of UTF-16 words. ++ * When "outstr" is NULL only return the required number of bytes. ++ * Otherwise "outstr" must be a buffer of sufficient size. ++ * Return the number of bytes produced. ++ */ ++ int ++ utf16_to_utf8(short_u *instr, int inlen, char_u *outstr) ++ { ++ int outlen = 0; ++ int todo = inlen; ++ short_u *p = instr; ++ int l; ++ int ch, ch2; ++ ++ while (todo > 0) ++ { ++ ch = *p; ++ if (ch >= 0xD800 && ch <= 0xDBFF && todo > 1) ++ { ++ /* surrogate pairs handling */ ++ ch2 = p[1]; ++ if (ch2 >= 0xDC00 && ch2 <= 0xDFFF) ++ { ++ ch = ((ch - 0xD800) << 10) + (ch2 & 0x3FF) + 0x10000; ++ ++p; ++ --todo; ++ } ++ } ++ if (outstr != NULL) ++ { ++ l = utf_char2bytes(ch, outstr); ++ outstr += l; ++ } ++ else ++ l = utf_char2len(ch); ++ ++p; ++ outlen += l; ++ --todo; ++ } ++ ++ return outlen; ++ } ++ ++ /* ++ * Call MultiByteToWideChar() and allocate memory for the result. ++ * Returns the result in "*out[*outlen]" with an extra zero appended. ++ * "outlen" is in words. ++ */ ++ void ++ MultiByteToWideChar_alloc(UINT cp, DWORD flags, ++ LPCSTR in, int inlen, ++ LPWSTR *out, int *outlen) ++ { ++ *outlen = MultiByteToWideChar(cp, flags, in, inlen, 0, 0); ++ /* Add one one word to avoid a zero-length alloc(). */ ++ *out = (LPWSTR)alloc(sizeof(WCHAR) * (*outlen + 1)); ++ if (*out != NULL) ++ { ++ MultiByteToWideChar(cp, flags, in, inlen, *out, *outlen); ++ (*out)[*outlen] = 0; ++ } ++ } ++ ++ /* ++ * Call WideCharToMultiByte() and allocate memory for the result. ++ * Returns the result in "*out[*outlen]" with an extra NUL appended. ++ */ ++ void ++ WideCharToMultiByte_alloc(UINT cp, DWORD flags, ++ LPCWSTR in, int inlen, ++ LPSTR *out, int *outlen, ++ LPCSTR def, LPBOOL useddef) ++ { ++ *outlen = WideCharToMultiByte(cp, flags, in, inlen, NULL, 0, def, useddef); ++ /* Add one one byte to avoid a zero-length alloc(). */ ++ *out = alloc((unsigned)*outlen + 1); ++ if (*out != NULL) ++ { ++ WideCharToMultiByte(cp, flags, in, inlen, *out, *outlen, def, useddef); ++ (*out)[*outlen] = 0; ++ } ++ } ++ ++ #endif /* FEAT_MBYTE */ ++ ++ #ifdef FEAT_CLIPBOARD ++ /* ++ * Clipboard stuff, for cutting and pasting text to other windows. ++ */ ++ ++ void ++ win_clip_init(void) ++ { ++ clip_init(TRUE); ++ ++ /* ++ * Vim's own clipboard format recognises whether the text is char, line, ++ * or rectangular block. Only useful for copying between two Vims. ++ * "VimClipboard" was used for previous versions, using the first ++ * character to specify MCHAR, MLINE or MBLOCK. ++ */ ++ clip_star.format = RegisterClipboardFormat("VimClipboard2"); ++ clip_star.format_raw = RegisterClipboardFormat("VimRawBytes"); ++ } ++ ++ /* Type used for the clipboard type of Vim's data. */ ++ typedef struct ++ { ++ int type; /* MCHAR, MBLOCK or MLINE */ ++ int txtlen; /* length of CF_TEXT in bytes */ ++ int ucslen; /* length of CF_UNICODETEXT in words */ ++ int rawlen; /* length of clip_star.format_raw, including encoding, ++ excluding terminating NUL */ ++ } VimClipType_t; ++ ++ /* ++ * Make vim the owner of the current selection. Return OK upon success. ++ */ ++ /*ARGSUSED*/ ++ int ++ clip_mch_own_selection(VimClipboard *cbd) ++ { ++ /* ++ * Never actually own the clipboard. If another application sets the ++ * clipboard, we don't want to think that we still own it. ++ */ ++ return FAIL; ++ } ++ ++ /* ++ * Make vim NOT the owner of the current selection. ++ */ ++ /*ARGSUSED*/ ++ void ++ clip_mch_lose_selection(VimClipboard *cbd) ++ { ++ /* Nothing needs to be done here */ ++ } ++ ++ /* ++ * Copy "str[*size]" into allocated memory, changing CR-NL to NL. ++ * Return the allocated result and the size in "*size". ++ * Returns NULL when out of memory. ++ */ ++ static char_u * ++ crnl_to_nl(const char_u *str, int *size) ++ { ++ int pos = 0; ++ int str_len = *size; ++ char_u *ret; ++ char_u *retp; ++ ++ /* Avoid allocating zero bytes, it generates an error message. */ ++ ret = lalloc((long_u)(str_len == 0 ? 1 : str_len), TRUE); ++ if (ret != NULL) ++ { ++ retp = ret; ++ for (pos = 0; pos < str_len; ++pos) ++ { ++ if (str[pos] == '\r' && str[pos + 1] == '\n') ++ { ++ ++pos; ++ --(*size); ++ } ++ *retp++ = str[pos]; ++ } ++ } ++ ++ return ret; ++ } ++ ++ /* ++ * Wait for another process to Close the Clipboard. ++ * Returns TRUE for success. ++ */ ++ static int ++ vim_open_clipboard(void) ++ { ++ int delay = 10; ++ ++ while (!OpenClipboard(NULL)) ++ { ++ if (delay > 500) ++ return FALSE; /* waited too long, give up */ ++ Sleep(delay); ++ delay *= 2; /* wait for 10, 20, 40, 80, etc. msec */ ++ } ++ return TRUE; ++ } ++ ++ /* ++ * Get the current selection and put it in the clipboard register. ++ * ++ * NOTE: Must use GlobalLock/Unlock here to ensure Win32s compatibility. ++ * On NT/W95 the clipboard data is a fixed global memory object and ++ * so its handle = its pointer. ++ * On Win32s, however, co-operation with the Win16 system means that ++ * the clipboard data is moveable and its handle is not a pointer at all, ++ * so we can't just cast the return value of GetClipboardData to (char_u*). ++ * ++ */ ++ void ++ clip_mch_request_selection(VimClipboard *cbd) ++ { ++ VimClipType_t metadata = { -1, -1, -1, -1 }; ++ HGLOBAL hMem = NULL; ++ char_u *str = NULL; ++ #if defined(FEAT_MBYTE) && defined(WIN3264) ++ char_u *to_free = NULL; ++ #endif ++ #ifdef FEAT_MBYTE ++ HGLOBAL rawh = NULL; ++ #endif ++ int str_size = 0; ++ int maxlen; ++ size_t n; ++ ++ /* ++ * Don't pass GetActiveWindow() as an argument to OpenClipboard() because ++ * then we can't paste back into the same window for some reason - webb. ++ */ ++ if (!vim_open_clipboard()) ++ return; ++ ++ /* Check for vim's own clipboard format first. This only gets the type of ++ * the data, still need to use CF_UNICODETEXT or CF_TEXT for the text. */ ++ if (IsClipboardFormatAvailable(cbd->format)) ++ { ++ VimClipType_t *meta_p; ++ HGLOBAL meta_h; ++ ++ /* We have metadata on the clipboard; try to get it. */ ++ if ((meta_h = GetClipboardData(cbd->format)) != NULL ++ && (meta_p = (VimClipType_t *)GlobalLock(meta_h)) != NULL) ++ { ++ /* The size of "VimClipType_t" changed, "rawlen" was added later. ++ * Only copy what is available for backwards compatibility. */ ++ n = sizeof(VimClipType_t); ++ if (GlobalSize(meta_h) < n) ++ n = GlobalSize(meta_h); ++ memcpy(&metadata, meta_p, n); ++ GlobalUnlock(meta_h); ++ } ++ } ++ ++ #ifdef FEAT_MBYTE ++ /* Check for Vim's raw clipboard format first. This is used without ++ * conversion, but only if 'encoding' matches. */ ++ if (IsClipboardFormatAvailable(cbd->format_raw) ++ && metadata.rawlen > (int)STRLEN(p_enc)) ++ { ++ /* We have raw data on the clipboard; try to get it. */ ++ if ((rawh = GetClipboardData(cbd->format_raw)) != NULL) ++ { ++ char_u *rawp; ++ ++ rawp = (char_u *)GlobalLock(rawh); ++ if (rawp != NULL && STRCMP(p_enc, rawp) == 0) ++ { ++ n = STRLEN(p_enc) + 1; ++ str = rawp + n; ++ str_size = (int)(metadata.rawlen - n); ++ } ++ else ++ { ++ GlobalUnlock(rawh); ++ rawh = NULL; ++ } ++ } ++ } ++ if (str == NULL) ++ { ++ #endif ++ ++ #if defined(FEAT_MBYTE) && defined(WIN3264) ++ /* Try to get the clipboard in Unicode if it's not an empty string. */ ++ if (IsClipboardFormatAvailable(CF_UNICODETEXT) && metadata.ucslen != 0) ++ { ++ HGLOBAL hMemW; ++ ++ if ((hMemW = GetClipboardData(CF_UNICODETEXT)) != NULL) ++ { ++ WCHAR *hMemWstr = (WCHAR *)GlobalLock(hMemW); ++ ++ /* Use the length of our metadata if possible, but limit it to the ++ * GlobalSize() for safety. */ ++ maxlen = (int)(GlobalSize(hMemW) / sizeof(WCHAR)); ++ if (metadata.ucslen >= 0) ++ { ++ if (metadata.ucslen > maxlen) ++ str_size = maxlen; ++ else ++ str_size = metadata.ucslen; ++ } ++ else ++ { ++ for (str_size = 0; str_size < maxlen; ++str_size) ++ if (hMemWstr[str_size] == NUL) ++ break; ++ } ++ to_free = str = utf16_to_enc((short_u *)hMemWstr, &str_size); ++ GlobalUnlock(hMemW); ++ } ++ } ++ else ++ #endif ++ /* Get the clipboard in the Active codepage. */ ++ if (IsClipboardFormatAvailable(CF_TEXT)) ++ { ++ if ((hMem = GetClipboardData(CF_TEXT)) != NULL) ++ { ++ str = (char_u *)GlobalLock(hMem); ++ ++ /* The length is either what our metadata says or the strlen(). ++ * But limit it to the GlobalSize() for safety. */ ++ maxlen = (int)GlobalSize(hMem); ++ if (metadata.txtlen >= 0) ++ { ++ if (metadata.txtlen > maxlen) ++ str_size = maxlen; ++ else ++ str_size = metadata.txtlen; ++ } ++ else ++ { ++ for (str_size = 0; str_size < maxlen; ++str_size) ++ if (str[str_size] == NUL) ++ break; ++ } ++ ++ # if defined(FEAT_MBYTE) && defined(WIN3264) ++ /* The text is in the active codepage. Convert to 'encoding', ++ * going through UTF-16. */ ++ acp_to_enc(str, str_size, &to_free, &maxlen); ++ if (to_free != NULL) ++ { ++ str_size = maxlen; ++ str = to_free; ++ } ++ # endif ++ } ++ } ++ #ifdef FEAT_MBYTE ++ } ++ #endif ++ ++ if (str != NULL && *str != NUL) ++ { ++ char_u *temp_clipboard; ++ ++ /* If the type is not known detect it. */ ++ if (metadata.type == -1) ++ metadata.type = MAUTO; ++ ++ /* Translate into . */ ++ temp_clipboard = crnl_to_nl(str, &str_size); ++ if (temp_clipboard != NULL) ++ { ++ clip_yank_selection(metadata.type, temp_clipboard, str_size, cbd); ++ vim_free(temp_clipboard); ++ } ++ } ++ ++ /* unlock the global object */ ++ if (hMem != NULL) ++ GlobalUnlock(hMem); ++ #ifdef FEAT_MBYTE ++ if (rawh != NULL) ++ GlobalUnlock(rawh); ++ #endif ++ CloseClipboard(); ++ #if defined(FEAT_MBYTE) && defined(WIN3264) ++ vim_free(to_free); ++ #endif ++ } ++ ++ /* ++ * Send the current selection to the clipboard. ++ */ ++ void ++ clip_mch_set_selection(VimClipboard *cbd) ++ { ++ char_u *str = NULL; ++ VimClipType_t metadata; ++ long_u txtlen; ++ HGLOBAL hMemRaw = NULL; ++ HGLOBAL hMem = NULL; ++ HGLOBAL hMemVim = NULL; ++ # if defined(FEAT_MBYTE) && defined(WIN3264) ++ HGLOBAL hMemW = NULL; ++ # endif ++ ++ /* If the '*' register isn't already filled in, fill it in now */ ++ cbd->owned = TRUE; ++ clip_get_selection(cbd); ++ cbd->owned = FALSE; ++ ++ /* Get the text to be put on the clipboard, with CR-LF. */ ++ metadata.type = clip_convert_selection(&str, &txtlen, cbd); ++ if (metadata.type < 0) ++ return; ++ metadata.txtlen = (int)txtlen; ++ metadata.ucslen = 0; ++ metadata.rawlen = 0; ++ ++ #ifdef FEAT_MBYTE ++ /* Always set the raw bytes: 'encoding', NUL and the text. This is used ++ * when copy/paste from/to Vim with the same 'encoding', so that illegal ++ * bytes can also be copied and no conversion is needed. */ ++ { ++ LPSTR lpszMemRaw; ++ ++ metadata.rawlen = (int)(txtlen + STRLEN(p_enc) + 1); ++ hMemRaw = (LPSTR)GlobalAlloc(GMEM_MOVEABLE | GMEM_DDESHARE, ++ metadata.rawlen + 1); ++ lpszMemRaw = (LPSTR)GlobalLock(hMemRaw); ++ if (lpszMemRaw != NULL) ++ { ++ STRCPY(lpszMemRaw, p_enc); ++ memcpy(lpszMemRaw + STRLEN(p_enc) + 1, str, txtlen + 1); ++ GlobalUnlock(hMemRaw); ++ } ++ else ++ metadata.rawlen = 0; ++ } ++ #endif ++ ++ # if defined(FEAT_MBYTE) && defined(WIN3264) ++ { ++ WCHAR *out; ++ int len = metadata.txtlen; ++ ++ /* Convert the text to UTF-16. This is put on the clipboard as ++ * CF_UNICODETEXT. */ ++ out = (WCHAR *)enc_to_utf16(str, &len); ++ if (out != NULL) ++ { ++ WCHAR *lpszMemW; ++ ++ /* Convert the text for CF_TEXT to Active codepage. Otherwise it's ++ * p_enc, which has no relation to the Active codepage. */ ++ metadata.txtlen = WideCharToMultiByte(GetACP(), 0, out, len, ++ NULL, 0, 0, 0); ++ vim_free(str); ++ str = (char_u *)alloc((unsigned)(metadata.txtlen == 0 ? 1 ++ : metadata.txtlen)); ++ if (str == NULL) ++ { ++ vim_free(out); ++ return; /* out of memory */ ++ } ++ WideCharToMultiByte(GetACP(), 0, out, len, ++ str, metadata.txtlen, 0, 0); ++ ++ /* Allocate memory for the UTF-16 text, add one NUL word to ++ * terminate the string. */ ++ hMemW = (LPSTR)GlobalAlloc(GMEM_MOVEABLE | GMEM_DDESHARE, ++ (len + 1) * sizeof(WCHAR)); ++ lpszMemW = (WCHAR *)GlobalLock(hMemW); ++ if (lpszMemW != NULL) ++ { ++ memcpy(lpszMemW, out, len * sizeof(WCHAR)); ++ lpszMemW[len] = NUL; ++ GlobalUnlock(hMemW); ++ } ++ vim_free(out); ++ metadata.ucslen = len; ++ } ++ } ++ # endif ++ ++ /* Allocate memory for the text, add one NUL byte to terminate the string. ++ */ ++ hMem = GlobalAlloc(GMEM_MOVEABLE | GMEM_DDESHARE, metadata.txtlen + 1); ++ { ++ LPSTR lpszMem = (LPSTR)GlobalLock(hMem); ++ ++ if (lpszMem) ++ { ++ vim_strncpy(lpszMem, str, metadata.txtlen); ++ GlobalUnlock(hMem); ++ } ++ } ++ ++ /* Set up metadata: */ ++ { ++ VimClipType_t *lpszMemVim = NULL; ++ ++ hMemVim = GlobalAlloc(GMEM_MOVEABLE|GMEM_DDESHARE, ++ sizeof(VimClipType_t)); ++ lpszMemVim = (VimClipType_t *)GlobalLock(hMemVim); ++ memcpy(lpszMemVim, &metadata, sizeof(metadata)); ++ GlobalUnlock(hMemVim); ++ } ++ ++ /* ++ * Open the clipboard, clear it and put our text on it. ++ * Always set our Vim format. Put Unicode and plain text on it. ++ * ++ * Don't pass GetActiveWindow() as an argument to OpenClipboard() ++ * because then we can't paste back into the same window for some ++ * reason - webb. ++ */ ++ if (vim_open_clipboard()) ++ { ++ if (EmptyClipboard()) ++ { ++ SetClipboardData(cbd->format, hMemVim); ++ hMemVim = 0; ++ # if defined(FEAT_MBYTE) && defined(WIN3264) ++ if (hMemW != NULL) ++ { ++ if (SetClipboardData(CF_UNICODETEXT, hMemW) != NULL) ++ hMemW = NULL; ++ } ++ # endif ++ /* Always use CF_TEXT. On Win98 Notepad won't obtain the ++ * CF_UNICODETEXT text, only CF_TEXT. */ ++ SetClipboardData(CF_TEXT, hMem); ++ hMem = 0; ++ } ++ CloseClipboard(); ++ } ++ ++ vim_free(str); ++ /* Free any allocations we didn't give to the clipboard: */ ++ if (hMemRaw) ++ GlobalFree(hMemRaw); ++ if (hMem) ++ GlobalFree(hMem); ++ # if defined(FEAT_MBYTE) && defined(WIN3264) ++ if (hMemW) ++ GlobalFree(hMemW); ++ # endif ++ if (hMemVim) ++ GlobalFree(hMemVim); ++ } ++ ++ #endif /* FEAT_CLIPBOARD */ ++ ++ #if defined(FEAT_MBYTE) || defined(PROTO) ++ /* ++ * Note: the following two functions are only guaranteed to work when using ++ * valid MS-Windows codepages or when iconv() is available. ++ */ ++ ++ /* ++ * Convert "str" from 'encoding' to UTF-16. ++ * Input in "str" with length "*lenp". When "lenp" is NULL, use strlen(). ++ * Output is returned as an allocated string. "*lenp" is set to the length of ++ * the result. A trailing NUL is always added. ++ * Returns NULL when out of memory. ++ */ ++ short_u * ++ enc_to_utf16(char_u *str, int *lenp) ++ { ++ vimconv_T conv; ++ WCHAR *ret; ++ char_u *allocbuf = NULL; ++ int len_loc; ++ int length; ++ ++ if (lenp == NULL) ++ { ++ len_loc = (int)STRLEN(str) + 1; ++ lenp = &len_loc; ++ } ++ ++ if (enc_codepage > 0) ++ { ++ /* We can do any CP### -> UTF-16 in one pass, and we can do it ++ * without iconv() (convert_* may need iconv). */ ++ MultiByteToWideChar_alloc(enc_codepage, 0, str, *lenp, &ret, &length); ++ } ++ else ++ { ++ /* Use "latin1" by default, we might be called before we have p_enc ++ * set up. Convert to utf-8 first, works better with iconv(). Does ++ * nothing if 'encoding' is "utf-8". */ ++ conv.vc_type = CONV_NONE; ++ if (convert_setup(&conv, p_enc ? p_enc : (char_u *)"latin1", ++ (char_u *)"utf-8") == FAIL) ++ return NULL; ++ if (conv.vc_type != CONV_NONE) ++ { ++ str = allocbuf = string_convert(&conv, str, lenp); ++ if (str == NULL) ++ return NULL; ++ } ++ convert_setup(&conv, NULL, NULL); ++ ++ length = utf8_to_utf16(str, *lenp, NULL, NULL); ++ ret = (WCHAR *)alloc((unsigned)((length + 1) * sizeof(WCHAR))); ++ if (ret != NULL) ++ { ++ utf8_to_utf16(str, *lenp, (short_u *)ret, NULL); ++ ret[length] = 0; ++ } ++ ++ vim_free(allocbuf); ++ } ++ ++ *lenp = length; ++ return (short_u *)ret; ++ } ++ ++ /* ++ * Convert an UTF-16 string to 'encoding'. ++ * Input in "str" with length (counted in wide characters) "*lenp". When ++ * "lenp" is NULL, use wcslen(). ++ * Output is returned as an allocated string. If "*lenp" is not NULL it is ++ * set to the length of the result. ++ * Returns NULL when out of memory. ++ */ ++ char_u * ++ utf16_to_enc(short_u *str, int *lenp) ++ { ++ vimconv_T conv; ++ char_u *utf8_str = NULL, *enc_str = NULL; ++ int len_loc; ++ ++ if (lenp == NULL) ++ { ++ len_loc = (int)wcslen(str) + 1; ++ lenp = &len_loc; ++ } ++ ++ if (enc_codepage > 0) ++ { ++ /* We can do any UTF-16 -> CP### in one pass. */ ++ int length; ++ ++ WideCharToMultiByte_alloc(enc_codepage, 0, str, *lenp, ++ (LPSTR *)&enc_str, &length, 0, 0); ++ *lenp = length; ++ return enc_str; ++ } ++ ++ /* Avoid allocating zero bytes, it generates an error message. */ ++ utf8_str = alloc(utf16_to_utf8(str, *lenp == 0 ? 1 : *lenp, NULL)); ++ if (utf8_str != NULL) ++ { ++ *lenp = utf16_to_utf8(str, *lenp, utf8_str); ++ ++ /* We might be called before we have p_enc set up. */ ++ conv.vc_type = CONV_NONE; ++ convert_setup(&conv, (char_u *)"utf-8", ++ p_enc? p_enc: (char_u *)"latin1"); ++ if (conv.vc_type == CONV_NONE) ++ { ++ /* p_enc is utf-8, so we're done. */ ++ enc_str = utf8_str; ++ } ++ else ++ { ++ enc_str = string_convert(&conv, utf8_str, lenp); ++ vim_free(utf8_str); ++ } ++ ++ convert_setup(&conv, NULL, NULL); ++ } ++ ++ return enc_str; ++ } ++ #endif /* FEAT_MBYTE */ ++ ++ #if (defined(FEAT_MBYTE) && defined(WIN3264)) || defined(PROTO) ++ /* ++ * Convert from the active codepage to 'encoding'. ++ * Input is "str[str_size]". ++ * The result is in allocated memory: "out[outlen]". With terminating NUL. ++ */ ++ void ++ acp_to_enc(str, str_size, out, outlen) ++ char_u *str; ++ int str_size; ++ char_u **out; ++ int *outlen; ++ ++ { ++ LPWSTR widestr; ++ ++ MultiByteToWideChar_alloc(GetACP(), 0, str, str_size, &widestr, outlen); ++ if (widestr != NULL) ++ { ++ ++*outlen; /* Include the 0 after the string */ ++ *out = utf16_to_enc((short_u *)widestr, outlen); ++ vim_free(widestr); ++ } ++ } ++ #endif +*** ../vim-7.3.835/src/version.c 2013-02-26 14:14:01.000000000 +0100 +--- src/version.c 2013-02-26 14:43:36.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 836, + /**/ + +-- +Engineers understand that their appearance only bothers other people and +therefore it is not worth optimizing. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 523ed1e25fcd94e2275e041d46cd3d8094d5d0fa Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:07 +0200 Subject: [PATCH 0723/3340] - patchlevel 837 --- 7.3.837 | 84 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 7.3.837 diff --git a/7.3.837 b/7.3.837 new file mode 100644 index 00000000..7e7ed417 --- /dev/null +++ b/7.3.837 @@ -0,0 +1,84 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.837 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.837 (after 7.3.826) +Problem: Empty lines in :version output when 'columns' is 320. +Solution: Simplify the logic of making columns. (Nazri Ramliy, Roland + Eggner) +Files: src/version.c + + +*** ../vim-7.3.836/src/version.c 2013-02-26 14:56:24.000000000 +0100 +--- src/version.c 2013-02-26 15:10:56.000000000 +0100 +*************** +*** 2496,2509 **** + return; + } + +- ncol = (int) Columns / width; + /* The rightmost column doesn't need a separator. + * Sacrifice it to fit in one more column if possible. */ +! if (Columns % width == width - 1) +! ncol++; +! + nrow = nfeat / ncol + (nfeat % ncol ? 1 : 0); + + for (i = 0; !got_int && i < nrow * ncol; ++i) + { + int idx = (i / ncol) + (i % ncol) * nrow; +--- 2498,2509 ---- + return; + } + + /* The rightmost column doesn't need a separator. + * Sacrifice it to fit in one more column if possible. */ +! ncol = (int) (Columns + 1) / width; + nrow = nfeat / ncol + (nfeat % ncol ? 1 : 0); + ++ /* i counts columns then rows. idx counts rows then columns. */ + for (i = 0; !got_int && i < nrow * ncol; ++i) + { + int idx = (i / ncol) + (i % ncol) * nrow; +*************** +*** 2525,2531 **** + } + } + else +! msg_putchar('\n'); + } + } + +--- 2525,2534 ---- + } + } + else +! { +! if (msg_col > 0) +! msg_putchar('\n'); +! } + } + } + +*** ../vim-7.3.836/src/version.c 2013-02-26 14:56:24.000000000 +0100 +--- src/version.c 2013-02-26 15:10:56.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 837, + /**/ + +-- +Imagine a world without hypothetical situations. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9d213938c6bf47a984ccbb0670d0377fc7a062d9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:08 +0200 Subject: [PATCH 0724/3340] - patchlevel 838 --- 7.3.838 | 364 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 364 insertions(+) create mode 100644 7.3.838 diff --git a/7.3.838 b/7.3.838 new file mode 100644 index 00000000..02ad2ae2 --- /dev/null +++ b/7.3.838 @@ -0,0 +1,364 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.838 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.838 (after 7.3.830) +Problem: Insufficient testing for mksession. +Solution: Add tests. (mostly by Roland Eggner) +Files: src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak, + src/testdir/Make_ming.mak, src/testdir/Make_os2.mak, + src/testdir/Make_vms.mms, src/testdir/Makefile, + src/testdir/test92.in, src/testdir/test92.ok, + src/testdir/test93.in, src/testdir/test93.ok, + src/ex_docmd.c + + +*** ../vim-7.3.837/src/testdir/Make_amiga.mak 2013-02-20 21:11:14.000000000 +0100 +--- src/testdir/Make_amiga.mak 2013-02-26 15:30:10.000000000 +0100 +*************** +*** 32,38 **** + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out test90.out test91.out + + .SUFFIXES: .in .out + +--- 32,38 ---- + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out test90.out test91.out test92.out test93.out + + .SUFFIXES: .in .out + +*************** +*** 140,142 **** +--- 140,144 ---- + test89.out: test89.in + test90.out: test90.in + test91.out: test91.in ++ test92.out: test92.in ++ test93.out: test93.in +*** ../vim-7.3.837/src/testdir/Make_dos.mak 2013-02-20 21:11:14.000000000 +0100 +--- src/testdir/Make_dos.mak 2013-02-26 15:30:10.000000000 +0100 +*************** +*** 31,37 **** + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out test91.out + + SCRIPTS32 = test50.out test70.out + +--- 31,37 ---- + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out test91.out test92.out test93.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.837/src/testdir/Make_ming.mak 2013-02-20 21:11:14.000000000 +0100 +--- src/testdir/Make_ming.mak 2013-02-26 15:30:10.000000000 +0100 +*************** +*** 51,57 **** + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out test91.out + + SCRIPTS32 = test50.out test70.out + +--- 51,57 ---- + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out test91.out test92.out test93.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.837/src/testdir/Make_os2.mak 2013-02-20 21:11:14.000000000 +0100 +--- src/testdir/Make_os2.mak 2013-02-26 15:30:10.000000000 +0100 +*************** +*** 32,38 **** + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out test90.out test91.out + + .SUFFIXES: .in .out + +--- 32,38 ---- + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out test90.out test91.out test92.out test93.out + + .SUFFIXES: .in .out + +*** ../vim-7.3.837/src/testdir/Make_vms.mms 2013-02-20 21:11:14.000000000 +0100 +--- src/testdir/Make_vms.mms 2013-02-26 15:30:10.000000000 +0100 +*************** +*** 4,10 **** + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2013 Feb 20 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +--- 4,10 ---- + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2013-02-21 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +*************** +*** 77,83 **** + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ + test82.out test83.out test84.out test88.out test89.out \ +! test90.out test91.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +--- 77,83 ---- + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ + test82.out test83.out test84.out test88.out test89.out \ +! test90.out test91.out test92.out test93.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +*** ../vim-7.3.837/src/testdir/Makefile 2013-02-20 21:11:14.000000000 +0100 +--- src/testdir/Makefile 2013-02-26 15:30:10.000000000 +0100 +*************** +*** 28,34 **** + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out test91.out + + SCRIPTS_GUI = test16.out + +--- 28,34 ---- + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out test91.out test92.out test93.out + + SCRIPTS_GUI = test16.out + +*** ../vim-7.3.837/src/testdir/test92.in 2013-02-26 17:20:44.000000000 +0100 +--- src/testdir/test92.in 2013-02-26 16:27:55.000000000 +0100 +*************** +*** 0 **** +--- 1,48 ---- ++ vim: set ft=vim fenc=utf-8: ++ ++ Tests if :mksession saves cursor columns correctly in presence of tab and ++ multibyte characters when fileencoding=utf-8. ++ ++ STARTTEST ++ :so mbyte.vim ++ :if !has('mksession') ++ : e! test.ok ++ : wq! test.out ++ :endif ++ :set sessionoptions=buffers splitbelow fileencoding=utf-8 ++ /^start: ++ :vsplit ++ j16|:split ++ j16|:split ++ j16|:split ++ j8|:split ++ j8|:split ++ j16|:split ++ j16|:split ++ j16|:wincmd l ++ /^start: ++ :set nowrap ++ j16|3zl:split ++ j016|3zl:split ++ j016|3zl:split ++ j08|3zl:split ++ j08|3zl:split ++ j016|3zl:split ++ j016|3zl:split ++ j016|3zl:split ++ :mksession! test.out ++ :new test.out ++ :v/\(^ *normal! 0\|^ *exe 'normal!\)/d ++ :w ++ :qa! ++ ENDTEST ++ ++ start: ++ no multibyte chAracter ++ one leaDing tab ++ four leadinG spaces ++ two consecutive tabs ++ two tabs in one line ++ one … multibyteCharacter ++ a “b†two multiByte characters ++ “câ€Â1€ three mulTibyte characters +*** ../vim-7.3.837/src/testdir/test92.ok 2013-02-26 17:20:44.000000000 +0100 +--- src/testdir/test92.ok 2013-02-26 17:13:48.000000000 +0100 +*************** +*** 0 **** +--- 1,26 ---- ++ normal! 016| ++ normal! 016| ++ normal! 016| ++ normal! 08| ++ normal! 08| ++ normal! 016| ++ normal! 016| ++ normal! 016| ++ exe 'normal! ' . s:c . '|zs' . 16 . '|' ++ normal! 016| ++ exe 'normal! ' . s:c . '|zs' . 16 . '|' ++ normal! 016| ++ exe 'normal! ' . s:c . '|zs' . 16 . '|' ++ normal! 016| ++ exe 'normal! ' . s:c . '|zs' . 8 . '|' ++ normal! 08| ++ exe 'normal! ' . s:c . '|zs' . 8 . '|' ++ normal! 08| ++ exe 'normal! ' . s:c . '|zs' . 16 . '|' ++ normal! 016| ++ exe 'normal! ' . s:c . '|zs' . 16 . '|' ++ normal! 016| ++ exe 'normal! ' . s:c . '|zs' . 16 . '|' ++ normal! 016| ++ exe 'normal! ' . s:c . '|zs' . 16 . '|' ++ normal! 016| +*** ../vim-7.3.837/src/testdir/test93.in 2013-02-26 17:20:44.000000000 +0100 +--- src/testdir/test93.in 2013-02-26 17:13:01.000000000 +0100 +*************** +*** 0 **** +--- 1,48 ---- ++ vim: set ft=vim fenc=latin1: ++ ++ Tests if :mksession saves cursor columns correctly in presence of tab and ++ multibyte characters when fileencoding=latin1. ++ ++ STARTTEST ++ :so mbyte.vim ++ :if !has('mksession') ++ : e! test.ok ++ : wq! test.out ++ :endif ++ :set sessionoptions=buffers splitbelow fileencoding=latin1 ++ /^start: ++ :vsplit ++ j16|:split ++ j16|:split ++ j16|:split ++ j8|:split ++ j8|:split ++ j16|:split ++ j16|:split ++ j16|:wincmd l ++ /^start: ++ :set nowrap ++ j16|3zl:split ++ j016|3zl:split ++ j016|3zl:split ++ j08|3zl:split ++ j08|3zl:split ++ j016|3zl:split ++ j016|3zl:split ++ j016|3zl:split ++ :mksession! test.out ++ :new test.out ++ :v/\(^ *normal! 0\|^ *exe 'normal!\)/d ++ :w ++ :qa! ++ ENDTEST ++ ++ start: ++ no multibyte chAracter ++ one leaDing tab ++ four leadinG spaces ++ two consecutive tabs ++ two tabs in one line ++ one ä multibyteCharacter ++ aä Ä two multiByte characters ++ Aäöü three mulTibyte characters +*** ../vim-7.3.837/src/testdir/test93.ok 2013-02-26 17:20:44.000000000 +0100 +--- src/testdir/test93.ok 2013-02-26 17:14:02.000000000 +0100 +*************** +*** 0 **** +--- 1,26 ---- ++ normal! 016| ++ normal! 016| ++ normal! 016| ++ normal! 08| ++ normal! 08| ++ normal! 016| ++ normal! 016| ++ normal! 016| ++ exe 'normal! ' . s:c . '|zs' . 16 . '|' ++ normal! 016| ++ exe 'normal! ' . s:c . '|zs' . 16 . '|' ++ normal! 016| ++ exe 'normal! ' . s:c . '|zs' . 16 . '|' ++ normal! 016| ++ exe 'normal! ' . s:c . '|zs' . 8 . '|' ++ normal! 08| ++ exe 'normal! ' . s:c . '|zs' . 8 . '|' ++ normal! 08| ++ exe 'normal! ' . s:c . '|zs' . 16 . '|' ++ normal! 016| ++ exe 'normal! ' . s:c . '|zs' . 16 . '|' ++ normal! 016| ++ exe 'normal! ' . s:c . '|zs' . 16 . '|' ++ normal! 016| ++ exe 'normal! ' . s:c . '|zs' . 16 . '|' ++ normal! 016| +*** ../vim-7.3.837/src/ex_docmd.c 2013-02-20 19:26:24.000000000 +0100 +--- src/ex_docmd.c 2013-02-26 16:14:07.000000000 +0100 +*************** +*** 10839,10845 **** + (long)wp->w_virtcol + 1) < 0 + || put_eol(fd) == FAIL + || put_line(fd, "else") == FAIL +! || fprintf(fd, " normal! %d|", wp->w_virtcol + 1) < 0 + || put_eol(fd) == FAIL + || put_line(fd, "endif") == FAIL) + return FAIL; +--- 10839,10845 ---- + (long)wp->w_virtcol + 1) < 0 + || put_eol(fd) == FAIL + || put_line(fd, "else") == FAIL +! || fprintf(fd, " normal! 0%d|", wp->w_virtcol + 1) < 0 + || put_eol(fd) == FAIL + || put_line(fd, "endif") == FAIL) + return FAIL; +*** ../vim-7.3.837/src/version.c 2013-02-26 15:27:20.000000000 +0100 +--- src/version.c 2013-02-26 15:31:06.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 838, + /**/ + +-- +It doesn't really matter what you are able to do if you don't do it. + (Bram Moolenaar) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7264c3a635eea3bf02372b4f5c35baf7cd47c0a8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:08 +0200 Subject: [PATCH 0725/3340] - patchlevel 839 --- 7.3.839 | 76 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 7.3.839 diff --git a/7.3.839 b/7.3.839 new file mode 100644 index 00000000..2c4eb78c --- /dev/null +++ b/7.3.839 @@ -0,0 +1,76 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.839 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.839 +Problem: Some files missing in the list of distributed files. +Solution: Add lines for new files. +Files: Filelist + + +*** ../vim-7.3.838/Filelist 2012-10-03 21:48:38.000000000 +0200 +--- Filelist 2013-02-26 17:55:17.000000000 +0100 +*************** +*** 73,78 **** +--- 73,79 ---- + src/version.c \ + src/version.h \ + src/vim.h \ ++ src/winclip.c \ + src/window.c \ + src/xxd/xxd.c \ + src/main.aap \ +*************** +*** 83,88 **** +--- 84,90 ---- + src/testdir/test60.vim \ + src/testdir/test83-tags? \ + src/proto.h \ ++ src/proto/arabic.pro \ + src/proto/blowfish.pro \ + src/proto/buffer.pro \ + src/proto/charset.pro \ +*************** +*** 130,135 **** +--- 132,138 ---- + src/proto/ui.pro \ + src/proto/undo.pro \ + src/proto/version.pro \ ++ src/proto/winclip.pro \ + src/proto/window.pro \ + + +*************** +*** 444,449 **** +--- 447,453 ---- + src/os_beos.c \ + src/os_beos.h \ + src/os_beos.rsrc \ ++ src/proto/os_beos.pro \ + src/os_mint.h \ + src/os_vms_fix.com \ + src/toolbar.phi \ +*** ../vim-7.3.838/src/version.c 2013-02-26 17:21:15.000000000 +0100 +--- src/version.c 2013-02-26 17:56:40.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 839, + /**/ + +-- +Normal people believe that if it ain't broke, don't fix it. Engineers believe +that if it ain't broke, it doesn't have enough features yet. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4fabf59821b95ebce50f77cfd4fcc7283d8f699f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:09 +0200 Subject: [PATCH 0726/3340] - patchlevel 840 --- 7.3.840 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 7.3.840 diff --git a/7.3.840 b/7.3.840 new file mode 100644 index 00000000..d68c9fbf --- /dev/null +++ b/7.3.840 @@ -0,0 +1,54 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.840 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.840 +Problem: "\@rs_un.regsave.rs_u.pos.col -= ++ (*mb_head_off)(regline, regline ++ + rp->rs_un.regsave.rs_u.pos.col - 1) + 1; ++ else ++ #endif + --rp->rs_un.regsave.rs_u.pos.col; + } + else +*** ../vim-7.3.839/src/version.c 2013-02-26 17:59:37.000000000 +0100 +--- src/version.c 2013-02-26 18:39:28.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 840, + /**/ + +-- +I learned the customs and mannerisms of engineers by observing them, much the +way Jane Goodall learned about the great apes, but without the hassle of +grooming. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3bed6c4f45fb137330a64c7111ae8d0a695bcda7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:09 +0200 Subject: [PATCH 0727/3340] - patchlevel 841 --- 7.3.841 | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.841 diff --git a/7.3.841 b/7.3.841 new file mode 100644 index 00000000..abe5bf7b --- /dev/null +++ b/7.3.841 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.841 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.841 +Problem: When a "cond ? one : two" expression has a subscript it is not + parsed correctly. (Andy Wokula) +Solution: Handle a subscript also when the type is unknown. (Christian + Brabandt) +Files: src/eval.c + + +*** ../vim-7.3.840/src/eval.c 2013-02-20 21:11:14.000000000 +0100 +--- src/eval.c 2013-02-26 19:27:59.000000000 +0100 +*************** +*** 5164,5169 **** +--- 5164,5179 ---- + ret = get_func_tv(s, len, rettv, arg, + curwin->w_cursor.lnum, curwin->w_cursor.lnum, + &len, evaluate, NULL); ++ ++ /* If evaluate is FALSE rettv->v_type was not set in ++ * get_func_tv, but it's needed in handle_subscript() to parse ++ * what follows. So set it here. */ ++ if (rettv->v_type == VAR_UNKNOWN && !evaluate && **arg == '(') ++ { ++ rettv->vval.v_string = vim_strsave(""); ++ rettv->v_type = VAR_FUNC; ++ } ++ + /* Stop the expression evaluation when immediately + * aborting on error, or when an interrupt occurred or + * an exception was thrown but not caught. */ +*** ../vim-7.3.840/src/version.c 2013-02-26 18:45:49.000000000 +0100 +--- src/version.c 2013-02-26 19:35:36.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 841, + /**/ + +-- +If someone questions your market projections, simply point out that your +target market is "People who are nuts" and "People who will buy any damn +thing". Nobody is going to tell you there aren't enough of those people +to go around. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f07892961f75c1ad34ba68e7698f71dec0c6a487 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:10 +0200 Subject: [PATCH 0728/3340] - patchlevel 842 --- 7.3.842 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 7.3.842 diff --git a/7.3.842 b/7.3.842 new file mode 100644 index 00000000..895c783b --- /dev/null +++ b/7.3.842 @@ -0,0 +1,54 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.842 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.842 +Problem: Compiler warning for signed/unsigned pointer. +Solution: Add type cast. (Christian Brabandt) +Files: src/eval.c + + +*** ../vim-7.3.841/src/eval.c 2013-02-26 19:36:03.000000000 +0100 +--- src/eval.c 2013-02-26 21:41:24.000000000 +0100 +*************** +*** 5170,5176 **** + * what follows. So set it here. */ + if (rettv->v_type == VAR_UNKNOWN && !evaluate && **arg == '(') + { +! rettv->vval.v_string = vim_strsave(""); + rettv->v_type = VAR_FUNC; + } + +--- 5170,5176 ---- + * what follows. So set it here. */ + if (rettv->v_type == VAR_UNKNOWN && !evaluate && **arg == '(') + { +! rettv->vval.v_string = vim_strsave((char_u *)""); + rettv->v_type = VAR_FUNC; + } + +*** ../vim-7.3.841/src/version.c 2013-02-26 19:36:03.000000000 +0100 +--- src/version.c 2013-02-26 21:43:21.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 842, + /**/ + +-- +The process for understanding customers primarily involves sitting around with +other marketing people and talking about what you would to if you were dumb +enough to be a customer. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 50186aef3c08a43bd62a7e992279907724b3f0de Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:11 +0200 Subject: [PATCH 0729/3340] - patchlevel 843 --- 7.3.843 | 111 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 111 insertions(+) create mode 100644 7.3.843 diff --git a/7.3.843 b/7.3.843 new file mode 100644 index 00000000..ebb369d5 --- /dev/null +++ b/7.3.843 @@ -0,0 +1,111 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.843 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.843 (after 7.3.841) +Problem: Missing test file changes. +Solution: Change the tests. +Files: src/testdir/test49.vim, src/testdir/test49.ok + + +*** ../vim-7.3.842/src/testdir/test49.vim 2012-12-05 19:00:03.000000000 +0100 +--- src/testdir/test49.vim 2013-02-26 19:22:36.000000000 +0100 +*************** +*** 9624,9630 **** + Xcheck 0 + + "------------------------------------------------------------------------------- +! " Test 87: $VIMNOERRTHROW and $VIMNOINTTHROW support {{{1 + " + " It is possible to configure Vim for throwing exceptions on error + " or interrupt, controlled by variables $VIMNOERRTHROW and +--- 9624,9661 ---- + Xcheck 0 + + "------------------------------------------------------------------------------- +! " Test 87 using (expr) ? funcref : funcref {{{1 +! " +! " Vim needs to correctly parse the funcref and even when it does +! " not execute the funcref, it needs to consume the trailing () +! "------------------------------------------------------------------------------- +! +! XpathINIT +! +! func Add2(x1, x2) +! return a:x1 + a:x2 +! endfu +! +! func GetStr() +! return "abcdefghijklmnopqrstuvwxyp" +! endfu +! +! echo function('Add2')(2,3) +! +! Xout 1 ? function('Add2')(1,2) : function('Add2')(2,3) +! Xout 0 ? function('Add2')(1,2) : function('Add2')(2,3) +! " Make sure, GetStr() still works. +! Xout GetStr()[0:10] +! +! +! delfunction GetStr +! delfunction Add2 +! Xout "Successfully executed funcref Add2" +! +! Xcheck 0 +! +! "------------------------------------------------------------------------------- +! " Test 88: $VIMNOERRTHROW and $VIMNOINTTHROW support {{{1 + " + " It is possible to configure Vim for throwing exceptions on error + " or interrupt, controlled by variables $VIMNOERRTHROW and +*** ../vim-7.3.842/src/testdir/test49.ok 2012-11-14 22:38:04.000000000 +0100 +--- src/testdir/test49.ok 2013-02-26 19:22:36.000000000 +0100 +*************** +*** 87,94 **** + *** Test 85: OK (198689) + --- Test 86: No Crash for vimgrep on BufUnload + *** Test 86: OK (0) +! --- Test 87: All tests were run with throwing exceptions on error. + The $VIMNOERRTHROW control is not configured. +! --- Test 87: All tests were run with throwing exceptions on interrupt. + The $VIMNOINTTHROW control is not configured. +! *** Test 87: OK (50443995) +--- 87,99 ---- + *** Test 85: OK (198689) + --- Test 86: No Crash for vimgrep on BufUnload + *** Test 86: OK (0) +! --- Test 87: 3 +! --- Test 87: 5 +! --- Test 87: abcdefghijk +! --- Test 87: Successfully executed funcref Add2 +! *** Test 87: OK (0) +! --- Test 88: All tests were run with throwing exceptions on error. + The $VIMNOERRTHROW control is not configured. +! --- Test 88: All tests were run with throwing exceptions on interrupt. + The $VIMNOINTTHROW control is not configured. +! *** Test 88: OK (50443995) +*** ../vim-7.3.842/src/version.c 2013-02-26 21:43:28.000000000 +0100 +--- src/version.c 2013-02-26 22:53:13.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 843, + /**/ + +-- +Never enter the boss's office unless it's absolutely necessary. Every boss +saves one corner of the desk for useless assignments that are doled out like +Halloween candy to each visitor. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 348c77da12bba828496a28205606f93967547bb5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:11 +0200 Subject: [PATCH 0730/3340] - patchlevel 844 --- 7.3.844 | 197 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 197 insertions(+) create mode 100644 7.3.844 diff --git a/7.3.844 b/7.3.844 new file mode 100644 index 00000000..015a0b56 --- /dev/null +++ b/7.3.844 @@ -0,0 +1,197 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.844 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.844 +Problem: Enum is not indented correctly with "public" etc. +Solution: Skip "public", "private" and "protected". (Hong Xu) +Files: src/misc1.c + + +*** ../vim-7.3.843/src/misc1.c 2013-02-13 16:10:13.000000000 +0100 +--- src/misc1.c 2013-03-07 12:59:45.000000000 +0100 +*************** +*** 5275,5280 **** +--- 5275,5281 ---- + static int cin_is_cpp_baseclass __ARGS((colnr_T *col)); + static int get_baseclass_amount __ARGS((int col, int ind_maxparen, int ind_maxcomment, int ind_cpp_baseclass)); + static int cin_ends_in __ARGS((char_u *, char_u *, char_u *)); ++ static int cin_starts_with __ARGS((char_u *s, char *word)); + static int cin_skip2pos __ARGS((pos_T *trypos)); + static pos_T *find_start_brace __ARGS((int)); + static pos_T *find_match_paren __ARGS((int, int)); +*************** +*** 5446,5469 **** + } + + /* +! * Recognize structure initialization and enumerations. +! * Q&D-Implementation: +! * check for "=" at end or "[typedef] enum" at beginning of line. + */ + static int + cin_isinit(void) + { + char_u *s; + + s = cin_skipcomment(ml_get_curline()); + +! if (STRNCMP(s, "typedef", 7) == 0 && !vim_isIDc(s[7])) + s = cin_skipcomment(s + 7); + +! if (STRNCMP(s, "static", 6) == 0 && !vim_isIDc(s[6])) +! s = cin_skipcomment(s + 6); + +! if (STRNCMP(s, "enum", 4) == 0 && !vim_isIDc(s[4])) + return TRUE; + + if (cin_ends_in(s, (char_u *)"=", (char_u *)"{")) +--- 5447,5486 ---- + } + + /* +! * Recognize structure initialization and enumerations: +! * "[typedef] [static|public|protected|private] enum" +! * "[typedef] [static|public|protected|private] = {" + */ + static int + cin_isinit(void) + { + char_u *s; ++ static char *skip[] = {"static", "public", "protected", "private"}; + + s = cin_skipcomment(ml_get_curline()); + +! if (cin_starts_with(s, "typedef")) + s = cin_skipcomment(s + 7); + +! for (;;) +! { +! int i, l; +! +! for (i = 0; i < (int)(sizeof(skip) / sizeof(char *)); ++i) +! { +! l = strlen(skip[i]); +! if (cin_starts_with(s, skip[i])) +! { +! s = cin_skipcomment(s + l); +! l = 0; +! break; +! } +! } +! if (l != 0) +! break; +! } + +! if (cin_starts_with(s, "enum")) + return TRUE; + + if (cin_ends_in(s, (char_u *)"=", (char_u *)"{")) +*************** +*** 5481,5487 **** + int strict; /* Allow relaxed check of case statement for JS */ + { + s = cin_skipcomment(s); +! if (STRNCMP(s, "case", 4) == 0 && !vim_isIDc(s[4])) + { + for (s += 4; *s; ++s) + { +--- 5498,5504 ---- + int strict; /* Allow relaxed check of case statement for JS */ + { + s = cin_skipcomment(s); +! if (cin_starts_with(s, "case")) + { + for (s += 4; *s; ++s) + { +*************** +*** 6049,6055 **** + p = cin_skipcomment(p); + if (*p == '}') /* accept "} while (cond);" */ + p = cin_skipcomment(p + 1); +! if (STRNCMP(p, "while", 5) == 0 && !vim_isIDc(p[5])) + { + cursor_save = curwin->w_cursor; + curwin->w_cursor.lnum = lnum; +--- 6066,6072 ---- + p = cin_skipcomment(p); + if (*p == '}') /* accept "} while (cond);" */ + p = cin_skipcomment(p + 1); +! if (cin_starts_with(p, "while")) + { + cursor_save = curwin->w_cursor; + curwin->w_cursor.lnum = lnum; +*************** +*** 6156,6162 **** + s = cin_skipcomment(ml_get(trypos->lnum)); + if (*s == '}') /* accept "} while (cond);" */ + s = cin_skipcomment(s + 1); +! if (STRNCMP(s, "while", 5) == 0 && !vim_isIDc(s[5])) + { + curwin->w_cursor.lnum = trypos->lnum; + return TRUE; +--- 6173,6179 ---- + s = cin_skipcomment(ml_get(trypos->lnum)); + if (*s == '}') /* accept "} while (cond);" */ + s = cin_skipcomment(s + 1); +! if (cin_starts_with(s, "while")) + { + curwin->w_cursor.lnum = trypos->lnum; + return TRUE; +*************** +*** 6406,6411 **** +--- 6423,6441 ---- + } + + /* ++ * Return TRUE when "s" starts with "word" and then a non-ID character. ++ */ ++ static int ++ cin_starts_with(s, word) ++ char_u *s; ++ char *word; ++ { ++ int l = STRLEN(word); ++ ++ return (STRNCMP(s, word, l) == 0 && !vim_isIDc(s[l])); ++ } ++ ++ /* + * Skip strings, chars and comments until at or past "trypos". + * Return the column found. + */ +*** ../vim-7.3.843/src/version.c 2013-02-26 22:54:06.000000000 +0100 +--- src/version.c 2013-03-07 13:12:20.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 844, + /**/ + +-- +Now it is such a bizarrely improbable coincidence that anything as +mind-bogglingly useful as the Babel fish could have evolved purely by chance +that some thinkers have chosen to see it as a final and clinching proof of the +NON-existence of God. +The argument goes something like this: 'I refuse to prove that I exist,' says +God, 'for proof denies faith, and without faith I am nothing.' +'But,' says Man, 'the Babel fish is a dead giveaway, isn't it? It could not +have evolved by chance. It proves you exist, and so therefore, by your own +arguments, you don't. QED.' +'Oh dear,' says God, 'I hadn't thought of that,' and promptly vanishes in a +puff of logic. +'Oh, that was easy,' says Man, and for an encore goes on to prove that black +is white and gets himself killed on the next pedestrian crossing. + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 312157ace0267077c8518bca2b155e3d50e4c0ee Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:12 +0200 Subject: [PATCH 0731/3340] - patchlevel 845 --- 7.3.845 | 88 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 88 insertions(+) create mode 100644 7.3.845 diff --git a/7.3.845 b/7.3.845 new file mode 100644 index 00000000..d9acfefb --- /dev/null +++ b/7.3.845 @@ -0,0 +1,88 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.845 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.845 (after 7.3.844) +Problem: Enum indenting is not tested. +Solution: Add tests. (Hong Xu) +Files: src/testdir/test3.in, src/testdir/test3.ok + + +*** ../vim-7.3.844/src/testdir/test3.in 2012-06-13 13:40:45.000000000 +0200 +--- src/testdir/test3.in 2013-03-07 12:39:35.000000000 +0100 +*************** +*** 318,323 **** +--- 318,337 ---- + maybe + } soppie; + ++ public static enum ++ { ++ yes = 0, ++ no, ++ maybe ++ } soppie; ++ ++ static private enum ++ { ++ yes = 0, ++ no, ++ maybe ++ } soppie; ++ + { + int a, + b; +*** ../vim-7.3.844/src/testdir/test3.ok 2012-06-13 13:40:45.000000000 +0200 +--- src/testdir/test3.ok 2013-03-07 12:40:03.000000000 +0100 +*************** +*** 306,311 **** +--- 306,325 ---- + maybe + } soppie; + ++ public static enum ++ { ++ yes = 0, ++ no, ++ maybe ++ } soppie; ++ ++ static private enum ++ { ++ yes = 0, ++ no, ++ maybe ++ } soppie; ++ + { + int a, + b; +*** ../vim-7.3.844/src/version.c 2013-03-07 13:13:45.000000000 +0100 +--- src/version.c 2013-03-07 13:18:49.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 845, + /**/ + +-- +"So this is it," said Arthur, "we are going to die." +"Yes," said Ford, "except...no! Wait a minute!" He suddenly lunged across +the chamber at something behind Arthur's line of vision. "What's this +switch?" he cried. +"What? Where?" cried Arthur, twisting around. +"No, I was only fooling," said Ford, "we are going to die after all." + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 26ce66b13982816905fe886eccb8f7471ae1efd1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:12 +0200 Subject: [PATCH 0732/3340] - patchlevel 846 --- 7.3.846 | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 7.3.846 diff --git a/7.3.846 b/7.3.846 new file mode 100644 index 00000000..da52ef59 --- /dev/null +++ b/7.3.846 @@ -0,0 +1,46 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.846 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.846 +Problem: Missing proto file, listing a non-existing proto file. +Solution: Remove the file. Add os_beos.pro only in Mercurial. +Files: Filelist + + +*** ../vim-7.3.845/Filelist 2013-02-26 17:59:37.000000000 +0100 +--- Filelist 2013-03-07 13:27:30.000000000 +0100 +*************** +*** 84,90 **** + src/testdir/test60.vim \ + src/testdir/test83-tags? \ + src/proto.h \ +- src/proto/arabic.pro \ + src/proto/blowfish.pro \ + src/proto/buffer.pro \ + src/proto/charset.pro \ +--- 84,89 ---- +*** ../vim-7.3.845/src/version.c 2013-03-07 13:21:28.000000000 +0100 +--- src/version.c 2013-03-07 13:23:02.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 846, + /**/ + +-- +I am also told that there is a logical proof out there somewhere +that demonstrates that there is no task which duct tape cannot handle. + -- Paul Brannan + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d2126a04240ee2c1b7117b891ae5bb4b44f23b4d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:13 +0200 Subject: [PATCH 0733/3340] - patchlevel 847 --- 7.3.847 | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 7.3.847 diff --git a/7.3.847 b/7.3.847 new file mode 100644 index 00000000..a9bb4267 --- /dev/null +++ b/7.3.847 @@ -0,0 +1,47 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.847 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.847 +Problem: Test 55 fails when messages are translated. +Solution: Set language to C. (Ken Takata) +Files: src/testdir/test55.in + + +*** ../vim-7.3.846/src/testdir/test55.in 2012-08-29 16:55:09.000000000 +0200 +--- src/testdir/test55.in 2013-03-07 14:33:12.000000000 +0100 +*************** +*** 3,8 **** +--- 3,9 ---- + STARTTEST + :so small.vim + :fun Test(...) ++ :lang C + :" Creating List directly with different types + :let l = [1, 'as''d', [1, 2, function("strlen")], {'a': 1},] + :$put =string(l) +*** ../vim-7.3.846/src/version.c 2013-03-07 13:32:03.000000000 +0100 +--- src/version.c 2013-03-07 14:49:57.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 847, + /**/ + +-- +"Space is big. Really big. You just won't believe how vastly hugely mind- +bogglingly big it is. I mean, you may think it's a long way down the +road to the chemist, but that's just peanuts to space." + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4c79b2ba49fec4c34fc2eb328e106852de48445d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:14 +0200 Subject: [PATCH 0734/3340] - patchlevel 848 --- 7.3.848 | 153 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 153 insertions(+) create mode 100644 7.3.848 diff --git a/7.3.848 b/7.3.848 new file mode 100644 index 00000000..aaf8401c --- /dev/null +++ b/7.3.848 @@ -0,0 +1,153 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.848 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.848 +Problem: Can't build with Ruby 2.0 when using MinGW x64 or MSVC10. +Solution: Fix it. Also detect RUBY_PLATFORM and RUBY_INSTALL_NAME for x64. + (Ken Takata) +Files: src/Make_cyg.mak, src/Make_ming.mak, src/if_ruby.c + + +*** ../vim-7.3.847/src/Make_cyg.mak 2013-02-26 14:56:24.000000000 +0100 +--- src/Make_cyg.mak 2013-03-07 14:56:29.000000000 +0100 +*************** +*** 229,246 **** +--- 229,254 ---- + ifneq ($(wildcard $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/i386-mingw32),) + RUBY_PLATFORM = i386-mingw32 + else ++ ifneq ($(wildcard $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/x64-mingw32),) ++ RUBY_PLATFORM = x64-mingw32 ++ else + RUBY_PLATFORM = i386-mswin32 + endif + endif + endif ++ endif + + ifndef RUBY_INSTALL_NAME + ifeq ($(RUBY_VER), 16) + RUBY_INSTALL_NAME = mswin32-ruby$(RUBY_API_VER) + else ++ ifeq ($(ARCH),x86-64) ++ RUBY_INSTALL_NAME = x64-msvcrt-ruby$(RUBY_API_VER) ++ else + RUBY_INSTALL_NAME = msvcrt-ruby$(RUBY_API_VER) + endif + endif ++ endif + + ifeq (19, $(word 1,$(sort 19 $(RUBY_VER)))) + RUBY_19_OR_LATER = 1 +*** ../vim-7.3.847/src/Make_ming.mak 2013-02-26 14:56:24.000000000 +0100 +--- src/Make_ming.mak 2013-03-07 14:56:29.000000000 +0100 +*************** +*** 288,305 **** +--- 288,313 ---- + ifneq ($(wildcard $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/i386-mingw32),) + RUBY_PLATFORM = i386-mingw32 + else ++ ifneq ($(wildcard $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/x64-mingw32),) ++ RUBY_PLATFORM = x64-mingw32 ++ else + RUBY_PLATFORM = i386-mswin32 + endif + endif + endif ++ endif + + ifndef RUBY_INSTALL_NAME + ifeq ($(RUBY_VER), 16) + RUBY_INSTALL_NAME = mswin32-ruby$(RUBY_API_VER) + else ++ ifeq ($(ARCH),x86-64) ++ RUBY_INSTALL_NAME = x64-msvcrt-ruby$(RUBY_API_VER) ++ else + RUBY_INSTALL_NAME = msvcrt-ruby$(RUBY_API_VER) + endif + endif ++ endif + + ifeq (19, $(word 1,$(sort 19 $(RUBY_VER)))) + RUBY_19_OR_LATER = 1 +*** ../vim-7.3.847/src/if_ruby.c 2013-02-26 13:41:31.000000000 +0100 +--- src/if_ruby.c 2013-03-07 14:56:29.000000000 +0100 +*************** +*** 39,44 **** +--- 39,47 ---- + */ + # define rb_cFalseClass (*dll_rb_cFalseClass) + # define rb_cFixnum (*dll_rb_cFixnum) ++ # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 20 ++ # define rb_cFloat (*dll_rb_cFloat) ++ # endif + # define rb_cNilClass (*dll_rb_cNilClass) + # define rb_cSymbol (*dll_rb_cSymbol) + # define rb_cTrueClass (*dll_rb_cTrueClass) +*************** +*** 249,254 **** +--- 252,260 ---- + static VALUE (*dll_rb_assoc_new) (VALUE, VALUE); + VALUE *dll_rb_cFalseClass; + VALUE *dll_rb_cFixnum; ++ #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 20 ++ VALUE *dll_rb_cFloat; ++ #endif + VALUE *dll_rb_cNilClass; + static VALUE *dll_rb_cObject; + VALUE *dll_rb_cSymbol; +*************** +*** 352,358 **** + { + return dll_rb_float_new(d); + } +! unsigned long rb_num2ulong(VALUE x) + { + return (long)RSHIFT((SIGNED_VALUE)(x),1); + } +--- 358,364 ---- + { + return dll_rb_float_new(d); + } +! VALUE rb_num2ulong(VALUE x) + { + return (long)RSHIFT((SIGNED_VALUE)(x),1); + } +*************** +*** 373,378 **** +--- 379,387 ---- + {"rb_assoc_new", (RUBY_PROC*)&dll_rb_assoc_new}, + {"rb_cFalseClass", (RUBY_PROC*)&dll_rb_cFalseClass}, + {"rb_cFixnum", (RUBY_PROC*)&dll_rb_cFixnum}, ++ #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 20 ++ {"rb_cFloat", (RUBY_PROC*)&dll_rb_cFloat}, ++ #endif + {"rb_cNilClass", (RUBY_PROC*)&dll_rb_cNilClass}, + {"rb_cObject", (RUBY_PROC*)&dll_rb_cObject}, + {"rb_cSymbol", (RUBY_PROC*)&dll_rb_cSymbol}, +*** ../vim-7.3.847/src/version.c 2013-03-07 14:50:30.000000000 +0100 +--- src/version.c 2013-03-07 14:57:03.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 848, + /**/ + +-- +`The Guide says there is an art to flying,' said Ford, `or at least a +knack. The knack lies in learning how to throw yourself at the ground +and miss.' He smiled weakly. + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e24c92a7ffec3f5f145f1b3ed2df2172ece1cc0e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:14 +0200 Subject: [PATCH 0735/3340] - patchlevel 849 --- 7.3.849 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.849 diff --git a/7.3.849 b/7.3.849 new file mode 100644 index 00000000..b97cc74c --- /dev/null +++ b/7.3.849 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.849 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.849 +Problem: ":g//" gives "Pattern not found error" with E486. Should not use + the error number, it's not a regular error message. +Solution: Use a normal message. (David Bürgin) +Files: src/ex_cmds.c + + +*** ../vim-7.3.848/src/ex_cmds.c 2013-02-06 18:23:58.000000000 +0100 +--- src/ex_cmds.c 2013-03-07 16:05:49.000000000 +0100 +*************** +*** 5411,5417 **** + if (type == 'v') + smsg((char_u *)_("Pattern found in every line: %s"), pat); + else +! smsg((char_u *)_(e_patnotf2), pat); + } + else + global_exe(cmd); +--- 5411,5417 ---- + if (type == 'v') + smsg((char_u *)_("Pattern found in every line: %s"), pat); + else +! smsg((char_u *)_("Pattern not found: %s"), pat); + } + else + global_exe(cmd); +*** ../vim-7.3.848/src/version.c 2013-03-07 15:16:16.000000000 +0100 +--- src/version.c 2013-03-07 16:03:57.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 849, + /**/ + +-- +Apparently, 1 in 5 people in the world are Chinese. And there are 5 +people in my family, so it must be one of them. It's either my mum +or my dad. Or my older brother Colin. Or my younger brother +Ho-Cha-Chu. But I think it's Colin. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1cd6cc7334cf5c1df4e9136a186d3c048fc1e440 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:15 +0200 Subject: [PATCH 0736/3340] - patchlevel 850 --- 7.3.850 | 82 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 82 insertions(+) create mode 100644 7.3.850 diff --git a/7.3.850 b/7.3.850 new file mode 100644 index 00000000..325b5ee7 --- /dev/null +++ b/7.3.850 @@ -0,0 +1,82 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.850 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.850 +Problem: ":vimgrep //" matches everywhere. +Solution: Make it use the previous search pattern. (David Bürgin) +Files: runtime/doc/quickfix.txt, src/quickfix.c + + +*** ../vim-7.3.849/runtime/doc/quickfix.txt 2010-08-15 21:57:19.000000000 +0200 +--- runtime/doc/quickfix.txt 2013-03-07 16:17:39.000000000 +0100 +*************** +*** 563,568 **** +--- 574,581 ---- + 'ignorecase' applies. To overrule it put |/\c| in the + pattern to ignore case or |/\C| to match case. + 'smartcase' is not used. ++ If {pattern} is empty (e.g. // is specified), the last ++ used search pattern is used. |last-pattern| + + When a number is put before the command this is used + as the maximum number of matches to find. Use +*** ../vim-7.3.849/src/quickfix.c 2012-12-12 15:55:16.000000000 +0100 +--- src/quickfix.c 2013-03-07 16:21:17.000000000 +0100 +*************** +*** 3179,3185 **** + EMSG(_(e_invalpat)); + goto theend; + } +! regmatch.regprog = vim_regcomp(s, RE_MAGIC); + if (regmatch.regprog == NULL) + goto theend; + regmatch.rmm_ic = p_ic; +--- 3179,3198 ---- + EMSG(_(e_invalpat)); + goto theend; + } +! +! if (s != NULL && *s == NUL) +! { +! /* Pattern is empty, use last search pattern. */ +! if (last_search_pat() == NULL) +! { +! EMSG(_(e_noprevre)); +! goto theend; +! } +! regmatch.regprog = vim_regcomp(last_search_pat(), RE_MAGIC); +! } +! else +! regmatch.regprog = vim_regcomp(s, RE_MAGIC); +! + if (regmatch.regprog == NULL) + goto theend; + regmatch.rmm_ic = p_ic; +*** ../vim-7.3.849/src/version.c 2013-03-07 16:08:31.000000000 +0100 +--- src/version.c 2013-03-07 16:16:26.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 850, + /**/ + +-- +The technology involved in making anything invisible is so infinitely +complex that nine hundred and ninety-nine billion, nine hundred and +ninety-nine million, nine hundred and ninety-nine thousand, nine hundred +and ninety-nine times out of a trillion it is much simpler and more +effective just to take the thing away and do without it. + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 12f5c18472257647a37397f4e5133c33d7f75f5d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:15 +0200 Subject: [PATCH 0737/3340] - patchlevel 851 --- 7.3.851 | 67 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 7.3.851 diff --git a/7.3.851 b/7.3.851 new file mode 100644 index 00000000..87ff27d1 --- /dev/null +++ b/7.3.851 @@ -0,0 +1,67 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.851 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.851 +Problem: Using an empty pattern with :sort silently continues when there is + no previous search pattern. +Solution: Give an error message. +Files: src/ex_cmds.c + + +*** ../vim-7.3.850/src/ex_cmds.c 2013-03-07 16:08:31.000000000 +0100 +--- src/ex_cmds.c 2013-03-07 16:25:28.000000000 +0100 +*************** +*** 415,422 **** + } + *s = NUL; + /* Use last search pattern if sort pattern is empty. */ +! if (s == p + 1 && last_search_pat() != NULL) + regmatch.regprog = vim_regcomp(last_search_pat(), RE_MAGIC); + else + regmatch.regprog = vim_regcomp(p + 1, RE_MAGIC); + if (regmatch.regprog == NULL) +--- 415,429 ---- + } + *s = NUL; + /* Use last search pattern if sort pattern is empty. */ +! if (s == p + 1) +! { +! if (last_search_pat() == NULL) +! { +! EMSG(_(e_noprevre)); +! goto sortend; +! } + regmatch.regprog = vim_regcomp(last_search_pat(), RE_MAGIC); ++ } + else + regmatch.regprog = vim_regcomp(p + 1, RE_MAGIC); + if (regmatch.regprog == NULL) +*** ../vim-7.3.850/src/version.c 2013-03-07 16:32:49.000000000 +0100 +--- src/version.c 2013-03-07 16:38:49.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 851, + /**/ + +-- +This planet has -- or rather had -- a problem, which was this: most +of the people living on it were unhappy for pretty much of the time. +Many solutions were suggested for this problem, but most of these +were largely concerned with the movements of small green pieces of +paper, which is odd because on the whole it wasn't the small green +pieces of paper that were unhappy. + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0c1b460c7ffda39862ec091a14c164887660ec0e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:16 +0200 Subject: [PATCH 0738/3340] - patchlevel 852 --- 7.3.852 | 124 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 124 insertions(+) create mode 100644 7.3.852 diff --git a/7.3.852 b/7.3.852 new file mode 100644 index 00000000..50906577 --- /dev/null +++ b/7.3.852 @@ -0,0 +1,124 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.852 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.852 +Problem: system() breaks clipboard text. (Yukihiro Nakadaira) +Solution: Use Xutf8TextPropertyToTextList(). (Christian Brabandt) + Also do not put the text in the clip buffer if conversion fails. +Files: src/ui.c, src/ops.c + + +*** ../vim-7.3.851/src/ui.c 2012-10-21 00:58:34.000000000 +0200 +--- src/ui.c 2013-03-07 17:30:37.000000000 +0100 +*************** +*** 2119,2125 **** + text_prop.encoding = *type; + text_prop.format = *format; + text_prop.nitems = len; +! status = XmbTextPropertyToTextList(X_DISPLAY, &text_prop, + &text_list, &n_text); + if (status != Success || n_text < 1) + { +--- 2119,2131 ---- + text_prop.encoding = *type; + text_prop.format = *format; + text_prop.nitems = len; +! #ifdef FEAT_MBYTE +! if (*type == utf8_atom) +! status = Xutf8TextPropertyToTextList(X_DISPLAY, &text_prop, +! &text_list, &n_text); +! else +! #endif +! status = XmbTextPropertyToTextList(X_DISPLAY, &text_prop, + &text_list, &n_text); + if (status != Success || n_text < 1) + { +*** ../vim-7.3.851/src/ops.c 2012-12-12 16:11:28.000000000 +0100 +--- src/ops.c 2013-03-07 17:55:59.000000000 +0100 +*************** +*** 5828,5833 **** +--- 5828,5835 ---- + && len < 1024*1024 && len > 0) + { + #ifdef FEAT_MBYTE ++ int ok = TRUE; ++ + /* The CUT_BUFFER0 is supposed to always contain latin1. Convert from + * 'enc' when it is a multi-byte encoding. When 'enc' is an 8-bit + * encoding conversion usually doesn't work, so keep the text as-is. +*************** +*** 5842,5847 **** +--- 5844,5850 ---- + int intlen = len; + char_u *conv_str; + ++ vc.vc_fail = TRUE; + conv_str = string_convert(&vc, str, &intlen); + len = intlen; + if (conv_str != NULL) +*************** +*** 5849,5860 **** + vim_free(str); + str = conv_str; + } + convert_setup(&vc, NULL, NULL); + } + } + #endif +! XStoreBuffer(dpy, (char *)str, (int)len, 0); +! XFlush(dpy); + } + + vim_free(str); +--- 5852,5877 ---- + vim_free(str); + str = conv_str; + } ++ else ++ { ++ ok = FALSE; ++ } + convert_setup(&vc, NULL, NULL); + } ++ else ++ { ++ ok = FALSE; ++ } + } ++ ++ /* Do not store the string if conversion failed. Better to use any ++ * other selection than garbled text. */ ++ if (ok) + #endif +! { +! XStoreBuffer(dpy, (char *)str, (int)len, 0); +! XFlush(dpy); +! } + } + + vim_free(str); +*** ../vim-7.3.851/src/version.c 2013-03-07 16:41:26.000000000 +0100 +--- src/version.c 2013-03-07 18:01:08.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 852, + /**/ + +-- +Tips for aliens in New York: Land anywhere. Central Park, anywhere. +No one will care or indeed even notice. + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ceaab2aead323b60f1b35c557fb9369c5a477772 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:17 +0200 Subject: [PATCH 0739/3340] - patchlevel 853 --- 7.3.853 | 96 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 96 insertions(+) create mode 100644 7.3.853 diff --git a/7.3.853 b/7.3.853 new file mode 100644 index 00000000..6ccb0f4a --- /dev/null +++ b/7.3.853 @@ -0,0 +1,96 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.853 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.853 +Problem: Using "ra" in multiple lines on multi-byte characters leaves a few + characters not replaced. +Solution: Adjust the end column only in the last line. (Yasuhiro Matsumoto) +Files: src/testdir/test69.in, src/testdir/test69.ok, src/ops.c + + +*** ../vim-7.3.852/src/testdir/test69.in 2013-01-17 17:01:57.000000000 +0100 +--- src/testdir/test69.in 2013-03-07 18:30:50.000000000 +0100 +*************** +*** 1,5 **** +--- 1,6 ---- + Test for multi-byte text formatting. + Also test, that 'mps' with multibyte chars works. ++ And test "ra" on multi-byte characters. + + STARTTEST + :so mbyte.vim +*************** +*** 144,149 **** +--- 145,159 ---- + ‘ two three ’ four + } + STARTTEST ++ /^ra test ++ jVjra ++ ENDTEST ++ ++ ra test ++ ï½bbï½ ++ ï½ï½b ++ ++ STARTTEST + :g/^STARTTEST/.,/^ENDTEST/d + :1;/^Results/,$wq! test.out + ENDTEST +*** ../vim-7.3.852/src/testdir/test69.ok 2013-01-17 17:01:57.000000000 +0100 +--- src/testdir/test69.ok 2013-03-07 18:31:32.000000000 +0100 +*************** +*** 144,146 **** +--- 144,151 ---- + { + four + } ++ ++ ra test ++ aaaa ++ aaa ++ +*** ../vim-7.3.852/src/ops.c 2013-03-07 18:02:27.000000000 +0100 +--- src/ops.c 2013-03-07 18:35:01.000000000 +0100 +*************** +*** 2194,2200 **** + { + /* This is slow, but it handles replacing a single-byte + * with a multi-byte and the other way around. */ +! oap->end.col += (*mb_char2len)(c) - (*mb_char2len)(n); + n = State; + State = REPLACE; + ins_char(c); +--- 2194,2201 ---- + { + /* This is slow, but it handles replacing a single-byte + * with a multi-byte and the other way around. */ +! if (curwin->w_cursor.lnum == oap->end.lnum) +! oap->end.col += (*mb_char2len)(c) - (*mb_char2len)(n); + n = State; + State = REPLACE; + ins_char(c); +*** ../vim-7.3.852/src/version.c 2013-03-07 18:02:27.000000000 +0100 +--- src/version.c 2013-03-07 18:36:46.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 853, + /**/ + +-- +What a wonderfully exciting cough! Do you mind if I join you? + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 823a007e5becdc66c8157356d3be6cd839d16aeb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:17 +0200 Subject: [PATCH 0740/3340] - patchlevel 854 --- 7.3.854 | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 7.3.854 diff --git a/7.3.854 b/7.3.854 new file mode 100644 index 00000000..6bc4717f --- /dev/null +++ b/7.3.854 @@ -0,0 +1,49 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.854 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.854 +Problem: After using backspace in insert mode completion, CTRL-N and CTRL-P + do not highlight the right entry. (Olivier Teuliere) +Solution: Set the current item to the shown item after using backspace. +Files: src/edit.c + + +*** ../vim-7.3.853/src/edit.c 2013-02-26 13:30:28.000000000 +0100 +--- src/edit.c 2013-03-07 19:31:46.000000000 +0100 +*************** +*** 3380,3385 **** +--- 3380,3388 ---- + if (compl_leader != NULL) + { + ins_compl_new_leader(); ++ if (compl_shown_match != NULL) ++ /* Make sure current match is not a hidden item. */ ++ compl_curr_match = compl_shown_match; + return NUL; + } + return K_BS; +*** ../vim-7.3.853/src/version.c 2013-03-07 18:50:52.000000000 +0100 +--- src/version.c 2013-03-07 19:34:32.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 854, + /**/ + +-- +If you put 7 of the most talented OSS developers in a room for a week +and asked them to fix a bug in a spreadsheet program, in 1 week +you'd have 2 new mail readers and a text-based web browser. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1983f939aac8f598d561712df4dd2fffbe5b9ff9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:18 +0200 Subject: [PATCH 0741/3340] - patchlevel 855 --- 7.3.855 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.855 diff --git a/7.3.855 b/7.3.855 new file mode 100644 index 00000000..06b315d5 --- /dev/null +++ b/7.3.855 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.855 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.855 +Problem: Compiler warnings. +Solution: Add type casts. (Mike Williams) +Files: src/misc1.c + + +*** ../vim-7.3.854/src/misc1.c 2013-03-07 13:13:45.000000000 +0100 +--- src/misc1.c 2013-03-13 16:58:12.000000000 +0100 +*************** +*** 5468,5474 **** + + for (i = 0; i < (int)(sizeof(skip) / sizeof(char *)); ++i) + { +! l = strlen(skip[i]); + if (cin_starts_with(s, skip[i])) + { + s = cin_skipcomment(s + l); +--- 5468,5474 ---- + + for (i = 0; i < (int)(sizeof(skip) / sizeof(char *)); ++i) + { +! l = (int)strlen(skip[i]); + if (cin_starts_with(s, skip[i])) + { + s = cin_skipcomment(s + l); +*************** +*** 6430,6436 **** + char_u *s; + char *word; + { +! int l = STRLEN(word); + + return (STRNCMP(s, word, l) == 0 && !vim_isIDc(s[l])); + } +--- 6430,6436 ---- + char_u *s; + char *word; + { +! int l = (int)STRLEN(word); + + return (STRNCMP(s, word, l) == 0 && !vim_isIDc(s[l])); + } +*** ../vim-7.3.854/src/version.c 2013-03-07 19:38:49.000000000 +0100 +--- src/version.c 2013-03-13 16:59:02.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 855, + /**/ + +-- +George: "I just got a new set of golf clubs for my wife!" + John: "Great trade!" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9644463c847473505024ab45c432cdced69fc347 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:18 +0200 Subject: [PATCH 0742/3340] - patchlevel 856 --- 7.3.856 | 311 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 311 insertions(+) create mode 100644 7.3.856 diff --git a/7.3.856 b/7.3.856 new file mode 100644 index 00000000..b9f28a47 --- /dev/null +++ b/7.3.856 @@ -0,0 +1,311 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.856 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.856 +Problem: When calling system() multi-byte clipboard contents is garbled. +Solution: Save and restore the clipboard contents. (Yukihiro Nakadaira) +Files: src/gui_gtk_x11.c, src/proto/gui_gtk_x11.pro, src/ops.c, + src/proto/ops.pro, src/os_unix.c, src/proto/ui.pro, src/ui.c + + +*** ../vim-7.3.855/src/gui_gtk_x11.c 2013-02-14 22:11:31.000000000 +0100 +--- src/gui_gtk_x11.c 2013-03-13 17:28:00.000000000 +0100 +*************** +*** 5674,5685 **** + void + clip_mch_lose_selection(VimClipboard *cbd UNUSED) + { +! /* WEIRD: when using NULL to actually disown the selection, we lose the +! * selection the first time we own it. */ +! /* +! gtk_selection_owner_set(NULL, cbd->gtk_sel_atom, (guint32)GDK_CURRENT_TIME); + gui_mch_update(); +- */ + } + + /* +--- 5674,5681 ---- + void + clip_mch_lose_selection(VimClipboard *cbd UNUSED) + { +! gtk_selection_owner_set(NULL, cbd->gtk_sel_atom, gui.event_time); + gui_mch_update(); + } + + /* +*************** +*** 5705,5710 **** +--- 5701,5712 ---- + { + } + ++ int ++ clip_gtk_owner_exists(VimClipboard *cbd) ++ { ++ return gdk_selection_owner_get(cbd->gtk_sel_atom) != NULL; ++ } ++ + + #if defined(FEAT_MENU) || defined(PROTO) + /* +*** ../vim-7.3.855/src/proto/gui_gtk_x11.pro 2012-05-18 17:03:14.000000000 +0200 +--- src/proto/gui_gtk_x11.pro 2013-03-13 17:35:17.000000000 +0100 +*************** +*** 59,64 **** +--- 59,65 ---- + void clip_mch_lose_selection __ARGS((VimClipboard *cbd)); + int clip_mch_own_selection __ARGS((VimClipboard *cbd)); + void clip_mch_set_selection __ARGS((VimClipboard *cbd)); ++ int clip_gtk_owner_exists __ARGS((VimClipboard *cbd)); + void gui_mch_menu_grey __ARGS((vimmenu_T *menu, int grey)); + void gui_mch_menu_hidden __ARGS((vimmenu_T *menu, int hidden)); + void gui_mch_draw_menubar __ARGS((void)); +*** ../vim-7.3.855/src/ops.c 2013-03-07 18:50:52.000000000 +0100 +--- src/ops.c 2013-03-13 17:30:50.000000000 +0100 +*************** +*** 1017,1022 **** +--- 1017,1035 ---- + may_set_selection(); + # endif + } ++ ++ void ++ free_register(reg) ++ void *reg; ++ { ++ struct yankreg tmp; ++ ++ tmp = *y_current; ++ *y_current = *(struct yankreg *)reg; ++ free_yank_all(); ++ vim_free(reg); ++ *y_current = tmp; ++ } + #endif + + #if defined(FEAT_MOUSE) || defined(PROTO) +*** ../vim-7.3.855/src/proto/ops.pro 2012-06-06 16:12:54.000000000 +0200 +--- src/proto/ops.pro 2013-03-13 17:35:04.000000000 +0100 +*************** +*** 15,20 **** +--- 15,21 ---- + int may_get_selection __ARGS((int regname)); + void *get_register __ARGS((int name, int copy)); + void put_register __ARGS((int name, void *reg)); ++ void free_register __ARGS((void *reg)); + int yank_register_mline __ARGS((int regname)); + int do_record __ARGS((int c)); + int do_execreg __ARGS((int regname, int colon, int addcr, int silent)); +*** ../vim-7.3.855/src/os_unix.c 2013-02-26 14:56:24.000000000 +0100 +--- src/os_unix.c 2013-03-13 17:33:00.000000000 +0100 +*************** +*** 1138,1143 **** +--- 1138,1148 ---- + + # if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) + static void loose_clipboard __ARGS((void)); ++ static void save_clipboard __ARGS((void)); ++ static void restore_clipboard __ARGS((void)); ++ ++ static void *clip_star_save = NULL; ++ static void *clip_plus_save = NULL; + + /* + * Called when Vim is going to sleep or execute a shell command. +*************** +*** 1158,1163 **** +--- 1163,1204 ---- + XFlush(x11_display); + } + } ++ ++ /* ++ * Save clipboard text to restore later. ++ */ ++ static void ++ save_clipboard() ++ { ++ if (clip_star.owned) ++ clip_star_save = get_register('*', TRUE); ++ if (clip_plus.owned) ++ clip_plus_save = get_register('+', TRUE); ++ } ++ ++ /* ++ * Restore clipboard text if no one own the X selection. ++ */ ++ static void ++ restore_clipboard() ++ { ++ if (clip_star_save != NULL) ++ { ++ if (!clip_gen_owner_exists(&clip_star)) ++ put_register('*', clip_star_save); ++ else ++ free_register(clip_star_save); ++ clip_star_save = NULL; ++ } ++ if (clip_plus_save != NULL) ++ { ++ if (!clip_gen_owner_exists(&clip_plus)) ++ put_register('+', clip_plus_save); ++ else ++ free_register(clip_plus_save); ++ clip_plus_save = NULL; ++ } ++ } + #endif + + /* +*************** +*** 3844,3849 **** +--- 3885,3891 ---- + settmode(TMODE_COOK); /* set to normal mode */ + + # if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) ++ save_clipboard(); + loose_clipboard(); + # endif + +*************** +*** 3917,3922 **** +--- 3959,3967 ---- + # ifdef FEAT_TITLE + resettitle(); + # endif ++ # if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) ++ restore_clipboard(); ++ # endif + return x; + + #else /* USE_SYSTEM */ /* don't use system(), use fork()/exec() */ +*************** +*** 3965,3970 **** +--- 4010,4018 ---- + settmode(TMODE_COOK); /* set to normal mode */ + + # if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) ++ /* Disown the clipboard, because is the executed command tries to obtain a ++ * selection and we own it we get a deadlock. */ ++ save_clipboard(); + loose_clipboard(); + # endif + +*************** +*** 4836,4841 **** +--- 4884,4892 ---- + # ifdef FEAT_TITLE + resettitle(); + # endif ++ # if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) ++ restore_clipboard(); ++ # endif + vim_free(newcmd); + + return retval; +*** ../vim-7.3.855/src/proto/ui.pro 2012-07-10 16:49:08.000000000 +0200 +--- src/proto/ui.pro 2013-03-13 17:35:08.000000000 +0100 +*************** +*** 29,34 **** +--- 29,35 ---- + void clip_gen_lose_selection __ARGS((VimClipboard *cbd)); + void clip_gen_set_selection __ARGS((VimClipboard *cbd)); + void clip_gen_request_selection __ARGS((VimClipboard *cbd)); ++ int clip_gen_owner_exists __ARGS((VimClipboard *cbd)); + int vim_is_input_buf_full __ARGS((void)); + int vim_is_input_buf_empty __ARGS((void)); + int vim_free_in_input_buf __ARGS((void)); +*************** +*** 52,57 **** +--- 53,59 ---- + void clip_x11_lose_selection __ARGS((Widget myShell, VimClipboard *cbd)); + int clip_x11_own_selection __ARGS((Widget myShell, VimClipboard *cbd)); + void clip_x11_set_selection __ARGS((VimClipboard *cbd)); ++ int clip_x11_owner_exists __ARGS((VimClipboard *cbd)); + void yank_cut_buffer0 __ARGS((Display *dpy, VimClipboard *cbd)); + int jump_to_mouse __ARGS((int flags, int *inclusive, int which_button)); + int mouse_comp_pos __ARGS((win_T *win, int *rowp, int *colp, linenr_T *lnump)); +*** ../vim-7.3.855/src/ui.c 2013-03-07 18:02:27.000000000 +0100 +--- src/ui.c 2013-03-13 17:31:31.000000000 +0100 +*************** +*** 1456,1461 **** +--- 1456,1476 ---- + #endif + } + ++ int ++ clip_gen_owner_exists(cbd) ++ VimClipboard *cbd; ++ { ++ #ifdef FEAT_XCLIPBOARD ++ # ifdef FEAT_GUI_GTK ++ if (gui.in_use) ++ return clip_gtk_owner_exists(cbd); ++ else ++ # endif ++ return clip_x11_owner_exists(cbd); ++ #endif ++ return TRUE; ++ } ++ + #endif /* FEAT_CLIPBOARD */ + + /***************************************************************************** +*************** +*** 2398,2404 **** + Widget myShell; + VimClipboard *cbd; + { +! XtDisownSelection(myShell, cbd->sel_atom, CurrentTime); + } + + int +--- 2413,2420 ---- + Widget myShell; + VimClipboard *cbd; + { +! XtDisownSelection(myShell, cbd->sel_atom, +! XtLastTimestampProcessed(XtDisplay(myShell))); + } + + int +*************** +*** 2440,2445 **** +--- 2456,2468 ---- + VimClipboard *cbd UNUSED; + { + } ++ ++ int ++ clip_x11_owner_exists(cbd) ++ VimClipboard *cbd; ++ { ++ return XGetSelectionOwner(X_DISPLAY, cbd->sel_atom) != None; ++ } + #endif + + #if defined(FEAT_XCLIPBOARD) || defined(FEAT_GUI_X11) \ +*** ../vim-7.3.855/src/version.c 2013-03-13 17:01:47.000000000 +0100 +--- src/version.c 2013-03-13 17:45:25.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 856, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +39. You move into a new house and decide to Netscape before you landscape. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ce9b31f8a388dc44d283f0e65ba39f8c91424b06 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:19 +0200 Subject: [PATCH 0743/3340] - patchlevel 857 --- 7.3.857 | 91 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 91 insertions(+) create mode 100644 7.3.857 diff --git a/7.3.857 b/7.3.857 new file mode 100644 index 00000000..1c3ca8c5 --- /dev/null +++ b/7.3.857 @@ -0,0 +1,91 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.857 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.857 +Problem: The QuitPre autocommand event does not trigger for :qa and :wq. +Solution: Trigger the event. (Tatsuro Fujii) +Files: src/ex_docmd.c + + +*** ../vim-7.3.856/src/ex_docmd.c 2013-02-26 17:21:15.000000000 +0100 +--- src/ex_docmd.c 2013-03-13 18:14:56.000000000 +0100 +*************** +*** 6526,6532 **** + } + #ifdef FEAT_AUTOCMD + apply_autocmds(EVENT_QUITPRE, NULL, NULL, FALSE, curbuf); +! /* Refuse to quick when locked or when the buffer in the last window is + * being closed (can only happen in autocommands). */ + if (curbuf_locked() || (curbuf->b_nwindows == 1 && curbuf->b_closing)) + return; +--- 6526,6532 ---- + } + #ifdef FEAT_AUTOCMD + apply_autocmds(EVENT_QUITPRE, NULL, NULL, FALSE, curbuf); +! /* Refuse to quit when locked or when the buffer in the last window is + * being closed (can only happen in autocommands). */ + if (curbuf_locked() || (curbuf->b_nwindows == 1 && curbuf->b_closing)) + return; +*************** +*** 6600,6606 **** + return; + } + #ifdef FEAT_AUTOCMD +! if (curbuf_locked()) + return; + #endif + +--- 6600,6609 ---- + return; + } + #ifdef FEAT_AUTOCMD +! apply_autocmds(EVENT_QUITPRE, NULL, NULL, FALSE, curbuf); +! /* Refuse to quit when locked or when the buffer in the last window is +! * being closed (can only happen in autocommands). */ +! if (curbuf_locked() || (curbuf->b_nwindows == 1 && curbuf->b_closing)) + return; + #endif + +*************** +*** 6936,6942 **** + return; + } + #ifdef FEAT_AUTOCMD +! if (curbuf_locked()) + return; + #endif + +--- 6939,6948 ---- + return; + } + #ifdef FEAT_AUTOCMD +! apply_autocmds(EVENT_QUITPRE, NULL, NULL, FALSE, curbuf); +! /* Refuse to quit when locked or when the buffer in the last window is +! * being closed (can only happen in autocommands). */ +! if (curbuf_locked() || (curbuf->b_nwindows == 1 && curbuf->b_closing)) + return; + #endif + +*** ../vim-7.3.856/src/version.c 2013-03-13 17:50:20.000000000 +0100 +--- src/version.c 2013-03-13 18:26:13.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 857, + /**/ + +-- +The future isn't what it used to be. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9716d7cd8839ce9863d05b9d706caa810746360f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:20 +0200 Subject: [PATCH 0744/3340] - patchlevel 858 --- 7.3.858 | 159 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 159 insertions(+) create mode 100644 7.3.858 diff --git a/7.3.858 b/7.3.858 new file mode 100644 index 00000000..a03c0158 --- /dev/null +++ b/7.3.858 @@ -0,0 +1,159 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.858 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.858 +Problem: "gv" selects the wrong area after some operators. +Solution: Save and restore the type of selection. (Christian Brabandt) +Files: src/testdir/test66.in, src/testdir/test66.ok, src/normal.c + + +*** ../vim-7.3.857/src/testdir/test66.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test66.in 2013-03-13 18:42:46.000000000 +0100 +*************** +*** 3,14 **** + + STARTTEST + :so small.vim + /^abcdefgh + 4jI j<<11|D + 7|a  + 7|a  + 7|a 4k13|4j< +! :$-4,$w! test.out + :$-4,$s/\s\+//g + 4kI j<< + 7|a  +--- 3,16 ---- + + STARTTEST + :so small.vim ++ /^one ++ fe4jRugvr1:'<,'>w! test.out + /^abcdefgh + 4jI j<<11|D + 7|a  + 7|a  + 7|a 4k13|4j< +! :$-5,$w >> test.out + :$-4,$s/\s\+//g + 4kI j<< + 7|a  +*************** +*** 18,23 **** +--- 20,31 ---- + :qa! + ENDTEST + ++ one two three ++ one two three ++ one two three ++ one two three ++ one two three ++ + abcdefghijklmnopqrstuvwxyz + abcdefghijklmnopqrstuvwxyz + abcdefghijklmnopqrstuvwxyz +*** ../vim-7.3.857/src/testdir/test66.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test66.ok 2013-03-13 18:42:46.000000000 +0100 +*************** +*** 1,3 **** +--- 1,9 ---- ++ on1 two three ++ on1 two three ++ on1 two three ++ on1 two three ++ on1 two three ++ + abcdefghijklmnopqrstuvwxyz + abcdefghij + abc defghijklmnopqrstuvwxyz +*** ../vim-7.3.857/src/normal.c 2013-02-26 13:30:28.000000000 +0100 +--- src/normal.c 2013-03-13 18:47:49.000000000 +0100 +*************** +*** 21,26 **** +--- 21,27 ---- + static int resel_VIsual_mode = NUL; /* 'v', 'V', or Ctrl-V */ + static linenr_T resel_VIsual_line_count; /* number of lines */ + static colnr_T resel_VIsual_vcol; /* nr of cols or end col */ ++ static int VIsual_mode_orig = NUL; /* type of Visual mode, that user entered */ + + static int restart_VIsual_select = 0; + #endif +*************** +*** 1594,1599 **** +--- 1595,1605 ---- + curbuf->b_visual.vi_start = VIsual; + curbuf->b_visual.vi_end = curwin->w_cursor; + curbuf->b_visual.vi_mode = VIsual_mode; ++ if (VIsual_mode_orig != NUL) ++ { ++ curbuf->b_visual.vi_mode = VIsual_mode_orig; ++ VIsual_mode_orig = NUL; ++ } + curbuf->b_visual.vi_curswant = curwin->w_curswant; + # ifdef FEAT_EVAL + curbuf->b_visual_mode_eval = VIsual_mode; +*************** +*** 7230,7235 **** +--- 7236,7242 ---- + { + cap->cmdchar = 'c'; + cap->nchar = NUL; ++ VIsual_mode_orig = VIsual_mode; /* remember original area for gv */ + VIsual_mode = 'V'; + nv_operator(cap); + } +*************** +*** 7429,7435 **** +--- 7436,7445 ---- + if (isupper(cap->cmdchar)) + { + if (VIsual_mode != Ctrl_V) ++ { ++ VIsual_mode_orig = VIsual_mode; + VIsual_mode = 'V'; ++ } + else if (cap->cmdchar == 'C' || cap->cmdchar == 'D') + curwin->w_curswant = MAXCOL; + } +*************** +*** 7449,7455 **** +--- 7459,7468 ---- + if (VIsual_active) /* "vs" and "vS" are the same as "vc" */ + { + if (cap->cmdchar == 'S') ++ { ++ VIsual_mode_orig = VIsual_mode; + VIsual_mode = 'V'; ++ } + cap->cmdchar = 'c'; + nv_operator(cap); + } +*** ../vim-7.3.857/src/version.c 2013-03-13 18:30:39.000000000 +0100 +--- src/version.c 2013-03-13 18:48:50.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 858, + /**/ + +-- +"Oh, no! NOT the Spanish Inquisition!" +"NOBODY expects the Spanish Inquisition!!!" + -- Monty Python sketch -- +"Oh, no! NOT another option!" +"EVERYBODY expects another option!!!" + -- Discussion in vim-dev mailing list -- + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 599fe65eec33ad5a6d730ae1a9cca22839704d3a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:20 +0200 Subject: [PATCH 0745/3340] - patchlevel 859 --- 7.3.859 | 316 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 316 insertions(+) create mode 100644 7.3.859 diff --git a/7.3.859 b/7.3.859 new file mode 100644 index 00000000..e1714c4b --- /dev/null +++ b/7.3.859 @@ -0,0 +1,316 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.859 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.859 +Problem: 'ambiwidth' must be set by the user. +Solution: Detects East Asian ambiguous width (UAX #11) state of the terminal + at the start-up time and 'ambiwidth' accordingly. (Hayaki Saito) +Files: src/main.c, src/option.c, src/term.c, src/term.h, + src/proto/term.pro + + +*** ../vim-7.3.858/src/main.c 2013-01-17 13:59:56.000000000 +0100 +--- src/main.c 2013-03-13 19:09:03.000000000 +0100 +*************** +*** 804,809 **** +--- 804,812 ---- + + starttermcap(); /* start termcap if not done by wait_return() */ + TIME_MSG("start termcap"); ++ #if defined(FEAT_TERMRESPONSE) && defined(FEAT_MBYTE) ++ may_req_ambiguous_character_width(); ++ #endif + + #ifdef FEAT_MOUSE + setmouse(); /* may start using the mouse */ +*** ../vim-7.3.858/src/option.c 2013-02-13 15:44:22.000000000 +0100 +--- src/option.c 2013-03-13 19:09:03.000000000 +0100 +*************** +*** 2900,2905 **** +--- 2900,2906 ---- + p_term("t_op", T_OP) + p_term("t_RI", T_CRI) + p_term("t_RV", T_CRV) ++ p_term("t_u7", T_U7) + p_term("t_Sb", T_CSB) + p_term("t_Sf", T_CSF) + p_term("t_se", T_SE) +*** ../vim-7.3.858/src/term.c 2013-02-26 14:56:24.000000000 +0100 +--- src/term.c 2013-03-13 19:18:22.000000000 +0100 +*************** +*** 111,116 **** +--- 111,121 ---- + # define CRV_SENT 2 /* did send T_CRV, waiting for answer */ + # define CRV_GOT 3 /* received T_CRV response */ + static int crv_status = CRV_GET; ++ /* Request Cursor position report: */ ++ # define U7_GET 1 /* send T_U7 when switched to RAW mode */ ++ # define U7_SENT 2 /* did send T_U7, waiting for answer */ ++ # define U7_GOT 3 /* received T_U7 response */ ++ static int u7_status = U7_GET; + # endif + + /* +*************** +*** 933,938 **** +--- 938,944 ---- + {(int)KS_CWP, IF_EB("\033[3;%d;%dt", ESC_STR "[3;%d;%dt")}, + # endif + {(int)KS_CRV, IF_EB("\033[>c", ESC_STR "[>c")}, ++ {(int)KS_U7, IF_EB("\033[6n", ESC_STR "[6n")}, + + {K_UP, IF_EB("\033O*A", ESC_STR "O*A")}, + {K_DOWN, IF_EB("\033O*B", ESC_STR "O*B")}, +*************** +*** 1221,1226 **** +--- 1227,1233 ---- + {(int)KS_CWP, "[%dCWP%d]"}, + # endif + {(int)KS_CRV, "[CRV]"}, ++ {(int)KS_U7, "[U7]"}, + {K_UP, "[KU]"}, + {K_DOWN, "[KD]"}, + {K_LEFT, "[KL]"}, +*************** +*** 1596,1601 **** +--- 1603,1609 ---- + {KS_TS, "ts"}, {KS_FS, "fs"}, + {KS_CWP, "WP"}, {KS_CWS, "WS"}, + {KS_CSI, "SI"}, {KS_CEI, "EI"}, ++ {KS_U7, "u7"}, + {(enum SpecialKey)0, NULL} + }; + +*************** +*** 3183,3189 **** + /* May need to check for T_CRV response and termcodes, it + * doesn't work in Cooked mode, an external program may get + * them. */ +! if (tmode != TMODE_RAW && crv_status == CRV_SENT) + (void)vpeekc_nomap(); + check_for_codes_from_term(); + } +--- 3191,3198 ---- + /* May need to check for T_CRV response and termcodes, it + * doesn't work in Cooked mode, an external program may get + * them. */ +! if (tmode != TMODE_RAW && (crv_status == CRV_SENT +! || u7_status == U7_SENT)) + (void)vpeekc_nomap(); + check_for_codes_from_term(); + } +*************** +*** 3245,3251 **** + # endif + { + /* May need to check for T_CRV response. */ +! if (crv_status == CRV_SENT) + (void)vpeekc_nomap(); + /* Check for termcodes first, otherwise an external program may + * get them. */ +--- 3254,3260 ---- + # endif + { + /* May need to check for T_CRV response. */ +! if (crv_status == CRV_SENT || u7_status == U7_SENT) + (void)vpeekc_nomap(); + /* Check for termcodes first, otherwise an external program may + * get them. */ +*************** +*** 3299,3304 **** +--- 3308,3355 ---- + (void)vpeekc_nomap(); + } + } ++ ++ # if defined(FEAT_MBYTE) || defined(PROTO) ++ /* ++ * Check how the terminal treats ambiguous character width (UAX #11). ++ * First, we move the cursor to (0, 0) and print a test ambiguous character ++ * \u25bd (WHITE DOWN-POINTING TRIANGLE) and query current cursor position. ++ * If the terminal treats \u25bd as single width, the position is (0, 1), ++ * or if it is treated as double width, that will be (0, 2). ++ * This function has the side effect that changes cursor position, so ++ * it must be called immediately after entering termcap mode. ++ */ ++ void ++ may_req_ambiguous_character_width() ++ { ++ if (u7_status == U7_GET ++ && cur_tmode == TMODE_RAW ++ && termcap_active ++ && p_ek ++ # ifdef UNIX ++ && isatty(1) ++ && isatty(read_cmd_fd) ++ # endif ++ && *T_U7 != NUL ++ && !option_was_set((char_u *)"ambiwidth")) ++ { ++ char_u buf[16]; ++ ++ term_windgoto(0, 0); ++ buf[mb_char2bytes(0x25bd, buf)] = 0; ++ out_str(buf); ++ out_str(T_U7); ++ u7_status = U7_SENT; ++ term_windgoto(0, 0); ++ out_str((char_u *)" "); ++ term_windgoto(0, 0); ++ /* check for the characters now, otherwise they might be eaten by ++ * get_keystroke() */ ++ out_flush(); ++ (void)vpeekc_nomap(); ++ } ++ } ++ # endif + #endif + + /* +*************** +*** 4049,4061 **** + /* URXVT mouse uses [#;#;#M, but we are matching [ */ + || key_name[0] == KS_URXVT_MOUSE) + { +! /* Check for xterm version string: "[>{x};{vers};{y}c". Also +! * eat other possible responses to t_RV, rxvt returns +! * "[?1;2c". Also accept CSI instead of [. +! * mrxvt has been reported to have "+" in the version. Assume +! * the escape sequence ends with a letter or one of "{|}~". */ +! if (*T_CRV != NUL && ((tp[0] == ESC && tp[1] == '[' && len >= 3) +! || (tp[0] == CSI && len >= 2))) + { + j = 0; + extra = 0; +--- 4100,4121 ---- + /* URXVT mouse uses [#;#;#M, but we are matching [ */ + || key_name[0] == KS_URXVT_MOUSE) + { +! /* Check for some responses from terminal start with "[" or +! * CSI. +! * +! * - xterm version string: [>{x};{vers};{y}c +! * Also eat other possible responses to t_RV, rxvt returns +! * "[?1;2c". Also accept CSI instead of [. +! * mrxvt has been reported to have "+" in the version. Assume +! * the escape sequence ends with a letter or one of "{|}~". +! * +! * - cursor position report: [{row};{col}R +! * The final byte is 'R'. now it is only used for checking for +! * ambiguous-width character state. +! */ +! if ((*T_CRV != NUL || *T_U7 != NUL) +! && ((tp[0] == ESC && tp[1] == '[' && len >= 3) +! || (tp[0] == CSI && len >= 2))) + { + j = 0; + extra = 0; +*************** +*** 4067,4074 **** + if (i == len) + return -1; /* not enough characters */ + + /* eat it when at least one digit and ending in 'c' */ +! if (i > 2 + (tp[0] != CSI) && tp[i] == 'c') + { + crv_status = CRV_GOT; + +--- 4127,4153 ---- + if (i == len) + return -1; /* not enough characters */ + ++ #ifdef FEAT_MBYTE ++ /* eat it when it has 2 arguments and ends in 'R' */ ++ if (u7_status == U7_SENT && j == 1 && tp[i] == 'R') ++ { ++ char *p = NULL; ++ ++ u7_status = U7_GOT; ++ if (extra == 2) ++ p = "single"; ++ else if (extra == 3) ++ p = "double"; ++ if (p != NULL) ++ set_option_value((char_u *)"ambw", 0L, (char_u *)p, 0); ++ key_name[0] = (int)KS_EXTRA; ++ key_name[1] = (int)KE_IGNORE; ++ slen = i + 1; ++ } ++ else ++ #endif + /* eat it when at least one digit and ending in 'c' */ +! if (*T_CRV != NUL && i > 2 + (tp[0] != CSI) && tp[i] == 'c') + { + crv_status = CRV_GOT; + +*** ../vim-7.3.858/src/term.h 2010-08-15 21:57:25.000000000 +0200 +--- src/term.h 2013-03-13 19:09:03.000000000 +0100 +*************** +*** 83,92 **** + #ifdef FEAT_VERTSPLIT + KS_CSV, /* scroll region vertical */ + #endif +! KS_OP /* original color pair */ + }; + +! #define KS_LAST KS_OP + + /* + * the terminal capabilities are stored in this array +--- 83,93 ---- + #ifdef FEAT_VERTSPLIT + KS_CSV, /* scroll region vertical */ + #endif +! KS_OP, /* original color pair */ +! KS_U7 /* request cursor position */ + }; + +! #define KS_LAST KS_U7 + + /* + * the terminal capabilities are stored in this array +*************** +*** 158,163 **** +--- 159,165 ---- + #define T_CEI (term_str(KS_CEI)) /* end insert mode */ + #define T_CRV (term_str(KS_CRV)) /* request version string */ + #define T_OP (term_str(KS_OP)) /* original color pair */ ++ #define T_U7 (term_str(KS_U7)) /* request cursor position */ + + #define TMODE_COOK 0 /* terminal mode for external cmds and Ex mode */ + #define TMODE_SLEEP 1 /* terminal mode for sleeping (cooked but no echo) */ +*** ../vim-7.3.858/src/proto/term.pro 2012-02-05 22:05:44.000000000 +0100 +--- src/proto/term.pro 2013-03-13 19:09:54.000000000 +0100 +*************** +*** 34,39 **** +--- 34,40 ---- + void starttermcap __ARGS((void)); + void stoptermcap __ARGS((void)); + void may_req_termresponse __ARGS((void)); ++ void may_req_ambiguous_character_width __ARGS((void)); + int swapping_screen __ARGS((void)); + void setmouse __ARGS((void)); + int mouse_has __ARGS((int c)); +*** ../vim-7.3.858/src/version.c 2013-03-13 19:02:37.000000000 +0100 +--- src/version.c 2013-03-13 19:27:31.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 859, + /**/ + +-- +Microsoft is to software what McDonalds is to gourmet cooking + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 13d1cd872af463a041745c574af6372b016122ab Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:21 +0200 Subject: [PATCH 0746/3340] - patchlevel 860 --- 7.3.860 | 85 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100644 7.3.860 diff --git a/7.3.860 b/7.3.860 new file mode 100644 index 00000000..fbcab261 --- /dev/null +++ b/7.3.860 @@ -0,0 +1,85 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.860 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.860 +Problem: When using --remote-expr try/catch does not work. (Andrey Radev) +Solution: Set emsg_silent instead of emsg_skip. +Files: src/main.c + + +*** ../vim-7.3.859/src/main.c 2013-03-13 19:29:24.000000000 +0100 +--- src/main.c 2013-03-13 19:46:03.000000000 +0100 +*************** +*** 4025,4032 **** + + /* + * Evaluate an expression that the client sent to a string. +- * Handles disabling error messages and disables debugging, otherwise Vim +- * hangs, waiting for "cont" to be typed. + */ + char_u * + eval_client_expr_to_string(expr) +--- 4025,4030 ---- +*************** +*** 4036,4050 **** + int save_dbl = debug_break_level; + int save_ro = redir_off; + + debug_break_level = -1; + redir_off = 0; +! ++emsg_skip; + + res = eval_to_string(expr, NULL, TRUE); + + debug_break_level = save_dbl; + redir_off = save_ro; +! --emsg_skip; + + /* A client can tell us to redraw, but not to display the cursor, so do + * that here. */ +--- 4034,4054 ---- + int save_dbl = debug_break_level; + int save_ro = redir_off; + ++ /* Disable debugging, otherwise Vim hangs, waiting for "cont" to be ++ * typed. */ + debug_break_level = -1; + redir_off = 0; +! /* Do not display error message, otherwise Vim hangs, waiting for "cont" +! * to be typed. Do generate errors so that try/catch works. */ +! ++emsg_silent; + + res = eval_to_string(expr, NULL, TRUE); + + debug_break_level = save_dbl; + redir_off = save_ro; +! --emsg_silent; +! if (emsg_silent < 0) +! emsg_silent = 0; + + /* A client can tell us to redraw, but not to display the cursor, so do + * that here. */ +*** ../vim-7.3.859/src/version.c 2013-03-13 19:29:24.000000000 +0100 +--- src/version.c 2013-03-13 20:09:47.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 860, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +42. Your virtual girlfriend finds a new net sweetheart with a larger bandwidth. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ee4e8f4f3a87ddf33f2eea8281c6ff97939d0491 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:22 +0200 Subject: [PATCH 0747/3340] - patchlevel 861 --- 7.3.861 | 165 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 165 insertions(+) create mode 100644 7.3.861 diff --git a/7.3.861 b/7.3.861 new file mode 100644 index 00000000..aa91d583 --- /dev/null +++ b/7.3.861 @@ -0,0 +1,165 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.861 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.861 +Problem: ":setlocal number" clears global value of 'relativenumber'. +Solution: Do it properly. (Markus Heidelberg) +Files: src/testdir/test89.in, src/testdir/test89.ok, src/option.c + + +*** ../vim-7.3.860/src/testdir/test89.in 2013-02-14 20:10:28.000000000 +0100 +--- src/testdir/test89.in 2013-03-13 20:27:10.000000000 +0100 +*************** +*** 10,15 **** +--- 10,52 ---- + :$put ='results:' + :$put a + :$put b ++ :" ++ :set nonu nornu ++ :setglobal nu ++ :setlocal rnu ++ :redir @c | setglobal nu? | redir END ++ :set nonu nornu ++ :setglobal rnu ++ :setlocal nu ++ :redir @d | setglobal rnu? | redir END ++ :$put =':setlocal must NOT reset the other global value' ++ :$put c ++ :$put d ++ :" ++ :set nonu nornu ++ :setglobal nu ++ :setglobal rnu ++ :redir @e | setglobal nu? | redir END ++ :set nonu nornu ++ :setglobal rnu ++ :setglobal nu ++ :redir @f | setglobal rnu? | redir END ++ :$put =':setglobal MUST reset the other global value' ++ :$put e ++ :$put f ++ :" ++ :set nonu nornu ++ :set nu ++ :set rnu ++ :redir @g | setglobal nu? | redir END ++ :set nonu nornu ++ :set rnu ++ :set nu ++ :redir @h | setglobal rnu? | redir END ++ :$put =':set MUST reset the other global value' ++ :$put g ++ :$put h ++ :" + :/^results/,$w! test.out + :q! + ENDTEST +*** ../vim-7.3.860/src/testdir/test89.ok 2013-02-13 15:44:22.000000000 +0100 +--- src/testdir/test89.ok 2013-03-13 20:27:10.000000000 +0100 +*************** +*** 5,7 **** +--- 5,22 ---- + + nonumber + relativenumber ++ :setlocal must NOT reset the other global value ++ ++ number ++ ++ relativenumber ++ :setglobal MUST reset the other global value ++ ++ nonumber ++ ++ norelativenumber ++ :set MUST reset the other global value ++ ++ nonumber ++ ++ norelativenumber +*** ../vim-7.3.860/src/option.c 2013-03-13 19:29:24.000000000 +0100 +--- src/option.c 2013-03-13 20:35:20.000000000 +0100 +*************** +*** 7631,7652 **** + } + #endif + +! /* 'number', 'relativenumber' */ +! else if ((int *)varp == &curwin->w_p_nu +! || (int *)varp == &curwin->w_p_rnu) + { +! /* If 'number' is set, reset 'relativenumber'. */ +! /* If 'relativenumber' is set, reset 'number'. */ +! if ((int *)varp == &curwin->w_p_nu && curwin->w_p_nu) +! { +! curwin->w_p_rnu = FALSE; + curwin->w_allbuf_opt.wo_rnu = FALSE; +! } +! if ((int *)varp == &curwin->w_p_rnu && curwin->w_p_rnu) +! { +! curwin->w_p_nu = FALSE; + curwin->w_allbuf_opt.wo_nu = FALSE; +! } + } + + else if ((int *)varp == &curbuf->b_p_ro) +--- 7631,7663 ---- + } + #endif + +! /* If 'number' is set, reset 'relativenumber'. */ +! /* If 'relativenumber' is set, reset 'number'. */ +! else if ((int *)varp == &curwin->w_p_nu && curwin->w_p_nu) + { +! curwin->w_p_rnu = FALSE; +! +! /* Only reset the global value if the own value is set globally. */ +! if (((opt_flags & (OPT_LOCAL | OPT_GLOBAL)) == 0)) + curwin->w_allbuf_opt.wo_rnu = FALSE; +! } +! else if ((int *)varp == &curwin->w_p_rnu && curwin->w_p_rnu) +! { +! curwin->w_p_nu = FALSE; +! +! /* Only reset the global value if the own value is set globally. */ +! if (((opt_flags & (OPT_LOCAL | OPT_GLOBAL)) == 0)) + curwin->w_allbuf_opt.wo_nu = FALSE; +! } +! else if ((int *)varp == &curwin->w_allbuf_opt.wo_nu +! && curwin->w_allbuf_opt.wo_nu) +! { +! curwin->w_allbuf_opt.wo_rnu = FALSE; +! } +! else if ((int *)varp == &curwin->w_allbuf_opt.wo_rnu +! && curwin->w_allbuf_opt.wo_rnu) +! { +! curwin->w_allbuf_opt.wo_nu = FALSE; + } + + else if ((int *)varp == &curbuf->b_p_ro) +*** ../vim-7.3.860/src/version.c 2013-03-13 20:23:17.000000000 +0100 +--- src/version.c 2013-03-13 20:42:09.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 861, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +43. You tell the kids they can't use the computer because "Daddy's got work to + do" and you don't even have a job. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6e5bc62eae8576a7111350b200d362031a8ebcbb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:22 +0200 Subject: [PATCH 0748/3340] - patchlevel 862 --- 7.3.862 | 215 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 215 insertions(+) create mode 100644 7.3.862 diff --git a/7.3.862 b/7.3.862 new file mode 100644 index 00000000..3ad18363 --- /dev/null +++ b/7.3.862 @@ -0,0 +1,215 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.862 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.862 +Problem: Dragging the status line can be slow. +Solution: Look ahead and drop the drag event if there is a next one. +Files: src/eval.c, src/misc1.c, src/proto/misc1.pro, src/normal.c + + +*** ../vim-7.3.861/src/eval.c 2013-02-26 21:43:28.000000000 +0100 +--- src/eval.c 2013-03-16 14:02:36.000000000 +0100 +*************** +*** 11238,11264 **** + rettv->vval.v_string = vim_strsave(temp); + + #ifdef FEAT_MOUSE +! if (n == K_LEFTMOUSE +! || n == K_LEFTMOUSE_NM +! || n == K_LEFTDRAG +! || n == K_LEFTRELEASE +! || n == K_LEFTRELEASE_NM +! || n == K_MIDDLEMOUSE +! || n == K_MIDDLEDRAG +! || n == K_MIDDLERELEASE +! || n == K_RIGHTMOUSE +! || n == K_RIGHTDRAG +! || n == K_RIGHTRELEASE +! || n == K_X1MOUSE +! || n == K_X1DRAG +! || n == K_X1RELEASE +! || n == K_X2MOUSE +! || n == K_X2DRAG +! || n == K_X2RELEASE +! || n == K_MOUSELEFT +! || n == K_MOUSERIGHT +! || n == K_MOUSEDOWN +! || n == K_MOUSEUP) + { + int row = mouse_row; + int col = mouse_col; +--- 11238,11244 ---- + rettv->vval.v_string = vim_strsave(temp); + + #ifdef FEAT_MOUSE +! if (is_mouse_key(n)) + { + int row = mouse_row; + int col = mouse_col; +*** ../vim-7.3.861/src/misc1.c 2013-03-13 17:01:47.000000000 +0100 +--- src/misc1.c 2013-03-16 14:08:05.000000000 +0100 +*************** +*** 3288,3293 **** +--- 3288,3325 ---- + return r; + } + ++ #if defined(FEAT_MOUSE) || defined(PROTO) ++ /* ++ * Return TRUE if "c" is a mouse key. ++ */ ++ int ++ is_mouse_key(c) ++ int c; ++ { ++ return c == K_LEFTMOUSE ++ || c == K_LEFTMOUSE_NM ++ || c == K_LEFTDRAG ++ || c == K_LEFTRELEASE ++ || c == K_LEFTRELEASE_NM ++ || c == K_MIDDLEMOUSE ++ || c == K_MIDDLEDRAG ++ || c == K_MIDDLERELEASE ++ || c == K_RIGHTMOUSE ++ || c == K_RIGHTDRAG ++ || c == K_RIGHTRELEASE ++ || c == K_MOUSEDOWN ++ || c == K_MOUSEUP ++ || c == K_MOUSELEFT ++ || c == K_MOUSERIGHT ++ || c == K_X1MOUSE ++ || c == K_X1DRAG ++ || c == K_X1RELEASE ++ || c == K_X2MOUSE ++ || c == K_X2DRAG ++ || c == K_X2RELEASE; ++ } ++ #endif ++ + /* + * Get a key stroke directly from the user. + * Ignores mouse clicks and scrollbar events, except a click for the left +*************** +*** 3373,3403 **** + n = TO_SPECIAL(buf[1], buf[2]); + if (buf[1] == KS_MODIFIER + || n == K_IGNORE +! #ifdef FEAT_MOUSE +! || n == K_LEFTMOUSE_NM +! || n == K_LEFTDRAG +! || n == K_LEFTRELEASE +! || n == K_LEFTRELEASE_NM +! || n == K_MIDDLEMOUSE +! || n == K_MIDDLEDRAG +! || n == K_MIDDLERELEASE +! || n == K_RIGHTMOUSE +! || n == K_RIGHTDRAG +! || n == K_RIGHTRELEASE +! || n == K_MOUSEDOWN +! || n == K_MOUSEUP +! || n == K_MOUSELEFT +! || n == K_MOUSERIGHT +! || n == K_X1MOUSE +! || n == K_X1DRAG +! || n == K_X1RELEASE +! || n == K_X2MOUSE +! || n == K_X2DRAG +! || n == K_X2RELEASE +! # ifdef FEAT_GUI + || n == K_VER_SCROLLBAR + || n == K_HOR_SCROLLBAR +- # endif + #endif + ) + { +--- 3405,3414 ---- + n = TO_SPECIAL(buf[1], buf[2]); + if (buf[1] == KS_MODIFIER + || n == K_IGNORE +! || (is_mouse_key(n) && n != K_LEFTMOUSE) +! #ifdef FEAT_GUI + || n == K_VER_SCROLLBAR + || n == K_HOR_SCROLLBAR + #endif + ) + { +*** ../vim-7.3.861/src/proto/misc1.pro 2012-11-20 16:56:49.000000000 +0100 +--- src/proto/misc1.pro 2013-03-16 14:02:33.000000000 +0100 +*************** +*** 42,47 **** +--- 42,48 ---- + void check_status __ARGS((buf_T *buf)); + void change_warning __ARGS((int col)); + int ask_yesno __ARGS((char_u *str, int direct)); ++ int is_mouse_key __ARGS((int c)); + int get_keystroke __ARGS((void)); + int get_number __ARGS((int colon, int *mouse_used)); + int prompt_for_number __ARGS((int *mouse_used)); +*** ../vim-7.3.861/src/normal.c 2013-03-13 19:02:37.000000000 +0100 +--- src/normal.c 2013-03-16 14:09:34.000000000 +0100 +*************** +*** 2443,2449 **** + return FALSE; + } + +! which_button = get_mouse_button(KEY2TERMCAP1(c), &is_click, &is_drag); + + #ifdef FEAT_MOUSESHAPE + /* May have stopped dragging the status or separator line. The pointer is +--- 2443,2473 ---- + return FALSE; + } + +! for (;;) +! { +! which_button = get_mouse_button(KEY2TERMCAP1(c), &is_click, &is_drag); +! if (is_drag) +! { +! /* If the next character is the same mouse event then use that +! * one. Speeds up dragging the status line. */ +! if (vpeekc() != NUL) +! { +! int nc; +! int save_mouse_row = mouse_row; +! int save_mouse_col = mouse_col; +! +! /* Need to get the character, peeking doesn't get the actual +! * one. */ +! nc = safe_vgetc(); +! if (c == nc) +! continue; +! vungetc(nc); +! mouse_row = save_mouse_row; +! mouse_col = save_mouse_col; +! } +! } +! break; +! } + + #ifdef FEAT_MOUSESHAPE + /* May have stopped dragging the status or separator line. The pointer is +*** ../vim-7.3.861/src/version.c 2013-03-13 20:42:28.000000000 +0100 +--- src/version.c 2013-03-16 14:18:36.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 862, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +53. To find out what time it is, you send yourself an e-mail and check the + "Date:" field. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9259b4aafd82b8d4195838fef3e3545221b8cf59 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:23 +0200 Subject: [PATCH 0749/3340] - patchlevel 863 --- 7.3.863 | 91 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 91 insertions(+) create mode 100644 7.3.863 diff --git a/7.3.863 b/7.3.863 new file mode 100644 index 00000000..64bd9ba1 --- /dev/null +++ b/7.3.863 @@ -0,0 +1,91 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.863 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.863 (after 7.3.859) +Problem: Problem with 'ambiwidth' detection for ANSI terminal. +Solution: Work around not recognizing a term response. (Hayaki Saito) +Files: src/term.c + + +*** ../vim-7.3.862/src/term.c 2013-03-13 19:29:24.000000000 +0100 +--- src/term.c 2013-03-16 14:29:00.000000000 +0100 +*************** +*** 3926,3933 **** + * Check at several positions in typebuf.tb_buf[], to catch something like + * "x" that can be mapped. Stop at max_offset, because characters + * after that cannot be used for mapping, and with @r commands +! * typebuf.tb_buf[] +! * can become very long. + * This is used often, KEEP IT FAST! + */ + for (offset = 0; offset < max_offset; ++offset) +--- 3926,3932 ---- + * Check at several positions in typebuf.tb_buf[], to catch something like + * "x" that can be mapped. Stop at max_offset, because characters + * after that cannot be used for mapping, and with @r commands +! * typebuf.tb_buf[] can become very long. + * This is used often, KEEP IT FAST! + */ + for (offset = 0; offset < max_offset; ++offset) +*************** +*** 4098,4104 **** + #ifdef FEAT_TERMRESPONSE + if (key_name[0] == NUL + /* URXVT mouse uses [#;#;#M, but we are matching [ */ +! || key_name[0] == KS_URXVT_MOUSE) + { + /* Check for some responses from terminal start with "[" or + * CSI. +--- 4097,4107 ---- + #ifdef FEAT_TERMRESPONSE + if (key_name[0] == NUL + /* URXVT mouse uses [#;#;#M, but we are matching [ */ +! || key_name[0] == KS_URXVT_MOUSE +! # ifdef FEAT_MBYTE +! || u7_status == U7_SENT +! # endif +! ) + { + /* Check for some responses from terminal start with "[" or + * CSI. +*************** +*** 4129,4135 **** + + #ifdef FEAT_MBYTE + /* eat it when it has 2 arguments and ends in 'R' */ +! if (u7_status == U7_SENT && j == 1 && tp[i] == 'R') + { + char *p = NULL; + +--- 4132,4138 ---- + + #ifdef FEAT_MBYTE + /* eat it when it has 2 arguments and ends in 'R' */ +! if (j == 1 && tp[i] == 'R') + { + char *p = NULL; + +*** ../vim-7.3.862/src/version.c 2013-03-16 14:20:45.000000000 +0100 +--- src/version.c 2013-03-16 14:33:16.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 863, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +54. You start tilting your head sideways to smile. :-) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From aaee7ef92a728a8a209dfb0a2ceb43938f5a58f9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:23 +0200 Subject: [PATCH 0750/3340] - patchlevel 864 --- 7.3.864 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.864 diff --git a/7.3.864 b/7.3.864 new file mode 100644 index 00000000..c8d0e201 --- /dev/null +++ b/7.3.864 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.864 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.864 (after 7.3.862) +Problem: Can't build without the mouse feature. +Solution: Add an #ifdef. (Ike Devolder) +Files: src/misc1.c + + +*** ../vim-7.3.863/src/misc1.c 2013-03-16 14:20:45.000000000 +0100 +--- src/misc1.c 2013-03-16 21:33:08.000000000 +0100 +*************** +*** 3405,3411 **** +--- 3405,3413 ---- + n = TO_SPECIAL(buf[1], buf[2]); + if (buf[1] == KS_MODIFIER + || n == K_IGNORE ++ #ifdef FEAT_MOUSE + || (is_mouse_key(n) && n != K_LEFTMOUSE) ++ #endif + #ifdef FEAT_GUI + || n == K_VER_SCROLLBAR + || n == K_HOR_SCROLLBAR +*** ../vim-7.3.863/src/version.c 2013-03-16 14:33:32.000000000 +0100 +--- src/version.c 2013-03-16 21:34:15.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 864, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +57. You begin to wonder how on earth your service provider is allowed to call + 200 hours per month "unlimited." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From be0e497d550ad1ab9c3f4a2aa4d42c1bda67cdb3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:24 +0200 Subject: [PATCH 0751/3340] - patchlevel 865 --- 7.3.865 | 74 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 7.3.865 diff --git a/7.3.865 b/7.3.865 new file mode 100644 index 00000000..faffde0f --- /dev/null +++ b/7.3.865 @@ -0,0 +1,74 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.865 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.865 (after 7.3.862) +Problem: Mouse position may be wrong. +Solution: Let vungetc() restore the mouse position. +Files: src/getchar.c + + +*** ../vim-7.3.864/src/getchar.c 2012-06-06 12:06:10.000000000 +0200 +--- src/getchar.c 2013-03-16 21:41:02.000000000 +0100 +*************** +*** 1337,1342 **** +--- 1337,1346 ---- + + static int old_char = -1; /* character put back by vungetc() */ + static int old_mod_mask; /* mod_mask for ungotten character */ ++ #ifdef FEAT_MOUSE ++ static int old_mouse_row; /* mouse_row related to old_char */ ++ static int old_mouse_col; /* mouse_col related to old_char */ ++ #endif + + #if defined(FEAT_EVAL) || defined(FEAT_EX_EXTRA) || defined(PROTO) + +*************** +*** 1567,1572 **** +--- 1571,1580 ---- + c = old_char; + old_char = -1; + mod_mask = old_mod_mask; ++ #ifdef FEAT_MOUSE ++ mouse_row = old_mouse_row; ++ mouse_col = old_mouse_col; ++ #endif + } + else + { +*************** +*** 1877,1882 **** +--- 1885,1894 ---- + { + old_char = c; + old_mod_mask = mod_mask; ++ #ifdef FEAT_MOUSE ++ old_mouse_row = mouse_row; ++ old_mouse_col = mouse_col; ++ #endif + } + + /* +*** ../vim-7.3.864/src/version.c 2013-03-16 21:35:28.000000000 +0100 +--- src/version.c 2013-03-16 21:38:44.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 865, + /**/ + +-- +Creating the world with Emacs: M-x let-there-be-light +Creating the world with Vim: :make world + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 219fed690413ced179a058b815962fabce8b32d7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:25 +0200 Subject: [PATCH 0752/3340] - patchlevel 866 --- 7.3.866 | 196 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 196 insertions(+) create mode 100644 7.3.866 diff --git a/7.3.866 b/7.3.866 new file mode 100644 index 00000000..c0da32d2 --- /dev/null +++ b/7.3.866 @@ -0,0 +1,196 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.866 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.866 +Problem: Not serving the X selection during system() isn't nice. +Solution: When using fork() do not loose the selection, keep serving it. + Add a loop similar to handling I/O. (Yukihiro Nakadaira) +Files: src/os_unix.c + + +*** ../vim-7.3.865/src/os_unix.c 2013-03-13 17:50:20.000000000 +0100 +--- src/os_unix.c 2013-03-19 12:34:04.000000000 +0100 +*************** +*** 132,137 **** +--- 132,138 ---- + # include + # include + static Widget xterm_Shell = (Widget)0; ++ static void clip_update __ARGS((void)); + static void xterm_update __ARGS((void)); + # endif + +*************** +*** 1138,1148 **** +--- 1139,1151 ---- + + # if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) + static void loose_clipboard __ARGS((void)); ++ # ifdef USE_SYSTEM + static void save_clipboard __ARGS((void)); + static void restore_clipboard __ARGS((void)); + + static void *clip_star_save = NULL; + static void *clip_plus_save = NULL; ++ # endif + + /* + * Called when Vim is going to sleep or execute a shell command. +*************** +*** 1164,1169 **** +--- 1167,1173 ---- + } + } + ++ # ifdef USE_SYSTEM + /* + * Save clipboard text to restore later. + */ +*************** +*** 1199,1204 **** +--- 1203,1209 ---- + clip_plus_save = NULL; + } + } ++ # endif + #endif + + /* +*************** +*** 4009,4021 **** + if (options & SHELL_COOKED) + settmode(TMODE_COOK); /* set to normal mode */ + +- # if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) +- /* Disown the clipboard, because is the executed command tries to obtain a +- * selection and we own it we get a deadlock. */ +- save_clipboard(); +- loose_clipboard(); +- # endif +- + /* + * Do this loop twice: + * 1: find number of arguments +--- 4014,4019 ---- +*************** +*** 4788,4793 **** +--- 4786,4796 ---- + } + else + wait_pid = 0; ++ ++ # if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) ++ /* Handle any X events, e.g. serving the clipboard. */ ++ clip_update(); ++ # endif + } + finished: + p_more = p_more_save; +*************** +*** 4814,4819 **** +--- 4817,4861 ---- + close(toshell_fd); + close(fromshell_fd); + } ++ # if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) ++ else ++ { ++ /* ++ * Similar to the loop above, but only handle X events, no ++ * I/O. ++ */ ++ for (;;) ++ { ++ if (got_int) ++ { ++ /* CTRL-C sends a signal to the child, we ignore it ++ * ourselves */ ++ # ifdef HAVE_SETSID ++ kill(-pid, SIGINT); ++ # else ++ kill(0, SIGINT); ++ # endif ++ got_int = FALSE; ++ } ++ # ifdef __NeXT__ ++ wait_pid = wait4(pid, &status, WNOHANG, (struct rusage *)0); ++ # else ++ wait_pid = waitpid(pid, &status, WNOHANG); ++ # endif ++ if ((wait_pid == (pid_t)-1 && errno == ECHILD) ++ || (wait_pid == pid && WIFEXITED(status))) ++ { ++ wait_pid = pid; ++ break; ++ } ++ ++ /* Handle any X events, e.g. serving the clipboard. */ ++ clip_update(); ++ ++ mch_delay(10L, TRUE); ++ } ++ } ++ # endif + + /* + * Wait until our child has exited. +*************** +*** 4884,4892 **** + # ifdef FEAT_TITLE + resettitle(); + # endif +- # if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) +- restore_clipboard(); +- # endif + vim_free(newcmd); + + return retval; +--- 4926,4931 ---- +*************** +*** 6868,6873 **** +--- 6907,6927 ---- + # endif + + /* ++ * Catch up with GUI or X events. ++ */ ++ static void ++ clip_update() ++ { ++ # ifdef FEAT_GUI ++ if (gui.in_use) ++ gui_mch_update(); ++ else ++ # endif ++ if (xterm_Shell != (Widget)0) ++ xterm_update(); ++ } ++ ++ /* + * Catch up with any queued X events. This may put keyboard input into the + * input buffer, call resize call-backs, trigger timers etc. If there is + * nothing in the X event queue (& no timers pending), then we return +*** ../vim-7.3.865/src/version.c 2013-03-16 21:42:12.000000000 +0100 +--- src/version.c 2013-03-19 12:30:16.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 866, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +71. You wonder how people walk + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7f399bb764f8aa7a8b5c0b68db8862c003f83511 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:25 +0200 Subject: [PATCH 0753/3340] - patchlevel 867 --- 7.3.867 | 279 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 279 insertions(+) create mode 100644 7.3.867 diff --git a/7.3.867 b/7.3.867 new file mode 100644 index 00000000..68f4312b --- /dev/null +++ b/7.3.867 @@ -0,0 +1,279 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.867 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.867 +Problem: Matchparen does not update match when using auto-indenting. + (Marc Aldorasi) +Solution: Add the TextChanged and TextChangedI autocommand events. +Files: runtime/plugin/matchparen.vim, src/main.c, src/edit.c, + src/globals.h, src/vim.h, src/fileio.c, src/proto/fileio.pro, + runtime/doc/autocmd.txt + + +*** ../vim-7.3.866/runtime/plugin/matchparen.vim 2010-08-15 21:57:19.000000000 +0200 +--- runtime/plugin/matchparen.vim 2013-03-19 13:16:46.000000000 +0100 +*************** +*** 1,6 **** + " Vim plugin for showing matching parens + " Maintainer: Bram Moolenaar +! " Last Change: 2008 Sep 03 + + " Exit quickly when: + " - this plugin was already loaded (or disabled) +--- 1,6 ---- + " Vim plugin for showing matching parens + " Maintainer: Bram Moolenaar +! " Last Change: 2013 Mar 19 + + " Exit quickly when: + " - this plugin was already loaded (or disabled) +*************** +*** 14,19 **** +--- 14,22 ---- + augroup matchparen + " Replace all matchparen autocommands + autocmd! CursorMoved,CursorMovedI,WinEnter * call s:Highlight_Matching_Pair() ++ if exists('##TextChanged') ++ autocmd! TextChanged,TextChangedI * call s:Highlight_Matching_Pair() ++ endif + augroup END + + " Skip the rest if it was already done. +*************** +*** 82,89 **** + endif + + " When not in a string or comment ignore matches inside them. + let s_skip ='synIDattr(synID(line("."), col("."), 0), "name") ' . +! \ '=~? "string\\|character\\|singlequote\\|comment"' + execute 'if' s_skip '| let s_skip = 0 | endif' + + " Limit the search to lines visible in the window. +--- 85,93 ---- + endif + + " When not in a string or comment ignore matches inside them. ++ " We match "escape" for special items, such as lispEscapeSpecial. + let s_skip ='synIDattr(synID(line("."), col("."), 0), "name") ' . +! \ '=~? "string\\|character\\|singlequote\\|escape\\|comment"' + execute 'if' s_skip '| let s_skip = 0 | endif' + + " Limit the search to lines visible in the window. +*** ../vim-7.3.866/src/main.c 2013-03-13 20:23:17.000000000 +0100 +--- src/main.c 2013-03-19 13:00:34.000000000 +0100 +*************** +*** 1168,1173 **** +--- 1168,1186 ---- + } + #endif + ++ #ifdef FEAT_AUTOCMD ++ /* Trigger TextChanged if b_changedtick differs. */ ++ if (!finish_op && has_textchanged() ++ && last_changedtick != curbuf->b_changedtick) ++ { ++ if (last_changedtick_buf == curbuf) ++ apply_autocmds(EVENT_TEXTCHANGED, NULL, NULL, ++ FALSE, curbuf); ++ last_changedtick_buf = curbuf; ++ last_changedtick = curbuf->b_changedtick; ++ } ++ #endif ++ + #if defined(FEAT_DIFF) && defined(FEAT_SCROLLBIND) + /* Scroll-binding for diff mode may have been postponed until + * here. Avoids doing it for every change. */ +*** ../vim-7.3.866/src/edit.c 2013-03-07 19:38:49.000000000 +0100 +--- src/edit.c 2013-03-19 13:08:46.000000000 +0100 +*************** +*** 1593,1598 **** +--- 1593,1613 ---- + last_cursormoved = curwin->w_cursor; + } + #endif ++ #ifdef FEAT_AUTOCMD ++ /* Trigger TextChangedI if b_changedtick differs. */ ++ if (!ready && has_textchangedI() ++ && last_changedtick != curbuf->b_changedtick ++ # ifdef FEAT_INS_EXPAND ++ && !pum_visible() ++ # endif ++ ) ++ { ++ if (last_changedtick_buf == curbuf) ++ apply_autocmds(EVENT_TEXTCHANGEDI, NULL, NULL, FALSE, curbuf); ++ last_changedtick_buf = curbuf; ++ last_changedtick = curbuf->b_changedtick; ++ } ++ #endif + if (must_redraw) + update_screen(0); + else if (clear_cmdline || redraw_cmdline) +*** ../vim-7.3.866/src/globals.h 2013-02-26 14:56:24.000000000 +0100 +--- src/globals.h 2013-03-19 13:11:35.000000000 +0100 +*************** +*** 1057,1067 **** + EXTERN int autocmd_bufnr INIT(= 0); /* fnum for on cmdline */ + EXTERN char_u *autocmd_match INIT(= NULL); /* name for on cmdline */ + EXTERN int did_cursorhold INIT(= FALSE); /* set when CursorHold t'gerd */ +! EXTERN pos_T last_cursormoved /* for CursorMoved event */ + # ifdef DO_INIT + = INIT_POS_T(0, 0, 0) + # endif + ; + #endif + + #ifdef FEAT_WINDOWS +--- 1057,1069 ---- + EXTERN int autocmd_bufnr INIT(= 0); /* fnum for on cmdline */ + EXTERN char_u *autocmd_match INIT(= NULL); /* name for on cmdline */ + EXTERN int did_cursorhold INIT(= FALSE); /* set when CursorHold t'gerd */ +! EXTERN pos_T last_cursormoved /* for CursorMoved event */ + # ifdef DO_INIT + = INIT_POS_T(0, 0, 0) + # endif + ; ++ EXTERN int last_changedtick INIT(= 0); /* for TextChanged event */ ++ EXTERN buf_T *last_changedtick_buf INIT(= NULL); + #endif + + #ifdef FEAT_WINDOWS +*** ../vim-7.3.866/src/vim.h 2013-02-26 14:56:24.000000000 +0100 +--- src/vim.h 2013-03-19 13:07:00.000000000 +0100 +*************** +*** 1300,1305 **** +--- 1300,1307 ---- + EVENT_TABENTER, /* after entering a tab page */ + EVENT_SHELLCMDPOST, /* after ":!cmd" */ + EVENT_SHELLFILTERPOST, /* after ":1,2!cmd", ":w !cmd", ":r !cmd". */ ++ EVENT_TEXTCHANGED, /* text was modified */ ++ EVENT_TEXTCHANGEDI, /* text was modified in Insert mode*/ + NUM_EVENTS /* MUST be the last one */ + }; + +*** ../vim-7.3.866/src/fileio.c 2013-01-30 14:13:52.000000000 +0100 +--- src/fileio.c 2013-03-19 13:08:31.000000000 +0100 +*************** +*** 7713,7718 **** +--- 7713,7720 ---- + {"TabLeave", EVENT_TABLEAVE}, + {"TermChanged", EVENT_TERMCHANGED}, + {"TermResponse", EVENT_TERMRESPONSE}, ++ {"TextChanged", EVENT_TEXTCHANGED}, ++ {"TextChangedI", EVENT_TEXTCHANGEDI}, + {"User", EVENT_USER}, + {"VimEnter", EVENT_VIMENTER}, + {"VimLeave", EVENT_VIMLEAVE}, +*************** +*** 9138,9143 **** +--- 9140,9163 ---- + } + + /* ++ * Return TRUE when there is a TextChanged autocommand defined. ++ */ ++ int ++ has_textchanged() ++ { ++ return (first_autopat[(int)EVENT_TEXTCHANGED] != NULL); ++ } ++ ++ /* ++ * Return TRUE when there is a TextChangedI autocommand defined. ++ */ ++ int ++ has_textchangedI() ++ { ++ return (first_autopat[(int)EVENT_TEXTCHANGEDI] != NULL); ++ } ++ ++ /* + * Return TRUE when there is an InsertCharPre autocommand defined. + */ + int +*** ../vim-7.3.866/src/proto/fileio.pro 2012-12-05 19:13:11.000000000 +0100 +--- src/proto/fileio.pro 2013-03-19 13:10:13.000000000 +0100 +*************** +*** 44,49 **** +--- 44,51 ---- + int trigger_cursorhold __ARGS((void)); + int has_cursormoved __ARGS((void)); + int has_cursormovedI __ARGS((void)); ++ int has_textchanged __ARGS((void)); ++ int has_textchangedI __ARGS((void)); + int has_insertcharpre __ARGS((void)); + void block_autocmds __ARGS((void)); + void unblock_autocmds __ARGS((void)); +*** ../vim-7.3.866/runtime/doc/autocmd.txt 2012-03-07 20:13:44.000000000 +0100 +--- runtime/doc/autocmd.txt 2013-03-19 13:22:37.000000000 +0100 +*************** +*** 805,817 **** + TermResponse After the response to |t_RV| is received from + the terminal. The value of |v:termresponse| + can be used to do things depending on the +! terminal version. + *User* + User Never executed automatically. To be used for + autocommands that are only executed with + ":doautocmd". + *UserGettingBored* +! UserGettingBored When the user hits CTRL-C. Just kidding! :-) + *VimEnter* + VimEnter After doing all the startup stuff, including + loading .vimrc files, executing the "-c cmd" +--- 828,858 ---- + TermResponse After the response to |t_RV| is received from + the terminal. The value of |v:termresponse| + can be used to do things depending on the +! terminal version. Note that this event may be +! triggered halfway executing another event, +! especially if file I/O, a shell command or +! anything else that takes time is involved. +! *TextChanged* +! TextChanged After a change was made to the text in the +! current buffer in Normal mode. That is when +! |b:changedtick| has changed. +! Not triggered when there is typeahead or when +! an operator is pending. +! Careful: This is triggered very often, don't +! do anything that the user does not expect or +! that is slow. +! *TextChangedI* +! TextChangedI After a change was made to the text in the +! current buffer in Insert mode. +! Not triggered when the popup menu is visible. +! Otherwise the same as TextChanged. + *User* + User Never executed automatically. To be used for + autocommands that are only executed with + ":doautocmd". + *UserGettingBored* +! UserGettingBored When the user presses the same key 42 times. +! Just kidding! :-) + *VimEnter* + VimEnter After doing all the startup stuff, including + loading .vimrc files, executing the "-c cmd" +*** ../vim-7.3.866/src/version.c 2013-03-19 12:35:33.000000000 +0100 +--- src/version.c 2013-03-19 13:29:58.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 867, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +73. You give your dog used motherboards instead of bones + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 20d8e8e0d2d51eec682732788bc5cf92e4b6a755 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:26 +0200 Subject: [PATCH 0754/3340] - patchlevel 868 --- 7.3.868 | 90 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) create mode 100644 7.3.868 diff --git a/7.3.868 b/7.3.868 new file mode 100644 index 00000000..56a0225e --- /dev/null +++ b/7.3.868 @@ -0,0 +1,90 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.868 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.868 +Problem: When at the hit-return prompt and using "k" while no text has + scrolled off screen, then using "j", an empty line is displayed. +Solution: Only act on "k" when text scrolled off screen. Also accept + page-up and page-down. (cptstubing) +Files: src/message.c + + +*** ../vim-7.3.867/src/message.c 2012-11-14 18:10:49.000000000 +0100 +--- src/message.c 2013-03-19 13:50:16.000000000 +0100 +*************** +*** 976,985 **** + */ + if (p_more && !p_cp) + { +! if (c == 'b' || c == 'k' || c == 'u' || c == 'g' || c == K_UP) + { +! /* scroll back to show older messages */ +! do_more_prompt(c); + if (quit_more) + { + c = CAR; /* just pretend CR was hit */ +--- 976,997 ---- + */ + if (p_more && !p_cp) + { +! if (c == 'b' || c == 'k' || c == 'u' || c == 'g' +! || c == K_UP || c == K_PAGEUP) + { +! if (msg_scrolled > Rows) +! /* scroll back to show older messages */ +! do_more_prompt(c); +! else +! { +! msg_didout = FALSE; +! c = K_IGNORE; +! msg_col = +! #ifdef FEAT_RIGHTLEFT +! cmdmsg_rl ? Columns - 1 : +! #endif +! 0; +! } + if (quit_more) + { + c = CAR; /* just pretend CR was hit */ +*************** +*** 993,999 **** + } + } + else if (msg_scrolled > Rows - 2 +! && (c == 'j' || c == K_DOWN || c == 'd' || c == 'f')) + c = K_IGNORE; + } + } while ((had_got_int && c == Ctrl_C) +--- 1005,1012 ---- + } + } + else if (msg_scrolled > Rows - 2 +! && (c == 'j' || c == 'd' || c == 'f' +! || c == K_DOWN || c == K_PAGEDOWN)) + c = K_IGNORE; + } + } while ((had_got_int && c == Ctrl_C) +*** ../vim-7.3.867/src/version.c 2013-03-19 13:33:18.000000000 +0100 +--- src/version.c 2013-03-19 13:53:02.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 868, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +74. Your most erotic dreams are about cybersex + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4e368ca8dbb940cd3ab80e8556567e74de557e41 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:26 +0200 Subject: [PATCH 0755/3340] - patchlevel 869 --- 7.3.869 | 358 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 358 insertions(+) create mode 100644 7.3.869 diff --git a/7.3.869 b/7.3.869 new file mode 100644 index 00000000..a848f0cd --- /dev/null +++ b/7.3.869 @@ -0,0 +1,358 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.869 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.869 +Problem: bufwinnr() matches buffers in other tabs. +Solution: For bufwinnr() and ? only match buffers in the current tab. + (Alexey Radkov) +Files: src/buffer.c, src/diff.c, src/eval.c, src/ex_docmd.c, + src/if_perl.xs, src/proto/buffer.pro + + +*** ../vim-7.3.868/src/buffer.c 2013-02-17 15:45:34.000000000 +0100 +--- src/buffer.c 2013-03-19 14:19:17.000000000 +0100 +*************** +*** 928,934 **** + if (!VIM_ISDIGIT(*arg)) + { + p = skiptowhite_esc(arg); +! bnr = buflist_findpat(arg, p, command == DOBUF_WIPE, FALSE); + if (bnr < 0) /* failed */ + break; + arg = p; +--- 928,935 ---- + if (!VIM_ISDIGIT(*arg)) + { + p = skiptowhite_esc(arg); +! bnr = buflist_findpat(arg, p, command == DOBUF_WIPE, +! FALSE, FALSE); + if (bnr < 0) /* failed */ + break; + arg = p; +*************** +*** 2129,2146 **** + return NULL; + } + +! #if defined(FEAT_LISTCMDS) || defined(FEAT_EVAL) || defined(FEAT_PERL) || defined(PROTO) + /* + * Find file in buffer list by a regexp pattern. + * Return fnum of the found buffer. + * Return < 0 for error. + */ + int +! buflist_findpat(pattern, pattern_end, unlisted, diffmode) + char_u *pattern; + char_u *pattern_end; /* pointer to first char after pattern */ + int unlisted; /* find unlisted buffers */ + int diffmode UNUSED; /* find diff-mode buffers only */ + { + buf_T *buf; + regprog_T *prog; +--- 2130,2149 ---- + return NULL; + } + +! #if defined(FEAT_LISTCMDS) || defined(FEAT_EVAL) || defined(FEAT_PERL) \ +! || defined(PROTO) + /* + * Find file in buffer list by a regexp pattern. + * Return fnum of the found buffer. + * Return < 0 for error. + */ + int +! buflist_findpat(pattern, pattern_end, unlisted, diffmode, curtab_only) + char_u *pattern; + char_u *pattern_end; /* pointer to first char after pattern */ + int unlisted; /* find unlisted buffers */ + int diffmode UNUSED; /* find diff-mode buffers only */ ++ int curtab_only; /* find buffers in current tab only */ + { + buf_T *buf; + regprog_T *prog; +*************** +*** 2208,2213 **** +--- 2211,2233 ---- + #endif + && buflist_match(prog, buf) != NULL) + { ++ if (curtab_only) ++ { ++ /* Ignore the match if the buffer is not open in ++ * the current tab. */ ++ #ifdef FEAT_WINDOWS ++ win_T *wp; ++ ++ for (wp = firstwin; wp != NULL; wp = wp->w_next) ++ if (wp->w_buffer == buf) ++ break; ++ if (wp == NULL) ++ continue; ++ #else ++ if (curwin->w_buffer != buf) ++ continue; ++ #endif ++ } + if (match >= 0) /* already found a match */ + { + match = -2; +*** ../vim-7.3.868/src/diff.c 2012-10-21 22:18:17.000000000 +0200 +--- src/diff.c 2013-03-19 14:11:40.000000000 +0100 +*************** +*** 2152,2158 **** + i = atol((char *)eap->arg); + else + { +! i = buflist_findpat(eap->arg, p, FALSE, TRUE); + if (i < 0) + return; /* error message already given */ + } +--- 2152,2158 ---- + i = atol((char *)eap->arg); + else + { +! i = buflist_findpat(eap->arg, p, FALSE, TRUE, FALSE); + if (i < 0) + return; /* error message already given */ + } +*** ../vim-7.3.868/src/eval.c 2013-03-16 14:20:45.000000000 +0100 +--- src/eval.c 2013-03-19 14:11:40.000000000 +0100 +*************** +*** 9019,9032 **** + rettv->vval.v_number = (buf != NULL && buf->b_ml.ml_mfp != NULL); + } + +! static buf_T *get_buf_tv __ARGS((typval_T *tv)); + + /* + * Get buffer by number or pattern. + */ + static buf_T * +! get_buf_tv(tv) + typval_T *tv; + { + char_u *name = tv->vval.v_string; + int save_magic; +--- 9019,9033 ---- + rettv->vval.v_number = (buf != NULL && buf->b_ml.ml_mfp != NULL); + } + +! static buf_T *get_buf_tv __ARGS((typval_T *tv, int curtab_only)); + + /* + * Get buffer by number or pattern. + */ + static buf_T * +! get_buf_tv(tv, curtab_only) + typval_T *tv; ++ int curtab_only; + { + char_u *name = tv->vval.v_string; + int save_magic; +*************** +*** 9049,9055 **** + p_cpo = (char_u *)""; + + buf = buflist_findnr(buflist_findpat(name, name + STRLEN(name), +! TRUE, FALSE)); + + p_magic = save_magic; + p_cpo = save_cpo; +--- 9050,9056 ---- + p_cpo = (char_u *)""; + + buf = buflist_findnr(buflist_findpat(name, name + STRLEN(name), +! TRUE, FALSE, curtab_only)); + + p_magic = save_magic; + p_cpo = save_cpo; +*************** +*** 9073,9079 **** + + (void)get_tv_number(&argvars[0]); /* issue errmsg if type error */ + ++emsg_off; +! buf = get_buf_tv(&argvars[0]); + rettv->v_type = VAR_STRING; + if (buf != NULL && buf->b_fname != NULL) + rettv->vval.v_string = vim_strsave(buf->b_fname); +--- 9074,9080 ---- + + (void)get_tv_number(&argvars[0]); /* issue errmsg if type error */ + ++emsg_off; +! buf = get_buf_tv(&argvars[0], FALSE); + rettv->v_type = VAR_STRING; + if (buf != NULL && buf->b_fname != NULL) + rettv->vval.v_string = vim_strsave(buf->b_fname); +*************** +*** 9096,9102 **** + + (void)get_tv_number(&argvars[0]); /* issue errmsg if type error */ + ++emsg_off; +! buf = get_buf_tv(&argvars[0]); + --emsg_off; + + /* If the buffer isn't found and the second argument is not zero create a +--- 9097,9103 ---- + + (void)get_tv_number(&argvars[0]); /* issue errmsg if type error */ + ++emsg_off; +! buf = get_buf_tv(&argvars[0], FALSE); + --emsg_off; + + /* If the buffer isn't found and the second argument is not zero create a +*************** +*** 9131,9137 **** + + (void)get_tv_number(&argvars[0]); /* issue errmsg if type error */ + ++emsg_off; +! buf = get_buf_tv(&argvars[0]); + #ifdef FEAT_WINDOWS + for (wp = firstwin; wp; wp = wp->w_next) + { +--- 9132,9138 ---- + + (void)get_tv_number(&argvars[0]); /* issue errmsg if type error */ + ++emsg_off; +! buf = get_buf_tv(&argvars[0], TRUE); + #ifdef FEAT_WINDOWS + for (wp = firstwin; wp; wp = wp->w_next) + { +*************** +*** 11095,11101 **** + + (void)get_tv_number(&argvars[0]); /* issue errmsg if type error */ + ++emsg_off; +! buf = get_buf_tv(&argvars[0]); + --emsg_off; + + lnum = get_tv_lnum_buf(&argvars[1], buf); +--- 11096,11102 ---- + + (void)get_tv_number(&argvars[0]); /* issue errmsg if type error */ + ++emsg_off; +! buf = get_buf_tv(&argvars[0], FALSE); + --emsg_off; + + lnum = get_tv_lnum_buf(&argvars[1], buf); +*************** +*** 11123,11129 **** + (void)get_tv_number(&argvars[0]); /* issue errmsg if type error */ + varname = get_tv_string_chk(&argvars[1]); + ++emsg_off; +! buf = get_buf_tv(&argvars[0]); + + if (argvars[2].v_type != VAR_UNKNOWN) + /* set the default value */ +--- 11124,11130 ---- + (void)get_tv_number(&argvars[0]); /* issue errmsg if type error */ + varname = get_tv_string_chk(&argvars[1]); + ++emsg_off; +! buf = get_buf_tv(&argvars[0], FALSE); + + if (argvars[2].v_type != VAR_UNKNOWN) + /* set the default value */ +*************** +*** 16216,16222 **** + return; + (void)get_tv_number(&argvars[0]); /* issue errmsg if type error */ + varname = get_tv_string_chk(&argvars[1]); +! buf = get_buf_tv(&argvars[0]); + varp = &argvars[2]; + + if (buf != NULL && varname != NULL && varp != NULL) +--- 16217,16223 ---- + return; + (void)get_tv_number(&argvars[0]); /* issue errmsg if type error */ + varname = get_tv_string_chk(&argvars[1]); +! buf = get_buf_tv(&argvars[0], FALSE); + varp = &argvars[2]; + + if (buf != NULL && varname != NULL && varp != NULL) +*** ../vim-7.3.868/src/ex_docmd.c 2013-03-13 18:30:39.000000000 +0100 +--- src/ex_docmd.c 2013-03-19 14:15:17.000000000 +0100 +*************** +*** 2645,2651 **** + while (p > ea.arg && vim_iswhite(p[-1])) + --p; + } +! ea.line2 = buflist_findpat(ea.arg, p, (ea.argt & BUFUNL) != 0, FALSE); + if (ea.line2 < 0) /* failed */ + goto doend; + ea.addr_count = 1; +--- 2645,2652 ---- + while (p > ea.arg && vim_iswhite(p[-1])) + --p; + } +! ea.line2 = buflist_findpat(ea.arg, p, (ea.argt & BUFUNL) != 0, +! FALSE, FALSE); + if (ea.line2 < 0) /* failed */ + goto doend; + ea.addr_count = 1; +*** ../vim-7.3.868/src/if_perl.xs 2013-02-14 22:19:47.000000000 +0100 +--- src/if_perl.xs 2013-03-19 14:15:46.000000000 +0100 +*************** +*** 1056,1062 **** + + pat = (char_u *)SvPV(sv, len); + ++emsg_off; +! b = buflist_findpat(pat, pat+len, FALSE, FALSE); + --emsg_off; + } + +--- 1056,1062 ---- + + pat = (char_u *)SvPV(sv, len); + ++emsg_off; +! b = buflist_findpat(pat, pat+len, FALSE, FALSE, FALSE); + --emsg_off; + } + +*** ../vim-7.3.868/src/proto/buffer.pro 2012-10-03 18:24:55.000000000 +0200 +--- src/proto/buffer.pro 2013-03-19 14:16:22.000000000 +0100 +*************** +*** 17,23 **** + void buflist_getfpos __ARGS((void)); + buf_T *buflist_findname_exp __ARGS((char_u *fname)); + buf_T *buflist_findname __ARGS((char_u *ffname)); +! int buflist_findpat __ARGS((char_u *pattern, char_u *pattern_end, int unlisted, int diffmode)); + int ExpandBufnames __ARGS((char_u *pat, int *num_file, char_u ***file, int options)); + buf_T *buflist_findnr __ARGS((int nr)); + char_u *buflist_nr2name __ARGS((int n, int fullname, int helptail)); +--- 17,23 ---- + void buflist_getfpos __ARGS((void)); + buf_T *buflist_findname_exp __ARGS((char_u *fname)); + buf_T *buflist_findname __ARGS((char_u *ffname)); +! int buflist_findpat __ARGS((char_u *pattern, char_u *pattern_end, int unlisted, int diffmode, int curtab_only)); + int ExpandBufnames __ARGS((char_u *pat, int *num_file, char_u ***file, int options)); + buf_T *buflist_findnr __ARGS((int nr)); + char_u *buflist_nr2name __ARGS((int n, int fullname, int helptail)); +*** ../vim-7.3.868/src/version.c 2013-03-19 13:56:03.000000000 +0100 +--- src/version.c 2013-03-19 14:23:42.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 869, + /**/ + +-- +Proof techniques #2: Proof by Oddity. + SAMPLE: To prove that horses have an infinite number of legs. +(1) Horses have an even number of legs. +(2) They have two legs in back and fore legs in front. +(3) This makes a total of six legs, which certainly is an odd number of + legs for a horse. +(4) But the only number that is both odd and even is infinity. +(5) Therefore, horses must have an infinite number of legs. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9197e4b739317b03fddbeb33bc4611be5d7963fd Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:27 +0200 Subject: [PATCH 0756/3340] - patchlevel 870 --- 7.3.870 | 203 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 203 insertions(+) create mode 100644 7.3.870 diff --git a/7.3.870 b/7.3.870 new file mode 100644 index 00000000..38bb219f --- /dev/null +++ b/7.3.870 @@ -0,0 +1,203 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.870 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.870 +Problem: Compiler warnings when using MingW 4.5.3. +Solution: Do not use MAKEINTRESOURCE. Adjust #if. (Ken Takata) +Files: src/gui_w32.c, src/gui_w48.c, src/os_mswin.c, src/os_win32.c, + src/os_win32.h + + +*** ../vim-7.3.869/src/gui_w32.c 2012-11-20 16:53:34.000000000 +0100 +--- src/gui_w32.c 2013-03-19 14:45:24.000000000 +0100 +*************** +*** 1614,1620 **** + #endif + + #ifdef FEAT_EVAL +! # if _MSC_VER < 1400 + /* HandleToLong() only exists in compilers that can do 64 bit builds */ + # define HandleToLong(h) ((long)(h)) + # endif +--- 1614,1620 ---- + #endif + + #ifdef FEAT_EVAL +! # ifndef HandleToLong + /* HandleToLong() only exists in compilers that can do 64 bit builds */ + # define HandleToLong(h) ((long)(h)) + # endif +*** ../vim-7.3.869/src/gui_w48.c 2013-01-25 19:28:34.000000000 +0100 +--- src/gui_w48.c 2013-03-19 14:46:35.000000000 +0100 +*************** +*** 3265,3291 **** + * misc2.c! */ + static LPCSTR mshape_idcs[] = + { +! MAKEINTRESOURCE(IDC_ARROW), /* arrow */ +! MAKEINTRESOURCE(0), /* blank */ +! MAKEINTRESOURCE(IDC_IBEAM), /* beam */ +! MAKEINTRESOURCE(IDC_SIZENS), /* updown */ +! MAKEINTRESOURCE(IDC_SIZENS), /* udsizing */ +! MAKEINTRESOURCE(IDC_SIZEWE), /* leftright */ +! MAKEINTRESOURCE(IDC_SIZEWE), /* lrsizing */ +! MAKEINTRESOURCE(IDC_WAIT), /* busy */ + #ifdef WIN3264 +! MAKEINTRESOURCE(IDC_NO), /* no */ + #else +! MAKEINTRESOURCE(IDC_ICON), /* no */ + #endif +! MAKEINTRESOURCE(IDC_ARROW), /* crosshair */ +! MAKEINTRESOURCE(IDC_ARROW), /* hand1 */ +! MAKEINTRESOURCE(IDC_ARROW), /* hand2 */ +! MAKEINTRESOURCE(IDC_ARROW), /* pencil */ +! MAKEINTRESOURCE(IDC_ARROW), /* question */ +! MAKEINTRESOURCE(IDC_ARROW), /* right-arrow */ +! MAKEINTRESOURCE(IDC_UPARROW), /* up-arrow */ +! MAKEINTRESOURCE(IDC_ARROW) /* last one */ + }; + + void +--- 3265,3291 ---- + * misc2.c! */ + static LPCSTR mshape_idcs[] = + { +! IDC_ARROW, /* arrow */ +! MAKEINTRESOURCE(0), /* blank */ +! IDC_IBEAM, /* beam */ +! IDC_SIZENS, /* updown */ +! IDC_SIZENS, /* udsizing */ +! IDC_SIZEWE, /* leftright */ +! IDC_SIZEWE, /* lrsizing */ +! IDC_WAIT, /* busy */ + #ifdef WIN3264 +! IDC_NO, /* no */ + #else +! IDC_ICON, /* no */ + #endif +! IDC_ARROW, /* crosshair */ +! IDC_ARROW, /* hand1 */ +! IDC_ARROW, /* hand2 */ +! IDC_ARROW, /* pencil */ +! IDC_ARROW, /* question */ +! IDC_ARROW, /* right-arrow */ +! IDC_UPARROW, /* up-arrow */ +! IDC_ARROW /* last one */ + }; + + void +*************** +*** 3298,3304 **** + else + { + if (shape >= MSHAPE_NUMBERED) +! idc = MAKEINTRESOURCE(IDC_ARROW); + else + idc = mshape_idcs[shape]; + #ifdef SetClassLongPtr +--- 3298,3304 ---- + else + { + if (shape >= MSHAPE_NUMBERED) +! idc = IDC_ARROW; + else + idc = mshape_idcs[shape]; + #ifdef SetClassLongPtr +*** ../vim-7.3.869/src/os_mswin.c 2013-02-26 14:56:24.000000000 +0100 +--- src/os_mswin.c 2013-03-19 14:45:24.000000000 +0100 +*************** +*** 184,195 **** +--- 184,197 ---- + } + # endif + ++ # if !defined(__MINGW32__) || (__GNUC__ < 4) + int _chdrive(int drive) + { + char temp [3] = "-:"; + temp[0] = drive + 'A' - 1; + return !SetCurrentDirectory(temp); + } ++ # endif + #else + # ifdef __BORLANDC__ + /* being a more ANSI compliant compiler, BorlandC doesn't define _stricoll: +*** ../vim-7.3.869/src/os_win32.c 2013-02-26 14:56:24.000000000 +0100 +--- src/os_win32.c 2013-03-19 14:45:24.000000000 +0100 +*************** +*** 163,169 **** + + /* Enable common dialogs input unicode from IME if posible. */ + #ifdef FEAT_MBYTE +! LRESULT (WINAPI *pDispatchMessage)(LPMSG) = DispatchMessage; + BOOL (WINAPI *pGetMessage)(LPMSG, HWND, UINT, UINT) = GetMessage; + BOOL (WINAPI *pIsDialogMessage)(HWND, LPMSG) = IsDialogMessage; + BOOL (WINAPI *pPeekMessage)(LPMSG, HWND, UINT, UINT, UINT) = PeekMessage; +--- 163,169 ---- + + /* Enable common dialogs input unicode from IME if posible. */ + #ifdef FEAT_MBYTE +! LRESULT (WINAPI *pDispatchMessage)(CONST MSG *) = DispatchMessage; + BOOL (WINAPI *pGetMessage)(LPMSG, HWND, UINT, UINT) = GetMessage; + BOOL (WINAPI *pIsDialogMessage)(HWND, LPMSG) = IsDialogMessage; + BOOL (WINAPI *pPeekMessage)(LPMSG, HWND, UINT, UINT, UINT) = PeekMessage; +*************** +*** 3464,3470 **** + && (lnum != curbuf->b_ml.ml_line_count + || curbuf->b_p_eol))) + { +! WriteFile(g_hChildStd_IN_Wr, "\n", 1, &ignored, NULL); + } + + ++lnum; +--- 3464,3470 ---- + && (lnum != curbuf->b_ml.ml_line_count + || curbuf->b_p_eol))) + { +! WriteFile(g_hChildStd_IN_Wr, "\n", 1, (LPDWORD)&ignored, NULL); + } + + ++lnum; +*** ../vim-7.3.869/src/os_win32.h 2012-11-20 16:53:34.000000000 +0100 +--- src/os_win32.h 2013-03-19 14:45:24.000000000 +0100 +*************** +*** 204,210 **** + /* Enable common dialogs input unicode from IME if posible. */ + #ifdef FEAT_MBYTE + /* The variables are defined in os_win32.c. */ +! extern LRESULT (WINAPI *pDispatchMessage)(LPMSG); + extern BOOL (WINAPI *pGetMessage)(LPMSG, HWND, UINT, UINT); + extern BOOL (WINAPI *pIsDialogMessage)(HWND, LPMSG); + extern BOOL (WINAPI *pPeekMessage)(LPMSG, HWND, UINT, UINT, UINT); +--- 204,210 ---- + /* Enable common dialogs input unicode from IME if posible. */ + #ifdef FEAT_MBYTE + /* The variables are defined in os_win32.c. */ +! extern LRESULT (WINAPI *pDispatchMessage)(CONST MSG *); + extern BOOL (WINAPI *pGetMessage)(LPMSG, HWND, UINT, UINT); + extern BOOL (WINAPI *pIsDialogMessage)(HWND, LPMSG); + extern BOOL (WINAPI *pPeekMessage)(LPMSG, HWND, UINT, UINT, UINT); +*** ../vim-7.3.869/src/version.c 2013-03-19 14:25:50.000000000 +0100 +--- src/version.c 2013-03-19 14:45:42.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 870, + /**/ + +-- +Q: How many legs does a giraffe have? +A: Eight: two in front, two behind, two on the left and two on the right + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9681cac6fc0777b081a1503227d3ae207487f47e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:28 +0200 Subject: [PATCH 0757/3340] - patchlevel 871 --- 7.3.871 | 102 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 102 insertions(+) create mode 100644 7.3.871 diff --git a/7.3.871 b/7.3.871 new file mode 100644 index 00000000..25ab1dd0 --- /dev/null +++ b/7.3.871 @@ -0,0 +1,102 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.871 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.871 +Problem: search('^$', 'c') does not use the empty match under the cursor. +Solution: Special handling of the 'c' flag. (Christian Brabandt) + Add tests. +Files: src/search.c, src/testdir/test14.in, src/testdir/test14.ok + + +*** ../vim-7.3.870/src/search.c 2013-02-20 18:39:07.000000000 +0100 +--- src/search.c 2013-03-19 15:23:13.000000000 +0100 +*************** +*** 727,732 **** +--- 727,734 ---- + ++matchcol; + } + } ++ if (options & SEARCH_START) ++ break; + if (ptr[matchcol] == NUL + || (nmatched = vim_regexec_multi(®match, + win, buf, lnum + matchpos.lnum, +*** ../vim-7.3.870/src/testdir/test14.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test14.in 2013-03-19 15:21:54.000000000 +0100 +*************** +*** 2,7 **** +--- 2,8 ---- + Also test ":s/pat/sub/" with different ~s in sub. + Also test for ^Vxff and ^Vo123 in Insert mode. + Also test "[m", "]m", "[M" and "]M" ++ Also test search() + + STARTTEST + :so small.vim +*************** +*** 34,39 **** +--- 35,50 ---- + 2[MaJ:.w >>test.out + k[MaK:.w >>test.out + 3[MaL:.w >>test.out ++ :" ++ /^foobar ++ :let startline = line('.') ++ :call search('foobar', 'c') ++ :call append(line('$'), line('.') - startline) ++ j:call search('^$', 'c') ++ :call append(line('$'), line('.') - startline) ++ :call search('^$', 'bc') ++ :call append(line('$'), line('.') - startline) ++ :/^search()/,$w >>test.out + :qa! + ENDTEST + +*************** +*** 64,66 **** +--- 75,82 ---- + } + } e3 + } ++ ++ foobar ++ ++ ++ search() +*** ../vim-7.3.870/src/testdir/test14.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test14.ok 2013-03-19 15:26:18.000000000 +0100 +*************** +*** 15,17 **** +--- 15,21 ---- + }JH e3 + }K e2 + {LF ++ search() ++ 0 ++ 1 ++ 1 +*** ../vim-7.3.870/src/version.c 2013-03-19 14:48:25.000000000 +0100 +--- src/version.c 2013-03-19 15:26:38.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 871, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +75. You start wondering whether you could actually upgrade your brain + with a Pentium Pro microprocessor 80. The upgrade works just fine. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 30914c92e24edb2b1f5090ba1382fb0e317760d4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:28 +0200 Subject: [PATCH 0758/3340] - patchlevel 872 --- 7.3.872 | 524 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 524 insertions(+) create mode 100644 7.3.872 diff --git a/7.3.872 b/7.3.872 new file mode 100644 index 00000000..0e407f45 --- /dev/null +++ b/7.3.872 @@ -0,0 +1,524 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.872 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.872 +Problem: On some systems case of file names is always ignored, on others + never. +Solution: Add the 'fileignorecase' option to control this at runtime. + Implies 'wildignorecase'. +Files: src/buffer.c, src/edit.c, src/ex_cmds2.c, src/ex_getln.c, + src/fileio.c, src/misc1.c, src/misc2.c, src/option.c, + src/option.h, src/vim.h, runtime/doc/options.txt + + +*** ../vim-7.3.871/src/buffer.c 2013-03-19 14:25:50.000000000 +0100 +--- src/buffer.c 2013-03-19 16:03:42.000000000 +0100 +*************** +*** 2401,2412 **** + if (name != NULL) + { + regmatch.regprog = prog; +! #ifdef CASE_INSENSITIVE_FILENAME +! regmatch.rm_ic = TRUE; /* Always ignore case */ +! #else +! regmatch.rm_ic = FALSE; /* Never ignore case */ +! #endif +! + if (vim_regexec(®match, name, (colnr_T)0)) + match = name; + else +--- 2401,2407 ---- + if (name != NULL) + { + regmatch.regprog = prog; +! regmatch.rm_ic = p_fic; /* ignore case when 'fileignorecase' is set */ + if (vim_regexec(®match, name, (colnr_T)0)) + match = name; + else +*** ../vim-7.3.871/src/edit.c 2013-03-19 13:33:18.000000000 +0100 +--- src/edit.c 2013-03-19 15:43:19.000000000 +0100 +*************** +*** 4336,4348 **** + + /* May change home directory back to "~". */ + tilde_replace(compl_pattern, num_matches, matches); +! ins_compl_add_matches(num_matches, matches, +! #ifdef CASE_INSENSITIVE_FILENAME +! TRUE +! #else +! FALSE +! #endif +! ); + } + break; + +--- 4336,4342 ---- + + /* May change home directory back to "~". */ + tilde_replace(compl_pattern, num_matches, matches); +! ins_compl_add_matches(num_matches, matches, p_fic || p_wic); + } + break; + +*** ../vim-7.3.871/src/ex_cmds2.c 2012-10-03 18:24:55.000000000 +0200 +--- src/ex_cmds2.c 2013-03-19 16:03:50.000000000 +0100 +*************** +*** 1926,1936 **** + * Delete the items: use each item as a regexp and find a match in the + * argument list. + */ +! #ifdef CASE_INSENSITIVE_FILENAME +! regmatch.rm_ic = TRUE; /* Always ignore case */ +! #else +! regmatch.rm_ic = FALSE; /* Never ignore case */ +! #endif + for (i = 0; i < new_ga.ga_len && !got_int; ++i) + { + p = ((char_u **)new_ga.ga_data)[i]; +--- 1926,1932 ---- + * Delete the items: use each item as a regexp and find a match in the + * argument list. + */ +! regmatch.rm_ic = p_fic; /* ignore case when 'fileignorecase' is set */ + for (i = 0; i < new_ga.ga_len && !got_int; ++i) + { + p = ((char_u **)new_ga.ga_data)[i]; +*** ../vim-7.3.871/src/ex_getln.c 2012-11-28 16:49:53.000000000 +0100 +--- src/ex_getln.c 2013-03-19 16:03:53.000000000 +0100 +*************** +*** 3653,3671 **** + { + for (i = 0; i < xp->xp_numfiles; ++i) + { +! #ifdef CASE_INSENSITIVE_FILENAME +! if (xp->xp_context == EXPAND_DIRECTORIES + || xp->xp_context == EXPAND_FILES + || xp->xp_context == EXPAND_SHELLCMD +! || xp->xp_context == EXPAND_BUFFERS) + { + if (TOLOWER_LOC(xp->xp_files[i][len]) != + TOLOWER_LOC(xp->xp_files[0][len])) + break; + } +! else +! #endif +! if (xp->xp_files[i][len] != xp->xp_files[0][len]) + break; + } + if (i < xp->xp_numfiles) +--- 3653,3668 ---- + { + for (i = 0; i < xp->xp_numfiles; ++i) + { +! if (p_fic && (xp->xp_context == EXPAND_DIRECTORIES + || xp->xp_context == EXPAND_FILES + || xp->xp_context == EXPAND_SHELLCMD +! || xp->xp_context == EXPAND_BUFFERS)) + { + if (TOLOWER_LOC(xp->xp_files[i][len]) != + TOLOWER_LOC(xp->xp_files[0][len])) + break; + } +! else if (xp->xp_files[i][len] != xp->xp_files[0][len]) + break; + } + if (i < xp->xp_numfiles) +*** ../vim-7.3.871/src/fileio.c 2013-03-19 13:33:18.000000000 +0100 +--- src/fileio.c 2013-03-19 15:49:28.000000000 +0100 +*************** +*** 6485,6493 **** + #ifdef HAVE_ACL + vim_acl_T acl; /* ACL from original file */ + #endif +- #if defined(UNIX) || defined(CASE_INSENSITIVE_FILENAME) + int use_tmp_file = FALSE; +- #endif + + /* + * When the names are identical, there is nothing to do. When they refer +--- 6485,6491 ---- +*************** +*** 6496,6506 **** + */ + if (fnamecmp(from, to) == 0) + { +! #ifdef CASE_INSENSITIVE_FILENAME +! if (STRCMP(gettail(from), gettail(to)) != 0) + use_tmp_file = TRUE; + else +- #endif + return 0; + } + +--- 6494,6502 ---- + */ + if (fnamecmp(from, to) == 0) + { +! if (p_fic && STRCMP(gettail(from), gettail(to)) != 0) + use_tmp_file = TRUE; + else + return 0; + } + +*************** +*** 6539,6545 **** + } + #endif + +- #if defined(UNIX) || defined(CASE_INSENSITIVE_FILENAME) + if (use_tmp_file) + { + char tempname[MAXPATHL + 1]; +--- 6535,6540 ---- +*************** +*** 6572,6578 **** + } + return -1; + } +- #endif + + /* + * Delete the "to" file, this is required on some systems to make the +--- 6567,6572 ---- +*************** +*** 10007,10017 **** + int match = FALSE; + #endif + +! #ifdef CASE_INSENSITIVE_FILENAME +! regmatch.rm_ic = TRUE; /* Always ignore case */ +! #else +! regmatch.rm_ic = FALSE; /* Don't ever ignore case */ +! #endif + #ifdef FEAT_OSFILETYPE + if (*pattern == '<') + { +--- 10001,10007 ---- + int match = FALSE; + #endif + +! regmatch.rm_ic = p_fic; /* ignore case if 'fileignorecase' is set */ + #ifdef FEAT_OSFILETYPE + if (*pattern == '<') + { +*** ../vim-7.3.871/src/misc1.c 2013-03-16 21:35:28.000000000 +0100 +--- src/misc1.c 2013-03-19 16:16:24.000000000 +0100 +*************** +*** 5026,5041 **** + return retval; + } + +- #if (defined(CASE_INSENSITIVE_FILENAME) && defined(BACKSLASH_IN_FILENAME)) \ +- || defined(PROTO) + /* +! * Versions of fnamecmp() and fnamencmp() that handle '/' and '\' equally. + */ + int + vim_fnamecmp(x, y) + char_u *x, *y; + { + return vim_fnamencmp(x, y, MAXPATHL); + } + + int +--- 5026,5046 ---- + return retval; + } + + /* +! * Versions of fnamecmp() and fnamencmp() that handle '/' and '\' equally +! * and deal with 'fileignorecase'. + */ + int + vim_fnamecmp(x, y) + char_u *x, *y; + { ++ #ifdef BACKSLASH_IN_FILENAME + return vim_fnamencmp(x, y, MAXPATHL); ++ #else ++ if (p_fic) ++ return MB_STRICMP(x, y); ++ return STRCMP(x, y); ++ #endif + } + + int +*************** +*** 5043,5051 **** + char_u *x, *y; + size_t len; + { + while (len > 0 && *x && *y) + { +! if (TOLOWER_LOC(*x) != TOLOWER_LOC(*y) + && !(*x == '/' && *y == '\\') + && !(*x == '\\' && *y == '/')) + break; +--- 5048,5058 ---- + char_u *x, *y; + size_t len; + { ++ #ifdef BACKSLASH_IN_FILENAME ++ /* TODO: multi-byte characters. */ + while (len > 0 && *x && *y) + { +! if ((p_fic ? TOLOWER_LOC(*x) != TOLOWER_LOC(*y) : *x != *y) + && !(*x == '/' && *y == '\\') + && !(*x == '\\' && *y == '/')) + break; +*************** +*** 5056,5063 **** + if (len == 0) + return 0; + return (*x - *y); +! } + #endif + + /* + * Concatenate file names fname1 and fname2 into allocated memory. +--- 5063,5074 ---- + if (len == 0) + return 0; + return (*x - *y); +! #else +! if (p_fic) +! return MB_STRNICMP(x, y, len); +! return STRNCMP(x, y, len); + #endif ++ } + + /* + * Concatenate file names fname1 and fname2 into allocated memory. +*************** +*** 9835,9845 **** + } + else if (path_end >= path + wildoff + && (vim_strchr((char_u *)"*?[{~$", *path_end) != NULL +! #ifndef CASE_INSENSITIVE_FILENAME +! || ((flags & EW_ICASE) +! && isalpha(PTR2CHAR(path_end))) +! #endif +! )) + e = p; + #ifdef FEAT_MBYTE + if (has_mbyte) +--- 9846,9853 ---- + } + else if (path_end >= path + wildoff + && (vim_strchr((char_u *)"*?[{~$", *path_end) != NULL +! || (!p_fic && (flags & EW_ICASE) +! && isalpha(PTR2CHAR(path_end))))) + e = p; + #ifdef FEAT_MBYTE + if (has_mbyte) +*************** +*** 9882,9895 **** + } + + /* compile the regexp into a program */ +- #ifdef CASE_INSENSITIVE_FILENAME +- regmatch.rm_ic = TRUE; /* Behave like Terminal.app */ +- #else + if (flags & EW_ICASE) + regmatch.rm_ic = TRUE; /* 'wildignorecase' set */ + else +! regmatch.rm_ic = FALSE; /* Don't ignore case */ +! #endif + if (flags & (EW_NOERROR | EW_NOTWILD)) + ++emsg_silent; + regmatch.regprog = vim_regcomp(pat, RE_MAGIC); +--- 9890,9899 ---- + } + + /* compile the regexp into a program */ + if (flags & EW_ICASE) + regmatch.rm_ic = TRUE; /* 'wildignorecase' set */ + else +! regmatch.rm_ic = p_fic; /* ignore case when 'fileignorecase' is set */ + if (flags & (EW_NOERROR | EW_NOTWILD)) + ++emsg_silent; + regmatch.regprog = vim_regcomp(pat, RE_MAGIC); +*** ../vim-7.3.871/src/misc2.c 2012-11-28 18:31:49.000000000 +0100 +--- src/misc2.c 2013-03-19 16:39:56.000000000 +0100 +*************** +*** 5362,5374 **** + if (STRLEN(s1) != STRLEN(s2)) + return FAIL; + + for (i = 0; s1[i] != NUL && s2[i] != NUL; i++) + { + if (s1[i] != s2[i] +! #ifdef CASE_INSENSITIVE_FILENAME +! && TOUPPER_LOC(s1[i]) != TOUPPER_LOC(s2[i]) +! #endif +! ) + { + if (i >= 2) + if (s1[i-1] == '*' && s1[i-2] == '*') +--- 5362,5372 ---- + if (STRLEN(s1) != STRLEN(s2)) + return FAIL; + ++ /* TODO: handle multi-byte characters. */ + for (i = 0; s1[i] != NUL && s2[i] != NUL; i++) + { + if (s1[i] != s2[i] +! && (!p_fic || TOUPPER_LOC(s1[i]) != TOUPPER_LOC(s2[i]))) + { + if (i >= 2) + if (s1[i-1] == '*' && s1[i-2] == '*') +*************** +*** 6123,6134 **** + break; + } + +! if ( +! #ifdef CASE_INSENSITIVE_FILENAME +! TOUPPER_LOC(p[i]) != TOUPPER_LOC(q[i]) +! #else +! p[i] != q[i] +! #endif + #ifdef BACKSLASH_IN_FILENAME + /* consider '/' and '\\' to be equal */ + && !((p[i] == '/' && q[i] == '\\') +--- 6121,6127 ---- + break; + } + +! if ((p_fic ? TOUPPER_LOC(p[i]) != TOUPPER_LOC(q[i]) : p[i] != q[i]) + #ifdef BACKSLASH_IN_FILENAME + /* consider '/' and '\\' to be equal */ + && !((p[i] == '/' && q[i] == '\\') +*** ../vim-7.3.871/src/option.c 2013-03-13 20:42:28.000000000 +0100 +--- src/option.c 2013-03-19 15:40:25.000000000 +0100 +*************** +*** 1108,1113 **** +--- 1108,1122 ---- + (char_u *)&p_ffs, PV_NONE, + {(char_u *)DFLT_FFS_VI, (char_u *)DFLT_FFS_VIM} + SCRIPTID_INIT}, ++ {"fileignorecase", "fic", P_BOOL|P_VI_DEF, ++ (char_u *)&p_fic, PV_NONE, ++ { ++ #ifdef CASE_INSENSITIVE_FILENAME ++ (char_u *)TRUE, ++ #else ++ (char_u *)FALSE, ++ #endif ++ (char_u *)0L} SCRIPTID_INIT}, + {"filetype", "ft", P_STRING|P_ALLOCED|P_VI_DEF|P_NOGLOB|P_NFNAME, + #ifdef FEAT_AUTOCMD + (char_u *)&p_ft, PV_FT, +*** ../vim-7.3.871/src/option.h 2012-08-15 16:20:59.000000000 +0200 +--- src/option.h 2013-03-19 15:42:24.000000000 +0100 +*************** +*** 453,458 **** +--- 453,459 ---- + EXTERN char_u *p_fencs; /* 'fileencodings' */ + #endif + EXTERN char_u *p_ffs; /* 'fileformats' */ ++ EXTERN long p_fic; /* 'fileignorecase' */ + #ifdef FEAT_FOLDING + EXTERN char_u *p_fcl; /* 'foldclose' */ + EXTERN long p_fdls; /* 'foldlevelstart' */ +*** ../vim-7.3.871/src/vim.h 2013-03-19 13:33:18.000000000 +0100 +--- src/vim.h 2013-03-19 16:14:29.000000000 +0100 +*************** +*** 1627,1644 **** + * (this does not account for maximum name lengths and things like "../dir", + * thus it is not 100% accurate!) + */ +! #ifdef CASE_INSENSITIVE_FILENAME +! # ifdef BACKSLASH_IN_FILENAME +! # define fnamecmp(x, y) vim_fnamecmp((x), (y)) +! # define fnamencmp(x, y, n) vim_fnamencmp((x), (y), (size_t)(n)) +! # else +! # define fnamecmp(x, y) MB_STRICMP((x), (y)) +! # define fnamencmp(x, y, n) MB_STRNICMP((x), (y), (n)) +! # endif +! #else +! # define fnamecmp(x, y) strcmp((char *)(x), (char *)(y)) +! # define fnamencmp(x, y, n) strncmp((char *)(x), (char *)(y), (size_t)(n)) +! #endif + + #ifdef HAVE_MEMSET + # define vim_memset(ptr, c, size) memset((ptr), (c), (size)) +--- 1627,1634 ---- + * (this does not account for maximum name lengths and things like "../dir", + * thus it is not 100% accurate!) + */ +! #define fnamecmp(x, y) vim_fnamecmp((char_u *)(x), (char_u *)(y)) +! #define fnamencmp(x, y, n) vim_fnamencmp((char_u *)(x), (char_u *)(y), (size_t)(n)) + + #ifdef HAVE_MEMSET + # define vim_memset(ptr, c, size) memset((ptr), (c), (size)) +*** ../vim-7.3.871/runtime/doc/options.txt 2013-01-23 18:37:31.000000000 +0100 +--- runtime/doc/options.txt 2013-03-19 16:25:49.000000000 +0100 +*************** +*** 2895,2900 **** +--- 2941,2954 ---- + NOTE: This option is set to the Vi default value when 'compatible' is + set and to the Vim default value when 'compatible' is reset. + ++ *'fileignorecase'* *'wic'* *'nofileignorecase'* *'nowic'* ++ 'fileignorecase' 'wic' boolean (default on for systems where case in file ++ names is normally ignored. ++ global ++ {not in Vi} ++ When set case is ignored when using file names and directories. ++ See 'wildignorecase' for only ignoring case when doing completion. ++ + *'filetype'* *'ft'* + 'filetype' 'ft' string (default: "") + local to buffer +*************** +*** 7832,7843 **** + uses another default. + + +! *'wildignorecase* *'wic'* *'nowildignorecase* *'nowic'* + 'wildignorecase' 'wic' boolean (default off) + global + {not in Vi} + When set case is ignored when completing file names and directories. +! Has no effect on systems where file name case is generally ignored. + Does not apply when the shell is used to expand wildcards, which + happens when there are special characters. + +--- 7906,7917 ---- + uses another default. + + +! *'wildignorecase'* *'wic'* *'nowildignorecase'* *'nowic'* + 'wildignorecase' 'wic' boolean (default off) + global + {not in Vi} + When set case is ignored when completing file names and directories. +! Has no effect when 'fileignorecase' is set. + Does not apply when the shell is used to expand wildcards, which + happens when there are special characters. + +*** ../vim-7.3.871/src/version.c 2013-03-19 15:27:43.000000000 +0100 +--- src/version.c 2013-03-19 16:22:46.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 872, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +76. Your ISP regards you as a business partner rather than as a customer. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 31a88b7740602cc9dee2d50537b8734d7822c5c8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:29 +0200 Subject: [PATCH 0759/3340] - patchlevel 873 --- 7.3.873 | Bin 0 -> 5967 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 7.3.873 diff --git a/7.3.873 b/7.3.873 new file mode 100644 index 0000000000000000000000000000000000000000..dbb636522de863509795ff0e986878acd762c1a6 GIT binary patch literal 5967 zcmcgwTXW*Z63*jcs?KYkdpDk)`woai4#kpOM*D5mnf*S)T_AIC)=kH<8sU2$KG7@s)M z9x_R48xJAdw!VwRFrc9W0C4GXE+kMdX2A-Qn1U076cBo!C`cv)3ceT9I=K}=B9)l{ zzj|{DFWnnAc?l7XlRyIFo1@|6zg|dVcU#PPEC_`+s-O_BcV*>t35Dx&xWvS%9 z+G=e#xqx%1nXkwTB`}`J=%HI0C)|f~I7yqQzx8fzG9>}yl;apb;7JJQV7w~n6=0l6 z7>fvgxx9pmzByw+`B#R0$HpT%hU=?~?!#68;zl8oInw~7+NQE?>yLKk!3%;thxS~4 z5S;FfN|F4>-QEuAI;NJ{)@;kNvY0BCejxy*QoLYTBTg!D(5Y0oj{_vgk(YFD*M8 z9$Xb^%4odjIcoVG-x%xPQwCaQ2cd6f415;!JA`^N{5!NAi6@3&fBvV1VSoO=5{k7o z$jKeW$3~_&N!o^HTOA`ylJ6)Vu`vP2BC1#5L&PM-wP%=&$28J_jlmbQ6|fj$D(hIX zUZgQ*V>n6EX1f5MVwwAx#4;631xh~FNna%ol7|K{RdmuT&`qMDfJ^X2sFv9n7EDe> zB0)|m$kmMcUMw?3JDI9XIQic9HSkYQF<%L6)ylU&4Z2sEhiLQEiyy+_O48Fcf!ij+ zk`wrEf<*=K#SS#jcX@}Q%5Ci1aD5#Ygf&u8wV^}F0{b~>8fGV|p> z=kA|DaG0IXcI`NZJ_4DC<1j~`Z_D;J<^WGOY$;;uBLNO`wJ3j!lI4yHex+rn1hGyAm(%`Ndo1JX+{^-Q|d);+$V~XFmy6b1( zUH#i{bW&CQJsnRTNiT5&_o|om_I0=C2K{;8P28(F%3b~TbNA}Dn<9u`52jOSRI8<( ztyd;As%2|uc}0%iM+6|gjR}D4N>YU$sX{+hdfUBt-(An)#8d(op*LZE;Vf-KYp?4C z&eCpb9rOR^dZXBN)37wtXg@~8G&-7To@ItT&3)zk_eXM2eEKUK%%z{s!A4VSbRIo! zG&L&^MC7V)`zqYusBk9;QVKnNH~v^VJw+UBt0q5`}48}<$hTM z_oX{@UusY;r!k>^#W|5J-9nPSQ)g;+a>4 zX#EYy7NUiarY}TmdACHgROcbIHt_Aa!C*B&v{t)lS$k+5LGwJ{8_%J6E}hfdbegTB zR;-4tSsQ`FX1+Mg|AjSS;VuZk^508Rg~4hyAXWH$fB*TYYVozDCn2ygLly3p%R5qq z)nKsN)_u5E%+ssI`u3I8nbSOTTKiX4**#aWlESMjE`U?k|?IZ7)Hzs zP~y$IwK*{euFit9so=Cu2dy>EF31NE;B{fb%GkRHa=4t%pj!c@5P&+Z(+`S$-+&`-dtW@*M1d2;PFwW H4|V+k&C&hV literal 0 HcmV?d00001 From 6fe1da80c6eab689d5ec6668f4ae81a2e520a92f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:29 +0200 Subject: [PATCH 0760/3340] - patchlevel 874 --- 7.3.874 | 139 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 139 insertions(+) create mode 100644 7.3.874 diff --git a/7.3.874 b/7.3.874 new file mode 100644 index 00000000..3b0f51b1 --- /dev/null +++ b/7.3.874 @@ -0,0 +1,139 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.874 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.874 +Problem: Comparing file names does not handle multi-byte characters + properly. +Solution: Implement multi-byte handling. +Files: src/misc1.c, src/misc2.c + + +*** ../vim-7.3.873/src/misc1.c 2013-03-19 16:46:59.000000000 +0100 +--- src/misc1.c 2013-03-19 18:30:52.000000000 +0100 +*************** +*** 5049,5068 **** + size_t len; + { + #ifdef BACKSLASH_IN_FILENAME + /* TODO: multi-byte characters. */ +! while (len > 0 && *x && *y) + { +! if ((p_fic ? TOLOWER_LOC(*x) != TOLOWER_LOC(*y) : *x != *y) +! && !(*x == '/' && *y == '\\') +! && !(*x == '\\' && *y == '/')) + break; +! ++x; +! ++y; +! --len; + } + if (len == 0) + return 0; +! return (*x - *y); + #else + if (p_fic) + return MB_STRNICMP(x, y, len); +--- 5049,5076 ---- + size_t len; + { + #ifdef BACKSLASH_IN_FILENAME ++ char_u *px = x; ++ char_u *py = y; ++ int cx = NUL; ++ int cy = NUL; ++ + /* TODO: multi-byte characters. */ +! while (len > 0) + { +! cx = PTR2CHAR(px); +! cy = PTR2CHAR(py); +! if (cx == NUL || cy == NUL +! || ((p_fic ? MB_TOLOWER(cx) != MB_TOLOWER(cy) : cx != cy) +! && !(cx == '/' && cy == '\\') +! && !(cx == '\\' && cy == '/'))) + break; +! len -= MB_PTR2LEN(px); +! px += MB_PTR2LEN(px); +! py += MB_PTR2LEN(py); + } + if (len == 0) + return 0; +! return (cx - cy); + #else + if (p_fic) + return MB_STRNICMP(x, y, len); +*** ../vim-7.3.873/src/misc2.c 2013-03-19 16:46:59.000000000 +0100 +--- src/misc2.c 2013-03-19 18:22:29.000000000 +0100 +*************** +*** 5352,5357 **** +--- 5352,5359 ---- + char_u *s2; + { + int i; ++ int prev1 = NUL; ++ int prev2 = NUL; + + if (s1 == s2) + return TRUE; +*************** +*** 5362,5381 **** + if (STRLEN(s1) != STRLEN(s2)) + return FAIL; + +! /* TODO: handle multi-byte characters. */ +! for (i = 0; s1[i] != NUL && s2[i] != NUL; i++) + { +! if (s1[i] != s2[i] +! && (!p_fic || TOUPPER_LOC(s1[i]) != TOUPPER_LOC(s2[i]))) +! { +! if (i >= 2) +! if (s1[i-1] == '*' && s1[i-2] == '*') +! continue; +! else +! return FAIL; +! else +! return FAIL; +! } + } + return TRUE; + } +--- 5364,5379 ---- + if (STRLEN(s1) != STRLEN(s2)) + return FAIL; + +! for (i = 0; s1[i] != NUL && s2[i] != NUL; i += MB_PTR2LEN(s1 + i)) + { +! int c1 = PTR2CHAR(s1 + i); +! int c2 = PTR2CHAR(s2 + i); +! +! if ((p_fic ? MB_TOLOWER(c1) != MB_TOLOWER(c2) : c1 != c2) +! && (prev1 != '*' || prev2 != '*')) +! return FAIL; +! prev2 = prev1; +! prev1 = c1; + } + return TRUE; + } +*** ../vim-7.3.873/src/version.c 2013-03-19 17:42:10.000000000 +0100 +--- src/version.c 2013-03-19 18:24:57.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 874, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +80. At parties, you introduce your spouse as your "service provider." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5c4a61c945d0a0e012ff6a21d1be8803b79f045d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:30 +0200 Subject: [PATCH 0761/3340] - patchlevel 875 --- 7.3.875 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.875 diff --git a/7.3.875 b/7.3.875 new file mode 100644 index 00000000..155d6567 --- /dev/null +++ b/7.3.875 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.875 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.875 (after 7.3.866) +Problem: Build problem with some combination of features. +Solution: Use FEAT_XCLIPBOARD instead of FEAT_CLIPBOARD. +Files: src/os_unix.c + + +*** ../vim-7.3.874/src/os_unix.c 2013-03-19 12:35:33.000000000 +0100 +--- src/os_unix.c 2013-03-21 21:43:37.000000000 +0100 +*************** +*** 4787,4793 **** + else + wait_pid = 0; + +! # if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) + /* Handle any X events, e.g. serving the clipboard. */ + clip_update(); + # endif +--- 4787,4793 ---- + else + wait_pid = 0; + +! # if defined(FEAT_XCLIPBOARD) && defined(FEAT_X11) + /* Handle any X events, e.g. serving the clipboard. */ + clip_update(); + # endif +*************** +*** 4817,4823 **** + close(toshell_fd); + close(fromshell_fd); + } +! # if defined(FEAT_CLIPBOARD) && defined(FEAT_X11) + else + { + /* +--- 4817,4823 ---- + close(toshell_fd); + close(fromshell_fd); + } +! # if defined(FEAT_XCLIPBOARD) && defined(FEAT_X11) + else + { + /* +*** ../vim-7.3.874/src/version.c 2013-03-19 18:31:45.000000000 +0100 +--- src/version.c 2013-03-21 22:05:59.000000000 +0100 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 875, + /**/ + +-- +From "know your smileys": + O:-) Saint + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9013d9abcb096e6b648b0bb555cc6cb08ea57285 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:31 +0200 Subject: [PATCH 0762/3340] - patchlevel 876 --- 7.3.876 | 80 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 7.3.876 diff --git a/7.3.876 b/7.3.876 new file mode 100644 index 00000000..573df0da --- /dev/null +++ b/7.3.876 @@ -0,0 +1,80 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.876 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.876 +Problem: #if indents are off. +Solution: Insert a space where appropriate. (Taro Muraoka) +Files: src/gui.c + + +*** ../vim-7.3.875/src/gui.c 2013-01-23 18:37:31.000000000 +0100 +--- src/gui.c 2013-03-27 22:44:19.000000000 +0100 +*************** +*** 991,997 **** + } + + gui_mch_free_font(gui.wide_font); +! #ifdef FEAT_GUI_GTK + /* Avoid unnecessary overhead if 'guifontwide' is equal to 'guifont'. */ + if (font != NOFONT && gui.norm_font != NOFONT + && pango_font_description_equal(font, gui.norm_font)) +--- 991,997 ---- + } + + gui_mch_free_font(gui.wide_font); +! # ifdef FEAT_GUI_GTK + /* Avoid unnecessary overhead if 'guifontwide' is equal to 'guifont'. */ + if (font != NOFONT && gui.norm_font != NOFONT + && pango_font_description_equal(font, gui.norm_font)) +*************** +*** 1000,1010 **** + gui_mch_free_font(font); + } + else +! #endif + gui.wide_font = font; +! #ifdef FEAT_GUI_MSWIN + gui_mch_wide_font_changed(); +! #endif + return OK; + } + #endif +--- 1000,1010 ---- + gui_mch_free_font(font); + } + else +! # endif + gui.wide_font = font; +! # ifdef FEAT_GUI_MSWIN + gui_mch_wide_font_changed(); +! # endif + return OK; + } + #endif +*** ../vim-7.3.875/src/version.c 2013-03-21 22:53:45.000000000 +0100 +--- src/version.c 2013-04-03 21:10:44.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 876, + /**/ + +-- +Nobody will ever need more than 640 kB RAM. + -- Bill Gates, 1983 +Windows 98 requires 16 MB RAM. + -- Bill Gates, 1999 +Logical conclusion: Nobody will ever need Windows 98. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 74c289cb457afdae7d1fc0156fb5e31e0fb32fb6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:31 +0200 Subject: [PATCH 0763/3340] - patchlevel 877 --- 7.3.877 | 100 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 100 insertions(+) create mode 100644 7.3.877 diff --git a/7.3.877 b/7.3.877 new file mode 100644 index 00000000..7a563997 --- /dev/null +++ b/7.3.877 @@ -0,0 +1,100 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.877 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.877 (after 7.3.871) +Problem: Forward searching with search() is broken. +Solution: Fix it and add tests. (Sung Pae) +Files: src/search.c, src/testdir/test14.in, src/testdir/test14.ok + + +*** ../vim-7.3.876/src/search.c 2013-03-19 15:27:43.000000000 +0100 +--- src/search.c 2013-04-03 21:07:11.000000000 +0200 +*************** +*** 727,733 **** + ++matchcol; + } + } +! if (options & SEARCH_START) + break; + if (ptr[matchcol] == NUL + || (nmatched = vim_regexec_multi(®match, +--- 727,733 ---- + ++matchcol; + } + } +! if (matchcol == 0 && (options & SEARCH_START)) + break; + if (ptr[matchcol] == NUL + || (nmatched = vim_regexec_multi(®match, +*************** +*** 869,875 **** + /* With the SEARCH_END option move to the last character + * of the match. Don't do it for an empty match, end + * should be same as start then. */ +! if (options & SEARCH_END && !(options & SEARCH_NOOF) + && !(matchpos.lnum == endpos.lnum + && matchpos.col == endpos.col)) + { +--- 869,875 ---- + /* With the SEARCH_END option move to the last character + * of the match. Don't do it for an empty match, end + * should be same as start then. */ +! if ((options & SEARCH_END) && !(options & SEARCH_NOOF) + && !(matchpos.lnum == endpos.lnum + && matchpos.col == endpos.col)) + { +*** ../vim-7.3.876/src/testdir/test14.in 2013-03-19 15:27:43.000000000 +0100 +--- src/testdir/test14.in 2013-04-03 20:59:14.000000000 +0200 +*************** +*** 44,49 **** +--- 44,52 ---- + :call append(line('$'), line('.') - startline) + :call search('^$', 'bc') + :call append(line('$'), line('.') - startline) ++ /two ++ :call search('.', 'c') ++ :call append(line('$'), getline('.')[col('.') - 1:]) + :/^search()/,$w >>test.out + :qa! + ENDTEST +*************** +*** 79,82 **** +--- 82,86 ---- + foobar + + ++ one two + search() +*** ../vim-7.3.876/src/testdir/test14.ok 2013-03-19 15:27:43.000000000 +0100 +--- src/testdir/test14.ok 2013-04-03 20:59:14.000000000 +0200 +*************** +*** 19,21 **** +--- 19,22 ---- + 0 + 1 + 1 ++ two +*** ../vim-7.3.876/src/version.c 2013-04-03 21:11:33.000000000 +0200 +--- src/version.c 2013-04-03 21:12:50.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 877, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +113. You are asked about a bus schedule, you wonder if it is 16 or 32 bits. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 02330313a883beb6c9144ce8fed829d99a8f0d99 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:32 +0200 Subject: [PATCH 0764/3340] - patchlevel 878 --- 7.3.878 | 78 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) create mode 100644 7.3.878 diff --git a/7.3.878 b/7.3.878 new file mode 100644 index 00000000..1669ec40 --- /dev/null +++ b/7.3.878 @@ -0,0 +1,78 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.878 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.878 +Problem: 'fileignorecase' is missing in options window and quickref. +Solution: Add the option. +Files: runtime/optwin.vim, runtime/doc/quickref.txt + + +*** ../vim-7.3.877/runtime/optwin.vim 2010-08-15 21:57:20.000000000 +0200 +--- runtime/optwin.vim 2013-04-05 15:35:22.000000000 +0200 +*************** +*** 1042,1047 **** +--- 1035,1044 ---- + call append("$", "wildignore\tlist of patterns to ignore files for file name completion") + call OptionG("wig", &wig) + endif ++ call append("$", "fileignorecase\tignore case when using file names") ++ call BinOptionG("fic", &fic) ++ call append("$", "wildignorecase\tignore case when completing file names") ++ call BinOptionG("wic", &wic) + if has("wildmenu") + call append("$", "wildmenu\tcommand-line completion shows a list of matches") + call BinOptionG("wmnu", &wmnu) +*************** +*** 1340,1342 **** +--- 1339,1343 ---- + let &sc = s:old_sc + let &cpo = s:cpo_save + unlet s:old_title s:old_icon s:old_ru s:old_sc s:cpo_save s:idx s:lnum ++ ++ " vim: ts=8 sw=2 sts=2 +*** ../vim-7.3.877/runtime/doc/quickref.txt 2010-08-15 21:57:17.000000000 +0200 +--- runtime/doc/quickref.txt 2013-04-05 15:36:35.000000000 +0200 +*************** +*** 690,695 **** +--- 691,697 ---- + 'fileencodings' 'fencs' automatically detected character encodings + 'fileformat' 'ff' file format used for file I/O + 'fileformats' 'ffs' automatically detected values for 'fileformat' ++ 'fileignorecase' 'fic' ignore case when using file names + 'filetype' 'ft' type of file, used for autocommands + 'fillchars' 'fcs' characters to use for displaying special items + 'fkmap' 'fk' Farsi keyboard mapping +*************** +*** 934,939 **** +--- 937,943 ---- + 'wildchar' 'wc' command-line character for wildcard expansion + 'wildcharm' 'wcm' like 'wildchar' but also works when mapped + 'wildignore' 'wig' files matching these patterns are not completed ++ 'wildignorecase' 'wic' ignore case when completing file names + 'wildmenu' 'wmnu' use menu for command line completion + 'wildmode' 'wim' mode for 'wildchar' command-line expansion + 'wildoptions' 'wop' specifies how command line completion is done +*** ../vim-7.3.877/src/version.c 2013-04-03 21:14:25.000000000 +0200 +--- src/version.c 2013-04-05 15:37:09.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 878, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +121. You ask for e-mail adresses instead of telephone numbers. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f23d95e4707db295016e3929098f68c46194e517 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:32 +0200 Subject: [PATCH 0765/3340] - patchlevel 879 --- 7.3.879 | 97 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100644 7.3.879 diff --git a/7.3.879 b/7.3.879 new file mode 100644 index 00000000..bb642dd8 --- /dev/null +++ b/7.3.879 @@ -0,0 +1,97 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.879 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.879 +Problem: When using an ex command in operator pending mode, using Esc to + abort the command still executes the operator. (David Bürgin) +Solution: Clear the operator when the ex command fails. (Christian Brabandt) +Files: src/normal.c + + +*** ../vim-7.3.878/src/normal.c 2013-03-16 14:20:45.000000000 +0100 +--- src/normal.c 2013-04-05 16:54:13.000000000 +0200 +*************** +*** 5418,5423 **** +--- 5418,5424 ---- + cmdarg_T *cap; + { + int old_p_im; ++ int cmd_result; + + #ifdef FEAT_VISUAL + if (VIsual_active) +*************** +*** 5449,5455 **** + old_p_im = p_im; + + /* get a command line and execute it */ +! do_cmdline(NULL, getexline, NULL, + cap->oap->op_type != OP_NOP ? DOCMD_KEEPLINE : 0); + + /* If 'insertmode' changed, enter or exit Insert mode */ +--- 5450,5456 ---- + old_p_im = p_im; + + /* get a command line and execute it */ +! cmd_result = do_cmdline(NULL, getexline, NULL, + cap->oap->op_type != OP_NOP ? DOCMD_KEEPLINE : 0); + + /* If 'insertmode' changed, enter or exit Insert mode */ +*************** +*** 5461,5472 **** + restart_edit = 0; + } + +! /* The start of the operator may have become invalid by the Ex +! * command. */ +! if (cap->oap->op_type != OP_NOP + && (cap->oap->start.lnum > curbuf->b_ml.ml_line_count + || cap->oap->start.col > +! (colnr_T)STRLEN(ml_get(cap->oap->start.lnum)))) + clearopbeep(cap->oap); + } + } +--- 5462,5478 ---- + restart_edit = 0; + } + +! if (cmd_result == FAIL) +! /* The Ex command failed, do not execute the operator. */ +! clearop(cap->oap); +! else if (cap->oap->op_type != OP_NOP + && (cap->oap->start.lnum > curbuf->b_ml.ml_line_count + || cap->oap->start.col > +! (colnr_T)STRLEN(ml_get(cap->oap->start.lnum)) +! || did_emsg +! )) +! /* The start of the operator has become invalid by the Ex command. +! */ + clearopbeep(cap->oap); + } + } +*** ../vim-7.3.878/src/version.c 2013-04-05 15:39:41.000000000 +0200 +--- src/version.c 2013-04-05 16:56:43.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 879, + /**/ + +-- +~ +~ +~ +".signature" 4 lines, 50 characters written + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bd0f9e2f6fc17b207147c17f12c17afe4d25fd3d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:33 +0200 Subject: [PATCH 0766/3340] - patchlevel 880 --- 7.3.880 | 287 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 287 insertions(+) create mode 100644 7.3.880 diff --git a/7.3.880 b/7.3.880 new file mode 100644 index 00000000..14a93846 --- /dev/null +++ b/7.3.880 @@ -0,0 +1,287 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.880 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.880 +Problem: When writing viminfo, old history lines may replace lines written + more recently by another Vim instance. +Solution: Mark history entries that were read from viminfo and overwrite + them when merging with the current viminfo. +Files: src/ex_getln.c + + +*** ../vim-7.3.879/src/ex_getln.c 2013-03-19 16:46:59.000000000 +0100 +--- src/ex_getln.c 2013-04-05 18:56:08.000000000 +0200 +*************** +*** 56,61 **** +--- 56,62 ---- + typedef struct hist_entry + { + int hisnum; /* identifying number */ ++ int viminfo; /* when TRUE hisstr comes from viminfo */ + char_u *hisstr; /* actual entry, separator char after the NUL */ + } histentry_T; + +*************** +*** 113,118 **** +--- 114,120 ---- + static int ExpandRTDir __ARGS((char_u *pat, int *num_file, char_u ***file, char *dirname[])); + # ifdef FEAT_CMDHIST + static char_u *get_history_arg __ARGS((expand_T *xp, int idx)); ++ static void clear_hist_entry __ARGS((histentry_T *hisptr)); + # endif + # if defined(FEAT_USR_CMDS) && defined(FEAT_EVAL) + static int ExpandUserDefined __ARGS((expand_T *xp, regmatch_T *regmatch, int *num_file, char_u ***file)); +*************** +*** 5343,5352 **** + if (hisidx[type] < 0) /* there are no entries yet */ + { + for (i = 0; i < newlen; ++i) +! { +! temp[i].hisnum = 0; +! temp[i].hisstr = NULL; +! } + } + else if (newlen > hislen) /* array becomes bigger */ + { +--- 5345,5351 ---- + if (hisidx[type] < 0) /* there are no entries yet */ + { + for (i = 0; i < newlen; ++i) +! clear_hist_entry(&temp[i]); + } + else if (newlen > hislen) /* array becomes bigger */ + { +*************** +*** 5354,5363 **** + temp[i] = history[type][i]; + j = i; + for ( ; i <= newlen - (hislen - hisidx[type]); ++i) +! { +! temp[i].hisnum = 0; +! temp[i].hisstr = NULL; +! } + for ( ; j < hislen; ++i, ++j) + temp[i] = history[type][j]; + } +--- 5353,5359 ---- + temp[i] = history[type][i]; + j = i; + for ( ; i <= newlen - (hislen - hisidx[type]); ++i) +! clear_hist_entry(&temp[i]); + for ( ; j < hislen; ++i, ++j) + temp[i] = history[type][j]; + } +*************** +*** 5385,5390 **** +--- 5381,5395 ---- + } + } + ++ static void ++ clear_hist_entry(hisptr) ++ histentry_T *hisptr; ++ { ++ hisptr->hisnum = 0; ++ hisptr->viminfo = FALSE; ++ hisptr->hisstr = NULL; ++ } ++ + /* + * Check if command line 'str' is already in history. + * If 'move_to_front' is TRUE, matching entry is moved to end of history. +*************** +*** 5433,5440 **** + history[type][last_i] = history[type][i]; + last_i = i; + } +- history[type][i].hisstr = str; + history[type][i].hisnum = ++hisnum[type]; + return TRUE; + } + return FALSE; +--- 5438,5446 ---- + history[type][last_i] = history[type][i]; + last_i = i; + } + history[type][i].hisnum = ++hisnum[type]; ++ history[type][i].viminfo = FALSE; ++ history[type][i].hisstr = str; + return TRUE; + } + return FALSE; +*************** +*** 5498,5505 **** + /* Current line is from the same mapping, remove it */ + hisptr = &history[HIST_SEARCH][hisidx[HIST_SEARCH]]; + vim_free(hisptr->hisstr); +! hisptr->hisstr = NULL; +! hisptr->hisnum = 0; + --hisnum[histype]; + if (--hisidx[HIST_SEARCH] < 0) + hisidx[HIST_SEARCH] = hislen - 1; +--- 5504,5510 ---- + /* Current line is from the same mapping, remove it */ + hisptr = &history[HIST_SEARCH][hisidx[HIST_SEARCH]]; + vim_free(hisptr->hisstr); +! clear_hist_entry(hisptr); + --hisnum[histype]; + if (--hisidx[HIST_SEARCH] < 0) + hisidx[HIST_SEARCH] = hislen - 1; +*************** +*** 5520,5525 **** +--- 5525,5531 ---- + hisptr->hisstr[len + 1] = sep; + + hisptr->hisnum = ++hisnum[histype]; ++ hisptr->viminfo = FALSE; + if (histype == HIST_SEARCH && in_map) + last_maptick = maptick; + } +*************** +*** 5709,5716 **** + for (i = hislen; i--;) + { + vim_free(hisptr->hisstr); +! hisptr->hisnum = 0; +! hisptr++->hisstr = NULL; + } + hisidx[histype] = -1; /* mark history as cleared */ + hisnum[histype] = 0; /* reset identifier counter */ +--- 5715,5721 ---- + for (i = hislen; i--;) + { + vim_free(hisptr->hisstr); +! clear_hist_entry(hisptr); + } + hisidx[histype] = -1; /* mark history as cleared */ + hisnum[histype] = 0; /* reset identifier counter */ +*************** +*** 5755,5770 **** + { + found = TRUE; + vim_free(hisptr->hisstr); +! hisptr->hisstr = NULL; +! hisptr->hisnum = 0; + } + else + { + if (i != last) + { + history[histype][last] = *hisptr; +! hisptr->hisstr = NULL; +! hisptr->hisnum = 0; + } + if (--last < 0) + last += hislen; +--- 5760,5773 ---- + { + found = TRUE; + vim_free(hisptr->hisstr); +! clear_hist_entry(hisptr); + } + else + { + if (i != last) + { + history[histype][last] = *hisptr; +! clear_hist_entry(hisptr); + } + if (--last < 0) + last += hislen; +*************** +*** 5808,5815 **** + history[histype][i] = history[histype][j]; + i = j; + } +! history[histype][i].hisstr = NULL; +! history[histype][i].hisnum = 0; + if (--i < 0) + i += hislen; + hisidx[histype] = i; +--- 5811,5817 ---- + history[histype][i] = history[histype][j]; + i = j; + } +! clear_hist_entry(&history[histype][i]); + if (--i < 0) + i += hislen; + hisidx[histype] = i; +*************** +*** 6043,6054 **** + + for (type = 0; type < HIST_COUNT; ++type) + { +! /* +! * Count the number of empty spaces in the history list. If there are +! * more spaces available than we request, then fill them up. +! */ + for (i = 0, num = 0; i < hislen; i++) +! if (history[type][i].hisstr == NULL) + num++; + len = asklen; + if (num > len) +--- 6045,6055 ---- + + for (type = 0; type < HIST_COUNT; ++type) + { +! /* Count the number of empty spaces in the history list. Entries read +! * from viminfo previously are also considered empty. If there are +! * more spaces available than we request, then fill them up. */ + for (i = 0, num = 0; i < hislen; i++) +! if (history[type][i].hisstr == NULL || history[type][i].viminfo) + num++; + len = asklen; + if (num > len) +*************** +*** 6141,6147 **** + hisidx[type] = hislen - 1; + do + { +! if (history[type][idx].hisstr != NULL) + break; + if (++idx == hislen) + idx = 0; +--- 6142,6149 ---- + hisidx[type] = hislen - 1; + do + { +! if (history[type][idx].hisstr != NULL +! || history[type][idx].viminfo) + break; + if (++idx == hislen) + idx = 0; +*************** +*** 6153,6158 **** +--- 6155,6161 ---- + { + vim_free(history[type][idx].hisstr); + history[type][idx].hisstr = viminfo_history[type][i]; ++ history[type][idx].viminfo = TRUE; + if (--idx < 0) + idx = hislen - 1; + } +*** ../vim-7.3.879/src/version.c 2013-04-05 17:43:10.000000000 +0200 +--- src/version.c 2013-04-05 18:54:11.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 880, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +122. You ask if the Netaholics Anonymous t-shirt you ordered can be + sent to you via e-mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7be4c3d652263d03c1c07198d3a90c75e67cb8c5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:34 +0200 Subject: [PATCH 0767/3340] - patchlevel 881 --- 7.3.881 | 108 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 108 insertions(+) create mode 100644 7.3.881 diff --git a/7.3.881 b/7.3.881 new file mode 100644 index 00000000..d0ca99b0 --- /dev/null +++ b/7.3.881 @@ -0,0 +1,108 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.881 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.881 +Problem: Python list does not work correctly. +Solution: Fix it and add a test. (Yukihiro Nakadaira) +Files: src/testdir/test86.in, src/testdir/test86.ok, src/if_py_both.h + + +*** ../vim-7.3.880/src/testdir/test86.in 2013-02-20 16:54:24.000000000 +0100 +--- src/testdir/test86.in 2013-04-05 19:18:48.000000000 +0200 +*************** +*** 321,326 **** +--- 321,351 ---- + :py trace_main() + :py sys.settrace(None) + :$put =string(l) ++ :" ++ :" Slice ++ :py ll = vim.bindeval('[0, 1, 2, 3, 4, 5]') ++ :py l = ll[:4] ++ :$put =string(pyeval('l')) ++ :py l = ll[2:] ++ :$put =string(pyeval('l')) ++ :py l = ll[:-4] ++ :$put =string(pyeval('l')) ++ :py l = ll[-2:] ++ :$put =string(pyeval('l')) ++ :py l = ll[2:4] ++ :$put =string(pyeval('l')) ++ :py l = ll[4:2] ++ :$put =string(pyeval('l')) ++ :py l = ll[-4:-2] ++ :$put =string(pyeval('l')) ++ :py l = ll[-2:-4] ++ :$put =string(pyeval('l')) ++ :py l = ll[:] ++ :$put =string(pyeval('l')) ++ :py l = ll[0:6] ++ :$put =string(pyeval('l')) ++ :py l = ll[-10:10] ++ :$put =string(pyeval('l')) + :endfun + :" + :call Test() +*** ../vim-7.3.880/src/testdir/test86.ok 2013-02-20 16:54:24.000000000 +0100 +--- src/testdir/test86.ok 2013-04-05 19:18:48.000000000 +0200 +*************** +*** 65,67 **** +--- 65,78 ---- + vim: Vim(let):E859: + [1] + [1, 10, 11, 10, 11, 10, 11, 10, 11, 10, 11, 10, 1] ++ [0, 1, 2, 3] ++ [2, 3, 4, 5] ++ [0, 1] ++ [4, 5] ++ [2, 3] ++ [] ++ [2, 3] ++ [] ++ [0, 1, 2, 3, 4, 5] ++ [0, 1, 2, 3, 4, 5] ++ [0, 1, 2, 3, 4, 5] +*** ../vim-7.3.880/src/if_py_both.h 2013-02-14 22:11:31.000000000 +0100 +--- src/if_py_both.h 2013-04-05 19:27:46.000000000 +0200 +*************** +*** 1139,1145 **** + + for (i = 0; i < n; ++i) + { +! PyObject *item = ListItem(self, i); + if (item == NULL) + { + Py_DECREF(list); +--- 1139,1145 ---- + + for (i = 0; i < n; ++i) + { +! PyObject *item = ListItem(self, first + i); + if (item == NULL) + { + Py_DECREF(list); +*** ../vim-7.3.880/src/version.c 2013-04-05 18:58:42.000000000 +0200 +--- src/version.c 2013-04-05 19:31:59.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 881, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +123. You ask the car dealer to install an extra cigarette lighter + on your new car to power your notebook. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fa0ab21248b070b66cac0ad855888c525b3bfbb3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:34 +0200 Subject: [PATCH 0768/3340] - patchlevel 882 --- 7.3.882 | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.882 diff --git a/7.3.882 b/7.3.882 new file mode 100644 index 00000000..bfc348b4 --- /dev/null +++ b/7.3.882 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.882 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.882 +Problem: CursorHold may trigger after receiving the termresponse. +Solution: Set the did_cursorhold flag. (Hayaki Saito) +Files: src/term.c + + +*** ../vim-7.3.881/src/term.c 2013-03-16 14:33:32.000000000 +0100 +--- src/term.c 2013-04-05 19:49:58.000000000 +0200 +*************** +*** 4137,4142 **** +--- 4137,4145 ---- + char *p = NULL; + + u7_status = U7_GOT; ++ # ifdef FEAT_AUTOCMD ++ did_cursorhold = TRUE; ++ # endif + if (extra == 2) + p = "single"; + else if (extra == 3) +*************** +*** 4153,4158 **** +--- 4156,4164 ---- + if (*T_CRV != NUL && i > 2 + (tp[0] != CSI) && tp[i] == 'c') + { + crv_status = CRV_GOT; ++ # ifdef FEAT_AUTOCMD ++ did_cursorhold = TRUE; ++ # endif + + /* If this code starts with CSI, you can bet that the + * terminal uses 8-bit codes. */ +*** ../vim-7.3.881/src/version.c 2013-04-05 19:32:30.000000000 +0200 +--- src/version.c 2013-04-05 19:46:21.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 882, + /**/ + +-- +Would you care for a drink? I mean, if it were, like, +disabled and you had to look after it? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 90f0bb5dcf30d4a7dd44fe027f259e223e3855b8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:35 +0200 Subject: [PATCH 0769/3340] - patchlevel 883 --- 7.3.883 | 65 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 7.3.883 diff --git a/7.3.883 b/7.3.883 new file mode 100644 index 00000000..984e5d4c --- /dev/null +++ b/7.3.883 @@ -0,0 +1,65 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.883 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.883 (after 7.3.880) +Problem: Can't build with some combination of features. +Solution: Adjust #ifdefs. +Files: src/ex_getln.c + + +*** ../vim-7.3.882/src/ex_getln.c 2013-04-05 18:58:41.000000000 +0200 +--- src/ex_getln.c 2013-04-06 13:24:22.000000000 +0200 +*************** +*** 114,126 **** + static int ExpandRTDir __ARGS((char_u *pat, int *num_file, char_u ***file, char *dirname[])); + # ifdef FEAT_CMDHIST + static char_u *get_history_arg __ARGS((expand_T *xp, int idx)); +- static void clear_hist_entry __ARGS((histentry_T *hisptr)); + # endif + # if defined(FEAT_USR_CMDS) && defined(FEAT_EVAL) + static int ExpandUserDefined __ARGS((expand_T *xp, regmatch_T *regmatch, int *num_file, char_u ***file)); + static int ExpandUserList __ARGS((expand_T *xp, int *num_file, char_u ***file)); + # endif + #endif + + #ifdef FEAT_CMDWIN + static int ex_window __ARGS((void)); +--- 114,128 ---- + static int ExpandRTDir __ARGS((char_u *pat, int *num_file, char_u ***file, char *dirname[])); + # ifdef FEAT_CMDHIST + static char_u *get_history_arg __ARGS((expand_T *xp, int idx)); + # endif + # if defined(FEAT_USR_CMDS) && defined(FEAT_EVAL) + static int ExpandUserDefined __ARGS((expand_T *xp, regmatch_T *regmatch, int *num_file, char_u ***file)); + static int ExpandUserList __ARGS((expand_T *xp, int *num_file, char_u ***file)); + # endif + #endif ++ #ifdef FEAT_CMDHIST ++ static void clear_hist_entry __ARGS((histentry_T *hisptr)); ++ #endif + + #ifdef FEAT_CMDWIN + static int ex_window __ARGS((void)); +*** ../vim-7.3.882/src/version.c 2013-04-05 19:50:12.000000000 +0200 +--- src/version.c 2013-04-06 14:28:41.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 883, + /**/ + +-- +Why is it called "Windows"? "Gates" would be more appropriate... + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a7d73c0395fc7d4fed846f5686a6c5e9c6b345a0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:36 +0200 Subject: [PATCH 0770/3340] - patchlevel 884 --- 7.3.884 | 73 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 7.3.884 diff --git a/7.3.884 b/7.3.884 new file mode 100644 index 00000000..31d2e7f3 --- /dev/null +++ b/7.3.884 @@ -0,0 +1,73 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.884 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.884 +Problem: Compiler warning for variable shadowing another. (John Little) +Solution: Rename the variable. (Christian Brabandt) +Files: src/term.c + + +*** ../vim-7.3.883/src/term.c 2013-04-05 19:50:12.000000000 +0200 +--- src/term.c 2013-04-06 13:27:59.000000000 +0200 +*************** +*** 4134,4151 **** + /* eat it when it has 2 arguments and ends in 'R' */ + if (j == 1 && tp[i] == 'R') + { +! char *p = NULL; + + u7_status = U7_GOT; + # ifdef FEAT_AUTOCMD + did_cursorhold = TRUE; + # endif + if (extra == 2) +! p = "single"; + else if (extra == 3) +! p = "double"; +! if (p != NULL) +! set_option_value((char_u *)"ambw", 0L, (char_u *)p, 0); + key_name[0] = (int)KS_EXTRA; + key_name[1] = (int)KE_IGNORE; + slen = i + 1; +--- 4134,4151 ---- + /* eat it when it has 2 arguments and ends in 'R' */ + if (j == 1 && tp[i] == 'R') + { +! char *aw = NULL; + + u7_status = U7_GOT; + # ifdef FEAT_AUTOCMD + did_cursorhold = TRUE; + # endif + if (extra == 2) +! aw = "single"; + else if (extra == 3) +! aw = "double"; +! if (aw != NULL) +! set_option_value((char_u *)"ambw", 0L, (char_u *)aw, 0); + key_name[0] = (int)KS_EXTRA; + key_name[1] = (int)KE_IGNORE; + slen = i + 1; +*** ../vim-7.3.883/src/version.c 2013-04-06 14:28:56.000000000 +0200 +--- src/version.c 2013-04-06 14:30:05.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 884, + /**/ + +-- +Don't drink and drive. You might hit a bump and spill your beer. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b46193c5cdc90b13bed6c9e802eceb22df9b1f87 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:36 +0200 Subject: [PATCH 0771/3340] - patchlevel 885 --- 7.3.885 | 88 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 88 insertions(+) create mode 100644 7.3.885 diff --git a/7.3.885 b/7.3.885 new file mode 100644 index 00000000..f7fdbd52 --- /dev/null +++ b/7.3.885 @@ -0,0 +1,88 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.885 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.885 +Problem: Double free for list and dict in Lua. (Shougo Matsu) +Solution: Do not unref list and dict. (Yasuhiro Matsumoto) +Files: src/if_lua.c + + +*** ../vim-7.3.884/src/if_lua.c 2013-02-14 22:19:47.000000000 +0100 +--- src/if_lua.c 2013-04-12 11:42:56.000000000 +0200 +*************** +*** 665,677 **** + luaV_type_tostring(list, LUAVIM_LIST) + + static int +- luaV_list_gc (lua_State *L) +- { +- list_unref(luaV_unbox(L, luaV_List, 1)); +- return 0; +- } +- +- static int + luaV_list_len (lua_State *L) + { + list_T *l = luaV_unbox(L, luaV_List, 1); +--- 665,670 ---- +*************** +*** 801,807 **** + + static const luaL_Reg luaV_List_mt[] = { + {"__tostring", luaV_list_tostring}, +- {"__gc", luaV_list_gc}, + {"__len", luaV_list_len}, + {"__call", luaV_list_call}, + {"__index", luaV_list_index}, +--- 794,799 ---- +*************** +*** 830,842 **** + luaV_type_tostring(dict, LUAVIM_DICT) + + static int +- luaV_dict_gc (lua_State *L) +- { +- dict_unref(luaV_unbox(L, luaV_Dict, 1)); +- return 0; +- } +- +- static int + luaV_dict_len (lua_State *L) + { + dict_T *d = luaV_unbox(L, luaV_Dict, 1); +--- 822,827 ---- +*************** +*** 929,935 **** + + static const luaL_Reg luaV_Dict_mt[] = { + {"__tostring", luaV_dict_tostring}, +- {"__gc", luaV_dict_gc}, + {"__len", luaV_dict_len}, + {"__call", luaV_dict_call}, + {"__index", luaV_dict_index}, +--- 914,919 ---- +*** ../vim-7.3.884/src/version.c 2013-04-06 14:30:35.000000000 +0200 +--- src/version.c 2013-04-12 11:44:45.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 885, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +148. You find it easier to dial-up the National Weather Service + Weather/your_town/now.html than to simply look out the window. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9b9b87f6c555cfde8656741a59c58eb75c9c2def Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:37 +0200 Subject: [PATCH 0772/3340] - patchlevel 886 --- 7.3.886 | 93 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 93 insertions(+) create mode 100644 7.3.886 diff --git a/7.3.886 b/7.3.886 new file mode 100644 index 00000000..a823507e --- /dev/null +++ b/7.3.886 @@ -0,0 +1,93 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.886 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.886 +Problem: Can't build with multi-byte on Solaris 10. +Solution: Add #ifdef X_HAVE_UTF8_STRING. (Laurent Blume) +Files: src/ui.c + + +*** ../vim-7.3.885/src/ui.c 2013-03-13 17:50:20.000000000 +0100 +--- src/ui.c 2013-04-12 12:24:10.000000000 +0200 +*************** +*** 1458,1464 **** + + int + clip_gen_owner_exists(cbd) +! VimClipboard *cbd; + { + #ifdef FEAT_XCLIPBOARD + # ifdef FEAT_GUI_GTK +--- 1458,1464 ---- + + int + clip_gen_owner_exists(cbd) +! VimClipboard *cbd UNUSED; + { + #ifdef FEAT_XCLIPBOARD + # ifdef FEAT_GUI_GTK +*************** +*** 2134,2140 **** + text_prop.encoding = *type; + text_prop.format = *format; + text_prop.nitems = len; +! #ifdef FEAT_MBYTE + if (*type == utf8_atom) + status = Xutf8TextPropertyToTextList(X_DISPLAY, &text_prop, + &text_list, &n_text); +--- 2134,2140 ---- + text_prop.encoding = *type; + text_prop.format = *format; + text_prop.nitems = len; +! #if defined(FEAT_MBYTE) && defined(X_HAVE_UTF8_STRING) + if (*type == utf8_atom) + status = Xutf8TextPropertyToTextList(X_DISPLAY, &text_prop, + &text_list, &n_text); +*************** +*** 2196,2203 **** + default: type = XA_STRING; + } + #ifdef FEAT_MBYTE +! if (type == utf8_atom && !enc_utf8) +! /* Only request utf-8 when 'encoding' is utf8. */ + continue; + #endif + success = MAYBE; +--- 2196,2208 ---- + default: type = XA_STRING; + } + #ifdef FEAT_MBYTE +! if (type == utf8_atom +! # if defined(X_HAVE_UTF8_STRING) +! && !enc_utf8 +! # endif +! ) +! /* Only request utf-8 when 'encoding' is utf8 and +! * Xutf8TextPropertyToTextList is available. */ + continue; + #endif + success = MAYBE; +*** ../vim-7.3.885/src/version.c 2013-04-12 12:18:43.000000000 +0200 +--- src/version.c 2013-04-12 12:25:44.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 886, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +149. You find your computer sexier than your girlfriend + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1e450b9070776e73f63af7ba46e17ebcfe4a040c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:37 +0200 Subject: [PATCH 0773/3340] - patchlevel 887 --- 7.3.887 | 308 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 308 insertions(+) create mode 100644 7.3.887 diff --git a/7.3.887 b/7.3.887 new file mode 100644 index 00000000..228845f6 --- /dev/null +++ b/7.3.887 @@ -0,0 +1,308 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.887 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.887 +Problem: No tests for Visual mode operators, what 7.3.879 fixes. +Solution: Add a new test file. (David Bürgin) +Files: src/testdir/test94.in, src/testdir/test94.ok, + src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak, + src/testdir/Make_ming.mak, src/testdir/Make_os2.mak, + src/testdir/Make_vms.mms, src/testdir/Makefile + + +*** ../vim-7.3.886/src/testdir/test94.in 2013-04-12 13:44:19.000000000 +0200 +--- src/testdir/test94.in 2013-04-12 13:37:12.000000000 +0200 +*************** +*** 0 **** +--- 1,98 ---- ++ Test for Visual mode and operators ++ ++ Tests for the two kinds of operations: Those executed with Visual mode ++ followed by an operator and those executed via Operator-pending mode. Also ++ part of the test are mappings, counts, and repetition with the . command. ++ ++ Test cases: ++ - Visual modes (v V CTRL-V) followed by an operator; count; repeating ++ - Visual mode maps; count; repeating ++ - Simple ++ - With an Ex command (custom text object) ++ - Operator-pending mode maps ++ - Simple ++ - With Ex command moving the cursor ++ - With Ex command and Visual selection (custom text object) ++ - Patch 7.3.879: Properly abort Ex command in Operator-pending mode ++ ++ STARTTEST ++ :so small.vim ++ :set nocp ++ : ++ :" User functions ++ :function MoveToCap() ++ : call search('\u', 'W') ++ :endfunction ++ :function SelectInCaps() ++ : let [line1, col1] = searchpos('\u', 'bcnW') ++ : let [line2, col2] = searchpos('.\u', 'nW') ++ : call setpos("'<", [0, line1, col1, 0]) ++ : call setpos("'>", [0, line2, col2, 0]) ++ : normal! gv ++ :endfunction ++ :function MoveToEndCount(count) ++ : normal! v:count . e ++ :endfunction ++ : ++ :" Visual modes followed by operator ++ /^apple ++ lvld.l3vd.: ++ /^line 1 ++ Vcnewlinej.j2Vd.: ++ /^xxxx ++ jlc l.l2c----l.: ++ : ++ :" Visual mode maps (movement and text object) ++ :vnoremap W /\u/s-1 ++ :vnoremap iW :call SelectInCaps() ++ /^Kiwi ++ vWcNol.fD2vd.: ++ /^Jambu ++ llviWc-l.l2vdl.: ++ : ++ :" Operator-pending mode maps (movement and text object) ++ :onoremap W /\u/ ++ :onoremap W :call MoveToCap() ++ :onoremap iW :call SelectInCaps() ++ /^Pineapple ++ cW-l.l2.l.: ++ /^Juniper ++ g?\WfD.: ++ /^Lemon ++ yiWPlciWNew: ++ : ++ :" Patch 7.3.879: Properly abort Operator-pending mode for "dv:" etc. ++ /^zzzz ++ dV: dv: :set noma | let v:errmsg = '' ++ d: :set ma | put = v:errmsg =~# '^E21' ? 'ok' : 'failed' ++ dv:dV::set noma | let v:errmsg = '' ++ d::set ma | put = v:errmsg =~# '^E21' ? 'failed' : 'ok' ++ :/^start:/+2,$w! test.out ++ :q! ++ ENDTEST ++ ++ start: ++ ++ apple banana cherry ++ ++ line 1 line 1 ++ line 2 line 2 ++ line 3 line 3 ++ line 4 line 4 ++ line 5 line 5 ++ line 6 line 6 ++ ++ xxxxxxxxxxxxx ++ xxxxxxxxxxxxx ++ xxxxxxxxxxxxx ++ xxxxxxxxxxxxx ++ ++ KiwiRaspberryDateWatermelonPeach ++ JambuRambutanBananaTangerineMango ++ ++ PineappleQuinceLoganberryOrangeGrapefruitKiwiZ ++ JuniperDurianZ ++ LemonNectarineZ ++ ++ zzzz ++ zzzz +*** ../vim-7.3.886/src/testdir/test94.ok 2013-04-12 13:44:19.000000000 +0200 +--- src/testdir/test94.ok 2013-04-12 13:37:12.000000000 +0200 +*************** +*** 0 **** +--- 1,20 ---- ++ a y ++ ++ newline ++ newline ++ ++ --------x ++ --------x ++ xxxx--------x ++ xxxx--------x ++ ++ NoNoberryach ++ --ago ++ ++ ----Z ++ WhavcreQhevnaZ ++ LemonNewNectarineZ ++ ++ zzz ++ ok ++ ok +*** ../vim-7.3.886/src/testdir/Make_amiga.mak 2013-02-26 17:21:15.000000000 +0100 +--- src/testdir/Make_amiga.mak 2013-04-12 13:39:47.000000000 +0200 +*************** +*** 32,38 **** + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out test90.out test91.out test92.out test93.out + + .SUFFIXES: .in .out + +--- 32,39 ---- + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out test90.out test91.out test92.out test93.out \ +! test94.out + + .SUFFIXES: .in .out + +*************** +*** 142,144 **** +--- 143,146 ---- + test91.out: test91.in + test92.out: test92.in + test93.out: test93.in ++ test94.out: test94.in +*** ../vim-7.3.886/src/testdir/Make_dos.mak 2013-02-26 17:21:15.000000000 +0100 +--- src/testdir/Make_dos.mak 2013-04-12 13:39:56.000000000 +0200 +*************** +*** 31,37 **** + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out test91.out test92.out test93.out + + SCRIPTS32 = test50.out test70.out + +--- 31,38 ---- + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out test91.out test92.out test93.out \ +! test94.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.886/src/testdir/Make_ming.mak 2013-02-26 17:21:15.000000000 +0100 +--- src/testdir/Make_ming.mak 2013-04-12 13:40:06.000000000 +0200 +*************** +*** 51,57 **** + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out test91.out test92.out test93.out + + SCRIPTS32 = test50.out test70.out + +--- 51,58 ---- + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out test91.out test92.out test93.out \ +! test94.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.886/src/testdir/Make_os2.mak 2013-02-26 17:21:15.000000000 +0100 +--- src/testdir/Make_os2.mak 2013-04-12 13:40:13.000000000 +0200 +*************** +*** 32,38 **** + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out test90.out test91.out test92.out test93.out + + .SUFFIXES: .in .out + +--- 32,39 ---- + test71.out test72.out test73.out test74.out test75.out \ + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ +! test89.out test90.out test91.out test92.out test93.out \ +! test94.out + + .SUFFIXES: .in .out + +*** ../vim-7.3.886/src/testdir/Make_vms.mms 2013-02-26 17:21:15.000000000 +0100 +--- src/testdir/Make_vms.mms 2013-04-12 13:40:24.000000000 +0200 +*************** +*** 4,10 **** + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2013-02-21 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +--- 4,10 ---- + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2013 Apr 12 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +*************** +*** 77,83 **** + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ + test82.out test83.out test84.out test88.out test89.out \ +! test90.out test91.out test92.out test93.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +--- 77,83 ---- + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ + test82.out test83.out test84.out test88.out test89.out \ +! test90.out test91.out test92.out test93.out test94.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +*** ../vim-7.3.886/src/testdir/Makefile 2013-02-26 17:21:15.000000000 +0100 +--- src/testdir/Makefile 2013-04-12 13:40:32.000000000 +0200 +*************** +*** 28,34 **** + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out test91.out test92.out test93.out + + SCRIPTS_GUI = test16.out + +--- 28,35 ---- + test74.out test75.out test76.out test77.out test78.out \ + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ +! test89.out test90.out test91.out test92.out test93.out \ +! test94.out + + SCRIPTS_GUI = test16.out + +*** ../vim-7.3.886/src/version.c 2013-04-12 12:27:24.000000000 +0200 +--- src/version.c 2013-04-12 13:43:34.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 887, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +153. You find yourself staring at your "inbox" waiting for new e-mail + to arrive. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bc1559fb71ea49bc83c95a4c3ff99a929ae218b0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:38 +0200 Subject: [PATCH 0774/3340] - patchlevel 888 --- 7.3.888 | 150 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 150 insertions(+) create mode 100644 7.3.888 diff --git a/7.3.888 b/7.3.888 new file mode 100644 index 00000000..6707f8a0 --- /dev/null +++ b/7.3.888 @@ -0,0 +1,150 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.888 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.888 +Problem: Filename completion with 'fileignorecase' does not work for + multi-byte characters. +Solution: Make 'fileignorecase' work properly. (Hirohito Higashi) +Files: src/misc2.c + + +*** ../vim-7.3.887/src/misc2.c 2013-03-19 18:31:45.000000000 +0100 +--- src/misc2.c 2013-04-12 14:15:03.000000000 +0200 +*************** +*** 6099,6150 **** + int maxlen; + { + int i; + const char *s = NULL; + +! for (i = 0; maxlen < 0 || i < maxlen; ++i) + { + /* End of "p": check if "q" also ends or just has a slash. */ +! if (p[i] == NUL) + { +! if (q[i] == NUL) /* full match */ + return 0; + s = q; + break; + } + + /* End of "q": check if "p" just has a slash. */ +! if (q[i] == NUL) + { + s = p; + break; + } + +! if ((p_fic ? TOUPPER_LOC(p[i]) != TOUPPER_LOC(q[i]) : p[i] != q[i]) + #ifdef BACKSLASH_IN_FILENAME + /* consider '/' and '\\' to be equal */ +! && !((p[i] == '/' && q[i] == '\\') +! || (p[i] == '\\' && q[i] == '/')) + #endif + ) + { +! if (vim_ispathsep(p[i])) + return -1; +! if (vim_ispathsep(q[i])) + return 1; +! return ((char_u *)p)[i] - ((char_u *)q)[i]; /* no match */ + } + } + if (s == NULL) /* "i" ran into "maxlen" */ + return 0; + + /* ignore a trailing slash, but not "//" or ":/" */ +! if (s[i + 1] == NUL + && i > 0 + && !after_pathsep((char_u *)s, (char_u *)s + i) + #ifdef BACKSLASH_IN_FILENAME +! && (s[i] == '/' || s[i] == '\\') + #else +! && s[i] == '/' + #endif + ) + return 0; /* match with trailing slash */ +--- 6099,6157 ---- + int maxlen; + { + int i; ++ int c1, c2; + const char *s = NULL; + +! for (i = 0; maxlen < 0 || i < maxlen; i += MB_PTR2LEN((char_u *)p + i)) + { ++ c1 = PTR2CHAR((char_u *)p + i); ++ c2 = PTR2CHAR((char_u *)q + i); ++ + /* End of "p": check if "q" also ends or just has a slash. */ +! if (c1 == NUL) + { +! if (c2 == NUL) /* full match */ + return 0; + s = q; + break; + } + + /* End of "q": check if "p" just has a slash. */ +! if (c2 == NUL) + { + s = p; + break; + } + +! if ((p_fic ? MB_TOUPPER(c1) != MB_TOUPPER(c2) : c1 != c2) + #ifdef BACKSLASH_IN_FILENAME + /* consider '/' and '\\' to be equal */ +! && !((c1 == '/' && c2 == '\\') +! || (c1 == '\\' && c2 == '/')) + #endif + ) + { +! if (vim_ispathsep(c1)) + return -1; +! if (vim_ispathsep(c2)) + return 1; +! return p_fic ? MB_TOUPPER(c1) - MB_TOUPPER(c2) +! : c1 - c2; /* no match */ + } + } + if (s == NULL) /* "i" ran into "maxlen" */ + return 0; + ++ c1 = PTR2CHAR((char_u *)s + i); ++ c2 = PTR2CHAR((char_u *)s + i + MB_PTR2LEN((char_u *)s + i)); + /* ignore a trailing slash, but not "//" or ":/" */ +! if (c2 == NUL + && i > 0 + && !after_pathsep((char_u *)s, (char_u *)s + i) + #ifdef BACKSLASH_IN_FILENAME +! && (c1 == '/' || c1 == '\\') + #else +! && c1 == '/' + #endif + ) + return 0; /* match with trailing slash */ +*** ../vim-7.3.887/src/version.c 2013-04-12 13:44:49.000000000 +0200 +--- src/version.c 2013-04-12 14:10:41.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 888, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +155. You forget to eat because you're too busy surfing the net. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ca6833753916270c2d09b3d5577aa32939661f9b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:39 +0200 Subject: [PATCH 0775/3340] - patchlevel 889 --- 7.3.889 | 71 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) create mode 100644 7.3.889 diff --git a/7.3.889 b/7.3.889 new file mode 100644 index 00000000..f63ce355 --- /dev/null +++ b/7.3.889 @@ -0,0 +1,71 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.889 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.889 +Problem: Can't build with Ruby 2.0 on a 64 bit system. +Solution: Define rb_fix2int and rb_num2int. (Kohei Suzuki) +Files: src/if_ruby.c + + +*** ../vim-7.3.888/src/if_ruby.c 2013-03-07 15:16:16.000000000 +0100 +--- src/if_ruby.c 2013-04-12 15:25:26.000000000 +0200 +*************** +*** 88,93 **** +--- 88,101 ---- + # define rb_int2big rb_int2big_stub + #endif + ++ #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 20 \ ++ && SIZEOF_INT < SIZEOF_LONG ++ /* Ruby 2.0 defines a number of static functions which use rb_fix2int and ++ * rb_num2int if SIZEOF_INT < SIZEOF_LONG (64bit) */ ++ # define rb_fix2int rb_fix2int_stub ++ # define rb_num2int rb_num2int_stub ++ #endif ++ + #include + #ifdef RUBY19_OR_LATER + # include +*************** +*** 352,357 **** +--- 360,376 ---- + { + return dll_rb_int2big(x); + } ++ #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 20 \ ++ && SIZEOF_INT < SIZEOF_LONG ++ long rb_fix2int_stub(VALUE x) ++ { ++ return dll_rb_fix2int(x); ++ } ++ long rb_num2int_stub(VALUE x) ++ { ++ return dll_rb_num2int(x); ++ } ++ #endif + #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 20 + VALUE + rb_float_new_in_heap(double d) +*** ../vim-7.3.888/src/version.c 2013-04-12 14:42:35.000000000 +0200 +--- src/version.c 2013-04-12 15:24:15.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 889, + /**/ + +-- +"Hit any key to continue" is very confusing when you have two keyboards. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 20f7953208b27e37689f1acbe27206d636bdbe52 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:39 +0200 Subject: [PATCH 0776/3340] - patchlevel 890 --- 7.3.890 | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 7.3.890 diff --git a/7.3.890 b/7.3.890 new file mode 100644 index 00000000..a7bcbca7 --- /dev/null +++ b/7.3.890 @@ -0,0 +1,60 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.890 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.890 +Problem: Test 79 fails on Windows. (Michael Soyka) +Solution: Add comment below line causing an error. +Files: src/testdir/test79.in + + +*** ../vim-7.3.889/src/testdir/test79.in 2013-03-19 17:42:10.000000000 +0100 +--- src/testdir/test79.in 2013-04-13 11:16:38.000000000 +0200 +*************** +*** 206,216 **** + STARTTEST + :set magic& + :set cpo& +! /^TEST/ + j:s/A./\=submatch(0)/ + j:s/B./\=submatch(0)/ + /^Q$ + :s/Q[^\n]Q/\=submatch(0)."foobar"/ + ENDTEST + + TEST_7: +--- 206,217 ---- + STARTTEST + :set magic& + :set cpo& +! /^TEST_7/ + j:s/A./\=submatch(0)/ + j:s/B./\=submatch(0)/ + /^Q$ + :s/Q[^\n]Q/\=submatch(0)."foobar"/ ++ :" Avoid :s error breaks dotest map on Windows. + ENDTEST + + TEST_7: +*** ../vim-7.3.889/src/version.c 2013-04-14 16:18:52.000000000 +0200 +--- src/version.c 2013-04-14 16:21:14.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 890, + /**/ + +-- +"Hit any key to continue" it said, but nothing happened after F sharp. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 042920f49ff30cb808c13773ac923e1ebd6dd9f1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:40 +0200 Subject: [PATCH 0777/3340] - patchlevel 891 --- 7.3.891 | 142 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 142 insertions(+) create mode 100644 7.3.891 diff --git a/7.3.891 b/7.3.891 new file mode 100644 index 00000000..456410f4 --- /dev/null +++ b/7.3.891 @@ -0,0 +1,142 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.891 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.891 +Problem: Merging viminfo history doesn't work well. +Solution: Don't stop when one type of history is empty. Don't merge history + when writing viminfo. +Files: src/ex_getln.c + + +*** ../vim-7.3.890/src/ex_getln.c 2013-04-06 14:28:56.000000000 +0200 +--- src/ex_getln.c 2013-04-14 16:25:28.000000000 +0200 +*************** +*** 6130,6136 **** + for (type = 0; type < HIST_COUNT; ++type) + { + if (history[type] == NULL) +! return; + idx = hisidx[type] + viminfo_hisidx[type]; + if (idx >= hislen) + idx -= hislen; +--- 6130,6136 ---- + for (type = 0; type < HIST_COUNT; ++type) + { + if (history[type] == NULL) +! continue; + idx = hisidx[type] + viminfo_hisidx[type]; + if (idx >= hislen) + idx -= hislen; +*************** +*** 6182,6187 **** +--- 6182,6188 ---- + int num_saved; + char_u *p; + int c; ++ int round; + + init_history(); + if (hislen == 0) +*************** +*** 6200,6225 **** + _("Input Line")); + if (num_saved > hislen) + num_saved = hislen; +! i = hisidx[type]; +! if (i >= 0) +! while (num_saved--) +! { +! p = history[type][i].hisstr; +! if (p != NULL) + { +! fputc(hist_type2char(type, TRUE), fp); +! /* For the search history: put the separator in the second +! * column; use a space if there isn't one. */ +! if (type == HIST_SEARCH) + { +! c = p[STRLEN(p) + 1]; +! putc(c == NUL ? ' ' : c, fp); + } +- viminfo_writestring(fp, p); + } +! if (--i < 0) +! i = hislen - 1; +! } + } + } + #endif /* FEAT_VIMINFO */ +--- 6201,6250 ---- + _("Input Line")); + if (num_saved > hislen) + num_saved = hislen; +! +! /* +! * Merge typed and viminfo history: +! * round 1: history of typed commands. +! * round 2: history from recently read viminfo. +! */ +! for (round = 1; round <= 2; ++round) +! { +! i = round == 1 ? hisidx[type] : 0; +! if (i >= 0) +! while (num_saved > 0 +! && !(round == 2 && i >= viminfo_hisidx[type])) + { +! p = round == 1 ? history[type][i].hisstr +! : viminfo_history[type][i]; +! if (p != NULL) + { +! --num_saved; +! fputc(hist_type2char(type, TRUE), fp); +! /* For the search history: put the separator in the +! * second column; use a space if there isn't one. */ +! if (type == HIST_SEARCH) +! { +! c = p[STRLEN(p) + 1]; +! putc(c == NUL ? ' ' : c, fp); +! } +! viminfo_writestring(fp, p); +! } +! if (round == 1) +! { +! /* Decrement index, loop around and stop when back at +! * the start. */ +! if (--i < 0) +! i = hislen - 1; +! if (i == hisidx[type]) +! break; +! } +! else +! { +! /* Increment index. Stop at the end in the while. */ +! ++i; + } + } +! } + } + } + #endif /* FEAT_VIMINFO */ +*** ../vim-7.3.890/src/version.c 2013-04-14 16:21:30.000000000 +0200 +--- src/version.c 2013-04-14 16:23:17.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 891, + /**/ + +-- +"The question of whether computers can think is just like the question +of whether submarines can swim." -- Edsger W. Dijkstra + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7c0976d098455ffea616e52e6ed5aed7e6c43936 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:41 +0200 Subject: [PATCH 0778/3340] - patchlevel 892 --- 7.3.892 | 295 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 295 insertions(+) create mode 100644 7.3.892 diff --git a/7.3.892 b/7.3.892 new file mode 100644 index 00000000..4031d4df --- /dev/null +++ b/7.3.892 @@ -0,0 +1,295 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.892 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.892 (after 7.3.891) +Problem: Still merging problems for viminfo history. +Solution: Do not merge lines when writing, don't write old viminfo lines. +Files: src/ex_getln.c, src/ex_cmds.c, src/proto/ex_getln.pro + + +*** ../vim-7.3.891/src/ex_getln.c 2013-04-14 16:26:08.000000000 +0200 +--- src/ex_getln.c 2013-04-14 23:12:37.000000000 +0200 +*************** +*** 68,74 **** + + static int hist_char2type __ARGS((int c)); + +! static int in_history __ARGS((int, char_u *, int, int)); + # ifdef FEAT_EVAL + static int calc_hist_idx __ARGS((int histype, int num)); + # endif +--- 68,74 ---- + + static int hist_char2type __ARGS((int c)); + +! static int in_history __ARGS((int, char_u *, int, int, int)); + # ifdef FEAT_EVAL + static int calc_hist_idx __ARGS((int histype, int num)); + # endif +*************** +*** 5397,5407 **** + * If 'move_to_front' is TRUE, matching entry is moved to end of history. + */ + static int +! in_history(type, str, move_to_front, sep) + int type; + char_u *str; + int move_to_front; /* Move the entry to the front if it exists */ + int sep; + { + int i; + int last_i = -1; +--- 5397,5408 ---- + * If 'move_to_front' is TRUE, matching entry is moved to end of history. + */ + static int +! in_history(type, str, move_to_front, sep, writing) + int type; + char_u *str; + int move_to_front; /* Move the entry to the front if it exists */ + int sep; ++ int writing; /* ignore entries read from viminfo */ + { + int i; + int last_i = -1; +*************** +*** 5419,5424 **** +--- 5420,5426 ---- + * well. */ + p = history[type][i].hisstr; + if (STRCMP(str, p) == 0 ++ && !(writing && history[type][i].viminfo) + && (type != HIST_SEARCH || sep == p[STRLEN(p) + 1])) + { + if (!move_to_front) +*************** +*** 5513,5519 **** + } + last_maptick = -1; + } +! if (!in_history(histype, new_entry, TRUE, sep)) + { + if (++hisidx[histype] == hislen) + hisidx[histype] = 0; +--- 5515,5521 ---- + } + last_maptick = -1; + } +! if (!in_history(histype, new_entry, TRUE, sep, FALSE)) + { + if (++hisidx[histype] == hislen) + hisidx[histype] = 0; +*************** +*** 6032,6039 **** + * This allocates history arrays to store the read history lines. + */ + void +! prepare_viminfo_history(asklen) + int asklen; + { + int i; + int num; +--- 6034,6042 ---- + * This allocates history arrays to store the read history lines. + */ + void +! prepare_viminfo_history(asklen, writing) + int asklen; ++ int writing; + { + int i; + int num; +*************** +*** 6041,6047 **** + int len; + + init_history(); +! viminfo_add_at_front = (asklen != 0); + if (asklen > hislen) + asklen = hislen; + +--- 6044,6050 ---- + int len; + + init_history(); +! viminfo_add_at_front = (asklen != 0 && !writing); + if (asklen > hislen) + asklen = hislen; + +*************** +*** 6073,6080 **** + * new. + */ + int +! read_viminfo_history(virp) + vir_T *virp; + { + int type; + long_u len; +--- 6076,6084 ---- + * new. + */ + int +! read_viminfo_history(virp, writing) + vir_T *virp; ++ int writing; + { + int type; + long_u len; +*************** +*** 6090,6096 **** + int sep = (*val == ' ' ? NUL : *val); + + if (!in_history(type, val + (type == HIST_SEARCH), +! viminfo_add_at_front, sep)) + { + /* Need to re-allocate to append the separator byte. */ + len = STRLEN(val); +--- 6094,6100 ---- + int sep = (*val == ' ' ? NUL : *val); + + if (!in_history(type, val + (type == HIST_SEARCH), +! viminfo_add_at_front, sep, writing)) + { + /* Need to re-allocate to append the separator byte. */ + len = STRLEN(val); +*************** +*** 6120,6125 **** +--- 6124,6132 ---- + return viminfo_readline(virp); + } + ++ /* ++ * Finish reading history lines from viminfo. Not used when writing viminfo. ++ */ + void + finish_viminfo_history() + { +*************** +*** 6216,6222 **** + { + p = round == 1 ? history[type][i].hisstr + : viminfo_history[type][i]; +! if (p != NULL) + { + --num_saved; + fputc(hist_type2char(type, TRUE), fp); +--- 6223,6229 ---- + { + p = round == 1 ? history[type][i].hisstr + : viminfo_history[type][i]; +! if (p != NULL && (round == 2 || !history[type][i].viminfo)) + { + --num_saved; + fputc(hist_type2char(type, TRUE), fp); +*************** +*** 6245,6250 **** +--- 6252,6261 ---- + } + } + } ++ for (i = 0; i < viminfo_hisidx[type]; ++i) ++ vim_free(viminfo_history[type][i]); ++ vim_free(viminfo_history[type]); ++ viminfo_history[type] = NULL; + } + } + #endif /* FEAT_VIMINFO */ +*** ../vim-7.3.891/src/ex_cmds.c 2013-03-07 16:41:26.000000000 +0100 +--- src/ex_cmds.c 2013-04-14 23:08:26.000000000 +0200 +*************** +*** 2113,2119 **** + buf_T *buf; + + #ifdef FEAT_CMDHIST +! prepare_viminfo_history(forceit ? 9999 : 0); + #endif + eof = viminfo_readline(virp); + while (!eof && virp->vir_line[0] != '>') +--- 2113,2119 ---- + buf_T *buf; + + #ifdef FEAT_CMDHIST +! prepare_viminfo_history(forceit ? 9999 : 0, writing); + #endif + eof = viminfo_readline(virp); + while (!eof && virp->vir_line[0] != '>') +*************** +*** 2161,2167 **** + case '=': + case '@': + #ifdef FEAT_CMDHIST +! eof = read_viminfo_history(virp); + #else + eof = viminfo_readline(virp); + #endif +--- 2161,2167 ---- + case '=': + case '@': + #ifdef FEAT_CMDHIST +! eof = read_viminfo_history(virp, writing); + #else + eof = viminfo_readline(virp); + #endif +*************** +*** 2182,2188 **** + + #ifdef FEAT_CMDHIST + /* Finish reading history items. */ +! finish_viminfo_history(); + #endif + + /* Change file names to buffer numbers for fmarks. */ +--- 2182,2189 ---- + + #ifdef FEAT_CMDHIST + /* Finish reading history items. */ +! if (!writing) +! finish_viminfo_history(); + #endif + + /* Change file names to buffer numbers for fmarks. */ +*** ../vim-7.3.891/src/proto/ex_getln.pro 2011-05-19 18:26:34.000000000 +0200 +--- src/proto/ex_getln.pro 2013-04-14 23:12:02.000000000 +0200 +*************** +*** 48,55 **** + void remove_key_from_history __ARGS((void)); + int get_list_range __ARGS((char_u **str, int *num1, int *num2)); + void ex_history __ARGS((exarg_T *eap)); +! void prepare_viminfo_history __ARGS((int asklen)); +! int read_viminfo_history __ARGS((vir_T *virp)); + void finish_viminfo_history __ARGS((void)); + void write_viminfo_history __ARGS((FILE *fp)); + void cmd_pchar __ARGS((int c, int offset)); +--- 48,55 ---- + void remove_key_from_history __ARGS((void)); + int get_list_range __ARGS((char_u **str, int *num1, int *num2)); + void ex_history __ARGS((exarg_T *eap)); +! void prepare_viminfo_history __ARGS((int asklen, int writing)); +! int read_viminfo_history __ARGS((vir_T *virp, int writing)); + void finish_viminfo_history __ARGS((void)); + void write_viminfo_history __ARGS((FILE *fp)); + void cmd_pchar __ARGS((int c, int offset)); +*** ../vim-7.3.891/src/version.c 2013-04-14 16:26:08.000000000 +0200 +--- src/version.c 2013-04-14 22:53:04.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 892, + /**/ + +-- +"Hit any key to continue" is a lie. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 520a3cb1179ae0c810ccb1eb62f46e8f6abda83d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:42 +0200 Subject: [PATCH 0779/3340] - patchlevel 893 --- 7.3.893 | 718 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 718 insertions(+) create mode 100644 7.3.893 diff --git a/7.3.893 b/7.3.893 new file mode 100644 index 00000000..5dd71ba7 --- /dev/null +++ b/7.3.893 @@ -0,0 +1,718 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.893 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.893 +Problem: Crash when using b:, w: or t: after closing the buffer, window or + tabpage. +Solution: Allocate the dictionary instead of having it part of the + buffer/window/tabpage struct. (Yukihiro Nakadaira) +Files: src/buffer.c, src/eval.c, src/fileio.c, src/structs.h, + src/window.c, src/proto/eval.pro + + +*** ../vim-7.3.892/src/buffer.c 2013-03-19 16:46:59.000000000 +0100 +--- src/buffer.c 2013-04-15 12:07:07.000000000 +0200 +*************** +*** 648,653 **** +--- 648,656 ---- + buf_T *buf; + { + free_buffer_stuff(buf, TRUE); ++ #ifdef FEAT_EVAL ++ unref_var_dict(buf->b_vars); ++ #endif + #ifdef FEAT_LUA + lua_buffer_free(buf); + #endif +*************** +*** 689,696 **** + #endif + } + #ifdef FEAT_EVAL +! vars_clear(&buf->b_vars.dv_hashtab); /* free all internal variables */ +! hash_init(&buf->b_vars.dv_hashtab); + #endif + #ifdef FEAT_USR_CMDS + uc_clear(&buf->b_ucmds); /* clear local user commands */ +--- 692,699 ---- + #endif + } + #ifdef FEAT_EVAL +! vars_clear(&buf->b_vars->dv_hashtab); /* free all internal variables */ +! hash_init(&buf->b_vars->dv_hashtab); + #endif + #ifdef FEAT_USR_CMDS + uc_clear(&buf->b_ucmds); /* clear local user commands */ +*************** +*** 1694,1699 **** +--- 1697,1713 ---- + vim_free(ffname); + return NULL; + } ++ #ifdef FEAT_EVAL ++ /* init b: variables */ ++ buf->b_vars = dict_alloc(); ++ if (buf->b_vars == NULL) ++ { ++ vim_free(ffname); ++ vim_free(buf); ++ return NULL; ++ } ++ init_var_dict(buf->b_vars, &buf->b_bufvar, VAR_SCOPE); ++ #endif + } + + if (ffname != NULL) +*************** +*** 1778,1787 **** + buf->b_wininfo->wi_fpos.lnum = lnum; + buf->b_wininfo->wi_win = curwin; + +- #ifdef FEAT_EVAL +- /* init b: variables */ +- init_var_dict(&buf->b_vars, &buf->b_bufvar, VAR_SCOPE); +- #endif + #ifdef FEAT_SYN_HL + hash_init(&buf->b_s.b_keywtab); + hash_init(&buf->b_s.b_keywtab_ic); +--- 1792,1797 ---- +*** ../vim-7.3.892/src/eval.c 2013-03-19 14:25:50.000000000 +0100 +--- src/eval.c 2013-04-15 12:26:33.000000000 +0200 +*************** +*** 2131,2137 **** + { + char_u numbuf[NUMBUFLEN]; + +! list_hashtable_vars(&curbuf->b_vars.dv_hashtab, (char_u *)"b:", + TRUE, first); + + sprintf((char *)numbuf, "%ld", (long)curbuf->b_changedtick); +--- 2131,2137 ---- + { + char_u numbuf[NUMBUFLEN]; + +! list_hashtable_vars(&curbuf->b_vars->dv_hashtab, (char_u *)"b:", + TRUE, first); + + sprintf((char *)numbuf, "%ld", (long)curbuf->b_changedtick); +*************** +*** 2146,2152 **** + list_win_vars(first) + int *first; + { +! list_hashtable_vars(&curwin->w_vars.dv_hashtab, + (char_u *)"w:", TRUE, first); + } + +--- 2146,2152 ---- + list_win_vars(first) + int *first; + { +! list_hashtable_vars(&curwin->w_vars->dv_hashtab, + (char_u *)"w:", TRUE, first); + } + +*************** +*** 2158,2164 **** + list_tab_vars(first) + int *first; + { +! list_hashtable_vars(&curtab->tp_vars.dv_hashtab, + (char_u *)"t:", TRUE, first); + } + #endif +--- 2158,2164 ---- + list_tab_vars(first) + int *first; + { +! list_hashtable_vars(&curtab->tp_vars->dv_hashtab, + (char_u *)"t:", TRUE, first); + } + #endif +*************** +*** 3948,3954 **** + } + + /* b: variables */ +! ht = &curbuf->b_vars.dv_hashtab; + if (bdone < ht->ht_used) + { + if (bdone++ == 0) +--- 3948,3954 ---- + } + + /* b: variables */ +! ht = &curbuf->b_vars->dv_hashtab; + if (bdone < ht->ht_used) + { + if (bdone++ == 0) +*************** +*** 3966,3972 **** + } + + /* w: variables */ +! ht = &curwin->w_vars.dv_hashtab; + if (wdone < ht->ht_used) + { + if (wdone++ == 0) +--- 3966,3972 ---- + } + + /* w: variables */ +! ht = &curwin->w_vars->dv_hashtab; + if (wdone < ht->ht_used) + { + if (wdone++ == 0) +*************** +*** 3980,3986 **** + + #ifdef FEAT_WINDOWS + /* t: variables */ +! ht = &curtab->tp_vars.dv_hashtab; + if (tdone < ht->ht_used) + { + if (tdone++ == 0) +--- 3980,3986 ---- + + #ifdef FEAT_WINDOWS + /* t: variables */ +! ht = &curtab->tp_vars->dv_hashtab; + if (tdone < ht->ht_used) + { + if (tdone++ == 0) +*************** +*** 6787,6802 **** + + /* buffer-local variables */ + for (buf = firstbuf; buf != NULL; buf = buf->b_next) +! set_ref_in_ht(&buf->b_vars.dv_hashtab, copyID); + + /* window-local variables */ + FOR_ALL_TAB_WINDOWS(tp, wp) +! set_ref_in_ht(&wp->w_vars.dv_hashtab, copyID); + + #ifdef FEAT_WINDOWS + /* tabpage-local variables */ + for (tp = first_tabpage; tp != NULL; tp = tp->tp_next) +! set_ref_in_ht(&tp->tp_vars.dv_hashtab, copyID); + #endif + + /* global variables */ +--- 6787,6802 ---- + + /* buffer-local variables */ + for (buf = firstbuf; buf != NULL; buf = buf->b_next) +! set_ref_in_item(&buf->b_bufvar.di_tv, copyID); + + /* window-local variables */ + FOR_ALL_TAB_WINDOWS(tp, wp) +! set_ref_in_item(&wp->w_winvar.di_tv, copyID); + + #ifdef FEAT_WINDOWS + /* tabpage-local variables */ + for (tp = first_tabpage; tp != NULL; tp = tp->tp_next) +! set_ref_in_item(&tp->tp_winvar.di_tv, copyID); + #endif + + /* global variables */ +*************** +*** 11156,11162 **** + * find_var_in_ht(). */ + varname = (char_u *)"b:" + 2; + /* look up the variable */ +! v = find_var_in_ht(&curbuf->b_vars.dv_hashtab, varname, FALSE); + if (v != NULL) + copy_tv(&v->di_tv, rettv); + } +--- 11156,11162 ---- + * find_var_in_ht(). */ + varname = (char_u *)"b:" + 2; + /* look up the variable */ +! v = find_var_in_ht(&curbuf->b_vars->dv_hashtab, varname, FALSE); + if (v != NULL) + copy_tv(&v->di_tv, rettv); + } +*************** +*** 11779,11785 **** + if (tp != NULL && varname != NULL) + { + /* look up the variable */ +! v = find_var_in_ht(&tp->tp_vars.dv_hashtab, varname, FALSE); + if (v != NULL) + copy_tv(&v->di_tv, rettv); + else if (argvars[2].v_type != VAR_UNKNOWN) +--- 11779,11785 ---- + if (tp != NULL && varname != NULL) + { + /* look up the variable */ +! v = find_var_in_ht(&tp->tp_vars->dv_hashtab, varname, FALSE); + if (v != NULL) + copy_tv(&v->di_tv, rettv); + else if (argvars[2].v_type != VAR_UNKNOWN) +*************** +*** 11935,11941 **** + * find_var_in_ht(). */ + varname = (char_u *)"w:" + 2; + /* look up the variable */ +! v = find_var_in_ht(&win->w_vars.dv_hashtab, varname, FALSE); + if (v != NULL) + copy_tv(&v->di_tv, rettv); + } +--- 11935,11941 ---- + * find_var_in_ht(). */ + varname = (char_u *)"w:" + 2; + /* look up the variable */ +! v = find_var_in_ht(&win->w_vars->dv_hashtab, varname, FALSE); + if (v != NULL) + copy_tv(&v->di_tv, rettv); + } +*************** +*** 14333,14339 **** + rettv->v_type = VAR_STRING; + } + +! #ifdef FEAT_MZSCHEME + /* + * "mzeval()" function + */ +--- 14333,14339 ---- + rettv->v_type = VAR_STRING; + } + +! #if defined(FEAT_MZSCHEME) || defined(PROTO) + /* + * "mzeval()" function + */ +*************** +*** 20134,20145 **** + || vim_strchr(name + 2, AUTOLOAD_CHAR) != NULL) + return NULL; + if (*name == 'b') /* buffer variable */ +! return &curbuf->b_vars.dv_hashtab; + if (*name == 'w') /* window variable */ +! return &curwin->w_vars.dv_hashtab; + #ifdef FEAT_WINDOWS + if (*name == 't') /* tab page variable */ +! return &curtab->tp_vars.dv_hashtab; + #endif + if (*name == 'v') /* v: variable */ + return &vimvarht; +--- 20134,20145 ---- + || vim_strchr(name + 2, AUTOLOAD_CHAR) != NULL) + return NULL; + if (*name == 'b') /* buffer variable */ +! return &curbuf->b_vars->dv_hashtab; + if (*name == 'w') /* window variable */ +! return &curwin->w_vars->dv_hashtab; + #ifdef FEAT_WINDOWS + if (*name == 't') /* tab page variable */ +! return &curtab->tp_vars->dv_hashtab; + #endif + if (*name == 'v') /* v: variable */ + return &vimvarht; +*************** +*** 20229,20234 **** +--- 20229,20247 ---- + } + + /* ++ * Unreference a dictionary initialized by init_var_dict(). ++ */ ++ void ++ unref_var_dict(dict) ++ dict_T *dict; ++ { ++ /* Now the dict needs to be freed if no one else is using it, go back to ++ * normal reference counting. */ ++ dict->dv_refcount -= DO_NOT_FREE_CNT - 1; ++ dict_unref(dict); ++ } ++ ++ /* + * Clean up a list of internal variables. + * Frees all allocated variables and the value they contain. + * Clears hashtab "ht", does not free it. +*** ../vim-7.3.892/src/fileio.c 2013-03-19 16:46:59.000000000 +0100 +--- src/fileio.c 2013-04-15 11:52:34.000000000 +0200 +*************** +*** 8955,8962 **** + /* Hmm, original window disappeared. Just use the first one. */ + curwin = firstwin; + # ifdef FEAT_EVAL +! vars_clear(&aucmd_win->w_vars.dv_hashtab); /* free all w: variables */ +! hash_init(&aucmd_win->w_vars.dv_hashtab); /* re-use the hashtab */ + # endif + #else + curwin = aco->save_curwin; +--- 8955,8962 ---- + /* Hmm, original window disappeared. Just use the first one. */ + curwin = firstwin; + # ifdef FEAT_EVAL +! vars_clear(&aucmd_win->w_vars->dv_hashtab); /* free all w: variables */ +! hash_init(&aucmd_win->w_vars->dv_hashtab); /* re-use the hashtab */ + # endif + #else + curwin = aco->save_curwin; +*** ../vim-7.3.892/src/structs.h 2012-07-16 17:31:48.000000000 +0200 +--- src/structs.h 2013-04-15 11:52:34.000000000 +0200 +*************** +*** 1611,1617 **** + + #ifdef FEAT_EVAL + dictitem_T b_bufvar; /* variable for "b:" Dictionary */ +! dict_T b_vars; /* internal variables, local to buffer */ + #endif + + #if defined(FEAT_BEVAL) && defined(FEAT_EVAL) +--- 1611,1617 ---- + + #ifdef FEAT_EVAL + dictitem_T b_bufvar; /* variable for "b:" Dictionary */ +! dict_T *b_vars; /* internal variables, local to buffer */ + #endif + + #if defined(FEAT_BEVAL) && defined(FEAT_EVAL) +*************** +*** 1757,1763 **** + frame_T *(tp_snapshot[SNAP_COUNT]); /* window layout snapshots */ + #ifdef FEAT_EVAL + dictitem_T tp_winvar; /* variable for "t:" Dictionary */ +! dict_T tp_vars; /* internal variables, local to tab page */ + #endif + }; + +--- 1757,1763 ---- + frame_T *(tp_snapshot[SNAP_COUNT]); /* window layout snapshots */ + #ifdef FEAT_EVAL + dictitem_T tp_winvar; /* variable for "t:" Dictionary */ +! dict_T *tp_vars; /* internal variables, local to tab page */ + #endif + }; + +*************** +*** 2080,2086 **** + + #ifdef FEAT_EVAL + dictitem_T w_winvar; /* variable for "w:" Dictionary */ +! dict_T w_vars; /* internal variables, local to window */ + #endif + + #if defined(FEAT_RIGHTLEFT) && defined(FEAT_FKMAP) +--- 2080,2086 ---- + + #ifdef FEAT_EVAL + dictitem_T w_winvar; /* variable for "w:" Dictionary */ +! dict_T *w_vars; /* internal variables, local to window */ + #endif + + #if defined(FEAT_RIGHTLEFT) && defined(FEAT_FKMAP) +*** ../vim-7.3.892/src/window.c 2013-02-06 13:37:58.000000000 +0100 +--- src/window.c 2013-04-15 12:20:09.000000000 +0200 +*************** +*** 3457,3481 **** + alloc_tabpage() + { + tabpage_T *tp; + + tp = (tabpage_T *)alloc_clear((unsigned)sizeof(tabpage_T)); +! if (tp != NULL) + { +! # ifdef FEAT_GUI +! int i; + +! for (i = 0; i < 3; i++) +! tp->tp_prev_which_scrollbars[i] = -1; + # endif + # ifdef FEAT_DIFF +! tp->tp_diff_invalid = TRUE; + # endif +! #ifdef FEAT_EVAL +! /* init t: variables */ +! init_var_dict(&tp->tp_vars, &tp->tp_winvar, VAR_SCOPE); +! #endif +! tp->tp_ch_used = p_ch; +! } + return tp; + } + +--- 3457,3491 ---- + alloc_tabpage() + { + tabpage_T *tp; ++ # ifdef FEAT_GUI ++ int i; ++ # endif ++ + + tp = (tabpage_T *)alloc_clear((unsigned)sizeof(tabpage_T)); +! if (tp == NULL) +! return NULL; +! +! # ifdef FEAT_EVAL +! /* init t: variables */ +! tp->tp_vars = dict_alloc(); +! if (tp->tp_vars == NULL) + { +! vim_free(tp); +! return NULL; +! } +! init_var_dict(tp->tp_vars, &tp->tp_winvar, VAR_SCOPE); +! # endif + +! # ifdef FEAT_GUI +! for (i = 0; i < 3; i++) +! tp->tp_prev_which_scrollbars[i] = -1; + # endif + # ifdef FEAT_DIFF +! tp->tp_diff_invalid = TRUE; + # endif +! tp->tp_ch_used = p_ch; +! + return tp; + } + +*************** +*** 3491,3497 **** + for (idx = 0; idx < SNAP_COUNT; ++idx) + clear_snapshot(tp, idx); + #ifdef FEAT_EVAL +! vars_clear(&tp->tp_vars.dv_hashtab); /* free all t: variables */ + #endif + vim_free(tp); + } +--- 3501,3509 ---- + for (idx = 0; idx < SNAP_COUNT; ++idx) + clear_snapshot(tp, idx); + #ifdef FEAT_EVAL +! vars_clear(&tp->tp_vars->dv_hashtab); /* free all t: variables */ +! hash_init(&tp->tp_vars->dv_hashtab); +! unref_var_dict(tp->tp_vars); + #endif + vim_free(tp); + } +*************** +*** 4363,4433 **** + * allocate window structure and linesizes arrays + */ + new_wp = (win_T *)alloc_clear((unsigned)sizeof(win_T)); +! if (new_wp != NULL && win_alloc_lines(new_wp) == FAIL) + { + vim_free(new_wp); +! new_wp = NULL; + } + +! if (new_wp != NULL) + { + #ifdef FEAT_AUTOCMD +! /* Don't execute autocommands while the window is not properly +! * initialized yet. gui_create_scrollbar() may trigger a FocusGained +! * event. */ +! block_autocmds(); + #endif +! /* +! * link the window in the window list +! */ + #ifdef FEAT_WINDOWS +! if (!hidden) +! win_append(after, new_wp); + #endif + #ifdef FEAT_VERTSPLIT +! new_wp->w_wincol = 0; +! new_wp->w_width = Columns; + #endif + +! /* position the display and the cursor at the top of the file. */ +! new_wp->w_topline = 1; + #ifdef FEAT_DIFF +! new_wp->w_topfill = 0; + #endif +! new_wp->w_botline = 2; +! new_wp->w_cursor.lnum = 1; + #ifdef FEAT_SCROLLBIND +! new_wp->w_scbind_pos = 1; + #endif + +! /* We won't calculate w_fraction until resizing the window */ +! new_wp->w_fraction = 0; +! new_wp->w_prev_fraction_row = -1; + + #ifdef FEAT_GUI +! if (gui.in_use) +! { +! gui_create_scrollbar(&new_wp->w_scrollbars[SBAR_LEFT], +! SBAR_LEFT, new_wp); +! gui_create_scrollbar(&new_wp->w_scrollbars[SBAR_RIGHT], +! SBAR_RIGHT, new_wp); +! } +! #endif +! #ifdef FEAT_EVAL +! /* init w: variables */ +! init_var_dict(&new_wp->w_vars, &new_wp->w_winvar, VAR_SCOPE); + #endif + #ifdef FEAT_FOLDING +! foldInitWin(new_wp); + #endif + #ifdef FEAT_AUTOCMD +! unblock_autocmds(); + #endif + #ifdef FEAT_SEARCH_EXTRA +! new_wp->w_match_head = NULL; +! new_wp->w_next_match_id = 4; + #endif +- } + return new_wp; + } + +--- 4375,4453 ---- + * allocate window structure and linesizes arrays + */ + new_wp = (win_T *)alloc_clear((unsigned)sizeof(win_T)); +! if (new_wp == NULL) +! return NULL; +! +! if (win_alloc_lines(new_wp) == FAIL) + { + vim_free(new_wp); +! return NULL; + } + +! #ifdef FEAT_EVAL +! /* init w: variables */ +! new_wp->w_vars = dict_alloc(); +! if (new_wp->w_vars == NULL) + { ++ win_free_lsize(new_wp); ++ vim_free(new_wp); ++ return NULL; ++ } ++ init_var_dict(new_wp->w_vars, &new_wp->w_winvar, VAR_SCOPE); ++ #endif ++ + #ifdef FEAT_AUTOCMD +! /* Don't execute autocommands while the window is not properly +! * initialized yet. gui_create_scrollbar() may trigger a FocusGained +! * event. */ +! block_autocmds(); + #endif +! /* +! * link the window in the window list +! */ + #ifdef FEAT_WINDOWS +! if (!hidden) +! win_append(after, new_wp); + #endif + #ifdef FEAT_VERTSPLIT +! new_wp->w_wincol = 0; +! new_wp->w_width = Columns; + #endif + +! /* position the display and the cursor at the top of the file. */ +! new_wp->w_topline = 1; + #ifdef FEAT_DIFF +! new_wp->w_topfill = 0; + #endif +! new_wp->w_botline = 2; +! new_wp->w_cursor.lnum = 1; + #ifdef FEAT_SCROLLBIND +! new_wp->w_scbind_pos = 1; + #endif + +! /* We won't calculate w_fraction until resizing the window */ +! new_wp->w_fraction = 0; +! new_wp->w_prev_fraction_row = -1; + + #ifdef FEAT_GUI +! if (gui.in_use) +! { +! gui_create_scrollbar(&new_wp->w_scrollbars[SBAR_LEFT], +! SBAR_LEFT, new_wp); +! gui_create_scrollbar(&new_wp->w_scrollbars[SBAR_RIGHT], +! SBAR_RIGHT, new_wp); +! } + #endif + #ifdef FEAT_FOLDING +! foldInitWin(new_wp); + #endif + #ifdef FEAT_AUTOCMD +! unblock_autocmds(); + #endif + #ifdef FEAT_SEARCH_EXTRA +! new_wp->w_match_head = NULL; +! new_wp->w_next_match_id = 4; + #endif + return new_wp; + } + +*************** +*** 4488,4494 **** + clear_winopt(&wp->w_allbuf_opt); + + #ifdef FEAT_EVAL +! vars_clear(&wp->w_vars.dv_hashtab); /* free all w: variables */ + #endif + + if (prevwin == wp) +--- 4508,4516 ---- + clear_winopt(&wp->w_allbuf_opt); + + #ifdef FEAT_EVAL +! vars_clear(&wp->w_vars->dv_hashtab); /* free all w: variables */ +! hash_init(&wp->w_vars->dv_hashtab); +! unref_var_dict(wp->w_vars); + #endif + + if (prevwin == wp) +*** ../vim-7.3.892/src/proto/eval.pro 2013-01-30 14:55:35.000000000 +0100 +--- src/proto/eval.pro 2013-04-15 12:26:39.000000000 +0200 +*************** +*** 24,31 **** + int get_spellword __ARGS((list_T *list, char_u **pp)); + typval_T *eval_expr __ARGS((char_u *arg, char_u **nextcmd)); + int call_vim_function __ARGS((char_u *func, int argc, char_u **argv, int safe, int str_arg_only, typval_T *rettv)); +- void *call_func_retstr __ARGS((char_u *func, int argc, char_u **argv, int safe)); + long call_func_retnr __ARGS((char_u *func, int argc, char_u **argv, int safe)); + void *call_func_retlist __ARGS((char_u *func, int argc, char_u **argv, int safe)); + void *save_funccal __ARGS((void)); + void restore_funccal __ARGS((void *vfc)); +--- 24,31 ---- + int get_spellword __ARGS((list_T *list, char_u **pp)); + typval_T *eval_expr __ARGS((char_u *arg, char_u **nextcmd)); + int call_vim_function __ARGS((char_u *func, int argc, char_u **argv, int safe, int str_arg_only, typval_T *rettv)); + long call_func_retnr __ARGS((char_u *func, int argc, char_u **argv, int safe)); ++ void *call_func_retstr __ARGS((char_u *func, int argc, char_u **argv, int safe)); + void *call_func_retlist __ARGS((char_u *func, int argc, char_u **argv, int safe)); + void *save_funccal __ARGS((void)); + void restore_funccal __ARGS((void *vfc)); +*************** +*** 95,100 **** +--- 95,101 ---- + char_u *get_var_value __ARGS((char_u *name)); + void new_script_vars __ARGS((scid_T id)); + void init_var_dict __ARGS((dict_T *dict, dictitem_T *dict_var, int scope)); ++ void unref_var_dict __ARGS((dict_T *dict)); + void vars_clear __ARGS((hashtab_T *ht)); + void copy_tv __ARGS((typval_T *from, typval_T *to)); + void ex_echo __ARGS((exarg_T *eap)); +*** ../vim-7.3.892/src/version.c 2013-04-14 23:19:32.000000000 +0200 +--- src/version.c 2013-04-15 12:19:17.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 893, + /**/ + +-- +Apathy Error: Don't bother striking any key. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From be2e68872fb1a5f2e0bdb530a6a0c0789ece9dab Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:42 +0200 Subject: [PATCH 0780/3340] - patchlevel 894 --- 7.3.894 | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 7.3.894 diff --git a/7.3.894 b/7.3.894 new file mode 100644 index 00000000..8b435fee --- /dev/null +++ b/7.3.894 @@ -0,0 +1,47 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.894 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.894 +Problem: Using wrong RUBY_VER causing Ruby build to break. +Solution: Correct the RUBY_VER value. (Yongwei Wu) +Files: src/bigvim.bat + + +*** ../vim-7.3.893/src/bigvim.bat 2012-08-29 14:18:26.000000000 +0200 +--- src/bigvim.bat 2013-04-15 12:32:08.000000000 +0200 +*************** +*** 1,5 **** + :: command to build big Vim with OLE, Perl, Python, Ruby and Tcl + SET VCDIR="C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\bin\" + SET TOOLDIR=E:\ +! %VCDIR%nmake -f Make_mvc.mak GUI=yes OLE=yes PERL=E:\perl514 DYNAMIC_PERL=yes PERL_VER=514 PYTHON=%TOOLDIR%python27 DYNAMIC_PYTHON=yes PYTHON_VER=27 PYTHON3=%TOOLDIR%python32 DYNAMIC_PYTHON3=yes PYTHON3_VER=32 RUBY=%TOOLDIR%ruby192 DYNAMIC_RUBY=yes RUBY_VER=192 RUBY_VER_LONG=1.9.2 TCL=%TOOLDIR%tcl TCL_VER=85 TCL_VER_LONG=8.5 DYNAMIC_TCL=yes %1 IME=yes CSCOPE=yes + +--- 1,5 ---- + :: command to build big Vim with OLE, Perl, Python, Ruby and Tcl + SET VCDIR="C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\bin\" + SET TOOLDIR=E:\ +! %VCDIR%nmake -f Make_mvc.mak GUI=yes OLE=yes PERL=E:\perl514 DYNAMIC_PERL=yes PERL_VER=514 PYTHON=%TOOLDIR%python27 DYNAMIC_PYTHON=yes PYTHON_VER=27 PYTHON3=%TOOLDIR%python32 DYNAMIC_PYTHON3=yes PYTHON3_VER=32 RUBY=%TOOLDIR%ruby192 DYNAMIC_RUBY=yes RUBY_VER=19 RUBY_VER_LONG=1.9.2 TCL=%TOOLDIR%tcl TCL_VER=85 TCL_VER_LONG=8.5 DYNAMIC_TCL=yes %1 IME=yes CSCOPE=yes + +*** ../vim-7.3.893/src/version.c 2013-04-15 12:27:30.000000000 +0200 +--- src/version.c 2013-04-15 12:34:36.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 894, + /**/ + +-- +Did you ever see a "Hit any key to continue" message in a music piece? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d1aaf17c79160dba71d21e40f33537c3ee3e1faf Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:43 +0200 Subject: [PATCH 0781/3340] - patchlevel 895 --- 7.3.895 | 189 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 189 insertions(+) create mode 100644 7.3.895 diff --git a/7.3.895 b/7.3.895 new file mode 100644 index 00000000..676c972e --- /dev/null +++ b/7.3.895 @@ -0,0 +1,189 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.895 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.895 +Problem: Valgrind error in test 91. (Issue 128) +Solution: Pass scope name to find_var_in_ht(). +Files: src/eval.c + + +*** ../vim-7.3.894/src/eval.c 2013-04-15 12:27:30.000000000 +0200 +--- src/eval.c 2013-04-15 13:00:44.000000000 +0200 +*************** +*** 788,794 **** + static char_u *get_tv_string_buf __ARGS((typval_T *varp, char_u *buf)); + static char_u *get_tv_string_buf_chk __ARGS((typval_T *varp, char_u *buf)); + static dictitem_T *find_var __ARGS((char_u *name, hashtab_T **htp)); +! static dictitem_T *find_var_in_ht __ARGS((hashtab_T *ht, char_u *varname, int writing)); + static hashtab_T *find_var_ht __ARGS((char_u *name, char_u **varname)); + static void vars_clear_ext __ARGS((hashtab_T *ht, int free_val)); + static void delete_var __ARGS((hashtab_T *ht, hashitem_T *hi)); +--- 788,794 ---- + static char_u *get_tv_string_buf __ARGS((typval_T *varp, char_u *buf)); + static char_u *get_tv_string_buf_chk __ARGS((typval_T *varp, char_u *buf)); + static dictitem_T *find_var __ARGS((char_u *name, hashtab_T **htp)); +! static dictitem_T *find_var_in_ht __ARGS((hashtab_T *ht, int htname, char_u *varname, int writing)); + static hashtab_T *find_var_ht __ARGS((char_u *name, char_u **varname)); + static void vars_clear_ext __ARGS((hashtab_T *ht, int free_val)); + static void delete_var __ARGS((hashtab_T *ht, hashitem_T *hi)); +*************** +*** 11150,11162 **** + } + else + { +! if (*varname == NUL) +! /* let getbufvar({nr}, "") return the "b:" dictionary. The +! * scope prefix before the NUL byte is required by +! * find_var_in_ht(). */ +! varname = (char_u *)"b:" + 2; +! /* look up the variable */ +! v = find_var_in_ht(&curbuf->b_vars->dv_hashtab, varname, FALSE); + if (v != NULL) + copy_tv(&v->di_tv, rettv); + } +--- 11150,11159 ---- + } + else + { +! /* Look up the variable. */ +! /* Let getbufvar({nr}, "") return the "b:" dictionary. */ +! v = find_var_in_ht(&curbuf->b_vars->dv_hashtab, +! 'b', varname, FALSE); + if (v != NULL) + copy_tv(&v->di_tv, rettv); + } +*************** +*** 11779,11785 **** + if (tp != NULL && varname != NULL) + { + /* look up the variable */ +! v = find_var_in_ht(&tp->tp_vars->dv_hashtab, varname, FALSE); + if (v != NULL) + copy_tv(&v->di_tv, rettv); + else if (argvars[2].v_type != VAR_UNKNOWN) +--- 11776,11782 ---- + if (tp != NULL && varname != NULL) + { + /* look up the variable */ +! v = find_var_in_ht(&tp->tp_vars->dv_hashtab, 0, varname, FALSE); + if (v != NULL) + copy_tv(&v->di_tv, rettv); + else if (argvars[2].v_type != VAR_UNKNOWN) +*************** +*** 11929,11941 **** + get_option_tv(&varname, rettv, 1); + else + { +! if (*varname == NUL) +! /* let getwinvar({nr}, "") return the "w:" dictionary. The +! * scope prefix before the NUL byte is required by +! * find_var_in_ht(). */ +! varname = (char_u *)"w:" + 2; +! /* look up the variable */ +! v = find_var_in_ht(&win->w_vars->dv_hashtab, varname, FALSE); + if (v != NULL) + copy_tv(&v->di_tv, rettv); + } +--- 11926,11934 ---- + get_option_tv(&varname, rettv, 1); + else + { +! /* Look up the variable. */ +! /* Let getwinvar({nr}, "") return the "w:" dictionary. */ +! v = find_var_in_ht(&win->w_vars->dv_hashtab, 'w', varname, FALSE); + if (v != NULL) + copy_tv(&v->di_tv, rettv); + } +*************** +*** 20041,20056 **** + *htp = ht; + if (ht == NULL) + return NULL; +! return find_var_in_ht(ht, varname, htp != NULL); + } + + /* +! * Find variable "varname" in hashtab "ht". + * Returns NULL if not found. + */ + static dictitem_T * +! find_var_in_ht(ht, varname, writing) + hashtab_T *ht; + char_u *varname; + int writing; + { +--- 20034,20050 ---- + *htp = ht; + if (ht == NULL) + return NULL; +! return find_var_in_ht(ht, *name, varname, htp != NULL); + } + + /* +! * Find variable "varname" in hashtab "ht" with name "htname". + * Returns NULL if not found. + */ + static dictitem_T * +! find_var_in_ht(ht, htname, varname, writing) + hashtab_T *ht; ++ int htname; + char_u *varname; + int writing; + { +*************** +*** 20059,20065 **** + if (*varname == NUL) + { + /* Must be something like "s:", otherwise "ht" would be NULL. */ +! switch (varname[-2]) + { + case 's': return &SCRIPT_SV(current_SID)->sv_var; + case 'g': return &globvars_var; +--- 20053,20059 ---- + if (*varname == NUL) + { + /* Must be something like "s:", otherwise "ht" would be NULL. */ +! switch (htname) + { + case 's': return &SCRIPT_SV(current_SID)->sv_var; + case 'g': return &globvars_var; +*************** +*** 20389,20395 **** + EMSG2(_(e_illvar), name); + return; + } +! v = find_var_in_ht(ht, varname, TRUE); + + if (tv->v_type == VAR_FUNC && var_check_func_name(name, v == NULL)) + return; +--- 20383,20389 ---- + EMSG2(_(e_illvar), name); + return; + } +! v = find_var_in_ht(ht, 0, varname, TRUE); + + if (tv->v_type == VAR_FUNC && var_check_func_name(name, v == NULL)) + return; +*** ../vim-7.3.894/src/version.c 2013-04-15 12:36:14.000000000 +0200 +--- src/version.c 2013-04-15 13:04:54.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 895, + /**/ + +-- + Very funny, Scotty. Now beam down my clothes. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9785c117e89e9f4d922cde01c6bac5cb1dd9ebda Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:43 +0200 Subject: [PATCH 0782/3340] - patchlevel 896 --- 7.3.896 | 206 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 206 insertions(+) create mode 100644 7.3.896 diff --git a/7.3.896 b/7.3.896 new file mode 100644 index 00000000..e7f33ccc --- /dev/null +++ b/7.3.896 @@ -0,0 +1,206 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.896 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.896 +Problem: Memory leaks in Lua interface. +Solution: Fix the leaks, add tests. (Yukihiro Nakadaira) +Files: src/testdir/test85.in, src/testdir/test85.ok, src/if_lua.c + + +*** ../vim-7.3.895/src/testdir/test85.in 2012-04-05 16:56:38.000000000 +0200 +--- src/testdir/test85.in 2013-04-15 13:12:43.000000000 +0200 +*************** +*** 33,38 **** +--- 33,81 ---- + :let res = "FAILED" + :endif + :call setline(search("^3"), "circular test " . res) ++ ++ :let l = [] ++ :lua l = vim.eval("l") ++ :lua l:add(123) ++ :lua l:add("abc") ++ :lua l:add(vim.eval("[1, 2, 3]")) ++ :lua l:add(vim.eval("{'a':1, 'b':2, 'c':3}")) ++ :lua l:insert(123) ++ :lua l:insert("abc") ++ :lua l:insert(vim.eval("[1, 2, 3]")) ++ :lua l:insert(vim.eval("{'a':1, 'b':2, 'c':3}")) ++ :lua l[0] = l[0] ++ :lua l[1] = l[1] ++ :lua l[2] = l[2] ++ :lua l[3] = l[3] ++ :lua l[0] = 123 ++ :lua l[1] = "abc" ++ :lua l[2] = vim.eval("[1, 2, 3]") ++ :lua l[3] = vim.eval("{'a':1, 'b':2, 'c':3}") ++ :lua l[3] = nil ++ :lua l[2] = nil ++ :lua l[1] = nil ++ :lua l[0] = nil ++ :lua l = nil ++ :$put =string(l) ++ ++ :let d = {} ++ :lua d = vim.eval("d") ++ :lua d[0] = 123 ++ :lua d[1] = "abc" ++ :lua d[2] = vim.eval("[1, 2, 3]") ++ :lua d[3] = vim.eval("{'a':1, 'b':2, 'c':3}") ++ :lua d[4] = d[0] ++ :lua d[5] = d[1] ++ :lua d[6] = d[2] ++ :lua d[7] = d[3] ++ :lua d[3] = nil ++ :lua d[2] = nil ++ :lua d[1] = nil ++ :lua d[0] = nil ++ :lua d = nil ++ :$put =string(d) ++ + :?^1?,$w! test.out + :qa! + ENDTEST +*** ../vim-7.3.895/src/testdir/test85.ok 2012-04-05 16:56:38.000000000 +0200 +--- src/testdir/test85.ok 2013-04-15 13:12:47.000000000 +0200 +*************** +*** 3,5 **** +--- 3,7 ---- + 2 line 2 + dictionary with list OK + circular test OK ++ [123.0, 'abc', [1, 2, 3], {'a': 1, 'b': 2, 'c': 3}] ++ {'4': 123.0, '5': 'abc', '6': [1, 2, 3], '7': {'a': 1, 'b': 2, 'c': 3}} +*** ../vim-7.3.895/src/if_lua.c 2013-04-12 12:18:43.000000000 +0200 +--- src/if_lua.c 2013-04-15 13:35:40.000000000 +0200 +*************** +*** 709,716 **** + { + const char *s = lua_tostring(L, 2); + if (strncmp(s, "add", 3) == 0 +! || strncmp(s, "insert", 6) == 0 +! || strncmp(s, "extend", 6) == 0) + { + lua_getmetatable(L, 1); + lua_getfield(L, -1, s); +--- 709,715 ---- + { + const char *s = lua_tostring(L, 2); + if (strncmp(s, "add", 3) == 0 +! || strncmp(s, "insert", 6) == 0) + { + lua_getmetatable(L, 1); + lua_getfield(L, -1, s); +*************** +*** 745,750 **** +--- 744,750 ---- + luaV_totypval(L, 3, &v); + clear_tv(&li->li_tv); + copy_tv(&v, &li->li_tv); ++ clear_tv(&v); + } + return 0; + } +*************** +*** 754,770 **** + { + luaV_List *lis = luaV_checkudata(L, 1, LUAVIM_LIST); + list_T *l = (list_T *) luaV_checkcache(L, (void *) *lis); +! listitem_T *li; + if (l->lv_lock) + luaL_error(L, "list is locked"); +! li = listitem_alloc(); +! if (li != NULL) + { +! typval_T v; +! lua_settop(L, 2); +! luaV_totypval(L, 2, &v); +! list_append_tv(l, &v); + } + lua_settop(L, 1); + return 1; + } +--- 754,770 ---- + { + luaV_List *lis = luaV_checkudata(L, 1, LUAVIM_LIST); + list_T *l = (list_T *) luaV_checkcache(L, (void *) *lis); +! typval_T v; + if (l->lv_lock) + luaL_error(L, "list is locked"); +! lua_settop(L, 2); +! luaV_totypval(L, 2, &v); +! if (list_append_tv(l, &v) == FAIL) + { +! clear_tv(&v); +! luaL_error(L, "Failed to add item to list"); + } ++ clear_tv(&v); + lua_settop(L, 1); + return 1; + } +*************** +*** 787,793 **** + } + lua_settop(L, 2); + luaV_totypval(L, 2, &v); +! list_insert_tv(l, &v, li); + lua_settop(L, 1); + return 1; + } +--- 787,798 ---- + } + lua_settop(L, 2); + luaV_totypval(L, 2, &v); +! if (list_insert_tv(l, &v, li) == FAIL) +! { +! clear_tv(&v); +! luaL_error(L, "Failed to add item to list"); +! } +! clear_tv(&v); + lua_settop(L, 1); + return 1; + } +*************** +*** 908,913 **** +--- 913,919 ---- + typval_T v; + luaV_totypval(L, 3, &v); + copy_tv(&v, &di->di_tv); ++ clear_tv(&v); + } + return 0; + } +*************** +*** 1323,1328 **** +--- 1329,1335 ---- + typval_T *tv = eval_expr((char_u *) luaL_checkstring(L, 1), NULL); + if (tv == NULL) luaL_error(L, "invalid expression"); + luaV_pushtypval(L, tv); ++ free_tv(tv); + return 1; + } + +*** ../vim-7.3.895/src/version.c 2013-04-15 13:06:15.000000000 +0200 +--- src/version.c 2013-04-15 13:48:21.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 896, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +172. You join listservers just for the extra e-mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a37a4c9ed70c49119ba2e26fd40610c790496eb0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:44 +0200 Subject: [PATCH 0783/3340] - patchlevel 897 --- 7.3.897 | 126 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 126 insertions(+) create mode 100644 7.3.897 diff --git a/7.3.897 b/7.3.897 new file mode 100644 index 00000000..ae4813cb --- /dev/null +++ b/7.3.897 @@ -0,0 +1,126 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.897 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.897 +Problem: Configure doesn't always find the shared library. +Solution: Change the configure script. (Ken Takata) +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.896/src/configure.in 2013-02-26 14:56:24.000000000 +0100 +--- src/configure.in 2013-04-15 14:28:02.000000000 +0200 +*************** +*** 494,510 **** + if test -f "${vi_cv_path_lua_pfx}/bin/cyglua-${vi_cv_version_lua}.dll"; then + vi_cv_dll_name_lua="cyglua-${vi_cv_version_lua}.dll" + else +! dnl Determine the SONAME for the current version, but fallback to +! dnl liblua${vi_cv_version_lua}.so if no SONAME-versioned file is found. +! for LUA_SOVER in "${vi_cv_version_lua}.so" ".so.${vi_cv_version_lua}"; do +! for i in 0 1 2 3 4 5 6 7 8 9; do +! if test -f "${vi_cv_path_lua_pfx}/lib/liblua${LUA_SOVER}.$i"; then +! LUA_SONAME=".$i" +! break +! fi + done +- vi_cv_dll_name_lua="liblua${LUA_SOVER}$LUA_SONAME" + done + fi + AC_DEFINE(DYNAMIC_LUA) + LUA_LIBS="" +--- 494,519 ---- + if test -f "${vi_cv_path_lua_pfx}/bin/cyglua-${vi_cv_version_lua}.dll"; then + vi_cv_dll_name_lua="cyglua-${vi_cv_version_lua}.dll" + else +! multiarch=`dpkg-architecture -qDEB_HOST_MULTIARCH 2> /dev/null` +! if test "X$multiarch" != "X"; then +! lib_multiarch="lib/${multiarch}" +! fi +! dnl Determine the sover for the current version, but fallback to +! dnl liblua${vi_cv_version_lua}.so if no sover-versioned file is found. +! for subdir in "${lib_multiarch}" lib64 lib; do +! if test -z "$subdir"; then +! continue +! fi +! for sover in "${vi_cv_version_lua}.so" "-${vi_cv_version_lua}.so" ".so.${vi_cv_version_lua}"; do +! for i in .0 .1 .2 .3 .4 .5 .6 .7 .8 .9 ""; do +! if test -f "${vi_cv_path_lua_pfx}/${subdir}/liblua${sover}$i"; then +! sover2="$i" +! break 3 +! fi +! done + done + done ++ vi_cv_dll_name_lua="liblua${sover}$sover2" + fi + AC_DEFINE(DYNAMIC_LUA) + LUA_LIBS="" +*** ../vim-7.3.896/src/auto/configure 2013-02-26 14:56:24.000000000 +0100 +--- src/auto/configure 2013-04-15 14:28:06.000000000 +0200 +*************** +*** 4737,4751 **** + if test -f "${vi_cv_path_lua_pfx}/bin/cyglua-${vi_cv_version_lua}.dll"; then + vi_cv_dll_name_lua="cyglua-${vi_cv_version_lua}.dll" + else +! for LUA_SOVER in "${vi_cv_version_lua}.so" ".so.${vi_cv_version_lua}"; do +! for i in 0 1 2 3 4 5 6 7 8 9; do +! if test -f "${vi_cv_path_lua_pfx}/lib/liblua${LUA_SOVER}.$i"; then +! LUA_SONAME=".$i" +! break +! fi + done +- vi_cv_dll_name_lua="liblua${LUA_SOVER}$LUA_SONAME" + done + fi + $as_echo "#define DYNAMIC_LUA 1" >>confdefs.h + +--- 4737,4760 ---- + if test -f "${vi_cv_path_lua_pfx}/bin/cyglua-${vi_cv_version_lua}.dll"; then + vi_cv_dll_name_lua="cyglua-${vi_cv_version_lua}.dll" + else +! multiarch=`dpkg-architecture -qDEB_HOST_MULTIARCH 2> /dev/null` +! if test "X$multiarch" != "X"; then +! lib_multiarch="lib/${multiarch}" +! fi +! for subdir in "${lib_multiarch}" lib64 lib; do +! if test -z "$subdir"; then +! continue +! fi +! for sover in "${vi_cv_version_lua}.so" "-${vi_cv_version_lua}.so" ".so.${vi_cv_version_lua}"; do +! for i in .0 .1 .2 .3 .4 .5 .6 .7 .8 .9 ""; do +! if test -f "${vi_cv_path_lua_pfx}/${subdir}/liblua${sover}$i"; then +! sover2="$i" +! break 3 +! fi +! done + done + done ++ vi_cv_dll_name_lua="liblua${sover}$sover2" + fi + $as_echo "#define DYNAMIC_LUA 1" >>confdefs.h + +*** ../vim-7.3.896/src/version.c 2013-04-15 13:49:17.000000000 +0200 +--- src/version.c 2013-04-15 14:43:52.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 897, + /**/ + +-- +If Microsoft would build a car... +... the oil, water temperature, and alternator warning lights would +all be replaced by a single "General Protection Fault" warning light. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4c9a90575b1c6abfb21afae10653578b4fbaef75 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:45 +0200 Subject: [PATCH 0784/3340] - patchlevel 898 --- 7.3.898 | 304 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 304 insertions(+) create mode 100644 7.3.898 diff --git a/7.3.898 b/7.3.898 new file mode 100644 index 00000000..d2530a55 --- /dev/null +++ b/7.3.898 @@ -0,0 +1,304 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.898 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.898 +Problem: Memory leak reported by valgrind in test 91. +Solution: Only use default argument when needed. +Files: src/eval.c, src/testdir/test91.in, src/testdir/test91.ok + + +*** ../vim-7.3.897/src/eval.c 2013-04-15 13:06:15.000000000 +0200 +--- src/eval.c 2013-04-15 15:09:17.000000000 +0200 +*************** +*** 11120,11139 **** + buf_T *save_curbuf; + char_u *varname; + dictitem_T *v; + + (void)get_tv_number(&argvars[0]); /* issue errmsg if type error */ + varname = get_tv_string_chk(&argvars[1]); + ++emsg_off; + buf = get_buf_tv(&argvars[0], FALSE); + +! if (argvars[2].v_type != VAR_UNKNOWN) +! /* set the default value */ +! copy_tv(&argvars[2], rettv); +! else +! { +! rettv->v_type = VAR_STRING; +! rettv->vval.v_string = NULL; +! } + + if (buf != NULL && varname != NULL) + { +--- 11120,11134 ---- + buf_T *save_curbuf; + char_u *varname; + dictitem_T *v; ++ int done = FALSE; + + (void)get_tv_number(&argvars[0]); /* issue errmsg if type error */ + varname = get_tv_string_chk(&argvars[1]); + ++emsg_off; + buf = get_buf_tv(&argvars[0], FALSE); + +! rettv->v_type = VAR_STRING; +! rettv->vval.v_string = NULL; + + if (buf != NULL && varname != NULL) + { +*************** +*** 11142,11152 **** + curbuf = buf; + + if (*varname == '&') /* buffer-local-option */ +! get_option_tv(&varname, rettv, TRUE); + else if (STRCMP(varname, "changedtick") == 0) + { + rettv->v_type = VAR_NUMBER; + rettv->vval.v_number = curbuf->b_changedtick; + } + else + { +--- 11137,11151 ---- + curbuf = buf; + + if (*varname == '&') /* buffer-local-option */ +! { +! if (get_option_tv(&varname, rettv, TRUE) == OK) +! done = TRUE; +! } + else if (STRCMP(varname, "changedtick") == 0) + { + rettv->v_type = VAR_NUMBER; + rettv->vval.v_number = curbuf->b_changedtick; ++ done = TRUE; + } + else + { +*************** +*** 11155,11167 **** +--- 11154,11173 ---- + v = find_var_in_ht(&curbuf->b_vars->dv_hashtab, + 'b', varname, FALSE); + if (v != NULL) ++ { + copy_tv(&v->di_tv, rettv); ++ done = TRUE; ++ } + } + + /* restore previous notion of curbuf */ + curbuf = save_curbuf; + } + ++ if (!done && argvars[2].v_type != VAR_UNKNOWN) ++ /* use the default value */ ++ copy_tv(&argvars[2], rettv); ++ + --emsg_off; + } + +*************** +*** 11767,11772 **** +--- 11773,11779 ---- + tabpage_T *tp; + dictitem_T *v; + char_u *varname; ++ int done = FALSE; + + rettv->v_type = VAR_STRING; + rettv->vval.v_string = NULL; +*************** +*** 11778,11788 **** + /* look up the variable */ + v = find_var_in_ht(&tp->tp_vars->dv_hashtab, 0, varname, FALSE); + if (v != NULL) + copy_tv(&v->di_tv, rettv); +! else if (argvars[2].v_type != VAR_UNKNOWN) +! copy_tv(&argvars[2], rettv); + } +! else if (argvars[2].v_type != VAR_UNKNOWN) + copy_tv(&argvars[2], rettv); + } + +--- 11785,11797 ---- + /* look up the variable */ + v = find_var_in_ht(&tp->tp_vars->dv_hashtab, 0, varname, FALSE); + if (v != NULL) ++ { + copy_tv(&v->di_tv, rettv); +! done = TRUE; +! } + } +! +! if (!done && argvars[2].v_type != VAR_UNKNOWN) + copy_tv(&argvars[2], rettv); + } + +*************** +*** 11894,11899 **** +--- 11903,11909 ---- + char_u *varname; + dictitem_T *v; + tabpage_T *tp; ++ int done = FALSE; + + #ifdef FEAT_WINDOWS + if (off == 1) +*************** +*** 11905,11918 **** + varname = get_tv_string_chk(&argvars[off + 1]); + ++emsg_off; + +! if (argvars[off + 2].v_type != VAR_UNKNOWN) +! /* set the default return value */ +! copy_tv(&argvars[off + 2], rettv); +! else +! { +! rettv->v_type = VAR_STRING; +! rettv->vval.v_string = NULL; +! } + + if (win != NULL && varname != NULL) + { +--- 11915,11922 ---- + varname = get_tv_string_chk(&argvars[off + 1]); + ++emsg_off; + +! rettv->v_type = VAR_STRING; +! rettv->vval.v_string = NULL; + + if (win != NULL && varname != NULL) + { +*************** +*** 11923,11936 **** + curbuf = win->w_buffer; + + if (*varname == '&') /* window-local-option */ +! get_option_tv(&varname, rettv, 1); + else + { + /* Look up the variable. */ + /* Let getwinvar({nr}, "") return the "w:" dictionary. */ + v = find_var_in_ht(&win->w_vars->dv_hashtab, 'w', varname, FALSE); + if (v != NULL) + copy_tv(&v->di_tv, rettv); + } + + /* restore previous notion of curwin */ +--- 11927,11946 ---- + curbuf = win->w_buffer; + + if (*varname == '&') /* window-local-option */ +! { +! if (get_option_tv(&varname, rettv, 1) == OK) +! done = TRUE; +! } + else + { + /* Look up the variable. */ + /* Let getwinvar({nr}, "") return the "w:" dictionary. */ + v = find_var_in_ht(&win->w_vars->dv_hashtab, 'w', varname, FALSE); + if (v != NULL) ++ { + copy_tv(&v->di_tv, rettv); ++ done = TRUE; ++ } + } + + /* restore previous notion of curwin */ +*************** +*** 11938,11943 **** +--- 11948,11957 ---- + curbuf = curwin->w_buffer; + } + ++ if (!done && argvars[off + 2].v_type != VAR_UNKNOWN) ++ /* use the default return value */ ++ copy_tv(&argvars[off + 2], rettv); ++ + --emsg_off; + } + +*** ../vim-7.3.897/src/testdir/test91.in 2013-02-20 21:11:14.000000000 +0100 +--- src/testdir/test91.in 2013-04-15 14:59:31.000000000 +0200 +*************** +*** 4,12 **** + STARTTEST + :so small.vim + :" +! :" test for getbufvar() +! :let b:var_num = 1234 +! :let def_num = 5678 + :$put =string(getbufvar(1, 'var_num')) + :$put =string(getbufvar(1, 'var_num', def_num)) + :$put =string(getbufvar(1, '')) +--- 4,13 ---- + STARTTEST + :so small.vim + :" +! :" Test for getbufvar() +! :" Use strings to test for memory leaks. +! :let b:var_num = '1234' +! :let def_num = '5678' + :$put =string(getbufvar(1, 'var_num')) + :$put =string(getbufvar(1, 'var_num', def_num)) + :$put =string(getbufvar(1, '')) +*** ../vim-7.3.897/src/testdir/test91.ok 2013-02-20 21:11:14.000000000 +0100 +--- src/testdir/test91.ok 2013-04-15 15:02:45.000000000 +0200 +*************** +*** 1,13 **** + start: +! 1234 +! 1234 +! {'var_num': 1234} +! {'var_num': 1234} +! 5678 + {} + {} + '' +! 5678 + 0 + 0 + 'Dance' +--- 1,13 ---- + start: +! '1234' +! '1234' +! {'var_num': '1234'} +! {'var_num': '1234'} +! '5678' + {} + {} + '' +! '5678' + 0 + 0 + 'Dance' +*** ../vim-7.3.897/src/version.c 2013-04-15 14:44:53.000000000 +0200 +--- src/version.c 2013-04-15 15:14:22.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 898, + /**/ + +-- +If Apple would build a car... +... it would be powered by the sun, be reliable, five times +as fast and twice as easy to drive; but would only run on +five percent of the roads. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 368259d1647cfe6551dc4a533cc8e89774c86176 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:45 +0200 Subject: [PATCH 0785/3340] - patchlevel 899 --- 7.3.899 | 67 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 7.3.899 diff --git a/7.3.899 b/7.3.899 new file mode 100644 index 00000000..46fceb79 --- /dev/null +++ b/7.3.899 @@ -0,0 +1,67 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.899 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.899 +Problem: #if indents are off. +Solution: Fix the indents. +Files: src/os_unix.c + + +*** ../vim-7.3.898/src/os_unix.c 2013-03-21 22:53:45.000000000 +0100 +--- src/os_unix.c 2013-04-15 15:28:01.000000000 +0200 +*************** +*** 3493,3505 **** + * 4 = Windows Cross Hair + * 5 = Windows UP Arrow + */ +! #ifdef JSBTERM_MOUSE_NONADVANCED /* Disables full feedback of pointer movements */ + out_str_nf((char_u *)IF_EB("\033[0~ZwLMRK1Q\033\\", + ESC_STR "[0~ZwLMRK1Q" ESC_STR "\\")); +! #else + out_str_nf((char_u *)IF_EB("\033[0~ZwLMRK+1Q\033\\", + ESC_STR "[0~ZwLMRK+1Q" ESC_STR "\\")); +! #endif + ison = TRUE; + } + else +--- 3493,3506 ---- + * 4 = Windows Cross Hair + * 5 = Windows UP Arrow + */ +! # ifdef JSBTERM_MOUSE_NONADVANCED +! /* Disables full feedback of pointer movements */ + out_str_nf((char_u *)IF_EB("\033[0~ZwLMRK1Q\033\\", + ESC_STR "[0~ZwLMRK1Q" ESC_STR "\\")); +! # else + out_str_nf((char_u *)IF_EB("\033[0~ZwLMRK+1Q\033\\", + ESC_STR "[0~ZwLMRK+1Q" ESC_STR "\\")); +! # endif + ison = TRUE; + } + else +*** ../vim-7.3.898/src/version.c 2013-04-15 15:15:31.000000000 +0200 +--- src/version.c 2013-04-15 15:31:43.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 899, + /**/ + +-- +If Microsoft would build a car... +... Occasionally, executing a maneuver such as a left turn +would cause your car to shut down and refuse to restart, in +which case you would have to reinstall the engine. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3a74ebae0207dd4c5065feb688978855d88fc462 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:46 +0200 Subject: [PATCH 0786/3340] - patchlevel 900 --- 7.3.900 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.900 diff --git a/7.3.900 b/7.3.900 new file mode 100644 index 00000000..e19e0f23 --- /dev/null +++ b/7.3.900 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.900 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.900 +Problem: Not obvious that some mouse features are mutual-exclusive. +Solution: Add a comment. +Files: src/feature.h + + +*** ../vim-7.3.899/src/feature.h 2013-02-26 14:56:24.000000000 +0100 +--- src/feature.h 2013-04-15 15:29:17.000000000 +0200 +*************** +*** 1088,1093 **** +--- 1088,1100 ---- + # endif + #endif + ++ /* ++ * Note: Only one of the following may be defined: ++ * FEAT_MOUSE_GPM ++ * FEAT_SYSMOUSE ++ * FEAT_MOUSE_JSB ++ * FEAT_MOUSE_PTERM ++ */ + #if defined(FEAT_NORMAL) && defined(HAVE_GPM) + # define FEAT_MOUSE_GPM + #endif +*** ../vim-7.3.899/src/version.c 2013-04-15 15:32:20.000000000 +0200 +--- src/version.c 2013-04-15 15:39:10.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 900, + /**/ + +-- +If Microsoft would build a car... +... Occasionally your car would die on the freeway for no +reason. You would have to pull over to the side of the road, +close all of the car windows, shut it off, restart it, and +reopen the windows before you could continue. For some reason +you would simply accept this. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 48b30d5d00c90ea5d0eb61d1248a92b786a7101c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:46 +0200 Subject: [PATCH 0787/3340] - patchlevel 901 --- 7.3.901 | 95 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 95 insertions(+) create mode 100644 7.3.901 diff --git a/7.3.901 b/7.3.901 new file mode 100644 index 00000000..b3ddf886 --- /dev/null +++ b/7.3.901 @@ -0,0 +1,95 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.901 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.901 +Problem: Outdated comment, ugly condition. +Solution: Update a few comments, break line. +Files: src/getchar.c, src/misc1.c, src/undo.c + + +*** ../vim-7.3.900/src/getchar.c 2013-03-16 21:42:12.000000000 +0100 +--- src/getchar.c 2013-04-12 15:01:39.000000000 +0200 +*************** +*** 444,450 **** + typebuf.tb_off = MAXMAPLEN; + typebuf.tb_len = 0; + } +! else /* remove mapped characters only */ + { + typebuf.tb_off += typebuf.tb_maplen; + typebuf.tb_len -= typebuf.tb_maplen; +--- 444,450 ---- + typebuf.tb_off = MAXMAPLEN; + typebuf.tb_len = 0; + } +! else /* remove mapped characters at the start only */ + { + typebuf.tb_off += typebuf.tb_maplen; + typebuf.tb_len -= typebuf.tb_maplen; +*** ../vim-7.3.900/src/misc1.c 2013-03-19 18:31:45.000000000 +0100 +--- src/misc1.c 2013-03-19 20:43:48.000000000 +0100 +*************** +*** 5054,5060 **** + int cx = NUL; + int cy = NUL; + +- /* TODO: multi-byte characters. */ + while (len > 0) + { + cx = PTR2CHAR(px); +--- 5054,5059 ---- +*** ../vim-7.3.900/src/undo.c 2012-08-23 12:58:56.000000000 +0200 +--- src/undo.c 2012-12-12 16:00:19.000000000 +0100 +*************** +*** 216,221 **** +--- 216,222 ---- + + /* + * Save the current line for both the "u" and "U" command. ++ * Careful: may trigger autocommands that reload the buffer. + * Returns OK or FAIL. + */ + int +*************** +*** 238,245 **** + if (undo_off) + return OK; + +! if (top > curbuf->b_ml.ml_line_count || +! top >= bot || bot > curbuf->b_ml.ml_line_count + 1) + return FALSE; /* rely on caller to do error messages */ + + if (top + 2 == bot) +--- 239,247 ---- + if (undo_off) + return OK; + +! if (top > curbuf->b_ml.ml_line_count +! || top >= bot +! || bot > curbuf->b_ml.ml_line_count + 1) + return FALSE; /* rely on caller to do error messages */ + + if (top + 2 == bot) +*** ../vim-7.3.900/src/version.c 2013-04-15 15:40:08.000000000 +0200 +--- src/version.c 2013-04-15 15:46:37.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 901, + /**/ + +-- +The CIA drives around in cars with the "Intel inside" logo. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8247408c843674fe3acd5dc871284dad3aca1cee Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:47 +0200 Subject: [PATCH 0788/3340] - patchlevel 902 --- 7.3.902 | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 7.3.902 diff --git a/7.3.902 b/7.3.902 new file mode 100644 index 00000000..4fd627ba --- /dev/null +++ b/7.3.902 @@ -0,0 +1,45 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.902 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.902 +Problem: When deleting last buffer in other tab the tabline is not updated. +Solution: Set the redraw_tabline flag. (Yukihiro Nakadaira) +Files: src/window.c + + +*** ../vim-7.3.901/src/window.c 2013-04-15 12:27:30.000000000 +0200 +--- src/window.c 2013-04-15 15:52:46.000000000 +0200 +*************** +*** 2070,2075 **** +--- 2070,2076 ---- + + --RedrawingDisabled; + ++ redraw_tabline = TRUE; + if (h != tabline_height()) + shell_new_rows(); + } +*** ../vim-7.3.901/src/version.c 2013-04-15 15:47:07.000000000 +0200 +--- src/version.c 2013-04-15 15:54:42.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 902, + /**/ + +-- +If Microsoft would build a car... +... The airbag system would ask "are you SURE?" before deploying. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 82f2388acc625ee1f66e6c41ad4989d967fece69 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:48 +0200 Subject: [PATCH 0789/3340] - patchlevel 903 --- 7.3.903 | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 7.3.903 diff --git a/7.3.903 b/7.3.903 new file mode 100644 index 00000000..42858619 --- /dev/null +++ b/7.3.903 @@ -0,0 +1,60 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.903 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.903 (after 7.3.892) +Problem: Crash on exit writing viminfo. (Ron Aaron) +Solution: Check for the history to be empty. +Files: src/ex_getln.c + + +*** ../vim-7.3.902/src/ex_getln.c 2013-04-14 23:19:32.000000000 +0200 +--- src/ex_getln.c 2013-04-15 16:13:56.000000000 +0200 +*************** +*** 6216,6222 **** + */ + for (round = 1; round <= 2; ++round) + { +! i = round == 1 ? hisidx[type] : 0; + if (i >= 0) + while (num_saved > 0 + && !(round == 2 && i >= viminfo_hisidx[type])) +--- 6216,6230 ---- + */ + for (round = 1; round <= 2; ++round) + { +! if (round == 1) +! /* start at newest entry, somewhere in the list */ +! i = hisidx[type]; +! else if (viminfo_hisidx[type] > 0) +! /* start at newest entry, first in the list */ +! i = 0; +! else +! /* empty list */ +! i = -1; + if (i >= 0) + while (num_saved > 0 + && !(round == 2 && i >= viminfo_hisidx[type])) +*** ../vim-7.3.902/src/version.c 2013-04-15 15:55:15.000000000 +0200 +--- src/version.c 2013-04-15 16:11:08.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 903, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +176. You lie, even to user-friends, about how long you were online yesterday. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 410624c31ae7b73a69b8f2c63c75676fb0b92265 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 15 Apr 2013 17:02:49 +0200 Subject: [PATCH 0790/3340] - patchlevel 903 --- README.patches | 81 ++++++++++++++++++++++++ vim.spec | 167 ++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 247 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index d50252b1..a82d9d62 100644 --- a/README.patches +++ b/README.patches @@ -854,3 +854,84 @@ Individual patches for Vim 7.3: 3295 7.3.820 errors when building with small features and Lua, Perl or Ruby 2199 7.3.821 build with OLE and Cygwin is broken 4013 7.3.822 (after 7.3.799) crash when accessing freed buffer + 2051 7.3.823 (after 7.3.821) building with Cygwin: '-lsupc++' is not needed + 1566 7.3.824 can redefine builtin functions + 4540 7.3.825 with Python errors are not always clear + 3807 7.3.826 list of features in :version output is hard to read + 3112 7.3.827 (after 7.3.825) Python tests fail + 4780 7.3.828 mappings are not aware of wildmenu mode + 2664 7.3.829 'showmatch' shows wrong match and may scroll the screen + 2841 7.3.830 :mksession confuses bytes and characters when placing cursor + 20653 7.3.831 clumsy to handle the situation that a variable does not exist + 1830 7.3.832 compiler warning + 2985 7.3.833 In the terminal scroll wheel always scrolls the active window + 2556 7.3.834 Ruby 2.0 has a few API changes + 1755 7.3.835 "xxd -i" fails on an empty file + 59985 7.3.836 clipboard does not work on Win32 when compiled with Cygwin + 2221 7.3.837 empty lines in :version output when 'columns' is 320 + 11082 7.3.838 (after 7.3.830) insufficient testing for mksession + 2012 7.3.839 some files missing in the list of distributed files + 1652 7.3.840 "\@ 1 line + 1630 7.3.854 after BS in insert mode completion current entry is wrong + 1831 7.3.855 compiler warnings + 8587 7.3.856 system() garbles multi-byte clipboard contents + 2763 7.3.857 QuitPre autocommand event does not trigger for :qa and :wq + 4120 7.3.858 "gv" selects the wrong area after some operators + 9955 7.3.859 'ambiwidth' must be set by the user + 2602 7.3.860 in --remote-expr try/catch does not work + 4494 7.3.861 ":setlocal number" clears global value of 'relativenumber' + 5831 7.3.862 dragging the status line can be slow + 3025 7.3.863 (after 7.3.859) 'ambiwidth' detection for ANSI terminal + 1516 7.3.864 (after 7.3.862) can't build without the mouse feature + 2015 7.3.865 (after 7.3.862) mouse position can be wrong + 4745 7.3.866 not serving the X selection during system() isn't nice + 9641 7.3.867 matchparen does not update match when using auto-indenting + 2567 7.3.868 empty line at hit-return prompt with few lines of text + 11112 7.3.869 bufwinnr() matches buffers in other tabs + 6562 7.3.870 compiler warnings when using MingW 4.5.3 + 2741 7.3.871 search('^$', 'c') does not use empty match under the cursor + 14914 7.3.872 on some systems file name case is always ignored + 5967 7.3.873 cannot easily use :s to make title case + 3480 7.3.874 comparing file names does not handle multi-byte chars properly + 1865 7.3.875 (after 7.3.866) build problem with a combination of features + 2182 7.3.876 #if indents are off + 3069 7.3.877 (after 7.3.871) forward searching with search() is broken + 3124 7.3.878 'fileignorecase' is missing in options window and quickref + 2792 7.3.879 aborting an ex command does not abort a pending operator + 7907 7.3.880 new viminfo history lines may be replacd with old lines + 2849 7.3.881 Python list does not work correctly + 1714 7.3.882 CursorHold may trigger after receiving the termresponse + 2350 7.3.883 (after 7.3.880) can't build with some combination of features + 2150 7.3.884 compiler warning for variable shadowing another + 2408 7.3.885 double free for list and dict in Lua + 2567 7.3.886 can't build with multi-byte on Solaris 10 + 9601 7.3.887 no tests for Visual mode operators, what 7.3.879 fixes + 3933 7.3.888 filename completion with 'fic' does not work for multi-byte + 2040 7.3.889 can't build with Ruby 2.0 on a 64 bit system + 1563 7.3.890 test 79 fails on Windows + 3761 7.3.891 merging viminfo history doesn't work well + 7984 7.3.892 (after 7.3.891) still merging problems for viminfo history + 19606 7.3.893 crash when using b:, w: or t: after closing the buffer etc. + 2219 7.3.894 using wrong RUBY_VER causing Ruby build to break + 5927 7.3.895 valgrind error in test 91 + 5208 7.3.896 memory leaks in Lua interface + 4487 7.3.897 configure doesn't always find the shared library + 7367 7.3.898 memory leak reported by valgrind in test 91 + 2116 7.3.899 #if indents are off + 1639 7.3.900 not obvious that some mouse features are mutual-exclusive + 2748 7.3.901 outdated comment, ugly condition + 1345 7.3.902 tabline not updated when deleting last buffer in other tab + 1827 7.3.903 (after 7.3.892) crash on exit writing viminfo diff --git a/vim.spec b/vim.spec index a29ca949..dcc04fbb 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 822 +%define patchlevel 903 Summary: The VIM editor URL: http://www.vim.org/ @@ -879,6 +879,87 @@ Patch819: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.819 Patch820: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.820 Patch821: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.821 Patch822: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.822 +Patch823: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.823 +Patch824: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.824 +Patch825: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.825 +Patch826: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.826 +Patch827: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.827 +Patch828: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.828 +Patch829: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.829 +Patch830: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.830 +Patch831: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.831 +Patch832: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.832 +Patch833: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.833 +Patch834: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.834 +Patch835: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.835 +Patch836: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.836 +Patch837: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.837 +Patch838: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.838 +Patch839: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.839 +Patch840: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.840 +Patch841: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.841 +Patch842: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.842 +Patch843: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.843 +Patch844: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.844 +Patch845: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.845 +Patch846: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.846 +Patch847: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.847 +Patch848: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.848 +Patch849: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.849 +Patch850: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.850 +Patch851: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.851 +Patch852: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.852 +Patch853: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.853 +Patch854: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.854 +Patch855: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.855 +Patch856: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.856 +Patch857: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.857 +Patch858: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.858 +Patch859: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.859 +Patch860: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.860 +Patch861: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.861 +Patch862: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.862 +Patch863: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.863 +Patch864: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.864 +Patch865: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.865 +Patch866: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.866 +Patch867: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.867 +Patch868: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.868 +Patch869: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.869 +Patch870: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.870 +Patch871: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.871 +Patch872: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.872 +Patch873: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.873 +Patch874: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.874 +Patch875: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.875 +Patch876: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.876 +Patch877: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.877 +Patch878: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.878 +Patch879: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.879 +Patch880: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.880 +Patch881: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.881 +Patch882: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.882 +Patch883: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.883 +Patch884: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.884 +Patch885: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.885 +Patch886: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.886 +Patch887: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.887 +Patch888: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.888 +Patch889: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.889 +Patch890: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.890 +Patch891: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.891 +Patch892: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.892 +Patch893: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.893 +Patch894: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.894 +Patch895: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.895 +Patch896: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.896 +Patch897: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.897 +Patch898: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.898 +Patch899: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.899 +Patch900: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.900 +Patch901: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.901 +Patch902: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.902 +Patch903: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.903 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -1847,6 +1928,87 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch820 -p0 %patch821 -p0 %patch822 -p0 +%patch823 -p0 +%patch824 -p0 +%patch825 -p0 +%patch826 -p0 +%patch827 -p0 +%patch828 -p0 +%patch829 -p0 +%patch830 -p0 +%patch831 -p0 +%patch832 -p0 +%patch833 -p0 +%patch834 -p0 +%patch835 -p0 +%patch836 -p0 +%patch837 -p0 +%patch838 -p0 +%patch839 -p0 +%patch840 -p0 +%patch841 -p0 +%patch842 -p0 +%patch843 -p0 +%patch844 -p0 +%patch845 -p0 +%patch846 -p0 +%patch847 -p0 +%patch848 -p0 +%patch849 -p0 +%patch850 -p0 +%patch851 -p0 +%patch852 -p0 +%patch853 -p0 +%patch854 -p0 +%patch855 -p0 +%patch856 -p0 +%patch857 -p0 +%patch858 -p0 +%patch859 -p0 +%patch860 -p0 +%patch861 -p0 +%patch862 -p0 +%patch863 -p0 +%patch864 -p0 +%patch865 -p0 +%patch866 -p0 +%patch867 -p0 +%patch868 -p0 +%patch869 -p0 +%patch870 -p0 +%patch871 -p0 +%patch872 -p0 +%patch873 -p0 +%patch874 -p0 +%patch875 -p0 +%patch876 -p0 +%patch877 -p0 +%patch878 -p0 +%patch879 -p0 +%patch880 -p0 +%patch881 -p0 +%patch882 -p0 +%patch883 -p0 +%patch884 -p0 +%patch885 -p0 +%patch886 -p0 +%patch887 -p0 +%patch888 -p0 +%patch889 -p0 +%patch890 -p0 +%patch891 -p0 +%patch892 -p0 +%patch893 -p0 +%patch894 -p0 +%patch895 -p0 +%patch896 -p0 +%patch897 -p0 +%patch898 -p0 +%patch899 -p0 +%patch900 -p0 +%patch901 -p0 +%patch902 -p0 +%patch903 -p0 # install spell files @@ -2322,6 +2484,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon Apr 15 2013 Karsten Hopp 7.3.903-1 +- patchlevel 903 + * Mon Feb 18 2013 Karsten Hopp 7.3.822-1 - patchlevel 822 From 931a877b9784e77c0a10b91bead69aba83397727 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 19 Apr 2013 13:13:36 +0200 Subject: [PATCH 0791/3340] upstream patch was broken, re-commit --- 7.3.838 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/7.3.838 b/7.3.838 index 02ad2ae2..7ecfc00c 100644 --- a/7.3.838 +++ b/7.3.838 @@ -207,9 +207,9 @@ Files: src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak, + four leadinG spaces + two consecutive tabs + two tabs in one line -+ one … multibyteCharacter -+ a “b†two multiByte characters -+ “câ€Â1€ three mulTibyte characters ++ one … multibyteCharacter ++ a “b†two multiByte characters ++ “câ€1€ three mulTibyte characters *** ../vim-7.3.837/src/testdir/test92.ok 2013-02-26 17:20:44.000000000 +0100 --- src/testdir/test92.ok 2013-02-26 17:13:48.000000000 +0100 *************** From 64f562360e1106bec413c7dead25355ed91f5d24 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 19 Apr 2013 13:35:16 +0200 Subject: [PATCH 0792/3340] drop crv patch update 7.3.838 patch, it was broken upstream --- vim-7.0-crv.patch | 10 ---------- vim.spec | 6 ++++-- 2 files changed, 4 insertions(+), 12 deletions(-) delete mode 100644 vim-7.0-crv.patch diff --git a/vim-7.0-crv.patch b/vim-7.0-crv.patch deleted file mode 100644 index 416c64ee..00000000 --- a/vim-7.0-crv.patch +++ /dev/null @@ -1,10 +0,0 @@ ---- vim70aa/src/term.c.orig 2006-03-14 15:40:15.000000000 +0100 -+++ vim70aa/src/term.c 2006-03-14 15:43:54.000000000 +0100 -@@ -1284,7 +1284,6 @@ - {(int)KS_CWS, "[%dCWS%d]"}, - {(int)KS_CWP, "[%dCWP%d]"}, - # endif -- {(int)KS_CRV, "[CRV]"}, - {K_UP, "[KU]"}, - {K_DOWN, "[KD]"}, - {K_LEFT, "[KL]"}, diff --git a/vim.spec b/vim.spec index dcc04fbb..2279e412 100644 --- a/vim.spec +++ b/vim.spec @@ -46,7 +46,6 @@ Source16: nl.po Patch2002: vim-7.0-fixkeys.patch Patch2003: vim-6.2-specsyntax.patch -Patch2004: vim-7.0-crv.patch %if %{withhunspell} Patch2011: vim-7.0-hunspell.patch BuildRequires: hunspell-devel @@ -1097,7 +1096,6 @@ vim-common package. chmod -x runtime/tools/mve.awk %patch2002 -p1 %patch2003 -p1 -%patch2004 -p1 %if %{withhunspell} %patch2011 -p1 %endif @@ -2484,6 +2482,10 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Fri Apr 19 2013 Karsten Hopp 7.3.903-1 +- drop crv patch +- update 7.3.838 patch, it was broken upstream + * Mon Apr 15 2013 Karsten Hopp 7.3.903-1 - patchlevel 903 From 19713298dbff96e7d5206e9de8dcd33501d8d1d3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 16:55:12 +0200 Subject: [PATCH 0793/3340] fix ruby version check --- vim-7.3-rubyversion.patch | 15 +++++++++++++++ vim.spec | 5 +++++ 2 files changed, 20 insertions(+) create mode 100644 vim-7.3-rubyversion.patch diff --git a/vim-7.3-rubyversion.patch b/vim-7.3-rubyversion.patch new file mode 100644 index 00000000..114b8a7c --- /dev/null +++ b/vim-7.3-rubyversion.patch @@ -0,0 +1,15 @@ +diff -up vim73/src/configure.in.rubyversion vim73/src/configure.in +--- vim73/src/configure.in.rubyversion 2013-05-08 16:21:11.067927960 +0200 ++++ vim73/src/configure.in 2013-05-08 16:31:05.854534820 +0200 +@@ -1490,7 +1490,10 @@ if test "$enable_rubyinterp" = "yes" -o + if test -d "$rubyhdrdir/$rubyarch"; then + RUBY_CFLAGS="$RUBY_CFLAGS -I$rubyhdrdir/$rubyarch" + fi +- rubyversion=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG[['ruby_version']].gsub(/\./, '')[[0,2]]"` ++ rubymajor=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG[['MAJOR']]"` ++ rubyminor=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG[['MINOR']]"` ++ rubyversion="$rubymajor$rubyminor" ++ # rubyversion=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG[['ruby_version']].gsub(/\./, '')[[0,2]]"` + RUBY_CFLAGS="$RUBY_CFLAGS -DRUBY_VERSION=$rubyversion" + rubylibs=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG[['LIBS']]"` + if test "X$rubylibs" != "X"; then diff --git a/vim.spec b/vim.spec index 2279e412..ecb493e0 100644 --- a/vim.spec +++ b/vim.spec @@ -971,6 +971,7 @@ Patch3010: vim-7.0-specedit.patch Patch3011: vim72-rh514717.patch Patch3012: vim-7.3-bug816848.patch Patch3013: vim-7.3-manpage-typo-668894-675480.patch +Patch3014: vim-7.3-rubyversion.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel ncurses-devel gettext perl-devel @@ -2025,6 +2026,7 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch3011 -p1 %patch3012 -p1 %patch3013 -p1 +%patch3014 -p1 %build cp -f %{SOURCE5} . @@ -2482,6 +2484,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Wed May 08 2013 Karsten Hopp 7.3.903-1 +- fix ruby version check + * Fri Apr 19 2013 Karsten Hopp 7.3.903-1 - drop crv patch - update 7.3.838 patch, it was broken upstream From 941e2a84b90ea95dcb3bc327e661831be331347d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:34 +0200 Subject: [PATCH 0794/3340] - patchlevel 904 --- 7.3.904 | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 7.3.904 diff --git a/7.3.904 b/7.3.904 new file mode 100644 index 00000000..a41b4699 --- /dev/null +++ b/7.3.904 @@ -0,0 +1,47 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.904 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.904 (after 7.3.893) +Problem: Using memory freed by the garbage collector. +Solution: Mark items in aucmd_win as used. +Files: src/eval.c + + +*** ../vim-7.3.903/src/eval.c 2013-04-15 15:15:31.000000000 +0200 +--- src/eval.c 2013-04-15 18:20:35.000000000 +0200 +*************** +*** 6792,6797 **** +--- 6792,6801 ---- + /* window-local variables */ + FOR_ALL_TAB_WINDOWS(tp, wp) + set_ref_in_item(&wp->w_winvar.di_tv, copyID); ++ #ifdef FEAT_AUTOCMD ++ if (aucmd_win != NULL) ++ set_ref_in_item(&aucmd_win->w_winvar.di_tv, copyID); ++ #endif + + #ifdef FEAT_WINDOWS + /* tabpage-local variables */ +*** ../vim-7.3.903/src/version.c 2013-04-15 16:14:15.000000000 +0200 +--- src/version.c 2013-04-15 18:21:49.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 904, + /**/ + +-- +Rule #1: Don't give somebody a tool that he's going to hurt himself with. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From cd294e6dd5d5d29fb72c2e13be5c87e332728302 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:35 +0200 Subject: [PATCH 0795/3340] - patchlevel 905 --- 7.3.905 | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 7.3.905 diff --git a/7.3.905 b/7.3.905 new file mode 100644 index 00000000..60ff5283 --- /dev/null +++ b/7.3.905 @@ -0,0 +1,45 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.905 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.905 (after 7.3.903) +Problem: Crash when writing viminfo. (Ron Aaron) +Solution: Prevent freed history info to be used. +Files: src/ex_getln.c + + +*** ../vim-7.3.904/src/ex_getln.c 2013-04-15 16:14:15.000000000 +0200 +--- src/ex_getln.c 2013-04-15 22:12:33.000000000 +0200 +*************** +*** 6264,6269 **** +--- 6264,6270 ---- + vim_free(viminfo_history[type][i]); + vim_free(viminfo_history[type]); + viminfo_history[type] = NULL; ++ viminfo_hisidx[type] = 0; + } + } + #endif /* FEAT_VIMINFO */ +*** ../vim-7.3.904/src/version.c 2013-04-15 18:25:55.000000000 +0200 +--- src/version.c 2013-04-15 22:19:03.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 905, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +180. You maintain more than six e-mail addresses. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5352e010270f03c380c87ad2edb7c8a80a3c3dc8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:36 +0200 Subject: [PATCH 0796/3340] - patchlevel 906 --- 7.3.906 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.906 diff --git a/7.3.906 b/7.3.906 new file mode 100644 index 00000000..84950319 --- /dev/null +++ b/7.3.906 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.906 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.906 +Problem: The "sleep .2" for running tests does not work on Solaris. +Solution: Fall back to using "sleep 1". (Laurent Blume) +Files: src/testdir/Makefile + + +*** ../vim-7.3.905/src/testdir/Makefile 2013-04-12 13:44:49.000000000 +0200 +--- src/testdir/Makefile 2013-04-21 13:06:20.000000000 +0200 +*************** +*** 69,76 **** + .in.out: + -rm -rf $*.failed test.ok $(RM_ON_RUN) + cp $*.ok test.ok +! # Sleep a moment to avoid that the xterm title is messed up +! @-sleep .2 + -$(RUN_VIM) $*.in + + # For flaky tests retry one time. +--- 69,78 ---- + .in.out: + -rm -rf $*.failed test.ok $(RM_ON_RUN) + cp $*.ok test.ok +! # Sleep a moment to avoid that the xterm title is messed up. +! # 200 msec is sufficient, but only modern sleep supports a fraction of +! # a second, fall back to a second if it fails. +! @-/bin/sh -c "sleep .2 > /dev/null 2>&1 || sleep 1" + -$(RUN_VIM) $*.in + + # For flaky tests retry one time. +*** ../vim-7.3.905/src/version.c 2013-04-15 22:22:48.000000000 +0200 +--- src/version.c 2013-04-24 12:54:57.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 906, + /**/ + +-- +Don't be humble ... you're not that great. + -- Golda Meir + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c3bbd5fac5ea358c503bb067cf79c3360c9a7367 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:37 +0200 Subject: [PATCH 0797/3340] - patchlevel 907 --- 7.3.907 | 162 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 162 insertions(+) create mode 100644 7.3.907 diff --git a/7.3.907 b/7.3.907 new file mode 100644 index 00000000..28d42347 --- /dev/null +++ b/7.3.907 @@ -0,0 +1,162 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.907 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.907 +Problem: Python uses IndexError when a dict key is not found. +Solution: Use KeyError instead. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c, + src/testdir/test86.ok, src/testdir/test87.ok + + +*** ../vim-7.3.906/src/if_py_both.h 2013-04-05 19:32:30.000000000 +0200 +--- src/if_py_both.h 2013-04-24 13:00:01.000000000 +0200 +*************** +*** 861,867 **** + + if (di == NULL) + { +! PyErr_SetString(PyExc_IndexError, _("no such key in dictionary")); + return NULL; + } + +--- 861,867 ---- + + if (di == NULL) + { +! PyErr_SetString(PyExc_KeyError, _("no such key in dictionary")); + return NULL; + } + +*** ../vim-7.3.906/src/if_python3.c 2013-02-20 16:09:35.000000000 +0100 +--- src/if_python3.c 2013-04-24 13:00:01.000000000 +0200 +*************** +*** 327,338 **** +--- 327,340 ---- + /* Imported exception objects */ + static PyObject *p3imp_PyExc_AttributeError; + static PyObject *p3imp_PyExc_IndexError; ++ static PyObject *p3imp_PyExc_KeyError; + static PyObject *p3imp_PyExc_KeyboardInterrupt; + static PyObject *p3imp_PyExc_TypeError; + static PyObject *p3imp_PyExc_ValueError; + + # define PyExc_AttributeError p3imp_PyExc_AttributeError + # define PyExc_IndexError p3imp_PyExc_IndexError ++ # define PyExc_KeyError p3imp_PyExc_KeyError + # define PyExc_KeyboardInterrupt p3imp_PyExc_KeyboardInterrupt + # define PyExc_TypeError p3imp_PyExc_TypeError + # define PyExc_ValueError p3imp_PyExc_ValueError +*************** +*** 567,577 **** +--- 569,581 ---- + PyObject *exdict = PyModule_GetDict(exmod); + p3imp_PyExc_AttributeError = PyDict_GetItemString(exdict, "AttributeError"); + p3imp_PyExc_IndexError = PyDict_GetItemString(exdict, "IndexError"); ++ p3imp_PyExc_KeyError = PyDict_GetItemString(exdict, "KeyError"); + p3imp_PyExc_KeyboardInterrupt = PyDict_GetItemString(exdict, "KeyboardInterrupt"); + p3imp_PyExc_TypeError = PyDict_GetItemString(exdict, "TypeError"); + p3imp_PyExc_ValueError = PyDict_GetItemString(exdict, "ValueError"); + Py_XINCREF(p3imp_PyExc_AttributeError); + Py_XINCREF(p3imp_PyExc_IndexError); ++ Py_XINCREF(p3imp_PyExc_KeyError); + Py_XINCREF(p3imp_PyExc_KeyboardInterrupt); + Py_XINCREF(p3imp_PyExc_TypeError); + Py_XINCREF(p3imp_PyExc_ValueError); +*** ../vim-7.3.906/src/if_python.c 2013-02-20 16:09:35.000000000 +0100 +--- src/if_python.c 2013-04-24 13:00:01.000000000 +0200 +*************** +*** 348,359 **** +--- 348,361 ---- + /* Imported exception objects */ + static PyObject *imp_PyExc_AttributeError; + static PyObject *imp_PyExc_IndexError; ++ static PyObject *imp_PyExc_KeyError; + static PyObject *imp_PyExc_KeyboardInterrupt; + static PyObject *imp_PyExc_TypeError; + static PyObject *imp_PyExc_ValueError; + + # define PyExc_AttributeError imp_PyExc_AttributeError + # define PyExc_IndexError imp_PyExc_IndexError ++ # define PyExc_KeyError imp_PyExc_KeyError + # define PyExc_KeyboardInterrupt imp_PyExc_KeyboardInterrupt + # define PyExc_TypeError imp_PyExc_TypeError + # define PyExc_ValueError imp_PyExc_ValueError +*************** +*** 579,589 **** +--- 581,593 ---- + PyObject *exdict = PyModule_GetDict(exmod); + imp_PyExc_AttributeError = PyDict_GetItemString(exdict, "AttributeError"); + imp_PyExc_IndexError = PyDict_GetItemString(exdict, "IndexError"); ++ imp_PyExc_KeyError = PyDict_GetItemString(exdict, "KeyError"); + imp_PyExc_KeyboardInterrupt = PyDict_GetItemString(exdict, "KeyboardInterrupt"); + imp_PyExc_TypeError = PyDict_GetItemString(exdict, "TypeError"); + imp_PyExc_ValueError = PyDict_GetItemString(exdict, "ValueError"); + Py_XINCREF(imp_PyExc_AttributeError); + Py_XINCREF(imp_PyExc_IndexError); ++ Py_XINCREF(imp_PyExc_KeyError); + Py_XINCREF(imp_PyExc_KeyboardInterrupt); + Py_XINCREF(imp_PyExc_TypeError); + Py_XINCREF(imp_PyExc_ValueError); +*** ../vim-7.3.906/src/testdir/test86.ok 2013-04-05 19:32:30.000000000 +0200 +--- src/testdir/test86.ok 2013-04-24 13:00:01.000000000 +0200 +*************** +*** 38,44 **** + Vim(python):E725: + Vim(python):E117: + [0.0, 0.0] +! IndexError + TypeError + TypeError + ValueError +--- 38,44 ---- + Vim(python):E725: + Vim(python):E117: + [0.0, 0.0] +! KeyError + TypeError + TypeError + ValueError +*** ../vim-7.3.906/src/testdir/test87.ok 2013-02-20 16:54:24.000000000 +0100 +--- src/testdir/test87.ok 2013-04-24 13:00:01.000000000 +0200 +*************** +*** 38,44 **** + Vim(py3):E725: + Vim(py3):E117: + [0.0, 0.0] +! IndexError + TypeError + TypeError + ValueError +--- 38,44 ---- + Vim(py3):E725: + Vim(py3):E117: + [0.0, 0.0] +! KeyError + TypeError + TypeError + ValueError +*** ../vim-7.3.906/src/version.c 2013-04-24 12:56:13.000000000 +0200 +--- src/version.c 2013-04-24 13:00:13.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 907, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +219. Your spouse has his or her lawyer deliver the divorce papers... + via e-mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6d927fab3270f7bab8a22752e2ff27fb30f2fce0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:38 +0200 Subject: [PATCH 0798/3340] - patchlevel 908 --- 7.3.908 | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 7.3.908 diff --git a/7.3.908 b/7.3.908 new file mode 100644 index 00000000..1b71dca1 --- /dev/null +++ b/7.3.908 @@ -0,0 +1,45 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.908 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.908 +Problem: Possible crash when using a list in Python. +Solution: Return early if the list is NULL. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.907/src/if_py_both.h 2013-04-24 13:04:21.000000000 +0200 +--- src/if_py_both.h 2013-04-24 13:10:20.000000000 +0200 +*************** +*** 738,743 **** +--- 738,745 ---- + tv->vval.v_dict = d; + + list = PyMapping_Items(obj); ++ if (list == NULL) ++ return -1; + lsize = PyList_Size(list); + while (lsize--) + { +*** ../vim-7.3.907/src/version.c 2013-04-24 13:04:21.000000000 +0200 +--- src/version.c 2013-04-24 13:09:30.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 908, + /**/ + +-- +How do I set the laser printer to stun? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 869996d5209160d6ab1e2e9c015d7861be863432 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:39 +0200 Subject: [PATCH 0799/3340] - patchlevel 909 --- 7.3.909 | 2129 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 2129 insertions(+) create mode 100644 7.3.909 diff --git a/7.3.909 b/7.3.909 new file mode 100644 index 00000000..1dbf4530 --- /dev/null +++ b/7.3.909 @@ -0,0 +1,2129 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.909 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.909 +Problem: Duplicate Python code. +Solution: Move more items to if_py_both.h. (ZyX) Also avoid compiler + warnings for missing initializers. +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c + + +*** ../vim-7.3.908/src/if_py_both.h 2013-04-24 13:10:35.000000000 +0200 +--- src/if_py_both.h 2013-04-24 13:26:54.000000000 +0200 +*************** +*** 542,547 **** +--- 542,555 ---- + * Buffer list object - Implementation + */ + ++ typedef struct ++ { ++ PyObject_HEAD ++ } BufListObject; ++ ++ static PyTypeObject BufListType; ++ static PySequenceMethods WinListAsSeq; ++ + static PyInt + BufListLength(PyObject *self UNUSED) + { +*************** +*** 578,583 **** +--- 586,596 ---- + win_T *win; + } WindowObject; + ++ static struct PyMethodDef WindowMethods[] = { ++ /* name, function, calling, documentation */ ++ { NULL, NULL, 0, NULL } ++ }; ++ + static int ConvertFromPyObject(PyObject *, typval_T *); + static int _ConvertFromPyObject(PyObject *, typval_T *, PyObject *); + +*************** +*** 642,647 **** +--- 655,670 ---- + pylinkedlist_T ref; + } DictionaryObject; + ++ static PyInt DictionaryAssItem(PyObject *, PyObject *, PyObject *); ++ static PyInt DictionaryLength(PyObject *); ++ static PyObject *DictionaryItem(PyObject *, PyObject *); ++ ++ static PyMappingMethods DictionaryAsMapping = { ++ (lenfunc) DictionaryLength, ++ (binaryfunc) DictionaryItem, ++ (objobjargproc) DictionaryAssItem, ++ }; ++ + static PyObject * + DictionaryNew(dict_T *dict) + { +*************** +*** 658,663 **** +--- 681,697 ---- + return (PyObject *)(self); + } + ++ static void ++ DictionaryDestructor(PyObject *self) ++ { ++ DictionaryObject *this = ((DictionaryObject *) (self)); ++ ++ pyll_remove(&this->ref, &lastdict); ++ dict_unref(this->dict); ++ ++ DESTRUCTOR_FINISH(self); ++ } ++ + static int + pydict_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) + { +*************** +*** 804,812 **** + return 0; + } + +! static PyInt +! DictionarySetattr(DictionaryObject *self, char *name, PyObject *val) + { + if (val == NULL) + { + PyErr_SetString(PyExc_AttributeError, _("Cannot delete DictionaryObject attributes")); +--- 838,848 ---- + return 0; + } + +! static int +! DictionarySetattr(PyObject *self, char *name, PyObject *val) + { ++ DictionaryObject *this = (DictionaryObject *)(self); ++ + if (val == NULL) + { + PyErr_SetString(PyExc_AttributeError, _("Cannot delete DictionaryObject attributes")); +*************** +*** 815,821 **** + + if (strcmp(name, "locked") == 0) + { +! if (self->dict->dv_lock == VAR_FIXED) + { + PyErr_SetString(PyExc_TypeError, _("Cannot modify fixed dictionary")); + return -1; +--- 851,857 ---- + + if (strcmp(name, "locked") == 0) + { +! if (this->dict->dv_lock == VAR_FIXED) + { + PyErr_SetString(PyExc_TypeError, _("Cannot modify fixed dictionary")); + return -1; +*************** +*** 829,837 **** + } + + if (val == Py_True) +! self->dict->dv_lock = VAR_LOCKED; + else +! self->dict->dv_lock = 0; + } + return 0; + } +--- 865,873 ---- + } + + if (val == Py_True) +! this->dict->dv_lock = VAR_LOCKED; + else +! this->dict->dv_lock = 0; + } + return 0; + } +*************** +*** 963,968 **** +--- 999,1006 ---- + }; + + static PyTypeObject ListType; ++ static PySequenceMethods ListAsSeq; ++ static PyMappingMethods ListAsMapping; + + typedef struct + { +*************** +*** 987,992 **** +--- 1025,1041 ---- + return (PyObject *)(self); + } + ++ static void ++ ListDestructor(PyObject *self) ++ { ++ ListObject *this = (ListObject *)(self); ++ ++ pyll_remove(&this->ref, &lastlist); ++ list_unref(this->list); ++ ++ DESTRUCTOR_FINISH(self); ++ } ++ + static int + list_py_concat(list_T *l, PyObject *obj, PyObject *lookupDict) + { +*************** +*** 1307,1314 **** + } + + static int +! ListSetattr(ListObject *self, char *name, PyObject *val) + { + if (val == NULL) + { + PyErr_SetString(PyExc_AttributeError, _("Cannot delete DictionaryObject attributes")); +--- 1356,1365 ---- + } + + static int +! ListSetattr(PyObject *self, char *name, PyObject *val) + { ++ ListObject *this = (ListObject *)(self); ++ + if (val == NULL) + { + PyErr_SetString(PyExc_AttributeError, _("Cannot delete DictionaryObject attributes")); +*************** +*** 1317,1323 **** + + if (strcmp(name, "locked") == 0) + { +! if (self->list->lv_lock == VAR_FIXED) + { + PyErr_SetString(PyExc_TypeError, _("Cannot modify fixed list")); + return -1; +--- 1368,1374 ---- + + if (strcmp(name, "locked") == 0) + { +! if (this->list->lv_lock == VAR_FIXED) + { + PyErr_SetString(PyExc_TypeError, _("Cannot modify fixed list")); + return -1; +*************** +*** 1331,1339 **** + } + + if (val == Py_True) +! self->list->lv_lock = VAR_LOCKED; + else +! self->list->lv_lock = 0; + } + return 0; + } +--- 1382,1390 ---- + } + + if (val == Py_True) +! this->list->lv_lock = VAR_LOCKED; + else +! this->list->lv_lock = 0; + } + return 0; + } +*************** +*** 1376,1381 **** +--- 1427,1443 ---- + return (PyObject *)(self); + } + ++ static void ++ FunctionDestructor(PyObject *self) ++ { ++ FunctionObject *this = (FunctionObject *) (self); ++ ++ func_unref(this->name); ++ PyMem_Del(this->name); ++ ++ DESTRUCTOR_FINISH(self); ++ } ++ + static PyObject * + FunctionCall(PyObject *self, PyObject *argsObject, PyObject *kwargs) + { +*************** +*** 1451,1456 **** +--- 1513,1557 ---- + + static int WindowSetattr(PyObject *, char *, PyObject *); + static PyObject *WindowRepr(PyObject *); ++ static PyTypeObject WindowType; ++ ++ static PyObject * ++ WindowAttr(WindowObject *this, char *name) ++ { ++ if (strcmp(name, "buffer") == 0) ++ return (PyObject *)BufferNew(this->win->w_buffer); ++ else if (strcmp(name, "cursor") == 0) ++ { ++ pos_T *pos = &this->win->w_cursor; ++ ++ return Py_BuildValue("(ll)", (long)(pos->lnum), (long)(pos->col)); ++ } ++ else if (strcmp(name, "height") == 0) ++ return Py_BuildValue("l", (long)(this->win->w_height)); ++ #ifdef FEAT_VERTSPLIT ++ else if (strcmp(name, "width") == 0) ++ return Py_BuildValue("l", (long)(W_WIDTH(this->win))); ++ #endif ++ else if (strcmp(name,"__members__") == 0) ++ return Py_BuildValue("[sss]", "buffer", "cursor", "height"); ++ else ++ return NULL; ++ } ++ ++ static void ++ WindowDestructor(PyObject *self) ++ { ++ WindowObject *this = (WindowObject *)(self); ++ ++ if (this->win && this->win != INVALID_WINDOW_VALUE) ++ #if PY_MAJOR_VERSION >= 3 ++ this->win->w_python3_ref = NULL; ++ #else ++ this->win->w_python_ref = NULL; ++ #endif ++ ++ DESTRUCTOR_FINISH(self); ++ } + + static int + WindowSetattr(PyObject *self, char *name, PyObject *val) +*************** +*** 1579,1584 **** +--- 1680,1694 ---- + /* + * Window list object - Implementation + */ ++ ++ typedef struct ++ { ++ PyObject_HEAD ++ } WinListObject; ++ ++ static PyTypeObject WinListType; ++ static PySequenceMethods BufListAsSeq; ++ + static PyInt + WinListLength(PyObject *self UNUSED) + { +*************** +*** 2310,2319 **** + return Py_None; + } + +! +! /* Buffer object - Definitions + */ + + typedef struct + { + PyObject_HEAD +--- 2420,2430 ---- + return Py_None; + } + +! /* Range object - Definitions + */ + ++ static PyTypeObject RangeType; ++ + typedef struct + { + PyObject_HEAD +*************** +*** 2322,2327 **** +--- 2433,2442 ---- + PyInt end; + } RangeObject; + ++ static void RangeDestructor(PyObject *); ++ static PySequenceMethods RangeAsSeq; ++ static PyMappingMethods RangeAsMapping; ++ + static PyObject * + RangeNew(buf_T *buf, PyInt start, PyInt end) + { +*************** +*** 2346,2351 **** +--- 2461,2506 ---- + return (PyObject *)(self); + } + ++ static void ++ RangeDestructor(PyObject *self) ++ { ++ Py_DECREF(((RangeObject *)(self))->buf); ++ DESTRUCTOR_FINISH(self); ++ } ++ ++ static PyTypeObject BufferType; ++ static PyObject *BufferRepr(PyObject *); ++ static PySequenceMethods BufferAsSeq; ++ static PyMappingMethods BufferAsMapping; ++ ++ static void ++ BufferDestructor(PyObject *self) ++ { ++ BufferObject *this = (BufferObject *)(self); ++ ++ if (this->buf && this->buf != INVALID_BUFFER_VALUE) ++ #if PY_MAJOR_VERSION >= 3 ++ this->buf->b_python3_ref = NULL; ++ #else ++ this->buf->b_python_ref = NULL; ++ #endif ++ ++ DESTRUCTOR_FINISH(self); ++ } ++ ++ static PyObject * ++ BufferAttr(BufferObject *this, char *name) ++ { ++ if (strcmp(name, "name") == 0) ++ return Py_BuildValue("s", this->buf->b_ffname); ++ else if (strcmp(name, "number") == 0) ++ return Py_BuildValue(Py_ssize_t_fmt, this->buf->b_fnum); ++ else if (strcmp(name,"__members__") == 0) ++ return Py_BuildValue("[ss]", "name", "number"); ++ else ++ return NULL; ++ } ++ + static PyObject * + BufferAppend(PyObject *self, PyObject *args) + { +*************** +*** 2409,2414 **** +--- 2564,2598 ---- + return RangeNew(((BufferObject *)(self))->buf, start, end); + } + ++ static PyObject * ++ BufferRepr(PyObject *self) ++ { ++ static char repr[100]; ++ BufferObject *this = (BufferObject *)(self); ++ ++ if (this->buf == INVALID_BUFFER_VALUE) ++ { ++ vim_snprintf(repr, 100, _(""), (self)); ++ return PyString_FromString(repr); ++ } ++ else ++ { ++ char *name = (char *)this->buf->b_fname; ++ PyInt len; ++ ++ if (name == NULL) ++ name = ""; ++ len = strlen(name); ++ ++ if (len > 35) ++ name = name + (35 - len); ++ ++ vim_snprintf(repr, 100, "", len > 35 ? "..." : "", name); ++ ++ return PyString_FromString(repr); ++ } ++ } ++ + static struct PyMethodDef BufferMethods[] = { + /* name, function, calling, documentation */ + {"append", BufferAppend, 1, "Append data to Vim buffer" }, +*************** +*** 2497,2502 **** +--- 2681,2729 ---- + { NULL, NULL, 0, NULL } + }; + ++ /* Current items object - Implementation ++ */ ++ ++ static PyInt RangeStart; ++ static PyInt RangeEnd; ++ ++ static PyObject * ++ CurrentGetattr(PyObject *self UNUSED, char *name) ++ { ++ if (strcmp(name, "buffer") == 0) ++ return (PyObject *)BufferNew(curbuf); ++ else if (strcmp(name, "window") == 0) ++ return (PyObject *)WindowNew(curwin); ++ else if (strcmp(name, "line") == 0) ++ return GetBufferLine(curbuf, (PyInt)curwin->w_cursor.lnum); ++ else if (strcmp(name, "range") == 0) ++ return RangeNew(curbuf, RangeStart, RangeEnd); ++ else if (strcmp(name,"__members__") == 0) ++ return Py_BuildValue("[ssss]", "buffer", "window", "line", "range"); ++ else ++ { ++ PyErr_SetString(PyExc_AttributeError, name); ++ return NULL; ++ } ++ } ++ ++ static int ++ CurrentSetattr(PyObject *self UNUSED, char *name, PyObject *value) ++ { ++ if (strcmp(name, "line") == 0) ++ { ++ if (SetBufferLine(curbuf, (PyInt)curwin->w_cursor.lnum, value, NULL) == FAIL) ++ return -1; ++ ++ return 0; ++ } ++ else ++ { ++ PyErr_SetString(PyExc_AttributeError, name); ++ return -1; ++ } ++ } ++ + static void + set_ref_in_py(const int copyID) + { +*************** +*** 2770,2772 **** +--- 2997,3165 ---- + return NULL; + } + } ++ ++ typedef struct ++ { ++ PyObject_HEAD ++ } CurrentObject; ++ static PyTypeObject CurrentType; ++ ++ static void ++ init_structs(void) ++ { ++ vim_memset(&OutputType, 0, sizeof(OutputType)); ++ OutputType.tp_name = "vim.message"; ++ OutputType.tp_basicsize = sizeof(OutputObject); ++ OutputType.tp_flags = Py_TPFLAGS_DEFAULT; ++ OutputType.tp_doc = "vim message object"; ++ OutputType.tp_methods = OutputMethods; ++ #if PY_MAJOR_VERSION >= 3 ++ OutputType.tp_getattro = OutputGetattro; ++ OutputType.tp_setattro = OutputSetattro; ++ OutputType.tp_alloc = call_PyType_GenericAlloc; ++ OutputType.tp_new = call_PyType_GenericNew; ++ OutputType.tp_free = call_PyObject_Free; ++ #else ++ OutputType.tp_getattr = OutputGetattr; ++ OutputType.tp_setattr = OutputSetattr; ++ #endif ++ ++ vim_memset(&BufferType, 0, sizeof(BufferType)); ++ BufferType.tp_name = "vim.buffer"; ++ BufferType.tp_basicsize = sizeof(BufferType); ++ BufferType.tp_dealloc = BufferDestructor; ++ BufferType.tp_repr = BufferRepr; ++ BufferType.tp_as_sequence = &BufferAsSeq; ++ BufferType.tp_as_mapping = &BufferAsMapping; ++ BufferType.tp_flags = Py_TPFLAGS_DEFAULT; ++ BufferType.tp_doc = "vim buffer object"; ++ BufferType.tp_methods = BufferMethods; ++ #if PY_MAJOR_VERSION >= 3 ++ BufferType.tp_getattro = BufferGetattro; ++ BufferType.tp_alloc = call_PyType_GenericAlloc; ++ BufferType.tp_new = call_PyType_GenericNew; ++ BufferType.tp_free = call_PyObject_Free; ++ #else ++ BufferType.tp_getattr = BufferGetattr; ++ #endif ++ ++ vim_memset(&WindowType, 0, sizeof(WindowType)); ++ WindowType.tp_name = "vim.window"; ++ WindowType.tp_basicsize = sizeof(WindowObject); ++ WindowType.tp_dealloc = WindowDestructor; ++ WindowType.tp_repr = WindowRepr; ++ WindowType.tp_flags = Py_TPFLAGS_DEFAULT; ++ WindowType.tp_doc = "vim Window object"; ++ WindowType.tp_methods = WindowMethods; ++ #if PY_MAJOR_VERSION >= 3 ++ WindowType.tp_getattro = WindowGetattro; ++ WindowType.tp_setattro = WindowSetattro; ++ WindowType.tp_alloc = call_PyType_GenericAlloc; ++ WindowType.tp_new = call_PyType_GenericNew; ++ WindowType.tp_free = call_PyObject_Free; ++ #else ++ WindowType.tp_getattr = WindowGetattr; ++ WindowType.tp_setattr = WindowSetattr; ++ #endif ++ ++ vim_memset(&BufListType, 0, sizeof(BufListType)); ++ BufListType.tp_name = "vim.bufferlist"; ++ BufListType.tp_basicsize = sizeof(BufListObject); ++ BufListType.tp_as_sequence = &BufListAsSeq; ++ BufListType.tp_flags = Py_TPFLAGS_DEFAULT; ++ BufferType.tp_doc = "vim buffer list"; ++ ++ vim_memset(&WinListType, 0, sizeof(WinListType)); ++ WinListType.tp_name = "vim.windowlist"; ++ WinListType.tp_basicsize = sizeof(WinListType); ++ WinListType.tp_as_sequence = &WinListAsSeq; ++ WinListType.tp_flags = Py_TPFLAGS_DEFAULT; ++ WinListType.tp_doc = "vim window list"; ++ ++ vim_memset(&RangeType, 0, sizeof(RangeType)); ++ RangeType.tp_name = "vim.range"; ++ RangeType.tp_basicsize = sizeof(RangeObject); ++ RangeType.tp_dealloc = RangeDestructor; ++ RangeType.tp_repr = RangeRepr; ++ RangeType.tp_as_sequence = &RangeAsSeq; ++ RangeType.tp_as_mapping = &RangeAsMapping; ++ RangeType.tp_flags = Py_TPFLAGS_DEFAULT; ++ RangeType.tp_doc = "vim Range object"; ++ RangeType.tp_methods = RangeMethods; ++ #if PY_MAJOR_VERSION >= 3 ++ RangeType.tp_getattro = RangeGetattro; ++ RangeType.tp_alloc = call_PyType_GenericAlloc; ++ RangeType.tp_new = call_PyType_GenericNew; ++ RangeType.tp_free = call_PyObject_Free; ++ #else ++ RangeType.tp_getattr = RangeGetattr; ++ #endif ++ ++ vim_memset(&CurrentType, 0, sizeof(CurrentType)); ++ CurrentType.tp_name = "vim.currentdata"; ++ CurrentType.tp_basicsize = sizeof(CurrentObject); ++ CurrentType.tp_flags = Py_TPFLAGS_DEFAULT; ++ CurrentType.tp_doc = "vim current object"; ++ #if PY_MAJOR_VERSION >= 3 ++ CurrentType.tp_getattro = CurrentGetattro; ++ CurrentType.tp_setattro = CurrentSetattro; ++ #else ++ CurrentType.tp_getattr = CurrentGetattr; ++ CurrentType.tp_setattr = CurrentSetattr; ++ #endif ++ ++ vim_memset(&DictionaryType, 0, sizeof(DictionaryType)); ++ DictionaryType.tp_name = "vim.dictionary"; ++ DictionaryType.tp_basicsize = sizeof(DictionaryObject); ++ DictionaryType.tp_dealloc = DictionaryDestructor; ++ DictionaryType.tp_as_mapping = &DictionaryAsMapping; ++ DictionaryType.tp_flags = Py_TPFLAGS_DEFAULT; ++ DictionaryType.tp_doc = "dictionary pushing modifications to vim structure"; ++ DictionaryType.tp_methods = DictionaryMethods; ++ #if PY_MAJOR_VERSION >= 3 ++ DictionaryType.tp_getattro = DictionaryGetattro; ++ DictionaryType.tp_setattro = DictionarySetattro; ++ #else ++ DictionaryType.tp_getattr = DictionaryGetattr; ++ DictionaryType.tp_setattr = DictionarySetattr; ++ #endif ++ ++ vim_memset(&ListType, 0, sizeof(ListType)); ++ ListType.tp_name = "vim.list"; ++ ListType.tp_dealloc = ListDestructor; ++ ListType.tp_basicsize = sizeof(ListObject); ++ ListType.tp_as_sequence = &ListAsSeq; ++ ListType.tp_as_mapping = &ListAsMapping; ++ ListType.tp_flags = Py_TPFLAGS_DEFAULT; ++ ListType.tp_doc = "list pushing modifications to vim structure"; ++ ListType.tp_methods = ListMethods; ++ #if PY_MAJOR_VERSION >= 3 ++ ListType.tp_getattro = ListGetattro; ++ ListType.tp_setattro = ListSetattro; ++ #else ++ ListType.tp_getattr = ListGetattr; ++ ListType.tp_setattr = ListSetattr; ++ #endif ++ ++ vim_memset(&FunctionType, 0, sizeof(FunctionType)); ++ FunctionType.tp_name = "vim.list"; ++ FunctionType.tp_basicsize = sizeof(FunctionObject); ++ FunctionType.tp_dealloc = FunctionDestructor; ++ FunctionType.tp_call = FunctionCall; ++ FunctionType.tp_flags = Py_TPFLAGS_DEFAULT; ++ FunctionType.tp_doc = "object that calls vim function"; ++ FunctionType.tp_methods = FunctionMethods; ++ #if PY_MAJOR_VERSION >= 3 ++ FunctionType.tp_getattro = FunctionGetattro; ++ #else ++ FunctionType.tp_getattr = FunctionGetattr; ++ #endif ++ ++ #if PY_MAJOR_VERSION >= 3 ++ vim_memset(&vimmodule, 0, sizeof(vimmodule)); ++ vimmodule.m_name = "vim"; ++ vimmodule.m_doc = "Vim Python interface\n"; ++ vimmodule.m_size = -1; ++ vimmodule.m_methods = VimMethods; ++ #endif ++ } +*** ../vim-7.3.908/src/if_python3.c 2013-04-24 13:04:21.000000000 +0200 +--- src/if_python3.c 2013-04-24 13:26:54.000000000 +0200 +*************** +*** 91,96 **** +--- 91,97 ---- + #define PyInt_Check(obj) PyLong_Check(obj) + #define PyInt_FromLong(i) PyLong_FromLong(i) + #define PyInt_AsLong(obj) PyLong_AsLong(obj) ++ #define Py_ssize_t_fmt "n" + + #if defined(DYNAMIC_PYTHON3) || defined(PROTO) + +*************** +*** 588,595 **** + static PyObject *LineToString(const char *); + static PyObject *BufferDir(PyObject *, PyObject *); + +- static PyTypeObject RangeType; +- + static int py3initialised = 0; + + #define PYINITIALISED py3initialised +--- 589,594 ---- +*************** +*** 620,636 **** + if (bytes != NULL) \ + Py_XDECREF(bytes); + +! /* +! * Include the code shared with if_python.c +! */ +! #include "if_py_both.h" +! +! #define GET_ATTR_STRING(name, nameobj) \ +! char *name = ""; \ +! if (PyUnicode_Check(nameobj)) \ +! name = _PyUnicode_AsString(nameobj) +! +! #define PY3OBJ_DELETED(obj) (obj->ob_base.ob_refcnt<=0) + + static void + call_PyObject_Free(void *p) +--- 619,625 ---- + if (bytes != NULL) \ + Py_XDECREF(bytes); + +! #define DESTRUCTOR_FINISH(self) Py_TYPE(self)->tp_free((PyObject*)self); + + static void + call_PyObject_Free(void *p) +*************** +*** 654,666 **** + return PyType_GenericAlloc(type,nitems); + } + + /****************************************************** + * Internal function prototypes. + */ + +- static Py_ssize_t RangeStart; +- static Py_ssize_t RangeEnd; +- + static PyObject *globals; + + static int PythonIO_Init(void); +--- 643,680 ---- + return PyType_GenericAlloc(type,nitems); + } + ++ static PyObject *OutputGetattro(PyObject *, PyObject *); ++ static int OutputSetattro(PyObject *, PyObject *, PyObject *); ++ static PyObject *BufferGetattro(PyObject *, PyObject *); ++ static PyObject *WindowGetattro(PyObject *, PyObject *); ++ static int WindowSetattro(PyObject *, PyObject *, PyObject *); ++ static PyObject *RangeGetattro(PyObject *, PyObject *); ++ static PyObject *CurrentGetattro(PyObject *, PyObject *); ++ static int CurrentSetattro(PyObject *, PyObject *, PyObject *); ++ static PyObject *DictionaryGetattro(PyObject *, PyObject *); ++ static int DictionarySetattro(PyObject *, PyObject *, PyObject *); ++ static PyObject *ListGetattro(PyObject *, PyObject *); ++ static int ListSetattro(PyObject *, PyObject *, PyObject *); ++ static PyObject *FunctionGetattro(PyObject *, PyObject *); ++ ++ static struct PyModuleDef vimmodule; ++ ++ /* ++ * Include the code shared with if_python.c ++ */ ++ #include "if_py_both.h" ++ ++ #define GET_ATTR_STRING(name, nameobj) \ ++ char *name = ""; \ ++ if (PyUnicode_Check(nameobj)) \ ++ name = _PyUnicode_AsString(nameobj) ++ ++ #define PY3OBJ_DELETED(obj) (obj->ob_base.ob_refcnt<=0) ++ + /****************************************************** + * Internal function prototypes. + */ + + static PyObject *globals; + + static int PythonIO_Init(void); +*************** +*** 1046,1052 **** + 0, /* sq_inplace_repeat */ + }; + +! PyMappingMethods BufferAsMapping = { + /* mp_length */ (lenfunc)BufferLength, + /* mp_subscript */ (binaryfunc)BufferSubscript, + /* mp_ass_subscript */ (objobjargproc)BufferAsSubscript, +--- 1060,1066 ---- + 0, /* sq_inplace_repeat */ + }; + +! static PyMappingMethods BufferAsMapping = { + /* mp_length */ (lenfunc)BufferLength, + /* mp_subscript */ (binaryfunc)BufferSubscript, + /* mp_ass_subscript */ (objobjargproc)BufferAsSubscript, +*************** +*** 1056,1063 **** + /* Buffer object - Definitions + */ + +- static PyTypeObject BufferType; +- + static PyObject * + BufferNew(buf_T *buf) + { +--- 1070,1075 ---- +*************** +*** 1094,1124 **** + return (PyObject *)(self); + } + +- static void +- BufferDestructor(PyObject *self) +- { +- BufferObject *this = (BufferObject *)(self); +- +- if (this->buf && this->buf != INVALID_BUFFER_VALUE) +- this->buf->b_python3_ref = NULL; +- +- Py_TYPE(self)->tp_free((PyObject*)self); +- } +- + static PyObject * + BufferGetattro(PyObject *self, PyObject*nameobj) + { +! BufferObject *this = (BufferObject *)(self); + + GET_ATTR_STRING(name, nameobj); + +! if (CheckBuffer(this)) + return NULL; + +! if (strcmp(name, "name") == 0) +! return Py_BuildValue("s", this->buf->b_ffname); +! else if (strcmp(name, "number") == 0) +! return Py_BuildValue("n", this->buf->b_fnum); + else + return PyObject_GenericGetAttr(self, nameobj); + } +--- 1106,1124 ---- + return (PyObject *)(self); + } + + static PyObject * + BufferGetattro(PyObject *self, PyObject*nameobj) + { +! PyObject *r; + + GET_ATTR_STRING(name, nameobj); + +! if (CheckBuffer((BufferObject *)(self))) + return NULL; + +! r = BufferAttr((BufferObject *)(self), name); +! if (r || PyErr_Occurred()) +! return r; + else + return PyObject_GenericGetAttr(self, nameobj); + } +*************** +*** 1130,1164 **** + "append", "mark", "range"); + } + +- static PyObject * +- BufferRepr(PyObject *self) +- { +- static char repr[100]; +- BufferObject *this = (BufferObject *)(self); +- +- if (this->buf == INVALID_BUFFER_VALUE) +- { +- vim_snprintf(repr, 100, _(""), (self)); +- return PyUnicode_FromString(repr); +- } +- else +- { +- char *name = (char *)this->buf->b_fname; +- Py_ssize_t len; +- +- if (name == NULL) +- name = ""; +- len = strlen(name); +- +- if (len > 35) +- name = name + (35 - len); +- +- vim_snprintf(repr, 100, "", len > 35 ? "..." : "", name); +- +- return PyUnicode_FromString(repr); +- } +- } +- + /******************/ + + static Py_ssize_t +--- 1130,1135 ---- +*************** +*** 1255,1261 **** + 0, /* sq_inplace_repeat */ + }; + +! PyMappingMethods RangeAsMapping = { + /* mp_length */ (lenfunc)RangeLength, + /* mp_subscript */ (binaryfunc)RangeSubscript, + /* mp_ass_subscript */ (objobjargproc)RangeAsSubscript, +--- 1226,1232 ---- + 0, /* sq_inplace_repeat */ + }; + +! static PyMappingMethods RangeAsMapping = { + /* mp_length */ (lenfunc)RangeLength, + /* mp_subscript */ (binaryfunc)RangeSubscript, + /* mp_ass_subscript */ (objobjargproc)RangeAsSubscript, +*************** +*** 1264,1276 **** + /* Line range object - Implementation + */ + +- static void +- RangeDestructor(PyObject *self) +- { +- Py_DECREF(((RangeObject *)(self))->buf); +- Py_TYPE(self)->tp_free((PyObject*)self); +- } +- + static PyObject * + RangeGetattro(PyObject *self, PyObject *nameobj) + { +--- 1235,1240 ---- +*************** +*** 1358,1372 **** + } + } + +- + /* Buffer list object - Definitions + */ + +- typedef struct +- { +- PyObject_HEAD +- } BufListObject; +- + static PySequenceMethods BufListAsSeq = { + (lenfunc) BufListLength, /* sq_length, len(x) */ + (binaryfunc) 0, /* sq_concat, x+y */ +--- 1322,1330 ---- +*************** +*** 1380,1397 **** + 0, /* sq_inplace_repeat */ + }; + +- static PyTypeObject BufListType; +- +- /* Window object - Definitions +- */ +- +- static struct PyMethodDef WindowMethods[] = { +- /* name, function, calling, documentation */ +- { NULL, NULL, 0, NULL } +- }; +- +- static PyTypeObject WindowType; +- + /* Window object - Implementation + */ + +--- 1338,1343 ---- +*************** +*** 1429,1471 **** + return (PyObject *)(self); + } + +- static void +- WindowDestructor(PyObject *self) +- { +- WindowObject *this = (WindowObject *)(self); +- +- if (this->win && this->win != INVALID_WINDOW_VALUE) +- this->win->w_python3_ref = NULL; +- +- Py_TYPE(self)->tp_free((PyObject*)self); +- } +- + static PyObject * + WindowGetattro(PyObject *self, PyObject *nameobj) + { +! WindowObject *this = (WindowObject *)(self); + + GET_ATTR_STRING(name, nameobj); + +! if (CheckWindow(this)) + return NULL; + +! if (strcmp(name, "buffer") == 0) +! return (PyObject *)BufferNew(this->win->w_buffer); +! else if (strcmp(name, "cursor") == 0) +! { +! pos_T *pos = &this->win->w_cursor; +! +! return Py_BuildValue("(ll)", (long)(pos->lnum), (long)(pos->col)); +! } +! else if (strcmp(name, "height") == 0) +! return Py_BuildValue("l", (long)(this->win->w_height)); +! #ifdef FEAT_VERTSPLIT +! else if (strcmp(name, "width") == 0) +! return Py_BuildValue("l", (long)(W_WIDTH(this->win))); +! #endif +! else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[sss]", "buffer", "cursor", "height"); + else + return PyObject_GenericGetAttr(self, nameobj); + } +--- 1375,1393 ---- + return (PyObject *)(self); + } + + static PyObject * + WindowGetattro(PyObject *self, PyObject *nameobj) + { +! PyObject *r; + + GET_ATTR_STRING(name, nameobj); + +! if (CheckWindow((WindowObject *)(self))) + return NULL; + +! r = WindowAttr((WindowObject *)(self), name); +! if (r || PyErr_Occurred()) +! return r; + else + return PyObject_GenericGetAttr(self, nameobj); + } +*************** +*** 1481,1492 **** + /* Window list object - Definitions + */ + +- typedef struct +- { +- PyObject_HEAD +- } +- WinListObject; +- + static PySequenceMethods WinListAsSeq = { + (lenfunc) WinListLength, /* sq_length, len(x) */ + (binaryfunc) 0, /* sq_concat, x+y */ +--- 1403,1408 ---- +*************** +*** 1500,1560 **** + 0, /* sq_inplace_repeat */ + }; + +- static PyTypeObject WinListType; +- +- /* Current items object - Definitions +- */ +- +- typedef struct +- { +- PyObject_HEAD +- } CurrentObject; +- +- static PyTypeObject CurrentType; +- + /* Current items object - Implementation + */ + static PyObject * +! CurrentGetattro(PyObject *self UNUSED, PyObject *nameobj) + { + GET_ATTR_STRING(name, nameobj); +! +! if (strcmp(name, "buffer") == 0) +! return (PyObject *)BufferNew(curbuf); +! else if (strcmp(name, "window") == 0) +! return (PyObject *)WindowNew(curwin); +! else if (strcmp(name, "line") == 0) +! return GetBufferLine(curbuf, (Py_ssize_t)curwin->w_cursor.lnum); +! else if (strcmp(name, "range") == 0) +! return RangeNew(curbuf, RangeStart, RangeEnd); +! else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[ssss]", "buffer", "window", "line", "range"); +! else +! { +! PyErr_SetString(PyExc_AttributeError, name); +! return NULL; +! } + } + + static int +! CurrentSetattro(PyObject *self UNUSED, PyObject *nameobj, PyObject *value) + { +! char *name = ""; +! if (PyUnicode_Check(nameobj)) +! name = _PyUnicode_AsString(nameobj); +! +! if (strcmp(name, "line") == 0) +! { +! if (SetBufferLine(curbuf, (Py_ssize_t)curwin->w_cursor.lnum, value, NULL) == FAIL) +! return -1; +! +! return 0; +! } +! else +! { +! PyErr_SetString(PyExc_AttributeError, name); +! return -1; +! } + } + + /* Dictionary object - Definitions +--- 1416,1435 ---- + 0, /* sq_inplace_repeat */ + }; + + /* Current items object - Implementation + */ + static PyObject * +! CurrentGetattro(PyObject *self, PyObject *nameobj) + { + GET_ATTR_STRING(name, nameobj); +! return CurrentGetattr(self, name); + } + + static int +! CurrentSetattro(PyObject *self, PyObject *nameobj, PyObject *value) + { +! GET_ATTR_STRING(name, nameobj); +! return CurrentSetattr(self, name, value); + } + + /* Dictionary object - Definitions +*************** +*** 1562,1573 **** + + static PyInt DictionaryLength(PyObject *); + +- static PyMappingMethods DictionaryAsMapping = { +- /* mp_length */ (lenfunc) DictionaryLength, +- /* mp_subscript */ (binaryfunc) DictionaryItem, +- /* mp_ass_subscript */ (objobjargproc) DictionaryAssItem, +- }; +- + static PyObject * + DictionaryGetattro(PyObject *self, PyObject *nameobj) + { +--- 1437,1442 ---- +*************** +*** 1587,1606 **** + DictionarySetattro(PyObject *self, PyObject *nameobj, PyObject *val) + { + GET_ATTR_STRING(name, nameobj); +! return DictionarySetattr((DictionaryObject *) self, name, val); +! } +! +! static PyTypeObject DictionaryType; +! +! static void +! DictionaryDestructor(PyObject *self) +! { +! DictionaryObject *this = (DictionaryObject *)(self); +! +! pyll_remove(&this->ref, &lastdict); +! dict_unref(this->dict); +! +! Py_TYPE(self)->tp_free((PyObject*)self); + } + + /* List object - Definitions +--- 1456,1462 ---- + DictionarySetattro(PyObject *self, PyObject *nameobj, PyObject *val) + { + GET_ATTR_STRING(name, nameobj); +! return DictionarySetattr(self, name, val); + } + + /* List object - Definitions +*************** +*** 1631,1638 **** + /* mp_ass_subscript */ (objobjargproc) ListAsSubscript, + }; + +- static PyTypeObject ListType; +- + static PyObject * + ListSubscript(PyObject *self, PyObject* idxObject) + { +--- 1487,1492 ---- +*************** +*** 1696,1729 **** + ListSetattro(PyObject *self, PyObject *nameobj, PyObject *val) + { + GET_ATTR_STRING(name, nameobj); +! return ListSetattr((ListObject *) self, name, val); +! } +! +! static void +! ListDestructor(PyObject *self) +! { +! ListObject *this = (ListObject *)(self); +! +! pyll_remove(&this->ref, &lastlist); +! list_unref(this->list); +! +! Py_TYPE(self)->tp_free((PyObject*)self); + } + + /* Function object - Definitions + */ + +- static void +- FunctionDestructor(PyObject *self) +- { +- FunctionObject *this = (FunctionObject *) (self); +- +- func_unref(this->name); +- PyMem_Del(this->name); +- +- Py_TYPE(self)->tp_free((PyObject*)self); +- } +- + static PyObject * + FunctionGetattro(PyObject *self, PyObject *nameobj) + { +--- 1550,1561 ---- + ListSetattro(PyObject *self, PyObject *nameobj, PyObject *val) + { + GET_ATTR_STRING(name, nameobj); +! return ListSetattr(self, name, val); + } + + /* Function object - Definitions + */ + + static PyObject * + FunctionGetattro(PyObject *self, PyObject *nameobj) + { +*************** +*** 1779,1788 **** + PyObject_HEAD_INIT(&CurrentType) + }; + +- PyDoc_STRVAR(vim_module_doc,"vim python interface\n"); +- +- static struct PyModuleDef vimmodule; +- + static PyObject * + Py3Init_vim(void) + { +--- 1611,1616 ---- +*************** +*** 1898,2021 **** + { + set_ref_in_py(copyID); + } +- +- static void +- init_structs(void) +- { +- vim_memset(&OutputType, 0, sizeof(OutputType)); +- OutputType.tp_name = "vim.message"; +- OutputType.tp_basicsize = sizeof(OutputObject); +- OutputType.tp_getattro = OutputGetattro; +- OutputType.tp_setattro = OutputSetattro; +- OutputType.tp_flags = Py_TPFLAGS_DEFAULT; +- OutputType.tp_doc = "vim message object"; +- OutputType.tp_methods = OutputMethods; +- OutputType.tp_alloc = call_PyType_GenericAlloc; +- OutputType.tp_new = call_PyType_GenericNew; +- OutputType.tp_free = call_PyObject_Free; +- +- vim_memset(&BufferType, 0, sizeof(BufferType)); +- BufferType.tp_name = "vim.buffer"; +- BufferType.tp_basicsize = sizeof(BufferType); +- BufferType.tp_dealloc = BufferDestructor; +- BufferType.tp_repr = BufferRepr; +- BufferType.tp_as_sequence = &BufferAsSeq; +- BufferType.tp_as_mapping = &BufferAsMapping; +- BufferType.tp_getattro = BufferGetattro; +- BufferType.tp_flags = Py_TPFLAGS_DEFAULT; +- BufferType.tp_doc = "vim buffer object"; +- BufferType.tp_methods = BufferMethods; +- BufferType.tp_alloc = call_PyType_GenericAlloc; +- BufferType.tp_new = call_PyType_GenericNew; +- BufferType.tp_free = call_PyObject_Free; +- +- vim_memset(&WindowType, 0, sizeof(WindowType)); +- WindowType.tp_name = "vim.window"; +- WindowType.tp_basicsize = sizeof(WindowObject); +- WindowType.tp_dealloc = WindowDestructor; +- WindowType.tp_repr = WindowRepr; +- WindowType.tp_getattro = WindowGetattro; +- WindowType.tp_setattro = WindowSetattro; +- WindowType.tp_flags = Py_TPFLAGS_DEFAULT; +- WindowType.tp_doc = "vim Window object"; +- WindowType.tp_methods = WindowMethods; +- WindowType.tp_alloc = call_PyType_GenericAlloc; +- WindowType.tp_new = call_PyType_GenericNew; +- WindowType.tp_free = call_PyObject_Free; +- +- vim_memset(&BufListType, 0, sizeof(BufListType)); +- BufListType.tp_name = "vim.bufferlist"; +- BufListType.tp_basicsize = sizeof(BufListObject); +- BufListType.tp_as_sequence = &BufListAsSeq; +- BufListType.tp_flags = Py_TPFLAGS_DEFAULT; +- BufferType.tp_doc = "vim buffer list"; +- +- vim_memset(&WinListType, 0, sizeof(WinListType)); +- WinListType.tp_name = "vim.windowlist"; +- WinListType.tp_basicsize = sizeof(WinListType); +- WinListType.tp_as_sequence = &WinListAsSeq; +- WinListType.tp_flags = Py_TPFLAGS_DEFAULT; +- WinListType.tp_doc = "vim window list"; +- +- vim_memset(&RangeType, 0, sizeof(RangeType)); +- RangeType.tp_name = "vim.range"; +- RangeType.tp_basicsize = sizeof(RangeObject); +- RangeType.tp_dealloc = RangeDestructor; +- RangeType.tp_repr = RangeRepr; +- RangeType.tp_as_sequence = &RangeAsSeq; +- RangeType.tp_as_mapping = &RangeAsMapping; +- RangeType.tp_getattro = RangeGetattro; +- RangeType.tp_flags = Py_TPFLAGS_DEFAULT; +- RangeType.tp_doc = "vim Range object"; +- RangeType.tp_methods = RangeMethods; +- RangeType.tp_alloc = call_PyType_GenericAlloc; +- RangeType.tp_new = call_PyType_GenericNew; +- RangeType.tp_free = call_PyObject_Free; +- +- vim_memset(&CurrentType, 0, sizeof(CurrentType)); +- CurrentType.tp_name = "vim.currentdata"; +- CurrentType.tp_basicsize = sizeof(CurrentObject); +- CurrentType.tp_getattro = CurrentGetattro; +- CurrentType.tp_setattro = CurrentSetattro; +- CurrentType.tp_flags = Py_TPFLAGS_DEFAULT; +- CurrentType.tp_doc = "vim current object"; +- +- vim_memset(&DictionaryType, 0, sizeof(DictionaryType)); +- DictionaryType.tp_name = "vim.dictionary"; +- DictionaryType.tp_basicsize = sizeof(DictionaryObject); +- DictionaryType.tp_getattro = DictionaryGetattro; +- DictionaryType.tp_setattro = DictionarySetattro; +- DictionaryType.tp_dealloc = DictionaryDestructor; +- DictionaryType.tp_as_mapping = &DictionaryAsMapping; +- DictionaryType.tp_flags = Py_TPFLAGS_DEFAULT; +- DictionaryType.tp_doc = "dictionary pushing modifications to vim structure"; +- DictionaryType.tp_methods = DictionaryMethods; +- +- vim_memset(&ListType, 0, sizeof(ListType)); +- ListType.tp_name = "vim.list"; +- ListType.tp_dealloc = ListDestructor; +- ListType.tp_basicsize = sizeof(ListObject); +- ListType.tp_getattro = ListGetattro; +- ListType.tp_setattro = ListSetattro; +- ListType.tp_as_sequence = &ListAsSeq; +- ListType.tp_as_mapping = &ListAsMapping; +- ListType.tp_flags = Py_TPFLAGS_DEFAULT; +- ListType.tp_doc = "list pushing modifications to vim structure"; +- ListType.tp_methods = ListMethods; +- +- vim_memset(&FunctionType, 0, sizeof(FunctionType)); +- FunctionType.tp_name = "vim.list"; +- FunctionType.tp_basicsize = sizeof(FunctionObject); +- FunctionType.tp_getattro = FunctionGetattro; +- FunctionType.tp_dealloc = FunctionDestructor; +- FunctionType.tp_call = FunctionCall; +- FunctionType.tp_flags = Py_TPFLAGS_DEFAULT; +- FunctionType.tp_doc = "object that calls vim function"; +- FunctionType.tp_methods = FunctionMethods; +- +- vim_memset(&vimmodule, 0, sizeof(vimmodule)); +- vimmodule.m_name = "vim"; +- vimmodule.m_doc = vim_module_doc; +- vimmodule.m_size = -1; +- vimmodule.m_methods = VimMethods; +- } +--- 1726,1728 ---- +*** ../vim-7.3.908/src/if_python.c 2013-04-24 13:04:21.000000000 +0200 +--- src/if_python.c 2013-04-24 13:35:06.000000000 +0200 +*************** +*** 87,92 **** +--- 87,93 ---- + # define Py_ssize_t_fmt "n" + #else + # define PyInt int ++ # define lenfunc inquiry + # define PyInquiry inquiry + # define PyIntArgFunc intargfunc + # define PyIntIntArgFunc intintargfunc +*************** +*** 600,607 **** + static PyObject *DictionaryNew(dict_T *); + static PyObject *LineToString(const char *); + +- static PyTypeObject RangeType; +- + static int initialised = 0; + #define PYINITIALISED initialised + +--- 601,606 ---- +*************** +*** 617,622 **** +--- 616,631 ---- + #define DICTKEY_UNREF + #define DICTKEY_DECL + ++ #define DESTRUCTOR_FINISH(self) Py_DECREF(self); ++ ++ static PyObject *OutputGetattr(PyObject *, char *); ++ static PyObject *BufferGetattr(PyObject *, char *); ++ static PyObject *WindowGetattr(PyObject *, char *); ++ static PyObject *RangeGetattr(PyObject *, char *); ++ static PyObject *DictionaryGetattr(PyObject *, char*); ++ static PyObject *ListGetattr(PyObject *, char *); ++ static PyObject *FunctionGetattr(PyObject *, char *); ++ + /* + * Include the code shared with if_python3.c + */ +*************** +*** 627,635 **** + * Internal function prototypes. + */ + +- static PyInt RangeStart; +- static PyInt RangeEnd; +- + static PyObject *globals; + + static void PythonIO_Flush(void); +--- 636,641 ---- +*************** +*** 1003,1021 **** + + #define WindowType_Check(obj) ((obj)->ob_type == &WindowType) + +- static void WindowDestructor(PyObject *); +- static PyObject *WindowGetattr(PyObject *, char *); +- + /* Buffer type - Implementation functions + * -------------------------------------- + */ + + #define BufferType_Check(obj) ((obj)->ob_type == &BufferType) + +- static void BufferDestructor(PyObject *); +- static PyObject *BufferGetattr(PyObject *, char *); +- static PyObject *BufferRepr(PyObject *); +- + static PyInt BufferLength(PyObject *); + static PyObject *BufferItem(PyObject *, PyInt); + static PyObject *BufferSlice(PyObject *, PyInt, PyInt); +--- 1009,1020 ---- +*************** +*** 1035,1043 **** + * ----------------------------------------------- + */ + +- static PyObject *CurrentGetattr(PyObject *, char *); +- static int CurrentSetattr(PyObject *, char *, PyObject *); +- + static PySequenceMethods BufferAsSeq = { + (PyInquiry) BufferLength, /* sq_length, len(x) */ + (binaryfunc) 0, /* BufferConcat, sq_concat, x+y */ +--- 1034,1039 ---- +*************** +*** 1045,1074 **** + (PyIntArgFunc) BufferItem, /* sq_item, x[i] */ + (PyIntIntArgFunc) BufferSlice, /* sq_slice, x[i:j] */ + (PyIntObjArgProc) BufferAssItem, /* sq_ass_item, x[i]=v */ +! (PyIntIntObjArgProc) BufferAssSlice, /* sq_ass_slice, x[i:j]=v */ +! }; +! +! static PyTypeObject BufferType = { +! PyObject_HEAD_INIT(0) +! 0, +! "buffer", +! sizeof(BufferObject), + 0, +! +! (destructor) BufferDestructor, /* tp_dealloc, refcount==0 */ +! (printfunc) 0, /* tp_print, print x */ +! (getattrfunc) BufferGetattr, /* tp_getattr, x.attr */ +! (setattrfunc) 0, /* tp_setattr, x.attr=v */ +! (cmpfunc) 0, /* tp_compare, x>y */ +! (reprfunc) BufferRepr, /* tp_repr, `x`, print x */ +! +! 0, /* as number */ +! &BufferAsSeq, /* as sequence */ +! 0, /* as mapping */ +! +! (hashfunc) 0, /* tp_hash, dict(x) */ +! (ternaryfunc) 0, /* tp_call, x() */ +! (reprfunc) 0, /* tp_str, str(x) */ + }; + + /* Buffer object - Implementation +--- 1041,1052 ---- + (PyIntArgFunc) BufferItem, /* sq_item, x[i] */ + (PyIntIntArgFunc) BufferSlice, /* sq_slice, x[i:j] */ + (PyIntObjArgProc) BufferAssItem, /* sq_ass_item, x[i]=v */ +! (PyIntIntObjArgProc) BufferAssSlice, /* sq_ass_slice, x[i:j]=v */ +! (objobjproc) 0, +! #if PY_MAJOR_VERSION >= 2 +! (binaryfunc) 0, + 0, +! #endif + }; + + /* Buffer object - Implementation +*************** +*** 1110,1173 **** + return (PyObject *)(self); + } + +- static void +- BufferDestructor(PyObject *self) +- { +- BufferObject *this = (BufferObject *)(self); +- +- if (this->buf && this->buf != INVALID_BUFFER_VALUE) +- this->buf->b_python_ref = NULL; +- +- Py_DECREF(self); +- } +- + static PyObject * + BufferGetattr(PyObject *self, char *name) + { +! BufferObject *this = (BufferObject *)(self); + +! if (CheckBuffer(this)) + return NULL; + +! if (strcmp(name, "name") == 0) +! return Py_BuildValue("s", this->buf->b_ffname); +! else if (strcmp(name, "number") == 0) +! return Py_BuildValue(Py_ssize_t_fmt, this->buf->b_fnum); +! else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[ss]", "name", "number"); + else + return Py_FindMethod(BufferMethods, self, name); + } + +- static PyObject * +- BufferRepr(PyObject *self) +- { +- static char repr[100]; +- BufferObject *this = (BufferObject *)(self); +- +- if (this->buf == INVALID_BUFFER_VALUE) +- { +- vim_snprintf(repr, 100, _(""), (self)); +- return PyString_FromString(repr); +- } +- else +- { +- char *name = (char *)this->buf->b_fname; +- PyInt len; +- +- if (name == NULL) +- name = ""; +- len = strlen(name); +- +- if (len > 35) +- name = name + (35 - len); +- +- vim_snprintf(repr, 100, "", len > 35 ? "..." : "", name); +- +- return PyString_FromString(repr); +- } +- } +- + /******************/ + + static PyInt +--- 1088,1108 ---- + return (PyObject *)(self); + } + + static PyObject * + BufferGetattr(PyObject *self, char *name) + { +! PyObject *r; + +! if (CheckBuffer((BufferObject *)(self))) + return NULL; + +! r = BufferAttr((BufferObject *)(self), name); +! if (r || PyErr_Occurred()) +! return r; + else + return Py_FindMethod(BufferMethods, self, name); + } + + /******************/ + + static PyInt +*************** +*** 1211,1235 **** + } + + static PySequenceMethods RangeAsSeq = { +! (PyInquiry) RangeLength, /* sq_length, len(x) */ +! (binaryfunc) 0, /* RangeConcat, */ /* sq_concat, x+y */ +! (PyIntArgFunc) 0, /* RangeRepeat, */ /* sq_repeat, x*n */ +! (PyIntArgFunc) RangeItem, /* sq_item, x[i] */ +! (PyIntIntArgFunc) RangeSlice, /* sq_slice, x[i:j] */ +! (PyIntObjArgProc) RangeAssItem, /* sq_ass_item, x[i]=v */ +! (PyIntIntObjArgProc) RangeAssSlice, /* sq_ass_slice, x[i:j]=v */ + }; + + /* Line range object - Implementation + */ + +- static void +- RangeDestructor(PyObject *self) +- { +- Py_DECREF(((RangeObject *)(self))->buf); +- Py_DECREF(self); +- } +- + static PyObject * + RangeGetattr(PyObject *self, char *name) + { +--- 1146,1168 ---- + } + + static PySequenceMethods RangeAsSeq = { +! (PyInquiry) RangeLength, /* sq_length, len(x) */ +! (binaryfunc) 0, /* RangeConcat, */ /* sq_concat, x+y */ +! (PyIntArgFunc) 0, /* RangeRepeat, */ /* sq_repeat, x*n */ +! (PyIntArgFunc) RangeItem, /* sq_item, x[i] */ +! (PyIntIntArgFunc) RangeSlice, /* sq_slice, x[i:j] */ +! (PyIntObjArgProc) RangeAssItem, /* sq_ass_item, x[i]=v */ +! (PyIntIntObjArgProc) RangeAssSlice, /* sq_ass_slice, x[i:j]=v */ +! (objobjproc) 0, +! #if PY_MAJOR_VERSION >= 2 +! (binaryfunc) 0, +! 0, +! #endif + }; + + /* Line range object - Implementation + */ + + static PyObject * + RangeGetattr(PyObject *self, char *name) + { +*************** +*** 1264,1274 **** + /* Buffer list object - Definitions + */ + +- typedef struct +- { +- PyObject_HEAD +- } BufListObject; +- + static PySequenceMethods BufListAsSeq = { + (PyInquiry) BufListLength, /* sq_length, len(x) */ + (binaryfunc) 0, /* sq_concat, x+y */ +--- 1197,1202 ---- +*************** +*** 1276,1336 **** + (PyIntArgFunc) BufListItem, /* sq_item, x[i] */ + (PyIntIntArgFunc) 0, /* sq_slice, x[i:j] */ + (PyIntObjArgProc) 0, /* sq_ass_item, x[i]=v */ +! (PyIntIntObjArgProc) 0, /* sq_ass_slice, x[i:j]=v */ +! }; +! +! static PyTypeObject BufListType = { +! PyObject_HEAD_INIT(0) +! 0, +! "buffer list", +! sizeof(BufListObject), +! 0, +! +! (destructor) 0, /* tp_dealloc, refcount==0 */ +! (printfunc) 0, /* tp_print, print x */ +! (getattrfunc) 0, /* tp_getattr, x.attr */ +! (setattrfunc) 0, /* tp_setattr, x.attr=v */ +! (cmpfunc) 0, /* tp_compare, x>y */ +! (reprfunc) 0, /* tp_repr, `x`, print x */ +! +! 0, /* as number */ +! &BufListAsSeq, /* as sequence */ +! 0, /* as mapping */ +! +! (hashfunc) 0, /* tp_hash, dict(x) */ +! (ternaryfunc) 0, /* tp_call, x() */ +! (reprfunc) 0, /* tp_str, str(x) */ +! }; +! +! /* Window object - Definitions +! */ +! +! static struct PyMethodDef WindowMethods[] = { +! /* name, function, calling, documentation */ +! { NULL, NULL, 0, NULL } +! }; +! +! static PyTypeObject WindowType = { +! PyObject_HEAD_INIT(0) +! 0, +! "window", +! sizeof(WindowObject), + 0, +! +! (destructor) WindowDestructor, /* tp_dealloc, refcount==0 */ +! (printfunc) 0, /* tp_print, print x */ +! (getattrfunc) WindowGetattr, /* tp_getattr, x.attr */ +! (setattrfunc) WindowSetattr, /* tp_setattr, x.attr=v */ +! (cmpfunc) 0, /* tp_compare, x>y */ +! (reprfunc) WindowRepr, /* tp_repr, `x`, print x */ +! +! 0, /* as number */ +! 0, /* as sequence */ +! 0, /* as mapping */ +! +! (hashfunc) 0, /* tp_hash, dict(x) */ +! (ternaryfunc) 0, /* tp_call, x() */ +! (reprfunc) 0, /* tp_str, str(x) */ + }; + + /* Window object - Implementation +--- 1204,1215 ---- + (PyIntArgFunc) BufListItem, /* sq_item, x[i] */ + (PyIntIntArgFunc) 0, /* sq_slice, x[i:j] */ + (PyIntObjArgProc) 0, /* sq_ass_item, x[i]=v */ +! (PyIntIntObjArgProc) 0, /* sq_ass_slice, x[i:j]=v */ +! (objobjproc) 0, +! #if PY_MAJOR_VERSION >= 2 +! (binaryfunc) 0, + 0, +! #endif + }; + + /* Window object - Implementation +*************** +*** 1370,1410 **** + return (PyObject *)(self); + } + +- static void +- WindowDestructor(PyObject *self) +- { +- WindowObject *this = (WindowObject *)(self); +- +- if (this->win && this->win != INVALID_WINDOW_VALUE) +- this->win->w_python_ref = NULL; +- +- Py_DECREF(self); +- } +- + static PyObject * + WindowGetattr(PyObject *self, char *name) + { +! WindowObject *this = (WindowObject *)(self); + +! if (CheckWindow(this)) + return NULL; + +! if (strcmp(name, "buffer") == 0) +! return (PyObject *)BufferNew(this->win->w_buffer); +! else if (strcmp(name, "cursor") == 0) +! { +! pos_T *pos = &this->win->w_cursor; +! +! return Py_BuildValue("(ll)", (long)(pos->lnum), (long)(pos->col)); +! } +! else if (strcmp(name, "height") == 0) +! return Py_BuildValue("l", (long)(this->win->w_height)); +! #ifdef FEAT_VERTSPLIT +! else if (strcmp(name, "width") == 0) +! return Py_BuildValue("l", (long)(W_WIDTH(this->win))); +! #endif +! else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[sss]", "buffer", "cursor", "height"); + else + return Py_FindMethod(WindowMethods, self, name); + } +--- 1249,1265 ---- + return (PyObject *)(self); + } + + static PyObject * + WindowGetattr(PyObject *self, char *name) + { +! PyObject *r; + +! if (CheckWindow((WindowObject *)(self))) + return NULL; + +! r = WindowAttr((WindowObject *)(self), name); +! if (r || PyErr_Occurred()) +! return r; + else + return Py_FindMethod(WindowMethods, self, name); + } +*************** +*** 1412,1423 **** + /* Window list object - Definitions + */ + +- typedef struct +- { +- PyObject_HEAD +- } +- WinListObject; +- + static PySequenceMethods WinListAsSeq = { + (PyInquiry) WinListLength, /* sq_length, len(x) */ + (binaryfunc) 0, /* sq_concat, x+y */ +--- 1267,1272 ---- +*************** +*** 1425,1526 **** + (PyIntArgFunc) WinListItem, /* sq_item, x[i] */ + (PyIntIntArgFunc) 0, /* sq_slice, x[i:j] */ + (PyIntObjArgProc) 0, /* sq_ass_item, x[i]=v */ +! (PyIntIntObjArgProc) 0, /* sq_ass_slice, x[i:j]=v */ +! }; +! +! static PyTypeObject WinListType = { +! PyObject_HEAD_INIT(0) +! 0, +! "window list", +! sizeof(WinListObject), +! 0, +! +! (destructor) 0, /* tp_dealloc, refcount==0 */ +! (printfunc) 0, /* tp_print, print x */ +! (getattrfunc) 0, /* tp_getattr, x.attr */ +! (setattrfunc) 0, /* tp_setattr, x.attr=v */ +! (cmpfunc) 0, /* tp_compare, x>y */ +! (reprfunc) 0, /* tp_repr, `x`, print x */ +! +! 0, /* as number */ +! &WinListAsSeq, /* as sequence */ +! 0, /* as mapping */ +! +! (hashfunc) 0, /* tp_hash, dict(x) */ +! (ternaryfunc) 0, /* tp_call, x() */ +! (reprfunc) 0, /* tp_str, str(x) */ +! }; +! +! /* Current items object - Definitions +! */ +! +! typedef struct +! { +! PyObject_HEAD +! } CurrentObject; +! +! static PyTypeObject CurrentType = { +! PyObject_HEAD_INIT(0) +! 0, +! "current data", +! sizeof(CurrentObject), + 0, +! +! (destructor) 0, /* tp_dealloc, refcount==0 */ +! (printfunc) 0, /* tp_print, print x */ +! (getattrfunc) CurrentGetattr, /* tp_getattr, x.attr */ +! (setattrfunc) CurrentSetattr, /* tp_setattr, x.attr=v */ +! (cmpfunc) 0, /* tp_compare, x>y */ +! (reprfunc) 0, /* tp_repr, `x`, print x */ +! +! 0, /* as number */ +! 0, /* as sequence */ +! 0, /* as mapping */ +! +! (hashfunc) 0, /* tp_hash, dict(x) */ +! (ternaryfunc) 0, /* tp_call, x() */ +! (reprfunc) 0, /* tp_str, str(x) */ + }; + +- /* Current items object - Implementation +- */ +- static PyObject * +- CurrentGetattr(PyObject *self UNUSED, char *name) +- { +- if (strcmp(name, "buffer") == 0) +- return (PyObject *)BufferNew(curbuf); +- else if (strcmp(name, "window") == 0) +- return (PyObject *)WindowNew(curwin); +- else if (strcmp(name, "line") == 0) +- return GetBufferLine(curbuf, (PyInt)curwin->w_cursor.lnum); +- else if (strcmp(name, "range") == 0) +- return RangeNew(curbuf, RangeStart, RangeEnd); +- else if (strcmp(name,"__members__") == 0) +- return Py_BuildValue("[ssss]", "buffer", "window", "line", "range"); +- else +- { +- PyErr_SetString(PyExc_AttributeError, name); +- return NULL; +- } +- } +- +- static int +- CurrentSetattr(PyObject *self UNUSED, char *name, PyObject *value) +- { +- if (strcmp(name, "line") == 0) +- { +- if (SetBufferLine(curbuf, (PyInt)curwin->w_cursor.lnum, value, NULL) == FAIL) +- return -1; +- +- return 0; +- } +- else +- { +- PyErr_SetString(PyExc_AttributeError, name); +- return -1; +- } +- } +- + /* External interface + */ + +--- 1274,1287 ---- + (PyIntArgFunc) WinListItem, /* sq_item, x[i] */ + (PyIntIntArgFunc) 0, /* sq_slice, x[i:j] */ + (PyIntObjArgProc) 0, /* sq_ass_item, x[i]=v */ +! (PyIntIntObjArgProc) 0, /* sq_ass_slice, x[i:j]=v */ +! (objobjproc) 0, +! #if PY_MAJOR_VERSION >= 2 +! (binaryfunc) 0, + 0, +! #endif + }; + + /* External interface + */ + +*************** +*** 1642,1690 **** + return result; + } + +- static void DictionaryDestructor(PyObject *); +- static PyObject *DictionaryGetattr(PyObject *, char*); +- +- static PyMappingMethods DictionaryAsMapping = { +- (PyInquiry) DictionaryLength, +- (binaryfunc) DictionaryItem, +- (objobjargproc) DictionaryAssItem, +- }; +- +- static PyTypeObject DictionaryType = { +- PyObject_HEAD_INIT(0) +- 0, +- "vimdictionary", +- sizeof(DictionaryObject), +- 0, +- +- (destructor) DictionaryDestructor, +- (printfunc) 0, +- (getattrfunc) DictionaryGetattr, +- (setattrfunc) DictionarySetattr, +- (cmpfunc) 0, +- (reprfunc) 0, +- +- 0, /* as number */ +- 0, /* as sequence */ +- &DictionaryAsMapping, /* as mapping */ +- +- (hashfunc) 0, +- (ternaryfunc) 0, +- (reprfunc) 0, +- }; +- +- static void +- DictionaryDestructor(PyObject *self) +- { +- DictionaryObject *this = ((DictionaryObject *) (self)); +- +- pyll_remove(&this->ref, &lastdict); +- dict_unref(this->dict); +- +- Py_DECREF(self); +- } +- + static PyObject * + DictionaryGetattr(PyObject *self, char *name) + { +--- 1403,1408 ---- +*************** +*** 1698,1706 **** + return Py_FindMethod(DictionaryMethods, self, name); + } + +- static void ListDestructor(PyObject *); +- static PyObject *ListGetattr(PyObject *, char *); +- + static PySequenceMethods ListAsSeq = { + (PyInquiry) ListLength, + (binaryfunc) 0, +--- 1416,1421 ---- +*************** +*** 1716,1755 **** + #endif + }; + +- static PyTypeObject ListType = { +- PyObject_HEAD_INIT(0) +- 0, +- "vimlist", +- sizeof(ListObject), +- 0, +- +- (destructor) ListDestructor, +- (printfunc) 0, +- (getattrfunc) ListGetattr, +- (setattrfunc) ListSetattr, +- (cmpfunc) 0, +- (reprfunc) 0, +- +- 0, /* as number */ +- &ListAsSeq, /* as sequence */ +- 0, /* as mapping */ +- +- (hashfunc) 0, +- (ternaryfunc) 0, +- (reprfunc) 0, +- }; +- +- static void +- ListDestructor(PyObject *self) +- { +- ListObject *this = ((ListObject *) (self)); +- +- pyll_remove(&this->ref, &lastlist); +- list_unref(this->list); +- +- Py_DECREF(self); +- } +- + static PyObject * + ListGetattr(PyObject *self, char *name) + { +--- 1431,1436 ---- +*************** +*** 1759,1801 **** + return Py_FindMethod(ListMethods, self, name); + } + +- static void FunctionDestructor(PyObject *); +- static PyObject *FunctionGetattr(PyObject *, char *); +- +- static PyTypeObject FunctionType = { +- PyObject_HEAD_INIT(0) +- 0, +- "vimfunction", +- sizeof(FunctionObject), +- 0, +- +- (destructor) FunctionDestructor, +- (printfunc) 0, +- (getattrfunc) FunctionGetattr, +- (setattrfunc) 0, +- (cmpfunc) 0, +- (reprfunc) 0, +- +- 0, /* as number */ +- 0, /* as sequence */ +- 0, /* as mapping */ +- +- (hashfunc) 0, +- (ternaryfunc) FunctionCall, +- (reprfunc) 0, +- }; +- +- static void +- FunctionDestructor(PyObject *self) +- { +- FunctionObject *this = (FunctionObject *) (self); +- +- func_unref(this->name); +- PyMem_Del(this->name); +- +- Py_DECREF(self); +- } +- + static PyObject * + FunctionGetattr(PyObject *self, char *name) + { +--- 1440,1445 ---- +*************** +*** 1839,1859 **** + { + set_ref_in_py(copyID); + } +- +- static void +- init_structs(void) +- { +- vim_memset(&OutputType, 0, sizeof(OutputType)); +- OutputType.tp_name = "message"; +- OutputType.tp_basicsize = sizeof(OutputObject); +- OutputType.tp_getattr = OutputGetattr; +- OutputType.tp_setattr = OutputSetattr; +- +- vim_memset(&RangeType, 0, sizeof(RangeType)); +- RangeType.tp_name = "range"; +- RangeType.tp_basicsize = sizeof(RangeObject); +- RangeType.tp_dealloc = RangeDestructor; +- RangeType.tp_getattr = RangeGetattr; +- RangeType.tp_repr = RangeRepr; +- RangeType.tp_as_sequence = &RangeAsSeq; +- } +--- 1483,1485 ---- +*** ../vim-7.3.908/src/version.c 2013-04-24 13:10:35.000000000 +0200 +--- src/version.c 2013-04-24 13:27:49.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 909, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +221. Your wife melts your keyboard in the oven. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6ae0d6211526b7c636fba6e0b98ac144bf10ba7f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:39 +0200 Subject: [PATCH 0800/3340] - patchlevel 910 --- 7.3.910 | 119 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 119 insertions(+) create mode 100644 7.3.910 diff --git a/7.3.910 b/7.3.910 new file mode 100644 index 00000000..ae8deb5d --- /dev/null +++ b/7.3.910 @@ -0,0 +1,119 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.910 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.910 +Problem: Python code in #ifdef branches with only minor differences. +Solution: Merge the #ifdef branches. (ZyX) +Files: src/if_py_both.h, src/if_python.c + + +*** ../vim-7.3.909/src/if_py_both.h 2013-04-24 13:39:11.000000000 +0200 +--- src/if_py_both.h 2013-04-24 13:42:30.000000000 +0200 +*************** +*** 2853,2859 **** + tv->v_type = VAR_FUNC; + func_ref(tv->vval.v_string); + } +- #if PY_MAJOR_VERSION >= 3 + else if (PyBytes_Check(obj)) + { + char_u *result; +--- 2853,2858 ---- +*************** +*** 2873,2902 **** + PyObject *bytes; + char_u *result; + +- bytes = PyString_AsBytes(obj); +- if (bytes == NULL) +- return -1; +- +- if(PyString_AsStringAndSize(bytes, (char **) &result, NULL) == -1) +- return -1; +- if (result == NULL) +- return -1; +- +- if (set_string_copy(result, tv) == -1) +- { +- Py_XDECREF(bytes); +- return -1; +- } +- Py_XDECREF(bytes); +- +- tv->v_type = VAR_STRING; +- } +- #else +- else if (PyUnicode_Check(obj)) +- { +- PyObject *bytes; +- char_u *result; +- + bytes = PyUnicode_AsEncodedString(obj, (char *)ENC_OPT, NULL); + if (bytes == NULL) + return -1; +--- 2872,2877 ---- +*************** +*** 2915,2934 **** + + tv->v_type = VAR_STRING; + } +! else if (PyString_Check(obj)) +! { +! char_u *result; +! +! if(PyString_AsStringAndSize(obj, (char **) &result, NULL) == -1) +! return -1; +! if (result == NULL) +! return -1; +! +! if (set_string_copy(result, tv) == -1) +! return -1; +! +! tv->v_type = VAR_STRING; +! } + else if (PyInt_Check(obj)) + { + tv->v_type = VAR_NUMBER; +--- 2890,2896 ---- + + tv->v_type = VAR_STRING; + } +! #if PY_MAJOR_VERSION < 3 + else if (PyInt_Check(obj)) + { + tv->v_type = VAR_NUMBER; +*** ../vim-7.3.909/src/if_python.c 2013-04-24 13:39:11.000000000 +0200 +--- src/if_python.c 2013-04-24 13:42:30.000000000 +0200 +*************** +*** 59,64 **** +--- 59,65 ---- + static void init_structs(void); + + #define PyBytes_FromString PyString_FromString ++ #define PyBytes_Check PyString_Check + + /* No-op conversion functions, use with care! */ + #define PyString_AsBytes(obj) (obj) +*** ../vim-7.3.909/src/version.c 2013-04-24 13:39:11.000000000 +0200 +--- src/version.c 2013-04-24 13:43:51.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 910, + /**/ + +-- +Your fault: core dumped + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f0cc65e5e1db7440d29efca10f32edda543c5ade Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:40 +0200 Subject: [PATCH 0801/3340] - patchlevel 911 --- 7.3.911 | 343 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 343 insertions(+) create mode 100644 7.3.911 diff --git a/7.3.911 b/7.3.911 new file mode 100644 index 00000000..9143ceea --- /dev/null +++ b/7.3.911 @@ -0,0 +1,343 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.911 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.911 +Problem: Python: Access to Vim variables is not so easy. +Solution: Define vim.vars and vim.vvars. (ZyX) +Files: runtime/doc/if_pyth.txt, src/eval.c, src/globals.h, + src/if_py_both.h, src/if_python3.c, src/if_python.c, + src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.910/runtime/doc/if_pyth.txt 2012-09-21 14:00:05.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-04-24 13:54:23.000000000 +0200 +*************** +*** 54,61 **** + EOF + endfunction + < +! Note: Python is very sensitive to the indenting. Also make sure the "class" +! line and "EOF" do not have any indent. + + *:pyfile* *:pyf* + :[range]pyf[ile] {file} +--- 54,61 ---- + EOF + endfunction + < +! Note: Python is very sensitive to the indenting. Make sure the "class" line +! and "EOF" do not have any indent. + + *:pyfile* *:pyf* + :[range]pyf[ile] {file} +*************** +*** 165,171 **** + Value Meaning ~ + zero Variable is not locked + vim.VAR_LOCKED Variable is locked, but can be unlocked +! vim.VAR_FIXED Variable is locked and can’t be unlocked + integer constants. If variable is not fixed, you can do + `var.locked=True` to lock it and `var.locked=False` to unlock. + There is no recursive locking like |:lockvar|! does. There is also +--- 165,171 ---- + Value Meaning ~ + zero Variable is not locked + vim.VAR_LOCKED Variable is locked, but can be unlocked +! vim.VAR_FIXED Variable is locked and can't be unlocked + integer constants. If variable is not fixed, you can do + `var.locked=True` to lock it and `var.locked=False` to unlock. + There is no recursive locking like |:lockvar|! does. There is also +*************** +*** 237,242 **** +--- 237,247 ---- + "current range". A range is a bit like a buffer, but with all access + restricted to a subset of lines. See |python-range| for more details. + ++ vim.vars *python-vars* ++ vim.vvars *python-vvars* ++ Dictionary-like objects holding dictionaries with global (|g:|) and ++ vim (|v:|) variables respectively. Identical to `vim.bindeval("g:")`, ++ but faster. + + Output from Python *python-output* + Vim displays all Python code output in the Vim message area. Normal +*************** +*** 307,312 **** +--- 312,318 ---- + :py n = len(b) # number of lines + :py (row,col) = b.mark('a') # named mark + :py r = b.range(1,5) # a sub-range of the buffer ++ :py b.vars["foo"] = "bar" # assign b:foo variable + + ============================================================================== + 4. Range objects *python-range* +*************** +*** 354,359 **** +--- 360,368 ---- + This is a tuple, (row,col). + height (read-write) The window height, in rows + width (read-write) The window width, in columns ++ vars (read-only) The window |w:| variables. Attribute is ++ unassignable, but you can change window ++ variables this way + The height attribute is writable only if the screen is split horizontally. + The width attribute is writable only if the screen is split vertically. + +*************** +*** 385,391 **** + + *:py3* *:python3* + The |:py3| and |:python3| commands work similar to |:python|. A simple check +! if the `:py3` command is wrong: > + :py3 print("Hello") + < *:py3file* + The |:py3file| command works similar to |:pyfile|. +--- 394,400 ---- + + *:py3* *:python3* + The |:py3| and |:python3| commands work similar to |:python|. A simple check +! if the `:py3` command is working: > + :py3 print("Hello") + < *:py3file* + The |:py3file| command works similar to |:pyfile|. +*** ../vim-7.3.910/src/eval.c 2013-04-15 18:25:55.000000000 +0200 +--- src/eval.c 2013-04-24 14:02:45.000000000 +0200 +*************** +*** 113,124 **** + static char *e_nofunc = N_("E130: Unknown function: %s"); + static char *e_illvar = N_("E461: Illegal variable name: %s"); + +! /* +! * All user-defined global variables are stored in dictionary "globvardict". +! * "globvars_var" is the variable that is used for "g:". +! */ +! static dict_T globvardict; +! static dictitem_T globvars_var; + #define globvarht globvardict.dv_hashtab + + /* +--- 113,119 ---- + static char *e_nofunc = N_("E130: Unknown function: %s"); + static char *e_illvar = N_("E461: Illegal variable name: %s"); + +! static dictitem_T globvars_var; /* variable used for g: */ + #define globvarht globvardict.dv_hashtab + + /* +*************** +*** 370,381 **** + #define vv_list vv_di.di_tv.vval.v_list + #define vv_tv vv_di.di_tv + +! /* +! * The v: variables are stored in dictionary "vimvardict". +! * "vimvars_var" is the variable that is used for the "l:" scope. +! */ +! static dict_T vimvardict; +! static dictitem_T vimvars_var; + #define vimvarht vimvardict.dv_hashtab + + static void prepare_vimvar __ARGS((int idx, typval_T *save_tv)); +--- 365,371 ---- + #define vv_list vv_di.di_tv.vval.v_list + #define vv_tv vv_di.di_tv + +! static dictitem_T vimvars_var; /* variable used for v: */ + #define vimvarht vimvardict.dv_hashtab + + static void prepare_vimvar __ARGS((int idx, typval_T *save_tv)); +*** ../vim-7.3.910/src/globals.h 2013-03-19 13:33:18.000000000 +0100 +--- src/globals.h 2013-04-24 13:57:51.000000000 +0200 +*************** +*** 180,185 **** +--- 180,187 ---- + EXTERN int emsg_severe INIT(= FALSE); /* use message of next of several + emsg() calls for throw */ + EXTERN int did_endif INIT(= FALSE); /* just had ":endif" */ ++ EXTERN dict_T vimvardict; /* Dictionary with v: variables */ ++ EXTERN dict_T globvardict; /* Dictionary with g: variables */ + #endif + EXTERN int did_emsg; /* set by emsg() when the message + is displayed or thrown */ +*** ../vim-7.3.910/src/if_py_both.h 2013-04-24 13:47:36.000000000 +0200 +--- src/if_py_both.h 2013-04-24 13:54:23.000000000 +0200 +*************** +*** 1532,1539 **** + else if (strcmp(name, "width") == 0) + return Py_BuildValue("l", (long)(W_WIDTH(this->win))); + #endif + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[sss]", "buffer", "cursor", "height"); + else + return NULL; + } +--- 1532,1541 ---- + else if (strcmp(name, "width") == 0) + return Py_BuildValue("l", (long)(W_WIDTH(this->win))); + #endif ++ else if (strcmp(name, "vars") == 0) ++ return DictionaryNew(this->win->w_vars); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[ssss]", "buffer", "cursor", "height", "vars"); + else + return NULL; + } +*************** +*** 2495,2502 **** + return Py_BuildValue("s", this->buf->b_ffname); + else if (strcmp(name, "number") == 0) + return Py_BuildValue(Py_ssize_t_fmt, this->buf->b_fnum); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[ss]", "name", "number"); + else + return NULL; + } +--- 2497,2506 ---- + return Py_BuildValue("s", this->buf->b_ffname); + else if (strcmp(name, "number") == 0) + return Py_BuildValue(Py_ssize_t_fmt, this->buf->b_fnum); ++ else if (strcmp(name, "vars") == 0) ++ return DictionaryNew(this->buf->b_vars); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[sss]", "name", "number", "vars"); + else + return NULL; + } +*** ../vim-7.3.910/src/if_python3.c 2013-04-24 13:39:11.000000000 +0200 +--- src/if_python3.c 2013-04-24 13:54:23.000000000 +0200 +*************** +*** 1647,1652 **** +--- 1647,1655 ---- + Py_INCREF((PyObject *)(void *)&TheWindowList); + PyModule_AddObject(mod, "windows", (PyObject *)(void *)&TheWindowList); + ++ PyModule_AddObject(mod, "vars", DictionaryNew(&globvardict)); ++ PyModule_AddObject(mod, "vvars", DictionaryNew(&vimvardict)); ++ + #define ADD_INT_CONSTANT(name, value) \ + tmp = PyLong_FromLong(value); \ + Py_INCREF(tmp); \ +*** ../vim-7.3.910/src/if_python.c 2013-04-24 13:47:36.000000000 +0200 +--- src/if_python.c 2013-04-24 13:54:33.000000000 +0200 +*************** +*** 1330,1335 **** +--- 1330,1336 ---- + { + PyObject *mod; + PyObject *dict; ++ PyObject *tmp; + /* The special value is removed from sys.path in Python_Init(). */ + static char *(argv[2]) = {"/must>not&exist/foo", NULL}; + +*************** +*** 1353,1358 **** +--- 1354,1365 ---- + PyDict_SetItemString(dict, "buffers", (PyObject *)(void *)&TheBufferList); + PyDict_SetItemString(dict, "current", (PyObject *)(void *)&TheCurrent); + PyDict_SetItemString(dict, "windows", (PyObject *)(void *)&TheWindowList); ++ tmp = DictionaryNew(&globvardict); ++ PyDict_SetItemString(dict, "vars", tmp); ++ Py_DECREF(tmp); ++ tmp = DictionaryNew(&vimvardict); ++ PyDict_SetItemString(dict, "vvars", tmp); ++ Py_DECREF(tmp); + PyDict_SetItemString(dict, "VAR_LOCKED", PyInt_FromLong(VAR_LOCKED)); + PyDict_SetItemString(dict, "VAR_FIXED", PyInt_FromLong(VAR_FIXED)); + PyDict_SetItemString(dict, "VAR_SCOPE", PyInt_FromLong(VAR_SCOPE)); +*** ../vim-7.3.910/src/testdir/test86.in 2013-04-05 19:32:30.000000000 +0200 +--- src/testdir/test86.in 2013-04-24 13:54:33.000000000 +0200 +*************** +*** 346,351 **** +--- 346,364 ---- + :$put =string(pyeval('l')) + :py l = ll[-10:10] + :$put =string(pyeval('l')) ++ :" ++ :" Vars ++ :let g:foo = 'bac' ++ :let w:abc = 'def' ++ :let b:baz = 'bar' ++ :try ++ : throw "Abc" ++ :catch ++ : put =pyeval('vim.vvars[''exception'']') ++ :endtry ++ :put =pyeval('vim.vars[''foo'']') ++ :put =pyeval('vim.current.window.vars[''abc'']') ++ :put =pyeval('vim.current.buffer.vars[''baz'']') + :endfun + :" + :call Test() +*** ../vim-7.3.910/src/testdir/test86.ok 2013-04-24 13:04:21.000000000 +0200 +--- src/testdir/test86.ok 2013-04-24 13:54:33.000000000 +0200 +*************** +*** 76,78 **** +--- 76,82 ---- + [0, 1, 2, 3, 4, 5] + [0, 1, 2, 3, 4, 5] + [0, 1, 2, 3, 4, 5] ++ Abc ++ bac ++ def ++ bar +*** ../vim-7.3.910/src/testdir/test87.in 2013-02-13 14:17:00.000000000 +0100 +--- src/testdir/test87.in 2013-04-24 13:54:33.000000000 +0200 +*************** +*** 315,320 **** +--- 315,333 ---- + :py3 trace_main() + :py3 sys.settrace(None) + :$put =string(l) ++ :" ++ :" Vars ++ :let g:foo = 'bac' ++ :let w:abc = 'def' ++ :let b:baz = 'bar' ++ :try ++ : throw "Abc" ++ :catch ++ : put =py3eval('vim.vvars[''exception'']') ++ :endtry ++ :put =py3eval('vim.vars[''foo'']') ++ :put =py3eval('vim.current.window.vars[''abc'']') ++ :put =py3eval('vim.current.buffer.vars[''baz'']') + :endfun + :" + :call Test() +*** ../vim-7.3.910/src/testdir/test87.ok 2013-04-24 13:04:21.000000000 +0200 +--- src/testdir/test87.ok 2013-04-24 13:54:33.000000000 +0200 +*************** +*** 65,67 **** +--- 65,71 ---- + vim: Vim(let):E861: + [1] + [1, 10, 11, 10, 11, 10, 11, 10, 11, 10, 11, 10, 1] ++ Abc ++ bac ++ def ++ bar +*** ../vim-7.3.910/src/version.c 2013-04-24 13:47:36.000000000 +0200 +--- src/version.c 2013-04-24 13:54:00.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 911, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +222. You send more than 20 personal e-mails a day. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7095faa838a327eff9c558ca6cad46e8f9f1d131 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:41 +0200 Subject: [PATCH 0802/3340] - patchlevel 912 --- 7.3.912 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.912 diff --git a/7.3.912 b/7.3.912 new file mode 100644 index 00000000..8a7ed929 --- /dev/null +++ b/7.3.912 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.912 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.912 +Problem: Typing a ":" command at the hit-enter dialog does not work if the + "file changed" dialog happens next. +Solution: Check for changed files before giving the hit-enter dialog. +Files: src/message.c + + +*** ../vim-7.3.911/src/message.c 2013-03-19 13:56:03.000000000 +0100 +--- src/message.c 2013-04-24 15:01:31.000000000 +0200 +*************** +*** 939,944 **** +--- 939,950 ---- + #ifdef USE_ON_FLY_SCROLL + dont_scroll = TRUE; /* disallow scrolling here */ + #endif ++ /* Avoid the sequence that the user types ":" at the hit-return prompt ++ * to start an Ex command, but the file-changed dialog gets in the ++ * way. */ ++ if (need_check_timestamps) ++ check_timestamps(FALSE); ++ + hit_return_msg(); + + do +*** ../vim-7.3.911/src/version.c 2013-04-24 14:06:42.000000000 +0200 +--- src/version.c 2013-04-24 15:04:30.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 912, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +224. You set up your own Web page. You set up a Web page for each + of your kids... and your pets. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From caf0207af03aa8166fc1776ed42174e7c6e505e7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:42 +0200 Subject: [PATCH 0803/3340] - patchlevel 913 --- 7.3.913 | 73 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 7.3.913 diff --git a/7.3.913 b/7.3.913 new file mode 100644 index 00000000..721959ae --- /dev/null +++ b/7.3.913 @@ -0,0 +1,73 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.913 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.913 (after 7.3.905) +Problem: Still a crash when writing viminfo. +Solution: Add checks for NULL pointers. (Ron Aaron) +Files: src/ex_getln.c + + +*** ../vim-7.3.912/src/ex_getln.c 2013-04-15 22:22:48.000000000 +0200 +--- src/ex_getln.c 2013-04-24 15:35:22.000000000 +0200 +*************** +*** 6177,6182 **** +--- 6177,6183 ---- + } + vim_free(viminfo_history[type]); + viminfo_history[type] = NULL; ++ viminfo_hisidx[type] = 0; + } + } + +*************** +*** 6230,6235 **** +--- 6231,6237 ---- + && !(round == 2 && i >= viminfo_hisidx[type])) + { + p = round == 1 ? history[type][i].hisstr ++ : viminfo_history[type] == NULL ? NULL + : viminfo_history[type][i]; + if (p != NULL && (round == 2 || !history[type][i].viminfo)) + { +*************** +*** 6261,6267 **** + } + } + for (i = 0; i < viminfo_hisidx[type]; ++i) +! vim_free(viminfo_history[type][i]); + vim_free(viminfo_history[type]); + viminfo_history[type] = NULL; + viminfo_hisidx[type] = 0; +--- 6263,6270 ---- + } + } + for (i = 0; i < viminfo_hisidx[type]; ++i) +! if (viminfo_history[type] != NULL) +! vim_free(viminfo_history[type][i]); + vim_free(viminfo_history[type]); + viminfo_history[type] = NULL; + viminfo_hisidx[type] = 0; +*** ../vim-7.3.912/src/version.c 2013-04-24 15:12:27.000000000 +0200 +--- src/version.c 2013-04-24 15:38:22.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 913, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +225. You sign up for free subscriptions for all the computer magazines + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3ec334214878af569d72b9ae0fe365212a67a2af Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:42 +0200 Subject: [PATCH 0804/3340] - patchlevel 914 --- 7.3.914 | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 7.3.914 diff --git a/7.3.914 b/7.3.914 new file mode 100644 index 00000000..e7cc58fd --- /dev/null +++ b/7.3.914 @@ -0,0 +1,72 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.914 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.914 +Problem: ~/.viminfo is messed up when running tests. +Solution: Set the viminfo filename. +Files: src/testdir/test89.in, src/testdir/test94.in + + +*** ../vim-7.3.913/src/testdir/test89.in 2013-03-13 20:42:28.000000000 +0100 +--- src/testdir/test89.in 2013-04-24 15:42:05.000000000 +0200 +*************** +*** 2,8 **** + + STARTTEST + :so small.vim +! :set hidden nocp nu rnu + :redir @a | set nu? rnu? | redir END + :e! xx + :redir @b | set nu? rnu? | redir END +--- 2,8 ---- + + STARTTEST + :so small.vim +! :set hidden nocp nu rnu viminfo+=nviminfo + :redir @a | set nu? rnu? | redir END + :e! xx + :redir @b | set nu? rnu? | redir END +*** ../vim-7.3.913/src/testdir/test94.in 2013-04-12 13:44:49.000000000 +0200 +--- src/testdir/test94.in 2013-04-24 15:43:10.000000000 +0200 +*************** +*** 17,23 **** + + STARTTEST + :so small.vim +! :set nocp + : + :" User functions + :function MoveToCap() +--- 17,23 ---- + + STARTTEST + :so small.vim +! :set nocp viminfo+=nviminfo + : + :" User functions + :function MoveToCap() +*** ../vim-7.3.913/src/version.c 2013-04-24 15:39:06.000000000 +0200 +--- src/version.c 2013-04-24 15:44:19.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 914, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +226. You sit down at the computer right after dinner and your spouse + says "See you in the morning." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From cf1ebe13d2242cd568c6f45b4fe4e7860ddd8af6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:43 +0200 Subject: [PATCH 0805/3340] - patchlevel 915 --- 7.3.915 | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 7.3.915 diff --git a/7.3.915 b/7.3.915 new file mode 100644 index 00000000..da1f12e8 --- /dev/null +++ b/7.3.915 @@ -0,0 +1,47 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.915 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.915 +Problem: When reading a file with encoding conversion fails at the end the + next encoding in 'fencs' is not used. +Solution: Retry with another encoding when possible. (Taro Muraoka) +Files: src/fileio.c + + +*** ../vim-7.3.914/src/fileio.c 2013-04-15 12:27:30.000000000 +0200 +--- src/fileio.c 2013-04-24 16:16:28.000000000 +0200 +*************** +*** 1380,1385 **** +--- 1380,1387 ---- + # endif + ) + { ++ if (can_retry) ++ goto rewind_retry; + if (conv_error == 0) + conv_error = curbuf->b_ml.ml_line_count + - linecnt + 1; +*** ../vim-7.3.914/src/version.c 2013-04-24 15:47:11.000000000 +0200 +--- src/version.c 2013-04-24 16:18:48.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 915, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +227. You sleep next to your monitor. Or on top of it. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6588f1bd9bd41af8ce0157298eafec8f47780ff4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:44 +0200 Subject: [PATCH 0806/3340] - patchlevel 916 --- 7.3.916 | 115 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 115 insertions(+) create mode 100644 7.3.916 diff --git a/7.3.916 b/7.3.916 new file mode 100644 index 00000000..3ed5ec15 --- /dev/null +++ b/7.3.916 @@ -0,0 +1,115 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.916 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.916 +Problem: Using freed memory when pasting with the mouse (Issue 130). +Solution: Get the byte value early. (hint by Dominique Pelle) +Files: src/buffer.c + + +*** ../vim-7.3.915/src/buffer.c 2013-04-15 12:27:30.000000000 +0200 +--- src/buffer.c 2013-04-24 16:45:38.000000000 +0200 +*************** +*** 3506,3512 **** + char_u *p; + char_u *s; + char_u *t; +! char_u *linecont; + #ifdef FEAT_EVAL + win_T *o_curwin; + buf_T *o_curbuf; +--- 3506,3512 ---- + char_u *p; + char_u *s; + char_u *t; +! int byteval; + #ifdef FEAT_EVAL + win_T *o_curwin; + buf_T *o_curbuf; +*************** +*** 3573,3584 **** + fillchar = '-'; + #endif + +! /* +! * Get line & check if empty (cursorpos will show "0-1"). +! * If inversion is possible we use it. Else '=' characters are used. +! */ +! linecont = ml_get_buf(wp->w_buffer, wp->w_cursor.lnum, FALSE); +! empty_line = (*linecont == NUL); + + groupdepth = 0; + p = out; +--- 3573,3593 ---- + fillchar = '-'; + #endif + +! /* Get line & check if empty (cursorpos will show "0-1"). Note that +! * p will become invalid when getting another buffer line. */ +! p = ml_get_buf(wp->w_buffer, wp->w_cursor.lnum, FALSE); +! empty_line = (*p == NUL); +! +! /* Get the byte value now, in case we need it below. This is more +! * efficient than making a copy of the line. */ +! if (wp->w_cursor.col > (colnr_T)STRLEN(p)) +! byteval = 0; +! else +! #ifdef FEAT_MBYTE +! byteval = (*mb_ptr2char)(p + wp->w_cursor.col); +! #else +! byteval = p[wp->w_cursor.col]; +! #endif + + groupdepth = 0; + p = out; +*************** +*** 3956,3971 **** + case STL_BYTEVAL_X: + base = 'X'; + case STL_BYTEVAL: +! if (wp->w_cursor.col > (colnr_T)STRLEN(linecont)) +! num = 0; +! else +! { +! #ifdef FEAT_MBYTE +! num = (*mb_ptr2char)(linecont + wp->w_cursor.col); +! #else +! num = linecont[wp->w_cursor.col]; +! #endif +! } + if (num == NL) + num = 0; + else if (num == CAR && get_fileformat(wp->w_buffer) == EOL_MAC) +--- 3965,3971 ---- + case STL_BYTEVAL_X: + base = 'X'; + case STL_BYTEVAL: +! num = byteval; + if (num == NL) + num = 0; + else if (num == CAR && get_fileformat(wp->w_buffer) == EOL_MAC) +*** ../vim-7.3.915/src/version.c 2013-04-24 16:33:58.000000000 +0200 +--- src/version.c 2013-04-24 16:51:24.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 916, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +228. You spend Saturday night making the counter on your home page + pass that 2000 mark. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 49f701409065f06670988d199dd44e4deee0ed9f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:45 +0200 Subject: [PATCH 0807/3340] - patchlevel 917 --- 7.3.917 | 85 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100644 7.3.917 diff --git a/7.3.917 b/7.3.917 new file mode 100644 index 00000000..00ed2f6e --- /dev/null +++ b/7.3.917 @@ -0,0 +1,85 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.917 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.917 +Problem: When a path ends in a backslash appending a comma has the wrong + effect. +Solution: Replace a trailing backslash with a slash. (Nazri Ramliy) +Files: src/misc1.c, src/testdir/test73.in, src/testdir/test73.ok + + +*** ../vim-7.3.916/src/misc1.c 2013-04-15 15:47:07.000000000 +0200 +--- src/misc1.c 2013-04-24 17:25:45.000000000 +0200 +*************** +*** 10135,10140 **** +--- 10135,10149 ---- + + if (ga_grow(gap, 1) == FAIL) + break; ++ ++ # if defined(MSWIN) || defined(MSDOS) ++ /* Avoid the path ending in a backslash, it fails when a comma is ++ * appended. */ ++ len = STRLEN(buf); ++ if (buf[len - 1] == '\\') ++ buf[len - 1] = '/'; ++ # endif ++ + p = vim_strsave(buf); + if (p == NULL) + break; +*** ../vim-7.3.916/src/testdir/test73.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test73.in 2013-04-24 17:22:14.000000000 +0200 +*************** +*** 158,163 **** +--- 158,173 ---- + :" Find the file containing 'E.T.' in the Xfind/in/path directory + :find file + :exec "w >>" . test_out ++ :" ++ :" Test that completion works when path=.,, ++ :" ++ :set path=.,, ++ :" Open Jimmy Hoffa file ++ :e in/file.txt ++ :exec "w >>" . test_out ++ :" Search for the file containing Holy Grail in same directory as in/path.txt ++ :find stu ++ :exec "w >>" . test_out + :q + :exec "cd " . cwd + :call DeleteDirectory("Xfind") +*** ../vim-7.3.916/src/testdir/test73.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test73.ok 2013-04-24 17:22:28.000000000 +0200 +*************** +*** 17,19 **** +--- 17,21 ---- + Voyager 2 + Jimmy Hoffa + E.T. ++ Jimmy Hoffa ++ Another Holy Grail +*** ../vim-7.3.916/src/version.c 2013-04-24 16:52:28.000000000 +0200 +--- src/version.c 2013-04-24 17:27:55.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 917, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +229. You spend so much time thinking what to add on this list. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ab36fcc69fb6f9faf86c53c9c99ba7f5c52da3eb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:46 +0200 Subject: [PATCH 0808/3340] - patchlevel 918 --- 7.3.918 | 80 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 7.3.918 diff --git a/7.3.918 b/7.3.918 new file mode 100644 index 00000000..4367b65a --- /dev/null +++ b/7.3.918 @@ -0,0 +1,80 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.918 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.918 +Problem: Repeating an Ex command after using a Visual motion does not work. +Solution: Check for an Ex command being used. (David Bürgin) +Files: src/normal.c + + +*** ../vim-7.3.917/src/normal.c 2013-04-05 17:43:10.000000000 +0200 +--- src/normal.c 2013-04-24 18:12:43.000000000 +0200 +*************** +*** 1504,1514 **** + } + #endif + +! /* only redo yank when 'y' flag is in 'cpoptions' */ +! /* never redo "zf" (define fold) */ + if ((vim_strchr(p_cpo, CPO_YANK) != NULL || oap->op_type != OP_YANK) + #ifdef FEAT_VISUAL +! && (!VIsual_active || oap->motion_force) + #endif + && cap->cmdchar != 'D' + #ifdef FEAT_FOLDING +--- 1504,1517 ---- + } + #endif + +! /* Only redo yank when 'y' flag is in 'cpoptions'. */ +! /* Never redo "zf" (define fold). */ + if ((vim_strchr(p_cpo, CPO_YANK) != NULL || oap->op_type != OP_YANK) + #ifdef FEAT_VISUAL +! && ((!VIsual_active || oap->motion_force) +! /* Also redo Operator-pending Visual mode mappings */ +! || (VIsual_active && cap->cmdchar == ':' +! && oap->op_type != OP_COLON)) + #endif + && cap->cmdchar != 'D' + #ifdef FEAT_FOLDING +*************** +*** 1797,1803 **** + prep_redo(oap->regname, 0L, NUL, cap->cmdchar, cap->nchar, + get_op_char(oap->op_type), + get_extra_op_char(oap->op_type)); +! else + prep_redo(oap->regname, 0L, NUL, 'v', + get_op_char(oap->op_type), + get_extra_op_char(oap->op_type), +--- 1800,1806 ---- + prep_redo(oap->regname, 0L, NUL, cap->cmdchar, cap->nchar, + get_op_char(oap->op_type), + get_extra_op_char(oap->op_type)); +! else if (cap->cmdchar != ':') + prep_redo(oap->regname, 0L, NUL, 'v', + get_op_char(oap->op_type), + get_extra_op_char(oap->op_type), +*** ../vim-7.3.917/src/version.c 2013-04-24 17:34:15.000000000 +0200 +--- src/version.c 2013-04-24 18:34:03.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 918, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +230. You spend your Friday nights typing away at your keyboard + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 09ca1af1c018fd044eac4541e367a980655ca528 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:46 +0200 Subject: [PATCH 0809/3340] - patchlevel 919 --- 7.3.919 | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 7.3.919 diff --git a/7.3.919 b/7.3.919 new file mode 100644 index 00000000..f179985c --- /dev/null +++ b/7.3.919 @@ -0,0 +1,57 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.919 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.919 (after 7.3.788) +Problem: An empty nl.po file does not work with an old msgfmt. +Solution: Put a single # in the file. (Laurent Blume) +Files: src/po/Makefile + + +*** ../vim-7.3.918/src/po/Makefile 2013-01-30 12:50:50.000000000 +0100 +--- src/po/Makefile 2013-04-27 14:04:45.000000000 +0200 +*************** +*** 176,184 **** + + converted: $(MOCONVERTED) + +! # nl.po was added later, if it does not exist use an empty file. + nl.po: +! touch nl.po + + # Norwegian/Bokmal: "nb" is an alias for "no". + # Copying the file is not efficient, but I don't know of another way to make +--- 176,185 ---- + + converted: $(MOCONVERTED) + +! # nl.po was added later, if it does not exist use a file with just a # in it +! # (an empty file doesn't work with old msgfmt). + nl.po: +! @( echo \# > nl.po ) + + # Norwegian/Bokmal: "nb" is an alias for "no". + # Copying the file is not efficient, but I don't know of another way to make +*** ../vim-7.3.918/src/version.c 2013-04-24 18:34:40.000000000 +0200 +--- src/version.c 2013-05-04 03:30:05.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 919, + /**/ + +-- +God made the integers; all else is the work of Man. + -- Kronecker + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 84de59d8a6e9a3bbcfa84b5b377437970864efd7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:47 +0200 Subject: [PATCH 0810/3340] - patchlevel 920 --- 7.3.920 | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 7.3.920 diff --git a/7.3.920 b/7.3.920 new file mode 100644 index 00000000..d1f50ba8 --- /dev/null +++ b/7.3.920 @@ -0,0 +1,51 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.920 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.920 +Problem: Compiler warning for size_t to int. +Solution: Add a type cast. (Mike Williams) +Files: src/misc1.c + + +*** ../vim-7.3.919/src/misc1.c 2013-04-24 17:34:15.000000000 +0200 +--- src/misc1.c 2013-04-29 22:33:49.000000000 +0200 +*************** +*** 10139,10145 **** + # if defined(MSWIN) || defined(MSDOS) + /* Avoid the path ending in a backslash, it fails when a comma is + * appended. */ +! len = STRLEN(buf); + if (buf[len - 1] == '\\') + buf[len - 1] = '/'; + # endif +--- 10139,10145 ---- + # if defined(MSWIN) || defined(MSDOS) + /* Avoid the path ending in a backslash, it fails when a comma is + * appended. */ +! len = (int)STRLEN(buf); + if (buf[len - 1] == '\\') + buf[len - 1] = '/'; + # endif +*** ../vim-7.3.919/src/version.c 2013-05-04 03:37:03.000000000 +0200 +--- src/version.c 2013-05-04 03:39:44.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 920, + /**/ + +-- +Women are probably the main cause of free software starvation. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1c0c4366fa1af3ed4fdc85f86c1e7fe9c31da114 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:48 +0200 Subject: [PATCH 0811/3340] - patchlevel 921 --- 7.3.921 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.921 diff --git a/7.3.921 b/7.3.921 new file mode 100644 index 00000000..d95108ee --- /dev/null +++ b/7.3.921 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.921 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.921 (after 7.3.697) +Problem: Trying to create a fontset handle when 'guifontset' is not set. +Solution: Add curly braces around the code block. (Max Kirillov) +Files: src/syntax.c + + +*** ../vim-7.3.920/src/syntax.c 2013-01-23 15:53:08.000000000 +0100 +--- src/syntax.c 2013-05-02 03:51:38.000000000 +0200 +*************** +*** 8082,8087 **** +--- 8082,8088 ---- + || do_tooltip + # endif + ) ++ { + if (free_font) + gui_mch_free_fontset(HL_TABLE()[idx].sg_fontset); + HL_TABLE()[idx].sg_fontset = fontset_name2handle(arg, 0 +*************** +*** 8092,8097 **** +--- 8093,8099 ---- + || do_tooltip + # endif + ); ++ } + if (HL_TABLE()[idx].sg_fontset != NOFONTSET) + { + /* If it worked and it's the Normal group, use it as the normal +*** ../vim-7.3.920/src/version.c 2013-05-04 03:40:22.000000000 +0200 +--- src/version.c 2013-05-04 03:41:40.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 921, + /**/ + +-- +Edison's greatest achievement came in 1879, when he invented the +electric company. Edison's design was a brilliant adaptation of the +simple electrical circuit: the electric company sends electricity +through a wire to a customer, then immediately gets the electricity +back through another wire + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c075bf3c43d037a1bebff07347270c5c878f7a6e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:49 +0200 Subject: [PATCH 0812/3340] - patchlevel 922 --- 7.3.922 | 83 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 7.3.922 diff --git a/7.3.922 b/7.3.922 new file mode 100644 index 00000000..8b78ca0a --- /dev/null +++ b/7.3.922 @@ -0,0 +1,83 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.922 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.922 +Problem: No test for what 7.3.918 fixes. +Solution: Add a test. (David Bürgin) +Files: src/testdir/test94.in, src/testdir/test94.ok + + +*** ../vim-7.3.921/src/testdir/test94.in 2013-04-24 15:47:11.000000000 +0200 +--- src/testdir/test94.in 2013-05-04 04:03:02.000000000 +0200 +*************** +*** 30,38 **** + : call setpos("'>", [0, line2, col2, 0]) + : normal! gv + :endfunction +- :function MoveToEndCount(count) +- : normal! v:count . e +- :endfunction + : + :" Visual modes followed by operator + /^apple +--- 30,35 ---- +*************** +*** 59,65 **** + /^Juniper + g?\WfD.: + /^Lemon +! yiWPlciWNew: + : + :" Patch 7.3.879: Properly abort Operator-pending mode for "dv:" etc. + /^zzzz +--- 56,62 ---- + /^Juniper + g?\WfD.: + /^Lemon +! yiWPlciWNewfr.: + : + :" Patch 7.3.879: Properly abort Operator-pending mode for "dv:" etc. + /^zzzz +*** ../vim-7.3.921/src/testdir/test94.ok 2013-04-12 13:44:49.000000000 +0200 +--- src/testdir/test94.ok 2013-05-04 04:06:46.000000000 +0200 +*************** +*** 13,19 **** + + ----Z + WhavcreQhevnaZ +! LemonNewNectarineZ + + zzz + ok +--- 13,19 ---- + + ----Z + WhavcreQhevnaZ +! LemonNewNewZ + + zzz + ok +*** ../vim-7.3.921/src/version.c 2013-05-04 03:42:30.000000000 +0200 +--- src/version.c 2013-05-04 04:07:08.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 922, + /**/ + +-- +This sentence is not sure that it exists, but if it does, it will +certainly consider the possibility that other sentences exist. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a6f6165bb38f544660c58ee9c21ea481e7a477cb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:50 +0200 Subject: [PATCH 0813/3340] - patchlevel 923 --- 7.3.923 | 82 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 82 insertions(+) create mode 100644 7.3.923 diff --git a/7.3.923 b/7.3.923 new file mode 100644 index 00000000..c506b6bb --- /dev/null +++ b/7.3.923 @@ -0,0 +1,82 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.923 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.923 +Problem: Check for X11 header files fails on Solaris. +Solution: Only use -Werror for gcc. (Laurent Blume) +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.922/src/configure.in 2013-04-15 14:44:53.000000000 +0200 +--- src/configure.in 2013-05-04 04:34:46.000000000 +0200 +*************** +*** 1751,1757 **** + dnl Check that the X11 header files don't use implicit declarations + AC_MSG_CHECKING(if X11 header files implicitly declare return values) + cflags_save=$CFLAGS +! CFLAGS="$CFLAGS $X_CFLAGS -Werror" + AC_TRY_COMPILE([#include ], , + AC_MSG_RESULT(no), + CFLAGS="$CFLAGS -Wno-implicit-int" +--- 1751,1762 ---- + dnl Check that the X11 header files don't use implicit declarations + AC_MSG_CHECKING(if X11 header files implicitly declare return values) + cflags_save=$CFLAGS +! dnl -Werror is GCC only, others like Solaris Studio might not like it +! if test "$GCC" = yes; then +! CFLAGS="$CFLAGS $X_CFLAGS -Werror" +! else +! CFLAGS="$CFLAGS $X_CFLAGS" +! fi + AC_TRY_COMPILE([#include ], , + AC_MSG_RESULT(no), + CFLAGS="$CFLAGS -Wno-implicit-int" +*** ../vim-7.3.922/src/auto/configure 2013-04-15 14:44:53.000000000 +0200 +--- src/auto/configure 2013-05-04 04:34:50.000000000 +0200 +*************** +*** 7656,7662 **** + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if X11 header files implicitly declare return values" >&5 + $as_echo_n "checking if X11 header files implicitly declare return values... " >&6; } + cflags_save=$CFLAGS +! CFLAGS="$CFLAGS $X_CFLAGS -Werror" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ + #include +--- 7656,7666 ---- + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if X11 header files implicitly declare return values" >&5 + $as_echo_n "checking if X11 header files implicitly declare return values... " >&6; } + cflags_save=$CFLAGS +! if test "$GCC" = yes; then +! CFLAGS="$CFLAGS $X_CFLAGS -Werror" +! else +! CFLAGS="$CFLAGS $X_CFLAGS" +! fi + cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ + #include +*** ../vim-7.3.922/src/version.c 2013-05-04 04:11:01.000000000 +0200 +--- src/version.c 2013-05-04 04:39:13.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 923, + /**/ + +-- +GALAHAD: Camelot ... +LAUNCELOT: Camelot ... +GAWAIN: It's only a model. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5ddb5105f6a62157713038a8c9a7779f50e124c4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:50 +0200 Subject: [PATCH 0814/3340] - patchlevel 924 --- 7.3.924 | 1628 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1628 insertions(+) create mode 100644 7.3.924 diff --git a/7.3.924 b/7.3.924 new file mode 100644 index 00000000..c743c3ef --- /dev/null +++ b/7.3.924 @@ -0,0 +1,1628 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.924 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.924 +Problem: Python interface can't easily access options. +Solution: Add vim.options, vim.window.options and vim.buffer.options. (ZyX) +Files: runtime/doc/if_pyth.txt, src/eval.c, src/if_py_both.h, + src/if_python.c, src/if_python3.c, src/option.c, + src/proto/eval.pro, src/proto/option.pro, src/testdir/test86.in, + src/testdir/test86.ok, src/testdir/test87.in, + src/testdir/test87.ok, src/vim.h + + +*** ../vim-7.3.923/runtime/doc/if_pyth.txt 2013-04-24 14:06:42.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-05-06 03:39:13.000000000 +0200 +*************** +*** 243,248 **** +--- 243,260 ---- + vim (|v:|) variables respectively. Identical to `vim.bindeval("g:")`, + but faster. + ++ vim.options *python-options* ++ Object partly supporting mapping protocol (supports setting and ++ getting items) providing a read-write access to global options. ++ Note: unlike |:set| this provides access only to global options. You ++ cannot use this object to obtain or set local options' values or ++ access local-only options in any fashion. Raises KeyError if no global ++ option with such name exists (i.e. does not raise KeyError for ++ |global-local| options and global only options, but does for window- ++ and buffer-local ones). Use |python-buffer| objects to access to ++ buffer-local options and |python-window| objects to access to ++ window-local options. ++ + Output from Python *python-output* + Vim displays all Python code output in the Vim message area. Normal + output appears as information messages, and error output appears as +*************** +*** 283,288 **** +--- 295,311 ---- + line numbers, which start from 1. This is particularly relevant when dealing + with marks (see below) which use vim line numbers. + ++ The buffer object attributes are: ++ b.vars Dictionary-like object used to access ++ |buffer-variable|s. ++ b.options Mapping object (supports item getting, setting and ++ deleting) that provides access to buffer-local options ++ and buffer-local values of |global-local| options. Use ++ |python-window|.options if option is window-local, ++ this object will raise KeyError. If option is ++ |global-local| and local value is missing getting it ++ will return None. ++ + The buffer object methods are: + b.append(str) Append a line to the buffer + b.append(str, nr) Idem, below line "nr" +*************** +*** 313,318 **** +--- 336,343 ---- + :py (row,col) = b.mark('a') # named mark + :py r = b.range(1,5) # a sub-range of the buffer + :py b.vars["foo"] = "bar" # assign b:foo variable ++ :py b.options["ff"] = "dos" # set fileformat ++ :py del b.options["ar"] # same as :set autoread< + + ============================================================================== + 4. Range objects *python-range* +*************** +*** 363,368 **** +--- 388,401 ---- + vars (read-only) The window |w:| variables. Attribute is + unassignable, but you can change window + variables this way ++ options (read-only) The window-local options. Attribute is ++ unassignable, but you can change window ++ options this way. Provides access only to ++ window-local options, for buffer-local use ++ |python-buffer| and for global ones use ++ |python-options|. If option is |global-local| ++ and local value is missing getting it will ++ return None. + The height attribute is writable only if the screen is split horizontally. + The width attribute is writable only if the screen is split vertically. + +*** ../vim-7.3.923/src/eval.c 2013-04-24 14:06:42.000000000 +0200 +--- src/eval.c 2013-05-06 03:42:00.000000000 +0200 +*************** +*** 16643,16651 **** +--- 16643,16690 ---- + setwinvar(argvars, rettv, 0); + } + ++ int ++ switch_win(save_curwin, save_curtab, win, tp) ++ win_T **save_curwin; ++ tabpage_T **save_curtab; ++ win_T *win; ++ tabpage_T *tp; ++ { ++ #ifdef FEAT_WINDOWS ++ /* set curwin to be our win, temporarily */ ++ *save_curwin = curwin; ++ *save_curtab = curtab; ++ goto_tabpage_tp(tp, TRUE); ++ if (!win_valid(win)) ++ return FAIL; ++ curwin = win; ++ curbuf = curwin->w_buffer; ++ #endif ++ return OK; ++ } ++ ++ void ++ restore_win(save_curwin, save_curtab) ++ win_T *save_curwin; ++ tabpage_T *save_curtab; ++ { ++ #ifdef FEAT_WINDOWS ++ /* Restore current tabpage and window, if still valid (autocomands can ++ * make them invalid). */ ++ if (valid_tabpage(save_curtab)) ++ goto_tabpage_tp(save_curtab, TRUE); ++ if (win_valid(save_curwin)) ++ { ++ curwin = save_curwin; ++ curbuf = curwin->w_buffer; ++ } ++ #endif ++ } ++ + /* + * "setwinvar()" and "settabwinvar()" functions + */ ++ + static void + setwinvar(argvars, rettv, off) + typval_T *argvars; +*************** +*** 16678,16691 **** + if (win != NULL && varname != NULL && varp != NULL) + { + #ifdef FEAT_WINDOWS +! /* set curwin to be our win, temporarily */ +! save_curwin = curwin; +! save_curtab = curtab; +! goto_tabpage_tp(tp, TRUE); +! if (!win_valid(win)) + return; +- curwin = win; +- curbuf = curwin->w_buffer; + #endif + + if (*varname == '&') +--- 16717,16724 ---- + if (win != NULL && varname != NULL && varp != NULL) + { + #ifdef FEAT_WINDOWS +! if (switch_win(&save_curwin, &save_curtab, win, tp) == FAIL) + return; + #endif + + if (*varname == '&') +*************** +*** 16713,16727 **** + } + + #ifdef FEAT_WINDOWS +! /* Restore current tabpage and window, if still valid (autocomands can +! * make them invalid). */ +! if (valid_tabpage(save_curtab)) +! goto_tabpage_tp(save_curtab, TRUE); +! if (win_valid(save_curwin)) +! { +! curwin = save_curwin; +! curbuf = curwin->w_buffer; +! } + #endif + } + } +--- 16746,16752 ---- + } + + #ifdef FEAT_WINDOWS +! restore_win(save_curwin, save_curtab); + #endif + } + } +*** ../vim-7.3.923/src/if_py_both.h 2013-04-24 14:06:42.000000000 +0200 +--- src/if_py_both.h 2013-05-06 03:47:38.000000000 +0200 +*************** +*** 1497,1502 **** +--- 1497,1775 ---- + { NULL, NULL, 0, NULL } + }; + ++ /* ++ * Options object ++ */ ++ ++ static PyTypeObject OptionsType; ++ ++ typedef int (*checkfun)(void *); ++ ++ typedef struct ++ { ++ PyObject_HEAD ++ int opt_type; ++ void *from; ++ checkfun Check; ++ PyObject *fromObj; ++ } OptionsObject; ++ ++ static PyObject * ++ OptionsItem(OptionsObject *this, PyObject *keyObject) ++ { ++ char_u *key; ++ int flags; ++ long numval; ++ char_u *stringval; ++ ++ if (this->Check(this->from)) ++ return NULL; ++ ++ DICTKEY_DECL ++ ++ DICTKEY_GET_NOTEMPTY(NULL) ++ ++ flags = get_option_value_strict(key, &numval, &stringval, ++ this->opt_type, this->from); ++ ++ DICTKEY_UNREF ++ ++ if (flags == 0) ++ { ++ PyErr_SetString(PyExc_KeyError, "Option does not exist in given scope"); ++ return NULL; ++ } ++ ++ if (flags & SOPT_UNSET) ++ { ++ Py_INCREF(Py_None); ++ return Py_None; ++ } ++ else if (flags & SOPT_BOOL) ++ { ++ PyObject *r; ++ r = numval ? Py_True : Py_False; ++ Py_INCREF(r); ++ return r; ++ } ++ else if (flags & SOPT_NUM) ++ return PyInt_FromLong(numval); ++ else if (flags & SOPT_STRING) ++ { ++ if (stringval) ++ return PyBytes_FromString((char *) stringval); ++ else ++ { ++ PyErr_SetString(PyExc_ValueError, "Unable to get option value"); ++ return NULL; ++ } ++ } ++ else ++ { ++ PyErr_SetVim("Internal error: unknown option type. Should not happen"); ++ return NULL; ++ } ++ } ++ ++ static int ++ set_option_value_for(key, numval, stringval, opt_flags, opt_type, from) ++ char_u *key; ++ int numval; ++ char_u *stringval; ++ int opt_flags; ++ int opt_type; ++ void *from; ++ { ++ win_T *save_curwin; ++ tabpage_T *save_curtab; ++ aco_save_T aco; ++ int r = 0; ++ ++ switch (opt_type) ++ { ++ case SREQ_WIN: ++ if (switch_win(&save_curwin, &save_curtab, (win_T *) from, curtab) ++ == FAIL) ++ { ++ PyErr_SetVim("Problem while switching windows."); ++ return -1; ++ } ++ set_option_value(key, numval, stringval, opt_flags); ++ restore_win(save_curwin, save_curtab); ++ break; ++ case SREQ_BUF: ++ aucmd_prepbuf(&aco, (buf_T *) from); ++ set_option_value(key, numval, stringval, opt_flags); ++ aucmd_restbuf(&aco); ++ break; ++ case SREQ_GLOBAL: ++ set_option_value(key, numval, stringval, opt_flags); ++ break; ++ } ++ return r; ++ } ++ ++ static int ++ OptionsAssItem(OptionsObject *this, PyObject *keyObject, PyObject *valObject) ++ { ++ char_u *key; ++ int flags; ++ int opt_flags; ++ int r = 0; ++ ++ if (this->Check(this->from)) ++ return -1; ++ ++ DICTKEY_DECL ++ ++ DICTKEY_GET_NOTEMPTY(-1) ++ ++ flags = get_option_value_strict(key, NULL, NULL, ++ this->opt_type, this->from); ++ ++ DICTKEY_UNREF ++ ++ if (flags == 0) ++ { ++ PyErr_SetString(PyExc_KeyError, "Option does not exist in given scope"); ++ return -1; ++ } ++ ++ if (valObject == NULL) ++ { ++ if (this->opt_type == SREQ_GLOBAL) ++ { ++ PyErr_SetString(PyExc_ValueError, "Unable to unset global option"); ++ return -1; ++ } ++ else if (!(flags & SOPT_GLOBAL)) ++ { ++ PyErr_SetString(PyExc_ValueError, "Unable to unset option without " ++ "global value"); ++ return -1; ++ } ++ else ++ { ++ unset_global_local_option(key, this->from); ++ return 0; ++ } ++ } ++ ++ opt_flags = (this->opt_type ? OPT_LOCAL : OPT_GLOBAL); ++ ++ if (flags & SOPT_BOOL) ++ { ++ if (!PyBool_Check(valObject)) ++ { ++ PyErr_SetString(PyExc_ValueError, "Object must be boolean"); ++ return -1; ++ } ++ ++ r = set_option_value_for(key, (valObject == Py_True), NULL, opt_flags, ++ this->opt_type, this->from); ++ } ++ else if (flags & SOPT_NUM) ++ { ++ int val; ++ ++ #if PY_MAJOR_VERSION < 3 ++ if (PyInt_Check(valObject)) ++ val = PyInt_AsLong(valObject); ++ else ++ #endif ++ if (PyLong_Check(valObject)) ++ val = PyLong_AsLong(valObject); ++ else ++ { ++ PyErr_SetString(PyExc_ValueError, "Object must be integer"); ++ return -1; ++ } ++ ++ r = set_option_value_for(key, val, NULL, opt_flags, ++ this->opt_type, this->from); ++ } ++ else ++ { ++ char_u *val; ++ if (PyBytes_Check(valObject)) ++ { ++ ++ if (PyString_AsStringAndSize(valObject, (char **) &val, NULL) == -1) ++ return -1; ++ if (val == NULL) ++ return -1; ++ ++ val = vim_strsave(val); ++ } ++ else if (PyUnicode_Check(valObject)) ++ { ++ PyObject *bytes; ++ ++ bytes = PyUnicode_AsEncodedString(valObject, (char *)ENC_OPT, NULL); ++ if (bytes == NULL) ++ return -1; ++ ++ if(PyString_AsStringAndSize(bytes, (char **) &val, NULL) == -1) ++ return -1; ++ if (val == NULL) ++ return -1; ++ ++ val = vim_strsave(val); ++ Py_XDECREF(bytes); ++ } ++ else ++ { ++ PyErr_SetString(PyExc_ValueError, "Object must be string"); ++ return -1; ++ } ++ ++ r = set_option_value_for(key, 0, val, opt_flags, ++ this->opt_type, this->from); ++ vim_free(val); ++ } ++ ++ return r; ++ } ++ ++ static int ++ dummy_check(void *arg UNUSED) ++ { ++ return 0; ++ } ++ ++ static PyObject * ++ OptionsNew(int opt_type, void *from, checkfun Check, PyObject *fromObj) ++ { ++ OptionsObject *self; ++ ++ self = PyObject_NEW(OptionsObject, &OptionsType); ++ if (self == NULL) ++ return NULL; ++ ++ self->opt_type = opt_type; ++ self->from = from; ++ self->Check = Check; ++ self->fromObj = fromObj; ++ if (fromObj) ++ Py_INCREF(fromObj); ++ ++ return (PyObject *)(self); ++ } ++ ++ static void ++ OptionsDestructor(PyObject *self) ++ { ++ if (((OptionsObject *)(self))->fromObj) ++ Py_DECREF(((OptionsObject *)(self))->fromObj); ++ DESTRUCTOR_FINISH(self); ++ } ++ ++ static PyMappingMethods OptionsAsMapping = { ++ (lenfunc) NULL, ++ (binaryfunc) OptionsItem, ++ (objobjargproc) OptionsAssItem, ++ }; ++ + #define INVALID_WINDOW_VALUE ((win_T *)(-1)) + + static int +*************** +*** 1534,1541 **** + #endif + else if (strcmp(name, "vars") == 0) + return DictionaryNew(this->win->w_vars); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[ssss]", "buffer", "cursor", "height", "vars"); + else + return NULL; + } +--- 1807,1818 ---- + #endif + else if (strcmp(name, "vars") == 0) + return DictionaryNew(this->win->w_vars); ++ else if (strcmp(name, "options") == 0) ++ return OptionsNew(SREQ_WIN, this->win, (checkfun) CheckWindow, ++ (PyObject *) this); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[sssss]", "buffer", "cursor", "height", "vars", +! "options"); + else + return NULL; + } +*************** +*** 2499,2506 **** + return Py_BuildValue(Py_ssize_t_fmt, this->buf->b_fnum); + else if (strcmp(name, "vars") == 0) + return DictionaryNew(this->buf->b_vars); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[sss]", "name", "number", "vars"); + else + return NULL; + } +--- 2776,2786 ---- + return Py_BuildValue(Py_ssize_t_fmt, this->buf->b_fnum); + else if (strcmp(name, "vars") == 0) + return DictionaryNew(this->buf->b_vars); ++ else if (strcmp(name, "options") == 0) ++ return OptionsNew(SREQ_BUF, this->buf, (checkfun) CheckBuffer, ++ (PyObject *) this); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[ssss]", "name", "number", "vars", "options"); + else + return NULL; + } +*************** +*** 3121,3126 **** +--- 3401,3414 ---- + FunctionType.tp_getattr = FunctionGetattr; + #endif + ++ vim_memset(&OptionsType, 0, sizeof(OptionsType)); ++ OptionsType.tp_name = "vim.options"; ++ OptionsType.tp_basicsize = sizeof(OptionsObject); ++ OptionsType.tp_flags = Py_TPFLAGS_DEFAULT; ++ OptionsType.tp_doc = "object for manipulating options"; ++ OptionsType.tp_as_mapping = &OptionsAsMapping; ++ OptionsType.tp_dealloc = OptionsDestructor; ++ + #if PY_MAJOR_VERSION >= 3 + vim_memset(&vimmodule, 0, sizeof(vimmodule)); + vimmodule.m_name = "vim"; +*** ../vim-7.3.923/src/if_python.c 2013-04-24 14:06:42.000000000 +0200 +--- src/if_python.c 2013-05-06 03:36:46.000000000 +0200 +*************** +*** 1341,1346 **** +--- 1341,1347 ---- + PyType_Ready(&BufListType); + PyType_Ready(&WinListType); + PyType_Ready(&CurrentType); ++ PyType_Ready(&OptionsType); + + /* Set sys.argv[] to avoid a crash in warn(). */ + PySys_SetArgv(1, argv); +*************** +*** 1360,1365 **** +--- 1361,1369 ---- + tmp = DictionaryNew(&vimvardict); + PyDict_SetItemString(dict, "vvars", tmp); + Py_DECREF(tmp); ++ tmp = OptionsNew(SREQ_GLOBAL, NULL, dummy_check, NULL); ++ PyDict_SetItemString(dict, "options", tmp); ++ Py_DECREF(tmp); + PyDict_SetItemString(dict, "VAR_LOCKED", PyInt_FromLong(VAR_LOCKED)); + PyDict_SetItemString(dict, "VAR_FIXED", PyInt_FromLong(VAR_FIXED)); + PyDict_SetItemString(dict, "VAR_SCOPE", PyInt_FromLong(VAR_SCOPE)); +*** ../vim-7.3.923/src/if_python3.c 2013-04-24 14:06:42.000000000 +0200 +--- src/if_python3.c 2013-05-06 03:36:46.000000000 +0200 +*************** +*** 1628,1633 **** +--- 1628,1634 ---- + PyType_Ready(&DictionaryType); + PyType_Ready(&ListType); + PyType_Ready(&FunctionType); ++ PyType_Ready(&OptionsType); + + /* Set sys.argv[] to avoid a crash in warn(). */ + PySys_SetArgv(1, argv); +*************** +*** 1649,1654 **** +--- 1650,1657 ---- + + PyModule_AddObject(mod, "vars", DictionaryNew(&globvardict)); + PyModule_AddObject(mod, "vvars", DictionaryNew(&vimvardict)); ++ PyModule_AddObject(mod, "options", ++ OptionsNew(SREQ_GLOBAL, NULL, dummy_check, NULL)); + + #define ADD_INT_CONSTANT(name, value) \ + tmp = PyLong_FromLong(value); \ +*** ../vim-7.3.923/src/option.c 2013-03-19 16:46:59.000000000 +0100 +--- src/option.c 2013-05-06 03:47:31.000000000 +0200 +*************** +*** 8820,8825 **** +--- 8820,8963 ---- + } + #endif + ++ #if defined(FEAT_PYTHON) || defined(FEAT_PYTHON3) ++ /* ++ * Returns the option attributes and its value. Unlike the above function it ++ * will return either global value or local value of the option depending on ++ * what was requested, but it will never return global value if it was ++ * requested to return local one and vice versa. Neither it will return ++ * buffer-local value if it was requested to return window-local one. ++ * ++ * Pretends that option is absent if it is not present in the requested scope ++ * (i.e. has no global, window-local or buffer-local value depending on ++ * opt_type). Uses ++ * ++ * Returned flags: ++ * 0 hidden or unknown option ++ * see SOPT_* in vim.h for other flags ++ * ++ * Possible opt_type values: see SREQ_* in vim.h ++ */ ++ int ++ get_option_value_strict(name, numval, stringval, opt_type, from) ++ char_u *name; ++ long *numval; ++ char_u **stringval; /* NULL when only obtaining attributes */ ++ int opt_type; ++ void *from; ++ { ++ int opt_idx; ++ char_u *varp; ++ struct vimoption *p; ++ int r = 0; ++ ++ opt_idx = findoption(name); ++ if (opt_idx < 0) ++ return 0; ++ ++ p = &(options[opt_idx]); ++ ++ /* Hidden option */ ++ if (p->var == NULL) ++ return 0; ++ ++ if (p->flags & P_BOOL) ++ r |= SOPT_BOOL; ++ else if (p->flags & P_NUM) ++ r |= SOPT_NUM; ++ else if (p->flags & P_STRING) ++ r |= SOPT_STRING; ++ ++ if (p->indir == PV_NONE) ++ { ++ if (opt_type == SREQ_GLOBAL) ++ r |= SOPT_GLOBAL; ++ else ++ return 0; /* Did not request global-only option */ ++ } ++ else ++ { ++ if (p->indir & PV_BOTH) ++ r |= SOPT_GLOBAL; ++ else if (opt_type == SREQ_GLOBAL) ++ return 0; /* Requested global option */ ++ ++ if (p->indir & PV_WIN) ++ { ++ if (opt_type == SREQ_BUF) ++ return 0; /* Did not request window-local option */ ++ else ++ r |= SOPT_WIN; ++ } ++ else if (p->indir & PV_BUF) ++ { ++ if (opt_type == SREQ_WIN) ++ return 0; /* Did not request buffer-local option */ ++ else ++ r |= SOPT_BUF; ++ } ++ } ++ ++ if (stringval == NULL) ++ return r; ++ ++ if (opt_type == SREQ_GLOBAL) ++ varp = p->var; ++ else ++ { ++ if (opt_type == SREQ_BUF) ++ { ++ /* Special case: 'modified' is b_changed, but we also want to ++ * consider it set when 'ff' or 'fenc' changed. */ ++ if (p->indir == PV_MOD) ++ { ++ *numval = bufIsChanged((buf_T *) from); ++ varp = NULL; ++ } ++ #ifdef FEAT_CRYPT ++ else if (p->indir == PV_KEY) ++ { ++ /* never return the value of the crypt key */ ++ *stringval = NULL; ++ varp = NULL; ++ } ++ #endif ++ else ++ { ++ aco_save_T aco; ++ aucmd_prepbuf(&aco, (buf_T *) from); ++ varp = get_varp(p); ++ aucmd_restbuf(&aco); ++ } ++ } ++ else if (opt_type == SREQ_WIN) ++ { ++ win_T *save_curwin; ++ save_curwin = curwin; ++ curwin = (win_T *) from; ++ curbuf = curwin->w_buffer; ++ varp = get_varp(p); ++ curwin = save_curwin; ++ curbuf = curwin->w_buffer; ++ } ++ if (varp == p->var) ++ return (r | SOPT_UNSET); ++ } ++ ++ if (varp != NULL) ++ { ++ if (p->flags & P_STRING) ++ *stringval = vim_strsave(*(char_u **)(varp)); ++ else if (p->flags & P_NUM) ++ *numval = *(long *) varp; ++ else ++ *numval = *(int *)varp; ++ } ++ ++ return r; ++ } ++ #endif ++ + /* + * Set the value of option "name". + * Use "string" for string options, use "number" for other options. +*************** +*** 9557,9562 **** +--- 9695,9781 ---- + } + + /* ++ * Unset local option value, similar to ":set opt<". ++ */ ++ ++ void ++ unset_global_local_option(name, from) ++ char_u *name; ++ void *from; ++ { ++ struct vimoption *p; ++ int opt_idx; ++ ++ buf_T *buf = (buf_T *) from; ++ win_T *win = (win_T *) from; ++ ++ opt_idx = findoption(name); ++ p = &(options[opt_idx]); ++ ++ switch ((int)p->indir) ++ { ++ /* global option with local value: use local value if it's been set */ ++ case PV_EP: ++ *buf->b_p_ep = NUL; ++ break; ++ case PV_KP: ++ *buf->b_p_kp = NUL; ++ break; ++ case PV_PATH: ++ *buf->b_p_path = NUL; ++ break; ++ case PV_AR: ++ buf->b_p_ar = -1; ++ break; ++ case PV_TAGS: ++ *buf->b_p_tags = NUL; ++ break; ++ #ifdef FEAT_FIND_ID ++ case PV_DEF: ++ *buf->b_p_def = NUL; ++ break; ++ case PV_INC: ++ *buf->b_p_inc = NUL; ++ break; ++ #endif ++ #ifdef FEAT_INS_EXPAND ++ case PV_DICT: ++ *buf->b_p_dict = NUL; ++ break; ++ case PV_TSR: ++ *buf->b_p_tsr = NUL; ++ break; ++ #endif ++ #ifdef FEAT_QUICKFIX ++ case PV_EFM: ++ *buf->b_p_efm = NUL; ++ break; ++ case PV_GP: ++ *buf->b_p_gp = NUL; ++ break; ++ case PV_MP: ++ *buf->b_p_mp = NUL; ++ break; ++ #endif ++ #if defined(FEAT_BEVAL) && defined(FEAT_EVAL) ++ case PV_BEXPR: ++ *buf->b_p_bexpr = NUL; ++ break; ++ #endif ++ #if defined(FEAT_CRYPT) ++ case PV_CM: ++ *buf->b_p_cm = NUL; ++ break; ++ #endif ++ #ifdef FEAT_STL_OPT ++ case PV_STL: ++ *win->w_p_stl = NUL; ++ break; ++ #endif ++ } ++ } ++ ++ /* + * Get pointer to option variable, depending on local or global scope. + */ + static char_u * +*** ../vim-7.3.923/src/proto/eval.pro 2013-04-15 12:27:30.000000000 +0200 +--- src/proto/eval.pro 2013-05-06 03:36:46.000000000 +0200 +*************** +*** 125,128 **** +--- 125,130 ---- + void ex_oldfiles __ARGS((exarg_T *eap)); + int modify_fname __ARGS((char_u *src, int *usedlen, char_u **fnamep, char_u **bufp, int *fnamelen)); + char_u *do_string_sub __ARGS((char_u *str, char_u *pat, char_u *sub, char_u *flags)); ++ int switch_win __ARGS((win_T **, tabpage_T **, win_T *, tabpage_T *)); ++ void restore_win __ARGS((win_T *, tabpage_T *)); + /* vim: set ft=c : */ +*** ../vim-7.3.923/src/proto/option.pro 2013-01-17 17:01:57.000000000 +0100 +--- src/proto/option.pro 2013-05-06 03:47:07.000000000 +0200 +*************** +*** 22,27 **** +--- 22,28 ---- + char_u *check_colorcolumn __ARGS((win_T *wp)); + char_u *check_stl_option __ARGS((char_u *s)); + int get_option_value __ARGS((char_u *name, long *numval, char_u **stringval, int opt_flags)); ++ int get_option_value_strict __ARGS((char_u *name, long *numval, char_u **stringval, int opt_type, void *from)); + void set_option_value __ARGS((char_u *name, long number, char_u *string, int opt_flags)); + char_u *get_term_code __ARGS((char_u *tname)); + char_u *get_highlight_default __ARGS((void)); +*************** +*** 33,38 **** +--- 34,40 ---- + void free_one_termoption __ARGS((char_u *var)); + void set_term_defaults __ARGS((void)); + void comp_col __ARGS((void)); ++ void unset_global_local_option __ARGS((char_u *name, void *from)); + char_u *get_equalprg __ARGS((void)); + void win_copy_options __ARGS((win_T *wp_from, win_T *wp_to)); + void copy_winopt __ARGS((winopt_T *from, winopt_T *to)); +*** ../vim-7.3.923/src/testdir/test86.in 2013-04-24 14:06:42.000000000 +0200 +--- src/testdir/test86.in 2013-05-06 03:36:46.000000000 +0200 +*************** +*** 359,364 **** +--- 359,483 ---- + :put =pyeval('vim.vars[''foo'']') + :put =pyeval('vim.current.window.vars[''abc'']') + :put =pyeval('vim.current.buffer.vars[''baz'']') ++ :" ++ :" Options ++ :" paste: boolean, global ++ :" previewheight number, global ++ :" operatorfunc: string, global ++ :" number: boolean, window-local ++ :" numberwidth: number, window-local ++ :" colorcolumn: string, window-local ++ :" statusline: string, window-local/global ++ :" autoindent: boolean, buffer-local ++ :" iminsert: number, buffer-local ++ :" omnifunc: string, buffer-local ++ :" preserveindent: boolean, buffer-local/global ++ :" path: string, buffer-local/global ++ :let g:bufs=[bufnr('%')] ++ :new ++ :let g:bufs+=[bufnr('%')] ++ :vnew ++ :let g:bufs+=[bufnr('%')] ++ :wincmd j ++ :vnew ++ :let g:bufs+=[bufnr('%')] ++ :wincmd l ++ :fun RecVars(opt) ++ : let gval =string(eval('&g:'.a:opt)) ++ : let wvals=join(map(range(1, 4), 'v:val.":".string(getwinvar(v:val, "&".a:opt))')) ++ : let bvals=join(map(copy(g:bufs), 'v:val.":".string(getbufvar(v:val, "&".a:opt))')) ++ : put =' G: '.gval ++ : put =' W: '.wvals ++ : put =' B: '.wvals ++ :endfun ++ py << EOF ++ def e(s, g=globals(), l=locals()): ++ try: ++ exec(s, g, l) ++ except Exception as e: ++ vim.command('throw ' + repr(e.__class__.__name__)) ++ ++ def ev(s, g=globals(), l=locals()): ++ try: ++ return eval(s, g, l) ++ except Exception as e: ++ vim.command('throw ' + repr(e.__class__.__name__)) ++ return 0 ++ EOF ++ :function E(s) ++ : python e(vim.eval('a:s')) ++ :endfunction ++ :function Ev(s) ++ : return pyeval('ev(vim.eval("a:s"))') ++ :endfunction ++ :py gopts1=vim.options ++ :py wopts1=vim.windows[2].options ++ :py wopts2=vim.windows[0].options ++ :py wopts3=vim.windows[1].options ++ :py bopts1=vim.buffers[vim.bindeval("g:bufs")[2]].options ++ :py bopts2=vim.buffers[vim.bindeval("g:bufs")[1]].options ++ :py bopts3=vim.buffers[vim.bindeval("g:bufs")[0]].options ++ :let lst=[] ++ :let lst+=[['paste', 1, 0, 1, 2, 1, 1, 0 ]] ++ :let lst+=[['previewheight', 5, 1, 6, 'a', 0, 1, 0 ]] ++ :let lst+=[['operatorfunc', 'A', 'B', 'C', 2, 0, 1, 0 ]] ++ :let lst+=[['number', 0, 1, 1, 0, 1, 0, 1 ]] ++ :let lst+=[['numberwidth', 2, 3, 5, -100, 0, 0, 1 ]] ++ :let lst+=[['colorcolumn', '+1', '+2', '+3', 'abc', 0, 0, 1 ]] ++ :let lst+=[['statusline', '1', '2', '4', 0, 0, 1, 1 ]] ++ :let lst+=[['autoindent', 0, 1, 1, 2, 1, 0, 2 ]] ++ :let lst+=[['iminsert', 0, 2, 1, 3, 0, 0, 2 ]] ++ :let lst+=[['omnifunc', 'A', 'B', 'C', 1, 0, 0, 2 ]] ++ :let lst+=[['preserveindent', 0, 1, 1, 2, 1, 1, 2 ]] ++ :let lst+=[['path', '.,,', ',,', '.', 0, 0, 1, 2 ]] ++ :for [oname, oval1, oval2, oval3, invval, bool, global, local] in lst ++ : py oname=vim.eval('oname') ++ : py oval1=vim.bindeval('oval1') ++ : py oval2=vim.bindeval('oval2') ++ : py oval3=vim.bindeval('oval3') ++ : if invval is 0 || invval is 1 ++ : py invval=bool(vim.bindeval('invval')) ++ : else ++ : py invval=vim.bindeval('invval') ++ : endif ++ : if bool ++ : py oval1=bool(oval1) ++ : py oval2=bool(oval2) ++ : py oval3=bool(oval3) ++ : endif ++ : put ='>>> '.oname ++ : for v in ['gopts1', 'wopts1', 'bopts1'] ++ : try ++ : put =' p/'.v.': '.Ev('repr('.v.'['''.oname.'''])') ++ : catch ++ : put =' p/'.v.'! '.v:exception ++ : endtry ++ : try ++ : call E(v.'["'.oname.'"]=invval') ++ : catch ++ : put =' inv: '.string(invval).'! '.v:exception ++ : endtry ++ : for vv in (v is# 'gopts1' ? [v] : [v, v[:-2].'2', v[:-2].'3']) ++ : let val=substitute(vv, '^.opts', 'oval', '') ++ : try ++ : call E(vv.'["'.oname.'"]='.val) ++ : catch ++ : put =' '.vv.'! '.v:exception ++ : endtry ++ : endfor ++ : endfor ++ : call RecVars(oname) ++ : for v in ['wopts3', 'bopts3'] ++ : try ++ : call E('del '.v.'["'.oname.'"]') ++ : catch ++ : put =' del '.v.'! '.v:exception ++ : endtry ++ : endfor ++ : call RecVars(oname) ++ endtry ++ :endfor ++ :only + :endfun + :" + :call Test() +*** ../vim-7.3.923/src/testdir/test86.ok 2013-04-24 14:06:42.000000000 +0200 +--- src/testdir/test86.ok 2013-05-06 03:36:46.000000000 +0200 +*************** +*** 80,82 **** +--- 80,308 ---- + bac + def + bar ++ >>> paste ++ p/gopts1: False ++ inv: 2! ValueError ++ p/wopts1! KeyError ++ inv: 2! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1! KeyError ++ inv: 2! KeyError ++ bopts1! KeyError ++ bopts2! KeyError ++ bopts3! KeyError ++ G: 1 ++ W: 1:1 2:1 3:1 4:1 ++ B: 1:1 2:1 3:1 4:1 ++ del wopts3! KeyError ++ del bopts3! KeyError ++ G: 1 ++ W: 1:1 2:1 3:1 4:1 ++ B: 1:1 2:1 3:1 4:1 ++ >>> previewheight ++ p/gopts1: 12 ++ inv: 'a'! ValueError ++ p/wopts1! KeyError ++ inv: 'a'! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1! KeyError ++ inv: 'a'! KeyError ++ bopts1! KeyError ++ bopts2! KeyError ++ bopts3! KeyError ++ G: 5 ++ W: 1:5 2:5 3:5 4:5 ++ B: 1:5 2:5 3:5 4:5 ++ del wopts3! KeyError ++ del bopts3! KeyError ++ G: 5 ++ W: 1:5 2:5 3:5 4:5 ++ B: 1:5 2:5 3:5 4:5 ++ >>> operatorfunc ++ p/gopts1: '' ++ inv: 2! ValueError ++ p/wopts1! KeyError ++ inv: 2! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1! KeyError ++ inv: 2! KeyError ++ bopts1! KeyError ++ bopts2! KeyError ++ bopts3! KeyError ++ G: 'A' ++ W: 1:'A' 2:'A' 3:'A' 4:'A' ++ B: 1:'A' 2:'A' 3:'A' 4:'A' ++ del wopts3! KeyError ++ del bopts3! KeyError ++ G: 'A' ++ W: 1:'A' 2:'A' 3:'A' 4:'A' ++ B: 1:'A' 2:'A' 3:'A' 4:'A' ++ >>> number ++ p/gopts1! KeyError ++ inv: 0! KeyError ++ gopts1! KeyError ++ p/wopts1: False ++ p/bopts1! KeyError ++ inv: 0! KeyError ++ bopts1! KeyError ++ bopts2! KeyError ++ bopts3! KeyError ++ G: 0 ++ W: 1:1 2:1 3:0 4:0 ++ B: 1:1 2:1 3:0 4:0 ++ del wopts3! ValueError ++ del bopts3! KeyError ++ G: 0 ++ W: 1:1 2:1 3:0 4:0 ++ B: 1:1 2:1 3:0 4:0 ++ >>> numberwidth ++ p/gopts1! KeyError ++ inv: -100! KeyError ++ gopts1! KeyError ++ p/wopts1: 8 ++ p/bopts1! KeyError ++ inv: -100! KeyError ++ bopts1! KeyError ++ bopts2! KeyError ++ bopts3! KeyError ++ G: 8 ++ W: 1:3 2:5 3:2 4:8 ++ B: 1:3 2:5 3:2 4:8 ++ del wopts3! ValueError ++ del bopts3! KeyError ++ G: 8 ++ W: 1:3 2:5 3:2 4:8 ++ B: 1:3 2:5 3:2 4:8 ++ >>> colorcolumn ++ p/gopts1! KeyError ++ inv: 'abc'! KeyError ++ gopts1! KeyError ++ p/wopts1: '' ++ p/bopts1! KeyError ++ inv: 'abc'! KeyError ++ bopts1! KeyError ++ bopts2! KeyError ++ bopts3! KeyError ++ G: '' ++ W: 1:'+2' 2:'+3' 3:'+1' 4:'' ++ B: 1:'+2' 2:'+3' 3:'+1' 4:'' ++ del wopts3! ValueError ++ del bopts3! KeyError ++ G: '' ++ W: 1:'+2' 2:'+3' 3:'+1' 4:'' ++ B: 1:'+2' 2:'+3' 3:'+1' 4:'' ++ >>> statusline ++ p/gopts1: '' ++ inv: 0! ValueError ++ p/wopts1: None ++ inv: 0! ValueError ++ p/bopts1! KeyError ++ inv: 0! KeyError ++ bopts1! KeyError ++ bopts2! KeyError ++ bopts3! KeyError ++ G: '1' ++ W: 1:'2' 2:'4' 3:'1' 4:'1' ++ B: 1:'2' 2:'4' 3:'1' 4:'1' ++ del bopts3! KeyError ++ G: '1' ++ W: 1:'2' 2:'1' 3:'1' 4:'1' ++ B: 1:'2' 2:'1' 3:'1' 4:'1' ++ >>> autoindent ++ p/gopts1! KeyError ++ inv: 2! KeyError ++ gopts1! KeyError ++ p/wopts1! KeyError ++ inv: 2! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1: False ++ inv: 2! ValueError ++ G: 0 ++ W: 1:1 2:1 3:0 4:0 ++ B: 1:1 2:1 3:0 4:0 ++ del wopts3! KeyError ++ del bopts3! ValueError ++ G: 0 ++ W: 1:1 2:1 3:0 4:0 ++ B: 1:1 2:1 3:0 4:0 ++ >>> iminsert ++ p/gopts1! KeyError ++ inv: 3! KeyError ++ gopts1! KeyError ++ p/wopts1! KeyError ++ inv: 3! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1: 2 ++ G: 1 ++ W: 1:2 2:1 3:0 4:2 ++ B: 1:2 2:1 3:0 4:2 ++ del wopts3! KeyError ++ del bopts3! ValueError ++ G: 1 ++ W: 1:2 2:1 3:0 4:2 ++ B: 1:2 2:1 3:0 4:2 ++ >>> omnifunc ++ p/gopts1! KeyError ++ inv: 1! KeyError ++ gopts1! KeyError ++ p/wopts1! KeyError ++ inv: 1! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1: '' ++ inv: 1! ValueError ++ G: '' ++ W: 1:'B' 2:'C' 3:'A' 4:'' ++ B: 1:'B' 2:'C' 3:'A' 4:'' ++ del wopts3! KeyError ++ del bopts3! ValueError ++ G: '' ++ W: 1:'B' 2:'C' 3:'A' 4:'' ++ B: 1:'B' 2:'C' 3:'A' 4:'' ++ >>> preserveindent ++ p/gopts1! KeyError ++ inv: 2! KeyError ++ gopts1! KeyError ++ p/wopts1! KeyError ++ inv: 2! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1: False ++ inv: 2! ValueError ++ G: 0 ++ W: 1:1 2:1 3:0 4:0 ++ B: 1:1 2:1 3:0 4:0 ++ del wopts3! KeyError ++ del bopts3! ValueError ++ G: 0 ++ W: 1:1 2:1 3:0 4:0 ++ B: 1:1 2:1 3:0 4:0 ++ >>> path ++ p/gopts1: '.,/usr/include,,' ++ inv: 0! ValueError ++ p/wopts1! KeyError ++ inv: 0! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1: None ++ inv: 0! ValueError ++ G: '.,,' ++ W: 1:',,' 2:'.' 3:'.,,' 4:'.,,' ++ B: 1:',,' 2:'.' 3:'.,,' 4:'.,,' ++ del wopts3! KeyError ++ G: '.,,' ++ W: 1:',,' 2:'.,,' 3:'.,,' 4:'.,,' ++ B: 1:',,' 2:'.,,' 3:'.,,' 4:'.,,' +*** ../vim-7.3.923/src/testdir/test87.in 2013-04-24 14:06:42.000000000 +0200 +--- src/testdir/test87.in 2013-05-06 03:36:46.000000000 +0200 +*************** +*** 328,333 **** +--- 328,452 ---- + :put =py3eval('vim.vars[''foo'']') + :put =py3eval('vim.current.window.vars[''abc'']') + :put =py3eval('vim.current.buffer.vars[''baz'']') ++ :" ++ :" Options ++ :" paste: boolean, global ++ :" previewheight number, global ++ :" operatorfunc: string, global ++ :" number: boolean, window-local ++ :" numberwidth: number, window-local ++ :" colorcolumn: string, window-local ++ :" statusline: string, window-local/global ++ :" autoindent: boolean, buffer-local ++ :" iminsert: number, buffer-local ++ :" omnifunc: string, buffer-local ++ :" preserveindent: boolean, buffer-local/global ++ :" path: string, buffer-local/global ++ :let g:bufs=[bufnr('%')] ++ :new ++ :let g:bufs+=[bufnr('%')] ++ :vnew ++ :let g:bufs+=[bufnr('%')] ++ :wincmd j ++ :vnew ++ :let g:bufs+=[bufnr('%')] ++ :wincmd l ++ :fun RecVars(opt) ++ : let gval =string(eval('&g:'.a:opt)) ++ : let wvals=join(map(range(1, 4), 'v:val.":".string(getwinvar(v:val, "&".a:opt))')) ++ : let bvals=join(map(copy(g:bufs), 'v:val.":".string(getbufvar(v:val, "&".a:opt))')) ++ : put =' G: '.gval ++ : put =' W: '.wvals ++ : put =' B: '.wvals ++ :endfun ++ py3 << EOF ++ def e(s, g=globals(), l=locals()): ++ try: ++ exec(s, g, l) ++ except Exception as e: ++ vim.command('throw ' + repr(e.__class__.__name__)) ++ ++ def ev(s, g=globals(), l=locals()): ++ try: ++ return eval(s, g, l) ++ except Exception as e: ++ vim.command('throw ' + repr(e.__class__.__name__)) ++ return 0 ++ EOF ++ :function E(s) ++ : python3 e(vim.eval('a:s')) ++ :endfunction ++ :function Ev(s) ++ : return py3eval('ev(vim.eval("a:s"))') ++ :endfunction ++ :py3 gopts1=vim.options ++ :py3 wopts1=vim.windows[2].options ++ :py3 wopts2=vim.windows[0].options ++ :py3 wopts3=vim.windows[1].options ++ :py3 bopts1=vim.buffers[vim.bindeval("g:bufs")[2]].options ++ :py3 bopts2=vim.buffers[vim.bindeval("g:bufs")[1]].options ++ :py3 bopts3=vim.buffers[vim.bindeval("g:bufs")[0]].options ++ :let lst=[] ++ :let lst+=[['paste', 1, 0, 1, 2, 1, 1, 0 ]] ++ :let lst+=[['previewheight', 5, 1, 6, 'a', 0, 1, 0 ]] ++ :let lst+=[['operatorfunc', 'A', 'B', 'C', 2, 0, 1, 0 ]] ++ :let lst+=[['number', 0, 1, 1, 0, 1, 0, 1 ]] ++ :let lst+=[['numberwidth', 2, 3, 5, -100, 0, 0, 1 ]] ++ :let lst+=[['colorcolumn', '+1', '+2', '+3', 'abc', 0, 0, 1 ]] ++ :let lst+=[['statusline', '1', '2', '4', 0, 0, 1, 1 ]] ++ :let lst+=[['autoindent', 0, 1, 1, 2, 1, 0, 2 ]] ++ :let lst+=[['iminsert', 0, 2, 1, 3, 0, 0, 2 ]] ++ :let lst+=[['omnifunc', 'A', 'B', 'C', 1, 0, 0, 2 ]] ++ :let lst+=[['preserveindent', 0, 1, 1, 2, 1, 1, 2 ]] ++ :let lst+=[['path', '.,,', ',,', '.', 0, 0, 1, 2 ]] ++ :for [oname, oval1, oval2, oval3, invval, bool, global, local] in lst ++ : py3 oname=vim.eval('oname') ++ : py3 oval1=vim.bindeval('oval1') ++ : py3 oval2=vim.bindeval('oval2') ++ : py3 oval3=vim.bindeval('oval3') ++ : if invval is 0 || invval is 1 ++ : py3 invval=bool(vim.bindeval('invval')) ++ : else ++ : py3 invval=vim.bindeval('invval') ++ : endif ++ : if bool ++ : py3 oval1=bool(oval1) ++ : py3 oval2=bool(oval2) ++ : py3 oval3=bool(oval3) ++ : endif ++ : put ='>>> '.oname ++ : for v in ['gopts1', 'wopts1', 'bopts1'] ++ : try ++ : put =' p/'.v.': '.Ev('repr('.v.'['''.oname.'''])') ++ : catch ++ : put =' p/'.v.'! '.v:exception ++ : endtry ++ : try ++ : call E(v.'["'.oname.'"]=invval') ++ : catch ++ : put =' inv: '.string(invval).'! '.v:exception ++ : endtry ++ : for vv in (v is# 'gopts1' ? [v] : [v, v[:-2].'2', v[:-2].'3']) ++ : let val=substitute(vv, '^.opts', 'oval', '') ++ : try ++ : call E(vv.'["'.oname.'"]='.val) ++ : catch ++ : put =' '.vv.'! '.v:exception ++ : endtry ++ : endfor ++ : endfor ++ : call RecVars(oname) ++ : for v in ['wopts3', 'bopts3'] ++ : try ++ : call E('del '.v.'["'.oname.'"]') ++ : catch ++ : put =' del '.v.'! '.v:exception ++ : endtry ++ : endfor ++ : call RecVars(oname) ++ endtry ++ :endfor ++ :only + :endfun + :" + :call Test() +*** ../vim-7.3.923/src/testdir/test87.ok 2013-04-24 14:06:42.000000000 +0200 +--- src/testdir/test87.ok 2013-05-06 03:36:46.000000000 +0200 +*************** +*** 69,71 **** +--- 69,297 ---- + bac + def + bar ++ >>> paste ++ p/gopts1: False ++ inv: 2! ValueError ++ p/wopts1! KeyError ++ inv: 2! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1! KeyError ++ inv: 2! KeyError ++ bopts1! KeyError ++ bopts2! KeyError ++ bopts3! KeyError ++ G: 1 ++ W: 1:1 2:1 3:1 4:1 ++ B: 1:1 2:1 3:1 4:1 ++ del wopts3! KeyError ++ del bopts3! KeyError ++ G: 1 ++ W: 1:1 2:1 3:1 4:1 ++ B: 1:1 2:1 3:1 4:1 ++ >>> previewheight ++ p/gopts1: 12 ++ inv: 'a'! ValueError ++ p/wopts1! KeyError ++ inv: 'a'! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1! KeyError ++ inv: 'a'! KeyError ++ bopts1! KeyError ++ bopts2! KeyError ++ bopts3! KeyError ++ G: 5 ++ W: 1:5 2:5 3:5 4:5 ++ B: 1:5 2:5 3:5 4:5 ++ del wopts3! KeyError ++ del bopts3! KeyError ++ G: 5 ++ W: 1:5 2:5 3:5 4:5 ++ B: 1:5 2:5 3:5 4:5 ++ >>> operatorfunc ++ p/gopts1: b'' ++ inv: 2! ValueError ++ p/wopts1! KeyError ++ inv: 2! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1! KeyError ++ inv: 2! KeyError ++ bopts1! KeyError ++ bopts2! KeyError ++ bopts3! KeyError ++ G: 'A' ++ W: 1:'A' 2:'A' 3:'A' 4:'A' ++ B: 1:'A' 2:'A' 3:'A' 4:'A' ++ del wopts3! KeyError ++ del bopts3! KeyError ++ G: 'A' ++ W: 1:'A' 2:'A' 3:'A' 4:'A' ++ B: 1:'A' 2:'A' 3:'A' 4:'A' ++ >>> number ++ p/gopts1! KeyError ++ inv: 0! KeyError ++ gopts1! KeyError ++ p/wopts1: False ++ p/bopts1! KeyError ++ inv: 0! KeyError ++ bopts1! KeyError ++ bopts2! KeyError ++ bopts3! KeyError ++ G: 0 ++ W: 1:1 2:1 3:0 4:0 ++ B: 1:1 2:1 3:0 4:0 ++ del wopts3! ValueError ++ del bopts3! KeyError ++ G: 0 ++ W: 1:1 2:1 3:0 4:0 ++ B: 1:1 2:1 3:0 4:0 ++ >>> numberwidth ++ p/gopts1! KeyError ++ inv: -100! KeyError ++ gopts1! KeyError ++ p/wopts1: 8 ++ p/bopts1! KeyError ++ inv: -100! KeyError ++ bopts1! KeyError ++ bopts2! KeyError ++ bopts3! KeyError ++ G: 8 ++ W: 1:3 2:5 3:2 4:8 ++ B: 1:3 2:5 3:2 4:8 ++ del wopts3! ValueError ++ del bopts3! KeyError ++ G: 8 ++ W: 1:3 2:5 3:2 4:8 ++ B: 1:3 2:5 3:2 4:8 ++ >>> colorcolumn ++ p/gopts1! KeyError ++ inv: 'abc'! KeyError ++ gopts1! KeyError ++ p/wopts1: b'' ++ p/bopts1! KeyError ++ inv: 'abc'! KeyError ++ bopts1! KeyError ++ bopts2! KeyError ++ bopts3! KeyError ++ G: '' ++ W: 1:'+2' 2:'+3' 3:'+1' 4:'' ++ B: 1:'+2' 2:'+3' 3:'+1' 4:'' ++ del wopts3! ValueError ++ del bopts3! KeyError ++ G: '' ++ W: 1:'+2' 2:'+3' 3:'+1' 4:'' ++ B: 1:'+2' 2:'+3' 3:'+1' 4:'' ++ >>> statusline ++ p/gopts1: b'' ++ inv: 0! ValueError ++ p/wopts1: None ++ inv: 0! ValueError ++ p/bopts1! KeyError ++ inv: 0! KeyError ++ bopts1! KeyError ++ bopts2! KeyError ++ bopts3! KeyError ++ G: '1' ++ W: 1:'2' 2:'4' 3:'1' 4:'1' ++ B: 1:'2' 2:'4' 3:'1' 4:'1' ++ del bopts3! KeyError ++ G: '1' ++ W: 1:'2' 2:'1' 3:'1' 4:'1' ++ B: 1:'2' 2:'1' 3:'1' 4:'1' ++ >>> autoindent ++ p/gopts1! KeyError ++ inv: 2! KeyError ++ gopts1! KeyError ++ p/wopts1! KeyError ++ inv: 2! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1: False ++ inv: 2! ValueError ++ G: 0 ++ W: 1:1 2:1 3:0 4:0 ++ B: 1:1 2:1 3:0 4:0 ++ del wopts3! KeyError ++ del bopts3! ValueError ++ G: 0 ++ W: 1:1 2:1 3:0 4:0 ++ B: 1:1 2:1 3:0 4:0 ++ >>> iminsert ++ p/gopts1! KeyError ++ inv: 3! KeyError ++ gopts1! KeyError ++ p/wopts1! KeyError ++ inv: 3! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1: 2 ++ G: 1 ++ W: 1:2 2:1 3:0 4:2 ++ B: 1:2 2:1 3:0 4:2 ++ del wopts3! KeyError ++ del bopts3! ValueError ++ G: 1 ++ W: 1:2 2:1 3:0 4:2 ++ B: 1:2 2:1 3:0 4:2 ++ >>> omnifunc ++ p/gopts1! KeyError ++ inv: 1! KeyError ++ gopts1! KeyError ++ p/wopts1! KeyError ++ inv: 1! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1: b'' ++ inv: 1! ValueError ++ G: '' ++ W: 1:'B' 2:'C' 3:'A' 4:'' ++ B: 1:'B' 2:'C' 3:'A' 4:'' ++ del wopts3! KeyError ++ del bopts3! ValueError ++ G: '' ++ W: 1:'B' 2:'C' 3:'A' 4:'' ++ B: 1:'B' 2:'C' 3:'A' 4:'' ++ >>> preserveindent ++ p/gopts1! KeyError ++ inv: 2! KeyError ++ gopts1! KeyError ++ p/wopts1! KeyError ++ inv: 2! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1: False ++ inv: 2! ValueError ++ G: 0 ++ W: 1:1 2:1 3:0 4:0 ++ B: 1:1 2:1 3:0 4:0 ++ del wopts3! KeyError ++ del bopts3! ValueError ++ G: 0 ++ W: 1:1 2:1 3:0 4:0 ++ B: 1:1 2:1 3:0 4:0 ++ >>> path ++ p/gopts1: b'.,/usr/include,,' ++ inv: 0! ValueError ++ p/wopts1! KeyError ++ inv: 0! KeyError ++ wopts1! KeyError ++ wopts2! KeyError ++ wopts3! KeyError ++ p/bopts1: None ++ inv: 0! ValueError ++ G: '.,,' ++ W: 1:',,' 2:'.' 3:'.,,' 4:'.,,' ++ B: 1:',,' 2:'.' 3:'.,,' 4:'.,,' ++ del wopts3! KeyError ++ G: '.,,' ++ W: 1:',,' 2:'.,,' 3:'.,,' 4:'.,,' ++ B: 1:',,' 2:'.,,' 3:'.,,' 4:'.,,' +*** ../vim-7.3.923/src/vim.h 2013-03-19 16:46:59.000000000 +0100 +--- src/vim.h 2013-05-06 03:36:46.000000000 +0200 +*************** +*** 2230,2233 **** +--- 2230,2246 ---- + #define FILEINFO_READ_FAIL 2 /* CreateFile() failed */ + #define FILEINFO_INFO_FAIL 3 /* GetFileInformationByHandle() failed */ + ++ /* Return value from get_option_value_strict */ ++ #define SOPT_BOOL 0x01 /* Boolean option */ ++ #define SOPT_NUM 0x02 /* Number option */ ++ #define SOPT_STRING 0x04 /* String option */ ++ #define SOPT_GLOBAL 0x08 /* Option has global value */ ++ #define SOPT_WIN 0x10 /* Option has window-local value */ ++ #define SOPT_BUF 0x20 /* Option has buffer-local value */ ++ #define SOPT_UNSET 0x40 /* Option does not have local value set */ ++ ++ #define SREQ_GLOBAL 0 /* Request global option */ ++ #define SREQ_WIN 1 /* Request window-local option */ ++ #define SREQ_BUF 2 /* Request buffer-local option */ ++ + #endif /* VIM__H */ +*** ../vim-7.3.923/src/version.c 2013-05-04 04:40:06.000000000 +0200 +--- src/version.c 2013-05-06 03:38:06.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 924, + /**/ + +-- +ARTHUR: (as the MAN next to him is squashed by a sheep) Knights! Run away! + Midst echoing shouts of "run away" the KNIGHTS retreat to cover with the odd + cow or goose hitting them still. The KNIGHTS crouch down under cover. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9ecdde217dac2ca36b581b0c96cf20e446712fb9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:51 +0200 Subject: [PATCH 0815/3340] - patchlevel 925 --- 7.3.925 | 2899 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 2899 insertions(+) create mode 100644 7.3.925 diff --git a/7.3.925 b/7.3.925 new file mode 100644 index 00000000..a7a0b5a3 --- /dev/null +++ b/7.3.925 @@ -0,0 +1,2899 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.925 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.925 +Problem: Typos in source files. +Solution: Fix the typos. (Ken Takata) +Files: runtime/plugin/matchparen.vim, runtime/tools/vim_vs_net.cmd, + src/GvimExt/gvimext.cpp, src/INSTALLvms.txt, src/Make_cyg.mak, + src/Make_mvc.mak, src/Make_sas.mak, src/Make_vms.mms, + src/Make_w16.mak, src/Makefile, src/VisVim/OleAut.cpp, + src/VisVim/README_VisVim.txt, src/auto/configure, src/buffer.c, + src/configure.in, src/diff.c, src/dosinst.c, src/edit.c, + src/eval.c, src/ex_cmds2.c, src/ex_docmd.c, src/ex_eval.c, + src/farsi.c, src/feature.h, src/fileio.c, src/glbl_ime.cpp, + src/gui.c, src/gui_athena.c, src/gui_beval.c, src/gui_gtk_x11.c, + src/gui_mac.c, src/gui_motif.c, src/gui_photon.c, src/gui_w16.c, + src/gui_w32.c, src/gui_w48.c, src/gui_xmebw.c, src/gui_xmebwp.h, + src/hardcopy.c, src/if_cscope.c, src/if_mzsch.c, src/if_ole.cpp, + src/if_perl.xs, src/if_py_both.h, src/if_python.c, + src/if_python3.c, src/if_ruby.c, src/main.aap, src/mbyte.c, + src/memfile.c, src/memline.c, src/misc1.c, src/misc2.c, + src/nbdebug.c, src/normal.c, src/ops.c, src/os_amiga.c, + src/os_mac.h, src/os_msdos.c, src/os_mswin.c, src/os_win16.h, + src/os_win32.c, src/os_win32.h, src/quickfix.c, src/screen.c, + src/search.c, src/spell.c, src/structs.h, src/syntax.c, + src/window.c, vimtutor.com + + +*** ../vim-7.3.924/runtime/plugin/matchparen.vim 2013-03-19 13:33:18.000000000 +0100 +--- runtime/plugin/matchparen.vim 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 5,11 **** + " Exit quickly when: + " - this plugin was already loaded (or disabled) + " - when 'compatible' is set +! " - the "CursorMoved" autocmd event is not availble. + if exists("g:loaded_matchparen") || &cp || !exists("##CursorMoved") + finish + endif +--- 5,11 ---- + " Exit quickly when: + " - this plugin was already loaded (or disabled) + " - when 'compatible' is set +! " - the "CursorMoved" autocmd event is not available. + if exists("g:loaded_matchparen") || &cp || !exists("##CursorMoved") + finish + endif +*** ../vim-7.3.924/runtime/tools/vim_vs_net.cmd 2010-08-15 21:57:12.000000000 +0200 +--- runtime/tools/vim_vs_net.cmd 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 7,18 **** + @rem Arguments - +$(CurLine) $(ItemPath) + @rem Init Dir - Empty + @rem +! @rem Coutesy of Brian Sturk + @rem + @rem --remote-silent +%1 is a command +954, move ahead 954 lines + @rem --remote-silent %2 full path to file + @rem In Vim +! @rem :h --remote-silent for mor details + @rem + @rem --servername VS_NET + @rem This will create a new instance of vim called VS_NET. So if you +--- 7,18 ---- + @rem Arguments - +$(CurLine) $(ItemPath) + @rem Init Dir - Empty + @rem +! @rem Courtesy of Brian Sturk + @rem + @rem --remote-silent +%1 is a command +954, move ahead 954 lines + @rem --remote-silent %2 full path to file + @rem In Vim +! @rem :h --remote-silent for more details + @rem + @rem --servername VS_NET + @rem This will create a new instance of vim called VS_NET. So if you +*** ../vim-7.3.924/src/GvimExt/gvimext.cpp 2011-08-10 16:31:18.000000000 +0200 +--- src/GvimExt/gvimext.cpp 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 527,533 **** + // + // PARAMETERS: + // pIDFolder - Specifies the parent folder +! // pDataObj - Spefifies the set of items selected in that folder. + // hRegKey - Specifies the type of the focused item in the selection. + // + // RETURN VALUE: +--- 527,533 ---- + // + // PARAMETERS: + // pIDFolder - Specifies the parent folder +! // pDataObj - Specifies the set of items selected in that folder. + // hRegKey - Specifies the type of the focused item in the selection. + // + // RETURN VALUE: +*** ../vim-7.3.924/src/INSTALLvms.txt 2010-08-15 21:57:25.000000000 +0200 +--- src/INSTALLvms.txt 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 330,336 **** + Also VMS_JACKETS.EXE from OpenVMS Porting Library. + + Please note, that GTK uses /name=(as_is,short)/float=ieee/ieee=denorm +! complier directives that is not compatible with "standard" VMS usage, + therefore other external features might fail as PERL, PYTHON and TCL + support. + +--- 330,336 ---- + Also VMS_JACKETS.EXE from OpenVMS Porting Library. + + Please note, that GTK uses /name=(as_is,short)/float=ieee/ieee=denorm +! compiler directives that is not compatible with "standard" VMS usage, + therefore other external features might fail as PERL, PYTHON and TCL + support. + +*** ../vim-7.3.924/src/Make_cyg.mak 2013-03-07 15:16:16.000000000 +0100 +--- src/Make_cyg.mak 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 1,6 **** + # + # Makefile for VIM on Win32, using Cygnus gcc +! # Last updated by Dan Sharp. Last Change: 2013 Feb 17 + # + # Also read INSTALLpc.txt! + # +--- 1,6 ---- + # + # Makefile for VIM on Win32, using Cygnus gcc +! # Last updated by Dan Sharp. Last Change: 2013 Apr 22 + # + # Also read INSTALLpc.txt! + # +*************** +*** 48,54 **** + # USEDLL no or yes: set to yes to use the Runtime library DLL (no) + # For USEDLL=yes the cygwin1.dll is required to run Vim. + # For "no" the mingw-gcc-g++ package or the mingw64-i686-gcc-g++ +! # package is required to complie Vim. Or set CC to gcc-3 and add + # -L/lib/w32api to EXTRA_LIBS. + # POSTSCRIPT no or yes: set to yes for PostScript printing (no) + # FEATURES TINY, SMALL, NORMAL, BIG or HUGE (BIG) +--- 48,54 ---- + # USEDLL no or yes: set to yes to use the Runtime library DLL (no) + # For USEDLL=yes the cygwin1.dll is required to run Vim. + # For "no" the mingw-gcc-g++ package or the mingw64-i686-gcc-g++ +! # package is required to compile Vim. Or set CC to gcc-3 and add + # -L/lib/w32api to EXTRA_LIBS. + # POSTSCRIPT no or yes: set to yes for PostScript printing (no) + # FEATURES TINY, SMALL, NORMAL, BIG or HUGE (BIG) +*** ../vim-7.3.924/src/Make_mvc.mak 2013-02-26 14:56:24.000000000 +0100 +--- src/Make_mvc.mak 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 418,424 **** + !endif + !endif + +! # Abort bulding VIM if version of VC is unrecognised. + !ifndef MSVCVER + !message *** ERROR + !message Cannot determine Visual C version being used. If you are using the +--- 418,424 ---- + !endif + !endif + +! # Abort building VIM if version of VC is unrecognised. + !ifndef MSVCVER + !message *** ERROR + !message Cannot determine Visual C version being used. If you are using the +*** ../vim-7.3.924/src/Make_sas.mak 2010-08-15 21:57:27.000000000 +0200 +--- src/Make_sas.mak 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 251,257 **** + + # generate GlobalSymbolTable, which speeds up the compile time. + # +! # A preprocessing stage is used to work arounda bug in the GST generator, in + # that it does not handle nested makefiles properly in this stage. + # Ignore error message for not producing any code (105). + $(GST): scoptions vim.h keymap.h macros.h ascii.h term.h structs.h +--- 251,257 ---- + + # generate GlobalSymbolTable, which speeds up the compile time. + # +! # A preprocessing stage is used to work around a bug in the GST generator, in + # that it does not handle nested makefiles properly in this stage. + # Ignore error message for not producing any code (105). + $(GST): scoptions vim.h keymap.h macros.h ascii.h term.h structs.h +*************** +*** 283,289 **** + .c.pro: + $(CC) $(CFLAGS) GPFILE=proto/$*.pro $(PROPT) $*.c + +! # dependancies + blowfish.o: blowfish.c + proto/blowfish.pro: blowfish.c + buffer.o: buffer.c +--- 283,289 ---- + .c.pro: + $(CC) $(CFLAGS) GPFILE=proto/$*.pro $(PROPT) $*.c + +! # dependencies + blowfish.o: blowfish.c + proto/blowfish.pro: blowfish.c + buffer.o: buffer.c +*** ../vim-7.3.924/src/Make_vms.mms 2010-08-15 21:57:32.000000000 +0200 +--- src/Make_vms.mms 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 34,40 **** + # SMALL - Few features enabled, as basic as possible + # NORMAL - A default selection of features enabled + # BIG - Many features enabled, as rich as possible. (default) +! # HUGE - All possible featues enabled. + # Please select one of these alternatives above. + MODEL = HUGE + +--- 34,40 ---- + # SMALL - Few features enabled, as basic as possible + # NORMAL - A default selection of features enabled + # BIG - Many features enabled, as rich as possible. (default) +! # HUGE - All possible features enabled. + # Please select one of these alternatives above. + MODEL = HUGE + +*************** +*** 55,61 **** + # Comment out if you want the compiler version with :ver command. + # NOTE: This part can make some complications if you're using some + # predefined symbols/flags for your compiler. If does, just leave behind +! # the comment varialbe CCVER. + CCVER = YES + + # Uncomment if want a debug version. Resulting executable is DVIM.EXE +--- 55,61 ---- + # Comment out if you want the compiler version with :ver command. + # NOTE: This part can make some complications if you're using some + # predefined symbols/flags for your compiler. If does, just leave behind +! # the comment variable CCVER. + CCVER = YES + + # Uncomment if want a debug version. Resulting executable is DVIM.EXE +*** ../vim-7.3.924/src/Make_w16.mak 2013-02-26 14:56:24.000000000 +0100 +--- src/Make_w16.mak 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 4,10 **** + # ************************************************************* + # * WARNING! + # * This was originally produced by the IDE, but has since been +! # * modifed to make it work properly. Adjust with care! + # * In particular, leave LinkerLocalOptsAtW16_gvim16dexe alone + # * unless you are a guru. + # ************************************************************* +--- 4,10 ---- + # ************************************************************* + # * WARNING! + # * This was originally produced by the IDE, but has since been +! # * modified to make it work properly. Adjust with care! + # * In particular, leave LinkerLocalOptsAtW16_gvim16dexe alone + # * unless you are a guru. + # ************************************************************* +*** ../vim-7.3.924/src/Makefile 2013-02-26 14:56:24.000000000 +0100 +--- src/Makefile 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 200,206 **** + #Solaris 2.5 (sun4m) cc (SC4.0) +X11R6 +GUI (CDE) 4.6b (E) Andrew Large + #Solaris 2.5 cc +X11 +GUI Athena 4.2 (9) Sonia Heimann + #Solaris 2.5 gcc 2.5.6 +X11 Motif 5.0m (R) Ant. Colombo +! #Solaris 2.6 gcc 2.8.1 ncursus 5.3 (G) Larry W. Virden + #Solaris with -lthread 5.5 (W) K. Nagano + #Solaris gcc (b) Riccardo + #SunOS 4.1.x +X11 -GUI 5.1b (J) Bram Moolenaar +--- 200,206 ---- + #Solaris 2.5 (sun4m) cc (SC4.0) +X11R6 +GUI (CDE) 4.6b (E) Andrew Large + #Solaris 2.5 cc +X11 +GUI Athena 4.2 (9) Sonia Heimann + #Solaris 2.5 gcc 2.5.6 +X11 Motif 5.0m (R) Ant. Colombo +! #Solaris 2.6 gcc 2.8.1 ncurses 5.3 (G) Larry W. Virden + #Solaris with -lthread 5.5 (W) K. Nagano + #Solaris gcc (b) Riccardo + #SunOS 4.1.x +X11 -GUI 5.1b (J) Bram Moolenaar +*************** +*** 231,238 **** + # (D) Uncomment lines below for QNX + # (E) You might want to use termlib instead of termcap, see below. + # (F) See below for instructions. +! # (G) Using ncursus version 4.2 has reported to cause a crash. Use the +! # Sun cursus library instead. + # (H) See line for EXTRA_LIBS below. + # (I) SINIX-N 5.42 and 5.43 need some EXTRA_LIBS. Also for Reliant-Unix. + # (J) If you get undefined symbols, see below for a solution. +--- 231,238 ---- + # (D) Uncomment lines below for QNX + # (E) You might want to use termlib instead of termcap, see below. + # (F) See below for instructions. +! # (G) Using ncurses version 4.2 has reported to cause a crash. Use the +! # Sun curses library instead. + # (H) See line for EXTRA_LIBS below. + # (I) SINIX-N 5.42 and 5.43 need some EXTRA_LIBS. Also for Reliant-Unix. + # (J) If you get undefined symbols, see below for a solution. +*************** +*** 402,408 **** + # to the command line. If you see strange flags during compilation, check in + # auto/config.mk where they come from. If it's PERL_CFLAGS, try commenting + # the next line. +! # When you get an error for a missing "perl.exp" file, try creating an emtpy + # one: "touch perl.exp". + # This requires at least "small" features, "tiny" doesn't work. + #CONF_OPT_PERL = --enable-perlinterp +--- 402,408 ---- + # to the command line. If you see strange flags during compilation, check in + # auto/config.mk where they come from. If it's PERL_CFLAGS, try commenting + # the next line. +! # When you get an error for a missing "perl.exp" file, try creating an empty + # one: "touch perl.exp". + # This requires at least "small" features, "tiny" doesn't work. + #CONF_OPT_PERL = --enable-perlinterp +*************** +*** 601,607 **** + # Might not work with GUI or Perl. + # For unknown reasons adding "-lc" fixes a linking problem with some versions + # of GCC. That's probably a bug in the "-pg" implementation. +! # After running Vim see the profile result with: gmon vim gmon.out | vim - + # Need to recompile everything after changing this: "make clean" "make". + #PROFILE_CFLAGS = -pg -g -DWE_ARE_PROFILING + #PROFILE_LIBS = -pg +--- 601,607 ---- + # Might not work with GUI or Perl. + # For unknown reasons adding "-lc" fixes a linking problem with some versions + # of GCC. That's probably a bug in the "-pg" implementation. +! # After running Vim see the profile result with: gprof vim gmon.out | vim - + # Need to recompile everything after changing this: "make clean" "make". + #PROFILE_CFLAGS = -pg -g -DWE_ARE_PROFILING + #PROFILE_LIBS = -pg +*************** +*** 1294,1300 **** + ### prototype headers are ignored due to -DPROTO, system + ### headers #include <...> are ignored if we use the -MM option, as + ### e.g. provided by gcc-cpp. +! ### Include FEAT_GUI to get gependency on gui.h + ### Need to change "-I /" to "-isystem /" for GCC 3.x. + CPP_DEPEND = $(CC) -I$(srcdir) -M$(CPP_MM) \ + `echo "$(DEPEND_CFLAGS)" $(DEPEND_CFLAGS_FILTER)` +--- 1294,1300 ---- + ### prototype headers are ignored due to -DPROTO, system + ### headers #include <...> are ignored if we use the -MM option, as + ### e.g. provided by gcc-cpp. +! ### Include FEAT_GUI to get dependency on gui.h + ### Need to change "-I /" to "-isystem /" for GCC 3.x. + CPP_DEPEND = $(CC) -I$(srcdir) -M$(CPP_MM) \ + `echo "$(DEPEND_CFLAGS)" $(DEPEND_CFLAGS_FILTER)` +*************** +*** 1717,1723 **** + + + # Link the target for normal use or debugging. +! # A shell script is used to try linking without unneccesary libraries. + $(VIMTARGET): auto/config.mk objects $(OBJ) version.c version.h + $(CCC) version.c -o objects/version.o + @LINK="$(PURIFY) $(SHRPENV) $(CClink) $(ALL_LIB_DIRS) $(LDFLAGS) \ +--- 1717,1723 ---- + + + # Link the target for normal use or debugging. +! # A shell script is used to try linking without unnecessary libraries. + $(VIMTARGET): auto/config.mk objects $(OBJ) version.c version.h + $(CCC) version.c -o objects/version.o + @LINK="$(PURIFY) $(SHRPENV) $(CClink) $(ALL_LIB_DIRS) $(LDFLAGS) \ +*************** +*** 1837,1844 **** + # + # This will produce a lot of garbage on your screen, including a few error + # messages. Don't worry about that. +! # If there is a real error, there will be a difference between "test.out" and +! # a "test99.ok" file. + # If everything is alright, the final message will be "ALL DONE". If not you + # get "TEST FAILURE". + # +--- 1837,1844 ---- + # + # This will produce a lot of garbage on your screen, including a few error + # messages. Don't worry about that. +! # If there is a real error, there will be a difference between "testXX.out" and +! # a "testXX.ok" file. + # If everything is alright, the final message will be "ALL DONE". If not you + # get "TEST FAILURE". + # +*************** +*** 2779,2787 **** + mv gui_mac.rsrc.rsrcfork $(RESDIR)/$(VIMNAME).rsrc + + # po/Make_osx.pl says something about generating a Mac message file +! # for Ukrananian. Would somebody using Mac OS X in Ukranian + # *really* be upset that Carbon Vim was not localised in +! # Ukranian? + # + #bundle-language: bundle-dir po/Make_osx.pl + # cd po && perl Make_osx.pl --outdir ../$(RESDIR) $(MULTILANG) +--- 2779,2787 ---- + mv gui_mac.rsrc.rsrcfork $(RESDIR)/$(VIMNAME).rsrc + + # po/Make_osx.pl says something about generating a Mac message file +! # for Ukrainian. Would somebody using Mac OS X in Ukrainian + # *really* be upset that Carbon Vim was not localised in +! # Ukrainian? + # + #bundle-language: bundle-dir po/Make_osx.pl + # cd po && perl Make_osx.pl --outdir ../$(RESDIR) $(MULTILANG) +*** ../vim-7.3.924/src/VisVim/OleAut.cpp 2010-08-15 21:57:27.000000000 +0200 +--- src/VisVim/OleAut.cpp 2013-05-06 04:04:07.000000000 +0200 +*************** +*** 654,660 **** + } + + char Buf[256]; +! sprintf (Buf, "An OLE error occured:\r\nCode = %s\r\nResult = %lx.", + (char*) ErrName, m_hResult); + MessageBox (NULL, Buf, "OLE Error", MB_OK); + } +--- 654,660 ---- + } + + char Buf[256]; +! sprintf (Buf, "An OLE error occurred:\r\nCode = %s\r\nResult = %lx.", + (char*) ErrName, m_hResult); + MessageBox (NULL, Buf, "OLE Error", MB_OK); + } +*** ../vim-7.3.924/src/VisVim/README_VisVim.txt 2010-08-15 21:57:27.000000000 +0200 +--- src/VisVim/README_VisVim.txt 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 17,28 **** + VisVim is based upon VisEmacs by Christopher Payne + (Copyright (C) Christopher Payne 1997). + +! Author: Heiko Erhardt + Based upon: VisEmacs by Christopher Payne + Version: 1.0 + Created: 23 Oct 1997 + Date: 23 Oct 1997 + + VisVim is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2, or (at your option) +--- 17,32 ---- + VisVim is based upon VisEmacs by Christopher Payne + (Copyright (C) Christopher Payne 1997). + +! Author: Heiko Erhardt + Based upon: VisEmacs by Christopher Payne + Version: 1.0 + Created: 23 Oct 1997 + Date: 23 Oct 1997 + ++ VisVim was originally GNU GPL licensed, as stated below. On March 21 2012 ++ Heiko Erhardt declared this work to be relicensed under the Vim license, as ++ stated in ../../runtime/doc/uganda.txt (or ":help uganda" in Vim). ++ + VisVim is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2, or (at your option) +*************** +*** 216,222 **** + 2. Close Visual Studio. + 3. Delete VisVim.dll or move it somewhere it can't be found. + 4. Run Visual Studio. +! 5. Tools -> Cursomize ->Add-ins and Macro-Files. + 6. A message appears: + ".../VisVim.dll" "This add-in no longer exists. It will + no longer be displayed." +--- 220,226 ---- + 2. Close Visual Studio. + 3. Delete VisVim.dll or move it somewhere it can't be found. + 4. Run Visual Studio. +! 5. Tools -> Customize ->Add-ins and Macro-Files. + 6. A message appears: + ".../VisVim.dll" "This add-in no longer exists. It will + no longer be displayed." +*************** +*** 294,300 **** + P8 Execute :tag command in Vim for word under cursor in DevStudio + + P7 Controlling the Visual Studio Debugger from inside Vim +! See message above. Also a 'Debug' highligh group and a + command to highlight a certain line would be necessary. + + P6 Provide an option to open the current file in VisVim in +--- 298,304 ---- + P8 Execute :tag command in Vim for word under cursor in DevStudio + + P7 Controlling the Visual Studio Debugger from inside Vim +! See message above. Also a 'Debug' highlight group and a + command to highlight a certain line would be necessary. + + P6 Provide an option to open the current file in VisVim in +*************** +*** 318,322 **** + Have fun! + + Heiko Erhardt +! Heiko.Erhardt@munich.netsurf.de + +--- 322,326 ---- + Have fun! + + Heiko Erhardt +! heiko.erhardt@gmx.net + +*** ../vim-7.3.924/src/auto/configure 2013-05-04 04:40:06.000000000 +0200 +--- src/auto/configure 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 5831,5837 **** + /* If this program fails, then RTLD_GLOBAL is needed. + * RTLD_GLOBAL will be used and then it is not possible to + * have both python versions enabled in the same vim instance. +! * Only the first pyhton version used will be switched on. + */ + + int no_rtl_global_needed_for(char *python_instsoname, char *prefix) +--- 5831,5837 ---- + /* If this program fails, then RTLD_GLOBAL is needed. + * RTLD_GLOBAL will be used and then it is not possible to + * have both python versions enabled in the same vim instance. +! * Only the first python version used will be switched on. + */ + + int no_rtl_global_needed_for(char *python_instsoname, char *prefix) +*************** +*** 5897,5903 **** + /* If this program fails, then RTLD_GLOBAL is needed. + * RTLD_GLOBAL will be used and then it is not possible to + * have both python versions enabled in the same vim instance. +! * Only the first pyhton version used will be switched on. + */ + + int no_rtl_global_needed_for(char *python_instsoname, wchar_t *prefix) +--- 5897,5903 ---- + /* If this program fails, then RTLD_GLOBAL is needed. + * RTLD_GLOBAL will be used and then it is not possible to + * have both python versions enabled in the same vim instance. +! * Only the first python version used will be switched on. + */ + + int no_rtl_global_needed_for(char *python_instsoname, wchar_t *prefix) +*************** +*** 10593,10599 **** + _ACEOF + + if test "x$vim_cv_tty_mode" = "x" ; then +! as_fn_error "It seems you're cross compiling and have 'vim_cv_tty_group' set, please also set the environment variable 'vim_cv_tty_mode' to the correct mode (propably 0620)" "$LINENO" 5 + else + $as_echo "#define PTYMODE 0620" >>confdefs.h + +--- 10593,10599 ---- + _ACEOF + + if test "x$vim_cv_tty_mode" = "x" ; then +! as_fn_error "It seems you're cross compiling and have 'vim_cv_tty_group' set, please also set the environment variable 'vim_cv_tty_mode' to the correct mode (probably 0620)" "$LINENO" 5 + else + $as_echo "#define PTYMODE 0620" >>confdefs.h + +*** ../vim-7.3.924/src/buffer.c 2013-04-24 16:52:28.000000000 +0200 +--- src/buffer.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 2005,2011 **** + * "buf" if one exists */ + if (swb_flags & SWB_USEOPEN) + wp = buf_jump_open_win(buf); +! /* If 'switchbuf' contians "usetab": jump to first window in any tab + * page containing "buf" if one exists */ + if (wp == NULL && (swb_flags & SWB_USETAB)) + wp = buf_jump_open_tab(buf); +--- 2005,2011 ---- + * "buf" if one exists */ + if (swb_flags & SWB_USEOPEN) + wp = buf_jump_open_win(buf); +! /* If 'switchbuf' contains "usetab": jump to first window in any tab + * page containing "buf" if one exists */ + if (wp == NULL && (swb_flags & SWB_USETAB)) + wp = buf_jump_open_tab(buf); +*** ../vim-7.3.924/src/configure.in 2013-05-04 04:40:06.000000000 +0200 +--- src/configure.in 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 306,312 **** + AC_SUBST(line_break) + + if test "$cf_cv_ebcdic" = "yes"; then +! dnl If we have EBCDIC we most likley have z/OS Unix, let's test it! + AC_MSG_CHECKING(for z/OS Unix) + case `uname` in + OS/390) zOSUnix="yes"; +--- 306,312 ---- + AC_SUBST(line_break) + + if test "$cf_cv_ebcdic" = "yes"; then +! dnl If we have EBCDIC we most likely have z/OS Unix, let's test it! + AC_MSG_CHECKING(for z/OS Unix) + case `uname` in + OS/390) zOSUnix="yes"; +*************** +*** 1228,1234 **** + /* If this program fails, then RTLD_GLOBAL is needed. + * RTLD_GLOBAL will be used and then it is not possible to + * have both python versions enabled in the same vim instance. +! * Only the first pyhton version used will be switched on. + */ + + int no_rtl_global_needed_for(char *python_instsoname, char *prefix) +--- 1228,1234 ---- + /* If this program fails, then RTLD_GLOBAL is needed. + * RTLD_GLOBAL will be used and then it is not possible to + * have both python versions enabled in the same vim instance. +! * Only the first python version used will be switched on. + */ + + int no_rtl_global_needed_for(char *python_instsoname, char *prefix) +*************** +*** 1274,1280 **** + /* If this program fails, then RTLD_GLOBAL is needed. + * RTLD_GLOBAL will be used and then it is not possible to + * have both python versions enabled in the same vim instance. +! * Only the first pyhton version used will be switched on. + */ + + int no_rtl_global_needed_for(char *python_instsoname, wchar_t *prefix) +--- 1274,1280 ---- + /* If this program fails, then RTLD_GLOBAL is needed. + * RTLD_GLOBAL will be used and then it is not possible to + * have both python versions enabled in the same vim instance. +! * Only the first python version used will be switched on. + */ + + int no_rtl_global_needed_for(char *python_instsoname, wchar_t *prefix) +*************** +*** 3002,3008 **** + if test "x$vim_cv_tty_group" != "xworld" ; then + AC_DEFINE_UNQUOTED(PTYGROUP,$vim_cv_tty_group) + if test "x$vim_cv_tty_mode" = "x" ; then +! AC_MSG_ERROR([It seems you're cross compiling and have 'vim_cv_tty_group' set, please also set the environment variable 'vim_cv_tty_mode' to the correct mode (propably 0620)]) + else + AC_DEFINE(PTYMODE, 0620) + fi +--- 3002,3008 ---- + if test "x$vim_cv_tty_group" != "xworld" ; then + AC_DEFINE_UNQUOTED(PTYGROUP,$vim_cv_tty_group) + if test "x$vim_cv_tty_mode" = "x" ; then +! AC_MSG_ERROR([It seems you're cross compiling and have 'vim_cv_tty_group' set, please also set the environment variable 'vim_cv_tty_mode' to the correct mode (probably 0620)]) + else + AC_DEFINE(PTYMODE, 0620) + fi +*** ../vim-7.3.924/src/diff.c 2013-03-19 14:25:50.000000000 +0100 +--- src/diff.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 1110,1116 **** + } + + /* +! * Set options to show difs for the current window. + */ + void + ex_diffthis(eap) +--- 1110,1116 ---- + } + + /* +! * Set options to show diffs for the current window. + */ + void + ex_diffthis(eap) +*** ../vim-7.3.924/src/dosinst.c 2013-02-13 14:36:39.000000000 +0100 +--- src/dosinst.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 1609,1615 **** + + /* + * Only add the choice for the open-with menu entry when gvim.exe was found +! * and and regedit.exe exist. + */ + static void + init_openwith_choice(void) +--- 1609,1615 ---- + + /* + * Only add the choice for the open-with menu entry when gvim.exe was found +! * and regedit.exe exist. + */ + static void + init_openwith_choice(void) +*** ../vim-7.3.924/src/edit.c 2013-03-19 16:46:59.000000000 +0100 +--- src/edit.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 1418,1424 **** + + normalchar: + /* +! * Insert a nomal character. + */ + #ifdef FEAT_AUTOCMD + if (!p_paste) +--- 1418,1424 ---- + + normalchar: + /* +! * Insert a normal character. + */ + #ifdef FEAT_AUTOCMD + if (!p_paste) +*************** +*** 7162,7168 **** + /* + * Count each sequence of folded lines as one logical line. + */ +! /* go to the the start of the current fold */ + (void)hasFolding(lnum, &lnum, NULL); + + while (n--) +--- 7162,7168 ---- + /* + * Count each sequence of folded lines as one logical line. + */ +! /* go to the start of the current fold */ + (void)hasFolding(lnum, &lnum, NULL); + + while (n--) +*************** +*** 7213,7219 **** + (void)hasFolding(lnum, NULL, &lnum); + #endif + /* This fails if the cursor is already in the last line or would move +! * beyound the last line and '-' is in 'cpoptions' */ + if (lnum >= curbuf->b_ml.ml_line_count + || (lnum + n > curbuf->b_ml.ml_line_count + && vim_strchr(p_cpo, CPO_MINUS) != NULL)) +--- 7213,7219 ---- + (void)hasFolding(lnum, NULL, &lnum); + #endif + /* This fails if the cursor is already in the last line or would move +! * beyond the last line and '-' is in 'cpoptions' */ + if (lnum >= curbuf->b_ml.ml_line_count + || (lnum + n > curbuf->b_ml.ml_line_count + && vim_strchr(p_cpo, CPO_MINUS) != NULL)) +*************** +*** 7715,7721 **** + /* + * return TRUE if 'cinkeys' contains the key "keytyped", + * when == '*': Only if key is preceded with '*' (indent before insert) +! * when == '!': Only if key is prededed with '!' (don't insert) + * when == ' ': Only if key is not preceded with '*'(indent afterwards) + * + * "keytyped" can have a few special values: +--- 7715,7721 ---- + /* + * return TRUE if 'cinkeys' contains the key "keytyped", + * when == '*': Only if key is preceded with '*' (indent before insert) +! * when == '!': Only if key is preceded with '!' (don't insert) + * when == ' ': Only if key is not preceded with '*'(indent afterwards) + * + * "keytyped" can have a few special values: +*************** +*** 8541,8547 **** + #endif + + /* +! * key in Insert mode: toggle insert/remplace mode. + */ + static void + ins_insert(replaceState) +--- 8541,8547 ---- + #endif + + /* +! * key in Insert mode: toggle insert/replace mode. + */ + static void + ins_insert(replaceState) +*** ../vim-7.3.924/src/eval.c 2013-05-06 03:52:44.000000000 +0200 +--- src/eval.c 2013-05-06 04:07:45.000000000 +0200 +*************** +*** 16669,16675 **** + tabpage_T *save_curtab; + { + #ifdef FEAT_WINDOWS +! /* Restore current tabpage and window, if still valid (autocomands can + * make them invalid). */ + if (valid_tabpage(save_curtab)) + goto_tabpage_tp(save_curtab, TRUE); +--- 16669,16675 ---- + tabpage_T *save_curtab; + { + #ifdef FEAT_WINDOWS +! /* Restore current tabpage and window, if still valid (autocommands can + * make them invalid). */ + if (valid_tabpage(save_curtab)) + goto_tabpage_tp(save_curtab, TRUE); +*** ../vim-7.3.924/src/ex_cmds2.c 2013-03-19 16:46:59.000000000 +0100 +--- src/ex_cmds2.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 2851,2857 **** + EMSG(_(e_argreq)); + + else if (eap != NULL && eap->forceit) +! /* ":source!": read Normal mdoe commands + * Need to execute the commands directly. This is required at least + * for: + * - ":g" command busy +--- 2851,2857 ---- + EMSG(_(e_argreq)); + + else if (eap != NULL && eap->forceit) +! /* ":source!": read Normal mode commands + * Need to execute the commands directly. This is required at least + * for: + * - ":g" command busy +*** ../vim-7.3.924/src/ex_docmd.c 2013-03-19 14:25:50.000000000 +0100 +--- src/ex_docmd.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 1093,1099 **** + msg_didany = FALSE; /* no output yet */ + msg_start(); + msg_scroll = TRUE; /* put messages below each other */ +! ++no_wait_return; /* dont wait for return until finished */ + ++RedrawingDisabled; + did_inc = TRUE; + } +--- 1093,1099 ---- + msg_didany = FALSE; /* no output yet */ + msg_start(); + msg_scroll = TRUE; /* put messages below each other */ +! ++no_wait_return; /* don't wait for return until finished */ + ++RedrawingDisabled; + did_inc = TRUE; + } +*************** +*** 1298,1304 **** + && !(did_emsg + #ifdef FEAT_EVAL + /* Keep going when inside try/catch, so that the error can be +! * dealth with, except when it is a syntax error, it may cause + * the :endtry to be missed. */ + && (cstack.cs_trylevel == 0 || did_emsg_syntax) + #endif +--- 1298,1304 ---- + && !(did_emsg + #ifdef FEAT_EVAL + /* Keep going when inside try/catch, so that the error can be +! * deal with, except when it is a syntax error, it may cause + * the :endtry to be missed. */ + && (cstack.cs_trylevel == 0 || did_emsg_syntax) + #endif +*************** +*** 10982,10988 **** + *p = '/'; + } + +! /* escapse special characters */ + p = vim_strsave_fnameescape(sname, FALSE); + vim_free(sname); + if (p == NULL) +--- 10982,10988 ---- + *p = '/'; + } + +! /* escape special characters */ + p = vim_strsave_fnameescape(sname, FALSE); + vim_free(sname); + if (p == NULL) +*** ../vim-7.3.924/src/ex_eval.c 2010-08-15 21:57:25.000000000 +0200 +--- src/ex_eval.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 44,50 **** + * executed. Otherwise, errors and/or interrupts are converted into catchable + * exceptions (did_throw additionally set), which terminate the script only if + * not caught. For user exceptions, only did_throw is set. (Note: got_int can +! * be set asyncronously afterwards by a SIGINT, so did_throw && got_int is not + * a reliant test that the exception currently being thrown is an interrupt + * exception. Similarly, did_emsg can be set afterwards on an error in an + * (unskipped) conditional command inside an inactive conditional, so did_throw +--- 44,50 ---- + * executed. Otherwise, errors and/or interrupts are converted into catchable + * exceptions (did_throw additionally set), which terminate the script only if + * not caught. For user exceptions, only did_throw is set. (Note: got_int can +! * be set asynchronously afterwards by a SIGINT, so did_throw && got_int is not + * a reliant test that the exception currently being thrown is an interrupt + * exception. Similarly, did_emsg can be set afterwards on an error in an + * (unskipped) conditional command inside an inactive conditional, so did_throw +*************** +*** 2091,2101 **** + * Values used for "searched_cond" are (CSF_WHILE | CSF_FOR) or CSF_TRY or 0, + * the latter meaning the innermost try conditional not in its finally clause. + * "inclusive" tells whether the conditional searched for should be made +! * inactive itself (a try conditional not in its finally claused possibly find + * before is always made inactive). If "inclusive" is TRUE and + * "searched_cond" is CSF_TRY|CSF_SILENT, the saved former value of + * "emsg_silent", if reset when the try conditional finally reached was +! * entered, is restored (unsed by ex_endtry()). This is normally done only + * when such a try conditional is left. + */ + int +--- 2091,2101 ---- + * Values used for "searched_cond" are (CSF_WHILE | CSF_FOR) or CSF_TRY or 0, + * the latter meaning the innermost try conditional not in its finally clause. + * "inclusive" tells whether the conditional searched for should be made +! * inactive itself (a try conditional not in its finally clause possibly find + * before is always made inactive). If "inclusive" is TRUE and + * "searched_cond" is CSF_TRY|CSF_SILENT, the saved former value of + * "emsg_silent", if reset when the try conditional finally reached was +! * entered, is restored (used by ex_endtry()). This is normally done only + * when such a try conditional is left. + */ + int +*** ../vim-7.3.924/src/farsi.c 2012-07-16 17:26:18.000000000 +0200 +--- src/farsi.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 1841,1847 **** + } + + /* +! * Convert the Farsi VIM into Farsi 3342 standad. + */ + void + conv_to_pstd() +--- 1841,1847 ---- + } + + /* +! * Convert the Farsi VIM into Farsi 3342 standard. + */ + void + conv_to_pstd() +*** ../vim-7.3.924/src/feature.h 2013-04-15 15:40:08.000000000 +0200 +--- src/feature.h 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 1007,1013 **** + + /* + * MODIFIED_BY Name of who modified Vim. Required when distributing +! * a modifed version of Vim. + * Also from the "--with-modified-by" configure argument. + */ + /* #define MODIFIED_BY "John Doe" */ +--- 1007,1013 ---- + + /* + * MODIFIED_BY Name of who modified Vim. Required when distributing +! * a modified version of Vim. + * Also from the "--with-modified-by" configure argument. + */ + /* #define MODIFIED_BY "John Doe" */ +*** ../vim-7.3.924/src/fileio.c 2013-04-24 16:33:58.000000000 +0200 +--- src/fileio.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 3279,3285 **** + overwriting = FALSE; + + if (exiting) +! settmode(TMODE_COOK); /* when exiting allow typahead now */ + + ++no_wait_return; /* don't wait for return yet */ + +--- 3279,3285 ---- + overwriting = FALSE; + + if (exiting) +! settmode(TMODE_COOK); /* when exiting allow typeahead now */ + + ++no_wait_return; /* don't wait for return yet */ + +*************** +*** 3303,3309 **** + int empty_memline = (buf->b_ml.ml_mfp == NULL); + + /* +! * Apply PRE aucocommands. + * Set curbuf to the buffer to be written. + * Careful: The autocommands may call buf_write() recursively! + */ +--- 3303,3309 ---- + int empty_memline = (buf->b_ml.ml_mfp == NULL); + + /* +! * Apply PRE autocommands. + * Set curbuf to the buffer to be written. + * Careful: The autocommands may call buf_write() recursively! + */ +*************** +*** 8866,8872 **** + else + { + /* There is no window for "buf", use "aucmd_win". To minimize the side +! * effects, insert it in a the current tab page. + * Anything related to a window (e.g., setting folds) may have + * unexpected results. */ + aco->use_aucmd_win = TRUE; +--- 8866,8872 ---- + else + { + /* There is no window for "buf", use "aucmd_win". To minimize the side +! * effects, insert it in the current tab page. + * Anything related to a window (e.g., setting folds) may have + * unexpected results. */ + aco->use_aucmd_win = TRUE; +*** ../vim-7.3.924/src/glbl_ime.cpp 2010-08-15 21:57:27.000000000 +0200 +--- src/glbl_ime.cpp 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 156,162 **** + } + + /* +! * Set position of IME compotision window. + * + * You have to call this before starting composition. If once composition + * started, this can take no effect until that composition have finished. So +--- 156,162 ---- + } + + /* +! * Set position of IME composition window. + * + * You have to call this before starting composition. If once composition + * started, this can take no effect until that composition have finished. So +*** ../vim-7.3.924/src/gui.c 2013-04-03 21:11:33.000000000 +0200 +--- src/gui.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 826,832 **** + #endif + + /* +! * Set the font. "font_list" is a a comma separated list of font names. The + * first font name that works is used. If none is found, use the default + * font. + * If "fontset" is TRUE, the "font_list" is used as one name for the fontset. +--- 826,832 ---- + #endif + + /* +! * Set the font. "font_list" is a comma separated list of font names. The + * first font name that works is used. If none is found, use the default + * font. + * If "fontset" is TRUE, the "font_list" is used as one name for the fontset. +*************** +*** 2376,2382 **** + { + int start; /* index of bytes to be drawn */ + int cells; /* cellwidth of bytes to be drawn */ +! int thislen; /* length of bytes to be drawin */ + int cn; /* cellwidth of current char */ + int i; /* index of current char */ + int c; /* current char value */ +--- 2376,2382 ---- + { + int start; /* index of bytes to be drawn */ + int cells; /* cellwidth of bytes to be drawn */ +! int thislen; /* length of bytes to be drawn */ + int cn; /* cellwidth of current char */ + int i; /* index of current char */ + int c; /* current char value */ +*************** +*** 3886,3892 **** + gui.dragged_sb = SBAR_NONE; + #ifdef FEAT_GUI_GTK + /* Keep the "dragged_wp" value until after the scrolling, for when the +! * moust button is released. GTK2 doesn't send the button-up event. */ + gui.dragged_wp = NULL; + #endif + } +--- 3886,3892 ---- + gui.dragged_sb = SBAR_NONE; + #ifdef FEAT_GUI_GTK + /* Keep the "dragged_wp" value until after the scrolling, for when the +! * mouse button is released. GTK2 doesn't send the button-up event. */ + gui.dragged_wp = NULL; + #endif + } +*** ../vim-7.3.924/src/gui_athena.c 2011-01-17 20:08:03.000000000 +0100 +--- src/gui_athena.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 519,525 **** + &color[TOP_SHADOW].pixel, + &color[HIGHLIGHT].pixel); + +! /* Setup the color subsititution table */ + attrs.valuemask = XpmColorSymbols; + attrs.colorsymbols = color; + attrs.numsymbols = 5; +--- 519,525 ---- + &color[TOP_SHADOW].pixel, + &color[HIGHLIGHT].pixel); + +! /* Setup the color substitution table */ + attrs.valuemask = XpmColorSymbols; + attrs.colorsymbols = color; + attrs.numsymbols = 5; +*** ../vim-7.3.924/src/gui_beval.c 2012-10-21 00:58:34.000000000 +0200 +--- src/gui_beval.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 726,732 **** + BalloonEval *beval; + XEvent *event; + { +! Position distance; /* a measure of how much the ponter moved */ + Position delta; /* used to compute distance */ + + switch (event->type) +--- 726,732 ---- + BalloonEval *beval; + XEvent *event; + { +! Position distance; /* a measure of how much the pointer moved */ + Position delta; /* used to compute distance */ + + switch (event->type) +*** ../vim-7.3.924/src/gui_gtk_x11.c 2013-03-13 17:50:20.000000000 +0100 +--- src/gui_gtk_x11.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 1257,1263 **** + } + } + +! /* Chop off any traiing NUL bytes. OpenOffice sends these. */ + while (len > 0 && text[len - 1] == NUL) + --len; + +--- 1257,1263 ---- + } + } + +! /* Chop off any trailing NUL bytes. OpenOffice sends these. */ + while (len > 0 && text[len - 1] == NUL) + --len; + +*** ../vim-7.3.924/src/gui_mac.c 2012-11-20 17:18:56.000000000 +0100 +--- src/gui_mac.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 41,47 **** + #define USE_AEVENT /* Enable AEVENT */ + #undef USE_OFFSETED_WINDOW /* Debugging feature: start Vim window OFFSETed */ + +! /* Compile as CodeWarior External Editor */ + #if defined(FEAT_CW_EDITOR) && !defined(USE_AEVENT) + # define USE_AEVENT /* Need Apple Event Support */ + #endif +--- 41,47 ---- + #define USE_AEVENT /* Enable AEVENT */ + #undef USE_OFFSETED_WINDOW /* Debugging feature: start Vim window OFFSETed */ + +! /* Compile as CodeWarrior External Editor */ + #if defined(FEAT_CW_EDITOR) && !defined(USE_AEVENT) + # define USE_AEVENT /* Need Apple Event Support */ + #endif +*************** +*** 1478,1484 **** + /* + * gui_mac_get_menu_item_index + * +! * Returns the index inside the menu wher + */ + short /* Should we return MenuItemIndex? */ + gui_mac_get_menu_item_index(vimmenu_T *pMenu) +--- 1478,1484 ---- + /* + * gui_mac_get_menu_item_index + * +! * Returns the index inside the menu where + */ + short /* Should we return MenuItemIndex? */ + gui_mac_get_menu_item_index(vimmenu_T *pMenu) +*************** +*** 1693,1699 **** + + if (theControl != NUL) + { +! /* We hit a scollbar */ + + if (thePortion != kControlIndicatorPart) + { +--- 1693,1699 ---- + + if (theControl != NUL) + { +! /* We hit a scrollbar */ + + if (thePortion != kControlIndicatorPart) + { +*************** +*** 2630,2636 **** + { + /* Handle the menu CntxMenuID, CntxMenuItem */ + /* The submenu can be handle directly by gui_mac_handle_menu */ +! /* But what about the current menu, is the meny changed by ContextualMenuSelect */ + gui_mac_handle_menu((CntxMenuID << 16) + CntxMenuItem); + } + else if (CntxMenuID == kCMShowHelpSelected) +--- 2630,2636 ---- + { + /* Handle the menu CntxMenuID, CntxMenuItem */ + /* The submenu can be handle directly by gui_mac_handle_menu */ +! /* But what about the current menu, is the many changed by ContextualMenuSelect */ + gui_mac_handle_menu((CntxMenuID << 16) + CntxMenuItem); + } + else if (CntxMenuID == kCMShowHelpSelected) +*************** +*** 5356,5362 **** + char_u *initdir, + char_u *filter) + { +! /* TODO: Add Ammon's safety checl (Dany) */ + NavReplyRecord reply; + char_u *fname = NULL; + char_u **fnames = NULL; +--- 5356,5362 ---- + char_u *initdir, + char_u *filter) + { +! /* TODO: Add Ammon's safety check (Dany) */ + NavReplyRecord reply; + char_u *fname = NULL; + char_u **fnames = NULL; +*************** +*** 5704,5710 **** + + /* Resize the button to fit its name */ + width = StringWidth(name) + 2 * dfltButtonEdge; +! /* Limite the size of any button to an acceptable value. */ + /* TODO: Should be based on the message width */ + if (width > maxButtonWidth) + width = maxButtonWidth; +--- 5704,5710 ---- + + /* Resize the button to fit its name */ + width = StringWidth(name) + 2 * dfltButtonEdge; +! /* Limit the size of any button to an acceptable value. */ + /* TODO: Should be based on the message width */ + if (width > maxButtonWidth) + width = maxButtonWidth; +*************** +*** 5887,5893 **** + /* Free the modal filterProc */ + DisposeRoutineDescriptor(dialogUPP); + +! /* Get ride of th edialog (free memory) */ + DisposeDialog(theDialog); + + return itemHit; +--- 5887,5893 ---- + /* Free the modal filterProc */ + DisposeRoutineDescriptor(dialogUPP); + +! /* Get ride of the dialog (free memory) */ + DisposeDialog(theDialog); + + return itemHit; +*************** +*** 5967,5975 **** + /* New way */ + + /* +! * Get first devoice with one button. +! * This will probably be the standad mouse +! * startat head of cursor dev list + * + */ + +--- 5967,5975 ---- + /* New way */ + + /* +! * Get first device with one button. +! * This will probably be the standard mouse +! * start at head of cursor dev list + * + */ + +*************** +*** 6151,6157 **** + } + + /* +! * Convert a FSSpec to a fuill path + */ + + char_u *FullPathFromFSSpec_save(FSSpec file) +--- 6151,6157 ---- + } + + /* +! * Convert a FSSpec to a full path + */ + + char_u *FullPathFromFSSpec_save(FSSpec file) +*************** +*** 6215,6222 **** + + #ifdef USE_UNIXFILENAME + /* +! * The function used here are available in Carbon, but +! * do nothing une MacOS 8 and 9 + */ + if (error == fnfErr) + { +--- 6215,6222 ---- + + #ifdef USE_UNIXFILENAME + /* +! * The functions used here are available in Carbon, but do nothing on +! * MacOS 8 and 9. + */ + if (error == fnfErr) + { +*************** +*** 6544,6550 **** + + // when the tabline is hidden, vim doesn't call update_tabline(). When + // the tabline is shown again, show_tabline() is called before update_tabline(), +! // and because of this, the tab labels and vims internal tabs are out of sync + // for a very short time. to prevent inconsistent state, we store the labels + // of the tabs, not pointers to the tabs (which are invalid for a short time). + static CFStringRef *tabLabels = NULL; +--- 6544,6550 ---- + + // when the tabline is hidden, vim doesn't call update_tabline(). When + // the tabline is shown again, show_tabline() is called before update_tabline(), +! // and because of this, the tab labels and vim's internal tabs are out of sync + // for a very short time. to prevent inconsistent state, we store the labels + // of the tabs, not pointers to the tabs (which are invalid for a short time). + static CFStringRef *tabLabels = NULL; +*************** +*** 6578,6584 **** + + // assert(property == kTabsColumn); // why is this violated?? + +! // changeValue is true if we have a modifieable list and data was changed. + // In our case, it's always false. + // (that is: if (changeValue) updateInternalData(); else return + // internalData(); +--- 6578,6584 ---- + + // assert(property == kTabsColumn); // why is this violated?? + +! // changeValue is true if we have a modifiable list and data was changed. + // In our case, it's always false. + // (that is: if (changeValue) updateInternalData(); else return + // internalData(); +*** ../vim-7.3.924/src/gui_motif.c 2011-01-17 20:08:03.000000000 +0100 +--- src/gui_motif.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 1344,1350 **** + else + { + /* Without shadows one can't sense whatever the button has been +! * pressed or not! However we wan't to save a bit of space... + * Need the highlightThickness to see the focus. + */ + XtSetArg(args[n], XmNhighlightThickness, 1); n++; +--- 1344,1350 ---- + else + { + /* Without shadows one can't sense whatever the button has been +! * pressed or not! However we want to save a bit of space... + * Need the highlightThickness to see the focus. + */ + XtSetArg(args[n], XmNhighlightThickness, 1); n++; +*************** +*** 3205,3211 **** + # ifdef FEAT_FOOTER + /* + * The next toolbar enter/leave callbacks should really do balloon help. But +! * I have to use footer help for backwards compatability. Hopefully both will + * get implemented and the user will have a choice. + */ + static void +--- 3205,3211 ---- + # ifdef FEAT_FOOTER + /* + * The next toolbar enter/leave callbacks should really do balloon help. But +! * I have to use footer help for backwards compatibility. Hopefully both will + * get implemented and the user will have a choice. + */ + static void +*** ../vim-7.3.924/src/gui_photon.c 2012-11-20 16:53:34.000000000 +0100 +--- src/gui_photon.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 61,67 **** + static PhPoint_t gui_ph_raw_offset; + static PtWidget_t *gui_ph_timer_cursor; /* handle cursor blinking */ + static PtWidget_t *gui_ph_timer_timeout; /* used in gui_mch_wait_for_chars */ +! static short is_timeout; /* Has the timeout occured? */ + + /* + * This is set inside the mouse callback for a right mouse +--- 61,67 ---- + static PhPoint_t gui_ph_raw_offset; + static PtWidget_t *gui_ph_timer_cursor; /* handle cursor blinking */ + static PtWidget_t *gui_ph_timer_timeout; /* used in gui_mch_wait_for_chars */ +! static short is_timeout; /* Has the timeout occurred? */ + + /* + * This is set inside the mouse callback for a right mouse +*************** +*** 1156,1162 **** + PtSetArg(&args[ n++ ], Pt_ARG_POS, &pos, 0); + + #ifdef USE_PANEL_GROUP +! /* Put in a temprary place holder title */ + PtSetArg(&args[ n++ ], Pt_ARG_PG_PANEL_TITLES, &empty_title, 1); + + gui.vimPanelGroup = PtCreateWidget(PtPanelGroup, gui.vimWindow, n, args); +--- 1156,1162 ---- + PtSetArg(&args[ n++ ], Pt_ARG_POS, &pos, 0); + + #ifdef USE_PANEL_GROUP +! /* Put in a temporary place holder title */ + PtSetArg(&args[ n++ ], Pt_ARG_PG_PANEL_TITLES, &empty_title, 1); + + gui.vimPanelGroup = PtCreateWidget(PtPanelGroup, gui.vimWindow, n, args); +*************** +*** 1527,1533 **** + /* There is one less separator than buttons, so bump up the button count */ + button_count = 1; + +! /* Count string length and number of seperators */ + for (str = buttons; *str; str++) + { + len++; +--- 1527,1533 ---- + /* There is one less separator than buttons, so bump up the button count */ + button_count = 1; + +! /* Count string length and number of separators */ + for (str = buttons; *str; str++) + { + len++; +*** ../vim-7.3.924/src/gui_w16.c 2012-11-20 16:53:34.000000000 +0100 +--- src/gui_w16.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 511,517 **** + workarea_rect.right = GetSystemMetrics(SM_CXSCREEN); + workarea_rect.bottom = GetSystemMetrics(SM_CYFULLSCREEN); + +! /* get current posision of our window */ + wndpl.length = sizeof(WINDOWPLACEMENT); + GetWindowPlacement(s_hwnd, &wndpl); + if (wndpl.showCmd == SW_SHOWNORMAL) +--- 511,517 ---- + workarea_rect.right = GetSystemMetrics(SM_CXSCREEN); + workarea_rect.bottom = GetSystemMetrics(SM_CYFULLSCREEN); + +! /* get current position of our window */ + wndpl.length = sizeof(WINDOWPLACEMENT); + GetWindowPlacement(s_hwnd, &wndpl); + if (wndpl.showCmd == SW_SHOWNORMAL) +*************** +*** 1161,1167 **** + return -1; + + /* +! * make a copy of 'buttons' to fiddle with it. complier grizzles because + * vim_strsave() doesn't take a const arg (why not?), so cast away the + * const. + */ +--- 1161,1167 ---- + return -1; + + /* +! * make a copy of 'buttons' to fiddle with it. compiler grizzles because + * vim_strsave() doesn't take a const arg (why not?), so cast away the + * const. + */ +*** ../vim-7.3.924/src/gui_w32.c 2013-03-19 14:48:25.000000000 +0100 +--- src/gui_w32.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 1258,1264 **** + + #ifdef FEAT_NETBEANS_INTG + { +! /* stolen from gui_x11.x */ + int arg; + + for (arg = 1; arg < *argc; arg++) +--- 1258,1264 ---- + + #ifdef FEAT_NETBEANS_INTG + { +! /* stolen from gui_x11.c */ + int arg; + + for (arg = 1; arg < *argc; arg++) +*************** +*** 1676,1682 **** + * used by the taskbar or appbars. */ + get_work_area(&workarea_rect); + +! /* Get current posision of our window. Note that the .left and .top are + * relative to the work area. */ + wndpl.length = sizeof(WINDOWPLACEMENT); + GetWindowPlacement(s_hwnd, &wndpl); +--- 1676,1682 ---- + * used by the taskbar or appbars. */ + get_work_area(&workarea_rect); + +! /* Get current position of our window. Note that the .left and .top are + * relative to the work area. */ + wndpl.length = sizeof(WINDOWPLACEMENT); + GetWindowPlacement(s_hwnd, &wndpl); +*************** +*** 3100,3106 **** + return -1; + + /* +! * make a copy of 'buttons' to fiddle with it. complier grizzles because + * vim_strsave() doesn't take a const arg (why not?), so cast away the + * const. + */ +--- 3100,3106 ---- + return -1; + + /* +! * make a copy of 'buttons' to fiddle with it. compiler grizzles because + * vim_strsave() doesn't take a const arg (why not?), so cast away the + * const. + */ +*************** +*** 4391,4397 **** + } + + sign.hImage = NULL; +! ext = signfile + STRLEN(signfile) - 4; /* get extention */ + if (ext > signfile) + { + int do_load = 1; +--- 4391,4397 ---- + } + + sign.hImage = NULL; +! ext = signfile + STRLEN(signfile) - 4; /* get extension */ + if (ext > signfile) + { + int do_load = 1; +*** ../vim-7.3.924/src/gui_w48.c 2013-03-19 14:48:25.000000000 +0100 +--- src/gui_w48.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 1222,1228 **** + + /* When side scroll bar is unshown, the size of window will change. + * then, the text area move left or right. thus client rect should be +! * forcely redraw. (Yasuhiro Matsumoto) */ + if (oldx != x || oldy != y) + { + InvalidateRect(s_hwnd, NULL, FALSE); +--- 1222,1228 ---- + + /* When side scroll bar is unshown, the size of window will change. + * then, the text area move left or right. thus client rect should be +! * forcedly redrawn. (Yasuhiro Matsumoto) */ + if (oldx != x || oldy != y) + { + InvalidateRect(s_hwnd, NULL, FALSE); +*** ../vim-7.3.924/src/gui_xmebw.c 2012-06-29 13:19:23.000000000 +0200 +--- src/gui_xmebw.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 345,351 **** + &eb->primitive.top_shadow_color, + &eb->primitive.highlight_color); + +! /* Setup color subsititution table. */ + color[0].pixel = eb->core.background_pixel; + color[1].pixel = eb->core.background_pixel; + color[2].pixel = eb->core.background_pixel; +--- 345,351 ---- + &eb->primitive.top_shadow_color, + &eb->primitive.highlight_color); + +! /* Setup color substitution table. */ + color[0].pixel = eb->core.background_pixel; + color[1].pixel = eb->core.background_pixel; + color[2].pixel = eb->core.background_pixel; +*************** +*** 919,926 **** + } + + /* +! * Plase note that we manipulate the width only in case of push buttons not +! * used in the context of a menu pane. + */ + if (Lab_IsMenupane(newtb)) + { +--- 919,926 ---- + } + + /* +! * Please note that we manipulate the width only in case of push buttons +! * not used in the context of a menu pane. + */ + if (Lab_IsMenupane(newtb)) + { +*************** +*** 1006,1012 **** + XmString str; + set_pixmap(eb); + +! /* FIXME: this is not the perfect way to deal with menues, which do not + * have any string set right now. */ + str = XmStringCreateLocalized(""); + XtVaSetValues((Widget) eb, XmNlabelString, str, NULL); +--- 1006,1012 ---- + XmString str; + set_pixmap(eb); + +! /* FIXME: this is not the perfect way to deal with menus, which do not + * have any string set right now. */ + str = XmStringCreateLocalized(""); + XtVaSetValues((Widget) eb, XmNlabelString, str, NULL); +*** ../vim-7.3.924/src/gui_xmebwp.h 2010-08-15 21:57:27.000000000 +0200 +--- src/gui_xmebwp.h 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 26,32 **** + + + /* +! * EnahncedButton class structure. + */ + typedef struct _XmEnhancedButtonClassPart + { +--- 26,32 ---- + + + /* +! * EnhancedButton class structure. + */ + typedef struct _XmEnhancedButtonClassPart + { +*************** +*** 49,55 **** + extern XmEnhancedButtonClassRec xmEnhancedButtonClassRec; + + /* +! * EnahncedButton instance record. + */ + typedef struct _XmEnhancedButtonPart + { +--- 49,55 ---- + extern XmEnhancedButtonClassRec xmEnhancedButtonClassRec; + + /* +! * EnhancedButton instance record. + */ + typedef struct _XmEnhancedButtonPart + { +*** ../vim-7.3.924/src/hardcopy.c 2011-04-11 21:35:03.000000000 +0200 +--- src/hardcopy.c 2013-05-06 04:00:47.000000000 +0200 +*************** +*** 2186,2192 **** + if (num_copies > 1) + { + prt_write_string(" numcopies("); +! /* Note: no space wanted so dont use prt_write_int() */ + sprintf((char *)prt_line_buffer, "%d", num_copies); + prt_write_file(prt_line_buffer); + prt_write_string(")"); +--- 2186,2192 ---- + if (num_copies > 1) + { + prt_write_string(" numcopies("); +! /* Note: no space wanted so don't use prt_write_int() */ + sprintf((char *)prt_line_buffer, "%d", num_copies); + prt_write_file(prt_line_buffer); + prt_write_string(")"); +*** ../vim-7.3.924/src/if_cscope.c 2011-06-12 21:24:56.000000000 +0200 +--- src/if_cscope.c 2013-05-06 03:58:29.000000000 +0200 +*************** +*** 1192,1200 **** + if (nummatches == NULL) + return FALSE; + +! /* send query to all open connections, then count the total number +! * of matches so we can alloc matchesp all in one swell foop +! */ + for (i = 0; i < csinfo_size; i++) + nummatches[i] = 0; + totmatches = 0; +--- 1192,1199 ---- + if (nummatches == NULL) + return FALSE; + +! /* Send query to all open connections, then count the total number +! * of matches so we can alloc all in one swell foop. */ + for (i = 0; i < csinfo_size; i++) + nummatches[i] = 0; + totmatches = 0; +*** ../vim-7.3.924/src/if_mzsch.c 2013-01-31 21:09:10.000000000 +0100 +--- src/if_mzsch.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 3053,3059 **** + status = FAIL; + else + { +! /* add the value in advance to allow handling of self-referencial + * data structures */ + typval_T *visited_tv = (typval_T *)alloc(sizeof(typval_T)); + copy_tv(tv, visited_tv); +--- 3053,3059 ---- + status = FAIL; + else + { +! /* add the value in advance to allow handling of self-referential + * data structures */ + typval_T *visited_tv = (typval_T *)alloc(sizeof(typval_T)); + copy_tv(tv, visited_tv); +*************** +*** 3088,3094 **** + if (status == FAIL) + break; + } +! /* impoper list not terminated with null + * need to handle the last element */ + if (status == OK && !SCHEME_NULLP(curr)) + { +--- 3088,3094 ---- + if (status == FAIL) + break; + } +! /* improper list not terminated with null + * need to handle the last element */ + if (status == OK && !SCHEME_NULLP(curr)) + { +*************** +*** 3136,3142 **** + { + if (((Scheme_Hash_Table *) obj)->vals[i] != NULL) + { +! /* generate item for `diplay'ed Scheme key */ + dictitem_T *item = dictitem_alloc((char_u *)string_to_line( + ((Scheme_Hash_Table *) obj)->keys[i])); + /* convert Scheme val to Vim and add it to the dict */ +--- 3136,3142 ---- + { + if (((Scheme_Hash_Table *) obj)->vals[i] != NULL) + { +! /* generate item for `display'ed Scheme key */ + dictitem_T *item = dictitem_alloc((char_u *)string_to_line( + ((Scheme_Hash_Table *) obj)->keys[i])); + /* convert Scheme val to Vim and add it to the dict */ +*** ../vim-7.3.924/src/if_ole.cpp 2010-08-15 21:57:32.000000000 +0200 +--- src/if_ole.cpp 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 645,651 **** + CoTaskMemFree(wGUID); + } + +! // Delete a key and all of its descendents + static void RecursiveDeleteKey(HKEY hKeyParent, const char *child) + { + // Open the child +--- 645,651 ---- + CoTaskMemFree(wGUID); + } + +! // Delete a key and all of its descendants + static void RecursiveDeleteKey(HKEY hKeyParent, const char *child) + { + // Open the child +*************** +*** 655,661 **** + if (result != ERROR_SUCCESS) + return; + +! // Enumerate all of the decendents of this child + FILETIME time; + char buffer[1024]; + DWORD size = 1024; +--- 655,661 ---- + if (result != ERROR_SUCCESS) + return; + +! // Enumerate all of the descendants of this child + FILETIME time; + char buffer[1024]; + DWORD size = 1024; +*************** +*** 663,669 **** + while (RegEnumKeyEx(hKeyChild, 0, buffer, &size, NULL, + NULL, NULL, &time) == S_OK) + { +! // Delete the decendents of this child + RecursiveDeleteKey(hKeyChild, buffer); + size = 256; + } +--- 663,669 ---- + while (RegEnumKeyEx(hKeyChild, 0, buffer, &size, NULL, + NULL, NULL, &time) == S_OK) + { +! // Delete the descendants of this child + RecursiveDeleteKey(hKeyChild, buffer); + size = 256; + } +*** ../vim-7.3.924/src/if_perl.xs 2013-03-19 14:25:50.000000000 +0100 +--- src/if_perl.xs 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 657,663 **** + + /* + * perl_win_free +! * Remove all refences to the window to be destroyed + */ + void + perl_win_free(wp) +--- 657,663 ---- + + /* + * perl_win_free +! * Remove all references to the window to be destroyed + */ + void + perl_win_free(wp) +*** ../vim-7.3.924/src/if_py_both.h 2013-05-06 03:52:44.000000000 +0200 +--- src/if_py_both.h 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 2160,2166 **** + static int + SetBufferLine(buf_T *buf, PyInt n, PyObject *line, PyInt *len_change) + { +! /* First of all, we check the thpe of the supplied Python object. + * There are three cases: + * 1. NULL, or None - this is a deletion. + * 2. A string - this is a replacement. +--- 2160,2166 ---- + static int + SetBufferLine(buf_T *buf, PyInt n, PyObject *line, PyInt *len_change) + { +! /* First of all, we check the type of the supplied Python object. + * There are three cases: + * 1. NULL, or None - this is a deletion. + * 2. A string - this is a replacement. +*************** +*** 2251,2257 **** + static int + SetBufferLineList(buf_T *buf, PyInt lo, PyInt hi, PyObject *list, PyInt *len_change) + { +! /* First of all, we check the thpe of the supplied Python object. + * There are three cases: + * 1. NULL, or None - this is a deletion. + * 2. A list - this is a replacement. +--- 2251,2257 ---- + static int + SetBufferLineList(buf_T *buf, PyInt lo, PyInt hi, PyObject *list, PyInt *len_change) + { +! /* First of all, we check the type of the supplied Python object. + * There are three cases: + * 1. NULL, or None - this is a deletion. + * 2. A list - this is a replacement. +*************** +*** 2428,2434 **** + } + } + +! /* Insert a number of lines into the specified buffer after the specifed line. + * The line number is in Vim format (1-based). The lines to be inserted are + * given as a Python list of string objects or as a single string. The lines + * to be added are checked for validity and correct format. Errors are +--- 2428,2434 ---- + } + } + +! /* Insert a number of lines into the specified buffer after the specified line. + * The line number is in Vim format (1-based). The lines to be inserted are + * given as a Python list of string objects or as a single string. The lines + * to be added are checked for validity and correct format. Errors are +*************** +*** 2819,2825 **** + return NULL; + } + +! /* Ckeck for keyboard interrupt */ + if (VimErrorCheck()) + return NULL; + +--- 2819,2825 ---- + return NULL; + } + +! /* Check for keyboard interrupt */ + if (VimErrorCheck()) + return NULL; + +*** ../vim-7.3.924/src/if_python.c 2013-05-06 03:52:44.000000000 +0200 +--- src/if_python.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 773,779 **** + + /* Remove the element from sys.path that was added because of our + * argv[0] value in PythonMod_Init(). Previously we used an empty +! * string, but dependinding on the OS we then get an empty entry or + * the current directory in sys.path. */ + PyRun_SimpleString("import sys; sys.path = filter(lambda x: x != '/must>not&exist', sys.path)"); + +--- 773,779 ---- + + /* Remove the element from sys.path that was added because of our + * argv[0] value in PythonMod_Init(). Previously we used an empty +! * string, but depending on the OS we then get an empty entry or + * the current directory in sys.path. */ + PyRun_SimpleString("import sys; sys.path = filter(lambda x: x != '/must>not&exist', sys.path)"); + +*** ../vim-7.3.924/src/if_python3.c 2013-05-06 03:52:44.000000000 +0200 +--- src/if_python3.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 766,772 **** + + /* Remove the element from sys.path that was added because of our + * argv[0] value in Py3Init_vim(). Previously we used an empty +! * string, but dependinding on the OS we then get an empty entry or + * the current directory in sys.path. + * Only after vim has been imported, the element does exist in + * sys.path. +--- 766,772 ---- + + /* Remove the element from sys.path that was added because of our + * argv[0] value in Py3Init_vim(). Previously we used an empty +! * string, but depending on the OS we then get an empty entry or + * the current directory in sys.path. + * Only after vim has been imported, the element does exist in + * sys.path. +*** ../vim-7.3.924/src/if_ruby.c 2013-04-14 16:18:52.000000000 +0200 +--- src/if_ruby.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 113,119 **** + #endif + + /* +! * Backward compatiblity for Ruby 1.8 and earlier. + * Ruby 1.9 does not provide STR2CSTR, instead StringValuePtr is provided. + * Ruby 1.9 does not provide RXXX(s)->len and RXXX(s)->ptr, instead + * RXXX_LEN(s) and RXXX_PTR(s) are provided. +--- 113,119 ---- + #endif + + /* +! * Backward compatibility for Ruby 1.8 and earlier. + * Ruby 1.9 does not provide STR2CSTR, instead StringValuePtr is provided. + * Ruby 1.9 does not provide RXXX(s)->len and RXXX(s)->ptr, instead + * RXXX_LEN(s) and RXXX_PTR(s) are provided. +*************** +*** 1333,1339 **** + rb_global_variable(&objtbl); + + /* The Vim module used to be called "VIM", but "Vim" is better. Make an +! * alias "VIM" for backwards compatiblity. */ + mVIM = rb_define_module("Vim"); + rb_define_const(rb_cObject, "VIM", mVIM); + rb_define_const(mVIM, "VERSION_MAJOR", INT2NUM(VIM_VERSION_MAJOR)); +--- 1333,1339 ---- + rb_global_variable(&objtbl); + + /* The Vim module used to be called "VIM", but "Vim" is better. Make an +! * alias "VIM" for backwards compatibility. */ + mVIM = rb_define_module("Vim"); + rb_define_const(rb_cObject, "VIM", mVIM); + rb_define_const(mVIM, "VERSION_MAJOR", INT2NUM(VIM_VERSION_MAJOR)); +*** ../vim-7.3.924/src/main.aap 2010-08-15 21:57:28.000000000 +0200 +--- src/main.aap 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 1213,1221 **** + :move gui_mac.rsrc.rsrcfork $(RESDIR)/$(VIMNAME).rsrc + + # po/Make_osx.pl says something about generating a Mac message file +! # for Ukrananian. Would somebody using Mac OS X in Ukranian + # *really* be upset that Carbon Vim was not localised in +! # Ukranian? + # + #bundle-language: bundle-dir po/Make_osx.pl + # cd po && perl Make_osx.pl --outdir ../$(RESDIR) $(MULTILANG) +--- 1213,1221 ---- + :move gui_mac.rsrc.rsrcfork $(RESDIR)/$(VIMNAME).rsrc + + # po/Make_osx.pl says something about generating a Mac message file +! # for Ukrainian. Would somebody using Mac OS X in Ukrainian + # *really* be upset that Carbon Vim was not localised in +! # Ukrainian? + # + #bundle-language: bundle-dir po/Make_osx.pl + # cd po && perl Make_osx.pl --outdir ../$(RESDIR) $(MULTILANG) +*** ../vim-7.3.924/src/mbyte.c 2013-02-26 14:56:24.000000000 +0100 +--- src/mbyte.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 903,909 **** + { + switch (enc_dbcs) + { +! /* please add classfy routine for your language in here */ + + case DBCS_JPNU: /* ? */ + case DBCS_JPN: +--- 903,909 ---- + { + switch (enc_dbcs) + { +! /* please add classify routine for your language in here */ + + case DBCS_JPNU: /* ? */ + case DBCS_JPN: +*************** +*** 1003,1009 **** + * 26 : Box Drawings + * 27 : Unit Symbols + * 28 : Circled/Parenthesized Letter +! * 29 : Hirigana/Katakana + * 30 : Cyrillic Letter + */ + +--- 1003,1009 ---- + * 26 : Box Drawings + * 27 : Unit Symbols + * 28 : Circled/Parenthesized Letter +! * 29 : Hiragana/Katakana + * 30 : Cyrillic Letter + */ + +*************** +*** 1054,1060 **** + return 28; + case 0xAA: + case 0xAB: +! /* Hirigana/Katakana */ + return 29; + case 0xAC: + /* Cyrillic Letter */ +--- 1054,1060 ---- + return 28; + case 0xAA: + case 0xAB: +! /* Hiragana/Katakana */ + return 29; + case 0xAC: + /* Cyrillic Letter */ +*************** +*** 4599,4605 **** + } + + /* The thing which setting "preedit_start_col" to MAXCOL means that +! * "preedit_start_col" will be set forcely when calling + * preedit_changed_cb() next time. + * "preedit_start_col" should not reset with MAXCOL on this part. Vim + * is simulating the preediting by using add_to_input_str(). when +--- 4599,4605 ---- + } + + /* The thing which setting "preedit_start_col" to MAXCOL means that +! * "preedit_start_col" will be set forcedly when calling + * preedit_changed_cb() next time. + * "preedit_start_col" should not reset with MAXCOL on this part. Vim + * is simulating the preediting by using add_to_input_str(). when +*** ../vim-7.3.924/src/memfile.c 2011-05-10 16:41:13.000000000 +0200 +--- src/memfile.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 628,634 **** + * sync from the system itself). + */ + # if defined(__EMX__) +! error "Dont use fsync with EMX! Read emxdoc.doc or emxfix01.doc for info." + # endif + if (STRCMP(p_sws, "fsync") == 0) + { +--- 628,634 ---- + * sync from the system itself). + */ + # if defined(__EMX__) +! error "Don't use fsync with EMX! Read emxdoc.doc or emxfix01.doc for info." + # endif + if (STRCMP(p_sws, "fsync") == 0) + { +*************** +*** 1075,1081 **** + if (nr > mfp->mf_infile_count) /* beyond end of file */ + { + nr = mfp->mf_infile_count; +! hp2 = mf_find_hash(mfp, nr); /* NULL catched below */ + } + else + hp2 = hp; +--- 1075,1081 ---- + if (nr > mfp->mf_infile_count) /* beyond end of file */ + { + nr = mfp->mf_infile_count; +! hp2 = mf_find_hash(mfp, nr); /* NULL caught below */ + } + else + hp2 = hp; +*************** +*** 1184,1190 **** + { + new_bnum = freep->bh_bnum; + /* +! * If the page count of the free block was larger, recude it. + * If the page count matches, remove the block from the free list + */ + if (freep->bh_page_count > page_count) +--- 1184,1190 ---- + { + new_bnum = freep->bh_bnum; + /* +! * If the page count of the free block was larger, reduce it. + * If the page count matches, remove the block from the free list + */ + if (freep->bh_page_count > page_count) +*************** +*** 1309,1315 **** + mf_set_ffname(mfp); + #if defined(MSDOS) || defined(MSWIN) + /* +! * A ":!cd e:xxx" may change the directory without us knowning, use the + * full pathname always. Careful: This frees fname! + */ + mf_fullname(mfp); +--- 1309,1315 ---- + mf_set_ffname(mfp); + #if defined(MSDOS) || defined(MSWIN) + /* +! * A ":!cd e:xxx" may change the directory without us knowing, use the + * full pathname always. Careful: This frees fname! + */ + mf_fullname(mfp); +*** ../vim-7.3.924/src/memline.c 2012-10-03 18:24:55.000000000 +0200 +--- src/memline.c 2013-05-06 04:01:02.000000000 +0200 +*************** +*** 3141,3147 **** + ) + set_keep_msg((char_u *)_(no_lines_msg), 0); + +! /* FEAT_BYTEOFF already handled in there, dont worry 'bout it below */ + i = ml_replace((linenr_T)1, (char_u *)"", TRUE); + buf->b_ml.ml_flags |= ML_EMPTY; + +--- 3141,3147 ---- + ) + set_keep_msg((char_u *)_(no_lines_msg), 0); + +! /* FEAT_BYTEOFF already handled in there, don't worry 'bout it below */ + i = ml_replace((linenr_T)1, (char_u *)"", TRUE); + buf->b_ml.ml_flags |= ML_EMPTY; + +*** ../vim-7.3.924/src/misc1.c 2013-05-04 03:40:22.000000000 +0200 +--- src/misc1.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 1654,1660 **** + if (vim_iswhite(string[0])) + { + if (i == 0 || !vim_iswhite(line[i - 1])) +! continue; /* missing shite space */ + while (vim_iswhite(string[0])) + ++string; + } +--- 1654,1660 ---- + if (vim_iswhite(string[0])) + { + if (i == 0 || !vim_iswhite(line[i - 1])) +! continue; /* missing white space */ + while (vim_iswhite(string[0])) + ++string; + } +*** ../vim-7.3.924/src/misc2.c 2013-04-12 14:42:35.000000000 +0200 +--- src/misc2.c 2013-05-06 03:59:29.000000000 +0200 +*************** +*** 2907,2913 **** + int modifiers = *modp; + + #ifdef MACOS +! /* Command-key really special, No fancynest */ + if (!(modifiers & MOD_MASK_CMD)) + #endif + if ((modifiers & MOD_MASK_SHIFT) && ASCII_ISALPHA(key)) +--- 2907,2913 ---- + int modifiers = *modp; + + #ifdef MACOS +! /* Command-key really special, no fancynest */ + if (!(modifiers & MOD_MASK_CMD)) + #endif + if ((modifiers & MOD_MASK_SHIFT) && ASCII_ISALPHA(key)) +*************** +*** 2934,2940 **** + key = K_ZERO; + } + #ifdef MACOS +! /* Command-key really special, No fancynest */ + if (!(modifiers & MOD_MASK_CMD)) + #endif + if ((modifiers & MOD_MASK_ALT) && key < 0x80 +--- 2934,2940 ---- + key = K_ZERO; + } + #ifdef MACOS +! /* Command-key really special, no fancynest */ + if (!(modifiers & MOD_MASK_CMD)) + #endif + if ((modifiers & MOD_MASK_ALT) && key < 0x80 +*** ../vim-7.3.924/src/nbdebug.c 2010-08-15 21:57:29.000000000 +0200 +--- src/nbdebug.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 17,23 **** + * debugging startup problems because gvim will be started automatically from + * netbeans and cannot be run directly from a debugger. The only way to debug + * a gvim started by netbeans is by attaching a debugger to it. Without this +! * tool all starup code will have completed before you can get the pid and + * attach. + * + * The second tool is a log tool. +--- 17,23 ---- + * debugging startup problems because gvim will be started automatically from + * netbeans and cannot be run directly from a debugger. The only way to debug + * a gvim started by netbeans is by attaching a debugger to it. Without this +! * tool all startup code will have completed before you can get the pid and + * attach. + * + * The second tool is a log tool. +*** ../vim-7.3.924/src/normal.c 2013-04-24 18:34:40.000000000 +0200 +--- src/normal.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 2513,2519 **** + + #ifndef FEAT_VISUAL + /* +! * ALT is only used for starging/extending Visual mode. + */ + if ((mod_mask & MOD_MASK_ALT)) + return FALSE; +--- 2513,2519 ---- + + #ifndef FEAT_VISUAL + /* +! * ALT is only used for starting/extending Visual mode. + */ + if ((mod_mask & MOD_MASK_ALT)) + return FALSE; +*************** +*** 5084,5090 **** + } + break; + +! /* "zE": erease all folds */ + case 'E': if (foldmethodIsManual(curwin)) + { + clearFolding(curwin); +--- 5084,5090 ---- + } + break; + +! /* "zE": erase all folds */ + case 'E': if (foldmethodIsManual(curwin)) + { + clearFolding(curwin); +*************** +*** 7465,7471 **** + static char_u trans[] = "YyDdCcxdXdAAIIrr"; + + /* Uppercase means linewise, except in block mode, then "D" deletes till +! * the end of the line, and "C" replaces til EOL */ + if (isupper(cap->cmdchar)) + { + if (VIsual_mode != Ctrl_V) +--- 7465,7471 ---- + static char_u trans[] = "YyDdCcxdXdAAIIrr"; + + /* Uppercase means linewise, except in block mode, then "D" deletes till +! * the end of the line, and "C" replaces till EOL */ + if (isupper(cap->cmdchar)) + { + if (VIsual_mode != Ctrl_V) +*************** +*** 8804,8810 **** + * at first, but it's really more what we mean when we say + * 'cw'. + * Another strangeness: When standing on the end of a word +! * "ce" will change until the end of the next wordt, but "cw" + * will change only one character! This is done by setting + * flag. + */ +--- 8804,8810 ---- + * at first, but it's really more what we mean when we say + * 'cw'. + * Another strangeness: When standing on the end of a word +! * "ce" will change until the end of the next word, but "cw" + * will change only one character! This is done by setting + * flag. + */ +*************** +*** 9150,9156 **** + { + int save_State = State; + +! /* Pretent Insert mode here to allow the cursor on the + * character past the end of the line */ + State = INSERT; + coladvance((colnr_T)MAXCOL); +--- 9150,9156 ---- + { + int save_State = State; + +! /* Pretend Insert mode here to allow the cursor on the + * character past the end of the line */ + State = INSERT; + coladvance((colnr_T)MAXCOL); +*************** +*** 9189,9195 **** + { + int save_State = State; + +! /* Pretent Insert mode here to allow the cursor on the + * character past the end of the line */ + State = INSERT; + coladvance(getviscol()); +--- 9189,9195 ---- + { + int save_State = State; + +! /* Pretend Insert mode here to allow the cursor on the + * character past the end of the line */ + State = INSERT; + coladvance(getviscol()); +*** ../vim-7.3.924/src/ops.c 2013-03-13 17:50:20.000000000 +0100 +--- src/ops.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 398,404 **** + #ifdef FEAT_RIGHTLEFT + int old_p_ri = p_ri; + +! p_ri = 0; /* don't want revins in ident */ + #endif + + State = INSERT; /* don't want REPLACE for State */ +--- 398,404 ---- + #ifdef FEAT_RIGHTLEFT + int old_p_ri = p_ri; + +! p_ri = 0; /* don't want revins in indent */ + #endif + + State = INSERT; /* don't want REPLACE for State */ +*** ../vim-7.3.924/src/os_amiga.c 2012-11-20 16:53:34.000000000 +0100 +--- src/os_amiga.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 118,124 **** + } + + /* +! * mch_inchar(): low level input funcion. + * Get a characters from the keyboard. + * If time == 0 do not wait for characters. + * If time == n wait a short time for characters. +--- 118,124 ---- + } + + /* +! * mch_inchar(): low level input function. + * Get a characters from the keyboard. + * If time == 0 do not wait for characters. + * If time == n wait a short time for characters. +*** ../vim-7.3.924/src/os_mac.h 2010-08-15 21:57:32.000000000 +0200 +--- src/os_mac.h 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 45,51 **** + /* Get stat.h or something similar. Comment: How come some OS get in in vim.h */ + # include + /* && defined(HAVE_CURSE) */ +! /* The curses.h from MacOS X provides by default some BACKWARD compatibilty + * definition which can cause us problem later on. So we undefine a few of them. */ + # include + # undef reg +--- 45,51 ---- + /* Get stat.h or something similar. Comment: How come some OS get in in vim.h */ + # include + /* && defined(HAVE_CURSE) */ +! /* The curses.h from MacOS X provides by default some BACKWARD compatibility + * definition which can cause us problem later on. So we undefine a few of them. */ + # include + # undef reg +*** ../vim-7.3.924/src/os_msdos.c 2012-11-20 16:53:34.000000000 +0100 +--- src/os_msdos.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 702,708 **** + * If Vim should work over the serial line after a 'ctty com1' we must use + * kbhit() and getch(). (jw) + * Usually kbhit() is not used, because then CTRL-C and CTRL-P +! * will be catched by DOS (mool). + * + * return TRUE if a character is available, FALSE otherwise + */ +--- 702,708 ---- + * If Vim should work over the serial line after a 'ctty com1' we must use + * kbhit() and getch(). (jw) + * Usually kbhit() is not used, because then CTRL-C and CTRL-P +! * will be caught by DOS (mool). + * + * return TRUE if a character is available, FALSE otherwise + */ +*************** +*** 971,977 **** + } + + /* +! * mch_inchar(): low level input funcion. + * Get a characters from the keyboard. + * If time == 0 do not wait for characters. + * If time == n wait a short time for characters. +--- 971,977 ---- + } + + /* +! * mch_inchar(): low level input function. + * Get a characters from the keyboard. + * If time == 0 do not wait for characters. + * If time == n wait a short time for characters. +*************** +*** 993,999 **** + + /* + * if we got a ctrl-C when we were busy, there will be a "^C" somewhere +! * on the sceen, so we need to redisplay it. + */ + if (delayed_redraw) + { +--- 993,999 ---- + + /* + * if we got a ctrl-C when we were busy, there will be a "^C" somewhere +! * on the screen, so we need to redisplay it. + */ + if (delayed_redraw) + { +*************** +*** 1745,1751 **** + mch_setmouse(int on) + { + mouse_active = on; +! mouse_hidden = TRUE; /* dont show it until moved */ + } + #endif + +--- 1745,1751 ---- + mch_setmouse(int on) + { + mouse_active = on; +! mouse_hidden = TRUE; /* don't show it until moved */ + } + #endif + +*************** +*** 2438,2444 **** + long start_time; + int tick_count; + +! /* int 02xf, AX = 0x1701 attempts to open the Windows clipboard. Upon + * return from the interrupt, if AX is non-zero, the clipboard was + * successfully opened. If AX is zero, the clipboard could not be opened + * because it is currently in use by another process. +--- 2438,2444 ---- + long start_time; + int tick_count; + +! /* int 0x2f, AX = 0x1701 attempts to open the Windows clipboard. Upon + * return from the interrupt, if AX is non-zero, the clipboard was + * successfully opened. If AX is zero, the clipboard could not be opened + * because it is currently in use by another process. +*************** +*** 2533,2539 **** + { + __dpmi_regs dpmi_regs; + +! /* int 02xf, AX = 0x1702 attempts to empty the Windows clipboard. Upon + * return from the interrupt, if AX == 0, the clipboard could not be + * emptied (for some reason). + */ +--- 2533,2539 ---- + { + __dpmi_regs dpmi_regs; + +! /* int 0x2f, AX = 0x1702 attempts to empty the Windows clipboard. Upon + * return from the interrupt, if AX == 0, the clipboard could not be + * emptied (for some reason). + */ +*************** +*** 2616,2622 **** + case CF_TEXT: /* Windows text */ + case CF_OEMTEXT: /* DOS (OEM) text */ + +! /* int 02xf, AX = 0x1704 returns the number of bytes of data currently + * on the Windows clipboard, for the specified format. Upon return + * from the interrupt, DX:AX = the number of bytes, rounded up to the + * nearest multiple of 32. +--- 2616,2622 ---- + case CF_TEXT: /* Windows text */ + case CF_OEMTEXT: /* DOS (OEM) text */ + +! /* int 0x2f, AX = 0x1704 returns the number of bytes of data currently + * on the Windows clipboard, for the specified format. Upon return + * from the interrupt, DX:AX = the number of bytes, rounded up to the + * nearest multiple of 32. +*************** +*** 2820,2826 **** + clip_data_size); /* how many bytes to copy */ + + /* Send data from the DOS transfer buffer to the Windows clipboard. +! * int 02xf, AX = 0x1703 sends SI:CX bytes of data from the buffer + * at ES:BX, to the clipboard. + */ + dpmi_regs.x.ax = 0x1703; /* send clipboard data */ +--- 2820,2826 ---- + clip_data_size); /* how many bytes to copy */ + + /* Send data from the DOS transfer buffer to the Windows clipboard. +! * int 0x2f, AX = 0x1703 sends SI:CX bytes of data from the buffer + * at ES:BX, to the clipboard. + */ + dpmi_regs.x.ax = 0x1703; /* send clipboard data */ +*** ../vim-7.3.924/src/os_mswin.c 2013-03-19 14:48:25.000000000 +0100 +--- src/os_mswin.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 1794,1800 **** + * + * So we create a hidden window, and arrange to destroy it on exit. + */ +! HWND message_window = 0; /* window that's handling messsages */ + + #define VIM_CLASSNAME "VIM_MESSAGES" + #define VIM_CLASSNAME_LEN (sizeof(VIM_CLASSNAME) - 1) +--- 1794,1800 ---- + * + * So we create a hidden window, and arrange to destroy it on exit. + */ +! HWND message_window = 0; /* window that's handling messages */ + + #define VIM_CLASSNAME "VIM_MESSAGES" + #define VIM_CLASSNAME_LEN (sizeof(VIM_CLASSNAME) - 1) +*************** +*** 1857,1863 **** + + static int save_reply(HWND server, char_u *reply, int expr); + +! /*s + * The window procedure for the hidden message window. + * It handles callback messages and notifications from servers. + * In order to process these messages, it is necessary to run a +--- 1857,1863 ---- + + static int save_reply(HWND server, char_u *reply, int expr); + +! /* + * The window procedure for the hidden message window. + * It handles callback messages and notifications from servers. + * In order to process these messages, it is necessary to run a +*************** +*** 2603,2609 **** + + ReleaseDC(hwnd, hdc); + +! /* If we couldn't find a useable font, return failure */ + if (n == 1) + return FAIL; + +--- 2603,2609 ---- + + ReleaseDC(hwnd, hdc); + +! /* If we couldn't find a usable font, return failure */ + if (n == 1) + return FAIL; + +*** ../vim-7.3.924/src/os_win16.h 2012-11-20 16:53:34.000000000 +0100 +--- src/os_win16.h 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 50,56 **** + #endif + + /* toupper() is not really broken, but it's very slow. Probably because of +! * using unicde characters on Windows NT */ + #define BROKEN_TOUPPER + + #define FNAME_ILLEGAL "\"*?><|" /* illegal characters in a file name */ +--- 50,56 ---- + #endif + + /* toupper() is not really broken, but it's very slow. Probably because of +! * using unicode characters on Windows NT */ + #define BROKEN_TOUPPER + + #define FNAME_ILLEGAL "\"*?><|" /* illegal characters in a file name */ +*** ../vim-7.3.924/src/os_win32.c 2013-03-19 14:48:25.000000000 +0100 +--- src/os_win32.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 161,167 **** + + #ifndef PROTO + +! /* Enable common dialogs input unicode from IME if posible. */ + #ifdef FEAT_MBYTE + LRESULT (WINAPI *pDispatchMessage)(CONST MSG *) = DispatchMessage; + BOOL (WINAPI *pGetMessage)(LPMSG, HWND, UINT, UINT) = GetMessage; +--- 161,167 ---- + + #ifndef PROTO + +! /* Enable common dialogs input unicode from IME if possible. */ + #ifdef FEAT_MBYTE + LRESULT (WINAPI *pDispatchMessage)(CONST MSG *) = DispatchMessage; + BOOL (WINAPI *pGetMessage)(LPMSG, HWND, UINT, UINT) = GetMessage; +*************** +*** 1032,1038 **** + DWORD dwLR = (pmer->dwButtonState & LEFT_RIGHT); + + /* if either left or right button only is pressed, see if the +! * the next mouse event has both of them pressed */ + if (dwLR == LEFT || dwLR == RIGHT) + { + for (;;) +--- 1032,1038 ---- + DWORD dwLR = (pmer->dwButtonState & LEFT_RIGHT); + + /* if either left or right button only is pressed, see if the +! * next mouse event has both of them pressed */ + if (dwLR == LEFT || dwLR == RIGHT) + { + for (;;) +*** ../vim-7.3.924/src/os_win32.h 2013-03-19 14:48:25.000000000 +0100 +--- src/os_win32.h 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 201,207 **** + + #ifndef PROTO + +! /* Enable common dialogs input unicode from IME if posible. */ + #ifdef FEAT_MBYTE + /* The variables are defined in os_win32.c. */ + extern LRESULT (WINAPI *pDispatchMessage)(CONST MSG *); +--- 201,207 ---- + + #ifndef PROTO + +! /* Enable common dialogs input unicode from IME if possible. */ + #ifdef FEAT_MBYTE + /* The variables are defined in os_win32.c. */ + extern LRESULT (WINAPI *pDispatchMessage)(CONST MSG *); +*** ../vim-7.3.924/src/quickfix.c 2013-03-07 16:32:49.000000000 +0100 +--- src/quickfix.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 3235,3241 **** + mch_dirname(dirname_start, MAXPATHL); + + #ifdef FEAT_AUTOCMD +! /* Remeber the value of qf_start, so that we can check for autocommands + * changing the current quickfix list. */ + cur_qf_start = qi->qf_lists[qi->qf_curlist].qf_start; + #endif +--- 3235,3241 ---- + mch_dirname(dirname_start, MAXPATHL); + + #ifdef FEAT_AUTOCMD +! /* Remember the value of qf_start, so that we can check for autocommands + * changing the current quickfix list. */ + cur_qf_start = qi->qf_lists[qi->qf_curlist].qf_start; + #endif +*** ../vim-7.3.924/src/screen.c 2013-02-13 12:15:59.000000000 +0100 +--- src/screen.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 4044,4050 **** + + /* If a double-width char doesn't fit at the left side display + * a '<' in the first column. Don't do this for unprintable +! * charactes. */ + if (n_skip > 0 && mb_l > 1 && n_extra == 0) + { + n_extra = 1; +--- 4044,4050 ---- + + /* If a double-width char doesn't fit at the left side display + * a '<' in the first column. Don't do this for unprintable +! * characters. */ + if (n_skip > 0 && mb_l > 1 && n_extra == 0) + { + n_extra = 1; +*** ../vim-7.3.924/src/search.c 2013-04-03 21:14:25.000000000 +0200 +--- src/search.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 73,79 **** + { + char_u *pat; /* the pattern (in allocated memory) or NULL */ + int magic; /* magicness of the pattern */ +! int no_scs; /* no smarcase for this pattern */ + struct soffset off; + }; + +--- 73,79 ---- + { + char_u *pat; /* the pattern (in allocated memory) or NULL */ + int magic; /* magicness of the pattern */ +! int no_scs; /* no smartcase for this pattern */ + struct soffset off; + }; + +*************** +*** 3546,3552 **** + + /* + * Find block under the cursor, cursor at end. +! * "what" and "other" are two matching parenthesis/paren/etc. + */ + int + current_block(oap, count, include, what, other) +--- 3546,3552 ---- + + /* + * Find block under the cursor, cursor at end. +! * "what" and "other" are two matching parenthesis/brace/etc. + */ + int + current_block(oap, count, include, what, other) +*** ../vim-7.3.924/src/spell.c 2012-06-29 12:57:03.000000000 +0200 +--- src/spell.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 4228,4234 **** + ga_init2(&ga, sizeof(langp_T), 2); + clear_midword(wp); + +! /* Make a copy of 'spellang', the SpellFileMissing autocommands may change + * it under our fingers. */ + spl_copy = vim_strsave(wp->w_s->b_p_spl); + if (spl_copy == NULL) +--- 4228,4234 ---- + ga_init2(&ga, sizeof(langp_T), 2); + clear_midword(wp); + +! /* Make a copy of 'spelllang', the SpellFileMissing autocommands may change + * it under our fingers. */ + spl_copy = vim_strsave(wp->w_s->b_p_spl); + if (spl_copy == NULL) +*************** +*** 7645,7651 **** + + /* Compress both trees. Either they both have many nodes, which makes + * compression useful, or one of them is small, which means +! * compression goes fast. But when filling the souldfold word tree + * there is no keep-case tree. */ + wordtree_compress(spin, spin->si_foldroot); + if (affixID >= 0) +--- 7645,7651 ---- + + /* Compress both trees. Either they both have many nodes, which makes + * compression useful, or one of them is small, which means +! * compression goes fast. But when filling the soundfold word tree + * there is no keep-case tree. */ + wordtree_compress(spin, spin->si_foldroot); + if (affixID >= 0) +*************** +*** 8671,8677 **** + unsigned words_done = 0; + int wordcount[MAXWLEN]; + +! /* We use si_foldroot for the souldfolded trie. */ + spin->si_foldroot = wordtree_alloc(spin); + if (spin->si_foldroot == NULL) + return FAIL; +--- 8671,8677 ---- + unsigned words_done = 0; + int wordcount[MAXWLEN]; + +! /* We use si_foldroot for the soundfolded trie. */ + spin->si_foldroot = wordtree_alloc(spin); + if (spin->si_foldroot == NULL) + return FAIL; +*************** +*** 13019,13025 **** + + /* + * Combine the list of suggestions in su->su_ga and su->su_sga. +! * They are intwined. + */ + static void + score_combine(su) +--- 13019,13025 ---- + + /* + * Combine the list of suggestions in su->su_ga and su->su_sga. +! * They are entwined. + */ + static void + score_combine(su) +*************** +*** 13457,13463 **** + + /* Add a small penalty for changing the first letter from + * lower to upper case. Helps for "tath" -> "Kath", which is +! * less common thatn "tath" -> "path". Don't do it when the + * letter is the same, that has already been counted. */ + gc = PTR2CHAR(p); + if (SPELL_ISUPPER(gc)) +--- 13457,13463 ---- + + /* Add a small penalty for changing the first letter from + * lower to upper case. Helps for "tath" -> "Kath", which is +! * less common than "tath" -> "path". Don't do it when the + * letter is the same, that has already been counted. */ + gc = PTR2CHAR(p); + if (SPELL_ISUPPER(gc)) +*** ../vim-7.3.924/src/structs.h 2013-04-15 12:27:30.000000000 +0200 +--- src/structs.h 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 1215,1221 **** + #ifdef FEAT_SYN_HL + hashtab_T b_keywtab; /* syntax keywords hash table */ + hashtab_T b_keywtab_ic; /* idem, ignore case */ +! int b_syn_error; /* TRUE when error occured in HL */ + int b_syn_ic; /* ignore case for :syn cmds */ + int b_syn_spell; /* SYNSPL_ values */ + garray_T b_syn_patterns; /* table for syntax patterns */ +--- 1215,1221 ---- + #ifdef FEAT_SYN_HL + hashtab_T b_keywtab; /* syntax keywords hash table */ + hashtab_T b_keywtab_ic; /* idem, ignore case */ +! int b_syn_error; /* TRUE when error occurred in HL */ + int b_syn_ic; /* ignore case for :syn cmds */ + int b_syn_spell; /* SYNSPL_ values */ + garray_T b_syn_patterns; /* table for syntax patterns */ +*** ../vim-7.3.924/src/syntax.c 2013-05-04 03:42:30.000000000 +0200 +--- src/syntax.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 6069,6075 **** + static int depth = 0; + int r; + +! /* If spp has a "containedin" list and "cur_si" is in it, return TRUE. */ + if (cur_si != NULL && ssp->cont_in_list != NULL + && !(cur_si->si_flags & HL_MATCH)) + { +--- 6069,6075 ---- + static int depth = 0; + int r; + +! /* If ssp has a "containedin" list and "cur_si" is in it, return TRUE. */ + if (cur_si != NULL && ssp->cont_in_list != NULL + && !(cur_si->si_flags & HL_MATCH)) + { +*** ../vim-7.3.924/src/window.c 2013-04-15 15:55:15.000000000 +0200 +--- src/window.c 2013-05-06 04:06:04.000000000 +0200 +*************** +*** 3687,3693 **** + + /* + * Prepare for leaving the current tab page. +! * When autocomands change "curtab" we don't leave the tab page and return + * FAIL. + * Careful: When OK is returned need to get a new tab page very very soon! + */ +--- 3687,3693 ---- + + /* + * Prepare for leaving the current tab page. +! * When autocommands change "curtab" we don't leave the tab page and return + * FAIL. + * Careful: When OK is returned need to get a new tab page very very soon! + */ +*** ../vim-7.3.924/vimtutor.com 2010-08-15 21:57:32.000000000 +0200 +--- vimtutor.com 2013-05-06 04:04:07.000000000 +0200 +*************** +*** 30,36 **** + $ ! + $ if f$search ("vim:vim.exe") .eqs. "" + $ then +! $ write sys$error "Error - Can't run tutoral. VIM not found." + $ exit + $ endif + $ ! +--- 30,36 ---- + $ ! + $ if f$search ("vim:vim.exe") .eqs. "" + $ then +! $ write sys$error "Error - Can't run tutorial. VIM not found." + $ exit + $ endif + $ ! +*** ../vim-7.3.924/src/version.c 2013-05-06 03:52:44.000000000 +0200 +--- src/version.c 2013-05-06 04:03:10.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 925, + /**/ + +-- + A KNIGHT rides into shot and hacks him to the ground. He rides off. + We stay for a moment on the glade. A MIDDLE-AGED LADY in a C. & A. + twin-set emerges from the trees and looks in horror at the body of her + HUSBAND. +MRS HISTORIAN: FRANK! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e623a34843ada41cbf2eedf0566a04c11f21fb32 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:52 +0200 Subject: [PATCH 0816/3340] - patchlevel 926 --- 7.3.926 | 905 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 905 insertions(+) create mode 100644 7.3.926 diff --git a/7.3.926 b/7.3.926 new file mode 100644 index 00000000..f0d6cc3e --- /dev/null +++ b/7.3.926 @@ -0,0 +1,905 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.926 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.926 +Problem: Autocommands are triggered by setwinvar() et al. Missing BufEnter + on :tabclose. Duplicate WinEnter on :tabclose. Wrong order of + events for :tablose and :tabnew. +Solution: Fix these autocommand events. (Zyx) +Files: runtime/doc/eval.txt, src/buffer.c, src/eval.c, src/ex_cmds2.c, + src/fileio.c, src/proto/window.pro, src/testdir/test62.in, + src/testdir/test62.ok, src/window.c + + +*** ../vim-7.3.925/runtime/doc/eval.txt 2013-02-20 21:11:14.000000000 +0100 +--- runtime/doc/eval.txt 2013-05-06 04:33:13.000000000 +0200 +*************** +*** 5294,5301 **** + |t:var| + Note that the variable name without "t:" must be used. + Tabs are numbered starting with one. +- Vim briefly goes to the tab page {tabnr}, this may trigger +- TabLeave and TabEnter autocommands. + This function is not available in the |sandbox|. + + settabwinvar({tabnr}, {winnr}, {varname}, {val}) *settabwinvar()* +--- 5320,5325 ---- +*************** +*** 5308,5315 **** + doesn't work for a global or local buffer variable. + For a local buffer option the global value is unchanged. + Note that the variable name without "w:" must be used. +- Vim briefly goes to the tab page {tabnr}, this may trigger +- TabLeave and TabEnter autocommands. + Examples: > + :call settabwinvar(1, 1, "&list", 0) + :call settabwinvar(3, 2, "myvar", "foobar") +--- 5332,5337 ---- +*** ../vim-7.3.925/src/buffer.c 2013-05-06 04:21:35.000000000 +0200 +--- src/buffer.c 2013-05-06 04:33:13.000000000 +0200 +*************** +*** 4551,4557 **** + * When the ":tab" modifier was used do this for all tab pages. + */ + if (had_tab > 0) +! goto_tabpage_tp(first_tabpage, TRUE); + for (;;) + { + tpnext = curtab->tp_next; +--- 4551,4557 ---- + * When the ":tab" modifier was used do this for all tab pages. + */ + if (had_tab > 0) +! goto_tabpage_tp(first_tabpage, TRUE, TRUE); + for (;;) + { + tpnext = curtab->tp_next; +*************** +*** 4663,4669 **** + if (!valid_tabpage(tpnext)) + tpnext = first_tabpage; /* start all over...*/ + # endif +! goto_tabpage_tp(tpnext, TRUE); + } + + /* +--- 4663,4669 ---- + if (!valid_tabpage(tpnext)) + tpnext = first_tabpage; /* start all over...*/ + # endif +! goto_tabpage_tp(tpnext, TRUE, TRUE); + } + + /* +*************** +*** 4767,4779 **** + if (last_curtab != new_curtab) + { + if (valid_tabpage(last_curtab)) +! goto_tabpage_tp(last_curtab, TRUE); + if (win_valid(last_curwin)) + win_enter(last_curwin, FALSE); + } + /* to window with first arg */ + if (valid_tabpage(new_curtab)) +! goto_tabpage_tp(new_curtab, TRUE); + if (win_valid(new_curwin)) + win_enter(new_curwin, FALSE); + +--- 4767,4779 ---- + if (last_curtab != new_curtab) + { + if (valid_tabpage(last_curtab)) +! goto_tabpage_tp(last_curtab, TRUE, TRUE); + if (win_valid(last_curwin)) + win_enter(last_curwin, FALSE); + } + /* to window with first arg */ + if (valid_tabpage(new_curtab)) +! goto_tabpage_tp(new_curtab, TRUE, TRUE); + if (win_valid(new_curwin)) + win_enter(new_curwin, FALSE); + +*************** +*** 4825,4831 **** + */ + #ifdef FEAT_WINDOWS + if (had_tab > 0) +! goto_tabpage_tp(first_tabpage, TRUE); + for (;;) + { + #endif +--- 4825,4831 ---- + */ + #ifdef FEAT_WINDOWS + if (had_tab > 0) +! goto_tabpage_tp(first_tabpage, TRUE, TRUE); + for (;;) + { + #endif +*************** +*** 4865,4871 **** + /* Without the ":tab" modifier only do the current tab page. */ + if (had_tab == 0 || tpnext == NULL) + break; +! goto_tabpage_tp(tpnext, TRUE); + } + #endif + +--- 4865,4871 ---- + /* Without the ":tab" modifier only do the current tab page. */ + if (had_tab == 0 || tpnext == NULL) + break; +! goto_tabpage_tp(tpnext, TRUE, TRUE); + } + #endif + +*** ../vim-7.3.925/src/eval.c 2013-05-06 04:21:35.000000000 +0200 +--- src/eval.c 2013-05-06 04:33:13.000000000 +0200 +*************** +*** 16604,16610 **** + if (tp != NULL && varname != NULL && varp != NULL) + { + save_curtab = curtab; +! goto_tabpage_tp(tp, TRUE); + + tabvarname = alloc((unsigned)STRLEN(varname) + 3); + if (tabvarname != NULL) +--- 16604,16610 ---- + if (tp != NULL && varname != NULL && varp != NULL) + { + save_curtab = curtab; +! goto_tabpage_tp(tp, FALSE, FALSE); + + tabvarname = alloc((unsigned)STRLEN(varname) + 3); + if (tabvarname != NULL) +*************** +*** 16617,16623 **** + + /* Restore current tabpage */ + if (valid_tabpage(save_curtab)) +! goto_tabpage_tp(save_curtab, TRUE); + } + } + +--- 16617,16623 ---- + + /* Restore current tabpage */ + if (valid_tabpage(save_curtab)) +! goto_tabpage_tp(save_curtab, FALSE, FALSE); + } + } + +*************** +*** 16654,16660 **** + /* set curwin to be our win, temporarily */ + *save_curwin = curwin; + *save_curtab = curtab; +! goto_tabpage_tp(tp, TRUE); + if (!win_valid(win)) + return FAIL; + curwin = win; +--- 16654,16660 ---- + /* set curwin to be our win, temporarily */ + *save_curwin = curwin; + *save_curtab = curtab; +! goto_tabpage_tp(tp, FALSE, FALSE); + if (!win_valid(win)) + return FAIL; + curwin = win; +*************** +*** 16672,16678 **** + /* Restore current tabpage and window, if still valid (autocommands can + * make them invalid). */ + if (valid_tabpage(save_curtab)) +! goto_tabpage_tp(save_curtab, TRUE); + if (win_valid(save_curwin)) + { + curwin = save_curwin; +--- 16672,16678 ---- + /* Restore current tabpage and window, if still valid (autocommands can + * make them invalid). */ + if (valid_tabpage(save_curtab)) +! goto_tabpage_tp(save_curtab, FALSE, FALSE); + if (win_valid(save_curwin)) + { + curwin = save_curwin; +*** ../vim-7.3.925/src/ex_cmds2.c 2013-05-06 04:21:35.000000000 +0200 +--- src/ex_cmds2.c 2013-05-06 04:33:13.000000000 +0200 +*************** +*** 2482,2488 **** + /* go to window "tp" */ + if (!valid_tabpage(tp)) + break; +! goto_tabpage_tp(tp, TRUE); + tp = tp->tp_next; + } + #endif +--- 2482,2488 ---- + /* go to window "tp" */ + if (!valid_tabpage(tp)) + break; +! goto_tabpage_tp(tp, TRUE, TRUE); + tp = tp->tp_next; + } + #endif +*** ../vim-7.3.925/src/fileio.c 2013-05-06 04:21:35.000000000 +0200 +--- src/fileio.c 2013-05-06 04:33:13.000000000 +0200 +*************** +*** 8934,8940 **** + if (wp == aucmd_win) + { + if (tp != curtab) +! goto_tabpage_tp(tp, TRUE); + win_goto(aucmd_win); + goto win_found; + } +--- 8934,8940 ---- + if (wp == aucmd_win) + { + if (tp != curtab) +! goto_tabpage_tp(tp, TRUE, TRUE); + win_goto(aucmd_win); + goto win_found; + } +*** ../vim-7.3.925/src/proto/window.pro 2012-07-19 18:05:40.000000000 +0200 +--- src/proto/window.pro 2013-05-06 04:33:13.000000000 +0200 +*************** +*** 27,33 **** + tabpage_T *find_tabpage __ARGS((int n)); + int tabpage_index __ARGS((tabpage_T *ftp)); + void goto_tabpage __ARGS((int n)); +! void goto_tabpage_tp __ARGS((tabpage_T *tp, int trigger_autocmds)); + void goto_tabpage_win __ARGS((tabpage_T *tp, win_T *wp)); + void tabpage_move __ARGS((int nr)); + void win_goto __ARGS((win_T *wp)); +--- 27,33 ---- + tabpage_T *find_tabpage __ARGS((int n)); + int tabpage_index __ARGS((tabpage_T *ftp)); + void goto_tabpage __ARGS((int n)); +! void goto_tabpage_tp __ARGS((tabpage_T *tp, int trigger_enter_autocmds, int trigger_leave_autocmds)); + void goto_tabpage_win __ARGS((tabpage_T *tp, win_T *wp)); + void tabpage_move __ARGS((int nr)); + void win_goto __ARGS((win_T *wp)); +*** ../vim-7.3.925/src/testdir/test62.in 2012-07-06 18:27:34.000000000 +0200 +--- src/testdir/test62.in 2013-05-06 04:35:08.000000000 +0200 +*************** +*** 120,125 **** +--- 120,187 ---- + :endtry + i=a  + :" ++ :" Test autocommands ++ :tabonly! ++ :let g:r=[] ++ :command -nargs=1 -bar C :call add(g:r, '=== ' . . ' ===')| ++ :function Test() ++ let hasau=has('autocmd') ++ if hasau ++ autocmd TabEnter * :call add(g:r, 'TabEnter') ++ autocmd WinEnter * :call add(g:r, 'WinEnter') ++ autocmd BufEnter * :call add(g:r, 'BufEnter') ++ autocmd TabLeave * :call add(g:r, 'TabLeave') ++ autocmd WinLeave * :call add(g:r, 'WinLeave') ++ autocmd BufLeave * :call add(g:r, 'BufLeave') ++ endif ++ let t:a='a' ++ C tab split ++ if !hasau ++ let g:r+=['WinLeave', 'TabLeave', 'WinEnter', 'TabEnter'] ++ endif ++ let t:a='b' ++ C tabnew ++ if !hasau ++ let g:r+=['WinLeave', 'TabLeave', 'WinEnter', 'TabEnter', 'BufLeave', 'BufEnter'] ++ endif ++ let t:a='c' ++ call add(g:r, join(map(range(1, tabpagenr('$')), 'gettabvar(v:val, "a")'))) ++ C call map(range(1, tabpagenr('$')), 'settabvar(v:val, "a", v:val*2)') ++ call add(g:r, join(map(range(1, tabpagenr('$')), 'gettabvar(v:val, "a")'))) ++ let w:a='a' ++ C vsplit ++ if !hasau ++ let g:r+=['WinLeave', 'WinEnter'] ++ endif ++ let w:a='a' ++ let tabn=tabpagenr() ++ let winr=range(1, winnr('$')) ++ C tabnext 1 ++ if !hasau ++ let g:r+=['BufLeave', 'WinLeave', 'TabLeave', 'WinEnter', 'TabEnter', 'BufEnter'] ++ endif ++ call add(g:r, join(map(copy(winr), 'gettabwinvar('.tabn.', v:val, "a")'))) ++ C call map(copy(winr), 'settabwinvar('.tabn.', v:val, "a", v:val*2)') ++ call add(g:r, join(map(copy(winr), 'gettabwinvar('.tabn.', v:val, "a")'))) ++ if hasau ++ augroup TabDestructive ++ autocmd TabEnter * :C tabnext 2 | C tabclose 3 ++ augroup END ++ C tabnext 3 ++ let g:r+=[tabpagenr().'/'.tabpagenr('$')] ++ autocmd! TabDestructive TabEnter ++ C tabnew ++ C tabnext 1 ++ autocmd TabDestructive TabEnter * nested :C tabnext 2 | C tabclose 3 ++ C tabnext 3 ++ let g:r+=[tabpagenr().'/'.tabpagenr('$')] ++ else ++ let g:r+=["=== tabnext 3 ===","BufLeave","WinLeave","TabLeave","WinEnter","TabEnter","=== tabnext 2 ===","=== tabclose 3 ===","2/2","=== tabnew ===","WinLeave","TabLeave","WinEnter","TabEnter","BufLeave","BufEnter","=== tabnext 1 ===","BufLeave","WinLeave","TabLeave","WinEnter","TabEnter","BufEnter","=== tabnext 3 ===","BufLeave","WinLeave","TabLeave","WinEnter","TabEnter","=== tabnext 2 ===","BufLeave","WinLeave","TabLeave","WinEnter","TabEnter","=== tabnext 2 ===","=== tabclose 3 ===","BufEnter","=== tabclose 3 ===","2/2",] ++ endif ++ endfunction ++ :call Test() ++ :$ put =g:r ++ :" + :" + :/^Results/,$w! test.out + :qa! +*** ../vim-7.3.925/src/testdir/test62.ok 2012-07-06 18:27:34.000000000 +0200 +--- src/testdir/test62.ok 2013-05-06 04:35:08.000000000 +0200 +*************** +*** 18,20 **** +--- 18,88 ---- + 4 + 6 + E474 caught. ++ === tab split === ++ WinLeave ++ TabLeave ++ WinEnter ++ TabEnter ++ === tabnew === ++ WinLeave ++ TabLeave ++ WinEnter ++ TabEnter ++ BufLeave ++ BufEnter ++ a b c ++ === call map(range(1, tabpagenr('$')), 'settabvar(v:val, === ++ a b c ++ === vsplit === ++ WinLeave ++ WinEnter ++ === tabnext 1 === ++ BufLeave ++ WinLeave ++ TabLeave ++ WinEnter ++ TabEnter ++ BufEnter ++ a a ++ === call map(copy(winr), 'settabwinvar('.tabn.', v:val, === ++ a a ++ === tabnext 3 === ++ BufLeave ++ WinLeave ++ TabLeave ++ WinEnter ++ TabEnter ++ === tabnext 2 === ++ === tabclose 3 === ++ 2/2 ++ === tabnew === ++ WinLeave ++ TabLeave ++ WinEnter ++ TabEnter ++ BufLeave ++ BufEnter ++ === tabnext 1 === ++ BufLeave ++ WinLeave ++ TabLeave ++ WinEnter ++ TabEnter ++ BufEnter ++ === tabnext 3 === ++ BufLeave ++ WinLeave ++ TabLeave ++ WinEnter ++ TabEnter ++ === tabnext 2 === ++ BufLeave ++ WinLeave ++ TabLeave ++ WinEnter ++ TabEnter ++ === tabnext 2 === ++ === tabclose 3 === ++ BufEnter ++ === tabclose 3 === ++ 2/2 +*** ../vim-7.3.925/src/window.c 2013-05-06 04:21:35.000000000 +0200 +--- src/window.c 2013-05-06 04:47:06.000000000 +0200 +*************** +*** 44,54 **** + static void new_frame __ARGS((win_T *wp)); + #if defined(FEAT_WINDOWS) || defined(PROTO) + static tabpage_T *alloc_tabpage __ARGS((void)); +! static int leave_tabpage __ARGS((buf_T *new_curbuf)); +! static void enter_tabpage __ARGS((tabpage_T *tp, buf_T *old_curbuf, int trigger_autocmds)); + static void frame_fix_height __ARGS((win_T *wp)); + static int frame_minheight __ARGS((frame_T *topfrp, win_T *next_curwin)); +! static void win_enter_ext __ARGS((win_T *wp, int undo_sync, int no_curwin)); + static void win_free __ARGS((win_T *wp, tabpage_T *tp)); + static void frame_append __ARGS((frame_T *after, frame_T *frp)); + static void frame_insert __ARGS((frame_T *before, frame_T *frp)); +--- 44,54 ---- + static void new_frame __ARGS((win_T *wp)); + #if defined(FEAT_WINDOWS) || defined(PROTO) + static tabpage_T *alloc_tabpage __ARGS((void)); +! static int leave_tabpage __ARGS((buf_T *new_curbuf, int trigger_leave_autocmds)); +! static void enter_tabpage __ARGS((tabpage_T *tp, buf_T *old_curbuf, int trigger_enter_autocmds, int trigger_leave_autocmds)); + static void frame_fix_height __ARGS((win_T *wp)); + static int frame_minheight __ARGS((frame_T *topfrp, win_T *next_curwin)); +! static void win_enter_ext __ARGS((win_T *wp, int undo_sync, int no_curwin, int trigger_enter_autocmds, int trigger_leave_autocmds)); + static void win_free __ARGS((win_T *wp, tabpage_T *tp)); + static void frame_append __ARGS((frame_T *after, frame_T *frp)); + static void frame_insert __ARGS((frame_T *before, frame_T *frp)); +*************** +*** 353,363 **** + && valid_tabpage(oldtab)) + { + newtab = curtab; +! goto_tabpage_tp(oldtab, TRUE); + if (curwin == wp) + win_close(curwin, FALSE); + if (valid_tabpage(newtab)) +! goto_tabpage_tp(newtab, TRUE); + } + } + break; +--- 353,363 ---- + && valid_tabpage(oldtab)) + { + newtab = curtab; +! goto_tabpage_tp(oldtab, TRUE, TRUE); + if (curwin == wp) + win_close(curwin, FALSE); + if (valid_tabpage(newtab)) +! goto_tabpage_tp(newtab, TRUE, TRUE); + } + } + break; +*************** +*** 2124,2129 **** +--- 2124,2131 ---- + { + if (firstwin == lastwin) + { ++ buf_T *old_curbuf = curbuf; ++ + /* + * Closing the last window in a tab page. First go to another tab + * page and then close the window and the tab page. This avoids that +*************** +*** 2132,2138 **** + * Don't trigger autocommands yet, they may use wrong values, so do + * that below. + */ +! goto_tabpage_tp(alt_tabpage(), FALSE); + redraw_tabline = TRUE; + + /* Safety check: Autocommands may have closed the window when jumping +--- 2134,2140 ---- + * Don't trigger autocommands yet, they may use wrong values, so do + * that below. + */ +! goto_tabpage_tp(alt_tabpage(), FALSE, TRUE); + redraw_tabline = TRUE; + + /* Safety check: Autocommands may have closed the window when jumping +*************** +*** 2148,2155 **** + /* Since goto_tabpage_tp above did not trigger *Enter autocommands, do + * that now. */ + #ifdef FEAT_AUTOCMD +- apply_autocmds(EVENT_TABENTER, NULL, NULL, FALSE, curbuf); + apply_autocmds(EVENT_WINENTER, NULL, NULL, FALSE, curbuf); + #endif + return TRUE; + } +--- 2150,2159 ---- + /* Since goto_tabpage_tp above did not trigger *Enter autocommands, do + * that now. */ + #ifdef FEAT_AUTOCMD + apply_autocmds(EVENT_WINENTER, NULL, NULL, FALSE, curbuf); ++ apply_autocmds(EVENT_TABENTER, NULL, NULL, FALSE, curbuf); ++ if (old_curbuf != curbuf) ++ apply_autocmds(EVENT_BUFENTER, NULL, NULL, FALSE, curbuf); + #endif + return TRUE; + } +*************** +*** 2341,2347 **** + win_comp_pos(); + if (close_curwin) + { +! win_enter_ext(wp, FALSE, TRUE); + #ifdef FEAT_AUTOCMD + if (other_buffer) + /* careful: after this wp and win may be invalid! */ +--- 2345,2351 ---- + win_comp_pos(); + if (close_curwin) + { +! win_enter_ext(wp, FALSE, TRUE, TRUE, TRUE); + #ifdef FEAT_AUTOCMD + if (other_buffer) + /* careful: after this wp and win may be invalid! */ +*************** +*** 3529,3535 **** + return FAIL; + + /* Remember the current windows in this Tab page. */ +! if (leave_tabpage(curbuf) == FAIL) + { + vim_free(newtp); + return FAIL; +--- 3533,3539 ---- + return FAIL; + + /* Remember the current windows in this Tab page. */ +! if (leave_tabpage(curbuf, TRUE) == FAIL) + { + vim_free(newtp); + return FAIL; +*************** +*** 3574,3587 **** + + redraw_all_later(CLEAR); + #ifdef FEAT_AUTOCMD +- apply_autocmds(EVENT_TABENTER, NULL, NULL, FALSE, curbuf); + apply_autocmds(EVENT_WINENTER, NULL, NULL, FALSE, curbuf); + #endif + return OK; + } + + /* Failed, get back the previous Tab page */ +! enter_tabpage(curtab, curbuf, TRUE); + return FAIL; + } + +--- 3578,3591 ---- + + redraw_all_later(CLEAR); + #ifdef FEAT_AUTOCMD + apply_autocmds(EVENT_WINENTER, NULL, NULL, FALSE, curbuf); ++ apply_autocmds(EVENT_TABENTER, NULL, NULL, FALSE, curbuf); + #endif + return OK; + } + + /* Failed, get back the previous Tab page */ +! enter_tabpage(curtab, curbuf, TRUE, TRUE); + return FAIL; + } + +*************** +*** 3692,3700 **** + * Careful: When OK is returned need to get a new tab page very very soon! + */ + static int +! leave_tabpage(new_curbuf) + buf_T *new_curbuf UNUSED; /* what is going to be the new curbuf, + NULL if unknown */ + { + tabpage_T *tp = curtab; + +--- 3696,3705 ---- + * Careful: When OK is returned need to get a new tab page very very soon! + */ + static int +! leave_tabpage(new_curbuf, trigger_leave_autocmds) + buf_T *new_curbuf UNUSED; /* what is going to be the new curbuf, + NULL if unknown */ ++ int trigger_leave_autocmds UNUSED; + { + tabpage_T *tp = curtab; + +*************** +*** 3702,3719 **** + reset_VIsual_and_resel(); /* stop Visual mode */ + #endif + #ifdef FEAT_AUTOCMD +! if (new_curbuf != curbuf) + { +! apply_autocmds(EVENT_BUFLEAVE, NULL, NULL, FALSE, curbuf); + if (curtab != tp) + return FAIL; + } +- apply_autocmds(EVENT_WINLEAVE, NULL, NULL, FALSE, curbuf); +- if (curtab != tp) +- return FAIL; +- apply_autocmds(EVENT_TABLEAVE, NULL, NULL, FALSE, curbuf); +- if (curtab != tp) +- return FAIL; + #endif + #if defined(FEAT_GUI) + /* Remove the scrollbars. They may be added back later. */ +--- 3707,3727 ---- + reset_VIsual_and_resel(); /* stop Visual mode */ + #endif + #ifdef FEAT_AUTOCMD +! if (trigger_leave_autocmds) + { +! if (new_curbuf != curbuf) +! { +! apply_autocmds(EVENT_BUFLEAVE, NULL, NULL, FALSE, curbuf); +! if (curtab != tp) +! return FAIL; +! } +! apply_autocmds(EVENT_WINLEAVE, NULL, NULL, FALSE, curbuf); +! if (curtab != tp) +! return FAIL; +! apply_autocmds(EVENT_TABLEAVE, NULL, NULL, FALSE, curbuf); + if (curtab != tp) + return FAIL; + } + #endif + #if defined(FEAT_GUI) + /* Remove the scrollbars. They may be added back later. */ +*************** +*** 3734,3746 **** + /* + * Start using tab page "tp". + * Only to be used after leave_tabpage() or freeing the current tab page. +! * Only trigger *Enter autocommands when trigger_autocmds is TRUE. + */ + static void +! enter_tabpage(tp, old_curbuf, trigger_autocmds) + tabpage_T *tp; + buf_T *old_curbuf UNUSED; +! int trigger_autocmds UNUSED; + { + int old_off = tp->tp_firstwin->w_winrow; + win_T *next_prevwin = tp->tp_prevwin; +--- 3742,3756 ---- + /* + * Start using tab page "tp". + * Only to be used after leave_tabpage() or freeing the current tab page. +! * Only trigger *Enter autocommands when trigger_enter_autocmds is TRUE. +! * Only trigger *Leave autocommands when trigger_leave_autocmds is TRUE. + */ + static void +! enter_tabpage(tp, old_curbuf, trigger_enter_autocmds, trigger_leave_autocmds) + tabpage_T *tp; + buf_T *old_curbuf UNUSED; +! int trigger_enter_autocmds UNUSED; +! int trigger_leave_autocmds UNUSED; + { + int old_off = tp->tp_firstwin->w_winrow; + win_T *next_prevwin = tp->tp_prevwin; +*************** +*** 3753,3759 **** + /* We would like doing the TabEnter event first, but we don't have a + * valid current window yet, which may break some commands. + * This triggers autocommands, thus may make "tp" invalid. */ +! win_enter_ext(tp->tp_curwin, FALSE, TRUE); + prevwin = next_prevwin; + + last_status(FALSE); /* status line may appear or disappear */ +--- 3763,3769 ---- + /* We would like doing the TabEnter event first, but we don't have a + * valid current window yet, which may break some commands. + * This triggers autocommands, thus may make "tp" invalid. */ +! win_enter_ext(tp->tp_curwin, FALSE, TRUE, trigger_enter_autocmds, trigger_leave_autocmds); + prevwin = next_prevwin; + + last_status(FALSE); /* status line may appear or disappear */ +*************** +*** 3788,3794 **** + #ifdef FEAT_AUTOCMD + /* Apply autocommands after updating the display, when 'rows' and + * 'columns' have been set correctly. */ +! if (trigger_autocmds) + { + apply_autocmds(EVENT_TABENTER, NULL, NULL, FALSE, curbuf); + if (old_curbuf != curbuf) +--- 3798,3804 ---- + #ifdef FEAT_AUTOCMD + /* Apply autocommands after updating the display, when 'rows' and + * 'columns' have been set correctly. */ +! if (trigger_enter_autocmds) + { + apply_autocmds(EVENT_TABENTER, NULL, NULL, FALSE, curbuf); + if (old_curbuf != curbuf) +*************** +*** 3869,3875 **** + } + } + +! goto_tabpage_tp(tp, TRUE); + + #ifdef FEAT_GUI_TABLINE + if (gui_use_tabline()) +--- 3879,3885 ---- + } + } + +! goto_tabpage_tp(tp, TRUE, TRUE); + + #ifdef FEAT_GUI_TABLINE + if (gui_use_tabline()) +*************** +*** 3879,3901 **** + + /* + * Go to tabpage "tp". +! * Only trigger *Enter autocommands when trigger_autocmds is TRUE. + * Note: doesn't update the GUI tab. + */ + void +! goto_tabpage_tp(tp, trigger_autocmds) + tabpage_T *tp; +! int trigger_autocmds; + { + /* Don't repeat a message in another tab page. */ + set_keep_msg(NULL, 0); + +! if (tp != curtab && leave_tabpage(tp->tp_curwin->w_buffer) == OK) + { + if (valid_tabpage(tp)) +! enter_tabpage(tp, curbuf, trigger_autocmds); + else +! enter_tabpage(curtab, curbuf, trigger_autocmds); + } + } + +--- 3889,3916 ---- + + /* + * Go to tabpage "tp". +! * Only trigger *Enter autocommands when trigger_enter_autocmds is TRUE. +! * Only trigger *Leave autocommands when trigger_leave_autocmds is TRUE. + * Note: doesn't update the GUI tab. + */ + void +! goto_tabpage_tp(tp, trigger_enter_autocmds, trigger_leave_autocmds) + tabpage_T *tp; +! int trigger_enter_autocmds; +! int trigger_leave_autocmds; + { + /* Don't repeat a message in another tab page. */ + set_keep_msg(NULL, 0); + +! if (tp != curtab && leave_tabpage(tp->tp_curwin->w_buffer, +! trigger_leave_autocmds) == OK) + { + if (valid_tabpage(tp)) +! enter_tabpage(tp, curbuf, trigger_enter_autocmds, +! trigger_leave_autocmds); + else +! enter_tabpage(curtab, curbuf, trigger_enter_autocmds, +! trigger_leave_autocmds); + } + } + +*************** +*** 3908,3914 **** + tabpage_T *tp; + win_T *wp; + { +! goto_tabpage_tp(tp, TRUE); + if (curtab == tp && win_valid(wp)) + { + win_enter(wp, TRUE); +--- 3923,3929 ---- + tabpage_T *tp; + win_T *wp; + { +! goto_tabpage_tp(tp, TRUE, TRUE); + if (curtab == tp && win_valid(wp)) + { + win_enter(wp, TRUE); +*************** +*** 4168,4174 **** + win_T *wp; + int undo_sync; + { +! win_enter_ext(wp, undo_sync, FALSE); + } + + /* +--- 4183,4189 ---- + win_T *wp; + int undo_sync; + { +! win_enter_ext(wp, undo_sync, FALSE, TRUE, TRUE); + } + + /* +*************** +*** 4177,4186 **** + * been closed and isn't valid. + */ + static void +! win_enter_ext(wp, undo_sync, curwin_invalid) + win_T *wp; + int undo_sync; + int curwin_invalid; + { + #ifdef FEAT_AUTOCMD + int other_buffer = FALSE; +--- 4192,4203 ---- + * been closed and isn't valid. + */ + static void +! win_enter_ext(wp, undo_sync, curwin_invalid, trigger_enter_autocmds, trigger_leave_autocmds) + win_T *wp; + int undo_sync; + int curwin_invalid; ++ int trigger_enter_autocmds UNUSED; ++ int trigger_leave_autocmds UNUSED; + { + #ifdef FEAT_AUTOCMD + int other_buffer = FALSE; +*************** +*** 4190,4196 **** + return; + + #ifdef FEAT_AUTOCMD +! if (!curwin_invalid) + { + /* + * Be careful: If autocommands delete the window, return now. +--- 4207,4213 ---- + return; + + #ifdef FEAT_AUTOCMD +! if (!curwin_invalid && trigger_leave_autocmds) + { + /* + * Be careful: If autocommands delete the window, return now. +*************** +*** 4259,4267 **** + } + + #ifdef FEAT_AUTOCMD +! apply_autocmds(EVENT_WINENTER, NULL, NULL, FALSE, curbuf); +! if (other_buffer) +! apply_autocmds(EVENT_BUFENTER, NULL, NULL, FALSE, curbuf); + #endif + + #ifdef FEAT_TITLE +--- 4276,4287 ---- + } + + #ifdef FEAT_AUTOCMD +! if (trigger_enter_autocmds) +! { +! apply_autocmds(EVENT_WINENTER, NULL, NULL, FALSE, curbuf); +! if (other_buffer) +! apply_autocmds(EVENT_BUFENTER, NULL, NULL, FALSE, curbuf); +! } + #endif + + #ifdef FEAT_TITLE +*** ../vim-7.3.925/src/version.c 2013-05-06 04:21:35.000000000 +0200 +--- src/version.c 2013-05-06 04:40:52.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 926, + /**/ + +-- + Bravely bold Sir Robin, rode forth from Camelot, + He was not afraid to die, Oh Brave Sir Robin, + He was not at all afraid to be killed in nasty ways + Brave, brave, brave, brave Sir Robin. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 497e5d7e5442aa3a9209a63cc23a7397fee84802 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:53 +0200 Subject: [PATCH 0817/3340] - patchlevel 927 --- 7.3.927 | 99 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 99 insertions(+) create mode 100644 7.3.927 diff --git a/7.3.927 b/7.3.927 new file mode 100644 index 00000000..4add389c --- /dev/null +++ b/7.3.927 @@ -0,0 +1,99 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.927 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.927 +Problem: Missing combining characters when putting text in a register. +Solution: Include combining characters. (Christian Brabandt) +Files: src/getchar.c, src/testdir/test44.in, src/testdir/test44.ok + + +*** ../vim-7.3.926/src/getchar.c 2013-04-15 15:47:07.000000000 +0200 +--- src/getchar.c 2013-05-06 05:06:13.000000000 +0200 +*************** +*** 4616,4624 **** +--- 4616,4636 ---- + } + else + { ++ #ifdef FEAT_MBYTE ++ int len = mb_char2len(PTR2CHAR(s)); ++ int len2 = mb_ptr2len(s); ++ #endif + /* Add character, possibly multi-byte to destination, escaping + * CSI and K_SPECIAL. */ + d = add_char2buf(PTR2CHAR(s), d); ++ #ifdef FEAT_MBYTE ++ while (len < len2) ++ { ++ /* add following combining char */ ++ d = add_char2buf(PTR2CHAR(s + len), d); ++ len += mb_char2len(PTR2CHAR(s + len)); ++ } ++ #endif + mb_ptr_adv(s); + } + } +*** ../vim-7.3.926/src/testdir/test44.in 2013-01-23 16:43:07.000000000 +0100 +--- src/testdir/test44.in 2013-05-06 05:01:39.000000000 +0200 +*************** +*** 32,38 **** + x:" Test backwards search from a multi-byte char + /x + x?. +! x:?^1?,$w! test.out + :e! test.out + G:put =matchstr(\"×בגד\", \".\", 0, 2) " ב + :put =matchstr(\"×בגד\", \"..\", 0, 2) " בג +--- 32,40 ---- + x:" Test backwards search from a multi-byte char + /x + x?. +! x:let @w=':%s#comb[i]nations#œ̄ṣÌm̥̄ᾱ̆Ì#g' +! :@w +! :?^1?,$w! test.out + :e! test.out + G:put =matchstr(\"×בגד\", \".\", 0, 2) " ב + :put =matchstr(\"×בגד\", \"..\", 0, 2) " בג +*************** +*** 61,63 **** +--- 63,66 ---- + h AÀÃÂÃÄÅĀĂĄÇǞǠẢ BḂḆ CÇĆĈĊČ DÄŽÄḊḎḠEÈÉÊËĒĔĖĘĚẺẼ FḞ GĜĞĠĢǤǦǴḠ HĤĦḢḦḨ IÃŒÃÃŽÃĨĪĬĮİÇỈ JÄ´ KĶǨḰḴ LĹĻĽĿÅḺ MḾṀ NÑŃŅŇṄṈ OÃ’Ã“Ã”Ã•Ã–Ã˜ÅŒÅŽÅÆ Ç‘ǪǬỎ PṔṖ Q RŔŖŘṘṞ SŚŜŞŠṠ TŢŤŦṪṮ UÙÚÛÜŨŪŬŮŰŲƯǓỦ Vá¹¼ WŴẀẂẄẆ XẊẌ YÃŶŸẎỲỶỸ ZŹŻŽƵáºáº” + i aàáâãäåÄăąǎǟǡả bḃḇ cÃ§Ä‡Ä‰Ä‹Ä dÄđḋá¸á¸‘ eèéêëēĕėęěẻẽ fḟ gÄğġģǥǧǵḡ hĥħḣḧḩẖ iìíîïĩīĭįÇỉ jĵǰ kķǩḱḵ lĺļľŀłḻ mḿṠnñńņňʼnṅṉ oòóôõöøÅÅőơǒǫǭỠpṕṗ q rŕŗřṙṟ sÅ›Åşšṡ tţťŧṫṯẗ uùúûüũūŭůűųưǔủ vá¹½ wŵáºáºƒáº…ẇẘ xẋẠyýÿŷáºáº™á»³á»·á»¹ zźżžƶẑẕ + j 0123â¤x ++ k combinations +*** ../vim-7.3.926/src/testdir/test44.ok 2013-01-23 16:43:07.000000000 +0100 +--- src/testdir/test44.ok 2013-05-06 05:01:39.000000000 +0200 +*************** +*** 17,22 **** +--- 17,23 ---- + h AÀÃÂÃÄÅĀĂĄÇǞǠẢ BḂḆ CÇĆĈĊČ DÄŽÄḊḎḠEÈÉÊËĒĔĖĘĚẺẼ FḞ GĜĞĠĢǤǦǴḠ HĤĦḢḦḨ IÃŒÃÃŽÃĨĪĬĮİÇỈ JÄ´ KĶǨḰḴ LĹĻĽĿÅḺ MḾṀ NÑŃŅŇṄṈ OÃ’Ã“Ã”Ã•Ã–Ã˜ÅŒÅŽÅÆ Ç‘ǪǬỎ PṔṖ Q RŔŖŘṘṞ SŚŜŞŠṠ TŢŤŦṪṮ UÙÚÛÜŨŪŬŮŰŲƯǓỦ Vá¹¼ WŴẀẂẄẆ XẊẌ YÃŶŸẎỲỶỸ ZŹŻŽƵẠ+ i aàáâãäåÄăąǎǟǡả bḃḇ cÃ§Ä‡Ä‰Ä‹Ä dÄđḋá¸á¸‘ eèéêëēĕėęěẻẽ fḟ gÄğġģǥǧǵḡ hĥħḣḧḩẖ iìíîïĩīĭįÇỉ jĵǰ kķǩḱḵ lĺļľŀłḻ mḿṠnñńņňʼnṅṉ oòóôõöøÅÅőơǒǫǭỠpṕṗ q rŕŗřṙṟ sÅ›Åşšṡ tţťŧṫṯẗ uùúûüũūŭůűųưǔủ vá¹½ wŵáºáºƒáº…ẇẘ xẋẠyýÿŷáºáº™á»³á»·á»¹ zźżžƶẑ + j 012⤠++ k œ̄ṣÌmÌ¥Ì„Î±Ì„Ì†Ì + ב + בג + × +*** ../vim-7.3.926/src/version.c 2013-05-06 04:50:26.000000000 +0200 +--- src/version.c 2013-05-06 05:08:11.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 927, + /**/ + +-- +In his lifetime van Gogh painted 486 oil paintings. Oddly enough, 8975 +of them are to be found in the United States. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ab10fac225eefaa7e5dcb88956ee1ecb27bf4fa4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:54 +0200 Subject: [PATCH 0818/3340] - patchlevel 928 --- 7.3.928 | 86 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 7.3.928 diff --git a/7.3.928 b/7.3.928 new file mode 100644 index 00000000..764e7051 --- /dev/null +++ b/7.3.928 @@ -0,0 +1,86 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.928 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.928 (after 7.3.924) +Problem: Can't build with strict C compiler. +Solution: Move declaration to start of block. (Taro Muraoka) +Files: src/if_py_both.h + + +*** ../vim-7.3.927/src/if_py_both.h 2013-05-06 04:21:35.000000000 +0200 +--- src/if_py_both.h 2013-05-06 06:21:55.000000000 +0200 +*************** +*** 1521,1532 **** + int flags; + long numval; + char_u *stringval; + + if (this->Check(this->from)) + return NULL; + +- DICTKEY_DECL +- + DICTKEY_GET_NOTEMPTY(NULL) + + flags = get_option_value_strict(key, &numval, &stringval, +--- 1521,1531 ---- + int flags; + long numval; + char_u *stringval; ++ DICTKEY_DECL + + if (this->Check(this->from)) + return NULL; + + DICTKEY_GET_NOTEMPTY(NULL) + + flags = get_option_value_strict(key, &numval, &stringval, +*************** +*** 1616,1627 **** + int flags; + int opt_flags; + int r = 0; + + if (this->Check(this->from)) + return -1; + +- DICTKEY_DECL +- + DICTKEY_GET_NOTEMPTY(-1) + + flags = get_option_value_strict(key, NULL, NULL, +--- 1615,1625 ---- + int flags; + int opt_flags; + int r = 0; ++ DICTKEY_DECL + + if (this->Check(this->from)) + return -1; + + DICTKEY_GET_NOTEMPTY(-1) + + flags = get_option_value_strict(key, NULL, NULL, +*** ../vim-7.3.927/src/version.c 2013-05-06 05:50:22.000000000 +0200 +--- src/version.c 2013-05-06 06:22:57.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 928, + /**/ + +-- +press CTRL-ALT-DEL for more information + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fe46cb6b778a3958e47b5940e2612b551e4f27b2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:55 +0200 Subject: [PATCH 0819/3340] - patchlevel 929 --- 7.3.929 | 178 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 178 insertions(+) create mode 100644 7.3.929 diff --git a/7.3.929 b/7.3.929 new file mode 100644 index 00000000..adf5d6e2 --- /dev/null +++ b/7.3.929 @@ -0,0 +1,178 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.929 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.929 (after 7.3.924) +Problem: Compiler warning for unused variable. Not freeing unused string. +Solution: Remove the variable. Clear the options. +Files: src/option.c + + +*** ../vim-7.3.928/src/option.c 2013-05-06 03:52:44.000000000 +0200 +--- src/option.c 2013-05-06 06:42:03.000000000 +0200 +*************** +*** 9705,9713 **** + { + struct vimoption *p; + int opt_idx; +! +! buf_T *buf = (buf_T *) from; +! win_T *win = (win_T *) from; + + opt_idx = findoption(name); + p = &(options[opt_idx]); +--- 9705,9711 ---- + { + struct vimoption *p; + int opt_idx; +! buf_T *buf = (buf_T *)from; + + opt_idx = findoption(name); + p = &(options[opt_idx]); +*************** +*** 9716,9775 **** + { + /* global option with local value: use local value if it's been set */ + case PV_EP: +! *buf->b_p_ep = NUL; + break; + case PV_KP: +! *buf->b_p_kp = NUL; + break; + case PV_PATH: +! *buf->b_p_path = NUL; + break; + case PV_AR: + buf->b_p_ar = -1; + break; + case PV_TAGS: +! *buf->b_p_tags = NUL; + break; + #ifdef FEAT_FIND_ID + case PV_DEF: +! *buf->b_p_def = NUL; + break; + case PV_INC: +! *buf->b_p_inc = NUL; + break; + #endif + #ifdef FEAT_INS_EXPAND + case PV_DICT: +! *buf->b_p_dict = NUL; + break; + case PV_TSR: +! *buf->b_p_tsr = NUL; + break; + #endif + #ifdef FEAT_QUICKFIX + case PV_EFM: +! *buf->b_p_efm = NUL; + break; + case PV_GP: +! *buf->b_p_gp = NUL; + break; + case PV_MP: +! *buf->b_p_mp = NUL; + break; + #endif + #if defined(FEAT_BEVAL) && defined(FEAT_EVAL) + case PV_BEXPR: +! *buf->b_p_bexpr = NUL; + break; + #endif + #if defined(FEAT_CRYPT) + case PV_CM: +! *buf->b_p_cm = NUL; + break; + #endif + #ifdef FEAT_STL_OPT + case PV_STL: +! *win->w_p_stl = NUL; + break; + #endif + } +--- 9714,9773 ---- + { + /* global option with local value: use local value if it's been set */ + case PV_EP: +! clear_string_option(&buf->b_p_ep); + break; + case PV_KP: +! clear_string_option(&buf->b_p_kp); + break; + case PV_PATH: +! clear_string_option(&buf->b_p_path); + break; + case PV_AR: + buf->b_p_ar = -1; + break; + case PV_TAGS: +! clear_string_option(&buf->b_p_tags); + break; + #ifdef FEAT_FIND_ID + case PV_DEF: +! clear_string_option(&buf->b_p_def); + break; + case PV_INC: +! clear_string_option(&buf->b_p_inc); + break; + #endif + #ifdef FEAT_INS_EXPAND + case PV_DICT: +! clear_string_option(&buf->b_p_dict); + break; + case PV_TSR: +! clear_string_option(&buf->b_p_tsr); + break; + #endif + #ifdef FEAT_QUICKFIX + case PV_EFM: +! clear_string_option(&buf->b_p_efm); + break; + case PV_GP: +! clear_string_option(&buf->b_p_gp); + break; + case PV_MP: +! clear_string_option(&buf->b_p_mp); + break; + #endif + #if defined(FEAT_BEVAL) && defined(FEAT_EVAL) + case PV_BEXPR: +! clear_string_option(&buf->b_p_bexpr); + break; + #endif + #if defined(FEAT_CRYPT) + case PV_CM: +! clear_string_option(&buf->b_p_cm); + break; + #endif + #ifdef FEAT_STL_OPT + case PV_STL: +! clear_string_option(&((win_T *)from)->w_p_stl); + break; + #endif + } +*** ../vim-7.3.928/src/version.c 2013-05-06 06:26:10.000000000 +0200 +--- src/version.c 2013-05-06 06:35:06.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 929, + /**/ + +-- +Microsoft: "Windows NT 4.0 now has the same user-interface as Windows 95" + Windows 95: "Press CTRL-ALT-DEL to reboot" +Windows NT 4.0: "Press CTRL-ALT-DEL to login" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 62058115424ab77101843296bfeea124aa805c57 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:55 +0200 Subject: [PATCH 0820/3340] - patchlevel 930 --- 7.3.930 | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 7.3.930 diff --git a/7.3.930 b/7.3.930 new file mode 100644 index 00000000..b2ba17ca --- /dev/null +++ b/7.3.930 @@ -0,0 +1,46 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.930 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.930 +Problem: MSVC 2012 update is not recognized. +Solution: Update the version in the makefile. (Raymond Ko) +Files: src/Make_mvc.mak + + +*** ../vim-7.3.929/src/Make_mvc.mak 2013-05-06 04:21:35.000000000 +0200 +--- src/Make_mvc.mak 2013-05-07 05:08:08.000000000 +0200 +*************** +*** 416,421 **** +--- 416,424 ---- + !if "$(_NMAKE_VER)" == "11.00.51106.1" + MSVCVER = 11.0 + !endif ++ !if "$(_NMAKE_VER)" == "11.00.60315.1" ++ MSVCVER = 11.0 ++ !endif + !endif + + # Abort building VIM if version of VC is unrecognised. +*** ../vim-7.3.929/src/version.c 2013-05-06 06:45:42.000000000 +0200 +--- src/version.c 2013-05-07 05:09:51.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 930, + /**/ + +-- +Life would be so much easier if we could just look at the source code. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 639cf1629dccf02b7b4f7bea94c625c92052d319 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:56 +0200 Subject: [PATCH 0821/3340] - patchlevel 931 --- 7.3.931 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.931 diff --git a/7.3.931 b/7.3.931 new file mode 100644 index 00000000..bc96b7a9 --- /dev/null +++ b/7.3.931 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.931 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.931 +Problem: No completion for :xmap and :smap. (Yukihiro Nakadaira) +Solution: Add the case statements. (Christian Brabandt) +Files: src/ex_docmd.c + + +*** ../vim-7.3.930/src/ex_docmd.c 2013-05-06 04:21:35.000000000 +0200 +--- src/ex_docmd.c 2013-05-07 05:15:26.000000000 +0200 +*************** +*** 3889,3894 **** +--- 3889,3896 ---- + case CMD_imap: case CMD_inoremap: + case CMD_cmap: case CMD_cnoremap: + case CMD_lmap: case CMD_lnoremap: ++ case CMD_smap: case CMD_snoremap: ++ case CMD_xmap: case CMD_xnoremap: + return set_context_in_map_cmd(xp, cmd, arg, forceit, + FALSE, FALSE, ea.cmdidx); + case CMD_unmap: +*************** +*** 3898,3903 **** +--- 3900,3907 ---- + case CMD_iunmap: + case CMD_cunmap: + case CMD_lunmap: ++ case CMD_sunmap: ++ case CMD_xunmap: + return set_context_in_map_cmd(xp, cmd, arg, forceit, + FALSE, TRUE, ea.cmdidx); + case CMD_abbreviate: case CMD_noreabbrev: +*** ../vim-7.3.930/src/version.c 2013-05-07 05:11:12.000000000 +0200 +--- src/version.c 2013-05-07 05:16:45.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 931, + /**/ + +-- +FIRST HEAD: All right! All right! We'll kill him first and then have tea and + biscuits. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 94b639ab98ff1d3166ebdd5897c95038fbb82288 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 8 May 2013 17:06:58 +0200 Subject: [PATCH 0822/3340] - patchlevel 931 --- README.patches | 30 ++++++++++++++++++++++++- vim.spec | 61 +++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 89 insertions(+), 2 deletions(-) diff --git a/README.patches b/README.patches index a82d9d62..6b0cf9e4 100644 --- a/README.patches +++ b/README.patches @@ -869,7 +869,7 @@ Individual patches for Vim 7.3: 1755 7.3.835 "xxd -i" fails on an empty file 59985 7.3.836 clipboard does not work on Win32 when compiled with Cygwin 2221 7.3.837 empty lines in :version output when 'columns' is 320 - 11082 7.3.838 (after 7.3.830) insufficient testing for mksession + 11057 7.3.838 (after 7.3.830) insufficient testing for mksession 2012 7.3.839 some files missing in the list of distributed files 1652 7.3.840 "\@ 7.3.931-1 +- patchlevel 931 + * Wed May 08 2013 Karsten Hopp 7.3.903-1 - fix ruby version check From 1e86775d8fe3f028325f360cf822260a00addcf9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 14:12:35 +0200 Subject: [PATCH 0823/3340] - patchlevel 932 --- 7.3.932 | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 7.3.932 diff --git a/7.3.932 b/7.3.932 new file mode 100644 index 00000000..81ae1aab --- /dev/null +++ b/7.3.932 @@ -0,0 +1,51 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.932 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.932 +Problem: Compiler warning for uninitialized variable. (Tony Mechelynck) +Solution: Initialize the variable. +Files: src/option.c + + +*** ../vim-7.3.931/src/option.c 2013-05-06 06:45:42.000000000 +0200 +--- src/option.c 2013-05-08 01:32:25.000000000 +0200 +*************** +*** 8847,8853 **** + void *from; + { + int opt_idx; +! char_u *varp; + struct vimoption *p; + int r = 0; + +--- 8847,8853 ---- + void *from; + { + int opt_idx; +! char_u *varp = NULL; + struct vimoption *p; + int r = 0; + +*** ../vim-7.3.931/src/version.c 2013-05-07 05:18:15.000000000 +0200 +--- src/version.c 2013-05-11 13:44:04.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 932, + /**/ + +-- +Proverb: A nightingale that forgets the lyrics is a hummingbird. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ab1641f5a3067fd23c0f8b6706dc17da9112df27 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 14:12:36 +0200 Subject: [PATCH 0824/3340] - patchlevel 933 --- 7.3.933 | 163 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 163 insertions(+) create mode 100644 7.3.933 diff --git a/7.3.933 b/7.3.933 new file mode 100644 index 00000000..d76314b6 --- /dev/null +++ b/7.3.933 @@ -0,0 +1,163 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.933 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.933 +Problem: Ruby on Mac crashes due to GC failure. +Solution: Init the stack from main(). (Hiroshi Shirosaki) +Files: src/main.c, src/if_ruby.c, src/proto/if_ruby.pro + + +*** ../vim-7.3.932/src/main.c 2013-03-19 13:33:18.000000000 +0100 +--- src/main.c 2013-05-11 13:37:23.000000000 +0200 +*************** +*** 192,197 **** +--- 192,204 ---- + params.window_count = -1; + #endif + ++ #ifdef FEAT_RUBY ++ { ++ int ruby_stack_start; ++ vim_ruby_init((void *)&ruby_stack_start); ++ } ++ #endif ++ + #ifdef FEAT_TCL + vim_tcl_init(params.argv[0]); + #endif +*** ../vim-7.3.932/src/if_ruby.c 2013-05-06 04:21:35.000000000 +0200 +--- src/if_ruby.c 2013-05-11 13:37:23.000000000 +0200 +*************** +*** 144,149 **** +--- 144,150 ---- + #endif + + static int ruby_initialized = 0; ++ static void *ruby_stack_start; + static VALUE objtbl; + + static VALUE mVIM; +*************** +*** 226,231 **** +--- 227,233 ---- + # define rb_float_new dll_rb_float_new + # define rb_ary_new dll_rb_ary_new + # define rb_ary_push dll_rb_ary_push ++ # define ruby_init_stack dll_ruby_init_stack + #else + # define rb_str2cstr dll_rb_str2cstr + #endif +*************** +*** 250,256 **** + # define rb_enc_str_new dll_rb_enc_str_new + # define rb_sprintf dll_rb_sprintf + # define rb_require dll_rb_require +- # define ruby_init_stack dll_ruby_init_stack + # define ruby_process_options dll_ruby_process_options + #endif + +--- 252,257 ---- +*************** +*** 335,340 **** +--- 336,342 ---- + static VALUE (*dll_rb_float_new) (double); + static VALUE (*dll_rb_ary_new) (void); + static VALUE (*dll_rb_ary_push) (VALUE, VALUE); ++ static void (*ruby_init_stack)(VALUE*); + #endif + #ifdef RUBY19_OR_LATER + static VALUE (*dll_rb_int2big)(SIGNED_VALUE); +*************** +*** 347,353 **** + static VALUE (*dll_rb_enc_str_new) (const char*, long, rb_encoding*); + static VALUE (*dll_rb_sprintf) (const char*, ...); + static VALUE (*dll_rb_require) (const char*); +- static void (*ruby_init_stack)(VALUE*); + static void* (*ruby_process_options)(int, char**); + #endif + +--- 349,354 ---- +*************** +*** 475,480 **** +--- 476,482 ---- + #endif + #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + {"rb_string_value_ptr", (RUBY_PROC*)&dll_rb_string_value_ptr}, ++ {"ruby_init_stack", (RUBY_PROC*)&dll_ruby_init_stack}, + # if DYNAMIC_RUBY_VER <= 19 + {"rb_float_new", (RUBY_PROC*)&dll_rb_float_new}, + # else +*************** +*** 491,497 **** + {"rb_enc_str_new", (RUBY_PROC*)&dll_rb_enc_str_new}, + {"rb_sprintf", (RUBY_PROC*)&dll_rb_sprintf}, + {"rb_require", (RUBY_PROC*)&dll_rb_require}, +- {"ruby_init_stack", (RUBY_PROC*)&dll_ruby_init_stack}, + {"ruby_process_options", (RUBY_PROC*)&dll_ruby_process_options}, + #endif + {"", NULL}, +--- 493,498 ---- +*************** +*** 716,723 **** + NtInitialize(&argc, &argv); + #endif + { +! #ifdef RUBY19_OR_LATER +! RUBY_INIT_STACK; + #endif + ruby_init(); + } +--- 717,724 ---- + NtInitialize(&argc, &argv); + #endif + { +! #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 +! ruby_init_stack(ruby_stack_start); + #endif + ruby_init(); + } +*************** +*** 1389,1391 **** +--- 1390,1398 ---- + rb_define_virtual_variable("$curbuf", buffer_s_current, 0); + rb_define_virtual_variable("$curwin", window_s_current, 0); + } ++ ++ void vim_ruby_init(void *stack_start) ++ { ++ /* should get machine stack start address early in main function */ ++ ruby_stack_start = stack_start; ++ } +*** ../vim-7.3.932/src/proto/if_ruby.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/if_ruby.pro 2013-05-11 13:37:28.000000000 +0200 +*************** +*** 6,9 **** +--- 6,10 ---- + void ex_rubyfile __ARGS((exarg_T *eap)); + void ruby_buffer_free __ARGS((buf_T *buf)); + void ruby_window_free __ARGS((win_T *win)); ++ void vim_ruby_init __ARGS((void *stack_start)); + /* vim: set ft=c : */ +*** ../vim-7.3.932/src/version.c 2013-05-11 13:45:00.000000000 +0200 +--- src/version.c 2013-05-11 13:52:55.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 933, + /**/ + +-- +Veni, Vidi, Video -- I came, I saw, I taped what I saw. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 35e11c421dd5408f8aa859c039e446da9909bbb2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 14:12:37 +0200 Subject: [PATCH 0825/3340] - patchlevel 934 --- 7.3.934 | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 7.3.934 diff --git a/7.3.934 b/7.3.934 new file mode 100644 index 00000000..d820f3ce --- /dev/null +++ b/7.3.934 @@ -0,0 +1,81 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.934 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.934 +Problem: E381 and E380 make the user think nothing happened. +Solution: Display the message indicating what error list is now active. + (Christian Brabandt) +Files: src/quickfix.c + + +*** ../vim-7.3.933/src/quickfix.c 2013-05-06 04:21:35.000000000 +0200 +--- src/quickfix.c 2013-05-11 13:50:56.000000000 +0200 +*************** +*** 2085,2091 **** + if (qi->qf_curlist == 0) + { + EMSG(_("E380: At bottom of quickfix stack")); +! return; + } + --qi->qf_curlist; + } +--- 2085,2091 ---- + if (qi->qf_curlist == 0) + { + EMSG(_("E380: At bottom of quickfix stack")); +! break; + } + --qi->qf_curlist; + } +*************** +*** 2094,2106 **** + if (qi->qf_curlist >= qi->qf_listcount - 1) + { + EMSG(_("E381: At top of quickfix stack")); +! return; + } + ++qi->qf_curlist; + } + } + qf_msg(qi); +- + } + + static void +--- 2094,2105 ---- + if (qi->qf_curlist >= qi->qf_listcount - 1) + { + EMSG(_("E381: At top of quickfix stack")); +! break; + } + ++qi->qf_curlist; + } + } + qf_msg(qi); + } + + static void +*** ../vim-7.3.933/src/version.c 2013-05-11 13:56:12.000000000 +0200 +--- src/version.c 2013-05-11 15:46:36.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 934, + /**/ + +-- +"A mouse can be just as dangerous as a bullet or a bomb." + (US Representative Lamar Smith, R-Texas) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 19175ab6dcb0f0dd57708b3d2935b5aa2701348b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 14:12:38 +0200 Subject: [PATCH 0826/3340] - patchlevel 935 --- 7.3.935 | 114 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 114 insertions(+) create mode 100644 7.3.935 diff --git a/7.3.935 b/7.3.935 new file mode 100644 index 00000000..fb14b74a --- /dev/null +++ b/7.3.935 @@ -0,0 +1,114 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.935 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.935 (after 7.3.933) +Problem: Init stack works differently on 64 bit systems. +Solution: Handle 64 bit systems and also static library. (Yukihiro + Nakadaira) +Files: src/if_ruby.c + + +*** ../vim-7.3.934/src/if_ruby.c 2013-05-11 13:56:12.000000000 +0200 +--- src/if_ruby.c 2013-05-11 17:31:55.000000000 +0200 +*************** +*** 227,233 **** + # define rb_float_new dll_rb_float_new + # define rb_ary_new dll_rb_ary_new + # define rb_ary_push dll_rb_ary_push +! # define ruby_init_stack dll_ruby_init_stack + #else + # define rb_str2cstr dll_rb_str2cstr + #endif +--- 227,239 ---- + # define rb_float_new dll_rb_float_new + # define rb_ary_new dll_rb_ary_new + # define rb_ary_push dll_rb_ary_push +! # ifdef __ia64 +! # define rb_ia64_bsp dll_rb_ia64_bsp +! # undef ruby_init_stack +! # define ruby_init_stack(addr) dll_ruby_init_stack((addr), rb_ia64_bsp()) +! # else +! # define ruby_init_stack dll_ruby_init_stack +! # endif + #else + # define rb_str2cstr dll_rb_str2cstr + #endif +*************** +*** 336,342 **** + static VALUE (*dll_rb_float_new) (double); + static VALUE (*dll_rb_ary_new) (void); + static VALUE (*dll_rb_ary_push) (VALUE, VALUE); +! static void (*ruby_init_stack)(VALUE*); + #endif + #ifdef RUBY19_OR_LATER + static VALUE (*dll_rb_int2big)(SIGNED_VALUE); +--- 342,353 ---- + static VALUE (*dll_rb_float_new) (double); + static VALUE (*dll_rb_ary_new) (void); + static VALUE (*dll_rb_ary_push) (VALUE, VALUE); +! # ifdef __ia64 +! static void * (*dll_rb_ia64_bsp) (void); +! static void (*dll_ruby_init_stack)(VALUE*, void*); +! # else +! static void (*dll_ruby_init_stack)(VALUE*); +! # endif + #endif + #ifdef RUBY19_OR_LATER + static VALUE (*dll_rb_int2big)(SIGNED_VALUE); +*************** +*** 476,481 **** +--- 487,495 ---- + #endif + #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + {"rb_string_value_ptr", (RUBY_PROC*)&dll_rb_string_value_ptr}, ++ # ifdef __ia64 ++ {"rb_ia64_bsp", (RUBY_PROC*)&dll_rb_ia64_bsp}, ++ # endif + {"ruby_init_stack", (RUBY_PROC*)&dll_ruby_init_stack}, + # if DYNAMIC_RUBY_VER <= 19 + {"rb_float_new", (RUBY_PROC*)&dll_rb_float_new}, +*************** +*** 717,723 **** + NtInitialize(&argc, &argv); + #endif + { +! #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + ruby_init_stack(ruby_stack_start); + #endif + ruby_init(); +--- 731,737 ---- + NtInitialize(&argc, &argv); + #endif + { +! #if defined(RUBY_VERSION) && RUBY_VERSION >= 18 + ruby_init_stack(ruby_stack_start); + #endif + ruby_init(); +*** ../vim-7.3.934/src/version.c 2013-05-11 15:50:02.000000000 +0200 +--- src/version.c 2013-05-11 17:39:08.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 935, + /**/ + +-- +ARTHUR: Well, it doesn't matter. Will you go and tell your master that + Arthur from the Court of Camelot is here. +GUARD #1: Listen, in order to maintain air-speed velocity, a swallow + needs to beat its wings 43 times every second, right? +ARTHUR: Please! + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4b44f72cac30ae8ade40405635e5eec12ea21af6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 14:12:39 +0200 Subject: [PATCH 0827/3340] - patchlevel 936 --- 7.3.936 | 661 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 661 insertions(+) create mode 100644 7.3.936 diff --git a/7.3.936 b/7.3.936 new file mode 100644 index 00000000..964dae72 --- /dev/null +++ b/7.3.936 @@ -0,0 +1,661 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.936 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.936 (after 7.3.935) +Problem: Ruby 1.8: Missing piece for static linking on 64 bit systems. +Solution: Define ruby_init_stack() (Hiroshi Shirosaki) + Also fix preprocessor indents. +Files: src/if_ruby.c + + +*** ../vim-7.3.935/src/if_ruby.c 2013-05-11 17:45:45.000000000 +0200 +--- src/if_ruby.c 2013-05-12 00:09:18.000000000 +0200 +*************** +*** 158,265 **** + static void ruby_io_init(void); + static void ruby_vim_init(void); + +! #if defined(DYNAMIC_RUBY) || defined(PROTO) +! #ifdef PROTO +! # define HINSTANCE int /* for generating prototypes */ + #endif + + /* + * Wrapper defines + */ +! #define rb_assoc_new dll_rb_assoc_new +! #define rb_cObject (*dll_rb_cObject) +! #define rb_check_type dll_rb_check_type +! #define rb_class_path dll_rb_class_path +! #define rb_data_object_alloc dll_rb_data_object_alloc +! #define rb_define_class_under dll_rb_define_class_under +! #define rb_define_const dll_rb_define_const +! #define rb_define_global_function dll_rb_define_global_function +! #define rb_define_method dll_rb_define_method +! #define rb_define_module dll_rb_define_module +! #define rb_define_module_function dll_rb_define_module_function +! #define rb_define_singleton_method dll_rb_define_singleton_method +! #define rb_define_virtual_variable dll_rb_define_virtual_variable +! #define rb_stdout (*dll_rb_stdout) +! #define rb_eArgError (*dll_rb_eArgError) +! #define rb_eIndexError (*dll_rb_eIndexError) +! #define rb_eRuntimeError (*dll_rb_eRuntimeError) +! #define rb_eStandardError (*dll_rb_eStandardError) +! #define rb_eval_string_protect dll_rb_eval_string_protect +! #define rb_global_variable dll_rb_global_variable +! #define rb_hash_aset dll_rb_hash_aset +! #define rb_hash_new dll_rb_hash_new +! #define rb_inspect dll_rb_inspect +! #define rb_int2inum dll_rb_int2inum +! #if SIZEOF_INT < SIZEOF_LONG /* 64 bits only */ +! #define rb_fix2int dll_rb_fix2int +! #define rb_num2int dll_rb_num2int +! #define rb_num2uint dll_rb_num2uint +! #endif +! #define rb_lastline_get dll_rb_lastline_get +! #define rb_lastline_set dll_rb_lastline_set +! #define rb_load_protect dll_rb_load_protect +! #ifndef RUBY19_OR_LATER +! #define rb_num2long dll_rb_num2long +! #endif +! #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER <= 19 +! #define rb_num2ulong dll_rb_num2ulong +! #endif +! #define rb_obj_alloc dll_rb_obj_alloc +! #define rb_obj_as_string dll_rb_obj_as_string +! #define rb_obj_id dll_rb_obj_id +! #define rb_raise dll_rb_raise +! #define rb_str_cat dll_rb_str_cat +! #define rb_str_concat dll_rb_str_concat +! #define rb_str_new dll_rb_str_new +! #ifdef rb_str_new2 + /* Ruby may #define rb_str_new2 to use rb_str_new_cstr. */ +! # define need_rb_str_new_cstr 1 + /* Ruby's headers #define rb_str_new_cstr to make use of GCC's + * __builtin_constant_p extension. */ +! # undef rb_str_new_cstr +! # define rb_str_new_cstr dll_rb_str_new_cstr +! #else +! # define rb_str_new2 dll_rb_str_new2 +! #endif +! #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 +! # define rb_string_value dll_rb_string_value +! # define rb_string_value_ptr dll_rb_string_value_ptr +! # define rb_float_new dll_rb_float_new +! # define rb_ary_new dll_rb_ary_new +! # define rb_ary_push dll_rb_ary_push +! # ifdef __ia64 +! # define rb_ia64_bsp dll_rb_ia64_bsp +! # undef ruby_init_stack +! # define ruby_init_stack(addr) dll_ruby_init_stack((addr), rb_ia64_bsp()) + # else +! # define ruby_init_stack dll_ruby_init_stack + # endif +- #else +- # define rb_str2cstr dll_rb_str2cstr +- #endif +- #ifdef RUBY19_OR_LATER +- # define rb_errinfo dll_rb_errinfo +- #else +- # define ruby_errinfo (*dll_ruby_errinfo) +- #endif +- #define ruby_init dll_ruby_init +- #define ruby_init_loadpath dll_ruby_init_loadpath +- #ifdef WIN3264 +- # define NtInitialize dll_NtInitialize + # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 +! # define rb_w32_snprintf dll_rb_w32_snprintf + # endif +- #endif + +! #ifdef RUBY19_OR_LATER +! # define ruby_script dll_ruby_script +! # define rb_enc_find_index dll_rb_enc_find_index +! # define rb_enc_find dll_rb_enc_find +! # define rb_enc_str_new dll_rb_enc_str_new +! # define rb_sprintf dll_rb_sprintf +! # define rb_require dll_rb_require +! # define ruby_process_options dll_ruby_process_options +! #endif + + /* + * Pointers for dynamic link +--- 158,269 ---- + static void ruby_io_init(void); + static void ruby_vim_init(void); + +! #if defined(__ia64) && !defined(ruby_init_stack) +! # define ruby_init_stack(addr) ruby_init_stack((addr), rb_ia64_bsp()) + #endif + ++ #if defined(DYNAMIC_RUBY) || defined(PROTO) ++ # ifdef PROTO ++ # define HINSTANCE int /* for generating prototypes */ ++ # endif ++ + /* + * Wrapper defines + */ +! # define rb_assoc_new dll_rb_assoc_new +! # define rb_cObject (*dll_rb_cObject) +! # define rb_check_type dll_rb_check_type +! # define rb_class_path dll_rb_class_path +! # define rb_data_object_alloc dll_rb_data_object_alloc +! # define rb_define_class_under dll_rb_define_class_under +! # define rb_define_const dll_rb_define_const +! # define rb_define_global_function dll_rb_define_global_function +! # define rb_define_method dll_rb_define_method +! # define rb_define_module dll_rb_define_module +! # define rb_define_module_function dll_rb_define_module_function +! # define rb_define_singleton_method dll_rb_define_singleton_method +! # define rb_define_virtual_variable dll_rb_define_virtual_variable +! # define rb_stdout (*dll_rb_stdout) +! # define rb_eArgError (*dll_rb_eArgError) +! # define rb_eIndexError (*dll_rb_eIndexError) +! # define rb_eRuntimeError (*dll_rb_eRuntimeError) +! # define rb_eStandardError (*dll_rb_eStandardError) +! # define rb_eval_string_protect dll_rb_eval_string_protect +! # define rb_global_variable dll_rb_global_variable +! # define rb_hash_aset dll_rb_hash_aset +! # define rb_hash_new dll_rb_hash_new +! # define rb_inspect dll_rb_inspect +! # define rb_int2inum dll_rb_int2inum +! # if SIZEOF_INT < SIZEOF_LONG /* 64 bits only */ +! # define rb_fix2int dll_rb_fix2int +! # define rb_num2int dll_rb_num2int +! # define rb_num2uint dll_rb_num2uint +! # endif +! # define rb_lastline_get dll_rb_lastline_get +! # define rb_lastline_set dll_rb_lastline_set +! # define rb_load_protect dll_rb_load_protect +! # ifndef RUBY19_OR_LATER +! # define rb_num2long dll_rb_num2long +! # endif +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER <= 19 +! # define rb_num2ulong dll_rb_num2ulong +! # endif +! # define rb_obj_alloc dll_rb_obj_alloc +! # define rb_obj_as_string dll_rb_obj_as_string +! # define rb_obj_id dll_rb_obj_id +! # define rb_raise dll_rb_raise +! # define rb_str_cat dll_rb_str_cat +! # define rb_str_concat dll_rb_str_concat +! # define rb_str_new dll_rb_str_new +! # ifdef rb_str_new2 + /* Ruby may #define rb_str_new2 to use rb_str_new_cstr. */ +! # define need_rb_str_new_cstr 1 + /* Ruby's headers #define rb_str_new_cstr to make use of GCC's + * __builtin_constant_p extension. */ +! # undef rb_str_new_cstr +! # define rb_str_new_cstr dll_rb_str_new_cstr + # else +! # define rb_str_new2 dll_rb_str_new2 + # endif + # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 +! # define rb_string_value dll_rb_string_value +! # define rb_string_value_ptr dll_rb_string_value_ptr +! # define rb_float_new dll_rb_float_new +! # define rb_ary_new dll_rb_ary_new +! # define rb_ary_push dll_rb_ary_push +! # ifdef __ia64 +! # define rb_ia64_bsp dll_rb_ia64_bsp +! # undef ruby_init_stack +! # define ruby_init_stack(addr) dll_ruby_init_stack((addr), rb_ia64_bsp()) +! # else +! # define ruby_init_stack dll_ruby_init_stack +! # endif +! # else +! # define rb_str2cstr dll_rb_str2cstr +! # endif +! # ifdef RUBY19_OR_LATER +! # define rb_errinfo dll_rb_errinfo +! # else +! # define ruby_errinfo (*dll_ruby_errinfo) +! # endif +! # define ruby_init dll_ruby_init +! # define ruby_init_loadpath dll_ruby_init_loadpath +! # ifdef WIN3264 +! # define NtInitialize dll_NtInitialize +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 +! # define rb_w32_snprintf dll_rb_w32_snprintf +! # endif + # endif + +! # ifdef RUBY19_OR_LATER +! # define ruby_script dll_ruby_script +! # define rb_enc_find_index dll_rb_enc_find_index +! # define rb_enc_find dll_rb_enc_find +! # define rb_enc_str_new dll_rb_enc_str_new +! # define rb_sprintf dll_rb_sprintf +! # define rb_require dll_rb_require +! # define ruby_process_options dll_ruby_process_options +! # endif + + /* + * Pointers for dynamic link +*************** +*** 267,275 **** + static VALUE (*dll_rb_assoc_new) (VALUE, VALUE); + VALUE *dll_rb_cFalseClass; + VALUE *dll_rb_cFixnum; +! #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 20 + VALUE *dll_rb_cFloat; +! #endif + VALUE *dll_rb_cNilClass; + static VALUE *dll_rb_cObject; + VALUE *dll_rb_cSymbol; +--- 271,279 ---- + static VALUE (*dll_rb_assoc_new) (VALUE, VALUE); + VALUE *dll_rb_cFalseClass; + VALUE *dll_rb_cFixnum; +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 20 + VALUE *dll_rb_cFloat; +! # endif + VALUE *dll_rb_cNilClass; + static VALUE *dll_rb_cObject; + VALUE *dll_rb_cSymbol; +*************** +*** 296,306 **** + static VALUE (*dll_rb_hash_new) (void); + static VALUE (*dll_rb_inspect) (VALUE); + static VALUE (*dll_rb_int2inum) (long); +! #if SIZEOF_INT < SIZEOF_LONG /* 64 bits only */ + static long (*dll_rb_fix2int) (VALUE); + static long (*dll_rb_num2int) (VALUE); + static unsigned long (*dll_rb_num2uint) (VALUE); +! #endif + static VALUE (*dll_rb_lastline_get) (void); + static void (*dll_rb_lastline_set) (VALUE); + static void (*dll_rb_load_protect) (VALUE, int, int*); +--- 300,310 ---- + static VALUE (*dll_rb_hash_new) (void); + static VALUE (*dll_rb_inspect) (VALUE); + static VALUE (*dll_rb_int2inum) (long); +! # if SIZEOF_INT < SIZEOF_LONG /* 64 bits only */ + static long (*dll_rb_fix2int) (VALUE); + static long (*dll_rb_num2int) (VALUE); + static unsigned long (*dll_rb_num2uint) (VALUE); +! # endif + static VALUE (*dll_rb_lastline_get) (void); + static void (*dll_rb_lastline_set) (VALUE); + static void (*dll_rb_load_protect) (VALUE, int, int*); +*************** +*** 310,359 **** + static VALUE (*dll_rb_obj_as_string) (VALUE); + static VALUE (*dll_rb_obj_id) (VALUE); + static void (*dll_rb_raise) (VALUE, const char*, ...); +! #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + static VALUE (*dll_rb_string_value) (volatile VALUE*); +! #else + static char *(*dll_rb_str2cstr) (VALUE,int*); +! #endif + static VALUE (*dll_rb_str_cat) (VALUE, const char*, long); + static VALUE (*dll_rb_str_concat) (VALUE, VALUE); + static VALUE (*dll_rb_str_new) (const char*, long); +! #ifdef need_rb_str_new_cstr + /* Ruby may #define rb_str_new2 to use rb_str_new_cstr. */ + static VALUE (*dll_rb_str_new_cstr) (const char*); +! #else + static VALUE (*dll_rb_str_new2) (const char*); +! #endif +! #ifdef RUBY19_OR_LATER + static VALUE (*dll_rb_errinfo) (void); +! #else + static VALUE *dll_ruby_errinfo; +! #endif + static void (*dll_ruby_init) (void); + static void (*dll_ruby_init_loadpath) (void); +! #ifdef WIN3264 + static void (*dll_NtInitialize) (int*, char***); +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + static int (*dll_rb_w32_snprintf)(char*, size_t, const char*, ...); + # endif +! #endif +! #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + static char * (*dll_rb_string_value_ptr) (volatile VALUE*); + static VALUE (*dll_rb_float_new) (double); + static VALUE (*dll_rb_ary_new) (void); + static VALUE (*dll_rb_ary_push) (VALUE, VALUE); +! # ifdef __ia64 + static void * (*dll_rb_ia64_bsp) (void); + static void (*dll_ruby_init_stack)(VALUE*, void*); +! # else + static void (*dll_ruby_init_stack)(VALUE*); + # endif +! #endif +! #ifdef RUBY19_OR_LATER + static VALUE (*dll_rb_int2big)(SIGNED_VALUE); +! #endif + +! #ifdef RUBY19_OR_LATER + static void (*dll_ruby_script) (const char*); + static int (*dll_rb_enc_find_index) (const char*); + static rb_encoding* (*dll_rb_enc_find) (const char*); +--- 314,363 ---- + static VALUE (*dll_rb_obj_as_string) (VALUE); + static VALUE (*dll_rb_obj_id) (VALUE); + static void (*dll_rb_raise) (VALUE, const char*, ...); +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + static VALUE (*dll_rb_string_value) (volatile VALUE*); +! # else + static char *(*dll_rb_str2cstr) (VALUE,int*); +! # endif + static VALUE (*dll_rb_str_cat) (VALUE, const char*, long); + static VALUE (*dll_rb_str_concat) (VALUE, VALUE); + static VALUE (*dll_rb_str_new) (const char*, long); +! # ifdef need_rb_str_new_cstr + /* Ruby may #define rb_str_new2 to use rb_str_new_cstr. */ + static VALUE (*dll_rb_str_new_cstr) (const char*); +! # else + static VALUE (*dll_rb_str_new2) (const char*); +! # endif +! # ifdef RUBY19_OR_LATER + static VALUE (*dll_rb_errinfo) (void); +! # else + static VALUE *dll_ruby_errinfo; +! # endif + static void (*dll_ruby_init) (void); + static void (*dll_ruby_init_loadpath) (void); +! # ifdef WIN3264 + static void (*dll_NtInitialize) (int*, char***); +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + static int (*dll_rb_w32_snprintf)(char*, size_t, const char*, ...); ++ # endif + # endif +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + static char * (*dll_rb_string_value_ptr) (volatile VALUE*); + static VALUE (*dll_rb_float_new) (double); + static VALUE (*dll_rb_ary_new) (void); + static VALUE (*dll_rb_ary_push) (VALUE, VALUE); +! # ifdef __ia64 + static void * (*dll_rb_ia64_bsp) (void); + static void (*dll_ruby_init_stack)(VALUE*, void*); +! # else + static void (*dll_ruby_init_stack)(VALUE*); ++ # endif + # endif +! # ifdef RUBY19_OR_LATER + static VALUE (*dll_rb_int2big)(SIGNED_VALUE); +! # endif + +! # ifdef RUBY19_OR_LATER + static void (*dll_ruby_script) (const char*); + static int (*dll_rb_enc_find_index) (const char*); + static rb_encoding* (*dll_rb_enc_find) (const char*); +*************** +*** 361,369 **** + static VALUE (*dll_rb_sprintf) (const char*, ...); + static VALUE (*dll_rb_require) (const char*); + static void* (*ruby_process_options)(int, char**); +! #endif + +! #if defined(RUBY19_OR_LATER) && !defined(PROTO) + SIGNED_VALUE rb_num2long_stub(VALUE x) + { + return dll_rb_num2long(x); +--- 365,373 ---- + static VALUE (*dll_rb_sprintf) (const char*, ...); + static VALUE (*dll_rb_require) (const char*); + static void* (*ruby_process_options)(int, char**); +! # endif + +! # if defined(RUBY19_OR_LATER) && !defined(PROTO) + SIGNED_VALUE rb_num2long_stub(VALUE x) + { + return dll_rb_num2long(x); +*************** +*** 372,378 **** + { + return dll_rb_int2big(x); + } +! #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 20 \ + && SIZEOF_INT < SIZEOF_LONG + long rb_fix2int_stub(VALUE x) + { +--- 376,382 ---- + { + return dll_rb_int2big(x); + } +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 20 \ + && SIZEOF_INT < SIZEOF_LONG + long rb_fix2int_stub(VALUE x) + { +*************** +*** 382,389 **** + { + return dll_rb_num2int(x); + } +! #endif +! #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 20 + VALUE + rb_float_new_in_heap(double d) + { +--- 386,393 ---- + { + return dll_rb_num2int(x); + } +! # endif +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 20 + VALUE + rb_float_new_in_heap(double d) + { +*************** +*** 393,400 **** + { + return (long)RSHIFT((SIGNED_VALUE)(x),1); + } +! #endif +! #endif + + static HINSTANCE hinstRuby = NULL; /* Instance of ruby.dll */ + +--- 397,404 ---- + { + return (long)RSHIFT((SIGNED_VALUE)(x),1); + } +! # endif +! # endif + + static HINSTANCE hinstRuby = NULL; /* Instance of ruby.dll */ + +*************** +*** 410,418 **** + {"rb_assoc_new", (RUBY_PROC*)&dll_rb_assoc_new}, + {"rb_cFalseClass", (RUBY_PROC*)&dll_rb_cFalseClass}, + {"rb_cFixnum", (RUBY_PROC*)&dll_rb_cFixnum}, +! #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 20 + {"rb_cFloat", (RUBY_PROC*)&dll_rb_cFloat}, +! #endif + {"rb_cNilClass", (RUBY_PROC*)&dll_rb_cNilClass}, + {"rb_cObject", (RUBY_PROC*)&dll_rb_cObject}, + {"rb_cSymbol", (RUBY_PROC*)&dll_rb_cSymbol}, +--- 414,422 ---- + {"rb_assoc_new", (RUBY_PROC*)&dll_rb_assoc_new}, + {"rb_cFalseClass", (RUBY_PROC*)&dll_rb_cFalseClass}, + {"rb_cFixnum", (RUBY_PROC*)&dll_rb_cFixnum}, +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 20 + {"rb_cFloat", (RUBY_PROC*)&dll_rb_cFloat}, +! # endif + {"rb_cNilClass", (RUBY_PROC*)&dll_rb_cNilClass}, + {"rb_cObject", (RUBY_PROC*)&dll_rb_cObject}, + {"rb_cSymbol", (RUBY_PROC*)&dll_rb_cSymbol}, +*************** +*** 439,449 **** + {"rb_hash_new", (RUBY_PROC*)&dll_rb_hash_new}, + {"rb_inspect", (RUBY_PROC*)&dll_rb_inspect}, + {"rb_int2inum", (RUBY_PROC*)&dll_rb_int2inum}, +! #if SIZEOF_INT < SIZEOF_LONG /* 64 bits only */ + {"rb_fix2int", (RUBY_PROC*)&dll_rb_fix2int}, + {"rb_num2int", (RUBY_PROC*)&dll_rb_num2int}, + {"rb_num2uint", (RUBY_PROC*)&dll_rb_num2uint}, +! #endif + {"rb_lastline_get", (RUBY_PROC*)&dll_rb_lastline_get}, + {"rb_lastline_set", (RUBY_PROC*)&dll_rb_lastline_set}, + {"rb_load_protect", (RUBY_PROC*)&dll_rb_load_protect}, +--- 443,453 ---- + {"rb_hash_new", (RUBY_PROC*)&dll_rb_hash_new}, + {"rb_inspect", (RUBY_PROC*)&dll_rb_inspect}, + {"rb_int2inum", (RUBY_PROC*)&dll_rb_int2inum}, +! # if SIZEOF_INT < SIZEOF_LONG /* 64 bits only */ + {"rb_fix2int", (RUBY_PROC*)&dll_rb_fix2int}, + {"rb_num2int", (RUBY_PROC*)&dll_rb_num2int}, + {"rb_num2uint", (RUBY_PROC*)&dll_rb_num2uint}, +! # endif + {"rb_lastline_get", (RUBY_PROC*)&dll_rb_lastline_get}, + {"rb_lastline_set", (RUBY_PROC*)&dll_rb_lastline_set}, + {"rb_load_protect", (RUBY_PROC*)&dll_rb_load_protect}, +*************** +*** 453,505 **** + {"rb_obj_as_string", (RUBY_PROC*)&dll_rb_obj_as_string}, + {"rb_obj_id", (RUBY_PROC*)&dll_rb_obj_id}, + {"rb_raise", (RUBY_PROC*)&dll_rb_raise}, +! #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + {"rb_string_value", (RUBY_PROC*)&dll_rb_string_value}, +! #else + {"rb_str2cstr", (RUBY_PROC*)&dll_rb_str2cstr}, +! #endif + {"rb_str_cat", (RUBY_PROC*)&dll_rb_str_cat}, + {"rb_str_concat", (RUBY_PROC*)&dll_rb_str_concat}, + {"rb_str_new", (RUBY_PROC*)&dll_rb_str_new}, +! #ifdef need_rb_str_new_cstr + {"rb_str_new_cstr", (RUBY_PROC*)&dll_rb_str_new_cstr}, +! #else + {"rb_str_new2", (RUBY_PROC*)&dll_rb_str_new2}, +! #endif +! #ifdef RUBY19_OR_LATER + {"rb_errinfo", (RUBY_PROC*)&dll_rb_errinfo}, +! #else + {"ruby_errinfo", (RUBY_PROC*)&dll_ruby_errinfo}, +! #endif + {"ruby_init", (RUBY_PROC*)&dll_ruby_init}, + {"ruby_init_loadpath", (RUBY_PROC*)&dll_ruby_init_loadpath}, +! #ifdef WIN3264 + { +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER < 19 + "NtInitialize", +! # else + "ruby_sysinit", +! # endif + (RUBY_PROC*)&dll_NtInitialize}, +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + {"rb_w32_snprintf", (RUBY_PROC*)&dll_rb_w32_snprintf}, + # endif +! #endif +! #if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + {"rb_string_value_ptr", (RUBY_PROC*)&dll_rb_string_value_ptr}, +! # ifdef __ia64 + {"rb_ia64_bsp", (RUBY_PROC*)&dll_rb_ia64_bsp}, +! # endif + {"ruby_init_stack", (RUBY_PROC*)&dll_ruby_init_stack}, +! # if DYNAMIC_RUBY_VER <= 19 + {"rb_float_new", (RUBY_PROC*)&dll_rb_float_new}, +! # else + {"rb_float_new_in_heap", (RUBY_PROC*)&dll_rb_float_new}, +! # endif + {"rb_ary_new", (RUBY_PROC*)&dll_rb_ary_new}, + {"rb_ary_push", (RUBY_PROC*)&dll_rb_ary_push}, +! #endif +! #ifdef RUBY19_OR_LATER + {"rb_int2big", (RUBY_PROC*)&dll_rb_int2big}, + {"ruby_script", (RUBY_PROC*)&dll_ruby_script}, + {"rb_enc_find_index", (RUBY_PROC*)&dll_rb_enc_find_index}, +--- 457,509 ---- + {"rb_obj_as_string", (RUBY_PROC*)&dll_rb_obj_as_string}, + {"rb_obj_id", (RUBY_PROC*)&dll_rb_obj_id}, + {"rb_raise", (RUBY_PROC*)&dll_rb_raise}, +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + {"rb_string_value", (RUBY_PROC*)&dll_rb_string_value}, +! # else + {"rb_str2cstr", (RUBY_PROC*)&dll_rb_str2cstr}, +! # endif + {"rb_str_cat", (RUBY_PROC*)&dll_rb_str_cat}, + {"rb_str_concat", (RUBY_PROC*)&dll_rb_str_concat}, + {"rb_str_new", (RUBY_PROC*)&dll_rb_str_new}, +! # ifdef need_rb_str_new_cstr + {"rb_str_new_cstr", (RUBY_PROC*)&dll_rb_str_new_cstr}, +! # else + {"rb_str_new2", (RUBY_PROC*)&dll_rb_str_new2}, +! # endif +! # ifdef RUBY19_OR_LATER + {"rb_errinfo", (RUBY_PROC*)&dll_rb_errinfo}, +! # else + {"ruby_errinfo", (RUBY_PROC*)&dll_ruby_errinfo}, +! # endif + {"ruby_init", (RUBY_PROC*)&dll_ruby_init}, + {"ruby_init_loadpath", (RUBY_PROC*)&dll_ruby_init_loadpath}, +! # ifdef WIN3264 + { +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER < 19 + "NtInitialize", +! # else + "ruby_sysinit", +! # endif + (RUBY_PROC*)&dll_NtInitialize}, +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + {"rb_w32_snprintf", (RUBY_PROC*)&dll_rb_w32_snprintf}, ++ # endif + # endif +! # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + {"rb_string_value_ptr", (RUBY_PROC*)&dll_rb_string_value_ptr}, +! # ifdef __ia64 + {"rb_ia64_bsp", (RUBY_PROC*)&dll_rb_ia64_bsp}, +! # endif + {"ruby_init_stack", (RUBY_PROC*)&dll_ruby_init_stack}, +! # if DYNAMIC_RUBY_VER <= 19 + {"rb_float_new", (RUBY_PROC*)&dll_rb_float_new}, +! # else + {"rb_float_new_in_heap", (RUBY_PROC*)&dll_rb_float_new}, +! # endif + {"rb_ary_new", (RUBY_PROC*)&dll_rb_ary_new}, + {"rb_ary_push", (RUBY_PROC*)&dll_rb_ary_push}, +! # endif +! # ifdef RUBY19_OR_LATER + {"rb_int2big", (RUBY_PROC*)&dll_rb_int2big}, + {"ruby_script", (RUBY_PROC*)&dll_ruby_script}, + {"rb_enc_find_index", (RUBY_PROC*)&dll_rb_enc_find_index}, +*************** +*** 508,514 **** + {"rb_sprintf", (RUBY_PROC*)&dll_rb_sprintf}, + {"rb_require", (RUBY_PROC*)&dll_rb_require}, + {"ruby_process_options", (RUBY_PROC*)&dll_ruby_process_options}, +! #endif + {"", NULL}, + }; + +--- 512,518 ---- + {"rb_sprintf", (RUBY_PROC*)&dll_rb_sprintf}, + {"rb_require", (RUBY_PROC*)&dll_rb_require}, + {"ruby_process_options", (RUBY_PROC*)&dll_ruby_process_options}, +! # endif + {"", NULL}, + }; + +*** ../vim-7.3.935/src/version.c 2013-05-11 17:45:45.000000000 +0200 +--- src/version.c 2013-05-12 14:09:22.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 936, + /**/ + +-- +DEAD PERSON: I don't want to go in the cart! +CUSTOMER: Oh, don't be such a baby. +MORTICIAN: I can't take him... +DEAD PERSON: I feel fine! +CUSTOMER: Oh, do us a favor... +MORTICIAN: I can't. + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4451f1774f106dbe1628b0bc34f757863bc90d30 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 14:12:40 +0200 Subject: [PATCH 0828/3340] - patchlevel 937 --- 7.3.937 | 616 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 616 insertions(+) create mode 100644 7.3.937 diff --git a/7.3.937 b/7.3.937 new file mode 100644 index 00000000..a9bd210c --- /dev/null +++ b/7.3.937 @@ -0,0 +1,616 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.937 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.937 +Problem: More can be shared between Python 2 and 3. +Solution: Move code to if_py_both.h. (ZyX) +Files: src/if_python.c, src/if_python3.c, src/if_py_both.h + + +*** ../vim-7.3.936/src/if_python.c 2013-05-06 04:21:35.000000000 +0200 +--- src/if_python.c 2013-05-12 18:31:20.000000000 +0200 +*************** +*** 619,624 **** +--- 619,627 ---- + + #define DESTRUCTOR_FINISH(self) Py_DECREF(self); + ++ #define WIN_PYTHON_REF(win) win->w_python_ref ++ #define BUF_PYTHON_REF(buf) buf->b_python_ref ++ + static PyObject *OutputGetattr(PyObject *, char *); + static PyObject *BufferGetattr(PyObject *, char *); + static PyObject *WindowGetattr(PyObject *, char *); +*************** +*** 1054,1095 **** + */ + + static PyObject * +- BufferNew(buf_T *buf) +- { +- /* We need to handle deletion of buffers underneath us. +- * If we add a "b_python_ref" field to the buf_T structure, +- * then we can get at it in buf_freeall() in vim. We then +- * need to create only ONE Python object per buffer - if +- * we try to create a second, just INCREF the existing one +- * and return it. The (single) Python object referring to +- * the buffer is stored in "b_python_ref". +- * Question: what to do on a buf_freeall(). We'll probably +- * have to either delete the Python object (DECREF it to +- * zero - a bad idea, as it leaves dangling refs!) or +- * set the buf_T * value to an invalid value (-1?), which +- * means we need checks in all access functions... Bah. +- */ +- +- BufferObject *self; +- +- if (buf->b_python_ref != NULL) +- { +- self = buf->b_python_ref; +- Py_INCREF(self); +- } +- else +- { +- self = PyObject_NEW(BufferObject, &BufferType); +- if (self == NULL) +- return NULL; +- self->buf = buf; +- buf->b_python_ref = self; +- } +- +- return (PyObject *)(self); +- } +- +- static PyObject * + BufferGetattr(PyObject *self, char *name) + { + PyObject *r; +--- 1057,1062 ---- +*************** +*** 1107,1136 **** + /******************/ + + static PyInt +- BufferLength(PyObject *self) +- { +- /* HOW DO WE SIGNAL AN ERROR FROM THIS FUNCTION? */ +- if (CheckBuffer((BufferObject *)(self))) +- return -1; /* ??? */ +- +- return (((BufferObject *)(self))->buf->b_ml.ml_line_count); +- } +- +- static PyObject * +- BufferItem(PyObject *self, PyInt n) +- { +- return RBItem((BufferObject *)(self), n, 1, +- (int)((BufferObject *)(self))->buf->b_ml.ml_line_count); +- } +- +- static PyObject * +- BufferSlice(PyObject *self, PyInt lo, PyInt hi) +- { +- return RBSlice((BufferObject *)(self), lo, hi, 1, +- (int)((BufferObject *)(self))->buf->b_ml.ml_line_count); +- } +- +- static PyInt + BufferAssItem(PyObject *self, PyInt n, PyObject *val) + { + return RBAsItem((BufferObject *)(self), n, val, 1, +--- 1074,1079 ---- +*************** +*** 1217,1256 **** + */ + + static PyObject * +- WindowNew(win_T *win) +- { +- /* We need to handle deletion of windows underneath us. +- * If we add a "w_python_ref" field to the win_T structure, +- * then we can get at it in win_free() in vim. We then +- * need to create only ONE Python object per window - if +- * we try to create a second, just INCREF the existing one +- * and return it. The (single) Python object referring to +- * the window is stored in "w_python_ref". +- * On a win_free() we set the Python object's win_T* field +- * to an invalid value. We trap all uses of a window +- * object, and reject them if the win_T* field is invalid. +- */ +- +- WindowObject *self; +- +- if (win->w_python_ref) +- { +- self = win->w_python_ref; +- Py_INCREF(self); +- } +- else +- { +- self = PyObject_NEW(WindowObject, &WindowType); +- if (self == NULL) +- return NULL; +- self->win = win; +- win->w_python_ref = self; +- } +- +- return (PyObject *)(self); +- } +- +- static PyObject * + WindowGetattr(PyObject *self, char *name) + { + PyObject *r; +--- 1160,1165 ---- +*************** +*** 1289,1299 **** + void + python_buffer_free(buf_T *buf) + { +! if (buf->b_python_ref != NULL) + { +! BufferObject *bp = buf->b_python_ref; + bp->buf = INVALID_BUFFER_VALUE; +! buf->b_python_ref = NULL; + } + } + +--- 1198,1208 ---- + void + python_buffer_free(buf_T *buf) + { +! if (BUF_PYTHON_REF(buf) != NULL) + { +! BufferObject *bp = BUF_PYTHON_REF(buf); + bp->buf = INVALID_BUFFER_VALUE; +! BUF_PYTHON_REF(buf) = NULL; + } + } + +*************** +*** 1301,1311 **** + void + python_window_free(win_T *win) + { +! if (win->w_python_ref != NULL) + { +! WindowObject *wp = win->w_python_ref; + wp->win = INVALID_WINDOW_VALUE; +! win->w_python_ref = NULL; + } + } + #endif +--- 1210,1220 ---- + void + python_window_free(win_T *win) + { +! if (WIN_PYTHON_REF(win) != NULL) + { +! WindowObject *wp = WIN_PYTHON_REF(win); + wp->win = INVALID_WINDOW_VALUE; +! WIN_PYTHON_REF(win) = NULL; + } + } + #endif +*** ../vim-7.3.936/src/if_python3.c 2013-05-06 04:21:35.000000000 +0200 +--- src/if_python3.c 2013-05-12 18:31:20.000000000 +0200 +*************** +*** 621,626 **** +--- 621,629 ---- + + #define DESTRUCTOR_FINISH(self) Py_TYPE(self)->tp_free((PyObject*)self); + ++ #define WIN_PYTHON_REF(win) win->w_python3_ref ++ #define BUF_PYTHON_REF(buf) buf->b_python3_ref ++ + static void + call_PyObject_Free(void *p) + { +*************** +*** 1067,1112 **** + }; + + +! /* Buffer object - Definitions + */ + + static PyObject * +- BufferNew(buf_T *buf) +- { +- /* We need to handle deletion of buffers underneath us. +- * If we add a "b_python3_ref" field to the buf_T structure, +- * then we can get at it in buf_freeall() in vim. We then +- * need to create only ONE Python object per buffer - if +- * we try to create a second, just INCREF the existing one +- * and return it. The (single) Python object referring to +- * the buffer is stored in "b_python3_ref". +- * Question: what to do on a buf_freeall(). We'll probably +- * have to either delete the Python object (DECREF it to +- * zero - a bad idea, as it leaves dangling refs!) or +- * set the buf_T * value to an invalid value (-1?), which +- * means we need checks in all access functions... Bah. +- */ +- +- BufferObject *self; +- +- if (buf->b_python3_ref != NULL) +- { +- self = buf->b_python3_ref; +- Py_INCREF(self); +- } +- else +- { +- self = PyObject_NEW(BufferObject, &BufferType); +- buf->b_python3_ref = self; +- if (self == NULL) +- return NULL; +- self->buf = buf; +- } +- +- return (PyObject *)(self); +- } +- +- static PyObject * + BufferGetattro(PyObject *self, PyObject*nameobj) + { + PyObject *r; +--- 1070,1079 ---- + }; + + +! /* Buffer object + */ + + static PyObject * + BufferGetattro(PyObject *self, PyObject*nameobj) + { + PyObject *r; +*************** +*** 1132,1160 **** + + /******************/ + +- static Py_ssize_t +- BufferLength(PyObject *self) +- { +- if (CheckBuffer((BufferObject *)(self))) +- return -1; +- +- return (Py_ssize_t)(((BufferObject *)(self))->buf->b_ml.ml_line_count); +- } +- +- static PyObject * +- BufferItem(PyObject *self, Py_ssize_t n) +- { +- return RBItem((BufferObject *)(self), n, 1, +- (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count); +- } +- +- static PyObject * +- BufferSlice(PyObject *self, Py_ssize_t lo, Py_ssize_t hi) +- { +- return RBSlice((BufferObject *)(self), lo, hi, 1, +- (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count); +- } +- + static PyObject * + BufferSubscript(PyObject *self, PyObject* idx) + { +--- 1099,1104 ---- +*************** +*** 1342,1381 **** + */ + + static PyObject * +- WindowNew(win_T *win) +- { +- /* We need to handle deletion of windows underneath us. +- * If we add a "w_python3_ref" field to the win_T structure, +- * then we can get at it in win_free() in vim. We then +- * need to create only ONE Python object per window - if +- * we try to create a second, just INCREF the existing one +- * and return it. The (single) Python object referring to +- * the window is stored in "w_python3_ref". +- * On a win_free() we set the Python object's win_T* field +- * to an invalid value. We trap all uses of a window +- * object, and reject them if the win_T* field is invalid. +- */ +- +- WindowObject *self; +- +- if (win->w_python3_ref) +- { +- self = win->w_python3_ref; +- Py_INCREF(self); +- } +- else +- { +- self = PyObject_NEW(WindowObject, &WindowType); +- if (self == NULL) +- return NULL; +- self->win = win; +- win->w_python3_ref = self; +- } +- +- return (PyObject *)(self); +- } +- +- static PyObject * + WindowGetattro(PyObject *self, PyObject *nameobj) + { + PyObject *r; +--- 1286,1291 ---- +*************** +*** 1575,1585 **** + void + python3_buffer_free(buf_T *buf) + { +! if (buf->b_python3_ref != NULL) + { +! BufferObject *bp = buf->b_python3_ref; + bp->buf = INVALID_BUFFER_VALUE; +! buf->b_python3_ref = NULL; + } + } + +--- 1485,1495 ---- + void + python3_buffer_free(buf_T *buf) + { +! if (BUF_PYTHON_REF(buf) != NULL) + { +! BufferObject *bp = BUF_PYTHON_REF(buf); + bp->buf = INVALID_BUFFER_VALUE; +! BUF_PYTHON_REF(buf) = NULL; + } + } + +*************** +*** 1587,1597 **** + void + python3_window_free(win_T *win) + { +! if (win->w_python3_ref != NULL) + { +! WindowObject *wp = win->w_python3_ref; + wp->win = INVALID_WINDOW_VALUE; +! win->w_python3_ref = NULL; + } + } + #endif +--- 1497,1507 ---- + void + python3_window_free(win_T *win) + { +! if (WIN_PYTHON_REF(win) != NULL) + { +! WindowObject *wp = WIN_PYTHON_REF(win); + wp->win = INVALID_WINDOW_VALUE; +! WIN_PYTHON_REF(win) = NULL; + } + } + #endif +*** ../vim-7.3.936/src/if_py_both.h 2013-05-06 06:26:10.000000000 +0200 +--- src/if_py_both.h 2013-05-12 18:31:20.000000000 +0200 +*************** +*** 1782,1792 **** +--- 1782,1832 ---- + return 0; + } + ++ /* Window object ++ */ ++ + static int WindowSetattr(PyObject *, char *, PyObject *); + static PyObject *WindowRepr(PyObject *); + static PyTypeObject WindowType; + + static PyObject * ++ WindowNew(win_T *win) ++ { ++ /* We need to handle deletion of windows underneath us. ++ * If we add a "w_python*_ref" field to the win_T structure, ++ * then we can get at it in win_free() in vim. We then ++ * need to create only ONE Python object per window - if ++ * we try to create a second, just INCREF the existing one ++ * and return it. The (single) Python object referring to ++ * the window is stored in "w_python*_ref". ++ * On a win_free() we set the Python object's win_T* field ++ * to an invalid value. We trap all uses of a window ++ * object, and reject them if the win_T* field is invalid. ++ * ++ * Python2 and Python3 get different fields and different objects: ++ * w_python_ref and w_python3_ref fields respectively. ++ */ ++ ++ WindowObject *self; ++ ++ if (WIN_PYTHON_REF(win)) ++ { ++ self = WIN_PYTHON_REF(win); ++ Py_INCREF(self); ++ } ++ else ++ { ++ self = PyObject_NEW(WindowObject, &WindowType); ++ if (self == NULL) ++ return NULL; ++ self->win = win; ++ WIN_PYTHON_REF(win) = self; ++ } ++ ++ return (PyObject *)(self); ++ } ++ ++ static PyObject * + WindowAttr(WindowObject *this, char *name) + { + if (strcmp(name, "buffer") == 0) +*************** +*** 1809,1815 **** + return OptionsNew(SREQ_WIN, this->win, (checkfun) CheckWindow, + (PyObject *) this); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[sssss]", "buffer", "cursor", "height", "vars", + "options"); + else + return NULL; +--- 1849,1855 ---- + return OptionsNew(SREQ_WIN, this->win, (checkfun) CheckWindow, + (PyObject *) this); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[ssssss]", "buffer", "cursor", "height", "vars", + "options"); + else + return NULL; +*************** +*** 1821,1831 **** + WindowObject *this = (WindowObject *)(self); + + if (this->win && this->win != INVALID_WINDOW_VALUE) +! #if PY_MAJOR_VERSION >= 3 +! this->win->w_python3_ref = NULL; +! #else +! this->win->w_python_ref = NULL; +! #endif + + DESTRUCTOR_FINISH(self); + } +--- 1861,1867 ---- + WindowObject *this = (WindowObject *)(self); + + if (this->win && this->win != INVALID_WINDOW_VALUE) +! WIN_PYTHON_REF(this->win) = NULL; + + DESTRUCTOR_FINISH(self); + } +*************** +*** 2756,2771 **** + BufferObject *this = (BufferObject *)(self); + + if (this->buf && this->buf != INVALID_BUFFER_VALUE) +! #if PY_MAJOR_VERSION >= 3 +! this->buf->b_python3_ref = NULL; +! #else +! this->buf->b_python_ref = NULL; +! #endif + + DESTRUCTOR_FINISH(self); + } + + static PyObject * + BufferAttr(BufferObject *this, char *name) + { + if (strcmp(name, "name") == 0) +--- 2792,2842 ---- + BufferObject *this = (BufferObject *)(self); + + if (this->buf && this->buf != INVALID_BUFFER_VALUE) +! BUF_PYTHON_REF(this->buf) = NULL; + + DESTRUCTOR_FINISH(self); + } + + static PyObject * ++ BufferNew(buf_T *buf) ++ { ++ /* We need to handle deletion of buffers underneath us. ++ * If we add a "b_python*_ref" field to the buf_T structure, ++ * then we can get at it in buf_freeall() in vim. We then ++ * need to create only ONE Python object per buffer - if ++ * we try to create a second, just INCREF the existing one ++ * and return it. The (single) Python object referring to ++ * the buffer is stored in "b_python*_ref". ++ * Question: what to do on a buf_freeall(). We'll probably ++ * have to either delete the Python object (DECREF it to ++ * zero - a bad idea, as it leaves dangling refs!) or ++ * set the buf_T * value to an invalid value (-1?), which ++ * means we need checks in all access functions... Bah. ++ * ++ * Python2 and Python3 get different fields and different objects: ++ * b_python_ref and b_python3_ref fields respectively. ++ */ ++ ++ BufferObject *self; ++ ++ if (BUF_PYTHON_REF(buf) != NULL) ++ { ++ self = BUF_PYTHON_REF(buf); ++ Py_INCREF(self); ++ } ++ else ++ { ++ self = PyObject_NEW(BufferObject, &BufferType); ++ if (self == NULL) ++ return NULL; ++ self->buf = buf; ++ BUF_PYTHON_REF(buf) = self; ++ } ++ ++ return (PyObject *)(self); ++ } ++ ++ static PyObject * + BufferAttr(BufferObject *this, char *name) + { + if (strcmp(name, "name") == 0) +*************** +*** 2783,2788 **** +--- 2854,2883 ---- + return NULL; + } + ++ static PyInt ++ BufferLength(PyObject *self) ++ { ++ /* HOW DO WE SIGNAL AN ERROR FROM THIS FUNCTION? */ ++ if (CheckBuffer((BufferObject *)(self))) ++ return -1; /* ??? */ ++ ++ return (PyInt)(((BufferObject *)(self))->buf->b_ml.ml_line_count); ++ } ++ ++ static PyObject * ++ BufferItem(PyObject *self, PyInt n) ++ { ++ return RBItem((BufferObject *)(self), n, 1, ++ (PyInt)((BufferObject *)(self))->buf->b_ml.ml_line_count); ++ } ++ ++ static PyObject * ++ BufferSlice(PyObject *self, PyInt lo, PyInt hi) ++ { ++ return RBSlice((BufferObject *)(self), lo, hi, 1, ++ (PyInt)((BufferObject *)(self))->buf->b_ml.ml_line_count); ++ } ++ + static PyObject * + BufferAppend(PyObject *self, PyObject *args) + { +*** ../vim-7.3.936/src/version.c 2013-05-12 14:10:41.000000000 +0200 +--- src/version.c 2013-05-12 18:44:01.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 937, + /**/ + +-- +ARTHUR: Well, I can't just call you `Man'. +DENNIS: Well, you could say `Dennis'. +ARTHUR: Well, I didn't know you were called `Dennis.' +DENNIS: Well, you didn't bother to find out, did you? + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6f24d0a5cdfcd1bb85cc3c161c453912eaec4c0a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 14:12:41 +0200 Subject: [PATCH 0829/3340] - patchlevel 938 --- 7.3.938 | 145 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 145 insertions(+) create mode 100644 7.3.938 diff --git a/7.3.938 b/7.3.938 new file mode 100644 index 00000000..df8d37a6 --- /dev/null +++ b/7.3.938 @@ -0,0 +1,145 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.938 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.938 +Problem: Python: not easy to get to window number. +Solution: Add vim.window.number. (ZyX) +Files: runtime/doc/if_pyth.txt, src/if_py_both.h, src/proto/window.pro, + src/window.c + + +*** ../vim-7.3.937/runtime/doc/if_pyth.txt 2013-05-06 03:52:44.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-05-12 18:55:41.000000000 +0200 +*************** +*** 396,401 **** +--- 396,405 ---- + |python-options|. If option is |global-local| + and local value is missing getting it will + return None. ++ number (read-only) Window number. The first window has number 1. ++ This is zero in case it cannot be determined ++ (e.g. when the window object belongs to other ++ tab page). + The height attribute is writable only if the screen is split horizontally. + The width attribute is writable only if the screen is split vertically. + +*** ../vim-7.3.937/src/if_py_both.h 2013-05-12 18:44:44.000000000 +0200 +--- src/if_py_both.h 2013-05-12 18:48:07.000000000 +0200 +*************** +*** 1848,1856 **** + else if (strcmp(name, "options") == 0) + return OptionsNew(SREQ_WIN, this->win, (checkfun) CheckWindow, + (PyObject *) this); + else if (strcmp(name,"__members__") == 0) + return Py_BuildValue("[ssssss]", "buffer", "cursor", "height", "vars", +! "options"); + else + return NULL; + } +--- 1848,1858 ---- + else if (strcmp(name, "options") == 0) + return OptionsNew(SREQ_WIN, this->win, (checkfun) CheckWindow, + (PyObject *) this); ++ else if (strcmp(name, "number") == 0) ++ return PyLong_FromLong((long) get_win_number(this->win)); + else if (strcmp(name,"__members__") == 0) + return Py_BuildValue("[ssssss]", "buffer", "cursor", "height", "vars", +! "options", "number"); + else + return NULL; + } +*************** +*** 1974,1990 **** + } + else + { +! int i = 0; +! win_T *w; + +! for (w = firstwin; w != NULL && w != this->win; w = W_NEXT(w)) +! ++i; +! +! if (w == NULL) + vim_snprintf(repr, 100, _(""), + (self)); + else +! vim_snprintf(repr, 100, _(""), i); + + return PyString_FromString(repr); + } +--- 1976,1988 ---- + } + else + { +! int w = get_win_number(this->win); + +! if (w == 0) + vim_snprintf(repr, 100, _(""), + (self)); + else +! vim_snprintf(repr, 100, _(""), w - 1); + + return PyString_FromString(repr); + } +*** ../vim-7.3.937/src/proto/window.pro 2013-05-06 04:50:26.000000000 +0200 +--- src/proto/window.pro 2013-05-12 18:48:07.000000000 +0200 +*************** +*** 74,77 **** +--- 74,78 ---- + int match_delete __ARGS((win_T *wp, int id, int perr)); + void clear_matches __ARGS((win_T *wp)); + matchitem_T *get_match __ARGS((win_T *wp, int id)); ++ int get_win_number __ARGS((win_T *wp)); + /* vim: set ft=c : */ +*** ../vim-7.3.937/src/window.c 2013-05-06 04:50:26.000000000 +0200 +--- src/window.c 2013-05-12 18:48:07.000000000 +0200 +*************** +*** 6731,6733 **** +--- 6731,6750 ---- + return cur; + } + #endif ++ ++ #if defined(FEAT_PYTHON) || defined(FEAT_PYTHON3) || defined(PROTO) ++ int ++ get_win_number(win_T *wp) ++ { ++ int i = 1; ++ win_T *w; ++ ++ for (w = firstwin; w != NULL && w != wp; w = W_NEXT(w)) ++ ++i; ++ ++ if (w == NULL) ++ return 0; ++ else ++ return i; ++ } ++ #endif +*** ../vim-7.3.937/src/version.c 2013-05-12 18:44:44.000000000 +0200 +--- src/version.c 2013-05-12 18:52:29.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 938, + /**/ + +-- +ARTHUR: I did say sorry about the `old woman,' but from the behind you + looked-- +DENNIS: What I object to is you automatically treat me like an inferior! +ARTHUR: Well, I AM king... + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b3d5f539cd3841d000833e415cb218e4f4497cde Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 14:12:41 +0200 Subject: [PATCH 0830/3340] - patchlevel 939 --- 7.3.939 | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 7.3.939 diff --git a/7.3.939 b/7.3.939 new file mode 100644 index 00000000..3b8b7167 --- /dev/null +++ b/7.3.939 @@ -0,0 +1,60 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.939 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.939 +Problem: Using Py_BuildValue is inefficient sometimes. +Solution: Use PyLong_FromLong(). (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.938/src/if_py_both.h 2013-05-12 19:00:36.000000000 +0200 +--- src/if_py_both.h 2013-05-12 19:08:24.000000000 +0200 +*************** +*** 1838,1847 **** + return Py_BuildValue("(ll)", (long)(pos->lnum), (long)(pos->col)); + } + else if (strcmp(name, "height") == 0) +! return Py_BuildValue("l", (long)(this->win->w_height)); + #ifdef FEAT_VERTSPLIT + else if (strcmp(name, "width") == 0) +! return Py_BuildValue("l", (long)(W_WIDTH(this->win))); + #endif + else if (strcmp(name, "vars") == 0) + return DictionaryNew(this->win->w_vars); +--- 1838,1847 ---- + return Py_BuildValue("(ll)", (long)(pos->lnum), (long)(pos->col)); + } + else if (strcmp(name, "height") == 0) +! return PyLong_FromLong((long)(this->win->w_height)); + #ifdef FEAT_VERTSPLIT + else if (strcmp(name, "width") == 0) +! return PyLong_FromLong((long)(W_WIDTH(this->win))); + #endif + else if (strcmp(name, "vars") == 0) + return DictionaryNew(this->win->w_vars); +*** ../vim-7.3.938/src/version.c 2013-05-12 19:00:36.000000000 +0200 +--- src/version.c 2013-05-12 19:09:19.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 939, + /**/ + +-- +A mathematician is a device for turning coffee into theorems. + Paul Erdos +A computer programmer is a device for turning coffee into bugs. + Bram Moolenaar + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f99b4a2fd3420ccc068f244d0a40699bff465ea5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 14:12:42 +0200 Subject: [PATCH 0831/3340] - patchlevel 940 --- 7.3.940 | 87 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 87 insertions(+) create mode 100644 7.3.940 diff --git a/7.3.940 b/7.3.940 new file mode 100644 index 00000000..07209b0b --- /dev/null +++ b/7.3.940 @@ -0,0 +1,87 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.940 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.940 +Problem: Python: Can't get position of window. +Solution: Add window.row and window.col. (ZyX) +Files: runtime/doc/if_pyth.txt, src/if_py_both.h + + +*** ../vim-7.3.939/runtime/doc/if_pyth.txt 2013-05-12 19:00:36.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-05-12 19:24:40.000000000 +0200 +*************** +*** 400,405 **** +--- 400,408 ---- + This is zero in case it cannot be determined + (e.g. when the window object belongs to other + tab page). ++ row, col (read-only) On-screen window position in display cells. ++ First position is zero. ++ + The height attribute is writable only if the screen is split horizontally. + The width attribute is writable only if the screen is split vertically. + +*** ../vim-7.3.939/src/if_py_both.h 2013-05-12 19:09:46.000000000 +0200 +--- src/if_py_both.h 2013-05-12 19:22:16.000000000 +0200 +*************** +*** 1839,1847 **** +--- 1839,1853 ---- + } + else if (strcmp(name, "height") == 0) + return PyLong_FromLong((long)(this->win->w_height)); ++ #ifdef FEAT_WINDOWS ++ else if (strcmp(name, "row") == 0) ++ return PyLong_FromLong((long)(this->win->w_winrow)); ++ #endif + #ifdef FEAT_VERTSPLIT + else if (strcmp(name, "width") == 0) + return PyLong_FromLong((long)(W_WIDTH(this->win))); ++ else if (strcmp(name, "col") == 0) ++ return PyLong_FromLong((long)(W_WINCOL(this->win))); + #endif + else if (strcmp(name, "vars") == 0) + return DictionaryNew(this->win->w_vars); +*************** +*** 1851,1858 **** + else if (strcmp(name, "number") == 0) + return PyLong_FromLong((long) get_win_number(this->win)); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[ssssss]", "buffer", "cursor", "height", "vars", +! "options", "number"); + else + return NULL; + } +--- 1857,1864 ---- + else if (strcmp(name, "number") == 0) + return PyLong_FromLong((long) get_win_number(this->win)); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[ssssssss]", "buffer", "cursor", "height", "vars", +! "options", "number", "row", "col"); + else + return NULL; + } +*** ../vim-7.3.939/src/version.c 2013-05-12 19:09:46.000000000 +0200 +--- src/version.c 2013-05-12 19:23:50.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 940, + /**/ + +-- +A computer programmer is a device for turning requirements into +undocumented features. It runs on cola, pizza and Dilbert cartoons. + Bram Moolenaar + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ffc55f25e10c8dbaad7d4876902188d423c90238 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 14:12:43 +0200 Subject: [PATCH 0832/3340] - patchlevel 941 --- 7.3.941 | 1456 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1456 insertions(+) create mode 100644 7.3.941 diff --git a/7.3.941 b/7.3.941 new file mode 100644 index 00000000..c7792aa8 --- /dev/null +++ b/7.3.941 @@ -0,0 +1,1456 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.941 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.941 +Problem: Stuff in if_py_both.h is ordered badly. +Solution: Reorder by type. (ZyX) +Files: src/if_py_both.h, src/if_python.c + + +*** ../vim-7.3.940/src/if_py_both.h 2013-05-12 19:30:27.000000000 +0200 +--- src/if_py_both.h 2013-05-12 19:36:38.000000000 +0200 +*************** +*** 7,13 **** + * See README.txt for an overview of the Vim source code. + */ + /* +! * Python extensions by Paul Moore, David Leonard, Roland Puntaier. + * + * Common code for if_python.c and if_python3.c. + */ +--- 7,14 ---- + * See README.txt for an overview of the Vim source code. + */ + /* +! * Python extensions by Paul Moore, David Leonard, Roland Puntaier, Nikolay +! * Pavlov. + * + * Common code for if_python.c and if_python3.c. + */ +*************** +*** 22,27 **** +--- 23,39 ---- + # define ENC_OPT "latin1" + #endif + ++ #define PyErr_SetVim(str) PyErr_SetString(VimError, str) ++ ++ #define INVALID_BUFFER_VALUE ((buf_T *)(-1)) ++ #define INVALID_WINDOW_VALUE ((win_T *)(-1)) ++ ++ static int ConvertFromPyObject(PyObject *, typval_T *); ++ static int _ConvertFromPyObject(PyObject *, typval_T *, PyObject *); ++ ++ static PyInt RangeStart; ++ static PyInt RangeEnd; ++ + /* + * obtain a lock on the Vim data structures + */ +*************** +*** 38,53 **** + { + } + +! /* Output object definition + */ + +- static PyObject *OutputWrite(PyObject *, PyObject *); +- static PyObject *OutputWritelines(PyObject *, PyObject *); +- static PyObject *OutputFlush(PyObject *, PyObject *); +- + /* Function to write a line, points to either msg() or emsg(). */ + typedef void (*writefn)(char_u *); +! static void writer(writefn fn, char_u *str, PyInt n); + + typedef struct + { +--- 50,62 ---- + { + } + +! /* Output buffer management + */ + + /* Function to write a line, points to either msg() or emsg(). */ + typedef void (*writefn)(char_u *); +! +! static PyTypeObject OutputType; + + typedef struct + { +*************** +*** 56,76 **** + long error; + } OutputObject; + +- static struct PyMethodDef OutputMethods[] = { +- /* name, function, calling, documentation */ +- {"write", OutputWrite, 1, ""}, +- {"writelines", OutputWritelines, 1, ""}, +- {"flush", OutputFlush, 1, ""}, +- { NULL, NULL, 0, NULL} +- }; +- +- #define PyErr_SetVim(str) PyErr_SetString(VimError, str) +- +- /*************/ +- +- /* Output buffer management +- */ +- + static int + OutputSetattr(PyObject *self, char *name, PyObject *val) + { +--- 65,70 ---- +*************** +*** 96,101 **** +--- 90,145 ---- + return -1; + } + ++ /* Buffer IO, we write one whole line at a time. */ ++ static garray_T io_ga = {0, 0, 1, 80, NULL}; ++ static writefn old_fn = NULL; ++ ++ static void ++ PythonIO_Flush(void) ++ { ++ if (old_fn != NULL && io_ga.ga_len > 0) ++ { ++ ((char_u *)io_ga.ga_data)[io_ga.ga_len] = NUL; ++ old_fn((char_u *)io_ga.ga_data); ++ } ++ io_ga.ga_len = 0; ++ } ++ ++ static void ++ writer(writefn fn, char_u *str, PyInt n) ++ { ++ char_u *ptr; ++ ++ /* Flush when switching output function. */ ++ if (fn != old_fn) ++ PythonIO_Flush(); ++ old_fn = fn; ++ ++ /* Write each NL separated line. Text after the last NL is kept for ++ * writing later. */ ++ while (n > 0 && (ptr = memchr(str, '\n', n)) != NULL) ++ { ++ PyInt len = ptr - str; ++ ++ if (ga_grow(&io_ga, (int)(len + 1)) == FAIL) ++ break; ++ ++ mch_memmove(((char *)io_ga.ga_data) + io_ga.ga_len, str, (size_t)len); ++ ((char *)io_ga.ga_data)[io_ga.ga_len + len] = NUL; ++ fn((char_u *)io_ga.ga_data); ++ str = ptr + 1; ++ n -= len + 1; ++ io_ga.ga_len = 0; ++ } ++ ++ /* Put the remaining text into io_ga for later printing. */ ++ if (n > 0 && ga_grow(&io_ga, (int)(n + 1)) == OK) ++ { ++ mch_memmove(((char *)io_ga.ga_data) + io_ga.ga_len, str, (size_t)n); ++ io_ga.ga_len += (int)n; ++ } ++ } ++ + static PyObject * + OutputWrite(PyObject *self, PyObject *args) + { +*************** +*** 172,231 **** + return Py_None; + } + +- +- /* Buffer IO, we write one whole line at a time. */ +- static garray_T io_ga = {0, 0, 1, 80, NULL}; +- static writefn old_fn = NULL; +- +- static void +- PythonIO_Flush(void) +- { +- if (old_fn != NULL && io_ga.ga_len > 0) +- { +- ((char_u *)io_ga.ga_data)[io_ga.ga_len] = NUL; +- old_fn((char_u *)io_ga.ga_data); +- } +- io_ga.ga_len = 0; +- } +- +- static void +- writer(writefn fn, char_u *str, PyInt n) +- { +- char_u *ptr; +- +- /* Flush when switching output function. */ +- if (fn != old_fn) +- PythonIO_Flush(); +- old_fn = fn; +- +- /* Write each NL separated line. Text after the last NL is kept for +- * writing later. */ +- while (n > 0 && (ptr = memchr(str, '\n', n)) != NULL) +- { +- PyInt len = ptr - str; +- +- if (ga_grow(&io_ga, (int)(len + 1)) == FAIL) +- break; +- +- mch_memmove(((char *)io_ga.ga_data) + io_ga.ga_len, str, (size_t)len); +- ((char *)io_ga.ga_data)[io_ga.ga_len + len] = NUL; +- fn((char_u *)io_ga.ga_data); +- str = ptr + 1; +- n -= len + 1; +- io_ga.ga_len = 0; +- } +- +- /* Put the remaining text into io_ga for later printing. */ +- if (n > 0 && ga_grow(&io_ga, (int)(n + 1)) == OK) +- { +- mch_memmove(((char *)io_ga.ga_data) + io_ga.ga_len, str, (size_t)n); +- io_ga.ga_len += (int)n; +- } +- } +- + /***************/ + +! static PyTypeObject OutputType; + + static OutputObject Output = + { +--- 216,230 ---- + return Py_None; + } + + /***************/ + +! static struct PyMethodDef OutputMethods[] = { +! /* name, function, calling, documentation */ +! {"write", OutputWrite, 1, ""}, +! {"writelines", OutputWritelines, 1, ""}, +! {"flush", OutputFlush, 1, ""}, +! { NULL, NULL, 0, NULL} +! }; + + static OutputObject Output = + { +*************** +*** 281,286 **** +--- 280,286 ---- + + /* Vim module - Implementation + */ ++ + static PyObject * + VimCommand(PyObject *self UNUSED, PyObject *args) + { +*************** +*** 530,555 **** + { NULL, NULL, 0, NULL } + }; + +- typedef struct +- { +- PyObject_HEAD +- buf_T *buf; +- } BufferObject; +- +- #define INVALID_BUFFER_VALUE ((buf_T *)(-1)) +- + /* + * Buffer list object - Implementation + */ + + typedef struct + { + PyObject_HEAD + } BufListObject; + +- static PyTypeObject BufListType; +- static PySequenceMethods WinListAsSeq; +- + static PyInt + BufListLength(PyObject *self UNUSED) + { +--- 530,547 ---- + { NULL, NULL, 0, NULL } + }; + + /* + * Buffer list object - Implementation + */ + ++ static PyTypeObject BufListType; ++ static PySequenceMethods BufListAsSeq; ++ + typedef struct + { + PyObject_HEAD + } BufListObject; + + static PyInt + BufListLength(PyObject *self UNUSED) + { +*************** +*** 580,599 **** + return NULL; + } + +- typedef struct +- { +- PyObject_HEAD +- win_T *win; +- } WindowObject; +- +- static struct PyMethodDef WindowMethods[] = { +- /* name, function, calling, documentation */ +- { NULL, NULL, 0, NULL } +- }; +- +- static int ConvertFromPyObject(PyObject *, typval_T *); +- static int _ConvertFromPyObject(PyObject *, typval_T *, PyObject *); +- + typedef struct pylinkedlist_S { + struct pylinkedlist_S *pll_next; + struct pylinkedlist_S *pll_prev; +--- 572,577 ---- +*************** +*** 655,670 **** + pylinkedlist_T ref; + } DictionaryObject; + +- static PyInt DictionaryAssItem(PyObject *, PyObject *, PyObject *); +- static PyInt DictionaryLength(PyObject *); +- static PyObject *DictionaryItem(PyObject *, PyObject *); +- +- static PyMappingMethods DictionaryAsMapping = { +- (lenfunc) DictionaryLength, +- (binaryfunc) DictionaryItem, +- (objobjargproc) DictionaryAssItem, +- }; +- + static PyObject * + DictionaryNew(dict_T *dict) + { +--- 633,638 ---- +*************** +*** 693,895 **** + } + + static int +! pydict_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) + { +! dict_T *d; +! char_u *key; +! dictitem_T *di; +! PyObject *keyObject; +! PyObject *valObject; +! Py_ssize_t iter = 0; + +! d = dict_alloc(); +! if (d == NULL) + { +! PyErr_NoMemory(); + return -1; + } + +! tv->v_type = VAR_DICT; +! tv->vval.v_dict = d; +! +! while (PyDict_Next(obj, &iter, &keyObject, &valObject)) + { +! DICTKEY_DECL +! +! if (keyObject == NULL) +! return -1; +! if (valObject == NULL) +! return -1; +! +! DICTKEY_GET_NOTEMPTY(-1) +! +! di = dictitem_alloc(key); +! +! DICTKEY_UNREF +! +! if (di == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! di->di_tv.v_lock = 0; +! +! if (_ConvertFromPyObject(valObject, &di->di_tv, lookupDict) == -1) + { +! vim_free(di); + return -1; + } +! if (dict_add(d, di) == FAIL) + { +! vim_free(di); +! PyErr_SetVim(_("failed to add key to dictionary")); +! return -1; + } + } +- return 0; + } + +! static int +! pymap_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) + { +- dict_T *d; + char_u *key; + dictitem_T *di; +! PyObject *list; +! PyObject *litem; +! PyObject *keyObject; +! PyObject *valObject; +! Py_ssize_t lsize; +! +! d = dict_alloc(); +! if (d == NULL) +! { +! PyErr_NoMemory(); +! return -1; +! } +! +! tv->v_type = VAR_DICT; +! tv->vval.v_dict = d; +! +! list = PyMapping_Items(obj); +! if (list == NULL) +! return -1; +! lsize = PyList_Size(list); +! while (lsize--) +! { +! DICTKEY_DECL +! +! litem = PyList_GetItem(list, lsize); +! if (litem == NULL) +! { +! Py_DECREF(list); +! return -1; +! } +! +! keyObject = PyTuple_GetItem(litem, 0); +! if (keyObject == NULL) +! { +! Py_DECREF(list); +! Py_DECREF(litem); +! return -1; +! } +! +! DICTKEY_GET_NOTEMPTY(-1) +! +! valObject = PyTuple_GetItem(litem, 1); +! if (valObject == NULL) +! { +! Py_DECREF(list); +! Py_DECREF(litem); +! return -1; +! } +! +! di = dictitem_alloc(key); +! +! DICTKEY_UNREF +! +! if (di == NULL) +! { +! Py_DECREF(list); +! Py_DECREF(litem); +! PyErr_NoMemory(); +! return -1; +! } +! di->di_tv.v_lock = 0; +! +! if (_ConvertFromPyObject(valObject, &di->di_tv, lookupDict) == -1) +! { +! vim_free(di); +! Py_DECREF(list); +! Py_DECREF(litem); +! return -1; +! } +! if (dict_add(d, di) == FAIL) +! { +! vim_free(di); +! Py_DECREF(list); +! Py_DECREF(litem); +! PyErr_SetVim(_("failed to add key to dictionary")); +! return -1; +! } +! Py_DECREF(litem); +! } +! Py_DECREF(list); +! return 0; +! } +! +! static int +! DictionarySetattr(PyObject *self, char *name, PyObject *val) +! { +! DictionaryObject *this = (DictionaryObject *)(self); +! +! if (val == NULL) +! { +! PyErr_SetString(PyExc_AttributeError, _("Cannot delete DictionaryObject attributes")); +! return -1; +! } +! +! if (strcmp(name, "locked") == 0) +! { +! if (this->dict->dv_lock == VAR_FIXED) +! { +! PyErr_SetString(PyExc_TypeError, _("Cannot modify fixed dictionary")); +! return -1; +! } +! else +! { +! if (!PyBool_Check(val)) +! { +! PyErr_SetString(PyExc_TypeError, _("Only boolean objects are allowed")); +! return -1; +! } +! +! if (val == Py_True) +! this->dict->dv_lock = VAR_LOCKED; +! else +! this->dict->dv_lock = 0; +! } +! return 0; +! } +! else +! { +! PyErr_SetString(PyExc_AttributeError, _("Cannot set this attribute")); +! return -1; +! } +! } +! +! static PyInt +! DictionaryLength(PyObject *self) +! { +! return ((PyInt) ((((DictionaryObject *)(self))->dict->dv_hashtab.ht_used))); +! } +! +! static PyObject * +! DictionaryItem(PyObject *self, PyObject *keyObject) +! { +! char_u *key; +! dictitem_T *di; +! DICTKEY_DECL + + DICTKEY_GET_NOTEMPTY(NULL) + +--- 661,717 ---- + } + + static int +! DictionarySetattr(PyObject *self, char *name, PyObject *val) + { +! DictionaryObject *this = (DictionaryObject *)(self); + +! if (val == NULL) + { +! PyErr_SetString(PyExc_AttributeError, _("Cannot delete DictionaryObject attributes")); + return -1; + } + +! if (strcmp(name, "locked") == 0) + { +! if (this->dict->dv_lock == VAR_FIXED) + { +! PyErr_SetString(PyExc_TypeError, _("Cannot modify fixed dictionary")); + return -1; + } +! else + { +! if (!PyBool_Check(val)) +! { +! PyErr_SetString(PyExc_TypeError, _("Only boolean objects are allowed")); +! return -1; +! } +! +! if (val == Py_True) +! this->dict->dv_lock = VAR_LOCKED; +! else +! this->dict->dv_lock = 0; + } ++ return 0; ++ } ++ else ++ { ++ PyErr_SetString(PyExc_AttributeError, _("Cannot set this attribute")); ++ return -1; + } + } + +! static PyInt +! DictionaryLength(PyObject *self) +! { +! return ((PyInt) ((((DictionaryObject *)(self))->dict->dv_hashtab.ht_used))); +! } +! +! static PyObject * +! DictionaryItem(PyObject *self, PyObject *keyObject) + { + char_u *key; + dictitem_T *di; +! DICTKEY_DECL + + DICTKEY_GET_NOTEMPTY(NULL) + +*************** +*** 993,998 **** +--- 815,826 ---- + return r; + } + ++ static PyMappingMethods DictionaryAsMapping = { ++ (lenfunc) DictionaryLength, ++ (binaryfunc) DictionaryItem, ++ (objobjargproc) DictionaryAssItem, ++ }; ++ + static struct PyMethodDef DictionaryMethods[] = { + {"keys", (PyCFunction)DictionaryListKeys, METH_NOARGS, ""}, + { NULL, NULL, 0, NULL } +*************** +*** 1065,1136 **** + return 0; + } + +- static int +- pyseq_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) +- { +- list_T *l; +- +- l = list_alloc(); +- if (l == NULL) +- { +- PyErr_NoMemory(); +- return -1; +- } +- +- tv->v_type = VAR_LIST; +- tv->vval.v_list = l; +- +- if (list_py_concat(l, obj, lookupDict) == -1) +- return -1; +- +- return 0; +- } +- +- static int +- pyiter_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) +- { +- PyObject *iterator = PyObject_GetIter(obj); +- PyObject *item; +- list_T *l; +- listitem_T *li; +- +- l = list_alloc(); +- +- if (l == NULL) +- { +- PyErr_NoMemory(); +- return -1; +- } +- +- tv->vval.v_list = l; +- tv->v_type = VAR_LIST; +- +- +- if (iterator == NULL) +- return -1; +- +- while ((item = PyIter_Next(obj))) +- { +- li = listitem_alloc(); +- if (li == NULL) +- { +- PyErr_NoMemory(); +- return -1; +- } +- li->li_tv.v_lock = 0; +- +- if (_ConvertFromPyObject(item, &li->li_tv, lookupDict) == -1) +- return -1; +- +- list_append(l, li); +- +- Py_DECREF(item); +- } +- +- Py_DECREF(iterator); +- return 0; +- } +- + static PyInt + ListLength(PyObject *self) + { +--- 893,898 ---- +*************** +*** 1768,1774 **** + (objobjargproc) OptionsAssItem, + }; + +! #define INVALID_WINDOW_VALUE ((win_T *)(-1)) + + static int + CheckWindow(WindowObject *this) +--- 1530,1547 ---- + (objobjargproc) OptionsAssItem, + }; + +! /* Window object +! */ +! +! typedef struct +! { +! PyObject_HEAD +! win_T *win; +! } WindowObject; +! +! static int WindowSetattr(PyObject *, char *, PyObject *); +! static PyObject *WindowRepr(PyObject *); +! static PyTypeObject WindowType; + + static int + CheckWindow(WindowObject *this) +*************** +*** 1782,1794 **** + return 0; + } + +- /* Window object +- */ +- +- static int WindowSetattr(PyObject *, char *, PyObject *); +- static PyObject *WindowRepr(PyObject *); +- static PyTypeObject WindowType; +- + static PyObject * + WindowNew(win_T *win) + { +--- 1555,1560 ---- +*************** +*** 1803,1809 **** + * to an invalid value. We trap all uses of a window + * object, and reject them if the win_T* field is invalid. + * +! * Python2 and Python3 get different fields and different objects: + * w_python_ref and w_python3_ref fields respectively. + */ + +--- 1569,1575 ---- + * to an invalid value. We trap all uses of a window + * object, and reject them if the win_T* field is invalid. + * +! * Python2 and Python3 get different fields and different objects: + * w_python_ref and w_python3_ref fields respectively. + */ + +*************** +*** 1826,1831 **** +--- 1592,1608 ---- + return (PyObject *)(self); + } + ++ static void ++ WindowDestructor(PyObject *self) ++ { ++ WindowObject *this = (WindowObject *)(self); ++ ++ if (this->win && this->win != INVALID_WINDOW_VALUE) ++ WIN_PYTHON_REF(this->win) = NULL; ++ ++ DESTRUCTOR_FINISH(self); ++ } ++ + static PyObject * + WindowAttr(WindowObject *this, char *name) + { +*************** +*** 1863,1879 **** + return NULL; + } + +- static void +- WindowDestructor(PyObject *self) +- { +- WindowObject *this = (WindowObject *)(self); +- +- if (this->win && this->win != INVALID_WINDOW_VALUE) +- WIN_PYTHON_REF(this->win) = NULL; +- +- DESTRUCTOR_FINISH(self); +- } +- + static int + WindowSetattr(PyObject *self, char *name, PyObject *val) + { +--- 1640,1645 ---- +*************** +*** 1994,2011 **** + } + } + + /* +! * Window list object - Implementation + */ + + typedef struct + { + PyObject_HEAD + } WinListObject; + +- static PyTypeObject WinListType; +- static PySequenceMethods BufListAsSeq; +- + static PyInt + WinListLength(PyObject *self UNUSED) + { +--- 1760,1782 ---- + } + } + ++ static struct PyMethodDef WindowMethods[] = { ++ /* name, function, calling, documentation */ ++ { NULL, NULL, 0, NULL } ++ }; ++ + /* +! * Window list object + */ + ++ static PyTypeObject WinListType; ++ static PySequenceMethods WinListAsSeq; ++ + typedef struct + { + PyObject_HEAD + } WinListObject; + + static PyInt + WinListLength(PyObject *self UNUSED) + { +*************** +*** 2596,2602 **** + * ------------------------------------------- + */ + +! static int + CheckBuffer(BufferObject *this) + { + if (this->buf == INVALID_BUFFER_VALUE) +--- 2367,2379 ---- + * ------------------------------------------- + */ + +! typedef struct +! { +! PyObject_HEAD +! buf_T *buf; +! } BufferObject; +! +! static int + CheckBuffer(BufferObject *this) + { + if (this->buf == INVALID_BUFFER_VALUE) +*************** +*** 2737,2746 **** + return Py_None; + } + +! /* Range object - Definitions + */ + + static PyTypeObject RangeType; + + typedef struct + { +--- 2514,2525 ---- + return Py_None; + } + +! /* Range object + */ + + static PyTypeObject RangeType; ++ static PySequenceMethods RangeAsSeq; ++ static PyMappingMethods RangeAsMapping; + + typedef struct + { +*************** +*** 2750,2759 **** + PyInt end; + } RangeObject; + +- static void RangeDestructor(PyObject *); +- static PySequenceMethods RangeAsSeq; +- static PyMappingMethods RangeAsMapping; +- + static PyObject * + RangeNew(buf_T *buf, PyInt start, PyInt end) + { +--- 2529,2534 ---- +*************** +*** 2785,2806 **** + DESTRUCTOR_FINISH(self); + } + +! static PyTypeObject BufferType; +! static PyObject *BufferRepr(PyObject *); +! static PySequenceMethods BufferAsSeq; +! static PyMappingMethods BufferAsMapping; + +! static void +! BufferDestructor(PyObject *self) + { +! BufferObject *this = (BufferObject *)(self); + +! if (this->buf && this->buf != INVALID_BUFFER_VALUE) +! BUF_PYTHON_REF(this->buf) = NULL; + +! DESTRUCTOR_FINISH(self); + } + + static PyObject * + BufferNew(buf_T *buf) + { +--- 2560,2642 ---- + DESTRUCTOR_FINISH(self); + } + +! static PyInt +! RangeLength(PyObject *self) +! { +! /* HOW DO WE SIGNAL AN ERROR FROM THIS FUNCTION? */ +! if (CheckBuffer(((RangeObject *)(self))->buf)) +! return -1; /* ??? */ + +! return (((RangeObject *)(self))->end - ((RangeObject *)(self))->start + 1); +! } +! +! static PyObject * +! RangeItem(PyObject *self, PyInt n) + { +! return RBItem(((RangeObject *)(self))->buf, n, +! ((RangeObject *)(self))->start, +! ((RangeObject *)(self))->end); +! } + +! static PyObject * +! RangeSlice(PyObject *self, PyInt lo, PyInt hi) +! { +! return RBSlice(((RangeObject *)(self))->buf, lo, hi, +! ((RangeObject *)(self))->start, +! ((RangeObject *)(self))->end); +! } + +! static PyObject * +! RangeAppend(PyObject *self, PyObject *args) +! { +! return RBAppend(((RangeObject *)(self))->buf, args, +! ((RangeObject *)(self))->start, +! ((RangeObject *)(self))->end, +! &((RangeObject *)(self))->end); +! } +! +! static PyObject * +! RangeRepr(PyObject *self) +! { +! static char repr[100]; +! RangeObject *this = (RangeObject *)(self); +! +! if (this->buf->buf == INVALID_BUFFER_VALUE) +! { +! vim_snprintf(repr, 100, "", +! (self)); +! return PyString_FromString(repr); +! } +! else +! { +! char *name = (char *)this->buf->buf->b_fname; +! int len; +! +! if (name == NULL) +! name = ""; +! len = (int)strlen(name); +! +! if (len > 45) +! name = name + (45 - len); +! +! vim_snprintf(repr, 100, "", +! len > 45 ? "..." : "", name, +! this->start, this->end); +! +! return PyString_FromString(repr); +! } + } + ++ static struct PyMethodDef RangeMethods[] = { ++ /* name, function, calling, documentation */ ++ {"append", RangeAppend, 1, "Append data to the Vim range" }, ++ { NULL, NULL, 0, NULL } ++ }; ++ ++ static PyTypeObject BufferType; ++ static PySequenceMethods BufferAsSeq; ++ static PyMappingMethods BufferAsMapping; ++ + static PyObject * + BufferNew(buf_T *buf) + { +*************** +*** 2817,2823 **** + * set the buf_T * value to an invalid value (-1?), which + * means we need checks in all access functions... Bah. + * +! * Python2 and Python3 get different fields and different objects: + * b_python_ref and b_python3_ref fields respectively. + */ + +--- 2653,2659 ---- + * set the buf_T * value to an invalid value (-1?), which + * means we need checks in all access functions... Bah. + * +! * Python2 and Python3 get different fields and different objects: + * b_python_ref and b_python3_ref fields respectively. + */ + +*************** +*** 2840,2861 **** + return (PyObject *)(self); + } + +! static PyObject * +! BufferAttr(BufferObject *this, char *name) + { +! if (strcmp(name, "name") == 0) +! return Py_BuildValue("s", this->buf->b_ffname); +! else if (strcmp(name, "number") == 0) +! return Py_BuildValue(Py_ssize_t_fmt, this->buf->b_fnum); +! else if (strcmp(name, "vars") == 0) +! return DictionaryNew(this->buf->b_vars); +! else if (strcmp(name, "options") == 0) +! return OptionsNew(SREQ_BUF, this->buf, (checkfun) CheckBuffer, +! (PyObject *) this); +! else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[ssss]", "name", "number", "vars", "options"); +! else +! return NULL; + } + + static PyInt +--- 2676,2690 ---- + return (PyObject *)(self); + } + +! static void +! BufferDestructor(PyObject *self) + { +! BufferObject *this = (BufferObject *)(self); +! +! if (this->buf && this->buf != INVALID_BUFFER_VALUE) +! BUF_PYTHON_REF(this->buf) = NULL; +! +! DESTRUCTOR_FINISH(self); + } + + static PyInt +*************** +*** 2883,2888 **** +--- 2712,2735 ---- + } + + static PyObject * ++ BufferAttr(BufferObject *this, char *name) ++ { ++ if (strcmp(name, "name") == 0) ++ return Py_BuildValue("s", this->buf->b_ffname); ++ else if (strcmp(name, "number") == 0) ++ return Py_BuildValue(Py_ssize_t_fmt, this->buf->b_fnum); ++ else if (strcmp(name, "vars") == 0) ++ return DictionaryNew(this->buf->b_vars); ++ else if (strcmp(name, "options") == 0) ++ return OptionsNew(SREQ_BUF, this->buf, (checkfun) CheckBuffer, ++ (PyObject *) this); ++ else if (strcmp(name,"__members__") == 0) ++ return Py_BuildValue("[ssss]", "name", "number", "vars", "options"); ++ else ++ return NULL; ++ } ++ ++ static PyObject * + BufferAppend(PyObject *self, PyObject *args) + { + return RBAppend((BufferObject *)(self), args, 1, +*************** +*** 2985,3073 **** + { NULL, NULL, 0, NULL } + }; + +! static PyObject * +! RangeAppend(PyObject *self, PyObject *args) +! { +! return RBAppend(((RangeObject *)(self))->buf, args, +! ((RangeObject *)(self))->start, +! ((RangeObject *)(self))->end, +! &((RangeObject *)(self))->end); +! } +! +! static PyInt +! RangeLength(PyObject *self) +! { +! /* HOW DO WE SIGNAL AN ERROR FROM THIS FUNCTION? */ +! if (CheckBuffer(((RangeObject *)(self))->buf)) +! return -1; /* ??? */ +! +! return (((RangeObject *)(self))->end - ((RangeObject *)(self))->start + 1); +! } +! +! static PyObject * +! RangeItem(PyObject *self, PyInt n) +! { +! return RBItem(((RangeObject *)(self))->buf, n, +! ((RangeObject *)(self))->start, +! ((RangeObject *)(self))->end); +! } +! +! static PyObject * +! RangeRepr(PyObject *self) +! { +! static char repr[100]; +! RangeObject *this = (RangeObject *)(self); +! +! if (this->buf->buf == INVALID_BUFFER_VALUE) +! { +! vim_snprintf(repr, 100, "", +! (self)); +! return PyString_FromString(repr); +! } +! else +! { +! char *name = (char *)this->buf->buf->b_fname; +! int len; +! +! if (name == NULL) +! name = ""; +! len = (int)strlen(name); +! +! if (len > 45) +! name = name + (45 - len); +! +! vim_snprintf(repr, 100, "", +! len > 45 ? "..." : "", name, +! this->start, this->end); +! +! return PyString_FromString(repr); +! } +! } +! +! static PyObject * +! RangeSlice(PyObject *self, PyInt lo, PyInt hi) +! { +! return RBSlice(((RangeObject *)(self))->buf, lo, hi, +! ((RangeObject *)(self))->start, +! ((RangeObject *)(self))->end); +! } +! +! /* +! * Line range object - Definitions +! */ +! +! static struct PyMethodDef RangeMethods[] = { +! /* name, function, calling, documentation */ +! {"append", RangeAppend, 1, "Append data to the Vim range" }, +! { NULL, NULL, 0, NULL } +! }; +! +! /* Current items object - Implementation + */ + +- static PyInt RangeStart; +- static PyInt RangeEnd; +- + static PyObject * + CurrentGetattr(PyObject *self UNUSED, char *name) + { +--- 2832,2840 ---- + { NULL, NULL, 0, NULL } + }; + +! /* Current items object + */ + + static PyObject * + CurrentGetattr(PyObject *self UNUSED, char *name) + { +*************** +*** 3147,3152 **** +--- 2914,3131 ---- + return 0; + } + ++ static int ++ pydict_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) ++ { ++ dict_T *d; ++ char_u *key; ++ dictitem_T *di; ++ PyObject *keyObject; ++ PyObject *valObject; ++ Py_ssize_t iter = 0; ++ ++ d = dict_alloc(); ++ if (d == NULL) ++ { ++ PyErr_NoMemory(); ++ return -1; ++ } ++ ++ tv->v_type = VAR_DICT; ++ tv->vval.v_dict = d; ++ ++ while (PyDict_Next(obj, &iter, &keyObject, &valObject)) ++ { ++ DICTKEY_DECL ++ ++ if (keyObject == NULL) ++ return -1; ++ if (valObject == NULL) ++ return -1; ++ ++ DICTKEY_GET_NOTEMPTY(-1) ++ ++ di = dictitem_alloc(key); ++ ++ DICTKEY_UNREF ++ ++ if (di == NULL) ++ { ++ PyErr_NoMemory(); ++ return -1; ++ } ++ di->di_tv.v_lock = 0; ++ ++ if (_ConvertFromPyObject(valObject, &di->di_tv, lookupDict) == -1) ++ { ++ vim_free(di); ++ return -1; ++ } ++ if (dict_add(d, di) == FAIL) ++ { ++ vim_free(di); ++ PyErr_SetVim(_("failed to add key to dictionary")); ++ return -1; ++ } ++ } ++ return 0; ++ } ++ ++ static int ++ pymap_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) ++ { ++ dict_T *d; ++ char_u *key; ++ dictitem_T *di; ++ PyObject *list; ++ PyObject *litem; ++ PyObject *keyObject; ++ PyObject *valObject; ++ Py_ssize_t lsize; ++ ++ d = dict_alloc(); ++ if (d == NULL) ++ { ++ PyErr_NoMemory(); ++ return -1; ++ } ++ ++ tv->v_type = VAR_DICT; ++ tv->vval.v_dict = d; ++ ++ list = PyMapping_Items(obj); ++ if (list == NULL) ++ return -1; ++ lsize = PyList_Size(list); ++ while (lsize--) ++ { ++ DICTKEY_DECL ++ ++ litem = PyList_GetItem(list, lsize); ++ if (litem == NULL) ++ { ++ Py_DECREF(list); ++ return -1; ++ } ++ ++ keyObject = PyTuple_GetItem(litem, 0); ++ if (keyObject == NULL) ++ { ++ Py_DECREF(list); ++ Py_DECREF(litem); ++ return -1; ++ } ++ ++ DICTKEY_GET_NOTEMPTY(-1) ++ ++ valObject = PyTuple_GetItem(litem, 1); ++ if (valObject == NULL) ++ { ++ Py_DECREF(list); ++ Py_DECREF(litem); ++ return -1; ++ } ++ ++ di = dictitem_alloc(key); ++ ++ DICTKEY_UNREF ++ ++ if (di == NULL) ++ { ++ Py_DECREF(list); ++ Py_DECREF(litem); ++ PyErr_NoMemory(); ++ return -1; ++ } ++ di->di_tv.v_lock = 0; ++ ++ if (_ConvertFromPyObject(valObject, &di->di_tv, lookupDict) == -1) ++ { ++ vim_free(di); ++ Py_DECREF(list); ++ Py_DECREF(litem); ++ return -1; ++ } ++ if (dict_add(d, di) == FAIL) ++ { ++ vim_free(di); ++ Py_DECREF(list); ++ Py_DECREF(litem); ++ PyErr_SetVim(_("failed to add key to dictionary")); ++ return -1; ++ } ++ Py_DECREF(litem); ++ } ++ Py_DECREF(list); ++ return 0; ++ } ++ ++ static int ++ pyseq_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) ++ { ++ list_T *l; ++ ++ l = list_alloc(); ++ if (l == NULL) ++ { ++ PyErr_NoMemory(); ++ return -1; ++ } ++ ++ tv->v_type = VAR_LIST; ++ tv->vval.v_list = l; ++ ++ if (list_py_concat(l, obj, lookupDict) == -1) ++ return -1; ++ ++ return 0; ++ } ++ ++ static int ++ pyiter_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) ++ { ++ PyObject *iterator = PyObject_GetIter(obj); ++ PyObject *item; ++ list_T *l; ++ listitem_T *li; ++ ++ l = list_alloc(); ++ ++ if (l == NULL) ++ { ++ PyErr_NoMemory(); ++ return -1; ++ } ++ ++ tv->vval.v_list = l; ++ tv->v_type = VAR_LIST; ++ ++ ++ if (iterator == NULL) ++ return -1; ++ ++ while ((item = PyIter_Next(obj))) ++ { ++ li = listitem_alloc(); ++ if (li == NULL) ++ { ++ PyErr_NoMemory(); ++ return -1; ++ } ++ li->li_tv.v_lock = 0; ++ ++ if (_ConvertFromPyObject(item, &li->li_tv, lookupDict) == -1) ++ return -1; ++ ++ list_append(l, li); ++ ++ Py_DECREF(item); ++ } ++ ++ Py_DECREF(iterator); ++ return 0; ++ } ++ + typedef int (*pytotvfunc)(PyObject *, typval_T *, PyObject *); + + static int +*** ../vim-7.3.940/src/if_python.c 2013-05-12 18:44:44.000000000 +0200 +--- src/if_python.c 2013-05-12 19:34:35.000000000 +0200 +*************** +*** 1019,1027 **** + + #define BufferType_Check(obj) ((obj)->ob_type == &BufferType) + +- static PyInt BufferLength(PyObject *); +- static PyObject *BufferItem(PyObject *, PyInt); +- static PyObject *BufferSlice(PyObject *, PyInt, PyInt); + static PyInt BufferAssItem(PyObject *, PyInt, PyObject *); + static PyInt BufferAssSlice(PyObject *, PyInt, PyInt, PyObject *); + +--- 1019,1024 ---- +*** ../vim-7.3.940/src/version.c 2013-05-12 19:30:27.000000000 +0200 +--- src/version.c 2013-05-12 19:37:08.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 941, + /**/ + +-- +ARTHUR: Well, I AM king... +DENNIS: Oh king, eh, very nice. An' how'd you get that, eh? By exploitin' + the workers -- by 'angin' on to outdated imperialist dogma which + perpetuates the economic an' social differences in our society! If + there's ever going to be any progress-- + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From abbeab1d8c44825cd74c05047facf15152bbb558 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 14:12:44 +0200 Subject: [PATCH 0833/3340] - patchlevel 942 --- 7.3.942 | 205 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 205 insertions(+) create mode 100644 7.3.942 diff --git a/7.3.942 b/7.3.942 new file mode 100644 index 00000000..2ce3d164 --- /dev/null +++ b/7.3.942 @@ -0,0 +1,205 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.942 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.942 +Problem: Python: SEGV in Buffer functions. +Solution: Call CheckBuffer() at the right time. (ZyX) +Files: src/if_py_both.h, src/if_python.c, src/if_python3.c + + +*** ../vim-7.3.941/src/if_py_both.h 2013-05-12 19:45:30.000000000 +0200 +--- src/if_py_both.h 2013-05-12 20:19:08.000000000 +0200 +*************** +*** 2391,2396 **** +--- 2391,2399 ---- + if (CheckBuffer(self)) + return NULL; + ++ if (end == -1) ++ end = self->buf->b_ml.ml_line_count; ++ + if (n < 0 || n > end - start) + { + PyErr_SetString(PyExc_IndexError, _("line number out of range")); +*************** +*** 2408,2413 **** +--- 2411,2419 ---- + if (CheckBuffer(self)) + return NULL; + ++ if (end == -1) ++ end = self->buf->b_ml.ml_line_count; ++ + size = end - start + 1; + + if (lo < 0) +*************** +*** 2432,2437 **** +--- 2438,2446 ---- + if (CheckBuffer(self)) + return -1; + ++ if (end == -1) ++ end = self->buf->b_ml.ml_line_count; ++ + if (n < 0 || n > end - start) + { + PyErr_SetString(PyExc_IndexError, _("line number out of range")); +*************** +*** 2457,2462 **** +--- 2466,2474 ---- + if (CheckBuffer(self)) + return -1; + ++ if (end == -1) ++ end = self->buf->b_ml.ml_line_count; ++ + /* Sort out the slice range */ + size = end - start + 1; + +*************** +*** 2493,2498 **** +--- 2505,2513 ---- + if (CheckBuffer(self)) + return NULL; + ++ if (end == -1) ++ end = self->buf->b_ml.ml_line_count; ++ + max = n = end - start + 1; + + if (!PyArg_ParseTuple(args, "O|n", &lines, &n)) +*************** +*** 2700,2714 **** + static PyObject * + BufferItem(PyObject *self, PyInt n) + { +! return RBItem((BufferObject *)(self), n, 1, +! (PyInt)((BufferObject *)(self))->buf->b_ml.ml_line_count); + } + + static PyObject * + BufferSlice(PyObject *self, PyInt lo, PyInt hi) + { +! return RBSlice((BufferObject *)(self), lo, hi, 1, +! (PyInt)((BufferObject *)(self))->buf->b_ml.ml_line_count); + } + + static PyObject * +--- 2715,2727 ---- + static PyObject * + BufferItem(PyObject *self, PyInt n) + { +! return RBItem((BufferObject *)(self), n, 1, -1); + } + + static PyObject * + BufferSlice(PyObject *self, PyInt lo, PyInt hi) + { +! return RBSlice((BufferObject *)(self), lo, hi, 1, -1); + } + + static PyObject * +*************** +*** 2732,2740 **** + static PyObject * + BufferAppend(PyObject *self, PyObject *args) + { +! return RBAppend((BufferObject *)(self), args, 1, +! (PyInt)((BufferObject *)(self))->buf->b_ml.ml_line_count, +! NULL); + } + + static PyObject * +--- 2745,2751 ---- + static PyObject * + BufferAppend(PyObject *self, PyObject *args) + { +! return RBAppend((BufferObject *)(self), args, 1, -1, NULL); + } + + static PyObject * +*** ../vim-7.3.941/src/if_python.c 2013-05-12 19:45:30.000000000 +0200 +--- src/if_python.c 2013-05-12 20:19:08.000000000 +0200 +*************** +*** 1073,1089 **** + static PyInt + BufferAssItem(PyObject *self, PyInt n, PyObject *val) + { +! return RBAsItem((BufferObject *)(self), n, val, 1, +! (PyInt)((BufferObject *)(self))->buf->b_ml.ml_line_count, +! NULL); + } + + static PyInt + BufferAssSlice(PyObject *self, PyInt lo, PyInt hi, PyObject *val) + { +! return RBAsSlice((BufferObject *)(self), lo, hi, val, 1, +! (PyInt)((BufferObject *)(self))->buf->b_ml.ml_line_count, +! NULL); + } + + static PySequenceMethods RangeAsSeq = { +--- 1073,1085 ---- + static PyInt + BufferAssItem(PyObject *self, PyInt n, PyObject *val) + { +! return RBAsItem((BufferObject *)(self), n, val, 1, -1, NULL); + } + + static PyInt + BufferAssSlice(PyObject *self, PyInt lo, PyInt hi, PyObject *val) + { +! return RBAsSlice((BufferObject *)(self), lo, hi, val, 1, -1, NULL); + } + + static PySequenceMethods RangeAsSeq = { +*** ../vim-7.3.941/src/if_python3.c 2013-05-12 18:44:44.000000000 +0200 +--- src/if_python3.c 2013-05-12 20:19:08.000000000 +0200 +*************** +*** 1110,1115 **** +--- 1110,1118 ---- + { + Py_ssize_t start, stop, step, slicelen; + ++ if (CheckBuffer((BufferObject *) self)) ++ return NULL; ++ + if (PySlice_GetIndicesEx((PyObject *)idx, + (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count+1, + &start, &stop, +*************** +*** 1139,1144 **** +--- 1142,1150 ---- + { + Py_ssize_t start, stop, step, slicelen; + ++ if (CheckBuffer((BufferObject *) self)) ++ return -1; ++ + if (PySlice_GetIndicesEx((PyObject *)idx, + (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count+1, + &start, &stop, +*** ../vim-7.3.941/src/version.c 2013-05-12 19:45:30.000000000 +0200 +--- src/version.c 2013-05-12 19:49:58.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 942, + /**/ + +-- +Vim is like Emacs without all the typing. (John "Johann" Spetz) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 50f7bcc4970a52bc9cddeb8500908e7319254bae Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 14:12:45 +0200 Subject: [PATCH 0834/3340] - patchlevel 943 --- 7.3.943 | 267 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 267 insertions(+) create mode 100644 7.3.943 diff --git a/7.3.943 b/7.3.943 new file mode 100644 index 00000000..5d1de0c5 --- /dev/null +++ b/7.3.943 @@ -0,0 +1,267 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.943 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.943 +Problem: Python: Negative indices were failing. +Solution: Fix negative indices. Add tests. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/testdir/test86.in, + src/testdir/test86.ok, src/testdir/test87.in, + src/testdir/test87.ok + + +*** ../vim-7.3.942/src/if_py_both.h 2013-05-12 20:36:09.000000000 +0200 +--- src/if_py_both.h 2013-05-12 21:10:03.000000000 +0200 +*************** +*** 2394,2399 **** +--- 2394,2402 ---- + if (end == -1) + end = self->buf->b_ml.ml_line_count; + ++ if (n < 0) ++ n += end - start + 1; ++ + if (n < 0 || n > end - start) + { + PyErr_SetString(PyExc_IndexError, _("line number out of range")); +*************** +*** 2441,2446 **** +--- 2444,2452 ---- + if (end == -1) + end = self->buf->b_ml.ml_line_count; + ++ if (n < 0) ++ n += end - start + 1; ++ + if (n < 0 || n > end - start) + { + PyErr_SetString(PyExc_IndexError, _("line number out of range")); +*** ../vim-7.3.942/src/if_python3.c 2013-05-12 20:36:09.000000000 +0200 +--- src/if_python3.c 2013-05-12 21:10:03.000000000 +0200 +*************** +*** 1114,1120 **** + return NULL; + + if (PySlice_GetIndicesEx((PyObject *)idx, +! (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count+1, + &start, &stop, + &step, &slicelen) < 0) + { +--- 1114,1120 ---- + return NULL; + + if (PySlice_GetIndicesEx((PyObject *)idx, +! (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count, + &start, &stop, + &step, &slicelen) < 0) + { +*************** +*** 1146,1152 **** + return -1; + + if (PySlice_GetIndicesEx((PyObject *)idx, +! (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count+1, + &start, &stop, + &step, &slicelen) < 0) + { +--- 1146,1152 ---- + return -1; + + if (PySlice_GetIndicesEx((PyObject *)idx, +! (Py_ssize_t)((BufferObject *)(self))->buf->b_ml.ml_line_count, + &start, &stop, + &step, &slicelen) < 0) + { +*** ../vim-7.3.942/src/testdir/test86.in 2013-05-06 03:52:44.000000000 +0200 +--- src/testdir/test86.in 2013-05-12 21:11:43.000000000 +0200 +*************** +*** 475,483 **** + : endtry + : endfor + : call RecVars(oname) +- endtry + :endfor + :only + :endfun + :" + :call Test() +--- 475,524 ---- + : endtry + : endfor + : call RecVars(oname) + :endfor + :only ++ :" ++ :" Test buffer object ++ :vnew ++ :put ='First line' ++ :put ='Second line' ++ :put ='Third line' ++ :1 delete _ ++ :py b=vim.current.buffer ++ :wincmd w ++ :mark a ++ py << EOF ++ cb = vim.current.buffer ++ # Tests BufferAppend and BufferItem ++ cb.append(b[0]) ++ # Tests BufferSlice and BufferAssSlice ++ cb.append('abc') # Will be overwritten ++ cb[-1:] = b[:-2] ++ # Test BufferLength and BufferAssSlice ++ cb.append('def') # Will not be overwritten ++ cb[len(cb):] = b[:] ++ # Test BufferAssItem and BufferMark ++ cb.append('ghi') # Will be overwritten ++ cb[-1] = repr((len(cb) - cb.mark('a')[0], cb.mark('a')[1])) ++ # Test BufferRepr ++ cb.append(repr(cb) + repr(b)) ++ # Modify foreign buffer ++ b.append('foo') ++ b[0]='bar' ++ b[0:0]=['baz'] ++ vim.command('call append("$", getbufline(%i, 1, "$"))' % b.number) ++ # Test CheckBuffer ++ vim.command('bwipeout! ' + str(b.number)) ++ for expr in ('b[1]','b[:] = ["A", "B"]','b[:]','b.append("abc")'): ++ try: ++ exec(expr) ++ except vim.error: ++ pass ++ else: ++ # Usually a SEGV here ++ # Should not happen in any case ++ cb.append('No exception for ' + expr) ++ EOF + :endfun + :" + :call Test() +*** ../vim-7.3.942/src/testdir/test86.ok 2013-05-06 03:52:44.000000000 +0200 +--- src/testdir/test86.ok 2013-05-12 21:11:43.000000000 +0200 +*************** +*** 306,308 **** +--- 306,321 ---- + G: '.,,' + W: 1:',,' 2:'.,,' 3:'.,,' 4:'.,,' + B: 1:',,' 2:'.,,' 3:'.,,' 4:'.,,' ++ First line ++ First line ++ def ++ First line ++ Second line ++ Third line ++ (7, 2) ++ ++ baz ++ bar ++ Second line ++ Third line ++ foo +*** ../vim-7.3.942/src/testdir/test87.in 2013-05-06 03:52:44.000000000 +0200 +--- src/testdir/test87.in 2013-05-12 21:11:43.000000000 +0200 +*************** +*** 444,452 **** + : endtry + : endfor + : call RecVars(oname) +- endtry + :endfor + :only + :endfun + :" + :call Test() +--- 444,493 ---- + : endtry + : endfor + : call RecVars(oname) + :endfor + :only ++ :" ++ :" Test buffer object ++ :vnew ++ :put ='First line' ++ :put ='Second line' ++ :put ='Third line' ++ :1 delete _ ++ :py3 b=vim.current.buffer ++ :wincmd w ++ :mark a ++ py3 << EOF ++ cb = vim.current.buffer ++ # Tests BufferAppend and BufferItem ++ cb.append(b[0]) ++ # Tests BufferSlice and BufferAssSlice ++ cb.append('abc') # Will be overwritten ++ cb[-1:] = b[:-2] ++ # Test BufferLength and BufferAssSlice ++ cb.append('def') # Will not be overwritten ++ cb[len(cb):] = b[:] ++ # Test BufferAssItem and BufferMark ++ cb.append('ghi') # Will be overwritten ++ cb[-1] = repr((len(cb) - cb.mark('a')[0], cb.mark('a')[1])) ++ # Test BufferRepr ++ cb.append(repr(cb) + repr(b)) ++ # Modify foreign buffer ++ b.append('foo') ++ b[0]='bar' ++ b[0:0]=['baz'] ++ vim.command('call append("$", getbufline(%i, 1, "$"))' % b.number) ++ # Test CheckBuffer ++ vim.command('bwipeout! ' + str(b.number)) ++ for expr in ('b[1]','b[:] = ["A", "B"]','b[:]','b.append("abc")'): ++ try: ++ exec(expr) ++ except vim.error: ++ pass ++ else: ++ # Usually a SEGV here ++ # Should not happen in any case ++ cb.append('No exception for ' + expr) ++ EOF + :endfun + :" + :call Test() +*** ../vim-7.3.942/src/testdir/test87.ok 2013-05-06 03:52:44.000000000 +0200 +--- src/testdir/test87.ok 2013-05-12 21:11:43.000000000 +0200 +*************** +*** 295,297 **** +--- 295,310 ---- + G: '.,,' + W: 1:',,' 2:'.,,' 3:'.,,' 4:'.,,' + B: 1:',,' 2:'.,,' 3:'.,,' 4:'.,,' ++ First line ++ First line ++ def ++ First line ++ Second line ++ Third line ++ (7, 2) ++ ++ baz ++ bar ++ Second line ++ Third line ++ foo +*** ../vim-7.3.942/src/version.c 2013-05-12 20:36:09.000000000 +0200 +--- src/version.c 2013-05-12 21:11:53.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 943, + /**/ + +-- +Q: Is selling software the same as selling hardware? +A: No, good hardware is sold new, good software has already been used by many. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 47a0a0118e55caab02e312c34acc1107adafa59f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 14:12:47 +0200 Subject: [PATCH 0835/3340] - patchlevel 943 --- README.patches | 12 ++++++++++++ vim.spec | 29 ++++++++++++++++++++++++++++- 2 files changed, 40 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index 6b0cf9e4..e7e5ab78 100644 --- a/README.patches +++ b/README.patches @@ -963,3 +963,15 @@ Individual patches for Vim 7.3: 4270 7.3.929 (after 7.3.924) unused variable, not freeing unused string 1375 7.3.930 MSVC 2012 update is not recognized 1915 7.3.931 no completion for :xmap and :smap + 1388 7.3.932 compiler warning for uninitialized variable + 4739 7.3.933 Ruby on Mac crashes due to GC failure + 2023 7.3.934 E381 and E380 make the user think nothing happened + 3655 7.3.935 (after 7.3.933) Ruby init stack differs on 64 bit systems + 23271 7.3.936 (after 7.3.935) Ruby missing piece for static 64 bit linking + 16512 7.3.937 more can be shared between Python 2 and 3 + 4418 7.3.938 Python: not so easy to get the window number + 2053 7.3.939 Using Py_BuildValue is inefficient sometimes + 3030 7.3.940 Python: Can't get position of window + 32095 7.3.941 Python: Stuff in if_py_both.h is ordered badly + 5470 7.3.942 Python: SEGV in Buffer functions + 6867 7.3.943 Python: Negative indices were failing diff --git a/vim.spec b/vim.spec index 7483a2ab..de71c004 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 931 +%define patchlevel 943 Summary: The VIM editor URL: http://www.vim.org/ @@ -987,6 +987,18 @@ Patch928: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.928 Patch929: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.929 Patch930: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.930 Patch931: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.931 +Patch932: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.932 +Patch933: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.933 +Patch934: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.934 +Patch935: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.935 +Patch936: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.936 +Patch937: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.937 +Patch938: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.938 +Patch939: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.939 +Patch940: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.940 +Patch941: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.941 +Patch942: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.942 +Patch943: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.943 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -2064,6 +2076,18 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch929 -p0 %patch930 -p0 %patch931 -p0 +%patch932 -p0 +%patch933 -p0 +%patch934 -p0 +%patch935 -p0 +%patch936 -p0 +%patch937 -p0 +%patch938 -p0 +%patch939 -p0 +%patch940 -p0 +%patch941 -p0 +%patch942 -p0 +%patch943 -p0 # install spell files @@ -2540,6 +2564,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon May 13 2013 Karsten Hopp 7.3.943-1 +- patchlevel 943 + * Wed May 08 2013 Karsten Hopp 7.3.931-1 - patchlevel 931 From 87aef7f23cbb1a74880245b64946a60cd03d369b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 14:45:32 +0200 Subject: [PATCH 0836/3340] add BR perl(ExtUtils::ParseXS) --- vim.spec | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/vim.spec b/vim.spec index de71c004..ed1652df 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1%{?dist} +Release: 2%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -1015,7 +1015,7 @@ Patch3014: vim-7.3-rubyversion.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel ncurses-devel gettext perl-devel -BuildRequires: perl(ExtUtils::Embed) +BuildRequires: perl(ExtUtils::Embed) perl(ExtUtils::ParseXS) BuildRequires: libacl-devel gpm-devel autoconf %if %{WITH_SELINUX} BuildRequires: libselinux-devel @@ -2564,6 +2564,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Mon May 13 2013 Karsten Hopp 7.3.943-2 +- add BR perl(ExtUtils::ParseXS) + * Mon May 13 2013 Karsten Hopp 7.3.943-1 - patchlevel 943 From bc35d20a537839bb42e0c308e108f3828737cfe2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 15:45:45 +0200 Subject: [PATCH 0837/3340] fix path to xsubpp script --- vim-7.3-xsubpp-path.patch | 12 ++++++++++++ vim.spec | 3 +++ 2 files changed, 15 insertions(+) create mode 100644 vim-7.3-xsubpp-path.patch diff --git a/vim-7.3-xsubpp-path.patch b/vim-7.3-xsubpp-path.patch new file mode 100644 index 00000000..971b10a5 --- /dev/null +++ b/vim-7.3-xsubpp-path.patch @@ -0,0 +1,12 @@ +diff -up vim73/src/Makefile.xsubpp vim73/src/Makefile +--- vim73/src/Makefile.xsubpp 2013-05-13 15:02:15.894805644 +0200 ++++ vim73/src/Makefile 2013-05-13 15:07:03.922821257 +0200 +@@ -2416,7 +2416,7 @@ lintinstall: + + auto/if_perl.c: if_perl.xs + $(PERL) -e 'unless ( $$] >= 5.005 ) { for (qw(na defgv errgv)) { print "#define PL_$$_ $$_\n" }}' > $@ +- $(PERL) $(PERLLIB)/ExtUtils/xsubpp -prototypes -typemap \ ++ $(PERL) $(PERLLIB)/vendor_perl/ExtUtils/xsubpp -prototypes -typemap \ + $(PERLLIB)/ExtUtils/typemap if_perl.xs >> $@ + + auto/osdef.h: auto/config.h osdef.sh osdef1.h.in osdef2.h.in diff --git a/vim.spec b/vim.spec index ed1652df..9aecdd96 100644 --- a/vim.spec +++ b/vim.spec @@ -1012,6 +1012,7 @@ Patch3011: vim72-rh514717.patch Patch3012: vim-7.3-bug816848.patch Patch3013: vim-7.3-manpage-typo-668894-675480.patch Patch3014: vim-7.3-rubyversion.patch +Patch3015: vim-7.3-xsubpp-path.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel ncurses-devel gettext perl-devel @@ -2107,6 +2108,7 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch3012 -p1 %patch3013 -p1 %patch3014 -p1 +%patch3015 -p1 %build cp -f %{SOURCE5} . @@ -2566,6 +2568,7 @@ rm -rf $RPM_BUILD_ROOT %changelog * Mon May 13 2013 Karsten Hopp 7.3.943-2 - add BR perl(ExtUtils::ParseXS) +- fix path to xsubpp script * Mon May 13 2013 Karsten Hopp 7.3.943-1 - patchlevel 943 From 270d9c19a6e37b4bb5af0f50ab67947e79a8d96d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Mon, 13 May 2013 15:47:17 +0200 Subject: [PATCH 0838/3340] fix path to xsubpp script --- vim-7.3-xsubpp-path.patch | 12 ++++++++++++ vim.spec | 3 +++ 2 files changed, 15 insertions(+) create mode 100644 vim-7.3-xsubpp-path.patch diff --git a/vim-7.3-xsubpp-path.patch b/vim-7.3-xsubpp-path.patch new file mode 100644 index 00000000..971b10a5 --- /dev/null +++ b/vim-7.3-xsubpp-path.patch @@ -0,0 +1,12 @@ +diff -up vim73/src/Makefile.xsubpp vim73/src/Makefile +--- vim73/src/Makefile.xsubpp 2013-05-13 15:02:15.894805644 +0200 ++++ vim73/src/Makefile 2013-05-13 15:07:03.922821257 +0200 +@@ -2416,7 +2416,7 @@ lintinstall: + + auto/if_perl.c: if_perl.xs + $(PERL) -e 'unless ( $$] >= 5.005 ) { for (qw(na defgv errgv)) { print "#define PL_$$_ $$_\n" }}' > $@ +- $(PERL) $(PERLLIB)/ExtUtils/xsubpp -prototypes -typemap \ ++ $(PERL) $(PERLLIB)/vendor_perl/ExtUtils/xsubpp -prototypes -typemap \ + $(PERLLIB)/ExtUtils/typemap if_perl.xs >> $@ + + auto/osdef.h: auto/config.h osdef.sh osdef1.h.in osdef2.h.in diff --git a/vim.spec b/vim.spec index ed1652df..9aecdd96 100644 --- a/vim.spec +++ b/vim.spec @@ -1012,6 +1012,7 @@ Patch3011: vim72-rh514717.patch Patch3012: vim-7.3-bug816848.patch Patch3013: vim-7.3-manpage-typo-668894-675480.patch Patch3014: vim-7.3-rubyversion.patch +Patch3015: vim-7.3-xsubpp-path.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel ncurses-devel gettext perl-devel @@ -2107,6 +2108,7 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch3012 -p1 %patch3013 -p1 %patch3014 -p1 +%patch3015 -p1 %build cp -f %{SOURCE5} . @@ -2566,6 +2568,7 @@ rm -rf $RPM_BUILD_ROOT %changelog * Mon May 13 2013 Karsten Hopp 7.3.943-2 - add BR perl(ExtUtils::ParseXS) +- fix path to xsubpp script * Mon May 13 2013 Karsten Hopp 7.3.943-1 - patchlevel 943 From 726954caa162dafd034c29f1501e37d51902acd6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 14 May 2013 14:59:15 +0200 Subject: [PATCH 0839/3340] - patchlevel 944 --- 7.3.944 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.944 diff --git a/7.3.944 b/7.3.944 new file mode 100644 index 00000000..f5bbc972 --- /dev/null +++ b/7.3.944 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.944 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.944 +Problem: External program receives the termrespone. +Solution: Insert a delay and discard input. (Hayaki Saito) +Files: src/term.c + + +*** ../vim-7.3.943/src/term.c 2013-04-06 14:30:35.000000000 +0200 +--- src/term.c 2013-05-13 20:24:14.000000000 +0200 +*************** +*** 3253,3261 **** + if (!gui.in_use && !gui.starting) + # endif + { +! /* May need to check for T_CRV response. */ + if (crv_status == CRV_SENT || u7_status == U7_SENT) +! (void)vpeekc_nomap(); + /* Check for termcodes first, otherwise an external program may + * get them. */ + check_for_codes_from_term(); +--- 3253,3271 ---- + if (!gui.in_use && !gui.starting) + # endif + { +! /* May need to discard T_CRV or T_U7 response. */ + if (crv_status == CRV_SENT || u7_status == U7_SENT) +! { +! # ifdef UNIX +! /* Give the terminal a chance to respond. */ +! mch_delay(100L, FALSE); +! # endif +! # ifdef TCIFLUSH +! /* Discard data received but not read. */ +! if (exiting) +! tcflush(fileno(stdin), TCIFLUSH); +! # endif +! } + /* Check for termcodes first, otherwise an external program may + * get them. */ + check_for_codes_from_term(); +*** ../vim-7.3.943/src/version.c 2013-05-12 21:16:17.000000000 +0200 +--- src/version.c 2013-05-13 20:24:29.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 944, + /**/ + +-- +DENNIS: Listen -- strange women lying in ponds distributing swords is no + basis for a system of government. Supreme executive power derives + from a mandate from the masses, not from some farcical aquatic + ceremony. + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0a58aceceb59f05d8d11071bf2c436026b2a6fd1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 14 May 2013 14:59:16 +0200 Subject: [PATCH 0840/3340] - patchlevel 944 --- README.patches | 1 + vim.spec | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/README.patches b/README.patches index e7e5ab78..ad55b60a 100644 --- a/README.patches +++ b/README.patches @@ -975,3 +975,4 @@ Individual patches for Vim 7.3: 32095 7.3.941 Python: Stuff in if_py_both.h is ordered badly 5470 7.3.942 Python: SEGV in Buffer functions 6867 7.3.943 Python: Negative indices were failing + 2283 7.3.944 external program receives the termrespone diff --git a/vim.spec b/vim.spec index 9aecdd96..8ce1ab58 100644 --- a/vim.spec +++ b/vim.spec @@ -18,13 +18,13 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 943 +%define patchlevel 944 Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 2%{?dist} +Release: 1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -999,6 +999,7 @@ Patch940: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.940 Patch941: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.941 Patch942: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.942 Patch943: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.943 +Patch944: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.944 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -2089,6 +2090,7 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch941 -p0 %patch942 -p0 %patch943 -p0 +%patch944 -p0 # install spell files @@ -2566,6 +2568,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/icons/hicolor/*/apps/* %changelog +* Tue May 14 2013 Karsten Hopp 7.3.944-1 +- patchlevel 944 + * Mon May 13 2013 Karsten Hopp 7.3.943-2 - add BR perl(ExtUtils::ParseXS) - fix path to xsubpp script From b3a77559032cc8328aa0a48d8486d081d5bac2ef Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 14 May 2013 15:09:45 +0200 Subject: [PATCH 0841/3340] fix path to xsubpp script --- vim-7.3-xsubpp-path.patch | 12 ------------ vim.spec | 5 +---- 2 files changed, 1 insertion(+), 16 deletions(-) delete mode 100644 vim-7.3-xsubpp-path.patch diff --git a/vim-7.3-xsubpp-path.patch b/vim-7.3-xsubpp-path.patch deleted file mode 100644 index 971b10a5..00000000 --- a/vim-7.3-xsubpp-path.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -up vim73/src/Makefile.xsubpp vim73/src/Makefile ---- vim73/src/Makefile.xsubpp 2013-05-13 15:02:15.894805644 +0200 -+++ vim73/src/Makefile 2013-05-13 15:07:03.922821257 +0200 -@@ -2416,7 +2416,7 @@ lintinstall: - - auto/if_perl.c: if_perl.xs - $(PERL) -e 'unless ( $$] >= 5.005 ) { for (qw(na defgv errgv)) { print "#define PL_$$_ $$_\n" }}' > $@ -- $(PERL) $(PERLLIB)/ExtUtils/xsubpp -prototypes -typemap \ -+ $(PERL) $(PERLLIB)/vendor_perl/ExtUtils/xsubpp -prototypes -typemap \ - $(PERLLIB)/ExtUtils/typemap if_perl.xs >> $@ - - auto/osdef.h: auto/config.h osdef.sh osdef1.h.in osdef2.h.in diff --git a/vim.spec b/vim.spec index e4bffe28..1aff1e72 100644 --- a/vim.spec +++ b/vim.spec @@ -1013,7 +1013,6 @@ Patch3011: vim72-rh514717.patch Patch3012: vim-7.3-bug816848.patch Patch3013: vim-7.3-manpage-typo-668894-675480.patch Patch3014: vim-7.3-rubyversion.patch -Patch3015: vim-7.3-xsubpp-path.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel ncurses-devel gettext perl-devel @@ -2110,7 +2109,6 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch3012 -p1 %patch3013 -p1 %patch3014 -p1 -%patch3015 -p1 %build cp -f %{SOURCE5} . @@ -2576,7 +2574,6 @@ rm -rf $RPM_BUILD_ROOT * Mon May 13 2013 Karsten Hopp 7.3.943-2 - add BR perl(ExtUtils::ParseXS) -- fix path to xsubpp script * Mon May 13 2013 Karsten Hopp 7.3.943-1 - patchlevel 943 @@ -2608,7 +2605,7 @@ rm -rf $RPM_BUILD_ROOT * Tue Nov 20 2012 Karsten Hopp 7.3.715-1 - patchlevel 715 -* + * Mon Nov 12 2012 Karsten Hopp 7.3.712-1 - patchlevel 712 From 6ffa9a239fc5c8622a29e48747b21d0342da5b8e Mon Sep 17 00:00:00 2001 From: Daniel Mach Date: Tue, 14 May 2013 14:06:28 -0400 Subject: [PATCH 0842/3340] Reset content to fedora/f19 --- vim-7.3-xsubpp-path.patch | 12 ------------ vim.spec | 10 +++++----- 2 files changed, 5 insertions(+), 17 deletions(-) delete mode 100644 vim-7.3-xsubpp-path.patch diff --git a/vim-7.3-xsubpp-path.patch b/vim-7.3-xsubpp-path.patch deleted file mode 100644 index 971b10a5..00000000 --- a/vim-7.3-xsubpp-path.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -up vim73/src/Makefile.xsubpp vim73/src/Makefile ---- vim73/src/Makefile.xsubpp 2013-05-13 15:02:15.894805644 +0200 -+++ vim73/src/Makefile 2013-05-13 15:07:03.922821257 +0200 -@@ -2416,7 +2416,7 @@ lintinstall: - - auto/if_perl.c: if_perl.xs - $(PERL) -e 'unless ( $$] >= 5.005 ) { for (qw(na defgv errgv)) { print "#define PL_$$_ $$_\n" }}' > $@ -- $(PERL) $(PERLLIB)/ExtUtils/xsubpp -prototypes -typemap \ -+ $(PERL) $(PERLLIB)/vendor_perl/ExtUtils/xsubpp -prototypes -typemap \ - $(PERLLIB)/ExtUtils/typemap if_perl.xs >> $@ - - auto/osdef.h: auto/config.h osdef.sh osdef1.h.in osdef2.h.in diff --git a/vim.spec b/vim.spec index d91f31d4..1aff1e72 100644 --- a/vim.spec +++ b/vim.spec @@ -1013,7 +1013,6 @@ Patch3011: vim72-rh514717.patch Patch3012: vim-7.3-bug816848.patch Patch3013: vim-7.3-manpage-typo-668894-675480.patch Patch3014: vim-7.3-rubyversion.patch -Patch3015: vim-7.3-xsubpp-path.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel ncurses-devel gettext perl-devel @@ -2110,7 +2109,6 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch3012 -p1 %patch3013 -p1 %patch3014 -p1 -%patch3015 -p1 %build cp -f %{SOURCE5} . @@ -2306,8 +2304,11 @@ if [ -n "\$BASH_VERSION" -o -n "\$KSH_VERSION" -o -n "\$ZSH_VERSION" ]; then fi EOF cat >$RPM_BUILD_ROOT/%{_sysconfdir}/profile.d/vim.csh < 100 ) then + alias vi vim + endif +endif EOF chmod 0644 $RPM_BUILD_ROOT/%{_sysconfdir}/profile.d/* install -p -m644 %{SOURCE4} $RPM_BUILD_ROOT/%{_sysconfdir}/vimrc @@ -2573,7 +2574,6 @@ rm -rf $RPM_BUILD_ROOT * Mon May 13 2013 Karsten Hopp 7.3.943-2 - add BR perl(ExtUtils::ParseXS) -- fix path to xsubpp script * Mon May 13 2013 Karsten Hopp 7.3.943-1 - patchlevel 943 From 6833e0dc5d72914ea467701a58fb539f174483f6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:30:10 +0200 Subject: [PATCH 0843/3340] consistent use of macros in spec file add some links to man pages --- vim.spec | 129 +++++++++++++++++++++++++++++++------------------------ 1 file changed, 74 insertions(+), 55 deletions(-) diff --git a/vim.spec b/vim.spec index 1aff1e72..92cb81dc 100644 --- a/vim.spec +++ b/vim.spec @@ -24,7 +24,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 1%{?dist} +Release: 2%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -2119,8 +2119,8 @@ autoconf sed -e "s+VIMRCLOC = \$(VIMLOC)+VIMRCLOC = /etc+" Makefile > Makefile.tmp mv -f Makefile.tmp Makefile -export CFLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2" -export CXXFLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2" +export CFLAGS="%{optflags} -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2" +export CXXFLAGS="%{optflags} -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2" %configure --with-features=huge \ --enable-pythoninterp=dynamic \ @@ -2198,15 +2198,15 @@ perl -pi -e "s/\/etc\/vimrc/\/etc\/virc/" os_unix.h make VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} %{?_smp_mflags} %install -rm -rf $RPM_BUILD_ROOT -mkdir -p $RPM_BUILD_ROOT/%{_bindir} -mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/{after,autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} -mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/after/{autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} +rm -rf %{buildroot} +mkdir -p %{buildroot}/%{_bindir} +mkdir -p %{buildroot}/%{_datadir}/%{name}/vimfiles/{after,autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} +mkdir -p %{buildroot}/%{_datadir}/%{name}/vimfiles/after/{autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} cp -f %{SOURCE11} . %if %{?fedora}%{!?fedora:0} >= 16 || %{?rhel}%{!?rhel:0} >= 6 -cp -f %{SOURCE15} $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/template.spec +cp -f %{SOURCE15} %{buildroot}/%{_datadir}/%{name}/vimfiles/template.spec %else -cp -f %{SOURCE14} $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/template.spec +cp -f %{SOURCE14} %{buildroot}/%{_datadir}/%{name}/vimfiles/template.spec %endif cp runtime/doc/uganda.txt LICENSE # Those aren't Linux info files but some binary files for Amiga: @@ -2214,29 +2214,29 @@ rm -f README*.info cd src -make install DESTDIR=$RPM_BUILD_ROOT BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} -make installgtutorbin DESTDIR=$RPM_BUILD_ROOT BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} -mkdir -p $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/{16x16,32x32,48x48,64x64}/apps -install -m755 vim $RPM_BUILD_ROOT%{_bindir}/vi -install -m755 enhanced-vim $RPM_BUILD_ROOT%{_bindir}/vim -install -m755 gvim $RPM_BUILD_ROOT%{_bindir}/gvim +make install DESTDIR=%{buildroot} BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} +make installgtutorbin DESTDIR=%{buildroot} BINDIR=%{_bindir} VIMRCLOC=/etc VIMRUNTIMEDIR=/usr/share/vim/%{vimdir} +mkdir -p %{buildroot}%{_datadir}/icons/hicolor/{16x16,32x32,48x48,64x64}/apps +install -m755 vim %{buildroot}%{_bindir}/vi +install -m755 enhanced-vim %{buildroot}%{_bindir}/vim +install -m755 gvim %{buildroot}%{_bindir}/gvim install -p -m644 %{SOURCE7} \ - $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/16x16/apps/gvim.png + %{buildroot}%{_datadir}/icons/hicolor/16x16/apps/gvim.png install -p -m644 %{SOURCE8} \ - $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/32x32/apps/gvim.png + %{buildroot}%{_datadir}/icons/hicolor/32x32/apps/gvim.png install -p -m644 %{SOURCE9} \ - $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/48x48/apps/gvim.png + %{buildroot}%{_datadir}/icons/hicolor/48x48/apps/gvim.png install -p -m644 %{SOURCE10} \ - $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/64x64/apps/gvim.png + %{buildroot}%{_datadir}/icons/hicolor/64x64/apps/gvim.png -( cd $RPM_BUILD_ROOT +( cd %{buildroot} ln -sf vi ./%{_bindir}/rvi ln -sf vi ./%{_bindir}/rview ln -sf vi ./%{_bindir}/view ln -sf vi ./%{_bindir}/ex ln -sf vim ./%{_bindir}/rvim ln -sf vim ./%{_bindir}/vimdiff - perl -pi -e "s,$RPM_BUILD_ROOT,," .%{_mandir}/man1/vim.1 .%{_mandir}/man1/vimtutor.1 + perl -pi -e "s,%{buildroot},," .%{_mandir}/man1/vim.1 .%{_mandir}/man1/vimtutor.1 rm -f .%{_mandir}/man1/rvim.1 ln -sf vim.1.gz .%{_mandir}/man1/vi.1.gz ln -sf vim.1.gz .%{_mandir}/man1/rvi.1.gz @@ -2247,12 +2247,12 @@ install -p -m644 %{SOURCE10} \ ln -sf gvim ./%{_bindir}/gvimdiff ln -sf gvim ./%{_bindir}/vimx %if "%{desktop_file}" == "1" - mkdir -p $RPM_BUILD_ROOT/%{_datadir}/applications + mkdir -p %{buildroot}/%{_datadir}/applications desktop-file-install \ %if 0%{?fedora} && 0%{?fedora} < 19 --vendor fedora \ %endif - --dir $RPM_BUILD_ROOT/%{_datadir}/applications \ + --dir %{buildroot}/%{_datadir}/applications \ %{SOURCE3} # --add-category "Development;TextEditor;X-Red-Hat-Base" D\ %else @@ -2264,7 +2264,7 @@ install -p -m644 %{SOURCE10} \ ln -sf menu_ja_jp.ujis.vim menu_ja_jp.eucjp.vim ) ) -pushd $RPM_BUILD_ROOT/%{_datadir}/%{name}/%{vimdir}/tutor +pushd %{buildroot}/%{_datadir}/%{name}/%{vimdir}/tutor mkdir conv iconv -f CP1252 -t UTF8 tutor.ca > conv/tutor.ca iconv -f CP1252 -t UTF8 tutor.it > conv/tutor.it @@ -2289,13 +2289,13 @@ rmdir conv popd # Dependency cleanups -chmod 644 $RPM_BUILD_ROOT/%{_datadir}/%{name}/%{vimdir}/doc/vim2html.pl \ - $RPM_BUILD_ROOT/%{_datadir}/%{name}/%{vimdir}/tools/*.pl \ - $RPM_BUILD_ROOT/%{_datadir}/%{name}/%{vimdir}/tools/vim132 +chmod 644 %{buildroot}/%{_datadir}/%{name}/%{vimdir}/doc/vim2html.pl \ + %{buildroot}/%{_datadir}/%{name}/%{vimdir}/tools/*.pl \ + %{buildroot}/%{_datadir}/%{name}/%{vimdir}/tools/vim132 chmod 644 ../runtime/doc/vim2html.pl -mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/profile.d -cat >$RPM_BUILD_ROOT/%{_sysconfdir}/profile.d/vim.sh <%{buildroot}/%{_sysconfdir}/profile.d/vim.sh </dev/null 2>&1 || alias vi=vim fi EOF -cat >$RPM_BUILD_ROOT/%{_sysconfdir}/profile.d/vim.csh <%{buildroot}/%{_sysconfdir}/profile.d/vim.csh < 100 ) then alias vi vim endif endif EOF -chmod 0644 $RPM_BUILD_ROOT/%{_sysconfdir}/profile.d/* -install -p -m644 %{SOURCE4} $RPM_BUILD_ROOT/%{_sysconfdir}/vimrc -install -p -m644 %{SOURCE4} $RPM_BUILD_ROOT/%{_sysconfdir}/virc -(cd $RPM_BUILD_ROOT/%{_datadir}/%{name}/%{vimdir}/doc; +chmod 0644 %{buildroot}/%{_sysconfdir}/profile.d/* +install -p -m644 %{SOURCE4} %{buildroot}/%{_sysconfdir}/vimrc +install -p -m644 %{SOURCE4} %{buildroot}/%{_sysconfdir}/virc +(cd %{buildroot}/%{_datadir}/%{name}/%{vimdir}/doc; gzip -9 *.txt gzip -d help.txt.gz version7.txt.gz sponsor.txt.gz cp %{SOURCE12} . @@ -2328,35 +2328,39 @@ EOF LANG=C sort tags > tags.tmp; mv tags.tmp tags ) (cd ../runtime; rm -rf doc; ln -svf ../../vim/%{vimdir}/doc docs;) -rm -f $RPM_BUILD_ROOT/%{_datadir}/vim/%{vimdir}/macros/maze/maze*.c -rm -rf $RPM_BUILD_ROOT/%{_datadir}/vim/%{vimdir}/tools -rm -rf $RPM_BUILD_ROOT/%{_datadir}/vim/%{vimdir}/doc/vim2html.pl -rm -f $RPM_BUILD_ROOT/%{_datadir}/vim/%{vimdir}/tutor/tutor.gr.utf-8~ -( cd $RPM_BUILD_ROOT/%{_mandir} +rm -f %{buildroot}/%{_datadir}/vim/%{vimdir}/macros/maze/maze*.c +rm -rf %{buildroot}/%{_datadir}/vim/%{vimdir}/tools +rm -rf %{buildroot}/%{_datadir}/vim/%{vimdir}/doc/vim2html.pl +rm -f %{buildroot}/%{_datadir}/vim/%{vimdir}/tutor/tutor.gr.utf-8~ +( cd %{buildroot}/%{_mandir} for i in `find ??/ -type f`; do bi=`basename $i` - iconv -f latin1 -t UTF8 $i > $RPM_BUILD_ROOT/$bi - mv -f $RPM_BUILD_ROOT/$bi $i + iconv -f latin1 -t UTF8 $i > %{buildroot}/$bi + mv -f %{buildroot}/$bi $i done ) # Remove not UTF-8 manpages for i in pl.ISO8859-2 it.ISO8859-1 ru.KOI8-R fr.ISO8859-1; do - rm -rf $RPM_BUILD_ROOT/%{_mandir}/$i + rm -rf %{buildroot}/%{_mandir}/$i done # use common man1/ru directory -mv $RPM_BUILD_ROOT/%{_mandir}/ru.UTF-8 $RPM_BUILD_ROOT/%{_mandir}/ru +mv %{buildroot}/%{_mandir}/ru.UTF-8 %{buildroot}/%{_mandir}/ru # Remove duplicate man pages for i in fr.UTF-8 it.UTF-8 pl.UTF-8; do - rm -rf $RPM_BUILD_ROOT/%{_mandir}/$i + rm -rf %{buildroot}/%{_mandir}/$i done -for i in rvim.1 gvim.1 gvimdiff.1; do - echo ".so man1/vim.1" > $RPM_BUILD_ROOT/%{_mandir}/man1/$i +for i in rvim.1 gvim.1 gvimdiff.1 gex.1 gview.1 gvimtutor.1 vimx.1; do + echo ".so man1/vim.1" > %{buildroot}/%{_mandir}/man1/$i done -touch $RPM_BUILD_ROOT/%{_datadir}/%{name}/vimfiles/doc/tags +mkdir -p %{buildroot}/%{_mandir}/man5 +for i in virc.5 vimrc.5; do + echo ".so man1/vim.1" > %{buildroot}/%{_mandir}/man5/$i +done +touch %{buildroot}/%{_datadir}/%{name}/vimfiles/doc/tags %post X11 touch --no-create %{_datadir}/icons/hicolor @@ -2373,7 +2377,7 @@ fi update-desktop-database &> /dev/null ||: %clean -rm -rf $RPM_BUILD_ROOT +rm -rf %{buildroot} %files common %defattr(-,root,root) @@ -2440,13 +2444,21 @@ rm -rf $RPM_BUILD_ROOT %lang(zh_CN.UTF-8) %{_datadir}/%{name}/%{vimdir}/lang/zh_CN.UTF-8 %lang(zh_TW.UTF-8) %{_datadir}/%{name}/%{vimdir}/lang/zh_TW.UTF-8 /%{_bindir}/xxd -%{_mandir}/man1/vim.* %{_mandir}/man1/ex.* -%{_mandir}/man1/vi.* -%{_mandir}/man1/view.* +%{_mandir}/man1/gex.* +%{_mandir}/man1/gview.* +%{_mandir}/man1/gvim* %{_mandir}/man1/rvi.* %{_mandir}/man1/rview.* +%{_mandir}/man1/rvim.* +%{_mandir}/man1/vi.* +%{_mandir}/man1/view.* +%{_mandir}/man1/vim.* +%{_mandir}/man1/vimdiff.* +%{_mandir}/man1/vimtutor.* +%{_mandir}/man1/vimx.* %{_mandir}/man1/xxd.* +%{_mandir}/man5/vimrc.* %lang(fr) %{_mandir}/fr/man1/* %lang(it) %{_mandir}/it/man1/* %lang(pl) %{_mandir}/pl/man1/* @@ -2517,6 +2529,13 @@ rm -rf $RPM_BUILD_ROOT %{_bindir}/view %{_bindir}/rvi %{_bindir}/rview +%{_mandir}/man1/vim.* +%{_mandir}/man1/vi.* +%{_mandir}/man1/ex.* +%{_mandir}/man1/rvi.* +%{_mandir}/man1/rview.* +%{_mandir}/man1/view.* +%{_mandir}/man5/virc.* %files enhanced %defattr(-,root,root) @@ -2525,9 +2544,6 @@ rm -rf $RPM_BUILD_ROOT %{_bindir}/vimdiff %{_bindir}/vimtutor %config(noreplace) %{_sysconfdir}/profile.d/vim.* -%{_mandir}/man1/rvim.* -%{_mandir}/man1/vimdiff.* -%{_mandir}/man1/vimtutor.* %files filesystem %defattr(-,root,root) @@ -2565,10 +2581,13 @@ rm -rf $RPM_BUILD_ROOT %{_bindir}/vimx %{_bindir}/evim %{_mandir}/man1/evim.* -%{_mandir}/man1/gvim* %{_datadir}/icons/hicolor/*/apps/* %changelog +* Tue May 21 2013 Karsten Hopp 7.3.944-2 +- consistent use of macros in spec file +- add some links to man pages + * Tue May 14 2013 Karsten Hopp 7.3.944-1 - patchlevel 944 From 15bee7a7d67c54f04b01b4aa599390f8e7274e8e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:25 +0200 Subject: [PATCH 0844/3340] - patchlevel 945 --- 7.3.945 | 648 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 648 insertions(+) create mode 100644 7.3.945 diff --git a/7.3.945 b/7.3.945 new file mode 100644 index 00000000..f3bfb2f0 --- /dev/null +++ b/7.3.945 @@ -0,0 +1,648 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.945 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.945 +Problem: Python: List of buffers is not very useful. +Solution: Make vim.buffers a map. No iterator yet. (ZyX) +Files: runtime/doc/if_pyth.txt, src/if_py_both.h, src/if_python3.c, + src/if_python.c, src/testdir/test86.ok, src/testdir/test87.ok + + +*** ../vim-7.3.944/runtime/doc/if_pyth.txt 2013-05-12 19:30:27.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-05-15 13:34:06.000000000 +0200 +*************** +*** 209,220 **** + to which the variables referred. + + vim.buffers *python-buffers* +! A sequence object providing access to the list of vim buffers. The + object supports the following operations: > + :py b = vim.buffers[i] # Indexing (read-only) + :py b in vim.buffers # Membership test + :py n = len(vim.buffers) # Number of elements +- :py for b in vim.buffers: # Sequential access + < + vim.windows *python-windows* + A sequence object providing access to the list of vim windows. The +--- 209,219 ---- + to which the variables referred. + + vim.buffers *python-buffers* +! A mapping object providing access to the list of vim buffers. The + object supports the following operations: > + :py b = vim.buffers[i] # Indexing (read-only) + :py b in vim.buffers # Membership test + :py n = len(vim.buffers) # Number of elements + < + vim.windows *python-windows* + A sequence object providing access to the list of vim windows. The +*** ../vim-7.3.944/src/if_py_both.h 2013-05-12 21:16:17.000000000 +0200 +--- src/if_py_both.h 2013-05-15 13:34:06.000000000 +0200 +*************** +*** 534,549 **** + * Buffer list object - Implementation + */ + +! static PyTypeObject BufListType; +! static PySequenceMethods BufListAsSeq; + + typedef struct + { + PyObject_HEAD +! } BufListObject; + + static PyInt +! BufListLength(PyObject *self UNUSED) + { + buf_T *b = firstbuf; + PyInt n = 0; +--- 534,548 ---- + * Buffer list object - Implementation + */ + +! static PyTypeObject BufMapType; + + typedef struct + { + PyObject_HEAD +! } BufMapObject; + + static PyInt +! BufMapLength(PyObject *self UNUSED) + { + buf_T *b = firstbuf; + PyInt n = 0; +*************** +*** 558,577 **** + } + + static PyObject * +! BufListItem(PyObject *self UNUSED, PyInt n) + { +! buf_T *b; + +! for (b = firstbuf; b; b = b->b_next, --n) + { +! if (n == 0) +! return BufferNew(b); + } + +! PyErr_SetString(PyExc_IndexError, _("no such buffer")); +! return NULL; + } + + typedef struct pylinkedlist_S { + struct pylinkedlist_S *pll_next; + struct pylinkedlist_S *pll_prev; +--- 557,597 ---- + } + + static PyObject * +! BufMapItem(PyObject *self UNUSED, PyObject *keyObject) + { +! buf_T *b; +! int bnr; + +! #if PY_MAJOR_VERSION < 3 +! if (PyInt_Check(keyObject)) +! bnr = PyInt_AsLong(keyObject); +! else +! #endif +! if (PyLong_Check(keyObject)) +! bnr = PyLong_AsLong(keyObject); +! else + { +! PyErr_SetString(PyExc_ValueError, _("key must be integer")); +! return NULL; + } + +! b = buflist_findnr(bnr); +! +! if (b) +! return BufferNew(b); +! else +! { +! PyErr_SetString(PyExc_KeyError, _("no such buffer")); +! return NULL; +! } + } + ++ static PyMappingMethods BufMapAsMapping = { ++ (lenfunc) BufMapLength, ++ (binaryfunc) BufMapItem, ++ (objobjargproc) 0, ++ }; ++ + typedef struct pylinkedlist_S { + struct pylinkedlist_S *pll_next; + struct pylinkedlist_S *pll_prev; +*************** +*** 3401,3411 **** + WindowType.tp_setattr = WindowSetattr; + #endif + +! vim_memset(&BufListType, 0, sizeof(BufListType)); +! BufListType.tp_name = "vim.bufferlist"; +! BufListType.tp_basicsize = sizeof(BufListObject); +! BufListType.tp_as_sequence = &BufListAsSeq; +! BufListType.tp_flags = Py_TPFLAGS_DEFAULT; + BufferType.tp_doc = "vim buffer list"; + + vim_memset(&WinListType, 0, sizeof(WinListType)); +--- 3421,3431 ---- + WindowType.tp_setattr = WindowSetattr; + #endif + +! vim_memset(&BufMapType, 0, sizeof(BufMapType)); +! BufMapType.tp_name = "vim.bufferlist"; +! BufMapType.tp_basicsize = sizeof(BufMapObject); +! BufMapType.tp_as_mapping = &BufMapAsMapping; +! BufMapType.tp_flags = Py_TPFLAGS_DEFAULT; + BufferType.tp_doc = "vim buffer list"; + + vim_memset(&WinListType, 0, sizeof(WinListType)); +*** ../vim-7.3.944/src/if_python3.c 2013-05-12 21:16:17.000000000 +0200 +--- src/if_python3.c 2013-05-15 13:34:06.000000000 +0200 +*************** +*** 1272,1293 **** + } + } + +- /* Buffer list object - Definitions +- */ +- +- static PySequenceMethods BufListAsSeq = { +- (lenfunc) BufListLength, /* sq_length, len(x) */ +- (binaryfunc) 0, /* sq_concat, x+y */ +- (ssizeargfunc) 0, /* sq_repeat, x*n */ +- (ssizeargfunc) BufListItem, /* sq_item, x[i] */ +- 0, /* was_sq_slice, x[i:j] */ +- (ssizeobjargproc) 0, /* sq_as_item, x[i]=v */ +- 0, /* sq_ass_slice, x[i:j]=v */ +- 0, /* sq_contains */ +- 0, /* sq_inplace_concat */ +- 0, /* sq_inplace_repeat */ +- }; +- + /* Window object - Implementation + */ + +--- 1272,1277 ---- +*************** +*** 1512,1520 **** + } + #endif + +! static BufListObject TheBufferList = + { +! PyObject_HEAD_INIT(&BufListType) + }; + + static WinListObject TheWindowList = +--- 1496,1504 ---- + } + #endif + +! static BufMapObject TheBufferMap = + { +! PyObject_HEAD_INIT(&BufMapType) + }; + + static WinListObject TheWindowList = +*************** +*** 1538,1544 **** + PyType_Ready(&BufferType); + PyType_Ready(&RangeType); + PyType_Ready(&WindowType); +! PyType_Ready(&BufListType); + PyType_Ready(&WinListType); + PyType_Ready(&CurrentType); + PyType_Ready(&DictionaryType); +--- 1522,1528 ---- + PyType_Ready(&BufferType); + PyType_Ready(&RangeType); + PyType_Ready(&WindowType); +! PyType_Ready(&BufMapType); + PyType_Ready(&WinListType); + PyType_Ready(&CurrentType); + PyType_Ready(&DictionaryType); +*************** +*** 1557,1564 **** + Py_INCREF(VimError); + + PyModule_AddObject(mod, "error", VimError); +! Py_INCREF((PyObject *)(void *)&TheBufferList); +! PyModule_AddObject(mod, "buffers", (PyObject *)(void *)&TheBufferList); + Py_INCREF((PyObject *)(void *)&TheCurrent); + PyModule_AddObject(mod, "current", (PyObject *)(void *)&TheCurrent); + Py_INCREF((PyObject *)(void *)&TheWindowList); +--- 1541,1548 ---- + Py_INCREF(VimError); + + PyModule_AddObject(mod, "error", VimError); +! Py_INCREF((PyObject *)(void *)&TheBufferMap); +! PyModule_AddObject(mod, "buffers", (PyObject *)(void *)&TheBufferMap); + Py_INCREF((PyObject *)(void *)&TheCurrent); + PyModule_AddObject(mod, "current", (PyObject *)(void *)&TheCurrent); + Py_INCREF((PyObject *)(void *)&TheWindowList); +*** ../vim-7.3.944/src/if_python.c 2013-05-12 20:36:09.000000000 +0200 +--- src/if_python.c 2013-05-15 13:34:06.000000000 +0200 +*************** +*** 1131,1154 **** + &((RangeObject *)(self))->end); + } + +- /* Buffer list object - Definitions +- */ +- +- static PySequenceMethods BufListAsSeq = { +- (PyInquiry) BufListLength, /* sq_length, len(x) */ +- (binaryfunc) 0, /* sq_concat, x+y */ +- (PyIntArgFunc) 0, /* sq_repeat, x*n */ +- (PyIntArgFunc) BufListItem, /* sq_item, x[i] */ +- (PyIntIntArgFunc) 0, /* sq_slice, x[i:j] */ +- (PyIntObjArgProc) 0, /* sq_ass_item, x[i]=v */ +- (PyIntIntObjArgProc) 0, /* sq_ass_slice, x[i:j]=v */ +- (objobjproc) 0, +- #if PY_MAJOR_VERSION >= 2 +- (binaryfunc) 0, +- 0, +- #endif +- }; +- + /* Window object - Implementation + */ + +--- 1131,1136 ---- +*************** +*** 1212,1220 **** + } + #endif + +! static BufListObject TheBufferList = + { +! PyObject_HEAD_INIT(&BufListType) + }; + + static WinListObject TheWindowList = +--- 1194,1202 ---- + } + #endif + +! static BufMapObject TheBufferMap = + { +! PyObject_HEAD_INIT(&BufMapType) + }; + + static WinListObject TheWindowList = +*************** +*** 1240,1246 **** + PyType_Ready(&BufferType); + PyType_Ready(&RangeType); + PyType_Ready(&WindowType); +! PyType_Ready(&BufListType); + PyType_Ready(&WinListType); + PyType_Ready(&CurrentType); + PyType_Ready(&OptionsType); +--- 1222,1228 ---- + PyType_Ready(&BufferType); + PyType_Ready(&RangeType); + PyType_Ready(&WindowType); +! PyType_Ready(&BufMapType); + PyType_Ready(&WinListType); + PyType_Ready(&CurrentType); + PyType_Ready(&OptionsType); +*************** +*** 1254,1260 **** + VimError = Py_BuildValue("s", "vim.error"); + + PyDict_SetItemString(dict, "error", VimError); +! PyDict_SetItemString(dict, "buffers", (PyObject *)(void *)&TheBufferList); + PyDict_SetItemString(dict, "current", (PyObject *)(void *)&TheCurrent); + PyDict_SetItemString(dict, "windows", (PyObject *)(void *)&TheWindowList); + tmp = DictionaryNew(&globvardict); +--- 1236,1242 ---- + VimError = Py_BuildValue("s", "vim.error"); + + PyDict_SetItemString(dict, "error", VimError); +! PyDict_SetItemString(dict, "buffers", (PyObject *)(void *)&TheBufferMap); + PyDict_SetItemString(dict, "current", (PyObject *)(void *)&TheCurrent); + PyDict_SetItemString(dict, "windows", (PyObject *)(void *)&TheWindowList); + tmp = DictionaryNew(&globvardict); +*** ../vim-7.3.944/src/testdir/test86.ok 2013-05-12 21:16:17.000000000 +0200 +--- src/testdir/test86.ok 2013-05-15 13:34:06.000000000 +0200 +*************** +*** 226,238 **** + p/bopts1: False + inv: 2! ValueError + G: 0 +! W: 1:1 2:1 3:0 4:0 +! B: 1:1 2:1 3:0 4:0 + del wopts3! KeyError + del bopts3! ValueError + G: 0 +! W: 1:1 2:1 3:0 4:0 +! B: 1:1 2:1 3:0 4:0 + >>> iminsert + p/gopts1! KeyError + inv: 3! KeyError +--- 226,238 ---- + p/bopts1: False + inv: 2! ValueError + G: 0 +! W: 1:0 2:1 3:0 4:1 +! B: 1:0 2:1 3:0 4:1 + del wopts3! KeyError + del bopts3! ValueError + G: 0 +! W: 1:0 2:1 3:0 4:1 +! B: 1:0 2:1 3:0 4:1 + >>> iminsert + p/gopts1! KeyError + inv: 3! KeyError +*************** +*** 244,256 **** + wopts3! KeyError + p/bopts1: 2 + G: 1 +! W: 1:2 2:1 3:0 4:2 +! B: 1:2 2:1 3:0 4:2 + del wopts3! KeyError + del bopts3! ValueError + G: 1 +! W: 1:2 2:1 3:0 4:2 +! B: 1:2 2:1 3:0 4:2 + >>> omnifunc + p/gopts1! KeyError + inv: 1! KeyError +--- 244,256 ---- + wopts3! KeyError + p/bopts1: 2 + G: 1 +! W: 1:0 2:2 3:2 4:1 +! B: 1:0 2:2 3:2 4:1 + del wopts3! KeyError + del bopts3! ValueError + G: 1 +! W: 1:0 2:2 3:2 4:1 +! B: 1:0 2:2 3:2 4:1 + >>> omnifunc + p/gopts1! KeyError + inv: 1! KeyError +*************** +*** 263,275 **** + p/bopts1: '' + inv: 1! ValueError + G: '' +! W: 1:'B' 2:'C' 3:'A' 4:'' +! B: 1:'B' 2:'C' 3:'A' 4:'' + del wopts3! KeyError + del bopts3! ValueError + G: '' +! W: 1:'B' 2:'C' 3:'A' 4:'' +! B: 1:'B' 2:'C' 3:'A' 4:'' + >>> preserveindent + p/gopts1! KeyError + inv: 2! KeyError +--- 263,275 ---- + p/bopts1: '' + inv: 1! ValueError + G: '' +! W: 1:'A' 2:'B' 3:'' 4:'C' +! B: 1:'A' 2:'B' 3:'' 4:'C' + del wopts3! KeyError + del bopts3! ValueError + G: '' +! W: 1:'A' 2:'B' 3:'' 4:'C' +! B: 1:'A' 2:'B' 3:'' 4:'C' + >>> preserveindent + p/gopts1! KeyError + inv: 2! KeyError +*************** +*** 282,294 **** + p/bopts1: False + inv: 2! ValueError + G: 0 +! W: 1:1 2:1 3:0 4:0 +! B: 1:1 2:1 3:0 4:0 + del wopts3! KeyError + del bopts3! ValueError + G: 0 +! W: 1:1 2:1 3:0 4:0 +! B: 1:1 2:1 3:0 4:0 + >>> path + p/gopts1: '.,/usr/include,,' + inv: 0! ValueError +--- 282,294 ---- + p/bopts1: False + inv: 2! ValueError + G: 0 +! W: 1:0 2:1 3:0 4:1 +! B: 1:0 2:1 3:0 4:1 + del wopts3! KeyError + del bopts3! ValueError + G: 0 +! W: 1:0 2:1 3:0 4:1 +! B: 1:0 2:1 3:0 4:1 + >>> path + p/gopts1: '.,/usr/include,,' + inv: 0! ValueError +*************** +*** 300,311 **** + p/bopts1: None + inv: 0! ValueError + G: '.,,' +! W: 1:',,' 2:'.' 3:'.,,' 4:'.,,' +! B: 1:',,' 2:'.' 3:'.,,' 4:'.,,' + del wopts3! KeyError + G: '.,,' +! W: 1:',,' 2:'.,,' 3:'.,,' 4:'.,,' +! B: 1:',,' 2:'.,,' 3:'.,,' 4:'.,,' + First line + First line + def +--- 300,311 ---- + p/bopts1: None + inv: 0! ValueError + G: '.,,' +! W: 1:'.,,' 2:',,' 3:'.,,' 4:'.' +! B: 1:'.,,' 2:',,' 3:'.,,' 4:'.' + del wopts3! KeyError + G: '.,,' +! W: 1:'.,,' 2:',,' 3:'.,,' 4:'.,,' +! B: 1:'.,,' 2:',,' 3:'.,,' 4:'.,,' + First line + First line + def +*** ../vim-7.3.944/src/testdir/test87.ok 2013-05-12 21:16:17.000000000 +0200 +--- src/testdir/test87.ok 2013-05-15 13:34:06.000000000 +0200 +*************** +*** 215,227 **** + p/bopts1: False + inv: 2! ValueError + G: 0 +! W: 1:1 2:1 3:0 4:0 +! B: 1:1 2:1 3:0 4:0 + del wopts3! KeyError + del bopts3! ValueError + G: 0 +! W: 1:1 2:1 3:0 4:0 +! B: 1:1 2:1 3:0 4:0 + >>> iminsert + p/gopts1! KeyError + inv: 3! KeyError +--- 215,227 ---- + p/bopts1: False + inv: 2! ValueError + G: 0 +! W: 1:0 2:1 3:0 4:1 +! B: 1:0 2:1 3:0 4:1 + del wopts3! KeyError + del bopts3! ValueError + G: 0 +! W: 1:0 2:1 3:0 4:1 +! B: 1:0 2:1 3:0 4:1 + >>> iminsert + p/gopts1! KeyError + inv: 3! KeyError +*************** +*** 233,245 **** + wopts3! KeyError + p/bopts1: 2 + G: 1 +! W: 1:2 2:1 3:0 4:2 +! B: 1:2 2:1 3:0 4:2 + del wopts3! KeyError + del bopts3! ValueError + G: 1 +! W: 1:2 2:1 3:0 4:2 +! B: 1:2 2:1 3:0 4:2 + >>> omnifunc + p/gopts1! KeyError + inv: 1! KeyError +--- 233,245 ---- + wopts3! KeyError + p/bopts1: 2 + G: 1 +! W: 1:0 2:2 3:2 4:1 +! B: 1:0 2:2 3:2 4:1 + del wopts3! KeyError + del bopts3! ValueError + G: 1 +! W: 1:0 2:2 3:2 4:1 +! B: 1:0 2:2 3:2 4:1 + >>> omnifunc + p/gopts1! KeyError + inv: 1! KeyError +*************** +*** 252,264 **** + p/bopts1: b'' + inv: 1! ValueError + G: '' +! W: 1:'B' 2:'C' 3:'A' 4:'' +! B: 1:'B' 2:'C' 3:'A' 4:'' + del wopts3! KeyError + del bopts3! ValueError + G: '' +! W: 1:'B' 2:'C' 3:'A' 4:'' +! B: 1:'B' 2:'C' 3:'A' 4:'' + >>> preserveindent + p/gopts1! KeyError + inv: 2! KeyError +--- 252,264 ---- + p/bopts1: b'' + inv: 1! ValueError + G: '' +! W: 1:'A' 2:'B' 3:'' 4:'C' +! B: 1:'A' 2:'B' 3:'' 4:'C' + del wopts3! KeyError + del bopts3! ValueError + G: '' +! W: 1:'A' 2:'B' 3:'' 4:'C' +! B: 1:'A' 2:'B' 3:'' 4:'C' + >>> preserveindent + p/gopts1! KeyError + inv: 2! KeyError +*************** +*** 271,283 **** + p/bopts1: False + inv: 2! ValueError + G: 0 +! W: 1:1 2:1 3:0 4:0 +! B: 1:1 2:1 3:0 4:0 + del wopts3! KeyError + del bopts3! ValueError + G: 0 +! W: 1:1 2:1 3:0 4:0 +! B: 1:1 2:1 3:0 4:0 + >>> path + p/gopts1: b'.,/usr/include,,' + inv: 0! ValueError +--- 271,283 ---- + p/bopts1: False + inv: 2! ValueError + G: 0 +! W: 1:0 2:1 3:0 4:1 +! B: 1:0 2:1 3:0 4:1 + del wopts3! KeyError + del bopts3! ValueError + G: 0 +! W: 1:0 2:1 3:0 4:1 +! B: 1:0 2:1 3:0 4:1 + >>> path + p/gopts1: b'.,/usr/include,,' + inv: 0! ValueError +*************** +*** 289,300 **** + p/bopts1: None + inv: 0! ValueError + G: '.,,' +! W: 1:',,' 2:'.' 3:'.,,' 4:'.,,' +! B: 1:',,' 2:'.' 3:'.,,' 4:'.,,' + del wopts3! KeyError + G: '.,,' +! W: 1:',,' 2:'.,,' 3:'.,,' 4:'.,,' +! B: 1:',,' 2:'.,,' 3:'.,,' 4:'.,,' + First line + First line + def +--- 289,300 ---- + p/bopts1: None + inv: 0! ValueError + G: '.,,' +! W: 1:'.,,' 2:',,' 3:'.,,' 4:'.' +! B: 1:'.,,' 2:',,' 3:'.,,' 4:'.' + del wopts3! KeyError + G: '.,,' +! W: 1:'.,,' 2:',,' 3:'.,,' 4:'.,,' +! B: 1:'.,,' 2:',,' 3:'.,,' 4:'.,,' + First line + First line + def +*** ../vim-7.3.944/src/version.c 2013-05-13 20:26:47.000000000 +0200 +--- src/version.c 2013-05-15 13:37:08.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 945, + /**/ + +-- +ARTHUR: A scratch? Your arm's off! +BLACK KNIGHT: No, it isn't. +ARTHUR: Well, what's that then? +BLACK KNIGHT: I've had worse. + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 64226d6aae7f15170833f1385d9eb10cb0f4cf12 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:26 +0200 Subject: [PATCH 0845/3340] - patchlevel 946 --- 7.3.946 | 98 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 98 insertions(+) create mode 100644 7.3.946 diff --git a/7.3.946 b/7.3.946 new file mode 100644 index 00000000..4e42bebb --- /dev/null +++ b/7.3.946 @@ -0,0 +1,98 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.946 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.946 +Problem: Sometimes get stuck in waiting for cursor position report, + resulting in keys starting with [ not working. +Solution: Only wait for more characters after [ if followed by '?', '>' + or a digit. +Files: src/term.c + + +*** ../vim-7.3.945/src/term.c 2013-05-13 20:26:47.000000000 +0200 +--- src/term.c 2013-05-15 14:12:43.000000000 +0200 +*************** +*** 4126,4134 **** + * The final byte is 'R'. now it is only used for checking for + * ambiguous-width character state. + */ + if ((*T_CRV != NUL || *T_U7 != NUL) + && ((tp[0] == ESC && tp[1] == '[' && len >= 3) +! || (tp[0] == CSI && len >= 2))) + { + j = 0; + extra = 0; +--- 4126,4136 ---- + * The final byte is 'R'. now it is only used for checking for + * ambiguous-width character state. + */ ++ p = tp[0] == CSI ? tp + 1 : tp + 2; + if ((*T_CRV != NUL || *T_U7 != NUL) + && ((tp[0] == ESC && tp[1] == '[' && len >= 3) +! || (tp[0] == CSI && len >= 2)) +! && (VIM_ISDIGIT(*p) || *p == '>' || *p == '?')) + { + j = 0; + extra = 0; +*************** +*** 4136,4142 **** + && !(tp[i] >= '{' && tp[i] <= '~') + && !ASCII_ISALPHA(tp[i]); ++i) + if (tp[i] == ';' && ++j == 1) +! extra = atoi((char *)tp + i + 1); + if (i == len) + return -1; /* not enough characters */ + +--- 4138,4144 ---- + && !(tp[i] >= '{' && tp[i] <= '~') + && !ASCII_ISALPHA(tp[i]); ++i) + if (tp[i] == ';' && ++j == 1) +! extra = i + 1; + if (i == len) + return -1; /* not enough characters */ + +*************** +*** 4150,4155 **** +--- 4152,4159 ---- + # ifdef FEAT_AUTOCMD + did_cursorhold = TRUE; + # endif ++ if (extra > 0) ++ extra = atoi((char *)tp + extra); + if (extra == 2) + aw = "single"; + else if (extra == 3) +*************** +*** 4178,4183 **** +--- 4182,4189 ---- + /* rxvt sends its version number: "20703" is 2.7.3. + * Ignore it for when the user has set 'term' to xterm, + * even though it's an rxvt. */ ++ if (extra > 0) ++ extra = atoi((char *)tp + extra); + if (extra > 20000) + extra = 0; + +*** ../vim-7.3.945/src/version.c 2013-05-15 13:38:41.000000000 +0200 +--- src/version.c 2013-05-15 14:17:51.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 946, + /**/ + +-- +No letters of the alphabet were harmed in the creation of this message. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9f98904759b37b5d73c8090042a63da093e8d0d7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:27 +0200 Subject: [PATCH 0846/3340] - patchlevel 947 --- 7.3.947 | 703 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 703 insertions(+) create mode 100644 7.3.947 diff --git a/7.3.947 b/7.3.947 new file mode 100644 index 00000000..2093c9dc --- /dev/null +++ b/7.3.947 @@ -0,0 +1,703 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.947 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.947 +Problem: Python: No iterator for vim.list and vim.bufferlist. +Solution: Add the iterators. Also fix name of FunctionType. Add tests for + vim.buffers. (ZyX) +Files: runtime/doc/if_pyth.txt, src/eval.c, src/if_py_both.h, + src/if_python3.c, src/if_python.c, src/proto/eval.pro, + src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.946/runtime/doc/if_pyth.txt 2013-05-15 13:38:41.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-05-15 14:24:11.000000000 +0200 +*************** +*** 214,219 **** +--- 214,220 ---- + :py b = vim.buffers[i] # Indexing (read-only) + :py b in vim.buffers # Membership test + :py n = len(vim.buffers) # Number of elements ++ :py for b in vim.buffers: # Iterating over buffer list + < + vim.windows *python-windows* + A sequence object providing access to the list of vim windows. The +*** ../vim-7.3.946/src/eval.c 2013-05-06 04:50:26.000000000 +0200 +--- src/eval.c 2013-05-15 14:24:11.000000000 +0200 +*************** +*** 390,397 **** + static void clear_lval __ARGS((lval_T *lp)); + static void set_var_lval __ARGS((lval_T *lp, char_u *endp, typval_T *rettv, int copy, char_u *op)); + static int tv_op __ARGS((typval_T *tv1, typval_T *tv2, char_u *op)); +- static void list_add_watch __ARGS((list_T *l, listwatch_T *lw)); +- static void list_rem_watch __ARGS((list_T *l, listwatch_T *lwrem)); + static void list_fix_watch __ARGS((list_T *l, listitem_T *item)); + static void ex_unletlock __ARGS((exarg_T *eap, char_u *argstart, int deep)); + static int do_unlet_var __ARGS((lval_T *lp, char_u *name_end, int forceit)); +--- 390,395 ---- +*************** +*** 3106,3112 **** + /* + * Add a watcher to a list. + */ +! static void + list_add_watch(l, lw) + list_T *l; + listwatch_T *lw; +--- 3104,3110 ---- + /* + * Add a watcher to a list. + */ +! void + list_add_watch(l, lw) + list_T *l; + listwatch_T *lw; +*************** +*** 3119,3125 **** + * Remove a watcher from a list. + * No warning when it isn't found... + */ +! static void + list_rem_watch(l, lwrem) + list_T *l; + listwatch_T *lwrem; +--- 3117,3123 ---- + * Remove a watcher from a list. + * No warning when it isn't found... + */ +! void + list_rem_watch(l, lwrem) + list_T *l; + listwatch_T *lwrem; +*** ../vim-7.3.946/src/if_py_both.h 2013-05-15 13:38:41.000000000 +0200 +--- src/if_py_both.h 2013-05-15 14:24:11.000000000 +0200 +*************** +*** 531,596 **** + }; + + /* +! * Buffer list object - Implementation + */ + +! static PyTypeObject BufMapType; + + typedef struct + { + PyObject_HEAD +! } BufMapObject; + +! static PyInt +! BufMapLength(PyObject *self UNUSED) + { +! buf_T *b = firstbuf; +! PyInt n = 0; + +! while (b) +! { +! ++n; +! b = b->b_next; +! } + +! return n; + } + +! static PyObject * +! BufMapItem(PyObject *self UNUSED, PyObject *keyObject) + { +! buf_T *b; +! int bnr; + +! #if PY_MAJOR_VERSION < 3 +! if (PyInt_Check(keyObject)) +! bnr = PyInt_AsLong(keyObject); +! else +! #endif +! if (PyLong_Check(keyObject)) +! bnr = PyLong_AsLong(keyObject); +! else +! { +! PyErr_SetString(PyExc_ValueError, _("key must be integer")); +! return NULL; +! } + +! b = buflist_findnr(bnr); + +! if (b) +! return BufferNew(b); +! else +! { +! PyErr_SetString(PyExc_KeyError, _("no such buffer")); +! return NULL; +! } + } + +! static PyMappingMethods BufMapAsMapping = { +! (lenfunc) BufMapLength, +! (binaryfunc) BufMapItem, +! (objobjargproc) 0, +! }; + + typedef struct pylinkedlist_S { + struct pylinkedlist_S *pll_next; +--- 531,592 ---- + }; + + /* +! * Generic iterator object + */ + +! static PyTypeObject IterType; +! +! typedef PyObject *(*nextfun)(void **); +! typedef void (*destructorfun)(void *); +! +! /* Main purpose of this object is removing the need for do python initialization +! * (i.e. PyType_Ready and setting type attributes) for a big bunch of objects. +! */ + + typedef struct + { + PyObject_HEAD +! void *cur; +! nextfun next; +! destructorfun destruct; +! } IterObject; + +! static PyObject * +! IterNew(void *start, destructorfun destruct, nextfun next) + { +! IterObject *self; + +! self = PyObject_NEW(IterObject, &IterType); +! self->cur = start; +! self->next = next; +! self->destruct = destruct; + +! return (PyObject *)(self); + } + +! static void +! IterDestructor(PyObject *self) + { +! IterObject *this = (IterObject *)(self); + +! this->destruct(this->cur); + +! DESTRUCTOR_FINISH(self); +! } + +! static PyObject * +! IterNext(PyObject *self) +! { +! IterObject *this = (IterObject *)(self); +! +! return this->next(&this->cur); + } + +! static PyObject * +! IterIter(PyObject *self) +! { +! return self; +! } + + typedef struct pylinkedlist_S { + struct pylinkedlist_S *pll_next; +*************** +*** 990,995 **** +--- 986,1040 ---- + return list; + } + ++ typedef struct ++ { ++ listwatch_T lw; ++ list_T *list; ++ } listiterinfo_T; ++ ++ static void ++ ListIterDestruct(listiterinfo_T *lii) ++ { ++ list_rem_watch(lii->list, &lii->lw); ++ PyMem_Free(lii); ++ } ++ ++ static PyObject * ++ ListIterNext(listiterinfo_T **lii) ++ { ++ PyObject *r; ++ ++ if (!((*lii)->lw.lw_item)) ++ return NULL; ++ ++ if (!(r = ConvertToPyObject(&((*lii)->lw.lw_item->li_tv)))) ++ return NULL; ++ ++ (*lii)->lw.lw_item = (*lii)->lw.lw_item->li_next; ++ ++ return r; ++ } ++ ++ static PyObject * ++ ListIter(PyObject *self) ++ { ++ listiterinfo_T *lii; ++ list_T *l = ((ListObject *) (self))->list; ++ ++ if (!(lii = PyMem_New(listiterinfo_T, 1))) ++ { ++ PyErr_NoMemory(); ++ return NULL; ++ } ++ ++ list_add_watch(l, &lii->lw); ++ lii->lw.lw_item = l->lv_first; ++ lii->list = l; ++ ++ return IterNew(lii, ++ (destructorfun) ListIterDestruct, (nextfun) ListIterNext); ++ } ++ + static int + ListAssItem(PyObject *self, Py_ssize_t index, PyObject *obj) + { +*************** +*** 2869,2874 **** +--- 2914,3029 ---- + { NULL, NULL, 0, NULL } + }; + ++ /* ++ * Buffer list object - Implementation ++ */ ++ ++ static PyTypeObject BufMapType; ++ ++ typedef struct ++ { ++ PyObject_HEAD ++ } BufMapObject; ++ ++ static PyInt ++ BufMapLength(PyObject *self UNUSED) ++ { ++ buf_T *b = firstbuf; ++ PyInt n = 0; ++ ++ while (b) ++ { ++ ++n; ++ b = b->b_next; ++ } ++ ++ return n; ++ } ++ ++ static PyObject * ++ BufMapItem(PyObject *self UNUSED, PyObject *keyObject) ++ { ++ buf_T *b; ++ int bnr; ++ ++ #if PY_MAJOR_VERSION < 3 ++ if (PyInt_Check(keyObject)) ++ bnr = PyInt_AsLong(keyObject); ++ else ++ #endif ++ if (PyLong_Check(keyObject)) ++ bnr = PyLong_AsLong(keyObject); ++ else ++ { ++ PyErr_SetString(PyExc_ValueError, _("key must be integer")); ++ return NULL; ++ } ++ ++ b = buflist_findnr(bnr); ++ ++ if (b) ++ return BufferNew(b); ++ else ++ { ++ PyErr_SetString(PyExc_KeyError, _("no such buffer")); ++ return NULL; ++ } ++ } ++ ++ static void ++ BufMapIterDestruct(PyObject *buffer) ++ { ++ /* Iteration was stopped before all buffers were processed */ ++ if (buffer) ++ { ++ Py_DECREF(buffer); ++ } ++ } ++ ++ static PyObject * ++ BufMapIterNext(PyObject **buffer) ++ { ++ PyObject *next; ++ PyObject *r; ++ ++ if (!*buffer) ++ return NULL; ++ ++ r = *buffer; ++ ++ if (CheckBuffer((BufferObject *)(r))) ++ { ++ *buffer = NULL; ++ return NULL; ++ } ++ ++ if (!((BufferObject *)(r))->buf->b_next) ++ next = NULL; ++ else if (!(next = BufferNew(((BufferObject *)(r))->buf->b_next))) ++ return NULL; ++ *buffer = next; ++ /* Do not increment reference: we no longer hold it (decref), but whoever on ++ * other side will hold (incref). Decref+incref = nothing. ++ */ ++ return r; ++ } ++ ++ static PyObject * ++ BufMapIter(PyObject *self UNUSED) ++ { ++ PyObject *buffer; ++ ++ buffer = BufferNew(firstbuf); ++ return IterNew(buffer, ++ (destructorfun) BufMapIterDestruct, (nextfun) BufMapIterNext); ++ } ++ ++ static PyMappingMethods BufMapAsMapping = { ++ (lenfunc) BufMapLength, ++ (binaryfunc) BufMapItem, ++ (objobjargproc) 0, ++ }; ++ + /* Current items object + */ + +*************** +*** 3383,3388 **** +--- 3538,3551 ---- + OutputType.tp_setattr = OutputSetattr; + #endif + ++ vim_memset(&IterType, 0, sizeof(IterType)); ++ IterType.tp_name = "vim.iter"; ++ IterType.tp_basicsize = sizeof(IterObject); ++ IterType.tp_flags = Py_TPFLAGS_DEFAULT; ++ IterType.tp_doc = "generic iterator object"; ++ IterType.tp_iter = IterIter; ++ IterType.tp_iternext = IterNext; ++ + vim_memset(&BufferType, 0, sizeof(BufferType)); + BufferType.tp_name = "vim.buffer"; + BufferType.tp_basicsize = sizeof(BufferType); +*************** +*** 3426,3431 **** +--- 3589,3595 ---- + BufMapType.tp_basicsize = sizeof(BufMapObject); + BufMapType.tp_as_mapping = &BufMapAsMapping; + BufMapType.tp_flags = Py_TPFLAGS_DEFAULT; ++ BufMapType.tp_iter = BufMapIter; + BufferType.tp_doc = "vim buffer list"; + + vim_memset(&WinListType, 0, sizeof(WinListType)); +*************** +*** 3492,3497 **** +--- 3656,3662 ---- + ListType.tp_flags = Py_TPFLAGS_DEFAULT; + ListType.tp_doc = "list pushing modifications to vim structure"; + ListType.tp_methods = ListMethods; ++ ListType.tp_iter = ListIter; + #if PY_MAJOR_VERSION >= 3 + ListType.tp_getattro = ListGetattro; + ListType.tp_setattro = ListSetattro; +*************** +*** 3501,3507 **** + #endif + + vim_memset(&FunctionType, 0, sizeof(FunctionType)); +! FunctionType.tp_name = "vim.list"; + FunctionType.tp_basicsize = sizeof(FunctionObject); + FunctionType.tp_dealloc = FunctionDestructor; + FunctionType.tp_call = FunctionCall; +--- 3666,3672 ---- + #endif + + vim_memset(&FunctionType, 0, sizeof(FunctionType)); +! FunctionType.tp_name = "vim.function"; + FunctionType.tp_basicsize = sizeof(FunctionObject); + FunctionType.tp_dealloc = FunctionDestructor; + FunctionType.tp_call = FunctionCall; +*** ../vim-7.3.946/src/if_python3.c 2013-05-15 13:38:41.000000000 +0200 +--- src/if_python3.c 2013-05-15 14:24:11.000000000 +0200 +*************** +*** 1519,1524 **** +--- 1519,1525 ---- + /* The special value is removed from sys.path in Python3_Init(). */ + static wchar_t *(argv[2]) = {L"/must>not&exist/foo", NULL}; + ++ PyType_Ready(&IterType); + PyType_Ready(&BufferType); + PyType_Ready(&RangeType); + PyType_Ready(&WindowType); +*** ../vim-7.3.946/src/if_python.c 2013-05-15 13:38:41.000000000 +0200 +--- src/if_python.c 2013-05-15 14:24:11.000000000 +0200 +*************** +*** 1219,1224 **** +--- 1219,1225 ---- + static char *(argv[2]) = {"/must>not&exist/foo", NULL}; + + /* Fixups... */ ++ PyType_Ready(&IterType); + PyType_Ready(&BufferType); + PyType_Ready(&RangeType); + PyType_Ready(&WindowType); +*** ../vim-7.3.946/src/proto/eval.pro 2013-05-06 03:52:44.000000000 +0200 +--- src/proto/eval.pro 2013-05-15 14:24:11.000000000 +0200 +*************** +*** 127,130 **** +--- 127,132 ---- + char_u *do_string_sub __ARGS((char_u *str, char_u *pat, char_u *sub, char_u *flags)); + int switch_win __ARGS((win_T **, tabpage_T **, win_T *, tabpage_T *)); + void restore_win __ARGS((win_T *, tabpage_T *)); ++ void list_add_watch __ARGS((list_T *l, listwatch_T *lw)); ++ void list_rem_watch __ARGS((list_T *l, listwatch_T *lwrem)); + /* vim: set ft=c : */ +*** ../vim-7.3.946/src/testdir/test86.in 2013-05-12 21:16:17.000000000 +0200 +--- src/testdir/test86.in 2013-05-15 14:27:21.000000000 +0200 +*************** +*** 477,482 **** +--- 477,485 ---- + : call RecVars(oname) + :endfor + :only ++ :for buf in g:bufs[1:] ++ : execute 'bwipeout!' buf ++ :endfor + :" + :" Test buffer object + :vnew +*************** +*** 519,524 **** +--- 522,583 ---- + # Should not happen in any case + cb.append('No exception for ' + expr) + EOF ++ :" ++ :" Test vim.buffers object ++ :set hidden ++ :edit a ++ :buffer # ++ :edit b ++ :buffer # ++ :edit c ++ :buffer # ++ py << EOF ++ # Check GCing iterator that was not fully exhausted ++ i = iter(vim.buffers) ++ cb.append('i:' + str(next(i))) ++ # and also check creating more then one iterator at a time ++ i2 = iter(vim.buffers) ++ cb.append('i2:' + str(next(i2))) ++ cb.append('i:' + str(next(i))) ++ # The following should trigger GC and not cause any problems ++ del i ++ del i2 ++ i3 = iter(vim.buffers) ++ cb.append('i3:' + str(next(i3))) ++ del i3 ++ ++ prevnum = 0 ++ for b in vim.buffers: ++ # Check buffer order ++ if prevnum >= b.number: ++ cb.append('!!! Buffer numbers not in strictly ascending order') ++ # Check indexing: vim.buffers[number].number == number ++ cb.append(str(b.number) + ':' + repr(vim.buffers[b.number]) + '=' + repr(b)) ++ prevnum = b.number ++ ++ cb.append(str(len(vim.buffers))) ++ ++ bnums = list(map(lambda b: b.number, vim.buffers))[1:] ++ ++ # Test wiping out buffer with existing iterator ++ i4 = iter(vim.buffers) ++ cb.append('i4:' + str(next(i4))) ++ vim.command('bwipeout! ' + str(bnums.pop(0))) ++ try: ++ next(i4) ++ except vim.error: ++ pass ++ else: ++ cb.append('!!!! No vim.error') ++ i4 = iter(vim.buffers) ++ vim.command('bwipeout! ' + str(bnums.pop(-1))) ++ vim.command('bwipeout! ' + str(bnums.pop(-1))) ++ cb.append('i4:' + str(next(i4))) ++ try: ++ next(i4) ++ except StopIteration: ++ cb.append('StopIteration') ++ EOF + :endfun + :" + :call Test() +*** ../vim-7.3.946/src/testdir/test86.ok 2013-05-15 13:38:41.000000000 +0200 +--- src/testdir/test86.ok 2013-05-15 14:27:21.000000000 +0200 +*************** +*** 319,321 **** +--- 319,333 ---- + Second line + Third line + foo ++ i: ++ i2: ++ i: ++ i3: ++ 1:= ++ 6:= ++ 7:= ++ 8:= ++ 4 ++ i4: ++ i4: ++ StopIteration +*** ../vim-7.3.946/src/testdir/test87.in 2013-05-12 21:16:17.000000000 +0200 +--- src/testdir/test87.in 2013-05-15 14:27:21.000000000 +0200 +*************** +*** 446,451 **** +--- 446,454 ---- + : call RecVars(oname) + :endfor + :only ++ :for buf in g:bufs[1:] ++ : execute 'bwipeout!' buf ++ :endfor + :" + :" Test buffer object + :vnew +*************** +*** 488,493 **** +--- 491,552 ---- + # Should not happen in any case + cb.append('No exception for ' + expr) + EOF ++ :" ++ :" Test vim.buffers object ++ :set hidden ++ :edit a ++ :buffer # ++ :edit b ++ :buffer # ++ :edit c ++ :buffer # ++ py3 << EOF ++ # Check GCing iterator that was not fully exhausted ++ i = iter(vim.buffers) ++ cb.append('i:' + str(next(i))) ++ # and also check creating more then one iterator at a time ++ i2 = iter(vim.buffers) ++ cb.append('i2:' + str(next(i2))) ++ cb.append('i:' + str(next(i))) ++ # The following should trigger GC and not cause any problems ++ del i ++ del i2 ++ i3 = iter(vim.buffers) ++ cb.append('i3:' + str(next(i3))) ++ del i3 ++ ++ prevnum = 0 ++ for b in vim.buffers: ++ # Check buffer order ++ if prevnum >= b.number: ++ cb.append('!!! Buffer numbers not in strictly ascending order') ++ # Check indexing: vim.buffers[number].number == number ++ cb.append(str(b.number) + ':' + repr(vim.buffers[b.number]) + '=' + repr(b)) ++ prevnum = b.number ++ ++ cb.append(str(len(vim.buffers))) ++ ++ bnums = list(map(lambda b: b.number, vim.buffers))[1:] ++ ++ # Test wiping out buffer with existing iterator ++ i4 = iter(vim.buffers) ++ cb.append('i4:' + str(next(i4))) ++ vim.command('bwipeout! ' + str(bnums.pop(0))) ++ try: ++ next(i4) ++ except vim.error: ++ pass ++ else: ++ cb.append('!!!! No vim.error') ++ i4 = iter(vim.buffers) ++ vim.command('bwipeout! ' + str(bnums.pop(-1))) ++ vim.command('bwipeout! ' + str(bnums.pop(-1))) ++ cb.append('i4:' + str(next(i4))) ++ try: ++ next(i4) ++ except StopIteration: ++ cb.append('StopIteration') ++ EOF + :endfun + :" + :call Test() +*************** +*** 496,501 **** +--- 555,561 ---- + :call garbagecollect(1) + :" + :/^start:/,$wq! test.out ++ :call getchar() + ENDTEST + + start: +*** ../vim-7.3.946/src/testdir/test87.ok 2013-05-15 13:38:41.000000000 +0200 +--- src/testdir/test87.ok 2013-05-15 14:27:21.000000000 +0200 +*************** +*** 308,310 **** +--- 308,322 ---- + Second line + Third line + foo ++ i: ++ i2: ++ i: ++ i3: ++ 1:= ++ 6:= ++ 7:= ++ 8:= ++ 4 ++ i4: ++ i4: ++ StopIteration +*** ../vim-7.3.946/src/version.c 2013-05-15 14:22:36.000000000 +0200 +--- src/version.c 2013-05-15 14:25:26.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 947, + /**/ + +-- +"It's so simple to be wise. Just think of something stupid to say +and then don't say it." -- Sam Levenson + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4352a3b91847ea7dde1a235a9098abef6d85fa10 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:27 +0200 Subject: [PATCH 0847/3340] - patchlevel 948 --- 7.3.948 | 423 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 423 insertions(+) create mode 100644 7.3.948 diff --git a/7.3.948 b/7.3.948 new file mode 100644 index 00000000..d2d2eb35 --- /dev/null +++ b/7.3.948 @@ -0,0 +1,423 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.948 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.948 +Problem: Cannot build with Python 2.2 +Solution: Make Python interface work with Python 2.2 + Make 2.2 the first supported version. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c, + src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.ok, src/configure.in, src/auto/configure + + +*** ../vim-7.3.947/src/if_py_both.h 2013-05-15 14:39:47.000000000 +0200 +--- src/if_py_both.h 2013-05-15 14:49:11.000000000 +0200 +*************** +*** 564,569 **** +--- 564,570 ---- + return (PyObject *)(self); + } + ++ #if 0 /* unused */ + static void + IterDestructor(PyObject *self) + { +*************** +*** 573,578 **** +--- 574,580 ---- + + DESTRUCTOR_FINISH(self); + } ++ #endif + + static PyObject * + IterNext(PyObject *self) +*************** +*** 696,708 **** + } + else + { +! if (!PyBool_Check(val)) +! { +! PyErr_SetString(PyExc_TypeError, _("Only boolean objects are allowed")); +! return -1; +! } +! +! if (val == Py_True) + this->dict->dv_lock = VAR_LOCKED; + else + this->dict->dv_lock = 0; +--- 698,704 ---- + } + else + { +! if (PyObject_IsTrue(val)) + this->dict->dv_lock = VAR_LOCKED; + else + this->dict->dv_lock = 0; +*************** +*** 1202,1214 **** + } + else + { +! if (!PyBool_Check(val)) +! { +! PyErr_SetString(PyExc_TypeError, _("Only boolean objects are allowed")); +! return -1; +! } +! +! if (val == Py_True) + this->list->lv_lock = VAR_LOCKED; + else + this->list->lv_lock = 0; +--- 1198,1204 ---- + } + else + { +! if (PyObject_IsTrue(val)) + this->list->lv_lock = VAR_LOCKED; + else + this->list->lv_lock = 0; +*************** +*** 1484,1497 **** + + if (flags & SOPT_BOOL) + { +! if (!PyBool_Check(valObject)) +! { +! PyErr_SetString(PyExc_ValueError, "Object must be boolean"); +! return -1; +! } +! +! r = set_option_value_for(key, (valObject == Py_True), NULL, opt_flags, +! this->opt_type, this->from); + } + else if (flags & SOPT_NUM) + { +--- 1474,1481 ---- + + if (flags & SOPT_BOOL) + { +! r = set_option_value_for(key, PyObject_IsTrue(valObject), NULL, +! opt_flags, this->opt_type, this->from); + } + else if (flags & SOPT_NUM) + { +*** ../vim-7.3.947/src/if_python3.c 2013-05-15 14:39:47.000000000 +0200 +--- src/if_python3.c 2013-05-15 14:42:21.000000000 +0200 +*************** +*** 156,161 **** +--- 156,162 ---- + # define PyMapping_Items py3_PyMapping_Items + # define PyIter_Next py3_PyIter_Next + # define PyObject_GetIter py3_PyObject_GetIter ++ # define PyObject_IsTrue py3_PyObject_IsTrue + # define PyModule_GetDict py3_PyModule_GetDict + #undef PyRun_SimpleString + # define PyRun_SimpleString py3_PyRun_SimpleString +*************** +*** 264,269 **** +--- 265,271 ---- + static PyObject* (*py3_PyDict_New)(void); + static PyObject* (*py3_PyIter_Next)(PyObject *); + static PyObject* (*py3_PyObject_GetIter)(PyObject *); ++ static int (*py3_PyObject_IsTrue)(PyObject *); + static PyObject* (*py3_Py_BuildValue)(char *, ...); + static int (*py3_PyType_Ready)(PyTypeObject *type); + static int (*py3_PyDict_SetItemString)(PyObject *dp, char *key, PyObject *item); +*************** +*** 392,397 **** +--- 394,400 ---- + {"PyMapping_Items", (PYTHON_PROC*)&py3_PyMapping_Items}, + {"PyIter_Next", (PYTHON_PROC*)&py3_PyIter_Next}, + {"PyObject_GetIter", (PYTHON_PROC*)&py3_PyObject_GetIter}, ++ {"PyObject_IsTrue", (PYTHON_PROC*)&py3_PyObject_IsTrue}, + {"PyLong_FromLong", (PYTHON_PROC*)&py3_PyLong_FromLong}, + {"PyDict_New", (PYTHON_PROC*)&py3_PyDict_New}, + {"PyType_Ready", (PYTHON_PROC*)&py3_PyType_Ready}, +*** ../vim-7.3.947/src/if_python.c 2013-05-15 14:39:47.000000000 +0200 +--- src/if_python.c 2013-05-15 14:42:21.000000000 +0200 +*************** +*** 229,234 **** +--- 229,235 ---- + # define _Py_TrueStruct (*dll__Py_TrueStruct) + # define PyObject_Init dll__PyObject_Init + # define PyObject_GetIter dll_PyObject_GetIter ++ # define PyObject_IsTrue dll_PyObject_IsTrue + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + # define PyType_IsSubtype dll_PyType_IsSubtype + # endif +*************** +*** 324,329 **** +--- 325,331 ---- + static PyObject*(*dll__PyObject_New)(PyTypeObject *, PyObject *); + static PyObject*(*dll__PyObject_Init)(PyObject *, PyTypeObject *); + static PyObject* (*dll_PyObject_GetIter)(PyObject *); ++ static int (*dll_PyObject_IsTrue)(PyObject *); + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02070000 + static iternextfunc dll__PyObject_NextNotImplemented; + # endif +*************** +*** 459,464 **** +--- 461,467 ---- + {"_PyObject_New", (PYTHON_PROC*)&dll__PyObject_New}, + {"PyObject_Init", (PYTHON_PROC*)&dll__PyObject_Init}, + {"PyObject_GetIter", (PYTHON_PROC*)&dll_PyObject_GetIter}, ++ {"PyObject_IsTrue", (PYTHON_PROC*)&dll_PyObject_IsTrue}, + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02070000 + {"_PyObject_NextNotImplemented", (PYTHON_PROC*)&dll__PyObject_NextNotImplemented}, + # endif +*************** +*** 787,793 **** + * so the following does both: unlock GIL and save thread state in TLS + * without deleting thread state + */ +! PyEval_SaveThread(); + + initialised = 1; + } +--- 790,799 ---- + * so the following does both: unlock GIL and save thread state in TLS + * without deleting thread state + */ +! #ifndef PY_CAN_RECURSE +! saved_python_thread = +! #endif +! PyEval_SaveThread(); + + initialised = 1; + } +*** ../vim-7.3.947/src/testdir/test86.in 2013-05-15 14:39:47.000000000 +0200 +--- src/testdir/test86.in 2013-05-15 14:42:21.000000000 +0200 +*************** +*** 183,220 **** + : $put ='[0.0, 0.0]' + :endif + :let messages=[] +! :py <>> paste + p/gopts1: False +- inv: 2! ValueError + p/wopts1! KeyError + inv: 2! KeyError + wopts1! KeyError +--- 82,87 ---- +*************** +*** 224,230 **** + wopts2! KeyError + wopts3! KeyError + p/bopts1: False +- inv: 2! ValueError + G: 0 + W: 1:0 2:1 3:0 4:1 + B: 1:0 2:1 3:0 4:1 +--- 223,228 ---- +*************** +*** 280,286 **** + wopts2! KeyError + wopts3! KeyError + p/bopts1: False +- inv: 2! ValueError + G: 0 + W: 1:0 2:1 3:0 4:1 + B: 1:0 2:1 3:0 4:1 +--- 278,283 ---- +*** ../vim-7.3.947/src/testdir/test87.ok 2013-05-15 14:39:47.000000000 +0200 +--- src/testdir/test87.ok 2013-05-15 14:42:21.000000000 +0200 +*************** +*** 71,77 **** + bar + >>> paste + p/gopts1: False +- inv: 2! ValueError + p/wopts1! KeyError + inv: 2! KeyError + wopts1! KeyError +--- 71,76 ---- +*************** +*** 213,219 **** + wopts2! KeyError + wopts3! KeyError + p/bopts1: False +- inv: 2! ValueError + G: 0 + W: 1:0 2:1 3:0 4:1 + B: 1:0 2:1 3:0 4:1 +--- 212,217 ---- +*************** +*** 269,275 **** + wopts2! KeyError + wopts3! KeyError + p/bopts1: False +- inv: 2! ValueError + G: 0 + W: 1:0 2:1 3:0 4:1 + B: 1:0 2:1 3:0 4:1 +--- 267,272 ---- +*** ../vim-7.3.947/src/configure.in 2013-05-06 04:21:35.000000000 +0200 +--- src/configure.in 2013-05-15 14:46:11.000000000 +0200 +*************** +*** 863,872 **** + ${vi_cv_path_python} -c 'import sys; print sys.version[:3]'` + ]]) + +! dnl -- it must be at least version 1.4 +! AC_MSG_CHECKING(Python is 1.4 or better) + if ${vi_cv_path_python} -c \ +! "import sys; sys.exit(${vi_cv_var_python_version} < 1.4)" + then + AC_MSG_RESULT(yep) + +--- 863,872 ---- + ${vi_cv_path_python} -c 'import sys; print sys.version[:3]'` + ]]) + +! dnl -- it must be at least version 2.2 +! AC_MSG_CHECKING(Python is 2.2 or better) + if ${vi_cv_path_python} -c \ +! "import sys; sys.exit(${vi_cv_var_python_version} < 2.2)" + then + AC_MSG_RESULT(yep) + +*** ../vim-7.3.947/src/auto/configure 2013-05-06 04:21:35.000000000 +0200 +--- src/auto/configure 2013-05-15 14:46:28.000000000 +0200 +*************** +*** 5289,5298 **** + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_var_python_version" >&5 + $as_echo "$vi_cv_var_python_version" >&6; } + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python is 1.4 or better" >&5 +! $as_echo_n "checking Python is 1.4 or better... " >&6; } + if ${vi_cv_path_python} -c \ +! "import sys; sys.exit(${vi_cv_var_python_version} < 1.4)" + then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yep" >&5 + $as_echo "yep" >&6; } +--- 5289,5298 ---- + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_var_python_version" >&5 + $as_echo "$vi_cv_var_python_version" >&6; } + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python is 2.2 or better" >&5 +! $as_echo_n "checking Python is 2.2 or better... " >&6; } + if ${vi_cv_path_python} -c \ +! "import sys; sys.exit(${vi_cv_var_python_version} < 2.2)" + then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yep" >&5 + $as_echo "yep" >&6; } +*** ../vim-7.3.947/src/version.c 2013-05-15 14:39:47.000000000 +0200 +--- src/version.c 2013-05-15 14:43:39.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 948, + /**/ + +-- +MARTHA'S WAY: Don't throw out all that leftover wine. Freeze into ice cubes + for future use in casseroles and sauces. +MY WAY: What leftover wine? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 88a91da9f3fa466f7e4e812c4719af4eb81953ba Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:28 +0200 Subject: [PATCH 0848/3340] - patchlevel 949 --- 7.3.949 | 919 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 919 insertions(+) create mode 100644 7.3.949 diff --git a/7.3.949 b/7.3.949 new file mode 100644 index 00000000..419913ab --- /dev/null +++ b/7.3.949 @@ -0,0 +1,919 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.949 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.949 +Problem: Python: no easy access to tabpages. +Solution: Add vim.tabpages and vim.current.tabpage. (ZyX) +Files: runtime/doc/if_pyth.txt, src/if_py_both.h, src/if_python3.c, + src/if_python.c, src/proto/if_python3.pro, + src/proto/if_python.pro, src/proto/window.pro, src/structs.h, + src/window.c + + +*** ../vim-7.3.948/runtime/doc/if_pyth.txt 2013-05-15 14:39:47.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-05-15 15:05:04.000000000 +0200 +*************** +*** 223,228 **** +--- 223,242 ---- + :py w in vim.windows # Membership test + :py n = len(vim.windows) # Number of elements + :py for w in vim.windows: # Sequential access ++ < Note: vim.windows object always accesses current tab page,. ++ |python-tabpage|.windows objects are bound to parent |python-tabpage| ++ object and always use windows from that tab page (or throw vim.error ++ in case tab page was deleted). You can keep a reference to both ++ without keeping a reference to vim module object or |python-tabpage|, ++ they will not loose their properties in this case. ++ ++ vim.tabpages *python-tabpages* ++ A sequence object providing access to the list of vim tab pages. The ++ object supports the following operations: > ++ :py t = vim.tabpages[i] # Indexing (read-only) ++ :py t in vim.tabpages # Membership test ++ :py n = len(vim.tabpages) # Number of elements ++ :py for t in vim.tabpages: # Sequential access + < + vim.current *python-current* + An object providing access (via specific attributes) to various +*************** +*** 230,235 **** +--- 244,250 ---- + vim.current.line The current line (RW) String + vim.current.buffer The current buffer (RO) Buffer + vim.current.window The current window (RO) Window ++ vim.current.tabpage The current tab page (RO) TabPage + vim.current.range The current line range (RO) Range + + The last case deserves a little explanation. When the :python or +*************** +*** 375,380 **** +--- 390,397 ---- + Window objects represent vim windows. You can obtain them in a number of ways: + - via vim.current.window (|python-current|) + - from indexing vim.windows (|python-windows|) ++ - from indexing "windows" attribute of a tab page (|python-tabpage|) ++ - from the "window" attribute of a tab page (|python-tabpage|) + + You can manipulate window objects only through their attributes. They have no + methods, and no sequence or other interface. +*************** +*** 407,412 **** +--- 424,447 ---- + The width attribute is writable only if the screen is split vertically. + + ============================================================================== ++ 6. Tab page objects *python-tabpage* ++ ++ Tab page objects represent vim tab pages. You can obtain them in a number of ++ ways: ++ - via vim.current.tabpage (|python-current|) ++ - from indexing vim.tabpages (|python-tabpages|) ++ ++ You can use this object to access tab page windows. They have no methods and ++ no sequence or other interfaces. ++ ++ Tab page attributes are: ++ number The tab page number like the one returned by ++ |tabpagenr()|. ++ windows Like |python-windows|, but for current tab page. ++ vars The tab page |t:| variables. ++ window Current tabpage window. ++ ++ ============================================================================== + 6. pyeval() and py3eval() Vim functions *python-pyeval* + + To facilitate bi-directional interface, you can use |pyeval()| and |py3eval()| +*** ../vim-7.3.948/src/if_py_both.h 2013-05-15 14:51:31.000000000 +0200 +--- src/if_py_both.h 2013-05-15 15:10:16.000000000 +0200 +*************** +*** 27,32 **** +--- 27,33 ---- + + #define INVALID_BUFFER_VALUE ((buf_T *)(-1)) + #define INVALID_WINDOW_VALUE ((win_T *)(-1)) ++ #define INVALID_TABPAGE_VALUE ((tabpage_T *)(-1)) + + static int ConvertFromPyObject(PyObject *, typval_T *); + static int _ConvertFromPyObject(PyObject *, typval_T *, PyObject *); +*************** +*** 1579,1584 **** +--- 1580,1734 ---- + (objobjargproc) OptionsAssItem, + }; + ++ /* Tabpage object ++ */ ++ ++ typedef struct ++ { ++ PyObject_HEAD ++ tabpage_T *tab; ++ } TabPageObject; ++ ++ static PyObject *WinListNew(TabPageObject *tabObject); ++ ++ static PyTypeObject TabPageType; ++ ++ static int ++ CheckTabPage(TabPageObject *this) ++ { ++ if (this->tab == INVALID_TABPAGE_VALUE) ++ { ++ PyErr_SetVim(_("attempt to refer to deleted tab page")); ++ return -1; ++ } ++ ++ return 0; ++ } ++ ++ static PyObject * ++ TabPageNew(tabpage_T *tab) ++ { ++ TabPageObject *self; ++ ++ if (TAB_PYTHON_REF(tab)) ++ { ++ self = TAB_PYTHON_REF(tab); ++ Py_INCREF(self); ++ } ++ else ++ { ++ self = PyObject_NEW(TabPageObject, &TabPageType); ++ if (self == NULL) ++ return NULL; ++ self->tab = tab; ++ TAB_PYTHON_REF(tab) = self; ++ } ++ ++ return (PyObject *)(self); ++ } ++ ++ static void ++ TabPageDestructor(PyObject *self) ++ { ++ TabPageObject *this = (TabPageObject *)(self); ++ ++ if (this->tab && this->tab != INVALID_TABPAGE_VALUE) ++ TAB_PYTHON_REF(this->tab) = NULL; ++ ++ DESTRUCTOR_FINISH(self); ++ } ++ ++ static PyObject * ++ TabPageAttr(TabPageObject *this, char *name) ++ { ++ if (strcmp(name, "windows") == 0) ++ return WinListNew(this); ++ else if (strcmp(name, "number") == 0) ++ return PyLong_FromLong((long) get_tab_number(this->tab)); ++ else if (strcmp(name, "vars") == 0) ++ return DictionaryNew(this->tab->tp_vars); ++ else if (strcmp(name, "window") == 0) ++ { ++ /* For current tab window.c does not bother to set or update tp_curwin ++ */ ++ if (this->tab == curtab) ++ return WindowNew(curwin); ++ else ++ return WindowNew(this->tab->tp_curwin); ++ } ++ return NULL; ++ } ++ ++ static PyObject * ++ TabPageRepr(PyObject *self) ++ { ++ static char repr[100]; ++ TabPageObject *this = (TabPageObject *)(self); ++ ++ if (this->tab == INVALID_TABPAGE_VALUE) ++ { ++ vim_snprintf(repr, 100, _(""), (self)); ++ return PyString_FromString(repr); ++ } ++ else ++ { ++ int t = get_tab_number(this->tab); ++ ++ if (t == 0) ++ vim_snprintf(repr, 100, _(""), ++ (self)); ++ else ++ vim_snprintf(repr, 100, _(""), t - 1); ++ ++ return PyString_FromString(repr); ++ } ++ } ++ ++ static struct PyMethodDef TabPageMethods[] = { ++ /* name, function, calling, documentation */ ++ { NULL, NULL, 0, NULL } ++ }; ++ ++ /* ++ * Window list object ++ */ ++ ++ static PyTypeObject TabListType; ++ static PySequenceMethods TabListAsSeq; ++ ++ typedef struct ++ { ++ PyObject_HEAD ++ } TabListObject; ++ ++ static PyInt ++ TabListLength(PyObject *self UNUSED) ++ { ++ tabpage_T *tp = first_tabpage; ++ PyInt n = 0; ++ ++ while (tp != NULL) ++ { ++ ++n; ++ tp = tp->tp_next; ++ } ++ ++ return n; ++ } ++ ++ static PyObject * ++ TabListItem(PyObject *self UNUSED, PyInt n) ++ { ++ tabpage_T *tp; ++ ++ for (tp = first_tabpage; tp != NULL; tp = tp->tp_next, --n) ++ if (n == 0) ++ return TabPageNew(tp); ++ ++ PyErr_SetString(PyExc_IndexError, _("no such tab page")); ++ return NULL; ++ } ++ + /* Window object + */ + +*************** +*** 1588,1595 **** + win_T *win; + } WindowObject; + +- static int WindowSetattr(PyObject *, char *, PyObject *); +- static PyObject *WindowRepr(PyObject *); + static PyTypeObject WindowType; + + static int +--- 1738,1743 ---- +*************** +*** 1681,1687 **** + return OptionsNew(SREQ_WIN, this->win, (checkfun) CheckWindow, + (PyObject *) this); + else if (strcmp(name, "number") == 0) +! return PyLong_FromLong((long) get_win_number(this->win)); + else if (strcmp(name,"__members__") == 0) + return Py_BuildValue("[ssssssss]", "buffer", "cursor", "height", "vars", + "options", "number", "row", "col"); +--- 1829,1835 ---- + return OptionsNew(SREQ_WIN, this->win, (checkfun) CheckWindow, + (PyObject *) this); + else if (strcmp(name, "number") == 0) +! return PyLong_FromLong((long) get_win_number(this->win, firstwin)); + else if (strcmp(name,"__members__") == 0) + return Py_BuildValue("[ssssssss]", "buffer", "cursor", "height", "vars", + "options", "number", "row", "col"); +*************** +*** 1797,1803 **** + } + else + { +! int w = get_win_number(this->win); + + if (w == 0) + vim_snprintf(repr, 100, _(""), +--- 1945,1951 ---- + } + else + { +! int w = get_win_number(this->win, firstwin); + + if (w == 0) + vim_snprintf(repr, 100, _(""), +*************** +*** 1824,1837 **** + typedef struct + { + PyObject_HEAD + } WinListObject; + + static PyInt +! WinListLength(PyObject *self UNUSED) + { +! win_T *w = firstwin; + PyInt n = 0; + + while (w != NULL) + { + ++n; +--- 1972,2030 ---- + typedef struct + { + PyObject_HEAD ++ TabPageObject *tabObject; + } WinListObject; + ++ static PyObject * ++ WinListNew(TabPageObject *tabObject) ++ { ++ WinListObject *self; ++ ++ self = PyObject_NEW(WinListObject, &WinListType); ++ self->tabObject = tabObject; ++ Py_INCREF(tabObject); ++ ++ return (PyObject *)(self); ++ } ++ ++ static void ++ WinListDestructor(PyObject *self) ++ { ++ TabPageObject *tabObject = ((WinListObject *)(self))->tabObject; ++ ++ if (tabObject) ++ Py_DECREF((PyObject *)(tabObject)); ++ ++ DESTRUCTOR_FINISH(self); ++ } ++ ++ static win_T * ++ get_firstwin(WinListObject *this) ++ { ++ if (this->tabObject) ++ { ++ if (CheckTabPage(this->tabObject)) ++ return NULL; ++ /* For current tab window.c does not bother to set or update tp_firstwin ++ */ ++ else if (this->tabObject->tab == curtab) ++ return firstwin; ++ else ++ return this->tabObject->tab->tp_firstwin; ++ } ++ else ++ return firstwin; ++ } ++ + static PyInt +! WinListLength(PyObject *self) + { +! win_T *w; + PyInt n = 0; + ++ if (!(w = get_firstwin((WinListObject *)(self)))) ++ return -1; ++ + while (w != NULL) + { + ++n; +*************** +*** 1842,1852 **** + } + + static PyObject * +! WinListItem(PyObject *self UNUSED, PyInt n) + { + win_T *w; + +! for (w = firstwin; w != NULL; w = W_NEXT(w), --n) + if (n == 0) + return WindowNew(w); + +--- 2035,2048 ---- + } + + static PyObject * +! WinListItem(PyObject *self, PyInt n) + { + win_T *w; + +! if (!(w = get_firstwin((WinListObject *)(self)))) +! return NULL; +! +! for (; w != NULL; w = W_NEXT(w), --n) + if (n == 0) + return WindowNew(w); + +*************** +*** 3018,3029 **** + return (PyObject *)BufferNew(curbuf); + else if (strcmp(name, "window") == 0) + return (PyObject *)WindowNew(curwin); + else if (strcmp(name, "line") == 0) + return GetBufferLine(curbuf, (PyInt)curwin->w_cursor.lnum); + else if (strcmp(name, "range") == 0) + return RangeNew(curbuf, RangeStart, RangeEnd); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[ssss]", "buffer", "window", "line", "range"); + else + { + PyErr_SetString(PyExc_AttributeError, name); +--- 3214,3228 ---- + return (PyObject *)BufferNew(curbuf); + else if (strcmp(name, "window") == 0) + return (PyObject *)WindowNew(curwin); ++ else if (strcmp(name, "tabpage") == 0) ++ return (PyObject *)TabPageNew(curtab); + else if (strcmp(name, "line") == 0) + return GetBufferLine(curbuf, (PyInt)curwin->w_cursor.lnum); + else if (strcmp(name, "range") == 0) + return RangeNew(curbuf, RangeStart, RangeEnd); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[sssss]", "buffer", "window", "line", "range", +! "tabpage"); + else + { + PyErr_SetString(PyExc_AttributeError, name); +*************** +*** 3568,3573 **** +--- 3767,3789 ---- + WindowType.tp_setattr = WindowSetattr; + #endif + ++ vim_memset(&TabPageType, 0, sizeof(TabPageType)); ++ TabPageType.tp_name = "vim.tabpage"; ++ TabPageType.tp_basicsize = sizeof(TabPageObject); ++ TabPageType.tp_dealloc = TabPageDestructor; ++ TabPageType.tp_repr = TabPageRepr; ++ TabPageType.tp_flags = Py_TPFLAGS_DEFAULT; ++ TabPageType.tp_doc = "vim tab page object"; ++ TabPageType.tp_methods = TabPageMethods; ++ #if PY_MAJOR_VERSION >= 3 ++ TabPageType.tp_getattro = TabPageGetattro; ++ TabPageType.tp_alloc = call_PyType_GenericAlloc; ++ TabPageType.tp_new = call_PyType_GenericNew; ++ TabPageType.tp_free = call_PyObject_Free; ++ #else ++ TabPageType.tp_getattr = TabPageGetattr; ++ #endif ++ + vim_memset(&BufMapType, 0, sizeof(BufMapType)); + BufMapType.tp_name = "vim.bufferlist"; + BufMapType.tp_basicsize = sizeof(BufMapObject); +*************** +*** 3582,3587 **** +--- 3798,3811 ---- + WinListType.tp_as_sequence = &WinListAsSeq; + WinListType.tp_flags = Py_TPFLAGS_DEFAULT; + WinListType.tp_doc = "vim window list"; ++ WinListType.tp_dealloc = WinListDestructor; ++ ++ vim_memset(&TabListType, 0, sizeof(TabListType)); ++ TabListType.tp_name = "vim.tabpagelist"; ++ TabListType.tp_basicsize = sizeof(TabListType); ++ TabListType.tp_as_sequence = &TabListAsSeq; ++ TabListType.tp_flags = Py_TPFLAGS_DEFAULT; ++ TabListType.tp_doc = "vim tab page list"; + + vim_memset(&RangeType, 0, sizeof(RangeType)); + RangeType.tp_name = "vim.range"; +*** ../vim-7.3.948/src/if_python3.c 2013-05-15 14:51:31.000000000 +0200 +--- src/if_python3.c 2013-05-15 15:05:04.000000000 +0200 +*************** +*** 626,631 **** +--- 626,632 ---- + + #define WIN_PYTHON_REF(win) win->w_python3_ref + #define BUF_PYTHON_REF(buf) buf->b_python3_ref ++ #define TAB_PYTHON_REF(tab) tab->tp_python3_ref + + static void + call_PyObject_Free(void *p) +*************** +*** 652,657 **** +--- 653,659 ---- + static PyObject *OutputGetattro(PyObject *, PyObject *); + static int OutputSetattro(PyObject *, PyObject *, PyObject *); + static PyObject *BufferGetattro(PyObject *, PyObject *); ++ static PyObject *TabPageGetattro(PyObject *, PyObject *); + static PyObject *WindowGetattro(PyObject *, PyObject *); + static int WindowSetattro(PyObject *, PyObject *, PyObject *); + static PyObject *RangeGetattro(PyObject *, PyObject *); +*************** +*** 1275,1280 **** +--- 1277,1302 ---- + } + } + ++ /* TabPage object - Implementation ++ */ ++ ++ static PyObject * ++ TabPageGetattro(PyObject *self, PyObject *nameobj) ++ { ++ PyObject *r; ++ ++ GET_ATTR_STRING(name, nameobj); ++ ++ if (CheckTabPage((TabPageObject *)(self))) ++ return NULL; ++ ++ r = TabPageAttr((TabPageObject *)(self), name); ++ if (r || PyErr_Occurred()) ++ return r; ++ else ++ return PyObject_GenericGetAttr(self, nameobj); ++ } ++ + /* Window object - Implementation + */ + +*************** +*** 1303,1308 **** +--- 1325,1346 ---- + return WindowSetattr(self, name, val); + } + ++ /* Tab page list object - Definitions ++ */ ++ ++ static PySequenceMethods TabListAsSeq = { ++ (lenfunc) TabListLength, /* sq_length, len(x) */ ++ (binaryfunc) 0, /* sq_concat, x+y */ ++ (ssizeargfunc) 0, /* sq_repeat, x*n */ ++ (ssizeargfunc) TabListItem, /* sq_item, x[i] */ ++ 0, /* sq_slice, x[i:j] */ ++ (ssizeobjargproc)0, /* sq_as_item, x[i]=v */ ++ 0, /* sq_ass_slice, x[i:j]=v */ ++ 0, /* sq_contains */ ++ 0, /* sq_inplace_concat */ ++ 0, /* sq_inplace_repeat */ ++ }; ++ + /* Window list object - Definitions + */ + +*************** +*** 1497,1502 **** +--- 1535,1551 ---- + WIN_PYTHON_REF(win) = NULL; + } + } ++ ++ void ++ python3_tabpage_free(tabpage_T *tab) ++ { ++ if (TAB_PYTHON_REF(tab) != NULL) ++ { ++ TabPageObject *tp = TAB_PYTHON_REF(tab); ++ tp->tab = INVALID_TABPAGE_VALUE; ++ TAB_PYTHON_REF(tab) = NULL; ++ } ++ } + #endif + + static BufMapObject TheBufferMap = +*************** +*** 1507,1512 **** +--- 1556,1562 ---- + static WinListObject TheWindowList = + { + PyObject_HEAD_INIT(&WinListType) ++ NULL + }; + + static CurrentObject TheCurrent = +*************** +*** 1514,1519 **** +--- 1564,1574 ---- + PyObject_HEAD_INIT(&CurrentType) + }; + ++ static TabListObject TheTabPageList = ++ { ++ PyObject_HEAD_INIT(&TabListType) ++ }; ++ + static PyObject * + Py3Init_vim(void) + { +*************** +*** 1526,1533 **** +--- 1581,1590 ---- + PyType_Ready(&BufferType); + PyType_Ready(&RangeType); + PyType_Ready(&WindowType); ++ PyType_Ready(&TabPageType); + PyType_Ready(&BufMapType); + PyType_Ready(&WinListType); ++ PyType_Ready(&TabListType); + PyType_Ready(&CurrentType); + PyType_Ready(&DictionaryType); + PyType_Ready(&ListType); +*************** +*** 1551,1556 **** +--- 1608,1615 ---- + PyModule_AddObject(mod, "current", (PyObject *)(void *)&TheCurrent); + Py_INCREF((PyObject *)(void *)&TheWindowList); + PyModule_AddObject(mod, "windows", (PyObject *)(void *)&TheWindowList); ++ Py_INCREF((PyObject *)(void *)&TheTabPageList); ++ PyModule_AddObject(mod, "tabpages", (PyObject *)(void *)&TheTabPageList); + + PyModule_AddObject(mod, "vars", DictionaryNew(&globvardict)); + PyModule_AddObject(mod, "vvars", DictionaryNew(&vimvardict)); +*** ../vim-7.3.948/src/if_python.c 2013-05-15 14:51:31.000000000 +0200 +--- src/if_python.c 2013-05-15 15:05:04.000000000 +0200 +*************** +*** 624,633 **** +--- 624,635 ---- + + #define WIN_PYTHON_REF(win) win->w_python_ref + #define BUF_PYTHON_REF(buf) buf->b_python_ref ++ #define TAB_PYTHON_REF(tab) tab->tp_python_ref + + static PyObject *OutputGetattr(PyObject *, char *); + static PyObject *BufferGetattr(PyObject *, char *); + static PyObject *WindowGetattr(PyObject *, char *); ++ static PyObject *TabPageGetattr(PyObject *, char *); + static PyObject *RangeGetattr(PyObject *, char *); + static PyObject *DictionaryGetattr(PyObject *, char*); + static PyObject *ListGetattr(PyObject *, char *); +*************** +*** 1137,1142 **** +--- 1139,1162 ---- + &((RangeObject *)(self))->end); + } + ++ /* TabPage object - Implementation ++ */ ++ ++ static PyObject * ++ TabPageGetattr(PyObject *self, char *name) ++ { ++ PyObject *r; ++ ++ if (CheckTabPage((TabPageObject *)(self))) ++ return NULL; ++ ++ r = TabPageAttr((TabPageObject *)(self), name); ++ if (r || PyErr_Occurred()) ++ return r; ++ else ++ return Py_FindMethod(TabPageMethods, self, name); ++ } ++ + /* Window object - Implementation + */ + +*************** +*** 1155,1160 **** +--- 1175,1198 ---- + return Py_FindMethod(WindowMethods, self, name); + } + ++ /* Tab page list object - Definitions ++ */ ++ ++ static PySequenceMethods TabListAsSeq = { ++ (PyInquiry) TabListLength, /* sq_length, len(x) */ ++ (binaryfunc) 0, /* sq_concat, x+y */ ++ (PyIntArgFunc) 0, /* sq_repeat, x*n */ ++ (PyIntArgFunc) TabListItem, /* sq_item, x[i] */ ++ (PyIntIntArgFunc) 0, /* sq_slice, x[i:j] */ ++ (PyIntObjArgProc) 0, /* sq_ass_item, x[i]=v */ ++ (PyIntIntObjArgProc) 0, /* sq_ass_slice, x[i:j]=v */ ++ (objobjproc) 0, ++ #if PY_MAJOR_VERSION >= 2 ++ (binaryfunc) 0, ++ 0, ++ #endif ++ }; ++ + /* Window list object - Definitions + */ + +*************** +*** 1198,1203 **** +--- 1236,1252 ---- + WIN_PYTHON_REF(win) = NULL; + } + } ++ ++ void ++ python_tabpage_free(tabpage_T *tab) ++ { ++ if (TAB_PYTHON_REF(tab) != NULL) ++ { ++ TabPageObject *tp = TAB_PYTHON_REF(tab); ++ tp->tab = INVALID_TABPAGE_VALUE; ++ TAB_PYTHON_REF(tab) = NULL; ++ } ++ } + #endif + + static BufMapObject TheBufferMap = +*************** +*** 1208,1213 **** +--- 1257,1263 ---- + static WinListObject TheWindowList = + { + PyObject_HEAD_INIT(&WinListType) ++ NULL + }; + + static CurrentObject TheCurrent = +*************** +*** 1215,1220 **** +--- 1265,1275 ---- + PyObject_HEAD_INIT(&CurrentType) + }; + ++ static TabListObject TheTabPageList = ++ { ++ PyObject_HEAD_INIT(&TabListType) ++ }; ++ + static int + PythonMod_Init(void) + { +*************** +*** 1229,1236 **** +--- 1284,1293 ---- + PyType_Ready(&BufferType); + PyType_Ready(&RangeType); + PyType_Ready(&WindowType); ++ PyType_Ready(&TabPageType); + PyType_Ready(&BufMapType); + PyType_Ready(&WinListType); ++ PyType_Ready(&TabListType); + PyType_Ready(&CurrentType); + PyType_Ready(&OptionsType); + +*************** +*** 1246,1251 **** +--- 1303,1309 ---- + PyDict_SetItemString(dict, "buffers", (PyObject *)(void *)&TheBufferMap); + PyDict_SetItemString(dict, "current", (PyObject *)(void *)&TheCurrent); + PyDict_SetItemString(dict, "windows", (PyObject *)(void *)&TheWindowList); ++ PyDict_SetItemString(dict, "tabpages", (PyObject *)(void *)&TheTabPageList); + tmp = DictionaryNew(&globvardict); + PyDict_SetItemString(dict, "vars", tmp); + Py_DECREF(tmp); +*** ../vim-7.3.948/src/proto/if_python3.pro 2012-06-29 12:54:32.000000000 +0200 +--- src/proto/if_python3.pro 2013-05-15 15:05:04.000000000 +0200 +*************** +*** 6,11 **** +--- 6,12 ---- + void ex_py3file __ARGS((exarg_T *eap)); + void python3_buffer_free __ARGS((buf_T *buf)); + void python3_window_free __ARGS((win_T *win)); ++ void python3_tabpage_free __ARGS((tabpage_T *tab)); + void do_py3eval __ARGS((char_u *str, typval_T *rettv)); + void set_ref_in_python3 __ARGS((int copyID)); + /* vim: set ft=c : */ +*** ../vim-7.3.948/src/proto/if_python.pro 2012-06-29 12:54:32.000000000 +0200 +--- src/proto/if_python.pro 2013-05-15 15:05:04.000000000 +0200 +*************** +*** 6,11 **** +--- 6,12 ---- + void ex_pyfile __ARGS((exarg_T *eap)); + void python_buffer_free __ARGS((buf_T *buf)); + void python_window_free __ARGS((win_T *win)); ++ void python_tabpage_free __ARGS((tabpage_T *tab)); + void do_pyeval __ARGS((char_u *str, typval_T *rettv)); + void set_ref_in_python __ARGS((int copyID)); + /* vim: set ft=c : */ +*** ../vim-7.3.948/src/proto/window.pro 2013-05-12 19:00:36.000000000 +0200 +--- src/proto/window.pro 2013-05-15 15:05:04.000000000 +0200 +*************** +*** 74,78 **** + int match_delete __ARGS((win_T *wp, int id, int perr)); + void clear_matches __ARGS((win_T *wp)); + matchitem_T *get_match __ARGS((win_T *wp, int id)); +! int get_win_number __ARGS((win_T *wp)); + /* vim: set ft=c : */ +--- 74,79 ---- + int match_delete __ARGS((win_T *wp, int id, int perr)); + void clear_matches __ARGS((win_T *wp)); + matchitem_T *get_match __ARGS((win_T *wp, int id)); +! int get_win_number __ARGS((win_T *wp, win_T *first_win)); +! int get_tab_number __ARGS((tabpage_T *tp)); + /* vim: set ft=c : */ +*** ../vim-7.3.948/src/structs.h 2013-05-06 04:21:35.000000000 +0200 +--- src/structs.h 2013-05-15 15:05:04.000000000 +0200 +*************** +*** 1759,1764 **** +--- 1759,1772 ---- + dictitem_T tp_winvar; /* variable for "t:" Dictionary */ + dict_T *tp_vars; /* internal variables, local to tab page */ + #endif ++ ++ #ifdef FEAT_PYTHON ++ void *tp_python_ref; /* The Python value for this tab page */ ++ #endif ++ ++ #ifdef FEAT_PYTHON3 ++ void *tp_python3_ref; /* The Python value for this tab page */ ++ #endif + }; + + /* +*** ../vim-7.3.948/src/window.c 2013-05-12 19:00:36.000000000 +0200 +--- src/window.c 2013-05-15 15:05:04.000000000 +0200 +*************** +*** 3510,3515 **** +--- 3510,3524 ---- + hash_init(&tp->tp_vars->dv_hashtab); + unref_var_dict(tp->tp_vars); + #endif ++ ++ #ifdef FEAT_PYTHON ++ python_tabpage_free(tp); ++ #endif ++ ++ #ifdef FEAT_PYTHON3 ++ python3_tabpage_free(tp); ++ #endif ++ + vim_free(tp); + } + +*************** +*** 6734,6750 **** + + #if defined(FEAT_PYTHON) || defined(FEAT_PYTHON3) || defined(PROTO) + int +! get_win_number(win_T *wp) + { + int i = 1; + win_T *w; + +! for (w = firstwin; w != NULL && w != wp; w = W_NEXT(w)) + ++i; + + if (w == NULL) + return 0; + else + return i; + } + #endif +--- 6743,6774 ---- + + #if defined(FEAT_PYTHON) || defined(FEAT_PYTHON3) || defined(PROTO) + int +! get_win_number(win_T *wp, win_T *first_win) + { + int i = 1; + win_T *w; + +! for (w = first_win; w != NULL && w != wp; w = W_NEXT(w)) + ++i; + + if (w == NULL) + return 0; + else + return i; ++ } ++ ++ int ++ get_tab_number(tabpage_T *tp) ++ { ++ int i = 1; ++ tabpage_T *t; ++ ++ for (t = first_tabpage; t != NULL && t != tp; t = t->tp_next) ++ ++i; ++ ++ if (t == NULL) ++ return 0; ++ else ++ return i; + } + #endif +*** ../vim-7.3.948/src/version.c 2013-05-15 14:51:31.000000000 +0200 +--- src/version.c 2013-05-15 15:06:37.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 949, + /**/ + +-- +BLACK KNIGHT: Come on you pansy! + [hah] [parry thrust] + [ARTHUR chops the BLACK KNIGHT's right arm off] +ARTHUR: Victory is mine! [kneeling] + We thank thee Lord, that in thy merc- + [Black Knight kicks Arthur in the head while he is praying] + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 62864f5bd718865d28a5700f2b5adafce1f8aa85 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:29 +0200 Subject: [PATCH 0849/3340] - patchlevel 950 --- 7.3.950 | 185 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 185 insertions(+) create mode 100644 7.3.950 diff --git a/7.3.950 b/7.3.950 new file mode 100644 index 00000000..66a0332d --- /dev/null +++ b/7.3.950 @@ -0,0 +1,185 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.950 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.950 +Problem: Python: Stack trace printer can't handle messages. +Solution: Make KeyErrors use PyErr_SetObject. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c + + +*** ../vim-7.3.949/src/if_py_both.h 2013-05-15 15:12:25.000000000 +0200 +--- src/if_py_both.h 2013-05-15 15:16:23.000000000 +0200 +*************** +*** 734,740 **** + + if (di == NULL) + { +! PyErr_SetString(PyExc_KeyError, _("no such key in dictionary")); + return NULL; + } + +--- 734,740 ---- + + if (di == NULL) + { +! PyErr_SetObject(PyExc_KeyError, keyObject); + return NULL; + } + +*************** +*** 767,773 **** + if (di == NULL) + { + DICTKEY_UNREF +! PyErr_SetString(PyExc_IndexError, _("no such key in dictionary")); + return -1; + } + hi = hash_find(&d->dv_hashtab, di->di_key); +--- 767,773 ---- + if (di == NULL) + { + DICTKEY_UNREF +! PyErr_SetObject(PyExc_KeyError, keyObject); + return -1; + } + hi = hash_find(&d->dv_hashtab, di->di_key); +*************** +*** 1353,1359 **** + + if (flags == 0) + { +! PyErr_SetString(PyExc_KeyError, "Option does not exist in given scope"); + return NULL; + } + +--- 1353,1359 ---- + + if (flags == 0) + { +! PyErr_SetObject(PyExc_KeyError, keyObject); + return NULL; + } + +*************** +*** 1447,1453 **** + + if (flags == 0) + { +! PyErr_SetString(PyExc_KeyError, "Option does not exist in given scope"); + return -1; + } + +--- 1447,1453 ---- + + if (flags == 0) + { +! PyErr_SetObject(PyExc_KeyError, keyObject); + return -1; + } + +*************** +*** 3145,3151 **** + return BufferNew(b); + else + { +! PyErr_SetString(PyExc_KeyError, _("no such buffer")); + return NULL; + } + } +--- 3145,3151 ---- + return BufferNew(b); + else + { +! PyErr_SetObject(PyExc_KeyError, keyObject); + return NULL; + } + } +*** ../vim-7.3.949/src/if_python3.c 2013-05-15 15:12:25.000000000 +0200 +--- src/if_python3.c 2013-05-15 15:16:23.000000000 +0200 +*************** +*** 128,133 **** +--- 128,134 ---- + # define PyErr_Occurred py3_PyErr_Occurred + # define PyErr_SetNone py3_PyErr_SetNone + # define PyErr_SetString py3_PyErr_SetString ++ # define PyErr_SetObject py3_PyErr_SetObject + # define PyEval_InitThreads py3_PyEval_InitThreads + # define PyEval_RestoreThread py3_PyEval_RestoreThread + # define PyEval_SaveThread py3_PyEval_SaveThread +*************** +*** 250,255 **** +--- 251,257 ---- + static PyObject* (*py3_PyErr_NoMemory)(void); + static void (*py3_Py_Finalize)(void); + static void (*py3_PyErr_SetString)(PyObject *, const char *); ++ static void (*py3_PyErr_SetObject)(PyObject *, PyObject *); + static int (*py3_PyRun_SimpleString)(char *); + static PyObject* (*py3_PyRun_String)(char *, int, PyObject *, PyObject *); + static PyObject* (*py3_PyList_GetItem)(PyObject *, Py_ssize_t); +*************** +*** 379,384 **** +--- 381,387 ---- + {"PyErr_NoMemory", (PYTHON_PROC*)&py3_PyErr_NoMemory}, + {"Py_Finalize", (PYTHON_PROC*)&py3_Py_Finalize}, + {"PyErr_SetString", (PYTHON_PROC*)&py3_PyErr_SetString}, ++ {"PyErr_SetObject", (PYTHON_PROC*)&py3_PyErr_SetObject}, + {"PyRun_SimpleString", (PYTHON_PROC*)&py3_PyRun_SimpleString}, + {"PyRun_String", (PYTHON_PROC*)&py3_PyRun_String}, + {"PyList_GetItem", (PYTHON_PROC*)&py3_PyList_GetItem}, +*** ../vim-7.3.949/src/if_python.c 2013-05-15 15:12:25.000000000 +0200 +--- src/if_python.c 2013-05-15 15:16:23.000000000 +0200 +*************** +*** 155,160 **** +--- 155,161 ---- + # define PyErr_Occurred dll_PyErr_Occurred + # define PyErr_SetNone dll_PyErr_SetNone + # define PyErr_SetString dll_PyErr_SetString ++ # define PyErr_SetObject dll_PyErr_SetObject + # define PyEval_InitThreads dll_PyEval_InitThreads + # define PyEval_RestoreThread dll_PyEval_RestoreThread + # define PyEval_SaveThread dll_PyEval_SaveThread +*************** +*** 260,265 **** +--- 261,267 ---- + static PyObject*(*dll_PyErr_Occurred)(void); + static void(*dll_PyErr_SetNone)(PyObject *); + static void(*dll_PyErr_SetString)(PyObject *, const char *); ++ static void(*dll_PyErr_SetObject)(PyObject *, PyObject *); + static void(*dll_PyEval_InitThreads)(void); + static void(*dll_PyEval_RestoreThread)(PyThreadState *); + static PyThreadState*(*dll_PyEval_SaveThread)(void); +*************** +*** 393,398 **** +--- 395,401 ---- + {"PyErr_Occurred", (PYTHON_PROC*)&dll_PyErr_Occurred}, + {"PyErr_SetNone", (PYTHON_PROC*)&dll_PyErr_SetNone}, + {"PyErr_SetString", (PYTHON_PROC*)&dll_PyErr_SetString}, ++ {"PyErr_SetObject", (PYTHON_PROC*)&dll_PyErr_SetObject}, + {"PyEval_InitThreads", (PYTHON_PROC*)&dll_PyEval_InitThreads}, + {"PyEval_RestoreThread", (PYTHON_PROC*)&dll_PyEval_RestoreThread}, + {"PyEval_SaveThread", (PYTHON_PROC*)&dll_PyEval_SaveThread}, +*** ../vim-7.3.949/src/version.c 2013-05-15 15:12:25.000000000 +0200 +--- src/version.c 2013-05-15 15:17:56.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 950, + /**/ + +-- +-rwxr-xr-x 1 root 24 Oct 29 1929 /bin/ed +-rwxr-xr-t 4 root 131720 Jan 1 1970 /usr/ucb/vi +-rwxr-xr-x 1 root 5.89824e37 Oct 22 1990 /usr/bin/emacs + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ec7af47e36a4cf93a06ca1d589f9f6fbb7d49344 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:29 +0200 Subject: [PATCH 0850/3340] - patchlevel 951 --- 7.3.951 | 666 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 666 insertions(+) create mode 100644 7.3.951 diff --git a/7.3.951 b/7.3.951 new file mode 100644 index 00000000..7f1518cb --- /dev/null +++ b/7.3.951 @@ -0,0 +1,666 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.951 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.951 +Problem: Python exceptions have problems. +Solution: Change some IndexErrors to TypeErrors. Make “line number out of + range†an IndexError. Make “unable to get option value†a + RuntimeError. Make all PyErr_SetString messages start with + lowercase letter and use _(). (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c, + src/testdir/test86.ok, src/testdir/test87.ok + + +*** ../vim-7.3.950/src/if_py_both.h 2013-05-15 15:35:05.000000000 +0200 +--- src/if_py_both.h 2013-05-15 15:38:57.000000000 +0200 +*************** +*** 71,77 **** + { + if (val == NULL) + { +! PyErr_SetString(PyExc_AttributeError, _("can't delete OutputObject attributes")); + return -1; + } + +--- 71,78 ---- + { + if (val == NULL) + { +! PyErr_SetString(PyExc_AttributeError, +! _("can't delete OutputObject attributes")); + return -1; + } + +*************** +*** 919,925 **** + + if (index>=ListLength(self)) + { +! PyErr_SetString(PyExc_IndexError, "list index out of range"); + return NULL; + } + li = list_find(((ListObject *) (self))->list, (long) index); +--- 920,926 ---- + + if (index>=ListLength(self)) + { +! PyErr_SetString(PyExc_IndexError, _("list index out of range")); + return NULL; + } + li = list_find(((ListObject *) (self))->list, (long) index); +*************** +*** 1047,1053 **** + } + if (index>length || (index==length && obj==NULL)) + { +! PyErr_SetString(PyExc_IndexError, "list index out of range"); + return -1; + } + +--- 1048,1054 ---- + } + if (index>length || (index==length && obj==NULL)) + { +! PyErr_SetString(PyExc_IndexError, _("list index out of range")); + return -1; + } + +*************** +*** 1186,1192 **** + + if (val == NULL) + { +! PyErr_SetString(PyExc_AttributeError, _("Cannot delete DictionaryObject attributes")); + return -1; + } + +--- 1187,1194 ---- + + if (val == NULL) + { +! PyErr_SetString(PyExc_AttributeError, +! _("cannot delete vim.dictionary attributes")); + return -1; + } + +*************** +*** 1194,1200 **** + { + if (this->list->lv_lock == VAR_FIXED) + { +! PyErr_SetString(PyExc_TypeError, _("Cannot modify fixed list")); + return -1; + } + else +--- 1196,1202 ---- + { + if (this->list->lv_lock == VAR_FIXED) + { +! PyErr_SetString(PyExc_TypeError, _("cannot modify fixed list")); + return -1; + } + else +*************** +*** 1208,1214 **** + } + else + { +! PyErr_SetString(PyExc_AttributeError, _("Cannot set this attribute")); + return -1; + } + } +--- 1210,1216 ---- + } + else + { +! PyErr_SetString(PyExc_AttributeError, _("cannot set this attribute")); + return -1; + } + } +*************** +*** 1377,1383 **** + return PyBytes_FromString((char *) stringval); + else + { +! PyErr_SetString(PyExc_ValueError, "Unable to get option value"); + return NULL; + } + } +--- 1379,1386 ---- + return PyBytes_FromString((char *) stringval); + else + { +! PyErr_SetString(PyExc_RuntimeError, +! _("unable to get option value")); + return NULL; + } + } +*************** +*** 1455,1467 **** + { + if (this->opt_type == SREQ_GLOBAL) + { +! PyErr_SetString(PyExc_ValueError, "Unable to unset global option"); + return -1; + } + else if (!(flags & SOPT_GLOBAL)) + { +! PyErr_SetString(PyExc_ValueError, "Unable to unset option without " +! "global value"); + return -1; + } + else +--- 1458,1471 ---- + { + if (this->opt_type == SREQ_GLOBAL) + { +! PyErr_SetString(PyExc_ValueError, +! _("unable to unset global option")); + return -1; + } + else if (!(flags & SOPT_GLOBAL)) + { +! PyErr_SetString(PyExc_ValueError, _("unable to unset option " +! "without global value")); + return -1; + } + else +*************** +*** 1491,1497 **** + val = PyLong_AsLong(valObject); + else + { +! PyErr_SetString(PyExc_ValueError, "Object must be integer"); + return -1; + } + +--- 1495,1501 ---- + val = PyLong_AsLong(valObject); + else + { +! PyErr_SetString(PyExc_TypeError, _("object must be integer")); + return -1; + } + +*************** +*** 1529,1535 **** + } + else + { +! PyErr_SetString(PyExc_ValueError, "Object must be string"); + return -1; + } + +--- 1533,1539 ---- + } + else + { +! PyErr_SetString(PyExc_TypeError, _("object must be string")); + return -1; + } + +*************** +*** 2766,2772 **** + + if (n < 0 || n > max) + { +! PyErr_SetString(PyExc_ValueError, _("line number out of range")); + return NULL; + } + +--- 2770,2776 ---- + + if (n < 0 || n > max) + { +! PyErr_SetString(PyExc_IndexError, _("line number out of range")); + return NULL; + } + +*************** +*** 3135,3141 **** + bnr = PyLong_AsLong(keyObject); + else + { +! PyErr_SetString(PyExc_ValueError, _("key must be integer")); + return NULL; + } + +--- 3139,3145 ---- + bnr = PyLong_AsLong(keyObject); + else + { +! PyErr_SetString(PyExc_TypeError, _("key must be integer")); + return NULL; + } + +*************** +*** 3654,3660 **** + return convert_dl(obj, tv, pymap_to_tv, lookupDict); + else + { +! PyErr_SetString(PyExc_TypeError, _("unable to convert to vim structure")); + return -1; + } + return 0; +--- 3658,3665 ---- + return convert_dl(obj, tv, pymap_to_tv, lookupDict); + else + { +! PyErr_SetString(PyExc_TypeError, +! _("unable to convert to vim structure")); + return -1; + } + return 0; +*** ../vim-7.3.950/src/if_python3.c 2013-05-15 15:35:05.000000000 +0200 +--- src/if_python3.c 2013-05-15 15:38:57.000000000 +0200 +*************** +*** 336,341 **** +--- 336,342 ---- + static PyObject *p3imp_PyExc_KeyboardInterrupt; + static PyObject *p3imp_PyExc_TypeError; + static PyObject *p3imp_PyExc_ValueError; ++ static PyObject *p3imp_PyExc_RuntimeError; + + # define PyExc_AttributeError p3imp_PyExc_AttributeError + # define PyExc_IndexError p3imp_PyExc_IndexError +*************** +*** 343,348 **** +--- 344,350 ---- + # define PyExc_KeyboardInterrupt p3imp_PyExc_KeyboardInterrupt + # define PyExc_TypeError p3imp_PyExc_TypeError + # define PyExc_ValueError p3imp_PyExc_ValueError ++ # define PyExc_RuntimeError p3imp_PyExc_RuntimeError + + /* + * Table of name to function pointer of python. +*************** +*** 580,591 **** +--- 582,595 ---- + p3imp_PyExc_KeyboardInterrupt = PyDict_GetItemString(exdict, "KeyboardInterrupt"); + p3imp_PyExc_TypeError = PyDict_GetItemString(exdict, "TypeError"); + p3imp_PyExc_ValueError = PyDict_GetItemString(exdict, "ValueError"); ++ p3imp_PyExc_RuntimeError = PyDict_GetItemString(exdict, "RuntimeError"); + Py_XINCREF(p3imp_PyExc_AttributeError); + Py_XINCREF(p3imp_PyExc_IndexError); + Py_XINCREF(p3imp_PyExc_KeyError); + Py_XINCREF(p3imp_PyExc_KeyboardInterrupt); + Py_XINCREF(p3imp_PyExc_TypeError); + Py_XINCREF(p3imp_PyExc_ValueError); ++ Py_XINCREF(p3imp_PyExc_RuntimeError); + Py_XDECREF(exmod); + } + #endif /* DYNAMIC_PYTHON3 */ +*************** +*** 1132,1138 **** + } + else + { +! PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return NULL; + } + } +--- 1136,1142 ---- + } + else + { +! PyErr_SetString(PyExc_TypeError, _("index must be int or slice")); + return NULL; + } + } +*************** +*** 1166,1172 **** + } + else + { +! PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return -1; + } + } +--- 1170,1176 ---- + } + else + { +! PyErr_SetString(PyExc_TypeError, _("index must be int or slice")); + return -1; + } + } +*************** +*** 1248,1254 **** + } + else + { +! PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return NULL; + } + } +--- 1252,1258 ---- + } + else + { +! PyErr_SetString(PyExc_TypeError, _("index must be int or slice")); + return NULL; + } + } +*************** +*** 1275,1281 **** + } + else + { +! PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return -1; + } + } +--- 1279,1285 ---- + } + else + { +! PyErr_SetString(PyExc_TypeError, _("index must be int or slice")); + return -1; + } + } +*************** +*** 1450,1456 **** + } + else + { +! PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return NULL; + } + } +--- 1454,1460 ---- + } + else + { +! PyErr_SetString(PyExc_TypeError, _("index must be int or slice")); + return NULL; + } + } +*************** +*** 1474,1480 **** + } + else + { +! PyErr_SetString(PyExc_IndexError, "Index must be int or slice"); + return -1; + } + } +--- 1478,1484 ---- + } + else + { +! PyErr_SetString(PyExc_TypeError, _("index must be int or slice")); + return -1; + } + } +*** ../vim-7.3.950/src/if_python.c 2013-05-15 15:35:05.000000000 +0200 +--- src/if_python.c 2013-05-15 15:38:57.000000000 +0200 +*************** +*** 358,363 **** +--- 358,364 ---- + static PyObject *imp_PyExc_KeyboardInterrupt; + static PyObject *imp_PyExc_TypeError; + static PyObject *imp_PyExc_ValueError; ++ static PyObject *imp_PyExc_RuntimeError; + + # define PyExc_AttributeError imp_PyExc_AttributeError + # define PyExc_IndexError imp_PyExc_IndexError +*************** +*** 365,370 **** +--- 366,372 ---- + # define PyExc_KeyboardInterrupt imp_PyExc_KeyboardInterrupt + # define PyExc_TypeError imp_PyExc_TypeError + # define PyExc_ValueError imp_PyExc_ValueError ++ # define PyExc_RuntimeError imp_PyExc_RuntimeError + + /* + * Table of name to function pointer of python. +*************** +*** 593,604 **** +--- 595,608 ---- + imp_PyExc_KeyboardInterrupt = PyDict_GetItemString(exdict, "KeyboardInterrupt"); + imp_PyExc_TypeError = PyDict_GetItemString(exdict, "TypeError"); + imp_PyExc_ValueError = PyDict_GetItemString(exdict, "ValueError"); ++ imp_PyExc_RuntimeError = PyDict_GetItemString(exdict, "RuntimeError"); + Py_XINCREF(imp_PyExc_AttributeError); + Py_XINCREF(imp_PyExc_IndexError); + Py_XINCREF(imp_PyExc_KeyError); + Py_XINCREF(imp_PyExc_KeyboardInterrupt); + Py_XINCREF(imp_PyExc_TypeError); + Py_XINCREF(imp_PyExc_ValueError); ++ Py_XINCREF(imp_PyExc_RuntimeError); + Py_XDECREF(exmod); + } + #endif /* DYNAMIC_PYTHON */ +*** ../vim-7.3.950/src/testdir/test86.ok 2013-05-15 14:51:31.000000000 +0200 +--- src/testdir/test86.ok 2013-05-15 15:38:57.000000000 +0200 +*************** +*** 102,108 **** + B: 1:1 2:1 3:1 4:1 + >>> previewheight + p/gopts1: 12 +! inv: 'a'! ValueError + p/wopts1! KeyError + inv: 'a'! KeyError + wopts1! KeyError +--- 102,108 ---- + B: 1:1 2:1 3:1 4:1 + >>> previewheight + p/gopts1: 12 +! inv: 'a'! TypeError + p/wopts1! KeyError + inv: 'a'! KeyError + wopts1! KeyError +*************** +*** 123,129 **** + B: 1:5 2:5 3:5 4:5 + >>> operatorfunc + p/gopts1: '' +! inv: 2! ValueError + p/wopts1! KeyError + inv: 2! KeyError + wopts1! KeyError +--- 123,129 ---- + B: 1:5 2:5 3:5 4:5 + >>> operatorfunc + p/gopts1: '' +! inv: 2! TypeError + p/wopts1! KeyError + inv: 2! KeyError + wopts1! KeyError +*************** +*** 198,206 **** + B: 1:'+2' 2:'+3' 3:'+1' 4:'' + >>> statusline + p/gopts1: '' +! inv: 0! ValueError + p/wopts1: None +! inv: 0! ValueError + p/bopts1! KeyError + inv: 0! KeyError + bopts1! KeyError +--- 198,206 ---- + B: 1:'+2' 2:'+3' 3:'+1' 4:'' + >>> statusline + p/gopts1: '' +! inv: 0! TypeError + p/wopts1: None +! inv: 0! TypeError + p/bopts1! KeyError + inv: 0! KeyError + bopts1! KeyError +*************** +*** 259,265 **** + wopts2! KeyError + wopts3! KeyError + p/bopts1: '' +! inv: 1! ValueError + G: '' + W: 1:'A' 2:'B' 3:'' 4:'C' + B: 1:'A' 2:'B' 3:'' 4:'C' +--- 259,265 ---- + wopts2! KeyError + wopts3! KeyError + p/bopts1: '' +! inv: 1! TypeError + G: '' + W: 1:'A' 2:'B' 3:'' 4:'C' + B: 1:'A' 2:'B' 3:'' 4:'C' +*************** +*** 288,301 **** + B: 1:0 2:1 3:0 4:1 + >>> path + p/gopts1: '.,/usr/include,,' +! inv: 0! ValueError + p/wopts1! KeyError + inv: 0! KeyError + wopts1! KeyError + wopts2! KeyError + wopts3! KeyError + p/bopts1: None +! inv: 0! ValueError + G: '.,,' + W: 1:'.,,' 2:',,' 3:'.,,' 4:'.' + B: 1:'.,,' 2:',,' 3:'.,,' 4:'.' +--- 288,301 ---- + B: 1:0 2:1 3:0 4:1 + >>> path + p/gopts1: '.,/usr/include,,' +! inv: 0! TypeError + p/wopts1! KeyError + inv: 0! KeyError + wopts1! KeyError + wopts2! KeyError + wopts3! KeyError + p/bopts1: None +! inv: 0! TypeError + G: '.,,' + W: 1:'.,,' 2:',,' 3:'.,,' 4:'.' + B: 1:'.,,' 2:',,' 3:'.,,' 4:'.' +*** ../vim-7.3.950/src/testdir/test87.ok 2013-05-15 14:51:31.000000000 +0200 +--- src/testdir/test87.ok 2013-05-15 15:38:57.000000000 +0200 +*************** +*** 91,97 **** + B: 1:1 2:1 3:1 4:1 + >>> previewheight + p/gopts1: 12 +! inv: 'a'! ValueError + p/wopts1! KeyError + inv: 'a'! KeyError + wopts1! KeyError +--- 91,97 ---- + B: 1:1 2:1 3:1 4:1 + >>> previewheight + p/gopts1: 12 +! inv: 'a'! TypeError + p/wopts1! KeyError + inv: 'a'! KeyError + wopts1! KeyError +*************** +*** 112,118 **** + B: 1:5 2:5 3:5 4:5 + >>> operatorfunc + p/gopts1: b'' +! inv: 2! ValueError + p/wopts1! KeyError + inv: 2! KeyError + wopts1! KeyError +--- 112,118 ---- + B: 1:5 2:5 3:5 4:5 + >>> operatorfunc + p/gopts1: b'' +! inv: 2! TypeError + p/wopts1! KeyError + inv: 2! KeyError + wopts1! KeyError +*************** +*** 187,195 **** + B: 1:'+2' 2:'+3' 3:'+1' 4:'' + >>> statusline + p/gopts1: b'' +! inv: 0! ValueError + p/wopts1: None +! inv: 0! ValueError + p/bopts1! KeyError + inv: 0! KeyError + bopts1! KeyError +--- 187,195 ---- + B: 1:'+2' 2:'+3' 3:'+1' 4:'' + >>> statusline + p/gopts1: b'' +! inv: 0! TypeError + p/wopts1: None +! inv: 0! TypeError + p/bopts1! KeyError + inv: 0! KeyError + bopts1! KeyError +*************** +*** 248,254 **** + wopts2! KeyError + wopts3! KeyError + p/bopts1: b'' +! inv: 1! ValueError + G: '' + W: 1:'A' 2:'B' 3:'' 4:'C' + B: 1:'A' 2:'B' 3:'' 4:'C' +--- 248,254 ---- + wopts2! KeyError + wopts3! KeyError + p/bopts1: b'' +! inv: 1! TypeError + G: '' + W: 1:'A' 2:'B' 3:'' 4:'C' + B: 1:'A' 2:'B' 3:'' 4:'C' +*************** +*** 277,290 **** + B: 1:0 2:1 3:0 4:1 + >>> path + p/gopts1: b'.,/usr/include,,' +! inv: 0! ValueError + p/wopts1! KeyError + inv: 0! KeyError + wopts1! KeyError + wopts2! KeyError + wopts3! KeyError + p/bopts1: None +! inv: 0! ValueError + G: '.,,' + W: 1:'.,,' 2:',,' 3:'.,,' 4:'.' + B: 1:'.,,' 2:',,' 3:'.,,' 4:'.' +--- 277,290 ---- + B: 1:0 2:1 3:0 4:1 + >>> path + p/gopts1: b'.,/usr/include,,' +! inv: 0! TypeError + p/wopts1! KeyError + inv: 0! KeyError + wopts1! KeyError + wopts2! KeyError + wopts3! KeyError + p/bopts1: None +! inv: 0! TypeError + G: '.,,' + W: 1:'.,,' 2:',,' 3:'.,,' 4:'.' + B: 1:'.,,' 2:',,' 3:'.,,' 4:'.' +*** ../vim-7.3.950/src/version.c 2013-05-15 15:35:05.000000000 +0200 +--- src/version.c 2013-05-15 15:38:34.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 951, + /**/ + +-- +5 out of 4 people have trouble with fractions. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fc5a6963fbe3445a53e5072a40e3e61dc8f375d5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:30 +0200 Subject: [PATCH 0851/3340] - patchlevel 952 --- 7.3.952 | 166 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 166 insertions(+) create mode 100644 7.3.952 diff --git a/7.3.952 b/7.3.952 new file mode 100644 index 00000000..297632f5 --- /dev/null +++ b/7.3.952 @@ -0,0 +1,166 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.952 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.952 +Problem: Python: It's not easy to change window/buffer/tabpage. +Solution: Add ability to assign to vim.current.{tabpage,buffer,window}. + (ZyX) +Files: runtime/doc/if_pyth.txt, src/if_py_both.h + + +*** ../vim-7.3.951/runtime/doc/if_pyth.txt 2013-05-15 15:12:25.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-05-15 15:48:39.000000000 +0200 +*************** +*** 242,250 **** + An object providing access (via specific attributes) to various + "current" objects available in vim: + vim.current.line The current line (RW) String +! vim.current.buffer The current buffer (RO) Buffer +! vim.current.window The current window (RO) Window +! vim.current.tabpage The current tab page (RO) TabPage + vim.current.range The current line range (RO) Range + + The last case deserves a little explanation. When the :python or +--- 242,250 ---- + An object providing access (via specific attributes) to various + "current" objects available in vim: + vim.current.line The current line (RW) String +! vim.current.buffer The current buffer (RW) Buffer +! vim.current.window The current window (RW) Window +! vim.current.tabpage The current tab page (RW) TabPage + vim.current.range The current line range (RO) Range + + The last case deserves a little explanation. When the :python or +*************** +*** 252,257 **** +--- 252,273 ---- + "current range". A range is a bit like a buffer, but with all access + restricted to a subset of lines. See |python-range| for more details. + ++ Note: When assigning to vim.current.{buffer,window,tabpage} it expects ++ valid |python-buffer|, |python-window| or |python-tabpage| objects ++ respectively. Assigning triggers normal (with |autocommand|s) ++ switching to given buffer, window or tab page. It is the only way to ++ switch UI objects in python: you can't assign to ++ |python-tabpage|.window attribute. To switch without triggering ++ autocommands use > ++ py << EOF ++ saved_eventignore = vim.options['eventignore'] ++ vim.options['eventignore'] = 'all' ++ try: ++ vim.current.buffer = vim.buffers[2] # Switch to buffer 2 ++ finally: ++ vim.options['eventignore'] = saved_eventignore ++ EOF ++ < + vim.vars *python-vars* + vim.vvars *python-vvars* + Dictionary-like objects holding dictionaries with global (|g:|) and +*** ../vim-7.3.951/src/if_py_both.h 2013-05-15 15:44:24.000000000 +0200 +--- src/if_py_both.h 2013-05-15 15:48:39.000000000 +0200 +*************** +*** 3244,3249 **** +--- 3244,3323 ---- + + return 0; + } ++ else if (strcmp(name, "buffer") == 0) ++ { ++ int count; ++ ++ if (value->ob_type != &BufferType) ++ { ++ PyErr_SetString(PyExc_TypeError, _("expected vim.buffer object")); ++ return -1; ++ } ++ ++ if (CheckBuffer((BufferObject *)(value))) ++ return -1; ++ count = ((BufferObject *)(value))->buf->b_fnum; ++ ++ if (do_buffer(DOBUF_GOTO, DOBUF_FIRST, FORWARD, count, 0) == FAIL) ++ { ++ PyErr_SetVim(_("failed to switch to given buffer")); ++ return -1; ++ } ++ ++ return 0; ++ } ++ else if (strcmp(name, "window") == 0) ++ { ++ int count; ++ ++ if (value->ob_type != &WindowType) ++ { ++ PyErr_SetString(PyExc_TypeError, _("expected vim.window object")); ++ return -1; ++ } ++ ++ if (CheckWindow((WindowObject *)(value))) ++ return -1; ++ count = get_win_number(((WindowObject *)(value))->win, firstwin); ++ ++ if (!count) ++ { ++ PyErr_SetString(PyExc_ValueError, ++ _("failed to find window in the current tab page")); ++ return -1; ++ } ++ ++ win_goto(((WindowObject *)(value))->win); ++ if (((WindowObject *)(value))->win != curwin) ++ { ++ PyErr_SetString(PyExc_RuntimeError, ++ _("did not switch to the specified window")); ++ return -1; ++ } ++ ++ return 0; ++ } ++ else if (strcmp(name, "tabpage") == 0) ++ { ++ if (value->ob_type != &TabPageType) ++ { ++ PyErr_SetString(PyExc_TypeError, _("expected vim.tabpage object")); ++ return -1; ++ } ++ ++ if (CheckTabPage((TabPageObject *)(value))) ++ return -1; ++ ++ goto_tabpage_tp(((TabPageObject *)(value))->tab, TRUE, TRUE); ++ if (((TabPageObject *)(value))->tab != curtab) ++ { ++ PyErr_SetString(PyExc_RuntimeError, ++ _("did not switch to the specified tab page")); ++ return -1; ++ } ++ ++ return 0; ++ } + else + { + PyErr_SetString(PyExc_AttributeError, name); +*** ../vim-7.3.951/src/version.c 2013-05-15 15:44:24.000000000 +0200 +--- src/version.c 2013-05-15 15:49:12.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 952, + /**/ + +-- +Trees moving back and forth is what makes the wind blow. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 18a3aaabd0e7e82b0770caa14dc5ee6c0896d7bc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:31 +0200 Subject: [PATCH 0852/3340] - patchlevel 953 --- 7.3.953 | 103 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 103 insertions(+) create mode 100644 7.3.953 diff --git a/7.3.953 b/7.3.953 new file mode 100644 index 00000000..9eb70bdd --- /dev/null +++ b/7.3.953 @@ -0,0 +1,103 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.953 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.953 +Problem: Python: string exceptions are deprecated. +Solution: Make vim.error an Exception subclass. (ZyX) +Files: src/if_python.c, src/if_python3.c + + +*** ../vim-7.3.952/src/if_python.c 2013-05-15 15:44:24.000000000 +0200 +--- src/if_python.c 2013-05-15 16:02:20.000000000 +0200 +*************** +*** 149,154 **** +--- 149,155 ---- + # define PyMem_Malloc dll_PyMem_Malloc + # define PyDict_SetItemString dll_PyDict_SetItemString + # define PyErr_BadArgument dll_PyErr_BadArgument ++ # define PyErr_NewException dll_PyErr_NewException + # define PyErr_Clear dll_PyErr_Clear + # define PyErr_PrintEx dll_PyErr_PrintEx + # define PyErr_NoMemory dll_PyErr_NoMemory +*************** +*** 255,260 **** +--- 256,262 ---- + static void* (*dll_PyMem_Malloc)(size_t); + static int(*dll_PyDict_SetItemString)(PyObject *dp, char *key, PyObject *item); + static int(*dll_PyErr_BadArgument)(void); ++ static PyObject *(*dll_PyErr_NewException)(char *, PyObject *, PyObject *); + static void(*dll_PyErr_Clear)(void); + static void(*dll_PyErr_PrintEx)(int); + static PyObject*(*dll_PyErr_NoMemory)(void); +*************** +*** 391,396 **** +--- 393,399 ---- + {"PyMem_Malloc", (PYTHON_PROC*)&dll_PyMem_Malloc}, + {"PyDict_SetItemString", (PYTHON_PROC*)&dll_PyDict_SetItemString}, + {"PyErr_BadArgument", (PYTHON_PROC*)&dll_PyErr_BadArgument}, ++ {"PyErr_NewException", (PYTHON_PROC*)&dll_PyErr_NewException}, + {"PyErr_Clear", (PYTHON_PROC*)&dll_PyErr_Clear}, + {"PyErr_PrintEx", (PYTHON_PROC*)&dll_PyErr_PrintEx}, + {"PyErr_NoMemory", (PYTHON_PROC*)&dll_PyErr_NoMemory}, +*************** +*** 1304,1310 **** + mod = Py_InitModule4("vim", VimMethods, (char *)NULL, (PyObject *)NULL, PYTHON_API_VERSION); + dict = PyModule_GetDict(mod); + +! VimError = Py_BuildValue("s", "vim.error"); + + PyDict_SetItemString(dict, "error", VimError); + PyDict_SetItemString(dict, "buffers", (PyObject *)(void *)&TheBufferMap); +--- 1307,1313 ---- + mod = Py_InitModule4("vim", VimMethods, (char *)NULL, (PyObject *)NULL, PYTHON_API_VERSION); + dict = PyModule_GetDict(mod); + +! VimError = PyErr_NewException("vim.error", NULL, NULL); + + PyDict_SetItemString(dict, "error", VimError); + PyDict_SetItemString(dict, "buffers", (PyObject *)(void *)&TheBufferMap); +*** ../vim-7.3.952/src/if_python3.c 2013-05-15 15:44:24.000000000 +0200 +--- src/if_python3.c 2013-05-15 16:02:20.000000000 +0200 +*************** +*** 1606,1613 **** + return NULL; + + VimError = PyErr_NewException("vim.error", NULL, NULL); +- Py_INCREF(VimError); + + PyModule_AddObject(mod, "error", VimError); + Py_INCREF((PyObject *)(void *)&TheBufferMap); + PyModule_AddObject(mod, "buffers", (PyObject *)(void *)&TheBufferMap); +--- 1606,1613 ---- + return NULL; + + VimError = PyErr_NewException("vim.error", NULL, NULL); + ++ Py_INCREF(VimError); + PyModule_AddObject(mod, "error", VimError); + Py_INCREF((PyObject *)(void *)&TheBufferMap); + PyModule_AddObject(mod, "buffers", (PyObject *)(void *)&TheBufferMap); +*** ../vim-7.3.952/src/version.c 2013-05-15 15:51:03.000000000 +0200 +--- src/version.c 2013-05-15 16:02:43.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 953, + /**/ + +-- +The early bird gets the worm. If you want something else for +breakfast, get up later. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 22ccd561dd6c2a1f5da900fe88216733b1f007cd Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:32 +0200 Subject: [PATCH 0853/3340] - patchlevel 954 --- 7.3.954 | 94 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 94 insertions(+) create mode 100644 7.3.954 diff --git a/7.3.954 b/7.3.954 new file mode 100644 index 00000000..4e37875f --- /dev/null +++ b/7.3.954 @@ -0,0 +1,94 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.954 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.954 +Problem: No check if PyObject_IsTrue fails. +Solution: Add a check for -1 value. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.953/src/if_py_both.h 2013-05-15 15:51:03.000000000 +0200 +--- src/if_py_both.h 2013-05-15 16:08:53.000000000 +0200 +*************** +*** 700,706 **** + } + else + { +! if (PyObject_IsTrue(val)) + this->dict->dv_lock = VAR_LOCKED; + else + this->dict->dv_lock = 0; +--- 700,709 ---- + } + else + { +! int istrue = PyObject_IsTrue(val); +! if (istrue == -1) +! return -1; +! else if (istrue) + this->dict->dv_lock = VAR_LOCKED; + else + this->dict->dv_lock = 0; +*************** +*** 1201,1207 **** + } + else + { +! if (PyObject_IsTrue(val)) + this->list->lv_lock = VAR_LOCKED; + else + this->list->lv_lock = 0; +--- 1204,1213 ---- + } + else + { +! int istrue = PyObject_IsTrue(val); +! if (istrue == -1) +! return -1; +! else if (istrue) + this->list->lv_lock = VAR_LOCKED; + else + this->list->lv_lock = 0; +*************** +*** 1479,1485 **** + + if (flags & SOPT_BOOL) + { +! r = set_option_value_for(key, PyObject_IsTrue(valObject), NULL, + opt_flags, this->opt_type, this->from); + } + else if (flags & SOPT_NUM) +--- 1485,1494 ---- + + if (flags & SOPT_BOOL) + { +! int istrue = PyObject_IsTrue(valObject); +! if (istrue == -1) +! return -1; +! r = set_option_value_for(key, istrue, NULL, + opt_flags, this->opt_type, this->from); + } + else if (flags & SOPT_NUM) +*** ../vim-7.3.953/src/version.c 2013-05-15 16:04:34.000000000 +0200 +--- src/version.c 2013-05-15 16:08:26.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 954, + /**/ + +-- +The early bird gets the worm. The second mouse gets the cheese. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a96f4f3a3a763198a479e77a0c9ce1d567c2e335 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:33 +0200 Subject: [PATCH 0854/3340] - patchlevel 955 --- 7.3.955 | 339 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 339 insertions(+) create mode 100644 7.3.955 diff --git a/7.3.955 b/7.3.955 new file mode 100644 index 00000000..cccf4628 --- /dev/null +++ b/7.3.955 @@ -0,0 +1,339 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.955 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.955 +Problem: Python: Not enough tests. +Solution: Add tests for vim.{current,window*,tabpage*}. (ZyX) +Files: src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.954/src/testdir/test86.in 2013-05-15 14:51:31.000000000 +0200 +--- src/testdir/test86.in 2013-05-15 16:15:25.000000000 +0200 +*************** +*** 334,339 **** +--- 334,340 ---- + :let g:foo = 'bac' + :let w:abc = 'def' + :let b:baz = 'bar' ++ :let t:bar = 'jkl' + :try + : throw "Abc" + :catch +*************** +*** 342,347 **** +--- 343,349 ---- + :put =pyeval('vim.vars[''foo'']') + :put =pyeval('vim.current.window.vars[''abc'']') + :put =pyeval('vim.current.buffer.vars[''baz'']') ++ :put =pyeval('vim.current.tabpage.vars[''bar'']') + :" + :" Options + :" paste: boolean, global +*************** +*** 561,566 **** +--- 563,640 ---- + except StopIteration: + cb.append('StopIteration') + EOF ++ :" ++ :" Test vim.{tabpage,window}list and vim.{tabpage,window} objects ++ :tabnew 0 ++ :tabnew 1 ++ :vnew a.1 ++ :tabnew 2 ++ :vnew a.2 ++ :vnew b.2 ++ :vnew c.2 ++ py << EOF ++ cb.append('Number of tabs: ' + str(len(vim.tabpages))) ++ cb.append('Current tab pages:') ++ def W(w): ++ if '(unknown)' in repr(w): ++ return '' ++ else: ++ return repr(w) ++ for t in vim.tabpages: ++ cb.append(' ' + repr(t) + '(' + str(t.number) + ')' + ': ' + str(len(t.windows)) + ' windows, current is ' + W(t.window)) ++ cb.append(' Windows:') ++ for w in t.windows: ++ cb.append(' ' + W(w) + '(' + str(w.number) + ')' + ': displays buffer ' + repr(w.buffer) + '; cursor is at ' + repr(w.cursor)) ++ # Other values depend on the size of the terminal, so they are checked partly: ++ for attr in ('height', 'row', 'width', 'col'): ++ try: ++ aval = getattr(w, attr) ++ if type(aval) is not long: ++ raise TypeError ++ if aval < 0: ++ raise ValueError ++ except Exception: ++ cb.append('!!!!!! Error while getting attribute ' + attr + ': ' + sys.exc_type.__name__) ++ w.cursor = (len(w.buffer), 0) ++ cb.append('Number of windows in current tab page: ' + str(len(vim.windows))) ++ if list(vim.windows) != list(vim.current.tabpage.windows): ++ cb.append('!!!!!! Windows differ') ++ EOF ++ :" ++ :" Test vim.current ++ py << EOF ++ def H(o): ++ return repr(o) ++ cb.append('Current tab page: ' + repr(vim.current.tabpage)) ++ cb.append('Current window: ' + repr(vim.current.window) + ': ' + H(vim.current.window) + ' is ' + H(vim.current.tabpage.window)) ++ cb.append('Current buffer: ' + repr(vim.current.buffer) + ': ' + H(vim.current.buffer) + ' is ' + H(vim.current.window.buffer)+ ' is ' + H(vim.current.tabpage.window.buffer)) ++ # Assigning: fails ++ try: ++ vim.current.window = vim.tabpages[0].window ++ except ValueError: ++ cb.append('ValueError at assigning foreign tab window') ++ ++ for attr in ('window', 'tabpage', 'buffer'): ++ try: ++ setattr(vim.current, attr, None) ++ except TypeError: ++ cb.append('Type error at assigning None to vim.current.' + attr) ++ ++ # Assigning: success ++ vim.current.tabpage = vim.tabpages[-2] ++ vim.current.buffer = cb ++ vim.current.window = vim.windows[0] ++ vim.current.window.cursor = (len(vim.current.buffer), 0) ++ cb.append('Current tab page: ' + repr(vim.current.tabpage)) ++ cb.append('Current window: ' + repr(vim.current.window)) ++ cb.append('Current buffer: ' + repr(vim.current.buffer)) ++ cb.append('Current line: ' + repr(vim.current.line)) ++ for b in vim.buffers: ++ if b is not cb: ++ vim.command('bwipeout! ' + b.number) ++ EOF ++ :tabonly! ++ :only! + :endfun + :" + :call Test() +*** ../vim-7.3.954/src/testdir/test86.ok 2013-05-15 15:44:24.000000000 +0200 +--- src/testdir/test86.ok 2013-05-15 16:22:06.000000000 +0200 +*************** +*** 80,85 **** +--- 80,86 ---- + bac + def + bar ++ jkl + >>> paste + p/gopts1: False + p/wopts1! KeyError +*************** +*** 328,330 **** +--- 329,361 ---- + i4: + i4: + StopIteration ++ Number of tabs: 4 ++ Current tab pages: ++ (1): 1 windows, current is ++ Windows: ++ (0): displays buffer ; cursor is at (954, 0) ++ (2): 1 windows, current is ++ Windows: ++ (0): displays buffer ; cursor is at (1, 0) ++ (3): 2 windows, current is ++ Windows: ++ (0): displays buffer ; cursor is at (1, 0) ++ (0): displays buffer ; cursor is at (1, 0) ++ (4): 4 windows, current is ++ Windows: ++ (1): displays buffer ; cursor is at (1, 0) ++ (2): displays buffer ; cursor is at (1, 0) ++ (3): displays buffer ; cursor is at (1, 0) ++ (4): displays buffer ; cursor is at (1, 0) ++ Number of windows in current tab page: 4 ++ Current tab page: ++ Current window: : is ++ Current buffer: : is is ++ ValueError at assigning foreign tab window ++ Type error at assigning None to vim.current.window ++ Type error at assigning None to vim.current.tabpage ++ Type error at assigning None to vim.current.buffer ++ Current tab page: ++ Current window: ++ Current buffer: ++ Current line: 'Type error at assigning None to vim.current.buffer' +*** ../vim-7.3.954/src/testdir/test87.in 2013-05-15 14:39:47.000000000 +0200 +--- src/testdir/test87.in 2013-05-15 16:15:25.000000000 +0200 +*************** +*** 320,325 **** +--- 320,326 ---- + :let g:foo = 'bac' + :let w:abc = 'def' + :let b:baz = 'bar' ++ :let t:bar = 'jkl' + :try + : throw "Abc" + :catch +*************** +*** 328,333 **** +--- 329,335 ---- + :put =py3eval('vim.vars[''foo'']') + :put =py3eval('vim.current.window.vars[''abc'']') + :put =py3eval('vim.current.buffer.vars[''baz'']') ++ :put =py3eval('vim.current.tabpage.vars[''bar'']') + :" + :" Options + :" paste: boolean, global +*************** +*** 547,552 **** +--- 549,626 ---- + except StopIteration: + cb.append('StopIteration') + EOF ++ :" ++ :" Test vim.{tabpage,window}list and vim.{tabpage,window} objects ++ :tabnew 0 ++ :tabnew 1 ++ :vnew a.1 ++ :tabnew 2 ++ :vnew a.2 ++ :vnew b.2 ++ :vnew c.2 ++ py3 << EOF ++ def W(w): ++ if '(unknown)' in repr(w): ++ return '' ++ else: ++ return repr(w) ++ cb.append('Number of tabs: ' + str(len(vim.tabpages))) ++ cb.append('Current tab pages:') ++ for t in vim.tabpages: ++ cb.append(' ' + repr(t) + '(' + str(t.number) + ')' + ': ' + str(len(t.windows)) + ' windows, current is ' + W(t.window)) ++ cb.append(' Windows:') ++ for w in t.windows: ++ cb.append(' ' + W(w) + '(' + str(w.number) + ')' + ': displays buffer ' + repr(w.buffer) + '; cursor is at ' + repr(w.cursor)) ++ # Other values depend on the size of the terminal, so they are checked partly: ++ for attr in ('height', 'row', 'width', 'col'): ++ try: ++ aval = getattr(w, attr) ++ if type(aval) is not int: ++ raise TypeError ++ if aval < 0: ++ raise ValueError ++ except Exception as e: ++ cb.append('!!!!!! Error while getting attribute ' + attr + ': ' + e.__class__.__name__) ++ w.cursor = (len(w.buffer), 0) ++ cb.append('Number of windows in current tab page: ' + str(len(vim.windows))) ++ if list(vim.windows) != list(vim.current.tabpage.windows): ++ cb.append('!!!!!! Windows differ') ++ EOF ++ :" ++ :" Test vim.current ++ py3 << EOF ++ def H(o): ++ return repr(o) ++ cb.append('Current tab page: ' + repr(vim.current.tabpage)) ++ cb.append('Current window: ' + repr(vim.current.window) + ': ' + H(vim.current.window) + ' is ' + H(vim.current.tabpage.window)) ++ cb.append('Current buffer: ' + repr(vim.current.buffer) + ': ' + H(vim.current.buffer) + ' is ' + H(vim.current.window.buffer)+ ' is ' + H(vim.current.tabpage.window.buffer)) ++ # Assigning: fails ++ try: ++ vim.current.window = vim.tabpages[0].window ++ except ValueError: ++ cb.append('ValueError at assigning foreign tab window') ++ ++ for attr in ('window', 'tabpage', 'buffer'): ++ try: ++ setattr(vim.current, attr, None) ++ except TypeError: ++ cb.append('Type error at assigning None to vim.current.' + attr) ++ ++ # Assigning: success ++ vim.current.tabpage = vim.tabpages[-2] ++ vim.current.buffer = cb ++ vim.current.window = vim.windows[0] ++ vim.current.window.cursor = (len(vim.current.buffer), 0) ++ cb.append('Current tab page: ' + repr(vim.current.tabpage)) ++ cb.append('Current window: ' + repr(vim.current.window)) ++ cb.append('Current buffer: ' + repr(vim.current.buffer)) ++ cb.append('Current line: ' + repr(vim.current.line)) ++ for b in vim.buffers: ++ if b is not cb: ++ vim.command('bwipeout! ' + str(b.number)) ++ EOF ++ :tabonly! ++ :only! + :endfun + :" + :call Test() +*** ../vim-7.3.954/src/testdir/test87.ok 2013-05-15 15:44:24.000000000 +0200 +--- src/testdir/test87.ok 2013-05-15 16:21:39.000000000 +0200 +*************** +*** 69,74 **** +--- 69,75 ---- + bac + def + bar ++ jkl + >>> paste + p/gopts1: False + p/wopts1! KeyError +*************** +*** 317,319 **** +--- 318,350 ---- + i4: + i4: + StopIteration ++ Number of tabs: 4 ++ Current tab pages: ++ (1): 1 windows, current is ++ Windows: ++ (0): displays buffer ; cursor is at (929, 0) ++ (2): 1 windows, current is ++ Windows: ++ (0): displays buffer ; cursor is at (1, 0) ++ (3): 2 windows, current is ++ Windows: ++ (0): displays buffer ; cursor is at (1, 0) ++ (0): displays buffer ; cursor is at (1, 0) ++ (4): 4 windows, current is ++ Windows: ++ (1): displays buffer ; cursor is at (1, 0) ++ (2): displays buffer ; cursor is at (1, 0) ++ (3): displays buffer ; cursor is at (1, 0) ++ (4): displays buffer ; cursor is at (1, 0) ++ Number of windows in current tab page: 4 ++ Current tab page: ++ Current window: : is ++ Current buffer: : is is ++ ValueError at assigning foreign tab window ++ Type error at assigning None to vim.current.window ++ Type error at assigning None to vim.current.tabpage ++ Type error at assigning None to vim.current.buffer ++ Current tab page: ++ Current window: ++ Current buffer: ++ Current line: 'Type error at assigning None to vim.current.buffer' +*** ../vim-7.3.954/src/version.c 2013-05-15 16:11:46.000000000 +0200 +--- src/version.c 2013-05-15 16:14:46.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 955, + /**/ + +-- +FATHER: You only killed the bride's father - that's all - +LAUNCELOT: Oh dear, I didn't really mean to... +FATHER: Didn't mean to? You put your sword right through his head! +LAUNCELOT: Gosh - Is he all right? + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From dc13e80ac903ca064c9e46ebb37ba4c17e8be3f0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:33 +0200 Subject: [PATCH 0855/3340] - patchlevel 956 --- 7.3.956 | 224 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 224 insertions(+) create mode 100644 7.3.956 diff --git a/7.3.956 b/7.3.956 new file mode 100644 index 00000000..d4c1be68 --- /dev/null +++ b/7.3.956 @@ -0,0 +1,224 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.956 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.956 +Problem: Python vim.bindeval() causes SIGABRT. +Solution: Make pygilstate a local variable. (Yukihiro Nakadaira) +Files: src/if_py_both.h, src/if_python.c, src/if_python3.c + + +*** ../vim-7.3.955/src/if_py_both.h 2013-05-15 16:11:46.000000000 +0200 +--- src/if_py_both.h 2013-05-15 17:37:48.000000000 +0200 +*************** +*** 1298,1304 **** +--- 1298,1311 ---- + } + } + ++ Py_BEGIN_ALLOW_THREADS ++ Python_Lock_Vim(); ++ + error = func_call(name, &args, selfdict, &rettv); ++ ++ Python_Release_Vim(); ++ Py_END_ALLOW_THREADS ++ + if (error != OK) + { + result = NULL; +*** ../vim-7.3.955/src/if_python.c 2013-05-15 16:04:34.000000000 +0200 +--- src/if_python.c 2013-05-15 17:37:48.000000000 +0200 +*************** +*** 676,686 **** + typedef PyObject PyThreadState; + #endif + +! #ifdef PY_CAN_RECURSE +! static PyGILState_STATE pygilstate = PyGILState_UNLOCKED; +! #else + static PyThreadState *saved_python_thread = NULL; +- #endif + + /* + * Suspend a thread of the Python interpreter, other threads are allowed to +--- 676,683 ---- + typedef PyObject PyThreadState; + #endif + +! #ifndef PY_CAN_RECURSE + static PyThreadState *saved_python_thread = NULL; + + /* + * Suspend a thread of the Python interpreter, other threads are allowed to +*************** +*** 689,699 **** + static void + Python_SaveThread(void) + { +- #ifdef PY_CAN_RECURSE +- PyGILState_Release(pygilstate); +- #else + saved_python_thread = PyEval_SaveThread(); +- #endif + } + + /* +--- 686,692 ---- +*************** +*** 703,715 **** + static void + Python_RestoreThread(void) + { +- #ifdef PY_CAN_RECURSE +- pygilstate = PyGILState_Ensure(); +- #else + PyEval_RestoreThread(saved_python_thread); + saved_python_thread = NULL; +- #endif + } + + void + python_end() +--- 696,705 ---- + static void + Python_RestoreThread(void) + { + PyEval_RestoreThread(saved_python_thread); + saved_python_thread = NULL; + } ++ #endif + + void + python_end() +*************** +*** 725,738 **** +--- 715,736 ---- + #ifdef DYNAMIC_PYTHON + if (hinstPython && Py_IsInitialized()) + { ++ # ifdef PY_CAN_RECURSE ++ PyGILState_Ensure(); ++ # else + Python_RestoreThread(); /* enter python */ ++ # endif + Py_Finalize(); + } + end_dynamic_python(); + #else + if (Py_IsInitialized()) + { ++ # ifdef PY_CAN_RECURSE ++ PyGILState_Ensure(); ++ # else + Python_RestoreThread(); /* enter python */ ++ # endif + Py_Finalize(); + } + #endif +*************** +*** 837,842 **** +--- 835,843 ---- + #if defined(HAVE_LOCALE_H) || defined(X_LOCALE) + char *saved_locale; + #endif ++ #ifdef PY_CAN_RECURSE ++ PyGILState_STATE pygilstate; ++ #endif + + #ifndef PY_CAN_RECURSE + if (recursive) +*************** +*** 881,887 **** +--- 882,892 ---- + } + #endif + ++ #ifdef PY_CAN_RECURSE ++ pygilstate = PyGILState_Ensure(); ++ #else + Python_RestoreThread(); /* enter python */ ++ #endif + + if (rettv == NULL) + PyRun_SimpleString((char *)(cmd)); +*************** +*** 905,911 **** +--- 910,920 ---- + PyErr_Clear(); + } + ++ #ifdef PY_CAN_RECURSE ++ PyGILState_Release(pygilstate); ++ #else + Python_SaveThread(); /* leave python */ ++ #endif + + #if defined(HAVE_LOCALE_H) || defined(X_LOCALE) + if (saved_locale != NULL) +*** ../vim-7.3.955/src/if_python3.c 2013-05-15 16:04:34.000000000 +0200 +--- src/if_python3.c 2013-05-15 17:37:48.000000000 +0200 +*************** +*** 699,706 **** + * 1. Python interpreter main program. + */ + +- static PyGILState_STATE pygilstate = PyGILState_UNLOCKED; +- + void + python3_end() + { +--- 699,704 ---- +*************** +*** 718,724 **** + if (Py_IsInitialized()) + { + // acquire lock before finalizing +! pygilstate = PyGILState_Ensure(); + + Py_Finalize(); + } +--- 716,722 ---- + if (Py_IsInitialized()) + { + // acquire lock before finalizing +! PyGILState_Ensure(); + + Py_Finalize(); + } +*************** +*** 826,831 **** +--- 824,830 ---- + #endif + PyObject *cmdstr; + PyObject *cmdbytes; ++ PyGILState_STATE pygilstate; + + #if defined(MACOS) && !defined(MACOS_X_UNIX) + GetPort(&oldPort); +*** ../vim-7.3.955/src/version.c 2013-05-15 16:27:33.000000000 +0200 +--- src/version.c 2013-05-15 17:48:15.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 956, + /**/ + +-- +GUEST: He's killed the best man! +SECOND GUEST: (holding a limp WOMAN) He's killed my auntie. +FATHER: No, please! This is supposed to be a happy occasion! Let's + not bicker and argue about who killed who ... + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 45b9fadea5ca60e4a3653640f503db3e58706eeb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:34 +0200 Subject: [PATCH 0856/3340] - patchlevel 957 --- 7.3.957 | 287 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 287 insertions(+) create mode 100644 7.3.957 diff --git a/7.3.957 b/7.3.957 new file mode 100644 index 00000000..ac684c3f --- /dev/null +++ b/7.3.957 @@ -0,0 +1,287 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.957 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.957 +Problem: Python does not have a "do" command like Perl or Lua. +Solution: Add the ":py3do" command. (Lilydjwg) +Files: runtime/doc/if_pyth.txt, src/ex_cmds.h, src/ex_docmd.c, + src/if_python3.c, src/proto/if_python3.pro + + +*** ../vim-7.3.956/runtime/doc/if_pyth.txt 2013-05-15 15:51:03.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-05-15 18:04:17.000000000 +0200 +*************** +*** 490,495 **** +--- 490,510 ---- + < *:py3file* + The |:py3file| command works similar to |:pyfile|. + ++ *:py3do* ++ :[range]py3do {body} Execute Python function "def _vim_pydo(line, linenr): ++ {body}" for each line in the [range], with the ++ function arguments being set to the text of each line ++ in turn, without a trailing , and the current ++ line number. The function should return a string or ++ None. If a string is returned, it becomes the text of ++ the line in the current turn. The default for [range] ++ is the whole file: "1,$". ++ {not in Vi} ++ ++ Examples: ++ > ++ :py3do return "%s\t%d" % (line[::-1], len(line)) ++ :py3do if line: return "%4d: %s" % (linenr, line) + + Vim can be built in four ways (:version output): + 1. No Python support (-python, -python3) +*** ../vim-7.3.956/src/ex_cmds.h 2012-11-14 20:52:22.000000000 +0100 +--- src/ex_cmds.h 2013-05-15 18:01:55.000000000 +0200 +*************** +*** 743,748 **** +--- 743,750 ---- + RANGE|FILE1|NEEDARG|CMDWIN), + EX(CMD_py3, "py3", ex_py3, + RANGE|EXTRA|NEEDARG|CMDWIN), ++ EX(CMD_py3do, "py3do", ex_py3do, ++ RANGE|DFLALL|EXTRA|NEEDARG|CMDWIN), + EX(CMD_python3, "python3", ex_py3, + RANGE|EXTRA|NEEDARG|CMDWIN), + EX(CMD_py3file, "py3file", ex_py3file, +*** ../vim-7.3.956/src/ex_docmd.c 2013-05-07 05:18:15.000000000 +0200 +--- src/ex_docmd.c 2013-05-15 18:01:55.000000000 +0200 +*************** +*** 272,277 **** +--- 272,278 ---- + #endif + #ifndef FEAT_PYTHON3 + # define ex_py3 ex_script_ni ++ # define ex_py3do ex_ni + # define ex_py3file ex_ni + #endif + #ifndef FEAT_TCL +*** ../vim-7.3.956/src/if_python3.c 2013-05-15 17:49:00.000000000 +0200 +--- src/if_python3.c 2013-05-15 18:23:30.000000000 +0200 +*************** +*** 76,81 **** +--- 76,82 ---- + #else + # define CODEC_ERROR_HANDLER NULL + #endif ++ #define DOPY_FUNC "_vim_pydo" + + /* Python 3 does not support CObjects, always use Capsules */ + #define PY_USE_CAPSULE +*************** +*** 126,131 **** +--- 127,133 ---- + # define PyErr_PrintEx py3_PyErr_PrintEx + # define PyErr_NoMemory py3_PyErr_NoMemory + # define PyErr_Occurred py3_PyErr_Occurred ++ # define PyErr_PrintEx py3_PyErr_PrintEx + # define PyErr_SetNone py3_PyErr_SetNone + # define PyErr_SetString py3_PyErr_SetString + # define PyErr_SetObject py3_PyErr_SetObject +*************** +*** 148,154 **** + # define PyTuple_GetItem py3_PyTuple_GetItem + # define PySlice_GetIndicesEx py3_PySlice_GetIndicesEx + # define PyImport_ImportModule py3_PyImport_ImportModule +- # define PyImport_AddModule py3_PyImport_AddModule + # define PyObject_Init py3__PyObject_Init + # define PyDict_New py3_PyDict_New + # define PyDict_GetItemString py3_PyDict_GetItemString +--- 150,155 ---- +*************** +*** 163,168 **** +--- 164,174 ---- + # define PyRun_SimpleString py3_PyRun_SimpleString + #undef PyRun_String + # define PyRun_String py3_PyRun_String ++ # define PyObject_GetAttrString py3_PyObject_GetAttrString ++ # define PyObject_SetAttrString py3_PyObject_SetAttrString ++ # define PyObject_CallFunctionObjArgs py3_PyObject_CallFunctionObjArgs ++ # define PyEval_GetLocals py3_PyEval_GetLocals ++ # define PyEval_GetGlobals py3_PyEval_GetGlobals + # define PySys_SetObject py3_PySys_SetObject + # define PySys_SetArgv py3_PySys_SetArgv + # define PyType_Ready py3_PyType_Ready +*************** +*** 178,183 **** +--- 184,190 ---- + # define _PyObject_NextNotImplemented (*py3__PyObject_NextNotImplemented) + # define PyModule_AddObject py3_PyModule_AddObject + # define PyImport_AppendInittab py3_PyImport_AppendInittab ++ # define PyImport_AddModule py3_PyImport_AddModule + # if PY_VERSION_HEX >= 0x030300f0 + # undef _PyUnicode_AsString + # define _PyUnicode_AsString py3_PyUnicode_AsUTF8 +*************** +*** 254,259 **** +--- 261,271 ---- + static void (*py3_PyErr_SetObject)(PyObject *, PyObject *); + static int (*py3_PyRun_SimpleString)(char *); + static PyObject* (*py3_PyRun_String)(char *, int, PyObject *, PyObject *); ++ static PyObject* (*py3_PyObject_GetAttrString)(PyObject *, const char *); ++ static PyObject* (*py3_PyObject_SetAttrString)(PyObject *, const char *, PyObject *); ++ static PyObject* (*py3_PyObject_CallFunctionObjArgs)(PyObject *, ...); ++ static PyObject* (*py3_PyEval_GetGlobals)(); ++ static PyObject* (*py3_PyEval_GetLocals)(); + static PyObject* (*py3_PyList_GetItem)(PyObject *, Py_ssize_t); + static PyObject* (*py3_PyImport_ImportModule)(const char *); + static PyObject* (*py3_PyImport_AddModule)(const char *); +*************** +*** 386,391 **** +--- 398,408 ---- + {"PyErr_SetObject", (PYTHON_PROC*)&py3_PyErr_SetObject}, + {"PyRun_SimpleString", (PYTHON_PROC*)&py3_PyRun_SimpleString}, + {"PyRun_String", (PYTHON_PROC*)&py3_PyRun_String}, ++ {"PyObject_GetAttrString", (PYTHON_PROC*)&py3_PyObject_GetAttrString}, ++ {"PyObject_SetAttrString", (PYTHON_PROC*)&py3_PyObject_SetAttrString}, ++ {"PyObject_CallFunctionObjArgs", (PYTHON_PROC*)&py3_PyObject_CallFunctionObjArgs}, ++ {"PyEval_GetGlobals", (PYTHON_PROC*)&py3_PyEval_GetGlobals}, ++ {"PyEval_GetLocals", (PYTHON_PROC*)&py3_PyEval_GetLocals}, + {"PyList_GetItem", (PYTHON_PROC*)&py3_PyList_GetItem}, + {"PyImport_ImportModule", (PYTHON_PROC*)&py3_PyImport_ImportModule}, + {"PyImport_AddModule", (PYTHON_PROC*)&py3_PyImport_AddModule}, +*************** +*** 990,995 **** +--- 1007,1106 ---- + DoPy3Command(eap, buffer, NULL); + } + ++ void ex_py3do(exarg_T *eap) ++ { ++ linenr_T i; ++ const char *code_hdr = "def " DOPY_FUNC "(line, linenr):\n "; ++ const char *s = (const char *) eap->arg; ++ size_t len; ++ char *code; ++ int status; ++ PyObject *pyfunc, *pymain; ++ PyGILState_STATE pygilstate; ++ ++ if (Python3_Init()) ++ goto theend; ++ ++ if (u_save(eap->line1 - 1, eap->line2 + 1) != OK) ++ { ++ EMSG(_("cannot save undo information")); ++ return; ++ } ++ len = strlen(code_hdr) + strlen(s); ++ code = malloc(len + 1); ++ STRCPY(code, code_hdr); ++ STRNCAT(code, s, len + 1); ++ pygilstate = PyGILState_Ensure(); ++ status = PyRun_SimpleString(code); ++ vim_free(code); ++ if (status) ++ { ++ EMSG(_("failed to run the code")); ++ return; ++ } ++ status = 0; /* good */ ++ pymain = PyImport_AddModule("__main__"); ++ pyfunc = PyObject_GetAttrString(pymain, DOPY_FUNC); ++ PyGILState_Release(pygilstate); ++ ++ for (i = eap->line1; i <= eap->line2; i++) ++ { ++ const char *line; ++ PyObject *pyline, *pylinenr, *pyret, *pybytes; ++ ++ line = (char *)ml_get(i); ++ pygilstate = PyGILState_Ensure(); ++ pyline = PyUnicode_Decode(line, strlen(line), ++ (char *)ENC_OPT, CODEC_ERROR_HANDLER); ++ pylinenr = PyLong_FromLong(i); ++ pyret = PyObject_CallFunctionObjArgs(pyfunc, pyline, pylinenr, NULL); ++ Py_DECREF(pyline); ++ Py_DECREF(pylinenr); ++ if (!pyret) ++ { ++ PyErr_PrintEx(0); ++ PythonIO_Flush(); ++ status = 1; ++ goto out; ++ } ++ ++ if (pyret && pyret != Py_None) ++ { ++ if (!PyUnicode_Check(pyret)) ++ { ++ /* TODO: a proper error number */ ++ EMSG(_("E000: return value must be an instance of str")); ++ Py_XDECREF(pyret); ++ status = 1; ++ goto out; ++ } ++ pybytes = PyUnicode_AsEncodedString(pyret, ++ (char *)ENC_OPT, CODEC_ERROR_HANDLER); ++ ml_replace(i, (char_u *) PyBytes_AsString(pybytes), 1); ++ Py_DECREF(pybytes); ++ changed(); ++ #ifdef SYNTAX_HL ++ syn_changed(i); /* recompute syntax hl. for this line */ ++ #endif ++ } ++ Py_XDECREF(pyret); ++ PythonIO_Flush(); ++ PyGILState_Release(pygilstate); ++ } ++ pygilstate = PyGILState_Ensure(); ++ out: ++ Py_DECREF(pyfunc); ++ PyObject_SetAttrString(pymain, DOPY_FUNC, NULL); ++ PyGILState_Release(pygilstate); ++ if (status) ++ return; ++ check_cursor(); ++ update_curbuf(NOT_VALID); ++ ++ theend: ++ return; ++ } ++ + /****************************************************** + * 2. Python output stream: writes output via [e]msg(). + */ +*** ../vim-7.3.956/src/proto/if_python3.pro 2013-05-15 15:12:25.000000000 +0200 +--- src/proto/if_python3.pro 2013-05-15 18:01:55.000000000 +0200 +*************** +*** 3,8 **** +--- 3,9 ---- + void python3_end __ARGS((void)); + int python3_loaded __ARGS((void)); + void ex_py3 __ARGS((exarg_T *eap)); ++ void ex_py3do __ARGS((exarg_T *eap)); + void ex_py3file __ARGS((exarg_T *eap)); + void python3_buffer_free __ARGS((buf_T *buf)); + void python3_window_free __ARGS((win_T *win)); +*** ../vim-7.3.956/src/version.c 2013-05-15 17:49:00.000000000 +0200 +--- src/version.c 2013-05-15 18:16:28.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 957, + /**/ + +-- +FATHER: We are here today to witness the union of two young people in the + joyful bond of the holy wedlock. Unfortunately, one of them, my son + Herbert, has just fallen to his death. + [Murmurs from CROWD; the BRIDE smiles with relief, coughs.] + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b787dd15d2c5328c7182d88742c02e5d36cd2019 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:35 +0200 Subject: [PATCH 0857/3340] - patchlevel 958 --- 7.3.958 | 67 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 7.3.958 diff --git a/7.3.958 b/7.3.958 new file mode 100644 index 00000000..92aa384b --- /dev/null +++ b/7.3.958 @@ -0,0 +1,67 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.958 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.958 +Problem: Python: Iteration destructor not set. +Solution: Put IterDestructor to use. (ZyX) +Files: src/if_py_both.c + + +*** ../vim-7.3.957/src/if_py_both.h 2013-05-15 17:49:00.000000000 +0200 +--- src/if_py_both.h 2013-05-15 19:00:19.000000000 +0200 +*************** +*** 566,572 **** + return (PyObject *)(self); + } + +- #if 0 /* unused */ + static void + IterDestructor(PyObject *self) + { +--- 566,571 ---- +*************** +*** 576,582 **** + + DESTRUCTOR_FINISH(self); + } +- #endif + + static PyObject * + IterNext(PyObject *self) +--- 575,580 ---- +*************** +*** 3823,3828 **** +--- 3821,3827 ---- + IterType.tp_doc = "generic iterator object"; + IterType.tp_iter = IterIter; + IterType.tp_iternext = IterNext; ++ IterType.tp_dealloc = IterDestructor; + + vim_memset(&BufferType, 0, sizeof(BufferType)); + BufferType.tp_name = "vim.buffer"; +*** ../vim-7.3.957/src/version.c 2013-05-15 18:28:08.000000000 +0200 +--- src/version.c 2013-05-15 19:05:28.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 958, + /**/ + +-- +Yesterday is history. +Tomorrow is a mystery. +Today is a gift. +That's why it is called 'present'. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 17f88d31367b847b731a8516857c07dc43b545ff Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:35 +0200 Subject: [PATCH 0858/3340] - patchlevel 959 --- 7.3.959 | 74 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 7.3.959 diff --git a/7.3.959 b/7.3.959 new file mode 100644 index 00000000..0435da3b --- /dev/null +++ b/7.3.959 @@ -0,0 +1,74 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.959 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.959 (after 7.3.957) +Problem: Missing error number. +Solution: Assign an error number. +Files: src/if_python3.c + + +*** ../vim-7.3.958/src/if_python3.c 2013-05-15 18:28:08.000000000 +0200 +--- src/if_python3.c 2013-05-15 19:41:51.000000000 +0200 +*************** +*** 1007,1013 **** + DoPy3Command(eap, buffer, NULL); + } + +! void ex_py3do(exarg_T *eap) + { + linenr_T i; + const char *code_hdr = "def " DOPY_FUNC "(line, linenr):\n "; +--- 1007,1014 ---- + DoPy3Command(eap, buffer, NULL); + } + +! void +! ex_py3do(exarg_T *eap) + { + linenr_T i; + const char *code_hdr = "def " DOPY_FUNC "(line, linenr):\n "; +*************** +*** 1068,1075 **** + { + if (!PyUnicode_Check(pyret)) + { +! /* TODO: a proper error number */ +! EMSG(_("E000: return value must be an instance of str")); + Py_XDECREF(pyret); + status = 1; + goto out; +--- 1069,1075 ---- + { + if (!PyUnicode_Check(pyret)) + { +! EMSG(_("E863: return value must be an instance of str")); + Py_XDECREF(pyret); + status = 1; + goto out; +*** ../vim-7.3.958/src/version.c 2013-05-15 19:07:03.000000000 +0200 +--- src/version.c 2013-05-15 19:38:05.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 959, + /**/ + + +-- +CRONE: Who sent you? +ARTHUR: The Knights Who Say Ni! +CRONE: Aaaagh! (she looks around in rear) No! We have no shrubberies here. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 35fc42d93fa0605a116a4c4aea887a5306deb7b3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:36 +0200 Subject: [PATCH 0859/3340] - patchlevel 960 --- 7.3.960 | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 7.3.960 diff --git a/7.3.960 b/7.3.960 new file mode 100644 index 00000000..1b4b25c4 --- /dev/null +++ b/7.3.960 @@ -0,0 +1,47 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.960 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.960 +Problem: Compiler warning for unused variable. +Solution: Put declaration in #ifdef. +Files: src/window.c + + +*** ../vim-7.3.959/src/window.c 2013-05-15 15:12:25.000000000 +0200 +--- src/window.c 2013-05-15 23:11:02.000000000 +0200 +*************** +*** 2124,2130 **** +--- 2124,2132 ---- + { + if (firstwin == lastwin) + { ++ #ifdef FEAT_AUTOCMD + buf_T *old_curbuf = curbuf; ++ #endif + + /* + * Closing the last window in a tab page. First go to another tab +*** ../vim-7.3.959/src/version.c 2013-05-15 19:44:35.000000000 +0200 +--- src/version.c 2013-05-15 23:12:12.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 960, + /**/ + +-- +Did you ever stop to think... and forget to start again? + -- Steven Wright + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5d2c32534929a85be25d834a16d5f862ad7d5f2a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:37 +0200 Subject: [PATCH 0860/3340] - patchlevel 961 --- 7.3.961 | 90 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) create mode 100644 7.3.961 diff --git a/7.3.961 b/7.3.961 new file mode 100644 index 00000000..c61ec657 --- /dev/null +++ b/7.3.961 @@ -0,0 +1,90 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.961 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.961 +Problem: Tests 86 and 87 fail when using another language than English. +Solution: Set the language to C in the test. (Dominique Pelle) +Files: src/testdir/test86.in, src/testdir/test87.in, + src/testdir/test87.ok + + +*** ../vim-7.3.960/src/testdir/test86.in 2013-05-15 16:27:33.000000000 +0200 +--- src/testdir/test86.in 2013-05-16 18:58:46.000000000 +0200 +*************** +*** 5,14 **** + ./configure --without-pymalloc + See http://svn.python.org/view/python/trunk/Misc/README.valgrind?view=markup + +- + STARTTEST + :so small.vim + :if !has('python') | e! test.ok | wq! test.out | endif + :py import vim + :fun Test() + :let l = [] +--- 5,14 ---- + ./configure --without-pymalloc + See http://svn.python.org/view/python/trunk/Misc/README.valgrind?view=markup + + STARTTEST + :so small.vim + :if !has('python') | e! test.ok | wq! test.out | endif ++ :lang C + :py import vim + :fun Test() + :let l = [] +*** ../vim-7.3.960/src/testdir/test87.in 2013-05-15 16:27:33.000000000 +0200 +--- src/testdir/test87.in 2013-05-16 18:56:21.000000000 +0200 +*************** +*** 3,8 **** +--- 3,9 ---- + STARTTEST + :so small.vim + :if !has('python3') | e! test.ok | wq! test.out | endif ++ :lang C + :py3 import vim + :fun Test() + :let l = [] +*** ../vim-7.3.960/src/testdir/test87.ok 2013-05-15 16:27:33.000000000 +0200 +--- src/testdir/test87.ok 2013-05-16 20:46:05.000000000 +0200 +*************** +*** 322,328 **** + Current tab pages: + (1): 1 windows, current is + Windows: +! (0): displays buffer ; cursor is at (929, 0) + (2): 1 windows, current is + Windows: + (0): displays buffer ; cursor is at (1, 0) +--- 322,328 ---- + Current tab pages: + (1): 1 windows, current is + Windows: +! (0): displays buffer ; cursor is at (930, 0) + (2): 1 windows, current is + Windows: + (0): displays buffer ; cursor is at (1, 0) +*** ../vim-7.3.960/src/version.c 2013-05-15 23:13:06.000000000 +0200 +--- src/version.c 2013-05-16 20:47:38.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 961, + /**/ + +-- +When I look deep into your eyes, I see JPEG artifacts. +I can tell by the pixels that we're wrong for each other. (xkcd) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0f6a9a21162e0a5e1f6d2e3d08dbc1cace13b757 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:37 +0200 Subject: [PATCH 0861/3340] - patchlevel 962 --- 7.3.962 | 230 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 230 insertions(+) create mode 100644 7.3.962 diff --git a/7.3.962 b/7.3.962 new file mode 100644 index 00000000..ee39d5e7 --- /dev/null +++ b/7.3.962 @@ -0,0 +1,230 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.962 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.962 +Problem: Python tests are not portable. +Solution: Use shiftwidth instead of iminsert. (ZyX) +Files: src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.961/src/testdir/test86.in 2013-05-16 20:47:51.000000000 +0200 +--- src/testdir/test86.in 2013-05-17 13:34:56.000000000 +0200 +*************** +*** 354,360 **** + :" colorcolumn: string, window-local + :" statusline: string, window-local/global + :" autoindent: boolean, buffer-local +! :" iminsert: number, buffer-local + :" omnifunc: string, buffer-local + :" preserveindent: boolean, buffer-local/global + :" path: string, buffer-local/global +--- 354,360 ---- + :" colorcolumn: string, window-local + :" statusline: string, window-local/global + :" autoindent: boolean, buffer-local +! :" shiftwidth: number, buffer-local + :" omnifunc: string, buffer-local + :" preserveindent: boolean, buffer-local/global + :" path: string, buffer-local/global +*************** +*** 411,417 **** + :let lst+=[['colorcolumn', '+1', '+2', '+3', 'abc', 0, 0, 1 ]] + :let lst+=[['statusline', '1', '2', '4', 0, 0, 1, 1 ]] + :let lst+=[['autoindent', 0, 1, 1, 2, 1, 0, 2 ]] +! :let lst+=[['iminsert', 0, 2, 1, 3, 0, 0, 2 ]] + :let lst+=[['omnifunc', 'A', 'B', 'C', 1, 0, 0, 2 ]] + :let lst+=[['preserveindent', 0, 1, 1, 2, 1, 1, 2 ]] + :let lst+=[['path', '.,,', ',,', '.', 0, 0, 1, 2 ]] +--- 411,417 ---- + :let lst+=[['colorcolumn', '+1', '+2', '+3', 'abc', 0, 0, 1 ]] + :let lst+=[['statusline', '1', '2', '4', 0, 0, 1, 1 ]] + :let lst+=[['autoindent', 0, 1, 1, 2, 1, 0, 2 ]] +! :let lst+=[['shiftwidth', 0, 2, 1, 3, 0, 0, 2 ]] + :let lst+=[['omnifunc', 'A', 'B', 'C', 1, 0, 0, 2 ]] + :let lst+=[['preserveindent', 0, 1, 1, 2, 1, 1, 2 ]] + :let lst+=[['path', '.,,', ',,', '.', 0, 0, 1, 2 ]] +*** ../vim-7.3.961/src/testdir/test86.ok 2013-05-15 16:27:33.000000000 +0200 +--- src/testdir/test86.ok 2013-05-17 13:34:56.000000000 +0200 +*************** +*** 232,238 **** + G: 0 + W: 1:0 2:1 3:0 4:1 + B: 1:0 2:1 3:0 4:1 +! >>> iminsert + p/gopts1! KeyError + inv: 3! KeyError + gopts1! KeyError +--- 232,238 ---- + G: 0 + W: 1:0 2:1 3:0 4:1 + B: 1:0 2:1 3:0 4:1 +! >>> shiftwidth + p/gopts1! KeyError + inv: 3! KeyError + gopts1! KeyError +*************** +*** 241,255 **** + wopts1! KeyError + wopts2! KeyError + wopts3! KeyError +! p/bopts1: 2 +! G: 1 +! W: 1:0 2:2 3:2 4:1 +! B: 1:0 2:2 3:2 4:1 + del wopts3! KeyError + del bopts3! ValueError +! G: 1 +! W: 1:0 2:2 3:2 4:1 +! B: 1:0 2:2 3:2 4:1 + >>> omnifunc + p/gopts1! KeyError + inv: 1! KeyError +--- 241,255 ---- + wopts1! KeyError + wopts2! KeyError + wopts3! KeyError +! p/bopts1: 8 +! G: 8 +! W: 1:0 2:2 3:8 4:1 +! B: 1:0 2:2 3:8 4:1 + del wopts3! KeyError + del bopts3! ValueError +! G: 8 +! W: 1:0 2:2 3:8 4:1 +! B: 1:0 2:2 3:8 4:1 + >>> omnifunc + p/gopts1! KeyError + inv: 1! KeyError +*************** +*** 333,339 **** + Current tab pages: + (1): 1 windows, current is + Windows: +! (0): displays buffer ; cursor is at (954, 0) + (2): 1 windows, current is + Windows: + (0): displays buffer ; cursor is at (1, 0) +--- 333,339 ---- + Current tab pages: + (1): 1 windows, current is + Windows: +! (0): displays buffer ; cursor is at (955, 0) + (2): 1 windows, current is + Windows: + (0): displays buffer ; cursor is at (1, 0) +*** ../vim-7.3.961/src/testdir/test87.in 2013-05-16 20:47:51.000000000 +0200 +--- src/testdir/test87.in 2013-05-17 13:34:56.000000000 +0200 +*************** +*** 341,347 **** + :" colorcolumn: string, window-local + :" statusline: string, window-local/global + :" autoindent: boolean, buffer-local +! :" iminsert: number, buffer-local + :" omnifunc: string, buffer-local + :" preserveindent: boolean, buffer-local/global + :" path: string, buffer-local/global +--- 341,347 ---- + :" colorcolumn: string, window-local + :" statusline: string, window-local/global + :" autoindent: boolean, buffer-local +! :" shiftwidth: number, buffer-local + :" omnifunc: string, buffer-local + :" preserveindent: boolean, buffer-local/global + :" path: string, buffer-local/global +*************** +*** 398,404 **** + :let lst+=[['colorcolumn', '+1', '+2', '+3', 'abc', 0, 0, 1 ]] + :let lst+=[['statusline', '1', '2', '4', 0, 0, 1, 1 ]] + :let lst+=[['autoindent', 0, 1, 1, 2, 1, 0, 2 ]] +! :let lst+=[['iminsert', 0, 2, 1, 3, 0, 0, 2 ]] + :let lst+=[['omnifunc', 'A', 'B', 'C', 1, 0, 0, 2 ]] + :let lst+=[['preserveindent', 0, 1, 1, 2, 1, 1, 2 ]] + :let lst+=[['path', '.,,', ',,', '.', 0, 0, 1, 2 ]] +--- 398,404 ---- + :let lst+=[['colorcolumn', '+1', '+2', '+3', 'abc', 0, 0, 1 ]] + :let lst+=[['statusline', '1', '2', '4', 0, 0, 1, 1 ]] + :let lst+=[['autoindent', 0, 1, 1, 2, 1, 0, 2 ]] +! :let lst+=[['shiftwidth', 0, 2, 1, 3, 0, 0, 2 ]] + :let lst+=[['omnifunc', 'A', 'B', 'C', 1, 0, 0, 2 ]] + :let lst+=[['preserveindent', 0, 1, 1, 2, 1, 1, 2 ]] + :let lst+=[['path', '.,,', ',,', '.', 0, 0, 1, 2 ]] +*** ../vim-7.3.961/src/testdir/test87.ok 2013-05-16 20:47:51.000000000 +0200 +--- src/testdir/test87.ok 2013-05-17 13:34:56.000000000 +0200 +*************** +*** 221,227 **** + G: 0 + W: 1:0 2:1 3:0 4:1 + B: 1:0 2:1 3:0 4:1 +! >>> iminsert + p/gopts1! KeyError + inv: 3! KeyError + gopts1! KeyError +--- 221,227 ---- + G: 0 + W: 1:0 2:1 3:0 4:1 + B: 1:0 2:1 3:0 4:1 +! >>> shiftwidth + p/gopts1! KeyError + inv: 3! KeyError + gopts1! KeyError +*************** +*** 230,244 **** + wopts1! KeyError + wopts2! KeyError + wopts3! KeyError +! p/bopts1: 2 +! G: 1 +! W: 1:0 2:2 3:2 4:1 +! B: 1:0 2:2 3:2 4:1 + del wopts3! KeyError + del bopts3! ValueError +! G: 1 +! W: 1:0 2:2 3:2 4:1 +! B: 1:0 2:2 3:2 4:1 + >>> omnifunc + p/gopts1! KeyError + inv: 1! KeyError +--- 230,244 ---- + wopts1! KeyError + wopts2! KeyError + wopts3! KeyError +! p/bopts1: 8 +! G: 8 +! W: 1:0 2:2 3:8 4:1 +! B: 1:0 2:2 3:8 4:1 + del wopts3! KeyError + del bopts3! ValueError +! G: 8 +! W: 1:0 2:2 3:8 4:1 +! B: 1:0 2:2 3:8 4:1 + >>> omnifunc + p/gopts1! KeyError + inv: 1! KeyError +*** ../vim-7.3.961/src/version.c 2013-05-16 20:47:51.000000000 +0200 +--- src/version.c 2013-05-17 13:36:36.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 962, + /**/ + +-- +TIM: To the north there lies a cave, the cave of Caerbannog, wherein, carved + in mystic runes, upon the very living rock, the last words of Olfin + Bedwere of Rheged make plain the last resting place of the most Holy + Grail. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bc9fedf68542f3de5a87b43ea679a95c31a9b3fd Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:38 +0200 Subject: [PATCH 0862/3340] - patchlevel 963 --- 7.3.963 | 720 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 720 insertions(+) create mode 100644 7.3.963 diff --git a/7.3.963 b/7.3.963 new file mode 100644 index 00000000..85c362c8 --- /dev/null +++ b/7.3.963 @@ -0,0 +1,720 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.963 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.963 +Problem: Setting curbuf without curwin causes trouble. +Solution: Add switch_buffer() and restore_buffer(). Block autocommands to + avoid trouble. +Files: src/eval.c, src/proto/eval.pro, src/proto/window.pro, + src/if_py_both.h, src/window.c, src/testdir/test86.ok + + +*** ../vim-7.3.962/src/eval.c 2013-05-15 14:39:47.000000000 +0200 +--- src/eval.c 2013-05-17 14:50:35.000000000 +0200 +*************** +*** 11894,11900 **** + win_T *win, *oldcurwin; + char_u *varname; + dictitem_T *v; +! tabpage_T *tp; + int done = FALSE; + + #ifdef FEAT_WINDOWS +--- 11894,11900 ---- + win_T *win, *oldcurwin; + char_u *varname; + dictitem_T *v; +! tabpage_T *tp, *oldtabpage; + int done = FALSE; + + #ifdef FEAT_WINDOWS +*************** +*** 11912,11922 **** + + if (win != NULL && varname != NULL) + { +! /* Set curwin to be our win, temporarily. Also set curbuf, so +! * that we can get buffer-local options. */ +! oldcurwin = curwin; +! curwin = win; +! curbuf = win->w_buffer; + + if (*varname == '&') /* window-local-option */ + { +--- 11912,11920 ---- + + if (win != NULL && varname != NULL) + { +! /* Set curwin to be our win, temporarily. Also set the tabpage, +! * otherwise the window is not valid. */ +! switch_win(&oldcurwin, &oldtabpage, win, tp); + + if (*varname == '&') /* window-local-option */ + { +*************** +*** 11936,11943 **** + } + + /* restore previous notion of curwin */ +! curwin = oldcurwin; +! curbuf = curwin->w_buffer; + } + + if (!done && argvars[off + 2].v_type != VAR_UNKNOWN) +--- 11934,11940 ---- + } + + /* restore previous notion of curwin */ +! restore_win(oldcurwin, oldtabpage); + } + + if (!done && argvars[off + 2].v_type != VAR_UNKNOWN) +*************** +*** 16641,16684 **** + setwinvar(argvars, rettv, 0); + } + +- int +- switch_win(save_curwin, save_curtab, win, tp) +- win_T **save_curwin; +- tabpage_T **save_curtab; +- win_T *win; +- tabpage_T *tp; +- { +- #ifdef FEAT_WINDOWS +- /* set curwin to be our win, temporarily */ +- *save_curwin = curwin; +- *save_curtab = curtab; +- goto_tabpage_tp(tp, FALSE, FALSE); +- if (!win_valid(win)) +- return FAIL; +- curwin = win; +- curbuf = curwin->w_buffer; +- #endif +- return OK; +- } +- +- void +- restore_win(save_curwin, save_curtab) +- win_T *save_curwin; +- tabpage_T *save_curtab; +- { +- #ifdef FEAT_WINDOWS +- /* Restore current tabpage and window, if still valid (autocommands can +- * make them invalid). */ +- if (valid_tabpage(save_curtab)) +- goto_tabpage_tp(save_curtab, FALSE, FALSE); +- if (win_valid(save_curwin)) +- { +- curwin = save_curwin; +- curbuf = curwin->w_buffer; +- } +- #endif +- } +- + /* + * "setwinvar()" and "settabwinvar()" functions + */ +--- 16638,16643 ---- +*** ../vim-7.3.962/src/proto/eval.pro 2013-05-15 14:39:47.000000000 +0200 +--- src/proto/eval.pro 2013-05-17 16:01:40.000000000 +0200 +*************** +*** 33,38 **** +--- 33,40 ---- + void prof_child_exit __ARGS((proftime_T *tm)); + int eval_foldexpr __ARGS((char_u *arg, int *cp)); + void ex_let __ARGS((exarg_T *eap)); ++ void list_add_watch __ARGS((list_T *l, listwatch_T *lw)); ++ void list_rem_watch __ARGS((list_T *l, listwatch_T *lwrem)); + void *eval_for_line __ARGS((char_u *arg, int *errp, char_u **nextcmdp, int skip)); + int next_for_item __ARGS((void *fi_void, char_u *arg)); + void free_for_info __ARGS((void *fi_void)); +*************** +*** 125,132 **** + void ex_oldfiles __ARGS((exarg_T *eap)); + int modify_fname __ARGS((char_u *src, int *usedlen, char_u **fnamep, char_u **bufp, int *fnamelen)); + char_u *do_string_sub __ARGS((char_u *str, char_u *pat, char_u *sub, char_u *flags)); +- int switch_win __ARGS((win_T **, tabpage_T **, win_T *, tabpage_T *)); +- void restore_win __ARGS((win_T *, tabpage_T *)); +- void list_add_watch __ARGS((list_T *l, listwatch_T *lw)); +- void list_rem_watch __ARGS((list_T *l, listwatch_T *lwrem)); + /* vim: set ft=c : */ +--- 127,130 ---- +*** ../vim-7.3.962/src/proto/window.pro 2013-05-15 15:12:25.000000000 +0200 +--- src/proto/window.pro 2013-05-17 15:04:14.000000000 +0200 +*************** +*** 32,37 **** +--- 32,38 ---- + void tabpage_move __ARGS((int nr)); + void win_goto __ARGS((win_T *wp)); + win_T *win_find_nr __ARGS((int winnr)); ++ tabpage_T *win_find_tabpage __ARGS((win_T *win)); + void win_enter __ARGS((win_T *wp, int undo_sync)); + win_T *buf_jump_open_win __ARGS((buf_T *buf)); + win_T *buf_jump_open_tab __ARGS((buf_T *buf)); +*************** +*** 69,74 **** +--- 70,79 ---- + void check_lnums __ARGS((int do_curwin)); + void make_snapshot __ARGS((int idx)); + void restore_snapshot __ARGS((int idx, int close_curwin)); ++ int switch_win __ARGS((win_T **save_curwin, tabpage_T **save_curtab, win_T *win, tabpage_T *tp)); ++ void restore_win __ARGS((win_T *save_curwin, tabpage_T *save_curtab)); ++ void switch_buffer __ARGS((buf_T **save_curbuf, buf_T *buf)); ++ void restore_buffer __ARGS((buf_T *save_curbuf)); + int win_hasvertsplit __ARGS((void)); + int match_add __ARGS((win_T *wp, char_u *grp, char_u *pat, int prio, int id)); + int match_delete __ARGS((win_T *wp, int id, int perr)); +*** ../vim-7.3.962/src/if_py_both.h 2013-05-15 19:07:03.000000000 +0200 +--- src/if_py_both.h 2013-05-17 15:57:08.000000000 +0200 +*************** +*** 1413,1426 **** + { + win_T *save_curwin; + tabpage_T *save_curtab; +! aco_save_T aco; + int r = 0; + + switch (opt_type) + { + case SREQ_WIN: +! if (switch_win(&save_curwin, &save_curtab, (win_T *) from, curtab) +! == FAIL) + { + PyErr_SetVim("Problem while switching windows."); + return -1; +--- 1413,1426 ---- + { + win_T *save_curwin; + tabpage_T *save_curtab; +! buf_T *save_curbuf; + int r = 0; + + switch (opt_type) + { + case SREQ_WIN: +! if (switch_win(&save_curwin, &save_curtab, (win_T *)from, +! win_find_tabpage((win_T *)from)) == FAIL) + { + PyErr_SetVim("Problem while switching windows."); + return -1; +*************** +*** 1429,1437 **** + restore_win(save_curwin, save_curtab); + break; + case SREQ_BUF: +! aucmd_prepbuf(&aco, (buf_T *) from); + set_option_value(key, numval, stringval, opt_flags); +! aucmd_restbuf(&aco); + break; + case SREQ_GLOBAL: + set_option_value(key, numval, stringval, opt_flags); +--- 1429,1437 ---- + restore_win(save_curwin, save_curtab); + break; + case SREQ_BUF: +! switch_buffer(&save_curbuf, (buf_T *)from); + set_option_value(key, numval, stringval, opt_flags); +! restore_buffer(save_curbuf); + break; + case SREQ_GLOBAL: + set_option_value(key, numval, stringval, opt_flags); +*************** +*** 2240,2249 **** + */ + if (line == Py_None || line == NULL) + { +! buf_T *savebuf = curbuf; + + PyErr_Clear(); +! curbuf = buf; + + if (u_savedel((linenr_T)n, 1L) == FAIL) + PyErr_SetVim(_("cannot save undo information")); +--- 2240,2249 ---- + */ + if (line == Py_None || line == NULL) + { +! buf_T *savebuf; + + PyErr_Clear(); +! switch_buffer(&savebuf, buf); + + if (u_savedel((linenr_T)n, 1L) == FAIL) + PyErr_SetVim(_("cannot save undo information")); +*************** +*** 2251,2262 **** + PyErr_SetVim(_("cannot delete line")); + else + { +! if (buf == curwin->w_buffer) + py_fix_cursor((linenr_T)n, (linenr_T)n + 1, (linenr_T)-1); + deleted_lines_mark((linenr_T)n, 1L); + } + +! curbuf = savebuf; + + if (PyErr_Occurred() || VimErrorCheck()) + return FAIL; +--- 2251,2262 ---- + PyErr_SetVim(_("cannot delete line")); + else + { +! if (buf == savebuf) + py_fix_cursor((linenr_T)n, (linenr_T)n + 1, (linenr_T)-1); + deleted_lines_mark((linenr_T)n, 1L); + } + +! restore_buffer(savebuf); + + if (PyErr_Occurred() || VimErrorCheck()) + return FAIL; +*************** +*** 2269,2282 **** + else if (PyString_Check(line)) + { + char *save = StringToLine(line); +! buf_T *savebuf = curbuf; + + if (save == NULL) + return FAIL; + + /* We do not need to free "save" if ml_replace() consumes it. */ + PyErr_Clear(); +! curbuf = buf; + + if (u_savesub((linenr_T)n) == FAIL) + { +--- 2269,2282 ---- + else if (PyString_Check(line)) + { + char *save = StringToLine(line); +! buf_T *savebuf; + + if (save == NULL) + return FAIL; + + /* We do not need to free "save" if ml_replace() consumes it. */ + PyErr_Clear(); +! switch_buffer(&savebuf, buf); + + if (u_savesub((linenr_T)n) == FAIL) + { +*************** +*** 2291,2300 **** + else + changed_bytes((linenr_T)n, 0); + +! curbuf = savebuf; + + /* Check that the cursor is not beyond the end of the line now. */ +! if (buf == curwin->w_buffer) + check_cursor_col(); + + if (PyErr_Occurred() || VimErrorCheck()) +--- 2291,2300 ---- + else + changed_bytes((linenr_T)n, 0); + +! restore_buffer(savebuf); + + /* Check that the cursor is not beyond the end of the line now. */ +! if (buf == savebuf) + check_cursor_col(); + + if (PyErr_Occurred() || VimErrorCheck()) +*************** +*** 2333,2342 **** + { + PyInt i; + PyInt n = (int)(hi - lo); +! buf_T *savebuf = curbuf; + + PyErr_Clear(); +! curbuf = buf; + + if (u_savedel((linenr_T)lo, (long)n) == FAIL) + PyErr_SetVim(_("cannot save undo information")); +--- 2333,2342 ---- + { + PyInt i; + PyInt n = (int)(hi - lo); +! buf_T *savebuf; + + PyErr_Clear(); +! switch_buffer(&savebuf, buf); + + if (u_savedel((linenr_T)lo, (long)n) == FAIL) + PyErr_SetVim(_("cannot save undo information")); +*************** +*** 2350,2361 **** + break; + } + } +! if (buf == curwin->w_buffer) + py_fix_cursor((linenr_T)lo, (linenr_T)hi, (linenr_T)-n); + deleted_lines_mark((linenr_T)lo, (long)i); + } + +! curbuf = savebuf; + + if (PyErr_Occurred() || VimErrorCheck()) + return FAIL; +--- 2350,2361 ---- + break; + } + } +! if (buf == savebuf) + py_fix_cursor((linenr_T)lo, (linenr_T)hi, (linenr_T)-n); + deleted_lines_mark((linenr_T)lo, (long)i); + } + +! restore_buffer(savebuf); + + if (PyErr_Occurred() || VimErrorCheck()) + return FAIL; +*************** +*** 2400,2409 **** + } + } + +- savebuf = curbuf; +- + PyErr_Clear(); +! curbuf = buf; + + if (u_save((linenr_T)(lo-1), (linenr_T)hi) == FAIL) + PyErr_SetVim(_("cannot save undo information")); +--- 2400,2409 ---- + } + } + + PyErr_Clear(); +! +! // START of region without "return". Must call restore_buffer()! +! switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)(lo-1), (linenr_T)hi) == FAIL) + PyErr_SetVim(_("cannot save undo information")); +*************** +*** 2480,2489 **** + (long)MAXLNUM, (long)extra); + changed_lines((linenr_T)lo, 0, (linenr_T)hi, (long)extra); + +! if (buf == curwin->w_buffer) + py_fix_cursor((linenr_T)lo, (linenr_T)hi, (linenr_T)extra); + +! curbuf = savebuf; + + if (PyErr_Occurred() || VimErrorCheck()) + return FAIL; +--- 2480,2490 ---- + (long)MAXLNUM, (long)extra); + changed_lines((linenr_T)lo, 0, (linenr_T)hi, (long)extra); + +! if (buf == savebuf) + py_fix_cursor((linenr_T)lo, (linenr_T)hi, (linenr_T)extra); + +! // END of region without "return". +! restore_buffer(savebuf); + + if (PyErr_Occurred() || VimErrorCheck()) + return FAIL; +*************** +*** 2522,2531 **** + if (str == NULL) + return FAIL; + +- savebuf = curbuf; +- + PyErr_Clear(); +! curbuf = buf; + + if (u_save((linenr_T)n, (linenr_T)(n+1)) == FAIL) + PyErr_SetVim(_("cannot save undo information")); +--- 2523,2530 ---- + if (str == NULL) + return FAIL; + + PyErr_Clear(); +! switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)n, (linenr_T)(n+1)) == FAIL) + PyErr_SetVim(_("cannot save undo information")); +*************** +*** 2535,2541 **** + appended_lines_mark((linenr_T)n, 1L); + + vim_free(str); +! curbuf = savebuf; + update_screen(VALID); + + if (PyErr_Occurred() || VimErrorCheck()) +--- 2534,2540 ---- + appended_lines_mark((linenr_T)n, 1L); + + vim_free(str); +! restore_buffer(savebuf); + update_screen(VALID); + + if (PyErr_Occurred() || VimErrorCheck()) +*************** +*** 2574,2583 **** + } + } + +- savebuf = curbuf; +- + PyErr_Clear(); +! curbuf = buf; + + if (u_save((linenr_T)n, (linenr_T)(n + 1)) == FAIL) + PyErr_SetVim(_("cannot save undo information")); +--- 2573,2580 ---- + } + } + + PyErr_Clear(); +! switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)n, (linenr_T)(n + 1)) == FAIL) + PyErr_SetVim(_("cannot save undo information")); +*************** +*** 2607,2613 **** + */ + vim_free(array); + +! curbuf = savebuf; + update_screen(VALID); + + if (PyErr_Occurred() || VimErrorCheck()) +--- 2604,2610 ---- + */ + vim_free(array); + +! restore_buffer(savebuf); + update_screen(VALID); + + if (PyErr_Occurred() || VimErrorCheck()) +*************** +*** 3023,3029 **** + pos_T *posp; + char *pmark; + char mark; +! buf_T *curbuf_save; + + if (CheckBuffer((BufferObject *)(self))) + return NULL; +--- 3020,3026 ---- + pos_T *posp; + char *pmark; + char mark; +! buf_T *savebuf; + + if (CheckBuffer((BufferObject *)(self))) + return NULL; +*************** +*** 3032,3041 **** + return NULL; + mark = *pmark; + +! curbuf_save = curbuf; +! curbuf = ((BufferObject *)(self))->buf; + posp = getmark(mark, FALSE); +! curbuf = curbuf_save; + + if (posp == NULL) + { +--- 3029,3037 ---- + return NULL; + mark = *pmark; + +! switch_buffer(&savebuf, ((BufferObject *)(self))->buf); + posp = getmark(mark, FALSE); +! restore_buffer(savebuf); + + if (posp == NULL) + { +*** ../vim-7.3.962/src/window.c 2013-05-15 23:13:06.000000000 +0200 +--- src/window.c 2013-05-17 15:57:17.000000000 +0200 +*************** +*** 4058,4063 **** +--- 4058,4082 ---- + } + #endif + ++ #if (defined(FEAT_WINDOWS) && defined(FEAT_PYTHON)) || defined(PROTO) ++ /* ++ * Find the tabpage for window "win". ++ */ ++ tabpage_T * ++ win_find_tabpage(win) ++ win_T *win; ++ { ++ win_T *wp; ++ tabpage_T *tp; ++ ++ for (tp = first_tabpage; tp != NULL; tp = tp->tp_next) ++ for (wp = tp->tp_firstwin; wp != NULL; wp = wp->w_next) ++ if (wp == win) ++ return tp; ++ return NULL; ++ } ++ #endif ++ + #ifdef FEAT_VERTSPLIT + /* + * Move to window above or below "count" times. +*************** +*** 6550,6555 **** +--- 6569,6673 ---- + + #endif + ++ #if defined(FEAT_EVAL) || defined(PROTO) ++ /* ++ * Set "win" to be the curwin and "tp" to be the current tab page. ++ * restore_win() MUST be called to undo. ++ * No autocommands will be executed. ++ * Returns FAIL if switching to "win" failed. ++ */ ++ int ++ switch_win(save_curwin, save_curtab, win, tp) ++ win_T **save_curwin; ++ tabpage_T **save_curtab; ++ win_T *win; ++ tabpage_T *tp; ++ { ++ # ifdef FEAT_AUTOCMD ++ block_autocmds(); ++ # endif ++ # ifdef FEAT_WINDOWS ++ *save_curwin = curwin; ++ if (tp != NULL) ++ { ++ *save_curtab = curtab; ++ goto_tabpage_tp(tp, FALSE, FALSE); ++ } ++ if (!win_valid(win)) ++ { ++ # ifdef FEAT_AUTOCMD ++ unblock_autocmds(); ++ # endif ++ return FAIL; ++ } ++ curwin = win; ++ curbuf = curwin->w_buffer; ++ # endif ++ return OK; ++ } ++ ++ /* ++ * Restore current tabpage and window saved by switch_win(), if still valid. ++ */ ++ void ++ restore_win(save_curwin, save_curtab) ++ win_T *save_curwin; ++ tabpage_T *save_curtab; ++ { ++ # ifdef FEAT_WINDOWS ++ if (save_curtab != NULL && valid_tabpage(save_curtab)) ++ goto_tabpage_tp(save_curtab, FALSE, FALSE); ++ if (win_valid(save_curwin)) ++ { ++ curwin = save_curwin; ++ curbuf = curwin->w_buffer; ++ } ++ # endif ++ # ifdef FEAT_AUTOCMD ++ unblock_autocmds(); ++ # endif ++ } ++ ++ /* ++ * Make "buf" the current buffer. restore_buffer() MUST be called to undo. ++ * No autocommands will be executed. Use aucmd_prepbuf() if there are any. ++ */ ++ void ++ switch_buffer(save_curbuf, buf) ++ buf_T *buf; ++ buf_T **save_curbuf; ++ { ++ # ifdef FEAT_AUTOCMD ++ block_autocmds(); ++ # endif ++ *save_curbuf = curbuf; ++ --curbuf->b_nwindows; ++ curbuf = buf; ++ curwin->w_buffer = buf; ++ ++curbuf->b_nwindows; ++ } ++ ++ /* ++ * Restore the current buffer after using switch_buffer(). ++ */ ++ void ++ restore_buffer(save_curbuf) ++ buf_T *save_curbuf; ++ { ++ # ifdef FEAT_AUTOCMD ++ unblock_autocmds(); ++ # endif ++ /* Check for valid buffer, just in case. */ ++ if (buf_valid(save_curbuf)) ++ { ++ --curbuf->b_nwindows; ++ curwin->w_buffer = save_curbuf; ++ curbuf = save_curbuf; ++ ++curbuf->b_nwindows; ++ } ++ } ++ #endif ++ + #if (defined(FEAT_GUI) && defined(FEAT_VERTSPLIT)) || defined(PROTO) + /* + * Return TRUE if there is any vertically split window. +*** ../vim-7.3.962/src/testdir/test86.ok 2013-05-17 13:37:57.000000000 +0200 +--- src/testdir/test86.ok 2013-05-17 14:48:57.000000000 +0200 +*************** +*** 333,339 **** + Current tab pages: + (1): 1 windows, current is + Windows: +! (0): displays buffer ; cursor is at (955, 0) + (2): 1 windows, current is + Windows: + (0): displays buffer ; cursor is at (1, 0) +--- 333,339 ---- + Current tab pages: + (1): 1 windows, current is + Windows: +! (0): displays buffer ; cursor is at (954, 0) + (2): 1 windows, current is + Windows: + (0): displays buffer ; cursor is at (1, 0) +*** ../vim-7.3.962/src/version.c 2013-05-17 13:37:57.000000000 +0200 +--- src/version.c 2013-05-17 15:59:48.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 963, + /**/ + +-- +TIM: That is not an ordinary rabbit ... 'tis the most foul cruel and + bad-tempered thing you ever set eyes on. +ROBIN: You tit. I soiled my armour I was so scared! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 69032adff5cbab707db5f553cde9f8fc60f2c0fe Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:39 +0200 Subject: [PATCH 0863/3340] - patchlevel 964 --- 7.3.964 | 405 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 405 insertions(+) create mode 100644 7.3.964 diff --git a/7.3.964 b/7.3.964 new file mode 100644 index 00000000..e037ad7d --- /dev/null +++ b/7.3.964 @@ -0,0 +1,405 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.964 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.964 +Problem: Python: not so easy to access tab pages. +Solution: Add window.tabpage, make window.number work with non-current tab + pages. (ZyX) +Files: runtime/doc/if_pyth.txt, src/if_py_both.h, src/if_python3.c, + src/if_python.c, src/testdir/test86.ok, src/testdir/test87.ok + + +*** ../vim-7.3.963/runtime/doc/if_pyth.txt 2013-05-15 18:28:08.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-05-17 16:07:16.000000000 +0200 +*************** +*** 433,440 **** + This is zero in case it cannot be determined + (e.g. when the window object belongs to other + tab page). +! row, col (read-only) On-screen window position in display cells. + First position is zero. + + The height attribute is writable only if the screen is split horizontally. + The width attribute is writable only if the screen is split vertically. +--- 433,441 ---- + This is zero in case it cannot be determined + (e.g. when the window object belongs to other + tab page). +! row, col (read-only) On-screen window position in display cells. + First position is zero. ++ tabpage (read-only) Window tab page. + + The height attribute is writable only if the screen is split horizontally. + The width attribute is writable only if the screen is split vertically. +*************** +*** 490,496 **** + < *:py3file* + The |:py3file| command works similar to |:pyfile|. + +! *:py3do* + :[range]py3do {body} Execute Python function "def _vim_pydo(line, linenr): + {body}" for each line in the [range], with the + function arguments being set to the text of each line +--- 491,497 ---- + < *:py3file* + The |:py3file| command works similar to |:pyfile|. + +! *:py3do* *E863* + :[range]py3do {body} Execute Python function "def _vim_pydo(line, linenr): + {body}" for each line in the [range], with the + function arguments being set to the text of each line +*** ../vim-7.3.963/src/if_py_both.h 2013-05-17 16:03:53.000000000 +0200 +--- src/if_py_both.h 2013-05-17 16:07:16.000000000 +0200 +*************** +*** 31,36 **** +--- 31,39 ---- + + static int ConvertFromPyObject(PyObject *, typval_T *); + static int _ConvertFromPyObject(PyObject *, typval_T *, PyObject *); ++ static PyObject *WindowNew(win_T *, tabpage_T *); ++ static PyObject *BufferNew (buf_T *); ++ static PyObject *LineToString(const char *); + + static PyInt RangeStart; + static PyInt RangeEnd; +*************** +*** 1670,1678 **** + /* For current tab window.c does not bother to set or update tp_curwin + */ + if (this->tab == curtab) +! return WindowNew(curwin); + else +! return WindowNew(this->tab->tp_curwin); + } + return NULL; + } +--- 1673,1681 ---- + /* For current tab window.c does not bother to set or update tp_curwin + */ + if (this->tab == curtab) +! return WindowNew(curwin, curtab); + else +! return WindowNew(this->tab->tp_curwin, this->tab); + } + return NULL; + } +*************** +*** 1754,1759 **** +--- 1757,1763 ---- + { + PyObject_HEAD + win_T *win; ++ TabPageObject *tabObject; + } WindowObject; + + static PyTypeObject WindowType; +*************** +*** 1771,1777 **** + } + + static PyObject * +! WindowNew(win_T *win) + { + /* We need to handle deletion of windows underneath us. + * If we add a "w_python*_ref" field to the win_T structure, +--- 1775,1781 ---- + } + + static PyObject * +! WindowNew(win_T *win, tabpage_T *tab) + { + /* We need to handle deletion of windows underneath us. + * If we add a "w_python*_ref" field to the win_T structure, +*************** +*** 1804,1809 **** +--- 1808,1815 ---- + WIN_PYTHON_REF(win) = self; + } + ++ self->tabObject = ((TabPageObject *)(TabPageNew(tab))); ++ + return (PyObject *)(self); + } + +*************** +*** 1815,1823 **** +--- 1821,1849 ---- + if (this->win && this->win != INVALID_WINDOW_VALUE) + WIN_PYTHON_REF(this->win) = NULL; + ++ Py_DECREF(((PyObject *)(this->tabObject))); ++ + DESTRUCTOR_FINISH(self); + } + ++ static win_T * ++ get_firstwin(TabPageObject *tabObject) ++ { ++ if (tabObject) ++ { ++ if (CheckTabPage(tabObject)) ++ return NULL; ++ /* For current tab window.c does not bother to set or update tp_firstwin ++ */ ++ else if (tabObject->tab == curtab) ++ return firstwin; ++ else ++ return tabObject->tab->tp_firstwin; ++ } ++ else ++ return firstwin; ++ } ++ + static PyObject * + WindowAttr(WindowObject *this, char *name) + { +*************** +*** 1847,1856 **** + return OptionsNew(SREQ_WIN, this->win, (checkfun) CheckWindow, + (PyObject *) this); + else if (strcmp(name, "number") == 0) +! return PyLong_FromLong((long) get_win_number(this->win, firstwin)); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[ssssssss]", "buffer", "cursor", "height", "vars", +! "options", "number", "row", "col"); + else + return NULL; + } +--- 1873,1892 ---- + return OptionsNew(SREQ_WIN, this->win, (checkfun) CheckWindow, + (PyObject *) this); + else if (strcmp(name, "number") == 0) +! { +! if (CheckTabPage(this->tabObject)) +! return NULL; +! return PyLong_FromLong((long) +! get_win_number(this->win, get_firstwin(this->tabObject))); +! } +! else if (strcmp(name, "tabpage") == 0) +! { +! Py_INCREF(this->tabObject); +! return (PyObject *)(this->tabObject); +! } + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[sssssssss]", "buffer", "cursor", "height", +! "vars", "options", "number", "row", "col", "tabpage"); + else + return NULL; + } +*************** +*** 2016,2046 **** + DESTRUCTOR_FINISH(self); + } + +- static win_T * +- get_firstwin(WinListObject *this) +- { +- if (this->tabObject) +- { +- if (CheckTabPage(this->tabObject)) +- return NULL; +- /* For current tab window.c does not bother to set or update tp_firstwin +- */ +- else if (this->tabObject->tab == curtab) +- return firstwin; +- else +- return this->tabObject->tab->tp_firstwin; +- } +- else +- return firstwin; +- } +- + static PyInt + WinListLength(PyObject *self) + { + win_T *w; + PyInt n = 0; + +! if (!(w = get_firstwin((WinListObject *)(self)))) + return -1; + + while (w != NULL) +--- 2052,2064 ---- + DESTRUCTOR_FINISH(self); + } + + static PyInt + WinListLength(PyObject *self) + { + win_T *w; + PyInt n = 0; + +! if (!(w = get_firstwin(((WinListObject *)(self))->tabObject))) + return -1; + + while (w != NULL) +*************** +*** 2055,2068 **** + static PyObject * + WinListItem(PyObject *self, PyInt n) + { + win_T *w; + +! if (!(w = get_firstwin((WinListObject *)(self)))) + return NULL; + + for (; w != NULL; w = W_NEXT(w), --n) + if (n == 0) +! return WindowNew(w); + + PyErr_SetString(PyExc_IndexError, _("no such window")); + return NULL; +--- 2073,2087 ---- + static PyObject * + WinListItem(PyObject *self, PyInt n) + { ++ WinListObject *this = ((WinListObject *)(self)); + win_T *w; + +! if (!(w = get_firstwin(this->tabObject))) + return NULL; + + for (; w != NULL; w = W_NEXT(w), --n) + if (n == 0) +! return WindowNew(w, this->tabObject? this->tabObject->tab: curtab); + + PyErr_SetString(PyExc_IndexError, _("no such window")); + return NULL; +*************** +*** 3227,3233 **** + if (strcmp(name, "buffer") == 0) + return (PyObject *)BufferNew(curbuf); + else if (strcmp(name, "window") == 0) +! return (PyObject *)WindowNew(curwin); + else if (strcmp(name, "tabpage") == 0) + return (PyObject *)TabPageNew(curtab); + else if (strcmp(name, "line") == 0) +--- 3246,3252 ---- + if (strcmp(name, "buffer") == 0) + return (PyObject *)BufferNew(curbuf); + else if (strcmp(name, "window") == 0) +! return (PyObject *)WindowNew(curwin, curtab); + else if (strcmp(name, "tabpage") == 0) + return (PyObject *)TabPageNew(curtab); + else if (strcmp(name, "line") == 0) +*** ../vim-7.3.963/src/if_python3.c 2013-05-15 19:44:35.000000000 +0200 +--- src/if_python3.c 2013-05-17 16:07:16.000000000 +0200 +*************** +*** 611,619 **** + } + #endif /* DYNAMIC_PYTHON3 */ + +- static PyObject *BufferNew (buf_T *); +- static PyObject *WindowNew(win_T *); +- static PyObject *LineToString(const char *); + static PyObject *BufferDir(PyObject *, PyObject *); + + static int py3initialised = 0; +--- 611,616 ---- +*** ../vim-7.3.963/src/if_python.c 2013-05-15 17:49:00.000000000 +0200 +--- src/if_python.c 2013-05-17 16:07:16.000000000 +0200 +*************** +*** 610,620 **** + } + #endif /* DYNAMIC_PYTHON */ + +- static PyObject *BufferNew (buf_T *); +- static PyObject *WindowNew(win_T *); +- static PyObject *DictionaryNew(dict_T *); +- static PyObject *LineToString(const char *); +- + static int initialised = 0; + #define PYINITIALISED initialised + +--- 610,615 ---- +*** ../vim-7.3.963/src/testdir/test86.ok 2013-05-17 16:03:53.000000000 +0200 +--- src/testdir/test86.ok 2013-05-17 16:10:26.000000000 +0200 +*************** +*** 333,346 **** + Current tab pages: + (1): 1 windows, current is + Windows: +! (0): displays buffer ; cursor is at (954, 0) + (2): 1 windows, current is + Windows: +! (0): displays buffer ; cursor is at (1, 0) + (3): 2 windows, current is + Windows: +! (0): displays buffer ; cursor is at (1, 0) +! (0): displays buffer ; cursor is at (1, 0) + (4): 4 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +--- 333,346 ---- + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (954, 0) + (2): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (1, 0) + (3): 2 windows, current is + Windows: +! (1): displays buffer ; cursor is at (1, 0) +! (2): displays buffer ; cursor is at (1, 0) + (4): 4 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +*** ../vim-7.3.963/src/testdir/test87.ok 2013-05-17 13:37:57.000000000 +0200 +--- src/testdir/test87.ok 2013-05-17 16:07:16.000000000 +0200 +*************** +*** 322,335 **** + Current tab pages: + (1): 1 windows, current is + Windows: +! (0): displays buffer ; cursor is at (930, 0) + (2): 1 windows, current is + Windows: +! (0): displays buffer ; cursor is at (1, 0) + (3): 2 windows, current is + Windows: +! (0): displays buffer ; cursor is at (1, 0) +! (0): displays buffer ; cursor is at (1, 0) + (4): 4 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +--- 322,335 ---- + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (930, 0) + (2): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (1, 0) + (3): 2 windows, current is + Windows: +! (1): displays buffer ; cursor is at (1, 0) +! (2): displays buffer ; cursor is at (1, 0) + (4): 4 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +*** ../vim-7.3.963/src/version.c 2013-05-17 16:03:53.000000000 +0200 +--- src/version.c 2013-05-17 16:11:15.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 964, + /**/ + +-- +ARTHUR: Go on, Bors, chop its head off. +BORS: Right. Silly little bleeder. One rabbit stew coming up. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 98f57671195e3badbbbb4267d06b7b7e6fa2ba85 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:39 +0200 Subject: [PATCH 0864/3340] - patchlevel 965 --- 7.3.965 | 331 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 331 insertions(+) create mode 100644 7.3.965 diff --git a/7.3.965 b/7.3.965 new file mode 100644 index 00000000..cc2d676c --- /dev/null +++ b/7.3.965 @@ -0,0 +1,331 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.965 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.965 +Problem: Python garbage collection not working properly. +Solution: Add support for garbage collection. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.964/src/if_py_both.h 2013-05-17 16:18:27.000000000 +0200 +--- src/if_py_both.h 2013-05-17 16:21:05.000000000 +0200 +*************** +*** 543,548 **** +--- 543,550 ---- + + typedef PyObject *(*nextfun)(void **); + typedef void (*destructorfun)(void *); ++ typedef int (*traversefun)(void *, visitproc, void *); ++ typedef int (*clearfun)(void **); + + /* Main purpose of this object is removing the need for do python initialization + * (i.e. PyType_Ready and setting type attributes) for a big bunch of objects. +*************** +*** 554,563 **** + void *cur; + nextfun next; + destructorfun destruct; + } IterObject; + + static PyObject * +! IterNew(void *start, destructorfun destruct, nextfun next) + { + IterObject *self; + +--- 556,568 ---- + void *cur; + nextfun next; + destructorfun destruct; ++ traversefun traverse; ++ clearfun clear; + } IterObject; + + static PyObject * +! IterNew(void *start, destructorfun destruct, nextfun next, traversefun traverse, +! clearfun clear) + { + IterObject *self; + +*************** +*** 565,570 **** +--- 570,577 ---- + self->cur = start; + self->next = next; + self->destruct = destruct; ++ self->traverse = traverse; ++ self->clear = clear; + + return (PyObject *)(self); + } +*************** +*** 579,584 **** +--- 586,613 ---- + DESTRUCTOR_FINISH(self); + } + ++ static int ++ IterTraverse(PyObject *self, visitproc visit, void *arg) ++ { ++ IterObject *this = (IterObject *)(self); ++ ++ if (this->traverse != NULL) ++ return this->traverse(this->cur, visit, arg); ++ else ++ return 0; ++ } ++ ++ static int ++ IterClear(PyObject *self) ++ { ++ IterObject *this = (IterObject *)(self); ++ ++ if (this->clear != NULL) ++ return this->clear(&this->cur); ++ else ++ return 0; ++ } ++ + static PyObject * + IterNext(PyObject *self) + { +*************** +*** 1034,1040 **** + lii->list = l; + + return IterNew(lii, +! (destructorfun) ListIterDestruct, (nextfun) ListIterNext); + } + + static int +--- 1063,1070 ---- + lii->list = l; + + return IterNew(lii, +! (destructorfun) ListIterDestruct, (nextfun) ListIterNext, +! NULL, NULL); + } + + static int +*************** +*** 1348,1353 **** +--- 1378,1430 ---- + PyObject *fromObj; + } OptionsObject; + ++ static int ++ dummy_check(void *arg UNUSED) ++ { ++ return 0; ++ } ++ ++ static PyObject * ++ OptionsNew(int opt_type, void *from, checkfun Check, PyObject *fromObj) ++ { ++ OptionsObject *self; ++ ++ self = PyObject_NEW(OptionsObject, &OptionsType); ++ if (self == NULL) ++ return NULL; ++ ++ self->opt_type = opt_type; ++ self->from = from; ++ self->Check = Check; ++ self->fromObj = fromObj; ++ if (fromObj) ++ Py_INCREF(fromObj); ++ ++ return (PyObject *)(self); ++ } ++ ++ static void ++ OptionsDestructor(PyObject *self) ++ { ++ if (((OptionsObject *)(self))->fromObj) ++ Py_DECREF(((OptionsObject *)(self))->fromObj); ++ DESTRUCTOR_FINISH(self); ++ } ++ ++ static int ++ OptionsTraverse(PyObject *self, visitproc visit, void *arg) ++ { ++ Py_VISIT(((OptionsObject *)(self))->fromObj); ++ return 0; ++ } ++ ++ static int ++ OptionsClear(PyObject *self) ++ { ++ Py_CLEAR(((OptionsObject *)(self))->fromObj); ++ return 0; ++ } ++ + static PyObject * + OptionsItem(OptionsObject *this, PyObject *keyObject) + { +*************** +*** 1562,1600 **** + return r; + } + +- static int +- dummy_check(void *arg UNUSED) +- { +- return 0; +- } +- +- static PyObject * +- OptionsNew(int opt_type, void *from, checkfun Check, PyObject *fromObj) +- { +- OptionsObject *self; +- +- self = PyObject_NEW(OptionsObject, &OptionsType); +- if (self == NULL) +- return NULL; +- +- self->opt_type = opt_type; +- self->from = from; +- self->Check = Check; +- self->fromObj = fromObj; +- if (fromObj) +- Py_INCREF(fromObj); +- +- return (PyObject *)(self); +- } +- +- static void +- OptionsDestructor(PyObject *self) +- { +- if (((OptionsObject *)(self))->fromObj) +- Py_DECREF(((OptionsObject *)(self))->fromObj); +- DESTRUCTOR_FINISH(self); +- } +- + static PyMappingMethods OptionsAsMapping = { + (lenfunc) NULL, + (binaryfunc) OptionsItem, +--- 1639,1644 ---- +*************** +*** 1843,1848 **** +--- 1887,1905 ---- + else + return firstwin; + } ++ static int ++ WindowTraverse(PyObject *self, visitproc visit, void *arg) ++ { ++ Py_VISIT(((PyObject *)(((WindowObject *)(self))->tabObject))); ++ return 0; ++ } ++ ++ static int ++ WindowClear(PyObject *self) ++ { ++ Py_CLEAR((((WindowObject *)(self))->tabObject)); ++ return 0; ++ } + + static PyObject * + WindowAttr(WindowObject *this, char *name) +*************** +*** 3193,3198 **** +--- 3250,3269 ---- + } + } + ++ static int ++ BufMapIterTraverse(PyObject *buffer, visitproc visit, void *arg) ++ { ++ Py_VISIT(buffer); ++ return 0; ++ } ++ ++ static int ++ BufMapIterClear(PyObject **buffer) ++ { ++ Py_CLEAR(*buffer); ++ return 0; ++ } ++ + static PyObject * + BufMapIterNext(PyObject **buffer) + { +*************** +*** 3228,3234 **** + + buffer = BufferNew(firstbuf); + return IterNew(buffer, +! (destructorfun) BufMapIterDestruct, (nextfun) BufMapIterNext); + } + + static PyMappingMethods BufMapAsMapping = { +--- 3299,3306 ---- + + buffer = BufferNew(firstbuf); + return IterNew(buffer, +! (destructorfun) BufMapIterDestruct, (nextfun) BufMapIterNext, +! (traversefun) BufMapIterTraverse, (clearfun) BufMapIterClear); + } + + static PyMappingMethods BufMapAsMapping = { +*************** +*** 3837,3842 **** +--- 3909,3916 ---- + IterType.tp_iter = IterIter; + IterType.tp_iternext = IterNext; + IterType.tp_dealloc = IterDestructor; ++ IterType.tp_traverse = IterTraverse; ++ IterType.tp_clear = IterClear; + + vim_memset(&BufferType, 0, sizeof(BufferType)); + BufferType.tp_name = "vim.buffer"; +*************** +*** 3865,3870 **** +--- 3939,3946 ---- + WindowType.tp_flags = Py_TPFLAGS_DEFAULT; + WindowType.tp_doc = "vim Window object"; + WindowType.tp_methods = WindowMethods; ++ WindowType.tp_traverse = WindowTraverse; ++ WindowType.tp_clear = WindowClear; + #if PY_MAJOR_VERSION >= 3 + WindowType.tp_getattro = WindowGetattro; + WindowType.tp_setattro = WindowSetattro; +*************** +*** 4003,4008 **** +--- 4079,4086 ---- + OptionsType.tp_doc = "object for manipulating options"; + OptionsType.tp_as_mapping = &OptionsAsMapping; + OptionsType.tp_dealloc = OptionsDestructor; ++ OptionsType.tp_traverse = OptionsTraverse; ++ OptionsType.tp_clear = OptionsClear; + + #if PY_MAJOR_VERSION >= 3 + vim_memset(&vimmodule, 0, sizeof(vimmodule)); +*** ../vim-7.3.964/src/version.c 2013-05-17 16:18:27.000000000 +0200 +--- src/version.c 2013-05-17 16:21:24.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 965, + /**/ + +-- +ARTHUR: Charge! + [They all charge with swords drawn towards the RABBIT. A tremendous twenty + second fight with Peckinpahish shots and borrowing heavily also on the + Kung Fu and karate-type films ensues, in which some four KNIGHTS are + comprehensively killed.] +ARTHUR: Run away! Run away! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 193f84fb8c60efdc198756d3ac5883602022a44e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:40 +0200 Subject: [PATCH 0865/3340] - patchlevel 966 --- 7.3.966 | 301 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 301 insertions(+) create mode 100644 7.3.966 diff --git a/7.3.966 b/7.3.966 new file mode 100644 index 00000000..6dc69508 --- /dev/null +++ b/7.3.966 @@ -0,0 +1,301 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.966 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.966 +Problem: There is ":py3do" but no ":pydo". +Solution: Add the ":pydo" command. (Lilydjwg) +Files: runtime/doc/if_pyth.txt, src/ex_cmds.h, src/ex_docmd.c, + src/if_py_both.h, src/if_python.c, src/if_python3.c, + src/proto/if_python.pro + + +*** ../vim-7.3.965/runtime/doc/if_pyth.txt 2013-05-17 16:18:27.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-05-17 16:34:28.000000000 +0200 +*************** +*** 57,62 **** +--- 57,78 ---- + Note: Python is very sensitive to the indenting. Make sure the "class" line + and "EOF" do not have any indent. + ++ *:pydo* ++ :[range]pydo {body} Execute Python function "def _vim_pydo(line, linenr): ++ {body}" for each line in the [range], with the ++ function arguments being set to the text of each line ++ in turn, without a trailing , and the current ++ line number. The function should return a string or ++ None. If a string is returned, it becomes the text of ++ the line in the current turn. The default for [range] ++ is the whole file: "1,$". ++ {not in Vi} ++ ++ Examples: ++ > ++ :pydo return "%s\t%d" % (line[::-1], len(line)) ++ :pydo if line: return "%4d: %s" % (linenr, line) ++ < + *:pyfile* *:pyf* + :[range]pyf[ile] {file} + Execute the Python script in {file}. The whole +*************** +*** 485,511 **** + 8. Python 3 *python3* + + *:py3* *:python3* +! The |:py3| and |:python3| commands work similar to |:python|. A simple check + if the `:py3` command is working: > + :py3 print("Hello") + < *:py3file* +! The |:py3file| command works similar to |:pyfile|. +! + *:py3do* *E863* +! :[range]py3do {body} Execute Python function "def _vim_pydo(line, linenr): +! {body}" for each line in the [range], with the +! function arguments being set to the text of each line +! in turn, without a trailing , and the current +! line number. The function should return a string or +! None. If a string is returned, it becomes the text of +! the line in the current turn. The default for [range] +! is the whole file: "1,$". +! {not in Vi} + +- Examples: +- > +- :py3do return "%s\t%d" % (line[::-1], len(line)) +- :py3do if line: return "%4d: %s" % (linenr, line) + + Vim can be built in four ways (:version output): + 1. No Python support (-python, -python3) +--- 501,514 ---- + 8. Python 3 *python3* + + *:py3* *:python3* +! The `:py3` and `:python3` commands work similar to `:python`. A simple check + if the `:py3` command is working: > + :py3 print("Hello") + < *:py3file* +! The `:py3file` command works similar to `:pyfile`. + *:py3do* *E863* +! The `:py3do` command works similar to `:pydo`. + + + Vim can be built in four ways (:version output): + 1. No Python support (-python, -python3) +*** ../vim-7.3.965/src/ex_cmds.h 2013-05-15 18:28:08.000000000 +0200 +--- src/ex_cmds.h 2013-05-17 16:29:38.000000000 +0200 +*************** +*** 739,744 **** +--- 739,746 ---- + TRLBAR|CMDWIN), + EX(CMD_python, "python", ex_python, + RANGE|EXTRA|NEEDARG|CMDWIN), ++ EX(CMD_pydo, "pydo", ex_pydo, ++ RANGE|DFLALL|EXTRA|NEEDARG|CMDWIN), + EX(CMD_pyfile, "pyfile", ex_pyfile, + RANGE|FILE1|NEEDARG|CMDWIN), + EX(CMD_py3, "py3", ex_py3, +*** ../vim-7.3.965/src/ex_docmd.c 2013-05-15 18:28:08.000000000 +0200 +--- src/ex_docmd.c 2013-05-17 16:29:38.000000000 +0200 +*************** +*** 268,273 **** +--- 268,274 ---- + #endif + #ifndef FEAT_PYTHON + # define ex_python ex_script_ni ++ # define ex_pydo ex_ni + # define ex_pyfile ex_ni + #endif + #ifndef FEAT_PYTHON3 +*** ../vim-7.3.965/src/if_py_both.h 2013-05-17 16:24:27.000000000 +0200 +--- src/if_py_both.h 2013-05-17 16:29:38.000000000 +0200 +*************** +*** 22,27 **** +--- 22,28 ---- + #else + # define ENC_OPT "latin1" + #endif ++ #define DOPY_FUNC "_vim_pydo" + + #define PyErr_SetVim(str) PyErr_SetString(VimError, str) + +*** ../vim-7.3.965/src/if_python.c 2013-05-17 16:18:27.000000000 +0200 +--- src/if_python.c 2013-05-17 16:29:38.000000000 +0200 +*************** +*** 198,203 **** +--- 198,206 ---- + # define PyModule_GetDict dll_PyModule_GetDict + # define PyRun_SimpleString dll_PyRun_SimpleString + # define PyRun_String dll_PyRun_String ++ # define PyObject_GetAttrString dll_PyObject_GetAttrString ++ # define PyObject_SetAttrString dll_PyObject_SetAttrString ++ # define PyObject_CallFunctionObjArgs dll_PyObject_CallFunctionObjArgs + # define PyString_AsString dll_PyString_AsString + # define PyString_AsStringAndSize dll_PyString_AsStringAndSize + # define PyString_FromString dll_PyString_FromString +*************** +*** 303,308 **** +--- 306,314 ---- + static PyObject*(*dll_PyModule_GetDict)(PyObject *); + static int(*dll_PyRun_SimpleString)(char *); + static PyObject *(*dll_PyRun_String)(char *, int, PyObject *, PyObject *); ++ static PyObject* (*dll_PyObject_GetAttrString)(PyObject *, const char *); ++ static PyObject* (*dll_PyObject_SetAttrString)(PyObject *, const char *, PyObject *); ++ static PyObject* (*dll_PyObject_CallFunctionObjArgs)(PyObject *, ...); + static char*(*dll_PyString_AsString)(PyObject *); + static int(*dll_PyString_AsStringAndSize)(PyObject *, char **, int *); + static PyObject*(*dll_PyString_FromString)(const char *); +*************** +*** 440,445 **** +--- 446,454 ---- + {"PyModule_GetDict", (PYTHON_PROC*)&dll_PyModule_GetDict}, + {"PyRun_SimpleString", (PYTHON_PROC*)&dll_PyRun_SimpleString}, + {"PyRun_String", (PYTHON_PROC*)&dll_PyRun_String}, ++ {"PyObject_GetAttrString", (PYTHON_PROC*)&dll_PyObject_GetAttrString}, ++ {"PyObject_SetAttrString", (PYTHON_PROC*)&dll_PyObject_SetAttrString}, ++ {"PyObject_CallFunctionObjArgs", (PYTHON_PROC*)&dll_PyObject_CallFunctionObjArgs}, + {"PyString_AsString", (PYTHON_PROC*)&dll_PyString_AsString}, + {"PyString_AsStringAndSize", (PYTHON_PROC*)&dll_PyString_AsStringAndSize}, + {"PyString_FromString", (PYTHON_PROC*)&dll_PyString_FromString}, +*************** +*** 995,1000 **** +--- 1004,1096 ---- + DoPythonCommand(eap, buffer, NULL); + } + ++ void ++ ex_pydo(exarg_T *eap) ++ { ++ linenr_T i; ++ const char *code_hdr = "def " DOPY_FUNC "(line, linenr):\n "; ++ const char *s = (const char *) eap->arg; ++ size_t len; ++ char *code; ++ int status; ++ PyObject *pyfunc, *pymain; ++ PyGILState_STATE pygilstate; ++ ++ if (Python_Init()) ++ return; ++ ++ if (u_save(eap->line1 - 1, eap->line2 + 1) != OK) ++ { ++ EMSG(_("cannot save undo information")); ++ return; ++ } ++ len = strlen(code_hdr) + strlen(s); ++ code = malloc(len + 1); ++ STRCPY(code, code_hdr); ++ STRNCAT(code, s, len + 1); ++ pygilstate = PyGILState_Ensure(); ++ status = PyRun_SimpleString(code); ++ vim_free(code); ++ if (status) ++ { ++ EMSG(_("failed to run the code")); ++ return; ++ } ++ status = 0; /* good */ ++ pymain = PyImport_AddModule("__main__"); ++ pyfunc = PyObject_GetAttrString(pymain, DOPY_FUNC); ++ PyGILState_Release(pygilstate); ++ ++ for (i = eap->line1; i <= eap->line2; i++) ++ { ++ const char *line; ++ PyObject *pyline, *pylinenr, *pyret; ++ ++ line = (char *)ml_get(i); ++ pygilstate = PyGILState_Ensure(); ++ pyline = PyString_FromStringAndSize(line, strlen(line)); ++ pylinenr = PyLong_FromLong(i); ++ pyret = PyObject_CallFunctionObjArgs(pyfunc, pyline, pylinenr, NULL); ++ Py_DECREF(pyline); ++ Py_DECREF(pylinenr); ++ if (!pyret) ++ { ++ PyErr_PrintEx(0); ++ PythonIO_Flush(); ++ status = 1; ++ goto out; ++ } ++ ++ if (pyret && pyret != Py_None) ++ { ++ if (!PyString_Check(pyret)) ++ { ++ EMSG(_("E863: return value must be an instance of str")); ++ Py_XDECREF(pyret); ++ status = 1; ++ goto out; ++ } ++ ml_replace(i, (char_u *) PyString_AsString(pyret), 1); ++ changed(); ++ #ifdef SYNTAX_HL ++ syn_changed(i); /* recompute syntax hl. for this line */ ++ #endif ++ } ++ Py_XDECREF(pyret); ++ PythonIO_Flush(); ++ PyGILState_Release(pygilstate); ++ } ++ pygilstate = PyGILState_Ensure(); ++ out: ++ Py_DECREF(pyfunc); ++ PyObject_SetAttrString(pymain, DOPY_FUNC, NULL); ++ PyGILState_Release(pygilstate); ++ if (status) ++ return; ++ check_cursor(); ++ update_curbuf(NOT_VALID); ++ } ++ + /****************************************************** + * 2. Python output stream: writes output via [e]msg(). + */ +*** ../vim-7.3.965/src/if_python3.c 2013-05-17 16:18:27.000000000 +0200 +--- src/if_python3.c 2013-05-17 16:29:38.000000000 +0200 +*************** +*** 76,82 **** + #else + # define CODEC_ERROR_HANDLER NULL + #endif +- #define DOPY_FUNC "_vim_pydo" + + /* Python 3 does not support CObjects, always use Capsules */ + #define PY_USE_CAPSULE +--- 76,81 ---- +*** ../vim-7.3.965/src/proto/if_python.pro 2013-05-15 15:12:25.000000000 +0200 +--- src/proto/if_python.pro 2013-05-17 16:29:38.000000000 +0200 +*************** +*** 3,8 **** +--- 3,9 ---- + void python_end __ARGS((void)); + int python_loaded __ARGS((void)); + void ex_python __ARGS((exarg_T *eap)); ++ void ex_pydo __ARGS((exarg_T *eap)); + void ex_pyfile __ARGS((exarg_T *eap)); + void python_buffer_free __ARGS((buf_T *buf)); + void python_window_free __ARGS((win_T *win)); +*** ../vim-7.3.965/src/version.c 2013-05-17 16:24:27.000000000 +0200 +--- src/version.c 2013-05-17 16:39:19.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 966, + /**/ + +-- +A hamburger walks into a bar, and the bartender says: "I'm sorry, +but we don't serve food here." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 857924af1461994da938853800a3b11221ddd254 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:41 +0200 Subject: [PATCH 0866/3340] - patchlevel 967 --- 7.3.967 | 112 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 112 insertions(+) create mode 100644 7.3.967 diff --git a/7.3.967 b/7.3.967 new file mode 100644 index 00000000..39c67dda --- /dev/null +++ b/7.3.967 @@ -0,0 +1,112 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.9 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.967 (after 7.3.965) +Problem: Build fails on Mac OSX. (Greg Novack) +Solution: Undefine clear(). +Files: src/if_py_both.h + + +*** ../vim-7.3.966/src/if_py_both.h 2013-05-17 16:39:59.000000000 +0200 +--- src/if_py_both.h 2013-05-17 20:40:47.000000000 +0200 +*************** +*** 474,480 **** + static PyObject *ConvertToPyObject(typval_T *); + + static PyObject * +! VimEvalPy(PyObject *self UNUSED, PyObject *args UNUSED) + { + char *expr; + typval_T *our_tv; +--- 474,480 ---- + static PyObject *ConvertToPyObject(typval_T *); + + static PyObject * +! VimEvalPy(PyObject *self UNUSED, PyObject *args) + { + char *expr; + typval_T *our_tv; +*************** +*** 547,555 **** + typedef int (*traversefun)(void *, visitproc, void *); + typedef int (*clearfun)(void **); + +! /* Main purpose of this object is removing the need for do python initialization +! * (i.e. PyType_Ready and setting type attributes) for a big bunch of objects. +! */ + + typedef struct + { +--- 547,555 ---- + typedef int (*traversefun)(void *, visitproc, void *); + typedef int (*clearfun)(void **); + +! /* Main purpose of this object is removing the need for do python +! * initialization (i.e. PyType_Ready and setting type attributes) for a big +! * bunch of objects. */ + + typedef struct + { +*************** +*** 598,603 **** +--- 598,608 ---- + return 0; + } + ++ /* Mac OSX defines clear() somewhere. */ ++ #ifdef clear ++ # undef clear ++ #endif ++ + static int + IterClear(PyObject *self) + { +*************** +*** 3287,3295 **** + else if (!(next = BufferNew(((BufferObject *)(r))->buf->b_next))) + return NULL; + *buffer = next; +! /* Do not increment reference: we no longer hold it (decref), but whoever on +! * other side will hold (incref). Decref+incref = nothing. +! */ + return r; + } + +--- 3292,3299 ---- + else if (!(next = BufferNew(((BufferObject *)(r))->buf->b_next))) + return NULL; + *buffer = next; +! /* Do not increment reference: we no longer hold it (decref), but whoever +! * on other side will hold (incref). Decref+incref = nothing. */ + return r; + } + +*** ../vim-7.3.966/src/version.c 2013-05-17 16:39:59.000000000 +0200 +--- src/version.c 2013-05-17 21:19:17.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 967, + /**/ + +-- +ARTHUR: What does it say? +BROTHER MAYNARD: It reads ... "Here may be found the last words of Joseph of + Aramathea." "He who is valorous and pure of heart may find + the Holy Grail in the aaaaarrrrrrggghhh..." +ARTHUR: What? +BROTHER MAYNARD: "The Aaaaarrrrrrggghhh..." + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 07869a3d350877d1356689c9d5fceb179eb79d18 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:41 +0200 Subject: [PATCH 0867/3340] - patchlevel 968 --- 7.3.968 | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.968 diff --git a/7.3.968 b/7.3.968 new file mode 100644 index 00000000..be175413 --- /dev/null +++ b/7.3.968 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.968 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.968 +Problem: Multi-byte support is only available when compiled with "big" + features. +Solution: Include multi-byte by default, with "normal" features. +Files: src/feature.h + + +*** ../vim-7.3.967/src/feature.h 2013-05-06 04:21:35.000000000 +0200 +--- src/feature.h 2013-05-18 20:18:20.000000000 +0200 +*************** +*** 638,644 **** + * Disabled for EBCDIC: + * Multibyte support doesn't work on z/OS Unix currently. + */ +! #if (defined(FEAT_BIG) || defined(FEAT_GUI_GTK) || defined(FEAT_ARABIC)) \ + && !defined(FEAT_MBYTE) && !defined(WIN16) \ + && SIZEOF_INT >= 4 && !defined(EBCDIC) + # define FEAT_MBYTE +--- 638,644 ---- + * Disabled for EBCDIC: + * Multibyte support doesn't work on z/OS Unix currently. + */ +! #if (defined(FEAT_NORMAL) || defined(FEAT_GUI_GTK) || defined(FEAT_ARABIC)) \ + && !defined(FEAT_MBYTE) && !defined(WIN16) \ + && SIZEOF_INT >= 4 && !defined(EBCDIC) + # define FEAT_MBYTE +*** ../vim-7.3.967/src/version.c 2013-05-17 21:20:13.000000000 +0200 +--- src/version.c 2013-05-18 20:21:19.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 968, + /**/ + +-- +VOICE OVER: As the horrendous Black Beast lunged forward, escape for Arthur + and his knights seemed hopeless, when, suddenly ... the animator + suffered a fatal heart attack. +ANIMATOR: Aaaaagh! +VOICE OVER: The cartoon peril was no more ... The Quest for Holy Grail could + continue. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0fb6431c259da9023a141dd5ad06bfc1c0bcf459 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:42 +0200 Subject: [PATCH 0868/3340] - patchlevel 969 --- 7.3.969 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.969 diff --git a/7.3.969 b/7.3.969 new file mode 100644 index 00000000..8dc47c7a --- /dev/null +++ b/7.3.969 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.969 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.969 +Problem: Can't built with Python 3 and without Python 2. +Solution: Adjust #ifdef. (Xavier de Gaye) +Files: src/window.c + + +*** ../vim-7.3.968/src/window.c 2013-05-17 16:03:53.000000000 +0200 +--- src/window.c 2013-05-18 20:53:21.000000000 +0200 +*************** +*** 4058,4064 **** + } + #endif + +! #if (defined(FEAT_WINDOWS) && defined(FEAT_PYTHON)) || defined(PROTO) + /* + * Find the tabpage for window "win". + */ +--- 4058,4065 ---- + } + #endif + +! #if (defined(FEAT_WINDOWS) && (defined(FEAT_PYTHON) || defined(FEAT_PYTHON3))) \ +! || defined(PROTO) + /* + * Find the tabpage for window "win". + */ +*** ../vim-7.3.968/src/version.c 2013-05-18 20:45:51.000000000 +0200 +--- src/version.c 2013-05-18 20:54:16.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 969, + /**/ + +-- +ROBIN: (warily) And if you get a question wrong? +ARTHUR: You are cast into the Gorge of Eternal Peril. +ROBIN: Oh ... wacho! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f66dc1a2e7861bdf362a19aeaabea828e9481f1e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:43 +0200 Subject: [PATCH 0869/3340] - patchlevel 970 --- 7.3.970 | 6775 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 6775 insertions(+) create mode 100644 7.3.970 diff --git a/7.3.970 b/7.3.970 new file mode 100644 index 00000000..5b74a5e2 --- /dev/null +++ b/7.3.970 @@ -0,0 +1,6775 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.970 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.970 +Problem: Syntax highlighting can be slow. +Solution: Include the NFA regexp engine. Add the 'regexpengine' option to + select which one is used. (various authors, including Ken Takata, + Andrei Aiordachioaie, Russ Cox, Xiaozhou Liua, Ian Young) +Files: src/Make_cyg.mak, src/Make_ming.mak, src/Make_mvc.mak, + src/Makefile, src/regexp.c, src/regexp.h, src/regexp_nfa.c, + src/structs.h, src/testdir/Makefile, src/testdir/test64.in, + src/testdir/test64.ok, Filelist, runtime/doc/pattern.txt, + runtime/doc/option.txt, src/option.c, src/option.h, + src/testdir/test95.in, src/testdir/test95.ok, + src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak, + src/testdir/Make_ming.mak, src/testdir/Make_os2.mak, + src/testdir/Make_vms.mms, src/testdir/Makefile + + +*** ../vim-7.3.969/src/Make_cyg.mak 2013-05-06 04:21:35.000000000 +0200 +--- src/Make_cyg.mak 2013-05-17 18:54:19.000000000 +0200 +*************** +*** 672,677 **** +--- 672,680 ---- + $(OUTDIR)/netbeans.o: netbeans.c $(INCL) $(NBDEBUG_DEP) + $(CC) -c $(CFLAGS) netbeans.c -o $(OUTDIR)/netbeans.o + ++ $(OUTDIR)/regexp.o: regexp.c regexp_nfa.c $(INCL) ++ $(CC) -c $(CFLAGS) regexp.c -o $(OUTDIR)/regexp.o ++ + $(OUTDIR)/if_mzsch.o: if_mzsch.c $(INCL) if_mzsch.h $(MZ_EXTRA_DEP) + $(CC) -c $(CFLAGS) if_mzsch.c -o $(OUTDIR)/if_mzsch.o + +*** ../vim-7.3.969/src/Make_ming.mak 2013-03-07 15:16:16.000000000 +0100 +--- src/Make_ming.mak 2013-05-17 18:54:19.000000000 +0200 +*************** +*** 765,770 **** +--- 765,773 ---- + $(OUTDIR)/netbeans.o: netbeans.c $(INCL) $(NBDEBUG_INCL) $(NBDEBUG_SRC) + $(CC) -c $(CFLAGS) netbeans.c -o $(OUTDIR)/netbeans.o + ++ $(OUTDIR)/regexp.o: regexp.c regexp_nfa.c $(INCL) ++ $(CC) -c $(CFLAGS) regexp.c -o $(OUTDIR)/regexp.o ++ + $(OUTDIR)/if_mzsch.o: if_mzsch.c $(INCL) if_mzsch.h $(MZ_EXTRA_DEP) + $(CC) -c $(CFLAGS) if_mzsch.c -o $(OUTDIR)/if_mzsch.o + +*** ../vim-7.3.969/src/Make_mvc.mak 2013-05-07 05:11:12.000000000 +0200 +--- src/Make_mvc.mak 2013-05-19 16:38:29.000000000 +0200 +*************** +*** 1166,1172 **** + + $(OUTDIR)/quickfix.obj: $(OUTDIR) quickfix.c $(INCL) + +! $(OUTDIR)/regexp.obj: $(OUTDIR) regexp.c $(INCL) + + $(OUTDIR)/screen.obj: $(OUTDIR) screen.c $(INCL) + +--- 1173,1179 ---- + + $(OUTDIR)/quickfix.obj: $(OUTDIR) quickfix.c $(INCL) + +! $(OUTDIR)/regexp.obj: $(OUTDIR) regexp.c regexp_nfa.c $(INCL) + + $(OUTDIR)/screen.obj: $(OUTDIR) screen.c $(INCL) + +*** ../vim-7.3.969/src/Makefile 2013-05-06 04:21:35.000000000 +0200 +--- src/Makefile 2013-05-18 23:42:30.000000000 +0200 +*************** +*** 454,460 **** + + # MULTIBYTE - To edit multi-byte characters. + # Uncomment this when you want to edit a multibyte language. +! # It's automatically enabled with big features or IME support. + # Note: Compile on a machine where setlocale() actually works, otherwise the + # configure tests may fail. + #CONF_OPT_MULTIBYTE = --enable-multibyte +--- 454,460 ---- + + # MULTIBYTE - To edit multi-byte characters. + # Uncomment this when you want to edit a multibyte language. +! # It's automatically enabled with normal features, GTK or IME support. + # Note: Compile on a machine where setlocale() actually works, otherwise the + # configure tests may fail. + #CONF_OPT_MULTIBYTE = --enable-multibyte +*************** +*** 2664,2670 **** + objects/quickfix.o: quickfix.c + $(CCC) -o $@ quickfix.c + +! objects/regexp.o: regexp.c + $(CCC) -o $@ regexp.c + + objects/screen.o: screen.c +--- 2664,2670 ---- + objects/quickfix.o: quickfix.c + $(CCC) -o $@ quickfix.c + +! objects/regexp.o: regexp.c regexp_nfa.c + $(CCC) -o $@ regexp.c + + objects/screen.o: screen.c +*************** +*** 2938,2947 **** + auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \ + regexp.h gui.h gui_beval.h proto/gui_beval.pro ex_cmds.h proto.h \ + globals.h farsi.h arabic.h +! objects/regexp.o: regexp.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \ +! ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \ +! gui_beval.h proto/gui_beval.pro ex_cmds.h proto.h globals.h farsi.h \ +! arabic.h + objects/screen.o: screen.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \ + ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \ + gui_beval.h proto/gui_beval.pro ex_cmds.h proto.h globals.h farsi.h \ +--- 2938,2947 ---- + auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \ + regexp.h gui.h gui_beval.h proto/gui_beval.pro ex_cmds.h proto.h \ + globals.h farsi.h arabic.h +! objects/regexp.o: regexp.c regexp_nfa.c vim.h auto/config.h feature.h os_unix.h \ +! auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \ +! regexp.h gui.h gui_beval.h proto/gui_beval.pro ex_cmds.h proto.h \ +! globals.h farsi.h arabic.h + objects/screen.o: screen.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \ + ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \ + gui_beval.h proto/gui_beval.pro ex_cmds.h proto.h globals.h farsi.h \ +*** ../vim-7.3.969/src/regexp.c 2013-03-19 17:42:10.000000000 +0100 +--- src/regexp.c 2013-05-18 19:47:06.000000000 +0200 +*************** +*** 38,46 **** + * Named character class support added by Walter Briscoe (1998 Jul 01) + */ + + #include "vim.h" + +! #undef DEBUG + + /* + * The "internal use only" fields in regexp.h are present to pass info from +--- 38,57 ---- + * Named character class support added by Walter Briscoe (1998 Jul 01) + */ + ++ /* Uncomment the first if you do not want to see debugging logs or files ++ * related to regular expressions, even when compiling with -DDEBUG. ++ * Uncomment the second to get the regexp debugging. */ ++ /* #undef DEBUG */ ++ /* #define DEBUG */ ++ + #include "vim.h" + +! #ifdef DEBUG +! /* show/save debugging data when BT engine is used */ +! # define BT_REGEXP_DUMP +! /* save the debugging data to a file instead of displaying it */ +! # define BT_REGEXP_LOG +! #endif + + /* + * The "internal use only" fields in regexp.h are present to pass info from +*************** +*** 326,334 **** + /* Used for an error (down from) vim_regcomp(): give the error message, set + * rc_did_emsg and return NULL */ + #define EMSG_RET_NULL(m) return (EMSG(m), rc_did_emsg = TRUE, (void *)NULL) +- #define EMSG_M_RET_NULL(m, c) return (EMSG2((m), (c) ? "" : "\\"), rc_did_emsg = TRUE, (void *)NULL) + #define EMSG_RET_FAIL(m) return (EMSG(m), rc_did_emsg = TRUE, FAIL) +! #define EMSG_ONE_RET_NULL EMSG_M_RET_NULL(_("E369: invalid item in %s%%[]"), reg_magic == MAGIC_ALL) + + #define MAX_LIMIT (32767L << 16L) + +--- 337,346 ---- + /* Used for an error (down from) vim_regcomp(): give the error message, set + * rc_did_emsg and return NULL */ + #define EMSG_RET_NULL(m) return (EMSG(m), rc_did_emsg = TRUE, (void *)NULL) + #define EMSG_RET_FAIL(m) return (EMSG(m), rc_did_emsg = TRUE, FAIL) +! #define EMSG2_RET_NULL(m, c) return (EMSG2((m), (c) ? "" : "\\"), rc_did_emsg = TRUE, (void *)NULL) +! #define EMSG2_RET_FAIL(m, c) return (EMSG2((m), (c) ? "" : "\\"), rc_did_emsg = TRUE, FAIL) +! #define EMSG_ONE_RET_NULL EMSG2_RET_NULL(_("E369: invalid item in %s%%[]"), reg_magic == MAGIC_ALL) + + #define MAX_LIMIT (32767L << 16L) + +*************** +*** 336,346 **** + static int cstrncmp __ARGS((char_u *s1, char_u *s2, int *n)); + static char_u *cstrchr __ARGS((char_u *, int)); + + #ifdef DEBUG +- static void regdump __ARGS((char_u *, regprog_T *)); + static char_u *regprop __ARGS((char_u *)); + #endif + + #define NOT_MULTI 0 + #define MULTI_ONE 1 + #define MULTI_MULT 2 +--- 348,365 ---- + static int cstrncmp __ARGS((char_u *s1, char_u *s2, int *n)); + static char_u *cstrchr __ARGS((char_u *, int)); + ++ #ifdef BT_REGEXP_DUMP ++ static void regdump __ARGS((char_u *, bt_regprog_T *)); ++ #endif + #ifdef DEBUG + static char_u *regprop __ARGS((char_u *)); + #endif + ++ static char_u e_missingbracket[] = N_("E769: Missing ] after %s["); ++ static char_u e_unmatchedpp[] = N_("E53: Unmatched %s%%("); ++ static char_u e_unmatchedp[] = N_("E54: Unmatched %s("); ++ static char_u e_unmatchedpar[] = N_("E55: Unmatched %s)"); ++ + #define NOT_MULTI 0 + #define MULTI_ONE 1 + #define MULTI_MULT 2 +*************** +*** 630,636 **** + }; + #endif + +! static int curchr; + + /* arguments for reg() */ + #define REG_NOPAREN 0 /* toplevel reg() */ +--- 649,661 ---- + }; + #endif + +! static int curchr; /* currently parsed character */ +! /* Previous character. Note: prevchr is sometimes -1 when we are not at the +! * start, eg in /[ ^I]^ the pattern was never found even if it existed, +! * because ^ was taken to be magic -- webb */ +! static int prevchr; +! static int prevprevchr; /* previous-previous character */ +! static int nextchr; /* used for ungetchr() */ + + /* arguments for reg() */ + #define REG_NOPAREN 0 /* toplevel reg() */ +*************** +*** 680,685 **** +--- 705,713 ---- + static void regtail __ARGS((char_u *, char_u *)); + static void regoptail __ARGS((char_u *, char_u *)); + ++ static regengine_T bt_regengine; ++ static regengine_T nfa_regengine; ++ + /* + * Return TRUE if compiled regular expression "prog" can match a line break. + */ +*************** +*** 762,767 **** +--- 790,796 ---- + /* + * Produce the bytes for equivalence class "c". + * Currently only handles latin1, latin9 and utf-8. ++ * NOTE: When changing this function, also change nfa_emit_equi_class() + */ + static void + reg_equi_class(c) +*************** +*** 1239,1246 **** + return p; + } + + /* +! * vim_regcomp() - compile a regular expression into internal code + * Returns the program in allocated space. Returns NULL for an error. + * + * We can't allocate space until we know how big the compiled form will be, +--- 1268,1278 ---- + return p; + } + ++ static regprog_T *bt_regcomp __ARGS((char_u *expr, int re_flags)); ++ + /* +! * bt_regcomp() - compile a regular expression into internal code for the +! * traditional back track matcher. + * Returns the program in allocated space. Returns NULL for an error. + * + * We can't allocate space until we know how big the compiled form will be, +*************** +*** 1259,1270 **** + * of the structure of the compiled regexp. + * "re_flags": RE_MAGIC and/or RE_STRING. + */ +! regprog_T * +! vim_regcomp(expr, re_flags) + char_u *expr; + int re_flags; + { +! regprog_T *r; + char_u *scan; + char_u *longest; + int len; +--- 1291,1302 ---- + * of the structure of the compiled regexp. + * "re_flags": RE_MAGIC and/or RE_STRING. + */ +! static regprog_T * +! bt_regcomp(expr, re_flags) + char_u *expr; + int re_flags; + { +! bt_regprog_T *r; + char_u *scan; + char_u *longest; + int len; +*************** +*** 1291,1297 **** + #endif + + /* Allocate space. */ +! r = (regprog_T *)lalloc(sizeof(regprog_T) + regsize, TRUE); + if (r == NULL) + return NULL; + +--- 1323,1329 ---- + #endif + + /* Allocate space. */ +! r = (bt_regprog_T *)lalloc(sizeof(bt_regprog_T) + regsize, TRUE); + if (r == NULL) + return NULL; + +*************** +*** 1386,1395 **** + r->regmlen = len; + } + } +! #ifdef DEBUG + regdump(expr, r); + #endif +! return r; + } + + /* +--- 1418,1428 ---- + r->regmlen = len; + } + } +! #ifdef BT_REGEXP_DUMP + regdump(expr, r); + #endif +! r->engine = &bt_regengine; +! return (regprog_T *)r; + } + + /* +*************** +*** 1436,1442 **** + #endif + + /* +! * reg - regular expression, i.e. main body or parenthesized thing + * + * Caller must absorb opening parenthesis. + * +--- 1469,1475 ---- + #endif + + /* +! * Parse regular expression, i.e. main body or parenthesized thing. + * + * Caller must absorb opening parenthesis. + * +*************** +*** 1473,1479 **** + { + /* Make a MOPEN node. */ + if (regnpar >= NSUBEXP) +! EMSG_M_RET_NULL(_("E51: Too many %s("), reg_magic == MAGIC_ALL); + parno = regnpar; + ++regnpar; + ret = regnode(MOPEN + parno); +--- 1506,1512 ---- + { + /* Make a MOPEN node. */ + if (regnpar >= NSUBEXP) +! EMSG2_RET_NULL(_("E51: Too many %s("), reg_magic == MAGIC_ALL); + parno = regnpar; + ++regnpar; + ret = regnode(MOPEN + parno); +*************** +*** 1534,1547 **** + else + #endif + if (paren == REG_NPAREN) +! EMSG_M_RET_NULL(_("E53: Unmatched %s%%("), reg_magic == MAGIC_ALL); + else +! EMSG_M_RET_NULL(_("E54: Unmatched %s("), reg_magic == MAGIC_ALL); + } + else if (paren == REG_NOPAREN && peekchr() != NUL) + { + if (curchr == Magic(')')) +! EMSG_M_RET_NULL(_("E55: Unmatched %s)"), reg_magic == MAGIC_ALL); + else + EMSG_RET_NULL(_(e_trailing)); /* "Can't happen". */ + /* NOTREACHED */ +--- 1567,1580 ---- + else + #endif + if (paren == REG_NPAREN) +! EMSG2_RET_NULL(_(e_unmatchedpp), reg_magic == MAGIC_ALL); + else +! EMSG2_RET_NULL(_(e_unmatchedp), reg_magic == MAGIC_ALL); + } + else if (paren == REG_NOPAREN && peekchr() != NUL) + { + if (curchr == Magic(')')) +! EMSG2_RET_NULL(_(e_unmatchedpar), reg_magic == MAGIC_ALL); + else + EMSG_RET_NULL(_(e_trailing)); /* "Can't happen". */ + /* NOTREACHED */ +*************** +*** 1556,1562 **** + } + + /* +! * Handle one alternative of an | operator. + * Implements the & operator. + */ + static char_u * +--- 1589,1595 ---- + } + + /* +! * Parse one alternative of an | operator. + * Implements the & operator. + */ + static char_u * +*************** +*** 1599,1605 **** + } + + /* +! * Handle one alternative of an | or & operator. + * Implements the concatenation operator. + */ + static char_u * +--- 1632,1638 ---- + } + + /* +! * Parse one alternative of an | or & operator. + * Implements the concatenation operator. + */ + static char_u * +*************** +*** 1679,1685 **** + } + + /* +! * regpiece - something followed by possible [*+=] + * + * Note that the branching code sequences used for = and the general cases + * of * and + are somewhat optimized: they use the same NOTHING node as +--- 1712,1718 ---- + } + + /* +! * Parse something followed by possible [*+=]. + * + * Note that the branching code sequences used for = and the general cases + * of * and + are somewhat optimized: they use the same NOTHING node as +*************** +*** 1759,1765 **** + } + } + if (lop == END) +! EMSG_M_RET_NULL(_("E59: invalid character after %s@"), + reg_magic == MAGIC_ALL); + /* Look behind must match with behind_pos. */ + if (lop == BEHIND || lop == NOBEHIND) +--- 1792,1798 ---- + } + } + if (lop == END) +! EMSG2_RET_NULL(_("E59: invalid character after %s@"), + reg_magic == MAGIC_ALL); + /* Look behind must match with behind_pos. */ + if (lop == BEHIND || lop == NOBEHIND) +*************** +*** 1793,1799 **** + else + { + if (num_complex_braces >= 10) +! EMSG_M_RET_NULL(_("E60: Too many complex %s{...}s"), + reg_magic == MAGIC_ALL); + reginsert(BRACE_COMPLEX + num_complex_braces, ret); + regoptail(ret, regnode(BACK)); +--- 1826,1832 ---- + else + { + if (num_complex_braces >= 10) +! EMSG2_RET_NULL(_("E60: Too many complex %s{...}s"), + reg_magic == MAGIC_ALL); + reginsert(BRACE_COMPLEX + num_complex_braces, ret); + regoptail(ret, regnode(BACK)); +*************** +*** 1820,1827 **** + return ret; + } + + /* +! * regatom - the lowest level + * + * Optimization: gobbles an entire sequence of ordinary characters so that + * it can turn them into a single node, which is smaller to store and +--- 1853,1872 ---- + return ret; + } + ++ /* When making changes to classchars also change nfa_classcodes. */ ++ static char_u *classchars = (char_u *)".iIkKfFpPsSdDxXoOwWhHaAlLuU"; ++ static int classcodes[] = { ++ ANY, IDENT, SIDENT, KWORD, SKWORD, ++ FNAME, SFNAME, PRINT, SPRINT, ++ WHITE, NWHITE, DIGIT, NDIGIT, ++ HEX, NHEX, OCTAL, NOCTAL, ++ WORD, NWORD, HEAD, NHEAD, ++ ALPHA, NALPHA, LOWER, NLOWER, ++ UPPER, NUPPER ++ }; ++ + /* +! * Parse the lowest level. + * + * Optimization: gobbles an entire sequence of ordinary characters so that + * it can turn them into a single node, which is smaller to store and +*************** +*** 1836,1850 **** + int cpo_lit; /* 'cpoptions' contains 'l' flag */ + int cpo_bsl; /* 'cpoptions' contains '\' flag */ + int c; +- static char_u *classchars = (char_u *)".iIkKfFpPsSdDxXoOwWhHaAlLuU"; +- static int classcodes[] = {ANY, IDENT, SIDENT, KWORD, SKWORD, +- FNAME, SFNAME, PRINT, SPRINT, +- WHITE, NWHITE, DIGIT, NDIGIT, +- HEX, NHEX, OCTAL, NOCTAL, +- WORD, NWORD, HEAD, NHEAD, +- ALPHA, NALPHA, LOWER, NLOWER, +- UPPER, NUPPER +- }; + char_u *p; + int extra = 0; + +--- 1881,1886 ---- +*************** +*** 2140,2146 **** + while ((c = getchr()) != ']') + { + if (c == NUL) +! EMSG_M_RET_NULL(_("E69: Missing ] after %s%%["), + reg_magic == MAGIC_ALL); + br = regnode(BRANCH); + if (ret == NULL) +--- 2176,2182 ---- + while ((c = getchr()) != ']') + { + if (c == NUL) +! EMSG2_RET_NULL(_("E69: Missing ] after %s%%["), + reg_magic == MAGIC_ALL); + br = regnode(BRANCH); + if (ret == NULL) +*************** +*** 2156,2162 **** + return NULL; + } + if (ret == NULL) +! EMSG_M_RET_NULL(_("E70: Empty %s%%[]"), + reg_magic == MAGIC_ALL); + lastbranch = regnode(BRANCH); + br = regnode(NOTHING); +--- 2192,2198 ---- + return NULL; + } + if (ret == NULL) +! EMSG2_RET_NULL(_("E70: Empty %s%%[]"), + reg_magic == MAGIC_ALL); + lastbranch = regnode(BRANCH); + br = regnode(NOTHING); +*************** +*** 2200,2206 **** + } + + if (i < 0) +! EMSG_M_RET_NULL( + _("E678: Invalid character after %s%%[dxouU]"), + reg_magic == MAGIC_ALL); + #ifdef FEAT_MBYTE +--- 2236,2242 ---- + } + + if (i < 0) +! EMSG2_RET_NULL( + _("E678: Invalid character after %s%%[dxouU]"), + reg_magic == MAGIC_ALL); + #ifdef FEAT_MBYTE +*************** +*** 2272,2278 **** + } + } + +! EMSG_M_RET_NULL(_("E71: Invalid character after %s%%"), + reg_magic == MAGIC_ALL); + } + } +--- 2308,2314 ---- + } + } + +! EMSG2_RET_NULL(_("E71: Invalid character after %s%%"), + reg_magic == MAGIC_ALL); + } + } +*************** +*** 2567,2574 **** + break; + } + else if (reg_strict) +! EMSG_M_RET_NULL(_("E769: Missing ] after %s["), +! reg_magic > MAGIC_OFF); + } + /* FALLTHROUGH */ + +--- 2603,2609 ---- + break; + } + else if (reg_strict) +! EMSG2_RET_NULL(_(e_missingbracket), reg_magic > MAGIC_OFF); + } + /* FALLTHROUGH */ + +*************** +*** 2659,2665 **** + #endif + + /* +! * emit a node + * Return pointer to generated code. + */ + static char_u * +--- 2694,2700 ---- + #endif + + /* +! * Emit a node. + * Return pointer to generated code. + */ + static char_u * +*************** +*** 2711,2717 **** + #endif + + /* +! * reginsert - insert an operator in front of already-emitted operand + * + * Means relocating the operand. + */ +--- 2746,2752 ---- + #endif + + /* +! * Insert an operator in front of already-emitted operand + * + * Means relocating the operand. + */ +*************** +*** 2742,2748 **** + } + + /* +! * reginsert_limits - insert an operator in front of already-emitted operand. + * The operator has the given limit values as operands. Also set next pointer. + * + * Means relocating the operand. +--- 2777,2783 ---- + } + + /* +! * Insert an operator in front of already-emitted operand. + * The operator has the given limit values as operands. Also set next pointer. + * + * Means relocating the operand. +*************** +*** 2794,2800 **** + } + + /* +! * regtail - set the next-pointer at the end of a node chain + */ + static void + regtail(p, val) +--- 2829,2835 ---- + } + + /* +! * Set the next-pointer at the end of a node chain. + */ + static void + regtail(p, val) +*************** +*** 2835,2841 **** + } + + /* +! * regoptail - regtail on item after a BRANCH; nop if none + */ + static void + regoptail(p, val) +--- 2870,2876 ---- + } + + /* +! * Like regtail, on item after a BRANCH; nop if none. + */ + static void + regoptail(p, val) +*************** +*** 2851,2872 **** + } + + /* +! * getchr() - get the next character from the pattern. We know about +! * magic and such, so therefore we need a lexical analyzer. + */ + +- /* static int curchr; */ +- static int prevprevchr; +- static int prevchr; +- static int nextchr; /* used for ungetchr() */ +- /* +- * Note: prevchr is sometimes -1 when we are not at the start, +- * eg in /[ ^I]^ the pattern was never found even if it existed, because ^ was +- * taken to be magic -- webb +- */ + static int at_start; /* True when on the first character */ + static int prev_at_start; /* True when on the second character */ + + static void + initchr(str) + char_u *str; +--- 2886,2900 ---- + } + + /* +! * Functions for getting characters from the regexp input. + */ + + static int at_start; /* True when on the first character */ + static int prev_at_start; /* True when on the second character */ + ++ /* ++ * Start parsing at "str". ++ */ + static void + initchr(str) + char_u *str; +*************** +*** 2878,2883 **** +--- 2906,2914 ---- + prev_at_start = FALSE; + } + ++ /* ++ * Get the next character without advancing. ++ */ + static int + peekchr() + { +*************** +*** 3086,3091 **** +--- 3117,3126 ---- + prevprevchr = prpr; + } + ++ /* ++ * Get the next character from the pattern. We know about magic and such, so ++ * therefore we need a lexical analyzer. ++ */ + static int + getchr() + { +*************** +*** 3340,3347 **** + } regbehind_T; + + static char_u *reg_getline __ARGS((linenr_T lnum)); +! static long vim_regexec_both __ARGS((char_u *line, colnr_T col, proftime_T *tm)); +! static long regtry __ARGS((regprog_T *prog, colnr_T col)); + static void cleanup_subexpr __ARGS((void)); + #ifdef FEAT_SYN_HL + static void cleanup_zsubexpr __ARGS((void)); +--- 3375,3382 ---- + } regbehind_T; + + static char_u *reg_getline __ARGS((linenr_T lnum)); +! static long bt_regexec_both __ARGS((char_u *line, colnr_T col, proftime_T *tm)); +! static long regtry __ARGS((bt_regprog_T *prog, colnr_T col)); + static void cleanup_subexpr __ARGS((void)); + #ifdef FEAT_SYN_HL + static void cleanup_zsubexpr __ARGS((void)); +*************** +*** 3398,3404 **** + /* + * Sometimes need to save a copy of a line. Since alloc()/free() is very + * slow, we keep one allocated piece of memory and only re-allocate it when +! * it's too small. It's freed in vim_regexec_both() when finished. + */ + static char_u *reg_tofree = NULL; + static unsigned reg_tofreelen; +--- 3433,3439 ---- + /* + * Sometimes need to save a copy of a line. Since alloc()/free() is very + * slow, we keep one allocated piece of memory and only re-allocate it when +! * it's too small. It's freed in bt_regexec_both() when finished. + */ + static char_u *reg_tofree = NULL; + static unsigned reg_tofreelen; +*************** +*** 3556,3561 **** +--- 3591,3598 ---- + /* TRUE if using multi-line regexp. */ + #define REG_MULTI (reg_match == NULL) + ++ static int bt_regexec __ARGS((regmatch_T *rmp, char_u *line, colnr_T col)); ++ + /* + * Match a regexp against a string. + * "rmp->regprog" is a compiled regexp as returned by vim_regcomp(). +*************** +*** 3563,3570 **** + * + * Return TRUE if there is a match, FALSE if not. + */ +! int +! vim_regexec(rmp, line, col) + regmatch_T *rmp; + char_u *line; /* string to match against */ + colnr_T col; /* column to start looking for match */ +--- 3600,3607 ---- + * + * Return TRUE if there is a match, FALSE if not. + */ +! static int +! bt_regexec(rmp, line, col) + regmatch_T *rmp; + char_u *line; /* string to match against */ + colnr_T col; /* column to start looking for match */ +*************** +*** 3580,3595 **** + ireg_icombine = FALSE; + #endif + ireg_maxcol = 0; +! return (vim_regexec_both(line, col, NULL) != 0); + } + + #if defined(FEAT_MODIFY_FNAME) || defined(FEAT_EVAL) \ + || defined(FIND_REPLACE_DIALOG) || defined(PROTO) + /* + * Like vim_regexec(), but consider a "\n" in "line" to be a line break. + */ +! int +! vim_regexec_nl(rmp, line, col) + regmatch_T *rmp; + char_u *line; /* string to match against */ + colnr_T col; /* column to start looking for match */ +--- 3617,3635 ---- + ireg_icombine = FALSE; + #endif + ireg_maxcol = 0; +! return (bt_regexec_both(line, col, NULL) != 0); + } + + #if defined(FEAT_MODIFY_FNAME) || defined(FEAT_EVAL) \ + || defined(FIND_REPLACE_DIALOG) || defined(PROTO) ++ ++ static int bt_regexec_nl __ARGS((regmatch_T *rmp, char_u *line, colnr_T col)); ++ + /* + * Like vim_regexec(), but consider a "\n" in "line" to be a line break. + */ +! static int +! bt_regexec_nl(rmp, line, col) + regmatch_T *rmp; + char_u *line; /* string to match against */ + colnr_T col; /* column to start looking for match */ +*************** +*** 3605,3614 **** + ireg_icombine = FALSE; + #endif + ireg_maxcol = 0; +! return (vim_regexec_both(line, col, NULL) != 0); + } + #endif + + /* + * Match a regexp against multiple lines. + * "rmp->regprog" is a compiled regexp as returned by vim_regcomp(). +--- 3645,3656 ---- + ireg_icombine = FALSE; + #endif + ireg_maxcol = 0; +! return (bt_regexec_both(line, col, NULL) != 0); + } + #endif + ++ static long bt_regexec_multi __ARGS((regmmatch_T *rmp, win_T *win, buf_T *buf, linenr_T lnum, colnr_T col, proftime_T *tm)); ++ + /* + * Match a regexp against multiple lines. + * "rmp->regprog" is a compiled regexp as returned by vim_regcomp(). +*************** +*** 3617,3624 **** + * Return zero if there is no match. Return number of lines contained in the + * match otherwise. + */ +! long +! vim_regexec_multi(rmp, win, buf, lnum, col, tm) + regmmatch_T *rmp; + win_T *win; /* window in which to search or NULL */ + buf_T *buf; /* buffer in which to search */ +--- 3659,3666 ---- + * Return zero if there is no match. Return number of lines contained in the + * match otherwise. + */ +! static long +! bt_regexec_multi(rmp, win, buf, lnum, col, tm) + regmmatch_T *rmp; + win_T *win; /* window in which to search or NULL */ + buf_T *buf; /* buffer in which to search */ +*************** +*** 3641,3647 **** + #endif + ireg_maxcol = rmp->rmm_maxcol; + +! r = vim_regexec_both(NULL, col, tm); + + return r; + } +--- 3683,3689 ---- + #endif + ireg_maxcol = rmp->rmm_maxcol; + +! r = bt_regexec_both(NULL, col, tm); + + return r; + } +*************** +*** 3651,3662 **** + * lines ("line" is NULL, use reg_getline()). + */ + static long +! vim_regexec_both(line, col, tm) + char_u *line; + colnr_T col; /* column to start looking for match */ + proftime_T *tm UNUSED; /* timeout limit or NULL */ + { +! regprog_T *prog; + char_u *s; + long retval = 0L; + +--- 3693,3704 ---- + * lines ("line" is NULL, use reg_getline()). + */ + static long +! bt_regexec_both(line, col, tm) + char_u *line; + colnr_T col; /* column to start looking for match */ + proftime_T *tm UNUSED; /* timeout limit or NULL */ + { +! bt_regprog_T *prog; + char_u *s; + long retval = 0L; + +*************** +*** 3682,3695 **** + + if (REG_MULTI) + { +! prog = reg_mmatch->regprog; + line = reg_getline((linenr_T)0); + reg_startpos = reg_mmatch->startpos; + reg_endpos = reg_mmatch->endpos; + } + else + { +! prog = reg_match->regprog; + reg_startp = reg_match->startp; + reg_endp = reg_match->endp; + } +--- 3724,3737 ---- + + if (REG_MULTI) + { +! prog = (bt_regprog_T *)reg_mmatch->regprog; + line = reg_getline((linenr_T)0); + reg_startpos = reg_mmatch->startpos; + reg_endpos = reg_mmatch->endpos; + } + else + { +! prog = (bt_regprog_T *)reg_match->regprog; + reg_startp = reg_match->startp; + reg_endp = reg_match->endp; + } +*************** +*** 3931,3937 **** + */ + static long + regtry(prog, col) +! regprog_T *prog; + colnr_T col; + { + reginput = regline + col; +--- 3973,3979 ---- + */ + static long + regtry(prog, col) +! bt_regprog_T *prog; + colnr_T col; + { + reginput = regline + col; +*************** +*** 4063,4069 **** + #define RA_NOMATCH 5 /* didn't match */ + + /* Make "regstack" and "backpos" empty. They are allocated and freed in +! * vim_regexec_both() to reduce malloc()/free() calls. */ + regstack.ga_len = 0; + backpos.ga_len = 0; + +--- 4105,4111 ---- + #define RA_NOMATCH 5 /* didn't match */ + + /* Make "regstack" and "backpos" empty. They are allocated and freed in +! * bt_regexec_both() to reduce malloc()/free() calls. */ + regstack.ga_len = 0; + backpos.ga_len = 0; + +*************** +*** 4072,4085 **** + */ + for (;;) + { +! /* Some patterns my cause a long time to match, even though they are not + * illegal. E.g., "\([a-z]\+\)\+Q". Allow breaking them with CTRL-C. */ + fast_breakcheck(); + + #ifdef DEBUG + if (scan != NULL && regnarrate) + { +! mch_errmsg(regprop(scan)); + mch_errmsg("(\n"); + } + #endif +--- 4114,4127 ---- + */ + for (;;) + { +! /* Some patterns may cause a long time to match, even though they are not + * illegal. E.g., "\([a-z]\+\)\+Q". Allow breaking them with CTRL-C. */ + fast_breakcheck(); + + #ifdef DEBUG + if (scan != NULL && regnarrate) + { +! mch_errmsg((char *)regprop(scan)); + mch_errmsg("(\n"); + } + #endif +*************** +*** 4100,4106 **** + #ifdef DEBUG + if (regnarrate) + { +! mch_errmsg(regprop(scan)); + mch_errmsg("...\n"); + # ifdef FEAT_SYN_HL + if (re_extmatch_in != NULL) +--- 4142,4148 ---- + #ifdef DEBUG + if (regnarrate) + { +! mch_errmsg((char *)regprop(scan)); + mch_errmsg("...\n"); + # ifdef FEAT_SYN_HL + if (re_extmatch_in != NULL) +*************** +*** 4112,4118 **** + { + mch_errmsg(" \""); + if (re_extmatch_in->matches[i] != NULL) +! mch_errmsg(re_extmatch_in->matches[i]); + mch_errmsg("\"\n"); + } + } +--- 4154,4160 ---- + { + mch_errmsg(" \""); + if (re_extmatch_in->matches[i] != NULL) +! mch_errmsg((char *)re_extmatch_in->matches[i]); + mch_errmsg("\"\n"); + } + } +*************** +*** 6091,6099 **** + static int + prog_magic_wrong() + { +! if (UCHARAT(REG_MULTI +! ? reg_mmatch->regprog->program +! : reg_match->regprog->program) != REGMAGIC) + { + EMSG(_(e_re_corr)); + return TRUE; +--- 6133,6146 ---- + static int + prog_magic_wrong() + { +! regprog_T *prog; +! +! prog = REG_MULTI ? reg_mmatch->regprog : reg_match->regprog; +! if (prog->engine == &nfa_regengine) +! /* For NFA matcher we don't check the magic */ +! return FALSE; +! +! if (UCHARAT(((bt_regprog_T *)prog)->program) != REGMAGIC) + { + EMSG(_(e_re_corr)); + return TRUE; +*************** +*** 6318,6324 **** + } + + +! #ifdef DEBUG + + /* + * regdump - dump a regexp onto stdout in vaguely comprehensible form +--- 6365,6371 ---- + } + + +! #ifdef BT_REGEXP_DUMP + + /* + * regdump - dump a regexp onto stdout in vaguely comprehensible form +*************** +*** 6326,6339 **** + static void + regdump(pattern, r) + char_u *pattern; +! regprog_T *r; + { + char_u *s; + int op = EXACTLY; /* Arbitrary non-END op. */ + char_u *next; + char_u *end = NULL; + +! printf("\r\nregcomp(%s):\r\n", pattern); + + s = r->program + 1; + /* +--- 6373,6394 ---- + static void + regdump(pattern, r) + char_u *pattern; +! bt_regprog_T *r; + { + char_u *s; + int op = EXACTLY; /* Arbitrary non-END op. */ + char_u *next; + char_u *end = NULL; ++ FILE *f; + +! #ifdef BT_REGEXP_LOG +! f = fopen("bt_regexp_log.log", "a"); +! #else +! f = stdout; +! #endif +! if (f == NULL) +! return; +! fprintf(f, "-------------------------------------\n\r\nregcomp(%s):\r\n", pattern); + + s = r->program + 1; + /* +*************** +*** 6343,6360 **** + while (op != END || s <= end) + { + op = OP(s); +! printf("%2d%s", (int)(s - r->program), regprop(s)); /* Where, what. */ + next = regnext(s); + if (next == NULL) /* Next ptr. */ +! printf("(0)"); + else +! printf("(%d)", (int)((s - r->program) + (next - s))); + if (end < next) + end = next; + if (op == BRACE_LIMITS) + { + /* Two short ints */ +! printf(" minval %ld, maxval %ld", OPERAND_MIN(s), OPERAND_MAX(s)); + s += 8; + } + s += 3; +--- 6398,6415 ---- + while (op != END || s <= end) + { + op = OP(s); +! fprintf(f, "%2d%s", (int)(s - r->program), regprop(s)); /* Where, what. */ + next = regnext(s); + if (next == NULL) /* Next ptr. */ +! fprintf(f, "(0)"); + else +! fprintf(f, "(%d)", (int)((s - r->program) + (next - s))); + if (end < next) + end = next; + if (op == BRACE_LIMITS) + { + /* Two short ints */ +! fprintf(f, " minval %ld, maxval %ld", OPERAND_MIN(s), OPERAND_MAX(s)); + s += 8; + } + s += 3; +*************** +*** 6363,6387 **** + || op == EXACTLY) + { + /* Literal string, where present. */ + while (*s != NUL) +! printf("%c", *s++); + s++; + } +! printf("\r\n"); + } + + /* Header fields of interest. */ + if (r->regstart != NUL) +! printf("start `%s' 0x%x; ", r->regstart < 256 + ? (char *)transchar(r->regstart) + : "multibyte", r->regstart); + if (r->reganch) +! printf("anchored; "); + if (r->regmust != NULL) +! printf("must have \"%s\"", r->regmust); +! printf("\r\n"); + } + + /* + * regprop - printable representation of opcode + */ +--- 6418,6450 ---- + || op == EXACTLY) + { + /* Literal string, where present. */ ++ fprintf(f, "\nxxxxxxxxx\n"); + while (*s != NUL) +! fprintf(f, "%c", *s++); +! fprintf(f, "\nxxxxxxxxx\n"); + s++; + } +! fprintf(f, "\r\n"); + } + + /* Header fields of interest. */ + if (r->regstart != NUL) +! fprintf(f, "start `%s' 0x%x; ", r->regstart < 256 + ? (char *)transchar(r->regstart) + : "multibyte", r->regstart); + if (r->reganch) +! fprintf(f, "anchored; "); + if (r->regmust != NULL) +! fprintf(f, "must have \"%s\"", r->regmust); +! fprintf(f, "\r\n"); +! +! #ifdef BT_REGEXP_LOG +! fclose(f); +! #endif + } ++ #endif /* BT_REGEXP_DUMP */ + ++ #ifdef DEBUG + /* + * regprop - printable representation of opcode + */ +*************** +*** 6389,6400 **** + regprop(op) + char_u *op; + { +! char_u *p; +! static char_u buf[50]; + +! (void) strcpy(buf, ":"); + +! switch (OP(op)) + { + case BOL: + p = "BOL"; +--- 6452,6463 ---- + regprop(op) + char_u *op; + { +! char *p; +! static char buf[50]; + +! STRCPY(buf, ":"); + +! switch ((int) OP(op)) + { + case BOL: + p = "BOL"; +*************** +*** 6761,6770 **** + break; + } + if (p != NULL) +! (void) strcat(buf, p); +! return buf; + } +! #endif + + #ifdef FEAT_MBYTE + static void mb_decompose __ARGS((int c, int *c1, int *c2, int *c3)); +--- 6824,6833 ---- + break; + } + if (p != NULL) +! STRCAT(buf, p); +! return (char_u *)buf; + } +! #endif /* DEBUG */ + + #ifdef FEAT_MBYTE + static void mb_decompose __ARGS((int c, int *c1, int *c2, int *c3)); +*************** +*** 7667,7669 **** +--- 7730,7916 ---- + return retval; + } + #endif ++ ++ static regengine_T bt_regengine = ++ { ++ bt_regcomp, ++ bt_regexec, ++ #if defined(FEAT_MODIFY_FNAME) || defined(FEAT_EVAL) \ ++ || defined(FIND_REPLACE_DIALOG) || defined(PROTO) ++ bt_regexec_nl, ++ #endif ++ bt_regexec_multi ++ #ifdef DEBUG ++ ,(char_u *)"" ++ #endif ++ }; ++ ++ ++ #include "regexp_nfa.c" ++ ++ static regengine_T nfa_regengine = ++ { ++ nfa_regcomp, ++ nfa_regexec, ++ #if defined(FEAT_MODIFY_FNAME) || defined(FEAT_EVAL) \ ++ || defined(FIND_REPLACE_DIALOG) || defined(PROTO) ++ nfa_regexec_nl, ++ #endif ++ nfa_regexec_multi ++ #ifdef DEBUG ++ ,(char_u *)"" ++ #endif ++ }; ++ ++ /* Which regexp engine to use? Needed for vim_regcomp(). ++ * Must match with 'regexpengine'. */ ++ static int regexp_engine = 0; ++ #define AUTOMATIC_ENGINE 0 ++ #define BACKTRACKING_ENGINE 1 ++ #define NFA_ENGINE 2 ++ #ifdef DEBUG ++ static char_u regname[][30] = { ++ "AUTOMATIC Regexp Engine", ++ "BACKTACKING Regexp Engine", ++ "NFA Regexp Engine" ++ }; ++ #endif ++ ++ /* ++ * Compile a regular expression into internal code. ++ * Returns the program in allocated memory. Returns NULL for an error. ++ */ ++ regprog_T * ++ vim_regcomp(expr_arg, re_flags) ++ char_u *expr_arg; ++ int re_flags; ++ { ++ regprog_T *prog = NULL; ++ char_u *expr = expr_arg; ++ ++ syntax_error = FALSE; ++ regexp_engine = p_re; ++ ++ /* Check for prefix "\%#=", that sets the regexp engine */ ++ if (STRNCMP(expr, "\\%#=", 4) == 0) ++ { ++ int newengine = expr[4] - '0'; ++ ++ if (newengine == AUTOMATIC_ENGINE ++ || newengine == BACKTRACKING_ENGINE ++ || newengine == NFA_ENGINE) ++ { ++ regexp_engine = expr[4] - '0'; ++ expr += 5; ++ #ifdef DEBUG ++ EMSG3("New regexp mode selected (%d): %s", regexp_engine, ++ regname[newengine]); ++ #endif ++ } ++ else ++ { ++ EMSG(_("E864: \\%#= can only be followed by 0, 1, or 2. The automatic engine will be used ")); ++ regexp_engine = AUTOMATIC_ENGINE; ++ } ++ } ++ #ifdef DEBUG ++ bt_regengine.expr = expr; ++ nfa_regengine.expr = expr; ++ #endif ++ ++ /* ++ * First try the NFA engine, unless backtracking was requested. ++ */ ++ if (regexp_engine != BACKTRACKING_ENGINE) ++ prog = nfa_regengine.regcomp(expr, re_flags); ++ else ++ prog = bt_regengine.regcomp(expr, re_flags); ++ ++ if (prog == NULL) /* error compiling regexp with initial engine */ ++ { ++ #ifdef DEBUG ++ if (regexp_engine != BACKTRACKING_ENGINE) /* debugging log for NFA */ ++ { ++ FILE *f; ++ f = fopen("debug.log", "a"); ++ if (f) ++ { ++ if (!syntax_error) ++ fprintf(f, "NFA engine could not handle \"%s\"\n", expr); ++ else ++ fprintf(f, "Syntax error in \"%s\"\n", expr); ++ fclose(f); ++ } ++ else ++ EMSG("(NFA) Could not open \"debug.log\" to write !!!"); ++ /* ++ if (syntax_error) ++ EMSG("NFA Regexp: Syntax Error !"); ++ */ ++ } ++ #endif ++ /* ++ * If NFA engine failed, then revert to the backtracking engine. ++ * Except when there was a syntax error, which was properly handled by ++ * NFA engine. ++ */ ++ if (regexp_engine == AUTOMATIC_ENGINE) ++ if (!syntax_error) ++ prog = bt_regengine.regcomp(expr, re_flags); ++ ++ } /* endif prog==NULL */ ++ ++ ++ return prog; ++ } ++ ++ /* ++ * Match a regexp against a string. ++ * "rmp->regprog" is a compiled regexp as returned by vim_regcomp(). ++ * Uses curbuf for line count and 'iskeyword'. ++ * ++ * Return TRUE if there is a match, FALSE if not. ++ */ ++ int ++ vim_regexec(rmp, line, col) ++ regmatch_T *rmp; ++ char_u *line; /* string to match against */ ++ colnr_T col; /* column to start looking for match */ ++ { ++ return rmp->regprog->engine->regexec(rmp, line, col); ++ } ++ ++ #if defined(FEAT_MODIFY_FNAME) || defined(FEAT_EVAL) \ ++ || defined(FIND_REPLACE_DIALOG) || defined(PROTO) ++ /* ++ * Like vim_regexec(), but consider a "\n" in "line" to be a line break. ++ */ ++ int ++ vim_regexec_nl(rmp, line, col) ++ regmatch_T *rmp; ++ char_u *line; ++ colnr_T col; ++ { ++ return rmp->regprog->engine->regexec_nl(rmp, line, col); ++ } ++ #endif ++ ++ /* ++ * Match a regexp against multiple lines. ++ * "rmp->regprog" is a compiled regexp as returned by vim_regcomp(). ++ * Uses curbuf for line count and 'iskeyword'. ++ * ++ * Return zero if there is no match. Return number of lines contained in the ++ * match otherwise. ++ */ ++ long ++ vim_regexec_multi(rmp, win, buf, lnum, col, tm) ++ regmmatch_T *rmp; ++ win_T *win; /* window in which to search or NULL */ ++ buf_T *buf; /* buffer in which to search */ ++ linenr_T lnum; /* nr of line to start looking for match */ ++ colnr_T col; /* column to start looking for match */ ++ proftime_T *tm; /* timeout limit or NULL */ ++ { ++ return rmp->regprog->engine->regexec_multi(rmp, win, buf, lnum, col, tm); ++ } +*** ../vim-7.3.969/src/regexp.h 2010-08-15 21:57:27.000000000 +0200 +--- src/regexp.h 2013-05-18 17:24:42.000000000 +0200 +*************** +*** 22,41 **** + #define NSUBEXP 10 + + /* + * Structure returned by vim_regcomp() to pass on to vim_regexec(). + * These fields are only to be used in regexp.c! +! * See regep.c for an explanation. + */ + typedef struct + { + int regstart; + char_u reganch; + char_u *regmust; + int regmlen; +- unsigned regflags; + char_u reghasz; +! char_u program[1]; /* actually longer.. */ +! } regprog_T; + + /* + * Structure to be used for single-line matching. +--- 22,97 ---- + #define NSUBEXP 10 + + /* ++ * In the NFA engine: how many braces are allowed. ++ * TODO(RE): Use dynamic memory allocation instead of static, like here ++ */ ++ #define NFA_MAX_BRACES 20 ++ ++ typedef struct regengine regengine_T; ++ ++ typedef struct thread thread_T; ++ ++ /* + * Structure returned by vim_regcomp() to pass on to vim_regexec(). ++ * This is the general structure. For the actual matcher, two specific ++ * structures are used. See code below. ++ */ ++ typedef struct regprog ++ { ++ regengine_T *engine; ++ unsigned regflags; ++ } regprog_T; ++ ++ /* ++ * Structure used by the back track matcher. + * These fields are only to be used in regexp.c! +! * See regexp.c for an explanation. + */ + typedef struct + { ++ /* These two members implement regprog_T */ ++ regengine_T *engine; ++ unsigned regflags; ++ + int regstart; + char_u reganch; + char_u *regmust; + int regmlen; + char_u reghasz; +! char_u program[1]; /* actually longer.. */ +! } bt_regprog_T; +! +! /* +! * Structure representing a NFA state. +! * A NFA state may have no outgoing edge, when it is a NFA_MATCH state. +! */ +! typedef struct nfa_state nfa_state_T; +! struct nfa_state +! { +! int c; +! nfa_state_T *out; +! nfa_state_T *out1; +! int id; +! int lastlist; +! int visits; +! thread_T *lastthread; +! int negated; +! }; +! +! /* +! * Structure used by the NFA matcher. +! */ +! typedef struct +! { +! /* These two members implement regprog_T */ +! regengine_T *engine; +! unsigned regflags; +! +! regprog_T regprog; +! nfa_state_T *start; +! int nstate; +! nfa_state_T state[0]; /* actually longer.. */ +! } nfa_regprog_T; + + /* + * Structure to be used for single-line matching. +*************** +*** 78,81 **** +--- 134,151 ---- + char_u *matches[NSUBEXP]; + } reg_extmatch_T; + ++ struct regengine ++ { ++ regprog_T *(*regcomp)(char_u*, int); ++ int (*regexec)(regmatch_T*, char_u*, colnr_T); ++ #if defined(FEAT_MODIFY_FNAME) || defined(FEAT_EVAL) \ ++ || defined(FIND_REPLACE_DIALOG) || defined(PROTO) ++ int (*regexec_nl)(regmatch_T*, char_u*, colnr_T); ++ #endif ++ long (*regexec_multi)(regmmatch_T*, win_T*, buf_T*, linenr_T, colnr_T, proftime_T*); ++ #ifdef DEBUG ++ char_u *expr; ++ #endif ++ }; ++ + #endif /* _REGEXP_H */ +*** ../vim-7.3.969/src/regexp_nfa.c 2013-05-19 19:10:10.000000000 +0200 +--- src/regexp_nfa.c 2013-05-19 16:08:09.000000000 +0200 +*************** +*** 0 **** +--- 1,3819 ---- ++ /* vi:set ts=8 sts=4 sw=4: ++ * ++ * NFA regular expression implementation. ++ * ++ * This file is included in "regexp.c". ++ */ ++ ++ #ifdef DEBUG ++ /* Comment this out to disable log files. They can get pretty big */ ++ # define ENABLE_LOG ++ # define LOG_NAME "log_nfarun.log" ++ #endif ++ ++ /* Upper limit allowed for {m,n} repetitions handled by NFA */ ++ #define NFA_BRACES_MAXLIMIT 10 ++ /* For allocating space for the postfix representation */ ++ #define NFA_POSTFIX_MULTIPLIER (NFA_BRACES_MAXLIMIT + 2)*2 ++ /* Size of stack, used when converting the postfix regexp into NFA */ ++ #define NFA_STACK_SIZE 1024 ++ ++ enum ++ { ++ NFA_SPLIT = -1024, ++ NFA_MATCH, ++ NFA_SKIP_CHAR, /* matches a 0-length char */ ++ NFA_END_NEG_RANGE, /* Used when expanding [^ab] */ ++ ++ NFA_CONCAT, ++ NFA_OR, ++ NFA_STAR, ++ NFA_PLUS, ++ NFA_QUEST, ++ NFA_QUEST_NONGREEDY, /* Non-greedy version of \? */ ++ NFA_NOT, /* used for [^ab] negated char ranges */ ++ ++ NFA_BOL, /* ^ Begin line */ ++ NFA_EOL, /* $ End line */ ++ NFA_BOW, /* \< Begin word */ ++ NFA_EOW, /* \> End word */ ++ NFA_BOF, /* \%^ Begin file */ ++ NFA_EOF, /* \%$ End file */ ++ NFA_NEWL, ++ NFA_ZSTART, /* Used for \zs */ ++ NFA_ZEND, /* Used for \ze */ ++ NFA_NOPEN, /* Start of subexpression marked with \%( */ ++ NFA_NCLOSE, /* End of subexpr. marked with \%( ... \) */ ++ NFA_START_INVISIBLE, ++ NFA_END_INVISIBLE, ++ NFA_MULTIBYTE, /* Next nodes in NFA are part of the same ++ multibyte char */ ++ NFA_END_MULTIBYTE, /* End of multibyte char in the NFA */ ++ NFA_COMPOSING, /* Next nodes in NFA are part of the ++ composing multibyte char */ ++ NFA_END_COMPOSING, /* End of a composing char in the NFA */ ++ ++ /* The following are used only in the postfix form, not in the NFA */ ++ NFA_PREV_ATOM_NO_WIDTH, /* Used for \@= */ ++ NFA_PREV_ATOM_NO_WIDTH_NEG, /* Used for \@! */ ++ NFA_PREV_ATOM_JUST_BEFORE, /* Used for \@<= */ ++ NFA_PREV_ATOM_JUST_BEFORE_NEG, /* Used for \@ */ ++ ++ NFA_MOPEN, ++ NFA_MCLOSE = NFA_MOPEN + NSUBEXP, ++ ++ /* NFA_FIRST_NL */ ++ NFA_ANY = NFA_MCLOSE + NSUBEXP, /* Match any one character. */ ++ NFA_ANYOF, /* Match any character in this string. */ ++ NFA_ANYBUT, /* Match any character not in this string. */ ++ NFA_IDENT, /* Match identifier char */ ++ NFA_SIDENT, /* Match identifier char but no digit */ ++ NFA_KWORD, /* Match keyword char */ ++ NFA_SKWORD, /* Match word char but no digit */ ++ NFA_FNAME, /* Match file name char */ ++ NFA_SFNAME, /* Match file name char but no digit */ ++ NFA_PRINT, /* Match printable char */ ++ NFA_SPRINT, /* Match printable char but no digit */ ++ NFA_WHITE, /* Match whitespace char */ ++ NFA_NWHITE, /* Match non-whitespace char */ ++ NFA_DIGIT, /* Match digit char */ ++ NFA_NDIGIT, /* Match non-digit char */ ++ NFA_HEX, /* Match hex char */ ++ NFA_NHEX, /* Match non-hex char */ ++ NFA_OCTAL, /* Match octal char */ ++ NFA_NOCTAL, /* Match non-octal char */ ++ NFA_WORD, /* Match word char */ ++ NFA_NWORD, /* Match non-word char */ ++ NFA_HEAD, /* Match head char */ ++ NFA_NHEAD, /* Match non-head char */ ++ NFA_ALPHA, /* Match alpha char */ ++ NFA_NALPHA, /* Match non-alpha char */ ++ NFA_LOWER, /* Match lowercase char */ ++ NFA_NLOWER, /* Match non-lowercase char */ ++ NFA_UPPER, /* Match uppercase char */ ++ NFA_NUPPER, /* Match non-uppercase char */ ++ NFA_FIRST_NL = NFA_ANY + ADD_NL, ++ NFA_LAST_NL = NFA_NUPPER + ADD_NL, ++ ++ /* Character classes [:alnum:] etc */ ++ NFA_CLASS_ALNUM, ++ NFA_CLASS_ALPHA, ++ NFA_CLASS_BLANK, ++ NFA_CLASS_CNTRL, ++ NFA_CLASS_DIGIT, ++ NFA_CLASS_GRAPH, ++ NFA_CLASS_LOWER, ++ NFA_CLASS_PRINT, ++ NFA_CLASS_PUNCT, ++ NFA_CLASS_SPACE, ++ NFA_CLASS_UPPER, ++ NFA_CLASS_XDIGIT, ++ NFA_CLASS_TAB, ++ NFA_CLASS_RETURN, ++ NFA_CLASS_BACKSPACE, ++ NFA_CLASS_ESCAPE ++ }; ++ ++ /* Keep in sync with classchars. */ ++ static int nfa_classcodes[] = { ++ NFA_ANY, NFA_IDENT, NFA_SIDENT, NFA_KWORD,NFA_SKWORD, ++ NFA_FNAME, NFA_SFNAME, NFA_PRINT, NFA_SPRINT, ++ NFA_WHITE, NFA_NWHITE, NFA_DIGIT, NFA_NDIGIT, ++ NFA_HEX, NFA_NHEX, NFA_OCTAL, NFA_NOCTAL, ++ NFA_WORD, NFA_NWORD, NFA_HEAD, NFA_NHEAD, ++ NFA_ALPHA, NFA_NALPHA, NFA_LOWER, NFA_NLOWER, ++ NFA_UPPER, NFA_NUPPER ++ }; ++ ++ static char_u e_misplaced[] = N_("E866: (NFA regexp) Misplaced %c"); ++ ++ /* ++ * NFA errors can be of 3 types: ++ * *** NFA runtime errors, when something unknown goes wrong. The NFA fails ++ * silently and revert the to backtracking engine. ++ * syntax_error = FALSE; ++ * *** Regexp syntax errors, when the input regexp is not syntactically correct. ++ * The NFA engine displays an error message, and nothing else happens. ++ * syntax_error = TRUE ++ * *** Unsupported features, when the input regexp uses an operator that is not ++ * implemented in the NFA. The NFA engine fails silently, and reverts to the ++ * old backtracking engine. ++ * syntax_error = FALSE ++ * "The NFA fails" means that "compiling the regexp with the NFA fails": ++ * nfa_regcomp() returns FAIL. ++ */ ++ static int syntax_error = FALSE; ++ ++ /* NFA regexp \ze operator encountered. */ ++ static int nfa_has_zend = FALSE; ++ ++ static int *post_start; /* holds the postfix form of r.e. */ ++ static int *post_end; ++ static int *post_ptr; ++ ++ static int nstate; /* Number of states in the NFA. */ ++ static int istate; /* Index in the state vector, used in new_state() */ ++ static int nstate_max; /* Upper bound of estimated number of states. */ ++ ++ ++ static int nfa_regcomp_start __ARGS((char_u*expr, int re_flags)); ++ static int nfa_recognize_char_class __ARGS((char_u *start, char_u *end, int extra_newl)); ++ static int nfa_emit_equi_class __ARGS((int c, int neg)); ++ static void nfa_inc __ARGS((char_u **p)); ++ static void nfa_dec __ARGS((char_u **p)); ++ static int nfa_regatom __ARGS((void)); ++ static int nfa_regpiece __ARGS((void)); ++ static int nfa_regconcat __ARGS((void)); ++ static int nfa_regbranch __ARGS((void)); ++ static int nfa_reg __ARGS((int paren)); ++ #ifdef DEBUG ++ static void nfa_set_code __ARGS((int c)); ++ static void nfa_postfix_dump __ARGS((char_u *expr, int retval)); ++ static void nfa_print_state __ARGS((FILE *debugf, nfa_state_T *state, int ident)); ++ static void nfa_dump __ARGS((nfa_regprog_T *prog)); ++ #endif ++ static int *re2post __ARGS((void)); ++ static nfa_state_T *new_state __ARGS((int c, nfa_state_T *out, nfa_state_T *out1)); ++ static nfa_state_T *post2nfa __ARGS((int *postfix, int *end, int nfa_calc_size)); ++ static int check_char_class __ARGS((int class, int c)); ++ static void st_error __ARGS((int *postfix, int *end, int *p)); ++ static void nfa_save_listids __ARGS((nfa_state_T *start, int *list)); ++ static void nfa_restore_listids __ARGS((nfa_state_T *start, int *list)); ++ static void nfa_set_null_listids __ARGS((nfa_state_T *start)); ++ static void nfa_set_neg_listids __ARGS((nfa_state_T *start)); ++ static long nfa_regtry __ARGS((nfa_state_T *start, colnr_T col)); ++ static long nfa_regexec_both __ARGS((char_u *line, colnr_T col)); ++ static regprog_T *nfa_regcomp __ARGS((char_u *expr, int re_flags)); ++ static int nfa_regexec __ARGS((regmatch_T *rmp, char_u *line, colnr_T col)); ++ static long nfa_regexec_multi __ARGS((regmmatch_T *rmp, win_T *win, buf_T *buf, linenr_T lnum, colnr_T col, proftime_T *tm)); ++ ++ /* helper functions used when doing re2post() ... regatom() parsing */ ++ #define EMIT(c) do { \ ++ if (post_ptr >= post_end) \ ++ return FAIL; \ ++ *post_ptr++ = c; \ ++ } while (0) ++ ++ #define EMIT_MBYTE(c) \ ++ len = (*mb_char2bytes)(c, buf); \ ++ EMIT(buf[0]); \ ++ for (i = 1; i < len; i++) \ ++ { \ ++ EMIT(buf[i]); \ ++ EMIT(NFA_CONCAT); \ ++ } \ ++ EMIT(NFA_MULTIBYTE); ++ ++ #define EMIT_COMPOSING_UTF(input) \ ++ len = utfc_ptr2len(input); \ ++ EMIT(input[0]); \ ++ for (i = 1; i < len; i++) \ ++ { \ ++ EMIT(input[i]); \ ++ EMIT(NFA_CONCAT); \ ++ } \ ++ EMIT(NFA_COMPOSING); ++ ++ /* ++ * Initialize internal variables before NFA compilation. ++ * Return OK on success, FAIL otherwise. ++ */ ++ static int ++ nfa_regcomp_start(expr, re_flags) ++ char_u *expr; ++ int re_flags; /* see vim_regcomp() */ ++ { ++ int postfix_size; ++ ++ nstate = 0; ++ istate = 0; ++ /* A reasonable estimation for size */ ++ nstate_max = (STRLEN(expr) + 1) * NFA_POSTFIX_MULTIPLIER; ++ ++ /* Size for postfix representation of expr */ ++ postfix_size = sizeof(*post_start) * nstate_max; ++ post_start = (int *)lalloc(postfix_size, TRUE); ++ if (post_start == NULL) ++ return FAIL; ++ vim_memset(post_start, 0, postfix_size); ++ post_ptr = post_start; ++ post_end = post_start + postfix_size; ++ nfa_has_zend = FALSE; ++ ++ regcomp_start(expr, re_flags); ++ ++ return OK; ++ } ++ ++ /* ++ * Search between "start" and "end" and try to recognize a ++ * character class in expanded form. For example [0-9]. ++ * On success, return the id the character class to be emitted. ++ * On failure, return 0 (=FAIL) ++ * Start points to the first char of the range, while end should point ++ * to the closing brace. ++ */ ++ static int ++ nfa_recognize_char_class(start, end, extra_newl) ++ char_u *start; ++ char_u *end; ++ int extra_newl; ++ { ++ int i; ++ /* Each of these variables takes up a char in "config[]", ++ * in the order they are here. */ ++ int not = FALSE, af = FALSE, AF = FALSE, az = FALSE, AZ = FALSE, ++ o7 = FALSE, o9 = FALSE, underscore = FALSE, newl = FALSE; ++ char_u *p; ++ #define NCONFIGS 16 ++ int classid[NCONFIGS] = { ++ NFA_DIGIT, NFA_NDIGIT, NFA_HEX, NFA_NHEX, ++ NFA_OCTAL, NFA_NOCTAL, NFA_WORD, NFA_NWORD, ++ NFA_HEAD, NFA_NHEAD, NFA_ALPHA, NFA_NALPHA, ++ NFA_LOWER, NFA_NLOWER, NFA_UPPER, NFA_NUPPER ++ }; ++ char_u myconfig[9]; ++ char_u config[NCONFIGS][9] = { ++ "000000100", /* digit */ ++ "100000100", /* non digit */ ++ "011000100", /* hex-digit */ ++ "111000100", /* non hex-digit */ ++ "000001000", /* octal-digit */ ++ "100001000", /* [^0-7] */ ++ "000110110", /* [0-9A-Za-z_] */ ++ "100110110", /* [^0-9A-Za-z_] */ ++ "000110010", /* head of word */ ++ "100110010", /* not head of word */ ++ "000110000", /* alphabetic char a-z */ ++ "100110000", /* non alphabetic char */ ++ "000100000", /* lowercase letter */ ++ "100100000", /* non lowercase */ ++ "000010000", /* uppercase */ ++ "100010000" /* non uppercase */ ++ }; ++ ++ if (extra_newl == TRUE) ++ newl = TRUE; ++ ++ if (*end != ']') ++ return FAIL; ++ p = start; ++ if (*p == '^') ++ { ++ not = TRUE; ++ p ++; ++ } ++ ++ while (p < end) ++ { ++ if (p + 2 < end && *(p + 1) == '-') ++ { ++ switch (*p) ++ { ++ case '0': ++ if (*(p + 2) == '9') ++ { ++ o9 = TRUE; ++ break; ++ } ++ else ++ if (*(p + 2) == '7') ++ { ++ o7 = TRUE; ++ break; ++ } ++ case 'a': ++ if (*(p + 2) == 'z') ++ { ++ az = TRUE; ++ break; ++ } ++ else ++ if (*(p + 2) == 'f') ++ { ++ af = TRUE; ++ break; ++ } ++ case 'A': ++ if (*(p + 2) == 'Z') ++ { ++ AZ = TRUE; ++ break; ++ } ++ else ++ if (*(p + 2) == 'F') ++ { ++ AF = TRUE; ++ break; ++ } ++ /* FALLTHROUGH */ ++ default: ++ return FAIL; ++ } ++ p += 3; ++ } ++ else if (p + 1 < end && *p == '\\' && *(p + 1) == 'n') ++ { ++ newl = TRUE; ++ p += 2; ++ } ++ else if (*p == '_') ++ { ++ underscore = TRUE; ++ p ++; ++ } ++ else if (*p == '\n') ++ { ++ newl = TRUE; ++ p ++; ++ } ++ else ++ return FAIL; ++ } /* while (p < end) */ ++ ++ if (p != end) ++ return FAIL; ++ ++ /* build the config that represents the ranges we gathered */ ++ STRCPY(myconfig, "000000000"); ++ if (not == TRUE) ++ myconfig[0] = '1'; ++ if (af == TRUE) ++ myconfig[1] = '1'; ++ if (AF == TRUE) ++ myconfig[2] = '1'; ++ if (az == TRUE) ++ myconfig[3] = '1'; ++ if (AZ == TRUE) ++ myconfig[4] = '1'; ++ if (o7 == TRUE) ++ myconfig[5] = '1'; ++ if (o9 == TRUE) ++ myconfig[6] = '1'; ++ if (underscore == TRUE) ++ myconfig[7] = '1'; ++ if (newl == TRUE) ++ { ++ myconfig[8] = '1'; ++ extra_newl = ADD_NL; ++ } ++ /* try to recognize character classes */ ++ for (i = 0; i < NCONFIGS; i++) ++ if (STRNCMP(myconfig, config[i],8) == 0) ++ return classid[i] + extra_newl; ++ ++ /* fallthrough => no success so far */ ++ return FAIL; ++ ++ #undef NCONFIGS ++ } ++ ++ /* ++ * Produce the bytes for equivalence class "c". ++ * Currently only handles latin1, latin9 and utf-8. ++ * Emits bytes in postfix notation: 'a,b,NFA_OR,c,NFA_OR' is ++ * equivalent to 'a OR b OR c' ++ * ++ * NOTE! When changing this function, also update reg_equi_class() ++ */ ++ static int ++ nfa_emit_equi_class(c, neg) ++ int c; ++ int neg; ++ { ++ int first = TRUE; ++ int glue = neg == TRUE ? NFA_CONCAT : NFA_OR; ++ #define EMIT2(c) \ ++ EMIT(c); \ ++ if (neg == TRUE) { \ ++ EMIT(NFA_NOT); \ ++ } \ ++ if (first == FALSE) \ ++ EMIT(glue); \ ++ else \ ++ first = FALSE; \ ++ ++ #ifdef FEAT_MBYTE ++ if (enc_utf8 || STRCMP(p_enc, "latin1") == 0 ++ || STRCMP(p_enc, "iso-8859-15") == 0) ++ #endif ++ { ++ switch (c) ++ { ++ case 'A': case '\300': case '\301': case '\302': ++ case '\303': case '\304': case '\305': ++ EMIT2('A'); EMIT2('\300'); EMIT2('\301'); ++ EMIT2('\302'); EMIT2('\303'); EMIT2('\304'); ++ EMIT2('\305'); ++ return OK; ++ ++ case 'C': case '\307': ++ EMIT2('C'); EMIT2('\307'); ++ return OK; ++ ++ case 'E': case '\310': case '\311': case '\312': case '\313': ++ EMIT2('E'); EMIT2('\310'); EMIT2('\311'); ++ EMIT2('\312'); EMIT2('\313'); ++ return OK; ++ ++ case 'I': case '\314': case '\315': case '\316': case '\317': ++ EMIT2('I'); EMIT2('\314'); EMIT2('\315'); ++ EMIT2('\316'); EMIT2('\317'); ++ return OK; ++ ++ case 'N': case '\321': ++ EMIT2('N'); EMIT2('\321'); ++ return OK; ++ ++ case 'O': case '\322': case '\323': case '\324': case '\325': ++ case '\326': ++ EMIT2('O'); EMIT2('\322'); EMIT2('\323'); ++ EMIT2('\324'); EMIT2('\325'); EMIT2('\326'); ++ return OK; ++ ++ case 'U': case '\331': case '\332': case '\333': case '\334': ++ EMIT2('U'); EMIT2('\331'); EMIT2('\332'); ++ EMIT2('\333'); EMIT2('\334'); ++ return OK; ++ ++ case 'Y': case '\335': ++ EMIT2('Y'); EMIT2('\335'); ++ return OK; ++ ++ case 'a': case '\340': case '\341': case '\342': ++ case '\343': case '\344': case '\345': ++ EMIT2('a'); EMIT2('\340'); EMIT2('\341'); ++ EMIT2('\342'); EMIT2('\343'); EMIT2('\344'); ++ EMIT2('\345'); ++ return OK; ++ ++ case 'c': case '\347': ++ EMIT2('c'); EMIT2('\347'); ++ return OK; ++ ++ case 'e': case '\350': case '\351': case '\352': case '\353': ++ EMIT2('e'); EMIT2('\350'); EMIT2('\351'); ++ EMIT2('\352'); EMIT2('\353'); ++ return OK; ++ ++ case 'i': case '\354': case '\355': case '\356': case '\357': ++ EMIT2('i'); EMIT2('\354'); EMIT2('\355'); ++ EMIT2('\356'); EMIT2('\357'); ++ return OK; ++ ++ case 'n': case '\361': ++ EMIT2('n'); EMIT2('\361'); ++ return OK; ++ ++ case 'o': case '\362': case '\363': case '\364': case '\365': ++ case '\366': ++ EMIT2('o'); EMIT2('\362'); EMIT2('\363'); ++ EMIT2('\364'); EMIT2('\365'); EMIT2('\366'); ++ return OK; ++ ++ case 'u': case '\371': case '\372': case '\373': case '\374': ++ EMIT2('u'); EMIT2('\371'); EMIT2('\372'); ++ EMIT2('\373'); EMIT2('\374'); ++ return OK; ++ ++ case 'y': case '\375': case '\377': ++ EMIT2('y'); EMIT2('\375'); EMIT2('\377'); ++ return OK; ++ ++ default: ++ return FAIL; ++ } ++ } ++ ++ EMIT(c); ++ return OK; ++ #undef EMIT2 ++ } ++ ++ /* ++ * Code to parse regular expression. ++ * ++ * We try to reuse parsing functions in regexp.c to ++ * minimize surprise and keep the syntax consistent. ++ */ ++ ++ /* ++ * Increments the pointer "p" by one (multi-byte) character. ++ */ ++ static void ++ nfa_inc(p) ++ char_u **p; ++ { ++ #ifdef FEAT_MBYTE ++ if (has_mbyte) ++ mb_ptr2char_adv(p); ++ else ++ #endif ++ *p = *p + 1; ++ } ++ ++ /* ++ * Decrements the pointer "p" by one (multi-byte) character. ++ */ ++ static void ++ nfa_dec(p) ++ char_u **p; ++ { ++ #ifdef FEAT_MBYTE ++ char_u *p2, *oldp; ++ ++ if (has_mbyte) ++ { ++ oldp = *p; ++ /* Try to find the multibyte char that advances to the current ++ * position. */ ++ do ++ { ++ *p = *p - 1; ++ p2 = *p; ++ mb_ptr2char_adv(&p2); ++ } while (p2 != oldp); ++ } ++ #else ++ *p = *p - 1; ++ #endif ++ } ++ ++ /* ++ * Parse the lowest level. ++ * ++ * An atom can be one of a long list of items. Many atoms match one character ++ * in the text. It is often an ordinary character or a character class. ++ * Braces can be used to make a pattern into an atom. The "\z(\)" construct ++ * is only for syntax highlighting. ++ * ++ * atom ::= ordinary-atom ++ * or \( pattern \) ++ * or \%( pattern \) ++ * or \z( pattern \) ++ */ ++ static int ++ nfa_regatom() ++ { ++ int c; ++ int charclass; ++ int equiclass; ++ int collclass; ++ int got_coll_char; ++ char_u *p; ++ char_u *endp; ++ #ifdef FEAT_MBYTE ++ char_u *old_regparse = regparse; ++ int clen; ++ int len; ++ static char_u buf[30]; ++ int i; ++ #endif ++ int extra = 0; ++ int first; ++ int emit_range; ++ int negated; ++ int result; ++ int startc = -1; ++ int endc = -1; ++ int oldstartc = -1; ++ int cpo_lit; /* 'cpoptions' contains 'l' flag */ ++ int cpo_bsl; /* 'cpoptions' contains '\' flag */ ++ int glue; /* ID that will "glue" nodes together */ ++ ++ cpo_lit = vim_strchr(p_cpo, CPO_LITERAL) != NULL; ++ cpo_bsl = vim_strchr(p_cpo, CPO_BACKSL) != NULL; ++ ++ c = getchr(); ++ ++ #ifdef FEAT_MBYTE ++ /* clen has the length of the current char, without composing chars */ ++ clen = (*mb_char2len)(c); ++ if (has_mbyte && clen > 1) ++ goto nfa_do_multibyte; ++ #endif ++ switch (c) ++ { ++ case Magic('^'): ++ EMIT(NFA_BOL); ++ break; ++ ++ case Magic('$'): ++ EMIT(NFA_EOL); ++ #if defined(FEAT_SYN_HL) || defined(PROTO) ++ had_eol = TRUE; ++ #endif ++ break; ++ ++ case Magic('<'): ++ EMIT(NFA_BOW); ++ break; ++ ++ case Magic('>'): ++ EMIT(NFA_EOW); ++ break; ++ ++ case Magic('_'): ++ c = no_Magic(getchr()); ++ if (c == '^') /* "\_^" is start-of-line */ ++ { ++ EMIT(NFA_BOL); ++ break; ++ } ++ if (c == '$') /* "\_$" is end-of-line */ ++ { ++ EMIT(NFA_EOL); ++ #if defined(FEAT_SYN_HL) || defined(PROTO) ++ had_eol = TRUE; ++ #endif ++ break; ++ } ++ ++ extra = ADD_NL; ++ ++ /* "\_[" is collection plus newline */ ++ if (c == '[') ++ /* TODO: make this work ++ * goto collection; */ ++ return FAIL; ++ ++ /* "\_x" is character class plus newline */ ++ /*FALLTHROUGH*/ ++ ++ /* ++ * Character classes. ++ */ ++ case Magic('.'): ++ case Magic('i'): ++ case Magic('I'): ++ case Magic('k'): ++ case Magic('K'): ++ case Magic('f'): ++ case Magic('F'): ++ case Magic('p'): ++ case Magic('P'): ++ case Magic('s'): ++ case Magic('S'): ++ case Magic('d'): ++ case Magic('D'): ++ case Magic('x'): ++ case Magic('X'): ++ case Magic('o'): ++ case Magic('O'): ++ case Magic('w'): ++ case Magic('W'): ++ case Magic('h'): ++ case Magic('H'): ++ case Magic('a'): ++ case Magic('A'): ++ case Magic('l'): ++ case Magic('L'): ++ case Magic('u'): ++ case Magic('U'): ++ p = vim_strchr(classchars, no_Magic(c)); ++ if (p == NULL) ++ { ++ return FAIL; /* runtime error */ ++ } ++ #ifdef FEAT_MBYTE ++ /* When '.' is followed by a composing char ignore the dot, so that ++ * the composing char is matched here. */ ++ if (enc_utf8 && c == Magic('.') && utf_iscomposing(peekchr())) ++ { ++ c = getchr(); ++ goto nfa_do_multibyte; ++ } ++ #endif ++ EMIT(nfa_classcodes[p - classchars]); ++ if (extra == ADD_NL) ++ { ++ EMIT(NFA_NEWL); ++ EMIT(NFA_OR); ++ regflags |= RF_HASNL; ++ } ++ break; ++ ++ case Magic('n'): ++ if (reg_string) ++ /* In a string "\n" matches a newline character. */ ++ EMIT(NL); ++ else ++ { ++ /* In buffer text "\n" matches the end of a line. */ ++ EMIT(NFA_NEWL); ++ regflags |= RF_HASNL; ++ } ++ break; ++ ++ case Magic('('): ++ if (nfa_reg(REG_PAREN) == FAIL) ++ return FAIL; /* cascaded error */ ++ break; ++ ++ case NUL: ++ syntax_error = TRUE; ++ EMSG_RET_FAIL(_("E865: (NFA) Regexp end encountered prematurely")); ++ ++ case Magic('|'): ++ case Magic('&'): ++ case Magic(')'): ++ syntax_error = TRUE; ++ EMSG2(_(e_misplaced), no_Magic(c)); ++ return FAIL; ++ ++ case Magic('='): ++ case Magic('?'): ++ case Magic('+'): ++ case Magic('@'): ++ case Magic('*'): ++ case Magic('{'): ++ /* these should follow an atom, not form an atom */ ++ syntax_error = TRUE; ++ EMSG2(_(e_misplaced), no_Magic(c)); ++ return FAIL; ++ ++ case Magic('~'): /* previous substitute pattern */ ++ /* Not supported yet */ ++ return FAIL; ++ ++ case Magic('1'): ++ case Magic('2'): ++ case Magic('3'): ++ case Magic('4'): ++ case Magic('5'): ++ case Magic('6'): ++ case Magic('7'): ++ case Magic('8'): ++ case Magic('9'): ++ /* not supported yet */ ++ return FAIL; ++ ++ case Magic('z'): ++ c = no_Magic(getchr()); ++ switch (c) ++ { ++ case 's': ++ EMIT(NFA_ZSTART); ++ break; ++ case 'e': ++ EMIT(NFA_ZEND); ++ nfa_has_zend = TRUE; ++ /* TODO: Currently \ze does not work properly. */ ++ return FAIL; ++ /* break; */ ++ case '1': ++ case '2': ++ case '3': ++ case '4': ++ case '5': ++ case '6': ++ case '7': ++ case '8': ++ case '9': ++ case '(': ++ /* \z1...\z9 and \z( not yet supported */ ++ return FAIL; ++ default: ++ syntax_error = TRUE; ++ EMSG2(_("E867: (NFA) Unknown operator '\\z%c'"), ++ no_Magic(c)); ++ return FAIL; ++ } ++ break; ++ ++ case Magic('%'): ++ c = no_Magic(getchr()); ++ switch (c) ++ { ++ /* () without a back reference */ ++ case '(': ++ if (nfa_reg(REG_NPAREN) == FAIL) ++ return FAIL; ++ EMIT(NFA_NOPEN); ++ break; ++ ++ case 'd': /* %d123 decimal */ ++ case 'o': /* %o123 octal */ ++ case 'x': /* %xab hex 2 */ ++ case 'u': /* %uabcd hex 4 */ ++ case 'U': /* %U1234abcd hex 8 */ ++ /* Not yet supported */ ++ return FAIL; ++ ++ c = coll_get_char(); ++ #ifdef FEAT_MBYTE ++ if ((*mb_char2len)(c) > 1) ++ { ++ EMIT_MBYTE(c); ++ } ++ else ++ #endif ++ EMIT(c); ++ break; ++ ++ /* Catch \%^ and \%$ regardless of where they appear in the ++ * pattern -- regardless of whether or not it makes sense. */ ++ case '^': ++ EMIT(NFA_BOF); ++ /* Not yet supported */ ++ return FAIL; ++ break; ++ ++ case '$': ++ EMIT(NFA_EOF); ++ /* Not yet supported */ ++ return FAIL; ++ break; ++ ++ case '#': ++ /* not supported yet */ ++ return FAIL; ++ break; ++ ++ case 'V': ++ /* not supported yet */ ++ return FAIL; ++ break; ++ ++ case '[': ++ /* \%[abc] not supported yet */ ++ return FAIL; ++ ++ default: ++ /* not supported yet */ ++ return FAIL; ++ } ++ break; ++ ++ /* collection: */ ++ case Magic('['): ++ /* ++ * Glue is emitted between several atoms from the []. ++ * It is either NFA_OR, or NFA_CONCAT. ++ * ++ * [abc] expands to 'a b NFA_OR c NFA_OR' (in postfix notation) ++ * [^abc] expands to 'a NFA_NOT b NFA_NOT NFA_CONCAT c NFA_NOT ++ * NFA_CONCAT NFA_END_NEG_RANGE NFA_CONCAT' (in postfix ++ * notation) ++ * ++ */ ++ ++ ++ /* Emit negation atoms, if needed. ++ * The CONCAT below merges the NOT with the previous node. */ ++ #define TRY_NEG() \ ++ if (negated == TRUE) \ ++ { \ ++ EMIT(NFA_NOT); \ ++ } ++ ++ /* Emit glue between important nodes : CONCAT or OR. */ ++ #define EMIT_GLUE() \ ++ if (first == FALSE) \ ++ EMIT(glue); \ ++ else \ ++ first = FALSE; ++ ++ p = regparse; ++ endp = skip_anyof(p); ++ if (*endp == ']') ++ { ++ /* ++ * Try to reverse engineer character classes. For example, ++ * recognize that [0-9] stands for \d and [A-Za-z_] with \h, ++ * and perform the necessary substitutions in the NFA. ++ */ ++ result = nfa_recognize_char_class(regparse, endp, ++ extra == ADD_NL); ++ if (result != FAIL) ++ { ++ if (result >= NFA_DIGIT && result <= NFA_NUPPER) ++ EMIT(result); ++ else /* must be char class + newline */ ++ { ++ EMIT(result - ADD_NL); ++ EMIT(NFA_NEWL); ++ EMIT(NFA_OR); ++ } ++ regparse = endp; ++ nfa_inc(®parse); ++ return OK; ++ } ++ /* ++ * Failed to recognize a character class. Use the simple ++ * version that turns [abc] into 'a' OR 'b' OR 'c' ++ */ ++ startc = endc = oldstartc = -1; ++ first = TRUE; /* Emitting first atom in this sequence? */ ++ negated = FALSE; ++ glue = NFA_OR; ++ if (*regparse == '^') /* negated range */ ++ { ++ negated = TRUE; ++ glue = NFA_CONCAT; ++ nfa_inc(®parse); ++ } ++ if (*regparse == '-') ++ { ++ startc = '-'; ++ EMIT(startc); ++ TRY_NEG(); ++ EMIT_GLUE(); ++ nfa_inc(®parse); ++ } ++ /* Emit the OR branches for each character in the [] */ ++ emit_range = FALSE; ++ while (regparse < endp) ++ { ++ oldstartc = startc; ++ startc = -1; ++ got_coll_char = FALSE; ++ if (*regparse == '[') ++ { ++ /* Check for [: :], [= =], [. .] */ ++ equiclass = collclass = 0; ++ charclass = get_char_class(®parse); ++ if (charclass == CLASS_NONE) ++ { ++ equiclass = get_equi_class(®parse); ++ if (equiclass == 0) ++ collclass = get_coll_element(®parse); ++ } ++ ++ /* Character class like [:alpha:] */ ++ if (charclass != CLASS_NONE) ++ { ++ switch (charclass) ++ { ++ case CLASS_ALNUM: ++ EMIT(NFA_CLASS_ALNUM); ++ break; ++ case CLASS_ALPHA: ++ EMIT(NFA_CLASS_ALPHA); ++ break; ++ case CLASS_BLANK: ++ EMIT(NFA_CLASS_BLANK); ++ break; ++ case CLASS_CNTRL: ++ EMIT(NFA_CLASS_CNTRL); ++ break; ++ case CLASS_DIGIT: ++ EMIT(NFA_CLASS_DIGIT); ++ break; ++ case CLASS_GRAPH: ++ EMIT(NFA_CLASS_GRAPH); ++ break; ++ case CLASS_LOWER: ++ EMIT(NFA_CLASS_LOWER); ++ break; ++ case CLASS_PRINT: ++ EMIT(NFA_CLASS_PRINT); ++ break; ++ case CLASS_PUNCT: ++ EMIT(NFA_CLASS_PUNCT); ++ break; ++ case CLASS_SPACE: ++ EMIT(NFA_CLASS_SPACE); ++ break; ++ case CLASS_UPPER: ++ EMIT(NFA_CLASS_UPPER); ++ break; ++ case CLASS_XDIGIT: ++ EMIT(NFA_CLASS_XDIGIT); ++ break; ++ case CLASS_TAB: ++ EMIT(NFA_CLASS_TAB); ++ break; ++ case CLASS_RETURN: ++ EMIT(NFA_CLASS_RETURN); ++ break; ++ case CLASS_BACKSPACE: ++ EMIT(NFA_CLASS_BACKSPACE); ++ break; ++ case CLASS_ESCAPE: ++ EMIT(NFA_CLASS_ESCAPE); ++ break; ++ } ++ TRY_NEG(); ++ EMIT_GLUE(); ++ continue; ++ } ++ /* Try equivalence class [=a=] and the like */ ++ if (equiclass != 0) ++ { ++ result = nfa_emit_equi_class(equiclass, negated); ++ if (result == FAIL) ++ { ++ /* should never happen */ ++ EMSG_RET_FAIL(_("E868: Error building NFA with equivalence class!")); ++ } ++ EMIT_GLUE(); ++ continue; ++ } ++ /* Try collating class like [. .] */ ++ if (collclass != 0) ++ { ++ startc = collclass; /* allow [.a.]-x as a range */ ++ /* Will emit the proper atom at the end of the ++ * while loop. */ ++ } ++ } ++ /* Try a range like 'a-x' or '\t-z' */ ++ if (*regparse == '-') ++ { ++ emit_range = TRUE; ++ startc = oldstartc; ++ nfa_inc(®parse); ++ continue; /* reading the end of the range */ ++ } ++ ++ /* Now handle simple and escaped characters. ++ * Only "\]", "\^", "\]" and "\\" are special in Vi. Vim ++ * accepts "\t", "\e", etc., but only when the 'l' flag in ++ * 'cpoptions' is not included. ++ * Posix doesn't recognize backslash at all. ++ */ ++ if (*regparse == '\\' ++ && !cpo_bsl ++ && regparse + 1 <= endp ++ && (vim_strchr(REGEXP_INRANGE, regparse[1]) != NULL ++ || (!cpo_lit ++ && vim_strchr(REGEXP_ABBR, regparse[1]) ++ != NULL) ++ ) ++ ) ++ { ++ nfa_inc(®parse); ++ ++ if (*regparse == 'n' || *regparse == 'n') ++ startc = reg_string ? NL : NFA_NEWL; ++ else ++ if (*regparse == 'd' ++ || *regparse == 'o' ++ || *regparse == 'x' ++ || *regparse == 'u' ++ || *regparse == 'U' ++ ) ++ { ++ /* TODO(RE) This needs more testing */ ++ startc = coll_get_char(); ++ got_coll_char = TRUE; ++ nfa_dec(®parse); ++ } ++ else ++ { ++ /* \r,\t,\e,\b */ ++ startc = backslash_trans(*regparse); ++ } ++ } ++ ++ /* Normal printable char */ ++ if (startc == -1) ++ #ifdef FEAT_MBYTE ++ startc = (*mb_ptr2char)(regparse); ++ #else ++ startc = *regparse; ++ #endif ++ ++ /* Previous char was '-', so this char is end of range. */ ++ if (emit_range) ++ { ++ endc = startc; startc = oldstartc; ++ if (startc > endc) ++ EMSG_RET_FAIL(_(e_invrange)); ++ #ifdef FEAT_MBYTE ++ if (has_mbyte && ((*mb_char2len)(startc) > 1 ++ || (*mb_char2len)(endc) > 1)) ++ { ++ if (endc > startc + 256) ++ EMSG_RET_FAIL(_(e_invrange)); ++ /* Emit the range. "startc" was already emitted, so ++ * skip it. */ ++ for (c = startc + 1; c <= endc; c++) ++ { ++ if ((*mb_char2len)(c) > 1) ++ { ++ EMIT_MBYTE(c); ++ } ++ else ++ EMIT(c); ++ TRY_NEG(); ++ EMIT_GLUE(); ++ } ++ emit_range = FALSE; ++ } ++ else ++ #endif ++ { ++ #ifdef EBCDIC ++ int alpha_only = FALSE; ++ ++ /* for alphabetical range skip the gaps ++ * 'i'-'j', 'r'-'s', 'I'-'J' and 'R'-'S'. */ ++ if (isalpha(startc) && isalpha(endc)) ++ alpha_only = TRUE; ++ #endif ++ /* Emit the range. "startc" was already emitted, so ++ * skip it. */ ++ for (c = startc + 1; c <= endc; c++) ++ #ifdef EBCDIC ++ if (!alpha_only || isalpha(startc)) ++ #endif ++ { ++ EMIT(c); ++ TRY_NEG(); ++ EMIT_GLUE(); ++ } ++ emit_range = FALSE; ++ } ++ } ++ else ++ { ++ /* ++ * This char (startc) is not part of a range. Just ++ * emit it. ++ * ++ * Normally, simply emit startc. But if we get char ++ * code=0 from a collating char, then replace it with ++ * 0x0a. ++ * ++ * This is needed to completely mimic the behaviour of ++ * the backtracking engine. ++ */ ++ if (got_coll_char == TRUE && startc == 0) ++ EMIT(0x0a); ++ else ++ #ifdef FEAT_MBYTE ++ if ((*mb_char2len)(startc) > 1) ++ { ++ EMIT_MBYTE(startc); ++ } ++ else ++ #endif ++ EMIT(startc); ++ TRY_NEG(); ++ EMIT_GLUE(); ++ } ++ ++ nfa_inc(®parse); ++ } /* while (p < endp) */ ++ ++ nfa_dec(®parse); ++ if (*regparse == '-') /* if last, '-' is just a char */ ++ { ++ EMIT('-'); ++ TRY_NEG(); ++ EMIT_GLUE(); ++ } ++ nfa_inc(®parse); ++ ++ if (extra == ADD_NL) /* \_[] also matches \n */ ++ { ++ EMIT(reg_string ? NL : NFA_NEWL); ++ TRY_NEG(); ++ EMIT_GLUE(); ++ } ++ ++ /* skip the trailing ] */ ++ regparse = endp; ++ nfa_inc(®parse); ++ if (negated == TRUE) ++ { ++ /* Mark end of negated char range */ ++ EMIT(NFA_END_NEG_RANGE); ++ EMIT(NFA_CONCAT); ++ } ++ return OK; ++ } /* if exists closing ] */ ++ else if (reg_strict) ++ { ++ syntax_error = TRUE; ++ EMSG_RET_FAIL(_(e_missingbracket)); ++ } ++ ++ /* FALLTHROUGH */ ++ default: ++ { ++ #ifdef FEAT_MBYTE ++ int plen; ++ ++ nfa_do_multibyte: ++ /* length of current char, with composing chars, ++ * from pointer */ ++ plen = (*mb_ptr2len)(old_regparse); ++ if (enc_utf8 && clen != plen) ++ { ++ /* A composing character is always handled as a ++ * separate atom, surrounded by NFA_COMPOSING and ++ * NFA_END_COMPOSING. Note that right now we are ++ * building the postfix form, not the NFA itself; ++ * a composing char could be: a, b, c, NFA_COMPOSING ++ * where 'a', 'b', 'c' are chars with codes > 256. ++ */ ++ EMIT_COMPOSING_UTF(old_regparse); ++ regparse = old_regparse + plen; ++ } ++ else ++ /* A multi-byte character is always handled as a ++ * separate atom, surrounded by NFA_MULTIBYTE and ++ * NFA_END_MULTIBYTE */ ++ if (plen > 1) ++ { ++ EMIT_MBYTE(c); ++ } ++ else ++ #endif ++ { ++ c = no_Magic(c); ++ EMIT(c); ++ } ++ return OK; ++ } ++ } ++ ++ #undef TRY_NEG ++ #undef EMIT_GLUE ++ ++ return OK; ++ } ++ ++ /* ++ * Parse something followed by possible [*+=]. ++ * ++ * A piece is an atom, possibly followed by a multi, an indication of how many ++ * times the atom can be matched. Example: "a*" matches any sequence of "a" ++ * characters: "", "a", "aa", etc. ++ * ++ * piece ::= atom ++ * or atom multi ++ */ ++ static int ++ nfa_regpiece() ++ { ++ int i; ++ int op; ++ int ret; ++ long minval, maxval; ++ int greedy = TRUE; /* Braces are prefixed with '-' ? */ ++ char_u *old_regparse, *new_regparse; ++ int c2; ++ int *old_post_ptr, *my_post_start; ++ int old_regnpar; ++ int quest; ++ ++ /* Save the current position in the regexp, so that we can use it if ++ * {m,n} is next. */ ++ old_regparse = regparse; ++ /* Save current number of open parenthesis, so we can use it if ++ * {m,n} is next */ ++ old_regnpar = regnpar; ++ /* store current pos in the postfix form, for \{m,n} involving 0s */ ++ my_post_start = post_ptr; ++ ++ ret = nfa_regatom(); ++ if (ret == FAIL) ++ return FAIL; /* cascaded error */ ++ ++ op = peekchr(); ++ if (re_multi_type(op) == NOT_MULTI) ++ return OK; ++ ++ skipchr(); ++ switch (op) ++ { ++ case Magic('*'): ++ EMIT(NFA_STAR); ++ break; ++ ++ case Magic('+'): ++ /* ++ * Trick: Normally, (a*)\+ would match the whole input "aaa". The ++ * first and only submatch would be "aaa". But the backtracking ++ * engine interprets the plus as "try matching one more time", and ++ * a* matches a second time at the end of the input, the empty ++ * string. ++ * The submatch will the empty string. ++ * ++ * In order to be consistent with the old engine, we disable ++ * NFA_PLUS, and replace + with * ++ */ ++ /* EMIT(NFA_PLUS); */ ++ regnpar = old_regnpar; ++ regparse = old_regparse; ++ curchr = -1; ++ if (nfa_regatom() == FAIL) ++ return FAIL; ++ EMIT(NFA_STAR); ++ EMIT(NFA_CONCAT); ++ skipchr(); /* skip the \+ */ ++ break; ++ ++ case Magic('@'): ++ op = no_Magic(getchr()); ++ switch(op) ++ { ++ case '=': ++ EMIT(NFA_PREV_ATOM_NO_WIDTH); ++ break; ++ case '!': ++ case '<': ++ case '>': ++ /* Not supported yet */ ++ return FAIL; ++ default: ++ syntax_error = TRUE; ++ EMSG2(_("E869: (NFA) Unknown operator '\\@%c'"), op); ++ return FAIL; ++ } ++ break; ++ ++ case Magic('?'): ++ case Magic('='): ++ EMIT(NFA_QUEST); ++ break; ++ ++ case Magic('{'): ++ /* a{2,5} will expand to 'aaa?a?a?' ++ * a{-1,3} will expand to 'aa??a??', where ?? is the nongreedy ++ * version of '?' ++ * \v(ab){2,3} will expand to '(ab)(ab)(ab)?', where all the ++ * parenthesis have the same id ++ */ ++ ++ greedy = TRUE; ++ c2 = peekchr(); ++ if (c2 == '-' || c2 == Magic('-')) ++ { ++ skipchr(); ++ greedy = FALSE; ++ } ++ if (!read_limits(&minval, &maxval)) ++ { ++ syntax_error = TRUE; ++ EMSG_RET_FAIL(_("E870: (NFA regexp) Error reading repetition limits")); ++ } ++ /* {0,inf}, {0,} and {} are equivalent to ++ * * */ ++ if (minval == 0 && maxval == MAX_LIMIT && greedy) ++ { ++ EMIT(NFA_STAR); ++ break; ++ } ++ ++ if (maxval > NFA_BRACES_MAXLIMIT) ++ { ++ /* This would yield a huge automaton and use too much memory. ++ * Revert to old engine */ ++ return FAIL; ++ } ++ ++ /* Special case: x{0} or x{-0} */ ++ if (maxval == 0) ++ { ++ /* Ignore result of previous call to nfa_regatom() */ ++ post_ptr = my_post_start; ++ /* NFA_SKIP_CHAR has 0-length and works everywhere */ ++ EMIT(NFA_SKIP_CHAR); ++ return OK; ++ } ++ ++ /* Ignore previous call to nfa_regatom() */ ++ post_ptr = my_post_start; ++ /* Save pos after the repeated atom and the \{} */ ++ new_regparse = regparse; ++ ++ new_regparse = regparse; ++ quest = (greedy == TRUE? NFA_QUEST : NFA_QUEST_NONGREEDY); ++ for (i = 0; i < maxval; i++) ++ { ++ /* Goto beginning of the repeated atom */ ++ regparse = old_regparse; ++ curchr = -1; ++ /* Restore count of parenthesis */ ++ regnpar = old_regnpar; ++ old_post_ptr = post_ptr; ++ if (nfa_regatom() == FAIL) ++ return FAIL; ++ /* after "minval" times, atoms are optional */ ++ if (i + 1 > minval) ++ EMIT(quest); ++ if (old_post_ptr != my_post_start) ++ EMIT(NFA_CONCAT); ++ } ++ ++ /* Go to just after the repeated atom and the \{} */ ++ regparse = new_regparse; ++ curchr = -1; ++ ++ break; ++ ++ ++ default: ++ break; ++ } /* end switch */ ++ ++ if (re_multi_type(peekchr()) != NOT_MULTI) ++ { ++ /* Can't have a multi follow a multi. */ ++ syntax_error = TRUE; ++ EMSG_RET_FAIL(_("E871: (NFA regexp) Can't have a multi follow a multi !")); ++ } ++ ++ return OK; ++ } ++ ++ /* ++ * Parse one or more pieces, concatenated. It matches a match for the ++ * first piece, followed by a match for the second piece, etc. Example: ++ * "f[0-9]b", first matches "f", then a digit and then "b". ++ * ++ * concat ::= piece ++ * or piece piece ++ * or piece piece piece ++ * etc. ++ */ ++ static int ++ nfa_regconcat() ++ { ++ int cont = TRUE; ++ int first = TRUE; ++ ++ while (cont) ++ { ++ switch (peekchr()) ++ { ++ case NUL: ++ case Magic('|'): ++ case Magic('&'): ++ case Magic(')'): ++ cont = FALSE; ++ break; ++ ++ case Magic('Z'): ++ #ifdef FEAT_MBYTE ++ regflags |= RF_ICOMBINE; ++ #endif ++ skipchr_keepstart(); ++ break; ++ case Magic('c'): ++ regflags |= RF_ICASE; ++ skipchr_keepstart(); ++ break; ++ case Magic('C'): ++ regflags |= RF_NOICASE; ++ skipchr_keepstart(); ++ break; ++ case Magic('v'): ++ reg_magic = MAGIC_ALL; ++ skipchr_keepstart(); ++ curchr = -1; ++ break; ++ case Magic('m'): ++ reg_magic = MAGIC_ON; ++ skipchr_keepstart(); ++ curchr = -1; ++ break; ++ case Magic('M'): ++ reg_magic = MAGIC_OFF; ++ skipchr_keepstart(); ++ curchr = -1; ++ break; ++ case Magic('V'): ++ reg_magic = MAGIC_NONE; ++ skipchr_keepstart(); ++ curchr = -1; ++ break; ++ ++ default: ++ if (nfa_regpiece() == FAIL) ++ return FAIL; ++ if (first == FALSE) ++ EMIT(NFA_CONCAT); ++ else ++ first = FALSE; ++ break; ++ } ++ } ++ ++ return OK; ++ } ++ ++ /* ++ * Parse a branch, one or more concats, separated by "\&". It matches the ++ * last concat, but only if all the preceding concats also match at the same ++ * position. Examples: ++ * "foobeep\&..." matches "foo" in "foobeep". ++ * ".*Peter\&.*Bob" matches in a line containing both "Peter" and "Bob" ++ * ++ * branch ::= concat ++ * or concat \& concat ++ * or concat \& concat \& concat ++ * etc. ++ */ ++ static int ++ nfa_regbranch() ++ { ++ int ch; ++ int *old_post_ptr; ++ ++ old_post_ptr = post_ptr; ++ ++ /* First branch, possibly the only one */ ++ if (nfa_regconcat() == FAIL) ++ return FAIL; ++ ++ ch = peekchr(); ++ /* Try next concats */ ++ while (ch == Magic('&')) ++ { ++ skipchr(); ++ EMIT(NFA_NOPEN); ++ EMIT(NFA_PREV_ATOM_NO_WIDTH); ++ old_post_ptr = post_ptr; ++ if (nfa_regconcat() == FAIL) ++ return FAIL; ++ /* if concat is empty, skip a input char. But do emit a node */ ++ if (old_post_ptr == post_ptr) ++ EMIT(NFA_SKIP_CHAR); ++ EMIT(NFA_CONCAT); ++ ch = peekchr(); ++ } ++ ++ /* Even if a branch is empty, emit one node for it */ ++ if (old_post_ptr == post_ptr) ++ EMIT(NFA_SKIP_CHAR); ++ ++ return OK; ++ } ++ ++ /* ++ * Parse a pattern, one or more branches, separated by "\|". It matches ++ * anything that matches one of the branches. Example: "foo\|beep" matches ++ * "foo" and matches "beep". If more than one branch matches, the first one ++ * is used. ++ * ++ * pattern ::= branch ++ * or branch \| branch ++ * or branch \| branch \| branch ++ * etc. ++ */ ++ static int ++ nfa_reg(paren) ++ int paren; /* REG_NOPAREN, REG_PAREN, REG_NPAREN or REG_ZPAREN */ ++ { ++ int parno = 0; ++ ++ #ifdef FEAT_SYN_HL ++ #endif ++ if (paren == REG_PAREN) ++ { ++ if (regnpar >= NSUBEXP) /* Too many `(' */ ++ { ++ syntax_error = TRUE; ++ EMSG_RET_FAIL(_("E872: (NFA regexp) Too many '('")); ++ } ++ parno = regnpar++; ++ } ++ ++ if (nfa_regbranch() == FAIL) ++ return FAIL; /* cascaded error */ ++ ++ while (peekchr() == Magic('|')) ++ { ++ skipchr(); ++ if (nfa_regbranch() == FAIL) ++ return FAIL; /* cascaded error */ ++ EMIT(NFA_OR); ++ } ++ ++ /* Check for proper termination. */ ++ if (paren != REG_NOPAREN && getchr() != Magic(')')) ++ { ++ syntax_error = TRUE; ++ if (paren == REG_NPAREN) ++ EMSG2_RET_FAIL(_(e_unmatchedpp), reg_magic == MAGIC_ALL); ++ else ++ EMSG2_RET_FAIL(_(e_unmatchedp), reg_magic == MAGIC_ALL); ++ } ++ else if (paren == REG_NOPAREN && peekchr() != NUL) ++ { ++ syntax_error = TRUE; ++ if (peekchr() == Magic(')')) ++ EMSG2_RET_FAIL(_(e_unmatchedpar), reg_magic == MAGIC_ALL); ++ else ++ EMSG_RET_FAIL(_("E873: (NFA regexp) proper termination error")); ++ } ++ /* ++ * Here we set the flag allowing back references to this set of ++ * parentheses. ++ */ ++ if (paren == REG_PAREN) ++ { ++ had_endbrace[parno] = TRUE; /* have seen the close paren */ ++ EMIT(NFA_MOPEN + parno); ++ } ++ ++ return OK; ++ } ++ ++ typedef struct ++ { ++ char_u *start[NSUBEXP]; ++ char_u *end[NSUBEXP]; ++ lpos_T startpos[NSUBEXP]; ++ lpos_T endpos[NSUBEXP]; ++ } regsub_T; ++ ++ static int nfa_regmatch __ARGS((nfa_state_T *start, regsub_T *submatch, regsub_T *m)); ++ ++ #ifdef DEBUG ++ static char_u code[50]; ++ ++ static void ++ nfa_set_code(c) ++ int c; ++ { ++ int addnl = FALSE; ++ ++ if (c >= NFA_FIRST_NL && c <= NFA_LAST_NL) ++ { ++ addnl = TRUE; ++ c -= ADD_NL; ++ } ++ ++ STRCPY(code, ""); ++ switch (c) ++ { ++ case NFA_MATCH: STRCPY(code, "NFA_MATCH "); break; ++ case NFA_SPLIT: STRCPY(code, "NFA_SPLIT "); break; ++ case NFA_CONCAT: STRCPY(code, "NFA_CONCAT "); break; ++ case NFA_NEWL: STRCPY(code, "NFA_NEWL "); break; ++ case NFA_ZSTART: STRCPY(code, "NFA_ZSTART"); break; ++ case NFA_ZEND: STRCPY(code, "NFA_ZEND"); break; ++ ++ case NFA_PREV_ATOM_NO_WIDTH: ++ STRCPY(code, "NFA_PREV_ATOM_NO_WIDTH"); break; ++ case NFA_NOPEN: STRCPY(code, "NFA_MOPEN_INVISIBLE"); break; ++ case NFA_NCLOSE: STRCPY(code, "NFA_MCLOSE_INVISIBLE"); break; ++ case NFA_START_INVISIBLE: STRCPY(code, "NFA_START_INVISIBLE"); break; ++ case NFA_END_INVISIBLE: STRCPY(code, "NFA_END_INVISIBLE"); break; ++ ++ case NFA_MULTIBYTE: STRCPY(code, "NFA_MULTIBYTE"); break; ++ case NFA_END_MULTIBYTE: STRCPY(code, "NFA_END_MULTIBYTE"); break; ++ ++ case NFA_COMPOSING: STRCPY(code, "NFA_COMPOSING"); break; ++ case NFA_END_COMPOSING: STRCPY(code, "NFA_END_COMPOSING"); break; ++ ++ case NFA_MOPEN + 0: ++ case NFA_MOPEN + 1: ++ case NFA_MOPEN + 2: ++ case NFA_MOPEN + 3: ++ case NFA_MOPEN + 4: ++ case NFA_MOPEN + 5: ++ case NFA_MOPEN + 6: ++ case NFA_MOPEN + 7: ++ case NFA_MOPEN + 8: ++ case NFA_MOPEN + 9: ++ STRCPY(code, "NFA_MOPEN(x)"); ++ code[10] = c - NFA_MOPEN + '0'; ++ break; ++ case NFA_MCLOSE + 0: ++ case NFA_MCLOSE + 1: ++ case NFA_MCLOSE + 2: ++ case NFA_MCLOSE + 3: ++ case NFA_MCLOSE + 4: ++ case NFA_MCLOSE + 5: ++ case NFA_MCLOSE + 6: ++ case NFA_MCLOSE + 7: ++ case NFA_MCLOSE + 8: ++ case NFA_MCLOSE + 9: ++ STRCPY(code, "NFA_MCLOSE(x)"); ++ code[11] = c - NFA_MCLOSE + '0'; ++ break; ++ case NFA_EOL: STRCPY(code, "NFA_EOL "); break; ++ case NFA_BOL: STRCPY(code, "NFA_BOL "); break; ++ case NFA_EOW: STRCPY(code, "NFA_EOW "); break; ++ case NFA_BOW: STRCPY(code, "NFA_BOW "); break; ++ case NFA_STAR: STRCPY(code, "NFA_STAR "); break; ++ case NFA_PLUS: STRCPY(code, "NFA_PLUS "); break; ++ case NFA_NOT: STRCPY(code, "NFA_NOT "); break; ++ case NFA_SKIP_CHAR: STRCPY(code, "NFA_SKIP_CHAR"); break; ++ case NFA_OR: STRCPY(code, "NFA_OR"); break; ++ case NFA_QUEST: STRCPY(code, "NFA_QUEST"); break; ++ case NFA_QUEST_NONGREEDY: STRCPY(code, "NFA_QUEST_NON_GREEDY"); break; ++ case NFA_END_NEG_RANGE: STRCPY(code, "NFA_END_NEG_RANGE"); break; ++ case NFA_CLASS_ALNUM: STRCPY(code, "NFA_CLASS_ALNUM"); break; ++ case NFA_CLASS_ALPHA: STRCPY(code, "NFA_CLASS_ALPHA"); break; ++ case NFA_CLASS_BLANK: STRCPY(code, "NFA_CLASS_BLANK"); break; ++ case NFA_CLASS_CNTRL: STRCPY(code, "NFA_CLASS_CNTRL"); break; ++ case NFA_CLASS_DIGIT: STRCPY(code, "NFA_CLASS_DIGIT"); break; ++ case NFA_CLASS_GRAPH: STRCPY(code, "NFA_CLASS_GRAPH"); break; ++ case NFA_CLASS_LOWER: STRCPY(code, "NFA_CLASS_LOWER"); break; ++ case NFA_CLASS_PRINT: STRCPY(code, "NFA_CLASS_PRINT"); break; ++ case NFA_CLASS_PUNCT: STRCPY(code, "NFA_CLASS_PUNCT"); break; ++ case NFA_CLASS_SPACE: STRCPY(code, "NFA_CLASS_SPACE"); break; ++ case NFA_CLASS_UPPER: STRCPY(code, "NFA_CLASS_UPPER"); break; ++ case NFA_CLASS_XDIGIT: STRCPY(code, "NFA_CLASS_XDIGIT"); break; ++ case NFA_CLASS_TAB: STRCPY(code, "NFA_CLASS_TAB"); break; ++ case NFA_CLASS_RETURN: STRCPY(code, "NFA_CLASS_RETURN"); break; ++ case NFA_CLASS_BACKSPACE: STRCPY(code, "NFA_CLASS_BACKSPACE"); break; ++ case NFA_CLASS_ESCAPE: STRCPY(code, "NFA_CLASS_ESCAPE"); break; ++ ++ case NFA_ANY: STRCPY(code, "NFA_ANY"); break; ++ case NFA_IDENT: STRCPY(code, "NFA_IDENT"); break; ++ case NFA_SIDENT:STRCPY(code, "NFA_SIDENT"); break; ++ case NFA_KWORD: STRCPY(code, "NFA_KWORD"); break; ++ case NFA_SKWORD:STRCPY(code, "NFA_SKWORD"); break; ++ case NFA_FNAME: STRCPY(code, "NFA_FNAME"); break; ++ case NFA_SFNAME:STRCPY(code, "NFA_SFNAME"); break; ++ case NFA_PRINT: STRCPY(code, "NFA_PRINT"); break; ++ case NFA_SPRINT:STRCPY(code, "NFA_SPRINT"); break; ++ case NFA_WHITE: STRCPY(code, "NFA_WHITE"); break; ++ case NFA_NWHITE:STRCPY(code, "NFA_NWHITE"); break; ++ case NFA_DIGIT: STRCPY(code, "NFA_DIGIT"); break; ++ case NFA_NDIGIT:STRCPY(code, "NFA_NDIGIT"); break; ++ case NFA_HEX: STRCPY(code, "NFA_HEX"); break; ++ case NFA_NHEX: STRCPY(code, "NFA_NHEX"); break; ++ case NFA_OCTAL: STRCPY(code, "NFA_OCTAL"); break; ++ case NFA_NOCTAL:STRCPY(code, "NFA_NOCTAL"); break; ++ case NFA_WORD: STRCPY(code, "NFA_WORD"); break; ++ case NFA_NWORD: STRCPY(code, "NFA_NWORD"); break; ++ case NFA_HEAD: STRCPY(code, "NFA_HEAD"); break; ++ case NFA_NHEAD: STRCPY(code, "NFA_NHEAD"); break; ++ case NFA_ALPHA: STRCPY(code, "NFA_ALPHA"); break; ++ case NFA_NALPHA:STRCPY(code, "NFA_NALPHA"); break; ++ case NFA_LOWER: STRCPY(code, "NFA_LOWER"); break; ++ case NFA_NLOWER:STRCPY(code, "NFA_NLOWER"); break; ++ case NFA_UPPER: STRCPY(code, "NFA_UPPER"); break; ++ case NFA_NUPPER:STRCPY(code, "NFA_NUPPER"); break; ++ ++ default: ++ STRCPY(code, "CHAR(x)"); ++ code[5] = c; ++ } ++ ++ if (addnl == TRUE) ++ STRCAT(code, " + NEWLINE "); ++ ++ } ++ ++ #ifdef ENABLE_LOG ++ static FILE *log_fd; ++ ++ /* ++ * Print the postfix notation of the current regexp. ++ */ ++ static void ++ nfa_postfix_dump(expr, retval) ++ char_u *expr; ++ int retval; ++ { ++ int *p; ++ FILE *f; ++ ++ f = fopen("LOG.log", "a"); ++ if (f != NULL) ++ { ++ fprintf(f, "\n-------------------------\n"); ++ if (retval == FAIL) ++ fprintf(f, ">>> NFA engine failed ... \n"); ++ else if (retval == OK) ++ fprintf(f, ">>> NFA engine succeeded !\n"); ++ fprintf(f, "Regexp: \"%s\"\nPostfix notation (char): \"", expr); ++ for (p=post_start; *p; p++) ++ { ++ nfa_set_code(*p); ++ fprintf(f, "%s, ", code); ++ } ++ fprintf(f, "\"\nPostfix notation (int): "); ++ for (p=post_start; *p; p++) ++ fprintf(f, "%d ", *p); ++ fprintf(f, "\n\n"); ++ fclose(f); ++ } ++ } ++ ++ /* ++ * Print the NFA starting with a root node "state". ++ */ ++ static void ++ nfa_print_state(debugf, state, ident) ++ FILE *debugf; ++ nfa_state_T *state; ++ int ident; ++ { ++ int i; ++ ++ if (state == NULL) ++ return; ++ ++ fprintf(debugf, "(%2d)", abs(state->id)); ++ for (i = 0; i < ident; i++) ++ fprintf(debugf, "%c", ' '); ++ ++ nfa_set_code(state->c); ++ fprintf(debugf, "%s %s (%d) (id=%d)\n", ++ state->negated ? "NOT" : "", code, state->c, abs(state->id)); ++ if (state->id < 0) ++ return; ++ ++ state->id = abs(state->id) * -1; ++ nfa_print_state(debugf, state->out, ident + 4); ++ nfa_print_state(debugf, state->out1, ident + 4); ++ } ++ ++ /* ++ * Print the NFA state machine. ++ */ ++ static void ++ nfa_dump(prog) ++ nfa_regprog_T *prog; ++ { ++ FILE *debugf = fopen("LOG.log", "a"); ++ ++ if (debugf != NULL) ++ { ++ nfa_print_state(debugf, prog->start, 0); ++ fclose(debugf); ++ } ++ } ++ #endif /* ENABLE_LOG */ ++ #endif /* DEBUG */ ++ ++ /* ++ * Parse r.e. @expr and convert it into postfix form. ++ * Return the postfix string on success, NULL otherwise. ++ */ ++ static int * ++ re2post() ++ { ++ if (nfa_reg(REG_NOPAREN) == FAIL) ++ return NULL; ++ EMIT(NFA_MOPEN); ++ return post_start; ++ } ++ ++ /* NB. Some of the code below is inspired by Russ's. */ ++ ++ /* ++ * Represents an NFA state plus zero or one or two arrows exiting. ++ * if c == MATCH, no arrows out; matching state. ++ * If c == SPLIT, unlabeled arrows to out and out1 (if != NULL). ++ * If c < 256, labeled arrow with character c to out. ++ */ ++ ++ static nfa_state_T *state_ptr; /* points to nfa_prog->state */ ++ ++ /* ++ * Allocate and initialize nfa_state_T. ++ */ ++ static nfa_state_T * ++ new_state(c, out, out1) ++ int c; ++ nfa_state_T *out; ++ nfa_state_T *out1; ++ { ++ nfa_state_T *s; ++ ++ if (istate >= nstate) ++ return NULL; ++ ++ s = &state_ptr[istate++]; ++ ++ s->c = c; ++ s->out = out; ++ s->out1 = out1; ++ ++ s->id = istate; ++ s->lastlist = 0; ++ s->lastthread = NULL; ++ s->visits = 0; ++ s->negated = FALSE; ++ ++ return s; ++ } ++ ++ /* ++ * A partially built NFA without the matching state filled in. ++ * Frag_T.start points at the start state. ++ * Frag_T.out is a list of places that need to be set to the ++ * next state for this fragment. ++ */ ++ typedef union Ptrlist Ptrlist; ++ struct Frag ++ { ++ nfa_state_T *start; ++ Ptrlist *out; ++ }; ++ typedef struct Frag Frag_T; ++ ++ static Frag_T frag __ARGS((nfa_state_T *start, Ptrlist *out)); ++ static Ptrlist *list1 __ARGS((nfa_state_T **outp)); ++ static void patch __ARGS((Ptrlist *l, nfa_state_T *s)); ++ static Ptrlist *append __ARGS((Ptrlist *l1, Ptrlist *l2)); ++ static void st_push __ARGS((Frag_T s, Frag_T **p, Frag_T *stack_end)); ++ static Frag_T st_pop __ARGS((Frag_T **p, Frag_T *stack)); ++ ++ /* ++ * Initialize Frag_T struct. ++ */ ++ static Frag_T ++ frag(start, out) ++ nfa_state_T *start; ++ Ptrlist *out; ++ { ++ Frag_T n = { start, out }; ++ return n; ++ } ++ ++ /* ++ * Since the out pointers in the list are always ++ * uninitialized, we use the pointers themselves ++ * as storage for the Ptrlists. ++ */ ++ union Ptrlist ++ { ++ Ptrlist *next; ++ nfa_state_T *s; ++ }; ++ ++ /* ++ * Create singleton list containing just outp. ++ */ ++ static Ptrlist * ++ list1(outp) ++ nfa_state_T **outp; ++ { ++ Ptrlist *l; ++ ++ l = (Ptrlist *)outp; ++ l->next = NULL; ++ return l; ++ } ++ ++ /* ++ * Patch the list of states at out to point to start. ++ */ ++ static void ++ patch(l, s) ++ Ptrlist *l; ++ nfa_state_T *s; ++ { ++ Ptrlist *next; ++ ++ for (; l; l = next) ++ { ++ next = l->next; ++ l->s = s; ++ } ++ } ++ ++ ++ /* ++ * Join the two lists l1 and l2, returning the combination. ++ */ ++ static Ptrlist * ++ append(l1, l2) ++ Ptrlist *l1; ++ Ptrlist *l2; ++ { ++ Ptrlist *oldl1; ++ ++ oldl1 = l1; ++ while (l1->next) ++ l1 = l1->next; ++ l1->next = l2; ++ return oldl1; ++ } ++ ++ /* ++ * Stack used for transforming postfix form into NFA. ++ */ ++ static Frag_T empty; ++ ++ static void ++ st_error(postfix, end, p) ++ int *postfix; ++ int *end; ++ int *p; ++ { ++ FILE *df; ++ int *p2; ++ ++ df = fopen("stack.err", "a"); ++ if (df) ++ { ++ fprintf(df, "Error popping the stack!\n"); ++ #ifdef DEBUG ++ fprintf(df, "Current regexp is \"%s\"\n", nfa_regengine.expr); ++ #endif ++ fprintf(df, "Postfix form is: "); ++ #ifdef DEBUG ++ for (p2 = postfix; p2 < end; p2++) ++ { ++ nfa_set_code(*p2); ++ fprintf(df, "%s, ", code); ++ } ++ nfa_set_code(*p); ++ fprintf(df, "\nCurrent position is: "); ++ for (p2 = postfix; p2 <= p; p2 ++) ++ { ++ nfa_set_code(*p2); ++ fprintf(df, "%s, ", code); ++ } ++ #else ++ for (p2 = postfix; p2 < end; p2++) ++ { ++ fprintf(df, "%d, ", *p2); ++ } ++ fprintf(df, "\nCurrent position is: "); ++ for (p2 = postfix; p2 <= p; p2 ++) ++ { ++ fprintf(df, "%d, ", *p2); ++ } ++ #endif ++ fprintf(df, "\n--------------------------\n"); ++ fclose(df); ++ } ++ EMSG(_("E874: (NFA) Could not pop the stack !")); ++ } ++ ++ /* ++ * Push an item onto the stack. ++ */ ++ static void ++ st_push(s, p, stack_end) ++ Frag_T s; ++ Frag_T **p; ++ Frag_T *stack_end; ++ { ++ Frag_T *stackp = *p; ++ ++ if (stackp >= stack_end) ++ return; ++ *stackp = s; ++ *p = *p + 1; ++ } ++ ++ /* ++ * Pop an item from the stack. ++ */ ++ static Frag_T ++ st_pop(p, stack) ++ Frag_T **p; ++ Frag_T *stack; ++ { ++ Frag_T *stackp; ++ ++ *p = *p - 1; ++ stackp = *p; ++ if (stackp < stack) ++ return empty; ++ return **p; ++ } ++ ++ /* ++ * Convert a postfix form into its equivalent NFA. ++ * Return the NFA start state on success, NULL otherwise. ++ */ ++ static nfa_state_T * ++ post2nfa(postfix, end, nfa_calc_size) ++ int *postfix; ++ int *end; ++ int nfa_calc_size; ++ { ++ int *p; ++ int mopen; ++ int mclose; ++ Frag_T *stack = NULL; ++ Frag_T *stackp = NULL; ++ Frag_T *stack_end = NULL; ++ Frag_T e1; ++ Frag_T e2; ++ Frag_T e; ++ nfa_state_T *s; ++ nfa_state_T *s1; ++ nfa_state_T *matchstate; ++ ++ if (postfix == NULL) ++ return NULL; ++ ++ #define PUSH(s) st_push ((s), &stackp, stack_end) ++ #define POP() st_pop(&stackp, stack); \ ++ if (stackp < stack) \ ++ { \ ++ st_error(postfix, end, p); \ ++ return NULL; \ ++ } ++ ++ if (nfa_calc_size == FALSE) ++ { ++ /* Allocate space for the stack. Max states on the stack : nstate */ ++ stack = (Frag_T *) lalloc((nstate + 1)*sizeof(Frag_T), TRUE); ++ stackp = stack; ++ stack_end = stack + NFA_STACK_SIZE; ++ } ++ ++ for (p = postfix; p < end; ++p) ++ { ++ switch (*p) ++ { ++ case NFA_CONCAT: ++ /* Catenation. ++ * Pay attention: this operator does not exist ++ * in the r.e. itself (it is implicit, really). ++ * It is added when r.e. is translated to postfix ++ * form in re2post(). ++ * ++ * No new state added here. */ ++ if (nfa_calc_size == TRUE) ++ { ++ nstate += 0; ++ break; ++ } ++ e2 = POP(); ++ e1 = POP(); ++ patch(e1.out, e2.start); ++ PUSH(frag(e1.start, e2.out)); ++ break; ++ ++ case NFA_NOT: ++ /* Negation of a character */ ++ if (nfa_calc_size == TRUE) ++ { ++ nstate += 0; ++ break; ++ } ++ e1 = POP(); ++ e1.start->negated = TRUE; ++ if (e1.start->c == NFA_MULTIBYTE || e1.start->c == NFA_COMPOSING) ++ e1.start->out1->negated = TRUE; ++ PUSH(e1); ++ break; ++ ++ case NFA_OR: ++ /* Alternation */ ++ if (nfa_calc_size == TRUE) ++ { ++ nstate ++; ++ break; ++ } ++ e2 = POP(); ++ e1 = POP(); ++ s = new_state(NFA_SPLIT, e1.start, e2.start); ++ if (s == NULL) ++ return NULL; ++ PUSH(frag(s, append(e1.out, e2.out))); ++ break; ++ ++ case NFA_STAR: ++ /* Zero or more */ ++ if (nfa_calc_size == TRUE) ++ { ++ nstate ++; ++ break; ++ } ++ e = POP(); ++ s = new_state(NFA_SPLIT, e.start, NULL); ++ if (s == NULL) ++ return NULL; ++ patch(e.out, s); ++ PUSH(frag(s, list1(&s->out1))); ++ break; ++ ++ case NFA_QUEST: ++ /* one or zero atoms=> greedy match */ ++ if (nfa_calc_size == TRUE) ++ { ++ nstate ++; ++ break; ++ } ++ e = POP(); ++ s = new_state(NFA_SPLIT, e.start, NULL); ++ if (s == NULL) ++ return NULL; ++ PUSH(frag(s, append(e.out, list1(&s->out1)))); ++ break; ++ ++ case NFA_QUEST_NONGREEDY: ++ /* zero or one atoms => non-greedy match */ ++ if (nfa_calc_size == TRUE) ++ { ++ nstate ++; ++ break; ++ } ++ e = POP(); ++ s = new_state(NFA_SPLIT, NULL, e.start); ++ if (s == NULL) ++ return NULL; ++ PUSH(frag(s, append(e.out, list1(&s->out)))); ++ break; ++ ++ case NFA_PLUS: ++ /* One or more */ ++ if (nfa_calc_size == TRUE) ++ { ++ nstate ++; ++ break; ++ } ++ e = POP(); ++ s = new_state(NFA_SPLIT, e.start, NULL); ++ if (s == NULL) ++ return NULL; ++ patch(e.out, s); ++ PUSH(frag(e.start, list1(&s->out1))); ++ break; ++ ++ case NFA_SKIP_CHAR: ++ /* Symbol of 0-length, Used in a repetition ++ * with max/min count of 0 */ ++ if (nfa_calc_size == TRUE) ++ { ++ nstate ++; ++ break; ++ } ++ s = new_state(NFA_SKIP_CHAR, NULL, NULL); ++ if (s == NULL) ++ return NULL; ++ PUSH(frag(s, list1(&s->out))); ++ break; ++ ++ case NFA_PREV_ATOM_NO_WIDTH: ++ /* The \@= operator: match the preceding atom with 0 width. ++ * Surrounds the preceding atom with START_INVISIBLE and ++ * END_INVISIBLE, similarly to MOPEN. ++ */ ++ /* TODO: Maybe this drops the speed? */ ++ return NULL; ++ ++ if (nfa_calc_size == TRUE) ++ { ++ nstate += 2; ++ break; ++ } ++ e = POP(); ++ s1 = new_state(NFA_END_INVISIBLE, NULL, NULL); ++ if (s1 == NULL) ++ return NULL; ++ patch(e.out, s1); ++ ++ s = new_state(NFA_START_INVISIBLE, e.start, s1); ++ if (s == NULL) ++ return NULL; ++ PUSH(frag(s, list1(&s1->out))); ++ break; ++ ++ case NFA_MOPEN + 0: /* Submatch */ ++ case NFA_MOPEN + 1: ++ case NFA_MOPEN + 2: ++ case NFA_MOPEN + 3: ++ case NFA_MOPEN + 4: ++ case NFA_MOPEN + 5: ++ case NFA_MOPEN + 6: ++ case NFA_MOPEN + 7: ++ case NFA_MOPEN + 8: ++ case NFA_MOPEN + 9: ++ case NFA_NOPEN: /* \%( "Invisible Submatch" */ ++ case NFA_MULTIBYTE: /* mbyte char */ ++ case NFA_COMPOSING: /* composing char */ ++ if (nfa_calc_size == TRUE) ++ { ++ nstate += 2; ++ break; ++ } ++ ++ mopen = *p; ++ switch (*p) ++ { ++ case NFA_NOPEN: ++ mclose = NFA_NCLOSE; ++ break; ++ case NFA_MULTIBYTE: ++ mclose = NFA_END_MULTIBYTE; ++ break; ++ case NFA_COMPOSING: ++ mclose = NFA_END_COMPOSING; ++ break; ++ default: ++ /* NFA_MOPEN(0) ... NFA_MOPEN(9) */ ++ mclose = *p + NSUBEXP; ++ break; ++ } ++ ++ /* Allow "NFA_MOPEN" as a valid postfix representation for ++ * the empty regexp "". In this case, the NFA will be ++ * NFA_MOPEN -> NFA_MCLOSE. Note that this also allows ++ * empty groups of parenthesis, and empty mbyte chars */ ++ if (stackp == stack) ++ { ++ s = new_state(mopen, NULL, NULL); ++ if (s == NULL) ++ return NULL; ++ s1 = new_state(mclose, NULL, NULL); ++ if (s1 == NULL) ++ return NULL; ++ patch(list1(&s->out), s1); ++ PUSH(frag(s, list1(&s1->out))); ++ break; ++ } ++ ++ /* At least one node was emitted before NFA_MOPEN, so ++ * at least one node will be between NFA_MOPEN and NFA_MCLOSE */ ++ e = POP(); ++ s = new_state(mopen, e.start, NULL); /* `(' */ ++ if (s == NULL) ++ return NULL; ++ ++ s1 = new_state(mclose, NULL, NULL); /* `)' */ ++ if (s1 == NULL) ++ return NULL; ++ patch(e.out, s1); ++ ++ if (mopen == NFA_MULTIBYTE || mopen == NFA_COMPOSING) ++ /* MULTIBYTE->out1 = END_MULTIBYTE ++ * COMPOSING->out1 = END_COMPOSING */ ++ patch(list1(&s->out1), s1); ++ ++ PUSH(frag(s, list1(&s1->out))); ++ break; ++ ++ case NFA_ZSTART: ++ case NFA_ZEND: ++ default: ++ /* Operands */ ++ if (nfa_calc_size == TRUE) ++ { ++ nstate ++; ++ break; ++ } ++ s = new_state(*p, NULL, NULL); ++ if (s == NULL) ++ return NULL; ++ PUSH(frag(s, list1(&s->out))); ++ break; ++ ++ } /* switch(*p) */ ++ ++ } /* for(p = postfix; *p; ++p) */ ++ ++ if (nfa_calc_size == TRUE) ++ { ++ nstate ++; ++ return NULL; /* Return value when counting size is ignored anyway */ ++ } ++ ++ e = POP(); ++ if (stackp != stack) ++ EMSG_RET_NULL(_("E875: (NFA regexp) (While converting from postfix to NFA), too many states left on stack")); ++ ++ if (istate >= nstate) ++ EMSG_RET_NULL(_("E876: (NFA regexp) Not enough space to store the whole NFA ")); ++ ++ vim_free(stack); ++ ++ matchstate = &state_ptr[istate++]; /* the match state */ ++ matchstate->c = NFA_MATCH; ++ matchstate->out = matchstate->out1 = NULL; ++ ++ patch(e.out, matchstate); ++ return e.start; ++ ++ #undef POP1 ++ #undef PUSH1 ++ #undef POP2 ++ #undef PUSH2 ++ #undef POP ++ #undef PUSH ++ } ++ ++ /**************************************************************** ++ * NFA execution code. ++ ****************************************************************/ ++ ++ /* thread_T contains runtime information of a NFA state */ ++ struct thread ++ { ++ nfa_state_T *state; ++ regsub_T sub; /* submatch info */ ++ }; ++ ++ typedef struct ++ { ++ thread_T *t; ++ int n; ++ } List; ++ ++ static void addstate __ARGS((List *l, nfa_state_T *state, regsub_T *m, int off, int lid, int *match)); ++ ++ static void ++ addstate(l, state, m, off, lid, match) ++ List *l; /* runtime state list */ ++ nfa_state_T *state; /* state to update */ ++ regsub_T *m; /* pointers to subexpressions */ ++ int off; ++ int lid; ++ int *match; /* found match? */ ++ { ++ regsub_T save; ++ int subidx = 0; ++ ++ if (l == NULL || state == NULL) ++ return; ++ ++ switch (state->c) ++ { ++ case NFA_SPLIT: ++ case NFA_NOT: ++ case NFA_NOPEN: ++ case NFA_NCLOSE: ++ case NFA_MCLOSE: ++ case NFA_MCLOSE + 1: ++ case NFA_MCLOSE + 2: ++ case NFA_MCLOSE + 3: ++ case NFA_MCLOSE + 4: ++ case NFA_MCLOSE + 5: ++ case NFA_MCLOSE + 6: ++ case NFA_MCLOSE + 7: ++ case NFA_MCLOSE + 8: ++ case NFA_MCLOSE + 9: ++ /* Do not remember these nodes in list "thislist" or "nextlist" */ ++ break; ++ ++ default: ++ if (state->lastlist == lid) ++ { ++ if (++state->visits > 2) ++ return; ++ } ++ else ++ { ++ /* add the state to the list */ ++ state->lastlist = lid; ++ state->lastthread = &l->t[l->n++]; ++ state->lastthread->state = state; ++ state->lastthread->sub = *m; ++ } ++ } ++ ++ #ifdef ENABLE_LOG ++ nfa_set_code(state->c); ++ fprintf(log_fd, "> Adding state %d to list. Character %s, code %d\n", ++ abs(state->id), code, state->c); ++ #endif ++ switch (state->c) ++ { ++ case NFA_MATCH: ++ *match = TRUE; ++ break; ++ ++ case NFA_SPLIT: ++ addstate(l, state->out, m, off, lid, match); ++ addstate(l, state->out1, m, off, lid, match); ++ break; ++ ++ case NFA_SKIP_CHAR: ++ addstate(l, state->out, m, off, lid, match); ++ break; ++ ++ #if 0 ++ case NFA_END_NEG_RANGE: ++ /* Nothing to handle here. nfa_regmatch() will take care of it */ ++ break; ++ ++ case NFA_NOT: ++ EMSG(_("E999: (NFA regexp internal error) Should not process NOT node !")); ++ #ifdef ENABLE_LOG ++ fprintf(f, "\n\n>>> E999: Added state NFA_NOT to a list ... Something went wrong ! Why wasn't it processed already? \n\n"); ++ #endif ++ break; ++ ++ case NFA_COMPOSING: ++ /* nfa_regmatch() will match all the bytes of this composing char. */ ++ break; ++ ++ case NFA_MULTIBYTE: ++ /* nfa_regmatch() will match all the bytes of this multibyte char. */ ++ break; ++ #endif ++ ++ case NFA_END_MULTIBYTE: ++ /* Successfully matched this mbyte char */ ++ addstate(l, state->out, m, off, lid, match); ++ break; ++ ++ case NFA_NOPEN: ++ case NFA_NCLOSE: ++ addstate(l, state->out, m, off, lid, match); ++ break; ++ ++ /* If this state is reached, then a recursive call of nfa_regmatch() ++ * succeeded. the next call saves the found submatches in the ++ * first state after the "invisible" branch. */ ++ #if 0 ++ case NFA_END_INVISIBLE: ++ break; ++ #endif ++ ++ case NFA_MOPEN + 0: ++ case NFA_MOPEN + 1: ++ case NFA_MOPEN + 2: ++ case NFA_MOPEN + 3: ++ case NFA_MOPEN + 4: ++ case NFA_MOPEN + 5: ++ case NFA_MOPEN + 6: ++ case NFA_MOPEN + 7: ++ case NFA_MOPEN + 8: ++ case NFA_MOPEN + 9: ++ case NFA_ZSTART: ++ subidx = state->c - NFA_MOPEN; ++ if (state->c == NFA_ZSTART) ++ subidx = 0; ++ ++ if (REG_MULTI) ++ { ++ save.startpos[subidx] = m->startpos[subidx]; ++ save.endpos[subidx] = m->endpos[subidx]; ++ m->startpos[subidx].lnum = reglnum; ++ m->startpos[subidx].col = reginput - regline + off; ++ } ++ else ++ { ++ save.start[subidx] = m->start[subidx]; ++ save.end[subidx] = m->end[subidx]; ++ m->start[subidx] = reginput + off; ++ } ++ ++ addstate(l, state->out, m, off, lid, match); ++ ++ if (REG_MULTI) ++ { ++ m->startpos[subidx] = save.startpos[subidx]; ++ m->endpos[subidx] = save.endpos[subidx]; ++ } ++ else ++ { ++ m->start[subidx] = save.start[subidx]; ++ m->end[subidx] = save.end[subidx]; ++ } ++ break; ++ ++ case NFA_MCLOSE + 0: ++ if (nfa_has_zend == TRUE) ++ { ++ addstate(l, state->out, m, off, lid, match); ++ break; ++ } ++ case NFA_MCLOSE + 1: ++ case NFA_MCLOSE + 2: ++ case NFA_MCLOSE + 3: ++ case NFA_MCLOSE + 4: ++ case NFA_MCLOSE + 5: ++ case NFA_MCLOSE + 6: ++ case NFA_MCLOSE + 7: ++ case NFA_MCLOSE + 8: ++ case NFA_MCLOSE + 9: ++ case NFA_ZEND: ++ subidx = state->c - NFA_MCLOSE; ++ if (state->c == NFA_ZEND) ++ subidx = 0; ++ ++ if (REG_MULTI) ++ { ++ save.startpos[subidx] = m->startpos[subidx]; ++ save.endpos[subidx] = m->endpos[subidx]; ++ m->endpos[subidx].lnum = reglnum; ++ m->endpos[subidx].col = reginput - regline + off; ++ } ++ else ++ { ++ save.start[subidx] = m->start[subidx]; ++ save.end[subidx] = m->end[subidx]; ++ m->end[subidx] = reginput + off; ++ } ++ ++ addstate(l, state->out, m, off, lid, match); ++ ++ if (REG_MULTI) ++ { ++ m->startpos[subidx] = save.startpos[subidx]; ++ m->endpos[subidx] = save.endpos[subidx]; ++ } ++ else ++ { ++ m->start[subidx] = save.start[subidx]; ++ m->end[subidx] = save.end[subidx]; ++ } ++ break; ++ } ++ } ++ ++ /* ++ * Check character class "class" against current character c. ++ */ ++ static int ++ check_char_class(class, c) ++ int class; ++ int c; ++ { ++ switch (class) ++ { ++ case NFA_CLASS_ALNUM: ++ if (isalnum(c)) ++ return OK; ++ break; ++ case NFA_CLASS_ALPHA: ++ if (isalpha(c)) ++ return OK; ++ break; ++ case NFA_CLASS_BLANK: ++ if (c == ' ' || c == '\t') ++ return OK; ++ break; ++ case NFA_CLASS_CNTRL: ++ if (iscntrl(c)) ++ return OK; ++ break; ++ case NFA_CLASS_DIGIT: ++ if (VIM_ISDIGIT(c)) ++ return OK; ++ break; ++ case NFA_CLASS_GRAPH: ++ if (isgraph(c)) ++ return OK; ++ break; ++ case NFA_CLASS_LOWER: ++ if (MB_ISLOWER(c)) ++ return OK; ++ break; ++ case NFA_CLASS_PRINT: ++ if (vim_isprintc(c)) ++ return OK; ++ break; ++ case NFA_CLASS_PUNCT: ++ if (ispunct(c)) ++ return OK; ++ break; ++ case NFA_CLASS_SPACE: ++ if ((c >=9 && c <= 13) || (c == ' ')) ++ return OK; ++ break; ++ case NFA_CLASS_UPPER: ++ if (MB_ISUPPER(c)) ++ return OK; ++ break; ++ case NFA_CLASS_XDIGIT: ++ if (vim_isxdigit(c)) ++ return OK; ++ break; ++ case NFA_CLASS_TAB: ++ if (c == '\t') ++ return OK; ++ break; ++ case NFA_CLASS_RETURN: ++ if (c == '\r') ++ return OK; ++ break; ++ case NFA_CLASS_BACKSPACE: ++ if (c == '\b') ++ return OK; ++ break; ++ case NFA_CLASS_ESCAPE: ++ if (c == '\033') ++ return OK; ++ break; ++ ++ default: ++ /* should not be here :P */ ++ EMSG_RET_FAIL(_("E877: (NFA regexp) Invalid character class ")); ++ } ++ return FAIL; ++ } ++ ++ /* ++ * Set all NFA nodes' list ID equal to -1. ++ */ ++ static void ++ nfa_set_neg_listids(start) ++ nfa_state_T *start; ++ { ++ if (start == NULL) ++ return; ++ if (start->lastlist >= 0) ++ { ++ start->lastlist = -1; ++ nfa_set_neg_listids(start->out); ++ nfa_set_neg_listids(start->out1); ++ } ++ } ++ ++ /* ++ * Set all NFA nodes' list ID equal to 0. ++ */ ++ static void ++ nfa_set_null_listids(start) ++ nfa_state_T *start; ++ { ++ if (start == NULL) ++ return; ++ if (start->lastlist == -1) ++ { ++ start->lastlist = 0; ++ nfa_set_null_listids(start->out); ++ nfa_set_null_listids(start->out1); ++ } ++ } ++ ++ /* ++ * Save list IDs for all NFA states in "list". ++ */ ++ static void ++ nfa_save_listids(start, list) ++ nfa_state_T *start; ++ int *list; ++ { ++ if (start == NULL) ++ return; ++ if (start->lastlist != -1) ++ { ++ list[abs(start->id)] = start->lastlist; ++ start->lastlist = -1; ++ nfa_save_listids(start->out, list); ++ nfa_save_listids(start->out1, list); ++ } ++ } ++ ++ /* ++ * Restore list IDs from "list" to all NFA states. ++ */ ++ static void ++ nfa_restore_listids(start, list) ++ nfa_state_T *start; ++ int *list; ++ { ++ if (start == NULL) ++ return; ++ if (start->lastlist == -1) ++ { ++ start->lastlist = list[abs(start->id)]; ++ nfa_restore_listids(start->out, list); ++ nfa_restore_listids(start->out1, list); ++ } ++ } ++ ++ /* ++ * Main matching routine. ++ * ++ * Run NFA to determine whether it matches reginput. ++ * ++ * Return TRUE if there is a match, FALSE otherwise. ++ * Note: Caller must ensure that: start != NULL. ++ */ ++ static int ++ nfa_regmatch(start, submatch, m) ++ nfa_state_T *start; ++ regsub_T *submatch; ++ regsub_T *m; ++ { ++ int c = -1; ++ int n; ++ int i = 0; ++ int result; ++ int size = 0; ++ int match = FALSE; ++ int flag = 0; ++ int old_reglnum = -1; ++ int reginput_updated = FALSE; ++ thread_T *t; ++ char_u *cc; ++ char_u *old_reginput = NULL; ++ char_u *old_regline = NULL; ++ nfa_state_T *sta; ++ nfa_state_T *end; ++ List list[3]; ++ List *listtbl[2][2]; ++ List *ll; ++ int listid = 1; ++ int endnode = 0; ++ List *thislist; ++ List *nextlist; ++ List *neglist; ++ int *listids = NULL; ++ int j = 0; ++ int len = 0; ++ #ifdef DEBUG ++ FILE *debug = fopen("list.log", "a"); ++ ++ if (debug == NULL) ++ { ++ EMSG(_("(NFA) COULD NOT OPEN list.log !")); ++ return FALSE; ++ } ++ #endif ++ ++ /* Allocate memory for the lists of nodes */ ++ size = (nstate + 1) * sizeof(thread_T); ++ list[0].t = (thread_T *)lalloc(size, TRUE); ++ list[1].t = (thread_T *)lalloc(size, TRUE); ++ list[2].t = (thread_T *)lalloc(size, TRUE); ++ if (list[0].t == NULL || list[1].t == NULL || list[2].t == NULL) ++ goto theend; ++ vim_memset(list[0].t, 0, size); ++ vim_memset(list[1].t, 0, size); ++ vim_memset(list[2].t, 0, size); ++ ++ #ifdef ENABLE_LOG ++ log_fd = fopen(LOG_NAME, "a"); ++ if (log_fd != NULL) ++ { ++ fprintf(log_fd, "**********************************\n"); ++ nfa_set_code(start->c); ++ fprintf(log_fd, " RUNNING nfa_regmatch() starting with state %d, code %s\n", ++ abs(start->id), code); ++ fprintf(log_fd, "**********************************\n"); ++ } ++ else ++ { ++ EMSG(_("Could not open temporary log file for writing, displaying on stderr ... ")); ++ log_fd = stderr; ++ } ++ #endif ++ ++ thislist = &list[0]; ++ thislist->n = 0; ++ nextlist = &list[1]; ++ nextlist->n = 0; ++ neglist = &list[2]; ++ neglist->n = 0; ++ #ifdef ENABLE_LOG ++ fprintf(log_fd, "(---) STARTSTATE\n"); ++ #endif ++ addstate(thislist, start, m, 0, listid, &match); ++ ++ /* There are two cases when the NFA advances: 1. input char matches the ++ * NFA node and 2. input char does not match the NFA node, but the next ++ * node is NFA_NOT. The following macro calls addstate() according to ++ * these rules. It is used A LOT, so use the "listtbl" table for speed */ ++ listtbl[0][0] = NULL; ++ listtbl[0][1] = neglist; ++ listtbl[1][0] = nextlist; ++ listtbl[1][1] = NULL; ++ #define ADD_POS_NEG_STATE(node) \ ++ ll = listtbl[result ? 1 : 0][node->negated]; \ ++ if (ll != NULL) \ ++ addstate(ll, node->out , &t->sub, n, listid + 1, &match); ++ ++ ++ /* ++ * Run for each character. ++ */ ++ do { ++ again: ++ #ifdef FEAT_MBYTE ++ if (has_mbyte) ++ { ++ c = (*mb_ptr2char)(reginput); ++ n = (*mb_ptr2len)(reginput); ++ } ++ else ++ #endif ++ { ++ c = *reginput; ++ n = 1; ++ } ++ if (c == NUL) ++ n = 0; ++ cc = (char_u *)&c; ++ ++ /* swap lists */ ++ thislist = &list[flag]; ++ nextlist = &list[flag ^= 1]; ++ nextlist->n = 0; /* `clear' nextlist */ ++ listtbl[1][0] = nextlist; ++ ++listid; ++ ++ #ifdef ENABLE_LOG ++ fprintf(log_fd, "------------------------------------------\n"); ++ fprintf(log_fd, ">>> Reginput is \"%s\"\n", reginput); ++ fprintf(log_fd, ">>> Advanced one character ... Current char is %c (code %d) \n", c, (int)c); ++ fprintf(log_fd, ">>> Thislist has %d states available: ", thislist->n); ++ for (i = 0; i< thislist->n; i++) ++ fprintf(log_fd, "%d ", abs(thislist->t[i].state->id)); ++ fprintf(log_fd, "\n"); ++ #endif ++ ++ #ifdef DEBUG ++ fprintf(debug, "\n-------------------\n"); ++ #endif ++ ++ /* compute nextlist */ ++ for (i = 0; i < thislist->n || neglist->n > 0; ++i) ++ { ++ if (neglist->n > 0) ++ { ++ t = &neglist->t[0]; ++ neglist->n --; ++ i--; ++ } ++ else ++ t = &thislist->t[i]; ++ ++ #ifdef DEBUG ++ nfa_set_code(t->state->c); ++ fprintf(debug, "%s, ", code); ++ #endif ++ #ifdef ENABLE_LOG ++ nfa_set_code(t->state->c); ++ fprintf(log_fd, "(%d) %s, code %d ... \n", abs(t->state->id), ++ code, (int)t->state->c); ++ #endif ++ ++ /* ++ * Handle the possible codes of the current state. ++ * The most important is NFA_MATCH. ++ */ ++ switch (t->state->c) ++ { ++ case NFA_MATCH: ++ match = TRUE; ++ *submatch = t->sub; ++ #ifdef ENABLE_LOG ++ for (j = 0; j < 4; j++) ++ if (REG_MULTI) ++ fprintf(log_fd, "\n *** group %d, start: c=%d, l=%d, end: c=%d, l=%d", ++ j, ++ t->sub.startpos[j].col, ++ (int)t->sub.startpos[j].lnum, ++ t->sub.endpos[j].col, ++ (int)t->sub.endpos[j].lnum); ++ else ++ fprintf(log_fd, "\n *** group %d, start: \"%s\", end: \"%s\"", ++ j, ++ (char *)t->sub.start[j], ++ (char *)t->sub.end[j]); ++ fprintf(log_fd, "\n"); ++ #endif ++ goto nextchar; /* found the left-most longest match */ ++ ++ case NFA_END_INVISIBLE: ++ /* This is only encountered after a NFA_START_INVISIBLE node. ++ * They surround a zero-width group, used with "\@=" and "\&". ++ * If we got here, it means that the current "invisible" group ++ * finished successfully, so return control to the parent ++ * nfa_regmatch(). Submatches are stored in *m, and used in ++ * the parent call. */ ++ if (start->c == NFA_MOPEN + 0) ++ addstate(thislist, t->state->out, &t->sub, 0, listid, ++ &match); ++ else ++ { ++ *m = t->sub; ++ match = TRUE; ++ } ++ break; ++ ++ case NFA_START_INVISIBLE: ++ /* Save global variables, and call nfa_regmatch() to check if ++ * the current concat matches at this position. The concat ++ * ends with the node NFA_END_INVISIBLE */ ++ old_reginput = reginput; ++ old_regline = regline; ++ old_reglnum = reglnum; ++ if (listids == NULL) ++ { ++ listids = (int *) lalloc(sizeof(int) * nstate, TRUE); ++ if (listids == NULL) ++ { ++ EMSG(_("E878: (NFA) Could not allocate memory for branch traversal!")); ++ return 0; ++ } ++ } ++ #ifdef ENABLE_LOG ++ if (log_fd != stderr) ++ fclose(log_fd); ++ log_fd = NULL; ++ #endif ++ /* Have to clear the listid field of the NFA nodes, so that ++ * nfa_regmatch() and addstate() can run properly after ++ * recursion. */ ++ nfa_save_listids(start, listids); ++ nfa_set_null_listids(start); ++ result = nfa_regmatch(t->state->out, submatch, m); ++ nfa_set_neg_listids(start); ++ nfa_restore_listids(start, listids); ++ ++ #ifdef ENABLE_LOG ++ log_fd = fopen(LOG_NAME, "a"); ++ if (log_fd != NULL) ++ { ++ fprintf(log_fd, "****************************\n"); ++ fprintf(log_fd, "FINISHED RUNNING nfa_regmatch() recursively\n"); ++ fprintf(log_fd, "MATCH = %s\n", result == TRUE ? "OK" : "FALSE"); ++ fprintf(log_fd, "****************************\n"); ++ } ++ else ++ { ++ EMSG(_("Could not open temporary log file for writing, displaying on stderr ... ")); ++ log_fd = stderr; ++ } ++ #endif ++ if (result == TRUE) ++ { ++ /* Restore position in input text */ ++ reginput = old_reginput; ++ regline = old_regline; ++ reglnum = old_reglnum; ++ /* Copy submatch info from the recursive call */ ++ if (REG_MULTI) ++ for (j = 1; j < NSUBEXP; j++) ++ { ++ t->sub.startpos[j] = m->startpos[j]; ++ t->sub.endpos[j] = m->endpos[j]; ++ } ++ else ++ for (j = 1; j < NSUBEXP; j++) ++ { ++ t->sub.start[j] = m->start[j]; ++ t->sub.end[j] = m->end[j]; ++ } ++ /* t->state->out1 is the corresponding END_INVISIBLE node */ ++ addstate(thislist, t->state->out1->out, &t->sub, 0, listid, ++ &match); ++ } ++ else ++ { ++ /* continue with next input char */ ++ reginput = old_reginput; ++ } ++ break; ++ ++ case NFA_BOL: ++ if (reginput == regline) ++ addstate(thislist, t->state->out, &t->sub, 0, listid, ++ &match); ++ break; ++ ++ case NFA_EOL: ++ if (c == NUL) ++ addstate(thislist, t->state->out, &t->sub, 0, listid, ++ &match); ++ break; ++ ++ case NFA_BOW: ++ { ++ int bow = TRUE; ++ ++ if (c == NUL) ++ bow = FALSE; ++ #ifdef FEAT_MBYTE ++ else if (has_mbyte) ++ { ++ int this_class; ++ ++ /* Get class of current and previous char (if it exists). */ ++ this_class = mb_get_class(reginput); ++ if (this_class <= 1) ++ bow = FALSE; ++ else if (reg_prev_class() == this_class) ++ bow = FALSE; ++ } ++ #endif ++ else if (!vim_iswordc(c) ++ || (reginput > regline && vim_iswordc(reginput[-1]))) ++ bow = FALSE; ++ if (bow) ++ addstate(thislist, t->state->out, &t->sub, 0, listid, ++ &match); ++ break; ++ } ++ ++ case NFA_EOW: ++ { ++ int eow = TRUE; ++ ++ if (reginput == regline) ++ eow = FALSE; ++ #ifdef FEAT_MBYTE ++ else if (has_mbyte) ++ { ++ int this_class, prev_class; ++ ++ /* Get class of current and previous char (if it exists). */ ++ this_class = mb_get_class(reginput); ++ prev_class = reg_prev_class(); ++ if (this_class == prev_class ++ || prev_class == 0 || prev_class == 1) ++ eow = FALSE; ++ } ++ #endif ++ else if (!vim_iswordc(reginput[-1]) ++ || (reginput[0] != NUL && vim_iswordc(c))) ++ eow = FALSE; ++ if (eow) ++ addstate(thislist, t->state->out, &t->sub, 0, listid, ++ &match); ++ break; ++ } ++ ++ case NFA_MULTIBYTE: ++ case NFA_COMPOSING: ++ switch (t->state->c) ++ { ++ case NFA_MULTIBYTE: endnode = NFA_END_MULTIBYTE; break; ++ case NFA_COMPOSING: endnode = NFA_END_COMPOSING; break; ++ default: endnode = 0; ++ } ++ ++ result = OK; ++ sta = t->state->out; ++ len = 1; ++ while (sta->c != endnode && len <= n) ++ { ++ if (reginput[len-1] != sta->c) ++ { ++ result = OK - 1; ++ break; ++ } ++ len++; ++ sta = sta->out; ++ } ++ ++ /* if input char length doesn't match regexp char length */ ++ if (len -1 < n || sta->c != endnode) ++ result = OK - 1; ++ end = t->state->out1; /* NFA_END_MULTIBYTE or ++ NFA_END_COMPOSING */ ++ /* If \Z was present, then ignore composing characters */ ++ if (regflags & RF_ICOMBINE) ++ result = 1 ^ sta->negated; ++ ADD_POS_NEG_STATE(end); ++ break; ++ ++ case NFA_NEWL: ++ if (!reg_line_lbr && REG_MULTI ++ && c == NUL && reglnum <= reg_maxline) ++ { ++ if (reginput_updated == FALSE) ++ { ++ reg_nextline(); ++ reginput_updated = TRUE; ++ } ++ addstate(nextlist, t->state->out, &t->sub, n, listid + 1, ++ &match); ++ } ++ break; ++ ++ case NFA_CLASS_ALNUM: ++ case NFA_CLASS_ALPHA: ++ case NFA_CLASS_BLANK: ++ case NFA_CLASS_CNTRL: ++ case NFA_CLASS_DIGIT: ++ case NFA_CLASS_GRAPH: ++ case NFA_CLASS_LOWER: ++ case NFA_CLASS_PRINT: ++ case NFA_CLASS_PUNCT: ++ case NFA_CLASS_SPACE: ++ case NFA_CLASS_UPPER: ++ case NFA_CLASS_XDIGIT: ++ case NFA_CLASS_TAB: ++ case NFA_CLASS_RETURN: ++ case NFA_CLASS_BACKSPACE: ++ case NFA_CLASS_ESCAPE: ++ result = check_char_class(t->state->c, c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_END_NEG_RANGE: ++ /* This follows a series of negated nodes, like: ++ * CHAR(x), NFA_NOT, CHAR(y), NFA_NOT etc. */ ++ if (c > 0) ++ addstate(nextlist, t->state->out, &t->sub, n, listid + 1, ++ &match); ++ break; ++ ++ case NFA_ANY: ++ /* Any printable char, not just any char. '\0' (end of input) ++ * must not match */ ++ if (c > 0) ++ addstate(nextlist, t->state->out, &t->sub, n, listid + 1, ++ &match); ++ break; ++ ++ /* ++ * Character classes like \a for alpha, \d for digit etc. ++ */ ++ case NFA_IDENT: /* \i */ ++ result = vim_isIDc(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_SIDENT: /* \I */ ++ result = !VIM_ISDIGIT(c) && vim_isIDc(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_KWORD: /* \k */ ++ result = vim_iswordp(cc); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_SKWORD: /* \K */ ++ result = !VIM_ISDIGIT(c) && vim_iswordp(cc); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_FNAME: /* \f */ ++ result = vim_isfilec(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_SFNAME: /* \F */ ++ result = !VIM_ISDIGIT(c) && vim_isfilec(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_PRINT: /* \p */ ++ result = ptr2cells(cc) == 1; ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_SPRINT: /* \P */ ++ result = !VIM_ISDIGIT(c) && ptr2cells(cc) == 1; ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_WHITE: /* \s */ ++ result = vim_iswhite(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_NWHITE: /* \S */ ++ result = c != NUL && !vim_iswhite(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_DIGIT: /* \d */ ++ result = ri_digit(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_NDIGIT: /* \D */ ++ result = c != NUL && !ri_digit(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_HEX: /* \x */ ++ result = ri_hex(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_NHEX: /* \X */ ++ result = c != NUL && !ri_hex(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_OCTAL: /* \o */ ++ result = ri_octal(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_NOCTAL: /* \O */ ++ result = c != NUL && !ri_octal(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_WORD: /* \w */ ++ result = ri_word(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_NWORD: /* \W */ ++ result = c != NUL && !ri_word(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_HEAD: /* \h */ ++ result = ri_head(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_NHEAD: /* \H */ ++ result = c != NUL && !ri_head(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_ALPHA: /* \a */ ++ result = ri_alpha(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_NALPHA: /* \A */ ++ result = c != NUL && !ri_alpha(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_LOWER: /* \l */ ++ result = ri_lower(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_NLOWER: /* \L */ ++ result = c != NUL && !ri_lower(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_UPPER: /* \u */ ++ result = ri_upper(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ case NFA_NUPPER: /* \U */ ++ result = c != NUL && !ri_upper(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ ++ default: /* regular character */ ++ result = (no_Magic(t->state->c) == c); ++ if (!result) ++ result = ireg_ic == TRUE ++ && MB_TOLOWER(t->state->c) == MB_TOLOWER(c); ++ ADD_POS_NEG_STATE(t->state); ++ break; ++ } ++ ++ } /* for (thislist = thislist; thislist->state; thislist++) */ ++ ++ /* The first found match is the leftmost one, but there may be a ++ * longer one. Keep running the NFA, but don't start from the ++ * beginning. Also, do not add the start state in recursive calls of ++ * nfa_regmatch(), because recursive calls should only start in the ++ * first position. */ ++ if (match == FALSE && start->c == NFA_MOPEN + 0) ++ { ++ #ifdef ENABLE_LOG ++ fprintf(log_fd, "(---) STARTSTATE\n"); ++ #endif ++ addstate(nextlist, start, m, n, listid + 1, &match); ++ } ++ ++ if (reginput_updated) ++ { ++ reginput_updated = FALSE; ++ goto again; ++ } ++ ++ #ifdef ENABLE_LOG ++ fprintf(log_fd, ">>> Thislist had %d states available: ", thislist->n); ++ for (i = 0; i< thislist->n; i++) ++ fprintf(log_fd, "%d ", abs(thislist->t[i].state->id)); ++ fprintf(log_fd, "\n"); ++ #endif ++ ++ nextchar: ++ reginput += n; ++ } while (c || reginput_updated); ++ ++ #ifdef ENABLE_LOG ++ if (log_fd != stderr) ++ fclose(log_fd); ++ log_fd = NULL; ++ #endif ++ ++ theend: ++ /* Free memory */ ++ vim_free(list[0].t); ++ vim_free(list[1].t); ++ vim_free(list[2].t); ++ list[0].t = list[1].t = list[2].t = NULL; ++ if (listids != NULL) ++ vim_free(listids); ++ #undef ADD_POS_NEG_STATE ++ #ifdef DEBUG ++ fclose(debug); ++ #endif ++ ++ return match; ++ } ++ ++ /* ++ * Try match of "prog" with at regline["col"]. ++ * Returns 0 for failure, number of lines contained in the match otherwise. ++ */ ++ static long ++ nfa_regtry(start, col) ++ nfa_state_T *start; ++ colnr_T col; ++ { ++ int i; ++ regsub_T sub, m; ++ #ifdef ENABLE_LOG ++ FILE *f; ++ #endif ++ ++ reginput = regline + col; ++ need_clear_subexpr = TRUE; ++ ++ #ifdef ENABLE_LOG ++ f = fopen(LOG_NAME, "a"); ++ if (f != NULL) ++ { ++ fprintf(f, "\n\n\n\n\n\n\t\t=======================================================\n"); ++ fprintf(f, " =======================================================\n"); ++ #ifdef DEBUG ++ fprintf(f, "\tRegexp is \"%s\"\n", nfa_regengine.expr); ++ #endif ++ fprintf(f, "\tInput text is \"%s\" \n", reginput); ++ fprintf(f, " =======================================================\n\n\n\n\n\n\n"); ++ nfa_print_state(f, start, 0); ++ fprintf(f, "\n\n"); ++ fclose(f); ++ } ++ else ++ EMSG(_("Could not open temporary log file for writing ")); ++ #endif ++ ++ if (REG_MULTI) ++ { ++ /* Use 0xff to set lnum to -1 */ ++ vim_memset(sub.startpos, 0xff, sizeof(lpos_T) * NSUBEXP); ++ vim_memset(sub.endpos, 0xff, sizeof(lpos_T) * NSUBEXP); ++ vim_memset(m.startpos, 0xff, sizeof(lpos_T) * NSUBEXP); ++ vim_memset(m.endpos, 0xff, sizeof(lpos_T) * NSUBEXP); ++ } ++ else ++ { ++ vim_memset(sub.start, 0, sizeof(char_u *) * NSUBEXP); ++ vim_memset(sub.end, 0, sizeof(char_u *) * NSUBEXP); ++ vim_memset(m.start, 0, sizeof(char_u *) * NSUBEXP); ++ vim_memset(m.end, 0, sizeof(char_u *) * NSUBEXP); ++ } ++ ++ if (nfa_regmatch(start, &sub, &m) == FALSE) ++ return 0; ++ ++ cleanup_subexpr(); ++ if (REG_MULTI) ++ { ++ for (i = 0; i < NSUBEXP; i++) ++ { ++ reg_startpos[i] = sub.startpos[i]; ++ reg_endpos[i] = sub.endpos[i]; ++ } ++ ++ if (reg_startpos[0].lnum < 0) ++ { ++ reg_startpos[0].lnum = 0; ++ reg_startpos[0].col = col; ++ } ++ if (reg_endpos[0].lnum < 0) ++ { ++ reg_endpos[0].lnum = reglnum; ++ reg_endpos[0].col = (int)(reginput - regline); ++ } ++ else ++ /* Use line number of "\ze". */ ++ reglnum = reg_endpos[0].lnum; ++ } ++ else ++ { ++ for (i = 0; i < NSUBEXP; i++) ++ { ++ reg_startp[i] = sub.start[i]; ++ reg_endp[i] = sub.end[i]; ++ } ++ ++ if (reg_startp[0] == NULL) ++ reg_startp[0] = regline + col; ++ if (reg_endp[0] == NULL) ++ reg_endp[0] = reginput; ++ } ++ ++ return 1 + reglnum; ++ } ++ ++ /* ++ * Match a regexp against a string ("line" points to the string) or multiple ++ * lines ("line" is NULL, use reg_getline()). ++ * ++ * Returns 0 for failure, number of lines contained in the match otherwise. ++ */ ++ static long ++ nfa_regexec_both(line, col) ++ char_u *line; ++ colnr_T col; /* column to start looking for match */ ++ { ++ nfa_regprog_T *prog; ++ long retval = 0L; ++ int i; ++ ++ if (REG_MULTI) ++ { ++ prog = (nfa_regprog_T *)reg_mmatch->regprog; ++ line = reg_getline((linenr_T)0); /* relative to the cursor */ ++ reg_startpos = reg_mmatch->startpos; ++ reg_endpos = reg_mmatch->endpos; ++ } ++ else ++ { ++ prog = (nfa_regprog_T *)reg_match->regprog; ++ reg_startp = reg_match->startp; ++ reg_endp = reg_match->endp; ++ } ++ ++ /* Be paranoid... */ ++ if (prog == NULL || line == NULL) ++ { ++ EMSG(_(e_null)); ++ goto theend; ++ } ++ ++ /* If the start column is past the maximum column: no need to try. */ ++ if (ireg_maxcol > 0 && col >= ireg_maxcol) ++ goto theend; ++ ++ /* If pattern contains "\c" or "\C": overrule value of ireg_ic */ ++ if (prog->regflags & RF_ICASE) ++ ireg_ic = TRUE; ++ else if (prog->regflags & RF_NOICASE) ++ ireg_ic = FALSE; ++ ++ #ifdef FEAT_MBYTE ++ /* If pattern contains "\Z" overrule value of ireg_icombine */ ++ if (prog->regflags & RF_ICOMBINE) ++ ireg_icombine = TRUE; ++ #endif ++ ++ regline = line; ++ reglnum = 0; /* relative to line */ ++ ++ nstate = prog->nstate; ++ ++ for (i = 0; i < nstate; ++i) ++ { ++ prog->state[i].id = i; ++ prog->state[i].lastlist = 0; ++ prog->state[i].visits = 0; ++ prog->state[i].lastthread = NULL; ++ } ++ ++ retval = nfa_regtry(prog->start, col); ++ ++ theend: ++ return retval; ++ } ++ ++ /* ++ * Compile a regular expression into internal code for the NFA matcher. ++ * Returns the program in allocated space. Returns NULL for an error. ++ */ ++ static regprog_T * ++ nfa_regcomp(expr, re_flags) ++ char_u *expr; ++ int re_flags; ++ { ++ nfa_regprog_T *prog; ++ int prog_size; ++ int *postfix; ++ ++ if (expr == NULL) ++ return NULL; ++ ++ #ifdef DEBUG ++ nfa_regengine.expr = expr; ++ #endif ++ ++ init_class_tab(); ++ ++ if (nfa_regcomp_start(expr, re_flags) == FAIL) ++ return NULL; ++ ++ /* Space for compiled regexp */ ++ prog_size = sizeof(nfa_regprog_T) + sizeof(nfa_state_T) * nstate_max; ++ prog = (nfa_regprog_T *)lalloc(prog_size, TRUE); ++ if (prog == NULL) ++ goto fail; ++ vim_memset(prog, 0, prog_size); ++ ++ /* Build postfix form of the regexp. Needed to build the NFA ++ * (and count its size) */ ++ postfix = re2post(); ++ if (postfix == NULL) ++ goto fail; /* Cascaded (syntax?) error */ ++ ++ /* ++ * In order to build the NFA, we parse the input regexp twice: ++ * 1. first pass to count size (so we can allocate space) ++ * 2. second to emit code ++ */ ++ #ifdef ENABLE_LOG ++ { ++ FILE *f = fopen(LOG_NAME, "a"); ++ ++ if (f != NULL) ++ { ++ fprintf(f, "\n*****************************\n\n\n\n\tCompiling regexp \"%s\" ... hold on !\n", expr); ++ fclose(f); ++ } ++ } ++ #endif ++ ++ /* ++ * PASS 1 ++ * Count number of NFA states in "nstate". Do not build the NFA. ++ */ ++ post2nfa(postfix, post_ptr, TRUE); ++ state_ptr = prog->state; ++ ++ /* ++ * PASS 2 ++ * Build the NFA ++ */ ++ prog->start = post2nfa(postfix, post_ptr, FALSE); ++ if (prog->start == NULL) ++ goto fail; ++ ++ prog->regflags = regflags; ++ prog->engine = &nfa_regengine; ++ prog->nstate = nstate; ++ #ifdef ENABLE_LOG ++ nfa_postfix_dump(expr, OK); ++ nfa_dump(prog); ++ #endif ++ ++ out: ++ vim_free(post_start); ++ post_start = post_ptr = post_end = NULL; ++ state_ptr = NULL; ++ return (regprog_T *)prog; ++ ++ fail: ++ vim_free(prog); ++ prog = NULL; ++ #ifdef ENABLE_LOG ++ nfa_postfix_dump(expr, FAIL); ++ #endif ++ #ifdef DEBUG ++ nfa_regengine.expr = NULL; ++ #endif ++ goto out; ++ } ++ ++ ++ /* ++ * Match a regexp against a string. ++ * "rmp->regprog" is a compiled regexp as returned by nfa_regcomp(). ++ * Uses curbuf for line count and 'iskeyword'. ++ * ++ * Return TRUE if there is a match, FALSE if not. ++ */ ++ static int ++ nfa_regexec(rmp, line, col) ++ regmatch_T *rmp; ++ char_u *line; /* string to match against */ ++ colnr_T col; /* column to start looking for match */ ++ { ++ reg_match = rmp; ++ reg_mmatch = NULL; ++ reg_maxline = 0; ++ reg_line_lbr = FALSE; ++ reg_buf = curbuf; ++ reg_win = NULL; ++ ireg_ic = rmp->rm_ic; ++ #ifdef FEAT_MBYTE ++ ireg_icombine = FALSE; ++ #endif ++ ireg_maxcol = 0; ++ return (nfa_regexec_both(line, col) != 0); ++ } ++ ++ #if defined(FEAT_MODIFY_FNAME) || defined(FEAT_EVAL) \ ++ || defined(FIND_REPLACE_DIALOG) || defined(PROTO) ++ ++ static int nfa_regexec_nl __ARGS((regmatch_T *rmp, char_u *line, colnr_T col)); ++ ++ /* ++ * Like nfa_regexec(), but consider a "\n" in "line" to be a line break. ++ */ ++ static int ++ nfa_regexec_nl(rmp, line, col) ++ regmatch_T *rmp; ++ char_u *line; /* string to match against */ ++ colnr_T col; /* column to start looking for match */ ++ { ++ reg_match = rmp; ++ reg_mmatch = NULL; ++ reg_maxline = 0; ++ reg_line_lbr = TRUE; ++ reg_buf = curbuf; ++ reg_win = NULL; ++ ireg_ic = rmp->rm_ic; ++ #ifdef FEAT_MBYTE ++ ireg_icombine = FALSE; ++ #endif ++ ireg_maxcol = 0; ++ return (nfa_regexec_both(line, col) != 0); ++ } ++ #endif ++ ++ ++ /* ++ * Match a regexp against multiple lines. ++ * "rmp->regprog" is a compiled regexp as returned by vim_regcomp(). ++ * Uses curbuf for line count and 'iskeyword'. ++ * ++ * Return zero if there is no match. Return number of lines contained in the ++ * match otherwise. ++ * ++ * Note: the body is the same as bt_regexec() except for nfa_regexec_both() ++ * ++ * ! Also NOTE : match may actually be in another line. e.g.: ++ * when r.e. is \nc, cursor is at 'a' and the text buffer looks like ++ * ++ * +-------------------------+ ++ * |a | ++ * |b | ++ * |c | ++ * | | ++ * +-------------------------+ ++ * ++ * then nfa_regexec_multi() returns 3. while the original ++ * vim_regexec_multi() returns 0 and a second call at line 2 will return 2. ++ * ++ * FIXME if this behavior is not compatible. ++ */ ++ static long ++ nfa_regexec_multi(rmp, win, buf, lnum, col, tm) ++ regmmatch_T *rmp; ++ win_T *win; /* window in which to search or NULL */ ++ buf_T *buf; /* buffer in which to search */ ++ linenr_T lnum; /* nr of line to start looking for match */ ++ colnr_T col; /* column to start looking for match */ ++ proftime_T *tm UNUSED; /* timeout limit or NULL */ ++ { ++ long r; ++ buf_T *save_curbuf = curbuf; ++ ++ reg_match = NULL; ++ reg_mmatch = rmp; ++ reg_buf = buf; ++ reg_win = win; ++ reg_firstlnum = lnum; ++ reg_maxline = reg_buf->b_ml.ml_line_count - lnum; ++ reg_line_lbr = FALSE; ++ ireg_ic = rmp->rmm_ic; ++ #ifdef FEAT_MBYTE ++ ireg_icombine = FALSE; ++ #endif ++ ireg_maxcol = rmp->rmm_maxcol; ++ ++ /* Need to switch to buffer "buf" to make vim_iswordc() work. */ ++ curbuf = buf; ++ r = nfa_regexec_both(NULL, col); ++ curbuf = save_curbuf; ++ ++ return r; ++ } ++ ++ #ifdef DEBUG ++ # undef ENABLE_LOG ++ #endif +*** ../vim-7.3.969/src/structs.h 2013-05-15 15:12:25.000000000 +0200 +--- src/structs.h 2013-05-17 18:54:19.000000000 +0200 +*************** +*** 63,77 **** + + #define GA_EMPTY {0, 0, 0, 0, NULL} + +- /* +- * This is here because regexp.h needs pos_T and below regprog_T is used. +- */ +- #include "regexp.h" +- + typedef struct window_S win_T; + typedef struct wininfo_S wininfo_T; + typedef struct frame_S frame_T; + typedef int scid_T; /* script ID */ + + /* + * This is here because gui.h needs the pos_T and win_T, and win_T needs gui.h +--- 63,78 ---- + + #define GA_EMPTY {0, 0, 0, 0, NULL} + + typedef struct window_S win_T; + typedef struct wininfo_S wininfo_T; + typedef struct frame_S frame_T; + typedef int scid_T; /* script ID */ ++ typedef struct file_buffer buf_T; /* forward declaration */ ++ ++ /* ++ * This is here because regexp.h needs pos_T and below regprog_T is used. ++ */ ++ #include "regexp.h" + + /* + * This is here because gui.h needs the pos_T and win_T, and win_T needs gui.h +*************** +*** 526,533 **** + # endif + } cmdmod_T; + +- typedef struct file_buffer buf_T; /* forward declaration */ +- + #define MF_SEED_LEN 8 + + struct memfile +--- 527,532 ---- +*** ../vim-7.3.969/src/testdir/Makefile 2013-04-24 12:56:13.000000000 +0200 +--- src/testdir/Makefile 2013-05-18 14:22:50.000000000 +0200 +*************** +*** 29,35 **** + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ + test89.out test90.out test91.out test92.out test93.out \ +! test94.out + + SCRIPTS_GUI = test16.out + +--- 29,35 ---- + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ + test89.out test90.out test91.out test92.out test93.out \ +! test94.out test95.out + + SCRIPTS_GUI = test16.out + +*************** +*** 85,97 **** + fi" + + # Check if the test.out file matches test.ok. +! @/bin/sh -c "if test -f test.out; then\ + if diff test.out $*.ok; \ + then mv -f test.out $*.out; \ + else echo $* FAILED >>test.log; mv -f test.out $*.failed; \ + fi \ + else echo $* NO OUTPUT >>test.log; \ + fi" + -rm -rf X* test.ok viminfo + + test49.out: test49.vim +--- 85,100 ---- + fi" + + # Check if the test.out file matches test.ok. +! @/bin/sh -c "if test -f test.out; then \ + if diff test.out $*.ok; \ + then mv -f test.out $*.out; \ + else echo $* FAILED >>test.log; mv -f test.out $*.failed; \ + fi \ + else echo $* NO OUTPUT >>test.log; \ + fi" ++ @/bin/sh -c "if test -f valgrind; then\ ++ mv -f valgrind valgrind.$*; \ ++ fi" + -rm -rf X* test.ok viminfo + + test49.out: test49.vim +*** ../vim-7.3.969/src/testdir/test64.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test64.in 2013-05-19 16:05:36.000000000 +0200 +*************** +*** 1,4 **** +! Test for regexp patterns. + + A pattern that gives the expected result produces OK, so that we know it was + actually tried. +--- 1,5 ---- +! Test for regexp patterns without multi-byte support. +! See test95 for multi-byte tests. + + A pattern that gives the expected result produces OK, so that we know it was + actually tried. +*************** +*** 14,19 **** +--- 15,25 ---- + :" etc. + :" When there is no match use only the first two items. + :let tl = [] ++ ++ :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" ++ :"""" Previously written tests """""""""""""""""""""""""""""""" ++ :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" ++ + :call add(tl, ['ab', 'aab', 'ab']) + :call add(tl, ['b', 'abcdef', 'b']) + :call add(tl, ['bc*', 'abccccdef', 'bcccc']) +*************** +*** 132,137 **** +--- 138,301 ---- + :" + :call add(tl, ['\v(a*)+', 'aaaa', 'aaaa', '']) + :call add(tl, ['x', 'abcdef']) ++ ++ :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" ++ :""""" Simple tests """"""""""""""""""""""""""""""""""""""""""" ++ :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" ++ ++ :" Search single groups ++ :call add(tl, ['ab', 'aab', 'ab']) ++ :call add(tl, ['ab', 'baced']) ++ :call add(tl, ['ab', ' ab ', 'ab']) ++ ++ :" Search multi-modifiers ++ :call add(tl, ['x*', 'xcd', 'x']) ++ :call add(tl, ['x*', 'xxxxxxxxxxxxxxxxsofijiojgf', 'xxxxxxxxxxxxxxxx']) ++ :call add(tl, ['x*', 'abcdoij', '']) " empty match is good ++ :call add(tl, ['x\+', 'abcdoin']) " no match here ++ :call add(tl, ['x\+', 'abcdeoijdfxxiuhfij', 'xx']) ++ :call add(tl, ['x\+', 'xxxxx', 'xxxxx']) ++ :call add(tl, ['x\+', 'abc x siufhiush xxxxxxxxx', 'x']) ++ :call add(tl, ['x\=', 'x sdfoij', 'x']) ++ :call add(tl, ['x\=', 'abc sfoij', '']) " empty match is good ++ :call add(tl, ['x\=', 'xxxxxxxxx c', 'x']) ++ :call add(tl, ['x\?', 'x sdfoij', 'x']) ++ :call add(tl, ['x\?', 'abc sfoij', '']) " empty match is good ++ :call add(tl, ['x\?', 'xxxxxxxxxx c', 'x']) ++ ++ :call add(tl, ['a\{0,0}', 'abcdfdoij', '']) ++ :call add(tl, ['a\{0,1}', 'asiubid axxxaaa', 'a']) " same thing as 'a?' ++ :call add(tl, ['a\{1,0}', 'asiubid axxxaaa', 'a']) " same thing as 'a\{0,1}' ++ :call add(tl, ['a\{3,6}', 'aa siofuh']) ++ :call add(tl, ['a\{3,6}', 'aaaaa asfoij afaa', 'aaaaa']) ++ :call add(tl, ['a\{3,6}', 'aaaaaaaa', 'aaaaaa']) ++ :call add(tl, ['a\{0}', 'asoiuj', '']) ++ :call add(tl, ['a\{2}', 'aaaa', 'aa']) ++ :call add(tl, ['a\{2}', 'iuash fiusahfliusah fiushfilushfi uhsaifuh askfj nasfvius afg aaaa sfiuhuhiushf', 'aa']) ++ :call add(tl, ['a\{2}', 'abcdefghijklmnopqrestuvwxyz1234567890']) ++ :call add(tl, ['a\{0,}', 'oij sdigfusnf', '']) " same thing as 'a*' ++ :call add(tl, ['a\{0,}', 'aaaaa aa', 'aaaaa']) ++ :call add(tl, ['a\{2,}', 'sdfiougjdsafg']) ++ :call add(tl, ['a\{2,}', 'aaaaasfoij ', 'aaaaa']) ++ :call add(tl, ['a\{,0}', 'oidfguih iuhi hiu aaaa', '']) ++ :call add(tl, ['a\{,5}', 'abcd', 'a']) ++ :call add(tl, ['a\{,5}', 'aaaaaaaaaa', 'aaaaa']) ++ :call add(tl, ['a\{}', 'bbbcddiuhfcd', '']) " same thing as 'a*' ++ :call add(tl, ['a\{}', 'aaaaioudfh coisf jda', 'aaaa']) ++ ++ :call add(tl, ['a\{-0,0}', 'abcdfdoij', '']) ++ :call add(tl, ['a\{-0,1}', 'asiubid axxxaaa', '']) " anti-greedy version of 'a?' ++ :call add(tl, ['a\{-3,6}', 'aa siofuh']) ++ :call add(tl, ['a\{-3,6}', 'aaaaa asfoij afaa', 'aaa']) ++ :call add(tl, ['a\{-3,6}', 'aaaaaaaa', 'aaa']) ++ :call add(tl, ['a\{-0}', 'asoiuj', '']) ++ :call add(tl, ['a\{-2}', 'aaaa', 'aa']) ++ :call add(tl, ['a\{-2}', 'abcdefghijklmnopqrestuvwxyz1234567890']) ++ :call add(tl, ['a\{-0,}', 'oij sdigfusnf', '']) ++ :call add(tl, ['a\{-0,}', 'aaaaa aa', '']) ++ :call add(tl, ['a\{-2,}', 'sdfiougjdsafg']) ++ :call add(tl, ['a\{-2,}', 'aaaaasfoij ', 'aa']) ++ :call add(tl, ['a\{-,0}', 'oidfguih iuhi hiu aaaa', '']) ++ :call add(tl, ['a\{-,5}', 'abcd', '']) ++ :call add(tl, ['a\{-,5}', 'aaaaaaaaaa', '']) ++ :call add(tl, ['a\{-}', 'bbbcddiuhfcd', '']) " anti-greedy version of 'a*' ++ :call add(tl, ['a\{-}', 'aaaaioudfh coisf jda', '']) ++ ++ :" Test groups of characters and submatches ++ :call add(tl, ['\(abc\)*', 'abcabcabc', 'abcabcabc', 'abc']) ++ :call add(tl, ['\(ab\)\+', 'abababaaaaa', 'ababab', 'ab']) ++ :call add(tl, ['\(abaaaaa\)*cd', 'cd', 'cd', '']) ++ :call add(tl, ['\(test1\)\? \(test2\)\?', 'test1 test3', 'test1 ', 'test1', '']) ++ :call add(tl, ['\(test1\)\= \(test2\) \(test4443\)\=', ' test2 test4443 yupiiiiiiiiiii', ' test2 test4443', '', 'test2', 'test4443']) ++ :call add(tl, ['\(\(sub1\) hello \(sub 2\)\)', 'asterix sub1 hello sub 2 obelix', 'sub1 hello sub 2', 'sub1 hello sub 2', 'sub1', 'sub 2']) ++ :call add(tl, ['\(\(\(yyxxzz\)\)\)', 'abcdddsfiusfyyzzxxyyxxzz', 'yyxxzz', 'yyxxzz', 'yyxxzz', 'yyxxzz']) ++ :call add(tl, ['\v((ab)+|c+)+', 'abcccaba', 'abcccab', 'ab', 'ab']) ++ :call add(tl, ['\v((ab)|c*)+', 'abcccaba', 'abcccab', '', 'ab']) ++ :call add(tl, ['\v(a(c*)+b)+', 'acbababaaa', 'acbabab', 'ab', '']) ++ :call add(tl, ['\v(a|b*)+', 'aaaa', 'aaaa', '']) ++ ++ :" Test greedy-ness and lazy-ness ++ :call add(tl, ['a\{-2,7}','aaaaaaaaaaaaa', 'aa']) ++ :call add(tl, ['a\{2,7}','aaaaaaaaaaaaaaaaaaaa', 'aaaaaaa']) ++ :call add(tl, ['\vx(.{-,8})yz(.*)','xayxayzxayzxayz','xayxayzxayzxayz','ayxa','xayzxayz']) ++ :call add(tl, ['\vx(.*)yz(.*)','xayxayzxayzxayz','xayxayzxayzxayz', 'ayxayzxayzxa','']) ++ :call add(tl, ['\v(a{1,2}){-2,3}','aaaaaaa','aaaa','aa']) ++ :call add(tl, ['\v(a{-1,3})+','aa','aa','a']) ++ ++ :" Test Character classes ++ :call add(tl, ['\d\+e\d\d','test 10e23 fd','10e23']) ++ ++ :" Test collections and character range [] ++ :call add(tl, ['\v[a]', 'abcd', 'a']) ++ :call add(tl, ['a[bcd]', 'abcd', 'ab']) ++ :call add(tl, ['a[b-d]', 'acbd', 'ac']) ++ :call add(tl, ['[a-d][e-f][x-x]d', 'cexdxx', 'cexd']) ++ :call add(tl, ['\v[[:alpha:]]+', 'abcdefghijklmnopqrstuvwxyz6','abcdefghijklmnopqrstuvwxyz']) ++ :call add(tl, ['[[:alpha:]\+]', '6x8','x']) ++ :call add(tl, ['[^abc]\+','abcabcabc']) ++ :call add(tl, ['[^abc]','defghiasijvoinasoiunbvb','d']) ++ :call add(tl, ['[^abc]\+','ddddddda','ddddddd']) ++ :call add(tl, ['[^a-d]\+','aaaAAAZIHFNCddd','AAAZIHFNC']) ++ :call add(tl, ['[a-f]*','iiiiiiii','']) ++ :call add(tl, ['[a-f]*','abcdefgh','abcdef']) ++ :call add(tl, ['[^a-f]\+','abcdefgh','gh']) ++ :call add(tl, ['[a-c]\{-3,6}','abcabc','abc']) ++ :call add(tl, ['[^[:alpha:]]\+','abcccadfoij7787ysf287yrnccdu','7787']) ++ :call add(tl, ['[-a]', '-', '-']) ++ :call add(tl, ['[a-]', '-', '-']) ++ :call add(tl, ['[-./[:alnum:]_~]\+', 'log13.file', 'log13.file']) " filename regexp ++ :call add(tl, ['[\]\^\-\\]\+', '\^\\\-\---^', '\^\\\-\---^']) " special chars ++ :call add(tl, ['[[.a.]]\+', 'aa', 'aa']) " collation elem ++ :call add(tl, ['abc[0-9]*ddd', 'siuhabc ii']) " middle of regexp ++ :call add(tl, ['abc[0-9]*ddd', 'adf abc44482ddd oijs', 'abc44482ddd']) ++ :call add(tl, ['\_[0-9]\+', 'asfi9888u', '9888']) ++ :call add(tl, ['[0-9\n]\+', 'asfi9888u', '9888']) ++ ++ ++ :"""" Test recognition of some character classes ++ :call add(tl, ['[0-9]', '8', '8']) ++ :call add(tl, ['[^0-9]', '8']) ++ :call add(tl, ['[0-9a-fA-F]*', '0a7', '0a7']) ++ :call add(tl, ['[^0-9A-Fa-f]\+', '0a7']) ++ :call add(tl, ['[a-z_A-Z0-9]\+', 'aso_sfoij', 'aso_sfoij']) ++ :call add(tl, ['[a-z]', 'a', 'a']) ++ :call add(tl, ['[a-zA-Z]', 'a', 'a']) ++ :call add(tl, ['[A-Z]', 'a']) ++ :call add(tl, ['\C[^A-Z]\+', 'ABCOIJDEOIFNSD jsfoij sa', ' jsfoij sa']) ++ ++ :"""" Tests for \z features ++ :call add(tl, ['xx \ze test', 'xx ']) " must match after \ze ++ :call add(tl, ['abc\zeend', 'oij abcend', 'abc']) ++ :call add(tl, ['abc\zsdd', 'ddabcddxyzt', 'dd']) ++ :call add(tl, ['aa \zsax', ' ax']) " must match before \zs ++ :call add(tl, ['abc \zsmatch\ze abc', 'abc abc abc match abc abc', 'match']) ++ :call add(tl, ['\v(a \zsif .*){2}', 'a if then a if last', 'if last', 'a if last']) ++ ++ :"""" Tests for \@ features ++ :call add(tl, ['abc\@=', 'abc', 'ab']) ++ :call add(tl, ['abc\@=cd', 'abcd', 'abcd']) ++ :call add(tl, ['abc\@=', 'ababc', 'ab']) ++ :call add(tl, ['abcd\@=e', 'abcd']) " will never match, no matter the input text ++ :call add(tl, ['abcd\@=e', 'any text in here ... ']) " will never match ++ :call add(tl, ['\v(abc)@=..', 'xabcd', 'ab', 'abc']) ++ :call add(tl, ['\(.*John\)\@=.*Bob', 'here is John, and here is B']) " no match ++ :call add(tl, ['\(John.*\)\@=.*Bob', 'John is Bobs friend', 'John is Bob', 'John is Bobs friend']) ++ :call add(tl, ['.*John\&.*Bob', 'here is John, and here is B']) " no match ++ :call add(tl, ['.*John\&.*Bob', 'John is Bobs friend', 'John is Bob']) ++ :call add(tl, ['\v(test1)@=.*yep', 'this is a test1, yep it is', 'test1, yep', 'test1']) ++ ++ :"""" Combining different tests and features ++ :call add(tl, ['[[:alpha:]]\{-2,6}', '787abcdiuhsasiuhb4', 'ab']) ++ :call add(tl, ['[^[=a=]]\+', 'ddaãâbcd', 'dd']) ++ :call add(tl, ['', 'abcd', '']) ++ :call add(tl, ['\v(())', 'any possible text', '']) ++ :call add(tl, ['\v%(ab(xyz)c)', ' abxyzc ', 'abxyzc', 'xyz']) ++ :call add(tl, ['\v(test|)empty', 'tesempty', 'empty', '']) ++ :call add(tl, ['\v(a|aa)(a|aa)', 'aaa', 'aa', 'a', 'a']) ++ ++ ++ :"""" Run the tests ++ + :" + :for t in tl + : let l = matchlist(t[1], t[0]) +*************** +*** 143,149 **** + : elseif len(t) > 2 && l[0] != t[2] + : $put ='ERROR: pat: \"' . t[0] . '\", text: \"' . t[1] . '\", match: \"' . l[0] . '\", expected: \"' . t[2] . '\"' + : else +! : $put ='OK' + : endif + : if len(l) > 0 + :" check all the nine submatches +--- 307,313 ---- + : elseif len(t) > 2 && l[0] != t[2] + : $put ='ERROR: pat: \"' . t[0] . '\", text: \"' . t[1] . '\", match: \"' . l[0] . '\", expected: \"' . t[2] . '\"' + : else +! : $put ='OK - ' . t[0] + : endif + : if len(l) > 0 + :" check all the nine submatches +*************** +*** 161,167 **** + : endif + :endfor + :unlet t tl e l +! :/^Results/,$wq! test.out + ENDTEST + + Results of test64: +--- 325,341 ---- + : endif + :endfor + :unlet t tl e l +! +! :" Check that \_[0-9] matching EOL does not break a following \> +! :" This only works on a buffer line, not with expression evaluation +! /^Find this +! /\<\(\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\.\)\{3\}\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\> +! y$Gop:" +! +! :/\%#=1^Results/,$wq! test.out + ENDTEST + ++ Find this: ++ localnet/192.168.0.1 ++ + Results of test64: +*** ../vim-7.3.969/src/testdir/test64.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test64.ok 2013-05-19 16:05:16.000000000 +0200 +*************** +*** 1,102 **** + Results of test64: +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +! OK +--- 1,230 ---- + Results of test64: +! OK - ab +! OK - b +! OK - bc* +! OK - bc\{-} +! OK - bc\{-}\(d\) +! OK - bc* +! OK - c* +! OK - bc* +! OK - c* +! OK - bc\+ +! OK - bc\+ +! OK - a\|ab +! OK - c\? +! OK - bc\? +! OK - bc\? +! OK - \va{1} +! OK - \va{2} +! OK - \va{2} +! OK - \va{2} +! OK - \va{2} +! OK - \va{2} +! OK - \va{2} +! OK - \vb{1} +! OK - \vba{2} +! OK - \vba{3} +! OK - \v(ab){1} +! OK - \v(ab){1} +! OK - \v(ab){1} +! OK - \v(ab){0,2} +! OK - \v(ab){0,2} +! OK - \v(ab){1,2} +! OK - \v(ab){1,2} +! OK - \v(ab){2,4} +! OK - \v(ab){2,4} +! OK - \v(ab){2} +! OK - \v(ab){2} +! OK - \v(ab){2} +! OK - \v(ab){2} +! OK - \v((ab){2}){2} +! OK - \v((ab){2}){2} +! OK - \v(a{1}){1} +! OK - \v(a{2}){1} +! OK - \v(a{2}){1} +! OK - \v(a{2}){1} +! OK - \v(a{1}){2} +! OK - \v(a{1}){2} +! OK - \v(a{2})+ +! OK - \v(a{2})+ +! OK - \v(a{2}){1} +! OK - \v(a{1}){2} +! OK - \v(a{1}){1} +! OK - \v(a{2}){2} +! OK - \v(a{2}){2} +! OK - \v(a+){2} +! OK - \v(a{3}){2} +! OK - \v(a{1,2}){2} +! OK - \v(a{1,3}){2} +! OK - \v(a{1,3}){2} +! OK - \v(a{1,3}){3} +! OK - \v(a{1,2}){2} +! OK - \v(a+)+ +! OK - \v(a+)+ +! OK - \v(a+){1,2} +! OK - \v(a+)(a+) +! OK - \v(a{3})+ +! OK - \v(a|b|c)+ +! OK - \v(a|b|c){2} +! OK - \v(abc){2} +! OK - \v(abc){2} +! OK - a* +! OK - \v(a*)+ +! OK - \v((ab)+)+ +! OK - \v(((ab)+)+)+ +! OK - \v(((ab)+)+)+ +! OK - \v(a{0,2})+ +! OK - \v(a*)+ +! OK - \v((a*)+)+ +! OK - \v((ab)*)+ +! OK - \va{1,3} +! OK - \va{2,3} +! OK - \v((ab)+|c*)+ +! OK - \v(a{2})|(b{3}) +! OK - \va{2}|b{2} +! OK - \v(a)+|(c)+ +! OK - \vab{2,3}c +! OK - \vab{2,3}c +! OK - \vab{2,3}cd{2,3}e +! OK - \va(bc){2}d +! OK - \va*a{2} +! OK - \va*a{2} +! OK - \va*a{2} +! OK - \va*a{2} +! OK - \va*b*|a*c* +! OK - \va{1}b{1}|a{1}b{1} +! OK - \v(a) +! OK - \v(a)(b) +! OK - \v(ab)(b)(c) +! OK - \v((a)(b)) +! OK - \v(a)|(b) +! OK - \v(a*)+ +! OK - x +! OK - ab +! OK - ab +! OK - ab +! OK - x* +! OK - x* +! OK - x* +! OK - x\+ +! OK - x\+ +! OK - x\+ +! OK - x\+ +! OK - x\= +! OK - x\= +! OK - x\= +! OK - x\? +! OK - x\? +! OK - x\? +! OK - a\{0,0} +! OK - a\{0,1} +! OK - a\{1,0} +! OK - a\{3,6} +! OK - a\{3,6} +! OK - a\{3,6} +! OK - a\{0} +! OK - a\{2} +! OK - a\{2} +! OK - a\{2} +! OK - a\{0,} +! OK - a\{0,} +! OK - a\{2,} +! OK - a\{2,} +! OK - a\{,0} +! OK - a\{,5} +! OK - a\{,5} +! OK - a\{} +! OK - a\{} +! OK - a\{-0,0} +! OK - a\{-0,1} +! OK - a\{-3,6} +! OK - a\{-3,6} +! OK - a\{-3,6} +! OK - a\{-0} +! OK - a\{-2} +! OK - a\{-2} +! OK - a\{-0,} +! OK - a\{-0,} +! OK - a\{-2,} +! OK - a\{-2,} +! OK - a\{-,0} +! OK - a\{-,5} +! OK - a\{-,5} +! OK - a\{-} +! OK - a\{-} +! OK - \(abc\)* +! OK - \(ab\)\+ +! OK - \(abaaaaa\)*cd +! OK - \(test1\)\? \(test2\)\? +! OK - \(test1\)\= \(test2\) \(test4443\)\= +! OK - \(\(sub1\) hello \(sub 2\)\) +! OK - \(\(\(yyxxzz\)\)\) +! OK - \v((ab)+|c+)+ +! OK - \v((ab)|c*)+ +! OK - \v(a(c*)+b)+ +! OK - \v(a|b*)+ +! OK - a\{-2,7} +! OK - a\{2,7} +! OK - \vx(.{-,8})yz(.*) +! OK - \vx(.*)yz(.*) +! OK - \v(a{1,2}){-2,3} +! OK - \v(a{-1,3})+ +! OK - \d\+e\d\d +! OK - \v[a] +! OK - a[bcd] +! OK - a[b-d] +! OK - [a-d][e-f][x-x]d +! OK - \v[[:alpha:]]+ +! OK - [[:alpha:]\+] +! OK - [^abc]\+ +! OK - [^abc] +! OK - [^abc]\+ +! OK - [^a-d]\+ +! OK - [a-f]* +! OK - [a-f]* +! OK - [^a-f]\+ +! OK - [a-c]\{-3,6} +! OK - [^[:alpha:]]\+ +! OK - [-a] +! OK - [a-] +! OK - [-./[:alnum:]_~]\+ +! OK - [\]\^\-\\]\+ +! OK - [[.a.]]\+ +! OK - abc[0-9]*ddd +! OK - abc[0-9]*ddd +! OK - \_[0-9]\+ +! OK - [0-9\n]\+ +! OK - [0-9] +! OK - [^0-9] +! OK - [0-9a-fA-F]* +! OK - [^0-9A-Fa-f]\+ +! OK - [a-z_A-Z0-9]\+ +! OK - [a-z] +! OK - [a-zA-Z] +! OK - [A-Z] +! OK - \C[^A-Z]\+ +! OK - xx \ze test +! OK - abc\zeend +! OK - abc\zsdd +! OK - aa \zsax +! OK - abc \zsmatch\ze abc +! OK - \v(a \zsif .*){2} +! OK - abc\@= +! OK - abc\@=cd +! OK - abc\@= +! OK - abcd\@=e +! OK - abcd\@=e +! OK - \v(abc)@=.. +! OK - \(.*John\)\@=.*Bob +! OK - \(John.*\)\@=.*Bob +! OK - .*John\&.*Bob +! OK - .*John\&.*Bob +! OK - \v(test1)@=.*yep +! OK - [[:alpha:]]\{-2,6} +! OK - [^[=a=]]\+ +! OK - +! OK - \v(()) +! OK - \v%(ab(xyz)c) +! OK - \v(test|)empty +! OK - \v(a|aa)(a|aa) +! 192.168.0.1 +*** ../vim-7.3.969/Filelist 2013-03-07 13:32:03.000000000 +0100 +--- Filelist 2013-05-17 19:25:39.000000000 +0200 +*************** +*** 57,62 **** +--- 57,63 ---- + src/popupmnu.c \ + src/quickfix.c \ + src/regexp.c \ ++ src/regexp_nfa.c \ + src/regexp.h \ + src/screen.c \ + src/search.c \ +*** ../vim-7.3.969/runtime/doc/pattern.txt 2011-07-20 17:58:14.000000000 +0200 +--- runtime/doc/pattern.txt 2013-05-17 22:57:02.000000000 +0200 +*************** +*** 21,27 **** + 10. Highlighting matches |match-highlight| + + ============================================================================== +! 1. Search commands *search-commands* *E486* + + */* + /{pattern}[/] Search forward for the [count]'th occurrence of +--- 21,27 ---- + 10. Highlighting matches |match-highlight| + + ============================================================================== +! 1. Search commands *search-commands* + + */* + /{pattern}[/] Search forward for the [count]'th occurrence of +*************** +*** 150,155 **** +--- 150,160 ---- + All matches for the last used search pattern will be highlighted if you set + the 'hlsearch' option. This can be suspended with the |:nohlsearch| command. + ++ When no match is found you get the error: *E486* Pattern not found ++ Note that for the |:global| command this behaves like a normal message, for Vi ++ compatibility. For the |:s| command the "e" flag can be used to avoid the ++ error message |:s_flags|. ++ + *search-offset* *{offset}* + These commands search for the specified pattern. With "/" and "?" an + additional offset may be given. There are two types of offsets: line offsets +*************** +*** 214,220 **** + the search, possibly in another direction or with another count. Note that + two patterns are remembered: One for 'normal' search commands and one for the + substitute command ":s". Each time an empty pattern is given, the previously +! used pattern is used. + + The 'magic' option sticks with the last used pattern. If you change 'magic', + this will not change how the last used pattern will be interpreted. +--- 219,226 ---- + the search, possibly in another direction or with another count. Note that + two patterns are remembered: One for 'normal' search commands and one for the + substitute command ":s". Each time an empty pattern is given, the previously +! used pattern is used. However, if there is no previous search command, a +! previous substitute pattern is used, if possible. + + The 'magic' option sticks with the last used pattern. If you change 'magic', + this will not change how the last used pattern will be interpreted. +*************** +*** 344,349 **** +--- 350,376 ---- + or \z( pattern \) |/\z(| + + ++ */\%#=* *two-engines* ++ Vim includes two regexp engines: ++ 1. An old, backtracking engine that supports everything. ++ 2. A new, NFA engine that works much faster on some patterns, but does not ++ support everything. ++ ++ Vim will automatically select the right engine for you. However, if you run ++ into a problem or want to specifically select one engine or the other, you can ++ prepend one of the following to the pattern: ++ ++ \%#=0 Force automatic selection. Only has an effect when ++ 'regexpengine' has been set to a non-zero value. ++ \%#=1 Force using the old engine. ++ \%#=2 Force using the NFA engine. ++ ++ You can also use the 'regexpengine' option to change the default. ++ ++ *E864* *E868* *E874* *E875* *E876* *E877* *E878* ++ If selecting the NFA engine and it runs into something that is not implemented ++ the pattern will not match. This is only useful when debugging Vim. ++ + ============================================================================== + 3. Magic */magic* + +*************** +*** 390,398 **** + + ============================================================================== + 4. Overview of pattern items *pattern-overview* + + Overview of multi items. */multi* *E61* *E62* +! More explanation and examples below, follow the links. *E64* + + multi ~ + 'magic' 'nomagic' matches of the preceding atom ~ +--- 417,426 ---- + + ============================================================================== + 4. Overview of pattern items *pattern-overview* ++ *E865* *E866* *E867* *E869* + + Overview of multi items. */multi* *E61* *E62* +! More explanation and examples below, follow the links. *E64* *E871* + + multi ~ + 'magic' 'nomagic' matches of the preceding atom ~ +*************** +*** 498,513 **** + x x a character with no special meaning matches itself + + |/[]| [] \[] any character specified inside the [] +! |/\%[]| \%[] \%[] a sequence of optionally matched atoms + + |/\c| \c \c ignore case, do not use the 'ignorecase' option + |/\C| \C \C match case, do not use the 'ignorecase' option + |/\m| \m \m 'magic' on for the following chars in the pattern + |/\M| \M \M 'magic' off for the following chars in the pattern + |/\v| \v \v the following chars in the pattern are "very magic" + |/\V| \V \V the following chars in the pattern are "very nomagic" +! |/\Z| \Z \Z ignore differences in Unicode "combining characters". +! Useful when searching voweled Hebrew or Arabic text. + + |/\%d| \%d \%d match specified decimal character (eg \%d123) + |/\%x| \%x \%x match specified hex character (eg \%x2a) +--- 526,543 ---- + x x a character with no special meaning matches itself + + |/[]| [] \[] any character specified inside the [] +! |/\%[]| \%[] \%[] a sequence of optionally matched atoms + + |/\c| \c \c ignore case, do not use the 'ignorecase' option + |/\C| \C \C match case, do not use the 'ignorecase' option ++ |/\Z| \Z \Z ignore differences in Unicode "combining characters". ++ Useful when searching voweled Hebrew or Arabic text. ++ + |/\m| \m \m 'magic' on for the following chars in the pattern + |/\M| \M \M 'magic' off for the following chars in the pattern + |/\v| \v \v the following chars in the pattern are "very magic" + |/\V| \V \V the following chars in the pattern are "very nomagic" +! |/\%#=| \%#=1 \%#=1 select regexp engine |/zero-width| + + |/\%d| \%d \%d match specified decimal character (eg \%d123) + |/\%x| \%x \%x match specified hex character (eg \%x2a) +*************** +*** 575,581 **** + \? Just like \=. Cannot be used when searching backwards with the "?" + command. {not in Vi} + +! */\{* *E58* *E60* *E554* + \{n,m} Matches n to m of the preceding atom, as many as possible + \{n} Matches n of the preceding atom + \{n,} Matches at least n of the preceding atom, as many as possible +--- 605,611 ---- + \? Just like \=. Cannot be used when searching backwards with the "?" + command. {not in Vi} + +! */\{* *E58* *E60* *E554* *E870* + \{n,m} Matches n to m of the preceding atom, as many as possible + \{n} Matches n of the preceding atom + \{n,} Matches at least n of the preceding atom, as many as possible +*************** +*** 631,647 **** + */\@!* + \@! Matches with zero width if the preceding atom does NOT match at the + current position. |/zero-width| {not in Vi} +! Like '(?!pattern)" in Perl. + Example matches ~ + foo\(bar\)\@! any "foo" not followed by "bar" +! a.\{-}p\@! "a", "ap", "app", etc. not followed by a "p" + if \(\(then\)\@!.\)*$ "if " not followed by "then" + + Using "\@!" is tricky, because there are many places where a pattern + does not match. "a.*p\@!" will match from an "a" to the end of the + line, because ".*" can match all characters in the line and the "p" + doesn't match at the end of the line. "a.\{-}p\@!" will match any +! "a", "ap", "aap", etc. that isn't followed by a "p", because the "." + can match a "p" and "p\@!" doesn't match after that. + + You can't use "\@!" to look for a non-match before the matching +--- 661,678 ---- + */\@!* + \@! Matches with zero width if the preceding atom does NOT match at the + current position. |/zero-width| {not in Vi} +! Like "(?!pattern)" in Perl. + Example matches ~ + foo\(bar\)\@! any "foo" not followed by "bar" +! a.\{-}p\@! "a", "ap", "app", "appp", etc. not immediately +! followed by a "p" + if \(\(then\)\@!.\)*$ "if " not followed by "then" + + Using "\@!" is tricky, because there are many places where a pattern + does not match. "a.*p\@!" will match from an "a" to the end of the + line, because ".*" can match all characters in the line and the "p" + doesn't match at the end of the line. "a.\{-}p\@!" will match any +! "a", "ap", "app", etc. that isn't followed by a "p", because the "." + can match a "p" and "p\@!" doesn't match after that. + + You can't use "\@!" to look for a non-match before the matching +*************** +*** 650,659 **** + "foobar" you could use "\(foo\)\@!...bar", but that doesn't match a + bar at the start of a line. Use "\(foo\)\@ ++ /^\%(.*bar\)\@!.*\zsfoo ++ < This pattern first checks that there is not a single position in the ++ line where "bar" matches. If ".*bar" matches somewhere the \@! will ++ reject the pattern. When there is no match any "foo" will be found. ++ The "\zs" is to have the match start just before "foo". ++ + */\@<=* + \@<= Matches with zero width if the preceding atom matches just before what + follows. |/zero-width| {not in Vi} +! Like "(?<=pattern)" in Perl, but Vim allows non-fixed-width patterns. + Example matches ~ + \(an\_s\+\)\@<=file "file" after "an" and white space or an + end-of-line +*************** +*** 677,683 **** + before what follows. Thus this matches if there is no position in the + current or previous line where the atom matches such that it ends just + before what follows. |/zero-width| {not in Vi} +! Like '(? +*** ../vim-7.3.969/src/option.c 2013-05-11 13:45:00.000000000 +0200 +--- src/option.c 2013-05-17 22:23:14.000000000 +0200 +*************** +*** 2077,2082 **** +--- 2077,2085 ---- + (char_u *)NULL, PV_NONE, + #endif + {(char_u *)2000L, (char_u *)0L} SCRIPTID_INIT}, ++ {"regexpengine", "re", P_NUM|P_VI_DEF, ++ (char_u *)&p_re, PV_NONE, ++ {(char_u *)0L, (char_u *)0L} SCRIPTID_INIT}, + {"relativenumber", "rnu", P_BOOL|P_VI_DEF|P_RWIN, + (char_u *)VAR_WIN, PV_RNU, + {(char_u *)FALSE, (char_u *)0L} SCRIPTID_INIT}, +*************** +*** 8604,8609 **** +--- 8607,8617 ---- + errmsg = e_positive; + p_hi = 0; + } ++ if (p_re < 0 || p_re > 2) ++ { ++ errmsg = e_invarg; ++ p_re = 0; ++ } + if (p_report < 0) + { + errmsg = e_positive; +*** ../vim-7.3.969/src/option.h 2013-03-19 16:46:59.000000000 +0100 +--- src/option.h 2013-05-17 22:23:39.000000000 +0200 +*************** +*** 653,658 **** +--- 653,659 ---- + EXTERN long p_rdt; /* 'redrawtime' */ + #endif + EXTERN int p_remap; /* 'remap' */ ++ EXTERN long p_re; /* 'regexpengine' */ + EXTERN long p_report; /* 'report' */ + #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) + EXTERN long p_pvh; /* 'previewheight' */ +*** ../vim-7.3.969/src/testdir/test95.in 2013-05-19 19:10:10.000000000 +0200 +--- src/testdir/test95.in 2013-05-18 15:11:43.000000000 +0200 +*************** +*** 0 **** +--- 1,63 ---- ++ Test for regexp patterns with multi-byte support. ++ See test64 for the non-multi-byte tests. ++ ++ A pattern that gives the expected result produces OK, so that we know it was ++ actually tried. ++ ++ STARTTEST ++ :so small.vim ++ :so mbyte.vim ++ :" tl is a List of Lists with: ++ :" regexp pattern ++ :" text to test the pattern on ++ :" expected match (optional) ++ :" expected submatch 1 (optional) ++ :" expected submatch 2 (optional) ++ :" etc. ++ :" When there is no match use only the first two items. ++ :let tl = [] ++ ++ :"""" Multi-byte character tests. These will fail unless vim is compiled ++ :"""" with Multibyte (FEAT_MBYTE) or BIG/HUGE features. ++ :call add(tl, ['[[:alpha:][=a=]]\+', '879 aiaãâaiuvna ', 'aiaãâaiuvna']) ++ :call add(tl, ['[[=a=]]\+', 'ddaãâbcd', 'aãâ']) " equivalence classes ++ :call add(tl, ['[^ม ]\+', 'มม oijasoifjos ifjoisj f osij j มมมมม abcd', 'oijasoifjos']) ++ :call add(tl, [' [^ ]\+', 'start มabcdม ', ' มabcdม']) ++ :call add(tl, ['[ม[:alpha:][=a=]]\+', '879 aiaãมâมaiuvna ', 'aiaãมâมaiuvna']) ++ ++ :"""" Run the tests ++ ++ :" ++ :for t in tl ++ : let l = matchlist(t[1], t[0]) ++ :" check the match itself ++ : if len(l) == 0 && len(t) > 2 ++ : $put ='ERROR: pat: \"' . t[0] . '\", text: \"' . t[1] . '\", did not match, expected: \"' . t[2] . '\"' ++ : elseif len(l) > 0 && len(t) == 2 ++ : $put ='ERROR: pat: \"' . t[0] . '\", text: \"' . t[1] . '\", match: \"' . l[0] . '\", expected no match' ++ : elseif len(t) > 2 && l[0] != t[2] ++ : $put ='ERROR: pat: \"' . t[0] . '\", text: \"' . t[1] . '\", match: \"' . l[0] . '\", expected: \"' . t[2] . '\"' ++ : else ++ : $put ='OK - ' . t[0] ++ : endif ++ : if len(l) > 0 ++ :" check all the nine submatches ++ : for i in range(1, 9) ++ : if len(t) <= i + 2 ++ : let e = '' ++ : else ++ : let e = t[i + 2] ++ : endif ++ : if l[i] != e ++ : $put ='ERROR: pat: \"' . t[0] . '\", text: \"' . t[1] . '\", submatch ' . i . ': \"' . l[i] . '\", expected: \"' . e . '\"' ++ : endif ++ : endfor ++ : unlet i ++ : endif ++ :endfor ++ :unlet t tl e l ++ ++ :/\%#=1^Results/,$wq! test.out ++ ENDTEST ++ ++ Results of test95: +*** ../vim-7.3.969/src/testdir/test95.ok 2013-05-19 19:10:10.000000000 +0200 +--- src/testdir/test95.ok 2013-05-18 14:30:49.000000000 +0200 +*************** +*** 0 **** +--- 1,6 ---- ++ Results of test95: ++ OK - [[:alpha:][=a=]]\+ ++ OK - [[=a=]]\+ ++ OK - [^ม ]\+ ++ OK - [^ ]\+ ++ OK - [ม[:alpha:][=a=]]\+ +*** ../vim-7.3.969/src/testdir/Make_amiga.mak 2013-04-12 13:44:49.000000000 +0200 +--- src/testdir/Make_amiga.mak 2013-05-18 14:21:35.000000000 +0200 +*************** +*** 33,39 **** + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ + test89.out test90.out test91.out test92.out test93.out \ +! test94.out + + .SUFFIXES: .in .out + +--- 33,39 ---- + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ + test89.out test90.out test91.out test92.out test93.out \ +! test94.out test95.out + + .SUFFIXES: .in .out + +*************** +*** 144,146 **** +--- 144,147 ---- + test92.out: test92.in + test93.out: test93.in + test94.out: test94.in ++ test95.out: test95.in +*** ../vim-7.3.969/src/testdir/Make_dos.mak 2013-04-12 13:44:49.000000000 +0200 +--- src/testdir/Make_dos.mak 2013-05-18 14:21:47.000000000 +0200 +*************** +*** 32,38 **** + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ + test89.out test90.out test91.out test92.out test93.out \ +! test94.out + + SCRIPTS32 = test50.out test70.out + +--- 32,38 ---- + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ + test89.out test90.out test91.out test92.out test93.out \ +! test94.out test95.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.969/src/testdir/Make_ming.mak 2013-04-12 13:44:49.000000000 +0200 +--- src/testdir/Make_ming.mak 2013-05-18 14:21:56.000000000 +0200 +*************** +*** 52,58 **** + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ + test89.out test90.out test91.out test92.out test93.out \ +! test94.out + + SCRIPTS32 = test50.out test70.out + +--- 52,58 ---- + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ + test89.out test90.out test91.out test92.out test93.out \ +! test94.out test95.out + + SCRIPTS32 = test50.out test70.out + +*** ../vim-7.3.969/src/testdir/Make_os2.mak 2013-04-12 13:44:49.000000000 +0200 +--- src/testdir/Make_os2.mak 2013-05-18 14:22:00.000000000 +0200 +*************** +*** 33,39 **** + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ + test89.out test90.out test91.out test92.out test93.out \ +! test94.out + + .SUFFIXES: .in .out + +--- 33,39 ---- + test76.out test77.out test78.out test79.out test80.out \ + test81.out test82.out test83.out test84.out test88.out \ + test89.out test90.out test91.out test92.out test93.out \ +! test94.out test95.out + + .SUFFIXES: .in .out + +*** ../vim-7.3.969/src/testdir/Make_vms.mms 2013-04-12 13:44:49.000000000 +0200 +--- src/testdir/Make_vms.mms 2013-05-18 14:22:11.000000000 +0200 +*************** +*** 4,10 **** + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2013 Apr 12 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +--- 4,10 ---- + # Authors: Zoltan Arpadffy, + # Sandor Kopanyi, + # +! # Last change: 2013 May 18 + # + # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. + # Edit the lines in the Configuration section below to select. +*************** +*** 77,83 **** + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ + test82.out test83.out test84.out test88.out test89.out \ +! test90.out test91.out test92.out test93.out test94.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +--- 77,84 ---- + test71.out test72.out test74.out test75.out test76.out \ + test77.out test78.out test79.out test80.out test81.out \ + test82.out test83.out test84.out test88.out test89.out \ +! test90.out test91.out test92.out test93.out test94.out \ +! test95.out + + # Known problems: + # Test 30: a problem around mac format - unknown reason +*** ../vim-7.3.969/src/testdir/Makefile 2013-04-24 12:56:13.000000000 +0200 +--- src/testdir/Makefile 2013-05-18 14:22:50.000000000 +0200 +*************** +*** 29,35 **** + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ + test89.out test90.out test91.out test92.out test93.out \ +! test94.out + + SCRIPTS_GUI = test16.out + +--- 29,35 ---- + test79.out test80.out test81.out test82.out test83.out \ + test84.out test85.out test86.out test87.out test88.out \ + test89.out test90.out test91.out test92.out test93.out \ +! test94.out test95.out + + SCRIPTS_GUI = test16.out + +*************** +*** 85,97 **** + fi" + + # Check if the test.out file matches test.ok. +! @/bin/sh -c "if test -f test.out; then\ + if diff test.out $*.ok; \ + then mv -f test.out $*.out; \ + else echo $* FAILED >>test.log; mv -f test.out $*.failed; \ + fi \ + else echo $* NO OUTPUT >>test.log; \ + fi" + -rm -rf X* test.ok viminfo + + test49.out: test49.vim +--- 85,100 ---- + fi" + + # Check if the test.out file matches test.ok. +! @/bin/sh -c "if test -f test.out; then \ + if diff test.out $*.ok; \ + then mv -f test.out $*.out; \ + else echo $* FAILED >>test.log; mv -f test.out $*.failed; \ + fi \ + else echo $* NO OUTPUT >>test.log; \ + fi" ++ @/bin/sh -c "if test -f valgrind; then\ ++ mv -f valgrind valgrind.$*; \ ++ fi" + -rm -rf X* test.ok viminfo + + test49.out: test49.vim +*** ../vim-7.3.969/src/version.c 2013-05-18 20:55:31.000000000 +0200 +--- src/version.c 2013-05-19 19:10:25.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 970, + /**/ + +-- +BRIDGEKEEPER: What is the air-speed velocity of an unladen swallow? +ARTHUR: What do you mean? An African or European swallow? +BRIDGEKEEPER: Er ... I don't know that ... Aaaaarrrrrrggghhh! + BRIDGEKEEPER is cast into the gorge. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2d6d8b3eb33d901ba67f93d13cf286ac6f8407b3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:44 +0200 Subject: [PATCH 0870/3340] - patchlevel 971 --- 7.3.971 | 135 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 135 insertions(+) create mode 100644 7.3.971 diff --git a/7.3.971 b/7.3.971 new file mode 100644 index 00000000..9cf92cd6 --- /dev/null +++ b/7.3.971 @@ -0,0 +1,135 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.971 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.971 +Problem: No support for VS2012 static code analysis. +Solution: Add the ANALYZE option. (Mike Williams) +Files: src/Make_mvc.mak + + +*** ../vim-7.3.970/src/Make_mvc.mak 2013-05-19 19:16:25.000000000 +0200 +--- src/Make_mvc.mak 2013-05-19 16:38:29.000000000 +0200 +*************** +*** 20,26 **** + # + # !!!! After changing features do "nmake clean" first !!!! + # +! # Feature Set: FEATURES=[TINY, SMALL, NORMAL, BIG, HUGE] (default is BIG) + # + # GUI interface: GUI=yes (default is no) + # +--- 20,26 ---- + # + # !!!! After changing features do "nmake clean" first !!!! + # +! # Feature Set: FEATURES=[TINY, SMALL, NORMAL, BIG, HUGE] (default is BIG) + # + # GUI interface: GUI=yes (default is no) + # +*************** +*** 87,106 **** + # GETTEXT=[yes or no] (default is yes) + # See http://sourceforge.net/projects/gettext/ + # +! # PostScript printing: POSTSCRIPT=yes (default is no) + # +! # Netbeans Support: NETBEANS=[yes or no] (default is yes if GUI is yes) + # +! # XPM Image Support: XPM=[path to XPM directory] +! # Default is "xpm", using the files included in the distribution. +! # Use "no" to disable this feature. + # +! # Optimization: OPTIMIZE=[SPACE, SPEED, MAXSPEED] (default is MAXSPEED) + # +! # Processor Version: CPUNR=[i386, i486, i586, i686, pentium4] (default is +! # i386) + # +! # Version Support: WINVER=[0x0400, 0x0500] (default is 0x0400) + # + # Debug version: DEBUG=yes + # Mapfile: MAP=[no, yes or lines] (default is yes) +--- 87,106 ---- + # GETTEXT=[yes or no] (default is yes) + # See http://sourceforge.net/projects/gettext/ + # +! # PostScript printing: POSTSCRIPT=yes (default is no) + # +! # Netbeans Support: NETBEANS=[yes or no] (default is yes if GUI is yes) + # +! # XPM Image Support: XPM=[path to XPM directory] +! # Default is "xpm", using the files included in the distribution. +! # Use "no" to disable this feature. + # +! # Optimization: OPTIMIZE=[SPACE, SPEED, MAXSPEED] (default is MAXSPEED) + # +! # Processor Version: CPUNR=[i386, i486, i586, i686, pentium4] (default is +! # i386) + # +! # Version Support: WINVER=[0x0400, 0x0500] (default is 0x0400) + # + # Debug version: DEBUG=yes + # Mapfile: MAP=[no, yes or lines] (default is yes) +*************** +*** 108,117 **** + # yes: Write a normal mapfile. + # lines: Write a mapfile with line numbers (only for VC6 and later) + # +! # Netbeans Debugging Support: NBDEBUG=[yes or no] (should be no, yes +! # doesn't work) + # +! # Visual C Version: MSVCVER=m.n (default derived from nmake if undefined) + # + # You can combine any of these interfaces + # +--- 108,119 ---- + # yes: Write a normal mapfile. + # lines: Write a mapfile with line numbers (only for VC6 and later) + # +! # Netbeans Debugging Support: NBDEBUG=[yes or no] (should be no, yes +! # doesn't work) + # +! # Visual C Version: MSVCVER=m.n (default derived from nmake if undefined) +! # +! # Static Code Analysis: ANALYZE=yes (works with VS2012 only) + # + # You can combine any of these interfaces + # +*************** +*** 479,484 **** +--- 481,491 ---- + CFLAGS=$(CFLAGS) $(WP64CHECK) + !endif + ++ # Static code analysis generally available starting with VS2012 ++ !if ("$(ANALYZE)" == "yes") && ("$(MSVCVER)" == "11.0") ++ CFLAGS=$(CFLAGS) /analyze ++ !endif ++ + CFLAGS = $(CFLAGS) $(OPTFLAG) -DNDEBUG $(CPUARG) + RCFLAGS = $(rcflags) $(rcvars) -DNDEBUG + ! ifdef USE_MSVCRT +*** ../vim-7.3.970/src/version.c 2013-05-19 19:16:25.000000000 +0200 +--- src/version.c 2013-05-19 21:03:34.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 971, + /**/ + + +-- +It is illegal for a driver to be blindfolded while operating a vehicle. + [real standing law in Alabama, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7d1ef0678be60c7e603b459b1d91199eb3e10797 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:44 +0200 Subject: [PATCH 0871/3340] - patchlevel 972 --- 7.3.972 | 99 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 99 insertions(+) create mode 100644 7.3.972 diff --git a/7.3.972 b/7.3.972 new file mode 100644 index 00000000..725f23b5 --- /dev/null +++ b/7.3.972 @@ -0,0 +1,99 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.972 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.972 +Problem: Cursor not restored after InsertEnter autocommand if it moved to + another line. +Solution: Also restore if the saved line number is still valid. Allow + setting v:char to skip restoring. +Files: src/edit.c, runtime/doc/autocmd.txt + + +*** ../vim-7.3.971/src/edit.c 2013-05-06 04:21:35.000000000 +0200 +--- src/edit.c 2013-05-19 21:09:37.000000000 +0200 +*************** +*** 382,394 **** + else + ptr = (char_u *)"i"; + set_vim_var_string(VV_INSERTMODE, ptr, 1); + # endif + apply_autocmds(EVENT_INSERTENTER, NULL, NULL, FALSE, curbuf); + +! /* Since Insert mode was not started yet a call to check_cursor_col() +! * may have moved the cursor, especially with the "A" command. */ +! if (curwin->w_cursor.col != save_cursor.col +! && curwin->w_cursor.lnum == save_cursor.lnum) + { + int save_state = State; + +--- 382,402 ---- + else + ptr = (char_u *)"i"; + set_vim_var_string(VV_INSERTMODE, ptr, 1); ++ set_vim_var_string(VV_CHAR, NULL, -1); /* clear v:char */ + # endif + apply_autocmds(EVENT_INSERTENTER, NULL, NULL, FALSE, curbuf); + +! /* Make sure the cursor didn't move. Do call check_cursor_col() in +! * case the text was modified. Since Insert mode was not started yet +! * a call to check_cursor_col() may move the cursor, especially with +! * the "A" command, thus set State to avoid that. Also check that the +! * line number is still valid (lines may have been deleted). +! * Do not restore if v:char was set to a non-empty string. */ +! if (!equalpos(curwin->w_cursor, save_cursor) +! # ifdef FEAT_EVAL +! && *get_vim_var_str(VV_CHAR) == NUL +! # endif +! && save_cursor.lnum <= curbuf->b_ml.ml_line_count) + { + int save_state = State; + +*** ../vim-7.3.971/runtime/doc/autocmd.txt 2013-03-19 13:33:18.000000000 +0100 +--- runtime/doc/autocmd.txt 2013-05-19 21:05:59.000000000 +0200 +*************** +*** 674,681 **** + InsertEnter Just before starting Insert mode. Also for + Replace mode and Virtual Replace mode. The + |v:insertmode| variable indicates the mode. +! Be careful not to move the cursor or do +! anything else that the user does not expect. + *InsertLeave* + InsertLeave When leaving Insert mode. Also when using + CTRL-O |i_CTRL-O|. But not for |i_CTRL-C|. +--- 691,701 ---- + InsertEnter Just before starting Insert mode. Also for + Replace mode and Virtual Replace mode. The + |v:insertmode| variable indicates the mode. +! Be careful not to do anything else that the +! user does not expect. +! The cursor is restored afterwards. If you do +! not want that set |v:char| to a non-empty +! string. + *InsertLeave* + InsertLeave When leaving Insert mode. Also when using + CTRL-O |i_CTRL-O|. But not for |i_CTRL-C|. +*** ../vim-7.3.971/src/version.c 2013-05-19 21:03:50.000000000 +0200 +--- src/version.c 2013-05-19 21:13:10.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 972, + /**/ + +-- +It is illegal for anyone to try and stop a child from playfully jumping over +puddles of water. + [real standing law in California, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6bc15738b4bac3b7217181974e24514e4356270b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:45 +0200 Subject: [PATCH 0872/3340] - patchlevel 973 --- 7.3.973 | 137 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 137 insertions(+) create mode 100644 7.3.973 diff --git a/7.3.973 b/7.3.973 new file mode 100644 index 00000000..6a4ac109 --- /dev/null +++ b/7.3.973 @@ -0,0 +1,137 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.973 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.973 +Problem: Compiler warnings. Crash on startup. (Tony Mechelynck) +Solution: Change EMSG2 to EMSGN. Make array one character longer. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.972/src/regexp_nfa.c 2013-05-19 19:16:25.000000000 +0200 +--- src/regexp_nfa.c 2013-05-19 21:56:31.000000000 +0200 +*************** +*** 273,279 **** + NFA_HEAD, NFA_NHEAD, NFA_ALPHA, NFA_NALPHA, + NFA_LOWER, NFA_NLOWER, NFA_UPPER, NFA_NUPPER + }; +! char_u myconfig[9]; + char_u config[NCONFIGS][9] = { + "000000100", /* digit */ + "100000100", /* non digit */ +--- 273,279 ---- + NFA_HEAD, NFA_NHEAD, NFA_ALPHA, NFA_NALPHA, + NFA_LOWER, NFA_NLOWER, NFA_UPPER, NFA_NUPPER + }; +! char_u myconfig[10]; + char_u config[NCONFIGS][9] = { + "000000100", /* digit */ + "100000100", /* non digit */ +*************** +*** 400,406 **** + } + /* try to recognize character classes */ + for (i = 0; i < NCONFIGS; i++) +! if (STRNCMP(myconfig, config[i],8) == 0) + return classid[i] + extra_newl; + + /* fallthrough => no success so far */ +--- 400,406 ---- + } + /* try to recognize character classes */ + for (i = 0; i < NCONFIGS; i++) +! if (STRNCMP(myconfig, config[i], 8) == 0) + return classid[i] + extra_newl; + + /* fallthrough => no success so far */ +*************** +*** 759,765 **** + case Magic('&'): + case Magic(')'): + syntax_error = TRUE; +! EMSG2(_(e_misplaced), no_Magic(c)); + return FAIL; + + case Magic('='): +--- 759,765 ---- + case Magic('&'): + case Magic(')'): + syntax_error = TRUE; +! EMSGN(_(e_misplaced), no_Magic(c)); + return FAIL; + + case Magic('='): +*************** +*** 770,776 **** + case Magic('{'): + /* these should follow an atom, not form an atom */ + syntax_error = TRUE; +! EMSG2(_(e_misplaced), no_Magic(c)); + return FAIL; + + case Magic('~'): /* previous substitute pattern */ +--- 770,776 ---- + case Magic('{'): + /* these should follow an atom, not form an atom */ + syntax_error = TRUE; +! EMSGN(_(e_misplaced), no_Magic(c)); + return FAIL; + + case Magic('~'): /* previous substitute pattern */ +*************** +*** 816,822 **** + return FAIL; + default: + syntax_error = TRUE; +! EMSG2(_("E867: (NFA) Unknown operator '\\z%c'"), + no_Magic(c)); + return FAIL; + } +--- 816,822 ---- + return FAIL; + default: + syntax_error = TRUE; +! EMSGN(_("E867: (NFA) Unknown operator '\\z%c'"), + no_Magic(c)); + return FAIL; + } +*************** +*** 1363,1369 **** + return FAIL; + default: + syntax_error = TRUE; +! EMSG2(_("E869: (NFA) Unknown operator '\\@%c'"), op); + return FAIL; + } + break; +--- 1363,1369 ---- + return FAIL; + default: + syntax_error = TRUE; +! EMSGN(_("E869: (NFA) Unknown operator '\\@%c'"), op); + return FAIL; + } + break; +*** ../vim-7.3.972/src/version.c 2013-05-19 21:15:08.000000000 +0200 +--- src/version.c 2013-05-19 22:29:03.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 973, + /**/ + +-- +Sometimes I think the surest sign that intelligent life exists elsewhere +in the universe is that none of it has tried to contact us. (Calvin) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bac898effdeeb40213a8b3ef1af251c0b40284fb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:46 +0200 Subject: [PATCH 0873/3340] - patchlevel 974 --- 7.3.974 | 158 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 158 insertions(+) create mode 100644 7.3.974 diff --git a/7.3.974 b/7.3.974 new file mode 100644 index 00000000..97f7e528 --- /dev/null +++ b/7.3.974 @@ -0,0 +1,158 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.974 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.974 +Problem: Can't build with ruby 1.8.5. +Solution: Only use ruby_init_stack() when RUBY_INIT_STACK is defined. + (Yukihiro Nakadaira) +Files: src/if_ruby.c + + +*** ../vim-7.3.973/src/if_ruby.c 2013-05-12 14:10:41.000000000 +0200 +--- src/if_ruby.c 2013-05-20 12:47:48.000000000 +0200 +*************** +*** 158,165 **** + static void ruby_io_init(void); + static void ruby_vim_init(void); + +! #if defined(__ia64) && !defined(ruby_init_stack) +! # define ruby_init_stack(addr) ruby_init_stack((addr), rb_ia64_bsp()) + #endif + + #if defined(DYNAMIC_RUBY) || defined(PROTO) +--- 158,167 ---- + static void ruby_io_init(void); + static void ruby_vim_init(void); + +! #if defined(RUBY19_OR_LATER) || defined(RUBY_INIT_STACK) +! # if defined(__ia64) && !defined(ruby_init_stack) +! # define ruby_init_stack(addr) ruby_init_stack((addr), rb_ia64_bsp()) +! # endif + #endif + + #if defined(DYNAMIC_RUBY) || defined(PROTO) +*************** +*** 231,242 **** + # define rb_float_new dll_rb_float_new + # define rb_ary_new dll_rb_ary_new + # define rb_ary_push dll_rb_ary_push +! # ifdef __ia64 +! # define rb_ia64_bsp dll_rb_ia64_bsp +! # undef ruby_init_stack +! # define ruby_init_stack(addr) dll_ruby_init_stack((addr), rb_ia64_bsp()) +! # else +! # define ruby_init_stack dll_ruby_init_stack + # endif + # else + # define rb_str2cstr dll_rb_str2cstr +--- 233,246 ---- + # define rb_float_new dll_rb_float_new + # define rb_ary_new dll_rb_ary_new + # define rb_ary_push dll_rb_ary_push +! # if defined(RUBY19_OR_LATER) || defined(RUBY_INIT_STACK) +! # ifdef __ia64 +! # define rb_ia64_bsp dll_rb_ia64_bsp +! # undef ruby_init_stack +! # define ruby_init_stack(addr) dll_ruby_init_stack((addr), rb_ia64_bsp()) +! # else +! # define ruby_init_stack dll_ruby_init_stack +! # endif + # endif + # else + # define rb_str2cstr dll_rb_str2cstr +*************** +*** 346,356 **** + static VALUE (*dll_rb_float_new) (double); + static VALUE (*dll_rb_ary_new) (void); + static VALUE (*dll_rb_ary_push) (VALUE, VALUE); +! # ifdef __ia64 + static void * (*dll_rb_ia64_bsp) (void); + static void (*dll_ruby_init_stack)(VALUE*, void*); +! # else + static void (*dll_ruby_init_stack)(VALUE*); + # endif + # endif + # ifdef RUBY19_OR_LATER +--- 350,362 ---- + static VALUE (*dll_rb_float_new) (double); + static VALUE (*dll_rb_ary_new) (void); + static VALUE (*dll_rb_ary_push) (VALUE, VALUE); +! # if defined(RUBY19_OR_LATER) || defined(RUBY_INIT_STACK) +! # ifdef __ia64 + static void * (*dll_rb_ia64_bsp) (void); + static void (*dll_ruby_init_stack)(VALUE*, void*); +! # else + static void (*dll_ruby_init_stack)(VALUE*); ++ # endif + # endif + # endif + # ifdef RUBY19_OR_LATER +*************** +*** 491,500 **** + # endif + # if defined(DYNAMIC_RUBY_VER) && DYNAMIC_RUBY_VER >= 18 + {"rb_string_value_ptr", (RUBY_PROC*)&dll_rb_string_value_ptr}, +- # ifdef __ia64 +- {"rb_ia64_bsp", (RUBY_PROC*)&dll_rb_ia64_bsp}, +- # endif +- {"ruby_init_stack", (RUBY_PROC*)&dll_ruby_init_stack}, + # if DYNAMIC_RUBY_VER <= 19 + {"rb_float_new", (RUBY_PROC*)&dll_rb_float_new}, + # else +--- 497,502 ---- +*************** +*** 513,518 **** +--- 515,526 ---- + {"rb_require", (RUBY_PROC*)&dll_rb_require}, + {"ruby_process_options", (RUBY_PROC*)&dll_ruby_process_options}, + # endif ++ # if defined(RUBY19_OR_LATER) || defined(RUBY_INIT_STACK) ++ # ifdef __ia64 ++ {"rb_ia64_bsp", (RUBY_PROC*)&dll_rb_ia64_bsp}, ++ # endif ++ {"ruby_init_stack", (RUBY_PROC*)&dll_ruby_init_stack}, ++ # endif + {"", NULL}, + }; + +*************** +*** 735,741 **** + NtInitialize(&argc, &argv); + #endif + { +! #if defined(RUBY_VERSION) && RUBY_VERSION >= 18 + ruby_init_stack(ruby_stack_start); + #endif + ruby_init(); +--- 743,749 ---- + NtInitialize(&argc, &argv); + #endif + { +! #if defined(RUBY19_OR_LATER) || defined(RUBY_INIT_STACK) + ruby_init_stack(ruby_stack_start); + #endif + ruby_init(); +*** ../vim-7.3.973/src/version.c 2013-05-19 22:31:13.000000000 +0200 +--- src/version.c 2013-05-20 12:51:22.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 974, + /**/ + +-- +bashian roulette: +$ ((RANDOM%6)) || rm -rf ~ + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4d5cfa3e44d6166851d29051bce7447f29eaaa4f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:46 +0200 Subject: [PATCH 0874/3340] - patchlevel 975 --- 7.3.975 | 70 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 7.3.975 diff --git a/7.3.975 b/7.3.975 new file mode 100644 index 00000000..d4b97ac7 --- /dev/null +++ b/7.3.975 @@ -0,0 +1,70 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.975 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.975 +Problem: Crash in regexp parsing. +Solution: Correctly compute the end of allocated memory. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.974/src/regexp_nfa.c 2013-05-19 22:31:13.000000000 +0200 +--- src/regexp_nfa.c 2013-05-20 13:43:37.000000000 +0200 +*************** +*** 231,244 **** + /* A reasonable estimation for size */ + nstate_max = (STRLEN(expr) + 1) * NFA_POSTFIX_MULTIPLIER; + +! /* Size for postfix representation of expr */ + postfix_size = sizeof(*post_start) * nstate_max; + post_start = (int *)lalloc(postfix_size, TRUE); + if (post_start == NULL) + return FAIL; + vim_memset(post_start, 0, postfix_size); + post_ptr = post_start; +! post_end = post_start + postfix_size; + nfa_has_zend = FALSE; + + regcomp_start(expr, re_flags); +--- 231,249 ---- + /* A reasonable estimation for size */ + nstate_max = (STRLEN(expr) + 1) * NFA_POSTFIX_MULTIPLIER; + +! /* Some items blow up in size, such as [A-z]. Add more space for that. +! * TODO: some patterns may still fail. */ +! // nstate_max += 1000; +! +! /* Size for postfix representation of expr. */ + postfix_size = sizeof(*post_start) * nstate_max; ++ + post_start = (int *)lalloc(postfix_size, TRUE); + if (post_start == NULL) + return FAIL; + vim_memset(post_start, 0, postfix_size); + post_ptr = post_start; +! post_end = post_start + nstate_max; + nfa_has_zend = FALSE; + + regcomp_start(expr, re_flags); +*** ../vim-7.3.974/src/version.c 2013-05-20 12:52:23.000000000 +0200 +--- src/version.c 2013-05-20 13:42:10.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 975, + /**/ + +-- +My Go, this amn keyboar oesn't have a . + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6d34bf48e6bcbcf335b9fbbdb0a784b52e9bf9d4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:47 +0200 Subject: [PATCH 0875/3340] - patchlevel 976 --- 7.3.976 | 87 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 87 insertions(+) create mode 100644 7.3.976 diff --git a/7.3.976 b/7.3.976 new file mode 100644 index 00000000..1012e739 --- /dev/null +++ b/7.3.976 @@ -0,0 +1,87 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.976 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.976 +Problem: Can't build on HP-UX. +Solution: Remove modern initialization. (John Marriott) +Files: src/regexp_nfa.c + + +*** ../vim-7.3.975/src/regexp_nfa.c 2013-05-20 13:44:24.000000000 +0200 +--- src/regexp_nfa.c 2013-05-20 13:51:07.000000000 +0200 +*************** +*** 1961,1974 **** + static Frag_T st_pop __ARGS((Frag_T **p, Frag_T *stack)); + + /* +! * Initialize Frag_T struct. + */ + static Frag_T + frag(start, out) + nfa_state_T *start; + Ptrlist *out; + { +! Frag_T n = { start, out }; + return n; + } + +--- 1961,1977 ---- + static Frag_T st_pop __ARGS((Frag_T **p, Frag_T *stack)); + + /* +! * Initialize a Frag_T struct and return it. + */ + static Frag_T + frag(start, out) + nfa_state_T *start; + Ptrlist *out; + { +! Frag_T n; +! +! n.start = start; +! n.out = out; + return n; + } + +*************** +*** 2144,2150 **** + if (postfix == NULL) + return NULL; + +! #define PUSH(s) st_push ((s), &stackp, stack_end) + #define POP() st_pop(&stackp, stack); \ + if (stackp < stack) \ + { \ +--- 2147,2153 ---- + if (postfix == NULL) + return NULL; + +! #define PUSH(s) st_push((s), &stackp, stack_end) + #define POP() st_pop(&stackp, stack); \ + if (stackp < stack) \ + { \ +*** ../vim-7.3.975/src/version.c 2013-05-20 13:44:24.000000000 +0200 +--- src/version.c 2013-05-20 13:54:56.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 976, + /**/ + +-- +Dogs must have a permit signed by the mayor in order to congregate in groups +of three or more on private property. + [real standing law in Oklahoma, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 60686d43b7f49330bc5ce62e2bcd80ce94ef4877 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:48 +0200 Subject: [PATCH 0876/3340] - patchlevel 977 --- 7.3.977 | 294 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 294 insertions(+) create mode 100644 7.3.977 diff --git a/7.3.977 b/7.3.977 new file mode 100644 index 00000000..d6a30972 --- /dev/null +++ b/7.3.977 @@ -0,0 +1,294 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.977 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.977 +Problem: Compiler warnings on 64 bit Windows. +Solution: Add type casts. (Mike Williams) Also fix some white space and + uncomment what was commented-out for testing. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.976/src/regexp_nfa.c 2013-05-20 13:55:17.000000000 +0200 +--- src/regexp_nfa.c 2013-05-20 14:24:44.000000000 +0200 +*************** +*** 224,239 **** + char_u *expr; + int re_flags; /* see vim_regcomp() */ + { +! int postfix_size; + + nstate = 0; + istate = 0; + /* A reasonable estimation for size */ +! nstate_max = (STRLEN(expr) + 1) * NFA_POSTFIX_MULTIPLIER; + + /* Some items blow up in size, such as [A-z]. Add more space for that. + * TODO: some patterns may still fail. */ +! // nstate_max += 1000; + + /* Size for postfix representation of expr. */ + postfix_size = sizeof(*post_start) * nstate_max; +--- 224,239 ---- + char_u *expr; + int re_flags; /* see vim_regcomp() */ + { +! size_t postfix_size; + + nstate = 0; + istate = 0; + /* A reasonable estimation for size */ +! nstate_max = (int)(STRLEN(expr) + 1) * NFA_POSTFIX_MULTIPLIER; + + /* Some items blow up in size, such as [A-z]. Add more space for that. + * TODO: some patterns may still fail. */ +! nstate_max += 1000; + + /* Size for postfix representation of expr. */ + postfix_size = sizeof(*post_start) * nstate_max; +*************** +*** 2177,2183 **** + * No new state added here. */ + if (nfa_calc_size == TRUE) + { +! nstate += 0; + break; + } + e2 = POP(); +--- 2177,2183 ---- + * No new state added here. */ + if (nfa_calc_size == TRUE) + { +! /* nstate += 0; */ + break; + } + e2 = POP(); +*************** +*** 2190,2196 **** + /* Negation of a character */ + if (nfa_calc_size == TRUE) + { +! nstate += 0; + break; + } + e1 = POP(); +--- 2190,2196 ---- + /* Negation of a character */ + if (nfa_calc_size == TRUE) + { +! /* nstate += 0; */ + break; + } + e1 = POP(); +*************** +*** 2204,2210 **** + /* Alternation */ + if (nfa_calc_size == TRUE) + { +! nstate ++; + break; + } + e2 = POP(); +--- 2204,2210 ---- + /* Alternation */ + if (nfa_calc_size == TRUE) + { +! nstate++; + break; + } + e2 = POP(); +*************** +*** 2219,2225 **** + /* Zero or more */ + if (nfa_calc_size == TRUE) + { +! nstate ++; + break; + } + e = POP(); +--- 2219,2225 ---- + /* Zero or more */ + if (nfa_calc_size == TRUE) + { +! nstate++; + break; + } + e = POP(); +*************** +*** 2234,2240 **** + /* one or zero atoms=> greedy match */ + if (nfa_calc_size == TRUE) + { +! nstate ++; + break; + } + e = POP(); +--- 2234,2240 ---- + /* one or zero atoms=> greedy match */ + if (nfa_calc_size == TRUE) + { +! nstate++; + break; + } + e = POP(); +*************** +*** 2248,2254 **** + /* zero or one atoms => non-greedy match */ + if (nfa_calc_size == TRUE) + { +! nstate ++; + break; + } + e = POP(); +--- 2248,2254 ---- + /* zero or one atoms => non-greedy match */ + if (nfa_calc_size == TRUE) + { +! nstate++; + break; + } + e = POP(); +*************** +*** 2262,2268 **** + /* One or more */ + if (nfa_calc_size == TRUE) + { +! nstate ++; + break; + } + e = POP(); +--- 2262,2268 ---- + /* One or more */ + if (nfa_calc_size == TRUE) + { +! nstate++; + break; + } + e = POP(); +*************** +*** 2278,2284 **** + * with max/min count of 0 */ + if (nfa_calc_size == TRUE) + { +! nstate ++; + break; + } + s = new_state(NFA_SKIP_CHAR, NULL, NULL); +--- 2278,2284 ---- + * with max/min count of 0 */ + if (nfa_calc_size == TRUE) + { +! nstate++; + break; + } + s = new_state(NFA_SKIP_CHAR, NULL, NULL); +*************** +*** 2392,2398 **** + /* Operands */ + if (nfa_calc_size == TRUE) + { +! nstate ++; + break; + } + s = new_state(*p, NULL, NULL); +--- 2392,2398 ---- + /* Operands */ + if (nfa_calc_size == TRUE) + { +! nstate++; + break; + } + s = new_state(*p, NULL, NULL); +*************** +*** 2407,2413 **** + + if (nfa_calc_size == TRUE) + { +! nstate ++; + return NULL; /* Return value when counting size is ignored anyway */ + } + +--- 2407,2413 ---- + + if (nfa_calc_size == TRUE) + { +! nstate++; + return NULL; /* Return value when counting size is ignored anyway */ + } + +*************** +*** 2583,2589 **** + save.startpos[subidx] = m->startpos[subidx]; + save.endpos[subidx] = m->endpos[subidx]; + m->startpos[subidx].lnum = reglnum; +! m->startpos[subidx].col = reginput - regline + off; + } + else + { +--- 2583,2589 ---- + save.startpos[subidx] = m->startpos[subidx]; + save.endpos[subidx] = m->endpos[subidx]; + m->startpos[subidx].lnum = reglnum; +! m->startpos[subidx].col = (colnr_T)(reginput - regline + off); + } + else + { +*************** +*** 2631,2637 **** + save.startpos[subidx] = m->startpos[subidx]; + save.endpos[subidx] = m->endpos[subidx]; + m->endpos[subidx].lnum = reglnum; +! m->endpos[subidx].col = reginput - regline + off; + } + else + { +--- 2631,2637 ---- + save.startpos[subidx] = m->startpos[subidx]; + save.endpos[subidx] = m->endpos[subidx]; + m->endpos[subidx].lnum = reglnum; +! m->endpos[subidx].col = (colnr_T)(reginput - regline + off); + } + else + { +*************** +*** 3620,3626 **** + int re_flags; + { + nfa_regprog_T *prog; +! int prog_size; + int *postfix; + + if (expr == NULL) +--- 3620,3626 ---- + int re_flags; + { + nfa_regprog_T *prog; +! size_t prog_size; + int *postfix; + + if (expr == NULL) +*** ../vim-7.3.976/src/version.c 2013-05-20 13:55:17.000000000 +0200 +--- src/version.c 2013-05-20 21:24:28.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 977, + /**/ + +-- +A law to reduce crime states: "It is mandatory for a motorist with criminal +intentions to stop at the city limits and telephone the chief of police as he +is entering the town. + [real standing law in Washington, United States of America] + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bec2cd2e71b25d223f392be8f0249b64ddf0c98c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:48 +0200 Subject: [PATCH 0877/3340] - patchlevel 978 --- 7.3.978 | 180 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 180 insertions(+) create mode 100644 7.3.978 diff --git a/7.3.978 b/7.3.978 new file mode 100644 index 00000000..168596d0 --- /dev/null +++ b/7.3.978 @@ -0,0 +1,180 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.978 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.978 +Problem: Regexp debug logs don't have a good name. +Solution: Use clear names and make it possible to write logs for the old and + new engines separately. (Taro Muraoka) +Files: src/regexp.c, src/regexp_nfa.c + + +*** ../vim-7.3.977/src/regexp.c 2013-05-19 19:16:25.000000000 +0200 +--- src/regexp.c 2013-05-20 21:41:19.000000000 +0200 +*************** +*** 51,56 **** +--- 51,58 ---- + # define BT_REGEXP_DUMP + /* save the debugging data to a file instead of displaying it */ + # define BT_REGEXP_LOG ++ # define BT_REGEXP_DEBUG_LOG ++ # define BT_REGEXP_DEBUG_LOG_NAME "bt_regexp_debug.log" + #endif + + /* +*************** +*** 7828,7838 **** + + if (prog == NULL) /* error compiling regexp with initial engine */ + { +! #ifdef DEBUG + if (regexp_engine != BACKTRACKING_ENGINE) /* debugging log for NFA */ + { + FILE *f; +! f = fopen("debug.log", "a"); + if (f) + { + if (!syntax_error) +--- 7830,7840 ---- + + if (prog == NULL) /* error compiling regexp with initial engine */ + { +! #ifdef BT_REGEXP_DEBUG_LOG + if (regexp_engine != BACKTRACKING_ENGINE) /* debugging log for NFA */ + { + FILE *f; +! f = fopen(BT_REGEXP_DEBUG_LOG_NAME, "a"); + if (f) + { + if (!syntax_error) +*************** +*** 7842,7848 **** + fclose(f); + } + else +! EMSG("(NFA) Could not open \"debug.log\" to write !!!"); + /* + if (syntax_error) + EMSG("NFA Regexp: Syntax Error !"); +--- 7844,7851 ---- + fclose(f); + } + else +! EMSG2("(NFA) Could not open \"%s\" to write !!!", +! BT_REGEXP_DEBUG_LOG_NAME); + /* + if (syntax_error) + EMSG("NFA Regexp: Syntax Error !"); +*** ../vim-7.3.977/src/regexp_nfa.c 2013-05-20 21:26:26.000000000 +0200 +--- src/regexp_nfa.c 2013-05-20 21:41:19.000000000 +0200 +*************** +*** 9,14 **** +--- 9,16 ---- + /* Comment this out to disable log files. They can get pretty big */ + # define ENABLE_LOG + # define LOG_NAME "log_nfarun.log" ++ # define NFA_REGEXP_DEBUG_LOG ++ # define NFA_REGEXP_DEBUG_LOG_NAME "nfa_regexp_debug.log" + #endif + + /* Upper limit allowed for {m,n} repetitions handled by NFA */ +*************** +*** 2849,2860 **** + int *listids = NULL; + int j = 0; + int len = 0; +! #ifdef DEBUG +! FILE *debug = fopen("list.log", "a"); + + if (debug == NULL) + { +! EMSG(_("(NFA) COULD NOT OPEN list.log !")); + return FALSE; + } + #endif +--- 2851,2862 ---- + int *listids = NULL; + int j = 0; + int len = 0; +! #ifdef NFA_REGEXP_DEBUG_LOG +! FILE *debug = fopen(NFA_REGEXP_DEBUG_LOG_NAME, "a"); + + if (debug == NULL) + { +! EMSG2(_("(NFA) COULD NOT OPEN %s !"), NFA_REGEXP_DEBUG_LOG_NAME); + return FALSE; + } + #endif +*************** +*** 2950,2956 **** + fprintf(log_fd, "\n"); + #endif + +! #ifdef DEBUG + fprintf(debug, "\n-------------------\n"); + #endif + +--- 2952,2958 ---- + fprintf(log_fd, "\n"); + #endif + +! #ifdef NFA_REGEXP_DEBUG_LOG + fprintf(debug, "\n-------------------\n"); + #endif + +*************** +*** 2966,2972 **** + else + t = &thislist->t[i]; + +! #ifdef DEBUG + nfa_set_code(t->state->c); + fprintf(debug, "%s, ", code); + #endif +--- 2968,2974 ---- + else + t = &thislist->t[i]; + +! #ifdef NFA_REGEXP_DEBUG_LOG + nfa_set_code(t->state->c); + fprintf(debug, "%s, ", code); + #endif +*************** +*** 3436,3442 **** + if (listids != NULL) + vim_free(listids); + #undef ADD_POS_NEG_STATE +! #ifdef DEBUG + fclose(debug); + #endif + +--- 3438,3444 ---- + if (listids != NULL) + vim_free(listids); + #undef ADD_POS_NEG_STATE +! #ifdef NFA_REGEXP_DEBUG_LOG + fclose(debug); + #endif + +*** ../vim-7.3.977/src/version.c 2013-05-20 21:26:26.000000000 +0200 +--- src/version.c 2013-05-20 21:48:27.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 978, + /**/ + +-- +SIGIRO -- irony detected (iron core dumped) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From eb8b7a5e91a2ca096aa1f1b71533fc90b07e59e0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:49 +0200 Subject: [PATCH 0878/3340] - patchlevel 979 --- 7.3.979 | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.979 diff --git a/7.3.979 b/7.3.979 new file mode 100644 index 00000000..e7ca5ded --- /dev/null +++ b/7.3.979 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.979 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.979 +Problem: Complex NFA regexp doesn't work. +Solution: Set actual state stack end instead of using an arbitrary number. + (Yasuhiro Matsumoto) +Files: src/regexp_nfa.c + + +*** ../vim-7.3.978/src/regexp_nfa.c 2013-05-20 21:49:08.000000000 +0200 +--- src/regexp_nfa.c 2013-05-20 21:53:24.000000000 +0200 +*************** +*** 17,24 **** + #define NFA_BRACES_MAXLIMIT 10 + /* For allocating space for the postfix representation */ + #define NFA_POSTFIX_MULTIPLIER (NFA_BRACES_MAXLIMIT + 2)*2 +- /* Size of stack, used when converting the postfix regexp into NFA */ +- #define NFA_STACK_SIZE 1024 + + enum + { +--- 17,22 ---- +*************** +*** 2160,2168 **** + if (nfa_calc_size == FALSE) + { + /* Allocate space for the stack. Max states on the stack : nstate */ +! stack = (Frag_T *) lalloc((nstate + 1)*sizeof(Frag_T), TRUE); + stackp = stack; +! stack_end = stack + NFA_STACK_SIZE; + } + + for (p = postfix; p < end; ++p) +--- 2158,2166 ---- + if (nfa_calc_size == FALSE) + { + /* Allocate space for the stack. Max states on the stack : nstate */ +! stack = (Frag_T *) lalloc((nstate + 1) * sizeof(Frag_T), TRUE); + stackp = stack; +! stack_end = stack + (nstate + 1); + } + + for (p = postfix; p < end; ++p) +*** ../vim-7.3.978/src/version.c 2013-05-20 21:49:08.000000000 +0200 +--- src/version.c 2013-05-20 21:55:37.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 979, + /**/ + +-- + Another bucket of what can only be described as human ordure hits ARTHUR. +ARTHUR: ... Right! (to the KNIGHTS) That settles it! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4b5efec2b7fe161a0280c24dfa35abe0c1b36d5c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:50 +0200 Subject: [PATCH 0879/3340] - patchlevel 980 --- 7.3.980 | 141 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 141 insertions(+) create mode 100644 7.3.980 diff --git a/7.3.980 b/7.3.980 new file mode 100644 index 00000000..f57d5f73 --- /dev/null +++ b/7.3.980 @@ -0,0 +1,141 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.980 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.980 +Problem: Regexp logs may contain garbage. Character classes don't work + correctly for multi-byte characters. +Solution: Check for end of post list. Only use "is" functions for + characters up to 255. (Ken Takata) +Files: src/regexp_nfa.c + + +*** ../vim-7.3.979/src/regexp_nfa.c 2013-05-20 21:56:53.000000000 +0200 +--- src/regexp_nfa.c 2013-05-20 22:09:01.000000000 +0200 +*************** +*** 1826,1838 **** + else if (retval == OK) + fprintf(f, ">>> NFA engine succeeded !\n"); + fprintf(f, "Regexp: \"%s\"\nPostfix notation (char): \"", expr); +! for (p=post_start; *p; p++) + { + nfa_set_code(*p); + fprintf(f, "%s, ", code); + } + fprintf(f, "\"\nPostfix notation (int): "); +! for (p=post_start; *p; p++) + fprintf(f, "%d ", *p); + fprintf(f, "\n\n"); + fclose(f); +--- 1826,1838 ---- + else if (retval == OK) + fprintf(f, ">>> NFA engine succeeded !\n"); + fprintf(f, "Regexp: \"%s\"\nPostfix notation (char): \"", expr); +! for (p = post_start; *p && p < post_end; p++) + { + nfa_set_code(*p); + fprintf(f, "%s, ", code); + } + fprintf(f, "\"\nPostfix notation (int): "); +! for (p = post_start; *p && p < post_end; p++) + fprintf(f, "%d ", *p); + fprintf(f, "\n\n"); + fclose(f); +*************** +*** 2667,2677 **** + switch (class) + { + case NFA_CLASS_ALNUM: +! if (isalnum(c)) + return OK; + break; + case NFA_CLASS_ALPHA: +! if (isalpha(c)) + return OK; + break; + case NFA_CLASS_BLANK: +--- 2667,2677 ---- + switch (class) + { + case NFA_CLASS_ALNUM: +! if (c >= 1 && c <= 255 && isalnum(c)) + return OK; + break; + case NFA_CLASS_ALPHA: +! if (c >= 1 && c <= 255 && isalpha(c)) + return OK; + break; + case NFA_CLASS_BLANK: +*************** +*** 2679,2685 **** + return OK; + break; + case NFA_CLASS_CNTRL: +! if (iscntrl(c)) + return OK; + break; + case NFA_CLASS_DIGIT: +--- 2679,2685 ---- + return OK; + break; + case NFA_CLASS_CNTRL: +! if (c >= 1 && c <= 255 && iscntrl(c)) + return OK; + break; + case NFA_CLASS_DIGIT: +*************** +*** 2687,2693 **** + return OK; + break; + case NFA_CLASS_GRAPH: +! if (isgraph(c)) + return OK; + break; + case NFA_CLASS_LOWER: +--- 2687,2693 ---- + return OK; + break; + case NFA_CLASS_GRAPH: +! if (c >= 1 && c <= 255 && isgraph(c)) + return OK; + break; + case NFA_CLASS_LOWER: +*************** +*** 2699,2705 **** + return OK; + break; + case NFA_CLASS_PUNCT: +! if (ispunct(c)) + return OK; + break; + case NFA_CLASS_SPACE: +--- 2699,2705 ---- + return OK; + break; + case NFA_CLASS_PUNCT: +! if (c >= 1 && c <= 255 && ispunct(c)) + return OK; + break; + case NFA_CLASS_SPACE: +*** ../vim-7.3.979/src/version.c 2013-05-20 21:56:53.000000000 +0200 +--- src/version.c 2013-05-20 22:10:54.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 980, + /**/ + +-- +Why is "abbreviation" such a long word? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1f612a7f54162a2e2e474909ace495358ccd3db6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:50 +0200 Subject: [PATCH 0880/3340] - patchlevel 981 --- 7.3.981 | 101 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 101 insertions(+) create mode 100644 7.3.981 diff --git a/7.3.981 b/7.3.981 new file mode 100644 index 00000000..d1185853 --- /dev/null +++ b/7.3.981 @@ -0,0 +1,101 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.981 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.981 +Problem: In the old regexp engine \i, \I, \f and \F don't work on + multi-byte characters. +Solution: Dereference pointer properly. +Files: src/regexp.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.980/src/regexp.c 2013-05-20 21:49:08.000000000 +0200 +--- src/regexp.c 2013-05-20 23:58:32.000000000 +0200 +*************** +*** 5758,5764 **** + case SIDENT + ADD_NL: + while (count < maxcount) + { +! if (vim_isIDc(*scan) && (testval || !VIM_ISDIGIT(*scan))) + { + mb_ptr_adv(scan); + } +--- 5758,5764 ---- + case SIDENT + ADD_NL: + while (count < maxcount) + { +! if (vim_isIDc(PTR2CHAR(scan)) && (testval || !VIM_ISDIGIT(*scan))) + { + mb_ptr_adv(scan); + } +*************** +*** 5819,5825 **** + case SFNAME + ADD_NL: + while (count < maxcount) + { +! if (vim_isfilec(*scan) && (testval || !VIM_ISDIGIT(*scan))) + { + mb_ptr_adv(scan); + } +--- 5819,5825 ---- + case SFNAME + ADD_NL: + while (count < maxcount) + { +! if (vim_isfilec(PTR2CHAR(scan)) && (testval || !VIM_ISDIGIT(*scan))) + { + mb_ptr_adv(scan); + } +*** ../vim-7.3.980/src/testdir/test64.in 2013-05-19 19:16:25.000000000 +0200 +--- src/testdir/test64.in 2013-05-20 23:58:09.000000000 +0200 +*************** +*** 262,267 **** +--- 262,271 ---- + :call add(tl, ['[a-zA-Z]', 'a', 'a']) + :call add(tl, ['[A-Z]', 'a']) + :call add(tl, ['\C[^A-Z]\+', 'ABCOIJDEOIFNSD jsfoij sa', ' jsfoij sa']) ++ :call add(tl, ['\i\+', '&*§xx ', 'xx']) ++ :call add(tl, ['\%#=1\i\+', '&*§xx ', 'xx']) ++ :call add(tl, ['\f\+', '&*Ÿfname ', 'fname']) ++ :call add(tl, ['\%#=1\i\+', '&*Ÿfname ', 'fname']) + + :"""" Tests for \z features + :call add(tl, ['xx \ze test', 'xx ']) " must match after \ze +*** ../vim-7.3.980/src/testdir/test64.ok 2013-05-19 19:16:25.000000000 +0200 +--- src/testdir/test64.ok 2013-05-21 00:00:08.000000000 +0200 +*************** +*** 203,208 **** +--- 203,212 ---- + OK - [a-zA-Z] + OK - [A-Z] + OK - \C[^A-Z]\+ ++ OK - \i\+ ++ OK - \%#=1\i\+ ++ OK - \f\+ ++ OK - \%#=1\i\+ + OK - xx \ze test + OK - abc\zeend + OK - abc\zsdd +*** ../vim-7.3.980/src/version.c 2013-05-20 22:19:58.000000000 +0200 +--- src/version.c 2013-05-21 00:01:30.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 981, + /**/ + +-- + [The rest of the ARMY stand around looking at a loss.] +INSPECTOR END OF FILM: (picks up megaphone) All right! Clear off! Go on! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 04ae19925579a3bcb68381ff68fdf7fc3d931798 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:51 +0200 Subject: [PATCH 0881/3340] - patchlevel 982 --- 7.3.982 | 97 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100644 7.3.982 diff --git a/7.3.982 b/7.3.982 new file mode 100644 index 00000000..3e8b94f4 --- /dev/null +++ b/7.3.982 @@ -0,0 +1,97 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.982 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.982 +Problem: In the new regexp engine \p does not work on multi-byte + characters. +Solution: Don't point to an integer but the characters. +Files: src/regexp_nfa.c, src/testdir/test95.in, src/testdir/test95.ok + + +*** ../vim-7.3.981/src/regexp_nfa.c 2013-05-20 22:19:58.000000000 +0200 +--- src/regexp_nfa.c 2013-05-21 12:34:02.000000000 +0200 +*************** +*** 2931,2937 **** + } + if (c == NUL) + n = 0; +! cc = (char_u *)&c; + + /* swap lists */ + thislist = &list[flag]; +--- 2931,2937 ---- + } + if (c == NUL) + n = 0; +! cc = reginput; + + /* swap lists */ + thislist = &list[flag]; +*************** +*** 2960,2966 **** + if (neglist->n > 0) + { + t = &neglist->t[0]; +! neglist->n --; + i--; + } + else +--- 2960,2966 ---- + if (neglist->n > 0) + { + t = &neglist->t[0]; +! neglist->n--; + i--; + } + else +*** ../vim-7.3.981/src/testdir/test95.in 2013-05-19 19:16:25.000000000 +0200 +--- src/testdir/test95.in 2013-05-21 12:24:56.000000000 +0200 +*************** +*** 25,30 **** +--- 25,33 ---- + :call add(tl, [' [^ ]\+', 'start มabcdม ', ' มabcdม']) + :call add(tl, ['[ม[:alpha:][=a=]]\+', '879 aiaãมâมaiuvna ', 'aiaãมâมaiuvna']) + ++ :" this is not a normal "i" but 0xec ++ :call add(tl, ['\p\+', 'ìa', 'ìa']) ++ + :"""" Run the tests + + :" +*** ../vim-7.3.981/src/testdir/test95.ok 2013-05-19 19:16:25.000000000 +0200 +--- src/testdir/test95.ok 2013-05-21 12:31:00.000000000 +0200 +*************** +*** 4,6 **** +--- 4,7 ---- + OK - [^ม ]\+ + OK - [^ ]\+ + OK - [ม[:alpha:][=a=]]\+ ++ OK - \p\+ +*** ../vim-7.3.981/src/version.c 2013-05-21 00:02:54.000000000 +0200 +--- src/version.c 2013-05-21 12:32:41.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 982, + /**/ + +-- +ERIC IDLE PLAYED: THE DEAD COLLECTOR, MR BINT (A VILLAGE NE'ER-DO -WELL VERY + KEEN ON BURNING WITCHES), SIR ROBIN, THE GUARD WHO DOESN'T + HICOUGH BUT TRIES TO GET THINGS STRAIGHT, CONCORDE (SIR + LAUNCELOT'S TRUSTY STEED), ROGER THE SHRUBBER (A SHRUBBER), + BROTHER MAYNARD + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4be79b049b22dcd16c8e442783464f60d62ed6a8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:52 +0200 Subject: [PATCH 0882/3340] - patchlevel 983 --- 7.3.983 | 109 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 109 insertions(+) create mode 100644 7.3.983 diff --git a/7.3.983 b/7.3.983 new file mode 100644 index 00000000..19b4a9ca --- /dev/null +++ b/7.3.983 @@ -0,0 +1,109 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.983 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.983 +Problem: Uneccessary temp variable. +Solution: Remove the variable. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.982/src/regexp_nfa.c 2013-05-21 12:34:13.000000000 +0200 +--- src/regexp_nfa.c 2013-05-21 12:35:37.000000000 +0200 +*************** +*** 2833,2839 **** + int old_reglnum = -1; + int reginput_updated = FALSE; + thread_T *t; +- char_u *cc; + char_u *old_reginput = NULL; + char_u *old_regline = NULL; + nfa_state_T *sta; +--- 2833,2838 ---- +*************** +*** 2931,2937 **** + } + if (c == NUL) + n = 0; +- cc = reginput; + + /* swap lists */ + thislist = &list[flag]; +--- 2930,2935 ---- +*************** +*** 3261,3272 **** + break; + + case NFA_KWORD: /* \k */ +! result = vim_iswordp(cc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_SKWORD: /* \K */ +! result = !VIM_ISDIGIT(c) && vim_iswordp(cc); + ADD_POS_NEG_STATE(t->state); + break; + +--- 3259,3270 ---- + break; + + case NFA_KWORD: /* \k */ +! result = vim_iswordp(reginput); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_SKWORD: /* \K */ +! result = !VIM_ISDIGIT(c) && vim_iswordp(reginput); + ADD_POS_NEG_STATE(t->state); + break; + +*************** +*** 3281,3292 **** + break; + + case NFA_PRINT: /* \p */ +! result = ptr2cells(cc) == 1; + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_SPRINT: /* \P */ +! result = !VIM_ISDIGIT(c) && ptr2cells(cc) == 1; + ADD_POS_NEG_STATE(t->state); + break; + +--- 3279,3290 ---- + break; + + case NFA_PRINT: /* \p */ +! result = ptr2cells(reginput) == 1; + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_SPRINT: /* \P */ +! result = !VIM_ISDIGIT(c) && ptr2cells(reginput) == 1; + ADD_POS_NEG_STATE(t->state); + break; + +*** ../vim-7.3.982/src/version.c 2013-05-21 12:34:13.000000000 +0200 +--- src/version.c 2013-05-21 12:41:58.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 983, + /**/ + +-- +Communication is one of the most compli..., eh, well, it's hard. +You know what I mean. Not? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From dfe816dea4a93acaa270e0325bd82a6f5858c66b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:52 +0200 Subject: [PATCH 0883/3340] - patchlevel 984 --- 7.3.984 | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 7.3.984 diff --git a/7.3.984 b/7.3.984 new file mode 100644 index 00000000..c767638c --- /dev/null +++ b/7.3.984 @@ -0,0 +1,49 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.984 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.984 +Problem: A Visual mapping that uses CTRL-G works differently when started + from Insert mode. (Ein Brown) +Solution: Reset old_mapped_len when handling typed text in Select mode. +Files: src/normal.c + + +*** ../vim-7.3.983/src/normal.c 2013-05-06 04:21:35.000000000 +0200 +--- src/normal.c 2013-05-20 21:11:55.000000000 +0200 +*************** +*** 701,706 **** +--- 701,707 ---- + else + c = 'c'; + msg_nowait = TRUE; /* don't delay going to insert mode */ ++ old_mapped_len = 0; /* do go to Insert mode */ + } + #endif + +*** ../vim-7.3.983/src/version.c 2013-05-21 12:43:52.000000000 +0200 +--- src/version.c 2013-05-21 12:45:02.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 984, + /**/ + +-- +MICHAEL PALIN PLAYED: 1ST SOLDIER WITH A KEEN INTEREST IN BIRDS, DENNIS, MR + DUCK (A VILLAGE CARPENTER WHO IS ALMOST KEENER THAN + ANYONE ELSE TO BURN WITCHES), THREE-HEADED KNIGHT, SIR + GALAHAD, KING OF SWAMP CASTLE, BROTHER MAYNARD'S ROOMATE + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ef6e95a49171f02885f422a7642e63029ab20076 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:53 +0200 Subject: [PATCH 0884/3340] - patchlevel 985 --- 7.3.985 | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 7.3.985 diff --git a/7.3.985 b/7.3.985 new file mode 100644 index 00000000..9772951b --- /dev/null +++ b/7.3.985 @@ -0,0 +1,51 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.985 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.985 +Problem: GTK vim not started as gvim doesn't set WM_CLASS property to a + useful value. +Solution: Call g_set_prgname() on startup. (James McCoy) +Files: src/gui_gtk_x11.c + + +*** ../vim-7.3.984/src/gui_gtk_x11.c 2013-05-06 04:21:35.000000000 +0200 +--- src/gui_gtk_x11.c 2013-05-21 12:48:16.000000000 +0200 +*************** +*** 1447,1452 **** +--- 1447,1457 ---- + using_gnome = 1; + #endif + ++ /* This defaults to argv[0], but we want it to match the name of the ++ * shipped gvim.desktop so that Vim's windows can be associated with this ++ * file. */ ++ g_set_prgname("gvim"); ++ + /* Don't use gtk_init() or gnome_init(), it exits on failure. */ + if (!gtk_init_check(&gui_argc, &gui_argv)) + { +*** ../vim-7.3.984/src/version.c 2013-05-21 12:45:54.000000000 +0200 +--- src/version.c 2013-05-21 12:50:04.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 985, + /**/ + +-- +A disclaimer for the disclaimer: +"and before I get a huge amount of complaints , I have no control over the +disclaimer at the end of this mail :-)" (Timothy Aldrich) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 21eb49fadba2ee3875631e39f37582479df9e0fc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:54 +0200 Subject: [PATCH 0885/3340] - patchlevel 986 --- 7.3.986 | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 7.3.986 diff --git a/7.3.986 b/7.3.986 new file mode 100644 index 00000000..f6fc7736 --- /dev/null +++ b/7.3.986 @@ -0,0 +1,61 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.986 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.986 +Problem: Test 95 doesn't pass when 'encoding' isn't utf-8. (Yasuhiro + Matsumoto) +Solution: Force 'encoding' to be utf-8. +Files: src/testdir/test95.in + + +*** ../vim-7.3.985/src/testdir/test95.in 2013-05-21 12:34:13.000000000 +0200 +--- src/testdir/test95.in 2013-05-21 12:58:09.000000000 +0200 +*************** +*** 1,4 **** +! Test for regexp patterns with multi-byte support. + See test64 for the non-multi-byte tests. + + A pattern that gives the expected result produces OK, so that we know it was +--- 1,4 ---- +! Test for regexp patterns with multi-byte support, using utf-8. + See test64 for the non-multi-byte tests. + + A pattern that gives the expected result produces OK, so that we know it was +*************** +*** 7,12 **** +--- 7,13 ---- + STARTTEST + :so small.vim + :so mbyte.vim ++ :set encoding=utf-8 viminfo+=nviminfo + :" tl is a List of Lists with: + :" regexp pattern + :" text to test the pattern on +*** ../vim-7.3.985/src/version.c 2013-05-21 12:52:00.000000000 +0200 +--- src/version.c 2013-05-21 12:59:32.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 986, + /**/ + +-- +(letter from Mark to Mike, about the film's probable certificate) + For an 'A' we would have to: Lose as many shits as possible; Take Jesus + Christ out, if possible; Loose "I fart in your general direction"; Lose + "the oral sex"; Lose "oh, fuck off"; Lose "We make castanets out of your + testicles" + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5589d698c9519647ac71587613db390288fdaf9b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:54 +0200 Subject: [PATCH 0886/3340] - patchlevel 987 --- 7.3.987 | 201 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 201 insertions(+) create mode 100644 7.3.987 diff --git a/7.3.987 b/7.3.987 new file mode 100644 index 00000000..543c40bf --- /dev/null +++ b/7.3.987 @@ -0,0 +1,201 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.987 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.987 +Problem: No easy to run an individual test. Tests 64 fails when + 'encoding' is not utf-8. +Solution: Add individual test targets to the Makefile. Move some lines from + test 64 to 95. +Files: src/Makefile, src/testdir/test64.in, src/testdir/test64.ok, + src/testdir/test95.in, src/testdir/test95.ok + + +*** ../vim-7.3.986/src/Makefile 2013-05-19 19:16:25.000000000 +0200 +--- src/Makefile 2013-05-21 13:18:04.000000000 +0200 +*************** +*** 1861,1866 **** +--- 1861,1879 ---- + ./$$t || exit 1; echo $$t passed; \ + done + ++ # Run individual test, assuming that Vim was already compiled. ++ test1 test2 test3 test4 test5 test6 test7 test8 test9 test10 \ ++ test11 test12 test13 test14 test15 test16 test17 test18 test19 \ ++ test21 test22 test23 test24 test25 test26 test27 test28 test29 \ ++ test31 test32 test33 test34 test35 test36 test37 test38 test39 \ ++ test41 test42 test43 test44 test45 test46 test47 test48 test49 \ ++ test51 test52 test53 test54 test55 test56 test57 test58 test59 \ ++ test61 test62 test63 test64 test65 test66 test67 test68 test69 \ ++ test71 test72 test73 test74 test75 test76 test77 test78 test79 \ ++ test81 test82 test83 test84 test85 test86 test87 test88 test89 \ ++ test91 test92 test93 test94 test95 test96 test97 test98 test99: ++ cd testdir; rm $@.out; $(MAKE) -f Makefile $@.out VIMPROG=../$(VIMTARGET) ++ + testclean: + cd testdir; $(MAKE) -f Makefile clean + if test -d $(PODIR); then \ +*** ../vim-7.3.986/src/testdir/test64.in 2013-05-21 00:02:54.000000000 +0200 +--- src/testdir/test64.in 2013-05-21 13:23:27.000000000 +0200 +*************** +*** 262,271 **** + :call add(tl, ['[a-zA-Z]', 'a', 'a']) + :call add(tl, ['[A-Z]', 'a']) + :call add(tl, ['\C[^A-Z]\+', 'ABCOIJDEOIFNSD jsfoij sa', ' jsfoij sa']) +- :call add(tl, ['\i\+', '&*§xx ', 'xx']) +- :call add(tl, ['\%#=1\i\+', '&*§xx ', 'xx']) +- :call add(tl, ['\f\+', '&*Ÿfname ', 'fname']) +- :call add(tl, ['\%#=1\i\+', '&*Ÿfname ', 'fname']) + + :"""" Tests for \z features + :call add(tl, ['xx \ze test', 'xx ']) " must match after \ze +--- 262,267 ---- +*************** +*** 290,302 **** + + :"""" Combining different tests and features + :call add(tl, ['[[:alpha:]]\{-2,6}', '787abcdiuhsasiuhb4', 'ab']) +- :call add(tl, ['[^[=a=]]\+', 'ddaãâbcd', 'dd']) + :call add(tl, ['', 'abcd', '']) + :call add(tl, ['\v(())', 'any possible text', '']) + :call add(tl, ['\v%(ab(xyz)c)', ' abxyzc ', 'abxyzc', 'xyz']) + :call add(tl, ['\v(test|)empty', 'tesempty', 'empty', '']) + :call add(tl, ['\v(a|aa)(a|aa)', 'aaa', 'aa', 'a', 'a']) + + + :"""" Run the tests + +--- 286,303 ---- + + :"""" Combining different tests and features + :call add(tl, ['[[:alpha:]]\{-2,6}', '787abcdiuhsasiuhb4', 'ab']) + :call add(tl, ['', 'abcd', '']) + :call add(tl, ['\v(())', 'any possible text', '']) + :call add(tl, ['\v%(ab(xyz)c)', ' abxyzc ', 'abxyzc', 'xyz']) + :call add(tl, ['\v(test|)empty', 'tesempty', 'empty', '']) + :call add(tl, ['\v(a|aa)(a|aa)', 'aaa', 'aa', 'a', 'a']) + ++ :"""" \%u and friends ++ :call add(tl, ['\%d32', 'yes no', ' ']) ++ :call add(tl, ['\%o40', 'yes no', ' ']) ++ :call add(tl, ['\%x20', 'yes no', ' ']) ++ :call add(tl, ['\%u0020', 'yes no', ' ']) ++ :call add(tl, ['\%U00000020', 'yes no', ' ']) + + :"""" Run the tests + +*** ../vim-7.3.986/src/testdir/test64.ok 2013-05-21 00:02:54.000000000 +0200 +--- src/testdir/test64.ok 2013-05-21 13:23:37.000000000 +0200 +*************** +*** 203,212 **** + OK - [a-zA-Z] + OK - [A-Z] + OK - \C[^A-Z]\+ +- OK - \i\+ +- OK - \%#=1\i\+ +- OK - \f\+ +- OK - \%#=1\i\+ + OK - xx \ze test + OK - abc\zeend + OK - abc\zsdd +--- 203,208 ---- +*************** +*** 225,234 **** + OK - .*John\&.*Bob + OK - \v(test1)@=.*yep + OK - [[:alpha:]]\{-2,6} +- OK - [^[=a=]]\+ + OK - + OK - \v(()) + OK - \v%(ab(xyz)c) + OK - \v(test|)empty + OK - \v(a|aa)(a|aa) + 192.168.0.1 +--- 221,234 ---- + OK - .*John\&.*Bob + OK - \v(test1)@=.*yep + OK - [[:alpha:]]\{-2,6} + OK - + OK - \v(()) + OK - \v%(ab(xyz)c) + OK - \v(test|)empty + OK - \v(a|aa)(a|aa) ++ OK - \%d32 ++ OK - \%o40 ++ OK - \%x20 ++ OK - \%u0020 ++ OK - \%U00000020 + 192.168.0.1 +*** ../vim-7.3.986/src/testdir/test95.in 2013-05-21 13:05:05.000000000 +0200 +--- src/testdir/test95.in 2013-05-21 13:24:19.000000000 +0200 +*************** +*** 7,13 **** + STARTTEST + :so small.vim + :so mbyte.vim +! :set encoding=utf-8 viminfo+=nviminfo + :" tl is a List of Lists with: + :" regexp pattern + :" text to test the pattern on +--- 7,13 ---- + STARTTEST + :so small.vim + :so mbyte.vim +! :set nocp encoding=utf-8 viminfo+=nviminfo + :" tl is a List of Lists with: + :" regexp pattern + :" text to test the pattern on +*************** +*** 29,34 **** +--- 29,43 ---- + :" this is not a normal "i" but 0xec + :call add(tl, ['\p\+', 'ìa', 'ìa']) + ++ :"""" Test recognition of some character classes ++ :call add(tl, ['\i\+', '&*§xx ', 'xx']) ++ :call add(tl, ['\%#=1\i\+', '&*§xx ', 'xx']) ++ :call add(tl, ['\f\+', '&*Ÿfname ', 'fname']) ++ :call add(tl, ['\%#=1\i\+', '&*Ÿfname ', 'fname']) ++ ++ :"""" Combining different tests and features ++ :call add(tl, ['[^[=a=]]\+', 'ddaãâbcd', 'dd']) ++ + :"""" Run the tests + + :" +*** ../vim-7.3.986/src/testdir/test95.ok 2013-05-21 12:34:13.000000000 +0200 +--- src/testdir/test95.ok 2013-05-21 13:24:23.000000000 +0200 +*************** +*** 5,7 **** +--- 5,12 ---- + OK - [^ ]\+ + OK - [ม[:alpha:][=a=]]\+ + OK - \p\+ ++ OK - \i\+ ++ OK - \%#=1\i\+ ++ OK - \f\+ ++ OK - \%#=1\i\+ ++ OK - [^[=a=]]\+ +*** ../vim-7.3.986/src/version.c 2013-05-21 13:05:05.000000000 +0200 +--- src/version.c 2013-05-21 13:27:12.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 987, + /**/ + +-- +An SQL statement walks into a bar. He approaches two tables +and says, "Mind if I join you?" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5106782ad7f930e11682ae1f25b9e4fded1d7774 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 13:33:56 +0200 Subject: [PATCH 0887/3340] - patchlevel 987 --- README.patches | 43 +++++++++++++++++++++++ vim.spec | 93 ++++++++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 134 insertions(+), 2 deletions(-) diff --git a/README.patches b/README.patches index ad55b60a..287479e0 100644 --- a/README.patches +++ b/README.patches @@ -976,3 +976,46 @@ Individual patches for Vim 7.3: 5470 7.3.942 Python: SEGV in Buffer functions 6867 7.3.943 Python: Negative indices were failing 2283 7.3.944 external program receives the termrespone + 16738 7.3.945 Python: List of buffers is not very useful + 3029 7.3.946 sometimes keys starting with [ ar not working + 17613 7.3.947 Python: No iterator for vim.list and vim.bufferlist + 11841 7.3.948 cannot build with Python 2.2 + 25668 7.3.949 Python: no easy access to tabpages + 5750 7.3.950 Python: Stack trace printer can't handle messages + 15906 7.3.951 Python exceptions have problems + 5245 7.3.952 Python: It's not easy to change window/buffer/tabpage + 3924 7.3.953 Python: string exceptions are deprecated + 2374 7.3.954 No check if PyObject_IsTrue fails + 12291 7.3.955 Python: Not enough tests + 5261 7.3.956 Python vim.bindeval() causes SIGABRT + 9959 7.3.957 Python does not have a "do" command like Perl or Lua + 1772 7.3.958 Python: Iteration destructor not set + 2058 7.3.959 (after 7.3.957) missing error number + 1366 7.3.960 compiler warning for unused variable + 3054 7.3.961 tests 86 and 87 fail when using another language than English + 8389 7.3.962 Python tests are not portable + 18867 7.3.963 setting curbuf without curwin causes trouble + 13179 7.3.964 Python: not so easy to access tab pages + 8088 7.3.965 Python garbage collection not working properly + 10038 7.3.966 there is ":py3do" but no ":pydo" + 3304 7.3.967 (after 7.3.965) build fails on Mac OSX + 2100 7.3.968 multi-byte support is only available with "big" features + 1603 7.3.969 can't built with Python 3 and without Python 2 +184170 7.3.970 pattern matching is slow, include the NFA engine + 4337 7.3.971 no support for VS2012 static code analysis + 3720 7.3.972 cursor not restored properly after InsertEnter autocommand + 3881 7.3.973 (after 7.3.970) compiler warnings, crash on startup + 4775 7.3.974 can't build with ruby 1.8.5 + 2301 7.3.975 (after 7.3.970) crash in regexp parsing + 2254 7.3.976 (after 7.3.970) can't build with HP-UX + 7028 7.3.977 compiler warnings, white space, uncommented for testing + 4535 7.3.978 regexp debug logs don't have a good name + 2268 7.3.979 complex NFA regexp doesn't work + 3597 7.3.980 regexp logs contain garbage; character classes don't work + 3105 7.3.981 old regexp engine fails on \i, \I, \f and \F with mbyte chars + 2800 7.3.982 \p does not work on multi-byte chars in new regexp engine + 2675 7.3.983 uneccessary temp variable + 1706 7.3.984 Visual mapping using CTRL-G works differently from Insert mode + 1691 7.3.985 GTK vim not started as gvim has WM_CLASS property wrong + 2113 7.3.986 test 95 doesn't pass when 'encoding' isn't utf-8 + 6338 7.3.987 no easy to run an individual test; test 64 may fail diff --git a/vim.spec b/vim.spec index 92cb81dc..13484e16 100644 --- a/vim.spec +++ b/vim.spec @@ -18,13 +18,13 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 944 +%define patchlevel 987 Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{beta}%{patchlevel} -Release: 2%{?dist} +Release: 1%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}%{?beta}%{?CVSDATE}.tar.bz2 @@ -1000,6 +1000,49 @@ Patch941: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.941 Patch942: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.942 Patch943: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.943 Patch944: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.944 +Patch945: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.945 +Patch946: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.946 +Patch947: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.947 +Patch948: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.948 +Patch949: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.949 +Patch950: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.950 +Patch951: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.951 +Patch952: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.952 +Patch953: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.953 +Patch954: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.954 +Patch955: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.955 +Patch956: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.956 +Patch957: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.957 +Patch958: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.958 +Patch959: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.959 +Patch960: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.960 +Patch961: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.961 +Patch962: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.962 +Patch963: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.963 +Patch964: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.964 +Patch965: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.965 +Patch966: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.966 +Patch967: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.967 +Patch968: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.968 +Patch969: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.969 +Patch970: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.970 +Patch971: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.971 +Patch972: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.972 +Patch973: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.973 +Patch974: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.974 +Patch975: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.975 +Patch976: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.976 +Patch977: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.977 +Patch978: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.978 +Patch979: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.979 +Patch980: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.980 +Patch981: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.981 +Patch982: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.982 +Patch983: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.983 +Patch984: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.984 +Patch985: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.985 +Patch986: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.986 +Patch987: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.987 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -2090,6 +2133,49 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch942 -p0 %patch943 -p0 %patch944 -p0 +%patch945 -p0 +%patch946 -p0 +%patch947 -p0 +%patch948 -p0 +%patch949 -p0 +%patch950 -p0 +%patch951 -p0 +%patch952 -p0 +%patch953 -p0 +%patch954 -p0 +%patch955 -p0 +%patch956 -p0 +%patch957 -p0 +%patch958 -p0 +%patch959 -p0 +%patch960 -p0 +%patch961 -p0 +%patch962 -p0 +%patch963 -p0 +%patch964 -p0 +%patch965 -p0 +%patch966 -p0 +%patch967 -p0 +%patch968 -p0 +%patch969 -p0 +%patch970 -p0 +%patch971 -p0 +%patch972 -p0 +%patch973 -p0 +%patch974 -p0 +%patch975 -p0 +%patch976 -p0 +%patch977 -p0 +%patch978 -p0 +%patch979 -p0 +%patch980 -p0 +%patch981 -p0 +%patch982 -p0 +%patch983 -p0 +%patch984 -p0 +%patch985 -p0 +%patch986 -p0 +%patch987 -p0 # install spell files @@ -2584,6 +2670,9 @@ rm -rf %{buildroot} %{_datadir}/icons/hicolor/*/apps/* %changelog +* Tue May 21 2013 Karsten Hopp 7.3.987-1 +- patchlevel 987 + * Tue May 21 2013 Karsten Hopp 7.3.944-2 - consistent use of macros in spec file - add some links to man pages From a90d90b0d806c2c587e39a5c47cd70b2141163b3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 21 May 2013 14:19:09 +0200 Subject: [PATCH 0888/3340] fix patch --- 7.3.970 | 53 +---------------------------------------------------- 1 file changed, 1 insertion(+), 52 deletions(-) diff --git a/7.3.970 b/7.3.970 index 5b74a5e2..519138a0 100644 --- a/7.3.970 +++ b/7.3.970 @@ -20,7 +20,7 @@ Files: src/Make_cyg.mak, src/Make_ming.mak, src/Make_mvc.mak, src/testdir/test95.in, src/testdir/test95.ok, src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak, src/testdir/Make_ming.mak, src/testdir/Make_os2.mak, - src/testdir/Make_vms.mms, src/testdir/Makefile + src/testdir/Make_vms.mms *** ../vim-7.3.969/src/Make_cyg.mak 2013-05-06 04:21:35.000000000 +0200 @@ -6701,57 +6701,6 @@ Files: src/Make_cyg.mak, src/Make_ming.mak, src/Make_mvc.mak, # Known problems: # Test 30: a problem around mac format - unknown reason -*** ../vim-7.3.969/src/testdir/Makefile 2013-04-24 12:56:13.000000000 +0200 ---- src/testdir/Makefile 2013-05-18 14:22:50.000000000 +0200 -*************** -*** 29,35 **** - test79.out test80.out test81.out test82.out test83.out \ - test84.out test85.out test86.out test87.out test88.out \ - test89.out test90.out test91.out test92.out test93.out \ -! test94.out - - SCRIPTS_GUI = test16.out - ---- 29,35 ---- - test79.out test80.out test81.out test82.out test83.out \ - test84.out test85.out test86.out test87.out test88.out \ - test89.out test90.out test91.out test92.out test93.out \ -! test94.out test95.out - - SCRIPTS_GUI = test16.out - -*************** -*** 85,97 **** - fi" - - # Check if the test.out file matches test.ok. -! @/bin/sh -c "if test -f test.out; then\ - if diff test.out $*.ok; \ - then mv -f test.out $*.out; \ - else echo $* FAILED >>test.log; mv -f test.out $*.failed; \ - fi \ - else echo $* NO OUTPUT >>test.log; \ - fi" - -rm -rf X* test.ok viminfo - - test49.out: test49.vim ---- 85,100 ---- - fi" - - # Check if the test.out file matches test.ok. -! @/bin/sh -c "if test -f test.out; then \ - if diff test.out $*.ok; \ - then mv -f test.out $*.out; \ - else echo $* FAILED >>test.log; mv -f test.out $*.failed; \ - fi \ - else echo $* NO OUTPUT >>test.log; \ - fi" -+ @/bin/sh -c "if test -f valgrind; then\ -+ mv -f valgrind valgrind.$*; \ -+ fi" - -rm -rf X* test.ok viminfo - - test49.out: test49.vim *** ../vim-7.3.969/src/version.c 2013-05-18 20:55:31.000000000 +0200 --- src/version.c 2013-05-19 19:10:25.000000000 +0200 *************** From 5357f602ce055845f58bd24a7ac8584142d90d89 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 14 May 2013 15:09:45 +0200 Subject: [PATCH 0889/3340] fix path to xsubpp script --- vim-7.3-xsubpp-path.patch | 12 ++++++++++++ vim.spec | 2 ++ 2 files changed, 14 insertions(+) create mode 100644 vim-7.3-xsubpp-path.patch diff --git a/vim-7.3-xsubpp-path.patch b/vim-7.3-xsubpp-path.patch new file mode 100644 index 00000000..971b10a5 --- /dev/null +++ b/vim-7.3-xsubpp-path.patch @@ -0,0 +1,12 @@ +diff -up vim73/src/Makefile.xsubpp vim73/src/Makefile +--- vim73/src/Makefile.xsubpp 2013-05-13 15:02:15.894805644 +0200 ++++ vim73/src/Makefile 2013-05-13 15:07:03.922821257 +0200 +@@ -2416,7 +2416,7 @@ lintinstall: + + auto/if_perl.c: if_perl.xs + $(PERL) -e 'unless ( $$] >= 5.005 ) { for (qw(na defgv errgv)) { print "#define PL_$$_ $$_\n" }}' > $@ +- $(PERL) $(PERLLIB)/ExtUtils/xsubpp -prototypes -typemap \ ++ $(PERL) $(PERLLIB)/vendor_perl/ExtUtils/xsubpp -prototypes -typemap \ + $(PERLLIB)/ExtUtils/typemap if_perl.xs >> $@ + + auto/osdef.h: auto/config.h osdef.sh osdef1.h.in osdef2.h.in diff --git a/vim.spec b/vim.spec index 13484e16..87cd16f1 100644 --- a/vim.spec +++ b/vim.spec @@ -1056,6 +1056,7 @@ Patch3011: vim72-rh514717.patch Patch3012: vim-7.3-bug816848.patch Patch3013: vim-7.3-manpage-typo-668894-675480.patch Patch3014: vim-7.3-rubyversion.patch +Patch3015: vim-7.3-xsubpp-path.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel ncurses-devel gettext perl-devel @@ -2195,6 +2196,7 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch3012 -p1 %patch3013 -p1 %patch3014 -p1 +%patch3015 -p1 %build cp -f %{SOURCE5} . From ae61a4312d074208dfbf86ffd9ee525c38b28b2c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 22 May 2013 14:13:12 +0200 Subject: [PATCH 0890/3340] patchlevel 1000 --- 7.3.1000 | 55 + 7.3.988 | 50 + 7.3.989 | 67 ++ 7.3.990 | 305 ++++++ 7.3.991 | 745 +++++++++++++ 7.3.992 | 2719 ++++++++++++++++++++++++++++++++++++++++++++++++ 7.3.993 | 248 +++++ 7.3.994 | 249 +++++ 7.3.995 | 512 +++++++++ 7.3.996 | 374 +++++++ 7.3.997 | 983 +++++++++++++++++ 7.3.998 | 414 ++++++++ 7.3.999 | 165 +++ README.patches | 15 +- vim.spec | 31 +- 15 files changed, 6930 insertions(+), 2 deletions(-) create mode 100644 7.3.1000 create mode 100644 7.3.988 create mode 100644 7.3.989 create mode 100644 7.3.990 create mode 100644 7.3.991 create mode 100644 7.3.992 create mode 100644 7.3.993 create mode 100644 7.3.994 create mode 100644 7.3.995 create mode 100644 7.3.996 create mode 100644 7.3.997 create mode 100644 7.3.998 create mode 100644 7.3.999 diff --git a/7.3.1000 b/7.3.1000 new file mode 100644 index 00000000..c9164fff --- /dev/null +++ b/7.3.1000 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1000 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1000 (whoa!) +Problem: Typo in char value causes out of bounds access. +Solution: Fix character value. (Klemens Baum) +Files: src/regexp.c + + +*** ../vim-7.3.999/src/regexp.c 2013-05-21 00:02:54.000000000 +0200 +--- src/regexp.c 2013-05-21 21:25:58.000000000 +0200 +*************** +*** 6899,6905 **** + { + decomp_T d; + +! if (c >= 0x4b20 && c <= 0xfb4f) + { + d = decomp_table[c - 0xfb20]; + *c1 = d.a; +--- 6899,6905 ---- + { + decomp_T d; + +! if (c >= 0xfb20 && c <= 0xfb4f) + { + d = decomp_table[c - 0xfb20]; + *c1 = d.a; +*** ../vim-7.3.999/src/version.c 2013-05-21 21:20:16.000000000 +0200 +--- src/version.c 2013-05-21 21:22:14.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1000, + /**/ + +-- +ARTHUR: The swallow may fly south with the sun, or the house martin or the + plover seek warmer hot lands in winter, yet these are not strangers to + our land. +SOLDIER: Are you suggesting coconuts migrate? + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// diff --git a/7.3.988 b/7.3.988 new file mode 100644 index 00000000..46073b8c --- /dev/null +++ b/7.3.988 @@ -0,0 +1,50 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.988 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.988 +Problem: New regexp engine is slow. +Solution: Break out of the loop when the state list is empty. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.987/src/regexp_nfa.c 2013-05-21 12:43:52.000000000 +0200 +--- src/regexp_nfa.c 2013-05-21 14:01:33.000000000 +0200 +*************** +*** 2951,2956 **** +--- 2951,2961 ---- + #ifdef NFA_REGEXP_DEBUG_LOG + fprintf(debug, "\n-------------------\n"); + #endif ++ /* ++ * If the state lists are empty we can stop. ++ */ ++ if (thislist->n == 0 && neglist->n == 0) ++ break; + + /* compute nextlist */ + for (i = 0; i < thislist->n || neglist->n > 0; ++i) +*** ../vim-7.3.987/src/version.c 2013-05-21 13:30:17.000000000 +0200 +--- src/version.c 2013-05-21 14:02:12.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 988, + /**/ + +-- +The chat program is in public domain. This is not the GNU public license. +If it breaks then you get to keep both pieces. + -- Copyright notice for the chat program + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// diff --git a/7.3.989 b/7.3.989 new file mode 100644 index 00000000..63103567 --- /dev/null +++ b/7.3.989 @@ -0,0 +1,67 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.989 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.989 +Problem: New regexp engine compares negative numbers to character. +Solution: Add missing case statements. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.988/src/regexp_nfa.c 2013-05-21 14:02:55.000000000 +0200 +--- src/regexp_nfa.c 2013-05-21 15:31:47.000000000 +0200 +*************** +*** 3383,3390 **** +--- 3383,3412 ---- + ADD_POS_NEG_STATE(t->state); + break; + ++ case NFA_MOPEN + 0: ++ case NFA_MOPEN + 1: ++ case NFA_MOPEN + 2: ++ case NFA_MOPEN + 3: ++ case NFA_MOPEN + 4: ++ case NFA_MOPEN + 5: ++ case NFA_MOPEN + 6: ++ case NFA_MOPEN + 7: ++ case NFA_MOPEN + 8: ++ case NFA_MOPEN + 9: ++ /* handled below */ ++ break; ++ ++ case NFA_SKIP_CHAR: ++ case NFA_ZSTART: ++ /* TODO: should not happen? */ ++ break; ++ + default: /* regular character */ ++ /* TODO: put this in #ifdef later */ ++ if (t->state->c < -256) ++ EMSGN("INTERNAL: Negative state char: %ld", t->state->c); + result = (no_Magic(t->state->c) == c); ++ + if (!result) + result = ireg_ic == TRUE + && MB_TOLOWER(t->state->c) == MB_TOLOWER(c); +*** ../vim-7.3.988/src/version.c 2013-05-21 14:02:55.000000000 +0200 +--- src/version.c 2013-05-21 15:32:50.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 989, + /**/ + +-- +God made machine language; all the rest is the work of man. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// diff --git a/7.3.990 b/7.3.990 new file mode 100644 index 00000000..aea9343f --- /dev/null +++ b/7.3.990 @@ -0,0 +1,305 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.990 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.990 +Problem: Memory leak in new regexp engine. +Solution: Jump to end of function to free memory. (Dominique Pelle) +Files: src/regexp_nfa.c + + +*** ../vim-7.3.989/src/regexp_nfa.c 2013-05-21 15:33:37.000000000 +0200 +--- src/regexp_nfa.c 2013-05-21 16:17:15.000000000 +0200 +*************** +*** 2143,2148 **** +--- 2143,2149 ---- + nfa_state_T *s; + nfa_state_T *s1; + nfa_state_T *matchstate; ++ nfa_state_T *ret = NULL; + + if (postfix == NULL) + return NULL; +*************** +*** 2211,2217 **** + e1 = POP(); + s = new_state(NFA_SPLIT, e1.start, e2.start); + if (s == NULL) +! return NULL; + PUSH(frag(s, append(e1.out, e2.out))); + break; + +--- 2212,2218 ---- + e1 = POP(); + s = new_state(NFA_SPLIT, e1.start, e2.start); + if (s == NULL) +! goto theend; + PUSH(frag(s, append(e1.out, e2.out))); + break; + +*************** +*** 2225,2231 **** + e = POP(); + s = new_state(NFA_SPLIT, e.start, NULL); + if (s == NULL) +! return NULL; + patch(e.out, s); + PUSH(frag(s, list1(&s->out1))); + break; +--- 2226,2232 ---- + e = POP(); + s = new_state(NFA_SPLIT, e.start, NULL); + if (s == NULL) +! goto theend; + patch(e.out, s); + PUSH(frag(s, list1(&s->out1))); + break; +*************** +*** 2240,2246 **** + e = POP(); + s = new_state(NFA_SPLIT, e.start, NULL); + if (s == NULL) +! return NULL; + PUSH(frag(s, append(e.out, list1(&s->out1)))); + break; + +--- 2241,2247 ---- + e = POP(); + s = new_state(NFA_SPLIT, e.start, NULL); + if (s == NULL) +! goto theend; + PUSH(frag(s, append(e.out, list1(&s->out1)))); + break; + +*************** +*** 2254,2260 **** + e = POP(); + s = new_state(NFA_SPLIT, NULL, e.start); + if (s == NULL) +! return NULL; + PUSH(frag(s, append(e.out, list1(&s->out)))); + break; + +--- 2255,2261 ---- + e = POP(); + s = new_state(NFA_SPLIT, NULL, e.start); + if (s == NULL) +! goto theend; + PUSH(frag(s, append(e.out, list1(&s->out)))); + break; + +*************** +*** 2268,2274 **** + e = POP(); + s = new_state(NFA_SPLIT, e.start, NULL); + if (s == NULL) +! return NULL; + patch(e.out, s); + PUSH(frag(e.start, list1(&s->out1))); + break; +--- 2269,2275 ---- + e = POP(); + s = new_state(NFA_SPLIT, e.start, NULL); + if (s == NULL) +! goto theend; + patch(e.out, s); + PUSH(frag(e.start, list1(&s->out1))); + break; +*************** +*** 2283,2289 **** + } + s = new_state(NFA_SKIP_CHAR, NULL, NULL); + if (s == NULL) +! return NULL; + PUSH(frag(s, list1(&s->out))); + break; + +--- 2284,2290 ---- + } + s = new_state(NFA_SKIP_CHAR, NULL, NULL); + if (s == NULL) +! goto theend; + PUSH(frag(s, list1(&s->out))); + break; + +*************** +*** 2293,2299 **** + * END_INVISIBLE, similarly to MOPEN. + */ + /* TODO: Maybe this drops the speed? */ +! return NULL; + + if (nfa_calc_size == TRUE) + { +--- 2294,2300 ---- + * END_INVISIBLE, similarly to MOPEN. + */ + /* TODO: Maybe this drops the speed? */ +! goto theend; + + if (nfa_calc_size == TRUE) + { +*************** +*** 2303,2314 **** + e = POP(); + s1 = new_state(NFA_END_INVISIBLE, NULL, NULL); + if (s1 == NULL) +! return NULL; + patch(e.out, s1); + + s = new_state(NFA_START_INVISIBLE, e.start, s1); + if (s == NULL) +! return NULL; + PUSH(frag(s, list1(&s1->out))); + break; + +--- 2304,2315 ---- + e = POP(); + s1 = new_state(NFA_END_INVISIBLE, NULL, NULL); + if (s1 == NULL) +! goto theend; + patch(e.out, s1); + + s = new_state(NFA_START_INVISIBLE, e.start, s1); + if (s == NULL) +! goto theend; + PUSH(frag(s, list1(&s1->out))); + break; + +*************** +*** 2357,2366 **** + { + s = new_state(mopen, NULL, NULL); + if (s == NULL) +! return NULL; + s1 = new_state(mclose, NULL, NULL); + if (s1 == NULL) +! return NULL; + patch(list1(&s->out), s1); + PUSH(frag(s, list1(&s1->out))); + break; +--- 2358,2367 ---- + { + s = new_state(mopen, NULL, NULL); + if (s == NULL) +! goto theend; + s1 = new_state(mclose, NULL, NULL); + if (s1 == NULL) +! goto theend; + patch(list1(&s->out), s1); + PUSH(frag(s, list1(&s1->out))); + break; +*************** +*** 2371,2381 **** + e = POP(); + s = new_state(mopen, e.start, NULL); /* `(' */ + if (s == NULL) +! return NULL; + + s1 = new_state(mclose, NULL, NULL); /* `)' */ + if (s1 == NULL) +! return NULL; + patch(e.out, s1); + + if (mopen == NFA_MULTIBYTE || mopen == NFA_COMPOSING) +--- 2372,2382 ---- + e = POP(); + s = new_state(mopen, e.start, NULL); /* `(' */ + if (s == NULL) +! goto theend; + + s1 = new_state(mclose, NULL, NULL); /* `)' */ + if (s1 == NULL) +! goto theend; + patch(e.out, s1); + + if (mopen == NFA_MULTIBYTE || mopen == NFA_COMPOSING) +*************** +*** 2397,2403 **** + } + s = new_state(*p, NULL, NULL); + if (s == NULL) +! return NULL; + PUSH(frag(s, list1(&s->out))); + break; + +--- 2398,2404 ---- + } + s = new_state(*p, NULL, NULL); + if (s == NULL) +! goto theend; + PUSH(frag(s, list1(&s->out))); + break; + +*************** +*** 2408,2414 **** + if (nfa_calc_size == TRUE) + { + nstate++; +! return NULL; /* Return value when counting size is ignored anyway */ + } + + e = POP(); +--- 2409,2415 ---- + if (nfa_calc_size == TRUE) + { + nstate++; +! goto theend; /* Return value when counting size is ignored anyway */ + } + + e = POP(); +*************** +*** 2418,2431 **** + if (istate >= nstate) + EMSG_RET_NULL(_("E876: (NFA regexp) Not enough space to store the whole NFA ")); + +- vim_free(stack); +- + matchstate = &state_ptr[istate++]; /* the match state */ + matchstate->c = NFA_MATCH; + matchstate->out = matchstate->out1 = NULL; + + patch(e.out, matchstate); +! return e.start; + + #undef POP1 + #undef PUSH1 +--- 2419,2434 ---- + if (istate >= nstate) + EMSG_RET_NULL(_("E876: (NFA regexp) Not enough space to store the whole NFA ")); + + matchstate = &state_ptr[istate++]; /* the match state */ + matchstate->c = NFA_MATCH; + matchstate->out = matchstate->out1 = NULL; + + patch(e.out, matchstate); +! ret = e.start; +! +! theend: +! vim_free(stack); +! return ret; + + #undef POP1 + #undef PUSH1 +*** ../vim-7.3.989/src/version.c 2013-05-21 15:33:37.000000000 +0200 +--- src/version.c 2013-05-21 16:18:03.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 990, + /**/ + +-- +This message contains 78% recycled characters. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// diff --git a/7.3.991 b/7.3.991 new file mode 100644 index 00000000..3b28bcd9 --- /dev/null +++ b/7.3.991 @@ -0,0 +1,745 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.991 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.991 +Problem: More can be shared by Python 2 and 3. +Solution: Move more stuff to if_py_both. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c, + src/testdir/test87.ok + + +*** ../vim-7.3.990/src/if_py_both.h 2013-05-17 21:20:13.000000000 +0200 +--- src/if_py_both.h 2013-05-21 18:07:46.000000000 +0200 +*************** +*** 30,35 **** +--- 30,38 ---- + #define INVALID_WINDOW_VALUE ((win_T *)(-1)) + #define INVALID_TABPAGE_VALUE ((tabpage_T *)(-1)) + ++ typedef void (*rangeinitializer)(void *); ++ typedef void (*runner)(const char *, void *, PyGILState_STATE *); ++ + static int ConvertFromPyObject(PyObject *, typval_T *); + static int _ConvertFromPyObject(PyObject *, typval_T *, PyObject *); + static PyObject *WindowNew(win_T *, tabpage_T *); +*************** +*** 39,44 **** +--- 42,49 ---- + static PyInt RangeStart; + static PyInt RangeEnd; + ++ static PyObject *globals; ++ + /* + * obtain a lock on the Vim data structures + */ +*************** +*** 1296,1302 **** + FunctionObject *this = (FunctionObject *) (self); + + func_unref(this->name); +! PyMem_Del(this->name); + + DESTRUCTOR_FINISH(self); + } +--- 1301,1307 ---- + FunctionObject *this = (FunctionObject *) (self); + + func_unref(this->name); +! PyMem_Free(this->name); + + DESTRUCTOR_FINISH(self); + } +*************** +*** 3432,3437 **** +--- 3437,3562 ---- + } + + static void ++ init_range_cmd(exarg_T *eap) ++ { ++ RangeStart = eap->line1; ++ RangeEnd = eap->line2; ++ } ++ ++ static void ++ init_range_eval(typval_T *rettv UNUSED) ++ { ++ RangeStart = (PyInt) curwin->w_cursor.lnum; ++ RangeEnd = RangeStart; ++ } ++ ++ static void ++ run_cmd(const char *cmd, void *arg UNUSED, PyGILState_STATE *pygilstate UNUSED) ++ { ++ PyRun_SimpleString((char *) cmd); ++ } ++ ++ static const char *code_hdr = "def " DOPY_FUNC "(line, linenr):\n "; ++ static int code_hdr_len = 30; ++ ++ static void ++ run_do(const char *cmd, void *arg UNUSED, PyGILState_STATE *pygilstate) ++ { ++ PyInt lnum; ++ size_t len; ++ char *code; ++ int status; ++ PyObject *pyfunc, *pymain; ++ ++ if (u_save(RangeStart - 1, RangeEnd + 1) != OK) ++ { ++ EMSG(_("cannot save undo information")); ++ return; ++ } ++ ++ len = code_hdr_len + STRLEN(cmd); ++ code = PyMem_New(char, len + 1); ++ memcpy(code, code_hdr, code_hdr_len); ++ STRCPY(code + code_hdr_len, cmd); ++ status = PyRun_SimpleString(code); ++ PyMem_Free(code); ++ ++ if (status) ++ { ++ EMSG(_("failed to run the code")); ++ return; ++ } ++ ++ status = 0; ++ pymain = PyImport_AddModule("__main__"); ++ pyfunc = PyObject_GetAttrString(pymain, DOPY_FUNC); ++ PyGILState_Release(*pygilstate); ++ ++ for (lnum = RangeStart; lnum <= RangeEnd; ++lnum) ++ { ++ PyObject *line, *linenr, *ret; ++ ++ *pygilstate = PyGILState_Ensure(); ++ if (!(line = GetBufferLine(curbuf, lnum))) ++ goto err; ++ if (!(linenr = PyInt_FromLong((long) lnum))) ++ { ++ Py_DECREF(line); ++ goto err; ++ } ++ ret = PyObject_CallFunctionObjArgs(pyfunc, line, linenr, NULL); ++ Py_DECREF(line); ++ Py_DECREF(linenr); ++ if (!ret) ++ goto err; ++ ++ if (ret != Py_None) ++ if (SetBufferLine(curbuf, lnum, ret, NULL) == FAIL) ++ goto err; ++ ++ Py_XDECREF(ret); ++ PythonIO_Flush(); ++ PyGILState_Release(*pygilstate); ++ } ++ goto out; ++ err: ++ *pygilstate = PyGILState_Ensure(); ++ PyErr_PrintEx(0); ++ PythonIO_Flush(); ++ status = 1; ++ out: ++ if (!status) ++ *pygilstate = PyGILState_Ensure(); ++ Py_DECREF(pyfunc); ++ PyObject_SetAttrString(pymain, DOPY_FUNC, NULL); ++ if (status) ++ return; ++ check_cursor(); ++ update_curbuf(NOT_VALID); ++ } ++ ++ static void ++ run_eval(const char *cmd, typval_T *rettv, PyGILState_STATE *pygilstate UNUSED) ++ { ++ PyObject *r; ++ ++ r = PyRun_String((char *) cmd, Py_eval_input, globals, globals); ++ if (r == NULL) ++ { ++ if (PyErr_Occurred() && !msg_silent) ++ PyErr_PrintEx(0); ++ EMSG(_("E858: Eval did not return a valid python object")); ++ } ++ else ++ { ++ if (ConvertFromPyObject(r, rettv) == -1) ++ EMSG(_("E859: Failed to convert returned python object to vim value")); ++ Py_DECREF(r); ++ } ++ PyErr_Clear(); ++ } ++ ++ static void + set_ref_in_py(const int copyID) + { + pylinkedlist_T *cur; +*** ../vim-7.3.990/src/if_python3.c 2013-05-17 16:39:59.000000000 +0200 +--- src/if_python3.c 2013-05-21 18:07:39.000000000 +0200 +*************** +*** 703,710 **** + * Internal function prototypes. + */ + +- static PyObject *globals; +- + static int PythonIO_Init(void); + static PyObject *Py3Init_vim(void); + +--- 703,708 ---- +*************** +*** 827,833 **** + * External interface + */ + static void +! DoPy3Command(exarg_T *eap, const char *cmd, typval_T *rettv) + { + #if defined(MACOS) && !defined(MACOS_X_UNIX) + GrafPtr oldPort; +--- 825,831 ---- + * External interface + */ + static void +! DoPyCommand(const char *cmd, rangeinitializer init_range, runner run, void *arg) + { + #if defined(MACOS) && !defined(MACOS_X_UNIX) + GrafPtr oldPort; +*************** +*** 848,863 **** + if (Python3_Init()) + goto theend; + +! if (rettv == NULL) +! { +! RangeStart = eap->line1; +! RangeEnd = eap->line2; +! } +! else +! { +! RangeStart = (PyInt) curwin->w_cursor.lnum; +! RangeEnd = RangeStart; +! } + Python_Release_Vim(); /* leave vim */ + + #if defined(HAVE_LOCALE_H) || defined(X_LOCALE) +--- 846,853 ---- + if (Python3_Init()) + goto theend; + +! init_range(arg); +! + Python_Release_Vim(); /* leave vim */ + + #if defined(HAVE_LOCALE_H) || defined(X_LOCALE) +*************** +*** 881,908 **** + (char *)ENC_OPT, CODEC_ERROR_HANDLER); + cmdbytes = PyUnicode_AsEncodedString(cmdstr, "utf-8", CODEC_ERROR_HANDLER); + Py_XDECREF(cmdstr); +- if (rettv == NULL) +- PyRun_SimpleString(PyBytes_AsString(cmdbytes)); +- else +- { +- PyObject *r; + +! r = PyRun_String(PyBytes_AsString(cmdbytes), Py_eval_input, +! globals, globals); +! if (r == NULL) +! { +! if (PyErr_Occurred() && !msg_silent) +! PyErr_PrintEx(0); +! EMSG(_("E860: Eval did not return a valid python 3 object")); +! } +! else +! { +! if (ConvertFromPyObject(r, rettv) == -1) +! EMSG(_("E861: Failed to convert returned python 3 object to vim value")); +! Py_DECREF(r); +! } +! PyErr_Clear(); +! } + Py_XDECREF(cmdbytes); + + PyGILState_Release(pygilstate); +--- 871,878 ---- + (char *)ENC_OPT, CODEC_ERROR_HANDLER); + cmdbytes = PyUnicode_AsEncodedString(cmdstr, "utf-8", CODEC_ERROR_HANDLER); + Py_XDECREF(cmdstr); + +! run(PyBytes_AsString(cmdbytes), arg, &pygilstate); + Py_XDECREF(cmdbytes); + + PyGILState_Release(pygilstate); +*************** +*** 936,945 **** + script = script_get(eap, eap->arg); + if (!eap->skip) + { +! if (script == NULL) +! DoPy3Command(eap, (char *)eap->arg, NULL); +! else +! DoPy3Command(eap, (char *)script, NULL); + } + vim_free(script); + } +--- 906,915 ---- + script = script_get(eap, eap->arg); + if (!eap->skip) + { +! DoPyCommand(script == NULL ? (char *) eap->arg : (char *) script, +! (rangeinitializer) init_range_cmd, +! (runner) run_cmd, +! (void *) eap); + } + vim_free(script); + } +*************** +*** 1000,1100 **** + + + /* Execute the file */ +! DoPy3Command(eap, buffer, NULL); + } + + void + ex_py3do(exarg_T *eap) + { +! linenr_T i; +! const char *code_hdr = "def " DOPY_FUNC "(line, linenr):\n "; +! const char *s = (const char *) eap->arg; +! size_t len; +! char *code; +! int status; +! PyObject *pyfunc, *pymain; +! PyGILState_STATE pygilstate; +! +! if (Python3_Init()) +! goto theend; +! +! if (u_save(eap->line1 - 1, eap->line2 + 1) != OK) +! { +! EMSG(_("cannot save undo information")); +! return; +! } +! len = strlen(code_hdr) + strlen(s); +! code = malloc(len + 1); +! STRCPY(code, code_hdr); +! STRNCAT(code, s, len + 1); +! pygilstate = PyGILState_Ensure(); +! status = PyRun_SimpleString(code); +! vim_free(code); +! if (status) +! { +! EMSG(_("failed to run the code")); +! return; +! } +! status = 0; /* good */ +! pymain = PyImport_AddModule("__main__"); +! pyfunc = PyObject_GetAttrString(pymain, DOPY_FUNC); +! PyGILState_Release(pygilstate); +! +! for (i = eap->line1; i <= eap->line2; i++) +! { +! const char *line; +! PyObject *pyline, *pylinenr, *pyret, *pybytes; +! +! line = (char *)ml_get(i); +! pygilstate = PyGILState_Ensure(); +! pyline = PyUnicode_Decode(line, strlen(line), +! (char *)ENC_OPT, CODEC_ERROR_HANDLER); +! pylinenr = PyLong_FromLong(i); +! pyret = PyObject_CallFunctionObjArgs(pyfunc, pyline, pylinenr, NULL); +! Py_DECREF(pyline); +! Py_DECREF(pylinenr); +! if (!pyret) +! { +! PyErr_PrintEx(0); +! PythonIO_Flush(); +! status = 1; +! goto out; +! } +! +! if (pyret && pyret != Py_None) +! { +! if (!PyUnicode_Check(pyret)) +! { +! EMSG(_("E863: return value must be an instance of str")); +! Py_XDECREF(pyret); +! status = 1; +! goto out; +! } +! pybytes = PyUnicode_AsEncodedString(pyret, +! (char *)ENC_OPT, CODEC_ERROR_HANDLER); +! ml_replace(i, (char_u *) PyBytes_AsString(pybytes), 1); +! Py_DECREF(pybytes); +! changed(); +! #ifdef SYNTAX_HL +! syn_changed(i); /* recompute syntax hl. for this line */ +! #endif +! } +! Py_XDECREF(pyret); +! PythonIO_Flush(); +! PyGILState_Release(pygilstate); +! } +! pygilstate = PyGILState_Ensure(); +! out: +! Py_DECREF(pyfunc); +! PyObject_SetAttrString(pymain, DOPY_FUNC, NULL); +! PyGILState_Release(pygilstate); +! if (status) +! return; +! check_cursor(); +! update_curbuf(NOT_VALID); +! +! theend: +! return; + } + + /****************************************************** +--- 970,988 ---- + + + /* Execute the file */ +! DoPyCommand(buffer, +! (rangeinitializer) init_range_cmd, +! (runner) run_cmd, +! (void *) eap); + } + + void + ex_py3do(exarg_T *eap) + { +! DoPyCommand((char *)eap->arg, +! (rangeinitializer)init_range_cmd, +! (runner)run_do, +! (void *)eap); + } + + /****************************************************** +*************** +*** 1790,1796 **** + void + do_py3eval (char_u *str, typval_T *rettv) + { +! DoPy3Command(NULL, (char *) str, rettv); + switch(rettv->v_type) + { + case VAR_DICT: ++rettv->vval.v_dict->dv_refcount; break; +--- 1678,1687 ---- + void + do_py3eval (char_u *str, typval_T *rettv) + { +! DoPyCommand((char *) str, +! (rangeinitializer) init_range_eval, +! (runner) run_eval, +! (void *) rettv); + switch(rettv->v_type) + { + case VAR_DICT: ++rettv->vval.v_dict->dv_refcount; break; +*** ../vim-7.3.990/src/if_python.c 2013-05-17 16:39:59.000000000 +0200 +--- src/if_python.c 2013-05-21 18:07:11.000000000 +0200 +*************** +*** 659,666 **** + * Internal function prototypes. + */ + +- static PyObject *globals; +- + static void PythonIO_Flush(void); + static int PythonIO_Init(void); + static int PythonMod_Init(void); +--- 659,664 ---- +*************** +*** 828,834 **** + * External interface + */ + static void +! DoPythonCommand(exarg_T *eap, const char *cmd, typval_T *rettv) + { + #ifndef PY_CAN_RECURSE + static int recursive = 0; +--- 826,832 ---- + * External interface + */ + static void +! DoPyCommand(const char *cmd, rangeinitializer init_range, runner run, void *arg) + { + #ifndef PY_CAN_RECURSE + static int recursive = 0; +*************** +*** 861,876 **** + if (Python_Init()) + goto theend; + +! if (rettv == NULL) +! { +! RangeStart = eap->line1; +! RangeEnd = eap->line2; +! } +! else +! { +! RangeStart = (PyInt) curwin->w_cursor.lnum; +! RangeEnd = RangeStart; +! } + Python_Release_Vim(); /* leave vim */ + + #if defined(HAVE_LOCALE_H) || defined(X_LOCALE) +--- 859,866 ---- + if (Python_Init()) + goto theend; + +! init_range(arg); +! + Python_Release_Vim(); /* leave vim */ + + #if defined(HAVE_LOCALE_H) || defined(X_LOCALE) +*************** +*** 892,918 **** + Python_RestoreThread(); /* enter python */ + #endif + +! if (rettv == NULL) +! PyRun_SimpleString((char *)(cmd)); +! else +! { +! PyObject *r; +! +! r = PyRun_String((char *)(cmd), Py_eval_input, globals, globals); +! if (r == NULL) +! { +! if (PyErr_Occurred() && !msg_silent) +! PyErr_PrintEx(0); +! EMSG(_("E858: Eval did not return a valid python object")); +! } +! else +! { +! if (ConvertFromPyObject(r, rettv) == -1) +! EMSG(_("E859: Failed to convert returned python object to vim value")); +! Py_DECREF(r); +! } +! PyErr_Clear(); +! } + + #ifdef PY_CAN_RECURSE + PyGILState_Release(pygilstate); +--- 882,888 ---- + Python_RestoreThread(); /* enter python */ + #endif + +! run((char *) cmd, arg, &pygilstate); + + #ifdef PY_CAN_RECURSE + PyGILState_Release(pygilstate); +*************** +*** 952,961 **** + script = script_get(eap, eap->arg); + if (!eap->skip) + { +! if (script == NULL) +! DoPythonCommand(eap, (char *)eap->arg, NULL); +! else +! DoPythonCommand(eap, (char *)script, NULL); + } + vim_free(script); + } +--- 922,931 ---- + script = script_get(eap, eap->arg); + if (!eap->skip) + { +! DoPyCommand(script == NULL ? (char *) eap->arg : (char *) script, +! (rangeinitializer) init_range_cmd, +! (runner) run_cmd, +! (void *) eap); + } + vim_free(script); + } +*************** +*** 1001,1094 **** + *p++ = '\0'; + + /* Execute the file */ +! DoPythonCommand(eap, buffer, NULL); + } + + void + ex_pydo(exarg_T *eap) + { +! linenr_T i; +! const char *code_hdr = "def " DOPY_FUNC "(line, linenr):\n "; +! const char *s = (const char *) eap->arg; +! size_t len; +! char *code; +! int status; +! PyObject *pyfunc, *pymain; +! PyGILState_STATE pygilstate; +! +! if (Python_Init()) +! return; +! +! if (u_save(eap->line1 - 1, eap->line2 + 1) != OK) +! { +! EMSG(_("cannot save undo information")); +! return; +! } +! len = strlen(code_hdr) + strlen(s); +! code = malloc(len + 1); +! STRCPY(code, code_hdr); +! STRNCAT(code, s, len + 1); +! pygilstate = PyGILState_Ensure(); +! status = PyRun_SimpleString(code); +! vim_free(code); +! if (status) +! { +! EMSG(_("failed to run the code")); +! return; +! } +! status = 0; /* good */ +! pymain = PyImport_AddModule("__main__"); +! pyfunc = PyObject_GetAttrString(pymain, DOPY_FUNC); +! PyGILState_Release(pygilstate); +! +! for (i = eap->line1; i <= eap->line2; i++) +! { +! const char *line; +! PyObject *pyline, *pylinenr, *pyret; +! +! line = (char *)ml_get(i); +! pygilstate = PyGILState_Ensure(); +! pyline = PyString_FromStringAndSize(line, strlen(line)); +! pylinenr = PyLong_FromLong(i); +! pyret = PyObject_CallFunctionObjArgs(pyfunc, pyline, pylinenr, NULL); +! Py_DECREF(pyline); +! Py_DECREF(pylinenr); +! if (!pyret) +! { +! PyErr_PrintEx(0); +! PythonIO_Flush(); +! status = 1; +! goto out; +! } +! +! if (pyret && pyret != Py_None) +! { +! if (!PyString_Check(pyret)) +! { +! EMSG(_("E863: return value must be an instance of str")); +! Py_XDECREF(pyret); +! status = 1; +! goto out; +! } +! ml_replace(i, (char_u *) PyString_AsString(pyret), 1); +! changed(); +! #ifdef SYNTAX_HL +! syn_changed(i); /* recompute syntax hl. for this line */ +! #endif +! } +! Py_XDECREF(pyret); +! PythonIO_Flush(); +! PyGILState_Release(pygilstate); +! } +! pygilstate = PyGILState_Ensure(); +! out: +! Py_DECREF(pyfunc); +! PyObject_SetAttrString(pymain, DOPY_FUNC, NULL); +! PyGILState_Release(pygilstate); +! if (status) +! return; +! check_cursor(); +! update_curbuf(NOT_VALID); + } + + /****************************************************** +--- 971,989 ---- + *p++ = '\0'; + + /* Execute the file */ +! DoPyCommand(buffer, +! (rangeinitializer) init_range_cmd, +! (runner) run_cmd, +! (void *) eap); + } + + void + ex_pydo(exarg_T *eap) + { +! DoPyCommand((char *)eap->arg, +! (rangeinitializer) init_range_cmd, +! (runner)run_do, +! (void *)eap); + } + + /****************************************************** +*************** +*** 1525,1531 **** + void + do_pyeval (char_u *str, typval_T *rettv) + { +! DoPythonCommand(NULL, (char *) str, rettv); + switch(rettv->v_type) + { + case VAR_DICT: ++rettv->vval.v_dict->dv_refcount; break; +--- 1420,1429 ---- + void + do_pyeval (char_u *str, typval_T *rettv) + { +! DoPyCommand((char *) str, +! (rangeinitializer) init_range_eval, +! (runner) run_eval, +! (void *) rettv); + switch(rettv->v_type) + { + case VAR_DICT: ++rettv->vval.v_dict->dv_refcount; break; +*** ../vim-7.3.990/src/testdir/test87.ok 2013-05-17 16:18:27.000000000 +0200 +--- src/testdir/test87.ok 2013-05-21 17:59:56.000000000 +0200 +*************** +*** 59,68 **** + ['c', 1] + ['d', ['e']] + 0.0 +! "\0": Vim(let):E861: +! {"\0": 1}: Vim(let):E861: + undefined_name: Vim(let):Trace +! vim: Vim(let):E861: + [1] + [1, 10, 11, 10, 11, 10, 11, 10, 11, 10, 11, 10, 1] + Abc +--- 59,68 ---- + ['c', 1] + ['d', ['e']] + 0.0 +! "\0": Vim(let):E859: +! {"\0": 1}: Vim(let):E859: + undefined_name: Vim(let):Trace +! vim: Vim(let):E859: + [1] + [1, 10, 11, 10, 11, 10, 11, 10, 11, 10, 11, 10, 1] + Abc +*** ../vim-7.3.990/src/version.c 2013-05-21 16:28:05.000000000 +0200 +--- src/version.c 2013-05-21 18:19:20.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 991, + /**/ + +-- +Mynd you, m00se bites Kan be pretty nasti ... + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// diff --git a/7.3.992 b/7.3.992 new file mode 100644 index 00000000..f3f233bb --- /dev/null +++ b/7.3.992 @@ -0,0 +1,2719 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.992 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.992 +Problem: Python: Too many type casts. +Solution: Change argument types. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c + + +*** ../vim-7.3.991/src/if_py_both.h 2013-05-21 18:19:33.000000000 +0200 +--- src/if_py_both.h 2013-05-21 18:22:03.000000000 +0200 +*************** +*** 76,82 **** + } OutputObject; + + static int +! OutputSetattr(PyObject *self, char *name, PyObject *val) + { + if (val == NULL) + { +--- 76,82 ---- + } OutputObject; + + static int +! OutputSetattr(OutputObject *self, char *name, PyObject *val) + { + if (val == NULL) + { +*************** +*** 93,99 **** + return -1; + } + +! ((OutputObject *)(self))->softspace = PyInt_AsLong(val); + return 0; + } + +--- 93,99 ---- + return -1; + } + +! self->softspace = PyInt_AsLong(val); + return 0; + } + +*************** +*** 152,162 **** + } + + static PyObject * +! OutputWrite(PyObject *self, PyObject *args) + { + Py_ssize_t len = 0; + char *str = NULL; +! int error = ((OutputObject *)(self))->error; + + if (!PyArg_ParseTuple(args, "et#", ENC_OPT, &str, &len)) + return NULL; +--- 152,162 ---- + } + + static PyObject * +! OutputWrite(OutputObject *self, PyObject *args) + { + Py_ssize_t len = 0; + char *str = NULL; +! int error = self->error; + + if (!PyArg_ParseTuple(args, "et#", ENC_OPT, &str, &len)) + return NULL; +*************** +*** 173,184 **** + } + + static PyObject * +! OutputWritelines(PyObject *self, PyObject *args) + { + PyInt n; + PyInt i; + PyObject *list; +! int error = ((OutputObject *)(self))->error; + + if (!PyArg_ParseTuple(args, "O", &list)) + return NULL; +--- 173,184 ---- + } + + static PyObject * +! OutputWritelines(OutputObject *self, PyObject *args) + { + PyInt n; + PyInt i; + PyObject *list; +! int error = self->error; + + if (!PyArg_ParseTuple(args, "O", &list)) + return NULL; +*************** +*** 220,226 **** + } + + static PyObject * +! OutputFlush(PyObject *self UNUSED, PyObject *args UNUSED) + { + /* do nothing */ + Py_INCREF(Py_None); +--- 220,226 ---- + } + + static PyObject * +! OutputFlush(PyObject *self UNUSED) + { + /* do nothing */ + Py_INCREF(Py_None); +*************** +*** 230,240 **** + /***************/ + + static struct PyMethodDef OutputMethods[] = { +! /* name, function, calling, documentation */ +! {"write", OutputWrite, 1, ""}, +! {"writelines", OutputWritelines, 1, ""}, +! {"flush", OutputFlush, 1, ""}, +! { NULL, NULL, 0, NULL} + }; + + static OutputObject Output = +--- 230,240 ---- + /***************/ + + static struct PyMethodDef OutputMethods[] = { +! /* name, function, calling, doc */ +! {"write", (PyCFunction)OutputWrite, METH_VARARGS, ""}, +! {"writelines", (PyCFunction)OutputWritelines, METH_VARARGS, ""}, +! {"flush", (PyCFunction)OutputFlush, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL} + }; + + static OutputObject Output = +*************** +*** 533,544 **** + */ + + static struct PyMethodDef VimMethods[] = { +! /* name, function, calling, documentation */ +! {"command", VimCommand, 1, "Execute a Vim ex-mode command" }, +! {"eval", VimEval, 1, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, 1, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, 1, "Screen string width, counts as having width 1"}, +! { NULL, NULL, 0, NULL } + }; + + /* +--- 533,544 ---- + */ + + static struct PyMethodDef VimMethods[] = { +! /* name, function, calling, documentation */ +! {"command", VimCommand, METH_VARARGS, "Execute a Vim ex-mode command" }, +! {"eval", VimEval, METH_VARARGS, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, METH_VARARGS, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, METH_VARARGS, "Screen string width, counts as having width 1"}, +! { NULL, NULL, 0, NULL } + }; + + /* +*************** +*** 583,604 **** + } + + static void +! IterDestructor(PyObject *self) + { +! IterObject *this = (IterObject *)(self); +! +! this->destruct(this->cur); + + DESTRUCTOR_FINISH(self); + } + + static int +! IterTraverse(PyObject *self, visitproc visit, void *arg) + { +! IterObject *this = (IterObject *)(self); +! +! if (this->traverse != NULL) +! return this->traverse(this->cur, visit, arg); + else + return 0; + } +--- 583,600 ---- + } + + static void +! IterDestructor(IterObject *self) + { +! self->destruct(self->cur); + + DESTRUCTOR_FINISH(self); + } + + static int +! IterTraverse(IterObject *self, visitproc visit, void *arg) + { +! if (self->traverse != NULL) +! return self->traverse(self->cur, visit, arg); + else + return 0; + } +*************** +*** 609,630 **** + #endif + + static int +! IterClear(PyObject *self) + { +! IterObject *this = (IterObject *)(self); +! +! if (this->clear != NULL) +! return this->clear(&this->cur); + else + return 0; + } + + static PyObject * +! IterNext(PyObject *self) + { +! IterObject *this = (IterObject *)(self); +! +! return this->next(&this->cur); + } + + static PyObject * +--- 605,622 ---- + #endif + + static int +! IterClear(IterObject *self) + { +! if (self->clear != NULL) +! return self->clear(&self->cur); + else + return 0; + } + + static PyObject * +! IterNext(IterObject *self) + { +! return self->next(&self->cur); + } + + static PyObject * +*************** +*** 711,731 **** + } + + static void +! DictionaryDestructor(PyObject *self) + { +! DictionaryObject *this = ((DictionaryObject *) (self)); +! +! pyll_remove(&this->ref, &lastdict); +! dict_unref(this->dict); + + DESTRUCTOR_FINISH(self); + } + + static int +! DictionarySetattr(PyObject *self, char *name, PyObject *val) + { +- DictionaryObject *this = (DictionaryObject *)(self); +- + if (val == NULL) + { + PyErr_SetString(PyExc_AttributeError, _("Cannot delete DictionaryObject attributes")); +--- 703,719 ---- + } + + static void +! DictionaryDestructor(DictionaryObject *self) + { +! pyll_remove(&self->ref, &lastdict); +! dict_unref(self->dict); + + DESTRUCTOR_FINISH(self); + } + + static int +! DictionarySetattr(DictionaryObject *self, char *name, PyObject *val) + { + if (val == NULL) + { + PyErr_SetString(PyExc_AttributeError, _("Cannot delete DictionaryObject attributes")); +*************** +*** 734,740 **** + + if (strcmp(name, "locked") == 0) + { +! if (this->dict->dv_lock == VAR_FIXED) + { + PyErr_SetString(PyExc_TypeError, _("Cannot modify fixed dictionary")); + return -1; +--- 722,728 ---- + + if (strcmp(name, "locked") == 0) + { +! if (self->dict->dv_lock == VAR_FIXED) + { + PyErr_SetString(PyExc_TypeError, _("Cannot modify fixed dictionary")); + return -1; +*************** +*** 745,753 **** + if (istrue == -1) + return -1; + else if (istrue) +! this->dict->dv_lock = VAR_LOCKED; + else +! this->dict->dv_lock = 0; + } + return 0; + } +--- 733,741 ---- + if (istrue == -1) + return -1; + else if (istrue) +! self->dict->dv_lock = VAR_LOCKED; + else +! self->dict->dv_lock = 0; + } + return 0; + } +*************** +*** 759,771 **** + } + + static PyInt +! DictionaryLength(PyObject *self) + { +! return ((PyInt) ((((DictionaryObject *)(self))->dict->dv_hashtab.ht_used))); + } + + static PyObject * +! DictionaryItem(PyObject *self, PyObject *keyObject) + { + char_u *key; + dictitem_T *di; +--- 747,759 ---- + } + + static PyInt +! DictionaryLength(DictionaryObject *self) + { +! return ((PyInt) (self->dict->dv_hashtab.ht_used)); + } + + static PyObject * +! DictionaryItem(DictionaryObject *self, PyObject *keyObject) + { + char_u *key; + dictitem_T *di; +*************** +*** 773,779 **** + + DICTKEY_GET_NOTEMPTY(NULL) + +! di = dict_find(((DictionaryObject *) (self))->dict, key, -1); + + DICTKEY_UNREF + +--- 761,767 ---- + + DICTKEY_GET_NOTEMPTY(NULL) + +! di = dict_find(self->dict, key, -1); + + DICTKEY_UNREF + +*************** +*** 787,797 **** + } + + static PyInt +! DictionaryAssItem(PyObject *self, PyObject *keyObject, PyObject *valObject) + { + char_u *key; + typval_T tv; +! dict_T *d = ((DictionaryObject *)(self))->dict; + dictitem_T *di; + DICTKEY_DECL + +--- 775,785 ---- + } + + static PyInt +! DictionaryAssItem(DictionaryObject *self, PyObject *keyObject, PyObject *valObject) + { + char_u *key; + typval_T tv; +! dict_T *d = self->dict; + dictitem_T *di; + DICTKEY_DECL + +*************** +*** 852,860 **** + } + + static PyObject * +! DictionaryListKeys(PyObject *self UNUSED) + { +! dict_T *dict = ((DictionaryObject *)(self))->dict; + long_u todo = dict->dv_hashtab.ht_used; + Py_ssize_t i = 0; + PyObject *r; +--- 840,848 ---- + } + + static PyObject * +! DictionaryListKeys(DictionaryObject *self) + { +! dict_T *dict = self->dict; + long_u todo = dict->dv_hashtab.ht_used; + Py_ssize_t i = 0; + PyObject *r; +*************** +*** 880,887 **** + }; + + static struct PyMethodDef DictionaryMethods[] = { +! {"keys", (PyCFunction)DictionaryListKeys, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL } + }; + + static PyTypeObject ListType; +--- 868,875 ---- + }; + + static struct PyMethodDef DictionaryMethods[] = { +! {"keys", (PyCFunction)DictionaryListKeys, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL } + }; + + static PyTypeObject ListType; +*************** +*** 912,923 **** + } + + static void +! ListDestructor(PyObject *self) + { +! ListObject *this = (ListObject *)(self); +! +! pyll_remove(&this->ref, &lastlist); +! list_unref(this->list); + + DESTRUCTOR_FINISH(self); + } +--- 900,909 ---- + } + + static void +! ListDestructor(ListObject *self) + { +! pyll_remove(&self->ref, &lastlist); +! list_unref(self->list); + + DESTRUCTOR_FINISH(self); + } +*************** +*** 952,973 **** + } + + static PyInt +! ListLength(PyObject *self) + { +! return ((PyInt) (((ListObject *) (self))->list->lv_len)); + } + + static PyObject * +! ListItem(PyObject *self, Py_ssize_t index) + { + listitem_T *li; + +! if (index>=ListLength(self)) + { + PyErr_SetString(PyExc_IndexError, _("list index out of range")); + return NULL; + } +! li = list_find(((ListObject *) (self))->list, (long) index); + if (li == NULL) + { + PyErr_SetVim(_("internal error: failed to get vim list item")); +--- 938,959 ---- + } + + static PyInt +! ListLength(ListObject *self) + { +! return ((PyInt) (self->list->lv_len)); + } + + static PyObject * +! ListItem(ListObject *self, Py_ssize_t index) + { + listitem_T *li; + +! if (index >= ListLength(self)) + { + PyErr_SetString(PyExc_IndexError, _("list index out of range")); + return NULL; + } +! li = list_find(self->list, (long) index); + if (li == NULL) + { + PyErr_SetVim(_("internal error: failed to get vim list item")); +*************** +*** 991,997 **** + last = size; + + static PyObject * +! ListSlice(PyObject *self, Py_ssize_t first, Py_ssize_t last) + { + PyInt i; + PyInt size = ListLength(self); +--- 977,983 ---- + last = size; + + static PyObject * +! ListSlice(ListObject *self, Py_ssize_t first, Py_ssize_t last) + { + PyInt i; + PyInt size = ListLength(self); +*************** +*** 1058,1067 **** + } + + static PyObject * +! ListIter(PyObject *self) + { + listiterinfo_T *lii; +! list_T *l = ((ListObject *) (self))->list; + + if (!(lii = PyMem_New(listiterinfo_T, 1))) + { +--- 1044,1053 ---- + } + + static PyObject * +! ListIter(ListObject *self) + { + listiterinfo_T *lii; +! list_T *l = self->list; + + if (!(lii = PyMem_New(listiterinfo_T, 1))) + { +*************** +*** 1079,1088 **** + } + + static int +! ListAssItem(PyObject *self, Py_ssize_t index, PyObject *obj) + { + typval_T tv; +! list_T *l = ((ListObject *) (self))->list; + listitem_T *li; + Py_ssize_t length = ListLength(self); + +--- 1065,1074 ---- + } + + static int +! ListAssItem(ListObject *self, Py_ssize_t index, PyObject *obj) + { + typval_T tv; +! list_T *l = self->list; + listitem_T *li; + Py_ssize_t length = ListLength(self); + +*************** +*** 1127,1133 **** + } + + static int +! ListAssSlice(PyObject *self, Py_ssize_t first, Py_ssize_t last, PyObject *obj) + { + PyInt size = ListLength(self); + Py_ssize_t i; +--- 1113,1119 ---- + } + + static int +! ListAssSlice(ListObject *self, Py_ssize_t first, Py_ssize_t last, PyObject *obj) + { + PyInt size = ListLength(self); + Py_ssize_t i; +*************** +*** 1136,1142 **** + listitem_T *li; + listitem_T *next; + typval_T v; +! list_T *l = ((ListObject *) (self))->list; + + if (l->lv_lock) + { +--- 1122,1128 ---- + listitem_T *li; + listitem_T *next; + typval_T v; +! list_T *l = self->list; + + if (l->lv_lock) + { +*************** +*** 1196,1204 **** + } + + static PyObject * +! ListConcatInPlace(PyObject *self, PyObject *obj) + { +! list_T *l = ((ListObject *) (self))->list; + PyObject *lookup_dict; + + if (l->lv_lock) +--- 1182,1190 ---- + } + + static PyObject * +! ListConcatInPlace(ListObject *self, PyObject *obj) + { +! list_T *l = self->list; + PyObject *lookup_dict; + + if (l->lv_lock) +*************** +*** 1222,1235 **** + Py_DECREF(lookup_dict); + + Py_INCREF(self); +! return self; + } + + static int +! ListSetattr(PyObject *self, char *name, PyObject *val) + { +- ListObject *this = (ListObject *)(self); +- + if (val == NULL) + { + PyErr_SetString(PyExc_AttributeError, +--- 1208,1219 ---- + Py_DECREF(lookup_dict); + + Py_INCREF(self); +! return (PyObject *)(self); + } + + static int +! ListSetattr(ListObject *self, char *name, PyObject *val) + { + if (val == NULL) + { + PyErr_SetString(PyExc_AttributeError, +*************** +*** 1239,1245 **** + + if (strcmp(name, "locked") == 0) + { +! if (this->list->lv_lock == VAR_FIXED) + { + PyErr_SetString(PyExc_TypeError, _("cannot modify fixed list")); + return -1; +--- 1223,1229 ---- + + if (strcmp(name, "locked") == 0) + { +! if (self->list->lv_lock == VAR_FIXED) + { + PyErr_SetString(PyExc_TypeError, _("cannot modify fixed list")); + return -1; +*************** +*** 1250,1258 **** + if (istrue == -1) + return -1; + else if (istrue) +! this->list->lv_lock = VAR_LOCKED; + else +! this->list->lv_lock = 0; + } + return 0; + } +--- 1234,1242 ---- + if (istrue == -1) + return -1; + else if (istrue) +! self->list->lv_lock = VAR_LOCKED; + else +! self->list->lv_lock = 0; + } + return 0; + } +*************** +*** 1264,1271 **** + } + + static struct PyMethodDef ListMethods[] = { +! {"extend", (PyCFunction)ListConcatInPlace, METH_O, ""}, +! { NULL, NULL, 0, NULL } + }; + + typedef struct +--- 1248,1255 ---- + } + + static struct PyMethodDef ListMethods[] = { +! {"extend", (PyCFunction)ListConcatInPlace, METH_O, ""}, +! { NULL, NULL, 0, NULL } + }; + + typedef struct +*************** +*** 1296,1316 **** + } + + static void +! FunctionDestructor(PyObject *self) + { +! FunctionObject *this = (FunctionObject *) (self); +! +! func_unref(this->name); +! PyMem_Free(this->name); + + DESTRUCTOR_FINISH(self); + } + + static PyObject * +! FunctionCall(PyObject *self, PyObject *argsObject, PyObject *kwargs) + { +! FunctionObject *this = (FunctionObject *)(self); +! char_u *name = this->name; + typval_T args; + typval_T selfdicttv; + typval_T rettv; +--- 1280,1297 ---- + } + + static void +! FunctionDestructor(FunctionObject *self) + { +! func_unref(self->name); +! PyMem_Free(self->name); + + DESTRUCTOR_FINISH(self); + } + + static PyObject * +! FunctionCall(FunctionObject *self, PyObject *argsObject, PyObject *kwargs) + { +! char_u *name = self->name; + typval_T args; + typval_T selfdicttv; + typval_T rettv; +*************** +*** 1368,1375 **** + } + + static struct PyMethodDef FunctionMethods[] = { +! {"__call__", (PyCFunction)FunctionCall, METH_VARARGS|METH_KEYWORDS, ""}, +! { NULL, NULL, 0, NULL } + }; + + /* +--- 1349,1356 ---- + } + + static struct PyMethodDef FunctionMethods[] = { +! {"__call__", (PyCFunction)FunctionCall, METH_VARARGS|METH_KEYWORDS, ""}, +! { NULL, NULL, 0, NULL} + }; + + /* +*************** +*** 1415,1443 **** + } + + static void +! OptionsDestructor(PyObject *self) + { +! if (((OptionsObject *)(self))->fromObj) +! Py_DECREF(((OptionsObject *)(self))->fromObj); + DESTRUCTOR_FINISH(self); + } + + static int +! OptionsTraverse(PyObject *self, visitproc visit, void *arg) + { +! Py_VISIT(((OptionsObject *)(self))->fromObj); + return 0; + } + + static int +! OptionsClear(PyObject *self) + { +! Py_CLEAR(((OptionsObject *)(self))->fromObj); + return 0; + } + + static PyObject * +! OptionsItem(OptionsObject *this, PyObject *keyObject) + { + char_u *key; + int flags; +--- 1396,1424 ---- + } + + static void +! OptionsDestructor(OptionsObject *self) + { +! if (self->fromObj) +! Py_DECREF(self->fromObj); + DESTRUCTOR_FINISH(self); + } + + static int +! OptionsTraverse(OptionsObject *self, visitproc visit, void *arg) + { +! Py_VISIT(self->fromObj); + return 0; + } + + static int +! OptionsClear(OptionsObject *self) + { +! Py_CLEAR(self->fromObj); + return 0; + } + + static PyObject * +! OptionsItem(OptionsObject *self, PyObject *keyObject) + { + char_u *key; + int flags; +*************** +*** 1445,1457 **** + char_u *stringval; + DICTKEY_DECL + +! if (this->Check(this->from)) + return NULL; + + DICTKEY_GET_NOTEMPTY(NULL) + + flags = get_option_value_strict(key, &numval, &stringval, +! this->opt_type, this->from); + + DICTKEY_UNREF + +--- 1426,1438 ---- + char_u *stringval; + DICTKEY_DECL + +! if (self->Check(self->from)) + return NULL; + + DICTKEY_GET_NOTEMPTY(NULL) + + flags = get_option_value_strict(key, &numval, &stringval, +! self->opt_type, self->from); + + DICTKEY_UNREF + +*************** +*** 1532,1538 **** + } + + static int +! OptionsAssItem(OptionsObject *this, PyObject *keyObject, PyObject *valObject) + { + char_u *key; + int flags; +--- 1513,1519 ---- + } + + static int +! OptionsAssItem(OptionsObject *self, PyObject *keyObject, PyObject *valObject) + { + char_u *key; + int flags; +*************** +*** 1540,1552 **** + int r = 0; + DICTKEY_DECL + +! if (this->Check(this->from)) + return -1; + + DICTKEY_GET_NOTEMPTY(-1) + + flags = get_option_value_strict(key, NULL, NULL, +! this->opt_type, this->from); + + DICTKEY_UNREF + +--- 1521,1533 ---- + int r = 0; + DICTKEY_DECL + +! if (self->Check(self->from)) + return -1; + + DICTKEY_GET_NOTEMPTY(-1) + + flags = get_option_value_strict(key, NULL, NULL, +! self->opt_type, self->from); + + DICTKEY_UNREF + +*************** +*** 1558,1564 **** + + if (valObject == NULL) + { +! if (this->opt_type == SREQ_GLOBAL) + { + PyErr_SetString(PyExc_ValueError, + _("unable to unset global option")); +--- 1539,1545 ---- + + if (valObject == NULL) + { +! if (self->opt_type == SREQ_GLOBAL) + { + PyErr_SetString(PyExc_ValueError, + _("unable to unset global option")); +*************** +*** 1572,1583 **** + } + else + { +! unset_global_local_option(key, this->from); + return 0; + } + } + +! opt_flags = (this->opt_type ? OPT_LOCAL : OPT_GLOBAL); + + if (flags & SOPT_BOOL) + { +--- 1553,1564 ---- + } + else + { +! unset_global_local_option(key, self->from); + return 0; + } + } + +! opt_flags = (self->opt_type ? OPT_LOCAL : OPT_GLOBAL); + + if (flags & SOPT_BOOL) + { +*************** +*** 1585,1591 **** + if (istrue == -1) + return -1; + r = set_option_value_for(key, istrue, NULL, +! opt_flags, this->opt_type, this->from); + } + else if (flags & SOPT_NUM) + { +--- 1566,1572 ---- + if (istrue == -1) + return -1; + r = set_option_value_for(key, istrue, NULL, +! opt_flags, self->opt_type, self->from); + } + else if (flags & SOPT_NUM) + { +*************** +*** 1605,1611 **** + } + + r = set_option_value_for(key, val, NULL, opt_flags, +! this->opt_type, this->from); + } + else + { +--- 1586,1592 ---- + } + + r = set_option_value_for(key, val, NULL, opt_flags, +! self->opt_type, self->from); + } + else + { +*************** +*** 1643,1649 **** + } + + r = set_option_value_for(key, 0, val, opt_flags, +! this->opt_type, this->from); + vim_free(val); + } + +--- 1624,1630 ---- + } + + r = set_option_value_for(key, 0, val, opt_flags, +! self->opt_type, self->from); + vim_free(val); + } + +*************** +*** 1670,1678 **** + static PyTypeObject TabPageType; + + static int +! CheckTabPage(TabPageObject *this) + { +! if (this->tab == INVALID_TABPAGE_VALUE) + { + PyErr_SetVim(_("attempt to refer to deleted tab page")); + return -1; +--- 1651,1659 ---- + static PyTypeObject TabPageType; + + static int +! CheckTabPage(TabPageObject *self) + { +! if (self->tab == INVALID_TABPAGE_VALUE) + { + PyErr_SetVim(_("attempt to refer to deleted tab page")); + return -1; +*************** +*** 1704,1754 **** + } + + static void +! TabPageDestructor(PyObject *self) + { +! TabPageObject *this = (TabPageObject *)(self); +! +! if (this->tab && this->tab != INVALID_TABPAGE_VALUE) +! TAB_PYTHON_REF(this->tab) = NULL; + + DESTRUCTOR_FINISH(self); + } + + static PyObject * +! TabPageAttr(TabPageObject *this, char *name) + { + if (strcmp(name, "windows") == 0) +! return WinListNew(this); + else if (strcmp(name, "number") == 0) +! return PyLong_FromLong((long) get_tab_number(this->tab)); + else if (strcmp(name, "vars") == 0) +! return DictionaryNew(this->tab->tp_vars); + else if (strcmp(name, "window") == 0) + { + /* For current tab window.c does not bother to set or update tp_curwin + */ +! if (this->tab == curtab) + return WindowNew(curwin, curtab); + else +! return WindowNew(this->tab->tp_curwin, this->tab); + } + return NULL; + } + + static PyObject * +! TabPageRepr(PyObject *self) + { + static char repr[100]; +- TabPageObject *this = (TabPageObject *)(self); + +! if (this->tab == INVALID_TABPAGE_VALUE) + { + vim_snprintf(repr, 100, _(""), (self)); + return PyString_FromString(repr); + } + else + { +! int t = get_tab_number(this->tab); + + if (t == 0) + vim_snprintf(repr, 100, _(""), +--- 1685,1732 ---- + } + + static void +! TabPageDestructor(TabPageObject *self) + { +! if (self->tab && self->tab != INVALID_TABPAGE_VALUE) +! TAB_PYTHON_REF(self->tab) = NULL; + + DESTRUCTOR_FINISH(self); + } + + static PyObject * +! TabPageAttr(TabPageObject *self, char *name) + { + if (strcmp(name, "windows") == 0) +! return WinListNew(self); + else if (strcmp(name, "number") == 0) +! return PyLong_FromLong((long) get_tab_number(self->tab)); + else if (strcmp(name, "vars") == 0) +! return DictionaryNew(self->tab->tp_vars); + else if (strcmp(name, "window") == 0) + { + /* For current tab window.c does not bother to set or update tp_curwin + */ +! if (self->tab == curtab) + return WindowNew(curwin, curtab); + else +! return WindowNew(self->tab->tp_curwin, self->tab); + } + return NULL; + } + + static PyObject * +! TabPageRepr(TabPageObject *self) + { + static char repr[100]; + +! if (self->tab == INVALID_TABPAGE_VALUE) + { + vim_snprintf(repr, 100, _(""), (self)); + return PyString_FromString(repr); + } + else + { +! int t = get_tab_number(self->tab); + + if (t == 0) + vim_snprintf(repr, 100, _(""), +*************** +*** 1818,1826 **** + static PyTypeObject WindowType; + + static int +! CheckWindow(WindowObject *this) + { +! if (this->win == INVALID_WINDOW_VALUE) + { + PyErr_SetVim(_("attempt to refer to deleted window")); + return -1; +--- 1796,1804 ---- + static PyTypeObject WindowType; + + static int +! CheckWindow(WindowObject *self) + { +! if (self->win == INVALID_WINDOW_VALUE) + { + PyErr_SetVim(_("attempt to refer to deleted window")); + return -1; +*************** +*** 1869,1882 **** + } + + static void +! WindowDestructor(PyObject *self) + { +! WindowObject *this = (WindowObject *)(self); +! +! if (this->win && this->win != INVALID_WINDOW_VALUE) +! WIN_PYTHON_REF(this->win) = NULL; + +! Py_DECREF(((PyObject *)(this->tabObject))); + + DESTRUCTOR_FINISH(self); + } +--- 1847,1858 ---- + } + + static void +! WindowDestructor(WindowObject *self) + { +! if (self->win && self->win != INVALID_WINDOW_VALUE) +! WIN_PYTHON_REF(self->win) = NULL; + +! Py_DECREF(((PyObject *)(self->tabObject))); + + DESTRUCTOR_FINISH(self); + } +*************** +*** 1899,1956 **** + return firstwin; + } + static int +! WindowTraverse(PyObject *self, visitproc visit, void *arg) + { +! Py_VISIT(((PyObject *)(((WindowObject *)(self))->tabObject))); + return 0; + } + + static int +! WindowClear(PyObject *self) + { +! Py_CLEAR((((WindowObject *)(self))->tabObject)); + return 0; + } + + static PyObject * +! WindowAttr(WindowObject *this, char *name) + { + if (strcmp(name, "buffer") == 0) +! return (PyObject *)BufferNew(this->win->w_buffer); + else if (strcmp(name, "cursor") == 0) + { +! pos_T *pos = &this->win->w_cursor; + + return Py_BuildValue("(ll)", (long)(pos->lnum), (long)(pos->col)); + } + else if (strcmp(name, "height") == 0) +! return PyLong_FromLong((long)(this->win->w_height)); + #ifdef FEAT_WINDOWS + else if (strcmp(name, "row") == 0) +! return PyLong_FromLong((long)(this->win->w_winrow)); + #endif + #ifdef FEAT_VERTSPLIT + else if (strcmp(name, "width") == 0) +! return PyLong_FromLong((long)(W_WIDTH(this->win))); + else if (strcmp(name, "col") == 0) +! return PyLong_FromLong((long)(W_WINCOL(this->win))); + #endif + else if (strcmp(name, "vars") == 0) +! return DictionaryNew(this->win->w_vars); + else if (strcmp(name, "options") == 0) +! return OptionsNew(SREQ_WIN, this->win, (checkfun) CheckWindow, +! (PyObject *) this); + else if (strcmp(name, "number") == 0) + { +! if (CheckTabPage(this->tabObject)) + return NULL; + return PyLong_FromLong((long) +! get_win_number(this->win, get_firstwin(this->tabObject))); + } + else if (strcmp(name, "tabpage") == 0) + { +! Py_INCREF(this->tabObject); +! return (PyObject *)(this->tabObject); + } + else if (strcmp(name,"__members__") == 0) + return Py_BuildValue("[sssssssss]", "buffer", "cursor", "height", +--- 1875,1932 ---- + return firstwin; + } + static int +! WindowTraverse(WindowObject *self, visitproc visit, void *arg) + { +! Py_VISIT(((PyObject *)(self->tabObject))); + return 0; + } + + static int +! WindowClear(WindowObject *self) + { +! Py_CLEAR(self->tabObject); + return 0; + } + + static PyObject * +! WindowAttr(WindowObject *self, char *name) + { + if (strcmp(name, "buffer") == 0) +! return (PyObject *)BufferNew(self->win->w_buffer); + else if (strcmp(name, "cursor") == 0) + { +! pos_T *pos = &self->win->w_cursor; + + return Py_BuildValue("(ll)", (long)(pos->lnum), (long)(pos->col)); + } + else if (strcmp(name, "height") == 0) +! return PyLong_FromLong((long)(self->win->w_height)); + #ifdef FEAT_WINDOWS + else if (strcmp(name, "row") == 0) +! return PyLong_FromLong((long)(self->win->w_winrow)); + #endif + #ifdef FEAT_VERTSPLIT + else if (strcmp(name, "width") == 0) +! return PyLong_FromLong((long)(W_WIDTH(self->win))); + else if (strcmp(name, "col") == 0) +! return PyLong_FromLong((long)(W_WINCOL(self->win))); + #endif + else if (strcmp(name, "vars") == 0) +! return DictionaryNew(self->win->w_vars); + else if (strcmp(name, "options") == 0) +! return OptionsNew(SREQ_WIN, self->win, (checkfun) CheckWindow, +! (PyObject *) self); + else if (strcmp(name, "number") == 0) + { +! if (CheckTabPage(self->tabObject)) + return NULL; + return PyLong_FromLong((long) +! get_win_number(self->win, get_firstwin(self->tabObject))); + } + else if (strcmp(name, "tabpage") == 0) + { +! Py_INCREF(self->tabObject); +! return (PyObject *)(self->tabObject); + } + else if (strcmp(name,"__members__") == 0) + return Py_BuildValue("[sssssssss]", "buffer", "cursor", "height", +*************** +*** 1960,1970 **** + } + + static int +! WindowSetattr(PyObject *self, char *name, PyObject *val) + { +! WindowObject *this = (WindowObject *)(self); +! +! if (CheckWindow(this)) + return -1; + + if (strcmp(name, "buffer") == 0) +--- 1936,1944 ---- + } + + static int +! WindowSetattr(WindowObject *self, char *name, PyObject *val) + { +! if (CheckWindow(self)) + return -1; + + if (strcmp(name, "buffer") == 0) +*************** +*** 1980,1986 **** + if (!PyArg_Parse(val, "(ll)", &lnum, &col)) + return -1; + +! if (lnum <= 0 || lnum > this->win->w_buffer->b_ml.ml_line_count) + { + PyErr_SetVim(_("cursor position outside buffer")); + return -1; +--- 1954,1960 ---- + if (!PyArg_Parse(val, "(ll)", &lnum, &col)) + return -1; + +! if (lnum <= 0 || lnum > self->win->w_buffer->b_ml.ml_line_count) + { + PyErr_SetVim(_("cursor position outside buffer")); + return -1; +*************** +*** 1990,2002 **** + if (VimErrorCheck()) + return -1; + +! this->win->w_cursor.lnum = lnum; +! this->win->w_cursor.col = col; + #ifdef FEAT_VIRTUALEDIT +! this->win->w_cursor.coladd = 0; + #endif + /* When column is out of range silently correct it. */ +! check_cursor_col_win(this->win); + + update_screen(VALID); + return 0; +--- 1964,1976 ---- + if (VimErrorCheck()) + return -1; + +! self->win->w_cursor.lnum = lnum; +! self->win->w_cursor.col = col; + #ifdef FEAT_VIRTUALEDIT +! self->win->w_cursor.coladd = 0; + #endif + /* When column is out of range silently correct it. */ +! check_cursor_col_win(self->win); + + update_screen(VALID); + return 0; +*************** +*** 2013,2019 **** + need_mouse_correct = TRUE; + #endif + savewin = curwin; +! curwin = this->win; + win_setheight(height); + curwin = savewin; + +--- 1987,1993 ---- + need_mouse_correct = TRUE; + #endif + savewin = curwin; +! curwin = self->win; + win_setheight(height); + curwin = savewin; + +*************** +*** 2036,2042 **** + need_mouse_correct = TRUE; + #endif + savewin = curwin; +! curwin = this->win; + win_setwidth(width); + curwin = savewin; + +--- 2010,2016 ---- + need_mouse_correct = TRUE; + #endif + savewin = curwin; +! curwin = self->win; + win_setwidth(width); + curwin = savewin; + +*************** +*** 2055,2073 **** + } + + static PyObject * +! WindowRepr(PyObject *self) + { + static char repr[100]; +- WindowObject *this = (WindowObject *)(self); + +! if (this->win == INVALID_WINDOW_VALUE) + { + vim_snprintf(repr, 100, _(""), (self)); + return PyString_FromString(repr); + } + else + { +! int w = get_win_number(this->win, firstwin); + + if (w == 0) + vim_snprintf(repr, 100, _(""), +--- 2029,2046 ---- + } + + static PyObject * +! WindowRepr(WindowObject *self) + { + static char repr[100]; + +! if (self->win == INVALID_WINDOW_VALUE) + { + vim_snprintf(repr, 100, _(""), (self)); + return PyString_FromString(repr); + } + else + { +! int w = get_win_number(self->win, firstwin); + + if (w == 0) + vim_snprintf(repr, 100, _(""), +*************** +*** 2110,2118 **** + } + + static void +! WinListDestructor(PyObject *self) + { +! TabPageObject *tabObject = ((WinListObject *)(self))->tabObject; + + if (tabObject) + Py_DECREF((PyObject *)(tabObject)); +--- 2083,2091 ---- + } + + static void +! WinListDestructor(WinListObject *self) + { +! TabPageObject *tabObject = self->tabObject; + + if (tabObject) + Py_DECREF((PyObject *)(tabObject)); +*************** +*** 2121,2132 **** + } + + static PyInt +! WinListLength(PyObject *self) + { + win_T *w; + PyInt n = 0; + +! if (!(w = get_firstwin(((WinListObject *)(self))->tabObject))) + return -1; + + while (w != NULL) +--- 2094,2105 ---- + } + + static PyInt +! WinListLength(WinListObject *self) + { + win_T *w; + PyInt n = 0; + +! if (!(w = get_firstwin(self->tabObject))) + return -1; + + while (w != NULL) +*************** +*** 2139,2155 **** + } + + static PyObject * +! WinListItem(PyObject *self, PyInt n) + { +- WinListObject *this = ((WinListObject *)(self)); + win_T *w; + +! if (!(w = get_firstwin(this->tabObject))) + return NULL; + + for (; w != NULL; w = W_NEXT(w), --n) + if (n == 0) +! return WindowNew(w, this->tabObject? this->tabObject->tab: curtab); + + PyErr_SetString(PyExc_IndexError, _("no such window")); + return NULL; +--- 2112,2127 ---- + } + + static PyObject * +! WinListItem(WinListObject *self, PyInt n) + { + win_T *w; + +! if (!(w = get_firstwin(self->tabObject))) + return NULL; + + for (; w != NULL; w = W_NEXT(w), --n) + if (n == 0) +! return WindowNew(w, self->tabObject? self->tabObject->tab: curtab); + + PyErr_SetString(PyExc_IndexError, _("no such window")); + return NULL; +*************** +*** 2721,2729 **** + } BufferObject; + + static int +! CheckBuffer(BufferObject *this) + { +! if (this->buf == INVALID_BUFFER_VALUE) + { + PyErr_SetVim(_("attempt to refer to deleted buffer")); + return -1; +--- 2693,2701 ---- + } BufferObject; + + static int +! CheckBuffer(BufferObject *self) + { +! if (self->buf == INVALID_BUFFER_VALUE) + { + PyErr_SetVim(_("attempt to refer to deleted buffer")); + return -1; +*************** +*** 2922,2975 **** + } + + static void +! RangeDestructor(PyObject *self) + { +! Py_DECREF(((RangeObject *)(self))->buf); + DESTRUCTOR_FINISH(self); + } + + static PyInt +! RangeLength(PyObject *self) + { + /* HOW DO WE SIGNAL AN ERROR FROM THIS FUNCTION? */ +! if (CheckBuffer(((RangeObject *)(self))->buf)) + return -1; /* ??? */ + +! return (((RangeObject *)(self))->end - ((RangeObject *)(self))->start + 1); + } + + static PyObject * +! RangeItem(PyObject *self, PyInt n) + { +! return RBItem(((RangeObject *)(self))->buf, n, +! ((RangeObject *)(self))->start, +! ((RangeObject *)(self))->end); + } + + static PyObject * +! RangeSlice(PyObject *self, PyInt lo, PyInt hi) + { +! return RBSlice(((RangeObject *)(self))->buf, lo, hi, +! ((RangeObject *)(self))->start, +! ((RangeObject *)(self))->end); + } + + static PyObject * +! RangeAppend(PyObject *self, PyObject *args) + { +! return RBAppend(((RangeObject *)(self))->buf, args, +! ((RangeObject *)(self))->start, +! ((RangeObject *)(self))->end, +! &((RangeObject *)(self))->end); + } + + static PyObject * +! RangeRepr(PyObject *self) + { + static char repr[100]; +- RangeObject *this = (RangeObject *)(self); + +! if (this->buf->buf == INVALID_BUFFER_VALUE) + { + vim_snprintf(repr, 100, "", + (self)); +--- 2894,2939 ---- + } + + static void +! RangeDestructor(RangeObject *self) + { +! Py_DECREF(self->buf); + DESTRUCTOR_FINISH(self); + } + + static PyInt +! RangeLength(RangeObject *self) + { + /* HOW DO WE SIGNAL AN ERROR FROM THIS FUNCTION? */ +! if (CheckBuffer(self->buf)) + return -1; /* ??? */ + +! return (self->end - self->start + 1); + } + + static PyObject * +! RangeItem(RangeObject *self, PyInt n) + { +! return RBItem(self->buf, n, self->start, self->end); + } + + static PyObject * +! RangeSlice(RangeObject *self, PyInt lo, PyInt hi) + { +! return RBSlice(self->buf, lo, hi, self->start, self->end); + } + + static PyObject * +! RangeAppend(RangeObject *self, PyObject *args) + { +! return RBAppend(self->buf, args, self->start, self->end, &self->end); + } + + static PyObject * +! RangeRepr(RangeObject *self) + { + static char repr[100]; + +! if (self->buf->buf == INVALID_BUFFER_VALUE) + { + vim_snprintf(repr, 100, "", + (self)); +*************** +*** 2977,2983 **** + } + else + { +! char *name = (char *)this->buf->buf->b_fname; + int len; + + if (name == NULL) +--- 2941,2947 ---- + } + else + { +! char *name = (char *)self->buf->buf->b_fname; + int len; + + if (name == NULL) +*************** +*** 2989,3004 **** + + vim_snprintf(repr, 100, "", + len > 45 ? "..." : "", name, +! this->start, this->end); + + return PyString_FromString(repr); + } + } + + static struct PyMethodDef RangeMethods[] = { +! /* name, function, calling, documentation */ +! {"append", RangeAppend, 1, "Append data to the Vim range" }, +! { NULL, NULL, 0, NULL } + }; + + static PyTypeObject BufferType; +--- 2953,2968 ---- + + vim_snprintf(repr, 100, "", + len > 45 ? "..." : "", name, +! self->start, self->end); + + return PyString_FromString(repr); + } + } + + static struct PyMethodDef RangeMethods[] = { +! /* name, function, calling, documentation */ +! {"append", (PyCFunction)RangeAppend, METH_VARARGS, "Append data to the Vim range" }, +! { NULL, NULL, 0, NULL } + }; + + static PyTypeObject BufferType; +*************** +*** 3045,3094 **** + } + + static void +! BufferDestructor(PyObject *self) + { +! BufferObject *this = (BufferObject *)(self); +! +! if (this->buf && this->buf != INVALID_BUFFER_VALUE) +! BUF_PYTHON_REF(this->buf) = NULL; + + DESTRUCTOR_FINISH(self); + } + + static PyInt +! BufferLength(PyObject *self) + { + /* HOW DO WE SIGNAL AN ERROR FROM THIS FUNCTION? */ +! if (CheckBuffer((BufferObject *)(self))) + return -1; /* ??? */ + +! return (PyInt)(((BufferObject *)(self))->buf->b_ml.ml_line_count); + } + + static PyObject * +! BufferItem(PyObject *self, PyInt n) + { +! return RBItem((BufferObject *)(self), n, 1, -1); + } + + static PyObject * +! BufferSlice(PyObject *self, PyInt lo, PyInt hi) + { +! return RBSlice((BufferObject *)(self), lo, hi, 1, -1); + } + + static PyObject * +! BufferAttr(BufferObject *this, char *name) + { + if (strcmp(name, "name") == 0) +! return Py_BuildValue("s", this->buf->b_ffname); + else if (strcmp(name, "number") == 0) +! return Py_BuildValue(Py_ssize_t_fmt, this->buf->b_fnum); + else if (strcmp(name, "vars") == 0) +! return DictionaryNew(this->buf->b_vars); + else if (strcmp(name, "options") == 0) +! return OptionsNew(SREQ_BUF, this->buf, (checkfun) CheckBuffer, +! (PyObject *) this); + else if (strcmp(name,"__members__") == 0) + return Py_BuildValue("[ssss]", "name", "number", "vars", "options"); + else +--- 3009,3056 ---- + } + + static void +! BufferDestructor(BufferObject *self) + { +! if (self->buf && self->buf != INVALID_BUFFER_VALUE) +! BUF_PYTHON_REF(self->buf) = NULL; + + DESTRUCTOR_FINISH(self); + } + + static PyInt +! BufferLength(BufferObject *self) + { + /* HOW DO WE SIGNAL AN ERROR FROM THIS FUNCTION? */ +! if (CheckBuffer(self)) + return -1; /* ??? */ + +! return (PyInt)(self->buf->b_ml.ml_line_count); + } + + static PyObject * +! BufferItem(BufferObject *self, PyInt n) + { +! return RBItem(self, n, 1, -1); + } + + static PyObject * +! BufferSlice(BufferObject *self, PyInt lo, PyInt hi) + { +! return RBSlice(self, lo, hi, 1, -1); + } + + static PyObject * +! BufferAttr(BufferObject *self, char *name) + { + if (strcmp(name, "name") == 0) +! return Py_BuildValue("s", self->buf->b_ffname); + else if (strcmp(name, "number") == 0) +! return Py_BuildValue(Py_ssize_t_fmt, self->buf->b_fnum); + else if (strcmp(name, "vars") == 0) +! return DictionaryNew(self->buf->b_vars); + else if (strcmp(name, "options") == 0) +! return OptionsNew(SREQ_BUF, self->buf, (checkfun) CheckBuffer, +! (PyObject *) self); + else if (strcmp(name,"__members__") == 0) + return Py_BuildValue("[ssss]", "name", "number", "vars", "options"); + else +*************** +*** 3096,3122 **** + } + + static PyObject * +! BufferAppend(PyObject *self, PyObject *args) + { +! return RBAppend((BufferObject *)(self), args, 1, -1, NULL); + } + + static PyObject * +! BufferMark(PyObject *self, PyObject *args) + { + pos_T *posp; + char *pmark; + char mark; + buf_T *savebuf; + +! if (CheckBuffer((BufferObject *)(self))) + return NULL; + + if (!PyArg_ParseTuple(args, "s", &pmark)) + return NULL; + mark = *pmark; + +! switch_buffer(&savebuf, ((BufferObject *)(self))->buf); + posp = getmark(mark, FALSE); + restore_buffer(savebuf); + +--- 3058,3084 ---- + } + + static PyObject * +! BufferAppend(BufferObject *self, PyObject *args) + { +! return RBAppend(self, args, 1, -1, NULL); + } + + static PyObject * +! BufferMark(BufferObject *self, PyObject *args) + { + pos_T *posp; + char *pmark; + char mark; + buf_T *savebuf; + +! if (CheckBuffer(self)) + return NULL; + + if (!PyArg_ParseTuple(args, "s", &pmark)) + return NULL; + mark = *pmark; + +! switch_buffer(&savebuf, self->buf); + posp = getmark(mark, FALSE); + restore_buffer(savebuf); + +*************** +*** 3141,3174 **** + } + + static PyObject * +! BufferRange(PyObject *self, PyObject *args) + { + PyInt start; + PyInt end; + +! if (CheckBuffer((BufferObject *)(self))) + return NULL; + + if (!PyArg_ParseTuple(args, "nn", &start, &end)) + return NULL; + +! return RangeNew(((BufferObject *)(self))->buf, start, end); + } + + static PyObject * +! BufferRepr(PyObject *self) + { + static char repr[100]; +- BufferObject *this = (BufferObject *)(self); + +! if (this->buf == INVALID_BUFFER_VALUE) + { + vim_snprintf(repr, 100, _(""), (self)); + return PyString_FromString(repr); + } + else + { +! char *name = (char *)this->buf->b_fname; + PyInt len; + + if (name == NULL) +--- 3103,3135 ---- + } + + static PyObject * +! BufferRange(BufferObject *self, PyObject *args) + { + PyInt start; + PyInt end; + +! if (CheckBuffer(self)) + return NULL; + + if (!PyArg_ParseTuple(args, "nn", &start, &end)) + return NULL; + +! return RangeNew(self->buf, start, end); + } + + static PyObject * +! BufferRepr(BufferObject *self) + { + static char repr[100]; + +! if (self->buf == INVALID_BUFFER_VALUE) + { + vim_snprintf(repr, 100, _(""), (self)); + return PyString_FromString(repr); + } + else + { +! char *name = (char *)self->buf->b_fname; + PyInt len; + + if (name == NULL) +*************** +*** 3185,3198 **** + } + + static struct PyMethodDef BufferMethods[] = { +! /* name, function, calling, documentation */ +! {"append", BufferAppend, 1, "Append data to Vim buffer" }, +! {"mark", BufferMark, 1, "Return (row,col) representing position of named mark" }, +! {"range", BufferRange, 1, "Return a range object which represents the part of the given buffer between line numbers s and e" }, + #if PY_VERSION_HEX >= 0x03000000 +! {"__dir__", BufferDir, 4, "List its attributes" }, + #endif +! { NULL, NULL, 0, NULL } + }; + + /* +--- 3146,3159 ---- + } + + static struct PyMethodDef BufferMethods[] = { +! /* name, function, calling, documentation */ +! {"append", (PyCFunction)BufferAppend, METH_VARARGS, "Append data to Vim buffer" }, +! {"mark", (PyCFunction)BufferMark, METH_VARARGS, "Return (row,col) representing position of named mark" }, +! {"range", (PyCFunction)BufferRange, METH_VARARGS, "Return a range object which represents the part of the given buffer between line numbers s and e" }, + #if PY_VERSION_HEX >= 0x03000000 +! {"__dir__", (PyCFunction)BufferDir, METH_NOARGS, "List buffer attributes" }, + #endif +! { NULL, NULL, 0, NULL } + }; + + /* +*************** +*** 4021,4034 **** + OutputType.tp_doc = "vim message object"; + OutputType.tp_methods = OutputMethods; + #if PY_MAJOR_VERSION >= 3 +! OutputType.tp_getattro = OutputGetattro; +! OutputType.tp_setattro = OutputSetattro; + OutputType.tp_alloc = call_PyType_GenericAlloc; + OutputType.tp_new = call_PyType_GenericNew; + OutputType.tp_free = call_PyObject_Free; + #else +! OutputType.tp_getattr = OutputGetattr; +! OutputType.tp_setattr = OutputSetattr; + #endif + + vim_memset(&IterType, 0, sizeof(IterType)); +--- 3982,3995 ---- + OutputType.tp_doc = "vim message object"; + OutputType.tp_methods = OutputMethods; + #if PY_MAJOR_VERSION >= 3 +! OutputType.tp_getattro = (getattrofunc)OutputGetattro; +! OutputType.tp_setattro = (setattrofunc)OutputSetattro; + OutputType.tp_alloc = call_PyType_GenericAlloc; + OutputType.tp_new = call_PyType_GenericNew; + OutputType.tp_free = call_PyObject_Free; + #else +! OutputType.tp_getattr = (getattrfunc)OutputGetattr; +! OutputType.tp_setattr = (setattrfunc)OutputSetattr; + #endif + + vim_memset(&IterType, 0, sizeof(IterType)); +*************** +*** 4036,4102 **** + IterType.tp_basicsize = sizeof(IterObject); + IterType.tp_flags = Py_TPFLAGS_DEFAULT; + IterType.tp_doc = "generic iterator object"; +! IterType.tp_iter = IterIter; +! IterType.tp_iternext = IterNext; +! IterType.tp_dealloc = IterDestructor; +! IterType.tp_traverse = IterTraverse; +! IterType.tp_clear = IterClear; + + vim_memset(&BufferType, 0, sizeof(BufferType)); + BufferType.tp_name = "vim.buffer"; + BufferType.tp_basicsize = sizeof(BufferType); +! BufferType.tp_dealloc = BufferDestructor; +! BufferType.tp_repr = BufferRepr; + BufferType.tp_as_sequence = &BufferAsSeq; + BufferType.tp_as_mapping = &BufferAsMapping; + BufferType.tp_flags = Py_TPFLAGS_DEFAULT; + BufferType.tp_doc = "vim buffer object"; + BufferType.tp_methods = BufferMethods; + #if PY_MAJOR_VERSION >= 3 +! BufferType.tp_getattro = BufferGetattro; + BufferType.tp_alloc = call_PyType_GenericAlloc; + BufferType.tp_new = call_PyType_GenericNew; + BufferType.tp_free = call_PyObject_Free; + #else +! BufferType.tp_getattr = BufferGetattr; + #endif + + vim_memset(&WindowType, 0, sizeof(WindowType)); + WindowType.tp_name = "vim.window"; + WindowType.tp_basicsize = sizeof(WindowObject); +! WindowType.tp_dealloc = WindowDestructor; +! WindowType.tp_repr = WindowRepr; + WindowType.tp_flags = Py_TPFLAGS_DEFAULT; + WindowType.tp_doc = "vim Window object"; + WindowType.tp_methods = WindowMethods; +! WindowType.tp_traverse = WindowTraverse; +! WindowType.tp_clear = WindowClear; + #if PY_MAJOR_VERSION >= 3 +! WindowType.tp_getattro = WindowGetattro; +! WindowType.tp_setattro = WindowSetattro; + WindowType.tp_alloc = call_PyType_GenericAlloc; + WindowType.tp_new = call_PyType_GenericNew; + WindowType.tp_free = call_PyObject_Free; + #else +! WindowType.tp_getattr = WindowGetattr; +! WindowType.tp_setattr = WindowSetattr; + #endif + + vim_memset(&TabPageType, 0, sizeof(TabPageType)); + TabPageType.tp_name = "vim.tabpage"; + TabPageType.tp_basicsize = sizeof(TabPageObject); +! TabPageType.tp_dealloc = TabPageDestructor; +! TabPageType.tp_repr = TabPageRepr; + TabPageType.tp_flags = Py_TPFLAGS_DEFAULT; + TabPageType.tp_doc = "vim tab page object"; + TabPageType.tp_methods = TabPageMethods; + #if PY_MAJOR_VERSION >= 3 +! TabPageType.tp_getattro = TabPageGetattro; + TabPageType.tp_alloc = call_PyType_GenericAlloc; + TabPageType.tp_new = call_PyType_GenericNew; + TabPageType.tp_free = call_PyObject_Free; + #else +! TabPageType.tp_getattr = TabPageGetattr; + #endif + + vim_memset(&BufMapType, 0, sizeof(BufMapType)); +--- 3997,4063 ---- + IterType.tp_basicsize = sizeof(IterObject); + IterType.tp_flags = Py_TPFLAGS_DEFAULT; + IterType.tp_doc = "generic iterator object"; +! IterType.tp_iter = (getiterfunc)IterIter; +! IterType.tp_iternext = (iternextfunc)IterNext; +! IterType.tp_dealloc = (destructor)IterDestructor; +! IterType.tp_traverse = (traverseproc)IterTraverse; +! IterType.tp_clear = (inquiry)IterClear; + + vim_memset(&BufferType, 0, sizeof(BufferType)); + BufferType.tp_name = "vim.buffer"; + BufferType.tp_basicsize = sizeof(BufferType); +! BufferType.tp_dealloc = (destructor)BufferDestructor; +! BufferType.tp_repr = (reprfunc)BufferRepr; + BufferType.tp_as_sequence = &BufferAsSeq; + BufferType.tp_as_mapping = &BufferAsMapping; + BufferType.tp_flags = Py_TPFLAGS_DEFAULT; + BufferType.tp_doc = "vim buffer object"; + BufferType.tp_methods = BufferMethods; + #if PY_MAJOR_VERSION >= 3 +! BufferType.tp_getattro = (getattrofunc)BufferGetattro; + BufferType.tp_alloc = call_PyType_GenericAlloc; + BufferType.tp_new = call_PyType_GenericNew; + BufferType.tp_free = call_PyObject_Free; + #else +! BufferType.tp_getattr = (getattrfunc)BufferGetattr; + #endif + + vim_memset(&WindowType, 0, sizeof(WindowType)); + WindowType.tp_name = "vim.window"; + WindowType.tp_basicsize = sizeof(WindowObject); +! WindowType.tp_dealloc = (destructor)WindowDestructor; +! WindowType.tp_repr = (reprfunc)WindowRepr; + WindowType.tp_flags = Py_TPFLAGS_DEFAULT; + WindowType.tp_doc = "vim Window object"; + WindowType.tp_methods = WindowMethods; +! WindowType.tp_traverse = (traverseproc)WindowTraverse; +! WindowType.tp_clear = (inquiry)WindowClear; + #if PY_MAJOR_VERSION >= 3 +! WindowType.tp_getattro = (getattrofunc)WindowGetattro; +! WindowType.tp_setattro = (setattrofunc)WindowSetattro; + WindowType.tp_alloc = call_PyType_GenericAlloc; + WindowType.tp_new = call_PyType_GenericNew; + WindowType.tp_free = call_PyObject_Free; + #else +! WindowType.tp_getattr = (getattrfunc)WindowGetattr; +! WindowType.tp_setattr = (setattrfunc)WindowSetattr; + #endif + + vim_memset(&TabPageType, 0, sizeof(TabPageType)); + TabPageType.tp_name = "vim.tabpage"; + TabPageType.tp_basicsize = sizeof(TabPageObject); +! TabPageType.tp_dealloc = (destructor)TabPageDestructor; +! TabPageType.tp_repr = (reprfunc)TabPageRepr; + TabPageType.tp_flags = Py_TPFLAGS_DEFAULT; + TabPageType.tp_doc = "vim tab page object"; + TabPageType.tp_methods = TabPageMethods; + #if PY_MAJOR_VERSION >= 3 +! TabPageType.tp_getattro = (getattrofunc)TabPageGetattro; + TabPageType.tp_alloc = call_PyType_GenericAlloc; + TabPageType.tp_new = call_PyType_GenericNew; + TabPageType.tp_free = call_PyObject_Free; + #else +! TabPageType.tp_getattr = (getattrfunc)TabPageGetattr; + #endif + + vim_memset(&BufMapType, 0, sizeof(BufMapType)); +*************** +*** 4113,4119 **** + WinListType.tp_as_sequence = &WinListAsSeq; + WinListType.tp_flags = Py_TPFLAGS_DEFAULT; + WinListType.tp_doc = "vim window list"; +! WinListType.tp_dealloc = WinListDestructor; + + vim_memset(&TabListType, 0, sizeof(TabListType)); + TabListType.tp_name = "vim.tabpagelist"; +--- 4074,4080 ---- + WinListType.tp_as_sequence = &WinListAsSeq; + WinListType.tp_flags = Py_TPFLAGS_DEFAULT; + WinListType.tp_doc = "vim window list"; +! WinListType.tp_dealloc = (destructor)WinListDestructor; + + vim_memset(&TabListType, 0, sizeof(TabListType)); + TabListType.tp_name = "vim.tabpagelist"; +*************** +*** 4125,4144 **** + vim_memset(&RangeType, 0, sizeof(RangeType)); + RangeType.tp_name = "vim.range"; + RangeType.tp_basicsize = sizeof(RangeObject); +! RangeType.tp_dealloc = RangeDestructor; +! RangeType.tp_repr = RangeRepr; + RangeType.tp_as_sequence = &RangeAsSeq; + RangeType.tp_as_mapping = &RangeAsMapping; + RangeType.tp_flags = Py_TPFLAGS_DEFAULT; + RangeType.tp_doc = "vim Range object"; + RangeType.tp_methods = RangeMethods; + #if PY_MAJOR_VERSION >= 3 +! RangeType.tp_getattro = RangeGetattro; + RangeType.tp_alloc = call_PyType_GenericAlloc; + RangeType.tp_new = call_PyType_GenericNew; + RangeType.tp_free = call_PyObject_Free; + #else +! RangeType.tp_getattr = RangeGetattr; + #endif + + vim_memset(&CurrentType, 0, sizeof(CurrentType)); +--- 4086,4105 ---- + vim_memset(&RangeType, 0, sizeof(RangeType)); + RangeType.tp_name = "vim.range"; + RangeType.tp_basicsize = sizeof(RangeObject); +! RangeType.tp_dealloc = (destructor)RangeDestructor; +! RangeType.tp_repr = (reprfunc)RangeRepr; + RangeType.tp_as_sequence = &RangeAsSeq; + RangeType.tp_as_mapping = &RangeAsMapping; + RangeType.tp_flags = Py_TPFLAGS_DEFAULT; + RangeType.tp_doc = "vim Range object"; + RangeType.tp_methods = RangeMethods; + #if PY_MAJOR_VERSION >= 3 +! RangeType.tp_getattro = (getattrofunc)RangeGetattro; + RangeType.tp_alloc = call_PyType_GenericAlloc; + RangeType.tp_new = call_PyType_GenericNew; + RangeType.tp_free = call_PyObject_Free; + #else +! RangeType.tp_getattr = (getattrfunc)RangeGetattr; + #endif + + vim_memset(&CurrentType, 0, sizeof(CurrentType)); +*************** +*** 4147,4205 **** + CurrentType.tp_flags = Py_TPFLAGS_DEFAULT; + CurrentType.tp_doc = "vim current object"; + #if PY_MAJOR_VERSION >= 3 +! CurrentType.tp_getattro = CurrentGetattro; +! CurrentType.tp_setattro = CurrentSetattro; + #else +! CurrentType.tp_getattr = CurrentGetattr; +! CurrentType.tp_setattr = CurrentSetattr; + #endif + + vim_memset(&DictionaryType, 0, sizeof(DictionaryType)); + DictionaryType.tp_name = "vim.dictionary"; + DictionaryType.tp_basicsize = sizeof(DictionaryObject); +! DictionaryType.tp_dealloc = DictionaryDestructor; + DictionaryType.tp_as_mapping = &DictionaryAsMapping; + DictionaryType.tp_flags = Py_TPFLAGS_DEFAULT; + DictionaryType.tp_doc = "dictionary pushing modifications to vim structure"; + DictionaryType.tp_methods = DictionaryMethods; + #if PY_MAJOR_VERSION >= 3 +! DictionaryType.tp_getattro = DictionaryGetattro; +! DictionaryType.tp_setattro = DictionarySetattro; + #else +! DictionaryType.tp_getattr = DictionaryGetattr; +! DictionaryType.tp_setattr = DictionarySetattr; + #endif + + vim_memset(&ListType, 0, sizeof(ListType)); + ListType.tp_name = "vim.list"; +! ListType.tp_dealloc = ListDestructor; + ListType.tp_basicsize = sizeof(ListObject); + ListType.tp_as_sequence = &ListAsSeq; + ListType.tp_as_mapping = &ListAsMapping; + ListType.tp_flags = Py_TPFLAGS_DEFAULT; + ListType.tp_doc = "list pushing modifications to vim structure"; + ListType.tp_methods = ListMethods; +! ListType.tp_iter = ListIter; + #if PY_MAJOR_VERSION >= 3 +! ListType.tp_getattro = ListGetattro; +! ListType.tp_setattro = ListSetattro; + #else +! ListType.tp_getattr = ListGetattr; +! ListType.tp_setattr = ListSetattr; + #endif + + vim_memset(&FunctionType, 0, sizeof(FunctionType)); + FunctionType.tp_name = "vim.function"; + FunctionType.tp_basicsize = sizeof(FunctionObject); +! FunctionType.tp_dealloc = FunctionDestructor; +! FunctionType.tp_call = FunctionCall; + FunctionType.tp_flags = Py_TPFLAGS_DEFAULT; + FunctionType.tp_doc = "object that calls vim function"; + FunctionType.tp_methods = FunctionMethods; + #if PY_MAJOR_VERSION >= 3 +! FunctionType.tp_getattro = FunctionGetattro; + #else +! FunctionType.tp_getattr = FunctionGetattr; + #endif + + vim_memset(&OptionsType, 0, sizeof(OptionsType)); +--- 4108,4166 ---- + CurrentType.tp_flags = Py_TPFLAGS_DEFAULT; + CurrentType.tp_doc = "vim current object"; + #if PY_MAJOR_VERSION >= 3 +! CurrentType.tp_getattro = (getattrofunc)CurrentGetattro; +! CurrentType.tp_setattro = (setattrofunc)CurrentSetattro; + #else +! CurrentType.tp_getattr = (getattrfunc)CurrentGetattr; +! CurrentType.tp_setattr = (setattrfunc)CurrentSetattr; + #endif + + vim_memset(&DictionaryType, 0, sizeof(DictionaryType)); + DictionaryType.tp_name = "vim.dictionary"; + DictionaryType.tp_basicsize = sizeof(DictionaryObject); +! DictionaryType.tp_dealloc = (destructor)DictionaryDestructor; + DictionaryType.tp_as_mapping = &DictionaryAsMapping; + DictionaryType.tp_flags = Py_TPFLAGS_DEFAULT; + DictionaryType.tp_doc = "dictionary pushing modifications to vim structure"; + DictionaryType.tp_methods = DictionaryMethods; + #if PY_MAJOR_VERSION >= 3 +! DictionaryType.tp_getattro = (getattrofunc)DictionaryGetattro; +! DictionaryType.tp_setattro = (setattrofunc)DictionarySetattro; + #else +! DictionaryType.tp_getattr = (getattrfunc)DictionaryGetattr; +! DictionaryType.tp_setattr = (setattrfunc)DictionarySetattr; + #endif + + vim_memset(&ListType, 0, sizeof(ListType)); + ListType.tp_name = "vim.list"; +! ListType.tp_dealloc = (destructor)ListDestructor; + ListType.tp_basicsize = sizeof(ListObject); + ListType.tp_as_sequence = &ListAsSeq; + ListType.tp_as_mapping = &ListAsMapping; + ListType.tp_flags = Py_TPFLAGS_DEFAULT; + ListType.tp_doc = "list pushing modifications to vim structure"; + ListType.tp_methods = ListMethods; +! ListType.tp_iter = (getiterfunc)ListIter; + #if PY_MAJOR_VERSION >= 3 +! ListType.tp_getattro = (getattrofunc)ListGetattro; +! ListType.tp_setattro = (setattrofunc)ListSetattro; + #else +! ListType.tp_getattr = (getattrfunc)ListGetattr; +! ListType.tp_setattr = (setattrfunc)ListSetattr; + #endif + + vim_memset(&FunctionType, 0, sizeof(FunctionType)); + FunctionType.tp_name = "vim.function"; + FunctionType.tp_basicsize = sizeof(FunctionObject); +! FunctionType.tp_dealloc = (destructor)FunctionDestructor; +! FunctionType.tp_call = (ternaryfunc)FunctionCall; + FunctionType.tp_flags = Py_TPFLAGS_DEFAULT; + FunctionType.tp_doc = "object that calls vim function"; + FunctionType.tp_methods = FunctionMethods; + #if PY_MAJOR_VERSION >= 3 +! FunctionType.tp_getattro = (getattrofunc)FunctionGetattro; + #else +! FunctionType.tp_getattr = (getattrfunc)FunctionGetattr; + #endif + + vim_memset(&OptionsType, 0, sizeof(OptionsType)); +*************** +*** 4208,4216 **** + OptionsType.tp_flags = Py_TPFLAGS_DEFAULT; + OptionsType.tp_doc = "object for manipulating options"; + OptionsType.tp_as_mapping = &OptionsAsMapping; +! OptionsType.tp_dealloc = OptionsDestructor; +! OptionsType.tp_traverse = OptionsTraverse; +! OptionsType.tp_clear = OptionsClear; + + #if PY_MAJOR_VERSION >= 3 + vim_memset(&vimmodule, 0, sizeof(vimmodule)); +--- 4169,4177 ---- + OptionsType.tp_flags = Py_TPFLAGS_DEFAULT; + OptionsType.tp_doc = "object for manipulating options"; + OptionsType.tp_as_mapping = &OptionsAsMapping; +! OptionsType.tp_dealloc = (destructor)OptionsDestructor; +! OptionsType.tp_traverse = (traverseproc)OptionsTraverse; +! OptionsType.tp_clear = (inquiry)OptionsClear; + + #if PY_MAJOR_VERSION >= 3 + vim_memset(&vimmodule, 0, sizeof(vimmodule)); +*** ../vim-7.3.991/src/if_python3.c 2013-05-21 18:19:33.000000000 +0200 +--- src/if_python3.c 2013-05-21 18:22:03.000000000 +0200 +*************** +*** 68,75 **** + # define PY_SSIZE_T_CLEAN + #endif + +- static void init_structs(void); +- + /* The "surrogateescape" error handler is new in Python 3.1 */ + #if PY_VERSION_HEX >= 0x030100f0 + # define CODEC_ERROR_HANDLER "surrogateescape" +--- 68,73 ---- +*************** +*** 610,617 **** + } + #endif /* DYNAMIC_PYTHON3 */ + +- static PyObject *BufferDir(PyObject *, PyObject *); +- + static int py3initialised = 0; + + #define PYINITIALISED py3initialised +--- 608,613 ---- +*************** +*** 670,675 **** +--- 666,672 ---- + return PyType_GenericAlloc(type,nitems); + } + ++ static PyObject *BufferDir(PyObject *); + static PyObject *OutputGetattro(PyObject *, PyObject *); + static int OutputSetattro(PyObject *, PyObject *, PyObject *); + static PyObject *BufferGetattro(PyObject *, PyObject *); +*************** +*** 1008,1014 **** + { + GET_ATTR_STRING(name, nameobj); + +! return OutputSetattr(self, name, val); + } + + /***************/ +--- 1005,1011 ---- + { + GET_ATTR_STRING(name, nameobj); + +! return OutputSetattr((OutputObject *)(self), name, val); + } + + /***************/ +*************** +*** 1036,1047 **** + + #define BufferType_Check(obj) ((obj)->ob_base.ob_type == &BufferType) + +- static Py_ssize_t BufferLength(PyObject *); +- static PyObject *BufferItem(PyObject *, Py_ssize_t); + static PyObject* BufferSubscript(PyObject *self, PyObject *idx); + static Py_ssize_t BufferAsSubscript(PyObject *self, PyObject *idx, PyObject *val); + +- + /* Line range type - Implementation functions + * -------------------------------------- + */ +--- 1033,1041 ---- +*************** +*** 1097,1103 **** + } + + static PyObject * +! BufferDir(PyObject *self UNUSED, PyObject *args UNUSED) + { + return Py_BuildValue("[sssss]", "name", "number", + "append", "mark", "range"); +--- 1091,1097 ---- + } + + static PyObject * +! BufferDir(PyObject *self UNUSED) + { + return Py_BuildValue("[sssss]", "name", "number", + "append", "mark", "range"); +*************** +*** 1111,1117 **** + if (PyLong_Check(idx)) + { + long _idx = PyLong_AsLong(idx); +! return BufferItem(self,_idx); + } else if (PySlice_Check(idx)) + { + Py_ssize_t start, stop, step, slicelen; +--- 1105,1111 ---- + if (PyLong_Check(idx)) + { + long _idx = PyLong_AsLong(idx); +! return BufferItem((BufferObject *)(self), _idx); + } else if (PySlice_Check(idx)) + { + Py_ssize_t start, stop, step, slicelen; +*************** +*** 1126,1132 **** + { + return NULL; + } +! return BufferSlice(self, start, stop); + } + else + { +--- 1120,1126 ---- + { + return NULL; + } +! return BufferSlice((BufferObject *)(self), start, stop); + } + else + { +*************** +*** 1230,1236 **** + if (PyLong_Check(idx)) + { + long _idx = PyLong_AsLong(idx); +! return RangeItem(self,_idx); + } else if (PySlice_Check(idx)) + { + Py_ssize_t start, stop, step, slicelen; +--- 1224,1230 ---- + if (PyLong_Check(idx)) + { + long _idx = PyLong_AsLong(idx); +! return RangeItem((RangeObject *)(self), _idx); + } else if (PySlice_Check(idx)) + { + Py_ssize_t start, stop, step, slicelen; +*************** +*** 1242,1248 **** + { + return NULL; + } +! return RangeSlice(self, start, stop); + } + else + { +--- 1236,1242 ---- + { + return NULL; + } +! return RangeSlice((RangeObject *)(self), start, stop); + } + else + { +*************** +*** 1323,1329 **** + { + GET_ATTR_STRING(name, nameobj); + +! return WindowSetattr(self, name, val); + } + + /* Tab page list object - Definitions +--- 1317,1323 ---- + { + GET_ATTR_STRING(name, nameobj); + +! return WindowSetattr((WindowObject *)(self), name, val); + } + + /* Tab page list object - Definitions +*************** +*** 1377,1384 **** + /* Dictionary object - Definitions + */ + +- static PyInt DictionaryLength(PyObject *); +- + static PyObject * + DictionaryGetattro(PyObject *self, PyObject *nameobj) + { +--- 1371,1376 ---- +*************** +*** 1398,1412 **** + DictionarySetattro(PyObject *self, PyObject *nameobj, PyObject *val) + { + GET_ATTR_STRING(name, nameobj); +! return DictionarySetattr(self, name, val); + } + + /* List object - Definitions + */ + +- static PyInt ListLength(PyObject *); +- static PyObject *ListItem(PyObject *, Py_ssize_t); +- + static PySequenceMethods ListAsSeq = { + (lenfunc) ListLength, /* sq_length, len(x) */ + (binaryfunc) 0, /* RangeConcat, sq_concat, x+y */ +--- 1390,1401 ---- + DictionarySetattro(PyObject *self, PyObject *nameobj, PyObject *val) + { + GET_ATTR_STRING(name, nameobj); +! return DictionarySetattr((DictionaryObject *)(self), name, val); + } + + /* List object - Definitions + */ + + static PySequenceMethods ListAsSeq = { + (lenfunc) ListLength, /* sq_length, len(x) */ + (binaryfunc) 0, /* RangeConcat, sq_concat, x+y */ +*************** +*** 1430,1450 **** + }; + + static PyObject * +! ListSubscript(PyObject *self, PyObject* idxObject) + { +! if (PyLong_Check(idxObject)) + { +! long idx = PyLong_AsLong(idxObject); +! return ListItem(self, idx); + } +! else if (PySlice_Check(idxObject)) + { + Py_ssize_t start, stop, step, slicelen; + +! if (PySlice_GetIndicesEx(idxObject, ListLength(self), &start, &stop, +! &step, &slicelen) < 0) + return NULL; +! return ListSlice(self, start, stop); + } + else + { +--- 1419,1439 ---- + }; + + static PyObject * +! ListSubscript(PyObject *self, PyObject* idx) + { +! if (PyLong_Check(idx)) + { +! long _idx = PyLong_AsLong(idx); +! return ListItem((ListObject *)(self), _idx); + } +! else if (PySlice_Check(idx)) + { + Py_ssize_t start, stop, step, slicelen; + +! if (PySlice_GetIndicesEx(idx, ListLength((ListObject *)(self)), +! &start, &stop, &step, &slicelen) < 0) + return NULL; +! return ListSlice((ListObject *)(self), start, stop); + } + else + { +*************** +*** 1454,1474 **** + } + + static Py_ssize_t +! ListAsSubscript(PyObject *self, PyObject *idxObject, PyObject *obj) + { +! if (PyLong_Check(idxObject)) + { +! long idx = PyLong_AsLong(idxObject); +! return ListAssItem(self, idx, obj); + } +! else if (PySlice_Check(idxObject)) + { + Py_ssize_t start, stop, step, slicelen; + +! if (PySlice_GetIndicesEx(idxObject, ListLength(self), &start, &stop, +! &step, &slicelen) < 0) + return -1; +! return ListAssSlice(self, start, stop, obj); + } + else + { +--- 1443,1463 ---- + } + + static Py_ssize_t +! ListAsSubscript(PyObject *self, PyObject *idx, PyObject *obj) + { +! if (PyLong_Check(idx)) + { +! long _idx = PyLong_AsLong(idx); +! return ListAssItem((ListObject *)(self), _idx, obj); + } +! else if (PySlice_Check(idx)) + { + Py_ssize_t start, stop, step, slicelen; + +! if (PySlice_GetIndicesEx(idx, ListLength((ListObject *)(self)), +! &start, &stop, &step, &slicelen) < 0) + return -1; +! return ListAssSlice((ListObject *)(self), start, stop, obj); + } + else + { +*************** +*** 1492,1498 **** + ListSetattro(PyObject *self, PyObject *nameobj, PyObject *val) + { + GET_ATTR_STRING(name, nameobj); +! return ListSetattr(self, name, val); + } + + /* Function object - Definitions +--- 1481,1487 ---- + ListSetattro(PyObject *self, PyObject *nameobj, PyObject *val) + { + GET_ATTR_STRING(name, nameobj); +! return ListSetattr((ListObject *)(self), name, val); + } + + /* Function object - Definitions +*** ../vim-7.3.991/src/if_python.c 2013-05-21 18:19:33.000000000 +0200 +--- src/if_python.c 2013-05-21 18:22:03.000000000 +0200 +*************** +*** 56,63 **** + # define PY_SSIZE_T_CLEAN + #endif + +- static void init_structs(void); +- + #define PyBytes_FromString PyString_FromString + #define PyBytes_Check PyString_Check + +--- 56,61 ---- +*************** +*** 659,674 **** + * Internal function prototypes. + */ + +- static void PythonIO_Flush(void); + static int PythonIO_Init(void); + static int PythonMod_Init(void); + +- /* Utility functions for the vim/python interface +- * ---------------------------------------------- +- */ +- +- static int SetBufferLineList(buf_T *, PyInt, PyInt, PyObject *, PyInt *); +- + + /****************************************************** + * 1. Python interpreter main program. +--- 657,665 ---- +*************** +*** 1017,1025 **** + * 3. Implementation of the Vim module for Python + */ + +- static PyObject *ConvertToPyObject(typval_T *); +- static int ConvertFromPyObject(PyObject *, typval_T *); +- + /* Window type - Implementation functions + * -------------------------------------- + */ +--- 1008,1013 ---- +*** ../vim-7.3.991/src/version.c 2013-05-21 18:19:33.000000000 +0200 +--- src/version.c 2013-05-21 18:28:18.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 992, + /**/ + +-- +We apologise again for the fault in the subtitles. Those responsible for +sacking the people who have just been sacked have been sacked. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// diff --git a/7.3.993 b/7.3.993 new file mode 100644 index 00000000..d9dcbb37 --- /dev/null +++ b/7.3.993 @@ -0,0 +1,248 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.993 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.993 +Problem: Python: Later patch does things slightly differently. +Solution: Adjusted argument type changes. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c + + +*** ../vim-7.3.992/src/if_py_both.h 2013-05-21 18:30:29.000000000 +0200 +--- src/if_py_both.h 2013-05-21 18:42:28.000000000 +0200 +*************** +*** 220,226 **** + } + + static PyObject * +! OutputFlush(PyObject *self UNUSED) + { + /* do nothing */ + Py_INCREF(Py_None); +--- 220,226 ---- + } + + static PyObject * +! OutputFlush(PyObject *self UNUSED, PyObject *args UNUSED) + { + /* do nothing */ + Py_INCREF(Py_None); +*************** +*** 230,240 **** + /***************/ + + static struct PyMethodDef OutputMethods[] = { +! /* name, function, calling, doc */ +! {"write", (PyCFunction)OutputWrite, METH_VARARGS, ""}, +! {"writelines", (PyCFunction)OutputWritelines, METH_VARARGS, ""}, +! {"flush", (PyCFunction)OutputFlush, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL} + }; + + static OutputObject Output = +--- 230,240 ---- + /***************/ + + static struct PyMethodDef OutputMethods[] = { +! /* name, function, calling, doc */ +! {"write", (PyCFunction)OutputWrite, 1, ""}, +! {"writelines", (PyCFunction)OutputWritelines, 1, ""}, +! {"flush", (PyCFunction)OutputFlush, 1, ""}, +! { NULL, NULL, 0, NULL} + }; + + static OutputObject Output = +*************** +*** 533,544 **** + */ + + static struct PyMethodDef VimMethods[] = { +! /* name, function, calling, documentation */ +! {"command", VimCommand, METH_VARARGS, "Execute a Vim ex-mode command" }, +! {"eval", VimEval, METH_VARARGS, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, METH_VARARGS, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, METH_VARARGS, "Screen string width, counts as having width 1"}, +! { NULL, NULL, 0, NULL } + }; + + /* +--- 533,544 ---- + */ + + static struct PyMethodDef VimMethods[] = { +! /* name, function, calling, documentation */ +! {"command", VimCommand, 1, "Execute a Vim ex-mode command" }, +! {"eval", VimEval, 1, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, 1, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, 1, "Screen string width, counts as having width 1"}, +! { NULL, NULL, 0, NULL } + }; + + /* +*************** +*** 868,875 **** + }; + + static struct PyMethodDef DictionaryMethods[] = { +! {"keys", (PyCFunction)DictionaryListKeys, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL } + }; + + static PyTypeObject ListType; +--- 868,875 ---- + }; + + static struct PyMethodDef DictionaryMethods[] = { +! {"keys", (PyCFunction)DictionaryListKeys, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL } + }; + + static PyTypeObject ListType; +*************** +*** 1248,1255 **** + } + + static struct PyMethodDef ListMethods[] = { +! {"extend", (PyCFunction)ListConcatInPlace, METH_O, ""}, +! { NULL, NULL, 0, NULL } + }; + + typedef struct +--- 1248,1255 ---- + } + + static struct PyMethodDef ListMethods[] = { +! {"extend", (PyCFunction)ListConcatInPlace, METH_O, ""}, +! { NULL, NULL, 0, NULL } + }; + + typedef struct +*************** +*** 1349,1356 **** + } + + static struct PyMethodDef FunctionMethods[] = { +! {"__call__", (PyCFunction)FunctionCall, METH_VARARGS|METH_KEYWORDS, ""}, +! { NULL, NULL, 0, NULL} + }; + + /* +--- 1349,1356 ---- + } + + static struct PyMethodDef FunctionMethods[] = { +! {"__call__", (PyCFunction)FunctionCall, METH_VARARGS|METH_KEYWORDS, ""}, +! { NULL, NULL, 0, NULL } + }; + + /* +*************** +*** 2960,2968 **** + } + + static struct PyMethodDef RangeMethods[] = { +! /* name, function, calling, documentation */ +! {"append", (PyCFunction)RangeAppend, METH_VARARGS, "Append data to the Vim range" }, +! { NULL, NULL, 0, NULL } + }; + + static PyTypeObject BufferType; +--- 2960,2968 ---- + } + + static struct PyMethodDef RangeMethods[] = { +! /* name, function, calling, documentation */ +! {"append", (PyCFunction)RangeAppend, 1, "Append data to the Vim range" }, +! { NULL, NULL, 0, NULL } + }; + + static PyTypeObject BufferType; +*************** +*** 3146,3159 **** + } + + static struct PyMethodDef BufferMethods[] = { +! /* name, function, calling, documentation */ +! {"append", (PyCFunction)BufferAppend, METH_VARARGS, "Append data to Vim buffer" }, +! {"mark", (PyCFunction)BufferMark, METH_VARARGS, "Return (row,col) representing position of named mark" }, +! {"range", (PyCFunction)BufferRange, METH_VARARGS, "Return a range object which represents the part of the given buffer between line numbers s and e" }, + #if PY_VERSION_HEX >= 0x03000000 +! {"__dir__", (PyCFunction)BufferDir, METH_NOARGS, "List buffer attributes" }, + #endif +! { NULL, NULL, 0, NULL } + }; + + /* +--- 3146,3159 ---- + } + + static struct PyMethodDef BufferMethods[] = { +! /* name, function, calling, documentation */ +! {"append", (PyCFunction)BufferAppend, 1, "Append data to Vim buffer" }, +! {"mark", (PyCFunction)BufferMark, 1, "Return (row,col) representing position of named mark" }, +! {"range", (PyCFunction)BufferRange, 1, "Return a range object which represents the part of the given buffer between line numbers s and e" }, + #if PY_VERSION_HEX >= 0x03000000 +! {"__dir__", (PyCFunction)BufferDir, 4, "List its attributes" }, + #endif +! { NULL, NULL, 0, NULL } + }; + + /* +*** ../vim-7.3.992/src/if_python3.c 2013-05-21 18:30:29.000000000 +0200 +--- src/if_python3.c 2013-05-21 18:42:28.000000000 +0200 +*************** +*** 666,672 **** + return PyType_GenericAlloc(type,nitems); + } + +! static PyObject *BufferDir(PyObject *); + static PyObject *OutputGetattro(PyObject *, PyObject *); + static int OutputSetattro(PyObject *, PyObject *, PyObject *); + static PyObject *BufferGetattro(PyObject *, PyObject *); +--- 666,672 ---- + return PyType_GenericAlloc(type,nitems); + } + +! static PyObject *BufferDir(PyObject *, PyObject *); + static PyObject *OutputGetattro(PyObject *, PyObject *); + static int OutputSetattro(PyObject *, PyObject *, PyObject *); + static PyObject *BufferGetattro(PyObject *, PyObject *); +*************** +*** 1091,1097 **** + } + + static PyObject * +! BufferDir(PyObject *self UNUSED) + { + return Py_BuildValue("[sssss]", "name", "number", + "append", "mark", "range"); +--- 1091,1097 ---- + } + + static PyObject * +! BufferDir(PyObject *self UNUSED, PyObject *args UNUSED) + { + return Py_BuildValue("[sssss]", "name", "number", + "append", "mark", "range"); +*** ../vim-7.3.992/src/version.c 2013-05-21 18:30:29.000000000 +0200 +--- src/version.c 2013-05-21 18:46:51.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 993, + /**/ + +-- +How come wrong numbers are never busy? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// diff --git a/7.3.994 b/7.3.994 new file mode 100644 index 00000000..221ec102 --- /dev/null +++ b/7.3.994 @@ -0,0 +1,249 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.994 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.994 +Problem: Python: using magic constants. +Solution: Use descriptive values for ml_flags. (ZyX) +Files: src/if_py_both.h, src/if_python3.c + + +*** ../vim-7.3.993/src/if_py_both.h 2013-05-21 18:47:17.000000000 +0200 +--- src/if_py_both.h 2013-05-21 18:51:12.000000000 +0200 +*************** +*** 220,226 **** + } + + static PyObject * +! OutputFlush(PyObject *self UNUSED, PyObject *args UNUSED) + { + /* do nothing */ + Py_INCREF(Py_None); +--- 220,226 ---- + } + + static PyObject * +! OutputFlush(PyObject *self UNUSED) + { + /* do nothing */ + Py_INCREF(Py_None); +*************** +*** 230,240 **** + /***************/ + + static struct PyMethodDef OutputMethods[] = { +! /* name, function, calling, doc */ +! {"write", (PyCFunction)OutputWrite, 1, ""}, +! {"writelines", (PyCFunction)OutputWritelines, 1, ""}, +! {"flush", (PyCFunction)OutputFlush, 1, ""}, +! { NULL, NULL, 0, NULL} + }; + + static OutputObject Output = +--- 230,240 ---- + /***************/ + + static struct PyMethodDef OutputMethods[] = { +! /* name, function, calling, doc */ +! {"write", (PyCFunction)OutputWrite, METH_VARARGS, ""}, +! {"writelines", (PyCFunction)OutputWritelines, METH_VARARGS, ""}, +! {"flush", (PyCFunction)OutputFlush, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL} + }; + + static OutputObject Output = +*************** +*** 533,544 **** + */ + + static struct PyMethodDef VimMethods[] = { +! /* name, function, calling, documentation */ +! {"command", VimCommand, 1, "Execute a Vim ex-mode command" }, +! {"eval", VimEval, 1, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, 1, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, 1, "Screen string width, counts as having width 1"}, +! { NULL, NULL, 0, NULL } + }; + + /* +--- 533,544 ---- + */ + + static struct PyMethodDef VimMethods[] = { +! /* name, function, calling, documentation */ +! {"command", VimCommand, METH_VARARGS, "Execute a Vim ex-mode command" }, +! {"eval", VimEval, METH_VARARGS, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, METH_VARARGS, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, METH_VARARGS, "Screen string width, counts as having width 1"}, +! { NULL, NULL, 0, NULL } + }; + + /* +*************** +*** 868,875 **** + }; + + static struct PyMethodDef DictionaryMethods[] = { +! {"keys", (PyCFunction)DictionaryListKeys, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL } + }; + + static PyTypeObject ListType; +--- 868,875 ---- + }; + + static struct PyMethodDef DictionaryMethods[] = { +! {"keys", (PyCFunction)DictionaryListKeys, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL } + }; + + static PyTypeObject ListType; +*************** +*** 1248,1255 **** + } + + static struct PyMethodDef ListMethods[] = { +! {"extend", (PyCFunction)ListConcatInPlace, METH_O, ""}, +! { NULL, NULL, 0, NULL } + }; + + typedef struct +--- 1248,1255 ---- + } + + static struct PyMethodDef ListMethods[] = { +! {"extend", (PyCFunction)ListConcatInPlace, METH_O, ""}, +! { NULL, NULL, 0, NULL } + }; + + typedef struct +*************** +*** 1349,1356 **** + } + + static struct PyMethodDef FunctionMethods[] = { +! {"__call__", (PyCFunction)FunctionCall, METH_VARARGS|METH_KEYWORDS, ""}, +! { NULL, NULL, 0, NULL } + }; + + /* +--- 1349,1356 ---- + } + + static struct PyMethodDef FunctionMethods[] = { +! {"__call__", (PyCFunction)FunctionCall, METH_VARARGS|METH_KEYWORDS, ""}, +! { NULL, NULL, 0, NULL} + }; + + /* +*************** +*** 2960,2968 **** + } + + static struct PyMethodDef RangeMethods[] = { +! /* name, function, calling, documentation */ +! {"append", (PyCFunction)RangeAppend, 1, "Append data to the Vim range" }, +! { NULL, NULL, 0, NULL } + }; + + static PyTypeObject BufferType; +--- 2960,2968 ---- + } + + static struct PyMethodDef RangeMethods[] = { +! /* name, function, calling, documentation */ +! {"append", (PyCFunction)RangeAppend, METH_VARARGS, "Append data to the Vim range" }, +! { NULL, NULL, 0, NULL } + }; + + static PyTypeObject BufferType; +*************** +*** 3146,3159 **** + } + + static struct PyMethodDef BufferMethods[] = { +! /* name, function, calling, documentation */ +! {"append", (PyCFunction)BufferAppend, 1, "Append data to Vim buffer" }, +! {"mark", (PyCFunction)BufferMark, 1, "Return (row,col) representing position of named mark" }, +! {"range", (PyCFunction)BufferRange, 1, "Return a range object which represents the part of the given buffer between line numbers s and e" }, + #if PY_VERSION_HEX >= 0x03000000 +! {"__dir__", (PyCFunction)BufferDir, 4, "List its attributes" }, + #endif +! { NULL, NULL, 0, NULL } + }; + + /* +--- 3146,3159 ---- + } + + static struct PyMethodDef BufferMethods[] = { +! /* name, function, calling, documentation */ +! {"append", (PyCFunction)BufferAppend, METH_VARARGS, "Append data to Vim buffer" }, +! {"mark", (PyCFunction)BufferMark, METH_VARARGS, "Return (row,col) representing position of named mark" }, +! {"range", (PyCFunction)BufferRange, METH_VARARGS, "Return a range object which represents the part of the given buffer between line numbers s and e" }, + #if PY_VERSION_HEX >= 0x03000000 +! {"__dir__", (PyCFunction)BufferDir, METH_NOARGS, "List buffer attributes" }, + #endif +! { NULL, NULL, 0, NULL } + }; + + /* +*** ../vim-7.3.993/src/if_python3.c 2013-05-21 18:47:17.000000000 +0200 +--- src/if_python3.c 2013-05-21 18:51:12.000000000 +0200 +*************** +*** 666,672 **** + return PyType_GenericAlloc(type,nitems); + } + +! static PyObject *BufferDir(PyObject *, PyObject *); + static PyObject *OutputGetattro(PyObject *, PyObject *); + static int OutputSetattro(PyObject *, PyObject *, PyObject *); + static PyObject *BufferGetattro(PyObject *, PyObject *); +--- 666,672 ---- + return PyType_GenericAlloc(type,nitems); + } + +! static PyObject *BufferDir(PyObject *); + static PyObject *OutputGetattro(PyObject *, PyObject *); + static int OutputSetattro(PyObject *, PyObject *, PyObject *); + static PyObject *BufferGetattro(PyObject *, PyObject *); +*************** +*** 1091,1097 **** + } + + static PyObject * +! BufferDir(PyObject *self UNUSED, PyObject *args UNUSED) + { + return Py_BuildValue("[sssss]", "name", "number", + "append", "mark", "range"); +--- 1091,1097 ---- + } + + static PyObject * +! BufferDir(PyObject *self UNUSED) + { + return Py_BuildValue("[sssss]", "name", "number", + "append", "mark", "range"); +*** ../vim-7.3.993/src/version.c 2013-05-21 18:47:17.000000000 +0200 +--- src/version.c 2013-05-21 18:51:33.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 994, + /**/ + +-- +It might look like I'm doing nothing, but at the cellular level +I'm really quite busy. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// diff --git a/7.3.995 b/7.3.995 new file mode 100644 index 00000000..daa01bee --- /dev/null +++ b/7.3.995 @@ -0,0 +1,512 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.995 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.995 +Problem: Python: Module initialization is duplicated. +Solution: Move to shared file. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c + + +*** ../vim-7.3.994/src/if_py_both.h 2013-05-21 19:01:51.000000000 +0200 +--- src/if_py_both.h 2013-05-21 19:07:17.000000000 +0200 +*************** +*** 4181,4183 **** +--- 4181,4295 ---- + vimmodule.m_methods = VimMethods; + #endif + } ++ ++ #define PYTYPE_READY(type) \ ++ if (PyType_Ready(&type)) \ ++ return -1; ++ ++ static int ++ init_types() ++ { ++ PYTYPE_READY(IterType); ++ PYTYPE_READY(BufferType); ++ PYTYPE_READY(RangeType); ++ PYTYPE_READY(WindowType); ++ PYTYPE_READY(TabPageType); ++ PYTYPE_READY(BufMapType); ++ PYTYPE_READY(WinListType); ++ PYTYPE_READY(TabListType); ++ PYTYPE_READY(CurrentType); ++ PYTYPE_READY(DictionaryType); ++ PYTYPE_READY(ListType); ++ PYTYPE_READY(FunctionType); ++ PYTYPE_READY(OptionsType); ++ PYTYPE_READY(OutputType); ++ return 0; ++ } ++ ++ static BufMapObject TheBufferMap = ++ { ++ PyObject_HEAD_INIT(&BufMapType) ++ }; ++ ++ static WinListObject TheWindowList = ++ { ++ PyObject_HEAD_INIT(&WinListType) ++ NULL ++ }; ++ ++ static CurrentObject TheCurrent = ++ { ++ PyObject_HEAD_INIT(&CurrentType) ++ }; ++ ++ static TabListObject TheTabPageList = ++ { ++ PyObject_HEAD_INIT(&TabListType) ++ }; ++ ++ static struct numeric_constant { ++ char *name; ++ int value; ++ } numeric_constants[] = { ++ {"VAR_LOCKED", VAR_LOCKED}, ++ {"VAR_FIXED", VAR_FIXED}, ++ {"VAR_SCOPE", VAR_SCOPE}, ++ {"VAR_DEF_SCOPE", VAR_DEF_SCOPE}, ++ }; ++ ++ static struct object_constant { ++ char *name; ++ PyObject *value; ++ } object_constants[] = { ++ {"buffers", (PyObject *)(void *)&TheBufferMap}, ++ {"windows", (PyObject *)(void *)&TheWindowList}, ++ {"tabpages", (PyObject *)(void *)&TheTabPageList}, ++ {"current", (PyObject *)(void *)&TheCurrent}, ++ }; ++ ++ typedef int (*object_adder)(PyObject *, const char *, PyObject *); ++ ++ #define ADD_OBJECT(m, name, obj) \ ++ if (add_object(m, name, obj)) \ ++ return -1; ++ ++ #define ADD_CHECKED_OBJECT(m, name, obj) \ ++ { \ ++ PyObject *value = obj; \ ++ if (!value) \ ++ return -1; \ ++ ADD_OBJECT(m, name, value); \ ++ } ++ ++ static int ++ populate_module(PyObject *m, object_adder add_object) ++ { ++ int i; ++ ++ for (i = 0; i < (int)(sizeof(numeric_constants) ++ / sizeof(struct numeric_constant)); ++ ++i) ++ ADD_CHECKED_OBJECT(m, numeric_constants[i].name, ++ PyInt_FromLong(numeric_constants[i].value)); ++ ++ for (i = 0; i < (int)(sizeof(object_constants) ++ / sizeof(struct object_constant)); ++ ++i) ++ { ++ PyObject *value; ++ ++ value = object_constants[i].value; ++ Py_INCREF(value); ++ ADD_OBJECT(m, object_constants[i].name, value); ++ } ++ ++ if (!(VimError = PyErr_NewException("vim.error", NULL, NULL))) ++ return -1; ++ ADD_OBJECT(m, "error", VimError); ++ ++ ADD_CHECKED_OBJECT(m, "vars", DictionaryNew(&globvardict)); ++ ADD_CHECKED_OBJECT(m, "vvars", DictionaryNew(&vimvardict)); ++ ADD_CHECKED_OBJECT(m, "options", ++ OptionsNew(SREQ_GLOBAL, NULL, dummy_check, NULL)); ++ return 0; ++ } +*** ../vim-7.3.994/src/if_python3.c 2013-05-21 19:01:51.000000000 +0200 +--- src/if_python3.c 2013-05-21 19:07:40.000000000 +0200 +*************** +*** 700,706 **** + * Internal function prototypes. + */ + +- static int PythonIO_Init(void); + static PyObject *Py3Init_vim(void); + + /****************************************************** +--- 700,705 ---- +*************** +*** 780,786 **** + get_py3_exceptions(); + #endif + +! if (PythonIO_Init()) + goto fail; + + globals = PyModule_GetDict(PyImport_AddModule("__main__")); +--- 779,785 ---- + get_py3_exceptions(); + #endif + +! if (PythonIO_Init_io()) + goto fail; + + globals = PyModule_GetDict(PyImport_AddModule("__main__")); +*************** +*** 811,817 **** + fail: + /* We call PythonIO_Flush() here to print any Python errors. + * This is OK, as it is possible to call this function even +! * if PythonIO_Init() has not completed successfully (it will + * not do anything in this case). + */ + PythonIO_Flush(); +--- 810,816 ---- + fail: + /* We call PythonIO_Flush() here to print any Python errors. + * This is OK, as it is possible to call this function even +! * if PythonIO_Init_io() has not completed successfully (it will + * not do anything in this case). + */ + PythonIO_Flush(); +*************** +*** 1008,1022 **** + return OutputSetattr((OutputObject *)(self), name, val); + } + +- /***************/ +- +- static int +- PythonIO_Init(void) +- { +- PyType_Ready(&OutputType); +- return PythonIO_Init_io(); +- } +- + /****************************************************** + * 3. Implementation of the Vim module for Python + */ +--- 1007,1012 ---- +*************** +*** 1538,1585 **** + } + #endif + +- static BufMapObject TheBufferMap = +- { +- PyObject_HEAD_INIT(&BufMapType) +- }; +- +- static WinListObject TheWindowList = +- { +- PyObject_HEAD_INIT(&WinListType) +- NULL +- }; +- +- static CurrentObject TheCurrent = +- { +- PyObject_HEAD_INIT(&CurrentType) +- }; +- +- static TabListObject TheTabPageList = +- { +- PyObject_HEAD_INIT(&TabListType) +- }; +- + static PyObject * + Py3Init_vim(void) + { + PyObject *mod; +! PyObject *tmp; + /* The special value is removed from sys.path in Python3_Init(). */ + static wchar_t *(argv[2]) = {L"/must>not&exist/foo", NULL}; + +! PyType_Ready(&IterType); +! PyType_Ready(&BufferType); +! PyType_Ready(&RangeType); +! PyType_Ready(&WindowType); +! PyType_Ready(&TabPageType); +! PyType_Ready(&BufMapType); +! PyType_Ready(&WinListType); +! PyType_Ready(&TabListType); +! PyType_Ready(&CurrentType); +! PyType_Ready(&DictionaryType); +! PyType_Ready(&ListType); +! PyType_Ready(&FunctionType); +! PyType_Ready(&OptionsType); + + /* Set sys.argv[] to avoid a crash in warn(). */ + PySys_SetArgv(1, argv); +--- 1528,1543 ---- + } + #endif + + static PyObject * + Py3Init_vim(void) + { + PyObject *mod; +! + /* The special value is removed from sys.path in Python3_Init(). */ + static wchar_t *(argv[2]) = {L"/must>not&exist/foo", NULL}; + +! if (init_types()) +! return NULL; + + /* Set sys.argv[] to avoid a crash in warn(). */ + PySys_SetArgv(1, argv); +*************** +*** 1588,1622 **** + if (mod == NULL) + return NULL; + +! VimError = PyErr_NewException("vim.error", NULL, NULL); +! +! Py_INCREF(VimError); +! PyModule_AddObject(mod, "error", VimError); +! Py_INCREF((PyObject *)(void *)&TheBufferMap); +! PyModule_AddObject(mod, "buffers", (PyObject *)(void *)&TheBufferMap); +! Py_INCREF((PyObject *)(void *)&TheCurrent); +! PyModule_AddObject(mod, "current", (PyObject *)(void *)&TheCurrent); +! Py_INCREF((PyObject *)(void *)&TheWindowList); +! PyModule_AddObject(mod, "windows", (PyObject *)(void *)&TheWindowList); +! Py_INCREF((PyObject *)(void *)&TheTabPageList); +! PyModule_AddObject(mod, "tabpages", (PyObject *)(void *)&TheTabPageList); +! +! PyModule_AddObject(mod, "vars", DictionaryNew(&globvardict)); +! PyModule_AddObject(mod, "vvars", DictionaryNew(&vimvardict)); +! PyModule_AddObject(mod, "options", +! OptionsNew(SREQ_GLOBAL, NULL, dummy_check, NULL)); +! +! #define ADD_INT_CONSTANT(name, value) \ +! tmp = PyLong_FromLong(value); \ +! Py_INCREF(tmp); \ +! PyModule_AddObject(mod, name, tmp) +! +! ADD_INT_CONSTANT("VAR_LOCKED", VAR_LOCKED); +! ADD_INT_CONSTANT("VAR_FIXED", VAR_FIXED); +! ADD_INT_CONSTANT("VAR_SCOPE", VAR_SCOPE); +! ADD_INT_CONSTANT("VAR_DEF_SCOPE", VAR_DEF_SCOPE); +! +! if (PyErr_Occurred()) + return NULL; + + return mod; +--- 1546,1552 ---- + if (mod == NULL) + return NULL; + +! if (populate_module(mod, PyModule_AddObject)) + return NULL; + + return mod; +*** ../vim-7.3.994/src/if_python.c 2013-05-21 18:30:29.000000000 +0200 +--- src/if_python.c 2013-05-21 19:07:26.000000000 +0200 +*************** +*** 657,663 **** + * Internal function prototypes. + */ + +- static int PythonIO_Init(void); + static int PythonMod_Init(void); + + +--- 657,662 ---- +*************** +*** 772,778 **** + get_exceptions(); + #endif + +! if (PythonIO_Init()) + goto fail; + + if (PythonMod_Init()) +--- 771,777 ---- + get_exceptions(); + #endif + +! if (PythonIO_Init_io()) + goto fail; + + if (PythonMod_Init()) +*************** +*** 806,812 **** + fail: + /* We call PythonIO_Flush() here to print any Python errors. + * This is OK, as it is possible to call this function even +! * if PythonIO_Init() has not completed successfully (it will + * not do anything in this case). + */ + PythonIO_Flush(); +--- 805,811 ---- + fail: + /* We call PythonIO_Flush() here to print any Python errors. + * This is OK, as it is possible to call this function even +! * if PythonIO_Init_io() has not completed successfully (it will + * not do anything in this case). + */ + PythonIO_Flush(); +*************** +*** 993,1009 **** + return Py_FindMethod(OutputMethods, self, name); + } + +- /***************/ +- +- static int +- PythonIO_Init(void) +- { +- /* Fixups... */ +- PyType_Ready(&OutputType); +- +- return PythonIO_Init_io(); +- } +- + /****************************************************** + * 3. Implementation of the Vim module for Python + */ +--- 992,997 ---- +*************** +*** 1242,1288 **** + } + #endif + +! static BufMapObject TheBufferMap = +! { +! PyObject_HEAD_INIT(&BufMapType) +! }; +! +! static WinListObject TheWindowList = +! { +! PyObject_HEAD_INIT(&WinListType) +! NULL +! }; +! +! static CurrentObject TheCurrent = +! { +! PyObject_HEAD_INIT(&CurrentType) +! }; +! +! static TabListObject TheTabPageList = + { +! PyObject_HEAD_INIT(&TabListType) +! }; + + static int + PythonMod_Init(void) + { + PyObject *mod; + PyObject *dict; +! PyObject *tmp; + /* The special value is removed from sys.path in Python_Init(). */ + static char *(argv[2]) = {"/must>not&exist/foo", NULL}; + +! /* Fixups... */ +! PyType_Ready(&IterType); +! PyType_Ready(&BufferType); +! PyType_Ready(&RangeType); +! PyType_Ready(&WindowType); +! PyType_Ready(&TabPageType); +! PyType_Ready(&BufMapType); +! PyType_Ready(&WinListType); +! PyType_Ready(&TabListType); +! PyType_Ready(&CurrentType); +! PyType_Ready(&OptionsType); + + /* Set sys.argv[] to avoid a crash in warn(). */ + PySys_SetArgv(1, argv); +--- 1230,1255 ---- + } + #endif + +! static int +! add_object(PyObject *dict, const char *name, PyObject *object) + { +! if (PyDict_SetItemString(dict, (char *) name, object)) +! return -1; +! Py_DECREF(object); +! return 0; +! } + + static int + PythonMod_Init(void) + { + PyObject *mod; + PyObject *dict; +! + /* The special value is removed from sys.path in Python_Init(). */ + static char *(argv[2]) = {"/must>not&exist/foo", NULL}; + +! if (init_types()) +! return -1; + + /* Set sys.argv[] to avoid a crash in warn(). */ + PySys_SetArgv(1, argv); +*************** +*** 1290,1320 **** + mod = Py_InitModule4("vim", VimMethods, (char *)NULL, (PyObject *)NULL, PYTHON_API_VERSION); + dict = PyModule_GetDict(mod); + +! VimError = PyErr_NewException("vim.error", NULL, NULL); +! +! PyDict_SetItemString(dict, "error", VimError); +! PyDict_SetItemString(dict, "buffers", (PyObject *)(void *)&TheBufferMap); +! PyDict_SetItemString(dict, "current", (PyObject *)(void *)&TheCurrent); +! PyDict_SetItemString(dict, "windows", (PyObject *)(void *)&TheWindowList); +! PyDict_SetItemString(dict, "tabpages", (PyObject *)(void *)&TheTabPageList); +! tmp = DictionaryNew(&globvardict); +! PyDict_SetItemString(dict, "vars", tmp); +! Py_DECREF(tmp); +! tmp = DictionaryNew(&vimvardict); +! PyDict_SetItemString(dict, "vvars", tmp); +! Py_DECREF(tmp); +! tmp = OptionsNew(SREQ_GLOBAL, NULL, dummy_check, NULL); +! PyDict_SetItemString(dict, "options", tmp); +! Py_DECREF(tmp); +! PyDict_SetItemString(dict, "VAR_LOCKED", PyInt_FromLong(VAR_LOCKED)); +! PyDict_SetItemString(dict, "VAR_FIXED", PyInt_FromLong(VAR_FIXED)); +! PyDict_SetItemString(dict, "VAR_SCOPE", PyInt_FromLong(VAR_SCOPE)); +! PyDict_SetItemString(dict, "VAR_DEF_SCOPE", PyInt_FromLong(VAR_DEF_SCOPE)); +! +! if (PyErr_Occurred()) +! return -1; +! +! return 0; + } + + /************************************************************************* +--- 1257,1263 ---- + mod = Py_InitModule4("vim", VimMethods, (char *)NULL, (PyObject *)NULL, PYTHON_API_VERSION); + dict = PyModule_GetDict(mod); + +! return populate_module(dict, add_object); + } + + /************************************************************************* +*** ../vim-7.3.994/src/version.c 2013-05-21 19:01:51.000000000 +0200 +--- src/version.c 2013-05-21 19:06:22.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 995, + /**/ + +-- +System administrators are just like women: You can't live with them and you +can't live without them. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// diff --git a/7.3.996 b/7.3.996 new file mode 100644 index 00000000..284fce9b --- /dev/null +++ b/7.3.996 @@ -0,0 +1,374 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.996 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.996 +Problem: Python: Can't check types of what is returned by bindeval(). +Solution: Add vim.List, vim.Dictionary and vim.Function types. (ZyX) +Files: runtime/doc/if_pyth.txt, src/if_py_both.h, src/testdir/test86.in, + src/testdir/test86.ok, src/testdir/test87.in, + src/testdir/test87.ok + + +*** ../vim-7.3.995/runtime/doc/if_pyth.txt 2013-05-17 16:39:59.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-05-21 19:21:58.000000000 +0200 +*************** +*** 11,19 **** + 3. Buffer objects |python-buffer| + 4. Range objects |python-range| + 5. Window objects |python-window| +! 6. pyeval(), py3eval() Vim functions |python-pyeval| +! 7. Dynamic loading |python-dynamic| +! 8. Python 3 |python3| + + {Vi does not have any of these commands} + +--- 11,20 ---- + 3. Buffer objects |python-buffer| + 4. Range objects |python-range| + 5. Window objects |python-window| +! 6. Tab page objects |python-tabpage| +! 7. pyeval(), py3eval() Vim functions |python-pyeval| +! 8. Dynamic loading |python-dynamic| +! 9. Python 3 |python3| + + {Vi does not have any of these commands} + +*************** +*** 176,182 **** + list or dictionary. Thus modifications to these objects imply + modifications of the original. + +! Additionally, vimlist and vimdictionary type have read-write + `.locked` attribute that returns + Value Meaning ~ + zero Variable is not locked +--- 177,183 ---- + list or dictionary. Thus modifications to these objects imply + modifications of the original. + +! Additionally, vim.List and vim.Dictionary type have read-write + `.locked` attribute that returns + Value Meaning ~ + zero Variable is not locked +*************** +*** 189,202 **** + case these locks are ignored by anything except |:let|: |extend()| + does not care, neither does python interface). + +! Vimdictionary type also supports `.scope` attribute which is one of + Value Meaning ~ + zero Dictionary is not a scope one + vim.VAR_DEF_SCOPE Function-local or global scope dictionary + vim.VAR_SCOPE Other scope dictionary + + 2. if expression evaluates to a function reference, then it returns +! callable vimfunction object. Use self keyword argument to assign + |self| object for dictionary functions. + + Note: this function has the same behavior as |lua-eval| (except that +--- 190,204 ---- + case these locks are ignored by anything except |:let|: |extend()| + does not care, neither does python interface). + +! vim.Dictionary type also supports `.scope` attribute which is one +! of + Value Meaning ~ + zero Dictionary is not a scope one + vim.VAR_DEF_SCOPE Function-local or global scope dictionary + vim.VAR_SCOPE Other scope dictionary + + 2. if expression evaluates to a function reference, then it returns +! callable vim.Function object. Use self keyword argument to assign + |self| object for dictionary functions. + + Note: this function has the same behavior as |lua-eval| (except that +*************** +*** 205,210 **** +--- 207,216 ---- + relying on outputs of vim.eval() being a copy of original or + vim.eval("1") returning a string. + ++ You can use "List", "Dictionary" and "Function" vim module attributes ++ to test whether object has given type. These types are currently not ++ subclassable, neither they contain constructors, so you can use them ++ only for checks like `isinstance(obj, vim.List)`. + + + Error object of the "vim" module +*************** +*** 302,307 **** +--- 308,316 ---- + buffer-local options and |python-window| objects to access to + window-local options. + ++ Type of this object is available via "Options" attribute of vim ++ module. ++ + Output from Python *python-output* + Vim displays all Python code output in the Vim message area. Normal + output appears as information messages, and error output appears as +*************** +*** 371,376 **** +--- 380,387 ---- + A trailing '\n' is allowed and ignored, so that you can do: > + :py b.append(f.readlines()) + ++ Buffer object type is available using "Buffer" attribute of vim module. ++ + Examples (assume b is the current buffer) > + :py print b.name # write the buffer file name + :py b[0] = "hello!!!" # replace the top line +*************** +*** 412,417 **** +--- 423,430 ---- + for Python's built-in list objects. + r.append(list, nr) Idem, after line "nr" + ++ Range object type is available using "Range" attribute of vim module. ++ + Example (assume r is the current range): + # Send all lines in a range to the default printer + vim.command("%d,%dhardcopy!" % (r.start+1,r.end+1)) +*************** +*** 456,461 **** +--- 469,476 ---- + The height attribute is writable only if the screen is split horizontally. + The width attribute is writable only if the screen is split vertically. + ++ Window object type is available using "Window" attribute of vim module. ++ + ============================================================================== + 6. Tab page objects *python-tabpage* + +*************** +*** 474,487 **** + vars The tab page |t:| variables. + window Current tabpage window. + + ============================================================================== +! 6. pyeval() and py3eval() Vim functions *python-pyeval* + + To facilitate bi-directional interface, you can use |pyeval()| and |py3eval()| + functions to evaluate Python expressions and pass their values to VimL. + + ============================================================================== +! 7. Dynamic loading *python-dynamic* + + On MS-Windows the Python library can be loaded dynamically. The |:version| + output then includes |+python/dyn|. +--- 489,504 ---- + vars The tab page |t:| variables. + window Current tabpage window. + ++ TabPage object type is available using "TabPage" attribute of vim module. ++ + ============================================================================== +! 7. pyeval() and py3eval() Vim functions *python-pyeval* + + To facilitate bi-directional interface, you can use |pyeval()| and |py3eval()| + functions to evaluate Python expressions and pass their values to VimL. + + ============================================================================== +! 8. Dynamic loading *python-dynamic* + + On MS-Windows the Python library can be loaded dynamically. The |:version| + output then includes |+python/dyn|. +*************** +*** 498,504 **** + sure edit "gvim.exe" and search for "python\d*.dll\c". + + ============================================================================== +! 8. Python 3 *python3* + + *:py3* *:python3* + The `:py3` and `:python3` commands work similar to `:python`. A simple check +--- 515,521 ---- + sure edit "gvim.exe" and search for "python\d*.dll\c". + + ============================================================================== +! 9. Python 3 *python3* + + *:py3* *:python3* + The `:py3` and `:python3` commands work similar to `:python`. A simple check +*** ../vim-7.3.995/src/if_py_both.h 2013-05-21 19:10:56.000000000 +0200 +--- src/if_py_both.h 2013-05-21 19:21:58.000000000 +0200 +*************** +*** 4245,4250 **** +--- 4245,4259 ---- + {"windows", (PyObject *)(void *)&TheWindowList}, + {"tabpages", (PyObject *)(void *)&TheTabPageList}, + {"current", (PyObject *)(void *)&TheCurrent}, ++ ++ {"Buffer", (PyObject *)&BufferType}, ++ {"Range", (PyObject *)&RangeType}, ++ {"Window", (PyObject *)&WindowType}, ++ {"TabPage", (PyObject *)&TabPageType}, ++ {"Dictionary", (PyObject *)&DictionaryType}, ++ {"List", (PyObject *)&ListType}, ++ {"Function", (PyObject *)&FunctionType}, ++ {"Options", (PyObject *)&OptionsType}, + }; + + typedef int (*object_adder)(PyObject *, const char *, PyObject *); +*** ../vim-7.3.995/src/testdir/test86.in 2013-05-17 13:37:57.000000000 +0200 +--- src/testdir/test86.in 2013-05-21 19:21:58.000000000 +0200 +*************** +*** 631,640 **** + cb.append('Current line: ' + repr(vim.current.line)) + for b in vim.buffers: + if b is not cb: +! vim.command('bwipeout! ' + b.number) + EOF + :tabonly! + :only! + :endfun + :" + :call Test() +--- 631,656 ---- + cb.append('Current line: ' + repr(vim.current.line)) + for b in vim.buffers: + if b is not cb: +! vim.command('bwipeout! ' + str(b.number)) + EOF + :tabonly! + :only! ++ :" ++ :" Test types ++ py << EOF ++ for expr, attr in ( ++ ('vim.vars', 'Dictionary'), ++ ('vim.options', 'Options'), ++ ('vim.bindeval("{}")', 'Dictionary'), ++ ('vim.bindeval("[]")', 'List'), ++ ('vim.bindeval("function(\'tr\')")', 'Function'), ++ ('vim.current.buffer', 'Buffer'), ++ ('vim.current.range', 'Range'), ++ ('vim.current.window', 'Window'), ++ ('vim.current.tabpage', 'TabPage'), ++ ): ++ cb.append(expr + ':' + attr + ':' + repr(type(eval(expr)) is getattr(vim, attr))) ++ EOF + :endfun + :" + :call Test() +*** ../vim-7.3.995/src/testdir/test86.ok 2013-05-17 16:18:27.000000000 +0200 +--- src/testdir/test86.ok 2013-05-21 19:21:58.000000000 +0200 +*************** +*** 333,339 **** + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (954, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +--- 333,339 ---- + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (970, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +*************** +*** 359,361 **** +--- 359,370 ---- + Current window: + Current buffer: + Current line: 'Type error at assigning None to vim.current.buffer' ++ vim.vars:Dictionary:True ++ vim.options:Options:True ++ vim.bindeval("{}"):Dictionary:True ++ vim.bindeval("[]"):List:True ++ vim.bindeval("function('tr')"):Function:True ++ vim.current.buffer:Buffer:True ++ vim.current.range:Range:True ++ vim.current.window:Window:True ++ vim.current.tabpage:TabPage:True +*** ../vim-7.3.995/src/testdir/test87.in 2013-05-17 13:37:57.000000000 +0200 +--- src/testdir/test87.in 2013-05-21 19:21:58.000000000 +0200 +*************** +*** 622,627 **** +--- 622,643 ---- + EOF + :tabonly! + :only! ++ :" ++ :" Test types ++ py3 << EOF ++ for expr, attr in ( ++ ('vim.vars', 'Dictionary'), ++ ('vim.options', 'Options'), ++ ('vim.bindeval("{}")', 'Dictionary'), ++ ('vim.bindeval("[]")', 'List'), ++ ('vim.bindeval("function(\'tr\')")', 'Function'), ++ ('vim.current.buffer', 'Buffer'), ++ ('vim.current.range', 'Range'), ++ ('vim.current.window', 'Window'), ++ ('vim.current.tabpage', 'TabPage'), ++ ): ++ cb.append(expr + ':' + attr + ':' + repr(type(eval(expr)) is getattr(vim, attr))) ++ EOF + :endfun + :" + :call Test() +*** ../vim-7.3.995/src/testdir/test87.ok 2013-05-21 18:19:33.000000000 +0200 +--- src/testdir/test87.ok 2013-05-21 19:21:58.000000000 +0200 +*************** +*** 322,328 **** + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (930, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +--- 322,328 ---- + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (946, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +*************** +*** 348,350 **** +--- 348,359 ---- + Current window: + Current buffer: + Current line: 'Type error at assigning None to vim.current.buffer' ++ vim.vars:Dictionary:True ++ vim.options:Options:True ++ vim.bindeval("{}"):Dictionary:True ++ vim.bindeval("[]"):List:True ++ vim.bindeval("function('tr')"):Function:True ++ vim.current.buffer:Buffer:True ++ vim.current.range:Range:True ++ vim.current.window:Window:True ++ vim.current.tabpage:TabPage:True +*** ../vim-7.3.995/src/version.c 2013-05-21 19:10:56.000000000 +0200 +--- src/version.c 2013-05-21 19:48:38.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 996, + /**/ + +-- +SUPERIMPOSE "England AD 787". After a few more seconds we hear hoofbeats in +the distance. They come slowly closer. Then out of the mist comes KING +ARTHUR followed by a SERVANT who is banging two half coconuts together. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// diff --git a/7.3.997 b/7.3.997 new file mode 100644 index 00000000..3839e54a --- /dev/null +++ b/7.3.997 @@ -0,0 +1,983 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.997 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.997 +Problem: Vim and Python exceptions are different. +Solution: Make Vim exceptions be Python exceptions. (ZyX) +Files: src/if_py_both.h, src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.996/src/if_py_both.h 2013-05-21 19:49:58.000000000 +0200 +--- src/if_py_both.h 2013-05-21 20:35:07.000000000 +0200 +*************** +*** 272,291 **** + /* Check to see whether a Vim error has been reported, or a keyboard + * interrupt has been detected. + */ + static int +! VimErrorCheck(void) + { + if (got_int) + { + PyErr_SetNone(PyExc_KeyboardInterrupt); + return 1; + } +! else if (did_emsg && !PyErr_Occurred()) + { +! PyErr_SetNone(VimError); + return 1; + } + + return 0; + } + +--- 272,313 ---- + /* Check to see whether a Vim error has been reported, or a keyboard + * interrupt has been detected. + */ ++ ++ static void ++ VimTryStart(void) ++ { ++ ++trylevel; ++ } ++ + static int +! VimTryEnd(void) + { ++ --trylevel; + if (got_int) + { + PyErr_SetNone(PyExc_KeyboardInterrupt); + return 1; + } +! else if (!did_throw) +! return 0; +! else if (PyErr_Occurred()) +! return 1; +! else + { +! PyErr_SetVim((char *) current_exception->value); +! discard_current_exception(); + return 1; + } ++ } + ++ static int ++ VimCheckInterrupt(void) ++ { ++ if (got_int) ++ { ++ PyErr_SetNone(PyExc_KeyboardInterrupt); ++ return 1; ++ } + return 0; + } + +*************** +*** 306,322 **** + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + + do_cmdline_cmd((char_u *)cmd); + update_screen(VALID); + + Python_Release_Vim(); + Py_END_ALLOW_THREADS + +! if (VimErrorCheck()) + result = NULL; + else + result = Py_None; + + Py_XINCREF(result); + return result; + } +--- 328,346 ---- + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + ++ VimTryStart(); + do_cmdline_cmd((char_u *)cmd); + update_screen(VALID); + + Python_Release_Vim(); + Py_END_ALLOW_THREADS + +! if (VimTryEnd()) + result = NULL; + else + result = Py_None; + ++ + Py_XINCREF(result); + return result; + } +*************** +*** 449,459 **** + + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + our_tv = eval_expr((char_u *)expr, NULL); +- + Python_Release_Vim(); + Py_END_ALLOW_THREADS + + if (our_tv == NULL) + { + PyErr_SetVim(_("invalid expression")); +--- 473,486 ---- + + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); ++ VimTryStart(); + our_tv = eval_expr((char_u *)expr, NULL); + Python_Release_Vim(); + Py_END_ALLOW_THREADS + ++ if (VimTryEnd()) ++ return NULL; ++ + if (our_tv == NULL) + { + PyErr_SetVim(_("invalid expression")); +*************** +*** 490,500 **** + + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + our_tv = eval_expr((char_u *)expr, NULL); +- + Python_Release_Vim(); + Py_END_ALLOW_THREADS + + if (our_tv == NULL) + { + PyErr_SetVim(_("invalid expression")); +--- 517,530 ---- + + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); ++ VimTryStart(); + our_tv = eval_expr((char_u *)expr, NULL); + Python_Release_Vim(); + Py_END_ALLOW_THREADS + ++ if (VimTryEnd()) ++ return NULL; ++ + if (our_tv == NULL) + { + PyErr_SetVim(_("invalid expression")); +*************** +*** 1324,1335 **** + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + + error = func_call(name, &args, selfdict, &rettv); + + Python_Release_Vim(); + Py_END_ALLOW_THREADS + +! if (error != OK) + { + result = NULL; + PyErr_SetVim(_("failed to run function")); +--- 1354,1368 ---- + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + ++ VimTryStart(); + error = func_call(name, &args, selfdict, &rettv); + + Python_Release_Vim(); + Py_END_ALLOW_THREADS + +! if (VimTryEnd()) +! result = NULL; +! else if (error != OK) + { + result = NULL; + PyErr_SetVim(_("failed to run function")); +*************** +*** 1486,1499 **** + win_T *save_curwin; + tabpage_T *save_curtab; + buf_T *save_curbuf; +- int r = 0; + + switch (opt_type) + { + case SREQ_WIN: + if (switch_win(&save_curwin, &save_curtab, (win_T *)from, + win_find_tabpage((win_T *)from)) == FAIL) + { + PyErr_SetVim("Problem while switching windows."); + return -1; + } +--- 1519,1534 ---- + win_T *save_curwin; + tabpage_T *save_curtab; + buf_T *save_curbuf; + ++ VimTryStart(); + switch (opt_type) + { + case SREQ_WIN: + if (switch_win(&save_curwin, &save_curtab, (win_T *)from, + win_find_tabpage((win_T *)from)) == FAIL) + { ++ if (VimTryEnd()) ++ return -1; + PyErr_SetVim("Problem while switching windows."); + return -1; + } +*************** +*** 1509,1515 **** + set_option_value(key, numval, stringval, opt_flags); + break; + } +! return r; + } + + static int +--- 1544,1550 ---- + set_option_value(key, numval, stringval, opt_flags); + break; + } +! return VimTryEnd(); + } + + static int +*************** +*** 1961,1967 **** + } + + /* Check for keyboard interrupts */ +! if (VimErrorCheck()) + return -1; + + self->win->w_cursor.lnum = lnum; +--- 1996,2002 ---- + } + + /* Check for keyboard interrupts */ +! if (VimCheckInterrupt()) + return -1; + + self->win->w_cursor.lnum = lnum; +*************** +*** 1988,1998 **** + #endif + savewin = curwin; + curwin = self->win; + win_setheight(height); + curwin = savewin; +! +! /* Check for keyboard interrupts */ +! if (VimErrorCheck()) + return -1; + + return 0; +--- 2023,2033 ---- + #endif + savewin = curwin; + curwin = self->win; ++ ++ VimTryStart(); + win_setheight(height); + curwin = savewin; +! if (VimTryEnd()) + return -1; + + return 0; +*************** +*** 2011,2021 **** + #endif + savewin = curwin; + curwin = self->win; + win_setwidth(width); + curwin = savewin; +! +! /* Check for keyboard interrupts */ +! if (VimErrorCheck()) + return -1; + + return 0; +--- 2046,2056 ---- + #endif + savewin = curwin; + curwin = self->win; ++ ++ VimTryStart(); + win_setwidth(width); + curwin = savewin; +! if (VimTryEnd()) + return -1; + + return 0; +*************** +*** 2304,2309 **** +--- 2339,2346 ---- + PyErr_Clear(); + switch_buffer(&savebuf, buf); + ++ VimTryStart(); ++ + if (u_savedel((linenr_T)n, 1L) == FAIL) + PyErr_SetVim(_("cannot save undo information")); + else if (ml_delete((linenr_T)n, FALSE) == FAIL) +*************** +*** 2317,2323 **** + + restore_buffer(savebuf); + +! if (PyErr_Occurred() || VimErrorCheck()) + return FAIL; + + if (len_change) +--- 2354,2360 ---- + + restore_buffer(savebuf); + +! if (VimTryEnd()) + return FAIL; + + if (len_change) +*************** +*** 2333,2338 **** +--- 2370,2377 ---- + if (save == NULL) + return FAIL; + ++ VimTryStart(); ++ + /* We do not need to free "save" if ml_replace() consumes it. */ + PyErr_Clear(); + switch_buffer(&savebuf, buf); +*************** +*** 2356,2362 **** + if (buf == savebuf) + check_cursor_col(); + +! if (PyErr_Occurred() || VimErrorCheck()) + return FAIL; + + if (len_change) +--- 2395,2401 ---- + if (buf == savebuf) + check_cursor_col(); + +! if (VimTryEnd()) + return FAIL; + + if (len_change) +*************** +*** 2395,2400 **** +--- 2434,2440 ---- + buf_T *savebuf; + + PyErr_Clear(); ++ VimTryStart(); + switch_buffer(&savebuf, buf); + + if (u_savedel((linenr_T)lo, (long)n) == FAIL) +*************** +*** 2416,2422 **** + + restore_buffer(savebuf); + +! if (PyErr_Occurred() || VimErrorCheck()) + return FAIL; + + if (len_change) +--- 2456,2462 ---- + + restore_buffer(savebuf); + +! if (VimTryEnd()) + return FAIL; + + if (len_change) +*************** +*** 2459,2464 **** +--- 2499,2505 ---- + } + } + ++ VimTryStart(); + PyErr_Clear(); + + // START of region without "return". Must call restore_buffer()! +*************** +*** 2545,2551 **** + // END of region without "return". + restore_buffer(savebuf); + +! if (PyErr_Occurred() || VimErrorCheck()) + return FAIL; + + if (len_change) +--- 2586,2592 ---- + // END of region without "return". + restore_buffer(savebuf); + +! if (VimTryEnd()) + return FAIL; + + if (len_change) +*************** +*** 2583,2588 **** +--- 2624,2630 ---- + return FAIL; + + PyErr_Clear(); ++ VimTryStart(); + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)n, (linenr_T)(n+1)) == FAIL) +*************** +*** 2596,2602 **** + restore_buffer(savebuf); + update_screen(VALID); + +! if (PyErr_Occurred() || VimErrorCheck()) + return FAIL; + + if (len_change) +--- 2638,2644 ---- + restore_buffer(savebuf); + update_screen(VALID); + +! if (VimTryEnd()) + return FAIL; + + if (len_change) +*************** +*** 2633,2638 **** +--- 2675,2681 ---- + } + + PyErr_Clear(); ++ VimTryStart(); + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)n, (linenr_T)(n + 1)) == FAIL) +*************** +*** 2666,2672 **** + restore_buffer(savebuf); + update_screen(VALID); + +! if (PyErr_Occurred() || VimErrorCheck()) + return FAIL; + + if (len_change) +--- 2709,2715 ---- + restore_buffer(savebuf); + update_screen(VALID); + +! if (VimTryEnd()) + return FAIL; + + if (len_change) +*************** +*** 2896,2902 **** + static void + RangeDestructor(RangeObject *self) + { +! Py_DECREF(self->buf); + DESTRUCTOR_FINISH(self); + } + +--- 2939,2945 ---- + static void + RangeDestructor(RangeObject *self) + { +! Py_XDECREF(self->buf); + DESTRUCTOR_FINISH(self); + } + +*************** +*** 3078,3086 **** +--- 3121,3132 ---- + return NULL; + mark = *pmark; + ++ VimTryStart(); + switch_buffer(&savebuf, self->buf); + posp = getmark(mark, FALSE); + restore_buffer(savebuf); ++ if (VimTryEnd()) ++ return NULL; + + if (posp == NULL) + { +*************** +*** 3088,3097 **** + return NULL; + } + +- /* Check for keyboard interrupt */ +- if (VimErrorCheck()) +- return NULL; +- + if (posp->lnum <= 0) + { + /* Or raise an error? */ +--- 3134,3139 ---- +*************** +*** 3330,3342 **** + return -1; + count = ((BufferObject *)(value))->buf->b_fnum; + + if (do_buffer(DOBUF_GOTO, DOBUF_FIRST, FORWARD, count, 0) == FAIL) + { + PyErr_SetVim(_("failed to switch to given buffer")); + return -1; + } + +! return 0; + } + else if (strcmp(name, "window") == 0) + { +--- 3372,3387 ---- + return -1; + count = ((BufferObject *)(value))->buf->b_fnum; + ++ VimTryStart(); + if (do_buffer(DOBUF_GOTO, DOBUF_FIRST, FORWARD, count, 0) == FAIL) + { ++ if (VimTryEnd()) ++ return -1; + PyErr_SetVim(_("failed to switch to given buffer")); + return -1; + } + +! return VimTryEnd(); + } + else if (strcmp(name, "window") == 0) + { +*************** +*** 3359,3373 **** + return -1; + } + + win_goto(((WindowObject *)(value))->win); + if (((WindowObject *)(value))->win != curwin) + { + PyErr_SetString(PyExc_RuntimeError, + _("did not switch to the specified window")); + return -1; + } + +! return 0; + } + else if (strcmp(name, "tabpage") == 0) + { +--- 3404,3421 ---- + return -1; + } + ++ VimTryStart(); + win_goto(((WindowObject *)(value))->win); + if (((WindowObject *)(value))->win != curwin) + { ++ if (VimTryEnd()) ++ return -1; + PyErr_SetString(PyExc_RuntimeError, + _("did not switch to the specified window")); + return -1; + } + +! return VimTryEnd(); + } + else if (strcmp(name, "tabpage") == 0) + { +*************** +*** 3380,3394 **** + if (CheckTabPage((TabPageObject *)(value))) + return -1; + + goto_tabpage_tp(((TabPageObject *)(value))->tab, TRUE, TRUE); + if (((TabPageObject *)(value))->tab != curtab) + { + PyErr_SetString(PyExc_RuntimeError, + _("did not switch to the specified tab page")); + return -1; + } + +! return 0; + } + else + { +--- 3428,3445 ---- + if (CheckTabPage((TabPageObject *)(value))) + return -1; + ++ VimTryStart(); + goto_tabpage_tp(((TabPageObject *)(value))->tab, TRUE, TRUE); + if (((TabPageObject *)(value))->tab != curtab) + { ++ if (VimTryEnd()) ++ return -1; + PyErr_SetString(PyExc_RuntimeError, + _("did not switch to the specified tab page")); + return -1; + } + +! return VimTryEnd(); + } + else + { +*** ../vim-7.3.996/src/testdir/test86.in 2013-05-21 19:49:58.000000000 +0200 +--- src/testdir/test86.in 2013-05-21 20:34:32.000000000 +0200 +*************** +*** 380,399 **** + try: + exec(s, g, l) + except: +! vim.command('throw ' + repr(sys.exc_type.__name__)) + + def ev(s, g=globals(), l=locals()): + try: + return eval(s, g, l) + except: +! vim.command('throw ' + repr(sys.exc_type.__name__)) + return 0 + EOF + :function E(s) + : python e(vim.eval('a:s')) + :endfunction + :function Ev(s) +! : return pyeval('ev(vim.eval("a:s"))') + :endfunction + :py gopts1=vim.options + :py wopts1=vim.windows[2].options +--- 380,403 ---- + try: + exec(s, g, l) + except: +! vim.command('return ' + repr(sys.exc_type.__name__)) + + def ev(s, g=globals(), l=locals()): + try: + return eval(s, g, l) + except: +! vim.command('let exc=' + repr(sys.exc_type.__name__)) + return 0 + EOF + :function E(s) + : python e(vim.eval('a:s')) + :endfunction + :function Ev(s) +! : let r=pyeval('ev(vim.eval("a:s"))') +! : if exists('exc') +! : throw exc +! : endif +! : return r + :endfunction + :py gopts1=vim.options + :py wopts1=vim.windows[2].options +*************** +*** 437,463 **** + : catch + : put =' p/'.v.'! '.v:exception + : endtry +! : try +! : call E(v.'["'.oname.'"]=invval') +! : catch +! : put =' inv: '.string(invval).'! '.v:exception +! : endtry + : for vv in (v is# 'gopts1' ? [v] : [v, v[:-2].'2', v[:-2].'3']) + : let val=substitute(vv, '^.opts', 'oval', '') +! : try +! : call E(vv.'["'.oname.'"]='.val) +! : catch +! : put =' '.vv.'! '.v:exception +! : endtry + : endfor + : endfor + : call RecVars(oname) + : for v in ['wopts3', 'bopts3'] +! : try +! : call E('del '.v.'["'.oname.'"]') +! : catch +! : put =' del '.v.'! '.v:exception +! : endtry + : endfor + : call RecVars(oname) + :endfor +--- 441,464 ---- + : catch + : put =' p/'.v.'! '.v:exception + : endtry +! : let r=E(v.'['''.oname.''']=invval') +! : if r isnot 0 +! : put =' inv: '.string(invval).'! '.r +! : endif + : for vv in (v is# 'gopts1' ? [v] : [v, v[:-2].'2', v[:-2].'3']) + : let val=substitute(vv, '^.opts', 'oval', '') +! : let r=E(vv.'['''.oname.''']='.val) +! : if r isnot 0 +! : put =' '.vv.'! '.r +! : endif + : endfor + : endfor + : call RecVars(oname) + : for v in ['wopts3', 'bopts3'] +! : let r=E('del '.v.'["'.oname.'"]') +! : if r isnot 0 +! : put =' del '.v.'! '.r +! : endif + : endfor + : call RecVars(oname) + :endfor +*************** +*** 651,656 **** +--- 652,676 ---- + ): + cb.append(expr + ':' + attr + ':' + repr(type(eval(expr)) is getattr(vim, attr))) + EOF ++ :" ++ :" Test exceptions ++ :fun Exe(e) ++ : execute a:e ++ :endfun ++ py << EOF ++ def ee(expr, g=globals(), l=locals()): ++ try: ++ exec(expr, g, l) ++ except: ++ cb.append(repr(sys.exc_info()[:2])) ++ Exe = vim.bindeval('function("Exe")') ++ ee('vim.command("throw \'abc\'")') ++ ee('Exe("throw \'def\'")') ++ ee('vim.eval("Exe(\'throw \'\'ghi\'\'\')")') ++ ee('vim.eval("Exe(\'echoerr \'\'jkl\'\'\')")') ++ ee('vim.eval("Exe(\'xxx_non_existent_command_xxx\')")') ++ ee('vim.bindeval("Exe(\'xxx_non_existent_command_xxx\')")') ++ EOF + :endfun + :" + :call Test() +*** ../vim-7.3.996/src/testdir/test86.ok 2013-05-21 19:49:58.000000000 +0200 +--- src/testdir/test86.ok 2013-05-21 20:38:29.000000000 +0200 +*************** +*** 333,339 **** + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (970, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +--- 333,339 ---- + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (990, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +*************** +*** 368,370 **** +--- 368,376 ---- + vim.current.range:Range:True + vim.current.window:Window:True + vim.current.tabpage:TabPage:True ++ (, error('abc',)) ++ (, error('def',)) ++ (, error('ghi',)) ++ (, error('Vim(echoerr):jkl',)) ++ (, error('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',)) ++ (, error('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',)) +*** ../vim-7.3.996/src/testdir/test87.in 2013-05-21 19:49:58.000000000 +0200 +--- src/testdir/test87.in 2013-05-21 20:34:32.000000000 +0200 +*************** +*** 367,386 **** + try: + exec(s, g, l) + except Exception as e: +! vim.command('throw ' + repr(e.__class__.__name__)) + + def ev(s, g=globals(), l=locals()): + try: + return eval(s, g, l) + except Exception as e: +! vim.command('throw ' + repr(e.__class__.__name__)) + return 0 + EOF + :function E(s) + : python3 e(vim.eval('a:s')) + :endfunction + :function Ev(s) +! : return py3eval('ev(vim.eval("a:s"))') + :endfunction + :py3 gopts1=vim.options + :py3 wopts1=vim.windows[2].options +--- 367,390 ---- + try: + exec(s, g, l) + except Exception as e: +! vim.command('return ' + repr(e.__class__.__name__)) + + def ev(s, g=globals(), l=locals()): + try: + return eval(s, g, l) + except Exception as e: +! vim.command('let exc=' + repr(e.__class__.__name__)) + return 0 + EOF + :function E(s) + : python3 e(vim.eval('a:s')) + :endfunction + :function Ev(s) +! : let r=py3eval('ev(vim.eval("a:s"))') +! : if exists('exc') +! : throw exc +! : endif +! : return r + :endfunction + :py3 gopts1=vim.options + :py3 wopts1=vim.windows[2].options +*************** +*** 424,450 **** + : catch + : put =' p/'.v.'! '.v:exception + : endtry +! : try +! : call E(v.'["'.oname.'"]=invval') +! : catch +! : put =' inv: '.string(invval).'! '.v:exception +! : endtry + : for vv in (v is# 'gopts1' ? [v] : [v, v[:-2].'2', v[:-2].'3']) + : let val=substitute(vv, '^.opts', 'oval', '') +! : try +! : call E(vv.'["'.oname.'"]='.val) +! : catch +! : put =' '.vv.'! '.v:exception +! : endtry + : endfor + : endfor + : call RecVars(oname) + : for v in ['wopts3', 'bopts3'] +! : try +! : call E('del '.v.'["'.oname.'"]') +! : catch +! : put =' del '.v.'! '.v:exception +! : endtry + : endfor + : call RecVars(oname) + :endfor +--- 428,451 ---- + : catch + : put =' p/'.v.'! '.v:exception + : endtry +! : let r=E(v.'['''.oname.''']=invval') +! : if r isnot 0 +! : put =' inv: '.string(invval).'! '.r +! : endif + : for vv in (v is# 'gopts1' ? [v] : [v, v[:-2].'2', v[:-2].'3']) + : let val=substitute(vv, '^.opts', 'oval', '') +! : let r=E(vv.'['''.oname.''']='.val) +! : if r isnot 0 +! : put =' '.vv.'! '.r +! : endif + : endfor + : endfor + : call RecVars(oname) + : for v in ['wopts3', 'bopts3'] +! : let r=E('del '.v.'["'.oname.'"]') +! : if r isnot 0 +! : put =' del '.v.'! '.r +! : endif + : endfor + : call RecVars(oname) + :endfor +*************** +*** 638,643 **** +--- 639,663 ---- + ): + cb.append(expr + ':' + attr + ':' + repr(type(eval(expr)) is getattr(vim, attr))) + EOF ++ :" ++ :" Test exceptions ++ :fun Exe(e) ++ : execute a:e ++ :endfun ++ py3 << EOF ++ def ee(expr, g=globals(), l=locals()): ++ try: ++ exec(expr, g, l) ++ except Exception as e: ++ cb.append(repr((e.__class__, e))) ++ Exe = vim.bindeval('function("Exe")') ++ ee('vim.command("throw \'abc\'")') ++ ee('Exe("throw \'def\'")') ++ ee('vim.eval("Exe(\'throw \'\'ghi\'\'\')")') ++ ee('vim.eval("Exe(\'echoerr \'\'jkl\'\'\')")') ++ ee('vim.eval("Exe(\'xxx_non_existent_command_xxx\')")') ++ ee('vim.bindeval("Exe(\'xxx_non_existent_command_xxx\')")') ++ EOF + :endfun + :" + :call Test() +*** ../vim-7.3.996/src/testdir/test87.ok 2013-05-21 19:49:58.000000000 +0200 +--- src/testdir/test87.ok 2013-05-21 20:38:46.000000000 +0200 +*************** +*** 322,328 **** + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (946, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +--- 322,328 ---- + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (966, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +*************** +*** 357,359 **** +--- 357,365 ---- + vim.current.range:Range:True + vim.current.window:Window:True + vim.current.tabpage:TabPage:True ++ (, error('abc',)) ++ (, error('def',)) ++ (, error('ghi',)) ++ (, error('Vim(echoerr):jkl',)) ++ (, error('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',)) ++ (, error('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',)) +*** ../vim-7.3.996/src/version.c 2013-05-21 19:49:58.000000000 +0200 +--- src/version.c 2013-05-21 20:32:46.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 997, + /**/ + +-- +ARTHUR: It is I, Arthur, son of Uther Pendragon, from the castle of Camelot. + King of all Britons, defeator of the Saxons, sovereign of all England! + [Pause] +SOLDIER: Get away! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// diff --git a/7.3.998 b/7.3.998 new file mode 100644 index 00000000..952cb300 --- /dev/null +++ b/7.3.998 @@ -0,0 +1,414 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.998 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.998 +Problem: Python: garbage collection issues. +Solution: Fix the GC issues: Use proper DESTRUCTOR_FINISH: avoids negative + refcounts, use PyObject_GC_* for objects with tp_traverse and + tp_clear, add RangeTraverse and RangeClear, use Py_XDECREF in some + places. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c + + +*** ../vim-7.3.997/src/if_py_both.h 2013-05-21 20:40:35.000000000 +0200 +--- src/if_py_both.h 2013-05-21 20:44:44.000000000 +0200 +*************** +*** 461,467 **** + } + + static PyObject * +! VimEval(PyObject *self UNUSED, PyObject *args UNUSED) + { + char *expr; + typval_T *our_tv; +--- 461,467 ---- + } + + static PyObject * +! VimEval(PyObject *self UNUSED, PyObject *args) + { + char *expr; + typval_T *our_tv; +*************** +*** 602,608 **** + { + IterObject *self; + +! self = PyObject_NEW(IterObject, &IterType); + self->cur = start; + self->next = next; + self->destruct = destruct; +--- 602,608 ---- + { + IterObject *self; + +! self = PyObject_GC_New(IterObject, &IterType); + self->cur = start; + self->next = next; + self->destruct = destruct; +*************** +*** 615,623 **** + static void + IterDestructor(IterObject *self) + { + self->destruct(self->cur); +! +! DESTRUCTOR_FINISH(self); + } + + static int +--- 615,623 ---- + static void + IterDestructor(IterObject *self) + { ++ PyObject_GC_UnTrack((void *)(self)); + self->destruct(self->cur); +! PyObject_GC_Del((void *)(self)); + } + + static int +*************** +*** 1414,1420 **** + { + OptionsObject *self; + +! self = PyObject_NEW(OptionsObject, &OptionsType); + if (self == NULL) + return NULL; + +--- 1414,1420 ---- + { + OptionsObject *self; + +! self = PyObject_GC_New(OptionsObject, &OptionsType); + if (self == NULL) + return NULL; + +*************** +*** 1431,1439 **** + static void + OptionsDestructor(OptionsObject *self) + { +! if (self->fromObj) +! Py_DECREF(self->fromObj); +! DESTRUCTOR_FINISH(self); + } + + static int +--- 1431,1439 ---- + static void + OptionsDestructor(OptionsObject *self) + { +! PyObject_GC_UnTrack((void *)(self)); +! Py_XDECREF(self->fromObj); +! PyObject_GC_Del((void *)(self)); + } + + static int +*************** +*** 1869,1875 **** + } + else + { +! self = PyObject_NEW(WindowObject, &WindowType); + if (self == NULL) + return NULL; + self->win = win; +--- 1869,1875 ---- + } + else + { +! self = PyObject_GC_New(WindowObject, &WindowType); + if (self == NULL) + return NULL; + self->win = win; +*************** +*** 1884,1895 **** + static void + WindowDestructor(WindowObject *self) + { + if (self->win && self->win != INVALID_WINDOW_VALUE) + WIN_PYTHON_REF(self->win) = NULL; + +! Py_DECREF(((PyObject *)(self->tabObject))); + +! DESTRUCTOR_FINISH(self); + } + + static win_T * +--- 1884,1908 ---- + static void + WindowDestructor(WindowObject *self) + { ++ PyObject_GC_UnTrack((void *)(self)); + if (self->win && self->win != INVALID_WINDOW_VALUE) + WIN_PYTHON_REF(self->win) = NULL; ++ Py_XDECREF(((PyObject *)(self->tabObject))); ++ PyObject_GC_Del((void *)(self)); ++ } + +! static int +! WindowTraverse(WindowObject *self, visitproc visit, void *arg) +! { +! Py_VISIT(((PyObject *)(self->tabObject))); +! return 0; +! } + +! static int +! WindowClear(WindowObject *self) +! { +! Py_CLEAR(self->tabObject); +! return 0; + } + + static win_T * +*************** +*** 1909,1927 **** + else + return firstwin; + } +- static int +- WindowTraverse(WindowObject *self, visitproc visit, void *arg) +- { +- Py_VISIT(((PyObject *)(self->tabObject))); +- return 0; +- } +- +- static int +- WindowClear(WindowObject *self) +- { +- Py_CLEAR(self->tabObject); +- return 0; +- } + + static PyObject * + WindowAttr(WindowObject *self, char *name) +--- 1922,1927 ---- +*************** +*** 2917,2923 **** + { + BufferObject *bufr; + RangeObject *self; +! self = PyObject_NEW(RangeObject, &RangeType); + if (self == NULL) + return NULL; + +--- 2917,2923 ---- + { + BufferObject *bufr; + RangeObject *self; +! self = PyObject_GC_New(RangeObject, &RangeType); + if (self == NULL) + return NULL; + +*************** +*** 2939,2946 **** + static void + RangeDestructor(RangeObject *self) + { + Py_XDECREF(self->buf); +! DESTRUCTOR_FINISH(self); + } + + static PyInt +--- 2939,2961 ---- + static void + RangeDestructor(RangeObject *self) + { ++ PyObject_GC_UnTrack((void *)(self)); + Py_XDECREF(self->buf); +! PyObject_GC_Del((void *)(self)); +! } +! +! static int +! RangeTraverse(RangeObject *self, visitproc visit, void *arg) +! { +! Py_VISIT(((PyObject *)(self->buf))); +! return 0; +! } +! +! static int +! RangeClear(RangeObject *self) +! { +! Py_CLEAR(self->buf); +! return 0; + } + + static PyInt +*************** +*** 3267,3280 **** + static int + BufMapIterTraverse(PyObject *buffer, visitproc visit, void *arg) + { +! Py_VISIT(buffer); + return 0; + } + + static int + BufMapIterClear(PyObject **buffer) + { +! Py_CLEAR(*buffer); + return 0; + } + +--- 3282,3297 ---- + static int + BufMapIterTraverse(PyObject *buffer, visitproc visit, void *arg) + { +! if (buffer) +! Py_VISIT(buffer); + return 0; + } + + static int + BufMapIterClear(PyObject **buffer) + { +! if (*buffer) +! Py_CLEAR(*buffer); + return 0; + } + +*************** +*** 4144,4149 **** +--- 4161,4168 ---- + RangeType.tp_flags = Py_TPFLAGS_DEFAULT; + RangeType.tp_doc = "vim Range object"; + RangeType.tp_methods = RangeMethods; ++ RangeType.tp_traverse = (traverseproc)RangeTraverse; ++ RangeType.tp_clear = (inquiry)RangeClear; + #if PY_MAJOR_VERSION >= 3 + RangeType.tp_getattro = (getattrofunc)RangeGetattro; + RangeType.tp_alloc = call_PyType_GenericAlloc; +*** ../vim-7.3.997/src/if_python3.c 2013-05-21 19:10:56.000000000 +0200 +--- src/if_python3.c 2013-05-21 20:44:44.000000000 +0200 +*************** +*** 213,218 **** +--- 213,221 ---- + # define PyObject_Malloc py3_PyObject_Malloc + # define PyObject_Free py3_PyObject_Free + # endif ++ # define _PyObject_GC_New py3__PyObject_GC_New ++ # define PyObject_GC_Del py3_PyObject_GC_Del ++ # define PyObject_GC_UnTrack py3_PyObject_GC_UnTrack + # define PyType_GenericAlloc py3_PyType_GenericAlloc + # define PyType_GenericNew py3_PyType_GenericNew + # define PyModule_Create2 py3_PyModule_Create2 +*************** +*** 334,339 **** +--- 337,345 ---- + static void (*py3_PyObject_Free)(void*); + static void* (*py3_PyObject_Malloc)(size_t); + # endif ++ static PyObject*(*py3__PyObject_GC_New)(PyTypeObject *); ++ static void(*py3_PyObject_GC_Del)(void *); ++ static void(*py3_PyObject_GC_UnTrack)(void *); + static int (*py3_PyType_IsSubtype)(PyTypeObject *, PyTypeObject *); + + static HINSTANCE hinstPy3 = 0; /* Instance of python.dll */ +*************** +*** 463,468 **** +--- 469,477 ---- + {"PyObject_Malloc", (PYTHON_PROC*)&py3_PyObject_Malloc}, + {"PyObject_Free", (PYTHON_PROC*)&py3_PyObject_Free}, + # endif ++ {"_PyObject_GC_New", (PYTHON_PROC*)&py3__PyObject_GC_New}, ++ {"PyObject_GC_Del", (PYTHON_PROC*)&py3_PyObject_GC_Del}, ++ {"PyObject_GC_UnTrack", (PYTHON_PROC*)&py3_PyObject_GC_UnTrack}, + {"PyType_IsSubtype", (PYTHON_PROC*)&py3_PyType_IsSubtype}, + {"PyCapsule_New", (PYTHON_PROC*)&py3_PyCapsule_New}, + {"PyCapsule_GetPointer", (PYTHON_PROC*)&py3_PyCapsule_GetPointer}, +*************** +*** 638,644 **** + if (bytes != NULL) \ + Py_XDECREF(bytes); + +! #define DESTRUCTOR_FINISH(self) Py_TYPE(self)->tp_free((PyObject*)self); + + #define WIN_PYTHON_REF(win) win->w_python3_ref + #define BUF_PYTHON_REF(buf) buf->b_python3_ref +--- 647,653 ---- + if (bytes != NULL) \ + Py_XDECREF(bytes); + +! #define DESTRUCTOR_FINISH(self) Py_TYPE(self)->tp_free((PyObject*)self) + + #define WIN_PYTHON_REF(win) win->w_python3_ref + #define BUF_PYTHON_REF(buf) buf->b_python3_ref +*** ../vim-7.3.997/src/if_python.c 2013-05-21 19:10:56.000000000 +0200 +--- src/if_python.c 2013-05-21 20:44:44.000000000 +0200 +*************** +*** 224,229 **** +--- 224,232 ---- + # define Py_Finalize dll_Py_Finalize + # define Py_IsInitialized dll_Py_IsInitialized + # define _PyObject_New dll__PyObject_New ++ # define _PyObject_GC_New dll__PyObject_GC_New ++ # define PyObject_GC_Del dll_PyObject_GC_Del ++ # define PyObject_GC_UnTrack dll_PyObject_GC_UnTrack + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02070000 + # define _PyObject_NextNotImplemented (*dll__PyObject_NextNotImplemented) + # endif +*************** +*** 331,336 **** +--- 334,342 ---- + static void(*dll_Py_Finalize)(void); + static int(*dll_Py_IsInitialized)(void); + static PyObject*(*dll__PyObject_New)(PyTypeObject *, PyObject *); ++ static PyObject*(*dll__PyObject_GC_New)(PyTypeObject *); ++ static void(*dll_PyObject_GC_Del)(void *); ++ static void(*dll_PyObject_GC_UnTrack)(void *); + static PyObject*(*dll__PyObject_Init)(PyObject *, PyTypeObject *); + static PyObject* (*dll_PyObject_GetIter)(PyObject *); + static int (*dll_PyObject_IsTrue)(PyObject *); +*************** +*** 474,479 **** +--- 480,488 ---- + {"Py_Finalize", (PYTHON_PROC*)&dll_Py_Finalize}, + {"Py_IsInitialized", (PYTHON_PROC*)&dll_Py_IsInitialized}, + {"_PyObject_New", (PYTHON_PROC*)&dll__PyObject_New}, ++ {"_PyObject_GC_New", (PYTHON_PROC*)&dll__PyObject_GC_New}, ++ {"PyObject_GC_Del", (PYTHON_PROC*)&dll_PyObject_GC_Del}, ++ {"PyObject_GC_UnTrack", (PYTHON_PROC*)&dll_PyObject_GC_UnTrack}, + {"PyObject_Init", (PYTHON_PROC*)&dll__PyObject_Init}, + {"PyObject_GetIter", (PYTHON_PROC*)&dll_PyObject_GetIter}, + {"PyObject_IsTrue", (PYTHON_PROC*)&dll_PyObject_IsTrue}, +*************** +*** 632,638 **** + #define DICTKEY_UNREF + #define DICTKEY_DECL + +! #define DESTRUCTOR_FINISH(self) Py_DECREF(self); + + #define WIN_PYTHON_REF(win) win->w_python_ref + #define BUF_PYTHON_REF(buf) buf->b_python_ref +--- 641,647 ---- + #define DICTKEY_UNREF + #define DICTKEY_DECL + +! #define DESTRUCTOR_FINISH(self) Py_TYPE(self)->tp_free((PyObject*)self); + + #define WIN_PYTHON_REF(win) win->w_python_ref + #define BUF_PYTHON_REF(buf) buf->b_python_ref +*** ../vim-7.3.997/src/version.c 2013-05-21 20:40:35.000000000 +0200 +--- src/version.c 2013-05-21 20:43:56.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 998, + /**/ + +-- +The problem with political jokes is that they get elected. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// diff --git a/7.3.999 b/7.3.999 new file mode 100644 index 00000000..13bffc65 --- /dev/null +++ b/7.3.999 @@ -0,0 +1,165 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.999 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.999 +Problem: New regexp engine sets curbuf temporarily. +Solution: Use reg_buf instead, like the old engine. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.998/src/regexp_nfa.c 2013-05-21 16:28:05.000000000 +0200 +--- src/regexp_nfa.c 2013-05-21 21:15:41.000000000 +0200 +*************** +*** 3125,3139 **** + int this_class; + + /* Get class of current and previous char (if it exists). */ +! this_class = mb_get_class(reginput); + if (this_class <= 1) + bow = FALSE; + else if (reg_prev_class() == this_class) + bow = FALSE; + } + #endif +! else if (!vim_iswordc(c) +! || (reginput > regline && vim_iswordc(reginput[-1]))) + bow = FALSE; + if (bow) + addstate(thislist, t->state->out, &t->sub, 0, listid, +--- 3125,3140 ---- + int this_class; + + /* Get class of current and previous char (if it exists). */ +! this_class = mb_get_class_buf(reginput, reg_buf); + if (this_class <= 1) + bow = FALSE; + else if (reg_prev_class() == this_class) + bow = FALSE; + } + #endif +! else if (!vim_iswordc_buf(c, reg_buf) +! || (reginput > regline +! && vim_iswordc_buf(reginput[-1], reg_buf))) + bow = FALSE; + if (bow) + addstate(thislist, t->state->out, &t->sub, 0, listid, +*************** +*** 3153,3167 **** + int this_class, prev_class; + + /* Get class of current and previous char (if it exists). */ +! this_class = mb_get_class(reginput); + prev_class = reg_prev_class(); + if (this_class == prev_class + || prev_class == 0 || prev_class == 1) + eow = FALSE; + } + #endif +! else if (!vim_iswordc(reginput[-1]) +! || (reginput[0] != NUL && vim_iswordc(c))) + eow = FALSE; + if (eow) + addstate(thislist, t->state->out, &t->sub, 0, listid, +--- 3154,3168 ---- + int this_class, prev_class; + + /* Get class of current and previous char (if it exists). */ +! this_class = mb_get_class_buf(reginput, reg_buf); + prev_class = reg_prev_class(); + if (this_class == prev_class + || prev_class == 0 || prev_class == 1) + eow = FALSE; + } + #endif +! else if (!vim_iswordc_buf(reginput[-1], reg_buf) +! || (reginput[0] != NUL && vim_iswordc_buf(c, reg_buf))) + eow = FALSE; + if (eow) + addstate(thislist, t->state->out, &t->sub, 0, listid, +*************** +*** 3267,3278 **** + break; + + case NFA_KWORD: /* \k */ +! result = vim_iswordp(reginput); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_SKWORD: /* \K */ +! result = !VIM_ISDIGIT(c) && vim_iswordp(reginput); + ADD_POS_NEG_STATE(t->state); + break; + +--- 3268,3279 ---- + break; + + case NFA_KWORD: /* \k */ +! result = vim_iswordp_buf(reginput, reg_buf); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_SKWORD: /* \K */ +! result = !VIM_ISDIGIT(c) && vim_iswordp_buf(reginput, reg_buf); + ADD_POS_NEG_STATE(t->state); + break; + +*************** +*** 3826,3834 **** + colnr_T col; /* column to start looking for match */ + proftime_T *tm UNUSED; /* timeout limit or NULL */ + { +- long r; +- buf_T *save_curbuf = curbuf; +- + reg_match = NULL; + reg_mmatch = rmp; + reg_buf = buf; +--- 3827,3832 ---- +*************** +*** 3842,3853 **** + #endif + ireg_maxcol = rmp->rmm_maxcol; + +! /* Need to switch to buffer "buf" to make vim_iswordc() work. */ +! curbuf = buf; +! r = nfa_regexec_both(NULL, col); +! curbuf = save_curbuf; +! +! return r; + } + + #ifdef DEBUG +--- 3840,3846 ---- + #endif + ireg_maxcol = rmp->rmm_maxcol; + +! return nfa_regexec_both(NULL, col); + } + + #ifdef DEBUG +*** ../vim-7.3.998/src/version.c 2013-05-21 20:51:55.000000000 +0200 +--- src/version.c 2013-05-21 21:16:32.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 999, + /**/ + +-- +SOLDIER: Where did you get the coconuts? +ARTHUR: Through ... We found them. +SOLDIER: Found them? In Mercea. The coconut's tropical! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// diff --git a/README.patches b/README.patches index 287479e0..b2044a56 100644 --- a/README.patches +++ b/README.patches @@ -1001,7 +1001,7 @@ Individual patches for Vim 7.3: 3304 7.3.967 (after 7.3.965) build fails on Mac OSX 2100 7.3.968 multi-byte support is only available with "big" features 1603 7.3.969 can't built with Python 3 and without Python 2 -184170 7.3.970 pattern matching is slow, include the NFA engine +182647 7.3.970 (fixed) pattern matching is slow, include the NFA engine 4337 7.3.971 no support for VS2012 static code analysis 3720 7.3.972 cursor not restored properly after InsertEnter autocommand 3881 7.3.973 (after 7.3.970) compiler warnings, crash on startup @@ -1019,3 +1019,16 @@ Individual patches for Vim 7.3: 1691 7.3.985 GTK vim not started as gvim has WM_CLASS property wrong 2113 7.3.986 test 95 doesn't pass when 'encoding' isn't utf-8 6338 7.3.987 no easy to run an individual test; test 64 may fail + 1552 7.3.988 new regexp engine is slow + 1944 7.3.989 new regexp engine compares negative numbers to character + 7487 7.3.990 memory leak in new regexp engine + 18482 7.3.991 more can be shared between python 2 and 3 + 70337 7.3.992 Python: Too many type casts + 7832 7.3.993 (after 7.3.992) later patch does things slightly differently + 7845 7.3.994 Python: using magic constants + 13902 7.3.995 Python: Module initialization is duplicated + 14039 7.3.996 Python: Can't check types of what is returned by bindeval() + 23712 7.3.997 Vim and Python exceptions are different + 11177 7.3.998 Python: garbage collection issues + 4683 7.3.999 new regexp engine sets curbuf temporarily + 1637 7.3.1000 (whoa!) typo in char value causes out of bounds access diff --git a/vim.spec b/vim.spec index 87cd16f1..1fa76a45 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 987 +%define patchlevel 1000 Summary: The VIM editor URL: http://www.vim.org/ @@ -1043,6 +1043,19 @@ Patch984: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.984 Patch985: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.985 Patch986: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.986 Patch987: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.987 +Patch988: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.988 +Patch989: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.989 +Patch990: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.990 +Patch991: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.991 +Patch992: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.992 +Patch993: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.993 +Patch994: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.994 +Patch995: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.995 +Patch996: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.996 +Patch997: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.997 +Patch998: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.998 +Patch999: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.999 +Patch1000: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1000 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -2177,6 +2190,19 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch985 -p0 %patch986 -p0 %patch987 -p0 +%patch988 -p0 +%patch989 -p0 +%patch990 -p0 +%patch991 -p0 +%patch992 -p0 +%patch993 -p0 +%patch994 -p0 +%patch995 -p0 +%patch996 -p0 +%patch997 -p0 +%patch998 -p0 +%patch999 -p0 +%patch1000 -p0 # install spell files @@ -2672,6 +2698,9 @@ rm -rf %{buildroot} %{_datadir}/icons/hicolor/*/apps/* %changelog +* Wed May 22 2013 Karsten Hopp 7.3.1000-1 +- patchlevel 1000 ! + * Tue May 21 2013 Karsten Hopp 7.3.987-1 - patchlevel 987 From a10fc775f2e3de70153a32df66f58c7e8d5fb5e4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 22 May 2013 15:06:13 +0200 Subject: [PATCH 0891/3340] - patchlevel 1001 --- 7.3.1001 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 7.3.1001 diff --git a/7.3.1001 b/7.3.1001 new file mode 100644 index 00000000..a968fd70 --- /dev/null +++ b/7.3.1001 @@ -0,0 +1,54 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1001 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1001 +Problem: Duplicate condition in if. +Solution: Remove one condition. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1000/src/regexp_nfa.c 2013-05-21 21:20:16.000000000 +0200 +--- src/regexp_nfa.c 2013-05-21 21:56:45.000000000 +0200 +*************** +*** 1091,1097 **** + { + nfa_inc(®parse); + +! if (*regparse == 'n' || *regparse == 'n') + startc = reg_string ? NL : NFA_NEWL; + else + if (*regparse == 'd' +--- 1091,1097 ---- + { + nfa_inc(®parse); + +! if (*regparse == 'n') + startc = reg_string ? NL : NFA_NEWL; + else + if (*regparse == 'd' +*** ../vim-7.3.1000/src/version.c 2013-05-21 21:37:01.000000000 +0200 +--- src/version.c 2013-05-21 21:59:09.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1001, + /**/ + +-- +SECOND SOLDIER: It could be carried by an African swallow! +FIRST SOLDIER: Oh yes! An African swallow maybe ... but not a European + swallow. that's my point. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7b8f8e62b9438b8496a104ac67ba681232dbdee5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 22 May 2013 15:06:13 +0200 Subject: [PATCH 0892/3340] - patchlevel 1002 --- 7.3.1002 | 178 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 178 insertions(+) create mode 100644 7.3.1002 diff --git a/7.3.1002 b/7.3.1002 new file mode 100644 index 00000000..d76c5738 --- /dev/null +++ b/7.3.1002 @@ -0,0 +1,178 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1002 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1002 +Problem: Valgrind errors for Python interface. +Solution: Fix memory leaks when running tests. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1001/src/if_py_both.h 2013-05-21 20:51:55.000000000 +0200 +--- src/if_py_both.h 2013-05-21 22:08:25.000000000 +0200 +*************** +*** 866,871 **** +--- 866,872 ---- + DICTKEY_UNREF + + copy_tv(&tv, &di->di_tv); ++ clear_tv(&tv); + return 0; + } + +*************** +*** 1129,1134 **** +--- 1130,1136 ---- + { + if (list_append_tv(l, &tv) == FAIL) + { ++ clear_tv(&tv); + PyErr_SetVim(_("Failed to add item to list")); + return -1; + } +*************** +*** 1138,1143 **** +--- 1140,1146 ---- + li = list_find(l, (long) index); + clear_tv(&li->li_tv); + copy_tv(&tv, &li->li_tv); ++ clear_tv(&tv); + } + return 0; + } +*************** +*** 1204,1212 **** +--- 1207,1217 ---- + return -1; + if (list_insert_tv(l, &v, li) == FAIL) + { ++ clear_tv(&v); + PyErr_SetVim(_("internal error: failed to add item to list")); + return -1; + } ++ clear_tv(&v); + } + return 0; + } +*************** +*** 1346,1352 **** +--- 1351,1360 ---- + return NULL; + } + if (ConvertFromPyObject(selfdictObject, &selfdicttv) == -1) ++ { ++ clear_tv(&args); + return NULL; ++ } + selfdict = selfdicttv.vval.v_dict; + } + } +*************** +*** 1370,1382 **** + else + result = ConvertToPyObject(&rettv); + +- /* FIXME Check what should really be cleared. */ + clear_tv(&args); + clear_tv(&rettv); +! /* +! * if (selfdict!=NULL) +! * clear_tv(selfdicttv); +! */ + + return result; + } +--- 1378,1387 ---- + else + result = ConvertToPyObject(&rettv); + + clear_tv(&args); + clear_tv(&rettv); +! if (selfdict != NULL) +! clear_tv(&selfdicttv); + + return result; + } +*************** +*** 1482,1488 **** + } + else if (flags & SOPT_BOOL) + { +! PyObject *r; + r = numval ? Py_True : Py_False; + Py_INCREF(r); + return r; +--- 1487,1493 ---- + } + else if (flags & SOPT_BOOL) + { +! PyObject *r; + r = numval ? Py_True : Py_False; + Py_INCREF(r); + return r; +*************** +*** 1492,1498 **** + else if (flags & SOPT_STRING) + { + if (stringval) +! return PyBytes_FromString((char *) stringval); + else + { + PyErr_SetString(PyExc_RuntimeError, +--- 1497,1507 ---- + else if (flags & SOPT_STRING) + { + if (stringval) +! { +! PyObject *r = PyBytes_FromString((char *) stringval); +! vim_free(stringval); +! return r; +! } + else + { + PyErr_SetString(PyExc_RuntimeError, +*************** +*** 1516,1524 **** + int opt_type; + void *from; + { +! win_T *save_curwin; +! tabpage_T *save_curtab; +! buf_T *save_curbuf; + + VimTryStart(); + switch (opt_type) +--- 1525,1533 ---- + int opt_type; + void *from; + { +! win_T *save_curwin = NULL; +! tabpage_T *save_curtab = NULL; +! buf_T *save_curbuf = NULL; + + VimTryStart(); + switch (opt_type) +*** ../vim-7.3.1001/src/version.c 2013-05-21 22:00:42.000000000 +0200 +--- src/version.c 2013-05-21 22:12:54.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1002, + /**/ + +-- +"I've been teaching myself to play the piano for about 5 years and now write +most of my songs on it, mainly because I can never find any paper." + Jeff Lynne, ELO's greatest hits + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ed761cda269919f6d0a263bb97496d15b035b71f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 22 May 2013 15:06:14 +0200 Subject: [PATCH 0893/3340] - patchlevel 1003 --- 7.3.1003 | 381 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 381 insertions(+) create mode 100644 7.3.1003 diff --git a/7.3.1003 b/7.3.1003 new file mode 100644 index 00000000..cd84406c --- /dev/null +++ b/7.3.1003 @@ -0,0 +1,381 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1003 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1003 +Problem: Python interface does not compile with Python 2.2 +Solution: Fix thread issues and True/False. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c, + src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.1002/src/if_py_both.h 2013-05-21 22:13:36.000000000 +0200 +--- src/if_py_both.h 2013-05-21 22:16:58.000000000 +0200 +*************** +*** 31,37 **** + #define INVALID_TABPAGE_VALUE ((tabpage_T *)(-1)) + + typedef void (*rangeinitializer)(void *); +! typedef void (*runner)(const char *, void *, PyGILState_STATE *); + + static int ConvertFromPyObject(PyObject *, typval_T *); + static int _ConvertFromPyObject(PyObject *, typval_T *, PyObject *); +--- 31,41 ---- + #define INVALID_TABPAGE_VALUE ((tabpage_T *)(-1)) + + typedef void (*rangeinitializer)(void *); +! typedef void (*runner)(const char *, void * +! #ifdef PY_CAN_RECURSE +! , PyGILState_STATE * +! #endif +! ); + + static int ConvertFromPyObject(PyObject *, typval_T *); + static int _ConvertFromPyObject(PyObject *, typval_T *, PyObject *); +*************** +*** 3489,3495 **** + } + + static void +! run_cmd(const char *cmd, void *arg UNUSED, PyGILState_STATE *pygilstate UNUSED) + { + PyRun_SimpleString((char *) cmd); + } +--- 3493,3503 ---- + } + + static void +! run_cmd(const char *cmd, void *arg UNUSED +! #ifdef PY_CAN_RECURSE +! , PyGILState_STATE *pygilstate UNUSED +! #endif +! ) + { + PyRun_SimpleString((char *) cmd); + } +*************** +*** 3498,3504 **** + static int code_hdr_len = 30; + + static void +! run_do(const char *cmd, void *arg UNUSED, PyGILState_STATE *pygilstate) + { + PyInt lnum; + size_t len; +--- 3506,3516 ---- + static int code_hdr_len = 30; + + static void +! run_do(const char *cmd, void *arg UNUSED +! #ifdef PY_CAN_RECURSE +! , PyGILState_STATE *pygilstate +! #endif +! ) + { + PyInt lnum; + size_t len; +*************** +*** 3528,3540 **** +--- 3540,3556 ---- + status = 0; + pymain = PyImport_AddModule("__main__"); + pyfunc = PyObject_GetAttrString(pymain, DOPY_FUNC); ++ #ifdef PY_CAN_RECURSE + PyGILState_Release(*pygilstate); ++ #endif + + for (lnum = RangeStart; lnum <= RangeEnd; ++lnum) + { + PyObject *line, *linenr, *ret; + ++ #ifdef PY_CAN_RECURSE + *pygilstate = PyGILState_Ensure(); ++ #endif + if (!(line = GetBufferLine(curbuf, lnum))) + goto err; + if (!(linenr = PyInt_FromLong((long) lnum))) +*************** +*** 3554,3570 **** +--- 3570,3592 ---- + + Py_XDECREF(ret); + PythonIO_Flush(); ++ #ifdef PY_CAN_RECURSE + PyGILState_Release(*pygilstate); ++ #endif + } + goto out; + err: ++ #ifdef PY_CAN_RECURSE + *pygilstate = PyGILState_Ensure(); ++ #endif + PyErr_PrintEx(0); + PythonIO_Flush(); + status = 1; + out: ++ #ifdef PY_CAN_RECURSE + if (!status) + *pygilstate = PyGILState_Ensure(); ++ #endif + Py_DECREF(pyfunc); + PyObject_SetAttrString(pymain, DOPY_FUNC, NULL); + if (status) +*************** +*** 3574,3580 **** + } + + static void +! run_eval(const char *cmd, typval_T *rettv, PyGILState_STATE *pygilstate UNUSED) + { + PyObject *r; + +--- 3596,3606 ---- + } + + static void +! run_eval(const char *cmd, typval_T *rettv +! #ifdef PY_CAN_RECURSE +! , PyGILState_STATE *pygilstate UNUSED +! #endif +! ) + { + PyObject *r; + +*** ../vim-7.3.1002/src/if_python3.c 2013-05-21 20:51:55.000000000 +0200 +--- src/if_python3.c 2013-05-21 22:16:58.000000000 +0200 +*************** +*** 693,698 **** +--- 693,700 ---- + + static struct PyModuleDef vimmodule; + ++ #define PY_CAN_RECURSE ++ + /* + * Include the code shared with if_python.c + */ +*** ../vim-7.3.1002/src/if_python.c 2013-05-21 20:51:55.000000000 +0200 +--- src/if_python.c 2013-05-21 22:16:58.000000000 +0200 +*************** +*** 641,647 **** + #define DICTKEY_UNREF + #define DICTKEY_DECL + +! #define DESTRUCTOR_FINISH(self) Py_TYPE(self)->tp_free((PyObject*)self); + + #define WIN_PYTHON_REF(win) win->w_python_ref + #define BUF_PYTHON_REF(buf) buf->b_python_ref +--- 641,647 ---- + #define DICTKEY_UNREF + #define DICTKEY_DECL + +! #define DESTRUCTOR_FINISH(self) self->ob_type->tp_free((PyObject*)self); + + #define WIN_PYTHON_REF(win) win->w_python_ref + #define BUF_PYTHON_REF(buf) buf->b_python_ref +*************** +*** 656,661 **** +--- 656,670 ---- + static PyObject *ListGetattr(PyObject *, char *); + static PyObject *FunctionGetattr(PyObject *, char *); + ++ #ifndef Py_VISIT ++ # define Py_VISIT(obj) visit(obj, arg) ++ #endif ++ #ifndef Py_CLEAR ++ # define Py_CLEAR(obj) \ ++ Py_XDECREF(obj); \ ++ obj = NULL; ++ #endif ++ + /* + * Include the code shared with if_python3.c + */ +*************** +*** 881,887 **** + Python_RestoreThread(); /* enter python */ + #endif + +! run((char *) cmd, arg, &pygilstate); + + #ifdef PY_CAN_RECURSE + PyGILState_Release(pygilstate); +--- 890,900 ---- + Python_RestoreThread(); /* enter python */ + #endif + +! run((char *) cmd, arg +! #ifdef PY_CAN_RECURSE +! , &pygilstate +! #endif +! ); + + #ifdef PY_CAN_RECURSE + PyGILState_Release(pygilstate); +*** ../vim-7.3.1002/src/testdir/test86.in 2013-05-21 20:40:35.000000000 +0200 +--- src/testdir/test86.in 2013-05-21 22:16:58.000000000 +0200 +*************** +*** 518,523 **** +--- 518,527 ---- + :edit c + :buffer # + py << EOF ++ try: ++ from __builtin__ import next ++ except ImportError: ++ next = lambda o: o.next() + # Check GCing iterator that was not fully exhausted + i = iter(vim.buffers) + cb.append('i:' + str(next(i))) +*************** +*** 577,591 **** + cb.append('Number of tabs: ' + str(len(vim.tabpages))) + cb.append('Current tab pages:') + def W(w): +! if '(unknown)' in repr(w): + return '' + else: + return repr(w) + for t in vim.tabpages: + cb.append(' ' + repr(t) + '(' + str(t.number) + ')' + ': ' + str(len(t.windows)) + ' windows, current is ' + W(t.window)) + cb.append(' Windows:') + for w in t.windows: +! cb.append(' ' + W(w) + '(' + str(w.number) + ')' + ': displays buffer ' + repr(w.buffer) + '; cursor is at ' + repr(w.cursor)) + # Other values depend on the size of the terminal, so they are checked partly: + for attr in ('height', 'row', 'width', 'col'): + try: +--- 581,602 ---- + cb.append('Number of tabs: ' + str(len(vim.tabpages))) + cb.append('Current tab pages:') + def W(w): +! if repr(w).find('(unknown)') != -1: + return '' + else: + return repr(w) ++ ++ def Cursor(w, start=len(cb)): ++ if w.buffer is cb: ++ return repr((start - w.cursor[0], w.cursor[1])) ++ else: ++ return repr(w.cursor) ++ + for t in vim.tabpages: + cb.append(' ' + repr(t) + '(' + str(t.number) + ')' + ': ' + str(len(t.windows)) + ' windows, current is ' + W(t.window)) + cb.append(' Windows:') + for w in t.windows: +! cb.append(' ' + W(w) + '(' + str(w.number) + ')' + ': displays buffer ' + repr(w.buffer) + '; cursor is at ' + Cursor(w)) + # Other values depend on the size of the terminal, so they are checked partly: + for attr in ('height', 'row', 'width', 'col'): + try: +*** ../vim-7.3.1002/src/testdir/test86.ok 2013-05-21 20:40:35.000000000 +0200 +--- src/testdir/test86.ok 2013-05-21 22:18:02.000000000 +0200 +*************** +*** 333,339 **** + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (990, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +--- 333,339 ---- + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (27, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +*** ../vim-7.3.1002/src/testdir/test87.in 2013-05-21 20:40:35.000000000 +0200 +--- src/testdir/test87.in 2013-05-21 22:16:58.000000000 +0200 +*************** +*** 561,578 **** + :vnew b.2 + :vnew c.2 + py3 << EOF + def W(w): + if '(unknown)' in repr(w): + return '' + else: + return repr(w) +! cb.append('Number of tabs: ' + str(len(vim.tabpages))) +! cb.append('Current tab pages:') + for t in vim.tabpages: + cb.append(' ' + repr(t) + '(' + str(t.number) + ')' + ': ' + str(len(t.windows)) + ' windows, current is ' + W(t.window)) + cb.append(' Windows:') + for w in t.windows: +! cb.append(' ' + W(w) + '(' + str(w.number) + ')' + ': displays buffer ' + repr(w.buffer) + '; cursor is at ' + repr(w.cursor)) + # Other values depend on the size of the terminal, so they are checked partly: + for attr in ('height', 'row', 'width', 'col'): + try: +--- 561,586 ---- + :vnew b.2 + :vnew c.2 + py3 << EOF ++ cb.append('Number of tabs: ' + str(len(vim.tabpages))) ++ cb.append('Current tab pages:') ++ + def W(w): + if '(unknown)' in repr(w): + return '' + else: + return repr(w) +! +! def Cursor(w, start=len(cb)): +! if w.buffer is cb: +! return repr((start - w.cursor[0], w.cursor[1])) +! else: +! return repr(w.cursor) +! + for t in vim.tabpages: + cb.append(' ' + repr(t) + '(' + str(t.number) + ')' + ': ' + str(len(t.windows)) + ' windows, current is ' + W(t.window)) + cb.append(' Windows:') + for w in t.windows: +! cb.append(' ' + W(w) + '(' + str(w.number) + ')' + ': displays buffer ' + repr(w.buffer) + '; cursor is at ' + Cursor(w)) + # Other values depend on the size of the terminal, so they are checked partly: + for attr in ('height', 'row', 'width', 'col'): + try: +*** ../vim-7.3.1002/src/testdir/test87.ok 2013-05-21 20:40:35.000000000 +0200 +--- src/testdir/test87.ok 2013-05-21 22:18:31.000000000 +0200 +*************** +*** 322,328 **** + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (966, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +--- 322,328 ---- + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (27, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +*** ../vim-7.3.1002/src/version.c 2013-05-21 22:13:36.000000000 +0200 +--- src/version.c 2013-05-21 22:19:01.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1003, + /**/ + +-- +./configure +Checking whether build environment is sane ... +build environment is grinning and holding a spatula. Guess not. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6a194d5dcfbaf626c5d6f61b52340b568168565f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 22 May 2013 15:06:15 +0200 Subject: [PATCH 0894/3340] - patchlevel 1004 --- 7.3.1004 | 364 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 364 insertions(+) create mode 100644 7.3.1004 diff --git a/7.3.1004 b/7.3.1004 new file mode 100644 index 00000000..2498fe16 --- /dev/null +++ b/7.3.1004 @@ -0,0 +1,364 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1004 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1004 +Problem: No error when option could not be set. +Solution: Report an error. (ZyX) +Files: src/if_py_both.h, src/option.c, src/proto/option.pro, + src/testdir/test86.ok, src/testdir/test87.ok + + +*** ../vim-7.3.1003/src/if_py_both.h 2013-05-21 22:23:50.000000000 +0200 +--- src/if_py_both.h 2013-05-21 22:34:04.000000000 +0200 +*************** +*** 1521,1526 **** +--- 1521,1545 ---- + } + + static int ++ set_option_value_err(key, numval, stringval, opt_flags) ++ char_u *key; ++ int numval; ++ char_u *stringval; ++ int opt_flags; ++ { ++ char_u *errmsg; ++ ++ if ((errmsg = set_option_value(key, numval, stringval, opt_flags))) ++ { ++ if (VimTryEnd()) ++ return FAIL; ++ PyErr_SetVim((char *)errmsg); ++ return FAIL; ++ } ++ return OK; ++ } ++ ++ static int + set_option_value_for(key, numval, stringval, opt_flags, opt_type, from) + char_u *key; + int numval; +*************** +*** 1532,1537 **** +--- 1551,1557 ---- + win_T *save_curwin = NULL; + tabpage_T *save_curtab = NULL; + buf_T *save_curbuf = NULL; ++ int r = 0; + + VimTryStart(); + switch (opt_type) +*************** +*** 1545,1560 **** + PyErr_SetVim("Problem while switching windows."); + return -1; + } +! set_option_value(key, numval, stringval, opt_flags); + restore_win(save_curwin, save_curtab); + break; + case SREQ_BUF: + switch_buffer(&save_curbuf, (buf_T *)from); +! set_option_value(key, numval, stringval, opt_flags); + restore_buffer(save_curbuf); + break; + case SREQ_GLOBAL: +! set_option_value(key, numval, stringval, opt_flags); + break; + } + return VimTryEnd(); +--- 1565,1586 ---- + PyErr_SetVim("Problem while switching windows."); + return -1; + } +! r = set_option_value_err(key, numval, stringval, opt_flags); + restore_win(save_curwin, save_curtab); ++ if (r == FAIL) ++ return -1; + break; + case SREQ_BUF: + switch_buffer(&save_curbuf, (buf_T *)from); +! r = set_option_value_err(key, numval, stringval, opt_flags); + restore_buffer(save_curbuf); ++ if (r == FAIL) ++ return -1; + break; + case SREQ_GLOBAL: +! r = set_option_value_err(key, numval, stringval, opt_flags); +! if (r == FAIL) +! return -1; + break; + } + return VimTryEnd(); +*************** +*** 1611,1616 **** +--- 1637,1643 ---- + if (flags & SOPT_BOOL) + { + int istrue = PyObject_IsTrue(valObject); ++ + if (istrue == -1) + return -1; + r = set_option_value_for(key, istrue, NULL, +*** ../vim-7.3.1003/src/option.c 2013-05-19 19:16:25.000000000 +0200 +--- src/option.c 2013-05-21 22:34:41.000000000 +0200 +*************** +*** 3018,3024 **** + # define insecure_flag(opt_idx, opt_flags) (&options[opt_idx].flags) + #endif + static void set_string_option_global __ARGS((int opt_idx, char_u **varp)); +! static void set_string_option __ARGS((int opt_idx, char_u *value, int opt_flags)); + static char_u *did_set_string_option __ARGS((int opt_idx, char_u **varp, int new_value_alloced, char_u *oldval, char_u *errbuf, int opt_flags)); + static char_u *set_chars_option __ARGS((char_u **varp)); + #ifdef FEAT_SYN_HL +--- 3018,3024 ---- + # define insecure_flag(opt_idx, opt_flags) (&options[opt_idx].flags) + #endif + static void set_string_option_global __ARGS((int opt_idx, char_u **varp)); +! static char_u *set_string_option __ARGS((int opt_idx, char_u *value, int opt_flags)); + static char_u *did_set_string_option __ARGS((int opt_idx, char_u **varp, int new_value_alloced, char_u *oldval, char_u *errbuf, int opt_flags)); + static char_u *set_chars_option __ARGS((char_u **varp)); + #ifdef FEAT_SYN_HL +*************** +*** 5600,5607 **** + + /* + * Set a string option to a new value, and handle the effects. + */ +! static void + set_string_option(opt_idx, value, opt_flags) + int opt_idx; + char_u *value; +--- 5600,5609 ---- + + /* + * Set a string option to a new value, and handle the effects. ++ * ++ * Returns NULL on success or error message on error. + */ +! static char_u * + set_string_option(opt_idx, value, opt_flags) + int opt_idx; + char_u *value; +*************** +*** 5610,5618 **** + char_u *s; + char_u **varp; + char_u *oldval; + + if (options[opt_idx].var == NULL) /* don't set hidden option */ +! return; + + s = vim_strsave(value); + if (s != NULL) +--- 5612,5621 ---- + char_u *s; + char_u **varp; + char_u *oldval; ++ char_u *r = NULL; + + if (options[opt_idx].var == NULL) /* don't set hidden option */ +! return NULL; + + s = vim_strsave(value); + if (s != NULL) +*************** +*** 5624,5633 **** + : opt_flags); + oldval = *varp; + *varp = s; +! if (did_set_string_option(opt_idx, varp, TRUE, oldval, NULL, +! opt_flags) == NULL) + did_set_option(opt_idx, opt_flags, TRUE); + } + } + + /* +--- 5627,5637 ---- + : opt_flags); + oldval = *varp; + *varp = s; +! if ((r = did_set_string_option(opt_idx, varp, TRUE, oldval, NULL, +! opt_flags)) == NULL) + did_set_option(opt_idx, opt_flags, TRUE); + } ++ return r; + } + + /* +*************** +*** 8969,8976 **** + /* + * Set the value of option "name". + * Use "string" for string options, use "number" for other options. + */ +! void + set_option_value(name, number, string, opt_flags) + char_u *name; + long number; +--- 8973,8982 ---- + /* + * Set the value of option "name". + * Use "string" for string options, use "number" for other options. ++ * ++ * Returns NULL on success or error message on error. + */ +! char_u * + set_option_value(name, number, string, opt_flags) + char_u *name; + long number; +*************** +*** 8992,9002 **** + if (sandbox > 0 && (flags & P_SECURE)) + { + EMSG(_(e_sandbox)); +! return; + } + #endif + if (flags & P_STRING) +! set_string_option(opt_idx, string, opt_flags); + else + { + varp = get_varp_scope(&(options[opt_idx]), opt_flags); +--- 8998,9008 ---- + if (sandbox > 0 && (flags & P_SECURE)) + { + EMSG(_(e_sandbox)); +! return NULL; + } + #endif + if (flags & P_STRING) +! return set_string_option(opt_idx, string, opt_flags); + else + { + varp = get_varp_scope(&(options[opt_idx]), opt_flags); +*************** +*** 9017,9035 **** + * num option using a string. */ + EMSG3(_("E521: Number required: &%s = '%s'"), + name, string); +! return; /* do nothing as we hit an error */ + + } + } + if (flags & P_NUM) +! (void)set_num_option(opt_idx, varp, number, + NULL, 0, opt_flags); + else +! (void)set_bool_option(opt_idx, varp, (int)number, + opt_flags); + } + } + } + } + + /* +--- 9023,9042 ---- + * num option using a string. */ + EMSG3(_("E521: Number required: &%s = '%s'"), + name, string); +! return NULL; /* do nothing as we hit an error */ + + } + } + if (flags & P_NUM) +! return set_num_option(opt_idx, varp, number, + NULL, 0, opt_flags); + else +! return set_bool_option(opt_idx, varp, (int)number, + opt_flags); + } + } + } ++ return NULL; + } + + /* +*** ../vim-7.3.1003/src/proto/option.pro 2013-05-06 03:52:44.000000000 +0200 +--- src/proto/option.pro 2013-05-21 22:27:50.000000000 +0200 +*************** +*** 23,29 **** + char_u *check_stl_option __ARGS((char_u *s)); + int get_option_value __ARGS((char_u *name, long *numval, char_u **stringval, int opt_flags)); + int get_option_value_strict __ARGS((char_u *name, long *numval, char_u **stringval, int opt_type, void *from)); +! void set_option_value __ARGS((char_u *name, long number, char_u *string, int opt_flags)); + char_u *get_term_code __ARGS((char_u *tname)); + char_u *get_highlight_default __ARGS((void)); + char_u *get_encoding_default __ARGS((void)); +--- 23,29 ---- + char_u *check_stl_option __ARGS((char_u *s)); + int get_option_value __ARGS((char_u *name, long *numval, char_u **stringval, int opt_flags)); + int get_option_value_strict __ARGS((char_u *name, long *numval, char_u **stringval, int opt_type, void *from)); +! char_u *set_option_value __ARGS((char_u *name, long number, char_u *string, int opt_flags)); + char_u *get_term_code __ARGS((char_u *tname)); + char_u *get_highlight_default __ARGS((void)); + char_u *get_encoding_default __ARGS((void)); +*** ../vim-7.3.1003/src/testdir/test86.ok 2013-05-21 22:23:51.000000000 +0200 +--- src/testdir/test86.ok 2013-05-21 22:27:50.000000000 +0200 +*************** +*** 166,171 **** +--- 166,172 ---- + inv: -100! KeyError + gopts1! KeyError + p/wopts1: 8 ++ inv: -100! error + p/bopts1! KeyError + inv: -100! KeyError + bopts1! KeyError +*************** +*** 184,189 **** +--- 185,191 ---- + inv: 'abc'! KeyError + gopts1! KeyError + p/wopts1: '' ++ inv: 'abc'! error + p/bopts1! KeyError + inv: 'abc'! KeyError + bopts1! KeyError +*** ../vim-7.3.1003/src/testdir/test87.ok 2013-05-21 22:23:51.000000000 +0200 +--- src/testdir/test87.ok 2013-05-21 22:27:50.000000000 +0200 +*************** +*** 155,160 **** +--- 155,161 ---- + inv: -100! KeyError + gopts1! KeyError + p/wopts1: 8 ++ inv: -100! error + p/bopts1! KeyError + inv: -100! KeyError + bopts1! KeyError +*************** +*** 173,178 **** +--- 174,180 ---- + inv: 'abc'! KeyError + gopts1! KeyError + p/wopts1: b'' ++ inv: 'abc'! error + p/bopts1! KeyError + inv: 'abc'! KeyError + bopts1! KeyError +*** ../vim-7.3.1003/src/version.c 2013-05-21 22:23:51.000000000 +0200 +--- src/version.c 2013-05-21 22:37:33.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1004, + /**/ + +-- +FIRST SOLDIER: So they wouldn't be able to bring a coconut back anyway. +SECOND SOLDIER: Wait a minute! Suppose two swallows carried it together? +FIRST SOLDIER: No, they'd have to have it on a line. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4874ab7d0a77b56500bc77e5758e5ca6421d725a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 22 May 2013 15:06:16 +0200 Subject: [PATCH 0895/3340] - patchlevel 1004 --- README.patches | 4 ++++ vim.spec | 13 ++++++++++++- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index b2044a56..de26f645 100644 --- a/README.patches +++ b/README.patches @@ -1032,3 +1032,7 @@ Individual patches for Vim 7.3: 11177 7.3.998 Python: garbage collection issues 4683 7.3.999 new regexp engine sets curbuf temporarily 1637 7.3.1000 (whoa!) typo in char value causes out of bounds access + 1651 7.3.1001 duplicate condition in if + 4012 7.3.1002 valgrind errors for Python interface + 11873 7.3.1003 Python interface does not compile with Python 2.2 + 10551 7.3.1004 Python: no error when option could not be set diff --git a/vim.spec b/vim.spec index 1fa76a45..efb6c8d0 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 1000 +%define patchlevel 1004 Summary: The VIM editor URL: http://www.vim.org/ @@ -1056,6 +1056,10 @@ Patch997: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.997 Patch998: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.998 Patch999: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.999 Patch1000: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1000 +Patch1001: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1001 +Patch1002: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1002 +Patch1003: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1003 +Patch1004: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1004 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -2203,6 +2207,10 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch998 -p0 %patch999 -p0 %patch1000 -p0 +%patch1001 -p0 +%patch1002 -p0 +%patch1003 -p0 +%patch1004 -p0 # install spell files @@ -2698,6 +2706,9 @@ rm -rf %{buildroot} %{_datadir}/icons/hicolor/*/apps/* %changelog +* Wed May 22 2013 Karsten Hopp 7.3.1004-1 +- patchlevel 1004 + * Wed May 22 2013 Karsten Hopp 7.3.1000-1 - patchlevel 1000 ! From 6d666be5d60d08fac9478e1f34c204b025c707f5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:05:53 +0200 Subject: [PATCH 0896/3340] - patchlevel 1005 --- 7.3.1005 | 265 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 265 insertions(+) create mode 100644 7.3.1005 diff --git a/7.3.1005 b/7.3.1005 new file mode 100644 index 00000000..dbc05c29 --- /dev/null +++ b/7.3.1005 @@ -0,0 +1,265 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1005 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1005 +Problem: Get stuck on regexp "\n*" and on "%s/^\n\+/\r". +Solution: Fix handling of matching a line break. (idea by Hirohito Higashi) +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1004/src/regexp_nfa.c 2013-05-21 22:00:42.000000000 +0200 +--- src/regexp_nfa.c 2013-05-22 22:53:08.000000000 +0200 +*************** +*** 2462,2468 **** + List *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ + regsub_T *m; /* pointers to subexpressions */ +! int off; + int lid; + int *match; /* found match? */ + { +--- 2462,2468 ---- + List *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ + regsub_T *m; /* pointers to subexpressions */ +! int off; /* byte offset, when -1 go to next line */ + int lid; + int *match; /* found match? */ + { +*************** +*** 2585,2592 **** + { + save.startpos[subidx] = m->startpos[subidx]; + save.endpos[subidx] = m->endpos[subidx]; +! m->startpos[subidx].lnum = reglnum; +! m->startpos[subidx].col = (colnr_T)(reginput - regline + off); + } + else + { +--- 2585,2601 ---- + { + save.startpos[subidx] = m->startpos[subidx]; + save.endpos[subidx] = m->endpos[subidx]; +! if (off == -1) +! { +! m->startpos[subidx].lnum = reglnum + 1; +! m->startpos[subidx].col = 0; +! } +! else +! { +! m->startpos[subidx].lnum = reglnum; +! m->startpos[subidx].col = +! (colnr_T)(reginput - regline + off); +! } + } + else + { +*************** +*** 2633,2640 **** + { + save.startpos[subidx] = m->startpos[subidx]; + save.endpos[subidx] = m->endpos[subidx]; +! m->endpos[subidx].lnum = reglnum; +! m->endpos[subidx].col = (colnr_T)(reginput - regline + off); + } + else + { +--- 2642,2657 ---- + { + save.startpos[subidx] = m->startpos[subidx]; + save.endpos[subidx] = m->endpos[subidx]; +! if (off == -1) +! { +! m->endpos[subidx].lnum = reglnum + 1; +! m->endpos[subidx].col = 0; +! } +! else +! { +! m->endpos[subidx].lnum = reglnum; +! m->endpos[subidx].col = (colnr_T)(reginput - regline + off); +! } + } + else + { +*************** +*** 2834,2840 **** + int match = FALSE; + int flag = 0; + int old_reglnum = -1; +! int reginput_updated = FALSE; + thread_T *t; + char_u *old_reginput = NULL; + char_u *old_regline = NULL; +--- 2851,2857 ---- + int match = FALSE; + int flag = 0; + int old_reglnum = -1; +! int go_to_nextline; + thread_T *t; + char_u *old_reginput = NULL; + char_u *old_regline = NULL; +*************** +*** 2917,2924 **** + /* + * Run for each character. + */ +! do { +! again: + #ifdef FEAT_MBYTE + if (has_mbyte) + { +--- 2934,2941 ---- + /* + * Run for each character. + */ +! for (;;) +! { + #ifdef FEAT_MBYTE + if (has_mbyte) + { +*************** +*** 2932,2938 **** +--- 2949,2958 ---- + n = 1; + } + if (c == NUL) ++ { + n = 0; ++ go_to_nextline = FALSE; ++ } + + /* swap lists */ + thislist = &list[flag]; +*************** +*** 3007,3013 **** + (char *)t->sub.end[j]); + fprintf(log_fd, "\n"); + #endif +! goto nextchar; /* found the left-most longest match */ + + case NFA_END_INVISIBLE: + /* This is only encountered after a NFA_START_INVISIBLE node. +--- 3027,3035 ---- + (char *)t->sub.end[j]); + fprintf(log_fd, "\n"); + #endif +! /* Found the left-most longest match, do not look at any other +! * states at this position. */ +! goto nextchar; + + case NFA_END_INVISIBLE: + /* This is only encountered after a NFA_START_INVISIBLE node. +*************** +*** 3206,3220 **** + + case NFA_NEWL: + if (!reg_line_lbr && REG_MULTI +! && c == NUL && reglnum <= reg_maxline) + { +! if (reginput_updated == FALSE) +! { +! reg_nextline(); +! reginput_updated = TRUE; +! } +! addstate(nextlist, t->state->out, &t->sub, n, listid + 1, +! &match); + } + break; + +--- 3228,3240 ---- + + case NFA_NEWL: + if (!reg_line_lbr && REG_MULTI +! && c == NUL && reglnum <= reg_maxline) + { +! go_to_nextline = TRUE; +! /* Pass -1 for the offset, which means taking the position +! * at the start of the next line. */ +! addstate(nextlist, t->state->out, &t->sub, -1, +! listid + 1, &match); + } + break; + +*************** +*** 3247,3254 **** + break; + + case NFA_ANY: +! /* Any printable char, not just any char. '\0' (end of input) +! * must not match */ + if (c > 0) + addstate(nextlist, t->state->out, &t->sub, n, listid + 1, + &match); +--- 3267,3273 ---- + break; + + case NFA_ANY: +! /* Any char except '\0', (end of input) does not match. */ + if (c > 0) + addstate(nextlist, t->state->out, &t->sub, n, listid + 1, + &match); +*************** +*** 3433,3444 **** + addstate(nextlist, start, m, n, listid + 1, &match); + } + +- if (reginput_updated) +- { +- reginput_updated = FALSE; +- goto again; +- } +- + #ifdef ENABLE_LOG + fprintf(log_fd, ">>> Thislist had %d states available: ", thislist->n); + for (i = 0; i< thislist->n; i++) +--- 3452,3457 ---- +*************** +*** 3447,3454 **** + #endif + + nextchar: +! reginput += n; +! } while (c || reginput_updated); + + #ifdef ENABLE_LOG + if (log_fd != stderr) +--- 3460,3474 ---- + #endif + + nextchar: +! /* Advance to the next character, or advance to the next line, or +! * finish. */ +! if (n != 0) +! reginput += n; +! else if (go_to_nextline) +! reg_nextline(); +! else +! break; +! } + + #ifdef ENABLE_LOG + if (log_fd != stderr) +*** ../vim-7.3.1004/src/version.c 2013-05-21 22:38:14.000000000 +0200 +--- src/version.c 2013-05-22 22:57:59.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1005, + /**/ + +-- +"Lisp has all the visual appeal of oatmeal with nail clippings thrown in." + -- Larry Wall + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 88ed77b54b9520a960df9ea1b52d5796c74844bf Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:05:53 +0200 Subject: [PATCH 0897/3340] - patchlevel 1006 --- 7.3.1006 | 74 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 7.3.1006 diff --git a/7.3.1006 b/7.3.1006 new file mode 100644 index 00000000..c5e05fb3 --- /dev/null +++ b/7.3.1006 @@ -0,0 +1,74 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1006 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1006 +Problem: NFA engine not used for "\_[0-9]". +Solution: Enable this, fixed in patch 1005. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1005/src/regexp_nfa.c 2013-05-22 23:00:34.000000000 +0200 +--- src/regexp_nfa.c 2013-05-23 22:19:29.000000000 +0200 +*************** +*** 679,687 **** + + /* "\_[" is collection plus newline */ + if (c == '[') +! /* TODO: make this work +! * goto collection; */ +! return FAIL; + + /* "\_x" is character class plus newline */ + /*FALLTHROUGH*/ +--- 679,685 ---- + + /* "\_[" is collection plus newline */ + if (c == '[') +! goto collection; + + /* "\_x" is character class plus newline */ + /*FALLTHROUGH*/ +*************** +*** 891,898 **** + } + break; + +- /* collection: */ + case Magic('['): + /* + * Glue is emitted between several atoms from the []. + * It is either NFA_OR, or NFA_CONCAT. +--- 889,896 ---- + } + break; + + case Magic('['): ++ collection: + /* + * Glue is emitted between several atoms from the []. + * It is either NFA_OR, or NFA_CONCAT. +*** ../vim-7.3.1005/src/version.c 2013-05-22 23:00:34.000000000 +0200 +--- src/version.c 2013-05-23 22:23:07.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1006, + /**/ + +-- +BLACK KNIGHT: I'm invincible! +ARTHUR: You're a looney. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e92fdfe5bf8713ae7a1133deb70a678d467f0990 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:05:54 +0200 Subject: [PATCH 0898/3340] - patchlevel 1007 --- 7.3.1007 | 57 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 7.3.1007 diff --git a/7.3.1007 b/7.3.1007 new file mode 100644 index 00000000..a7e758e4 --- /dev/null +++ b/7.3.1007 @@ -0,0 +1,57 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1007 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1007 +Problem: Can't build on Minix 3.2.1. +Solution: Add a condition to an #ifdef. (Gautam Tirumala) +Files: src/memfile.c + + +*** ../vim-7.3.1006/src/memfile.c 2013-05-06 04:21:35.000000000 +0200 +--- src/memfile.c 2013-05-23 22:22:22.000000000 +0200 +*************** +*** 127,133 **** + { + memfile_T *mfp; + off_t size; +! #if defined(STATFS) && defined(UNIX) && !defined(__QNX__) + # define USE_FSTATFS + struct STATFS stf; + #endif +--- 127,133 ---- + { + memfile_T *mfp; + off_t size; +! #if defined(STATFS) && defined(UNIX) && !defined(__QNX__) && !defined(__minix) + # define USE_FSTATFS + struct STATFS stf; + #endif +*** ../vim-7.3.1006/src/version.c 2013-05-23 22:25:10.000000000 +0200 +--- src/version.c 2013-05-23 22:26:16.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1007, + /**/ + +-- +Mrs Abbott: I'm a paediatrician. + Basil: Feet? +Mrs Abbott: Children. + Sybil: Oh, Basil! + Basil: Well, children have feet, don't they? That's how they move + around, my dear. You must take a look next time, it's most + interesting. (Fawlty Towers) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b61b00ca84e58dbbd43abac4bc8a68e6826fa4dd Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:05:54 +0200 Subject: [PATCH 0899/3340] - patchlevel 1008 --- 7.3.1008 | 76 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 7.3.1008 diff --git a/7.3.1008 b/7.3.1008 new file mode 100644 index 00000000..1dc03762 --- /dev/null +++ b/7.3.1008 @@ -0,0 +1,76 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1008 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1008 +Problem: Test 95 fails on MS-Windows. +Solution: Set 'nomore'. Change \i to \f. Change multi-byte character to + something that is not matching \i. (Ken Takata) +Files: src/testdir/test95.in, src/testdir/test95.ok + + +*** ../vim-7.3.1007/src/testdir/test95.in 2013-05-21 13:30:17.000000000 +0200 +--- src/testdir/test95.in 2013-05-23 22:36:22.000000000 +0200 +*************** +*** 30,39 **** + :call add(tl, ['\p\+', 'ìa', 'ìa']) + + :"""" Test recognition of some character classes +! :call add(tl, ['\i\+', '&*§xx ', 'xx']) +! :call add(tl, ['\%#=1\i\+', '&*§xx ', 'xx']) + :call add(tl, ['\f\+', '&*Ÿfname ', 'fname']) +! :call add(tl, ['\%#=1\i\+', '&*Ÿfname ', 'fname']) + + :"""" Combining different tests and features + :call add(tl, ['[^[=a=]]\+', 'ddaãâbcd', 'dd']) +--- 30,39 ---- + :call add(tl, ['\p\+', 'ìa', 'ìa']) + + :"""" Test recognition of some character classes +! :call add(tl, ['\i\+', '&*¨xx ', 'xx']) +! :call add(tl, ['\%#=1\i\+', '&*¨xx ', 'xx']) + :call add(tl, ['\f\+', '&*Ÿfname ', 'fname']) +! :call add(tl, ['\%#=1\f\+', '&*Ÿfname ', 'fname']) + + :"""" Combining different tests and features + :call add(tl, ['[^[=a=]]\+', 'ddaãâbcd', 'dd']) +*** ../vim-7.3.1007/src/testdir/test95.ok 2013-05-21 13:30:17.000000000 +0200 +--- src/testdir/test95.ok 2013-05-23 19:34:01.000000000 +0200 +*************** +*** 8,12 **** + OK - \i\+ + OK - \%#=1\i\+ + OK - \f\+ +! OK - \%#=1\i\+ + OK - [^[=a=]]\+ +--- 8,12 ---- + OK - \i\+ + OK - \%#=1\i\+ + OK - \f\+ +! OK - \%#=1\f\+ + OK - [^[=a=]]\+ +*** ../vim-7.3.1007/src/version.c 2013-05-23 22:26:50.000000000 +0200 +--- src/version.c 2013-05-23 22:39:37.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1008, + /**/ + +-- +BLACK KNIGHT: The Black Knight always triumphs. Have at you! + ARTHUR takes his last leg off. The BLACK KNIGHT's body lands upright. +BLACK KNIGHT: All right, we'll call it a draw. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 88e430898262a4cbfc7d18a2841ecebc9320e5bd Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:05:55 +0200 Subject: [PATCH 0900/3340] - patchlevel 1009 --- 7.3.1009 | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 7.3.1009 diff --git a/7.3.1009 b/7.3.1009 new file mode 100644 index 00000000..3fa2107b --- /dev/null +++ b/7.3.1009 @@ -0,0 +1,50 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1009 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1009 +Problem: Compiler warning for ambiguous else. +Solution: Add curly braces. +Files: src/if_py_both.h + + +*** ../vim-7.3.1008/src/if_py_both.h 2013-05-21 22:38:14.000000000 +0200 +--- src/if_py_both.h 2013-05-24 18:54:32.000000000 +0200 +*************** +*** 2163,2169 **** +--- 2163,2171 ---- + TabPageObject *tabObject = self->tabObject; + + if (tabObject) ++ { + Py_DECREF((PyObject *)(tabObject)); ++ } + + DESTRUCTOR_FINISH(self); + } +*** ../vim-7.3.1008/src/version.c 2013-05-23 22:43:03.000000000 +0200 +--- src/version.c 2013-05-24 18:58:10.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1009, + /**/ + +-- +BEDEVERE: Why do you think she is a witch? +SECOND VILLAGER: She turned me into a newt. +BEDEVERE: A newt? +SECOND VILLAGER: (After looking at himself for some time) I got better. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7ec0acef8f13e4924670ea221ed5fe0b568613bb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:05:56 +0200 Subject: [PATCH 0901/3340] - patchlevel 1010 --- 7.3.1010 | 174 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 174 insertions(+) create mode 100644 7.3.1010 diff --git a/7.3.1010 b/7.3.1010 new file mode 100644 index 00000000..7fafb935 --- /dev/null +++ b/7.3.1010 @@ -0,0 +1,174 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1010 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1010 +Problem: New regexp: adding \Z makes every character match. +Solution: Only apply ireg_icombine for composing characters. + Alsl add missing change from patch 1008. (Ken Takata) +Files: src/regexp_nfa.c, src/testdir/test95.in, src/testdir/test95.ok + + +*** ../vim-7.3.1009/src/regexp_nfa.c 2013-05-23 22:25:10.000000000 +0200 +--- src/regexp_nfa.c 2013-05-24 20:20:14.000000000 +0200 +*************** +*** 2859,2865 **** + List *listtbl[2][2]; + List *ll; + int listid = 1; +! int endnode = 0; + List *thislist; + List *nextlist; + List *neglist; +--- 2859,2865 ---- + List *listtbl[2][2]; + List *ll; + int listid = 1; +! int endnode; + List *thislist; + List *nextlist; + List *neglist; +*************** +*** 3192,3204 **** + + case NFA_MULTIBYTE: + case NFA_COMPOSING: +! switch (t->state->c) +! { +! case NFA_MULTIBYTE: endnode = NFA_END_MULTIBYTE; break; +! case NFA_COMPOSING: endnode = NFA_END_COMPOSING; break; +! default: endnode = 0; +! } +! + result = OK; + sta = t->state->out; + len = 1; +--- 3192,3198 ---- + + case NFA_MULTIBYTE: + case NFA_COMPOSING: +! endnode = t->state->c + 1; + result = OK; + sta = t->state->out; + len = 1; +*************** +*** 3206,3212 **** + { + if (reginput[len-1] != sta->c) + { +! result = OK - 1; + break; + } + len++; +--- 3200,3206 ---- + { + if (reginput[len-1] != sta->c) + { +! result = FAIL; + break; + } + len++; +*************** +*** 3215,3225 **** + + /* if input char length doesn't match regexp char length */ + if (len -1 < n || sta->c != endnode) +! result = OK - 1; + end = t->state->out1; /* NFA_END_MULTIBYTE or + NFA_END_COMPOSING */ + /* If \Z was present, then ignore composing characters */ +! if (regflags & RF_ICOMBINE) + result = 1 ^ sta->negated; + ADD_POS_NEG_STATE(end); + break; +--- 3209,3219 ---- + + /* if input char length doesn't match regexp char length */ + if (len -1 < n || sta->c != endnode) +! result = FAIL; + end = t->state->out1; /* NFA_END_MULTIBYTE or + NFA_END_COMPOSING */ + /* If \Z was present, then ignore composing characters */ +! if (ireg_icombine && endnode == NFA_END_COMPOSING) + result = 1 ^ sta->negated; + ADD_POS_NEG_STATE(end); + break; +*** ../vim-7.3.1009/src/testdir/test95.in 2013-05-23 22:43:03.000000000 +0200 +--- src/testdir/test95.in 2013-05-24 20:18:13.000000000 +0200 +*************** +*** 7,13 **** + STARTTEST + :so small.vim + :so mbyte.vim +! :set nocp encoding=utf-8 viminfo+=nviminfo + :" tl is a List of Lists with: + :" regexp pattern + :" text to test the pattern on +--- 7,13 ---- + STARTTEST + :so small.vim + :so mbyte.vim +! :set nocp encoding=utf-8 viminfo+=nviminfo nomore + :" tl is a List of Lists with: + :" regexp pattern + :" text to test the pattern on +*************** +*** 35,45 **** + :call add(tl, ['\f\+', '&*Ÿfname ', 'fname']) + :call add(tl, ['\%#=1\f\+', '&*Ÿfname ', 'fname']) + + :"""" Combining different tests and features + :call add(tl, ['[^[=a=]]\+', 'ddaãâbcd', 'dd']) + + :"""" Run the tests +- + :" + :for t in tl + : let l = matchlist(t[1], t[0]) +--- 35,47 ---- + :call add(tl, ['\f\+', '&*Ÿfname ', 'fname']) + :call add(tl, ['\%#=1\f\+', '&*Ÿfname ', 'fname']) + ++ :"""" Test \Z ++ :call add(tl, ['ú\Z', 'x']) ++ + :"""" Combining different tests and features + :call add(tl, ['[^[=a=]]\+', 'ddaãâbcd', 'dd']) + + :"""" Run the tests + :" + :for t in tl + : let l = matchlist(t[1], t[0]) +*** ../vim-7.3.1009/src/testdir/test95.ok 2013-05-23 22:43:03.000000000 +0200 +--- src/testdir/test95.ok 2013-05-24 20:18:55.000000000 +0200 +*************** +*** 9,12 **** +--- 9,13 ---- + OK - \%#=1\i\+ + OK - \f\+ + OK - \%#=1\f\+ ++ OK - ú\Z + OK - [^[=a=]]\+ +*** ../vim-7.3.1009/src/version.c 2013-05-24 18:58:39.000000000 +0200 +--- src/version.c 2013-05-24 20:21:52.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1010, + /**/ + +-- +Never under any circumstances take a sleeping pill +and a laxative on the same night. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ca9c198de7c572cc49770f24800e8b91e403ddc3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:05:56 +0200 Subject: [PATCH 0902/3340] - patchlevel 1011 --- 7.3.1011 | 475 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 475 insertions(+) create mode 100644 7.3.1011 diff --git a/7.3.1011 b/7.3.1011 new file mode 100644 index 00000000..0e2304bc --- /dev/null +++ b/7.3.1011 @@ -0,0 +1,475 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1011 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1011 +Problem: New regexp engine is inefficient with multi-byte characters. +Solution: Handle a character at a time instead of a byte at a time. Also + make \Z partly work. +Files: src/regexp_nfa.c, src/testdir/test95.in, src/testdir/test95.ok + + +*** ../vim-7.3.1010/src/regexp_nfa.c 2013-05-24 20:25:28.000000000 +0200 +--- src/regexp_nfa.c 2013-05-24 21:49:43.000000000 +0200 +*************** +*** 46,54 **** + NFA_NCLOSE, /* End of subexpr. marked with \%( ... \) */ + NFA_START_INVISIBLE, + NFA_END_INVISIBLE, +- NFA_MULTIBYTE, /* Next nodes in NFA are part of the same +- multibyte char */ +- NFA_END_MULTIBYTE, /* End of multibyte char in the NFA */ + NFA_COMPOSING, /* Next nodes in NFA are part of the + composing multibyte char */ + NFA_END_COMPOSING, /* End of a composing char in the NFA */ +--- 46,51 ---- +*************** +*** 195,220 **** + *post_ptr++ = c; \ + } while (0) + +- #define EMIT_MBYTE(c) \ +- len = (*mb_char2bytes)(c, buf); \ +- EMIT(buf[0]); \ +- for (i = 1; i < len; i++) \ +- { \ +- EMIT(buf[i]); \ +- EMIT(NFA_CONCAT); \ +- } \ +- EMIT(NFA_MULTIBYTE); +- +- #define EMIT_COMPOSING_UTF(input) \ +- len = utfc_ptr2len(input); \ +- EMIT(input[0]); \ +- for (i = 1; i < len; i++) \ +- { \ +- EMIT(input[i]); \ +- EMIT(NFA_CONCAT); \ +- } \ +- EMIT(NFA_COMPOSING); +- + /* + * Initialize internal variables before NFA compilation. + * Return OK on success, FAIL otherwise. +--- 192,197 ---- +*************** +*** 611,618 **** + #ifdef FEAT_MBYTE + char_u *old_regparse = regparse; + int clen; +- int len; +- static char_u buf[30]; + int i; + #endif + int extra = 0; +--- 588,593 ---- +*************** +*** 845,858 **** + return FAIL; + + c = coll_get_char(); +! #ifdef FEAT_MBYTE +! if ((*mb_char2len)(c) > 1) +! { +! EMIT_MBYTE(c); +! } +! else +! #endif +! EMIT(c); + break; + + /* Catch \%^ and \%$ regardless of where they appear in the +--- 820,826 ---- + return FAIL; + + c = coll_get_char(); +! EMIT(c); + break; + + /* Catch \%^ and \%$ regardless of where they appear in the +*************** +*** 1135,1146 **** + * skip it. */ + for (c = startc + 1; c <= endc; c++) + { +! if ((*mb_char2len)(c) > 1) +! { +! EMIT_MBYTE(c); +! } +! else +! EMIT(c); + TRY_NEG(); + EMIT_GLUE(); + } +--- 1103,1109 ---- + * skip it. */ + for (c = startc + 1; c <= endc; c++) + { +! EMIT(c); + TRY_NEG(); + EMIT_GLUE(); + } +*************** +*** 1187,1200 **** + if (got_coll_char == TRUE && startc == 0) + EMIT(0x0a); + else +! #ifdef FEAT_MBYTE +! if ((*mb_char2len)(startc) > 1) +! { +! EMIT_MBYTE(startc); +! } +! else +! #endif +! EMIT(startc); + TRY_NEG(); + EMIT_GLUE(); + } +--- 1150,1156 ---- + if (got_coll_char == TRUE && startc == 0) + EMIT(0x0a); + else +! EMIT(startc); + TRY_NEG(); + EMIT_GLUE(); + } +*************** +*** 1242,1271 **** + int plen; + + nfa_do_multibyte: +! /* length of current char, with composing chars, +! * from pointer */ +! plen = (*mb_ptr2len)(old_regparse); +! if (enc_utf8 && clen != plen) +! { +! /* A composing character is always handled as a +! * separate atom, surrounded by NFA_COMPOSING and +! * NFA_END_COMPOSING. Note that right now we are + * building the postfix form, not the NFA itself; + * a composing char could be: a, b, c, NFA_COMPOSING +! * where 'a', 'b', 'c' are chars with codes > 256. +! */ +! EMIT_COMPOSING_UTF(old_regparse); + regparse = old_regparse + plen; + } + else +- /* A multi-byte character is always handled as a +- * separate atom, surrounded by NFA_MULTIBYTE and +- * NFA_END_MULTIBYTE */ +- if (plen > 1) +- { +- EMIT_MBYTE(c); +- } +- else + #endif + { + c = no_Magic(c); +--- 1198,1227 ---- + int plen; + + nfa_do_multibyte: +! /* Length of current char with composing chars. */ +! if (enc_utf8 && clen != (plen = (*mb_ptr2len)(old_regparse))) +! { +! /* A base character plus composing characters. +! * This requires creating a separate atom as if enclosing +! * the characters in (), where NFA_COMPOSING is the ( and +! * NFA_END_COMPOSING is the ). Note that right now we are + * building the postfix form, not the NFA itself; + * a composing char could be: a, b, c, NFA_COMPOSING +! * where 'b' and 'c' are chars with codes > 256. */ +! i = 0; +! for (;;) +! { +! EMIT(c); +! if (i > 0) +! EMIT(NFA_CONCAT); +! if (i += utf_char2len(c) >= plen) +! break; +! c = utf_ptr2char(old_regparse + i); +! } +! EMIT(NFA_COMPOSING); + regparse = old_regparse + plen; + } + else + #endif + { + c = no_Magic(c); +*************** +*** 1702,1710 **** + case NFA_START_INVISIBLE: STRCPY(code, "NFA_START_INVISIBLE"); break; + case NFA_END_INVISIBLE: STRCPY(code, "NFA_END_INVISIBLE"); break; + +- case NFA_MULTIBYTE: STRCPY(code, "NFA_MULTIBYTE"); break; +- case NFA_END_MULTIBYTE: STRCPY(code, "NFA_END_MULTIBYTE"); break; +- + case NFA_COMPOSING: STRCPY(code, "NFA_COMPOSING"); break; + case NFA_END_COMPOSING: STRCPY(code, "NFA_END_COMPOSING"); break; + +--- 1658,1663 ---- +*************** +*** 2194,2200 **** + } + e1 = POP(); + e1.start->negated = TRUE; +! if (e1.start->c == NFA_MULTIBYTE || e1.start->c == NFA_COMPOSING) + e1.start->out1->negated = TRUE; + PUSH(e1); + break; +--- 2147,2153 ---- + } + e1 = POP(); + e1.start->negated = TRUE; +! if (e1.start->c == NFA_COMPOSING) + e1.start->out1->negated = TRUE; + PUSH(e1); + break; +*************** +*** 2311,2316 **** +--- 2264,2279 ---- + PUSH(frag(s, list1(&s1->out))); + break; + ++ case NFA_COMPOSING: /* char with composing char */ ++ #if 0 ++ /* TODO */ ++ if (regflags & RF_ICOMBINE) ++ { ++ goto normalchar; ++ } ++ #endif ++ /* FALLTHROUGH */ ++ + case NFA_MOPEN + 0: /* Submatch */ + case NFA_MOPEN + 1: + case NFA_MOPEN + 2: +*************** +*** 2322,2329 **** + case NFA_MOPEN + 8: + case NFA_MOPEN + 9: + case NFA_NOPEN: /* \%( "Invisible Submatch" */ +- case NFA_MULTIBYTE: /* mbyte char */ +- case NFA_COMPOSING: /* composing char */ + if (nfa_calc_size == TRUE) + { + nstate += 2; +--- 2285,2290 ---- +*************** +*** 2336,2344 **** + case NFA_NOPEN: + mclose = NFA_NCLOSE; + break; +- case NFA_MULTIBYTE: +- mclose = NFA_END_MULTIBYTE; +- break; + case NFA_COMPOSING: + mclose = NFA_END_COMPOSING; + break; +--- 2297,2302 ---- +*************** +*** 2377,2385 **** + goto theend; + patch(e.out, s1); + +! if (mopen == NFA_MULTIBYTE || mopen == NFA_COMPOSING) +! /* MULTIBYTE->out1 = END_MULTIBYTE +! * COMPOSING->out1 = END_COMPOSING */ + patch(list1(&s->out1), s1); + + PUSH(frag(s, list1(&s1->out))); +--- 2335,2342 ---- + goto theend; + patch(e.out, s1); + +! if (mopen == NFA_COMPOSING) +! /* COMPOSING->out1 = END_COMPOSING */ + patch(list1(&s->out1), s1); + + PUSH(frag(s, list1(&s1->out))); +*************** +*** 2540,2556 **** + case NFA_COMPOSING: + /* nfa_regmatch() will match all the bytes of this composing char. */ + break; +- +- case NFA_MULTIBYTE: +- /* nfa_regmatch() will match all the bytes of this multibyte char. */ +- break; + #endif + +- case NFA_END_MULTIBYTE: +- /* Successfully matched this mbyte char */ +- addstate(l, state->out, m, off, lid, match); +- break; +- + case NFA_NOPEN: + case NFA_NCLOSE: + addstate(l, state->out, m, off, lid, match); +--- 2497,2504 ---- +*************** +*** 2841,2847 **** + regsub_T *submatch; + regsub_T *m; + { +! int c = -1; + int n; + int i = 0; + int result; +--- 2789,2795 ---- + regsub_T *submatch; + regsub_T *m; + { +! int c; + int n; + int i = 0; + int result; +*************** +*** 2859,2865 **** + List *listtbl[2][2]; + List *ll; + int listid = 1; +- int endnode; + List *thislist; + List *nextlist; + List *neglist; +--- 2807,2812 ---- +*************** +*** 3190,3222 **** + break; + } + +! case NFA_MULTIBYTE: + case NFA_COMPOSING: +! endnode = t->state->c + 1; + result = OK; + sta = t->state->out; +! len = 1; +! while (sta->c != endnode && len <= n) + { +! if (reginput[len-1] != sta->c) +! { +! result = FAIL; + break; +! } +! len++; + sta = sta->out; + } + + /* if input char length doesn't match regexp char length */ +! if (len -1 < n || sta->c != endnode) + result = FAIL; +! end = t->state->out1; /* NFA_END_MULTIBYTE or +! NFA_END_COMPOSING */ + /* If \Z was present, then ignore composing characters */ +! if (ireg_icombine && endnode == NFA_END_COMPOSING) + result = 1 ^ sta->negated; + ADD_POS_NEG_STATE(end); + break; + + case NFA_NEWL: + if (!reg_line_lbr && REG_MULTI +--- 3137,3171 ---- + break; + } + +! #ifdef FEAT_MBYTE + case NFA_COMPOSING: +! { +! int mc = c; +! + result = OK; + sta = t->state->out; +! len = 0; +! while (sta->c != NFA_END_COMPOSING && len < n) + { +! if (len > 0) +! mc = mb_ptr2char(reginput + len); +! if (mc != sta->c) + break; +! len += mb_char2len(mc); + sta = sta->out; + } + + /* if input char length doesn't match regexp char length */ +! if (len < n || sta->c != NFA_END_COMPOSING) + result = FAIL; +! end = t->state->out1; /* NFA_END_COMPOSING */ + /* If \Z was present, then ignore composing characters */ +! if (ireg_icombine) + result = 1 ^ sta->negated; + ADD_POS_NEG_STATE(end); + break; ++ } ++ #endif + + case NFA_NEWL: + if (!reg_line_lbr && REG_MULTI +*************** +*** 3425,3430 **** +--- 3374,3387 ---- + if (!result) + result = ireg_ic == TRUE + && MB_TOLOWER(t->state->c) == MB_TOLOWER(c); ++ #ifdef FEAT_MBYTE ++ /* If there is a composing character which is not being ++ * ignored there can be no match. Match with composing ++ * character uses NFA_COMPOSING above. */ ++ if (result && enc_utf8 && !ireg_icombine ++ && n != utf_char2len(c)) ++ result = FALSE; ++ #endif + ADD_POS_NEG_STATE(t->state); + break; + } +*** ../vim-7.3.1010/src/testdir/test95.in 2013-05-24 20:25:28.000000000 +0200 +--- src/testdir/test95.in 2013-05-24 20:45:08.000000000 +0200 +*************** +*** 35,40 **** +--- 35,44 ---- + :call add(tl, ['\f\+', '&*Ÿfname ', 'fname']) + :call add(tl, ['\%#=1\f\+', '&*Ÿfname ', 'fname']) + ++ :"""" Test composing character matching ++ :call add(tl, ['.ม', 'xม่x yมy', 'yม']) ++ :call add(tl, ['.ม่', 'xม่x yมy', 'xม่']) ++ + :"""" Test \Z + :call add(tl, ['ú\Z', 'x']) + +*** ../vim-7.3.1010/src/testdir/test95.ok 2013-05-24 20:25:28.000000000 +0200 +--- src/testdir/test95.ok 2013-05-24 20:44:41.000000000 +0200 +*************** +*** 9,13 **** +--- 9,15 ---- + OK - \%#=1\i\+ + OK - \f\+ + OK - \%#=1\f\+ ++ OK - .ม ++ OK - .ม่ + OK - ú\Z + OK - [^[=a=]]\+ +*** ../vim-7.3.1010/src/version.c 2013-05-24 20:25:28.000000000 +0200 +--- src/version.c 2013-05-24 21:56:02.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1011, + /**/ + +-- +If you had to identify, in one word, the reason why the +human race has not achieved, and never will achieve, its +full potential, that word would be "meetings." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d6e760e3357711d55cc6827a57e4a33308e3133d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:05:57 +0200 Subject: [PATCH 0903/3340] - patchlevel 1012 --- 7.3.1012 | 196 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 196 insertions(+) create mode 100644 7.3.1012 diff --git a/7.3.1012 b/7.3.1012 new file mode 100644 index 00000000..20c29988 --- /dev/null +++ b/7.3.1012 @@ -0,0 +1,196 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1012 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1012 +Problem: \Z does not work properly with the new regexp engine. +Solution: Make \Z work. Add tests. +Files: src/regexp_nfa.c, src/testdir/test95.in, src/testdir/test95.ok + + +*** ../vim-7.3.1011/src/regexp_nfa.c 2013-05-24 21:59:50.000000000 +0200 +--- src/regexp_nfa.c 2013-05-24 22:46:00.000000000 +0200 +*************** +*** 1184,1197 **** + EMIT(NFA_CONCAT); + } + return OK; +! } /* if exists closing ] */ +! else if (reg_strict) + { + syntax_error = TRUE; + EMSG_RET_FAIL(_(e_missingbracket)); + } + +- /* FALLTHROUGH */ + default: + { + #ifdef FEAT_MBYTE +--- 1184,1198 ---- + EMIT(NFA_CONCAT); + } + return OK; +! } /* if exists closing ] */ +! +! if (reg_strict) + { + syntax_error = TRUE; + EMSG_RET_FAIL(_(e_missingbracket)); + } ++ /* FALLTHROUGH */ + + default: + { + #ifdef FEAT_MBYTE +*************** +*** 1214,1220 **** + EMIT(c); + if (i > 0) + EMIT(NFA_CONCAT); +! if (i += utf_char2len(c) >= plen) + break; + c = utf_ptr2char(old_regparse + i); + } +--- 1215,1221 ---- + EMIT(c); + if (i > 0) + EMIT(NFA_CONCAT); +! if ((i += utf_char2len(c)) >= plen) + break; + c = utf_ptr2char(old_regparse + i); + } +*************** +*** 2269,2275 **** + /* TODO */ + if (regflags & RF_ICOMBINE) + { +! goto normalchar; + } + #endif + /* FALLTHROUGH */ +--- 2270,2276 ---- + /* TODO */ + if (regflags & RF_ICOMBINE) + { +! /* use the base character only */ + } + #endif + /* FALLTHROUGH */ +*************** +*** 3145,3167 **** + result = OK; + sta = t->state->out; + len = 0; +! while (sta->c != NFA_END_COMPOSING && len < n) + { +! if (len > 0) +! mc = mb_ptr2char(reginput + len); +! if (mc != sta->c) +! break; +! len += mb_char2len(mc); +! sta = sta->out; + } + + /* if input char length doesn't match regexp char length */ + if (len < n || sta->c != NFA_END_COMPOSING) + result = FAIL; + end = t->state->out1; /* NFA_END_COMPOSING */ +- /* If \Z was present, then ignore composing characters */ +- if (ireg_icombine) +- result = 1 ^ sta->negated; + ADD_POS_NEG_STATE(end); + break; + } +--- 3146,3176 ---- + result = OK; + sta = t->state->out; + len = 0; +! if (ireg_icombine) + { +! /* If \Z was present, then ignore composing characters. */ +! /* TODO: How about negated? */ +! if (sta->c != c) +! result = FAIL; +! len = n; +! while (sta->c != NFA_END_COMPOSING) +! sta = sta->out; + } ++ else ++ while (sta->c != NFA_END_COMPOSING && len < n) ++ { ++ if (len > 0) ++ mc = mb_ptr2char(reginput + len); ++ if (mc != sta->c) ++ break; ++ len += mb_char2len(mc); ++ sta = sta->out; ++ } + + /* if input char length doesn't match regexp char length */ + if (len < n || sta->c != NFA_END_COMPOSING) + result = FAIL; + end = t->state->out1; /* NFA_END_COMPOSING */ + ADD_POS_NEG_STATE(end); + break; + } +*** ../vim-7.3.1011/src/testdir/test95.in 2013-05-24 21:59:50.000000000 +0200 +--- src/testdir/test95.in 2013-05-24 23:02:13.000000000 +0200 +*************** +*** 41,46 **** +--- 41,55 ---- + + :"""" Test \Z + :call add(tl, ['ú\Z', 'x']) ++ :call add(tl, ['יהוה\Z', 'יהוה', 'יהוה']) ++ :call add(tl, ['יְהוָה\Z', 'יהוה', 'יהוה']) ++ :call add(tl, ['יהוה\Z', 'יְהוָה', 'יְהוָה']) ++ :call add(tl, ['יְהוָה\Z', 'יְהוָה', 'יְהוָה']) ++ :call add(tl, ['×™Ö°\Z', 'וְיַ', '×™Ö·']) ++ :call add(tl, ["×§\u200d\u05b9x\\Z", "x×§\u200d\u05b9xy", "×§\u200d\u05b9x"]) ++ :call add(tl, ["×§\u200d\u05b9x\\Z", "x×§\u200dxy", "×§\u200dx"]) ++ :call add(tl, ["×§\u200dx\\Z", "x×§\u200d\u05b9xy", "×§\u200d\u05b9x"]) ++ :call add(tl, ["×§\u200dx\\Z", "x×§\u200dxy", "×§\u200dx"]) + + :"""" Combining different tests and features + :call add(tl, ['[^[=a=]]\+', 'ddaãâbcd', 'dd']) +*** ../vim-7.3.1011/src/testdir/test95.ok 2013-05-24 21:59:50.000000000 +0200 +--- src/testdir/test95.ok 2013-05-24 23:02:59.000000000 +0200 +*************** +*** 12,15 **** +--- 12,24 ---- + OK - .ม + OK - .ม่ + OK - ú\Z ++ OK - יהוה\Z ++ OK - יְהוָה\Z ++ OK - יהוה\Z ++ OK - יְהוָה\Z ++ OK - ×™Ö°\Z ++ OK - ×§â€Ö¹x\Z ++ OK - ×§â€Ö¹x\Z ++ OK - ×§â€x\Z ++ OK - ×§â€x\Z + OK - [^[=a=]]\+ +*** ../vim-7.3.1011/src/version.c 2013-05-24 21:59:50.000000000 +0200 +--- src/version.c 2013-05-24 23:08:21.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1012, + /**/ + +-- +BEDEVERE: And that, my lord, is how we know the Earth to be banana-shaped. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1469c474a1188229a2a1c1e804201aabaeb7a422 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:05:58 +0200 Subject: [PATCH 0904/3340] - patchlevel 1013 --- 7.3.1013 | 347 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 347 insertions(+) create mode 100644 7.3.1013 diff --git a/7.3.1013 b/7.3.1013 new file mode 100644 index 00000000..125bd346 --- /dev/null +++ b/7.3.1013 @@ -0,0 +1,347 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1013 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1013 +Problem: New regexp logging is a bit messy. +Solution: Consistently use #defines, add explanatory comment. (Taro Muraoka) +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1012/src/regexp_nfa.c 2013-05-24 23:10:45.000000000 +0200 +--- src/regexp_nfa.c 2013-05-25 12:17:35.000000000 +0200 +*************** +*** 5,16 **** + * This file is included in "regexp.c". + */ + + #ifdef DEBUG +! /* Comment this out to disable log files. They can get pretty big */ + # define ENABLE_LOG +! # define LOG_NAME "log_nfarun.log" +! # define NFA_REGEXP_DEBUG_LOG +! # define NFA_REGEXP_DEBUG_LOG_NAME "nfa_regexp_debug.log" + #endif + + /* Upper limit allowed for {m,n} repetitions handled by NFA */ +--- 5,32 ---- + * This file is included in "regexp.c". + */ + ++ /* ++ * Logging of NFA engine. ++ * ++ * The NFA engine can write four log files: ++ * - Error log: Contains NFA engine's fatal errors. ++ * - Dump log: Contains compiled NFA state machine's information. ++ * - Run log: Contains information of matching procedure. ++ * - Debug log: Contains detailed information of matching procedure. Can be ++ * disabled by undefining NFA_REGEXP_DEBUG_LOG. ++ * The first one can also be used without debug mode. ++ * The last three are enabled when compiled as debug mode and individually ++ * disabled by commenting them out. ++ * The log files can get quite big! ++ * Do disable all of this when compiling Vim for debugging, undefine DEBUG in ++ * regexp.c ++ */ + #ifdef DEBUG +! # define NFA_REGEXP_ERROR_LOG "nfa_regexp_error.log" + # define ENABLE_LOG +! # define NFA_REGEXP_DUMP_LOG "nfa_regexp_dump.log" +! # define NFA_REGEXP_RUN_LOG "nfa_regexp_run.log" +! # define NFA_REGEXP_DEBUG_LOG "nfa_regexp_debug.log" + #endif + + /* Upper limit allowed for {m,n} repetitions handled by NFA */ +*************** +*** 1769,1775 **** + int *p; + FILE *f; + +! f = fopen("LOG.log", "a"); + if (f != NULL) + { + fprintf(f, "\n-------------------------\n"); +--- 1785,1791 ---- + int *p; + FILE *f; + +! f = fopen(NFA_REGEXP_DUMP_LOG, "a"); + if (f != NULL) + { + fprintf(f, "\n-------------------------\n"); +*************** +*** 1827,1833 **** + nfa_dump(prog) + nfa_regprog_T *prog; + { +! FILE *debugf = fopen("LOG.log", "a"); + + if (debugf != NULL) + { +--- 1843,1849 ---- + nfa_dump(prog) + nfa_regprog_T *prog; + { +! FILE *debugf = fopen(NFA_REGEXP_DUMP_LOG, "a"); + + if (debugf != NULL) + { +*************** +*** 1994,2007 **** + + static void + st_error(postfix, end, p) +! int *postfix; +! int *end; +! int *p; + { + FILE *df; + int *p2; + +! df = fopen("stack.err", "a"); + if (df) + { + fprintf(df, "Error popping the stack!\n"); +--- 2010,2024 ---- + + static void + st_error(postfix, end, p) +! int *postfix UNUSED; +! int *end UNUSED; +! int *p UNUSED; + { ++ #ifdef NFA_REGEXP_ERROR_LOG + FILE *df; + int *p2; + +! df = fopen(NFA_REGEXP_ERROR_LOG, "a"); + if (df) + { + fprintf(df, "Error popping the stack!\n"); +*************** +*** 2036,2041 **** +--- 2053,2059 ---- + fprintf(df, "\n--------------------------\n"); + fclose(df); + } ++ #endif + EMSG(_("E874: (NFA) Could not pop the stack !")); + } + +*************** +*** 2148,2155 **** +--- 2166,2175 ---- + } + e1 = POP(); + e1.start->negated = TRUE; ++ #ifdef FEAT_MBYTE + if (e1.start->c == NFA_COMPOSING) + e1.start->out1->negated = TRUE; ++ #endif + PUSH(e1); + break; + +*************** +*** 2265,2270 **** +--- 2285,2291 ---- + PUSH(frag(s, list1(&s1->out))); + break; + ++ #ifdef FEAT_MBYTE + case NFA_COMPOSING: /* char with composing char */ + #if 0 + /* TODO */ +*************** +*** 2274,2279 **** +--- 2295,2301 ---- + } + #endif + /* FALLTHROUGH */ ++ #endif + + case NFA_MOPEN + 0: /* Submatch */ + case NFA_MOPEN + 1: +*************** +*** 2298,2306 **** +--- 2320,2330 ---- + case NFA_NOPEN: + mclose = NFA_NCLOSE; + break; ++ #ifdef FEAT_MBYTE + case NFA_COMPOSING: + mclose = NFA_END_COMPOSING; + break; ++ #endif + default: + /* NFA_MOPEN(0) ... NFA_MOPEN(9) */ + mclose = *p + NSUBEXP; +*************** +*** 2336,2344 **** +--- 2360,2370 ---- + goto theend; + patch(e.out, s1); + ++ #ifdef FEAT_MBYTE + if (mopen == NFA_COMPOSING) + /* COMPOSING->out1 = END_COMPOSING */ + patch(list1(&s->out1), s1); ++ #endif + + PUSH(frag(s, list1(&s1->out))); + break; +*************** +*** 2802,2809 **** + thread_T *t; + char_u *old_reginput = NULL; + char_u *old_regline = NULL; +- nfa_state_T *sta; +- nfa_state_T *end; + List list[3]; + List *listtbl[2][2]; + List *ll; +--- 2828,2833 ---- +*************** +*** 2813,2825 **** + List *neglist; + int *listids = NULL; + int j = 0; +- int len = 0; + #ifdef NFA_REGEXP_DEBUG_LOG +! FILE *debug = fopen(NFA_REGEXP_DEBUG_LOG_NAME, "a"); + + if (debug == NULL) + { +! EMSG2(_("(NFA) COULD NOT OPEN %s !"), NFA_REGEXP_DEBUG_LOG_NAME); + return FALSE; + } + #endif +--- 2837,2848 ---- + List *neglist; + int *listids = NULL; + int j = 0; + #ifdef NFA_REGEXP_DEBUG_LOG +! FILE *debug = fopen(NFA_REGEXP_DEBUG_LOG, "a"); + + if (debug == NULL) + { +! EMSG2(_("(NFA) COULD NOT OPEN %s !"), NFA_REGEXP_DEBUG_LOG); + return FALSE; + } + #endif +*************** +*** 2836,2842 **** + vim_memset(list[2].t, 0, size); + + #ifdef ENABLE_LOG +! log_fd = fopen(LOG_NAME, "a"); + if (log_fd != NULL) + { + fprintf(log_fd, "**********************************\n"); +--- 2859,2865 ---- + vim_memset(list[2].t, 0, size); + + #ifdef ENABLE_LOG +! log_fd = fopen(NFA_REGEXP_RUN_LOG, "a"); + if (log_fd != NULL) + { + fprintf(log_fd, "**********************************\n"); +*************** +*** 3025,3031 **** + nfa_restore_listids(start, listids); + + #ifdef ENABLE_LOG +! log_fd = fopen(LOG_NAME, "a"); + if (log_fd != NULL) + { + fprintf(log_fd, "****************************\n"); +--- 3048,3054 ---- + nfa_restore_listids(start, listids); + + #ifdef ENABLE_LOG +! log_fd = fopen(NFA_REGEXP_RUN_LOG, "a"); + if (log_fd != NULL) + { + fprintf(log_fd, "****************************\n"); +*************** +*** 3141,3147 **** + #ifdef FEAT_MBYTE + case NFA_COMPOSING: + { +! int mc = c; + + result = OK; + sta = t->state->out; +--- 3164,3173 ---- + #ifdef FEAT_MBYTE + case NFA_COMPOSING: + { +! int mc = c; +! int len = 0; +! nfa_state_T *end; +! nfa_state_T *sta; + + result = OK; + sta = t->state->out; +*************** +*** 3469,3475 **** + need_clear_subexpr = TRUE; + + #ifdef ENABLE_LOG +! f = fopen(LOG_NAME, "a"); + if (f != NULL) + { + fprintf(f, "\n\n\n\n\n\n\t\t=======================================================\n"); +--- 3495,3501 ---- + need_clear_subexpr = TRUE; + + #ifdef ENABLE_LOG +! f = fopen(NFA_REGEXP_RUN_LOG, "a"); + if (f != NULL) + { + fprintf(f, "\n\n\n\n\n\n\t\t=======================================================\n"); +*************** +*** 3662,3668 **** + */ + #ifdef ENABLE_LOG + { +! FILE *f = fopen(LOG_NAME, "a"); + + if (f != NULL) + { +--- 3688,3694 ---- + */ + #ifdef ENABLE_LOG + { +! FILE *f = fopen(NFA_REGEXP_RUN_LOG, "a"); + + if (f != NULL) + { +*** ../vim-7.3.1012/src/version.c 2013-05-24 23:10:45.000000000 +0200 +--- src/version.c 2013-05-25 12:06:33.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1013, + /**/ + +-- +Scientists decoded the first message from an alien civilization: + SIMPLY SEND 6 TIMES 10 TO THE 50 ATOMS OF HYDROGEN TO THE STAR +SYSTEM AT THE TOP OF THE LIST, CROSS OFF THAT STAR SYSTEM, THEN PUT +YOUR STAR SYSTEM AT THE BOTTOM OF THE LIST AND SEND IT TO 100 OTHER +STAR SYSTEMS. WITHIN ONE TENTH GALACTIC ROTATION YOU WILL RECEIVE +ENOUGH HYDROGREN TO POWER YOUR CIVILIZATION UNTIL ENTROPY REACHES ITS +MAXIMUM! IT REALLY WORKS! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0723cf5d4a52dc4853a25ebaf61a79ce622a45bc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:05:58 +0200 Subject: [PATCH 0905/3340] - patchlevel 1014 --- 7.3.1014 | 192 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 192 insertions(+) create mode 100644 7.3.1014 diff --git a/7.3.1014 b/7.3.1014 new file mode 100644 index 00000000..5cc84bef --- /dev/null +++ b/7.3.1014 @@ -0,0 +1,192 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1014 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1014 +Problem: New regexp state dump is hard to read. +Solution: Make the state dump more pretty. (Taro Muraoka) +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1013/src/regexp_nfa.c 2013-05-25 12:18:34.000000000 +0200 +--- src/regexp_nfa.c 2013-05-25 12:25:43.000000000 +0200 +*************** +*** 183,189 **** + #ifdef DEBUG + static void nfa_set_code __ARGS((int c)); + static void nfa_postfix_dump __ARGS((char_u *expr, int retval)); +! static void nfa_print_state __ARGS((FILE *debugf, nfa_state_T *state, int ident)); + static void nfa_dump __ARGS((nfa_regprog_T *prog)); + #endif + static int *re2post __ARGS((void)); +--- 183,190 ---- + #ifdef DEBUG + static void nfa_set_code __ARGS((int c)); + static void nfa_postfix_dump __ARGS((char_u *expr, int retval)); +! static void nfa_print_state __ARGS((FILE *debugf, nfa_state_T *state)); +! static void nfa_print_state2 __ARGS((FILE *debugf, nfa_state_T *state, garray_T *indent)); + static void nfa_dump __ARGS((nfa_regprog_T *prog)); + #endif + static int *re2post __ARGS((void)); +*************** +*** 1811,1839 **** + * Print the NFA starting with a root node "state". + */ + static void +! nfa_print_state(debugf, state, ident) + FILE *debugf; + nfa_state_T *state; +- int ident; + { +! int i; + + if (state == NULL) + return; + + fprintf(debugf, "(%2d)", abs(state->id)); +! for (i = 0; i < ident; i++) +! fprintf(debugf, "%c", ' '); + + nfa_set_code(state->c); +! fprintf(debugf, "%s %s (%d) (id=%d)\n", +! state->negated ? "NOT" : "", code, state->c, abs(state->id)); + if (state->id < 0) + return; + + state->id = abs(state->id) * -1; +! nfa_print_state(debugf, state->out, ident + 4); +! nfa_print_state(debugf, state->out1, ident + 4); + } + + /* +--- 1812,1885 ---- + * Print the NFA starting with a root node "state". + */ + static void +! nfa_print_state(debugf, state) + FILE *debugf; + nfa_state_T *state; + { +! garray_T indent; +! +! ga_init2(&indent, 1, 64); +! ga_append(&indent, '\0'); +! nfa_print_state2(debugf, state, &indent); +! ga_clear(&indent); +! } +! +! static void +! nfa_print_state2(debugf, state, indent) +! FILE *debugf; +! nfa_state_T *state; +! garray_T *indent; +! { +! char_u *p; + + if (state == NULL) + return; + + fprintf(debugf, "(%2d)", abs(state->id)); +! +! /* Output indent */ +! p = (char_u *)indent->ga_data; +! if (indent->ga_len >= 3) +! { +! int last = indent->ga_len - 3; +! char_u save[2]; +! +! STRNCPY(save, &p[last], 2); +! STRNCPY(&p[last], "+-", 2); +! fprintf(debugf, " %s", p); +! STRNCPY(&p[last], save, 2); +! } +! else +! fprintf(debugf, " %s", p); + + nfa_set_code(state->c); +! fprintf(debugf, "%s%s (%d) (id=%d)\n", +! state->negated ? "NOT " : "", code, state->c, abs(state->id)); + if (state->id < 0) + return; + + state->id = abs(state->id) * -1; +! +! /* grow indent for state->out */ +! indent->ga_len -= 1; +! if (state->out1) +! ga_concat(indent, "| "); +! else +! ga_concat(indent, " "); +! ga_append(indent, '\0'); +! +! nfa_print_state2(debugf, state->out, indent); +! +! /* replace last part of indent for state->out1 */ +! indent->ga_len -= 3; +! ga_concat(indent, " "); +! ga_append(indent, '\0'); +! +! nfa_print_state2(debugf, state->out1, indent); +! +! /* shrink indent */ +! indent->ga_len -= 3; +! ga_append(indent, '\0'); + } + + /* +*************** +*** 1847,1853 **** + + if (debugf != NULL) + { +! nfa_print_state(debugf, prog->start, 0); + fclose(debugf); + } + } +--- 1893,1899 ---- + + if (debugf != NULL) + { +! nfa_print_state(debugf, prog->start); + fclose(debugf); + } + } +*************** +*** 3505,3511 **** + #endif + fprintf(f, "\tInput text is \"%s\" \n", reginput); + fprintf(f, " =======================================================\n\n\n\n\n\n\n"); +! nfa_print_state(f, start, 0); + fprintf(f, "\n\n"); + fclose(f); + } +--- 3551,3557 ---- + #endif + fprintf(f, "\tInput text is \"%s\" \n", reginput); + fprintf(f, " =======================================================\n\n\n\n\n\n\n"); +! nfa_print_state(f, start); + fprintf(f, "\n\n"); + fclose(f); + } +*** ../vim-7.3.1013/src/version.c 2013-05-25 12:18:34.000000000 +0200 +--- src/version.c 2013-05-25 12:27:22.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1014, + /**/ + +-- +Lower life forms have more fun! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 31a074ea9d7af1f0727386cc4503e941e4b17be1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:05:59 +0200 Subject: [PATCH 0906/3340] - patchlevel 1015 --- 7.3.1015 | 172 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 172 insertions(+) create mode 100644 7.3.1015 diff --git a/7.3.1015 b/7.3.1015 new file mode 100644 index 00000000..91b0d073 --- /dev/null +++ b/7.3.1015 @@ -0,0 +1,172 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1015 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1015 +Problem: New regexp engine: Matching composing characters is wrong. +Solution: Fix matching composing characters. +Files: src/regexp_nfa.c, src/testdir/test95.in, src/testdir/test95.ok + + +*** ../vim-7.3.1014/src/regexp_nfa.c 2013-05-25 12:28:08.000000000 +0200 +--- src/regexp_nfa.c 2013-05-25 14:25:42.000000000 +0200 +*************** +*** 716,721 **** +--- 716,722 ---- + * the composing char is matched here. */ + if (enc_utf8 && c == Magic('.') && utf_iscomposing(peekchr())) + { ++ old_regparse = regparse; + c = getchr(); + goto nfa_do_multibyte; + } +*************** +*** 1217,1225 **** + + nfa_do_multibyte: + /* Length of current char with composing chars. */ +! if (enc_utf8 && clen != (plen = (*mb_ptr2len)(old_regparse))) + { +! /* A base character plus composing characters. + * This requires creating a separate atom as if enclosing + * the characters in (), where NFA_COMPOSING is the ( and + * NFA_END_COMPOSING is the ). Note that right now we are +--- 1218,1228 ---- + + nfa_do_multibyte: + /* Length of current char with composing chars. */ +! if (enc_utf8 && (clen != (plen = (*mb_ptr2len)(old_regparse)) +! || utf_iscomposing(c))) + { +! /* A base character plus composing characters, or just one +! * or more composing characters. + * This requires creating a separate atom as if enclosing + * the characters in (), where NFA_COMPOSING is the ( and + * NFA_END_COMPOSING is the ). Note that right now we are +*************** +*** 1400,1406 **** + /* Save pos after the repeated atom and the \{} */ + new_regparse = regparse; + +- new_regparse = regparse; + quest = (greedy == TRUE? NFA_QUEST : NFA_QUEST_NONGREEDY); + for (i = 0; i < maxval; i++) + { +--- 1403,1408 ---- +*************** +*** 3218,3228 **** + result = OK; + sta = t->state->out; + len = 0; + if (ireg_icombine) + { +! /* If \Z was present, then ignore composing characters. */ + /* TODO: How about negated? */ +! if (sta->c != c) + result = FAIL; + len = n; + while (sta->c != NFA_END_COMPOSING) +--- 3220,3238 ---- + result = OK; + sta = t->state->out; + len = 0; ++ if (utf_iscomposing(sta->c)) ++ { ++ /* Only match composing character(s), ignore base ++ * character. Used for ".{composing}" and "{composing}" ++ * (no preceding character). */ ++ len += mb_char2len(c); ++ } + if (ireg_icombine) + { +! /* If \Z was present, then ignore composing characters. +! * When ignoring the base character this always matches. */ + /* TODO: How about negated? */ +! if (len == 0 && sta->c != c) + result = FAIL; + len = n; + while (sta->c != NFA_END_COMPOSING) +*** ../vim-7.3.1014/src/testdir/test95.in 2013-05-24 23:10:45.000000000 +0200 +--- src/testdir/test95.in 2013-05-25 14:36:50.000000000 +0200 +*************** +*** 38,43 **** +--- 38,52 ---- + :"""" Test composing character matching + :call add(tl, ['.ม', 'xม่x yมy', 'yม']) + :call add(tl, ['.ม่', 'xม่x yมy', 'xม่']) ++ :call add(tl, ["\u05b9", " x\u05b9 ", "x\u05b9"]) ++ :call add(tl, [".\u05b9", " x\u05b9 ", "x\u05b9"]) ++ :call add(tl, ["\u05b9\u05bb", " x\u05b9\u05bb ", "x\u05b9\u05bb"]) ++ :call add(tl, [".\u05b9\u05bb", " x\u05b9\u05bb ", "x\u05b9\u05bb"]) ++ :call add(tl, ["\u05bb\u05b9", " x\u05b9\u05bb "]) ++ :call add(tl, [".\u05bb\u05b9", " x\u05b9\u05bb "]) ++ :call add(tl, ["\u05b9", " y\u05bb x\u05b9 ", "x\u05b9"]) ++ :call add(tl, [".\u05b9", " y\u05bb x\u05b9 ", "x\u05b9"]) ++ + + :"""" Test \Z + :call add(tl, ['ú\Z', 'x']) +*************** +*** 50,55 **** +--- 59,66 ---- + :call add(tl, ["×§\u200d\u05b9x\\Z", "x×§\u200dxy", "×§\u200dx"]) + :call add(tl, ["×§\u200dx\\Z", "x×§\u200d\u05b9xy", "×§\u200d\u05b9x"]) + :call add(tl, ["×§\u200dx\\Z", "x×§\u200dxy", "×§\u200dx"]) ++ :call add(tl, ["\u05b9\\+\\Z", "xyz", "xyz"]) ++ :call add(tl, ["\\Z\u05b9\\+", "xyz", "xyz"]) + + :"""" Combining different tests and features + :call add(tl, ['[^[=a=]]\+', 'ddaãâbcd', 'dd']) +*** ../vim-7.3.1014/src/testdir/test95.ok 2013-05-24 23:10:45.000000000 +0200 +--- src/testdir/test95.ok 2013-05-25 14:36:54.000000000 +0200 +*************** +*** 11,16 **** +--- 11,24 ---- + OK - \%#=1\f\+ + OK - .ม + OK - .ม่ ++ OK - Ö¹ ++ OK - .Ö¹ ++ OK - Ö¹Ö» ++ OK - .Ö¹Ö» ++ OK - Ö»Ö¹ ++ OK - .Ö»Ö¹ ++ OK - Ö¹ ++ OK - .Ö¹ + OK - ú\Z + OK - יהוה\Z + OK - יְהוָה\Z +*************** +*** 21,24 **** +--- 29,34 ---- + OK - ×§â€Ö¹x\Z + OK - ×§â€x\Z + OK - ×§â€x\Z ++ OK - Ö¹\+\Z ++ OK - \ZÖ¹\+ + OK - [^[=a=]]\+ +*** ../vim-7.3.1014/src/version.c 2013-05-25 12:28:08.000000000 +0200 +--- src/version.c 2013-05-25 14:41:05.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1015, + /**/ + +-- +If your company is not involved in something called "ISO 9000" you probably +have no idea what it is. If your company _is_ involved in ISO 9000 then you +definitely have no idea what it is. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d0fa66dde8d6cc8540ed0be355158f89ee7e48af Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:05:59 +0200 Subject: [PATCH 0907/3340] - patchlevel 1016 --- 7.3.1016 | 153 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 153 insertions(+) create mode 100644 7.3.1016 diff --git a/7.3.1016 b/7.3.1016 new file mode 100644 index 00000000..5c2e52ae --- /dev/null +++ b/7.3.1016 @@ -0,0 +1,153 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1016 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1016 +Problem: Unused field in nfa_state. +Solution: Remove lastthread. +Files: src/regexp.h, src/regexp_nfa.c + + +*** ../vim-7.3.1015/src/regexp.h 2013-05-19 19:16:25.000000000 +0200 +--- src/regexp.h 2013-05-25 15:23:33.000000000 +0200 +*************** +*** 74,80 **** + int id; + int lastlist; + int visits; +- thread_T *lastthread; + int negated; + }; + +--- 74,79 ---- +*** ../vim-7.3.1015/src/regexp_nfa.c 2013-05-25 14:41:58.000000000 +0200 +--- src/regexp_nfa.c 2013-05-25 15:23:28.000000000 +0200 +*************** +*** 1865,1880 **** + /* grow indent for state->out */ + indent->ga_len -= 1; + if (state->out1) +! ga_concat(indent, "| "); + else +! ga_concat(indent, " "); + ga_append(indent, '\0'); + + nfa_print_state2(debugf, state->out, indent); + + /* replace last part of indent for state->out1 */ + indent->ga_len -= 3; +! ga_concat(indent, " "); + ga_append(indent, '\0'); + + nfa_print_state2(debugf, state->out1, indent); +--- 1865,1880 ---- + /* grow indent for state->out */ + indent->ga_len -= 1; + if (state->out1) +! ga_concat(indent, (char_u *)"| "); + else +! ga_concat(indent, (char_u *)" "); + ga_append(indent, '\0'); + + nfa_print_state2(debugf, state->out, indent); + + /* replace last part of indent for state->out1 */ + indent->ga_len -= 3; +! ga_concat(indent, (char_u *)" "); + ga_append(indent, '\0'); + + nfa_print_state2(debugf, state->out1, indent); +*************** +*** 1948,1954 **** + + s->id = istate; + s->lastlist = 0; +- s->lastthread = NULL; + s->visits = 0; + s->negated = FALSE; + +--- 1948,1953 ---- +*************** +*** 2498,2503 **** +--- 2497,2503 ---- + { + regsub_T save; + int subidx = 0; ++ thread_T *lastthread; + + if (l == NULL || state == NULL) + return; +*************** +*** 2531,2539 **** + { + /* add the state to the list */ + state->lastlist = lid; +! state->lastthread = &l->t[l->n++]; +! state->lastthread->state = state; +! state->lastthread->sub = *m; + } + } + +--- 2531,2539 ---- + { + /* add the state to the list */ + state->lastlist = lid; +! lastthread = &l->t[l->n++]; +! lastthread->state = state; +! lastthread->sub = *m; + } + } + +*************** +*** 2983,2989 **** + fprintf(log_fd, ">>> Reginput is \"%s\"\n", reginput); + fprintf(log_fd, ">>> Advanced one character ... Current char is %c (code %d) \n", c, (int)c); + fprintf(log_fd, ">>> Thislist has %d states available: ", thislist->n); +! for (i = 0; i< thislist->n; i++) + fprintf(log_fd, "%d ", abs(thislist->t[i].state->id)); + fprintf(log_fd, "\n"); + #endif +--- 2983,2989 ---- + fprintf(log_fd, ">>> Reginput is \"%s\"\n", reginput); + fprintf(log_fd, ">>> Advanced one character ... Current char is %c (code %d) \n", c, (int)c); + fprintf(log_fd, ">>> Thislist has %d states available: ", thislist->n); +! for (i = 0; i < thislist->n; i++) + fprintf(log_fd, "%d ", abs(thislist->t[i].state->id)); + fprintf(log_fd, "\n"); + #endif +*************** +*** 3690,3696 **** + prog->state[i].id = i; + prog->state[i].lastlist = 0; + prog->state[i].visits = 0; +- prog->state[i].lastthread = NULL; + } + + retval = nfa_regtry(prog->start, col); +--- 3690,3695 ---- +*** ../vim-7.3.1015/src/version.c 2013-05-25 14:41:58.000000000 +0200 +--- src/version.c 2013-05-25 15:28:53.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1016, + /**/ + +-- +For large projects, Team Leaders use sophisticated project management software +to keep track of who's doing what. The software collects the lies and guesses +of the project team and organizes them in to instantly outdated charts that +are too boring to look at closely. This is called "planning". + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ec2eb364919a4482473e4e8d41d6f58636fb8f5c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:00 +0200 Subject: [PATCH 0908/3340] - patchlevel 1017 --- 7.3.1017 | 416 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 416 insertions(+) create mode 100644 7.3.1017 diff --git a/7.3.1017 b/7.3.1017 new file mode 100644 index 00000000..6e043e3d --- /dev/null +++ b/7.3.1017 @@ -0,0 +1,416 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1017 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1017 +Problem: Zero width match changes length of match. +Solution: For a zero width match put new states in the current position in + the state list. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok, + src/regexp.h + + +*** ../vim-7.3.1016/src/regexp_nfa.c 2013-05-25 15:31:02.000000000 +0200 +--- src/regexp_nfa.c 2013-05-25 20:18:25.000000000 +0200 +*************** +*** 2471,2494 **** + * NFA execution code. + ****************************************************************/ + +! /* thread_T contains runtime information of a NFA state */ +! struct thread + { + nfa_state_T *state; +! regsub_T sub; /* submatch info */ +! }; + + typedef struct + { +! thread_T *t; +! int n; +! } List; + +! static void addstate __ARGS((List *l, nfa_state_T *state, regsub_T *m, int off, int lid, int *match)); + + static void + addstate(l, state, m, off, lid, match) +! List *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ + regsub_T *m; /* pointers to subexpressions */ + int off; /* byte offset, when -1 go to next line */ +--- 2471,2497 ---- + * NFA execution code. + ****************************************************************/ + +! /* nfa_thread_T contains runtime information of a NFA state */ +! typedef struct + { + nfa_state_T *state; +! regsub_T sub; /* Submatch info. TODO: expensive! */ +! } nfa_thread_T; +! + + typedef struct + { +! nfa_thread_T *t; +! int n; +! } nfa_list_T; + +! static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *m, int off, int lid, int *match)); +! +! static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *m, int lid, int *match, int *ip)); + + static void + addstate(l, state, m, off, lid, match) +! nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ + regsub_T *m; /* pointers to subexpressions */ + int off; /* byte offset, when -1 go to next line */ +*************** +*** 2497,2503 **** + { + regsub_T save; + int subidx = 0; +! thread_T *lastthread; + + if (l == NULL || state == NULL) + return; +--- 2500,2506 ---- + { + regsub_T save; + int subidx = 0; +! nfa_thread_T *lastthread; + + if (l == NULL || state == NULL) + return; +*************** +*** 2533,2539 **** + state->lastlist = lid; + lastthread = &l->t[l->n++]; + lastthread->state = state; +! lastthread->sub = *m; + } + } + +--- 2536,2542 ---- + state->lastlist = lid; + lastthread = &l->t[l->n++]; + lastthread->state = state; +! lastthread->sub = *m; /* TODO: expensive! */ + } + } + +*************** +*** 2698,2703 **** +--- 2701,2754 ---- + } + + /* ++ * Like addstate(), but the new state(s) are put at position "*ip". ++ * Used for zero-width matches, next state to use is the added one. ++ * This makes sure the order of states to be tried does not change, which ++ * matters for alternatives. ++ */ ++ static void ++ addstate_here(l, state, m, lid, matchp, ip) ++ nfa_list_T *l; /* runtime state list */ ++ nfa_state_T *state; /* state to update */ ++ regsub_T *m; /* pointers to subexpressions */ ++ int lid; ++ int *matchp; /* found match? */ ++ int *ip; ++ { ++ int tlen = l->n; ++ int count; ++ int i = *ip; ++ ++ /* first add the state(s) at the end, so that we know how many there are */ ++ addstate(l, state, m, 0, lid, matchp); ++ ++ /* when "*ip" was at the end of the list, nothing to do */ ++ if (i + 1 == tlen) ++ return; ++ ++ /* re-order to put the new state at the current position */ ++ count = l->n - tlen; ++ if (count > 1) ++ { ++ /* make space for new states, then move them from the ++ * end to the current position */ ++ mch_memmove(&(l->t[i + count]), ++ &(l->t[i + 1]), ++ sizeof(nfa_thread_T) * (l->n - i - 1)); ++ mch_memmove(&(l->t[i]), ++ &(l->t[l->n - 1]), ++ sizeof(nfa_thread_T) * count); ++ } ++ else ++ { ++ /* overwrite the current state */ ++ l->t[i] = l->t[l->n - 1]; ++ } ++ --l->n; ++ *ip = i - 1; ++ } ++ ++ /* + * Check character class "class" against current character c. + */ + static int +*************** +*** 2872,2888 **** + int match = FALSE; + int flag = 0; + int old_reglnum = -1; +! int go_to_nextline; +! thread_T *t; + char_u *old_reginput = NULL; + char_u *old_regline = NULL; +! List list[3]; +! List *listtbl[2][2]; +! List *ll; + int listid = 1; +! List *thislist; +! List *nextlist; +! List *neglist; + int *listids = NULL; + int j = 0; + #ifdef NFA_REGEXP_DEBUG_LOG +--- 2923,2939 ---- + int match = FALSE; + int flag = 0; + int old_reglnum = -1; +! int go_to_nextline = FALSE; +! nfa_thread_T *t; + char_u *old_reginput = NULL; + char_u *old_regline = NULL; +! nfa_list_T list[3]; +! nfa_list_T *listtbl[2][2]; +! nfa_list_T *ll; + int listid = 1; +! nfa_list_T *thislist; +! nfa_list_T *nextlist; +! nfa_list_T *neglist; + int *listids = NULL; + int j = 0; + #ifdef NFA_REGEXP_DEBUG_LOG +*************** +*** 2896,2905 **** + #endif + + /* Allocate memory for the lists of nodes */ +! size = (nstate + 1) * sizeof(thread_T); +! list[0].t = (thread_T *)lalloc(size, TRUE); +! list[1].t = (thread_T *)lalloc(size, TRUE); +! list[2].t = (thread_T *)lalloc(size, TRUE); + if (list[0].t == NULL || list[1].t == NULL || list[2].t == NULL) + goto theend; + vim_memset(list[0].t, 0, size); +--- 2947,2956 ---- + #endif + + /* Allocate memory for the lists of nodes */ +! size = (nstate + 1) * sizeof(nfa_thread_T); +! list[0].t = (nfa_thread_T *)lalloc(size, TRUE); +! list[1].t = (nfa_thread_T *)lalloc(size, TRUE); +! list[2].t = (nfa_thread_T *)lalloc(size, TRUE); + if (list[0].t == NULL || list[1].t == NULL || list[2].t == NULL) + goto theend; + vim_memset(list[0].t, 0, size); +*************** +*** 3056,3063 **** + * nfa_regmatch(). Submatches are stored in *m, and used in + * the parent call. */ + if (start->c == NFA_MOPEN + 0) +! addstate(thislist, t->state->out, &t->sub, 0, listid, +! &match); + else + { + *m = t->sub; +--- 3107,3114 ---- + * nfa_regmatch(). Submatches are stored in *m, and used in + * the parent call. */ + if (start->c == NFA_MOPEN + 0) +! addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &i); + else + { + *m = t->sub; +*************** +*** 3130,3137 **** + t->sub.end[j] = m->end[j]; + } + /* t->state->out1 is the corresponding END_INVISIBLE node */ +! addstate(thislist, t->state->out1->out, &t->sub, 0, listid, +! &match); + } + else + { +--- 3181,3188 ---- + t->sub.end[j] = m->end[j]; + } + /* t->state->out1 is the corresponding END_INVISIBLE node */ +! addstate_here(thislist, t->state->out1->out, &t->sub, +! listid, &match, &i); + } + else + { +*************** +*** 3142,3155 **** + + case NFA_BOL: + if (reginput == regline) +! addstate(thislist, t->state->out, &t->sub, 0, listid, +! &match); + break; + + case NFA_EOL: + if (c == NUL) +! addstate(thislist, t->state->out, &t->sub, 0, listid, +! &match); + break; + + case NFA_BOW: +--- 3193,3206 ---- + + case NFA_BOL: + if (reginput == regline) +! addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &i); + break; + + case NFA_EOL: + if (c == NUL) +! addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &i); + break; + + case NFA_BOW: +*************** +*** 3176,3183 **** + && vim_iswordc_buf(reginput[-1], reg_buf))) + bow = FALSE; + if (bow) +! addstate(thislist, t->state->out, &t->sub, 0, listid, +! &match); + break; + } + +--- 3227,3234 ---- + && vim_iswordc_buf(reginput[-1], reg_buf))) + bow = FALSE; + if (bow) +! addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &i); + break; + } + +*************** +*** 3204,3211 **** + || (reginput[0] != NUL && vim_iswordc_buf(c, reg_buf))) + eow = FALSE; + if (eow) +! addstate(thislist, t->state->out, &t->sub, 0, listid, +! &match); + break; + } + +--- 3255,3262 ---- + || (reginput[0] != NUL && vim_iswordc_buf(c, reg_buf))) + eow = FALSE; + if (eow) +! addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &i); + break; + } + +*** ../vim-7.3.1016/src/testdir/test64.in 2013-05-21 13:30:17.000000000 +0200 +--- src/testdir/test64.in 2013-05-25 19:54:40.000000000 +0200 +*************** +*** 270,275 **** +--- 270,276 ---- + :call add(tl, ['aa \zsax', ' ax']) " must match before \zs + :call add(tl, ['abc \zsmatch\ze abc', 'abc abc abc match abc abc', 'match']) + :call add(tl, ['\v(a \zsif .*){2}', 'a if then a if last', 'if last', 'a if last']) ++ :call add(tl, ['\>\zs.', 'aword. ', '.']) + + :"""" Tests for \@ features + :call add(tl, ['abc\@=', 'abc', 'ab']) +*************** +*** 299,304 **** +--- 300,311 ---- + :call add(tl, ['\%u0020', 'yes no', ' ']) + :call add(tl, ['\%U00000020', 'yes no', ' ']) + ++ :"""" Alternatives, must use first longest match ++ :call add(tl, ['goo\|go', 'google', 'goo']) ++ :call add(tl, ['\\zs. + OK - abc\@= + OK - abc\@=cd + OK - abc\@= +*************** +*** 231,234 **** +--- 232,238 ---- + OK - \%x20 + OK - \%u0020 + OK - \%U00000020 ++ OK - goo\|go ++ OK - \ Date: Tue, 4 Jun 2013 12:06:01 +0200 Subject: [PATCH 0909/3340] - patchlevel 1018 --- 7.3.1018 | 97 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100644 7.3.1018 diff --git a/7.3.1018 b/7.3.1018 new file mode 100644 index 00000000..98e05fa2 --- /dev/null +++ b/7.3.1018 @@ -0,0 +1,97 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1018 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1018 +Problem: New regexp engine wastes memory. +Solution: Allocate prog with actual number of states, not estimated maximum + number of sates. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1017/src/regexp_nfa.c 2013-05-25 20:19:45.000000000 +0200 +--- src/regexp_nfa.c 2013-05-25 20:57:21.000000000 +0200 +*************** +*** 3758,3764 **** + char_u *expr; + int re_flags; + { +! nfa_regprog_T *prog; + size_t prog_size; + int *postfix; + +--- 3758,3764 ---- + char_u *expr; + int re_flags; + { +! nfa_regprog_T *prog = NULL; + size_t prog_size; + int *postfix; + +*************** +*** 3774,3788 **** + if (nfa_regcomp_start(expr, re_flags) == FAIL) + return NULL; + +- /* Space for compiled regexp */ +- prog_size = sizeof(nfa_regprog_T) + sizeof(nfa_state_T) * nstate_max; +- prog = (nfa_regprog_T *)lalloc(prog_size, TRUE); +- if (prog == NULL) +- goto fail; +- vim_memset(prog, 0, prog_size); +- + /* Build postfix form of the regexp. Needed to build the NFA +! * (and count its size) */ + postfix = re2post(); + if (postfix == NULL) + goto fail; /* Cascaded (syntax?) error */ +--- 3774,3781 ---- + if (nfa_regcomp_start(expr, re_flags) == FAIL) + return NULL; + + /* Build postfix form of the regexp. Needed to build the NFA +! * (and count its size). */ + postfix = re2post(); + if (postfix == NULL) + goto fail; /* Cascaded (syntax?) error */ +*************** +*** 3809,3814 **** +--- 3802,3814 ---- + * Count number of NFA states in "nstate". Do not build the NFA. + */ + post2nfa(postfix, post_ptr, TRUE); ++ ++ /* Space for compiled regexp */ ++ prog_size = sizeof(nfa_regprog_T) + sizeof(nfa_state_T) * nstate; ++ prog = (nfa_regprog_T *)lalloc(prog_size, TRUE); ++ if (prog == NULL) ++ goto fail; ++ vim_memset(prog, 0, prog_size); + state_ptr = prog->state; + + /* +*** ../vim-7.3.1017/src/version.c 2013-05-25 20:19:45.000000000 +0200 +--- src/version.c 2013-05-25 21:17:39.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1018, + /**/ + +-- +Sometimes you can protect millions of dollars in your budget simply by buying +a bag of cookies, dropping it on the budget anylyst's desk, and saying +something deeply personal such as "How was your weekend, big guy?" + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e233d0f83041f490636a507d58f702e0f2b6a8f9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:01 +0200 Subject: [PATCH 0910/3340] - patchlevel 1019 --- 7.3.1019 | 152 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 152 insertions(+) create mode 100644 7.3.1019 diff --git a/7.3.1019 b/7.3.1019 new file mode 100644 index 00000000..481bce0e --- /dev/null +++ b/7.3.1019 @@ -0,0 +1,152 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1019 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1019 +Problem: These do not work with the new regexp engine: \%o123, \%x123, + \%d123, \%u123 and \%U123. +Solution: Implement these items. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1018/src/regexp_nfa.c 2013-05-25 21:18:30.000000000 +0200 +--- src/regexp_nfa.c 2013-05-25 21:56:16.000000000 +0200 +*************** +*** 604,610 **** + char_u *endp; + #ifdef FEAT_MBYTE + char_u *old_regparse = regparse; +- int clen; + int i; + #endif + int extra = 0; +--- 604,609 ---- +*************** +*** 623,637 **** + cpo_bsl = vim_strchr(p_cpo, CPO_BACKSL) != NULL; + + c = getchr(); +- +- #ifdef FEAT_MBYTE +- /* clen has the length of the current char, without composing chars */ +- clen = (*mb_char2len)(c); +- if (has_mbyte && clen > 1) +- goto nfa_do_multibyte; +- #endif + switch (c) + { + case Magic('^'): + EMIT(NFA_BOL); + break; +--- 622,633 ---- + cpo_bsl = vim_strchr(p_cpo, CPO_BACKSL) != NULL; + + c = getchr(); + switch (c) + { ++ case NUL: ++ syntax_error = TRUE; ++ EMSG_RET_FAIL(_("E865: (NFA) Regexp end encountered prematurely")); ++ + case Magic('^'): + EMIT(NFA_BOL); + break; +*************** +*** 747,756 **** + return FAIL; /* cascaded error */ + break; + +- case NUL: +- syntax_error = TRUE; +- EMSG_RET_FAIL(_("E865: (NFA) Regexp end encountered prematurely")); +- + case Magic('|'): + case Magic('&'): + case Magic(')'): +--- 743,748 ---- +*************** +*** 834,844 **** + case 'x': /* %xab hex 2 */ + case 'u': /* %uabcd hex 4 */ + case 'U': /* %U1234abcd hex 8 */ +! /* Not yet supported */ +! return FAIL; + +! c = coll_get_char(); +! EMIT(c); + break; + + /* Catch \%^ and \%$ regardless of where they appear in the +--- 826,851 ---- + case 'x': /* %xab hex 2 */ + case 'u': /* %uabcd hex 4 */ + case 'U': /* %U1234abcd hex 8 */ +! { +! int i; + +! switch (c) +! { +! case 'd': i = getdecchrs(); break; +! case 'o': i = getoctchrs(); break; +! case 'x': i = gethexchrs(2); break; +! case 'u': i = gethexchrs(4); break; +! case 'U': i = gethexchrs(8); break; +! default: i = -1; break; +! } +! +! if (i < 0) +! EMSG2_RET_FAIL( +! _("E678: Invalid character after %s%%[dxouU]"), +! reg_magic == MAGIC_ALL); +! /* TODO: what if a composing character follows? */ +! EMIT(i); +! } + break; + + /* Catch \%^ and \%$ regardless of where they appear in the +*************** +*** 1217,1225 **** + int plen; + + nfa_do_multibyte: +! /* Length of current char with composing chars. */ +! if (enc_utf8 && (clen != (plen = (*mb_ptr2len)(old_regparse)) +! || utf_iscomposing(c))) + { + /* A base character plus composing characters, or just one + * or more composing characters. +--- 1224,1233 ---- + int plen; + + nfa_do_multibyte: +! /* plen is length of current char with composing chars */ +! if (enc_utf8 && ((*mb_char2len)(c) +! != (plen = (*mb_ptr2len)(old_regparse)) +! || utf_iscomposing(c))) + { + /* A base character plus composing characters, or just one + * or more composing characters. +*** ../vim-7.3.1018/src/version.c 2013-05-25 21:18:30.000000000 +0200 +--- src/version.c 2013-05-25 22:00:51.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1019, + /**/ + +-- +The budget process was invented by an alien race of sadistic beings who +resemble large cats. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3ce479f3e513b9a347c4bf38cd3339d9067dddcd Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:02 +0200 Subject: [PATCH 0911/3340] - patchlevel 1020 --- 7.3.1020 | 1945 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1945 insertions(+) create mode 100644 7.3.1020 diff --git a/7.3.1020 b/7.3.1020 new file mode 100644 index 00000000..7093a8ef --- /dev/null +++ b/7.3.1020 @@ -0,0 +1,1945 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1020 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1020 +Problem: Not all patterns are tested with auto / old / new engine. +Solution: Test patterns with three values of 'regexpengine'. +Files: src/testdir/test64.in, src/testdir/test64.ok, + src/testdir/test95.in, src/testdir/test95.ok + + +*** ../vim-7.3.1019/src/testdir/test64.in 2013-05-25 20:19:45.000000000 +0200 +--- src/testdir/test64.in 2013-05-25 23:11:58.000000000 +0200 +*************** +*** 20,347 **** + :"""" Previously written tests """""""""""""""""""""""""""""""" + :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" + +! :call add(tl, ['ab', 'aab', 'ab']) +! :call add(tl, ['b', 'abcdef', 'b']) +! :call add(tl, ['bc*', 'abccccdef', 'bcccc']) +! :call add(tl, ['bc\{-}', 'abccccdef', 'b']) +! :call add(tl, ['bc\{-}\(d\)', 'abccccdef', 'bccccd', 'd']) +! :call add(tl, ['bc*', 'abbdef', 'b']) +! :call add(tl, ['c*', 'ccc', 'ccc']) +! :call add(tl, ['bc*', 'abdef', 'b']) +! :call add(tl, ['c*', 'abdef', '']) +! :call add(tl, ['bc\+', 'abccccdef', 'bcccc']) +! :call add(tl, ['bc\+', 'abdef']) "no match + :" + :"operator \| +! :call add(tl, ['a\|ab', 'cabd', 'a']) "alternation is ordered + :" +! :call add(tl, ['c\?', 'ccb', 'c']) +! :call add(tl, ['bc\?', 'abd', 'b']) +! :call add(tl, ['bc\?', 'abccd', 'bc']) +! :" +! :call add(tl, ['\va{1}', 'ab', 'a']) +! :" +! :call add(tl, ['\va{2}', 'aa', 'aa']) +! :call add(tl, ['\va{2}', 'caad', 'aa']) +! :call add(tl, ['\va{2}', 'aba']) +! :call add(tl, ['\va{2}', 'ab']) +! :call add(tl, ['\va{2}', 'abaa', 'aa']) +! :call add(tl, ['\va{2}', 'aaa', 'aa']) +! :" +! :call add(tl, ['\vb{1}', 'abca', 'b']) +! :call add(tl, ['\vba{2}', 'abaa', 'baa']) +! :call add(tl, ['\vba{3}', 'aabaac']) +! :" +! :call add(tl, ['\v(ab){1}', 'ab', 'ab', 'ab']) +! :call add(tl, ['\v(ab){1}', 'dabc', 'ab', 'ab']) +! :call add(tl, ['\v(ab){1}', 'acb']) +! :" +! :call add(tl, ['\v(ab){0,2}', 'acb', "", ""]) +! :call add(tl, ['\v(ab){0,2}', 'ab', 'ab', 'ab']) +! :call add(tl, ['\v(ab){1,2}', 'ab', 'ab', 'ab']) +! :call add(tl, ['\v(ab){1,2}', 'ababc', 'abab', 'ab']) +! :call add(tl, ['\v(ab){2,4}', 'ababcab', 'abab', 'ab']) +! :call add(tl, ['\v(ab){2,4}', 'abcababa', 'abab', 'ab']) +! :" +! :call add(tl, ['\v(ab){2}', 'abab', 'abab', 'ab']) +! :call add(tl, ['\v(ab){2}', 'cdababe', 'abab', 'ab']) +! :call add(tl, ['\v(ab){2}', 'abac']) +! :call add(tl, ['\v(ab){2}', 'abacabab', 'abab', 'ab']) +! :call add(tl, ['\v((ab){2}){2}', 'abababab', 'abababab', 'abab', 'ab']) +! :call add(tl, ['\v((ab){2}){2}', 'abacabababab', 'abababab', 'abab', 'ab']) +! :" +! :call add(tl, ['\v(a{1}){1}', 'a', 'a', 'a']) +! :call add(tl, ['\v(a{2}){1}', 'aa', 'aa', 'aa']) +! :call add(tl, ['\v(a{2}){1}', 'aaac', 'aa', 'aa']) +! :call add(tl, ['\v(a{2}){1}', 'daaac', 'aa', 'aa']) +! :call add(tl, ['\v(a{1}){2}', 'daaac', 'aa', 'a']) +! :call add(tl, ['\v(a{1}){2}', 'aaa', 'aa', 'a']) +! :call add(tl, ['\v(a{2})+', 'adaac', 'aa', 'aa']) +! :call add(tl, ['\v(a{2})+', 'aa', 'aa', 'aa']) +! :call add(tl, ['\v(a{2}){1}', 'aa', 'aa', 'aa']) +! :call add(tl, ['\v(a{1}){2}', 'aa', 'aa', 'a']) +! :call add(tl, ['\v(a{1}){1}', 'a', 'a', 'a']) +! :call add(tl, ['\v(a{2}){2}', 'aaaa', 'aaaa', 'aa']) +! :call add(tl, ['\v(a{2}){2}', 'aaabaaaa', 'aaaa', 'aa']) +! :" +! :call add(tl, ['\v(a+){2}', 'dadaac', 'aa', 'a']) +! :call add(tl, ['\v(a{3}){2}', 'aaaaaaa', 'aaaaaa', 'aaa']) +! :" +! :call add(tl, ['\v(a{1,2}){2}', 'daaac', 'aaa', 'a']) +! :call add(tl, ['\v(a{1,3}){2}', 'daaaac', 'aaaa', 'a']) +! :call add(tl, ['\v(a{1,3}){2}', 'daaaaac', 'aaaaa', 'aa']) +! :call add(tl, ['\v(a{1,3}){3}', 'daac']) +! :call add(tl, ['\v(a{1,2}){2}', 'dac']) +! :call add(tl, ['\v(a+)+', 'daac', 'aa', 'aa']) +! :call add(tl, ['\v(a+)+', 'aaa', 'aaa', 'aaa']) +! :call add(tl, ['\v(a+){1,2}', 'aaa', 'aaa', 'aaa']) +! :call add(tl, ['\v(a+)(a+)', 'aaa', 'aaa', 'aa', 'a']) +! :call add(tl, ['\v(a{3})+', 'daaaac', 'aaa', 'aaa']) +! :call add(tl, ['\v(a|b|c)+', 'aacb', 'aacb', 'b']) +! :call add(tl, ['\v(a|b|c){2}', 'abcb', 'ab', 'b']) +! :call add(tl, ['\v(abc){2}', 'abcabd', ]) +! :call add(tl, ['\v(abc){2}', 'abdabcabc','abcabc', 'abc']) +! :" +! :call add(tl, ['a*', 'cc', '']) +! :call add(tl, ['\v(a*)+', 'cc', '']) +! :call add(tl, ['\v((ab)+)+', 'ab', 'ab', 'ab', 'ab']) +! :call add(tl, ['\v(((ab)+)+)+', 'ab', 'ab', 'ab', 'ab', 'ab']) +! :call add(tl, ['\v(((ab)+)+)+', 'dababc', 'abab', 'abab', 'abab', 'ab']) +! :call add(tl, ['\v(a{0,2})+', 'cc', '']) +! :call add(tl, ['\v(a*)+', '', '']) +! :call add(tl, ['\v((a*)+)+', '', '']) +! :call add(tl, ['\v((ab)*)+', '', '']) +! :call add(tl, ['\va{1,3}', 'aab', 'aa']) +! :call add(tl, ['\va{2,3}', 'abaa', 'aa']) +! :" +! :call add(tl, ['\v((ab)+|c*)+', 'abcccaba', 'abcccab', '', 'ab']) +! :call add(tl, ['\v(a{2})|(b{3})', 'bbabbbb', 'bbb', '', 'bbb']) +! :call add(tl, ['\va{2}|b{2}', 'abab']) +! :call add(tl, ['\v(a)+|(c)+', 'bbacbaacbbb', 'a', 'a']) +! :call add(tl, ['\vab{2,3}c', 'aabbccccccccccccc', 'abbc']) +! :call add(tl, ['\vab{2,3}c', 'aabbbccccccccccccc', 'abbbc']) +! :call add(tl, ['\vab{2,3}cd{2,3}e', 'aabbbcddee', 'abbbcdde']) +! :call add(tl, ['\va(bc){2}d', 'aabcbfbc' ]) +! :call add(tl, ['\va*a{2}', 'a', ]) +! :call add(tl, ['\va*a{2}', 'aa', 'aa' ]) +! :call add(tl, ['\va*a{2}', 'aaa', 'aaa' ]) +! :call add(tl, ['\va*a{2}', 'bbbabcc', ]) +! :call add(tl, ['\va*b*|a*c*', 'a', 'a']) +! :call add(tl, ['\va{1}b{1}|a{1}b{1}', '']) + :" + :"submatches +! :call add(tl, ['\v(a)', 'ab', 'a', 'a']) +! :call add(tl, ['\v(a)(b)', 'ab', 'ab', 'a', 'b']) +! :call add(tl, ['\v(ab)(b)(c)', 'abbc', 'abbc', 'ab', 'b', 'c']) +! :call add(tl, ['\v((a)(b))', 'ab', 'ab', 'ab', 'a', 'b']) +! :call add(tl, ['\v(a)|(b)', 'ab', 'a', 'a']) + :" +! :call add(tl, ['\v(a*)+', 'aaaa', 'aaaa', '']) +! :call add(tl, ['x', 'abcdef']) + + :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" + :""""" Simple tests """"""""""""""""""""""""""""""""""""""""""" + :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" + + :" Search single groups +! :call add(tl, ['ab', 'aab', 'ab']) +! :call add(tl, ['ab', 'baced']) +! :call add(tl, ['ab', ' ab ', 'ab']) + + :" Search multi-modifiers +! :call add(tl, ['x*', 'xcd', 'x']) +! :call add(tl, ['x*', 'xxxxxxxxxxxxxxxxsofijiojgf', 'xxxxxxxxxxxxxxxx']) +! :call add(tl, ['x*', 'abcdoij', '']) " empty match is good +! :call add(tl, ['x\+', 'abcdoin']) " no match here +! :call add(tl, ['x\+', 'abcdeoijdfxxiuhfij', 'xx']) +! :call add(tl, ['x\+', 'xxxxx', 'xxxxx']) +! :call add(tl, ['x\+', 'abc x siufhiush xxxxxxxxx', 'x']) +! :call add(tl, ['x\=', 'x sdfoij', 'x']) +! :call add(tl, ['x\=', 'abc sfoij', '']) " empty match is good +! :call add(tl, ['x\=', 'xxxxxxxxx c', 'x']) +! :call add(tl, ['x\?', 'x sdfoij', 'x']) +! :call add(tl, ['x\?', 'abc sfoij', '']) " empty match is good +! :call add(tl, ['x\?', 'xxxxxxxxxx c', 'x']) +! +! :call add(tl, ['a\{0,0}', 'abcdfdoij', '']) +! :call add(tl, ['a\{0,1}', 'asiubid axxxaaa', 'a']) " same thing as 'a?' +! :call add(tl, ['a\{1,0}', 'asiubid axxxaaa', 'a']) " same thing as 'a\{0,1}' +! :call add(tl, ['a\{3,6}', 'aa siofuh']) +! :call add(tl, ['a\{3,6}', 'aaaaa asfoij afaa', 'aaaaa']) +! :call add(tl, ['a\{3,6}', 'aaaaaaaa', 'aaaaaa']) +! :call add(tl, ['a\{0}', 'asoiuj', '']) +! :call add(tl, ['a\{2}', 'aaaa', 'aa']) +! :call add(tl, ['a\{2}', 'iuash fiusahfliusah fiushfilushfi uhsaifuh askfj nasfvius afg aaaa sfiuhuhiushf', 'aa']) +! :call add(tl, ['a\{2}', 'abcdefghijklmnopqrestuvwxyz1234567890']) +! :call add(tl, ['a\{0,}', 'oij sdigfusnf', '']) " same thing as 'a*' +! :call add(tl, ['a\{0,}', 'aaaaa aa', 'aaaaa']) +! :call add(tl, ['a\{2,}', 'sdfiougjdsafg']) +! :call add(tl, ['a\{2,}', 'aaaaasfoij ', 'aaaaa']) +! :call add(tl, ['a\{,0}', 'oidfguih iuhi hiu aaaa', '']) +! :call add(tl, ['a\{,5}', 'abcd', 'a']) +! :call add(tl, ['a\{,5}', 'aaaaaaaaaa', 'aaaaa']) +! :call add(tl, ['a\{}', 'bbbcddiuhfcd', '']) " same thing as 'a*' +! :call add(tl, ['a\{}', 'aaaaioudfh coisf jda', 'aaaa']) +! +! :call add(tl, ['a\{-0,0}', 'abcdfdoij', '']) +! :call add(tl, ['a\{-0,1}', 'asiubid axxxaaa', '']) " anti-greedy version of 'a?' +! :call add(tl, ['a\{-3,6}', 'aa siofuh']) +! :call add(tl, ['a\{-3,6}', 'aaaaa asfoij afaa', 'aaa']) +! :call add(tl, ['a\{-3,6}', 'aaaaaaaa', 'aaa']) +! :call add(tl, ['a\{-0}', 'asoiuj', '']) +! :call add(tl, ['a\{-2}', 'aaaa', 'aa']) +! :call add(tl, ['a\{-2}', 'abcdefghijklmnopqrestuvwxyz1234567890']) +! :call add(tl, ['a\{-0,}', 'oij sdigfusnf', '']) +! :call add(tl, ['a\{-0,}', 'aaaaa aa', '']) +! :call add(tl, ['a\{-2,}', 'sdfiougjdsafg']) +! :call add(tl, ['a\{-2,}', 'aaaaasfoij ', 'aa']) +! :call add(tl, ['a\{-,0}', 'oidfguih iuhi hiu aaaa', '']) +! :call add(tl, ['a\{-,5}', 'abcd', '']) +! :call add(tl, ['a\{-,5}', 'aaaaaaaaaa', '']) +! :call add(tl, ['a\{-}', 'bbbcddiuhfcd', '']) " anti-greedy version of 'a*' +! :call add(tl, ['a\{-}', 'aaaaioudfh coisf jda', '']) + + :" Test groups of characters and submatches +! :call add(tl, ['\(abc\)*', 'abcabcabc', 'abcabcabc', 'abc']) +! :call add(tl, ['\(ab\)\+', 'abababaaaaa', 'ababab', 'ab']) +! :call add(tl, ['\(abaaaaa\)*cd', 'cd', 'cd', '']) +! :call add(tl, ['\(test1\)\? \(test2\)\?', 'test1 test3', 'test1 ', 'test1', '']) +! :call add(tl, ['\(test1\)\= \(test2\) \(test4443\)\=', ' test2 test4443 yupiiiiiiiiiii', ' test2 test4443', '', 'test2', 'test4443']) +! :call add(tl, ['\(\(sub1\) hello \(sub 2\)\)', 'asterix sub1 hello sub 2 obelix', 'sub1 hello sub 2', 'sub1 hello sub 2', 'sub1', 'sub 2']) +! :call add(tl, ['\(\(\(yyxxzz\)\)\)', 'abcdddsfiusfyyzzxxyyxxzz', 'yyxxzz', 'yyxxzz', 'yyxxzz', 'yyxxzz']) +! :call add(tl, ['\v((ab)+|c+)+', 'abcccaba', 'abcccab', 'ab', 'ab']) +! :call add(tl, ['\v((ab)|c*)+', 'abcccaba', 'abcccab', '', 'ab']) +! :call add(tl, ['\v(a(c*)+b)+', 'acbababaaa', 'acbabab', 'ab', '']) +! :call add(tl, ['\v(a|b*)+', 'aaaa', 'aaaa', '']) + + :" Test greedy-ness and lazy-ness +! :call add(tl, ['a\{-2,7}','aaaaaaaaaaaaa', 'aa']) +! :call add(tl, ['a\{2,7}','aaaaaaaaaaaaaaaaaaaa', 'aaaaaaa']) +! :call add(tl, ['\vx(.{-,8})yz(.*)','xayxayzxayzxayz','xayxayzxayzxayz','ayxa','xayzxayz']) +! :call add(tl, ['\vx(.*)yz(.*)','xayxayzxayzxayz','xayxayzxayzxayz', 'ayxayzxayzxa','']) +! :call add(tl, ['\v(a{1,2}){-2,3}','aaaaaaa','aaaa','aa']) +! :call add(tl, ['\v(a{-1,3})+','aa','aa','a']) + + :" Test Character classes +! :call add(tl, ['\d\+e\d\d','test 10e23 fd','10e23']) + + :" Test collections and character range [] +! :call add(tl, ['\v[a]', 'abcd', 'a']) +! :call add(tl, ['a[bcd]', 'abcd', 'ab']) +! :call add(tl, ['a[b-d]', 'acbd', 'ac']) +! :call add(tl, ['[a-d][e-f][x-x]d', 'cexdxx', 'cexd']) +! :call add(tl, ['\v[[:alpha:]]+', 'abcdefghijklmnopqrstuvwxyz6','abcdefghijklmnopqrstuvwxyz']) +! :call add(tl, ['[[:alpha:]\+]', '6x8','x']) +! :call add(tl, ['[^abc]\+','abcabcabc']) +! :call add(tl, ['[^abc]','defghiasijvoinasoiunbvb','d']) +! :call add(tl, ['[^abc]\+','ddddddda','ddddddd']) +! :call add(tl, ['[^a-d]\+','aaaAAAZIHFNCddd','AAAZIHFNC']) +! :call add(tl, ['[a-f]*','iiiiiiii','']) +! :call add(tl, ['[a-f]*','abcdefgh','abcdef']) +! :call add(tl, ['[^a-f]\+','abcdefgh','gh']) +! :call add(tl, ['[a-c]\{-3,6}','abcabc','abc']) +! :call add(tl, ['[^[:alpha:]]\+','abcccadfoij7787ysf287yrnccdu','7787']) +! :call add(tl, ['[-a]', '-', '-']) +! :call add(tl, ['[a-]', '-', '-']) +! :call add(tl, ['[-./[:alnum:]_~]\+', 'log13.file', 'log13.file']) " filename regexp +! :call add(tl, ['[\]\^\-\\]\+', '\^\\\-\---^', '\^\\\-\---^']) " special chars +! :call add(tl, ['[[.a.]]\+', 'aa', 'aa']) " collation elem +! :call add(tl, ['abc[0-9]*ddd', 'siuhabc ii']) " middle of regexp +! :call add(tl, ['abc[0-9]*ddd', 'adf abc44482ddd oijs', 'abc44482ddd']) +! :call add(tl, ['\_[0-9]\+', 'asfi9888u', '9888']) +! :call add(tl, ['[0-9\n]\+', 'asfi9888u', '9888']) + + + :"""" Test recognition of some character classes +! :call add(tl, ['[0-9]', '8', '8']) +! :call add(tl, ['[^0-9]', '8']) +! :call add(tl, ['[0-9a-fA-F]*', '0a7', '0a7']) +! :call add(tl, ['[^0-9A-Fa-f]\+', '0a7']) +! :call add(tl, ['[a-z_A-Z0-9]\+', 'aso_sfoij', 'aso_sfoij']) +! :call add(tl, ['[a-z]', 'a', 'a']) +! :call add(tl, ['[a-zA-Z]', 'a', 'a']) +! :call add(tl, ['[A-Z]', 'a']) +! :call add(tl, ['\C[^A-Z]\+', 'ABCOIJDEOIFNSD jsfoij sa', ' jsfoij sa']) + + :"""" Tests for \z features +! :call add(tl, ['xx \ze test', 'xx ']) " must match after \ze +! :call add(tl, ['abc\zeend', 'oij abcend', 'abc']) +! :call add(tl, ['abc\zsdd', 'ddabcddxyzt', 'dd']) +! :call add(tl, ['aa \zsax', ' ax']) " must match before \zs +! :call add(tl, ['abc \zsmatch\ze abc', 'abc abc abc match abc abc', 'match']) +! :call add(tl, ['\v(a \zsif .*){2}', 'a if then a if last', 'if last', 'a if last']) +! :call add(tl, ['\>\zs.', 'aword. ', '.']) + + :"""" Tests for \@ features +! :call add(tl, ['abc\@=', 'abc', 'ab']) +! :call add(tl, ['abc\@=cd', 'abcd', 'abcd']) +! :call add(tl, ['abc\@=', 'ababc', 'ab']) +! :call add(tl, ['abcd\@=e', 'abcd']) " will never match, no matter the input text +! :call add(tl, ['abcd\@=e', 'any text in here ... ']) " will never match +! :call add(tl, ['\v(abc)@=..', 'xabcd', 'ab', 'abc']) +! :call add(tl, ['\(.*John\)\@=.*Bob', 'here is John, and here is B']) " no match +! :call add(tl, ['\(John.*\)\@=.*Bob', 'John is Bobs friend', 'John is Bob', 'John is Bobs friend']) +! :call add(tl, ['.*John\&.*Bob', 'here is John, and here is B']) " no match +! :call add(tl, ['.*John\&.*Bob', 'John is Bobs friend', 'John is Bob']) +! :call add(tl, ['\v(test1)@=.*yep', 'this is a test1, yep it is', 'test1, yep', 'test1']) + + :"""" Combining different tests and features +! :call add(tl, ['[[:alpha:]]\{-2,6}', '787abcdiuhsasiuhb4', 'ab']) +! :call add(tl, ['', 'abcd', '']) +! :call add(tl, ['\v(())', 'any possible text', '']) +! :call add(tl, ['\v%(ab(xyz)c)', ' abxyzc ', 'abxyzc', 'xyz']) +! :call add(tl, ['\v(test|)empty', 'tesempty', 'empty', '']) +! :call add(tl, ['\v(a|aa)(a|aa)', 'aaa', 'aa', 'a', 'a']) + + :"""" \%u and friends +! :call add(tl, ['\%d32', 'yes no', ' ']) +! :call add(tl, ['\%o40', 'yes no', ' ']) +! :call add(tl, ['\%x20', 'yes no', ' ']) +! :call add(tl, ['\%u0020', 'yes no', ' ']) +! :call add(tl, ['\%U00000020', 'yes no', ' ']) + + :"""" Alternatives, must use first longest match +! :call add(tl, ['goo\|go', 'google', 'goo']) +! :call add(tl, ['\ 2 +! : $put ='ERROR: pat: \"' . t[0] . '\", text: \"' . t[1] . '\", did not match, expected: \"' . t[2] . '\"' +! : elseif len(l) > 0 && len(t) == 2 +! : $put ='ERROR: pat: \"' . t[0] . '\", text: \"' . t[1] . '\", match: \"' . l[0] . '\", expected no match' +! : elseif len(t) > 2 && l[0] != t[2] +! : $put ='ERROR: pat: \"' . t[0] . '\", text: \"' . t[1] . '\", match: \"' . l[0] . '\", expected: \"' . t[2] . '\"' +! : else +! : $put ='OK - ' . t[0] +! : endif +! : if len(l) > 0 + :" check all the nine submatches +! : for i in range(1, 9) +! : if len(t) <= i + 2 +! : let e = '' +! : else +! : let e = t[i + 2] +! : endif +! : if l[i] != e +! : $put ='ERROR: pat: \"' . t[0] . '\", text: \"' . t[1] . '\", submatch ' . i . ': \"' . l[i] . '\", expected: \"' . e . '\"' +! : endif +! : endfor +! : unlet i +! : endif + :endfor + :unlet t tl e l + + :" Check that \_[0-9] matching EOL does not break a following \> + :" This only works on a buffer line, not with expression evaluation + /^Find this +! /\<\(\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\.\)\{3\}\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\> + y$Gop:" + + :/\%#=1^Results/,$wq! test.out +--- 20,363 ---- + :"""" Previously written tests """""""""""""""""""""""""""""""" + :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" + +! :call add(tl, [2, 'ab', 'aab', 'ab']) +! :call add(tl, [2, 'b', 'abcdef', 'b']) +! :call add(tl, [2, 'bc*', 'abccccdef', 'bcccc']) +! :call add(tl, [0, 'bc\{-}', 'abccccdef', 'b']) +! :call add(tl, [0, 'bc\{-}\(d\)', 'abccccdef', 'bccccd', 'd']) +! :call add(tl, [2, 'bc*', 'abbdef', 'b']) +! :call add(tl, [2, 'c*', 'ccc', 'ccc']) +! :call add(tl, [2, 'bc*', 'abdef', 'b']) +! :call add(tl, [2, 'c*', 'abdef', '']) +! :call add(tl, [2, 'bc\+', 'abccccdef', 'bcccc']) +! :call add(tl, [2, 'bc\+', 'abdef']) "no match + :" + :"operator \| +! :call add(tl, [2, 'a\|ab', 'cabd', 'a']) "alternation is ordered + :" +! :call add(tl, [2, 'c\?', 'ccb', 'c']) +! :call add(tl, [2, 'bc\?', 'abd', 'b']) +! :call add(tl, [2, 'bc\?', 'abccd', 'bc']) +! :" +! :call add(tl, [2, '\va{1}', 'ab', 'a']) +! :" +! :call add(tl, [2, '\va{2}', 'aa', 'aa']) +! :call add(tl, [2, '\va{2}', 'caad', 'aa']) +! :call add(tl, [2, '\va{2}', 'aba']) +! :call add(tl, [2, '\va{2}', 'ab']) +! :call add(tl, [2, '\va{2}', 'abaa', 'aa']) +! :call add(tl, [2, '\va{2}', 'aaa', 'aa']) +! :" +! :call add(tl, [2, '\vb{1}', 'abca', 'b']) +! :call add(tl, [2, '\vba{2}', 'abaa', 'baa']) +! :call add(tl, [2, '\vba{3}', 'aabaac']) +! :" +! :call add(tl, [2, '\v(ab){1}', 'ab', 'ab', 'ab']) +! :call add(tl, [2, '\v(ab){1}', 'dabc', 'ab', 'ab']) +! :call add(tl, [2, '\v(ab){1}', 'acb']) +! :" +! :call add(tl, [2, '\v(ab){0,2}', 'acb', "", ""]) +! :call add(tl, [2, '\v(ab){0,2}', 'ab', 'ab', 'ab']) +! :call add(tl, [2, '\v(ab){1,2}', 'ab', 'ab', 'ab']) +! :call add(tl, [2, '\v(ab){1,2}', 'ababc', 'abab', 'ab']) +! :call add(tl, [2, '\v(ab){2,4}', 'ababcab', 'abab', 'ab']) +! :call add(tl, [2, '\v(ab){2,4}', 'abcababa', 'abab', 'ab']) +! :" +! :call add(tl, [2, '\v(ab){2}', 'abab', 'abab', 'ab']) +! :call add(tl, [2, '\v(ab){2}', 'cdababe', 'abab', 'ab']) +! :call add(tl, [2, '\v(ab){2}', 'abac']) +! :call add(tl, [2, '\v(ab){2}', 'abacabab', 'abab', 'ab']) +! :call add(tl, [2, '\v((ab){2}){2}', 'abababab', 'abababab', 'abab', 'ab']) +! :call add(tl, [2, '\v((ab){2}){2}', 'abacabababab', 'abababab', 'abab', 'ab']) +! :" +! :call add(tl, [2, '\v(a{1}){1}', 'a', 'a', 'a']) +! :call add(tl, [2, '\v(a{2}){1}', 'aa', 'aa', 'aa']) +! :call add(tl, [2, '\v(a{2}){1}', 'aaac', 'aa', 'aa']) +! :call add(tl, [2, '\v(a{2}){1}', 'daaac', 'aa', 'aa']) +! :call add(tl, [2, '\v(a{1}){2}', 'daaac', 'aa', 'a']) +! :call add(tl, [2, '\v(a{1}){2}', 'aaa', 'aa', 'a']) +! :call add(tl, [2, '\v(a{2})+', 'adaac', 'aa', 'aa']) +! :call add(tl, [2, '\v(a{2})+', 'aa', 'aa', 'aa']) +! :call add(tl, [2, '\v(a{2}){1}', 'aa', 'aa', 'aa']) +! :call add(tl, [2, '\v(a{1}){2}', 'aa', 'aa', 'a']) +! :call add(tl, [2, '\v(a{1}){1}', 'a', 'a', 'a']) +! :call add(tl, [2, '\v(a{2}){2}', 'aaaa', 'aaaa', 'aa']) +! :call add(tl, [2, '\v(a{2}){2}', 'aaabaaaa', 'aaaa', 'aa']) +! :" +! :call add(tl, [2, '\v(a+){2}', 'dadaac', 'aa', 'a']) +! :call add(tl, [2, '\v(a{3}){2}', 'aaaaaaa', 'aaaaaa', 'aaa']) +! :" +! :call add(tl, [2, '\v(a{1,2}){2}', 'daaac', 'aaa', 'a']) +! :call add(tl, [2, '\v(a{1,3}){2}', 'daaaac', 'aaaa', 'a']) +! :call add(tl, [2, '\v(a{1,3}){2}', 'daaaaac', 'aaaaa', 'aa']) +! :call add(tl, [2, '\v(a{1,3}){3}', 'daac']) +! :call add(tl, [2, '\v(a{1,2}){2}', 'dac']) +! :call add(tl, [2, '\v(a+)+', 'daac', 'aa', 'aa']) +! :call add(tl, [2, '\v(a+)+', 'aaa', 'aaa', 'aaa']) +! :call add(tl, [2, '\v(a+){1,2}', 'aaa', 'aaa', 'aaa']) +! :call add(tl, [2, '\v(a+)(a+)', 'aaa', 'aaa', 'aa', 'a']) +! :call add(tl, [2, '\v(a{3})+', 'daaaac', 'aaa', 'aaa']) +! :call add(tl, [2, '\v(a|b|c)+', 'aacb', 'aacb', 'b']) +! :call add(tl, [2, '\v(a|b|c){2}', 'abcb', 'ab', 'b']) +! :call add(tl, [2, '\v(abc){2}', 'abcabd', ]) +! :call add(tl, [2, '\v(abc){2}', 'abdabcabc','abcabc', 'abc']) +! :" +! :call add(tl, [2, 'a*', 'cc', '']) +! :call add(tl, [2, '\v(a*)+', 'cc', '']) +! :call add(tl, [2, '\v((ab)+)+', 'ab', 'ab', 'ab', 'ab']) +! :call add(tl, [2, '\v(((ab)+)+)+', 'ab', 'ab', 'ab', 'ab', 'ab']) +! :call add(tl, [2, '\v(((ab)+)+)+', 'dababc', 'abab', 'abab', 'abab', 'ab']) +! :call add(tl, [2, '\v(a{0,2})+', 'cc', '']) +! :call add(tl, [2, '\v(a*)+', '', '']) +! :call add(tl, [2, '\v((a*)+)+', '', '']) +! :call add(tl, [2, '\v((ab)*)+', '', '']) +! :call add(tl, [2, '\va{1,3}', 'aab', 'aa']) +! :call add(tl, [2, '\va{2,3}', 'abaa', 'aa']) +! :" +! :call add(tl, [2, '\v((ab)+|c*)+', 'abcccaba', 'abcccab', '', 'ab']) +! :call add(tl, [2, '\v(a{2})|(b{3})', 'bbabbbb', 'bbb', '', 'bbb']) +! :call add(tl, [2, '\va{2}|b{2}', 'abab']) +! :call add(tl, [2, '\v(a)+|(c)+', 'bbacbaacbbb', 'a', 'a']) +! :call add(tl, [2, '\vab{2,3}c', 'aabbccccccccccccc', 'abbc']) +! :call add(tl, [2, '\vab{2,3}c', 'aabbbccccccccccccc', 'abbbc']) +! :call add(tl, [2, '\vab{2,3}cd{2,3}e', 'aabbbcddee', 'abbbcdde']) +! :call add(tl, [2, '\va(bc){2}d', 'aabcbfbc' ]) +! :call add(tl, [2, '\va*a{2}', 'a', ]) +! :call add(tl, [2, '\va*a{2}', 'aa', 'aa' ]) +! :call add(tl, [2, '\va*a{2}', 'aaa', 'aaa' ]) +! :call add(tl, [2, '\va*a{2}', 'bbbabcc', ]) +! :call add(tl, [2, '\va*b*|a*c*', 'a', 'a']) +! :call add(tl, [2, '\va{1}b{1}|a{1}b{1}', '']) + :" + :"submatches +! :call add(tl, [2, '\v(a)', 'ab', 'a', 'a']) +! :call add(tl, [2, '\v(a)(b)', 'ab', 'ab', 'a', 'b']) +! :call add(tl, [2, '\v(ab)(b)(c)', 'abbc', 'abbc', 'ab', 'b', 'c']) +! :call add(tl, [2, '\v((a)(b))', 'ab', 'ab', 'ab', 'a', 'b']) +! :call add(tl, [2, '\v(a)|(b)', 'ab', 'a', 'a']) + :" +! :call add(tl, [2, '\v(a*)+', 'aaaa', 'aaaa', '']) +! :call add(tl, [2, 'x', 'abcdef']) + + :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" + :""""" Simple tests """"""""""""""""""""""""""""""""""""""""""" + :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" + + :" Search single groups +! :call add(tl, [2, 'ab', 'aab', 'ab']) +! :call add(tl, [2, 'ab', 'baced']) +! :call add(tl, [2, 'ab', ' ab ', 'ab']) + + :" Search multi-modifiers +! :call add(tl, [2, 'x*', 'xcd', 'x']) +! :call add(tl, [2, 'x*', 'xxxxxxxxxxxxxxxxsofijiojgf', 'xxxxxxxxxxxxxxxx']) +! :call add(tl, [2, 'x*', 'abcdoij', '']) " empty match is good +! :call add(tl, [2, 'x\+', 'abcdoin']) " no match here +! :call add(tl, [2, 'x\+', 'abcdeoijdfxxiuhfij', 'xx']) +! :call add(tl, [2, 'x\+', 'xxxxx', 'xxxxx']) +! :call add(tl, [2, 'x\+', 'abc x siufhiush xxxxxxxxx', 'x']) +! :call add(tl, [2, 'x\=', 'x sdfoij', 'x']) +! :call add(tl, [2, 'x\=', 'abc sfoij', '']) " empty match is good +! :call add(tl, [2, 'x\=', 'xxxxxxxxx c', 'x']) +! :call add(tl, [2, 'x\?', 'x sdfoij', 'x']) +! :call add(tl, [2, 'x\?', 'abc sfoij', '']) " empty match is good +! :call add(tl, [2, 'x\?', 'xxxxxxxxxx c', 'x']) +! +! :call add(tl, [2, 'a\{0,0}', 'abcdfdoij', '']) +! :call add(tl, [2, 'a\{0,1}', 'asiubid axxxaaa', 'a']) " same thing as 'a?' +! :call add(tl, [2, 'a\{1,0}', 'asiubid axxxaaa', 'a']) " same thing as 'a\{0,1}' +! :call add(tl, [2, 'a\{3,6}', 'aa siofuh']) +! :call add(tl, [2, 'a\{3,6}', 'aaaaa asfoij afaa', 'aaaaa']) +! :call add(tl, [2, 'a\{3,6}', 'aaaaaaaa', 'aaaaaa']) +! :call add(tl, [2, 'a\{0}', 'asoiuj', '']) +! :call add(tl, [2, 'a\{2}', 'aaaa', 'aa']) +! :call add(tl, [2, 'a\{2}', 'iuash fiusahfliusah fiushfilushfi uhsaifuh askfj nasfvius afg aaaa sfiuhuhiushf', 'aa']) +! :call add(tl, [2, 'a\{2}', 'abcdefghijklmnopqrestuvwxyz1234567890']) +! :call add(tl, [2, 'a\{0,}', 'oij sdigfusnf', '']) " same thing as 'a*' +! :call add(tl, [2, 'a\{0,}', 'aaaaa aa', 'aaaaa']) +! :call add(tl, [2, 'a\{2,}', 'sdfiougjdsafg']) +! :call add(tl, [0, 'a\{2,}', 'aaaaasfoij ', 'aaaaa']) +! :call add(tl, [2, 'a\{,0}', 'oidfguih iuhi hiu aaaa', '']) +! :call add(tl, [2, 'a\{,5}', 'abcd', 'a']) +! :call add(tl, [2, 'a\{,5}', 'aaaaaaaaaa', 'aaaaa']) +! :call add(tl, [2, 'a\{}', 'bbbcddiuhfcd', '']) " same thing as 'a*' +! :call add(tl, [2, 'a\{}', 'aaaaioudfh coisf jda', 'aaaa']) +! +! :call add(tl, [2, 'a\{-0,0}', 'abcdfdoij', '']) +! :call add(tl, [2, 'a\{-0,1}', 'asiubid axxxaaa', '']) " anti-greedy version of 'a?' +! :call add(tl, [2, 'a\{-3,6}', 'aa siofuh']) +! :call add(tl, [2, 'a\{-3,6}', 'aaaaa asfoij afaa', 'aaa']) +! :call add(tl, [2, 'a\{-3,6}', 'aaaaaaaa', 'aaa']) +! :call add(tl, [2, 'a\{-0}', 'asoiuj', '']) +! :call add(tl, [2, 'a\{-2}', 'aaaa', 'aa']) +! :call add(tl, [2, 'a\{-2}', 'abcdefghijklmnopqrestuvwxyz1234567890']) +! :call add(tl, [0, 'a\{-0,}', 'oij sdigfusnf', '']) +! :call add(tl, [0, 'a\{-0,}', 'aaaaa aa', '']) +! :call add(tl, [2, 'a\{-2,}', 'sdfiougjdsafg']) +! :call add(tl, [0, 'a\{-2,}', 'aaaaasfoij ', 'aa']) +! :call add(tl, [2, 'a\{-,0}', 'oidfguih iuhi hiu aaaa', '']) +! :call add(tl, [2, 'a\{-,5}', 'abcd', '']) +! :call add(tl, [2, 'a\{-,5}', 'aaaaaaaaaa', '']) +! :call add(tl, [0, 'a\{-}', 'bbbcddiuhfcd', '']) " anti-greedy version of 'a*' +! :call add(tl, [0, 'a\{-}', 'aaaaioudfh coisf jda', '']) + + :" Test groups of characters and submatches +! :call add(tl, [2, '\(abc\)*', 'abcabcabc', 'abcabcabc', 'abc']) +! :call add(tl, [2, '\(ab\)\+', 'abababaaaaa', 'ababab', 'ab']) +! :call add(tl, [2, '\(abaaaaa\)*cd', 'cd', 'cd', '']) +! :call add(tl, [2, '\(test1\)\? \(test2\)\?', 'test1 test3', 'test1 ', 'test1', '']) +! :call add(tl, [2, '\(test1\)\= \(test2\) \(test4443\)\=', ' test2 test4443 yupiiiiiiiiiii', ' test2 test4443', '', 'test2', 'test4443']) +! :call add(tl, [2, '\(\(sub1\) hello \(sub 2\)\)', 'asterix sub1 hello sub 2 obelix', 'sub1 hello sub 2', 'sub1 hello sub 2', 'sub1', 'sub 2']) +! :call add(tl, [2, '\(\(\(yyxxzz\)\)\)', 'abcdddsfiusfyyzzxxyyxxzz', 'yyxxzz', 'yyxxzz', 'yyxxzz', 'yyxxzz']) +! :call add(tl, [2, '\v((ab)+|c+)+', 'abcccaba', 'abcccab', 'ab', 'ab']) +! :call add(tl, [2, '\v((ab)|c*)+', 'abcccaba', 'abcccab', '', 'ab']) +! :call add(tl, [2, '\v(a(c*)+b)+', 'acbababaaa', 'acbabab', 'ab', '']) +! :call add(tl, [2, '\v(a|b*)+', 'aaaa', 'aaaa', '']) + + :" Test greedy-ness and lazy-ness +! :call add(tl, [2, 'a\{-2,7}','aaaaaaaaaaaaa', 'aa']) +! :call add(tl, [2, 'a\{2,7}','aaaaaaaaaaaaaaaaaaaa', 'aaaaaaa']) +! :call add(tl, [2, '\vx(.{-,8})yz(.*)','xayxayzxayzxayz','xayxayzxayzxayz','ayxa','xayzxayz']) +! :call add(tl, [2, '\vx(.*)yz(.*)','xayxayzxayzxayz','xayxayzxayzxayz', 'ayxayzxayzxa','']) +! :call add(tl, [2, '\v(a{1,2}){-2,3}','aaaaaaa','aaaa','aa']) +! :call add(tl, [2, '\v(a{-1,3})+','aa','aa','a']) + + :" Test Character classes +! :call add(tl, [2, '\d\+e\d\d','test 10e23 fd','10e23']) + + :" Test collections and character range [] +! :call add(tl, [2, '\v[a]', 'abcd', 'a']) +! :call add(tl, [2, 'a[bcd]', 'abcd', 'ab']) +! :call add(tl, [2, 'a[b-d]', 'acbd', 'ac']) +! :call add(tl, [2, '[a-d][e-f][x-x]d', 'cexdxx', 'cexd']) +! :call add(tl, [2, '\v[[:alpha:]]+', 'abcdefghijklmnopqrstuvwxyz6','abcdefghijklmnopqrstuvwxyz']) +! :call add(tl, [2, '[[:alpha:]\+]', '6x8','x']) +! :call add(tl, [2, '[^abc]\+','abcabcabc']) +! :call add(tl, [2, '[^abc]','defghiasijvoinasoiunbvb','d']) +! :call add(tl, [2, '[^abc]\+','ddddddda','ddddddd']) +! :call add(tl, [2, '[^a-d]\+','aaaAAAZIHFNCddd','AAAZIHFNC']) +! :call add(tl, [2, '[a-f]*','iiiiiiii','']) +! :call add(tl, [2, '[a-f]*','abcdefgh','abcdef']) +! :call add(tl, [2, '[^a-f]\+','abcdefgh','gh']) +! :call add(tl, [2, '[a-c]\{-3,6}','abcabc','abc']) +! :call add(tl, [2, '[^[:alpha:]]\+','abcccadfoij7787ysf287yrnccdu','7787']) +! :call add(tl, [2, '[-a]', '-', '-']) +! :call add(tl, [2, '[a-]', '-', '-']) +! :call add(tl, [2, '[-./[:alnum:]_~]\+', 'log13.file', 'log13.file']) " filename regexp +! :call add(tl, [2, '[\]\^\-\\]\+', '\^\\\-\---^', '\^\\\-\---^']) " special chars +! :call add(tl, [2, '[[.a.]]\+', 'aa', 'aa']) " collation elem +! :call add(tl, [2, 'abc[0-9]*ddd', 'siuhabc ii']) " middle of regexp +! :call add(tl, [2, 'abc[0-9]*ddd', 'adf abc44482ddd oijs', 'abc44482ddd']) +! :call add(tl, [2, '\_[0-9]\+', 'asfi9888u', '9888']) +! :call add(tl, [2, '[0-9\n]\+', 'asfi9888u', '9888']) + + + :"""" Test recognition of some character classes +! :call add(tl, [2, '[0-9]', '8', '8']) +! :call add(tl, [2, '[^0-9]', '8']) +! :call add(tl, [2, '[0-9a-fA-F]*', '0a7', '0a7']) +! :call add(tl, [2, '[^0-9A-Fa-f]\+', '0a7']) +! :call add(tl, [2, '[a-z_A-Z0-9]\+', 'aso_sfoij', 'aso_sfoij']) +! :call add(tl, [2, '[a-z]', 'a', 'a']) +! :call add(tl, [2, '[a-zA-Z]', 'a', 'a']) +! :call add(tl, [2, '[A-Z]', 'a']) +! :call add(tl, [2, '\C[^A-Z]\+', 'ABCOIJDEOIFNSD jsfoij sa', ' jsfoij sa']) + + :"""" Tests for \z features +! :call add(tl, [2, 'xx \ze test', 'xx ']) " must match after \ze +! :call add(tl, [0, 'abc\zeend', 'oij abcend', 'abc']) +! :call add(tl, [2, 'abc\zsdd', 'ddabcddxyzt', 'dd']) +! :call add(tl, [2, 'aa \zsax', ' ax']) " must match before \zs +! :call add(tl, [0, 'abc \zsmatch\ze abc', 'abc abc abc match abc abc', 'match']) +! :call add(tl, [2, '\v(a \zsif .*){2}', 'a if then a if last', 'if last', 'a if last']) +! :call add(tl, [2, '\>\zs.', 'aword. ', '.']) + + :"""" Tests for \@ features +! :call add(tl, [0, 'abc\@=', 'abc', 'ab']) +! :call add(tl, [0, 'abc\@=cd', 'abcd', 'abcd']) +! :call add(tl, [0, 'abc\@=', 'ababc', 'ab']) +! :call add(tl, [2, 'abcd\@=e', 'abcd']) " will never match, no matter the input text +! :call add(tl, [2, 'abcd\@=e', 'any text in here ... ']) " will never match +! :call add(tl, [0, '\v(abc)@=..', 'xabcd', 'ab', 'abc']) +! :call add(tl, [2, '\(.*John\)\@=.*Bob', 'here is John, and here is B']) " no match +! :call add(tl, [0, '\(John.*\)\@=.*Bob', 'John is Bobs friend', 'John is Bob', 'John is Bobs friend']) +! :call add(tl, [2, '.*John\&.*Bob', 'here is John, and here is B']) " no match +! :call add(tl, [0, '.*John\&.*Bob', 'John is Bobs friend', 'John is Bob']) +! :call add(tl, [0, '\v(test1)@=.*yep', 'this is a test1, yep it is', 'test1, yep', 'test1']) + + :"""" Combining different tests and features +! :call add(tl, [2, '[[:alpha:]]\{-2,6}', '787abcdiuhsasiuhb4', 'ab']) +! :call add(tl, [2, '', 'abcd', '']) +! :call add(tl, [2, '\v(())', 'any possible text', '']) +! :call add(tl, [2, '\v%(ab(xyz)c)', ' abxyzc ', 'abxyzc', 'xyz']) +! :call add(tl, [2, '\v(test|)empty', 'tesempty', 'empty', '']) +! :call add(tl, [2, '\v(a|aa)(a|aa)', 'aaa', 'aa', 'a', 'a']) + + :"""" \%u and friends +! :call add(tl, [2, '\%d32', 'yes no', ' ']) +! :call add(tl, [2, '\%o40', 'yes no', ' ']) +! :call add(tl, [2, '\%x20', 'yes no', ' ']) +! :call add(tl, [2, '\%u0020', 'yes no', ' ']) +! :call add(tl, [2, '\%U00000020', 'yes no', ' ']) + + :"""" Alternatives, must use first longest match +! :call add(tl, [2, 'goo\|go', 'google', 'goo']) +! :call add(tl, [2, '\ matchidx +! : $put ='ERROR: pat: \"' . pat . '\", text: \"' . text . '\", did not match, expected: \"' . t[matchidx] . '\"' +! : elseif len(l) > 0 && len(t) == matchidx +! : $put ='ERROR: pat: \"' . pat . '\", text: \"' . text . '\", match: \"' . l[0] . '\", expected no match' +! : elseif len(t) > matchidx && l[0] != t[matchidx] +! : $put ='ERROR: pat: \"' . pat . '\", text: \"' . text . '\", match: \"' . l[0] . '\", expected: \"' . t[matchidx] . '\"' +! : else +! : $put ='OK ' . engine . ' - ' . pat +! : endif +! : if len(l) > 0 + :" check all the nine submatches +! : for i in range(1, 9) +! : if len(t) <= matchidx + i +! : let e = '' +! : else +! : let e = t[matchidx + i] +! : endif +! : if l[i] != e +! : $put ='ERROR: pat: \"' . pat . '\", text: \"' . text . '\", submatch ' . i . ': \"' . l[i] . '\", expected: \"' . e . '\"' +! : endif +! : endfor +! : unlet i +! : endif +! : endfor + :endfor + :unlet t tl e l + + :" Check that \_[0-9] matching EOL does not break a following \> + :" This only works on a buffer line, not with expression evaluation + /^Find this +! /\%#=0\<\(\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\.\)\{3\}\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\> +! y$Gop:" +! /^Find this +! /\%#=1\<\(\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\.\)\{3\}\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\> +! y$Gop:" +! /^Find this +! /\%#=2\<\(\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\.\)\{3\}\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\> + y$Gop:" + + :/\%#=1^Results/,$wq! test.out +*** ../vim-7.3.1019/src/testdir/test64.ok 2013-05-25 20:19:45.000000000 +0200 +--- src/testdir/test64.ok 2013-05-25 23:12:31.000000000 +0200 +*************** +*** 1,238 **** + Results of test64: +! OK - ab +! OK - b +! OK - bc* +! OK - bc\{-} +! OK - bc\{-}\(d\) +! OK - bc* +! OK - c* +! OK - bc* +! OK - c* +! OK - bc\+ +! OK - bc\+ +! OK - a\|ab +! OK - c\? +! OK - bc\? +! OK - bc\? +! OK - \va{1} +! OK - \va{2} +! OK - \va{2} +! OK - \va{2} +! OK - \va{2} +! OK - \va{2} +! OK - \va{2} +! OK - \vb{1} +! OK - \vba{2} +! OK - \vba{3} +! OK - \v(ab){1} +! OK - \v(ab){1} +! OK - \v(ab){1} +! OK - \v(ab){0,2} +! OK - \v(ab){0,2} +! OK - \v(ab){1,2} +! OK - \v(ab){1,2} +! OK - \v(ab){2,4} +! OK - \v(ab){2,4} +! OK - \v(ab){2} +! OK - \v(ab){2} +! OK - \v(ab){2} +! OK - \v(ab){2} +! OK - \v((ab){2}){2} +! OK - \v((ab){2}){2} +! OK - \v(a{1}){1} +! OK - \v(a{2}){1} +! OK - \v(a{2}){1} +! OK - \v(a{2}){1} +! OK - \v(a{1}){2} +! OK - \v(a{1}){2} +! OK - \v(a{2})+ +! OK - \v(a{2})+ +! OK - \v(a{2}){1} +! OK - \v(a{1}){2} +! OK - \v(a{1}){1} +! OK - \v(a{2}){2} +! OK - \v(a{2}){2} +! OK - \v(a+){2} +! OK - \v(a{3}){2} +! OK - \v(a{1,2}){2} +! OK - \v(a{1,3}){2} +! OK - \v(a{1,3}){2} +! OK - \v(a{1,3}){3} +! OK - \v(a{1,2}){2} +! OK - \v(a+)+ +! OK - \v(a+)+ +! OK - \v(a+){1,2} +! OK - \v(a+)(a+) +! OK - \v(a{3})+ +! OK - \v(a|b|c)+ +! OK - \v(a|b|c){2} +! OK - \v(abc){2} +! OK - \v(abc){2} +! OK - a* +! OK - \v(a*)+ +! OK - \v((ab)+)+ +! OK - \v(((ab)+)+)+ +! OK - \v(((ab)+)+)+ +! OK - \v(a{0,2})+ +! OK - \v(a*)+ +! OK - \v((a*)+)+ +! OK - \v((ab)*)+ +! OK - \va{1,3} +! OK - \va{2,3} +! OK - \v((ab)+|c*)+ +! OK - \v(a{2})|(b{3}) +! OK - \va{2}|b{2} +! OK - \v(a)+|(c)+ +! OK - \vab{2,3}c +! OK - \vab{2,3}c +! OK - \vab{2,3}cd{2,3}e +! OK - \va(bc){2}d +! OK - \va*a{2} +! OK - \va*a{2} +! OK - \va*a{2} +! OK - \va*a{2} +! OK - \va*b*|a*c* +! OK - \va{1}b{1}|a{1}b{1} +! OK - \v(a) +! OK - \v(a)(b) +! OK - \v(ab)(b)(c) +! OK - \v((a)(b)) +! OK - \v(a)|(b) +! OK - \v(a*)+ +! OK - x +! OK - ab +! OK - ab +! OK - ab +! OK - x* +! OK - x* +! OK - x* +! OK - x\+ +! OK - x\+ +! OK - x\+ +! OK - x\+ +! OK - x\= +! OK - x\= +! OK - x\= +! OK - x\? +! OK - x\? +! OK - x\? +! OK - a\{0,0} +! OK - a\{0,1} +! OK - a\{1,0} +! OK - a\{3,6} +! OK - a\{3,6} +! OK - a\{3,6} +! OK - a\{0} +! OK - a\{2} +! OK - a\{2} +! OK - a\{2} +! OK - a\{0,} +! OK - a\{0,} +! OK - a\{2,} +! OK - a\{2,} +! OK - a\{,0} +! OK - a\{,5} +! OK - a\{,5} +! OK - a\{} +! OK - a\{} +! OK - a\{-0,0} +! OK - a\{-0,1} +! OK - a\{-3,6} +! OK - a\{-3,6} +! OK - a\{-3,6} +! OK - a\{-0} +! OK - a\{-2} +! OK - a\{-2} +! OK - a\{-0,} +! OK - a\{-0,} +! OK - a\{-2,} +! OK - a\{-2,} +! OK - a\{-,0} +! OK - a\{-,5} +! OK - a\{-,5} +! OK - a\{-} +! OK - a\{-} +! OK - \(abc\)* +! OK - \(ab\)\+ +! OK - \(abaaaaa\)*cd +! OK - \(test1\)\? \(test2\)\? +! OK - \(test1\)\= \(test2\) \(test4443\)\= +! OK - \(\(sub1\) hello \(sub 2\)\) +! OK - \(\(\(yyxxzz\)\)\) +! OK - \v((ab)+|c+)+ +! OK - \v((ab)|c*)+ +! OK - \v(a(c*)+b)+ +! OK - \v(a|b*)+ +! OK - a\{-2,7} +! OK - a\{2,7} +! OK - \vx(.{-,8})yz(.*) +! OK - \vx(.*)yz(.*) +! OK - \v(a{1,2}){-2,3} +! OK - \v(a{-1,3})+ +! OK - \d\+e\d\d +! OK - \v[a] +! OK - a[bcd] +! OK - a[b-d] +! OK - [a-d][e-f][x-x]d +! OK - \v[[:alpha:]]+ +! OK - [[:alpha:]\+] +! OK - [^abc]\+ +! OK - [^abc] +! OK - [^abc]\+ +! OK - [^a-d]\+ +! OK - [a-f]* +! OK - [a-f]* +! OK - [^a-f]\+ +! OK - [a-c]\{-3,6} +! OK - [^[:alpha:]]\+ +! OK - [-a] +! OK - [a-] +! OK - [-./[:alnum:]_~]\+ +! OK - [\]\^\-\\]\+ +! OK - [[.a.]]\+ +! OK - abc[0-9]*ddd +! OK - abc[0-9]*ddd +! OK - \_[0-9]\+ +! OK - [0-9\n]\+ +! OK - [0-9] +! OK - [^0-9] +! OK - [0-9a-fA-F]* +! OK - [^0-9A-Fa-f]\+ +! OK - [a-z_A-Z0-9]\+ +! OK - [a-z] +! OK - [a-zA-Z] +! OK - [A-Z] +! OK - \C[^A-Z]\+ +! OK - xx \ze test +! OK - abc\zeend +! OK - abc\zsdd +! OK - aa \zsax +! OK - abc \zsmatch\ze abc +! OK - \v(a \zsif .*){2} +! OK - \>\zs. +! OK - abc\@= +! OK - abc\@=cd +! OK - abc\@= +! OK - abcd\@=e +! OK - abcd\@=e +! OK - \v(abc)@=.. +! OK - \(.*John\)\@=.*Bob +! OK - \(John.*\)\@=.*Bob +! OK - .*John\&.*Bob +! OK - .*John\&.*Bob +! OK - \v(test1)@=.*yep +! OK - [[:alpha:]]\{-2,6} +! OK - +! OK - \v(()) +! OK - \v%(ab(xyz)c) +! OK - \v(test|)empty +! OK - \v(a|aa)(a|aa) +! OK - \%d32 +! OK - \%o40 +! OK - \%x20 +! OK - \%u0020 +! OK - \%U00000020 +! OK - goo\|go +! OK - \\zs. +! OK 1 - \>\zs. +! OK 2 - \>\zs. +! OK 0 - abc\@= +! OK 1 - abc\@= +! OK 0 - abc\@=cd +! OK 1 - abc\@=cd +! OK 0 - abc\@= +! OK 1 - abc\@= +! OK 0 - abcd\@=e +! OK 1 - abcd\@=e +! OK 2 - abcd\@=e +! OK 0 - abcd\@=e +! OK 1 - abcd\@=e +! OK 2 - abcd\@=e +! OK 0 - \v(abc)@=.. +! OK 1 - \v(abc)@=.. +! OK 0 - \(.*John\)\@=.*Bob +! OK 1 - \(.*John\)\@=.*Bob +! OK 2 - \(.*John\)\@=.*Bob +! OK 0 - \(John.*\)\@=.*Bob +! OK 1 - \(John.*\)\@=.*Bob +! OK 0 - .*John\&.*Bob +! OK 1 - .*John\&.*Bob +! OK 2 - .*John\&.*Bob +! OK 0 - .*John\&.*Bob +! OK 1 - .*John\&.*Bob +! OK 0 - \v(test1)@=.*yep +! OK 1 - \v(test1)@=.*yep +! OK 0 - [[:alpha:]]\{-2,6} +! OK 1 - [[:alpha:]]\{-2,6} +! OK 2 - [[:alpha:]]\{-2,6} +! OK 0 - +! OK 1 - +! OK 2 - +! OK 0 - \v(()) +! OK 1 - \v(()) +! OK 2 - \v(()) +! OK 0 - \v%(ab(xyz)c) +! OK 1 - \v%(ab(xyz)c) +! OK 2 - \v%(ab(xyz)c) +! OK 0 - \v(test|)empty +! OK 1 - \v(test|)empty +! OK 2 - \v(test|)empty +! OK 0 - \v(a|aa)(a|aa) +! OK 1 - \v(a|aa)(a|aa) +! OK 2 - \v(a|aa)(a|aa) +! OK 0 - \%d32 +! OK 1 - \%d32 +! OK 2 - \%d32 +! OK 0 - \%o40 +! OK 1 - \%o40 +! OK 2 - \%o40 +! OK 0 - \%x20 +! OK 1 - \%x20 +! OK 2 - \%x20 +! OK 0 - \%u0020 +! OK 1 - \%u0020 +! OK 2 - \%u0020 +! OK 0 - \%U00000020 +! OK 1 - \%U00000020 +! OK 2 - \%U00000020 +! OK 0 - goo\|go +! OK 1 - goo\|go +! OK 2 - goo\|go +! OK 0 - \ 2 +! : $put ='ERROR: pat: \"' . t[0] . '\", text: \"' . t[1] . '\", did not match, expected: \"' . t[2] . '\"' +! : elseif len(l) > 0 && len(t) == 2 +! : $put ='ERROR: pat: \"' . t[0] . '\", text: \"' . t[1] . '\", match: \"' . l[0] . '\", expected no match' +! : elseif len(t) > 2 && l[0] != t[2] +! : $put ='ERROR: pat: \"' . t[0] . '\", text: \"' . t[1] . '\", match: \"' . l[0] . '\", expected: \"' . t[2] . '\"' +! : else +! : $put ='OK - ' . t[0] +! : endif +! : if len(l) > 0 + :" check all the nine submatches +! : for i in range(1, 9) +! : if len(t) <= i + 2 +! : let e = '' +! : else +! : let e = t[i + 2] +! : endif +! : if l[i] != e +! : $put ='ERROR: pat: \"' . t[0] . '\", text: \"' . t[1] . '\", submatch ' . i . ': \"' . l[i] . '\", expected: \"' . e . '\"' +! : endif +! : endfor +! : unlet i +! : endif + :endfor + :unlet t tl e l + +--- 20,109 ---- + + :"""" Multi-byte character tests. These will fail unless vim is compiled + :"""" with Multibyte (FEAT_MBYTE) or BIG/HUGE features. +! :call add(tl, [2, '[[:alpha:][=a=]]\+', '879 aiaãâaiuvna ', 'aiaãâaiuvna']) +! :call add(tl, [2, '[[=a=]]\+', 'ddaãâbcd', 'aãâ']) " equivalence classes +! :call add(tl, [2, '[^ม ]\+', 'มม oijasoifjos ifjoisj f osij j มมมมม abcd', 'oijasoifjos']) +! :call add(tl, [2, ' [^ ]\+', 'start มabcdม ', ' มabcdม']) +! :call add(tl, [2, '[ม[:alpha:][=a=]]\+', '879 aiaãมâมaiuvna ', 'aiaãมâมaiuvna']) + + :" this is not a normal "i" but 0xec +! :call add(tl, [2, '\p\+', 'ìa', 'ìa']) + + :"""" Test recognition of some character classes +! :call add(tl, [2, '\i\+', '&*¨xx ', 'xx']) +! :call add(tl, [2, '\f\+', '&*Ÿfname ', 'fname']) + + :"""" Test composing character matching +! :call add(tl, [2, '.ม', 'xม่x yมy', 'yม']) +! :call add(tl, [2, '.ม่', 'xม่x yมy', 'xม่']) +! :call add(tl, [2, "\u05b9", " x\u05b9 ", "x\u05b9"]) +! :call add(tl, [2, ".\u05b9", " x\u05b9 ", "x\u05b9"]) +! :call add(tl, [2, "\u05b9\u05bb", " x\u05b9\u05bb ", "x\u05b9\u05bb"]) +! :call add(tl, [2, ".\u05b9\u05bb", " x\u05b9\u05bb ", "x\u05b9\u05bb"]) +! :"call add(tl, [2, "\u05bb\u05b9", " x\u05b9\u05bb "]) +! :"call add(tl, [2, ".\u05bb\u05b9", " x\u05b9\u05bb "]) +! :call add(tl, [2, "\u05b9", " y\u05bb x\u05b9 ", "x\u05b9"]) +! :call add(tl, [2, ".\u05b9", " y\u05bb x\u05b9 ", "x\u05b9"]) + + + :"""" Test \Z +! :call add(tl, [2, 'ú\Z', 'x']) +! :call add(tl, [2, 'יהוה\Z', 'יהוה', 'יהוה']) +! :call add(tl, [2, 'יְהוָה\Z', 'יהוה', 'יהוה']) +! :call add(tl, [2, 'יהוה\Z', 'יְהוָה', 'יְהוָה']) +! :call add(tl, [2, 'יְהוָה\Z', 'יְהוָה', 'יְהוָה']) +! :call add(tl, [2, '×™Ö°\Z', 'וְיַ', '×™Ö·']) +! :call add(tl, [2, "×§\u200d\u05b9x\\Z", "x×§\u200d\u05b9xy", "×§\u200d\u05b9x"]) +! :call add(tl, [2, "×§\u200d\u05b9x\\Z", "x×§\u200dxy", "×§\u200dx"]) +! :call add(tl, [2, "×§\u200dx\\Z", "x×§\u200d\u05b9xy", "×§\u200d\u05b9x"]) +! :call add(tl, [2, "×§\u200dx\\Z", "x×§\u200dxy", "×§\u200dx"]) +! :"call add(tl, [2, "\u05b9\\Z", "xyz"]) +! :"call add(tl, [2, "\\Z\u05b9", "xyz"]) +! :"call add(tl, [2, "\u05b9\\+\\Z", "xyz", "xyz"]) +! :"call add(tl, [2, "\\Z\u05b9\\+", "xyz", "xyz"]) + + :"""" Combining different tests and features +! :call add(tl, [2, '[^[=a=]]\+', 'ddaãâbcd', 'dd']) + + :"""" Run the tests ++ + :" + :for t in tl +! : let re = t[0] +! : let pat = t[1] +! : let text = t[2] +! : let matchidx = 3 +! : for engine in [0, 1, 2] +! : if engine == 2 && !re +! : continue +! : endif +! : let ®expengine = engine +! : let l = matchlist(text, pat) + :" check the match itself +! : if len(l) == 0 && len(t) > matchidx +! : $put ='ERROR: pat: \"' . pat . '\", text: \"' . text . '\", did not match, expected: \"' . t[matchidx] . '\"' +! : elseif len(l) > 0 && len(t) == matchidx +! : $put ='ERROR: pat: \"' . pat . '\", text: \"' . text . '\", match: \"' . l[0] . '\", expected no match' +! : elseif len(t) > matchidx && l[0] != t[matchidx] +! : $put ='ERROR: pat: \"' . pat . '\", text: \"' . text . '\", match: \"' . l[0] . '\", expected: \"' . t[matchidx] . '\"' +! : else +! : $put ='OK ' . engine . ' - ' . pat +! : endif +! : if len(l) > 0 + :" check all the nine submatches +! : for i in range(1, 9) +! : if len(t) <= matchidx + i +! : let e = '' +! : else +! : let e = t[matchidx + i] +! : endif +! : if l[i] != e +! : $put ='ERROR: pat: \"' . pat . '\", text: \"' . text . '\", submatch ' . i . ': \"' . l[i] . '\", expected: \"' . e . '\"' +! : endif +! : endfor +! : unlet i +! : endif +! : endfor + :endfor + :unlet t tl e l + +*** ../vim-7.3.1019/src/testdir/test95.ok 2013-05-25 14:41:58.000000000 +0200 +--- src/testdir/test95.ok 2013-05-25 23:06:26.000000000 +0200 +*************** +*** 1,34 **** + Results of test95: +! OK - [[:alpha:][=a=]]\+ +! OK - [[=a=]]\+ +! OK - [^ม ]\+ +! OK - [^ ]\+ +! OK - [ม[:alpha:][=a=]]\+ +! OK - \p\+ +! OK - \i\+ +! OK - \%#=1\i\+ +! OK - \f\+ +! OK - \%#=1\f\+ +! OK - .ม +! OK - .ม่ +! OK - Ö¹ +! OK - .Ö¹ +! OK - Ö¹Ö» +! OK - .Ö¹Ö» +! OK - Ö»Ö¹ +! OK - .Ö»Ö¹ +! OK - Ö¹ +! OK - .Ö¹ +! OK - ú\Z +! OK - יהוה\Z +! OK - יְהוָה\Z +! OK - יהוה\Z +! OK - יְהוָה\Z +! OK - ×™Ö°\Z +! OK - ×§â€Ö¹x\Z +! OK - ×§â€Ö¹x\Z +! OK - ×§â€x\Z +! OK - ×§â€x\Z +! OK - Ö¹\+\Z +! OK - \ZÖ¹\+ +! OK - [^[=a=]]\+ +--- 1,82 ---- + Results of test95: +! OK 0 - [[:alpha:][=a=]]\+ +! OK 1 - [[:alpha:][=a=]]\+ +! OK 2 - [[:alpha:][=a=]]\+ +! OK 0 - [[=a=]]\+ +! OK 1 - [[=a=]]\+ +! OK 2 - [[=a=]]\+ +! OK 0 - [^ม ]\+ +! OK 1 - [^ม ]\+ +! OK 2 - [^ม ]\+ +! OK 0 - [^ ]\+ +! OK 1 - [^ ]\+ +! OK 2 - [^ ]\+ +! OK 0 - [ม[:alpha:][=a=]]\+ +! OK 1 - [ม[:alpha:][=a=]]\+ +! OK 2 - [ม[:alpha:][=a=]]\+ +! OK 0 - \p\+ +! OK 1 - \p\+ +! OK 2 - \p\+ +! OK 0 - \i\+ +! OK 1 - \i\+ +! OK 2 - \i\+ +! OK 0 - \f\+ +! OK 1 - \f\+ +! OK 2 - \f\+ +! OK 0 - .ม +! OK 1 - .ม +! OK 2 - .ม +! OK 0 - .ม่ +! OK 1 - .ม่ +! OK 2 - .ม่ +! OK 0 - Ö¹ +! OK 1 - Ö¹ +! OK 2 - Ö¹ +! OK 0 - .Ö¹ +! OK 1 - .Ö¹ +! OK 2 - .Ö¹ +! OK 0 - Ö¹Ö» +! OK 1 - Ö¹Ö» +! OK 2 - Ö¹Ö» +! OK 0 - .Ö¹Ö» +! OK 1 - .Ö¹Ö» +! OK 2 - .Ö¹Ö» +! OK 0 - Ö¹ +! OK 1 - Ö¹ +! OK 2 - Ö¹ +! OK 0 - .Ö¹ +! OK 1 - .Ö¹ +! OK 2 - .Ö¹ +! OK 0 - ú\Z +! OK 1 - ú\Z +! OK 2 - ú\Z +! OK 0 - יהוה\Z +! OK 1 - יהוה\Z +! OK 2 - יהוה\Z +! OK 0 - יְהוָה\Z +! OK 1 - יְהוָה\Z +! OK 2 - יְהוָה\Z +! OK 0 - יהוה\Z +! OK 1 - יהוה\Z +! OK 2 - יהוה\Z +! OK 0 - יְהוָה\Z +! OK 1 - יְהוָה\Z +! OK 2 - יְהוָה\Z +! OK 0 - ×™Ö°\Z +! OK 1 - ×™Ö°\Z +! OK 2 - ×™Ö°\Z +! OK 0 - ×§â€Ö¹x\Z +! OK 1 - ×§â€Ö¹x\Z +! OK 2 - ×§â€Ö¹x\Z +! OK 0 - ×§â€Ö¹x\Z +! OK 1 - ×§â€Ö¹x\Z +! OK 2 - ×§â€Ö¹x\Z +! OK 0 - ×§â€x\Z +! OK 1 - ×§â€x\Z +! OK 2 - ×§â€x\Z +! OK 0 - ×§â€x\Z +! OK 1 - ×§â€x\Z +! OK 2 - ×§â€x\Z +! OK 0 - [^[=a=]]\+ +! OK 1 - [^[=a=]]\+ +! OK 2 - [^[=a=]]\+ +*** ../vim-7.3.1019/src/version.c 2013-05-25 22:04:19.000000000 +0200 +--- src/version.c 2013-05-25 23:10:16.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1020, + /**/ + +-- +Engineers will go without food and hygiene for days to solve a problem. +(Other times just because they forgot.) + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1e6789796b577ecc0c8cfd14e17546586b6cc94b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:03 +0200 Subject: [PATCH 0912/3340] - patchlevel 1021 --- 7.3.1021 | 229 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 229 insertions(+) create mode 100644 7.3.1021 diff --git a/7.3.1021 b/7.3.1021 new file mode 100644 index 00000000..6d268073 --- /dev/null +++ b/7.3.1021 @@ -0,0 +1,229 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1021 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1021 +Problem: New regexp engine does not ignore order of composing chars. +Solution: Ignore composing chars order. +Files: src/regexp_nfa.c, src/testdir/test95.in, src/testdir/test95.ok + + +*** ../vim-7.3.1020/src/regexp_nfa.c 2013-05-25 22:04:19.000000000 +0200 +--- src/regexp_nfa.c 2013-05-26 14:27:11.000000000 +0200 +*************** +*** 3275,3282 **** + int len = 0; + nfa_state_T *end; + nfa_state_T *sta; + +- result = OK; + sta = t->state->out; + len = 0; + if (utf_iscomposing(sta->c)) +--- 3275,3284 ---- + int len = 0; + nfa_state_T *end; + nfa_state_T *sta; ++ int cchars[MAX_MCO]; ++ int ccount = 0; ++ int j; + + sta = t->state->out; + len = 0; + if (utf_iscomposing(sta->c)) +*************** +*** 3293,3316 **** + /* TODO: How about negated? */ + if (len == 0 && sta->c != c) + result = FAIL; +! len = n; + while (sta->c != NFA_END_COMPOSING) + sta = sta->out; + } +! else +! while (sta->c != NFA_END_COMPOSING && len < n) + { +- if (len > 0) +- mc = mb_ptr2char(reginput + len); +- if (mc != sta->c) +- break; + len += mb_char2len(mc); + sta = sta->out; + } + +! /* if input char length doesn't match regexp char length */ +! if (len < n || sta->c != NFA_END_COMPOSING) + result = FAIL; + end = t->state->out1; /* NFA_END_COMPOSING */ + ADD_POS_NEG_STATE(end); + break; +--- 3295,3346 ---- + /* TODO: How about negated? */ + if (len == 0 && sta->c != c) + result = FAIL; +! else +! result = OK; + while (sta->c != NFA_END_COMPOSING) + sta = sta->out; + } +! +! /* Check base character matches first, unless ignored. */ +! else if (len > 0 || mc == sta->c) +! { +! if (len == 0) + { + len += mb_char2len(mc); + sta = sta->out; + } + +! /* We don't care about the order of composing characters. +! * Get them into cchars[] first. */ +! while (len < n) +! { +! mc = mb_ptr2char(reginput + len); +! cchars[ccount++] = mc; +! len += mb_char2len(mc); +! if (ccount == MAX_MCO) +! break; +! } +! +! /* Check that each composing char in the pattern matches a +! * composing char in the text. We do not check if all +! * composing chars are matched. */ +! result = OK; +! while (sta->c != NFA_END_COMPOSING) +! { +! for (j = 0; j < ccount; ++j) +! if (cchars[j] == sta->c) +! break; +! if (j == ccount) +! { +! result = FAIL; +! break; +! } +! sta = sta->out; +! } +! } +! else + result = FAIL; ++ + end = t->state->out1; /* NFA_END_COMPOSING */ + ADD_POS_NEG_STATE(end); + break; +*** ../vim-7.3.1020/src/testdir/test95.in 2013-05-25 23:15:21.000000000 +0200 +--- src/testdir/test95.in 2013-05-26 14:12:13.000000000 +0200 +*************** +*** 9,14 **** +--- 9,15 ---- + :so mbyte.vim + :set nocp encoding=utf-8 viminfo+=nviminfo nomore + :" tl is a List of Lists with: ++ :" 2: test auto/old/new 0: test auto/old 1: test auto/new + :" regexp pattern + :" text to test the pattern on + :" expected match (optional) +*************** +*** 40,49 **** + :call add(tl, [2, ".\u05b9", " x\u05b9 ", "x\u05b9"]) + :call add(tl, [2, "\u05b9\u05bb", " x\u05b9\u05bb ", "x\u05b9\u05bb"]) + :call add(tl, [2, ".\u05b9\u05bb", " x\u05b9\u05bb ", "x\u05b9\u05bb"]) +! :"call add(tl, [2, "\u05bb\u05b9", " x\u05b9\u05bb "]) +! :"call add(tl, [2, ".\u05bb\u05b9", " x\u05b9\u05bb "]) + :call add(tl, [2, "\u05b9", " y\u05bb x\u05b9 ", "x\u05b9"]) + :call add(tl, [2, ".\u05b9", " y\u05bb x\u05b9 ", "x\u05b9"]) + + + :"""" Test \Z +--- 41,54 ---- + :call add(tl, [2, ".\u05b9", " x\u05b9 ", "x\u05b9"]) + :call add(tl, [2, "\u05b9\u05bb", " x\u05b9\u05bb ", "x\u05b9\u05bb"]) + :call add(tl, [2, ".\u05b9\u05bb", " x\u05b9\u05bb ", "x\u05b9\u05bb"]) +! :call add(tl, [2, "\u05bb\u05b9", " x\u05b9\u05bb ", "x\u05b9\u05bb"]) +! :call add(tl, [2, ".\u05bb\u05b9", " x\u05b9\u05bb ", "x\u05b9\u05bb"]) + :call add(tl, [2, "\u05b9", " y\u05bb x\u05b9 ", "x\u05b9"]) + :call add(tl, [2, ".\u05b9", " y\u05bb x\u05b9 ", "x\u05b9"]) ++ :call add(tl, [2, "\u05b9", " y\u05bb\u05b9 x\u05b9 ", "y\u05bb\u05b9"]) ++ :call add(tl, [2, ".\u05b9", " y\u05bb\u05b9 x\u05b9 ", "y\u05bb\u05b9"]) ++ :call add(tl, [1, "\u05b9\u05bb", " y\u05b9 x\u05b9\u05bb ", "x\u05b9\u05bb"]) ++ :call add(tl, [2, ".\u05b9\u05bb", " y\u05bb x\u05b9\u05bb ", "x\u05b9\u05bb"]) + + + :"""" Test \Z +*************** +*** 74,80 **** + : let text = t[2] + : let matchidx = 3 + : for engine in [0, 1, 2] +! : if engine == 2 && !re + : continue + : endif + : let ®expengine = engine +--- 79,85 ---- + : let text = t[2] + : let matchidx = 3 + : for engine in [0, 1, 2] +! : if engine == 2 && re == 0 || engine == 1 && re == 1 + : continue + : endif + : let ®expengine = engine +*** ../vim-7.3.1020/src/testdir/test95.ok 2013-05-25 23:15:21.000000000 +0200 +--- src/testdir/test95.ok 2013-05-26 14:12:36.000000000 +0200 +*************** +*** 41,52 **** +--- 41,69 ---- + OK 0 - .Ö¹Ö» + OK 1 - .Ö¹Ö» + OK 2 - .Ö¹Ö» ++ OK 0 - Ö»Ö¹ ++ OK 1 - Ö»Ö¹ ++ OK 2 - Ö»Ö¹ ++ OK 0 - .Ö»Ö¹ ++ OK 1 - .Ö»Ö¹ ++ OK 2 - .Ö»Ö¹ + OK 0 - Ö¹ + OK 1 - Ö¹ + OK 2 - Ö¹ + OK 0 - .Ö¹ + OK 1 - .Ö¹ + OK 2 - .Ö¹ ++ OK 0 - Ö¹ ++ OK 1 - Ö¹ ++ OK 2 - Ö¹ ++ OK 0 - .Ö¹ ++ OK 1 - .Ö¹ ++ OK 2 - .Ö¹ ++ OK 0 - Ö¹Ö» ++ OK 2 - Ö¹Ö» ++ OK 0 - .Ö¹Ö» ++ OK 1 - .Ö¹Ö» ++ OK 2 - .Ö¹Ö» + OK 0 - ú\Z + OK 1 - ú\Z + OK 2 - ú\Z +*** ../vim-7.3.1020/src/version.c 2013-05-25 23:15:21.000000000 +0200 +--- src/version.c 2013-05-26 13:54:16.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1021, + /**/ + +-- +Engineers are always delighted to share wisdom, even in areas in which they +have no experience whatsoever. Their logic provides them with inherent +insight into any field of expertise. This can be a problem when dealing with +the illogical people who believe that knowledge can only be derived through +experience. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9be36a83ed907fbb17e572ce8299f24ac3edd24f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:03 +0200 Subject: [PATCH 0913/3340] - patchlevel 1022 --- 7.3.1022 | 873 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 873 insertions(+) create mode 100644 7.3.1022 diff --git a/7.3.1022 b/7.3.1022 new file mode 100644 index 00000000..557f0bb3 --- /dev/null +++ b/7.3.1022 @@ -0,0 +1,873 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1022 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1022 +Problem: Compiler warning for shadowed variable. (John Little) +Solution: Move declaration, rename variables. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1021/src/regexp_nfa.c 2013-05-26 14:32:01.000000000 +0200 +--- src/regexp_nfa.c 2013-05-26 14:50:27.000000000 +0200 +*************** +*** 604,610 **** + char_u *endp; + #ifdef FEAT_MBYTE + char_u *old_regparse = regparse; +- int i; + #endif + int extra = 0; + int first; +--- 604,609 ---- +*************** +*** 827,850 **** + case 'u': /* %uabcd hex 4 */ + case 'U': /* %U1234abcd hex 8 */ + { +! int i; + + switch (c) + { +! case 'd': i = getdecchrs(); break; +! case 'o': i = getoctchrs(); break; +! case 'x': i = gethexchrs(2); break; +! case 'u': i = gethexchrs(4); break; +! case 'U': i = gethexchrs(8); break; +! default: i = -1; break; + } + +! if (i < 0) + EMSG2_RET_FAIL( + _("E678: Invalid character after %s%%[dxouU]"), + reg_magic == MAGIC_ALL); + /* TODO: what if a composing character follows? */ +! EMIT(i); + } + break; + +--- 826,849 ---- + case 'u': /* %uabcd hex 4 */ + case 'U': /* %U1234abcd hex 8 */ + { +! int nr; + + switch (c) + { +! case 'd': nr = getdecchrs(); break; +! case 'o': nr = getoctchrs(); break; +! case 'x': nr = gethexchrs(2); break; +! case 'u': nr = gethexchrs(4); break; +! case 'U': nr = gethexchrs(8); break; +! default: nr = -1; break; + } + +! if (nr < 0) + EMSG2_RET_FAIL( + _("E678: Invalid character after %s%%[dxouU]"), + reg_magic == MAGIC_ALL); + /* TODO: what if a composing character follows? */ +! EMIT(nr); + } + break; + +*************** +*** 1229,1234 **** +--- 1228,1235 ---- + != (plen = (*mb_ptr2len)(old_regparse)) + || utf_iscomposing(c))) + { ++ int i = 0; ++ + /* A base character plus composing characters, or just one + * or more composing characters. + * This requires creating a separate atom as if enclosing +*************** +*** 1237,1243 **** + * building the postfix form, not the NFA itself; + * a composing char could be: a, b, c, NFA_COMPOSING + * where 'b' and 'c' are chars with codes > 256. */ +- i = 0; + for (;;) + { + EMIT(c); +--- 1238,1243 ---- +*************** +*** 2923,2931 **** + regsub_T *submatch; + regsub_T *m; + { +- int c; +- int n; +- int i = 0; + int result; + int size = 0; + int match = FALSE; +--- 2923,2928 ---- +*************** +*** 2939,2944 **** +--- 2936,2942 ---- + nfa_list_T *listtbl[2][2]; + nfa_list_T *ll; + int listid = 1; ++ int listidx; + nfa_list_T *thislist; + nfa_list_T *nextlist; + nfa_list_T *neglist; +*************** +*** 3004,3010 **** + #define ADD_POS_NEG_STATE(node) \ + ll = listtbl[result ? 1 : 0][node->negated]; \ + if (ll != NULL) \ +! addstate(ll, node->out , &t->sub, n, listid + 1, &match); + + + /* +--- 3002,3008 ---- + #define ADD_POS_NEG_STATE(node) \ + ll = listtbl[result ? 1 : 0][node->negated]; \ + if (ll != NULL) \ +! addstate(ll, node->out , &t->sub, clen, listid + 1, &match); + + + /* +*************** +*** 3012,3032 **** + */ + for (;;) + { + #ifdef FEAT_MBYTE + if (has_mbyte) + { +! c = (*mb_ptr2char)(reginput); +! n = (*mb_ptr2len)(reginput); + } + else + #endif + { +! c = *reginput; +! n = 1; + } +! if (c == NUL) + { +! n = 0; + go_to_nextline = FALSE; + } + +--- 3010,3033 ---- + */ + for (;;) + { ++ int curc; ++ int clen; ++ + #ifdef FEAT_MBYTE + if (has_mbyte) + { +! curc = (*mb_ptr2char)(reginput); +! clen = (*mb_ptr2len)(reginput); + } + else + #endif + { +! curc = *reginput; +! clen = 1; + } +! if (curc == NUL) + { +! clen = 0; + go_to_nextline = FALSE; + } + +*************** +*** 3040,3049 **** + #ifdef ENABLE_LOG + fprintf(log_fd, "------------------------------------------\n"); + fprintf(log_fd, ">>> Reginput is \"%s\"\n", reginput); +! fprintf(log_fd, ">>> Advanced one character ... Current char is %c (code %d) \n", c, (int)c); + fprintf(log_fd, ">>> Thislist has %d states available: ", thislist->n); +! for (i = 0; i < thislist->n; i++) +! fprintf(log_fd, "%d ", abs(thislist->t[i].state->id)); + fprintf(log_fd, "\n"); + #endif + +--- 3041,3054 ---- + #ifdef ENABLE_LOG + fprintf(log_fd, "------------------------------------------\n"); + fprintf(log_fd, ">>> Reginput is \"%s\"\n", reginput); +! fprintf(log_fd, ">>> Advanced one character ... Current char is %c (code %d) \n", curc, (int)curc); + fprintf(log_fd, ">>> Thislist has %d states available: ", thislist->n); +! { +! int i; +! +! for (i = 0; i < thislist->n; i++) +! fprintf(log_fd, "%d ", abs(thislist->t[i].state->id)); +! } + fprintf(log_fd, "\n"); + #endif + +*************** +*** 3057,3072 **** + break; + + /* compute nextlist */ +! for (i = 0; i < thislist->n || neglist->n > 0; ++i) + { + if (neglist->n > 0) + { + t = &neglist->t[0]; + neglist->n--; +! i--; + } + else +! t = &thislist->t[i]; + + #ifdef NFA_REGEXP_DEBUG_LOG + nfa_set_code(t->state->c); +--- 3062,3077 ---- + break; + + /* compute nextlist */ +! for (listidx = 0; listidx < thislist->n || neglist->n > 0; ++listidx) + { + if (neglist->n > 0) + { + t = &neglist->t[0]; + neglist->n--; +! listidx--; + } + else +! t = &thislist->t[listidx]; + + #ifdef NFA_REGEXP_DEBUG_LOG + nfa_set_code(t->state->c); +*************** +*** 3116,3122 **** + * the parent call. */ + if (start->c == NFA_MOPEN + 0) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &i); + else + { + *m = t->sub; +--- 3121,3127 ---- + * the parent call. */ + if (start->c == NFA_MOPEN + 0) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &listidx); + else + { + *m = t->sub; +*************** +*** 3190,3196 **** + } + /* t->state->out1 is the corresponding END_INVISIBLE node */ + addstate_here(thislist, t->state->out1->out, &t->sub, +! listid, &match, &i); + } + else + { +--- 3195,3201 ---- + } + /* t->state->out1 is the corresponding END_INVISIBLE node */ + addstate_here(thislist, t->state->out1->out, &t->sub, +! listid, &match, &listidx); + } + else + { +*************** +*** 3202,3221 **** + case NFA_BOL: + if (reginput == regline) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &i); + break; + + case NFA_EOL: +! if (c == NUL) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &i); + break; + + case NFA_BOW: + { + int bow = TRUE; + +! if (c == NUL) + bow = FALSE; + #ifdef FEAT_MBYTE + else if (has_mbyte) +--- 3207,3226 ---- + case NFA_BOL: + if (reginput == regline) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &listidx); + break; + + case NFA_EOL: +! if (curc == NUL) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &listidx); + break; + + case NFA_BOW: + { + int bow = TRUE; + +! if (curc == NUL) + bow = FALSE; + #ifdef FEAT_MBYTE + else if (has_mbyte) +*************** +*** 3230,3242 **** + bow = FALSE; + } + #endif +! else if (!vim_iswordc_buf(c, reg_buf) + || (reginput > regline + && vim_iswordc_buf(reginput[-1], reg_buf))) + bow = FALSE; + if (bow) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &i); + break; + } + +--- 3235,3247 ---- + bow = FALSE; + } + #endif +! else if (!vim_iswordc_buf(curc, reg_buf) + || (reginput > regline + && vim_iswordc_buf(reginput[-1], reg_buf))) + bow = FALSE; + if (bow) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &listidx); + break; + } + +*************** +*** 3260,3277 **** + } + #endif + else if (!vim_iswordc_buf(reginput[-1], reg_buf) +! || (reginput[0] != NUL && vim_iswordc_buf(c, reg_buf))) + eow = FALSE; + if (eow) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &i); + break; + } + + #ifdef FEAT_MBYTE + case NFA_COMPOSING: + { +! int mc = c; + int len = 0; + nfa_state_T *end; + nfa_state_T *sta; +--- 3265,3283 ---- + } + #endif + else if (!vim_iswordc_buf(reginput[-1], reg_buf) +! || (reginput[0] != NUL +! && vim_iswordc_buf(curc, reg_buf))) + eow = FALSE; + if (eow) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &listidx); + break; + } + + #ifdef FEAT_MBYTE + case NFA_COMPOSING: + { +! int mc = curc; + int len = 0; + nfa_state_T *end; + nfa_state_T *sta; +*************** +*** 3286,3299 **** + /* Only match composing character(s), ignore base + * character. Used for ".{composing}" and "{composing}" + * (no preceding character). */ +! len += mb_char2len(c); + } + if (ireg_icombine) + { + /* If \Z was present, then ignore composing characters. + * When ignoring the base character this always matches. */ + /* TODO: How about negated? */ +! if (len == 0 && sta->c != c) + result = FAIL; + else + result = OK; +--- 3292,3305 ---- + /* Only match composing character(s), ignore base + * character. Used for ".{composing}" and "{composing}" + * (no preceding character). */ +! len += mb_char2len(mc); + } + if (ireg_icombine) + { + /* If \Z was present, then ignore composing characters. + * When ignoring the base character this always matches. */ + /* TODO: How about negated? */ +! if (len == 0 && sta->c != curc) + result = FAIL; + else + result = OK; +*************** +*** 3312,3318 **** + + /* We don't care about the order of composing characters. + * Get them into cchars[] first. */ +! while (len < n) + { + mc = mb_ptr2char(reginput + len); + cchars[ccount++] = mc; +--- 3318,3324 ---- + + /* We don't care about the order of composing characters. + * Get them into cchars[] first. */ +! while (len < clen) + { + mc = mb_ptr2char(reginput + len); + cchars[ccount++] = mc; +*************** +*** 3349,3355 **** + + case NFA_NEWL: + if (!reg_line_lbr && REG_MULTI +! && c == NUL && reglnum <= reg_maxline) + { + go_to_nextline = TRUE; + /* Pass -1 for the offset, which means taking the position +--- 3355,3361 ---- + + case NFA_NEWL: + if (!reg_line_lbr && REG_MULTI +! && curc == NUL && reglnum <= reg_maxline) + { + go_to_nextline = TRUE; + /* Pass -1 for the offset, which means taking the position +*************** +*** 3375,3409 **** + case NFA_CLASS_RETURN: + case NFA_CLASS_BACKSPACE: + case NFA_CLASS_ESCAPE: +! result = check_char_class(t->state->c, c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_END_NEG_RANGE: + /* This follows a series of negated nodes, like: + * CHAR(x), NFA_NOT, CHAR(y), NFA_NOT etc. */ +! if (c > 0) +! addstate(nextlist, t->state->out, &t->sub, n, listid + 1, +! &match); + break; + + case NFA_ANY: + /* Any char except '\0', (end of input) does not match. */ +! if (c > 0) +! addstate(nextlist, t->state->out, &t->sub, n, listid + 1, +! &match); + break; + + /* + * Character classes like \a for alpha, \d for digit etc. + */ + case NFA_IDENT: /* \i */ +! result = vim_isIDc(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_SIDENT: /* \I */ +! result = !VIM_ISDIGIT(c) && vim_isIDc(c); + ADD_POS_NEG_STATE(t->state); + break; + +--- 3381,3415 ---- + case NFA_CLASS_RETURN: + case NFA_CLASS_BACKSPACE: + case NFA_CLASS_ESCAPE: +! result = check_char_class(t->state->c, curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_END_NEG_RANGE: + /* This follows a series of negated nodes, like: + * CHAR(x), NFA_NOT, CHAR(y), NFA_NOT etc. */ +! if (curc > 0) +! addstate(nextlist, t->state->out, &t->sub, clen, +! listid + 1, &match); + break; + + case NFA_ANY: + /* Any char except '\0', (end of input) does not match. */ +! if (curc > 0) +! addstate(nextlist, t->state->out, &t->sub, clen, +! listid + 1, &match); + break; + + /* + * Character classes like \a for alpha, \d for digit etc. + */ + case NFA_IDENT: /* \i */ +! result = vim_isIDc(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_SIDENT: /* \I */ +! result = !VIM_ISDIGIT(curc) && vim_isIDc(curc); + ADD_POS_NEG_STATE(t->state); + break; + +*************** +*** 3413,3429 **** + break; + + case NFA_SKWORD: /* \K */ +! result = !VIM_ISDIGIT(c) && vim_iswordp_buf(reginput, reg_buf); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_FNAME: /* \f */ +! result = vim_isfilec(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_SFNAME: /* \F */ +! result = !VIM_ISDIGIT(c) && vim_isfilec(c); + ADD_POS_NEG_STATE(t->state); + break; + +--- 3419,3436 ---- + break; + + case NFA_SKWORD: /* \K */ +! result = !VIM_ISDIGIT(curc) +! && vim_iswordp_buf(reginput, reg_buf); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_FNAME: /* \f */ +! result = vim_isfilec(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_SFNAME: /* \F */ +! result = !VIM_ISDIGIT(curc) && vim_isfilec(curc); + ADD_POS_NEG_STATE(t->state); + break; + +*************** +*** 3433,3529 **** + break; + + case NFA_SPRINT: /* \P */ +! result = !VIM_ISDIGIT(c) && ptr2cells(reginput) == 1; + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_WHITE: /* \s */ +! result = vim_iswhite(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NWHITE: /* \S */ +! result = c != NUL && !vim_iswhite(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_DIGIT: /* \d */ +! result = ri_digit(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NDIGIT: /* \D */ +! result = c != NUL && !ri_digit(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_HEX: /* \x */ +! result = ri_hex(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NHEX: /* \X */ +! result = c != NUL && !ri_hex(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_OCTAL: /* \o */ +! result = ri_octal(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NOCTAL: /* \O */ +! result = c != NUL && !ri_octal(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_WORD: /* \w */ +! result = ri_word(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NWORD: /* \W */ +! result = c != NUL && !ri_word(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_HEAD: /* \h */ +! result = ri_head(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NHEAD: /* \H */ +! result = c != NUL && !ri_head(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_ALPHA: /* \a */ +! result = ri_alpha(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NALPHA: /* \A */ +! result = c != NUL && !ri_alpha(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_LOWER: /* \l */ +! result = ri_lower(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NLOWER: /* \L */ +! result = c != NUL && !ri_lower(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_UPPER: /* \u */ +! result = ri_upper(c); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NUPPER: /* \U */ +! result = c != NUL && !ri_upper(c); + ADD_POS_NEG_STATE(t->state); + break; + +--- 3440,3536 ---- + break; + + case NFA_SPRINT: /* \P */ +! result = !VIM_ISDIGIT(curc) && ptr2cells(reginput) == 1; + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_WHITE: /* \s */ +! result = vim_iswhite(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NWHITE: /* \S */ +! result = curc != NUL && !vim_iswhite(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_DIGIT: /* \d */ +! result = ri_digit(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NDIGIT: /* \D */ +! result = curc != NUL && !ri_digit(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_HEX: /* \x */ +! result = ri_hex(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NHEX: /* \X */ +! result = curc != NUL && !ri_hex(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_OCTAL: /* \o */ +! result = ri_octal(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NOCTAL: /* \O */ +! result = curc != NUL && !ri_octal(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_WORD: /* \w */ +! result = ri_word(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NWORD: /* \W */ +! result = curc != NUL && !ri_word(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_HEAD: /* \h */ +! result = ri_head(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NHEAD: /* \H */ +! result = curc != NUL && !ri_head(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_ALPHA: /* \a */ +! result = ri_alpha(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NALPHA: /* \A */ +! result = curc != NUL && !ri_alpha(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_LOWER: /* \l */ +! result = ri_lower(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NLOWER: /* \L */ +! result = curc != NUL && !ri_lower(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_UPPER: /* \u */ +! result = ri_upper(curc); + ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NUPPER: /* \U */ +! result = curc != NUL && !ri_upper(curc); + ADD_POS_NEG_STATE(t->state); + break; + +*************** +*** 3549,3565 **** + /* TODO: put this in #ifdef later */ + if (t->state->c < -256) + EMSGN("INTERNAL: Negative state char: %ld", t->state->c); +! result = (no_Magic(t->state->c) == c); + + if (!result) + result = ireg_ic == TRUE +! && MB_TOLOWER(t->state->c) == MB_TOLOWER(c); + #ifdef FEAT_MBYTE + /* If there is a composing character which is not being + * ignored there can be no match. Match with composing + * character uses NFA_COMPOSING above. */ + if (result && enc_utf8 && !ireg_icombine +! && n != utf_char2len(c)) + result = FALSE; + #endif + ADD_POS_NEG_STATE(t->state); +--- 3556,3572 ---- + /* TODO: put this in #ifdef later */ + if (t->state->c < -256) + EMSGN("INTERNAL: Negative state char: %ld", t->state->c); +! result = (no_Magic(t->state->c) == curc); + + if (!result) + result = ireg_ic == TRUE +! && MB_TOLOWER(t->state->c) == MB_TOLOWER(curc); + #ifdef FEAT_MBYTE + /* If there is a composing character which is not being + * ignored there can be no match. Match with composing + * character uses NFA_COMPOSING above. */ + if (result && enc_utf8 && !ireg_icombine +! && clen != utf_char2len(curc)) + result = FALSE; + #endif + ADD_POS_NEG_STATE(t->state); +*************** +*** 3578,3598 **** + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif +! addstate(nextlist, start, m, n, listid + 1, &match); + } + + #ifdef ENABLE_LOG + fprintf(log_fd, ">>> Thislist had %d states available: ", thislist->n); +! for (i = 0; i< thislist->n; i++) +! fprintf(log_fd, "%d ", abs(thislist->t[i].state->id)); + fprintf(log_fd, "\n"); + #endif + + nextchar: + /* Advance to the next character, or advance to the next line, or + * finish. */ +! if (n != 0) +! reginput += n; + else if (go_to_nextline) + reg_nextline(); + else +--- 3585,3609 ---- + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif +! addstate(nextlist, start, m, clen, listid + 1, &match); + } + + #ifdef ENABLE_LOG + fprintf(log_fd, ">>> Thislist had %d states available: ", thislist->n); +! { +! int i; +! +! for (i = 0; i < thislist->n; i++) +! fprintf(log_fd, "%d ", abs(thislist->t[i].state->id)); +! } + fprintf(log_fd, "\n"); + #endif + + nextchar: + /* Advance to the next character, or advance to the next line, or + * finish. */ +! if (clen != 0) +! reginput += clen; + else if (go_to_nextline) + reg_nextline(); + else +*** ../vim-7.3.1021/src/version.c 2013-05-26 14:32:01.000000000 +0200 +--- src/version.c 2013-05-26 14:39:12.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1022, + /**/ + +-- +Female engineers become irresistible at the age of consent and remain that +way until about thirty minutes after their clinical death. Longer if it's a +warm day. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 92b20399a84839c44a85905515c2189aab79ce9d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:04 +0200 Subject: [PATCH 0914/3340] - patchlevel 1023 --- 7.3.1023 | 109 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 109 insertions(+) create mode 100644 7.3.1023 diff --git a/7.3.1023 b/7.3.1023 new file mode 100644 index 00000000..1d2c03ee --- /dev/null +++ b/7.3.1023 @@ -0,0 +1,109 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1023 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1023 +Problem: Searching for composing char only and using \Z has different + results. +Solution: Make it match the composing char, matching everything is not + useful. +Files: src/regexp_nfa.c, src/testdir/test95.in, src/testdir/test95.ok + + +*** ../vim-7.3.1022/src/regexp_nfa.c 2013-05-26 14:54:07.000000000 +0200 +--- src/regexp_nfa.c 2013-05-26 15:02:26.000000000 +0200 +*************** +*** 3294,3300 **** + * (no preceding character). */ + len += mb_char2len(mc); + } +! if (ireg_icombine) + { + /* If \Z was present, then ignore composing characters. + * When ignoring the base character this always matches. */ +--- 3294,3300 ---- + * (no preceding character). */ + len += mb_char2len(mc); + } +! if (ireg_icombine && len == 0) + { + /* If \Z was present, then ignore composing characters. + * When ignoring the base character this always matches. */ +*** ../vim-7.3.1022/src/testdir/test95.in 2013-05-26 14:32:01.000000000 +0200 +--- src/testdir/test95.in 2013-05-26 15:07:01.000000000 +0200 +*************** +*** 62,71 **** + :call add(tl, [2, "×§\u200d\u05b9x\\Z", "x×§\u200dxy", "×§\u200dx"]) + :call add(tl, [2, "×§\u200dx\\Z", "x×§\u200d\u05b9xy", "×§\u200d\u05b9x"]) + :call add(tl, [2, "×§\u200dx\\Z", "x×§\u200dxy", "×§\u200dx"]) +! :"call add(tl, [2, "\u05b9\\Z", "xyz"]) +! :"call add(tl, [2, "\\Z\u05b9", "xyz"]) +! :"call add(tl, [2, "\u05b9\\+\\Z", "xyz", "xyz"]) +! :"call add(tl, [2, "\\Z\u05b9\\+", "xyz", "xyz"]) + + :"""" Combining different tests and features + :call add(tl, [2, '[^[=a=]]\+', 'ddaãâbcd', 'dd']) +--- 62,73 ---- + :call add(tl, [2, "×§\u200d\u05b9x\\Z", "x×§\u200dxy", "×§\u200dx"]) + :call add(tl, [2, "×§\u200dx\\Z", "x×§\u200d\u05b9xy", "×§\u200d\u05b9x"]) + :call add(tl, [2, "×§\u200dx\\Z", "x×§\u200dxy", "×§\u200dx"]) +! :call add(tl, [2, "\u05b9\\Z", "xyz"]) +! :call add(tl, [2, "\\Z\u05b9", "xyz"]) +! :call add(tl, [2, "\u05b9\\Z", "xy\u05b9z", "y\u05b9"]) +! :call add(tl, [2, "\\Z\u05b9", "xy\u05b9z", "y\u05b9"]) +! :call add(tl, [1, "\u05b9\\+\\Z", "xy\u05b9z\u05b9 ", "y\u05b9z\u05b9"]) +! :call add(tl, [1, "\\Z\u05b9\\+", "xy\u05b9z\u05b9 ", "y\u05b9z\u05b9"]) + + :"""" Combining different tests and features + :call add(tl, [2, '[^[=a=]]\+', 'ddaãâbcd', 'dd']) +*** ../vim-7.3.1022/src/testdir/test95.ok 2013-05-26 14:32:01.000000000 +0200 +--- src/testdir/test95.ok 2013-05-26 15:12:17.000000000 +0200 +*************** +*** 94,99 **** +--- 94,115 ---- + OK 0 - ×§â€x\Z + OK 1 - ×§â€x\Z + OK 2 - ×§â€x\Z ++ OK 0 - Ö¹\Z ++ OK 1 - Ö¹\Z ++ OK 2 - Ö¹\Z ++ OK 0 - \ZÖ¹ ++ OK 1 - \ZÖ¹ ++ OK 2 - \ZÖ¹ ++ OK 0 - Ö¹\Z ++ OK 1 - Ö¹\Z ++ OK 2 - Ö¹\Z ++ OK 0 - \ZÖ¹ ++ OK 1 - \ZÖ¹ ++ OK 2 - \ZÖ¹ ++ OK 0 - Ö¹\+\Z ++ OK 2 - Ö¹\+\Z ++ OK 0 - \ZÖ¹\+ ++ OK 2 - \ZÖ¹\+ + OK 0 - [^[=a=]]\+ + OK 1 - [^[=a=]]\+ + OK 2 - [^[=a=]]\+ +*** ../vim-7.3.1022/src/version.c 2013-05-26 15:14:11.000000000 +0200 +--- src/version.c 2013-05-26 15:08:43.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1023, + /**/ + +-- +Engineers are widely recognized as superior marriage material: intelligent, +dependable, employed, honest, and handy around the house. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c915e4deb40a3b64502e67c99b6259135da7cce2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:05 +0200 Subject: [PATCH 0915/3340] - patchlevel 1024 --- 7.3.1024 | 457 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 457 insertions(+) create mode 100644 7.3.1024 diff --git a/7.3.1024 b/7.3.1024 new file mode 100644 index 00000000..99025c91 --- /dev/null +++ b/7.3.1024 @@ -0,0 +1,457 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1024 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1024 +Problem: New regexp: End of matching pattern not set correctly. (Cesar + Romani) +Solution: Quit the loop after finding the match. Store nfa_has_zend in the + program. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok, + src/regexp.h + + +*** ../vim-7.3.1023/src/regexp_nfa.c 2013-05-26 15:14:49.000000000 +0200 +--- src/regexp_nfa.c 2013-05-26 16:51:44.000000000 +0200 +*************** +*** 2651,2657 **** + break; + + case NFA_MCLOSE + 0: +! if (nfa_has_zend == TRUE) + { + addstate(l, state->out, m, off, lid, match); + break; +--- 2651,2657 ---- + break; + + case NFA_MCLOSE + 0: +! if (nfa_has_zend) + { + addstate(l, state->out, m, off, lid, match); + break; +*************** +*** 3109,3115 **** + fprintf(log_fd, "\n"); + #endif + /* Found the left-most longest match, do not look at any other +! * states at this position. */ + goto nextchar; + + case NFA_END_INVISIBLE: +--- 3109,3119 ---- + fprintf(log_fd, "\n"); + #endif + /* Found the left-most longest match, do not look at any other +! * states at this position. When the list of states is going +! * to be empty quit without advancing, so that "reginput" is +! * correct. */ +! if (nextlist->n == 0 && neglist->n == 0) +! clen = 0; + goto nextchar; + + case NFA_END_INVISIBLE: +*************** +*** 3783,3790 **** + regline = line; + reglnum = 0; /* relative to line */ + +! nstate = prog->nstate; + + for (i = 0; i < nstate; ++i) + { + prog->state[i].id = i; +--- 3787,3795 ---- + regline = line; + reglnum = 0; /* relative to line */ + +! nfa_has_zend = prog->has_zend; + ++ nstate = prog->nstate; + for (i = 0; i < nstate; ++i) + { + prog->state[i].id = i; +*************** +*** 3871,3876 **** +--- 3876,3882 ---- + prog->regflags = regflags; + prog->engine = &nfa_regengine; + prog->nstate = nstate; ++ prog->has_zend = nfa_has_zend; + #ifdef ENABLE_LOG + nfa_postfix_dump(expr, OK); + nfa_dump(prog); +*** ../vim-7.3.1023/src/testdir/test64.in 2013-05-25 23:15:21.000000000 +0200 +--- src/testdir/test64.in 2013-05-26 16:50:38.000000000 +0200 +*************** +*** 15,25 **** + :" etc. + :" When there is no match use only the first two items. + :let tl = [] +! + :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" + :"""" Previously written tests """""""""""""""""""""""""""""""" + :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" +! + :call add(tl, [2, 'ab', 'aab', 'ab']) + :call add(tl, [2, 'b', 'abcdef', 'b']) + :call add(tl, [2, 'bc*', 'abccccdef', 'bcccc']) +--- 15,25 ---- + :" etc. + :" When there is no match use only the first two items. + :let tl = [] +! :" + :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" + :"""" Previously written tests """""""""""""""""""""""""""""""" + :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" +! :" + :call add(tl, [2, 'ab', 'aab', 'ab']) + :call add(tl, [2, 'b', 'abcdef', 'b']) + :call add(tl, [2, 'bc*', 'abccccdef', 'bcccc']) +*************** +*** 138,153 **** + :" + :call add(tl, [2, '\v(a*)+', 'aaaa', 'aaaa', '']) + :call add(tl, [2, 'x', 'abcdef']) +! + :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" + :""""" Simple tests """"""""""""""""""""""""""""""""""""""""""" + :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" +! + :" Search single groups + :call add(tl, [2, 'ab', 'aab', 'ab']) + :call add(tl, [2, 'ab', 'baced']) + :call add(tl, [2, 'ab', ' ab ', 'ab']) +! + :" Search multi-modifiers + :call add(tl, [2, 'x*', 'xcd', 'x']) + :call add(tl, [2, 'x*', 'xxxxxxxxxxxxxxxxsofijiojgf', 'xxxxxxxxxxxxxxxx']) +--- 138,153 ---- + :" + :call add(tl, [2, '\v(a*)+', 'aaaa', 'aaaa', '']) + :call add(tl, [2, 'x', 'abcdef']) +! :" + :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" + :""""" Simple tests """"""""""""""""""""""""""""""""""""""""""" + :"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" +! :" + :" Search single groups + :call add(tl, [2, 'ab', 'aab', 'ab']) + :call add(tl, [2, 'ab', 'baced']) + :call add(tl, [2, 'ab', ' ab ', 'ab']) +! :" + :" Search multi-modifiers + :call add(tl, [2, 'x*', 'xcd', 'x']) + :call add(tl, [2, 'x*', 'xxxxxxxxxxxxxxxxsofijiojgf', 'xxxxxxxxxxxxxxxx']) +*************** +*** 162,168 **** + :call add(tl, [2, 'x\?', 'x sdfoij', 'x']) + :call add(tl, [2, 'x\?', 'abc sfoij', '']) " empty match is good + :call add(tl, [2, 'x\?', 'xxxxxxxxxx c', 'x']) +! + :call add(tl, [2, 'a\{0,0}', 'abcdfdoij', '']) + :call add(tl, [2, 'a\{0,1}', 'asiubid axxxaaa', 'a']) " same thing as 'a?' + :call add(tl, [2, 'a\{1,0}', 'asiubid axxxaaa', 'a']) " same thing as 'a\{0,1}' +--- 162,168 ---- + :call add(tl, [2, 'x\?', 'x sdfoij', 'x']) + :call add(tl, [2, 'x\?', 'abc sfoij', '']) " empty match is good + :call add(tl, [2, 'x\?', 'xxxxxxxxxx c', 'x']) +! :" + :call add(tl, [2, 'a\{0,0}', 'abcdfdoij', '']) + :call add(tl, [2, 'a\{0,1}', 'asiubid axxxaaa', 'a']) " same thing as 'a?' + :call add(tl, [2, 'a\{1,0}', 'asiubid axxxaaa', 'a']) " same thing as 'a\{0,1}' +*************** +*** 182,188 **** + :call add(tl, [2, 'a\{,5}', 'aaaaaaaaaa', 'aaaaa']) + :call add(tl, [2, 'a\{}', 'bbbcddiuhfcd', '']) " same thing as 'a*' + :call add(tl, [2, 'a\{}', 'aaaaioudfh coisf jda', 'aaaa']) +! + :call add(tl, [2, 'a\{-0,0}', 'abcdfdoij', '']) + :call add(tl, [2, 'a\{-0,1}', 'asiubid axxxaaa', '']) " anti-greedy version of 'a?' + :call add(tl, [2, 'a\{-3,6}', 'aa siofuh']) +--- 182,188 ---- + :call add(tl, [2, 'a\{,5}', 'aaaaaaaaaa', 'aaaaa']) + :call add(tl, [2, 'a\{}', 'bbbcddiuhfcd', '']) " same thing as 'a*' + :call add(tl, [2, 'a\{}', 'aaaaioudfh coisf jda', 'aaaa']) +! :" + :call add(tl, [2, 'a\{-0,0}', 'abcdfdoij', '']) + :call add(tl, [2, 'a\{-0,1}', 'asiubid axxxaaa', '']) " anti-greedy version of 'a?' + :call add(tl, [2, 'a\{-3,6}', 'aa siofuh']) +*************** +*** 200,206 **** + :call add(tl, [2, 'a\{-,5}', 'aaaaaaaaaa', '']) + :call add(tl, [0, 'a\{-}', 'bbbcddiuhfcd', '']) " anti-greedy version of 'a*' + :call add(tl, [0, 'a\{-}', 'aaaaioudfh coisf jda', '']) +! + :" Test groups of characters and submatches + :call add(tl, [2, '\(abc\)*', 'abcabcabc', 'abcabcabc', 'abc']) + :call add(tl, [2, '\(ab\)\+', 'abababaaaaa', 'ababab', 'ab']) +--- 200,206 ---- + :call add(tl, [2, 'a\{-,5}', 'aaaaaaaaaa', '']) + :call add(tl, [0, 'a\{-}', 'bbbcddiuhfcd', '']) " anti-greedy version of 'a*' + :call add(tl, [0, 'a\{-}', 'aaaaioudfh coisf jda', '']) +! :" + :" Test groups of characters and submatches + :call add(tl, [2, '\(abc\)*', 'abcabcabc', 'abcabcabc', 'abc']) + :call add(tl, [2, '\(ab\)\+', 'abababaaaaa', 'ababab', 'ab']) +*************** +*** 213,219 **** + :call add(tl, [2, '\v((ab)|c*)+', 'abcccaba', 'abcccab', '', 'ab']) + :call add(tl, [2, '\v(a(c*)+b)+', 'acbababaaa', 'acbabab', 'ab', '']) + :call add(tl, [2, '\v(a|b*)+', 'aaaa', 'aaaa', '']) +! + :" Test greedy-ness and lazy-ness + :call add(tl, [2, 'a\{-2,7}','aaaaaaaaaaaaa', 'aa']) + :call add(tl, [2, 'a\{2,7}','aaaaaaaaaaaaaaaaaaaa', 'aaaaaaa']) +--- 213,219 ---- + :call add(tl, [2, '\v((ab)|c*)+', 'abcccaba', 'abcccab', '', 'ab']) + :call add(tl, [2, '\v(a(c*)+b)+', 'acbababaaa', 'acbabab', 'ab', '']) + :call add(tl, [2, '\v(a|b*)+', 'aaaa', 'aaaa', '']) +! :" + :" Test greedy-ness and lazy-ness + :call add(tl, [2, 'a\{-2,7}','aaaaaaaaaaaaa', 'aa']) + :call add(tl, [2, 'a\{2,7}','aaaaaaaaaaaaaaaaaaaa', 'aaaaaaa']) +*************** +*** 221,230 **** + :call add(tl, [2, '\vx(.*)yz(.*)','xayxayzxayzxayz','xayxayzxayzxayz', 'ayxayzxayzxa','']) + :call add(tl, [2, '\v(a{1,2}){-2,3}','aaaaaaa','aaaa','aa']) + :call add(tl, [2, '\v(a{-1,3})+','aa','aa','a']) +! + :" Test Character classes + :call add(tl, [2, '\d\+e\d\d','test 10e23 fd','10e23']) +! + :" Test collections and character range [] + :call add(tl, [2, '\v[a]', 'abcd', 'a']) + :call add(tl, [2, 'a[bcd]', 'abcd', 'ab']) +--- 221,230 ---- + :call add(tl, [2, '\vx(.*)yz(.*)','xayxayzxayzxayz','xayxayzxayzxayz', 'ayxayzxayzxa','']) + :call add(tl, [2, '\v(a{1,2}){-2,3}','aaaaaaa','aaaa','aa']) + :call add(tl, [2, '\v(a{-1,3})+','aa','aa','a']) +! :" + :" Test Character classes + :call add(tl, [2, '\d\+e\d\d','test 10e23 fd','10e23']) +! :" + :" Test collections and character range [] + :call add(tl, [2, '\v[a]', 'abcd', 'a']) + :call add(tl, [2, 'a[bcd]', 'abcd', 'ab']) +*************** +*** 250,257 **** + :call add(tl, [2, 'abc[0-9]*ddd', 'adf abc44482ddd oijs', 'abc44482ddd']) + :call add(tl, [2, '\_[0-9]\+', 'asfi9888u', '9888']) + :call add(tl, [2, '[0-9\n]\+', 'asfi9888u', '9888']) +! +! + :"""" Test recognition of some character classes + :call add(tl, [2, '[0-9]', '8', '8']) + :call add(tl, [2, '[^0-9]', '8']) +--- 250,257 ---- + :call add(tl, [2, 'abc[0-9]*ddd', 'adf abc44482ddd oijs', 'abc44482ddd']) + :call add(tl, [2, '\_[0-9]\+', 'asfi9888u', '9888']) + :call add(tl, [2, '[0-9\n]\+', 'asfi9888u', '9888']) +! :" +! :" + :"""" Test recognition of some character classes + :call add(tl, [2, '[0-9]', '8', '8']) + :call add(tl, [2, '[^0-9]', '8']) +*************** +*** 262,268 **** + :call add(tl, [2, '[a-zA-Z]', 'a', 'a']) + :call add(tl, [2, '[A-Z]', 'a']) + :call add(tl, [2, '\C[^A-Z]\+', 'ABCOIJDEOIFNSD jsfoij sa', ' jsfoij sa']) +! + :"""" Tests for \z features + :call add(tl, [2, 'xx \ze test', 'xx ']) " must match after \ze + :call add(tl, [0, 'abc\zeend', 'oij abcend', 'abc']) +--- 262,268 ---- + :call add(tl, [2, '[a-zA-Z]', 'a', 'a']) + :call add(tl, [2, '[A-Z]', 'a']) + :call add(tl, [2, '\C[^A-Z]\+', 'ABCOIJDEOIFNSD jsfoij sa', ' jsfoij sa']) +! :" + :"""" Tests for \z features + :call add(tl, [2, 'xx \ze test', 'xx ']) " must match after \ze + :call add(tl, [0, 'abc\zeend', 'oij abcend', 'abc']) +*************** +*** 271,277 **** + :call add(tl, [0, 'abc \zsmatch\ze abc', 'abc abc abc match abc abc', 'match']) + :call add(tl, [2, '\v(a \zsif .*){2}', 'a if then a if last', 'if last', 'a if last']) + :call add(tl, [2, '\>\zs.', 'aword. ', '.']) +! + :"""" Tests for \@ features + :call add(tl, [0, 'abc\@=', 'abc', 'ab']) + :call add(tl, [0, 'abc\@=cd', 'abcd', 'abcd']) +--- 271,277 ---- + :call add(tl, [0, 'abc \zsmatch\ze abc', 'abc abc abc match abc abc', 'match']) + :call add(tl, [2, '\v(a \zsif .*){2}', 'a if then a if last', 'if last', 'a if last']) + :call add(tl, [2, '\>\zs.', 'aword. ', '.']) +! :" + :"""" Tests for \@ features + :call add(tl, [0, 'abc\@=', 'abc', 'ab']) + :call add(tl, [0, 'abc\@=cd', 'abcd', 'abcd']) +*************** +*** 284,290 **** + :call add(tl, [2, '.*John\&.*Bob', 'here is John, and here is B']) " no match + :call add(tl, [0, '.*John\&.*Bob', 'John is Bobs friend', 'John is Bob']) + :call add(tl, [0, '\v(test1)@=.*yep', 'this is a test1, yep it is', 'test1, yep', 'test1']) +! + :"""" Combining different tests and features + :call add(tl, [2, '[[:alpha:]]\{-2,6}', '787abcdiuhsasiuhb4', 'ab']) + :call add(tl, [2, '', 'abcd', '']) +--- 284,290 ---- + :call add(tl, [2, '.*John\&.*Bob', 'here is John, and here is B']) " no match + :call add(tl, [0, '.*John\&.*Bob', 'John is Bobs friend', 'John is Bob']) + :call add(tl, [0, '\v(test1)@=.*yep', 'this is a test1, yep it is', 'test1, yep', 'test1']) +! :" + :"""" Combining different tests and features + :call add(tl, [2, '[[:alpha:]]\{-2,6}', '787abcdiuhsasiuhb4', 'ab']) + :call add(tl, [2, '', 'abcd', '']) +*************** +*** 292,313 **** + :call add(tl, [2, '\v%(ab(xyz)c)', ' abxyzc ', 'abxyzc', 'xyz']) + :call add(tl, [2, '\v(test|)empty', 'tesempty', 'empty', '']) + :call add(tl, [2, '\v(a|aa)(a|aa)', 'aaa', 'aa', 'a', 'a']) +! + :"""" \%u and friends + :call add(tl, [2, '\%d32', 'yes no', ' ']) + :call add(tl, [2, '\%o40', 'yes no', ' ']) + :call add(tl, [2, '\%x20', 'yes no', ' ']) + :call add(tl, [2, '\%u0020', 'yes no', ' ']) + :call add(tl, [2, '\%U00000020', 'yes no', ' ']) +! + :"""" Alternatives, must use first longest match + :call add(tl, [2, 'goo\|go', 'google', 'goo']) + :call add(tl, [2, '\ + :" This only works on a buffer line, not with expression evaluation + /^Find this +--- 347,353 ---- + : endfor + :endfor + :unlet t tl e l +! :" + :" Check that \_[0-9] matching EOL does not break a following \> + :" This only works on a buffer line, not with expression evaluation + /^Find this +*************** +*** 359,369 **** + /^Find this + /\%#=2\<\(\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\.\)\{3\}\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\> + y$Gop:" +! + :/\%#=1^Results/,$wq! test.out + ENDTEST + + Find this: + localnet/192.168.0.1 + + Results of test64: +--- 359,383 ---- + /^Find this + /\%#=2\<\(\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\.\)\{3\}\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\> + y$Gop:" +! :" +! :" Check that using a pattern on two lines doesn't get messed up by using +! :" matchstr() with \ze in between. +! :set re=0 +! /^Substitute here +! :.+1,.+2s/""/\='"'.matchstr(getline("."), '\d\+\ze<').'"' +! /^Substitute here +! :.+1,.+2yank +! Gop:" +! :" +! :" + :/\%#=1^Results/,$wq! test.out + ENDTEST + + Find this: + localnet/192.168.0.1 + ++ Substitute here: ++ Ta 5 ++ Ac 7 ++ + Results of test64: +*** ../vim-7.3.1023/src/testdir/test64.ok 2013-05-25 23:15:21.000000000 +0200 +--- src/testdir/test64.ok 2013-05-26 16:42:18.000000000 +0200 +*************** +*** 693,695 **** +--- 693,698 ---- + 192.168.0.1 + 192.168.0.1 + 192.168.0.1 ++ ++ Ta 5 ++ Ac 7 +*** ../vim-7.3.1023/src/regexp.h 2013-05-25 20:19:45.000000000 +0200 +--- src/regexp.h 2013-05-26 16:30:50.000000000 +0200 +*************** +*** 86,91 **** +--- 86,92 ---- + + regprog_T regprog; + nfa_state_T *start; ++ int has_zend; /* pattern contains \ze */ + int nstate; + nfa_state_T state[0]; /* actually longer.. */ + } nfa_regprog_T; +*** ../vim-7.3.1023/src/version.c 2013-05-26 15:14:49.000000000 +0200 +--- src/version.c 2013-05-26 16:55:29.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1024, + /**/ + +-- +An alien life briefly visits earth. Just before departing it leaves a +message in the dust on the back of a white van. The world is shocked +and wants to know what it means. After months of studies the worlds +best linguistic scientists are able to decipher the message: "Wash me!". + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b4e5145598341ced0fedbde3d9ca13db26e5c8eb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:05 +0200 Subject: [PATCH 0916/3340] - patchlevel 1025 --- 7.3.1025 | 218 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 218 insertions(+) create mode 100644 7.3.1025 diff --git a/7.3.1025 b/7.3.1025 new file mode 100644 index 00000000..04af5e43 --- /dev/null +++ b/7.3.1025 @@ -0,0 +1,218 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1025 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1025 +Problem: New regexp: not matching newline in string. (Marc Weber) +Solution: Check for "\n" character. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1024/src/regexp_nfa.c 2013-05-26 16:57:23.000000000 +0200 +--- src/regexp_nfa.c 2013-05-26 17:38:27.000000000 +0200 +*************** +*** 165,173 **** + static int *post_end; + static int *post_ptr; + +! static int nstate; /* Number of states in the NFA. */ + static int istate; /* Index in the state vector, used in new_state() */ +- static int nstate_max; /* Upper bound of estimated number of states. */ + + + static int nfa_regcomp_start __ARGS((char_u*expr, int re_flags)); +--- 165,173 ---- + static int *post_end; + static int *post_ptr; + +! static int nstate; /* Number of states in the NFA. Also used when +! * executing. */ + static int istate; /* Index in the state vector, used in new_state() */ + + + static int nfa_regcomp_start __ARGS((char_u*expr, int re_flags)); +*************** +*** 219,228 **** + int re_flags; /* see vim_regcomp() */ + { + size_t postfix_size; + + nstate = 0; + istate = 0; +! /* A reasonable estimation for size */ + nstate_max = (int)(STRLEN(expr) + 1) * NFA_POSTFIX_MULTIPLIER; + + /* Some items blow up in size, such as [A-z]. Add more space for that. +--- 219,229 ---- + int re_flags; /* see vim_regcomp() */ + { + size_t postfix_size; ++ int nstate_max; + + nstate = 0; + istate = 0; +! /* A reasonable estimation for maximum size */ + nstate_max = (int)(STRLEN(expr) + 1) * NFA_POSTFIX_MULTIPLIER; + + /* Some items blow up in size, such as [A-z]. Add more space for that. +*************** +*** 1968,1977 **** + * Frag_T.out is a list of places that need to be set to the + * next state for this fragment. + */ + typedef union Ptrlist Ptrlist; + struct Frag + { +! nfa_state_T *start; + Ptrlist *out; + }; + typedef struct Frag Frag_T; +--- 1969,1988 ---- + * Frag_T.out is a list of places that need to be set to the + * next state for this fragment. + */ ++ ++ /* Since the out pointers in the list are always ++ * uninitialized, we use the pointers themselves ++ * as storage for the Ptrlists. */ + typedef union Ptrlist Ptrlist; ++ union Ptrlist ++ { ++ Ptrlist *next; ++ nfa_state_T *s; ++ }; ++ + struct Frag + { +! nfa_state_T *start; + Ptrlist *out; + }; + typedef struct Frag Frag_T; +*************** +*** 1999,2015 **** + } + + /* +- * Since the out pointers in the list are always +- * uninitialized, we use the pointers themselves +- * as storage for the Ptrlists. +- */ +- union Ptrlist +- { +- Ptrlist *next; +- nfa_state_T *s; +- }; +- +- /* + * Create singleton list containing just outp. + */ + static Ptrlist * +--- 2010,2015 ---- +*************** +*** 3358,3365 **** + #endif + + case NFA_NEWL: +! if (!reg_line_lbr && REG_MULTI +! && curc == NUL && reglnum <= reg_maxline) + { + go_to_nextline = TRUE; + /* Pass -1 for the offset, which means taking the position +--- 3358,3365 ---- + #endif + + case NFA_NEWL: +! if (curc == NUL && !reg_line_lbr && REG_MULTI +! && reglnum <= reg_maxline) + { + go_to_nextline = TRUE; + /* Pass -1 for the offset, which means taking the position +*************** +*** 3367,3372 **** +--- 3367,3378 ---- + addstate(nextlist, t->state->out, &t->sub, -1, + listid + 1, &match); + } ++ else if (curc == '\n' && reg_line_lbr) ++ { ++ /* match \n as if it is an ordinary character */ ++ addstate(nextlist, t->state->out, &t->sub, 1, ++ listid + 1, &match); ++ } + break; + + case NFA_CLASS_ALNUM: +*************** +*** 3832,3838 **** +--- 3838,3849 ---- + * (and count its size). */ + postfix = re2post(); + if (postfix == NULL) ++ { ++ /* TODO: only give this error for debugging? */ ++ if (post_ptr >= post_end) ++ EMSGN("Internal error: estimated max number of states insufficient: %ld", post_end - post_start); + goto fail; /* Cascaded (syntax?) error */ ++ } + + /* + * In order to build the NFA, we parse the input regexp twice: +*** ../vim-7.3.1024/src/testdir/test64.in 2013-05-26 16:57:23.000000000 +0200 +--- src/testdir/test64.in 2013-05-26 17:37:51.000000000 +0200 +*************** +*** 250,255 **** +--- 250,258 ---- + :call add(tl, [2, 'abc[0-9]*ddd', 'adf abc44482ddd oijs', 'abc44482ddd']) + :call add(tl, [2, '\_[0-9]\+', 'asfi9888u', '9888']) + :call add(tl, [2, '[0-9\n]\+', 'asfi9888u', '9888']) ++ :call add(tl, [2, '\_[0-9]\+', "asfi\n9888u", "\n9888"]) ++ :call add(tl, [2, '\_f', " \na ", "\n"]) ++ :call add(tl, [2, '\_f\+', " \na ", "\na"]) + :" + :" + :"""" Test recognition of some character classes +*** ../vim-7.3.1024/src/testdir/test64.ok 2013-05-26 16:57:23.000000000 +0200 +--- src/testdir/test64.ok 2013-05-26 17:38:51.000000000 +0200 +*************** +*** 576,581 **** +--- 576,590 ---- + OK 0 - [0-9\n]\+ + OK 1 - [0-9\n]\+ + OK 2 - [0-9\n]\+ ++ OK 0 - \_[0-9]\+ ++ OK 1 - \_[0-9]\+ ++ OK 2 - \_[0-9]\+ ++ OK 0 - \_f ++ OK 1 - \_f ++ OK 2 - \_f ++ OK 0 - \_f\+ ++ OK 1 - \_f\+ ++ OK 2 - \_f\+ + OK 0 - [0-9] + OK 1 - [0-9] + OK 2 - [0-9] +*** ../vim-7.3.1024/src/version.c 2013-05-26 16:57:23.000000000 +0200 +--- src/version.c 2013-05-26 17:44:16.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1025, + /**/ + +-- +Every engineer dreams about saving the universe and having sex with aliens. +This is much more glamorous than the real life of an engineer, which consists +of hiding from the universe and having sex without the participation of other +life forms. (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 01ba77a949e6482ed8166f851fd16c1ce2564cb8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:06 +0200 Subject: [PATCH 0917/3340] - patchlevel 1026 --- 7.3.1026 | 108 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 108 insertions(+) create mode 100644 7.3.1026 diff --git a/7.3.1026 b/7.3.1026 new file mode 100644 index 00000000..dd5ca1bf --- /dev/null +++ b/7.3.1026 @@ -0,0 +1,108 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1026 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1026 +Problem: New regexp: pattern that includs a new-line matches too early. + (john McGowan) +Solution: Do not start searching in the second line. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1025/src/regexp_nfa.c 2013-05-26 17:45:41.000000000 +0200 +--- src/regexp_nfa.c 2013-05-26 18:38:01.000000000 +0200 +*************** +*** 3585,3596 **** + + } /* for (thislist = thislist; thislist->state; thislist++) */ + +! /* The first found match is the leftmost one, but there may be a +! * longer one. Keep running the NFA, but don't start from the +! * beginning. Also, do not add the start state in recursive calls of +! * nfa_regmatch(), because recursive calls should only start in the +! * first position. */ +! if (match == FALSE && start->c == NFA_MOPEN + 0) + { + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); +--- 3585,3599 ---- + + } /* for (thislist = thislist; thislist->state; thislist++) */ + +! /* Look for the start of a match in the current position by adding the +! * start state to the list of states. +! * The first found match is the leftmost one, thus the order of states +! * matters! +! * Do not add the start state in recursive calls of nfa_regmatch(), +! * because recursive calls should only start in the first position. +! * Also don't start a match past the first line. */ +! if (match == FALSE && start->c == NFA_MOPEN + 0 +! && reglnum == 0 && clen != 0) + { + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); +*** ../vim-7.3.1025/src/testdir/test64.in 2013-05-26 17:45:41.000000000 +0200 +--- src/testdir/test64.in 2013-05-26 18:34:04.000000000 +0200 +*************** +*** 372,377 **** +--- 372,383 ---- + :.+1,.+2yank + Gop:" + :" ++ :" Check a pattern with a line break matches in the right position. ++ /^Multiline ++ /\S.*\nx ++ :.yank ++ y$Gop:" ++ :" + :" + :/\%#=1^Results/,$wq! test.out + ENDTEST +*************** +*** 383,386 **** +--- 389,399 ---- + Ta 5 + Ac 7 + ++ Multiline: ++ abc ++ def ++ ghi ++ xjk ++ lmn ++ + Results of test64: +*** ../vim-7.3.1025/src/testdir/test64.ok 2013-05-26 17:45:41.000000000 +0200 +--- src/testdir/test64.ok 2013-05-26 18:34:00.000000000 +0200 +*************** +*** 705,707 **** +--- 705,708 ---- + + Ta 5 + Ac 7 ++ ghi +*** ../vim-7.3.1025/src/version.c 2013-05-26 17:45:41.000000000 +0200 +--- src/version.c 2013-05-26 18:35:52.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1026, + /**/ + +-- +For society, it's probably a good thing that engineers value function over +appearance. For example, you wouldn't want engineers to build nuclear power +plants that only _look_ like they would keep all the radiation inside. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 11ecdc8ecc60ea02cbb9ad06f0e9f8617ab3b331 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:06 +0200 Subject: [PATCH 0918/3340] - patchlevel 1027 --- 7.3.1027 | 80 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 7.3.1027 diff --git a/7.3.1027 b/7.3.1027 new file mode 100644 index 00000000..3dff82b3 --- /dev/null +++ b/7.3.1027 @@ -0,0 +1,80 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1027 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1027 +Problem: New regexp performance: Calling no_Magic() very often. +Solution: Remove magicness inline. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1026/src/regexp_nfa.c 2013-05-26 18:40:11.000000000 +0200 +--- src/regexp_nfa.c 2013-05-26 19:18:32.000000000 +0200 +*************** +*** 3563,3576 **** + break; + + default: /* regular character */ + /* TODO: put this in #ifdef later */ +! if (t->state->c < -256) +! EMSGN("INTERNAL: Negative state char: %ld", t->state->c); +! result = (no_Magic(t->state->c) == curc); + +! if (!result) +! result = ireg_ic == TRUE +! && MB_TOLOWER(t->state->c) == MB_TOLOWER(curc); + #ifdef FEAT_MBYTE + /* If there is a composing character which is not being + * ignored there can be no match. Match with composing +--- 3563,3580 ---- + break; + + default: /* regular character */ ++ { ++ int c = t->state->c; ++ + /* TODO: put this in #ifdef later */ +! if (c < -256) +! EMSGN("INTERNAL: Negative state char: %ld", c); +! if (is_Magic(c)) +! c = un_Magic(c); +! result = (c == curc); + +! if (!result && ireg_ic) +! result = MB_TOLOWER(c) == MB_TOLOWER(curc); + #ifdef FEAT_MBYTE + /* If there is a composing character which is not being + * ignored there can be no match. Match with composing +*************** +*** 3581,3586 **** +--- 3585,3591 ---- + #endif + ADD_POS_NEG_STATE(t->state); + break; ++ } + } + + } /* for (thislist = thislist; thislist->state; thislist++) */ +*** ../vim-7.3.1026/src/version.c 2013-05-26 18:40:11.000000000 +0200 +--- src/version.c 2013-05-26 19:16:07.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1027, + /**/ + +-- +It doesn't really matter what you are able to do if you don't do it. + (Bram Moolenaar) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 70ebfaa9db421b8680701d81f3037af0fc805682 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:07 +0200 Subject: [PATCH 0919/3340] - patchlevel 1028 --- 7.3.1028 | 895 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 895 insertions(+) create mode 100644 7.3.1028 diff --git a/7.3.1028 b/7.3.1028 new file mode 100644 index 00000000..44e3ddde --- /dev/null +++ b/7.3.1028 @@ -0,0 +1,895 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1028 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1028 +Problem: New regexp performance: Copying a lot of position state. +Solution: Only copy the sub-expressions that are being used. +Files: src/regexp_nfa.c, src/regexp.h + + +*** ../vim-7.3.1027/src/regexp_nfa.c 2013-05-26 19:19:48.000000000 +0200 +--- src/regexp_nfa.c 2013-05-26 21:35:33.000000000 +0200 +*************** +*** 161,166 **** +--- 161,170 ---- + /* NFA regexp \ze operator encountered. */ + static int nfa_has_zend = FALSE; + ++ /* Number of sub expressions actually being used during execution. 1 if only ++ * the whole match (subexpr 0) is used. */ ++ static int nfa_nsubexpr; ++ + static int *post_start; /* holds the postfix form of r.e. */ + static int *post_end; + static int *post_ptr; +*************** +*** 1645,1656 **** + return OK; + } + +! typedef struct + { +! char_u *start[NSUBEXP]; +! char_u *end[NSUBEXP]; +! lpos_T startpos[NSUBEXP]; +! lpos_T endpos[NSUBEXP]; + } regsub_T; + + static int nfa_regmatch __ARGS((nfa_state_T *start, regsub_T *submatch, regsub_T *m)); +--- 1649,1666 ---- + return OK; + } + +! typedef union + { +! struct multipos +! { +! lpos_T start; +! lpos_T end; +! } multilist[NSUBEXP]; +! struct linepos +! { +! char_u *start; +! char_u *end; +! } linelist[NSUBEXP]; + } regsub_T; + + static int nfa_regmatch __ARGS((nfa_state_T *start, regsub_T *submatch, regsub_T *m)); +*************** +*** 2479,2514 **** + * NFA execution code. + ****************************************************************/ + +! /* nfa_thread_T contains runtime information of a NFA state */ + typedef struct + { + nfa_state_T *state; +! regsub_T sub; /* Submatch info. TODO: expensive! */ + } nfa_thread_T; + +! + typedef struct + { + nfa_thread_T *t; + int n; + } nfa_list_T; + +! static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *m, int off, int lid, int *match)); + +! static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *m, int lid, int *match, int *ip)); + + static void +! addstate(l, state, m, off, lid, match) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ + regsub_T *m; /* pointers to subexpressions */ + int off; /* byte offset, when -1 go to next line */ + int lid; +- int *match; /* found match? */ + { +! regsub_T save; +! int subidx = 0; + nfa_thread_T *lastthread; + + if (l == NULL || state == NULL) + return; +--- 2489,2527 ---- + * NFA execution code. + ****************************************************************/ + +! /* nfa_thread_T contains execution information of a NFA state */ + typedef struct + { + nfa_state_T *state; +! regsub_T sub; /* submatch info, only party used */ + } nfa_thread_T; + +! /* nfa_list_T contains the alternative NFA execution states. */ + typedef struct + { + nfa_thread_T *t; + int n; + } nfa_list_T; + +! /* Used during execution: whether a match has been found. */ +! static int nfa_match; +! +! static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *m, int off, int lid)); + +! static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *m, int lid, int *ip)); + + static void +! addstate(l, state, m, off, lid) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ + regsub_T *m; /* pointers to subexpressions */ + int off; /* byte offset, when -1 go to next line */ + int lid; + { +! int subidx; + nfa_thread_T *lastthread; ++ lpos_T save_lpos; ++ char_u *save_ptr; + + if (l == NULL || state == NULL) + return; +*************** +*** 2544,2550 **** + state->lastlist = lid; + lastthread = &l->t[l->n++]; + lastthread->state = state; +! lastthread->sub = *m; /* TODO: expensive! */ + } + } + +--- 2557,2572 ---- + state->lastlist = lid; + lastthread = &l->t[l->n++]; + lastthread->state = state; +! +! /* Copy the match start and end positions. */ +! if (REG_MULTI) +! mch_memmove(&lastthread->sub.multilist[0], +! &m->multilist[0], +! sizeof(struct multipos) * nfa_nsubexpr); +! else +! mch_memmove(&lastthread->sub.linelist[0], +! &m->linelist[0], +! sizeof(struct linepos) * nfa_nsubexpr); + } + } + +*************** +*** 2556,2571 **** + switch (state->c) + { + case NFA_MATCH: +! *match = TRUE; + break; + + case NFA_SPLIT: +! addstate(l, state->out, m, off, lid, match); +! addstate(l, state->out1, m, off, lid, match); + break; + + case NFA_SKIP_CHAR: +! addstate(l, state->out, m, off, lid, match); + break; + + #if 0 +--- 2578,2593 ---- + switch (state->c) + { + case NFA_MATCH: +! nfa_match = TRUE; + break; + + case NFA_SPLIT: +! addstate(l, state->out, m, off, lid); +! addstate(l, state->out1, m, off, lid); + break; + + case NFA_SKIP_CHAR: +! addstate(l, state->out, m, off, lid); + break; + + #if 0 +*************** +*** 2587,2593 **** + + case NFA_NOPEN: + case NFA_NCLOSE: +! addstate(l, state->out, m, off, lid, match); + break; + + /* If this state is reached, then a recursive call of nfa_regmatch() +--- 2609,2615 ---- + + case NFA_NOPEN: + case NFA_NCLOSE: +! addstate(l, state->out, m, off, lid); + break; + + /* If this state is reached, then a recursive call of nfa_regmatch() +*************** +*** 2609,2659 **** + case NFA_MOPEN + 8: + case NFA_MOPEN + 9: + case NFA_ZSTART: +- subidx = state->c - NFA_MOPEN; + if (state->c == NFA_ZSTART) + subidx = 0; + + if (REG_MULTI) + { +! save.startpos[subidx] = m->startpos[subidx]; +! save.endpos[subidx] = m->endpos[subidx]; + if (off == -1) + { +! m->startpos[subidx].lnum = reglnum + 1; +! m->startpos[subidx].col = 0; + } + else + { +! m->startpos[subidx].lnum = reglnum; +! m->startpos[subidx].col = + (colnr_T)(reginput - regline + off); + } + } + else + { +! save.start[subidx] = m->start[subidx]; +! save.end[subidx] = m->end[subidx]; +! m->start[subidx] = reginput + off; + } + +! addstate(l, state->out, m, off, lid, match); + + if (REG_MULTI) +! { +! m->startpos[subidx] = save.startpos[subidx]; +! m->endpos[subidx] = save.endpos[subidx]; +! } + else +! { +! m->start[subidx] = save.start[subidx]; +! m->end[subidx] = save.end[subidx]; +! } + break; + + case NFA_MCLOSE + 0: + if (nfa_has_zend) + { +! addstate(l, state->out, m, off, lid, match); + break; + } + case NFA_MCLOSE + 1: +--- 2631,2674 ---- + case NFA_MOPEN + 8: + case NFA_MOPEN + 9: + case NFA_ZSTART: + if (state->c == NFA_ZSTART) + subidx = 0; ++ else ++ subidx = state->c - NFA_MOPEN; + + if (REG_MULTI) + { +! save_lpos = m->multilist[subidx].start; + if (off == -1) + { +! m->multilist[subidx].start.lnum = reglnum + 1; +! m->multilist[subidx].start.col = 0; + } + else + { +! m->multilist[subidx].start.lnum = reglnum; +! m->multilist[subidx].start.col = + (colnr_T)(reginput - regline + off); + } + } + else + { +! save_ptr = m->linelist[subidx].start; +! m->linelist[subidx].start = reginput + off; + } + +! addstate(l, state->out, m, off, lid); + + if (REG_MULTI) +! m->multilist[subidx].start = save_lpos; + else +! m->linelist[subidx].start = save_ptr; + break; + + case NFA_MCLOSE + 0: + if (nfa_has_zend) + { +! addstate(l, state->out, m, off, lid); + break; + } + case NFA_MCLOSE + 1: +*************** +*** 2666,2709 **** + case NFA_MCLOSE + 8: + case NFA_MCLOSE + 9: + case NFA_ZEND: +- subidx = state->c - NFA_MCLOSE; + if (state->c == NFA_ZEND) + subidx = 0; + + if (REG_MULTI) + { +! save.startpos[subidx] = m->startpos[subidx]; +! save.endpos[subidx] = m->endpos[subidx]; + if (off == -1) + { +! m->endpos[subidx].lnum = reglnum + 1; +! m->endpos[subidx].col = 0; + } + else + { +! m->endpos[subidx].lnum = reglnum; +! m->endpos[subidx].col = (colnr_T)(reginput - regline + off); + } + } + else + { +! save.start[subidx] = m->start[subidx]; +! save.end[subidx] = m->end[subidx]; +! m->end[subidx] = reginput + off; + } + +! addstate(l, state->out, m, off, lid, match); + + if (REG_MULTI) +! { +! m->startpos[subidx] = save.startpos[subidx]; +! m->endpos[subidx] = save.endpos[subidx]; +! } + else +! { +! m->start[subidx] = save.start[subidx]; +! m->end[subidx] = save.end[subidx]; +! } + break; + } + } +--- 2681,2718 ---- + case NFA_MCLOSE + 8: + case NFA_MCLOSE + 9: + case NFA_ZEND: + if (state->c == NFA_ZEND) + subidx = 0; ++ else ++ subidx = state->c - NFA_MCLOSE; + + if (REG_MULTI) + { +! save_lpos = m->multilist[subidx].end; + if (off == -1) + { +! m->multilist[subidx].end.lnum = reglnum + 1; +! m->multilist[subidx].end.col = 0; + } + else + { +! m->multilist[subidx].end.lnum = reglnum; +! m->multilist[subidx].end.col = +! (colnr_T)(reginput - regline + off); + } + } + else + { +! save_ptr = m->linelist[subidx].end; +! m->linelist[subidx].end = reginput + off; + } + +! addstate(l, state->out, m, off, lid); + + if (REG_MULTI) +! m->multilist[subidx].end = save_lpos; + else +! m->linelist[subidx].end = save_ptr; + break; + } + } +*************** +*** 2715,2726 **** + * matters for alternatives. + */ + static void +! addstate_here(l, state, m, lid, matchp, ip) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ + regsub_T *m; /* pointers to subexpressions */ + int lid; +- int *matchp; /* found match? */ + int *ip; + { + int tlen = l->n; +--- 2724,2734 ---- + * matters for alternatives. + */ + static void +! addstate_here(l, state, m, lid, ip) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ + regsub_T *m; /* pointers to subexpressions */ + int lid; + int *ip; + { + int tlen = l->n; +*************** +*** 2728,2734 **** + int i = *ip; + + /* first add the state(s) at the end, so that we know how many there are */ +! addstate(l, state, m, 0, lid, matchp); + + /* when "*ip" was at the end of the list, nothing to do */ + if (i + 1 == tlen) +--- 2736,2742 ---- + int i = *ip; + + /* first add the state(s) at the end, so that we know how many there are */ +! addstate(l, state, m, 0, lid); + + /* when "*ip" was at the end of the list, nothing to do */ + if (i + 1 == tlen) +*************** +*** 2925,2931 **** + { + int result; + int size = 0; +- int match = FALSE; + int flag = 0; + int old_reglnum = -1; + int go_to_nextline = FALSE; +--- 2933,2938 ---- +*************** +*** 2951,2956 **** +--- 2958,2964 ---- + return FALSE; + } + #endif ++ nfa_match = FALSE; + + /* Allocate memory for the lists of nodes */ + size = (nstate + 1) * sizeof(nfa_thread_T); +*************** +*** 2989,2995 **** + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif +! addstate(thislist, start, m, 0, listid, &match); + + /* There are two cases when the NFA advances: 1. input char matches the + * NFA node and 2. input char does not match the NFA node, but the next +--- 2997,3003 ---- + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif +! addstate(thislist, start, m, 0, listid); + + /* There are two cases when the NFA advances: 1. input char matches the + * NFA node and 2. input char does not match the NFA node, but the next +*************** +*** 3002,3008 **** + #define ADD_POS_NEG_STATE(node) \ + ll = listtbl[result ? 1 : 0][node->negated]; \ + if (ll != NULL) \ +! addstate(ll, node->out , &t->sub, clen, listid + 1, &match); + + + /* +--- 3010,3016 ---- + #define ADD_POS_NEG_STATE(node) \ + ll = listtbl[result ? 1 : 0][node->negated]; \ + if (ll != NULL) \ +! addstate(ll, node->out , &t->sub, clen, listid + 1); + + + /* +*************** +*** 3090,3096 **** + switch (t->state->c) + { + case NFA_MATCH: +! match = TRUE; + *submatch = t->sub; + #ifdef ENABLE_LOG + for (j = 0; j < 4; j++) +--- 3098,3104 ---- + switch (t->state->c) + { + case NFA_MATCH: +! nfa_match = TRUE; + *submatch = t->sub; + #ifdef ENABLE_LOG + for (j = 0; j < 4; j++) +*************** +*** 3125,3135 **** + * the parent call. */ + if (start->c == NFA_MOPEN + 0) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &listidx); + else + { + *m = t->sub; +! match = TRUE; + } + break; + +--- 3133,3143 ---- + * the parent call. */ + if (start->c == NFA_MOPEN + 0) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &listidx); + else + { + *m = t->sub; +! nfa_match = TRUE; + } + break; + +*************** +*** 3186,3205 **** + reglnum = old_reglnum; + /* Copy submatch info from the recursive call */ + if (REG_MULTI) +! for (j = 1; j < NSUBEXP; j++) + { +! t->sub.startpos[j] = m->startpos[j]; +! t->sub.endpos[j] = m->endpos[j]; + } + else +! for (j = 1; j < NSUBEXP; j++) + { +! t->sub.start[j] = m->start[j]; +! t->sub.end[j] = m->end[j]; + } + /* t->state->out1 is the corresponding END_INVISIBLE node */ + addstate_here(thislist, t->state->out1->out, &t->sub, +! listid, &match, &listidx); + } + else + { +--- 3194,3213 ---- + reglnum = old_reglnum; + /* Copy submatch info from the recursive call */ + if (REG_MULTI) +! for (j = 1; j < nfa_nsubexpr; j++) + { +! t->sub.multilist[j].start = m->multilist[j].start; +! t->sub.multilist[j].end = m->multilist[j].end; + } + else +! for (j = 1; j < nfa_nsubexpr; j++) + { +! t->sub.linelist[j].start = m->linelist[j].start; +! t->sub.linelist[j].end = m->linelist[j].end; + } + /* t->state->out1 is the corresponding END_INVISIBLE node */ + addstate_here(thislist, t->state->out1->out, &t->sub, +! listid, &listidx); + } + else + { +*************** +*** 3211,3223 **** + case NFA_BOL: + if (reginput == regline) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &listidx); + break; + + case NFA_EOL: + if (curc == NUL) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &listidx); + break; + + case NFA_BOW: +--- 3219,3231 ---- + case NFA_BOL: + if (reginput == regline) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &listidx); + break; + + case NFA_EOL: + if (curc == NUL) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &listidx); + break; + + case NFA_BOW: +*************** +*** 3245,3251 **** + bow = FALSE; + if (bow) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &listidx); + break; + } + +--- 3253,3259 ---- + bow = FALSE; + if (bow) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &listidx); + break; + } + +*************** +*** 3274,3280 **** + eow = FALSE; + if (eow) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &match, &listidx); + break; + } + +--- 3282,3288 ---- + eow = FALSE; + if (eow) + addstate_here(thislist, t->state->out, &t->sub, listid, +! &listidx); + break; + } + +*************** +*** 3364,3377 **** + go_to_nextline = TRUE; + /* Pass -1 for the offset, which means taking the position + * at the start of the next line. */ +! addstate(nextlist, t->state->out, &t->sub, -1, +! listid + 1, &match); + } + else if (curc == '\n' && reg_line_lbr) + { + /* match \n as if it is an ordinary character */ +! addstate(nextlist, t->state->out, &t->sub, 1, +! listid + 1, &match); + } + break; + +--- 3372,3383 ---- + go_to_nextline = TRUE; + /* Pass -1 for the offset, which means taking the position + * at the start of the next line. */ +! addstate(nextlist, t->state->out, &t->sub, -1, listid + 1); + } + else if (curc == '\n' && reg_line_lbr) + { + /* match \n as if it is an ordinary character */ +! addstate(nextlist, t->state->out, &t->sub, 1, listid + 1); + } + break; + +*************** +*** 3400,3413 **** + * CHAR(x), NFA_NOT, CHAR(y), NFA_NOT etc. */ + if (curc > 0) + addstate(nextlist, t->state->out, &t->sub, clen, +! listid + 1, &match); + break; + + case NFA_ANY: + /* Any char except '\0', (end of input) does not match. */ + if (curc > 0) + addstate(nextlist, t->state->out, &t->sub, clen, +! listid + 1, &match); + break; + + /* +--- 3406,3419 ---- + * CHAR(x), NFA_NOT, CHAR(y), NFA_NOT etc. */ + if (curc > 0) + addstate(nextlist, t->state->out, &t->sub, clen, +! listid + 1); + break; + + case NFA_ANY: + /* Any char except '\0', (end of input) does not match. */ + if (curc > 0) + addstate(nextlist, t->state->out, &t->sub, clen, +! listid + 1); + break; + + /* +*************** +*** 3597,3609 **** + * Do not add the start state in recursive calls of nfa_regmatch(), + * because recursive calls should only start in the first position. + * Also don't start a match past the first line. */ +! if (match == FALSE && start->c == NFA_MOPEN + 0 + && reglnum == 0 && clen != 0) + { + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif +! addstate(nextlist, start, m, clen, listid + 1, &match); + } + + #ifdef ENABLE_LOG +--- 3603,3615 ---- + * Do not add the start state in recursive calls of nfa_regmatch(), + * because recursive calls should only start in the first position. + * Also don't start a match past the first line. */ +! if (nfa_match == FALSE && start->c == NFA_MOPEN + 0 + && reglnum == 0 && clen != 0) + { + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif +! addstate(nextlist, start, m, clen, listid + 1); + } + + #ifdef ENABLE_LOG +*************** +*** 3640,3653 **** + vim_free(list[1].t); + vim_free(list[2].t); + list[0].t = list[1].t = list[2].t = NULL; +! if (listids != NULL) +! vim_free(listids); + #undef ADD_POS_NEG_STATE + #ifdef NFA_REGEXP_DEBUG_LOG + fclose(debug); + #endif + +! return match; + } + + /* +--- 3646,3658 ---- + vim_free(list[1].t); + vim_free(list[2].t); + list[0].t = list[1].t = list[2].t = NULL; +! vim_free(listids); + #undef ADD_POS_NEG_STATE + #ifdef NFA_REGEXP_DEBUG_LOG + fclose(debug); + #endif + +! return nfa_match; + } + + /* +*************** +*** 3690,3706 **** + if (REG_MULTI) + { + /* Use 0xff to set lnum to -1 */ +! vim_memset(sub.startpos, 0xff, sizeof(lpos_T) * NSUBEXP); +! vim_memset(sub.endpos, 0xff, sizeof(lpos_T) * NSUBEXP); +! vim_memset(m.startpos, 0xff, sizeof(lpos_T) * NSUBEXP); +! vim_memset(m.endpos, 0xff, sizeof(lpos_T) * NSUBEXP); + } + else + { +! vim_memset(sub.start, 0, sizeof(char_u *) * NSUBEXP); +! vim_memset(sub.end, 0, sizeof(char_u *) * NSUBEXP); +! vim_memset(m.start, 0, sizeof(char_u *) * NSUBEXP); +! vim_memset(m.end, 0, sizeof(char_u *) * NSUBEXP); + } + + if (nfa_regmatch(start, &sub, &m) == FALSE) +--- 3695,3707 ---- + if (REG_MULTI) + { + /* Use 0xff to set lnum to -1 */ +! vim_memset(sub.multilist, 0xff, sizeof(struct multipos) * nfa_nsubexpr); +! vim_memset(m.multilist, 0xff, sizeof(struct multipos) * nfa_nsubexpr); + } + else + { +! vim_memset(sub.linelist, 0, sizeof(struct linepos) * nfa_nsubexpr); +! vim_memset(m.linelist, 0, sizeof(struct linepos) * nfa_nsubexpr); + } + + if (nfa_regmatch(start, &sub, &m) == FALSE) +*************** +*** 3709,3718 **** + cleanup_subexpr(); + if (REG_MULTI) + { +! for (i = 0; i < NSUBEXP; i++) + { +! reg_startpos[i] = sub.startpos[i]; +! reg_endpos[i] = sub.endpos[i]; + } + + if (reg_startpos[0].lnum < 0) +--- 3710,3719 ---- + cleanup_subexpr(); + if (REG_MULTI) + { +! for (i = 0; i < nfa_nsubexpr; i++) + { +! reg_startpos[i] = sub.multilist[i].start; +! reg_endpos[i] = sub.multilist[i].end; + } + + if (reg_startpos[0].lnum < 0) +*************** +*** 3731,3740 **** + } + else + { +! for (i = 0; i < NSUBEXP; i++) + { +! reg_startp[i] = sub.start[i]; +! reg_endp[i] = sub.end[i]; + } + + if (reg_startp[0] == NULL) +--- 3732,3741 ---- + } + else + { +! for (i = 0; i < nfa_nsubexpr; i++) + { +! reg_startp[i] = sub.linelist[i].start; +! reg_endp[i] = sub.linelist[i].end; + } + + if (reg_startp[0] == NULL) +*************** +*** 3802,3807 **** +--- 3803,3809 ---- + reglnum = 0; /* relative to line */ + + nfa_has_zend = prog->has_zend; ++ nfa_nsubexpr = prog->nsubexp; + + nstate = prog->nstate; + for (i = 0; i < nstate; ++i) +*************** +*** 3896,3901 **** +--- 3898,3904 ---- + prog->engine = &nfa_regengine; + prog->nstate = nstate; + prog->has_zend = nfa_has_zend; ++ prog->nsubexp = regnpar; + #ifdef ENABLE_LOG + nfa_postfix_dump(expr, OK); + nfa_dump(prog); +*** ../vim-7.3.1027/src/regexp.h 2013-05-26 16:57:23.000000000 +0200 +--- src/regexp.h 2013-05-26 20:08:09.000000000 +0200 +*************** +*** 87,92 **** +--- 87,93 ---- + regprog_T regprog; + nfa_state_T *start; + int has_zend; /* pattern contains \ze */ ++ int nsubexp; /* number of () */ + int nstate; + nfa_state_T state[0]; /* actually longer.. */ + } nfa_regprog_T; +*** ../vim-7.3.1027/src/version.c 2013-05-26 19:19:48.000000000 +0200 +--- src/version.c 2013-05-26 21:44:20.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1028, + /**/ + +-- +Q: What's a light-year? +A: One-third less calories than a regular year. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c80075074aca6a4a810612a7ecb850f4db7ff9a0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:08 +0200 Subject: [PATCH 0920/3340] - patchlevel 1029 --- 7.3.1029 | 404 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 404 insertions(+) create mode 100644 7.3.1029 diff --git a/7.3.1029 b/7.3.1029 new file mode 100644 index 00000000..dcc59d2b --- /dev/null +++ b/7.3.1029 @@ -0,0 +1,404 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1029 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1029 +Problem: New regexp performance: Unused position state being copied. +Solution: Keep track of which positions are actually valid. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1028/src/regexp_nfa.c 2013-05-26 21:47:22.000000000 +0200 +--- src/regexp_nfa.c 2013-05-26 22:45:26.000000000 +0200 +*************** +*** 1649,1670 **** + return OK; + } + +- typedef union +- { +- struct multipos +- { +- lpos_T start; +- lpos_T end; +- } multilist[NSUBEXP]; +- struct linepos +- { +- char_u *start; +- char_u *end; +- } linelist[NSUBEXP]; +- } regsub_T; +- +- static int nfa_regmatch __ARGS((nfa_state_T *start, regsub_T *submatch, regsub_T *m)); +- + #ifdef DEBUG + static char_u code[50]; + +--- 1649,1654 ---- +*************** +*** 2489,2494 **** +--- 2473,2498 ---- + * NFA execution code. + ****************************************************************/ + ++ typedef struct ++ { ++ int in_use; /* number of subexpr with useful info */ ++ ++ /* When REG_MULTI is TRUE multilist is used, otherwise linelist. */ ++ union ++ { ++ struct multipos ++ { ++ lpos_T start; ++ lpos_T end; ++ } multilist[NSUBEXP]; ++ struct linepos ++ { ++ char_u *start; ++ char_u *end; ++ } linelist[NSUBEXP]; ++ }; ++ } regsub_T; ++ + /* nfa_thread_T contains execution information of a NFA state */ + typedef struct + { +*************** +*** 2507,2513 **** + static int nfa_match; + + static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *m, int off, int lid)); +- + static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *m, int lid, int *ip)); + + static void +--- 2511,2516 ---- +*************** +*** 2521,2527 **** +--- 2524,2532 ---- + int subidx; + nfa_thread_T *lastthread; + lpos_T save_lpos; ++ int save_in_use; + char_u *save_ptr; ++ int i; + + if (l == NULL || state == NULL) + return; +*************** +*** 2557,2572 **** + state->lastlist = lid; + lastthread = &l->t[l->n++]; + lastthread->state = state; +! +! /* Copy the match start and end positions. */ +! if (REG_MULTI) +! mch_memmove(&lastthread->sub.multilist[0], +! &m->multilist[0], +! sizeof(struct multipos) * nfa_nsubexpr); +! else +! mch_memmove(&lastthread->sub.linelist[0], +! &m->linelist[0], +! sizeof(struct linepos) * nfa_nsubexpr); + } + } + +--- 2562,2580 ---- + state->lastlist = lid; + lastthread = &l->t[l->n++]; + lastthread->state = state; +! lastthread->sub.in_use = m->in_use; +! if (m->in_use > 0) +! { +! /* Copy the match start and end positions. */ +! if (REG_MULTI) +! mch_memmove(&lastthread->sub.multilist[0], +! &m->multilist[0], +! sizeof(struct multipos) * m->in_use); +! else +! mch_memmove(&lastthread->sub.linelist[0], +! &m->linelist[0], +! sizeof(struct linepos) * m->in_use); +! } + } + } + +*************** +*** 2636,2644 **** + else + subidx = state->c - NFA_MOPEN; + + if (REG_MULTI) + { +! save_lpos = m->multilist[subidx].start; + if (off == -1) + { + m->multilist[subidx].start.lnum = reglnum + 1; +--- 2644,2668 ---- + else + subidx = state->c - NFA_MOPEN; + ++ /* Set the position (with "off") in the subexpression. Save and ++ * restore it when it was in use. Otherwise fill any gap. */ + if (REG_MULTI) + { +! if (subidx < m->in_use) +! { +! save_lpos = m->multilist[subidx].start; +! save_in_use = -1; +! } +! else +! { +! save_in_use = m->in_use; +! for (i = m->in_use; i < subidx; ++i) +! { +! m->multilist[i].start.lnum = -1; +! m->multilist[i].end.lnum = -1; +! } +! m->in_use = subidx + 1; +! } + if (off == -1) + { + m->multilist[subidx].start.lnum = reglnum + 1; +*************** +*** 2653,2668 **** + } + else + { +! save_ptr = m->linelist[subidx].start; + m->linelist[subidx].start = reginput + off; + } + + addstate(l, state->out, m, off, lid); + +! if (REG_MULTI) +! m->multilist[subidx].start = save_lpos; + else +! m->linelist[subidx].start = save_ptr; + break; + + case NFA_MCLOSE + 0: +--- 2677,2711 ---- + } + else + { +! if (subidx < m->in_use) +! { +! save_ptr = m->linelist[subidx].start; +! save_in_use = -1; +! } +! else +! { +! save_in_use = m->in_use; +! for (i = m->in_use; i < subidx; ++i) +! { +! m->linelist[i].start = NULL; +! m->linelist[i].end = NULL; +! } +! m->in_use = subidx + 1; +! } + m->linelist[subidx].start = reginput + off; + } + + addstate(l, state->out, m, off, lid); + +! if (save_in_use == -1) +! { +! if (REG_MULTI) +! m->multilist[subidx].start = save_lpos; +! else +! m->linelist[subidx].start = save_ptr; +! } + else +! m->in_use = save_in_use; + break; + + case NFA_MCLOSE + 0: +*************** +*** 2686,2691 **** +--- 2729,2739 ---- + else + subidx = state->c - NFA_MCLOSE; + ++ /* We don't fill in gaps here, there must have been an MOPEN that ++ * has done that. */ ++ save_in_use = m->in_use; ++ if (m->in_use <= subidx) ++ m->in_use = subidx + 1; + if (REG_MULTI) + { + save_lpos = m->multilist[subidx].end; +*************** +*** 2713,2718 **** +--- 2761,2767 ---- + m->multilist[subidx].end = save_lpos; + else + m->linelist[subidx].end = save_ptr; ++ m->in_use = save_in_use; + break; + } + } +*************** +*** 2917,2922 **** +--- 2966,2973 ---- + } + } + ++ static int nfa_regmatch __ARGS((nfa_state_T *start, regsub_T *submatch, regsub_T *m)); ++ + /* + * Main matching routine. + * +*************** +*** 2960,2966 **** + #endif + nfa_match = FALSE; + +! /* Allocate memory for the lists of nodes */ + size = (nstate + 1) * sizeof(nfa_thread_T); + list[0].t = (nfa_thread_T *)lalloc(size, TRUE); + list[1].t = (nfa_thread_T *)lalloc(size, TRUE); +--- 3011,3017 ---- + #endif + nfa_match = FALSE; + +! /* Allocate memory for the lists of nodes. */ + size = (nstate + 1) * sizeof(nfa_thread_T); + list[0].t = (nfa_thread_T *)lalloc(size, TRUE); + list[1].t = (nfa_thread_T *)lalloc(size, TRUE); +*************** +*** 3099,3105 **** + { + case NFA_MATCH: + nfa_match = TRUE; +! *submatch = t->sub; + #ifdef ENABLE_LOG + for (j = 0; j < 4; j++) + if (REG_MULTI) +--- 3150,3168 ---- + { + case NFA_MATCH: + nfa_match = TRUE; +! submatch->in_use = t->sub.in_use; +! if (REG_MULTI) +! for (j = 0; j < submatch->in_use; j++) +! { +! submatch->multilist[j].start = t->sub.multilist[j].start; +! submatch->multilist[j].end = t->sub.multilist[j].end; +! } +! else +! for (j = 0; j < submatch->in_use; j++) +! { +! submatch->linelist[j].start = t->sub.linelist[j].start; +! submatch->linelist[j].end = t->sub.linelist[j].end; +! } + #ifdef ENABLE_LOG + for (j = 0; j < 4; j++) + if (REG_MULTI) +*************** +*** 3194,3210 **** + reglnum = old_reglnum; + /* Copy submatch info from the recursive call */ + if (REG_MULTI) +! for (j = 1; j < nfa_nsubexpr; j++) + { + t->sub.multilist[j].start = m->multilist[j].start; + t->sub.multilist[j].end = m->multilist[j].end; + } + else +! for (j = 1; j < nfa_nsubexpr; j++) + { + t->sub.linelist[j].start = m->linelist[j].start; + t->sub.linelist[j].end = m->linelist[j].end; + } + /* t->state->out1 is the corresponding END_INVISIBLE node */ + addstate_here(thislist, t->state->out1->out, &t->sub, + listid, &listidx); +--- 3257,3275 ---- + reglnum = old_reglnum; + /* Copy submatch info from the recursive call */ + if (REG_MULTI) +! for (j = 1; j < m->in_use; j++) + { + t->sub.multilist[j].start = m->multilist[j].start; + t->sub.multilist[j].end = m->multilist[j].end; + } + else +! for (j = 1; j < m->in_use; j++) + { + t->sub.linelist[j].start = m->linelist[j].start; + t->sub.linelist[j].end = m->linelist[j].end; + } ++ t->sub.in_use = m->in_use; ++ + /* t->state->out1 is the corresponding END_INVISIBLE node */ + addstate_here(thislist, t->state->out1->out, &t->sub, + listid, &listidx); +*************** +*** 3703,3708 **** +--- 3768,3775 ---- + vim_memset(sub.linelist, 0, sizeof(struct linepos) * nfa_nsubexpr); + vim_memset(m.linelist, 0, sizeof(struct linepos) * nfa_nsubexpr); + } ++ sub.in_use = 0; ++ m.in_use = 0; + + if (nfa_regmatch(start, &sub, &m) == FALSE) + return 0; +*************** +*** 3710,3716 **** + cleanup_subexpr(); + if (REG_MULTI) + { +! for (i = 0; i < nfa_nsubexpr; i++) + { + reg_startpos[i] = sub.multilist[i].start; + reg_endpos[i] = sub.multilist[i].end; +--- 3777,3783 ---- + cleanup_subexpr(); + if (REG_MULTI) + { +! for (i = 0; i < sub.in_use; i++) + { + reg_startpos[i] = sub.multilist[i].start; + reg_endpos[i] = sub.multilist[i].end; +*************** +*** 3732,3738 **** + } + else + { +! for (i = 0; i < nfa_nsubexpr; i++) + { + reg_startp[i] = sub.linelist[i].start; + reg_endp[i] = sub.linelist[i].end; +--- 3799,3805 ---- + } + else + { +! for (i = 0; i < sub.in_use; i++) + { + reg_startp[i] = sub.linelist[i].start; + reg_endp[i] = sub.linelist[i].end; +*** ../vim-7.3.1028/src/version.c 2013-05-26 21:47:22.000000000 +0200 +--- src/version.c 2013-05-26 22:53:55.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1029, + /**/ + +-- +I used to be indecisive, now I'm not sure. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 062fcffaeb136335a7b132f8b3b212facaa5226a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:08 +0200 Subject: [PATCH 0921/3340] - patchlevel 1030 --- 7.3.1030 | 77 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 77 insertions(+) create mode 100644 7.3.1030 diff --git a/7.3.1030 b/7.3.1030 new file mode 100644 index 00000000..9ecda715 --- /dev/null +++ b/7.3.1030 @@ -0,0 +1,77 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1030 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1030 (after 7.3.1028) +Problem: Can't build for debugging. +Solution: Fix struct member names. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1029/src/regexp_nfa.c 2013-05-26 22:56:16.000000000 +0200 +--- src/regexp_nfa.c 2013-05-26 23:12:12.000000000 +0200 +*************** +*** 3164,3182 **** + submatch->linelist[j].end = t->sub.linelist[j].end; + } + #ifdef ENABLE_LOG +! for (j = 0; j < 4; j++) + if (REG_MULTI) + fprintf(log_fd, "\n *** group %d, start: c=%d, l=%d, end: c=%d, l=%d", + j, +! t->sub.startpos[j].col, +! (int)t->sub.startpos[j].lnum, +! t->sub.endpos[j].col, +! (int)t->sub.endpos[j].lnum); + else + fprintf(log_fd, "\n *** group %d, start: \"%s\", end: \"%s\"", + j, +! (char *)t->sub.start[j], +! (char *)t->sub.end[j]); + fprintf(log_fd, "\n"); + #endif + /* Found the left-most longest match, do not look at any other +--- 3164,3182 ---- + submatch->linelist[j].end = t->sub.linelist[j].end; + } + #ifdef ENABLE_LOG +! for (j = 0; j < t->sub.in_use; j++) + if (REG_MULTI) + fprintf(log_fd, "\n *** group %d, start: c=%d, l=%d, end: c=%d, l=%d", + j, +! t->sub.multilist[j].start.col, +! (int)t->sub.multilist[j].start.lnum, +! t->sub.multilist[j].end.col, +! (int)t->sub.multilist[j].end.lnum); + else + fprintf(log_fd, "\n *** group %d, start: \"%s\", end: \"%s\"", + j, +! (char *)t->sub.linelist[j].start, +! (char *)t->sub.linelist[j].end); + fprintf(log_fd, "\n"); + #endif + /* Found the left-most longest match, do not look at any other +*** ../vim-7.3.1029/src/version.c 2013-05-26 22:56:16.000000000 +0200 +--- src/version.c 2013-05-26 23:11:27.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1030, + /**/ + +-- +I think that you'll agree that engineers are very effective in their social +interactions. It's the "normal" people who are nuts. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1b6fde98863619e0cc97a8afdfb1d262ff897183 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:09 +0200 Subject: [PATCH 0922/3340] - patchlevel 1031 --- 7.3.1031 | 80 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 7.3.1031 diff --git a/7.3.1031 b/7.3.1031 new file mode 100644 index 00000000..466baec5 --- /dev/null +++ b/7.3.1031 @@ -0,0 +1,80 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1031 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1031 +Problem: Compiler warnings for shadowed variable. (John Little) +Solution: Move the variable declarations to the scope where they are used. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1030/src/regexp_nfa.c 2013-05-26 23:13:03.000000000 +0200 +--- src/regexp_nfa.c 2013-05-27 11:15:35.000000000 +0200 +*************** +*** 2999,3005 **** + nfa_list_T *nextlist; + nfa_list_T *neglist; + int *listids = NULL; +- int j = 0; + #ifdef NFA_REGEXP_DEBUG_LOG + FILE *debug = fopen(NFA_REGEXP_DEBUG_LOG, "a"); + +--- 2999,3004 ---- +*************** +*** 3149,3154 **** +--- 3148,3156 ---- + switch (t->state->c) + { + case NFA_MATCH: ++ { ++ int j; ++ + nfa_match = TRUE; + submatch->in_use = t->sub.in_use; + if (REG_MULTI) +*************** +*** 3186,3191 **** +--- 3188,3194 ---- + if (nextlist->n == 0 && neglist->n == 0) + clen = 0; + goto nextchar; ++ } + + case NFA_END_INVISIBLE: + /* This is only encountered after a NFA_START_INVISIBLE node. +*************** +*** 3251,3256 **** +--- 3254,3261 ---- + #endif + if (result == TRUE) + { ++ int j; ++ + /* Restore position in input text */ + reginput = old_reginput; + regline = old_regline; +*** ../vim-7.3.1030/src/version.c 2013-05-26 23:13:03.000000000 +0200 +--- src/version.c 2013-05-27 11:21:28.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1031, + /**/ + +-- +It's totally unfair to suggest - as many have - that engineers are socially +inept. Engineers simply have different objectives when it comes to social +interaction. + (Scott Adams - The Dilbert principle) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5b90797c45b619f4440e2682cd3ecc4b8f49dad8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:10 +0200 Subject: [PATCH 0923/3340] - patchlevel 1032 --- 7.3.1032 | 339 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 339 insertions(+) create mode 100644 7.3.1032 diff --git a/7.3.1032 b/7.3.1032 new file mode 100644 index 00000000..10ee7f1e --- /dev/null +++ b/7.3.1032 @@ -0,0 +1,339 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1032 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1032 +Problem: "\ze" is not supported by the new regexp engine. +Solution: Make "\ze" work. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1031/src/regexp_nfa.c 2013-05-27 11:21:59.000000000 +0200 +--- src/regexp_nfa.c 2013-05-27 20:06:16.000000000 +0200 +*************** +*** 159,165 **** + static int syntax_error = FALSE; + + /* NFA regexp \ze operator encountered. */ +! static int nfa_has_zend = FALSE; + + /* Number of sub expressions actually being used during execution. 1 if only + * the whole match (subexpr 0) is used. */ +--- 159,165 ---- + static int syntax_error = FALSE; + + /* NFA regexp \ze operator encountered. */ +! static int nfa_has_zend; + + /* Number of sub expressions actually being used during execution. 1 if only + * the whole match (subexpr 0) is used. */ +*************** +*** 791,799 **** + case 'e': + EMIT(NFA_ZEND); + nfa_has_zend = TRUE; +! /* TODO: Currently \ze does not work properly. */ +! return FAIL; +! /* break; */ + case '1': + case '2': + case '3': +--- 791,797 ---- + case 'e': + EMIT(NFA_ZEND); + nfa_has_zend = TRUE; +! break; + case '1': + case '2': + case '3': +*************** +*** 2711,2716 **** +--- 2709,2716 ---- + case NFA_MCLOSE + 0: + if (nfa_has_zend) + { ++ /* Do not overwrite the position set by \ze. If no \ze ++ * encountered end will be set in nfa_regtry(). */ + addstate(l, state->out, m, off, lid); + break; + } +*************** +*** 3635,3640 **** +--- 3635,3641 ---- + + case NFA_SKIP_CHAR: + case NFA_ZSTART: ++ case NFA_ZEND: + /* TODO: should not happen? */ + break; + +*************** +*** 3795,3800 **** +--- 3796,3802 ---- + } + if (reg_endpos[0].lnum < 0) + { ++ /* pattern has a \ze but it didn't match, use current end */ + reg_endpos[0].lnum = reglnum; + reg_endpos[0].col = (int)(reginput - regline); + } +*** ../vim-7.3.1031/src/testdir/test64.in 2013-05-26 18:40:11.000000000 +0200 +--- src/testdir/test64.in 2013-05-27 20:02:44.000000000 +0200 +*************** +*** 151,158 **** + :" Search multi-modifiers + :call add(tl, [2, 'x*', 'xcd', 'x']) + :call add(tl, [2, 'x*', 'xxxxxxxxxxxxxxxxsofijiojgf', 'xxxxxxxxxxxxxxxx']) +! :call add(tl, [2, 'x*', 'abcdoij', '']) " empty match is good +! :call add(tl, [2, 'x\+', 'abcdoin']) " no match here + :call add(tl, [2, 'x\+', 'abcdeoijdfxxiuhfij', 'xx']) + :call add(tl, [2, 'x\+', 'xxxxx', 'xxxxx']) + :call add(tl, [2, 'x\+', 'abc x siufhiush xxxxxxxxx', 'x']) +--- 151,160 ---- + :" Search multi-modifiers + :call add(tl, [2, 'x*', 'xcd', 'x']) + :call add(tl, [2, 'x*', 'xxxxxxxxxxxxxxxxsofijiojgf', 'xxxxxxxxxxxxxxxx']) +! :" empty match is good +! :call add(tl, [2, 'x*', 'abcdoij', '']) +! :" no match here +! :call add(tl, [2, 'x\+', 'abcdoin']) + :call add(tl, [2, 'x\+', 'abcdeoijdfxxiuhfij', 'xx']) + :call add(tl, [2, 'x\+', 'xxxxx', 'xxxxx']) + :call add(tl, [2, 'x\+', 'abc x siufhiush xxxxxxxxx', 'x']) +*************** +*** 160,171 **** + :call add(tl, [2, 'x\=', 'abc sfoij', '']) " empty match is good + :call add(tl, [2, 'x\=', 'xxxxxxxxx c', 'x']) + :call add(tl, [2, 'x\?', 'x sdfoij', 'x']) +! :call add(tl, [2, 'x\?', 'abc sfoij', '']) " empty match is good + :call add(tl, [2, 'x\?', 'xxxxxxxxxx c', 'x']) + :" + :call add(tl, [2, 'a\{0,0}', 'abcdfdoij', '']) +! :call add(tl, [2, 'a\{0,1}', 'asiubid axxxaaa', 'a']) " same thing as 'a?' +! :call add(tl, [2, 'a\{1,0}', 'asiubid axxxaaa', 'a']) " same thing as 'a\{0,1}' + :call add(tl, [2, 'a\{3,6}', 'aa siofuh']) + :call add(tl, [2, 'a\{3,6}', 'aaaaa asfoij afaa', 'aaaaa']) + :call add(tl, [2, 'a\{3,6}', 'aaaaaaaa', 'aaaaaa']) +--- 162,176 ---- + :call add(tl, [2, 'x\=', 'abc sfoij', '']) " empty match is good + :call add(tl, [2, 'x\=', 'xxxxxxxxx c', 'x']) + :call add(tl, [2, 'x\?', 'x sdfoij', 'x']) +! :" empty match is good +! :call add(tl, [2, 'x\?', 'abc sfoij', '']) + :call add(tl, [2, 'x\?', 'xxxxxxxxxx c', 'x']) + :" + :call add(tl, [2, 'a\{0,0}', 'abcdfdoij', '']) +! :" same thing as 'a?' +! :call add(tl, [2, 'a\{0,1}', 'asiubid axxxaaa', 'a']) +! :" same thing as 'a\{0,1}' +! :call add(tl, [2, 'a\{1,0}', 'asiubid axxxaaa', 'a']) + :call add(tl, [2, 'a\{3,6}', 'aa siofuh']) + :call add(tl, [2, 'a\{3,6}', 'aaaaa asfoij afaa', 'aaaaa']) + :call add(tl, [2, 'a\{3,6}', 'aaaaaaaa', 'aaaaaa']) +*************** +*** 173,190 **** + :call add(tl, [2, 'a\{2}', 'aaaa', 'aa']) + :call add(tl, [2, 'a\{2}', 'iuash fiusahfliusah fiushfilushfi uhsaifuh askfj nasfvius afg aaaa sfiuhuhiushf', 'aa']) + :call add(tl, [2, 'a\{2}', 'abcdefghijklmnopqrestuvwxyz1234567890']) +! :call add(tl, [2, 'a\{0,}', 'oij sdigfusnf', '']) " same thing as 'a*' + :call add(tl, [2, 'a\{0,}', 'aaaaa aa', 'aaaaa']) + :call add(tl, [2, 'a\{2,}', 'sdfiougjdsafg']) + :call add(tl, [0, 'a\{2,}', 'aaaaasfoij ', 'aaaaa']) + :call add(tl, [2, 'a\{,0}', 'oidfguih iuhi hiu aaaa', '']) + :call add(tl, [2, 'a\{,5}', 'abcd', 'a']) + :call add(tl, [2, 'a\{,5}', 'aaaaaaaaaa', 'aaaaa']) +! :call add(tl, [2, 'a\{}', 'bbbcddiuhfcd', '']) " same thing as 'a*' + :call add(tl, [2, 'a\{}', 'aaaaioudfh coisf jda', 'aaaa']) + :" + :call add(tl, [2, 'a\{-0,0}', 'abcdfdoij', '']) +! :call add(tl, [2, 'a\{-0,1}', 'asiubid axxxaaa', '']) " anti-greedy version of 'a?' + :call add(tl, [2, 'a\{-3,6}', 'aa siofuh']) + :call add(tl, [2, 'a\{-3,6}', 'aaaaa asfoij afaa', 'aaa']) + :call add(tl, [2, 'a\{-3,6}', 'aaaaaaaa', 'aaa']) +--- 178,198 ---- + :call add(tl, [2, 'a\{2}', 'aaaa', 'aa']) + :call add(tl, [2, 'a\{2}', 'iuash fiusahfliusah fiushfilushfi uhsaifuh askfj nasfvius afg aaaa sfiuhuhiushf', 'aa']) + :call add(tl, [2, 'a\{2}', 'abcdefghijklmnopqrestuvwxyz1234567890']) +! :" same thing as 'a*' +! :call add(tl, [2, 'a\{0,}', 'oij sdigfusnf', '']) + :call add(tl, [2, 'a\{0,}', 'aaaaa aa', 'aaaaa']) + :call add(tl, [2, 'a\{2,}', 'sdfiougjdsafg']) + :call add(tl, [0, 'a\{2,}', 'aaaaasfoij ', 'aaaaa']) + :call add(tl, [2, 'a\{,0}', 'oidfguih iuhi hiu aaaa', '']) + :call add(tl, [2, 'a\{,5}', 'abcd', 'a']) + :call add(tl, [2, 'a\{,5}', 'aaaaaaaaaa', 'aaaaa']) +! :" same thing as 'a*' +! :call add(tl, [2, 'a\{}', 'bbbcddiuhfcd', '']) + :call add(tl, [2, 'a\{}', 'aaaaioudfh coisf jda', 'aaaa']) + :" + :call add(tl, [2, 'a\{-0,0}', 'abcdfdoij', '']) +! :" anti-greedy version of 'a?' +! :call add(tl, [2, 'a\{-0,1}', 'asiubid axxxaaa', '']) + :call add(tl, [2, 'a\{-3,6}', 'aa siofuh']) + :call add(tl, [2, 'a\{-3,6}', 'aaaaa asfoij afaa', 'aaa']) + :call add(tl, [2, 'a\{-3,6}', 'aaaaaaaa', 'aaa']) +*************** +*** 198,204 **** + :call add(tl, [2, 'a\{-,0}', 'oidfguih iuhi hiu aaaa', '']) + :call add(tl, [2, 'a\{-,5}', 'abcd', '']) + :call add(tl, [2, 'a\{-,5}', 'aaaaaaaaaa', '']) +! :call add(tl, [0, 'a\{-}', 'bbbcddiuhfcd', '']) " anti-greedy version of 'a*' + :call add(tl, [0, 'a\{-}', 'aaaaioudfh coisf jda', '']) + :" + :" Test groups of characters and submatches +--- 206,213 ---- + :call add(tl, [2, 'a\{-,0}', 'oidfguih iuhi hiu aaaa', '']) + :call add(tl, [2, 'a\{-,5}', 'abcd', '']) + :call add(tl, [2, 'a\{-,5}', 'aaaaaaaaaa', '']) +! :" anti-greedy version of 'a*' +! :call add(tl, [0, 'a\{-}', 'bbbcddiuhfcd', '']) + :call add(tl, [0, 'a\{-}', 'aaaaioudfh coisf jda', '']) + :" + :" Test groups of characters and submatches +*************** +*** 243,252 **** + :call add(tl, [2, '[^[:alpha:]]\+','abcccadfoij7787ysf287yrnccdu','7787']) + :call add(tl, [2, '[-a]', '-', '-']) + :call add(tl, [2, '[a-]', '-', '-']) +! :call add(tl, [2, '[-./[:alnum:]_~]\+', 'log13.file', 'log13.file']) " filename regexp +! :call add(tl, [2, '[\]\^\-\\]\+', '\^\\\-\---^', '\^\\\-\---^']) " special chars +! :call add(tl, [2, '[[.a.]]\+', 'aa', 'aa']) " collation elem +! :call add(tl, [2, 'abc[0-9]*ddd', 'siuhabc ii']) " middle of regexp + :call add(tl, [2, 'abc[0-9]*ddd', 'adf abc44482ddd oijs', 'abc44482ddd']) + :call add(tl, [2, '\_[0-9]\+', 'asfi9888u', '9888']) + :call add(tl, [2, '[0-9\n]\+', 'asfi9888u', '9888']) +--- 252,265 ---- + :call add(tl, [2, '[^[:alpha:]]\+','abcccadfoij7787ysf287yrnccdu','7787']) + :call add(tl, [2, '[-a]', '-', '-']) + :call add(tl, [2, '[a-]', '-', '-']) +! :" filename regexp +! :call add(tl, [2, '[-./[:alnum:]_~]\+', 'log13.file', 'log13.file']) +! :" special chars +! :call add(tl, [2, '[\]\^\-\\]\+', '\^\\\-\---^', '\^\\\-\---^']) +! :" collation elem +! :call add(tl, [2, '[[.a.]]\+', 'aa', 'aa']) +! :" middle of regexp +! :call add(tl, [2, 'abc[0-9]*ddd', 'siuhabc ii']) + :call add(tl, [2, 'abc[0-9]*ddd', 'adf abc44482ddd oijs', 'abc44482ddd']) + :call add(tl, [2, '\_[0-9]\+', 'asfi9888u', '9888']) + :call add(tl, [2, '[0-9\n]\+', 'asfi9888u', '9888']) +*************** +*** 267,277 **** + :call add(tl, [2, '\C[^A-Z]\+', 'ABCOIJDEOIFNSD jsfoij sa', ' jsfoij sa']) + :" + :"""" Tests for \z features +! :call add(tl, [2, 'xx \ze test', 'xx ']) " must match after \ze +! :call add(tl, [0, 'abc\zeend', 'oij abcend', 'abc']) + :call add(tl, [2, 'abc\zsdd', 'ddabcddxyzt', 'dd']) +! :call add(tl, [2, 'aa \zsax', ' ax']) " must match before \zs +! :call add(tl, [0, 'abc \zsmatch\ze abc', 'abc abc abc match abc abc', 'match']) + :call add(tl, [2, '\v(a \zsif .*){2}', 'a if then a if last', 'if last', 'a if last']) + :call add(tl, [2, '\>\zs.', 'aword. ', '.']) + :" +--- 280,296 ---- + :call add(tl, [2, '\C[^A-Z]\+', 'ABCOIJDEOIFNSD jsfoij sa', ' jsfoij sa']) + :" + :"""" Tests for \z features +! :" match ends at \ze +! :call add(tl, [2, 'xx \ze test', 'xx ']) +! :call add(tl, [2, 'abc\zeend', 'oij abcend', 'abc']) +! :call add(tl, [2, 'aa\zebb\|aaxx', ' aabb ', 'aa']) +! :call add(tl, [2, 'aa\zebb\|aaxx', ' aaxx ', 'aaxx']) +! :call add(tl, [2, 'aabb\|aa\zebb', ' aabb ', 'aabb']) +! :call add(tl, [2, 'aa\zebb\|aaebb', ' aabb ', 'aa']) +! :" match starts at \zs + :call add(tl, [2, 'abc\zsdd', 'ddabcddxyzt', 'dd']) +! :call add(tl, [2, 'aa \zsax', ' ax']) +! :call add(tl, [2, 'abc \zsmatch\ze abc', 'abc abc abc match abc abc', 'match']) + :call add(tl, [2, '\v(a \zsif .*){2}', 'a if then a if last', 'if last', 'a if last']) + :call add(tl, [2, '\>\zs.', 'aword. ', '.']) + :" +*************** +*** 279,290 **** + :call add(tl, [0, 'abc\@=', 'abc', 'ab']) + :call add(tl, [0, 'abc\@=cd', 'abcd', 'abcd']) + :call add(tl, [0, 'abc\@=', 'ababc', 'ab']) +! :call add(tl, [2, 'abcd\@=e', 'abcd']) " will never match, no matter the input text +! :call add(tl, [2, 'abcd\@=e', 'any text in here ... ']) " will never match + :call add(tl, [0, '\v(abc)@=..', 'xabcd', 'ab', 'abc']) +! :call add(tl, [2, '\(.*John\)\@=.*Bob', 'here is John, and here is B']) " no match + :call add(tl, [0, '\(John.*\)\@=.*Bob', 'John is Bobs friend', 'John is Bob', 'John is Bobs friend']) +! :call add(tl, [2, '.*John\&.*Bob', 'here is John, and here is B']) " no match + :call add(tl, [0, '.*John\&.*Bob', 'John is Bobs friend', 'John is Bob']) + :call add(tl, [0, '\v(test1)@=.*yep', 'this is a test1, yep it is', 'test1, yep', 'test1']) + :" +--- 298,313 ---- + :call add(tl, [0, 'abc\@=', 'abc', 'ab']) + :call add(tl, [0, 'abc\@=cd', 'abcd', 'abcd']) + :call add(tl, [0, 'abc\@=', 'ababc', 'ab']) +! :" will never match, no matter the input text +! :call add(tl, [2, 'abcd\@=e', 'abcd']) +! :" will never match +! :call add(tl, [2, 'abcd\@=e', 'any text in here ... ']) + :call add(tl, [0, '\v(abc)@=..', 'xabcd', 'ab', 'abc']) +! :" no match +! :call add(tl, [2, '\(.*John\)\@=.*Bob', 'here is John, and here is B']) + :call add(tl, [0, '\(John.*\)\@=.*Bob', 'John is Bobs friend', 'John is Bob', 'John is Bobs friend']) +! :" no match +! :call add(tl, [2, '.*John\&.*Bob', 'here is John, and here is B']) + :call add(tl, [0, '.*John\&.*Bob', 'John is Bobs friend', 'John is Bob']) + :call add(tl, [0, '\v(test1)@=.*yep', 'this is a test1, yep it is', 'test1, yep', 'test1']) + :" +*** ../vim-7.3.1031/src/testdir/test64.ok 2013-05-26 18:40:11.000000000 +0200 +--- src/testdir/test64.ok 2013-05-27 20:04:55.000000000 +0200 +*************** +*** 617,622 **** +--- 617,635 ---- + OK 2 - xx \ze test + OK 0 - abc\zeend + OK 1 - abc\zeend ++ OK 2 - abc\zeend ++ OK 0 - aa\zebb\|aaxx ++ OK 1 - aa\zebb\|aaxx ++ OK 2 - aa\zebb\|aaxx ++ OK 0 - aa\zebb\|aaxx ++ OK 1 - aa\zebb\|aaxx ++ OK 2 - aa\zebb\|aaxx ++ OK 0 - aabb\|aa\zebb ++ OK 1 - aabb\|aa\zebb ++ OK 2 - aabb\|aa\zebb ++ OK 0 - aa\zebb\|aaebb ++ OK 1 - aa\zebb\|aaebb ++ OK 2 - aa\zebb\|aaebb + OK 0 - abc\zsdd + OK 1 - abc\zsdd + OK 2 - abc\zsdd +*************** +*** 625,630 **** +--- 638,644 ---- + OK 2 - aa \zsax + OK 0 - abc \zsmatch\ze abc + OK 1 - abc \zsmatch\ze abc ++ OK 2 - abc \zsmatch\ze abc + OK 0 - \v(a \zsif .*){2} + OK 1 - \v(a \zsif .*){2} + OK 2 - \v(a \zsif .*){2} +*** ../vim-7.3.1031/src/version.c 2013-05-27 11:21:59.000000000 +0200 +--- src/version.c 2013-05-27 20:04:19.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1032, + /**/ + +-- +An operatingsystem is just a name you give to the rest of bloating +idiosyncratic machine-based-features you left out of your editor. + (author unknown) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c7dad523eb94d3964db22a7d01f6b9d798a7991c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:10 +0200 Subject: [PATCH 0924/3340] - patchlevel 1033 --- 7.3.1033 | 1346 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1346 insertions(+) create mode 100644 7.3.1033 diff --git a/7.3.1033 b/7.3.1033 new file mode 100644 index 00000000..e7ff7cbc --- /dev/null +++ b/7.3.1033 @@ -0,0 +1,1346 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1033 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1033 +Problem: "\1" .. "\9" are not supported in the new regexp engine. +Solution: Implement them. Add a few more tests. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok, + src/regexp.h + + +*** ../vim-7.3.1032/src/regexp_nfa.c 2013-05-27 20:10:40.000000000 +0200 +--- src/regexp_nfa.c 2013-05-28 21:57:24.000000000 +0200 +*************** +*** 73,78 **** +--- 73,89 ---- + NFA_PREV_ATOM_JUST_BEFORE_NEG, /* Used for \@ */ + ++ NFA_BACKREF1, /* \1 */ ++ NFA_BACKREF2, /* \2 */ ++ NFA_BACKREF3, /* \3 */ ++ NFA_BACKREF4, /* \4 */ ++ NFA_BACKREF5, /* \5 */ ++ NFA_BACKREF6, /* \6 */ ++ NFA_BACKREF7, /* \7 */ ++ NFA_BACKREF8, /* \8 */ ++ NFA_BACKREF9, /* \9 */ ++ NFA_SKIP, /* Skip characters */ ++ + NFA_MOPEN, + NFA_MCLOSE = NFA_MOPEN + NSUBEXP, + +*************** +*** 709,715 **** + p = vim_strchr(classchars, no_Magic(c)); + if (p == NULL) + { +! return FAIL; /* runtime error */ + } + #ifdef FEAT_MBYTE + /* When '.' is followed by a composing char ignore the dot, so that +--- 720,727 ---- + p = vim_strchr(classchars, no_Magic(c)); + if (p == NULL) + { +! EMSGN("INTERNAL: Unknown character class char: %ld", c); +! return FAIL; + } + #ifdef FEAT_MBYTE + /* When '.' is followed by a composing char ignore the dot, so that +*************** +*** 766,785 **** + return FAIL; + + case Magic('~'): /* previous substitute pattern */ +! /* Not supported yet */ + return FAIL; + +! case Magic('1'): +! case Magic('2'): +! case Magic('3'): +! case Magic('4'): +! case Magic('5'): +! case Magic('6'): +! case Magic('7'): +! case Magic('8'): +! case Magic('9'): +! /* not supported yet */ +! return FAIL; + + case Magic('z'): + c = no_Magic(getchr()); +--- 778,795 ---- + return FAIL; + + case Magic('~'): /* previous substitute pattern */ +! /* TODO: Not supported yet */ + return FAIL; + +! case Magic('1'): EMIT(NFA_BACKREF1); break; +! case Magic('2'): EMIT(NFA_BACKREF2); break; +! case Magic('3'): EMIT(NFA_BACKREF3); break; +! case Magic('4'): EMIT(NFA_BACKREF4); break; +! case Magic('5'): EMIT(NFA_BACKREF5); break; +! case Magic('6'): EMIT(NFA_BACKREF6); break; +! case Magic('7'): EMIT(NFA_BACKREF7); break; +! case Magic('8'): EMIT(NFA_BACKREF8); break; +! case Magic('9'): EMIT(NFA_BACKREF9); break; + + case Magic('z'): + c = no_Magic(getchr()); +*************** +*** 802,808 **** + case '8': + case '9': + case '(': +! /* \z1...\z9 and \z( not yet supported */ + return FAIL; + default: + syntax_error = TRUE; +--- 812,818 ---- + case '8': + case '9': + case '(': +! /* TODO: \z1...\z9 and \z( not yet supported */ + return FAIL; + default: + syntax_error = TRUE; +*************** +*** 854,885 **** + * pattern -- regardless of whether or not it makes sense. */ + case '^': + EMIT(NFA_BOF); +! /* Not yet supported */ + return FAIL; + break; + + case '$': + EMIT(NFA_EOF); +! /* Not yet supported */ + return FAIL; + break; + + case '#': +! /* not supported yet */ + return FAIL; + break; + + case 'V': +! /* not supported yet */ + return FAIL; + break; + + case '[': +! /* \%[abc] not supported yet */ + return FAIL; + + default: +! /* not supported yet */ + return FAIL; + } + break; +--- 864,913 ---- + * pattern -- regardless of whether or not it makes sense. */ + case '^': + EMIT(NFA_BOF); +! /* TODO: Not yet supported */ + return FAIL; + break; + + case '$': + EMIT(NFA_EOF); +! /* TODO: Not yet supported */ + return FAIL; + break; + + case '#': +! /* TODO: not supported yet */ + return FAIL; + break; + + case 'V': +! /* TODO: not supported yet */ + return FAIL; + break; + + case '[': +! /* TODO: \%[abc] not supported yet */ +! return FAIL; +! +! case '0': +! case '1': +! case '2': +! case '3': +! case '4': +! case '5': +! case '6': +! case '7': +! case '8': +! case '9': +! case '<': +! case '>': +! case '\'': +! /* TODO: not supported yet */ + return FAIL; + + default: +! syntax_error = TRUE; +! EMSGN(_("E867: (NFA) Unknown operator '\\%%%c'"), +! no_Magic(c)); + return FAIL; + } + break; +*************** +*** 1672,1677 **** +--- 1700,1716 ---- + case NFA_ZSTART: STRCPY(code, "NFA_ZSTART"); break; + case NFA_ZEND: STRCPY(code, "NFA_ZEND"); break; + ++ case NFA_BACKREF1: STRCPY(code, "NFA_BACKREF1"); break; ++ case NFA_BACKREF2: STRCPY(code, "NFA_BACKREF2"); break; ++ case NFA_BACKREF3: STRCPY(code, "NFA_BACKREF3"); break; ++ case NFA_BACKREF4: STRCPY(code, "NFA_BACKREF4"); break; ++ case NFA_BACKREF5: STRCPY(code, "NFA_BACKREF5"); break; ++ case NFA_BACKREF6: STRCPY(code, "NFA_BACKREF6"); break; ++ case NFA_BACKREF7: STRCPY(code, "NFA_BACKREF7"); break; ++ case NFA_BACKREF8: STRCPY(code, "NFA_BACKREF8"); break; ++ case NFA_BACKREF9: STRCPY(code, "NFA_BACKREF9"); break; ++ case NFA_SKIP: STRCPY(code, "NFA_SKIP"); break; ++ + case NFA_PREV_ATOM_NO_WIDTH: + STRCPY(code, "NFA_PREV_ATOM_NO_WIDTH"); break; + case NFA_NOPEN: STRCPY(code, "NFA_MOPEN_INVISIBLE"); break; +*************** +*** 1949,1955 **** + + s->id = istate; + s->lastlist = 0; +- s->visits = 0; + s->negated = FALSE; + + return s; +--- 1988,1993 ---- +*************** +*** 2416,2421 **** +--- 2454,2483 ---- + PUSH(frag(s, list1(&s1->out))); + break; + ++ case NFA_BACKREF1: ++ case NFA_BACKREF2: ++ case NFA_BACKREF3: ++ case NFA_BACKREF4: ++ case NFA_BACKREF5: ++ case NFA_BACKREF6: ++ case NFA_BACKREF7: ++ case NFA_BACKREF8: ++ case NFA_BACKREF9: ++ if (nfa_calc_size == TRUE) ++ { ++ nstate += 2; ++ break; ++ } ++ s = new_state(*p, NULL, NULL); ++ if (s == NULL) ++ goto theend; ++ s1 = new_state(NFA_SKIP, NULL, NULL); ++ if (s1 == NULL) ++ goto theend; ++ patch(list1(&s->out), s1); ++ PUSH(frag(s, list1(&s1->out))); ++ break; ++ + case NFA_ZSTART: + case NFA_ZEND: + default: +*************** +*** 2495,2523 **** + typedef struct + { + nfa_state_T *state; + regsub_T sub; /* submatch info, only party used */ + } nfa_thread_T; + + /* nfa_list_T contains the alternative NFA execution states. */ + typedef struct + { +! nfa_thread_T *t; +! int n; + } nfa_list_T; + + /* Used during execution: whether a match has been found. */ + static int nfa_match; + +! static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *m, int off, int lid)); +! static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *m, int lid, int *ip)); + + static void +! addstate(l, state, m, off, lid) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ +! regsub_T *m; /* pointers to subexpressions */ + int off; /* byte offset, when -1 go to next line */ +- int lid; + { + int subidx; + nfa_thread_T *lastthread; +--- 2557,2610 ---- + typedef struct + { + nfa_state_T *state; ++ int count; + regsub_T sub; /* submatch info, only party used */ + } nfa_thread_T; + + /* nfa_list_T contains the alternative NFA execution states. */ + typedef struct + { +! nfa_thread_T *t; /* allocated array of states */ +! int n; /* nr of states in "t" */ +! int id; /* ID of the list */ + } nfa_list_T; + ++ #ifdef ENABLE_LOG ++ static void ++ log_subexpr(sub) ++ regsub_T *sub; ++ { ++ int j; ++ ++ for (j = 0; j < sub->in_use; j++) ++ if (REG_MULTI) ++ fprintf(log_fd, "\n *** group %d, start: c=%d, l=%d, end: c=%d, l=%d", ++ j, ++ sub->multilist[j].start.col, ++ (int)sub->multilist[j].start.lnum, ++ sub->multilist[j].end.col, ++ (int)sub->multilist[j].end.lnum); ++ else ++ fprintf(log_fd, "\n *** group %d, start: \"%s\", end: \"%s\"", ++ j, ++ (char *)sub->linelist[j].start, ++ (char *)sub->linelist[j].end); ++ fprintf(log_fd, "\n"); ++ } ++ #endif ++ + /* Used during execution: whether a match has been found. */ + static int nfa_match; + +! static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *sub, int off)); +! static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *sub, int *ip)); + + static void +! addstate(l, state, sub, off) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ +! regsub_T *sub; /* pointers to subexpressions */ + int off; /* byte offset, when -1 go to next line */ + { + int subidx; + nfa_thread_T *lastthread; +*************** +*** 2545,2585 **** + case NFA_MCLOSE + 7: + case NFA_MCLOSE + 8: + case NFA_MCLOSE + 9: +! /* Do not remember these nodes in list "thislist" or "nextlist" */ + break; + + default: +! if (state->lastlist == lid) + { +! if (++state->visits > 2) +! return; + } +! else + { +! /* add the state to the list */ +! state->lastlist = lid; +! lastthread = &l->t[l->n++]; +! lastthread->state = state; +! lastthread->sub.in_use = m->in_use; +! if (m->in_use > 0) +! { +! /* Copy the match start and end positions. */ +! if (REG_MULTI) +! mch_memmove(&lastthread->sub.multilist[0], +! &m->multilist[0], +! sizeof(struct multipos) * m->in_use); +! else +! mch_memmove(&lastthread->sub.linelist[0], +! &m->linelist[0], +! sizeof(struct linepos) * m->in_use); +! } + } + } + + #ifdef ENABLE_LOG + nfa_set_code(state->c); +! fprintf(log_fd, "> Adding state %d to list. Character %s, code %d\n", +! abs(state->id), code, state->c); + #endif + switch (state->c) + { +--- 2632,2689 ---- + case NFA_MCLOSE + 7: + case NFA_MCLOSE + 8: + case NFA_MCLOSE + 9: +! /* These nodes are not added themselves but their "out" and/or +! * "out1" may be added below. */ +! break; +! +! case NFA_MOPEN: +! case NFA_MOPEN + 1: +! case NFA_MOPEN + 2: +! case NFA_MOPEN + 3: +! case NFA_MOPEN + 4: +! case NFA_MOPEN + 5: +! case NFA_MOPEN + 6: +! case NFA_MOPEN + 7: +! case NFA_MOPEN + 8: +! case NFA_MOPEN + 9: +! /* These nodes do not need to be added, but we need to bail out +! * when it was tried to be added to this list before. */ +! if (state->lastlist == l->id) +! return; +! state->lastlist = l->id; + break; + + default: +! if (state->lastlist == l->id) + { +! /* This state is already in the list, don't add it again, +! * unless it is an MOPEN that is used for a backreference. */ +! return; + } +! +! /* add the state to the list */ +! state->lastlist = l->id; +! lastthread = &l->t[l->n++]; +! lastthread->state = state; +! lastthread->sub.in_use = sub->in_use; +! if (sub->in_use > 0) + { +! /* Copy the match start and end positions. */ +! if (REG_MULTI) +! mch_memmove(&lastthread->sub.multilist[0], +! &sub->multilist[0], +! sizeof(struct multipos) * sub->in_use); +! else +! mch_memmove(&lastthread->sub.linelist[0], +! &sub->linelist[0], +! sizeof(struct linepos) * sub->in_use); + } + } + + #ifdef ENABLE_LOG + nfa_set_code(state->c); +! fprintf(log_fd, "> Adding state %d to list. Character %d: %s\n", +! abs(state->id), state->c, code); + #endif + switch (state->c) + { +*************** +*** 2588,2599 **** + break; + + case NFA_SPLIT: +! addstate(l, state->out, m, off, lid); +! addstate(l, state->out1, m, off, lid); +! break; +! +! case NFA_SKIP_CHAR: +! addstate(l, state->out, m, off, lid); + break; + + #if 0 +--- 2692,2699 ---- + break; + + case NFA_SPLIT: +! addstate(l, state->out, sub, off); +! addstate(l, state->out1, sub, off); + break; + + #if 0 +*************** +*** 2613,2621 **** + break; + #endif + + case NFA_NOPEN: + case NFA_NCLOSE: +! addstate(l, state->out, m, off, lid); + break; + + /* If this state is reached, then a recursive call of nfa_regmatch() +--- 2713,2722 ---- + break; + #endif + ++ case NFA_SKIP_CHAR: + case NFA_NOPEN: + case NFA_NCLOSE: +! addstate(l, state->out, sub, off); + break; + + /* If this state is reached, then a recursive call of nfa_regmatch() +*************** +*** 2646,2709 **** + * restore it when it was in use. Otherwise fill any gap. */ + if (REG_MULTI) + { +! if (subidx < m->in_use) + { +! save_lpos = m->multilist[subidx].start; + save_in_use = -1; + } + else + { +! save_in_use = m->in_use; +! for (i = m->in_use; i < subidx; ++i) + { +! m->multilist[i].start.lnum = -1; +! m->multilist[i].end.lnum = -1; + } +! m->in_use = subidx + 1; + } + if (off == -1) + { +! m->multilist[subidx].start.lnum = reglnum + 1; +! m->multilist[subidx].start.col = 0; + } + else + { +! m->multilist[subidx].start.lnum = reglnum; +! m->multilist[subidx].start.col = + (colnr_T)(reginput - regline + off); + } + } + else + { +! if (subidx < m->in_use) + { +! save_ptr = m->linelist[subidx].start; + save_in_use = -1; + } + else + { +! save_in_use = m->in_use; +! for (i = m->in_use; i < subidx; ++i) + { +! m->linelist[i].start = NULL; +! m->linelist[i].end = NULL; + } +! m->in_use = subidx + 1; + } +! m->linelist[subidx].start = reginput + off; + } + +! addstate(l, state->out, m, off, lid); + + if (save_in_use == -1) + { + if (REG_MULTI) +! m->multilist[subidx].start = save_lpos; + else +! m->linelist[subidx].start = save_ptr; + } + else +! m->in_use = save_in_use; + break; + + case NFA_MCLOSE + 0: +--- 2747,2810 ---- + * restore it when it was in use. Otherwise fill any gap. */ + if (REG_MULTI) + { +! if (subidx < sub->in_use) + { +! save_lpos = sub->multilist[subidx].start; + save_in_use = -1; + } + else + { +! save_in_use = sub->in_use; +! for (i = sub->in_use; i < subidx; ++i) + { +! sub->multilist[i].start.lnum = -1; +! sub->multilist[i].end.lnum = -1; + } +! sub->in_use = subidx + 1; + } + if (off == -1) + { +! sub->multilist[subidx].start.lnum = reglnum + 1; +! sub->multilist[subidx].start.col = 0; + } + else + { +! sub->multilist[subidx].start.lnum = reglnum; +! sub->multilist[subidx].start.col = + (colnr_T)(reginput - regline + off); + } + } + else + { +! if (subidx < sub->in_use) + { +! save_ptr = sub->linelist[subidx].start; + save_in_use = -1; + } + else + { +! save_in_use = sub->in_use; +! for (i = sub->in_use; i < subidx; ++i) + { +! sub->linelist[i].start = NULL; +! sub->linelist[i].end = NULL; + } +! sub->in_use = subidx + 1; + } +! sub->linelist[subidx].start = reginput + off; + } + +! addstate(l, state->out, sub, off); + + if (save_in_use == -1) + { + if (REG_MULTI) +! sub->multilist[subidx].start = save_lpos; + else +! sub->linelist[subidx].start = save_ptr; + } + else +! sub->in_use = save_in_use; + break; + + case NFA_MCLOSE + 0: +*************** +*** 2711,2717 **** + { + /* Do not overwrite the position set by \ze. If no \ze + * encountered end will be set in nfa_regtry(). */ +! addstate(l, state->out, m, off, lid); + break; + } + case NFA_MCLOSE + 1: +--- 2812,2818 ---- + { + /* Do not overwrite the position set by \ze. If no \ze + * encountered end will be set in nfa_regtry(). */ +! addstate(l, state->out, sub, off); + break; + } + case NFA_MCLOSE + 1: +*************** +*** 2731,2767 **** + + /* We don't fill in gaps here, there must have been an MOPEN that + * has done that. */ +! save_in_use = m->in_use; +! if (m->in_use <= subidx) +! m->in_use = subidx + 1; + if (REG_MULTI) + { +! save_lpos = m->multilist[subidx].end; + if (off == -1) + { +! m->multilist[subidx].end.lnum = reglnum + 1; +! m->multilist[subidx].end.col = 0; + } + else + { +! m->multilist[subidx].end.lnum = reglnum; +! m->multilist[subidx].end.col = + (colnr_T)(reginput - regline + off); + } + } + else + { +! save_ptr = m->linelist[subidx].end; +! m->linelist[subidx].end = reginput + off; + } + +! addstate(l, state->out, m, off, lid); + + if (REG_MULTI) +! m->multilist[subidx].end = save_lpos; + else +! m->linelist[subidx].end = save_ptr; +! m->in_use = save_in_use; + break; + } + } +--- 2832,2868 ---- + + /* We don't fill in gaps here, there must have been an MOPEN that + * has done that. */ +! save_in_use = sub->in_use; +! if (sub->in_use <= subidx) +! sub->in_use = subidx + 1; + if (REG_MULTI) + { +! save_lpos = sub->multilist[subidx].end; + if (off == -1) + { +! sub->multilist[subidx].end.lnum = reglnum + 1; +! sub->multilist[subidx].end.col = 0; + } + else + { +! sub->multilist[subidx].end.lnum = reglnum; +! sub->multilist[subidx].end.col = + (colnr_T)(reginput - regline + off); + } + } + else + { +! save_ptr = sub->linelist[subidx].end; +! sub->linelist[subidx].end = reginput + off; + } + +! addstate(l, state->out, sub, off); + + if (REG_MULTI) +! sub->multilist[subidx].end = save_lpos; + else +! sub->linelist[subidx].end = save_ptr; +! sub->in_use = save_in_use; + break; + } + } +*************** +*** 2773,2783 **** + * matters for alternatives. + */ + static void +! addstate_here(l, state, m, lid, ip) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ +! regsub_T *m; /* pointers to subexpressions */ +! int lid; + int *ip; + { + int tlen = l->n; +--- 2874,2883 ---- + * matters for alternatives. + */ + static void +! addstate_here(l, state, sub, ip) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ +! regsub_T *sub; /* pointers to subexpressions */ + int *ip; + { + int tlen = l->n; +*************** +*** 2785,2791 **** + int i = *ip; + + /* first add the state(s) at the end, so that we know how many there are */ +! addstate(l, state, m, 0, lid); + + /* when "*ip" was at the end of the list, nothing to do */ + if (i + 1 == tlen) +--- 2885,2891 ---- + int i = *ip; + + /* first add the state(s) at the end, so that we know how many there are */ +! addstate(l, state, sub, 0); + + /* when "*ip" was at the end of the list, nothing to do */ + if (i + 1 == tlen) +*************** +*** 2895,2900 **** +--- 2995,3052 ---- + return FAIL; + } + ++ static int match_backref __ARGS((regsub_T *sub, int subidx, int *bytelen)); ++ ++ /* ++ * Check for a match with subexpression "subidx". ++ * return TRUE if it matches. ++ */ ++ static int ++ match_backref(sub, subidx, bytelen) ++ regsub_T *sub; /* pointers to subexpressions */ ++ int subidx; ++ int *bytelen; /* out: length of match in bytes */ ++ { ++ int len; ++ ++ if (sub->in_use <= subidx) ++ { ++ retempty: ++ /* backref was not set, match an empty string */ ++ *bytelen = 0; ++ return TRUE; ++ } ++ ++ if (REG_MULTI) ++ { ++ if (sub->multilist[subidx].start.lnum < 0 ++ || sub->multilist[subidx].end.lnum < 0) ++ goto retempty; ++ /* TODO: line breaks */ ++ len = sub->multilist[subidx].end.col ++ - sub->multilist[subidx].start.col; ++ if (cstrncmp(regline + sub->multilist[subidx].start.col, ++ reginput, &len) == 0) ++ { ++ *bytelen = len; ++ return TRUE; ++ } ++ } ++ else ++ { ++ if (sub->linelist[subidx].start == NULL ++ || sub->linelist[subidx].end == NULL) ++ goto retempty; ++ len = (int)(sub->linelist[subidx].end - sub->linelist[subidx].start); ++ if (cstrncmp(sub->linelist[subidx].start, reginput, &len) == 0) ++ { ++ *bytelen = len; ++ return TRUE; ++ } ++ } ++ return FALSE; ++ } ++ + /* + * Set all NFA nodes' list ID equal to -1. + */ +*************** +*** 2902,2910 **** + nfa_set_neg_listids(start) + nfa_state_T *start; + { +! if (start == NULL) +! return; +! if (start->lastlist >= 0) + { + start->lastlist = -1; + nfa_set_neg_listids(start->out); +--- 3054,3060 ---- + nfa_set_neg_listids(start) + nfa_state_T *start; + { +! if (start != NULL && start->lastlist >= 0) + { + start->lastlist = -1; + nfa_set_neg_listids(start->out); +*************** +*** 2919,2927 **** + nfa_set_null_listids(start) + nfa_state_T *start; + { +! if (start == NULL) +! return; +! if (start->lastlist == -1) + { + start->lastlist = 0; + nfa_set_null_listids(start->out); +--- 3069,3075 ---- + nfa_set_null_listids(start) + nfa_state_T *start; + { +! if (start != NULL && start->lastlist == -1) + { + start->lastlist = 0; + nfa_set_null_listids(start->out); +*************** +*** 2937,2945 **** + nfa_state_T *start; + int *list; + { +! if (start == NULL) +! return; +! if (start->lastlist != -1) + { + list[abs(start->id)] = start->lastlist; + start->lastlist = -1; +--- 3085,3091 ---- + nfa_state_T *start; + int *list; + { +! if (start != NULL && start->lastlist != -1) + { + list[abs(start->id)] = start->lastlist; + start->lastlist = -1; +*************** +*** 2956,2964 **** + nfa_state_T *start; + int *list; + { +! if (start == NULL) +! return; +! if (start->lastlist == -1) + { + start->lastlist = list[abs(start->id)]; + nfa_restore_listids(start->out, list); +--- 3102,3108 ---- + nfa_state_T *start; + int *list; + { +! if (start != NULL && start->lastlist == -1) + { + start->lastlist = list[abs(start->id)]; + nfa_restore_listids(start->out, list); +*************** +*** 3047,3053 **** + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif +! addstate(thislist, start, m, 0, listid); + + /* There are two cases when the NFA advances: 1. input char matches the + * NFA node and 2. input char does not match the NFA node, but the next +--- 3191,3198 ---- + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif +! thislist->id = listid; +! addstate(thislist, start, m, 0); + + /* There are two cases when the NFA advances: 1. input char matches the + * NFA node and 2. input char does not match the NFA node, but the next +*************** +*** 3060,3066 **** + #define ADD_POS_NEG_STATE(node) \ + ll = listtbl[result ? 1 : 0][node->negated]; \ + if (ll != NULL) \ +! addstate(ll, node->out , &t->sub, clen, listid + 1); + + + /* +--- 3205,3211 ---- + #define ADD_POS_NEG_STATE(node) \ + ll = listtbl[result ? 1 : 0][node->negated]; \ + if (ll != NULL) \ +! addstate(ll, node->out , &t->sub, clen); + + + /* +*************** +*** 3092,3100 **** + /* swap lists */ + thislist = &list[flag]; + nextlist = &list[flag ^= 1]; +! nextlist->n = 0; /* `clear' nextlist */ + listtbl[1][0] = nextlist; + ++listid; + + #ifdef ENABLE_LOG + fprintf(log_fd, "------------------------------------------\n"); +--- 3237,3248 ---- + /* swap lists */ + thislist = &list[flag]; + nextlist = &list[flag ^= 1]; +! nextlist->n = 0; /* clear nextlist */ + listtbl[1][0] = nextlist; + ++listid; ++ thislist->id = listid; ++ nextlist->id = listid + 1; ++ neglist->id = listid + 1; + + #ifdef ENABLE_LOG + fprintf(log_fd, "------------------------------------------\n"); +*************** +*** 3156,3162 **** + if (REG_MULTI) + for (j = 0; j < submatch->in_use; j++) + { +! submatch->multilist[j].start = t->sub.multilist[j].start; + submatch->multilist[j].end = t->sub.multilist[j].end; + } + else +--- 3304,3311 ---- + if (REG_MULTI) + for (j = 0; j < submatch->in_use; j++) + { +! submatch->multilist[j].start = +! t->sub.multilist[j].start; + submatch->multilist[j].end = t->sub.multilist[j].end; + } + else +*************** +*** 3166,3185 **** + submatch->linelist[j].end = t->sub.linelist[j].end; + } + #ifdef ENABLE_LOG +! for (j = 0; j < t->sub.in_use; j++) +! if (REG_MULTI) +! fprintf(log_fd, "\n *** group %d, start: c=%d, l=%d, end: c=%d, l=%d", +! j, +! t->sub.multilist[j].start.col, +! (int)t->sub.multilist[j].start.lnum, +! t->sub.multilist[j].end.col, +! (int)t->sub.multilist[j].end.lnum); +! else +! fprintf(log_fd, "\n *** group %d, start: \"%s\", end: \"%s\"", +! j, +! (char *)t->sub.linelist[j].start, +! (char *)t->sub.linelist[j].end); +! fprintf(log_fd, "\n"); + #endif + /* Found the left-most longest match, do not look at any other + * states at this position. When the list of states is going +--- 3315,3321 ---- + submatch->linelist[j].end = t->sub.linelist[j].end; + } + #ifdef ENABLE_LOG +! log_subexpr(&t->sub); + #endif + /* Found the left-most longest match, do not look at any other + * states at this position. When the list of states is going +*************** +*** 3198,3205 **** + * nfa_regmatch(). Submatches are stored in *m, and used in + * the parent call. */ + if (start->c == NFA_MOPEN + 0) +! addstate_here(thislist, t->state->out, &t->sub, listid, +! &listidx); + else + { + *m = t->sub; +--- 3334,3340 ---- + * nfa_regmatch(). Submatches are stored in *m, and used in + * the parent call. */ + if (start->c == NFA_MOPEN + 0) +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + else + { + *m = t->sub; +*************** +*** 3277,3283 **** + + /* t->state->out1 is the corresponding END_INVISIBLE node */ + addstate_here(thislist, t->state->out1->out, &t->sub, +! listid, &listidx); + } + else + { +--- 3412,3418 ---- + + /* t->state->out1 is the corresponding END_INVISIBLE node */ + addstate_here(thislist, t->state->out1->out, &t->sub, +! &listidx); + } + else + { +*************** +*** 3288,3301 **** + + case NFA_BOL: + if (reginput == regline) +! addstate_here(thislist, t->state->out, &t->sub, listid, +! &listidx); + break; + + case NFA_EOL: + if (curc == NUL) +! addstate_here(thislist, t->state->out, &t->sub, listid, +! &listidx); + break; + + case NFA_BOW: +--- 3423,3434 ---- + + case NFA_BOL: + if (reginput == regline) +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + break; + + case NFA_EOL: + if (curc == NUL) +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + break; + + case NFA_BOW: +*************** +*** 3322,3329 **** + && vim_iswordc_buf(reginput[-1], reg_buf))) + bow = FALSE; + if (bow) +! addstate_here(thislist, t->state->out, &t->sub, listid, +! &listidx); + break; + } + +--- 3455,3461 ---- + && vim_iswordc_buf(reginput[-1], reg_buf))) + bow = FALSE; + if (bow) +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + break; + } + +*************** +*** 3351,3358 **** + && vim_iswordc_buf(curc, reg_buf))) + eow = FALSE; + if (eow) +! addstate_here(thislist, t->state->out, &t->sub, listid, +! &listidx); + break; + } + +--- 3483,3489 ---- + && vim_iswordc_buf(curc, reg_buf))) + eow = FALSE; + if (eow) +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + break; + } + +*************** +*** 3442,3453 **** + go_to_nextline = TRUE; + /* Pass -1 for the offset, which means taking the position + * at the start of the next line. */ +! addstate(nextlist, t->state->out, &t->sub, -1, listid + 1); + } + else if (curc == '\n' && reg_line_lbr) + { + /* match \n as if it is an ordinary character */ +! addstate(nextlist, t->state->out, &t->sub, 1, listid + 1); + } + break; + +--- 3573,3584 ---- + go_to_nextline = TRUE; + /* Pass -1 for the offset, which means taking the position + * at the start of the next line. */ +! addstate(nextlist, t->state->out, &t->sub, -1); + } + else if (curc == '\n' && reg_line_lbr) + { + /* match \n as if it is an ordinary character */ +! addstate(nextlist, t->state->out, &t->sub, 1); + } + break; + +*************** +*** 3475,3489 **** + /* This follows a series of negated nodes, like: + * CHAR(x), NFA_NOT, CHAR(y), NFA_NOT etc. */ + if (curc > 0) +! addstate(nextlist, t->state->out, &t->sub, clen, +! listid + 1); + break; + + case NFA_ANY: + /* Any char except '\0', (end of input) does not match. */ + if (curc > 0) +! addstate(nextlist, t->state->out, &t->sub, clen, +! listid + 1); + break; + + /* +--- 3606,3618 ---- + /* This follows a series of negated nodes, like: + * CHAR(x), NFA_NOT, CHAR(y), NFA_NOT etc. */ + if (curc > 0) +! addstate(nextlist, t->state->out, &t->sub, clen); + break; + + case NFA_ANY: + /* Any char except '\0', (end of input) does not match. */ + if (curc > 0) +! addstate(nextlist, t->state->out, &t->sub, clen); + break; + + /* +*************** +*** 3620,3637 **** + ADD_POS_NEG_STATE(t->state); + break; + +! case NFA_MOPEN + 0: +! case NFA_MOPEN + 1: +! case NFA_MOPEN + 2: +! case NFA_MOPEN + 3: +! case NFA_MOPEN + 4: +! case NFA_MOPEN + 5: +! case NFA_MOPEN + 6: +! case NFA_MOPEN + 7: +! case NFA_MOPEN + 8: +! case NFA_MOPEN + 9: +! /* handled below */ + break; + + case NFA_SKIP_CHAR: + case NFA_ZSTART: +--- 3749,3822 ---- + ADD_POS_NEG_STATE(t->state); + break; + +! case NFA_BACKREF1: +! case NFA_BACKREF2: +! case NFA_BACKREF3: +! case NFA_BACKREF4: +! case NFA_BACKREF5: +! case NFA_BACKREF6: +! case NFA_BACKREF7: +! case NFA_BACKREF8: +! case NFA_BACKREF9: +! /* \1 .. \9 */ +! { +! int subidx = t->state->c - NFA_BACKREF1 + 1; +! int bytelen; +! +! result = match_backref(&t->sub, subidx, &bytelen); +! if (result) +! { +! if (bytelen == 0) +! { +! /* empty match always works, add NFA_SKIP with zero to +! * be used next */ +! addstate_here(thislist, t->state->out, &t->sub, +! &listidx); +! thislist->t[listidx + 1].count = 0; +! } +! else if (bytelen <= clen) +! { +! /* match current character, jump ahead to out of +! * NFA_SKIP */ +! addstate(nextlist, t->state->out->out, &t->sub, clen); +! #ifdef ENABLE_LOG +! log_subexpr(&nextlist->t[nextlist->n - 1].sub); +! #endif +! } +! else +! { +! /* skip ofer the matched characters, set character +! * count in NFA_SKIP */ +! addstate(nextlist, t->state->out, &t->sub, bytelen); +! nextlist->t[nextlist->n - 1].count = bytelen - clen; +! #ifdef ENABLE_LOG +! log_subexpr(&nextlist->t[nextlist->n - 1].sub); +! #endif +! } +! +! } + break; ++ } ++ case NFA_SKIP: ++ /* charater of previous matching \1 .. \9 */ ++ if (t->count - clen <= 0) ++ { ++ /* end of match, go to what follows */ ++ addstate(nextlist, t->state->out, &t->sub, clen); ++ #ifdef ENABLE_LOG ++ log_subexpr(&nextlist->t[nextlist->n - 1].sub); ++ #endif ++ } ++ else ++ { ++ /* add state again with decremented count */ ++ addstate(nextlist, t->state, &t->sub, 0); ++ nextlist->t[nextlist->n - 1].count = t->count - clen; ++ #ifdef ENABLE_LOG ++ log_subexpr(&nextlist->t[nextlist->n - 1].sub); ++ #endif ++ } ++ break; + + case NFA_SKIP_CHAR: + case NFA_ZSTART: +*************** +*** 3680,3686 **** + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif +! addstate(nextlist, start, m, clen, listid + 1); + } + + #ifdef ENABLE_LOG +--- 3865,3871 ---- + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif +! addstate(nextlist, start, m, clen); + } + + #ifdef ENABLE_LOG +*************** +*** 3884,3890 **** + { + prog->state[i].id = i; + prog->state[i].lastlist = 0; +- prog->state[i].visits = 0; + } + + retval = nfa_regtry(prog->start, col); +--- 4069,4074 ---- +*** ../vim-7.3.1032/src/testdir/test64.in 2013-05-27 20:10:40.000000000 +0200 +--- src/testdir/test64.in 2013-05-28 20:24:11.000000000 +0200 +*************** +*** 331,336 **** +--- 331,340 ---- + :call add(tl, [2, '\ Date: Tue, 4 Jun 2013 12:06:11 +0200 Subject: [PATCH 0925/3340] - patchlevel 1034 --- 7.3.1034 | 254 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 254 insertions(+) create mode 100644 7.3.1034 diff --git a/7.3.1034 b/7.3.1034 new file mode 100644 index 00000000..59e7ee3d --- /dev/null +++ b/7.3.1034 @@ -0,0 +1,254 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1034 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1034 +Problem: New regexp code using strange multi-byte code. +Solution: Use the normal code to advance and backup pointers. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1033/src/regexp_nfa.c 2013-05-28 22:03:13.000000000 +0200 +--- src/regexp_nfa.c 2013-05-28 22:25:28.000000000 +0200 +*************** +*** 188,195 **** + static int nfa_regcomp_start __ARGS((char_u*expr, int re_flags)); + static int nfa_recognize_char_class __ARGS((char_u *start, char_u *end, int extra_newl)); + static int nfa_emit_equi_class __ARGS((int c, int neg)); +- static void nfa_inc __ARGS((char_u **p)); +- static void nfa_dec __ARGS((char_u **p)); + static int nfa_regatom __ARGS((void)); + static int nfa_regpiece __ARGS((void)); + static int nfa_regconcat __ARGS((void)); +--- 188,193 ---- +*************** +*** 554,601 **** + */ + + /* +- * Increments the pointer "p" by one (multi-byte) character. +- */ +- static void +- nfa_inc(p) +- char_u **p; +- { +- #ifdef FEAT_MBYTE +- if (has_mbyte) +- mb_ptr2char_adv(p); +- else +- #endif +- *p = *p + 1; +- } +- +- /* +- * Decrements the pointer "p" by one (multi-byte) character. +- */ +- static void +- nfa_dec(p) +- char_u **p; +- { +- #ifdef FEAT_MBYTE +- char_u *p2, *oldp; +- +- if (has_mbyte) +- { +- oldp = *p; +- /* Try to find the multibyte char that advances to the current +- * position. */ +- do +- { +- *p = *p - 1; +- p2 = *p; +- mb_ptr2char_adv(&p2); +- } while (p2 != oldp); +- } +- #else +- *p = *p - 1; +- #endif +- } +- +- /* + * Parse the lowest level. + * + * An atom can be one of a long list of items. Many atoms match one character +--- 552,557 ---- +*************** +*** 963,969 **** + EMIT(NFA_OR); + } + regparse = endp; +! nfa_inc(®parse); + return OK; + } + /* +--- 919,925 ---- + EMIT(NFA_OR); + } + regparse = endp; +! mb_ptr_adv(regparse); + return OK; + } + /* +*************** +*** 978,984 **** + { + negated = TRUE; + glue = NFA_CONCAT; +! nfa_inc(®parse); + } + if (*regparse == '-') + { +--- 934,940 ---- + { + negated = TRUE; + glue = NFA_CONCAT; +! mb_ptr_adv(regparse); + } + if (*regparse == '-') + { +*************** +*** 986,992 **** + EMIT(startc); + TRY_NEG(); + EMIT_GLUE(); +! nfa_inc(®parse); + } + /* Emit the OR branches for each character in the [] */ + emit_range = FALSE; +--- 942,948 ---- + EMIT(startc); + TRY_NEG(); + EMIT_GLUE(); +! mb_ptr_adv(regparse); + } + /* Emit the OR branches for each character in the [] */ + emit_range = FALSE; +*************** +*** 1090,1096 **** + { + emit_range = TRUE; + startc = oldstartc; +! nfa_inc(®parse); + continue; /* reading the end of the range */ + } + +--- 1046,1052 ---- + { + emit_range = TRUE; + startc = oldstartc; +! mb_ptr_adv(regparse); + continue; /* reading the end of the range */ + } + +*************** +*** 1110,1116 **** + ) + ) + { +! nfa_inc(®parse); + + if (*regparse == 'n') + startc = reg_string ? NL : NFA_NEWL; +--- 1066,1072 ---- + ) + ) + { +! mb_ptr_adv(regparse); + + if (*regparse == 'n') + startc = reg_string ? NL : NFA_NEWL; +*************** +*** 1125,1131 **** + /* TODO(RE) This needs more testing */ + startc = coll_get_char(); + got_coll_char = TRUE; +! nfa_dec(®parse); + } + else + { +--- 1081,1087 ---- + /* TODO(RE) This needs more testing */ + startc = coll_get_char(); + got_coll_char = TRUE; +! mb_ptr_back(old_regparse, regparse); + } + else + { +*************** +*** 1210,1226 **** + EMIT_GLUE(); + } + +! nfa_inc(®parse); + } /* while (p < endp) */ + +! nfa_dec(®parse); + if (*regparse == '-') /* if last, '-' is just a char */ + { + EMIT('-'); + TRY_NEG(); + EMIT_GLUE(); + } +! nfa_inc(®parse); + + if (extra == ADD_NL) /* \_[] also matches \n */ + { +--- 1166,1182 ---- + EMIT_GLUE(); + } + +! mb_ptr_adv(regparse); + } /* while (p < endp) */ + +! mb_ptr_back(old_regparse, regparse); + if (*regparse == '-') /* if last, '-' is just a char */ + { + EMIT('-'); + TRY_NEG(); + EMIT_GLUE(); + } +! mb_ptr_adv(regparse); + + if (extra == ADD_NL) /* \_[] also matches \n */ + { +*************** +*** 1231,1237 **** + + /* skip the trailing ] */ + regparse = endp; +! nfa_inc(®parse); + if (negated == TRUE) + { + /* Mark end of negated char range */ +--- 1187,1193 ---- + + /* skip the trailing ] */ + regparse = endp; +! mb_ptr_adv(regparse); + if (negated == TRUE) + { + /* Mark end of negated char range */ +*** ../vim-7.3.1033/src/version.c 2013-05-28 22:03:13.000000000 +0200 +--- src/version.c 2013-05-28 22:29:18.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1034, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +7. You finally do take that vacation, but only after buying a cellular modem + and a laptop. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1005a586f8c2af5ef0a07f550f9bf65971160eac Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:12 +0200 Subject: [PATCH 0926/3340] - patchlevel 1035 --- 7.3.1035 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.1035 diff --git a/7.3.1035 b/7.3.1035 new file mode 100644 index 00000000..a188e1ee --- /dev/null +++ b/7.3.1035 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1035 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1035 +Problem: Compiler warning on 64 bit windows. +Solution: Add type cast. (Mike Williams) +Files: src/if_py_both.h + + +*** ../vim-7.3.1034/src/if_py_both.h 2013-05-24 18:58:39.000000000 +0200 +--- src/if_py_both.h 2013-05-28 19:19:50.000000000 +0200 +*************** +*** 3547,3553 **** + int status; + PyObject *pyfunc, *pymain; + +! if (u_save(RangeStart - 1, RangeEnd + 1) != OK) + { + EMSG(_("cannot save undo information")); + return; +--- 3547,3553 ---- + int status; + PyObject *pyfunc, *pymain; + +! if (u_save((linenr_T)RangeStart - 1, (linenr_T)RangeEnd + 1) != OK) + { + EMSG(_("cannot save undo information")); + return; +*** ../vim-7.3.1034/src/version.c 2013-05-28 22:30:22.000000000 +0200 +--- src/version.c 2013-05-28 22:31:18.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1035, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +8. You spend half of the plane trip with your laptop on your lap...and your + child in the overhead compartment. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5afbe74320a841a1b16806cdddbf1681b6470c44 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:12 +0200 Subject: [PATCH 0927/3340] - patchlevel 1036 --- 7.3.1036 | 515 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 515 insertions(+) create mode 100644 7.3.1036 diff --git a/7.3.1036 b/7.3.1036 new file mode 100644 index 00000000..bad7d11f --- /dev/null +++ b/7.3.1036 @@ -0,0 +1,515 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1036 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1036 +Problem: Can't build on HP-UX. +Solution: Give the union a name. (John Marriott) +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1035/src/regexp_nfa.c 2013-05-28 22:30:22.000000000 +0200 +--- src/regexp_nfa.c 2013-05-28 22:35:55.000000000 +0200 +*************** +*** 2493,2512 **** + { + int in_use; /* number of subexpr with useful info */ + +! /* When REG_MULTI is TRUE multilist is used, otherwise linelist. */ + union + { + struct multipos + { + lpos_T start; + lpos_T end; +! } multilist[NSUBEXP]; + struct linepos + { + char_u *start; + char_u *end; +! } linelist[NSUBEXP]; +! }; + } regsub_T; + + /* nfa_thread_T contains execution information of a NFA state */ +--- 2493,2512 ---- + { + int in_use; /* number of subexpr with useful info */ + +! /* When REG_MULTI is TRUE list.multi is used, otherwise list.line. */ + union + { + struct multipos + { + lpos_T start; + lpos_T end; +! } multi[NSUBEXP]; + struct linepos + { + char_u *start; + char_u *end; +! } line[NSUBEXP]; +! } list; + } regsub_T; + + /* nfa_thread_T contains execution information of a NFA state */ +*************** +*** 2536,2550 **** + if (REG_MULTI) + fprintf(log_fd, "\n *** group %d, start: c=%d, l=%d, end: c=%d, l=%d", + j, +! sub->multilist[j].start.col, +! (int)sub->multilist[j].start.lnum, +! sub->multilist[j].end.col, +! (int)sub->multilist[j].end.lnum); + else + fprintf(log_fd, "\n *** group %d, start: \"%s\", end: \"%s\"", + j, +! (char *)sub->linelist[j].start, +! (char *)sub->linelist[j].end); + fprintf(log_fd, "\n"); + } + #endif +--- 2536,2550 ---- + if (REG_MULTI) + fprintf(log_fd, "\n *** group %d, start: c=%d, l=%d, end: c=%d, l=%d", + j, +! sub->list.multi[j].start.col, +! (int)sub->list.multi[j].start.lnum, +! sub->list.multi[j].end.col, +! (int)sub->list.multi[j].end.lnum); + else + fprintf(log_fd, "\n *** group %d, start: \"%s\", end: \"%s\"", + j, +! (char *)sub->list.line[j].start, +! (char *)sub->list.line[j].end); + fprintf(log_fd, "\n"); + } + #endif +*************** +*** 2626,2637 **** + { + /* Copy the match start and end positions. */ + if (REG_MULTI) +! mch_memmove(&lastthread->sub.multilist[0], +! &sub->multilist[0], + sizeof(struct multipos) * sub->in_use); + else +! mch_memmove(&lastthread->sub.linelist[0], +! &sub->linelist[0], + sizeof(struct linepos) * sub->in_use); + } + } +--- 2626,2637 ---- + { + /* Copy the match start and end positions. */ + if (REG_MULTI) +! mch_memmove(&lastthread->sub.list.multi[0], +! &sub->list.multi[0], + sizeof(struct multipos) * sub->in_use); + else +! mch_memmove(&lastthread->sub.list.line[0], +! &sub->list.line[0], + sizeof(struct linepos) * sub->in_use); + } + } +*************** +*** 2705,2711 **** + { + if (subidx < sub->in_use) + { +! save_lpos = sub->multilist[subidx].start; + save_in_use = -1; + } + else +--- 2705,2711 ---- + { + if (subidx < sub->in_use) + { +! save_lpos = sub->list.multi[subidx].start; + save_in_use = -1; + } + else +*************** +*** 2713,2732 **** + save_in_use = sub->in_use; + for (i = sub->in_use; i < subidx; ++i) + { +! sub->multilist[i].start.lnum = -1; +! sub->multilist[i].end.lnum = -1; + } + sub->in_use = subidx + 1; + } + if (off == -1) + { +! sub->multilist[subidx].start.lnum = reglnum + 1; +! sub->multilist[subidx].start.col = 0; + } + else + { +! sub->multilist[subidx].start.lnum = reglnum; +! sub->multilist[subidx].start.col = + (colnr_T)(reginput - regline + off); + } + } +--- 2713,2732 ---- + save_in_use = sub->in_use; + for (i = sub->in_use; i < subidx; ++i) + { +! sub->list.multi[i].start.lnum = -1; +! sub->list.multi[i].end.lnum = -1; + } + sub->in_use = subidx + 1; + } + if (off == -1) + { +! sub->list.multi[subidx].start.lnum = reglnum + 1; +! sub->list.multi[subidx].start.col = 0; + } + else + { +! sub->list.multi[subidx].start.lnum = reglnum; +! sub->list.multi[subidx].start.col = + (colnr_T)(reginput - regline + off); + } + } +*************** +*** 2734,2740 **** + { + if (subidx < sub->in_use) + { +! save_ptr = sub->linelist[subidx].start; + save_in_use = -1; + } + else +--- 2734,2740 ---- + { + if (subidx < sub->in_use) + { +! save_ptr = sub->list.line[subidx].start; + save_in_use = -1; + } + else +*************** +*** 2742,2753 **** + save_in_use = sub->in_use; + for (i = sub->in_use; i < subidx; ++i) + { +! sub->linelist[i].start = NULL; +! sub->linelist[i].end = NULL; + } + sub->in_use = subidx + 1; + } +! sub->linelist[subidx].start = reginput + off; + } + + addstate(l, state->out, sub, off); +--- 2742,2753 ---- + save_in_use = sub->in_use; + for (i = sub->in_use; i < subidx; ++i) + { +! sub->list.line[i].start = NULL; +! sub->list.line[i].end = NULL; + } + sub->in_use = subidx + 1; + } +! sub->list.line[subidx].start = reginput + off; + } + + addstate(l, state->out, sub, off); +*************** +*** 2755,2763 **** + if (save_in_use == -1) + { + if (REG_MULTI) +! sub->multilist[subidx].start = save_lpos; + else +! sub->linelist[subidx].start = save_ptr; + } + else + sub->in_use = save_in_use; +--- 2755,2763 ---- + if (save_in_use == -1) + { + if (REG_MULTI) +! sub->list.multi[subidx].start = save_lpos; + else +! sub->list.line[subidx].start = save_ptr; + } + else + sub->in_use = save_in_use; +*************** +*** 2793,2823 **** + sub->in_use = subidx + 1; + if (REG_MULTI) + { +! save_lpos = sub->multilist[subidx].end; + if (off == -1) + { +! sub->multilist[subidx].end.lnum = reglnum + 1; +! sub->multilist[subidx].end.col = 0; + } + else + { +! sub->multilist[subidx].end.lnum = reglnum; +! sub->multilist[subidx].end.col = + (colnr_T)(reginput - regline + off); + } + } + else + { +! save_ptr = sub->linelist[subidx].end; +! sub->linelist[subidx].end = reginput + off; + } + + addstate(l, state->out, sub, off); + + if (REG_MULTI) +! sub->multilist[subidx].end = save_lpos; + else +! sub->linelist[subidx].end = save_ptr; + sub->in_use = save_in_use; + break; + } +--- 2793,2823 ---- + sub->in_use = subidx + 1; + if (REG_MULTI) + { +! save_lpos = sub->list.multi[subidx].end; + if (off == -1) + { +! sub->list.multi[subidx].end.lnum = reglnum + 1; +! sub->list.multi[subidx].end.col = 0; + } + else + { +! sub->list.multi[subidx].end.lnum = reglnum; +! sub->list.multi[subidx].end.col = + (colnr_T)(reginput - regline + off); + } + } + else + { +! save_ptr = sub->list.line[subidx].end; +! sub->list.line[subidx].end = reginput + off; + } + + addstate(l, state->out, sub, off); + + if (REG_MULTI) +! sub->list.multi[subidx].end = save_lpos; + else +! sub->list.line[subidx].end = save_ptr; + sub->in_use = save_in_use; + break; + } +*************** +*** 2975,2987 **** + + if (REG_MULTI) + { +! if (sub->multilist[subidx].start.lnum < 0 +! || sub->multilist[subidx].end.lnum < 0) + goto retempty; + /* TODO: line breaks */ +! len = sub->multilist[subidx].end.col +! - sub->multilist[subidx].start.col; +! if (cstrncmp(regline + sub->multilist[subidx].start.col, + reginput, &len) == 0) + { + *bytelen = len; +--- 2975,2987 ---- + + if (REG_MULTI) + { +! if (sub->list.multi[subidx].start.lnum < 0 +! || sub->list.multi[subidx].end.lnum < 0) + goto retempty; + /* TODO: line breaks */ +! len = sub->list.multi[subidx].end.col +! - sub->list.multi[subidx].start.col; +! if (cstrncmp(regline + sub->list.multi[subidx].start.col, + reginput, &len) == 0) + { + *bytelen = len; +*************** +*** 2990,3000 **** + } + else + { +! if (sub->linelist[subidx].start == NULL +! || sub->linelist[subidx].end == NULL) + goto retempty; +! len = (int)(sub->linelist[subidx].end - sub->linelist[subidx].start); +! if (cstrncmp(sub->linelist[subidx].start, reginput, &len) == 0) + { + *bytelen = len; + return TRUE; +--- 2990,3000 ---- + } + else + { +! if (sub->list.line[subidx].start == NULL +! || sub->list.line[subidx].end == NULL) + goto retempty; +! len = (int)(sub->list.line[subidx].end - sub->list.line[subidx].start); +! if (cstrncmp(sub->list.line[subidx].start, reginput, &len) == 0) + { + *bytelen = len; + return TRUE; +*************** +*** 3260,3274 **** + if (REG_MULTI) + for (j = 0; j < submatch->in_use; j++) + { +! submatch->multilist[j].start = +! t->sub.multilist[j].start; +! submatch->multilist[j].end = t->sub.multilist[j].end; + } + else + for (j = 0; j < submatch->in_use; j++) + { +! submatch->linelist[j].start = t->sub.linelist[j].start; +! submatch->linelist[j].end = t->sub.linelist[j].end; + } + #ifdef ENABLE_LOG + log_subexpr(&t->sub); +--- 3260,3275 ---- + if (REG_MULTI) + for (j = 0; j < submatch->in_use; j++) + { +! submatch->list.multi[j].start = +! t->sub.list.multi[j].start; +! submatch->list.multi[j].end = t->sub.list.multi[j].end; + } + else + for (j = 0; j < submatch->in_use; j++) + { +! submatch->list.line[j].start = +! t->sub.list.line[j].start; +! submatch->list.line[j].end = t->sub.list.line[j].end; + } + #ifdef ENABLE_LOG + log_subexpr(&t->sub); +*************** +*** 3355,3368 **** + if (REG_MULTI) + for (j = 1; j < m->in_use; j++) + { +! t->sub.multilist[j].start = m->multilist[j].start; +! t->sub.multilist[j].end = m->multilist[j].end; + } + else + for (j = 1; j < m->in_use; j++) + { +! t->sub.linelist[j].start = m->linelist[j].start; +! t->sub.linelist[j].end = m->linelist[j].end; + } + t->sub.in_use = m->in_use; + +--- 3356,3369 ---- + if (REG_MULTI) + for (j = 1; j < m->in_use; j++) + { +! t->sub.list.multi[j].start = m->list.multi[j].start; +! t->sub.list.multi[j].end = m->list.multi[j].end; + } + else + for (j = 1; j < m->in_use; j++) + { +! t->sub.list.line[j].start = m->list.line[j].start; +! t->sub.list.line[j].end = m->list.line[j].end; + } + t->sub.in_use = m->in_use; + +*************** +*** 3907,3919 **** + if (REG_MULTI) + { + /* Use 0xff to set lnum to -1 */ +! vim_memset(sub.multilist, 0xff, sizeof(struct multipos) * nfa_nsubexpr); +! vim_memset(m.multilist, 0xff, sizeof(struct multipos) * nfa_nsubexpr); + } + else + { +! vim_memset(sub.linelist, 0, sizeof(struct linepos) * nfa_nsubexpr); +! vim_memset(m.linelist, 0, sizeof(struct linepos) * nfa_nsubexpr); + } + sub.in_use = 0; + m.in_use = 0; +--- 3908,3920 ---- + if (REG_MULTI) + { + /* Use 0xff to set lnum to -1 */ +! vim_memset(sub.list.multi, 0xff, sizeof(struct multipos) * nfa_nsubexpr); +! vim_memset(m.list.multi, 0xff, sizeof(struct multipos) * nfa_nsubexpr); + } + else + { +! vim_memset(sub.list.line, 0, sizeof(struct linepos) * nfa_nsubexpr); +! vim_memset(m.list.line, 0, sizeof(struct linepos) * nfa_nsubexpr); + } + sub.in_use = 0; + m.in_use = 0; +*************** +*** 3926,3933 **** + { + for (i = 0; i < sub.in_use; i++) + { +! reg_startpos[i] = sub.multilist[i].start; +! reg_endpos[i] = sub.multilist[i].end; + } + + if (reg_startpos[0].lnum < 0) +--- 3927,3934 ---- + { + for (i = 0; i < sub.in_use; i++) + { +! reg_startpos[i] = sub.list.multi[i].start; +! reg_endpos[i] = sub.list.multi[i].end; + } + + if (reg_startpos[0].lnum < 0) +*************** +*** 3949,3956 **** + { + for (i = 0; i < sub.in_use; i++) + { +! reg_startp[i] = sub.linelist[i].start; +! reg_endp[i] = sub.linelist[i].end; + } + + if (reg_startp[0] == NULL) +--- 3950,3957 ---- + { + for (i = 0; i < sub.in_use; i++) + { +! reg_startp[i] = sub.list.line[i].start; +! reg_endp[i] = sub.list.line[i].end; + } + + if (reg_startp[0] == NULL) +*** ../vim-7.3.1035/src/version.c 2013-05-28 22:31:43.000000000 +0200 +--- src/version.c 2013-05-28 22:37:01.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1036, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +9. All your daydreaming is preoccupied with getting a faster connection to the + net: 28.8...ISDN...cable modem...T1...T3. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 34ad50efef450065c89a2f2f5a08f7f72074fa6f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:13 +0200 Subject: [PATCH 0928/3340] - patchlevel 1037 --- 7.3.1037 | 408 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 408 insertions(+) create mode 100644 7.3.1037 diff --git a/7.3.1037 b/7.3.1037 new file mode 100644 index 00000000..994134d3 --- /dev/null +++ b/7.3.1037 @@ -0,0 +1,408 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1037 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1037 +Problem: Look-behind matching is very slow on long lines. +Solution: Add a byte limit to how far back an attempt is made. +Files: src/regexp.c, src/regexp_nfa.c, src/testdir/test64.in, + src/testdir/test64.ok + + +*** ../vim-7.3.1036/src/regexp.c 2013-05-21 21:37:01.000000000 +0200 +--- src/regexp.c 2013-05-29 14:34:51.000000000 +0200 +*************** +*** 701,706 **** +--- 701,707 ---- + # define CASEMBC(x) + #endif + static void reginsert __ARGS((int, char_u *)); ++ static void reginsert_nr __ARGS((int op, long val, char_u *opnd)); + static void reginsert_limits __ARGS((int, long, long, char_u *)); + static char_u *re_put_long __ARGS((char_u *pr, long_u val)); + static int read_limits __ARGS((long *, long *)); +*************** +*** 1781,1787 **** +--- 1782,1790 ---- + case Magic('@'): + { + int lop = END; ++ int nr; + ++ nr = getdecchrs(); + switch (no_Magic(getchr())) + { + case '=': lop = MATCH; break; /* \@= */ +*************** +*** 1803,1809 **** + *flagp |= HASLOOKBH; + } + regtail(ret, regnode(END)); /* operand ends */ +! reginsert(lop, ret); + break; + } + +--- 1806,1819 ---- + *flagp |= HASLOOKBH; + } + regtail(ret, regnode(END)); /* operand ends */ +! if (lop == BEHIND || lop == NOBEHIND) +! { +! if (nr < 0) +! nr = 0; /* no limit is same as zero limit */ +! reginsert_nr(lop, nr, ret); +! } +! else +! reginsert(lop, ret); + break; + } + +*************** +*** 2780,2785 **** +--- 2790,2827 ---- + + /* + * Insert an operator in front of already-emitted operand. ++ * Add a number to the operator. ++ */ ++ static void ++ reginsert_nr(op, val, opnd) ++ int op; ++ long val; ++ char_u *opnd; ++ { ++ char_u *src; ++ char_u *dst; ++ char_u *place; ++ ++ if (regcode == JUST_CALC_SIZE) ++ { ++ regsize += 7; ++ return; ++ } ++ src = regcode; ++ regcode += 7; ++ dst = regcode; ++ while (src > opnd) ++ *--dst = *--src; ++ ++ place = opnd; /* Op node, where operand used to be. */ ++ *place++ = op; ++ *place++ = NUL; ++ *place++ = NUL; ++ place = re_put_long(place, (long_u)val); ++ } ++ ++ /* ++ * Insert an operator in front of already-emitted operand. + * The operator has the given limit values as operands. Also set next pointer. + * + * Means relocating the operand. +*************** +*** 3182,3188 **** + } + + /* +! * get and return the value of the decimal string immediately after the + * current position. Return -1 for invalid. Consumes all digits. + */ + static int +--- 3224,3230 ---- + } + + /* +! * Get and return the value of the decimal string immediately after the + * current position. Return -1 for invalid. Consumes all digits. + */ + static int +*************** +*** 3200,3205 **** +--- 3242,3248 ---- + nr *= 10; + nr += c - '0'; + ++regparse; ++ curchr = -1; /* no longer valid */ + } + + if (i == 0) +*************** +*** 5432,5438 **** + /* save the position after the found match for next */ + reg_save(&(((regbehind_T *)rp) - 1)->save_after, &backpos); + +! /* start looking for a match with operand at the current + * position. Go back one character until we find the + * result, hitting the start of the line or the previous + * line (for multi-line matching). +--- 5475,5481 ---- + /* save the position after the found match for next */ + reg_save(&(((regbehind_T *)rp) - 1)->save_after, &backpos); + +! /* Start looking for a match with operand at the current + * position. Go back one character until we find the + * result, hitting the start of the line or the previous + * line (for multi-line matching). +*************** +*** 5444,5450 **** + rp->rs_state = RS_BEHIND2; + + reg_restore(&rp->rs_un.regsave, &backpos); +! scan = OPERAND(rp->rs_scan); + } + break; + +--- 5487,5493 ---- + rp->rs_state = RS_BEHIND2; + + reg_restore(&rp->rs_un.regsave, &backpos); +! scan = OPERAND(rp->rs_scan) + 4; + } + break; + +*************** +*** 5472,5480 **** +--- 5515,5526 ---- + } + else + { ++ long limit; ++ + /* No match or a match that doesn't end where we want it: Go + * back one character. May go to previous line once. */ + no = OK; ++ limit = OPERAND_MIN(rp->rs_scan); + if (REG_MULTI) + { + if (rp->rs_un.regsave.rs_u.pos.col == 0) +*************** +*** 5493,5519 **** + } + } + else + #ifdef FEAT_MBYTE +! if (has_mbyte) +! rp->rs_un.regsave.rs_u.pos.col -= +! (*mb_head_off)(regline, regline + + rp->rs_un.regsave.rs_u.pos.col - 1) + 1; +! else + #endif +! --rp->rs_un.regsave.rs_u.pos.col; + } + else + { + if (rp->rs_un.regsave.rs_u.ptr == regline) + no = FAIL; + else +! --rp->rs_un.regsave.rs_u.ptr; + } + if (no == OK) + { + /* Advanced, prepare for finding match again. */ + reg_restore(&rp->rs_un.regsave, &backpos); +! scan = OPERAND(rp->rs_scan); + if (status == RA_MATCH) + { + /* We did match, so subexpr may have been changed, +--- 5539,5579 ---- + } + } + else ++ { + #ifdef FEAT_MBYTE +! if (has_mbyte) +! rp->rs_un.regsave.rs_u.pos.col -= +! (*mb_head_off)(regline, regline + + rp->rs_un.regsave.rs_u.pos.col - 1) + 1; +! else + #endif +! --rp->rs_un.regsave.rs_u.pos.col; +! if (limit > 0 +! && ((rp->rs_un.regsave.rs_u.pos.lnum +! < behind_pos.rs_u.pos.lnum +! ? (colnr_T)STRLEN(regline) +! : behind_pos.rs_u.pos.col) +! - rp->rs_un.regsave.rs_u.pos.col > limit)) +! no = FAIL; +! } + } + else + { + if (rp->rs_un.regsave.rs_u.ptr == regline) + no = FAIL; + else +! { +! mb_ptr_back(regline, rp->rs_un.regsave.rs_u.ptr); +! if (limit > 0 && (long)(behind_pos.rs_u.ptr +! - rp->rs_un.regsave.rs_u.ptr) > limit) +! no = FAIL; +! } + } + if (no == OK) + { + /* Advanced, prepare for finding match again. */ + reg_restore(&rp->rs_un.regsave, &backpos); +! scan = OPERAND(rp->rs_scan) + 4; + if (status == RA_MATCH) + { + /* We did match, so subexpr may have been changed, +*************** +*** 7773,7779 **** + #ifdef DEBUG + static char_u regname[][30] = { + "AUTOMATIC Regexp Engine", +! "BACKTACKING Regexp Engine", + "NFA Regexp Engine" + }; + #endif +--- 7833,7839 ---- + #ifdef DEBUG + static char_u regname[][30] = { + "AUTOMATIC Regexp Engine", +! "BACKTRACKING Regexp Engine", + "NFA Regexp Engine" + }; + #endif +*** ../vim-7.3.1036/src/regexp_nfa.c 2013-05-28 22:52:11.000000000 +0200 +--- src/regexp_nfa.c 2013-05-29 16:31:13.000000000 +0200 +*************** +*** 1331,1336 **** +--- 1331,1346 ---- + case '=': + EMIT(NFA_PREV_ATOM_NO_WIDTH); + break; ++ case '0': ++ case '1': ++ case '2': ++ case '3': ++ case '4': ++ case '5': ++ case '6': ++ case '7': ++ case '8': ++ case '9': + case '!': + case '<': + case '>': +*************** +*** 3817,3823 **** + * because recursive calls should only start in the first position. + * Also don't start a match past the first line. */ + if (nfa_match == FALSE && start->c == NFA_MOPEN + 0 +! && reglnum == 0 && clen != 0) + { + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); +--- 3827,3835 ---- + * because recursive calls should only start in the first position. + * Also don't start a match past the first line. */ + if (nfa_match == FALSE && start->c == NFA_MOPEN + 0 +! && reglnum == 0 && clen != 0 +! && (ireg_maxcol == 0 +! || (colnr_T)(reginput - regline) < ireg_maxcol)) + { + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); +*** ../vim-7.3.1036/src/testdir/test64.in 2013-05-28 22:03:13.000000000 +0200 +--- src/testdir/test64.in 2013-05-29 14:56:44.000000000 +0200 +*************** +*** 336,341 **** +--- 336,349 ---- + :"call add(tl, [2, '\(\i\+\) \1', 'xgoo goox', 'goo goo', 'goo']) + :call add(tl, [2, '\(a\)\(b\)\(c\)\(dd\)\(e\)\(f\)\(g\)\(h\)\(i\)\1\2\3\4\5\6\7\8\9', 'xabcddefghiabcddefghix', 'abcddefghiabcddefghi', 'a', 'b', 'c', 'dd', 'e', 'f', 'g', 'h', 'i']) + :" ++ :"""" Look-behind with limit ++ :call add(tl, [0, '<\@<=span.', 'xxspanxxTa 5 + Ac 7 + ghi ++ ++ xxxstart3 +*** ../vim-7.3.1036/src/version.c 2013-05-28 22:52:11.000000000 +0200 +--- src/version.c 2013-05-29 13:20:48.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1037, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +11. You find yourself typing "com" after every period when using a word + processor.com + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7ca41a4537c75e8ae8839148d0885dfe8833ba43 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:13 +0200 Subject: [PATCH 0929/3340] - patchlevel 1038 --- 7.3.1038 | 134 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 134 insertions(+) create mode 100644 7.3.1038 diff --git a/7.3.1038 b/7.3.1038 new file mode 100644 index 00000000..468ef46a --- /dev/null +++ b/7.3.1038 @@ -0,0 +1,134 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1038 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1038 +Problem: Crash when using Cscope. +Solution: Avoid negative argument to vim_strncpy(). (Narendran + Gopalakrishnan) +Files: src/if_cscope.c + + +*** ../vim-7.3.1037/src/if_cscope.c 2013-05-06 04:21:35.000000000 +0200 +--- src/if_cscope.c 2013-05-29 19:12:55.000000000 +0200 +*************** +*** 2460,2472 **** + /* + * PRIVATE: cs_resolve_file + * +! * construct the full pathname to a file found in the cscope database. + * (Prepends ppath, if there is one and if it's not already prepended, + * otherwise just uses the name found.) + * +! * we need to prepend the prefix because on some cscope's (e.g., the one that + * ships with Solaris 2.6), the output never has the prefix prepended. +! * contrast this with my development system (Digital Unix), which does. + */ + static char * + cs_resolve_file(i, name) +--- 2460,2472 ---- + /* + * PRIVATE: cs_resolve_file + * +! * Construct the full pathname to a file found in the cscope database. + * (Prepends ppath, if there is one and if it's not already prepended, + * otherwise just uses the name found.) + * +! * We need to prepend the prefix because on some cscope's (e.g., the one that + * ships with Solaris 2.6), the output never has the prefix prepended. +! * Contrast this with my development system (Digital Unix), which does. + */ + static char * + cs_resolve_file(i, name) +*************** +*** 2493,2506 **** + if (csdir != NULL) + { + vim_strncpy(csdir, (char_u *)csinfo[i].fname, +! gettail((char_u *)csinfo[i].fname) - 1 - (char_u *)csinfo[i].fname); + len += (int)STRLEN(csdir); + } + } + +- if ((fullname = (char *)alloc(len)) == NULL) +- return NULL; +- + /* Note/example: this won't work if the cscope output already starts + * "../.." and the prefix path is also "../..". if something like this + * happens, you are screwed up and need to fix how you're using cscope. */ +--- 2493,2504 ---- + if (csdir != NULL) + { + vim_strncpy(csdir, (char_u *)csinfo[i].fname, +! gettail((char_u *)csinfo[i].fname) +! - (char_u *)csinfo[i].fname); + len += (int)STRLEN(csdir); + } + } + + /* Note/example: this won't work if the cscope output already starts + * "../.." and the prefix path is also "../..". if something like this + * happens, you are screwed up and need to fix how you're using cscope. */ +*************** +*** 2511,2526 **** + && name[0] != '\\' && name[1] != ':' + #endif + ) +! (void)sprintf(fullname, "%s/%s", csinfo[i].ppath, name); +! else if (csdir != NULL && csinfo[i].fname != NULL && STRLEN(csdir) > 0) + { + /* Check for csdir to be non empty to avoid empty path concatenated to +! * cscope output. TODO: avoid the unnecessary alloc/free of fullname. */ +! vim_free(fullname); + fullname = (char *)concat_fnames(csdir, (char_u *)name, TRUE); + } + else +! (void)sprintf(fullname, "%s", name); + + vim_free(csdir); + return fullname; +--- 2509,2528 ---- + && name[0] != '\\' && name[1] != ':' + #endif + ) +! { +! if ((fullname = (char *)alloc(len)) != NULL) +! (void)sprintf(fullname, "%s/%s", csinfo[i].ppath, name); +! } +! else if (csdir != NULL && csinfo[i].fname != NULL && *csdir != NUL) + { + /* Check for csdir to be non empty to avoid empty path concatenated to +! * cscope output. */ + fullname = (char *)concat_fnames(csdir, (char_u *)name, TRUE); + } + else +! { +! fullname = (char *)vim_strsave((char_u *)name); +! } + + vim_free(csdir); + return fullname; +*** ../vim-7.3.1037/src/version.c 2013-05-29 18:45:07.000000000 +0200 +--- src/version.c 2013-05-29 19:17:16.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1038, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +12. You turn off your modem and get this awful empty feeling, like you just + pulled the plug on a loved one. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4013be1ad13f2afb83134934f5af2d12fe24b0fe Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:14 +0200 Subject: [PATCH 0930/3340] - patchlevel 1039 --- 7.3.1039 | 380 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 380 insertions(+) create mode 100644 7.3.1039 diff --git a/7.3.1039 b/7.3.1039 new file mode 100644 index 00000000..d41cb42c --- /dev/null +++ b/7.3.1039 @@ -0,0 +1,380 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1039 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1039 +Problem: New regexp engine does not support \%23c, \%<23c and the like. +Solution: Implement them. (partly by Yasuhiro Matsumoto) +Files: src/regexp.h, src/regexp_nfa.c, src/testdir/test64.in, + src/testdir/test64.ok + + +*** ../vim-7.3.1038/src/regexp.h 2013-05-28 22:03:13.000000000 +0200 +--- src/regexp.h 2013-05-29 20:35:35.000000000 +0200 +*************** +*** 72,77 **** +--- 72,78 ---- + int id; + int lastlist; + int negated; ++ int val; + }; + + /* +*** ../vim-7.3.1038/src/regexp_nfa.c 2013-05-29 18:45:07.000000000 +0200 +--- src/regexp_nfa.c 2013-05-29 20:59:34.000000000 +0200 +*************** +*** 117,122 **** +--- 117,134 ---- + NFA_NLOWER, /* Match non-lowercase char */ + NFA_UPPER, /* Match uppercase char */ + NFA_NUPPER, /* Match non-uppercase char */ ++ ++ NFA_CURSOR, /* Match cursor pos */ ++ NFA_LNUM, /* Match line number */ ++ NFA_LNUM_GT, /* Match > line number */ ++ NFA_LNUM_LT, /* Match < line number */ ++ NFA_COL, /* Match cursor column */ ++ NFA_COL_GT, /* Match > cursor column */ ++ NFA_COL_LT, /* Match < cursor column */ ++ NFA_VCOL, /* Match cursor virtual column */ ++ NFA_VCOL_GT, /* Match > cursor virtual column */ ++ NFA_VCOL_LT, /* Match < cursor virtual column */ ++ + NFA_FIRST_NL = NFA_ANY + ADD_NL, + NFA_LAST_NL = NFA_NUPPER + ADD_NL, + +*************** +*** 205,214 **** + static nfa_state_T *post2nfa __ARGS((int *postfix, int *end, int nfa_calc_size)); + static int check_char_class __ARGS((int class, int c)); + static void st_error __ARGS((int *postfix, int *end, int *p)); + static void nfa_save_listids __ARGS((nfa_state_T *start, int *list)); + static void nfa_restore_listids __ARGS((nfa_state_T *start, int *list)); +! static void nfa_set_null_listids __ARGS((nfa_state_T *start)); +! static void nfa_set_neg_listids __ARGS((nfa_state_T *start)); + static long nfa_regtry __ARGS((nfa_state_T *start, colnr_T col)); + static long nfa_regexec_both __ARGS((char_u *line, colnr_T col)); + static regprog_T *nfa_regcomp __ARGS((char_u *expr, int re_flags)); +--- 217,227 ---- + static nfa_state_T *post2nfa __ARGS((int *postfix, int *end, int nfa_calc_size)); + static int check_char_class __ARGS((int class, int c)); + static void st_error __ARGS((int *postfix, int *end, int *p)); ++ static void nfa_set_neg_listids __ARGS((nfa_state_T *start)); ++ static void nfa_set_null_listids __ARGS((nfa_state_T *start)); + static void nfa_save_listids __ARGS((nfa_state_T *start, int *list)); + static void nfa_restore_listids __ARGS((nfa_state_T *start, int *list)); +! static int nfa_re_num_cmp __ARGS((long_u val, int op, long_u pos)); + static long nfa_regtry __ARGS((nfa_state_T *start, colnr_T col)); + static long nfa_regexec_both __ARGS((char_u *line, colnr_T col)); + static regprog_T *nfa_regcomp __ARGS((char_u *expr, int re_flags)); +*************** +*** 831,838 **** + break; + + case '#': +! /* TODO: not supported yet */ +! return FAIL; + break; + + case 'V': +--- 844,850 ---- + break; + + case '#': +! EMIT(NFA_CURSOR); + break; + + case 'V': +*************** +*** 844,866 **** + /* TODO: \%[abc] not supported yet */ + return FAIL; + +- case '0': +- case '1': +- case '2': +- case '3': +- case '4': +- case '5': +- case '6': +- case '7': +- case '8': +- case '9': +- case '<': +- case '>': +- case '\'': +- /* TODO: not supported yet */ +- return FAIL; +- + default: + syntax_error = TRUE; + EMSGN(_("E867: (NFA) Unknown operator '\\%%%c'"), + no_Magic(c)); +--- 856,891 ---- + /* TODO: \%[abc] not supported yet */ + return FAIL; + + default: ++ { ++ long_u n = 0; ++ int cmp = c; ++ ++ if (c == '<' || c == '>') ++ c = getchr(); ++ while (VIM_ISDIGIT(c)) ++ { ++ n = n * 10 + (c - '0'); ++ c = getchr(); ++ } ++ if (c == 'l' || c == 'c' || c == 'v') ++ { ++ EMIT(n); ++ if (c == 'l') ++ EMIT(cmp == '<' ? NFA_LNUM_LT : ++ cmp == '>' ? NFA_LNUM_GT : NFA_LNUM); ++ else if (c == 'c') ++ EMIT(cmp == '<' ? NFA_COL_LT : ++ cmp == '>' ? NFA_COL_GT : NFA_COL); ++ else ++ EMIT(cmp == '<' ? NFA_VCOL_LT : ++ cmp == '>' ? NFA_VCOL_GT : NFA_VCOL); ++ break; ++ } ++ else if (c == '\'') ++ /* TODO: \%'m not supported yet */ ++ return FAIL; ++ } + syntax_error = TRUE; + EMSGN(_("E867: (NFA) Unknown operator '\\%%%c'"), + no_Magic(c)); +*************** +*** 1679,1684 **** +--- 1704,1711 ---- + + case NFA_PREV_ATOM_NO_WIDTH: + STRCPY(code, "NFA_PREV_ATOM_NO_WIDTH"); break; ++ case NFA_PREV_ATOM_NO_WIDTH_NEG: ++ STRCPY(code, "NFA_PREV_ATOM_NO_WIDTH_NEG"); break; + case NFA_NOPEN: STRCPY(code, "NFA_MOPEN_INVISIBLE"); break; + case NFA_NCLOSE: STRCPY(code, "NFA_MCLOSE_INVISIBLE"); break; + case NFA_START_INVISIBLE: STRCPY(code, "NFA_START_INVISIBLE"); break; +*************** +*** 2444,2449 **** +--- 2471,2498 ---- + PUSH(frag(s, list1(&s1->out))); + break; + ++ case NFA_LNUM: ++ case NFA_LNUM_GT: ++ case NFA_LNUM_LT: ++ case NFA_VCOL: ++ case NFA_VCOL_GT: ++ case NFA_VCOL_LT: ++ case NFA_COL: ++ case NFA_COL_GT: ++ case NFA_COL_LT: ++ if (nfa_calc_size == TRUE) ++ { ++ nstate += 1; ++ break; ++ } ++ e1 = POP(); ++ s = new_state(*p, NULL, NULL); ++ if (s == NULL) ++ goto theend; ++ s->val = e1.start->c; ++ PUSH(frag(s, list1(&s->out))); ++ break; ++ + case NFA_ZSTART: + case NFA_ZEND: + default: +*************** +*** 3076,3081 **** +--- 3125,3141 ---- + } + } + ++ static int ++ nfa_re_num_cmp(val, op, pos) ++ long_u val; ++ int op; ++ long_u pos; ++ { ++ if (op == 1) return pos > val; ++ if (op == 2) return pos < val; ++ return val == pos; ++ } ++ + static int nfa_regmatch __ARGS((nfa_state_T *start, regsub_T *submatch, regsub_T *m)); + + /* +*************** +*** 3791,3796 **** +--- 3851,3895 ---- + /* TODO: should not happen? */ + break; + ++ case NFA_LNUM: ++ case NFA_LNUM_GT: ++ case NFA_LNUM_LT: ++ result = (REG_MULTI && ++ nfa_re_num_cmp(t->state->val, t->state->c - NFA_LNUM, ++ (long_u)(reglnum + reg_firstlnum))); ++ if (result) ++ addstate_here(thislist, t->state->out, &t->sub, &listidx); ++ break; ++ ++ case NFA_COL: ++ case NFA_COL_GT: ++ case NFA_COL_LT: ++ result = nfa_re_num_cmp(t->state->val, t->state->c - NFA_COL, ++ (long_u)(reginput - regline) + 1); ++ if (result) ++ addstate_here(thislist, t->state->out, &t->sub, &listidx); ++ break; ++ ++ case NFA_VCOL: ++ case NFA_VCOL_GT: ++ case NFA_VCOL_LT: ++ result = nfa_re_num_cmp(t->state->val, t->state->c - NFA_VCOL, ++ (long_u)win_linetabsize( ++ reg_win == NULL ? curwin : reg_win, ++ regline, (colnr_T)(reginput - regline)) + 1); ++ if (result) ++ addstate_here(thislist, t->state->out, &t->sub, &listidx); ++ break; ++ ++ case NFA_CURSOR: ++ result = (reg_win != NULL ++ && (reglnum + reg_firstlnum == reg_win->w_cursor.lnum) ++ && ((colnr_T)(reginput - regline) ++ == reg_win->w_cursor.col)); ++ if (result) ++ addstate_here(thislist, t->state->out, &t->sub, &listidx); ++ break; ++ + default: /* regular character */ + { + int c = t->state->c; +*** ../vim-7.3.1038/src/testdir/test64.in 2013-05-29 18:45:07.000000000 +0200 +--- src/testdir/test64.in 2013-05-29 21:02:52.000000000 +0200 +*************** +*** 413,425 **** + :.yank + y$Gop:" + :" +- :" + :" Check a pattern with a look beind crossing a line boundary + /^Behind: + /\(<\_[xy]\+\)\@3<=start + :.yank + Gop:" + :" + :/\%#=1^Results/,$wq! test.out + ENDTEST + +--- 413,452 ---- + :.yank + y$Gop:" + :" + :" Check a pattern with a look beind crossing a line boundary + /^Behind: + /\(<\_[xy]\+\)\@3<=start + :.yank + Gop:" + :" ++ :" Check patterns matching cursor position. ++ :func! Postest() ++ new ++ call setline(1, ['ffooooo', 'boboooo', 'zoooooo', 'koooooo', 'moooooo', "\t\t\tfoo", 'abababababababfoo', 'bababababababafoo', '********_']) ++ call setpos('.', [0, 1, 0, 0]) ++ s/\%>3c.//g ++ call setpos('.', [0, 2, 4, 0]) ++ s/\%#.*$//g ++ call setpos('.', [0, 3, 0, 0]) ++ s/\%<3c./_/g ++ %s/\%4l\%>5c./_/g ++ %s/\%6l\%>25v./_/g ++ %s/\%>6l\%3c./!/g ++ %s/\%>7l\%12c./?/g ++ %s/\%>7l\%<9l\%>5v\%<8v./#/g ++ 1,$yank ++ quit! ++ endfunc ++ Go-0-:set re=0 ++ :call Postest() ++ :put ++ o-1-:set re=1 ++ :call Postest() ++ :put ++ o-2-:set re=2 ++ :call Postest() ++ :put ++ :" + :/\%#=1^Results/,$wq! test.out + ENDTEST + +*** ../vim-7.3.1038/src/testdir/test64.ok 2013-05-29 18:45:07.000000000 +0200 +--- src/testdir/test64.ok 2013-05-29 21:02:49.000000000 +0200 +*************** +*** 740,742 **** +--- 740,772 ---- + ghi + + xxxstart3 ++ -0- ++ ffo ++ bob ++ __ooooo ++ koooo__ ++ moooooo ++ f__ ++ ab!babababababfoo ++ ba!ab##abab?bafoo ++ **!*****_ ++ -1- ++ ffo ++ bob ++ __ooooo ++ koooo__ ++ moooooo ++ f__ ++ ab!babababababfoo ++ ba!ab##abab?bafoo ++ **!*****_ ++ -2- ++ ffo ++ bob ++ __ooooo ++ koooo__ ++ moooooo ++ f__ ++ ab!babababababfoo ++ ba!ab##abab?bafoo ++ **!*****_ +*** ../vim-7.3.1038/src/version.c 2013-05-29 19:17:55.000000000 +0200 +--- src/version.c 2013-05-29 21:11:47.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1039, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +16. You step out of your room and realize that your parents have moved and + you don't have a clue when it happened. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From cc2199469b55717035c1983d880c1289730668ad Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:15 +0200 Subject: [PATCH 0931/3340] - patchlevel 1040 --- 7.3.1040 | 298 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 298 insertions(+) create mode 100644 7.3.1040 diff --git a/7.3.1040 b/7.3.1040 new file mode 100644 index 00000000..1a0825d0 --- /dev/null +++ b/7.3.1040 @@ -0,0 +1,298 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1040 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1040 +Problem: Python: Problems with debugging dynamic build. +Solution: Python patch 1. (ZyX) +Files: src/if_python.c, src/if_python3.c + + +*** ../vim-7.3.1039/src/if_python.c 2013-05-21 22:23:51.000000000 +0200 +--- src/if_python.c 2013-05-29 21:32:46.000000000 +0200 +*************** +*** 21,26 **** +--- 21,35 ---- + + #include + ++ /* uncomment this if used with the debug version of python. ++ * Checked on 2.7.4. */ ++ /* #define Py_DEBUG */ ++ /* Note: most of time you can add -DPy_DEBUG to CFLAGS in place of uncommenting ++ */ ++ /* uncomment this if used with the debug version of python, but without its ++ * allocator */ ++ /* #define Py_DEBUG_NO_PYMALLOC */ ++ + /* Python.h defines _POSIX_THREADS itself (if needed) */ + #ifdef _POSIX_THREADS + # undef _POSIX_THREADS +*************** +*** 240,247 **** + # define PyType_IsSubtype dll_PyType_IsSubtype + # endif + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02030000 +! # define PyObject_Malloc dll_PyObject_Malloc +! # define PyObject_Free dll_PyObject_Free + # endif + # ifdef PY_USE_CAPSULE + # define PyCapsule_New dll_PyCapsule_New +--- 249,266 ---- + # define PyType_IsSubtype dll_PyType_IsSubtype + # endif + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02030000 +! # ifdef Py_DEBUG +! # define _Py_NegativeRefcount dll__Py_NegativeRefcount +! # define _Py_RefTotal (*dll__Py_RefTotal) +! # define _Py_Dealloc dll__Py_Dealloc +! # endif +! # if defined(Py_DEBUG) && !defined(Py_DEBUG_NO_PYMALLOC) +! # define _PyObject_DebugMalloc dll__PyObject_DebugMalloc +! # define _PyObject_DebugFree dll__PyObject_DebugFree +! # else +! # define PyObject_Malloc dll_PyObject_Malloc +! # define PyObject_Free dll_PyObject_Free +! # endif + # endif + # ifdef PY_USE_CAPSULE + # define PyCapsule_New dll_PyCapsule_New +*************** +*** 350,357 **** +--- 369,386 ---- + static int (*dll_PyType_IsSubtype)(PyTypeObject *, PyTypeObject *); + # endif + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02030000 ++ # ifdef Py_DEBUG ++ static void (*dll__Py_NegativeRefcount)(const char *fname, int lineno, PyObject *op); ++ static Py_ssize_t* dll__Py_RefTotal; ++ static void (*dll__Py_Dealloc)(PyObject *obj); ++ # endif ++ # if defined(Py_DEBUG) && !defined(Py_DEBUG_NO_PYMALLOC) ++ static void (*dll__PyObject_DebugFree)(void*); ++ static void* (*dll__PyObject_DebugMalloc)(size_t); ++ # else + static void* (*dll_PyObject_Malloc)(size_t); + static void (*dll_PyObject_Free)(void*); ++ # endif + # endif + # ifdef PY_USE_CAPSULE + static PyObject* (*dll_PyCapsule_New)(void *, char *, PyCapsule_Destructor); +*************** +*** 469,480 **** + {"PyType_Type", (PYTHON_PROC*)&dll_PyType_Type}, + {"PyType_Ready", (PYTHON_PROC*)&dll_PyType_Ready}, + {"Py_FindMethod", (PYTHON_PROC*)&dll_Py_FindMethod}, +- # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02050000 \ +- && SIZEOF_SIZE_T != SIZEOF_INT +- {"Py_InitModule4_64", (PYTHON_PROC*)&dll_Py_InitModule4}, +- # else +- {"Py_InitModule4", (PYTHON_PROC*)&dll_Py_InitModule4}, +- # endif + {"Py_SetPythonHome", (PYTHON_PROC*)&dll_Py_SetPythonHome}, + {"Py_Initialize", (PYTHON_PROC*)&dll_Py_Initialize}, + {"Py_Finalize", (PYTHON_PROC*)&dll_Py_Finalize}, +--- 498,503 ---- +*************** +*** 496,503 **** +--- 519,550 ---- + {"PyType_IsSubtype", (PYTHON_PROC*)&dll_PyType_IsSubtype}, + # endif + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02030000 ++ # ifdef Py_DEBUG ++ {"_Py_NegativeRefcount", (PYTHON_PROC*)&dll__Py_NegativeRefcount}, ++ {"_Py_RefTotal", (PYTHON_PROC*)&dll__Py_RefTotal}, ++ {"_Py_Dealloc", (PYTHON_PROC*)&dll__Py_Dealloc}, ++ # endif ++ # if defined(Py_DEBUG) && !defined(Py_DEBUG_NO_PYMALLOC) ++ {"_PyObject_DebugFree", (PYTHON_PROC*)&dll__PyObject_DebugFree}, ++ {"_PyObject_DebugMalloc", (PYTHON_PROC*)&dll__PyObject_DebugMalloc}, ++ # else + {"PyObject_Malloc", (PYTHON_PROC*)&dll_PyObject_Malloc}, + {"PyObject_Free", (PYTHON_PROC*)&dll_PyObject_Free}, ++ # endif ++ # endif ++ # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02050000 \ ++ && SIZEOF_SIZE_T != SIZEOF_INT ++ # ifdef Py_DEBUG ++ {"Py_InitModule4TraceRefs_64", (PYTHON_PROC*)&dll_Py_InitModule4}, ++ # else ++ {"Py_InitModule4_64", (PYTHON_PROC*)&dll_Py_InitModule4}, ++ # endif ++ # else ++ # ifdef Py_DEBUG ++ {"Py_InitModule4TraceRefs", (PYTHON_PROC*)&dll_Py_InitModule4}, ++ # else ++ {"Py_InitModule4", (PYTHON_PROC*)&dll_Py_InitModule4}, ++ # endif + # endif + # ifdef PY_USE_CAPSULE + {"PyCapsule_New", (PYTHON_PROC*)&dll_PyCapsule_New}, +*** ../vim-7.3.1039/src/if_python3.c 2013-05-21 22:23:51.000000000 +0200 +--- src/if_python3.c 2013-05-29 21:32:46.000000000 +0200 +*************** +*** 24,29 **** +--- 24,34 ---- + + /* uncomment this if used with the debug version of python */ + /* #define Py_DEBUG */ ++ /* Note: most of time you can add -DPy_DEBUG to CFLAGS in place of uncommenting ++ */ ++ /* uncomment this if used with the debug version of python, but without its ++ * allocator */ ++ /* #define Py_DEBUG_NO_PYMALLOC */ + + #include "vim.h" + +*************** +*** 207,212 **** +--- 212,222 ---- + # define _Py_NegativeRefcount py3__Py_NegativeRefcount + # define _Py_RefTotal (*py3__Py_RefTotal) + # define _Py_Dealloc py3__Py_Dealloc ++ # define PyModule_Create2TraceRefs py3_PyModule_Create2TraceRefs ++ # else ++ # define PyModule_Create2 py3_PyModule_Create2 ++ # endif ++ # if defined(Py_DEBUG) && !defined(Py_DEBUG_NO_PYMALLOC) + # define _PyObject_DebugMalloc py3__PyObject_DebugMalloc + # define _PyObject_DebugFree py3__PyObject_DebugFree + # else +*************** +*** 218,224 **** + # define PyObject_GC_UnTrack py3_PyObject_GC_UnTrack + # define PyType_GenericAlloc py3_PyType_GenericAlloc + # define PyType_GenericNew py3_PyType_GenericNew +- # define PyModule_Create2 py3_PyModule_Create2 + # undef PyUnicode_FromString + # define PyUnicode_FromString py3_PyUnicode_FromString + # undef PyUnicode_Decode +--- 228,233 ---- +*************** +*** 227,233 **** + # define PyCapsule_New py3_PyCapsule_New + # define PyCapsule_GetPointer py3_PyCapsule_GetPointer + +! # ifdef Py_DEBUG + # undef PyObject_NEW + # define PyObject_NEW(type, typeobj) \ + ( (type *) PyObject_Init( \ +--- 236,242 ---- + # define PyCapsule_New py3_PyCapsule_New + # define PyCapsule_GetPointer py3_PyCapsule_GetPointer + +! # if defined(Py_DEBUG) && !defined(Py_DEBUG_NO_PYMALLOC) + # undef PyObject_NEW + # define PyObject_NEW(type, typeobj) \ + ( (type *) PyObject_Init( \ +*************** +*** 317,323 **** + static PyObject* (*py3_PyFloat_FromDouble)(double num); + static double (*py3_PyFloat_AsDouble)(PyObject *); + static PyObject* (*py3_PyObject_GenericGetAttr)(PyObject *obj, PyObject *name); +- static PyObject* (*py3_PyModule_Create2)(struct PyModuleDef* module, int module_api_version); + static PyObject* (*py3_PyType_GenericAlloc)(PyTypeObject *type, Py_ssize_t nitems); + static PyObject* (*py3_PyType_GenericNew)(PyTypeObject *type, PyObject *args, PyObject *kwds); + static PyTypeObject* py3_PyType_Type; +--- 326,331 ---- +*************** +*** 328,341 **** + static PyObject* (*py3_PyCapsule_New)(void *, char *, PyCapsule_Destructor); + static void* (*py3_PyCapsule_GetPointer)(PyObject *, char *); + # ifdef Py_DEBUG +! static void (*py3__Py_NegativeRefcount)(const char *fname, int lineno, PyObject *op); +! static Py_ssize_t* py3__Py_RefTotal; +! static void (*py3__Py_Dealloc)(PyObject *obj); +! static void (*py3__PyObject_DebugFree)(void*); +! static void* (*py3__PyObject_DebugMalloc)(size_t); + # else +! static void (*py3_PyObject_Free)(void*); +! static void* (*py3_PyObject_Malloc)(size_t); + # endif + static PyObject*(*py3__PyObject_GC_New)(PyTypeObject *); + static void(*py3_PyObject_GC_Del)(void *); +--- 336,354 ---- + static PyObject* (*py3_PyCapsule_New)(void *, char *, PyCapsule_Destructor); + static void* (*py3_PyCapsule_GetPointer)(PyObject *, char *); + # ifdef Py_DEBUG +! static void (*py3__Py_NegativeRefcount)(const char *fname, int lineno, PyObject *op); +! static Py_ssize_t* py3__Py_RefTotal; +! static void (*py3__Py_Dealloc)(PyObject *obj); +! static PyObject* (*py3_PyModule_Create2TraceRefs)(struct PyModuleDef* module, int module_api_version); +! # else +! static PyObject* (*py3_PyModule_Create2)(struct PyModuleDef* module, int module_api_version); +! # endif +! # if defined(Py_DEBUG) && !defined(Py_DEBUG_NO_PYMALLOC) +! static void (*py3__PyObject_DebugFree)(void*); +! static void* (*py3__PyObject_DebugMalloc)(size_t); + # else +! static void (*py3_PyObject_Free)(void*); +! static void* (*py3_PyObject_Malloc)(size_t); + # endif + static PyObject*(*py3__PyObject_GC_New)(PyTypeObject *); + static void(*py3_PyObject_GC_Del)(void *); +*************** +*** 451,457 **** + {"PyFloat_FromDouble", (PYTHON_PROC*)&py3_PyFloat_FromDouble}, + {"PyFloat_AsDouble", (PYTHON_PROC*)&py3_PyFloat_AsDouble}, + {"PyObject_GenericGetAttr", (PYTHON_PROC*)&py3_PyObject_GenericGetAttr}, +- {"PyModule_Create2", (PYTHON_PROC*)&py3_PyModule_Create2}, + {"PyType_GenericAlloc", (PYTHON_PROC*)&py3_PyType_GenericAlloc}, + {"PyType_GenericNew", (PYTHON_PROC*)&py3_PyType_GenericNew}, + {"PyType_Type", (PYTHON_PROC*)&py3_PyType_Type}, +--- 464,469 ---- +*************** +*** 463,468 **** +--- 475,485 ---- + {"_Py_NegativeRefcount", (PYTHON_PROC*)&py3__Py_NegativeRefcount}, + {"_Py_RefTotal", (PYTHON_PROC*)&py3__Py_RefTotal}, + {"_Py_Dealloc", (PYTHON_PROC*)&py3__Py_Dealloc}, ++ {"PyModule_Create2TraceRefs", (PYTHON_PROC*)&py3_PyModule_Create2TraceRefs}, ++ # else ++ {"PyModule_Create2", (PYTHON_PROC*)&py3_PyModule_Create2}, ++ # endif ++ # if defined(Py_DEBUG) && !defined(Py_DEBUG_NO_PYMALLOC) + {"_PyObject_DebugFree", (PYTHON_PROC*)&py3__PyObject_DebugFree}, + {"_PyObject_DebugMalloc", (PYTHON_PROC*)&py3__PyObject_DebugMalloc}, + # else +*************** +*** 656,662 **** + static void + call_PyObject_Free(void *p) + { +! #ifdef Py_DEBUG + _PyObject_DebugFree(p); + #else + PyObject_Free(p); +--- 673,679 ---- + static void + call_PyObject_Free(void *p) + { +! #if defined(Py_DEBUG) && !defined(Py_DEBUG_NO_PYMALLOC) + _PyObject_DebugFree(p); + #else + PyObject_Free(p); +*** ../vim-7.3.1039/src/version.c 2013-05-29 21:14:37.000000000 +0200 +--- src/version.c 2013-05-29 21:32:32.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1040, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +17. You turn on your intercom when leaving the room so you can hear if new + e-mail arrives. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 03507a5e8d9afd0b1573d7dd112defe067cb5ea2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:15 +0200 Subject: [PATCH 0932/3340] - patchlevel 1041 --- 7.3.1041 | 179 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 179 insertions(+) create mode 100644 7.3.1041 diff --git a/7.3.1041 b/7.3.1041 new file mode 100644 index 00000000..e0a9f9cb --- /dev/null +++ b/7.3.1041 @@ -0,0 +1,179 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1041 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1041 +Problem: Python: Invalid read valgrind errors. +Solution: Python patch 2: defer DICTKEY_UNREF until key is no longer needed. + (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1040/src/if_py_both.h 2013-05-28 22:31:43.000000000 +0200 +--- src/if_py_both.h 2013-05-29 21:36:29.000000000 +0200 +*************** +*** 1603,1613 **** + flags = get_option_value_strict(key, NULL, NULL, + self->opt_type, self->from); + +- DICTKEY_UNREF +- + if (flags == 0) + { + PyErr_SetObject(PyExc_KeyError, keyObject); + return -1; + } + +--- 1603,1612 ---- + flags = get_option_value_strict(key, NULL, NULL, + self->opt_type, self->from); + + if (flags == 0) + { + PyErr_SetObject(PyExc_KeyError, keyObject); ++ DICTKEY_UNREF + return -1; + } + +*************** +*** 1617,1633 **** +--- 1616,1635 ---- + { + PyErr_SetString(PyExc_ValueError, + _("unable to unset global option")); ++ DICTKEY_UNREF + return -1; + } + else if (!(flags & SOPT_GLOBAL)) + { + PyErr_SetString(PyExc_ValueError, _("unable to unset option " + "without global value")); ++ DICTKEY_UNREF + return -1; + } + else + { + unset_global_local_option(key, self->from); ++ DICTKEY_UNREF + return 0; + } + } +*************** +*** 1639,1647 **** + int istrue = PyObject_IsTrue(valObject); + + if (istrue == -1) +! return -1; +! r = set_option_value_for(key, istrue, NULL, +! opt_flags, self->opt_type, self->from); + } + else if (flags & SOPT_NUM) + { +--- 1641,1650 ---- + int istrue = PyObject_IsTrue(valObject); + + if (istrue == -1) +! r = -1; +! else +! r = set_option_value_for(key, istrue, NULL, +! opt_flags, self->opt_type, self->from); + } + else if (flags & SOPT_NUM) + { +*************** +*** 1657,1662 **** +--- 1660,1666 ---- + else + { + PyErr_SetString(PyExc_TypeError, _("object must be integer")); ++ DICTKEY_UNREF + return -1; + } + +*************** +*** 1670,1678 **** +--- 1674,1688 ---- + { + + if (PyString_AsStringAndSize(valObject, (char **) &val, NULL) == -1) ++ { ++ DICTKEY_UNREF + return -1; ++ } + if (val == NULL) ++ { ++ DICTKEY_UNREF + return -1; ++ } + + val = vim_strsave(val); + } +*************** +*** 1682,1693 **** +--- 1692,1712 ---- + + bytes = PyUnicode_AsEncodedString(valObject, (char *)ENC_OPT, NULL); + if (bytes == NULL) ++ { ++ DICTKEY_UNREF + return -1; ++ } + + if(PyString_AsStringAndSize(bytes, (char **) &val, NULL) == -1) ++ { ++ DICTKEY_UNREF + return -1; ++ } + if (val == NULL) ++ { ++ DICTKEY_UNREF + return -1; ++ } + + val = vim_strsave(val); + Py_XDECREF(bytes); +*************** +*** 1695,1700 **** +--- 1714,1720 ---- + else + { + PyErr_SetString(PyExc_TypeError, _("object must be string")); ++ DICTKEY_UNREF + return -1; + } + +*************** +*** 1703,1708 **** +--- 1723,1730 ---- + vim_free(val); + } + ++ DICTKEY_UNREF ++ + return r; + } + +*** ../vim-7.3.1040/src/version.c 2013-05-29 21:33:34.000000000 +0200 +--- src/version.c 2013-05-29 21:36:47.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1041, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +18. Your wife drapes a blond wig over your monitor to remind you of what she + looks like. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 84ff6f57a3e717e6e31bc1113994e425e3ed2c50 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:16 +0200 Subject: [PATCH 0933/3340] - patchlevel 1042 --- 7.3.1042 | 964 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 964 insertions(+) create mode 100644 7.3.1042 diff --git a/7.3.1042 b/7.3.1042 new file mode 100644 index 00000000..a1d5bbbd --- /dev/null +++ b/7.3.1042 @@ -0,0 +1,964 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1042 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1042 +Problem: Python: can't assign to vim.Buffer.name. +Solution: Python patch 3. (ZyX) +Files: runtime/doc/if_pyth.txt, src/ex_cmds.c, src/if_py_both.h, + src/if_python3.c, src/if_python.c, src/proto/ex_cmds.pro, + src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.1041/runtime/doc/if_pyth.txt 2013-05-21 19:49:58.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-05-29 21:40:05.000000000 +0200 +*************** +*** 250,256 **** + object and always use windows from that tab page (or throw vim.error + in case tab page was deleted). You can keep a reference to both + without keeping a reference to vim module object or |python-tabpage|, +! they will not loose their properties in this case. + + vim.tabpages *python-tabpages* + A sequence object providing access to the list of vim tab pages. The +--- 250,256 ---- + object and always use windows from that tab page (or throw vim.error + in case tab page was deleted). You can keep a reference to both + without keeping a reference to vim module object or |python-tabpage|, +! they will not lose their properties in this case. + + vim.tabpages *python-tabpages* + A sequence object providing access to the list of vim tab pages. The +*************** +*** 361,366 **** +--- 361,371 ---- + this object will raise KeyError. If option is + |global-local| and local value is missing getting it + will return None. ++ b.name String, RW. Contains buffer name (full path). ++ Note: when assigning to b.name |BufFilePre| and ++ |BufFilePost| autocommands are launched. ++ b.number Buffer number. Can be used as |python-buffers| key. ++ Read-only. + + The buffer object methods are: + b.append(str) Append a line to the buffer +*** ../vim-7.3.1041/src/ex_cmds.c 2013-04-14 23:19:32.000000000 +0200 +--- src/ex_cmds.c 2013-05-29 21:44:19.000000000 +0200 +*************** +*** 784,789 **** +--- 784,790 ---- + */ + last_line = curbuf->b_ml.ml_line_count; + mark_adjust(line1, line2, last_line - line2, 0L); ++ changed_lines(last_line - num_lines + 1, 0, last_line + 1, num_lines); + if (dest >= line2) + { + mark_adjust(line2 + 1, dest, -num_lines, 0L); +*************** +*** 799,804 **** +--- 800,806 ---- + curbuf->b_op_start.col = curbuf->b_op_end.col = 0; + mark_adjust(last_line - num_lines + 1, last_line, + -(last_line - dest - extra), 0L); ++ changed_lines(last_line - num_lines + 1, 0, last_line + 1, -extra); + + /* + * Now we delete the original text -- webb +*************** +*** 2414,2419 **** +--- 2416,2473 ---- + info_message = FALSE; + } + ++ int ++ rename_buffer(new_fname) ++ char_u *new_fname; ++ { ++ char_u *fname, *sfname, *xfname; ++ #ifdef FEAT_AUTOCMD ++ buf_T *buf = curbuf; ++ ++ apply_autocmds(EVENT_BUFFILEPRE, NULL, NULL, FALSE, buf); ++ /* buffer changed, don't change name now */ ++ if (buf != curbuf) ++ return FAIL; ++ # ifdef FEAT_EVAL ++ if (aborting()) /* autocmds may abort script processing */ ++ return FAIL; ++ # endif ++ #endif ++ /* ++ * The name of the current buffer will be changed. ++ * A new (unlisted) buffer entry needs to be made to hold the old file ++ * name, which will become the alternate file name. ++ * But don't set the alternate file name if the buffer didn't have a ++ * name. ++ */ ++ fname = buf->b_ffname; ++ sfname = buf->b_sfname; ++ xfname = buf->b_fname; ++ buf->b_ffname = NULL; ++ buf->b_sfname = NULL; ++ if (setfname(buf, new_fname, NULL, TRUE) == FAIL) ++ { ++ buf->b_ffname = fname; ++ buf->b_sfname = sfname; ++ return FAIL; ++ } ++ buf->b_flags |= BF_NOTEDITED; ++ if (xfname != NULL && *xfname != NUL) ++ { ++ buf = buflist_new(fname, xfname, curwin->w_cursor.lnum, 0); ++ if (buf != NULL && !cmdmod.keepalt) ++ curwin->w_alt_fnum = buf->b_fnum; ++ } ++ vim_free(fname); ++ vim_free(sfname); ++ #ifdef FEAT_AUTOCMD ++ apply_autocmds(EVENT_BUFFILEPOST, NULL, NULL, FALSE, buf); ++ #endif ++ /* Change directories when the 'acd' option is set. */ ++ DO_AUTOCHDIR ++ return OK; ++ } ++ + /* + * ":file[!] [fname]". + */ +*************** +*** 2421,2429 **** + ex_file(eap) + exarg_T *eap; + { +- char_u *fname, *sfname, *xfname; +- buf_T *buf; +- + /* ":0file" removes the file name. Check for illegal uses ":3file", + * "0file name", etc. */ + if (eap->addr_count > 0 +--- 2475,2480 ---- +*************** +*** 2437,2485 **** + + if (*eap->arg != NUL || eap->addr_count == 1) + { +! #ifdef FEAT_AUTOCMD +! buf = curbuf; +! apply_autocmds(EVENT_BUFFILEPRE, NULL, NULL, FALSE, curbuf); +! /* buffer changed, don't change name now */ +! if (buf != curbuf) +! return; +! # ifdef FEAT_EVAL +! if (aborting()) /* autocmds may abort script processing */ +! return; +! # endif +! #endif +! /* +! * The name of the current buffer will be changed. +! * A new (unlisted) buffer entry needs to be made to hold the old file +! * name, which will become the alternate file name. +! * But don't set the alternate file name if the buffer didn't have a +! * name. +! */ +! fname = curbuf->b_ffname; +! sfname = curbuf->b_sfname; +! xfname = curbuf->b_fname; +! curbuf->b_ffname = NULL; +! curbuf->b_sfname = NULL; +! if (setfname(curbuf, eap->arg, NULL, TRUE) == FAIL) +! { +! curbuf->b_ffname = fname; +! curbuf->b_sfname = sfname; + return; +- } +- curbuf->b_flags |= BF_NOTEDITED; +- if (xfname != NULL && *xfname != NUL) +- { +- buf = buflist_new(fname, xfname, curwin->w_cursor.lnum, 0); +- if (buf != NULL && !cmdmod.keepalt) +- curwin->w_alt_fnum = buf->b_fnum; +- } +- vim_free(fname); +- vim_free(sfname); +- #ifdef FEAT_AUTOCMD +- apply_autocmds(EVENT_BUFFILEPOST, NULL, NULL, FALSE, curbuf); +- #endif +- /* Change directories when the 'acd' option is set. */ +- DO_AUTOCHDIR + } + /* print full file name if :cd used */ + fileinfo(FALSE, FALSE, eap->forceit); +--- 2488,2495 ---- + + if (*eap->arg != NUL || eap->addr_count == 1) + { +! if (rename_buffer(eap->arg) == FAIL) + return; + } + /* print full file name if :cd used */ + fileinfo(FALSE, FALSE, eap->forceit); +*** ../vim-7.3.1041/src/if_py_both.h 2013-05-29 21:37:29.000000000 +0200 +--- src/if_py_both.h 2013-05-29 21:47:35.000000000 +0200 +*************** +*** 30,35 **** +--- 30,43 ---- + #define INVALID_WINDOW_VALUE ((win_T *)(-1)) + #define INVALID_TABPAGE_VALUE ((tabpage_T *)(-1)) + ++ #define DICTKEY_DECL \ ++ PyObject *dictkey_todecref; ++ #define DICTKEY_GET(err) \ ++ if (!(key = StringToChars(keyObject, &dictkey_todecref))) \ ++ return err; ++ #define DICTKEY_UNREF \ ++ Py_XDECREF(dictkey_todecref); ++ + typedef void (*rangeinitializer)(void *); + typedef void (*runner)(const char *, void * + #ifdef PY_CAN_RECURSE +*************** +*** 64,69 **** +--- 72,122 ---- + { + } + ++ /* ++ * The "todecref" argument holds a pointer to PyObject * that must be ++ * DECREF'ed after returned char_u * is no longer needed or NULL if all what ++ * was needed to generate returned value is object. ++ * ++ * Use Py_XDECREF to decrement reference count. ++ */ ++ static char_u * ++ StringToChars(PyObject *object, PyObject **todecref) ++ { ++ char_u *p; ++ PyObject *bytes = NULL; ++ ++ if (PyBytes_Check(object)) ++ { ++ ++ if (PyString_AsStringAndSize(object, (char **) &p, NULL) == -1) ++ return NULL; ++ if (p == NULL) ++ return NULL; ++ ++ *todecref = NULL; ++ } ++ else if (PyUnicode_Check(object)) ++ { ++ bytes = PyUnicode_AsEncodedString(object, (char *)ENC_OPT, NULL); ++ if (bytes == NULL) ++ return NULL; ++ ++ if(PyString_AsStringAndSize(bytes, (char **) &p, NULL) == -1) ++ return NULL; ++ if (p == NULL) ++ return NULL; ++ ++ *todecref = bytes; ++ } ++ else ++ { ++ PyErr_SetString(PyExc_TypeError, _("object must be string")); ++ return NULL; ++ } ++ ++ return (char_u *) p; ++ } ++ + /* Output buffer management + */ + +*************** +*** 1586,1591 **** +--- 1639,1656 ---- + return VimTryEnd(); + } + ++ static void * ++ py_memsave(void *p, size_t len) ++ { ++ void *r; ++ if (!(r = PyMem_Malloc(len))) ++ return NULL; ++ mch_memmove(r, p, len); ++ return r; ++ } ++ ++ #define PY_STRSAVE(s) ((char_u *) py_memsave(s, STRLEN(s) + 1)) ++ + static int + OptionsAssItem(OptionsObject *self, PyObject *keyObject, PyObject *valObject) + { +*************** +*** 1670,1726 **** + else + { + char_u *val; +! if (PyBytes_Check(valObject)) +! { + +! if (PyString_AsStringAndSize(valObject, (char **) &val, NULL) == -1) +! { +! DICTKEY_UNREF +! return -1; +! } +! if (val == NULL) +! { +! DICTKEY_UNREF +! return -1; +! } +! +! val = vim_strsave(val); +! } +! else if (PyUnicode_Check(valObject)) + { +! PyObject *bytes; +! +! bytes = PyUnicode_AsEncodedString(valObject, (char *)ENC_OPT, NULL); +! if (bytes == NULL) +! { +! DICTKEY_UNREF +! return -1; +! } +! +! if(PyString_AsStringAndSize(bytes, (char **) &val, NULL) == -1) +! { +! DICTKEY_UNREF +! return -1; +! } +! if (val == NULL) +! { +! DICTKEY_UNREF +! return -1; +! } +! +! val = vim_strsave(val); +! Py_XDECREF(bytes); + } + else +! { +! PyErr_SetString(PyExc_TypeError, _("object must be string")); +! DICTKEY_UNREF +! return -1; +! } +! +! r = set_option_value_for(key, 0, val, opt_flags, +! self->opt_type, self->from); +! vim_free(val); + } + + DICTKEY_UNREF +--- 1735,1750 ---- + else + { + char_u *val; +! PyObject *todecref; + +! if ((val = StringToChars(valObject, &todecref))) + { +! r = set_option_value_for(key, 0, val, opt_flags, +! self->opt_type, self->from); +! Py_XDECREF(todecref); + } + else +! r = -1; + } + + DICTKEY_UNREF +*************** +*** 2541,2547 **** + array = NULL; + else + { +! array = (char **)alloc((unsigned)(new_len * sizeof(char *))); + if (array == NULL) + { + PyErr_NoMemory(); +--- 2565,2571 ---- + array = NULL; + else + { +! array = PyMem_New(char *, new_len); + if (array == NULL) + { + PyErr_NoMemory(); +*************** +*** 2558,2564 **** + { + while (i) + vim_free(array[--i]); +! vim_free(array); + return FAIL; + } + } +--- 2582,2588 ---- + { + while (i) + vim_free(array[--i]); +! PyMem_Free(array); + return FAIL; + } + } +*************** +*** 2635,2641 **** + * been dealt with (either freed, or the responsibility passed + * to vim. + */ +! vim_free(array); + + /* Adjust marks. Invalidate any which lie in the + * changed range, and move any in the remainder of the buffer. +--- 2659,2665 ---- + * been dealt with (either freed, or the responsibility passed + * to vim. + */ +! PyMem_Free(array); + + /* Adjust marks. Invalidate any which lie in the + * changed range, and move any in the remainder of the buffer. +*************** +*** 2717,2723 **** + char **array; + buf_T *savebuf; + +! array = (char **)alloc((unsigned)(size * sizeof(char *))); + if (array == NULL) + { + PyErr_NoMemory(); +--- 2741,2747 ---- + char **array; + buf_T *savebuf; + +! array = PyMem_New(char *, size); + if (array == NULL) + { + PyErr_NoMemory(); +*************** +*** 2733,2739 **** + { + while (i) + vim_free(array[--i]); +! vim_free(array); + return FAIL; + } + } +--- 2757,2763 ---- + { + while (i) + vim_free(array[--i]); +! PyMem_Free(array); + return FAIL; + } + } +*************** +*** 2768,2774 **** + /* Free the array of lines. All of its contents have now + * been freed. + */ +! vim_free(array); + + restore_buffer(savebuf); + update_screen(VALID); +--- 2792,2798 ---- + /* Free the array of lines. All of its contents have now + * been freed. + */ +! PyMem_Free(array); + + restore_buffer(savebuf); + update_screen(VALID); +*************** +*** 3179,3184 **** +--- 3203,3247 ---- + return NULL; + } + ++ static int ++ BufferSetattr(BufferObject *self, char *name, PyObject *valObject) ++ { ++ if (CheckBuffer(self)) ++ return -1; ++ ++ if (strcmp(name, "name") == 0) ++ { ++ char_u *val; ++ aco_save_T aco; ++ int r; ++ PyObject *todecref; ++ ++ if (!(val = StringToChars(valObject, &todecref))) ++ return -1; ++ ++ VimTryStart(); ++ /* Using aucmd_*: autocommands will be executed by rename_buffer */ ++ aucmd_prepbuf(&aco, self->buf); ++ r = rename_buffer(val); ++ aucmd_restbuf(&aco); ++ Py_XDECREF(todecref); ++ if (VimTryEnd()) ++ return -1; ++ ++ if (r == FAIL) ++ { ++ PyErr_SetVim(_("failed to rename buffer")); ++ return -1; ++ } ++ return 0; ++ } ++ else ++ { ++ PyErr_SetString(PyExc_AttributeError, name); ++ return -1; ++ } ++ } ++ + static PyObject * + BufferAppend(BufferObject *self, PyObject *args) + { +*************** +*** 4040,4046 **** + if (result == NULL) + return -1; + +! if (set_string_copy(result, tv) == -1) + { + Py_XDECREF(bytes); + return -1; +--- 4103,4109 ---- + if (result == NULL) + return -1; + +! if (set_string_copy(result, tv)) + { + Py_XDECREF(bytes); + return -1; +*************** +*** 4169,4179 **** +--- 4232,4244 ---- + BufferType.tp_methods = BufferMethods; + #if PY_MAJOR_VERSION >= 3 + BufferType.tp_getattro = (getattrofunc)BufferGetattro; ++ BufferType.tp_setattro = (setattrofunc)BufferSetattro; + BufferType.tp_alloc = call_PyType_GenericAlloc; + BufferType.tp_new = call_PyType_GenericNew; + BufferType.tp_free = call_PyObject_Free; + #else + BufferType.tp_getattr = (getattrfunc)BufferGetattr; ++ BufferType.tp_setattr = (setattrfunc)BufferSetattr; + #endif + + vim_memset(&WindowType, 0, sizeof(WindowType)); +*** ../vim-7.3.1041/src/if_python3.c 2013-05-29 21:33:34.000000000 +0200 +--- src/if_python3.c 2013-05-29 21:40:05.000000000 +0200 +*************** +*** 638,669 **** + + #define PYINITIALISED py3initialised + +- #define DICTKEY_DECL PyObject *bytes = NULL; +- +- #define DICTKEY_GET(err) \ +- if (PyBytes_Check(keyObject)) \ +- { \ +- if (PyString_AsStringAndSize(keyObject, (char **) &key, NULL) == -1) \ +- return err; \ +- } \ +- else if (PyUnicode_Check(keyObject)) \ +- { \ +- bytes = PyString_AsBytes(keyObject); \ +- if (bytes == NULL) \ +- return err; \ +- if (PyString_AsStringAndSize(bytes, (char **) &key, NULL) == -1) \ +- return err; \ +- } \ +- else \ +- { \ +- PyErr_SetString(PyExc_TypeError, _("only string keys are allowed")); \ +- return err; \ +- } +- +- #define DICTKEY_UNREF \ +- if (bytes != NULL) \ +- Py_XDECREF(bytes); +- + #define DESTRUCTOR_FINISH(self) Py_TYPE(self)->tp_free((PyObject*)self) + + #define WIN_PYTHON_REF(win) win->w_python3_ref +--- 638,643 ---- +*************** +*** 696,701 **** +--- 670,676 ---- + static PyObject *OutputGetattro(PyObject *, PyObject *); + static int OutputSetattro(PyObject *, PyObject *, PyObject *); + static PyObject *BufferGetattro(PyObject *, PyObject *); ++ static int BufferSetattro(PyObject *, PyObject *, PyObject *); + static PyObject *TabPageGetattro(PyObject *, PyObject *); + static PyObject *WindowGetattro(PyObject *, PyObject *); + static int WindowSetattro(PyObject *, PyObject *, PyObject *); +*************** +*** 1108,1113 **** +--- 1083,1096 ---- + return PyObject_GenericGetAttr(self, nameobj); + } + ++ static int ++ BufferSetattro(PyObject *self, PyObject *nameobj, PyObject *val) ++ { ++ GET_ATTR_STRING(name, nameobj); ++ ++ return BufferSetattr((BufferObject *)(self), name, val); ++ } ++ + static PyObject * + BufferDir(PyObject *self UNUSED) + { +*** ../vim-7.3.1041/src/if_python.c 2013-05-29 21:33:34.000000000 +0200 +--- src/if_python.c 2013-05-29 21:40:05.000000000 +0200 +*************** +*** 676,693 **** + static int initialised = 0; + #define PYINITIALISED initialised + +- #define DICTKEY_GET(err) \ +- if (!PyString_Check(keyObject)) \ +- { \ +- PyErr_SetString(PyExc_TypeError, _("only string keys are allowed")); \ +- return err; \ +- } \ +- if (PyString_AsStringAndSize(keyObject, (char **) &key, NULL) == -1) \ +- return err; +- +- #define DICTKEY_UNREF +- #define DICTKEY_DECL +- + #define DESTRUCTOR_FINISH(self) self->ob_type->tp_free((PyObject*)self); + + #define WIN_PYTHON_REF(win) win->w_python_ref +--- 676,681 ---- +*************** +*** 926,932 **** + else + { + /* Need to make a copy, value may change when setting new locale. */ +! saved_locale = (char *)vim_strsave((char_u *)saved_locale); + (void)setlocale(LC_NUMERIC, "C"); + } + #endif +--- 914,920 ---- + else + { + /* Need to make a copy, value may change when setting new locale. */ +! saved_locale = (char *) PY_STRSAVE(saved_locale); + (void)setlocale(LC_NUMERIC, "C"); + } + #endif +*************** +*** 953,959 **** + if (saved_locale != NULL) + { + (void)setlocale(LC_NUMERIC, saved_locale); +! vim_free(saved_locale); + } + #endif + +--- 941,947 ---- + if (saved_locale != NULL) + { + (void)setlocale(LC_NUMERIC, saved_locale); +! PyMem_Free(saved_locale); + } + #endif + +*** ../vim-7.3.1041/src/proto/ex_cmds.pro 2012-04-25 17:32:14.000000000 +0200 +--- src/proto/ex_cmds.pro 2013-05-29 21:40:05.000000000 +0200 +*************** +*** 19,24 **** +--- 19,25 ---- + void do_fixdel __ARGS((exarg_T *eap)); + void print_line_no_prefix __ARGS((linenr_T lnum, int use_number, int list)); + void print_line __ARGS((linenr_T lnum, int use_number, int list)); ++ int rename_buffer __ARGS((char_u *new_fname)); + void ex_file __ARGS((exarg_T *eap)); + void ex_update __ARGS((exarg_T *eap)); + void ex_write __ARGS((exarg_T *eap)); +*** ../vim-7.3.1041/src/testdir/test86.in 2013-05-21 22:23:51.000000000 +0200 +--- src/testdir/test86.in 2013-05-29 21:56:41.000000000 +0200 +*************** +*** 476,481 **** +--- 476,485 ---- + :py b=vim.current.buffer + :wincmd w + :mark a ++ :augroup BUFS ++ : autocmd BufFilePost * python cb.append(vim.eval('expand("")') + ':BufFilePost:' + vim.eval('bufnr("%")')) ++ : autocmd BufFilePre * python cb.append(vim.eval('expand("")') + ':BufFilePre:' + vim.eval('bufnr("%")')) ++ :augroup END + py << EOF + cb = vim.current.buffer + # Tests BufferAppend and BufferItem +*************** +*** 496,504 **** + b[0]='bar' + b[0:0]=['baz'] + vim.command('call append("$", getbufline(%i, 1, "$"))' % b.number) + # Test CheckBuffer +! vim.command('bwipeout! ' + str(b.number)) +! for expr in ('b[1]','b[:] = ["A", "B"]','b[:]','b.append("abc")'): + try: + exec(expr) + except vim.error: +--- 500,519 ---- + b[0]='bar' + b[0:0]=['baz'] + vim.command('call append("$", getbufline(%i, 1, "$"))' % b.number) ++ # Test assigning to name property ++ old_name = cb.name ++ cb.name = 'foo' ++ cb.append(cb.name[-11:]) ++ b.name = 'bar' ++ cb.append(b.name[-11:]) ++ cb.name = old_name ++ cb.append(cb.name[-17:]) + # Test CheckBuffer +! for _b in vim.buffers: +! if _b is not cb: +! vim.command('bwipeout! ' + str(_b.number)) +! del _b +! for expr in ('b[1]','b[:] = ["A", "B"]','b[:]','b.append("abc")', 'b.name = "!"'): + try: + exec(expr) + except vim.error: +*************** +*** 507,513 **** +--- 522,533 ---- + # Usually a SEGV here + # Should not happen in any case + cb.append('No exception for ' + expr) ++ vim.command('cd .') + EOF ++ :augroup BUFS ++ : autocmd! ++ :augroup END ++ :augroup! BUFS + :" + :" Test vim.buffers object + :set hidden +*************** +*** 586,592 **** + else: + return repr(w) + +! def Cursor(w, start=len(cb)): + if w.buffer is cb: + return repr((start - w.cursor[0], w.cursor[1])) + else: +--- 606,614 ---- + else: + return repr(w) + +! start = len(cb) +! +! def Cursor(w): + if w.buffer is cb: + return repr((start - w.cursor[0], w.cursor[1])) + else: +*** ../vim-7.3.1041/src/testdir/test86.ok 2013-05-21 22:38:14.000000000 +0200 +--- src/testdir/test86.ok 2013-05-29 21:57:30.000000000 +0200 +*************** +*** 319,332 **** + Second line + Third line + foo + i: + i2: + i: + i3: + 1:= +! 6:= +! 7:= +! 8:= + 4 + i4: + i4: +--- 319,341 ---- + Second line + Third line + foo ++ 1:BufFilePre:1 ++ 6:BufFilePost:1 ++ testdir/foo ++ 5:BufFilePre:5 ++ 5:BufFilePost:5 ++ testdir/bar ++ 1:BufFilePre:1 ++ 7:BufFilePost:1 ++ testdir/test86.in + i: + i2: + i: + i3: + 1:= +! 8:= +! 9:= +! 10:= + 4 + i4: + i4: +*************** +*** 335,341 **** + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (27, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +--- 344,350 ---- + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (36, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +*** ../vim-7.3.1041/src/testdir/test87.in 2013-05-21 22:23:51.000000000 +0200 +--- src/testdir/test87.in 2013-05-29 21:58:50.000000000 +0200 +*************** +*** 463,468 **** +--- 463,472 ---- + :py3 b=vim.current.buffer + :wincmd w + :mark a ++ :augroup BUFS ++ : autocmd BufFilePost * python3 cb.append(vim.eval('expand("")') + ':BufFilePost:' + vim.eval('bufnr("%")')) ++ : autocmd BufFilePre * python3 cb.append(vim.eval('expand("")') + ':BufFilePre:' + vim.eval('bufnr("%")')) ++ :augroup END + py3 << EOF + cb = vim.current.buffer + # Tests BufferAppend and BufferItem +*************** +*** 483,490 **** + b[0]='bar' + b[0:0]=['baz'] + vim.command('call append("$", getbufline(%i, 1, "$"))' % b.number) + # Test CheckBuffer +! vim.command('bwipeout! ' + str(b.number)) + for expr in ('b[1]','b[:] = ["A", "B"]','b[:]','b.append("abc")'): + try: + exec(expr) +--- 487,505 ---- + b[0]='bar' + b[0:0]=['baz'] + vim.command('call append("$", getbufline(%i, 1, "$"))' % b.number) ++ # Test assigning to name property ++ old_name = cb.name ++ cb.name = 'foo' ++ cb.append(cb.name[-11:]) ++ b.name = 'bar' ++ cb.append(b.name[-11:]) ++ cb.name = old_name ++ cb.append(cb.name[-17:]) + # Test CheckBuffer +! for _b in vim.buffers: +! if _b is not cb: +! vim.command('bwipeout! ' + str(_b.number)) +! del _b + for expr in ('b[1]','b[:] = ["A", "B"]','b[:]','b.append("abc")'): + try: + exec(expr) +*************** +*** 494,499 **** +--- 509,515 ---- + # Usually a SEGV here + # Should not happen in any case + cb.append('No exception for ' + expr) ++ vim.command('cd .') + EOF + :" + :" Test vim.buffers object +*** ../vim-7.3.1041/src/testdir/test87.ok 2013-05-21 22:38:14.000000000 +0200 +--- src/testdir/test87.ok 2013-05-29 21:59:04.000000000 +0200 +*************** +*** 308,321 **** + Second line + Third line + foo + i: + i2: + i: + i3: + 1:= +! 6:= +! 7:= +! 8:= + 4 + i4: + i4: +--- 308,330 ---- + Second line + Third line + foo ++ 1:BufFilePre:1 ++ 6:BufFilePost:1 ++ testdir/foo ++ 5:BufFilePre:5 ++ 5:BufFilePost:5 ++ testdir/bar ++ 1:BufFilePre:1 ++ 7:BufFilePost:1 ++ testdir/test87.in + i: + i2: + i: + i3: + 1:= +! 8:= +! 9:= +! 10:= + 4 + i4: + i4: +*************** +*** 324,330 **** + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (27, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +--- 333,339 ---- + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (36, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +*** ../vim-7.3.1041/src/version.c 2013-05-29 21:37:29.000000000 +0200 +--- src/version.c 2013-05-29 22:01:11.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1042, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +19. All of your friends have an @ in their names. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fe19549d5d02dbbf489f9fb784d64fded2b616dd Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:17 +0200 Subject: [PATCH 0934/3340] - patchlevel 1043 --- 7.3.1043 | 240 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 240 insertions(+) create mode 100644 7.3.1043 diff --git a/7.3.1043 b/7.3.1043 new file mode 100644 index 00000000..88d8b425 --- /dev/null +++ b/7.3.1043 @@ -0,0 +1,240 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1043 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1043 +Problem: Python: Dynamic compilation with 2.3 fails. +Solution: Python patch 4. (ZyX) +Files: src/if_python.c + + +*** ../vim-7.3.1042/src/if_python.c 2013-05-29 22:02:18.000000000 +0200 +--- src/if_python.c 2013-05-29 22:04:43.000000000 +0200 +*************** +*** 194,199 **** +--- 194,200 ---- + # define PyDict_New dll_PyDict_New + # define PyDict_GetItemString dll_PyDict_GetItemString + # define PyDict_Next dll_PyDict_Next ++ # define PyDict_Type (*dll_PyDict_Type) + # ifdef PyMapping_Items + # define PY_NO_MAPPING_ITEMS + # else +*************** +*** 234,241 **** + # define Py_IsInitialized dll_Py_IsInitialized + # define _PyObject_New dll__PyObject_New + # define _PyObject_GC_New dll__PyObject_GC_New +! # define PyObject_GC_Del dll_PyObject_GC_Del +! # define PyObject_GC_UnTrack dll_PyObject_GC_UnTrack + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02070000 + # define _PyObject_NextNotImplemented (*dll__PyObject_NextNotImplemented) + # endif +--- 235,248 ---- + # define Py_IsInitialized dll_Py_IsInitialized + # define _PyObject_New dll__PyObject_New + # define _PyObject_GC_New dll__PyObject_GC_New +! # ifdef PyObject_GC_Del +! # define Py_underscore_GC +! # define _PyObject_GC_Del dll__PyObject_GC_Del +! # define _PyObject_GC_UnTrack dll__PyObject_GC_UnTrack +! # else +! # define PyObject_GC_Del dll_PyObject_GC_Del +! # define PyObject_GC_UnTrack dll_PyObject_GC_UnTrack +! # endif + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02070000 + # define _PyObject_NextNotImplemented (*dll__PyObject_NextNotImplemented) + # endif +*************** +*** 247,259 **** + # define PyObject_IsTrue dll_PyObject_IsTrue + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + # define PyType_IsSubtype dll_PyType_IsSubtype +- # endif +- # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02030000 + # ifdef Py_DEBUG + # define _Py_NegativeRefcount dll__Py_NegativeRefcount + # define _Py_RefTotal (*dll__Py_RefTotal) + # define _Py_Dealloc dll__Py_Dealloc + # endif + # if defined(Py_DEBUG) && !defined(Py_DEBUG_NO_PYMALLOC) + # define _PyObject_DebugMalloc dll__PyObject_DebugMalloc + # define _PyObject_DebugFree dll__PyObject_DebugFree +--- 254,266 ---- + # define PyObject_IsTrue dll_PyObject_IsTrue + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + # define PyType_IsSubtype dll_PyType_IsSubtype + # ifdef Py_DEBUG + # define _Py_NegativeRefcount dll__Py_NegativeRefcount + # define _Py_RefTotal (*dll__Py_RefTotal) + # define _Py_Dealloc dll__Py_Dealloc + # endif ++ # endif ++ # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02030000 + # if defined(Py_DEBUG) && !defined(Py_DEBUG_NO_PYMALLOC) + # define _PyObject_DebugMalloc dll__PyObject_DebugMalloc + # define _PyObject_DebugFree dll__PyObject_DebugFree +*************** +*** 316,322 **** + static PyObject*(*dll_PyImport_ImportModule)(const char *); + static PyObject*(*dll_PyDict_New)(void); + static PyObject*(*dll_PyDict_GetItemString)(PyObject *, const char *); +! static int (*dll_PyDict_Next)(PyObject *, Py_ssize_t *, PyObject **, PyObject **); + # ifndef PY_NO_MAPPING_ITEMS + static PyObject* (*dll_PyMapping_Items)(PyObject *); + # endif +--- 323,330 ---- + static PyObject*(*dll_PyImport_ImportModule)(const char *); + static PyObject*(*dll_PyDict_New)(void); + static PyObject*(*dll_PyDict_GetItemString)(PyObject *, const char *); +! static int (*dll_PyDict_Next)(PyObject *, PyInt *, PyObject **, PyObject **); +! static PyTypeObject* dll_PyDict_Type; + # ifndef PY_NO_MAPPING_ITEMS + static PyObject* (*dll_PyMapping_Items)(PyObject *); + # endif +*************** +*** 354,361 **** +--- 362,374 ---- + static int(*dll_Py_IsInitialized)(void); + static PyObject*(*dll__PyObject_New)(PyTypeObject *, PyObject *); + static PyObject*(*dll__PyObject_GC_New)(PyTypeObject *); ++ # ifdef Py_underscore_GC ++ static void(*dll__PyObject_GC_Del)(void *); ++ static void(*dll__PyObject_GC_UnTrack)(void *); ++ # else + static void(*dll_PyObject_GC_Del)(void *); + static void(*dll_PyObject_GC_UnTrack)(void *); ++ # endif + static PyObject*(*dll__PyObject_Init)(PyObject *, PyTypeObject *); + static PyObject* (*dll_PyObject_GetIter)(PyObject *); + static int (*dll_PyObject_IsTrue)(PyObject *); +*************** +*** 367,379 **** + static PyObject* dll__Py_TrueStruct; + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + static int (*dll_PyType_IsSubtype)(PyTypeObject *, PyTypeObject *); +- # endif +- # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02030000 + # ifdef Py_DEBUG + static void (*dll__Py_NegativeRefcount)(const char *fname, int lineno, PyObject *op); +! static Py_ssize_t* dll__Py_RefTotal; + static void (*dll__Py_Dealloc)(PyObject *obj); + # endif + # if defined(Py_DEBUG) && !defined(Py_DEBUG_NO_PYMALLOC) + static void (*dll__PyObject_DebugFree)(void*); + static void* (*dll__PyObject_DebugMalloc)(size_t); +--- 380,392 ---- + static PyObject* dll__Py_TrueStruct; + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + static int (*dll_PyType_IsSubtype)(PyTypeObject *, PyTypeObject *); + # ifdef Py_DEBUG + static void (*dll__Py_NegativeRefcount)(const char *fname, int lineno, PyObject *op); +! static PyInt* dll__Py_RefTotal; + static void (*dll__Py_Dealloc)(PyObject *obj); + # endif ++ # endif ++ # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02030000 + # if defined(Py_DEBUG) && !defined(Py_DEBUG_NO_PYMALLOC) + static void (*dll__PyObject_DebugFree)(void*); + static void* (*dll__PyObject_DebugMalloc)(size_t); +*************** +*** 470,475 **** +--- 483,489 ---- + {"PyDict_GetItemString", (PYTHON_PROC*)&dll_PyDict_GetItemString}, + {"PyDict_Next", (PYTHON_PROC*)&dll_PyDict_Next}, + {"PyDict_New", (PYTHON_PROC*)&dll_PyDict_New}, ++ {"PyDict_Type", (PYTHON_PROC*)&dll_PyDict_Type}, + # ifndef PY_NO_MAPPING_ITEMS + {"PyMapping_Items", (PYTHON_PROC*)&dll_PyMapping_Items}, + # endif +*************** +*** 504,511 **** +--- 518,530 ---- + {"Py_IsInitialized", (PYTHON_PROC*)&dll_Py_IsInitialized}, + {"_PyObject_New", (PYTHON_PROC*)&dll__PyObject_New}, + {"_PyObject_GC_New", (PYTHON_PROC*)&dll__PyObject_GC_New}, ++ # ifdef Py_underscore_GC ++ {"_PyObject_GC_Del", (PYTHON_PROC*)&dll__PyObject_GC_Del}, ++ {"_PyObject_GC_UnTrack", (PYTHON_PROC*)&dll__PyObject_GC_UnTrack}, ++ # else + {"PyObject_GC_Del", (PYTHON_PROC*)&dll_PyObject_GC_Del}, + {"PyObject_GC_UnTrack", (PYTHON_PROC*)&dll_PyObject_GC_UnTrack}, ++ # endif + {"PyObject_Init", (PYTHON_PROC*)&dll__PyObject_Init}, + {"PyObject_GetIter", (PYTHON_PROC*)&dll_PyObject_GetIter}, + {"PyObject_IsTrue", (PYTHON_PROC*)&dll_PyObject_IsTrue}, +*************** +*** 516,529 **** + {"_Py_ZeroStruct", (PYTHON_PROC*)&dll__Py_ZeroStruct}, + {"_Py_TrueStruct", (PYTHON_PROC*)&dll__Py_TrueStruct}, + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 +- {"PyType_IsSubtype", (PYTHON_PROC*)&dll_PyType_IsSubtype}, +- # endif +- # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02030000 + # ifdef Py_DEBUG + {"_Py_NegativeRefcount", (PYTHON_PROC*)&dll__Py_NegativeRefcount}, + {"_Py_RefTotal", (PYTHON_PROC*)&dll__Py_RefTotal}, + {"_Py_Dealloc", (PYTHON_PROC*)&dll__Py_Dealloc}, + # endif + # if defined(Py_DEBUG) && !defined(Py_DEBUG_NO_PYMALLOC) + {"_PyObject_DebugFree", (PYTHON_PROC*)&dll__PyObject_DebugFree}, + {"_PyObject_DebugMalloc", (PYTHON_PROC*)&dll__PyObject_DebugMalloc}, +--- 535,548 ---- + {"_Py_ZeroStruct", (PYTHON_PROC*)&dll__Py_ZeroStruct}, + {"_Py_TrueStruct", (PYTHON_PROC*)&dll__Py_TrueStruct}, + # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02020000 + # ifdef Py_DEBUG + {"_Py_NegativeRefcount", (PYTHON_PROC*)&dll__Py_NegativeRefcount}, + {"_Py_RefTotal", (PYTHON_PROC*)&dll__Py_RefTotal}, + {"_Py_Dealloc", (PYTHON_PROC*)&dll__Py_Dealloc}, + # endif ++ {"PyType_IsSubtype", (PYTHON_PROC*)&dll_PyType_IsSubtype}, ++ # endif ++ # if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02030000 + # if defined(Py_DEBUG) && !defined(Py_DEBUG_NO_PYMALLOC) + {"_PyObject_DebugFree", (PYTHON_PROC*)&dll__PyObject_DebugFree}, + {"_PyObject_DebugMalloc", (PYTHON_PROC*)&dll__PyObject_DebugMalloc}, +*************** +*** 696,703 **** + #endif + #ifndef Py_CLEAR + # define Py_CLEAR(obj) \ +! Py_XDECREF(obj); \ +! obj = NULL; + #endif + + /* +--- 715,724 ---- + #endif + #ifndef Py_CLEAR + # define Py_CLEAR(obj) \ +! { \ +! Py_XDECREF(obj); \ +! obj = NULL; \ +! } + #endif + + /* +*** ../vim-7.3.1042/src/version.c 2013-05-29 22:02:18.000000000 +0200 +--- src/version.c 2013-05-29 22:04:56.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1043, + /**/ + +-- +When a fly lands on the ceiling, does it do a half roll or +a half loop? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f55637261353666d96ebf2f84783671b8f79b20d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:17 +0200 Subject: [PATCH 0935/3340] - patchlevel 1044 --- 7.3.1044 | 391 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 391 insertions(+) create mode 100644 7.3.1044 diff --git a/7.3.1044 b/7.3.1044 new file mode 100644 index 00000000..aad78994 --- /dev/null +++ b/7.3.1044 @@ -0,0 +1,391 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1044 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1044 +Problem: Python: No {Buffer,TabPage,Window}.valid attributes. +Solution: Python patch 5: add .valid (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c, + src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.1043/src/if_py_both.h 2013-05-29 22:02:18.000000000 +0200 +--- src/if_py_both.h 2013-05-29 22:08:36.000000000 +0200 +*************** +*** 1815,1820 **** +--- 1815,1833 ---- + } + + static PyObject * ++ TabPageAttrValid(TabPageObject *self, char *name) ++ { ++ PyObject *r; ++ ++ if (strcmp(name, "valid") != 0) ++ return NULL; ++ ++ r = ((self->tab == INVALID_TABPAGE_VALUE) ? Py_False : Py_True); ++ Py_INCREF(r); ++ return r; ++ } ++ ++ static PyObject * + TabPageAttr(TabPageObject *self, char *name) + { + if (strcmp(name, "windows") == 0) +*************** +*** 2010,2015 **** +--- 2023,2041 ---- + } + + static PyObject * ++ WindowAttrValid(WindowObject *self, char *name) ++ { ++ PyObject *r; ++ ++ if (strcmp(name, "valid") != 0) ++ return NULL; ++ ++ r = ((self->win == INVALID_WINDOW_VALUE) ? Py_False : Py_True); ++ Py_INCREF(r); ++ return r; ++ } ++ ++ static PyObject * + WindowAttr(WindowObject *self, char *name) + { + if (strcmp(name, "buffer") == 0) +*************** +*** 2050,2057 **** + return (PyObject *)(self->tabObject); + } + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[sssssssss]", "buffer", "cursor", "height", +! "vars", "options", "number", "row", "col", "tabpage"); + else + return NULL; + } +--- 2076,2083 ---- + return (PyObject *)(self->tabObject); + } + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[ssssssssss]", "buffer", "cursor", "height", +! "vars", "options", "number", "row", "col", "tabpage", "valid"); + else + return NULL; + } +*************** +*** 3186,3191 **** +--- 3212,3230 ---- + } + + static PyObject * ++ BufferAttrValid(BufferObject *self, char *name) ++ { ++ PyObject *r; ++ ++ if (strcmp(name, "valid") != 0) ++ return NULL; ++ ++ r = ((self->buf == INVALID_BUFFER_VALUE) ? Py_False : Py_True); ++ Py_INCREF(r); ++ return r; ++ } ++ ++ static PyObject * + BufferAttr(BufferObject *self, char *name) + { + if (strcmp(name, "name") == 0) +*************** +*** 3198,3204 **** + return OptionsNew(SREQ_BUF, self->buf, (checkfun) CheckBuffer, + (PyObject *) self); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[ssss]", "name", "number", "vars", "options"); + else + return NULL; + } +--- 3237,3244 ---- + return OptionsNew(SREQ_BUF, self->buf, (checkfun) CheckBuffer, + (PyObject *) self); + else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[sssss]", "name", "number", "vars", "options", +! "valid"); + else + return NULL; + } +*** ../vim-7.3.1043/src/if_python3.c 2013-05-29 22:02:18.000000000 +0200 +--- src/if_python3.c 2013-05-29 22:08:36.000000000 +0200 +*************** +*** 1067,1078 **** + */ + + static PyObject * +! BufferGetattro(PyObject *self, PyObject*nameobj) + { + PyObject *r; + + GET_ATTR_STRING(name, nameobj); + + if (CheckBuffer((BufferObject *)(self))) + return NULL; + +--- 1067,1081 ---- + */ + + static PyObject * +! BufferGetattro(PyObject *self, PyObject *nameobj) + { + PyObject *r; + + GET_ATTR_STRING(name, nameobj); + ++ if ((r = BufferAttrValid((BufferObject *)(self), name))) ++ return r; ++ + if (CheckBuffer((BufferObject *)(self))) + return NULL; + +*************** +*** 1094,1101 **** + static PyObject * + BufferDir(PyObject *self UNUSED) + { +! return Py_BuildValue("[sssss]", "name", "number", +! "append", "mark", "range"); + } + + /******************/ +--- 1097,1105 ---- + static PyObject * + BufferDir(PyObject *self UNUSED) + { +! return Py_BuildValue("[ssssssss]", +! "name", "number", "vars", "options", "valid", +! "append", "mark", "range"); + } + + /******************/ +*************** +*** 1283,1288 **** +--- 1287,1295 ---- + + GET_ATTR_STRING(name, nameobj); + ++ if ((r = TabPageAttrValid((TabPageObject *)(self), name))) ++ return r; ++ + if (CheckTabPage((TabPageObject *)(self))) + return NULL; + +*************** +*** 1303,1308 **** +--- 1310,1318 ---- + + GET_ATTR_STRING(name, nameobj); + ++ if ((r = WindowAttrValid((WindowObject *)(self), name))) ++ return r; ++ + if (CheckWindow((WindowObject *)(self))) + return NULL; + +*** ../vim-7.3.1043/src/if_python.c 2013-05-29 22:05:51.000000000 +0200 +--- src/if_python.c 2013-05-29 22:08:36.000000000 +0200 +*************** +*** 1125,1130 **** +--- 1125,1133 ---- + { + PyObject *r; + ++ if ((r = BufferAttrValid((BufferObject *)(self), name))) ++ return r; ++ + if (CheckBuffer((BufferObject *)(self))) + return NULL; + +*************** +*** 1206,1211 **** +--- 1209,1217 ---- + { + PyObject *r; + ++ if ((r = TabPageAttrValid((TabPageObject *)(self), name))) ++ return r; ++ + if (CheckTabPage((TabPageObject *)(self))) + return NULL; + +*************** +*** 1224,1229 **** +--- 1230,1238 ---- + { + PyObject *r; + ++ if ((r = WindowAttrValid((WindowObject *)(self), name))) ++ return r; ++ + if (CheckWindow((WindowObject *)(self))) + return NULL; + +*** ../vim-7.3.1043/src/testdir/test86.in 2013-05-29 22:02:18.000000000 +0200 +--- src/testdir/test86.in 2013-05-29 22:08:36.000000000 +0200 +*************** +*** 513,518 **** +--- 513,519 ---- + if _b is not cb: + vim.command('bwipeout! ' + str(_b.number)) + del _b ++ cb.append('valid: b:%s, cb:%s' % (repr(b.valid), repr(cb.valid))) + for expr in ('b[1]','b[:] = ["A", "B"]','b[:]','b.append("abc")', 'b.name = "!"'): + try: + exec(expr) +*************** +*** 663,671 **** +--- 664,676 ---- + cb.append('Current window: ' + repr(vim.current.window)) + cb.append('Current buffer: ' + repr(vim.current.buffer)) + cb.append('Current line: ' + repr(vim.current.line)) ++ ws = list(vim.windows) ++ ts = list(vim.tabpages) + for b in vim.buffers: + if b is not cb: + vim.command('bwipeout! ' + str(b.number)) ++ cb.append('w.valid: ' + repr([w.valid for w in ws])) ++ cb.append('t.valid: ' + repr([t.valid for t in ts])) + EOF + :tabonly! + :only! +*** ../vim-7.3.1043/src/testdir/test86.ok 2013-05-29 22:02:18.000000000 +0200 +--- src/testdir/test86.ok 2013-05-29 22:09:47.000000000 +0200 +*************** +*** 328,333 **** +--- 328,334 ---- + 1:BufFilePre:1 + 7:BufFilePost:1 + testdir/test86.in ++ valid: b:False, cb:True + i: + i2: + i: +*************** +*** 344,350 **** + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (36, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +--- 345,351 ---- + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (37, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +*************** +*** 370,375 **** +--- 371,378 ---- + Current window: + Current buffer: + Current line: 'Type error at assigning None to vim.current.buffer' ++ w.valid: [True, False] ++ t.valid: [True, False, True, False] + vim.vars:Dictionary:True + vim.options:Options:True + vim.bindeval("{}"):Dictionary:True +*** ../vim-7.3.1043/src/testdir/test87.in 2013-05-29 22:02:18.000000000 +0200 +--- src/testdir/test87.in 2013-05-29 22:08:36.000000000 +0200 +*************** +*** 500,505 **** +--- 500,506 ---- + if _b is not cb: + vim.command('bwipeout! ' + str(_b.number)) + del _b ++ cb.append('valid: b:%s, cb:%s' % (repr(b.valid), repr(cb.valid))) + for expr in ('b[1]','b[:] = ["A", "B"]','b[:]','b.append("abc")'): + try: + exec(expr) +*************** +*** 641,649 **** +--- 642,654 ---- + cb.append('Current window: ' + repr(vim.current.window)) + cb.append('Current buffer: ' + repr(vim.current.buffer)) + cb.append('Current line: ' + repr(vim.current.line)) ++ ws = list(vim.windows) ++ ts = list(vim.tabpages) + for b in vim.buffers: + if b is not cb: + vim.command('bwipeout! ' + str(b.number)) ++ cb.append('w.valid: ' + repr([w.valid for w in ws])) ++ cb.append('t.valid: ' + repr([t.valid for t in ts])) + EOF + :tabonly! + :only! +*** ../vim-7.3.1043/src/testdir/test87.ok 2013-05-29 22:02:18.000000000 +0200 +--- src/testdir/test87.ok 2013-05-29 22:10:11.000000000 +0200 +*************** +*** 317,322 **** +--- 317,323 ---- + 1:BufFilePre:1 + 7:BufFilePost:1 + testdir/test87.in ++ valid: b:False, cb:True + i: + i2: + i: +*************** +*** 333,339 **** + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (36, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +--- 334,340 ---- + Current tab pages: + (1): 1 windows, current is + Windows: +! (1): displays buffer ; cursor is at (37, 0) + (2): 1 windows, current is + Windows: + (1): displays buffer ; cursor is at (1, 0) +*************** +*** 359,364 **** +--- 360,367 ---- + Current window: + Current buffer: + Current line: 'Type error at assigning None to vim.current.buffer' ++ w.valid: [True, False] ++ t.valid: [True, False, True, False] + vim.vars:Dictionary:True + vim.options:Options:True + vim.bindeval("{}"):Dictionary:True +*** ../vim-7.3.1043/src/version.c 2013-05-29 22:05:51.000000000 +0200 +--- src/version.c 2013-05-29 22:10:45.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1044, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +20. When looking at a pageful of someone else's links, you notice all of them + are already highlighted in purple. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f8967f0739d2e5fd5133a8b759cf5b9efd70f326 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:18 +0200 Subject: [PATCH 0936/3340] - patchlevel 1045 --- 7.3.1045 | 173 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 173 insertions(+) create mode 100644 7.3.1045 diff --git a/7.3.1045 b/7.3.1045 new file mode 100644 index 00000000..b82613c0 --- /dev/null +++ b/7.3.1045 @@ -0,0 +1,173 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1045 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1045 +Problem: Python: No error handling for VimToPython function. +Solution: Python patch 6. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1044/src/if_py_both.h 2013-05-29 22:15:26.000000000 +0200 +--- src/if_py_both.h 2013-05-29 22:17:56.000000000 +0200 +*************** +*** 432,439 **** + sprintf(ptrBuf, "%p", + our_tv->v_type == VAR_LIST ? (void *)our_tv->vval.v_list + : (void *)our_tv->vval.v_dict); +! result = PyDict_GetItemString(lookupDict, ptrBuf); +! if (result != NULL) + { + Py_INCREF(result); + return result; +--- 432,439 ---- + sprintf(ptrBuf, "%p", + our_tv->v_type == VAR_LIST ? (void *)our_tv->vval.v_list + : (void *)our_tv->vval.v_dict); +! +! if ((result = PyDict_GetItemString(lookupDict, ptrBuf))) + { + Py_INCREF(result); + return result; +*************** +*** 467,510 **** + list_T *list = our_tv->vval.v_list; + listitem_T *curr; + +! result = PyList_New(0); + +! if (list != NULL) + { +! PyDict_SetItemString(lookupDict, ptrBuf, result); + +! for (curr = list->lv_first; curr != NULL; curr = curr->li_next) + { +- newObj = VimToPython(&curr->li_tv, depth + 1, lookupDict); +- PyList_Append(result, newObj); + Py_DECREF(newObj); + } + } + } + else if (our_tv->v_type == VAR_DICT) + { +- result = PyDict_New(); + +! if (our_tv->vval.v_dict != NULL) +! { +! hashtab_T *ht = &our_tv->vval.v_dict->dv_hashtab; +! long_u todo = ht->ht_used; +! hashitem_T *hi; +! dictitem_T *di; + +! PyDict_SetItemString(lookupDict, ptrBuf, result); + +! for (hi = ht->ht_array; todo > 0; ++hi) + { +! if (!HASHITEM_EMPTY(hi)) +! { +! --todo; + +! di = dict_lookup(hi); +! newObj = VimToPython(&di->di_tv, depth + 1, lookupDict); +! PyDict_SetItemString(result, (char *)hi->hi_key, newObj); + Py_DECREF(newObj); + } + } + } + } +--- 467,538 ---- + list_T *list = our_tv->vval.v_list; + listitem_T *curr; + +! if (list == NULL) +! return NULL; +! +! if (!(result = PyList_New(0))) +! return NULL; + +! if (PyDict_SetItemString(lookupDict, ptrBuf, result)) + { +! Py_DECREF(result); +! return NULL; +! } + +! for (curr = list->lv_first; curr != NULL; curr = curr->li_next) +! { +! if (!(newObj = VimToPython(&curr->li_tv, depth + 1, lookupDict))) +! { +! Py_DECREF(result); +! return NULL; +! } +! if (PyList_Append(result, newObj)) + { + Py_DECREF(newObj); ++ Py_DECREF(result); ++ return NULL; + } ++ Py_DECREF(newObj); + } + } + else if (our_tv->v_type == VAR_DICT) + { + +! hashtab_T *ht = &our_tv->vval.v_dict->dv_hashtab; +! long_u todo = ht->ht_used; +! hashitem_T *hi; +! dictitem_T *di; +! if (our_tv->vval.v_dict == NULL) +! return NULL; +! +! if (!(result = PyDict_New())) +! return NULL; + +! if (PyDict_SetItemString(lookupDict, ptrBuf, result)) +! { +! Py_DECREF(result); +! return NULL; +! } + +! for (hi = ht->ht_array; todo > 0; ++hi) +! { +! if (!HASHITEM_EMPTY(hi)) + { +! --todo; + +! di = dict_lookup(hi); +! if (!(newObj = VimToPython(&di->di_tv, depth + 1, lookupDict))) +! { +! Py_DECREF(result); +! return NULL; +! } +! if (PyDict_SetItemString(result, (char *)hi->hi_key, newObj)) +! { +! Py_DECREF(result); + Py_DECREF(newObj); ++ return NULL; + } ++ Py_DECREF(newObj); + } + } + } +*** ../vim-7.3.1044/src/version.c 2013-05-29 22:15:26.000000000 +0200 +--- src/version.c 2013-05-29 22:17:30.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1045, + /**/ + +-- +Shift happens. + -- Doppler + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f3a23f76ac2d9195fe71b538a9b8d1be37b54668 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:19 +0200 Subject: [PATCH 0937/3340] - patchlevel 1046 --- 7.3.1046 | 105 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 105 insertions(+) create mode 100644 7.3.1046 diff --git a/7.3.1046 b/7.3.1046 new file mode 100644 index 00000000..a66e9470 --- /dev/null +++ b/7.3.1046 @@ -0,0 +1,105 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1046 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1046 +Problem: Python: Using Py_BuildValue for building strings. +Solution: Python patch 7 and 7.5: Replace Py_BuildValue with + PyString_FromString. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1045/src/if_py_both.h 2013-05-29 22:19:57.000000000 +0200 +--- src/if_py_both.h 2013-05-29 22:24:52.000000000 +0200 +*************** +*** 442,448 **** + + if (our_tv->v_type == VAR_STRING) + { +! result = Py_BuildValue("s", our_tv->vval.v_string == NULL + ? "" : (char *)our_tv->vval.v_string); + } + else if (our_tv->v_type == VAR_NUMBER) +--- 442,448 ---- + + if (our_tv->v_type == VAR_STRING) + { +! result = PyString_FromString(our_tv->vval.v_string == NULL + ? "" : (char *)our_tv->vval.v_string); + } + else if (our_tv->v_type == VAR_NUMBER) +*************** +*** 451,457 **** + + /* For backwards compatibility numbers are stored as strings. */ + sprintf(buf, "%ld", (long)our_tv->vval.v_number); +! result = Py_BuildValue("s", buf); + } + # ifdef FEAT_FLOAT + else if (our_tv->v_type == VAR_FLOAT) +--- 451,457 ---- + + /* For backwards compatibility numbers are stored as strings. */ + sprintf(buf, "%ld", (long)our_tv->vval.v_number); +! result = PyString_FromString((char *) buf); + } + # ifdef FEAT_FLOAT + else if (our_tv->v_type == VAR_FLOAT) +*************** +*** 459,465 **** + char buf[NUMBUFLEN]; + + sprintf(buf, "%f", our_tv->vval.v_float); +! result = Py_BuildValue("s", buf); + } + # endif + else if (our_tv->v_type == VAR_LIST) +--- 459,465 ---- + char buf[NUMBUFLEN]; + + sprintf(buf, "%f", our_tv->vval.v_float); +! result = PyString_FromString((char *) buf); + } + # endif + else if (our_tv->v_type == VAR_LIST) +*************** +*** 3256,3262 **** + BufferAttr(BufferObject *self, char *name) + { + if (strcmp(name, "name") == 0) +! return Py_BuildValue("s", self->buf->b_ffname); + else if (strcmp(name, "number") == 0) + return Py_BuildValue(Py_ssize_t_fmt, self->buf->b_fnum); + else if (strcmp(name, "vars") == 0) +--- 3256,3263 ---- + BufferAttr(BufferObject *self, char *name) + { + if (strcmp(name, "name") == 0) +! return PyString_FromString((self->buf->b_ffname == NULL +! ? "" : (char *) self->buf->b_ffname)); + else if (strcmp(name, "number") == 0) + return Py_BuildValue(Py_ssize_t_fmt, self->buf->b_fnum); + else if (strcmp(name, "vars") == 0) +*** ../vim-7.3.1045/src/version.c 2013-05-29 22:19:57.000000000 +0200 +--- src/version.c 2013-05-29 22:25:14.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1046, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +21. Your dog has its own home page. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 48bd44461edadabeed2c9b91ffe4f6dd88525685 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:19 +0200 Subject: [PATCH 0938/3340] - patchlevel 1047 --- 7.3.1047 | 743 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 743 insertions(+) create mode 100644 7.3.1047 diff --git a/7.3.1047 b/7.3.1047 new file mode 100644 index 00000000..9d3a4163 --- /dev/null +++ b/7.3.1047 @@ -0,0 +1,743 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1047 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1047 +Problem: Python: dir() does not work properly. +Solution: Python patch 8. Add __dir__ method to all objects with custom + tp_getattr supplemented by __members__ attribute for at least + python-2* versions. __members__ is not mentioned in python-3* + dir() output even if it is accessible. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c, + src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.1046/src/if_py_both.h 2013-05-29 22:26:15.000000000 +0200 +--- src/if_py_both.h 2013-05-29 22:29:26.000000000 +0200 +*************** +*** 117,122 **** +--- 117,175 ---- + return (char_u *) p; + } + ++ static int ++ add_string(PyObject *list, char *s) ++ { ++ PyObject *string; ++ ++ if (!(string = PyString_FromString(s))) ++ return -1; ++ if (PyList_Append(list, string)) ++ { ++ Py_DECREF(string); ++ return -1; ++ } ++ ++ Py_DECREF(string); ++ return 0; ++ } ++ ++ static PyObject * ++ ObjectDir(PyObject *self, char **attributes) ++ { ++ PyMethodDef *method; ++ char **attr; ++ PyObject *r; ++ ++ if (!(r = PyList_New(0))) ++ return NULL; ++ ++ if (self) ++ for (method = self->ob_type->tp_methods ; method->ml_name != NULL ; ++method) ++ if (add_string(r, (char *) method->ml_name)) ++ { ++ Py_DECREF(r); ++ return NULL; ++ } ++ ++ for (attr = attributes ; *attr ; ++attr) ++ if (add_string(r, *attr)) ++ { ++ Py_DECREF(r); ++ return NULL; ++ } ++ ++ #if PY_MAJOR_VERSION < 3 ++ if (add_string(r, "__members__")) ++ { ++ Py_DECREF(r); ++ return NULL; ++ } ++ #endif ++ ++ return r; ++ } ++ + /* Output buffer management + */ + +*************** +*** 132,137 **** +--- 185,201 ---- + long error; + } OutputObject; + ++ static char *OutputAttrs[] = { ++ "softspace", ++ NULL ++ }; ++ ++ static PyObject * ++ OutputDir(PyObject *self) ++ { ++ return ObjectDir(self, OutputAttrs); ++ } ++ + static int + OutputSetattr(OutputObject *self, char *name, PyObject *val) + { +*************** +*** 291,296 **** +--- 355,361 ---- + {"write", (PyCFunction)OutputWrite, METH_VARARGS, ""}, + {"writelines", (PyCFunction)OutputWritelines, METH_VARARGS, ""}, + {"flush", (PyCFunction)OutputFlush, METH_NOARGS, ""}, ++ {"__dir__", (PyCFunction)OutputDir, METH_NOARGS, ""}, + { NULL, NULL, 0, NULL} + }; + +*************** +*** 826,831 **** +--- 891,907 ---- + DESTRUCTOR_FINISH(self); + } + ++ static char *DictionaryAttrs[] = { ++ "locked", "scope", ++ NULL ++ }; ++ ++ static PyObject * ++ DictionaryDir(PyObject *self) ++ { ++ return ObjectDir(self, DictionaryAttrs); ++ } ++ + static int + DictionarySetattr(DictionaryObject *self, char *name, PyObject *val) + { +*************** +*** 985,991 **** + + static struct PyMethodDef DictionaryMethods[] = { + {"keys", (PyCFunction)DictionaryListKeys, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL } + }; + + static PyTypeObject ListType; +--- 1061,1068 ---- + + static struct PyMethodDef DictionaryMethods[] = { + {"keys", (PyCFunction)DictionaryListKeys, METH_NOARGS, ""}, +! {"__dir__", (PyCFunction)DictionaryDir, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL} + }; + + static PyTypeObject ListType; +*************** +*** 1331,1336 **** +--- 1408,1424 ---- + return (PyObject *)(self); + } + ++ static char *ListAttrs[] = { ++ "locked", ++ NULL ++ }; ++ ++ static PyObject * ++ ListDir(PyObject *self) ++ { ++ return ObjectDir(self, ListAttrs); ++ } ++ + static int + ListSetattr(ListObject *self, char *name, PyObject *val) + { +*************** +*** 1368,1375 **** + } + + static struct PyMethodDef ListMethods[] = { +! {"extend", (PyCFunction)ListConcatInPlace, METH_O, ""}, +! { NULL, NULL, 0, NULL } + }; + + typedef struct +--- 1456,1464 ---- + } + + static struct PyMethodDef ListMethods[] = { +! {"extend", (PyCFunction)ListConcatInPlace, METH_O, ""}, +! {"__dir__", (PyCFunction)ListDir, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL} + }; + + typedef struct +*************** +*** 1408,1413 **** +--- 1497,1513 ---- + DESTRUCTOR_FINISH(self); + } + ++ static char *FunctionAttrs[] = { ++ "softspace", ++ NULL ++ }; ++ ++ static PyObject * ++ FunctionDir(PyObject *self) ++ { ++ return ObjectDir(self, FunctionAttrs); ++ } ++ + static PyObject * + FunctionCall(FunctionObject *self, PyObject *argsObject, PyObject *kwargs) + { +*************** +*** 1472,1479 **** + } + + static struct PyMethodDef FunctionMethods[] = { +! {"__call__", (PyCFunction)FunctionCall, METH_VARARGS|METH_KEYWORDS, ""}, +! { NULL, NULL, 0, NULL} + }; + + /* +--- 1572,1580 ---- + } + + static struct PyMethodDef FunctionMethods[] = { +! {"__call__",(PyCFunction)FunctionCall, METH_VARARGS|METH_KEYWORDS, ""}, +! {"__dir__", (PyCFunction)FunctionDir, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL} + }; + + /* +*************** +*** 1842,1847 **** +--- 1943,1959 ---- + DESTRUCTOR_FINISH(self); + } + ++ static char *TabPageAttrs[] = { ++ "windows", "number", "vars", "window", "valid", ++ NULL ++ }; ++ ++ static PyObject * ++ TabPageDir(PyObject *self) ++ { ++ return ObjectDir(self, TabPageAttrs); ++ } ++ + static PyObject * + TabPageAttrValid(TabPageObject *self, char *name) + { +*************** +*** 1873,1878 **** +--- 1985,1992 ---- + else + return WindowNew(self->tab->tp_curwin, self->tab); + } ++ else if (strcmp(name, "__members__") == 0) ++ return ObjectDir(NULL, TabPageAttrs); + return NULL; + } + +*************** +*** 1901,1908 **** + } + + static struct PyMethodDef TabPageMethods[] = { +! /* name, function, calling, documentation */ +! { NULL, NULL, 0, NULL } + }; + + /* +--- 2015,2023 ---- + } + + static struct PyMethodDef TabPageMethods[] = { +! /* name, function, calling, documentation */ +! {"__dir__", (PyCFunction)TabPageDir, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL} + }; + + /* +*************** +*** 2049,2054 **** +--- 2164,2180 ---- + else + return firstwin; + } ++ static char *WindowAttrs[] = { ++ "buffer", "cursor", "height", "vars", "options", "number", "row", "col", ++ "tabpage", "valid", ++ NULL ++ }; ++ ++ static PyObject * ++ WindowDir(PyObject *self) ++ { ++ return ObjectDir(self, WindowAttrs); ++ } + + static PyObject * + WindowAttrValid(WindowObject *self, char *name) +*************** +*** 2103,2111 **** + Py_INCREF(self->tabObject); + return (PyObject *)(self->tabObject); + } +! else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[ssssssssss]", "buffer", "cursor", "height", +! "vars", "options", "number", "row", "col", "tabpage", "valid"); + else + return NULL; + } +--- 2229,2236 ---- + Py_INCREF(self->tabObject); + return (PyObject *)(self->tabObject); + } +! else if (strcmp(name, "__members__") == 0) +! return ObjectDir(NULL, WindowAttrs); + else + return NULL; + } +*************** +*** 2228,2235 **** + } + + static struct PyMethodDef WindowMethods[] = { +! /* name, function, calling, documentation */ +! { NULL, NULL, 0, NULL } + }; + + /* +--- 2353,2361 ---- + } + + static struct PyMethodDef WindowMethods[] = { +! /* name, function, calling, documentation */ +! {"__dir__", (PyCFunction)WindowDir, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL} + }; + + /* +*************** +*** 3122,3127 **** +--- 3248,3264 ---- + return RBSlice(self->buf, lo, hi, self->start, self->end); + } + ++ static char *RangeAttrs[] = { ++ "start", "end", ++ NULL ++ }; ++ ++ static PyObject * ++ RangeDir(PyObject *self) ++ { ++ return ObjectDir(self, RangeAttrs); ++ } ++ + static PyObject * + RangeAppend(RangeObject *self, PyObject *args) + { +*************** +*** 3162,3168 **** + static struct PyMethodDef RangeMethods[] = { + /* name, function, calling, documentation */ + {"append", (PyCFunction)RangeAppend, METH_VARARGS, "Append data to the Vim range" }, +! { NULL, NULL, 0, NULL } + }; + + static PyTypeObject BufferType; +--- 3299,3306 ---- + static struct PyMethodDef RangeMethods[] = { + /* name, function, calling, documentation */ + {"append", (PyCFunction)RangeAppend, METH_VARARGS, "Append data to the Vim range" }, +! {"__dir__", (PyCFunction)RangeDir, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL} + }; + + static PyTypeObject BufferType; +*************** +*** 3239,3244 **** +--- 3377,3393 ---- + return RBSlice(self, lo, hi, 1, -1); + } + ++ static char *BufferAttrs[] = { ++ "name", "number", "vars", "options", "valid", ++ NULL ++ }; ++ ++ static PyObject * ++ BufferDir(PyObject *self) ++ { ++ return ObjectDir(self, BufferAttrs); ++ } ++ + static PyObject * + BufferAttrValid(BufferObject *self, char *name) + { +*************** +*** 3265,3273 **** + else if (strcmp(name, "options") == 0) + return OptionsNew(SREQ_BUF, self->buf, (checkfun) CheckBuffer, + (PyObject *) self); +! else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[sssss]", "name", "number", "vars", "options", +! "valid"); + else + return NULL; + } +--- 3414,3421 ---- + else if (strcmp(name, "options") == 0) + return OptionsNew(SREQ_BUF, self->buf, (checkfun) CheckBuffer, + (PyObject *) self); +! else if (strcmp(name, "__members__") == 0) +! return ObjectDir(NULL, BufferAttrs); + else + return NULL; + } +*************** +*** 3403,3412 **** + {"append", (PyCFunction)BufferAppend, METH_VARARGS, "Append data to Vim buffer" }, + {"mark", (PyCFunction)BufferMark, METH_VARARGS, "Return (row,col) representing position of named mark" }, + {"range", (PyCFunction)BufferRange, METH_VARARGS, "Return a range object which represents the part of the given buffer between line numbers s and e" }, +! #if PY_VERSION_HEX >= 0x03000000 +! {"__dir__", (PyCFunction)BufferDir, METH_NOARGS, "List buffer attributes" }, +! #endif +! { NULL, NULL, 0, NULL } + }; + + /* +--- 3551,3558 ---- + {"append", (PyCFunction)BufferAppend, METH_VARARGS, "Append data to Vim buffer" }, + {"mark", (PyCFunction)BufferMark, METH_VARARGS, "Return (row,col) representing position of named mark" }, + {"range", (PyCFunction)BufferRange, METH_VARARGS, "Return a range object which represents the part of the given buffer between line numbers s and e" }, +! {"__dir__", (PyCFunction)BufferDir, METH_NOARGS, ""}, +! { NULL, NULL, 0, NULL} + }; + + /* +*************** +*** 3538,3543 **** +--- 3684,3700 ---- + /* Current items object + */ + ++ static char *CurrentAttrs[] = { ++ "buffer", "window", "line", "range", "tabpage", ++ NULL ++ }; ++ ++ static PyObject * ++ CurrentDir(PyObject *self) ++ { ++ return ObjectDir(self, CurrentAttrs); ++ } ++ + static PyObject * + CurrentGetattr(PyObject *self UNUSED, char *name) + { +*************** +*** 3551,3564 **** + return GetBufferLine(curbuf, (PyInt)curwin->w_cursor.lnum); + else if (strcmp(name, "range") == 0) + return RangeNew(curbuf, RangeStart, RangeEnd); +! else if (strcmp(name,"__members__") == 0) +! return Py_BuildValue("[sssss]", "buffer", "window", "line", "range", +! "tabpage"); + else +! { +! PyErr_SetString(PyExc_AttributeError, name); + return NULL; +! } + } + + static int +--- 3708,3721 ---- + return GetBufferLine(curbuf, (PyInt)curwin->w_cursor.lnum); + else if (strcmp(name, "range") == 0) + return RangeNew(curbuf, RangeStart, RangeEnd); +! else if (strcmp(name, "__members__") == 0) +! return ObjectDir(NULL, CurrentAttrs); + else +! #if PY_MAJOR_VERSION < 3 +! return Py_FindMethod(WindowMethods, self, name); +! #else + return NULL; +! #endif + } + + static int +*************** +*** 3661,3666 **** +--- 3818,3829 ---- + } + } + ++ static struct PyMethodDef CurrentMethods[] = { ++ /* name, function, calling, documentation */ ++ {"__dir__", (PyCFunction)CurrentDir, METH_NOARGS, ""}, ++ { NULL, NULL, 0, NULL} ++ }; ++ + static void + init_range_cmd(exarg_T *eap) + { +*************** +*** 4397,4402 **** +--- 4560,4566 ---- + CurrentType.tp_basicsize = sizeof(CurrentObject); + CurrentType.tp_flags = Py_TPFLAGS_DEFAULT; + CurrentType.tp_doc = "vim current object"; ++ CurrentType.tp_methods = CurrentMethods; + #if PY_MAJOR_VERSION >= 3 + CurrentType.tp_getattro = (getattrofunc)CurrentGetattro; + CurrentType.tp_setattro = (setattrofunc)CurrentSetattro; +*** ../vim-7.3.1046/src/if_python3.c 2013-05-29 22:15:26.000000000 +0200 +--- src/if_python3.c 2013-05-29 22:29:26.000000000 +0200 +*************** +*** 666,672 **** + return PyType_GenericAlloc(type,nitems); + } + +- static PyObject *BufferDir(PyObject *); + static PyObject *OutputGetattro(PyObject *, PyObject *); + static int OutputSetattro(PyObject *, PyObject *, PyObject *); + static PyObject *BufferGetattro(PyObject *, PyObject *); +--- 666,671 ---- +*************** +*** 1094,1107 **** + return BufferSetattr((BufferObject *)(self), name, val); + } + +- static PyObject * +- BufferDir(PyObject *self UNUSED) +- { +- return Py_BuildValue("[ssssssss]", +- "name", "number", "vars", "options", "valid", +- "append", "mark", "range"); +- } +- + /******************/ + + static PyObject * +--- 1093,1098 ---- +*************** +*** 1368,1375 **** + static PyObject * + CurrentGetattro(PyObject *self, PyObject *nameobj) + { + GET_ATTR_STRING(name, nameobj); +! return CurrentGetattr(self, name); + } + + static int +--- 1359,1369 ---- + static PyObject * + CurrentGetattro(PyObject *self, PyObject *nameobj) + { ++ PyObject *r; + GET_ATTR_STRING(name, nameobj); +! if (!(r = CurrentGetattr(self, name))) +! return PyObject_GenericGetAttr(self, nameobj); +! return r; + } + + static int +*** ../vim-7.3.1046/src/if_python.c 2013-05-29 22:15:26.000000000 +0200 +--- src/if_python.c 2013-05-29 22:29:26.000000000 +0200 +*************** +*** 1066,1071 **** +--- 1066,1073 ---- + { + if (strcmp(name, "softspace") == 0) + return PyInt_FromLong(((OutputObject *)(self))->softspace); ++ else if (strcmp(name, "__members__") == 0) ++ return ObjectDir(NULL, OutputAttrs); + + return Py_FindMethod(OutputMethods, self, name); + } +*************** +*** 1177,1182 **** +--- 1179,1186 ---- + return Py_BuildValue(Py_ssize_t_fmt, ((RangeObject *)(self))->start - 1); + else if (strcmp(name, "end") == 0) + return Py_BuildValue(Py_ssize_t_fmt, ((RangeObject *)(self))->end - 1); ++ else if (strcmp(name, "__members__") == 0) ++ return ObjectDir(NULL, RangeAttrs); + else + return Py_FindMethod(RangeMethods, self, name); + } +*************** +*** 1396,1401 **** +--- 1400,1407 ---- + return PyInt_FromLong(this->dict->dv_lock); + else if (strcmp(name, "scope") == 0) + return PyInt_FromLong(this->dict->dv_scope); ++ else if (strcmp(name, "__members__") == 0) ++ return ObjectDir(NULL, DictionaryAttrs); + + return Py_FindMethod(DictionaryMethods, self, name); + } +*************** +*** 1420,1425 **** +--- 1426,1433 ---- + { + if (strcmp(name, "locked") == 0) + return PyInt_FromLong(((ListObject *)(self))->list->lv_lock); ++ else if (strcmp(name, "__members__") == 0) ++ return ObjectDir(NULL, ListAttrs); + + return Py_FindMethod(ListMethods, self, name); + } +*************** +*** 1431,1436 **** +--- 1439,1446 ---- + + if (strcmp(name, "name") == 0) + return PyString_FromString((char *)(this->name)); ++ else if (strcmp(name, "__members__") == 0) ++ return ObjectDir(NULL, FunctionAttrs); + else + return Py_FindMethod(FunctionMethods, self, name); + } +*** ../vim-7.3.1046/src/testdir/test86.in 2013-05-29 22:15:26.000000000 +0200 +--- src/testdir/test86.in 2013-05-29 22:29:26.000000000 +0200 +*************** +*** 691,696 **** +--- 691,714 ---- + cb.append(expr + ':' + attr + ':' + repr(type(eval(expr)) is getattr(vim, attr))) + EOF + :" ++ :" Test __dir__() method ++ py << EOF ++ for name, o in ( ++ ('current', vim.current), ++ ('buffer', vim.current.buffer), ++ ('window', vim.current.window), ++ ('tabpage', vim.current.tabpage), ++ ('range', vim.current.range), ++ ('dictionary', vim.bindeval('{}')), ++ ('list', vim.bindeval('[]')), ++ ('function', vim.bindeval('function("tr")')), ++ ('output', sys.stdout), ++ ): ++ cb.append(name + ':' + ','.join(dir(o))) ++ del name ++ del o ++ EOF ++ :" + :" Test exceptions + :fun Exe(e) + : execute a:e +*** ../vim-7.3.1046/src/testdir/test86.ok 2013-05-29 22:15:26.000000000 +0200 +--- src/testdir/test86.ok 2013-05-29 22:29:26.000000000 +0200 +*************** +*** 382,387 **** +--- 382,396 ---- + vim.current.range:Range:True + vim.current.window:Window:True + vim.current.tabpage:TabPage:True ++ current:__dir__,__members__,buffer,line,range,tabpage,window ++ buffer:__dir__,__members__,append,mark,name,number,options,range,valid,vars ++ window:__dir__,__members__,buffer,col,cursor,height,number,options,row,tabpage,valid,vars ++ tabpage:__dir__,__members__,number,valid,vars,window,windows ++ range:__dir__,__members__,append,end,start ++ dictionary:__dir__,__members__,keys,locked,scope ++ list:__dir__,__members__,extend,locked ++ function:__call__,__dir__,__members__,softspace ++ output:__dir__,__members__,flush,softspace,write,writelines + (, error('abc',)) + (, error('def',)) + (, error('ghi',)) +*** ../vim-7.3.1046/src/testdir/test87.in 2013-05-29 22:15:26.000000000 +0200 +--- src/testdir/test87.in 2013-05-29 22:29:26.000000000 +0200 +*************** +*** 669,674 **** +--- 669,692 ---- + cb.append(expr + ':' + attr + ':' + repr(type(eval(expr)) is getattr(vim, attr))) + EOF + :" ++ :" Test __dir__() method ++ py3 << EOF ++ for name, o in ( ++ ('current', vim.current), ++ ('buffer', vim.current.buffer), ++ ('window', vim.current.window), ++ ('tabpage', vim.current.tabpage), ++ ('range', vim.current.range), ++ ('dictionary', vim.bindeval('{}')), ++ ('list', vim.bindeval('[]')), ++ ('function', vim.bindeval('function("tr")')), ++ ('output', sys.stdout), ++ ): ++ cb.append(name + ':' + ','.join(dir(o))) ++ del name ++ del o ++ EOF ++ :" + :" Test exceptions + :fun Exe(e) + : execute a:e +*** ../vim-7.3.1046/src/testdir/test87.ok 2013-05-29 22:15:26.000000000 +0200 +--- src/testdir/test87.ok 2013-05-29 22:29:26.000000000 +0200 +*************** +*** 371,376 **** +--- 371,385 ---- + vim.current.range:Range:True + vim.current.window:Window:True + vim.current.tabpage:TabPage:True ++ current:__dir__,buffer,line,range,tabpage,window ++ buffer:__dir__,append,mark,name,number,options,range,valid,vars ++ window:__dir__,buffer,col,cursor,height,number,options,row,tabpage,valid,vars ++ tabpage:__dir__,number,valid,vars,window,windows ++ range:__dir__,append,end,start ++ dictionary:__dir__,keys,locked,scope ++ list:__dir__,extend,locked ++ function:__call__,__dir__,softspace ++ output:__dir__,flush,softspace,write,writelines + (, error('abc',)) + (, error('def',)) + (, error('ghi',)) +*** ../vim-7.3.1046/src/version.c 2013-05-29 22:26:15.000000000 +0200 +--- src/version.c 2013-05-29 22:35:24.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1047, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +22. You've already visited all the links at Yahoo and you're halfway through + Lycos. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 252336a2c612b9f3de645f6d4463a8cec989a92b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:20 +0200 Subject: [PATCH 0939/3340] - patchlevel 1048 --- 7.3.1048 | 614 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 614 insertions(+) create mode 100644 7.3.1048 diff --git a/7.3.1048 b/7.3.1048 new file mode 100644 index 00000000..3fcf6103 --- /dev/null +++ b/7.3.1048 @@ -0,0 +1,614 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1048 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1048 +Problem: Python: no consistent naming. +Solution: Python patch 9: Rename d to dict and lookupDict to lookup_dict. + (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1047/src/if_py_both.h 2013-05-29 22:36:06.000000000 +0200 +--- src/if_py_both.h 2013-05-29 22:39:16.000000000 +0200 +*************** +*** 475,481 **** + * you call VimToPython. + */ + static PyObject * +! VimToPython(typval_T *our_tv, int depth, PyObject *lookupDict) + { + PyObject *result; + PyObject *newObj; +--- 475,481 ---- + * you call VimToPython. + */ + static PyObject * +! VimToPython(typval_T *our_tv, int depth, PyObject *lookup_dict) + { + PyObject *result; + PyObject *newObj; +*************** +*** 489,495 **** + return result; + } + +! /* Check if we run into a recursive loop. The item must be in lookupDict + * then and we can use it again. */ + if ((our_tv->v_type == VAR_LIST && our_tv->vval.v_list != NULL) + || (our_tv->v_type == VAR_DICT && our_tv->vval.v_dict != NULL)) +--- 489,495 ---- + return result; + } + +! /* Check if we run into a recursive loop. The item must be in lookup_dict + * then and we can use it again. */ + if ((our_tv->v_type == VAR_LIST && our_tv->vval.v_list != NULL) + || (our_tv->v_type == VAR_DICT && our_tv->vval.v_dict != NULL)) +*************** +*** 498,504 **** + our_tv->v_type == VAR_LIST ? (void *)our_tv->vval.v_list + : (void *)our_tv->vval.v_dict); + +! if ((result = PyDict_GetItemString(lookupDict, ptrBuf))) + { + Py_INCREF(result); + return result; +--- 498,504 ---- + our_tv->v_type == VAR_LIST ? (void *)our_tv->vval.v_list + : (void *)our_tv->vval.v_dict); + +! if ((result = PyDict_GetItemString(lookup_dict, ptrBuf))) + { + Py_INCREF(result); + return result; +*************** +*** 538,544 **** + if (!(result = PyList_New(0))) + return NULL; + +! if (PyDict_SetItemString(lookupDict, ptrBuf, result)) + { + Py_DECREF(result); + return NULL; +--- 538,544 ---- + if (!(result = PyList_New(0))) + return NULL; + +! if (PyDict_SetItemString(lookup_dict, ptrBuf, result)) + { + Py_DECREF(result); + return NULL; +*************** +*** 546,552 **** + + for (curr = list->lv_first; curr != NULL; curr = curr->li_next) + { +! if (!(newObj = VimToPython(&curr->li_tv, depth + 1, lookupDict))) + { + Py_DECREF(result); + return NULL; +--- 546,552 ---- + + for (curr = list->lv_first; curr != NULL; curr = curr->li_next) + { +! if (!(newObj = VimToPython(&curr->li_tv, depth + 1, lookup_dict))) + { + Py_DECREF(result); + return NULL; +*************** +*** 573,579 **** + if (!(result = PyDict_New())) + return NULL; + +! if (PyDict_SetItemString(lookupDict, ptrBuf, result)) + { + Py_DECREF(result); + return NULL; +--- 573,579 ---- + if (!(result = PyDict_New())) + return NULL; + +! if (PyDict_SetItemString(lookup_dict, ptrBuf, result)) + { + Py_DECREF(result); + return NULL; +*************** +*** 586,592 **** + --todo; + + di = dict_lookup(hi); +! if (!(newObj = VimToPython(&di->di_tv, depth + 1, lookupDict))) + { + Py_DECREF(result); + return NULL; +--- 586,592 ---- + --todo; + + di = dict_lookup(hi); +! if (!(newObj = VimToPython(&di->di_tv, depth + 1, lookup_dict))) + { + Py_DECREF(result); + return NULL; +*************** +*** 970,980 **** + { + char_u *key; + typval_T tv; +! dict_T *d = self->dict; + dictitem_T *di; + DICTKEY_DECL + +! if (d->dv_lock) + { + PyErr_SetVim(_("dict is locked")); + return -1; +--- 970,980 ---- + { + char_u *key; + typval_T tv; +! dict_T *dict = self->dict; + dictitem_T *di; + DICTKEY_DECL + +! if (dict->dv_lock) + { + PyErr_SetVim(_("dict is locked")); + return -1; +*************** +*** 982,988 **** + + DICTKEY_GET_NOTEMPTY(-1) + +! di = dict_find(d, key, -1); + + if (valObject == NULL) + { +--- 982,988 ---- + + DICTKEY_GET_NOTEMPTY(-1) + +! di = dict_find(dict, key, -1); + + if (valObject == NULL) + { +*************** +*** 994,1001 **** + PyErr_SetObject(PyExc_KeyError, keyObject); + return -1; + } +! hi = hash_find(&d->dv_hashtab, di->di_key); +! hash_remove(&d->dv_hashtab, hi); + dictitem_free(di); + return 0; + } +--- 994,1001 ---- + PyErr_SetObject(PyExc_KeyError, keyObject); + return -1; + } +! hi = hash_find(&dict->dv_hashtab, di->di_key); +! hash_remove(&dict->dv_hashtab, hi); + dictitem_free(di); + return 0; + } +*************** +*** 1013,1019 **** + } + di->di_tv.v_lock = 0; + +! if (dict_add(d, di) == FAIL) + { + DICTKEY_UNREF + vim_free(di); +--- 1013,1019 ---- + } + di->di_tv.v_lock = 0; + +! if (dict_add(dict, di) == FAIL) + { + DICTKEY_UNREF + vim_free(di); +*************** +*** 1102,1108 **** + } + + static int +! list_py_concat(list_T *l, PyObject *obj, PyObject *lookupDict) + { + Py_ssize_t i; + Py_ssize_t lsize = PySequence_Size(obj); +--- 1102,1108 ---- + } + + static int +! list_py_concat(list_T *l, PyObject *obj, PyObject *lookup_dict) + { + Py_ssize_t i; + Py_ssize_t lsize = PySequence_Size(obj); +*************** +*** 1122,1128 **** + litem = PySequence_GetItem(obj, i); + if (litem == NULL) + return -1; +! if (_ConvertFromPyObject(litem, &li->li_tv, lookupDict) == -1) + return -1; + + list_append(l, li); +--- 1122,1128 ---- + litem = PySequence_GetItem(obj, i); + if (litem == NULL) + return -1; +! if (_ConvertFromPyObject(litem, &li->li_tv, lookup_dict) == -1) + return -1; + + list_append(l, li); +*************** +*** 4009,4032 **** + } + + static int +! pydict_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) + { +! dict_T *d; + char_u *key; + dictitem_T *di; + PyObject *keyObject; + PyObject *valObject; + Py_ssize_t iter = 0; + +! d = dict_alloc(); +! if (d == NULL) + { + PyErr_NoMemory(); + return -1; + } + + tv->v_type = VAR_DICT; +! tv->vval.v_dict = d; + + while (PyDict_Next(obj, &iter, &keyObject, &valObject)) + { +--- 4009,4032 ---- + } + + static int +! pydict_to_tv(PyObject *obj, typval_T *tv, PyObject *lookup_dict) + { +! dict_T *dict; + char_u *key; + dictitem_T *di; + PyObject *keyObject; + PyObject *valObject; + Py_ssize_t iter = 0; + +! dict = dict_alloc(); +! if (dict == NULL) + { + PyErr_NoMemory(); + return -1; + } + + tv->v_type = VAR_DICT; +! tv->vval.v_dict = dict; + + while (PyDict_Next(obj, &iter, &keyObject, &valObject)) + { +*************** +*** 4050,4061 **** + } + di->di_tv.v_lock = 0; + +! if (_ConvertFromPyObject(valObject, &di->di_tv, lookupDict) == -1) + { + vim_free(di); + return -1; + } +! if (dict_add(d, di) == FAIL) + { + vim_free(di); + PyErr_SetVim(_("failed to add key to dictionary")); +--- 4050,4062 ---- + } + di->di_tv.v_lock = 0; + +! if (_ConvertFromPyObject(valObject, &di->di_tv, lookup_dict) == -1) + { + vim_free(di); + return -1; + } +! +! if (dict_add(dict, di) == FAIL) + { + vim_free(di); + PyErr_SetVim(_("failed to add key to dictionary")); +*************** +*** 4066,4074 **** + } + + static int +! pymap_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) + { +! dict_T *d; + char_u *key; + dictitem_T *di; + PyObject *list; +--- 4067,4075 ---- + } + + static int +! pymap_to_tv(PyObject *obj, typval_T *tv, PyObject *lookup_dict) + { +! dict_T *dict; + char_u *key; + dictitem_T *di; + PyObject *list; +*************** +*** 4077,4091 **** + PyObject *valObject; + Py_ssize_t lsize; + +! d = dict_alloc(); +! if (d == NULL) + { + PyErr_NoMemory(); + return -1; + } + + tv->v_type = VAR_DICT; +! tv->vval.v_dict = d; + + list = PyMapping_Items(obj); + if (list == NULL) +--- 4078,4092 ---- + PyObject *valObject; + Py_ssize_t lsize; + +! dict = dict_alloc(); +! if (dict == NULL) + { + PyErr_NoMemory(); + return -1; + } + + tv->v_type = VAR_DICT; +! tv->vval.v_dict = dict; + + list = PyMapping_Items(obj); + if (list == NULL) +*************** +*** 4133,4146 **** + } + di->di_tv.v_lock = 0; + +! if (_ConvertFromPyObject(valObject, &di->di_tv, lookupDict) == -1) + { + vim_free(di); + Py_DECREF(list); + Py_DECREF(litem); + return -1; + } +! if (dict_add(d, di) == FAIL) + { + vim_free(di); + Py_DECREF(list); +--- 4134,4147 ---- + } + di->di_tv.v_lock = 0; + +! if (_ConvertFromPyObject(valObject, &di->di_tv, lookup_dict) == -1) + { + vim_free(di); + Py_DECREF(list); + Py_DECREF(litem); + return -1; + } +! if (dict_add(dict, di) == FAIL) + { + vim_free(di); + Py_DECREF(list); +*************** +*** 4155,4161 **** + } + + static int +! pyseq_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) + { + list_T *l; + +--- 4156,4162 ---- + } + + static int +! pyseq_to_tv(PyObject *obj, typval_T *tv, PyObject *lookup_dict) + { + list_T *l; + +*************** +*** 4169,4182 **** + tv->v_type = VAR_LIST; + tv->vval.v_list = l; + +! if (list_py_concat(l, obj, lookupDict) == -1) + return -1; + + return 0; + } + + static int +! pyiter_to_tv(PyObject *obj, typval_T *tv, PyObject *lookupDict) + { + PyObject *iterator = PyObject_GetIter(obj); + PyObject *item; +--- 4170,4183 ---- + tv->v_type = VAR_LIST; + tv->vval.v_list = l; + +! if (list_py_concat(l, obj, lookup_dict) == -1) + return -1; + + return 0; + } + + static int +! pyiter_to_tv(PyObject *obj, typval_T *tv, PyObject *lookup_dict) + { + PyObject *iterator = PyObject_GetIter(obj); + PyObject *item; +*************** +*** 4208,4214 **** + } + li->li_tv.v_lock = 0; + +! if (_ConvertFromPyObject(item, &li->li_tv, lookupDict) == -1) + return -1; + + list_append(l, li); +--- 4209,4215 ---- + } + li->li_tv.v_lock = 0; + +! if (_ConvertFromPyObject(item, &li->li_tv, lookup_dict) == -1) + return -1; + + list_append(l, li); +*************** +*** 4224,4230 **** + + static int + convert_dl(PyObject *obj, typval_T *tv, +! pytotvfunc py_to_tv, PyObject *lookupDict) + { + PyObject *capsule; + char hexBuf[sizeof(void *) * 2 + 3]; +--- 4225,4231 ---- + + static int + convert_dl(PyObject *obj, typval_T *tv, +! pytotvfunc py_to_tv, PyObject *lookup_dict) + { + PyObject *capsule; + char hexBuf[sizeof(void *) * 2 + 3]; +*************** +*** 4232,4240 **** + sprintf(hexBuf, "%p", obj); + + # ifdef PY_USE_CAPSULE +! capsule = PyDict_GetItemString(lookupDict, hexBuf); + # else +! capsule = (PyObject *)PyDict_GetItemString(lookupDict, hexBuf); + # endif + if (capsule == NULL) + { +--- 4233,4241 ---- + sprintf(hexBuf, "%p", obj); + + # ifdef PY_USE_CAPSULE +! capsule = PyDict_GetItemString(lookup_dict, hexBuf); + # else +! capsule = (PyObject *)PyDict_GetItemString(lookup_dict, hexBuf); + # endif + if (capsule == NULL) + { +*************** +*** 4243,4251 **** + # else + capsule = PyCObject_FromVoidPtr(tv, NULL); + # endif +! PyDict_SetItemString(lookupDict, hexBuf, capsule); + Py_DECREF(capsule); +! if (py_to_tv(obj, tv, lookupDict) == -1) + { + tv->v_type = VAR_UNKNOWN; + return -1; +--- 4244,4252 ---- + # else + capsule = PyCObject_FromVoidPtr(tv, NULL); + # endif +! PyDict_SetItemString(lookup_dict, hexBuf, capsule); + Py_DECREF(capsule); +! if (py_to_tv(obj, tv, lookup_dict) == -1) + { + tv->v_type = VAR_UNKNOWN; + return -1; +*************** +*** 4285,4291 **** + } + + static int +! _ConvertFromPyObject(PyObject *obj, typval_T *tv, PyObject *lookupDict) + { + if (obj->ob_type == &DictionaryType) + { +--- 4286,4292 ---- + } + + static int +! _ConvertFromPyObject(PyObject *obj, typval_T *tv, PyObject *lookup_dict) + { + if (obj->ob_type == &DictionaryType) + { +*************** +*** 4357,4363 **** + tv->vval.v_number = (varnumber_T) PyLong_AsLong(obj); + } + else if (PyDict_Check(obj)) +! return convert_dl(obj, tv, pydict_to_tv, lookupDict); + #ifdef FEAT_FLOAT + else if (PyFloat_Check(obj)) + { +--- 4358,4364 ---- + tv->vval.v_number = (varnumber_T) PyLong_AsLong(obj); + } + else if (PyDict_Check(obj)) +! return convert_dl(obj, tv, pydict_to_tv, lookup_dict); + #ifdef FEAT_FLOAT + else if (PyFloat_Check(obj)) + { +*************** +*** 4366,4376 **** + } + #endif + else if (PyIter_Check(obj)) +! return convert_dl(obj, tv, pyiter_to_tv, lookupDict); + else if (PySequence_Check(obj)) +! return convert_dl(obj, tv, pyseq_to_tv, lookupDict); + else if (PyMapping_Check(obj)) +! return convert_dl(obj, tv, pymap_to_tv, lookupDict); + else + { + PyErr_SetString(PyExc_TypeError, +--- 4367,4377 ---- + } + #endif + else if (PyIter_Check(obj)) +! return convert_dl(obj, tv, pyiter_to_tv, lookup_dict); + else if (PySequence_Check(obj)) +! return convert_dl(obj, tv, pyseq_to_tv, lookup_dict); + else if (PyMapping_Check(obj)) +! return convert_dl(obj, tv, pymap_to_tv, lookup_dict); + else + { + PyErr_SetString(PyExc_TypeError, +*** ../vim-7.3.1047/src/version.c 2013-05-29 22:36:06.000000000 +0200 +--- src/version.c 2013-05-29 22:38:23.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1048, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +23. You can't call your mother...she doesn't have a modem. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 60c4f8391058f2b89e5a77c738e39e09a29caf29 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:21 +0200 Subject: [PATCH 0940/3340] - patchlevel 1049 --- 7.3.1049 | 177 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 177 insertions(+) create mode 100644 7.3.1049 diff --git a/7.3.1049 b/7.3.1049 new file mode 100644 index 00000000..e275c12e --- /dev/null +++ b/7.3.1049 @@ -0,0 +1,177 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1049 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1049 +Problem: Python: no consistent naming +Solution: Python patch 10: Rename DICTKEY_GET_NOTEMPTY to DICTKEY_GET. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1048/src/if_py_both.h 2013-05-29 22:39:46.000000000 +0200 +--- src/if_py_both.h 2013-05-29 22:42:26.000000000 +0200 +*************** +*** 34,40 **** + PyObject *dictkey_todecref; + #define DICTKEY_GET(err) \ + if (!(key = StringToChars(keyObject, &dictkey_todecref))) \ +! return err; + #define DICTKEY_UNREF \ + Py_XDECREF(dictkey_todecref); + +--- 34,45 ---- + PyObject *dictkey_todecref; + #define DICTKEY_GET(err) \ + if (!(key = StringToChars(keyObject, &dictkey_todecref))) \ +! return err; \ +! if (*key == NUL) \ +! { \ +! PyErr_SetString(PyExc_ValueError, _("empty keys are not allowed")); \ +! return err; \ +! } + #define DICTKEY_UNREF \ + Py_XDECREF(dictkey_todecref); + +*************** +*** 851,864 **** + + static PyTypeObject DictionaryType; + +- #define DICTKEY_GET_NOTEMPTY(err) \ +- DICTKEY_GET(err) \ +- if (*key == NUL) \ +- { \ +- PyErr_SetString(PyExc_ValueError, _("empty keys are not allowed")); \ +- return err; \ +- } +- + typedef struct + { + PyObject_HEAD +--- 856,861 ---- +*************** +*** 950,956 **** + dictitem_T *di; + DICTKEY_DECL + +! DICTKEY_GET_NOTEMPTY(NULL) + + di = dict_find(self->dict, key, -1); + +--- 947,953 ---- + dictitem_T *di; + DICTKEY_DECL + +! DICTKEY_GET(NULL) + + di = dict_find(self->dict, key, -1); + +*************** +*** 980,986 **** + return -1; + } + +! DICTKEY_GET_NOTEMPTY(-1) + + di = dict_find(dict, key, -1); + +--- 977,983 ---- + return -1; + } + +! DICTKEY_GET(-1) + + di = dict_find(dict, key, -1); + +*************** +*** 1653,1659 **** + if (self->Check(self->from)) + return NULL; + +! DICTKEY_GET_NOTEMPTY(NULL) + + flags = get_option_value_strict(key, &numval, &stringval, + self->opt_type, self->from); +--- 1650,1656 ---- + if (self->Check(self->from)) + return NULL; + +! DICTKEY_GET(NULL) + + flags = get_option_value_strict(key, &numval, &stringval, + self->opt_type, self->from); +*************** +*** 1792,1798 **** + if (self->Check(self->from)) + return -1; + +! DICTKEY_GET_NOTEMPTY(-1) + + flags = get_option_value_strict(key, NULL, NULL, + self->opt_type, self->from); +--- 1789,1795 ---- + if (self->Check(self->from)) + return -1; + +! DICTKEY_GET(-1) + + flags = get_option_value_strict(key, NULL, NULL, + self->opt_type, self->from); +*************** +*** 4037,4043 **** + if (valObject == NULL) + return -1; + +! DICTKEY_GET_NOTEMPTY(-1) + + di = dictitem_alloc(key); + +--- 4034,4040 ---- + if (valObject == NULL) + return -1; + +! DICTKEY_GET(-1) + + di = dictitem_alloc(key); + +*************** +*** 4111,4117 **** + return -1; + } + +! DICTKEY_GET_NOTEMPTY(-1) + + valObject = PyTuple_GetItem(litem, 1); + if (valObject == NULL) +--- 4108,4114 ---- + return -1; + } + +! DICTKEY_GET(-1) + + valObject = PyTuple_GetItem(litem, 1); + if (valObject == NULL) +*** ../vim-7.3.1048/src/version.c 2013-05-29 22:39:46.000000000 +0200 +--- src/version.c 2013-05-29 22:42:23.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1049, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +24. You realize there is not a sound in the house and you have no idea where + your children are. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e9489defde857718379fc67098bae0a11580bbd1 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:21 +0200 Subject: [PATCH 0941/3340] - patchlevel 1050 --- 7.3.1050 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.1050 diff --git a/7.3.1050 b/7.3.1050 new file mode 100644 index 00000000..d1c4842f --- /dev/null +++ b/7.3.1050 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1050 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1050 +Problem: Python: Typo in pyiter_to_tv. +Solution: Python patch 11. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1049/src/if_py_both.h 2013-05-29 22:43:32.000000000 +0200 +--- src/if_py_both.h 2013-05-29 22:45:42.000000000 +0200 +*************** +*** 4196,4202 **** + if (iterator == NULL) + return -1; + +! while ((item = PyIter_Next(obj))) + { + li = listitem_alloc(); + if (li == NULL) +--- 4196,4202 ---- + if (iterator == NULL) + return -1; + +! while ((item = PyIter_Next(iterator))) + { + li = listitem_alloc(); + if (li == NULL) +*** ../vim-7.3.1049/src/version.c 2013-05-29 22:43:32.000000000 +0200 +--- src/version.c 2013-05-29 22:45:58.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1050, + /**/ + +-- +Computers are useless. They can only give you answers. + -- Pablo Picasso + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8c0a7c7824a132c32e3537a36b4328f4071c4b4e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:22 +0200 Subject: [PATCH 0942/3340] - patchlevel 1051 --- 7.3.1051 | 332 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 332 insertions(+) create mode 100644 7.3.1051 diff --git a/7.3.1051 b/7.3.1051 new file mode 100644 index 00000000..e9375355 --- /dev/null +++ b/7.3.1051 @@ -0,0 +1,332 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1051 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1051 +Problem: Python: possible memory leaks. +Solution: Python patch 12: fix the leaks (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1050/src/if_py_both.h 2013-05-29 22:46:22.000000000 +0200 +--- src/if_py_both.h 2013-05-29 22:48:45.000000000 +0200 +*************** +*** 32,40 **** + + #define DICTKEY_DECL \ + PyObject *dictkey_todecref; +! #define DICTKEY_GET(err) \ + if (!(key = StringToChars(keyObject, &dictkey_todecref))) \ + return err; \ + if (*key == NUL) \ + { \ + PyErr_SetString(PyExc_ValueError, _("empty keys are not allowed")); \ +--- 32,48 ---- + + #define DICTKEY_DECL \ + PyObject *dictkey_todecref; +! #define DICTKEY_GET(err, decref) \ + if (!(key = StringToChars(keyObject, &dictkey_todecref))) \ ++ { \ ++ if (decref) \ ++ { \ ++ Py_DECREF(keyObject); \ ++ } \ + return err; \ ++ } \ ++ if (decref && !dictkey_todecref) \ ++ dictkey_todecref = keyObject; \ + if (*key == NUL) \ + { \ + PyErr_SetString(PyExc_ValueError, _("empty keys are not allowed")); \ +*************** +*** 602,608 **** + Py_DECREF(newObj); + return NULL; + } +- Py_DECREF(newObj); + } + } + } +--- 610,615 ---- +*************** +*** 947,953 **** + dictitem_T *di; + DICTKEY_DECL + +! DICTKEY_GET(NULL) + + di = dict_find(self->dict, key, -1); + +--- 954,960 ---- + dictitem_T *di; + DICTKEY_DECL + +! DICTKEY_GET(NULL, 0) + + di = dict_find(self->dict, key, -1); + +*************** +*** 977,983 **** + return -1; + } + +! DICTKEY_GET(-1) + + di = dict_find(dict, key, -1); + +--- 984,990 ---- + return -1; + } + +! DICTKEY_GET(-1, 0) + + di = dict_find(dict, key, -1); + +*************** +*** 1650,1656 **** + if (self->Check(self->from)) + return NULL; + +! DICTKEY_GET(NULL) + + flags = get_option_value_strict(key, &numval, &stringval, + self->opt_type, self->from); +--- 1657,1663 ---- + if (self->Check(self->from)) + return NULL; + +! DICTKEY_GET(NULL, 0) + + flags = get_option_value_strict(key, &numval, &stringval, + self->opt_type, self->from); +*************** +*** 1789,1795 **** + if (self->Check(self->from)) + return -1; + +! DICTKEY_GET(-1) + + flags = get_option_value_strict(key, NULL, NULL, + self->opt_type, self->from); +--- 1796,1802 ---- + if (self->Check(self->from)) + return -1; + +! DICTKEY_GET(-1, 0) + + flags = get_option_value_strict(key, NULL, NULL, + self->opt_type, self->from); +*************** +*** 4029,4040 **** + { + DICTKEY_DECL + +! if (keyObject == NULL) +! return -1; +! if (valObject == NULL) + return -1; + +! DICTKEY_GET(-1) + + di = dictitem_alloc(key); + +--- 4036,4045 ---- + { + DICTKEY_DECL + +! if (keyObject == NULL || valObject == NULL) + return -1; + +! DICTKEY_GET(-1, 0) + + di = dictitem_alloc(key); + +*************** +*** 4055,4060 **** +--- 4060,4066 ---- + + if (dict_add(dict, di) == FAIL) + { ++ clear_tv(&di->di_tv); + vim_free(di); + PyErr_SetVim(_("failed to add key to dictionary")); + return -1; +*************** +*** 4100,4123 **** + return -1; + } + +! keyObject = PyTuple_GetItem(litem, 0); +! if (keyObject == NULL) + { + Py_DECREF(list); + Py_DECREF(litem); + return -1; + } + +! DICTKEY_GET(-1) + +! valObject = PyTuple_GetItem(litem, 1); +! if (valObject == NULL) + { + Py_DECREF(list); + Py_DECREF(litem); + return -1; + } + + di = dictitem_alloc(key); + + DICTKEY_UNREF +--- 4106,4130 ---- + return -1; + } + +! if (!(keyObject = PyTuple_GetItem(litem, 0))) + { + Py_DECREF(list); + Py_DECREF(litem); + return -1; + } + +! DICTKEY_GET(-1, 1) + +! if (!(valObject = PyTuple_GetItem(litem, 1))) + { + Py_DECREF(list); + Py_DECREF(litem); ++ DICTKEY_UNREF + return -1; + } + ++ Py_DECREF(litem); ++ + di = dictitem_alloc(key); + + DICTKEY_UNREF +*************** +*** 4125,4131 **** + if (di == NULL) + { + Py_DECREF(list); +! Py_DECREF(litem); + PyErr_NoMemory(); + return -1; + } +--- 4132,4138 ---- + if (di == NULL) + { + Py_DECREF(list); +! Py_DECREF(valObject); + PyErr_NoMemory(); + return -1; + } +*************** +*** 4135,4152 **** + { + vim_free(di); + Py_DECREF(list); +! Py_DECREF(litem); + return -1; + } + if (dict_add(dict, di) == FAIL) + { + vim_free(di); + Py_DECREF(list); +- Py_DECREF(litem); + PyErr_SetVim(_("failed to add key to dictionary")); + return -1; + } +- Py_DECREF(litem); + } + Py_DECREF(list); + return 0; +--- 4142,4161 ---- + { + vim_free(di); + Py_DECREF(list); +! Py_DECREF(valObject); + return -1; + } ++ ++ Py_DECREF(valObject); ++ + if (dict_add(dict, di) == FAIL) + { ++ clear_tv(&di->di_tv); + vim_free(di); + Py_DECREF(list); + PyErr_SetVim(_("failed to add key to dictionary")); + return -1; + } + } + Py_DECREF(list); + return 0; +*************** +*** 4201,4213 **** +--- 4210,4227 ---- + li = listitem_alloc(); + if (li == NULL) + { ++ Py_DECREF(iterator); + PyErr_NoMemory(); + return -1; + } + li->li_tv.v_lock = 0; + + if (_ConvertFromPyObject(item, &li->li_tv, lookup_dict) == -1) ++ { ++ Py_DECREF(item); ++ Py_DECREF(iterator); + return -1; ++ } + + list_append(l, li); + +*************** +*** 4241,4248 **** + # else + capsule = PyCObject_FromVoidPtr(tv, NULL); + # endif +! PyDict_SetItemString(lookup_dict, hexBuf, capsule); +! Py_DECREF(capsule); + if (py_to_tv(obj, tv, lookup_dict) == -1) + { + tv->v_type = VAR_UNKNOWN; +--- 4255,4266 ---- + # else + capsule = PyCObject_FromVoidPtr(tv, NULL); + # endif +! if (PyDict_SetItemString(lookup_dict, hexBuf, capsule)) +! { +! Py_DECREF(capsule); +! tv->v_type = VAR_UNKNOWN; +! return -1; +! } + if (py_to_tv(obj, tv, lookup_dict) == -1) + { + tv->v_type = VAR_UNKNOWN; +*** ../vim-7.3.1050/src/version.c 2013-05-29 22:46:22.000000000 +0200 +--- src/version.c 2013-05-29 22:48:31.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1051, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +25. You believe nothing looks sexier than a man in boxer shorts illuminated + only by a 17" inch svga monitor. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8e6384d7647574ecfa8ddd279e4e37b0b6a51bd9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:23 +0200 Subject: [PATCH 0943/3340] - patchlevel 1052 --- 7.3.1052 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.1052 diff --git a/7.3.1052 b/7.3.1052 new file mode 100644 index 00000000..7f587a95 --- /dev/null +++ b/7.3.1052 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1052 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1052 +Problem: Python: possible SEGV and negative refcount. +Solution: Python patch 13: Fix IterIter function. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1051/src/if_py_both.h 2013-05-29 22:49:21.000000000 +0200 +--- src/if_py_both.h 2013-05-29 22:51:59.000000000 +0200 +*************** +*** 814,819 **** +--- 814,820 ---- + static PyObject * + IterIter(PyObject *self) + { ++ Py_INCREF(self); + return self; + } + +*** ../vim-7.3.1051/src/version.c 2013-05-29 22:49:21.000000000 +0200 +--- src/version.c 2013-05-29 22:51:45.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1052, + /**/ + +-- +Q: What is the difference betwee open-source and commercial software? +A: If you have a problem with commercial software you can call a phone + number and they will tell you it might be solved in a future version. + For open-source software there isn't a phone number to call, but you + get the solution within a day. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2cc3cb053279b96a8e2c80c6f9a8699d97f0ea02 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:23 +0200 Subject: [PATCH 0944/3340] - patchlevel 1053 --- 7.3.1053 | 103 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 103 insertions(+) create mode 100644 7.3.1053 diff --git a/7.3.1053 b/7.3.1053 new file mode 100644 index 00000000..456deb25 --- /dev/null +++ b/7.3.1053 @@ -0,0 +1,103 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1053 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1053 +Problem: Python: no flag for types with tp_traverse+tp_clear. +Solution: Python patch 14: Add Py_TPFLAGS_HAVE_GC. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1052/src/if_py_both.h 2013-05-29 22:52:29.000000000 +0200 +--- src/if_py_both.h 2013-05-29 22:55:08.000000000 +0200 +*************** +*** 4461,4467 **** + vim_memset(&IterType, 0, sizeof(IterType)); + IterType.tp_name = "vim.iter"; + IterType.tp_basicsize = sizeof(IterObject); +! IterType.tp_flags = Py_TPFLAGS_DEFAULT; + IterType.tp_doc = "generic iterator object"; + IterType.tp_iter = (getiterfunc)IterIter; + IterType.tp_iternext = (iternextfunc)IterNext; +--- 4461,4467 ---- + vim_memset(&IterType, 0, sizeof(IterType)); + IterType.tp_name = "vim.iter"; + IterType.tp_basicsize = sizeof(IterObject); +! IterType.tp_flags = Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_GC; + IterType.tp_doc = "generic iterator object"; + IterType.tp_iter = (getiterfunc)IterIter; + IterType.tp_iternext = (iternextfunc)IterNext; +*************** +*** 4495,4501 **** + WindowType.tp_basicsize = sizeof(WindowObject); + WindowType.tp_dealloc = (destructor)WindowDestructor; + WindowType.tp_repr = (reprfunc)WindowRepr; +! WindowType.tp_flags = Py_TPFLAGS_DEFAULT; + WindowType.tp_doc = "vim Window object"; + WindowType.tp_methods = WindowMethods; + WindowType.tp_traverse = (traverseproc)WindowTraverse; +--- 4495,4501 ---- + WindowType.tp_basicsize = sizeof(WindowObject); + WindowType.tp_dealloc = (destructor)WindowDestructor; + WindowType.tp_repr = (reprfunc)WindowRepr; +! WindowType.tp_flags = Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_GC; + WindowType.tp_doc = "vim Window object"; + WindowType.tp_methods = WindowMethods; + WindowType.tp_traverse = (traverseproc)WindowTraverse; +*************** +*** 4558,4564 **** + RangeType.tp_repr = (reprfunc)RangeRepr; + RangeType.tp_as_sequence = &RangeAsSeq; + RangeType.tp_as_mapping = &RangeAsMapping; +! RangeType.tp_flags = Py_TPFLAGS_DEFAULT; + RangeType.tp_doc = "vim Range object"; + RangeType.tp_methods = RangeMethods; + RangeType.tp_traverse = (traverseproc)RangeTraverse; +--- 4558,4564 ---- + RangeType.tp_repr = (reprfunc)RangeRepr; + RangeType.tp_as_sequence = &RangeAsSeq; + RangeType.tp_as_mapping = &RangeAsMapping; +! RangeType.tp_flags = Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_GC; + RangeType.tp_doc = "vim Range object"; + RangeType.tp_methods = RangeMethods; + RangeType.tp_traverse = (traverseproc)RangeTraverse; +*************** +*** 4637,4643 **** + vim_memset(&OptionsType, 0, sizeof(OptionsType)); + OptionsType.tp_name = "vim.options"; + OptionsType.tp_basicsize = sizeof(OptionsObject); +! OptionsType.tp_flags = Py_TPFLAGS_DEFAULT; + OptionsType.tp_doc = "object for manipulating options"; + OptionsType.tp_as_mapping = &OptionsAsMapping; + OptionsType.tp_dealloc = (destructor)OptionsDestructor; +--- 4637,4643 ---- + vim_memset(&OptionsType, 0, sizeof(OptionsType)); + OptionsType.tp_name = "vim.options"; + OptionsType.tp_basicsize = sizeof(OptionsObject); +! OptionsType.tp_flags = Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_GC; + OptionsType.tp_doc = "object for manipulating options"; + OptionsType.tp_as_mapping = &OptionsAsMapping; + OptionsType.tp_dealloc = (destructor)OptionsDestructor; +*** ../vim-7.3.1052/src/version.c 2013-05-29 22:52:29.000000000 +0200 +--- src/version.c 2013-05-29 22:54:46.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1053, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +26. You check your mail. It says "no new messages." So you check it again. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1c124bd028e13e99f6a30b65da039ea7591fb7cc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:24 +0200 Subject: [PATCH 0945/3340] - patchlevel 1054 --- 7.3.1054 | 178 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 178 insertions(+) create mode 100644 7.3.1054 diff --git a/7.3.1054 b/7.3.1054 new file mode 100644 index 00000000..c354a6b2 --- /dev/null +++ b/7.3.1054 @@ -0,0 +1,178 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1054 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1054 (after 7.3.1042) +Problem: Can't build without the +autocmd feature. (Elimar Riesebieter) +Solution: Fix use of buf and curbuf. +Files: src/ex_cmds.c, src/testdir/test86.ok, src/testdir/test87.ok + + +*** ../vim-7.3.1053/src/ex_cmds.c 2013-05-29 22:02:18.000000000 +0200 +--- src/ex_cmds.c 2013-05-30 11:24:41.000000000 +0200 +*************** +*** 2421,2430 **** + char_u *new_fname; + { + char_u *fname, *sfname, *xfname; +! #ifdef FEAT_AUTOCMD +! buf_T *buf = curbuf; + +! apply_autocmds(EVENT_BUFFILEPRE, NULL, NULL, FALSE, buf); + /* buffer changed, don't change name now */ + if (buf != curbuf) + return FAIL; +--- 2421,2431 ---- + char_u *new_fname; + { + char_u *fname, *sfname, *xfname; +! buf_T *buf; + +! #ifdef FEAT_AUTOCMD +! buf = curbuf; +! apply_autocmds(EVENT_BUFFILEPRE, NULL, NULL, FALSE, curbuf); + /* buffer changed, don't change name now */ + if (buf != curbuf) + return FAIL; +*************** +*** 2440,2457 **** + * But don't set the alternate file name if the buffer didn't have a + * name. + */ +! fname = buf->b_ffname; +! sfname = buf->b_sfname; +! xfname = buf->b_fname; +! buf->b_ffname = NULL; +! buf->b_sfname = NULL; +! if (setfname(buf, new_fname, NULL, TRUE) == FAIL) + { +! buf->b_ffname = fname; +! buf->b_sfname = sfname; + return FAIL; + } +! buf->b_flags |= BF_NOTEDITED; + if (xfname != NULL && *xfname != NUL) + { + buf = buflist_new(fname, xfname, curwin->w_cursor.lnum, 0); +--- 2441,2458 ---- + * But don't set the alternate file name if the buffer didn't have a + * name. + */ +! fname = curbuf->b_ffname; +! sfname = curbuf->b_sfname; +! xfname = curbuf->b_fname; +! curbuf->b_ffname = NULL; +! curbuf->b_sfname = NULL; +! if (setfname(curbuf, new_fname, NULL, TRUE) == FAIL) + { +! curbuf->b_ffname = fname; +! curbuf->b_sfname = sfname; + return FAIL; + } +! curbuf->b_flags |= BF_NOTEDITED; + if (xfname != NULL && *xfname != NUL) + { + buf = buflist_new(fname, xfname, curwin->w_cursor.lnum, 0); +*************** +*** 2461,2467 **** + vim_free(fname); + vim_free(sfname); + #ifdef FEAT_AUTOCMD +! apply_autocmds(EVENT_BUFFILEPOST, NULL, NULL, FALSE, buf); + #endif + /* Change directories when the 'acd' option is set. */ + DO_AUTOCHDIR +--- 2462,2468 ---- + vim_free(fname); + vim_free(sfname); + #ifdef FEAT_AUTOCMD +! apply_autocmds(EVENT_BUFFILEPOST, NULL, NULL, FALSE, curbuf); + #endif + /* Change directories when the 'acd' option is set. */ + DO_AUTOCHDIR +*** ../vim-7.3.1053/src/testdir/test86.ok 2013-05-29 22:36:06.000000000 +0200 +--- src/testdir/test86.ok 2013-05-30 11:34:12.000000000 +0200 +*************** +*** 320,332 **** + Third line + foo + 1:BufFilePre:1 +! 6:BufFilePost:1 + testdir/foo + 5:BufFilePre:5 + 5:BufFilePost:5 + testdir/bar + 1:BufFilePre:1 +! 7:BufFilePost:1 + testdir/test86.in + valid: b:False, cb:True + i: +--- 320,332 ---- + Third line + foo + 1:BufFilePre:1 +! 1:BufFilePost:1 + testdir/foo + 5:BufFilePre:5 + 5:BufFilePost:5 + testdir/bar + 1:BufFilePre:1 +! 1:BufFilePost:1 + testdir/test86.in + valid: b:False, cb:True + i: +*** ../vim-7.3.1053/src/testdir/test87.ok 2013-05-29 22:36:06.000000000 +0200 +--- src/testdir/test87.ok 2013-05-30 11:34:26.000000000 +0200 +*************** +*** 309,321 **** + Third line + foo + 1:BufFilePre:1 +! 6:BufFilePost:1 + testdir/foo + 5:BufFilePre:5 + 5:BufFilePost:5 + testdir/bar + 1:BufFilePre:1 +! 7:BufFilePost:1 + testdir/test87.in + valid: b:False, cb:True + i: +--- 309,321 ---- + Third line + foo + 1:BufFilePre:1 +! 1:BufFilePost:1 + testdir/foo + 5:BufFilePre:5 + 5:BufFilePost:5 + testdir/bar + 1:BufFilePre:1 +! 1:BufFilePost:1 + testdir/test87.in + valid: b:False, cb:True + i: +*** ../vim-7.3.1053/src/version.c 2013-05-29 22:58:28.000000000 +0200 +--- src/version.c 2013-05-30 11:40:54.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1054, + /**/ + +-- +For a moment, nothing happened. +Then, after a second or so, nothing continued to happen. + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f7046f2ee425aeaa80ec7639ae6dea5a9ac5c75d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:25 +0200 Subject: [PATCH 0946/3340] - patchlevel 1055 --- 7.3.1055 | 112 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 112 insertions(+) create mode 100644 7.3.1055 diff --git a/7.3.1055 b/7.3.1055 new file mode 100644 index 00000000..0b7be2a6 --- /dev/null +++ b/7.3.1055 @@ -0,0 +1,112 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1055 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1055 +Problem: Negated collection does not match newline. +Solution: Handle newline differently. (Hiroshi Shirosaki) +Files: src/regexp_nfa.c, src/testdir/test64.ok, src/testdir/test64.in + + +*** ../vim-7.3.1054/src/regexp_nfa.c 2013-05-29 21:14:37.000000000 +0200 +--- src/regexp_nfa.c 2013-05-30 11:47:40.000000000 +0200 +*************** +*** 1203,1215 **** + } + mb_ptr_adv(regparse); + +- if (extra == ADD_NL) /* \_[] also matches \n */ +- { +- EMIT(reg_string ? NL : NFA_NEWL); +- TRY_NEG(); +- EMIT_GLUE(); +- } +- + /* skip the trailing ] */ + regparse = endp; + mb_ptr_adv(regparse); +--- 1203,1208 ---- +*************** +*** 1219,1224 **** +--- 1212,1225 ---- + EMIT(NFA_END_NEG_RANGE); + EMIT(NFA_CONCAT); + } ++ ++ /* \_[] also matches \n but it's not negated */ ++ if (extra == ADD_NL) ++ { ++ EMIT(reg_string ? NL : NFA_NEWL); ++ EMIT(NFA_OR); ++ } ++ + return OK; + } /* if exists closing ] */ + +*** ../vim-7.3.1054/src/testdir/test64.ok 2013-05-29 21:14:37.000000000 +0200 +--- src/testdir/test64.ok 2013-05-30 11:48:31.000000000 +0200 +*************** +*** 731,736 **** +--- 731,742 ---- + OK 1 - \(<<\)\@1<=span. + OK 0 - \(<<\)\@2<=span. + OK 1 - \(<<\)\@2<=span. ++ OK 0 - \_[^8-9]\+ ++ OK 1 - \_[^8-9]\+ ++ OK 2 - \_[^8-9]\+ ++ OK 0 - \_[^a]\+ ++ OK 1 - \_[^a]\+ ++ OK 2 - \_[^a]\+ + 192.168.0.1 + 192.168.0.1 + 192.168.0.1 +*** ../vim-7.3.1054/src/testdir/test64.in 2013-05-29 21:14:37.000000000 +0200 +--- src/testdir/test64.in 2013-05-30 11:45:59.000000000 +0200 +*************** +*** 344,351 **** + :call add(tl, [0, '\(<<\)\@1<=span.', 'xxspanxxxx Date: Tue, 4 Jun 2013 12:06:25 +0200 Subject: [PATCH 0947/3340] - patchlevel 1056 --- 7.3.1056 | 630 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 630 insertions(+) create mode 100644 7.3.1056 diff --git a/7.3.1056 b/7.3.1056 new file mode 100644 index 00000000..a07b8274 --- /dev/null +++ b/7.3.1056 @@ -0,0 +1,630 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1056 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1056 +Problem: Python: possible memory leaks. +Solution: Python patch 15. (ZyX) Fix will follow later. +Files: src/eval.c, src/if_py_both.h, src/proto/eval.pro + + +*** ../vim-7.3.1055/src/eval.c 2013-05-17 16:03:53.000000000 +0200 +--- src/eval.c 2013-05-30 12:11:40.000000000 +0200 +*************** +*** 412,418 **** + static int get_lit_string_tv __ARGS((char_u **arg, typval_T *rettv, int evaluate)); + static int get_list_tv __ARGS((char_u **arg, typval_T *rettv, int evaluate)); + static int rettv_list_alloc __ARGS((typval_T *rettv)); +- static void listitem_free __ARGS((listitem_T *item)); + static long list_len __ARGS((list_T *l)); + static int list_equal __ARGS((list_T *l1, list_T *l2, int ic, int recursive)); + static int dict_equal __ARGS((dict_T *d1, dict_T *d2, int ic, int recursive)); +--- 412,417 ---- +*************** +*** 428,434 **** + static int list_join __ARGS((garray_T *gap, list_T *l, char_u *sep, int echo, int copyID)); + static int free_unref_items __ARGS((int copyID)); + static int rettv_dict_alloc __ARGS((typval_T *rettv)); +- static void dict_free __ARGS((dict_T *d, int recurse)); + static dictitem_T *dictitem_copy __ARGS((dictitem_T *org)); + static void dictitem_remove __ARGS((dict_T *dict, dictitem_T *item)); + static dict_T *dict_copy __ARGS((dict_T *orig, int deep, int copyID)); +--- 427,432 ---- +*************** +*** 5955,5961 **** + /* + * Free a list item. Also clears the value. Does not notify watchers. + */ +! static void + listitem_free(item) + listitem_T *item; + { +--- 5953,5959 ---- + /* + * Free a list item. Also clears the value. Does not notify watchers. + */ +! void + listitem_free(item) + listitem_T *item; + { +*************** +*** 7031,7037 **** + * Free a Dictionary, including all items it contains. + * Ignores the reference count. + */ +! static void + dict_free(d, recurse) + dict_T *d; + int recurse; /* Free Lists and Dictionaries recursively. */ +--- 7029,7035 ---- + * Free a Dictionary, including all items it contains. + * Ignores the reference count. + */ +! void + dict_free(d, recurse) + dict_T *d; + int recurse; /* Free Lists and Dictionaries recursively. */ +*************** +*** 8353,8359 **** + + /* + * Call a function with its resolved parameters +! * Return OK when the function can't be called, FAIL otherwise. + * Also returns OK when an error was encountered while executing the function. + */ + static int +--- 8351,8357 ---- + + /* + * Call a function with its resolved parameters +! * Return FAIL when the function can't be called, OK otherwise. + * Also returns OK when an error was encountered while executing the function. + */ + static int +*** ../vim-7.3.1055/src/if_py_both.h 2013-05-29 22:58:28.000000000 +0200 +--- src/if_py_both.h 2013-05-30 12:13:37.000000000 +0200 +*************** +*** 32,39 **** + + #define DICTKEY_DECL \ + PyObject *dictkey_todecref; + #define DICTKEY_GET(err, decref) \ +! if (!(key = StringToChars(keyObject, &dictkey_todecref))) \ + { \ + if (decref) \ + { \ +--- 32,46 ---- + + #define DICTKEY_DECL \ + PyObject *dictkey_todecref; ++ #define DICTKEY_CHECK_EMPTY(err) \ ++ if (*key == NUL) \ ++ { \ ++ PyErr_SetString(PyExc_ValueError, _("empty keys are not allowed")); \ ++ return err; \ ++ } ++ #define DICTKEY_SET_KEY (key = StringToChars(keyObject, &dictkey_todecref)) + #define DICTKEY_GET(err, decref) \ +! if (!DICTKEY_SET_KEY) \ + { \ + if (decref) \ + { \ +*************** +*** 43,53 **** + } \ + if (decref && !dictkey_todecref) \ + dictkey_todecref = keyObject; \ +! if (*key == NUL) \ +! { \ +! PyErr_SetString(PyExc_ValueError, _("empty keys are not allowed")); \ +! return err; \ +! } + #define DICTKEY_UNREF \ + Py_XDECREF(dictkey_todecref); + +--- 50,56 ---- + } \ + if (decref && !dictkey_todecref) \ + dictkey_todecref = keyObject; \ +! DICTKEY_CHECK_EMPTY(err) + #define DICTKEY_UNREF \ + Py_XDECREF(dictkey_todecref); + +*************** +*** 651,659 **** + + /* Convert the Vim type into a Python type. Create a dictionary that's + * used to check for recursive loops. */ +! lookup_dict = PyDict_New(); +! result = VimToPython(our_tv, 1, lookup_dict); +! Py_DECREF(lookup_dict); + + + Py_BEGIN_ALLOW_THREADS +--- 654,666 ---- + + /* Convert the Vim type into a Python type. Create a dictionary that's + * used to check for recursive loops. */ +! if (!(lookup_dict = PyDict_New())) +! result = NULL; +! else +! { +! result = VimToPython(our_tv, 1, lookup_dict); +! Py_DECREF(lookup_dict); +! } + + + Py_BEGIN_ALLOW_THREADS +*************** +*** 1401,1407 **** + return NULL; + } + +! lookup_dict = PyDict_New(); + if (list_py_concat(l, obj, lookup_dict) == -1) + { + Py_DECREF(lookup_dict); +--- 1408,1416 ---- + return NULL; + } + +! if (!(lookup_dict = PyDict_New())) +! return NULL; +! + if (list_py_concat(l, obj, lookup_dict) == -1) + { + Py_DECREF(lookup_dict); +*************** +*** 4023,4034 **** + PyObject *valObject; + Py_ssize_t iter = 0; + +! dict = dict_alloc(); +! if (dict == NULL) +! { +! PyErr_NoMemory(); + return -1; +- } + + tv->v_type = VAR_DICT; + tv->vval.v_dict = dict; +--- 4032,4039 ---- + PyObject *valObject; + Py_ssize_t iter = 0; + +! if (!(dict = dict_alloc())) + return -1; + + tv->v_type = VAR_DICT; + tv->vval.v_dict = dict; +*************** +*** 4038,4046 **** + DICTKEY_DECL + + if (keyObject == NULL || valObject == NULL) + return -1; + +! DICTKEY_GET(-1, 0) + + di = dictitem_alloc(key); + +--- 4043,4059 ---- + DICTKEY_DECL + + if (keyObject == NULL || valObject == NULL) ++ { ++ dict_unref(dict); + return -1; ++ } + +! if (!DICTKEY_SET_KEY) +! { +! dict_unref(dict); +! return -1; +! } +! DICTKEY_CHECK_EMPTY(-1) + + di = dictitem_alloc(key); + +*************** +*** 4049,4054 **** +--- 4062,4068 ---- + if (di == NULL) + { + PyErr_NoMemory(); ++ dict_unref(dict); + return -1; + } + di->di_tv.v_lock = 0; +*************** +*** 4056,4061 **** +--- 4070,4076 ---- + if (_ConvertFromPyObject(valObject, &di->di_tv, lookup_dict) == -1) + { + vim_free(di); ++ dict_unref(dict); + return -1; + } + +*************** +*** 4063,4072 **** +--- 4078,4090 ---- + { + clear_tv(&di->di_tv); + vim_free(di); ++ dict_unref(dict); + PyErr_SetVim(_("failed to add key to dictionary")); + return -1; + } + } ++ ++ --dict->dv_refcount; + return 0; + } + +*************** +*** 4082,4100 **** + PyObject *valObject; + Py_ssize_t lsize; + +! dict = dict_alloc(); +! if (dict == NULL) +! { +! PyErr_NoMemory(); + return -1; +- } + + tv->v_type = VAR_DICT; + tv->vval.v_dict = dict; + + list = PyMapping_Items(obj); + if (list == NULL) + return -1; + lsize = PyList_Size(list); + while (lsize--) + { +--- 4100,4117 ---- + PyObject *valObject; + Py_ssize_t lsize; + +! if (!(dict = dict_alloc())) + return -1; + + tv->v_type = VAR_DICT; + tv->vval.v_dict = dict; + + list = PyMapping_Items(obj); + if (list == NULL) ++ { ++ dict_unref(dict); + return -1; ++ } + lsize = PyList_Size(list); + while (lsize--) + { +*************** +*** 4104,4109 **** +--- 4121,4127 ---- + if (litem == NULL) + { + Py_DECREF(list); ++ dict_unref(dict); + return -1; + } + +*************** +*** 4111,4125 **** + { + Py_DECREF(list); + Py_DECREF(litem); + return -1; + } + +! DICTKEY_GET(-1, 1) + + if (!(valObject = PyTuple_GetItem(litem, 1))) + { + Py_DECREF(list); + Py_DECREF(litem); + DICTKEY_UNREF + return -1; + } +--- 4129,4153 ---- + { + Py_DECREF(list); + Py_DECREF(litem); ++ dict_unref(dict); + return -1; + } + +! if (!DICTKEY_SET_KEY) +! { +! dict_unref(dict); +! Py_DECREF(list); +! Py_DECREF(litem); +! DICTKEY_UNREF +! return -1; +! } +! DICTKEY_CHECK_EMPTY(-1) + + if (!(valObject = PyTuple_GetItem(litem, 1))) + { + Py_DECREF(list); + Py_DECREF(litem); ++ dict_unref(dict); + DICTKEY_UNREF + return -1; + } +*************** +*** 4133,4139 **** + if (di == NULL) + { + Py_DECREF(list); +! Py_DECREF(valObject); + PyErr_NoMemory(); + return -1; + } +--- 4161,4167 ---- + if (di == NULL) + { + Py_DECREF(list); +! dict_unref(dict); + PyErr_NoMemory(); + return -1; + } +*************** +*** 4142,4216 **** + if (_ConvertFromPyObject(valObject, &di->di_tv, lookup_dict) == -1) + { + vim_free(di); + Py_DECREF(list); +- Py_DECREF(valObject); + return -1; + } + +- Py_DECREF(valObject); +- + if (dict_add(dict, di) == FAIL) + { +! clear_tv(&di->di_tv); +! vim_free(di); + Py_DECREF(list); + PyErr_SetVim(_("failed to add key to dictionary")); + return -1; + } + } + Py_DECREF(list); + return 0; + } + + static int + pyseq_to_tv(PyObject *obj, typval_T *tv, PyObject *lookup_dict) + { + list_T *l; + +! l = list_alloc(); +! if (l == NULL) +! { +! PyErr_NoMemory(); + return -1; +- } + + tv->v_type = VAR_LIST; + tv->vval.v_list = l; + + if (list_py_concat(l, obj, lookup_dict) == -1) + return -1; + + return 0; + } + + static int + pyiter_to_tv(PyObject *obj, typval_T *tv, PyObject *lookup_dict) + { +! PyObject *iterator = PyObject_GetIter(obj); + PyObject *item; + list_T *l; + listitem_T *li; + +! l = list_alloc(); +! +! if (l == NULL) +! { +! PyErr_NoMemory(); + return -1; +- } + + tv->vval.v_list = l; + tv->v_type = VAR_LIST; + +! +! if (iterator == NULL) + return -1; + + while ((item = PyIter_Next(iterator))) + { + li = listitem_alloc(); + if (li == NULL) + { + Py_DECREF(iterator); + PyErr_NoMemory(); + return -1; +--- 4170,4256 ---- + if (_ConvertFromPyObject(valObject, &di->di_tv, lookup_dict) == -1) + { + vim_free(di); ++ dict_unref(dict); + Py_DECREF(list); + return -1; + } + + if (dict_add(dict, di) == FAIL) + { +! dictitem_free(di); +! dict_unref(dict); + Py_DECREF(list); + PyErr_SetVim(_("failed to add key to dictionary")); + return -1; + } + } ++ --dict->dv_refcount; + Py_DECREF(list); + return 0; + } + ++ static list_T * ++ py_list_alloc() ++ { ++ list_T *r; ++ ++ if (!(r = list_alloc())) ++ { ++ PyErr_NoMemory(); ++ return NULL; ++ } ++ ++r->lv_refcount; ++ ++ return r; ++ } ++ + static int + pyseq_to_tv(PyObject *obj, typval_T *tv, PyObject *lookup_dict) + { + list_T *l; + +! if (!(l = py_list_alloc())) + return -1; + + tv->v_type = VAR_LIST; + tv->vval.v_list = l; + + if (list_py_concat(l, obj, lookup_dict) == -1) ++ { ++ list_unref(l); + return -1; ++ } + ++ --l->lv_refcount; + return 0; + } + + static int + pyiter_to_tv(PyObject *obj, typval_T *tv, PyObject *lookup_dict) + { +! PyObject *iterator; + PyObject *item; + list_T *l; + listitem_T *li; + +! if (!(l = py_list_alloc())) + return -1; + + tv->vval.v_list = l; + tv->v_type = VAR_LIST; + +! if (!(iterator = PyObject_GetIter(obj))) +! { +! list_unref(l); + return -1; ++ } + + while ((item = PyIter_Next(iterator))) + { + li = listitem_alloc(); + if (li == NULL) + { ++ list_unref(l); + Py_DECREF(iterator); + PyErr_NoMemory(); + return -1; +*************** +*** 4219,4224 **** +--- 4259,4266 ---- + + if (_ConvertFromPyObject(item, &li->li_tv, lookup_dict) == -1) + { ++ list_unref(l); ++ listitem_free(li); + Py_DECREF(item); + Py_DECREF(iterator); + return -1; +*************** +*** 4230,4235 **** +--- 4272,4286 ---- + } + + Py_DECREF(iterator); ++ ++ /* Iterator may have finished due to an exception */ ++ if (PyErr_Occurred()) ++ { ++ list_unref(l); ++ return -1; ++ } ++ ++ --l->lv_refcount; + return 0; + } + +*************** +*** 4295,4301 **** + PyObject *lookup_dict; + int r; + +! lookup_dict = PyDict_New(); + r = _ConvertFromPyObject(obj, tv, lookup_dict); + Py_DECREF(lookup_dict); + return r; +--- 4346,4353 ---- + PyObject *lookup_dict; + int r; + +! if (!(lookup_dict = PyDict_New())) +! return -1; + r = _ConvertFromPyObject(obj, tv, lookup_dict); + Py_DECREF(lookup_dict); + return r; +*** ../vim-7.3.1055/src/proto/eval.pro 2013-05-17 16:03:53.000000000 +0200 +--- src/proto/eval.pro 2013-05-30 12:11:40.000000000 +0200 +*************** +*** 49,54 **** +--- 49,55 ---- + void list_unref __ARGS((list_T *l)); + void list_free __ARGS((list_T *l, int recurse)); + listitem_T *listitem_alloc __ARGS((void)); ++ void listitem_free __ARGS((listitem_T *item)); + void listitem_remove __ARGS((list_T *l, listitem_T *item)); + dictitem_T *dict_lookup __ARGS((hashitem_T *hi)); + listitem_T *list_find __ARGS((list_T *l, long n)); +*************** +*** 65,70 **** +--- 66,72 ---- + void set_ref_in_item __ARGS((typval_T *tv, int copyID)); + dict_T *dict_alloc __ARGS((void)); + void dict_unref __ARGS((dict_T *d)); ++ void dict_free __ARGS((dict_T *d, int recurse)); + dictitem_T *dictitem_alloc __ARGS((char_u *key)); + void dictitem_free __ARGS((dictitem_T *item)); + int dict_add __ARGS((dict_T *d, dictitem_T *item)); +*** ../vim-7.3.1055/src/version.c 2013-05-30 11:51:04.000000000 +0200 +--- src/version.c 2013-05-30 12:13:57.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1056, + /**/ + +-- +I have a drinking problem -- I can't afford it. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b6734f5bbb5e740af396bb329e6eb4043babc5f0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:26 +0200 Subject: [PATCH 0948/3340] - patchlevel 1057 --- 7.3.1057 | 205 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 205 insertions(+) create mode 100644 7.3.1057 diff --git a/7.3.1057 b/7.3.1057 new file mode 100644 index 00000000..a47b6bcd --- /dev/null +++ b/7.3.1057 @@ -0,0 +1,205 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1057 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1057 +Problem: Python: not enough compatibilty. +Solution: Python patch 16: Make OutputWritelines support any sequence object + (ZyX) Note: tests fail +Files: src/if_py_both.h, src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.1056/src/if_py_both.h 2013-05-30 12:14:44.000000000 +0200 +--- src/if_py_both.h 2013-05-30 12:18:09.000000000 +0200 +*************** +*** 312,347 **** + static PyObject * + OutputWritelines(OutputObject *self, PyObject *args) + { +! PyInt n; +! PyInt i; +! PyObject *list; + int error = self->error; + +! if (!PyArg_ParseTuple(args, "O", &list)) + return NULL; +- Py_INCREF(list); + +! if (!PyList_Check(list)) +! { +! PyErr_SetString(PyExc_TypeError, _("writelines() requires list of strings")); +! Py_DECREF(list); + return NULL; +- } +- +- n = PyList_Size(list); + +! for (i = 0; i < n; ++i) + { +- PyObject *line = PyList_GetItem(list, i); + char *str = NULL; + PyInt len; + +! if (!PyArg_Parse(line, "et#", ENC_OPT, &str, &len)) + { + PyErr_SetString(PyExc_TypeError, _("writelines() requires list of strings")); +! Py_DECREF(list); + return NULL; + } + + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); +--- 312,341 ---- + static PyObject * + OutputWritelines(OutputObject *self, PyObject *args) + { +! PyObject *seq; +! PyObject *iterator; +! PyObject *item; + int error = self->error; + +! if (!PyArg_ParseTuple(args, "O", &seq)) + return NULL; + +! if (!(iterator = PyObject_GetIter(seq))) + return NULL; + +! while ((item = PyIter_Next(iterator))) + { + char *str = NULL; + PyInt len; + +! if (!PyArg_Parse(item, "et#", ENC_OPT, &str, &len)) + { + PyErr_SetString(PyExc_TypeError, _("writelines() requires list of strings")); +! Py_DECREF(iterator); +! Py_DECREF(item); + return NULL; + } ++ Py_DECREF(item); + + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); +*************** +*** 351,357 **** + PyMem_Free(str); + } + +! Py_DECREF(list); + Py_INCREF(Py_None); + return Py_None; + } +--- 345,356 ---- + PyMem_Free(str); + } + +! Py_DECREF(iterator); +! +! /* Iterator may have finished due to an exception */ +! if (PyErr_Occurred()) +! return NULL; +! + Py_INCREF(Py_None); + return Py_None; + } +*** ../vim-7.3.1056/src/testdir/test86.in 2013-05-29 22:36:06.000000000 +0200 +--- src/testdir/test86.in 2013-05-30 12:18:09.000000000 +0200 +*************** +*** 709,714 **** +--- 709,724 ---- + del o + EOF + :" ++ :" ++ :" Test stdout/stderr ++ :redir => messages ++ :py sys.stdout.write('abc') ; sys.stdout.write('def') ++ :py sys.stderr.write('abc') ; sys.stderr.write('def') ++ :py sys.stdout.writelines(iter('abc')) ++ :py sys.stderr.writelines(iter('abc')) ++ :redir END ++ :$put =string(substitute(messages, '\d\+', '', 'g')) ++ :" + :" Test exceptions + :fun Exe(e) + : execute a:e +*** ../vim-7.3.1056/src/testdir/test86.ok 2013-05-30 11:43:11.000000000 +0200 +--- src/testdir/test86.ok 2013-05-30 12:18:09.000000000 +0200 +*************** +*** 391,396 **** +--- 391,403 ---- + list:__dir__,__members__,extend,locked + function:__call__,__dir__,__members__,softspace + output:__dir__,__members__,flush,softspace,write,writelines ++ ' ++ abcdef ++ line : ++ abcdef ++ abc ++ line : ++ abc' + (, error('abc',)) + (, error('def',)) + (, error('ghi',)) +*** ../vim-7.3.1056/src/testdir/test87.in 2013-05-29 22:36:06.000000000 +0200 +--- src/testdir/test87.in 2013-05-30 12:18:09.000000000 +0200 +*************** +*** 687,692 **** +--- 687,702 ---- + del o + EOF + :" ++ :" ++ :" Test stdout/stderr ++ :redir => messages ++ :py sys.stdout.write('abc') ; sys.stdout.write('def') ++ :py sys.stderr.write('abc') ; sys.stderr.write('def') ++ :py sys.stdout.writelines(iter('abc')) ++ :py sys.stderr.writelines(iter('abc')) ++ :redir END ++ :$put =string(substitute(messages, '\d\+', '', 'g')) ++ :" + :" Test exceptions + :fun Exe(e) + : execute a:e +*** ../vim-7.3.1056/src/testdir/test87.ok 2013-05-30 11:43:11.000000000 +0200 +--- src/testdir/test87.ok 2013-05-30 12:18:09.000000000 +0200 +*************** +*** 380,385 **** +--- 380,392 ---- + list:__dir__,extend,locked + function:__call__,__dir__,softspace + output:__dir__,flush,softspace,write,writelines ++ ' ++ abcdef ++ line : ++ abcdef ++ abc ++ line : ++ abc' + (, error('abc',)) + (, error('def',)) + (, error('ghi',)) +*** ../vim-7.3.1056/src/version.c 2013-05-30 12:14:44.000000000 +0200 +--- src/version.c 2013-05-30 12:20:02.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1057, + /**/ + +-- +I have a drinking problem -- I don't have a drink! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From dc0934582f6c499d1065b01e93de3fa4ca600c20 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:27 +0200 Subject: [PATCH 0949/3340] - patchlevel 1058 --- 7.3.1058 | 163 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 163 insertions(+) create mode 100644 7.3.1058 diff --git a/7.3.1058 b/7.3.1058 new file mode 100644 index 00000000..cacdac76 --- /dev/null +++ b/7.3.1058 @@ -0,0 +1,163 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1058 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1058 +Problem: Call of funcref does not succeed in other script. +Solution: Python patch 17: add get_expanded_name(). (ZyX) +Files: src/eval.c, src/proto/eval.pro + + +*** ../vim-7.3.1057/src/eval.c 2013-05-30 12:14:44.000000000 +0200 +--- src/eval.c 2013-05-30 12:31:55.000000000 +0200 +*************** +*** 810,816 **** + # endif + prof_self_cmp __ARGS((const void *s1, const void *s2)); + #endif +- static int script_autoload __ARGS((char_u *name, int reload)); + static char_u *autoload_name __ARGS((char_u *name)); + static void cat_func_name __ARGS((char_u *buf, ufunc_T *fp)); + static void func_free __ARGS((ufunc_T *fp)); +--- 810,815 ---- +*************** +*** 10946,10961 **** + typval_T *rettv; + { + char_u *s; + + s = get_tv_string(&argvars[0]); + if (s == NULL || *s == NUL || VIM_ISDIGIT(*s)) + EMSG2(_(e_invarg2), s); +! /* Don't check an autoload name for existence here. */ +! else if (vim_strchr(s, AUTOLOAD_CHAR) == NULL && !function_exists(s)) + EMSG2(_("E700: Unknown function: %s"), s); + else + { +! rettv->vval.v_string = vim_strsave(s); + rettv->v_type = VAR_FUNC; + } + } +--- 10945,10969 ---- + typval_T *rettv; + { + char_u *s; ++ char_u *name = NULL; + + s = get_tv_string(&argvars[0]); + if (s == NULL || *s == NUL || VIM_ISDIGIT(*s)) + EMSG2(_(e_invarg2), s); +! /* Don't check an autoload name for existence here, but still expand it +! * checking for validity */ +! else if ((name = get_expanded_name(s, vim_strchr(s, AUTOLOAD_CHAR) == NULL)) +! == NULL) + EMSG2(_("E700: Unknown function: %s"), s); + else + { +! if (name == NULL) +! /* Autoload function, need to copy string */ +! rettv->vval.v_string = vim_strsave(s); +! else +! /* Function found by get_expanded_name, string allocated by +! * trans_function_name: no need to copy */ +! rettv->vval.v_string = name; + rettv->v_type = VAR_FUNC; + } + } +*************** +*** 21938,21943 **** +--- 21946,21978 ---- + return n; + } + ++ char_u * ++ get_expanded_name(name, check) ++ char_u *name; ++ int check; ++ { ++ char_u *nm = name; ++ char_u *p; ++ ++ p = trans_function_name(&nm, FALSE, TFN_INT|TFN_QUIET, NULL); ++ ++ if (p != NULL && *nm == NUL) ++ { ++ if (!check) ++ return p; ++ else if (builtin_function(p)) ++ { ++ if (find_internal_func(p) >= 0) ++ return p; ++ } ++ else ++ if (find_func(p) != NULL) ++ return p; ++ } ++ vim_free(p); ++ return NULL; ++ } ++ + /* + * Return TRUE if "name" looks like a builtin function name: starts with a + * lower case letter and doesn't contain a ':' or AUTOLOAD_CHAR. +*************** +*** 22146,22152 **** + * If "name" has a package name try autoloading the script for it. + * Return TRUE if a package was loaded. + */ +! static int + script_autoload(name, reload) + char_u *name; + int reload; /* load script again when already loaded */ +--- 22181,22187 ---- + * If "name" has a package name try autoloading the script for it. + * Return TRUE if a package was loaded. + */ +! int + script_autoload(name, reload) + char_u *name; + int reload; /* load script again when already loaded */ +*** ../vim-7.3.1057/src/proto/eval.pro 2013-05-30 12:14:44.000000000 +0200 +--- src/proto/eval.pro 2013-05-30 12:31:55.000000000 +0200 +*************** +*** 77,82 **** +--- 77,83 ---- + long get_dict_number __ARGS((dict_T *d, char_u *key)); + char_u *get_function_name __ARGS((expand_T *xp, int idx)); + char_u *get_expr_name __ARGS((expand_T *xp, int idx)); ++ char_u *get_expanded_name __ARGS((char_u *name, int check)); + int func_call __ARGS((char_u *name, typval_T *args, dict_T *selfdict, typval_T *rettv)); + void mzscheme_call_vim __ARGS((char_u *name, typval_T *args, typval_T *rettv)); + long do_searchpair __ARGS((char_u *spat, char_u *mpat, char_u *epat, int dir, char_u *skip, int flags, pos_T *match_pos, linenr_T lnum_stop, long time_limit)); +*************** +*** 129,132 **** +--- 130,134 ---- + void ex_oldfiles __ARGS((exarg_T *eap)); + int modify_fname __ARGS((char_u *src, int *usedlen, char_u **fnamep, char_u **bufp, int *fnamelen)); + char_u *do_string_sub __ARGS((char_u *str, char_u *pat, char_u *sub, char_u *flags)); ++ int script_autoload __ARGS((char_u *name, int reload)); + /* vim: set ft=c : */ +*** ../vim-7.3.1057/src/version.c 2013-05-30 12:26:52.000000000 +0200 +--- src/version.c 2013-05-30 12:29:55.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1058, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +1. At lunch time, sit in your parked car with sunglasses on and point + a hair dryer at passing cars. See if they slow down. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9bc07e1fd02fce15e3b4e248eaaf4b533c5e72bc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:27 +0200 Subject: [PATCH 0950/3340] - patchlevel 1059 --- 7.3.1059 | 321 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 321 insertions(+) create mode 100644 7.3.1059 diff --git a/7.3.1059 b/7.3.1059 new file mode 100644 index 00000000..61b158e3 --- /dev/null +++ b/7.3.1059 @@ -0,0 +1,321 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1059 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1059 +Problem: Python: Using fixed size buffers. +Solution: Python patch 18: Use python's own formatter. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c + + +*** ../vim-7.3.1058/src/if_py_both.h 2013-05-30 12:26:52.000000000 +0200 +--- src/if_py_both.h 2013-05-30 12:38:22.000000000 +0200 +*************** +*** 2006,2029 **** + static PyObject * + TabPageRepr(TabPageObject *self) + { +- static char repr[100]; +- + if (self->tab == INVALID_TABPAGE_VALUE) +! { +! vim_snprintf(repr, 100, _(""), (self)); +! return PyString_FromString(repr); +! } + else + { + int t = get_tab_number(self->tab); + + if (t == 0) +! vim_snprintf(repr, 100, _(""), +! (self)); + else +! vim_snprintf(repr, 100, _(""), t - 1); +! +! return PyString_FromString(repr); + } + } + +--- 2006,2022 ---- + static PyObject * + TabPageRepr(TabPageObject *self) + { + if (self->tab == INVALID_TABPAGE_VALUE) +! return PyString_FromFormat("", (self)); + else + { + int t = get_tab_number(self->tab); + + if (t == 0) +! return PyString_FromFormat("", +! (self)); + else +! return PyString_FromFormat("", t - 1); + } + } + +*************** +*** 2344,2367 **** + static PyObject * + WindowRepr(WindowObject *self) + { +- static char repr[100]; +- + if (self->win == INVALID_WINDOW_VALUE) +! { +! vim_snprintf(repr, 100, _(""), (self)); +! return PyString_FromString(repr); +! } + else + { + int w = get_win_number(self->win, firstwin); + + if (w == 0) +! vim_snprintf(repr, 100, _(""), + (self)); + else +! vim_snprintf(repr, 100, _(""), w - 1); +! +! return PyString_FromString(repr); + } + } + +--- 2337,2353 ---- + static PyObject * + WindowRepr(WindowObject *self) + { + if (self->win == INVALID_WINDOW_VALUE) +! return PyString_FromFormat("", (self)); + else + { + int w = get_win_number(self->win, firstwin); + + if (w == 0) +! return PyString_FromFormat("", + (self)); + else +! return PyString_FromFormat("", w - 1); + } + } + +*************** +*** 3281,3311 **** + static PyObject * + RangeRepr(RangeObject *self) + { +- static char repr[100]; +- + if (self->buf->buf == INVALID_BUFFER_VALUE) +! { +! vim_snprintf(repr, 100, "", +! (self)); +! return PyString_FromString(repr); +! } + else + { + char *name = (char *)self->buf->buf->b_fname; +- int len; + + if (name == NULL) + name = ""; +- len = (int)strlen(name); +- +- if (len > 45) +- name = name + (45 - len); +- +- vim_snprintf(repr, 100, "", +- len > 45 ? "..." : "", name, +- self->start, self->end); + +! return PyString_FromString(repr); + } + } + +--- 3267,3284 ---- + static PyObject * + RangeRepr(RangeObject *self) + { + if (self->buf->buf == INVALID_BUFFER_VALUE) +! return PyString_FromFormat("", +! (self)); + else + { + char *name = (char *)self->buf->buf->b_fname; + + if (name == NULL) + name = ""; + +! return PyString_FromFormat("", +! name, self->start, self->end); + } + } + +*************** +*** 3534,3561 **** + static PyObject * + BufferRepr(BufferObject *self) + { +- static char repr[100]; +- + if (self->buf == INVALID_BUFFER_VALUE) +! { +! vim_snprintf(repr, 100, _(""), (self)); +! return PyString_FromString(repr); +! } + else + { +! char *name = (char *)self->buf->b_fname; +! PyInt len; + + if (name == NULL) + name = ""; +- len = strlen(name); +- +- if (len > 35) +- name = name + (35 - len); +- +- vim_snprintf(repr, 100, "", len > 35 ? "..." : "", name); + +! return PyString_FromString(repr); + } + } + +--- 3507,3522 ---- + static PyObject * + BufferRepr(BufferObject *self) + { + if (self->buf == INVALID_BUFFER_VALUE) +! return PyString_FromFormat("", self); + else + { +! char *name = (char *)self->buf->b_fname; + + if (name == NULL) + name = ""; + +! return PyString_FromFormat("", name); + } + } + +*** ../vim-7.3.1058/src/if_python3.c 2013-05-29 22:36:06.000000000 +0200 +--- src/if_python3.c 2013-05-30 12:39:25.000000000 +0200 +*************** +*** 90,95 **** +--- 90,96 ---- + #define PyString_AsString(obj) PyBytes_AsString(obj) + #define PyString_Size(obj) PyBytes_GET_SIZE(bytes) + #define PyString_FromString(repr) PyUnicode_FromString(repr) ++ #define PyString_FromFormat PyUnicode_FromFormat + #define PyString_AsStringAndSize(obj, buffer, len) PyBytes_AsStringAndSize(obj, buffer, len) + #define PyInt_Check(obj) PyLong_Check(obj) + #define PyInt_FromLong(i) PyLong_FromLong(i) +*************** +*** 230,235 **** +--- 231,246 ---- + # define PyType_GenericNew py3_PyType_GenericNew + # undef PyUnicode_FromString + # define PyUnicode_FromString py3_PyUnicode_FromString ++ # ifndef PyUnicode_FromFormat ++ # define PyUnicode_FromFormat py3_PyUnicode_FromFormat ++ # else ++ # define Py_UNICODE_USE_UCS_FUNCTIONS ++ # ifdef Py_UNICODE_WIDE ++ # define PyUnicodeUCS4_FromFormat py3_PyUnicodeUCS4_FromFormat ++ # else ++ # define PyUnicodeUCS2_FromFormat py3_PyUnicodeUCS2_FromFormat ++ # endif ++ # endif + # undef PyUnicode_Decode + # define PyUnicode_Decode py3_PyUnicode_Decode + # define PyType_IsSubtype py3_PyType_IsSubtype +*************** +*** 293,298 **** +--- 304,318 ---- + static int (*py3_PyType_Ready)(PyTypeObject *type); + static int (*py3_PyDict_SetItemString)(PyObject *dp, char *key, PyObject *item); + static PyObject* (*py3_PyUnicode_FromString)(const char *u); ++ # ifndef Py_UNICODE_USE_UCS_FUNCTIONS ++ static PyObject* (*py3_PyUnicode_FromFormat)(const char *u, ...); ++ # else ++ # ifdef Py_UNICODE_WIDE ++ static PyObject* (*py3_PyUnicodeUCS4_FromFormat)(const char *u, ...); ++ # else ++ static PyObject* (*py3_PyUnicodeUCS2_FromFormat)(const char *u, ...); ++ # endif ++ # endif + static PyObject* (*py3_PyUnicode_Decode)(const char *u, Py_ssize_t size, + const char *encoding, const char *errors); + static long (*py3_PyLong_AsLong)(PyObject *); +*************** +*** 458,463 **** +--- 478,492 ---- + # else + {"_PyUnicode_AsString", (PYTHON_PROC*)&py3__PyUnicode_AsString}, + # endif ++ # ifndef Py_UNICODE_USE_UCS_FUNCTIONS ++ {"PyUnicode_FromFormat", (PYTHON_PROC*)&py3_PyUnicode_FromFormat}, ++ # else ++ # ifdef Py_UNICODE_WIDE ++ {"PyUnicodeUCS4_FromFormat", (PYTHON_PROC*)&py3_PyUnicodeUCS4_FromFormat}, ++ # else ++ {"PyUnicodeUCS2_FromFormat", (PYTHON_PROC*)&py3_PyUnicodeUCS2_FromFormat}, ++ # endif ++ # endif + {"PyBytes_AsString", (PYTHON_PROC*)&py3_PyBytes_AsString}, + {"PyBytes_AsStringAndSize", (PYTHON_PROC*)&py3_PyBytes_AsStringAndSize}, + {"PyBytes_FromString", (PYTHON_PROC*)&py3_PyBytes_FromString}, +*** ../vim-7.3.1058/src/if_python.c 2013-05-29 22:36:06.000000000 +0200 +--- src/if_python.c 2013-05-30 12:38:22.000000000 +0200 +*************** +*** 212,217 **** +--- 212,218 ---- + # define PyString_AsString dll_PyString_AsString + # define PyString_AsStringAndSize dll_PyString_AsStringAndSize + # define PyString_FromString dll_PyString_FromString ++ # define PyString_FromFormat dll_PyString_FromFormat + # define PyString_FromStringAndSize dll_PyString_FromStringAndSize + # define PyString_Size dll_PyString_Size + # define PyString_Type (*dll_PyString_Type) +*************** +*** 340,345 **** +--- 341,347 ---- + static char*(*dll_PyString_AsString)(PyObject *); + static int(*dll_PyString_AsStringAndSize)(PyObject *, char **, int *); + static PyObject*(*dll_PyString_FromString)(const char *); ++ static PyObject*(*dll_PyString_FromFormat)(const char *, ...); + static PyObject*(*dll_PyString_FromStringAndSize)(const char *, PyInt); + static PyInt(*dll_PyString_Size)(PyObject *); + static PyTypeObject* dll_PyString_Type; +*************** +*** 499,504 **** +--- 501,507 ---- + {"PyString_AsString", (PYTHON_PROC*)&dll_PyString_AsString}, + {"PyString_AsStringAndSize", (PYTHON_PROC*)&dll_PyString_AsStringAndSize}, + {"PyString_FromString", (PYTHON_PROC*)&dll_PyString_FromString}, ++ {"PyString_FromFormat", (PYTHON_PROC*)&dll_PyString_FromFormat}, + {"PyString_FromStringAndSize", (PYTHON_PROC*)&dll_PyString_FromStringAndSize}, + {"PyString_Size", (PYTHON_PROC*)&dll_PyString_Size}, + {"PyString_Type", (PYTHON_PROC*)&dll_PyString_Type}, +*** ../vim-7.3.1058/src/version.c 2013-05-30 12:35:48.000000000 +0200 +--- src/version.c 2013-05-30 12:39:51.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1059, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +2. Page yourself over the intercom. Don't disguise your voice. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f490c94abcaa27fe10ed3e8f9c299f068935d378 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:28 +0200 Subject: [PATCH 0951/3340] - patchlevel 1060 --- 7.3.1060 | 61 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 7.3.1060 diff --git a/7.3.1060 b/7.3.1060 new file mode 100644 index 00000000..085aed55 --- /dev/null +++ b/7.3.1060 @@ -0,0 +1,61 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1060 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1060 +Problem: Python: can't repr() a function. +Solution: Python patch 19: add FunctionRepr(). (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1059/src/if_py_both.h 2013-05-30 12:40:36.000000000 +0200 +--- src/if_py_both.h 2013-05-30 12:43:16.000000000 +0200 +*************** +*** 1584,1589 **** +--- 1584,1595 ---- + return result; + } + ++ static PyObject * ++ FunctionRepr(FunctionObject *self) ++ { ++ return PyString_FromFormat("", self->name); ++ } ++ + static struct PyMethodDef FunctionMethods[] = { + {"__call__",(PyCFunction)FunctionCall, METH_VARARGS|METH_KEYWORDS, ""}, + {"__dir__", (PyCFunction)FunctionDir, METH_NOARGS, ""}, +*************** +*** 4640,4645 **** +--- 4646,4652 ---- + FunctionType.tp_flags = Py_TPFLAGS_DEFAULT; + FunctionType.tp_doc = "object that calls vim function"; + FunctionType.tp_methods = FunctionMethods; ++ FunctionType.tp_repr = (reprfunc)FunctionRepr; + #if PY_MAJOR_VERSION >= 3 + FunctionType.tp_getattro = (getattrofunc)FunctionGetattro; + #else +*** ../vim-7.3.1059/src/version.c 2013-05-30 12:40:36.000000000 +0200 +--- src/version.c 2013-05-30 12:43:06.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1060, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +3. Every time someone asks you to do something, ask if they want fries + with that. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0fad6e23cc8f3b29a80c284d4710fb0c4becf554 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:29 +0200 Subject: [PATCH 0952/3340] - patchlevel 1061 --- 7.3.1061 | 1964 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1964 insertions(+) create mode 100644 7.3.1061 diff --git a/7.3.1061 b/7.3.1061 new file mode 100644 index 00000000..a263d658 --- /dev/null +++ b/7.3.1061 @@ -0,0 +1,1964 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1061 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1061 +Problem: Python: Dictionary is not standard. +Solution: Python patch 20: Add standard methods and fields. (ZyX) +Files: runtime/doc/if_pyth.txt, src/eval.c, src/if_py_both.h, + src/if_python3.c, src/if_python.c, src/proto/eval.pro, + src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.1060/runtime/doc/if_pyth.txt 2013-05-29 22:02:18.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-05-30 12:47:48.000000000 +0200 +*************** +*** 12,20 **** + 4. Range objects |python-range| + 5. Window objects |python-window| + 6. Tab page objects |python-tabpage| +! 7. pyeval(), py3eval() Vim functions |python-pyeval| +! 8. Dynamic loading |python-dynamic| +! 9. Python 3 |python3| + + {Vi does not have any of these commands} + +--- 12,21 ---- + 4. Range objects |python-range| + 5. Window objects |python-window| + 6. Tab page objects |python-tabpage| +! 7. vim.bindeval objects |python-bindeval-objects| +! 8. pyeval(), py3eval() Vim functions |python-pyeval| +! 9. Dynamic loading |python-dynamic| +! 10. Python 3 |python3| + + {Vi does not have any of these commands} + +*************** +*** 171,217 **** + 'eval_expr', 'kind': 'f', 'filename': './src/eval.c'}] + + vim.bindeval(str) *python-bindeval* +! Like |python-eval|, but +! 1. if expression evaluates to |List| or |Dictionary| it is returned as +! vimlist or vimdictionary python type that are connected to original +! list or dictionary. Thus modifications to these objects imply +! modifications of the original. +! +! Additionally, vim.List and vim.Dictionary type have read-write +! `.locked` attribute that returns +! Value Meaning ~ +! zero Variable is not locked +! vim.VAR_LOCKED Variable is locked, but can be unlocked +! vim.VAR_FIXED Variable is locked and can't be unlocked +! integer constants. If variable is not fixed, you can do +! `var.locked=True` to lock it and `var.locked=False` to unlock. +! There is no recursive locking like |:lockvar|! does. There is also +! no way to lock a specific key or check whether it is locked (in any +! case these locks are ignored by anything except |:let|: |extend()| +! does not care, neither does python interface). +! +! vim.Dictionary type also supports `.scope` attribute which is one +! of +! Value Meaning ~ +! zero Dictionary is not a scope one +! vim.VAR_DEF_SCOPE Function-local or global scope dictionary +! vim.VAR_SCOPE Other scope dictionary +! +! 2. if expression evaluates to a function reference, then it returns +! callable vim.Function object. Use self keyword argument to assign +! |self| object for dictionary functions. +! +! Note: this function has the same behavior as |lua-eval| (except that +! lua does not support running vim functions), |python-eval| is +! kept for backwards compatibility in order not to make scripts +! relying on outputs of vim.eval() being a copy of original or +! vim.eval("1") returning a string. +! +! You can use "List", "Dictionary" and "Function" vim module attributes +! to test whether object has given type. These types are currently not +! subclassable, neither they contain constructors, so you can use them +! only for checks like `isinstance(obj, vim.List)`. +! + + Error object of the "vim" module + +--- 172,180 ---- + 'eval_expr', 'kind': 'f', 'filename': './src/eval.c'}] + + vim.bindeval(str) *python-bindeval* +! Like |python-eval|, but returns special objects described in +! |python-bindeval-objects|. These python objects let you modify (|List| +! or |Dictionary|) or call (|Funcref|) vim objecs. + + Error object of the "vim" module + +*************** +*** 497,509 **** + TabPage object type is available using "TabPage" attribute of vim module. + + ============================================================================== +! 7. pyeval() and py3eval() Vim functions *python-pyeval* + + To facilitate bi-directional interface, you can use |pyeval()| and |py3eval()| + functions to evaluate Python expressions and pass their values to VimL. + + ============================================================================== +! 8. Dynamic loading *python-dynamic* + + On MS-Windows the Python library can be loaded dynamically. The |:version| + output then includes |+python/dyn|. +--- 460,549 ---- + TabPage object type is available using "TabPage" attribute of vim module. + + ============================================================================== +! 7. vim.bindeval objects *python-bindeval-objects* +! +! vim.Dictionary object *python-Dictionary* +! Dictionary-like object providing access to vim |Dictionary| type. +! Attributes: +! Attribute Description ~ +! locked One of *python-.locked* +! Value Description ~ +! zero Variable is not locked +! vim.VAR_LOCKED Variable is locked, but can be unlocked +! vim.VAR_FIXED Variable is locked and can't be unlocked +! Read-write. You can unlock locked variable by assigning +! `True` or `False` to this attribute. No recursive locking +! is supported. +! scope One of +! Value Description ~ +! zero Dictionary is not a scope one +! vim.VAR_DEF_SCOPE |g:| or |l:| dictionary +! vim.VAR_SCOPE Other scope dictionary, +! see |internal-variables| +! Methods: +! Method Description ~ +! keys() Returns a list with dictionary keys. +! values() Returns a list with dictionary values. +! items() Returns a list of 2-tuples with dictionary contents. +! update(iterable) +! update(dictionary) +! update(**kwargs) +! Adds keys to dictionary. +! Examples: > +! py d = vim.bindeval('{}') +! d['a'] = 'b' # Item assignment +! print d['a'] # getting item +! d.update({'c': 'd'}) # .update(dictionary) +! d.update(e='f') # .update(**kwargs) +! d.update((('g', 'h'), ('i', 'j'))) # .update(iterable) +! for key in d.keys(): # .keys() +! for val in d.values(): # .values() +! for key, val in d.items(): # .items() +! print isinstance(d, vim.Dictionary) # True +! for key in d: # Iteration over keys +! < +! Note: when iterating over keys you should not modify dictionary. +! +! vim.List object *python-List* +! Sequence-like object providing access to vim |List| type. +! Supports `.locked` attribute, see |python-.locked|. Also supports the +! following methods: +! Method Description ~ +! extend(item) Add items to the list. +! Examples: > +! l = vim.bindeval('[]') +! l.extend(['abc', 'def']) # .extend() method +! print l[1:] # slicing +! l[:0] = ['ghi', 'jkl'] # slice assignment +! print l[0] # getting item +! l[0] = 'mno' # assignment +! for i in l: # iteration +! print isinstance(l, vim.List) # True +! +! vim.Function object *python-Function* +! Function-like object, acting like vim |Funcref| object. Supports `.name` +! attribute and is callable. Accepts special keyword argument `self`, see +! |Dictionary-function|. +! Examples: > +! f = vim.bindeval('function("tr")') +! print f('abc', 'a', 'b') # Calls tr('abc', 'a', 'b') +! vim.command(''' +! function DictFun() dict +! return self +! endfunction +! ''') +! f = vim.bindeval('function("DictFun")') +! print f(self={}) # Like call('DictFun', [], {}) +! print isinstance(f, vim.Function) # True +! +! ============================================================================== +! 8. pyeval() and py3eval() Vim functions *python-pyeval* + + To facilitate bi-directional interface, you can use |pyeval()| and |py3eval()| + functions to evaluate Python expressions and pass their values to VimL. + + ============================================================================== +! 9. Dynamic loading *python-dynamic* + + On MS-Windows the Python library can be loaded dynamically. The |:version| + output then includes |+python/dyn|. +*************** +*** 520,526 **** + sure edit "gvim.exe" and search for "python\d*.dll\c". + + ============================================================================== +! 9. Python 3 *python3* + + *:py3* *:python3* + The `:py3` and `:python3` commands work similar to `:python`. A simple check +--- 560,566 ---- + sure edit "gvim.exe" and search for "python\d*.dll\c". + + ============================================================================== +! 10. Python 3 *python3* + + *:py3* *:python3* + The `:py3` and `:python3` commands work similar to `:python`. A simple check +*** ../vim-7.3.1060/src/eval.c 2013-05-30 12:35:48.000000000 +0200 +--- src/eval.c 2013-05-30 12:52:11.000000000 +0200 +*************** +*** 10157,10162 **** +--- 10157,10218 ---- + } + + /* ++ * Go over all entries in "d2" and add them to "d1". ++ * When "action" is "error" then a duplicate key is an error. ++ * When "action" is "force" then a duplicate key is overwritten. ++ * Otherwise duplicate keys are ignored ("action" is "keep"). ++ */ ++ void ++ dict_extend(d1, d2, action) ++ dict_T *d1; ++ dict_T *d2; ++ char_u *action; ++ { ++ dictitem_T *di1; ++ hashitem_T *hi2; ++ int todo; ++ ++ todo = (int)d2->dv_hashtab.ht_used; ++ for (hi2 = d2->dv_hashtab.ht_array; todo > 0; ++hi2) ++ { ++ if (!HASHITEM_EMPTY(hi2)) ++ { ++ --todo; ++ di1 = dict_find(d1, hi2->hi_key, -1); ++ if (d1->dv_scope != 0) ++ { ++ /* Disallow replacing a builtin function in l: and g:. ++ * Check the key to be valid when adding to any ++ * scope. */ ++ if (d1->dv_scope == VAR_DEF_SCOPE ++ && HI2DI(hi2)->di_tv.v_type == VAR_FUNC ++ && var_check_func_name(hi2->hi_key, ++ di1 == NULL)) ++ break; ++ if (!valid_varname(hi2->hi_key)) ++ break; ++ } ++ if (di1 == NULL) ++ { ++ di1 = dictitem_copy(HI2DI(hi2)); ++ if (di1 != NULL && dict_add(d1, di1) == FAIL) ++ dictitem_free(di1); ++ } ++ else if (*action == 'e') ++ { ++ EMSG2(_("E737: Key already exists: %s"), hi2->hi_key); ++ break; ++ } ++ else if (*action == 'f' && HI2DI(hi2) != di1) ++ { ++ clear_tv(&di1->di_tv); ++ copy_tv(&HI2DI(hi2)->di_tv, &di1->di_tv); ++ } ++ } ++ } ++ } ++ ++ /* + * "extend(list, list [, idx])" function + * "extend(dict, dict [, action])" function + */ +*************** +*** 10206,10217 **** + } + else if (argvars[0].v_type == VAR_DICT && argvars[1].v_type == VAR_DICT) + { +! dict_T *d1, *d2; +! dictitem_T *di1; +! char_u *action; +! int i; +! hashitem_T *hi2; +! int todo; + + d1 = argvars[0].vval.v_dict; + d2 = argvars[1].vval.v_dict; +--- 10262,10270 ---- + } + else if (argvars[0].v_type == VAR_DICT && argvars[1].v_type == VAR_DICT) + { +! dict_T *d1, *d2; +! char_u *action; +! int i; + + d1 = argvars[0].vval.v_dict; + d2 = argvars[1].vval.v_dict; +*************** +*** 10238,10283 **** + else + action = (char_u *)"force"; + +! /* Go over all entries in the second dict and add them to the +! * first dict. */ +! todo = (int)d2->dv_hashtab.ht_used; +! for (hi2 = d2->dv_hashtab.ht_array; todo > 0; ++hi2) +! { +! if (!HASHITEM_EMPTY(hi2)) +! { +! --todo; +! di1 = dict_find(d1, hi2->hi_key, -1); +! if (d1->dv_scope != 0) +! { +! /* Disallow replacing a builtin function in l: and g:. +! * Check the key to be valid when adding to any +! * scope. */ +! if (d1->dv_scope == VAR_DEF_SCOPE +! && HI2DI(hi2)->di_tv.v_type == VAR_FUNC +! && var_check_func_name(hi2->hi_key, +! di1 == NULL)) +! break; +! if (!valid_varname(hi2->hi_key)) +! break; +! } +! if (di1 == NULL) +! { +! di1 = dictitem_copy(HI2DI(hi2)); +! if (di1 != NULL && dict_add(d1, di1) == FAIL) +! dictitem_free(di1); +! } +! else if (*action == 'e') +! { +! EMSG2(_("E737: Key already exists: %s"), hi2->hi_key); +! break; +! } +! else if (*action == 'f' && HI2DI(hi2) != di1) +! { +! clear_tv(&di1->di_tv); +! copy_tv(&HI2DI(hi2)->di_tv, &di1->di_tv); +! } +! } +! } + + copy_tv(&argvars[0], rettv); + } +--- 10291,10297 ---- + else + action = (char_u *)"force"; + +! dict_extend(d1, d2, action); + + copy_tv(&argvars[0], rettv); + } +*** ../vim-7.3.1060/src/if_py_both.h 2013-05-30 12:43:50.000000000 +0200 +--- src/if_py_both.h 2013-05-30 12:52:42.000000000 +0200 +*************** +*** 31,37 **** + #define INVALID_TABPAGE_VALUE ((tabpage_T *)(-1)) + + #define DICTKEY_DECL \ +! PyObject *dictkey_todecref; + #define DICTKEY_CHECK_EMPTY(err) \ + if (*key == NUL) \ + { \ +--- 31,37 ---- + #define INVALID_TABPAGE_VALUE ((tabpage_T *)(-1)) + + #define DICTKEY_DECL \ +! PyObject *dictkey_todecref = NULL; + #define DICTKEY_CHECK_EMPTY(err) \ + if (*key == NUL) \ + { \ +*************** +*** 63,68 **** +--- 63,69 ---- + + static int ConvertFromPyObject(PyObject *, typval_T *); + static int _ConvertFromPyObject(PyObject *, typval_T *, PyObject *); ++ static int ConvertFromPyMapping(PyObject *, typval_T *); + static PyObject *WindowNew(win_T *, tabpage_T *); + static PyObject *BufferNew (buf_T *); + static PyObject *LineToString(const char *); +*************** +*** 877,888 **** + pylinkedlist_T ref; + } DictionaryObject; + + static PyObject * +! DictionaryNew(dict_T *dict) + { + DictionaryObject *self; + +! self = PyObject_NEW(DictionaryObject, &DictionaryType); + if (self == NULL) + return NULL; + self->dict = dict; +--- 878,893 ---- + pylinkedlist_T ref; + } DictionaryObject; + ++ static PyObject *DictionaryUpdate(DictionaryObject *, PyObject *, PyObject *); ++ ++ #define NEW_DICTIONARY(dict) DictionaryNew(&DictionaryType, dict) ++ + static PyObject * +! DictionaryNew(PyTypeObject *subtype, dict_T *dict) + { + DictionaryObject *self; + +! self = (DictionaryObject *) subtype->tp_alloc(subtype, 0); + if (self == NULL) + return NULL; + self->dict = dict; +*************** +*** 893,898 **** +--- 898,946 ---- + return (PyObject *)(self); + } + ++ static dict_T * ++ py_dict_alloc() ++ { ++ dict_T *r; ++ ++ if (!(r = dict_alloc())) ++ { ++ PyErr_NoMemory(); ++ return NULL; ++ } ++ ++r->dv_refcount; ++ ++ return r; ++ } ++ ++ static PyObject * ++ DictionaryConstructor(PyTypeObject *subtype, PyObject *args, PyObject *kwargs) ++ { ++ DictionaryObject *self; ++ dict_T *dict; ++ ++ if (!(dict = py_dict_alloc())) ++ return NULL; ++ ++ self = (DictionaryObject *) DictionaryNew(subtype, dict); ++ ++ --dict->dv_refcount; ++ ++ if (kwargs || PyTuple_Size(args)) ++ { ++ PyObject *tmp; ++ if (!(tmp = DictionaryUpdate(self, args, kwargs))) ++ { ++ Py_DECREF(self); ++ return NULL; ++ } ++ ++ Py_DECREF(tmp); ++ } ++ ++ return (PyObject *)(self); ++ } ++ + static void + DictionaryDestructor(DictionaryObject *self) + { +*************** +*** 918,924 **** + { + if (val == NULL) + { +! PyErr_SetString(PyExc_AttributeError, _("Cannot delete DictionaryObject attributes")); + return -1; + } + +--- 966,973 ---- + { + if (val == NULL) + { +! PyErr_SetString(PyExc_AttributeError, +! _("cannot delete vim.Dictionary attributes")); + return -1; + } + +*************** +*** 926,932 **** + { + if (self->dict->dv_lock == VAR_FIXED) + { +! PyErr_SetString(PyExc_TypeError, _("Cannot modify fixed dictionary")); + return -1; + } + else +--- 975,981 ---- + { + if (self->dict->dv_lock == VAR_FIXED) + { +! PyErr_SetString(PyExc_TypeError, _("cannot modify fixed dictionary")); + return -1; + } + else +*************** +*** 943,949 **** + } + else + { +! PyErr_SetString(PyExc_AttributeError, _("Cannot set this attribute")); + return -1; + } + } +--- 992,998 ---- + } + else + { +! PyErr_SetString(PyExc_AttributeError, _("cannot set this attribute")); + return -1; + } + } +*************** +*** 954,979 **** + return ((PyInt) (self->dict->dv_hashtab.ht_used)); + } + + static PyObject * +! DictionaryItem(DictionaryObject *self, PyObject *keyObject) + { + char_u *key; + dictitem_T *di; + DICTKEY_DECL + + DICTKEY_GET(NULL, 0) + +! di = dict_find(self->dict, key, -1); + + DICTKEY_UNREF + +! if (di == NULL) + { +! PyErr_SetObject(PyExc_KeyError, keyObject); + return NULL; + } + +! return ConvertToPyObject(&di->di_tv); + } + + static PyInt +--- 1003,1172 ---- + return ((PyInt) (self->dict->dv_hashtab.ht_used)); + } + ++ #define DICT_FLAG_HAS_DEFAULT 0x01 ++ #define DICT_FLAG_POP 0x02 ++ #define DICT_FLAG_NONE_DEFAULT 0x04 ++ #define DICT_FLAG_RETURN_BOOL 0x08 /* Incompatible with DICT_FLAG_POP */ ++ #define DICT_FLAG_RETURN_PAIR 0x10 ++ + static PyObject * +! _DictionaryItem(DictionaryObject *self, PyObject *args, int flags) + { ++ PyObject *keyObject; ++ PyObject *defObject = ((flags & DICT_FLAG_NONE_DEFAULT)? Py_None : NULL); ++ PyObject *r; + char_u *key; + dictitem_T *di; ++ dict_T *dict = self->dict; ++ hashitem_T *hi; ++ + DICTKEY_DECL + ++ if (flags & DICT_FLAG_HAS_DEFAULT) ++ { ++ if (!PyArg_ParseTuple(args, "O|O", &keyObject, &defObject)) ++ return NULL; ++ } ++ else ++ keyObject = args; ++ ++ if (flags & DICT_FLAG_RETURN_BOOL) ++ defObject = Py_False; ++ + DICTKEY_GET(NULL, 0) + +! hi = hash_find(&dict->dv_hashtab, key); + + DICTKEY_UNREF + +! if (HASHITEM_EMPTY(hi)) + { +! if (defObject) +! { +! Py_INCREF(defObject); +! return defObject; +! } +! else +! { +! PyErr_SetObject(PyExc_KeyError, keyObject); +! return NULL; +! } +! } +! else if (flags & DICT_FLAG_RETURN_BOOL) +! { +! Py_INCREF(Py_True); +! return Py_True; +! } +! +! di = dict_lookup(hi); +! +! if (!(r = ConvertToPyObject(&di->di_tv))) + return NULL; ++ ++ if (flags & DICT_FLAG_POP) ++ { ++ if (dict->dv_lock) ++ { ++ PyErr_SetVim(_("dict is locked")); ++ Py_DECREF(r); ++ return NULL; ++ } ++ ++ hash_remove(&dict->dv_hashtab, hi); ++ dictitem_free(di); + } + +! if (flags & DICT_FLAG_RETURN_PAIR) +! { +! PyObject *tmp = r; +! +! if (!(r = Py_BuildValue("(" Py_bytes_fmt "O)", hi->hi_key, tmp))) +! { +! Py_DECREF(tmp); +! return NULL; +! } +! } +! +! return r; +! } +! +! static PyObject * +! DictionaryItem(DictionaryObject *self, PyObject *keyObject) +! { +! return _DictionaryItem(self, keyObject, 0); +! } +! +! static int +! DictionaryContains(DictionaryObject *self, PyObject *keyObject) +! { +! PyObject *rObj = _DictionaryItem(self, keyObject, DICT_FLAG_RETURN_BOOL); +! int r; +! +! r = (rObj == Py_True); +! +! Py_DECREF(Py_True); +! +! return r; +! } +! +! typedef struct +! { +! hashitem_T *ht_array; +! long_u ht_used; +! hashtab_T *ht; +! hashitem_T *hi; +! int todo; +! } dictiterinfo_T; +! +! static PyObject * +! DictionaryIterNext(dictiterinfo_T **dii) +! { +! PyObject *r; +! +! if (!(*dii)->todo) +! return NULL; +! +! if ((*dii)->ht->ht_array != (*dii)->ht_array || +! (*dii)->ht->ht_used != (*dii)->ht_used) +! { +! PyErr_SetString(PyExc_RuntimeError, +! _("hashtab changed during iteration")); +! return NULL; +! } +! +! while (((*dii)->todo) && HASHITEM_EMPTY((*dii)->hi)) +! ++((*dii)->hi); +! +! --((*dii)->todo); +! +! if (!(r = PyBytes_FromString((char *) (*dii)->hi->hi_key))) +! return NULL; +! +! return r; +! } +! +! static PyObject * +! DictionaryIter(DictionaryObject *self) +! { +! dictiterinfo_T *dii; +! hashtab_T *ht; +! +! if (!(dii = PyMem_New(dictiterinfo_T, 1))) +! { +! PyErr_NoMemory(); +! return NULL; +! } +! +! ht = &self->dict->dv_hashtab; +! dii->ht_array = ht->ht_array; +! dii->ht_used = ht->ht_used; +! dii->ht = ht; +! dii->hi = dii->ht_array; +! dii->todo = dii->ht_used; +! +! return IterNew(dii, +! (destructorfun) PyMem_Free, (nextfun) DictionaryIterNext, +! NULL, NULL); + } + + static PyInt +*************** +*** 1016,1033 **** + + if (di == NULL) + { +! di = dictitem_alloc(key); +! if (di == NULL) + { + PyErr_NoMemory(); + return -1; + } + di->di_tv.v_lock = 0; + + if (dict_add(dict, di) == FAIL) + { + DICTKEY_UNREF + vim_free(di); + PyErr_SetVim(_("failed to add key to dictionary")); + return -1; + } +--- 1209,1227 ---- + + if (di == NULL) + { +! if (!(di = dictitem_alloc(key))) + { + PyErr_NoMemory(); + return -1; + } + di->di_tv.v_lock = 0; ++ di->di_tv.v_type = VAR_UNKNOWN; + + if (dict_add(dict, di) == FAIL) + { + DICTKEY_UNREF + vim_free(di); ++ dictitem_free(di); + PyErr_SetVim(_("failed to add key to dictionary")); + return -1; + } +*************** +*** 1042,1062 **** + return 0; + } + + static PyObject * +! DictionaryListKeys(DictionaryObject *self) + { + dict_T *dict = self->dict; + long_u todo = dict->dv_hashtab.ht_used; + Py_ssize_t i = 0; + PyObject *r; + hashitem_T *hi; + + r = PyList_New(todo); + for (hi = dict->dv_hashtab.ht_array; todo > 0; ++hi) + { + if (!HASHITEM_EMPTY(hi)) + { +! PyList_SetItem(r, i, PyBytes_FromString((char *)(hi->hi_key))); + --todo; + ++i; + } +--- 1236,1269 ---- + return 0; + } + ++ typedef PyObject *(*hi_to_py)(hashitem_T *); ++ + static PyObject * +! DictionaryListObjects(DictionaryObject *self, hi_to_py hiconvert) + { + dict_T *dict = self->dict; + long_u todo = dict->dv_hashtab.ht_used; + Py_ssize_t i = 0; + PyObject *r; + hashitem_T *hi; ++ PyObject *newObj; + + r = PyList_New(todo); + for (hi = dict->dv_hashtab.ht_array; todo > 0; ++hi) + { + if (!HASHITEM_EMPTY(hi)) + { +! if (!(newObj = hiconvert(hi))) +! { +! Py_DECREF(r); +! return NULL; +! } +! if (PyList_SetItem(r, i, newObj)) +! { +! Py_DECREF(r); +! Py_DECREF(newObj); +! return NULL; +! } + --todo; + ++i; + } +*************** +*** 1064,1069 **** +--- 1271,1505 ---- + return r; + } + ++ static PyObject * ++ dict_key(hashitem_T *hi) ++ { ++ return PyBytes_FromString((char *)(hi->hi_key)); ++ } ++ ++ static PyObject * ++ DictionaryListKeys(DictionaryObject *self) ++ { ++ return DictionaryListObjects(self, dict_key); ++ } ++ ++ static PyObject * ++ dict_val(hashitem_T *hi) ++ { ++ dictitem_T *di; ++ ++ di = dict_lookup(hi); ++ return ConvertToPyObject(&di->di_tv); ++ } ++ ++ static PyObject * ++ DictionaryListValues(DictionaryObject *self) ++ { ++ return DictionaryListObjects(self, dict_val); ++ } ++ ++ static PyObject * ++ dict_item(hashitem_T *hi) ++ { ++ PyObject *keyObject; ++ PyObject *valObject; ++ PyObject *r; ++ ++ if (!(keyObject = dict_key(hi))) ++ return NULL; ++ ++ if (!(valObject = dict_val(hi))) ++ { ++ Py_DECREF(keyObject); ++ return NULL; ++ } ++ ++ r = Py_BuildValue("(OO)", keyObject, valObject); ++ ++ Py_DECREF(keyObject); ++ Py_DECREF(valObject); ++ ++ return r; ++ } ++ ++ static PyObject * ++ DictionaryListItems(DictionaryObject *self) ++ { ++ return DictionaryListObjects(self, dict_item); ++ } ++ ++ static PyObject * ++ DictionaryUpdate(DictionaryObject *self, PyObject *args, PyObject *kwargs) ++ { ++ dict_T *dict = self->dict; ++ ++ if (dict->dv_lock) ++ { ++ PyErr_SetVim(_("dict is locked")); ++ return NULL; ++ } ++ ++ if (kwargs) ++ { ++ typval_T tv; ++ ++ if (ConvertFromPyMapping(kwargs, &tv) == -1) ++ return NULL; ++ ++ VimTryStart(); ++ dict_extend(self->dict, tv.vval.v_dict, (char_u *) "force"); ++ clear_tv(&tv); ++ if (VimTryEnd()) ++ return NULL; ++ } ++ else ++ { ++ PyObject *object; ++ ++ if (!PyArg_Parse(args, "(O)", &object)) ++ return NULL; ++ ++ if (PyObject_HasAttrString(object, "keys")) ++ return DictionaryUpdate(self, NULL, object); ++ else ++ { ++ PyObject *iterator; ++ PyObject *item; ++ ++ if (!(iterator = PyObject_GetIter(object))) ++ return NULL; ++ ++ while ((item = PyIter_Next(iterator))) ++ { ++ PyObject *fast; ++ PyObject *keyObject; ++ PyObject *valObject; ++ PyObject *todecref; ++ char_u *key; ++ dictitem_T *di; ++ ++ if (!(fast = PySequence_Fast(item, ""))) ++ { ++ Py_DECREF(iterator); ++ Py_DECREF(item); ++ return NULL; ++ } ++ ++ Py_DECREF(item); ++ ++ if (PySequence_Fast_GET_SIZE(fast) != 2) ++ { ++ Py_DECREF(iterator); ++ Py_DECREF(fast); ++ PyErr_SetString(PyExc_ValueError, ++ _("expected sequence element of size 2")); ++ return NULL; ++ } ++ ++ keyObject = PySequence_Fast_GET_ITEM(fast, 0); ++ ++ if (!(key = StringToChars(keyObject, &todecref))) ++ { ++ Py_DECREF(iterator); ++ Py_DECREF(fast); ++ return NULL; ++ } ++ ++ di = dictitem_alloc(key); ++ ++ Py_XDECREF(todecref); ++ ++ if (di == NULL) ++ { ++ Py_DECREF(fast); ++ Py_DECREF(iterator); ++ PyErr_NoMemory(); ++ return NULL; ++ } ++ di->di_tv.v_lock = 0; ++ di->di_tv.v_type = VAR_UNKNOWN; ++ ++ valObject = PySequence_Fast_GET_ITEM(fast, 1); ++ ++ if (ConvertFromPyObject(valObject, &di->di_tv) == -1) ++ { ++ Py_DECREF(iterator); ++ Py_DECREF(fast); ++ dictitem_free(di); ++ return NULL; ++ } ++ ++ Py_DECREF(fast); ++ ++ if (dict_add(dict, di) == FAIL) ++ { ++ Py_DECREF(iterator); ++ dictitem_free(di); ++ PyErr_SetVim(_("failed to add key to dictionary")); ++ return NULL; ++ } ++ } ++ ++ Py_DECREF(iterator); ++ ++ /* Iterator may have finished due to an exception */ ++ if (PyErr_Occurred()) ++ return NULL; ++ } ++ } ++ Py_INCREF(Py_None); ++ return Py_None; ++ } ++ ++ static PyObject * ++ DictionaryGet(DictionaryObject *self, PyObject *args) ++ { ++ return _DictionaryItem(self, args, ++ DICT_FLAG_HAS_DEFAULT|DICT_FLAG_NONE_DEFAULT); ++ } ++ ++ static PyObject * ++ DictionaryPop(DictionaryObject *self, PyObject *args) ++ { ++ return _DictionaryItem(self, args, DICT_FLAG_HAS_DEFAULT|DICT_FLAG_POP); ++ } ++ ++ static PyObject * ++ DictionaryPopItem(DictionaryObject *self, PyObject *args) ++ { ++ PyObject *keyObject; ++ ++ if (!PyArg_ParseTuple(args, "O", &keyObject)) ++ return NULL; ++ ++ return _DictionaryItem(self, keyObject, ++ DICT_FLAG_POP|DICT_FLAG_RETURN_PAIR); ++ } ++ ++ static PyObject * ++ DictionaryHasKey(DictionaryObject *self, PyObject *args) ++ { ++ PyObject *keyObject; ++ ++ if (!PyArg_ParseTuple(args, "O", &keyObject)) ++ return NULL; ++ ++ return _DictionaryItem(self, keyObject, DICT_FLAG_RETURN_BOOL); ++ } ++ ++ static PySequenceMethods DictionaryAsSeq = { ++ 0, /* sq_length */ ++ 0, /* sq_concat */ ++ 0, /* sq_repeat */ ++ 0, /* sq_item */ ++ 0, /* sq_slice */ ++ 0, /* sq_ass_item */ ++ 0, /* sq_ass_slice */ ++ (objobjproc) DictionaryContains, /* sq_contains */ ++ 0, /* sq_inplace_concat */ ++ 0, /* sq_inplace_repeat */ ++ }; ++ + static PyMappingMethods DictionaryAsMapping = { + (lenfunc) DictionaryLength, + (binaryfunc) DictionaryItem, +*************** +*** 1072,1077 **** +--- 1508,1520 ---- + + static struct PyMethodDef DictionaryMethods[] = { + {"keys", (PyCFunction)DictionaryListKeys, METH_NOARGS, ""}, ++ {"values", (PyCFunction)DictionaryListValues, METH_NOARGS, ""}, ++ {"items", (PyCFunction)DictionaryListItems, METH_NOARGS, ""}, ++ {"update", (PyCFunction)DictionaryUpdate, METH_VARARGS|METH_KEYWORDS, ""}, ++ {"get", (PyCFunction)DictionaryGet, METH_VARARGS, ""}, ++ {"pop", (PyCFunction)DictionaryPop, METH_VARARGS, ""}, ++ {"popitem", (PyCFunction)DictionaryPopItem, METH_VARARGS, ""}, ++ {"has_key", (PyCFunction)DictionaryHasKey, METH_VARARGS, ""}, + {"__dir__", (PyCFunction)DictionaryDir, METH_NOARGS, ""}, + { NULL, NULL, 0, NULL} + }; +*************** +*** 1541,1554 **** + selfdictObject = PyDict_GetItemString(kwargs, "self"); + if (selfdictObject != NULL) + { +! if (!PyMapping_Check(selfdictObject)) +! { +! PyErr_SetString(PyExc_TypeError, +! _("'self' argument must be a dictionary")); +! clear_tv(&args); +! return NULL; +! } +! if (ConvertFromPyObject(selfdictObject, &selfdicttv) == -1) + { + clear_tv(&args); + return NULL; +--- 1984,1990 ---- + selfdictObject = PyDict_GetItemString(kwargs, "self"); + if (selfdictObject != NULL) + { +! if (ConvertFromPyMapping(selfdictObject, &selfdicttv) == -1) + { + clear_tv(&args); + return NULL; +*************** +*** 1994,2000 **** + else if (strcmp(name, "number") == 0) + return PyLong_FromLong((long) get_tab_number(self->tab)); + else if (strcmp(name, "vars") == 0) +! return DictionaryNew(self->tab->tp_vars); + else if (strcmp(name, "window") == 0) + { + /* For current tab window.c does not bother to set or update tp_curwin +--- 2430,2436 ---- + else if (strcmp(name, "number") == 0) + return PyLong_FromLong((long) get_tab_number(self->tab)); + else if (strcmp(name, "vars") == 0) +! return NEW_DICTIONARY(self->tab->tp_vars); + else if (strcmp(name, "window") == 0) + { + /* For current tab window.c does not bother to set or update tp_curwin +*************** +*** 2225,2231 **** + return PyLong_FromLong((long)(W_WINCOL(self->win))); + #endif + else if (strcmp(name, "vars") == 0) +! return DictionaryNew(self->win->w_vars); + else if (strcmp(name, "options") == 0) + return OptionsNew(SREQ_WIN, self->win, (checkfun) CheckWindow, + (PyObject *) self); +--- 2661,2667 ---- + return PyLong_FromLong((long)(W_WINCOL(self->win))); + #endif + else if (strcmp(name, "vars") == 0) +! return NEW_DICTIONARY(self->win->w_vars); + else if (strcmp(name, "options") == 0) + return OptionsNew(SREQ_WIN, self->win, (checkfun) CheckWindow, + (PyObject *) self); +*************** +*** 3402,3408 **** + else if (strcmp(name, "number") == 0) + return Py_BuildValue(Py_ssize_t_fmt, self->buf->b_fnum); + else if (strcmp(name, "vars") == 0) +! return DictionaryNew(self->buf->b_vars); + else if (strcmp(name, "options") == 0) + return OptionsNew(SREQ_BUF, self->buf, (checkfun) CheckBuffer, + (PyObject *) self); +--- 3838,3844 ---- + else if (strcmp(name, "number") == 0) + return Py_BuildValue(Py_ssize_t_fmt, self->buf->b_fnum); + else if (strcmp(name, "vars") == 0) +! return NEW_DICTIONARY(self->buf->b_vars); + else if (strcmp(name, "options") == 0) + return OptionsNew(SREQ_BUF, self->buf, (checkfun) CheckBuffer, + (PyObject *) self); +*************** +*** 4307,4312 **** +--- 4743,4778 ---- + } + + static int ++ ConvertFromPyMapping(PyObject *obj, typval_T *tv) ++ { ++ PyObject *lookup_dict; ++ int r; ++ ++ if (!(lookup_dict = PyDict_New())) ++ return -1; ++ ++ if (PyType_IsSubtype(obj->ob_type, &DictionaryType)) ++ { ++ tv->v_type = VAR_DICT; ++ tv->vval.v_dict = (((DictionaryObject *)(obj))->dict); ++ ++tv->vval.v_dict->dv_refcount; ++ r = 0; ++ } ++ else if (PyDict_Check(obj)) ++ r = convert_dl(obj, tv, pydict_to_tv, lookup_dict); ++ else if (PyMapping_Check(obj)) ++ r = convert_dl(obj, tv, pymap_to_tv, lookup_dict); ++ else ++ { ++ PyErr_SetString(PyExc_TypeError, ++ _("unable to convert object to vim dictionary")); ++ r = -1; ++ } ++ Py_DECREF(lookup_dict); ++ return r; ++ } ++ ++ static int + ConvertFromPyObject(PyObject *obj, typval_T *tv) + { + PyObject *lookup_dict; +*************** +*** 4322,4328 **** + static int + _ConvertFromPyObject(PyObject *obj, typval_T *tv, PyObject *lookup_dict) + { +! if (obj->ob_type == &DictionaryType) + { + tv->v_type = VAR_DICT; + tv->vval.v_dict = (((DictionaryObject *)(obj))->dict); +--- 4788,4794 ---- + static int + _ConvertFromPyObject(PyObject *obj, typval_T *tv, PyObject *lookup_dict) + { +! if (PyType_IsSubtype(obj->ob_type, &DictionaryType)) + { + tv->v_type = VAR_DICT; + tv->vval.v_dict = (((DictionaryObject *)(obj))->dict); +*************** +*** 4437,4443 **** + case VAR_LIST: + return ListNew(tv->vval.v_list); + case VAR_DICT: +! return DictionaryNew(tv->vval.v_dict); + case VAR_FUNC: + return FunctionNew(tv->vval.v_string == NULL + ? (char_u *)"" : tv->vval.v_string); +--- 4903,4909 ---- + case VAR_LIST: + return ListNew(tv->vval.v_list); + case VAR_DICT: +! return NEW_DICTIONARY(tv->vval.v_dict); + case VAR_FUNC: + return FunctionNew(tv->vval.v_string == NULL + ? (char_u *)"" : tv->vval.v_string); +*************** +*** 4608,4617 **** + DictionaryType.tp_name = "vim.dictionary"; + DictionaryType.tp_basicsize = sizeof(DictionaryObject); + DictionaryType.tp_dealloc = (destructor)DictionaryDestructor; + DictionaryType.tp_as_mapping = &DictionaryAsMapping; +! DictionaryType.tp_flags = Py_TPFLAGS_DEFAULT; + DictionaryType.tp_doc = "dictionary pushing modifications to vim structure"; + DictionaryType.tp_methods = DictionaryMethods; + #if PY_MAJOR_VERSION >= 3 + DictionaryType.tp_getattro = (getattrofunc)DictionaryGetattro; + DictionaryType.tp_setattro = (setattrofunc)DictionarySetattro; +--- 5074,5087 ---- + DictionaryType.tp_name = "vim.dictionary"; + DictionaryType.tp_basicsize = sizeof(DictionaryObject); + DictionaryType.tp_dealloc = (destructor)DictionaryDestructor; ++ DictionaryType.tp_as_sequence = &DictionaryAsSeq; + DictionaryType.tp_as_mapping = &DictionaryAsMapping; +! DictionaryType.tp_flags = Py_TPFLAGS_DEFAULT|Py_TPFLAGS_BASETYPE; + DictionaryType.tp_doc = "dictionary pushing modifications to vim structure"; + DictionaryType.tp_methods = DictionaryMethods; ++ DictionaryType.tp_iter = (getiterfunc)DictionaryIter; ++ DictionaryType.tp_new = (newfunc)DictionaryConstructor; ++ DictionaryType.tp_alloc = (allocfunc)PyType_GenericAlloc; + #if PY_MAJOR_VERSION >= 3 + DictionaryType.tp_getattro = (getattrofunc)DictionaryGetattro; + DictionaryType.tp_setattro = (setattrofunc)DictionarySetattro; +*************** +*** 4786,4793 **** + return -1; + ADD_OBJECT(m, "error", VimError); + +! ADD_CHECKED_OBJECT(m, "vars", DictionaryNew(&globvardict)); +! ADD_CHECKED_OBJECT(m, "vvars", DictionaryNew(&vimvardict)); + ADD_CHECKED_OBJECT(m, "options", + OptionsNew(SREQ_GLOBAL, NULL, dummy_check, NULL)); + return 0; +--- 5256,5263 ---- + return -1; + ADD_OBJECT(m, "error", VimError); + +! ADD_CHECKED_OBJECT(m, "vars", NEW_DICTIONARY(&globvardict)); +! ADD_CHECKED_OBJECT(m, "vvars", NEW_DICTIONARY(&vimvardict)); + ADD_CHECKED_OBJECT(m, "options", + OptionsNew(SREQ_GLOBAL, NULL, dummy_check, NULL)); + return 0; +*** ../vim-7.3.1060/src/if_python3.c 2013-05-30 12:40:36.000000000 +0200 +--- src/if_python3.c 2013-05-30 12:47:48.000000000 +0200 +*************** +*** 96,101 **** +--- 96,102 ---- + #define PyInt_FromLong(i) PyLong_FromLong(i) + #define PyInt_AsLong(obj) PyLong_AsLong(obj) + #define Py_ssize_t_fmt "n" ++ #define Py_bytes_fmt "y" + + #if defined(DYNAMIC_PYTHON3) || defined(PROTO) + +*************** +*** 149,154 **** +--- 150,156 ---- + # define PySequence_Check py3_PySequence_Check + # define PySequence_Size py3_PySequence_Size + # define PySequence_GetItem py3_PySequence_GetItem ++ # define PySequence_Fast py3_PySequence_Fast + # define PyTuple_Size py3_PyTuple_Size + # define PyTuple_GetItem py3_PyTuple_GetItem + # define PySlice_GetIndicesEx py3_PySlice_GetIndicesEx +*************** +*** 168,173 **** +--- 170,176 ---- + #undef PyRun_String + # define PyRun_String py3_PyRun_String + # define PyObject_GetAttrString py3_PyObject_GetAttrString ++ # define PyObject_HasAttrString py3_PyObject_HasAttrString + # define PyObject_SetAttrString py3_PyObject_SetAttrString + # define PyObject_CallFunctionObjArgs py3_PyObject_CallFunctionObjArgs + # define PyEval_GetLocals py3_PyEval_GetLocals +*************** +*** 269,274 **** +--- 272,278 ---- + static int (*py3_PySequence_Check)(PyObject *); + static Py_ssize_t (*py3_PySequence_Size)(PyObject *); + static PyObject* (*py3_PySequence_GetItem)(PyObject *, Py_ssize_t); ++ static PyObject* (*py3_PySequence_Fast)(PyObject *, const char *); + static Py_ssize_t (*py3_PyTuple_Size)(PyObject *); + static PyObject* (*py3_PyTuple_GetItem)(PyObject *, Py_ssize_t); + static int (*py3_PyMapping_Check)(PyObject *); +*************** +*** 282,287 **** +--- 286,292 ---- + static int (*py3_PyRun_SimpleString)(char *); + static PyObject* (*py3_PyRun_String)(char *, int, PyObject *, PyObject *); + static PyObject* (*py3_PyObject_GetAttrString)(PyObject *, const char *); ++ static int (*py3_PyObject_HasAttrString)(PyObject *, const char *); + static PyObject* (*py3_PyObject_SetAttrString)(PyObject *, const char *, PyObject *); + static PyObject* (*py3_PyObject_CallFunctionObjArgs)(PyObject *, ...); + static PyObject* (*py3_PyEval_GetGlobals)(); +*************** +*** 425,430 **** +--- 430,436 ---- + {"PySequence_Check", (PYTHON_PROC*)&py3_PySequence_Check}, + {"PySequence_Size", (PYTHON_PROC*)&py3_PySequence_Size}, + {"PySequence_GetItem", (PYTHON_PROC*)&py3_PySequence_GetItem}, ++ {"PySequence_Fast", (PYTHON_PROC*)&py3_PySequence_Fast}, + {"PyTuple_Size", (PYTHON_PROC*)&py3_PyTuple_Size}, + {"PyTuple_GetItem", (PYTHON_PROC*)&py3_PyTuple_GetItem}, + {"PySlice_GetIndicesEx", (PYTHON_PROC*)&py3_PySlice_GetIndicesEx}, +*************** +*** 435,440 **** +--- 441,447 ---- + {"PyRun_SimpleString", (PYTHON_PROC*)&py3_PyRun_SimpleString}, + {"PyRun_String", (PYTHON_PROC*)&py3_PyRun_String}, + {"PyObject_GetAttrString", (PYTHON_PROC*)&py3_PyObject_GetAttrString}, ++ {"PyObject_HasAttrString", (PYTHON_PROC*)&py3_PyObject_HasAttrString}, + {"PyObject_SetAttrString", (PYTHON_PROC*)&py3_PyObject_SetAttrString}, + {"PyObject_CallFunctionObjArgs", (PYTHON_PROC*)&py3_PyObject_CallFunctionObjArgs}, + {"PyEval_GetGlobals", (PYTHON_PROC*)&py3_PyEval_GetGlobals}, +*** ../vim-7.3.1060/src/if_python.c 2013-05-30 12:40:36.000000000 +0200 +--- src/if_python.c 2013-05-30 12:48:47.000000000 +0200 +*************** +*** 103,108 **** +--- 103,109 ---- + # define PyIntIntObjArgProc intintobjargproc + # define Py_ssize_t_fmt "i" + #endif ++ #define Py_bytes_fmt "s" + + /* Parser flags */ + #define single_input 256 +*************** +*** 187,192 **** +--- 188,194 ---- + # define PySequence_Check dll_PySequence_Check + # define PySequence_Size dll_PySequence_Size + # define PySequence_GetItem dll_PySequence_GetItem ++ # define PySequence_Fast dll_PySequence_Fast + # define PyTuple_Size dll_PyTuple_Size + # define PyTuple_GetItem dll_PyTuple_GetItem + # define PyTuple_Type (*dll_PyTuple_Type) +*************** +*** 207,212 **** +--- 209,215 ---- + # define PyRun_SimpleString dll_PyRun_SimpleString + # define PyRun_String dll_PyRun_String + # define PyObject_GetAttrString dll_PyObject_GetAttrString ++ # define PyObject_HasAttrString dll_PyObject_HasAttrString + # define PyObject_SetAttrString dll_PyObject_SetAttrString + # define PyObject_CallFunctionObjArgs dll_PyObject_CallFunctionObjArgs + # define PyString_AsString dll_PyString_AsString +*************** +*** 227,232 **** +--- 230,236 ---- + # define PySys_SetArgv dll_PySys_SetArgv + # define PyType_Type (*dll_PyType_Type) + # define PyType_Ready (*dll_PyType_Ready) ++ # define PyType_GenericAlloc dll_PyType_GenericAlloc + # define Py_BuildValue dll_Py_BuildValue + # define Py_FindMethod dll_Py_FindMethod + # define Py_InitModule4 dll_Py_InitModule4 +*************** +*** 318,323 **** +--- 322,328 ---- + static int (*dll_PySequence_Check)(PyObject *); + static PyInt(*dll_PySequence_Size)(PyObject *); + static PyObject*(*dll_PySequence_GetItem)(PyObject *, PyInt); ++ static PyObject*(*dll_PySequence_Fast)(PyObject *, const char *); + static PyInt(*dll_PyTuple_Size)(PyObject *); + static PyObject*(*dll_PyTuple_GetItem)(PyObject *, PyInt); + static PyTypeObject* dll_PyTuple_Type; +*************** +*** 336,341 **** +--- 341,347 ---- + static int(*dll_PyRun_SimpleString)(char *); + static PyObject *(*dll_PyRun_String)(char *, int, PyObject *, PyObject *); + static PyObject* (*dll_PyObject_GetAttrString)(PyObject *, const char *); ++ static int (*dll_PyObject_HasAttrString)(PyObject *, const char *); + static PyObject* (*dll_PyObject_SetAttrString)(PyObject *, const char *, PyObject *); + static PyObject* (*dll_PyObject_CallFunctionObjArgs)(PyObject *, ...); + static char*(*dll_PyString_AsString)(PyObject *); +*************** +*** 354,359 **** +--- 360,366 ---- + static int(*dll_PySys_SetArgv)(int, char **); + static PyTypeObject* dll_PyType_Type; + static int (*dll_PyType_Ready)(PyTypeObject *type); ++ static PyObject* (*dll_PyType_GenericAlloc)(PyTypeObject *type, PyInt nitems); + static PyObject*(*dll_Py_BuildValue)(char *, ...); + static PyObject*(*dll_Py_FindMethod)(struct PyMethodDef[], PyObject *, char *); + static PyObject*(*dll_Py_InitModule4)(char *, struct PyMethodDef *, char *, PyObject *, int); +*************** +*** 475,483 **** + {"PyList_SetItem", (PYTHON_PROC*)&dll_PyList_SetItem}, + {"PyList_Size", (PYTHON_PROC*)&dll_PyList_Size}, + {"PyList_Type", (PYTHON_PROC*)&dll_PyList_Type}, +- {"PySequence_GetItem", (PYTHON_PROC*)&dll_PySequence_GetItem}, + {"PySequence_Size", (PYTHON_PROC*)&dll_PySequence_Size}, + {"PySequence_Check", (PYTHON_PROC*)&dll_PySequence_Check}, + {"PyTuple_GetItem", (PYTHON_PROC*)&dll_PyTuple_GetItem}, + {"PyTuple_Size", (PYTHON_PROC*)&dll_PyTuple_Size}, + {"PyTuple_Type", (PYTHON_PROC*)&dll_PyTuple_Type}, +--- 482,491 ---- + {"PyList_SetItem", (PYTHON_PROC*)&dll_PyList_SetItem}, + {"PyList_Size", (PYTHON_PROC*)&dll_PyList_Size}, + {"PyList_Type", (PYTHON_PROC*)&dll_PyList_Type}, + {"PySequence_Size", (PYTHON_PROC*)&dll_PySequence_Size}, + {"PySequence_Check", (PYTHON_PROC*)&dll_PySequence_Check}, ++ {"PySequence_GetItem", (PYTHON_PROC*)&dll_PySequence_GetItem}, ++ {"PySequence_Fast", (PYTHON_PROC*)&dll_PySequence_Fast}, + {"PyTuple_GetItem", (PYTHON_PROC*)&dll_PyTuple_GetItem}, + {"PyTuple_Size", (PYTHON_PROC*)&dll_PyTuple_Size}, + {"PyTuple_Type", (PYTHON_PROC*)&dll_PyTuple_Type}, +*************** +*** 496,501 **** +--- 504,510 ---- + {"PyRun_SimpleString", (PYTHON_PROC*)&dll_PyRun_SimpleString}, + {"PyRun_String", (PYTHON_PROC*)&dll_PyRun_String}, + {"PyObject_GetAttrString", (PYTHON_PROC*)&dll_PyObject_GetAttrString}, ++ {"PyObject_HasAttrString", (PYTHON_PROC*)&dll_PyObject_HasAttrString}, + {"PyObject_SetAttrString", (PYTHON_PROC*)&dll_PyObject_SetAttrString}, + {"PyObject_CallFunctionObjArgs", (PYTHON_PROC*)&dll_PyObject_CallFunctionObjArgs}, + {"PyString_AsString", (PYTHON_PROC*)&dll_PyString_AsString}, +*************** +*** 514,519 **** +--- 523,529 ---- + {"PySys_SetArgv", (PYTHON_PROC*)&dll_PySys_SetArgv}, + {"PyType_Type", (PYTHON_PROC*)&dll_PyType_Type}, + {"PyType_Ready", (PYTHON_PROC*)&dll_PyType_Ready}, ++ {"PyType_GenericAlloc", (PYTHON_PROC*)&dll_PyType_GenericAlloc}, + {"Py_FindMethod", (PYTHON_PROC*)&dll_Py_FindMethod}, + {"Py_SetPythonHome", (PYTHON_PROC*)&dll_Py_SetPythonHome}, + {"Py_Initialize", (PYTHON_PROC*)&dll_Py_Initialize}, +*************** +*** 1116,1125 **** + (PyIntObjArgProc) BufferAssItem, /* sq_ass_item, x[i]=v */ + (PyIntIntObjArgProc) BufferAssSlice, /* sq_ass_slice, x[i:j]=v */ + (objobjproc) 0, +- #if PY_MAJOR_VERSION >= 2 + (binaryfunc) 0, + 0, +- #endif + }; + + /* Buffer object - Implementation +--- 1126,1133 ---- +*** ../vim-7.3.1060/src/proto/eval.pro 2013-05-30 12:35:48.000000000 +0200 +--- src/proto/eval.pro 2013-05-30 12:47:48.000000000 +0200 +*************** +*** 75,80 **** +--- 75,81 ---- + dictitem_T *dict_find __ARGS((dict_T *d, char_u *key, int len)); + char_u *get_dict_string __ARGS((dict_T *d, char_u *key, int save)); + long get_dict_number __ARGS((dict_T *d, char_u *key)); ++ void dict_extend __ARGS((dict_T *d1, dict_T *d2, char_u *action)); + char_u *get_function_name __ARGS((expand_T *xp, int idx)); + char_u *get_expr_name __ARGS((expand_T *xp, int idx)); + char_u *get_expanded_name __ARGS((char_u *name, int check)); +*** ../vim-7.3.1060/src/testdir/test86.in 2013-05-30 12:26:52.000000000 +0200 +--- src/testdir/test86.in 2013-05-30 12:47:48.000000000 +0200 +*************** +*** 31,46 **** + :" + :" Extending Dictionary directly with different types + :let d = {} +! :py d=vim.bindeval('d') +! :py d['1']='asd' +! :py d['b']=[1, 2, f] +! :py d['-1']={'a': 1} +! :let dkeys = [] +! :py dk=vim.bindeval('dkeys') +! :py dkeys=d.keys() +! :py dkeys.sort() +! :py dk.extend(dkeys) +! :$put =string(dkeys) + :for [key, val] in sort(items(d)) + : $put =string(key) . ' : ' . string(val) + : unlet key val +--- 31,52 ---- + :" + :" Extending Dictionary directly with different types + :let d = {} +! py << EOF +! d=vim.bindeval('d') +! d['1']='asd' +! d.update(b=[1, 2, f]) +! d.update((('-1', {'a': 1}),)) +! d.update({'0': -1}) +! dk = d.keys() +! dv = d.values() +! di = d.items() +! dk.sort(key=repr) +! dv.sort(key=repr) +! di.sort(key=repr) +! EOF +! :$put =pyeval('repr(dk)') +! :$put =substitute(pyeval('repr(dv)'),'0x\x\+','','g') +! :$put =substitute(pyeval('repr(di)'),'0x\x\+','','g') + :for [key, val] in sort(items(d)) + : $put =string(key) . ' : ' . string(val) + : unlet key val +*************** +*** 60,66 **** +--- 66,85 ---- + :$put =string(l) + :" + :py del d['-1'] ++ :$put =string(pyeval('d.get(''b'', 1)')) ++ :$put =string(pyeval('d.pop(''b'')')) ++ :$put =string(pyeval('d.get(''b'', 1)')) ++ :$put =string(pyeval('d.pop(''1'', 2)')) ++ :$put =string(pyeval('d.pop(''1'', 2)')) ++ :$put =pyeval('repr(d.has_key(''0''))') ++ :$put =pyeval('repr(d.has_key(''1''))') ++ :$put =pyeval('repr(''0'' in d)') ++ :$put =pyeval('repr(''1'' in d)') ++ :$put =pyeval('repr(list(iter(d)))') + :$put =string(d) ++ :$put =pyeval('repr(d.popitem(''0''))') ++ :$put =pyeval('repr(d.get(''0''))') ++ :$put =pyeval('repr(list(iter(d)))') + :" + :" removing items out of range: silently skip items that don't exist + :let l = [0, 1, 2, 3] +*************** +*** 198,203 **** +--- 217,225 ---- + em('d[""]=1') + em('d["a\\0b"]=1') + em('d[u"a\\0b"]=1') ++ ++ em('d.pop("abc")') ++ em('d.popitem("abc")') + EOF + :$put =messages + :unlet messages +*************** +*** 709,714 **** +--- 731,740 ---- + del o + EOF + :" ++ :" Test vim.*.__new__ ++ :$put =string(pyeval('vim.Dictionary({})')) ++ :$put =string(pyeval('vim.Dictionary(a=1)')) ++ :$put =string(pyeval('vim.Dictionary(((''a'', 1),))')) + :" + :" Test stdout/stderr + :redir => messages +*************** +*** 718,723 **** +--- 744,759 ---- + :py sys.stderr.writelines(iter('abc')) + :redir END + :$put =string(substitute(messages, '\d\+', '', 'g')) ++ :" Test subclassing ++ py << EOF ++ class DupDict(vim.Dictionary): ++ def __setitem__(self, key, value): ++ super(DupDict, self).__setitem__(key, value) ++ super(DupDict, self).__setitem__('dup_' + key, value) ++ dd = DupDict() ++ dd['a'] = 'b' ++ EOF ++ :$put =string(sort(keys(pyeval('dd')))) + :" + :" Test exceptions + :fun Exe(e) +*** ../vim-7.3.1060/src/testdir/test86.ok 2013-05-30 12:26:52.000000000 +0200 +--- src/testdir/test86.ok 2013-05-30 12:47:48.000000000 +0200 +*************** +*** 4,16 **** + Vim(put):E684: + [0, 'as''d', [1, 2, function('strlen'), {'a': 1}]] + [0, function('strlen'), [1, 2, function('strlen'), {'a': 1}]] +! ['-1', '1', 'b'] + '-1' : {'a': 1} + '1' : 'asd' + 'b' : [1, 2, function('strlen')] + [0, function('strlen')] + [3] +! {'1': 'asd', 'b': [1, 2, function('strlen')]} + [0, 1, 2, 3] + [0, 1, 2, 3] + [0, 1, 3] +--- 4,32 ---- + Vim(put):E684: + [0, 'as''d', [1, 2, function('strlen'), {'a': 1}]] + [0, function('strlen'), [1, 2, function('strlen'), {'a': 1}]] +! ['-1', '0', '1', 'b'] +! ['asd', -1L, , ] +! [('-1', ), ('0', -1L), ('1', 'asd'), ('b', )] + '-1' : {'a': 1} ++ '0' : -1 + '1' : 'asd' + 'b' : [1, 2, function('strlen')] + [0, function('strlen')] + [3] +! [1, 2, function('strlen')] +! [1, 2, function('strlen')] +! 1 +! 'asd' +! 2 +! True +! False +! True +! False +! ['0'] +! {'0': -1} +! ('', -1L) +! None +! [] + [0, 1, 2, 3] + [0, 1, 2, 3] + [0, 1, 3] +*************** +*** 44,49 **** +--- 60,67 ---- + ValueError + TypeError + TypeError ++ KeyError ++ KeyError + d : locked:0;scope:0 + dl : locked:1;scope:0 + v: : locked:2;scope:1 +*************** +*** 387,396 **** + window:__dir__,__members__,buffer,col,cursor,height,number,options,row,tabpage,valid,vars + tabpage:__dir__,__members__,number,valid,vars,window,windows + range:__dir__,__members__,append,end,start +! dictionary:__dir__,__members__,keys,locked,scope + list:__dir__,__members__,extend,locked + function:__call__,__dir__,__members__,softspace + output:__dir__,__members__,flush,softspace,write,writelines + ' + abcdef + line : +--- 405,417 ---- + window:__dir__,__members__,buffer,col,cursor,height,number,options,row,tabpage,valid,vars + tabpage:__dir__,__members__,number,valid,vars,window,windows + range:__dir__,__members__,append,end,start +! dictionary:__dir__,__members__,get,has_key,items,keys,locked,pop,popitem,scope,update,values + list:__dir__,__members__,extend,locked + function:__call__,__dir__,__members__,softspace + output:__dir__,__members__,flush,softspace,write,writelines ++ {} ++ {'a': 1} ++ {'a': 1} + ' + abcdef + line : +*************** +*** 398,403 **** +--- 419,425 ---- + abc + line : + abc' ++ ['a', 'dup_a'] + (, error('abc',)) + (, error('def',)) + (, error('ghi',)) +*** ../vim-7.3.1060/src/testdir/test87.in 2013-05-30 12:26:52.000000000 +0200 +--- src/testdir/test87.in 2013-05-30 12:47:48.000000000 +0200 +*************** +*** 26,41 **** + :" + :" Extending Dictionary directly with different types + :let d = {} +! :py3 d=vim.bindeval('d') +! :py3 d['1']='asd' +! :py3 d['b']=[1, 2, f] +! :py3 d['-1']={'a': 1} +! :let dkeys = [] +! :py3 dk=vim.bindeval('dkeys') +! :py3 dkeys=d.keys() +! :py3 dkeys.sort() +! :py3 dk+=dkeys +! :$put =string(dkeys) + :for [key, val] in sort(items(d)) + : $put =string(key) . ' : ' . string(val) + : unlet key val +--- 26,47 ---- + :" + :" Extending Dictionary directly with different types + :let d = {} +! py3 << EOF +! d=vim.bindeval('d') +! d['1']='asd' +! d.update(b=[1, 2, f]) +! d.update((('-1', {'a': 1}),)) +! d.update({'0': -1}) +! dk = d.keys() +! dv = d.values() +! di = d.items() +! dk.sort(key=repr) +! dv.sort(key=repr) +! di.sort(key=repr) +! EOF +! :$put =py3eval('repr(dk)') +! :$put =substitute(py3eval('repr(dv)'),'0x\x\+','','g') +! :$put =substitute(py3eval('repr(di)'),'0x\x\+','','g') + :for [key, val] in sort(items(d)) + : $put =string(key) . ' : ' . string(val) + : unlet key val +*************** +*** 55,61 **** +--- 61,80 ---- + :$put =string(l) + :" + :py3 del d['-1'] ++ :$put =string(py3eval('d.get(''b'', 1)')) ++ :$put =string(py3eval('d.pop(''b'')')) ++ :$put =string(py3eval('d.get(''b'', 1)')) ++ :$put =string(py3eval('d.pop(''1'', 2)')) ++ :$put =string(py3eval('d.pop(''1'', 2)')) ++ :$put =py3eval('repr(d.has_key(''0''))') ++ :$put =py3eval('repr(d.has_key(''1''))') ++ :$put =py3eval('repr(''0'' in d)') ++ :$put =py3eval('repr(''1'' in d)') ++ :$put =py3eval('repr(list(iter(d)))') + :$put =string(d) ++ :$put =py3eval('repr(d.popitem(''0''))') ++ :$put =py3eval('repr(d.get(''0''))') ++ :$put =py3eval('repr(list(iter(d)))') + :" + :" removing items out of range: silently skip items that don't exist + :let l = [0, 1, 2, 3] +*************** +*** 181,215 **** + :py3 < messages +*************** +*** 696,701 **** +--- 705,720 ---- + :py sys.stderr.writelines(iter('abc')) + :redir END + :$put =string(substitute(messages, '\d\+', '', 'g')) ++ :" Test subclassing ++ py3 << EOF ++ class DupDict(vim.Dictionary): ++ def __setitem__(self, key, value): ++ super(DupDict, self).__setitem__(key, value) ++ super(DupDict, self).__setitem__('dup_' + key, value) ++ dd = DupDict() ++ dd['a'] = 'b' ++ EOF ++ :$put =string(sort(keys(py3eval('dd')))) + :" + :" Test exceptions + :fun Exe(e) +*** ../vim-7.3.1060/src/testdir/test87.ok 2013-05-30 12:26:52.000000000 +0200 +--- src/testdir/test87.ok 2013-05-30 12:47:48.000000000 +0200 +*************** +*** 4,16 **** + Vim(put):E684: + [0, 'as''d', [1, 2, function('strlen'), {'a': 1}]] + [0, function('strlen'), [1, 2, function('strlen'), {'a': 1}]] +! ['-1', '1', 'b'] + '-1' : {'a': 1} + '1' : 'asd' + 'b' : [1, 2, function('strlen')] + [0, function('strlen')] + [3] +! {'1': 'asd', 'b': [1, 2, function('strlen')]} + [0, 1, 2, 3] + [0, 1, 2, 3] + [0, 1, 3] +--- 4,32 ---- + Vim(put):E684: + [0, 'as''d', [1, 2, function('strlen'), {'a': 1}]] + [0, function('strlen'), [1, 2, function('strlen'), {'a': 1}]] +! [b'-1', b'0', b'1', b'b'] +! [-1, , , b'asd'] +! [(b'-1', ), (b'0', -1), (b'1', b'asd'), (b'b', )] + '-1' : {'a': 1} ++ '0' : -1 + '1' : 'asd' + 'b' : [1, 2, function('strlen')] + [0, function('strlen')] + [3] +! [1, 2, function('strlen')] +! [1, 2, function('strlen')] +! 1 +! 'asd' +! 2 +! True +! False +! True +! False +! [b'0'] +! {'0': -1} +! (b'', -1) +! None +! [] + [0, 1, 2, 3] + [0, 1, 2, 3] + [0, 1, 3] +*************** +*** 44,49 **** +--- 60,67 ---- + ValueError + TypeError + TypeError ++ KeyError ++ KeyError + d : locked:0;scope:0 + dl : locked:1;scope:0 + v: : locked:2;scope:1 +*************** +*** 376,385 **** + window:__dir__,buffer,col,cursor,height,number,options,row,tabpage,valid,vars + tabpage:__dir__,number,valid,vars,window,windows + range:__dir__,append,end,start +! dictionary:__dir__,keys,locked,scope + list:__dir__,extend,locked + function:__call__,__dir__,softspace + output:__dir__,flush,softspace,write,writelines + ' + abcdef + line : +--- 394,406 ---- + window:__dir__,buffer,col,cursor,height,number,options,row,tabpage,valid,vars + tabpage:__dir__,number,valid,vars,window,windows + range:__dir__,append,end,start +! dictionary:__dir__,get,has_key,items,keys,locked,pop,popitem,scope,update,values + list:__dir__,extend,locked + function:__call__,__dir__,softspace + output:__dir__,flush,softspace,write,writelines ++ {} ++ {'a': 1} ++ {'a': 1} + ' + abcdef + line : +*************** +*** 387,392 **** +--- 408,414 ---- + abc + line : + abc' ++ ['a', 'dup_a'] + (, error('abc',)) + (, error('def',)) + (, error('ghi',)) +*** ../vim-7.3.1060/src/version.c 2013-05-30 12:43:50.000000000 +0200 +--- src/version.c 2013-05-30 12:59:48.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1061, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +4. Put your garbage can on your desk and label it "in". + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b3807e3db129cc67ee8e0dbbdbdcc4c989e8fe08 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:30 +0200 Subject: [PATCH 0953/3340] - patchlevel 1062 --- 7.3.1062 | 642 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 642 insertions(+) create mode 100644 7.3.1062 diff --git a/7.3.1062 b/7.3.1062 new file mode 100644 index 00000000..dbc46f6e --- /dev/null +++ b/7.3.1062 @@ -0,0 +1,642 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1062 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1062 +Problem: Python: List is not standard. +Solution: Python patch 21: Add standard methods and fields. (ZyX) +Files: src/if_py_both.h, src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.1061/src/if_py_both.h 2013-05-30 13:01:14.000000000 +0200 +--- src/if_py_both.h 2013-05-30 13:03:54.000000000 +0200 +*************** +*** 1530,1541 **** + pylinkedlist_T ref; + } ListObject; + + static PyObject * +! ListNew(list_T *list) + { + ListObject *self; + +! self = PyObject_NEW(ListObject, &ListType); + if (self == NULL) + return NULL; + self->list = list; +--- 1530,1543 ---- + pylinkedlist_T ref; + } ListObject; + ++ #define NEW_LIST(list) ListNew(&ListType, list) ++ + static PyObject * +! ListNew(PyTypeObject *subtype, list_T *list) + { + ListObject *self; + +! self = (ListObject *) subtype->tp_alloc(subtype, 0); + if (self == NULL) + return NULL; + self->list = list; +*************** +*** 1546,1589 **** + return (PyObject *)(self); + } + +! static void +! ListDestructor(ListObject *self) + { +! pyll_remove(&self->ref, &lastlist); +! list_unref(self->list); + +! DESTRUCTOR_FINISH(self); + } + + static int + list_py_concat(list_T *l, PyObject *obj, PyObject *lookup_dict) + { +! Py_ssize_t i; +! Py_ssize_t lsize = PySequence_Size(obj); +! PyObject *litem; + listitem_T *li; + +! for(i=0; ili_tv.v_lock = 0; + +! litem = PySequence_GetItem(obj, i); +! if (litem == NULL) +! return -1; +! if (_ConvertFromPyObject(litem, &li->li_tv, lookup_dict) == -1) + return -1; + + list_append(l, li); + } + return 0; + } + + static PyInt + ListLength(ListObject *self) + { +--- 1548,1663 ---- + return (PyObject *)(self); + } + +! static list_T * +! py_list_alloc() + { +! list_T *r; + +! if (!(r = list_alloc())) +! { +! PyErr_NoMemory(); +! return NULL; +! } +! ++r->lv_refcount; +! +! return r; + } + + static int + list_py_concat(list_T *l, PyObject *obj, PyObject *lookup_dict) + { +! PyObject *iterator; +! PyObject *item; + listitem_T *li; + +! if (!(iterator = PyObject_GetIter(obj))) +! return -1; +! +! while ((item = PyIter_Next(iterator))) + { +! if (!(li = listitem_alloc())) + { + PyErr_NoMemory(); ++ Py_DECREF(item); ++ Py_DECREF(iterator); + return -1; + } + li->li_tv.v_lock = 0; ++ li->li_tv.v_type = VAR_UNKNOWN; + +! if (_ConvertFromPyObject(item, &li->li_tv, lookup_dict) == -1) +! { +! Py_DECREF(item); +! Py_DECREF(iterator); +! listitem_free(li); + return -1; ++ } ++ ++ Py_DECREF(item); + + list_append(l, li); + } ++ ++ Py_DECREF(iterator); ++ ++ /* Iterator may have finished due to an exception */ ++ if (PyErr_Occurred()) ++ return -1; ++ + return 0; + } + ++ static PyObject * ++ ListConstructor(PyTypeObject *subtype, PyObject *args, PyObject *kwargs) ++ { ++ list_T *list; ++ PyObject *obj = NULL; ++ ++ if (kwargs) ++ { ++ PyErr_SetString(PyExc_TypeError, ++ _("list constructor does not accept keyword arguments")); ++ return NULL; ++ } ++ ++ if (!PyArg_ParseTuple(args, "|O", &obj)) ++ return NULL; ++ ++ if (!(list = py_list_alloc())) ++ return NULL; ++ ++ if (obj) ++ { ++ PyObject *lookup_dict; ++ ++ if (!(lookup_dict = PyDict_New())) ++ { ++ list_unref(list); ++ return NULL; ++ } ++ ++ if (list_py_concat(list, obj, lookup_dict) == -1) ++ { ++ Py_DECREF(lookup_dict); ++ list_unref(list); ++ return NULL; ++ } ++ ++ Py_DECREF(lookup_dict); ++ } ++ ++ return ListNew(subtype, list); ++ } ++ ++ static void ++ ListDestructor(ListObject *self) ++ { ++ pyll_remove(&self->ref, &lastlist); ++ list_unref(self->list); ++ ++ DESTRUCTOR_FINISH(self); ++ } ++ + static PyInt + ListLength(ListObject *self) + { +*************** +*** 1747,1753 **** + if (list_append_tv(l, &tv) == FAIL) + { + clear_tv(&tv); +! PyErr_SetVim(_("Failed to add item to list")); + return -1; + } + } +--- 1821,1827 ---- + if (list_append_tv(l, &tv) == FAIL) + { + clear_tv(&tv); +! PyErr_SetVim(_("failed to add item to list")); + return -1; + } + } +*************** +*** 1765,1777 **** + ListAssSlice(ListObject *self, Py_ssize_t first, Py_ssize_t last, PyObject *obj) + { + PyInt size = ListLength(self); +! Py_ssize_t i; +! Py_ssize_t lsize; +! PyObject *litem; + listitem_T *li; + listitem_T *next; + typval_T v; + list_T *l = self->list; + + if (l->lv_lock) + { +--- 1839,1851 ---- + ListAssSlice(ListObject *self, Py_ssize_t first, Py_ssize_t last, PyObject *obj) + { + PyInt size = ListLength(self); +! PyObject *iterator; +! PyObject *item; + listitem_T *li; + listitem_T *next; + typval_T v; + list_T *l = self->list; ++ PyInt i; + + if (l->lv_lock) + { +*************** +*** 1806,1826 **** + if (obj == NULL) + return 0; + +! if (!PyList_Check(obj)) +! { +! PyErr_SetString(PyExc_TypeError, _("can only assign lists to slice")); + return -1; +- } +- +- lsize = PyList_Size(obj); + +! for(i=0; ilv_refcount; +- +- return r; +- } +- + static int + pyseq_to_tv(PyObject *obj, typval_T *tv, PyObject *lookup_dict) + { +--- 4657,4662 ---- +*************** +*** 4627,4691 **** + return 0; + } + +- static int +- pyiter_to_tv(PyObject *obj, typval_T *tv, PyObject *lookup_dict) +- { +- PyObject *iterator; +- PyObject *item; +- list_T *l; +- listitem_T *li; +- +- if (!(l = py_list_alloc())) +- return -1; +- +- tv->vval.v_list = l; +- tv->v_type = VAR_LIST; +- +- if (!(iterator = PyObject_GetIter(obj))) +- { +- list_unref(l); +- return -1; +- } +- +- while ((item = PyIter_Next(iterator))) +- { +- li = listitem_alloc(); +- if (li == NULL) +- { +- list_unref(l); +- Py_DECREF(iterator); +- PyErr_NoMemory(); +- return -1; +- } +- li->li_tv.v_lock = 0; +- +- if (_ConvertFromPyObject(item, &li->li_tv, lookup_dict) == -1) +- { +- list_unref(l); +- listitem_free(li); +- Py_DECREF(item); +- Py_DECREF(iterator); +- return -1; +- } +- +- list_append(l, li); +- +- Py_DECREF(item); +- } +- +- Py_DECREF(iterator); +- +- /* Iterator may have finished due to an exception */ +- if (PyErr_Occurred()) +- { +- list_unref(l); +- return -1; +- } +- +- --l->lv_refcount; +- return 0; +- } +- + typedef int (*pytotvfunc)(PyObject *, typval_T *, PyObject *); + + static int +--- 4678,4683 ---- +*************** +*** 4866,4874 **** + tv->vval.v_float = (float_T) PyFloat_AsDouble(obj); + } + #endif +! else if (PyIter_Check(obj)) +! return convert_dl(obj, tv, pyiter_to_tv, lookup_dict); +! else if (PySequence_Check(obj)) + return convert_dl(obj, tv, pyseq_to_tv, lookup_dict); + else if (PyMapping_Check(obj)) + return convert_dl(obj, tv, pymap_to_tv, lookup_dict); +--- 4858,4864 ---- + tv->vval.v_float = (float_T) PyFloat_AsDouble(obj); + } + #endif +! else if (PyIter_Check(obj) || PySequence_Check(obj)) + return convert_dl(obj, tv, pyseq_to_tv, lookup_dict); + else if (PyMapping_Check(obj)) + return convert_dl(obj, tv, pymap_to_tv, lookup_dict); +*************** +*** 4901,4907 **** + return PyFloat_FromDouble((double) tv->vval.v_float); + #endif + case VAR_LIST: +! return ListNew(tv->vval.v_list); + case VAR_DICT: + return NEW_DICTIONARY(tv->vval.v_dict); + case VAR_FUNC: +--- 4891,4897 ---- + return PyFloat_FromDouble((double) tv->vval.v_float); + #endif + case VAR_LIST: +! return NEW_LIST(tv->vval.v_list); + case VAR_DICT: + return NEW_DICTIONARY(tv->vval.v_dict); + case VAR_FUNC: +*************** +*** 5096,5105 **** + ListType.tp_basicsize = sizeof(ListObject); + ListType.tp_as_sequence = &ListAsSeq; + ListType.tp_as_mapping = &ListAsMapping; +! ListType.tp_flags = Py_TPFLAGS_DEFAULT; + ListType.tp_doc = "list pushing modifications to vim structure"; + ListType.tp_methods = ListMethods; + ListType.tp_iter = (getiterfunc)ListIter; + #if PY_MAJOR_VERSION >= 3 + ListType.tp_getattro = (getattrofunc)ListGetattro; + ListType.tp_setattro = (setattrofunc)ListSetattro; +--- 5086,5097 ---- + ListType.tp_basicsize = sizeof(ListObject); + ListType.tp_as_sequence = &ListAsSeq; + ListType.tp_as_mapping = &ListAsMapping; +! ListType.tp_flags = Py_TPFLAGS_DEFAULT|Py_TPFLAGS_BASETYPE; + ListType.tp_doc = "list pushing modifications to vim structure"; + ListType.tp_methods = ListMethods; + ListType.tp_iter = (getiterfunc)ListIter; ++ ListType.tp_new = (newfunc)ListConstructor; ++ ListType.tp_alloc = (allocfunc)PyType_GenericAlloc; + #if PY_MAJOR_VERSION >= 3 + ListType.tp_getattro = (getattrofunc)ListGetattro; + ListType.tp_setattro = (setattrofunc)ListSetattro; +*** ../vim-7.3.1061/src/testdir/test86.in 2013-05-30 13:01:14.000000000 +0200 +--- src/testdir/test86.in 2013-05-30 13:03:54.000000000 +0200 +*************** +*** 735,740 **** +--- 735,742 ---- + :$put =string(pyeval('vim.Dictionary({})')) + :$put =string(pyeval('vim.Dictionary(a=1)')) + :$put =string(pyeval('vim.Dictionary(((''a'', 1),))')) ++ :$put =string(pyeval('vim.List()')) ++ :$put =string(pyeval('vim.List(iter(''abc''))')) + :" + :" Test stdout/stderr + :redir => messages +*************** +*** 752,759 **** +--- 754,771 ---- + super(DupDict, self).__setitem__('dup_' + key, value) + dd = DupDict() + dd['a'] = 'b' ++ ++ class DupList(vim.List): ++ def __getitem__(self, idx): ++ return [super(DupList, self).__getitem__(idx)] * 2 ++ ++ dl = DupList() ++ dl2 = DupList(iter('abc')) ++ dl.extend(dl2[0]) + EOF + :$put =string(sort(keys(pyeval('dd')))) ++ :$put =string(pyeval('dl')) ++ :$put =string(pyeval('dl2')) + :" + :" Test exceptions + :fun Exe(e) +*** ../vim-7.3.1061/src/testdir/test86.ok 2013-05-30 13:01:14.000000000 +0200 +--- src/testdir/test86.ok 2013-05-30 13:03:54.000000000 +0200 +*************** +*** 412,417 **** +--- 412,419 ---- + {} + {'a': 1} + {'a': 1} ++ [] ++ ['a', 'b', 'c'] + ' + abcdef + line : +*************** +*** 420,425 **** +--- 422,429 ---- + line : + abc' + ['a', 'dup_a'] ++ ['a', 'a'] ++ ['a', 'b', 'c'] + (, error('abc',)) + (, error('def',)) + (, error('ghi',)) +*** ../vim-7.3.1061/src/testdir/test87.in 2013-05-30 13:01:14.000000000 +0200 +--- src/testdir/test87.in 2013-05-30 13:03:54.000000000 +0200 +*************** +*** 692,701 **** + del o + EOF + :" +! :" Test vim.Dictionary.__new__ + :$put =string(py3eval('vim.Dictionary({})')) + :$put =string(py3eval('vim.Dictionary(a=1)')) + :$put =string(py3eval('vim.Dictionary(((''a'', 1),))')) + :" + :" Test stdout/stderr + :redir => messages +--- 692,703 ---- + del o + EOF + :" +! :" Test vim.*.__new__ + :$put =string(py3eval('vim.Dictionary({})')) + :$put =string(py3eval('vim.Dictionary(a=1)')) + :$put =string(py3eval('vim.Dictionary(((''a'', 1),))')) ++ :$put =string(py3eval('vim.List()')) ++ :$put =string(py3eval('vim.List(iter(''abc''))')) + :" + :" Test stdout/stderr + :redir => messages +*************** +*** 713,720 **** +--- 715,732 ---- + super(DupDict, self).__setitem__('dup_' + key, value) + dd = DupDict() + dd['a'] = 'b' ++ ++ class DupList(vim.List): ++ def __getitem__(self, idx): ++ return [super(DupList, self).__getitem__(idx)] * 2 ++ ++ dl = DupList() ++ dl2 = DupList(iter('abc')) ++ dl.extend(dl2[0]) + EOF + :$put =string(sort(keys(py3eval('dd')))) ++ :$put =string(py3eval('dl')) ++ :$put =string(py3eval('dl2')) + :" + :" Test exceptions + :fun Exe(e) +*** ../vim-7.3.1061/src/testdir/test87.ok 2013-05-30 13:01:14.000000000 +0200 +--- src/testdir/test87.ok 2013-05-30 13:03:54.000000000 +0200 +*************** +*** 401,406 **** +--- 401,408 ---- + {} + {'a': 1} + {'a': 1} ++ [] ++ ['a', 'b', 'c'] + ' + abcdef + line : +*************** +*** 409,414 **** +--- 411,418 ---- + line : + abc' + ['a', 'dup_a'] ++ ['a', 'a'] ++ ['a', 'b', 'c'] + (, error('abc',)) + (, error('def',)) + (, error('ghi',)) +*** ../vim-7.3.1061/src/version.c 2013-05-30 13:01:14.000000000 +0200 +--- src/version.c 2013-05-30 13:02:28.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1062, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +5. Put decaf in the coffee maker for 3 weeks. Once everyone has gotten + over their caffeine addictions, switch to espresso. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 05b7573979405814c8c33854843501b812e40303 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:31 +0200 Subject: [PATCH 0954/3340] - patchlevel 1063 --- 7.3.1063 | 661 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 661 insertions(+) create mode 100644 7.3.1063 diff --git a/7.3.1063 b/7.3.1063 new file mode 100644 index 00000000..179b0b3a --- /dev/null +++ b/7.3.1063 @@ -0,0 +1,661 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1063 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1063 +Problem: Python: Function is not standard. +Solution: Python patch 22: make Function subclassable. (ZyX) +Files: src/eval.c, src/if_py_both.h, src/proto/eval.pro, + src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.1062/src/eval.c 2013-05-30 13:01:14.000000000 +0200 +--- src/eval.c 2013-05-30 13:13:53.000000000 +0200 +*************** +*** 21933,21938 **** +--- 21933,21947 ---- + } + #endif + ++ int ++ translated_function_exists(name) ++ char_u *name; ++ { ++ if (builtin_function(name)) ++ return find_internal_func(name) >= 0; ++ return find_func(name) != NULL; ++ } ++ + /* + * Return TRUE if a function "name" exists. + */ +*************** +*** 21950,21961 **** + /* Only accept "funcname", "funcname ", "funcname (..." and + * "funcname(...", not "funcname!...". */ + if (p != NULL && (*nm == NUL || *nm == '(')) +! { +! if (builtin_function(p)) +! n = (find_internal_func(p) >= 0); +! else +! n = (find_func(p) != NULL); +! } + vim_free(p); + return n; + } +--- 21959,21965 ---- + /* Only accept "funcname", "funcname ", "funcname (..." and + * "funcname(...", not "funcname!...". */ + if (p != NULL && (*nm == NUL || *nm == '(')) +! n = translated_function_exists(p); + vim_free(p); + return n; + } +*************** +*** 21971,21988 **** + p = trans_function_name(&nm, FALSE, TFN_INT|TFN_QUIET, NULL); + + if (p != NULL && *nm == NUL) +! { +! if (!check) + return p; +! else if (builtin_function(p)) +! { +! if (find_internal_func(p) >= 0) +! return p; +! } +! else +! if (find_func(p) != NULL) +! return p; +! } + vim_free(p); + return NULL; + } +--- 21975,21983 ---- + p = trans_function_name(&nm, FALSE, TFN_INT|TFN_QUIET, NULL); + + if (p != NULL && *nm == NUL) +! if (!check || translated_function_exists(p)) + return p; +! + vim_free(p); + return NULL; + } +*** ../vim-7.3.1062/src/if_py_both.h 2013-05-30 13:05:55.000000000 +0200 +--- src/if_py_both.h 2013-05-30 13:08:09.000000000 +0200 +*************** +*** 1991,2020 **** + + static PyTypeObject FunctionType; + + static PyObject * +! FunctionNew(char_u *name) + { + FunctionObject *self; + +! self = PyObject_NEW(FunctionObject, &FunctionType); + if (self == NULL) + return NULL; +! self->name = PyMem_New(char_u, STRLEN(name) + 1); +! if (self->name == NULL) + { +! PyErr_NoMemory(); +! return NULL; + } +! STRCPY(self->name, name); +! func_ref(name); + return (PyObject *)(self); + } + + static void + FunctionDestructor(FunctionObject *self) + { + func_unref(self->name); +! PyMem_Free(self->name); + + DESTRUCTOR_FINISH(self); + } +--- 1991,2063 ---- + + static PyTypeObject FunctionType; + ++ #define NEW_FUNCTION(name) FunctionNew(&FunctionType, name) ++ + static PyObject * +! FunctionNew(PyTypeObject *subtype, char_u *name) + { + FunctionObject *self; + +! self = (FunctionObject *) subtype->tp_alloc(subtype, 0); +! + if (self == NULL) + return NULL; +! +! if (isdigit(*name)) + { +! if (!translated_function_exists(name)) +! { +! PyErr_SetString(PyExc_ValueError, +! _("unnamed function does not exist")); +! return NULL; +! } +! self->name = vim_strsave(name); +! func_ref(self->name); + } +! else +! { +! self->name = get_expanded_name(name, TRUE); +! if (self->name == NULL) +! { +! if (script_autoload(name, TRUE) && !aborting()) +! self->name = get_expanded_name(name, TRUE); +! if (self->name == NULL) +! { +! PyErr_SetString(PyExc_ValueError, _("function does not exist")); +! return NULL; +! } +! } +! } +! + return (PyObject *)(self); + } + ++ static PyObject * ++ FunctionConstructor(PyTypeObject *subtype, PyObject *args, PyObject *kwargs) ++ { ++ PyObject *self; ++ char_u *name; ++ ++ if (kwargs) ++ { ++ PyErr_SetString(PyExc_TypeError, ++ _("function constructor does not accept keyword arguments")); ++ return NULL; ++ } ++ ++ if (!PyArg_ParseTuple(args, "s", &name)) ++ return NULL; ++ ++ self = FunctionNew(subtype, name); ++ ++ return self; ++ } ++ + static void + FunctionDestructor(FunctionObject *self) + { + func_unref(self->name); +! vim_free(self->name); + + DESTRUCTOR_FINISH(self); + } +*************** +*** 2093,2099 **** + } + + static struct PyMethodDef FunctionMethods[] = { +- {"__call__",(PyCFunction)FunctionCall, METH_VARARGS|METH_KEYWORDS, ""}, + {"__dir__", (PyCFunction)FunctionDir, METH_NOARGS, ""}, + { NULL, NULL, 0, NULL} + }; +--- 2136,2141 ---- +*************** +*** 4895,4901 **** + case VAR_DICT: + return NEW_DICTIONARY(tv->vval.v_dict); + case VAR_FUNC: +! return FunctionNew(tv->vval.v_string == NULL + ? (char_u *)"" : tv->vval.v_string); + case VAR_UNKNOWN: + Py_INCREF(Py_None); +--- 4937,4943 ---- + case VAR_DICT: + return NEW_DICTIONARY(tv->vval.v_dict); + case VAR_FUNC: +! return NEW_FUNCTION(tv->vval.v_string == NULL + ? (char_u *)"" : tv->vval.v_string); + case VAR_UNKNOWN: + Py_INCREF(Py_None); +*************** +*** 5105,5114 **** + FunctionType.tp_basicsize = sizeof(FunctionObject); + FunctionType.tp_dealloc = (destructor)FunctionDestructor; + FunctionType.tp_call = (ternaryfunc)FunctionCall; +! FunctionType.tp_flags = Py_TPFLAGS_DEFAULT; + FunctionType.tp_doc = "object that calls vim function"; + FunctionType.tp_methods = FunctionMethods; + FunctionType.tp_repr = (reprfunc)FunctionRepr; + #if PY_MAJOR_VERSION >= 3 + FunctionType.tp_getattro = (getattrofunc)FunctionGetattro; + #else +--- 5147,5158 ---- + FunctionType.tp_basicsize = sizeof(FunctionObject); + FunctionType.tp_dealloc = (destructor)FunctionDestructor; + FunctionType.tp_call = (ternaryfunc)FunctionCall; +! FunctionType.tp_flags = Py_TPFLAGS_DEFAULT|Py_TPFLAGS_BASETYPE; + FunctionType.tp_doc = "object that calls vim function"; + FunctionType.tp_methods = FunctionMethods; + FunctionType.tp_repr = (reprfunc)FunctionRepr; ++ FunctionType.tp_new = (newfunc)FunctionConstructor; ++ FunctionType.tp_alloc = (allocfunc)PyType_GenericAlloc; + #if PY_MAJOR_VERSION >= 3 + FunctionType.tp_getattro = (getattrofunc)FunctionGetattro; + #else +*** ../vim-7.3.1062/src/proto/eval.pro 2013-05-30 13:01:14.000000000 +0200 +--- src/proto/eval.pro 2013-05-30 13:08:09.000000000 +0200 +*************** +*** 79,84 **** +--- 79,85 ---- + char_u *get_function_name __ARGS((expand_T *xp, int idx)); + char_u *get_expr_name __ARGS((expand_T *xp, int idx)); + char_u *get_expanded_name __ARGS((char_u *name, int check)); ++ int translated_function_exists __ARGS((char_u *name)); + int func_call __ARGS((char_u *name, typval_T *args, dict_T *selfdict, typval_T *rettv)); + void mzscheme_call_vim __ARGS((char_u *name, typval_T *args, typval_T *rettv)); + long do_searchpair __ARGS((char_u *spat, char_u *mpat, char_u *epat, int dir, char_u *skip, int flags, pos_T *match_pos, linenr_T lnum_stop, long time_limit)); +*** ../vim-7.3.1062/src/testdir/test86.in 2013-05-30 13:05:55.000000000 +0200 +--- src/testdir/test86.in 2013-05-30 13:08:09.000000000 +0200 +*************** +*** 31,36 **** +--- 31,39 ---- + :" + :" Extending Dictionary directly with different types + :let d = {} ++ :fun d.f() ++ : return 1 ++ :endfun + py << EOF + d=vim.bindeval('d') + d['1']='asd' +*************** +*** 44,55 **** + dv.sort(key=repr) + di.sort(key=repr) + EOF + :$put =pyeval('repr(dk)') + :$put =substitute(pyeval('repr(dv)'),'0x\x\+','','g') + :$put =substitute(pyeval('repr(di)'),'0x\x\+','','g') +! :for [key, val] in sort(items(d)) +! : $put =string(key) . ' : ' . string(val) +! : unlet key val + :endfor + :" + :" removing items with del +--- 47,59 ---- + dv.sort(key=repr) + di.sort(key=repr) + EOF ++ :$put =pyeval('d[''f''](self={})') + :$put =pyeval('repr(dk)') + :$put =substitute(pyeval('repr(dv)'),'0x\x\+','','g') + :$put =substitute(pyeval('repr(di)'),'0x\x\+','','g') +! :for [key, Val] in sort(items(d)) +! : $put =string(key) . ' : ' . string(Val) +! : unlet key Val + :endfor + :" + :" removing items with del +*************** +*** 66,71 **** +--- 70,76 ---- + :$put =string(l) + :" + :py del d['-1'] ++ :py del d['f'] + :$put =string(pyeval('d.get(''b'', 1)')) + :$put =string(pyeval('d.pop(''b'')')) + :$put =string(pyeval('d.get(''b'', 1)')) +*************** +*** 187,195 **** + :catch + : $put =v:exception[:16] + :endtry + :delfunction New + :try +! : py l[0](1, 2, 3) + :catch + : $put =v:exception[:16] + :endtry +--- 192,201 ---- + :catch + : $put =v:exception[:16] + :endtry ++ :py f=l[0] + :delfunction New + :try +! : py f(1, 2, 3) + :catch + : $put =v:exception[:16] + :endtry +*************** +*** 737,742 **** +--- 743,749 ---- + :$put =string(pyeval('vim.Dictionary(((''a'', 1),))')) + :$put =string(pyeval('vim.List()')) + :$put =string(pyeval('vim.List(iter(''abc''))')) ++ :$put =string(pyeval('vim.Function(''tr'')')) + :" + :" Test stdout/stderr + :redir => messages +*************** +*** 747,752 **** +--- 754,763 ---- + :redir END + :$put =string(substitute(messages, '\d\+', '', 'g')) + :" Test subclassing ++ :fun Put(...) ++ : $put =string(a:000) ++ : return a:000 ++ :endfun + py << EOF + class DupDict(vim.Dictionary): + def __setitem__(self, key, value): +*************** +*** 762,771 **** +--- 773,789 ---- + dl = DupList() + dl2 = DupList(iter('abc')) + dl.extend(dl2[0]) ++ ++ class DupFun(vim.Function): ++ def __call__(self, arg): ++ return super(DupFun, self).__call__(arg, arg) ++ ++ df = DupFun('Put') + EOF + :$put =string(sort(keys(pyeval('dd')))) + :$put =string(pyeval('dl')) + :$put =string(pyeval('dl2')) ++ :$put =string(pyeval('df(2)')) + :" + :" Test exceptions + :fun Exe(e) +*** ../vim-7.3.1062/src/testdir/test86.ok 2013-05-30 13:05:55.000000000 +0200 +--- src/testdir/test86.ok 2013-05-30 13:08:09.000000000 +0200 +*************** +*** 4,16 **** + Vim(put):E684: + [0, 'as''d', [1, 2, function('strlen'), {'a': 1}]] + [0, function('strlen'), [1, 2, function('strlen'), {'a': 1}]] +! ['-1', '0', '1', 'b'] +! ['asd', -1L, , ] +! [('-1', ), ('0', -1L), ('1', 'asd'), ('b', )] + '-1' : {'a': 1} + '0' : -1 + '1' : 'asd' + 'b' : [1, 2, function('strlen')] + [0, function('strlen')] + [3] + [1, 2, function('strlen')] +--- 4,18 ---- + Vim(put):E684: + [0, 'as''d', [1, 2, function('strlen'), {'a': 1}]] + [0, function('strlen'), [1, 2, function('strlen'), {'a': 1}]] +! 1 +! ['-1', '0', '1', 'b', 'f'] +! ['asd', -1L, , , ] +! [('-1', ), ('0', -1L), ('1', 'asd'), ('b', ), ('f', )] + '-1' : {'a': 1} + '0' : -1 + '1' : 'asd' + 'b' : [1, 2, function('strlen')] ++ 'f' : function('1') + [0, function('strlen')] + [3] + [1, 2, function('strlen')] +*************** +*** 407,419 **** + range:__dir__,__members__,append,end,start + dictionary:__dir__,__members__,get,has_key,items,keys,locked,pop,popitem,scope,update,values + list:__dir__,__members__,extend,locked +! function:__call__,__dir__,__members__,softspace + output:__dir__,__members__,flush,softspace,write,writelines + {} + {'a': 1} + {'a': 1} + [] + ['a', 'b', 'c'] + ' + abcdef + line : +--- 409,422 ---- + range:__dir__,__members__,append,end,start + dictionary:__dir__,__members__,get,has_key,items,keys,locked,pop,popitem,scope,update,values + list:__dir__,__members__,extend,locked +! function:__dir__,__members__,softspace + output:__dir__,__members__,flush,softspace,write,writelines + {} + {'a': 1} + {'a': 1} + [] + ['a', 'b', 'c'] ++ function('tr') + ' + abcdef + line : +*************** +*** 424,429 **** +--- 427,434 ---- + ['a', 'dup_a'] + ['a', 'a'] + ['a', 'b', 'c'] ++ [2, 2] ++ [2, 2] + (, error('abc',)) + (, error('def',)) + (, error('ghi',)) +*** ../vim-7.3.1062/src/testdir/test87.in 2013-05-30 13:05:55.000000000 +0200 +--- src/testdir/test87.in 2013-05-30 13:08:09.000000000 +0200 +*************** +*** 26,31 **** +--- 26,34 ---- + :" + :" Extending Dictionary directly with different types + :let d = {} ++ :fun d.f() ++ : return 1 ++ :endfun + py3 << EOF + d=vim.bindeval('d') + d['1']='asd' +*************** +*** 39,50 **** + dv.sort(key=repr) + di.sort(key=repr) + EOF + :$put =py3eval('repr(dk)') + :$put =substitute(py3eval('repr(dv)'),'0x\x\+','','g') + :$put =substitute(py3eval('repr(di)'),'0x\x\+','','g') +! :for [key, val] in sort(items(d)) +! : $put =string(key) . ' : ' . string(val) +! : unlet key val + :endfor + :" + :" removing items with del +--- 42,54 ---- + dv.sort(key=repr) + di.sort(key=repr) + EOF ++ :$put =py3eval('d[''f''](self={})') + :$put =py3eval('repr(dk)') + :$put =substitute(py3eval('repr(dv)'),'0x\x\+','','g') + :$put =substitute(py3eval('repr(di)'),'0x\x\+','','g') +! :for [key, Val] in sort(items(d)) +! : $put =string(key) . ' : ' . string(Val) +! : unlet key Val + :endfor + :" + :" removing items with del +*************** +*** 61,66 **** +--- 65,71 ---- + :$put =string(l) + :" + :py3 del d['-1'] ++ :py3 del d['f'] + :$put =string(py3eval('d.get(''b'', 1)')) + :$put =string(py3eval('d.pop(''b'')')) + :$put =string(py3eval('d.get(''b'', 1)')) +*************** +*** 182,190 **** + :catch + : $put =v:exception[:13] + :endtry + :delfunction New + :try +! : py3 l[0](1, 2, 3) + :catch + : $put =v:exception[:13] + :endtry +--- 187,196 ---- + :catch + : $put =v:exception[:13] + :endtry ++ :py3 f=l[0] + :delfunction New + :try +! : py3 f(1, 2, 3) + :catch + : $put =v:exception[:13] + :endtry +*************** +*** 698,703 **** +--- 704,710 ---- + :$put =string(py3eval('vim.Dictionary(((''a'', 1),))')) + :$put =string(py3eval('vim.List()')) + :$put =string(py3eval('vim.List(iter(''abc''))')) ++ :$put =string(py3eval('vim.Function(''tr'')')) + :" + :" Test stdout/stderr + :redir => messages +*************** +*** 708,713 **** +--- 715,724 ---- + :redir END + :$put =string(substitute(messages, '\d\+', '', 'g')) + :" Test subclassing ++ :fun Put(...) ++ : $put =string(a:000) ++ : return a:000 ++ :endfun + py3 << EOF + class DupDict(vim.Dictionary): + def __setitem__(self, key, value): +*************** +*** 723,732 **** +--- 734,750 ---- + dl = DupList() + dl2 = DupList(iter('abc')) + dl.extend(dl2[0]) ++ ++ class DupFun(vim.Function): ++ def __call__(self, arg): ++ return super(DupFun, self).__call__(arg, arg) ++ ++ df = DupFun('Put') + EOF + :$put =string(sort(keys(py3eval('dd')))) + :$put =string(py3eval('dl')) + :$put =string(py3eval('dl2')) ++ :$put =string(py3eval('df(2)')) + :" + :" Test exceptions + :fun Exe(e) +*** ../vim-7.3.1062/src/testdir/test87.ok 2013-05-30 13:05:55.000000000 +0200 +--- src/testdir/test87.ok 2013-05-30 13:08:09.000000000 +0200 +*************** +*** 4,16 **** + Vim(put):E684: + [0, 'as''d', [1, 2, function('strlen'), {'a': 1}]] + [0, function('strlen'), [1, 2, function('strlen'), {'a': 1}]] +! [b'-1', b'0', b'1', b'b'] +! [-1, , , b'asd'] +! [(b'-1', ), (b'0', -1), (b'1', b'asd'), (b'b', )] + '-1' : {'a': 1} + '0' : -1 + '1' : 'asd' + 'b' : [1, 2, function('strlen')] + [0, function('strlen')] + [3] + [1, 2, function('strlen')] +--- 4,18 ---- + Vim(put):E684: + [0, 'as''d', [1, 2, function('strlen'), {'a': 1}]] + [0, function('strlen'), [1, 2, function('strlen'), {'a': 1}]] +! 1 +! [b'-1', b'0', b'1', b'b', b'f'] +! [-1, , , , b'asd'] +! [(b'-1', ), (b'0', -1), (b'1', b'asd'), (b'b', ), (b'f', )] + '-1' : {'a': 1} + '0' : -1 + '1' : 'asd' + 'b' : [1, 2, function('strlen')] ++ 'f' : function('1') + [0, function('strlen')] + [3] + [1, 2, function('strlen')] +*************** +*** 396,408 **** + range:__dir__,append,end,start + dictionary:__dir__,get,has_key,items,keys,locked,pop,popitem,scope,update,values + list:__dir__,extend,locked +! function:__call__,__dir__,softspace + output:__dir__,flush,softspace,write,writelines + {} + {'a': 1} + {'a': 1} + [] + ['a', 'b', 'c'] + ' + abcdef + line : +--- 398,411 ---- + range:__dir__,append,end,start + dictionary:__dir__,get,has_key,items,keys,locked,pop,popitem,scope,update,values + list:__dir__,extend,locked +! function:__dir__,softspace + output:__dir__,flush,softspace,write,writelines + {} + {'a': 1} + {'a': 1} + [] + ['a', 'b', 'c'] ++ function('tr') + ' + abcdef + line : +*************** +*** 413,418 **** +--- 416,423 ---- + ['a', 'dup_a'] + ['a', 'a'] + ['a', 'b', 'c'] ++ [2, 2] ++ [2, 2] + (, error('abc',)) + (, error('def',)) + (, error('ghi',)) +*** ../vim-7.3.1062/src/version.c 2013-05-30 13:05:55.000000000 +0200 +--- src/version.c 2013-05-30 13:07:47.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1063, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +6. In the memo field of all your checks, write "for sexual favors". + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 99c6df523bc28e91a0846f24e17db3dc1547b0f8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:31 +0200 Subject: [PATCH 0955/3340] - patchlevel 1064 --- 7.3.1064 | 192 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 192 insertions(+) create mode 100644 7.3.1064 diff --git a/7.3.1064 b/7.3.1064 new file mode 100644 index 00000000..c2e27499 --- /dev/null +++ b/7.3.1064 @@ -0,0 +1,192 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1064 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1064 +Problem: Python: insufficient error checking. +Solution: Python patch 23. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1063/src/if_py_both.h 2013-05-30 13:14:06.000000000 +0200 +--- src/if_py_both.h 2013-05-30 13:16:23.000000000 +0200 +*************** +*** 3304,3313 **** + + for (i = 0; i < new_len; ++i) + { +! PyObject *line = PyList_GetItem(list, i); + +! array[i] = StringToLine(line); +! if (array[i] == NULL) + { + while (i) + vim_free(array[--i]); +--- 3304,3313 ---- + + for (i = 0; i < new_len; ++i) + { +! PyObject *line; + +! if (!(line = PyList_GetItem(list, i)) || +! !(array[i] = StringToLine(line))) + { + while (i) + vim_free(array[--i]); +*************** +*** 3319,3325 **** + VimTryStart(); + PyErr_Clear(); + +! // START of region without "return". Must call restore_buffer()! + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)(lo-1), (linenr_T)hi) == FAIL) +--- 3319,3325 ---- + VimTryStart(); + PyErr_Clear(); + +! /* START of region without "return". Must call restore_buffer()! */ + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)(lo-1), (linenr_T)hi) == FAIL) +*************** +*** 3400,3406 **** + if (buf == savebuf) + py_fix_cursor((linenr_T)lo, (linenr_T)hi, (linenr_T)extra); + +! // END of region without "return". + restore_buffer(savebuf); + + if (VimTryEnd()) +--- 3400,3406 ---- + if (buf == savebuf) + py_fix_cursor((linenr_T)lo, (linenr_T)hi, (linenr_T)extra); + +! /* END of region without "return". */ + restore_buffer(savebuf); + + if (VimTryEnd()) +*************** +*** 3479,3488 **** + + for (i = 0; i < size; ++i) + { +! PyObject *line = PyList_GetItem(lines, i); +! array[i] = StringToLine(line); + +! if (array[i] == NULL) + { + while (i) + vim_free(array[--i]); +--- 3479,3488 ---- + + for (i = 0; i < size; ++i) + { +! PyObject *line; + +! if (!(line = PyList_GetItem(lines, i)) || +! !(array[i] = StringToLine(line))) + { + while (i) + vim_free(array[--i]); +*************** +*** 4014,4021 **** + + if (!PyArg_ParseTuple(args, "s", &pmark)) + return NULL; +- mark = *pmark; + + VimTryStart(); + switch_buffer(&savebuf, self->buf); + posp = getmark(mark, FALSE); +--- 4014,4028 ---- + + if (!PyArg_ParseTuple(args, "s", &pmark)) + return NULL; + ++ if (STRLEN(pmark) != 1) ++ { ++ PyErr_SetString(PyExc_ValueError, ++ _("mark name must be a single character")); ++ return NULL; ++ } ++ ++ mark = *pmark; + VimTryStart(); + switch_buffer(&savebuf, self->buf); + posp = getmark(mark, FALSE); +*************** +*** 4258,4264 **** + + if (value->ob_type != &BufferType) + { +! PyErr_SetString(PyExc_TypeError, _("expected vim.buffer object")); + return -1; + } + +--- 4265,4271 ---- + + if (value->ob_type != &BufferType) + { +! PyErr_SetString(PyExc_TypeError, _("expected vim.Buffer object")); + return -1; + } + +*************** +*** 4283,4289 **** + + if (value->ob_type != &WindowType) + { +! PyErr_SetString(PyExc_TypeError, _("expected vim.window object")); + return -1; + } + +--- 4290,4296 ---- + + if (value->ob_type != &WindowType) + { +! PyErr_SetString(PyExc_TypeError, _("expected vim.Window object")); + return -1; + } + +*************** +*** 4315,4321 **** + { + if (value->ob_type != &TabPageType) + { +! PyErr_SetString(PyExc_TypeError, _("expected vim.tabpage object")); + return -1; + } + +--- 4322,4328 ---- + { + if (value->ob_type != &TabPageType) + { +! PyErr_SetString(PyExc_TypeError, _("expected vim.TabPage object")); + return -1; + } + +*** ../vim-7.3.1063/src/version.c 2013-05-30 13:14:06.000000000 +0200 +--- src/version.c 2013-05-30 13:15:32.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1064, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +7. Finish all your sentences with "in accordance with the prophecy". + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 74e3fe64bad0560982c408fa73ea71b2a14cd90b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:32 +0200 Subject: [PATCH 0956/3340] - patchlevel 1065 --- 7.3.1065 | 381 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 381 insertions(+) create mode 100644 7.3.1065 diff --git a/7.3.1065 b/7.3.1065 new file mode 100644 index 00000000..bb62400f --- /dev/null +++ b/7.3.1065 @@ -0,0 +1,381 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1065 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1065 +Problem: Python: key mapping is not standard. +Solution: Puthon patch 24: use PyMapping_Keys. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c + + +*** ../vim-7.3.1064/src/if_py_both.h 2013-05-30 13:17:13.000000000 +0200 +--- src/if_py_both.h 2013-05-30 13:19:50.000000000 +0200 +*************** +*** 4612,4621 **** + char_u *key; + dictitem_T *di; + PyObject *list; +! PyObject *litem; + PyObject *keyObject; + PyObject *valObject; +- Py_ssize_t lsize; + + if (!(dict = dict_alloc())) + return -1; +--- 4612,4620 ---- + char_u *key; + dictitem_T *di; + PyObject *list; +! PyObject *iterator; + PyObject *keyObject; + PyObject *valObject; + + if (!(dict = dict_alloc())) + return -1; +*************** +*** 4623,4683 **** + tv->v_type = VAR_DICT; + tv->vval.v_dict = dict; + +! list = PyMapping_Items(obj); +! if (list == NULL) + { + dict_unref(dict); + return -1; + } +- lsize = PyList_Size(list); +- while (lsize--) +- { +- DICTKEY_DECL + +! litem = PyList_GetItem(list, lsize); +! if (litem == NULL) +! { +! Py_DECREF(list); +! dict_unref(dict); +! return -1; +! } + +! if (!(keyObject = PyTuple_GetItem(litem, 0))) +! { +! Py_DECREF(list); +! Py_DECREF(litem); +! dict_unref(dict); +! return -1; +! } + + if (!DICTKEY_SET_KEY) + { + dict_unref(dict); +- Py_DECREF(list); +- Py_DECREF(litem); + DICTKEY_UNREF + return -1; + } + DICTKEY_CHECK_EMPTY(-1) + +! if (!(valObject = PyTuple_GetItem(litem, 1))) + { +! Py_DECREF(list); +! Py_DECREF(litem); + dict_unref(dict); + DICTKEY_UNREF + return -1; + } + +- Py_DECREF(litem); +- + di = dictitem_alloc(key); + + DICTKEY_UNREF + + if (di == NULL) + { +! Py_DECREF(list); + dict_unref(dict); + PyErr_NoMemory(); + return -1; +--- 4622,4673 ---- + tv->v_type = VAR_DICT; + tv->vval.v_dict = dict; + +! if (!(list = PyMapping_Keys(obj))) + { + dict_unref(dict); + return -1; + } + +! if (!(iterator = PyObject_GetIter(list))) +! { +! dict_unref(dict); +! Py_DECREF(list); +! return -1; +! } +! Py_DECREF(list); + +! while ((keyObject = PyIter_Next(iterator))) +! { +! DICTKEY_DECL + + if (!DICTKEY_SET_KEY) + { ++ Py_DECREF(iterator); + dict_unref(dict); + DICTKEY_UNREF + return -1; + } + DICTKEY_CHECK_EMPTY(-1) + +! if (!(valObject = PyObject_GetItem(obj, keyObject))) + { +! Py_DECREF(keyObject); +! Py_DECREF(iterator); + dict_unref(dict); + DICTKEY_UNREF + return -1; + } + + di = dictitem_alloc(key); + + DICTKEY_UNREF + ++ Py_DECREF(keyObject); ++ + if (di == NULL) + { +! Py_DECREF(iterator); +! Py_DECREF(valObject); + dict_unref(dict); + PyErr_NoMemory(); + return -1; +*************** +*** 4686,4708 **** + + if (_ConvertFromPyObject(valObject, &di->di_tv, lookup_dict) == -1) + { + vim_free(di); + dict_unref(dict); +- Py_DECREF(list); + return -1; + } + + if (dict_add(dict, di) == FAIL) + { + dictitem_free(di); + dict_unref(dict); +- Py_DECREF(list); + PyErr_SetVim(_("failed to add key to dictionary")); + return -1; + } + } + --dict->dv_refcount; +- Py_DECREF(list); + return 0; + } + +--- 4676,4701 ---- + + if (_ConvertFromPyObject(valObject, &di->di_tv, lookup_dict) == -1) + { ++ Py_DECREF(iterator); ++ Py_DECREF(valObject); + vim_free(di); + dict_unref(dict); + return -1; + } + ++ Py_DECREF(valObject); ++ + if (dict_add(dict, di) == FAIL) + { ++ Py_DECREF(iterator); + dictitem_free(di); + dict_unref(dict); + PyErr_SetVim(_("failed to add key to dictionary")); + return -1; + } + } ++ Py_DECREF(iterator); + --dict->dv_refcount; + return 0; + } + +*************** +*** 4907,4912 **** +--- 4900,4907 ---- + tv->vval.v_float = (float_T) PyFloat_AsDouble(obj); + } + #endif ++ else if (PyObject_HasAttrString(obj, "keys")) ++ return convert_dl(obj, tv, pymap_to_tv, lookup_dict); + else if (PyIter_Check(obj) || PySequence_Check(obj)) + return convert_dl(obj, tv, pyseq_to_tv, lookup_dict); + else if (PyMapping_Check(obj)) +*** ../vim-7.3.1064/src/if_python3.c 2013-05-30 13:01:14.000000000 +0200 +--- src/if_python3.c 2013-05-30 13:19:50.000000000 +0200 +*************** +*** 160,168 **** + # define PyDict_GetItemString py3_PyDict_GetItemString + # define PyDict_Next py3_PyDict_Next + # define PyMapping_Check py3_PyMapping_Check +! # define PyMapping_Items py3_PyMapping_Items + # define PyIter_Next py3_PyIter_Next + # define PyObject_GetIter py3_PyObject_GetIter + # define PyObject_IsTrue py3_PyObject_IsTrue + # define PyModule_GetDict py3_PyModule_GetDict + #undef PyRun_SimpleString +--- 160,169 ---- + # define PyDict_GetItemString py3_PyDict_GetItemString + # define PyDict_Next py3_PyDict_Next + # define PyMapping_Check py3_PyMapping_Check +! # define PyMapping_Keys py3_PyMapping_Keys + # define PyIter_Next py3_PyIter_Next + # define PyObject_GetIter py3_PyObject_GetIter ++ # define PyObject_GetItem py3_PyObject_GetItem + # define PyObject_IsTrue py3_PyObject_IsTrue + # define PyModule_GetDict py3_PyModule_GetDict + #undef PyRun_SimpleString +*************** +*** 276,282 **** + static Py_ssize_t (*py3_PyTuple_Size)(PyObject *); + static PyObject* (*py3_PyTuple_GetItem)(PyObject *, Py_ssize_t); + static int (*py3_PyMapping_Check)(PyObject *); +! static PyObject* (*py3_PyMapping_Items)(PyObject *); + static int (*py3_PySlice_GetIndicesEx)(PyObject *r, Py_ssize_t length, + Py_ssize_t *start, Py_ssize_t *stop, Py_ssize_t *step, Py_ssize_t *slicelength); + static PyObject* (*py3_PyErr_NoMemory)(void); +--- 277,283 ---- + static Py_ssize_t (*py3_PyTuple_Size)(PyObject *); + static PyObject* (*py3_PyTuple_GetItem)(PyObject *, Py_ssize_t); + static int (*py3_PyMapping_Check)(PyObject *); +! static PyObject* (*py3_PyMapping_Keys)(PyObject *); + static int (*py3_PySlice_GetIndicesEx)(PyObject *r, Py_ssize_t length, + Py_ssize_t *start, Py_ssize_t *stop, Py_ssize_t *step, Py_ssize_t *slicelength); + static PyObject* (*py3_PyErr_NoMemory)(void); +*************** +*** 304,309 **** +--- 305,311 ---- + static PyObject* (*py3_PyDict_New)(void); + static PyObject* (*py3_PyIter_Next)(PyObject *); + static PyObject* (*py3_PyObject_GetIter)(PyObject *); ++ static PyObject* (*py3_PyObject_GetItem)(PyObject *, PyObject *); + static int (*py3_PyObject_IsTrue)(PyObject *); + static PyObject* (*py3_Py_BuildValue)(char *, ...); + static int (*py3_PyType_Ready)(PyTypeObject *type); +*************** +*** 456,464 **** + {"PyDict_GetItemString", (PYTHON_PROC*)&py3_PyDict_GetItemString}, + {"PyDict_Next", (PYTHON_PROC*)&py3_PyDict_Next}, + {"PyMapping_Check", (PYTHON_PROC*)&py3_PyMapping_Check}, +! {"PyMapping_Items", (PYTHON_PROC*)&py3_PyMapping_Items}, + {"PyIter_Next", (PYTHON_PROC*)&py3_PyIter_Next}, + {"PyObject_GetIter", (PYTHON_PROC*)&py3_PyObject_GetIter}, + {"PyObject_IsTrue", (PYTHON_PROC*)&py3_PyObject_IsTrue}, + {"PyLong_FromLong", (PYTHON_PROC*)&py3_PyLong_FromLong}, + {"PyDict_New", (PYTHON_PROC*)&py3_PyDict_New}, +--- 458,467 ---- + {"PyDict_GetItemString", (PYTHON_PROC*)&py3_PyDict_GetItemString}, + {"PyDict_Next", (PYTHON_PROC*)&py3_PyDict_Next}, + {"PyMapping_Check", (PYTHON_PROC*)&py3_PyMapping_Check}, +! {"PyMapping_Keys", (PYTHON_PROC*)&py3_PyMapping_Keys}, + {"PyIter_Next", (PYTHON_PROC*)&py3_PyIter_Next}, + {"PyObject_GetIter", (PYTHON_PROC*)&py3_PyObject_GetIter}, ++ {"PyObject_GetItem", (PYTHON_PROC*)&py3_PyObject_GetItem}, + {"PyObject_IsTrue", (PYTHON_PROC*)&py3_PyObject_IsTrue}, + {"PyLong_FromLong", (PYTHON_PROC*)&py3_PyLong_FromLong}, + {"PyDict_New", (PYTHON_PROC*)&py3_PyDict_New}, +*** ../vim-7.3.1064/src/if_python.c 2013-05-30 13:01:14.000000000 +0200 +--- src/if_python.c 2013-05-30 13:19:50.000000000 +0200 +*************** +*** 197,207 **** + # define PyDict_GetItemString dll_PyDict_GetItemString + # define PyDict_Next dll_PyDict_Next + # define PyDict_Type (*dll_PyDict_Type) +! # ifdef PyMapping_Items +! # define PY_NO_MAPPING_ITEMS + # else +! # define PyMapping_Items dll_PyMapping_Items + # endif + # define PyObject_CallMethod dll_PyObject_CallMethod + # define PyMapping_Check dll_PyMapping_Check + # define PyIter_Next dll_PyIter_Next +--- 197,208 ---- + # define PyDict_GetItemString dll_PyDict_GetItemString + # define PyDict_Next dll_PyDict_Next + # define PyDict_Type (*dll_PyDict_Type) +! # ifdef PyMapping_Keys +! # define PY_NO_MAPPING_KEYS + # else +! # define PyMapping_Keys dll_PyMapping_Keys + # endif ++ # define PyObject_GetItem dll_PyObject_GetItem + # define PyObject_CallMethod dll_PyObject_CallMethod + # define PyMapping_Check dll_PyMapping_Check + # define PyIter_Next dll_PyIter_Next +*************** +*** 331,339 **** + static PyObject*(*dll_PyDict_GetItemString)(PyObject *, const char *); + static int (*dll_PyDict_Next)(PyObject *, PyInt *, PyObject **, PyObject **); + static PyTypeObject* dll_PyDict_Type; +! # ifndef PY_NO_MAPPING_ITEMS +! static PyObject* (*dll_PyMapping_Items)(PyObject *); + # endif + static PyObject* (*dll_PyObject_CallMethod)(PyObject *, char *, PyObject *); + static int (*dll_PyMapping_Check)(PyObject *); + static PyObject* (*dll_PyIter_Next)(PyObject *); +--- 332,341 ---- + static PyObject*(*dll_PyDict_GetItemString)(PyObject *, const char *); + static int (*dll_PyDict_Next)(PyObject *, PyInt *, PyObject **, PyObject **); + static PyTypeObject* dll_PyDict_Type; +! # ifndef PY_NO_MAPPING_KEYS +! static PyObject* (*dll_PyMapping_Keys)(PyObject *); + # endif ++ static PyObject* (*dll_PyObject_GetItem)(PyObject *, PyObject *); + static PyObject* (*dll_PyObject_CallMethod)(PyObject *, char *, PyObject *); + static int (*dll_PyMapping_Check)(PyObject *); + static PyObject* (*dll_PyIter_Next)(PyObject *); +*************** +*** 494,502 **** + {"PyDict_Next", (PYTHON_PROC*)&dll_PyDict_Next}, + {"PyDict_New", (PYTHON_PROC*)&dll_PyDict_New}, + {"PyDict_Type", (PYTHON_PROC*)&dll_PyDict_Type}, +! # ifndef PY_NO_MAPPING_ITEMS +! {"PyMapping_Items", (PYTHON_PROC*)&dll_PyMapping_Items}, + # endif + {"PyObject_CallMethod", (PYTHON_PROC*)&dll_PyObject_CallMethod}, + {"PyMapping_Check", (PYTHON_PROC*)&dll_PyMapping_Check}, + {"PyIter_Next", (PYTHON_PROC*)&dll_PyIter_Next}, +--- 496,505 ---- + {"PyDict_Next", (PYTHON_PROC*)&dll_PyDict_Next}, + {"PyDict_New", (PYTHON_PROC*)&dll_PyDict_New}, + {"PyDict_Type", (PYTHON_PROC*)&dll_PyDict_Type}, +! # ifndef PY_NO_MAPPING_KEYS +! {"PyMapping_Keys", (PYTHON_PROC*)&dll_PyMapping_Keys}, + # endif ++ {"PyObject_GetItem", (PYTHON_PROC*)&dll_PyObject_GetItem}, + {"PyObject_CallMethod", (PYTHON_PROC*)&dll_PyObject_CallMethod}, + {"PyMapping_Check", (PYTHON_PROC*)&dll_PyMapping_Check}, + {"PyIter_Next", (PYTHON_PROC*)&dll_PyIter_Next}, +*** ../vim-7.3.1064/src/version.c 2013-05-30 13:17:13.000000000 +0200 +--- src/version.c 2013-05-30 13:19:32.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1065, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +8. Don't use any punctuation marks. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7160125927c49d0faf0c8eafc23254f390ff73aa Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:33 +0200 Subject: [PATCH 0957/3340] - patchlevel 1066 --- 7.3.1066 | 1979 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1979 insertions(+) create mode 100644 7.3.1066 diff --git a/7.3.1066 b/7.3.1066 new file mode 100644 index 00000000..8bb89b50 --- /dev/null +++ b/7.3.1066 @@ -0,0 +1,1979 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1066 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1066 +Problem: Python: Insufficient exception and error testing. +Solution: Python patch 25. (ZyX) +Files: src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.1065/src/testdir/test86.in 2013-05-30 13:14:06.000000000 +0200 +--- src/testdir/test86.in 2013-05-30 13:25:22.000000000 +0200 +*************** +*** 7,12 **** +--- 7,13 ---- + + STARTTEST + :so small.vim ++ :set encoding=latin1 + :if !has('python') | e! test.ok | wq! test.out | endif + :lang C + :py import vim +*************** +*** 785,800 **** + :$put =string(pyeval('dl2')) + :$put =string(pyeval('df(2)')) + :" +! :" Test exceptions +! :fun Exe(e) +! : execute a:e + :endfun + py << EOF + def ee(expr, g=globals(), l=locals()): + try: + exec(expr, g, l) + except: +! cb.append(repr(sys.exc_info()[:2])) + Exe = vim.bindeval('function("Exe")') + ee('vim.command("throw \'abc\'")') + ee('Exe("throw \'def\'")') +--- 786,1062 ---- + :$put =string(pyeval('dl2')) + :$put =string(pyeval('df(2)')) + :" +! :" Test errors +! :fun F() dict +! :endfun +! :fun D() + :endfun + py << EOF + def ee(expr, g=globals(), l=locals()): + try: + exec(expr, g, l) + except: +! cb.append(expr + ':' + repr(sys.exc_info()[:2])) +! else: +! cb.append(expr + ':NOT FAILED') +! d = vim.Dictionary() +! ned = vim.Dictionary(foo='bar', baz='abc') +! dl = vim.Dictionary(a=1) +! dl.locked = True +! l = vim.List() +! ll = vim.List('abc') +! ll.locked = True +! f = vim.Function('string') +! fd = vim.Function('F') +! fdel = vim.Function('D') +! vim.command('delfunction D') +! +! def subexpr_test(expr, name, subexprs): +! cb.append('>>> Testing %s using %s' % (name, expr)) +! for subexpr in subexprs: +! ee(expr % subexpr) +! cb.append('<<< Finished') +! +! def stringtochars_test(expr): +! return subexpr_test(expr, 'StringToChars', ( +! '1', # Fail type checks +! 'u"\\0"', # Fail PyString_AsStringAndSize(bytes, , NULL) check +! '"\\0"', # Fail PyString_AsStringAndSize(object, , NULL) check +! )) +! +! class Mapping(object): +! def __init__(self, d): +! self.d = d +! +! def __getitem__(self, key): +! return self.d[key] +! +! def keys(self): +! return self.d.keys() +! +! def items(self): +! return self.d.items() +! +! def convertfrompyobject_test(expr, recurse=True): +! # pydict_to_tv +! stringtochars_test(expr % '{%s : 1}') +! if recurse: +! convertfrompyobject_test(expr % '{"abc" : %s}', False) +! # pymap_to_tv +! stringtochars_test(expr % 'Mapping({%s : 1})') +! if recurse: +! convertfrompyobject_test(expr % 'Mapping({"abc" : %s})', False) +! # pyseq_to_tv +! iter_test(expr) +! return subexpr_test(expr, 'ConvertFromPyObject', ( +! 'None', # Not conversible +! '{"": 1}', # Empty key not allowed +! 'FailingMapping()', # +! 'FailingMappingKey()', # +! )) +! +! def convertfrompymapping_test(expr): +! convertfrompyobject_test(expr) +! return subexpr_test(expr, 'ConvertFromPyMapping', ( +! '[]', +! )) +! +! def iter_test(expr): +! return subexpr_test(expr, '*Iter*', ( +! 'FailingIter()', +! 'FailingIterNext()', +! )) +! +! class FailingTrue(object): +! def __nonzero__(self): +! raise NotImplementedError +! +! class FailingIter(object): +! def __iter__(self): +! raise NotImplementedError +! +! class FailingIterNext(object): +! def __iter__(self): +! return self +! +! def next(self): +! raise NotImplementedError +! +! class FailingMappingKey(object): +! def __getitem__(self, item): +! raise NotImplementedError +! +! def keys(self): +! return list("abc") +! +! class FailingMapping(object): +! def __getitem__(self): +! raise NotImplementedError +! +! def keys(self): +! raise NotImplementedError +! +! class FailingList(list): +! def __getitem__(self, idx): +! if i == 2: +! raise NotImplementedError +! else: +! return super(FailingList, self).__getitem__(idx) +! +! cb.append("> Output") +! cb.append(">> OutputSetattr") +! ee('del sys.stdout.softspace') +! ee('sys.stdout.softspace = []') +! ee('sys.stdout.attr = None') +! cb.append(">> OutputWrite") +! ee('sys.stdout.write(None)') +! cb.append(">> OutputWriteLines") +! ee('sys.stdout.writelines(None)') +! ee('sys.stdout.writelines([1])') +! iter_test('sys.stdout.writelines(%s)') +! cb.append("> VimCommand") +! ee('vim.command(1)') +! #! Not checked: vim->python exceptions translating: checked later +! cb.append("> VimToPython") +! #! Not checked: everything: needs errors in internal python functions +! cb.append("> VimEval") +! ee('vim.eval(1)') +! #! Not checked: everything: needs errors in internal python functions +! cb.append("> VimEvalPy") +! ee('vim.bindeval(1)') +! #! Not checked: vim->python exceptions translating: checked later +! cb.append("> VimStrwidth") +! ee('vim.strwidth(1)') +! cb.append("> Dictionary") +! cb.append(">> DictionaryConstructor") +! ee('vim.Dictionary("abc")') +! ##! Not checked: py_dict_alloc failure +! cb.append(">> DictionarySetattr") +! ee('del d.locked') +! ee('d.locked = FailingTrue()') +! ee('vim.vvars.locked = False') +! ee('d.scope = True') +! ee('d.xxx = True') +! cb.append(">> _DictionaryItem") +! ee('d.get("a", 2, 3)') +! stringtochars_test('d.get(%s)') +! ee('d.pop("a")') +! ee('dl.pop("a")') +! cb.append(">> DictionaryIterNext") +! ee('for i in ned: ned["a"] = 1') +! cb.append(">> DictionaryAssItem") +! ee('dl["b"] = 1') +! stringtochars_test('d[%s] = 1') +! convertfrompyobject_test('d["a"] = %s') +! cb.append(">> DictionaryUpdate") +! cb.append(">>> kwargs") +! cb.append(">>> iter") +! ee('d.update(FailingMapping())') +! ee('d.update([FailingIterNext()])') +! iter_test('d.update(%s)') +! convertfrompyobject_test('d.update(%s)') +! stringtochars_test('d.update(((%s, 0),))') +! convertfrompyobject_test('d.update((("a", %s),))') +! cb.append(">> DictionaryPopItem") +! ee('d.popitem(1, 2)') +! cb.append(">> DictionaryHasKey") +! ee('d.has_key()') +! cb.append("> List") +! cb.append(">> ListConstructor") +! ee('vim.List(1, 2)') +! ee('vim.List(a=1)') +! iter_test('vim.List(%s)') +! convertfrompyobject_test('vim.List([%s])') +! cb.append(">> ListItem") +! ee('l[1000]') +! cb.append(">> ListAssItem") +! ee('ll[1] = 2') +! ee('l[1000] = 3') +! cb.append(">> ListAssSlice") +! ee('ll[1:100] = "abc"') +! iter_test('l[:] = %s') +! convertfrompyobject_test('l[:] = [%s]') +! cb.append(">> ListConcatInPlace") +! iter_test('l.extend(%s)') +! convertfrompyobject_test('l.extend([%s])') +! cb.append(">> ListSetattr") +! ee('del l.locked') +! ee('l.locked = FailingTrue()') +! ee('l.xxx = True') +! cb.append("> Function") +! cb.append(">> FunctionConstructor") +! ee('vim.Function("123")') +! ee('vim.Function("xxx_non_existent_function_xxx")') +! ee('vim.Function("xxx#non#existent#function#xxx")') +! cb.append(">> FunctionCall") +! convertfrompyobject_test('f(%s)') +! convertfrompymapping_test('fd(self=%s)') +! cb.append("> TabPage") +! cb.append(">> TabPageAttr") +! ee('vim.current.tabpage.xxx') +! cb.append("> TabList") +! cb.append(">> TabListItem") +! ee('vim.tabpages[1000]') +! cb.append("> Window") +! cb.append(">> WindowAttr") +! ee('vim.current.window.xxx') +! cb.append(">> WindowSetattr") +! ee('vim.current.window.buffer = 0') +! ee('vim.current.window.cursor = (10000000000, 100000000)') +! ee('vim.current.window.cursor = True') +! ee('vim.current.window.height = "abc"') +! ee('vim.current.window.width = "abc"') +! ee('vim.current.window.xxxxxx = True') +! cb.append("> WinList") +! cb.append(">> WinListItem") +! ee('vim.windows[1000]') +! cb.append("> Buffer") +! cb.append(">> StringToLine (indirect)") +! ee('vim.current.buffer[0] = "\\na"') +! cb.append(">> SetBufferLine (indirect)") +! ee('vim.current.buffer[0] = True') +! cb.append(">> SetBufferLines (indirect)") +! ee('vim.current.buffer[:] = True') +! ee('vim.current.buffer[:] = ["\\na", "bc"]') +! cb.append(">> InsertBufferLines (indirect)") +! ee('vim.current.buffer.append(None)') +! ee('vim.current.buffer.append(["\\na", "bc"])') +! ee('vim.current.buffer.append("\\nbc")') +! cb.append(">> RBItem") +! ee('vim.current.buffer[10000000000]') +! cb.append(">> RBAsItem") +! ee('vim.current.buffer[10000000000] = ""') +! cb.append(">> BufferAttr") +! ee('vim.current.buffer.xxx') +! cb.append(">> BufferSetattr") +! ee('vim.current.buffer.name = True') +! ee('vim.current.buffer.xxx = True') +! cb.append(">> BufferMark") +! ee('vim.current.buffer.mark(0)') +! ee('vim.current.buffer.mark("abc")') +! ee('vim.current.buffer.mark("!")') +! cb.append(">> BufferRange") +! ee('vim.current.buffer.range(1, 2, 3)') +! cb.append("> BufMap") +! cb.append(">> BufMapItem") +! ee('vim.buffers[None]') +! ee('vim.buffers[100000000]') +! cb.append("> Current") +! cb.append(">> CurrentGetattr") +! ee('vim.current.xxx') +! cb.append(">> CurrentSetattr") +! ee('vim.current.line = True') +! ee('vim.current.buffer = True') +! ee('vim.current.window = True') +! ee('vim.current.tabpage = True') +! ee('vim.current.xxx = True') +! EOF +! :" +! :" Test exceptions +! :fun Exe(e) +! : execute a:e +! :endfun +! py << EOF + Exe = vim.bindeval('function("Exe")') + ee('vim.command("throw \'abc\'")') + ee('Exe("throw \'def\'")') +*** ../vim-7.3.1065/src/testdir/test86.ok 2013-05-30 13:14:06.000000000 +0200 +--- src/testdir/test86.ok 2013-05-30 13:25:22.000000000 +0200 +*************** +*** 429,437 **** + ['a', 'b', 'c'] + [2, 2] + [2, 2] +! (, error('abc',)) +! (, error('def',)) +! (, error('ghi',)) +! (, error('Vim(echoerr):jkl',)) +! (, error('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',)) +! (, error('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',)) +--- 429,1081 ---- + ['a', 'b', 'c'] + [2, 2] + [2, 2] +! > Output +! >> OutputSetattr +! del sys.stdout.softspace:(, AttributeError("can't delete OutputObject attributes",)) +! sys.stdout.softspace = []:(, TypeError('softspace must be an integer',)) +! sys.stdout.attr = None:(, AttributeError('invalid attribute',)) +! >> OutputWrite +! sys.stdout.write(None):(, TypeError('coercing to Unicode: need string or buffer, NoneType found',)) +! >> OutputWriteLines +! sys.stdout.writelines(None):(, TypeError("'NoneType' object is not iterable",)) +! sys.stdout.writelines([1]):(, TypeError('writelines() requires list of strings',)) +! >>> Testing *Iter* using sys.stdout.writelines(%s) +! sys.stdout.writelines(FailingIter()):(, NotImplementedError()) +! sys.stdout.writelines(FailingIterNext()):(, NotImplementedError()) +! <<< Finished +! > VimCommand +! vim.command(1):(, TypeError('must be string, not int',)) +! > VimToPython +! > VimEval +! vim.eval(1):(, TypeError('must be string, not int',)) +! > VimEvalPy +! vim.bindeval(1):(, TypeError('must be string, not int',)) +! > VimStrwidth +! vim.strwidth(1):(, TypeError('must be string, not int',)) +! > Dictionary +! >> DictionaryConstructor +! vim.Dictionary("abc"):(, ValueError('expected sequence element of size 2',)) +! >> DictionarySetattr +! del d.locked:(, AttributeError('cannot delete vim.Dictionary attributes',)) +! d.locked = FailingTrue():(, NotImplementedError()) +! vim.vvars.locked = False:(, TypeError('cannot modify fixed dictionary',)) +! d.scope = True:(, AttributeError('cannot set this attribute',)) +! d.xxx = True:(, AttributeError('cannot set this attribute',)) +! >> _DictionaryItem +! d.get("a", 2, 3):(, TypeError('function takes at most 2 arguments (3 given)',)) +! >>> Testing StringToChars using d.get(%s) +! d.get(1):(, TypeError('object must be string',)) +! d.get(u"\0"):(, TypeError('expected string without null bytes',)) +! d.get("\0"):(, TypeError('expected string without null bytes',)) +! <<< Finished +! d.pop("a"):(, KeyError('a',)) +! dl.pop("a"):(, error('dict is locked',)) +! >> DictionaryIterNext +! for i in ned: ned["a"] = 1:(, RuntimeError('hashtab changed during iteration',)) +! >> DictionaryAssItem +! dl["b"] = 1:(, error('dict is locked',)) +! >>> Testing StringToChars using d[%s] = 1 +! d[1] = 1:(, TypeError('object must be string',)) +! d[u"\0"] = 1:(, TypeError('expected string without null bytes',)) +! d["\0"] = 1:(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using d["a"] = {%s : 1} +! d["a"] = {1 : 1}:(, TypeError('object must be string',)) +! d["a"] = {u"\0" : 1}:(, TypeError('expected string without null bytes',)) +! d["a"] = {"\0" : 1}:(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using d["a"] = {"abc" : {%s : 1}} +! d["a"] = {"abc" : {1 : 1}}:(, TypeError('object must be string',)) +! d["a"] = {"abc" : {u"\0" : 1}}:(, TypeError('expected string without null bytes',)) +! d["a"] = {"abc" : {"\0" : 1}}:(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using d["a"] = {"abc" : Mapping({%s : 1})} +! d["a"] = {"abc" : Mapping({1 : 1})}:(, TypeError('object must be string',)) +! d["a"] = {"abc" : Mapping({u"\0" : 1})}:(, TypeError('expected string without null bytes',)) +! d["a"] = {"abc" : Mapping({"\0" : 1})}:(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : FailingIter()}:(, TypeError('unable to convert to vim structure',)) +! d["a"] = {"abc" : FailingIterNext()}:(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : None}:(, TypeError('unable to convert to vim structure',)) +! d["a"] = {"abc" : {"": 1}}:(, ValueError('empty keys are not allowed',)) +! d["a"] = {"abc" : FailingMapping()}:(, NotImplementedError()) +! d["a"] = {"abc" : FailingMappingKey()}:(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) +! d["a"] = Mapping({1 : 1}):(, TypeError('object must be string',)) +! d["a"] = Mapping({u"\0" : 1}):(, TypeError('expected string without null bytes',)) +! d["a"] = Mapping({"\0" : 1}):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using d["a"] = Mapping({"abc" : {%s : 1}}) +! d["a"] = Mapping({"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! d["a"] = Mapping({"abc" : {u"\0" : 1}}):(, TypeError('expected string without null bytes',)) +! d["a"] = Mapping({"abc" : {"\0" : 1}}):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using d["a"] = Mapping({"abc" : Mapping({%s : 1})}) +! d["a"] = Mapping({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! d["a"] = Mapping({"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected string without null bytes',)) +! d["a"] = Mapping({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) +! d["a"] = Mapping({"abc" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : None}):(, TypeError('unable to convert to vim structure',)) +! d["a"] = Mapping({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! d["a"] = Mapping({"abc" : FailingMapping()}):(, NotImplementedError()) +! d["a"] = Mapping({"abc" : FailingMappingKey()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using d["a"] = %s +! d["a"] = FailingIter():(, TypeError('unable to convert to vim structure',)) +! d["a"] = FailingIterNext():(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d["a"] = %s +! d["a"] = None:(, TypeError('unable to convert to vim structure',)) +! d["a"] = {"": 1}:(, ValueError('empty keys are not allowed',)) +! d["a"] = FailingMapping():(, NotImplementedError()) +! d["a"] = FailingMappingKey():(, NotImplementedError()) +! <<< Finished +! >> DictionaryUpdate +! >>> kwargs +! >>> iter +! d.update(FailingMapping()):(, NotImplementedError()) +! d.update([FailingIterNext()]):(, NotImplementedError()) +! >>> Testing *Iter* using d.update(%s) +! d.update(FailingIter()):(, NotImplementedError()) +! d.update(FailingIterNext()):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using d.update({%s : 1}) +! d.update({1 : 1}):(, TypeError('object must be string',)) +! d.update({u"\0" : 1}):(, TypeError('expected string without null bytes',)) +! d.update({"\0" : 1}):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using d.update({"abc" : {%s : 1}}) +! d.update({"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! d.update({"abc" : {u"\0" : 1}}):(, TypeError('expected string without null bytes',)) +! d.update({"abc" : {"\0" : 1}}):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using d.update({"abc" : Mapping({%s : 1})}) +! d.update({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! d.update({"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected string without null bytes',)) +! d.update({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using d.update({"abc" : %s}) +! d.update({"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) +! d.update({"abc" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update({"abc" : %s}) +! d.update({"abc" : None}):(, TypeError('unable to convert to vim structure',)) +! d.update({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! d.update({"abc" : FailingMapping()}):(, NotImplementedError()) +! d.update({"abc" : FailingMappingKey()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using d.update(Mapping({%s : 1})) +! d.update(Mapping({1 : 1})):(, TypeError('object must be string',)) +! d.update(Mapping({u"\0" : 1})):(, TypeError('expected string without null bytes',)) +! d.update(Mapping({"\0" : 1})):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using d.update(Mapping({"abc" : {%s : 1}})) +! d.update(Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) +! d.update(Mapping({"abc" : {u"\0" : 1}})):(, TypeError('expected string without null bytes',)) +! d.update(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using d.update(Mapping({"abc" : Mapping({%s : 1})})) +! d.update(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) +! d.update(Mapping({"abc" : Mapping({u"\0" : 1})})):(, TypeError('expected string without null bytes',)) +! d.update(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert to vim structure',)) +! d.update(Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) +! d.update(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! d.update(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) +! d.update(Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using d.update(%s) +! d.update(FailingIter()):(, NotImplementedError()) +! d.update(FailingIterNext()):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update(%s) +! d.update(None):(, TypeError("'NoneType' object is not iterable",)) +! d.update({"": 1}):(, ValueError('empty keys are not allowed',)) +! d.update(FailingMapping()):(, NotImplementedError()) +! d.update(FailingMappingKey()):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using d.update(((%s, 0),)) +! d.update(((1, 0),)):(, TypeError('object must be string',)) +! d.update(((u"\0", 0),)):(, TypeError('expected string without null bytes',)) +! d.update((("\0", 0),)):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", {%s : 1}),)) +! d.update((("a", {1 : 1}),)):(, TypeError('object must be string',)) +! d.update((("a", {u"\0" : 1}),)):(, TypeError('expected string without null bytes',)) +! d.update((("a", {"\0" : 1}),)):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", {"abc" : {%s : 1}}),)) +! d.update((("a", {"abc" : {1 : 1}}),)):(, TypeError('object must be string',)) +! d.update((("a", {"abc" : {u"\0" : 1}}),)):(, TypeError('expected string without null bytes',)) +! d.update((("a", {"abc" : {"\0" : 1}}),)):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", {"abc" : Mapping({%s : 1})}),)) +! d.update((("a", {"abc" : Mapping({1 : 1})}),)):(, TypeError('object must be string',)) +! d.update((("a", {"abc" : Mapping({u"\0" : 1})}),)):(, TypeError('expected string without null bytes',)) +! d.update((("a", {"abc" : Mapping({"\0" : 1})}),)):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : FailingIter()}),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", {"abc" : FailingIterNext()}),)):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : None}),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", {"abc" : {"": 1}}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", {"abc" : FailingMapping()}),)):(, NotImplementedError()) +! d.update((("a", {"abc" : FailingMappingKey()}),)):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) +! d.update((("a", Mapping({1 : 1})),)):(, TypeError('object must be string',)) +! d.update((("a", Mapping({u"\0" : 1})),)):(, TypeError('expected string without null bytes',)) +! d.update((("a", Mapping({"\0" : 1})),)):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", Mapping({"abc" : {%s : 1}})),)) +! d.update((("a", Mapping({"abc" : {1 : 1}})),)):(, TypeError('object must be string',)) +! d.update((("a", Mapping({"abc" : {u"\0" : 1}})),)):(, TypeError('expected string without null bytes',)) +! d.update((("a", Mapping({"abc" : {"\0" : 1}})),)):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", Mapping({"abc" : Mapping({%s : 1})})),)) +! d.update((("a", Mapping({"abc" : Mapping({1 : 1})})),)):(, TypeError('object must be string',)) +! d.update((("a", Mapping({"abc" : Mapping({u"\0" : 1})})),)):(, TypeError('expected string without null bytes',)) +! d.update((("a", Mapping({"abc" : Mapping({"\0" : 1})})),)):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : FailingIter()})),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", Mapping({"abc" : FailingIterNext()})),)):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : None})),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", Mapping({"abc" : {"": 1}})),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", Mapping({"abc" : FailingMapping()})),)):(, NotImplementedError()) +! d.update((("a", Mapping({"abc" : FailingMappingKey()})),)):(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using d.update((("a", %s),)) +! d.update((("a", FailingIter()),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", FailingIterNext()),)):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update((("a", %s),)) +! d.update((("a", None),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", {"": 1}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", FailingMapping()),)):(, NotImplementedError()) +! d.update((("a", FailingMappingKey()),)):(, NotImplementedError()) +! <<< Finished +! >> DictionaryPopItem +! d.popitem(1, 2):(, TypeError('function takes exactly 1 argument (2 given)',)) +! >> DictionaryHasKey +! d.has_key():(, TypeError('function takes exactly 1 argument (0 given)',)) +! > List +! >> ListConstructor +! vim.List(1, 2):(, TypeError('function takes at most 1 argument (2 given)',)) +! vim.List(a=1):(, TypeError('list constructor does not accept keyword arguments',)) +! >>> Testing *Iter* using vim.List(%s) +! vim.List(FailingIter()):(, NotImplementedError()) +! vim.List(FailingIterNext()):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using vim.List([{%s : 1}]) +! vim.List([{1 : 1}]):(, TypeError('object must be string',)) +! vim.List([{u"\0" : 1}]):(, TypeError('expected string without null bytes',)) +! vim.List([{"\0" : 1}]):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using vim.List([{"abc" : {%s : 1}}]) +! vim.List([{"abc" : {1 : 1}}]):(, TypeError('object must be string',)) +! vim.List([{"abc" : {u"\0" : 1}}]):(, TypeError('expected string without null bytes',)) +! vim.List([{"abc" : {"\0" : 1}}]):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using vim.List([{"abc" : Mapping({%s : 1})}]) +! vim.List([{"abc" : Mapping({1 : 1})}]):(, TypeError('object must be string',)) +! vim.List([{"abc" : Mapping({u"\0" : 1})}]):(, TypeError('expected string without null bytes',)) +! vim.List([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : FailingIter()}]):(, TypeError('unable to convert to vim structure',)) +! vim.List([{"abc" : FailingIterNext()}]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : None}]):(, TypeError('unable to convert to vim structure',)) +! vim.List([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) +! vim.List([{"abc" : FailingMapping()}]):(, NotImplementedError()) +! vim.List([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) +! vim.List([Mapping({1 : 1})]):(, TypeError('object must be string',)) +! vim.List([Mapping({u"\0" : 1})]):(, TypeError('expected string without null bytes',)) +! vim.List([Mapping({"\0" : 1})]):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using vim.List([Mapping({"abc" : {%s : 1}})]) +! vim.List([Mapping({"abc" : {1 : 1}})]):(, TypeError('object must be string',)) +! vim.List([Mapping({"abc" : {u"\0" : 1}})]):(, TypeError('expected string without null bytes',)) +! vim.List([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using vim.List([Mapping({"abc" : Mapping({%s : 1})})]) +! vim.List([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('object must be string',)) +! vim.List([Mapping({"abc" : Mapping({u"\0" : 1})})]):(, TypeError('expected string without null bytes',)) +! vim.List([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : FailingIter()})]):(, TypeError('unable to convert to vim structure',)) +! vim.List([Mapping({"abc" : FailingIterNext()})]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : None})]):(, TypeError('unable to convert to vim structure',)) +! vim.List([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) +! vim.List([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) +! vim.List([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using vim.List([%s]) +! vim.List([FailingIter()]):(, TypeError('unable to convert to vim structure',)) +! vim.List([FailingIterNext()]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using vim.List([%s]) +! vim.List([None]):(, TypeError('unable to convert to vim structure',)) +! vim.List([{"": 1}]):(, ValueError('empty keys are not allowed',)) +! vim.List([FailingMapping()]):(, NotImplementedError()) +! vim.List([FailingMappingKey()]):(, NotImplementedError()) +! <<< Finished +! >> ListItem +! l[1000]:(, IndexError('list index out of range',)) +! >> ListAssItem +! ll[1] = 2:(, error('list is locked',)) +! l[1000] = 3:(, IndexError('list index out of range',)) +! >> ListAssSlice +! ll[1:100] = "abc":(, error('list is locked',)) +! >>> Testing *Iter* using l[:] = %s +! l[:] = FailingIter():(, NotImplementedError()) +! l[:] = FailingIterNext():(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using l[:] = [{%s : 1}] +! l[:] = [{1 : 1}]:(, TypeError('object must be string',)) +! l[:] = [{u"\0" : 1}]:(, TypeError('expected string without null bytes',)) +! l[:] = [{"\0" : 1}]:(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using l[:] = [{"abc" : {%s : 1}}] +! l[:] = [{"abc" : {1 : 1}}]:(, TypeError('object must be string',)) +! l[:] = [{"abc" : {u"\0" : 1}}]:(, TypeError('expected string without null bytes',)) +! l[:] = [{"abc" : {"\0" : 1}}]:(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using l[:] = [{"abc" : Mapping({%s : 1})}] +! l[:] = [{"abc" : Mapping({1 : 1})}]:(, TypeError('object must be string',)) +! l[:] = [{"abc" : Mapping({u"\0" : 1})}]:(, TypeError('expected string without null bytes',)) +! l[:] = [{"abc" : Mapping({"\0" : 1})}]:(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : FailingIter()}]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [{"abc" : FailingIterNext()}]:(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : None}]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [{"abc" : {"": 1}}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [{"abc" : FailingMapping()}]:(, NotImplementedError()) +! l[:] = [{"abc" : FailingMappingKey()}]:(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] +! l[:] = [Mapping({1 : 1})]:(, TypeError('object must be string',)) +! l[:] = [Mapping({u"\0" : 1})]:(, TypeError('expected string without null bytes',)) +! l[:] = [Mapping({"\0" : 1})]:(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using l[:] = [Mapping({"abc" : {%s : 1}})] +! l[:] = [Mapping({"abc" : {1 : 1}})]:(, TypeError('object must be string',)) +! l[:] = [Mapping({"abc" : {u"\0" : 1}})]:(, TypeError('expected string without null bytes',)) +! l[:] = [Mapping({"abc" : {"\0" : 1}})]:(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using l[:] = [Mapping({"abc" : Mapping({%s : 1})})] +! l[:] = [Mapping({"abc" : Mapping({1 : 1})})]:(, TypeError('object must be string',)) +! l[:] = [Mapping({"abc" : Mapping({u"\0" : 1})})]:(, TypeError('expected string without null bytes',)) +! l[:] = [Mapping({"abc" : Mapping({"\0" : 1})})]:(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : FailingIter()})]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [Mapping({"abc" : FailingIterNext()})]:(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : None})]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [Mapping({"abc" : {"": 1}})]:(, ValueError('empty keys are not allowed',)) +! l[:] = [Mapping({"abc" : FailingMapping()})]:(, NotImplementedError()) +! l[:] = [Mapping({"abc" : FailingMappingKey()})]:(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using l[:] = [%s] +! l[:] = [FailingIter()]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [FailingIterNext()]:(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l[:] = [%s] +! l[:] = [None]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [{"": 1}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [FailingMapping()]:(, NotImplementedError()) +! l[:] = [FailingMappingKey()]:(, NotImplementedError()) +! <<< Finished +! >> ListConcatInPlace +! >>> Testing *Iter* using l.extend(%s) +! l.extend(FailingIter()):(, NotImplementedError()) +! l.extend(FailingIterNext()):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using l.extend([{%s : 1}]) +! l.extend([{1 : 1}]):(, TypeError('object must be string',)) +! l.extend([{u"\0" : 1}]):(, TypeError('expected string without null bytes',)) +! l.extend([{"\0" : 1}]):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using l.extend([{"abc" : {%s : 1}}]) +! l.extend([{"abc" : {1 : 1}}]):(, TypeError('object must be string',)) +! l.extend([{"abc" : {u"\0" : 1}}]):(, TypeError('expected string without null bytes',)) +! l.extend([{"abc" : {"\0" : 1}}]):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using l.extend([{"abc" : Mapping({%s : 1})}]) +! l.extend([{"abc" : Mapping({1 : 1})}]):(, TypeError('object must be string',)) +! l.extend([{"abc" : Mapping({u"\0" : 1})}]):(, TypeError('expected string without null bytes',)) +! l.extend([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : FailingIter()}]):(, TypeError('unable to convert to vim structure',)) +! l.extend([{"abc" : FailingIterNext()}]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : None}]):(, TypeError('unable to convert to vim structure',)) +! l.extend([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) +! l.extend([{"abc" : FailingMapping()}]):(, NotImplementedError()) +! l.extend([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) +! l.extend([Mapping({1 : 1})]):(, TypeError('object must be string',)) +! l.extend([Mapping({u"\0" : 1})]):(, TypeError('expected string without null bytes',)) +! l.extend([Mapping({"\0" : 1})]):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using l.extend([Mapping({"abc" : {%s : 1}})]) +! l.extend([Mapping({"abc" : {1 : 1}})]):(, TypeError('object must be string',)) +! l.extend([Mapping({"abc" : {u"\0" : 1}})]):(, TypeError('expected string without null bytes',)) +! l.extend([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using l.extend([Mapping({"abc" : Mapping({%s : 1})})]) +! l.extend([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('object must be string',)) +! l.extend([Mapping({"abc" : Mapping({u"\0" : 1})})]):(, TypeError('expected string without null bytes',)) +! l.extend([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : FailingIter()})]):(, TypeError('unable to convert to vim structure',)) +! l.extend([Mapping({"abc" : FailingIterNext()})]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : None})]):(, TypeError('unable to convert to vim structure',)) +! l.extend([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) +! l.extend([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) +! l.extend([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using l.extend([%s]) +! l.extend([FailingIter()]):(, TypeError('unable to convert to vim structure',)) +! l.extend([FailingIterNext()]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l.extend([%s]) +! l.extend([None]):(, TypeError('unable to convert to vim structure',)) +! l.extend([{"": 1}]):(, ValueError('empty keys are not allowed',)) +! l.extend([FailingMapping()]):(, NotImplementedError()) +! l.extend([FailingMappingKey()]):(, NotImplementedError()) +! <<< Finished +! >> ListSetattr +! del l.locked:(, AttributeError('cannot delete vim.List attributes',)) +! l.locked = FailingTrue():(, NotImplementedError()) +! l.xxx = True:(, AttributeError('cannot set this attribute',)) +! > Function +! >> FunctionConstructor +! vim.Function("123"):(, ValueError('unnamed function does not exist',)) +! vim.Function("xxx_non_existent_function_xxx"):(, ValueError('function does not exist',)) +! vim.Function("xxx#non#existent#function#xxx"):(, ValueError('function does not exist',)) +! >> FunctionCall +! >>> Testing StringToChars using f({%s : 1}) +! f({1 : 1}):(, TypeError('object must be string',)) +! f({u"\0" : 1}):(, TypeError('expected string without null bytes',)) +! f({"\0" : 1}):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using f({"abc" : {%s : 1}}) +! f({"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! f({"abc" : {u"\0" : 1}}):(, TypeError('expected string without null bytes',)) +! f({"abc" : {"\0" : 1}}):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using f({"abc" : Mapping({%s : 1})}) +! f({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! f({"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected string without null bytes',)) +! f({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using f({"abc" : %s}) +! f({"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) +! f({"abc" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using f({"abc" : %s}) +! f({"abc" : None}):(, TypeError('unable to convert to vim structure',)) +! f({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! f({"abc" : FailingMapping()}):(, NotImplementedError()) +! f({"abc" : FailingMappingKey()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using f(Mapping({%s : 1})) +! f(Mapping({1 : 1})):(, TypeError('object must be string',)) +! f(Mapping({u"\0" : 1})):(, TypeError('expected string without null bytes',)) +! f(Mapping({"\0" : 1})):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using f(Mapping({"abc" : {%s : 1}})) +! f(Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) +! f(Mapping({"abc" : {u"\0" : 1}})):(, TypeError('expected string without null bytes',)) +! f(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using f(Mapping({"abc" : Mapping({%s : 1})})) +! f(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) +! f(Mapping({"abc" : Mapping({u"\0" : 1})})):(, TypeError('expected string without null bytes',)) +! f(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert to vim structure',)) +! f(Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) +! f(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! f(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) +! f(Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using f(%s) +! f(FailingIter()):(, TypeError('unable to convert to vim structure',)) +! f(FailingIterNext()):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using f(%s) +! f(None):(, TypeError('unable to convert to vim structure',)) +! f({"": 1}):(, ValueError('empty keys are not allowed',)) +! f(FailingMapping()):(, NotImplementedError()) +! f(FailingMappingKey()):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using fd(self={%s : 1}) +! fd(self={1 : 1}):(, TypeError('object must be string',)) +! fd(self={u"\0" : 1}):(, TypeError('expected string without null bytes',)) +! fd(self={"\0" : 1}):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using fd(self={"abc" : {%s : 1}}) +! fd(self={"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! fd(self={"abc" : {u"\0" : 1}}):(, TypeError('expected string without null bytes',)) +! fd(self={"abc" : {"\0" : 1}}):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using fd(self={"abc" : Mapping({%s : 1})}) +! fd(self={"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! fd(self={"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected string without null bytes',)) +! fd(self={"abc" : Mapping({"\0" : 1})}):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using fd(self={"abc" : %s}) +! fd(self={"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) +! fd(self={"abc" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using fd(self={"abc" : %s}) +! fd(self={"abc" : None}):(, TypeError('unable to convert to vim structure',)) +! fd(self={"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! fd(self={"abc" : FailingMapping()}):(, NotImplementedError()) +! fd(self={"abc" : FailingMappingKey()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using fd(self=Mapping({%s : 1})) +! fd(self=Mapping({1 : 1})):(, TypeError('object must be string',)) +! fd(self=Mapping({u"\0" : 1})):(, TypeError('expected string without null bytes',)) +! fd(self=Mapping({"\0" : 1})):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using fd(self=Mapping({"abc" : {%s : 1}})) +! fd(self=Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) +! fd(self=Mapping({"abc" : {u"\0" : 1}})):(, TypeError('expected string without null bytes',)) +! fd(self=Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing StringToChars using fd(self=Mapping({"abc" : Mapping({%s : 1})})) +! fd(self=Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) +! fd(self=Mapping({"abc" : Mapping({u"\0" : 1})})):(, TypeError('expected string without null bytes',)) +! fd(self=Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected string without null bytes',)) +! <<< Finished +! >>> Testing *Iter* using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert to vim structure',)) +! fd(self=Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) +! fd(self=Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! fd(self=Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) +! fd(self=Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using fd(self=%s) +! fd(self=FailingIter()):(, TypeError('unable to convert object to vim dictionary',)) +! fd(self=FailingIterNext()):(, TypeError('unable to convert object to vim dictionary',)) +! <<< Finished +! >>> Testing ConvertFromPyObject using fd(self=%s) +! fd(self=None):(, TypeError('unable to convert object to vim dictionary',)) +! fd(self={"": 1}):(, ValueError('empty keys are not allowed',)) +! fd(self=FailingMapping()):(, NotImplementedError()) +! fd(self=FailingMappingKey()):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyMapping using fd(self=%s) +! fd(self=[]):(, TypeError('unable to convert object to vim dictionary',)) +! <<< Finished +! > TabPage +! >> TabPageAttr +! vim.current.tabpage.xxx:(, AttributeError('xxx',)) +! > TabList +! >> TabListItem +! vim.tabpages[1000]:(, IndexError('no such tab page',)) +! > Window +! >> WindowAttr +! vim.current.window.xxx:(, AttributeError('xxx',)) +! >> WindowSetattr +! vim.current.window.buffer = 0:(, TypeError('readonly attribute',)) +! vim.current.window.cursor = (10000000000, 100000000):(, error('cursor position outside buffer',)) +! vim.current.window.cursor = True:(, TypeError('argument must be 2-item sequence, not bool',)) +! vim.current.window.height = "abc":(, TypeError('an integer is required',)) +! vim.current.window.width = "abc":(, TypeError('an integer is required',)) +! vim.current.window.xxxxxx = True:(, AttributeError('xxxxxx',)) +! > WinList +! >> WinListItem +! vim.windows[1000]:(, IndexError('no such window',)) +! > Buffer +! >> StringToLine (indirect) +! vim.current.buffer[0] = "\na":(, error('string cannot contain newlines',)) +! >> SetBufferLine (indirect) +! vim.current.buffer[0] = True:(, TypeError('bad argument type for built-in operation',)) +! >> SetBufferLines (indirect) +! vim.current.buffer[:] = True:(, TypeError('bad argument type for built-in operation',)) +! vim.current.buffer[:] = ["\na", "bc"]:(, error('string cannot contain newlines',)) +! >> InsertBufferLines (indirect) +! vim.current.buffer.append(None):(, TypeError('bad argument type for built-in operation',)) +! vim.current.buffer.append(["\na", "bc"]):(, error('string cannot contain newlines',)) +! vim.current.buffer.append("\nbc"):(, error('string cannot contain newlines',)) +! >> RBItem +! vim.current.buffer[10000000000]:(, IndexError('line number out of range',)) +! >> RBAsItem +! vim.current.buffer[10000000000] = "":(, IndexError('line number out of range',)) +! >> BufferAttr +! vim.current.buffer.xxx:(, AttributeError('xxx',)) +! >> BufferSetattr +! vim.current.buffer.name = True:(, TypeError('object must be string',)) +! vim.current.buffer.xxx = True:(, AttributeError('xxx',)) +! >> BufferMark +! vim.current.buffer.mark(0):(, TypeError('must be string, not int',)) +! vim.current.buffer.mark("abc"):(, ValueError('mark name must be a single character',)) +! vim.current.buffer.mark("!"):(, error('invalid mark name',)) +! >> BufferRange +! vim.current.buffer.range(1, 2, 3):(, TypeError('function takes exactly 2 arguments (3 given)',)) +! > BufMap +! >> BufMapItem +! vim.buffers[None]:(, TypeError('key must be integer',)) +! vim.buffers[100000000]:(, KeyError(100000000,)) +! > Current +! >> CurrentGetattr +! vim.current.xxx:(, AttributeError('xxx',)) +! >> CurrentSetattr +! vim.current.line = True:(, TypeError('bad argument type for built-in operation',)) +! vim.current.buffer = True:(, TypeError('expected vim.Buffer object',)) +! vim.current.window = True:(, TypeError('expected vim.Window object',)) +! vim.current.tabpage = True:(, TypeError('expected vim.TabPage object',)) +! vim.current.xxx = True:(, AttributeError('xxx',)) +! vim.command("throw 'abc'"):(, error('abc',)) +! Exe("throw 'def'"):(, error('def',)) +! vim.eval("Exe('throw ''ghi''')"):(, error('ghi',)) +! vim.eval("Exe('echoerr ''jkl''')"):(, error('Vim(echoerr):jkl',)) +! vim.eval("Exe('xxx_non_existent_command_xxx')"):(, error('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',)) +! vim.bindeval("Exe('xxx_non_existent_command_xxx')"):(, error('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',)) +*** ../vim-7.3.1065/src/testdir/test87.in 2013-05-30 13:14:06.000000000 +0200 +--- src/testdir/test87.in 2013-05-30 13:25:22.000000000 +0200 +*************** +*** 746,761 **** + :$put =string(py3eval('dl2')) + :$put =string(py3eval('df(2)')) + :" +! :" Test exceptions +! :fun Exe(e) +! : execute a:e + :endfun + py3 << EOF + def ee(expr, g=globals(), l=locals()): + try: +! exec(expr, g, l) + except Exception as e: +! cb.append(repr((e.__class__, e))) + Exe = vim.bindeval('function("Exe")') + ee('vim.command("throw \'abc\'")') + ee('Exe("throw \'def\'")') +--- 746,1026 ---- + :$put =string(py3eval('dl2')) + :$put =string(py3eval('df(2)')) + :" +! :" Test errors +! :fun F() dict +! :endfun +! :fun D() + :endfun + py3 << EOF + def ee(expr, g=globals(), l=locals()): + try: +! try: +! exec(expr, g, l) +! except Exception as e: +! cb.append(expr + ':' + repr((e.__class__, e))) +! else: +! cb.append(expr + ':NOT FAILED') + except Exception as e: +! cb.append(expr + '::' + repr((e.__class__, e))) +! +! d = vim.Dictionary() +! ned = vim.Dictionary(foo='bar', baz='abc') +! dl = vim.Dictionary(a=1) +! dl.locked = True +! l = vim.List() +! ll = vim.List('abc') +! ll.locked = True +! f = vim.Function('string') +! fd = vim.Function('F') +! fdel = vim.Function('D') +! vim.command('delfunction D') +! +! def subexpr_test(expr, name, subexprs): +! cb.append('>>> Testing %s using %s' % (name, expr)) +! for subexpr in subexprs: +! ee(expr % subexpr) +! cb.append('<<< Finished') +! +! def stringtochars_test(expr): +! return subexpr_test(expr, 'StringToChars', ( +! '1', # Fail type checks +! 'u"\\0"', # Fail PyString_AsStringAndSize(bytes, , NULL) check +! '"\\0"', # Fail PyString_AsStringAndSize(object, , NULL) check +! )) +! +! class Mapping(object): +! def __init__(self, d): +! self.d = d +! +! def __getitem__(self, key): +! return self.d[key] +! +! def keys(self): +! return self.d.keys() +! +! def items(self): +! return self.d.items() +! +! def convertfrompyobject_test(expr, recurse=True): +! # pydict_to_tv +! stringtochars_test(expr % '{%s : 1}') +! if recurse: +! convertfrompyobject_test(expr % '{"abc" : %s}', False) +! # pymap_to_tv +! stringtochars_test(expr % 'Mapping({%s : 1})') +! if recurse: +! convertfrompyobject_test(expr % 'Mapping({"abc" : %s})', False) +! # pyseq_to_tv +! iter_test(expr) +! return subexpr_test(expr, 'ConvertFromPyObject', ( +! 'None', # Not conversible +! '{"": 1}', # Empty key not allowed +! 'FailingMapping()', # +! 'FailingMappingKey()', # +! )) +! +! def convertfrompymapping_test(expr): +! convertfrompyobject_test(expr) +! return subexpr_test(expr, 'ConvertFromPyMapping', ( +! '[]', +! )) +! +! def iter_test(expr): +! return subexpr_test(expr, '*Iter*', ( +! 'FailingIter()', +! 'FailingIterNext()', +! )) +! +! class FailingTrue(object): +! def __bool__(self): +! raise NotImplementedError +! +! class FailingIter(object): +! def __iter__(self): +! raise NotImplementedError +! +! class FailingIterNext(object): +! def __iter__(self): +! return self +! +! def __next__(self): +! raise NotImplementedError +! +! class FailingMappingKey(object): +! def __getitem__(self, item): +! raise NotImplementedError +! +! def keys(self): +! return list("abc") +! +! class FailingMapping(object): +! def __getitem__(self): +! raise NotImplementedError +! +! def keys(self): +! raise NotImplementedError +! +! class FailingList(list): +! def __getitem__(self, idx): +! if i == 2: +! raise NotImplementedError +! else: +! return super(FailingList, self).__getitem__(idx) +! +! cb.append("> Output") +! cb.append(">> OutputSetattr") +! ee('del sys.stdout.softspace') +! ee('sys.stdout.softspace = []') +! ee('sys.stdout.attr = None') +! cb.append(">> OutputWrite") +! ee('sys.stdout.write(None)') +! cb.append(">> OutputWriteLines") +! ee('sys.stdout.writelines(None)') +! ee('sys.stdout.writelines([1])') +! iter_test('sys.stdout.writelines(%s)') +! cb.append("> VimCommand") +! ee('vim.command(1)') +! #! Not checked: vim->python exceptions translating: checked later +! cb.append("> VimToPython") +! #! Not checked: everything: needs errors in internal python functions +! cb.append("> VimEval") +! ee('vim.eval(1)') +! #! Not checked: everything: needs errors in internal python functions +! cb.append("> VimEvalPy") +! ee('vim.bindeval(1)') +! #! Not checked: vim->python exceptions translating: checked later +! cb.append("> VimStrwidth") +! ee('vim.strwidth(1)') +! cb.append("> Dictionary") +! cb.append(">> DictionaryConstructor") +! ee('vim.Dictionary("abc")') +! ##! Not checked: py_dict_alloc failure +! cb.append(">> DictionarySetattr") +! ee('del d.locked') +! ee('d.locked = FailingTrue()') +! ee('vim.vvars.locked = False') +! ee('d.scope = True') +! ee('d.xxx = True') +! cb.append(">> _DictionaryItem") +! ee('d.get("a", 2, 3)') +! stringtochars_test('d.get(%s)') +! ee('d.pop("a")') +! ee('dl.pop("a")') +! cb.append(">> DictionaryIterNext") +! ee('for i in ned: ned["a"] = 1') +! cb.append(">> DictionaryAssItem") +! ee('dl["b"] = 1') +! stringtochars_test('d[%s] = 1') +! convertfrompyobject_test('d["a"] = %s') +! cb.append(">> DictionaryUpdate") +! cb.append(">>> kwargs") +! cb.append(">>> iter") +! ee('d.update(FailingMapping())') +! ee('d.update([FailingIterNext()])') +! iter_test('d.update(%s)') +! convertfrompyobject_test('d.update(%s)') +! stringtochars_test('d.update(((%s, 0),))') +! convertfrompyobject_test('d.update((("a", %s),))') +! cb.append(">> DictionaryPopItem") +! ee('d.popitem(1, 2)') +! cb.append(">> DictionaryHasKey") +! ee('d.has_key()') +! cb.append("> List") +! cb.append(">> ListConstructor") +! ee('vim.List(1, 2)') +! ee('vim.List(a=1)') +! iter_test('vim.List(%s)') +! convertfrompyobject_test('vim.List([%s])') +! cb.append(">> ListItem") +! ee('l[1000]') +! cb.append(">> ListAssItem") +! ee('ll[1] = 2') +! ee('l[1000] = 3') +! cb.append(">> ListAssSlice") +! ee('ll[1:100] = "abc"') +! iter_test('l[:] = %s') +! convertfrompyobject_test('l[:] = [%s]') +! cb.append(">> ListConcatInPlace") +! iter_test('l.extend(%s)') +! convertfrompyobject_test('l.extend([%s])') +! cb.append(">> ListSetattr") +! ee('del l.locked') +! ee('l.locked = FailingTrue()') +! ee('l.xxx = True') +! cb.append("> Function") +! cb.append(">> FunctionConstructor") +! ee('vim.Function("123")') +! ee('vim.Function("xxx_non_existent_function_xxx")') +! ee('vim.Function("xxx#non#existent#function#xxx")') +! cb.append(">> FunctionCall") +! convertfrompyobject_test('f(%s)') +! convertfrompymapping_test('fd(self=%s)') +! cb.append("> TabPage") +! cb.append(">> TabPageAttr") +! ee('vim.current.tabpage.xxx') +! cb.append("> TabList") +! cb.append(">> TabListItem") +! ee('vim.tabpages[1000]') +! cb.append("> Window") +! cb.append(">> WindowAttr") +! ee('vim.current.window.xxx') +! cb.append(">> WindowSetattr") +! ee('vim.current.window.buffer = 0') +! ee('vim.current.window.cursor = (10000000000, 100000000)') +! ee('vim.current.window.cursor = True') +! ee('vim.current.window.height = "abc"') +! ee('vim.current.window.width = "abc"') +! ee('vim.current.window.xxxxxx = True') +! cb.append("> WinList") +! cb.append(">> WinListItem") +! ee('vim.windows[1000]') +! cb.append("> Buffer") +! cb.append(">> StringToLine (indirect)") +! ee('vim.current.buffer[0] = "\\na"') +! cb.append(">> SetBufferLine (indirect)") +! ee('vim.current.buffer[0] = True') +! cb.append(">> SetBufferLines (indirect)") +! ee('vim.current.buffer[:] = True') +! ee('vim.current.buffer[:] = ["\\na", "bc"]') +! cb.append(">> InsertBufferLines (indirect)") +! ee('vim.current.buffer.append(None)') +! ee('vim.current.buffer.append(["\\na", "bc"])') +! ee('vim.current.buffer.append("\\nbc")') +! cb.append(">> RBItem") +! ee('vim.current.buffer[10000000000]') +! cb.append(">> RBAsItem") +! ee('vim.current.buffer[10000000000] = ""') +! cb.append(">> BufferAttr") +! ee('vim.current.buffer.xxx') +! cb.append(">> BufferSetattr") +! ee('vim.current.buffer.name = True') +! ee('vim.current.buffer.xxx = True') +! cb.append(">> BufferMark") +! ee('vim.current.buffer.mark(0)') +! ee('vim.current.buffer.mark("abc")') +! ee('vim.current.buffer.mark("!")') +! cb.append(">> BufferRange") +! ee('vim.current.buffer.range(1, 2, 3)') +! cb.append("> BufMap") +! cb.append(">> BufMapItem") +! ee('vim.buffers[None]') +! ee('vim.buffers[100000000]') +! cb.append("> Current") +! cb.append(">> CurrentGetattr") +! ee('vim.current.xxx') +! cb.append(">> CurrentSetattr") +! ee('vim.current.line = True') +! ee('vim.current.buffer = True') +! ee('vim.current.window = True') +! ee('vim.current.tabpage = True') +! ee('vim.current.xxx = True') +! EOF +! :" +! :" Test exceptions +! :fun Exe(e) +! : execute a:e +! :endfun +! py3 << EOF + Exe = vim.bindeval('function("Exe")') + ee('vim.command("throw \'abc\'")') + ee('Exe("throw \'def\'")') +*** ../vim-7.3.1065/src/testdir/test87.ok 2013-05-30 13:14:06.000000000 +0200 +--- src/testdir/test87.ok 2013-05-30 13:25:22.000000000 +0200 +*************** +*** 418,426 **** + ['a', 'b', 'c'] + [2, 2] + [2, 2] +! (, error('abc',)) +! (, error('def',)) +! (, error('ghi',)) +! (, error('Vim(echoerr):jkl',)) +! (, error('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',)) +! (, error('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',)) +--- 418,1070 ---- + ['a', 'b', 'c'] + [2, 2] + [2, 2] +! > Output +! >> OutputSetattr +! del sys.stdout.softspace:(, AttributeError("can't delete OutputObject attributes",)) +! sys.stdout.softspace = []:(, TypeError('softspace must be an integer',)) +! sys.stdout.attr = None:(, AttributeError('invalid attribute',)) +! >> OutputWrite +! sys.stdout.write(None):(, TypeError("Can't convert 'NoneType' object to str implicitly",)) +! >> OutputWriteLines +! sys.stdout.writelines(None):(, TypeError("'NoneType' object is not iterable",)) +! sys.stdout.writelines([1]):(, TypeError('writelines() requires list of strings',)) +! >>> Testing *Iter* using sys.stdout.writelines(%s) +! sys.stdout.writelines(FailingIter()):(, NotImplementedError()) +! sys.stdout.writelines(FailingIterNext()):(, NotImplementedError()) +! <<< Finished +! > VimCommand +! vim.command(1):(, TypeError('must be str, not int',)) +! > VimToPython +! > VimEval +! vim.eval(1):(, TypeError('must be str, not int',)) +! > VimEvalPy +! vim.bindeval(1):(, TypeError('must be str, not int',)) +! > VimStrwidth +! vim.strwidth(1):(, TypeError('must be str, not int',)) +! > Dictionary +! >> DictionaryConstructor +! vim.Dictionary("abc"):(, ValueError('expected sequence element of size 2',)) +! >> DictionarySetattr +! del d.locked:(, AttributeError('cannot delete vim.Dictionary attributes',)) +! d.locked = FailingTrue():(, NotImplementedError()) +! vim.vvars.locked = False:(, TypeError('cannot modify fixed dictionary',)) +! d.scope = True:(, AttributeError('cannot set this attribute',)) +! d.xxx = True:(, AttributeError('cannot set this attribute',)) +! >> _DictionaryItem +! d.get("a", 2, 3):(, TypeError('function takes at most 2 arguments (3 given)',)) +! >>> Testing StringToChars using d.get(%s) +! d.get(1):(, TypeError('object must be string',)) +! d.get(u"\0"):(, TypeError('expected bytes with no null',)) +! d.get("\0"):(, TypeError('expected bytes with no null',)) +! <<< Finished +! d.pop("a"):(, KeyError('a',)) +! dl.pop("a"):(, error('dict is locked',)) +! >> DictionaryIterNext +! for i in ned: ned["a"] = 1:(, RuntimeError('hashtab changed during iteration',)) +! >> DictionaryAssItem +! dl["b"] = 1:(, error('dict is locked',)) +! >>> Testing StringToChars using d[%s] = 1 +! d[1] = 1:(, TypeError('object must be string',)) +! d[u"\0"] = 1:(, TypeError('expected bytes with no null',)) +! d["\0"] = 1:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d["a"] = {%s : 1} +! d["a"] = {1 : 1}:(, TypeError('object must be string',)) +! d["a"] = {u"\0" : 1}:(, TypeError('expected bytes with no null',)) +! d["a"] = {"\0" : 1}:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d["a"] = {"abc" : {%s : 1}} +! d["a"] = {"abc" : {1 : 1}}:(, TypeError('object must be string',)) +! d["a"] = {"abc" : {u"\0" : 1}}:(, TypeError('expected bytes with no null',)) +! d["a"] = {"abc" : {"\0" : 1}}:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d["a"] = {"abc" : Mapping({%s : 1})} +! d["a"] = {"abc" : Mapping({1 : 1})}:(, TypeError('object must be string',)) +! d["a"] = {"abc" : Mapping({u"\0" : 1})}:(, TypeError('expected bytes with no null',)) +! d["a"] = {"abc" : Mapping({"\0" : 1})}:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : FailingIter()}:(, TypeError('unable to convert to vim structure',)) +! d["a"] = {"abc" : FailingIterNext()}:(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : None}:(, TypeError('unable to convert to vim structure',)) +! d["a"] = {"abc" : {"": 1}}:(, ValueError('empty keys are not allowed',)) +! d["a"] = {"abc" : FailingMapping()}:(, NotImplementedError()) +! d["a"] = {"abc" : FailingMappingKey()}:(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) +! d["a"] = Mapping({1 : 1}):(, TypeError('object must be string',)) +! d["a"] = Mapping({u"\0" : 1}):(, TypeError('expected bytes with no null',)) +! d["a"] = Mapping({"\0" : 1}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d["a"] = Mapping({"abc" : {%s : 1}}) +! d["a"] = Mapping({"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! d["a"] = Mapping({"abc" : {u"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! d["a"] = Mapping({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d["a"] = Mapping({"abc" : Mapping({%s : 1})}) +! d["a"] = Mapping({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! d["a"] = Mapping({"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! d["a"] = Mapping({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) +! d["a"] = Mapping({"abc" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : None}):(, TypeError('unable to convert to vim structure',)) +! d["a"] = Mapping({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! d["a"] = Mapping({"abc" : FailingMapping()}):(, NotImplementedError()) +! d["a"] = Mapping({"abc" : FailingMappingKey()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using d["a"] = %s +! d["a"] = FailingIter():(, TypeError('unable to convert to vim structure',)) +! d["a"] = FailingIterNext():(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d["a"] = %s +! d["a"] = None:(, TypeError('unable to convert to vim structure',)) +! d["a"] = {"": 1}:(, ValueError('empty keys are not allowed',)) +! d["a"] = FailingMapping():(, NotImplementedError()) +! d["a"] = FailingMappingKey():(, NotImplementedError()) +! <<< Finished +! >> DictionaryUpdate +! >>> kwargs +! >>> iter +! d.update(FailingMapping()):(, NotImplementedError()) +! d.update([FailingIterNext()]):(, NotImplementedError()) +! >>> Testing *Iter* using d.update(%s) +! d.update(FailingIter()):(, NotImplementedError()) +! d.update(FailingIterNext()):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using d.update({%s : 1}) +! d.update({1 : 1}):(, TypeError('object must be string',)) +! d.update({u"\0" : 1}):(, TypeError('expected bytes with no null',)) +! d.update({"\0" : 1}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update({"abc" : {%s : 1}}) +! d.update({"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! d.update({"abc" : {u"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! d.update({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update({"abc" : Mapping({%s : 1})}) +! d.update({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! d.update({"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! d.update({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d.update({"abc" : %s}) +! d.update({"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) +! d.update({"abc" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update({"abc" : %s}) +! d.update({"abc" : None}):(, TypeError('unable to convert to vim structure',)) +! d.update({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! d.update({"abc" : FailingMapping()}):(, NotImplementedError()) +! d.update({"abc" : FailingMappingKey()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using d.update(Mapping({%s : 1})) +! d.update(Mapping({1 : 1})):(, TypeError('object must be string',)) +! d.update(Mapping({u"\0" : 1})):(, TypeError('expected bytes with no null',)) +! d.update(Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update(Mapping({"abc" : {%s : 1}})) +! d.update(Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) +! d.update(Mapping({"abc" : {u"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! d.update(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update(Mapping({"abc" : Mapping({%s : 1})})) +! d.update(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) +! d.update(Mapping({"abc" : Mapping({u"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! d.update(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert to vim structure',)) +! d.update(Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) +! d.update(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! d.update(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) +! d.update(Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using d.update(%s) +! d.update(FailingIter()):(, NotImplementedError()) +! d.update(FailingIterNext()):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update(%s) +! d.update(None):(, TypeError("'NoneType' object is not iterable",)) +! d.update({"": 1}):(, ValueError('empty keys are not allowed',)) +! d.update(FailingMapping()):(, NotImplementedError()) +! d.update(FailingMappingKey()):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using d.update(((%s, 0),)) +! d.update(((1, 0),)):(, TypeError('object must be string',)) +! d.update(((u"\0", 0),)):(, TypeError('expected bytes with no null',)) +! d.update((("\0", 0),)):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", {%s : 1}),)) +! d.update((("a", {1 : 1}),)):(, TypeError('object must be string',)) +! d.update((("a", {u"\0" : 1}),)):(, TypeError('expected bytes with no null',)) +! d.update((("a", {"\0" : 1}),)):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", {"abc" : {%s : 1}}),)) +! d.update((("a", {"abc" : {1 : 1}}),)):(, TypeError('object must be string',)) +! d.update((("a", {"abc" : {u"\0" : 1}}),)):(, TypeError('expected bytes with no null',)) +! d.update((("a", {"abc" : {"\0" : 1}}),)):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", {"abc" : Mapping({%s : 1})}),)) +! d.update((("a", {"abc" : Mapping({1 : 1})}),)):(, TypeError('object must be string',)) +! d.update((("a", {"abc" : Mapping({u"\0" : 1})}),)):(, TypeError('expected bytes with no null',)) +! d.update((("a", {"abc" : Mapping({"\0" : 1})}),)):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : FailingIter()}),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", {"abc" : FailingIterNext()}),)):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : None}),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", {"abc" : {"": 1}}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", {"abc" : FailingMapping()}),)):(, NotImplementedError()) +! d.update((("a", {"abc" : FailingMappingKey()}),)):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) +! d.update((("a", Mapping({1 : 1})),)):(, TypeError('object must be string',)) +! d.update((("a", Mapping({u"\0" : 1})),)):(, TypeError('expected bytes with no null',)) +! d.update((("a", Mapping({"\0" : 1})),)):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", Mapping({"abc" : {%s : 1}})),)) +! d.update((("a", Mapping({"abc" : {1 : 1}})),)):(, TypeError('object must be string',)) +! d.update((("a", Mapping({"abc" : {u"\0" : 1}})),)):(, TypeError('expected bytes with no null',)) +! d.update((("a", Mapping({"abc" : {"\0" : 1}})),)):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", Mapping({"abc" : Mapping({%s : 1})})),)) +! d.update((("a", Mapping({"abc" : Mapping({1 : 1})})),)):(, TypeError('object must be string',)) +! d.update((("a", Mapping({"abc" : Mapping({u"\0" : 1})})),)):(, TypeError('expected bytes with no null',)) +! d.update((("a", Mapping({"abc" : Mapping({"\0" : 1})})),)):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : FailingIter()})),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", Mapping({"abc" : FailingIterNext()})),)):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : None})),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", Mapping({"abc" : {"": 1}})),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", Mapping({"abc" : FailingMapping()})),)):(, NotImplementedError()) +! d.update((("a", Mapping({"abc" : FailingMappingKey()})),)):(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using d.update((("a", %s),)) +! d.update((("a", FailingIter()),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", FailingIterNext()),)):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update((("a", %s),)) +! d.update((("a", None),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", {"": 1}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", FailingMapping()),)):(, NotImplementedError()) +! d.update((("a", FailingMappingKey()),)):(, NotImplementedError()) +! <<< Finished +! >> DictionaryPopItem +! d.popitem(1, 2):(, TypeError('function takes exactly 1 argument (2 given)',)) +! >> DictionaryHasKey +! d.has_key():(, TypeError('function takes exactly 1 argument (0 given)',)) +! > List +! >> ListConstructor +! vim.List(1, 2):(, TypeError('function takes at most 1 argument (2 given)',)) +! vim.List(a=1):(, TypeError('list constructor does not accept keyword arguments',)) +! >>> Testing *Iter* using vim.List(%s) +! vim.List(FailingIter()):(, NotImplementedError()) +! vim.List(FailingIterNext()):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using vim.List([{%s : 1}]) +! vim.List([{1 : 1}]):(, TypeError('object must be string',)) +! vim.List([{u"\0" : 1}]):(, TypeError('expected bytes with no null',)) +! vim.List([{"\0" : 1}]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using vim.List([{"abc" : {%s : 1}}]) +! vim.List([{"abc" : {1 : 1}}]):(, TypeError('object must be string',)) +! vim.List([{"abc" : {u"\0" : 1}}]):(, TypeError('expected bytes with no null',)) +! vim.List([{"abc" : {"\0" : 1}}]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using vim.List([{"abc" : Mapping({%s : 1})}]) +! vim.List([{"abc" : Mapping({1 : 1})}]):(, TypeError('object must be string',)) +! vim.List([{"abc" : Mapping({u"\0" : 1})}]):(, TypeError('expected bytes with no null',)) +! vim.List([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : FailingIter()}]):(, TypeError('unable to convert to vim structure',)) +! vim.List([{"abc" : FailingIterNext()}]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : None}]):(, TypeError('unable to convert to vim structure',)) +! vim.List([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) +! vim.List([{"abc" : FailingMapping()}]):(, NotImplementedError()) +! vim.List([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) +! vim.List([Mapping({1 : 1})]):(, TypeError('object must be string',)) +! vim.List([Mapping({u"\0" : 1})]):(, TypeError('expected bytes with no null',)) +! vim.List([Mapping({"\0" : 1})]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using vim.List([Mapping({"abc" : {%s : 1}})]) +! vim.List([Mapping({"abc" : {1 : 1}})]):(, TypeError('object must be string',)) +! vim.List([Mapping({"abc" : {u"\0" : 1}})]):(, TypeError('expected bytes with no null',)) +! vim.List([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using vim.List([Mapping({"abc" : Mapping({%s : 1})})]) +! vim.List([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('object must be string',)) +! vim.List([Mapping({"abc" : Mapping({u"\0" : 1})})]):(, TypeError('expected bytes with no null',)) +! vim.List([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : FailingIter()})]):(, TypeError('unable to convert to vim structure',)) +! vim.List([Mapping({"abc" : FailingIterNext()})]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : None})]):(, TypeError('unable to convert to vim structure',)) +! vim.List([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) +! vim.List([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) +! vim.List([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using vim.List([%s]) +! vim.List([FailingIter()]):(, TypeError('unable to convert to vim structure',)) +! vim.List([FailingIterNext()]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using vim.List([%s]) +! vim.List([None]):(, TypeError('unable to convert to vim structure',)) +! vim.List([{"": 1}]):(, ValueError('empty keys are not allowed',)) +! vim.List([FailingMapping()]):(, NotImplementedError()) +! vim.List([FailingMappingKey()]):(, NotImplementedError()) +! <<< Finished +! >> ListItem +! l[1000]:(, IndexError('list index out of range',)) +! >> ListAssItem +! ll[1] = 2:(, error('list is locked',)) +! l[1000] = 3:(, IndexError('list index out of range',)) +! >> ListAssSlice +! ll[1:100] = "abc":(, error('list is locked',)) +! >>> Testing *Iter* using l[:] = %s +! l[:] = FailingIter():(, NotImplementedError()) +! l[:] = FailingIterNext()::(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using l[:] = [{%s : 1}] +! l[:] = [{1 : 1}]:(, TypeError('object must be string',)) +! l[:] = [{u"\0" : 1}]:(, TypeError('expected bytes with no null',)) +! l[:] = [{"\0" : 1}]:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l[:] = [{"abc" : {%s : 1}}] +! l[:] = [{"abc" : {1 : 1}}]:(, TypeError('object must be string',)) +! l[:] = [{"abc" : {u"\0" : 1}}]:(, TypeError('expected bytes with no null',)) +! l[:] = [{"abc" : {"\0" : 1}}]:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l[:] = [{"abc" : Mapping({%s : 1})}] +! l[:] = [{"abc" : Mapping({1 : 1})}]:(, TypeError('object must be string',)) +! l[:] = [{"abc" : Mapping({u"\0" : 1})}]:(, TypeError('expected bytes with no null',)) +! l[:] = [{"abc" : Mapping({"\0" : 1})}]:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : FailingIter()}]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [{"abc" : FailingIterNext()}]:(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : None}]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [{"abc" : {"": 1}}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [{"abc" : FailingMapping()}]:(, NotImplementedError()) +! l[:] = [{"abc" : FailingMappingKey()}]:(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] +! l[:] = [Mapping({1 : 1})]:(, TypeError('object must be string',)) +! l[:] = [Mapping({u"\0" : 1})]:(, TypeError('expected bytes with no null',)) +! l[:] = [Mapping({"\0" : 1})]:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l[:] = [Mapping({"abc" : {%s : 1}})] +! l[:] = [Mapping({"abc" : {1 : 1}})]:(, TypeError('object must be string',)) +! l[:] = [Mapping({"abc" : {u"\0" : 1}})]:(, TypeError('expected bytes with no null',)) +! l[:] = [Mapping({"abc" : {"\0" : 1}})]:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l[:] = [Mapping({"abc" : Mapping({%s : 1})})] +! l[:] = [Mapping({"abc" : Mapping({1 : 1})})]:(, TypeError('object must be string',)) +! l[:] = [Mapping({"abc" : Mapping({u"\0" : 1})})]:(, TypeError('expected bytes with no null',)) +! l[:] = [Mapping({"abc" : Mapping({"\0" : 1})})]:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : FailingIter()})]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [Mapping({"abc" : FailingIterNext()})]:(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : None})]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [Mapping({"abc" : {"": 1}})]:(, ValueError('empty keys are not allowed',)) +! l[:] = [Mapping({"abc" : FailingMapping()})]:(, NotImplementedError()) +! l[:] = [Mapping({"abc" : FailingMappingKey()})]:(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using l[:] = [%s] +! l[:] = [FailingIter()]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [FailingIterNext()]:(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l[:] = [%s] +! l[:] = [None]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [{"": 1}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [FailingMapping()]:(, NotImplementedError()) +! l[:] = [FailingMappingKey()]:(, NotImplementedError()) +! <<< Finished +! >> ListConcatInPlace +! >>> Testing *Iter* using l.extend(%s) +! l.extend(FailingIter()):(, NotImplementedError()) +! l.extend(FailingIterNext()):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using l.extend([{%s : 1}]) +! l.extend([{1 : 1}]):(, TypeError('object must be string',)) +! l.extend([{u"\0" : 1}]):(, TypeError('expected bytes with no null',)) +! l.extend([{"\0" : 1}]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l.extend([{"abc" : {%s : 1}}]) +! l.extend([{"abc" : {1 : 1}}]):(, TypeError('object must be string',)) +! l.extend([{"abc" : {u"\0" : 1}}]):(, TypeError('expected bytes with no null',)) +! l.extend([{"abc" : {"\0" : 1}}]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l.extend([{"abc" : Mapping({%s : 1})}]) +! l.extend([{"abc" : Mapping({1 : 1})}]):(, TypeError('object must be string',)) +! l.extend([{"abc" : Mapping({u"\0" : 1})}]):(, TypeError('expected bytes with no null',)) +! l.extend([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : FailingIter()}]):(, TypeError('unable to convert to vim structure',)) +! l.extend([{"abc" : FailingIterNext()}]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : None}]):(, TypeError('unable to convert to vim structure',)) +! l.extend([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) +! l.extend([{"abc" : FailingMapping()}]):(, NotImplementedError()) +! l.extend([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) +! l.extend([Mapping({1 : 1})]):(, TypeError('object must be string',)) +! l.extend([Mapping({u"\0" : 1})]):(, TypeError('expected bytes with no null',)) +! l.extend([Mapping({"\0" : 1})]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l.extend([Mapping({"abc" : {%s : 1}})]) +! l.extend([Mapping({"abc" : {1 : 1}})]):(, TypeError('object must be string',)) +! l.extend([Mapping({"abc" : {u"\0" : 1}})]):(, TypeError('expected bytes with no null',)) +! l.extend([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l.extend([Mapping({"abc" : Mapping({%s : 1})})]) +! l.extend([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('object must be string',)) +! l.extend([Mapping({"abc" : Mapping({u"\0" : 1})})]):(, TypeError('expected bytes with no null',)) +! l.extend([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : FailingIter()})]):(, TypeError('unable to convert to vim structure',)) +! l.extend([Mapping({"abc" : FailingIterNext()})]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : None})]):(, TypeError('unable to convert to vim structure',)) +! l.extend([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) +! l.extend([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) +! l.extend([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using l.extend([%s]) +! l.extend([FailingIter()]):(, TypeError('unable to convert to vim structure',)) +! l.extend([FailingIterNext()]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l.extend([%s]) +! l.extend([None]):(, TypeError('unable to convert to vim structure',)) +! l.extend([{"": 1}]):(, ValueError('empty keys are not allowed',)) +! l.extend([FailingMapping()]):(, NotImplementedError()) +! l.extend([FailingMappingKey()]):(, NotImplementedError()) +! <<< Finished +! >> ListSetattr +! del l.locked:(, AttributeError('cannot delete vim.List attributes',)) +! l.locked = FailingTrue():(, NotImplementedError()) +! l.xxx = True:(, AttributeError('cannot set this attribute',)) +! > Function +! >> FunctionConstructor +! vim.Function("123"):(, ValueError('unnamed function does not exist',)) +! vim.Function("xxx_non_existent_function_xxx"):(, ValueError('function does not exist',)) +! vim.Function("xxx#non#existent#function#xxx"):(, ValueError('function does not exist',)) +! >> FunctionCall +! >>> Testing StringToChars using f({%s : 1}) +! f({1 : 1}):(, TypeError('object must be string',)) +! f({u"\0" : 1}):(, TypeError('expected bytes with no null',)) +! f({"\0" : 1}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using f({"abc" : {%s : 1}}) +! f({"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! f({"abc" : {u"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! f({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using f({"abc" : Mapping({%s : 1})}) +! f({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! f({"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! f({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using f({"abc" : %s}) +! f({"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) +! f({"abc" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using f({"abc" : %s}) +! f({"abc" : None}):(, TypeError('unable to convert to vim structure',)) +! f({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! f({"abc" : FailingMapping()}):(, NotImplementedError()) +! f({"abc" : FailingMappingKey()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using f(Mapping({%s : 1})) +! f(Mapping({1 : 1})):(, TypeError('object must be string',)) +! f(Mapping({u"\0" : 1})):(, TypeError('expected bytes with no null',)) +! f(Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using f(Mapping({"abc" : {%s : 1}})) +! f(Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) +! f(Mapping({"abc" : {u"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! f(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using f(Mapping({"abc" : Mapping({%s : 1})})) +! f(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) +! f(Mapping({"abc" : Mapping({u"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! f(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert to vim structure',)) +! f(Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) +! f(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! f(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) +! f(Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using f(%s) +! f(FailingIter()):(, TypeError('unable to convert to vim structure',)) +! f(FailingIterNext()):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using f(%s) +! f(None):(, TypeError('unable to convert to vim structure',)) +! f({"": 1}):(, ValueError('empty keys are not allowed',)) +! f(FailingMapping()):(, NotImplementedError()) +! f(FailingMappingKey()):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using fd(self={%s : 1}) +! fd(self={1 : 1}):(, TypeError('object must be string',)) +! fd(self={u"\0" : 1}):(, TypeError('expected bytes with no null',)) +! fd(self={"\0" : 1}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using fd(self={"abc" : {%s : 1}}) +! fd(self={"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! fd(self={"abc" : {u"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! fd(self={"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using fd(self={"abc" : Mapping({%s : 1})}) +! fd(self={"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! fd(self={"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! fd(self={"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using fd(self={"abc" : %s}) +! fd(self={"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) +! fd(self={"abc" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using fd(self={"abc" : %s}) +! fd(self={"abc" : None}):(, TypeError('unable to convert to vim structure',)) +! fd(self={"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! fd(self={"abc" : FailingMapping()}):(, NotImplementedError()) +! fd(self={"abc" : FailingMappingKey()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing StringToChars using fd(self=Mapping({%s : 1})) +! fd(self=Mapping({1 : 1})):(, TypeError('object must be string',)) +! fd(self=Mapping({u"\0" : 1})):(, TypeError('expected bytes with no null',)) +! fd(self=Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using fd(self=Mapping({"abc" : {%s : 1}})) +! fd(self=Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) +! fd(self=Mapping({"abc" : {u"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! fd(self=Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using fd(self=Mapping({"abc" : Mapping({%s : 1})})) +! fd(self=Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) +! fd(self=Mapping({"abc" : Mapping({u"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! fd(self=Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert to vim structure',)) +! fd(self=Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) +! fd(self=Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! fd(self=Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) +! fd(self=Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing *Iter* using fd(self=%s) +! fd(self=FailingIter()):(, TypeError('unable to convert object to vim dictionary',)) +! fd(self=FailingIterNext()):(, TypeError('unable to convert object to vim dictionary',)) +! <<< Finished +! >>> Testing ConvertFromPyObject using fd(self=%s) +! fd(self=None):(, TypeError('unable to convert object to vim dictionary',)) +! fd(self={"": 1}):(, ValueError('empty keys are not allowed',)) +! fd(self=FailingMapping()):(, NotImplementedError()) +! fd(self=FailingMappingKey()):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyMapping using fd(self=%s) +! fd(self=[]):(, AttributeError("'list' object has no attribute 'keys'",)) +! <<< Finished +! > TabPage +! >> TabPageAttr +! vim.current.tabpage.xxx:(, AttributeError("'vim.tabpage' object has no attribute 'xxx'",)) +! > TabList +! >> TabListItem +! vim.tabpages[1000]:(, IndexError('no such tab page',)) +! > Window +! >> WindowAttr +! vim.current.window.xxx:(, AttributeError("'vim.window' object has no attribute 'xxx'",)) +! >> WindowSetattr +! vim.current.window.buffer = 0:(, TypeError('readonly attribute',)) +! vim.current.window.cursor = (10000000000, 100000000):(, error('cursor position outside buffer',)) +! vim.current.window.cursor = True:(, TypeError('argument must be 2-item sequence, not bool',)) +! vim.current.window.height = "abc":(, TypeError('an integer is required',)) +! vim.current.window.width = "abc":(, TypeError('an integer is required',)) +! vim.current.window.xxxxxx = True:(, AttributeError('xxxxxx',)) +! > WinList +! >> WinListItem +! vim.windows[1000]:(, IndexError('no such window',)) +! > Buffer +! >> StringToLine (indirect) +! vim.current.buffer[0] = "\na":(, error('string cannot contain newlines',)) +! >> SetBufferLine (indirect) +! vim.current.buffer[0] = True:(, TypeError('bad argument type for built-in operation',)) +! >> SetBufferLines (indirect) +! vim.current.buffer[:] = True:(, TypeError('bad argument type for built-in operation',)) +! vim.current.buffer[:] = ["\na", "bc"]:(, error('string cannot contain newlines',)) +! >> InsertBufferLines (indirect) +! vim.current.buffer.append(None):(, TypeError('bad argument type for built-in operation',)) +! vim.current.buffer.append(["\na", "bc"]):(, error('string cannot contain newlines',)) +! vim.current.buffer.append("\nbc"):(, error('string cannot contain newlines',)) +! >> RBItem +! vim.current.buffer[10000000000]:(, IndexError('line number out of range',)) +! >> RBAsItem +! vim.current.buffer[10000000000] = "":(, IndexError('line number out of range',)) +! >> BufferAttr +! vim.current.buffer.xxx:(, AttributeError("'vim.buffer' object has no attribute 'xxx'",)) +! >> BufferSetattr +! vim.current.buffer.name = True:(, TypeError('object must be string',)) +! vim.current.buffer.xxx = True:(, AttributeError('xxx',)) +! >> BufferMark +! vim.current.buffer.mark(0):(, TypeError('must be str, not int',)) +! vim.current.buffer.mark("abc"):(, ValueError('mark name must be a single character',)) +! vim.current.buffer.mark("!"):(, error('invalid mark name',)) +! >> BufferRange +! vim.current.buffer.range(1, 2, 3):(, TypeError('function takes exactly 2 arguments (3 given)',)) +! > BufMap +! >> BufMapItem +! vim.buffers[None]:(, TypeError('key must be integer',)) +! vim.buffers[100000000]:(, KeyError(100000000,)) +! > Current +! >> CurrentGetattr +! vim.current.xxx:(, AttributeError("'vim.currentdata' object has no attribute 'xxx'",)) +! >> CurrentSetattr +! vim.current.line = True:(, TypeError('bad argument type for built-in operation',)) +! vim.current.buffer = True:(, TypeError('expected vim.Buffer object',)) +! vim.current.window = True:(, TypeError('expected vim.Window object',)) +! vim.current.tabpage = True:(, TypeError('expected vim.TabPage object',)) +! vim.current.xxx = True:(, AttributeError('xxx',)) +! vim.command("throw 'abc'"):(, error('abc',)) +! Exe("throw 'def'"):(, error('def',)) +! vim.eval("Exe('throw ''ghi''')"):(, error('ghi',)) +! vim.eval("Exe('echoerr ''jkl''')"):(, error('Vim(echoerr):jkl',)) +! vim.eval("Exe('xxx_non_existent_command_xxx')"):(, error('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',)) +! vim.bindeval("Exe('xxx_non_existent_command_xxx')"):(, error('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',)) +*** ../vim-7.3.1065/src/version.c 2013-05-30 13:22:07.000000000 +0200 +--- src/version.c 2013-05-30 13:24:41.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1066, + /**/ + +-- +If Pacman had affected us as kids we'd be running around in dark rooms, +munching pills and listening to repetitive music. + -- Marcus Brigstocke + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 40497552ec50ef435b54227fd0f06aaca4e97f48 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:33 +0200 Subject: [PATCH 0958/3340] - patchlevel 1067 --- 7.3.1067 | 158 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 158 insertions(+) create mode 100644 7.3.1067 diff --git a/7.3.1067 b/7.3.1067 new file mode 100644 index 00000000..0725a8b7 --- /dev/null +++ b/7.3.1067 @@ -0,0 +1,158 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1067 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1067 +Problem: Python: documentation lags behind. +Solution: Python patch 26. (ZyX) +Files: runtime/doc/if_pyth.txt + + +*** ../vim-7.3.1066/runtime/doc/if_pyth.txt 2013-05-30 13:01:14.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-05-30 13:31:16.000000000 +0200 +*************** +*** 480,496 **** + vim.VAR_DEF_SCOPE |g:| or |l:| dictionary + vim.VAR_SCOPE Other scope dictionary, + see |internal-variables| +! Methods: + Method Description ~ + keys() Returns a list with dictionary keys. + values() Returns a list with dictionary values. + items() Returns a list of 2-tuples with dictionary contents. +! update(iterable) +! update(dictionary) +! update(**kwargs) + Adds keys to dictionary. + Examples: > +! py d = vim.bindeval('{}') + d['a'] = 'b' # Item assignment + print d['a'] # getting item + d.update({'c': 'd'}) # .update(dictionary) +--- 480,515 ---- + vim.VAR_DEF_SCOPE |g:| or |l:| dictionary + vim.VAR_SCOPE Other scope dictionary, + see |internal-variables| +! Methods (note: methods do not support keyword arguments): + Method Description ~ + keys() Returns a list with dictionary keys. + values() Returns a list with dictionary values. + items() Returns a list of 2-tuples with dictionary contents. +! update(iterable), update(dictionary), update(**kwargs) + Adds keys to dictionary. ++ get(key[, default=None]) ++ Obtain key from dictionary, returning the default if it is ++ not present. ++ pop(key[, default]) ++ Remove specified key from dictionary and return ++ corresponding value. If key is not found and default is ++ given returns the default, otherwise raises KeyError. ++ popitem(key) ++ Remove specified key from dictionary and return a pair ++ with it and the corresponding value. Returned key is a new ++ object. ++ has_key(key) ++ Check whether dictionary contains specified key, similar ++ to `key in dict`. ++ ++ __new__(), __new__(iterable), __new__(dictionary), __new__(update) ++ You can use `vim.Dictionary()` to create new vim ++ dictionaries. `d=vim.Dictionary(arg)` is the same as ++ `d=vim.bindeval('{}');d.update(arg)`. Without arguments ++ constructs empty dictionary. ++ + Examples: > +! d = vim.Dictionary(food="bar") # Constructor + d['a'] = 'b' # Item assignment + print d['a'] # getting item + d.update({'c': 'd'}) # .update(dictionary) +*************** +*** 501,506 **** +--- 520,526 ---- + for key, val in d.items(): # .items() + print isinstance(d, vim.Dictionary) # True + for key in d: # Iteration over keys ++ class Dict(vim.Dictionary): # Subclassing + < + Note: when iterating over keys you should not modify dictionary. + +*************** +*** 510,517 **** + following methods: + Method Description ~ + extend(item) Add items to the list. + Examples: > +! l = vim.bindeval('[]') + l.extend(['abc', 'def']) # .extend() method + print l[1:] # slicing + l[:0] = ['ghi', 'jkl'] # slice assignment +--- 530,543 ---- + following methods: + Method Description ~ + extend(item) Add items to the list. ++ ++ __new__(), __new__(iterable) ++ You can use `vim.List()` to create new vim lists. ++ `l=vim.List(iterable)` is the same as ++ `l=vim.bindeval('[]');l.extend(iterable)`. Without ++ arguments constructs empty list. + Examples: > +! l = vim.List("abc") # Constructor, result: ['a', 'b', 'c'] + l.extend(['abc', 'def']) # .extend() method + print l[1:] # slicing + l[:0] = ['ghi', 'jkl'] # slice assignment +*************** +*** 519,531 **** + l[0] = 'mno' # assignment + for i in l: # iteration + print isinstance(l, vim.List) # True + + vim.Function object *python-Function* + Function-like object, acting like vim |Funcref| object. Supports `.name` + attribute and is callable. Accepts special keyword argument `self`, see +! |Dictionary-function|. + Examples: > +! f = vim.bindeval('function("tr")') + print f('abc', 'a', 'b') # Calls tr('abc', 'a', 'b') + vim.command(''' + function DictFun() dict +--- 545,560 ---- + l[0] = 'mno' # assignment + for i in l: # iteration + print isinstance(l, vim.List) # True ++ class List(vim.List): # Subclassing + + vim.Function object *python-Function* + Function-like object, acting like vim |Funcref| object. Supports `.name` + attribute and is callable. Accepts special keyword argument `self`, see +! |Dictionary-function|. You can also use `vim.Function(name)` constructor, +! it is the same as `vim.bindeval('function(%s)'%json.dumps(name))`. +! + Examples: > +! f = vim.Function('tr') # Constructor + print f('abc', 'a', 'b') # Calls tr('abc', 'a', 'b') + vim.command(''' + function DictFun() dict +*** ../vim-7.3.1066/src/version.c 2013-05-30 13:28:37.000000000 +0200 +--- src/version.c 2013-05-30 13:31:42.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1067, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +9. As often as possible, skip rather than walk. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 240fd3fd1b0640854ceb5e4a099560c902ede67a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:34 +0200 Subject: [PATCH 0959/3340] - patchlevel 1068 --- 7.3.1068 | 173 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 173 insertions(+) create mode 100644 7.3.1068 diff --git a/7.3.1068 b/7.3.1068 new file mode 100644 index 00000000..b796776b --- /dev/null +++ b/7.3.1068 @@ -0,0 +1,173 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1068 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1068 +Problem: Python: Script is auto-loaded on function creation. +Solution: Python patch 27. (ZyX) +Files: src/eval.c, src/if_py_both.h, src/proto/eval.pro, + src/testdir/test86.ok, src/testdir/test87.ok, src/vim.h + + +*** ../vim-7.3.1067/src/eval.c 2013-05-30 13:14:06.000000000 +0200 +--- src/eval.c 2013-05-30 13:35:15.000000000 +0200 +*************** +*** 810,815 **** +--- 810,816 ---- + # endif + prof_self_cmp __ARGS((const void *s1, const void *s2)); + #endif ++ static int script_autoload __ARGS((char_u *name, int reload)); + static char_u *autoload_name __ARGS((char_u *name)); + static void cat_func_name __ARGS((char_u *buf, ufunc_T *fp)); + static void func_free __ARGS((ufunc_T *fp)); +*************** +*** 829,838 **** + static void sortFunctions __ARGS(()); + #endif + +- +- /* Character used as separated in autoload function/variable names. */ +- #define AUTOLOAD_CHAR '#' +- + /* + * Initialize the global and v: variables. + */ +--- 830,835 ---- +*************** +*** 22190,22196 **** + * If "name" has a package name try autoloading the script for it. + * Return TRUE if a package was loaded. + */ +! int + script_autoload(name, reload) + char_u *name; + int reload; /* load script again when already loaded */ +--- 22187,22193 ---- + * If "name" has a package name try autoloading the script for it. + * Return TRUE if a package was loaded. + */ +! static int + script_autoload(name, reload) + char_u *name; + int reload; /* load script again when already loaded */ +*** ../vim-7.3.1067/src/if_py_both.h 2013-05-30 13:22:07.000000000 +0200 +--- src/if_py_both.h 2013-05-30 13:35:15.000000000 +0200 +*************** +*** 2015,2033 **** + func_ref(self->name); + } + else +! { +! self->name = get_expanded_name(name, TRUE); +! if (self->name == NULL) + { +! if (script_autoload(name, TRUE) && !aborting()) +! self->name = get_expanded_name(name, TRUE); +! if (self->name == NULL) +! { +! PyErr_SetString(PyExc_ValueError, _("function does not exist")); +! return NULL; +! } + } +- } + + return (PyObject *)(self); + } +--- 2015,2027 ---- + func_ref(self->name); + } + else +! if ((self->name = get_expanded_name(name, +! vim_strchr(name, AUTOLOAD_CHAR) == NULL)) +! == NULL) + { +! PyErr_SetString(PyExc_ValueError, _("function does not exist")); +! return NULL; + } + + return (PyObject *)(self); + } +*** ../vim-7.3.1067/src/proto/eval.pro 2013-05-30 13:14:06.000000000 +0200 +--- src/proto/eval.pro 2013-05-30 13:35:15.000000000 +0200 +*************** +*** 132,136 **** + void ex_oldfiles __ARGS((exarg_T *eap)); + int modify_fname __ARGS((char_u *src, int *usedlen, char_u **fnamep, char_u **bufp, int *fnamelen)); + char_u *do_string_sub __ARGS((char_u *str, char_u *pat, char_u *sub, char_u *flags)); +- int script_autoload __ARGS((char_u *name, int reload)); + /* vim: set ft=c : */ +--- 132,135 ---- +*** ../vim-7.3.1067/src/testdir/test86.ok 2013-05-30 13:28:37.000000000 +0200 +--- src/testdir/test86.ok 2013-05-30 13:35:15.000000000 +0200 +*************** +*** 889,895 **** + >> FunctionConstructor + vim.Function("123"):(, ValueError('unnamed function does not exist',)) + vim.Function("xxx_non_existent_function_xxx"):(, ValueError('function does not exist',)) +! vim.Function("xxx#non#existent#function#xxx"):(, ValueError('function does not exist',)) + >> FunctionCall + >>> Testing StringToChars using f({%s : 1}) + f({1 : 1}):(, TypeError('object must be string',)) +--- 889,895 ---- + >> FunctionConstructor + vim.Function("123"):(, ValueError('unnamed function does not exist',)) + vim.Function("xxx_non_existent_function_xxx"):(, ValueError('function does not exist',)) +! vim.Function("xxx#non#existent#function#xxx"):NOT FAILED + >> FunctionCall + >>> Testing StringToChars using f({%s : 1}) + f({1 : 1}):(, TypeError('object must be string',)) +*** ../vim-7.3.1067/src/testdir/test87.ok 2013-05-30 13:28:37.000000000 +0200 +--- src/testdir/test87.ok 2013-05-30 13:35:15.000000000 +0200 +*************** +*** 878,884 **** + >> FunctionConstructor + vim.Function("123"):(, ValueError('unnamed function does not exist',)) + vim.Function("xxx_non_existent_function_xxx"):(, ValueError('function does not exist',)) +! vim.Function("xxx#non#existent#function#xxx"):(, ValueError('function does not exist',)) + >> FunctionCall + >>> Testing StringToChars using f({%s : 1}) + f({1 : 1}):(, TypeError('object must be string',)) +--- 878,884 ---- + >> FunctionConstructor + vim.Function("123"):(, ValueError('unnamed function does not exist',)) + vim.Function("xxx_non_existent_function_xxx"):(, ValueError('function does not exist',)) +! vim.Function("xxx#non#existent#function#xxx"):NOT FAILED + >> FunctionCall + >>> Testing StringToChars using f({%s : 1}) + f({1 : 1}):(, TypeError('object must be string',)) +*** ../vim-7.3.1067/src/vim.h 2013-05-06 03:52:44.000000000 +0200 +--- src/vim.h 2013-05-30 13:35:15.000000000 +0200 +*************** +*** 2243,2246 **** +--- 2243,2249 ---- + #define SREQ_WIN 1 /* Request window-local option */ + #define SREQ_BUF 2 /* Request buffer-local option */ + ++ /* Character used as separated in autoload function/variable names. */ ++ #define AUTOLOAD_CHAR '#' ++ + #endif /* VIM__H */ +*** ../vim-7.3.1067/src/version.c 2013-05-30 13:32:26.000000000 +0200 +--- src/version.c 2013-05-30 13:34:44.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1068, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +10. Ask people what sex they are. Laugh hysterically after they answer. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 81c146f21388baad8050ba2a187f0217042ac372 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:35 +0200 Subject: [PATCH 0960/3340] - patchlevel 1069 --- 7.3.1069 | 210 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 210 insertions(+) create mode 100644 7.3.1069 diff --git a/7.3.1069 b/7.3.1069 new file mode 100644 index 00000000..a966c9df --- /dev/null +++ b/7.3.1069 @@ -0,0 +1,210 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1069 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1069 +Problem: Python: memory leaks. +Solution: Python patch 28: Purge out DICTKEY_CHECK_EMPTY macros. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1068/src/if_py_both.h 2013-05-30 13:37:23.000000000 +0200 +--- src/if_py_both.h 2013-05-30 14:50:11.000000000 +0200 +*************** +*** 32,46 **** + + #define DICTKEY_DECL \ + PyObject *dictkey_todecref = NULL; +- #define DICTKEY_CHECK_EMPTY(err) \ +- if (*key == NUL) \ +- { \ +- PyErr_SetString(PyExc_ValueError, _("empty keys are not allowed")); \ +- return err; \ +- } +- #define DICTKEY_SET_KEY (key = StringToChars(keyObject, &dictkey_todecref)) + #define DICTKEY_GET(err, decref) \ +! if (!DICTKEY_SET_KEY) \ + { \ + if (decref) \ + { \ +--- 32,39 ---- + + #define DICTKEY_DECL \ + PyObject *dictkey_todecref = NULL; + #define DICTKEY_GET(err, decref) \ +! if (!(key = StringToChars(keyObject, &dictkey_todecref))) \ + { \ + if (decref) \ + { \ +*************** +*** 50,56 **** + } \ + if (decref && !dictkey_todecref) \ + dictkey_todecref = keyObject; \ +! DICTKEY_CHECK_EMPTY(err) + #define DICTKEY_UNREF \ + Py_XDECREF(dictkey_todecref); + +--- 43,53 ---- + } \ + if (decref && !dictkey_todecref) \ + dictkey_todecref = keyObject; \ +! if (*key == NUL) \ +! { \ +! PyErr_SetString(PyExc_ValueError, _("empty keys are not allowed")); \ +! return err; \ +! } + #define DICTKEY_UNREF \ + Py_XDECREF(dictkey_todecref); + +*************** +*** 4551,4557 **** + + while (PyDict_Next(obj, &iter, &keyObject, &valObject)) + { +! DICTKEY_DECL + + if (keyObject == NULL || valObject == NULL) + { +--- 4548,4554 ---- + + while (PyDict_Next(obj, &iter, &keyObject, &valObject)) + { +! PyObject *todecref = NULL; + + if (keyObject == NULL || valObject == NULL) + { +*************** +*** 4559,4574 **** + return -1; + } + +! if (!DICTKEY_SET_KEY) + { + dict_unref(dict); + return -1; + } +- DICTKEY_CHECK_EMPTY(-1) + + di = dictitem_alloc(key); + +! DICTKEY_UNREF + + if (di == NULL) + { +--- 4556,4576 ---- + return -1; + } + +! if (!(key = StringToChars(keyObject, &todecref))) +! { +! dict_unref(dict); +! return -1; +! } +! if (*key == NUL) + { + dict_unref(dict); ++ Py_XDECREF(todecref); + return -1; + } + + di = dictitem_alloc(key); + +! Py_XDECREF(todecref); + + if (di == NULL) + { +*************** +*** 4632,4662 **** + + while ((keyObject = PyIter_Next(iterator))) + { +! DICTKEY_DECL + +! if (!DICTKEY_SET_KEY) + { + Py_DECREF(iterator); + dict_unref(dict); +- DICTKEY_UNREF + return -1; + } +! DICTKEY_CHECK_EMPTY(-1) + + if (!(valObject = PyObject_GetItem(obj, keyObject))) + { + Py_DECREF(keyObject); + Py_DECREF(iterator); + dict_unref(dict); +- DICTKEY_UNREF + return -1; + } + + di = dictitem_alloc(key); + +- DICTKEY_UNREF +- + Py_DECREF(keyObject); + + if (di == NULL) + { +--- 4634,4670 ---- + + while ((keyObject = PyIter_Next(iterator))) + { +! PyObject *todecref; + +! if (!(key = StringToChars(keyObject, &todecref))) + { ++ Py_DECREF(keyObject); + Py_DECREF(iterator); + dict_unref(dict); + return -1; + } +! if (*key == NUL) +! { +! Py_DECREF(keyObject); +! Py_DECREF(iterator); +! Py_XDECREF(todecref); +! dict_unref(dict); +! return -1; +! } + + if (!(valObject = PyObject_GetItem(obj, keyObject))) + { + Py_DECREF(keyObject); + Py_DECREF(iterator); ++ Py_XDECREF(todecref); + dict_unref(dict); + return -1; + } + + di = dictitem_alloc(key); + + Py_DECREF(keyObject); ++ Py_XDECREF(todecref); + + if (di == NULL) + { +*** ../vim-7.3.1068/src/version.c 2013-05-30 13:37:23.000000000 +0200 +--- src/version.c 2013-05-30 13:38:46.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1069, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +11. Specify that your drive-through order is "to go". + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 02db38b6f5fdaa9e6445b39aa8925566f647c450 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:35 +0200 Subject: [PATCH 0961/3340] - patchlevel 1070 --- 7.3.1070 | 109 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 109 insertions(+) create mode 100644 7.3.1070 diff --git a/7.3.1070 b/7.3.1070 new file mode 100644 index 00000000..4120898c --- /dev/null +++ b/7.3.1070 @@ -0,0 +1,109 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1070 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1070 +Problem: Vim crashes in Python tests. Compiler warning for unused function. +Solution: Disable the tests for now. Move the function. +Files: src/if_py_both.h, src/if_python.c, src/testdir/test86.in, + src/testdir/test87.in + + +*** ../vim-7.3.1069/src/if_py_both.h 2013-05-30 14:52:32.000000000 +0200 +--- src/if_py_both.h 2013-05-30 15:09:46.000000000 +0200 +*************** +*** 2322,2339 **** + return VimTryEnd(); + } + +- static void * +- py_memsave(void *p, size_t len) +- { +- void *r; +- if (!(r = PyMem_Malloc(len))) +- return NULL; +- mch_memmove(r, p, len); +- return r; +- } +- +- #define PY_STRSAVE(s) ((char_u *) py_memsave(s, STRLEN(s) + 1)) +- + static int + OptionsAssItem(OptionsObject *self, PyObject *keyObject, PyObject *valObject) + { +--- 2322,2327 ---- +*** ../vim-7.3.1069/src/if_python.c 2013-05-30 13:22:07.000000000 +0200 +--- src/if_python.c 2013-05-30 15:12:08.000000000 +0200 +*************** +*** 737,742 **** +--- 737,757 ---- + } + #endif + ++ #if defined(HAVE_LOCALE_H) || defined(X_LOCALE) ++ static void * ++ py_memsave(void *p, size_t len) ++ { ++ void *r; ++ ++ if (!(r = PyMem_Malloc(len))) ++ return NULL; ++ mch_memmove(r, p, len); ++ return r; ++ } ++ ++ # define PY_STRSAVE(s) ((char_u *) py_memsave(s, STRLEN(s) + 1)) ++ #endif ++ + /* + * Include the code shared with if_python3.c + */ +*** ../vim-7.3.1069/src/testdir/test86.in 2013-05-30 13:28:37.000000000 +0200 +--- src/testdir/test86.in 2013-05-30 15:13:46.000000000 +0200 +*************** +*** 8,13 **** +--- 8,15 ---- + STARTTEST + :so small.vim + :set encoding=latin1 ++ :" HACK: currently crashes, skip the test ++ :e! test.ok | wq! test.out + :if !has('python') | e! test.ok | wq! test.out | endif + :lang C + :py import vim +*** ../vim-7.3.1069/src/testdir/test87.in 2013-05-30 13:28:37.000000000 +0200 +--- src/testdir/test87.in 2013-05-30 15:13:55.000000000 +0200 +*************** +*** 2,7 **** +--- 2,9 ---- + + STARTTEST + :so small.vim ++ :" HACK: currently crashes, skip the test ++ :e! test.ok | wq! test.out + :if !has('python3') | e! test.ok | wq! test.out | endif + :lang C + :py3 import vim +*** ../vim-7.3.1069/src/version.c 2013-05-30 14:52:32.000000000 +0200 +--- src/version.c 2013-05-30 15:36:00.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1070, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +13. Go to a poetry recital and ask why the poems don't rhyme. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 13d2658d7d6b2c854c4a34d72fe1aca09c6e124d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:36 +0200 Subject: [PATCH 0962/3340] - patchlevel 1071 --- 7.3.1071 | 437 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 437 insertions(+) create mode 100644 7.3.1071 diff --git a/7.3.1071 b/7.3.1071 new file mode 100644 index 00000000..f3380b9e --- /dev/null +++ b/7.3.1071 @@ -0,0 +1,437 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1071 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1071 +Problem: New regexp engine: backreferences don't work correctly. +Solution: Add every possible start/end position on the state stack. +Files: src/regexp_nfa.c, src/regexp.h, src/testdir/test64.in, + src/testdir/test64.ok + + +*** ../vim-7.3.1070/src/regexp_nfa.c 2013-05-30 11:51:04.000000000 +0200 +--- src/regexp_nfa.c 2013-05-30 16:43:43.000000000 +0200 +*************** +*** 184,189 **** +--- 184,192 ---- + /* NFA regexp \ze operator encountered. */ + static int nfa_has_zend; + ++ /* NFA regexp \1 .. \9 encountered. */ ++ static int nfa_has_backref; ++ + /* Number of sub expressions actually being used during execution. 1 if only + * the whole match (subexpr 0) is used. */ + static int nfa_nsubexpr; +*************** +*** 266,271 **** +--- 269,275 ---- + post_ptr = post_start; + post_end = post_start + nstate_max; + nfa_has_zend = FALSE; ++ nfa_has_backref = FALSE; + + regcomp_start(expr, re_flags); + +*************** +*** 750,764 **** + /* TODO: Not supported yet */ + return FAIL; + +! case Magic('1'): EMIT(NFA_BACKREF1); break; +! case Magic('2'): EMIT(NFA_BACKREF2); break; +! case Magic('3'): EMIT(NFA_BACKREF3); break; +! case Magic('4'): EMIT(NFA_BACKREF4); break; +! case Magic('5'): EMIT(NFA_BACKREF5); break; +! case Magic('6'): EMIT(NFA_BACKREF6); break; +! case Magic('7'): EMIT(NFA_BACKREF7); break; +! case Magic('8'): EMIT(NFA_BACKREF8); break; +! case Magic('9'): EMIT(NFA_BACKREF9); break; + + case Magic('z'): + c = no_Magic(getchr()); +--- 754,771 ---- + /* TODO: Not supported yet */ + return FAIL; + +! case Magic('1'): +! case Magic('2'): +! case Magic('3'): +! case Magic('4'): +! case Magic('5'): +! case Magic('6'): +! case Magic('7'): +! case Magic('8'): +! case Magic('9'): +! EMIT(NFA_BACKREF1 + (no_Magic(c) - '1')); +! nfa_has_backref = TRUE; +! break; + + case Magic('z'): + c = no_Magic(getchr()); +*************** +*** 2581,2587 **** + typedef struct + { + nfa_thread_T *t; /* allocated array of states */ +! int n; /* nr of states in "t" */ + int id; /* ID of the list */ + } nfa_list_T; + +--- 2588,2595 ---- + typedef struct + { + nfa_thread_T *t; /* allocated array of states */ +! int n; /* nr of states currently in "t" */ +! int len; /* max nr of states in "t" */ + int id; /* ID of the list */ + } nfa_list_T; + +*************** +*** 2612,2620 **** +--- 2620,2711 ---- + /* Used during execution: whether a match has been found. */ + static int nfa_match; + ++ static int sub_equal __ARGS((regsub_T *sub1, regsub_T *sub2)); + static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *sub, int off)); + static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *sub, int *ip)); + ++ /* ++ * Return TRUE if "sub1" and "sub2" have the same positions. ++ */ ++ static int ++ sub_equal(sub1, sub2) ++ regsub_T *sub1; ++ regsub_T *sub2; ++ { ++ int i; ++ int todo; ++ linenr_T s1, e1; ++ linenr_T s2, e2; ++ char_u *sp1, *ep1; ++ char_u *sp2, *ep2; ++ ++ todo = sub1->in_use > sub2->in_use ? sub1->in_use : sub2->in_use; ++ if (REG_MULTI) ++ { ++ for (i = 0; i < todo; ++i) ++ { ++ if (i < sub1->in_use) ++ { ++ s1 = sub1->list.multi[i].start.lnum; ++ e1 = sub1->list.multi[i].end.lnum; ++ } ++ else ++ { ++ s1 = 0; ++ e1 = 0; ++ } ++ if (i < sub2->in_use) ++ { ++ s2 = sub2->list.multi[i].start.lnum; ++ e2 = sub2->list.multi[i].end.lnum; ++ } ++ else ++ { ++ s2 = 0; ++ e2 = 0; ++ } ++ if (s1 != s2 || e1 != e2) ++ return FALSE; ++ if (s1 != 0 && sub1->list.multi[i].start.col ++ != sub2->list.multi[i].start.col) ++ return FALSE; ++ if (e1 != 0 && sub1->list.multi[i].end.col ++ != sub2->list.multi[i].end.col) ++ return FALSE; ++ } ++ } ++ else ++ { ++ for (i = 0; i < todo; ++i) ++ { ++ if (i < sub1->in_use) ++ { ++ sp1 = sub1->list.line[i].start; ++ ep1 = sub1->list.line[i].end; ++ } ++ else ++ { ++ sp1 = NULL; ++ ep1 = NULL; ++ } ++ if (i < sub2->in_use) ++ { ++ sp2 = sub2->list.line[i].start; ++ ep2 = sub2->list.line[i].end; ++ } ++ else ++ { ++ sp2 = NULL; ++ ep2 = NULL; ++ } ++ if (sp1 != sp2 || ep1 != ep2) ++ return FALSE; ++ } ++ } ++ ++ return TRUE; ++ } ++ + static void + addstate(l, state, sub, off) + nfa_list_T *l; /* runtime state list */ +*************** +*** 2623,2629 **** + int off; /* byte offset, when -1 go to next line */ + { + int subidx; +! nfa_thread_T *lastthread; + lpos_T save_lpos; + int save_in_use; + char_u *save_ptr; +--- 2714,2720 ---- + int off; /* byte offset, when -1 go to next line */ + { + int subidx; +! nfa_thread_T *thread; + lpos_T save_lpos; + int save_in_use; + char_u *save_ptr; +*************** +*** 2674,2696 **** + { + /* This state is already in the list, don't add it again, + * unless it is an MOPEN that is used for a backreference. */ +! return; + } + + /* add the state to the list */ + state->lastlist = l->id; +! lastthread = &l->t[l->n++]; +! lastthread->state = state; +! lastthread->sub.in_use = sub->in_use; + if (sub->in_use > 0) + { + /* Copy the match start and end positions. */ + if (REG_MULTI) +! mch_memmove(&lastthread->sub.list.multi[0], + &sub->list.multi[0], + sizeof(struct multipos) * sub->in_use); + else +! mch_memmove(&lastthread->sub.list.line[0], + &sub->list.line[0], + sizeof(struct linepos) * sub->in_use); + } +--- 2765,2808 ---- + { + /* This state is already in the list, don't add it again, + * unless it is an MOPEN that is used for a backreference. */ +! if (!nfa_has_backref) +! return; +! +! /* See if the same state is already in the list with the same +! * positions. */ +! for (i = 0; i < l->n; ++i) +! { +! thread = &l->t[i]; +! if (thread->state->id == state->id +! && sub_equal(&thread->sub, sub)) +! return; +! } +! } +! +! /* when there are backreferences the number of states may be (a +! * lot) bigger */ +! if (nfa_has_backref && l->n == l->len) +! { +! int newlen = l->len * 3 / 2 + 50; +! +! l->t = vim_realloc(l->t, newlen * sizeof(nfa_thread_T)); +! l->len = newlen; + } + + /* add the state to the list */ + state->lastlist = l->id; +! thread = &l->t[l->n++]; +! thread->state = state; +! thread->sub.in_use = sub->in_use; + if (sub->in_use > 0) + { + /* Copy the match start and end positions. */ + if (REG_MULTI) +! mch_memmove(&thread->sub.list.multi[0], + &sub->list.multi[0], + sizeof(struct multipos) * sub->in_use); + else +! mch_memmove(&thread->sub.list.line[0], + &sub->list.line[0], + sizeof(struct linepos) * sub->in_use); + } +*************** +*** 2909,2915 **** + + /* re-order to put the new state at the current position */ + count = l->n - tlen; +! if (count > 1) + { + /* make space for new states, then move them from the + * end to the current position */ +--- 3021,3032 ---- + + /* re-order to put the new state at the current position */ + count = l->n - tlen; +! if (count == 1) +! { +! /* overwrite the current state */ +! l->t[i] = l->t[l->n - 1]; +! } +! else if (count > 1) + { + /* make space for new states, then move them from the + * end to the current position */ +*************** +*** 2920,2930 **** + &(l->t[l->n - 1]), + sizeof(nfa_thread_T) * count); + } +- else +- { +- /* overwrite the current state */ +- l->t[i] = l->t[l->n - 1]; +- } + --l->n; + *ip = i - 1; + } +--- 3037,3042 ---- +*************** +*** 3183,3196 **** + + /* Allocate memory for the lists of nodes. */ + size = (nstate + 1) * sizeof(nfa_thread_T); +! list[0].t = (nfa_thread_T *)lalloc(size, TRUE); +! list[1].t = (nfa_thread_T *)lalloc(size, TRUE); +! list[2].t = (nfa_thread_T *)lalloc(size, TRUE); + if (list[0].t == NULL || list[1].t == NULL || list[2].t == NULL) + goto theend; +- vim_memset(list[0].t, 0, size); +- vim_memset(list[1].t, 0, size); +- vim_memset(list[2].t, 0, size); + + #ifdef ENABLE_LOG + log_fd = fopen(NFA_REGEXP_RUN_LOG, "a"); +--- 3295,3308 ---- + + /* Allocate memory for the lists of nodes. */ + size = (nstate + 1) * sizeof(nfa_thread_T); +! list[0].t = (nfa_thread_T *)lalloc_clear(size, TRUE); +! list[0].len = nstate + 1; +! list[1].t = (nfa_thread_T *)lalloc_clear(size, TRUE); +! list[1].len = nstate + 1; +! list[2].t = (nfa_thread_T *)lalloc_clear(size, TRUE); +! list[2].len = nstate + 1; + if (list[0].t == NULL || list[1].t == NULL || list[2].t == NULL) + goto theend; + + #ifdef ENABLE_LOG + log_fd = fopen(NFA_REGEXP_RUN_LOG, "a"); +*************** +*** 3970,3976 **** + vim_free(list[0].t); + vim_free(list[1].t); + vim_free(list[2].t); +- list[0].t = list[1].t = list[2].t = NULL; + vim_free(listids); + #undef ADD_POS_NEG_STATE + #ifdef NFA_REGEXP_DEBUG_LOG +--- 4082,4087 ---- +*************** +*** 4131,4136 **** +--- 4242,4248 ---- + reglnum = 0; /* relative to line */ + + nfa_has_zend = prog->has_zend; ++ nfa_has_backref = prog->has_backref; + nfa_nsubexpr = prog->nsubexp; + + nstate = prog->nstate; +*************** +*** 4225,4230 **** +--- 4337,4343 ---- + prog->engine = &nfa_regengine; + prog->nstate = nstate; + prog->has_zend = nfa_has_zend; ++ prog->has_backref = nfa_has_backref; + prog->nsubexp = regnpar; + #ifdef ENABLE_LOG + nfa_postfix_dump(expr, OK); +*** ../vim-7.3.1070/src/regexp.h 2013-05-29 21:14:37.000000000 +0200 +--- src/regexp.h 2013-05-30 15:54:53.000000000 +0200 +*************** +*** 87,92 **** +--- 87,93 ---- + regprog_T regprog; + nfa_state_T *start; + int has_zend; /* pattern contains \ze */ ++ int has_backref; /* pattern contains \1 .. \9 */ + int nsubexp; /* number of () */ + int nstate; + nfa_state_T state[0]; /* actually longer.. */ +*** ../vim-7.3.1070/src/testdir/test64.in 2013-05-30 11:51:04.000000000 +0200 +--- src/testdir/test64.in 2013-05-30 16:47:29.000000000 +0200 +*************** +*** 333,339 **** + :" + :"""" Back references + :call add(tl, [2, '\(\i\+\) \1', ' abc abc', 'abc abc', 'abc']) +! :"call add(tl, [2, '\(\i\+\) \1', 'xgoo goox', 'goo goo', 'goo']) + :call add(tl, [2, '\(a\)\(b\)\(c\)\(dd\)\(e\)\(f\)\(g\)\(h\)\(i\)\1\2\3\4\5\6\7\8\9', 'xabcddefghiabcddefghix', 'abcddefghiabcddefghi', 'a', 'b', 'c', 'dd', 'e', 'f', 'g', 'h', 'i']) + :" + :"""" Look-behind with limit +--- 333,339 ---- + :" + :"""" Back references + :call add(tl, [2, '\(\i\+\) \1', ' abc abc', 'abc abc', 'abc']) +! :call add(tl, [2, '\(\i\+\) \1', 'xgoo goox', 'goo goo', 'goo']) + :call add(tl, [2, '\(a\)\(b\)\(c\)\(dd\)\(e\)\(f\)\(g\)\(h\)\(i\)\1\2\3\4\5\6\7\8\9', 'xabcddefghiabcddefghix', 'abcddefghiabcddefghi', 'a', 'b', 'c', 'dd', 'e', 'f', 'g', 'h', 'i']) + :" + :"""" Look-behind with limit +*** ../vim-7.3.1070/src/testdir/test64.ok 2013-05-30 11:51:04.000000000 +0200 +--- src/testdir/test64.ok 2013-05-30 17:00:27.000000000 +0200 +*************** +*** 716,721 **** +--- 716,724 ---- + OK 0 - \(\i\+\) \1 + OK 1 - \(\i\+\) \1 + OK 2 - \(\i\+\) \1 ++ OK 0 - \(\i\+\) \1 ++ OK 1 - \(\i\+\) \1 ++ OK 2 - \(\i\+\) \1 + OK 0 - \(a\)\(b\)\(c\)\(dd\)\(e\)\(f\)\(g\)\(h\)\(i\)\1\2\3\4\5\6\7\8\9 + OK 1 - \(a\)\(b\)\(c\)\(dd\)\(e\)\(f\)\(g\)\(h\)\(i\)\1\2\3\4\5\6\7\8\9 + OK 2 - \(a\)\(b\)\(c\)\(dd\)\(e\)\(f\)\(g\)\(h\)\(i\)\1\2\3\4\5\6\7\8\9 +*** ../vim-7.3.1070/src/version.c 2013-05-30 15:38:20.000000000 +0200 +--- src/version.c 2013-05-30 17:02:40.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1071, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +14. Put mosquito netting around your work area. Play a tape of jungle + sounds all day. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5d36ce9ea109dc4c75ede5dcb8035763ba5d03ed Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:37 +0200 Subject: [PATCH 0963/3340] - patchlevel 1072 --- 7.3.1072 | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 7.3.1072 diff --git a/7.3.1072 b/7.3.1072 new file mode 100644 index 00000000..9ff64b77 --- /dev/null +++ b/7.3.1072 @@ -0,0 +1,45 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1072 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1072 +Problem: Compiler warning for unitialized variable. +Solution: Initialize it. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1071/src/regexp_nfa.c 2013-05-30 17:05:34.000000000 +0200 +--- src/regexp_nfa.c 2013-05-30 17:37:48.000000000 +0200 +*************** +*** 2873,2878 **** +--- 2873,2879 ---- + + /* Set the position (with "off") in the subexpression. Save and + * restore it when it was in use. Otherwise fill any gap. */ ++ save_ptr = NULL; + if (REG_MULTI) + { + if (subidx < sub->in_use) +*** ../vim-7.3.1071/src/version.c 2013-05-30 17:05:34.000000000 +0200 +--- src/version.c 2013-05-30 17:48:42.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1072, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +16. Have your coworkers address you by your wrestling name, Rock Hard Kim. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ce0d03b45d72eb08f43a02d6eee9f3e263df8ebc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:37 +0200 Subject: [PATCH 0964/3340] - patchlevel 1073 --- 7.3.1073 | 339 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 339 insertions(+) create mode 100644 7.3.1073 diff --git a/7.3.1073 b/7.3.1073 new file mode 100644 index 00000000..30ffa940 --- /dev/null +++ b/7.3.1073 @@ -0,0 +1,339 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1073 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1073 +Problem: New regexp engine may run out of states. +Solution: Allocate states dynamically. Also make the test report errors. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok, + src/testdir/test95.in + + +*** ../vim-7.3.1072/src/regexp_nfa.c 2013-05-30 17:49:19.000000000 +0200 +--- src/regexp_nfa.c 2013-05-30 18:36:12.000000000 +0200 +*************** +*** 233,239 **** + + /* helper functions used when doing re2post() ... regatom() parsing */ + #define EMIT(c) do { \ +! if (post_ptr >= post_end) \ + return FAIL; \ + *post_ptr++ = c; \ + } while (0) +--- 233,239 ---- + + /* helper functions used when doing re2post() ... regatom() parsing */ + #define EMIT(c) do { \ +! if (post_ptr >= post_end && realloc_post_list() == FAIL) \ + return FAIL; \ + *post_ptr++ = c; \ + } while (0) +*************** +*** 256,266 **** + nstate_max = (int)(STRLEN(expr) + 1) * NFA_POSTFIX_MULTIPLIER; + + /* Some items blow up in size, such as [A-z]. Add more space for that. +! * TODO: some patterns may still fail. */ + nstate_max += 1000; + + /* Size for postfix representation of expr. */ +! postfix_size = sizeof(*post_start) * nstate_max; + + post_start = (int *)lalloc(postfix_size, TRUE); + if (post_start == NULL) +--- 256,266 ---- + nstate_max = (int)(STRLEN(expr) + 1) * NFA_POSTFIX_MULTIPLIER; + + /* Some items blow up in size, such as [A-z]. Add more space for that. +! * When it is still not enough realloc_post_list() will be used. */ + nstate_max += 1000; + + /* Size for postfix representation of expr. */ +! postfix_size = sizeof(int) * nstate_max; + + post_start = (int *)lalloc(postfix_size, TRUE); + if (post_start == NULL) +*************** +*** 277,282 **** +--- 277,307 ---- + } + + /* ++ * Allocate more space for post_start. Called when ++ * running above the estimated number of states. ++ */ ++ static int ++ realloc_post_list() ++ { ++ int nstate_max = post_end - post_start; ++ int new_max = nstate_max + 1000; ++ int *new_start; ++ int *old_start; ++ ++ new_start = (int *)lalloc(new_max * sizeof(int), TRUE); ++ if (new_start == NULL) ++ return FAIL; ++ mch_memmove(new_start, post_start, nstate_max * sizeof(int)); ++ vim_memset(new_start + nstate_max, 0, 1000 * sizeof(int)); ++ old_start = post_start; ++ post_start = new_start; ++ post_ptr = new_start + (post_ptr - old_start); ++ post_end = post_start + new_max; ++ vim_free(old_start); ++ return OK; ++ } ++ ++ /* + * Search between "start" and "end" and try to recognize a + * character class in expanded form. For example [0-9]. + * On success, return the id the character class to be emitted. +*************** +*** 1306,1312 **** + int greedy = TRUE; /* Braces are prefixed with '-' ? */ + char_u *old_regparse, *new_regparse; + int c2; +! int *old_post_ptr, *my_post_start; + int old_regnpar; + int quest; + +--- 1331,1338 ---- + int greedy = TRUE; /* Braces are prefixed with '-' ? */ + char_u *old_regparse, *new_regparse; + int c2; +! int old_post_pos; +! int my_post_start; + int old_regnpar; + int quest; + +*************** +*** 1317,1323 **** + * {m,n} is next */ + old_regnpar = regnpar; + /* store current pos in the postfix form, for \{m,n} involving 0s */ +! my_post_start = post_ptr; + + ret = nfa_regatom(); + if (ret == FAIL) +--- 1343,1349 ---- + * {m,n} is next */ + old_regnpar = regnpar; + /* store current pos in the postfix form, for \{m,n} involving 0s */ +! my_post_start = (int)(post_ptr - post_start); + + ret = nfa_regatom(); + if (ret == FAIL) +*************** +*** 1430,1443 **** + if (maxval == 0) + { + /* Ignore result of previous call to nfa_regatom() */ +! post_ptr = my_post_start; + /* NFA_SKIP_CHAR has 0-length and works everywhere */ + EMIT(NFA_SKIP_CHAR); + return OK; + } + + /* Ignore previous call to nfa_regatom() */ +! post_ptr = my_post_start; + /* Save pos after the repeated atom and the \{} */ + new_regparse = regparse; + +--- 1456,1469 ---- + if (maxval == 0) + { + /* Ignore result of previous call to nfa_regatom() */ +! post_ptr = post_start + my_post_start; + /* NFA_SKIP_CHAR has 0-length and works everywhere */ + EMIT(NFA_SKIP_CHAR); + return OK; + } + + /* Ignore previous call to nfa_regatom() */ +! post_ptr = post_start + my_post_start; + /* Save pos after the repeated atom and the \{} */ + new_regparse = regparse; + +*************** +*** 1449,1461 **** + curchr = -1; + /* Restore count of parenthesis */ + regnpar = old_regnpar; +! old_post_ptr = post_ptr; + if (nfa_regatom() == FAIL) + return FAIL; + /* after "minval" times, atoms are optional */ + if (i + 1 > minval) + EMIT(quest); +! if (old_post_ptr != my_post_start) + EMIT(NFA_CONCAT); + } + +--- 1475,1487 ---- + curchr = -1; + /* Restore count of parenthesis */ + regnpar = old_regnpar; +! old_post_pos = (int)(post_ptr - post_start); + if (nfa_regatom() == FAIL) + return FAIL; + /* after "minval" times, atoms are optional */ + if (i + 1 > minval) + EMIT(quest); +! if (old_post_pos != my_post_start) + EMIT(NFA_CONCAT); + } + +*************** +*** 1572,1580 **** + nfa_regbranch() + { + int ch; +! int *old_post_ptr; + +! old_post_ptr = post_ptr; + + /* First branch, possibly the only one */ + if (nfa_regconcat() == FAIL) +--- 1598,1606 ---- + nfa_regbranch() + { + int ch; +! int old_post_pos; + +! old_post_pos = (int)(post_ptr - post_start); + + /* First branch, possibly the only one */ + if (nfa_regconcat() == FAIL) +*************** +*** 1587,1604 **** + skipchr(); + EMIT(NFA_NOPEN); + EMIT(NFA_PREV_ATOM_NO_WIDTH); +! old_post_ptr = post_ptr; + if (nfa_regconcat() == FAIL) + return FAIL; + /* if concat is empty, skip a input char. But do emit a node */ +! if (old_post_ptr == post_ptr) + EMIT(NFA_SKIP_CHAR); + EMIT(NFA_CONCAT); + ch = peekchr(); + } + + /* Even if a branch is empty, emit one node for it */ +! if (old_post_ptr == post_ptr) + EMIT(NFA_SKIP_CHAR); + + return OK; +--- 1613,1630 ---- + skipchr(); + EMIT(NFA_NOPEN); + EMIT(NFA_PREV_ATOM_NO_WIDTH); +! old_post_pos = (int)(post_ptr - post_start); + if (nfa_regconcat() == FAIL) + return FAIL; + /* if concat is empty, skip a input char. But do emit a node */ +! if (old_post_pos == (int)(post_ptr - post_start)) + EMIT(NFA_SKIP_CHAR); + EMIT(NFA_CONCAT); + ch = peekchr(); + } + + /* Even if a branch is empty, emit one node for it */ +! if (old_post_pos == (int)(post_ptr - post_start)) + EMIT(NFA_SKIP_CHAR); + + return OK; +*** ../vim-7.3.1072/src/testdir/test64.in 2013-05-30 17:05:34.000000000 +0200 +--- src/testdir/test64.in 2013-05-30 18:38:49.000000000 +0200 +*************** +*** 348,353 **** +--- 348,356 ---- + :call add(tl, [2, '\_[^8-9]\+', "asfi\n9888", "asfi\n"]) + :call add(tl, [2, '\_[^a]\+', "asfi\n9888", "sfi\n9888"]) + :" ++ :"""" Requiring lots of states. ++ :call add(tl, [0, '[0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12}', " 12345678-1234-1234-1234-123456789012 ", "12345678-1234-1234-1234-123456789012", "1234-"]) ++ :" + :" + :"""" Run the tests + :" +*************** +*** 361,367 **** + : continue + : endif + : let ®expengine = engine +! : let l = matchlist(text, pat) + :" check the match itself + : if len(l) == 0 && len(t) > matchidx + : $put ='ERROR: pat: \"' . pat . '\", text: \"' . text . '\", did not match, expected: \"' . t[matchidx] . '\"' +--- 364,374 ---- + : continue + : endif + : let ®expengine = engine +! : try +! : let l = matchlist(text, pat) +! : catch +! : $put ='ERROR: pat: \"' . pat . '\", text: \"' . text . '\", caused an exception: \"' . v:exception . '\"' +! : endtry + :" check the match itself + : if len(l) == 0 && len(t) > matchidx + : $put ='ERROR: pat: \"' . pat . '\", text: \"' . text . '\", did not match, expected: \"' . t[matchidx] . '\"' +*** ../vim-7.3.1072/src/testdir/test64.ok 2013-05-30 17:05:34.000000000 +0200 +--- src/testdir/test64.ok 2013-05-30 18:42:43.000000000 +0200 +*************** +*** 740,745 **** +--- 740,747 ---- + OK 0 - \_[^a]\+ + OK 1 - \_[^a]\+ + OK 2 - \_[^a]\+ ++ OK 0 - [0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12} ++ OK 1 - [0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12} + 192.168.0.1 + 192.168.0.1 + 192.168.0.1 +*** ../vim-7.3.1072/src/testdir/test95.in 2013-05-26 15:14:49.000000000 +0200 +--- src/testdir/test95.in 2013-05-30 18:13:59.000000000 +0200 +*************** +*** 85,91 **** + : continue + : endif + : let ®expengine = engine +! : let l = matchlist(text, pat) + :" check the match itself + : if len(l) == 0 && len(t) > matchidx + : $put ='ERROR: pat: \"' . pat . '\", text: \"' . text . '\", did not match, expected: \"' . t[matchidx] . '\"' +--- 85,95 ---- + : continue + : endif + : let ®expengine = engine +! : try +! : let l = matchlist(text, pat) +! : catch +! : $put ='ERROR: pat: \"' . pat . '\", text: \"' . text . '\", caused an exception: \"' . v:exception . '\"' +! : endtry + :" check the match itself + : if len(l) == 0 && len(t) > matchidx + : $put ='ERROR: pat: \"' . pat . '\", text: \"' . text . '\", did not match, expected: \"' . t[matchidx] . '\"' +*** ../vim-7.3.1072/src/version.c 2013-05-30 17:49:19.000000000 +0200 +--- src/version.c 2013-05-30 18:43:08.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1073, + /**/ + +-- +How To Keep A Healthy Level Of Insanity: +17. When the money comes out the ATM, scream "I won!, I won! 3rd + time this week!!!!!" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 52c15c893a900f5533f3db6fcf7560604aaa3a9a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:38 +0200 Subject: [PATCH 0965/3340] - patchlevel 1074 --- 7.3.1074 | 59 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.1074 diff --git a/7.3.1074 b/7.3.1074 new file mode 100644 index 00000000..4d06267f --- /dev/null +++ b/7.3.1074 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1074 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1074 +Problem: Compiler warning for printf format. (Manuel Ortega) +Solution: Add type casts. +Files: src/if_py_both.h + + +*** ../vim-7.3.1073/src/if_py_both.h 2013-05-30 15:38:20.000000000 +0200 +--- src/if_py_both.h 2013-05-30 18:58:57.000000000 +0200 +*************** +*** 3807,3813 **** + name = ""; + + return PyString_FromFormat("", +! name, self->start, self->end); + } + } + +--- 3807,3813 ---- + name = ""; + + return PyString_FromFormat("", +! name, (int)self->start, (int)self->end); + } + } + +*** ../vim-7.3.1073/src/version.c 2013-05-30 18:45:20.000000000 +0200 +--- src/version.c 2013-05-30 18:59:37.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1074, + /**/ + +-- +In many of the more relaxed civilizations on the Outer Eastern Rim of the +Galaxy, "The Hitchhiker's Guide to the Galaxy" has already supplanted the +great "Encyclopedia Galactica" as the standard repository of all knowledge +and wisdom, for though it has many omissions and contains much that is +apocryphal, or at least wildly inaccurate, it scores over the older, more +pedestrian work in two important respects. +First, it is slightly cheaper; and second, it has the words "DON'T PANIC" +inscribed in large friendly letters on its cover. + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 31b7c8a4f30e79d0511951ed4fe9d3cbdfcbc10d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:39 +0200 Subject: [PATCH 0966/3340] - patchlevel 1075 --- 7.3.1075 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.1075 diff --git a/7.3.1075 b/7.3.1075 new file mode 100644 index 00000000..c86f42e4 --- /dev/null +++ b/7.3.1075 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1075 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1075 +Problem: Compiler warning for storing a long_u in an int. +Solution: Declare the number as an int. (Mike Williams) +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1074/src/regexp_nfa.c 2013-05-30 18:45:20.000000000 +0200 +--- src/regexp_nfa.c 2013-05-30 19:15:50.000000000 +0200 +*************** +*** 890,896 **** + + default: + { +! long_u n = 0; + int cmp = c; + + if (c == '<' || c == '>') +--- 890,896 ---- + + default: + { +! int n = 0; + int cmp = c; + + if (c == '<' || c == '>') +*** ../vim-7.3.1074/src/version.c 2013-05-30 19:01:20.000000000 +0200 +--- src/version.c 2013-05-30 19:16:36.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1075, + /**/ + +-- +One difference between a man and a machine is that a machine is quiet +when well oiled. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 29bbff0295f9c38366590f3aa1d5d748b881651f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:39 +0200 Subject: [PATCH 0967/3340] - patchlevel 1076 --- 7.3.1076 | 397 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 397 insertions(+) create mode 100644 7.3.1076 diff --git a/7.3.1076 b/7.3.1076 new file mode 100644 index 00000000..b01ad27d --- /dev/null +++ b/7.3.1076 @@ -0,0 +1,397 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1076 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1076 +Problem: New regexp engine: \@= and \& don't work. +Solution: Make these items work. Add column info to logging. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1075/src/regexp_nfa.c 2013-05-30 19:18:27.000000000 +0200 +--- src/regexp_nfa.c 2013-05-30 21:41:51.000000000 +0200 +*************** +*** 1740,1747 **** + STRCPY(code, "NFA_PREV_ATOM_NO_WIDTH"); break; + case NFA_PREV_ATOM_NO_WIDTH_NEG: + STRCPY(code, "NFA_PREV_ATOM_NO_WIDTH_NEG"); break; +! case NFA_NOPEN: STRCPY(code, "NFA_MOPEN_INVISIBLE"); break; +! case NFA_NCLOSE: STRCPY(code, "NFA_MCLOSE_INVISIBLE"); break; + case NFA_START_INVISIBLE: STRCPY(code, "NFA_START_INVISIBLE"); break; + case NFA_END_INVISIBLE: STRCPY(code, "NFA_END_INVISIBLE"); break; + +--- 1740,1747 ---- + STRCPY(code, "NFA_PREV_ATOM_NO_WIDTH"); break; + case NFA_PREV_ATOM_NO_WIDTH_NEG: + STRCPY(code, "NFA_PREV_ATOM_NO_WIDTH_NEG"); break; +! case NFA_NOPEN: STRCPY(code, "NFA_NOPEN"); break; +! case NFA_NCLOSE: STRCPY(code, "NFA_NCLOSE"); break; + case NFA_START_INVISIBLE: STRCPY(code, "NFA_START_INVISIBLE"); break; + case NFA_END_INVISIBLE: STRCPY(code, "NFA_END_INVISIBLE"); break; + +*************** +*** 2373,2384 **** + break; + + case NFA_PREV_ATOM_NO_WIDTH: +! /* The \@= operator: match the preceding atom with 0 width. + * Surrounds the preceding atom with START_INVISIBLE and +! * END_INVISIBLE, similarly to MOPEN. +! */ +! /* TODO: Maybe this drops the speed? */ +! goto theend; + + if (nfa_calc_size == TRUE) + { +--- 2373,2381 ---- + break; + + case NFA_PREV_ATOM_NO_WIDTH: +! /* The \@= operator: match the preceding atom with zero width. + * Surrounds the preceding atom with START_INVISIBLE and +! * END_INVISIBLE, similarly to MOPEN. */ + + if (nfa_calc_size == TRUE) + { +*************** +*** 2745,2750 **** +--- 2742,2750 ---- + int save_in_use; + char_u *save_ptr; + int i; ++ #ifdef ENABLE_LOG ++ int did_print = FALSE; ++ #endif + + if (l == NULL || state == NULL) + return; +*************** +*** 2782,2788 **** + /* These nodes do not need to be added, but we need to bail out + * when it was tried to be added to this list before. */ + if (state->lastlist == l->id) +! return; + state->lastlist = l->id; + break; + +--- 2782,2788 ---- + /* These nodes do not need to be added, but we need to bail out + * when it was tried to be added to this list before. */ + if (state->lastlist == l->id) +! goto skip_add; + state->lastlist = l->id; + break; + +*************** +*** 2792,2798 **** +--- 2792,2806 ---- + /* This state is already in the list, don't add it again, + * unless it is an MOPEN that is used for a backreference. */ + if (!nfa_has_backref) ++ { ++ skip_add: ++ #ifdef ENABLE_LOG ++ nfa_set_code(state->c); ++ fprintf(log_fd, "> Not adding state %d to list %d. char %d: %s\n", ++ abs(state->id), l->id, state->c, code); ++ #endif + return; ++ } + + /* See if the same state is already in the list with the same + * positions. */ +*************** +*** 2801,2807 **** + thread = &l->t[i]; + if (thread->state->id == state->id + && sub_equal(&thread->sub, sub)) +! return; + } + } + +--- 2809,2815 ---- + thread = &l->t[i]; + if (thread->state->id == state->id + && sub_equal(&thread->sub, sub)) +! goto skip_add; + } + } + +*************** +*** 2832,2843 **** + &sub->list.line[0], + sizeof(struct linepos) * sub->in_use); + } + } + + #ifdef ENABLE_LOG +! nfa_set_code(state->c); +! fprintf(log_fd, "> Adding state %d to list. Character %d: %s\n", +! abs(state->id), state->c, code); + #endif + switch (state->c) + { +--- 2840,2878 ---- + &sub->list.line[0], + sizeof(struct linepos) * sub->in_use); + } ++ #ifdef ENABLE_LOG ++ { ++ int col; ++ ++ if (thread->sub.in_use <= 0) ++ col = -1; ++ else if (REG_MULTI) ++ col = thread->sub.list.multi[0].start.col; ++ else ++ col = (int)(thread->sub.list.line[0].start - regline); ++ nfa_set_code(state->c); ++ fprintf(log_fd, "> Adding state %d to list %d. char %d: %s (start col %d)\n", ++ abs(state->id), l->id, state->c, code, col); ++ did_print = TRUE; ++ } ++ #endif + } + + #ifdef ENABLE_LOG +! if (!did_print) +! { +! int col; +! +! if (sub->in_use <= 0) +! col = -1; +! else if (REG_MULTI) +! col = sub->list.multi[0].start.col; +! else +! col = (int)(sub->list.line[0].start - regline); +! nfa_set_code(state->c); +! fprintf(log_fd, "> Processing state %d for list %d. char %d: %s (start col %d)\n", +! abs(state->id), l->id, state->c, code, col); +! } + #endif + switch (state->c) + { +*************** +*** 2873,2886 **** + addstate(l, state->out, sub, off); + break; + +- /* If this state is reached, then a recursive call of nfa_regmatch() +- * succeeded. the next call saves the found submatches in the +- * first state after the "invisible" branch. */ +- #if 0 +- case NFA_END_INVISIBLE: +- break; +- #endif +- + case NFA_MOPEN + 0: + case NFA_MOPEN + 1: + case NFA_MOPEN + 2: +--- 2908,2913 ---- +*************** +*** 3450,3458 **** + fprintf(debug, "%s, ", code); + #endif + #ifdef ENABLE_LOG +! nfa_set_code(t->state->c); +! fprintf(log_fd, "(%d) %s, code %d ... \n", abs(t->state->id), +! code, (int)t->state->c); + #endif + + /* +--- 3477,3495 ---- + fprintf(debug, "%s, ", code); + #endif + #ifdef ENABLE_LOG +! { +! int col; +! +! if (t->sub.in_use <= 0) +! col = -1; +! else if (REG_MULTI) +! col = t->sub.list.multi[0].start.col; +! else +! col = (int)(t->sub.list.line[0].start - regline); +! nfa_set_code(t->state->c); +! fprintf(log_fd, "(%d) char %d %s (start col %d) ... \n", +! abs(t->state->id), (int)t->state->c, code, col); +! } + #endif + + /* +*************** +*** 3504,3509 **** +--- 3541,3547 ---- + addstate_here(thislist, t->state->out, &t->sub, &listidx); + else + { ++ /* TODO: only copy positions in use. */ + *m = t->sub; + nfa_match = TRUE; + } +*************** +*** 3538,3543 **** +--- 3576,3582 ---- + result = nfa_regmatch(t->state->out, submatch, m); + nfa_set_neg_listids(start); + nfa_restore_listids(start, listids); ++ nfa_match = FALSE; + + #ifdef ENABLE_LOG + log_fd = fopen(NFA_REGEXP_RUN_LOG, "a"); +*************** +*** 3575,3583 **** + t->sub.list.line[j].start = m->list.line[j].start; + t->sub.list.line[j].end = m->list.line[j].end; + } +! t->sub.in_use = m->in_use; + +! /* t->state->out1 is the corresponding END_INVISIBLE node */ + addstate_here(thislist, t->state->out1->out, &t->sub, + &listidx); + } +--- 3614,3624 ---- + t->sub.list.line[j].start = m->list.line[j].start; + t->sub.list.line[j].end = m->list.line[j].end; + } +! if (m->in_use > t->sub.in_use) +! t->sub.in_use = m->in_use; + +! /* t->state->out1 is the corresponding END_INVISIBLE node; +! * Add it to the current list (zero-width match). */ + addstate_here(thislist, t->state->out1->out, &t->sub, + &listidx); + } +*************** +*** 4146,4152 **** + fprintf(f, "\tRegexp is \"%s\"\n", nfa_regengine.expr); + #endif + fprintf(f, "\tInput text is \"%s\" \n", reginput); +! fprintf(f, " =======================================================\n\n\n\n\n\n\n"); + nfa_print_state(f, start); + fprintf(f, "\n\n"); + fclose(f); +--- 4187,4193 ---- + fprintf(f, "\tRegexp is \"%s\"\n", nfa_regengine.expr); + #endif + fprintf(f, "\tInput text is \"%s\" \n", reginput); +! fprintf(f, " =======================================================\n\n"); + nfa_print_state(f, start); + fprintf(f, "\n\n"); + fclose(f); +*** ../vim-7.3.1075/src/testdir/test64.in 2013-05-30 18:45:20.000000000 +0200 +--- src/testdir/test64.in 2013-05-30 21:28:06.000000000 +0200 +*************** +*** 294,315 **** + :call add(tl, [2, '\v(a \zsif .*){2}', 'a if then a if last', 'if last', 'a if last']) + :call add(tl, [2, '\>\zs.', 'aword. ', '.']) + :" +! :"""" Tests for \@ features +! :call add(tl, [0, 'abc\@=', 'abc', 'ab']) +! :call add(tl, [0, 'abc\@=cd', 'abcd', 'abcd']) +! :call add(tl, [0, 'abc\@=', 'ababc', 'ab']) + :" will never match, no matter the input text + :call add(tl, [2, 'abcd\@=e', 'abcd']) + :" will never match + :call add(tl, [2, 'abcd\@=e', 'any text in here ... ']) +! :call add(tl, [0, '\v(abc)@=..', 'xabcd', 'ab', 'abc']) + :" no match + :call add(tl, [2, '\(.*John\)\@=.*Bob', 'here is John, and here is B']) +! :call add(tl, [0, '\(John.*\)\@=.*Bob', 'John is Bobs friend', 'John is Bob', 'John is Bobs friend']) + :" no match + :call add(tl, [2, '.*John\&.*Bob', 'here is John, and here is B']) +! :call add(tl, [0, '.*John\&.*Bob', 'John is Bobs friend', 'John is Bob']) +! :call add(tl, [0, '\v(test1)@=.*yep', 'this is a test1, yep it is', 'test1, yep', 'test1']) + :" + :"""" Combining different tests and features + :call add(tl, [2, '[[:alpha:]]\{-2,6}', '787abcdiuhsasiuhb4', 'ab']) +--- 294,315 ---- + :call add(tl, [2, '\v(a \zsif .*){2}', 'a if then a if last', 'if last', 'a if last']) + :call add(tl, [2, '\>\zs.', 'aword. ', '.']) + :" +! :"""" Tests for \@= and \& features +! :call add(tl, [2, 'abc\@=', 'abc', 'ab']) +! :call add(tl, [2, 'abc\@=cd', 'abcd', 'abcd']) +! :call add(tl, [2, 'abc\@=', 'ababc', 'ab']) + :" will never match, no matter the input text + :call add(tl, [2, 'abcd\@=e', 'abcd']) + :" will never match + :call add(tl, [2, 'abcd\@=e', 'any text in here ... ']) +! :call add(tl, [2, '\v(abc)@=..', 'xabcd', 'ab', 'abc']) + :" no match + :call add(tl, [2, '\(.*John\)\@=.*Bob', 'here is John, and here is B']) +! :call add(tl, [2, '\(John.*\)\@=.*Bob', 'John is Bobs friend', 'John is Bob', 'John is Bobs friend']) + :" no match + :call add(tl, [2, '.*John\&.*Bob', 'here is John, and here is B']) +! :call add(tl, [2, '.*John\&.*Bob', 'John is Bobs friend', 'John is Bob']) +! :call add(tl, [2, '\v(test1)@=.*yep', 'this is a test1, yep it is', 'test1, yep', 'test1']) + :" + :"""" Combining different tests and features + :call add(tl, [2, '[[:alpha:]]\{-2,6}', '787abcdiuhsasiuhb4', 'ab']) +*** ../vim-7.3.1075/src/testdir/test64.ok 2013-05-30 18:45:20.000000000 +0200 +--- src/testdir/test64.ok 2013-05-30 21:29:06.000000000 +0200 +*************** +*** 647,656 **** +--- 647,659 ---- + OK 2 - \>\zs. + OK 0 - abc\@= + OK 1 - abc\@= ++ OK 2 - abc\@= + OK 0 - abc\@=cd + OK 1 - abc\@=cd ++ OK 2 - abc\@=cd + OK 0 - abc\@= + OK 1 - abc\@= ++ OK 2 - abc\@= + OK 0 - abcd\@=e + OK 1 - abcd\@=e + OK 2 - abcd\@=e +*************** +*** 659,676 **** +--- 662,683 ---- + OK 2 - abcd\@=e + OK 0 - \v(abc)@=.. + OK 1 - \v(abc)@=.. ++ OK 2 - \v(abc)@=.. + OK 0 - \(.*John\)\@=.*Bob + OK 1 - \(.*John\)\@=.*Bob + OK 2 - \(.*John\)\@=.*Bob + OK 0 - \(John.*\)\@=.*Bob + OK 1 - \(John.*\)\@=.*Bob ++ OK 2 - \(John.*\)\@=.*Bob + OK 0 - .*John\&.*Bob + OK 1 - .*John\&.*Bob + OK 2 - .*John\&.*Bob + OK 0 - .*John\&.*Bob + OK 1 - .*John\&.*Bob ++ OK 2 - .*John\&.*Bob + OK 0 - \v(test1)@=.*yep + OK 1 - \v(test1)@=.*yep ++ OK 2 - \v(test1)@=.*yep + OK 0 - [[:alpha:]]\{-2,6} + OK 1 - [[:alpha:]]\{-2,6} + OK 2 - [[:alpha:]]\{-2,6} +*** ../vim-7.3.1075/src/version.c 2013-05-30 19:18:27.000000000 +0200 +--- src/version.c 2013-05-30 21:34:53.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1076, + /**/ + +-- +I'm not familiar with this proof, but I'm aware of a significant +following of toddlers who believe that peanut butter is the solution +to all of life's problems... -- Tim Hammerquist + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 52e1e875fc57e0079acaf859e1cfa8397bf45ff3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:40 +0200 Subject: [PATCH 0968/3340] - patchlevel 1077 --- 7.3.1077 | 462 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 462 insertions(+) create mode 100644 7.3.1077 diff --git a/7.3.1077 b/7.3.1077 new file mode 100644 index 00000000..3006835e --- /dev/null +++ b/7.3.1077 @@ -0,0 +1,462 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1077 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1077 +Problem: Python: Allocating dict the wrong way, causing a crash. +Solution: Use py_dict_alloc(). Fix some exception problems. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1076/src/if_py_both.h 2013-05-30 19:01:20.000000000 +0200 +--- src/if_py_both.h 2013-05-30 21:53:00.000000000 +0200 +*************** +*** 26,56 **** + + #define PyErr_SetVim(str) PyErr_SetString(VimError, str) + + #define INVALID_BUFFER_VALUE ((buf_T *)(-1)) + #define INVALID_WINDOW_VALUE ((win_T *)(-1)) + #define INVALID_TABPAGE_VALUE ((tabpage_T *)(-1)) + +- #define DICTKEY_DECL \ +- PyObject *dictkey_todecref = NULL; +- #define DICTKEY_GET(err, decref) \ +- if (!(key = StringToChars(keyObject, &dictkey_todecref))) \ +- { \ +- if (decref) \ +- { \ +- Py_DECREF(keyObject); \ +- } \ +- return err; \ +- } \ +- if (decref && !dictkey_todecref) \ +- dictkey_todecref = keyObject; \ +- if (*key == NUL) \ +- { \ +- PyErr_SetString(PyExc_ValueError, _("empty keys are not allowed")); \ +- return err; \ +- } +- #define DICTKEY_UNREF \ +- Py_XDECREF(dictkey_todecref); +- + typedef void (*rangeinitializer)(void *); + typedef void (*runner)(const char *, void * + #ifdef PY_CAN_RECURSE +--- 26,38 ---- + + #define PyErr_SetVim(str) PyErr_SetString(VimError, str) + ++ #define RAISE_NO_EMPTY_KEYS PyErr_SetString(PyExc_ValueError, \ ++ _("empty keys are not allowed")) ++ + #define INVALID_BUFFER_VALUE ((buf_T *)(-1)) + #define INVALID_WINDOW_VALUE ((win_T *)(-1)) + #define INVALID_TABPAGE_VALUE ((tabpage_T *)(-1)) + + typedef void (*rangeinitializer)(void *); + typedef void (*runner)(const char *, void * + #ifdef PY_CAN_RECURSE +*************** +*** 1016,1023 **** + dictitem_T *di; + dict_T *dict = self->dict; + hashitem_T *hi; +! +! DICTKEY_DECL + + if (flags & DICT_FLAG_HAS_DEFAULT) + { +--- 998,1004 ---- + dictitem_T *di; + dict_T *dict = self->dict; + hashitem_T *hi; +! PyObject *todecref; + + if (flags & DICT_FLAG_HAS_DEFAULT) + { +*************** +*** 1030,1040 **** + if (flags & DICT_FLAG_RETURN_BOOL) + defObject = Py_False; + +! DICTKEY_GET(NULL, 0) + + hi = hash_find(&dict->dv_hashtab, key); + +! DICTKEY_UNREF + + if (HASHITEM_EMPTY(hi)) + { +--- 1011,1028 ---- + if (flags & DICT_FLAG_RETURN_BOOL) + defObject = Py_False; + +! if (!(key = StringToChars(keyObject, &todecref))) +! return NULL; +! +! if (*key == NUL) +! { +! RAISE_NO_EMPTY_KEYS; +! return NULL; +! } + + hi = hash_find(&dict->dv_hashtab, key); + +! Py_XDECREF(todecref); + + if (HASHITEM_EMPTY(hi)) + { +*************** +*** 1173,1179 **** + typval_T tv; + dict_T *dict = self->dict; + dictitem_T *di; +! DICTKEY_DECL + + if (dict->dv_lock) + { +--- 1161,1167 ---- + typval_T tv; + dict_T *dict = self->dict; + dictitem_T *di; +! PyObject *todecref; + + if (dict->dv_lock) + { +*************** +*** 1181,1187 **** + return -1; + } + +! DICTKEY_GET(-1, 0) + + di = dict_find(dict, key, -1); + +--- 1169,1181 ---- + return -1; + } + +! if (!(key = StringToChars(keyObject, &todecref))) +! return -1; +! if (*key == NUL) +! { +! RAISE_NO_EMPTY_KEYS; +! return -1; +! } + + di = dict_find(dict, key, -1); + +*************** +*** 1191,1197 **** + + if (di == NULL) + { +! DICTKEY_UNREF + PyErr_SetObject(PyExc_KeyError, keyObject); + return -1; + } +--- 1185,1191 ---- + + if (di == NULL) + { +! Py_XDECREF(todecref); + PyErr_SetObject(PyExc_KeyError, keyObject); + return -1; + } +*************** +*** 1208,1213 **** +--- 1202,1208 ---- + { + if (!(di = dictitem_alloc(key))) + { ++ Py_XDECREF(todecref); + PyErr_NoMemory(); + return -1; + } +*************** +*** 1216,1222 **** + + if (dict_add(dict, di) == FAIL) + { +! DICTKEY_UNREF + vim_free(di); + dictitem_free(di); + PyErr_SetVim(_("failed to add key to dictionary")); +--- 1211,1217 ---- + + if (dict_add(dict, di) == FAIL) + { +! Py_XDECREF(todecref); + vim_free(di); + dictitem_free(di); + PyErr_SetVim(_("failed to add key to dictionary")); +*************** +*** 1226,1232 **** + else + clear_tv(&di->di_tv); + +! DICTKEY_UNREF + + copy_tv(&tv, &di->di_tv); + clear_tv(&tv); +--- 1221,1227 ---- + else + clear_tv(&di->di_tv); + +! Py_XDECREF(todecref); + + copy_tv(&tv, &di->di_tv); + clear_tv(&tv); +*************** +*** 2202,2218 **** + int flags; + long numval; + char_u *stringval; +! DICTKEY_DECL + + if (self->Check(self->from)) + return NULL; + +! DICTKEY_GET(NULL, 0) + + flags = get_option_value_strict(key, &numval, &stringval, + self->opt_type, self->from); + +! DICTKEY_UNREF + + if (flags == 0) + { +--- 2197,2219 ---- + int flags; + long numval; + char_u *stringval; +! PyObject *todecref; + + if (self->Check(self->from)) + return NULL; + +! if (!(key = StringToChars(keyObject, &todecref))) +! return NULL; +! if (*key == NUL) +! { +! RAISE_NO_EMPTY_KEYS; +! return NULL; +! } + + flags = get_option_value_strict(key, &numval, &stringval, + self->opt_type, self->from); + +! Py_XDECREF(todecref); + + if (flags == 0) + { +*************** +*** 2329,2340 **** + int flags; + int opt_flags; + int r = 0; +! DICTKEY_DECL + + if (self->Check(self->from)) + return -1; + +! DICTKEY_GET(-1, 0) + + flags = get_option_value_strict(key, NULL, NULL, + self->opt_type, self->from); +--- 2330,2347 ---- + int flags; + int opt_flags; + int r = 0; +! PyObject *todecref; + + if (self->Check(self->from)) + return -1; + +! if (!(key = StringToChars(keyObject, &todecref))) +! return -1; +! if (*key == NUL) +! { +! RAISE_NO_EMPTY_KEYS; +! return -1; +! } + + flags = get_option_value_strict(key, NULL, NULL, + self->opt_type, self->from); +*************** +*** 2342,2348 **** + if (flags == 0) + { + PyErr_SetObject(PyExc_KeyError, keyObject); +! DICTKEY_UNREF + return -1; + } + +--- 2349,2355 ---- + if (flags == 0) + { + PyErr_SetObject(PyExc_KeyError, keyObject); +! Py_XDECREF(todecref); + return -1; + } + +*************** +*** 2352,2371 **** + { + PyErr_SetString(PyExc_ValueError, + _("unable to unset global option")); +! DICTKEY_UNREF + return -1; + } + else if (!(flags & SOPT_GLOBAL)) + { + PyErr_SetString(PyExc_ValueError, _("unable to unset option " + "without global value")); +! DICTKEY_UNREF + return -1; + } + else + { + unset_global_local_option(key, self->from); +! DICTKEY_UNREF + return 0; + } + } +--- 2359,2378 ---- + { + PyErr_SetString(PyExc_ValueError, + _("unable to unset global option")); +! Py_XDECREF(todecref); + return -1; + } + else if (!(flags & SOPT_GLOBAL)) + { + PyErr_SetString(PyExc_ValueError, _("unable to unset option " + "without global value")); +! Py_XDECREF(todecref); + return -1; + } + else + { + unset_global_local_option(key, self->from); +! Py_XDECREF(todecref); + return 0; + } + } +*************** +*** 2396,2402 **** + else + { + PyErr_SetString(PyExc_TypeError, _("object must be integer")); +! DICTKEY_UNREF + return -1; + } + +--- 2403,2409 ---- + else + { + PyErr_SetString(PyExc_TypeError, _("object must be integer")); +! Py_XDECREF(todecref); + return -1; + } + +*************** +*** 2418,2424 **** + r = -1; + } + +! DICTKEY_UNREF + + return r; + } +--- 2425,2431 ---- + r = -1; + } + +! Py_XDECREF(todecref); + + return r; + } +*************** +*** 4528,4534 **** + PyObject *valObject; + Py_ssize_t iter = 0; + +! if (!(dict = dict_alloc())) + return -1; + + tv->v_type = VAR_DICT; +--- 4535,4541 ---- + PyObject *valObject; + Py_ssize_t iter = 0; + +! if (!(dict = py_dict_alloc())) + return -1; + + tv->v_type = VAR_DICT; +*************** +*** 4553,4558 **** +--- 4560,4566 ---- + { + dict_unref(dict); + Py_XDECREF(todecref); ++ RAISE_NO_EMPTY_KEYS; + return -1; + } + +*************** +*** 4600,4606 **** + PyObject *keyObject; + PyObject *valObject; + +! if (!(dict = dict_alloc())) + return -1; + + tv->v_type = VAR_DICT; +--- 4608,4614 ---- + PyObject *keyObject; + PyObject *valObject; + +! if (!(dict = py_dict_alloc())) + return -1; + + tv->v_type = VAR_DICT; +*************** +*** 4637,4642 **** +--- 4645,4651 ---- + Py_DECREF(iterator); + Py_XDECREF(todecref); + dict_unref(dict); ++ RAISE_NO_EMPTY_KEYS; + return -1; + } + +*** ../vim-7.3.1076/src/version.c 2013-05-30 21:42:09.000000000 +0200 +--- src/version.c 2013-05-30 21:49:50.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1077, + /**/ + +-- +The History of every major Galactic Civilization tends to pass through +three distinct and recognizable phases, those of Survival, Inquiry and +Sophistication, otherwise known as the How, Why and Where phases. +For instance, the first phase is characterized by the question 'How can +we eat?' the second by the question 'Why do we eat?' and the third by +the question 'Where shall we have lunch?' + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 55c6006752b3b8776251100063bb697668ad8efb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:40 +0200 Subject: [PATCH 0969/3340] - patchlevel 1078 --- 7.3.1078 | 205 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 205 insertions(+) create mode 100644 7.3.1078 diff --git a/7.3.1078 b/7.3.1078 new file mode 100644 index 00000000..e34f0fc3 --- /dev/null +++ b/7.3.1078 @@ -0,0 +1,205 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1078 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1078 +Problem: New regexp engine: \@! doesn't work. +Solution: Implement the negated version of \@=. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1077/src/regexp_nfa.c 2013-05-30 21:42:09.000000000 +0200 +--- src/regexp_nfa.c 2013-05-30 22:39:40.000000000 +0200 +*************** +*** 1390,1395 **** +--- 1390,1398 ---- + case '=': + EMIT(NFA_PREV_ATOM_NO_WIDTH); + break; ++ case '!': ++ EMIT(NFA_PREV_ATOM_NO_WIDTH_NEG); ++ break; + case '0': + case '1': + case '2': +*************** +*** 1400,1406 **** + case '7': + case '8': + case '9': +- case '!': + case '<': + case '>': + /* Not supported yet */ +--- 1403,1408 ---- +*************** +*** 2373,2379 **** +--- 2375,2383 ---- + break; + + case NFA_PREV_ATOM_NO_WIDTH: ++ case NFA_PREV_ATOM_NO_WIDTH_NEG: + /* The \@= operator: match the preceding atom with zero width. ++ * The \@! operator: no match for the preceding atom. + * Surrounds the preceding atom with START_INVISIBLE and + * END_INVISIBLE, similarly to MOPEN. */ + +*************** +*** 2391,2396 **** +--- 2395,2406 ---- + s = new_state(NFA_START_INVISIBLE, e.start, s1); + if (s == NULL) + goto theend; ++ if (*p == NFA_PREV_ATOM_NO_WIDTH_NEG) ++ { ++ s->negated = TRUE; ++ s1->negated = TRUE; ++ } ++ + PUSH(frag(s, list1(&s1->out))); + break; + +*************** +*** 3541,3548 **** + addstate_here(thislist, t->state->out, &t->sub, &listidx); + else + { +! /* TODO: only copy positions in use. */ +! *m = t->sub; + nfa_match = TRUE; + } + break; +--- 3551,3560 ---- + addstate_here(thislist, t->state->out, &t->sub, &listidx); + else + { +! /* do not set submatches for \@! */ +! if (!t->state->negated) +! /* TODO: only copy positions in use. */ +! *m = t->sub; + nfa_match = TRUE; + } + break; +*************** +*** 3593,3599 **** + log_fd = stderr; + } + #endif +! if (result == TRUE) + { + int j; + +--- 3605,3612 ---- + log_fd = stderr; + } + #endif +! /* for \@! it is a match when result is FALSE */ +! if (result != t->state->negated) + { + int j; + +*** ../vim-7.3.1077/src/testdir/test64.in 2013-05-30 21:42:09.000000000 +0200 +--- src/testdir/test64.in 2013-05-30 22:41:38.000000000 +0200 +*************** +*** 303,315 **** + :" will never match + :call add(tl, [2, 'abcd\@=e', 'any text in here ... ']) + :call add(tl, [2, '\v(abc)@=..', 'xabcd', 'ab', 'abc']) +- :" no match + :call add(tl, [2, '\(.*John\)\@=.*Bob', 'here is John, and here is B']) + :call add(tl, [2, '\(John.*\)\@=.*Bob', 'John is Bobs friend', 'John is Bob', 'John is Bobs friend']) +- :" no match + :call add(tl, [2, '.*John\&.*Bob', 'here is John, and here is B']) + :call add(tl, [2, '.*John\&.*Bob', 'John is Bobs friend', 'John is Bob']) + :call add(tl, [2, '\v(test1)@=.*yep', 'this is a test1, yep it is', 'test1, yep', 'test1']) + :" + :"""" Combining different tests and features + :call add(tl, [2, '[[:alpha:]]\{-2,6}', '787abcdiuhsasiuhb4', 'ab']) +--- 303,322 ---- + :" will never match + :call add(tl, [2, 'abcd\@=e', 'any text in here ... ']) + :call add(tl, [2, '\v(abc)@=..', 'xabcd', 'ab', 'abc']) + :call add(tl, [2, '\(.*John\)\@=.*Bob', 'here is John, and here is B']) + :call add(tl, [2, '\(John.*\)\@=.*Bob', 'John is Bobs friend', 'John is Bob', 'John is Bobs friend']) + :call add(tl, [2, '.*John\&.*Bob', 'here is John, and here is B']) + :call add(tl, [2, '.*John\&.*Bob', 'John is Bobs friend', 'John is Bob']) + :call add(tl, [2, '\v(test1)@=.*yep', 'this is a test1, yep it is', 'test1, yep', 'test1']) ++ :call add(tl, [2, 'foo\(bar\)\@!', 'foobar']) ++ :call add(tl, [2, 'foo\(bar\)\@!', 'foo bar', 'foo']) ++ :call add(tl, [2, 'if \(\(then\)\@!.\)*$', ' if then else']) ++ :call add(tl, [2, 'if \(\(then\)\@!.\)*$', ' if else ', 'if else ', ' ']) ++ :call add(tl, [2, '\(foo\)\@!bar', 'foobar', 'bar']) ++ :call add(tl, [2, '\(foo\)\@!...bar', 'foobar']) ++ :call add(tl, [2, '^\%(.*bar\)\@!.*\zsfoo', ' bar foo ']) ++ :call add(tl, [2, '^\%(.*bar\)\@!.*\zsfoo', ' foo bar ']) ++ :call add(tl, [2, '^\%(.*bar\)\@!.*\zsfoo', ' foo xxx ', 'foo']) + :" + :"""" Combining different tests and features + :call add(tl, [2, '[[:alpha:]]\{-2,6}', '787abcdiuhsasiuhb4', 'ab']) +*** ../vim-7.3.1077/src/testdir/test64.ok 2013-05-30 21:42:09.000000000 +0200 +--- src/testdir/test64.ok 2013-05-30 22:42:02.000000000 +0200 +*************** +*** 678,683 **** +--- 678,710 ---- + OK 0 - \v(test1)@=.*yep + OK 1 - \v(test1)@=.*yep + OK 2 - \v(test1)@=.*yep ++ OK 0 - foo\(bar\)\@! ++ OK 1 - foo\(bar\)\@! ++ OK 2 - foo\(bar\)\@! ++ OK 0 - foo\(bar\)\@! ++ OK 1 - foo\(bar\)\@! ++ OK 2 - foo\(bar\)\@! ++ OK 0 - if \(\(then\)\@!.\)*$ ++ OK 1 - if \(\(then\)\@!.\)*$ ++ OK 2 - if \(\(then\)\@!.\)*$ ++ OK 0 - if \(\(then\)\@!.\)*$ ++ OK 1 - if \(\(then\)\@!.\)*$ ++ OK 2 - if \(\(then\)\@!.\)*$ ++ OK 0 - \(foo\)\@!bar ++ OK 1 - \(foo\)\@!bar ++ OK 2 - \(foo\)\@!bar ++ OK 0 - \(foo\)\@!...bar ++ OK 1 - \(foo\)\@!...bar ++ OK 2 - \(foo\)\@!...bar ++ OK 0 - ^\%(.*bar\)\@!.*\zsfoo ++ OK 1 - ^\%(.*bar\)\@!.*\zsfoo ++ OK 2 - ^\%(.*bar\)\@!.*\zsfoo ++ OK 0 - ^\%(.*bar\)\@!.*\zsfoo ++ OK 1 - ^\%(.*bar\)\@!.*\zsfoo ++ OK 2 - ^\%(.*bar\)\@!.*\zsfoo ++ OK 0 - ^\%(.*bar\)\@!.*\zsfoo ++ OK 1 - ^\%(.*bar\)\@!.*\zsfoo ++ OK 2 - ^\%(.*bar\)\@!.*\zsfoo + OK 0 - [[:alpha:]]\{-2,6} + OK 1 - [[:alpha:]]\{-2,6} + OK 2 - [[:alpha:]]\{-2,6} +*** ../vim-7.3.1077/src/version.c 2013-05-30 22:06:28.000000000 +0200 +--- src/version.c 2013-05-30 22:42:59.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1078, + /**/ + +-- +The startling truth finally became apparent, and it was this: Numbers +written on restaurant checks within the confines of restaurants do not follow +the same mathematical laws as numbers written on any other pieces of paper in +any other parts of the Universe. This single statement took the scientific +world by storm. So many mathematical conferences got held in such good +restaurants that many of the finest minds of a generation died of obesity and +heart failure, and the science of mathematics was put back by years. + -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0d3371ed4a570d1c9362944c100ea9d9a63e9bbb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:41 +0200 Subject: [PATCH 0970/3340] - patchlevel 1079 --- 7.3.1079 | 832 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 832 insertions(+) create mode 100644 7.3.1079 diff --git a/7.3.1079 b/7.3.1079 new file mode 100644 index 00000000..8b07dbc3 --- /dev/null +++ b/7.3.1079 @@ -0,0 +1,832 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1079 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1079 +Problem: Test 87 fails. +Solution: Fix the test for Python 3.3. (ZyX) Make it pass on 32 bit systems. +Files: src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.1078/src/testdir/test87.in 2013-05-30 15:38:20.000000000 +0200 +--- src/testdir/test87.in 2013-05-31 18:40:40.000000000 +0200 +*************** +*** 2,9 **** + + STARTTEST + :so small.vim +- :" HACK: currently crashes, skip the test +- :e! test.ok | wq! test.out + :if !has('python3') | e! test.ok | wq! test.out | endif + :lang C + :py3 import vim +--- 2,7 ---- +*************** +*** 710,719 **** + :" + :" Test stdout/stderr + :redir => messages +! :py sys.stdout.write('abc') ; sys.stdout.write('def') +! :py sys.stderr.write('abc') ; sys.stderr.write('def') +! :py sys.stdout.writelines(iter('abc')) +! :py sys.stderr.writelines(iter('abc')) + :redir END + :$put =string(substitute(messages, '\d\+', '', 'g')) + :" Test subclassing +--- 708,717 ---- + :" + :" Test stdout/stderr + :redir => messages +! :py3 sys.stdout.write('abc') ; sys.stdout.write('def') +! :py3 sys.stderr.write('abc') ; sys.stderr.write('def') +! :py3 sys.stdout.writelines(iter('abc')) +! :py3 sys.stderr.writelines(iter('abc')) + :redir END + :$put =string(substitute(messages, '\d\+', '', 'g')) + :" Test subclassing +*************** +*** 759,765 **** + try: + exec(expr, g, l) + except Exception as e: +! cb.append(expr + ':' + repr((e.__class__, e))) + else: + cb.append(expr + ':NOT FAILED') + except Exception as e: +--- 757,766 ---- + try: + exec(expr, g, l) + except Exception as e: +! if sys.version_info >= (3, 3) and e.__class__ is AttributeError and str(e).find('has no attribute')>=0 and not str(e).startswith("'vim."): +! cb.append(expr + ':' + repr((e.__class__, AttributeError(str(e)[str(e).rfind(" '") + 2:-1])))) +! else: +! cb.append(expr + ':' + repr((e.__class__, e))) + else: + cb.append(expr + ':NOT FAILED') + except Exception as e: +*************** +*** 786,793 **** + def stringtochars_test(expr): + return subexpr_test(expr, 'StringToChars', ( + '1', # Fail type checks +! 'u"\\0"', # Fail PyString_AsStringAndSize(bytes, , NULL) check +! '"\\0"', # Fail PyString_AsStringAndSize(object, , NULL) check + )) + + class Mapping(object): +--- 787,794 ---- + def stringtochars_test(expr): + return subexpr_test(expr, 'StringToChars', ( + '1', # Fail type checks +! 'b"\\0"', # Fail PyString_AsStringAndSize(object, , NULL) check +! '"\\0"', # Fail PyString_AsStringAndSize(bytes, , NULL) check + )) + + class Mapping(object): +*************** +*** 968,974 **** + ee('vim.current.window.xxx') + cb.append(">> WindowSetattr") + ee('vim.current.window.buffer = 0') +! ee('vim.current.window.cursor = (10000000000, 100000000)') + ee('vim.current.window.cursor = True') + ee('vim.current.window.height = "abc"') + ee('vim.current.window.width = "abc"') +--- 969,975 ---- + ee('vim.current.window.xxx') + cb.append(">> WindowSetattr") + ee('vim.current.window.buffer = 0') +! ee('vim.current.window.cursor = (100000000, 100000000)') + ee('vim.current.window.cursor = True') + ee('vim.current.window.height = "abc"') + ee('vim.current.window.width = "abc"') +*************** +*** 989,997 **** + ee('vim.current.buffer.append(["\\na", "bc"])') + ee('vim.current.buffer.append("\\nbc")') + cb.append(">> RBItem") +! ee('vim.current.buffer[10000000000]') + cb.append(">> RBAsItem") +! ee('vim.current.buffer[10000000000] = ""') + cb.append(">> BufferAttr") + ee('vim.current.buffer.xxx') + cb.append(">> BufferSetattr") +--- 990,998 ---- + ee('vim.current.buffer.append(["\\na", "bc"])') + ee('vim.current.buffer.append("\\nbc")') + cb.append(">> RBItem") +! ee('vim.current.buffer[100000000]') + cb.append(">> RBAsItem") +! ee('vim.current.buffer[100000000] = ""') + cb.append(">> BufferAttr") + ee('vim.current.buffer.xxx') + cb.append(">> BufferSetattr") +*** ../vim-7.3.1078/src/testdir/test87.ok 2013-05-30 13:37:23.000000000 +0200 +--- src/testdir/test87.ok 2013-05-31 18:41:15.000000000 +0200 +*************** +*** 454,460 **** + d.get("a", 2, 3):(, TypeError('function takes at most 2 arguments (3 given)',)) + >>> Testing StringToChars using d.get(%s) + d.get(1):(, TypeError('object must be string',)) +! d.get(u"\0"):(, TypeError('expected bytes with no null',)) + d.get("\0"):(, TypeError('expected bytes with no null',)) + <<< Finished + d.pop("a"):(, KeyError('a',)) +--- 454,460 ---- + d.get("a", 2, 3):(, TypeError('function takes at most 2 arguments (3 given)',)) + >>> Testing StringToChars using d.get(%s) + d.get(1):(, TypeError('object must be string',)) +! d.get(b"\0"):(, TypeError('expected bytes with no null',)) + d.get("\0"):(, TypeError('expected bytes with no null',)) + <<< Finished + d.pop("a"):(, KeyError('a',)) +*************** +*** 465,486 **** + dl["b"] = 1:(, error('dict is locked',)) + >>> Testing StringToChars using d[%s] = 1 + d[1] = 1:(, TypeError('object must be string',)) +! d[u"\0"] = 1:(, TypeError('expected bytes with no null',)) + d["\0"] = 1:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = {%s : 1} + d["a"] = {1 : 1}:(, TypeError('object must be string',)) +! d["a"] = {u"\0" : 1}:(, TypeError('expected bytes with no null',)) + d["a"] = {"\0" : 1}:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : {%s : 1}} + d["a"] = {"abc" : {1 : 1}}:(, TypeError('object must be string',)) +! d["a"] = {"abc" : {u"\0" : 1}}:(, TypeError('expected bytes with no null',)) + d["a"] = {"abc" : {"\0" : 1}}:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : Mapping({%s : 1})} + d["a"] = {"abc" : Mapping({1 : 1})}:(, TypeError('object must be string',)) +! d["a"] = {"abc" : Mapping({u"\0" : 1})}:(, TypeError('expected bytes with no null',)) + d["a"] = {"abc" : Mapping({"\0" : 1})}:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d["a"] = {"abc" : %s} +--- 465,486 ---- + dl["b"] = 1:(, error('dict is locked',)) + >>> Testing StringToChars using d[%s] = 1 + d[1] = 1:(, TypeError('object must be string',)) +! d[b"\0"] = 1:(, TypeError('expected bytes with no null',)) + d["\0"] = 1:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = {%s : 1} + d["a"] = {1 : 1}:(, TypeError('object must be string',)) +! d["a"] = {b"\0" : 1}:(, TypeError('expected bytes with no null',)) + d["a"] = {"\0" : 1}:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : {%s : 1}} + d["a"] = {"abc" : {1 : 1}}:(, TypeError('object must be string',)) +! d["a"] = {"abc" : {b"\0" : 1}}:(, TypeError('expected bytes with no null',)) + d["a"] = {"abc" : {"\0" : 1}}:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : Mapping({%s : 1})} + d["a"] = {"abc" : Mapping({1 : 1})}:(, TypeError('object must be string',)) +! d["a"] = {"abc" : Mapping({b"\0" : 1})}:(, TypeError('expected bytes with no null',)) + d["a"] = {"abc" : Mapping({"\0" : 1})}:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d["a"] = {"abc" : %s} +*************** +*** 495,511 **** + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) + d["a"] = Mapping({1 : 1}):(, TypeError('object must be string',)) +! d["a"] = Mapping({u"\0" : 1}):(, TypeError('expected bytes with no null',)) + d["a"] = Mapping({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : {%s : 1}}) + d["a"] = Mapping({"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! d["a"] = Mapping({"abc" : {u"\0" : 1}}):(, TypeError('expected bytes with no null',)) + d["a"] = Mapping({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : Mapping({%s : 1})}) + d["a"] = Mapping({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! d["a"] = Mapping({"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected bytes with no null',)) + d["a"] = Mapping({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d["a"] = Mapping({"abc" : %s}) +--- 495,511 ---- + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) + d["a"] = Mapping({1 : 1}):(, TypeError('object must be string',)) +! d["a"] = Mapping({b"\0" : 1}):(, TypeError('expected bytes with no null',)) + d["a"] = Mapping({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : {%s : 1}}) + d["a"] = Mapping({"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! d["a"] = Mapping({"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) + d["a"] = Mapping({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : Mapping({%s : 1})}) + d["a"] = Mapping({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! d["a"] = Mapping({"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) + d["a"] = Mapping({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d["a"] = Mapping({"abc" : %s}) +*************** +*** 539,555 **** + <<< Finished + >>> Testing StringToChars using d.update({%s : 1}) + d.update({1 : 1}):(, TypeError('object must be string',)) +! d.update({u"\0" : 1}):(, TypeError('expected bytes with no null',)) + d.update({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : {%s : 1}}) + d.update({"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! d.update({"abc" : {u"\0" : 1}}):(, TypeError('expected bytes with no null',)) + d.update({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : Mapping({%s : 1})}) + d.update({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! d.update({"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected bytes with no null',)) + d.update({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update({"abc" : %s}) +--- 539,555 ---- + <<< Finished + >>> Testing StringToChars using d.update({%s : 1}) + d.update({1 : 1}):(, TypeError('object must be string',)) +! d.update({b"\0" : 1}):(, TypeError('expected bytes with no null',)) + d.update({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : {%s : 1}}) + d.update({"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! d.update({"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) + d.update({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : Mapping({%s : 1})}) + d.update({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! d.update({"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) + d.update({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update({"abc" : %s}) +*************** +*** 564,580 **** + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) + d.update(Mapping({1 : 1})):(, TypeError('object must be string',)) +! d.update(Mapping({u"\0" : 1})):(, TypeError('expected bytes with no null',)) + d.update(Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : {%s : 1}})) + d.update(Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) +! d.update(Mapping({"abc" : {u"\0" : 1}})):(, TypeError('expected bytes with no null',)) + d.update(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : Mapping({%s : 1})})) + d.update(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) +! d.update(Mapping({"abc" : Mapping({u"\0" : 1})})):(, TypeError('expected bytes with no null',)) + d.update(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update(Mapping({"abc" : %s})) +--- 564,580 ---- + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) + d.update(Mapping({1 : 1})):(, TypeError('object must be string',)) +! d.update(Mapping({b"\0" : 1})):(, TypeError('expected bytes with no null',)) + d.update(Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : {%s : 1}})) + d.update(Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) +! d.update(Mapping({"abc" : {b"\0" : 1}})):(, TypeError('expected bytes with no null',)) + d.update(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : Mapping({%s : 1})})) + d.update(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) +! d.update(Mapping({"abc" : Mapping({b"\0" : 1})})):(, TypeError('expected bytes with no null',)) + d.update(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update(Mapping({"abc" : %s})) +*************** +*** 599,620 **** + <<< Finished + >>> Testing StringToChars using d.update(((%s, 0),)) + d.update(((1, 0),)):(, TypeError('object must be string',)) +! d.update(((u"\0", 0),)):(, TypeError('expected bytes with no null',)) + d.update((("\0", 0),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", {%s : 1}),)) + d.update((("a", {1 : 1}),)):(, TypeError('object must be string',)) +! d.update((("a", {u"\0" : 1}),)):(, TypeError('expected bytes with no null',)) + d.update((("a", {"\0" : 1}),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : {%s : 1}}),)) + d.update((("a", {"abc" : {1 : 1}}),)):(, TypeError('object must be string',)) +! d.update((("a", {"abc" : {u"\0" : 1}}),)):(, TypeError('expected bytes with no null',)) + d.update((("a", {"abc" : {"\0" : 1}}),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : Mapping({%s : 1})}),)) + d.update((("a", {"abc" : Mapping({1 : 1})}),)):(, TypeError('object must be string',)) +! d.update((("a", {"abc" : Mapping({u"\0" : 1})}),)):(, TypeError('expected bytes with no null',)) + d.update((("a", {"abc" : Mapping({"\0" : 1})}),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update((("a", {"abc" : %s}),)) +--- 599,620 ---- + <<< Finished + >>> Testing StringToChars using d.update(((%s, 0),)) + d.update(((1, 0),)):(, TypeError('object must be string',)) +! d.update(((b"\0", 0),)):(, TypeError('expected bytes with no null',)) + d.update((("\0", 0),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", {%s : 1}),)) + d.update((("a", {1 : 1}),)):(, TypeError('object must be string',)) +! d.update((("a", {b"\0" : 1}),)):(, TypeError('expected bytes with no null',)) + d.update((("a", {"\0" : 1}),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : {%s : 1}}),)) + d.update((("a", {"abc" : {1 : 1}}),)):(, TypeError('object must be string',)) +! d.update((("a", {"abc" : {b"\0" : 1}}),)):(, TypeError('expected bytes with no null',)) + d.update((("a", {"abc" : {"\0" : 1}}),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : Mapping({%s : 1})}),)) + d.update((("a", {"abc" : Mapping({1 : 1})}),)):(, TypeError('object must be string',)) +! d.update((("a", {"abc" : Mapping({b"\0" : 1})}),)):(, TypeError('expected bytes with no null',)) + d.update((("a", {"abc" : Mapping({"\0" : 1})}),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update((("a", {"abc" : %s}),)) +*************** +*** 629,645 **** + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) + d.update((("a", Mapping({1 : 1})),)):(, TypeError('object must be string',)) +! d.update((("a", Mapping({u"\0" : 1})),)):(, TypeError('expected bytes with no null',)) + d.update((("a", Mapping({"\0" : 1})),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : {%s : 1}})),)) + d.update((("a", Mapping({"abc" : {1 : 1}})),)):(, TypeError('object must be string',)) +! d.update((("a", Mapping({"abc" : {u"\0" : 1}})),)):(, TypeError('expected bytes with no null',)) + d.update((("a", Mapping({"abc" : {"\0" : 1}})),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : Mapping({%s : 1})})),)) + d.update((("a", Mapping({"abc" : Mapping({1 : 1})})),)):(, TypeError('object must be string',)) +! d.update((("a", Mapping({"abc" : Mapping({u"\0" : 1})})),)):(, TypeError('expected bytes with no null',)) + d.update((("a", Mapping({"abc" : Mapping({"\0" : 1})})),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update((("a", Mapping({"abc" : %s})),)) +--- 629,645 ---- + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) + d.update((("a", Mapping({1 : 1})),)):(, TypeError('object must be string',)) +! d.update((("a", Mapping({b"\0" : 1})),)):(, TypeError('expected bytes with no null',)) + d.update((("a", Mapping({"\0" : 1})),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : {%s : 1}})),)) + d.update((("a", Mapping({"abc" : {1 : 1}})),)):(, TypeError('object must be string',)) +! d.update((("a", Mapping({"abc" : {b"\0" : 1}})),)):(, TypeError('expected bytes with no null',)) + d.update((("a", Mapping({"abc" : {"\0" : 1}})),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : Mapping({%s : 1})})),)) + d.update((("a", Mapping({"abc" : Mapping({1 : 1})})),)):(, TypeError('object must be string',)) +! d.update((("a", Mapping({"abc" : Mapping({b"\0" : 1})})),)):(, TypeError('expected bytes with no null',)) + d.update((("a", Mapping({"abc" : Mapping({"\0" : 1})})),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update((("a", Mapping({"abc" : %s})),)) +*************** +*** 676,692 **** + <<< Finished + >>> Testing StringToChars using vim.List([{%s : 1}]) + vim.List([{1 : 1}]):(, TypeError('object must be string',)) +! vim.List([{u"\0" : 1}]):(, TypeError('expected bytes with no null',)) + vim.List([{"\0" : 1}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : {%s : 1}}]) + vim.List([{"abc" : {1 : 1}}]):(, TypeError('object must be string',)) +! vim.List([{"abc" : {u"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + vim.List([{"abc" : {"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : Mapping({%s : 1})}]) + vim.List([{"abc" : Mapping({1 : 1})}]):(, TypeError('object must be string',)) +! vim.List([{"abc" : Mapping({u"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + vim.List([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using vim.List([{"abc" : %s}]) +--- 676,692 ---- + <<< Finished + >>> Testing StringToChars using vim.List([{%s : 1}]) + vim.List([{1 : 1}]):(, TypeError('object must be string',)) +! vim.List([{b"\0" : 1}]):(, TypeError('expected bytes with no null',)) + vim.List([{"\0" : 1}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : {%s : 1}}]) + vim.List([{"abc" : {1 : 1}}]):(, TypeError('object must be string',)) +! vim.List([{"abc" : {b"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + vim.List([{"abc" : {"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : Mapping({%s : 1})}]) + vim.List([{"abc" : Mapping({1 : 1})}]):(, TypeError('object must be string',)) +! vim.List([{"abc" : Mapping({b"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + vim.List([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using vim.List([{"abc" : %s}]) +*************** +*** 701,717 **** + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) + vim.List([Mapping({1 : 1})]):(, TypeError('object must be string',)) +! vim.List([Mapping({u"\0" : 1})]):(, TypeError('expected bytes with no null',)) + vim.List([Mapping({"\0" : 1})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : {%s : 1}})]) + vim.List([Mapping({"abc" : {1 : 1}})]):(, TypeError('object must be string',)) +! vim.List([Mapping({"abc" : {u"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + vim.List([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : Mapping({%s : 1})})]) + vim.List([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('object must be string',)) +! vim.List([Mapping({"abc" : Mapping({u"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + vim.List([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using vim.List([Mapping({"abc" : %s})]) +--- 701,717 ---- + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) + vim.List([Mapping({1 : 1})]):(, TypeError('object must be string',)) +! vim.List([Mapping({b"\0" : 1})]):(, TypeError('expected bytes with no null',)) + vim.List([Mapping({"\0" : 1})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : {%s : 1}})]) + vim.List([Mapping({"abc" : {1 : 1}})]):(, TypeError('object must be string',)) +! vim.List([Mapping({"abc" : {b"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + vim.List([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : Mapping({%s : 1})})]) + vim.List([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('object must be string',)) +! vim.List([Mapping({"abc" : Mapping({b"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + vim.List([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using vim.List([Mapping({"abc" : %s})]) +*************** +*** 747,763 **** + <<< Finished + >>> Testing StringToChars using l[:] = [{%s : 1}] + l[:] = [{1 : 1}]:(, TypeError('object must be string',)) +! l[:] = [{u"\0" : 1}]:(, TypeError('expected bytes with no null',)) + l[:] = [{"\0" : 1}]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : {%s : 1}}] + l[:] = [{"abc" : {1 : 1}}]:(, TypeError('object must be string',)) +! l[:] = [{"abc" : {u"\0" : 1}}]:(, TypeError('expected bytes with no null',)) + l[:] = [{"abc" : {"\0" : 1}}]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : Mapping({%s : 1})}] + l[:] = [{"abc" : Mapping({1 : 1})}]:(, TypeError('object must be string',)) +! l[:] = [{"abc" : Mapping({u"\0" : 1})}]:(, TypeError('expected bytes with no null',)) + l[:] = [{"abc" : Mapping({"\0" : 1})}]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l[:] = [{"abc" : %s}] +--- 747,763 ---- + <<< Finished + >>> Testing StringToChars using l[:] = [{%s : 1}] + l[:] = [{1 : 1}]:(, TypeError('object must be string',)) +! l[:] = [{b"\0" : 1}]:(, TypeError('expected bytes with no null',)) + l[:] = [{"\0" : 1}]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : {%s : 1}}] + l[:] = [{"abc" : {1 : 1}}]:(, TypeError('object must be string',)) +! l[:] = [{"abc" : {b"\0" : 1}}]:(, TypeError('expected bytes with no null',)) + l[:] = [{"abc" : {"\0" : 1}}]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : Mapping({%s : 1})}] + l[:] = [{"abc" : Mapping({1 : 1})}]:(, TypeError('object must be string',)) +! l[:] = [{"abc" : Mapping({b"\0" : 1})}]:(, TypeError('expected bytes with no null',)) + l[:] = [{"abc" : Mapping({"\0" : 1})}]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l[:] = [{"abc" : %s}] +*************** +*** 772,788 **** + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] + l[:] = [Mapping({1 : 1})]:(, TypeError('object must be string',)) +! l[:] = [Mapping({u"\0" : 1})]:(, TypeError('expected bytes with no null',)) + l[:] = [Mapping({"\0" : 1})]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : {%s : 1}})] + l[:] = [Mapping({"abc" : {1 : 1}})]:(, TypeError('object must be string',)) +! l[:] = [Mapping({"abc" : {u"\0" : 1}})]:(, TypeError('expected bytes with no null',)) + l[:] = [Mapping({"abc" : {"\0" : 1}})]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : Mapping({%s : 1})})] + l[:] = [Mapping({"abc" : Mapping({1 : 1})})]:(, TypeError('object must be string',)) +! l[:] = [Mapping({"abc" : Mapping({u"\0" : 1})})]:(, TypeError('expected bytes with no null',)) + l[:] = [Mapping({"abc" : Mapping({"\0" : 1})})]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l[:] = [Mapping({"abc" : %s})] +--- 772,788 ---- + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] + l[:] = [Mapping({1 : 1})]:(, TypeError('object must be string',)) +! l[:] = [Mapping({b"\0" : 1})]:(, TypeError('expected bytes with no null',)) + l[:] = [Mapping({"\0" : 1})]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : {%s : 1}})] + l[:] = [Mapping({"abc" : {1 : 1}})]:(, TypeError('object must be string',)) +! l[:] = [Mapping({"abc" : {b"\0" : 1}})]:(, TypeError('expected bytes with no null',)) + l[:] = [Mapping({"abc" : {"\0" : 1}})]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : Mapping({%s : 1})})] + l[:] = [Mapping({"abc" : Mapping({1 : 1})})]:(, TypeError('object must be string',)) +! l[:] = [Mapping({"abc" : Mapping({b"\0" : 1})})]:(, TypeError('expected bytes with no null',)) + l[:] = [Mapping({"abc" : Mapping({"\0" : 1})})]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l[:] = [Mapping({"abc" : %s})] +*************** +*** 812,828 **** + <<< Finished + >>> Testing StringToChars using l.extend([{%s : 1}]) + l.extend([{1 : 1}]):(, TypeError('object must be string',)) +! l.extend([{u"\0" : 1}]):(, TypeError('expected bytes with no null',)) + l.extend([{"\0" : 1}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : {%s : 1}}]) + l.extend([{"abc" : {1 : 1}}]):(, TypeError('object must be string',)) +! l.extend([{"abc" : {u"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + l.extend([{"abc" : {"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : Mapping({%s : 1})}]) + l.extend([{"abc" : Mapping({1 : 1})}]):(, TypeError('object must be string',)) +! l.extend([{"abc" : Mapping({u"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + l.extend([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l.extend([{"abc" : %s}]) +--- 812,828 ---- + <<< Finished + >>> Testing StringToChars using l.extend([{%s : 1}]) + l.extend([{1 : 1}]):(, TypeError('object must be string',)) +! l.extend([{b"\0" : 1}]):(, TypeError('expected bytes with no null',)) + l.extend([{"\0" : 1}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : {%s : 1}}]) + l.extend([{"abc" : {1 : 1}}]):(, TypeError('object must be string',)) +! l.extend([{"abc" : {b"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + l.extend([{"abc" : {"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : Mapping({%s : 1})}]) + l.extend([{"abc" : Mapping({1 : 1})}]):(, TypeError('object must be string',)) +! l.extend([{"abc" : Mapping({b"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + l.extend([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l.extend([{"abc" : %s}]) +*************** +*** 837,853 **** + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) + l.extend([Mapping({1 : 1})]):(, TypeError('object must be string',)) +! l.extend([Mapping({u"\0" : 1})]):(, TypeError('expected bytes with no null',)) + l.extend([Mapping({"\0" : 1})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : {%s : 1}})]) + l.extend([Mapping({"abc" : {1 : 1}})]):(, TypeError('object must be string',)) +! l.extend([Mapping({"abc" : {u"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + l.extend([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : Mapping({%s : 1})})]) + l.extend([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('object must be string',)) +! l.extend([Mapping({"abc" : Mapping({u"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + l.extend([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l.extend([Mapping({"abc" : %s})]) +--- 837,853 ---- + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) + l.extend([Mapping({1 : 1})]):(, TypeError('object must be string',)) +! l.extend([Mapping({b"\0" : 1})]):(, TypeError('expected bytes with no null',)) + l.extend([Mapping({"\0" : 1})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : {%s : 1}})]) + l.extend([Mapping({"abc" : {1 : 1}})]):(, TypeError('object must be string',)) +! l.extend([Mapping({"abc" : {b"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + l.extend([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : Mapping({%s : 1})})]) + l.extend([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('object must be string',)) +! l.extend([Mapping({"abc" : Mapping({b"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + l.extend([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l.extend([Mapping({"abc" : %s})]) +*************** +*** 882,898 **** + >> FunctionCall + >>> Testing StringToChars using f({%s : 1}) + f({1 : 1}):(, TypeError('object must be string',)) +! f({u"\0" : 1}):(, TypeError('expected bytes with no null',)) + f({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f({"abc" : {%s : 1}}) + f({"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! f({"abc" : {u"\0" : 1}}):(, TypeError('expected bytes with no null',)) + f({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f({"abc" : Mapping({%s : 1})}) + f({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! f({"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected bytes with no null',)) + f({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using f({"abc" : %s}) +--- 882,898 ---- + >> FunctionCall + >>> Testing StringToChars using f({%s : 1}) + f({1 : 1}):(, TypeError('object must be string',)) +! f({b"\0" : 1}):(, TypeError('expected bytes with no null',)) + f({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f({"abc" : {%s : 1}}) + f({"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! f({"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) + f({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f({"abc" : Mapping({%s : 1})}) + f({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! f({"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) + f({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using f({"abc" : %s}) +*************** +*** 907,923 **** + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) + f(Mapping({1 : 1})):(, TypeError('object must be string',)) +! f(Mapping({u"\0" : 1})):(, TypeError('expected bytes with no null',)) + f(Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : {%s : 1}})) + f(Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) +! f(Mapping({"abc" : {u"\0" : 1}})):(, TypeError('expected bytes with no null',)) + f(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : Mapping({%s : 1})})) + f(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) +! f(Mapping({"abc" : Mapping({u"\0" : 1})})):(, TypeError('expected bytes with no null',)) + f(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using f(Mapping({"abc" : %s})) +--- 907,923 ---- + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) + f(Mapping({1 : 1})):(, TypeError('object must be string',)) +! f(Mapping({b"\0" : 1})):(, TypeError('expected bytes with no null',)) + f(Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : {%s : 1}})) + f(Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) +! f(Mapping({"abc" : {b"\0" : 1}})):(, TypeError('expected bytes with no null',)) + f(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : Mapping({%s : 1})})) + f(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) +! f(Mapping({"abc" : Mapping({b"\0" : 1})})):(, TypeError('expected bytes with no null',)) + f(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using f(Mapping({"abc" : %s})) +*************** +*** 942,958 **** + <<< Finished + >>> Testing StringToChars using fd(self={%s : 1}) + fd(self={1 : 1}):(, TypeError('object must be string',)) +! fd(self={u"\0" : 1}):(, TypeError('expected bytes with no null',)) + fd(self={"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : {%s : 1}}) + fd(self={"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! fd(self={"abc" : {u"\0" : 1}}):(, TypeError('expected bytes with no null',)) + fd(self={"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : Mapping({%s : 1})}) + fd(self={"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! fd(self={"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected bytes with no null',)) + fd(self={"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using fd(self={"abc" : %s}) +--- 942,958 ---- + <<< Finished + >>> Testing StringToChars using fd(self={%s : 1}) + fd(self={1 : 1}):(, TypeError('object must be string',)) +! fd(self={b"\0" : 1}):(, TypeError('expected bytes with no null',)) + fd(self={"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : {%s : 1}}) + fd(self={"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! fd(self={"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) + fd(self={"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : Mapping({%s : 1})}) + fd(self={"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! fd(self={"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) + fd(self={"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using fd(self={"abc" : %s}) +*************** +*** 967,983 **** + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) + fd(self=Mapping({1 : 1})):(, TypeError('object must be string',)) +! fd(self=Mapping({u"\0" : 1})):(, TypeError('expected bytes with no null',)) + fd(self=Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : {%s : 1}})) + fd(self=Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) +! fd(self=Mapping({"abc" : {u"\0" : 1}})):(, TypeError('expected bytes with no null',)) + fd(self=Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : Mapping({%s : 1})})) + fd(self=Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) +! fd(self=Mapping({"abc" : Mapping({u"\0" : 1})})):(, TypeError('expected bytes with no null',)) + fd(self=Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using fd(self=Mapping({"abc" : %s})) +--- 967,983 ---- + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) + fd(self=Mapping({1 : 1})):(, TypeError('object must be string',)) +! fd(self=Mapping({b"\0" : 1})):(, TypeError('expected bytes with no null',)) + fd(self=Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : {%s : 1}})) + fd(self=Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) +! fd(self=Mapping({"abc" : {b"\0" : 1}})):(, TypeError('expected bytes with no null',)) + fd(self=Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : Mapping({%s : 1})})) + fd(self=Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) +! fd(self=Mapping({"abc" : Mapping({b"\0" : 1})})):(, TypeError('expected bytes with no null',)) + fd(self=Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using fd(self=Mapping({"abc" : %s})) +*************** +*** 1001,1007 **** + fd(self=FailingMappingKey()):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyMapping using fd(self=%s) +! fd(self=[]):(, AttributeError("'list' object has no attribute 'keys'",)) + <<< Finished + > TabPage + >> TabPageAttr +--- 1001,1007 ---- + fd(self=FailingMappingKey()):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyMapping using fd(self=%s) +! fd(self=[]):(, AttributeError('keys',)) + <<< Finished + > TabPage + >> TabPageAttr +*************** +*** 1014,1020 **** + vim.current.window.xxx:(, AttributeError("'vim.window' object has no attribute 'xxx'",)) + >> WindowSetattr + vim.current.window.buffer = 0:(, TypeError('readonly attribute',)) +! vim.current.window.cursor = (10000000000, 100000000):(, error('cursor position outside buffer',)) + vim.current.window.cursor = True:(, TypeError('argument must be 2-item sequence, not bool',)) + vim.current.window.height = "abc":(, TypeError('an integer is required',)) + vim.current.window.width = "abc":(, TypeError('an integer is required',)) +--- 1014,1020 ---- + vim.current.window.xxx:(, AttributeError("'vim.window' object has no attribute 'xxx'",)) + >> WindowSetattr + vim.current.window.buffer = 0:(, TypeError('readonly attribute',)) +! vim.current.window.cursor = (100000000, 100000000):(, error('cursor position outside buffer',)) + vim.current.window.cursor = True:(, TypeError('argument must be 2-item sequence, not bool',)) + vim.current.window.height = "abc":(, TypeError('an integer is required',)) + vim.current.window.width = "abc":(, TypeError('an integer is required',)) +*************** +*** 1035,1043 **** + vim.current.buffer.append(["\na", "bc"]):(, error('string cannot contain newlines',)) + vim.current.buffer.append("\nbc"):(, error('string cannot contain newlines',)) + >> RBItem +! vim.current.buffer[10000000000]:(, IndexError('line number out of range',)) + >> RBAsItem +! vim.current.buffer[10000000000] = "":(, IndexError('line number out of range',)) + >> BufferAttr + vim.current.buffer.xxx:(, AttributeError("'vim.buffer' object has no attribute 'xxx'",)) + >> BufferSetattr +--- 1035,1043 ---- + vim.current.buffer.append(["\na", "bc"]):(, error('string cannot contain newlines',)) + vim.current.buffer.append("\nbc"):(, error('string cannot contain newlines',)) + >> RBItem +! vim.current.buffer[100000000]:(, IndexError('line number out of range',)) + >> RBAsItem +! vim.current.buffer[100000000] = "":(, IndexError('line number out of range',)) + >> BufferAttr + vim.current.buffer.xxx:(, AttributeError("'vim.buffer' object has no attribute 'xxx'",)) + >> BufferSetattr +*** ../vim-7.3.1078/src/version.c 2013-05-30 22:43:57.000000000 +0200 +--- src/version.c 2013-05-31 18:41:58.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1079, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +29. Your phone bill comes to your doorstep in a box. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3cec34dc9167096cd560080c41b9746e8f8cc2ff Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:42 +0200 Subject: [PATCH 0971/3340] - patchlevel 1080 --- 7.3.1080 | 265 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 265 insertions(+) create mode 100644 7.3.1080 diff --git a/7.3.1080 b/7.3.1080 new file mode 100644 index 00000000..858a1d42 --- /dev/null +++ b/7.3.1080 @@ -0,0 +1,265 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1080 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1080 +Problem: Test 86 fails. +Solution: Comment out the parts that don't work. Make it pass on 32 bit + systems. +Files: src/testdir/test86.in, src/testdir/test86.ok + + +*** ../vim-7.3.1079/src/testdir/test86.in 2013-05-30 15:38:20.000000000 +0200 +--- src/testdir/test86.in 2013-05-31 18:59:05.000000000 +0200 +*************** +*** 8,15 **** + STARTTEST + :so small.vim + :set encoding=latin1 +- :" HACK: currently crashes, skip the test +- :e! test.ok | wq! test.out + :if !has('python') | e! test.ok | wq! test.out | endif + :lang C + :py import vim +--- 8,13 ---- +*************** +*** 915,921 **** + cb.append(">> OutputWriteLines") + ee('sys.stdout.writelines(None)') + ee('sys.stdout.writelines([1])') +! iter_test('sys.stdout.writelines(%s)') + cb.append("> VimCommand") + ee('vim.command(1)') + #! Not checked: vim->python exceptions translating: checked later +--- 913,919 ---- + cb.append(">> OutputWriteLines") + ee('sys.stdout.writelines(None)') + ee('sys.stdout.writelines([1])') +! #iter_test('sys.stdout.writelines(%s)') + cb.append("> VimCommand") + ee('vim.command(1)') + #! Not checked: vim->python exceptions translating: checked later +*************** +*** 955,961 **** + cb.append(">>> iter") + ee('d.update(FailingMapping())') + ee('d.update([FailingIterNext()])') +! iter_test('d.update(%s)') + convertfrompyobject_test('d.update(%s)') + stringtochars_test('d.update(((%s, 0),))') + convertfrompyobject_test('d.update((("a", %s),))') +--- 953,959 ---- + cb.append(">>> iter") + ee('d.update(FailingMapping())') + ee('d.update([FailingIterNext()])') +! #iter_test('d.update(%s)') + convertfrompyobject_test('d.update(%s)') + stringtochars_test('d.update(((%s, 0),))') + convertfrompyobject_test('d.update((("a", %s),))') +*************** +*** 967,973 **** + cb.append(">> ListConstructor") + ee('vim.List(1, 2)') + ee('vim.List(a=1)') +! iter_test('vim.List(%s)') + convertfrompyobject_test('vim.List([%s])') + cb.append(">> ListItem") + ee('l[1000]') +--- 965,971 ---- + cb.append(">> ListConstructor") + ee('vim.List(1, 2)') + ee('vim.List(a=1)') +! #iter_test('vim.List(%s)') + convertfrompyobject_test('vim.List([%s])') + cb.append(">> ListItem") + ee('l[1000]') +*************** +*** 976,985 **** + ee('l[1000] = 3') + cb.append(">> ListAssSlice") + ee('ll[1:100] = "abc"') +! iter_test('l[:] = %s') + convertfrompyobject_test('l[:] = [%s]') + cb.append(">> ListConcatInPlace") +! iter_test('l.extend(%s)') + convertfrompyobject_test('l.extend([%s])') + cb.append(">> ListSetattr") + ee('del l.locked') +--- 974,983 ---- + ee('l[1000] = 3') + cb.append(">> ListAssSlice") + ee('ll[1:100] = "abc"') +! #iter_test('l[:] = %s') + convertfrompyobject_test('l[:] = [%s]') + cb.append(">> ListConcatInPlace") +! #iter_test('l.extend(%s)') + convertfrompyobject_test('l.extend([%s])') + cb.append(">> ListSetattr") + ee('del l.locked') +*************** +*** 1004,1010 **** + ee('vim.current.window.xxx') + cb.append(">> WindowSetattr") + ee('vim.current.window.buffer = 0') +! ee('vim.current.window.cursor = (10000000000, 100000000)') + ee('vim.current.window.cursor = True') + ee('vim.current.window.height = "abc"') + ee('vim.current.window.width = "abc"') +--- 1002,1008 ---- + ee('vim.current.window.xxx') + cb.append(">> WindowSetattr") + ee('vim.current.window.buffer = 0') +! ee('vim.current.window.cursor = (100000000, 100000000)') + ee('vim.current.window.cursor = True') + ee('vim.current.window.height = "abc"') + ee('vim.current.window.width = "abc"') +*************** +*** 1025,1033 **** + ee('vim.current.buffer.append(["\\na", "bc"])') + ee('vim.current.buffer.append("\\nbc")') + cb.append(">> RBItem") +! ee('vim.current.buffer[10000000000]') + cb.append(">> RBAsItem") +! ee('vim.current.buffer[10000000000] = ""') + cb.append(">> BufferAttr") + ee('vim.current.buffer.xxx') + cb.append(">> BufferSetattr") +--- 1023,1031 ---- + ee('vim.current.buffer.append(["\\na", "bc"])') + ee('vim.current.buffer.append("\\nbc")') + cb.append(">> RBItem") +! ee('vim.current.buffer[100000000]') + cb.append(">> RBAsItem") +! ee('vim.current.buffer[100000000] = ""') + cb.append(">> BufferAttr") + ee('vim.current.buffer.xxx') + cb.append(">> BufferSetattr") +*** ../vim-7.3.1079/src/testdir/test86.ok 2013-05-30 13:37:23.000000000 +0200 +--- src/testdir/test86.ok 2013-05-31 18:59:34.000000000 +0200 +*************** +*** 439,448 **** + >> OutputWriteLines + sys.stdout.writelines(None):(, TypeError("'NoneType' object is not iterable",)) + sys.stdout.writelines([1]):(, TypeError('writelines() requires list of strings',)) +- >>> Testing *Iter* using sys.stdout.writelines(%s) +- sys.stdout.writelines(FailingIter()):(, NotImplementedError()) +- sys.stdout.writelines(FailingIterNext()):(, NotImplementedError()) +- <<< Finished + > VimCommand + vim.command(1):(, TypeError('must be string, not int',)) + > VimToPython +--- 439,444 ---- +*************** +*** 544,553 **** + >>> iter + d.update(FailingMapping()):(, NotImplementedError()) + d.update([FailingIterNext()]):(, NotImplementedError()) +- >>> Testing *Iter* using d.update(%s) +- d.update(FailingIter()):(, NotImplementedError()) +- d.update(FailingIterNext()):(, NotImplementedError()) +- <<< Finished + >>> Testing StringToChars using d.update({%s : 1}) + d.update({1 : 1}):(, TypeError('object must be string',)) + d.update({u"\0" : 1}):(, TypeError('expected string without null bytes',)) +--- 540,545 ---- +*************** +*** 681,690 **** + >> ListConstructor + vim.List(1, 2):(, TypeError('function takes at most 1 argument (2 given)',)) + vim.List(a=1):(, TypeError('list constructor does not accept keyword arguments',)) +- >>> Testing *Iter* using vim.List(%s) +- vim.List(FailingIter()):(, NotImplementedError()) +- vim.List(FailingIterNext()):(, NotImplementedError()) +- <<< Finished + >>> Testing StringToChars using vim.List([{%s : 1}]) + vim.List([{1 : 1}]):(, TypeError('object must be string',)) + vim.List([{u"\0" : 1}]):(, TypeError('expected string without null bytes',)) +--- 673,678 ---- +*************** +*** 752,761 **** + l[1000] = 3:(, IndexError('list index out of range',)) + >> ListAssSlice + ll[1:100] = "abc":(, error('list is locked',)) +- >>> Testing *Iter* using l[:] = %s +- l[:] = FailingIter():(, NotImplementedError()) +- l[:] = FailingIterNext():(, NotImplementedError()) +- <<< Finished + >>> Testing StringToChars using l[:] = [{%s : 1}] + l[:] = [{1 : 1}]:(, TypeError('object must be string',)) + l[:] = [{u"\0" : 1}]:(, TypeError('expected string without null bytes',)) +--- 740,745 ---- +*************** +*** 817,826 **** + l[:] = [FailingMappingKey()]:(, NotImplementedError()) + <<< Finished + >> ListConcatInPlace +- >>> Testing *Iter* using l.extend(%s) +- l.extend(FailingIter()):(, NotImplementedError()) +- l.extend(FailingIterNext()):(, NotImplementedError()) +- <<< Finished + >>> Testing StringToChars using l.extend([{%s : 1}]) + l.extend([{1 : 1}]):(, TypeError('object must be string',)) + l.extend([{u"\0" : 1}]):(, TypeError('expected string without null bytes',)) +--- 801,806 ---- +*************** +*** 1025,1031 **** + vim.current.window.xxx:(, AttributeError('xxx',)) + >> WindowSetattr + vim.current.window.buffer = 0:(, TypeError('readonly attribute',)) +! vim.current.window.cursor = (10000000000, 100000000):(, error('cursor position outside buffer',)) + vim.current.window.cursor = True:(, TypeError('argument must be 2-item sequence, not bool',)) + vim.current.window.height = "abc":(, TypeError('an integer is required',)) + vim.current.window.width = "abc":(, TypeError('an integer is required',)) +--- 1005,1011 ---- + vim.current.window.xxx:(, AttributeError('xxx',)) + >> WindowSetattr + vim.current.window.buffer = 0:(, TypeError('readonly attribute',)) +! vim.current.window.cursor = (100000000, 100000000):(, error('cursor position outside buffer',)) + vim.current.window.cursor = True:(, TypeError('argument must be 2-item sequence, not bool',)) + vim.current.window.height = "abc":(, TypeError('an integer is required',)) + vim.current.window.width = "abc":(, TypeError('an integer is required',)) +*************** +*** 1046,1054 **** + vim.current.buffer.append(["\na", "bc"]):(, error('string cannot contain newlines',)) + vim.current.buffer.append("\nbc"):(, error('string cannot contain newlines',)) + >> RBItem +! vim.current.buffer[10000000000]:(, IndexError('line number out of range',)) + >> RBAsItem +! vim.current.buffer[10000000000] = "":(, IndexError('line number out of range',)) + >> BufferAttr + vim.current.buffer.xxx:(, AttributeError('xxx',)) + >> BufferSetattr +--- 1026,1034 ---- + vim.current.buffer.append(["\na", "bc"]):(, error('string cannot contain newlines',)) + vim.current.buffer.append("\nbc"):(, error('string cannot contain newlines',)) + >> RBItem +! vim.current.buffer[100000000]:(, IndexError('line number out of range',)) + >> RBAsItem +! vim.current.buffer[100000000] = "":(, IndexError('line number out of range',)) + >> BufferAttr + vim.current.buffer.xxx:(, AttributeError('xxx',)) + >> BufferSetattr +*** ../vim-7.3.1079/src/version.c 2013-05-31 18:46:06.000000000 +0200 +--- src/version.c 2013-05-31 19:00:29.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1080, + /**/ + +-- +If you put 7 of the most talented OSS developers in a room for a week +and asked them to fix a bug in a spreadsheet program, in 1 week +you'd have 2 new mail readers and a text-based web browser. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a01f5cd429f34930730f51be2d5ccef055d55bfa Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:43 +0200 Subject: [PATCH 0972/3340] - patchlevel 1081 --- 7.3.1081 | 73 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 7.3.1081 diff --git a/7.3.1081 b/7.3.1081 new file mode 100644 index 00000000..1436295d --- /dev/null +++ b/7.3.1081 @@ -0,0 +1,73 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.10 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1081 +Problem: Compiler warnings on 64-bit Windows. +Solution: Change variable types. (Mike Williams) +Files: src/if_py_both.h, src/regexp_nfa.c + + +*** ../vim-7.3.1080/src/if_py_both.h 2013-05-30 22:06:28.000000000 +0200 +--- src/if_py_both.h 2013-05-31 20:39:37.000000000 +0200 +*************** +*** 1100,1106 **** + long_u ht_used; + hashtab_T *ht; + hashitem_T *hi; +! int todo; + } dictiterinfo_T; + + static PyObject * +--- 1100,1106 ---- + long_u ht_used; + hashtab_T *ht; + hashitem_T *hi; +! long_u todo; + } dictiterinfo_T; + + static PyObject * +*** ../vim-7.3.1080/src/regexp_nfa.c 2013-05-30 22:43:57.000000000 +0200 +--- src/regexp_nfa.c 2013-05-31 20:45:03.000000000 +0200 +*************** +*** 283,289 **** + static int + realloc_post_list() + { +! int nstate_max = post_end - post_start; + int new_max = nstate_max + 1000; + int *new_start; + int *old_start; +--- 283,289 ---- + static int + realloc_post_list() + { +! int nstate_max = (int)(post_end - post_start); + int new_max = nstate_max + 1000; + int *new_start; + int *old_start; +*** ../vim-7.3.1080/src/version.c 2013-05-31 19:01:13.000000000 +0200 +--- src/version.c 2013-05-31 20:40:19.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1081, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +32. You don't know what sex three of your closest friends are, because they + have neutral nicknames and you never bothered to ask. + normal GA + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2d1b1e08633b5aa29235642016a90fec798ec280 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:43 +0200 Subject: [PATCH 0973/3340] - patchlevel 1082 --- 7.3.1082 | 168 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 168 insertions(+) create mode 100644 7.3.1082 diff --git a/7.3.1082 b/7.3.1082 new file mode 100644 index 00000000..cd4da8b1 --- /dev/null +++ b/7.3.1082 @@ -0,0 +1,168 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1082 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1082 +Problem: New regexp engine: Problem with \@= matching. +Solution: Save and restore nfa_match. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1081/src/regexp_nfa.c 2013-05-31 20:49:27.000000000 +0200 +--- src/regexp_nfa.c 2013-05-31 21:19:15.000000000 +0200 +*************** +*** 3332,3342 **** + int result; + int size = 0; + int flag = 0; +- int old_reglnum = -1; + int go_to_nextline = FALSE; + nfa_thread_T *t; +- char_u *old_reginput = NULL; +- char_u *old_regline = NULL; + nfa_list_T list[3]; + nfa_list_T *listtbl[2][2]; + nfa_list_T *ll; +--- 3332,3339 ---- +*************** +*** 3560,3574 **** + break; + + case NFA_START_INVISIBLE: +! /* Save global variables, and call nfa_regmatch() to check if +! * the current concat matches at this position. The concat +! * ends with the node NFA_END_INVISIBLE */ +! old_reginput = reginput; +! old_regline = regline; +! old_reglnum = reglnum; + if (listids == NULL) + { +! listids = (int *) lalloc(sizeof(int) * nstate, TRUE); + if (listids == NULL) + { + EMSG(_("E878: (NFA) Could not allocate memory for branch traversal!")); +--- 3557,3574 ---- + break; + + case NFA_START_INVISIBLE: +! { +! char_u *save_reginput = reginput; +! char_u *save_regline = regline; +! int save_reglnum = reglnum; +! int save_nfa_match = nfa_match; +! +! /* Call nfa_regmatch() to check if the current concat matches +! * at this position. The concat ends with the node +! * NFA_END_INVISIBLE */ + if (listids == NULL) + { +! listids = (int *)lalloc(sizeof(int) * nstate, TRUE); + if (listids == NULL) + { + EMSG(_("E878: (NFA) Could not allocate memory for branch traversal!")); +*************** +*** 3588,3594 **** + result = nfa_regmatch(t->state->out, submatch, m); + nfa_set_neg_listids(start); + nfa_restore_listids(start, listids); +! nfa_match = FALSE; + + #ifdef ENABLE_LOG + log_fd = fopen(NFA_REGEXP_RUN_LOG, "a"); +--- 3588,3599 ---- + result = nfa_regmatch(t->state->out, submatch, m); + nfa_set_neg_listids(start); + nfa_restore_listids(start, listids); +! +! /* restore position in input text */ +! reginput = save_reginput; +! regline = save_regline; +! reglnum = save_reglnum; +! nfa_match = save_nfa_match; + + #ifdef ENABLE_LOG + log_fd = fopen(NFA_REGEXP_RUN_LOG, "a"); +*************** +*** 3610,3619 **** + { + int j; + +- /* Restore position in input text */ +- reginput = old_reginput; +- regline = old_regline; +- reglnum = old_reglnum; + /* Copy submatch info from the recursive call */ + if (REG_MULTI) + for (j = 1; j < m->in_use; j++) +--- 3615,3620 ---- +*************** +*** 3635,3646 **** + addstate_here(thislist, t->state->out1->out, &t->sub, + &listidx); + } +- else +- { +- /* continue with next input char */ +- reginput = old_reginput; +- } + break; + + case NFA_BOL: + if (reginput == regline) +--- 3636,3643 ---- + addstate_here(thislist, t->state->out1->out, &t->sub, + &listidx); + } + break; ++ } + + case NFA_BOL: + if (reginput == regline) +*** ../vim-7.3.1081/src/testdir/test64.in 2013-05-30 22:43:57.000000000 +0200 +--- src/testdir/test64.in 2013-05-31 21:14:37.000000000 +0200 +*************** +*** 305,310 **** +--- 305,311 ---- + :call add(tl, [2, '\v(abc)@=..', 'xabcd', 'ab', 'abc']) + :call add(tl, [2, '\(.*John\)\@=.*Bob', 'here is John, and here is B']) + :call add(tl, [2, '\(John.*\)\@=.*Bob', 'John is Bobs friend', 'John is Bob', 'John is Bobs friend']) ++ :call add(tl, [2, '\<\S\+\())\)\@=', '$((i=i+1))', 'i=i+1', '))']) + :call add(tl, [2, '.*John\&.*Bob', 'here is John, and here is B']) + :call add(tl, [2, '.*John\&.*Bob', 'John is Bobs friend', 'John is Bob']) + :call add(tl, [2, '\v(test1)@=.*yep', 'this is a test1, yep it is', 'test1, yep', 'test1']) +*** ../vim-7.3.1081/src/testdir/test64.ok 2013-05-30 22:43:57.000000000 +0200 +--- src/testdir/test64.ok 2013-05-31 21:16:29.000000000 +0200 +*************** +*** 669,674 **** +--- 669,677 ---- + OK 0 - \(John.*\)\@=.*Bob + OK 1 - \(John.*\)\@=.*Bob + OK 2 - \(John.*\)\@=.*Bob ++ OK 0 - \<\S\+\())\)\@= ++ OK 1 - \<\S\+\())\)\@= ++ OK 2 - \<\S\+\())\)\@= + OK 0 - .*John\&.*Bob + OK 1 - .*John\&.*Bob + OK 2 - .*John\&.*Bob +*** ../vim-7.3.1081/src/version.c 2013-05-31 20:49:27.000000000 +0200 +--- src/version.c 2013-05-31 21:21:12.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1082, + /**/ + +-- +To define recursion, we must first define recursion. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 036a0d329c0e5c6ff260ddbae0d52952a4d42b4d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:44 +0200 Subject: [PATCH 0974/3340] - patchlevel 1083 --- 7.3.1083 | 166 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 166 insertions(+) create mode 100644 7.3.1083 diff --git a/7.3.1083 b/7.3.1083 new file mode 100644 index 00000000..c9022cec --- /dev/null +++ b/7.3.1083 @@ -0,0 +1,166 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1083 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1083 +Problem: New regexp engine: Does not support \%^ and \%$. +Solution: Support matching start and end of file. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1082/src/regexp_nfa.c 2013-05-31 21:45:05.000000000 +0200 +--- src/regexp_nfa.c 2013-05-31 21:55:35.000000000 +0200 +*************** +*** 865,878 **** + * pattern -- regardless of whether or not it makes sense. */ + case '^': + EMIT(NFA_BOF); +- /* TODO: Not yet supported */ +- return FAIL; + break; + + case '$': + EMIT(NFA_EOF); +- /* TODO: Not yet supported */ +- return FAIL; + break; + + case '#': +--- 865,874 ---- +*************** +*** 1780,1785 **** +--- 1776,1783 ---- + case NFA_BOL: STRCPY(code, "NFA_BOL "); break; + case NFA_EOW: STRCPY(code, "NFA_EOW "); break; + case NFA_BOW: STRCPY(code, "NFA_BOW "); break; ++ case NFA_EOF: STRCPY(code, "NFA_EOF "); break; ++ case NFA_BOF: STRCPY(code, "NFA_BOF "); break; + case NFA_STAR: STRCPY(code, "NFA_STAR "); break; + case NFA_PLUS: STRCPY(code, "NFA_PLUS "); break; + case NFA_NOT: STRCPY(code, "NFA_NOT "); break; +*************** +*** 3705,3710 **** +--- 3703,3719 ---- + break; + } + ++ case NFA_BOF: ++ if (reglnum == 0 && reginput == regline ++ && (!REG_MULTI || reg_firstlnum == 1)) ++ addstate_here(thislist, t->state->out, &t->sub, &listidx); ++ break; ++ ++ case NFA_EOF: ++ if (reglnum == reg_maxline && curc == NUL) ++ addstate_here(thislist, t->state->out, &t->sub, &listidx); ++ break; ++ + #ifdef FEAT_MBYTE + case NFA_COMPOSING: + { +*** ../vim-7.3.1082/src/testdir/test64.in 2013-05-31 21:45:05.000000000 +0200 +--- src/testdir/test64.in 2013-05-31 22:10:12.000000000 +0200 +*************** +*** 267,272 **** +--- 267,281 ---- + :call add(tl, [2, '\_f', " \na ", "\n"]) + :call add(tl, [2, '\_f\+', " \na ", "\na"]) + :" ++ :"""" Test start/end of line, start/end of file ++ :call add(tl, [2, '^a.', "a_\nb ", "a_"]) ++ :call add(tl, [2, '^a.', "b a \na_"]) ++ :call add(tl, [2, '.a$', " a\n "]) ++ :call add(tl, [2, '.a$', " a b\n_a", "_a"]) ++ :call add(tl, [2, '\%^a.', "a a\na", "a "]) ++ :call add(tl, [2, '\%^a', " a \na "]) ++ :call add(tl, [2, '.a\%$', " a\n "]) ++ :call add(tl, [2, '.a\%$', " a\n_a", "_a"]) + :" + :"""" Test recognition of some character classes + :call add(tl, [2, '[0-9]', '8', '8']) +*************** +*** 466,471 **** +--- 475,489 ---- + :call Postest() + :put + :" ++ :" start and end of buffer ++ /\%^ ++ yeGop:" ++ 50%/\%^.. ++ yeGopA END:" ++ 50%/\%$ ++ "ayb20gg/..\%$ ++ "bybGo"apo"bp:" ++ :" + :/\%#=1^Results/,$wq! test.out + ENDTEST + +*** ../vim-7.3.1082/src/testdir/test64.ok 2013-05-31 21:45:05.000000000 +0200 +--- src/testdir/test64.ok 2013-05-31 22:10:47.000000000 +0200 +*************** +*** 585,590 **** +--- 585,614 ---- + OK 0 - \_f\+ + OK 1 - \_f\+ + OK 2 - \_f\+ ++ OK 0 - ^a. ++ OK 1 - ^a. ++ OK 2 - ^a. ++ OK 0 - ^a. ++ OK 1 - ^a. ++ OK 2 - ^a. ++ OK 0 - .a$ ++ OK 1 - .a$ ++ OK 2 - .a$ ++ OK 0 - .a$ ++ OK 1 - .a$ ++ OK 2 - .a$ ++ OK 0 - \%^a. ++ OK 1 - \%^a. ++ OK 2 - \%^a. ++ OK 0 - \%^a ++ OK 1 - \%^a ++ OK 2 - \%^a ++ OK 0 - .a\%$ ++ OK 1 - .a\%$ ++ OK 2 - .a\%$ ++ OK 0 - .a\%$ ++ OK 1 - .a\%$ ++ OK 2 - .a\%$ + OK 0 - [0-9] + OK 1 - [0-9] + OK 2 - [0-9] +*************** +*** 818,820 **** +--- 842,848 ---- + ab!babababababfoo + ba!ab##abab?bafoo + **!*****_ ++ Test ++ Test END ++ EN ++ E +*** ../vim-7.3.1082/src/version.c 2013-05-31 21:45:05.000000000 +0200 +--- src/version.c 2013-05-31 21:57:03.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1083, + /**/ + +-- +Have you heard about the new Beowulf cluster? It's so fast, it executes +an infinite loop in 6 seconds. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From af7e5cb63f178c41c8aa240230787c550d072c48 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:44 +0200 Subject: [PATCH 0975/3340] - patchlevel 1084 --- 7.3.1084 | 280 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 280 insertions(+) create mode 100644 7.3.1084 diff --git a/7.3.1084 b/7.3.1084 new file mode 100644 index 00000000..7ea8b36c --- /dev/null +++ b/7.3.1084 @@ -0,0 +1,280 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1084 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1084 +Problem: New regexp engine: only accepts up to \{,10}. +Solution: Remove upper limit. Remove dead code with NFA_PLUS. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1083/src/regexp_nfa.c 2013-05-31 22:14:48.000000000 +0200 +--- src/regexp_nfa.c 2013-05-31 23:09:16.000000000 +0200 +*************** +*** 29,39 **** + # define NFA_REGEXP_DEBUG_LOG "nfa_regexp_debug.log" + #endif + +- /* Upper limit allowed for {m,n} repetitions handled by NFA */ +- #define NFA_BRACES_MAXLIMIT 10 +- /* For allocating space for the postfix representation */ +- #define NFA_POSTFIX_MULTIPLIER (NFA_BRACES_MAXLIMIT + 2)*2 +- + enum + { + NFA_SPLIT = -1024, +--- 29,34 ---- +*************** +*** 44,50 **** + NFA_CONCAT, + NFA_OR, + NFA_STAR, +- NFA_PLUS, + NFA_QUEST, + NFA_QUEST_NONGREEDY, /* Non-greedy version of \? */ + NFA_NOT, /* used for [^ab] negated char ranges */ +--- 39,44 ---- +*************** +*** 253,259 **** + nstate = 0; + istate = 0; + /* A reasonable estimation for maximum size */ +! nstate_max = (int)(STRLEN(expr) + 1) * NFA_POSTFIX_MULTIPLIER; + + /* Some items blow up in size, such as [A-z]. Add more space for that. + * When it is still not enough realloc_post_list() will be used. */ +--- 247,253 ---- + nstate = 0; + istate = 0; + /* A reasonable estimation for maximum size */ +! nstate_max = (int)(STRLEN(expr) + 1) * 25; + + /* Some items blow up in size, such as [A-z]. Add more space for that. + * When it is still not enough realloc_post_list() will be used. */ +*************** +*** 1365,1374 **** + * string. + * The submatch will the empty string. + * +! * In order to be consistent with the old engine, we disable +! * NFA_PLUS, and replace + with * + */ +- /* EMIT(NFA_PLUS); */ + regnpar = old_regnpar; + regparse = old_regparse; + curchr = -1; +--- 1359,1367 ---- + * string. + * The submatch will the empty string. + * +! * In order to be consistent with the old engine, we replace +! * + with * + */ + regnpar = old_regnpar; + regparse = old_regparse; + curchr = -1; +*************** +*** 1443,1454 **** + break; + } + +! if (maxval > NFA_BRACES_MAXLIMIT) +! { +! /* This would yield a huge automaton and use too much memory. +! * Revert to old engine */ + return FAIL; +- } + + /* Special case: x{0} or x{-0} */ + if (maxval == 0) +--- 1436,1444 ---- + break; + } + +! /* TODO: \{-} doesn't work yet */ +! if (maxval == MAX_LIMIT && !greedy) + return FAIL; + + /* Special case: x{0} or x{-0} */ + if (maxval == 0) +*************** +*** 1478,1486 **** + return FAIL; + /* after "minval" times, atoms are optional */ + if (i + 1 > minval) +! EMIT(quest); + if (old_post_pos != my_post_start) + EMIT(NFA_CONCAT); + } + + /* Go to just after the repeated atom and the \{} */ +--- 1468,1483 ---- + return FAIL; + /* after "minval" times, atoms are optional */ + if (i + 1 > minval) +! { +! if (maxval == MAX_LIMIT) +! EMIT(NFA_STAR); +! else +! EMIT(quest); +! } + if (old_post_pos != my_post_start) + EMIT(NFA_CONCAT); ++ if (i + 1 > minval && maxval == MAX_LIMIT) ++ break; + } + + /* Go to just after the repeated atom and the \{} */ +*************** +*** 1779,1785 **** + case NFA_EOF: STRCPY(code, "NFA_EOF "); break; + case NFA_BOF: STRCPY(code, "NFA_BOF "); break; + case NFA_STAR: STRCPY(code, "NFA_STAR "); break; +- case NFA_PLUS: STRCPY(code, "NFA_PLUS "); break; + case NFA_NOT: STRCPY(code, "NFA_NOT "); break; + case NFA_SKIP_CHAR: STRCPY(code, "NFA_SKIP_CHAR"); break; + case NFA_OR: STRCPY(code, "NFA_OR"); break; +--- 1776,1781 ---- +*************** +*** 2343,2363 **** + PUSH(frag(s, append(e.out, list1(&s->out)))); + break; + +- case NFA_PLUS: +- /* One or more */ +- if (nfa_calc_size == TRUE) +- { +- nstate++; +- break; +- } +- e = POP(); +- s = new_state(NFA_SPLIT, e.start, NULL); +- if (s == NULL) +- goto theend; +- patch(e.out, s); +- PUSH(frag(e.start, list1(&s->out1))); +- break; +- + case NFA_SKIP_CHAR: + /* Symbol of 0-length, Used in a repetition + * with max/min count of 0 */ +--- 2339,2344 ---- +*** ../vim-7.3.1083/src/testdir/test64.in 2013-05-31 22:14:48.000000000 +0200 +--- src/testdir/test64.in 2013-05-31 22:55:52.000000000 +0200 +*************** +*** 182,188 **** + :call add(tl, [2, 'a\{0,}', 'oij sdigfusnf', '']) + :call add(tl, [2, 'a\{0,}', 'aaaaa aa', 'aaaaa']) + :call add(tl, [2, 'a\{2,}', 'sdfiougjdsafg']) +! :call add(tl, [0, 'a\{2,}', 'aaaaasfoij ', 'aaaaa']) + :call add(tl, [2, 'a\{,0}', 'oidfguih iuhi hiu aaaa', '']) + :call add(tl, [2, 'a\{,5}', 'abcd', 'a']) + :call add(tl, [2, 'a\{,5}', 'aaaaaaaaaa', 'aaaaa']) +--- 182,190 ---- + :call add(tl, [2, 'a\{0,}', 'oij sdigfusnf', '']) + :call add(tl, [2, 'a\{0,}', 'aaaaa aa', 'aaaaa']) + :call add(tl, [2, 'a\{2,}', 'sdfiougjdsafg']) +! :call add(tl, [2, 'a\{2,}', 'aaaaasfoij ', 'aaaaa']) +! :call add(tl, [2, 'a\{5,}', 'xxaaaaxxx ']) +! :call add(tl, [2, 'a\{5,}', 'xxaaaaaxxx ', 'aaaaa']) + :call add(tl, [2, 'a\{,0}', 'oidfguih iuhi hiu aaaa', '']) + :call add(tl, [2, 'a\{,5}', 'abcd', 'a']) + :call add(tl, [2, 'a\{,5}', 'aaaaaaaaaa', 'aaaaa']) +*************** +*** 225,231 **** +--- 227,235 ---- + :" + :" Test greedy-ness and lazy-ness + :call add(tl, [2, 'a\{-2,7}','aaaaaaaaaaaaa', 'aa']) ++ :call add(tl, [2, 'a\{-2,7}x','aaaaaaaaax', 'aaaaaaax']) + :call add(tl, [2, 'a\{2,7}','aaaaaaaaaaaaaaaaaaaa', 'aaaaaaa']) ++ :call add(tl, [2, 'a\{2,7}x','aaaaaaaaax', 'aaaaaaax']) + :call add(tl, [2, '\vx(.{-,8})yz(.*)','xayxayzxayzxayz','xayxayzxayzxayz','ayxa','xayzxayz']) + :call add(tl, [2, '\vx(.*)yz(.*)','xayxayzxayzxayz','xayxayzxayzxayz', 'ayxayzxayzxa','']) + :call add(tl, [2, '\v(a{1,2}){-2,3}','aaaaaaa','aaaa','aa']) +*************** +*** 366,372 **** + :call add(tl, [2, '\_[^a]\+', "asfi\n9888", "sfi\n9888"]) + :" + :"""" Requiring lots of states. +! :call add(tl, [0, '[0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12}', " 12345678-1234-1234-1234-123456789012 ", "12345678-1234-1234-1234-123456789012", "1234-"]) + :" + :" + :"""" Run the tests +--- 370,376 ---- + :call add(tl, [2, '\_[^a]\+', "asfi\n9888", "sfi\n9888"]) + :" + :"""" Requiring lots of states. +! :call add(tl, [2, '[0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12}', " 12345678-1234-1234-1234-123456789012 ", "12345678-1234-1234-1234-123456789012", "1234-"]) + :" + :" + :"""" Run the tests +*** ../vim-7.3.1083/src/testdir/test64.ok 2013-05-31 22:14:48.000000000 +0200 +--- src/testdir/test64.ok 2013-05-31 23:02:02.000000000 +0200 +*************** +*** 389,394 **** +--- 389,401 ---- + OK 2 - a\{2,} + OK 0 - a\{2,} + OK 1 - a\{2,} ++ OK 2 - a\{2,} ++ OK 0 - a\{5,} ++ OK 1 - a\{5,} ++ OK 2 - a\{5,} ++ OK 0 - a\{5,} ++ OK 1 - a\{5,} ++ OK 2 - a\{5,} + OK 0 - a\{,0} + OK 1 - a\{,0} + OK 2 - a\{,0} +*************** +*** 486,494 **** +--- 493,507 ---- + OK 0 - a\{-2,7} + OK 1 - a\{-2,7} + OK 2 - a\{-2,7} ++ OK 0 - a\{-2,7}x ++ OK 1 - a\{-2,7}x ++ OK 2 - a\{-2,7}x + OK 0 - a\{2,7} + OK 1 - a\{2,7} + OK 2 - a\{2,7} ++ OK 0 - a\{2,7}x ++ OK 1 - a\{2,7}x ++ OK 2 - a\{2,7}x + OK 0 - \vx(.{-,8})yz(.*) + OK 1 - \vx(.{-,8})yz(.*) + OK 2 - \vx(.{-,8})yz(.*) +*************** +*** 803,808 **** +--- 816,822 ---- + OK 2 - \_[^a]\+ + OK 0 - [0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12} + OK 1 - [0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12} ++ OK 2 - [0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12} + 192.168.0.1 + 192.168.0.1 + 192.168.0.1 +*** ../vim-7.3.1083/src/version.c 2013-05-31 22:14:48.000000000 +0200 +--- src/version.c 2013-05-31 23:10:36.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1084, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +34. You laugh at people with a 10 Mbit connection. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ee3896f1acf58e9cf0908a459b9097d13ccbe7a0 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:45 +0200 Subject: [PATCH 0976/3340] - patchlevel 1085 --- 7.3.1085 | 285 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 285 insertions(+) create mode 100644 7.3.1085 diff --git a/7.3.1085 b/7.3.1085 new file mode 100644 index 00000000..93952de6 --- /dev/null +++ b/7.3.1085 @@ -0,0 +1,285 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1085 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1085 +Problem: New regexp engine: Non-greedy multi doesn't work. +Solution: Implement \{-}. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1084/src/regexp_nfa.c 2013-05-31 23:17:56.000000000 +0200 +--- src/regexp_nfa.c 2013-06-01 12:22:17.000000000 +0200 +*************** +*** 38,46 **** + + NFA_CONCAT, + NFA_OR, +! NFA_STAR, +! NFA_QUEST, +! NFA_QUEST_NONGREEDY, /* Non-greedy version of \? */ + NFA_NOT, /* used for [^ab] negated char ranges */ + + NFA_BOL, /* ^ Begin line */ +--- 38,47 ---- + + NFA_CONCAT, + NFA_OR, +! NFA_STAR, /* greedy * */ +! NFA_STAR_NONGREEDY, /* non-greedy * */ +! NFA_QUEST, /* greedy \? */ +! NFA_QUEST_NONGREEDY, /* non-greedy \? */ + NFA_NOT, /* used for [^ab] negated char ranges */ + + NFA_BOL, /* ^ Begin line */ +*************** +*** 1430,1445 **** + } + /* {0,inf}, {0,} and {} are equivalent to + * * */ +! if (minval == 0 && maxval == MAX_LIMIT && greedy) + { +! EMIT(NFA_STAR); + break; + } + +- /* TODO: \{-} doesn't work yet */ +- if (maxval == MAX_LIMIT && !greedy) +- return FAIL; +- + /* Special case: x{0} or x{-0} */ + if (maxval == 0) + { +--- 1431,1447 ---- + } + /* {0,inf}, {0,} and {} are equivalent to + * * */ +! if (minval == 0 && maxval == MAX_LIMIT) + { +! if (greedy) +! /* \{}, \{0,} */ +! EMIT(NFA_STAR); +! else +! /* \{-}, \{-0,} */ +! EMIT(NFA_STAR_NONGREEDY); + break; + } + + /* Special case: x{0} or x{-0} */ + if (maxval == 0) + { +*************** +*** 1470,1476 **** + if (i + 1 > minval) + { + if (maxval == MAX_LIMIT) +! EMIT(NFA_STAR); + else + EMIT(quest); + } +--- 1472,1483 ---- + if (i + 1 > minval) + { + if (maxval == MAX_LIMIT) +! { +! if (greedy) +! EMIT(NFA_STAR); +! else +! EMIT(NFA_STAR_NONGREEDY); +! } + else + EMIT(quest); + } +*************** +*** 1776,1786 **** + case NFA_EOF: STRCPY(code, "NFA_EOF "); break; + case NFA_BOF: STRCPY(code, "NFA_BOF "); break; + case NFA_STAR: STRCPY(code, "NFA_STAR "); break; + case NFA_NOT: STRCPY(code, "NFA_NOT "); break; + case NFA_SKIP_CHAR: STRCPY(code, "NFA_SKIP_CHAR"); break; + case NFA_OR: STRCPY(code, "NFA_OR"); break; +- case NFA_QUEST: STRCPY(code, "NFA_QUEST"); break; +- case NFA_QUEST_NONGREEDY: STRCPY(code, "NFA_QUEST_NON_GREEDY"); break; + case NFA_END_NEG_RANGE: STRCPY(code, "NFA_END_NEG_RANGE"); break; + case NFA_CLASS_ALNUM: STRCPY(code, "NFA_CLASS_ALNUM"); break; + case NFA_CLASS_ALPHA: STRCPY(code, "NFA_CLASS_ALPHA"); break; +--- 1783,1794 ---- + case NFA_EOF: STRCPY(code, "NFA_EOF "); break; + case NFA_BOF: STRCPY(code, "NFA_BOF "); break; + case NFA_STAR: STRCPY(code, "NFA_STAR "); break; ++ case NFA_STAR_NONGREEDY: STRCPY(code, "NFA_STAR_NONGREEDY "); break; ++ case NFA_QUEST: STRCPY(code, "NFA_QUEST"); break; ++ case NFA_QUEST_NONGREEDY: STRCPY(code, "NFA_QUEST_NON_GREEDY"); break; + case NFA_NOT: STRCPY(code, "NFA_NOT "); break; + case NFA_SKIP_CHAR: STRCPY(code, "NFA_SKIP_CHAR"); break; + case NFA_OR: STRCPY(code, "NFA_OR"); break; + case NFA_END_NEG_RANGE: STRCPY(code, "NFA_END_NEG_RANGE"); break; + case NFA_CLASS_ALNUM: STRCPY(code, "NFA_CLASS_ALNUM"); break; + case NFA_CLASS_ALPHA: STRCPY(code, "NFA_CLASS_ALPHA"); break; +*************** +*** 2297,2303 **** + break; + + case NFA_STAR: +! /* Zero or more */ + if (nfa_calc_size == TRUE) + { + nstate++; +--- 2305,2311 ---- + break; + + case NFA_STAR: +! /* Zero or more, prefer more */ + if (nfa_calc_size == TRUE) + { + nstate++; +*************** +*** 2311,2316 **** +--- 2319,2339 ---- + PUSH(frag(s, list1(&s->out1))); + break; + ++ case NFA_STAR_NONGREEDY: ++ /* Zero or more, prefer zero */ ++ if (nfa_calc_size == TRUE) ++ { ++ nstate++; ++ break; ++ } ++ e = POP(); ++ s = new_state(NFA_SPLIT, NULL, e.start); ++ if (s == NULL) ++ goto theend; ++ patch(e.out, s); ++ PUSH(frag(s, list1(&s->out))); ++ break; ++ + case NFA_QUEST: + /* one or zero atoms=> greedy match */ + if (nfa_calc_size == TRUE) +*** ../vim-7.3.1084/src/testdir/test64.in 2013-05-31 23:17:56.000000000 +0200 +--- src/testdir/test64.in 2013-06-01 12:29:19.000000000 +0200 +*************** +*** 23,30 **** + :call add(tl, [2, 'ab', 'aab', 'ab']) + :call add(tl, [2, 'b', 'abcdef', 'b']) + :call add(tl, [2, 'bc*', 'abccccdef', 'bcccc']) +! :call add(tl, [0, 'bc\{-}', 'abccccdef', 'b']) +! :call add(tl, [0, 'bc\{-}\(d\)', 'abccccdef', 'bccccd', 'd']) + :call add(tl, [2, 'bc*', 'abbdef', 'b']) + :call add(tl, [2, 'c*', 'ccc', 'ccc']) + :call add(tl, [2, 'bc*', 'abdef', 'b']) +--- 23,30 ---- + :call add(tl, [2, 'ab', 'aab', 'ab']) + :call add(tl, [2, 'b', 'abcdef', 'b']) + :call add(tl, [2, 'bc*', 'abccccdef', 'bcccc']) +! :call add(tl, [2, 'bc\{-}', 'abccccdef', 'b']) +! :call add(tl, [2, 'bc\{-}\(d\)', 'abccccdef', 'bccccd', 'd']) + :call add(tl, [2, 'bc*', 'abbdef', 'b']) + :call add(tl, [2, 'c*', 'ccc', 'ccc']) + :call add(tl, [2, 'bc*', 'abdef', 'b']) +*************** +*** 201,216 **** + :call add(tl, [2, 'a\{-0}', 'asoiuj', '']) + :call add(tl, [2, 'a\{-2}', 'aaaa', 'aa']) + :call add(tl, [2, 'a\{-2}', 'abcdefghijklmnopqrestuvwxyz1234567890']) +! :call add(tl, [0, 'a\{-0,}', 'oij sdigfusnf', '']) +! :call add(tl, [0, 'a\{-0,}', 'aaaaa aa', '']) + :call add(tl, [2, 'a\{-2,}', 'sdfiougjdsafg']) +! :call add(tl, [0, 'a\{-2,}', 'aaaaasfoij ', 'aa']) + :call add(tl, [2, 'a\{-,0}', 'oidfguih iuhi hiu aaaa', '']) + :call add(tl, [2, 'a\{-,5}', 'abcd', '']) + :call add(tl, [2, 'a\{-,5}', 'aaaaaaaaaa', '']) + :" anti-greedy version of 'a*' +! :call add(tl, [0, 'a\{-}', 'bbbcddiuhfcd', '']) +! :call add(tl, [0, 'a\{-}', 'aaaaioudfh coisf jda', '']) + :" + :" Test groups of characters and submatches + :call add(tl, [2, '\(abc\)*', 'abcabcabc', 'abcabcabc', 'abc']) +--- 201,216 ---- + :call add(tl, [2, 'a\{-0}', 'asoiuj', '']) + :call add(tl, [2, 'a\{-2}', 'aaaa', 'aa']) + :call add(tl, [2, 'a\{-2}', 'abcdefghijklmnopqrestuvwxyz1234567890']) +! :call add(tl, [2, 'a\{-0,}', 'oij sdigfusnf', '']) +! :call add(tl, [2, 'a\{-0,}', 'aaaaa aa', '']) + :call add(tl, [2, 'a\{-2,}', 'sdfiougjdsafg']) +! :call add(tl, [2, 'a\{-2,}', 'aaaaasfoij ', 'aa']) + :call add(tl, [2, 'a\{-,0}', 'oidfguih iuhi hiu aaaa', '']) + :call add(tl, [2, 'a\{-,5}', 'abcd', '']) + :call add(tl, [2, 'a\{-,5}', 'aaaaaaaaaa', '']) + :" anti-greedy version of 'a*' +! :call add(tl, [2, 'a\{-}', 'bbbcddiuhfcd', '']) +! :call add(tl, [2, 'a\{-}', 'aaaaioudfh coisf jda', '']) + :" + :" Test groups of characters and submatches + :call add(tl, [2, '\(abc\)*', 'abcabcabc', 'abcabcabc', 'abc']) +*** ../vim-7.3.1084/src/testdir/test64.ok 2013-05-31 23:17:56.000000000 +0200 +--- src/testdir/test64.ok 2013-06-01 12:29:38.000000000 +0200 +*************** +*** 10,17 **** +--- 10,19 ---- + OK 2 - bc* + OK 0 - bc\{-} + OK 1 - bc\{-} ++ OK 2 - bc\{-} + OK 0 - bc\{-}\(d\) + OK 1 - bc\{-}\(d\) ++ OK 2 - bc\{-}\(d\) + OK 0 - bc* + OK 1 - bc* + OK 2 - bc* +*************** +*** 437,449 **** +--- 439,454 ---- + OK 2 - a\{-2} + OK 0 - a\{-0,} + OK 1 - a\{-0,} ++ OK 2 - a\{-0,} + OK 0 - a\{-0,} + OK 1 - a\{-0,} ++ OK 2 - a\{-0,} + OK 0 - a\{-2,} + OK 1 - a\{-2,} + OK 2 - a\{-2,} + OK 0 - a\{-2,} + OK 1 - a\{-2,} ++ OK 2 - a\{-2,} + OK 0 - a\{-,0} + OK 1 - a\{-,0} + OK 2 - a\{-,0} +*************** +*** 455,462 **** +--- 460,469 ---- + OK 2 - a\{-,5} + OK 0 - a\{-} + OK 1 - a\{-} ++ OK 2 - a\{-} + OK 0 - a\{-} + OK 1 - a\{-} ++ OK 2 - a\{-} + OK 0 - \(abc\)* + OK 1 - \(abc\)* + OK 2 - \(abc\)* +*** ../vim-7.3.1084/src/version.c 2013-05-31 23:17:56.000000000 +0200 +--- src/version.c 2013-06-01 12:39:01.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1085, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +35. Your husband tells you he's had the beard for 2 months. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ae76c096f76d9d08c933054287f7356463e43857 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:46 +0200 Subject: [PATCH 0977/3340] - patchlevel 1086 --- 7.3.1086 | 144 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 144 insertions(+) create mode 100644 7.3.1086 diff --git a/7.3.1086 b/7.3.1086 new file mode 100644 index 00000000..779977a4 --- /dev/null +++ b/7.3.1086 @@ -0,0 +1,144 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1086 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1086 +Problem: Old regexp engine accepts illegal range, new one doesn't. +Solution: Also accept the illegal range with the new engine. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1085/src/regexp_nfa.c 2013-06-01 12:40:14.000000000 +0200 +--- src/regexp_nfa.c 2013-06-01 13:16:34.000000000 +0200 +*************** +*** 1089,1096 **** + * while loop. */ + } + } +! /* Try a range like 'a-x' or '\t-z' */ +! if (*regparse == '-') + { + emit_range = TRUE; + startc = oldstartc; +--- 1089,1097 ---- + * while loop. */ + } + } +! /* Try a range like 'a-x' or '\t-z'. Also allows '-' as a +! * start character. */ +! if (*regparse == '-' && oldstartc != -1) + { + emit_range = TRUE; + startc = oldstartc; +*************** +*** 1140,1155 **** + + /* Normal printable char */ + if (startc == -1) +! #ifdef FEAT_MBYTE +! startc = (*mb_ptr2char)(regparse); +! #else +! startc = *regparse; +! #endif + + /* Previous char was '-', so this char is end of range. */ + if (emit_range) + { +! endc = startc; startc = oldstartc; + if (startc > endc) + EMSG_RET_FAIL(_(e_invrange)); + #ifdef FEAT_MBYTE +--- 1141,1153 ---- + + /* Normal printable char */ + if (startc == -1) +! startc = PTR2CHAR(regparse); + + /* Previous char was '-', so this char is end of range. */ + if (emit_range) + { +! endc = startc; +! startc = oldstartc; + if (startc > endc) + EMSG_RET_FAIL(_(e_invrange)); + #ifdef FEAT_MBYTE +*************** +*** 1166,1172 **** + TRY_NEG(); + EMIT_GLUE(); + } +- emit_range = FALSE; + } + else + #endif +--- 1164,1169 ---- +*************** +*** 1190,1197 **** + TRY_NEG(); + EMIT_GLUE(); + } +- emit_range = FALSE; + } + } + else + { +--- 1187,1195 ---- + TRY_NEG(); + EMIT_GLUE(); + } + } ++ emit_range = FALSE; ++ startc = -1; + } + else + { +*** ../vim-7.3.1085/src/testdir/test64.in 2013-06-01 12:40:14.000000000 +0200 +--- src/testdir/test64.in 2013-06-01 13:14:51.000000000 +0200 +*************** +*** 270,275 **** +--- 270,276 ---- + :call add(tl, [2, '\_[0-9]\+', "asfi\n9888u", "\n9888"]) + :call add(tl, [2, '\_f', " \na ", "\n"]) + :call add(tl, [2, '\_f\+', " \na ", "\na"]) ++ :call add(tl, [2, '[0-9A-Za-z-_.]\+', " @0_a.A-{ ", "0_a.A-"]) + :" + :"""" Test start/end of line, start/end of file + :call add(tl, [2, '^a.', "a_\nb ", "a_"]) +*** ../vim-7.3.1085/src/testdir/test64.ok 2013-06-01 12:40:14.000000000 +0200 +--- src/testdir/test64.ok 2013-06-01 13:22:58.000000000 +0200 +*************** +*** 605,610 **** +--- 605,613 ---- + OK 0 - \_f\+ + OK 1 - \_f\+ + OK 2 - \_f\+ ++ OK 0 - [0-9A-Za-z-_.]\+ ++ OK 1 - [0-9A-Za-z-_.]\+ ++ OK 2 - [0-9A-Za-z-_.]\+ + OK 0 - ^a. + OK 1 - ^a. + OK 2 - ^a. +*** ../vim-7.3.1085/src/version.c 2013-06-01 12:40:14.000000000 +0200 +--- src/version.c 2013-06-01 13:17:56.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1086, + /**/ + +-- +Micro$oft: where do you want to go today? + Linux: where do you want to go tomorrow? + FreeBSD: are you guys coming, or what? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b3183e447d2ade14440fce3c5f48bbf04bcb5fb6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:46 +0200 Subject: [PATCH 0978/3340] - patchlevel 1087 --- 7.3.1087 | 255 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 255 insertions(+) create mode 100644 7.3.1087 diff --git a/7.3.1087 b/7.3.1087 new file mode 100644 index 00000000..d751f342 --- /dev/null +++ b/7.3.1087 @@ -0,0 +1,255 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1087 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1087 +Problem: A leading star is not seen as a normal char when \{} follows. +Solution: Save and restore the parse state properly. +Files: src/regexp.c, src/regexp_nfa.c, src/testdir/test64.in, + src/testdir/test64.ok + + +*** ../vim-7.3.1086/src/regexp.c 2013-05-29 18:45:07.000000000 +0200 +--- src/regexp.c 2013-06-01 14:33:26.000000000 +0200 +*************** +*** 665,674 **** +--- 665,689 ---- + #define REG_ZPAREN 2 /* \z(\) */ + #define REG_NPAREN 3 /* \%(\) */ + ++ typedef struct ++ { ++ char_u *regparse; ++ int prevchr_len; ++ int curchr; ++ int prevchr; ++ int prevprevchr; ++ int nextchr; ++ int at_start; ++ int prev_at_start; ++ int regnpar; ++ } parse_state_T; ++ + /* + * Forward declarations for vim_regcomp()'s friends. + */ + static void initchr __ARGS((char_u *)); ++ static void save_parse_state __ARGS((parse_state_T *ps)); ++ static void restore_parse_state __ARGS((parse_state_T *ps)); + static int getchr __ARGS((void)); + static void skipchr_keepstart __ARGS((void)); + static int peekchr __ARGS((void)); +*************** +*** 2951,2956 **** +--- 2966,3009 ---- + } + + /* ++ * Save the current parse state, so that it can be restored and parsing ++ * starts in the same state again. ++ */ ++ static void ++ save_parse_state(ps) ++ parse_state_T *ps; ++ { ++ ps->regparse = regparse; ++ ps->prevchr_len = prevchr_len; ++ ps->curchr = curchr; ++ ps->prevchr = prevchr; ++ ps->prevprevchr = prevprevchr; ++ ps->nextchr = nextchr; ++ ps->at_start = at_start; ++ ps->prev_at_start = prev_at_start; ++ ps->regnpar = regnpar; ++ } ++ ++ /* ++ * Restore a previously saved parse state. ++ */ ++ static void ++ restore_parse_state(ps) ++ parse_state_T *ps; ++ { ++ regparse = ps->regparse; ++ prevchr_len = ps->prevchr_len; ++ curchr = ps->curchr; ++ prevchr = ps->prevchr; ++ prevprevchr = ps->prevprevchr; ++ nextchr = ps->nextchr; ++ at_start = ps->at_start; ++ prev_at_start = ps->prev_at_start; ++ regnpar = ps->regnpar; ++ } ++ ++ ++ /* + * Get the next character without advancing. + */ + static int +*** ../vim-7.3.1086/src/regexp_nfa.c 2013-06-01 13:24:19.000000000 +0200 +--- src/regexp_nfa.c 2013-06-01 14:30:27.000000000 +0200 +*************** +*** 1318,1336 **** + int ret; + long minval, maxval; + int greedy = TRUE; /* Braces are prefixed with '-' ? */ +! char_u *old_regparse, *new_regparse; + int c2; + int old_post_pos; + int my_post_start; +- int old_regnpar; + int quest; + +! /* Save the current position in the regexp, so that we can use it if +! * {m,n} is next. */ +! old_regparse = regparse; +! /* Save current number of open parenthesis, so we can use it if +! * {m,n} is next */ +! old_regnpar = regnpar; + /* store current pos in the postfix form, for \{m,n} involving 0s */ + my_post_start = (int)(post_ptr - post_start); + +--- 1318,1334 ---- + int ret; + long minval, maxval; + int greedy = TRUE; /* Braces are prefixed with '-' ? */ +! parse_state_T old_state; +! parse_state_T new_state; + int c2; + int old_post_pos; + int my_post_start; + int quest; + +! /* Save the current parse state, so that we can use it if {m,n} is +! * next. */ +! save_parse_state(&old_state); +! + /* store current pos in the postfix form, for \{m,n} involving 0s */ + my_post_start = (int)(post_ptr - post_start); + +*************** +*** 1361,1368 **** + * In order to be consistent with the old engine, we replace + * + with * + */ +! regnpar = old_regnpar; +! regparse = old_regparse; + curchr = -1; + if (nfa_regatom() == FAIL) + return FAIL; +--- 1359,1365 ---- + * In order to be consistent with the old engine, we replace + * + with * + */ +! restore_parse_state(&old_state); + curchr = -1; + if (nfa_regatom() == FAIL) + return FAIL; +*************** +*** 1452,1468 **** + + /* Ignore previous call to nfa_regatom() */ + post_ptr = post_start + my_post_start; +! /* Save pos after the repeated atom and the \{} */ +! new_regparse = regparse; + + quest = (greedy == TRUE? NFA_QUEST : NFA_QUEST_NONGREEDY); + for (i = 0; i < maxval; i++) + { + /* Goto beginning of the repeated atom */ +! regparse = old_regparse; +! curchr = -1; +! /* Restore count of parenthesis */ +! regnpar = old_regnpar; + old_post_pos = (int)(post_ptr - post_start); + if (nfa_regatom() == FAIL) + return FAIL; +--- 1449,1462 ---- + + /* Ignore previous call to nfa_regatom() */ + post_ptr = post_start + my_post_start; +! /* Save parse state after the repeated atom and the \{} */ +! save_parse_state(&new_state); + + quest = (greedy == TRUE? NFA_QUEST : NFA_QUEST_NONGREEDY); + for (i = 0; i < maxval; i++) + { + /* Goto beginning of the repeated atom */ +! restore_parse_state(&old_state); + old_post_pos = (int)(post_ptr - post_start); + if (nfa_regatom() == FAIL) + return FAIL; +*************** +*** 1486,1492 **** + } + + /* Go to just after the repeated atom and the \{} */ +! regparse = new_regparse; + curchr = -1; + + break; +--- 1480,1486 ---- + } + + /* Go to just after the repeated atom and the \{} */ +! restore_parse_state(&new_state); + curchr = -1; + + break; +*** ../vim-7.3.1086/src/testdir/test64.in 2013-06-01 13:24:19.000000000 +0200 +--- src/testdir/test64.in 2013-06-01 14:36:15.000000000 +0200 +*************** +*** 188,193 **** +--- 188,197 ---- + :call add(tl, [2, 'a\{,0}', 'oidfguih iuhi hiu aaaa', '']) + :call add(tl, [2, 'a\{,5}', 'abcd', 'a']) + :call add(tl, [2, 'a\{,5}', 'aaaaaaaaaa', 'aaaaa']) ++ :" leading star as normal char when \{} follows ++ :call add(tl, [2, '^*\{4,}$', '***']) ++ :call add(tl, [2, '^*\{4,}$', '****', '****']) ++ :call add(tl, [2, '^*\{4,}$', '*****', '*****']) + :" same thing as 'a*' + :call add(tl, [2, 'a\{}', 'bbbcddiuhfcd', '']) + :call add(tl, [2, 'a\{}', 'aaaaioudfh coisf jda', 'aaaa']) +*** ../vim-7.3.1086/src/testdir/test64.ok 2013-06-01 13:24:19.000000000 +0200 +--- src/testdir/test64.ok 2013-06-01 14:36:39.000000000 +0200 +*************** +*** 407,412 **** +--- 407,421 ---- + OK 0 - a\{,5} + OK 1 - a\{,5} + OK 2 - a\{,5} ++ OK 0 - ^*\{4,}$ ++ OK 1 - ^*\{4,}$ ++ OK 2 - ^*\{4,}$ ++ OK 0 - ^*\{4,}$ ++ OK 1 - ^*\{4,}$ ++ OK 2 - ^*\{4,}$ ++ OK 0 - ^*\{4,}$ ++ OK 1 - ^*\{4,}$ ++ OK 2 - ^*\{4,}$ + OK 0 - a\{} + OK 1 - a\{} + OK 2 - a\{} +*** ../vim-7.3.1086/src/version.c 2013-06-01 13:24:19.000000000 +0200 +--- src/version.c 2013-06-01 14:37:37.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1087, + /**/ + +-- +Change is inevitable, except from a vending machine. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bec9c65f726a25eb93e06ea65b76cb19cc90505e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:47 +0200 Subject: [PATCH 0979/3340] - patchlevel 1088 --- 7.3.1088 | 626 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 626 insertions(+) create mode 100644 7.3.1088 diff --git a/7.3.1088 b/7.3.1088 new file mode 100644 index 00000000..108cc44f --- /dev/null +++ b/7.3.1088 @@ -0,0 +1,626 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1088 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1088 +Problem: New regexp engine: \@<= and \@rs_scan); + if (REG_MULTI) + { +! if (rp->rs_un.regsave.rs_u.pos.col == 0) + { + if (rp->rs_un.regsave.rs_u.pos.lnum + < behind_pos.rs_u.pos.lnum +--- 5576,5589 ---- + limit = OPERAND_MIN(rp->rs_scan); + if (REG_MULTI) + { +! if (limit > 0 +! && ((rp->rs_un.regsave.rs_u.pos.lnum +! < behind_pos.rs_u.pos.lnum +! ? (colnr_T)STRLEN(regline) +! : behind_pos.rs_u.pos.col) +! - rp->rs_un.regsave.rs_u.pos.col >= limit)) +! no = FAIL; +! else if (rp->rs_un.regsave.rs_u.pos.col == 0) + { + if (rp->rs_un.regsave.rs_u.pos.lnum + < behind_pos.rs_u.pos.lnum +*************** +*** 5601,5613 **** + else + #endif + --rp->rs_un.regsave.rs_u.pos.col; +- if (limit > 0 +- && ((rp->rs_un.regsave.rs_u.pos.lnum +- < behind_pos.rs_u.pos.lnum +- ? (colnr_T)STRLEN(regline) +- : behind_pos.rs_u.pos.col) +- - rp->rs_un.regsave.rs_u.pos.col > limit)) +- no = FAIL; + } + } + else +--- 5608,5613 ---- +*** ../vim-7.3.1087/src/regexp_nfa.c 2013-06-01 14:42:51.000000000 +0200 +--- src/regexp_nfa.c 2013-06-01 19:42:22.000000000 +0200 +*************** +*** 56,61 **** +--- 56,62 ---- + NFA_NOPEN, /* Start of subexpression marked with \%( */ + NFA_NCLOSE, /* End of subexpr. marked with \%( ... \) */ + NFA_START_INVISIBLE, ++ NFA_START_INVISIBLE_BEFORE, + NFA_END_INVISIBLE, + NFA_COMPOSING, /* Next nodes in NFA are part of the + composing multibyte char */ +*************** +*** 1369,1402 **** + break; + + case Magic('@'): + op = no_Magic(getchr()); + switch(op) + { + case '=': +! EMIT(NFA_PREV_ATOM_NO_WIDTH); + break; + case '!': +! EMIT(NFA_PREV_ATOM_NO_WIDTH_NEG); + break; +- case '0': +- case '1': +- case '2': +- case '3': +- case '4': +- case '5': +- case '6': +- case '7': +- case '8': +- case '9': + case '<': + case '>': +! /* Not supported yet */ +! return FAIL; +! default: +! syntax_error = TRUE; +! EMSGN(_("E869: (NFA) Unknown operator '\\@%c'"), op); + return FAIL; + } + break; + + case Magic('?'): +--- 1370,1412 ---- + break; + + case Magic('@'): ++ c2 = getdecchrs(); + op = no_Magic(getchr()); ++ i = 0; + switch(op) + { + case '=': +! /* \@= */ +! i = NFA_PREV_ATOM_NO_WIDTH; + break; + case '!': +! /* \@! */ +! i = NFA_PREV_ATOM_NO_WIDTH_NEG; + break; + case '<': ++ op = no_Magic(getchr()); ++ if (op == '=') ++ /* \@<= */ ++ i = NFA_PREV_ATOM_JUST_BEFORE; ++ else if (op == '!') ++ /* \@': +! /* \@> Not supported yet */ +! /* i = NFA_PREV_ATOM_LIKE_PATTERN; */ + return FAIL; + } ++ if (i == 0) ++ { ++ syntax_error = TRUE; ++ EMSGN(_("E869: (NFA) Unknown operator '\\@%c'"), op); ++ return FAIL; ++ } ++ EMIT(i); ++ if (i == NFA_PREV_ATOM_JUST_BEFORE ++ || i == NFA_PREV_ATOM_JUST_BEFORE_NEG) ++ EMIT(c2); + break; + + case Magic('?'): +*************** +*** 1734,1742 **** +--- 1744,1758 ---- + STRCPY(code, "NFA_PREV_ATOM_NO_WIDTH"); break; + case NFA_PREV_ATOM_NO_WIDTH_NEG: + STRCPY(code, "NFA_PREV_ATOM_NO_WIDTH_NEG"); break; ++ case NFA_PREV_ATOM_JUST_BEFORE: ++ STRCPY(code, "NFA_PREV_ATOM_JUST_BEFORE"); break; ++ case NFA_PREV_ATOM_JUST_BEFORE_NEG: ++ STRCPY(code, "NFA_PREV_ATOM_JUST_BEFORE_NEG"); break; + case NFA_NOPEN: STRCPY(code, "NFA_NOPEN"); break; + case NFA_NCLOSE: STRCPY(code, "NFA_NCLOSE"); break; + case NFA_START_INVISIBLE: STRCPY(code, "NFA_START_INVISIBLE"); break; ++ case NFA_START_INVISIBLE_BEFORE: ++ STRCPY(code, "NFA_START_INVISIBLE_BEFORE"); break; + case NFA_END_INVISIBLE: STRCPY(code, "NFA_END_INVISIBLE"); break; + + case NFA_COMPOSING: STRCPY(code, "NFA_COMPOSING"); break; +*************** +*** 2237,2243 **** + if (nfa_calc_size == FALSE) + { + /* Allocate space for the stack. Max states on the stack : nstate */ +! stack = (Frag_T *) lalloc((nstate + 1) * sizeof(Frag_T), TRUE); + stackp = stack; + stack_end = stack + (nstate + 1); + } +--- 2253,2259 ---- + if (nfa_calc_size == FALSE) + { + /* Allocate space for the stack. Max states on the stack : nstate */ +! stack = (Frag_T *)lalloc((nstate + 1) * sizeof(Frag_T), TRUE); + stackp = stack; + stack_end = stack + (nstate + 1); + } +*************** +*** 2370,2377 **** +--- 2386,2397 ---- + + case NFA_PREV_ATOM_NO_WIDTH: + case NFA_PREV_ATOM_NO_WIDTH_NEG: ++ case NFA_PREV_ATOM_JUST_BEFORE: ++ case NFA_PREV_ATOM_JUST_BEFORE_NEG: + /* The \@= operator: match the preceding atom with zero width. + * The \@! operator: no match for the preceding atom. ++ * The \@<= operator: match for the preceding atom. ++ * The \@negated = TRUE; + s1->negated = TRUE; + } + + PUSH(frag(s, list1(&s1->out))); + break; +--- 2409,2426 ---- + s = new_state(NFA_START_INVISIBLE, e.start, s1); + if (s == NULL) + goto theend; +! if (*p == NFA_PREV_ATOM_NO_WIDTH_NEG +! || *p == NFA_PREV_ATOM_JUST_BEFORE_NEG) + { + s->negated = TRUE; + s1->negated = TRUE; + } ++ if (*p == NFA_PREV_ATOM_JUST_BEFORE ++ || *p == NFA_PREV_ATOM_JUST_BEFORE_NEG) ++ { ++ s->val = *++p; /* get the count */ ++ ++s->c; /* NFA_START_INVISIBLE -> NFA_START_INVISIBLE_BEFORE */ ++ } + + PUSH(frag(s, list1(&s1->out))); + break; +*************** +*** 3307,3327 **** + return val == pos; + } + +! static int nfa_regmatch __ARGS((nfa_state_T *start, regsub_T *submatch, regsub_T *m)); + + /* + * Main matching routine. + * + * Run NFA to determine whether it matches reginput. + * + * Return TRUE if there is a match, FALSE otherwise. + * Note: Caller must ensure that: start != NULL. + */ + static int +! nfa_regmatch(start, submatch, m) + nfa_state_T *start; + regsub_T *submatch; + regsub_T *m; + { + int result; + int size = 0; +--- 3334,3357 ---- + return val == pos; + } + +! static int nfa_regmatch __ARGS((nfa_state_T *start, regsub_T *submatch, regsub_T *m, save_se_T *endp)); + + /* + * Main matching routine. + * + * Run NFA to determine whether it matches reginput. + * ++ * When "endp" is not NULL it is a required end-of-match position. ++ * + * Return TRUE if there is a match, FALSE otherwise. + * Note: Caller must ensure that: start != NULL. + */ + static int +! nfa_regmatch(start, submatch, m, endp) + nfa_state_T *start; + regsub_T *submatch; + regsub_T *m; ++ save_se_T *endp; + { + int result; + int size = 0; +*************** +*** 3532,3547 **** + } + + case NFA_END_INVISIBLE: +! /* This is only encountered after a NFA_START_INVISIBLE node. +! * They surround a zero-width group, used with "\@=" and "\&". + * If we got here, it means that the current "invisible" group + * finished successfully, so return control to the parent + * nfa_regmatch(). Submatches are stored in *m, and used in + * the parent call. */ + if (start->c == NFA_MOPEN + 0) + addstate_here(thislist, t->state->out, &t->sub, &listidx); + else + { + /* do not set submatches for \@! */ + if (!t->state->negated) + /* TODO: only copy positions in use. */ +--- 3562,3603 ---- + } + + case NFA_END_INVISIBLE: +! /* This is only encountered after a NFA_START_INVISIBLE or +! * NFA_START_INVISIBLE_BEFORE node. +! * They surround a zero-width group, used with "\@=", "\&", +! * "\@!", "\@<=" and "\@c == NFA_MOPEN + 0) ++ /* TODO: do we ever get here? */ + addstate_here(thislist, t->state->out, &t->sub, &listidx); + else + { ++ #ifdef ENABLE_LOG ++ if (endp != NULL) ++ { ++ if (REG_MULTI) ++ fprintf(log_fd, "Current lnum: %d, endp lnum: %d; current col: %d, endp col: %d\n", ++ (int)reglnum, ++ (int)endp->se_u.pos.lnum, ++ (int)(reginput - regline), ++ endp->se_u.pos.col); ++ else ++ fprintf(log_fd, "Current col: %d, endp col: %d\n", ++ (int)(reginput - regline), ++ (int)(endp->se_u.ptr - reginput)); ++ } ++ #endif ++ /* It's only a match if it ends at "endp" */ ++ if (endp != NULL && (REG_MULTI ++ ? (reglnum != endp->se_u.pos.lnum ++ || (int)(reginput - regline) ++ != endp->se_u.pos.col) ++ : reginput != endp->se_u.ptr)) ++ break; ++ + /* do not set submatches for \@! */ + if (!t->state->negated) + /* TODO: only copy positions in use. */ +*************** +*** 3551,3561 **** + break; + + case NFA_START_INVISIBLE: + { +! char_u *save_reginput = reginput; +! char_u *save_regline = regline; +! int save_reglnum = reglnum; +! int save_nfa_match = nfa_match; + + /* Call nfa_regmatch() to check if the current concat matches + * at this position. The concat ends with the node +--- 3607,3676 ---- + break; + + case NFA_START_INVISIBLE: ++ case NFA_START_INVISIBLE_BEFORE: + { +! char_u *save_reginput = reginput; +! char_u *save_regline = regline; +! int save_reglnum = reglnum; +! int save_nfa_match = nfa_match; +! save_se_T endpos; +! save_se_T *endposp = NULL; +! +! if (t->state->c == NFA_START_INVISIBLE_BEFORE) +! { +! /* The recursive match must end at the current position. */ +! endposp = &endpos; +! if (REG_MULTI) +! { +! endpos.se_u.pos.col = (int)(reginput - regline); +! endpos.se_u.pos.lnum = reglnum; +! } +! else +! endpos.se_u.ptr = reginput; +! +! /* Go back the specified number of bytes, or as far as the +! * start of the previous line, to try matching "\@<=" or +! * not matching "\@state->val <= 0) +! { +! if (REG_MULTI) +! { +! regline = reg_getline(--reglnum); +! if (regline == NULL) +! /* can't go before the first line */ +! regline = reg_getline(++reglnum); +! } +! reginput = regline; +! } +! else +! { +! if (REG_MULTI +! && (int)(reginput - regline) < t->state->val) +! { +! /* Not enough bytes in this line, go to end of +! * previous line. */ +! regline = reg_getline(--reglnum); +! if (regline == NULL) +! { +! /* can't go before the first line */ +! regline = reg_getline(++reglnum); +! reginput = regline; +! } +! else +! reginput = regline + STRLEN(regline); +! } +! if ((int)(reginput - regline) >= t->state->val) +! { +! reginput -= t->state->val; +! #ifdef FEAT_MBYTE +! if (has_mbyte) +! reginput -= mb_head_off(regline, reginput); +! #endif +! } +! else +! reginput = regline; +! } +! } + + /* Call nfa_regmatch() to check if the current concat matches + * at this position. The concat ends with the node +*************** +*** 3579,3585 **** + * recursion. */ + nfa_save_listids(start, listids); + nfa_set_null_listids(start); +! result = nfa_regmatch(t->state->out, submatch, m); + nfa_set_neg_listids(start); + nfa_restore_listids(start, listids); + +--- 3694,3700 ---- + * recursion. */ + nfa_save_listids(start, listids); + nfa_set_null_listids(start); +! result = nfa_regmatch(t->state->out, submatch, m, endposp); + nfa_set_neg_listids(start); + nfa_restore_listids(start, listids); + +*************** +*** 4120,4130 **** + * matters! + * Do not add the start state in recursive calls of nfa_regmatch(), + * because recursive calls should only start in the first position. + * Also don't start a match past the first line. */ +! if (nfa_match == FALSE && start->c == NFA_MOPEN + 0 +! && reglnum == 0 && clen != 0 +! && (ireg_maxcol == 0 +! || (colnr_T)(reginput - regline) < ireg_maxcol)) + { + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); +--- 4235,4255 ---- + * matters! + * Do not add the start state in recursive calls of nfa_regmatch(), + * because recursive calls should only start in the first position. ++ * Unless "endp" is not NULL, then we match the end position. + * Also don't start a match past the first line. */ +! if (nfa_match == FALSE +! && ((start->c == NFA_MOPEN + 0 +! && reglnum == 0 +! && clen != 0 +! && (ireg_maxcol == 0 +! || (colnr_T)(reginput - regline) < ireg_maxcol)) +! || (endp != NULL +! && (REG_MULTI +! ? (reglnum < endp->se_u.pos.lnum +! || (reglnum == endp->se_u.pos.lnum +! && (int)(reginput - regline) +! < endp->se_u.pos.col)) +! : reginput < endp->se_u.ptr)))) + { + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); +*************** +*** 4148,4154 **** + * finish. */ + if (clen != 0) + reginput += clen; +! else if (go_to_nextline) + reg_nextline(); + else + break; +--- 4273,4280 ---- + * finish. */ + if (clen != 0) + reginput += clen; +! else if (go_to_nextline || (endp != NULL && REG_MULTI +! && reglnum < endp->se_u.pos.lnum)) + reg_nextline(); + else + break; +*************** +*** 4225,4231 **** + sub.in_use = 0; + m.in_use = 0; + +! if (nfa_regmatch(start, &sub, &m) == FALSE) + return 0; + + cleanup_subexpr(); +--- 4351,4357 ---- + sub.in_use = 0; + m.in_use = 0; + +! if (nfa_regmatch(start, &sub, &m, NULL) == FALSE) + return 0; + + cleanup_subexpr(); +*** ../vim-7.3.1087/src/testdir/test64.in 2013-06-01 14:42:51.000000000 +0200 +--- src/testdir/test64.in 2013-06-01 18:45:09.000000000 +0200 +*************** +*** 363,374 **** + :call add(tl, [2, '\(a\)\(b\)\(c\)\(dd\)\(e\)\(f\)\(g\)\(h\)\(i\)\1\2\3\4\5\6\7\8\9', 'xabcddefghiabcddefghix', 'abcddefghiabcddefghi', 'a', 'b', 'c', 'dd', 'e', 'f', 'g', 'h', 'i']) + :" + :"""" Look-behind with limit +! :call add(tl, [0, '<\@<=span.', 'xxspanxxAc 7 + ghi + +! xxxstart3 + -0- + ffo + bob +--- 853,859 ---- + Ac 7 + ghi + +! xxstart3 + -0- + ffo + bob +*** ../vim-7.3.1087/src/version.c 2013-06-01 14:42:51.000000000 +0200 +--- src/version.c 2013-06-01 18:37:11.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1088, + /**/ + +-- +Seen it all, done it all, can't remember most of it. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f69b498740ecd7330781a2f152885b12609c367c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:48 +0200 Subject: [PATCH 0980/3340] - patchlevel 1089 --- 7.3.1089 | 155 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 155 insertions(+) create mode 100644 7.3.1089 diff --git a/7.3.1089 b/7.3.1089 new file mode 100644 index 00000000..6b8a4b6a --- /dev/null +++ b/7.3.1089 @@ -0,0 +1,155 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1089 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1089 +Problem: Tests 86 and 87 fail on MS-Windows. (Ken Takata) +Solution: Fix platform-specific stuff. (ZyX) +Files: src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.1088/src/testdir/test86.in 2013-05-31 19:01:13.000000000 +0200 +--- src/testdir/test86.in 2013-06-01 20:27:14.000000000 +0200 +*************** +*** 435,440 **** +--- 435,441 ---- + :py bopts1=vim.buffers[vim.bindeval("g:bufs")[2]].options + :py bopts2=vim.buffers[vim.bindeval("g:bufs")[1]].options + :py bopts3=vim.buffers[vim.bindeval("g:bufs")[0]].options ++ :set path=.,..,, + :let lst=[] + :let lst+=[['paste', 1, 0, 1, 2, 1, 1, 0 ]] + :let lst+=[['previewheight', 5, 1, 6, 'a', 0, 1, 0 ]] +*************** +*** 530,542 **** + b[0:0]=['baz'] + vim.command('call append("$", getbufline(%i, 1, "$"))' % b.number) + # Test assigning to name property + old_name = cb.name + cb.name = 'foo' +! cb.append(cb.name[-11:]) + b.name = 'bar' +! cb.append(b.name[-11:]) + cb.name = old_name +! cb.append(cb.name[-17:]) + # Test CheckBuffer + for _b in vim.buffers: + if _b is not cb: +--- 531,544 ---- + b[0:0]=['baz'] + vim.command('call append("$", getbufline(%i, 1, "$"))' % b.number) + # Test assigning to name property ++ import os + old_name = cb.name + cb.name = 'foo' +! cb.append(cb.name[-11:].replace(os.path.sep, '/')) + b.name = 'bar' +! cb.append(b.name[-11:].replace(os.path.sep, '/')) + cb.name = old_name +! cb.append(cb.name[-17:].replace(os.path.sep, '/')) + # Test CheckBuffer + for _b in vim.buffers: + if _b is not cb: +*** ../vim-7.3.1088/src/testdir/test86.ok 2013-05-31 19:01:13.000000000 +0200 +--- src/testdir/test86.ok 2013-06-01 20:27:14.000000000 +0200 +*************** +*** 310,316 **** + W: 1:0 2:1 3:0 4:1 + B: 1:0 2:1 3:0 4:1 + >>> path +! p/gopts1: '.,/usr/include,,' + inv: 0! TypeError + p/wopts1! KeyError + inv: 0! KeyError +--- 310,316 ---- + W: 1:0 2:1 3:0 4:1 + B: 1:0 2:1 3:0 4:1 + >>> path +! p/gopts1: '.,..,,' + inv: 0! TypeError + p/wopts1! KeyError + inv: 0! KeyError +*** ../vim-7.3.1088/src/testdir/test87.in 2013-05-31 18:46:06.000000000 +0200 +--- src/testdir/test87.in 2013-06-01 20:27:14.000000000 +0200 +*************** +*** 404,409 **** +--- 404,410 ---- + :py3 bopts1=vim.buffers[vim.bindeval("g:bufs")[2]].options + :py3 bopts2=vim.buffers[vim.bindeval("g:bufs")[1]].options + :py3 bopts3=vim.buffers[vim.bindeval("g:bufs")[0]].options ++ :set path=.,..,, + :let lst=[] + :let lst+=[['paste', 1, 0, 1, 2, 1, 1, 0 ]] + :let lst+=[['previewheight', 5, 1, 6, 'a', 0, 1, 0 ]] +*************** +*** 499,511 **** + b[0:0]=['baz'] + vim.command('call append("$", getbufline(%i, 1, "$"))' % b.number) + # Test assigning to name property + old_name = cb.name + cb.name = 'foo' +! cb.append(cb.name[-11:]) + b.name = 'bar' +! cb.append(b.name[-11:]) + cb.name = old_name +! cb.append(cb.name[-17:]) + # Test CheckBuffer + for _b in vim.buffers: + if _b is not cb: +--- 500,513 ---- + b[0:0]=['baz'] + vim.command('call append("$", getbufline(%i, 1, "$"))' % b.number) + # Test assigning to name property ++ import os + old_name = cb.name + cb.name = 'foo' +! cb.append(cb.name[-11:].replace(os.path.sep, '/')) + b.name = 'bar' +! cb.append(b.name[-11:].replace(os.path.sep, '/')) + cb.name = old_name +! cb.append(cb.name[-17:].replace(os.path.sep, '/')) + # Test CheckBuffer + for _b in vim.buffers: + if _b is not cb: +*** ../vim-7.3.1088/src/testdir/test87.ok 2013-05-31 18:46:06.000000000 +0200 +--- src/testdir/test87.ok 2013-06-01 20:27:14.000000000 +0200 +*************** +*** 299,305 **** + W: 1:0 2:1 3:0 4:1 + B: 1:0 2:1 3:0 4:1 + >>> path +! p/gopts1: b'.,/usr/include,,' + inv: 0! TypeError + p/wopts1! KeyError + inv: 0! KeyError +--- 299,305 ---- + W: 1:0 2:1 3:0 4:1 + B: 1:0 2:1 3:0 4:1 + >>> path +! p/gopts1: b'.,..,,' + inv: 0! TypeError + p/wopts1! KeyError + inv: 0! KeyError +*** ../vim-7.3.1088/src/version.c 2013-06-01 19:54:39.000000000 +0200 +--- src/version.c 2013-06-01 20:28:22.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1089, + /**/ + +-- +I wonder how much deeper the ocean would be without sponges. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3d1a0d1d02cb354d8effd8b52cf44578d31850ca Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:48 +0200 Subject: [PATCH 0981/3340] - patchlevel 1090 --- 7.3.1090 | 1893 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1893 insertions(+) create mode 100644 7.3.1090 diff --git a/7.3.1090 b/7.3.1090 new file mode 100644 index 00000000..1278fae5 --- /dev/null +++ b/7.3.1090 @@ -0,0 +1,1893 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.10 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1090 +Problem: New regexp engine does not support \z1 .. \z9 and \z(. +Solution: Implement the syntax submatches. +Files: src/regexp.h, src/regexp_nfa.c + + +*** ../vim-7.3.1089/src/regexp.h 2013-05-30 17:05:34.000000000 +0200 +--- src/regexp.h 2013-06-01 22:18:07.000000000 +0200 +*************** +*** 55,61 **** +--- 55,63 ---- + char_u reganch; + char_u *regmust; + int regmlen; ++ #ifdef FEAT_SYN_HL + char_u reghasz; ++ #endif + char_u program[1]; /* actually longer.. */ + } bt_regprog_T; + +*************** +*** 88,93 **** +--- 90,98 ---- + nfa_state_T *start; + int has_zend; /* pattern contains \ze */ + int has_backref; /* pattern contains \1 .. \9 */ ++ #ifdef FEAT_SYN_HL ++ int reghasz; ++ #endif + int nsubexp; /* number of () */ + int nstate; + nfa_state_T state[0]; /* actually longer.. */ +*** ../vim-7.3.1089/src/regexp_nfa.c 2013-06-01 19:54:39.000000000 +0200 +--- src/regexp_nfa.c 2013-06-01 22:54:08.000000000 +0200 +*************** +*** 78,90 **** + NFA_BACKREF7, /* \7 */ + NFA_BACKREF8, /* \8 */ + NFA_BACKREF9, /* \9 */ + NFA_SKIP, /* Skip characters */ + + NFA_MOPEN, +! NFA_MCLOSE = NFA_MOPEN + NSUBEXP, + + /* NFA_FIRST_NL */ +! NFA_ANY = NFA_MCLOSE + NSUBEXP, /* Match any one character. */ + NFA_ANYOF, /* Match any character in this string. */ + NFA_ANYBUT, /* Match any character not in this string. */ + NFA_IDENT, /* Match identifier char */ +--- 78,144 ---- + NFA_BACKREF7, /* \7 */ + NFA_BACKREF8, /* \8 */ + NFA_BACKREF9, /* \9 */ ++ #ifdef FEAT_SYN_HL ++ NFA_ZREF1, /* \z1 */ ++ NFA_ZREF2, /* \z2 */ ++ NFA_ZREF3, /* \z3 */ ++ NFA_ZREF4, /* \z4 */ ++ NFA_ZREF5, /* \z5 */ ++ NFA_ZREF6, /* \z6 */ ++ NFA_ZREF7, /* \z7 */ ++ NFA_ZREF8, /* \z8 */ ++ NFA_ZREF9, /* \z9 */ ++ #endif + NFA_SKIP, /* Skip characters */ + + NFA_MOPEN, +! NFA_MOPEN1, +! NFA_MOPEN2, +! NFA_MOPEN3, +! NFA_MOPEN4, +! NFA_MOPEN5, +! NFA_MOPEN6, +! NFA_MOPEN7, +! NFA_MOPEN8, +! NFA_MOPEN9, +! +! NFA_MCLOSE, +! NFA_MCLOSE1, +! NFA_MCLOSE2, +! NFA_MCLOSE3, +! NFA_MCLOSE4, +! NFA_MCLOSE5, +! NFA_MCLOSE6, +! NFA_MCLOSE7, +! NFA_MCLOSE8, +! NFA_MCLOSE9, +! +! #ifdef FEAT_SYN_HL +! NFA_ZOPEN, +! NFA_ZOPEN1, +! NFA_ZOPEN2, +! NFA_ZOPEN3, +! NFA_ZOPEN4, +! NFA_ZOPEN5, +! NFA_ZOPEN6, +! NFA_ZOPEN7, +! NFA_ZOPEN8, +! NFA_ZOPEN9, +! +! NFA_ZCLOSE, +! NFA_ZCLOSE1, +! NFA_ZCLOSE2, +! NFA_ZCLOSE3, +! NFA_ZCLOSE4, +! NFA_ZCLOSE5, +! NFA_ZCLOSE6, +! NFA_ZCLOSE7, +! NFA_ZCLOSE8, +! NFA_ZCLOSE9, +! #endif + + /* NFA_FIRST_NL */ +! NFA_ANY, /* Match any one character. */ + NFA_ANYOF, /* Match any character in this string. */ + NFA_ANYBUT, /* Match any character not in this string. */ + NFA_IDENT, /* Match identifier char */ +*************** +*** 221,227 **** + static void nfa_save_listids __ARGS((nfa_state_T *start, int *list)); + static void nfa_restore_listids __ARGS((nfa_state_T *start, int *list)); + static int nfa_re_num_cmp __ARGS((long_u val, int op, long_u pos)); +! static long nfa_regtry __ARGS((nfa_state_T *start, colnr_T col)); + static long nfa_regexec_both __ARGS((char_u *line, colnr_T col)); + static regprog_T *nfa_regcomp __ARGS((char_u *expr, int re_flags)); + static int nfa_regexec __ARGS((regmatch_T *rmp, char_u *line, colnr_T col)); +--- 275,281 ---- + static void nfa_save_listids __ARGS((nfa_state_T *start, int *list)); + static void nfa_restore_listids __ARGS((nfa_state_T *start, int *list)); + static int nfa_re_num_cmp __ARGS((long_u val, int op, long_u pos)); +! static long nfa_regtry __ARGS((nfa_regprog_T *prog, colnr_T col)); + static long nfa_regexec_both __ARGS((char_u *line, colnr_T col)); + static regprog_T *nfa_regcomp __ARGS((char_u *expr, int re_flags)); + static int nfa_regexec __ARGS((regmatch_T *rmp, char_u *line, colnr_T col)); +*************** +*** 267,272 **** +--- 321,327 ---- + nfa_has_zend = FALSE; + nfa_has_backref = FALSE; + ++ /* shared with BT engine */ + regcomp_start(expr, re_flags); + + return OK; +*************** +*** 799,804 **** +--- 854,860 ---- + EMIT(NFA_ZEND); + nfa_has_zend = TRUE; + break; ++ #ifdef FEAT_SYN_HL + case '1': + case '2': + case '3': +*************** +*** 808,816 **** + case '7': + case '8': + case '9': + case '(': +! /* TODO: \z1...\z9 and \z( not yet supported */ +! return FAIL; + default: + syntax_error = TRUE; + EMSGN(_("E867: (NFA) Unknown operator '\\z%c'"), +--- 864,882 ---- + case '7': + case '8': + case '9': ++ /* \z1...\z9 */ ++ EMIT(NFA_ZREF1 + (no_Magic(c) - '1')); ++ /* No need to set nfa_has_backref, the sub-matches don't ++ * change when \z1 .. \z9 maches or not. */ ++ re_has_z = REX_USE; ++ break; + case '(': +! /* \z( */ +! if (nfa_reg(REG_ZPAREN) == FAIL) +! return FAIL; /* cascaded error */ +! re_has_z = REX_SET; +! break; +! #endif + default: + syntax_error = TRUE; + EMSGN(_("E867: (NFA) Unknown operator '\\z%c'"), +*************** +*** 1651,1658 **** + { + int parno = 0; + +- #ifdef FEAT_SYN_HL +- #endif + if (paren == REG_PAREN) + { + if (regnpar >= NSUBEXP) /* Too many `(' */ +--- 1717,1722 ---- +*************** +*** 1662,1667 **** +--- 1726,1743 ---- + } + parno = regnpar++; + } ++ #ifdef FEAT_SYN_HL ++ else if (paren == REG_ZPAREN) ++ { ++ /* Make a ZOPEN node. */ ++ if (regnzpar >= NSUBEXP) ++ { ++ syntax_error = TRUE; ++ EMSG_RET_FAIL(_("E879: (NFA regexp) Too many \\z(")); ++ } ++ parno = regnzpar++; ++ } ++ #endif + + if (nfa_regbranch() == FAIL) + return FAIL; /* cascaded error */ +*************** +*** 1700,1705 **** +--- 1776,1785 ---- + had_endbrace[parno] = TRUE; /* have seen the close paren */ + EMIT(NFA_MOPEN + parno); + } ++ #ifdef FEAT_SYN_HL ++ else if (paren == REG_ZPAREN) ++ EMIT(NFA_ZOPEN + parno); ++ #endif + + return OK; + } +*************** +*** 1738,1743 **** +--- 1818,1834 ---- + case NFA_BACKREF7: STRCPY(code, "NFA_BACKREF7"); break; + case NFA_BACKREF8: STRCPY(code, "NFA_BACKREF8"); break; + case NFA_BACKREF9: STRCPY(code, "NFA_BACKREF9"); break; ++ #ifdef FEAT_SYN_HL ++ case NFA_ZREF1: STRCPY(code, "NFA_ZREF1"); break; ++ case NFA_ZREF2: STRCPY(code, "NFA_ZREF2"); break; ++ case NFA_ZREF3: STRCPY(code, "NFA_ZREF3"); break; ++ case NFA_ZREF4: STRCPY(code, "NFA_ZREF4"); break; ++ case NFA_ZREF5: STRCPY(code, "NFA_ZREF5"); break; ++ case NFA_ZREF6: STRCPY(code, "NFA_ZREF6"); break; ++ case NFA_ZREF7: STRCPY(code, "NFA_ZREF7"); break; ++ case NFA_ZREF8: STRCPY(code, "NFA_ZREF8"); break; ++ case NFA_ZREF9: STRCPY(code, "NFA_ZREF9"); break; ++ #endif + case NFA_SKIP: STRCPY(code, "NFA_SKIP"); break; + + case NFA_PREV_ATOM_NO_WIDTH: +*************** +*** 1758,1789 **** + case NFA_COMPOSING: STRCPY(code, "NFA_COMPOSING"); break; + case NFA_END_COMPOSING: STRCPY(code, "NFA_END_COMPOSING"); break; + +! case NFA_MOPEN + 0: +! case NFA_MOPEN + 1: +! case NFA_MOPEN + 2: +! case NFA_MOPEN + 3: +! case NFA_MOPEN + 4: +! case NFA_MOPEN + 5: +! case NFA_MOPEN + 6: +! case NFA_MOPEN + 7: +! case NFA_MOPEN + 8: +! case NFA_MOPEN + 9: + STRCPY(code, "NFA_MOPEN(x)"); + code[10] = c - NFA_MOPEN + '0'; + break; +! case NFA_MCLOSE + 0: +! case NFA_MCLOSE + 1: +! case NFA_MCLOSE + 2: +! case NFA_MCLOSE + 3: +! case NFA_MCLOSE + 4: +! case NFA_MCLOSE + 5: +! case NFA_MCLOSE + 6: +! case NFA_MCLOSE + 7: +! case NFA_MCLOSE + 8: +! case NFA_MCLOSE + 9: + STRCPY(code, "NFA_MCLOSE(x)"); + code[11] = c - NFA_MCLOSE + '0'; + break; + case NFA_EOL: STRCPY(code, "NFA_EOL "); break; + case NFA_BOL: STRCPY(code, "NFA_BOL "); break; + case NFA_EOW: STRCPY(code, "NFA_EOW "); break; +--- 1849,1908 ---- + case NFA_COMPOSING: STRCPY(code, "NFA_COMPOSING"); break; + case NFA_END_COMPOSING: STRCPY(code, "NFA_END_COMPOSING"); break; + +! case NFA_MOPEN: +! case NFA_MOPEN1: +! case NFA_MOPEN2: +! case NFA_MOPEN3: +! case NFA_MOPEN4: +! case NFA_MOPEN5: +! case NFA_MOPEN6: +! case NFA_MOPEN7: +! case NFA_MOPEN8: +! case NFA_MOPEN9: + STRCPY(code, "NFA_MOPEN(x)"); + code[10] = c - NFA_MOPEN + '0'; + break; +! case NFA_MCLOSE: +! case NFA_MCLOSE1: +! case NFA_MCLOSE2: +! case NFA_MCLOSE3: +! case NFA_MCLOSE4: +! case NFA_MCLOSE5: +! case NFA_MCLOSE6: +! case NFA_MCLOSE7: +! case NFA_MCLOSE8: +! case NFA_MCLOSE9: + STRCPY(code, "NFA_MCLOSE(x)"); + code[11] = c - NFA_MCLOSE + '0'; + break; ++ #ifdef FEAT_SYN_HL ++ case NFA_ZOPEN: ++ case NFA_ZOPEN1: ++ case NFA_ZOPEN2: ++ case NFA_ZOPEN3: ++ case NFA_ZOPEN4: ++ case NFA_ZOPEN5: ++ case NFA_ZOPEN6: ++ case NFA_ZOPEN7: ++ case NFA_ZOPEN8: ++ case NFA_ZOPEN9: ++ STRCPY(code, "NFA_ZOPEN(x)"); ++ code[10] = c - NFA_ZOPEN + '0'; ++ break; ++ case NFA_ZCLOSE: ++ case NFA_ZCLOSE1: ++ case NFA_ZCLOSE2: ++ case NFA_ZCLOSE3: ++ case NFA_ZCLOSE4: ++ case NFA_ZCLOSE5: ++ case NFA_ZCLOSE6: ++ case NFA_ZCLOSE7: ++ case NFA_ZCLOSE8: ++ case NFA_ZCLOSE9: ++ STRCPY(code, "NFA_ZCLOSE(x)"); ++ code[11] = c - NFA_ZCLOSE + '0'; ++ break; ++ #endif + case NFA_EOL: STRCPY(code, "NFA_EOL "); break; + case NFA_BOL: STRCPY(code, "NFA_BOL "); break; + case NFA_EOW: STRCPY(code, "NFA_EOW "); break; +*************** +*** 2437,2453 **** + /* FALLTHROUGH */ + #endif + +! case NFA_MOPEN + 0: /* Submatch */ +! case NFA_MOPEN + 1: +! case NFA_MOPEN + 2: +! case NFA_MOPEN + 3: +! case NFA_MOPEN + 4: +! case NFA_MOPEN + 5: +! case NFA_MOPEN + 6: +! case NFA_MOPEN + 7: +! case NFA_MOPEN + 8: +! case NFA_MOPEN + 9: +! case NFA_NOPEN: /* \%( "Invisible Submatch" */ + if (nfa_calc_size == TRUE) + { + nstate += 2; +--- 2556,2584 ---- + /* FALLTHROUGH */ + #endif + +! case NFA_MOPEN: /* \( \) Submatch */ +! case NFA_MOPEN1: +! case NFA_MOPEN2: +! case NFA_MOPEN3: +! case NFA_MOPEN4: +! case NFA_MOPEN5: +! case NFA_MOPEN6: +! case NFA_MOPEN7: +! case NFA_MOPEN8: +! case NFA_MOPEN9: +! #ifdef FEAT_SYN_HL +! case NFA_ZOPEN: /* \z( \) Submatch */ +! case NFA_ZOPEN1: +! case NFA_ZOPEN2: +! case NFA_ZOPEN3: +! case NFA_ZOPEN4: +! case NFA_ZOPEN5: +! case NFA_ZOPEN6: +! case NFA_ZOPEN7: +! case NFA_ZOPEN8: +! case NFA_ZOPEN9: +! #endif +! case NFA_NOPEN: /* \%( \) "Invisible Submatch" */ + if (nfa_calc_size == TRUE) + { + nstate += 2; +*************** +*** 2457,2472 **** + mopen = *p; + switch (*p) + { +! case NFA_NOPEN: +! mclose = NFA_NCLOSE; +! break; + #ifdef FEAT_MBYTE +! case NFA_COMPOSING: +! mclose = NFA_END_COMPOSING; +! break; + #endif + default: +! /* NFA_MOPEN(0) ... NFA_MOPEN(9) */ + mclose = *p + NSUBEXP; + break; + } +--- 2588,2611 ---- + mopen = *p; + switch (*p) + { +! case NFA_NOPEN: mclose = NFA_NCLOSE; break; +! #ifdef FEAT_SYN_HL +! case NFA_ZOPEN: mclose = NFA_ZCLOSE; break; +! case NFA_ZOPEN1: mclose = NFA_ZCLOSE1; break; +! case NFA_ZOPEN2: mclose = NFA_ZCLOSE2; break; +! case NFA_ZOPEN3: mclose = NFA_ZCLOSE3; break; +! case NFA_ZOPEN4: mclose = NFA_ZCLOSE4; break; +! case NFA_ZOPEN5: mclose = NFA_ZCLOSE5; break; +! case NFA_ZOPEN6: mclose = NFA_ZCLOSE6; break; +! case NFA_ZOPEN7: mclose = NFA_ZCLOSE7; break; +! case NFA_ZOPEN8: mclose = NFA_ZCLOSE8; break; +! case NFA_ZOPEN9: mclose = NFA_ZCLOSE9; break; +! #endif + #ifdef FEAT_MBYTE +! case NFA_COMPOSING: mclose = NFA_END_COMPOSING; break; + #endif + default: +! /* NFA_MOPEN, NFA_MOPEN1 .. NFA_MOPEN9 */ + mclose = *p + NSUBEXP; + break; + } +*************** +*** 2518,2523 **** +--- 2657,2673 ---- + case NFA_BACKREF7: + case NFA_BACKREF8: + case NFA_BACKREF9: ++ #ifdef FEAT_SYN_HL ++ case NFA_ZREF1: ++ case NFA_ZREF2: ++ case NFA_ZREF3: ++ case NFA_ZREF4: ++ case NFA_ZREF5: ++ case NFA_ZREF6: ++ case NFA_ZREF7: ++ case NFA_ZREF8: ++ case NFA_ZREF9: ++ #endif + if (nfa_calc_size == TRUE) + { + nstate += 2; +*************** +*** 2630,2641 **** + } list; + } regsub_T; + + /* nfa_thread_T contains execution information of a NFA state */ + typedef struct + { + nfa_state_T *state; + int count; +! regsub_T sub; /* submatch info, only party used */ + } nfa_thread_T; + + /* nfa_list_T contains the alternative NFA execution states. */ +--- 2780,2799 ---- + } list; + } regsub_T; + ++ typedef struct ++ { ++ regsub_T norm; /* \( .. \) matches */ ++ #ifdef FEAT_SYN_HL ++ regsub_T synt; /* \z( .. \) matches */ ++ #endif ++ } regsubs_T; ++ + /* nfa_thread_T contains execution information of a NFA state */ + typedef struct + { + nfa_state_T *state; + int count; +! regsubs_T subs; /* submatch info, only party used */ + } nfa_thread_T; + + /* nfa_list_T contains the alternative NFA execution states. */ +*************** +*** 2648,2653 **** +--- 2806,2824 ---- + } nfa_list_T; + + #ifdef ENABLE_LOG ++ static void log_subsexpr __ARGS((regsubs_T *subs)); ++ static void log_subexpr __ARGS((regsub_T *sub)); ++ ++ static void ++ log_subsexpr(subs) ++ regsubs_T *subs; ++ { ++ log_subexpr(&subs->norm); ++ # ifdef FEAT_SYN_HL ++ log_subexpr(&subs->synt); ++ # endif ++ } ++ + static void + log_subexpr(sub) + regsub_T *sub; +*************** +*** 2674,2682 **** + /* Used during execution: whether a match has been found. */ + static int nfa_match; + + static int sub_equal __ARGS((regsub_T *sub1, regsub_T *sub2)); +! static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *sub, int off)); +! static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsub_T *sub, int *ip)); + + /* + * Return TRUE if "sub1" and "sub2" have the same positions. +--- 2845,2916 ---- + /* Used during execution: whether a match has been found. */ + static int nfa_match; + ++ static void clear_sub __ARGS((regsub_T *sub)); ++ static void copy_sub __ARGS((regsub_T *to, regsub_T *from)); ++ static void copy_sub_off __ARGS((regsub_T *to, regsub_T *from)); + static int sub_equal __ARGS((regsub_T *sub1, regsub_T *sub2)); +! static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, int off)); +! static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, int *ip)); +! +! static void +! clear_sub(sub) +! regsub_T *sub; +! { +! if (REG_MULTI) +! /* Use 0xff to set lnum to -1 */ +! vim_memset(sub->list.multi, 0xff, +! sizeof(struct multipos) * nfa_nsubexpr); +! else +! vim_memset(sub->list.line, 0, sizeof(struct linepos) * nfa_nsubexpr); +! sub->in_use = 0; +! } +! +! /* +! * Copy the submatches from "from" to "to". +! */ +! static void +! copy_sub(to, from) +! regsub_T *to; +! regsub_T *from; +! { +! to->in_use = from->in_use; +! if (from->in_use > 0) +! { +! /* Copy the match start and end positions. */ +! if (REG_MULTI) +! mch_memmove(&to->list.multi[0], +! &from->list.multi[0], +! sizeof(struct multipos) * from->in_use); +! else +! mch_memmove(&to->list.line[0], +! &from->list.line[0], +! sizeof(struct linepos) * from->in_use); +! } +! } +! +! /* +! * Like copy_sub() but exclude the main match. +! */ +! static void +! copy_sub_off(to, from) +! regsub_T *to; +! regsub_T *from; +! { +! if (to->in_use < from->in_use) +! to->in_use = from->in_use; +! if (from->in_use > 1) +! { +! /* Copy the match start and end positions. */ +! if (REG_MULTI) +! mch_memmove(&to->list.multi[1], +! &from->list.multi[1], +! sizeof(struct multipos) * (from->in_use - 1)); +! else +! mch_memmove(&to->list.line[1], +! &from->list.line[1], +! sizeof(struct linepos) * (from->in_use - 1)); +! } +! } + + /* + * Return TRUE if "sub1" and "sub2" have the same positions. +*************** +*** 2761,2770 **** + } + + static void +! addstate(l, state, sub, off) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ +! regsub_T *sub; /* pointers to subexpressions */ + int off; /* byte offset, when -1 go to next line */ + { + int subidx; +--- 2995,3004 ---- + } + + static void +! addstate(l, state, subs, off) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ +! regsubs_T *subs; /* pointers to subexpressions */ + int off; /* byte offset, when -1 go to next line */ + { + int subidx; +*************** +*** 2773,2778 **** +--- 3007,3013 ---- + int save_in_use; + char_u *save_ptr; + int i; ++ regsub_T *sub; + #ifdef ENABLE_LOG + int did_print = FALSE; + #endif +*************** +*** 2787,2815 **** + case NFA_NOPEN: + case NFA_NCLOSE: + case NFA_MCLOSE: +! case NFA_MCLOSE + 1: +! case NFA_MCLOSE + 2: +! case NFA_MCLOSE + 3: +! case NFA_MCLOSE + 4: +! case NFA_MCLOSE + 5: +! case NFA_MCLOSE + 6: +! case NFA_MCLOSE + 7: +! case NFA_MCLOSE + 8: +! case NFA_MCLOSE + 9: + /* These nodes are not added themselves but their "out" and/or + * "out1" may be added below. */ + break; + + case NFA_MOPEN: +! case NFA_MOPEN + 1: +! case NFA_MOPEN + 2: +! case NFA_MOPEN + 3: +! case NFA_MOPEN + 4: +! case NFA_MOPEN + 5: +! case NFA_MOPEN + 6: +! case NFA_MOPEN + 7: +! case NFA_MOPEN + 8: +! case NFA_MOPEN + 9: + /* These nodes do not need to be added, but we need to bail out + * when it was tried to be added to this list before. */ + if (state->lastlist == l->id) +--- 3022,3074 ---- + case NFA_NOPEN: + case NFA_NCLOSE: + case NFA_MCLOSE: +! case NFA_MCLOSE1: +! case NFA_MCLOSE2: +! case NFA_MCLOSE3: +! case NFA_MCLOSE4: +! case NFA_MCLOSE5: +! case NFA_MCLOSE6: +! case NFA_MCLOSE7: +! case NFA_MCLOSE8: +! case NFA_MCLOSE9: +! #ifdef FEAT_SYN_HL +! case NFA_ZCLOSE: +! case NFA_ZCLOSE1: +! case NFA_ZCLOSE2: +! case NFA_ZCLOSE3: +! case NFA_ZCLOSE4: +! case NFA_ZCLOSE5: +! case NFA_ZCLOSE6: +! case NFA_ZCLOSE7: +! case NFA_ZCLOSE8: +! case NFA_ZCLOSE9: +! #endif + /* These nodes are not added themselves but their "out" and/or + * "out1" may be added below. */ + break; + + case NFA_MOPEN: +! case NFA_MOPEN1: +! case NFA_MOPEN2: +! case NFA_MOPEN3: +! case NFA_MOPEN4: +! case NFA_MOPEN5: +! case NFA_MOPEN6: +! case NFA_MOPEN7: +! case NFA_MOPEN8: +! case NFA_MOPEN9: +! #ifdef FEAT_SYN_HL +! case NFA_ZOPEN: +! case NFA_ZOPEN1: +! case NFA_ZOPEN2: +! case NFA_ZOPEN3: +! case NFA_ZOPEN4: +! case NFA_ZOPEN5: +! case NFA_ZOPEN6: +! case NFA_ZOPEN7: +! case NFA_ZOPEN8: +! case NFA_ZOPEN9: +! #endif + /* These nodes do not need to be added, but we need to bail out + * when it was tried to be added to this list before. */ + if (state->lastlist == l->id) +*************** +*** 2839,2845 **** + { + thread = &l->t[i]; + if (thread->state->id == state->id +! && sub_equal(&thread->sub, sub)) + goto skip_add; + } + } +--- 3098,3108 ---- + { + thread = &l->t[i]; + if (thread->state->id == state->id +! && sub_equal(&thread->subs.norm, &subs->norm) +! #ifdef FEAT_SYN_HL +! && sub_equal(&thread->subs.synt, &subs->synt) +! #endif +! ) + goto skip_add; + } + } +*************** +*** 2858,2876 **** + state->lastlist = l->id; + thread = &l->t[l->n++]; + thread->state = state; +! thread->sub.in_use = sub->in_use; +! if (sub->in_use > 0) +! { +! /* Copy the match start and end positions. */ +! if (REG_MULTI) +! mch_memmove(&thread->sub.list.multi[0], +! &sub->list.multi[0], +! sizeof(struct multipos) * sub->in_use); +! else +! mch_memmove(&thread->sub.list.line[0], +! &sub->list.line[0], +! sizeof(struct linepos) * sub->in_use); +! } + #ifdef ENABLE_LOG + { + int col; +--- 3121,3130 ---- + state->lastlist = l->id; + thread = &l->t[l->n++]; + thread->state = state; +! copy_sub(&thread->subs.norm, &subs->norm); +! #ifdef FEAT_SYN_HL +! copy_sub(&thread->subs.synt, &subs->synt); +! #endif + #ifdef ENABLE_LOG + { + int col; +*************** +*** 2912,2959 **** + break; + + case NFA_SPLIT: +! addstate(l, state->out, sub, off); +! addstate(l, state->out1, sub, off); + break; + +- #if 0 +- case NFA_END_NEG_RANGE: +- /* Nothing to handle here. nfa_regmatch() will take care of it */ +- break; +- +- case NFA_NOT: +- EMSG(_("E999: (NFA regexp internal error) Should not process NOT node !")); +- #ifdef ENABLE_LOG +- fprintf(f, "\n\n>>> E999: Added state NFA_NOT to a list ... Something went wrong ! Why wasn't it processed already? \n\n"); +- #endif +- break; +- +- case NFA_COMPOSING: +- /* nfa_regmatch() will match all the bytes of this composing char. */ +- break; +- #endif +- + case NFA_SKIP_CHAR: + case NFA_NOPEN: + case NFA_NCLOSE: +! addstate(l, state->out, sub, off); + break; + +! case NFA_MOPEN + 0: +! case NFA_MOPEN + 1: +! case NFA_MOPEN + 2: +! case NFA_MOPEN + 3: +! case NFA_MOPEN + 4: +! case NFA_MOPEN + 5: +! case NFA_MOPEN + 6: +! case NFA_MOPEN + 7: +! case NFA_MOPEN + 8: +! case NFA_MOPEN + 9: + case NFA_ZSTART: + if (state->c == NFA_ZSTART) + subidx = 0; + else + subidx = state->c - NFA_MOPEN; + + /* Set the position (with "off") in the subexpression. Save and + * restore it when it was in use. Otherwise fill any gap. */ +--- 3166,3222 ---- + break; + + case NFA_SPLIT: +! /* order matters here */ +! addstate(l, state->out, subs, off); +! addstate(l, state->out1, subs, off); + break; + + case NFA_SKIP_CHAR: + case NFA_NOPEN: + case NFA_NCLOSE: +! addstate(l, state->out, subs, off); + break; + +! case NFA_MOPEN: +! case NFA_MOPEN1: +! case NFA_MOPEN2: +! case NFA_MOPEN3: +! case NFA_MOPEN4: +! case NFA_MOPEN5: +! case NFA_MOPEN6: +! case NFA_MOPEN7: +! case NFA_MOPEN8: +! case NFA_MOPEN9: +! #ifdef FEAT_SYN_HL +! case NFA_ZOPEN: +! case NFA_ZOPEN1: +! case NFA_ZOPEN2: +! case NFA_ZOPEN3: +! case NFA_ZOPEN4: +! case NFA_ZOPEN5: +! case NFA_ZOPEN6: +! case NFA_ZOPEN7: +! case NFA_ZOPEN8: +! case NFA_ZOPEN9: +! #endif + case NFA_ZSTART: + if (state->c == NFA_ZSTART) ++ { + subidx = 0; ++ sub = &subs->norm; ++ } ++ #ifdef FEAT_SYN_HL ++ else if (state->c >= NFA_ZOPEN) ++ { ++ subidx = state->c - NFA_ZOPEN; ++ sub = &subs->synt; ++ } ++ #endif + else ++ { + subidx = state->c - NFA_MOPEN; ++ sub = &subs->norm; ++ } + + /* Set the position (with "off") in the subexpression. Save and + * restore it when it was in use. Otherwise fill any gap. */ +*************** +*** 3007,3013 **** + sub->list.line[subidx].start = reginput + off; + } + +! addstate(l, state->out, sub, off); + + if (save_in_use == -1) + { +--- 3270,3276 ---- + sub->list.line[subidx].start = reginput + off; + } + +! addstate(l, state->out, subs, off); + + if (save_in_use == -1) + { +*************** +*** 3020,3047 **** + sub->in_use = save_in_use; + break; + +! case NFA_MCLOSE + 0: + if (nfa_has_zend) + { + /* Do not overwrite the position set by \ze. If no \ze + * encountered end will be set in nfa_regtry(). */ +! addstate(l, state->out, sub, off); + break; + } +! case NFA_MCLOSE + 1: +! case NFA_MCLOSE + 2: +! case NFA_MCLOSE + 3: +! case NFA_MCLOSE + 4: +! case NFA_MCLOSE + 5: +! case NFA_MCLOSE + 6: +! case NFA_MCLOSE + 7: +! case NFA_MCLOSE + 8: +! case NFA_MCLOSE + 9: + case NFA_ZEND: + if (state->c == NFA_ZEND) + subidx = 0; + else + subidx = state->c - NFA_MCLOSE; + + /* We don't fill in gaps here, there must have been an MOPEN that + * has done that. */ +--- 3283,3335 ---- + sub->in_use = save_in_use; + break; + +! case NFA_MCLOSE: + if (nfa_has_zend) + { + /* Do not overwrite the position set by \ze. If no \ze + * encountered end will be set in nfa_regtry(). */ +! addstate(l, state->out, subs, off); + break; + } +! case NFA_MCLOSE1: +! case NFA_MCLOSE2: +! case NFA_MCLOSE3: +! case NFA_MCLOSE4: +! case NFA_MCLOSE5: +! case NFA_MCLOSE6: +! case NFA_MCLOSE7: +! case NFA_MCLOSE8: +! case NFA_MCLOSE9: +! #ifdef FEAT_SYN_HL +! case NFA_ZCLOSE: +! case NFA_ZCLOSE1: +! case NFA_ZCLOSE2: +! case NFA_ZCLOSE3: +! case NFA_ZCLOSE4: +! case NFA_ZCLOSE5: +! case NFA_ZCLOSE6: +! case NFA_ZCLOSE7: +! case NFA_ZCLOSE8: +! case NFA_ZCLOSE9: +! #endif + case NFA_ZEND: + if (state->c == NFA_ZEND) ++ { + subidx = 0; ++ sub = &subs->norm; ++ } ++ #ifdef FEAT_SYN_HL ++ else if (state->c >= NFA_ZCLOSE) ++ { ++ subidx = state->c - NFA_ZCLOSE; ++ sub = &subs->synt; ++ } ++ #endif + else ++ { + subidx = state->c - NFA_MCLOSE; ++ sub = &subs->norm; ++ } + + /* We don't fill in gaps here, there must have been an MOPEN that + * has done that. */ +*************** +*** 3069,3075 **** + sub->list.line[subidx].end = reginput + off; + } + +! addstate(l, state->out, sub, off); + + if (REG_MULTI) + sub->list.multi[subidx].end = save_lpos; +--- 3357,3363 ---- + sub->list.line[subidx].end = reginput + off; + } + +! addstate(l, state->out, subs, off); + + if (REG_MULTI) + sub->list.multi[subidx].end = save_lpos; +*************** +*** 3087,3096 **** + * matters for alternatives. + */ + static void +! addstate_here(l, state, sub, ip) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ +! regsub_T *sub; /* pointers to subexpressions */ + int *ip; + { + int tlen = l->n; +--- 3375,3384 ---- + * matters for alternatives. + */ + static void +! addstate_here(l, state, subs, ip) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ +! regsubs_T *subs; /* pointers to subexpressions */ + int *ip; + { + int tlen = l->n; +*************** +*** 3098,3104 **** + int i = *ip; + + /* first add the state(s) at the end, so that we know how many there are */ +! addstate(l, state, sub, 0); + + /* when "*ip" was at the end of the list, nothing to do */ + if (i + 1 == tlen) +--- 3386,3392 ---- + int i = *ip; + + /* first add the state(s) at the end, so that we know how many there are */ +! addstate(l, state, subs, 0); + + /* when "*ip" was at the end of the list, nothing to do */ + if (i + 1 == tlen) +*************** +*** 3212,3218 **** + + /* + * Check for a match with subexpression "subidx". +! * return TRUE if it matches. + */ + static int + match_backref(sub, subidx, bytelen) +--- 3500,3506 ---- + + /* + * Check for a match with subexpression "subidx". +! * Return TRUE if it matches. + */ + static int + match_backref(sub, subidx, bytelen) +*************** +*** 3260,3265 **** +--- 3548,3586 ---- + return FALSE; + } + ++ #ifdef FEAT_SYN_HL ++ ++ static int match_zref __ARGS((int subidx, int *bytelen)); ++ ++ /* ++ * Check for a match with \z subexpression "subidx". ++ * Return TRUE if it matches. ++ */ ++ static int ++ match_zref(subidx, bytelen) ++ int subidx; ++ int *bytelen; /* out: length of match in bytes */ ++ { ++ int len; ++ ++ cleanup_zsubexpr(); ++ if (re_extmatch_in == NULL || re_extmatch_in->matches[subidx] == NULL) ++ { ++ /* backref was not set, match an empty string */ ++ *bytelen = 0; ++ return TRUE; ++ } ++ ++ len = (int)STRLEN(re_extmatch_in->matches[subidx]); ++ if (cstrncmp(re_extmatch_in->matches[subidx], reginput, &len) == 0) ++ { ++ *bytelen = len; ++ return TRUE; ++ } ++ return FALSE; ++ } ++ #endif ++ + /* + * Set all NFA nodes' list ID equal to -1. + */ +*************** +*** 3334,3340 **** + return val == pos; + } + +! static int nfa_regmatch __ARGS((nfa_state_T *start, regsub_T *submatch, regsub_T *m, save_se_T *endp)); + + /* + * Main matching routine. +--- 3655,3661 ---- + return val == pos; + } + +! static int nfa_regmatch __ARGS((nfa_state_T *start, regsubs_T *submatch, regsubs_T *m, save_se_T *endp)); + + /* + * Main matching routine. +*************** +*** 3349,3356 **** + static int + nfa_regmatch(start, submatch, m, endp) + nfa_state_T *start; +! regsub_T *submatch; +! regsub_T *m; + save_se_T *endp; + { + int result; +--- 3670,3677 ---- + static int + nfa_regmatch(start, submatch, m, endp) + nfa_state_T *start; +! regsubs_T *submatch; +! regsubs_T *m; + save_se_T *endp; + { + int result; +*************** +*** 3429,3435 **** + #define ADD_POS_NEG_STATE(node) \ + ll = listtbl[result ? 1 : 0][node->negated]; \ + if (ll != NULL) \ +! addstate(ll, node->out , &t->sub, clen); + + + /* +--- 3750,3756 ---- + #define ADD_POS_NEG_STATE(node) \ + ll = listtbl[result ? 1 : 0][node->negated]; \ + if (ll != NULL) \ +! addstate(ll, node->out , &t->subs, clen); + + + /* +*************** +*** 3531,3556 **** + { + case NFA_MATCH: + { +- int j; +- + nfa_match = TRUE; +! submatch->in_use = t->sub.in_use; +! if (REG_MULTI) +! for (j = 0; j < submatch->in_use; j++) +! { +! submatch->list.multi[j].start = +! t->sub.list.multi[j].start; +! submatch->list.multi[j].end = t->sub.list.multi[j].end; +! } +! else +! for (j = 0; j < submatch->in_use; j++) +! { +! submatch->list.line[j].start = +! t->sub.list.line[j].start; +! submatch->list.line[j].end = t->sub.list.line[j].end; +! } + #ifdef ENABLE_LOG +! log_subexpr(&t->sub); + #endif + /* Found the left-most longest match, do not look at any other + * states at this position. When the list of states is going +--- 3852,3864 ---- + { + case NFA_MATCH: + { + nfa_match = TRUE; +! copy_sub(&submatch->norm, &t->subs.norm); +! #ifdef FEAT_SYN_HL +! copy_sub(&submatch->synt, &t->subs.synt); +! #endif + #ifdef ENABLE_LOG +! log_subsexpr(&t->subs); + #endif + /* Found the left-most longest match, do not look at any other + * states at this position. When the list of states is going +*************** +*** 3570,3578 **** + * finished successfully, so return control to the parent + * nfa_regmatch(). Submatches are stored in *m, and used in + * the parent call. */ +! if (start->c == NFA_MOPEN + 0) + /* TODO: do we ever get here? */ +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + else + { + #ifdef ENABLE_LOG +--- 3878,3886 ---- + * finished successfully, so return control to the parent + * nfa_regmatch(). Submatches are stored in *m, and used in + * the parent call. */ +! if (start->c == NFA_MOPEN) + /* TODO: do we ever get here? */ +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + else + { + #ifdef ENABLE_LOG +*************** +*** 3600,3607 **** + + /* do not set submatches for \@! */ + if (!t->state->negated) +! /* TODO: only copy positions in use. */ +! *m = t->sub; + nfa_match = TRUE; + } + break; +--- 3908,3919 ---- + + /* do not set submatches for \@! */ + if (!t->state->negated) +! { +! copy_sub(&m->norm, &t->subs.norm); +! #ifdef FEAT_SYN_HL +! copy_sub(&m->synt, &t->subs.synt); +! #endif +! } + nfa_match = TRUE; + } + break; +*************** +*** 3630,3636 **** + + /* Go back the specified number of bytes, or as far as the + * start of the previous line, to try matching "\@<=" or +! * not matching "\@state->val <= 0) + { + if (REG_MULTI) +--- 3942,3950 ---- + + /* Go back the specified number of bytes, or as far as the + * start of the previous line, to try matching "\@<=" or +! * not matching "\@state->val <= 0) + { + if (REG_MULTI) +*************** +*** 3722,3748 **** + /* for \@! it is a match when result is FALSE */ + if (result != t->state->negated) + { +- int j; +- + /* Copy submatch info from the recursive call */ +! if (REG_MULTI) +! for (j = 1; j < m->in_use; j++) +! { +! t->sub.list.multi[j].start = m->list.multi[j].start; +! t->sub.list.multi[j].end = m->list.multi[j].end; +! } +! else +! for (j = 1; j < m->in_use; j++) +! { +! t->sub.list.line[j].start = m->list.line[j].start; +! t->sub.list.line[j].end = m->list.line[j].end; +! } +! if (m->in_use > t->sub.in_use) +! t->sub.in_use = m->in_use; + + /* t->state->out1 is the corresponding END_INVISIBLE node; + * Add it to the current list (zero-width match). */ +! addstate_here(thislist, t->state->out1->out, &t->sub, + &listidx); + } + break; +--- 4036,4050 ---- + /* for \@! it is a match when result is FALSE */ + if (result != t->state->negated) + { + /* Copy submatch info from the recursive call */ +! copy_sub_off(&t->subs.norm, &m->norm); +! #ifdef FEAT_SYN_HL +! copy_sub_off(&t->subs.synt, &m->synt); +! #endif + + /* t->state->out1 is the corresponding END_INVISIBLE node; + * Add it to the current list (zero-width match). */ +! addstate_here(thislist, t->state->out1->out, &t->subs, + &listidx); + } + break; +*************** +*** 3750,3761 **** + + case NFA_BOL: + if (reginput == regline) +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + break; + + case NFA_EOL: + if (curc == NUL) +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + break; + + case NFA_BOW: +--- 4052,4063 ---- + + case NFA_BOL: + if (reginput == regline) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + case NFA_EOL: + if (curc == NUL) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + case NFA_BOW: +*************** +*** 3782,3788 **** + && vim_iswordc_buf(reginput[-1], reg_buf))) + bow = FALSE; + if (bow) +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + break; + } + +--- 4084,4090 ---- + && vim_iswordc_buf(reginput[-1], reg_buf))) + bow = FALSE; + if (bow) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + } + +*************** +*** 3810,3828 **** + && vim_iswordc_buf(curc, reg_buf))) + eow = FALSE; + if (eow) +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + break; + } + + case NFA_BOF: + if (reglnum == 0 && reginput == regline + && (!REG_MULTI || reg_firstlnum == 1)) +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + break; + + case NFA_EOF: + if (reglnum == reg_maxline && curc == NUL) +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + break; + + #ifdef FEAT_MBYTE +--- 4112,4130 ---- + && vim_iswordc_buf(curc, reg_buf))) + eow = FALSE; + if (eow) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + } + + case NFA_BOF: + if (reglnum == 0 && reginput == regline + && (!REG_MULTI || reg_firstlnum == 1)) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + case NFA_EOF: + if (reglnum == reg_maxline && curc == NUL) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + #ifdef FEAT_MBYTE +*************** +*** 3911,3922 **** + go_to_nextline = TRUE; + /* Pass -1 for the offset, which means taking the position + * at the start of the next line. */ +! addstate(nextlist, t->state->out, &t->sub, -1); + } + else if (curc == '\n' && reg_line_lbr) + { + /* match \n as if it is an ordinary character */ +! addstate(nextlist, t->state->out, &t->sub, 1); + } + break; + +--- 4213,4224 ---- + go_to_nextline = TRUE; + /* Pass -1 for the offset, which means taking the position + * at the start of the next line. */ +! addstate(nextlist, t->state->out, &t->subs, -1); + } + else if (curc == '\n' && reg_line_lbr) + { + /* match \n as if it is an ordinary character */ +! addstate(nextlist, t->state->out, &t->subs, 1); + } + break; + +*************** +*** 3944,3956 **** + /* This follows a series of negated nodes, like: + * CHAR(x), NFA_NOT, CHAR(y), NFA_NOT etc. */ + if (curc > 0) +! addstate(nextlist, t->state->out, &t->sub, clen); + break; + + case NFA_ANY: + /* Any char except '\0', (end of input) does not match. */ + if (curc > 0) +! addstate(nextlist, t->state->out, &t->sub, clen); + break; + + /* +--- 4246,4258 ---- + /* This follows a series of negated nodes, like: + * CHAR(x), NFA_NOT, CHAR(y), NFA_NOT etc. */ + if (curc > 0) +! addstate(nextlist, t->state->out, &t->subs, clen); + break; + + case NFA_ANY: + /* Any char except '\0', (end of input) does not match. */ + if (curc > 0) +! addstate(nextlist, t->state->out, &t->subs, clen); + break; + + /* +*************** +*** 4096,4114 **** + case NFA_BACKREF7: + case NFA_BACKREF8: + case NFA_BACKREF9: +! /* \1 .. \9 */ + { +! int subidx = t->state->c - NFA_BACKREF1 + 1; + int bytelen; + +! result = match_backref(&t->sub, subidx, &bytelen); + if (result) + { + if (bytelen == 0) + { + /* empty match always works, add NFA_SKIP with zero to + * be used next */ +! addstate_here(thislist, t->state->out, &t->sub, + &listidx); + thislist->t[listidx + 1].count = 0; + } +--- 4398,4439 ---- + case NFA_BACKREF7: + case NFA_BACKREF8: + case NFA_BACKREF9: +! #ifdef FEAT_SYN_HL +! case NFA_ZREF1: +! case NFA_ZREF2: +! case NFA_ZREF3: +! case NFA_ZREF4: +! case NFA_ZREF5: +! case NFA_ZREF6: +! case NFA_ZREF7: +! case NFA_ZREF8: +! case NFA_ZREF9: +! #endif +! /* \1 .. \9 \z1 .. \z9 */ + { +! int subidx; + int bytelen; + +! if (t->state->c <= NFA_BACKREF9) +! { +! subidx = t->state->c - NFA_BACKREF1 + 1; +! result = match_backref(&t->subs.norm, subidx, &bytelen); +! } +! #ifdef FEAT_SYN_HL +! else +! { +! subidx = t->state->c - NFA_ZREF1 + 1; +! result = match_zref(subidx, &bytelen); +! } +! #endif +! + if (result) + { + if (bytelen == 0) + { + /* empty match always works, add NFA_SKIP with zero to + * be used next */ +! addstate_here(thislist, t->state->out, &t->subs, + &listidx); + thislist->t[listidx + 1].count = 0; + } +*************** +*** 4116,4134 **** + { + /* match current character, jump ahead to out of + * NFA_SKIP */ +! addstate(nextlist, t->state->out->out, &t->sub, clen); + #ifdef ENABLE_LOG +! log_subexpr(&nextlist->t[nextlist->n - 1].sub); + #endif + } + else + { + /* skip ofer the matched characters, set character + * count in NFA_SKIP */ +! addstate(nextlist, t->state->out, &t->sub, bytelen); + nextlist->t[nextlist->n - 1].count = bytelen - clen; + #ifdef ENABLE_LOG +! log_subexpr(&nextlist->t[nextlist->n - 1].sub); + #endif + } + +--- 4441,4459 ---- + { + /* match current character, jump ahead to out of + * NFA_SKIP */ +! addstate(nextlist, t->state->out->out, &t->subs, clen); + #ifdef ENABLE_LOG +! log_subsexpr(&nextlist->t[nextlist->n - 1].subs); + #endif + } + else + { + /* skip ofer the matched characters, set character + * count in NFA_SKIP */ +! addstate(nextlist, t->state->out, &t->subs, bytelen); + nextlist->t[nextlist->n - 1].count = bytelen - clen; + #ifdef ENABLE_LOG +! log_subsexpr(&nextlist->t[nextlist->n - 1].subs); + #endif + } + +*************** +*** 4140,4157 **** + if (t->count - clen <= 0) + { + /* end of match, go to what follows */ +! addstate(nextlist, t->state->out, &t->sub, clen); + #ifdef ENABLE_LOG +! log_subexpr(&nextlist->t[nextlist->n - 1].sub); + #endif + } + else + { + /* add state again with decremented count */ +! addstate(nextlist, t->state, &t->sub, 0); + nextlist->t[nextlist->n - 1].count = t->count - clen; + #ifdef ENABLE_LOG +! log_subexpr(&nextlist->t[nextlist->n - 1].sub); + #endif + } + break; +--- 4465,4482 ---- + if (t->count - clen <= 0) + { + /* end of match, go to what follows */ +! addstate(nextlist, t->state->out, &t->subs, clen); + #ifdef ENABLE_LOG +! log_subsexpr(&nextlist->t[nextlist->n - 1].subs); + #endif + } + else + { + /* add state again with decremented count */ +! addstate(nextlist, t->state, &t->subs, 0); + nextlist->t[nextlist->n - 1].count = t->count - clen; + #ifdef ENABLE_LOG +! log_subsexpr(&nextlist->t[nextlist->n - 1].subs); + #endif + } + break; +*************** +*** 4169,4175 **** + nfa_re_num_cmp(t->state->val, t->state->c - NFA_LNUM, + (long_u)(reglnum + reg_firstlnum))); + if (result) +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + break; + + case NFA_COL: +--- 4494,4500 ---- + nfa_re_num_cmp(t->state->val, t->state->c - NFA_LNUM, + (long_u)(reglnum + reg_firstlnum))); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + case NFA_COL: +*************** +*** 4178,4184 **** + result = nfa_re_num_cmp(t->state->val, t->state->c - NFA_COL, + (long_u)(reginput - regline) + 1); + if (result) +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + break; + + case NFA_VCOL: +--- 4503,4509 ---- + result = nfa_re_num_cmp(t->state->val, t->state->c - NFA_COL, + (long_u)(reginput - regline) + 1); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + case NFA_VCOL: +*************** +*** 4189,4195 **** + reg_win == NULL ? curwin : reg_win, + regline, (colnr_T)(reginput - regline)) + 1); + if (result) +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + break; + + case NFA_CURSOR: +--- 4514,4520 ---- + reg_win == NULL ? curwin : reg_win, + regline, (colnr_T)(reginput - regline)) + 1); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + case NFA_CURSOR: +*************** +*** 4198,4204 **** + && ((colnr_T)(reginput - regline) + == reg_win->w_cursor.col)); + if (result) +! addstate_here(thislist, t->state->out, &t->sub, &listidx); + break; + + default: /* regular character */ +--- 4523,4529 ---- + && ((colnr_T)(reginput - regline) + == reg_win->w_cursor.col)); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + default: /* regular character */ +*************** +*** 4238,4244 **** + * Unless "endp" is not NULL, then we match the end position. + * Also don't start a match past the first line. */ + if (nfa_match == FALSE +! && ((start->c == NFA_MOPEN + 0 + && reglnum == 0 + && clen != 0 + && (ireg_maxcol == 0 +--- 4563,4569 ---- + * Unless "endp" is not NULL, then we match the end position. + * Also don't start a match past the first line. */ + if (nfa_match == FALSE +! && ((start->c == NFA_MOPEN + && reglnum == 0 + && clen != 0 + && (ireg_maxcol == 0 +*************** +*** 4305,4322 **** + * Returns 0 for failure, number of lines contained in the match otherwise. + */ + static long +! nfa_regtry(start, col) +! nfa_state_T *start; +! colnr_T col; + { + int i; +! regsub_T sub, m; + #ifdef ENABLE_LOG + FILE *f; + #endif + + reginput = regline + col; + need_clear_subexpr = TRUE; + + #ifdef ENABLE_LOG + f = fopen(NFA_REGEXP_RUN_LOG, "a"); +--- 4630,4653 ---- + * Returns 0 for failure, number of lines contained in the match otherwise. + */ + static long +! nfa_regtry(prog, col) +! nfa_regprog_T *prog; +! colnr_T col; + { + int i; +! regsubs_T subs, m; +! nfa_state_T *start = prog->start; + #ifdef ENABLE_LOG + FILE *f; + #endif + + reginput = regline + col; + need_clear_subexpr = TRUE; ++ #ifdef FEAT_SYN_HL ++ /* Clear the external match subpointers if necessary. */ ++ if (prog->reghasz == REX_SET) ++ need_clear_zsubexpr = TRUE; ++ #endif + + #ifdef ENABLE_LOG + f = fopen(NFA_REGEXP_RUN_LOG, "a"); +*************** +*** 4337,4366 **** + EMSG(_("Could not open temporary log file for writing ")); + #endif + +! if (REG_MULTI) +! { +! /* Use 0xff to set lnum to -1 */ +! vim_memset(sub.list.multi, 0xff, sizeof(struct multipos) * nfa_nsubexpr); +! vim_memset(m.list.multi, 0xff, sizeof(struct multipos) * nfa_nsubexpr); +! } +! else +! { +! vim_memset(sub.list.line, 0, sizeof(struct linepos) * nfa_nsubexpr); +! vim_memset(m.list.line, 0, sizeof(struct linepos) * nfa_nsubexpr); +! } +! sub.in_use = 0; +! m.in_use = 0; + +! if (nfa_regmatch(start, &sub, &m, NULL) == FALSE) + return 0; + + cleanup_subexpr(); + if (REG_MULTI) + { +! for (i = 0; i < sub.in_use; i++) + { +! reg_startpos[i] = sub.list.multi[i].start; +! reg_endpos[i] = sub.list.multi[i].end; + } + + if (reg_startpos[0].lnum < 0) +--- 4668,4690 ---- + EMSG(_("Could not open temporary log file for writing ")); + #endif + +! clear_sub(&subs.norm); +! clear_sub(&m.norm); +! #ifdef FEAT_SYN_HL +! clear_sub(&subs.synt); +! clear_sub(&m.synt); +! #endif + +! if (nfa_regmatch(start, &subs, &m, NULL) == FALSE) + return 0; + + cleanup_subexpr(); + if (REG_MULTI) + { +! for (i = 0; i < subs.norm.in_use; i++) + { +! reg_startpos[i] = subs.norm.list.multi[i].start; +! reg_endpos[i] = subs.norm.list.multi[i].end; + } + + if (reg_startpos[0].lnum < 0) +*************** +*** 4380,4389 **** + } + else + { +! for (i = 0; i < sub.in_use; i++) + { +! reg_startp[i] = sub.list.line[i].start; +! reg_endp[i] = sub.list.line[i].end; + } + + if (reg_startp[0] == NULL) +--- 4704,4713 ---- + } + else + { +! for (i = 0; i < subs.norm.in_use; i++) + { +! reg_startp[i] = subs.norm.list.line[i].start; +! reg_endp[i] = subs.norm.list.line[i].end; + } + + if (reg_startp[0] == NULL) +*************** +*** 4392,4397 **** +--- 4716,4758 ---- + reg_endp[0] = reginput; + } + ++ #ifdef FEAT_SYN_HL ++ /* Package any found \z(...\) matches for export. Default is none. */ ++ unref_extmatch(re_extmatch_out); ++ re_extmatch_out = NULL; ++ ++ if (prog->reghasz == REX_SET) ++ { ++ int i; ++ ++ cleanup_zsubexpr(); ++ re_extmatch_out = make_extmatch(); ++ for (i = 0; i < subs.synt.in_use; i++) ++ { ++ if (REG_MULTI) ++ { ++ struct multipos *mpos = &subs.synt.list.multi[i]; ++ ++ /* Only accept single line matches. */ ++ if (mpos->start.lnum >= 0 && mpos->start.lnum == mpos->end.lnum) ++ re_extmatch_out->matches[i] = ++ vim_strnsave(reg_getline(mpos->start.lnum) ++ + mpos->start.col, ++ mpos->end.col - mpos->start.col); ++ } ++ else ++ { ++ struct linepos *lpos = &subs.synt.list.line[i]; ++ ++ if (lpos->start != NULL && lpos->end != NULL) ++ re_extmatch_out->matches[i] = ++ vim_strnsave(lpos->start, ++ (int)(lpos->end - lpos->start)); ++ } ++ } ++ } ++ #endif ++ + return 1 + reglnum; + } + +*************** +*** 4461,4467 **** + prog->state[i].lastlist = 0; + } + +! retval = nfa_regtry(prog->start, col); + + theend: + return retval; +--- 4822,4828 ---- + prog->state[i].lastlist = 0; + } + +! retval = nfa_regtry(prog, col); + + theend: + return retval; +*************** +*** 4552,4557 **** +--- 4913,4922 ---- + nfa_postfix_dump(expr, OK); + nfa_dump(prog); + #endif ++ #ifdef FEAT_SYN_HL ++ /* Remember whether this pattern has any \z specials in it. */ ++ prog->reghasz = re_has_z; ++ #endif + + out: + vim_free(post_start); +*** ../vim-7.3.1089/src/version.c 2013-06-01 20:32:09.000000000 +0200 +--- src/version.c 2013-06-01 22:29:51.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1090, + /**/ + +-- +Despite the cost of living, have you noticed how it remains so popular? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 236828d43417c25cea527263c938338f9ca7872d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:49 +0200 Subject: [PATCH 0982/3340] - patchlevel 1091 --- 7.3.1091 | 104 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 104 insertions(+) create mode 100644 7.3.1091 diff --git a/7.3.1091 b/7.3.1091 new file mode 100644 index 00000000..efd5c5b3 --- /dev/null +++ b/7.3.1091 @@ -0,0 +1,104 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1091 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1091 +Problem: New regexp engine: no error when using \z1 or \z( where it does + not work. +Solution: Give an error message. +Files: src/regexp.c, src/regexp_nfa.c + + +*** ../vim-7.3.1090/src/regexp.c 2013-06-01 19:54:39.000000000 +0200 +--- src/regexp.c 2013-06-02 14:56:07.000000000 +0200 +*************** +*** 361,366 **** +--- 361,368 ---- + static char_u e_unmatchedpp[] = N_("E53: Unmatched %s%%("); + static char_u e_unmatchedp[] = N_("E54: Unmatched %s("); + static char_u e_unmatchedpar[] = N_("E55: Unmatched %s)"); ++ static char_u e_z_not_allowed[] = N_("E66: \\z( not allowed here"); ++ static char_u e_z1_not_allowed[] = N_("E67: \\z1 et al. not allowed here"); + + #define NOT_MULTI 0 + #define MULTI_ONE 1 +*************** +*** 2120,2126 **** + { + #ifdef FEAT_SYN_HL + case '(': if (reg_do_extmatch != REX_SET) +! EMSG_RET_NULL(_("E66: \\z( not allowed here")); + if (one_exactly) + EMSG_ONE_RET_NULL; + ret = reg(REG_ZPAREN, &flags); +--- 2122,2128 ---- + { + #ifdef FEAT_SYN_HL + case '(': if (reg_do_extmatch != REX_SET) +! EMSG_RET_NULL(_(e_z_not_allowed)); + if (one_exactly) + EMSG_ONE_RET_NULL; + ret = reg(REG_ZPAREN, &flags); +*************** +*** 2139,2145 **** + case '7': + case '8': + case '9': if (reg_do_extmatch != REX_USE) +! EMSG_RET_NULL(_("E67: \\z1 et al. not allowed here")); + ret = regnode(ZREF + c - '0'); + re_has_z = REX_USE; + break; +--- 2141,2147 ---- + case '7': + case '8': + case '9': if (reg_do_extmatch != REX_USE) +! EMSG_RET_NULL(_(e_z1_not_allowed)); + ret = regnode(ZREF + c - '0'); + re_has_z = REX_USE; + break; +*** ../vim-7.3.1090/src/regexp_nfa.c 2013-06-01 23:02:48.000000000 +0200 +--- src/regexp_nfa.c 2013-06-02 14:56:53.000000000 +0200 +*************** +*** 865,870 **** +--- 865,872 ---- + case '8': + case '9': + /* \z1...\z9 */ ++ if (reg_do_extmatch != REX_USE) ++ EMSG_RET_FAIL(_(e_z1_not_allowed)); + EMIT(NFA_ZREF1 + (no_Magic(c) - '1')); + /* No need to set nfa_has_backref, the sub-matches don't + * change when \z1 .. \z9 maches or not. */ +*************** +*** 872,877 **** +--- 874,881 ---- + break; + case '(': + /* \z( */ ++ if (reg_do_extmatch != REX_SET) ++ EMSG_RET_FAIL(_(e_z_not_allowed)); + if (nfa_reg(REG_ZPAREN) == FAIL) + return FAIL; /* cascaded error */ + re_has_z = REX_SET; +*** ../vim-7.3.1090/src/version.c 2013-06-01 23:02:48.000000000 +0200 +--- src/version.c 2013-06-02 14:58:17.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1091, + /**/ + +-- +Don't believe everything you hear or anything you say. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 901d3ad6e4259e7297dfcbe0ed73b7caf95496b8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:50 +0200 Subject: [PATCH 0983/3340] - patchlevel 1092 --- 7.3.1092 | 189 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 189 insertions(+) create mode 100644 7.3.1092 diff --git a/7.3.1092 b/7.3.1092 new file mode 100644 index 00000000..5887bf23 --- /dev/null +++ b/7.3.1092 @@ -0,0 +1,189 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1092 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1092 +Problem: Can't build with regexp debugging. NFA debug output shows wrong + pattern. +Solution: Fix debugging code for recent changes. Add the pattern to the + program. +Files: src/regexp_nfa.c, src/regexp.h + + +*** ../vim-7.3.1091/src/regexp_nfa.c 2013-06-02 15:01:51.000000000 +0200 +--- src/regexp_nfa.c 2013-06-02 15:48:57.000000000 +0200 +*************** +*** 3133,3144 **** + { + int col; + +! if (thread->sub.in_use <= 0) + col = -1; + else if (REG_MULTI) +! col = thread->sub.list.multi[0].start.col; + else +! col = (int)(thread->sub.list.line[0].start - regline); + nfa_set_code(state->c); + fprintf(log_fd, "> Adding state %d to list %d. char %d: %s (start col %d)\n", + abs(state->id), l->id, state->c, code, col); +--- 3133,3144 ---- + { + int col; + +! if (thread->subs.norm.in_use <= 0) + col = -1; + else if (REG_MULTI) +! col = thread->subs.norm.list.multi[0].start.col; + else +! col = (int)(thread->subs.norm.list.line[0].start - regline); + nfa_set_code(state->c); + fprintf(log_fd, "> Adding state %d to list %d. char %d: %s (start col %d)\n", + abs(state->id), l->id, state->c, code, col); +*************** +*** 3152,3163 **** + { + int col; + +! if (sub->in_use <= 0) + col = -1; + else if (REG_MULTI) +! col = sub->list.multi[0].start.col; + else +! col = (int)(sub->list.line[0].start - regline); + nfa_set_code(state->c); + fprintf(log_fd, "> Processing state %d for list %d. char %d: %s (start col %d)\n", + abs(state->id), l->id, state->c, code, col); +--- 3152,3163 ---- + { + int col; + +! if (subs->norm.in_use <= 0) + col = -1; + else if (REG_MULTI) +! col = subs->norm.list.multi[0].start.col; + else +! col = (int)(subs->norm.list.line[0].start - regline); + nfa_set_code(state->c); + fprintf(log_fd, "> Processing state %d for list %d. char %d: %s (start col %d)\n", + abs(state->id), l->id, state->c, code, col); +*************** +*** 3836,3847 **** + { + int col; + +! if (t->sub.in_use <= 0) + col = -1; + else if (REG_MULTI) +! col = t->sub.list.multi[0].start.col; + else +! col = (int)(t->sub.list.line[0].start - regline); + nfa_set_code(t->state->c); + fprintf(log_fd, "(%d) char %d %s (start col %d) ... \n", + abs(t->state->id), (int)t->state->c, code, col); +--- 3836,3847 ---- + { + int col; + +! if (t->subs.norm.in_use <= 0) + col = -1; + else if (REG_MULTI) +! col = t->subs.norm.list.multi[0].start.col; + else +! col = (int)(t->subs.norm.list.line[0].start - regline); + nfa_set_code(t->state->c); + fprintf(log_fd, "(%d) char %d %s (start col %d) ... \n", + abs(t->state->id), (int)t->state->c, code, col); +*************** +*** 4818,4823 **** +--- 4818,4826 ---- + nfa_has_zend = prog->has_zend; + nfa_has_backref = prog->has_backref; + nfa_nsubexpr = prog->nsubexp; ++ #ifdef DEBUG ++ nfa_regengine.expr = prog->pattern; ++ #endif + + nstate = prog->nstate; + for (i = 0; i < nstate; ++i) +*************** +*** 4828,4833 **** +--- 4831,4840 ---- + + retval = nfa_regtry(prog, col); + ++ #ifdef DEBUG ++ nfa_regengine.expr = NULL; ++ #endif ++ + theend: + return retval; + } +*************** +*** 4921,4926 **** +--- 4928,4937 ---- + /* Remember whether this pattern has any \z specials in it. */ + prog->reghasz = re_has_z; + #endif ++ #ifdef DEBUG ++ prog->pattern = vim_strsave(expr); /* memory will leak */ ++ nfa_regengine.expr = NULL; ++ #endif + + out: + vim_free(post_start); +*** ../vim-7.3.1091/src/regexp.h 2013-06-01 23:02:48.000000000 +0200 +--- src/regexp.h 2013-06-02 15:42:57.000000000 +0200 +*************** +*** 86,98 **** + regengine_T *engine; + unsigned regflags; + +! regprog_T regprog; +! nfa_state_T *start; + int has_zend; /* pattern contains \ze */ + int has_backref; /* pattern contains \1 .. \9 */ + #ifdef FEAT_SYN_HL + int reghasz; + #endif + int nsubexp; /* number of () */ + int nstate; + nfa_state_T state[0]; /* actually longer.. */ +--- 86,100 ---- + regengine_T *engine; + unsigned regflags; + +! nfa_state_T *start; /* points into state[] */ + int has_zend; /* pattern contains \ze */ + int has_backref; /* pattern contains \1 .. \9 */ + #ifdef FEAT_SYN_HL + int reghasz; + #endif ++ #ifdef DEBUG ++ char_u *pattern; ++ #endif + int nsubexp; /* number of () */ + int nstate; + nfa_state_T state[0]; /* actually longer.. */ +*** ../vim-7.3.1091/src/version.c 2013-06-02 15:01:51.000000000 +0200 +--- src/version.c 2013-06-02 15:53:16.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1092, + /**/ + +-- +I started out with nothing, and I still have most of it. + -- Michael Davis -- "Tonight Show" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9587fc5d408ee06bd26f15cfe977b3dcada735c9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:50 +0200 Subject: [PATCH 0984/3340] - patchlevel 1093 --- 7.3.1093 | 87 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 87 insertions(+) create mode 100644 7.3.1093 diff --git a/7.3.1093 b/7.3.1093 new file mode 100644 index 00000000..1c52bf57 --- /dev/null +++ b/7.3.1093 @@ -0,0 +1,87 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1093 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1093 +Problem: New regexp engine: When a sub expression is empty \1 skips a + character. +Solution: Make \1 try the current position when the match is emtpy. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1092/src/regexp_nfa.c 2013-06-02 15:55:52.000000000 +0200 +--- src/regexp_nfa.c 2013-06-02 16:03:28.000000000 +0200 +*************** +*** 4435,4445 **** + { + if (bytelen == 0) + { +! /* empty match always works, add NFA_SKIP with zero to +! * be used next */ +! addstate_here(thislist, t->state->out, &t->subs, + &listidx); +- thislist->t[listidx + 1].count = 0; + } + else if (bytelen <= clen) + { +--- 4435,4444 ---- + { + if (bytelen == 0) + { +! /* empty match always works, output of NFA_SKIP to be +! * used next */ +! addstate_here(thislist, t->state->out->out, &t->subs, + &listidx); + } + else if (bytelen <= clen) + { +*** ../vim-7.3.1092/src/testdir/test64.in 2013-06-01 19:54:39.000000000 +0200 +--- src/testdir/test64.in 2013-06-02 16:02:56.000000000 +0200 +*************** +*** 361,366 **** +--- 361,367 ---- + :call add(tl, [2, '\(\i\+\) \1', ' abc abc', 'abc abc', 'abc']) + :call add(tl, [2, '\(\i\+\) \1', 'xgoo goox', 'goo goo', 'goo']) + :call add(tl, [2, '\(a\)\(b\)\(c\)\(dd\)\(e\)\(f\)\(g\)\(h\)\(i\)\1\2\3\4\5\6\7\8\9', 'xabcddefghiabcddefghix', 'abcddefghiabcddefghi', 'a', 'b', 'c', 'dd', 'e', 'f', 'g', 'h', 'i']) ++ :call add(tl, [2, '\(\d*\)a \1b', ' a b ', 'a b', '']) + :" + :"""" Look-behind with limit + :call add(tl, [2, '<\@<=span.', 'xxspanxx Date: Tue, 4 Jun 2013 12:06:51 +0200 Subject: [PATCH 0985/3340] - patchlevel 1094 --- 7.3.1094 | 291 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 291 insertions(+) create mode 100644 7.3.1094 diff --git a/7.3.1094 b/7.3.1094 new file mode 100644 index 00000000..1cd7e6eb --- /dev/null +++ b/7.3.1094 @@ -0,0 +1,291 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1094 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1094 +Problem: New regexp engine: Attempts to match "^" at every character. +Solution: Only try "^" at the start of a line. +Files: rc/regexp_nfa.c + + +*** ../vim-7.3.1093/src/regexp_nfa.c 2013-06-02 16:07:05.000000000 +0200 +--- src/regexp_nfa.c 2013-06-02 16:24:04.000000000 +0200 +*************** +*** 249,254 **** +--- 249,256 ---- + * executing. */ + static int istate; /* Index in the state vector, used in new_state() */ + ++ /* If not NULL match must end at this position */ ++ static save_se_T *nfa_endp = NULL; + + static int nfa_regcomp_start __ARGS((char_u*expr, int re_flags)); + static int nfa_recognize_char_class __ARGS((char_u *start, char_u *end, int extra_newl)); +*************** +*** 3080,3085 **** +--- 3082,3099 ---- + state->lastlist = l->id; + break; + ++ case NFA_BOL: ++ case NFA_BOF: ++ /* "^" won't match past end-of-line, don't bother trying. ++ * Except when we are going to the next line for a look-behind ++ * match. */ ++ if (reginput > regline ++ && (nfa_endp == NULL ++ || !REG_MULTI ++ || reglnum == nfa_endp->se_u.pos.lnum)) ++ goto skip_add; ++ /* FALLTHROUGH */ ++ + default: + if (state->lastlist == l->id) + { +*************** +*** 3659,3682 **** + return val == pos; + } + +! static int nfa_regmatch __ARGS((nfa_state_T *start, regsubs_T *submatch, regsubs_T *m, save_se_T *endp)); + + /* + * Main matching routine. + * + * Run NFA to determine whether it matches reginput. + * +! * When "endp" is not NULL it is a required end-of-match position. + * + * Return TRUE if there is a match, FALSE otherwise. + * Note: Caller must ensure that: start != NULL. + */ + static int +! nfa_regmatch(start, submatch, m, endp) + nfa_state_T *start; + regsubs_T *submatch; + regsubs_T *m; +- save_se_T *endp; + { + int result; + int size = 0; +--- 3673,3695 ---- + return val == pos; + } + +! static int nfa_regmatch __ARGS((nfa_state_T *start, regsubs_T *submatch, regsubs_T *m)); + + /* + * Main matching routine. + * + * Run NFA to determine whether it matches reginput. + * +! * When "nfa_endp" is not NULL it is a required end-of-match position. + * + * Return TRUE if there is a match, FALSE otherwise. + * Note: Caller must ensure that: start != NULL. + */ + static int +! nfa_regmatch(start, submatch, m) + nfa_state_T *start; + regsubs_T *submatch; + regsubs_T *m; + { + int result; + int size = 0; +*************** +*** 3888,3913 **** + else + { + #ifdef ENABLE_LOG +! if (endp != NULL) + { + if (REG_MULTI) + fprintf(log_fd, "Current lnum: %d, endp lnum: %d; current col: %d, endp col: %d\n", + (int)reglnum, +! (int)endp->se_u.pos.lnum, + (int)(reginput - regline), +! endp->se_u.pos.col); + else + fprintf(log_fd, "Current col: %d, endp col: %d\n", + (int)(reginput - regline), +! (int)(endp->se_u.ptr - reginput)); + } + #endif +! /* It's only a match if it ends at "endp" */ +! if (endp != NULL && (REG_MULTI +! ? (reglnum != endp->se_u.pos.lnum + || (int)(reginput - regline) +! != endp->se_u.pos.col) +! : reginput != endp->se_u.ptr)) + break; + + /* do not set submatches for \@! */ +--- 3901,3926 ---- + else + { + #ifdef ENABLE_LOG +! if (nfa_endp != NULL) + { + if (REG_MULTI) + fprintf(log_fd, "Current lnum: %d, endp lnum: %d; current col: %d, endp col: %d\n", + (int)reglnum, +! (int)nfa_endp->se_u.pos.lnum, + (int)(reginput - regline), +! nfa_endp->se_u.pos.col); + else + fprintf(log_fd, "Current col: %d, endp col: %d\n", + (int)(reginput - regline), +! (int)(nfa_endp->se_u.ptr - reginput)); + } + #endif +! /* It's only a match if it ends at "nfa_endp" */ +! if (nfa_endp != NULL && (REG_MULTI +! ? (reglnum != nfa_endp->se_u.pos.lnum + || (int)(reginput - regline) +! != nfa_endp->se_u.pos.col) +! : reginput != nfa_endp->se_u.ptr)) + break; + + /* do not set submatches for \@! */ +*************** +*** 3929,3934 **** +--- 3942,3948 ---- + char_u *save_regline = regline; + int save_reglnum = reglnum; + int save_nfa_match = nfa_match; ++ save_se_T *save_nfa_endp = nfa_endp; + save_se_T endpos; + save_se_T *endposp = NULL; + +*************** +*** 4012,4018 **** + * recursion. */ + nfa_save_listids(start, listids); + nfa_set_null_listids(start); +! result = nfa_regmatch(t->state->out, submatch, m, endposp); + nfa_set_neg_listids(start); + nfa_restore_listids(start, listids); + +--- 4026,4033 ---- + * recursion. */ + nfa_save_listids(start, listids); + nfa_set_null_listids(start); +! nfa_endp = endposp; +! result = nfa_regmatch(t->state->out, submatch, m); + nfa_set_neg_listids(start); + nfa_restore_listids(start, listids); + +*************** +*** 4021,4026 **** +--- 4036,4042 ---- + regline = save_regline; + reglnum = save_reglnum; + nfa_match = save_nfa_match; ++ nfa_endp = save_nfa_endp; + + #ifdef ENABLE_LOG + log_fd = fopen(NFA_REGEXP_RUN_LOG, "a"); +*************** +*** 4563,4569 **** + * matters! + * Do not add the start state in recursive calls of nfa_regmatch(), + * because recursive calls should only start in the first position. +! * Unless "endp" is not NULL, then we match the end position. + * Also don't start a match past the first line. */ + if (nfa_match == FALSE + && ((start->c == NFA_MOPEN +--- 4579,4585 ---- + * matters! + * Do not add the start state in recursive calls of nfa_regmatch(), + * because recursive calls should only start in the first position. +! * Unless "nfa_endp" is not NULL, then we match the end position. + * Also don't start a match past the first line. */ + if (nfa_match == FALSE + && ((start->c == NFA_MOPEN +*************** +*** 4571,4583 **** + && clen != 0 + && (ireg_maxcol == 0 + || (colnr_T)(reginput - regline) < ireg_maxcol)) +! || (endp != NULL + && (REG_MULTI +! ? (reglnum < endp->se_u.pos.lnum +! || (reglnum == endp->se_u.pos.lnum + && (int)(reginput - regline) +! < endp->se_u.pos.col)) +! : reginput < endp->se_u.ptr)))) + { + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); +--- 4587,4599 ---- + && clen != 0 + && (ireg_maxcol == 0 + || (colnr_T)(reginput - regline) < ireg_maxcol)) +! || (nfa_endp != NULL + && (REG_MULTI +! ? (reglnum < nfa_endp->se_u.pos.lnum +! || (reglnum == nfa_endp->se_u.pos.lnum + && (int)(reginput - regline) +! < nfa_endp->se_u.pos.col)) +! : reginput < nfa_endp->se_u.ptr)))) + { + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); +*************** +*** 4601,4608 **** + * finish. */ + if (clen != 0) + reginput += clen; +! else if (go_to_nextline || (endp != NULL && REG_MULTI +! && reglnum < endp->se_u.pos.lnum)) + reg_nextline(); + else + break; +--- 4617,4624 ---- + * finish. */ + if (clen != 0) + reginput += clen; +! else if (go_to_nextline || (nfa_endp != NULL && REG_MULTI +! && reglnum < nfa_endp->se_u.pos.lnum)) + reg_nextline(); + else + break; +*************** +*** 4678,4684 **** + clear_sub(&m.synt); + #endif + +! if (nfa_regmatch(start, &subs, &m, NULL) == FALSE) + return 0; + + cleanup_subexpr(); +--- 4694,4700 ---- + clear_sub(&m.synt); + #endif + +! if (nfa_regmatch(start, &subs, &m) == FALSE) + return 0; + + cleanup_subexpr(); +*** ../vim-7.3.1093/src/version.c 2013-06-02 16:07:05.000000000 +0200 +--- src/version.c 2013-06-02 16:25:02.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1094, + /**/ + +-- +The future isn't what it used to be. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 97c8da77747cf655c62a17c03b6ef8de9bc69687 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:52 +0200 Subject: [PATCH 0986/3340] - patchlevel 1095 --- 7.3.1095 | 331 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 331 insertions(+) create mode 100644 7.3.1095 diff --git a/7.3.1095 b/7.3.1095 new file mode 100644 index 00000000..6b9c2c99 --- /dev/null +++ b/7.3.1095 @@ -0,0 +1,331 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1095 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1095 +Problem: Compiler warnings for shadowed variables. (Christian Brabandt) +Solution: Rename new_state() to alloc_state(). Remove unnecessary + declaration. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1094/src/regexp_nfa.c 2013-06-02 16:34:14.000000000 +0200 +--- src/regexp_nfa.c 2013-06-02 16:38:44.000000000 +0200 +*************** +*** 247,253 **** + + static int nstate; /* Number of states in the NFA. Also used when + * executing. */ +! static int istate; /* Index in the state vector, used in new_state() */ + + /* If not NULL match must end at this position */ + static save_se_T *nfa_endp = NULL; +--- 247,253 ---- + + static int nstate; /* Number of states in the NFA. Also used when + * executing. */ +! static int istate; /* Index in the state vector, used in alloc_state() */ + + /* If not NULL match must end at this position */ + static save_se_T *nfa_endp = NULL; +*************** +*** 268,274 **** + static void nfa_dump __ARGS((nfa_regprog_T *prog)); + #endif + static int *re2post __ARGS((void)); +! static nfa_state_T *new_state __ARGS((int c, nfa_state_T *out, nfa_state_T *out1)); + static nfa_state_T *post2nfa __ARGS((int *postfix, int *end, int nfa_calc_size)); + static int check_char_class __ARGS((int class, int c)); + static void st_error __ARGS((int *postfix, int *end, int *p)); +--- 268,274 ---- + static void nfa_dump __ARGS((nfa_regprog_T *prog)); + #endif + static int *re2post __ARGS((void)); +! static nfa_state_T *alloc_state __ARGS((int c, nfa_state_T *out, nfa_state_T *out1)); + static nfa_state_T *post2nfa __ARGS((int *postfix, int *end, int nfa_calc_size)); + static int check_char_class __ARGS((int class, int c)); + static void st_error __ARGS((int *postfix, int *end, int *p)); +*************** +*** 2134,2140 **** + * Allocate and initialize nfa_state_T. + */ + static nfa_state_T * +! new_state(c, out, out1) + int c; + nfa_state_T *out; + nfa_state_T *out1; +--- 2134,2140 ---- + * Allocate and initialize nfa_state_T. + */ + static nfa_state_T * +! alloc_state(c, out, out1) + int c; + nfa_state_T *out; + nfa_state_T *out1; +*************** +*** 2431,2437 **** + } + e2 = POP(); + e1 = POP(); +! s = new_state(NFA_SPLIT, e1.start, e2.start); + if (s == NULL) + goto theend; + PUSH(frag(s, append(e1.out, e2.out))); +--- 2431,2437 ---- + } + e2 = POP(); + e1 = POP(); +! s = alloc_state(NFA_SPLIT, e1.start, e2.start); + if (s == NULL) + goto theend; + PUSH(frag(s, append(e1.out, e2.out))); +*************** +*** 2445,2451 **** + break; + } + e = POP(); +! s = new_state(NFA_SPLIT, e.start, NULL); + if (s == NULL) + goto theend; + patch(e.out, s); +--- 2445,2451 ---- + break; + } + e = POP(); +! s = alloc_state(NFA_SPLIT, e.start, NULL); + if (s == NULL) + goto theend; + patch(e.out, s); +*************** +*** 2460,2466 **** + break; + } + e = POP(); +! s = new_state(NFA_SPLIT, NULL, e.start); + if (s == NULL) + goto theend; + patch(e.out, s); +--- 2460,2466 ---- + break; + } + e = POP(); +! s = alloc_state(NFA_SPLIT, NULL, e.start); + if (s == NULL) + goto theend; + patch(e.out, s); +*************** +*** 2475,2481 **** + break; + } + e = POP(); +! s = new_state(NFA_SPLIT, e.start, NULL); + if (s == NULL) + goto theend; + PUSH(frag(s, append(e.out, list1(&s->out1)))); +--- 2475,2481 ---- + break; + } + e = POP(); +! s = alloc_state(NFA_SPLIT, e.start, NULL); + if (s == NULL) + goto theend; + PUSH(frag(s, append(e.out, list1(&s->out1)))); +*************** +*** 2489,2495 **** + break; + } + e = POP(); +! s = new_state(NFA_SPLIT, NULL, e.start); + if (s == NULL) + goto theend; + PUSH(frag(s, append(e.out, list1(&s->out)))); +--- 2489,2495 ---- + break; + } + e = POP(); +! s = alloc_state(NFA_SPLIT, NULL, e.start); + if (s == NULL) + goto theend; + PUSH(frag(s, append(e.out, list1(&s->out)))); +*************** +*** 2503,2509 **** + nstate++; + break; + } +! s = new_state(NFA_SKIP_CHAR, NULL, NULL); + if (s == NULL) + goto theend; + PUSH(frag(s, list1(&s->out))); +--- 2503,2509 ---- + nstate++; + break; + } +! s = alloc_state(NFA_SKIP_CHAR, NULL, NULL); + if (s == NULL) + goto theend; + PUSH(frag(s, list1(&s->out))); +*************** +*** 2526,2537 **** + break; + } + e = POP(); +! s1 = new_state(NFA_END_INVISIBLE, NULL, NULL); + if (s1 == NULL) + goto theend; + patch(e.out, s1); + +! s = new_state(NFA_START_INVISIBLE, e.start, s1); + if (s == NULL) + goto theend; + if (*p == NFA_PREV_ATOM_NO_WIDTH_NEG +--- 2526,2537 ---- + break; + } + e = POP(); +! s1 = alloc_state(NFA_END_INVISIBLE, NULL, NULL); + if (s1 == NULL) + goto theend; + patch(e.out, s1); + +! s = alloc_state(NFA_START_INVISIBLE, e.start, s1); + if (s == NULL) + goto theend; + if (*p == NFA_PREV_ATOM_NO_WIDTH_NEG +*************** +*** 2622,2631 **** + * empty groups of parenthesis, and empty mbyte chars */ + if (stackp == stack) + { +! s = new_state(mopen, NULL, NULL); + if (s == NULL) + goto theend; +! s1 = new_state(mclose, NULL, NULL); + if (s1 == NULL) + goto theend; + patch(list1(&s->out), s1); +--- 2622,2631 ---- + * empty groups of parenthesis, and empty mbyte chars */ + if (stackp == stack) + { +! s = alloc_state(mopen, NULL, NULL); + if (s == NULL) + goto theend; +! s1 = alloc_state(mclose, NULL, NULL); + if (s1 == NULL) + goto theend; + patch(list1(&s->out), s1); +*************** +*** 2636,2646 **** + /* At least one node was emitted before NFA_MOPEN, so + * at least one node will be between NFA_MOPEN and NFA_MCLOSE */ + e = POP(); +! s = new_state(mopen, e.start, NULL); /* `(' */ + if (s == NULL) + goto theend; + +! s1 = new_state(mclose, NULL, NULL); /* `)' */ + if (s1 == NULL) + goto theend; + patch(e.out, s1); +--- 2636,2646 ---- + /* At least one node was emitted before NFA_MOPEN, so + * at least one node will be between NFA_MOPEN and NFA_MCLOSE */ + e = POP(); +! s = alloc_state(mopen, e.start, NULL); /* `(' */ + if (s == NULL) + goto theend; + +! s1 = alloc_state(mclose, NULL, NULL); /* `)' */ + if (s1 == NULL) + goto theend; + patch(e.out, s1); +*************** +*** 2679,2688 **** + nstate += 2; + break; + } +! s = new_state(*p, NULL, NULL); + if (s == NULL) + goto theend; +! s1 = new_state(NFA_SKIP, NULL, NULL); + if (s1 == NULL) + goto theend; + patch(list1(&s->out), s1); +--- 2679,2688 ---- + nstate += 2; + break; + } +! s = alloc_state(*p, NULL, NULL); + if (s == NULL) + goto theend; +! s1 = alloc_state(NFA_SKIP, NULL, NULL); + if (s1 == NULL) + goto theend; + patch(list1(&s->out), s1); +*************** +*** 2704,2710 **** + break; + } + e1 = POP(); +! s = new_state(*p, NULL, NULL); + if (s == NULL) + goto theend; + s->val = e1.start->c; +--- 2704,2710 ---- + break; + } + e1 = POP(); +! s = alloc_state(*p, NULL, NULL); + if (s == NULL) + goto theend; + s->val = e1.start->c; +*************** +*** 2720,2726 **** + nstate++; + break; + } +! s = new_state(*p, NULL, NULL); + if (s == NULL) + goto theend; + PUSH(frag(s, list1(&s->out))); +--- 2720,2726 ---- + nstate++; + break; + } +! s = alloc_state(*p, NULL, NULL); + if (s == NULL) + goto theend; + PUSH(frag(s, list1(&s->out))); +*************** +*** 4742,4749 **** + + if (prog->reghasz == REX_SET) + { +- int i; +- + cleanup_zsubexpr(); + re_extmatch_out = make_extmatch(); + for (i = 0; i < subs.synt.in_use; i++) +--- 4742,4747 ---- +*** ../vim-7.3.1094/src/version.c 2013-06-02 16:34:14.000000000 +0200 +--- src/version.c 2013-06-02 16:39:59.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1095, + /**/ + +-- +Microsoft is to software what McDonalds is to gourmet cooking + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 438ef4ca01e01787bc39632a3a77d332aef5bc4d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:53 +0200 Subject: [PATCH 0987/3340] - patchlevel 1096 --- 7.3.1096 | 333 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 333 insertions(+) create mode 100644 7.3.1096 diff --git a/7.3.1096 b/7.3.1096 new file mode 100644 index 00000000..bc64eeda --- /dev/null +++ b/7.3.1096 @@ -0,0 +1,333 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1096 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1096 +Problem: Python: popitem() was not defined in a standard way. +Solution: Remove the argument from popitem(). (ZyX) +Files: runtime/doc/if_pyth.txt, src/if_py_both.h, src/testdir/test86.in, + src/testdir/test86.ok, src/testdir/test87.in, + src/testdir/test87.ok + + +*** ../vim-7.3.1095/runtime/doc/if_pyth.txt 2013-05-30 13:32:26.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-06-02 17:39:35.000000000 +0200 +*************** +*** 174,180 **** + vim.bindeval(str) *python-bindeval* + Like |python-eval|, but returns special objects described in + |python-bindeval-objects|. These python objects let you modify (|List| +! or |Dictionary|) or call (|Funcref|) vim objecs. + + Error object of the "vim" module + +--- 174,180 ---- + vim.bindeval(str) *python-bindeval* + Like |python-eval|, but returns special objects described in + |python-bindeval-objects|. These python objects let you modify (|List| +! or |Dictionary|) or call (|Funcref|) vim objects. + + Error object of the "vim" module + +*************** +*** 208,214 **** + :py w in vim.windows # Membership test + :py n = len(vim.windows) # Number of elements + :py for w in vim.windows: # Sequential access +! < Note: vim.windows object always accesses current tab page,. + |python-tabpage|.windows objects are bound to parent |python-tabpage| + object and always use windows from that tab page (or throw vim.error + in case tab page was deleted). You can keep a reference to both +--- 208,214 ---- + :py w in vim.windows # Membership test + :py n = len(vim.windows) # Number of elements + :py for w in vim.windows: # Sequential access +! < Note: vim.windows object always accesses current tab page. + |python-tabpage|.windows objects are bound to parent |python-tabpage| + object and always use windows from that tab page (or throw vim.error + in case tab page was deleted). You can keep a reference to both +*************** +*** 494,503 **** + Remove specified key from dictionary and return + corresponding value. If key is not found and default is + given returns the default, otherwise raises KeyError. +! popitem(key) +! Remove specified key from dictionary and return a pair +! with it and the corresponding value. Returned key is a new +! object. + has_key(key) + Check whether dictionary contains specified key, similar + to `key in dict`. +--- 494,502 ---- + Remove specified key from dictionary and return + corresponding value. If key is not found and default is + given returns the default, otherwise raises KeyError. +! popitem() +! Remove random key from dictionary and return (key, value) +! pair. + has_key(key) + Check whether dictionary contains specified key, similar + to `key in dict`. +*** ../vim-7.3.1095/src/if_py_both.h 2013-05-31 20:49:27.000000000 +0200 +--- src/if_py_both.h 2013-06-02 17:39:35.000000000 +0200 +*************** +*** 1061,1077 **** + dictitem_free(di); + } + +- if (flags & DICT_FLAG_RETURN_PAIR) +- { +- PyObject *tmp = r; +- +- if (!(r = Py_BuildValue("(" Py_bytes_fmt "O)", hi->hi_key, tmp))) +- { +- Py_DECREF(tmp); +- return NULL; +- } +- } +- + return r; + } + +--- 1061,1066 ---- +*************** +*** 1457,1471 **** + } + + static PyObject * +! DictionaryPopItem(DictionaryObject *self, PyObject *args) + { +! PyObject *keyObject; + +! if (!PyArg_ParseTuple(args, "O", &keyObject)) + return NULL; + +! return _DictionaryItem(self, keyObject, +! DICT_FLAG_POP|DICT_FLAG_RETURN_PAIR); + } + + static PyObject * +--- 1446,1483 ---- + } + + static PyObject * +! DictionaryPopItem(DictionaryObject *self) + { +! hashitem_T *hi; +! PyObject *r; +! PyObject *valObject; +! dictitem_T *di; + +! if (self->dict->dv_hashtab.ht_used == 0) +! { +! PyErr_SetNone(PyExc_KeyError); +! return NULL; +! } +! +! hi = self->dict->dv_hashtab.ht_array; +! while (HASHITEM_EMPTY(hi)) +! ++hi; +! +! di = dict_lookup(hi); +! +! if (!(valObject = ConvertToPyObject(&di->di_tv))) + return NULL; + +! if (!(r = Py_BuildValue("(" Py_bytes_fmt "O)", hi->hi_key, valObject))) +! { +! Py_DECREF(valObject); +! return NULL; +! } +! +! hash_remove(&self->dict->dv_hashtab, hi); +! dictitem_free(di); +! +! return r; + } + + static PyObject * +*************** +*** 1505,1511 **** + {"update", (PyCFunction)DictionaryUpdate, METH_VARARGS|METH_KEYWORDS, ""}, + {"get", (PyCFunction)DictionaryGet, METH_VARARGS, ""}, + {"pop", (PyCFunction)DictionaryPop, METH_VARARGS, ""}, +! {"popitem", (PyCFunction)DictionaryPopItem, METH_VARARGS, ""}, + {"has_key", (PyCFunction)DictionaryHasKey, METH_VARARGS, ""}, + {"__dir__", (PyCFunction)DictionaryDir, METH_NOARGS, ""}, + { NULL, NULL, 0, NULL} +--- 1517,1523 ---- + {"update", (PyCFunction)DictionaryUpdate, METH_VARARGS|METH_KEYWORDS, ""}, + {"get", (PyCFunction)DictionaryGet, METH_VARARGS, ""}, + {"pop", (PyCFunction)DictionaryPop, METH_VARARGS, ""}, +! {"popitem", (PyCFunction)DictionaryPopItem, METH_NOARGS, ""}, + {"has_key", (PyCFunction)DictionaryHasKey, METH_VARARGS, ""}, + {"__dir__", (PyCFunction)DictionaryDir, METH_NOARGS, ""}, + { NULL, NULL, 0, NULL} +*** ../vim-7.3.1095/src/testdir/test86.in 2013-06-01 20:32:09.000000000 +0200 +--- src/testdir/test86.in 2013-06-02 17:39:35.000000000 +0200 +*************** +*** 83,89 **** + :$put =pyeval('repr(''1'' in d)') + :$put =pyeval('repr(list(iter(d)))') + :$put =string(d) +! :$put =pyeval('repr(d.popitem(''0''))') + :$put =pyeval('repr(d.get(''0''))') + :$put =pyeval('repr(list(iter(d)))') + :" +--- 83,89 ---- + :$put =pyeval('repr(''1'' in d)') + :$put =pyeval('repr(list(iter(d)))') + :$put =string(d) +! :$put =pyeval('repr(d.popitem())') + :$put =pyeval('repr(d.get(''0''))') + :$put =pyeval('repr(list(iter(d)))') + :" +*************** +*** 226,232 **** + em('d[u"a\\0b"]=1') + + em('d.pop("abc")') +! em('d.popitem("abc")') + EOF + :$put =messages + :unlet messages +--- 226,232 ---- + em('d[u"a\\0b"]=1') + + em('d.pop("abc")') +! em('d.popitem()') + EOF + :$put =messages + :unlet messages +*** ../vim-7.3.1095/src/testdir/test86.ok 2013-06-01 20:32:09.000000000 +0200 +--- src/testdir/test86.ok 2013-06-02 17:39:35.000000000 +0200 +*************** +*** 26,32 **** + False + ['0'] + {'0': -1} +! ('', -1L) + None + [] + [0, 1, 2, 3] +--- 26,32 ---- + False + ['0'] + {'0': -1} +! ('0', -1L) + None + [] + [0, 1, 2, 3] +*************** +*** 666,672 **** + d.update((("a", FailingMappingKey()),)):(, NotImplementedError()) + <<< Finished + >> DictionaryPopItem +! d.popitem(1, 2):(, TypeError('function takes exactly 1 argument (2 given)',)) + >> DictionaryHasKey + d.has_key():(, TypeError('function takes exactly 1 argument (0 given)',)) + > List +--- 666,672 ---- + d.update((("a", FailingMappingKey()),)):(, NotImplementedError()) + <<< Finished + >> DictionaryPopItem +! d.popitem(1, 2):(, TypeError('popitem() takes no arguments (2 given)',)) + >> DictionaryHasKey + d.has_key():(, TypeError('function takes exactly 1 argument (0 given)',)) + > List +*** ../vim-7.3.1095/src/testdir/test87.in 2013-06-01 20:32:09.000000000 +0200 +--- src/testdir/test87.in 2013-06-02 17:39:35.000000000 +0200 +*************** +*** 77,83 **** + :$put =py3eval('repr(''1'' in d)') + :$put =py3eval('repr(list(iter(d)))') + :$put =string(d) +! :$put =py3eval('repr(d.popitem(''0''))') + :$put =py3eval('repr(d.get(''0''))') + :$put =py3eval('repr(list(iter(d)))') + :" +--- 77,83 ---- + :$put =py3eval('repr(''1'' in d)') + :$put =py3eval('repr(list(iter(d)))') + :$put =string(d) +! :$put =py3eval('repr(d.popitem())') + :$put =py3eval('repr(d.get(''0''))') + :$put =py3eval('repr(list(iter(d)))') + :" +*************** +*** 220,226 **** + em('d[b"a\\0b"]=1') + + em('d.pop("abc")') +! em('d.popitem("abc")') + EOF + :$put =messages + :unlet messages +--- 220,226 ---- + em('d[b"a\\0b"]=1') + + em('d.pop("abc")') +! em('d.popitem()') + EOF + :$put =messages + :unlet messages +*** ../vim-7.3.1095/src/testdir/test87.ok 2013-06-01 20:32:09.000000000 +0200 +--- src/testdir/test87.ok 2013-06-02 17:39:35.000000000 +0200 +*************** +*** 26,32 **** + False + [b'0'] + {'0': -1} +! (b'', -1) + None + [] + [0, 1, 2, 3] +--- 26,32 ---- + False + [b'0'] + {'0': -1} +! (b'0', -1) + None + [] + [0, 1, 2, 3] +*************** +*** 663,669 **** + d.update((("a", FailingMappingKey()),)):(, NotImplementedError()) + <<< Finished + >> DictionaryPopItem +! d.popitem(1, 2):(, TypeError('function takes exactly 1 argument (2 given)',)) + >> DictionaryHasKey + d.has_key():(, TypeError('function takes exactly 1 argument (0 given)',)) + > List +--- 663,669 ---- + d.update((("a", FailingMappingKey()),)):(, NotImplementedError()) + <<< Finished + >> DictionaryPopItem +! d.popitem(1, 2):(, TypeError('popitem() takes no arguments (2 given)',)) + >> DictionaryHasKey + d.has_key():(, TypeError('function takes exactly 1 argument (0 given)',)) + > List +*** ../vim-7.3.1095/src/version.c 2013-06-02 16:40:44.000000000 +0200 +--- src/version.c 2013-06-02 17:40:20.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1096, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +44. Your friends no longer send you e-mail...they just log on to your IRC + channel. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d4747778c7c549e05f6347dfed8f9d26998b9b04 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:53 +0200 Subject: [PATCH 0988/3340] - patchlevel 1097 --- 7.3.1097 | 81 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 7.3.1097 diff --git a/7.3.1097 b/7.3.1097 new file mode 100644 index 00000000..5ded419a --- /dev/null +++ b/7.3.1097 @@ -0,0 +1,81 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1097 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1097 +Problem: Python: a few recently added items are not documented. +Solution: Update the documentation. (ZyX) +Files: runtime/doc/if_pyth.txt + + +*** ../vim-7.3.1096/runtime/doc/if_pyth.txt 2013-06-02 17:41:50.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-06-02 17:44:29.000000000 +0200 +*************** +*** 176,181 **** +--- 176,185 ---- + |python-bindeval-objects|. These python objects let you modify (|List| + or |Dictionary|) or call (|Funcref|) vim objects. + ++ vim.strwidth(str) *python-strwidth* ++ Like |strwidth()|: returns number of display cells str occupies, tab ++ is counted as one cell. ++ + Error object of the "vim" module + + vim.error *python-error* +*************** +*** 329,334 **** +--- 333,340 ---- + |BufFilePost| autocommands are launched. + b.number Buffer number. Can be used as |python-buffers| key. + Read-only. ++ b.valid True or False. Buffer object becames invalid when ++ corresponding buffer is wiped out. + + The buffer object methods are: + b.append(str) Append a line to the buffer +*************** +*** 433,438 **** +--- 439,446 ---- + row, col (read-only) On-screen window position in display cells. + First position is zero. + tabpage (read-only) Window tab page. ++ valid (read-write) True or False. Window object becames invalid ++ when corresponding window is closed. + + The height attribute is writable only if the screen is split horizontally. + The width attribute is writable only if the screen is split vertically. +*************** +*** 456,461 **** +--- 464,471 ---- + windows Like |python-windows|, but for current tab page. + vars The tab page |t:| variables. + window Current tabpage window. ++ valid True or False. Tab page object becames invalid when ++ corresponding tab page is closed. + + TabPage object type is available using "TabPage" attribute of vim module. + +*** ../vim-7.3.1096/src/version.c 2013-06-02 17:41:50.000000000 +0200 +--- src/version.c 2013-06-02 17:44:06.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1097, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +45. You buy a Captain Kirk chair with a built-in keyboard and mouse. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ccf9ce28ba63f3f383dbdc86d63543ec35b0c4de Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:54 +0200 Subject: [PATCH 0989/3340] - patchlevel 1098 --- 7.3.1098 | 103 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 103 insertions(+) create mode 100644 7.3.1098 diff --git a/7.3.1098 b/7.3.1098 new file mode 100644 index 00000000..f0f4548b --- /dev/null +++ b/7.3.1098 @@ -0,0 +1,103 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1098 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1098 +Problem: Python: Possible memory leaks +Solution: Add Py_XDECREF() calls. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1097/src/if_py_both.h 2013-06-02 17:41:50.000000000 +0200 +--- src/if_py_both.h 2013-06-02 18:01:56.000000000 +0200 +*************** +*** 1017,1022 **** +--- 1017,1023 ---- + if (*key == NUL) + { + RAISE_NO_EMPTY_KEYS; ++ Py_XDECREF(todecref); + return NULL; + } + +*************** +*** 1160,1165 **** +--- 1161,1167 ---- + + if (!(key = StringToChars(keyObject, &todecref))) + return -1; ++ + if (*key == NUL) + { + RAISE_NO_EMPTY_KEYS; +*************** +*** 2216,2224 **** +--- 2218,2228 ---- + + if (!(key = StringToChars(keyObject, &todecref))) + return NULL; ++ + if (*key == NUL) + { + RAISE_NO_EMPTY_KEYS; ++ Py_XDECREF(todecref); + return NULL; + } + +*************** +*** 2349,2357 **** +--- 2353,2363 ---- + + if (!(key = StringToChars(keyObject, &todecref))) + return -1; ++ + if (*key == NUL) + { + RAISE_NO_EMPTY_KEYS; ++ Py_XDECREF(todecref); + return -1; + } + +*************** +*** 4568,4573 **** +--- 4574,4580 ---- + dict_unref(dict); + return -1; + } ++ + if (*key == NUL) + { + dict_unref(dict); +*************** +*** 4651,4656 **** +--- 4658,4664 ---- + dict_unref(dict); + return -1; + } ++ + if (*key == NUL) + { + Py_DECREF(keyObject); +*** ../vim-7.3.1097/src/version.c 2013-06-02 17:46:37.000000000 +0200 +--- src/version.c 2013-06-02 18:02:37.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1098, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +47. You are so familiar with the WWW that you find the search engines useless. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a30b22aba8bc3e26e07d7b2bc6613745d69e1891 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:54 +0200 Subject: [PATCH 0990/3340] - patchlevel 1099 --- 7.3.1099 | 505 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 505 insertions(+) create mode 100644 7.3.1099 diff --git a/7.3.1099 b/7.3.1099 new file mode 100644 index 00000000..90e7db37 --- /dev/null +++ b/7.3.1099 @@ -0,0 +1,505 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1099 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1099 +Problem: Python: Changing directory with os.chdir() causes problems for + Vim's notion of directories. +Solution: Add vim.chdir() and vim.fchdir(). (ZyX) +Files: runtime/doc/if_pyth.txt, src/ex_docmd.c, src/if_py_both.h, + src/if_python3.c, src/if_python.c, src/proto/ex_docmd.pro, + src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.1098/runtime/doc/if_pyth.txt 2013-06-02 17:46:37.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-06-02 18:11:13.000000000 +0200 +*************** +*** 180,185 **** +--- 180,192 ---- + Like |strwidth()|: returns number of display cells str occupies, tab + is counted as one cell. + ++ vim.chdir(*args, **kwargs) *python-chdir* ++ vim.fchdir(*args, **kwargs) *python-fchdir* ++ Run os.chdir or os.fchdir, then all appropriate vim stuff. ++ Note: you should not use these functions directly, use os.chdir and ++ os.fchdir instead. Behavior of vim.fchdir is undefined in case ++ os.fchdir does not exist. ++ + Error object of the "vim" module + + vim.error *python-error* +*** ../vim-7.3.1098/src/ex_docmd.c 2013-05-17 16:39:59.000000000 +0200 +--- src/ex_docmd.c 2013-06-02 18:20:05.000000000 +0200 +*************** +*** 8182,8187 **** +--- 8182,8218 ---- + } + #endif + ++ /* ++ * Deal with the side effects of changing the current directory. ++ * When "local" is TRUE then this was after an ":lcd" command. ++ */ ++ void ++ post_chdir(local) ++ int local; ++ { ++ vim_free(curwin->w_localdir); ++ if (local) ++ { ++ /* If still in global directory, need to remember current ++ * directory as global directory. */ ++ if (globaldir == NULL && prev_dir != NULL) ++ globaldir = vim_strsave(prev_dir); ++ /* Remember this local directory for the window. */ ++ if (mch_dirname(NameBuff, MAXPATHL) == OK) ++ curwin->w_localdir = vim_strsave(NameBuff); ++ } ++ else ++ { ++ /* We are now in the global directory, no need to remember its ++ * name. */ ++ vim_free(globaldir); ++ globaldir = NULL; ++ curwin->w_localdir = NULL; ++ } ++ ++ shorten_fnames(TRUE); ++ } ++ + + /* + * ":cd", ":lcd", ":chdir" and ":lchdir". +*************** +*** 8253,8279 **** + EMSG(_(e_failed)); + else + { +! vim_free(curwin->w_localdir); +! if (eap->cmdidx == CMD_lcd || eap->cmdidx == CMD_lchdir) +! { +! /* If still in global directory, need to remember current +! * directory as global directory. */ +! if (globaldir == NULL && prev_dir != NULL) +! globaldir = vim_strsave(prev_dir); +! /* Remember this local directory for the window. */ +! if (mch_dirname(NameBuff, MAXPATHL) == OK) +! curwin->w_localdir = vim_strsave(NameBuff); +! } +! else +! { +! /* We are now in the global directory, no need to remember its +! * name. */ +! vim_free(globaldir); +! globaldir = NULL; +! curwin->w_localdir = NULL; +! } +! +! shorten_fnames(TRUE); + + /* Echo the new current directory if the command was typed. */ + if (KeyTyped || p_verbose >= 5) +--- 8284,8290 ---- + EMSG(_(e_failed)); + else + { +! post_chdir(eap->cmdidx == CMD_lcd || eap->cmdidx == CMD_lchdir); + + /* Echo the new current directory if the command was typed. */ + if (KeyTyped || p_verbose >= 5) +*** ../vim-7.3.1098/src/if_py_both.h 2013-06-02 18:07:33.000000000 +0200 +--- src/if_py_both.h 2013-06-02 18:11:13.000000000 +0200 +*************** +*** 52,57 **** +--- 52,61 ---- + + static PyObject *globals; + ++ static PyObject *py_chdir; ++ static PyObject *py_fchdir; ++ static PyObject *py_getcwd; ++ + /* + * obtain a lock on the Vim data structures + */ +*************** +*** 706,722 **** + ); + } + + /* + * Vim module - Definitions + */ + + static struct PyMethodDef VimMethods[] = { +! /* name, function, calling, documentation */ +! {"command", VimCommand, METH_VARARGS, "Execute a Vim ex-mode command" }, +! {"eval", VimEval, METH_VARARGS, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, METH_VARARGS, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, METH_VARARGS, "Screen string width, counts as having width 1"}, +! { NULL, NULL, 0, NULL } + }; + + /* +--- 710,793 ---- + ); + } + ++ static PyObject * ++ _VimChdir(PyObject *_chdir, PyObject *args, PyObject *kwargs) ++ { ++ PyObject *r; ++ PyObject *newwd; ++ PyObject *todecref; ++ char_u *new_dir; ++ ++ if (!(r = PyObject_Call(_chdir, args, kwargs))) ++ return NULL; ++ ++ if (!(newwd = PyObject_CallFunctionObjArgs(py_getcwd, NULL))) ++ { ++ Py_DECREF(r); ++ return NULL; ++ } ++ ++ if (!(new_dir = StringToChars(newwd, &todecref))) ++ { ++ Py_DECREF(r); ++ Py_DECREF(newwd); ++ return NULL; ++ } ++ ++ VimTryStart(); ++ ++ if (vim_chdir(new_dir)) ++ { ++ Py_DECREF(r); ++ Py_DECREF(newwd); ++ Py_XDECREF(todecref); ++ ++ if (VimTryEnd()) ++ return NULL; ++ ++ PyErr_SetVim(_("failed to change directory")); ++ return NULL; ++ } ++ ++ Py_DECREF(newwd); ++ Py_XDECREF(todecref); ++ ++ post_chdir(FALSE); ++ ++ if (VimTryEnd()) ++ { ++ Py_DECREF(r); ++ return NULL; ++ } ++ ++ return r; ++ } ++ ++ static PyObject * ++ VimChdir(PyObject *self UNUSED, PyObject *args, PyObject *kwargs) ++ { ++ return _VimChdir(py_chdir, args, kwargs); ++ } ++ ++ static PyObject * ++ VimFchdir(PyObject *self UNUSED, PyObject *args, PyObject *kwargs) ++ { ++ return _VimChdir(py_fchdir, args, kwargs); ++ } ++ + /* + * Vim module - Definitions + */ + + static struct PyMethodDef VimMethods[] = { +! /* name, function, calling, documentation */ +! {"command", VimCommand, METH_VARARGS, "Execute a Vim ex-mode command" }, +! {"eval", VimEval, METH_VARARGS, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, METH_VARARGS, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, METH_VARARGS, "Screen string width, counts as having width 1"}, +! {"chdir", (PyCFunction)VimChdir, METH_VARARGS|METH_KEYWORDS, "Change directory"}, +! {"fchdir", (PyCFunction)VimFchdir, METH_VARARGS|METH_KEYWORDS, "Change directory"}, +! { NULL, NULL, 0, NULL } + }; + + /* +*************** +*** 5274,5279 **** +--- 5345,5351 ---- + }; + + typedef int (*object_adder)(PyObject *, const char *, PyObject *); ++ typedef PyObject *(*attr_getter)(PyObject *, const char *); + + #define ADD_OBJECT(m, name, obj) \ + if (add_object(m, name, obj)) \ +*************** +*** 5288,5296 **** + } + + static int +! populate_module(PyObject *m, object_adder add_object) + { + int i; + + for (i = 0; i < (int)(sizeof(numeric_constants) + / sizeof(struct numeric_constant)); +--- 5360,5369 ---- + } + + static int +! populate_module(PyObject *m, object_adder add_object, attr_getter get_attr) + { + int i; ++ PyObject *os; + + for (i = 0; i < (int)(sizeof(numeric_constants) + / sizeof(struct numeric_constant)); +*************** +*** 5317,5321 **** +--- 5390,5416 ---- + ADD_CHECKED_OBJECT(m, "vvars", NEW_DICTIONARY(&vimvardict)); + ADD_CHECKED_OBJECT(m, "options", + OptionsNew(SREQ_GLOBAL, NULL, dummy_check, NULL)); ++ ++ if (!(os = PyImport_ImportModule("os"))) ++ return -1; ++ ADD_OBJECT(m, "os", os); ++ ++ if (!(py_getcwd = PyObject_GetAttrString(os, "getcwd"))) ++ return -1; ++ ADD_OBJECT(m, "_getcwd", py_getcwd) ++ ++ if (!(py_chdir = PyObject_GetAttrString(os, "chdir"))) ++ return -1; ++ ADD_OBJECT(m, "_chdir", py_chdir); ++ if (PyObject_SetAttrString(os, "chdir", get_attr(m, "chdir"))) ++ return -1; ++ ++ if ((py_fchdir = PyObject_GetAttrString(os, "fchdir"))) ++ { ++ ADD_OBJECT(m, "_fchdir", py_fchdir); ++ if (PyObject_SetAttrString(os, "fchdir", get_attr(m, "fchdir"))) ++ return -1; ++ } ++ + return 0; + } +*** ../vim-7.3.1098/src/if_python3.c 2013-05-30 13:22:07.000000000 +0200 +--- src/if_python3.c 2013-06-02 18:14:51.000000000 +0200 +*************** +*** 174,179 **** +--- 174,180 ---- + # define PyObject_HasAttrString py3_PyObject_HasAttrString + # define PyObject_SetAttrString py3_PyObject_SetAttrString + # define PyObject_CallFunctionObjArgs py3_PyObject_CallFunctionObjArgs ++ # define PyObject_Call py3_PyObject_Call + # define PyEval_GetLocals py3_PyEval_GetLocals + # define PyEval_GetGlobals py3_PyEval_GetGlobals + # define PySys_SetObject py3_PySys_SetObject +*************** +*** 290,295 **** +--- 291,297 ---- + static int (*py3_PyObject_HasAttrString)(PyObject *, const char *); + static PyObject* (*py3_PyObject_SetAttrString)(PyObject *, const char *, PyObject *); + static PyObject* (*py3_PyObject_CallFunctionObjArgs)(PyObject *, ...); ++ static PyObject* (*py3_PyObject_Call)(PyObject *, PyObject *, PyObject *); + static PyObject* (*py3_PyEval_GetGlobals)(); + static PyObject* (*py3_PyEval_GetLocals)(); + static PyObject* (*py3_PyList_GetItem)(PyObject *, Py_ssize_t); +*************** +*** 446,451 **** +--- 448,454 ---- + {"PyObject_HasAttrString", (PYTHON_PROC*)&py3_PyObject_HasAttrString}, + {"PyObject_SetAttrString", (PYTHON_PROC*)&py3_PyObject_SetAttrString}, + {"PyObject_CallFunctionObjArgs", (PYTHON_PROC*)&py3_PyObject_CallFunctionObjArgs}, ++ {"PyObject_Call", (PYTHON_PROC*)&py3_PyObject_Call}, + {"PyEval_GetGlobals", (PYTHON_PROC*)&py3_PyEval_GetGlobals}, + {"PyEval_GetLocals", (PYTHON_PROC*)&py3_PyEval_GetLocals}, + {"PyList_GetItem", (PYTHON_PROC*)&py3_PyList_GetItem}, +*************** +*** 1600,1606 **** + if (mod == NULL) + return NULL; + +! if (populate_module(mod, PyModule_AddObject)) + return NULL; + + return mod; +--- 1603,1609 ---- + if (mod == NULL) + return NULL; + +! if (populate_module(mod, PyModule_AddObject, PyObject_GetAttrString)) + return NULL; + + return mod; +*** ../vim-7.3.1098/src/if_python.c 2013-05-30 15:38:20.000000000 +0200 +--- src/if_python.c 2013-06-02 18:14:46.000000000 +0200 +*************** +*** 213,218 **** +--- 213,219 ---- + # define PyObject_HasAttrString dll_PyObject_HasAttrString + # define PyObject_SetAttrString dll_PyObject_SetAttrString + # define PyObject_CallFunctionObjArgs dll_PyObject_CallFunctionObjArgs ++ # define PyObject_Call dll_PyObject_Call + # define PyString_AsString dll_PyString_AsString + # define PyString_AsStringAndSize dll_PyString_AsStringAndSize + # define PyString_FromString dll_PyString_FromString +*************** +*** 346,351 **** +--- 347,353 ---- + static int (*dll_PyObject_HasAttrString)(PyObject *, const char *); + static PyObject* (*dll_PyObject_SetAttrString)(PyObject *, const char *, PyObject *); + static PyObject* (*dll_PyObject_CallFunctionObjArgs)(PyObject *, ...); ++ static PyObject* (*dll_PyObject_Call)(PyObject *, PyObject *, PyObject *); + static char*(*dll_PyString_AsString)(PyObject *); + static int(*dll_PyString_AsStringAndSize)(PyObject *, char **, int *); + static PyObject*(*dll_PyString_FromString)(const char *); +*************** +*** 510,515 **** +--- 512,518 ---- + {"PyObject_HasAttrString", (PYTHON_PROC*)&dll_PyObject_HasAttrString}, + {"PyObject_SetAttrString", (PYTHON_PROC*)&dll_PyObject_SetAttrString}, + {"PyObject_CallFunctionObjArgs", (PYTHON_PROC*)&dll_PyObject_CallFunctionObjArgs}, ++ {"PyObject_Call", (PYTHON_PROC*)&dll_PyObject_Call}, + {"PyString_AsString", (PYTHON_PROC*)&dll_PyString_AsString}, + {"PyString_AsStringAndSize", (PYTHON_PROC*)&dll_PyString_AsStringAndSize}, + {"PyString_FromString", (PYTHON_PROC*)&dll_PyString_FromString}, +*************** +*** 1374,1383 **** + /* Set sys.argv[] to avoid a crash in warn(). */ + PySys_SetArgv(1, argv); + +! mod = Py_InitModule4("vim", VimMethods, (char *)NULL, (PyObject *)NULL, PYTHON_API_VERSION); + dict = PyModule_GetDict(mod); + +! return populate_module(dict, add_object); + } + + /************************************************************************* +--- 1377,1387 ---- + /* Set sys.argv[] to avoid a crash in warn(). */ + PySys_SetArgv(1, argv); + +! mod = Py_InitModule4("vim", VimMethods, (char *)NULL, (PyObject *)NULL, +! PYTHON_API_VERSION); + dict = PyModule_GetDict(mod); + +! return populate_module(dict, add_object, PyDict_GetItemString); + } + + /************************************************************************* +*** ../vim-7.3.1098/src/proto/ex_docmd.pro 2012-02-04 21:57:44.000000000 +0100 +--- src/proto/ex_docmd.pro 2013-06-02 18:11:13.000000000 +0200 +*************** +*** 53,56 **** +--- 53,57 ---- + int put_line __ARGS((FILE *fd, char *s)); + void dialog_msg __ARGS((char_u *buff, char *format, char_u *fname)); + char_u *get_behave_arg __ARGS((expand_T *xp, int idx)); ++ void post_chdir __ARGS((int local)); + /* vim: set ft=c : */ +*** ../vim-7.3.1098/src/testdir/test86.in 2013-06-02 17:41:50.000000000 +0200 +--- src/testdir/test86.in 2013-06-02 18:11:13.000000000 +0200 +*************** +*** 788,793 **** +--- 788,807 ---- + :$put =string(pyeval('dl2')) + :$put =string(pyeval('df(2)')) + :" ++ :" Test chdir ++ py << EOF ++ import os ++ fnamemodify = vim.Function('fnamemodify') ++ cb.append(fnamemodify('.', ':p:h:t')) ++ cb.append(vim.eval('@%')) ++ os.chdir('..') ++ cb.append(fnamemodify('.', ':p:h:t')) ++ cb.append(vim.eval('@%').replace(os.path.sep, '/')) ++ os.chdir('testdir') ++ cb.append(fnamemodify('.', ':p:h:t')) ++ cb.append(vim.eval('@%')) ++ EOF ++ :" + :" Test errors + :fun F() dict + :endfun +*** ../vim-7.3.1098/src/testdir/test86.ok 2013-06-02 17:41:50.000000000 +0200 +--- src/testdir/test86.ok 2013-06-02 18:11:13.000000000 +0200 +*************** +*** 429,434 **** +--- 429,440 ---- + ['a', 'b', 'c'] + [2, 2] + [2, 2] ++ testdir ++ test86.in ++ src ++ testdir/test86.in ++ testdir ++ test86.in + > Output + >> OutputSetattr + del sys.stdout.softspace:(, AttributeError("can't delete OutputObject attributes",)) +*** ../vim-7.3.1098/src/testdir/test87.in 2013-06-02 17:41:50.000000000 +0200 +--- src/testdir/test87.in 2013-06-02 18:11:13.000000000 +0200 +*************** +*** 748,753 **** +--- 748,767 ---- + :$put =string(py3eval('dl2')) + :$put =string(py3eval('df(2)')) + :" ++ :" Test chdir ++ py3 << EOF ++ import os ++ fnamemodify = vim.Function('fnamemodify') ++ cb.append(str(fnamemodify('.', ':p:h:t'))) ++ cb.append(vim.eval('@%')) ++ os.chdir('..') ++ cb.append(str(fnamemodify('.', ':p:h:t'))) ++ cb.append(vim.eval('@%').replace(os.path.sep, '/')) ++ os.chdir('testdir') ++ cb.append(str(fnamemodify('.', ':p:h:t'))) ++ cb.append(vim.eval('@%')) ++ EOF ++ :" + :" Test errors + :fun F() dict + :endfun +*** ../vim-7.3.1098/src/testdir/test87.ok 2013-06-02 17:41:50.000000000 +0200 +--- src/testdir/test87.ok 2013-06-02 18:11:13.000000000 +0200 +*************** +*** 418,423 **** +--- 418,429 ---- + ['a', 'b', 'c'] + [2, 2] + [2, 2] ++ b'testdir' ++ test87.in ++ b'src' ++ testdir/test87.in ++ b'testdir' ++ test87.in + > Output + >> OutputSetattr + del sys.stdout.softspace:(, AttributeError("can't delete OutputObject attributes",)) +*** ../vim-7.3.1098/src/version.c 2013-06-02 18:07:33.000000000 +0200 +--- src/version.c 2013-06-02 18:12:58.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1099, + /**/ From 49d57fbc1a43e3f7b6e16b1cb32a54c21be918cf Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:55 +0200 Subject: [PATCH 0991/3340] - patchlevel 1100 --- 7.3.1100 | 595 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 595 insertions(+) create mode 100644 7.3.1100 diff --git a/7.3.1100 b/7.3.1100 new file mode 100644 index 00000000..15a556e5 --- /dev/null +++ b/7.3.1100 @@ -0,0 +1,595 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1100 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1100 +Problem: Python: a few more memory problems. +Solution: Add and remove Py_XDECREF(). (ZyX) +Files: src/if_py_both.h, src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.1099/src/if_py_both.h 2013-06-02 18:20:12.000000000 +0200 +--- src/if_py_both.h 2013-06-02 18:41:12.000000000 +0200 +*************** +*** 1236,1241 **** +--- 1236,1242 ---- + if (*key == NUL) + { + RAISE_NO_EMPTY_KEYS; ++ Py_XDECREF(todecref); + return -1; + } + +*************** +*** 1254,1264 **** +--- 1255,1269 ---- + hi = hash_find(&dict->dv_hashtab, di->di_key); + hash_remove(&dict->dv_hashtab, hi); + dictitem_free(di); ++ Py_XDECREF(todecref); + return 0; + } + + if (ConvertFromPyObject(valObject, &tv) == -1) ++ { ++ Py_XDECREF(todecref); + return -1; ++ } + + if (di == NULL) + { +*************** +*** 2505,2515 **** + PyObject *todecref; + + if ((val = StringToChars(valObject, &todecref))) +- { + r = set_option_value_for(key, 0, val, opt_flags, + self->opt_type, self->from); +- Py_XDECREF(todecref); +- } + else + r = -1; + } +--- 2510,2517 ---- +*** ../vim-7.3.1099/src/testdir/test86.in 2013-06-02 18:20:12.000000000 +0200 +--- src/testdir/test86.in 2013-06-02 18:42:24.000000000 +0200 +*************** +*** 867,872 **** +--- 867,873 ---- + return subexpr_test(expr, 'ConvertFromPyObject', ( + 'None', # Not conversible + '{"": 1}', # Empty key not allowed ++ '{u"": 1}', # Same, but with unicode object + 'FailingMapping()', # + 'FailingMappingKey()', # + )) +*** ../vim-7.3.1099/src/testdir/test86.ok 2013-06-02 18:20:12.000000000 +0200 +--- src/testdir/test86.ok 2013-06-02 18:44:49.000000000 +0200 +*************** +*** 503,508 **** +--- 503,509 ---- + >>> Testing ConvertFromPyObject using d["a"] = {"abc" : %s} + d["a"] = {"abc" : None}:(, TypeError('unable to convert to vim structure',)) + d["a"] = {"abc" : {"": 1}}:(, ValueError('empty keys are not allowed',)) ++ d["a"] = {"abc" : {u"": 1}}:(, ValueError('empty keys are not allowed',)) + d["a"] = {"abc" : FailingMapping()}:(, NotImplementedError()) + d["a"] = {"abc" : FailingMappingKey()}:(, NotImplementedError()) + <<< Finished +*************** +*** 528,533 **** +--- 529,535 ---- + >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abc" : %s}) + d["a"] = Mapping({"abc" : None}):(, TypeError('unable to convert to vim structure',)) + d["a"] = Mapping({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) ++ d["a"] = Mapping({"abc" : {u"": 1}}):(, ValueError('empty keys are not allowed',)) + d["a"] = Mapping({"abc" : FailingMapping()}):(, NotImplementedError()) + d["a"] = Mapping({"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished +*************** +*** 538,543 **** +--- 540,546 ---- + >>> Testing ConvertFromPyObject using d["a"] = %s + d["a"] = None:(, TypeError('unable to convert to vim structure',)) + d["a"] = {"": 1}:(, ValueError('empty keys are not allowed',)) ++ d["a"] = {u"": 1}:(, ValueError('empty keys are not allowed',)) + d["a"] = FailingMapping():(, NotImplementedError()) + d["a"] = FailingMappingKey():(, NotImplementedError()) + <<< Finished +*************** +*** 568,573 **** +--- 571,577 ---- + >>> Testing ConvertFromPyObject using d.update({"abc" : %s}) + d.update({"abc" : None}):(, TypeError('unable to convert to vim structure',)) + d.update({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) ++ d.update({"abc" : {u"": 1}}):(, ValueError('empty keys are not allowed',)) + d.update({"abc" : FailingMapping()}):(, NotImplementedError()) + d.update({"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished +*************** +*** 593,598 **** +--- 597,603 ---- + >>> Testing ConvertFromPyObject using d.update(Mapping({"abc" : %s})) + d.update(Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) + d.update(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) ++ d.update(Mapping({"abc" : {u"": 1}})):(, ValueError('empty keys are not allowed',)) + d.update(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) + d.update(Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished +*************** +*** 603,608 **** +--- 608,614 ---- + >>> Testing ConvertFromPyObject using d.update(%s) + d.update(None):(, TypeError("'NoneType' object is not iterable",)) + d.update({"": 1}):(, ValueError('empty keys are not allowed',)) ++ d.update({u"": 1}):(, ValueError('empty keys are not allowed',)) + d.update(FailingMapping()):(, NotImplementedError()) + d.update(FailingMappingKey()):(, NotImplementedError()) + <<< Finished +*************** +*** 633,638 **** +--- 639,645 ---- + >>> Testing ConvertFromPyObject using d.update((("a", {"abc" : %s}),)) + d.update((("a", {"abc" : None}),)):(, TypeError('unable to convert to vim structure',)) + d.update((("a", {"abc" : {"": 1}}),)):(, ValueError('empty keys are not allowed',)) ++ d.update((("a", {"abc" : {u"": 1}}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", {"abc" : FailingMapping()}),)):(, NotImplementedError()) + d.update((("a", {"abc" : FailingMappingKey()}),)):(, NotImplementedError()) + <<< Finished +*************** +*** 658,663 **** +--- 665,671 ---- + >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abc" : %s})),)) + d.update((("a", Mapping({"abc" : None})),)):(, TypeError('unable to convert to vim structure',)) + d.update((("a", Mapping({"abc" : {"": 1}})),)):(, ValueError('empty keys are not allowed',)) ++ d.update((("a", Mapping({"abc" : {u"": 1}})),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", Mapping({"abc" : FailingMapping()})),)):(, NotImplementedError()) + d.update((("a", Mapping({"abc" : FailingMappingKey()})),)):(, NotImplementedError()) + <<< Finished +*************** +*** 668,673 **** +--- 676,682 ---- + >>> Testing ConvertFromPyObject using d.update((("a", %s),)) + d.update((("a", None),)):(, TypeError('unable to convert to vim structure',)) + d.update((("a", {"": 1}),)):(, ValueError('empty keys are not allowed',)) ++ d.update((("a", {u"": 1}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", FailingMapping()),)):(, NotImplementedError()) + d.update((("a", FailingMappingKey()),)):(, NotImplementedError()) + <<< Finished +*************** +*** 701,706 **** +--- 710,716 ---- + >>> Testing ConvertFromPyObject using vim.List([{"abc" : %s}]) + vim.List([{"abc" : None}]):(, TypeError('unable to convert to vim structure',)) + vim.List([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) ++ vim.List([{"abc" : {u"": 1}}]):(, ValueError('empty keys are not allowed',)) + vim.List([{"abc" : FailingMapping()}]):(, NotImplementedError()) + vim.List([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) + <<< Finished +*************** +*** 726,731 **** +--- 736,742 ---- + >>> Testing ConvertFromPyObject using vim.List([Mapping({"abc" : %s})]) + vim.List([Mapping({"abc" : None})]):(, TypeError('unable to convert to vim structure',)) + vim.List([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) ++ vim.List([Mapping({"abc" : {u"": 1}})]):(, ValueError('empty keys are not allowed',)) + vim.List([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) + vim.List([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) + <<< Finished +*************** +*** 736,741 **** +--- 747,753 ---- + >>> Testing ConvertFromPyObject using vim.List([%s]) + vim.List([None]):(, TypeError('unable to convert to vim structure',)) + vim.List([{"": 1}]):(, ValueError('empty keys are not allowed',)) ++ vim.List([{u"": 1}]):(, ValueError('empty keys are not allowed',)) + vim.List([FailingMapping()]):(, NotImplementedError()) + vim.List([FailingMappingKey()]):(, NotImplementedError()) + <<< Finished +*************** +*** 768,773 **** +--- 780,786 ---- + >>> Testing ConvertFromPyObject using l[:] = [{"abc" : %s}] + l[:] = [{"abc" : None}]:(, TypeError('unable to convert to vim structure',)) + l[:] = [{"abc" : {"": 1}}]:(, ValueError('empty keys are not allowed',)) ++ l[:] = [{"abc" : {u"": 1}}]:(, ValueError('empty keys are not allowed',)) + l[:] = [{"abc" : FailingMapping()}]:(, NotImplementedError()) + l[:] = [{"abc" : FailingMappingKey()}]:(, NotImplementedError()) + <<< Finished +*************** +*** 793,798 **** +--- 806,812 ---- + >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abc" : %s})] + l[:] = [Mapping({"abc" : None})]:(, TypeError('unable to convert to vim structure',)) + l[:] = [Mapping({"abc" : {"": 1}})]:(, ValueError('empty keys are not allowed',)) ++ l[:] = [Mapping({"abc" : {u"": 1}})]:(, ValueError('empty keys are not allowed',)) + l[:] = [Mapping({"abc" : FailingMapping()})]:(, NotImplementedError()) + l[:] = [Mapping({"abc" : FailingMappingKey()})]:(, NotImplementedError()) + <<< Finished +*************** +*** 803,808 **** +--- 817,823 ---- + >>> Testing ConvertFromPyObject using l[:] = [%s] + l[:] = [None]:(, TypeError('unable to convert to vim structure',)) + l[:] = [{"": 1}]:(, ValueError('empty keys are not allowed',)) ++ l[:] = [{u"": 1}]:(, ValueError('empty keys are not allowed',)) + l[:] = [FailingMapping()]:(, NotImplementedError()) + l[:] = [FailingMappingKey()]:(, NotImplementedError()) + <<< Finished +*************** +*** 829,834 **** +--- 844,850 ---- + >>> Testing ConvertFromPyObject using l.extend([{"abc" : %s}]) + l.extend([{"abc" : None}]):(, TypeError('unable to convert to vim structure',)) + l.extend([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) ++ l.extend([{"abc" : {u"": 1}}]):(, ValueError('empty keys are not allowed',)) + l.extend([{"abc" : FailingMapping()}]):(, NotImplementedError()) + l.extend([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) + <<< Finished +*************** +*** 854,859 **** +--- 870,876 ---- + >>> Testing ConvertFromPyObject using l.extend([Mapping({"abc" : %s})]) + l.extend([Mapping({"abc" : None})]):(, TypeError('unable to convert to vim structure',)) + l.extend([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) ++ l.extend([Mapping({"abc" : {u"": 1}})]):(, ValueError('empty keys are not allowed',)) + l.extend([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) + l.extend([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) + <<< Finished +*************** +*** 864,869 **** +--- 881,887 ---- + >>> Testing ConvertFromPyObject using l.extend([%s]) + l.extend([None]):(, TypeError('unable to convert to vim structure',)) + l.extend([{"": 1}]):(, ValueError('empty keys are not allowed',)) ++ l.extend([{u"": 1}]):(, ValueError('empty keys are not allowed',)) + l.extend([FailingMapping()]):(, NotImplementedError()) + l.extend([FailingMappingKey()]):(, NotImplementedError()) + <<< Finished +*************** +*** 899,904 **** +--- 917,923 ---- + >>> Testing ConvertFromPyObject using f({"abc" : %s}) + f({"abc" : None}):(, TypeError('unable to convert to vim structure',)) + f({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) ++ f({"abc" : {u"": 1}}):(, ValueError('empty keys are not allowed',)) + f({"abc" : FailingMapping()}):(, NotImplementedError()) + f({"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished +*************** +*** 924,929 **** +--- 943,949 ---- + >>> Testing ConvertFromPyObject using f(Mapping({"abc" : %s})) + f(Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) + f(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) ++ f(Mapping({"abc" : {u"": 1}})):(, ValueError('empty keys are not allowed',)) + f(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) + f(Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished +*************** +*** 934,939 **** +--- 954,960 ---- + >>> Testing ConvertFromPyObject using f(%s) + f(None):(, TypeError('unable to convert to vim structure',)) + f({"": 1}):(, ValueError('empty keys are not allowed',)) ++ f({u"": 1}):(, ValueError('empty keys are not allowed',)) + f(FailingMapping()):(, NotImplementedError()) + f(FailingMappingKey()):(, NotImplementedError()) + <<< Finished +*************** +*** 959,964 **** +--- 980,986 ---- + >>> Testing ConvertFromPyObject using fd(self={"abc" : %s}) + fd(self={"abc" : None}):(, TypeError('unable to convert to vim structure',)) + fd(self={"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) ++ fd(self={"abc" : {u"": 1}}):(, ValueError('empty keys are not allowed',)) + fd(self={"abc" : FailingMapping()}):(, NotImplementedError()) + fd(self={"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished +*************** +*** 984,989 **** +--- 1006,1012 ---- + >>> Testing ConvertFromPyObject using fd(self=Mapping({"abc" : %s})) + fd(self=Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) + fd(self=Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) ++ fd(self=Mapping({"abc" : {u"": 1}})):(, ValueError('empty keys are not allowed',)) + fd(self=Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) + fd(self=Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished +*************** +*** 994,999 **** +--- 1017,1023 ---- + >>> Testing ConvertFromPyObject using fd(self=%s) + fd(self=None):(, TypeError('unable to convert object to vim dictionary',)) + fd(self={"": 1}):(, ValueError('empty keys are not allowed',)) ++ fd(self={u"": 1}):(, ValueError('empty keys are not allowed',)) + fd(self=FailingMapping()):(, NotImplementedError()) + fd(self=FailingMappingKey()):(, NotImplementedError()) + <<< Finished +*** ../vim-7.3.1099/src/testdir/test87.in 2013-06-02 18:20:12.000000000 +0200 +--- src/testdir/test87.in 2013-06-02 18:44:49.000000000 +0200 +*************** +*** 833,839 **** + iter_test(expr) + return subexpr_test(expr, 'ConvertFromPyObject', ( + 'None', # Not conversible +! '{"": 1}', # Empty key not allowed + 'FailingMapping()', # + 'FailingMappingKey()', # + )) +--- 833,840 ---- + iter_test(expr) + return subexpr_test(expr, 'ConvertFromPyObject', ( + 'None', # Not conversible +! '{b"": 1}', # Empty key not allowed +! '{"": 1}', # Same, but with unicode object + 'FailingMapping()', # + 'FailingMappingKey()', # + )) +*** ../vim-7.3.1099/src/testdir/test87.ok 2013-06-02 18:20:12.000000000 +0200 +--- src/testdir/test87.ok 2013-06-02 18:44:49.000000000 +0200 +*************** +*** 495,500 **** +--- 495,501 ---- + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = {"abc" : %s} + d["a"] = {"abc" : None}:(, TypeError('unable to convert to vim structure',)) ++ d["a"] = {"abc" : {b"": 1}}:(, ValueError('empty keys are not allowed',)) + d["a"] = {"abc" : {"": 1}}:(, ValueError('empty keys are not allowed',)) + d["a"] = {"abc" : FailingMapping()}:(, NotImplementedError()) + d["a"] = {"abc" : FailingMappingKey()}:(, NotImplementedError()) +*************** +*** 520,525 **** +--- 521,527 ---- + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abc" : %s}) + d["a"] = Mapping({"abc" : None}):(, TypeError('unable to convert to vim structure',)) ++ d["a"] = Mapping({"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + d["a"] = Mapping({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) + d["a"] = Mapping({"abc" : FailingMapping()}):(, NotImplementedError()) + d["a"] = Mapping({"abc" : FailingMappingKey()}):(, NotImplementedError()) +*************** +*** 530,535 **** +--- 532,538 ---- + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = %s + d["a"] = None:(, TypeError('unable to convert to vim structure',)) ++ d["a"] = {b"": 1}:(, ValueError('empty keys are not allowed',)) + d["a"] = {"": 1}:(, ValueError('empty keys are not allowed',)) + d["a"] = FailingMapping():(, NotImplementedError()) + d["a"] = FailingMappingKey():(, NotImplementedError()) +*************** +*** 564,569 **** +--- 567,573 ---- + <<< Finished + >>> Testing ConvertFromPyObject using d.update({"abc" : %s}) + d.update({"abc" : None}):(, TypeError('unable to convert to vim structure',)) ++ d.update({"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + d.update({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) + d.update({"abc" : FailingMapping()}):(, NotImplementedError()) + d.update({"abc" : FailingMappingKey()}):(, NotImplementedError()) +*************** +*** 589,594 **** +--- 593,599 ---- + <<< Finished + >>> Testing ConvertFromPyObject using d.update(Mapping({"abc" : %s})) + d.update(Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) ++ d.update(Mapping({"abc" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) + d.update(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) + d.update(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) + d.update(Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) +*************** +*** 599,604 **** +--- 604,610 ---- + <<< Finished + >>> Testing ConvertFromPyObject using d.update(%s) + d.update(None):(, TypeError("'NoneType' object is not iterable",)) ++ d.update({b"": 1}):(, ValueError('empty keys are not allowed',)) + d.update({"": 1}):(, ValueError('empty keys are not allowed',)) + d.update(FailingMapping()):(, NotImplementedError()) + d.update(FailingMappingKey()):(, NotImplementedError()) +*************** +*** 629,634 **** +--- 635,641 ---- + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", {"abc" : %s}),)) + d.update((("a", {"abc" : None}),)):(, TypeError('unable to convert to vim structure',)) ++ d.update((("a", {"abc" : {b"": 1}}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", {"abc" : {"": 1}}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", {"abc" : FailingMapping()}),)):(, NotImplementedError()) + d.update((("a", {"abc" : FailingMappingKey()}),)):(, NotImplementedError()) +*************** +*** 654,659 **** +--- 661,667 ---- + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abc" : %s})),)) + d.update((("a", Mapping({"abc" : None})),)):(, TypeError('unable to convert to vim structure',)) ++ d.update((("a", Mapping({"abc" : {b"": 1}})),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", Mapping({"abc" : {"": 1}})),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", Mapping({"abc" : FailingMapping()})),)):(, NotImplementedError()) + d.update((("a", Mapping({"abc" : FailingMappingKey()})),)):(, NotImplementedError()) +*************** +*** 664,669 **** +--- 672,678 ---- + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", %s),)) + d.update((("a", None),)):(, TypeError('unable to convert to vim structure',)) ++ d.update((("a", {b"": 1}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", {"": 1}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", FailingMapping()),)):(, NotImplementedError()) + d.update((("a", FailingMappingKey()),)):(, NotImplementedError()) +*************** +*** 701,706 **** +--- 710,716 ---- + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([{"abc" : %s}]) + vim.List([{"abc" : None}]):(, TypeError('unable to convert to vim structure',)) ++ vim.List([{"abc" : {b"": 1}}]):(, ValueError('empty keys are not allowed',)) + vim.List([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) + vim.List([{"abc" : FailingMapping()}]):(, NotImplementedError()) + vim.List([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) +*************** +*** 726,731 **** +--- 736,742 ---- + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([Mapping({"abc" : %s})]) + vim.List([Mapping({"abc" : None})]):(, TypeError('unable to convert to vim structure',)) ++ vim.List([Mapping({"abc" : {b"": 1}})]):(, ValueError('empty keys are not allowed',)) + vim.List([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) + vim.List([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) + vim.List([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) +*************** +*** 736,741 **** +--- 747,753 ---- + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([%s]) + vim.List([None]):(, TypeError('unable to convert to vim structure',)) ++ vim.List([{b"": 1}]):(, ValueError('empty keys are not allowed',)) + vim.List([{"": 1}]):(, ValueError('empty keys are not allowed',)) + vim.List([FailingMapping()]):(, NotImplementedError()) + vim.List([FailingMappingKey()]):(, NotImplementedError()) +*************** +*** 772,777 **** +--- 784,790 ---- + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [{"abc" : %s}] + l[:] = [{"abc" : None}]:(, TypeError('unable to convert to vim structure',)) ++ l[:] = [{"abc" : {b"": 1}}]:(, ValueError('empty keys are not allowed',)) + l[:] = [{"abc" : {"": 1}}]:(, ValueError('empty keys are not allowed',)) + l[:] = [{"abc" : FailingMapping()}]:(, NotImplementedError()) + l[:] = [{"abc" : FailingMappingKey()}]:(, NotImplementedError()) +*************** +*** 797,802 **** +--- 810,816 ---- + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abc" : %s})] + l[:] = [Mapping({"abc" : None})]:(, TypeError('unable to convert to vim structure',)) ++ l[:] = [Mapping({"abc" : {b"": 1}})]:(, ValueError('empty keys are not allowed',)) + l[:] = [Mapping({"abc" : {"": 1}})]:(, ValueError('empty keys are not allowed',)) + l[:] = [Mapping({"abc" : FailingMapping()})]:(, NotImplementedError()) + l[:] = [Mapping({"abc" : FailingMappingKey()})]:(, NotImplementedError()) +*************** +*** 807,812 **** +--- 821,827 ---- + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [%s] + l[:] = [None]:(, TypeError('unable to convert to vim structure',)) ++ l[:] = [{b"": 1}]:(, ValueError('empty keys are not allowed',)) + l[:] = [{"": 1}]:(, ValueError('empty keys are not allowed',)) + l[:] = [FailingMapping()]:(, NotImplementedError()) + l[:] = [FailingMappingKey()]:(, NotImplementedError()) +*************** +*** 837,842 **** +--- 852,858 ---- + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([{"abc" : %s}]) + l.extend([{"abc" : None}]):(, TypeError('unable to convert to vim structure',)) ++ l.extend([{"abc" : {b"": 1}}]):(, ValueError('empty keys are not allowed',)) + l.extend([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) + l.extend([{"abc" : FailingMapping()}]):(, NotImplementedError()) + l.extend([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) +*************** +*** 862,867 **** +--- 878,884 ---- + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([Mapping({"abc" : %s})]) + l.extend([Mapping({"abc" : None})]):(, TypeError('unable to convert to vim structure',)) ++ l.extend([Mapping({"abc" : {b"": 1}})]):(, ValueError('empty keys are not allowed',)) + l.extend([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) + l.extend([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) + l.extend([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) +*************** +*** 872,877 **** +--- 889,895 ---- + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([%s]) + l.extend([None]):(, TypeError('unable to convert to vim structure',)) ++ l.extend([{b"": 1}]):(, ValueError('empty keys are not allowed',)) + l.extend([{"": 1}]):(, ValueError('empty keys are not allowed',)) + l.extend([FailingMapping()]):(, NotImplementedError()) + l.extend([FailingMappingKey()]):(, NotImplementedError()) +*************** +*** 907,912 **** +--- 925,931 ---- + <<< Finished + >>> Testing ConvertFromPyObject using f({"abc" : %s}) + f({"abc" : None}):(, TypeError('unable to convert to vim structure',)) ++ f({"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + f({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) + f({"abc" : FailingMapping()}):(, NotImplementedError()) + f({"abc" : FailingMappingKey()}):(, NotImplementedError()) +*************** +*** 932,937 **** +--- 951,957 ---- + <<< Finished + >>> Testing ConvertFromPyObject using f(Mapping({"abc" : %s})) + f(Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) ++ f(Mapping({"abc" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) + f(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) + f(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) + f(Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) +*************** +*** 942,947 **** +--- 962,968 ---- + <<< Finished + >>> Testing ConvertFromPyObject using f(%s) + f(None):(, TypeError('unable to convert to vim structure',)) ++ f({b"": 1}):(, ValueError('empty keys are not allowed',)) + f({"": 1}):(, ValueError('empty keys are not allowed',)) + f(FailingMapping()):(, NotImplementedError()) + f(FailingMappingKey()):(, NotImplementedError()) +*************** +*** 967,972 **** +--- 988,994 ---- + <<< Finished + >>> Testing ConvertFromPyObject using fd(self={"abc" : %s}) + fd(self={"abc" : None}):(, TypeError('unable to convert to vim structure',)) ++ fd(self={"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + fd(self={"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) + fd(self={"abc" : FailingMapping()}):(, NotImplementedError()) + fd(self={"abc" : FailingMappingKey()}):(, NotImplementedError()) +*************** +*** 992,997 **** +--- 1014,1020 ---- + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=Mapping({"abc" : %s})) + fd(self=Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) ++ fd(self=Mapping({"abc" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) + fd(self=Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) + fd(self=Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) + fd(self=Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) +*************** +*** 1002,1007 **** +--- 1025,1031 ---- + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=%s) + fd(self=None):(, TypeError('unable to convert object to vim dictionary',)) ++ fd(self={b"": 1}):(, ValueError('empty keys are not allowed',)) + fd(self={"": 1}):(, ValueError('empty keys are not allowed',)) + fd(self=FailingMapping()):(, NotImplementedError()) + fd(self=FailingMappingKey()):(, NotImplementedError()) +*** ../vim-7.3.1099/src/version.c 2013-06-02 18:20:12.000000000 +0200 +--- src/version.c 2013-06-02 18:53:59.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1100, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +48. You get a tatoo that says "This body best viewed with Netscape 3.1 or + higher." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c7c6fe459dae917178a091e17e3ff8bd76650101 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:56 +0200 Subject: [PATCH 0992/3340] - patchlevel 1101 --- 7.3.1101 | 243 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 243 insertions(+) create mode 100644 7.3.1101 diff --git a/7.3.1101 b/7.3.1101 new file mode 100644 index 00000000..b6f0c583 --- /dev/null +++ b/7.3.1101 @@ -0,0 +1,243 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1101 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1101 +Problem: Configure doesn't find Python 3 on Ubuntu 13.04. +Solution: First try distutils.sysconfig. Also fix some indents. (Ken + Takata) +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.1100/src/configure.in 2013-05-15 14:51:31.000000000 +0200 +--- src/configure.in 2013-06-02 19:02:31.000000000 +0200 +*************** +*** 899,912 **** + AC_CACHE_CHECK(Python's configuration directory,vi_cv_path_python_conf, + [ + vi_cv_path_python_conf= +! for path in "${vi_cv_path_python_pfx}" "${vi_cv_path_python_epfx}"; do +! for subdir in lib64 lib share; do +! d="${path}/${subdir}/python${vi_cv_var_python_version}/config" +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python_conf="$d" +! fi + done +! done + ]) + + PYTHON_CONFDIR="${vi_cv_path_python_conf}" +--- 899,917 ---- + AC_CACHE_CHECK(Python's configuration directory,vi_cv_path_python_conf, + [ + vi_cv_path_python_conf= +! d=`${vi_cv_path_python} -c "import distutils.sysconfig; print distutils.sysconfig.get_config_var('LIBPL')"` +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python_conf="$d" +! else +! for path in "${vi_cv_path_python_pfx}" "${vi_cv_path_python_epfx}"; do +! for subdir in lib64 lib share; do +! d="${path}/${subdir}/python${vi_cv_var_python_version}/config" +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python_conf="$d" +! fi +! done + done +! fi + ]) + + PYTHON_CONFDIR="${vi_cv_path_python_conf}" +*************** +*** 1097,1110 **** + if test "${vi_cv_var_python3_abiflags}" != ""; then + config_dir="${config_dir}-${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}" + fi +! for path in "${vi_cv_path_python3_pfx}" "${vi_cv_path_python3_epfx}"; do +! for subdir in lib64 lib share; do +! d="${path}/${subdir}/python${vi_cv_var_python3_version}/${config_dir}" +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python3_conf="$d" +! fi + done +! done + ]) + + PYTHON3_CONFDIR="${vi_cv_path_python3_conf}" +--- 1102,1120 ---- + if test "${vi_cv_var_python3_abiflags}" != ""; then + config_dir="${config_dir}-${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}" + fi +! d=`${vi_cv_path_python3} -c "import distutils.sysconfig; print(distutils.sysconfig.get_config_var('LIBPL'))"` +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python3_conf="$d" +! else +! for path in "${vi_cv_path_python3_pfx}" "${vi_cv_path_python3_epfx}"; do +! for subdir in lib64 lib share; do +! d="${path}/${subdir}/python${vi_cv_var_python3_version}/${config_dir}" +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python3_conf="$d" +! fi +! done + done +! fi + ]) + + PYTHON3_CONFDIR="${vi_cv_path_python3_conf}" +*************** +*** 1498,1511 **** + fi + librubyarg=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG[['LIBRUBYARG']])"` + librubya=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG[['LIBRUBY_A']])"` +! rubylibdir=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG[['libdir']])"` + if test -f "$rubylibdir/$librubya"; then + librubyarg="$librubyarg" +! RUBY_LIBS="$RUBY_LIBS -L$rubylibdir" +! elif test "$librubyarg" = "libruby.a"; then +! dnl required on Mac OS 10.3 where libruby.a doesn't exist +! librubyarg="-lruby" +! RUBY_LIBS="$RUBY_LIBS -L$rubylibdir" + fi + + if test "X$librubyarg" != "X"; then +--- 1508,1521 ---- + fi + librubyarg=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG[['LIBRUBYARG']])"` + librubya=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG[['LIBRUBY_A']])"` +! rubylibdir=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG[['libdir']])"` + if test -f "$rubylibdir/$librubya"; then + librubyarg="$librubyarg" +! RUBY_LIBS="$RUBY_LIBS -L$rubylibdir" +! elif test "$librubyarg" = "libruby.a"; then +! dnl required on Mac OS 10.3 where libruby.a doesn't exist +! librubyarg="-lruby" +! RUBY_LIBS="$RUBY_LIBS -L$rubylibdir" + fi + + if test "X$librubyarg" != "X"; then +*** ../vim-7.3.1100/src/auto/configure 2013-05-15 14:51:31.000000000 +0200 +--- src/auto/configure 2013-06-02 19:03:17.000000000 +0200 +*************** +*** 5347,5360 **** + else + + vi_cv_path_python_conf= +! for path in "${vi_cv_path_python_pfx}" "${vi_cv_path_python_epfx}"; do +! for subdir in lib64 lib share; do +! d="${path}/${subdir}/python${vi_cv_var_python_version}/config" +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python_conf="$d" +! fi + done +! done + + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python_conf" >&5 +--- 5347,5365 ---- + else + + vi_cv_path_python_conf= +! d=`${vi_cv_path_python} -c "import distutils.sysconfig; print distutils.sysconfig.get_config_var('LIBPL')"` +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python_conf="$d" +! else +! for path in "${vi_cv_path_python_pfx}" "${vi_cv_path_python_epfx}"; do +! for subdir in lib64 lib share; do +! d="${path}/${subdir}/python${vi_cv_var_python_version}/config" +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python_conf="$d" +! fi +! done + done +! fi + + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python_conf" >&5 +*************** +*** 5660,5673 **** + if test "${vi_cv_var_python3_abiflags}" != ""; then + config_dir="${config_dir}-${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}" + fi +! for path in "${vi_cv_path_python3_pfx}" "${vi_cv_path_python3_epfx}"; do +! for subdir in lib64 lib share; do +! d="${path}/${subdir}/python${vi_cv_var_python3_version}/${config_dir}" +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python3_conf="$d" +! fi + done +! done + + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python3_conf" >&5 +--- 5665,5683 ---- + if test "${vi_cv_var_python3_abiflags}" != ""; then + config_dir="${config_dir}-${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}" + fi +! d=`${vi_cv_path_python3} -c "import distutils.sysconfig; print(distutils.sysconfig.get_config_var('LIBPL'))"` +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python3_conf="$d" +! else +! for path in "${vi_cv_path_python3_pfx}" "${vi_cv_path_python3_epfx}"; do +! for subdir in lib64 lib share; do +! d="${path}/${subdir}/python${vi_cv_var_python3_version}/${config_dir}" +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python3_conf="$d" +! fi +! done + done +! fi + + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python3_conf" >&5 +*************** +*** 6408,6420 **** + fi + librubyarg=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG['LIBRUBYARG'])"` + librubya=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG['LIBRUBY_A'])"` +! rubylibdir=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG['libdir'])"` + if test -f "$rubylibdir/$librubya"; then + librubyarg="$librubyarg" +! RUBY_LIBS="$RUBY_LIBS -L$rubylibdir" +! elif test "$librubyarg" = "libruby.a"; then +! librubyarg="-lruby" +! RUBY_LIBS="$RUBY_LIBS -L$rubylibdir" + fi + + if test "X$librubyarg" != "X"; then +--- 6418,6430 ---- + fi + librubyarg=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG['LIBRUBYARG'])"` + librubya=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG['LIBRUBY_A'])"` +! rubylibdir=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG['libdir'])"` + if test -f "$rubylibdir/$librubya"; then + librubyarg="$librubyarg" +! RUBY_LIBS="$RUBY_LIBS -L$rubylibdir" +! elif test "$librubyarg" = "libruby.a"; then +! librubyarg="-lruby" +! RUBY_LIBS="$RUBY_LIBS -L$rubylibdir" + fi + + if test "X$librubyarg" != "X"; then +*** ../vim-7.3.1100/src/version.c 2013-06-02 18:54:16.000000000 +0200 +--- src/version.c 2013-06-02 19:01:39.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1101, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +49. You never have to deal with busy signals when calling your ISP...because + you never log off. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6bfd4f51fce43d28957eb846554ab0ed03e969a4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:56 +0200 Subject: [PATCH 0993/3340] - patchlevel 1102 --- 7.3.1102 | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 7.3.1102 diff --git a/7.3.1102 b/7.3.1102 new file mode 100644 index 00000000..f559ddf7 --- /dev/null +++ b/7.3.1102 @@ -0,0 +1,46 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1102 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1102 +Problem: Completion of ":py3do" and ":py3file" does not work after ":py3". +Solution: Make completion work. (Taro Muraoka) +Files: src/ex_docmd.c + + +*** ../vim-7.3.1101/src/ex_docmd.c 2013-06-02 18:20:12.000000000 +0200 +--- src/ex_docmd.c 2013-06-02 19:18:08.000000000 +0200 +*************** +*** 3249,3254 **** +--- 3249,3257 ---- + /* check for non-alpha command */ + if (p == cmd && vim_strchr((char_u *)"@*!=><&~#", *p) != NULL) + ++p; ++ /* for python 3.x: ":py3*" commands completion */ ++ if (cmd[0] == 'p' && cmd[1] == 'y' && p == cmd + 2 && *p == '3') ++ ++p; + len = (int)(p - cmd); + + if (len == 0) +*** ../vim-7.3.1101/src/version.c 2013-06-02 19:14:11.000000000 +0200 +--- src/version.c 2013-06-02 19:16:56.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1102, + /**/ + +-- +CVS sux, men don't like commitment + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f3a10e7fa2292c30e28023246f41dd05e8254b56 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:57 +0200 Subject: [PATCH 0994/3340] - patchlevel 1103 --- 7.3.1103 | 417 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 417 insertions(+) create mode 100644 7.3.1103 diff --git a/7.3.1103 b/7.3.1103 new file mode 100644 index 00000000..8744b361 --- /dev/null +++ b/7.3.1103 @@ -0,0 +1,417 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1103 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1103 +Problem: New regexp engine: overhead in saving and restoring. +Solution: Make saving and restoring list IDs faster. Don't copy or check \z + subexpressions when they are not used. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1102/src/regexp_nfa.c 2013-06-02 16:40:44.000000000 +0200 +--- src/regexp_nfa.c 2013-06-02 21:00:41.000000000 +0200 +*************** +*** 237,242 **** +--- 237,245 ---- + /* NFA regexp \1 .. \9 encountered. */ + static int nfa_has_backref; + ++ /* NFA regexp has \z( ), set zsubexpr. */ ++ static int nfa_has_zsubexpr; ++ + /* Number of sub expressions actually being used during execution. 1 if only + * the whole match (subexpr 0) is used. */ + static int nfa_nsubexpr; +*************** +*** 272,281 **** + static nfa_state_T *post2nfa __ARGS((int *postfix, int *end, int nfa_calc_size)); + static int check_char_class __ARGS((int class, int c)); + static void st_error __ARGS((int *postfix, int *end, int *p)); +! static void nfa_set_neg_listids __ARGS((nfa_state_T *start)); +! static void nfa_set_null_listids __ARGS((nfa_state_T *start)); +! static void nfa_save_listids __ARGS((nfa_state_T *start, int *list)); +! static void nfa_restore_listids __ARGS((nfa_state_T *start, int *list)); + static int nfa_re_num_cmp __ARGS((long_u val, int op, long_u pos)); + static long nfa_regtry __ARGS((nfa_regprog_T *prog, colnr_T col)); + static long nfa_regexec_both __ARGS((char_u *line, colnr_T col)); +--- 275,282 ---- + static nfa_state_T *post2nfa __ARGS((int *postfix, int *end, int nfa_calc_size)); + static int check_char_class __ARGS((int class, int c)); + static void st_error __ARGS((int *postfix, int *end, int *p)); +! static void nfa_save_listids __ARGS((nfa_regprog_T *prog, int *list)); +! static void nfa_restore_listids __ARGS((nfa_regprog_T *prog, int *list)); + static int nfa_re_num_cmp __ARGS((long_u val, int op, long_u pos)); + static long nfa_regtry __ARGS((nfa_regprog_T *prog, colnr_T col)); + static long nfa_regexec_both __ARGS((char_u *line, colnr_T col)); +*************** +*** 3000,3005 **** +--- 3001,3024 ---- + return TRUE; + } + ++ #ifdef ENABLE_LOG ++ static void ++ report_state(char *action, regsub_T *sub, nfa_state_T *state, int lid); ++ { ++ int col; ++ ++ if (sub->in_use <= 0) ++ col = -1; ++ else if (REG_MULTI) ++ col = sub->list.multi[0].start.col; ++ else ++ col = (int)(sub->list.line[0].start - regline); ++ nfa_set_code(state->c); ++ fprintf(log_fd, "> %s state %d to list %d. char %d: %s (start col %d)\n", ++ action, abs(state->id), lid, state->c, code, col); ++ } ++ #endif ++ + static void + addstate(l, state, subs, off) + nfa_list_T *l; /* runtime state list */ +*************** +*** 3118,3124 **** + if (thread->state->id == state->id + && sub_equal(&thread->subs.norm, &subs->norm) + #ifdef FEAT_SYN_HL +! && sub_equal(&thread->subs.synt, &subs->synt) + #endif + ) + goto skip_add; +--- 3137,3144 ---- + if (thread->state->id == state->id + && sub_equal(&thread->subs.norm, &subs->norm) + #ifdef FEAT_SYN_HL +! && (!nfa_has_zsubexpr || +! sub_equal(&thread->subs.synt, &subs->synt)) + #endif + ) + goto skip_add; +*************** +*** 3141,3181 **** + thread->state = state; + copy_sub(&thread->subs.norm, &subs->norm); + #ifdef FEAT_SYN_HL +! copy_sub(&thread->subs.synt, &subs->synt); + #endif + #ifdef ENABLE_LOG +! { +! int col; +! +! if (thread->subs.norm.in_use <= 0) +! col = -1; +! else if (REG_MULTI) +! col = thread->subs.norm.list.multi[0].start.col; +! else +! col = (int)(thread->subs.norm.list.line[0].start - regline); +! nfa_set_code(state->c); +! fprintf(log_fd, "> Adding state %d to list %d. char %d: %s (start col %d)\n", +! abs(state->id), l->id, state->c, code, col); +! did_print = TRUE; +! } + #endif + } + + #ifdef ENABLE_LOG + if (!did_print) +! { +! int col; +! +! if (subs->norm.in_use <= 0) +! col = -1; +! else if (REG_MULTI) +! col = subs->norm.list.multi[0].start.col; +! else +! col = (int)(subs->norm.list.line[0].start - regline); +! nfa_set_code(state->c); +! fprintf(log_fd, "> Processing state %d for list %d. char %d: %s (start col %d)\n", +! abs(state->id), l->id, state->c, code, col); +! } + #endif + switch (state->c) + { +--- 3161,3178 ---- + thread->state = state; + copy_sub(&thread->subs.norm, &subs->norm); + #ifdef FEAT_SYN_HL +! if (nfa_has_zsubexpr) +! copy_sub(&thread->subs.synt, &subs->synt); + #endif + #ifdef ENABLE_LOG +! report_state("Adding", &thread->subs.norm, state, l->id); +! did_print = TRUE; + #endif + } + + #ifdef ENABLE_LOG + if (!did_print) +! report_state("Processing", &subs->norm, state, l->id); + #endif + switch (state->c) + { +*************** +*** 3600,3648 **** + #endif + + /* +! * Set all NFA nodes' list ID equal to -1. + */ + static void +! nfa_set_neg_listids(start) +! nfa_state_T *start; +! { +! if (start != NULL && start->lastlist >= 0) +! { +! start->lastlist = -1; +! nfa_set_neg_listids(start->out); +! nfa_set_neg_listids(start->out1); +! } +! } +! +! /* +! * Set all NFA nodes' list ID equal to 0. +! */ +! static void +! nfa_set_null_listids(start) +! nfa_state_T *start; +! { +! if (start != NULL && start->lastlist == -1) +! { +! start->lastlist = 0; +! nfa_set_null_listids(start->out); +! nfa_set_null_listids(start->out1); +! } +! } +! +! /* +! * Save list IDs for all NFA states in "list". +! */ +! static void +! nfa_save_listids(start, list) +! nfa_state_T *start; + int *list; + { +! if (start != NULL && start->lastlist != -1) +! { +! list[abs(start->id)] = start->lastlist; +! start->lastlist = -1; +! nfa_save_listids(start->out, list); +! nfa_save_listids(start->out1, list); + } + } + +--- 3597,3620 ---- + #endif + + /* +! * Save list IDs for all NFA states of "prog" into "list". +! * Also reset the IDs to zero. + */ + static void +! nfa_save_listids(prog, list) +! nfa_regprog_T *prog; + int *list; + { +! int i; +! nfa_state_T *p; +! +! /* Order in the list is reverse, it's a bit faster that way. */ +! p = &prog->state[0]; +! for (i = prog->nstate; --i >= 0; ) +! { +! list[i] = p->lastlist; +! p->lastlist = 0; +! ++p; + } + } + +*************** +*** 3650,3664 **** + * Restore list IDs from "list" to all NFA states. + */ + static void +! nfa_restore_listids(start, list) +! nfa_state_T *start; + int *list; + { +! if (start != NULL && start->lastlist == -1) + { +! start->lastlist = list[abs(start->id)]; +! nfa_restore_listids(start->out, list); +! nfa_restore_listids(start->out1, list); + } + } + +--- 3622,3639 ---- + * Restore list IDs from "list" to all NFA states. + */ + static void +! nfa_restore_listids(prog, list) +! nfa_regprog_T *prog; + int *list; + { +! int i; +! nfa_state_T *p; +! +! p = &prog->state[0]; +! for (i = prog->nstate; --i >= 0; ) + { +! p->lastlist = list[i]; +! ++p; + } + } + +*************** +*** 3673,3679 **** + return val == pos; + } + +! static int nfa_regmatch __ARGS((nfa_state_T *start, regsubs_T *submatch, regsubs_T *m)); + + /* + * Main matching routine. +--- 3648,3654 ---- + return val == pos; + } + +! static int nfa_regmatch __ARGS((nfa_regprog_T *prog, nfa_state_T *start, regsubs_T *submatch, regsubs_T *m)); + + /* + * Main matching routine. +*************** +*** 3686,3692 **** + * Note: Caller must ensure that: start != NULL. + */ + static int +! nfa_regmatch(start, submatch, m) + nfa_state_T *start; + regsubs_T *submatch; + regsubs_T *m; +--- 3661,3668 ---- + * Note: Caller must ensure that: start != NULL. + */ + static int +! nfa_regmatch(prog, start, submatch, m) +! nfa_regprog_T *prog; + nfa_state_T *start; + regsubs_T *submatch; + regsubs_T *m; +*************** +*** 3872,3878 **** + nfa_match = TRUE; + copy_sub(&submatch->norm, &t->subs.norm); + #ifdef FEAT_SYN_HL +! copy_sub(&submatch->synt, &t->subs.synt); + #endif + #ifdef ENABLE_LOG + log_subsexpr(&t->subs); +--- 3848,3855 ---- + nfa_match = TRUE; + copy_sub(&submatch->norm, &t->subs.norm); + #ifdef FEAT_SYN_HL +! if (nfa_has_zsubexpr) +! copy_sub(&submatch->synt, &t->subs.synt); + #endif + #ifdef ENABLE_LOG + log_subsexpr(&t->subs); +*************** +*** 3928,3934 **** + { + copy_sub(&m->norm, &t->subs.norm); + #ifdef FEAT_SYN_HL +! copy_sub(&m->synt, &t->subs.synt); + #endif + } + nfa_match = TRUE; +--- 3905,3912 ---- + { + copy_sub(&m->norm, &t->subs.norm); + #ifdef FEAT_SYN_HL +! if (nfa_has_zsubexpr) +! copy_sub(&m->synt, &t->subs.synt); + #endif + } + nfa_match = TRUE; +*************** +*** 4024,4035 **** + /* Have to clear the listid field of the NFA nodes, so that + * nfa_regmatch() and addstate() can run properly after + * recursion. */ +! nfa_save_listids(start, listids); +! nfa_set_null_listids(start); + nfa_endp = endposp; +! result = nfa_regmatch(t->state->out, submatch, m); +! nfa_set_neg_listids(start); +! nfa_restore_listids(start, listids); + + /* restore position in input text */ + reginput = save_reginput; +--- 4002,4011 ---- + /* Have to clear the listid field of the NFA nodes, so that + * nfa_regmatch() and addstate() can run properly after + * recursion. */ +! nfa_save_listids(prog, listids); + nfa_endp = endposp; +! result = nfa_regmatch(prog, t->state->out, submatch, m); +! nfa_restore_listids(prog, listids); + + /* restore position in input text */ + reginput = save_reginput; +*************** +*** 4665,4671 **** +--- 4641,4652 ---- + #ifdef FEAT_SYN_HL + /* Clear the external match subpointers if necessary. */ + if (prog->reghasz == REX_SET) ++ { ++ nfa_has_zsubexpr = TRUE; + need_clear_zsubexpr = TRUE; ++ } ++ else ++ nfa_has_zsubexpr = FALSE; + #endif + + #ifdef ENABLE_LOG +*************** +*** 4694,4700 **** + clear_sub(&m.synt); + #endif + +! if (nfa_regmatch(start, &subs, &m) == FALSE) + return 0; + + cleanup_subexpr(); +--- 4675,4681 ---- + clear_sub(&m.synt); + #endif + +! if (nfa_regmatch(prog, start, &subs, &m) == FALSE) + return 0; + + cleanup_subexpr(); +*** ../vim-7.3.1102/src/version.c 2013-06-02 19:22:05.000000000 +0200 +--- src/version.c 2013-06-02 21:24:50.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1103, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +53. To find out what time it is, you send yourself an e-mail and check the + "Date:" field. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a42e099a7515a5e9a142663a5224c847576b78e2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:58 +0200 Subject: [PATCH 0995/3340] - patchlevel 1104 --- 7.3.1104 | 111 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 111 insertions(+) create mode 100644 7.3.1104 diff --git a/7.3.1104 b/7.3.1104 new file mode 100644 index 00000000..93670915 --- /dev/null +++ b/7.3.1104 @@ -0,0 +1,111 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1104 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1104 +Problem: New regexp engine does not handle "~". +Solution: Add support for "~". +Files: src/regexp_nfa.c, src/testdir/test24.in, src/testdir/test24.ok + + +*** ../vim-7.3.1103/src/regexp_nfa.c 2013-06-02 21:30:00.000000000 +0200 +--- src/regexp_nfa.c 2013-06-02 22:00:21.000000000 +0200 +*************** +*** 829,837 **** + EMSGN(_(e_misplaced), no_Magic(c)); + return FAIL; + +! case Magic('~'): /* previous substitute pattern */ +! /* TODO: Not supported yet */ +! return FAIL; + + case Magic('1'): + case Magic('2'): +--- 829,854 ---- + EMSGN(_(e_misplaced), no_Magic(c)); + return FAIL; + +! case Magic('~'): +! { +! char_u *lp; +! +! /* Previous substitute pattern. +! * Generated as "\%(pattern\)". */ +! if (reg_prev_sub == NULL) +! { +! EMSG(_(e_nopresub)); +! return FAIL; +! } +! for (lp = reg_prev_sub; *lp != NUL; mb_cptr_adv(lp)) +! { +! EMIT(PTR2CHAR(lp)); +! if (lp != reg_prev_sub) +! EMIT(NFA_CONCAT); +! } +! EMIT(NFA_NOPEN); +! break; +! } + + case Magic('1'): + case Magic('2'): +*** ../vim-7.3.1103/src/testdir/test24.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test24.in 2013-06-02 22:03:23.000000000 +0200 +*************** +*** 44,49 **** +--- 44,56 ---- + :s/^\(\h\w*\%(->\|\.\)\=\)\+=/XX/ + + :s/^\(\h\w*\%(->\|\.\)\=\)\+=/YY/ ++ ++ :s/aaa/xyz/ ++ ++ :s/~/bcd/ ++ ++ :s/~\+/BB/ ++ :" + :?start?,$w! test.out + :qa! + ENDTEST +*************** +*** 77,79 **** +--- 84,89 ---- + xx an file xx + x= 9; + hh= 77; ++ aaa ++ xyz ++ bcdbcdbcd +*** ../vim-7.3.1103/src/testdir/test24.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test24.ok 2013-06-02 22:03:36.000000000 +0200 +*************** +*** 27,29 **** +--- 27,32 ---- + xx an A xx + XX 9; + YY 77; ++ xyz ++ bcd ++ BB +*** ../vim-7.3.1103/src/version.c 2013-06-02 21:30:00.000000000 +0200 +--- src/version.c 2013-06-02 22:07:20.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1104, + /**/ + +-- +Q: What is a patch 22? +A: A patch you need to include to make it possible to include patches. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f59ea23d8166ad43e0af997942ab03473d308095 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:58 +0200 Subject: [PATCH 0996/3340] - patchlevel 1105 --- 7.3.1105 | 433 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 433 insertions(+) create mode 100644 7.3.1105 diff --git a/7.3.1105 b/7.3.1105 new file mode 100644 index 00000000..0fd7a867 --- /dev/null +++ b/7.3.1105 @@ -0,0 +1,433 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1105 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1105 +Problem: New regexp engine: too much code in one function. Dead code. +Solution: Move the recursive nfa_regmatch call to a separate function. + Remove the dead code. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1104/src/regexp_nfa.c 2013-06-02 22:07:57.000000000 +0200 +--- src/regexp_nfa.c 2013-06-02 22:35:43.000000000 +0200 +*************** +*** 3665,3673 **** +--- 3665,3802 ---- + return val == pos; + } + ++ static int recursive_regmatch __ARGS((nfa_state_T *state, nfa_regprog_T *prog, regsubs_T *submatch, regsubs_T *m, int **listids)); + static int nfa_regmatch __ARGS((nfa_regprog_T *prog, nfa_state_T *start, regsubs_T *submatch, regsubs_T *m)); + + /* ++ * Recursively call nfa_regmatch() ++ */ ++ static int ++ recursive_regmatch(state, prog, submatch, m, listids) ++ nfa_state_T *state; ++ nfa_regprog_T *prog; ++ regsubs_T *submatch; ++ regsubs_T *m; ++ int **listids; ++ { ++ char_u *save_reginput = reginput; ++ char_u *save_regline = regline; ++ int save_reglnum = reglnum; ++ int save_nfa_match = nfa_match; ++ save_se_T *save_nfa_endp = nfa_endp; ++ save_se_T endpos; ++ save_se_T *endposp = NULL; ++ int result; ++ ++ if (state->c == NFA_START_INVISIBLE_BEFORE) ++ { ++ /* The recursive match must end at the current position. */ ++ endposp = &endpos; ++ if (REG_MULTI) ++ { ++ endpos.se_u.pos.col = (int)(reginput - regline); ++ endpos.se_u.pos.lnum = reglnum; ++ } ++ else ++ endpos.se_u.ptr = reginput; ++ ++ /* Go back the specified number of bytes, or as far as the ++ * start of the previous line, to try matching "\@<=" or ++ * not matching "\@val <= 0) ++ { ++ if (REG_MULTI) ++ { ++ regline = reg_getline(--reglnum); ++ if (regline == NULL) ++ /* can't go before the first line */ ++ regline = reg_getline(++reglnum); ++ } ++ reginput = regline; ++ } ++ else ++ { ++ if (REG_MULTI && (int)(reginput - regline) < state->val) ++ { ++ /* Not enough bytes in this line, go to end of ++ * previous line. */ ++ regline = reg_getline(--reglnum); ++ if (regline == NULL) ++ { ++ /* can't go before the first line */ ++ regline = reg_getline(++reglnum); ++ reginput = regline; ++ } ++ else ++ reginput = regline + STRLEN(regline); ++ } ++ if ((int)(reginput - regline) >= state->val) ++ { ++ reginput -= state->val; ++ #ifdef FEAT_MBYTE ++ if (has_mbyte) ++ reginput -= mb_head_off(regline, reginput); ++ #endif ++ } ++ else ++ reginput = regline; ++ } ++ } ++ ++ /* Call nfa_regmatch() to check if the current concat matches ++ * at this position. The concat ends with the node ++ * NFA_END_INVISIBLE */ ++ if (*listids == NULL) ++ { ++ *listids = (int *)lalloc(sizeof(int) * nstate, TRUE); ++ if (*listids == NULL) ++ { ++ EMSG(_("E878: (NFA) Could not allocate memory for branch traversal!")); ++ return 0; ++ } ++ } ++ #ifdef ENABLE_LOG ++ if (log_fd != stderr) ++ fclose(log_fd); ++ log_fd = NULL; ++ #endif ++ /* Have to clear the listid field of the NFA nodes, so that ++ * nfa_regmatch() and addstate() can run properly after ++ * recursion. */ ++ nfa_save_listids(prog, *listids); ++ nfa_endp = endposp; ++ result = nfa_regmatch(prog, state->out, submatch, m); ++ nfa_restore_listids(prog, *listids); ++ ++ /* restore position in input text */ ++ reginput = save_reginput; ++ regline = save_regline; ++ reglnum = save_reglnum; ++ nfa_match = save_nfa_match; ++ nfa_endp = save_nfa_endp; ++ ++ #ifdef ENABLE_LOG ++ log_fd = fopen(NFA_REGEXP_RUN_LOG, "a"); ++ if (log_fd != NULL) ++ { ++ fprintf(log_fd, "****************************\n"); ++ fprintf(log_fd, "FINISHED RUNNING nfa_regmatch() recursively\n"); ++ fprintf(log_fd, "MATCH = %s\n", result == TRUE ? "OK" : "FALSE"); ++ fprintf(log_fd, "****************************\n"); ++ } ++ else ++ { ++ EMSG(_("Could not open temporary log file for writing, displaying on stderr ... ")); ++ log_fd = stderr; ++ } ++ #endif ++ ++ return result; ++ } ++ ++ /* + * Main matching routine. + * + * Run NFA to determine whether it matches reginput. +*************** +*** 3881,4051 **** + } + + case NFA_END_INVISIBLE: +! /* This is only encountered after a NFA_START_INVISIBLE or + * NFA_START_INVISIBLE_BEFORE node. + * They surround a zero-width group, used with "\@=", "\&", + * "\@!", "\@<=" and "\@c == NFA_MOPEN) +! /* TODO: do we ever get here? */ +! addstate_here(thislist, t->state->out, &t->subs, &listidx); +! else +! { + #ifdef ENABLE_LOG +! if (nfa_endp != NULL) +! { +! if (REG_MULTI) +! fprintf(log_fd, "Current lnum: %d, endp lnum: %d; current col: %d, endp col: %d\n", +! (int)reglnum, +! (int)nfa_endp->se_u.pos.lnum, +! (int)(reginput - regline), +! nfa_endp->se_u.pos.col); +! else +! fprintf(log_fd, "Current col: %d, endp col: %d\n", +! (int)(reginput - regline), +! (int)(nfa_endp->se_u.ptr - reginput)); +! } +! #endif +! /* It's only a match if it ends at "nfa_endp" */ +! if (nfa_endp != NULL && (REG_MULTI +! ? (reglnum != nfa_endp->se_u.pos.lnum +! || (int)(reginput - regline) +! != nfa_endp->se_u.pos.col) +! : reginput != nfa_endp->se_u.ptr)) +! break; +! +! /* do not set submatches for \@! */ +! if (!t->state->negated) +! { +! copy_sub(&m->norm, &t->subs.norm); +! #ifdef FEAT_SYN_HL +! if (nfa_has_zsubexpr) +! copy_sub(&m->synt, &t->subs.synt); +! #endif +! } +! nfa_match = TRUE; +! } +! break; +! +! case NFA_START_INVISIBLE: +! case NFA_START_INVISIBLE_BEFORE: +! { +! char_u *save_reginput = reginput; +! char_u *save_regline = regline; +! int save_reglnum = reglnum; +! int save_nfa_match = nfa_match; +! save_se_T *save_nfa_endp = nfa_endp; +! save_se_T endpos; +! save_se_T *endposp = NULL; +! +! if (t->state->c == NFA_START_INVISIBLE_BEFORE) + { +- /* The recursive match must end at the current position. */ +- endposp = &endpos; + if (REG_MULTI) +! { +! endpos.se_u.pos.col = (int)(reginput - regline); +! endpos.se_u.pos.lnum = reglnum; +! } + else +! endpos.se_u.ptr = reginput; +! +! /* Go back the specified number of bytes, or as far as the +! * start of the previous line, to try matching "\@<=" or +! * not matching "\@state->val <= 0) +! { +! if (REG_MULTI) +! { +! regline = reg_getline(--reglnum); +! if (regline == NULL) +! /* can't go before the first line */ +! regline = reg_getline(++reglnum); +! } +! reginput = regline; +! } +! else +! { +! if (REG_MULTI +! && (int)(reginput - regline) < t->state->val) +! { +! /* Not enough bytes in this line, go to end of +! * previous line. */ +! regline = reg_getline(--reglnum); +! if (regline == NULL) +! { +! /* can't go before the first line */ +! regline = reg_getline(++reglnum); +! reginput = regline; +! } +! else +! reginput = regline + STRLEN(regline); +! } +! if ((int)(reginput - regline) >= t->state->val) +! { +! reginput -= t->state->val; +! #ifdef FEAT_MBYTE +! if (has_mbyte) +! reginput -= mb_head_off(regline, reginput); +! #endif +! } +! else +! reginput = regline; +! } + } + +! /* Call nfa_regmatch() to check if the current concat matches +! * at this position. The concat ends with the node +! * NFA_END_INVISIBLE */ +! if (listids == NULL) + { +! listids = (int *)lalloc(sizeof(int) * nstate, TRUE); +! if (listids == NULL) +! { +! EMSG(_("E878: (NFA) Could not allocate memory for branch traversal!")); +! return 0; +! } + } +! #ifdef ENABLE_LOG +! if (log_fd != stderr) +! fclose(log_fd); +! log_fd = NULL; +! #endif +! /* Have to clear the listid field of the NFA nodes, so that +! * nfa_regmatch() and addstate() can run properly after +! * recursion. */ +! nfa_save_listids(prog, listids); +! nfa_endp = endposp; +! result = nfa_regmatch(prog, t->state->out, submatch, m); +! nfa_restore_listids(prog, listids); +! +! /* restore position in input text */ +! reginput = save_reginput; +! regline = save_regline; +! reglnum = save_reglnum; +! nfa_match = save_nfa_match; +! nfa_endp = save_nfa_endp; + +- #ifdef ENABLE_LOG +- log_fd = fopen(NFA_REGEXP_RUN_LOG, "a"); +- if (log_fd != NULL) +- { +- fprintf(log_fd, "****************************\n"); +- fprintf(log_fd, "FINISHED RUNNING nfa_regmatch() recursively\n"); +- fprintf(log_fd, "MATCH = %s\n", result == TRUE ? "OK" : "FALSE"); +- fprintf(log_fd, "****************************\n"); +- } +- else +- { +- EMSG(_("Could not open temporary log file for writing, displaying on stderr ... ")); +- log_fd = stderr; +- } +- #endif + /* for \@! it is a match when result is FALSE */ + if (result != t->state->negated) + { +--- 4010,4066 ---- + } + + case NFA_END_INVISIBLE: +! /* +! * This is only encountered after a NFA_START_INVISIBLE or + * NFA_START_INVISIBLE_BEFORE node. + * They surround a zero-width group, used with "\@=", "\&", + * "\@!", "\@<=" and "\@se_u.pos.lnum, +! (int)(reginput - regline), +! nfa_endp->se_u.pos.col); + else +! fprintf(log_fd, "Current col: %d, endp col: %d\n", +! (int)(reginput - regline), +! (int)(nfa_endp->se_u.ptr - reginput)); + } ++ #endif ++ /* It's only a match if it ends at "nfa_endp" */ ++ if (nfa_endp != NULL && (REG_MULTI ++ ? (reglnum != nfa_endp->se_u.pos.lnum ++ || (int)(reginput - regline) ++ != nfa_endp->se_u.pos.col) ++ : reginput != nfa_endp->se_u.ptr)) ++ break; + +! /* do not set submatches for \@! */ +! if (!t->state->negated) + { +! copy_sub(&m->norm, &t->subs.norm); +! #ifdef FEAT_SYN_HL +! if (nfa_has_zsubexpr) +! copy_sub(&m->synt, &t->subs.synt); +! #endif + } +! nfa_match = TRUE; +! break; +! +! case NFA_START_INVISIBLE: +! case NFA_START_INVISIBLE_BEFORE: +! result = recursive_regmatch(t->state, prog, submatch, m, +! &listids); + + /* for \@! it is a match when result is FALSE */ + if (result != t->state->negated) + { +*************** +*** 4056,4067 **** + #endif + + /* t->state->out1 is the corresponding END_INVISIBLE node; +! * Add it to the current list (zero-width match). */ + addstate_here(thislist, t->state->out1->out, &t->subs, + &listidx); + } + break; +- } + + case NFA_BOL: + if (reginput == regline) +--- 4071,4081 ---- + #endif + + /* t->state->out1 is the corresponding END_INVISIBLE node; +! * Add its out to the current list (zero-width match). */ + addstate_here(thislist, t->state->out1->out, &t->subs, + &listidx); + } + break; + + case NFA_BOL: + if (reginput == regline) +*** ../vim-7.3.1104/src/version.c 2013-06-02 22:07:57.000000000 +0200 +--- src/version.c 2013-06-02 22:37:02.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1105, + /**/ + +-- +"I can't complain, but sometimes I still do." (Joe Walsh) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2dbc7a74e73664f32af918d60bdf2df7a10c6dc7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:06:59 +0200 Subject: [PATCH 0997/3340] - patchlevel 1106 --- 7.3.1106 | 383 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 383 insertions(+) create mode 100644 7.3.1106 diff --git a/7.3.1106 b/7.3.1106 new file mode 100644 index 00000000..801c0072 --- /dev/null +++ b/7.3.1106 @@ -0,0 +1,383 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1106 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1106 +Problem: New regexp engine: saving and restoring lastlist in the states + takes a lot of time. +Solution: Use a second lastlist value for the first recursive call. +Files: src/regexp.h, src/regexp_nfa.c + + +*** ../vim-7.3.1105/src/regexp.h 2013-06-02 15:55:52.000000000 +0200 +--- src/regexp.h 2013-06-03 11:29:26.000000000 +0200 +*************** +*** 72,78 **** + nfa_state_T *out; + nfa_state_T *out1; + int id; +! int lastlist; + int negated; + int val; + }; +--- 72,78 ---- + nfa_state_T *out; + nfa_state_T *out1; + int id; +! int lastlist[2]; /* 0: normal, 1: recursive */ + int negated; + int val; + }; +*** ../vim-7.3.1105/src/regexp_nfa.c 2013-06-02 22:37:39.000000000 +0200 +--- src/regexp_nfa.c 2013-06-03 12:15:17.000000000 +0200 +*************** +*** 255,260 **** +--- 255,269 ---- + /* If not NULL match must end at this position */ + static save_se_T *nfa_endp = NULL; + ++ /* listid is global, so that it increases on recursive calls to ++ * nfa_regmatch(), which means we don't have to clear the lastlist field of ++ * all the states. */ ++ static int nfa_listid; ++ static int nfa_alt_listid; ++ ++ /* 0 for first call to nfa_regmatch(), 1 for recursive call. */ ++ static int nfa_ll_index = 0; ++ + static int nfa_regcomp_start __ARGS((char_u*expr, int re_flags)); + static int nfa_recognize_char_class __ARGS((char_u *start, char_u *end, int extra_newl)); + static int nfa_emit_equi_class __ARGS((int c, int neg)); +*************** +*** 2169,2175 **** + s->out1 = out1; + + s->id = istate; +! s->lastlist = 0; + s->negated = FALSE; + + return s; +--- 2178,2185 ---- + s->out1 = out1; + + s->id = istate; +! s->lastlist[0] = 0; +! s->lastlist[1] = 0; + s->negated = FALSE; + + return s; +*************** +*** 3113,3121 **** + #endif + /* These nodes do not need to be added, but we need to bail out + * when it was tried to be added to this list before. */ +! if (state->lastlist == l->id) + goto skip_add; +! state->lastlist = l->id; + break; + + case NFA_BOL: +--- 3123,3131 ---- + #endif + /* These nodes do not need to be added, but we need to bail out + * when it was tried to be added to this list before. */ +! if (state->lastlist[nfa_ll_index] == l->id) + goto skip_add; +! state->lastlist[nfa_ll_index] = l->id; + break; + + case NFA_BOL: +*************** +*** 3131,3137 **** + /* FALLTHROUGH */ + + default: +! if (state->lastlist == l->id) + { + /* This state is already in the list, don't add it again, + * unless it is an MOPEN that is used for a backreference. */ +--- 3141,3147 ---- + /* FALLTHROUGH */ + + default: +! if (state->lastlist[nfa_ll_index] == l->id) + { + /* This state is already in the list, don't add it again, + * unless it is an MOPEN that is used for a backreference. */ +*************** +*** 3173,3179 **** + } + + /* add the state to the list */ +! state->lastlist = l->id; + thread = &l->t[l->n++]; + thread->state = state; + copy_sub(&thread->subs.norm, &subs->norm); +--- 3183,3189 ---- + } + + /* add the state to the list */ +! state->lastlist[nfa_ll_index] = l->id; + thread = &l->t[l->n++]; + thread->state = state; + copy_sub(&thread->subs.norm, &subs->norm); +*************** +*** 3616,3621 **** +--- 3626,3632 ---- + /* + * Save list IDs for all NFA states of "prog" into "list". + * Also reset the IDs to zero. ++ * Only used for the recursive value lastlist[1]. + */ + static void + nfa_save_listids(prog, list) +*************** +*** 3629,3636 **** + p = &prog->state[0]; + for (i = prog->nstate; --i >= 0; ) + { +! list[i] = p->lastlist; +! p->lastlist = 0; + ++p; + } + } +--- 3640,3647 ---- + p = &prog->state[0]; + for (i = prog->nstate; --i >= 0; ) + { +! list[i] = p->lastlist[1]; +! p->lastlist[1] = 0; + ++p; + } + } +*************** +*** 3649,3655 **** + p = &prog->state[0]; + for (i = prog->nstate; --i >= 0; ) + { +! p->lastlist = list[i]; + ++p; + } + } +--- 3660,3666 ---- + p = &prog->state[0]; + for (i = prog->nstate; --i >= 0; ) + { +! p->lastlist[1] = list[i]; + ++p; + } + } +*************** +*** 3683,3692 **** +--- 3694,3705 ---- + char_u *save_regline = regline; + int save_reglnum = reglnum; + int save_nfa_match = nfa_match; ++ int save_nfa_listid = nfa_listid; + save_se_T *save_nfa_endp = nfa_endp; + save_se_T endpos; + save_se_T *endposp = NULL; + int result; ++ int need_restore = FALSE; + + if (state->c == NFA_START_INVISIBLE_BEFORE) + { +*************** +*** 3745,3774 **** + } + } + +- /* Call nfa_regmatch() to check if the current concat matches +- * at this position. The concat ends with the node +- * NFA_END_INVISIBLE */ +- if (*listids == NULL) +- { +- *listids = (int *)lalloc(sizeof(int) * nstate, TRUE); +- if (*listids == NULL) +- { +- EMSG(_("E878: (NFA) Could not allocate memory for branch traversal!")); +- return 0; +- } +- } + #ifdef ENABLE_LOG + if (log_fd != stderr) + fclose(log_fd); + log_fd = NULL; + #endif +! /* Have to clear the listid field of the NFA nodes, so that +! * nfa_regmatch() and addstate() can run properly after +! * recursion. */ +! nfa_save_listids(prog, *listids); + nfa_endp = endposp; + result = nfa_regmatch(prog, state->out, submatch, m); +! nfa_restore_listids(prog, *listids); + + /* restore position in input text */ + reginput = save_reginput; +--- 3758,3809 ---- + } + } + + #ifdef ENABLE_LOG + if (log_fd != stderr) + fclose(log_fd); + log_fd = NULL; + #endif +! /* Have to clear the lastlist field of the NFA nodes, so that +! * nfa_regmatch() and addstate() can run properly after recursion. */ +! if (nfa_ll_index == 1) +! { +! /* Already calling nfa_regmatch() recursively. Save the lastlist[1] +! * values and clear them. */ +! if (*listids == NULL) +! { +! *listids = (int *)lalloc(sizeof(int) * nstate, TRUE); +! if (*listids == NULL) +! { +! EMSG(_("E878: (NFA) Could not allocate memory for branch traversal!")); +! return 0; +! } +! } +! nfa_save_listids(prog, *listids); +! need_restore = TRUE; +! /* any value of nfa_listid will do */ +! } +! else +! { +! /* First recursive nfa_regmatch() call, switch to the second lastlist +! * entry. Make sure nfa_listid is different from a previous recursive +! * call, because some states may still have this ID. */ +! ++nfa_ll_index; +! if (nfa_listid <= nfa_alt_listid) +! nfa_listid = nfa_alt_listid; +! } +! +! /* Call nfa_regmatch() to check if the current concat matches at this +! * position. The concat ends with the node NFA_END_INVISIBLE */ + nfa_endp = endposp; + result = nfa_regmatch(prog, state->out, submatch, m); +! +! if (need_restore) +! nfa_restore_listids(prog, *listids); +! else +! { +! --nfa_ll_index; +! nfa_alt_listid = nfa_listid; +! } + + /* restore position in input text */ + reginput = save_reginput; +*************** +*** 3776,3781 **** +--- 3811,3817 ---- + reglnum = save_reglnum; + nfa_match = save_nfa_match; + nfa_endp = save_nfa_endp; ++ nfa_listid = save_nfa_listid; + + #ifdef ENABLE_LOG + log_fd = fopen(NFA_REGEXP_RUN_LOG, "a"); +*************** +*** 3821,3827 **** + nfa_list_T list[3]; + nfa_list_T *listtbl[2][2]; + nfa_list_T *ll; +- int listid = 1; + int listidx; + nfa_list_T *thislist; + nfa_list_T *nextlist; +--- 3857,3862 ---- +*************** +*** 3875,3881 **** + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif +! thislist->id = listid; + addstate(thislist, start, m, 0); + + /* There are two cases when the NFA advances: 1. input char matches the +--- 3910,3916 ---- + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif +! thislist->id = nfa_listid + 1; + addstate(thislist, start, m, 0); + + /* There are two cases when the NFA advances: 1. input char matches the +*************** +*** 3923,3932 **** + nextlist = &list[flag ^= 1]; + nextlist->n = 0; /* clear nextlist */ + listtbl[1][0] = nextlist; +! ++listid; +! thislist->id = listid; +! nextlist->id = listid + 1; +! neglist->id = listid + 1; + + #ifdef ENABLE_LOG + fprintf(log_fd, "------------------------------------------\n"); +--- 3958,3967 ---- + nextlist = &list[flag ^= 1]; + nextlist->n = 0; /* clear nextlist */ + listtbl[1][0] = nextlist; +! ++nfa_listid; +! thislist->id = nfa_listid; +! nextlist->id = nfa_listid + 1; +! neglist->id = nfa_listid + 1; + + #ifdef ENABLE_LOG + fprintf(log_fd, "------------------------------------------\n"); +*************** +*** 4843,4848 **** +--- 4878,4885 ---- + nfa_has_zend = prog->has_zend; + nfa_has_backref = prog->has_backref; + nfa_nsubexpr = prog->nsubexp; ++ nfa_listid = 1; ++ nfa_alt_listid = 2; + #ifdef DEBUG + nfa_regengine.expr = prog->pattern; + #endif +*************** +*** 4851,4857 **** + for (i = 0; i < nstate; ++i) + { + prog->state[i].id = i; +! prog->state[i].lastlist = 0; + } + + retval = nfa_regtry(prog, col); +--- 4888,4895 ---- + for (i = 0; i < nstate; ++i) + { + prog->state[i].id = i; +! prog->state[i].lastlist[0] = 0; +! prog->state[i].lastlist[1] = 0; + } + + retval = nfa_regtry(prog, col); +*** ../vim-7.3.1105/src/version.c 2013-06-02 22:37:39.000000000 +0200 +--- src/version.c 2013-06-03 12:13:15.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1106, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +59. Your wife says communication is important in a marriage...so you buy + another computer and install a second phone line so the two of you can + chat. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d101c4337cb3d00827d1c8df03de55da0f67676a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:07:00 +0200 Subject: [PATCH 0998/3340] - patchlevel 1107 --- 7.3.1107 | 80 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 7.3.1107 diff --git a/7.3.1107 b/7.3.1107 new file mode 100644 index 00000000..23d14b75 --- /dev/null +++ b/7.3.1107 @@ -0,0 +1,80 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1107 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1107 +Problem: Compiler warnings for unused variables. +Solution: Put the variables inside #ifdef. +Files: src/regexp.c, src/regexp_nfa.c + + +*** ../vim-7.3.1106/src/regexp.c 2013-06-02 15:01:51.000000000 +0200 +--- src/regexp.c 2013-06-03 19:38:46.000000000 +0200 +*************** +*** 361,368 **** +--- 361,370 ---- + static char_u e_unmatchedpp[] = N_("E53: Unmatched %s%%("); + static char_u e_unmatchedp[] = N_("E54: Unmatched %s("); + static char_u e_unmatchedpar[] = N_("E55: Unmatched %s)"); ++ #ifdef FEAT_SYN_HL + static char_u e_z_not_allowed[] = N_("E66: \\z( not allowed here"); + static char_u e_z1_not_allowed[] = N_("E67: \\z1 et al. not allowed here"); ++ #endif + + #define NOT_MULTI 0 + #define MULTI_ONE 1 +*** ../vim-7.3.1106/src/regexp_nfa.c 2013-06-03 12:17:00.000000000 +0200 +--- src/regexp_nfa.c 2013-06-03 19:39:55.000000000 +0200 +*************** +*** 237,244 **** +--- 237,246 ---- + /* NFA regexp \1 .. \9 encountered. */ + static int nfa_has_backref; + ++ #ifdef FEAT_SYN_HL + /* NFA regexp has \z( ), set zsubexpr. */ + static int nfa_has_zsubexpr; ++ #endif + + /* Number of sub expressions actually being used during execution. 1 if only + * the whole match (subexpr 0) is used. */ +*************** +*** 420,426 **** + if (*p == '^') + { + not = TRUE; +! p ++; + } + + while (p < end) +--- 422,428 ---- + if (*p == '^') + { + not = TRUE; +! p++; + } + + while (p < end) +*** ../vim-7.3.1106/src/version.c 2013-06-03 12:17:00.000000000 +0200 +--- src/version.c 2013-06-03 19:39:34.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1107, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +70. ISDN lines are added to your house on a hourly basis + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 54efc5f23a127bb4c629dd9c8568a70a7432b28d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:07:00 +0200 Subject: [PATCH 0999/3340] - patchlevel 1108 --- 7.3.1108 | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 7.3.1108 diff --git a/7.3.1108 b/7.3.1108 new file mode 100644 index 00000000..66b02b21 --- /dev/null +++ b/7.3.1108 @@ -0,0 +1,46 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1108 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1108 +Problem: Error message for os.fchdir() (Charles Peacech) +Solution: Clear the error. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1107/src/if_py_both.h 2013-06-02 18:54:16.000000000 +0200 +--- src/if_py_both.h 2013-06-03 20:01:23.000000000 +0200 +*************** +*** 5413,5418 **** +--- 5413,5420 ---- + if (PyObject_SetAttrString(os, "fchdir", get_attr(m, "fchdir"))) + return -1; + } ++ else ++ PyErr_Clear(); + + return 0; + } +*** ../vim-7.3.1107/src/version.c 2013-06-03 19:41:01.000000000 +0200 +--- src/version.c 2013-06-03 20:00:42.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1108, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +71. You wonder how people walk + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d92ab6d2cadfd79bea80925d2e5e9a529aba2f73 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:07:01 +0200 Subject: [PATCH 1000/3340] - patchlevel 1109 --- 7.3.1109 | 134 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 134 insertions(+) create mode 100644 7.3.1109 diff --git a/7.3.1109 b/7.3.1109 new file mode 100644 index 00000000..1e0c049a --- /dev/null +++ b/7.3.1109 @@ -0,0 +1,134 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1109 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1109 +Problem: Building on MS-Windows doesn't see changes in if_py_both.h. +Solution: Add a dependency. (Ken Takata) +Files: src/Make_bc5.mak, src/Make_cyg.mak, src/Make_ming.mak, + src/Make_mvc.mak + + +*** ../vim-7.3.1108/src/Make_bc5.mak 2013-02-26 14:56:24.000000000 +0100 +--- src/Make_bc5.mak 2013-06-03 20:09:58.000000000 +0200 +*************** +*** 1006,1015 **** + $(PERL)\bin\perl.exe $(PERL)\lib\ExtUtils\xsubpp -prototypes -typemap \ + $(PERL)\lib\ExtUtils\typemap if_perl.xs > $@ + +! $(OBJDIR)\if_python.obj: if_python.c python.lib + $(CC) -I$(PYTHON)\include $(CCARG) $(CC1) $(CC2)$@ -pc if_python.c + +! $(OBJDIR)\if_python3.obj: if_python3.c python3.lib + $(CC) -I$(PYTHON3)\include $(CCARG) $(CC1) $(CC2)$@ -pc if_python3.c + + $(OBJDIR)\if_ruby.obj: if_ruby.c ruby.lib +--- 1006,1015 ---- + $(PERL)\bin\perl.exe $(PERL)\lib\ExtUtils\xsubpp -prototypes -typemap \ + $(PERL)\lib\ExtUtils\typemap if_perl.xs > $@ + +! $(OBJDIR)\if_python.obj: if_python.c if_py_both.h python.lib + $(CC) -I$(PYTHON)\include $(CCARG) $(CC1) $(CC2)$@ -pc if_python.c + +! $(OBJDIR)\if_python3.obj: if_python3.c if_py_both.h python3.lib + $(CC) -I$(PYTHON3)\include $(CCARG) $(CC1) $(CC2)$@ -pc if_python3.c + + $(OBJDIR)\if_ruby.obj: if_ruby.c ruby.lib +*** ../vim-7.3.1108/src/Make_cyg.mak 2013-05-19 19:16:25.000000000 +0200 +--- src/Make_cyg.mak 2013-06-03 20:09:58.000000000 +0200 +*************** +*** 648,657 **** + $(OUTDIR)/if_ole.o: if_ole.cpp $(INCL) + $(CC) -c $(CFLAGS) if_ole.cpp -o $(OUTDIR)/if_ole.o + +! $(OUTDIR)/if_python.o : if_python.c $(INCL) + $(CC) -c $(CFLAGS) -I$(PYTHON)/include $< -o $@ + +! $(OUTDIR)/if_python3.o : if_python3.c $(INCL) + $(CC) -c $(CFLAGS) -I$(PYTHON3)/include $< -o $@ + + if_perl.c: if_perl.xs typemap +--- 648,657 ---- + $(OUTDIR)/if_ole.o: if_ole.cpp $(INCL) + $(CC) -c $(CFLAGS) if_ole.cpp -o $(OUTDIR)/if_ole.o + +! $(OUTDIR)/if_python.o : if_python.c if_py_both.h $(INCL) + $(CC) -c $(CFLAGS) -I$(PYTHON)/include $< -o $@ + +! $(OUTDIR)/if_python3.o : if_python3.c if_py_both.h $(INCL) + $(CC) -c $(CFLAGS) -I$(PYTHON3)/include $< -o $@ + + if_perl.c: if_perl.xs typemap +*** ../vim-7.3.1108/src/Make_ming.mak 2013-05-19 19:16:25.000000000 +0200 +--- src/Make_ming.mak 2013-06-03 20:09:58.000000000 +0200 +*************** +*** 721,730 **** + structs.h regexp.h option.h ex_cmds.h proto.h globals.h farsi.h \ + gui.h + +! $(OUTDIR)/if_python.o : if_python.c $(INCL) + $(CC) -c $(CFLAGS) $(PYTHONINC) -DDYNAMIC_PYTHON_DLL=\"python$(PYTHON_VER).dll\" $< -o $@ + +! $(OUTDIR)/if_python3.o : if_python3.c $(INCL) + $(CC) -c $(CFLAGS) $(PYTHON3INC) -DDYNAMIC_PYTHON3_DLL=\"PYTHON$(PYTHON3_VER).dll\" $< -o $@ + + $(OUTDIR)/%.o : %.c $(INCL) +--- 721,730 ---- + structs.h regexp.h option.h ex_cmds.h proto.h globals.h farsi.h \ + gui.h + +! $(OUTDIR)/if_python.o : if_python.c if_py_both.h $(INCL) + $(CC) -c $(CFLAGS) $(PYTHONINC) -DDYNAMIC_PYTHON_DLL=\"python$(PYTHON_VER).dll\" $< -o $@ + +! $(OUTDIR)/if_python3.o : if_python3.c if_py_both.h $(INCL) + $(CC) -c $(CFLAGS) $(PYTHON3INC) -DDYNAMIC_PYTHON3_DLL=\"PYTHON$(PYTHON3_VER).dll\" $< -o $@ + + $(OUTDIR)/%.o : %.c $(INCL) +*** ../vim-7.3.1108/src/Make_mvc.mak 2013-05-19 21:03:50.000000000 +0200 +--- src/Make_mvc.mak 2013-06-03 20:09:58.000000000 +0200 +*************** +*** 1113,1122 **** + mzscheme_base.c: + $(MZSCHEME)\mzc --c-mods mzscheme_base.c ++lib scheme/base + +! $(OUTDIR)/if_python.obj: $(OUTDIR) if_python.c $(INCL) + $(CC) $(CFLAGS) $(PYTHON_INC) if_python.c + +! $(OUTDIR)/if_python3.obj: $(OUTDIR) if_python3.c $(INCL) + $(CC) $(CFLAGS) $(PYTHON3_INC) if_python3.c + + $(OUTDIR)/if_ole.obj: $(OUTDIR) if_ole.cpp $(INCL) if_ole.h +--- 1113,1122 ---- + mzscheme_base.c: + $(MZSCHEME)\mzc --c-mods mzscheme_base.c ++lib scheme/base + +! $(OUTDIR)/if_python.obj: $(OUTDIR) if_python.c if_py_both.h $(INCL) + $(CC) $(CFLAGS) $(PYTHON_INC) if_python.c + +! $(OUTDIR)/if_python3.obj: $(OUTDIR) if_python3.c if_py_both.h $(INCL) + $(CC) $(CFLAGS) $(PYTHON3_INC) if_python3.c + + $(OUTDIR)/if_ole.obj: $(OUTDIR) if_ole.cpp $(INCL) if_ole.h +*** ../vim-7.3.1108/src/version.c 2013-06-03 20:04:43.000000000 +0200 +--- src/version.c 2013-06-03 20:10:22.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1109, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +74. Your most erotic dreams are about cybersex + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d3b012d03f77f829b7cc3365e387d4069c28d1f9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Tue, 4 Jun 2013 12:07:02 +0200 Subject: [PATCH 1001/3340] - patchlevel 1109 --- README.patches | 105 +++++++++++++++++++++++- vim.spec | 215 ++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 318 insertions(+), 2 deletions(-) diff --git a/README.patches b/README.patches index de26f645..923bf048 100644 --- a/README.patches +++ b/README.patches @@ -871,7 +871,7 @@ Individual patches for Vim 7.3: 2221 7.3.837 empty lines in :version output when 'columns' is 320 11057 7.3.838 (after 7.3.830) insufficient testing for mksession 2012 7.3.839 some files missing in the list of distributed files - 1652 7.3.840 "\@ 7.3.1109-1 +- patchlevel 1109 + * Wed May 22 2013 Karsten Hopp 7.3.1004-1 - patchlevel 1004 From 3c6980664afd15e6275a26209ec48eefeebb7ba8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:27:53 +0200 Subject: [PATCH 1002/3340] - patchlevel 1110 --- 7.3.1110 | 842 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 842 insertions(+) create mode 100644 7.3.1110 diff --git a/7.3.1110 b/7.3.1110 new file mode 100644 index 00000000..a8944bfd --- /dev/null +++ b/7.3.1110 @@ -0,0 +1,842 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1110 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1110 +Problem: New regexp matching: Using \@= and the like can be slow. +Solution: Decide whether to first try matching the zero-wdith part or what + follows, whatever is more likely to fail. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1109/src/regexp_nfa.c 2013-06-03 19:41:01.000000000 +0200 +--- src/regexp_nfa.c 2013-06-04 14:21:32.000000000 +0200 +*************** +*** 2824,2834 **** +--- 2824,2851 ---- + #endif + } regsubs_T; + ++ /* nfa_pim_T stores a Postponed Invisible Match. */ ++ typedef struct nfa_pim_S nfa_pim_T; ++ struct nfa_pim_S ++ { ++ nfa_state_T *state; ++ int result; /* NFA_PIM_TODO, NFA_PIM_[NO]MATCH */ ++ nfa_pim_T *pim; /* another PIM at the same position */ ++ regsubs_T subs; /* submatch info, only party used */ ++ }; ++ ++ /* Values for done in nfa_pim_T. */ ++ #define NFA_PIM_TODO 0 ++ #define NFA_PIM_MATCH 1 ++ #define NFA_PIM_NOMATCH -1 ++ ++ + /* nfa_thread_T contains execution information of a NFA state */ + typedef struct + { + nfa_state_T *state; + int count; ++ nfa_pim_T *pim; /* if not NULL: postponed invisible match */ + regsubs_T subs; /* submatch info, only party used */ + } nfa_thread_T; + +*************** +*** 2886,2892 **** + static void copy_sub_off __ARGS((regsub_T *to, regsub_T *from)); + static int sub_equal __ARGS((regsub_T *sub1, regsub_T *sub2)); + static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, int off)); +! static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, int *ip)); + + static void + clear_sub(sub) +--- 2903,2909 ---- + static void copy_sub_off __ARGS((regsub_T *to, regsub_T *from)); + static int sub_equal __ARGS((regsub_T *sub1, regsub_T *sub2)); + static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, int off)); +! static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, nfa_pim_T *pim, int *ip)); + + static void + clear_sub(sub) +*************** +*** 3032,3038 **** + + #ifdef ENABLE_LOG + static void +! report_state(char *action, regsub_T *sub, nfa_state_T *state, int lid); + { + int col; + +--- 3049,3055 ---- + + #ifdef ENABLE_LOG + static void +! report_state(char *action, regsub_T *sub, nfa_state_T *state, int lid) + { + int col; + +*************** +*** 3174,3181 **** + } + } + +! /* when there are backreferences the number of states may be (a +! * lot) bigger */ + if (nfa_has_backref && l->n == l->len) + { + int newlen = l->len * 3 / 2 + 50; +--- 3191,3198 ---- + } + } + +! /* when there are backreferences or look-behind matches the number +! * of states may be (a lot) bigger */ + if (nfa_has_backref && l->n == l->len) + { + int newlen = l->len * 3 / 2 + 50; +*************** +*** 3188,3193 **** +--- 3205,3211 ---- + state->lastlist[nfa_ll_index] = l->id; + thread = &l->t[l->n++]; + thread->state = state; ++ thread->pim = NULL; + copy_sub(&thread->subs.norm, &subs->norm); + #ifdef FEAT_SYN_HL + if (nfa_has_zsubexpr) +*************** +*** 3419,3439 **** + * matters for alternatives. + */ + static void +! addstate_here(l, state, subs, ip) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ + regsubs_T *subs; /* pointers to subexpressions */ + int *ip; + { + int tlen = l->n; + int count; +! int i = *ip; + + /* first add the state(s) at the end, so that we know how many there are */ + addstate(l, state, subs, 0); + + /* when "*ip" was at the end of the list, nothing to do */ +! if (i + 1 == tlen) + return; + + /* re-order to put the new state at the current position */ +--- 3437,3464 ---- + * matters for alternatives. + */ + static void +! addstate_here(l, state, subs, pim, ip) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ + regsubs_T *subs; /* pointers to subexpressions */ ++ nfa_pim_T *pim; /* postponed look-behind match */ + int *ip; + { + int tlen = l->n; + int count; +! int listidx = *ip; +! int i; + + /* first add the state(s) at the end, so that we know how many there are */ + addstate(l, state, subs, 0); + ++ /* fill in the "pim" field in the new states */ ++ if (pim != NULL) ++ for (i = tlen; i < l->n; ++i) ++ l->t[i].pim = pim; ++ + /* when "*ip" was at the end of the list, nothing to do */ +! if (listidx + 1 == tlen) + return; + + /* re-order to put the new state at the current position */ +*************** +*** 3441,3461 **** + if (count == 1) + { + /* overwrite the current state */ +! l->t[i] = l->t[l->n - 1]; + } + else if (count > 1) + { + /* make space for new states, then move them from the + * end to the current position */ +! mch_memmove(&(l->t[i + count]), +! &(l->t[i + 1]), +! sizeof(nfa_thread_T) * (l->n - i - 1)); +! mch_memmove(&(l->t[i]), + &(l->t[l->n - 1]), + sizeof(nfa_thread_T) * count); + } + --l->n; +! *ip = i - 1; + } + + /* +--- 3466,3486 ---- + if (count == 1) + { + /* overwrite the current state */ +! l->t[listidx] = l->t[l->n - 1]; + } + else if (count > 1) + { + /* make space for new states, then move them from the + * end to the current position */ +! mch_memmove(&(l->t[listidx + count]), +! &(l->t[listidx + 1]), +! sizeof(nfa_thread_T) * (l->n - listidx - 1)); +! mch_memmove(&(l->t[listidx]), + &(l->t[l->n - 1]), + sizeof(nfa_thread_T) * count); + } + --l->n; +! *ip = listidx - 1; + } + + /* +*************** +*** 3834,3839 **** +--- 3859,3903 ---- + return result; + } + ++ static int failure_chance __ARGS((nfa_state_T *state, int depth)); ++ ++ /* ++ * Estimate the chance of a match with "state" failing. ++ * NFA_ANY: 1 ++ * specific character: 99 ++ */ ++ static int ++ failure_chance(state, depth) ++ nfa_state_T *state; ++ int depth; ++ { ++ int c = state->c; ++ int l, r; ++ ++ /* detect looping */ ++ if (depth > 4) ++ return 1; ++ ++ if (c == NFA_SPLIT) ++ { ++ if (state->out->c == NFA_SPLIT || state->out1->c == NFA_SPLIT) ++ return 1; ++ l = failure_chance(state->out, depth + 1); ++ r = failure_chance(state->out1, depth + 1); ++ return l < r ? l : r; ++ } ++ if (c == NFA_ANY) ++ return 1; ++ if (c > 0) ++ return 99; ++ if ((c >= NFA_MOPEN && c <= NFA_MOPEN9) ++ || (c >= NFA_ZOPEN && c <= NFA_ZOPEN9) ++ || c == NFA_NOPEN) ++ return failure_chance(state->out, depth + 1); ++ /* something else */ ++ return 50; ++ } ++ + /* + * Main matching routine. + * +*************** +*** 3864,3869 **** +--- 3928,3937 ---- + nfa_list_T *nextlist; + nfa_list_T *neglist; + int *listids = NULL; ++ nfa_state_T *add_state; ++ int add_count; ++ int add_off; ++ garray_T pimlist; + #ifdef NFA_REGEXP_DEBUG_LOG + FILE *debug = fopen(NFA_REGEXP_DEBUG_LOG, "a"); + +*************** +*** 3874,3879 **** +--- 3942,3948 ---- + } + #endif + nfa_match = FALSE; ++ ga_init2(&pimlist, sizeof(nfa_pim_T), 5); + + /* Allocate memory for the lists of nodes. */ + size = (nstate + 1) * sizeof(nfa_thread_T); +*************** +*** 3923,3933 **** + listtbl[0][1] = neglist; + listtbl[1][0] = nextlist; + listtbl[1][1] = NULL; +! #define ADD_POS_NEG_STATE(node) \ +! ll = listtbl[result ? 1 : 0][node->negated]; \ +! if (ll != NULL) \ +! addstate(ll, node->out , &t->subs, clen); +! + + /* + * Run for each character. +--- 3992,4003 ---- + listtbl[0][1] = neglist; + listtbl[1][0] = nextlist; + listtbl[1][1] = NULL; +! #define ADD_POS_NEG_STATE(state) \ +! ll = listtbl[result ? 1 : 0][state->negated]; \ +! if (ll != NULL) { \ +! add_state = state->out; \ +! add_off = clen; \ +! } + + /* + * Run for each character. +*************** +*** 3965,3970 **** +--- 4035,4042 ---- + nextlist->id = nfa_listid + 1; + neglist->id = nfa_listid + 1; + ++ pimlist.ga_len = 0; ++ + #ifdef ENABLE_LOG + fprintf(log_fd, "------------------------------------------\n"); + fprintf(log_fd, ">>> Reginput is \"%s\"\n", reginput); +*************** +*** 4024,4029 **** +--- 4096,4103 ---- + * Handle the possible codes of the current state. + * The most important is NFA_MATCH. + */ ++ add_state = NULL; ++ add_count = 0; + switch (t->state->c) + { + case NFA_MATCH: +*************** +*** 4095,4127 **** + + case NFA_START_INVISIBLE: + case NFA_START_INVISIBLE_BEFORE: +! result = recursive_regmatch(t->state, prog, submatch, m, +! &listids); + +! /* for \@! it is a match when result is FALSE */ +! if (result != t->state->negated) +! { +! /* Copy submatch info from the recursive call */ +! copy_sub_off(&t->subs.norm, &m->norm); + #ifdef FEAT_SYN_HL +! copy_sub_off(&t->subs.synt, &m->synt); + #endif + +! /* t->state->out1 is the corresponding END_INVISIBLE node; +! * Add its out to the current list (zero-width match). */ +! addstate_here(thislist, t->state->out1->out, &t->subs, +! &listidx); + } + break; + + case NFA_BOL: + if (reginput == regline) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + case NFA_EOL: + if (curc == NUL) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + case NFA_BOW: +--- 4169,4256 ---- + + case NFA_START_INVISIBLE: + case NFA_START_INVISIBLE_BEFORE: +! /* If invisible match has a higher chance to fail, do it +! * right away. Otherwise postpone it until what follows is +! * matching and causes addstate(nextlist, ..) to be called. +! * This is indicated by the "pim" field. */ +! { +! nfa_pim_T *pim; +! int cout = t->state->out1->out->c; +! +! /* Do it directly when what follows is possibly end of +! * match (closing paren). +! * Postpone when it is \@<= or \@pim and check multiple +! * where it's used? +! * Otherwise first do the one that has the highest chance +! * of failing. */ +! if ((cout >= NFA_MCLOSE && cout <= NFA_MCLOSE9) +! || (cout >= NFA_ZCLOSE && cout <= NFA_ZCLOSE9) +! || cout == NFA_NCLOSE +! || t->pim != NULL +! || (t->state->c != NFA_START_INVISIBLE_BEFORE +! && failure_chance(t->state->out1->out, 0) +! < failure_chance(t->state->out, 0))) +! { +! /* +! * First try matching the invisible match, then what +! * follows. +! */ +! result = recursive_regmatch(t->state, prog, +! submatch, m, &listids); + +! /* for \@! it is a match when result is FALSE */ +! if (result != t->state->negated) +! { +! /* Copy submatch info from the recursive call */ +! copy_sub_off(&t->subs.norm, &m->norm); + #ifdef FEAT_SYN_HL +! copy_sub_off(&t->subs.synt, &m->synt); + #endif + +! /* t->state->out1 is the corresponding +! * END_INVISIBLE node; Add its out to the current +! * list (zero-width match). */ +! addstate_here(thislist, t->state->out1->out, +! &t->subs, t->pim, &listidx); +! } +! } +! else +! { +! /* +! * First try matching what follows at the current +! * position. Only if a match is found, addstate() is +! * called, then verify the invisible match matches. +! * Add a nfa_pim_T to the following states, it +! * contains info about the invisible match. +! */ +! if (ga_grow(&pimlist, 1) == FAIL) +! goto theend; +! pim = (nfa_pim_T *)pimlist.ga_data + pimlist.ga_len; +! ++pimlist.ga_len; +! pim->state = t->state; +! pim->pim = NULL; +! pim->result = NFA_PIM_TODO; +! +! /* t->state->out1 is the corresponding END_INVISIBLE +! * node; Add its out to the current list (zero-width +! * match). */ +! addstate_here(thislist, t->state->out1->out, &t->subs, +! pim, &listidx); +! } + } + break; + + case NFA_BOL: + if (reginput == regline) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + case NFA_EOL: + if (curc == NUL) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + case NFA_BOW: +*************** +*** 4148,4154 **** + && vim_iswordc_buf(reginput[-1], reg_buf))) + bow = FALSE; + if (bow) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + } + +--- 4277,4284 ---- + && vim_iswordc_buf(reginput[-1], reg_buf))) + bow = FALSE; + if (bow) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + } + +*************** +*** 4176,4194 **** + && vim_iswordc_buf(curc, reg_buf))) + eow = FALSE; + if (eow) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + } + + case NFA_BOF: + if (reglnum == 0 && reginput == regline + && (!REG_MULTI || reg_firstlnum == 1)) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + case NFA_EOF: + if (reglnum == reg_maxline && curc == NUL) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + #ifdef FEAT_MBYTE +--- 4306,4327 ---- + && vim_iswordc_buf(curc, reg_buf))) + eow = FALSE; + if (eow) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + } + + case NFA_BOF: + if (reglnum == 0 && reginput == regline + && (!REG_MULTI || reg_firstlnum == 1)) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + case NFA_EOF: + if (reglnum == reg_maxline && curc == NUL) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + #ifdef FEAT_MBYTE +*************** +*** 4277,4288 **** + go_to_nextline = TRUE; + /* Pass -1 for the offset, which means taking the position + * at the start of the next line. */ +! addstate(nextlist, t->state->out, &t->subs, -1); + } + else if (curc == '\n' && reg_line_lbr) + { + /* match \n as if it is an ordinary character */ +! addstate(nextlist, t->state->out, &t->subs, 1); + } + break; + +--- 4410,4425 ---- + go_to_nextline = TRUE; + /* Pass -1 for the offset, which means taking the position + * at the start of the next line. */ +! ll = nextlist; +! add_state = t->state->out; +! add_off = -1; + } + else if (curc == '\n' && reg_line_lbr) + { + /* match \n as if it is an ordinary character */ +! ll = nextlist; +! add_state = t->state->out; +! add_off = 1; + } + break; + +*************** +*** 4310,4322 **** + /* This follows a series of negated nodes, like: + * CHAR(x), NFA_NOT, CHAR(y), NFA_NOT etc. */ + if (curc > 0) +! addstate(nextlist, t->state->out, &t->subs, clen); + break; + + case NFA_ANY: + /* Any char except '\0', (end of input) does not match. */ + if (curc > 0) +! addstate(nextlist, t->state->out, &t->subs, clen); + break; + + /* +--- 4447,4467 ---- + /* This follows a series of negated nodes, like: + * CHAR(x), NFA_NOT, CHAR(y), NFA_NOT etc. */ + if (curc > 0) +! { +! ll = nextlist; +! add_state = t->state->out; +! add_off = clen; +! } + break; + + case NFA_ANY: + /* Any char except '\0', (end of input) does not match. */ + if (curc > 0) +! { +! ll = nextlist; +! add_state = t->state->out; +! add_off = clen; +! } + break; + + /* +*************** +*** 4498,4510 **** + /* empty match always works, output of NFA_SKIP to be + * used next */ + addstate_here(thislist, t->state->out->out, &t->subs, +! &listidx); + } + else if (bytelen <= clen) + { + /* match current character, jump ahead to out of + * NFA_SKIP */ +! addstate(nextlist, t->state->out->out, &t->subs, clen); + #ifdef ENABLE_LOG + log_subsexpr(&nextlist->t[nextlist->n - 1].subs); + #endif +--- 4643,4657 ---- + /* empty match always works, output of NFA_SKIP to be + * used next */ + addstate_here(thislist, t->state->out->out, &t->subs, +! t->pim, &listidx); + } + else if (bytelen <= clen) + { + /* match current character, jump ahead to out of + * NFA_SKIP */ +! ll = nextlist; +! add_state = t->state->out->out; +! add_off = clen; + #ifdef ENABLE_LOG + log_subsexpr(&nextlist->t[nextlist->n - 1].subs); + #endif +*************** +*** 4513,4520 **** + { + /* skip ofer the matched characters, set character + * count in NFA_SKIP */ +! addstate(nextlist, t->state->out, &t->subs, bytelen); +! nextlist->t[nextlist->n - 1].count = bytelen - clen; + #ifdef ENABLE_LOG + log_subsexpr(&nextlist->t[nextlist->n - 1].subs); + #endif +--- 4660,4669 ---- + { + /* skip ofer the matched characters, set character + * count in NFA_SKIP */ +! ll = nextlist; +! add_state = t->state->out; +! add_off = bytelen; +! add_count = bytelen - clen; + #ifdef ENABLE_LOG + log_subsexpr(&nextlist->t[nextlist->n - 1].subs); + #endif +*************** +*** 4528,4534 **** + if (t->count - clen <= 0) + { + /* end of match, go to what follows */ +! addstate(nextlist, t->state->out, &t->subs, clen); + #ifdef ENABLE_LOG + log_subsexpr(&nextlist->t[nextlist->n - 1].subs); + #endif +--- 4677,4685 ---- + if (t->count - clen <= 0) + { + /* end of match, go to what follows */ +! ll = nextlist; +! add_state = t->state->out; +! add_off = clen; + #ifdef ENABLE_LOG + log_subsexpr(&nextlist->t[nextlist->n - 1].subs); + #endif +*************** +*** 4536,4543 **** + else + { + /* add state again with decremented count */ +! addstate(nextlist, t->state, &t->subs, 0); +! nextlist->t[nextlist->n - 1].count = t->count - clen; + #ifdef ENABLE_LOG + log_subsexpr(&nextlist->t[nextlist->n - 1].subs); + #endif +--- 4687,4696 ---- + else + { + /* add state again with decremented count */ +! ll = nextlist; +! add_state = t->state; +! add_off = 0; +! add_count = t->count - clen; + #ifdef ENABLE_LOG + log_subsexpr(&nextlist->t[nextlist->n - 1].subs); + #endif +*************** +*** 4557,4563 **** + nfa_re_num_cmp(t->state->val, t->state->c - NFA_LNUM, + (long_u)(reglnum + reg_firstlnum))); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + case NFA_COL: +--- 4710,4717 ---- + nfa_re_num_cmp(t->state->val, t->state->c - NFA_LNUM, + (long_u)(reglnum + reg_firstlnum))); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + case NFA_COL: +*************** +*** 4566,4572 **** + result = nfa_re_num_cmp(t->state->val, t->state->c - NFA_COL, + (long_u)(reginput - regline) + 1); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + case NFA_VCOL: +--- 4720,4727 ---- + result = nfa_re_num_cmp(t->state->val, t->state->c - NFA_COL, + (long_u)(reginput - regline) + 1); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + case NFA_VCOL: +*************** +*** 4577,4583 **** + reg_win == NULL ? curwin : reg_win, + regline, (colnr_T)(reginput - regline)) + 1); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + case NFA_CURSOR: +--- 4732,4739 ---- + reg_win == NULL ? curwin : reg_win, + regline, (colnr_T)(reginput - regline)) + 1); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + case NFA_CURSOR: +*************** +*** 4586,4592 **** + && ((colnr_T)(reginput - regline) + == reg_win->w_cursor.col)); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, &listidx); + break; + + default: /* regular character */ +--- 4742,4749 ---- + && ((colnr_T)(reginput - regline) + == reg_win->w_cursor.col)); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + default: /* regular character */ +*************** +*** 4613,4618 **** +--- 4770,4834 ---- + ADD_POS_NEG_STATE(t->state); + break; + } ++ ++ } /* switch (t->state->c) */ ++ ++ if (add_state != NULL) ++ { ++ if (t->pim != NULL) ++ { ++ /* postponed invisible match */ ++ /* TODO: also do t->pim->pim recursively? */ ++ if (t->pim->result == NFA_PIM_TODO) ++ { ++ #ifdef ENABLE_LOG ++ fprintf(log_fd, "\n"); ++ fprintf(log_fd, "==================================\n"); ++ fprintf(log_fd, "Postponed recursive nfa_regmatch()\n"); ++ fprintf(log_fd, "\n"); ++ #endif ++ result = recursive_regmatch(t->pim->state, ++ prog, submatch, m, &listids); ++ t->pim->result = result ? NFA_PIM_MATCH ++ : NFA_PIM_NOMATCH; ++ /* for \@! it is a match when result is FALSE */ ++ if (result != t->pim->state->negated) ++ { ++ /* Copy submatch info from the recursive call */ ++ copy_sub_off(&t->pim->subs.norm, &m->norm); ++ #ifdef FEAT_SYN_HL ++ copy_sub_off(&t->pim->subs.synt, &m->synt); ++ #endif ++ } ++ } ++ else ++ { ++ result = (t->pim->result == NFA_PIM_MATCH); ++ #ifdef ENABLE_LOG ++ fprintf(log_fd, "\n"); ++ fprintf(log_fd, "Using previous recursive nfa_regmatch() result, result == %d\n", t->pim->result); ++ fprintf(log_fd, "MATCH = %s\n", result == TRUE ? "OK" : "FALSE"); ++ fprintf(log_fd, "\n"); ++ #endif ++ } ++ ++ /* for \@! it is a match when result is FALSE */ ++ if (result != t->pim->state->negated) ++ { ++ /* Copy submatch info from the recursive call */ ++ copy_sub_off(&t->subs.norm, &t->pim->subs.norm); ++ #ifdef FEAT_SYN_HL ++ copy_sub_off(&t->subs.synt, &t->pim->subs.synt); ++ #endif ++ } ++ else ++ /* look-behind match failed, don't add the state */ ++ continue; ++ } ++ ++ addstate(ll, add_state, &t->subs, add_off); ++ if (add_count > 0) ++ nextlist->t[ll->n - 1].count = add_count; + } + + } /* for (thislist = thislist; thislist->state; thislist++) */ +*************** +*** 4680,4685 **** +--- 4896,4902 ---- + vim_free(list[1].t); + vim_free(list[2].t); + vim_free(listids); ++ ga_clear(&pimlist); + #undef ADD_POS_NEG_STATE + #ifdef NFA_REGEXP_DEBUG_LOG + fclose(debug); +*** ../vim-7.3.1109/src/version.c 2013-06-03 20:12:47.000000000 +0200 +--- src/version.c 2013-06-04 13:51:17.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1110, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +80. At parties, you introduce your spouse as your "service provider." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8f0b651ad7d80aaa358d09f6fd1ca5e98c650954 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:27:54 +0200 Subject: [PATCH 1003/3340] - patchlevel 1111 --- 7.3.1111 | 575 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 575 insertions(+) create mode 100644 7.3.1111 diff --git a/7.3.1111 b/7.3.1111 new file mode 100644 index 00000000..da690584 --- /dev/null +++ b/7.3.1111 @@ -0,0 +1,575 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1111 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1111 +Problem: nfa_recognize_char_class() implementation is inefficient. +Solution: Use bits in an int instead of chars in a string. (Dominique Pelle) +Files: src/regexp_nfa.c, src/testdir/test36.in, src/testdir/test36.ok + + +*** ../vim-7.3.1110/src/regexp_nfa.c 2013-06-04 14:23:00.000000000 +0200 +--- src/regexp_nfa.c 2013-06-04 17:38:43.000000000 +0200 +*************** +*** 380,417 **** + char_u *end; + int extra_newl; + { +! int i; +! /* Each of these variables takes up a char in "config[]", +! * in the order they are here. */ +! int not = FALSE, af = FALSE, AF = FALSE, az = FALSE, AZ = FALSE, +! o7 = FALSE, o9 = FALSE, underscore = FALSE, newl = FALSE; + char_u *p; +! #define NCONFIGS 16 +! int classid[NCONFIGS] = { +! NFA_DIGIT, NFA_NDIGIT, NFA_HEX, NFA_NHEX, +! NFA_OCTAL, NFA_NOCTAL, NFA_WORD, NFA_NWORD, +! NFA_HEAD, NFA_NHEAD, NFA_ALPHA, NFA_NALPHA, +! NFA_LOWER, NFA_NLOWER, NFA_UPPER, NFA_NUPPER +! }; +! char_u myconfig[10]; +! char_u config[NCONFIGS][9] = { +! "000000100", /* digit */ +! "100000100", /* non digit */ +! "011000100", /* hex-digit */ +! "111000100", /* non hex-digit */ +! "000001000", /* octal-digit */ +! "100001000", /* [^0-7] */ +! "000110110", /* [0-9A-Za-z_] */ +! "100110110", /* [^0-9A-Za-z_] */ +! "000110010", /* head of word */ +! "100110010", /* not head of word */ +! "000110000", /* alphabetic char a-z */ +! "100110000", /* non alphabetic char */ +! "000100000", /* lowercase letter */ +! "100100000", /* non lowercase */ +! "000010000", /* uppercase */ +! "100010000" /* non uppercase */ +! }; + + if (extra_newl == TRUE) + newl = TRUE; +--- 380,397 ---- + char_u *end; + int extra_newl; + { +! # define CLASS_not 0x80 +! # define CLASS_af 0x40 +! # define CLASS_AF 0x20 +! # define CLASS_az 0x10 +! # define CLASS_AZ 0x08 +! # define CLASS_o7 0x04 +! # define CLASS_o9 0x02 +! # define CLASS_underscore 0x01 +! +! int newl = FALSE; + char_u *p; +! int config = 0; + + if (extra_newl == TRUE) + newl = TRUE; +*************** +*** 421,427 **** + p = start; + if (*p == '^') + { +! not = TRUE; + p++; + } + +--- 401,407 ---- + p = start; + if (*p == '^') + { +! config |= CLASS_not; + p++; + } + +*************** +*** 434,470 **** + case '0': + if (*(p + 2) == '9') + { +! o9 = TRUE; + break; + } + else + if (*(p + 2) == '7') + { +! o7 = TRUE; + break; + } + case 'a': + if (*(p + 2) == 'z') + { +! az = TRUE; + break; + } + else + if (*(p + 2) == 'f') + { +! af = TRUE; + break; + } + case 'A': + if (*(p + 2) == 'Z') + { +! AZ = TRUE; + break; + } + else + if (*(p + 2) == 'F') + { +! AF = TRUE; + break; + } + /* FALLTHROUGH */ +--- 414,450 ---- + case '0': + if (*(p + 2) == '9') + { +! config |= CLASS_o9; + break; + } + else + if (*(p + 2) == '7') + { +! config |= CLASS_o7; + break; + } + case 'a': + if (*(p + 2) == 'z') + { +! config |= CLASS_az; + break; + } + else + if (*(p + 2) == 'f') + { +! config |= CLASS_af; + break; + } + case 'A': + if (*(p + 2) == 'Z') + { +! config |= CLASS_AZ; + break; + } + else + if (*(p + 2) == 'F') + { +! config |= CLASS_AF; + break; + } + /* FALLTHROUGH */ +*************** +*** 480,486 **** + } + else if (*p == '_') + { +! underscore = TRUE; + p ++; + } + else if (*p == '\n') +--- 460,466 ---- + } + else if (*p == '_') + { +! config |= CLASS_underscore; + p ++; + } + else if (*p == '\n') +*************** +*** 495,532 **** + if (p != end) + return FAIL; + +- /* build the config that represents the ranges we gathered */ +- STRCPY(myconfig, "000000000"); +- if (not == TRUE) +- myconfig[0] = '1'; +- if (af == TRUE) +- myconfig[1] = '1'; +- if (AF == TRUE) +- myconfig[2] = '1'; +- if (az == TRUE) +- myconfig[3] = '1'; +- if (AZ == TRUE) +- myconfig[4] = '1'; +- if (o7 == TRUE) +- myconfig[5] = '1'; +- if (o9 == TRUE) +- myconfig[6] = '1'; +- if (underscore == TRUE) +- myconfig[7] = '1'; + if (newl == TRUE) +- { +- myconfig[8] = '1'; + extra_newl = ADD_NL; +- } +- /* try to recognize character classes */ +- for (i = 0; i < NCONFIGS; i++) +- if (STRNCMP(myconfig, config[i], 8) == 0) +- return classid[i] + extra_newl; + +! /* fallthrough => no success so far */ + return FAIL; +- +- #undef NCONFIGS + } + + /* +--- 475,519 ---- + if (p != end) + return FAIL; + + if (newl == TRUE) + extra_newl = ADD_NL; + +! switch (config) +! { +! case CLASS_o9: +! return extra_newl + NFA_DIGIT; +! case CLASS_not | CLASS_o9: +! return extra_newl + NFA_NDIGIT; +! case CLASS_af | CLASS_AF | CLASS_o9: +! return extra_newl + NFA_HEX; +! case CLASS_not | CLASS_af | CLASS_AF | CLASS_o9: +! return extra_newl + NFA_NHEX; +! case CLASS_o7: +! return extra_newl + NFA_OCTAL; +! case CLASS_not | CLASS_o7: +! return extra_newl + NFA_NOCTAL; +! case CLASS_az | CLASS_AZ | CLASS_o9 | CLASS_underscore: +! return extra_newl + NFA_WORD; +! case CLASS_not | CLASS_az | CLASS_AZ | CLASS_o9 | CLASS_underscore: +! return extra_newl + NFA_NWORD; +! case CLASS_az | CLASS_AZ | CLASS_underscore: +! return extra_newl + NFA_HEAD; +! case CLASS_not | CLASS_az | CLASS_AZ | CLASS_underscore: +! return extra_newl + NFA_NHEAD; +! case CLASS_az | CLASS_AZ: +! return extra_newl + NFA_ALPHA; +! case CLASS_not | CLASS_az | CLASS_AZ: +! return extra_newl + NFA_NALPHA; +! case CLASS_az: +! return extra_newl + NFA_LOWER; +! case CLASS_not | CLASS_az: +! return extra_newl + NFA_NLOWER; +! case CLASS_AZ: +! return extra_newl + NFA_UPPER; +! case CLASS_not | CLASS_AZ: +! return extra_newl + NFA_NUPPER; +! } + return FAIL; + } + + /* +*************** +*** 900,906 **** + EMSG_RET_FAIL(_(e_z1_not_allowed)); + EMIT(NFA_ZREF1 + (no_Magic(c) - '1')); + /* No need to set nfa_has_backref, the sub-matches don't +! * change when \z1 .. \z9 maches or not. */ + re_has_z = REX_USE; + break; + case '(': +--- 887,893 ---- + EMSG_RET_FAIL(_(e_z1_not_allowed)); + EMIT(NFA_ZREF1 + (no_Magic(c) - '1')); + /* No need to set nfa_has_backref, the sub-matches don't +! * change when \z1 .. \z9 matches or not. */ + re_has_z = REX_USE; + break; + case '(': +*************** +*** 4658,4664 **** + } + else + { +! /* skip ofer the matched characters, set character + * count in NFA_SKIP */ + ll = nextlist; + add_state = t->state->out; +--- 4645,4651 ---- + } + else + { +! /* skip over the matched characters, set character + * count in NFA_SKIP */ + ll = nextlist; + add_state = t->state->out; +*** ../vim-7.3.1110/src/testdir/test36.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test36.in 2013-06-04 17:38:14.000000000 +0200 +*************** +*** 1,40 **** +! Test character classes in regexp + + STARTTEST +! /^start-here +! j:s/\d//g +! j:s/\D//g +! j:s/\o//g +! j:s/\O//g +! j:s/\x//g +! j:s/\X//g +! j:s/\w//g +! j:s/\W//g +! j:s/\h//g +! j:s/\H//g +! j:s/\a//g +! j:s/\A//g +! j:s/\l//g +! j:s/\L//g +! j:s/\u//g +! j:s/\U//g + :/^start-here/+1,$wq! test.out + ENDTEST + + start-here + !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +- !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +- !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +- !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +- !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +- !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +- !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +- !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +- !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +- !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +- !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +- !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +- !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +- !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +- !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +- !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +--- 1,105 ---- +! Test character classes in regexp using regexpengine 0, 1, 2. + + STARTTEST +! /^start-here/+1 +! Y:s/\%#=0\d//g +! p:s/\%#=1\d//g +! p:s/\%#=2\d//g +! p:s/\%#=0[0-9]//g +! p:s/\%#=1[0-9]//g +! p:s/\%#=2[0-9]//g +! p:s/\%#=0\D//g +! p:s/\%#=1\D//g +! p:s/\%#=2\D//g +! p:s/\%#=0[^0-9]//g +! p:s/\%#=1[^0-9]//g +! p:s/\%#=2[^0-9]//g +! p:s/\%#=0\o//g +! p:s/\%#=1\o//g +! p:s/\%#=2\o//g +! p:s/\%#=0[0-7]//g +! p:s/\%#=1[0-7]//g +! p:s/\%#=2[0-7]//g +! p:s/\%#=0\O//g +! p:s/\%#=1\O//g +! p:s/\%#=2\O//g +! p:s/\%#=0[^0-7]//g +! p:s/\%#=1[^0-7]//g +! p:s/\%#=2[^0-7]//g +! p:s/\%#=0\x//g +! p:s/\%#=1\x//g +! p:s/\%#=2\x//g +! p:s/\%#=0[0-9A-Fa-f]//g +! p:s/\%#=1[0-9A-Fa-f]//g +! p:s/\%#=2[0-9A-Fa-f]//g +! p:s/\%#=0\X//g +! p:s/\%#=1\X//g +! p:s/\%#=2\X//g +! p:s/\%#=0[^0-9A-Fa-f]//g +! p:s/\%#=1[^0-9A-Fa-f]//g +! p:s/\%#=2[^0-9A-Fa-f]//g +! p:s/\%#=0\w//g +! p:s/\%#=1\w//g +! p:s/\%#=2\w//g +! p:s/\%#=0[0-9A-Za-z_]//g +! p:s/\%#=1[0-9A-Za-z_]//g +! p:s/\%#=2[0-9A-Za-z_]//g +! p:s/\%#=0\W//g +! p:s/\%#=1\W//g +! p:s/\%#=2\W//g +! p:s/\%#=0[^0-9A-Za-z_]//g +! p:s/\%#=1[^0-9A-Za-z_]//g +! p:s/\%#=2[^0-9A-Za-z_]//g +! p:s/\%#=0\h//g +! p:s/\%#=1\h//g +! p:s/\%#=2\h//g +! p:s/\%#=0[A-Za-z_]//g +! p:s/\%#=1[A-Za-z_]//g +! p:s/\%#=2[A-Za-z_]//g +! p:s/\%#=0\H//g +! p:s/\%#=1\H//g +! p:s/\%#=2\H//g +! p:s/\%#=0[^A-Za-z_]//g +! p:s/\%#=1[^A-Za-z_]//g +! p:s/\%#=2[^A-Za-z_]//g +! p:s/\%#=0\a//g +! p:s/\%#=1\a//g +! p:s/\%#=2\a//g +! p:s/\%#=0[A-Za-z]//g +! p:s/\%#=1[A-Za-z]//g +! p:s/\%#=2[A-Za-z]//g +! p:s/\%#=0\A//g +! p:s/\%#=1\A//g +! p:s/\%#=2\A//g +! p:s/\%#=0[^A-Za-z]//g +! p:s/\%#=1[^A-Za-z]//g +! p:s/\%#=2[^A-Za-z]//g +! p:s/\%#=0\l//g +! p:s/\%#=1\l//g +! p:s/\%#=2\l//g +! p:s/\%#=0[a-z]//g +! p:s/\%#=1[a-z]//g +! p:s/\%#=2[a-z]//g +! p:s/\%#=0\L//g +! p:s/\%#=1\L//g +! p:s/\%#=2\L//g +! p:s/\%#=0[^a-z]//g +! p:s/\%#=1[^a-z]//g +! p:s/\%#=2[^a-z]//g +! p:s/\%#=0\u//g +! p:s/\%#=1\u//g +! p:s/\%#=2\u//g +! p:s/\%#=0[A-Z]//g +! p:s/\%#=1[A-Z]//g +! p:s/\%#=2[A-Z]//g +! p:s/\%#=0\U//g +! p:s/\%#=1\U//g +! p:s/\%#=2\U//g +! p:s/\%#=0[^A-Z]//g +! p:s/\%#=1[^A-Z]//g +! p:s/\%#=2[^A-Z]//g + :/^start-here/+1,$wq! test.out + ENDTEST + + start-here + !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé +*** ../vim-7.3.1110/src/testdir/test36.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test36.ok 2013-06-04 17:38:14.000000000 +0200 +*************** +*** 1,16 **** +--- 1,96 ---- + !"#$%&'()#+'-./:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ 0123456789 ++ 0123456789 ++ 0123456789 ++ 0123456789 ++ 0123456789 + 0123456789 + !"#$%&'()#+'-./89:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./89:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./89:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./89:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./89:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./89:;<=>?@ABCDEFGHIXYZ[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ 01234567 ++ 01234567 ++ 01234567 ++ 01234567 ++ 01234567 + 01234567 + !"#$%&'()#+'-./:;<=>?@GHIXYZ[\]^_`ghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./:;<=>?@GHIXYZ[\]^_`ghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./:;<=>?@GHIXYZ[\]^_`ghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./:;<=>?@GHIXYZ[\]^_`ghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./:;<=>?@GHIXYZ[\]^_`ghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./:;<=>?@GHIXYZ[\]^_`ghiwxyz{|}~€‚›¦±¼ÇÓé ++ 0123456789ABCDEFabcdef ++ 0123456789ABCDEFabcdef ++ 0123456789ABCDEFabcdef ++ 0123456789ABCDEFabcdef ++ 0123456789ABCDEFabcdef + 0123456789ABCDEFabcdef + !"#$%&'()#+'-./:;<=>?@[\]^`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./:;<=>?@[\]^`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./:;<=>?@[\]^`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./:;<=>?@[\]^`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./:;<=>?@[\]^`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./:;<=>?@[\]^`{|}~€‚›¦±¼ÇÓé ++ 0123456789ABCDEFGHIXYZ_abcdefghiwxyz ++ 0123456789ABCDEFGHIXYZ_abcdefghiwxyz ++ 0123456789ABCDEFGHIXYZ_abcdefghiwxyz ++ 0123456789ABCDEFGHIXYZ_abcdefghiwxyz ++ 0123456789ABCDEFGHIXYZ_abcdefghiwxyz + 0123456789ABCDEFGHIXYZ_abcdefghiwxyz + !"#$%&'()#+'-./0123456789:;<=>?@[\]^`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@[\]^`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@[\]^`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@[\]^`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@[\]^`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@[\]^`{|}~€‚›¦±¼ÇÓé ++ ABCDEFGHIXYZ_abcdefghiwxyz ++ ABCDEFGHIXYZ_abcdefghiwxyz ++ ABCDEFGHIXYZ_abcdefghiwxyz ++ ABCDEFGHIXYZ_abcdefghiwxyz ++ ABCDEFGHIXYZ_abcdefghiwxyz + ABCDEFGHIXYZ_abcdefghiwxyz + !"#$%&'()#+'-./0123456789:;<=>?@[\]^_`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@[\]^_`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@[\]^_`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@[\]^_`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@[\]^_`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@[\]^_`{|}~€‚›¦±¼ÇÓé ++ ABCDEFGHIXYZabcdefghiwxyz ++ ABCDEFGHIXYZabcdefghiwxyz ++ ABCDEFGHIXYZabcdefghiwxyz ++ ABCDEFGHIXYZabcdefghiwxyz ++ ABCDEFGHIXYZabcdefghiwxyz + ABCDEFGHIXYZabcdefghiwxyz + !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@ABCDEFGHIXYZ[\]^_`{|}~€‚›¦±¼ÇÓé ++ abcdefghiwxyz ++ abcdefghiwxyz ++ abcdefghiwxyz ++ abcdefghiwxyz ++ abcdefghiwxyz + abcdefghiwxyz + !"#$%&'()#+'-./0123456789:;<=>?@[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ !"#$%&'()#+'-./0123456789:;<=>?@[\]^_`abcdefghiwxyz{|}~€‚›¦±¼ÇÓé ++ ABCDEFGHIXYZ ++ ABCDEFGHIXYZ ++ ABCDEFGHIXYZ ++ ABCDEFGHIXYZ ++ ABCDEFGHIXYZ + ABCDEFGHIXYZ +*** ../vim-7.3.1110/src/version.c 2013-06-04 14:23:00.000000000 +0200 +--- src/version.c 2013-06-04 17:42:06.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1111, + /**/ + +-- +Ed's Radiator Shop: The Best Place in Town to Take a Leak. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4dd856f321480bcddf12bd5fd7a0155c0aa700c9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:27:55 +0200 Subject: [PATCH 1004/3340] - patchlevel 1112 --- 7.3.1112 | 311 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 311 insertions(+) create mode 100644 7.3.1112 diff --git a/7.3.1112 b/7.3.1112 new file mode 100644 index 00000000..015d3f8b --- /dev/null +++ b/7.3.1112 @@ -0,0 +1,311 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1112 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1112 +Problem: New regexp engine: \%V not supported. +Solution: Implement \%V. Add tests. +Files: src/regexp.c, src/regexp_nfa.c, src/testdir/test64.in, + src/testdir/test64.ok + + +*** ../vim-7.3.1111/src/regexp.c 2013-06-03 19:41:01.000000000 +0200 +--- src/regexp.c 2013-06-04 18:28:12.000000000 +0200 +*************** +*** 4165,4170 **** +--- 4165,4249 ---- + } + + #endif ++ #ifdef FEAT_VISUAL ++ static int reg_match_visual __ARGS((void)); ++ ++ /* ++ * Return TRUE if the current reginput position matches the Visual area. ++ */ ++ static int ++ reg_match_visual() ++ { ++ pos_T top, bot; ++ linenr_T lnum; ++ colnr_T col; ++ win_T *wp = reg_win == NULL ? curwin : reg_win; ++ int mode; ++ colnr_T start, end; ++ colnr_T start2, end2; ++ colnr_T cols; ++ ++ /* Check if the buffer is the current buffer. */ ++ if (reg_buf != curbuf || VIsual.lnum == 0) ++ return FALSE; ++ ++ if (VIsual_active) ++ { ++ if (lt(VIsual, wp->w_cursor)) ++ { ++ top = VIsual; ++ bot = wp->w_cursor; ++ } ++ else ++ { ++ top = wp->w_cursor; ++ bot = VIsual; ++ } ++ mode = VIsual_mode; ++ } ++ else ++ { ++ if (lt(curbuf->b_visual.vi_start, curbuf->b_visual.vi_end)) ++ { ++ top = curbuf->b_visual.vi_start; ++ bot = curbuf->b_visual.vi_end; ++ } ++ else ++ { ++ top = curbuf->b_visual.vi_end; ++ bot = curbuf->b_visual.vi_start; ++ } ++ mode = curbuf->b_visual.vi_mode; ++ } ++ lnum = reglnum + reg_firstlnum; ++ if (lnum < top.lnum || lnum > bot.lnum) ++ return FALSE; ++ ++ if (mode == 'v') ++ { ++ col = (colnr_T)(reginput - regline); ++ if ((lnum == top.lnum && col < top.col) ++ || (lnum == bot.lnum && col >= bot.col + (*p_sel != 'e'))) ++ return FALSE; ++ } ++ else if (mode == Ctrl_V) ++ { ++ getvvcol(wp, &top, &start, NULL, &end); ++ getvvcol(wp, &bot, &start2, NULL, &end2); ++ if (start2 < start) ++ start = start2; ++ if (end2 > end) ++ end = end2; ++ if (top.col == MAXCOL || bot.col == MAXCOL) ++ end = MAXCOL; ++ cols = win_linetabsize(wp, regline, (colnr_T)(reginput - regline)); ++ if (cols < start || cols > end - (*p_sel == 'e')) ++ return FALSE; ++ } ++ return TRUE; ++ } ++ #endif ++ + #define ADVANCE_REGINPUT() mb_ptr_adv(reginput) + + /* +*************** +*** 4347,4426 **** + + case RE_VISUAL: + #ifdef FEAT_VISUAL +! /* Check if the buffer is the current buffer. and whether the +! * position is inside the Visual area. */ +! if (reg_buf != curbuf || VIsual.lnum == 0) +! status = RA_NOMATCH; +! else +! { +! pos_T top, bot; +! linenr_T lnum; +! colnr_T col; +! win_T *wp = reg_win == NULL ? curwin : reg_win; +! int mode; +! +! if (VIsual_active) +! { +! if (lt(VIsual, wp->w_cursor)) +! { +! top = VIsual; +! bot = wp->w_cursor; +! } +! else +! { +! top = wp->w_cursor; +! bot = VIsual; +! } +! mode = VIsual_mode; +! } +! else +! { +! if (lt(curbuf->b_visual.vi_start, curbuf->b_visual.vi_end)) +! { +! top = curbuf->b_visual.vi_start; +! bot = curbuf->b_visual.vi_end; +! } +! else +! { +! top = curbuf->b_visual.vi_end; +! bot = curbuf->b_visual.vi_start; +! } +! mode = curbuf->b_visual.vi_mode; +! } +! lnum = reglnum + reg_firstlnum; +! col = (colnr_T)(reginput - regline); +! if (lnum < top.lnum || lnum > bot.lnum) +! status = RA_NOMATCH; +! else if (mode == 'v') +! { +! if ((lnum == top.lnum && col < top.col) +! || (lnum == bot.lnum +! && col >= bot.col + (*p_sel != 'e'))) +! status = RA_NOMATCH; +! } +! else if (mode == Ctrl_V) +! { +! colnr_T start, end; +! colnr_T start2, end2; +! colnr_T cols; +! +! getvvcol(wp, &top, &start, NULL, &end); +! getvvcol(wp, &bot, &start2, NULL, &end2); +! if (start2 < start) +! start = start2; +! if (end2 > end) +! end = end2; +! if (top.col == MAXCOL || bot.col == MAXCOL) +! end = MAXCOL; +! cols = win_linetabsize(wp, +! regline, (colnr_T)(reginput - regline)); +! if (cols < start || cols > end - (*p_sel == 'e')) +! status = RA_NOMATCH; +! } +! } +! #else +! status = RA_NOMATCH; + #endif + break; + + case RE_LNUM: +--- 4426,4434 ---- + + case RE_VISUAL: + #ifdef FEAT_VISUAL +! if (!reg_match_visual()) + #endif ++ status = RA_NOMATCH; + break; + + case RE_LNUM: +*** ../vim-7.3.1111/src/regexp_nfa.c 2013-06-04 17:47:00.000000000 +0200 +--- src/regexp_nfa.c 2013-06-04 18:22:04.000000000 +0200 +*************** +*** 178,183 **** +--- 178,184 ---- + NFA_VCOL, /* Match cursor virtual column */ + NFA_VCOL_GT, /* Match > cursor virtual column */ + NFA_VCOL_LT, /* Match < cursor virtual column */ ++ NFA_VISUAL, /* Match Visual area */ + + NFA_FIRST_NL = NFA_ANY + ADD_NL, + NFA_LAST_NL = NFA_NUPPER + ADD_NL, +*************** +*** 960,967 **** + break; + + case 'V': +! /* TODO: not supported yet */ +! return FAIL; + break; + + case '[': +--- 961,967 ---- + break; + + case 'V': +! EMIT(NFA_VISUAL); + break; + + case '[': +*************** +*** 4731,4736 **** +--- 4731,4743 ---- + if (result) + addstate_here(thislist, t->state->out, &t->subs, + t->pim, &listidx); ++ break; ++ ++ case NFA_VISUAL: ++ result = reg_match_visual(); ++ if (result) ++ addstate_here(thislist, t->state->out, &t->subs, ++ t->pim, &listidx); + break; + + default: /* regular character */ +*** ../vim-7.3.1111/src/testdir/test64.in 2013-06-02 16:07:05.000000000 +0200 +--- src/testdir/test64.in 2013-06-04 18:07:59.000000000 +0200 +*************** +*** 458,463 **** +--- 458,471 ---- + :.yank + Gop:" + :" ++ :" Check matching Visual area ++ /^Visual: ++ jfxvfx:s/\%Ve/E/g ++ jV:s/\%Va/A/g ++ jfxfxj:s/\%Vo/O/g ++ :/^Visual/+1,/^Visual/+4yank ++ Gop:" ++ :" + :" Check patterns matching cursor position. + :func! Postest() + new +*************** +*** 520,523 **** +--- 528,537 ---- + asdfasd Date: Fri, 14 Jun 2013 00:27:57 +0200 Subject: [PATCH 1005/3340] - patchlevel 1113 --- 7.3.1113 | 266 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 266 insertions(+) create mode 100644 7.3.1113 diff --git a/7.3.1113 b/7.3.1113 new file mode 100644 index 00000000..c459295c --- /dev/null +++ b/7.3.1113 @@ -0,0 +1,266 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1113 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1113 +Problem: New regexp engine: \%'m not supported. +Solution: Implement \%'m. Add tests. +Files: src/regexp.c, src/regexp_nfa.c, src/testdir/test64.in, + src/testdir/test64.ok + + +*** ../vim-7.3.1112/src/regexp.c 2013-06-04 18:28:45.000000000 +0200 +--- src/regexp.c 2013-06-04 21:06:13.000000000 +0200 +*************** +*** 4401,4408 **** + break; + + case RE_MARK: +! /* Compare the mark position to the match position. NOTE: Always +! * uses the current buffer. */ + { + int mark = OPERAND(scan)[0]; + int cmp = OPERAND(scan)[1]; +--- 4401,4407 ---- + break; + + case RE_MARK: +! /* Compare the mark position to the match position. */ + { + int mark = OPERAND(scan)[0]; + int cmp = OPERAND(scan)[1]; +*************** +*** 4410,4416 **** + + pos = getmark_buf(reg_buf, mark, FALSE); + if (pos == NULL /* mark doesn't exist */ +! || pos->lnum <= 0 /* mark isn't set (in curbuf) */ + || (pos->lnum == reglnum + reg_firstlnum + ? (pos->col == (colnr_T)(reginput - regline) + ? (cmp == '<' || cmp == '>') +--- 4409,4415 ---- + + pos = getmark_buf(reg_buf, mark, FALSE); + if (pos == NULL /* mark doesn't exist */ +! || pos->lnum <= 0 /* mark isn't set in reg_buf */ + || (pos->lnum == reglnum + reg_firstlnum + ? (pos->col == (colnr_T)(reginput - regline) + ? (cmp == '<' || cmp == '>') +*** ../vim-7.3.1112/src/regexp_nfa.c 2013-06-04 18:28:45.000000000 +0200 +--- src/regexp_nfa.c 2013-06-04 21:19:11.000000000 +0200 +*************** +*** 178,183 **** +--- 178,186 ---- + NFA_VCOL, /* Match cursor virtual column */ + NFA_VCOL_GT, /* Match > cursor virtual column */ + NFA_VCOL_LT, /* Match < cursor virtual column */ ++ NFA_MARK, /* Match mark */ ++ NFA_MARK_GT, /* Match > mark */ ++ NFA_MARK_LT, /* Match < mark */ + NFA_VISUAL, /* Match Visual area */ + + NFA_FIRST_NL = NFA_ANY + ADD_NL, +*************** +*** 984,1002 **** + { + EMIT(n); + if (c == 'l') + EMIT(cmp == '<' ? NFA_LNUM_LT : +! cmp == '>' ? NFA_LNUM_GT : NFA_LNUM); + else if (c == 'c') + EMIT(cmp == '<' ? NFA_COL_LT : +! cmp == '>' ? NFA_COL_GT : NFA_COL); + else + EMIT(cmp == '<' ? NFA_VCOL_LT : +! cmp == '>' ? NFA_VCOL_GT : NFA_VCOL); + break; + } +- else if (c == '\'') +- /* TODO: \%'m not supported yet */ +- return FAIL; + } + syntax_error = TRUE; + EMSGN(_("E867: (NFA) Unknown operator '\\%%%c'"), +--- 987,1013 ---- + { + EMIT(n); + if (c == 'l') ++ /* \%{n}l \%{n}l */ + EMIT(cmp == '<' ? NFA_LNUM_LT : +! cmp == '>' ? NFA_LNUM_GT : NFA_LNUM); + else if (c == 'c') ++ /* \%{n}c \%{n}c */ + EMIT(cmp == '<' ? NFA_COL_LT : +! cmp == '>' ? NFA_COL_GT : NFA_COL); + else ++ /* \%{n}v \%{n}v */ + EMIT(cmp == '<' ? NFA_VCOL_LT : +! cmp == '>' ? NFA_VCOL_GT : NFA_VCOL); +! break; +! } +! else if (c == '\'' && n == 0) +! { +! /* \%'m \%<'m \%>'m */ +! EMIT(getchr()); +! EMIT(cmp == '<' ? NFA_MARK_LT : +! cmp == '>' ? NFA_MARK_GT : NFA_MARK); + break; + } + } + syntax_error = TRUE; + EMSGN(_("E867: (NFA) Unknown operator '\\%%%c'"), +*************** +*** 1931,1936 **** +--- 1942,1962 ---- + case NFA_BOW: STRCPY(code, "NFA_BOW "); break; + case NFA_EOF: STRCPY(code, "NFA_EOF "); break; + case NFA_BOF: STRCPY(code, "NFA_BOF "); break; ++ case NFA_LNUM: STRCPY(code, "NFA_LNUM "); break; ++ case NFA_LNUM_GT: STRCPY(code, "NFA_LNUM_GT "); break; ++ case NFA_LNUM_LT: STRCPY(code, "NFA_LNUM_LT "); break; ++ case NFA_COL: STRCPY(code, "NFA_COL "); break; ++ case NFA_COL_GT: STRCPY(code, "NFA_COL_GT "); break; ++ case NFA_COL_LT: STRCPY(code, "NFA_COL_LT "); break; ++ case NFA_VCOL: STRCPY(code, "NFA_VCOL "); break; ++ case NFA_VCOL_GT: STRCPY(code, "NFA_VCOL_GT "); break; ++ case NFA_VCOL_LT: STRCPY(code, "NFA_VCOL_LT "); break; ++ case NFA_MARK: STRCPY(code, "NFA_MARK "); break; ++ case NFA_MARK_GT: STRCPY(code, "NFA_MARK_GT "); break; ++ case NFA_MARK_LT: STRCPY(code, "NFA_MARK_LT "); break; ++ case NFA_CURSOR: STRCPY(code, "NFA_CURSOR "); break; ++ case NFA_VISUAL: STRCPY(code, "NFA_VISUAL "); break; ++ + case NFA_STAR: STRCPY(code, "NFA_STAR "); break; + case NFA_STAR_NONGREEDY: STRCPY(code, "NFA_STAR_NONGREEDY "); break; + case NFA_QUEST: STRCPY(code, "NFA_QUEST"); break; +*************** +*** 2715,2720 **** +--- 2741,2749 ---- + case NFA_COL: + case NFA_COL_GT: + case NFA_COL_LT: ++ case NFA_MARK: ++ case NFA_MARK_GT: ++ case NFA_MARK_LT: + if (nfa_calc_size == TRUE) + { + nstate += 1; +*************** +*** 2724,2730 **** + s = alloc_state(*p, NULL, NULL); + if (s == NULL) + goto theend; +! s->val = e1.start->c; + PUSH(frag(s, list1(&s->out))); + break; + +--- 2753,2759 ---- + s = alloc_state(*p, NULL, NULL); + if (s == NULL) + goto theend; +! s->val = e1.start->c; /* lnum, col or mark name */ + PUSH(frag(s, list1(&s->out))); + break; + +*************** +*** 4723,4728 **** +--- 4752,4781 ---- + t->pim, &listidx); + break; + ++ case NFA_MARK: ++ case NFA_MARK_GT: ++ case NFA_MARK_LT: ++ { ++ pos_T *pos = getmark_buf(reg_buf, t->state->val, FALSE); ++ ++ /* Compare the mark position to the match position. */ ++ result = (pos != NULL /* mark doesn't exist */ ++ && pos->lnum > 0 /* mark isn't set in reg_buf */ ++ && (pos->lnum == reglnum + reg_firstlnum ++ ? (pos->col == (colnr_T)(reginput - regline) ++ ? t->state->c == NFA_MARK ++ : (pos->col < (colnr_T)(reginput - regline) ++ ? t->state->c == NFA_MARK_GT ++ : t->state->c == NFA_MARK_LT)) ++ : (pos->lnum < reglnum + reg_firstlnum ++ ? t->state->c == NFA_MARK_GT ++ : t->state->c == NFA_MARK_LT))); ++ if (result) ++ addstate_here(thislist, t->state->out, &t->subs, ++ t->pim, &listidx); ++ break; ++ } ++ + case NFA_CURSOR: + result = (reg_win != NULL + && (reglnum + reg_firstlnum == reg_win->w_cursor.lnum) +*** ../vim-7.3.1112/src/testdir/test64.in 2013-06-04 18:28:45.000000000 +0200 +--- src/testdir/test64.in 2013-06-04 21:20:13.000000000 +0200 +*************** +*** 466,471 **** +--- 466,478 ---- + :/^Visual/+1,/^Visual/+4yank + Gop:" + :" ++ :" Check matching marks ++ /^Marks: ++ jfSmsfEme:.-4,.+6s/.\%>'s.*\%<'e../here/ ++ jfSmsj0fEme:.-4,.+6s/.\%>'s\_.*\%<'e../again/ ++ :/^Marks:/+1,/^Marks:/+3yank ++ Gop:" ++ :" + :" Check patterns matching cursor position. + :func! Postest() + new +*************** +*** 534,537 **** +--- 541,549 ---- + oooxofor foroxooo + oooxofor foroxooo + ++ Marks: ++ asdfSasdfsadfEasdf ++ asdfSas ++ dfsadfEasdf ++ + Results of test64: +*** ../vim-7.3.1112/src/testdir/test64.ok 2013-06-04 18:28:45.000000000 +0200 +--- src/testdir/test64.ok 2013-06-04 20:55:08.000000000 +0200 +*************** +*** 862,867 **** +--- 862,871 ---- + AndAxAnd AndAxAnd + oooxOfOr fOrOxooo + oooxOfOr fOrOxooo ++ ++ asdfhereasdf ++ asdfagainasdf ++ + -0- + ffo + bob +*** ../vim-7.3.1112/src/version.c 2013-06-04 18:28:45.000000000 +0200 +--- src/version.c 2013-06-04 21:25:20.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1113, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +89. In addition to your e-mail address being on your business + cards you even have your own domain. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ce7d1bf4a29dd02e2429170abc4b804ad0d2f826 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:27:58 +0200 Subject: [PATCH 1006/3340] - patchlevel 1114 --- 7.3.1114 | 59 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.1114 diff --git a/7.3.1114 b/7.3.1114 new file mode 100644 index 00000000..a38d57d0 --- /dev/null +++ b/7.3.1114 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1114 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1114 (after 7.3.1110) +Problem: Can't build without the syntax feature. +Solution: Add #ifdefs. (Erik Falor) +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1113/src/regexp_nfa.c 2013-06-04 21:27:33.000000000 +0200 +--- src/regexp_nfa.c 2013-06-04 21:39:30.000000000 +0200 +*************** +*** 3907,3913 **** +--- 3907,3915 ---- + if (c > 0) + return 99; + if ((c >= NFA_MOPEN && c <= NFA_MOPEN9) ++ #ifdef FEAT_SYN_HL + || (c >= NFA_ZOPEN && c <= NFA_ZOPEN9) ++ #endif + || c == NFA_NOPEN) + return failure_chance(state->out, depth + 1); + /* something else */ +*************** +*** 4201,4207 **** +--- 4203,4211 ---- + * Otherwise first do the one that has the highest chance + * of failing. */ + if ((cout >= NFA_MCLOSE && cout <= NFA_MCLOSE9) ++ #ifdef FEAT_SYN_HL + || (cout >= NFA_ZCLOSE && cout <= NFA_ZCLOSE9) ++ #endif + || cout == NFA_NCLOSE + || t->pim != NULL + || (t->state->c != NFA_START_INVISIBLE_BEFORE +*** ../vim-7.3.1113/src/version.c 2013-06-04 21:27:33.000000000 +0200 +--- src/version.c 2013-06-04 21:41:41.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1114, + /**/ + +-- +From "know your smileys": + y:-) Bad toupee + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6012b0a305c1abbecf8efc2f5fede551b227665e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:27:59 +0200 Subject: [PATCH 1007/3340] - patchlevel 1115 --- 7.3.1115 | 284 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 284 insertions(+) create mode 100644 7.3.1115 diff --git a/7.3.1115 b/7.3.1115 new file mode 100644 index 00000000..fa75d998 --- /dev/null +++ b/7.3.1115 @@ -0,0 +1,284 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1115 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1115 +Problem: Many users don't like the cursor line number when 'relativenumber' + is set. +Solution: Have four combinations with 'number' and 'relativenumber'. + (Christian Brabandt) +Files: runtime/doc/options.txt, src/option.c, src/screen.c, + src/testdir/test89.in, src/testdir/test89.ok + + +*** ../vim-7.3.1114/runtime/doc/options.txt 2013-03-19 16:46:59.000000000 +0100 +--- runtime/doc/options.txt 2013-06-04 22:01:35.000000000 +0200 +*************** +*** 5077,5084 **** + number. + When a long, wrapped line doesn't start with the first character, '-' + characters are put before the number. +! See |hl-LineNr| for the highlighting used for the number. +! When setting this option, 'relativenumber' is reset. + + *'numberwidth'* *'nuw'* + 'numberwidth' 'nuw' number (Vim default: 4 Vi default: 8) +--- 5130,5149 ---- + number. + When a long, wrapped line doesn't start with the first character, '-' + characters are put before the number. +! See |hl-LineNr| and |hl-CursorLineNr| for the highlighting used for +! the number. +! *number_relativenumber* +! The 'relativenumber' option changes the displayed number to be +! relative to the cursor. Together with 'number' there are these +! four combinations (cursor in line 3): +! +! 'nonu' 'nu' 'nonu' 'nu' +! 'nornu' 'nornu' 'rnu' 'rnu' +! +! |apple | 1 apple | 2 apple | 2 apple +! |pear | 2 pear | 1 pear | 1 pear +! |nobody | 3 nobody | 0 nobody |3 nobody +! |there | 4 there | 1 there | 1 there + + *'numberwidth'* *'nuw'* + 'numberwidth' 'nuw' number (Vim default: 4 Vi default: 8) +*************** +*** 5484,5491 **** + number. + When a long, wrapped line doesn't start with the first character, '-' + characters are put before the number. +! See |hl-LineNr| for the highlighting used for the number. +! When setting this option, 'number' is reset. + + *'remap'* *'noremap'* + 'remap' boolean (default on) +--- 5556,5567 ---- + number. + When a long, wrapped line doesn't start with the first character, '-' + characters are put before the number. +! See |hl-LineNr| and |hl-CursorLineNr| for the highlighting used for +! the number. +! +! The number in front of the cursor line also depends on the value of +! 'number', see |number_relativenumber| for all combinations of the two +! options. + + *'remap'* *'noremap'* + 'remap' boolean (default on) +*** ../vim-7.3.1114/src/option.c 2013-05-21 22:38:14.000000000 +0200 +--- src/option.c 2013-06-04 21:52:13.000000000 +0200 +*************** +*** 7647,7681 **** + } + #endif + +- /* If 'number' is set, reset 'relativenumber'. */ +- /* If 'relativenumber' is set, reset 'number'. */ +- else if ((int *)varp == &curwin->w_p_nu && curwin->w_p_nu) +- { +- curwin->w_p_rnu = FALSE; +- +- /* Only reset the global value if the own value is set globally. */ +- if (((opt_flags & (OPT_LOCAL | OPT_GLOBAL)) == 0)) +- curwin->w_allbuf_opt.wo_rnu = FALSE; +- } +- else if ((int *)varp == &curwin->w_p_rnu && curwin->w_p_rnu) +- { +- curwin->w_p_nu = FALSE; +- +- /* Only reset the global value if the own value is set globally. */ +- if (((opt_flags & (OPT_LOCAL | OPT_GLOBAL)) == 0)) +- curwin->w_allbuf_opt.wo_nu = FALSE; +- } +- else if ((int *)varp == &curwin->w_allbuf_opt.wo_nu +- && curwin->w_allbuf_opt.wo_nu) +- { +- curwin->w_allbuf_opt.wo_rnu = FALSE; +- } +- else if ((int *)varp == &curwin->w_allbuf_opt.wo_rnu +- && curwin->w_allbuf_opt.wo_rnu) +- { +- curwin->w_allbuf_opt.wo_nu = FALSE; +- } +- + else if ((int *)varp == &curbuf->b_p_ro) + { + /* when 'readonly' is reset globally, also reset readonlymode */ +--- 7647,7652 ---- +*** ../vim-7.3.1114/src/screen.c 2013-05-06 04:21:35.000000000 +0200 +--- src/screen.c 2013-06-04 22:04:39.000000000 +0200 +*************** +*** 2329,2343 **** + if (len > w + 1) + len = w + 1; + +! if (wp->w_p_nu) +! /* 'number' */ + num = (long)lnum; + else + { + /* 'relativenumber', don't use negative numbers */ + num = labs((long)get_cursor_rel_lnum(wp, lnum)); +! if (num == 0) + { + num = lnum; + fmt = "%-*ld "; + } +--- 2329,2345 ---- + if (len > w + 1) + len = w + 1; + +! if (wp->w_p_nu && !wp->w_p_rnu) +! /* 'number' + 'norelativenumber' */ + num = (long)lnum; + else + { + /* 'relativenumber', don't use negative numbers */ + num = labs((long)get_cursor_rel_lnum(wp, lnum)); +! if (num == 0 && wp->w_p_nu && wp->w_p_rnu) + { ++ /* 'number' + 'relativenumber': cursor line shows absolute ++ * line number */ + num = lnum; + fmt = "%-*ld "; + } +*************** +*** 3499,3513 **** + long num; + char *fmt = "%*ld "; + +! if (wp->w_p_nu) +! /* 'number' */ + num = (long)lnum; + else + { + /* 'relativenumber', don't use negative numbers */ + num = labs((long)get_cursor_rel_lnum(wp, lnum)); +! if (num == 0) + { + num = lnum; + fmt = "%-*ld "; + } +--- 3501,3516 ---- + long num; + char *fmt = "%*ld "; + +! if (wp->w_p_nu && !wp->w_p_rnu) +! /* 'number' + 'norelativenumber' */ + num = (long)lnum; + else + { + /* 'relativenumber', don't use negative numbers */ + num = labs((long)get_cursor_rel_lnum(wp, lnum)); +! if (num == 0 && wp->w_p_nu && wp->w_p_rnu) + { ++ /* 'number' + 'relativenumber' */ + num = lnum; + fmt = "%-*ld "; + } +*************** +*** 10260,10266 **** + int n; + linenr_T lnum; + +! lnum = wp->w_buffer->b_ml.ml_line_count; + + if (lnum == wp->w_nrwidth_line_count) + return wp->w_nrwidth_width; +--- 10263,10274 ---- + int n; + linenr_T lnum; + +! if (wp->w_p_rnu && !wp->w_p_nu) +! /* cursor line shows "0" */ +! lnum = wp->w_height; +! else +! /* cursor line shows absolute line number */ +! lnum = wp->w_buffer->b_ml.ml_line_count; + + if (lnum == wp->w_nrwidth_line_count) + return wp->w_nrwidth_width; +*** ../vim-7.3.1114/src/testdir/test89.in 2013-04-24 15:47:11.000000000 +0200 +--- src/testdir/test89.in 2013-06-04 21:59:01.000000000 +0200 +*************** +*** 1,4 **** +--- 1,6 ---- + Some tests for setting 'number' and 'relativenumber' ++ This is not all that useful now that the options are no longer reset when ++ setting the other. + + STARTTEST + :so small.vim +*** ../vim-7.3.1114/src/testdir/test89.ok 2013-03-13 20:42:28.000000000 +0100 +--- src/testdir/test89.ok 2013-06-04 21:58:09.000000000 +0200 +*************** +*** 1,9 **** + results: + +! nonumber + relativenumber + +! nonumber + relativenumber + :setlocal must NOT reset the other global value + +--- 1,9 ---- + results: + +! number + relativenumber + +! number + relativenumber + :setlocal must NOT reset the other global value + +*************** +*** 12,22 **** + relativenumber + :setglobal MUST reset the other global value + +! nonumber + +! norelativenumber + :set MUST reset the other global value + +! nonumber + +! norelativenumber +--- 12,22 ---- + relativenumber + :setglobal MUST reset the other global value + +! number + +! relativenumber + :set MUST reset the other global value + +! number + +! relativenumber +*** ../vim-7.3.1114/src/version.c 2013-06-04 21:42:19.000000000 +0200 +--- src/version.c 2013-06-04 22:11:05.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1115, + /**/ + +-- +From "know your smileys": + :----} You lie like Pinocchio + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bdfe313aeb3b0097556199e580093c2346e755f6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:00 +0200 Subject: [PATCH 1008/3340] - patchlevel 1116 --- 7.3.1116 | 91 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 91 insertions(+) create mode 100644 7.3.1116 diff --git a/7.3.1116 b/7.3.1116 new file mode 100644 index 00000000..cbc448e9 --- /dev/null +++ b/7.3.1116 @@ -0,0 +1,91 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1116 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1116 +Problem: Can't build without Visual mode. +Solution: Add #ifdefs. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1115/src/regexp_nfa.c 2013-06-04 21:42:19.000000000 +0200 +--- src/regexp_nfa.c 2013-06-05 11:01:40.000000000 +0200 +*************** +*** 181,187 **** +--- 181,189 ---- + NFA_MARK, /* Match mark */ + NFA_MARK_GT, /* Match > mark */ + NFA_MARK_LT, /* Match < mark */ ++ #ifdef FEAT_VISUAL + NFA_VISUAL, /* Match Visual area */ ++ #endif + + NFA_FIRST_NL = NFA_ANY + ADD_NL, + NFA_LAST_NL = NFA_NUPPER + ADD_NL, +*************** +*** 963,971 **** +--- 965,975 ---- + EMIT(NFA_CURSOR); + break; + ++ #ifdef FEAT_VISUAL + case 'V': + EMIT(NFA_VISUAL); + break; ++ #endif + + case '[': + /* TODO: \%[abc] not supported yet */ +*************** +*** 1955,1961 **** +--- 1959,1967 ---- + case NFA_MARK_GT: STRCPY(code, "NFA_MARK_GT "); break; + case NFA_MARK_LT: STRCPY(code, "NFA_MARK_LT "); break; + case NFA_CURSOR: STRCPY(code, "NFA_CURSOR "); break; ++ #ifdef FEAT_VISUAL + case NFA_VISUAL: STRCPY(code, "NFA_VISUAL "); break; ++ #endif + + case NFA_STAR: STRCPY(code, "NFA_STAR "); break; + case NFA_STAR_NONGREEDY: STRCPY(code, "NFA_STAR_NONGREEDY "); break; +*************** +*** 4790,4801 **** +--- 4796,4809 ---- + t->pim, &listidx); + break; + ++ #ifdef FEAT_VISUAL + case NFA_VISUAL: + result = reg_match_visual(); + if (result) + addstate_here(thislist, t->state->out, &t->subs, + t->pim, &listidx); + break; ++ #endif + + default: /* regular character */ + { +*** ../vim-7.3.1115/src/version.c 2013-06-04 22:13:45.000000000 +0200 +--- src/version.c 2013-06-04 23:42:50.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1116, + /**/ + +-- +From "know your smileys": + ;-0 Can't find shift key + ,-9 Kann Umschalttaste nicht finden + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7918ec00154ed66982feae71f5bd762652908cdb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:01 +0200 Subject: [PATCH 1009/3340] - patchlevel 1117 --- 7.3.1117 | 337 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 337 insertions(+) create mode 100644 7.3.1117 diff --git a/7.3.1117 b/7.3.1117 new file mode 100644 index 00000000..524cafe3 --- /dev/null +++ b/7.3.1117 @@ -0,0 +1,337 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1117 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1117 +Problem: New regexp engine: \%[abc] not supported. +Solution: Implement \%[abc]. Add tests. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1116/src/regexp_nfa.c 2013-06-05 11:01:59.000000000 +0200 +--- src/regexp_nfa.c 2013-06-05 11:03:19.000000000 +0200 +*************** +*** 61,66 **** +--- 61,67 ---- + NFA_COMPOSING, /* Next nodes in NFA are part of the + composing multibyte char */ + NFA_END_COMPOSING, /* End of a composing char in the NFA */ ++ NFA_OPT_CHARS, /* \%[abc] */ + + /* The following are used only in the postfix form, not in the NFA */ + NFA_PREV_ATOM_NO_WIDTH, /* Used for \@= */ +*************** +*** 972,979 **** + #endif + + case '[': +! /* TODO: \%[abc] not supported yet */ +! return FAIL; + + default: + { +--- 973,993 ---- + #endif + + case '[': +! { +! int n; +! +! /* \%[abc] */ +! for (n = 0; (c = getchr()) != ']'; ++n) +! { +! if (c == NUL) +! EMSG2_RET_FAIL(_(e_missing_sb), +! reg_magic == MAGIC_ALL); +! EMIT(c); +! } +! EMIT(NFA_OPT_CHARS); +! EMIT(n); +! break; +! } + + default: + { +*************** +*** 989,995 **** + } + if (c == 'l' || c == 'c' || c == 'v') + { +- EMIT(n); + if (c == 'l') + /* \%{n}l \%{n}l */ + EMIT(cmp == '<' ? NFA_LNUM_LT : +--- 1003,1008 ---- +*************** +*** 1002,1015 **** + /* \%{n}v \%{n}v */ + EMIT(cmp == '<' ? NFA_VCOL_LT : + cmp == '>' ? NFA_VCOL_GT : NFA_VCOL); + break; + } + else if (c == '\'' && n == 0) + { + /* \%'m \%<'m \%>'m */ +- EMIT(getchr()); + EMIT(cmp == '<' ? NFA_MARK_LT : + cmp == '>' ? NFA_MARK_GT : NFA_MARK); + break; + } + } +--- 1015,1029 ---- + /* \%{n}v \%{n}v */ + EMIT(cmp == '<' ? NFA_VCOL_LT : + cmp == '>' ? NFA_VCOL_GT : NFA_VCOL); ++ EMIT(n); + break; + } + else if (c == '\'' && n == 0) + { + /* \%'m \%<'m \%>'m */ + EMIT(cmp == '<' ? NFA_MARK_LT : + cmp == '>' ? NFA_MARK_GT : NFA_MARK); ++ EMIT(getchr()); + break; + } + } +*************** +*** 1885,1890 **** +--- 1899,1905 ---- + + case NFA_COMPOSING: STRCPY(code, "NFA_COMPOSING"); break; + case NFA_END_COMPOSING: STRCPY(code, "NFA_END_COMPOSING"); break; ++ case NFA_OPT_CHARS: STRCPY(code, "NFA_OPT_CHARS"); break; + + case NFA_MOPEN: + case NFA_MOPEN1: +*************** +*** 2558,2567 **** +--- 2573,2621 ---- + PUSH(frag(s, list1(&s->out))); + break; + ++ case NFA_OPT_CHARS: ++ { ++ int n; ++ ++ /* \%[abc] */ ++ n = *++p; /* get number of characters */ ++ if (nfa_calc_size == TRUE) ++ { ++ nstate += n; ++ break; ++ } ++ e1.out = NULL; /* stores list with out1's */ ++ s1 = NULL; /* previous NFA_SPLIT to connect to */ ++ while (n-- > 0) ++ { ++ e = POP(); /* get character */ ++ s = alloc_state(NFA_SPLIT, e.start, NULL); ++ if (s == NULL) ++ goto theend; ++ if (e1.out == NULL) ++ e1 = e; ++ patch(e.out, s1); ++ append(e1.out, list1(&s->out1)); ++ s1 = s; ++ } ++ PUSH(frag(s, e1.out)); ++ break; ++ } ++ + case NFA_PREV_ATOM_NO_WIDTH: + case NFA_PREV_ATOM_NO_WIDTH_NEG: + case NFA_PREV_ATOM_JUST_BEFORE: + case NFA_PREV_ATOM_JUST_BEFORE_NEG: ++ { ++ int neg = (*p == NFA_PREV_ATOM_NO_WIDTH_NEG ++ || *p == NFA_PREV_ATOM_JUST_BEFORE_NEG); ++ int before = (*p == NFA_PREV_ATOM_JUST_BEFORE ++ || *p == NFA_PREV_ATOM_JUST_BEFORE_NEG); ++ int n; ++ ++ if (before) ++ n = *++p; /* get the count */ ++ + /* The \@= operator: match the preceding atom with zero width. + * The \@! operator: no match for the preceding atom. + * The \@<= operator: match for the preceding atom. +*************** +*** 2583,2603 **** + s = alloc_state(NFA_START_INVISIBLE, e.start, s1); + if (s == NULL) + goto theend; +! if (*p == NFA_PREV_ATOM_NO_WIDTH_NEG +! || *p == NFA_PREV_ATOM_JUST_BEFORE_NEG) + { + s->negated = TRUE; + s1->negated = TRUE; + } +! if (*p == NFA_PREV_ATOM_JUST_BEFORE +! || *p == NFA_PREV_ATOM_JUST_BEFORE_NEG) + { +! s->val = *++p; /* get the count */ + ++s->c; /* NFA_START_INVISIBLE -> NFA_START_INVISIBLE_BEFORE */ + } + + PUSH(frag(s, list1(&s1->out))); + break; + + #ifdef FEAT_MBYTE + case NFA_COMPOSING: /* char with composing char */ +--- 2637,2656 ---- + s = alloc_state(NFA_START_INVISIBLE, e.start, s1); + if (s == NULL) + goto theend; +! if (neg) + { + s->negated = TRUE; + s1->negated = TRUE; + } +! if (before) + { +! s->val = n; /* store the count */ + ++s->c; /* NFA_START_INVISIBLE -> NFA_START_INVISIBLE_BEFORE */ + } + + PUSH(frag(s, list1(&s1->out))); + break; ++ } + + #ifdef FEAT_MBYTE + case NFA_COMPOSING: /* char with composing char */ +*************** +*** 2750,2767 **** + case NFA_MARK: + case NFA_MARK_GT: + case NFA_MARK_LT: + if (nfa_calc_size == TRUE) + { + nstate += 1; + break; + } +! e1 = POP(); +! s = alloc_state(*p, NULL, NULL); + if (s == NULL) + goto theend; +! s->val = e1.start->c; /* lnum, col or mark name */ + PUSH(frag(s, list1(&s->out))); + break; + + case NFA_ZSTART: + case NFA_ZEND: +--- 2803,2823 ---- + case NFA_MARK: + case NFA_MARK_GT: + case NFA_MARK_LT: ++ { ++ int n = *++p; /* lnum, col or mark name */ ++ + if (nfa_calc_size == TRUE) + { + nstate += 1; + break; + } +! s = alloc_state(p[-1], NULL, NULL); + if (s == NULL) + goto theend; +! s->val = n; + PUSH(frag(s, list1(&s->out))); + break; ++ } + + case NFA_ZSTART: + case NFA_ZEND: +*** ../vim-7.3.1116/src/testdir/test64.in 2013-06-04 21:27:33.000000000 +0200 +--- src/testdir/test64.in 2013-06-04 23:45:44.000000000 +0200 +*************** +*** 352,357 **** +--- 352,370 ---- + :call add(tl, [2, '\%u0020', 'yes no', ' ']) + :call add(tl, [2, '\%U00000020', 'yes no', ' ']) + :" ++ :""""" \%[abc] ++ :call add(tl, [2, 'foo\%[bar]', 'fobar']) ++ :call add(tl, [2, 'foo\%[bar]', 'foobar', 'foobar']) ++ :call add(tl, [2, 'foo\%[bar]', 'fooxx', 'foo']) ++ :call add(tl, [2, 'foo\%[bar]', 'foobxx', 'foob']) ++ :call add(tl, [2, 'foo\%[bar]', 'foobaxx', 'fooba']) ++ :call add(tl, [2, 'foo\%[bar]', 'foobarxx', 'foobar']) ++ :call add(tl, [2, 'foo\%[bar]x', 'foobxx', 'foobx']) ++ :call add(tl, [2, 'foo\%[bar]x', 'foobarxx', 'foobarx']) ++ :call add(tl, [2, '\%[bar]x', 'barxx', 'barx']) ++ :call add(tl, [2, '\%[bar]x', 'bxx', 'bx']) ++ :call add(tl, [2, '\%[bar]x', 'xxx', 'x']) ++ :" + :"""" Alternatives, must use first longest match + :call add(tl, [2, 'goo\|go', 'google', 'goo']) + :call add(tl, [2, '\ Date: Fri, 14 Jun 2013 00:28:02 +0200 Subject: [PATCH 1010/3340] - patchlevel 1118 --- 7.3.1118 | 201 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 201 insertions(+) create mode 100644 7.3.1118 diff --git a/7.3.1118 b/7.3.1118 new file mode 100644 index 00000000..84779d4e --- /dev/null +++ b/7.3.1118 @@ -0,0 +1,201 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1118 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1118 +Problem: Match failure rate is not very specific. +Solution: Tune the failure rate for match items. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1117/src/regexp_nfa.c 2013-06-05 11:05:12.000000000 +0200 +--- src/regexp_nfa.c 2013-06-05 11:41:09.000000000 +0200 +*************** +*** 3956,3980 **** + if (depth > 4) + return 1; + +! if (c == NFA_SPLIT) + { +! if (state->out->c == NFA_SPLIT || state->out1->c == NFA_SPLIT) + return 1; +! l = failure_chance(state->out, depth + 1); +! r = failure_chance(state->out1, depth + 1); +! return l < r ? l : r; +! } +! if (c == NFA_ANY) +! return 1; +! if (c > 0) +! return 99; +! if ((c >= NFA_MOPEN && c <= NFA_MOPEN9) + #ifdef FEAT_SYN_HL +! || (c >= NFA_ZOPEN && c <= NFA_ZOPEN9) + #endif +! || c == NFA_NOPEN) +! return failure_chance(state->out, depth + 1); +! /* something else */ + return 50; + } + +--- 3956,4093 ---- + if (depth > 4) + return 1; + +! switch (c) + { +! case NFA_SPLIT: +! if (state->out->c == NFA_SPLIT || state->out1->c == NFA_SPLIT) +! /* avoid recursive stuff */ +! return 1; +! /* two alternatives, use the lowest failure chance */ +! l = failure_chance(state->out, depth + 1); +! r = failure_chance(state->out1, depth + 1); +! return l < r ? l : r; +! +! case NFA_ANY: +! /* matches anything, unlikely to fail */ + return 1; +! case NFA_MATCH: +! /* empty match works always */ +! return 0; +! +! case NFA_BOL: +! case NFA_EOL: +! case NFA_BOF: +! case NFA_EOF: +! case NFA_NEWL: +! return 99; +! +! case NFA_BOW: +! case NFA_EOW: +! return 90; +! +! case NFA_MOPEN: +! case NFA_MOPEN1: +! case NFA_MOPEN2: +! case NFA_MOPEN3: +! case NFA_MOPEN4: +! case NFA_MOPEN5: +! case NFA_MOPEN6: +! case NFA_MOPEN7: +! case NFA_MOPEN8: +! case NFA_MOPEN9: +! #ifdef FEAT_SYN_HL +! case NFA_ZOPEN: +! case NFA_ZOPEN1: +! case NFA_ZOPEN2: +! case NFA_ZOPEN3: +! case NFA_ZOPEN4: +! case NFA_ZOPEN5: +! case NFA_ZOPEN6: +! case NFA_ZOPEN7: +! case NFA_ZOPEN8: +! case NFA_ZOPEN9: +! case NFA_ZCLOSE: +! case NFA_ZCLOSE1: +! case NFA_ZCLOSE2: +! case NFA_ZCLOSE3: +! case NFA_ZCLOSE4: +! case NFA_ZCLOSE5: +! case NFA_ZCLOSE6: +! case NFA_ZCLOSE7: +! case NFA_ZCLOSE8: +! case NFA_ZCLOSE9: +! #endif +! case NFA_NOPEN: +! case NFA_MCLOSE: +! case NFA_MCLOSE1: +! case NFA_MCLOSE2: +! case NFA_MCLOSE3: +! case NFA_MCLOSE4: +! case NFA_MCLOSE5: +! case NFA_MCLOSE6: +! case NFA_MCLOSE7: +! case NFA_MCLOSE8: +! case NFA_MCLOSE9: +! case NFA_NCLOSE: +! return failure_chance(state->out, depth + 1); +! +! case NFA_BACKREF1: +! case NFA_BACKREF2: +! case NFA_BACKREF3: +! case NFA_BACKREF4: +! case NFA_BACKREF5: +! case NFA_BACKREF6: +! case NFA_BACKREF7: +! case NFA_BACKREF8: +! case NFA_BACKREF9: + #ifdef FEAT_SYN_HL +! case NFA_ZREF1: +! case NFA_ZREF2: +! case NFA_ZREF3: +! case NFA_ZREF4: +! case NFA_ZREF5: +! case NFA_ZREF6: +! case NFA_ZREF7: +! case NFA_ZREF8: +! case NFA_ZREF9: + #endif +! /* backreferences don't match in many places */ +! return 94; +! +! case NFA_LNUM_GT: +! case NFA_LNUM_LT: +! case NFA_COL_GT: +! case NFA_COL_LT: +! case NFA_VCOL_GT: +! case NFA_VCOL_LT: +! case NFA_MARK_GT: +! case NFA_MARK_LT: +! #ifdef FEAT_VISUAL +! case NFA_VISUAL: +! #endif +! /* before/after positions don't match very often */ +! return 85; +! +! case NFA_LNUM: +! return 90; +! +! case NFA_CURSOR: +! case NFA_COL: +! case NFA_VCOL: +! case NFA_MARK: +! /* specific positions rarely match */ +! return 98; +! +! case NFA_COMPOSING: +! return 95; +! +! default: +! if (c > 0) +! /* character match fails often */ +! return 95; +! } +! +! /* something else, includes character classes */ + return 50; + } + +*** ../vim-7.3.1117/src/version.c 2013-06-05 11:05:12.000000000 +0200 +--- src/version.c 2013-06-05 11:41:58.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1118, + /**/ + +-- +From "know your smileys": + :~) A man with a tape recorder up his nose + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fbcfc8e71a69ee1911f77a38a3b8e9f097d17386 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:03 +0200 Subject: [PATCH 1011/3340] - patchlevel 1119 --- 7.3.1119 | 237 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 237 insertions(+) create mode 100644 7.3.1119 diff --git a/7.3.1119 b/7.3.1119 new file mode 100644 index 00000000..9bdf4faf --- /dev/null +++ b/7.3.1119 @@ -0,0 +1,237 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1119 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1119 +Problem: Flags in 'cpo' are searched for several times. +Solution: Store the result and re-use the flags. +Files: src/regexp.c, src/regexp_nfa.c + + +*** ../vim-7.3.1118/src/regexp.c 2013-06-04 21:27:33.000000000 +0200 +--- src/regexp.c 2013-06-05 12:37:30.000000000 +0200 +*************** +*** 365,370 **** +--- 365,371 ---- + static char_u e_z_not_allowed[] = N_("E66: \\z( not allowed here"); + static char_u e_z1_not_allowed[] = N_("E67: \\z1 et al. not allowed here"); + #endif ++ static char_u e_missing_sb[] = N_("E69: Missing ] after %s%%["); + + #define NOT_MULTI 0 + #define MULTI_ONE 1 +*************** +*** 1173,1178 **** +--- 1174,1189 ---- + return 0; + } + ++ static void get_cpo_flags __ARGS((void)); ++ static int reg_cpo_lit; /* 'cpoptions' contains 'l' flag */ ++ static int reg_cpo_bsl; /* 'cpoptions' contains '\' flag */ ++ ++ static void ++ get_cpo_flags() ++ { ++ reg_cpo_lit = vim_strchr(p_cpo, CPO_LITERAL) != NULL; ++ reg_cpo_bsl = vim_strchr(p_cpo, CPO_BACKSL) != NULL; ++ } + + /* + * Skip over a "[]" range. +*************** +*** 1183,1197 **** + skip_anyof(p) + char_u *p; + { +- int cpo_lit; /* 'cpoptions' contains 'l' flag */ +- int cpo_bsl; /* 'cpoptions' contains '\' flag */ + #ifdef FEAT_MBYTE + int l; + #endif + +- cpo_lit = vim_strchr(p_cpo, CPO_LITERAL) != NULL; +- cpo_bsl = vim_strchr(p_cpo, CPO_BACKSL) != NULL; +- + if (*p == '^') /* Complement of range. */ + ++p; + if (*p == ']' || *p == '-') +--- 1194,1203 ---- +*************** +*** 1210,1218 **** + mb_ptr_adv(p); + } + else if (*p == '\\' +! && !cpo_bsl + && (vim_strchr(REGEXP_INRANGE, p[1]) != NULL +! || (!cpo_lit && vim_strchr(REGEXP_ABBR, p[1]) != NULL))) + p += 2; + else if (*p == '[') + { +--- 1216,1224 ---- + mb_ptr_adv(p); + } + else if (*p == '\\' +! && !reg_cpo_bsl + && (vim_strchr(REGEXP_INRANGE, p[1]) != NULL +! || (!reg_cpo_lit && vim_strchr(REGEXP_ABBR, p[1]) != NULL))) + p += 2; + else if (*p == '[') + { +*************** +*** 1251,1256 **** +--- 1257,1263 ---- + mymagic = MAGIC_ON; + else + mymagic = MAGIC_OFF; ++ get_cpo_flags(); + + for (; p[0] != NUL; mb_ptr_adv(p)) + { +*************** +*** 1462,1467 **** +--- 1469,1475 ---- + reg_magic = MAGIC_OFF; + reg_string = (re_flags & RE_STRING); + reg_strict = (re_flags & RE_STRICT); ++ get_cpo_flags(); + + num_complex_braces = 0; + regnpar = 1; +*************** +*** 1909,1923 **** + { + char_u *ret; + int flags; +- int cpo_lit; /* 'cpoptions' contains 'l' flag */ +- int cpo_bsl; /* 'cpoptions' contains '\' flag */ + int c; + char_u *p; + int extra = 0; + + *flagp = WORST; /* Tentatively. */ +- cpo_lit = vim_strchr(p_cpo, CPO_LITERAL) != NULL; +- cpo_bsl = vim_strchr(p_cpo, CPO_BACKSL) != NULL; + + c = getchr(); + switch (c) +--- 1917,1927 ---- +*************** +*** 2207,2213 **** + while ((c = getchr()) != ']') + { + if (c == NUL) +! EMSG2_RET_NULL(_("E69: Missing ] after %s%%["), + reg_magic == MAGIC_ALL); + br = regnode(BRANCH); + if (ret == NULL) +--- 2211,2217 ---- + while ((c = getchr()) != ']') + { + if (c == NUL) +! EMSG2_RET_NULL(_(e_missing_sb), + reg_magic == MAGIC_ALL); + br = regnode(BRANCH); + if (ret == NULL) +*************** +*** 2410,2416 **** + } + + /* Handle \o40, \x20 and \u20AC style sequences */ +! if (endc == '\\' && !cpo_lit && !cpo_bsl) + endc = coll_get_char(); + + if (startc > endc) +--- 2414,2420 ---- + } + + /* Handle \o40, \x20 and \u20AC style sequences */ +! if (endc == '\\' && !reg_cpo_lit && !reg_cpo_bsl) + endc = coll_get_char(); + + if (startc > endc) +*************** +*** 2452,2460 **** + * Posix doesn't recognize backslash at all. + */ + else if (*regparse == '\\' +! && !cpo_bsl + && (vim_strchr(REGEXP_INRANGE, regparse[1]) != NULL +! || (!cpo_lit + && vim_strchr(REGEXP_ABBR, + regparse[1]) != NULL))) + { +--- 2456,2464 ---- + * Posix doesn't recognize backslash at all. + */ + else if (*regparse == '\\' +! && !reg_cpo_bsl + && (vim_strchr(REGEXP_INRANGE, regparse[1]) != NULL +! || (!reg_cpo_lit + && vim_strchr(REGEXP_ABBR, + regparse[1]) != NULL))) + { +*** ../vim-7.3.1118/src/regexp_nfa.c 2013-06-05 11:46:22.000000000 +0200 +--- src/regexp_nfa.c 2013-06-05 12:38:03.000000000 +0200 +*************** +*** 686,698 **** + int startc = -1; + int endc = -1; + int oldstartc = -1; +- int cpo_lit; /* 'cpoptions' contains 'l' flag */ +- int cpo_bsl; /* 'cpoptions' contains '\' flag */ + int glue; /* ID that will "glue" nodes together */ + +- cpo_lit = vim_strchr(p_cpo, CPO_LITERAL) != NULL; +- cpo_bsl = vim_strchr(p_cpo, CPO_BACKSL) != NULL; +- + c = getchr(); + switch (c) + { +--- 686,693 ---- +*************** +*** 1224,1233 **** + * Posix doesn't recognize backslash at all. + */ + if (*regparse == '\\' +! && !cpo_bsl + && regparse + 1 <= endp + && (vim_strchr(REGEXP_INRANGE, regparse[1]) != NULL +! || (!cpo_lit + && vim_strchr(REGEXP_ABBR, regparse[1]) + != NULL) + ) +--- 1219,1228 ---- + * Posix doesn't recognize backslash at all. + */ + if (*regparse == '\\' +! && !reg_cpo_bsl + && regparse + 1 <= endp + && (vim_strchr(REGEXP_INRANGE, regparse[1]) != NULL +! || (!reg_cpo_lit + && vim_strchr(REGEXP_ABBR, regparse[1]) + != NULL) + ) +*** ../vim-7.3.1118/src/version.c 2013-06-05 11:46:22.000000000 +0200 +--- src/version.c 2013-06-05 12:40:57.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1119, + /**/ + +-- +From "know your smileys": + :-O>-o Smiley American tourist (note big mouth and camera) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 48d68d28a5b859aa78c7659e3addb4bb57a8a006 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:04 +0200 Subject: [PATCH 1012/3340] - patchlevel 1120 --- 7.3.1120 | 94 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 94 insertions(+) create mode 100644 7.3.1120 diff --git a/7.3.1120 b/7.3.1120 new file mode 100644 index 00000000..29d47817 --- /dev/null +++ b/7.3.1120 @@ -0,0 +1,94 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1120 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1120 +Problem: Crash when regexp logging is enabled. +Solution: Avoid using NULL pointers. Advance over count argument. +Files: src/regexp.c, src/regexp_nfa.c + + +*** ../vim-7.3.1119/src/regexp.c 2013-06-05 12:43:05.000000000 +0200 +--- src/regexp.c 2013-06-05 16:27:25.000000000 +0200 +*************** +*** 6538,6547 **** + end = next; + if (op == BRACE_LIMITS) + { +! /* Two short ints */ + fprintf(f, " minval %ld, maxval %ld", OPERAND_MIN(s), OPERAND_MAX(s)); + s += 8; + } + s += 3; + if (op == ANYOF || op == ANYOF + ADD_NL + || op == ANYBUT || op == ANYBUT + ADD_NL +--- 6538,6553 ---- + end = next; + if (op == BRACE_LIMITS) + { +! /* Two ints */ + fprintf(f, " minval %ld, maxval %ld", OPERAND_MIN(s), OPERAND_MAX(s)); + s += 8; + } ++ else if (op == BEHIND || op == NOBEHIND) ++ { ++ /* one int */ ++ fprintf(f, " count %ld", OPERAND_MIN(s)); ++ s += 4; ++ } + s += 3; + if (op == ANYOF || op == ANYOF + ADD_NL + || op == ANYBUT || op == ANYBUT + ADD_NL +*** ../vim-7.3.1119/src/regexp_nfa.c 2013-06-05 12:43:05.000000000 +0200 +--- src/regexp_nfa.c 2013-06-05 16:13:25.000000000 +0200 +*************** +*** 2960,2969 **** + sub->list.multi[j].end.col, + (int)sub->list.multi[j].end.lnum); + else + fprintf(log_fd, "\n *** group %d, start: \"%s\", end: \"%s\"", + j, +! (char *)sub->list.line[j].start, +! (char *)sub->list.line[j].end); + fprintf(log_fd, "\n"); + } + #endif +--- 2960,2974 ---- + sub->list.multi[j].end.col, + (int)sub->list.multi[j].end.lnum); + else ++ { ++ char *s = (char *)sub->list.line[j].start; ++ char *e = (char *)sub->list.line[j].end; ++ + fprintf(log_fd, "\n *** group %d, start: \"%s\", end: \"%s\"", + j, +! s == NULL ? "NULL" : s, +! e == NULL ? "NULL" : e); +! } + fprintf(log_fd, "\n"); + } + #endif +*** ../vim-7.3.1119/src/version.c 2013-06-05 12:43:05.000000000 +0200 +--- src/version.c 2013-06-05 16:27:14.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1120, + /**/ + +-- +From "know your smileys": + |-P Reaction to unusually ugly C code + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6936df2395b2a6980036daed97e8191ee0a4b39d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:05 +0200 Subject: [PATCH 1013/3340] - patchlevel 1121 --- 7.3.1121 | 118 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 118 insertions(+) create mode 100644 7.3.1121 diff --git a/7.3.1121 b/7.3.1121 new file mode 100644 index 00000000..011e3f95 --- /dev/null +++ b/7.3.1121 @@ -0,0 +1,118 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1121 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1121 +Problem: New regexp engine: adding states that are not used. +Solution: Don't add the states. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1120/src/regexp_nfa.c 2013-06-05 16:33:05.000000000 +0200 +--- src/regexp_nfa.c 2013-06-05 16:47:27.000000000 +0200 +*************** +*** 3169,3174 **** +--- 3176,3182 ---- + case NFA_SPLIT: + case NFA_NOT: + case NFA_NOPEN: ++ case NFA_SKIP_CHAR: + case NFA_NCLOSE: + case NFA_MCLOSE: + case NFA_MCLOSE1: +*************** +*** 3192,3197 **** +--- 3200,3206 ---- + case NFA_ZCLOSE8: + case NFA_ZCLOSE9: + #endif ++ case NFA_ZEND: + /* These nodes are not added themselves but their "out" and/or + * "out1" may be added below. */ + break; +*************** +*** 3218,3223 **** +--- 3227,3233 ---- + case NFA_ZOPEN8: + case NFA_ZOPEN9: + #endif ++ case NFA_ZSTART: + /* These nodes do not need to be added, but we need to bail out + * when it was tried to be added to this list before. */ + if (state->lastlist[nfa_ll_index] == l->id) +*************** +*** 4362,4371 **** + + case NFA_START_INVISIBLE: + case NFA_START_INVISIBLE_BEFORE: +- /* If invisible match has a higher chance to fail, do it +- * right away. Otherwise postpone it until what follows is +- * matching and causes addstate(nextlist, ..) to be called. +- * This is indicated by the "pim" field. */ + { + nfa_pim_T *pim; + int cout = t->state->out1->out->c; +--- 4372,4377 ---- +*************** +*** 4863,4874 **** + log_subsexpr(&nextlist->t[nextlist->n - 1].subs); + #endif + } +- + } + break; + } + case NFA_SKIP: +! /* charater of previous matching \1 .. \9 */ + if (t->count - clen <= 0) + { + /* end of match, go to what follows */ +--- 4869,4879 ---- + log_subsexpr(&nextlist->t[nextlist->n - 1].subs); + #endif + } + } + break; + } + case NFA_SKIP: +! /* character of previous matching \1 .. \9 or \@> */ + if (t->count - clen <= 0) + { + /* end of match, go to what follows */ +*************** +*** 4892,4903 **** + } + break; + +- case NFA_SKIP_CHAR: +- case NFA_ZSTART: +- case NFA_ZEND: +- /* TODO: should not happen? */ +- break; +- + case NFA_LNUM: + case NFA_LNUM_GT: + case NFA_LNUM_LT: +--- 4897,4902 ---- +*** ../vim-7.3.1120/src/version.c 2013-06-05 16:33:05.000000000 +0200 +--- src/version.c 2013-06-05 16:50:39.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1121, + /**/ + +-- +Where do you want to crash today? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9ce2db6649b53fc09728daad08590e6e6787a6b6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:06 +0200 Subject: [PATCH 1014/3340] - patchlevel 1122 --- 7.3.1122 | 478 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 478 insertions(+) create mode 100644 7.3.1122 diff --git a/7.3.1122 b/7.3.1122 new file mode 100644 index 00000000..a60dce4a --- /dev/null +++ b/7.3.1122 @@ -0,0 +1,478 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1122 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1122 +Problem: New regexp engine: \@> not supported. +Solution: Implement \@>. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1121/src/regexp_nfa.c 2013-06-05 16:51:53.000000000 +0200 +--- src/regexp_nfa.c 2013-06-05 18:45:57.000000000 +0200 +*************** +*** 57,63 **** +--- 57,65 ---- + NFA_NCLOSE, /* End of subexpr. marked with \%( ... \) */ + NFA_START_INVISIBLE, + NFA_START_INVISIBLE_BEFORE, ++ NFA_START_PATTERN, + NFA_END_INVISIBLE, ++ NFA_END_PATTERN, + NFA_COMPOSING, /* Next nodes in NFA are part of the + composing multibyte char */ + NFA_END_COMPOSING, /* End of a composing char in the NFA */ +*************** +*** 1505,1513 **** + i = NFA_PREV_ATOM_JUST_BEFORE_NEG; + break; + case '>': +! /* \@> Not supported yet */ +! /* i = NFA_PREV_ATOM_LIKE_PATTERN; */ +! return FAIL; + } + if (i == 0) + { +--- 1507,1515 ---- + i = NFA_PREV_ATOM_JUST_BEFORE_NEG; + break; + case '>': +! /* \@> */ +! i = NFA_PREV_ATOM_LIKE_PATTERN; +! break; + } + if (i == 0) + { +*************** +*** 1885,1896 **** +--- 1887,1903 ---- + STRCPY(code, "NFA_PREV_ATOM_JUST_BEFORE"); break; + case NFA_PREV_ATOM_JUST_BEFORE_NEG: + STRCPY(code, "NFA_PREV_ATOM_JUST_BEFORE_NEG"); break; ++ case NFA_PREV_ATOM_LIKE_PATTERN: ++ STRCPY(code, "NFA_PREV_ATOM_LIKE_PATTERN"); break; ++ + case NFA_NOPEN: STRCPY(code, "NFA_NOPEN"); break; + case NFA_NCLOSE: STRCPY(code, "NFA_NCLOSE"); break; + case NFA_START_INVISIBLE: STRCPY(code, "NFA_START_INVISIBLE"); break; + case NFA_START_INVISIBLE_BEFORE: + STRCPY(code, "NFA_START_INVISIBLE_BEFORE"); break; ++ case NFA_START_PATTERN: STRCPY(code, "NFA_START_PATTERN"); break; + case NFA_END_INVISIBLE: STRCPY(code, "NFA_END_INVISIBLE"); break; ++ case NFA_END_PATTERN: STRCPY(code, "NFA_END_PATTERN"); break; + + case NFA_COMPOSING: STRCPY(code, "NFA_COMPOSING"); break; + case NFA_END_COMPOSING: STRCPY(code, "NFA_END_COMPOSING"); break; +*************** +*** 2601,2612 **** + case NFA_PREV_ATOM_NO_WIDTH_NEG: + case NFA_PREV_ATOM_JUST_BEFORE: + case NFA_PREV_ATOM_JUST_BEFORE_NEG: + { + int neg = (*p == NFA_PREV_ATOM_NO_WIDTH_NEG + || *p == NFA_PREV_ATOM_JUST_BEFORE_NEG); + int before = (*p == NFA_PREV_ATOM_JUST_BEFORE + || *p == NFA_PREV_ATOM_JUST_BEFORE_NEG); +! int n; + + if (before) + n = *++p; /* get the count */ +--- 2608,2633 ---- + case NFA_PREV_ATOM_NO_WIDTH_NEG: + case NFA_PREV_ATOM_JUST_BEFORE: + case NFA_PREV_ATOM_JUST_BEFORE_NEG: ++ case NFA_PREV_ATOM_LIKE_PATTERN: + { + int neg = (*p == NFA_PREV_ATOM_NO_WIDTH_NEG + || *p == NFA_PREV_ATOM_JUST_BEFORE_NEG); + int before = (*p == NFA_PREV_ATOM_JUST_BEFORE + || *p == NFA_PREV_ATOM_JUST_BEFORE_NEG); +! int pattern = (*p == NFA_PREV_ATOM_LIKE_PATTERN); +! int start_state = NFA_START_INVISIBLE; +! int end_state = NFA_END_INVISIBLE; +! int n = 0; +! nfa_state_T *zend; +! nfa_state_T *skip; +! +! if (before) +! start_state = NFA_START_INVISIBLE_BEFORE; +! else if (pattern) +! { +! start_state = NFA_START_PATTERN; +! end_state = NFA_END_PATTERN; +! } + + if (before) + n = *++p; /* get the count */ +*************** +*** 2620,2635 **** + + if (nfa_calc_size == TRUE) + { +! nstate += 2; + break; + } + e = POP(); +! s1 = alloc_state(NFA_END_INVISIBLE, NULL, NULL); + if (s1 == NULL) + goto theend; +- patch(e.out, s1); + +! s = alloc_state(NFA_START_INVISIBLE, e.start, s1); + if (s == NULL) + goto theend; + if (neg) +--- 2641,2655 ---- + + if (nfa_calc_size == TRUE) + { +! nstate += pattern ? 4 : 2; + break; + } + e = POP(); +! s1 = alloc_state(end_state, NULL, NULL); + if (s1 == NULL) + goto theend; + +! s = alloc_state(start_state, e.start, s1); + if (s == NULL) + goto theend; + if (neg) +*************** +*** 2638,2649 **** + s1->negated = TRUE; + } + if (before) +- { + s->val = n; /* store the count */ +! ++s->c; /* NFA_START_INVISIBLE -> NFA_START_INVISIBLE_BEFORE */ + } +- +- PUSH(frag(s, list1(&s1->out))); + break; + } + +--- 2658,2678 ---- + s1->negated = TRUE; + } + if (before) + s->val = n; /* store the count */ +! if (pattern) +! { +! /* NFA_ZEND -> NFA_END_PATTERN -> NFA_SKIP -> what follows. */ +! skip = alloc_state(NFA_SKIP, NULL, NULL); +! zend = alloc_state(NFA_ZEND, s1, NULL); +! s1->out= skip; +! patch(e.out, zend); +! PUSH(frag(s, list1(&skip->out))); +! } +! else +! { +! patch(e.out, s1); +! PUSH(frag(s, list1(&s1->out))); + } + break; + } + +*************** +*** 2953,2959 **** + + for (j = 0; j < sub->in_use; j++) + if (REG_MULTI) +! fprintf(log_fd, "\n *** group %d, start: c=%d, l=%d, end: c=%d, l=%d", + j, + sub->list.multi[j].start.col, + (int)sub->list.multi[j].start.lnum, +--- 2982,2988 ---- + + for (j = 0; j < sub->in_use; j++) + if (REG_MULTI) +! fprintf(log_fd, "*** group %d, start: c=%d, l=%d, end: c=%d, l=%d\n", + j, + sub->list.multi[j].start.col, + (int)sub->list.multi[j].start.lnum, +*************** +*** 2964,2975 **** + char *s = (char *)sub->list.line[j].start; + char *e = (char *)sub->list.line[j].end; + +! fprintf(log_fd, "\n *** group %d, start: \"%s\", end: \"%s\"", + j, + s == NULL ? "NULL" : s, + e == NULL ? "NULL" : e); + } +- fprintf(log_fd, "\n"); + } + #endif + +--- 2993,3003 ---- + char *s = (char *)sub->list.line[j].start; + char *e = (char *)sub->list.line[j].end; + +! fprintf(log_fd, "*** group %d, start: \"%s\", end: \"%s\"\n", + j, + s == NULL ? "NULL" : s, + e == NULL ? "NULL" : e); + } + } + #endif + +*************** +*** 4317,4322 **** +--- 4345,4351 ---- + } + + case NFA_END_INVISIBLE: ++ case NFA_END_PATTERN: + /* + * This is only encountered after a NFA_START_INVISIBLE or + * NFA_START_INVISIBLE_BEFORE node. +*************** +*** 4343,4349 **** + (int)(nfa_endp->se_u.ptr - reginput)); + } + #endif +! /* It's only a match if it ends at "nfa_endp" */ + if (nfa_endp != NULL && (REG_MULTI + ? (reglnum != nfa_endp->se_u.pos.lnum + || (int)(reginput - regline) +--- 4372,4379 ---- + (int)(nfa_endp->se_u.ptr - reginput)); + } + #endif +! /* If "nfa_endp" is set it's only a match if it ends at +! * "nfa_endp" */ + if (nfa_endp != NULL && (REG_MULTI + ? (reglnum != nfa_endp->se_u.pos.lnum + || (int)(reginput - regline) +*************** +*** 4360,4365 **** +--- 4390,4399 ---- + copy_sub(&m->synt, &t->subs.synt); + #endif + } ++ #ifdef ENABLE_LOG ++ fprintf(log_fd, "Match found:\n"); ++ log_subsexpr(m); ++ #endif + nfa_match = TRUE; + break; + +*************** +*** 4435,4440 **** +--- 4469,4531 ---- + } + break; + ++ case NFA_START_PATTERN: ++ /* First try matching the pattern. */ ++ result = recursive_regmatch(t->state, prog, ++ submatch, m, &listids); ++ if (result) ++ { ++ int bytelen; ++ ++ #ifdef ENABLE_LOG ++ fprintf(log_fd, "NFA_START_PATTERN matches:\n"); ++ log_subsexpr(m); ++ #endif ++ /* Copy submatch info from the recursive call */ ++ copy_sub_off(&t->subs.norm, &m->norm); ++ #ifdef FEAT_SYN_HL ++ copy_sub_off(&t->subs.synt, &m->synt); ++ #endif ++ /* Now we need to skip over the matched text and then ++ * continue with what follows. */ ++ if (REG_MULTI) ++ /* TODO: multi-line match */ ++ bytelen = m->norm.list.multi[0].end.col ++ - (int)(reginput - regline); ++ else ++ bytelen = (int)(m->norm.list.line[0].end - reginput); ++ ++ #ifdef ENABLE_LOG ++ fprintf(log_fd, "NFA_START_PATTERN length: %d\n", bytelen); ++ #endif ++ if (bytelen == 0) ++ { ++ /* empty match, output of corresponding ++ * NFA_END_PATTERN/NFA_SKIP to be used at current ++ * position */ ++ addstate_here(thislist, t->state->out1->out->out, ++ &t->subs, t->pim, &listidx); ++ } ++ else if (bytelen <= clen) ++ { ++ /* match current character, output of corresponding ++ * NFA_END_PATTERN to be used at next position. */ ++ ll = nextlist; ++ add_state = t->state->out1->out->out; ++ add_off = clen; ++ } ++ else ++ { ++ /* skip over the matched characters, set character ++ * count in NFA_SKIP */ ++ ll = nextlist; ++ add_state = t->state->out1->out; ++ add_off = bytelen; ++ add_count = bytelen - clen; ++ } ++ } ++ break; ++ + case NFA_BOL: + if (reginput == regline) + addstate_here(thislist, t->state->out, &t->subs, +*************** +*** 4846,4854 **** + ll = nextlist; + add_state = t->state->out->out; + add_off = clen; +- #ifdef ENABLE_LOG +- log_subsexpr(&nextlist->t[nextlist->n - 1].subs); +- #endif + } + else + { +--- 4937,4942 ---- +*************** +*** 4858,4866 **** + add_state = t->state->out; + add_off = bytelen; + add_count = bytelen - clen; +- #ifdef ENABLE_LOG +- log_subsexpr(&nextlist->t[nextlist->n - 1].subs); +- #endif + } + } + break; +--- 4946,4951 ---- +*************** +*** 4873,4881 **** + ll = nextlist; + add_state = t->state->out; + add_off = clen; +- #ifdef ENABLE_LOG +- log_subsexpr(&nextlist->t[nextlist->n - 1].subs); +- #endif + } + else + { +--- 4958,4963 ---- +*************** +*** 4884,4892 **** + add_state = t->state; + add_off = 0; + add_count = t->count - clen; +- #ifdef ENABLE_LOG +- log_subsexpr(&nextlist->t[nextlist->n - 1].subs); +- #endif + } + break; + +--- 4966,4971 ---- +*************** +*** 5158,5170 **** + f = fopen(NFA_REGEXP_RUN_LOG, "a"); + if (f != NULL) + { +! fprintf(f, "\n\n\n\n\n\n\t\t=======================================================\n"); +! fprintf(f, " =======================================================\n"); + #ifdef DEBUG + fprintf(f, "\tRegexp is \"%s\"\n", nfa_regengine.expr); + #endif + fprintf(f, "\tInput text is \"%s\" \n", reginput); +! fprintf(f, " =======================================================\n\n"); + nfa_print_state(f, start); + fprintf(f, "\n\n"); + fclose(f); +--- 5237,5248 ---- + f = fopen(NFA_REGEXP_RUN_LOG, "a"); + if (f != NULL) + { +! fprintf(f, "\n\n\t=======================================================\n"); + #ifdef DEBUG + fprintf(f, "\tRegexp is \"%s\"\n", nfa_regengine.expr); + #endif + fprintf(f, "\tInput text is \"%s\" \n", reginput); +! fprintf(f, "\t=======================================================\n\n"); + nfa_print_state(f, start); + fprintf(f, "\n\n"); + fclose(f); +*** ../vim-7.3.1121/src/testdir/test64.in 2013-06-05 11:05:12.000000000 +0200 +--- src/testdir/test64.in 2013-06-05 18:45:28.000000000 +0200 +*************** +*** 385,390 **** +--- 385,396 ---- + :call add(tl, [2, '\(<<\)\@2<=span.', 'xxspanxxxx ++ :call add(tl, [2, '\(a*\)\@>a', 'aaaa']) ++ :call add(tl, [2, '\(a*\)\@>b', 'aaab', 'aaab', 'aaa']) ++ :" TODO: BT engine does not restore submatch after failure ++ :call add(tl, [1, '\(a*\)\@>a\|a\+', 'aaaa', 'aaaa']) ++ :" + :"""" "\_" prepended negated collection matches EOL + :call add(tl, [2, '\_[^8-9]\+', "asfi\n9888", "asfi\n"]) + :call add(tl, [2, '\_[^a]\+', "asfi\n9888", "sfi\n9888"]) +*************** +*** 401,407 **** + : let text = t[2] + : let matchidx = 3 + : for engine in [0, 1, 2] +! : if engine == 2 && !re + : continue + : endif + : let ®expengine = engine +--- 407,413 ---- + : let text = t[2] + : let matchidx = 3 + : for engine in [0, 1, 2] +! : if engine == 2 && re == 0 || engine == 1 && re ==1 + : continue + : endif + : let ®expengine = engine +*** ../vim-7.3.1121/src/testdir/test64.ok 2013-06-05 11:05:12.000000000 +0200 +--- src/testdir/test64.ok 2013-06-05 18:47:54.000000000 +0200 +*************** +*** 872,877 **** +--- 872,885 ---- + OK 0 - \(foo\)\@a ++ OK 1 - \(a*\)\@>a ++ OK 2 - \(a*\)\@>a ++ OK 0 - \(a*\)\@>b ++ OK 1 - \(a*\)\@>b ++ OK 2 - \(a*\)\@>b ++ OK 0 - \(a*\)\@>a\|a\+ ++ OK 2 - \(a*\)\@>a\|a\+ + OK 0 - \_[^8-9]\+ + OK 1 - \_[^8-9]\+ + OK 2 - \_[^8-9]\+ +*** ../vim-7.3.1121/src/version.c 2013-06-05 16:51:53.000000000 +0200 +--- src/version.c 2013-06-05 18:51:35.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1122, + /**/ + +-- +From "know your smileys": + :q vi user saying, "How do I get out of this damn emacs editor?" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 19c1381f3723a2b13e310587478a73c5a794bcbf Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:07 +0200 Subject: [PATCH 1015/3340] - patchlevel 1123 --- 7.3.1123 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.1123 diff --git a/7.3.1123 b/7.3.1123 new file mode 100644 index 00000000..5b6d87a9 --- /dev/null +++ b/7.3.1123 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1123 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1123 +Problem: Can't build tiny Vim on MS-Windows. +Solution: Adjust #ifdef around using modif_fname(). (Mike Williams) +Files: src/misc1.c + + +*** ../vim-7.3.1122/src/misc1.c 2013-05-06 04:21:35.000000000 +0200 +--- src/misc1.c 2013-06-05 19:33:30.000000000 +0200 +*************** +*** 4607,4613 **** + if (homedir_env != NULL && *homedir_env == NUL) + homedir_env = NULL; + +! #if defined(FEAT_MODIFY_FNAME) || defined(WIN3264) + if (homedir_env != NULL && vim_strchr(homedir_env, '~') != NULL) + { + int usedlen = 0; +--- 4607,4613 ---- + if (homedir_env != NULL && *homedir_env == NUL) + homedir_env = NULL; + +! #if defined(FEAT_MODIFY_FNAME) || defined(FEAT_EVAL) + if (homedir_env != NULL && vim_strchr(homedir_env, '~') != NULL) + { + int usedlen = 0; +*** ../vim-7.3.1122/src/version.c 2013-06-05 18:52:36.000000000 +0200 +--- src/version.c 2013-06-05 19:34:17.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1123, + /**/ + +-- +From "know your smileys": + ...---... SOS + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 57d3a98449eac1fc1d2e5488549849b7dfa3da8e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:08 +0200 Subject: [PATCH 1016/3340] - patchlevel 1124 --- 7.3.1124 | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 7.3.1124 diff --git a/7.3.1124 b/7.3.1124 new file mode 100644 index 00000000..0304beec --- /dev/null +++ b/7.3.1124 @@ -0,0 +1,46 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1124 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1124 +Problem: Python: Crash on MS-Windows when os.fchdir() is not available. +Solution: Check for _chdir to be NULL. (Ken Takata) +Files: src/if_py_both.h + + +*** ../vim-7.3.1123/src/if_py_both.h 2013-06-03 20:04:43.000000000 +0200 +--- src/if_py_both.h 2013-06-05 20:33:48.000000000 +0200 +*************** +*** 718,723 **** +--- 718,725 ---- + PyObject *todecref; + char_u *new_dir; + ++ if (_chdir == NULL) ++ return NULL; + if (!(r = PyObject_Call(_chdir, args, kwargs))) + return NULL; + +*** ../vim-7.3.1123/src/version.c 2013-06-05 19:35:31.000000000 +0200 +--- src/version.c 2013-06-05 20:09:04.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1124, + /**/ + +-- +From "know your smileys": + =):-) Uncle Sam + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From caaef3e3f793b3caff2b79592117941d4cc760d3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:09 +0200 Subject: [PATCH 1017/3340] - patchlevel 1125 --- 7.3.1125 | 116 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 116 insertions(+) create mode 100644 7.3.1125 diff --git a/7.3.1125 b/7.3.1125 new file mode 100644 index 00000000..6e026959 --- /dev/null +++ b/7.3.1125 @@ -0,0 +1,116 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1125 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1125 +Problem: Error for using \%V in a pattern in tiny Vim. +Solution: Allow using \%V but never match. (Dominique Pelle) +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1124/src/regexp_nfa.c 2013-06-05 18:52:36.000000000 +0200 +--- src/regexp_nfa.c 2013-06-05 21:05:09.000000000 +0200 +*************** +*** 184,192 **** + NFA_MARK, /* Match mark */ + NFA_MARK_GT, /* Match > mark */ + NFA_MARK_LT, /* Match < mark */ +- #ifdef FEAT_VISUAL + NFA_VISUAL, /* Match Visual area */ +- #endif + + NFA_FIRST_NL = NFA_ANY + ADD_NL, + NFA_LAST_NL = NFA_NUPPER + ADD_NL, +--- 184,190 ---- +*************** +*** 963,973 **** + EMIT(NFA_CURSOR); + break; + +- #ifdef FEAT_VISUAL + case 'V': + EMIT(NFA_VISUAL); + break; +- #endif + + case '[': + { +--- 961,969 ---- +*************** +*** 1976,1984 **** + case NFA_MARK_GT: STRCPY(code, "NFA_MARK_GT "); break; + case NFA_MARK_LT: STRCPY(code, "NFA_MARK_LT "); break; + case NFA_CURSOR: STRCPY(code, "NFA_CURSOR "); break; +- #ifdef FEAT_VISUAL + case NFA_VISUAL: STRCPY(code, "NFA_VISUAL "); break; +- #endif + + case NFA_STAR: STRCPY(code, "NFA_STAR "); break; + case NFA_STAR_NONGREEDY: STRCPY(code, "NFA_STAR_NONGREEDY "); break; +--- 1972,1978 ---- +*************** +*** 4093,4101 **** + case NFA_VCOL_LT: + case NFA_MARK_GT: + case NFA_MARK_LT: +- #ifdef FEAT_VISUAL + case NFA_VISUAL: +- #endif + /* before/after positions don't match very often */ + return 85; + +--- 4087,4093 ---- +*************** +*** 5036,5049 **** + t->pim, &listidx); + break; + +- #ifdef FEAT_VISUAL + case NFA_VISUAL: + result = reg_match_visual(); + if (result) + addstate_here(thislist, t->state->out, &t->subs, + t->pim, &listidx); +- break; + #endif + + default: /* regular character */ + { +--- 5028,5041 ---- + t->pim, &listidx); + break; + + case NFA_VISUAL: ++ #ifdef FEAT_VISUAL + result = reg_match_visual(); + if (result) + addstate_here(thislist, t->state->out, &t->subs, + t->pim, &listidx); + #endif ++ break; + + default: /* regular character */ + { +*** ../vim-7.3.1124/src/version.c 2013-06-05 20:34:07.000000000 +0200 +--- src/version.c 2013-06-05 21:06:18.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1125, + /**/ + +-- +From "know your smileys": + (X0||) Double hamburger with lettuce and tomato + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 33b05b1234ddebc4872cf01bbf7d346a6f894d1d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:10 +0200 Subject: [PATCH 1018/3340] - patchlevel 1126 --- 7.3.1126 | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 7.3.1126 diff --git a/7.3.1126 b/7.3.1126 new file mode 100644 index 00000000..6c4a963b --- /dev/null +++ b/7.3.1126 @@ -0,0 +1,45 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1126 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1126 +Problem: Compiler warning for unitialized variable. (Tony Mechelynck) +Solution: Assign something to the variable. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1125/src/regexp_nfa.c 2013-06-05 21:10:55.000000000 +0200 +--- src/regexp_nfa.c 2013-06-05 21:21:48.000000000 +0200 +*************** +*** 2580,2585 **** +--- 2580,2586 ---- + nstate += n; + break; + } ++ s = NULL; /* avoid compiler warning */ + e1.out = NULL; /* stores list with out1's */ + s1 = NULL; /* previous NFA_SPLIT to connect to */ + while (n-- > 0) +*** ../vim-7.3.1125/src/version.c 2013-06-05 21:10:55.000000000 +0200 +--- src/version.c 2013-06-05 21:22:52.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1126, + /**/ + +-- +From "know your smileys": + 8<}} Glasses, big nose, beard + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5a8d3b8cdcf9664a9cf967afadcc79952c591072 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:12 +0200 Subject: [PATCH 1019/3340] - patchlevel 1127 --- 7.3.1127 | 83 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 7.3.1127 diff --git a/7.3.1127 b/7.3.1127 new file mode 100644 index 00000000..bf97a0cc --- /dev/null +++ b/7.3.1127 @@ -0,0 +1,83 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1127 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1127 +Problem: No error for using empty \%[]. +Solution: Give error message. +Files: src/regexp.c, src/regexp_nfa.c + + +*** ../vim-7.3.1126/src/regexp.c 2013-06-05 16:33:05.000000000 +0200 +--- src/regexp.c 2013-06-05 21:26:46.000000000 +0200 +*************** +*** 366,372 **** + static char_u e_z1_not_allowed[] = N_("E67: \\z1 et al. not allowed here"); + #endif + static char_u e_missing_sb[] = N_("E69: Missing ] after %s%%["); +! + #define NOT_MULTI 0 + #define MULTI_ONE 1 + #define MULTI_MULT 2 +--- 366,372 ---- + static char_u e_z1_not_allowed[] = N_("E67: \\z1 et al. not allowed here"); + #endif + static char_u e_missing_sb[] = N_("E69: Missing ] after %s%%["); +! static char_u e_empty_sb[] = N_("E70: Empty %s%%[]"); + #define NOT_MULTI 0 + #define MULTI_ONE 1 + #define MULTI_MULT 2 +*************** +*** 2227,2233 **** + return NULL; + } + if (ret == NULL) +! EMSG2_RET_NULL(_("E70: Empty %s%%[]"), + reg_magic == MAGIC_ALL); + lastbranch = regnode(BRANCH); + br = regnode(NOTHING); +--- 2227,2233 ---- + return NULL; + } + if (ret == NULL) +! EMSG2_RET_NULL(_(e_empty_sb), + reg_magic == MAGIC_ALL); + lastbranch = regnode(BRANCH); + br = regnode(NOTHING); +*** ../vim-7.3.1126/src/regexp_nfa.c 2013-06-05 21:23:33.000000000 +0200 +--- src/regexp_nfa.c 2013-06-05 21:29:07.000000000 +0200 +*************** +*** 977,982 **** +--- 977,985 ---- + reg_magic == MAGIC_ALL); + EMIT(c); + } ++ if (n == 0) ++ EMSG2_RET_FAIL(_(e_empty_sb), ++ reg_magic == MAGIC_ALL); + EMIT(NFA_OPT_CHARS); + EMIT(n); + break; +*** ../vim-7.3.1126/src/version.c 2013-06-05 21:23:33.000000000 +0200 +--- src/version.c 2013-06-05 21:29:48.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1127, + /**/ + +-- +From "know your smileys": + 8-O "Omigod!!" (done "rm -rf *" ?) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From eb154ba4def3a6d2fee9141870327e6d2f7bf421 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:13 +0200 Subject: [PATCH 1020/3340] - patchlevel 1128 --- 7.3.1128 | 284 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 284 insertions(+) create mode 100644 7.3.1128 diff --git a/7.3.1128 b/7.3.1128 new file mode 100644 index 00000000..6b8e05a3 --- /dev/null +++ b/7.3.1128 @@ -0,0 +1,284 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1128 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1128 +Problem: Now that the NFA engine handles everything every failure is a + syntax error. +Solution: Remove the syntax_error flag. +Files: src/regexp.c, src/regexp_nfa.c + + +*** ../vim-7.3.1127/src/regexp.c 2013-06-05 21:30:34.000000000 +0200 +--- src/regexp.c 2013-06-05 21:36:37.000000000 +0200 +*************** +*** 7924,7930 **** + regprog_T *prog = NULL; + char_u *expr = expr_arg; + +- syntax_error = FALSE; + regexp_engine = p_re; + + /* Check for prefix "\%#=", that sets the regexp engine */ +--- 7924,7929 ---- +*************** +*** 7971,7989 **** + f = fopen(BT_REGEXP_DEBUG_LOG_NAME, "a"); + if (f) + { +! if (!syntax_error) +! fprintf(f, "NFA engine could not handle \"%s\"\n", expr); +! else +! fprintf(f, "Syntax error in \"%s\"\n", expr); + fclose(f); + } + else + EMSG2("(NFA) Could not open \"%s\" to write !!!", + BT_REGEXP_DEBUG_LOG_NAME); +- /* +- if (syntax_error) +- EMSG("NFA Regexp: Syntax Error !"); +- */ + } + #endif + /* +--- 7970,7981 ---- + f = fopen(BT_REGEXP_DEBUG_LOG_NAME, "a"); + if (f) + { +! fprintf(f, "Syntax error in \"%s\"\n", expr); + fclose(f); + } + else + EMSG2("(NFA) Could not open \"%s\" to write !!!", + BT_REGEXP_DEBUG_LOG_NAME); + } + #endif + /* +*************** +*** 7992,8002 **** + * NFA engine. + */ + if (regexp_engine == AUTOMATIC_ENGINE) +! if (!syntax_error) +! prog = bt_regengine.regcomp(expr, re_flags); +! +! } /* endif prog==NULL */ +! + + return prog; + } +--- 7984,7991 ---- + * NFA engine. + */ + if (regexp_engine == AUTOMATIC_ENGINE) +! prog = bt_regengine.regcomp(expr, re_flags); +! } + + return prog; + } +*** ../vim-7.3.1127/src/regexp_nfa.c 2013-06-05 21:30:34.000000000 +0200 +--- src/regexp_nfa.c 2013-06-05 21:35:29.000000000 +0200 +*************** +*** 221,243 **** + + static char_u e_misplaced[] = N_("E866: (NFA regexp) Misplaced %c"); + +- /* +- * NFA errors can be of 3 types: +- * *** NFA runtime errors, when something unknown goes wrong. The NFA fails +- * silently and revert the to backtracking engine. +- * syntax_error = FALSE; +- * *** Regexp syntax errors, when the input regexp is not syntactically correct. +- * The NFA engine displays an error message, and nothing else happens. +- * syntax_error = TRUE +- * *** Unsupported features, when the input regexp uses an operator that is not +- * implemented in the NFA. The NFA engine fails silently, and reverts to the +- * old backtracking engine. +- * syntax_error = FALSE +- * "The NFA fails" means that "compiling the regexp with the NFA fails": +- * nfa_regcomp() returns FAIL. +- */ +- static int syntax_error = FALSE; +- + /* NFA regexp \ze operator encountered. */ + static int nfa_has_zend; + +--- 221,226 ---- +*************** +*** 692,698 **** + switch (c) + { + case NUL: +- syntax_error = TRUE; + EMSG_RET_FAIL(_("E865: (NFA) Regexp end encountered prematurely")); + + case Magic('^'): +--- 675,680 ---- +*************** +*** 814,820 **** + case Magic('|'): + case Magic('&'): + case Magic(')'): +- syntax_error = TRUE; + EMSGN(_(e_misplaced), no_Magic(c)); + return FAIL; + +--- 796,801 ---- +*************** +*** 825,831 **** + case Magic('*'): + case Magic('{'): + /* these should follow an atom, not form an atom */ +- syntax_error = TRUE; + EMSGN(_(e_misplaced), no_Magic(c)); + return FAIL; + +--- 806,811 ---- +*************** +*** 902,908 **** + break; + #endif + default: +- syntax_error = TRUE; + EMSGN(_("E867: (NFA) Unknown operator '\\z%c'"), + no_Magic(c)); + return FAIL; +--- 882,887 ---- +*************** +*** 1023,1029 **** + break; + } + } +- syntax_error = TRUE; + EMSGN(_("E867: (NFA) Unknown operator '\\%%%c'"), + no_Magic(c)); + return FAIL; +--- 1002,1007 ---- +*************** +*** 1359,1368 **** + } /* if exists closing ] */ + + if (reg_strict) +- { +- syntax_error = TRUE; + EMSG_RET_FAIL(_(e_missingbracket)); +- } + /* FALLTHROUGH */ + + default: +--- 1337,1343 ---- +*************** +*** 1512,1518 **** + } + if (i == 0) + { +- syntax_error = TRUE; + EMSGN(_("E869: (NFA) Unknown operator '\\@%c'"), op); + return FAIL; + } +--- 1487,1492 ---- +*************** +*** 1543,1552 **** + greedy = FALSE; + } + if (!read_limits(&minval, &maxval)) +- { +- syntax_error = TRUE; + EMSG_RET_FAIL(_("E870: (NFA regexp) Error reading repetition limits")); +! } + /* {0,inf}, {0,} and {} are equivalent to + * * */ + if (minval == 0 && maxval == MAX_LIMIT) +--- 1517,1524 ---- + greedy = FALSE; + } + if (!read_limits(&minval, &maxval)) + EMSG_RET_FAIL(_("E870: (NFA regexp) Error reading repetition limits")); +! + /* {0,inf}, {0,} and {} are equivalent to + * * */ + if (minval == 0 && maxval == MAX_LIMIT) +*************** +*** 1614,1624 **** + } /* end switch */ + + if (re_multi_type(peekchr()) != NOT_MULTI) +- { + /* Can't have a multi follow a multi. */ +- syntax_error = TRUE; + EMSG_RET_FAIL(_("E871: (NFA regexp) Can't have a multi follow a multi !")); +- } + + return OK; + } +--- 1586,1593 ---- +*************** +*** 1767,1776 **** + if (paren == REG_PAREN) + { + if (regnpar >= NSUBEXP) /* Too many `(' */ +- { +- syntax_error = TRUE; + EMSG_RET_FAIL(_("E872: (NFA regexp) Too many '('")); +- } + parno = regnpar++; + } + #ifdef FEAT_SYN_HL +--- 1736,1742 ---- +*************** +*** 1778,1787 **** + { + /* Make a ZOPEN node. */ + if (regnzpar >= NSUBEXP) +- { +- syntax_error = TRUE; + EMSG_RET_FAIL(_("E879: (NFA regexp) Too many \\z(")); +- } + parno = regnzpar++; + } + #endif +--- 1744,1750 ---- +*************** +*** 1800,1806 **** + /* Check for proper termination. */ + if (paren != REG_NOPAREN && getchr() != Magic(')')) + { +- syntax_error = TRUE; + if (paren == REG_NPAREN) + EMSG2_RET_FAIL(_(e_unmatchedpp), reg_magic == MAGIC_ALL); + else +--- 1763,1768 ---- +*************** +*** 1808,1814 **** + } + else if (paren == REG_NOPAREN && peekchr() != NUL) + { +- syntax_error = TRUE; + if (peekchr() == Magic(')')) + EMSG2_RET_FAIL(_(e_unmatchedpar), reg_magic == MAGIC_ALL); + else +--- 1770,1775 ---- +*** ../vim-7.3.1127/src/version.c 2013-06-05 21:30:34.000000000 +0200 +--- src/version.c 2013-06-05 21:42:28.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1128, + /**/ + +-- +From "know your smileys": + +<(:-) The Pope + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c44dc53659f1042996bc8fc746be12cb27e58ff4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:14 +0200 Subject: [PATCH 1021/3340] - patchlevel 1129 --- 7.3.1129 | 699 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 699 insertions(+) create mode 100644 7.3.1129 diff --git a/7.3.1129 b/7.3.1129 new file mode 100644 index 00000000..00e2d1f1 --- /dev/null +++ b/7.3.1129 @@ -0,0 +1,699 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1129 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1129 +Problem: Can't see what pattern in syntax highlighting is slow. +Solution: Add the ":syntime" command. +Files: src/structs.h, src/syntax.c, src/ex_cmds.h, src/ex_docmd.c, + src/proto/syntax.pro, src/ex_cmds2.c, src/proto/ex_cmds2.pro, + runtime/doc/syntax.txt + + +*** ../vim-7.3.1128/src/structs.h 2013-05-19 19:16:25.000000000 +0200 +--- src/structs.h 2013-06-06 12:24:08.000000000 +0200 +*************** +*** 1206,1211 **** +--- 1206,1223 ---- + typedef struct qf_info_S qf_info_T; + #endif + ++ #ifdef FEAT_RELTIME ++ /* ++ * Used for :syntime: timing of executing a syntax pattern. ++ */ ++ typedef struct { ++ proftime_T total; /* total time used */ ++ proftime_T slowest; /* time of slowest call */ ++ long count; /* nr of times used */ ++ long match; /* nr of times matched */ ++ } syn_time_T; ++ #endif ++ + /* + * These are items normally related to a buffer. But when using ":ownsyntax" + * a window may have its own instance. +*************** +*** 1230,1235 **** +--- 1242,1250 ---- + long b_syn_sync_linebreaks; /* offset for multi-line pattern */ + char_u *b_syn_linecont_pat; /* line continuation pattern */ + regprog_T *b_syn_linecont_prog; /* line continuation program */ ++ #ifdef FEAT_RELTIME ++ syn_time_T b_syn_linecont_time; ++ #endif + int b_syn_linecont_ic; /* ignore-case flag for above */ + int b_syn_topgrp; /* for ":syntax include" */ + # ifdef FEAT_CONCEAL +*** ../vim-7.3.1128/src/syntax.c 2013-05-06 04:21:35.000000000 +0200 +--- src/syntax.c 2013-06-06 12:37:55.000000000 +0200 +*************** +*** 153,158 **** +--- 153,161 ---- + short sp_syn_match_id; /* highlight group ID of pattern */ + char_u *sp_pattern; /* regexp to match, pattern */ + regprog_T *sp_prog; /* regexp to match, program */ ++ #ifdef FEAT_RELTIME ++ syn_time_T sp_time; ++ #endif + int sp_ic; /* ignore-case flag for sp_prog */ + short sp_off_flags; /* see below */ + int sp_offsets[SPO_COUNT]; /* offsets */ +*************** +*** 269,274 **** +--- 272,279 ---- + */ + static int keepend_level = -1; + ++ static char msg_no_items[] = N_("No Syntax items defined for this buffer"); ++ + /* + * For the current state we need to remember more than just the idx. + * When si_m_endpos.lnum is 0, the items other than si_idx are unknown. +*************** +*** 395,400 **** +--- 400,420 ---- + static int in_id_list __ARGS((stateitem_T *item, short *cont_list, struct sp_syn *ssp, int contained)); + static int push_current_state __ARGS((int idx)); + static void pop_current_state __ARGS((void)); ++ #ifdef FEAT_RELTIME ++ static void syn_clear_time __ARGS((syn_time_T *tt)); ++ static void syntime_clear __ARGS((void)); ++ #ifdef __BORLANDC__ ++ static int _RTLENTRYF syn_compare_syntime __ARGS((const void *v1, const void *v2)); ++ #else ++ static int syn_compare_syntime __ARGS((const void *v1, const void *v2)); ++ #endif ++ static void syntime_report __ARGS((void)); ++ static int syn_time_on = FALSE; ++ # define IF_SYN_TIME(p) (p) ++ #else ++ # define IF_SYN_TIME(p) NULL ++ typedef int syn_time_T; ++ #endif + + static void syn_stack_apply_changes_block __ARGS((synblock_T *block, buf_T *buf)); + static void find_endpos __ARGS((int idx, lpos_T *startpos, lpos_T *m_endpos, lpos_T *hl_endpos, long *flagsp, lpos_T *end_endpos, int *end_idx, reg_extmatch_T *start_ext)); +*************** +*** 406,412 **** + static void syn_add_end_off __ARGS((lpos_T *result, regmmatch_T *regmatch, synpat_T *spp, int idx, int extra)); + static void syn_add_start_off __ARGS((lpos_T *result, regmmatch_T *regmatch, synpat_T *spp, int idx, int extra)); + static char_u *syn_getcurline __ARGS((void)); +! static int syn_regexec __ARGS((regmmatch_T *rmp, linenr_T lnum, colnr_T col)); + static int check_keyword_id __ARGS((char_u *line, int startcol, int *endcol, long *flags, short **next_list, stateitem_T *cur_si, int *ccharp)); + static void syn_cmd_case __ARGS((exarg_T *eap, int syncing)); + static void syn_cmd_spell __ARGS((exarg_T *eap, int syncing)); +--- 426,432 ---- + static void syn_add_end_off __ARGS((lpos_T *result, regmmatch_T *regmatch, synpat_T *spp, int idx, int extra)); + static void syn_add_start_off __ARGS((lpos_T *result, regmmatch_T *regmatch, synpat_T *spp, int idx, int extra)); + static char_u *syn_getcurline __ARGS((void)); +! static int syn_regexec __ARGS((regmmatch_T *rmp, linenr_T lnum, colnr_T col, syn_time_T *st)); + static int check_keyword_id __ARGS((char_u *line, int startcol, int *endcol, long *flags, short **next_list, stateitem_T *cur_si, int *ccharp)); + static void syn_cmd_case __ARGS((exarg_T *eap, int syncing)); + static void syn_cmd_spell __ARGS((exarg_T *eap, int syncing)); +*************** +*** 977,983 **** + { + regmatch.rmm_ic = syn_block->b_syn_linecont_ic; + regmatch.regprog = syn_block->b_syn_linecont_prog; +! return syn_regexec(®match, lnum, (colnr_T)0); + } + return FALSE; + } +--- 997,1004 ---- + { + regmatch.rmm_ic = syn_block->b_syn_linecont_ic; + regmatch.regprog = syn_block->b_syn_linecont_prog; +! return syn_regexec(®match, lnum, (colnr_T)0, +! IF_SYN_TIME(&syn_block->b_syn_linecont_time)); + } + return FALSE; + } +*************** +*** 2068,2075 **** + + regmatch.rmm_ic = spp->sp_ic; + regmatch.regprog = spp->sp_prog; +! if (!syn_regexec(®match, current_lnum, +! (colnr_T)lc_col)) + { + /* no match in this line, try another one */ + spp->sp_startcol = MAXCOL; +--- 2089,2098 ---- + + regmatch.rmm_ic = spp->sp_ic; + regmatch.regprog = spp->sp_prog; +! if (!syn_regexec(®match, +! current_lnum, +! (colnr_T)lc_col, +! IF_SYN_TIME(&spp->sp_time))) + { + /* no match in this line, try another one */ + spp->sp_startcol = MAXCOL; +*************** +*** 2950,2956 **** + + regmatch.rmm_ic = spp->sp_ic; + regmatch.regprog = spp->sp_prog; +! if (syn_regexec(®match, startpos->lnum, lc_col)) + { + if (best_idx == -1 || regmatch.startpos[0].col + < best_regmatch.startpos[0].col) +--- 2973,2980 ---- + + regmatch.rmm_ic = spp->sp_ic; + regmatch.regprog = spp->sp_prog; +! if (syn_regexec(®match, startpos->lnum, lc_col, +! IF_SYN_TIME(&spp->sp_time))) + { + if (best_idx == -1 || regmatch.startpos[0].col + < best_regmatch.startpos[0].col) +*************** +*** 2981,2987 **** + lc_col = 0; + regmatch.rmm_ic = spp_skip->sp_ic; + regmatch.regprog = spp_skip->sp_prog; +! if (syn_regexec(®match, startpos->lnum, lc_col) + && regmatch.startpos[0].col + <= best_regmatch.startpos[0].col) + { +--- 3005,3012 ---- + lc_col = 0; + regmatch.rmm_ic = spp_skip->sp_ic; + regmatch.regprog = spp_skip->sp_prog; +! if (syn_regexec(®match, startpos->lnum, lc_col, +! IF_SYN_TIME(&spp_skip->sp_time)) + && regmatch.startpos[0].col + <= best_regmatch.startpos[0].col) + { +*************** +*** 3229,3241 **** + * Returns TRUE when there is a match. + */ + static int +! syn_regexec(rmp, lnum, col) + regmmatch_T *rmp; + linenr_T lnum; + colnr_T col; + { + rmp->rmm_maxcol = syn_buf->b_p_smc; +! if (vim_regexec_multi(rmp, syn_win, syn_buf, lnum, col, NULL) > 0) + { + rmp->startpos[0].lnum += lnum; + rmp->endpos[0].lnum += lnum; +--- 3254,3290 ---- + * Returns TRUE when there is a match. + */ + static int +! syn_regexec(rmp, lnum, col, st) + regmmatch_T *rmp; + linenr_T lnum; + colnr_T col; ++ syn_time_T *st; + { ++ int r; ++ #ifdef FEAT_RELTIME ++ proftime_T pt; ++ ++ if (syn_time_on) ++ profile_start(&pt); ++ #endif ++ + rmp->rmm_maxcol = syn_buf->b_p_smc; +! r = vim_regexec_multi(rmp, syn_win, syn_buf, lnum, col, NULL); +! +! #ifdef FEAT_RELTIME +! if (syn_time_on) +! { +! profile_end(&pt); +! profile_add(&st->total, &pt); +! if (profile_cmp(&pt, &st->slowest) < 0) +! st->slowest = pt; +! ++st->count; +! if (r > 0) +! ++st->match; +! } +! #endif +! +! if (r > 0) + { + rmp->startpos[0].lnum += lnum; + rmp->endpos[0].lnum += lnum; +*************** +*** 3769,3775 **** + + if (!syntax_present(curwin)) + { +! MSG(_("No Syntax items defined for this buffer")); + return; + } + +--- 3818,3824 ---- + + if (!syntax_present(curwin)) + { +! MSG(_(msg_no_items)); + return; + } + +*************** +*** 5609,5614 **** +--- 5658,5666 ---- + if (ci->sp_prog == NULL) + return NULL; + ci->sp_ic = curwin->w_s->b_syn_ic; ++ #ifdef FEAT_RELTIME ++ syn_clear_time(&ci->sp_time); ++ #endif + + /* + * Check for a match, highlight or region offset. +*************** +*** 5783,5790 **** + cpo_save = p_cpo; + p_cpo = (char_u *)""; + curwin->w_s->b_syn_linecont_prog = +! vim_regcomp(curwin->w_s->b_syn_linecont_pat, RE_MAGIC); + p_cpo = cpo_save; + + if (curwin->w_s->b_syn_linecont_prog == NULL) + { +--- 5835,5845 ---- + cpo_save = p_cpo; + p_cpo = (char_u *)""; + curwin->w_s->b_syn_linecont_prog = +! vim_regcomp(curwin->w_s->b_syn_linecont_pat, RE_MAGIC); + p_cpo = cpo_save; ++ #ifdef FEAT_RELTIME ++ syn_clear_time(&curwin->w_s->b_syn_linecont_time); ++ #endif + + if (curwin->w_s->b_syn_linecont_prog == NULL) + { +*************** +*** 6471,6476 **** +--- 6526,6704 ---- + } + #endif + ++ #ifdef FEAT_RELTIME ++ /* ++ * ":syntime". ++ */ ++ void ++ ex_syntime(eap) ++ exarg_T *eap; ++ { ++ if (STRCMP(eap->arg, "on") == 0) ++ syn_time_on = TRUE; ++ else if (STRCMP(eap->arg, "off") == 0) ++ syn_time_on = FALSE; ++ else if (STRCMP(eap->arg, "clear") == 0) ++ syntime_clear(); ++ else if (STRCMP(eap->arg, "report") == 0) ++ syntime_report(); ++ else ++ EMSG2(_(e_invarg2), eap->arg); ++ } ++ ++ static void ++ syn_clear_time(st) ++ syn_time_T *st; ++ { ++ profile_zero(&st->total); ++ profile_zero(&st->slowest); ++ st->count = 0; ++ st->match = 0; ++ } ++ ++ /* ++ * Clear the syntax timing for the current buffer. ++ */ ++ static void ++ syntime_clear() ++ { ++ int idx; ++ synpat_T *spp; ++ ++ if (!syntax_present(curwin)) ++ { ++ MSG(_(msg_no_items)); ++ return; ++ } ++ for (idx = 0; idx < curwin->w_s->b_syn_patterns.ga_len; ++idx) ++ { ++ spp = &(SYN_ITEMS(curwin->w_s)[idx]); ++ syn_clear_time(&spp->sp_time); ++ } ++ } ++ ++ typedef struct ++ { ++ proftime_T total; ++ int count; ++ int match; ++ proftime_T slowest; ++ proftime_T average; ++ int id; ++ char_u *pattern; ++ } time_entry_T; ++ ++ static int ++ #ifdef __BORLANDC__ ++ _RTLENTRYF ++ #endif ++ syn_compare_syntime(v1, v2) ++ const void *v1; ++ const void *v2; ++ { ++ const time_entry_T *s1 = v1; ++ const time_entry_T *s2 = v2; ++ ++ return profile_cmp(&s1->total, &s2->total); ++ } ++ ++ /* ++ * Clear the syntax timing for the current buffer. ++ */ ++ static void ++ syntime_report() ++ { ++ int idx; ++ synpat_T *spp; ++ proftime_T tm; ++ int len; ++ proftime_T total_total; ++ int total_count = 0; ++ garray_T ga; ++ time_entry_T *p; ++ ++ if (!syntax_present(curwin)) ++ { ++ MSG(_(msg_no_items)); ++ return; ++ } ++ ++ ga_init2(&ga, sizeof(time_entry_T), 50); ++ profile_zero(&total_total); ++ for (idx = 0; idx < curwin->w_s->b_syn_patterns.ga_len; ++idx) ++ { ++ spp = &(SYN_ITEMS(curwin->w_s)[idx]); ++ if (spp->sp_time.count > 0) ++ { ++ ga_grow(&ga, 1); ++ p = ((time_entry_T *)ga.ga_data) + ga.ga_len; ++ p->total = spp->sp_time.total; ++ profile_add(&total_total, &spp->sp_time.total); ++ p->count = spp->sp_time.count; ++ p->match = spp->sp_time.match; ++ total_count += spp->sp_time.count; ++ p->slowest = spp->sp_time.slowest; ++ # ifdef FEAT_FLOAT ++ profile_divide(&spp->sp_time.total, spp->sp_time.count, &tm); ++ p->average = tm; ++ # endif ++ p->id = spp->sp_syn.id; ++ p->pattern = spp->sp_pattern; ++ ++ga.ga_len; ++ } ++ } ++ ++ /* sort on total time */ ++ qsort(ga.ga_data, (size_t)ga.ga_len, sizeof(time_entry_T), syn_compare_syntime); ++ ++ MSG_PUTS_TITLE(_(" TOTAL COUNT MATCH SLOWEST AVERAGE NAME PATTERN")); ++ MSG_PUTS("\n"); ++ for (idx = 0; idx < ga.ga_len && !got_int; ++idx) ++ { ++ spp = &(SYN_ITEMS(curwin->w_s)[idx]); ++ p = ((time_entry_T *)ga.ga_data) + idx; ++ ++ MSG_PUTS(profile_msg(&p->total)); ++ MSG_PUTS(" "); /* make sure there is always a separating space */ ++ msg_advance(13); ++ msg_outnum(p->count); ++ MSG_PUTS(" "); ++ msg_advance(20); ++ msg_outnum(p->match); ++ MSG_PUTS(" "); ++ msg_advance(26); ++ MSG_PUTS(profile_msg(&p->slowest)); ++ MSG_PUTS(" "); ++ msg_advance(38); ++ # ifdef FEAT_FLOAT ++ MSG_PUTS(profile_msg(&p->average)); ++ MSG_PUTS(" "); ++ # endif ++ msg_advance(50); ++ msg_outtrans(HL_TABLE()[p->id - 1].sg_name); ++ MSG_PUTS(" "); ++ ++ msg_advance(69); ++ if (Columns < 80) ++ len = 20; /* will wrap anyway */ ++ else ++ len = Columns - 70; ++ if (len > (int)STRLEN(p->pattern)) ++ len = (int)STRLEN(p->pattern); ++ msg_outtrans_len(p->pattern, len); ++ MSG_PUTS("\n"); ++ } ++ if (!got_int) ++ { ++ MSG_PUTS("\n"); ++ MSG_PUTS(profile_msg(&total_total)); ++ msg_advance(13); ++ msg_outnum(total_count); ++ MSG_PUTS("\n"); ++ } ++ } ++ #endif ++ + #endif /* FEAT_SYN_HL */ + + /************************************** +*** ../vim-7.3.1128/src/ex_cmds.h 2013-05-17 16:39:59.000000000 +0200 +--- src/ex_cmds.h 2013-06-05 22:20:35.000000000 +0200 +*************** +*** 925,930 **** +--- 925,932 ---- + TRLBAR|CMDWIN), + EX(CMD_syntax, "syntax", ex_syntax, + EXTRA|NOTRLCOM|CMDWIN), ++ EX(CMD_syntime, "syntime", ex_syntime, ++ WORD1|TRLBAR|CMDWIN), + EX(CMD_syncbind, "syncbind", ex_syncbind, + TRLBAR), + EX(CMD_t, "t", ex_copymove, +*** ../vim-7.3.1128/src/ex_docmd.c 2013-06-02 19:22:05.000000000 +0200 +--- src/ex_docmd.c 2013-06-05 22:21:30.000000000 +0200 +*************** +*** 242,247 **** +--- 242,250 ---- + # define ex_syntax ex_ni + # define ex_ownsyntax ex_ni + #endif ++ #if !defined(FEAT_SYN_HL) || !defined(FEAT_RELTIME) ++ # define ex_syntime ex_ni ++ #endif + #ifndef FEAT_SPELL + # define ex_spell ex_ni + # define ex_mkspell ex_ni +*** ../vim-7.3.1128/src/proto/syntax.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/syntax.pro 2013-06-05 22:59:09.000000000 +0200 +*************** +*** 19,24 **** +--- 19,25 ---- + int syn_get_sub_char __ARGS((void)); + int syn_get_stack_item __ARGS((int i)); + int syn_get_foldlevel __ARGS((win_T *wp, long lnum)); ++ void ex_syntime __ARGS((exarg_T *eap)); + void init_highlight __ARGS((int both, int reset)); + int load_colors __ARGS((char_u *name)); + void do_highlight __ARGS((char_u *line, int forceit, int init)); +*** ../vim-7.3.1128/src/ex_cmds2.c 2013-05-06 04:50:26.000000000 +0200 +--- src/ex_cmds2.c 2013-06-06 12:14:52.000000000 +0200 +*************** +*** 958,963 **** +--- 958,993 ---- + + # endif /* FEAT_PROFILE || FEAT_RELTIME */ + ++ #if defined(FEAT_SYN_HL) && defined(FEAT_RELTIME) && defined(FEAT_FLOAT) ++ # if defined(HAVE_MATH_H) ++ # include ++ # endif ++ ++ /* ++ * Divide the time "tm" by "count" and store in "tm2". ++ */ ++ void ++ profile_divide(tm, count, tm2) ++ proftime_T *tm; ++ proftime_T *tm2; ++ int count; ++ { ++ if (count == 0) ++ profile_zero(tm2); ++ else ++ { ++ # ifdef WIN3264 ++ tm2->QuadPart = tm->QuadPart / count; ++ # else ++ double usec = (tm->tv_sec * 1000000.0 + tm->tv_usec) / count; ++ ++ tm2->tv_sec = floor(usec / 1000000.0); ++ tm2->tv_usec = round(usec - (tm2->tv_sec * 1000000.0)); ++ # endif ++ } ++ } ++ #endif ++ + # if defined(FEAT_PROFILE) || defined(PROTO) + /* + * Functions for profiling. +*************** +*** 1050,1056 **** + */ + int + profile_cmp(tm1, tm2) +! proftime_T *tm1, *tm2; + { + # ifdef WIN3264 + return (int)(tm2->QuadPart - tm1->QuadPart); +--- 1080,1086 ---- + */ + int + profile_cmp(tm1, tm2) +! const proftime_T *tm1, *tm2; + { + # ifdef WIN3264 + return (int)(tm2->QuadPart - tm1->QuadPart); +*** ../vim-7.3.1128/src/proto/ex_cmds2.pro 2012-06-29 12:57:03.000000000 +0200 +--- src/proto/ex_cmds2.pro 2013-06-06 12:14:57.000000000 +0200 +*************** +*** 17,28 **** + void profile_setlimit __ARGS((long msec, proftime_T *tm)); + int profile_passed_limit __ARGS((proftime_T *tm)); + void profile_zero __ARGS((proftime_T *tm)); + void profile_add __ARGS((proftime_T *tm, proftime_T *tm2)); + void profile_self __ARGS((proftime_T *self, proftime_T *total, proftime_T *children)); + void profile_get_wait __ARGS((proftime_T *tm)); + void profile_sub_wait __ARGS((proftime_T *tm, proftime_T *tma)); + int profile_equal __ARGS((proftime_T *tm1, proftime_T *tm2)); +! int profile_cmp __ARGS((proftime_T *tm1, proftime_T *tm2)); + void ex_profile __ARGS((exarg_T *eap)); + char_u *get_profile_name __ARGS((expand_T *xp, int idx)); + void set_context_in_profile_cmd __ARGS((expand_T *xp, char_u *arg)); +--- 17,29 ---- + void profile_setlimit __ARGS((long msec, proftime_T *tm)); + int profile_passed_limit __ARGS((proftime_T *tm)); + void profile_zero __ARGS((proftime_T *tm)); ++ void profile_divide __ARGS((proftime_T *tm, int count, proftime_T *tm2)); + void profile_add __ARGS((proftime_T *tm, proftime_T *tm2)); + void profile_self __ARGS((proftime_T *self, proftime_T *total, proftime_T *children)); + void profile_get_wait __ARGS((proftime_T *tm)); + void profile_sub_wait __ARGS((proftime_T *tm, proftime_T *tma)); + int profile_equal __ARGS((proftime_T *tm1, proftime_T *tm2)); +! int profile_cmp __ARGS((const proftime_T *tm1, const proftime_T *tm2)); + void ex_profile __ARGS((exarg_T *eap)); + char_u *get_profile_name __ARGS((expand_T *xp, int idx)); + void set_context_in_profile_cmd __ARGS((expand_T *xp, char_u *arg)); +*** ../vim-7.3.1128/runtime/doc/syntax.txt 2010-08-15 21:57:12.000000000 +0200 +--- runtime/doc/syntax.txt 2013-06-06 13:00:36.000000000 +0200 +*************** +*** 37,42 **** +--- 37,43 ---- + 15. Highlighting tags |tag-highlight| + 16. Window-local syntax |:ownsyntax| + 17. Color xterms |xterm-color| ++ 18. When syntax is slow |:syntime| + + {Vi does not have any of these commands} + +*************** +*** 4754,4757 **** +--- 5087,5146 ---- + that Setup / Font / Enable Bold is NOT enabled. + (info provided by John Love-Jensen ) + ++ ++ ============================================================================== ++ 18. When syntax is slow *:syntime* ++ ++ This is aimed at authors of a syntax file. ++ ++ If your syntax causes redrawing to be slow, here are a few hints on making it ++ faster. To see slowness switch on some features that usually interfere, such ++ as 'relativenumber' and |folding|. ++ ++ To find out what patterns are consuming most time, get an overview with this ++ sequence: > ++ :syntime on ++ [ redraw the text at least once with CTRL-L ] ++ :syntime report ++ ++ This will display a list of syntax patterns that were used, sorted by the time ++ it took to match them against the text. ++ ++ :syntime on Start measuring syntax times. This will add some ++ overhead to compute the time spent on syntax pattern ++ matching. ++ ++ :syntime off Stop measuring syntax times. ++ ++ :syntime clear Set all the counters to zero, restart measuring. ++ ++ :syntime report Show the syntax items used since ":syntime on" in the ++ current window. Use a wider display to see more of ++ the output. ++ ++ The list is sorted by total time. The columns are: ++ TOTAL Total time in seconds spent on ++ matching this pattern. ++ COUNT Number of times the pattern was used. ++ MATCH Number of times the pattern actually ++ matched ++ SLOWEST The longest time for one try. ++ AVERAGE The average time for one try. ++ NAME Name of the syntax item. Note that ++ this is not unique. ++ PATTERN The pattern being used. ++ ++ Pattern matching gets slow when it has to try many alternatives. Try to ++ include as much literal text as possible to reduce the number of ways a ++ pattern does NOT match. ++ ++ When using the "\@<=" and "\@ Date: Fri, 14 Jun 2013 00:28:15 +0200 Subject: [PATCH 1022/3340] - patchlevel 1130 --- 7.3.1130 | 209 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 209 insertions(+) create mode 100644 7.3.1130 diff --git a/7.3.1130 b/7.3.1130 new file mode 100644 index 00000000..0169e7a8 --- /dev/null +++ b/7.3.1130 @@ -0,0 +1,209 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1130 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1130 (after 7.3.1129) +Problem: Can't build with anything but huge features. +Solution: Check for FEAT_PROFILE. (Yasuhiro Matsumoto) +Files: src/ex_docmd.c, src/structs.h, src/syntax.c + + +*** ../vim-7.3.1129/src/ex_docmd.c 2013-06-06 14:01:35.000000000 +0200 +--- src/ex_docmd.c 2013-06-06 14:49:26.000000000 +0200 +*************** +*** 242,248 **** + # define ex_syntax ex_ni + # define ex_ownsyntax ex_ni + #endif +! #if !defined(FEAT_SYN_HL) || !defined(FEAT_RELTIME) + # define ex_syntime ex_ni + #endif + #ifndef FEAT_SPELL +--- 242,248 ---- + # define ex_syntax ex_ni + # define ex_ownsyntax ex_ni + #endif +! #if !defined(FEAT_SYN_HL) || !defined(FEAT_PROFILE) + # define ex_syntime ex_ni + #endif + #ifndef FEAT_SPELL +*** ../vim-7.3.1129/src/structs.h 2013-06-06 14:01:35.000000000 +0200 +--- src/structs.h 2013-06-06 14:49:26.000000000 +0200 +*************** +*** 1206,1212 **** + typedef struct qf_info_S qf_info_T; + #endif + +! #ifdef FEAT_RELTIME + /* + * Used for :syntime: timing of executing a syntax pattern. + */ +--- 1206,1212 ---- + typedef struct qf_info_S qf_info_T; + #endif + +! #ifdef FEAT_PROFILE + /* + * Used for :syntime: timing of executing a syntax pattern. + */ +*************** +*** 1242,1248 **** + long b_syn_sync_linebreaks; /* offset for multi-line pattern */ + char_u *b_syn_linecont_pat; /* line continuation pattern */ + regprog_T *b_syn_linecont_prog; /* line continuation program */ +! #ifdef FEAT_RELTIME + syn_time_T b_syn_linecont_time; + #endif + int b_syn_linecont_ic; /* ignore-case flag for above */ +--- 1242,1248 ---- + long b_syn_sync_linebreaks; /* offset for multi-line pattern */ + char_u *b_syn_linecont_pat; /* line continuation pattern */ + regprog_T *b_syn_linecont_prog; /* line continuation program */ +! #ifdef FEAT_PROFILE + syn_time_T b_syn_linecont_time; + #endif + int b_syn_linecont_ic; /* ignore-case flag for above */ +*** ../vim-7.3.1129/src/syntax.c 2013-06-06 14:01:35.000000000 +0200 +--- src/syntax.c 2013-06-06 14:49:26.000000000 +0200 +*************** +*** 153,159 **** + short sp_syn_match_id; /* highlight group ID of pattern */ + char_u *sp_pattern; /* regexp to match, pattern */ + regprog_T *sp_prog; /* regexp to match, program */ +! #ifdef FEAT_RELTIME + syn_time_T sp_time; + #endif + int sp_ic; /* ignore-case flag for sp_prog */ +--- 153,159 ---- + short sp_syn_match_id; /* highlight group ID of pattern */ + char_u *sp_pattern; /* regexp to match, pattern */ + regprog_T *sp_prog; /* regexp to match, program */ +! #ifdef FEAT_PROFILE + syn_time_T sp_time; + #endif + int sp_ic; /* ignore-case flag for sp_prog */ +*************** +*** 400,406 **** + static int in_id_list __ARGS((stateitem_T *item, short *cont_list, struct sp_syn *ssp, int contained)); + static int push_current_state __ARGS((int idx)); + static void pop_current_state __ARGS((void)); +! #ifdef FEAT_RELTIME + static void syn_clear_time __ARGS((syn_time_T *tt)); + static void syntime_clear __ARGS((void)); + #ifdef __BORLANDC__ +--- 400,406 ---- + static int in_id_list __ARGS((stateitem_T *item, short *cont_list, struct sp_syn *ssp, int contained)); + static int push_current_state __ARGS((int idx)); + static void pop_current_state __ARGS((void)); +! #ifdef FEAT_PROFILE + static void syn_clear_time __ARGS((syn_time_T *tt)); + static void syntime_clear __ARGS((void)); + #ifdef __BORLANDC__ +*************** +*** 3261,3267 **** + syn_time_T *st; + { + int r; +! #ifdef FEAT_RELTIME + proftime_T pt; + + if (syn_time_on) +--- 3261,3267 ---- + syn_time_T *st; + { + int r; +! #ifdef FEAT_PROFILE + proftime_T pt; + + if (syn_time_on) +*************** +*** 3271,3277 **** + rmp->rmm_maxcol = syn_buf->b_p_smc; + r = vim_regexec_multi(rmp, syn_win, syn_buf, lnum, col, NULL); + +! #ifdef FEAT_RELTIME + if (syn_time_on) + { + profile_end(&pt); +--- 3271,3277 ---- + rmp->rmm_maxcol = syn_buf->b_p_smc; + r = vim_regexec_multi(rmp, syn_win, syn_buf, lnum, col, NULL); + +! #ifdef FEAT_PROFILE + if (syn_time_on) + { + profile_end(&pt); +*************** +*** 5658,5664 **** + if (ci->sp_prog == NULL) + return NULL; + ci->sp_ic = curwin->w_s->b_syn_ic; +! #ifdef FEAT_RELTIME + syn_clear_time(&ci->sp_time); + #endif + +--- 5658,5664 ---- + if (ci->sp_prog == NULL) + return NULL; + ci->sp_ic = curwin->w_s->b_syn_ic; +! #ifdef FEAT_PROFILE + syn_clear_time(&ci->sp_time); + #endif + +*************** +*** 5837,5843 **** + curwin->w_s->b_syn_linecont_prog = + vim_regcomp(curwin->w_s->b_syn_linecont_pat, RE_MAGIC); + p_cpo = cpo_save; +! #ifdef FEAT_RELTIME + syn_clear_time(&curwin->w_s->b_syn_linecont_time); + #endif + +--- 5837,5843 ---- + curwin->w_s->b_syn_linecont_prog = + vim_regcomp(curwin->w_s->b_syn_linecont_pat, RE_MAGIC); + p_cpo = cpo_save; +! #ifdef FEAT_PROFILE + syn_clear_time(&curwin->w_s->b_syn_linecont_time); + #endif + +*************** +*** 6526,6532 **** + } + #endif + +! #ifdef FEAT_RELTIME + /* + * ":syntime". + */ +--- 6526,6532 ---- + } + #endif + +! #ifdef FEAT_PROFILE + /* + * ":syntime". + */ +*** ../vim-7.3.1129/src/version.c 2013-06-06 14:01:36.000000000 +0200 +--- src/version.c 2013-06-06 14:54:31.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1130, + /**/ + +-- +From "know your smileys": + @:-() Elvis Presley + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a99fffd9385b97a35642c24796c0bd6c008bf9b9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:16 +0200 Subject: [PATCH 1023/3340] - patchlevel 1131 --- 7.3.1131 | 162 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 162 insertions(+) create mode 100644 7.3.1131 diff --git a/7.3.1131 b/7.3.1131 new file mode 100644 index 00000000..1c51072e --- /dev/null +++ b/7.3.1131 @@ -0,0 +1,162 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1131 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1131 +Problem: New regexp engine is a bit slow. +Solution: Do not clear the state list. Don't copy syntax submatches when + not used. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1130/src/regexp_nfa.c 2013-06-05 21:42:49.000000000 +0200 +--- src/regexp_nfa.c 2013-06-06 15:57:14.000000000 +0200 +*************** +*** 319,325 **** + post_start = (int *)lalloc(postfix_size, TRUE); + if (post_start == NULL) + return FAIL; +- vim_memset(post_start, 0, postfix_size); + post_ptr = post_start; + post_end = post_start + nstate_max; + nfa_has_zend = FALSE; +--- 319,324 ---- +*************** +*** 347,353 **** + if (new_start == NULL) + return FAIL; + mch_memmove(new_start, post_start, nstate_max * sizeof(int)); +- vim_memset(new_start + nstate_max, 0, 1000 * sizeof(int)); + old_start = post_start; + post_start = new_start; + post_ptr = new_start + (post_ptr - old_start); +--- 346,351 ---- +*************** +*** 4127,4137 **** + + /* Allocate memory for the lists of nodes. */ + size = (nstate + 1) * sizeof(nfa_thread_T); +! list[0].t = (nfa_thread_T *)lalloc_clear(size, TRUE); + list[0].len = nstate + 1; +! list[1].t = (nfa_thread_T *)lalloc_clear(size, TRUE); + list[1].len = nstate + 1; +! list[2].t = (nfa_thread_T *)lalloc_clear(size, TRUE); + list[2].len = nstate + 1; + if (list[0].t == NULL || list[1].t == NULL || list[2].t == NULL) + goto theend; +--- 4125,4135 ---- + + /* Allocate memory for the lists of nodes. */ + size = (nstate + 1) * sizeof(nfa_thread_T); +! list[0].t = (nfa_thread_T *)lalloc(size, TRUE); + list[0].len = nstate + 1; +! list[1].t = (nfa_thread_T *)lalloc(size, TRUE); + list[1].len = nstate + 1; +! list[2].t = (nfa_thread_T *)lalloc(size, TRUE); + list[2].len = nstate + 1; + if (list[0].t == NULL || list[1].t == NULL || list[2].t == NULL) + goto theend; +*************** +*** 4390,4396 **** + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->subs.norm, &m->norm); + #ifdef FEAT_SYN_HL +! copy_sub_off(&t->subs.synt, &m->synt); + #endif + + /* t->state->out1 is the corresponding +--- 4388,4395 ---- + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->subs.norm, &m->norm); + #ifdef FEAT_SYN_HL +! if (nfa_has_zsubexpr) +! copy_sub_off(&t->subs.synt, &m->synt); + #endif + + /* t->state->out1 is the corresponding +*************** +*** 4441,4447 **** + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->subs.norm, &m->norm); + #ifdef FEAT_SYN_HL +! copy_sub_off(&t->subs.synt, &m->synt); + #endif + /* Now we need to skip over the matched text and then + * continue with what follows. */ +--- 4440,4447 ---- + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->subs.norm, &m->norm); + #ifdef FEAT_SYN_HL +! if (nfa_has_zsubexpr) +! copy_sub_off(&t->subs.synt, &m->synt); + #endif + /* Now we need to skip over the matched text and then + * continue with what follows. */ +*************** +*** 5053,5059 **** + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->pim->subs.norm, &m->norm); + #ifdef FEAT_SYN_HL +! copy_sub_off(&t->pim->subs.synt, &m->synt); + #endif + } + } +--- 5053,5060 ---- + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->pim->subs.norm, &m->norm); + #ifdef FEAT_SYN_HL +! if (nfa_has_zsubexpr) +! copy_sub_off(&t->pim->subs.synt, &m->synt); + #endif + } + } +*************** +*** 5074,5080 **** + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->subs.norm, &t->pim->subs.norm); + #ifdef FEAT_SYN_HL +! copy_sub_off(&t->subs.synt, &t->pim->subs.synt); + #endif + } + else +--- 5075,5082 ---- + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->subs.norm, &t->pim->subs.norm); + #ifdef FEAT_SYN_HL +! if (nfa_has_zsubexpr) +! copy_sub_off(&t->subs.synt, &t->pim->subs.synt); + #endif + } + else +*************** +*** 5440,5446 **** + prog = (nfa_regprog_T *)lalloc(prog_size, TRUE); + if (prog == NULL) + goto fail; +- vim_memset(prog, 0, prog_size); + state_ptr = prog->state; + + /* +--- 5442,5447 ---- +*** ../vim-7.3.1130/src/version.c 2013-06-06 14:55:16.000000000 +0200 +--- src/version.c 2013-06-06 16:21:32.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1131, + /**/ + +-- +There's no place like $(HOME)! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4f56804957f4bcff4380813618cb6311a70f196e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:17 +0200 Subject: [PATCH 1024/3340] - patchlevel 1132 --- 7.3.1132 | 87 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 87 insertions(+) create mode 100644 7.3.1132 diff --git a/7.3.1132 b/7.3.1132 new file mode 100644 index 00000000..d7ac4a33 --- /dev/null +++ b/7.3.1132 @@ -0,0 +1,87 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1132 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1132 +Problem: Crash when debugging regexp. +Solution: Do not try to dump subexpr that were not set. Skip over count of + \% items. +Files: src/regexp.c, src/regexp_nfa.c + + +*** ../vim-7.3.1131/src/regexp.c 2013-06-05 21:42:49.000000000 +0200 +--- src/regexp.c 2013-06-06 18:04:09.000000000 +0200 +*************** +*** 6548,6553 **** +--- 6548,6559 ---- + fprintf(f, " count %ld", OPERAND_MIN(s)); + s += 4; + } ++ else if (op == RE_LNUM || op == RE_COL || op == RE_VCOL) ++ { ++ /* one int plus comperator */ ++ fprintf(f, " count %ld", OPERAND_MIN(s)); ++ s += 5; ++ } + s += 3; + if (op == ANYOF || op == ANYOF + ADD_NL + || op == ANYBUT || op == ANYBUT + ADD_NL +*** ../vim-7.3.1131/src/regexp_nfa.c 2013-06-06 16:22:01.000000000 +0200 +--- src/regexp_nfa.c 2013-06-06 18:03:27.000000000 +0200 +*************** +*** 256,262 **** + /* 0 for first call to nfa_regmatch(), 1 for recursive call. */ + static int nfa_ll_index = 0; + +! static int nfa_regcomp_start __ARGS((char_u*expr, int re_flags)); + static int nfa_recognize_char_class __ARGS((char_u *start, char_u *end, int extra_newl)); + static int nfa_emit_equi_class __ARGS((int c, int neg)); + static int nfa_regatom __ARGS((void)); +--- 256,262 ---- + /* 0 for first call to nfa_regmatch(), 1 for recursive call. */ + static int nfa_ll_index = 0; + +! static int nfa_regcomp_start __ARGS((char_u *expr, int re_flags)); + static int nfa_recognize_char_class __ARGS((char_u *start, char_u *end, int extra_newl)); + static int nfa_emit_equi_class __ARGS((int c, int neg)); + static int nfa_regatom __ARGS((void)); +*************** +*** 2927,2933 **** + { + log_subexpr(&subs->norm); + # ifdef FEAT_SYN_HL +! log_subexpr(&subs->synt); + # endif + } + +--- 2927,2934 ---- + { + log_subexpr(&subs->norm); + # ifdef FEAT_SYN_HL +! if (nfa_has_zsubexpr) +! log_subexpr(&subs->synt); + # endif + } + +*** ../vim-7.3.1131/src/version.c 2013-06-06 16:22:01.000000000 +0200 +--- src/version.c 2013-06-06 17:58:00.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1132, + /**/ + +-- +Momento mori, ergo carpe diem + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From be765df33bbe3608aada7783f3494aef51a31b63 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:18 +0200 Subject: [PATCH 1025/3340] - patchlevel 1133 --- 7.3.1133 | 358 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 358 insertions(+) create mode 100644 7.3.1133 diff --git a/7.3.1133 b/7.3.1133 new file mode 100644 index 00000000..5882b75c --- /dev/null +++ b/7.3.1133 @@ -0,0 +1,358 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1133 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1133 +Problem: New regexp engine is a bit slow. +Solution: Skip ahead to a character that must match. Don't try matching a + "^" patter past the start of line. +Files: src/regexp_nfa.c, src/regexp.h + + +*** ../vim-7.3.1132/src/regexp_nfa.c 2013-06-06 18:04:47.000000000 +0200 +--- src/regexp_nfa.c 2013-06-06 18:37:23.000000000 +0200 +*************** +*** 257,262 **** +--- 257,264 ---- + static int nfa_ll_index = 0; + + static int nfa_regcomp_start __ARGS((char_u *expr, int re_flags)); ++ static int nfa_get_reganch __ARGS((nfa_state_T *start, int depth)); ++ static int nfa_get_regstart __ARGS((nfa_state_T *start, int depth)); + static int nfa_recognize_char_class __ARGS((char_u *start, char_u *end, int extra_newl)); + static int nfa_emit_equi_class __ARGS((int c, int neg)); + static int nfa_regatom __ARGS((void)); +*************** +*** 331,336 **** +--- 333,487 ---- + } + + /* ++ * Figure out if the NFA state list starts with an anchor, must match at start ++ * of the line. ++ */ ++ static int ++ nfa_get_reganch(start, depth) ++ nfa_state_T *start; ++ int depth; ++ { ++ nfa_state_T *p = start; ++ ++ if (depth > 4) ++ return 0; ++ ++ while (p != NULL) ++ { ++ switch (p->c) ++ { ++ case NFA_BOL: ++ case NFA_BOF: ++ return 1; /* yes! */ ++ ++ case NFA_ZSTART: ++ case NFA_ZEND: ++ case NFA_CURSOR: ++ case NFA_VISUAL: ++ ++ case NFA_MOPEN: ++ case NFA_MOPEN1: ++ case NFA_MOPEN2: ++ case NFA_MOPEN3: ++ case NFA_MOPEN4: ++ case NFA_MOPEN5: ++ case NFA_MOPEN6: ++ case NFA_MOPEN7: ++ case NFA_MOPEN8: ++ case NFA_MOPEN9: ++ case NFA_NOPEN: ++ #ifdef FEAT_SYN_HL ++ case NFA_ZOPEN: ++ case NFA_ZOPEN1: ++ case NFA_ZOPEN2: ++ case NFA_ZOPEN3: ++ case NFA_ZOPEN4: ++ case NFA_ZOPEN5: ++ case NFA_ZOPEN6: ++ case NFA_ZOPEN7: ++ case NFA_ZOPEN8: ++ case NFA_ZOPEN9: ++ #endif ++ p = p->out; ++ break; ++ ++ case NFA_SPLIT: ++ return nfa_get_reganch(p->out, depth + 1) ++ && nfa_get_reganch(p->out1, depth + 1); ++ ++ default: ++ return 0; /* noooo */ ++ } ++ } ++ return 0; ++ } ++ ++ /* ++ * Figure out if the NFA state list starts with a character which must match ++ * at start of the match. ++ */ ++ static int ++ nfa_get_regstart(start, depth) ++ nfa_state_T *start; ++ int depth; ++ { ++ nfa_state_T *p = start; ++ ++ if (depth > 4) ++ return 0; ++ ++ while (p != NULL) ++ { ++ switch (p->c) ++ { ++ /* all kinds of zero-width matches */ ++ case NFA_BOL: ++ case NFA_BOF: ++ case NFA_BOW: ++ case NFA_EOW: ++ case NFA_ZSTART: ++ case NFA_ZEND: ++ case NFA_CURSOR: ++ case NFA_VISUAL: ++ case NFA_LNUM: ++ case NFA_LNUM_GT: ++ case NFA_LNUM_LT: ++ case NFA_COL: ++ case NFA_COL_GT: ++ case NFA_COL_LT: ++ case NFA_VCOL: ++ case NFA_VCOL_GT: ++ case NFA_VCOL_LT: ++ case NFA_MARK: ++ case NFA_MARK_GT: ++ case NFA_MARK_LT: ++ ++ case NFA_MOPEN: ++ case NFA_MOPEN1: ++ case NFA_MOPEN2: ++ case NFA_MOPEN3: ++ case NFA_MOPEN4: ++ case NFA_MOPEN5: ++ case NFA_MOPEN6: ++ case NFA_MOPEN7: ++ case NFA_MOPEN8: ++ case NFA_MOPEN9: ++ case NFA_NOPEN: ++ #ifdef FEAT_SYN_HL ++ case NFA_ZOPEN: ++ case NFA_ZOPEN1: ++ case NFA_ZOPEN2: ++ case NFA_ZOPEN3: ++ case NFA_ZOPEN4: ++ case NFA_ZOPEN5: ++ case NFA_ZOPEN6: ++ case NFA_ZOPEN7: ++ case NFA_ZOPEN8: ++ case NFA_ZOPEN9: ++ #endif ++ p = p->out; ++ break; ++ ++ case NFA_SPLIT: ++ { ++ int c1 = nfa_get_regstart(p->out, depth + 1); ++ int c2 = nfa_get_regstart(p->out1, depth + 1); ++ ++ if (c1 == c2) ++ return c1; /* yes! */ ++ return 0; ++ } ++ ++ default: ++ if (p->c > 0 && !p->negated) ++ return p->c; /* yes! */ ++ return 0; ++ } ++ } ++ return 0; ++ } ++ ++ /* + * Allocate more space for post_start. Called when + * running above the estimated number of states. + */ +*************** +*** 2121,2126 **** +--- 2272,2281 ---- + if (debugf != NULL) + { + nfa_print_state(debugf, prog->start); ++ ++ fprintf(debugf, "reganch: %d\n", prog->reganch); ++ fprintf(debugf, "regstart: %d\n", prog->regstart); ++ + fclose(debugf); + } + } +*************** +*** 4248,4253 **** +--- 4403,4412 ---- + t = &neglist->t[0]; + neglist->n--; + listidx--; ++ #ifdef ENABLE_LOG ++ fprintf(log_fd, " using neglist entry, %d remaining\n", ++ neglist->n); ++ #endif + } + else + t = &thislist->t[listidx]; +*************** +*** 4688,4694 **** + + case NFA_END_NEG_RANGE: + /* This follows a series of negated nodes, like: +! * CHAR(x), NFA_NOT, CHAR(y), NFA_NOT etc. */ + if (curc > 0) + { + ll = nextlist; +--- 4847,4853 ---- + + case NFA_END_NEG_RANGE: + /* This follows a series of negated nodes, like: +! * NOT CHAR(x), NOT CHAR(y), etc. */ + if (curc > 0) + { + ll = nextlist; +*************** +*** 5304,5316 **** + * Returns 0 for failure, number of lines contained in the match otherwise. + */ + static long +! nfa_regexec_both(line, col) + char_u *line; +! colnr_T col; /* column to start looking for match */ + { + nfa_regprog_T *prog; + long retval = 0L; + int i; + + if (REG_MULTI) + { +--- 5463,5476 ---- + * Returns 0 for failure, number of lines contained in the match otherwise. + */ + static long +! nfa_regexec_both(line, startcol) + char_u *line; +! colnr_T startcol; /* column to start looking for match */ + { + nfa_regprog_T *prog; + long retval = 0L; + int i; ++ colnr_T col = startcol; + + if (REG_MULTI) + { +*************** +*** 5333,5342 **** + goto theend; + } + +- /* If the start column is past the maximum column: no need to try. */ +- if (ireg_maxcol > 0 && col >= ireg_maxcol) +- goto theend; +- + /* If pattern contains "\c" or "\C": overrule value of ireg_ic */ + if (prog->regflags & RF_ICASE) + ireg_ic = TRUE; +--- 5493,5498 ---- +*************** +*** 5361,5366 **** +--- 5517,5548 ---- + nfa_regengine.expr = prog->pattern; + #endif + ++ if (prog->reganch && col > 0) ++ return 0L; ++ ++ if (prog->regstart != NUL) ++ { ++ char_u *s; ++ ++ /* Skip until the char we know it must start with. ++ * Used often, do some work to avoid call overhead. */ ++ if (!ireg_ic ++ #ifdef FEAT_MBYTE ++ && !has_mbyte ++ #endif ++ ) ++ s = vim_strbyte(regline + col, prog->regstart); ++ else ++ s = cstrchr(regline + col, prog->regstart); ++ if (s == NULL) ++ return 0L; ++ col = (int)(s - regline); ++ } ++ ++ /* If the start column is past the maximum column: no need to try. */ ++ if (ireg_maxcol > 0 && col >= ireg_maxcol) ++ goto theend; ++ + nstate = prog->nstate; + for (i = 0; i < nstate; ++i) + { +*************** +*** 5459,5464 **** +--- 5641,5650 ---- + prog->has_zend = nfa_has_zend; + prog->has_backref = nfa_has_backref; + prog->nsubexp = regnpar; ++ ++ prog->reganch = nfa_get_reganch(prog->start, 0); ++ prog->regstart = nfa_get_regstart(prog->start, 0); ++ + #ifdef ENABLE_LOG + nfa_postfix_dump(expr, OK); + nfa_dump(prog); +*** ../vim-7.3.1132/src/regexp.h 2013-06-03 12:17:00.000000000 +0200 +--- src/regexp.h 2013-06-06 17:19:23.000000000 +0200 +*************** +*** 87,92 **** +--- 87,96 ---- + unsigned regflags; + + nfa_state_T *start; /* points into state[] */ ++ ++ int reganch; /* pattern starts with ^ */ ++ int regstart; /* char at start of pattern */ ++ + int has_zend; /* pattern contains \ze */ + int has_backref; /* pattern contains \1 .. \9 */ + #ifdef FEAT_SYN_HL +*** ../vim-7.3.1132/src/version.c 2013-06-06 18:04:47.000000000 +0200 +--- src/version.c 2013-06-06 18:43:55.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1133, + /**/ + +-- +From "know your smileys": + % Bike accident. A bit far-fetched, I suppose; although... + o _ _ _ + _o /\_ _ \\o (_)\__/o (_) + _< \_ _>(_) (_)/<_ \_| \ _|/' \/ + (_)>(_) (_) (_) (_) (_)' _\o_ + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fb7209c837d53bad3d0ca547f20334d5ed0fd4db Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:19 +0200 Subject: [PATCH 1026/3340] - patchlevel 1134 --- 7.3.1134 | 67 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 7.3.1134 diff --git a/7.3.1134 b/7.3.1134 new file mode 100644 index 00000000..65b7d00e --- /dev/null +++ b/7.3.1134 @@ -0,0 +1,67 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1134 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1134 +Problem: Running test 49 takes a long time. +Solution: Don't have it grep all files. +Files: src/testdir/test49.vim + + +*** ../vim-7.3.1133/src/testdir/test49.vim 2013-02-26 22:54:06.000000000 +0100 +--- src/testdir/test49.vim 2013-06-06 18:13:46.000000000 +0200 +*************** +*** 1,6 **** + " Vim script language tests + " Author: Servatius Brandt +! " Last Change: 2012 Nov 23 + + "------------------------------------------------------------------------------- + " Test environment {{{1 +--- 1,6 ---- + " Vim script language tests + " Author: Servatius Brandt +! " Last Change: 2013 Jun 06 + + "------------------------------------------------------------------------------- + " Test environment {{{1 +*************** +*** 9612,9618 **** + func F + au BufUnload * :call setloclist(0, [{'bufnr':1, 'lnum':1, 'col':1, 'text': 'tango down'}]) + +! :lvimgrep /.*/ * + endfunc + + XpathINIT +--- 9612,9618 ---- + func F + au BufUnload * :call setloclist(0, [{'bufnr':1, 'lnum':1, 'col':1, 'text': 'tango down'}]) + +! :lvimgrep /.*/ *.mak + endfunc + + XpathINIT +*** ../vim-7.3.1133/src/version.c 2013-06-06 18:46:00.000000000 +0200 +--- src/version.c 2013-06-06 18:55:21.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1134, + /**/ + +-- +I AM THANKFUL... +...for the taxes that I pay because it means that I am employed. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 065ce4c2972e59e06a0c4d4c2ab3093a945f5ef7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:20 +0200 Subject: [PATCH 1027/3340] - patchlevel 1135 --- 7.3.1135 | 71 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) create mode 100644 7.3.1135 diff --git a/7.3.1135 b/7.3.1135 new file mode 100644 index 00000000..a2086486 --- /dev/null +++ b/7.3.1135 @@ -0,0 +1,71 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1135 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1135 +Problem: Compiler warning for unused argument. +Solution: Add UNUSED. +Files: src/syntax.c + + +*** ../vim-7.3.1134/src/syntax.c 2013-06-06 14:55:16.000000000 +0200 +--- src/syntax.c 2013-06-06 21:18:20.000000000 +0200 +*************** +*** 3258,3264 **** + regmmatch_T *rmp; + linenr_T lnum; + colnr_T col; +! syn_time_T *st; + { + int r; + #ifdef FEAT_PROFILE +--- 3258,3264 ---- + regmmatch_T *rmp; + linenr_T lnum; + colnr_T col; +! syn_time_T *st UNUSED; + { + int r; + #ifdef FEAT_PROFILE +*************** +*** 6649,6655 **** + } + + /* sort on total time */ +! qsort(ga.ga_data, (size_t)ga.ga_len, sizeof(time_entry_T), syn_compare_syntime); + + MSG_PUTS_TITLE(_(" TOTAL COUNT MATCH SLOWEST AVERAGE NAME PATTERN")); + MSG_PUTS("\n"); +--- 6649,6656 ---- + } + + /* sort on total time */ +! qsort(ga.ga_data, (size_t)ga.ga_len, sizeof(time_entry_T), +! syn_compare_syntime); + + MSG_PUTS_TITLE(_(" TOTAL COUNT MATCH SLOWEST AVERAGE NAME PATTERN")); + MSG_PUTS("\n"); +*** ../vim-7.3.1134/src/version.c 2013-06-06 18:55:45.000000000 +0200 +--- src/version.c 2013-06-06 21:19:01.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1135, + /**/ + +-- +I AM THANKFUL... +...for all the complaining I hear about the government +because it means we have freedom of speech. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3ecefc16a1c86fd60bf15d23b70474ae98958e97 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:21 +0200 Subject: [PATCH 1028/3340] - patchlevel 1136 --- 7.3.1136 | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 7.3.1136 diff --git a/7.3.1136 b/7.3.1136 new file mode 100644 index 00000000..5d06cb16 --- /dev/null +++ b/7.3.1136 @@ -0,0 +1,50 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1136 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1136 +Problem: ":func Foo" does not show attributes. +Solution: Add "abort", "dict" and "range". (Yasuhiro Matsumoto) +Files: src/eval.c + + +*** ../vim-7.3.1135/src/eval.c 2013-05-30 13:37:23.000000000 +0200 +--- src/eval.c 2013-06-06 21:29:06.000000000 +0200 +*************** +*** 21891,21896 **** +--- 21891,21902 ---- + MSG_PUTS("..."); + } + msg_putchar(')'); ++ if (fp->uf_flags & FC_ABORT) ++ MSG_PUTS(" abort"); ++ if (fp->uf_flags & FC_RANGE) ++ MSG_PUTS(" range"); ++ if (fp->uf_flags & FC_DICT) ++ MSG_PUTS(" dict"); + msg_clr_eos(); + if (p_verbose > 0) + last_set_msg(fp->uf_script_ID); +*** ../vim-7.3.1135/src/version.c 2013-06-06 21:19:40.000000000 +0200 +--- src/version.c 2013-06-06 21:30:05.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1136, + /**/ + +-- +From "know your smileys": + :-E Has major dental problems + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5e4d4a98031aeb9fc08597d3f2a60818ee5feccf Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:22 +0200 Subject: [PATCH 1029/3340] - patchlevel 1137 --- 7.3.1137 | 966 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 966 insertions(+) create mode 100644 7.3.1137 diff --git a/7.3.1137 b/7.3.1137 new file mode 100644 index 00000000..fb26417a --- /dev/null +++ b/7.3.1137 @@ -0,0 +1,966 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1137 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1137 +Problem: New regexp engine: collections are slow. +Solution: Handle all characters in one go. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1136/src/regexp_nfa.c 2013-06-06 18:46:00.000000000 +0200 +--- src/regexp_nfa.c 2013-06-07 13:40:58.000000000 +0200 +*************** +*** 34,48 **** + NFA_SPLIT = -1024, + NFA_MATCH, + NFA_SKIP_CHAR, /* matches a 0-length char */ +- NFA_END_NEG_RANGE, /* Used when expanding [^ab] */ + +! NFA_CONCAT, + NFA_OR, + NFA_STAR, /* greedy * */ + NFA_STAR_NONGREEDY, /* non-greedy * */ + NFA_QUEST, /* greedy \? */ + NFA_QUEST_NONGREEDY, /* non-greedy \? */ +- NFA_NOT, /* used for [^ab] negated char ranges */ + + NFA_BOL, /* ^ Begin line */ + NFA_EOL, /* $ End line */ +--- 34,56 ---- + NFA_SPLIT = -1024, + NFA_MATCH, + NFA_SKIP_CHAR, /* matches a 0-length char */ + +! NFA_START_COLL, /* [abc] start */ +! NFA_END_COLL, /* [abc] end */ +! NFA_START_NEG_COLL, /* [^abc] start */ +! NFA_END_NEG_COLL, /* [^abc] end (only used in postfix) */ +! NFA_RANGE, /* range of the two previous items (only +! * used in postfix) */ +! NFA_RANGE_MIN, /* low end of a range */ +! NFA_RANGE_MAX, /* high end of a range */ +! +! NFA_CONCAT, /* concatenate two previous items (only +! * used in postfix) */ + NFA_OR, + NFA_STAR, /* greedy * */ + NFA_STAR_NONGREEDY, /* non-greedy * */ + NFA_QUEST, /* greedy \? */ + NFA_QUEST_NONGREEDY, /* non-greedy \? */ + + NFA_BOL, /* ^ Begin line */ + NFA_EOL, /* $ End line */ +*************** +*** 260,266 **** + static int nfa_get_reganch __ARGS((nfa_state_T *start, int depth)); + static int nfa_get_regstart __ARGS((nfa_state_T *start, int depth)); + static int nfa_recognize_char_class __ARGS((char_u *start, char_u *end, int extra_newl)); +! static int nfa_emit_equi_class __ARGS((int c, int neg)); + static int nfa_regatom __ARGS((void)); + static int nfa_regpiece __ARGS((void)); + static int nfa_regconcat __ARGS((void)); +--- 268,274 ---- + static int nfa_get_reganch __ARGS((nfa_state_T *start, int depth)); + static int nfa_get_regstart __ARGS((nfa_state_T *start, int depth)); + static int nfa_recognize_char_class __ARGS((char_u *start, char_u *end, int extra_newl)); +! static int nfa_emit_equi_class __ARGS((int c)); + static int nfa_regatom __ARGS((void)); + static int nfa_regpiece __ARGS((void)); + static int nfa_regconcat __ARGS((void)); +*************** +*** 664,684 **** + * NOTE! When changing this function, also update reg_equi_class() + */ + static int +! nfa_emit_equi_class(c, neg) + int c; +- int neg; + { +! int first = TRUE; +! int glue = neg == TRUE ? NFA_CONCAT : NFA_OR; +! #define EMIT2(c) \ +! EMIT(c); \ +! if (neg == TRUE) { \ +! EMIT(NFA_NOT); \ +! } \ +! if (first == FALSE) \ +! EMIT(glue); \ +! else \ +! first = FALSE; \ + + #ifdef FEAT_MBYTE + if (enc_utf8 || STRCMP(p_enc, "latin1") == 0 +--- 672,681 ---- + * NOTE! When changing this function, also update reg_equi_class() + */ + static int +! nfa_emit_equi_class(c) + int c; + { +! #define EMIT2(c) EMIT(c); EMIT(NFA_CONCAT); + + #ifdef FEAT_MBYTE + if (enc_utf8 || STRCMP(p_enc, "latin1") == 0 +*************** +*** 687,770 **** + { + switch (c) + { +! case 'A': case '\300': case '\301': case '\302': +! case '\303': case '\304': case '\305': +! EMIT2('A'); EMIT2('\300'); EMIT2('\301'); +! EMIT2('\302'); EMIT2('\303'); EMIT2('\304'); +! EMIT2('\305'); + return OK; + +! case 'C': case '\307': +! EMIT2('C'); EMIT2('\307'); + return OK; + +! case 'E': case '\310': case '\311': case '\312': case '\313': +! EMIT2('E'); EMIT2('\310'); EMIT2('\311'); +! EMIT2('\312'); EMIT2('\313'); + return OK; + +! case 'I': case '\314': case '\315': case '\316': case '\317': +! EMIT2('I'); EMIT2('\314'); EMIT2('\315'); +! EMIT2('\316'); EMIT2('\317'); + return OK; + +! case 'N': case '\321': +! EMIT2('N'); EMIT2('\321'); + return OK; + +! case 'O': case '\322': case '\323': case '\324': case '\325': +! case '\326': +! EMIT2('O'); EMIT2('\322'); EMIT2('\323'); +! EMIT2('\324'); EMIT2('\325'); EMIT2('\326'); + return OK; + +! case 'U': case '\331': case '\332': case '\333': case '\334': +! EMIT2('U'); EMIT2('\331'); EMIT2('\332'); +! EMIT2('\333'); EMIT2('\334'); + return OK; + +! case 'Y': case '\335': +! EMIT2('Y'); EMIT2('\335'); + return OK; + +! case 'a': case '\340': case '\341': case '\342': +! case '\343': case '\344': case '\345': +! EMIT2('a'); EMIT2('\340'); EMIT2('\341'); +! EMIT2('\342'); EMIT2('\343'); EMIT2('\344'); +! EMIT2('\345'); + return OK; + +! case 'c': case '\347': +! EMIT2('c'); EMIT2('\347'); + return OK; + +! case 'e': case '\350': case '\351': case '\352': case '\353': +! EMIT2('e'); EMIT2('\350'); EMIT2('\351'); +! EMIT2('\352'); EMIT2('\353'); + return OK; + +! case 'i': case '\354': case '\355': case '\356': case '\357': +! EMIT2('i'); EMIT2('\354'); EMIT2('\355'); +! EMIT2('\356'); EMIT2('\357'); + return OK; + +! case 'n': case '\361': +! EMIT2('n'); EMIT2('\361'); + return OK; + +! case 'o': case '\362': case '\363': case '\364': case '\365': +! case '\366': +! EMIT2('o'); EMIT2('\362'); EMIT2('\363'); +! EMIT2('\364'); EMIT2('\365'); EMIT2('\366'); + return OK; + +! case 'u': case '\371': case '\372': case '\373': case '\374': +! EMIT2('u'); EMIT2('\371'); EMIT2('\372'); +! EMIT2('\373'); EMIT2('\374'); + return OK; + +! case 'y': case '\375': case '\377': +! EMIT2('y'); EMIT2('\375'); EMIT2('\377'); + return OK; + + default: +--- 684,767 ---- + { + switch (c) + { +! case 'A': case 0300: case 0301: case 0302: +! case 0303: case 0304: case 0305: +! EMIT2('A'); EMIT2(0300); EMIT2(0301); +! EMIT2(0302); EMIT2(0303); EMIT2(0304); +! EMIT2(0305); + return OK; + +! case 'C': case 0307: +! EMIT2('C'); EMIT2(0307); + return OK; + +! case 'E': case 0310: case 0311: case 0312: case 0313: +! EMIT2('E'); EMIT2(0310); EMIT2(0311); +! EMIT2(0312); EMIT2(0313); + return OK; + +! case 'I': case 0314: case 0315: case 0316: case 0317: +! EMIT2('I'); EMIT2(0314); EMIT2(0315); +! EMIT2(0316); EMIT2(0317); + return OK; + +! case 'N': case 0321: +! EMIT2('N'); EMIT2(0321); + return OK; + +! case 'O': case 0322: case 0323: case 0324: case 0325: +! case 0326: +! EMIT2('O'); EMIT2(0322); EMIT2(0323); +! EMIT2(0324); EMIT2(0325); EMIT2(0326); + return OK; + +! case 'U': case 0331: case 0332: case 0333: case 0334: +! EMIT2('U'); EMIT2(0331); EMIT2(0332); +! EMIT2(0333); EMIT2(0334); + return OK; + +! case 'Y': case 0335: +! EMIT2('Y'); EMIT2(0335); + return OK; + +! case 'a': case 0340: case 0341: case 0342: +! case 0343: case 0344: case 0345: +! EMIT2('a'); EMIT2(0340); EMIT2(0341); +! EMIT2(0342); EMIT2(0343); EMIT2(0344); +! EMIT2(0345); + return OK; + +! case 'c': case 0347: +! EMIT2('c'); EMIT2(0347); + return OK; + +! case 'e': case 0350: case 0351: case 0352: case 0353: +! EMIT2('e'); EMIT2(0350); EMIT2(0351); +! EMIT2(0352); EMIT2(0353); + return OK; + +! case 'i': case 0354: case 0355: case 0356: case 0357: +! EMIT2('i'); EMIT2(0354); EMIT2(0355); +! EMIT2(0356); EMIT2(0357); + return OK; + +! case 'n': case 0361: +! EMIT2('n'); EMIT2(0361); + return OK; + +! case 'o': case 0362: case 0363: case 0364: case 0365: +! case 0366: +! EMIT2('o'); EMIT2(0362); EMIT2(0363); +! EMIT2(0364); EMIT2(0365); EMIT2(0366); + return OK; + +! case 'u': case 0371: case 0372: case 0373: case 0374: +! EMIT2('u'); EMIT2(0371); EMIT2(0372); +! EMIT2(0373); EMIT2(0374); + return OK; + +! case 'y': case 0375: case 0377: +! EMIT2('y'); EMIT2(0375); EMIT2(0377); + return OK; + + default: +*************** +*** 811,824 **** + char_u *old_regparse = regparse; + #endif + int extra = 0; +- int first; + int emit_range; + int negated; + int result; + int startc = -1; + int endc = -1; + int oldstartc = -1; +- int glue; /* ID that will "glue" nodes together */ + + c = getchr(); + switch (c) +--- 808,819 ---- +*************** +*** 927,934 **** + + case Magic('n'): + if (reg_string) +! /* In a string "\n" matches a newline character. */ +! EMIT(NL); + else + { + /* In buffer text "\n" matches the end of a line. */ +--- 922,929 ---- + + case Magic('n'): + if (reg_string) +! /* In a string "\n" matches a newline character. */ +! EMIT(NL); + else + { + /* In buffer text "\n" matches the end of a line. */ +*************** +*** 1160,1191 **** + case Magic('['): + collection: + /* +! * Glue is emitted between several atoms from the []. +! * It is either NFA_OR, or NFA_CONCAT. +! * +! * [abc] expands to 'a b NFA_OR c NFA_OR' (in postfix notation) +! * [^abc] expands to 'a NFA_NOT b NFA_NOT NFA_CONCAT c NFA_NOT +! * NFA_CONCAT NFA_END_NEG_RANGE NFA_CONCAT' (in postfix +! * notation) +! * + */ + +- +- /* Emit negation atoms, if needed. +- * The CONCAT below merges the NOT with the previous node. */ +- #define TRY_NEG() \ +- if (negated == TRUE) \ +- { \ +- EMIT(NFA_NOT); \ +- } +- +- /* Emit glue between important nodes : CONCAT or OR. */ +- #define EMIT_GLUE() \ +- if (first == FALSE) \ +- EMIT(glue); \ +- else \ +- first = FALSE; +- + p = regparse; + endp = skip_anyof(p); + if (*endp == ']') +--- 1155,1169 ---- + case Magic('['): + collection: + /* +! * [abc] uses NFA_START_COLL - NFA_END_COLL +! * [^abc] uses NFA_START_NEG_COLL - NFA_END_NEG_COLL +! * Each character is produced as a regular state, using +! * NFA_CONCAT to bind them together. +! * Besides normal characters there can be: +! * - character classes NFA_CLASS_* +! * - ranges, two characters followed by NFA_RANGE. + */ + + p = regparse; + endp = skip_anyof(p); + if (*endp == ']') +*************** +*** 1216,1236 **** + * version that turns [abc] into 'a' OR 'b' OR 'c' + */ + startc = endc = oldstartc = -1; +- first = TRUE; /* Emitting first atom in this sequence? */ + negated = FALSE; +- glue = NFA_OR; + if (*regparse == '^') /* negated range */ + { + negated = TRUE; +- glue = NFA_CONCAT; + mb_ptr_adv(regparse); + } + if (*regparse == '-') + { + startc = '-'; + EMIT(startc); +! TRY_NEG(); +! EMIT_GLUE(); + mb_ptr_adv(regparse); + } + /* Emit the OR branches for each character in the [] */ +--- 1194,1213 ---- + * version that turns [abc] into 'a' OR 'b' OR 'c' + */ + startc = endc = oldstartc = -1; + negated = FALSE; + if (*regparse == '^') /* negated range */ + { + negated = TRUE; + mb_ptr_adv(regparse); ++ EMIT(NFA_START_NEG_COLL); + } ++ else ++ EMIT(NFA_START_COLL); + if (*regparse == '-') + { + startc = '-'; + EMIT(startc); +! EMIT(NFA_CONCAT); + mb_ptr_adv(regparse); + } + /* Emit the OR branches for each character in the [] */ +*************** +*** 1306,1325 **** + EMIT(NFA_CLASS_ESCAPE); + break; + } +! TRY_NEG(); +! EMIT_GLUE(); + continue; + } + /* Try equivalence class [=a=] and the like */ + if (equiclass != 0) + { +! result = nfa_emit_equi_class(equiclass, negated); + if (result == FAIL) + { + /* should never happen */ + EMSG_RET_FAIL(_("E868: Error building NFA with equivalence class!")); + } +- EMIT_GLUE(); + continue; + } + /* Try collating class like [. .] */ +--- 1283,1300 ---- + EMIT(NFA_CLASS_ESCAPE); + break; + } +! EMIT(NFA_CONCAT); + continue; + } + /* Try equivalence class [=a=] and the like */ + if (equiclass != 0) + { +! result = nfa_emit_equi_class(equiclass); + if (result == FAIL) + { + /* should never happen */ + EMSG_RET_FAIL(_("E868: Error building NFA with equivalence class!")); + } + continue; + } + /* Try collating class like [. .] */ +*************** +*** 1391,1409 **** + startc = oldstartc; + if (startc > endc) + EMSG_RET_FAIL(_(e_invrange)); + #ifdef FEAT_MBYTE +! if (has_mbyte && ((*mb_char2len)(startc) > 1 + || (*mb_char2len)(endc) > 1)) + { +! if (endc > startc + 256) +! EMSG_RET_FAIL(_(e_invrange)); +! /* Emit the range. "startc" was already emitted, so +! * skip it. */ + for (c = startc + 1; c <= endc; c++) + { + EMIT(c); +! TRY_NEG(); +! EMIT_GLUE(); + } + } + else +--- 1366,1397 ---- + startc = oldstartc; + if (startc > endc) + EMSG_RET_FAIL(_(e_invrange)); ++ ++ if (endc > startc + 2) ++ { ++ /* Emit a range instead of the sequence of ++ * individual characters. */ ++ if (startc == 0) ++ /* \x00 is translated to \x0a, start at \x01. */ ++ EMIT(1); ++ else ++ --post_ptr; /* remove NFA_CONCAT */ ++ EMIT(endc); ++ EMIT(NFA_RANGE); ++ EMIT(NFA_CONCAT); ++ } ++ else + #ifdef FEAT_MBYTE +! if (has_mbyte && ((*mb_char2len)(startc) > 1 + || (*mb_char2len)(endc) > 1)) + { +! /* Emit the characters in the range. +! * "startc" was already emitted, so skip it. +! * */ + for (c = startc + 1; c <= endc; c++) + { + EMIT(c); +! EMIT(NFA_CONCAT); + } + } + else +*************** +*** 1425,1432 **** + #endif + { + EMIT(c); +! TRY_NEG(); +! EMIT_GLUE(); + } + } + emit_range = FALSE; +--- 1413,1419 ---- + #endif + { + EMIT(c); +! EMIT(NFA_CONCAT); + } + } + emit_range = FALSE; +*************** +*** 1434,1456 **** + } + else + { +! /* +! * This char (startc) is not part of a range. Just + * emit it. +- * + * Normally, simply emit startc. But if we get char + * code=0 from a collating char, then replace it with + * 0x0a. +- * + * This is needed to completely mimic the behaviour of +! * the backtracking engine. +! */ +! if (got_coll_char == TRUE && startc == 0) +! EMIT(0x0a); + else +! EMIT(startc); +! TRY_NEG(); +! EMIT_GLUE(); + } + + mb_ptr_adv(regparse); +--- 1421,1449 ---- + } + else + { +! /* This char (startc) is not part of a range. Just + * emit it. + * Normally, simply emit startc. But if we get char + * code=0 from a collating char, then replace it with + * 0x0a. + * This is needed to completely mimic the behaviour of +! * the backtracking engine. */ +! if (startc == NFA_NEWL) +! { +! /* Line break can't be matched as part of the +! * collection, add an OR below. But not for negated +! * range. */ +! if (!negated) +! extra = ADD_NL; +! } + else +! { +! if (got_coll_char == TRUE && startc == 0) +! EMIT(0x0a); +! else +! EMIT(startc); +! EMIT(NFA_CONCAT); +! } + } + + mb_ptr_adv(regparse); +*************** +*** 1460,1479 **** + if (*regparse == '-') /* if last, '-' is just a char */ + { + EMIT('-'); +! TRY_NEG(); +! EMIT_GLUE(); + } + mb_ptr_adv(regparse); + + /* skip the trailing ] */ + regparse = endp; + mb_ptr_adv(regparse); + if (negated == TRUE) +! { +! /* Mark end of negated char range */ +! EMIT(NFA_END_NEG_RANGE); +! EMIT(NFA_CONCAT); +! } + + /* \_[] also matches \n but it's not negated */ + if (extra == ADD_NL) +--- 1453,1471 ---- + if (*regparse == '-') /* if last, '-' is just a char */ + { + EMIT('-'); +! EMIT(NFA_CONCAT); + } + mb_ptr_adv(regparse); + + /* skip the trailing ] */ + regparse = endp; + mb_ptr_adv(regparse); ++ ++ /* Mark end of the collection. */ + if (negated == TRUE) +! EMIT(NFA_END_NEG_COLL); +! else +! EMIT(NFA_END_COLL); + + /* \_[] also matches \n but it's not negated */ + if (extra == ADD_NL) +*************** +*** 1532,1540 **** + } + } + +- #undef TRY_NEG +- #undef EMIT_GLUE +- + return OK; + } + +--- 1524,1529 ---- +*************** +*** 2091,2100 **** + case NFA_STAR_NONGREEDY: STRCPY(code, "NFA_STAR_NONGREEDY "); break; + case NFA_QUEST: STRCPY(code, "NFA_QUEST"); break; + case NFA_QUEST_NONGREEDY: STRCPY(code, "NFA_QUEST_NON_GREEDY"); break; +- case NFA_NOT: STRCPY(code, "NFA_NOT "); break; + case NFA_SKIP_CHAR: STRCPY(code, "NFA_SKIP_CHAR"); break; + case NFA_OR: STRCPY(code, "NFA_OR"); break; +! case NFA_END_NEG_RANGE: STRCPY(code, "NFA_END_NEG_RANGE"); break; + case NFA_CLASS_ALNUM: STRCPY(code, "NFA_CLASS_ALNUM"); break; + case NFA_CLASS_ALPHA: STRCPY(code, "NFA_CLASS_ALPHA"); break; + case NFA_CLASS_BLANK: STRCPY(code, "NFA_CLASS_BLANK"); break; +--- 2080,2096 ---- + case NFA_STAR_NONGREEDY: STRCPY(code, "NFA_STAR_NONGREEDY "); break; + case NFA_QUEST: STRCPY(code, "NFA_QUEST"); break; + case NFA_QUEST_NONGREEDY: STRCPY(code, "NFA_QUEST_NON_GREEDY"); break; + case NFA_SKIP_CHAR: STRCPY(code, "NFA_SKIP_CHAR"); break; + case NFA_OR: STRCPY(code, "NFA_OR"); break; +! +! case NFA_START_COLL: STRCPY(code, "NFA_START_COLL"); break; +! case NFA_END_COLL: STRCPY(code, "NFA_END_COLL"); break; +! case NFA_START_NEG_COLL: STRCPY(code, "NFA_START_NEG_COLL"); break; +! case NFA_END_NEG_COLL: STRCPY(code, "NFA_END_NEG_COLL"); break; +! case NFA_RANGE: STRCPY(code, "NFA_RANGE"); break; +! case NFA_RANGE_MIN: STRCPY(code, "NFA_RANGE_MIN"); break; +! case NFA_RANGE_MAX: STRCPY(code, "NFA_RANGE_MAX"); break; +! + case NFA_CLASS_ALNUM: STRCPY(code, "NFA_CLASS_ALNUM"); break; + case NFA_CLASS_ALPHA: STRCPY(code, "NFA_CLASS_ALPHA"); break; + case NFA_CLASS_BLANK: STRCPY(code, "NFA_CLASS_BLANK"); break; +*************** +*** 2231,2238 **** + fprintf(debugf, " %s", p); + + nfa_set_code(state->c); +! fprintf(debugf, "%s%s (%d) (id=%d)\n", +! state->negated ? "NOT " : "", code, state->c, abs(state->id)); + if (state->id < 0) + return; + +--- 2227,2238 ---- + fprintf(debugf, " %s", p); + + nfa_set_code(state->c); +! fprintf(debugf, "%s%s (%d) (id=%d) val=%d\n", +! state->negated ? "NOT " : "", +! code, +! state->c, +! abs(state->id), +! state->val); + if (state->id < 0) + return; + +*************** +*** 2325,2330 **** +--- 2325,2331 ---- + s->c = c; + s->out = out; + s->out1 = out1; ++ s->val = 0; + + s->id = istate; + s->lastlist[0] = 0; +*************** +*** 2565,2577 **** + switch (*p) + { + case NFA_CONCAT: +! /* Catenation. +! * Pay attention: this operator does not exist +! * in the r.e. itself (it is implicit, really). +! * It is added when r.e. is translated to postfix +! * form in re2post(). +! * +! * No new state added here. */ + if (nfa_calc_size == TRUE) + { + /* nstate += 0; */ +--- 2566,2575 ---- + switch (*p) + { + case NFA_CONCAT: +! /* Concatenation. +! * Pay attention: this operator does not exist in the r.e. itself +! * (it is implicit, really). It is added when r.e. is translated +! * to postfix form in re2post(). */ + if (nfa_calc_size == TRUE) + { + /* nstate += 0; */ +*************** +*** 2583,2604 **** + PUSH(frag(e1.start, e2.out)); + break; + +- case NFA_NOT: +- /* Negation of a character */ +- if (nfa_calc_size == TRUE) +- { +- /* nstate += 0; */ +- break; +- } +- e1 = POP(); +- e1.start->negated = TRUE; +- #ifdef FEAT_MBYTE +- if (e1.start->c == NFA_COMPOSING) +- e1.start->out1->negated = TRUE; +- #endif +- PUSH(e1); +- break; +- + case NFA_OR: + /* Alternation */ + if (nfa_calc_size == TRUE) +--- 2581,2586 ---- +*************** +*** 2672,2677 **** +--- 2654,2696 ---- + PUSH(frag(s, append(e.out, list1(&s->out)))); + break; + ++ case NFA_END_COLL: ++ case NFA_END_NEG_COLL: ++ /* On the stack is the sequence starting with NFA_START_COLL or ++ * NFA_START_NEG_COLL and all possible characters. Patch it to ++ * add the output to the start. */ ++ if (nfa_calc_size == TRUE) ++ { ++ nstate++; ++ break; ++ } ++ e = POP(); ++ s = alloc_state(NFA_END_COLL, NULL, NULL); ++ if (s == NULL) ++ goto theend; ++ patch(e.out, s); ++ e.start->out1 = s; ++ PUSH(frag(e.start, list1(&s->out))); ++ break; ++ ++ case NFA_RANGE: ++ /* Before this are two characters, the low and high end of a ++ * range. Turn them into two states with MIN and MAX. */ ++ if (nfa_calc_size == TRUE) ++ { ++ /* nstate += 0; */ ++ break; ++ } ++ e2 = POP(); ++ e1 = POP(); ++ e2.start->val = e2.start->c; ++ e2.start->c = NFA_RANGE_MAX; ++ e1.start->val = e1.start->c; ++ e1.start->c = NFA_RANGE_MIN; ++ patch(e1.out, e2.start); ++ PUSH(frag(e1.start, e2.out)); ++ break; ++ + case NFA_SKIP_CHAR: + /* Symbol of 0-length, Used in a repetition + * with max/min count of 0 */ +*************** +*** 2990,2995 **** +--- 3009,3016 ---- + matchstate = &state_ptr[istate++]; /* the match state */ + matchstate->c = NFA_MATCH; + matchstate->out = matchstate->out1 = NULL; ++ matchstate->negated = FALSE; ++ matchstate->id = 0; + + patch(e.out, matchstate); + ret = e.start; +*************** +*** 3308,3314 **** + switch (state->c) + { + case NFA_SPLIT: +- case NFA_NOT: + case NFA_NOPEN: + case NFA_SKIP_CHAR: + case NFA_NCLOSE: +--- 3329,3334 ---- +*************** +*** 3782,3788 **** + + default: + /* should not be here :P */ +! EMSG_RET_FAIL(_("E877: (NFA regexp) Invalid character class ")); + } + return FAIL; + } +--- 3802,3809 ---- + + default: + /* should not be here :P */ +! EMSGN("E877: (NFA regexp) Invalid character class: %ld", class); +! return FAIL; + } + return FAIL; + } +*************** +*** 4320,4327 **** + addstate(thislist, start, m, 0); + + /* There are two cases when the NFA advances: 1. input char matches the +! * NFA node and 2. input char does not match the NFA node, but the next +! * node is NFA_NOT. The following macro calls addstate() according to + * these rules. It is used A LOT, so use the "listtbl" table for speed */ + listtbl[0][0] = NULL; + listtbl[0][1] = neglist; +--- 4341,4348 ---- + addstate(thislist, start, m, 0); + + /* There are two cases when the NFA advances: 1. input char matches the +! * NFA node and 2. input char does not match the NFA node and the state +! * has the negated flag. The following macro calls addstate() according to + * these rules. It is used A LOT, so use the "listtbl" table for speed */ + listtbl[0][0] = NULL; + listtbl[0][1] = neglist; +*************** +*** 4845,4860 **** + ADD_POS_NEG_STATE(t->state); + break; + +! case NFA_END_NEG_RANGE: +! /* This follows a series of negated nodes, like: +! * NOT CHAR(x), NOT CHAR(y), etc. */ +! if (curc > 0) + { + ll = nextlist; +! add_state = t->state->out; + add_off = clen; + } + break; + + case NFA_ANY: + /* Any char except '\0', (end of input) does not match. */ +--- 4866,4944 ---- + ADD_POS_NEG_STATE(t->state); + break; + +! case NFA_START_COLL: +! case NFA_START_NEG_COLL: +! { +! /* What follows is a list of characters, until NFA_END_COLL. +! * One of them must match or none of them must match. */ +! nfa_state_T *state; +! int result_if_matched; +! int c1, c2; +! +! /* Never match EOL. If it's part of the collection it is added +! * as a separate state with an OR. */ +! if (curc == NUL) +! break; +! +! state = t->state->out; +! result_if_matched = (t->state->c == NFA_START_COLL); +! for (;;) + { ++ if (state->c == NFA_END_COLL) ++ { ++ result = !result_if_matched; ++ break; ++ } ++ if (state->c == NFA_RANGE_MIN) ++ { ++ c1 = state->val; ++ state = state->out; /* advance to NFA_RANGE_MAX */ ++ c2 = state->val; ++ #ifdef ENABLE_LOG ++ fprintf(log_fd, "NFA_RANGE_MIN curc=%d c1=%d c2=%d\n", ++ curc, c1, c2); ++ #endif ++ if (curc >= c1 && curc <= c2) ++ { ++ result = result_if_matched; ++ break; ++ } ++ if (ireg_ic) ++ { ++ int curc_low = MB_TOLOWER(curc); ++ int done = FALSE; ++ ++ for ( ; c1 <= c2; ++c1) ++ if (MB_TOLOWER(c1) == curc_low) ++ { ++ result = result_if_matched; ++ done = TRUE; ++ break; ++ } ++ if (done) ++ break; ++ } ++ } ++ else if (state->c < 0 ? check_char_class(state->c, curc) ++ : (curc == state->c ++ || (ireg_ic && MB_TOLOWER(curc) ++ == MB_TOLOWER(state->c)))) ++ { ++ result = result_if_matched; ++ break; ++ } ++ state = state->out; ++ } ++ if (result) ++ { ++ /* next state is in out of the NFA_END_COLL, out1 of ++ * START points to the END state */ + ll = nextlist; +! add_state = t->state->out1->out; + add_off = clen; + } + break; ++ } + + case NFA_ANY: + /* Any char except '\0', (end of input) does not match. */ +*** ../vim-7.3.1136/src/version.c 2013-06-06 21:31:02.000000000 +0200 +--- src/version.c 2013-06-07 13:21:57.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1137, + /**/ + +-- +From "know your smileys": + :.-( Crying + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d27979da0d78de544b0606085ab25a52a55bebac Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:23 +0200 Subject: [PATCH 1030/3340] - patchlevel 1138 --- 7.3.1138 | 651 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 651 insertions(+) create mode 100644 7.3.1138 diff --git a/7.3.1138 b/7.3.1138 new file mode 100644 index 00000000..25d2d0d4 --- /dev/null +++ b/7.3.1138 @@ -0,0 +1,651 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1138 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1138 +Problem: New regexp engine: neglist no longer used. +Solution: Remove the now unused neglist. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1137/src/regexp_nfa.c 2013-06-07 14:08:24.000000000 +0200 +--- src/regexp_nfa.c 2013-06-07 14:43:12.000000000 +0200 +*************** +*** 4276,4288 **** + int flag = 0; + int go_to_nextline = FALSE; + nfa_thread_T *t; +! nfa_list_T list[3]; +! nfa_list_T *listtbl[2][2]; +! nfa_list_T *ll; + int listidx; + nfa_list_T *thislist; + nfa_list_T *nextlist; +- nfa_list_T *neglist; + int *listids = NULL; + nfa_state_T *add_state; + int add_count; +--- 4276,4285 ---- + int flag = 0; + int go_to_nextline = FALSE; + nfa_thread_T *t; +! nfa_list_T list[2]; + int listidx; + nfa_list_T *thislist; + nfa_list_T *nextlist; + int *listids = NULL; + nfa_state_T *add_state; + int add_count; +*************** +*** 4306,4314 **** + list[0].len = nstate + 1; + list[1].t = (nfa_thread_T *)lalloc(size, TRUE); + list[1].len = nstate + 1; +! list[2].t = (nfa_thread_T *)lalloc(size, TRUE); +! list[2].len = nstate + 1; +! if (list[0].t == NULL || list[1].t == NULL || list[2].t == NULL) + goto theend; + + #ifdef ENABLE_LOG +--- 4303,4309 ---- + list[0].len = nstate + 1; + list[1].t = (nfa_thread_T *)lalloc(size, TRUE); + list[1].len = nstate + 1; +! if (list[0].t == NULL || list[1].t == NULL) + goto theend; + + #ifdef ENABLE_LOG +*************** +*** 4332,4356 **** + thislist->n = 0; + nextlist = &list[1]; + nextlist->n = 0; +- neglist = &list[2]; +- neglist->n = 0; + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif + thislist->id = nfa_listid + 1; + addstate(thislist, start, m, 0); + +! /* There are two cases when the NFA advances: 1. input char matches the +! * NFA node and 2. input char does not match the NFA node and the state +! * has the negated flag. The following macro calls addstate() according to +! * these rules. It is used A LOT, so use the "listtbl" table for speed */ +! listtbl[0][0] = NULL; +! listtbl[0][1] = neglist; +! listtbl[1][0] = nextlist; +! listtbl[1][1] = NULL; +! #define ADD_POS_NEG_STATE(state) \ +! ll = listtbl[result ? 1 : 0][state->negated]; \ +! if (ll != NULL) { \ + add_state = state->out; \ + add_off = clen; \ + } +--- 4327,4340 ---- + thislist->n = 0; + nextlist = &list[1]; + nextlist->n = 0; + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif + thislist->id = nfa_listid + 1; + addstate(thislist, start, m, 0); + +! #define ADD_STATE_IF_MATCH(state) \ +! if (result) { \ + add_state = state->out; \ + add_off = clen; \ + } +*************** +*** 4385,4395 **** + thislist = &list[flag]; + nextlist = &list[flag ^= 1]; + nextlist->n = 0; /* clear nextlist */ +- listtbl[1][0] = nextlist; + ++nfa_listid; + thislist->id = nfa_listid; + nextlist->id = nfa_listid + 1; +- neglist->id = nfa_listid + 1; + + pimlist.ga_len = 0; + +--- 4369,4377 ---- +*************** +*** 4413,4436 **** + /* + * If the state lists are empty we can stop. + */ +! if (thislist->n == 0 && neglist->n == 0) + break; + + /* compute nextlist */ +! for (listidx = 0; listidx < thislist->n || neglist->n > 0; ++listidx) + { +! if (neglist->n > 0) +! { +! t = &neglist->t[0]; +! neglist->n--; +! listidx--; +! #ifdef ENABLE_LOG +! fprintf(log_fd, " using neglist entry, %d remaining\n", +! neglist->n); +! #endif +! } +! else +! t = &thislist->t[listidx]; + + #ifdef NFA_REGEXP_DEBUG_LOG + nfa_set_code(t->state->c); +--- 4395,4407 ---- + /* + * If the state lists are empty we can stop. + */ +! if (thislist->n == 0) + break; + + /* compute nextlist */ +! for (listidx = 0; listidx < thislist->n; ++listidx) + { +! t = &thislist->t[listidx]; + + #ifdef NFA_REGEXP_DEBUG_LOG + nfa_set_code(t->state->c); +*************** +*** 4475,4481 **** + * states at this position. When the list of states is going + * to be empty quit without advancing, so that "reginput" is + * correct. */ +! if (nextlist->n == 0 && neglist->n == 0) + clen = 0; + goto nextchar; + } +--- 4446,4452 ---- + * states at this position. When the list of states is going + * to be empty quit without advancing, so that "reginput" is + * correct. */ +! if (nextlist->n == 0) + clen = 0; + goto nextchar; + } +*************** +*** 4648,4654 **** + { + /* match current character, output of corresponding + * NFA_END_PATTERN to be used at next position. */ +- ll = nextlist; + add_state = t->state->out1->out->out; + add_off = clen; + } +--- 4619,4624 ---- +*************** +*** 4656,4662 **** + { + /* skip over the matched characters, set character + * count in NFA_SKIP */ +- ll = nextlist; + add_state = t->state->out1->out; + add_off = bytelen; + add_count = bytelen - clen; +--- 4626,4631 ---- +*************** +*** 4821,4827 **** + result = FAIL; + + end = t->state->out1; /* NFA_END_COMPOSING */ +! ADD_POS_NEG_STATE(end); + break; + } + #endif +--- 4790,4796 ---- + result = FAIL; + + end = t->state->out1; /* NFA_END_COMPOSING */ +! ADD_STATE_IF_MATCH(end); + break; + } + #endif +*************** +*** 4833,4846 **** + go_to_nextline = TRUE; + /* Pass -1 for the offset, which means taking the position + * at the start of the next line. */ +- ll = nextlist; + add_state = t->state->out; + add_off = -1; + } + else if (curc == '\n' && reg_line_lbr) + { + /* match \n as if it is an ordinary character */ +- ll = nextlist; + add_state = t->state->out; + add_off = 1; + } +--- 4802,4813 ---- +*************** +*** 4863,4869 **** + case NFA_CLASS_BACKSPACE: + case NFA_CLASS_ESCAPE: + result = check_char_class(t->state->c, curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_START_COLL: +--- 4830,4836 ---- + case NFA_CLASS_BACKSPACE: + case NFA_CLASS_ESCAPE: + result = check_char_class(t->state->c, curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_START_COLL: +*************** +*** 4933,4939 **** + { + /* next state is in out of the NFA_END_COLL, out1 of + * START points to the END state */ +- ll = nextlist; + add_state = t->state->out1->out; + add_off = clen; + } +--- 4900,4905 ---- +*************** +*** 4944,4950 **** + /* Any char except '\0', (end of input) does not match. */ + if (curc > 0) + { +- ll = nextlist; + add_state = t->state->out; + add_off = clen; + } +--- 4910,4915 ---- +*************** +*** 4955,5087 **** + */ + case NFA_IDENT: /* \i */ + result = vim_isIDc(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_SIDENT: /* \I */ + result = !VIM_ISDIGIT(curc) && vim_isIDc(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_KWORD: /* \k */ + result = vim_iswordp_buf(reginput, reg_buf); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_SKWORD: /* \K */ + result = !VIM_ISDIGIT(curc) + && vim_iswordp_buf(reginput, reg_buf); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_FNAME: /* \f */ + result = vim_isfilec(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_SFNAME: /* \F */ + result = !VIM_ISDIGIT(curc) && vim_isfilec(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_PRINT: /* \p */ + result = ptr2cells(reginput) == 1; +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_SPRINT: /* \P */ + result = !VIM_ISDIGIT(curc) && ptr2cells(reginput) == 1; +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_WHITE: /* \s */ + result = vim_iswhite(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NWHITE: /* \S */ + result = curc != NUL && !vim_iswhite(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_DIGIT: /* \d */ + result = ri_digit(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NDIGIT: /* \D */ + result = curc != NUL && !ri_digit(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_HEX: /* \x */ + result = ri_hex(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NHEX: /* \X */ + result = curc != NUL && !ri_hex(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_OCTAL: /* \o */ + result = ri_octal(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NOCTAL: /* \O */ + result = curc != NUL && !ri_octal(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_WORD: /* \w */ + result = ri_word(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NWORD: /* \W */ + result = curc != NUL && !ri_word(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_HEAD: /* \h */ + result = ri_head(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NHEAD: /* \H */ + result = curc != NUL && !ri_head(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_ALPHA: /* \a */ + result = ri_alpha(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NALPHA: /* \A */ + result = curc != NUL && !ri_alpha(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_LOWER: /* \l */ + result = ri_lower(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NLOWER: /* \L */ + result = curc != NUL && !ri_lower(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_UPPER: /* \u */ + result = ri_upper(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_NUPPER: /* \U */ + result = curc != NUL && !ri_upper(curc); +! ADD_POS_NEG_STATE(t->state); + break; + + case NFA_BACKREF1: +--- 4920,5052 ---- + */ + case NFA_IDENT: /* \i */ + result = vim_isIDc(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_SIDENT: /* \I */ + result = !VIM_ISDIGIT(curc) && vim_isIDc(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_KWORD: /* \k */ + result = vim_iswordp_buf(reginput, reg_buf); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_SKWORD: /* \K */ + result = !VIM_ISDIGIT(curc) + && vim_iswordp_buf(reginput, reg_buf); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_FNAME: /* \f */ + result = vim_isfilec(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_SFNAME: /* \F */ + result = !VIM_ISDIGIT(curc) && vim_isfilec(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_PRINT: /* \p */ + result = ptr2cells(reginput) == 1; +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_SPRINT: /* \P */ + result = !VIM_ISDIGIT(curc) && ptr2cells(reginput) == 1; +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_WHITE: /* \s */ + result = vim_iswhite(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_NWHITE: /* \S */ + result = curc != NUL && !vim_iswhite(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_DIGIT: /* \d */ + result = ri_digit(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_NDIGIT: /* \D */ + result = curc != NUL && !ri_digit(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_HEX: /* \x */ + result = ri_hex(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_NHEX: /* \X */ + result = curc != NUL && !ri_hex(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_OCTAL: /* \o */ + result = ri_octal(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_NOCTAL: /* \O */ + result = curc != NUL && !ri_octal(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_WORD: /* \w */ + result = ri_word(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_NWORD: /* \W */ + result = curc != NUL && !ri_word(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_HEAD: /* \h */ + result = ri_head(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_NHEAD: /* \H */ + result = curc != NUL && !ri_head(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_ALPHA: /* \a */ + result = ri_alpha(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_NALPHA: /* \A */ + result = curc != NUL && !ri_alpha(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_LOWER: /* \l */ + result = ri_lower(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_NLOWER: /* \L */ + result = curc != NUL && !ri_lower(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_UPPER: /* \u */ + result = ri_upper(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_NUPPER: /* \U */ + result = curc != NUL && !ri_upper(curc); +! ADD_STATE_IF_MATCH(t->state); + break; + + case NFA_BACKREF1: +*************** +*** 5135,5141 **** + { + /* match current character, jump ahead to out of + * NFA_SKIP */ +- ll = nextlist; + add_state = t->state->out->out; + add_off = clen; + } +--- 5100,5105 ---- +*************** +*** 5143,5149 **** + { + /* skip over the matched characters, set character + * count in NFA_SKIP */ +- ll = nextlist; + add_state = t->state->out; + add_off = bytelen; + add_count = bytelen - clen; +--- 5107,5112 ---- +*************** +*** 5156,5169 **** + if (t->count - clen <= 0) + { + /* end of match, go to what follows */ +- ll = nextlist; + add_state = t->state->out; + add_off = clen; + } + else + { + /* add state again with decremented count */ +- ll = nextlist; + add_state = t->state; + add_off = 0; + add_count = t->count - clen; +--- 5119,5130 ---- +*************** +*** 5267,5273 **** + && clen != utf_char2len(curc)) + result = FALSE; + #endif +! ADD_POS_NEG_STATE(t->state); + break; + } + +--- 5228,5234 ---- + && clen != utf_char2len(curc)) + result = FALSE; + #endif +! ADD_STATE_IF_MATCH(t->state); + break; + } + +*************** +*** 5328,5336 **** + continue; + } + +! addstate(ll, add_state, &t->subs, add_off); + if (add_count > 0) +! nextlist->t[ll->n - 1].count = add_count; + } + + } /* for (thislist = thislist; thislist->state; thislist++) */ +--- 5289,5297 ---- + continue; + } + +! addstate(nextlist, add_state, &t->subs, add_off); + if (add_count > 0) +! nextlist->t[nextlist->n - 1].count = add_count; + } + + } /* for (thislist = thislist; thislist->state; thislist++) */ +*************** +*** 5396,5405 **** + /* Free memory */ + vim_free(list[0].t); + vim_free(list[1].t); +- vim_free(list[2].t); + vim_free(listids); + ga_clear(&pimlist); +! #undef ADD_POS_NEG_STATE + #ifdef NFA_REGEXP_DEBUG_LOG + fclose(debug); + #endif +--- 5357,5365 ---- + /* Free memory */ + vim_free(list[0].t); + vim_free(list[1].t); + vim_free(listids); + ga_clear(&pimlist); +! #undef ADD_STATE_IF_MATCH + #ifdef NFA_REGEXP_DEBUG_LOG + fclose(debug); + #endif +*** ../vim-7.3.1137/src/version.c 2013-06-07 14:08:24.000000000 +0200 +--- src/version.c 2013-06-07 14:57:46.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1138, + /**/ + +-- +From "know your smileys": + <|-) Chinese + <|-( Chinese and doesn't like these kind of jokes + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9d1a51af7ff87134f464b6414b7dfb1288a394c2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:24 +0200 Subject: [PATCH 1031/3340] - patchlevel 1139 --- 7.3.1139 | 537 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 537 insertions(+) create mode 100644 7.3.1139 diff --git a/7.3.1139 b/7.3.1139 new file mode 100644 index 00000000..4dbeaa92 --- /dev/null +++ b/7.3.1139 @@ -0,0 +1,537 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1139 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1139 +Problem: New regexp engine: negated flag is hardly used. +Solution: Add separate _NEG states, remove negated flag. +Files: src/regexp_nfa.c, src/regexp.h + + +*** ../vim-7.3.1138/src/regexp_nfa.c 2013-06-07 14:59:14.000000000 +0200 +--- src/regexp_nfa.c 2013-06-07 16:31:29.000000000 +0200 +*************** +*** 64,72 **** +--- 64,75 ---- + NFA_NOPEN, /* Start of subexpression marked with \%( */ + NFA_NCLOSE, /* End of subexpr. marked with \%( ... \) */ + NFA_START_INVISIBLE, ++ NFA_START_INVISIBLE_NEG, + NFA_START_INVISIBLE_BEFORE, ++ NFA_START_INVISIBLE_BEFORE_NEG, + NFA_START_PATTERN, + NFA_END_INVISIBLE, ++ NFA_END_INVISIBLE_NEG, + NFA_END_PATTERN, + NFA_COMPOSING, /* Next nodes in NFA are part of the + composing multibyte char */ +*************** +*** 481,487 **** + } + + default: +! if (p->c > 0 && !p->negated) + return p->c; /* yes! */ + return 0; + } +--- 484,490 ---- + } + + default: +! if (p->c > 0) + return p->c; /* yes! */ + return 0; + } +*************** +*** 1991,2000 **** +--- 1994,2008 ---- + case NFA_NOPEN: STRCPY(code, "NFA_NOPEN"); break; + case NFA_NCLOSE: STRCPY(code, "NFA_NCLOSE"); break; + case NFA_START_INVISIBLE: STRCPY(code, "NFA_START_INVISIBLE"); break; ++ case NFA_START_INVISIBLE_NEG: ++ STRCPY(code, "NFA_START_INVISIBLE_NEG"); break; + case NFA_START_INVISIBLE_BEFORE: + STRCPY(code, "NFA_START_INVISIBLE_BEFORE"); break; ++ case NFA_START_INVISIBLE_BEFORE_NEG: ++ STRCPY(code, "NFA_START_INVISIBLE_BEFORE_NEG"); break; + case NFA_START_PATTERN: STRCPY(code, "NFA_START_PATTERN"); break; + case NFA_END_INVISIBLE: STRCPY(code, "NFA_END_INVISIBLE"); break; ++ case NFA_END_INVISIBLE_NEG: STRCPY(code, "NFA_END_INVISIBLE_NEG"); break; + case NFA_END_PATTERN: STRCPY(code, "NFA_END_PATTERN"); break; + + case NFA_COMPOSING: STRCPY(code, "NFA_COMPOSING"); break; +*************** +*** 2227,2234 **** + fprintf(debugf, " %s", p); + + nfa_set_code(state->c); +! fprintf(debugf, "%s%s (%d) (id=%d) val=%d\n", +! state->negated ? "NOT " : "", + code, + state->c, + abs(state->id), +--- 2235,2241 ---- + fprintf(debugf, " %s", p); + + nfa_set_code(state->c); +! fprintf(debugf, "%s (%d) (id=%d) val=%d\n", + code, + state->c, + abs(state->id), +*************** +*** 2330,2336 **** + s->id = istate; + s->lastlist[0] = 0; + s->lastlist[1] = 0; +- s->negated = FALSE; + + return s; + } +--- 2337,2342 ---- +*************** +*** 2741,2763 **** + case NFA_PREV_ATOM_JUST_BEFORE_NEG: + case NFA_PREV_ATOM_LIKE_PATTERN: + { +- int neg = (*p == NFA_PREV_ATOM_NO_WIDTH_NEG +- || *p == NFA_PREV_ATOM_JUST_BEFORE_NEG); + int before = (*p == NFA_PREV_ATOM_JUST_BEFORE + || *p == NFA_PREV_ATOM_JUST_BEFORE_NEG); + int pattern = (*p == NFA_PREV_ATOM_LIKE_PATTERN); +! int start_state = NFA_START_INVISIBLE; +! int end_state = NFA_END_INVISIBLE; + int n = 0; + nfa_state_T *zend; + nfa_state_T *skip; + +! if (before) +! start_state = NFA_START_INVISIBLE_BEFORE; +! else if (pattern) + { +! start_state = NFA_START_PATTERN; +! end_state = NFA_END_PATTERN; + } + + if (before) +--- 2747,2783 ---- + case NFA_PREV_ATOM_JUST_BEFORE_NEG: + case NFA_PREV_ATOM_LIKE_PATTERN: + { + int before = (*p == NFA_PREV_ATOM_JUST_BEFORE + || *p == NFA_PREV_ATOM_JUST_BEFORE_NEG); + int pattern = (*p == NFA_PREV_ATOM_LIKE_PATTERN); +! int start_state; +! int end_state; + int n = 0; + nfa_state_T *zend; + nfa_state_T *skip; + +! switch (*p) + { +! case NFA_PREV_ATOM_NO_WIDTH: +! start_state = NFA_START_INVISIBLE; +! end_state = NFA_END_INVISIBLE; +! break; +! case NFA_PREV_ATOM_NO_WIDTH_NEG: +! start_state = NFA_START_INVISIBLE_NEG; +! end_state = NFA_END_INVISIBLE_NEG; +! break; +! case NFA_PREV_ATOM_JUST_BEFORE: +! start_state = NFA_START_INVISIBLE_BEFORE; +! end_state = NFA_END_INVISIBLE; +! break; +! case NFA_PREV_ATOM_JUST_BEFORE_NEG: +! start_state = NFA_START_INVISIBLE_BEFORE_NEG; +! end_state = NFA_END_INVISIBLE_NEG; +! break; +! case NFA_PREV_ATOM_LIKE_PATTERN: +! start_state = NFA_START_PATTERN; +! end_state = NFA_END_PATTERN; +! break; + } + + if (before) +*************** +*** 2783,2793 **** + s = alloc_state(start_state, e.start, s1); + if (s == NULL) + goto theend; +- if (neg) +- { +- s->negated = TRUE; +- s1->negated = TRUE; +- } + if (before) + s->val = n; /* store the count */ + if (pattern) +--- 2803,2808 ---- +*************** +*** 3009,3015 **** + matchstate = &state_ptr[istate++]; /* the match state */ + matchstate->c = NFA_MATCH; + matchstate->out = matchstate->out1 = NULL; +- matchstate->negated = FALSE; + matchstate->id = 0; + + patch(e.out, matchstate); +--- 3024,3029 ---- +*************** +*** 3772,3778 **** + return OK; + break; + case NFA_CLASS_SPACE: +! if ((c >=9 && c <= 13) || (c == ' ')) + return OK; + break; + case NFA_CLASS_UPPER: +--- 3786,3792 ---- + return OK; + break; + case NFA_CLASS_SPACE: +! if ((c >= 9 && c <= 13) || (c == ' ')) + return OK; + break; + case NFA_CLASS_UPPER: +*************** +*** 3971,3977 **** + int result; + int need_restore = FALSE; + +! if (state->c == NFA_START_INVISIBLE_BEFORE) + { + /* The recursive match must end at the current position. */ + endposp = &endpos; +--- 3985,3992 ---- + int result; + int need_restore = FALSE; + +! if (state->c == NFA_START_INVISIBLE_BEFORE +! || state->c == NFA_START_INVISIBLE_BEFORE_NEG) + { + /* The recursive match must end at the current position. */ + endposp = &endpos; +*************** +*** 4452,4457 **** +--- 4467,4473 ---- + } + + case NFA_END_INVISIBLE: ++ case NFA_END_INVISIBLE_NEG: + case NFA_END_PATTERN: + /* + * This is only encountered after a NFA_START_INVISIBLE or +*************** +*** 4489,4495 **** + break; + + /* do not set submatches for \@! */ +! if (!t->state->negated) + { + copy_sub(&m->norm, &t->subs.norm); + #ifdef FEAT_SYN_HL +--- 4505,4511 ---- + break; + + /* do not set submatches for \@! */ +! if (t->state->c != NFA_END_INVISIBLE_NEG) + { + copy_sub(&m->norm, &t->subs.norm); + #ifdef FEAT_SYN_HL +*************** +*** 4505,4511 **** +--- 4521,4529 ---- + break; + + case NFA_START_INVISIBLE: ++ case NFA_START_INVISIBLE_NEG: + case NFA_START_INVISIBLE_BEFORE: ++ case NFA_START_INVISIBLE_BEFORE_NEG: + { + nfa_pim_T *pim; + int cout = t->state->out1->out->c; +*************** +*** 4524,4529 **** +--- 4542,4548 ---- + || cout == NFA_NCLOSE + || t->pim != NULL + || (t->state->c != NFA_START_INVISIBLE_BEFORE ++ && t->state->c != NFA_START_INVISIBLE_BEFORE_NEG + && failure_chance(t->state->out1->out, 0) + < failure_chance(t->state->out, 0))) + { +*************** +*** 4534,4541 **** + result = recursive_regmatch(t->state, prog, + submatch, m, &listids); + +! /* for \@! it is a match when result is FALSE */ +! if (result != t->state->negated) + { + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->subs.norm, &m->norm); +--- 4553,4563 ---- + result = recursive_regmatch(t->state, prog, + submatch, m, &listids); + +! /* for \@! and \@state->c == NFA_START_INVISIBLE_NEG +! || t->state->c +! == NFA_START_INVISIBLE_BEFORE_NEG)) + { + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->subs.norm, &m->norm); +*************** +*** 4646,4656 **** + break; + + case NFA_BOW: +! { +! int bow = TRUE; + + if (curc == NUL) +! bow = FALSE; + #ifdef FEAT_MBYTE + else if (has_mbyte) + { +--- 4668,4677 ---- + break; + + case NFA_BOW: +! result = TRUE; + + if (curc == NUL) +! result = FALSE; + #ifdef FEAT_MBYTE + else if (has_mbyte) + { +*************** +*** 4659,4685 **** + /* Get class of current and previous char (if it exists). */ + this_class = mb_get_class_buf(reginput, reg_buf); + if (this_class <= 1) +! bow = FALSE; + else if (reg_prev_class() == this_class) +! bow = FALSE; + } + #endif + else if (!vim_iswordc_buf(curc, reg_buf) + || (reginput > regline + && vim_iswordc_buf(reginput[-1], reg_buf))) +! bow = FALSE; +! if (bow) + addstate_here(thislist, t->state->out, &t->subs, + t->pim, &listidx); + break; +- } + + case NFA_EOW: +! { +! int eow = TRUE; +! + if (reginput == regline) +! eow = FALSE; + #ifdef FEAT_MBYTE + else if (has_mbyte) + { +--- 4680,4703 ---- + /* Get class of current and previous char (if it exists). */ + this_class = mb_get_class_buf(reginput, reg_buf); + if (this_class <= 1) +! result = FALSE; + else if (reg_prev_class() == this_class) +! result = FALSE; + } + #endif + else if (!vim_iswordc_buf(curc, reg_buf) + || (reginput > regline + && vim_iswordc_buf(reginput[-1], reg_buf))) +! result = FALSE; +! if (result) + addstate_here(thislist, t->state->out, &t->subs, + t->pim, &listidx); + break; + + case NFA_EOW: +! result = TRUE; + if (reginput == regline) +! result = FALSE; + #ifdef FEAT_MBYTE + else if (has_mbyte) + { +*************** +*** 4690,4707 **** + prev_class = reg_prev_class(); + if (this_class == prev_class + || prev_class == 0 || prev_class == 1) +! eow = FALSE; + } + #endif + else if (!vim_iswordc_buf(reginput[-1], reg_buf) + || (reginput[0] != NUL + && vim_iswordc_buf(curc, reg_buf))) +! eow = FALSE; +! if (eow) + addstate_here(thislist, t->state->out, &t->subs, + t->pim, &listidx); + break; +- } + + case NFA_BOF: + if (reglnum == 0 && reginput == regline +--- 4708,4724 ---- + prev_class = reg_prev_class(); + if (this_class == prev_class + || prev_class == 0 || prev_class == 1) +! result = FALSE; + } + #endif + else if (!vim_iswordc_buf(reginput[-1], reg_buf) + || (reginput[0] != NUL + && vim_iswordc_buf(curc, reg_buf))) +! result = FALSE; +! if (result) + addstate_here(thislist, t->state->out, &t->subs, + t->pim, &listidx); + break; + + case NFA_BOF: + if (reglnum == 0 && reginput == regline +*************** +*** 4740,4746 **** + { + /* If \Z was present, then ignore composing characters. + * When ignoring the base character this always matches. */ +- /* TODO: How about negated? */ + if (len == 0 && sta->c != curc) + result = FAIL; + else +--- 4757,4762 ---- +*************** +*** 4813,4838 **** + } + break; + +- case NFA_CLASS_ALNUM: +- case NFA_CLASS_ALPHA: +- case NFA_CLASS_BLANK: +- case NFA_CLASS_CNTRL: +- case NFA_CLASS_DIGIT: +- case NFA_CLASS_GRAPH: +- case NFA_CLASS_LOWER: +- case NFA_CLASS_PRINT: +- case NFA_CLASS_PUNCT: +- case NFA_CLASS_SPACE: +- case NFA_CLASS_UPPER: +- case NFA_CLASS_XDIGIT: +- case NFA_CLASS_TAB: +- case NFA_CLASS_RETURN: +- case NFA_CLASS_BACKSPACE: +- case NFA_CLASS_ESCAPE: +- result = check_char_class(t->state->c, curc); +- ADD_STATE_IF_MATCH(t->state); +- break; +- + case NFA_START_COLL: + case NFA_START_NEG_COLL: + { +--- 4829,4834 ---- +*************** +*** 5212,5221 **** + int c = t->state->c; + + /* TODO: put this in #ifdef later */ +! if (c < -256) + EMSGN("INTERNAL: Negative state char: %ld", c); +- if (is_Magic(c)) +- c = un_Magic(c); + result = (c == curc); + + if (!result && ireg_ic) +--- 5208,5215 ---- + int c = t->state->c; + + /* TODO: put this in #ifdef later */ +! if (c < 0) + EMSGN("INTERNAL: Negative state char: %ld", c); + result = (c == curc); + + if (!result && ireg_ic) +*************** +*** 5252,5259 **** + prog, submatch, m, &listids); + t->pim->result = result ? NFA_PIM_MATCH + : NFA_PIM_NOMATCH; +! /* for \@! it is a match when result is FALSE */ +! if (result != t->pim->state->negated) + { + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->pim->subs.norm, &m->norm); +--- 5246,5257 ---- + prog, submatch, m, &listids); + t->pim->result = result ? NFA_PIM_MATCH + : NFA_PIM_NOMATCH; +! /* for \@! and \@pim->state->c +! == NFA_START_INVISIBLE_NEG +! || t->pim->state->c +! == NFA_START_INVISIBLE_BEFORE_NEG)) + { + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->pim->subs.norm, &m->norm); +*************** +*** 5274,5281 **** + #endif + } + +! /* for \@! it is a match when result is FALSE */ +! if (result != t->pim->state->negated) + { + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->subs.norm, &t->pim->subs.norm); +--- 5272,5281 ---- + #endif + } + +! /* for \@! and \@pim->state->c == NFA_START_INVISIBLE_NEG +! || t->pim->state->c +! == NFA_START_INVISIBLE_BEFORE_NEG)) + { + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->subs.norm, &t->pim->subs.norm); +*** ../vim-7.3.1138/src/regexp.h 2013-06-06 18:46:00.000000000 +0200 +--- src/regexp.h 2013-06-07 16:11:12.000000000 +0200 +*************** +*** 73,79 **** + nfa_state_T *out1; + int id; + int lastlist[2]; /* 0: normal, 1: recursive */ +- int negated; + int val; + }; + +--- 73,78 ---- +*** ../vim-7.3.1138/src/version.c 2013-06-07 14:59:14.000000000 +0200 +--- src/version.c 2013-06-07 16:11:59.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1139, + /**/ + +-- +Common sense is what tells you that the world is flat. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5147948c1eaca55b327a2ec777df5f7d6724e271 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:25 +0200 Subject: [PATCH 1032/3340] - patchlevel 1140 --- 7.3.1140 | 192 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 192 insertions(+) create mode 100644 7.3.1140 diff --git a/7.3.1140 b/7.3.1140 new file mode 100644 index 00000000..08def016 --- /dev/null +++ b/7.3.1140 @@ -0,0 +1,192 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1140 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1140 +Problem: New regexp engine: trying expensive match while the result is not + going to be used. +Solution: Check for output state already being in the state list. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1139/src/regexp_nfa.c 2013-06-07 16:31:44.000000000 +0200 +--- src/regexp_nfa.c 2013-06-07 17:16:31.000000000 +0200 +*************** +*** 3156,3161 **** +--- 3156,3163 ---- + static void copy_sub __ARGS((regsub_T *to, regsub_T *from)); + static void copy_sub_off __ARGS((regsub_T *to, regsub_T *from)); + static int sub_equal __ARGS((regsub_T *sub1, regsub_T *sub2)); ++ static int has_state_with_pos __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs)); ++ static int state_in_list __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs)); + static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, int off)); + static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, nfa_pim_T *pim, int *ip)); + +*************** +*** 3319,3324 **** +--- 3321,3371 ---- + } + #endif + ++ /* ++ * Return TRUE if the same state is already in list "l" with the same ++ * positions as "subs". ++ */ ++ static int ++ has_state_with_pos(l, state, subs) ++ nfa_list_T *l; /* runtime state list */ ++ nfa_state_T *state; /* state to update */ ++ regsubs_T *subs; /* pointers to subexpressions */ ++ { ++ nfa_thread_T *thread; ++ int i; ++ ++ for (i = 0; i < l->n; ++i) ++ { ++ thread = &l->t[i]; ++ if (thread->state->id == state->id ++ && sub_equal(&thread->subs.norm, &subs->norm) ++ #ifdef FEAT_SYN_HL ++ && (!nfa_has_zsubexpr || ++ sub_equal(&thread->subs.synt, &subs->synt)) ++ #endif ++ ) ++ return TRUE; ++ } ++ return FALSE; ++ } ++ ++ /* ++ * Return TRUE if "state" is already in list "l". ++ */ ++ static int ++ state_in_list(l, state, subs) ++ nfa_list_T *l; /* runtime state list */ ++ nfa_state_T *state; /* state to update */ ++ regsubs_T *subs; /* pointers to subexpressions */ ++ { ++ if (state->lastlist[nfa_ll_index] == l->id) ++ { ++ if (!nfa_has_backref || has_state_with_pos(l, state, subs)) ++ return TRUE; ++ } ++ return FALSE; ++ } ++ + static void + addstate(l, state, subs, off) + nfa_list_T *l; /* runtime state list */ +*************** +*** 3431,3450 **** + return; + } + +! /* See if the same state is already in the list with the same +! * positions. */ +! for (i = 0; i < l->n; ++i) +! { +! thread = &l->t[i]; +! if (thread->state->id == state->id +! && sub_equal(&thread->subs.norm, &subs->norm) +! #ifdef FEAT_SYN_HL +! && (!nfa_has_zsubexpr || +! sub_equal(&thread->subs.synt, &subs->synt)) +! #endif +! ) +! goto skip_add; +! } + } + + /* when there are backreferences or look-behind matches the number +--- 3478,3485 ---- + return; + } + +! if (has_state_with_pos(l, state, subs)) +! goto skip_add; + } + + /* when there are backreferences or look-behind matches the number +*************** +*** 4600,4605 **** +--- 4635,4681 ---- + break; + + case NFA_START_PATTERN: ++ { ++ nfa_state_T *skip = NULL; ++ #ifdef ENABLE_LOG ++ int skip_lid = 0; ++ #endif ++ ++ /* There is no point in trying to match the pattern if the ++ * output state is not going to be added to the list. */ ++ if (state_in_list(nextlist, t->state->out1->out, &t->subs)) ++ { ++ skip = t->state->out1->out; ++ #ifdef ENABLE_LOG ++ skip_lid = nextlist->id; ++ #endif ++ } ++ else if (state_in_list(nextlist, ++ t->state->out1->out->out, &t->subs)) ++ { ++ skip = t->state->out1->out->out; ++ #ifdef ENABLE_LOG ++ skip_lid = nextlist->id; ++ #endif ++ } ++ else if(state_in_list(thislist, ++ t->state->out1->out->out, &t->subs)) ++ { ++ skip = t->state->out1->out->out; ++ #ifdef ENABLE_LOG ++ skip_lid = thislist->id; ++ #endif ++ } ++ if (skip != NULL) ++ { ++ #ifdef ENABLE_LOG ++ nfa_set_code(skip->c); ++ fprintf(log_fd, "> Not trying to match pattern, output state %d is already in list %d. char %d: %s\n", ++ abs(skip->id), skip_lid, skip->c, code); ++ #endif ++ break; ++ } ++ + /* First try matching the pattern. */ + result = recursive_regmatch(t->state, prog, + submatch, m, &listids); +*************** +*** 4654,4659 **** +--- 4730,4736 ---- + } + } + break; ++ } + + case NFA_BOL: + if (reginput == regline) +*** ../vim-7.3.1139/src/version.c 2013-06-07 16:31:45.000000000 +0200 +--- src/version.c 2013-06-07 17:30:12.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1140, + /**/ + +-- +From "know your smileys": + :-* A big kiss! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a489da7633ad315bcb58f8eb32f86a7d2af500be Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:26 +0200 Subject: [PATCH 1033/3340] - patchlevel 1141 --- 7.3.1141 | 88 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 88 insertions(+) create mode 100644 7.3.1141 diff --git a/7.3.1141 b/7.3.1141 new file mode 100644 index 00000000..75894b13 --- /dev/null +++ b/7.3.1141 @@ -0,0 +1,88 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1141 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1141 +Problem: Win32: Check for available memory is not reliable and adds + overhead. +Solution: Remove mch_avail_mem(). (Mike Williams) +Files: src/os_win32.c, src/os_win32.h + + +*** ../vim-7.3.1140/src/os_win32.c 2013-05-06 04:21:35.000000000 +0200 +--- src/os_win32.c 2013-06-07 19:12:53.000000000 +0200 +*************** +*** 5048,5084 **** + } + + +- /* +- * How much memory is available in Kbyte? +- * Return sum of available physical and page file memory. +- */ +- /*ARGSUSED*/ +- long_u +- mch_avail_mem(int special) +- { +- #ifdef MEMORYSTATUSEX +- PlatformId(); +- if (g_PlatformId == VER_PLATFORM_WIN32_NT) +- { +- MEMORYSTATUSEX ms; +- +- /* Need to use GlobalMemoryStatusEx() when there is more memory than +- * what fits in 32 bits. But it's not always available. */ +- ms.dwLength = sizeof(MEMORYSTATUSEX); +- GlobalMemoryStatusEx(&ms); +- return (long_u)((ms.ullAvailPhys + ms.ullAvailPageFile) >> 10); +- } +- else +- #endif +- { +- MEMORYSTATUS ms; +- +- ms.dwLength = sizeof(MEMORYSTATUS); +- GlobalMemoryStatus(&ms); +- return (long_u)((ms.dwAvailPhys + ms.dwAvailPageFile) >> 10); +- } +- } +- + #ifdef FEAT_MBYTE + /* + * Same code as below, but with wide functions and no comments. +--- 5048,5053 ---- +*** ../vim-7.3.1140/src/os_win32.h 2013-05-06 04:21:35.000000000 +0200 +--- src/os_win32.h 2013-06-07 19:14:42.000000000 +0200 +*************** +*** 80,86 **** + #ifndef FEAT_GUI_W32 /* GUI works different */ + # define BREAKCHECK_SKIP 1 /* call mch_breakcheck() each time, it's fast */ + #endif +- #define HAVE_AVAIL_MEM + + #define HAVE_PUTENV /* at least Bcc 5.2 and MSC have it */ + +--- 80,85 ---- +*** ../vim-7.3.1140/src/version.c 2013-06-07 17:31:25.000000000 +0200 +--- src/version.c 2013-06-07 19:13:48.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1141, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +95. Only communication in your household is through email. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ee94379853b3e6c124175f33e2b975320d9c6022 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:27 +0200 Subject: [PATCH 1034/3340] - patchlevel 1142 --- 7.3.1142 | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 7.3.1142 diff --git a/7.3.1142 b/7.3.1142 new file mode 100644 index 00000000..63c9cda2 --- /dev/null +++ b/7.3.1142 @@ -0,0 +1,45 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1142 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1142 +Problem: Memory leak in ":syntime report". +Solution: Clear the grow array. (Dominique Pelle) +Files: src/syntax.c + + +*** ../vim-7.3.1141/src/syntax.c 2013-06-06 21:19:40.000000000 +0200 +--- src/syntax.c 2013-06-07 19:35:24.000000000 +0200 +*************** +*** 6689,6694 **** +--- 6689,6695 ---- + msg_outtrans_len(p->pattern, len); + MSG_PUTS("\n"); + } ++ ga_clear(&ga); + if (!got_int) + { + MSG_PUTS("\n"); +*** ../vim-7.3.1141/src/version.c 2013-06-07 19:17:12.000000000 +0200 +--- src/version.c 2013-06-07 19:36:10.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1142, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +99. The hum of a cooling fan and the click of keys is comforting to you. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4e500b5c5872a96335e001907eed1f0f942a0587 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:28 +0200 Subject: [PATCH 1035/3340] - patchlevel 1143 --- 7.3.1143 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.1143 diff --git a/7.3.1143 b/7.3.1143 new file mode 100644 index 00000000..5bd6e1a9 --- /dev/null +++ b/7.3.1143 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1143 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1143 +Problem: When mapping NUL it is displayed as an X. +Solution: Check for KS_ZERO instead of K_ZERO. (Yasuhiro Matsumoto) +Files: src/message.c + + +*** ../vim-7.3.1142/src/message.c 2013-04-24 15:12:27.000000000 +0200 +--- src/message.c 2013-06-07 19:47:23.000000000 +0200 +*************** +*** 1577,1583 **** + { + c = TO_SPECIAL(str[1], str[2]); + str += 2; +! if (c == K_ZERO) /* display as ^@ */ + c = NUL; + } + if (IS_SPECIAL(c) || modifiers) /* special key */ +--- 1577,1583 ---- + { + c = TO_SPECIAL(str[1], str[2]); + str += 2; +! if (c == KS_ZERO) /* display as ^@ or */ + c = NUL; + } + if (IS_SPECIAL(c) || modifiers) /* special key */ +*** ../vim-7.3.1142/src/version.c 2013-06-07 19:48:29.000000000 +0200 +--- src/version.c 2013-06-07 19:50:32.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1143, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +100. The most exciting sporting events you noticed during summer 1996 + was Netscape vs. Microsoft. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 78807e2f40305aa42849f2a355608df6378b3e18 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:29 +0200 Subject: [PATCH 1036/3340] - patchlevel 1144 --- 7.3.1144 | 87 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 87 insertions(+) create mode 100644 7.3.1144 diff --git a/7.3.1144 b/7.3.1144 new file mode 100644 index 00000000..aa5d574f --- /dev/null +++ b/7.3.1144 @@ -0,0 +1,87 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1144 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1144 +Problem: "RO" is not translated everywhere. +Solution: Put inside _(). (Sergey Alyoshin) +Files: src/buffer.c, src/screen.c + + +*** ../vim-7.3.1143/src/buffer.c 2013-05-06 04:50:26.000000000 +0200 +--- src/buffer.c 2013-06-07 20:15:03.000000000 +0200 +*************** +*** 3139,3145 **** + #endif + ? _("[New file]") : "", + (curbuf->b_flags & BF_READERR) ? _("[Read errors]") : "", +! curbuf->b_p_ro ? (shortmess(SHM_RO) ? "[RO]" + : _("[readonly]")) : "", + (curbufIsChanged() || (curbuf->b_flags & BF_WRITE_MASK) + || curbuf->b_p_ro) ? +--- 3139,3145 ---- + #endif + ? _("[New file]") : "", + (curbuf->b_flags & BF_READERR) ? _("[Read errors]") : "", +! curbuf->b_p_ro ? (shortmess(SHM_RO) ? _("[RO]") + : _("[readonly]")) : "", + (curbufIsChanged() || (curbuf->b_flags & BF_WRITE_MASK) + || curbuf->b_p_ro) ? +*************** +*** 3976,3982 **** + case STL_ROFLAG_ALT: + itemisflag = TRUE; + if (wp->w_buffer->b_p_ro) +! str = (char_u *)((opt == STL_ROFLAG_ALT) ? ",RO" : "[RO]"); + break; + + case STL_HELPFLAG: +--- 3976,3982 ---- + case STL_ROFLAG_ALT: + itemisflag = TRUE; + if (wp->w_buffer->b_p_ro) +! str = (char_u *)((opt == STL_ROFLAG_ALT) ? ",RO" : _("[RO]")); + break; + + case STL_HELPFLAG: +*** ../vim-7.3.1143/src/screen.c 2013-06-04 22:13:45.000000000 +0200 +--- src/screen.c 2013-06-07 20:15:06.000000000 +0200 +*************** +*** 6281,6287 **** + } + if (wp->w_buffer->b_p_ro) + { +! STRCPY(p + len, "[RO]"); + len += 4; + } + +--- 6281,6287 ---- + } + if (wp->w_buffer->b_p_ro) + { +! STRCPY(p + len, _("[RO]")); + len += 4; + } + +*** ../vim-7.3.1143/src/version.c 2013-06-07 19:53:04.000000000 +0200 +--- src/version.c 2013-06-07 20:16:03.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1144, + /**/ + +-- +A meeting is an event at which the minutes are kept and the hours are lost. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From aa0805b99fee5d55eaad0ebecc403c76a444eb81 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:30 +0200 Subject: [PATCH 1037/3340] - patchlevel 1145 --- 7.3.1145 | 142 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 142 insertions(+) create mode 100644 7.3.1145 diff --git a/7.3.1145 b/7.3.1145 new file mode 100644 index 00000000..bab42f38 --- /dev/null +++ b/7.3.1145 @@ -0,0 +1,142 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1145 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1145 +Problem: New regexp engine: addstate() is called very often. +Solution: Optimize adding the start state. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1144/src/regexp_nfa.c 2013-06-07 17:31:25.000000000 +0200 +--- src/regexp_nfa.c 2013-06-07 22:03:12.000000000 +0200 +*************** +*** 4332,4340 **** + nfa_list_T *nextlist; + int *listids = NULL; + nfa_state_T *add_state; +! int add_count; +! int add_off; + garray_T pimlist; + #ifdef NFA_REGEXP_DEBUG_LOG + FILE *debug = fopen(NFA_REGEXP_DEBUG_LOG, "a"); + +--- 4332,4341 ---- + nfa_list_T *nextlist; + int *listids = NULL; + nfa_state_T *add_state; +! int add_count; +! int add_off; + garray_T pimlist; ++ int toplevel = start->c == NFA_MOPEN; + #ifdef NFA_REGEXP_DEBUG_LOG + FILE *debug = fopen(NFA_REGEXP_DEBUG_LOG, "a"); + +*************** +*** 4378,4387 **** + nextlist = &list[1]; + nextlist->n = 0; + #ifdef ENABLE_LOG +! fprintf(log_fd, "(---) STARTSTATE\n"); + #endif + thislist->id = nfa_listid + 1; +! addstate(thislist, start, m, 0); + + #define ADD_STATE_IF_MATCH(state) \ + if (result) { \ +--- 4379,4404 ---- + nextlist = &list[1]; + nextlist->n = 0; + #ifdef ENABLE_LOG +! fprintf(log_fd, "(---) STARTSTATE first\n"); + #endif + thislist->id = nfa_listid + 1; +! +! /* Inline optimized code for addstate(thislist, start, m, 0) if we know +! * it's the first MOPEN. */ +! if (toplevel) +! { +! if (REG_MULTI) +! { +! m->norm.list.multi[0].start.lnum = reglnum; +! m->norm.list.multi[0].start.col = (colnr_T)(reginput - regline); +! } +! else +! m->norm.list.line[0].start = reginput; +! m->norm.in_use = 1; +! addstate(thislist, start->out, m, 0); +! } +! else +! addstate(thislist, start, m, 0); + + #define ADD_STATE_IF_MATCH(state) \ + if (result) { \ +*************** +*** 5382,5388 **** + * Unless "nfa_endp" is not NULL, then we match the end position. + * Also don't start a match past the first line. */ + if (nfa_match == FALSE +! && ((start->c == NFA_MOPEN + && reglnum == 0 + && clen != 0 + && (ireg_maxcol == 0 +--- 5399,5405 ---- + * Unless "nfa_endp" is not NULL, then we match the end position. + * Also don't start a match past the first line. */ + if (nfa_match == FALSE +! && ((toplevel + && reglnum == 0 + && clen != 0 + && (ireg_maxcol == 0 +*************** +*** 5398,5404 **** + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif +! addstate(nextlist, start, m, clen); + } + + #ifdef ENABLE_LOG +--- 5415,5433 ---- + #ifdef ENABLE_LOG + fprintf(log_fd, "(---) STARTSTATE\n"); + #endif +! /* Inline optimized code for addstate() if we know the state is +! * the first MOPEN. */ +! if (toplevel) +! { +! if (REG_MULTI) +! m->norm.list.multi[0].start.col = +! (colnr_T)(reginput - regline) + clen; +! else +! m->norm.list.line[0].start = reginput + clen; +! addstate(nextlist, start->out, m, clen); +! } +! else +! addstate(nextlist, start, m, clen); + } + + #ifdef ENABLE_LOG +*** ../vim-7.3.1144/src/version.c 2013-06-07 20:17:06.000000000 +0200 +--- src/version.c 2013-06-07 22:37:03.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1145, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +104. When people ask about the Presidential Election you ask "Which country?" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d17aa00703781287d8090dc44e4ad6454bbf6f26 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:31 +0200 Subject: [PATCH 1038/3340] - patchlevel 1146 --- 7.3.1146 | 400 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 400 insertions(+) create mode 100644 7.3.1146 diff --git a/7.3.1146 b/7.3.1146 new file mode 100644 index 00000000..86b83dc9 --- /dev/null +++ b/7.3.1146 @@ -0,0 +1,400 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1146 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1146 +Problem: New regexp engine: look-behind match not checked when followed by + zero-width match. +Solution: Do the look-behind match before adding the zero-width state. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1145/src/regexp_nfa.c 2013-06-07 22:39:35.000000000 +0200 +--- src/regexp_nfa.c 2013-06-08 13:16:52.000000000 +0200 +*************** +*** 4332,4337 **** +--- 4332,4338 ---- + nfa_list_T *nextlist; + int *listids = NULL; + nfa_state_T *add_state; ++ int add_here; + int add_count; + int add_off; + garray_T pimlist; +*************** +*** 4495,4500 **** +--- 4496,4502 ---- + * The most important is NFA_MATCH. + */ + add_state = NULL; ++ add_here = FALSE; + add_count = 0; + switch (t->state->c) + { +*************** +*** 4621,4638 **** + /* t->state->out1 is the corresponding + * END_INVISIBLE node; Add its out to the current + * list (zero-width match). */ +! addstate_here(thislist, t->state->out1->out, +! &t->subs, t->pim, &listidx); + } + } + else + { + /* + * First try matching what follows at the current +! * position. Only if a match is found, addstate() is +! * called, then verify the invisible match matches. +! * Add a nfa_pim_T to the following states, it +! * contains info about the invisible match. + */ + if (ga_grow(&pimlist, 1) == FAIL) + goto theend; +--- 4623,4640 ---- + /* t->state->out1 is the corresponding + * END_INVISIBLE node; Add its out to the current + * list (zero-width match). */ +! add_here = TRUE; +! add_state = t->state->out1->out; + } + } + else + { + /* + * First try matching what follows at the current +! * position. Only if a match is found, before +! * addstate() is called, then verify the invisible +! * match matches. Add a nfa_pim_T to the following +! * states, it contains info about the invisible match. + */ + if (ga_grow(&pimlist, 1) == FAIL) + goto theend; +*************** +*** 4727,4734 **** + /* empty match, output of corresponding + * NFA_END_PATTERN/NFA_SKIP to be used at current + * position */ +! addstate_here(thislist, t->state->out1->out->out, +! &t->subs, t->pim, &listidx); + } + else if (bytelen <= clen) + { +--- 4729,4736 ---- + /* empty match, output of corresponding + * NFA_END_PATTERN/NFA_SKIP to be used at current + * position */ +! add_here = TRUE; +! add_state = t->state->out1->out->out; + } + else if (bytelen <= clen) + { +*************** +*** 4751,4764 **** + + case NFA_BOL: + if (reginput == regline) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + case NFA_EOL: + if (curc == NUL) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + case NFA_BOW: +--- 4753,4770 ---- + + case NFA_BOL: + if (reginput == regline) +! { +! add_here = TRUE; +! add_state = t->state->out; +! } + break; + + case NFA_EOL: + if (curc == NUL) +! { +! add_here = TRUE; +! add_state = t->state->out; +! } + break; + + case NFA_BOW: +*************** +*** 4784,4791 **** + && vim_iswordc_buf(reginput[-1], reg_buf))) + result = FALSE; + if (result) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + case NFA_EOW: +--- 4790,4799 ---- + && vim_iswordc_buf(reginput[-1], reg_buf))) + result = FALSE; + if (result) +! { +! add_here = TRUE; +! add_state = t->state->out; +! } + break; + + case NFA_EOW: +*************** +*** 4810,4830 **** + && vim_iswordc_buf(curc, reg_buf))) + result = FALSE; + if (result) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + case NFA_BOF: + if (reglnum == 0 && reginput == regline + && (!REG_MULTI || reg_firstlnum == 1)) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + case NFA_EOF: + if (reglnum == reg_maxline && curc == NUL) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + #ifdef FEAT_MBYTE +--- 4818,4844 ---- + && vim_iswordc_buf(curc, reg_buf))) + result = FALSE; + if (result) +! { +! add_here = TRUE; +! add_state = t->state->out; +! } + break; + + case NFA_BOF: + if (reglnum == 0 && reginput == regline + && (!REG_MULTI || reg_firstlnum == 1)) +! { +! add_here = TRUE; +! add_state = t->state->out; +! } + break; + + case NFA_EOF: + if (reglnum == reg_maxline && curc == NUL) +! { +! add_here = TRUE; +! add_state = t->state->out; +! } + break; + + #ifdef FEAT_MBYTE +*************** +*** 5183,5190 **** + { + /* empty match always works, output of NFA_SKIP to be + * used next */ +! addstate_here(thislist, t->state->out->out, &t->subs, +! t->pim, &listidx); + } + else if (bytelen <= clen) + { +--- 5197,5204 ---- + { + /* empty match always works, output of NFA_SKIP to be + * used next */ +! add_here = TRUE; +! add_state = t->state->out->out; + } + else if (bytelen <= clen) + { +*************** +*** 5228,5235 **** + nfa_re_num_cmp(t->state->val, t->state->c - NFA_LNUM, + (long_u)(reglnum + reg_firstlnum))); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + case NFA_COL: +--- 5242,5251 ---- + nfa_re_num_cmp(t->state->val, t->state->c - NFA_LNUM, + (long_u)(reglnum + reg_firstlnum))); + if (result) +! { +! add_here = TRUE; +! add_state = t->state->out; +! } + break; + + case NFA_COL: +*************** +*** 5238,5245 **** + result = nfa_re_num_cmp(t->state->val, t->state->c - NFA_COL, + (long_u)(reginput - regline) + 1); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + case NFA_VCOL: +--- 5254,5263 ---- + result = nfa_re_num_cmp(t->state->val, t->state->c - NFA_COL, + (long_u)(reginput - regline) + 1); + if (result) +! { +! add_here = TRUE; +! add_state = t->state->out; +! } + break; + + case NFA_VCOL: +*************** +*** 5250,5257 **** + reg_win == NULL ? curwin : reg_win, + regline, (colnr_T)(reginput - regline)) + 1); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + case NFA_MARK: +--- 5268,5277 ---- + reg_win == NULL ? curwin : reg_win, + regline, (colnr_T)(reginput - regline)) + 1); + if (result) +! { +! add_here = TRUE; +! add_state = t->state->out; +! } + break; + + case NFA_MARK: +*************** +*** 5273,5280 **** + ? t->state->c == NFA_MARK_GT + : t->state->c == NFA_MARK_LT))); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + } + +--- 5293,5302 ---- + ? t->state->c == NFA_MARK_GT + : t->state->c == NFA_MARK_LT))); + if (result) +! { +! add_here = TRUE; +! add_state = t->state->out; +! } + break; + } + +*************** +*** 5284,5299 **** + && ((colnr_T)(reginput - regline) + == reg_win->w_cursor.col)); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + break; + + case NFA_VISUAL: + #ifdef FEAT_VISUAL + result = reg_match_visual(); + if (result) +! addstate_here(thislist, t->state->out, &t->subs, +! t->pim, &listidx); + #endif + break; + +--- 5306,5325 ---- + && ((colnr_T)(reginput - regline) + == reg_win->w_cursor.col)); + if (result) +! { +! add_here = TRUE; +! add_state = t->state->out; +! } + break; + + case NFA_VISUAL: + #ifdef FEAT_VISUAL + result = reg_match_visual(); + if (result) +! { +! add_here = TRUE; +! add_state = t->state->out; +! } + #endif + break; + +*************** +*** 5327,5333 **** + if (t->pim != NULL) + { + /* postponed invisible match */ +- /* TODO: also do t->pim->pim recursively? */ + if (t->pim->result == NFA_PIM_TODO) + { + #ifdef ENABLE_LOG +--- 5353,5358 ---- +*************** +*** 5383,5391 **** + continue; + } + +! addstate(nextlist, add_state, &t->subs, add_off); +! if (add_count > 0) +! nextlist->t[nextlist->n - 1].count = add_count; + } + + } /* for (thislist = thislist; thislist->state; thislist++) */ +--- 5408,5421 ---- + continue; + } + +! if (add_here) +! addstate_here(thislist, add_state, &t->subs, NULL, &listidx); +! else +! { +! addstate(nextlist, add_state, &t->subs, add_off); +! if (add_count > 0) +! nextlist->t[nextlist->n - 1].count = add_count; +! } + } + + } /* for (thislist = thislist; thislist->state; thislist++) */ +*** ../vim-7.3.1145/src/version.c 2013-06-07 22:39:35.000000000 +0200 +--- src/version.c 2013-06-08 13:30:41.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1146, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +111. You and your friends get together regularly on IRC, even though + all of you live in the same city. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3ea9d86f22e866e8a2232dd38f6a6516e91ed44f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:32 +0200 Subject: [PATCH 1039/3340] - patchlevel 1147 --- 7.3.1147 | 183 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 183 insertions(+) create mode 100644 7.3.1147 diff --git a/7.3.1147 b/7.3.1147 new file mode 100644 index 00000000..de33af37 --- /dev/null +++ b/7.3.1147 @@ -0,0 +1,183 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1147 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1147 +Problem: New regexp engine: regstart is only used to find the first match. +Solution: Use regstart whenever adding the start state. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1146/src/regexp_nfa.c 2013-06-08 13:33:32.000000000 +0200 +--- src/regexp_nfa.c 2013-06-08 14:37:36.000000000 +0200 +*************** +*** 4153,4158 **** +--- 4153,4159 ---- + } + + static int failure_chance __ARGS((nfa_state_T *state, int depth)); ++ static int skip_to_start __ARGS((int c, colnr_T *colp)); + + /* + * Estimate the chance of a match with "state" failing. +*************** +*** 4305,4310 **** +--- 4306,4336 ---- + } + + /* ++ * Skip until the char "c" we know a match must start with. ++ */ ++ static int ++ skip_to_start(c, colp) ++ int c; ++ colnr_T *colp; ++ { ++ char_u *s; ++ ++ /* Used often, do some work to avoid call overhead. */ ++ if (!ireg_ic ++ #ifdef FEAT_MBYTE ++ && !has_mbyte ++ #endif ++ ) ++ s = vim_strbyte(regline + *colp, c); ++ else ++ s = cstrchr(regline + *colp, c); ++ if (s == NULL) ++ return FAIL; ++ *colp = (int)(s - regline); ++ return OK; ++ } ++ ++ /* + * Main matching routine. + * + * Run NFA to determine whether it matches reginput. +*************** +*** 5449,5460 **** + * the first MOPEN. */ + if (toplevel) + { +! if (REG_MULTI) +! m->norm.list.multi[0].start.col = + (colnr_T)(reginput - regline) + clen; +! else +! m->norm.list.line[0].start = reginput + clen; +! addstate(nextlist, start->out, m, clen); + } + else + addstate(nextlist, start, m, clen); +--- 5475,5524 ---- + * the first MOPEN. */ + if (toplevel) + { +! int add = TRUE; +! int c; +! +! if (prog->regstart != NUL && clen != 0) +! { +! if (nextlist->n == 0) +! { +! colnr_T col = (colnr_T)(reginput - regline) + clen; +! +! /* Nextlist is empty, we can skip ahead to the +! * character that must appear at the start. */ +! if (skip_to_start(prog->regstart, &col) == FAIL) +! break; +! #ifdef ENABLE_LOG +! fprintf(log_fd, " Skipping ahead %d bytes to regstart\n", +! col - ((colnr_T)(reginput - regline) + clen)); +! #endif +! reginput = regline + col - clen; +! } +! else +! { +! /* Checking if the required start character matches is +! * cheaper than adding a state that won't match. */ +! c = PTR2CHAR(reginput + clen); +! if (c != prog->regstart && (!ireg_ic || MB_TOLOWER(c) +! != MB_TOLOWER(prog->regstart))) +! { +! #ifdef ENABLE_LOG +! fprintf(log_fd, " Skipping start state, regstart does not match\n"); +! #endif +! add = FALSE; +! } +! } +! } +! +! if (add) +! { +! if (REG_MULTI) +! m->norm.list.multi[0].start.col = + (colnr_T)(reginput - regline) + clen; +! else +! m->norm.list.line[0].start = reginput + clen; +! addstate(nextlist, start->out, m, clen); +! } + } + else + addstate(nextlist, start, m, clen); +*************** +*** 5701,5723 **** + return 0L; + + if (prog->regstart != NUL) +! { +! char_u *s; +! +! /* Skip until the char we know it must start with. +! * Used often, do some work to avoid call overhead. */ +! if (!ireg_ic +! #ifdef FEAT_MBYTE +! && !has_mbyte +! #endif +! ) +! s = vim_strbyte(regline + col, prog->regstart); +! else +! s = cstrchr(regline + col, prog->regstart); +! if (s == NULL) + return 0L; +- col = (int)(s - regline); +- } + + /* If the start column is past the maximum column: no need to try. */ + if (ireg_maxcol > 0 && col >= ireg_maxcol) +--- 5765,5774 ---- + return 0L; + + if (prog->regstart != NUL) +! /* Skip ahead until a character we know the match must start with. +! * When there is none there is no match. */ +! if (skip_to_start(prog->regstart, &col) == FAIL) + return 0L; + + /* If the start column is past the maximum column: no need to try. */ + if (ireg_maxcol > 0 && col >= ireg_maxcol) +*** ../vim-7.3.1146/src/version.c 2013-06-08 13:33:32.000000000 +0200 +--- src/version.c 2013-06-08 14:35:54.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1147, + /**/ + +-- +Nobody will ever need more than 640 kB RAM. + -- Bill Gates, 1983 +Windows 98 requires 16 MB RAM. + -- Bill Gates, 1999 +Logical conclusion: Nobody will ever need Windows 98. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From be7907173cf8d253b925725f6c7b728fab7285c7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:33 +0200 Subject: [PATCH 1040/3340] - patchlevel 1148 --- 7.3.1148 | 176 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 176 insertions(+) create mode 100644 7.3.1148 diff --git a/7.3.1148 b/7.3.1148 new file mode 100644 index 00000000..33f41965 --- /dev/null +++ b/7.3.1148 @@ -0,0 +1,176 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1148 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1148 +Problem: No command line completion for ":syntime". +Solution: Implement the completion. (Dominique Pelle) +Files: runtime/doc/map.txt, src/ex_cmds.h, src/ex_docmd.c, + src/ex_getln.c, src/proto/syntax.pro, src/syntax.c, src/vim.h + + +*** ../vim-7.3.1147/runtime/doc/map.txt 2012-08-15 14:04:50.000000000 +0200 +--- runtime/doc/map.txt 2013-06-08 15:08:20.000000000 +0200 +*************** +*** 1225,1230 **** +--- 1242,1248 ---- + -complete=shellcmd Shell command + -complete=sign |:sign| suboptions + -complete=syntax syntax file names |'syntax'| ++ -complete=syntime |:syntime| suboptions + -complete=tag tags + -complete=tag_listfiles tags, file names are shown when CTRL-D is hit + -complete=user user names +*** ../vim-7.3.1147/src/ex_cmds.h 2013-06-06 14:01:35.000000000 +0200 +--- src/ex_cmds.h 2013-06-08 15:08:20.000000000 +0200 +*************** +*** 926,932 **** + EX(CMD_syntax, "syntax", ex_syntax, + EXTRA|NOTRLCOM|CMDWIN), + EX(CMD_syntime, "syntime", ex_syntime, +! WORD1|TRLBAR|CMDWIN), + EX(CMD_syncbind, "syncbind", ex_syncbind, + TRLBAR), + EX(CMD_t, "t", ex_copymove, +--- 926,932 ---- + EX(CMD_syntax, "syntax", ex_syntax, + EXTRA|NOTRLCOM|CMDWIN), + EX(CMD_syntime, "syntime", ex_syntime, +! NEEDARG|WORD1|TRLBAR|CMDWIN), + EX(CMD_syncbind, "syncbind", ex_syncbind, + TRLBAR), + EX(CMD_t, "t", ex_copymove, +*** ../vim-7.3.1147/src/ex_docmd.c 2013-06-06 14:55:16.000000000 +0200 +--- src/ex_docmd.c 2013-06-08 15:08:20.000000000 +0200 +*************** +*** 3994,3999 **** +--- 3994,4005 ---- + xp->xp_pattern = arg; + break; + #endif ++ #if defined(FEAT_PROFILE) ++ case CMD_syntime: ++ xp->xp_context = EXPAND_SYNTIME; ++ xp->xp_pattern = arg; ++ break; ++ #endif + + #endif /* FEAT_CMDL_COMPL */ + +*************** +*** 5436,5441 **** +--- 5442,5450 ---- + {EXPAND_MAPPINGS, "mapping"}, + {EXPAND_MENUS, "menu"}, + {EXPAND_OWNSYNTAX, "syntax"}, ++ #if defined(FEAT_PROFILE) ++ {EXPAND_SYNTIME, "syntime"}, ++ #endif + {EXPAND_SETTINGS, "option"}, + {EXPAND_SHELLCMD, "shellcmd"}, + #if defined(FEAT_SIGNS) +*** ../vim-7.3.1147/src/ex_getln.c 2013-04-24 15:39:06.000000000 +0200 +--- src/ex_getln.c 2013-06-08 15:08:20.000000000 +0200 +*************** +*** 4674,4679 **** +--- 4674,4682 ---- + #ifdef FEAT_SYN_HL + {EXPAND_SYNTAX, get_syntax_name, TRUE, TRUE}, + #endif ++ #ifdef FEAT_PROFILE ++ {EXPAND_SYNTIME, get_syntime_arg, TRUE, TRUE}, ++ #endif + {EXPAND_HIGHLIGHT, get_highlight_name, TRUE, TRUE}, + #ifdef FEAT_AUTOCMD + {EXPAND_EVENTS, get_event_name, TRUE, TRUE}, +*** ../vim-7.3.1147/src/proto/syntax.pro 2013-06-06 14:01:35.000000000 +0200 +--- src/proto/syntax.pro 2013-06-08 15:08:20.000000000 +0200 +*************** +*** 20,25 **** +--- 20,26 ---- + int syn_get_stack_item __ARGS((int i)); + int syn_get_foldlevel __ARGS((win_T *wp, long lnum)); + void ex_syntime __ARGS((exarg_T *eap)); ++ char_u *get_syntime_arg __ARGS((expand_T *xp, int idx)); + void init_highlight __ARGS((int both, int reset)); + int load_colors __ARGS((char_u *name)); + void do_highlight __ARGS((char_u *line, int forceit, int init)); +*** ../vim-7.3.1147/src/syntax.c 2013-06-07 19:48:29.000000000 +0200 +--- src/syntax.c 2013-06-08 15:12:43.000000000 +0200 +*************** +*** 6577,6582 **** +--- 6577,6603 ---- + } + } + ++ #if defined(FEAT_CMDL_COMPL) || defined(PROTO) ++ /* ++ * Function given to ExpandGeneric() to obtain the possible arguments of the ++ * ":syntime {on,off,clear,report}" command. ++ */ ++ char_u * ++ get_syntime_arg(xp, idx) ++ expand_T *xp UNUSED; ++ int idx; ++ { ++ switch (idx) ++ { ++ case 0: return (char_u *)"on"; ++ case 1: return (char_u *)"off"; ++ case 2: return (char_u *)"clear"; ++ case 3: return (char_u *)"report"; ++ } ++ return NULL; ++ } ++ #endif ++ + typedef struct + { + proftime_T total; +*************** +*** 6610,6616 **** +--- 6631,6639 ---- + { + int idx; + synpat_T *spp; ++ # ifdef FEAT_FLOAT + proftime_T tm; ++ # endif + int len; + proftime_T total_total; + int total_count = 0; +*** ../vim-7.3.1147/src/vim.h 2013-05-30 13:37:23.000000000 +0200 +--- src/vim.h 2013-06-08 15:08:20.000000000 +0200 +*************** +*** 783,788 **** +--- 783,789 ---- + #define EXPAND_LOCALES 40 + #define EXPAND_HISTORY 41 + #define EXPAND_USER 42 ++ #define EXPAND_SYNTIME 43 + + /* Values for exmode_active (0 is no exmode) */ + #define EXMODE_NORMAL 1 +*** ../vim-7.3.1147/src/version.c 2013-06-08 14:38:23.000000000 +0200 +--- src/version.c 2013-06-08 15:23:00.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1148, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +113. You are asked about a bus schedule, you wonder if it is 16 or 32 bits. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 845bd6dec9f414e8755075bc875bfc6fb1c008bd Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:34 +0200 Subject: [PATCH 1041/3340] - patchlevel 1149 --- 7.3.1149 | 1542 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1542 insertions(+) create mode 100644 7.3.1149 diff --git a/7.3.1149 b/7.3.1149 new file mode 100644 index 00000000..15234065 --- /dev/null +++ b/7.3.1149 @@ -0,0 +1,1542 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1149 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1149 +Problem: New regexp engine: Matching plain text could be faster. +Solution: Detect a plain text match and handle it specifically. Add + vim_regfree(). +Files: src/regexp.c, src/regexp.h, src/regexp_nfa.c, + src/proto/regexp.pro, src/buffer.c, src/edit.c, src/eval.c, + src/ex_cmds.c, src/ex_cmds2.c, src/ex_docmd.c, src/ex_eval.c, + src/ex_getln.c, src/fileio.c, src/gui.c, src/misc1.c, src/misc2.c, + src/option.c, src/syntax.c, src/quickfix.c, src/search.c, + src/spell.c, src/tag.c, src/window.c, src/screen.c, src/macros.h, + src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1148/src/regexp.c 2013-06-06 18:04:47.000000000 +0200 +--- src/regexp.c 2013-06-08 17:13:06.000000000 +0200 +*************** +*** 1297,1303 **** + return p; + } + +! static regprog_T *bt_regcomp __ARGS((char_u *expr, int re_flags)); + + /* + * bt_regcomp() - compile a regular expression into internal code for the +--- 1297,1304 ---- + return p; + } + +! static regprog_T *bt_regcomp __ARGS((char_u *expr, int re_flags)); +! static void bt_regfree __ARGS((regprog_T *prog)); + + /* + * bt_regcomp() - compile a regular expression into internal code for the +*************** +*** 1455,1460 **** +--- 1456,1471 ---- + } + + /* ++ * Free a compiled regexp program, returned by bt_regcomp(). ++ */ ++ static void ++ bt_regfree(prog) ++ regprog_T *prog; ++ { ++ vim_free(prog); ++ } ++ ++ /* + * Setup to parse the regexp. Used once to get the length and once to do it. + */ + static void +*************** +*** 7876,7881 **** +--- 7887,7893 ---- + static regengine_T bt_regengine = + { + bt_regcomp, ++ bt_regfree, + bt_regexec, + #if defined(FEAT_MODIFY_FNAME) || defined(FEAT_EVAL) \ + || defined(FIND_REPLACE_DIALOG) || defined(PROTO) +*************** +*** 7893,7898 **** +--- 7905,7911 ---- + static regengine_T nfa_regengine = + { + nfa_regcomp, ++ nfa_regfree, + nfa_regexec, + #if defined(FEAT_MODIFY_FNAME) || defined(FEAT_EVAL) \ + || defined(FIND_REPLACE_DIALOG) || defined(PROTO) +*************** +*** 7920,7926 **** + + /* + * Compile a regular expression into internal code. +! * Returns the program in allocated memory. Returns NULL for an error. + */ + regprog_T * + vim_regcomp(expr_arg, re_flags) +--- 7933,7941 ---- + + /* + * Compile a regular expression into internal code. +! * Returns the program in allocated memory. +! * Use vim_regfree() to free the memory. +! * Returns NULL for an error. + */ + regprog_T * + vim_regcomp(expr_arg, re_flags) +*************** +*** 7997,8002 **** +--- 8012,8028 ---- + } + + /* ++ * Free a compiled regexp program, returned by vim_regcomp(). ++ */ ++ void ++ vim_regfree(prog) ++ regprog_T *prog; ++ { ++ if (prog != NULL) ++ prog->engine->regfree(prog); ++ } ++ ++ /* + * Match a regexp against a string. + * "rmp->regprog" is a compiled regexp as returned by vim_regcomp(). + * Uses curbuf for line count and 'iskeyword'. +*** ../vim-7.3.1148/src/regexp.h 2013-06-07 16:31:45.000000000 +0200 +--- src/regexp.h 2013-06-08 15:43:33.000000000 +0200 +*************** +*** 89,94 **** +--- 89,95 ---- + + int reganch; /* pattern starts with ^ */ + int regstart; /* char at start of pattern */ ++ char_u *match_text; /* plain text to match with */ + + int has_zend; /* pattern contains \ze */ + int has_backref; /* pattern contains \1 .. \9 */ +*************** +*** 147,152 **** +--- 148,154 ---- + struct regengine + { + regprog_T *(*regcomp)(char_u*, int); ++ void (*regfree)(regprog_T *); + int (*regexec)(regmatch_T*, char_u*, colnr_T); + #if defined(FEAT_MODIFY_FNAME) || defined(FEAT_EVAL) \ + || defined(FIND_REPLACE_DIALOG) || defined(PROTO) +*** ../vim-7.3.1148/src/regexp_nfa.c 2013-06-08 14:38:23.000000000 +0200 +--- src/regexp_nfa.c 2013-06-08 18:04:40.000000000 +0200 +*************** +*** 270,275 **** +--- 270,276 ---- + static int nfa_regcomp_start __ARGS((char_u *expr, int re_flags)); + static int nfa_get_reganch __ARGS((nfa_state_T *start, int depth)); + static int nfa_get_regstart __ARGS((nfa_state_T *start, int depth)); ++ static char_u *nfa_get_match_text __ARGS((nfa_state_T *start)); + static int nfa_recognize_char_class __ARGS((char_u *start, char_u *end, int extra_newl)); + static int nfa_emit_equi_class __ARGS((int c)); + static int nfa_regatom __ARGS((void)); +*************** +*** 295,300 **** +--- 296,302 ---- + static long nfa_regtry __ARGS((nfa_regprog_T *prog, colnr_T col)); + static long nfa_regexec_both __ARGS((char_u *line, colnr_T col)); + static regprog_T *nfa_regcomp __ARGS((char_u *expr, int re_flags)); ++ static void nfa_regfree __ARGS((regprog_T *prog)); + static int nfa_regexec __ARGS((regmatch_T *rmp, char_u *line, colnr_T col)); + static long nfa_regexec_multi __ARGS((regmmatch_T *rmp, win_T *win, buf_T *buf, linenr_T lnum, colnr_T col, proftime_T *tm)); + +*************** +*** 493,498 **** +--- 495,546 ---- + } + + /* ++ * Figure out if the NFA state list contains just literal text and nothing ++ * else. If so return a string with what must match after regstart. ++ * Otherwise return NULL. ++ */ ++ static char_u * ++ nfa_get_match_text(start) ++ nfa_state_T *start; ++ { ++ nfa_state_T *p = start; ++ int len = 0; ++ char_u *ret; ++ char_u *s; ++ ++ if (p->c != NFA_MOPEN) ++ return NULL; /* just in case */ ++ p = p->out; ++ while (p->c > 0) ++ { ++ len += MB_CHAR2LEN(p->c); ++ p = p->out; ++ } ++ if (p->c != NFA_MCLOSE || p->out->c != NFA_MATCH) ++ return NULL; ++ ++ ret = alloc(len); ++ if (ret != NULL) ++ { ++ len = 0; ++ p = start->out->out; /* skip first char, it goes into regstart */ ++ s = ret; ++ while (p->c > 0) ++ { ++ #ifdef FEAT_MBYTE ++ if (has_mbyte) ++ s += (*mb_char2bytes)(p->c, s); ++ else ++ #endif ++ *s++ = p->c; ++ p = p->out; ++ } ++ *s = NUL; ++ } ++ return ret; ++ } ++ ++ /* + * Allocate more space for post_start. Called when + * running above the estimated number of states. + */ +*************** +*** 2280,2287 **** + { + nfa_print_state(debugf, prog->start); + +! fprintf(debugf, "reganch: %d\n", prog->reganch); +! fprintf(debugf, "regstart: %d\n", prog->regstart); + + fclose(debugf); + } +--- 2328,2340 ---- + { + nfa_print_state(debugf, prog->start); + +! if (prog->reganch) +! fprintf(debugf, "reganch: %d\n", prog->reganch); +! if (prog->regstart != NUL) +! fprintf(debugf, "regstart: %c (decimal: %d)\n", +! prog->regstart, prog->regstart); +! if (prog->match_text != NULL) +! fprintf(debugf, "match_text: \"%s\"\n", prog->match_text); + + fclose(debugf); + } +*************** +*** 4154,4159 **** +--- 4207,4213 ---- + + static int failure_chance __ARGS((nfa_state_T *state, int depth)); + static int skip_to_start __ARGS((int c, colnr_T *colp)); ++ static long find_match_text __ARGS((colnr_T startcol, int regstart, char_u *match_text)); + + /* + * Estimate the chance of a match with "state" failing. +*************** +*** 4331,4336 **** +--- 4385,4453 ---- + } + + /* ++ * Check for a match with match_text. ++ * Called after skip_to_start() has find regstart. ++ * Returns zero for no match, 1 for a match. ++ */ ++ static long ++ find_match_text(startcol, regstart, match_text) ++ colnr_T startcol; ++ int regstart; ++ char_u *match_text; ++ { ++ colnr_T col = startcol; ++ int c1, c2; ++ int len1, len2; ++ int match; ++ ++ for (;;) ++ { ++ match = TRUE; ++ len2 = MB_CHAR2LEN(regstart); /* skip regstart */ ++ for (len1 = 0; match_text[len1] != NUL; len1 += MB_CHAR2LEN(c1)) ++ { ++ c1 = PTR2CHAR(match_text + len1); ++ c2 = PTR2CHAR(regline + col + len2); ++ if (c1 != c2 && (!ireg_ic || MB_TOLOWER(c1) != MB_TOLOWER(c2))) ++ { ++ match = FALSE; ++ break; ++ } ++ len2 += MB_CHAR2LEN(c2); ++ } ++ if (match ++ #ifdef FEAT_MBYTE ++ /* check that no composing char follows */ ++ && !(enc_utf8 ++ && utf_iscomposing(PTR2CHAR(regline + col + len2))) ++ #endif ++ ) ++ { ++ cleanup_subexpr(); ++ if (REG_MULTI) ++ { ++ reg_startpos[0].lnum = reglnum; ++ reg_startpos[0].col = col; ++ reg_endpos[0].lnum = reglnum; ++ reg_endpos[0].col = col + len2; ++ } ++ else ++ { ++ reg_startp[0] = regline + col; ++ reg_endp[0] = regline + col + len2; ++ } ++ return 1L; ++ } ++ ++ /* Try finding regstart after the current match. */ ++ col += MB_CHAR2LEN(regstart); /* skip regstart */ ++ if (skip_to_start(regstart, &col) == FAIL) ++ break; ++ } ++ return 0L; ++ } ++ ++ /* + * Main matching routine. + * + * Run NFA to determine whether it matches reginput. +*************** +*** 5584,5600 **** + #endif + + reginput = regline + col; +- need_clear_subexpr = TRUE; +- #ifdef FEAT_SYN_HL +- /* Clear the external match subpointers if necessary. */ +- if (prog->reghasz == REX_SET) +- { +- nfa_has_zsubexpr = TRUE; +- need_clear_zsubexpr = TRUE; +- } +- else +- nfa_has_zsubexpr = FALSE; +- #endif + + #ifdef ENABLE_LOG + f = fopen(NFA_REGEXP_RUN_LOG, "a"); +--- 5701,5706 ---- +*************** +*** 5764,5775 **** +--- 5870,5900 ---- + if (prog->reganch && col > 0) + return 0L; + ++ need_clear_subexpr = TRUE; ++ #ifdef FEAT_SYN_HL ++ /* Clear the external match subpointers if necessary. */ ++ if (prog->reghasz == REX_SET) ++ { ++ nfa_has_zsubexpr = TRUE; ++ need_clear_zsubexpr = TRUE; ++ } ++ else ++ nfa_has_zsubexpr = FALSE; ++ #endif ++ + if (prog->regstart != NUL) ++ { + /* Skip ahead until a character we know the match must start with. + * When there is none there is no match. */ + if (skip_to_start(prog->regstart, &col) == FAIL) + return 0L; + ++ /* If match_text is set it contains the full text that must match. ++ * Nothing else to try. Doesn't handle combining chars well. */ ++ if (prog->match_text != NULL && !ireg_icombine) ++ return find_match_text(col, prog->regstart, prog->match_text); ++ } ++ + /* If the start column is past the maximum column: no need to try. */ + if (ireg_maxcol > 0 && col >= ireg_maxcol) + goto theend; +*************** +*** 5876,5881 **** +--- 6001,6008 ---- + prog->reganch = nfa_get_reganch(prog->start, 0); + prog->regstart = nfa_get_regstart(prog->start, 0); + ++ prog->match_text = nfa_get_match_text(prog->start); ++ + #ifdef ENABLE_LOG + nfa_postfix_dump(expr, OK); + nfa_dump(prog); +*************** +*** 5885,5891 **** + prog->reghasz = re_has_z; + #endif + #ifdef DEBUG +! prog->pattern = vim_strsave(expr); /* memory will leak */ + nfa_regengine.expr = NULL; + #endif + +--- 6012,6018 ---- + prog->reghasz = re_has_z; + #endif + #ifdef DEBUG +! prog->pattern = vim_strsave(expr); + nfa_regengine.expr = NULL; + #endif + +*************** +*** 5907,5912 **** +--- 6034,6055 ---- + goto out; + } + ++ /* ++ * Free a compiled regexp program, returned by nfa_regcomp(). ++ */ ++ static void ++ nfa_regfree(prog) ++ regprog_T *prog; ++ { ++ if (prog != NULL) ++ { ++ vim_free(((nfa_regprog_T *)prog)->match_text); ++ #ifdef DEBUG ++ vim_free(((nfa_regprog_T *)prog)->pattern); ++ #endif ++ vim_free(prog); ++ } ++ } + + /* + * Match a regexp against a string. +*** ../vim-7.3.1148/src/proto/regexp.pro 2010-08-15 21:57:28.000000000 +0200 +--- src/proto/regexp.pro 2013-06-08 15:41:49.000000000 +0200 +*************** +*** 2,17 **** + int re_multiline __ARGS((regprog_T *prog)); + int re_lookbehind __ARGS((regprog_T *prog)); + char_u *skip_regexp __ARGS((char_u *startp, int dirc, int magic, char_u **newp)); +- regprog_T *vim_regcomp __ARGS((char_u *expr, int re_flags)); + int vim_regcomp_had_eol __ARGS((void)); + void free_regexp_stuff __ARGS((void)); +- int vim_regexec __ARGS((regmatch_T *rmp, char_u *line, colnr_T col)); +- int vim_regexec_nl __ARGS((regmatch_T *rmp, char_u *line, colnr_T col)); +- long vim_regexec_multi __ARGS((regmmatch_T *rmp, win_T *win, buf_T *buf, linenr_T lnum, colnr_T col, proftime_T *tm)); + reg_extmatch_T *ref_extmatch __ARGS((reg_extmatch_T *em)); + void unref_extmatch __ARGS((reg_extmatch_T *em)); + char_u *regtilde __ARGS((char_u *source, int magic)); + int vim_regsub __ARGS((regmatch_T *rmp, char_u *source, char_u *dest, int copy, int magic, int backslash)); + int vim_regsub_multi __ARGS((regmmatch_T *rmp, linenr_T lnum, char_u *source, char_u *dest, int copy, int magic, int backslash)); + char_u *reg_submatch __ARGS((int no)); + /* vim: set ft=c : */ +--- 2,18 ---- + int re_multiline __ARGS((regprog_T *prog)); + int re_lookbehind __ARGS((regprog_T *prog)); + char_u *skip_regexp __ARGS((char_u *startp, int dirc, int magic, char_u **newp)); + int vim_regcomp_had_eol __ARGS((void)); + void free_regexp_stuff __ARGS((void)); + reg_extmatch_T *ref_extmatch __ARGS((reg_extmatch_T *em)); + void unref_extmatch __ARGS((reg_extmatch_T *em)); + char_u *regtilde __ARGS((char_u *source, int magic)); + int vim_regsub __ARGS((regmatch_T *rmp, char_u *source, char_u *dest, int copy, int magic, int backslash)); + int vim_regsub_multi __ARGS((regmmatch_T *rmp, linenr_T lnum, char_u *source, char_u *dest, int copy, int magic, int backslash)); + char_u *reg_submatch __ARGS((int no)); ++ regprog_T *vim_regcomp __ARGS((char_u *expr_arg, int re_flags)); ++ void vim_regfree __ARGS((regprog_T *prog)); ++ int vim_regexec __ARGS((regmatch_T *rmp, char_u *line, colnr_T col)); ++ int vim_regexec_nl __ARGS((regmatch_T *rmp, char_u *line, colnr_T col)); ++ long vim_regexec_multi __ARGS((regmmatch_T *rmp, win_T *win, buf_T *buf, linenr_T lnum, colnr_T col, proftime_T *tm)); + /* vim: set ft=c : */ +*** ../vim-7.3.1148/src/buffer.c 2013-06-07 20:17:06.000000000 +0200 +--- src/buffer.c 2013-06-08 16:06:38.000000000 +0200 +*************** +*** 1898,1904 **** + #ifdef FEAT_SPELL + clear_string_option(&buf->b_s.b_p_spc); + clear_string_option(&buf->b_s.b_p_spf); +! vim_free(buf->b_s.b_cap_prog); + buf->b_s.b_cap_prog = NULL; + clear_string_option(&buf->b_s.b_p_spl); + #endif +--- 1898,1904 ---- + #ifdef FEAT_SPELL + clear_string_option(&buf->b_s.b_p_spc); + clear_string_option(&buf->b_s.b_p_spf); +! vim_regfree(buf->b_s.b_cap_prog); + buf->b_s.b_cap_prog = NULL; + clear_string_option(&buf->b_s.b_p_spl); + #endif +*************** +*** 2246,2252 **** + match = buf->b_fnum; /* remember first match */ + } + +! vim_free(prog); + if (match >= 0) /* found one match */ + break; + } +--- 2246,2252 ---- + match = buf->b_fnum; /* remember first match */ + } + +! vim_regfree(prog); + if (match >= 0) /* found one match */ + break; + } +*************** +*** 2355,2368 **** + *file = (char_u **)alloc((unsigned)(count * sizeof(char_u *))); + if (*file == NULL) + { +! vim_free(prog); + if (patc != pat) + vim_free(patc); + return FAIL; + } + } + } +! vim_free(prog); + if (count) /* match(es) found, break here */ + break; + } +--- 2355,2368 ---- + *file = (char_u **)alloc((unsigned)(count * sizeof(char_u *))); + if (*file == NULL) + { +! vim_regfree(prog); + if (patc != pat) + vim_free(patc); + return FAIL; + } + } + } +! vim_regfree(prog); + if (count) /* match(es) found, break here */ + break; + } +*** ../vim-7.3.1148/src/edit.c 2013-05-19 21:15:08.000000000 +0200 +--- src/edit.c 2013-06-08 15:46:43.000000000 +0200 +*************** +*** 3134,3140 **** + + theend: + p_scs = save_p_scs; +! vim_free(regmatch.regprog); + vim_free(buf); + } + +--- 3134,3140 ---- + + theend: + p_scs = save_p_scs; +! vim_regfree(regmatch.regprog); + vim_free(buf); + } + +*** ../vim-7.3.1148/src/eval.c 2013-06-06 21:31:02.000000000 +0200 +--- src/eval.c 2013-06-08 15:48:23.000000000 +0200 +*************** +*** 4560,4566 **** + if (regmatch.regprog != NULL) + { + n1 = vim_regexec_nl(®match, s1, (colnr_T)0); +! vim_free(regmatch.regprog); + if (type == TYPE_NOMATCH) + n1 = !n1; + } +--- 4560,4566 ---- + if (regmatch.regprog != NULL) + { + n1 = vim_regexec_nl(®match, s1, (colnr_T)0); +! vim_regfree(regmatch.regprog); + if (type == TYPE_NOMATCH) + n1 = !n1; + } +*************** +*** 13981,13987 **** + rettv->vval.v_number += (varnumber_T)(str - expr); + } + } +! vim_free(regmatch.regprog); + } + + theend: +--- 13981,13987 ---- + rettv->vval.v_number += (varnumber_T)(str - expr); + } + } +! vim_regfree(regmatch.regprog); + } + + theend: +*************** +*** 17214,17220 **** + str = regmatch.endp[0]; + } + +! vim_free(regmatch.regprog); + } + + p_cpo = save_cpo; +--- 17214,17220 ---- + str = regmatch.endp[0]; + } + +! vim_regfree(regmatch.regprog); + } + + p_cpo = save_cpo; +*************** +*** 21066,21072 **** + list_func_head(fp, FALSE); + } + } +! vim_free(regmatch.regprog); + } + } + if (*p == '/') +--- 21066,21072 ---- + list_func_head(fp, FALSE); + } + } +! vim_regfree(regmatch.regprog); + } + } + if (*p == '/') +*************** +*** 24220,24226 **** + if (ga.ga_data != NULL) + STRCPY((char *)ga.ga_data + ga.ga_len, tail); + +! vim_free(regmatch.regprog); + } + + ret = vim_strsave(ga.ga_data == NULL ? str : (char_u *)ga.ga_data); +--- 24220,24226 ---- + if (ga.ga_data != NULL) + STRCPY((char *)ga.ga_data + ga.ga_len, tail); + +! vim_regfree(regmatch.regprog); + } + + ret = vim_strsave(ga.ga_data == NULL ? str : (char_u *)ga.ga_data); +*** ../vim-7.3.1148/src/ex_cmds.c 2013-05-30 11:43:11.000000000 +0200 +--- src/ex_cmds.c 2013-06-08 16:07:02.000000000 +0200 +*************** +*** 571,577 **** + vim_free(nrs); + vim_free(sortbuf1); + vim_free(sortbuf2); +! vim_free(regmatch.regprog); + if (got_int) + EMSG(_(e_interr)); + } +--- 571,577 ---- + vim_free(nrs); + vim_free(sortbuf1); + vim_free(sortbuf2); +! vim_regfree(regmatch.regprog); + if (got_int) + EMSG(_(e_interr)); + } +*************** +*** 5261,5267 **** + changed_window_setting(); + #endif + +! vim_free(regmatch.regprog); + } + + /* +--- 5261,5267 ---- + changed_window_setting(); + #endif + +! vim_regfree(regmatch.regprog); + } + + /* +*************** +*** 5436,5442 **** + global_exe(cmd); + + ml_clearmarked(); /* clear rest of the marks */ +! vim_free(regmatch.regprog); + } + + /* +--- 5436,5442 ---- + global_exe(cmd); + + ml_clearmarked(); /* clear rest of the marks */ +! vim_regfree(regmatch.regprog); + } + + /* +*** ../vim-7.3.1148/src/ex_cmds2.c 2013-06-06 14:01:35.000000000 +0200 +--- src/ex_cmds2.c 2013-06-08 15:49:57.000000000 +0200 +*************** +*** 652,658 **** + while (gap->ga_len > 0) + { + vim_free(DEBUGGY(gap, todel).dbg_name); +! vim_free(DEBUGGY(gap, todel).dbg_prog); + --gap->ga_len; + if (todel < gap->ga_len) + mch_memmove(&DEBUGGY(gap, todel), &DEBUGGY(gap, todel + 1), +--- 652,658 ---- + while (gap->ga_len > 0) + { + vim_free(DEBUGGY(gap, todel).dbg_name); +! vim_regfree(DEBUGGY(gap, todel).dbg_prog); + --gap->ga_len; + if (todel < gap->ga_len) + mch_memmove(&DEBUGGY(gap, todel), &DEBUGGY(gap, todel + 1), +*************** +*** 1985,1991 **** + --match; + } + +! vim_free(regmatch.regprog); + vim_free(p); + if (!didone) + EMSG2(_(e_nomatch2), ((char_u **)new_ga.ga_data)[i]); +--- 1985,1991 ---- + --match; + } + +! vim_regfree(regmatch.regprog); + vim_free(p); + if (!didone) + EMSG2(_(e_nomatch2), ((char_u **)new_ga.ga_data)[i]); +*** ../vim-7.3.1148/src/ex_docmd.c 2013-06-08 15:24:41.000000000 +0200 +--- src/ex_docmd.c 2013-06-08 15:50:07.000000000 +0200 +*************** +*** 7779,7785 **** + curwin->w_cursor.col = (colnr_T)(regmatch.startp[0] - p); + else + EMSG(_(e_nomatch)); +! vim_free(regmatch.regprog); + } + /* Move to the NUL, ignore any other arguments. */ + eap->arg += STRLEN(eap->arg); +--- 7779,7785 ---- + curwin->w_cursor.col = (colnr_T)(regmatch.startp[0] - p); + else + EMSG(_(e_nomatch)); +! vim_regfree(regmatch.regprog); + } + /* Move to the NUL, ignore any other arguments. */ + eap->arg += STRLEN(eap->arg); +*** ../vim-7.3.1148/src/ex_eval.c 2013-05-06 04:21:35.000000000 +0200 +--- src/ex_eval.c 2013-06-08 15:50:28.000000000 +0200 +*************** +*** 1576,1582 **** + caught = vim_regexec_nl(®match, current_exception->value, + (colnr_T)0); + got_int |= prev_got_int; +! vim_free(regmatch.regprog); + } + } + } +--- 1576,1582 ---- + caught = vim_regexec_nl(®match, current_exception->value, + (colnr_T)0); + got_int |= prev_got_int; +! vim_regfree(regmatch.regprog); + } + } + } +*** ../vim-7.3.1148/src/ex_getln.c 2013-06-08 15:24:41.000000000 +0200 +--- src/ex_getln.c 2013-06-08 15:51:13.000000000 +0200 +*************** +*** 4717,4723 **** + } + } + +! vim_free(regmatch.regprog); + + return ret; + #endif /* FEAT_CMDL_COMPL */ +--- 4717,4723 ---- + } + } + +! vim_regfree(regmatch.regprog); + + return ret; + #endif /* FEAT_CMDL_COMPL */ +*************** +*** 5785,5791 **** + if (history[histype][idx].hisstr == NULL) + hisidx[histype] = -1; + } +! vim_free(regmatch.regprog); + return found; + } + +--- 5785,5791 ---- + if (history[histype][idx].hisstr == NULL) + hisidx[histype] = -1; + } +! vim_regfree(regmatch.regprog); + return found; + } + +*** ../vim-7.3.1148/src/fileio.c 2013-05-06 04:50:26.000000000 +0200 +--- src/fileio.c 2013-06-08 15:52:10.000000000 +0200 +*************** +*** 7921,7927 **** + if (ap->pat == NULL) + { + *prev_ap = ap->next; +! vim_free(ap->reg_prog); + vim_free(ap); + } + else +--- 7921,7927 ---- + if (ap->pat == NULL) + { + *prev_ap = ap->next; +! vim_regfree(ap->reg_prog); + vim_free(ap); + } + else +*************** +*** 10070,10076 **** + result = TRUE; + + if (prog == NULL) +! vim_free(regmatch.regprog); + return result; + } + #endif +--- 10070,10076 ---- + result = TRUE; + + if (prog == NULL) +! vim_regfree(regmatch.regprog); + return result; + } + #endif +*** ../vim-7.3.1148/src/gui.c 2013-05-06 04:21:35.000000000 +0200 +--- src/gui.c 2013-06-08 15:52:24.000000000 +0200 +*************** +*** 5319,5325 **** + } + else + MSG(_("No match at cursor, finding next")); +! vim_free(regmatch.regprog); + } + } + +--- 5319,5325 ---- + } + else + MSG(_("No match at cursor, finding next")); +! vim_regfree(regmatch.regprog); + } + } + +*** ../vim-7.3.1148/src/misc1.c 2013-06-05 19:35:31.000000000 +0200 +--- src/misc1.c 2013-06-08 15:53:36.000000000 +0200 +*************** +*** 456,463 **** + pos.coladd = 0; + #endif + } + } +- vim_free(regmatch.regprog); + + if (pos.lnum == 0 || *ml_get_pos(&pos) == NUL) + return -1; +--- 456,463 ---- + pos.coladd = 0; + #endif + } ++ vim_regfree(regmatch.regprog); + } + + if (pos.lnum == 0 || *ml_get_pos(&pos) == NUL) + return -1; +*************** +*** 9751,9757 **** + # endif + #endif + vim_free(buf); +! vim_free(regmatch.regprog); + vim_free(matchname); + + matches = gap->ga_len - start_len; +--- 9751,9757 ---- + # endif + #endif + vim_free(buf); +! vim_regfree(regmatch.regprog); + vim_free(matchname); + + matches = gap->ga_len - start_len; +*************** +*** 9993,9999 **** + } + + vim_free(buf); +! vim_free(regmatch.regprog); + + matches = gap->ga_len - start_len; + if (matches > 0) +--- 9993,9999 ---- + } + + vim_free(buf); +! vim_regfree(regmatch.regprog); + + matches = gap->ga_len - start_len; + if (matches > 0) +*************** +*** 10358,10364 **** + vim_free(in_curdir); + } + ga_clear_strings(&path_ga); +! vim_free(regmatch.regprog); + + if (sort_again) + remove_duplicates(gap); +--- 10358,10364 ---- + vim_free(in_curdir); + } + ga_clear_strings(&path_ga); +! vim_regfree(regmatch.regprog); + + if (sort_again) + remove_duplicates(gap); +*** ../vim-7.3.1148/src/misc2.c 2013-05-06 04:21:35.000000000 +0200 +--- src/misc2.c 2013-06-08 16:07:33.000000000 +0200 +*************** +*** 1134,1140 **** + /* Free some global vars. */ + vim_free(username); + # ifdef FEAT_CLIPBOARD +! vim_free(clip_exclude_prog); + # endif + vim_free(last_cmdline); + # ifdef FEAT_CMDHIST +--- 1134,1140 ---- + /* Free some global vars. */ + vim_free(username); + # ifdef FEAT_CLIPBOARD +! vim_regfree(clip_exclude_prog); + # endif + vim_free(last_cmdline); + # ifdef FEAT_CMDHIST +*************** +*** 5008,5015 **** + #endif + { + /* +! * we don't have further wildcards to expand, so we have to +! * check for the final file now + */ + for (i = stackp->ffs_filearray_cur; + i < stackp->ffs_filearray_size; ++i) +--- 5008,5015 ---- + #endif + { + /* +! * We don't have further wildcards to expand, so we have to +! * check for the final file now. + */ + for (i = stackp->ffs_filearray_cur; + i < stackp->ffs_filearray_size; ++i) +*** ../vim-7.3.1148/src/option.c 2013-06-04 22:13:45.000000000 +0200 +--- src/option.c 2013-06-08 16:30:58.000000000 +0200 +*************** +*** 7491,7497 **** + clip_autoselect_plus = new_autoselect_plus; + clip_autoselectml = new_autoselectml; + clip_html = new_html; +! vim_free(clip_exclude_prog); + clip_exclude_prog = new_exclude_prog; + #ifdef FEAT_GUI_GTK + if (gui.in_use) +--- 7491,7497 ---- + clip_autoselect_plus = new_autoselect_plus; + clip_autoselectml = new_autoselectml; + clip_html = new_html; +! vim_regfree(clip_exclude_prog); + clip_exclude_prog = new_exclude_prog; + #ifdef FEAT_GUI_GTK + if (gui.in_use) +*************** +*** 7502,7508 **** + #endif + } + else +! vim_free(new_exclude_prog); + + return errmsg; + } +--- 7502,7508 ---- + #endif + } + else +! vim_regfree(new_exclude_prog); + + return errmsg; + } +*************** +*** 7529,7544 **** + if (re != NULL) + { + synblock->b_cap_prog = vim_regcomp(re, RE_MAGIC); + if (synblock->b_cap_prog == NULL) + { + synblock->b_cap_prog = rp; /* restore the previous program */ + return e_invarg; + } +- vim_free(re); + } + } + +! vim_free(rp); + return NULL; + } + #endif +--- 7529,7544 ---- + if (re != NULL) + { + synblock->b_cap_prog = vim_regcomp(re, RE_MAGIC); ++ vim_free(re); + if (synblock->b_cap_prog == NULL) + { + synblock->b_cap_prog = rp; /* restore the previous program */ + return e_invarg; + } + } + } + +! vim_regfree(rp); + return NULL; + } + #endif +*** ../vim-7.3.1148/src/syntax.c 2013-06-08 15:24:41.000000000 +0200 +--- src/syntax.c 2013-06-08 16:10:08.000000000 +0200 +*************** +*** 3495,3501 **** + block->b_syn_sync_maxlines = 0; + block->b_syn_sync_linebreaks = 0; + +! vim_free(block->b_syn_linecont_prog); + block->b_syn_linecont_prog = NULL; + vim_free(block->b_syn_linecont_pat); + block->b_syn_linecont_pat = NULL; +--- 3495,3501 ---- + block->b_syn_sync_maxlines = 0; + block->b_syn_sync_linebreaks = 0; + +! vim_regfree(block->b_syn_linecont_prog); + block->b_syn_linecont_prog = NULL; + vim_free(block->b_syn_linecont_pat); + block->b_syn_linecont_pat = NULL; +*************** +*** 3544,3550 **** + curwin->w_s->b_syn_sync_maxlines = 0; + curwin->w_s->b_syn_sync_linebreaks = 0; + +! vim_free(curwin->w_s->b_syn_linecont_prog); + curwin->w_s->b_syn_linecont_prog = NULL; + vim_free(curwin->w_s->b_syn_linecont_pat); + curwin->w_s->b_syn_linecont_pat = NULL; +--- 3544,3550 ---- + curwin->w_s->b_syn_sync_maxlines = 0; + curwin->w_s->b_syn_sync_linebreaks = 0; + +! vim_regfree(curwin->w_s->b_syn_linecont_prog); + curwin->w_s->b_syn_linecont_prog = NULL; + vim_free(curwin->w_s->b_syn_linecont_pat); + curwin->w_s->b_syn_linecont_pat = NULL; +*************** +*** 3583,3589 **** + int i; + { + vim_free(SYN_ITEMS(block)[i].sp_pattern); +! vim_free(SYN_ITEMS(block)[i].sp_prog); + /* Only free sp_cont_list and sp_next_list of first start pattern */ + if (i == 0 || SYN_ITEMS(block)[i - 1].sp_type != SPTYPE_START) + { +--- 3583,3589 ---- + int i; + { + vim_free(SYN_ITEMS(block)[i].sp_pattern); +! vim_regfree(SYN_ITEMS(block)[i].sp_prog); + /* Only free sp_cont_list and sp_next_list of first start pattern */ + if (i == 0 || SYN_ITEMS(block)[i - 1].sp_type != SPTYPE_START) + { +*************** +*** 4991,4997 **** + /* + * Something failed, free the allocated memory. + */ +! vim_free(item.sp_prog); + vim_free(item.sp_pattern); + vim_free(syn_opt_arg.cont_list); + vim_free(syn_opt_arg.cont_in_list); +--- 4991,4997 ---- + /* + * Something failed, free the allocated memory. + */ +! vim_regfree(item.sp_prog); + vim_free(item.sp_pattern); + vim_free(syn_opt_arg.cont_list); + vim_free(syn_opt_arg.cont_in_list); +*************** +*** 5248,5254 **** + { + if (!success) + { +! vim_free(ppp->pp_synp->sp_prog); + vim_free(ppp->pp_synp->sp_pattern); + } + vim_free(ppp->pp_synp); +--- 5248,5254 ---- + { + if (!success) + { +! vim_regfree(ppp->pp_synp->sp_prog); + vim_free(ppp->pp_synp->sp_pattern); + } + vim_free(ppp->pp_synp); +*************** +*** 6022,6028 **** + id = -1; /* remember that we found one */ + } + } +! vim_free(regmatch.regprog); + } + } + vim_free(name); +--- 6022,6028 ---- + id = -1; /* remember that we found one */ + } + } +! vim_regfree(regmatch.regprog); + } + } + vim_free(name); +*************** +*** 6295,6301 **** + curwin->w_p_spell = FALSE; /* No spell checking */ + clear_string_option(&curwin->w_s->b_p_spc); + clear_string_option(&curwin->w_s->b_p_spf); +! vim_free(curwin->w_s->b_cap_prog); + curwin->w_s->b_cap_prog = NULL; + clear_string_option(&curwin->w_s->b_p_spl); + #endif +--- 6295,6301 ---- + curwin->w_p_spell = FALSE; /* No spell checking */ + clear_string_option(&curwin->w_s->b_p_spc); + clear_string_option(&curwin->w_s->b_p_spf); +! vim_regfree(curwin->w_s->b_cap_prog); + curwin->w_s->b_cap_prog = NULL; + clear_string_option(&curwin->w_s->b_p_spl); + #endif +*** ../vim-7.3.1148/src/quickfix.c 2013-05-11 15:50:02.000000000 +0200 +--- src/quickfix.c 2013-06-08 15:57:08.000000000 +0200 +*************** +*** 863,869 **** + for (fmt_ptr = fmt_first; fmt_ptr != NULL; fmt_ptr = fmt_first) + { + fmt_first = fmt_ptr->next; +! vim_free(fmt_ptr->prog); + vim_free(fmt_ptr); + } + qf_clean_dir_stack(&dir_stack); +--- 863,869 ---- + for (fmt_ptr = fmt_first; fmt_ptr != NULL; fmt_ptr = fmt_first) + { + fmt_first = fmt_ptr->next; +! vim_regfree(fmt_ptr->prog); + vim_free(fmt_ptr); + } + qf_clean_dir_stack(&dir_stack); +*************** +*** 3487,3493 **** + vim_free(dirname_now); + vim_free(dirname_start); + vim_free(target_dir); +! vim_free(regmatch.regprog); + } + + /* +--- 3487,3493 ---- + vim_free(dirname_now); + vim_free(dirname_start); + vim_free(target_dir); +! vim_regfree(regmatch.regprog); + } + + /* +*************** +*** 4178,4184 **** + } + } + +! vim_free(regmatch.regprog); + #ifdef FEAT_MBYTE + if (vc.vc_type != CONV_NONE) + convert_setup(&vc, NULL, NULL); +--- 4178,4184 ---- + } + } + +! vim_regfree(regmatch.regprog); + #ifdef FEAT_MBYTE + if (vc.vc_type != CONV_NONE) + convert_setup(&vc, NULL, NULL); +*** ../vim-7.3.1148/src/search.c 2013-05-06 04:21:35.000000000 +0200 +--- src/search.c 2013-06-08 15:59:38.000000000 +0200 +*************** +*** 972,978 **** + } + while (--count > 0 && found); /* stop after count matches or no match */ + +! vim_free(regmatch.regprog); + + called_emsg |= save_called_emsg; + +--- 972,978 ---- + } + while (--count > 0 && found); /* stop after count matches or no match */ + +! vim_regfree(regmatch.regprog); + + called_emsg |= save_called_emsg; + +*************** +*** 4680,4686 **** + } + + called_emsg |= save_called_emsg; +! vim_free(regmatch.regprog); + return result; + } + #endif /* FEAT_VISUAL */ +--- 4680,4686 ---- + } + + called_emsg |= save_called_emsg; +! vim_regfree(regmatch.regprog); + return result; + } + #endif /* FEAT_VISUAL */ +*************** +*** 5402,5410 **** + + fpip_end: + vim_free(file_line); +! vim_free(regmatch.regprog); +! vim_free(incl_regmatch.regprog); +! vim_free(def_regmatch.regprog); + } + + static void +--- 5402,5410 ---- + + fpip_end: + vim_free(file_line); +! vim_regfree(regmatch.regprog); +! vim_regfree(incl_regmatch.regprog); +! vim_regfree(def_regmatch.regprog); + } + + static void +*** ../vim-7.3.1148/src/spell.c 2013-05-06 04:21:35.000000000 +0200 +--- src/spell.c 2013-06-08 16:10:52.000000000 +0200 +*************** +*** 2658,2664 **** + ga_clear(gap); + + for (i = 0; i < lp->sl_prefixcnt; ++i) +! vim_free(lp->sl_prefprog[i]); + lp->sl_prefixcnt = 0; + vim_free(lp->sl_prefprog); + lp->sl_prefprog = NULL; +--- 2658,2664 ---- + ga_clear(gap); + + for (i = 0; i < lp->sl_prefixcnt; ++i) +! vim_regfree(lp->sl_prefprog[i]); + lp->sl_prefixcnt = 0; + vim_free(lp->sl_prefprog); + lp->sl_prefprog = NULL; +*************** +*** 2669,2675 **** + vim_free(lp->sl_midword); + lp->sl_midword = NULL; + +! vim_free(lp->sl_compprog); + vim_free(lp->sl_comprules); + vim_free(lp->sl_compstartflags); + vim_free(lp->sl_compallflags); +--- 2669,2675 ---- + vim_free(lp->sl_midword); + lp->sl_midword = NULL; + +! vim_regfree(lp->sl_compprog); + vim_free(lp->sl_comprules); + vim_free(lp->sl_compstartflags); + vim_free(lp->sl_compallflags); +*************** +*** 5802,5808 **** + { + sprintf((char *)buf, "^%s", + aff_entry->ae_cond); +! vim_free(aff_entry->ae_prog); + aff_entry->ae_prog = vim_regcomp( + buf, RE_MAGIC + RE_STRING); + } +--- 5802,5808 ---- + { + sprintf((char *)buf, "^%s", + aff_entry->ae_cond); +! vim_regfree(aff_entry->ae_prog); + aff_entry->ae_prog = vim_regcomp( + buf, RE_MAGIC + RE_STRING); + } +*************** +*** 6507,6513 **** + --todo; + ah = HI2AH(hi); + for (ae = ah->ah_first; ae != NULL; ae = ae->ae_next) +! vim_free(ae->ae_prog); + } + } + if (ht == &aff->af_suff) +--- 6507,6513 ---- + --todo; + ah = HI2AH(hi); + for (ae = ah->ah_first; ae != NULL; ae = ae->ae_next) +! vim_regfree(ae->ae_prog); + } + } + if (ht == &aff->af_suff) +*** ../vim-7.3.1148/src/tag.c 2012-09-12 18:19:39.000000000 +0200 +--- src/tag.c 2013-06-08 16:03:31.000000000 +0200 +*************** +*** 2491,2497 **** + + findtag_end: + vim_free(lbuf); +! vim_free(orgpat.regmatch.regprog); + vim_free(tag_fname); + #ifdef FEAT_EMACS_TAGS + vim_free(ebuf); +--- 2491,2497 ---- + + findtag_end: + vim_free(lbuf); +! vim_regfree(orgpat.regmatch.regprog); + vim_free(tag_fname); + #ifdef FEAT_EMACS_TAGS + vim_free(ebuf); +*** ../vim-7.3.1148/src/window.c 2013-05-18 20:55:31.000000000 +0200 +--- src/window.c 2013-06-08 16:03:54.000000000 +0200 +*************** +*** 6818,6824 **** + wp->w_match_head = cur->next; + else + prev->next = cur->next; +! vim_free(cur->match.regprog); + vim_free(cur->pattern); + vim_free(cur); + redraw_later(SOME_VALID); +--- 6818,6824 ---- + wp->w_match_head = cur->next; + else + prev->next = cur->next; +! vim_regfree(cur->match.regprog); + vim_free(cur->pattern); + vim_free(cur); + redraw_later(SOME_VALID); +*************** +*** 6837,6843 **** + while (wp->w_match_head != NULL) + { + m = wp->w_match_head->next; +! vim_free(wp->w_match_head->match.regprog); + vim_free(wp->w_match_head->pattern); + vim_free(wp->w_match_head); + wp->w_match_head = m; +--- 6837,6843 ---- + while (wp->w_match_head != NULL) + { + m = wp->w_match_head->next; +! vim_regfree(wp->w_match_head->match.regprog); + vim_free(wp->w_match_head->pattern); + vim_free(wp->w_match_head); + wp->w_match_head = m; +*** ../vim-7.3.1148/src/screen.c 2013-06-07 20:17:06.000000000 +0200 +--- src/screen.c 2013-06-08 16:09:18.000000000 +0200 +*************** +*** 7082,7088 **** + { + if (search_hl.rm.regprog != NULL) + { +! vim_free(search_hl.rm.regprog); + search_hl.rm.regprog = NULL; + } + } +--- 7082,7088 ---- + { + if (search_hl.rm.regprog != NULL) + { +! vim_regfree(search_hl.rm.regprog); + search_hl.rm.regprog = NULL; + } + } +*************** +*** 7284,7290 **** + if (shl == &search_hl) + { + /* don't free regprog in the match list, it's a copy */ +! vim_free(shl->rm.regprog); + no_hlsearch = TRUE; + } + shl->rm.regprog = NULL; +--- 7284,7290 ---- + if (shl == &search_hl) + { + /* don't free regprog in the match list, it's a copy */ +! vim_regfree(shl->rm.regprog); + no_hlsearch = TRUE; + } + shl->rm.regprog = NULL; +*** ../vim-7.3.1148/src/macros.h 2012-07-19 17:18:21.000000000 +0200 +--- src/macros.h 2013-06-08 16:53:34.000000000 +0200 +*************** +*** 272,277 **** +--- 272,278 ---- + + # define MB_COPY_CHAR(f, t) if (has_mbyte) mb_copy_char(&f, &t); else *t++ = *f++ + # define MB_CHARLEN(p) (has_mbyte ? mb_charlen(p) : (int)STRLEN(p)) ++ # define MB_CHAR2LEN(c) (has_mbyte ? mb_char2len(c) : 1) + # define PTR2CHAR(p) (has_mbyte ? mb_ptr2char(p) : (int)*(p)) + #else + # define MB_PTR2LEN(p) 1 +*************** +*** 280,285 **** +--- 281,287 ---- + # define mb_ptr_back(s, p) --p + # define MB_COPY_CHAR(f, t) *t++ = *f++ + # define MB_CHARLEN(p) STRLEN(p) ++ # define MB_CHAR2LEN(c) 1 + # define PTR2CHAR(p) ((int)*(p)) + #endif + +*** ../vim-7.3.1148/src/testdir/test64.in 2013-06-05 18:52:36.000000000 +0200 +--- src/testdir/test64.in 2013-06-08 13:05:08.000000000 +0200 +*************** +*** 260,265 **** +--- 260,267 ---- + :call add(tl, [2, '[^[:alpha:]]\+','abcccadfoij7787ysf287yrnccdu','7787']) + :call add(tl, [2, '[-a]', '-', '-']) + :call add(tl, [2, '[a-]', '-', '-']) ++ :call add(tl, [2, '[a-f]*\c','ABCDEFGH','ABCDEF']) ++ :call add(tl, [2, '[abc][xyz]\c','-af-AF-BY--','BY']) + :" filename regexp + :call add(tl, [2, '[-./[:alnum:]_~]\+', 'log13.file', 'log13.file']) + :" special chars +*************** +*** 385,390 **** +--- 387,398 ---- + :call add(tl, [2, '\(<<\)\@2<=span.', 'xxspanxxxx', 'foobar']) ++ :call add(tl, [2, '\(foo\)\@<=\>', 'barfoo', '', 'foo']) ++ :" + :""""" \@> + :call add(tl, [2, '\(a*\)\@>a', 'aaaa']) + :call add(tl, [2, '\(a*\)\@>b', 'aaab', 'aaab', 'aaa']) +*** ../vim-7.3.1148/src/testdir/test64.ok 2013-06-05 18:52:36.000000000 +0200 +--- src/testdir/test64.ok 2013-06-08 13:16:59.000000000 +0200 +*************** +*** 584,589 **** +--- 584,595 ---- + OK 0 - [a-] + OK 1 - [a-] + OK 2 - [a-] ++ OK 0 - [a-f]*\c ++ OK 1 - [a-f]*\c ++ OK 2 - [a-f]*\c ++ OK 0 - [abc][xyz]\c ++ OK 1 - [abc][xyz]\c ++ OK 2 - [abc][xyz]\c + OK 0 - [-./[:alnum:]_~]\+ + OK 1 - [-./[:alnum:]_~]\+ + OK 2 - [-./[:alnum:]_~]\+ +*************** +*** 872,877 **** +--- 878,895 ---- + OK 0 - \(foo\)\@ ++ OK 1 - \(foo\)\@<=\> ++ OK 2 - \(foo\)\@<=\> ++ OK 0 - \(foo\)\@<=\> ++ OK 1 - \(foo\)\@<=\> ++ OK 2 - \(foo\)\@<=\> + OK 0 - \(a*\)\@>a + OK 1 - \(a*\)\@>a + OK 2 - \(a*\)\@>a +*** ../vim-7.3.1148/src/version.c 2013-06-08 15:24:41.000000000 +0200 +--- src/version.c 2013-06-08 18:09:41.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1149, + /**/ + +-- +FIXME and XXX are two common keywords used to mark broken or incomplete code +not only since XXX as a sex reference would grab everybody's attention but +simply due to the fact that Vim would highlight these words. + -- Hendrik Scholz + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f5d6454a3cf7e894a7434feb9fbfb823cad0fbdc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:35 +0200 Subject: [PATCH 1042/3340] - patchlevel 1150 --- 7.3.1150 | 409 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 409 insertions(+) create mode 100644 7.3.1150 diff --git a/7.3.1150 b/7.3.1150 new file mode 100644 index 00000000..210b083b --- /dev/null +++ b/7.3.1150 @@ -0,0 +1,409 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1150 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1150 +Problem: New regexpengine: Slow when a look-behind match does not have a + width specified. +Solution: Try to compute the maximum width. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1149/src/regexp_nfa.c 2013-06-08 18:19:39.000000000 +0200 +--- src/regexp_nfa.c 2013-06-08 22:29:25.000000000 +0200 +*************** +*** 38,56 **** + NFA_START_COLL, /* [abc] start */ + NFA_END_COLL, /* [abc] end */ + NFA_START_NEG_COLL, /* [^abc] start */ +! NFA_END_NEG_COLL, /* [^abc] end (only used in postfix) */ +! NFA_RANGE, /* range of the two previous items (only +! * used in postfix) */ + NFA_RANGE_MIN, /* low end of a range */ + NFA_RANGE_MAX, /* high end of a range */ + +! NFA_CONCAT, /* concatenate two previous items (only +! * used in postfix) */ +! NFA_OR, +! NFA_STAR, /* greedy * */ +! NFA_STAR_NONGREEDY, /* non-greedy * */ +! NFA_QUEST, /* greedy \? */ +! NFA_QUEST_NONGREEDY, /* non-greedy \? */ + + NFA_BOL, /* ^ Begin line */ + NFA_EOL, /* $ End line */ +--- 38,56 ---- + NFA_START_COLL, /* [abc] start */ + NFA_END_COLL, /* [abc] end */ + NFA_START_NEG_COLL, /* [^abc] start */ +! NFA_END_NEG_COLL, /* [^abc] end (postfix only) */ +! NFA_RANGE, /* range of the two previous items +! * (postfix only) */ + NFA_RANGE_MIN, /* low end of a range */ + NFA_RANGE_MAX, /* high end of a range */ + +! NFA_CONCAT, /* concatenate two previous items (postfix +! * only) */ +! NFA_OR, /* \| (postfix only) */ +! NFA_STAR, /* greedy * (posfix only) */ +! NFA_STAR_NONGREEDY, /* non-greedy * (postfix only) */ +! NFA_QUEST, /* greedy \? (postfix only) */ +! NFA_QUEST_NONGREEDY, /* non-greedy \? (postfix only) */ + + NFA_BOL, /* ^ Begin line */ + NFA_EOL, /* $ End line */ +*************** +*** 153,160 **** + + /* NFA_FIRST_NL */ + NFA_ANY, /* Match any one character. */ +- NFA_ANYOF, /* Match any character in this string. */ +- NFA_ANYBUT, /* Match any character not in this string. */ + NFA_IDENT, /* Match identifier char */ + NFA_SIDENT, /* Match identifier char but no digit */ + NFA_KWORD, /* Match keyword char */ +--- 153,158 ---- +*************** +*** 496,503 **** + + /* + * Figure out if the NFA state list contains just literal text and nothing +! * else. If so return a string with what must match after regstart. +! * Otherwise return NULL. + */ + static char_u * + nfa_get_match_text(start) +--- 494,501 ---- + + /* + * Figure out if the NFA state list contains just literal text and nothing +! * else. If so return a string in allocated memory with what must match after +! * regstart. Otherwise return NULL. + */ + static char_u * + nfa_get_match_text(start) +*************** +*** 2578,2583 **** +--- 2576,2800 ---- + } + + /* ++ * Estimate the maximum byte length of anything matching "state". ++ * When unknown or unlimited return -1. ++ */ ++ static int ++ nfa_max_width(startstate, depth) ++ nfa_state_T *startstate; ++ int depth; ++ { ++ int l, r; ++ nfa_state_T *state = startstate; ++ int len = 0; ++ ++ /* detect looping in a NFA_SPLIT */ ++ if (depth > 4) ++ return -1; ++ ++ for (;;) ++ { ++ switch (state->c) ++ { ++ case NFA_END_INVISIBLE: ++ case NFA_END_INVISIBLE_NEG: ++ /* the end, return what we have */ ++ return len; ++ ++ case NFA_SPLIT: ++ /* two alternatives, use the maximum */ ++ l = nfa_max_width(state->out, depth + 1); ++ r = nfa_max_width(state->out1, depth + 1); ++ if (l < 0 || r < 0) ++ return -1; ++ return len + (l > r ? l : r); ++ ++ case NFA_ANY: ++ case NFA_START_COLL: ++ case NFA_START_NEG_COLL: ++ /* matches some character, including composing chars */ ++ #ifdef FEAT_MBYTE ++ if (enc_utf8) ++ len += MB_MAXBYTES; ++ else if (has_mbyte) ++ len += 2; ++ else ++ #endif ++ ++len; ++ if (state->c != NFA_ANY) ++ { ++ /* skip over the characters */ ++ state = state->out1->out; ++ continue; ++ } ++ break; ++ ++ case NFA_DIGIT: ++ case NFA_WHITE: ++ case NFA_HEX: ++ case NFA_OCTAL: ++ /* ascii */ ++ ++len; ++ break; ++ ++ case NFA_IDENT: ++ case NFA_SIDENT: ++ case NFA_KWORD: ++ case NFA_SKWORD: ++ case NFA_FNAME: ++ case NFA_SFNAME: ++ case NFA_PRINT: ++ case NFA_SPRINT: ++ case NFA_NWHITE: ++ case NFA_NDIGIT: ++ case NFA_NHEX: ++ case NFA_NOCTAL: ++ case NFA_WORD: ++ case NFA_NWORD: ++ case NFA_HEAD: ++ case NFA_NHEAD: ++ case NFA_ALPHA: ++ case NFA_NALPHA: ++ case NFA_LOWER: ++ case NFA_NLOWER: ++ case NFA_UPPER: ++ case NFA_NUPPER: ++ /* possibly non-ascii */ ++ #ifdef FEAT_MBYTE ++ if (has_mbyte) ++ len += 3; ++ else ++ #endif ++ ++len; ++ break; ++ ++ case NFA_START_INVISIBLE: ++ case NFA_START_INVISIBLE_NEG: ++ case NFA_START_INVISIBLE_BEFORE: ++ case NFA_START_INVISIBLE_BEFORE_NEG: ++ /* zero-width, out1 points to the END state */ ++ state = state->out1->out; ++ continue; ++ ++ case NFA_BACKREF1: ++ case NFA_BACKREF2: ++ case NFA_BACKREF3: ++ case NFA_BACKREF4: ++ case NFA_BACKREF5: ++ case NFA_BACKREF6: ++ case NFA_BACKREF7: ++ case NFA_BACKREF8: ++ case NFA_BACKREF9: ++ #ifdef FEAT_SYN_HL ++ case NFA_ZREF1: ++ case NFA_ZREF2: ++ case NFA_ZREF3: ++ case NFA_ZREF4: ++ case NFA_ZREF5: ++ case NFA_ZREF6: ++ case NFA_ZREF7: ++ case NFA_ZREF8: ++ case NFA_ZREF9: ++ #endif ++ case NFA_NEWL: ++ case NFA_SKIP: ++ /* unknown width */ ++ return -1; ++ ++ case NFA_BOL: ++ case NFA_EOL: ++ case NFA_BOF: ++ case NFA_EOF: ++ case NFA_BOW: ++ case NFA_EOW: ++ case NFA_MOPEN: ++ case NFA_MOPEN1: ++ case NFA_MOPEN2: ++ case NFA_MOPEN3: ++ case NFA_MOPEN4: ++ case NFA_MOPEN5: ++ case NFA_MOPEN6: ++ case NFA_MOPEN7: ++ case NFA_MOPEN8: ++ case NFA_MOPEN9: ++ #ifdef FEAT_SYN_HL ++ case NFA_ZOPEN: ++ case NFA_ZOPEN1: ++ case NFA_ZOPEN2: ++ case NFA_ZOPEN3: ++ case NFA_ZOPEN4: ++ case NFA_ZOPEN5: ++ case NFA_ZOPEN6: ++ case NFA_ZOPEN7: ++ case NFA_ZOPEN8: ++ case NFA_ZOPEN9: ++ case NFA_ZCLOSE: ++ case NFA_ZCLOSE1: ++ case NFA_ZCLOSE2: ++ case NFA_ZCLOSE3: ++ case NFA_ZCLOSE4: ++ case NFA_ZCLOSE5: ++ case NFA_ZCLOSE6: ++ case NFA_ZCLOSE7: ++ case NFA_ZCLOSE8: ++ case NFA_ZCLOSE9: ++ #endif ++ case NFA_MCLOSE: ++ case NFA_MCLOSE1: ++ case NFA_MCLOSE2: ++ case NFA_MCLOSE3: ++ case NFA_MCLOSE4: ++ case NFA_MCLOSE5: ++ case NFA_MCLOSE6: ++ case NFA_MCLOSE7: ++ case NFA_MCLOSE8: ++ case NFA_MCLOSE9: ++ case NFA_NOPEN: ++ case NFA_NCLOSE: ++ ++ case NFA_LNUM_GT: ++ case NFA_LNUM_LT: ++ case NFA_COL_GT: ++ case NFA_COL_LT: ++ case NFA_VCOL_GT: ++ case NFA_VCOL_LT: ++ case NFA_MARK_GT: ++ case NFA_MARK_LT: ++ case NFA_VISUAL: ++ case NFA_LNUM: ++ case NFA_CURSOR: ++ case NFA_COL: ++ case NFA_VCOL: ++ case NFA_MARK: ++ ++ case NFA_ZSTART: ++ case NFA_ZEND: ++ case NFA_OPT_CHARS: ++ case NFA_SKIP_CHAR: ++ case NFA_START_PATTERN: ++ case NFA_END_PATTERN: ++ case NFA_COMPOSING: ++ case NFA_END_COMPOSING: ++ /* zero-width */ ++ break; ++ ++ default: ++ if (state->c < 0) ++ /* don't know what this is */ ++ return -1; ++ /* normal character */ ++ len += MB_CHAR2LEN(state->c); ++ break; ++ } ++ ++ /* normal way to continue */ ++ state = state->out; ++ } ++ ++ /* unrecognized */ ++ return -1; ++ } ++ /* + * Convert a postfix form into its equivalent NFA. + * Return the NFA start state on success, NULL otherwise. + */ +*************** +*** 2856,2863 **** + s = alloc_state(start_state, e.start, s1); + if (s == NULL) + goto theend; +- if (before) +- s->val = n; /* store the count */ + if (pattern) + { + /* NFA_ZEND -> NFA_END_PATTERN -> NFA_SKIP -> what follows. */ +--- 3073,3078 ---- +*************** +*** 2871,2876 **** +--- 3086,3099 ---- + { + patch(e.out, s1); + PUSH(frag(s, list1(&s1->out))); ++ if (before) ++ { ++ if (n <= 0) ++ /* See if we can guess the maximum width, it avoids a ++ * lot of pointless tries. */ ++ n = nfa_max_width(e.start, 0); ++ s->val = n; /* store the count */ ++ } + } + break; + } +*************** +*** 4088,4096 **** + + /* Go back the specified number of bytes, or as far as the + * start of the previous line, to try matching "\@<=" or +! * not matching "\@val <= 0) + { + if (REG_MULTI) +--- 4311,4318 ---- + + /* Go back the specified number of bytes, or as far as the + * start of the previous line, to try matching "\@<=" or +! * not matching "\@val <= 0) + { + if (REG_MULTI) +*************** +*** 4386,4392 **** + + /* + * Check for a match with match_text. +! * Called after skip_to_start() has find regstart. + * Returns zero for no match, 1 for a match. + */ + static long +--- 4608,4614 ---- + + /* + * Check for a match with match_text. +! * Called after skip_to_start() has found regstart. + * Returns zero for no match, 1 for a match. + */ + static long +*************** +*** 4736,4742 **** + #ifdef FEAT_SYN_HL + || (cout >= NFA_ZCLOSE && cout <= NFA_ZCLOSE9) + #endif +- || cout == NFA_NCLOSE + || t->pim != NULL + || (t->state->c != NFA_START_INVISIBLE_BEFORE + && t->state->c != NFA_START_INVISIBLE_BEFORE_NEG +--- 4958,4963 ---- +*** ../vim-7.3.1149/src/version.c 2013-06-08 18:19:40.000000000 +0200 +--- src/version.c 2013-06-08 22:15:27.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1150, + /**/ + +-- +Amnesia is one of my favorite words, but I forgot what it means. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ba1cca9c8e0a3a975976ee114d22c32821a5a68a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:36 +0200 Subject: [PATCH 1043/3340] - patchlevel 1151 --- 7.3.1151 | 187 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 187 insertions(+) create mode 100644 7.3.1151 diff --git a/7.3.1151 b/7.3.1151 new file mode 100644 index 00000000..14298c7e --- /dev/null +++ b/7.3.1151 @@ -0,0 +1,187 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1151 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1151 +Problem: New regexp engine: Slow when a look-behind match is followed by a + zero-width match. +Solution: Postpone the look-behind match more often. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1150/src/regexp_nfa.c 2013-06-08 22:29:59.000000000 +0200 +--- src/regexp_nfa.c 2013-06-08 23:11:19.000000000 +0200 +*************** +*** 2794,2799 **** +--- 2794,2800 ---- + /* unrecognized */ + return -1; + } ++ + /* + * Convert a postfix form into its equivalent NFA. + * Return the NFA start state on success, NULL otherwise. +*************** +*** 3433,3438 **** +--- 3434,3440 ---- + static void copy_sub_off __ARGS((regsub_T *to, regsub_T *from)); + static int sub_equal __ARGS((regsub_T *sub1, regsub_T *sub2)); + static int has_state_with_pos __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs)); ++ static int match_follows __ARGS((nfa_state_T *startstate, int depth)); + static int state_in_list __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs)); + static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, int off)); + static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, nfa_pim_T *pim, int *ip)); +*************** +*** 3626,3631 **** +--- 3628,3715 ---- + } + + /* ++ * Return TRUE if "state" leads to a NFA_MATCH without advancing the input. ++ */ ++ static int ++ match_follows(startstate, depth) ++ nfa_state_T *startstate; ++ int depth; ++ { ++ nfa_state_T *state = startstate; ++ ++ /* avoid too much recursion */ ++ if (depth > 10) ++ return FALSE; ++ ++ for (;;) ++ { ++ switch (state->c) ++ { ++ case NFA_MATCH: ++ return TRUE; ++ ++ case NFA_SPLIT: ++ return match_follows(state->out, depth + 1) ++ || match_follows(state->out1, depth + 1); ++ ++ case NFA_START_INVISIBLE: ++ case NFA_START_INVISIBLE_BEFORE: ++ case NFA_START_INVISIBLE_NEG: ++ case NFA_START_INVISIBLE_BEFORE_NEG: ++ case NFA_COMPOSING: ++ /* skip ahead to next state */ ++ state = state->out1->out; ++ break; ++ ++ case NFA_ANY: ++ case NFA_IDENT: ++ case NFA_SIDENT: ++ case NFA_KWORD: ++ case NFA_SKWORD: ++ case NFA_FNAME: ++ case NFA_SFNAME: ++ case NFA_PRINT: ++ case NFA_SPRINT: ++ case NFA_WHITE: ++ case NFA_NWHITE: ++ case NFA_DIGIT: ++ case NFA_NDIGIT: ++ case NFA_HEX: ++ case NFA_NHEX: ++ case NFA_OCTAL: ++ case NFA_NOCTAL: ++ case NFA_WORD: ++ case NFA_NWORD: ++ case NFA_HEAD: ++ case NFA_NHEAD: ++ case NFA_ALPHA: ++ case NFA_NALPHA: ++ case NFA_LOWER: ++ case NFA_NLOWER: ++ case NFA_UPPER: ++ case NFA_NUPPER: ++ case NFA_START_COLL: ++ case NFA_START_NEG_COLL: ++ case NFA_NEWL: ++ /* state will advance input */ ++ return FALSE; ++ ++ default: ++ if (state->c > 0) ++ /* state will advance input */ ++ return FALSE; ++ ++ /* Others: zero-width or possibly zero-width, might still find ++ * a match at the same position, keep looking. */ ++ break; ++ } ++ state = state->out; ++ } ++ return FALSE; ++ } ++ ++ ++ /* + * Return TRUE if "state" is already in list "l". + */ + static int +*************** +*** 5714,5722 **** + + if (add_state != NULL) + { +! if (t->pim != NULL) + { +- /* postponed invisible match */ + if (t->pim->result == NFA_PIM_TODO) + { + #ifdef ENABLE_LOG +--- 5798,5808 ---- + + if (add_state != NULL) + { +! /* Handle the postponed invisible match before advancing to +! * the next character and for a zero-width match if the match +! * might end without advancing. */ +! if (t->pim != NULL && (!add_here || match_follows(add_state, 0))) + { + if (t->pim->result == NFA_PIM_TODO) + { + #ifdef ENABLE_LOG +*************** +*** 5773,5779 **** + } + + if (add_here) +! addstate_here(thislist, add_state, &t->subs, NULL, &listidx); + else + { + addstate(nextlist, add_state, &t->subs, add_off); +--- 5859,5865 ---- + } + + if (add_here) +! addstate_here(thislist, add_state, &t->subs, t->pim, &listidx); + else + { + addstate(nextlist, add_state, &t->subs, add_off); +*** ../vim-7.3.1150/src/version.c 2013-06-08 22:29:59.000000000 +0200 +--- src/version.c 2013-06-08 23:23:53.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1151, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +117. You are more comfortable typing in html. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 020142d6086ab7d00a1dd583d21e2341ee0990e5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:37 +0200 Subject: [PATCH 1044/3340] - patchlevel 1152 --- 7.3.1152 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.1152 diff --git a/7.3.1152 b/7.3.1152 new file mode 100644 index 00000000..4d18bc87 --- /dev/null +++ b/7.3.1152 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1152 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1152 +Problem: In tiny build ireg_icombine is undefined. (Tony Mechelynck) +Solution: Add #ifdef. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1151/src/regexp_nfa.c 2013-06-08 23:26:10.000000000 +0200 +--- src/regexp_nfa.c 2013-06-08 23:29:22.000000000 +0200 +*************** +*** 6198,6204 **** + + /* If match_text is set it contains the full text that must match. + * Nothing else to try. Doesn't handle combining chars well. */ +! if (prog->match_text != NULL && !ireg_icombine) + return find_match_text(col, prog->regstart, prog->match_text); + } + +--- 6198,6208 ---- + + /* If match_text is set it contains the full text that must match. + * Nothing else to try. Doesn't handle combining chars well. */ +! if (prog->match_text != NULL +! #ifdef FEAT_MBYTE +! && !ireg_icombine +! #endif +! ) + return find_match_text(col, prog->regstart, prog->match_text); + } + +*** ../vim-7.3.1151/src/version.c 2013-06-08 23:26:10.000000000 +0200 +--- src/version.c 2013-06-08 23:28:06.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1152, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +118. You are on a first-name basis with your ISP's staff. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 03107752c637bea8ebb1d460827e67555fdc2b9d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:38 +0200 Subject: [PATCH 1045/3340] - patchlevel 1153 --- 7.3.1153 | 895 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 895 insertions(+) create mode 100644 7.3.1153 diff --git a/7.3.1153 b/7.3.1153 new file mode 100644 index 00000000..d8b488b2 --- /dev/null +++ b/7.3.1153 @@ -0,0 +1,895 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1153 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1153 +Problem: New regexp engine: Some look-behind matches are very expensive. +Solution: Pospone invisible matches further, until a match is almost found. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1152/src/regexp_nfa.c 2013-06-08 23:30:00.000000000 +0200 +--- src/regexp_nfa.c 2013-06-09 16:11:41.000000000 +0200 +*************** +*** 3354,3369 **** + typedef struct nfa_pim_S nfa_pim_T; + struct nfa_pim_S + { +! nfa_state_T *state; +! int result; /* NFA_PIM_TODO, NFA_PIM_[NO]MATCH */ +! nfa_pim_T *pim; /* another PIM at the same position */ + regsubs_T subs; /* submatch info, only party used */ + }; + + /* Values for done in nfa_pim_T. */ +! #define NFA_PIM_TODO 0 +! #define NFA_PIM_MATCH 1 +! #define NFA_PIM_NOMATCH -1 + + + /* nfa_thread_T contains execution information of a NFA state */ +--- 3354,3374 ---- + typedef struct nfa_pim_S nfa_pim_T; + struct nfa_pim_S + { +! int result; /* NFA_PIM_*, see below */ +! nfa_state_T *state; /* the invisible match start state */ + regsubs_T subs; /* submatch info, only party used */ ++ union ++ { ++ lpos_T pos; ++ char_u *ptr; ++ } end; /* where the match must end */ + }; + + /* Values for done in nfa_pim_T. */ +! #define NFA_PIM_UNUSED 0 /* pim not used */ +! #define NFA_PIM_TODO 1 /* pim not done yet */ +! #define NFA_PIM_MATCH 2 /* pim executed, matches */ +! #define NFA_PIM_NOMATCH 3 /* pim executed, no match */ + + + /* nfa_thread_T contains execution information of a NFA state */ +*************** +*** 3371,3377 **** + { + nfa_state_T *state; + int count; +! nfa_pim_T *pim; /* if not NULL: postponed invisible match */ + regsubs_T subs; /* submatch info, only party used */ + } nfa_thread_T; + +--- 3376,3383 ---- + { + nfa_state_T *state; + int count; +! nfa_pim_T pim; /* if pim.result != NFA_PIM_UNUSED: postponed +! * invisible match */ + regsubs_T subs; /* submatch info, only party used */ + } nfa_thread_T; + +*************** +*** 3424,3434 **** +--- 3430,3457 ---- + e == NULL ? "NULL" : e); + } + } ++ ++ static char * ++ pim_info(nfa_pim_T *pim) ++ { ++ static char buf[30]; ++ ++ if (pim == NULL || pim->result == NFA_PIM_UNUSED) ++ buf[0] = NUL; ++ else ++ { ++ sprintf(buf, " PIM col %d", REG_MULTI ? (int)pim->end.pos.col ++ : (int)(pim->end.ptr - reginput)); ++ } ++ return buf; ++ } ++ + #endif + + /* Used during execution: whether a match has been found. */ + static int nfa_match; + ++ static void copy_pim __ARGS((nfa_pim_T *to, nfa_pim_T *from)); + static void clear_sub __ARGS((regsub_T *sub)); + static void copy_sub __ARGS((regsub_T *to, regsub_T *from)); + static void copy_sub_off __ARGS((regsub_T *to, regsub_T *from)); +*************** +*** 3436,3444 **** + static int has_state_with_pos __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs)); + static int match_follows __ARGS((nfa_state_T *startstate, int depth)); + static int state_in_list __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs)); +! static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, int off)); + static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, nfa_pim_T *pim, int *ip)); + + static void + clear_sub(sub) + regsub_T *sub; +--- 3459,3485 ---- + static int has_state_with_pos __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs)); + static int match_follows __ARGS((nfa_state_T *startstate, int depth)); + static int state_in_list __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs)); +! static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, nfa_pim_T *pim, int off)); + static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, nfa_pim_T *pim, int *ip)); + ++ /* ++ * Copy postponed invisible match info from "from" to "to". ++ */ ++ static void ++ copy_pim(to, from) ++ nfa_pim_T *to; ++ nfa_pim_T *from; ++ { ++ to->result = from->result; ++ to->state = from->state; ++ copy_sub(&to->subs.norm, &from->subs.norm); ++ #ifdef FEAT_SYN_HL ++ if (nfa_has_zsubexpr) ++ copy_sub(&to->subs.synt, &from->subs.synt); ++ #endif ++ to->end = from->end; ++ } ++ + static void + clear_sub(sub) + regsub_T *sub; +*************** +*** 3583,3589 **** + + #ifdef ENABLE_LOG + static void +! report_state(char *action, regsub_T *sub, nfa_state_T *state, int lid) + { + int col; + +--- 3624,3634 ---- + + #ifdef ENABLE_LOG + static void +! report_state(char *action, +! regsub_T *sub, +! nfa_state_T *state, +! int lid, +! nfa_pim_T *pim) + { + int col; + +*************** +*** 3594,3601 **** + else + col = (int)(sub->list.line[0].start - regline); + nfa_set_code(state->c); +! fprintf(log_fd, "> %s state %d to list %d. char %d: %s (start col %d)\n", +! action, abs(state->id), lid, state->c, code, col); + } + #endif + +--- 3639,3647 ---- + else + col = (int)(sub->list.line[0].start - regline); + nfa_set_code(state->c); +! fprintf(log_fd, "> %s state %d to list %d. char %d: %s (start col %d)%s\n", +! action, abs(state->id), lid, state->c, code, col, +! pim_info(pim)); + } + #endif + +*************** +*** 3646,3651 **** +--- 3692,3701 ---- + switch (state->c) + { + case NFA_MATCH: ++ case NFA_MCLOSE: ++ case NFA_END_INVISIBLE: ++ case NFA_END_INVISIBLE_NEG: ++ case NFA_END_PATTERN: + return TRUE; + + case NFA_SPLIT: +*************** +*** 3727,3736 **** + } + + static void +! addstate(l, state, subs, off) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ + regsubs_T *subs; /* pointers to subexpressions */ + int off; /* byte offset, when -1 go to next line */ + { + int subidx; +--- 3777,3787 ---- + } + + static void +! addstate(l, state, subs, pim, off) + nfa_list_T *l; /* runtime state list */ + nfa_state_T *state; /* state to update */ + regsubs_T *subs; /* pointers to subexpressions */ ++ nfa_pim_T *pim; /* postponed look-behind match */ + int off; /* byte offset, when -1 go to next line */ + { + int subidx; +*************** +*** 3856,3876 **** + state->lastlist[nfa_ll_index] = l->id; + thread = &l->t[l->n++]; + thread->state = state; +! thread->pim = NULL; + copy_sub(&thread->subs.norm, &subs->norm); + #ifdef FEAT_SYN_HL + if (nfa_has_zsubexpr) + copy_sub(&thread->subs.synt, &subs->synt); + #endif + #ifdef ENABLE_LOG +! report_state("Adding", &thread->subs.norm, state, l->id); + did_print = TRUE; + #endif + } + + #ifdef ENABLE_LOG + if (!did_print) +! report_state("Processing", &subs->norm, state, l->id); + #endif + switch (state->c) + { +--- 3907,3930 ---- + state->lastlist[nfa_ll_index] = l->id; + thread = &l->t[l->n++]; + thread->state = state; +! if (pim == NULL) +! thread->pim.result = NFA_PIM_UNUSED; +! else +! copy_pim(&thread->pim, pim); + copy_sub(&thread->subs.norm, &subs->norm); + #ifdef FEAT_SYN_HL + if (nfa_has_zsubexpr) + copy_sub(&thread->subs.synt, &subs->synt); + #endif + #ifdef ENABLE_LOG +! report_state("Adding", &thread->subs.norm, state, l->id, pim); + did_print = TRUE; + #endif + } + + #ifdef ENABLE_LOG + if (!did_print) +! report_state("Processing", &subs->norm, state, l->id, pim); + #endif + switch (state->c) + { +*************** +*** 3880,3893 **** + + case NFA_SPLIT: + /* order matters here */ +! addstate(l, state->out, subs, off); +! addstate(l, state->out1, subs, off); + break; + + case NFA_SKIP_CHAR: + case NFA_NOPEN: + case NFA_NCLOSE: +! addstate(l, state->out, subs, off); + break; + + case NFA_MOPEN: +--- 3934,3947 ---- + + case NFA_SPLIT: + /* order matters here */ +! addstate(l, state->out, subs, pim, off); +! addstate(l, state->out1, subs, pim, off); + break; + + case NFA_SKIP_CHAR: + case NFA_NOPEN: + case NFA_NCLOSE: +! addstate(l, state->out, subs, pim, off); + break; + + case NFA_MOPEN: +*************** +*** 3983,3989 **** + sub->list.line[subidx].start = reginput + off; + } + +! addstate(l, state->out, subs, off); + + if (save_in_use == -1) + { +--- 4037,4043 ---- + sub->list.line[subidx].start = reginput + off; + } + +! addstate(l, state->out, subs, pim, off); + + if (save_in_use == -1) + { +*************** +*** 4001,4007 **** + { + /* Do not overwrite the position set by \ze. If no \ze + * encountered end will be set in nfa_regtry(). */ +! addstate(l, state->out, subs, off); + break; + } + case NFA_MCLOSE1: +--- 4055,4061 ---- + { + /* Do not overwrite the position set by \ze. If no \ze + * encountered end will be set in nfa_regtry(). */ +! addstate(l, state->out, subs, pim, off); + break; + } + case NFA_MCLOSE1: +*************** +*** 4070,4076 **** + sub->list.line[subidx].end = reginput + off; + } + +! addstate(l, state->out, subs, off); + + if (REG_MULTI) + sub->list.multi[subidx].end = save_lpos; +--- 4124,4130 ---- + sub->list.line[subidx].end = reginput + off; + } + +! addstate(l, state->out, subs, pim, off); + + if (REG_MULTI) + sub->list.multi[subidx].end = save_lpos; +*************** +*** 4098,4112 **** + int tlen = l->n; + int count; + int listidx = *ip; +- int i; + + /* first add the state(s) at the end, so that we know how many there are */ +! addstate(l, state, subs, 0); +! +! /* fill in the "pim" field in the new states */ +! if (pim != NULL) +! for (i = tlen; i < l->n; ++i) +! l->t[i].pim = pim; + + /* when "*ip" was at the end of the list, nothing to do */ + if (listidx + 1 == tlen) +--- 4152,4160 ---- + int tlen = l->n; + int count; + int listidx = *ip; + + /* first add the state(s) at the end, so that we know how many there are */ +! addstate(l, state, subs, pim, 0); + + /* when "*ip" was at the end of the list, nothing to do */ + if (listidx + 1 == tlen) +*************** +*** 4355,4369 **** + return val == pos; + } + +! static int recursive_regmatch __ARGS((nfa_state_T *state, nfa_regprog_T *prog, regsubs_T *submatch, regsubs_T *m, int **listids)); + static int nfa_regmatch __ARGS((nfa_regprog_T *prog, nfa_state_T *start, regsubs_T *submatch, regsubs_T *m)); + + /* + * Recursively call nfa_regmatch() + */ + static int +! recursive_regmatch(state, prog, submatch, m, listids) + nfa_state_T *state; + nfa_regprog_T *prog; + regsubs_T *submatch; + regsubs_T *m; +--- 4403,4420 ---- + return val == pos; + } + +! static int recursive_regmatch __ARGS((nfa_state_T *state, nfa_pim_T *pim, nfa_regprog_T *prog, regsubs_T *submatch, regsubs_T *m, int **listids)); + static int nfa_regmatch __ARGS((nfa_regprog_T *prog, nfa_state_T *start, regsubs_T *submatch, regsubs_T *m)); + + /* + * Recursively call nfa_regmatch() ++ * "pim" is NULL or contains info about a Postponed Invisible Match (start ++ * position). + */ + static int +! recursive_regmatch(state, pim, prog, submatch, m, listids) + nfa_state_T *state; ++ nfa_pim_T *pim; + nfa_regprog_T *prog; + regsubs_T *submatch; + regsubs_T *m; +*************** +*** 4380,4397 **** + int result; + int need_restore = FALSE; + + if (state->c == NFA_START_INVISIBLE_BEFORE + || state->c == NFA_START_INVISIBLE_BEFORE_NEG) + { +! /* The recursive match must end at the current position. */ + endposp = &endpos; + if (REG_MULTI) + { +! endpos.se_u.pos.col = (int)(reginput - regline); +! endpos.se_u.pos.lnum = reglnum; + } + else +! endpos.se_u.ptr = reginput; + + /* Go back the specified number of bytes, or as far as the + * start of the previous line, to try matching "\@<=" or +--- 4431,4468 ---- + int result; + int need_restore = FALSE; + ++ if (pim != NULL) ++ { ++ /* start at the position where the postponed match was */ ++ if (REG_MULTI) ++ reginput = regline + pim->end.pos.col; ++ else ++ reginput = pim->end.ptr; ++ } ++ + if (state->c == NFA_START_INVISIBLE_BEFORE + || state->c == NFA_START_INVISIBLE_BEFORE_NEG) + { +! /* The recursive match must end at the current position. When "pim" is +! * not NULL it specifies the current position. */ + endposp = &endpos; + if (REG_MULTI) + { +! if (pim == NULL) +! { +! endpos.se_u.pos.col = (int)(reginput - regline); +! endpos.se_u.pos.lnum = reglnum; +! } +! else +! endpos.se_u.pos = pim->end.pos; + } + else +! { +! if (pim == NULL) +! endpos.se_u.ptr = reginput; +! else +! endpos.se_u.ptr = pim->end.ptr; +! } + + /* Go back the specified number of bytes, or as far as the + * start of the previous line, to try matching "\@<=" or +*************** +*** 4784,4790 **** + int add_here; + int add_count; + int add_off; +- garray_T pimlist; + int toplevel = start->c == NFA_MOPEN; + #ifdef NFA_REGEXP_DEBUG_LOG + FILE *debug = fopen(NFA_REGEXP_DEBUG_LOG, "a"); +--- 4855,4860 ---- +*************** +*** 4796,4802 **** + } + #endif + nfa_match = FALSE; +- ga_init2(&pimlist, sizeof(nfa_pim_T), 5); + + /* Allocate memory for the lists of nodes. */ + size = (nstate + 1) * sizeof(nfa_thread_T); +--- 4866,4871 ---- +*************** +*** 4845,4854 **** + else + m->norm.list.line[0].start = reginput; + m->norm.in_use = 1; +! addstate(thislist, start->out, m, 0); + } + else +! addstate(thislist, start, m, 0); + + #define ADD_STATE_IF_MATCH(state) \ + if (result) { \ +--- 4914,4923 ---- + else + m->norm.list.line[0].start = reginput; + m->norm.in_use = 1; +! addstate(thislist, start->out, m, NULL, 0); + } + else +! addstate(thislist, start, m, NULL, 0); + + #define ADD_STATE_IF_MATCH(state) \ + if (result) { \ +*************** +*** 4890,4897 **** + thislist->id = nfa_listid; + nextlist->id = nfa_listid + 1; + +- pimlist.ga_len = 0; +- + #ifdef ENABLE_LOG + fprintf(log_fd, "------------------------------------------\n"); + fprintf(log_fd, ">>> Reginput is \"%s\"\n", reginput); +--- 4959,4964 ---- +*************** +*** 4935,4942 **** + else + col = (int)(t->subs.norm.list.line[0].start - regline); + nfa_set_code(t->state->c); +! fprintf(log_fd, "(%d) char %d %s (start col %d) ... \n", +! abs(t->state->id), (int)t->state->c, code, col); + } + #endif + +--- 5002,5010 ---- + else + col = (int)(t->subs.norm.list.line[0].start - regline); + nfa_set_code(t->state->c); +! fprintf(log_fd, "(%d) char %d %s (start col %d)%s ... \n", +! abs(t->state->id), (int)t->state->c, code, col, +! pim_info(&t->pim)); + } + #endif + +*************** +*** 5028,5048 **** + case NFA_START_INVISIBLE_BEFORE: + case NFA_START_INVISIBLE_BEFORE_NEG: + { +- nfa_pim_T *pim; + int cout = t->state->out1->out->c; + + /* Do it directly when what follows is possibly end of + * match (closing paren). + * Postpone when it is \@<= or \@pim and check multiple +- * where it's used? + * Otherwise first do the one that has the highest chance + * of failing. */ + if ((cout >= NFA_MCLOSE && cout <= NFA_MCLOSE9) + #ifdef FEAT_SYN_HL + || (cout >= NFA_ZCLOSE && cout <= NFA_ZCLOSE9) + #endif +! || t->pim != NULL + || (t->state->c != NFA_START_INVISIBLE_BEFORE + && t->state->c != NFA_START_INVISIBLE_BEFORE_NEG + && failure_chance(t->state->out1->out, 0) +--- 5096,5114 ---- + case NFA_START_INVISIBLE_BEFORE: + case NFA_START_INVISIBLE_BEFORE_NEG: + { + int cout = t->state->out1->out->c; + + /* Do it directly when what follows is possibly end of + * match (closing paren). ++ * Do it directly if there already is a PIM. + * Postpone when it is \@<= or \@= NFA_MCLOSE && cout <= NFA_MCLOSE9) + #ifdef FEAT_SYN_HL + || (cout >= NFA_ZCLOSE && cout <= NFA_ZCLOSE9) + #endif +! || t->pim.result != NFA_PIM_UNUSED + || (t->state->c != NFA_START_INVISIBLE_BEFORE + && t->state->c != NFA_START_INVISIBLE_BEFORE_NEG + && failure_chance(t->state->out1->out, 0) +*************** +*** 5052,5058 **** + * First try matching the invisible match, then what + * follows. + */ +! result = recursive_regmatch(t->state, prog, + submatch, m, &listids); + + /* for \@! and \@state, NULL, prog, + submatch, m, &listids); + + /* for \@! and \@state = t->state; +! pim->pim = NULL; +! pim->result = NFA_PIM_TODO; + + /* t->state->out1 is the corresponding END_INVISIBLE + * node; Add its out to the current list (zero-width + * match). */ + addstate_here(thislist, t->state->out1->out, &t->subs, +! pim, &listidx); + } + } + break; +--- 5143,5175 ---- + } + else + { ++ nfa_pim_T pim; ++ + /* +! * First try matching what follows. Only if a match +! * is found verify the invisible match matches. Add a +! * nfa_pim_T to the following states, it contains info +! * about the invisible match. + */ +! pim.state = t->state; +! pim.result = NFA_PIM_TODO; +! pim.subs.norm.in_use = 0; +! #ifdef FEAT_SYN_HL +! pim.subs.synt.in_use = 0; +! #endif +! if (REG_MULTI) +! { +! pim.end.pos.col = (int)(reginput - regline); +! pim.end.pos.lnum = reglnum; +! } +! else +! pim.end.ptr = reginput; + + /* t->state->out1 is the corresponding END_INVISIBLE + * node; Add its out to the current list (zero-width + * match). */ + addstate_here(thislist, t->state->out1->out, &t->subs, +! &pim, &listidx); + } + } + break; +*************** +*** 5144,5150 **** + } + + /* First try matching the pattern. */ +! result = recursive_regmatch(t->state, prog, + submatch, m, &listids); + if (result) + { +--- 5217,5223 ---- + } + + /* First try matching the pattern. */ +! result = recursive_regmatch(t->state, NULL, prog, + submatch, m, &listids); + if (result) + { +*************** +*** 5798,5809 **** + + if (add_state != NULL) + { +! /* Handle the postponed invisible match before advancing to +! * the next character and for a zero-width match if the match +! * might end without advancing. */ +! if (t->pim != NULL && (!add_here || match_follows(add_state, 0))) + { +! if (t->pim->result == NFA_PIM_TODO) + { + #ifdef ENABLE_LOG + fprintf(log_fd, "\n"); +--- 5871,5888 ---- + + if (add_state != NULL) + { +! nfa_pim_T *pim; +! +! if (t->pim.result == NFA_PIM_UNUSED) +! pim = NULL; +! else +! pim = &t->pim; +! +! /* Handle the postponed invisible match if the match might end +! * without advancing and before the end of the line. */ +! if (pim != NULL && (clen == 0 || match_follows(add_state, 0))) + { +! if (pim->result == NFA_PIM_TODO) + { + #ifdef ENABLE_LOG + fprintf(log_fd, "\n"); +*************** +*** 5811,5868 **** + fprintf(log_fd, "Postponed recursive nfa_regmatch()\n"); + fprintf(log_fd, "\n"); + #endif +! result = recursive_regmatch(t->pim->state, + prog, submatch, m, &listids); +! t->pim->result = result ? NFA_PIM_MATCH +! : NFA_PIM_NOMATCH; + /* for \@! and \@pim->state->c +! == NFA_START_INVISIBLE_NEG +! || t->pim->state->c + == NFA_START_INVISIBLE_BEFORE_NEG)) + { + /* Copy submatch info from the recursive call */ +! copy_sub_off(&t->pim->subs.norm, &m->norm); + #ifdef FEAT_SYN_HL + if (nfa_has_zsubexpr) +! copy_sub_off(&t->pim->subs.synt, &m->synt); + #endif + } + } + else + { +! result = (t->pim->result == NFA_PIM_MATCH); + #ifdef ENABLE_LOG + fprintf(log_fd, "\n"); +! fprintf(log_fd, "Using previous recursive nfa_regmatch() result, result == %d\n", t->pim->result); + fprintf(log_fd, "MATCH = %s\n", result == TRUE ? "OK" : "FALSE"); + fprintf(log_fd, "\n"); + #endif + } + + /* for \@! and \@pim->state->c == NFA_START_INVISIBLE_NEG +! || t->pim->state->c + == NFA_START_INVISIBLE_BEFORE_NEG)) + { + /* Copy submatch info from the recursive call */ +! copy_sub_off(&t->subs.norm, &t->pim->subs.norm); + #ifdef FEAT_SYN_HL + if (nfa_has_zsubexpr) +! copy_sub_off(&t->subs.synt, &t->pim->subs.synt); + #endif + } + else + /* look-behind match failed, don't add the state */ + continue; + } + + if (add_here) +! addstate_here(thislist, add_state, &t->subs, t->pim, &listidx); + else + { +! addstate(nextlist, add_state, &t->subs, add_off); + if (add_count > 0) + nextlist->t[nextlist->n - 1].count = add_count; + } +--- 5890,5949 ---- + fprintf(log_fd, "Postponed recursive nfa_regmatch()\n"); + fprintf(log_fd, "\n"); + #endif +! result = recursive_regmatch(pim->state, pim, + prog, submatch, m, &listids); +! pim->result = result ? NFA_PIM_MATCH : NFA_PIM_NOMATCH; + /* for \@! and \@state->c == NFA_START_INVISIBLE_NEG +! || pim->state->c + == NFA_START_INVISIBLE_BEFORE_NEG)) + { + /* Copy submatch info from the recursive call */ +! copy_sub_off(&pim->subs.norm, &m->norm); + #ifdef FEAT_SYN_HL + if (nfa_has_zsubexpr) +! copy_sub_off(&pim->subs.synt, &m->synt); + #endif + } + } + else + { +! result = (pim->result == NFA_PIM_MATCH); + #ifdef ENABLE_LOG + fprintf(log_fd, "\n"); +! fprintf(log_fd, "Using previous recursive nfa_regmatch() result, result == %d\n", pim->result); + fprintf(log_fd, "MATCH = %s\n", result == TRUE ? "OK" : "FALSE"); + fprintf(log_fd, "\n"); + #endif + } + + /* for \@! and \@state->c == NFA_START_INVISIBLE_NEG +! || pim->state->c + == NFA_START_INVISIBLE_BEFORE_NEG)) + { + /* Copy submatch info from the recursive call */ +! copy_sub_off(&t->subs.norm, &pim->subs.norm); + #ifdef FEAT_SYN_HL + if (nfa_has_zsubexpr) +! copy_sub_off(&t->subs.synt, &pim->subs.synt); + #endif + } + else + /* look-behind match failed, don't add the state */ + continue; ++ ++ /* Postponed invisible match was handled, don't add it to ++ * following states. */ ++ pim = NULL; + } + + if (add_here) +! addstate_here(thislist, add_state, &t->subs, pim, &listidx); + else + { +! addstate(nextlist, add_state, &t->subs, pim, add_off); + if (add_count > 0) + nextlist->t[nextlist->n - 1].count = add_count; + } +*************** +*** 5941,5951 **** + (colnr_T)(reginput - regline) + clen; + else + m->norm.list.line[0].start = reginput + clen; +! addstate(nextlist, start->out, m, clen); + } + } + else +! addstate(nextlist, start, m, clen); + } + + #ifdef ENABLE_LOG +--- 6022,6032 ---- + (colnr_T)(reginput - regline) + clen; + else + m->norm.list.line[0].start = reginput + clen; +! addstate(nextlist, start->out, m, NULL, clen); + } + } + else +! addstate(nextlist, start, m, NULL, clen); + } + + #ifdef ENABLE_LOG +*************** +*** 5982,5988 **** + vim_free(list[0].t); + vim_free(list[1].t); + vim_free(listids); +- ga_clear(&pimlist); + #undef ADD_STATE_IF_MATCH + #ifdef NFA_REGEXP_DEBUG_LOG + fclose(debug); +--- 6063,6068 ---- +*** ../vim-7.3.1152/src/version.c 2013-06-08 23:30:00.000000000 +0200 +--- src/version.c 2013-06-09 15:21:03.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1153, + /**/ + +-- +"Computers in the future may weigh no more than 1.5 tons." + Popular Mechanics, 1949 + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d2dd939c25cd87b88ba1dc1d8b242463d5689781 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:39 +0200 Subject: [PATCH 1046/3340] - patchlevel 1154 --- 7.3.1154 | 115 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 115 insertions(+) create mode 100644 7.3.1154 diff --git a/7.3.1154 b/7.3.1154 new file mode 100644 index 00000000..2e4b54ed --- /dev/null +++ b/7.3.1154 @@ -0,0 +1,115 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1154 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1154 +Problem: New regexp_nfa engine: Uneccessary code. +Solution: Remove uneccessary code. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1153/src/regexp_nfa.c 2013-06-09 16:24:40.000000000 +0200 +--- src/regexp_nfa.c 2013-06-09 17:02:03.000000000 +0200 +*************** +*** 3795,3808 **** + int did_print = FALSE; + #endif + +- if (l == NULL || state == NULL) +- return; +- + switch (state->c) + { +- case NFA_SPLIT: +- case NFA_NOPEN: +- case NFA_SKIP_CHAR: + case NFA_NCLOSE: + case NFA_MCLOSE: + case NFA_MCLOSE1: +--- 3795,3802 ---- +*************** +*** 3827,3832 **** +--- 3821,3829 ---- + case NFA_ZCLOSE9: + #endif + case NFA_ZEND: ++ case NFA_SPLIT: ++ case NFA_NOPEN: ++ case NFA_SKIP_CHAR: + /* These nodes are not added themselves but their "out" and/or + * "out1" may be added below. */ + break; +*************** +*** 3889,3900 **** + return; + } + + if (has_state_with_pos(l, state, subs)) + goto skip_add; + } + +! /* when there are backreferences or look-behind matches the number +! * of states may be (a lot) bigger */ + if (nfa_has_backref && l->n == l->len) + { + int newlen = l->len * 3 / 2 + 50; +--- 3886,3899 ---- + return; + } + ++ /* Do not add the state again when it exists with the same ++ * positions. */ + if (has_state_with_pos(l, state, subs)) + goto skip_add; + } + +! /* When there are backreferences the number of states may be (a +! * lot) bigger than anticipated. */ + if (nfa_has_backref && l->n == l->len) + { + int newlen = l->len * 3 / 2 + 50; +*************** +*** 3985,3992 **** + sub = &subs->norm; + } + +! /* Set the position (with "off") in the subexpression. Save and +! * restore it when it was in use. Otherwise fill any gap. */ + save_ptr = NULL; + if (REG_MULTI) + { +--- 3984,3991 ---- + sub = &subs->norm; + } + +! /* Set the position (with "off" added) in the subexpression. Save +! * and restore it when it was in use. Otherwise fill any gap. */ + save_ptr = NULL; + if (REG_MULTI) + { +*** ../vim-7.3.1153/src/version.c 2013-06-09 16:24:40.000000000 +0200 +--- src/version.c 2013-06-09 17:24:42.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1154, + /**/ + + +-- +~ +~ +~ +".signature" 4 lines, 50 characters written + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From cfbf52522917b59c8e2a0bd962aa7a6b301cdc59 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:40 +0200 Subject: [PATCH 1047/3340] - patchlevel 1155 --- 7.3.1155 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.1155 diff --git a/7.3.1155 b/7.3.1155 new file mode 100644 index 00000000..622258c2 --- /dev/null +++ b/7.3.1155 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1155 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1155 +Problem: MS-DOS: "make test" uses external rmdir command. +Solution: Rename "rmdir" to "rd". (Taro Muraoka) +Files: src/testdir/Make_dos.mak + + +*** ../vim-7.3.1154/src/testdir/Make_dos.mak 2013-05-19 19:16:25.000000000 +0200 +--- src/testdir/Make_dos.mak 2013-06-09 17:49:47.000000000 +0200 +*************** +*** 77,81 **** + -del X* + -del X*.* + -del test.ok +! -rmdir /s /q Xfind + -if exist viminfo del viminfo +--- 77,81 ---- + -del X* + -del X*.* + -del test.ok +! -rd /s /q Xfind + -if exist viminfo del viminfo +*** ../vim-7.3.1154/src/version.c 2013-06-09 17:25:29.000000000 +0200 +--- src/version.c 2013-06-09 17:50:49.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1155, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +124. You begin conversations with, "Who is your internet service provider?" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f418795ffad9a0bb546792de4a6a535bf30b00fb Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:41 +0200 Subject: [PATCH 1048/3340] - patchlevel 1156 --- 7.3.1156 | 85 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100644 7.3.1156 diff --git a/7.3.1156 b/7.3.1156 new file mode 100644 index 00000000..899480a3 --- /dev/null +++ b/7.3.1156 @@ -0,0 +1,85 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1156 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1156 +Problem: Compiler warnings. (dv1445) +Solution: Initialize variables, even when the value isn't really used. +Files: src/regexp_nfa.c, src/eval.c + + +*** ../vim-7.3.1155/src/regexp_nfa.c 2013-06-09 17:25:29.000000000 +0200 +--- src/regexp_nfa.c 2013-06-09 20:35:42.000000000 +0200 +*************** +*** 3045,3051 **** + start_state = NFA_START_INVISIBLE_BEFORE_NEG; + end_state = NFA_END_INVISIBLE_NEG; + break; +! case NFA_PREV_ATOM_LIKE_PATTERN: + start_state = NFA_START_PATTERN; + end_state = NFA_END_PATTERN; + break; +--- 3045,3051 ---- + start_state = NFA_START_INVISIBLE_BEFORE_NEG; + end_state = NFA_END_INVISIBLE_NEG; + break; +! default: /* NFA_PREV_ATOM_LIKE_PATTERN: */ + start_state = NFA_START_PATTERN; + end_state = NFA_END_PATTERN; + break; +*************** +*** 4853,4859 **** + nfa_state_T *add_state; + int add_here; + int add_count; +! int add_off; + int toplevel = start->c == NFA_MOPEN; + #ifdef NFA_REGEXP_DEBUG_LOG + FILE *debug = fopen(NFA_REGEXP_DEBUG_LOG, "a"); +--- 4853,4859 ---- + nfa_state_T *add_state; + int add_here; + int add_count; +! int add_off = 0; + int toplevel = start->c == NFA_MOPEN; + #ifdef NFA_REGEXP_DEBUG_LOG + FILE *debug = fopen(NFA_REGEXP_DEBUG_LOG, "a"); +*** ../vim-7.3.1155/src/eval.c 2013-06-08 18:19:39.000000000 +0200 +--- src/eval.c 2013-06-09 20:38:06.000000000 +0200 +*************** +*** 2734,2739 **** +--- 2734,2741 ---- + prevval = key[len]; + key[len] = NUL; + } ++ else ++ prevval = 0; /* avoid compiler warning */ + wrong = (lp->ll_dict->dv_scope == VAR_DEF_SCOPE + && rettv->v_type == VAR_FUNC + && var_check_func_name(key, lp->ll_di == NULL)) +*** ../vim-7.3.1155/src/version.c 2013-06-09 17:52:42.000000000 +0200 +--- src/version.c 2013-06-09 20:50:05.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1156, + /**/ + +-- +"Microsoft is like Coke. It's a secret formula, all the money is from +distribution, and their goal is to get Coke everywhere. Open source is like +selling water. There are water companies like Perrier and Poland Spring, but +you're competing with something that's free." -- Carl Howe + + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a2374c223d8b3695e1fbb2118c1b067d5cb55949 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:43 +0200 Subject: [PATCH 1049/3340] - patchlevel 1157 --- 7.3.1157 | 165 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 165 insertions(+) create mode 100644 7.3.1157 diff --git a/7.3.1157 b/7.3.1157 new file mode 100644 index 00000000..6d342611 --- /dev/null +++ b/7.3.1157 @@ -0,0 +1,165 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1157 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1157 +Problem: New regexp engine fails on "\(\state->out1->out->c; + +! /* Do it directly when what follows is possibly end of +! * match (closing paren). +! * Do it directly if there already is a PIM. +! * Postpone when it is \@<= or \@= NFA_MCLOSE && cout <= NFA_MCLOSE9) +! #ifdef FEAT_SYN_HL +! || (cout >= NFA_ZCLOSE && cout <= NFA_ZCLOSE9) + #endif +! || t->pim.result != NFA_PIM_UNUSED +! || (t->state->c != NFA_START_INVISIBLE_BEFORE +! && t->state->c != NFA_START_INVISIBLE_BEFORE_NEG +! && failure_chance(t->state->out1->out, 0) +! < failure_chance(t->state->out, 0))) + { + /* + * First try matching the invisible match, then what +--- 5097,5142 ---- + case NFA_START_INVISIBLE_BEFORE: + case NFA_START_INVISIBLE_BEFORE_NEG: + { +! int directly = FALSE; + +! #ifdef ENABLE_LOG +! fprintf(log_fd, "Failure chance invisible: %d, what follows: %d\n", +! failure_chance(t->state->out, 0), +! failure_chance(t->state->out1->out, 0)); + #endif +! /* Do it directly when what follows is possibly the end of +! * the match. +! * Do it directly if there already is a PIM. +! * Postpone when the invisible match is expensive or has a +! * lower chance of failing. */ +! if (match_follows(t->state->out1->out, 0) +! || t->pim.result != NFA_PIM_UNUSED) +! directly = TRUE; +! else +! { +! int ch_invisible = failure_chance(t->state->out, 0); +! int ch_follows = failure_chance(t->state->out1->out, 0); +! +! if (t->state->c == NFA_START_INVISIBLE_BEFORE +! || t->state->c == NFA_START_INVISIBLE_BEFORE_NEG) +! { +! /* "before" matches are very expensive when +! * unbounded, always prefer what follows then, +! * unless what follows will always match. +! * Otherwise strongly prefer what follows. */ +! if (t->state->val <= 0 && ch_follows > 0) +! directly = FALSE; +! else +! directly = ch_follows * 10 < ch_invisible; +! } +! else +! { +! /* normal invisible, first do the one with the +! * highest failure chance */ +! directly = ch_follows < ch_invisible; +! } +! } +! if (directly) + { + /* + * First try matching the invisible match, then what +*** ../vim-7.3.1156/src/testdir/test64.in 2013-06-08 18:19:40.000000000 +0200 +--- src/testdir/test64.in 2013-06-10 16:19:49.000000000 +0200 +*************** +*** 392,397 **** +--- 392,398 ---- + :call add(tl, [2, '\v\C%(', 'foobar']) + :call add(tl, [2, '\(foo\)\@<=\>', 'barfoo', '', 'foo']) ++ :call add(tl, [2, '\(foo\)\@<=.*', 'foobar', 'bar', 'foo']) + :" + :""""" \@> + :call add(tl, [2, '\(a*\)\@>a', 'aaaa']) +*** ../vim-7.3.1156/src/testdir/test64.ok 2013-06-08 18:19:40.000000000 +0200 +--- src/testdir/test64.ok 2013-06-10 16:21:07.000000000 +0200 +*************** +*** 890,895 **** +--- 890,898 ---- + OK 0 - \(foo\)\@<=\> + OK 1 - \(foo\)\@<=\> + OK 2 - \(foo\)\@<=\> ++ OK 0 - \(foo\)\@<=.* ++ OK 1 - \(foo\)\@<=.* ++ OK 2 - \(foo\)\@<=.* + OK 0 - \(a*\)\@>a + OK 1 - \(a*\)\@>a + OK 2 - \(a*\)\@>a +*** ../vim-7.3.1156/src/version.c 2013-06-09 20:50:56.000000000 +0200 +--- src/version.c 2013-06-10 16:23:57.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1157, + /**/ + +-- +In a world without fences, who needs Gates and Windows? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fae23dfb46bd455a6744870e86098011ba78f056 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:44 +0200 Subject: [PATCH 1050/3340] - patchlevel 1158 --- 7.3.1158 | 113 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 113 insertions(+) create mode 100644 7.3.1158 diff --git a/7.3.1158 b/7.3.1158 new file mode 100644 index 00000000..f4de874f --- /dev/null +++ b/7.3.1158 @@ -0,0 +1,113 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1158 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1158 +Problem: Crash when running test 86. (Jun Takimoto) +Solution: Define PY_SSIZE_T_CLEAN early. (Elimar Riesebieter) +Files: src/if_python.c, src/if_python3.c + + +*** ../vim-7.3.1157/src/if_python.c 2013-06-02 18:20:12.000000000 +0200 +--- src/if_python.c 2013-06-10 18:19:52.000000000 +0200 +*************** +*** 53,59 **** +--- 53,66 ---- + # undef _XOPEN_SOURCE /* pyconfig.h defines it as well. */ + #endif + ++ #define PY_SSIZE_T_CLEAN ++ + #include ++ ++ #if !defined(PY_VERSION_HEX) || PY_VERSION_HEX < 0x02050000 ++ # undef PY_SSIZE_T_CLEAN ++ #endif ++ + #if defined(MACOS) && !defined(MACOS_X_UNIX) + # include "macglue.h" + # include +*************** +*** 61,70 **** + #undef main /* Defined in python.h - aargh */ + #undef HAVE_FCNTL_H /* Clash with os_win32.h */ + +- #if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02050000 +- # define PY_SSIZE_T_CLEAN +- #endif +- + #define PyBytes_FromString PyString_FromString + #define PyBytes_Check PyString_Check + +--- 68,73 ---- +*** ../vim-7.3.1157/src/if_python3.c 2013-06-02 18:20:12.000000000 +0200 +--- src/if_python3.c 2013-06-10 18:24:36.000000000 +0200 +*************** +*** 24,32 **** + + /* uncomment this if used with the debug version of python */ + /* #define Py_DEBUG */ +! /* Note: most of time you can add -DPy_DEBUG to CFLAGS in place of uncommenting + */ +! /* uncomment this if used with the debug version of python, but without its + * allocator */ + /* #define Py_DEBUG_NO_PYMALLOC */ + +--- 24,32 ---- + + /* uncomment this if used with the debug version of python */ + /* #define Py_DEBUG */ +! /* Note: most of time you can add -DPy_DEBUG to CFLAGS in place of uncommenting + */ +! /* uncomment this if used with the debug version of python, but without its + * allocator */ + /* #define Py_DEBUG_NO_PYMALLOC */ + +*************** +*** 61,67 **** +--- 61,70 ---- + # undef _XOPEN_SOURCE /* pyconfig.h defines it as well. */ + #endif + ++ #define PY_SSIZE_T_CLEAN ++ + #include ++ + #if defined(MACOS) && !defined(MACOS_X_UNIX) + # include "macglue.h" + # include +*************** +*** 69,78 **** + #undef main /* Defined in python.h - aargh */ + #undef HAVE_FCNTL_H /* Clash with os_win32.h */ + +- #if defined(PY_VERSION_HEX) && PY_VERSION_HEX >= 0x02050000 +- # define PY_SSIZE_T_CLEAN +- #endif +- + /* The "surrogateescape" error handler is new in Python 3.1 */ + #if PY_VERSION_HEX >= 0x030100f0 + # define CODEC_ERROR_HANDLER "surrogateescape" +--- 72,77 ---- +*** ../vim-7.3.1157/src/version.c 2013-06-10 16:35:11.000000000 +0200 +--- src/version.c 2013-06-10 18:25:01.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1158, + /**/ + +-- +Never eat yellow snow. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8a1227e4d57004a006a31bef33583e35f2b3a724 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:45 +0200 Subject: [PATCH 1051/3340] - patchlevel 1159 --- 7.3.1159 | 134 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 134 insertions(+) create mode 100644 7.3.1159 diff --git a/7.3.1159 b/7.3.1159 new file mode 100644 index 00000000..ab880516 --- /dev/null +++ b/7.3.1159 @@ -0,0 +1,134 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1159 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1159 +Problem: The round() function is not always available. (Christ van + Willegen) +Solution: Use the solution from f_round(). +Files: src/ex_cmds2.c, src/eval.c, src/proto/eval.pro + + +*** ../vim-7.3.1158/src/ex_cmds2.c 2013-06-08 18:19:39.000000000 +0200 +--- src/ex_cmds2.c 2013-06-10 20:06:00.000000000 +0200 +*************** +*** 982,988 **** + double usec = (tm->tv_sec * 1000000.0 + tm->tv_usec) / count; + + tm2->tv_sec = floor(usec / 1000000.0); +! tm2->tv_usec = round(usec - (tm2->tv_sec * 1000000.0)); + # endif + } + } +--- 982,988 ---- + double usec = (tm->tv_sec * 1000000.0 + tm->tv_usec) / count; + + tm2->tv_sec = floor(usec / 1000000.0); +! tm2->tv_usec = vim_round(usec - (tm2->tv_sec * 1000000.0)); + # endif + } + } +*** ../vim-7.3.1158/src/eval.c 2013-06-09 20:50:56.000000000 +0200 +--- src/eval.c 2013-06-10 20:05:59.000000000 +0200 +*************** +*** 15774,15779 **** +--- 15774,15790 ---- + } + + #ifdef FEAT_FLOAT ++ ++ /* ++ * round() is not in C90, use ceil() or floor() instead. ++ */ ++ float_T ++ vim_round(f) ++ float_T f; ++ { ++ return f > 0 ? floor(f + 0.5) : ceil(f - 0.5); ++ } ++ + /* + * "round({float})" function + */ +*************** +*** 15786,15793 **** + + rettv->v_type = VAR_FLOAT; + if (get_float_arg(argvars, &f) == OK) +! /* round() is not in C90, use ceil() or floor() instead. */ +! rettv->vval.v_float = f > 0 ? floor(f + 0.5) : ceil(f - 0.5); + else + rettv->vval.v_float = 0.0; + } +--- 15797,15803 ---- + + rettv->v_type = VAR_FLOAT; + if (get_float_arg(argvars, &f) == OK) +! rettv->vval.v_float = vim_round(f); + else + rettv->vval.v_float = 0.0; + } +*** ../vim-7.3.1158/src/proto/eval.pro 2013-05-30 13:37:23.000000000 +0200 +--- src/proto/eval.pro 2013-06-10 20:05:57.000000000 +0200 +*************** +*** 75,87 **** + dictitem_T *dict_find __ARGS((dict_T *d, char_u *key, int len)); + char_u *get_dict_string __ARGS((dict_T *d, char_u *key, int save)); + long get_dict_number __ARGS((dict_T *d, char_u *key)); +- void dict_extend __ARGS((dict_T *d1, dict_T *d2, char_u *action)); + char_u *get_function_name __ARGS((expand_T *xp, int idx)); + char_u *get_expr_name __ARGS((expand_T *xp, int idx)); +- char_u *get_expanded_name __ARGS((char_u *name, int check)); +- int translated_function_exists __ARGS((char_u *name)); + int func_call __ARGS((char_u *name, typval_T *args, dict_T *selfdict, typval_T *rettv)); + void mzscheme_call_vim __ARGS((char_u *name, typval_T *args, typval_T *rettv)); + long do_searchpair __ARGS((char_u *spat, char_u *mpat, char_u *epat, int dir, char_u *skip, int flags, pos_T *match_pos, linenr_T lnum_stop, long time_limit)); + void set_vim_var_nr __ARGS((int idx, long val)); + long get_vim_var_nr __ARGS((int idx)); +--- 75,86 ---- + dictitem_T *dict_find __ARGS((dict_T *d, char_u *key, int len)); + char_u *get_dict_string __ARGS((dict_T *d, char_u *key, int save)); + long get_dict_number __ARGS((dict_T *d, char_u *key)); + char_u *get_function_name __ARGS((expand_T *xp, int idx)); + char_u *get_expr_name __ARGS((expand_T *xp, int idx)); + int func_call __ARGS((char_u *name, typval_T *args, dict_T *selfdict, typval_T *rettv)); ++ void dict_extend __ARGS((dict_T *d1, dict_T *d2, char_u *action)); + void mzscheme_call_vim __ARGS((char_u *name, typval_T *args, typval_T *rettv)); ++ float_T vim_round __ARGS((float_T f)); + long do_searchpair __ARGS((char_u *spat, char_u *mpat, char_u *epat, int dir, char_u *skip, int flags, pos_T *match_pos, linenr_T lnum_stop, long time_limit)); + void set_vim_var_nr __ARGS((int idx, long val)); + long get_vim_var_nr __ARGS((int idx)); +*************** +*** 110,115 **** +--- 109,116 ---- + void ex_execute __ARGS((exarg_T *eap)); + void ex_function __ARGS((exarg_T *eap)); + void free_all_functions __ARGS((void)); ++ int translated_function_exists __ARGS((char_u *name)); ++ char_u *get_expanded_name __ARGS((char_u *name, int check)); + void func_dump_profile __ARGS((FILE *fd)); + char_u *get_user_func_name __ARGS((expand_T *xp, int idx)); + void ex_delfunction __ARGS((exarg_T *eap)); +*** ../vim-7.3.1158/src/version.c 2013-06-10 18:36:20.000000000 +0200 +--- src/version.c 2013-06-10 20:02:01.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1159, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +134. You consider bandwidth to be more important than carats. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e4eb52d56a427c61cf1b0929e63a71ccdc6c32b7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:46 +0200 Subject: [PATCH 1052/3340] - patchlevel 1160 --- 7.3.1160 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.1160 diff --git a/7.3.1160 b/7.3.1160 new file mode 100644 index 00000000..143a9d2a --- /dev/null +++ b/7.3.1160 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1160 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1160 +Problem: Mixing long and pointer doesn't always work. +Solution: Avoid cast to pointer. +Files: src/undo.c + + +*** ../vim-7.3.1159/src/undo.c 2013-04-15 15:47:07.000000000 +0200 +--- src/undo.c 2013-06-10 20:13:37.000000000 +0200 +*************** +*** 1514,1521 **** + write_ok = TRUE; + #ifdef U_DEBUG + if (headers_written != buf->b_u_numhead) +! EMSG3("Written %ld headers, but numhead is %ld", +! headers_written, buf->b_u_numhead); + #endif + + write_error: +--- 1514,1523 ---- + write_ok = TRUE; + #ifdef U_DEBUG + if (headers_written != buf->b_u_numhead) +! { +! EMSGN("Written %ld headers, ...", headers_written); +! EMSGN("... but numhead is %ld", buf->b_u_numhead); +! } + #endif + + write_error: +*** ../vim-7.3.1159/src/version.c 2013-06-10 20:10:40.000000000 +0200 +--- src/version.c 2013-06-10 20:14:58.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1160, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +135. You cut classes or miss work so you can stay home and browse the web. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f074fbc0169aa1cfed576950110bd83fc006e231 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:47 +0200 Subject: [PATCH 1053/3340] - patchlevel 1161 --- 7.3.1161 | 194 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 194 insertions(+) create mode 100644 7.3.1161 diff --git a/7.3.1161 b/7.3.1161 new file mode 100644 index 00000000..7f9558e8 --- /dev/null +++ b/7.3.1161 @@ -0,0 +1,194 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1161 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1161 +Problem: Python: PyList_SetItem() is inefficient. +Solution: Use PyList_SET_ITEM() (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1160/src/if_py_both.h 2013-06-05 20:34:07.000000000 +0200 +--- src/if_py_both.h 2013-06-10 20:37:50.000000000 +0200 +*************** +*** 375,382 **** + static int + PythonIO_Init_io(void) + { +! PySys_SetObject("stdout", (PyObject *)(void *)&Output); +! PySys_SetObject("stderr", (PyObject *)(void *)&Error); + + if (PyErr_Occurred()) + { +--- 375,384 ---- + static int + PythonIO_Init_io(void) + { +! if (PySys_SetObject("stdout", (PyObject *)(void *)&Output)) +! return -1; +! if (PySys_SetObject("stderr", (PyObject *)(void *)&Error)) +! return -1; + + if (PyErr_Occurred()) + { +*************** +*** 1319,1330 **** + Py_DECREF(r); + return NULL; + } +! if (PyList_SetItem(r, i, newObj)) +! { +! Py_DECREF(r); +! Py_DECREF(newObj); +! return NULL; +! } + --todo; + ++i; + } +--- 1321,1327 ---- + Py_DECREF(r); + return NULL; + } +! PyList_SET_ITEM(r, i, newObj); + --todo; + ++i; + } +*************** +*** 1808,1819 **** + return NULL; + } + +! if ((PyList_SetItem(list, ((reversed)?(n-i-1):(i)), item))) +! { +! Py_DECREF(item); +! Py_DECREF(list); +! return NULL; +! } + } + + return list; +--- 1805,1811 ---- + return NULL; + } + +! PyList_SET_ITEM(list, ((reversed)?(n-i-1):(i)), item); + } + + return list; +*************** +*** 3164,3176 **** + return NULL; + } + +! /* Set the list item */ +! if (PyList_SetItem(list, i, str)) +! { +! Py_DECREF(str); +! Py_DECREF(list); +! return NULL; +! } + } + + /* The ownership of the Python list is passed to the caller (ie, +--- 3156,3162 ---- + return NULL; + } + +! PyList_SET_ITEM(list, i, str); + } + + /* The ownership of the Python list is passed to the caller (ie, +*************** +*** 5366,5373 **** + static int + populate_module(PyObject *m, object_adder add_object, attr_getter get_attr) + { +! int i; +! PyObject *os; + + for (i = 0; i < (int)(sizeof(numeric_constants) + / sizeof(struct numeric_constant)); +--- 5352,5359 ---- + static int + populate_module(PyObject *m, object_adder add_object, attr_getter get_attr) + { +! int i; +! PyObject *other_module; + + for (i = 0; i < (int)(sizeof(numeric_constants) + / sizeof(struct numeric_constant)); +*************** +*** 5395,5418 **** + ADD_CHECKED_OBJECT(m, "options", + OptionsNew(SREQ_GLOBAL, NULL, dummy_check, NULL)); + +! if (!(os = PyImport_ImportModule("os"))) + return -1; +! ADD_OBJECT(m, "os", os); + +! if (!(py_getcwd = PyObject_GetAttrString(os, "getcwd"))) + return -1; + ADD_OBJECT(m, "_getcwd", py_getcwd) + +! if (!(py_chdir = PyObject_GetAttrString(os, "chdir"))) + return -1; + ADD_OBJECT(m, "_chdir", py_chdir); +! if (PyObject_SetAttrString(os, "chdir", get_attr(m, "chdir"))) + return -1; + +! if ((py_fchdir = PyObject_GetAttrString(os, "fchdir"))) + { + ADD_OBJECT(m, "_fchdir", py_fchdir); +! if (PyObject_SetAttrString(os, "fchdir", get_attr(m, "fchdir"))) + return -1; + } + else +--- 5381,5404 ---- + ADD_CHECKED_OBJECT(m, "options", + OptionsNew(SREQ_GLOBAL, NULL, dummy_check, NULL)); + +! if (!(other_module = PyImport_ImportModule("os"))) + return -1; +! ADD_OBJECT(m, "os", other_module); + +! if (!(py_getcwd = PyObject_GetAttrString(other_module, "getcwd"))) + return -1; + ADD_OBJECT(m, "_getcwd", py_getcwd) + +! if (!(py_chdir = PyObject_GetAttrString(other_module, "chdir"))) + return -1; + ADD_OBJECT(m, "_chdir", py_chdir); +! if (PyObject_SetAttrString(other_module, "chdir", get_attr(m, "chdir"))) + return -1; + +! if ((py_fchdir = PyObject_GetAttrString(other_module, "fchdir"))) + { + ADD_OBJECT(m, "_fchdir", py_fchdir); +! if (PyObject_SetAttrString(other_module,"fchdir",get_attr(m,"fchdir"))) + return -1; + } + else +*** ../vim-7.3.1160/src/version.c 2013-06-10 20:25:05.000000000 +0200 +--- src/version.c 2013-06-10 20:37:02.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1161, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +136. You decide to stay in a low-paying job teaching just for the + free Internet access. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d5bd53714d602b0ed23b1baa2cdd80957188f15d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:48 +0200 Subject: [PATCH 1054/3340] - patchlevel 1162 --- 7.3.1162 | 163 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 163 insertions(+) create mode 100644 7.3.1162 diff --git a/7.3.1162 b/7.3.1162 new file mode 100644 index 00000000..547f965c --- /dev/null +++ b/7.3.1162 @@ -0,0 +1,163 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1162 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1162 +Problem: Python: Memory leaks +Solution: Add more Py_DECREF(). (ZyX) +Files: src/if_py_both.h, src/if_python.c + + +*** ../vim-7.3.1161/src/if_py_both.h 2013-06-10 20:38:58.000000000 +0200 +--- src/if_py_both.h 2013-06-10 20:43:01.000000000 +0200 +*************** +*** 5354,5359 **** +--- 5354,5360 ---- + { + int i; + PyObject *other_module; ++ PyObject *attr; + + for (i = 0; i < (int)(sizeof(numeric_constants) + / sizeof(struct numeric_constant)); +*************** +*** 5392,5405 **** + if (!(py_chdir = PyObject_GetAttrString(other_module, "chdir"))) + return -1; + ADD_OBJECT(m, "_chdir", py_chdir); +! if (PyObject_SetAttrString(other_module, "chdir", get_attr(m, "chdir"))) + return -1; + + if ((py_fchdir = PyObject_GetAttrString(other_module, "fchdir"))) + { + ADD_OBJECT(m, "_fchdir", py_fchdir); +! if (PyObject_SetAttrString(other_module,"fchdir",get_attr(m,"fchdir"))) + return -1; + } + else + PyErr_Clear(); +--- 5393,5418 ---- + if (!(py_chdir = PyObject_GetAttrString(other_module, "chdir"))) + return -1; + ADD_OBJECT(m, "_chdir", py_chdir); +! if (!(attr = get_attr(m, "chdir"))) + return -1; ++ if (PyObject_SetAttrString(other_module, "chdir", attr)) ++ { ++ Py_DECREF(attr); ++ return -1; ++ } ++ Py_DECREF(attr); + + if ((py_fchdir = PyObject_GetAttrString(other_module, "fchdir"))) + { + ADD_OBJECT(m, "_fchdir", py_fchdir); +! if (!(attr = get_attr(m, "fchdir"))) +! return -1; +! if (PyObject_SetAttrString(other_module, "fchdir", attr)) +! { +! Py_DECREF(attr); + return -1; ++ } ++ Py_DECREF(attr); + } + else + PyErr_Clear(); +*** ../vim-7.3.1161/src/if_python.c 2013-06-10 18:36:20.000000000 +0200 +--- src/if_python.c 2013-06-10 20:42:44.000000000 +0200 +*************** +*** 210,215 **** +--- 210,216 ---- + # define PyMapping_Check dll_PyMapping_Check + # define PyIter_Next dll_PyIter_Next + # define PyModule_GetDict dll_PyModule_GetDict ++ # define PyModule_AddObject dll_PyModule_AddObject + # define PyRun_SimpleString dll_PyRun_SimpleString + # define PyRun_String dll_PyRun_String + # define PyObject_GetAttrString dll_PyObject_GetAttrString +*************** +*** 344,349 **** +--- 345,351 ---- + static int (*dll_PyMapping_Check)(PyObject *); + static PyObject* (*dll_PyIter_Next)(PyObject *); + static PyObject*(*dll_PyModule_GetDict)(PyObject *); ++ static int(*dll_PyModule_AddObject)(PyObject *, const char *, PyObject *); + static int(*dll_PyRun_SimpleString)(char *); + static PyObject *(*dll_PyRun_String)(char *, int, PyObject *, PyObject *); + static PyObject* (*dll_PyObject_GetAttrString)(PyObject *, const char *); +*************** +*** 509,514 **** +--- 511,517 ---- + {"PyMapping_Check", (PYTHON_PROC*)&dll_PyMapping_Check}, + {"PyIter_Next", (PYTHON_PROC*)&dll_PyIter_Next}, + {"PyModule_GetDict", (PYTHON_PROC*)&dll_PyModule_GetDict}, ++ {"PyModule_AddObject", (PYTHON_PROC*)&dll_PyModule_AddObject}, + {"PyRun_SimpleString", (PYTHON_PROC*)&dll_PyRun_SimpleString}, + {"PyRun_String", (PYTHON_PROC*)&dll_PyRun_String}, + {"PyObject_GetAttrString", (PYTHON_PROC*)&dll_PyObject_GetAttrString}, +*************** +*** 1357,1375 **** + #endif + + static int +- add_object(PyObject *dict, const char *name, PyObject *object) +- { +- if (PyDict_SetItemString(dict, (char *) name, object)) +- return -1; +- Py_DECREF(object); +- return 0; +- } +- +- static int + PythonMod_Init(void) + { + PyObject *mod; +- PyObject *dict; + + /* The special value is removed from sys.path in Python_Init(). */ + static char *(argv[2]) = {"/must>not&exist/foo", NULL}; +--- 1360,1368 ---- +*************** +*** 1382,1390 **** + + mod = Py_InitModule4("vim", VimMethods, (char *)NULL, (PyObject *)NULL, + PYTHON_API_VERSION); +- dict = PyModule_GetDict(mod); + +! return populate_module(dict, add_object, PyDict_GetItemString); + } + + /************************************************************************* +--- 1375,1382 ---- + + mod = Py_InitModule4("vim", VimMethods, (char *)NULL, (PyObject *)NULL, + PYTHON_API_VERSION); + +! return populate_module(mod, PyModule_AddObject, PyObject_GetAttrString); + } + + /************************************************************************* +*** ../vim-7.3.1161/src/version.c 2013-06-10 20:38:58.000000000 +0200 +--- src/version.c 2013-06-10 20:40:25.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1162, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +137. You decide to stay in college for an additional year or two, + just so you can have the free Internet access. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 828576ebcb890715b92aed92c519a99cf00d1ff6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:49 +0200 Subject: [PATCH 1055/3340] - patchlevel 1163 --- 7.3.1163 | 1313 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1313 insertions(+) create mode 100644 7.3.1163 diff --git a/7.3.1163 b/7.3.1163 new file mode 100644 index 00000000..35d92708 --- /dev/null +++ b/7.3.1163 @@ -0,0 +1,1313 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1163 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1163 +Problem: Not easy to load Python modules. +Solution: Search "python2", "python3" and "pythonx" directories in + 'runtimepath' for Python modules. (ZyX) +Files: runtime/doc/if_pyth.txt, src/configure.in, src/ex_cmds2.c, + src/if_py_both.h, src/if_python.c, src/if_python3.c, + src/testdir/test86.in, src/testdir/test87.in, src/auto/configure + + +*** ../vim-7.3.1162/runtime/doc/if_pyth.txt 2013-06-02 18:20:12.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-06-10 20:51:21.000000000 +0200 +*************** +*** 180,185 **** +--- 180,191 ---- + Like |strwidth()|: returns number of display cells str occupies, tab + is counted as one cell. + ++ vim.foreach_rtp(callable) *python-foreach_rtp* ++ Call the given callable for each path in 'runtimepath' until either ++ callable returns something but None, the exception is raised or there ++ are no longer paths. If stopped in case callable returned non-None, ++ vim.foreach_rtp function returns the value returned by callable. ++ + vim.chdir(*args, **kwargs) *python-chdir* + vim.fchdir(*args, **kwargs) *python-fchdir* + Run os.chdir or os.fchdir, then all appropriate vim stuff. +*************** +*** 300,305 **** +--- 306,418 ---- + supported, and may cause the program to crash. This should probably be + fixed. + ++ *python2-directory* *python3-directory* *pythonx-directory* ++ Python 'runtimepath' handling *python-special-path* ++ ++ In python vim.VIM_SPECIAL_PATH special directory is used as a replacement for ++ the list of paths found in 'runtimepath': with this directory in sys.path and ++ vim.path_hooks in sys.path_hooks python will try to load module from ++ {rtp}/python2 (or python3) and {rtp}/pythonx (for both python versions) for ++ each {rtp} found in 'runtimepath'. ++ ++ Implementation for python 2 is the following: usual importing code with empty ++ lists in place of sys.path_hooks and sys.meta_path. Code is similar to the ++ below, but written in C: > ++ ++ # Assuming vim variable is already accessible and is set to the current ++ # module ++ import sys ++ ++ def find_module(fullname): ++ return vim ++ ++ def load_module(fullname): ++ # see vim._get_paths below ++ new_path = _get_paths() ++ ++ try: old_path = sys.path ++ except: pass ++ try: old_meta_path = sys.meta_path ++ except: pass ++ try: old_path_hooks = sys.path_hooks ++ except: pass ++ ++ sys.meta_path = [] ++ sys.path_hooks = sys.meta_path ++ sys.path = new_path ++ ++ try: ++ exec ('import ' + fullname + ' as m') # No actual exec in C code ++ return m ++ finally: ++ e = None ++ try: sys.path = old_path ++ except Exception as e: pass ++ try: sys.meta_path = old_meta_path ++ except Exception as e: pass ++ try: sys.path_hooks = old_path_hooks ++ except Exception as e: pass ++ if e: ++ raise e ++ ++ def path_hook(d): ++ if d == VIM_SPECIAL_PATH: ++ return vim ++ raise ImportError ++ ++ sys.path_hooks.append(path_hook) ++ ++ Implementation for python 3 is cleaner: code is similar to the following, but, ++ again, written in C: > ++ ++ from importlib.machinery import PathFinder ++ import sys ++ ++ class Finder(PathFinder): ++ @classmethod ++ def find_module(cls, fullname): ++ # see vim._get_paths below ++ new_path = _get_paths() ++ ++ # super().find_module is also a class method ++ # super() is not used because this variant is easier to implement ++ # in C ++ return PathFinder.find_module(fullname, new_path) ++ ++ def path_hook(path): ++ if path == VIM_SPECIAL_PATH: ++ return Finder ++ raise ImportError ++ ++ sys.path_hooks.append(path_hook) ++ ++ vim.VIM_SPECIAL_PATH *python-VIM_SPECIAL_PATH* ++ String constant used in conjunction with vim path hook. If path hook ++ installed by vim is requested to handle anything but path equal to ++ vim.VIM_SPECIAL_PATH constant it raises ImportError. In the only other ++ case it uses special loader. ++ ++ Note: you must not use value of this constant directly, always use ++ vim.VIM_SPECIAL_PATH object. ++ ++ vim.load_module(name) *python-load_module* ++ vim.find_module(...) *python-find_module* ++ vim.path_hook(path) *python-path_hook* ++ Methods or objects used to implement path loading as described above. ++ You should not be using any of these directly except for vim.path_hook ++ in case you need to do something with sys.meta_path. It is not ++ guaranteed that any of the objects will exist in the future vim ++ versions. In fact, load_module and find_module methods do not exists ++ in python3. ++ ++ vim._get_paths *python-_get_paths* ++ Methods returning a list of paths which will be searched for by path ++ hook. You should not rely on this method being present in future ++ versions, but can use it for debugging. ++ ++ It returns a list of {rtp}/python2 (or {rtp}/python3) and ++ {rtp}/pythonx directories for each {rtp} in 'runtimepath'. ++ + ============================================================================== + 3. Buffer objects *python-buffer* + +*************** +*** 340,346 **** + |BufFilePost| autocommands are launched. + b.number Buffer number. Can be used as |python-buffers| key. + Read-only. +! b.valid True or False. Buffer object becames invalid when + corresponding buffer is wiped out. + + The buffer object methods are: +--- 453,459 ---- + |BufFilePost| autocommands are launched. + b.number Buffer number. Can be used as |python-buffers| key. + Read-only. +! b.valid True or False. Buffer object becomes invalid when + corresponding buffer is wiped out. + + The buffer object methods are: +*************** +*** 446,452 **** + row, col (read-only) On-screen window position in display cells. + First position is zero. + tabpage (read-only) Window tab page. +! valid (read-write) True or False. Window object becames invalid + when corresponding window is closed. + + The height attribute is writable only if the screen is split horizontally. +--- 559,565 ---- + row, col (read-only) On-screen window position in display cells. + First position is zero. + tabpage (read-only) Window tab page. +! valid (read-write) True or False. Window object becomes invalid + when corresponding window is closed. + + The height attribute is writable only if the screen is split horizontally. +*************** +*** 471,477 **** + windows Like |python-windows|, but for current tab page. + vars The tab page |t:| variables. + window Current tabpage window. +! valid True or False. Tab page object becames invalid when + corresponding tab page is closed. + + TabPage object type is available using "TabPage" attribute of vim module. +--- 584,590 ---- + windows Like |python-windows|, but for current tab page. + vars The tab page |t:| variables. + window Current tabpage window. +! valid True or False. Tab page object becomes invalid when + corresponding tab page is closed. + + TabPage object type is available using "TabPage" attribute of vim module. +*** ../vim-7.3.1162/src/configure.in 2013-06-02 19:14:11.000000000 +0200 +--- src/configure.in 2013-06-10 20:51:21.000000000 +0200 +*************** +*** 863,872 **** + ${vi_cv_path_python} -c 'import sys; print sys.version[:3]'` + ]]) + +! dnl -- it must be at least version 2.2 +! AC_MSG_CHECKING(Python is 2.2 or better) + if ${vi_cv_path_python} -c \ +! "import sys; sys.exit(${vi_cv_var_python_version} < 2.2)" + then + AC_MSG_RESULT(yep) + +--- 863,872 ---- + ${vi_cv_path_python} -c 'import sys; print sys.version[:3]'` + ]]) + +! dnl -- it must be at least version 2.3 +! AC_MSG_CHECKING(Python is 2.3 or better) + if ${vi_cv_path_python} -c \ +! "import sys; sys.exit(${vi_cv_var_python_version} < 2.3)" + then + AC_MSG_RESULT(yep) + +*** ../vim-7.3.1162/src/ex_cmds2.c 2013-06-10 20:10:40.000000000 +0200 +--- src/ex_cmds2.c 2013-06-10 20:51:21.000000000 +0200 +*************** +*** 2737,2742 **** +--- 2737,2746 ---- + * When "all" is TRUE repeat for all matches, otherwise only the first one is + * used. + * Returns OK when at least one match found, FAIL otherwise. ++ * ++ * If "name" is NULL calls callback for each entry in runtimepath. Cookie is ++ * passed by reference in this case, setting it to NULL indicates that callback ++ * has done its job. + */ + int + do_in_runtimepath(name, all, callback, cookie) +*************** +*** 2768,2774 **** + buf = alloc(MAXPATHL); + if (buf != NULL && rtp_copy != NULL) + { +! if (p_verbose > 1) + { + verbose_enter(); + smsg((char_u *)_("Searching for \"%s\" in \"%s\""), +--- 2772,2778 ---- + buf = alloc(MAXPATHL); + if (buf != NULL && rtp_copy != NULL) + { +! if (p_verbose > 1 && name != NULL) + { + verbose_enter(); + smsg((char_u *)_("Searching for \"%s\" in \"%s\""), +*************** +*** 2782,2788 **** + { + /* Copy the path from 'runtimepath' to buf[]. */ + copy_option_part(&rtp, buf, MAXPATHL, ","); +! if (STRLEN(buf) + STRLEN(name) + 2 < MAXPATHL) + { + add_pathsep(buf); + tail = buf + STRLEN(buf); +--- 2786,2798 ---- + { + /* Copy the path from 'runtimepath' to buf[]. */ + copy_option_part(&rtp, buf, MAXPATHL, ","); +! if (name == NULL) +! { +! (*callback)(buf, (void *) &cookie); +! if (!did_one) +! did_one = (cookie == NULL); +! } +! else if (STRLEN(buf) + STRLEN(name) + 2 < MAXPATHL) + { + add_pathsep(buf); + tail = buf + STRLEN(buf); +*************** +*** 2821,2827 **** + } + vim_free(buf); + vim_free(rtp_copy); +! if (p_verbose > 0 && !did_one) + { + verbose_enter(); + smsg((char_u *)_("not found in 'runtimepath': \"%s\""), name); +--- 2831,2837 ---- + } + vim_free(buf); + vim_free(rtp_copy); +! if (p_verbose > 0 && !did_one && name != NULL) + { + verbose_enter(); + smsg((char_u *)_("not found in 'runtimepath': \"%s\""), name); +*** ../vim-7.3.1162/src/if_py_both.h 2013-06-10 20:47:33.000000000 +0200 +--- src/if_py_both.h 2013-06-10 20:55:17.000000000 +0200 +*************** +*** 24,29 **** +--- 24,31 ---- + #endif + #define DOPY_FUNC "_vim_pydo" + ++ static const char *vim_special_path = "_vim_path_"; ++ + #define PyErr_SetVim(str) PyErr_SetString(VimError, str) + + #define RAISE_NO_EMPTY_KEYS PyErr_SetString(PyExc_ValueError, \ +*************** +*** 55,60 **** +--- 57,64 ---- + static PyObject *py_chdir; + static PyObject *py_fchdir; + static PyObject *py_getcwd; ++ static PyObject *vim_module; ++ static PyObject *vim_special_path_object; + + /* + * obtain a lock on the Vim data structures +*************** +*** 779,797 **** + return _VimChdir(py_fchdir, args, kwargs); + } + + /* + * Vim module - Definitions + */ + + static struct PyMethodDef VimMethods[] = { +! /* name, function, calling, documentation */ +! {"command", VimCommand, METH_VARARGS, "Execute a Vim ex-mode command" }, +! {"eval", VimEval, METH_VARARGS, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, METH_VARARGS, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, METH_VARARGS, "Screen string width, counts as having width 1"}, +! {"chdir", (PyCFunction)VimChdir, METH_VARARGS|METH_KEYWORDS, "Change directory"}, +! {"fchdir", (PyCFunction)VimFchdir, METH_VARARGS|METH_KEYWORDS, "Change directory"}, +! { NULL, NULL, 0, NULL } + }; + + /* +--- 783,950 ---- + return _VimChdir(py_fchdir, args, kwargs); + } + ++ typedef struct { ++ PyObject *callable; ++ PyObject *result; ++ } map_rtp_data; ++ ++ static void ++ map_rtp_callback(char_u *path, void *_data) ++ { ++ void **data = (void **) _data; ++ PyObject *pathObject; ++ map_rtp_data *mr_data = *((map_rtp_data **) data); ++ ++ if (!(pathObject = PyString_FromString((char *) path))) ++ { ++ *data = NULL; ++ return; ++ } ++ ++ mr_data->result = PyObject_CallFunctionObjArgs(mr_data->callable, ++ pathObject, NULL); ++ ++ Py_DECREF(pathObject); ++ ++ if (!mr_data->result || mr_data->result != Py_None) ++ *data = NULL; ++ else ++ { ++ Py_DECREF(mr_data->result); ++ mr_data->result = NULL; ++ } ++ } ++ ++ static PyObject * ++ VimForeachRTP(PyObject *self UNUSED, PyObject *args) ++ { ++ map_rtp_data data; ++ ++ if (!PyArg_ParseTuple(args, "O", &data.callable)) ++ return NULL; ++ ++ data.result = NULL; ++ ++ do_in_runtimepath(NULL, FALSE, &map_rtp_callback, &data); ++ ++ if (data.result == NULL) ++ { ++ if (PyErr_Occurred()) ++ return NULL; ++ else ++ { ++ Py_INCREF(Py_None); ++ return Py_None; ++ } ++ } ++ return data.result; ++ } ++ ++ /* ++ * _vim_runtimepath_ special path implementation. ++ */ ++ ++ static void ++ map_finder_callback(char_u *path, void *_data) ++ { ++ void **data = (void **) _data; ++ PyObject *list = *((PyObject **) data); ++ PyObject *pathObject1, *pathObject2; ++ char *pathbuf; ++ size_t pathlen; ++ ++ pathlen = STRLEN(path); ++ ++ #if PY_MAJOR_VERSION < 3 ++ # define PY_MAIN_DIR_STRING "python2" ++ #else ++ # define PY_MAIN_DIR_STRING "python3" ++ #endif ++ #define PY_ALTERNATE_DIR_STRING "pythonx" ++ ++ #define PYTHONX_STRING_LENGTH 7 /* STRLEN("pythonx") */ ++ if (!(pathbuf = PyMem_New(char, ++ pathlen + STRLEN(PATHSEPSTR) + PYTHONX_STRING_LENGTH + 1))) ++ { ++ PyErr_NoMemory(); ++ *data = NULL; ++ return; ++ } ++ ++ mch_memmove(pathbuf, path, pathlen + 1); ++ add_pathsep((char_u *) pathbuf); ++ ++ pathlen = STRLEN(pathbuf); ++ mch_memmove(pathbuf + pathlen, PY_MAIN_DIR_STRING, ++ PYTHONX_STRING_LENGTH + 1); ++ ++ if (!(pathObject1 = PyString_FromString(pathbuf))) ++ { ++ *data = NULL; ++ PyMem_Free(pathbuf); ++ return; ++ } ++ ++ mch_memmove(pathbuf + pathlen, PY_ALTERNATE_DIR_STRING, ++ PYTHONX_STRING_LENGTH + 1); ++ ++ if (!(pathObject2 = PyString_FromString(pathbuf))) ++ { ++ Py_DECREF(pathObject1); ++ PyMem_Free(pathbuf); ++ *data = NULL; ++ return; ++ } ++ ++ PyMem_Free(pathbuf); ++ ++ if (PyList_Append(list, pathObject1) ++ || PyList_Append(list, pathObject2)) ++ *data = NULL; ++ ++ Py_DECREF(pathObject1); ++ Py_DECREF(pathObject2); ++ } ++ ++ static PyObject * ++ Vim_GetPaths(PyObject *self UNUSED) ++ { ++ PyObject *r; ++ ++ if (!(r = PyList_New(0))) ++ return NULL; ++ ++ do_in_runtimepath(NULL, FALSE, &map_finder_callback, r); ++ ++ if (PyErr_Occurred()) ++ { ++ Py_DECREF(r); ++ return NULL; ++ } ++ ++ return r; ++ } ++ + /* + * Vim module - Definitions + */ + + static struct PyMethodDef VimMethods[] = { +! /* name, function, calling, documentation */ +! {"command", VimCommand, METH_VARARGS, "Execute a Vim ex-mode command" }, +! {"eval", VimEval, METH_VARARGS, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, METH_VARARGS, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, METH_VARARGS, "Screen string width, counts as having width 1"}, +! {"chdir", (PyCFunction)VimChdir, METH_VARARGS|METH_KEYWORDS, "Change directory"}, +! {"fchdir", (PyCFunction)VimFchdir, METH_VARARGS|METH_KEYWORDS, "Change directory"}, +! {"foreach_rtp", VimForeachRTP, METH_VARARGS, "Call given callable for each path in &rtp"}, +! #if PY_MAJOR_VERSION < 3 +! {"find_module", FinderFindModule, METH_VARARGS, "Internal use only, returns loader object for any input it receives"}, +! {"load_module", LoaderLoadModule, METH_VARARGS, "Internal use only, tries importing the given module from &rtp by temporary mocking sys.path (to an rtp-based one) and unsetting sys.meta_path and sys.path_hooks"}, +! #endif +! {"path_hook", VimPathHook, METH_VARARGS, "Hook function to install in sys.path_hooks"}, +! {"_get_paths", (PyCFunction)Vim_GetPaths, METH_NOARGS, "Get &rtp-based additions to sys.path"}, +! { NULL, NULL, 0, NULL} + }; + + /* +*************** +*** 5036,5041 **** +--- 5189,5202 ---- + } CurrentObject; + static PyTypeObject CurrentType; + ++ #if PY_MAJOR_VERSION >= 3 ++ typedef struct ++ { ++ PyObject_HEAD ++ } FinderObject; ++ static PyTypeObject FinderType; ++ #endif ++ + static void + init_structs(void) + { +*************** +*** 5281,5286 **** +--- 5442,5522 ---- + PYTYPE_READY(FunctionType); + PYTYPE_READY(OptionsType); + PYTYPE_READY(OutputType); ++ #if PY_MAJOR_VERSION >= 3 ++ PYTYPE_READY(FinderType); ++ #endif ++ return 0; ++ } ++ ++ static int ++ init_sys_path() ++ { ++ PyObject *path; ++ PyObject *path_hook; ++ PyObject *path_hooks; ++ ++ if (!(path_hook = PyObject_GetAttrString(vim_module, "path_hook"))) ++ return -1; ++ ++ if (!(path_hooks = PySys_GetObject("path_hooks"))) ++ { ++ PyErr_Clear(); ++ path_hooks = PyList_New(1); ++ PyList_SET_ITEM(path_hooks, 0, path_hook); ++ if (PySys_SetObject("path_hooks", path_hooks)) ++ { ++ Py_DECREF(path_hooks); ++ return -1; ++ } ++ Py_DECREF(path_hooks); ++ } ++ else if (PyList_Check(path_hooks)) ++ { ++ if (PyList_Append(path_hooks, path_hook)) ++ { ++ Py_DECREF(path_hook); ++ return -1; ++ } ++ Py_DECREF(path_hook); ++ } ++ else ++ { ++ VimTryStart(); ++ EMSG(_("Failed to set path hook: sys.path_hooks is not a list\n" ++ "You should now do the following:\n" ++ "- append vim.path_hook to sys.path_hooks\n" ++ "- append vim.VIM_SPECIAL_PATH to sys.path\n")); ++ VimTryEnd(); /* Discard the error */ ++ Py_DECREF(path_hook); ++ return 0; ++ } ++ ++ if (!(path = PySys_GetObject("path"))) ++ { ++ PyErr_Clear(); ++ path = PyList_New(1); ++ Py_INCREF(vim_special_path_object); ++ PyList_SET_ITEM(path, 0, vim_special_path_object); ++ if (PySys_SetObject("path", path)) ++ { ++ Py_DECREF(path); ++ return -1; ++ } ++ Py_DECREF(path); ++ } ++ else if (PyList_Check(path)) ++ { ++ if (PyList_Append(path, vim_special_path_object)) ++ return -1; ++ } ++ else ++ { ++ VimTryStart(); ++ EMSG(_("Failed to set path: sys.path is not a list\n" ++ "You should now append vim.VIM_SPECIAL_PATH to sys.path")); ++ VimTryEnd(); /* Discard the error */ ++ } ++ + return 0; + } + +*************** +*** 5332,5337 **** +--- 5568,5576 ---- + {"List", (PyObject *)&ListType}, + {"Function", (PyObject *)&FunctionType}, + {"Options", (PyObject *)&OptionsType}, ++ #if PY_MAJOR_VERSION >= 3 ++ {"Finder", (PyObject *)&FinderType}, ++ #endif + }; + + typedef int (*object_adder)(PyObject *, const char *, PyObject *); +*************** +*** 5417,5421 **** +--- 5656,5672 ---- + else + PyErr_Clear(); + ++ if (!(vim_special_path_object = PyString_FromString(vim_special_path))) ++ return -1; ++ ++ ADD_OBJECT(m, "VIM_SPECIAL_PATH", vim_special_path_object); ++ ++ #if PY_MAJOR_VERSION >= 3 ++ ADD_OBJECT(m, "_PathFinder", path_finder); ++ ADD_CHECKED_OBJECT(m, "_find_module", ++ (py_find_module = PyObject_GetAttrString(path_finder, ++ "find_module"))); ++ #endif ++ + return 0; + } +*** ../vim-7.3.1162/src/if_python.c 2013-06-10 20:47:33.000000000 +0200 +--- src/if_python.c 2013-06-10 20:55:04.000000000 +0200 +*************** +*** 24,32 **** + /* uncomment this if used with the debug version of python. + * Checked on 2.7.4. */ + /* #define Py_DEBUG */ +! /* Note: most of time you can add -DPy_DEBUG to CFLAGS in place of uncommenting + */ +! /* uncomment this if used with the debug version of python, but without its + * allocator */ + /* #define Py_DEBUG_NO_PYMALLOC */ + +--- 24,32 ---- + /* uncomment this if used with the debug version of python. + * Checked on 2.7.4. */ + /* #define Py_DEBUG */ +! /* Note: most of time you can add -DPy_DEBUG to CFLAGS in place of uncommenting + */ +! /* uncomment this if used with the debug version of python, but without its + * allocator */ + /* #define Py_DEBUG_NO_PYMALLOC */ + +*************** +*** 168,173 **** +--- 168,174 ---- + # define PyErr_SetNone dll_PyErr_SetNone + # define PyErr_SetString dll_PyErr_SetString + # define PyErr_SetObject dll_PyErr_SetObject ++ # define PyErr_ExceptionMatches dll_PyErr_ExceptionMatches + # define PyEval_InitThreads dll_PyEval_InitThreads + # define PyEval_RestoreThread dll_PyEval_RestoreThread + # define PyEval_SaveThread dll_PyEval_SaveThread +*************** +*** 184,189 **** +--- 185,191 ---- + # define PyLong_Type (*dll_PyLong_Type) + # define PyList_GetItem dll_PyList_GetItem + # define PyList_Append dll_PyList_Append ++ # define PyList_Insert dll_PyList_Insert + # define PyList_New dll_PyList_New + # define PyList_SetItem dll_PyList_SetItem + # define PyList_Size dll_PyList_Size +*************** +*** 233,238 **** +--- 235,241 ---- + # define PyFloat_Type (*dll_PyFloat_Type) + # define PyImport_AddModule (*dll_PyImport_AddModule) + # define PySys_SetObject dll_PySys_SetObject ++ # define PySys_GetObject dll_PySys_GetObject + # define PySys_SetArgv dll_PySys_SetArgv + # define PyType_Type (*dll_PyType_Type) + # define PyType_Ready (*dll_PyType_Ready) +*************** +*** 305,310 **** +--- 308,314 ---- + static void(*dll_PyErr_SetNone)(PyObject *); + static void(*dll_PyErr_SetString)(PyObject *, const char *); + static void(*dll_PyErr_SetObject)(PyObject *, PyObject *); ++ static int(*dll_PyErr_ExceptionMatches)(PyObject *); + static void(*dll_PyEval_InitThreads)(void); + static void(*dll_PyEval_RestoreThread)(PyThreadState *); + static PyThreadState*(*dll_PyEval_SaveThread)(void); +*************** +*** 320,326 **** + static PyTypeObject* dll_PyInt_Type; + static PyTypeObject* dll_PyLong_Type; + static PyObject*(*dll_PyList_GetItem)(PyObject *, PyInt); +! static PyObject*(*dll_PyList_Append)(PyObject *, PyObject *); + static PyObject*(*dll_PyList_New)(PyInt size); + static int(*dll_PyList_SetItem)(PyObject *, PyInt, PyObject *); + static PyInt(*dll_PyList_Size)(PyObject *); +--- 324,331 ---- + static PyTypeObject* dll_PyInt_Type; + static PyTypeObject* dll_PyLong_Type; + static PyObject*(*dll_PyList_GetItem)(PyObject *, PyInt); +! static int(*dll_PyList_Append)(PyObject *, PyObject *); +! static int(*dll_PyList_Insert)(PyObject *, int, PyObject *); + static PyObject*(*dll_PyList_New)(PyInt size); + static int(*dll_PyList_SetItem)(PyObject *, PyInt, PyObject *); + static PyInt(*dll_PyList_Size)(PyObject *); +*************** +*** 366,371 **** +--- 371,377 ---- + static PyObject*(*dll_PyFloat_FromDouble)(double); + static PyTypeObject* dll_PyFloat_Type; + static int(*dll_PySys_SetObject)(char *, PyObject *); ++ static PyObject *(*dll_PySys_GetObject)(char *); + static int(*dll_PySys_SetArgv)(int, char **); + static PyTypeObject* dll_PyType_Type; + static int (*dll_PyType_Ready)(PyTypeObject *type); +*************** +*** 431,436 **** +--- 437,443 ---- + static PyObject *imp_PyExc_TypeError; + static PyObject *imp_PyExc_ValueError; + static PyObject *imp_PyExc_RuntimeError; ++ static PyObject *imp_PyExc_ImportError; + + # define PyExc_AttributeError imp_PyExc_AttributeError + # define PyExc_IndexError imp_PyExc_IndexError +*************** +*** 439,444 **** +--- 446,452 ---- + # define PyExc_TypeError imp_PyExc_TypeError + # define PyExc_ValueError imp_PyExc_ValueError + # define PyExc_RuntimeError imp_PyExc_RuntimeError ++ # define PyExc_ImportError imp_PyExc_ImportError + + /* + * Table of name to function pointer of python. +*************** +*** 471,476 **** +--- 479,485 ---- + {"PyErr_SetNone", (PYTHON_PROC*)&dll_PyErr_SetNone}, + {"PyErr_SetString", (PYTHON_PROC*)&dll_PyErr_SetString}, + {"PyErr_SetObject", (PYTHON_PROC*)&dll_PyErr_SetObject}, ++ {"PyErr_ExceptionMatches", (PYTHON_PROC*)&dll_PyErr_ExceptionMatches}, + {"PyEval_InitThreads", (PYTHON_PROC*)&dll_PyEval_InitThreads}, + {"PyEval_RestoreThread", (PYTHON_PROC*)&dll_PyEval_RestoreThread}, + {"PyEval_SaveThread", (PYTHON_PROC*)&dll_PyEval_SaveThread}, +*************** +*** 487,492 **** +--- 496,502 ---- + {"PyLong_Type", (PYTHON_PROC*)&dll_PyLong_Type}, + {"PyList_GetItem", (PYTHON_PROC*)&dll_PyList_GetItem}, + {"PyList_Append", (PYTHON_PROC*)&dll_PyList_Append}, ++ {"PyList_Insert", (PYTHON_PROC*)&dll_PyList_Insert}, + {"PyList_New", (PYTHON_PROC*)&dll_PyList_New}, + {"PyList_SetItem", (PYTHON_PROC*)&dll_PyList_SetItem}, + {"PyList_Size", (PYTHON_PROC*)&dll_PyList_Size}, +*************** +*** 532,537 **** +--- 542,548 ---- + {"PyFloat_FromDouble", (PYTHON_PROC*)&dll_PyFloat_FromDouble}, + {"PyImport_AddModule", (PYTHON_PROC*)&dll_PyImport_AddModule}, + {"PySys_SetObject", (PYTHON_PROC*)&dll_PySys_SetObject}, ++ {"PySys_GetObject", (PYTHON_PROC*)&dll_PySys_GetObject}, + {"PySys_SetArgv", (PYTHON_PROC*)&dll_PySys_SetArgv}, + {"PyType_Type", (PYTHON_PROC*)&dll_PyType_Type}, + {"PyType_Ready", (PYTHON_PROC*)&dll_PyType_Ready}, +*************** +*** 706,711 **** +--- 717,723 ---- + imp_PyExc_TypeError = PyDict_GetItemString(exdict, "TypeError"); + imp_PyExc_ValueError = PyDict_GetItemString(exdict, "ValueError"); + imp_PyExc_RuntimeError = PyDict_GetItemString(exdict, "RuntimeError"); ++ imp_PyExc_ImportError = PyDict_GetItemString(exdict, "ImportError"); + Py_XINCREF(imp_PyExc_AttributeError); + Py_XINCREF(imp_PyExc_IndexError); + Py_XINCREF(imp_PyExc_KeyError); +*************** +*** 713,718 **** +--- 725,731 ---- + Py_XINCREF(imp_PyExc_TypeError); + Py_XINCREF(imp_PyExc_ValueError); + Py_XINCREF(imp_PyExc_RuntimeError); ++ Py_XINCREF(imp_PyExc_ImportError); + Py_XDECREF(exmod); + } + #endif /* DYNAMIC_PYTHON */ +*************** +*** 735,740 **** +--- 748,757 ---- + static PyObject *ListGetattr(PyObject *, char *); + static PyObject *FunctionGetattr(PyObject *, char *); + ++ static PyObject *LoaderLoadModule(PyObject *, PyObject *); ++ static PyObject *FinderFindModule(PyObject *, PyObject *); ++ static PyObject *VimPathHook(PyObject *, PyObject *); ++ + #ifndef Py_VISIT + # define Py_VISIT(obj) visit(obj, arg) + #endif +*************** +*** 1359,1369 **** + } + #endif + + static int + PythonMod_Init(void) + { +- PyObject *mod; +- + /* The special value is removed from sys.path in Python_Init(). */ + static char *(argv[2]) = {"/must>not&exist/foo", NULL}; + +--- 1376,1487 ---- + } + #endif + ++ static PyObject * ++ LoaderLoadModule(PyObject *self, PyObject *args) ++ { ++ char *fullname; ++ PyObject *path; ++ PyObject *meta_path; ++ PyObject *path_hooks; ++ PyObject *new_path; ++ PyObject *r; ++ PyObject *new_list; ++ ++ if (!PyArg_ParseTuple(args, "s", &fullname)) ++ return NULL; ++ ++ if (!(new_path = Vim_GetPaths(self))) ++ return NULL; ++ ++ if (!(new_list = PyList_New(0))) ++ return NULL; ++ ++ #define GET_SYS_OBJECT(objstr, obj) \ ++ obj = PySys_GetObject(objstr); \ ++ PyErr_Clear(); \ ++ Py_XINCREF(obj); ++ ++ GET_SYS_OBJECT("meta_path", meta_path); ++ if (PySys_SetObject("meta_path", new_list)) ++ { ++ Py_XDECREF(meta_path); ++ Py_DECREF(new_list); ++ return NULL; ++ } ++ Py_DECREF(new_list); /* Now it becomes a reference borrowed from ++ sys.meta_path */ ++ ++ #define RESTORE_SYS_OBJECT(objstr, obj) \ ++ if (obj) \ ++ { \ ++ PySys_SetObject(objstr, obj); \ ++ Py_DECREF(obj); \ ++ } ++ ++ GET_SYS_OBJECT("path_hooks", path_hooks); ++ if (PySys_SetObject("path_hooks", new_list)) ++ { ++ RESTORE_SYS_OBJECT("meta_path", meta_path); ++ Py_XDECREF(path_hooks); ++ return NULL; ++ } ++ ++ GET_SYS_OBJECT("path", path); ++ if (PySys_SetObject("path", new_path)) ++ { ++ RESTORE_SYS_OBJECT("meta_path", meta_path); ++ RESTORE_SYS_OBJECT("path_hooks", path_hooks); ++ Py_XDECREF(path); ++ return NULL; ++ } ++ Py_DECREF(new_path); ++ ++ r = PyImport_ImportModule(fullname); ++ ++ RESTORE_SYS_OBJECT("meta_path", meta_path); ++ RESTORE_SYS_OBJECT("path_hooks", path_hooks); ++ RESTORE_SYS_OBJECT("path", path); ++ ++ if (PyErr_Occurred()) ++ { ++ Py_XDECREF(r); ++ return NULL; ++ } ++ ++ return r; ++ } ++ ++ static PyObject * ++ FinderFindModule(PyObject *self UNUSED, PyObject *args UNUSED) ++ { ++ /* ++ * Don't bother actually finding the module, it is delegated to the "loader" ++ * object (which is basically the same object: vim module). ++ */ ++ Py_INCREF(vim_module); ++ return vim_module; ++ } ++ ++ static PyObject * ++ VimPathHook(PyObject *self UNUSED, PyObject *args) ++ { ++ char *path; ++ ++ if (PyArg_ParseTuple(args, "s", &path) ++ && STRCMP(path, vim_special_path) == 0) ++ { ++ Py_INCREF(vim_module); ++ return vim_module; ++ } ++ ++ PyErr_Clear(); ++ PyErr_SetNone(PyExc_ImportError); ++ return NULL; ++ } ++ + static int + PythonMod_Init(void) + { + /* The special value is removed from sys.path in Python_Init(). */ + static char *(argv[2]) = {"/must>not&exist/foo", NULL}; + +*************** +*** 1373,1382 **** + /* Set sys.argv[] to avoid a crash in warn(). */ + PySys_SetArgv(1, argv); + +! mod = Py_InitModule4("vim", VimMethods, (char *)NULL, (PyObject *)NULL, +! PYTHON_API_VERSION); + +! return populate_module(mod, PyModule_AddObject, PyObject_GetAttrString); + } + + /************************************************************************* +--- 1491,1507 ---- + /* Set sys.argv[] to avoid a crash in warn(). */ + PySys_SetArgv(1, argv); + +! vim_module = Py_InitModule4("vim", VimMethods, (char *)NULL, +! (PyObject *)NULL, PYTHON_API_VERSION); +! +! if (populate_module(vim_module, PyModule_AddObject, +! PyObject_GetAttrString)) +! return -1; +! +! if (init_sys_path()) +! return -1; + +! return 0; + } + + /************************************************************************* +*** ../vim-7.3.1162/src/if_python3.c 2013-06-10 18:36:20.000000000 +0200 +--- src/if_python3.c 2013-06-10 20:55:44.000000000 +0200 +*************** +*** 134,139 **** +--- 134,140 ---- + # define PyErr_SetNone py3_PyErr_SetNone + # define PyErr_SetString py3_PyErr_SetString + # define PyErr_SetObject py3_PyErr_SetObject ++ # define PyErr_ExceptionMatches py3_PyErr_ExceptionMatches + # define PyEval_InitThreads py3_PyEval_InitThreads + # define PyEval_RestoreThread py3_PyEval_RestoreThread + # define PyEval_SaveThread py3_PyEval_SaveThread +*************** +*** 143,148 **** +--- 144,150 ---- + # define PyLong_FromLong py3_PyLong_FromLong + # define PyList_GetItem py3_PyList_GetItem + # define PyList_Append py3_PyList_Append ++ # define PyList_Insert py3_PyList_Insert + # define PyList_New py3_PyList_New + # define PyList_SetItem py3_PyList_SetItem + # define PyList_Size py3_PyList_Size +*************** +*** 177,182 **** +--- 179,185 ---- + # define PyEval_GetLocals py3_PyEval_GetLocals + # define PyEval_GetGlobals py3_PyEval_GetGlobals + # define PySys_SetObject py3_PySys_SetObject ++ # define PySys_GetObject py3_PySys_GetObject + # define PySys_SetArgv py3_PySys_SetArgv + # define PyType_Ready py3_PyType_Ready + #undef Py_BuildValue +*************** +*** 268,274 **** + static PyGILState_STATE (*py3_PyGILState_Ensure)(void); + static void (*py3_PyGILState_Release)(PyGILState_STATE); + static int (*py3_PySys_SetObject)(char *, PyObject *); +! static PyObject* (*py3_PyList_Append)(PyObject *, PyObject *); + static Py_ssize_t (*py3_PyList_Size)(PyObject *); + static int (*py3_PySequence_Check)(PyObject *); + static Py_ssize_t (*py3_PySequence_Size)(PyObject *); +--- 271,279 ---- + static PyGILState_STATE (*py3_PyGILState_Ensure)(void); + static void (*py3_PyGILState_Release)(PyGILState_STATE); + static int (*py3_PySys_SetObject)(char *, PyObject *); +! static PyObject* (*py3_PySys_GetObject)(char *); +! static int (*py3_PyList_Append)(PyObject *, PyObject *); +! static int (*py3_PyList_Insert)(PyObject *, int, PyObject *); + static Py_ssize_t (*py3_PyList_Size)(PyObject *); + static int (*py3_PySequence_Check)(PyObject *); + static Py_ssize_t (*py3_PySequence_Size)(PyObject *); +*************** +*** 284,289 **** +--- 289,295 ---- + static void (*py3_Py_Finalize)(void); + static void (*py3_PyErr_SetString)(PyObject *, const char *); + static void (*py3_PyErr_SetObject)(PyObject *, PyObject *); ++ static int (*py3_PyErr_ExceptionMatches)(PyObject *); + static int (*py3_PyRun_SimpleString)(char *); + static PyObject* (*py3_PyRun_String)(char *, int, PyObject *, PyObject *); + static PyObject* (*py3_PyObject_GetAttrString)(PyObject *, const char *); +*************** +*** 393,398 **** +--- 399,405 ---- + static PyObject *p3imp_PyExc_TypeError; + static PyObject *p3imp_PyExc_ValueError; + static PyObject *p3imp_PyExc_RuntimeError; ++ static PyObject *p3imp_PyExc_ImportError; + + # define PyExc_AttributeError p3imp_PyExc_AttributeError + # define PyExc_IndexError p3imp_PyExc_IndexError +*************** +*** 401,406 **** +--- 408,414 ---- + # define PyExc_TypeError p3imp_PyExc_TypeError + # define PyExc_ValueError p3imp_PyExc_ValueError + # define PyExc_RuntimeError p3imp_PyExc_RuntimeError ++ # define PyExc_ImportError p3imp_PyExc_ImportError + + /* + * Table of name to function pointer of python. +*************** +*** 428,434 **** +--- 436,444 ---- + {"PyGILState_Ensure", (PYTHON_PROC*)&py3_PyGILState_Ensure}, + {"PyGILState_Release", (PYTHON_PROC*)&py3_PyGILState_Release}, + {"PySys_SetObject", (PYTHON_PROC*)&py3_PySys_SetObject}, ++ {"PySys_GetObject", (PYTHON_PROC*)&py3_PySys_GetObject}, + {"PyList_Append", (PYTHON_PROC*)&py3_PyList_Append}, ++ {"PyList_Insert", (PYTHON_PROC*)&py3_PyList_Insert}, + {"PyList_Size", (PYTHON_PROC*)&py3_PyList_Size}, + {"PySequence_Check", (PYTHON_PROC*)&py3_PySequence_Check}, + {"PySequence_Size", (PYTHON_PROC*)&py3_PySequence_Size}, +*************** +*** 441,446 **** +--- 451,457 ---- + {"Py_Finalize", (PYTHON_PROC*)&py3_Py_Finalize}, + {"PyErr_SetString", (PYTHON_PROC*)&py3_PyErr_SetString}, + {"PyErr_SetObject", (PYTHON_PROC*)&py3_PyErr_SetObject}, ++ {"PyErr_ExceptionMatches", (PYTHON_PROC*)&py3_PyErr_ExceptionMatches}, + {"PyRun_SimpleString", (PYTHON_PROC*)&py3_PyRun_SimpleString}, + {"PyRun_String", (PYTHON_PROC*)&py3_PyRun_String}, + {"PyObject_GetAttrString", (PYTHON_PROC*)&py3_PyObject_GetAttrString}, +*************** +*** 664,669 **** +--- 675,681 ---- + p3imp_PyExc_TypeError = PyDict_GetItemString(exdict, "TypeError"); + p3imp_PyExc_ValueError = PyDict_GetItemString(exdict, "ValueError"); + p3imp_PyExc_RuntimeError = PyDict_GetItemString(exdict, "RuntimeError"); ++ p3imp_PyExc_ImportError = PyDict_GetItemString(exdict, "ImportError"); + Py_XINCREF(p3imp_PyExc_AttributeError); + Py_XINCREF(p3imp_PyExc_IndexError); + Py_XINCREF(p3imp_PyExc_KeyError); +*************** +*** 671,676 **** +--- 683,689 ---- + Py_XINCREF(p3imp_PyExc_TypeError); + Py_XINCREF(p3imp_PyExc_ValueError); + Py_XINCREF(p3imp_PyExc_RuntimeError); ++ Py_XINCREF(p3imp_PyExc_ImportError); + Py_XDECREF(exmod); + } + #endif /* DYNAMIC_PYTHON3 */ +*************** +*** 723,730 **** +--- 736,748 ---- + static int ListSetattro(PyObject *, PyObject *, PyObject *); + static PyObject *FunctionGetattro(PyObject *, PyObject *); + ++ static PyObject *VimPathHook(PyObject *, PyObject *); ++ + static struct PyModuleDef vimmodule; + ++ static PyObject *path_finder; ++ static PyObject *py_find_module = NULL; ++ + #define PY_CAN_RECURSE + + /* +*************** +*** 1585,1596 **** + #endif + + static PyObject * +! Py3Init_vim(void) + { +! PyObject *mod; + + /* The special value is removed from sys.path in Python3_Init(). */ + static wchar_t *(argv[2]) = {L"/must>not&exist/foo", NULL}; + + if (init_types()) + return NULL; +--- 1603,1672 ---- + #endif + + static PyObject * +! VimPathHook(PyObject *self UNUSED, PyObject *args) + { +! char *path; +! +! if (PyArg_ParseTuple(args, "s", &path) +! && STRCMP(path, vim_special_path) == 0) +! { +! Py_INCREF(&FinderType); +! return (PyObject *) &FinderType; +! } +! +! PyErr_Clear(); +! PyErr_SetNone(PyExc_ImportError); +! return NULL; +! } +! +! static PyObject * +! FinderFindModule(PyObject *cls UNUSED, PyObject *fullname) +! { +! PyObject *new_path; +! PyObject *r; +! +! if (!(new_path = Vim_GetPaths(NULL))) +! return NULL; +! +! /* call find_module of the super() class */ +! r = PyObject_CallFunctionObjArgs(py_find_module, fullname, new_path, NULL); +! +! Py_DECREF(new_path); +! +! return r; +! } + ++ static struct PyMethodDef FinderMethods[] = { ++ {"find_module", FinderFindModule, METH_CLASS|METH_O, ""}, ++ {NULL, NULL, 0, NULL} ++ }; ++ ++ static PyObject * ++ Py3Init_vim(void) ++ { + /* The special value is removed from sys.path in Python3_Init(). */ + static wchar_t *(argv[2]) = {L"/must>not&exist/foo", NULL}; ++ PyObject *importlib_machinery; ++ ++ if (!(importlib_machinery = PyImport_ImportModule("importlib.machinery"))) ++ return NULL; ++ ++ if (!(path_finder = PyObject_GetAttrString(importlib_machinery, ++ "PathFinder"))) ++ { ++ Py_DECREF(importlib_machinery); ++ return NULL; ++ } ++ ++ Py_DECREF(importlib_machinery); ++ ++ vim_memset(&FinderType, 0, sizeof(FinderObject)); ++ FinderType.tp_name = "vim.Finder"; ++ FinderType.tp_basicsize = sizeof(FinderObject); ++ FinderType.tp_base = (PyTypeObject *) path_finder; ++ FinderType.tp_flags = Py_TPFLAGS_DEFAULT; ++ FinderType.tp_doc = "Vim finder class, for use with path hook"; ++ FinderType.tp_methods = FinderMethods; + + if (init_types()) + return NULL; +*************** +*** 1598,1611 **** + /* Set sys.argv[] to avoid a crash in warn(). */ + PySys_SetArgv(1, argv); + +! mod = PyModule_Create(&vimmodule); +! if (mod == NULL) + return NULL; + +! if (populate_module(mod, PyModule_AddObject, PyObject_GetAttrString)) + return NULL; + +! return mod; + } + + /************************************************************************* +--- 1674,1689 ---- + /* Set sys.argv[] to avoid a crash in warn(). */ + PySys_SetArgv(1, argv); + +! if ((vim_module = PyModule_Create(&vimmodule)) == NULL) +! return NULL; +! +! if (populate_module(vim_module, PyModule_AddObject, PyObject_GetAttrString)) + return NULL; + +! if (init_sys_path()) + return NULL; + +! return vim_module; + } + + /************************************************************************* +*** ../vim-7.3.1162/src/testdir/test86.in 2013-06-02 18:54:16.000000000 +0200 +--- src/testdir/test86.in 2013-06-10 21:05:44.000000000 +0200 +*************** +*** 1069,1074 **** +--- 1069,1082 ---- + ee('vim.current.xxx = True') + EOF + :" ++ :" Test import TODO: BROKEN ++ :"py << EOF ++ :"vim.options['rtp'] = os.getcwd().replace(',', '\\,').replace('\\', '\\\\') ++ :"from module import dir as d ++ :"from modulex import ddir ++ :"cb.append(d + ',' + ddir) ++ :"EOF ++ :" + :" Test exceptions + :fun Exe(e) + : execute a:e +*** ../vim-7.3.1162/src/testdir/test87.in 2013-06-02 18:54:16.000000000 +0200 +--- src/testdir/test87.in 2013-06-10 21:06:37.000000000 +0200 +*************** +*** 1036,1041 **** +--- 1036,1049 ---- + ee('vim.current.xxx = True') + EOF + :" ++ :" Test import TODO: BROKEN ++ :"py3 << EOF ++ :"vim.options['rtp'] = os.getcwd().replace(',', '\\,').replace('\\', '\\\\') ++ :"from module import dir as d ++ :"from modulex import ddir ++ :"cb.append(d + ',' + ddir) ++ :"EOF ++ :" + :" Test exceptions + :fun Exe(e) + : execute a:e +*** ../vim-7.3.1162/src/auto/configure 2013-06-02 19:14:11.000000000 +0200 +--- src/auto/configure 2013-06-10 21:22:52.000000000 +0200 +*************** +*** 5289,5298 **** + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_var_python_version" >&5 + $as_echo "$vi_cv_var_python_version" >&6; } + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python is 2.2 or better" >&5 +! $as_echo_n "checking Python is 2.2 or better... " >&6; } + if ${vi_cv_path_python} -c \ +! "import sys; sys.exit(${vi_cv_var_python_version} < 2.2)" + then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yep" >&5 + $as_echo "yep" >&6; } +--- 5289,5298 ---- + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_var_python_version" >&5 + $as_echo "$vi_cv_var_python_version" >&6; } + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python is 2.3 or better" >&5 +! $as_echo_n "checking Python is 2.3 or better... " >&6; } + if ${vi_cv_path_python} -c \ +! "import sys; sys.exit(${vi_cv_var_python_version} < 2.3)" + then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yep" >&5 + $as_echo "yep" >&6; } +*** ../vim-7.3.1162/src/version.c 2013-06-10 20:47:33.000000000 +0200 +--- src/version.c 2013-06-10 20:53:23.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1163, + /**/ + +-- +The coffee just wasn't strong enough to defend itself -- Tom Waits + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 80d5412ad201fcee8f46b6028c9506c5a98ab609 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:50 +0200 Subject: [PATCH 1056/3340] - patchlevel 1164 --- 7.3.1164 | 155 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 155 insertions(+) create mode 100644 7.3.1164 diff --git a/7.3.1164 b/7.3.1164 new file mode 100644 index 00000000..0f489839 --- /dev/null +++ b/7.3.1164 @@ -0,0 +1,155 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1164 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1164 +Problem: Can't test what is actually displayed on screen. +Solution: Add the screenchar() and screenattr() functions. +Files: src/eval.c, runtime/doc/eval.txt + + +*** ../vim-7.3.1163/src/eval.c 2013-06-10 20:10:40.000000000 +0200 +--- src/eval.c 2013-06-10 23:15:38.000000000 +0200 +*************** +*** 654,659 **** +--- 654,661 ---- + #ifdef FEAT_FLOAT + static void f_round __ARGS((typval_T *argvars, typval_T *rettv)); + #endif ++ static void f_screenattr __ARGS((typval_T *argvars, typval_T *rettv)); ++ static void f_screenchar __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_screencol __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_screenrow __ARGS((typval_T *argvars, typval_T *rettv)); + static void f_search __ARGS((typval_T *argvars, typval_T *rettv)); +*************** +*** 8037,8042 **** +--- 8039,8046 ---- + #ifdef FEAT_FLOAT + {"round", 1, 1, f_round}, + #endif ++ {"screenattr", 2, 2, f_screenattr}, ++ {"screenchar", 2, 2, f_screenchar}, + {"screencol", 0, 0, f_screencol}, + {"screenrow", 0, 0, f_screenrow}, + {"search", 1, 4, f_search}, +*************** +*** 15804,15809 **** +--- 15808,15866 ---- + #endif + + /* ++ * "screenattr()" function ++ */ ++ static void ++ f_screenattr(argvars, rettv) ++ typval_T *argvars UNUSED; ++ typval_T *rettv; ++ { ++ int row; ++ int col; ++ int c; ++ ++ row = get_tv_number_chk(&argvars[0], NULL) - 1; ++ col = get_tv_number_chk(&argvars[1], NULL) - 1; ++ if (row < 0 || row >= screen_Rows ++ || col < 0 || col >= screen_Columns) ++ c = -1; ++ else ++ c = ScreenAttrs[LineOffset[row] + col]; ++ rettv->vval.v_number = c; ++ } ++ ++ /* ++ * "screenchar()" function ++ */ ++ static void ++ f_screenchar(argvars, rettv) ++ typval_T *argvars UNUSED; ++ typval_T *rettv; ++ { ++ int row; ++ int col; ++ int off; ++ int c; ++ ++ row = get_tv_number_chk(&argvars[0], NULL) - 1; ++ col = get_tv_number_chk(&argvars[1], NULL) - 1; ++ if (row < 0 || row >= screen_Rows ++ || col < 0 || col >= screen_Columns) ++ c = -1; ++ else ++ { ++ off = LineOffset[row] + col; ++ #ifdef FEAT_MBYTE ++ if (enc_utf8 && ScreenLinesUC[off] != 0) ++ c = ScreenLinesUC[off]; ++ else ++ #endif ++ c = ScreenLines[off]; ++ } ++ rettv->vval.v_number = c; ++ } ++ ++ /* + * "screencol()" function + * + * First column is 1 to be consistent with virtcol(). +*** ../vim-7.3.1163/runtime/doc/eval.txt 2013-05-06 04:50:26.000000000 +0200 +--- runtime/doc/eval.txt 2013-06-11 18:39:17.000000000 +0200 +*************** +*** 1895,1900 **** +--- 1906,1913 ---- + resolve( {filename}) String get filename a shortcut points to + reverse( {list}) List reverse {list} in-place + round( {expr}) Float round off {expr} ++ screenattr( {row}, {col}) Number attribute at screen position ++ screenchar( {row}, {col}) Number character at screen position + screencol() Number current cursor column + screenrow() Number current cursor row + search( {pattern} [, {flags} [, {stopline} [, {timeout}]]]) +*************** +*** 4863,4868 **** +--- 4893,4913 ---- + < -5.0 + {only available when compiled with the |+float| feature} + ++ screenattr(row, col) *screenattr()* ++ Like screenchar(), but return the attribute. This is a rather ++ arbitrary number that can only be used to compare to the ++ attribute at other positions. ++ ++ screenchar(row, col) *screenchar()* ++ The result is a Number, which is the character at position ++ [row, col] on the screen. This works for every possible ++ screen position, also status lines, window separators and the ++ command line. The top left position is row one, column one ++ The character excludes composing characters. For double-byte ++ encodings it may only be the first byte. ++ This is mainly to be used for testing. ++ Returns -1 when row or col is out of range. ++ + screencol() *screencol()* + The result is a Number, which is the current screen column of + the cursor. The leftmost column has number 1. +*** ../vim-7.3.1163/src/version.c 2013-06-10 21:27:18.000000000 +0200 +--- src/version.c 2013-06-11 18:36:46.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1164, + /**/ + +-- +Fingers not found - Pound head on keyboard to continue. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 916c484951e8fd04b7d7130f1d3ed8799f5979d7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:51 +0200 Subject: [PATCH 1057/3340] - patchlevel 1165 --- 7.3.1165 | 73 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 7.3.1165 diff --git a/7.3.1165 b/7.3.1165 new file mode 100644 index 00000000..b1d03573 --- /dev/null +++ b/7.3.1165 @@ -0,0 +1,73 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1165 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1165 +Problem: HP-UX compiler can't handle zero size array. (Charles Cooper) +Solution: Make the array one item big. +Files: src/regexp.h, src/regexp_nfa.c + + +*** ../vim-7.3.1164/src/regexp.h 2013-06-08 18:19:39.000000000 +0200 +--- src/regexp.h 2013-06-11 10:53:14.000000000 +0200 +*************** +*** 101,107 **** + #endif + int nsubexp; /* number of () */ + int nstate; +! nfa_state_T state[0]; /* actually longer.. */ + } nfa_regprog_T; + + /* +--- 101,107 ---- + #endif + int nsubexp; /* number of () */ + int nstate; +! nfa_state_T state[1]; /* actually longer.. */ + } nfa_regprog_T; + + /* +*** ../vim-7.3.1164/src/regexp_nfa.c 2013-06-10 16:35:11.000000000 +0200 +--- src/regexp_nfa.c 2013-06-11 11:19:17.000000000 +0200 +*************** +*** 6391,6398 **** + */ + post2nfa(postfix, post_ptr, TRUE); + +! /* Space for compiled regexp */ +! prog_size = sizeof(nfa_regprog_T) + sizeof(nfa_state_T) * nstate; + prog = (nfa_regprog_T *)lalloc(prog_size, TRUE); + if (prog == NULL) + goto fail; +--- 6391,6398 ---- + */ + post2nfa(postfix, post_ptr, TRUE); + +! /* allocate the regprog with space for the compiled regexp */ +! prog_size = sizeof(nfa_regprog_T) + sizeof(nfa_state_T) * (nstate - 1); + prog = (nfa_regprog_T *)lalloc(prog_size, TRUE); + if (prog == NULL) + goto fail; +*** ../vim-7.3.1164/src/version.c 2013-06-11 18:40:06.000000000 +0200 +--- src/version.c 2013-06-11 18:41:47.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1165, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +145. You e-mail your boss, informing him you'll be late. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f7c25683010e3e4802fdfa0fc98cfcfb80d41a50 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:52 +0200 Subject: [PATCH 1058/3340] - patchlevel 1166 --- 7.3.1166 | 162 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 162 insertions(+) create mode 100644 7.3.1166 diff --git a/7.3.1166 b/7.3.1166 new file mode 100644 index 00000000..e71a0354 --- /dev/null +++ b/7.3.1166 @@ -0,0 +1,162 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1166 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1166 +Problem: Loading Python modules is not tested. +Solution: Enable commented-out tests, add missing files. (ZyX) +Files: src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok, + src/testdir/python2/module.py, src/testdir/python3/module.py, + src/testdir/pythonx/module.py, src/testdir/pythonx/modulex.py, + Filelist + + +*** ../vim-7.3.1165/src/testdir/test86.in 2013-06-10 21:27:18.000000000 +0200 +--- src/testdir/test86.in 2013-06-11 17:42:17.000000000 +0200 +*************** +*** 1069,1081 **** + ee('vim.current.xxx = True') + EOF + :" +! :" Test import TODO: BROKEN +! :"py << EOF +! :"vim.options['rtp'] = os.getcwd().replace(',', '\\,').replace('\\', '\\\\') +! :"from module import dir as d +! :"from modulex import ddir +! :"cb.append(d + ',' + ddir) +! :"EOF + :" + :" Test exceptions + :fun Exe(e) +--- 1069,1081 ---- + ee('vim.current.xxx = True') + EOF + :" +! :" Test import +! py << EOF +! vim.options['rtp'] = os.getcwd().replace(',', '\\,').replace('\\', '\\\\') +! from module import dir as d +! from modulex import ddir +! cb.append(d + ',' + ddir) +! EOF + :" + :" Test exceptions + :fun Exe(e) +*** ../vim-7.3.1165/src/testdir/test86.ok 2013-06-02 18:54:16.000000000 +0200 +--- src/testdir/test86.ok 2013-06-11 17:42:26.000000000 +0200 +*************** +*** 1083,1088 **** +--- 1083,1089 ---- + vim.current.window = True:(, TypeError('expected vim.Window object',)) + vim.current.tabpage = True:(, TypeError('expected vim.TabPage object',)) + vim.current.xxx = True:(, AttributeError('xxx',)) ++ 2,xx + vim.command("throw 'abc'"):(, error('abc',)) + Exe("throw 'def'"):(, error('def',)) + vim.eval("Exe('throw ''ghi''')"):(, error('ghi',)) +*** ../vim-7.3.1165/src/testdir/test87.in 2013-06-10 21:27:18.000000000 +0200 +--- src/testdir/test87.in 2013-06-11 17:42:38.000000000 +0200 +*************** +*** 1036,1048 **** + ee('vim.current.xxx = True') + EOF + :" +! :" Test import TODO: BROKEN +! :"py3 << EOF +! :"vim.options['rtp'] = os.getcwd().replace(',', '\\,').replace('\\', '\\\\') +! :"from module import dir as d +! :"from modulex import ddir +! :"cb.append(d + ',' + ddir) +! :"EOF + :" + :" Test exceptions + :fun Exe(e) +--- 1036,1048 ---- + ee('vim.current.xxx = True') + EOF + :" +! :" Test import +! py3 << EOF +! vim.options['rtp'] = os.getcwd().replace(',', '\\,').replace('\\', '\\\\') +! from module import dir as d +! from modulex import ddir +! cb.append(d + ',' + ddir) +! EOF + :" + :" Test exceptions + :fun Exe(e) +*** ../vim-7.3.1165/src/testdir/test87.ok 2013-06-02 18:54:16.000000000 +0200 +--- src/testdir/test87.ok 2013-06-11 17:42:55.000000000 +0200 +*************** +*** 1092,1097 **** +--- 1092,1098 ---- + vim.current.window = True:(, TypeError('expected vim.Window object',)) + vim.current.tabpage = True:(, TypeError('expected vim.TabPage object',)) + vim.current.xxx = True:(, AttributeError('xxx',)) ++ 3,xx + vim.command("throw 'abc'"):(, error('abc',)) + Exe("throw 'def'"):(, error('def',)) + vim.eval("Exe('throw ''ghi''')"):(, error('ghi',)) +*** ../vim-7.3.1165/src/testdir/python2/module.py 1970-01-01 01:00:00.000000000 +0100 +--- src/testdir/python2/module.py 2013-06-11 17:39:40.000000000 +0200 +*************** +*** 0 **** +--- 1 ---- ++ dir = '2' +*** ../vim-7.3.1165/src/testdir/python3/module.py 1970-01-01 01:00:00.000000000 +0100 +--- src/testdir/python3/module.py 2013-06-11 17:39:40.000000000 +0200 +*************** +*** 0 **** +--- 1 ---- ++ dir = '3' +*** ../vim-7.3.1165/src/testdir/pythonx/module.py 1970-01-01 01:00:00.000000000 +0100 +--- src/testdir/pythonx/module.py 2013-06-11 17:39:40.000000000 +0200 +*************** +*** 0 **** +--- 1 ---- ++ dir = 'x' +*** ../vim-7.3.1165/src/testdir/pythonx/modulex.py 1970-01-01 01:00:00.000000000 +0100 +--- src/testdir/pythonx/modulex.py 2013-06-11 17:39:40.000000000 +0200 +*************** +*** 0 **** +--- 1 ---- ++ ddir = 'xx' +*** ../vim-7.3.1165/Filelist 2013-05-19 19:16:25.000000000 +0200 +--- Filelist 2013-06-11 18:45:13.000000000 +0200 +*************** +*** 84,89 **** +--- 84,92 ---- + src/testdir/test49.vim \ + src/testdir/test60.vim \ + src/testdir/test83-tags? \ ++ src/testdir/python2/*.py \ ++ src/testdir/python3/*.py \ ++ src/testdir/pythonx/*.py \ + src/proto.h \ + src/proto/blowfish.pro \ + src/proto/buffer.pro \ +*** ../vim-7.3.1165/src/version.c 2013-06-11 18:42:28.000000000 +0200 +--- src/version.c 2013-06-11 18:44:06.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1166, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +146. You experience ACTUAL physical withdrawal symptoms when away + from your 'puter and the net. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2026185b0e6aefdda43fa503e00e42b7bc361971 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:53 +0200 Subject: [PATCH 1059/3340] - patchlevel 1167 --- 7.3.1167 | 889 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 889 insertions(+) create mode 100644 7.3.1167 diff --git a/7.3.1167 b/7.3.1167 new file mode 100644 index 00000000..6deb0a00 --- /dev/null +++ b/7.3.1167 @@ -0,0 +1,889 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1167 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1167 +Problem: Python configure check doesn't reject Python 2 when requesting + Python 3. Some systems need -pthreads instead of -pthread. +Solution: Adjust configure accordingly. (Andrei Olsen) +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.1166/src/configure.in 2013-06-10 21:27:18.000000000 +0200 +--- src/configure.in 2013-06-11 19:49:52.000000000 +0200 +*************** +*** 986,991 **** +--- 986,994 ---- + threadsafe_flag="-D_THREAD_SAFE" + thread_lib="-pthread" + fi ++ if test "`(uname) 2>/dev/null`" = SunOS; then ++ threadsafe_flag="-pthreads" ++ fi + fi + libs_save_old=$LIBS + if test -n "$threadsafe_flag"; then +*************** +*** 1022,1028 **** + PYTHON_LIBS= + PYTHON_CFLAGS= + fi +- + fi + else + AC_MSG_RESULT(too old) +--- 1025,1030 ---- +*************** +*** 1058,1135 **** + ${vi_cv_path_python3} -c 'import sys; print(sys.version[:3])'` + ]]) + +! dnl -- get abiflags for python 3.2 or higher (PEP 3149) +! AC_CACHE_CHECK(Python's abiflags,vi_cv_var_python3_abiflags, +! [ +! vi_cv_var_python3_abiflags= +! if ${vi_cv_path_python3} -c \ +! "import sys; sys.exit(${vi_cv_var_python3_version} < 3.2)" +! then +! vi_cv_var_python3_abiflags=`${vi_cv_path_python3} -c \ +! "import sys; print(sys.abiflags)"` +! fi ]) +! +! dnl -- find where python3 thinks it was installed +! AC_CACHE_CHECK(Python's install prefix,vi_cv_path_python3_pfx, +! [ vi_cv_path_python3_pfx=` +! ${vi_cv_path_python3} -c \ +! "import sys; print(sys.prefix)"` ]) +! +! dnl -- and where it thinks it runs +! AC_CACHE_CHECK(Python's execution prefix,vi_cv_path_python3_epfx, +! [ vi_cv_path_python3_epfx=` +! ${vi_cv_path_python3} -c \ +! "import sys; print(sys.exec_prefix)"` ]) +! +! dnl -- python3's internal library path +! +! AC_CACHE_VAL(vi_cv_path_python3path, +! [ vi_cv_path_python3path=` +! unset PYTHONPATH; +! ${vi_cv_path_python3} -c \ +! "import sys, string; print(':'.join(sys.path))"` ]) +! +! dnl -- where the Python implementation library archives are +! +! AC_ARG_WITH(python3-config-dir, +! [ --with-python3-config-dir=PATH Python's config directory], +! [ vi_cv_path_python3_conf="${withval}" ] ) +! +! AC_CACHE_CHECK(Python's configuration directory,vi_cv_path_python3_conf, +! [ +! vi_cv_path_python3_conf= +! config_dir="config" +! if test "${vi_cv_var_python3_abiflags}" != ""; then +! config_dir="${config_dir}-${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}" +! fi +! d=`${vi_cv_path_python3} -c "import distutils.sysconfig; print(distutils.sysconfig.get_config_var('LIBPL'))"` +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python3_conf="$d" +! else +! for path in "${vi_cv_path_python3_pfx}" "${vi_cv_path_python3_epfx}"; do +! for subdir in lib64 lib share; do +! d="${path}/${subdir}/python${vi_cv_var_python3_version}/${config_dir}" +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python3_conf="$d" +! fi +! done +! done +! fi +! ]) + +! PYTHON3_CONFDIR="${vi_cv_path_python3_conf}" +! +! if test "X$PYTHON3_CONFDIR" = "X"; then +! AC_MSG_RESULT([can't find it!]) +! else +! +! dnl -- we need to examine Python's config/Makefile too +! dnl see what the interpreter is built from +! AC_CACHE_VAL(vi_cv_path_python3_plibs, + [ +! pwd=`pwd` +! tmp_mkf="$pwd/config-PyMake$$" +! cat -- "${PYTHON3_CONFDIR}/Makefile" - <<'eof' >"${tmp_mkf}" + __: + @echo "python3_BASEMODLIBS='$(BASEMODLIBS)'" + @echo "python3_LIBS='$(LIBS)'" +--- 1060,1144 ---- + ${vi_cv_path_python3} -c 'import sys; print(sys.version[:3])'` + ]]) + +! dnl -- it must be at least version 3 +! AC_MSG_CHECKING(Python is 3.0 or better) +! if ${vi_cv_path_python3} -c \ +! "import sys; sys.exit(${vi_cv_var_python3_version} < 3.0)" +! then +! AC_MSG_RESULT(yep) + +! dnl -- get abiflags for python 3.2 or higher (PEP 3149) +! AC_CACHE_CHECK(Python's abiflags,vi_cv_var_python3_abiflags, + [ +! vi_cv_var_python3_abiflags= +! if ${vi_cv_path_python3} -c \ +! "import sys; sys.exit(${vi_cv_var_python3_version} < 3.2)" +! then +! vi_cv_var_python3_abiflags=`${vi_cv_path_python3} -c \ +! "import sys; print(sys.abiflags)"` +! fi ]) +! +! dnl -- find where python3 thinks it was installed +! AC_CACHE_CHECK(Python's install prefix,vi_cv_path_python3_pfx, +! [ vi_cv_path_python3_pfx=` +! ${vi_cv_path_python3} -c \ +! "import sys; print(sys.prefix)"` ]) +! +! dnl -- and where it thinks it runs +! AC_CACHE_CHECK(Python's execution prefix,vi_cv_path_python3_epfx, +! [ vi_cv_path_python3_epfx=` +! ${vi_cv_path_python3} -c \ +! "import sys; print(sys.exec_prefix)"` ]) +! +! dnl -- python3's internal library path +! +! AC_CACHE_VAL(vi_cv_path_python3path, +! [ vi_cv_path_python3path=` +! unset PYTHONPATH; +! ${vi_cv_path_python3} -c \ +! "import sys, string; print(':'.join(sys.path))"` ]) +! +! dnl -- where the Python implementation library archives are +! +! AC_ARG_WITH(python3-config-dir, +! [ --with-python3-config-dir=PATH Python's config directory], +! [ vi_cv_path_python3_conf="${withval}" ] ) +! +! AC_CACHE_CHECK(Python's configuration directory,vi_cv_path_python3_conf, +! [ +! vi_cv_path_python3_conf= +! config_dir="config" +! if test "${vi_cv_var_python3_abiflags}" != ""; then +! config_dir="${config_dir}-${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}" +! fi +! d=`${vi_cv_path_python3} -c "import distutils.sysconfig; print(distutils.sysconfig.get_config_var('LIBPL'))"` +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python3_conf="$d" +! else +! for path in "${vi_cv_path_python3_pfx}" "${vi_cv_path_python3_epfx}"; do +! for subdir in lib64 lib share; do +! d="${path}/${subdir}/python${vi_cv_var_python3_version}/${config_dir}" +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python3_conf="$d" +! fi +! done +! done +! fi +! ]) +! +! PYTHON3_CONFDIR="${vi_cv_path_python3_conf}" +! +! if test "X$PYTHON3_CONFDIR" = "X"; then +! AC_MSG_RESULT([can't find it!]) +! else +! +! dnl -- we need to examine Python's config/Makefile too +! dnl see what the interpreter is built from +! AC_CACHE_VAL(vi_cv_path_python3_plibs, +! [ +! pwd=`pwd` +! tmp_mkf="$pwd/config-PyMake$$" +! cat -- "${PYTHON3_CONFDIR}/Makefile" - <<'eof' >"${tmp_mkf}" + __: + @echo "python3_BASEMODLIBS='$(BASEMODLIBS)'" + @echo "python3_LIBS='$(LIBS)'" +*************** +*** 1137,1217 **** + @echo "python3_DLLLIBRARY='$(DLLLIBRARY)'" + @echo "python3_INSTSONAME='$(INSTSONAME)'" + eof +! dnl -- delete the lines from make about Entering/Leaving directory +! eval "`cd ${PYTHON3_CONFDIR} && make -f "${tmp_mkf}" __ | sed '/ directory /d'`" +! rm -f -- "${tmp_mkf}" +! vi_cv_path_python3_plibs="-L${PYTHON3_CONFDIR} -lpython${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}" +! vi_cv_path_python3_plibs="${vi_cv_path_python3_plibs} ${python3_BASEMODLIBS} ${python3_LIBS} ${python3_SYSLIBS}" +! dnl remove -ltermcap, it can conflict with an earlier -lncurses +! vi_cv_path_python3_plibs=`echo $vi_cv_path_python3_plibs | sed s/-ltermcap//` +! vi_cv_path_python3_plibs=`echo $vi_cv_path_python3_plibs | sed s/-lffi//` +! ]) +! +! if test "X$python3_DLLLIBRARY" != "X"; then +! python3_INSTSONAME="$python3_DLLLIBRARY" +! fi +! PYTHON3_LIBS="${vi_cv_path_python3_plibs}" +! if test "${vi_cv_path_python3_pfx}" = "${vi_cv_path_python3_epfx}"; then +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" +! else +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" +! fi +! PYTHON3_SRC="if_python3.c" +! PYTHON3_OBJ="objects/if_python3.o" +! +! dnl On FreeBSD linking with "-pthread" is required to use threads. +! dnl _THREAD_SAFE must be used for compiling then. +! dnl The "-pthread" is added to $LIBS, so that the following check for +! dnl sigaltstack() will look in libc_r (it's there in libc!). +! dnl Otherwise, when using GCC, try adding -pthread to $CFLAGS. GCC +! dnl will then define target-specific defines, e.g., -D_REENTRANT. +! dnl Don't do this for Mac OSX, -pthread will generate a warning. +! AC_MSG_CHECKING([if -pthread should be used]) +! threadsafe_flag= +! thread_lib= +! dnl if test "x$MACOSX" != "xyes"; then +! if test "`(uname) 2>/dev/null`" != Darwin; then +! test "$GCC" = yes && threadsafe_flag="-pthread" +! if test "`(uname) 2>/dev/null`" = FreeBSD; then +! threadsafe_flag="-D_THREAD_SAFE" +! thread_lib="-pthread" + fi +! fi +! libs_save_old=$LIBS +! if test -n "$threadsafe_flag"; then + cflags_save=$CFLAGS +! CFLAGS="$CFLAGS $threadsafe_flag" +! LIBS="$LIBS $thread_lib" + AC_TRY_LINK(,[ ], +! AC_MSG_RESULT(yes); PYTHON3_CFLAGS="$PYTHON3_CFLAGS $threadsafe_flag", +! AC_MSG_RESULT(no); LIBS=$libs_save_old +! ) + CFLAGS=$cflags_save +! else +! AC_MSG_RESULT(no) +! fi +! +! dnl check that compiling a simple program still works with the flags +! dnl added for Python. +! AC_MSG_CHECKING([if compile and link flags for Python 3 are sane]) +! cflags_save=$CFLAGS +! libs_save=$LIBS +! CFLAGS="$CFLAGS $PYTHON3_CFLAGS" +! LIBS="$LIBS $PYTHON3_LIBS" +! AC_TRY_LINK(,[ ], +! AC_MSG_RESULT(yes); python3_ok=yes, +! AC_MSG_RESULT(no: PYTHON3 DISABLED); python3_ok=no) +! CFLAGS=$cflags_save +! LIBS=$libs_save +! if test "$python3_ok" = yes; then +! AC_DEFINE(FEAT_PYTHON3) +! else +! LIBS=$libs_save_old +! PYTHON3_SRC= +! PYTHON3_OBJ= +! PYTHON3_LIBS= +! PYTHON3_CFLAGS= + fi + fi + fi + fi +--- 1146,1232 ---- + @echo "python3_DLLLIBRARY='$(DLLLIBRARY)'" + @echo "python3_INSTSONAME='$(INSTSONAME)'" + eof +! dnl -- delete the lines from make about Entering/Leaving directory +! eval "`cd ${PYTHON3_CONFDIR} && make -f "${tmp_mkf}" __ | sed '/ directory /d'`" +! rm -f -- "${tmp_mkf}" +! vi_cv_path_python3_plibs="-L${PYTHON3_CONFDIR} -lpython${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}" +! vi_cv_path_python3_plibs="${vi_cv_path_python3_plibs} ${python3_BASEMODLIBS} ${python3_LIBS} ${python3_SYSLIBS}" +! dnl remove -ltermcap, it can conflict with an earlier -lncurses +! vi_cv_path_python3_plibs=`echo $vi_cv_path_python3_plibs | sed s/-ltermcap//` +! vi_cv_path_python3_plibs=`echo $vi_cv_path_python3_plibs | sed s/-lffi//` +! ]) +! +! if test "X$python3_DLLLIBRARY" != "X"; then +! python3_INSTSONAME="$python3_DLLLIBRARY" + fi +! PYTHON3_LIBS="${vi_cv_path_python3_plibs}" +! if test "${vi_cv_path_python3_pfx}" = "${vi_cv_path_python3_epfx}"; then +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" +! else +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" +! fi +! PYTHON3_SRC="if_python3.c" +! PYTHON3_OBJ="objects/if_python3.o" +! +! dnl On FreeBSD linking with "-pthread" is required to use threads. +! dnl _THREAD_SAFE must be used for compiling then. +! dnl The "-pthread" is added to $LIBS, so that the following check for +! dnl sigaltstack() will look in libc_r (it's there in libc!). +! dnl Otherwise, when using GCC, try adding -pthread to $CFLAGS. GCC +! dnl will then define target-specific defines, e.g., -D_REENTRANT. +! dnl Don't do this for Mac OSX, -pthread will generate a warning. +! AC_MSG_CHECKING([if -pthread should be used]) +! threadsafe_flag= +! thread_lib= +! dnl if test "x$MACOSX" != "xyes"; then +! if test "`(uname) 2>/dev/null`" != Darwin; then +! test "$GCC" = yes && threadsafe_flag="-pthread" +! if test "`(uname) 2>/dev/null`" = FreeBSD; then +! threadsafe_flag="-D_THREAD_SAFE" +! thread_lib="-pthread" +! fi +! if test "`(uname) 2>/dev/null`" = SunOS; then +! threadsafe_flag="-pthreads" +! fi +! fi +! libs_save_old=$LIBS +! if test -n "$threadsafe_flag"; then +! cflags_save=$CFLAGS +! CFLAGS="$CFLAGS $threadsafe_flag" +! LIBS="$LIBS $thread_lib" +! AC_TRY_LINK(,[ ], +! AC_MSG_RESULT(yes); PYTHON3_CFLAGS="$PYTHON3_CFLAGS $threadsafe_flag", +! AC_MSG_RESULT(no); LIBS=$libs_save_old +! ) +! CFLAGS=$cflags_save +! else +! AC_MSG_RESULT(no) +! fi +! +! dnl check that compiling a simple program still works with the flags +! dnl added for Python. +! AC_MSG_CHECKING([if compile and link flags for Python 3 are sane]) + cflags_save=$CFLAGS +! libs_save=$LIBS +! CFLAGS="$CFLAGS $PYTHON3_CFLAGS" +! LIBS="$LIBS $PYTHON3_LIBS" + AC_TRY_LINK(,[ ], +! AC_MSG_RESULT(yes); python3_ok=yes, +! AC_MSG_RESULT(no: PYTHON3 DISABLED); python3_ok=no) + CFLAGS=$cflags_save +! LIBS=$libs_save +! if test "$python3_ok" = yes; then +! AC_DEFINE(FEAT_PYTHON3) +! else +! LIBS=$libs_save_old +! PYTHON3_SRC= +! PYTHON3_OBJ= +! PYTHON3_LIBS= +! PYTHON3_CFLAGS= +! fi + fi ++ else ++ AC_MSG_RESULT(too old) + fi + fi + fi +*************** +*** 2442,2448 **** + xmheader="Xm/Xm.h" + else + xmheader="Xm/Xm.h Xm/XpmP.h Xm/JoinSideT.h Xm/TraitP.h Xm/Manager.h +! Xm/UnhighlightT.h Xm/Notebook.h" + fi + AC_CHECK_HEADERS($xmheader) + +--- 2457,2463 ---- + xmheader="Xm/Xm.h" + else + xmheader="Xm/Xm.h Xm/XpmP.h Xm/JoinSideT.h Xm/TraitP.h Xm/Manager.h +! Xm/UnhighlightT.h Xm/Notebook.h" + fi + AC_CHECK_HEADERS($xmheader) + +*************** +*** 3356,3362 **** + [#include + #include ], + [ struct sysinfo sinfo; +! sinfo.mem_unit = 1; + ], + AC_MSG_RESULT(yes); AC_DEFINE(HAVE_SYSINFO_MEM_UNIT), + AC_MSG_RESULT(no)) +--- 3371,3377 ---- + [#include + #include ], + [ struct sysinfo sinfo; +! sinfo.mem_unit = 1; + ], + AC_MSG_RESULT(yes); AC_DEFINE(HAVE_SYSINFO_MEM_UNIT), + AC_MSG_RESULT(no)) +*** ../vim-7.3.1166/src/auto/configure 2013-06-10 21:27:18.000000000 +0200 +--- src/auto/configure 2013-06-11 19:50:08.000000000 +0200 +*************** +*** 5431,5436 **** +--- 5431,5439 ---- + threadsafe_flag="-D_THREAD_SAFE" + thread_lib="-pthread" + fi ++ if test "`(uname) 2>/dev/null`" = SunOS; then ++ threadsafe_flag="-pthreads" ++ fi + fi + libs_save_old=$LIBS + if test -n "$threadsafe_flag"; then +*************** +*** 5502,5508 **** + PYTHON_LIBS= + PYTHON_CFLAGS= + fi +- + fi + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: too old" >&5 +--- 5505,5510 ---- +*************** +*** 5594,5648 **** + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_var_python3_version" >&5 + $as_echo "$vi_cv_var_python3_version" >&6; } + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python's abiflags" >&5 + $as_echo_n "checking Python's abiflags... " >&6; } + if test "${vi_cv_var_python3_abiflags+set}" = set; then : + $as_echo_n "(cached) " >&6 + else + +! vi_cv_var_python3_abiflags= +! if ${vi_cv_path_python3} -c \ +! "import sys; sys.exit(${vi_cv_var_python3_version} < 3.2)" +! then +! vi_cv_var_python3_abiflags=`${vi_cv_path_python3} -c \ +! "import sys; print(sys.abiflags)"` +! fi + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_var_python3_abiflags" >&5 + $as_echo "$vi_cv_var_python3_abiflags" >&6; } + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python's install prefix" >&5 + $as_echo_n "checking Python's install prefix... " >&6; } + if test "${vi_cv_path_python3_pfx+set}" = set; then : + $as_echo_n "(cached) " >&6 + else + vi_cv_path_python3_pfx=` +! ${vi_cv_path_python3} -c \ +! "import sys; print(sys.prefix)"` + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python3_pfx" >&5 + $as_echo "$vi_cv_path_python3_pfx" >&6; } + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python's execution prefix" >&5 + $as_echo_n "checking Python's execution prefix... " >&6; } + if test "${vi_cv_path_python3_epfx+set}" = set; then : + $as_echo_n "(cached) " >&6 + else + vi_cv_path_python3_epfx=` +! ${vi_cv_path_python3} -c \ +! "import sys; print(sys.exec_prefix)"` + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python3_epfx" >&5 + $as_echo "$vi_cv_path_python3_epfx" >&6; } + + +! if test "${vi_cv_path_python3path+set}" = set; then : + $as_echo_n "(cached) " >&6 + else + vi_cv_path_python3path=` +! unset PYTHONPATH; +! ${vi_cv_path_python3} -c \ +! "import sys, string; print(':'.join(sys.path))"` + fi + + +--- 5596,5658 ---- + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_var_python3_version" >&5 + $as_echo "$vi_cv_var_python3_version" >&6; } + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python is 3.0 or better" >&5 +! $as_echo_n "checking Python is 3.0 or better... " >&6; } +! if ${vi_cv_path_python3} -c \ +! "import sys; sys.exit(${vi_cv_var_python3_version} < 3.0)" +! then +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: yep" >&5 +! $as_echo "yep" >&6; } +! +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python's abiflags" >&5 + $as_echo_n "checking Python's abiflags... " >&6; } + if test "${vi_cv_var_python3_abiflags+set}" = set; then : + $as_echo_n "(cached) " >&6 + else + +! vi_cv_var_python3_abiflags= +! if ${vi_cv_path_python3} -c \ +! "import sys; sys.exit(${vi_cv_var_python3_version} < 3.2)" +! then +! vi_cv_var_python3_abiflags=`${vi_cv_path_python3} -c \ +! "import sys; print(sys.abiflags)"` +! fi + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_var_python3_abiflags" >&5 + $as_echo "$vi_cv_var_python3_abiflags" >&6; } + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python's install prefix" >&5 + $as_echo_n "checking Python's install prefix... " >&6; } + if test "${vi_cv_path_python3_pfx+set}" = set; then : + $as_echo_n "(cached) " >&6 + else + vi_cv_path_python3_pfx=` +! ${vi_cv_path_python3} -c \ +! "import sys; print(sys.prefix)"` + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python3_pfx" >&5 + $as_echo "$vi_cv_path_python3_pfx" >&6; } + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python's execution prefix" >&5 + $as_echo_n "checking Python's execution prefix... " >&6; } + if test "${vi_cv_path_python3_epfx+set}" = set; then : + $as_echo_n "(cached) " >&6 + else + vi_cv_path_python3_epfx=` +! ${vi_cv_path_python3} -c \ +! "import sys; print(sys.exec_prefix)"` + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python3_epfx" >&5 + $as_echo "$vi_cv_path_python3_epfx" >&6; } + + +! if test "${vi_cv_path_python3path+set}" = set; then : + $as_echo_n "(cached) " >&6 + else + vi_cv_path_python3path=` +! unset PYTHONPATH; +! ${vi_cv_path_python3} -c \ +! "import sys, string; print(':'.join(sys.path))"` + fi + + +*************** +*** 5654,5702 **** + fi + + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python's configuration directory" >&5 + $as_echo_n "checking Python's configuration directory... " >&6; } + if test "${vi_cv_path_python3_conf+set}" = set; then : + $as_echo_n "(cached) " >&6 + else + +! vi_cv_path_python3_conf= +! config_dir="config" +! if test "${vi_cv_var_python3_abiflags}" != ""; then +! config_dir="${config_dir}-${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}" +! fi +! d=`${vi_cv_path_python3} -c "import distutils.sysconfig; print(distutils.sysconfig.get_config_var('LIBPL'))"` +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python3_conf="$d" +! else +! for path in "${vi_cv_path_python3_pfx}" "${vi_cv_path_python3_epfx}"; do +! for subdir in lib64 lib share; do +! d="${path}/${subdir}/python${vi_cv_var_python3_version}/${config_dir}" +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python3_conf="$d" +! fi +! done +! done +! fi + + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python3_conf" >&5 + $as_echo "$vi_cv_path_python3_conf" >&6; } + +! PYTHON3_CONFDIR="${vi_cv_path_python3_conf}" + +! if test "X$PYTHON3_CONFDIR" = "X"; then +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: can't find it!" >&5 + $as_echo "can't find it!" >&6; } +! else + +! if test "${vi_cv_path_python3_plibs+set}" = set; then : + $as_echo_n "(cached) " >&6 + else + +! pwd=`pwd` +! tmp_mkf="$pwd/config-PyMake$$" +! cat -- "${PYTHON3_CONFDIR}/Makefile" - <<'eof' >"${tmp_mkf}" + __: + @echo "python3_BASEMODLIBS='$(BASEMODLIBS)'" + @echo "python3_LIBS='$(LIBS)'" +--- 5664,5712 ---- + fi + + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python's configuration directory" >&5 + $as_echo_n "checking Python's configuration directory... " >&6; } + if test "${vi_cv_path_python3_conf+set}" = set; then : + $as_echo_n "(cached) " >&6 + else + +! vi_cv_path_python3_conf= +! config_dir="config" +! if test "${vi_cv_var_python3_abiflags}" != ""; then +! config_dir="${config_dir}-${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}" +! fi +! d=`${vi_cv_path_python3} -c "import distutils.sysconfig; print(distutils.sysconfig.get_config_var('LIBPL'))"` +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python3_conf="$d" +! else +! for path in "${vi_cv_path_python3_pfx}" "${vi_cv_path_python3_epfx}"; do +! for subdir in lib64 lib share; do +! d="${path}/${subdir}/python${vi_cv_var_python3_version}/${config_dir}" +! if test -d "$d" && test -f "$d/config.c"; then +! vi_cv_path_python3_conf="$d" +! fi +! done +! done +! fi + + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python3_conf" >&5 + $as_echo "$vi_cv_path_python3_conf" >&6; } + +! PYTHON3_CONFDIR="${vi_cv_path_python3_conf}" + +! if test "X$PYTHON3_CONFDIR" = "X"; then +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: can't find it!" >&5 + $as_echo "can't find it!" >&6; } +! else + +! if test "${vi_cv_path_python3_plibs+set}" = set; then : + $as_echo_n "(cached) " >&6 + else + +! pwd=`pwd` +! tmp_mkf="$pwd/config-PyMake$$" +! cat -- "${PYTHON3_CONFDIR}/Makefile" - <<'eof' >"${tmp_mkf}" + __: + @echo "python3_BASEMODLIBS='$(BASEMODLIBS)'" + @echo "python3_LIBS='$(LIBS)'" +*************** +*** 5704,5748 **** + @echo "python3_DLLLIBRARY='$(DLLLIBRARY)'" + @echo "python3_INSTSONAME='$(INSTSONAME)'" + eof +! eval "`cd ${PYTHON3_CONFDIR} && make -f "${tmp_mkf}" __ | sed '/ directory /d'`" +! rm -f -- "${tmp_mkf}" +! vi_cv_path_python3_plibs="-L${PYTHON3_CONFDIR} -lpython${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}" +! vi_cv_path_python3_plibs="${vi_cv_path_python3_plibs} ${python3_BASEMODLIBS} ${python3_LIBS} ${python3_SYSLIBS}" +! vi_cv_path_python3_plibs=`echo $vi_cv_path_python3_plibs | sed s/-ltermcap//` +! vi_cv_path_python3_plibs=`echo $vi_cv_path_python3_plibs | sed s/-lffi//` + + fi + + +! if test "X$python3_DLLLIBRARY" != "X"; then +! python3_INSTSONAME="$python3_DLLLIBRARY" +! fi +! PYTHON3_LIBS="${vi_cv_path_python3_plibs}" +! if test "${vi_cv_path_python3_pfx}" = "${vi_cv_path_python3_epfx}"; then +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" +! else +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" +! fi +! PYTHON3_SRC="if_python3.c" +! PYTHON3_OBJ="objects/if_python3.o" + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -pthread should be used" >&5 + $as_echo_n "checking if -pthread should be used... " >&6; } +! threadsafe_flag= +! thread_lib= +! if test "`(uname) 2>/dev/null`" != Darwin; then +! test "$GCC" = yes && threadsafe_flag="-pthread" +! if test "`(uname) 2>/dev/null`" = FreeBSD; then +! threadsafe_flag="-D_THREAD_SAFE" +! thread_lib="-pthread" + fi +! fi +! libs_save_old=$LIBS +! if test -n "$threadsafe_flag"; then +! cflags_save=$CFLAGS +! CFLAGS="$CFLAGS $threadsafe_flag" +! LIBS="$LIBS $thread_lib" +! cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ + + int +--- 5714,5761 ---- + @echo "python3_DLLLIBRARY='$(DLLLIBRARY)'" + @echo "python3_INSTSONAME='$(INSTSONAME)'" + eof +! eval "`cd ${PYTHON3_CONFDIR} && make -f "${tmp_mkf}" __ | sed '/ directory /d'`" +! rm -f -- "${tmp_mkf}" +! vi_cv_path_python3_plibs="-L${PYTHON3_CONFDIR} -lpython${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}" +! vi_cv_path_python3_plibs="${vi_cv_path_python3_plibs} ${python3_BASEMODLIBS} ${python3_LIBS} ${python3_SYSLIBS}" +! vi_cv_path_python3_plibs=`echo $vi_cv_path_python3_plibs | sed s/-ltermcap//` +! vi_cv_path_python3_plibs=`echo $vi_cv_path_python3_plibs | sed s/-lffi//` + + fi + + +! if test "X$python3_DLLLIBRARY" != "X"; then +! python3_INSTSONAME="$python3_DLLLIBRARY" +! fi +! PYTHON3_LIBS="${vi_cv_path_python3_plibs}" +! if test "${vi_cv_path_python3_pfx}" = "${vi_cv_path_python3_epfx}"; then +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" +! else +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" +! fi +! PYTHON3_SRC="if_python3.c" +! PYTHON3_OBJ="objects/if_python3.o" + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -pthread should be used" >&5 + $as_echo_n "checking if -pthread should be used... " >&6; } +! threadsafe_flag= +! thread_lib= +! if test "`(uname) 2>/dev/null`" != Darwin; then +! test "$GCC" = yes && threadsafe_flag="-pthread" +! if test "`(uname) 2>/dev/null`" = FreeBSD; then +! threadsafe_flag="-D_THREAD_SAFE" +! thread_lib="-pthread" +! fi +! if test "`(uname) 2>/dev/null`" = SunOS; then +! threadsafe_flag="-pthreads" +! fi + fi +! libs_save_old=$LIBS +! if test -n "$threadsafe_flag"; then +! cflags_save=$CFLAGS +! CFLAGS="$CFLAGS $threadsafe_flag" +! LIBS="$LIBS $thread_lib" +! cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ + + int +*************** +*** 5763,5781 **** + fi + rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +! CFLAGS=$cflags_save +! else +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 + $as_echo "no" >&6; } +! fi + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compile and link flags for Python 3 are sane" >&5 + $as_echo_n "checking if compile and link flags for Python 3 are sane... " >&6; } +! cflags_save=$CFLAGS +! libs_save=$LIBS +! CFLAGS="$CFLAGS $PYTHON3_CFLAGS" +! LIBS="$LIBS $PYTHON3_LIBS" +! cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ + + int +--- 5776,5794 ---- + fi + rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +! CFLAGS=$cflags_save +! else +! { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 + $as_echo "no" >&6; } +! fi + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compile and link flags for Python 3 are sane" >&5 + $as_echo_n "checking if compile and link flags for Python 3 are sane... " >&6; } +! cflags_save=$CFLAGS +! libs_save=$LIBS +! CFLAGS="$CFLAGS $PYTHON3_CFLAGS" +! LIBS="$LIBS $PYTHON3_LIBS" +! cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ + + int +*************** +*** 5795,5812 **** + fi + rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +! CFLAGS=$cflags_save +! LIBS=$libs_save +! if test "$python3_ok" = yes; then +! $as_echo "#define FEAT_PYTHON3 1" >>confdefs.h +! +! else +! LIBS=$libs_save_old +! PYTHON3_SRC= +! PYTHON3_OBJ= +! PYTHON3_LIBS= +! PYTHON3_CFLAGS= + fi + fi + fi + fi +--- 5808,5829 ---- + fi + rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +! CFLAGS=$cflags_save +! LIBS=$libs_save +! if test "$python3_ok" = yes; then +! $as_echo "#define FEAT_PYTHON3 1" >>confdefs.h +! +! else +! LIBS=$libs_save_old +! PYTHON3_SRC= +! PYTHON3_OBJ= +! PYTHON3_LIBS= +! PYTHON3_CFLAGS= +! fi + fi ++ else ++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: too old" >&5 ++ $as_echo "too old" >&6; } + fi + fi + fi +*************** +*** 8780,8786 **** + xmheader="Xm/Xm.h" + else + xmheader="Xm/Xm.h Xm/XpmP.h Xm/JoinSideT.h Xm/TraitP.h Xm/Manager.h +! Xm/UnhighlightT.h Xm/Notebook.h" + fi + for ac_header in $xmheader + do : +--- 8797,8803 ---- + xmheader="Xm/Xm.h" + else + xmheader="Xm/Xm.h Xm/XpmP.h Xm/JoinSideT.h Xm/TraitP.h Xm/Manager.h +! Xm/UnhighlightT.h Xm/Notebook.h" + fi + for ac_header in $xmheader + do : +*************** +*** 11777,11783 **** + main () + { + struct sysinfo sinfo; +! sinfo.mem_unit = 1; + + ; + return 0; +--- 11794,11800 ---- + main () + { + struct sysinfo sinfo; +! sinfo.mem_unit = 1; + + ; + return 0; +*** ../vim-7.3.1166/src/version.c 2013-06-11 18:47:37.000000000 +0200 +--- src/version.c 2013-06-11 19:51:50.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1167, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +147. You finally give up smoking...because it made the monitor dirty. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ea61b098a4b454958bba749d35a8c71447f95fef Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:54 +0200 Subject: [PATCH 1060/3340] - patchlevel 1168 --- 7.3.1168 | 123 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 123 insertions(+) create mode 100644 7.3.1168 diff --git a/7.3.1168 b/7.3.1168 new file mode 100644 index 00000000..ec1a7a08 --- /dev/null +++ b/7.3.1168 @@ -0,0 +1,123 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1168 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1168 +Problem: Python "sane" configure checks give a warning message. +Solution: Use single quotes intead of escaped double quotes. (Ben Fritz) +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.1167/src/configure.in 2013-06-11 19:53:34.000000000 +0200 +--- src/configure.in 2013-06-11 20:15:21.000000000 +0200 +*************** +*** 958,966 **** + fi + PYTHON_LIBS="${vi_cv_path_python_plibs}" + if test "${vi_cv_path_python_pfx}" = "${vi_cv_path_python_epfx}"; then +! PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\"" + else +! PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\"" + fi + PYTHON_SRC="if_python.c" + PYTHON_OBJ="objects/if_python.o" +--- 958,966 ---- + fi + PYTHON_LIBS="${vi_cv_path_python_plibs}" + if test "${vi_cv_path_python_pfx}" = "${vi_cv_path_python_epfx}"; then +! PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME='\"${vi_cv_path_python_pfx}\"'" + else +! PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME='\"${vi_cv_path_python_pfx}\"'" + fi + PYTHON_SRC="if_python.c" + PYTHON_OBJ="objects/if_python.o" +*************** +*** 1161,1169 **** + fi + PYTHON3_LIBS="${vi_cv_path_python3_plibs}" + if test "${vi_cv_path_python3_pfx}" = "${vi_cv_path_python3_epfx}"; then +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" + else +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" + fi + PYTHON3_SRC="if_python3.c" + PYTHON3_OBJ="objects/if_python3.o" +--- 1161,1169 ---- + fi + PYTHON3_LIBS="${vi_cv_path_python3_plibs}" + if test "${vi_cv_path_python3_pfx}" = "${vi_cv_path_python3_epfx}"; then +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME='L\"${vi_cv_path_python3_pfx}\"'" + else +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME='L\"${vi_cv_path_python3_pfx}\"'" + fi + PYTHON3_SRC="if_python3.c" + PYTHON3_OBJ="objects/if_python3.o" +*** ../vim-7.3.1167/src/auto/configure 2013-06-11 19:53:34.000000000 +0200 +--- src/auto/configure 2013-06-11 20:15:24.000000000 +0200 +*************** +*** 5410,5418 **** + fi + PYTHON_LIBS="${vi_cv_path_python_plibs}" + if test "${vi_cv_path_python_pfx}" = "${vi_cv_path_python_epfx}"; then +! PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\"" + else +! PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\"" + fi + PYTHON_SRC="if_python.c" + PYTHON_OBJ="objects/if_python.o" +--- 5410,5418 ---- + fi + PYTHON_LIBS="${vi_cv_path_python_plibs}" + if test "${vi_cv_path_python_pfx}" = "${vi_cv_path_python_epfx}"; then +! PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME='\"${vi_cv_path_python_pfx}\"'" + else +! PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME='\"${vi_cv_path_python_pfx}\"'" + fi + PYTHON_SRC="if_python.c" + PYTHON_OBJ="objects/if_python.o" +*************** +*** 5729,5737 **** + fi + PYTHON3_LIBS="${vi_cv_path_python3_plibs}" + if test "${vi_cv_path_python3_pfx}" = "${vi_cv_path_python3_epfx}"; then +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" + else +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME=L\\\"${vi_cv_path_python3_pfx}\\\"" + fi + PYTHON3_SRC="if_python3.c" + PYTHON3_OBJ="objects/if_python3.o" +--- 5729,5737 ---- + fi + PYTHON3_LIBS="${vi_cv_path_python3_plibs}" + if test "${vi_cv_path_python3_pfx}" = "${vi_cv_path_python3_epfx}"; then +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME='L\"${vi_cv_path_python3_pfx}\"'" + else +! PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME='L\"${vi_cv_path_python3_pfx}\"'" + fi + PYTHON3_SRC="if_python3.c" + PYTHON3_OBJ="objects/if_python3.o" +*** ../vim-7.3.1167/src/version.c 2013-06-11 19:53:34.000000000 +0200 +--- src/version.c 2013-06-11 20:17:21.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1168, + /**/ + +-- +Although the scythe isn't pre-eminent among the weapons of war, anyone who +has been on the wrong end of, say, a peasants' revolt will know that in +skilled hands it is fearsome. + -- (Terry Pratchett, Mort) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e73c549b2e5ced765a91d63cee46199e73312c77 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:55 +0200 Subject: [PATCH 1061/3340] - patchlevel 1169 --- 7.3.1169 | 384 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 384 insertions(+) create mode 100644 7.3.1169 diff --git a/7.3.1169 b/7.3.1169 new file mode 100644 index 00000000..aa804b6b --- /dev/null +++ b/7.3.1169 @@ -0,0 +1,384 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1169 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1169 +Problem: New regexp engine: some work is done while executing a pattern, + even though the result is predictable. +Solution: Do the work while compiling the pattern. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1168/src/regexp_nfa.c 2013-06-11 18:42:28.000000000 +0200 +--- src/regexp_nfa.c 2013-06-11 22:40:12.000000000 +0200 +*************** +*** 64,72 **** +--- 64,76 ---- + NFA_NOPEN, /* Start of subexpression marked with \%( */ + NFA_NCLOSE, /* End of subexpr. marked with \%( ... \) */ + NFA_START_INVISIBLE, ++ NFA_START_INVISIBLE_FIRST, + NFA_START_INVISIBLE_NEG, ++ NFA_START_INVISIBLE_NEG_FIRST, + NFA_START_INVISIBLE_BEFORE, ++ NFA_START_INVISIBLE_BEFORE_FIRST, + NFA_START_INVISIBLE_BEFORE_NEG, ++ NFA_START_INVISIBLE_BEFORE_NEG_FIRST, + NFA_START_PATTERN, + NFA_END_INVISIBLE, + NFA_END_INVISIBLE_NEG, +*************** +*** 286,291 **** +--- 290,296 ---- + static int *re2post __ARGS((void)); + static nfa_state_T *alloc_state __ARGS((int c, nfa_state_T *out, nfa_state_T *out1)); + static nfa_state_T *post2nfa __ARGS((int *postfix, int *end, int nfa_calc_size)); ++ static void nfa_postprocess __ARGS((nfa_regprog_T *prog)); + static int check_char_class __ARGS((int class, int c)); + static void st_error __ARGS((int *postfix, int *end, int *p)); + static void nfa_save_listids __ARGS((nfa_regprog_T *prog, int *list)); +*************** +*** 297,302 **** +--- 302,309 ---- + static void nfa_regfree __ARGS((regprog_T *prog)); + static int nfa_regexec __ARGS((regmatch_T *rmp, char_u *line, colnr_T col)); + static long nfa_regexec_multi __ARGS((regmmatch_T *rmp, win_T *win, buf_T *buf, linenr_T lnum, colnr_T col, proftime_T *tm)); ++ static int match_follows __ARGS((nfa_state_T *startstate, int depth)); ++ static int failure_chance __ARGS((nfa_state_T *state, int depth)); + + /* helper functions used when doing re2post() ... regatom() parsing */ + #define EMIT(c) do { \ +*************** +*** 2040,2051 **** +--- 2047,2066 ---- + case NFA_NOPEN: STRCPY(code, "NFA_NOPEN"); break; + case NFA_NCLOSE: STRCPY(code, "NFA_NCLOSE"); break; + case NFA_START_INVISIBLE: STRCPY(code, "NFA_START_INVISIBLE"); break; ++ case NFA_START_INVISIBLE_FIRST: ++ STRCPY(code, "NFA_START_INVISIBLE_FIRST"); break; + case NFA_START_INVISIBLE_NEG: + STRCPY(code, "NFA_START_INVISIBLE_NEG"); break; ++ case NFA_START_INVISIBLE_NEG_FIRST: ++ STRCPY(code, "NFA_START_INVISIBLE_NEG_FIRST"); break; + case NFA_START_INVISIBLE_BEFORE: + STRCPY(code, "NFA_START_INVISIBLE_BEFORE"); break; ++ case NFA_START_INVISIBLE_BEFORE_FIRST: ++ STRCPY(code, "NFA_START_INVISIBLE_BEFORE_FIRST"); break; + case NFA_START_INVISIBLE_BEFORE_NEG: + STRCPY(code, "NFA_START_INVISIBLE_BEFORE_NEG"); break; ++ case NFA_START_INVISIBLE_BEFORE_NEG_FIRST: ++ STRCPY(code, "NFA_START_INVISIBLE_BEFORE_NEG_FIRST"); break; + case NFA_START_PATTERN: STRCPY(code, "NFA_START_PATTERN"); break; + case NFA_END_INVISIBLE: STRCPY(code, "NFA_END_INVISIBLE"); break; + case NFA_END_INVISIBLE_NEG: STRCPY(code, "NFA_END_INVISIBLE_NEG"); break; +*************** +*** 3318,3323 **** +--- 3333,3395 ---- + #undef PUSH + } + ++ /* ++ * After building the NFA program, inspect it to add optimization hints. ++ */ ++ static void ++ nfa_postprocess(prog) ++ nfa_regprog_T *prog; ++ { ++ int i; ++ int c; ++ ++ for (i = 0; i < prog->nstate; ++i) ++ { ++ c = prog->state[i].c; ++ if (c == NFA_START_INVISIBLE ++ || c == NFA_START_INVISIBLE_NEG ++ || c == NFA_START_INVISIBLE_BEFORE ++ || c == NFA_START_INVISIBLE_BEFORE_NEG) ++ { ++ int directly; ++ ++ /* Do it directly when what follows is possibly the end of the ++ * match. */ ++ if (match_follows(prog->state[i].out1->out, 0)) ++ directly = TRUE; ++ else ++ { ++ int ch_invisible = failure_chance(prog->state[i].out, 0); ++ int ch_follows = failure_chance(prog->state[i].out1->out, 0); ++ ++ /* Postpone when the invisible match is expensive or has a ++ * lower chance of failing. */ ++ if (c == NFA_START_INVISIBLE_BEFORE ++ || c == NFA_START_INVISIBLE_BEFORE_NEG) ++ { ++ /* "before" matches are very expensive when ++ * unbounded, always prefer what follows then, ++ * unless what follows will always match. ++ * Otherwise strongly prefer what follows. */ ++ if (prog->state[i].val <= 0 && ch_follows > 0) ++ directly = FALSE; ++ else ++ directly = ch_follows * 10 < ch_invisible; ++ } ++ else ++ { ++ /* normal invisible, first do the one with the ++ * highest failure chance */ ++ directly = ch_follows < ch_invisible; ++ } ++ } ++ if (directly) ++ /* switch to the _FIRST state */ ++ ++prog->state[i].c; ++ } ++ } ++ } ++ + /**************************************************************** + * NFA execution code. + ****************************************************************/ +*************** +*** 3457,3463 **** + static void copy_sub_off __ARGS((regsub_T *to, regsub_T *from)); + static int sub_equal __ARGS((regsub_T *sub1, regsub_T *sub2)); + static int has_state_with_pos __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs)); +- static int match_follows __ARGS((nfa_state_T *startstate, int depth)); + static int state_in_list __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs)); + static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, nfa_pim_T *pim, int off)); + static void addstate_here __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, nfa_pim_T *pim, int *ip)); +--- 3529,3534 ---- +*************** +*** 3703,3711 **** +--- 3774,3786 ---- + || match_follows(state->out1, depth + 1); + + case NFA_START_INVISIBLE: ++ case NFA_START_INVISIBLE_FIRST: + case NFA_START_INVISIBLE_BEFORE: ++ case NFA_START_INVISIBLE_BEFORE_FIRST: + case NFA_START_INVISIBLE_NEG: ++ case NFA_START_INVISIBLE_NEG_FIRST: + case NFA_START_INVISIBLE_BEFORE_NEG: ++ case NFA_START_INVISIBLE_BEFORE_NEG_FIRST: + case NFA_COMPOSING: + /* skip ahead to next state */ + state = state->out1->out; +*************** +*** 4440,4446 **** + } + + if (state->c == NFA_START_INVISIBLE_BEFORE +! || state->c == NFA_START_INVISIBLE_BEFORE_NEG) + { + /* The recursive match must end at the current position. When "pim" is + * not NULL it specifies the current position. */ +--- 4515,4523 ---- + } + + if (state->c == NFA_START_INVISIBLE_BEFORE +! || state->c == NFA_START_INVISIBLE_BEFORE_FIRST +! || state->c == NFA_START_INVISIBLE_BEFORE_NEG +! || state->c == NFA_START_INVISIBLE_BEFORE_NEG_FIRST) + { + /* The recursive match must end at the current position. When "pim" is + * not NULL it specifies the current position. */ +*************** +*** 4581,4587 **** + return result; + } + +- static int failure_chance __ARGS((nfa_state_T *state, int depth)); + static int skip_to_start __ARGS((int c, colnr_T *colp)); + static long find_match_text __ARGS((colnr_T startcol, int regstart, char_u *match_text)); + +--- 4658,4663 ---- +*************** +*** 5093,5142 **** + break; + + case NFA_START_INVISIBLE: + case NFA_START_INVISIBLE_NEG: + case NFA_START_INVISIBLE_BEFORE: + case NFA_START_INVISIBLE_BEFORE_NEG: + { +- int directly = FALSE; +- + #ifdef ENABLE_LOG + fprintf(log_fd, "Failure chance invisible: %d, what follows: %d\n", + failure_chance(t->state->out, 0), + failure_chance(t->state->out1->out, 0)); + #endif +! /* Do it directly when what follows is possibly the end of +! * the match. +! * Do it directly if there already is a PIM. +! * Postpone when the invisible match is expensive or has a +! * lower chance of failing. */ +! if (match_follows(t->state->out1->out, 0) +! || t->pim.result != NFA_PIM_UNUSED) +! directly = TRUE; +! else +! { +! int ch_invisible = failure_chance(t->state->out, 0); +! int ch_follows = failure_chance(t->state->out1->out, 0); +! +! if (t->state->c == NFA_START_INVISIBLE_BEFORE +! || t->state->c == NFA_START_INVISIBLE_BEFORE_NEG) +! { +! /* "before" matches are very expensive when +! * unbounded, always prefer what follows then, +! * unless what follows will always match. +! * Otherwise strongly prefer what follows. */ +! if (t->state->val <= 0 && ch_follows > 0) +! directly = FALSE; +! else +! directly = ch_follows * 10 < ch_invisible; +! } +! else +! { +! /* normal invisible, first do the one with the +! * highest failure chance */ +! directly = ch_follows < ch_invisible; +! } +! } +! if (directly) + { + /* + * First try matching the invisible match, then what +--- 5169,5194 ---- + break; + + case NFA_START_INVISIBLE: ++ case NFA_START_INVISIBLE_FIRST: + case NFA_START_INVISIBLE_NEG: ++ case NFA_START_INVISIBLE_NEG_FIRST: + case NFA_START_INVISIBLE_BEFORE: ++ case NFA_START_INVISIBLE_BEFORE_FIRST: + case NFA_START_INVISIBLE_BEFORE_NEG: ++ case NFA_START_INVISIBLE_BEFORE_NEG_FIRST: + { + #ifdef ENABLE_LOG + fprintf(log_fd, "Failure chance invisible: %d, what follows: %d\n", + failure_chance(t->state->out, 0), + failure_chance(t->state->out1->out, 0)); + #endif +! /* Do it directly if there already is a PIM or when +! * nfa_postprocess() detected it will work better. */ +! if (t->pim.result != NFA_PIM_UNUSED +! || t->state->c == NFA_START_INVISIBLE_FIRST +! || t->state->c == NFA_START_INVISIBLE_NEG_FIRST +! || t->state->c == NFA_START_INVISIBLE_BEFORE_FIRST +! || t->state->c == NFA_START_INVISIBLE_BEFORE_NEG_FIRST) + { + /* + * First try matching the invisible match, then what +*************** +*** 5148,5155 **** + /* for \@! and \@state->c == NFA_START_INVISIBLE_NEG +! || t->state->c +! == NFA_START_INVISIBLE_BEFORE_NEG)) + { + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->subs.norm, &m->norm); +--- 5200,5210 ---- + /* for \@! and \@state->c == NFA_START_INVISIBLE_NEG +! || t->state->c == NFA_START_INVISIBLE_NEG_FIRST +! || t->state->c +! == NFA_START_INVISIBLE_BEFORE_NEG +! || t->state->c +! == NFA_START_INVISIBLE_BEFORE_NEG_FIRST)) + { + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->subs.norm, &m->norm); +*************** +*** 5920,5927 **** + /* for \@! and \@state->c == NFA_START_INVISIBLE_NEG +! || pim->state->c +! == NFA_START_INVISIBLE_BEFORE_NEG)) + { + /* Copy submatch info from the recursive call */ + copy_sub_off(&pim->subs.norm, &m->norm); +--- 5975,5985 ---- + /* for \@! and \@state->c == NFA_START_INVISIBLE_NEG +! || pim->state->c == NFA_START_INVISIBLE_NEG_FIRST +! || pim->state->c +! == NFA_START_INVISIBLE_BEFORE_NEG +! || pim->state->c +! == NFA_START_INVISIBLE_BEFORE_NEG_FIRST)) + { + /* Copy submatch info from the recursive call */ + copy_sub_off(&pim->subs.norm, &m->norm); +*************** +*** 5944,5951 **** + + /* for \@! and \@state->c == NFA_START_INVISIBLE_NEG +! || pim->state->c +! == NFA_START_INVISIBLE_BEFORE_NEG)) + { + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->subs.norm, &pim->subs.norm); +--- 6002,6012 ---- + + /* for \@! and \@state->c == NFA_START_INVISIBLE_NEG +! || pim->state->c == NFA_START_INVISIBLE_NEG_FIRST +! || pim->state->c +! == NFA_START_INVISIBLE_BEFORE_NEG +! || pim->state->c +! == NFA_START_INVISIBLE_BEFORE_NEG_FIRST)) + { + /* Copy submatch info from the recursive call */ + copy_sub_off(&t->subs.norm, &pim->subs.norm); +*************** +*** 6413,6421 **** + prog->has_backref = nfa_has_backref; + prog->nsubexp = regnpar; + + prog->reganch = nfa_get_reganch(prog->start, 0); + prog->regstart = nfa_get_regstart(prog->start, 0); +- + prog->match_text = nfa_get_match_text(prog->start); + + #ifdef ENABLE_LOG +--- 6474,6483 ---- + prog->has_backref = nfa_has_backref; + prog->nsubexp = regnpar; + ++ nfa_postprocess(prog); ++ + prog->reganch = nfa_get_reganch(prog->start, 0); + prog->regstart = nfa_get_regstart(prog->start, 0); + prog->match_text = nfa_get_match_text(prog->start); + + #ifdef ENABLE_LOG +*** ../vim-7.3.1168/src/version.c 2013-06-11 20:53:24.000000000 +0200 +--- src/version.c 2013-06-11 22:43:27.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1169, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +156. You forget your friend's name but not her e-mail address. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ec6f200530f798d2ee33bb7cec73b4fd6b68ce0d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:56 +0200 Subject: [PATCH 1062/3340] - patchlevel 1170 --- 7.3.1170 | 97 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100644 7.3.1170 diff --git a/7.3.1170 b/7.3.1170 new file mode 100644 index 00000000..b94f5ff7 --- /dev/null +++ b/7.3.1170 @@ -0,0 +1,97 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1170 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1170 +Problem: Patch 7.3.1058 breaks backwards compatibility, not possible to use + a function reference as a string. (lilydjwg) +Solution: Instead of translating the function name only translate "s:". +Files: src/eval.c + + +*** ../vim-7.3.1169/src/eval.c 2013-06-11 18:40:06.000000000 +0200 +--- src/eval.c 2013-06-12 13:31:26.000000000 +0200 +*************** +*** 10962,10986 **** + typval_T *rettv; + { + char_u *s; +- char_u *name = NULL; + + s = get_tv_string(&argvars[0]); + if (s == NULL || *s == NUL || VIM_ISDIGIT(*s)) + EMSG2(_(e_invarg2), s); +! /* Don't check an autoload name for existence here, but still expand it +! * checking for validity */ +! else if ((name = get_expanded_name(s, vim_strchr(s, AUTOLOAD_CHAR) == NULL)) +! == NULL) + EMSG2(_("E700: Unknown function: %s"), s); + else + { +! if (name == NULL) +! /* Autoload function, need to copy string */ +! rettv->vval.v_string = vim_strsave(s); + else +! /* Function found by get_expanded_name, string allocated by +! * trans_function_name: no need to copy */ +! rettv->vval.v_string = name; + rettv->v_type = VAR_FUNC; + } + } +--- 10962,10994 ---- + typval_T *rettv; + { + char_u *s; + + s = get_tv_string(&argvars[0]); + if (s == NULL || *s == NUL || VIM_ISDIGIT(*s)) + EMSG2(_(e_invarg2), s); +! /* Don't check an autoload name for existence here. */ +! else if (vim_strchr(s, AUTOLOAD_CHAR) == NULL && !function_exists(s)) + EMSG2(_("E700: Unknown function: %s"), s); + else + { +! if (STRNCMP(s, "s:", 2) == 0) +! { +! char sid_buf[25]; +! +! /* Expand s: into nr_, so that the function can also be +! * called from another script. Using trans_function_name() would +! * also work, but some plugins depend on the name being printable +! * text. */ +! sprintf(sid_buf, "%ld_", (long)current_SID); +! rettv->vval.v_string = alloc(STRLEN(sid_buf) + STRLEN(s + 2) + 1); +! if (rettv->vval.v_string != NULL) +! { +! STRCPY(rettv->vval.v_string, sid_buf); +! STRCAT(rettv->vval.v_string, s + 2); +! } +! } + else +! rettv->vval.v_string = vim_strsave(s); + rettv->v_type = VAR_FUNC; + } + } +*** ../vim-7.3.1169/src/version.c 2013-06-11 22:44:03.000000000 +0200 +--- src/version.c 2013-06-12 13:36:11.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1170, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +165. You have a web page burned into your glasses + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5bcb629e24296db1e5d9c38e5bbc53ccaad6a913 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:57 +0200 Subject: [PATCH 1063/3340] - patchlevel 1171 --- 7.3.1171 | 67 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 7.3.1171 diff --git a/7.3.1171 b/7.3.1171 new file mode 100644 index 00000000..b22f9726 --- /dev/null +++ b/7.3.1171 @@ -0,0 +1,67 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1171 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1171 +Problem: Check for digits and ascii letters can be faster. +Solution: Use a trick with one comparison. (Dominique Pelle) +Files: src/macros.h + + +*** ../vim-7.3.1170/src/macros.h 2013-06-08 18:19:40.000000000 +0200 +--- src/macros.h 2013-06-12 14:03:00.000000000 +0200 +*************** +*** 109,123 **** + #else + # define ASCII_ISALPHA(c) ((c) < 0x7f && isalpha(c)) + # define ASCII_ISALNUM(c) ((c) < 0x7f && isalnum(c)) +! # define ASCII_ISLOWER(c) ((c) < 0x7f && islower(c)) +! # define ASCII_ISUPPER(c) ((c) < 0x7f && isupper(c)) + #endif + + /* Use our own isdigit() replacement, because on MS-Windows isdigit() returns + * non-zero for superscript 1. Also avoids that isdigit() crashes for numbers +! * below 0 and above 255. For complicated arguments and in/decrement use +! * vim_isdigit() instead. */ +! #define VIM_ISDIGIT(c) ((c) >= '0' && (c) <= '9') + + /* macro version of chartab(). + * Only works with values 0-255! +--- 109,122 ---- + #else + # define ASCII_ISALPHA(c) ((c) < 0x7f && isalpha(c)) + # define ASCII_ISALNUM(c) ((c) < 0x7f && isalnum(c)) +! # define ASCII_ISLOWER(c) ((unsigned)(c) - 'a' < 26) +! # define ASCII_ISUPPER(c) ((unsigned)(c) - 'A' < 26) + #endif + + /* Use our own isdigit() replacement, because on MS-Windows isdigit() returns + * non-zero for superscript 1. Also avoids that isdigit() crashes for numbers +! * below 0 and above 255. */ +! #define VIM_ISDIGIT(c) ((unsigned)(c) - '0' < 10) + + /* macro version of chartab(). + * Only works with values 0-255! +*** ../vim-7.3.1170/src/version.c 2013-06-12 13:37:36.000000000 +0200 +--- src/version.c 2013-06-12 14:09:00.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1171, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +167. You have more than 200 websites bookmarked. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2999ae5e8ab10cdc2a053751794569bb43a342cf Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:58 +0200 Subject: [PATCH 1064/3340] - patchlevel 1172 --- 7.3.1172 | 726 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 726 insertions(+) create mode 100644 7.3.1172 diff --git a/7.3.1172 b/7.3.1172 new file mode 100644 index 00000000..9dc3a78d --- /dev/null +++ b/7.3.1172 @@ -0,0 +1,726 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1172 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1172 +Problem: Python 2: loading modules doesn't work well. +Solution: Fix the code. Add more tests. (ZyX) +Files: runtime/doc/if_pyth.txt, src/if_py_both.h, src/if_python.c, + src/testdir/python2/module.py, src/testdir/python3/module.py, + src/testdir/python_after/after.py, + src/testdir/python_before/before.py, src/testdir/test86.in, + src/testdir/test86.ok, src/testdir/test87.in, + src/testdir/test87.ok, Filelist + + +*** ../vim-7.3.1171/runtime/doc/if_pyth.txt 2013-06-10 21:27:18.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-06-12 14:12:13.000000000 +0200 +*************** +*** 315,366 **** + {rtp}/python2 (or python3) and {rtp}/pythonx (for both python versions) for + each {rtp} found in 'runtimepath'. + +! Implementation for python 2 is the following: usual importing code with empty +! lists in place of sys.path_hooks and sys.meta_path. Code is similar to the +! below, but written in C: > + +! # Assuming vim variable is already accessible and is set to the current +! # module + import sys + +! def find_module(fullname): +! return vim + +! def load_module(fullname): +! # see vim._get_paths below +! new_path = _get_paths() +! +! try: old_path = sys.path +! except: pass +! try: old_meta_path = sys.meta_path +! except: pass +! try: old_path_hooks = sys.path_hooks +! except: pass +! +! sys.meta_path = [] +! sys.path_hooks = sys.meta_path +! sys.path = new_path +! +! try: +! exec ('import ' + fullname + ' as m') # No actual exec in C code +! return m +! finally: +! e = None +! try: sys.path = old_path +! except Exception as e: pass +! try: sys.meta_path = old_meta_path +! except Exception as e: pass +! try: sys.path_hooks = old_path_hooks +! except Exception as e: pass +! if e: +! raise e +! +! def path_hook(d): +! if d == VIM_SPECIAL_PATH: +! return vim +! raise ImportError +! +! sys.path_hooks.append(path_hook) + + Implementation for python 3 is cleaner: code is similar to the following, but, + again, written in C: > +--- 315,367 ---- + {rtp}/python2 (or python3) and {rtp}/pythonx (for both python versions) for + each {rtp} found in 'runtimepath'. + +! Implementation for python 2 is similar to the following, but written in C: > + +! from imp import find_module, load_module +! import vim + import sys + +! class VimModuleLoader(object): +! def __init__(self, module): +! self.module = module +! +! def load_module(self, fullname, path=None): +! return self.module +! +! def _find_module(fullname, oldtail, path): +! idx = oldtail.find('.') +! if idx > 0: +! name = oldtail[:idx] +! tail = oldtail[idx+1:] +! fmr = find_module(name, path) +! module = load_module(fullname[:-len(oldtail)] + name, *fmr) +! return _find_module(fullname, tail, module.__path__) +! else: +! fmr = find_module(fullname, path) +! return load_module(fullname, *fmr) +! +! # It uses vim module itself in place of VimPathFinder class: it does not +! # matter for python which object has find_module function attached to as +! # an attribute. +! class VimPathFinder(object): +! def find_module(cls, fullname, path=None): +! try: +! return VimModuleLoader(_find_module(fullname, fullname, path or vim._get_paths())) +! except ImportError: +! return None +! find_module = classmethod(find_module) +! +! def load_module(cls, fullname, path=None): +! return _find_module(fullname, fullname, path or vim._get_paths()) +! load_module = classmethod(load_module) +! +! def hook(path): +! if path == vim.VIM_SPECIAL_PATH: +! return VimPathFinder +! else: +! raise ImportError + +! sys.path_hooks.append(hook) + + Implementation for python 3 is cleaner: code is similar to the following, but, + again, written in C: > +*************** +*** 395,408 **** + Note: you must not use value of this constant directly, always use + vim.VIM_SPECIAL_PATH object. + +- vim.load_module(name) *python-load_module* + vim.find_module(...) *python-find_module* + vim.path_hook(path) *python-path_hook* + Methods or objects used to implement path loading as described above. + You should not be using any of these directly except for vim.path_hook + in case you need to do something with sys.meta_path. It is not + guaranteed that any of the objects will exist in the future vim +! versions. In fact, load_module and find_module methods do not exists + in python3. + + vim._get_paths *python-_get_paths* +--- 396,408 ---- + Note: you must not use value of this constant directly, always use + vim.VIM_SPECIAL_PATH object. + + vim.find_module(...) *python-find_module* + vim.path_hook(path) *python-path_hook* + Methods or objects used to implement path loading as described above. + You should not be using any of these directly except for vim.path_hook + in case you need to do something with sys.meta_path. It is not + guaranteed that any of the objects will exist in the future vim +! versions. In fact, find_module methods do not exists + in python3. + + vim._get_paths *python-_get_paths* +*** ../vim-7.3.1171/src/if_py_both.h 2013-06-10 21:27:18.000000000 +0200 +--- src/if_py_both.h 2013-06-12 14:12:13.000000000 +0200 +*************** +*** 940,946 **** + {"foreach_rtp", VimForeachRTP, METH_VARARGS, "Call given callable for each path in &rtp"}, + #if PY_MAJOR_VERSION < 3 + {"find_module", FinderFindModule, METH_VARARGS, "Internal use only, returns loader object for any input it receives"}, +- {"load_module", LoaderLoadModule, METH_VARARGS, "Internal use only, tries importing the given module from &rtp by temporary mocking sys.path (to an rtp-based one) and unsetting sys.meta_path and sys.path_hooks"}, + #endif + {"path_hook", VimPathHook, METH_VARARGS, "Hook function to install in sys.path_hooks"}, + {"_get_paths", (PyCFunction)Vim_GetPaths, METH_NOARGS, "Get &rtp-based additions to sys.path"}, +--- 940,945 ---- +*************** +*** 5195,5200 **** +--- 5194,5206 ---- + PyObject_HEAD + } FinderObject; + static PyTypeObject FinderType; ++ #else ++ typedef struct ++ { ++ PyObject_HEAD ++ PyObject *module; ++ } LoaderObject; ++ static PyTypeObject LoaderType; + #endif + + static void +*************** +*** 5444,5449 **** +--- 5450,5457 ---- + PYTYPE_READY(OutputType); + #if PY_MAJOR_VERSION >= 3 + PYTYPE_READY(FinderType); ++ #else ++ PYTYPE_READY(LoaderType); + #endif + return 0; + } +*************** +*** 5570,5575 **** +--- 5578,5585 ---- + {"Options", (PyObject *)&OptionsType}, + #if PY_MAJOR_VERSION >= 3 + {"Finder", (PyObject *)&FinderType}, ++ #else ++ {"Loader", (PyObject *)&LoaderType}, + #endif + }; + +*************** +*** 5666,5671 **** +--- 5676,5684 ---- + ADD_CHECKED_OBJECT(m, "_find_module", + (py_find_module = PyObject_GetAttrString(path_finder, + "find_module"))); ++ #else ++ ADD_OBJECT(m, "_find_module", py_find_module); ++ ADD_OBJECT(m, "_load_module", py_load_module); + #endif + + return 0; +*** ../vim-7.3.1171/src/if_python.c 2013-06-10 21:27:18.000000000 +0200 +--- src/if_python.c 2013-06-12 14:14:27.000000000 +0200 +*************** +*** 150,155 **** +--- 150,156 ---- + # undef Py_InitModule4 + # undef Py_InitModule4_64 + # undef PyObject_CallMethod ++ # undef PyObject_CallFunction + + /* + * Wrapper defines +*************** +*** 219,224 **** +--- 220,226 ---- + # define PyObject_HasAttrString dll_PyObject_HasAttrString + # define PyObject_SetAttrString dll_PyObject_SetAttrString + # define PyObject_CallFunctionObjArgs dll_PyObject_CallFunctionObjArgs ++ # define PyObject_CallFunction dll_PyObject_CallFunction + # define PyObject_Call dll_PyObject_Call + # define PyString_AsString dll_PyString_AsString + # define PyString_AsStringAndSize dll_PyString_AsStringAndSize +*************** +*** 357,362 **** +--- 359,365 ---- + static int (*dll_PyObject_HasAttrString)(PyObject *, const char *); + static PyObject* (*dll_PyObject_SetAttrString)(PyObject *, const char *, PyObject *); + static PyObject* (*dll_PyObject_CallFunctionObjArgs)(PyObject *, ...); ++ static PyObject* (*dll_PyObject_CallFunction)(PyObject *, char *, ...); + static PyObject* (*dll_PyObject_Call)(PyObject *, PyObject *, PyObject *); + static char*(*dll_PyString_AsString)(PyObject *); + static int(*dll_PyString_AsStringAndSize)(PyObject *, char **, int *); +*************** +*** 528,533 **** +--- 531,537 ---- + {"PyObject_HasAttrString", (PYTHON_PROC*)&dll_PyObject_HasAttrString}, + {"PyObject_SetAttrString", (PYTHON_PROC*)&dll_PyObject_SetAttrString}, + {"PyObject_CallFunctionObjArgs", (PYTHON_PROC*)&dll_PyObject_CallFunctionObjArgs}, ++ {"PyObject_CallFunction", (PYTHON_PROC*)&dll_PyObject_CallFunction}, + {"PyObject_Call", (PYTHON_PROC*)&dll_PyObject_Call}, + {"PyString_AsString", (PYTHON_PROC*)&dll_PyString_AsString}, + {"PyString_AsStringAndSize", (PYTHON_PROC*)&dll_PyString_AsStringAndSize}, +*************** +*** 748,757 **** + static PyObject *ListGetattr(PyObject *, char *); + static PyObject *FunctionGetattr(PyObject *, char *); + +- static PyObject *LoaderLoadModule(PyObject *, PyObject *); + static PyObject *FinderFindModule(PyObject *, PyObject *); + static PyObject *VimPathHook(PyObject *, PyObject *); + + #ifndef Py_VISIT + # define Py_VISIT(obj) visit(obj, arg) + #endif +--- 752,763 ---- + static PyObject *ListGetattr(PyObject *, char *); + static PyObject *FunctionGetattr(PyObject *, char *); + + static PyObject *FinderFindModule(PyObject *, PyObject *); + static PyObject *VimPathHook(PyObject *, PyObject *); + ++ static PyObject *py_find_module; ++ static PyObject *py_load_module; ++ + #ifndef Py_VISIT + # define Py_VISIT(obj) visit(obj, arg) + #endif +*************** +*** 1376,1465 **** + } + #endif + + static PyObject * +! LoaderLoadModule(PyObject *self, PyObject *args) + { +! char *fullname; +! PyObject *path; +! PyObject *meta_path; +! PyObject *path_hooks; +! PyObject *new_path; +! PyObject *r; +! PyObject *new_list; + +! if (!PyArg_ParseTuple(args, "s", &fullname)) +! return NULL; + +! if (!(new_path = Vim_GetPaths(self))) + return NULL; + +! if (!(new_list = PyList_New(0))) + return NULL; + +! #define GET_SYS_OBJECT(objstr, obj) \ +! obj = PySys_GetObject(objstr); \ +! PyErr_Clear(); \ +! Py_XINCREF(obj); + +! GET_SYS_OBJECT("meta_path", meta_path); +! if (PySys_SetObject("meta_path", new_list)) + { +! Py_XDECREF(meta_path); +! Py_DECREF(new_list); +! return NULL; + } +! Py_DECREF(new_list); /* Now it becomes a reference borrowed from +! sys.meta_path */ + +! #define RESTORE_SYS_OBJECT(objstr, obj) \ +! if (obj) \ +! { \ +! PySys_SetObject(objstr, obj); \ +! Py_DECREF(obj); \ + } + +! GET_SYS_OBJECT("path_hooks", path_hooks); +! if (PySys_SetObject("path_hooks", new_list)) +! { +! RESTORE_SYS_OBJECT("meta_path", meta_path); +! Py_XDECREF(path_hooks); + return NULL; +- } + +! GET_SYS_OBJECT("path", path); +! if (PySys_SetObject("path", new_path)) +! { +! RESTORE_SYS_OBJECT("meta_path", meta_path); +! RESTORE_SYS_OBJECT("path_hooks", path_hooks); +! Py_XDECREF(path); + return NULL; +- } +- Py_DECREF(new_path); + +! r = PyImport_ImportModule(fullname); + +! RESTORE_SYS_OBJECT("meta_path", meta_path); +! RESTORE_SYS_OBJECT("path_hooks", path_hooks); +! RESTORE_SYS_OBJECT("path", path); + +! if (PyErr_Occurred()) + { +! Py_XDECREF(r); + return NULL; + } + +! return r; +! } + +! static PyObject * +! FinderFindModule(PyObject *self UNUSED, PyObject *args UNUSED) +! { +! /* +! * Don't bother actually finding the module, it is delegated to the "loader" +! * object (which is basically the same object: vim module). +! */ +! Py_INCREF(vim_module); +! return vim_module; + } + + static PyObject * +--- 1382,1534 ---- + } + #endif + ++ static void ++ LoaderDestructor(LoaderObject *self) ++ { ++ Py_DECREF(self->module); ++ DESTRUCTOR_FINISH(self); ++ } ++ + static PyObject * +! LoaderLoadModule(LoaderObject *self, PyObject *args UNUSED) + { +! PyObject *r = self->module; + +! Py_INCREF(r); +! return r; +! } + +! static struct PyMethodDef LoaderMethods[] = { +! /* name, function, calling, doc */ +! {"load_module", (PyCFunction)LoaderLoadModule, METH_VARARGS, ""}, +! { NULL, NULL, 0, NULL} +! }; +! +! static PyObject * +! call_load_module(char *name, int len, PyObject *find_module_result) +! { +! PyObject *fd, *pathname, *description; +! +! if (!PyTuple_Check(find_module_result) +! || PyTuple_GET_SIZE(find_module_result) != 3) +! { +! PyErr_SetString(PyExc_TypeError, +! _("expected 3-tuple as imp.find_module() result")); + return NULL; ++ } + +! if (!(fd = PyTuple_GET_ITEM(find_module_result, 0)) +! || !(pathname = PyTuple_GET_ITEM(find_module_result, 1)) +! || !(description = PyTuple_GET_ITEM(find_module_result, 2))) +! { +! PyErr_SetString(PyExc_RuntimeError, +! _("internal error: imp.find_module returned tuple with NULL")); + return NULL; ++ } ++ ++ return PyObject_CallFunction(py_load_module, ++ "s#OOO", name, len, fd, pathname, description); ++ } + +! static PyObject * +! find_module(char *fullname, char *tail, PyObject *new_path) +! { +! PyObject *find_module_result; +! PyObject *module; +! char *dot; + +! if ((dot = (char *) vim_strchr((char_u *) tail, '.'))) + { +! /* +! * There is a dot in the name: call find_module recursively without the +! * first component +! */ +! PyObject *newest_path; +! int partlen = (int) (dot - 1 - tail); +! +! if (!(find_module_result = PyObject_CallFunction(py_find_module, +! "s#O", tail, partlen, new_path))) +! return NULL; +! +! if (!(module = call_load_module( +! fullname, +! ((int) (tail - fullname)) + partlen, +! find_module_result))) +! { +! Py_DECREF(find_module_result); +! return NULL; +! } +! +! Py_DECREF(find_module_result); +! +! if (!(newest_path = PyObject_GetAttrString(module, "__path__"))) +! { +! Py_DECREF(module); +! return NULL; +! } +! +! Py_DECREF(module); +! +! module = find_module(fullname, dot + 1, newest_path); +! +! Py_DECREF(newest_path); +! +! return module; + } +! else +! { +! if (!(find_module_result = PyObject_CallFunction(py_find_module, +! "sO", tail, new_path))) +! return NULL; +! +! if (!(module = call_load_module( +! fullname, +! STRLEN(fullname), +! find_module_result))) +! { +! Py_DECREF(find_module_result); +! return NULL; +! } + +! Py_DECREF(find_module_result); +! +! return module; + } ++ } + +! static PyObject * +! FinderFindModule(PyObject *self, PyObject *args) +! { +! char *fullname; +! PyObject *module; +! PyObject *new_path; +! LoaderObject *loader; +! +! if (!PyArg_ParseTuple(args, "s", &fullname)) + return NULL; + +! if (!(new_path = Vim_GetPaths(self))) + return NULL; + +! module = find_module(fullname, fullname, new_path); + +! Py_DECREF(new_path); + +! if (!module) + { +! Py_INCREF(Py_None); +! return Py_None; +! } +! +! if (!(loader = PyObject_NEW(LoaderObject, &LoaderType))) +! { +! Py_DECREF(module); + return NULL; + } + +! loader->module = module; + +! return (PyObject *) loader; + } + + static PyObject * +*************** +*** 1483,1489 **** + PythonMod_Init(void) + { + /* The special value is removed from sys.path in Python_Init(). */ +! static char *(argv[2]) = {"/must>not&exist/foo", NULL}; + + if (init_types()) + return -1; +--- 1552,1585 ---- + PythonMod_Init(void) + { + /* The special value is removed from sys.path in Python_Init(). */ +! static char *(argv[2]) = {"/must>not&exist/foo", NULL}; +! PyObject *imp; +! +! if (!(imp = PyImport_ImportModule("imp"))) +! return -1; +! +! if (!(py_find_module = PyObject_GetAttrString(imp, "find_module"))) +! { +! Py_DECREF(imp); +! return -1; +! } +! +! if (!(py_load_module = PyObject_GetAttrString(imp, "load_module"))) +! { +! Py_DECREF(py_find_module); +! Py_DECREF(imp); +! return -1; +! } +! +! Py_DECREF(imp); +! +! vim_memset(&LoaderType, 0, sizeof(LoaderType)); +! LoaderType.tp_name = "vim.Loader"; +! LoaderType.tp_basicsize = sizeof(LoaderObject); +! LoaderType.tp_flags = Py_TPFLAGS_DEFAULT; +! LoaderType.tp_doc = "vim message object"; +! LoaderType.tp_methods = LoaderMethods; +! LoaderType.tp_dealloc = (destructor)LoaderDestructor; + + if (init_types()) + return -1; +*** ../vim-7.3.1171/src/testdir/python2/module.py 2013-06-11 18:47:37.000000000 +0200 +--- src/testdir/python2/module.py 2013-06-12 14:12:13.000000000 +0200 +*************** +*** 1 **** +--- 1,2 ---- ++ import before_1 + dir = '2' +*** ../vim-7.3.1171/src/testdir/python3/module.py 2013-06-11 18:47:37.000000000 +0200 +--- src/testdir/python3/module.py 2013-06-12 14:12:13.000000000 +0200 +*************** +*** 1 **** +--- 1,2 ---- ++ import before_1 + dir = '3' +*** ../vim-7.3.1171/src/testdir/python_after/after.py 1970-01-01 01:00:00.000000000 +0100 +--- src/testdir/python_after/after.py 2013-06-12 14:12:13.000000000 +0200 +*************** +*** 0 **** +--- 1,2 ---- ++ import before_2 ++ dir = "after" +*** ../vim-7.3.1171/src/testdir/python_before/before.py 1970-01-01 01:00:00.000000000 +0100 +--- src/testdir/python_before/before.py 2013-06-12 14:12:13.000000000 +0200 +*************** +*** 0 **** +--- 1 ---- ++ dir = "before" +*** ../vim-7.3.1171/src/testdir/test86.in 2013-06-11 18:47:37.000000000 +0200 +--- src/testdir/test86.in 2013-06-12 14:12:13.000000000 +0200 +*************** +*** 8,13 **** +--- 8,14 ---- + STARTTEST + :so small.vim + :set encoding=latin1 ++ :set noswapfile + :if !has('python') | e! test.ok | wq! test.out | endif + :lang C + :py import vim +*************** +*** 1071,1080 **** +--- 1072,1087 ---- + :" + :" Test import + py << EOF ++ sys.path.insert(0, os.path.join(os.getcwd(), 'python_before')) ++ sys.path.append(os.path.join(os.getcwd(), 'python_after')) + vim.options['rtp'] = os.getcwd().replace(',', '\\,').replace('\\', '\\\\') + from module import dir as d + from modulex import ddir + cb.append(d + ',' + ddir) ++ import before ++ cb.append(before.dir) ++ import after ++ cb.append(after.dir) + EOF + :" + :" Test exceptions +*** ../vim-7.3.1171/src/testdir/test86.ok 2013-06-11 18:47:37.000000000 +0200 +--- src/testdir/test86.ok 2013-06-12 14:12:13.000000000 +0200 +*************** +*** 1084,1089 **** +--- 1084,1091 ---- + vim.current.tabpage = True:(, TypeError('expected vim.TabPage object',)) + vim.current.xxx = True:(, AttributeError('xxx',)) + 2,xx ++ before ++ after + vim.command("throw 'abc'"):(, error('abc',)) + Exe("throw 'def'"):(, error('def',)) + vim.eval("Exe('throw ''ghi''')"):(, error('ghi',)) +*** ../vim-7.3.1171/src/testdir/test87.in 2013-06-11 18:47:37.000000000 +0200 +--- src/testdir/test87.in 2013-06-12 14:12:13.000000000 +0200 +*************** +*** 2,7 **** +--- 2,8 ---- + + STARTTEST + :so small.vim ++ :set noswapfile + :if !has('python3') | e! test.ok | wq! test.out | endif + :lang C + :py3 import vim +*************** +*** 1038,1047 **** +--- 1039,1054 ---- + :" + :" Test import + py3 << EOF ++ sys.path.insert(0, os.path.join(os.getcwd(), 'python_before')) ++ sys.path.append(os.path.join(os.getcwd(), 'python_after')) + vim.options['rtp'] = os.getcwd().replace(',', '\\,').replace('\\', '\\\\') + from module import dir as d + from modulex import ddir + cb.append(d + ',' + ddir) ++ import before ++ cb.append(before.dir) ++ import after ++ cb.append(after.dir) + EOF + :" + :" Test exceptions +*** ../vim-7.3.1171/src/testdir/test87.ok 2013-06-11 18:47:37.000000000 +0200 +--- src/testdir/test87.ok 2013-06-12 14:12:13.000000000 +0200 +*************** +*** 1093,1098 **** +--- 1093,1100 ---- + vim.current.tabpage = True:(, TypeError('expected vim.TabPage object',)) + vim.current.xxx = True:(, AttributeError('xxx',)) + 3,xx ++ before ++ after + vim.command("throw 'abc'"):(, error('abc',)) + Exe("throw 'def'"):(, error('def',)) + vim.eval("Exe('throw ''ghi''')"):(, error('ghi',)) +*** ../vim-7.3.1171/Filelist 2013-06-11 18:47:37.000000000 +0200 +--- Filelist 2013-06-12 14:13:57.000000000 +0200 +*************** +*** 87,92 **** +--- 87,94 ---- + src/testdir/python2/*.py \ + src/testdir/python3/*.py \ + src/testdir/pythonx/*.py \ ++ src/testdir/python_after/*.py \ ++ src/testdir/python_before/*.py \ + src/proto.h \ + src/proto/blowfish.pro \ + src/proto/buffer.pro \ +*** ../vim-7.3.1171/src/version.c 2013-06-12 14:10:23.000000000 +0200 +--- src/version.c 2013-06-12 14:14:12.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1172, + /**/ + +-- +Microsoft says that MS-Windows is much better for you than Linux. +That's like the Pope saying that catholicism is much better for +you than protestantism. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 52c181a8bfd6084fe4f6beb5dc35db3ee2b5fce5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:28:59 +0200 Subject: [PATCH 1065/3340] - patchlevel 1173 --- 7.3.1173 | 1405 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1405 insertions(+) create mode 100644 7.3.1173 diff --git a/7.3.1173 b/7.3.1173 new file mode 100644 index 00000000..fce4e879 --- /dev/null +++ b/7.3.1173 @@ -0,0 +1,1405 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1173 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1173 +Problem: Python 2 tests don't have the same output everywhere. +Solution: Make the Python 2 tests more portable. (ZyX) +Files: src/testdir/test86.in, src/testdir/test86.ok + + +*** ../vim-7.3.1172/src/testdir/test86.in 2013-06-12 14:20:15.000000000 +0200 +--- src/testdir/test86.in 2013-06-12 14:21:28.000000000 +0200 +*************** +*** 45,53 **** + dk = d.keys() + dv = d.values() + di = d.items() +! dk.sort(key=repr) +! dv.sort(key=repr) +! di.sort(key=repr) + EOF + :$put =pyeval('d[''f''](self={})') + :$put =pyeval('repr(dk)') +--- 45,54 ---- + dk = d.keys() + dv = d.values() + di = d.items() +! cmpfun = lambda a, b: cmp(repr(a), repr(b)) +! dk.sort(cmpfun) +! dv.sort(cmpfun) +! di.sort(cmpfun) + EOF + :$put =pyeval('d[''f''](self={})') + :$put =pyeval('repr(dk)') +*************** +*** 813,819 **** + try: + exec(expr, g, l) + except: +! cb.append(expr + ':' + repr(sys.exc_info()[:2])) + else: + cb.append(expr + ':NOT FAILED') + d = vim.Dictionary() +--- 814,830 ---- + try: + exec(expr, g, l) + except: +! ei = sys.exc_info() +! msg = sys.exc_info()[0].__name__ + ':' + repr(sys.exc_info()[1].args) +! msg = msg.replace('TypeError:(\'argument 1 ', 'TypeError:(\'') +! if expr.find('None') > -1: +! msg = msg.replace('TypeError:(\'iteration over non-sequence\',)', +! 'TypeError:("\'NoneType\' object is not iterable",)') +! if expr == 'fd(self=[])': +! # HACK: PyMapping_Check changed meaning +! msg = msg.replace('AttributeError:(\'keys\',)', +! 'TypeError:(\'unable to convert object to vim dictionary\',)') +! cb.append(expr + ':' + msg) + else: + cb.append(expr + ':NOT FAILED') + d = vim.Dictionary() +*** ../vim-7.3.1172/src/testdir/test86.ok 2013-06-12 14:20:15.000000000 +0200 +--- src/testdir/test86.ok 2013-06-12 14:21:28.000000000 +0200 +*************** +*** 437,1094 **** + test86.in + > Output + >> OutputSetattr +! del sys.stdout.softspace:(, AttributeError("can't delete OutputObject attributes",)) +! sys.stdout.softspace = []:(, TypeError('softspace must be an integer',)) +! sys.stdout.attr = None:(, AttributeError('invalid attribute',)) + >> OutputWrite +! sys.stdout.write(None):(, TypeError('coercing to Unicode: need string or buffer, NoneType found',)) + >> OutputWriteLines +! sys.stdout.writelines(None):(, TypeError("'NoneType' object is not iterable",)) +! sys.stdout.writelines([1]):(, TypeError('writelines() requires list of strings',)) + > VimCommand +! vim.command(1):(, TypeError('must be string, not int',)) + > VimToPython + > VimEval +! vim.eval(1):(, TypeError('must be string, not int',)) + > VimEvalPy +! vim.bindeval(1):(, TypeError('must be string, not int',)) + > VimStrwidth +! vim.strwidth(1):(, TypeError('must be string, not int',)) + > Dictionary + >> DictionaryConstructor +! vim.Dictionary("abc"):(, ValueError('expected sequence element of size 2',)) + >> DictionarySetattr +! del d.locked:(, AttributeError('cannot delete vim.Dictionary attributes',)) +! d.locked = FailingTrue():(, NotImplementedError()) +! vim.vvars.locked = False:(, TypeError('cannot modify fixed dictionary',)) +! d.scope = True:(, AttributeError('cannot set this attribute',)) +! d.xxx = True:(, AttributeError('cannot set this attribute',)) + >> _DictionaryItem +! d.get("a", 2, 3):(, TypeError('function takes at most 2 arguments (3 given)',)) + >>> Testing StringToChars using d.get(%s) +! d.get(1):(, TypeError('object must be string',)) +! d.get(u"\0"):(, TypeError('expected string without null bytes',)) +! d.get("\0"):(, TypeError('expected string without null bytes',)) + <<< Finished +! d.pop("a"):(, KeyError('a',)) +! dl.pop("a"):(, error('dict is locked',)) + >> DictionaryIterNext +! for i in ned: ned["a"] = 1:(, RuntimeError('hashtab changed during iteration',)) + >> DictionaryAssItem +! dl["b"] = 1:(, error('dict is locked',)) + >>> Testing StringToChars using d[%s] = 1 +! d[1] = 1:(, TypeError('object must be string',)) +! d[u"\0"] = 1:(, TypeError('expected string without null bytes',)) +! d["\0"] = 1:(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using d["a"] = {%s : 1} +! d["a"] = {1 : 1}:(, TypeError('object must be string',)) +! d["a"] = {u"\0" : 1}:(, TypeError('expected string without null bytes',)) +! d["a"] = {"\0" : 1}:(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : {%s : 1}} +! d["a"] = {"abc" : {1 : 1}}:(, TypeError('object must be string',)) +! d["a"] = {"abc" : {u"\0" : 1}}:(, TypeError('expected string without null bytes',)) +! d["a"] = {"abc" : {"\0" : 1}}:(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : Mapping({%s : 1})} +! d["a"] = {"abc" : Mapping({1 : 1})}:(, TypeError('object must be string',)) +! d["a"] = {"abc" : Mapping({u"\0" : 1})}:(, TypeError('expected string without null bytes',)) +! d["a"] = {"abc" : Mapping({"\0" : 1})}:(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : FailingIter()}:(, TypeError('unable to convert to vim structure',)) +! d["a"] = {"abc" : FailingIterNext()}:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : None}:(, TypeError('unable to convert to vim structure',)) +! d["a"] = {"abc" : {"": 1}}:(, ValueError('empty keys are not allowed',)) +! d["a"] = {"abc" : {u"": 1}}:(, ValueError('empty keys are not allowed',)) +! d["a"] = {"abc" : FailingMapping()}:(, NotImplementedError()) +! d["a"] = {"abc" : FailingMappingKey()}:(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) +! d["a"] = Mapping({1 : 1}):(, TypeError('object must be string',)) +! d["a"] = Mapping({u"\0" : 1}):(, TypeError('expected string without null bytes',)) +! d["a"] = Mapping({"\0" : 1}):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : {%s : 1}}) +! d["a"] = Mapping({"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! d["a"] = Mapping({"abc" : {u"\0" : 1}}):(, TypeError('expected string without null bytes',)) +! d["a"] = Mapping({"abc" : {"\0" : 1}}):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : Mapping({%s : 1})}) +! d["a"] = Mapping({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! d["a"] = Mapping({"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected string without null bytes',)) +! d["a"] = Mapping({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) +! d["a"] = Mapping({"abc" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : None}):(, TypeError('unable to convert to vim structure',)) +! d["a"] = Mapping({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! d["a"] = Mapping({"abc" : {u"": 1}}):(, ValueError('empty keys are not allowed',)) +! d["a"] = Mapping({"abc" : FailingMapping()}):(, NotImplementedError()) +! d["a"] = Mapping({"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d["a"] = %s +! d["a"] = FailingIter():(, TypeError('unable to convert to vim structure',)) +! d["a"] = FailingIterNext():(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = %s +! d["a"] = None:(, TypeError('unable to convert to vim structure',)) +! d["a"] = {"": 1}:(, ValueError('empty keys are not allowed',)) +! d["a"] = {u"": 1}:(, ValueError('empty keys are not allowed',)) +! d["a"] = FailingMapping():(, NotImplementedError()) +! d["a"] = FailingMappingKey():(, NotImplementedError()) + <<< Finished + >> DictionaryUpdate + >>> kwargs + >>> iter +! d.update(FailingMapping()):(, NotImplementedError()) +! d.update([FailingIterNext()]):(, NotImplementedError()) + >>> Testing StringToChars using d.update({%s : 1}) +! d.update({1 : 1}):(, TypeError('object must be string',)) +! d.update({u"\0" : 1}):(, TypeError('expected string without null bytes',)) +! d.update({"\0" : 1}):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : {%s : 1}}) +! d.update({"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! d.update({"abc" : {u"\0" : 1}}):(, TypeError('expected string without null bytes',)) +! d.update({"abc" : {"\0" : 1}}):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : Mapping({%s : 1})}) +! d.update({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! d.update({"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected string without null bytes',)) +! d.update({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using d.update({"abc" : %s}) +! d.update({"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) +! d.update({"abc" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update({"abc" : %s}) +! d.update({"abc" : None}):(, TypeError('unable to convert to vim structure',)) +! d.update({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! d.update({"abc" : {u"": 1}}):(, ValueError('empty keys are not allowed',)) +! d.update({"abc" : FailingMapping()}):(, NotImplementedError()) +! d.update({"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) +! d.update(Mapping({1 : 1})):(, TypeError('object must be string',)) +! d.update(Mapping({u"\0" : 1})):(, TypeError('expected string without null bytes',)) +! d.update(Mapping({"\0" : 1})):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : {%s : 1}})) +! d.update(Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) +! d.update(Mapping({"abc" : {u"\0" : 1}})):(, TypeError('expected string without null bytes',)) +! d.update(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : Mapping({%s : 1})})) +! d.update(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) +! d.update(Mapping({"abc" : Mapping({u"\0" : 1})})):(, TypeError('expected string without null bytes',)) +! d.update(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert to vim structure',)) +! d.update(Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) +! d.update(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! d.update(Mapping({"abc" : {u"": 1}})):(, ValueError('empty keys are not allowed',)) +! d.update(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) +! d.update(Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d.update(%s) +! d.update(FailingIter()):(, NotImplementedError()) +! d.update(FailingIterNext()):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update(%s) +! d.update(None):(, TypeError("'NoneType' object is not iterable",)) +! d.update({"": 1}):(, ValueError('empty keys are not allowed',)) +! d.update({u"": 1}):(, ValueError('empty keys are not allowed',)) +! d.update(FailingMapping()):(, NotImplementedError()) +! d.update(FailingMappingKey()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update(((%s, 0),)) +! d.update(((1, 0),)):(, TypeError('object must be string',)) +! d.update(((u"\0", 0),)):(, TypeError('expected string without null bytes',)) +! d.update((("\0", 0),)):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", {%s : 1}),)) +! d.update((("a", {1 : 1}),)):(, TypeError('object must be string',)) +! d.update((("a", {u"\0" : 1}),)):(, TypeError('expected string without null bytes',)) +! d.update((("a", {"\0" : 1}),)):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : {%s : 1}}),)) +! d.update((("a", {"abc" : {1 : 1}}),)):(, TypeError('object must be string',)) +! d.update((("a", {"abc" : {u"\0" : 1}}),)):(, TypeError('expected string without null bytes',)) +! d.update((("a", {"abc" : {"\0" : 1}}),)):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : Mapping({%s : 1})}),)) +! d.update((("a", {"abc" : Mapping({1 : 1})}),)):(, TypeError('object must be string',)) +! d.update((("a", {"abc" : Mapping({u"\0" : 1})}),)):(, TypeError('expected string without null bytes',)) +! d.update((("a", {"abc" : Mapping({"\0" : 1})}),)):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : FailingIter()}),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", {"abc" : FailingIterNext()}),)):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : None}),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", {"abc" : {"": 1}}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", {"abc" : {u"": 1}}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", {"abc" : FailingMapping()}),)):(, NotImplementedError()) +! d.update((("a", {"abc" : FailingMappingKey()}),)):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) +! d.update((("a", Mapping({1 : 1})),)):(, TypeError('object must be string',)) +! d.update((("a", Mapping({u"\0" : 1})),)):(, TypeError('expected string without null bytes',)) +! d.update((("a", Mapping({"\0" : 1})),)):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : {%s : 1}})),)) +! d.update((("a", Mapping({"abc" : {1 : 1}})),)):(, TypeError('object must be string',)) +! d.update((("a", Mapping({"abc" : {u"\0" : 1}})),)):(, TypeError('expected string without null bytes',)) +! d.update((("a", Mapping({"abc" : {"\0" : 1}})),)):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : Mapping({%s : 1})})),)) +! d.update((("a", Mapping({"abc" : Mapping({1 : 1})})),)):(, TypeError('object must be string',)) +! d.update((("a", Mapping({"abc" : Mapping({u"\0" : 1})})),)):(, TypeError('expected string without null bytes',)) +! d.update((("a", Mapping({"abc" : Mapping({"\0" : 1})})),)):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : FailingIter()})),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", Mapping({"abc" : FailingIterNext()})),)):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : None})),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", Mapping({"abc" : {"": 1}})),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", Mapping({"abc" : {u"": 1}})),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", Mapping({"abc" : FailingMapping()})),)):(, NotImplementedError()) +! d.update((("a", Mapping({"abc" : FailingMappingKey()})),)):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d.update((("a", %s),)) +! d.update((("a", FailingIter()),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", FailingIterNext()),)):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", %s),)) +! d.update((("a", None),)):(, TypeError('unable to convert to vim structure',)) +! d.update((("a", {"": 1}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", {u"": 1}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", FailingMapping()),)):(, NotImplementedError()) +! d.update((("a", FailingMappingKey()),)):(, NotImplementedError()) + <<< Finished + >> DictionaryPopItem +! d.popitem(1, 2):(, TypeError('popitem() takes no arguments (2 given)',)) + >> DictionaryHasKey +! d.has_key():(, TypeError('function takes exactly 1 argument (0 given)',)) + > List + >> ListConstructor +! vim.List(1, 2):(, TypeError('function takes at most 1 argument (2 given)',)) +! vim.List(a=1):(, TypeError('list constructor does not accept keyword arguments',)) + >>> Testing StringToChars using vim.List([{%s : 1}]) +! vim.List([{1 : 1}]):(, TypeError('object must be string',)) +! vim.List([{u"\0" : 1}]):(, TypeError('expected string without null bytes',)) +! vim.List([{"\0" : 1}]):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : {%s : 1}}]) +! vim.List([{"abc" : {1 : 1}}]):(, TypeError('object must be string',)) +! vim.List([{"abc" : {u"\0" : 1}}]):(, TypeError('expected string without null bytes',)) +! vim.List([{"abc" : {"\0" : 1}}]):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : Mapping({%s : 1})}]) +! vim.List([{"abc" : Mapping({1 : 1})}]):(, TypeError('object must be string',)) +! vim.List([{"abc" : Mapping({u"\0" : 1})}]):(, TypeError('expected string without null bytes',)) +! vim.List([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : FailingIter()}]):(, TypeError('unable to convert to vim structure',)) +! vim.List([{"abc" : FailingIterNext()}]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : None}]):(, TypeError('unable to convert to vim structure',)) +! vim.List([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) +! vim.List([{"abc" : {u"": 1}}]):(, ValueError('empty keys are not allowed',)) +! vim.List([{"abc" : FailingMapping()}]):(, NotImplementedError()) +! vim.List([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) +! vim.List([Mapping({1 : 1})]):(, TypeError('object must be string',)) +! vim.List([Mapping({u"\0" : 1})]):(, TypeError('expected string without null bytes',)) +! vim.List([Mapping({"\0" : 1})]):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : {%s : 1}})]) +! vim.List([Mapping({"abc" : {1 : 1}})]):(, TypeError('object must be string',)) +! vim.List([Mapping({"abc" : {u"\0" : 1}})]):(, TypeError('expected string without null bytes',)) +! vim.List([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : Mapping({%s : 1})})]) +! vim.List([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('object must be string',)) +! vim.List([Mapping({"abc" : Mapping({u"\0" : 1})})]):(, TypeError('expected string without null bytes',)) +! vim.List([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : FailingIter()})]):(, TypeError('unable to convert to vim structure',)) +! vim.List([Mapping({"abc" : FailingIterNext()})]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : None})]):(, TypeError('unable to convert to vim structure',)) +! vim.List([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) +! vim.List([Mapping({"abc" : {u"": 1}})]):(, ValueError('empty keys are not allowed',)) +! vim.List([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) +! vim.List([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using vim.List([%s]) +! vim.List([FailingIter()]):(, TypeError('unable to convert to vim structure',)) +! vim.List([FailingIterNext()]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([%s]) +! vim.List([None]):(, TypeError('unable to convert to vim structure',)) +! vim.List([{"": 1}]):(, ValueError('empty keys are not allowed',)) +! vim.List([{u"": 1}]):(, ValueError('empty keys are not allowed',)) +! vim.List([FailingMapping()]):(, NotImplementedError()) +! vim.List([FailingMappingKey()]):(, NotImplementedError()) + <<< Finished + >> ListItem +! l[1000]:(, IndexError('list index out of range',)) + >> ListAssItem +! ll[1] = 2:(, error('list is locked',)) +! l[1000] = 3:(, IndexError('list index out of range',)) + >> ListAssSlice +! ll[1:100] = "abc":(, error('list is locked',)) + >>> Testing StringToChars using l[:] = [{%s : 1}] +! l[:] = [{1 : 1}]:(, TypeError('object must be string',)) +! l[:] = [{u"\0" : 1}]:(, TypeError('expected string without null bytes',)) +! l[:] = [{"\0" : 1}]:(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : {%s : 1}}] +! l[:] = [{"abc" : {1 : 1}}]:(, TypeError('object must be string',)) +! l[:] = [{"abc" : {u"\0" : 1}}]:(, TypeError('expected string without null bytes',)) +! l[:] = [{"abc" : {"\0" : 1}}]:(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : Mapping({%s : 1})}] +! l[:] = [{"abc" : Mapping({1 : 1})}]:(, TypeError('object must be string',)) +! l[:] = [{"abc" : Mapping({u"\0" : 1})}]:(, TypeError('expected string without null bytes',)) +! l[:] = [{"abc" : Mapping({"\0" : 1})}]:(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : FailingIter()}]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [{"abc" : FailingIterNext()}]:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : None}]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [{"abc" : {"": 1}}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [{"abc" : {u"": 1}}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [{"abc" : FailingMapping()}]:(, NotImplementedError()) +! l[:] = [{"abc" : FailingMappingKey()}]:(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] +! l[:] = [Mapping({1 : 1})]:(, TypeError('object must be string',)) +! l[:] = [Mapping({u"\0" : 1})]:(, TypeError('expected string without null bytes',)) +! l[:] = [Mapping({"\0" : 1})]:(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : {%s : 1}})] +! l[:] = [Mapping({"abc" : {1 : 1}})]:(, TypeError('object must be string',)) +! l[:] = [Mapping({"abc" : {u"\0" : 1}})]:(, TypeError('expected string without null bytes',)) +! l[:] = [Mapping({"abc" : {"\0" : 1}})]:(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : Mapping({%s : 1})})] +! l[:] = [Mapping({"abc" : Mapping({1 : 1})})]:(, TypeError('object must be string',)) +! l[:] = [Mapping({"abc" : Mapping({u"\0" : 1})})]:(, TypeError('expected string without null bytes',)) +! l[:] = [Mapping({"abc" : Mapping({"\0" : 1})})]:(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : FailingIter()})]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [Mapping({"abc" : FailingIterNext()})]:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : None})]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [Mapping({"abc" : {"": 1}})]:(, ValueError('empty keys are not allowed',)) +! l[:] = [Mapping({"abc" : {u"": 1}})]:(, ValueError('empty keys are not allowed',)) +! l[:] = [Mapping({"abc" : FailingMapping()})]:(, NotImplementedError()) +! l[:] = [Mapping({"abc" : FailingMappingKey()})]:(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using l[:] = [%s] +! l[:] = [FailingIter()]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [FailingIterNext()]:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [%s] +! l[:] = [None]:(, TypeError('unable to convert to vim structure',)) +! l[:] = [{"": 1}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [{u"": 1}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [FailingMapping()]:(, NotImplementedError()) +! l[:] = [FailingMappingKey()]:(, NotImplementedError()) + <<< Finished + >> ListConcatInPlace + >>> Testing StringToChars using l.extend([{%s : 1}]) +! l.extend([{1 : 1}]):(, TypeError('object must be string',)) +! l.extend([{u"\0" : 1}]):(, TypeError('expected string without null bytes',)) +! l.extend([{"\0" : 1}]):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : {%s : 1}}]) +! l.extend([{"abc" : {1 : 1}}]):(, TypeError('object must be string',)) +! l.extend([{"abc" : {u"\0" : 1}}]):(, TypeError('expected string without null bytes',)) +! l.extend([{"abc" : {"\0" : 1}}]):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : Mapping({%s : 1})}]) +! l.extend([{"abc" : Mapping({1 : 1})}]):(, TypeError('object must be string',)) +! l.extend([{"abc" : Mapping({u"\0" : 1})}]):(, TypeError('expected string without null bytes',)) +! l.extend([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : FailingIter()}]):(, TypeError('unable to convert to vim structure',)) +! l.extend([{"abc" : FailingIterNext()}]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : None}]):(, TypeError('unable to convert to vim structure',)) +! l.extend([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) +! l.extend([{"abc" : {u"": 1}}]):(, ValueError('empty keys are not allowed',)) +! l.extend([{"abc" : FailingMapping()}]):(, NotImplementedError()) +! l.extend([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) +! l.extend([Mapping({1 : 1})]):(, TypeError('object must be string',)) +! l.extend([Mapping({u"\0" : 1})]):(, TypeError('expected string without null bytes',)) +! l.extend([Mapping({"\0" : 1})]):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : {%s : 1}})]) +! l.extend([Mapping({"abc" : {1 : 1}})]):(, TypeError('object must be string',)) +! l.extend([Mapping({"abc" : {u"\0" : 1}})]):(, TypeError('expected string without null bytes',)) +! l.extend([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : Mapping({%s : 1})})]) +! l.extend([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('object must be string',)) +! l.extend([Mapping({"abc" : Mapping({u"\0" : 1})})]):(, TypeError('expected string without null bytes',)) +! l.extend([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : FailingIter()})]):(, TypeError('unable to convert to vim structure',)) +! l.extend([Mapping({"abc" : FailingIterNext()})]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : None})]):(, TypeError('unable to convert to vim structure',)) +! l.extend([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) +! l.extend([Mapping({"abc" : {u"": 1}})]):(, ValueError('empty keys are not allowed',)) +! l.extend([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) +! l.extend([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using l.extend([%s]) +! l.extend([FailingIter()]):(, TypeError('unable to convert to vim structure',)) +! l.extend([FailingIterNext()]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([%s]) +! l.extend([None]):(, TypeError('unable to convert to vim structure',)) +! l.extend([{"": 1}]):(, ValueError('empty keys are not allowed',)) +! l.extend([{u"": 1}]):(, ValueError('empty keys are not allowed',)) +! l.extend([FailingMapping()]):(, NotImplementedError()) +! l.extend([FailingMappingKey()]):(, NotImplementedError()) + <<< Finished + >> ListSetattr +! del l.locked:(, AttributeError('cannot delete vim.List attributes',)) +! l.locked = FailingTrue():(, NotImplementedError()) +! l.xxx = True:(, AttributeError('cannot set this attribute',)) + > Function + >> FunctionConstructor +! vim.Function("123"):(, ValueError('unnamed function does not exist',)) +! vim.Function("xxx_non_existent_function_xxx"):(, ValueError('function does not exist',)) + vim.Function("xxx#non#existent#function#xxx"):NOT FAILED + >> FunctionCall + >>> Testing StringToChars using f({%s : 1}) +! f({1 : 1}):(, TypeError('object must be string',)) +! f({u"\0" : 1}):(, TypeError('expected string without null bytes',)) +! f({"\0" : 1}):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using f({"abc" : {%s : 1}}) +! f({"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! f({"abc" : {u"\0" : 1}}):(, TypeError('expected string without null bytes',)) +! f({"abc" : {"\0" : 1}}):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using f({"abc" : Mapping({%s : 1})}) +! f({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! f({"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected string without null bytes',)) +! f({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using f({"abc" : %s}) +! f({"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) +! f({"abc" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using f({"abc" : %s}) +! f({"abc" : None}):(, TypeError('unable to convert to vim structure',)) +! f({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! f({"abc" : {u"": 1}}):(, ValueError('empty keys are not allowed',)) +! f({"abc" : FailingMapping()}):(, NotImplementedError()) +! f({"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) +! f(Mapping({1 : 1})):(, TypeError('object must be string',)) +! f(Mapping({u"\0" : 1})):(, TypeError('expected string without null bytes',)) +! f(Mapping({"\0" : 1})):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : {%s : 1}})) +! f(Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) +! f(Mapping({"abc" : {u"\0" : 1}})):(, TypeError('expected string without null bytes',)) +! f(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : Mapping({%s : 1})})) +! f(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) +! f(Mapping({"abc" : Mapping({u"\0" : 1})})):(, TypeError('expected string without null bytes',)) +! f(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert to vim structure',)) +! f(Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) +! f(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! f(Mapping({"abc" : {u"": 1}})):(, ValueError('empty keys are not allowed',)) +! f(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) +! f(Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using f(%s) +! f(FailingIter()):(, TypeError('unable to convert to vim structure',)) +! f(FailingIterNext()):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using f(%s) +! f(None):(, TypeError('unable to convert to vim structure',)) +! f({"": 1}):(, ValueError('empty keys are not allowed',)) +! f({u"": 1}):(, ValueError('empty keys are not allowed',)) +! f(FailingMapping()):(, NotImplementedError()) +! f(FailingMappingKey()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using fd(self={%s : 1}) +! fd(self={1 : 1}):(, TypeError('object must be string',)) +! fd(self={u"\0" : 1}):(, TypeError('expected string without null bytes',)) +! fd(self={"\0" : 1}):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : {%s : 1}}) +! fd(self={"abc" : {1 : 1}}):(, TypeError('object must be string',)) +! fd(self={"abc" : {u"\0" : 1}}):(, TypeError('expected string without null bytes',)) +! fd(self={"abc" : {"\0" : 1}}):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : Mapping({%s : 1})}) +! fd(self={"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) +! fd(self={"abc" : Mapping({u"\0" : 1})}):(, TypeError('expected string without null bytes',)) +! fd(self={"abc" : Mapping({"\0" : 1})}):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using fd(self={"abc" : %s}) +! fd(self={"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) +! fd(self={"abc" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self={"abc" : %s}) +! fd(self={"abc" : None}):(, TypeError('unable to convert to vim structure',)) +! fd(self={"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! fd(self={"abc" : {u"": 1}}):(, ValueError('empty keys are not allowed',)) +! fd(self={"abc" : FailingMapping()}):(, NotImplementedError()) +! fd(self={"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) +! fd(self=Mapping({1 : 1})):(, TypeError('object must be string',)) +! fd(self=Mapping({u"\0" : 1})):(, TypeError('expected string without null bytes',)) +! fd(self=Mapping({"\0" : 1})):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : {%s : 1}})) +! fd(self=Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) +! fd(self=Mapping({"abc" : {u"\0" : 1}})):(, TypeError('expected string without null bytes',)) +! fd(self=Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : Mapping({%s : 1})})) +! fd(self=Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) +! fd(self=Mapping({"abc" : Mapping({u"\0" : 1})})):(, TypeError('expected string without null bytes',)) +! fd(self=Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected string without null bytes',)) + <<< Finished + >>> Testing *Iter* using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert to vim structure',)) +! fd(self=Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) +! fd(self=Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! fd(self=Mapping({"abc" : {u"": 1}})):(, ValueError('empty keys are not allowed',)) +! fd(self=Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) +! fd(self=Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using fd(self=%s) +! fd(self=FailingIter()):(, TypeError('unable to convert object to vim dictionary',)) +! fd(self=FailingIterNext()):(, TypeError('unable to convert object to vim dictionary',)) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=%s) +! fd(self=None):(, TypeError('unable to convert object to vim dictionary',)) +! fd(self={"": 1}):(, ValueError('empty keys are not allowed',)) +! fd(self={u"": 1}):(, ValueError('empty keys are not allowed',)) +! fd(self=FailingMapping()):(, NotImplementedError()) +! fd(self=FailingMappingKey()):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyMapping using fd(self=%s) +! fd(self=[]):(, TypeError('unable to convert object to vim dictionary',)) + <<< Finished + > TabPage + >> TabPageAttr +! vim.current.tabpage.xxx:(, AttributeError('xxx',)) + > TabList + >> TabListItem +! vim.tabpages[1000]:(, IndexError('no such tab page',)) + > Window + >> WindowAttr +! vim.current.window.xxx:(, AttributeError('xxx',)) + >> WindowSetattr +! vim.current.window.buffer = 0:(, TypeError('readonly attribute',)) +! vim.current.window.cursor = (100000000, 100000000):(, error('cursor position outside buffer',)) +! vim.current.window.cursor = True:(, TypeError('argument must be 2-item sequence, not bool',)) +! vim.current.window.height = "abc":(, TypeError('an integer is required',)) +! vim.current.window.width = "abc":(, TypeError('an integer is required',)) +! vim.current.window.xxxxxx = True:(, AttributeError('xxxxxx',)) + > WinList + >> WinListItem +! vim.windows[1000]:(, IndexError('no such window',)) + > Buffer + >> StringToLine (indirect) +! vim.current.buffer[0] = "\na":(, error('string cannot contain newlines',)) + >> SetBufferLine (indirect) +! vim.current.buffer[0] = True:(, TypeError('bad argument type for built-in operation',)) + >> SetBufferLines (indirect) +! vim.current.buffer[:] = True:(, TypeError('bad argument type for built-in operation',)) +! vim.current.buffer[:] = ["\na", "bc"]:(, error('string cannot contain newlines',)) + >> InsertBufferLines (indirect) +! vim.current.buffer.append(None):(, TypeError('bad argument type for built-in operation',)) +! vim.current.buffer.append(["\na", "bc"]):(, error('string cannot contain newlines',)) +! vim.current.buffer.append("\nbc"):(, error('string cannot contain newlines',)) + >> RBItem +! vim.current.buffer[100000000]:(, IndexError('line number out of range',)) + >> RBAsItem +! vim.current.buffer[100000000] = "":(, IndexError('line number out of range',)) + >> BufferAttr +! vim.current.buffer.xxx:(, AttributeError('xxx',)) + >> BufferSetattr +! vim.current.buffer.name = True:(, TypeError('object must be string',)) +! vim.current.buffer.xxx = True:(, AttributeError('xxx',)) + >> BufferMark +! vim.current.buffer.mark(0):(, TypeError('must be string, not int',)) +! vim.current.buffer.mark("abc"):(, ValueError('mark name must be a single character',)) +! vim.current.buffer.mark("!"):(, error('invalid mark name',)) + >> BufferRange +! vim.current.buffer.range(1, 2, 3):(, TypeError('function takes exactly 2 arguments (3 given)',)) + > BufMap + >> BufMapItem +! vim.buffers[None]:(, TypeError('key must be integer',)) +! vim.buffers[100000000]:(, KeyError(100000000,)) + > Current + >> CurrentGetattr +! vim.current.xxx:(, AttributeError('xxx',)) + >> CurrentSetattr +! vim.current.line = True:(, TypeError('bad argument type for built-in operation',)) +! vim.current.buffer = True:(, TypeError('expected vim.Buffer object',)) +! vim.current.window = True:(, TypeError('expected vim.Window object',)) +! vim.current.tabpage = True:(, TypeError('expected vim.TabPage object',)) +! vim.current.xxx = True:(, AttributeError('xxx',)) + 2,xx + before + after +! vim.command("throw 'abc'"):(, error('abc',)) +! Exe("throw 'def'"):(, error('def',)) +! vim.eval("Exe('throw ''ghi''')"):(, error('ghi',)) +! vim.eval("Exe('echoerr ''jkl''')"):(, error('Vim(echoerr):jkl',)) +! vim.eval("Exe('xxx_non_existent_command_xxx')"):(, error('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',)) +! vim.bindeval("Exe('xxx_non_existent_command_xxx')"):(, error('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',)) +--- 437,1094 ---- + test86.in + > Output + >> OutputSetattr +! del sys.stdout.softspace:AttributeError:("can't delete OutputObject attributes",) +! sys.stdout.softspace = []:TypeError:('softspace must be an integer',) +! sys.stdout.attr = None:AttributeError:('invalid attribute',) + >> OutputWrite +! sys.stdout.write(None):TypeError:('coercing to Unicode: need string or buffer, NoneType found',) + >> OutputWriteLines +! sys.stdout.writelines(None):TypeError:("'NoneType' object is not iterable",) +! sys.stdout.writelines([1]):TypeError:('writelines() requires list of strings',) + > VimCommand +! vim.command(1):TypeError:('must be string, not int',) + > VimToPython + > VimEval +! vim.eval(1):TypeError:('must be string, not int',) + > VimEvalPy +! vim.bindeval(1):TypeError:('must be string, not int',) + > VimStrwidth +! vim.strwidth(1):TypeError:('must be string, not int',) + > Dictionary + >> DictionaryConstructor +! vim.Dictionary("abc"):ValueError:('expected sequence element of size 2',) + >> DictionarySetattr +! del d.locked:AttributeError:('cannot delete vim.Dictionary attributes',) +! d.locked = FailingTrue():NotImplementedError:() +! vim.vvars.locked = False:TypeError:('cannot modify fixed dictionary',) +! d.scope = True:AttributeError:('cannot set this attribute',) +! d.xxx = True:AttributeError:('cannot set this attribute',) + >> _DictionaryItem +! d.get("a", 2, 3):TypeError:('function takes at most 2 arguments (3 given)',) + >>> Testing StringToChars using d.get(%s) +! d.get(1):TypeError:('object must be string',) +! d.get(u"\0"):TypeError:('expected string without null bytes',) +! d.get("\0"):TypeError:('expected string without null bytes',) + <<< Finished +! d.pop("a"):KeyError:('a',) +! dl.pop("a"):error:('dict is locked',) + >> DictionaryIterNext +! for i in ned: ned["a"] = 1:RuntimeError:('hashtab changed during iteration',) + >> DictionaryAssItem +! dl["b"] = 1:error:('dict is locked',) + >>> Testing StringToChars using d[%s] = 1 +! d[1] = 1:TypeError:('object must be string',) +! d[u"\0"] = 1:TypeError:('expected string without null bytes',) +! d["\0"] = 1:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d["a"] = {%s : 1} +! d["a"] = {1 : 1}:TypeError:('object must be string',) +! d["a"] = {u"\0" : 1}:TypeError:('expected string without null bytes',) +! d["a"] = {"\0" : 1}:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : {%s : 1}} +! d["a"] = {"abc" : {1 : 1}}:TypeError:('object must be string',) +! d["a"] = {"abc" : {u"\0" : 1}}:TypeError:('expected string without null bytes',) +! d["a"] = {"abc" : {"\0" : 1}}:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : Mapping({%s : 1})} +! d["a"] = {"abc" : Mapping({1 : 1})}:TypeError:('object must be string',) +! d["a"] = {"abc" : Mapping({u"\0" : 1})}:TypeError:('expected string without null bytes',) +! d["a"] = {"abc" : Mapping({"\0" : 1})}:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : FailingIter()}:TypeError:('unable to convert to vim structure',) +! d["a"] = {"abc" : FailingIterNext()}:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : None}:TypeError:('unable to convert to vim structure',) +! d["a"] = {"abc" : {"": 1}}:ValueError:('empty keys are not allowed',) +! d["a"] = {"abc" : {u"": 1}}:ValueError:('empty keys are not allowed',) +! d["a"] = {"abc" : FailingMapping()}:NotImplementedError:() +! d["a"] = {"abc" : FailingMappingKey()}:NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) +! d["a"] = Mapping({1 : 1}):TypeError:('object must be string',) +! d["a"] = Mapping({u"\0" : 1}):TypeError:('expected string without null bytes',) +! d["a"] = Mapping({"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : {%s : 1}}) +! d["a"] = Mapping({"abc" : {1 : 1}}):TypeError:('object must be string',) +! d["a"] = Mapping({"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) +! d["a"] = Mapping({"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : Mapping({%s : 1})}) +! d["a"] = Mapping({"abc" : Mapping({1 : 1})}):TypeError:('object must be string',) +! d["a"] = Mapping({"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) +! d["a"] = Mapping({"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : FailingIter()}):TypeError:('unable to convert to vim structure',) +! d["a"] = Mapping({"abc" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : None}):TypeError:('unable to convert to vim structure',) +! d["a"] = Mapping({"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) +! d["a"] = Mapping({"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! d["a"] = Mapping({"abc" : FailingMapping()}):NotImplementedError:() +! d["a"] = Mapping({"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d["a"] = %s +! d["a"] = FailingIter():TypeError:('unable to convert to vim structure',) +! d["a"] = FailingIterNext():NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = %s +! d["a"] = None:TypeError:('unable to convert to vim structure',) +! d["a"] = {"": 1}:ValueError:('empty keys are not allowed',) +! d["a"] = {u"": 1}:ValueError:('empty keys are not allowed',) +! d["a"] = FailingMapping():NotImplementedError:() +! d["a"] = FailingMappingKey():NotImplementedError:() + <<< Finished + >> DictionaryUpdate + >>> kwargs + >>> iter +! d.update(FailingMapping()):NotImplementedError:() +! d.update([FailingIterNext()]):NotImplementedError:() + >>> Testing StringToChars using d.update({%s : 1}) +! d.update({1 : 1}):TypeError:('object must be string',) +! d.update({u"\0" : 1}):TypeError:('expected string without null bytes',) +! d.update({"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : {%s : 1}}) +! d.update({"abc" : {1 : 1}}):TypeError:('object must be string',) +! d.update({"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) +! d.update({"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : Mapping({%s : 1})}) +! d.update({"abc" : Mapping({1 : 1})}):TypeError:('object must be string',) +! d.update({"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) +! d.update({"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d.update({"abc" : %s}) +! d.update({"abc" : FailingIter()}):TypeError:('unable to convert to vim structure',) +! d.update({"abc" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update({"abc" : %s}) +! d.update({"abc" : None}):TypeError:('unable to convert to vim structure',) +! d.update({"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) +! d.update({"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! d.update({"abc" : FailingMapping()}):NotImplementedError:() +! d.update({"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) +! d.update(Mapping({1 : 1})):TypeError:('object must be string',) +! d.update(Mapping({u"\0" : 1})):TypeError:('expected string without null bytes',) +! d.update(Mapping({"\0" : 1})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : {%s : 1}})) +! d.update(Mapping({"abc" : {1 : 1}})):TypeError:('object must be string',) +! d.update(Mapping({"abc" : {u"\0" : 1}})):TypeError:('expected string without null bytes',) +! d.update(Mapping({"abc" : {"\0" : 1}})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : Mapping({%s : 1})})) +! d.update(Mapping({"abc" : Mapping({1 : 1})})):TypeError:('object must be string',) +! d.update(Mapping({"abc" : Mapping({u"\0" : 1})})):TypeError:('expected string without null bytes',) +! d.update(Mapping({"abc" : Mapping({"\0" : 1})})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : FailingIter()})):TypeError:('unable to convert to vim structure',) +! d.update(Mapping({"abc" : FailingIterNext()})):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : None})):TypeError:('unable to convert to vim structure',) +! d.update(Mapping({"abc" : {"": 1}})):ValueError:('empty keys are not allowed',) +! d.update(Mapping({"abc" : {u"": 1}})):ValueError:('empty keys are not allowed',) +! d.update(Mapping({"abc" : FailingMapping()})):NotImplementedError:() +! d.update(Mapping({"abc" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d.update(%s) +! d.update(FailingIter()):NotImplementedError:() +! d.update(FailingIterNext()):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update(%s) +! d.update(None):TypeError:("'NoneType' object is not iterable",) +! d.update({"": 1}):ValueError:('empty keys are not allowed',) +! d.update({u"": 1}):ValueError:('empty keys are not allowed',) +! d.update(FailingMapping()):NotImplementedError:() +! d.update(FailingMappingKey()):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update(((%s, 0),)) +! d.update(((1, 0),)):TypeError:('object must be string',) +! d.update(((u"\0", 0),)):TypeError:('expected string without null bytes',) +! d.update((("\0", 0),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update((("a", {%s : 1}),)) +! d.update((("a", {1 : 1}),)):TypeError:('object must be string',) +! d.update((("a", {u"\0" : 1}),)):TypeError:('expected string without null bytes',) +! d.update((("a", {"\0" : 1}),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : {%s : 1}}),)) +! d.update((("a", {"abc" : {1 : 1}}),)):TypeError:('object must be string',) +! d.update((("a", {"abc" : {u"\0" : 1}}),)):TypeError:('expected string without null bytes',) +! d.update((("a", {"abc" : {"\0" : 1}}),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : Mapping({%s : 1})}),)) +! d.update((("a", {"abc" : Mapping({1 : 1})}),)):TypeError:('object must be string',) +! d.update((("a", {"abc" : Mapping({u"\0" : 1})}),)):TypeError:('expected string without null bytes',) +! d.update((("a", {"abc" : Mapping({"\0" : 1})}),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : FailingIter()}),)):TypeError:('unable to convert to vim structure',) +! d.update((("a", {"abc" : FailingIterNext()}),)):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : None}),)):TypeError:('unable to convert to vim structure',) +! d.update((("a", {"abc" : {"": 1}}),)):ValueError:('empty keys are not allowed',) +! d.update((("a", {"abc" : {u"": 1}}),)):ValueError:('empty keys are not allowed',) +! d.update((("a", {"abc" : FailingMapping()}),)):NotImplementedError:() +! d.update((("a", {"abc" : FailingMappingKey()}),)):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) +! d.update((("a", Mapping({1 : 1})),)):TypeError:('object must be string',) +! d.update((("a", Mapping({u"\0" : 1})),)):TypeError:('expected string without null bytes',) +! d.update((("a", Mapping({"\0" : 1})),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : {%s : 1}})),)) +! d.update((("a", Mapping({"abc" : {1 : 1}})),)):TypeError:('object must be string',) +! d.update((("a", Mapping({"abc" : {u"\0" : 1}})),)):TypeError:('expected string without null bytes',) +! d.update((("a", Mapping({"abc" : {"\0" : 1}})),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : Mapping({%s : 1})})),)) +! d.update((("a", Mapping({"abc" : Mapping({1 : 1})})),)):TypeError:('object must be string',) +! d.update((("a", Mapping({"abc" : Mapping({u"\0" : 1})})),)):TypeError:('expected string without null bytes',) +! d.update((("a", Mapping({"abc" : Mapping({"\0" : 1})})),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : FailingIter()})),)):TypeError:('unable to convert to vim structure',) +! d.update((("a", Mapping({"abc" : FailingIterNext()})),)):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : None})),)):TypeError:('unable to convert to vim structure',) +! d.update((("a", Mapping({"abc" : {"": 1}})),)):ValueError:('empty keys are not allowed',) +! d.update((("a", Mapping({"abc" : {u"": 1}})),)):ValueError:('empty keys are not allowed',) +! d.update((("a", Mapping({"abc" : FailingMapping()})),)):NotImplementedError:() +! d.update((("a", Mapping({"abc" : FailingMappingKey()})),)):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d.update((("a", %s),)) +! d.update((("a", FailingIter()),)):TypeError:('unable to convert to vim structure',) +! d.update((("a", FailingIterNext()),)):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", %s),)) +! d.update((("a", None),)):TypeError:('unable to convert to vim structure',) +! d.update((("a", {"": 1}),)):ValueError:('empty keys are not allowed',) +! d.update((("a", {u"": 1}),)):ValueError:('empty keys are not allowed',) +! d.update((("a", FailingMapping()),)):NotImplementedError:() +! d.update((("a", FailingMappingKey()),)):NotImplementedError:() + <<< Finished + >> DictionaryPopItem +! d.popitem(1, 2):TypeError:('popitem() takes no arguments (2 given)',) + >> DictionaryHasKey +! d.has_key():TypeError:('function takes exactly 1 argument (0 given)',) + > List + >> ListConstructor +! vim.List(1, 2):TypeError:('function takes at most 1 argument (2 given)',) +! vim.List(a=1):TypeError:('list constructor does not accept keyword arguments',) + >>> Testing StringToChars using vim.List([{%s : 1}]) +! vim.List([{1 : 1}]):TypeError:('object must be string',) +! vim.List([{u"\0" : 1}]):TypeError:('expected string without null bytes',) +! vim.List([{"\0" : 1}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : {%s : 1}}]) +! vim.List([{"abc" : {1 : 1}}]):TypeError:('object must be string',) +! vim.List([{"abc" : {u"\0" : 1}}]):TypeError:('expected string without null bytes',) +! vim.List([{"abc" : {"\0" : 1}}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : Mapping({%s : 1})}]) +! vim.List([{"abc" : Mapping({1 : 1})}]):TypeError:('object must be string',) +! vim.List([{"abc" : Mapping({u"\0" : 1})}]):TypeError:('expected string without null bytes',) +! vim.List([{"abc" : Mapping({"\0" : 1})}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : FailingIter()}]):TypeError:('unable to convert to vim structure',) +! vim.List([{"abc" : FailingIterNext()}]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : None}]):TypeError:('unable to convert to vim structure',) +! vim.List([{"abc" : {"": 1}}]):ValueError:('empty keys are not allowed',) +! vim.List([{"abc" : {u"": 1}}]):ValueError:('empty keys are not allowed',) +! vim.List([{"abc" : FailingMapping()}]):NotImplementedError:() +! vim.List([{"abc" : FailingMappingKey()}]):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) +! vim.List([Mapping({1 : 1})]):TypeError:('object must be string',) +! vim.List([Mapping({u"\0" : 1})]):TypeError:('expected string without null bytes',) +! vim.List([Mapping({"\0" : 1})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : {%s : 1}})]) +! vim.List([Mapping({"abc" : {1 : 1}})]):TypeError:('object must be string',) +! vim.List([Mapping({"abc" : {u"\0" : 1}})]):TypeError:('expected string without null bytes',) +! vim.List([Mapping({"abc" : {"\0" : 1}})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : Mapping({%s : 1})})]) +! vim.List([Mapping({"abc" : Mapping({1 : 1})})]):TypeError:('object must be string',) +! vim.List([Mapping({"abc" : Mapping({u"\0" : 1})})]):TypeError:('expected string without null bytes',) +! vim.List([Mapping({"abc" : Mapping({"\0" : 1})})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : FailingIter()})]):TypeError:('unable to convert to vim structure',) +! vim.List([Mapping({"abc" : FailingIterNext()})]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : None})]):TypeError:('unable to convert to vim structure',) +! vim.List([Mapping({"abc" : {"": 1}})]):ValueError:('empty keys are not allowed',) +! vim.List([Mapping({"abc" : {u"": 1}})]):ValueError:('empty keys are not allowed',) +! vim.List([Mapping({"abc" : FailingMapping()})]):NotImplementedError:() +! vim.List([Mapping({"abc" : FailingMappingKey()})]):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using vim.List([%s]) +! vim.List([FailingIter()]):TypeError:('unable to convert to vim structure',) +! vim.List([FailingIterNext()]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([%s]) +! vim.List([None]):TypeError:('unable to convert to vim structure',) +! vim.List([{"": 1}]):ValueError:('empty keys are not allowed',) +! vim.List([{u"": 1}]):ValueError:('empty keys are not allowed',) +! vim.List([FailingMapping()]):NotImplementedError:() +! vim.List([FailingMappingKey()]):NotImplementedError:() + <<< Finished + >> ListItem +! l[1000]:IndexError:('list index out of range',) + >> ListAssItem +! ll[1] = 2:error:('list is locked',) +! l[1000] = 3:IndexError:('list index out of range',) + >> ListAssSlice +! ll[1:100] = "abc":error:('list is locked',) + >>> Testing StringToChars using l[:] = [{%s : 1}] +! l[:] = [{1 : 1}]:TypeError:('object must be string',) +! l[:] = [{u"\0" : 1}]:TypeError:('expected string without null bytes',) +! l[:] = [{"\0" : 1}]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : {%s : 1}}] +! l[:] = [{"abc" : {1 : 1}}]:TypeError:('object must be string',) +! l[:] = [{"abc" : {u"\0" : 1}}]:TypeError:('expected string without null bytes',) +! l[:] = [{"abc" : {"\0" : 1}}]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : Mapping({%s : 1})}] +! l[:] = [{"abc" : Mapping({1 : 1})}]:TypeError:('object must be string',) +! l[:] = [{"abc" : Mapping({u"\0" : 1})}]:TypeError:('expected string without null bytes',) +! l[:] = [{"abc" : Mapping({"\0" : 1})}]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : FailingIter()}]:TypeError:('unable to convert to vim structure',) +! l[:] = [{"abc" : FailingIterNext()}]:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : None}]:TypeError:('unable to convert to vim structure',) +! l[:] = [{"abc" : {"": 1}}]:ValueError:('empty keys are not allowed',) +! l[:] = [{"abc" : {u"": 1}}]:ValueError:('empty keys are not allowed',) +! l[:] = [{"abc" : FailingMapping()}]:NotImplementedError:() +! l[:] = [{"abc" : FailingMappingKey()}]:NotImplementedError:() + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] +! l[:] = [Mapping({1 : 1})]:TypeError:('object must be string',) +! l[:] = [Mapping({u"\0" : 1})]:TypeError:('expected string without null bytes',) +! l[:] = [Mapping({"\0" : 1})]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : {%s : 1}})] +! l[:] = [Mapping({"abc" : {1 : 1}})]:TypeError:('object must be string',) +! l[:] = [Mapping({"abc" : {u"\0" : 1}})]:TypeError:('expected string without null bytes',) +! l[:] = [Mapping({"abc" : {"\0" : 1}})]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : Mapping({%s : 1})})] +! l[:] = [Mapping({"abc" : Mapping({1 : 1})})]:TypeError:('object must be string',) +! l[:] = [Mapping({"abc" : Mapping({u"\0" : 1})})]:TypeError:('expected string without null bytes',) +! l[:] = [Mapping({"abc" : Mapping({"\0" : 1})})]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : FailingIter()})]:TypeError:('unable to convert to vim structure',) +! l[:] = [Mapping({"abc" : FailingIterNext()})]:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : None})]:TypeError:('unable to convert to vim structure',) +! l[:] = [Mapping({"abc" : {"": 1}})]:ValueError:('empty keys are not allowed',) +! l[:] = [Mapping({"abc" : {u"": 1}})]:ValueError:('empty keys are not allowed',) +! l[:] = [Mapping({"abc" : FailingMapping()})]:NotImplementedError:() +! l[:] = [Mapping({"abc" : FailingMappingKey()})]:NotImplementedError:() + <<< Finished + >>> Testing *Iter* using l[:] = [%s] +! l[:] = [FailingIter()]:TypeError:('unable to convert to vim structure',) +! l[:] = [FailingIterNext()]:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [%s] +! l[:] = [None]:TypeError:('unable to convert to vim structure',) +! l[:] = [{"": 1}]:ValueError:('empty keys are not allowed',) +! l[:] = [{u"": 1}]:ValueError:('empty keys are not allowed',) +! l[:] = [FailingMapping()]:NotImplementedError:() +! l[:] = [FailingMappingKey()]:NotImplementedError:() + <<< Finished + >> ListConcatInPlace + >>> Testing StringToChars using l.extend([{%s : 1}]) +! l.extend([{1 : 1}]):TypeError:('object must be string',) +! l.extend([{u"\0" : 1}]):TypeError:('expected string without null bytes',) +! l.extend([{"\0" : 1}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : {%s : 1}}]) +! l.extend([{"abc" : {1 : 1}}]):TypeError:('object must be string',) +! l.extend([{"abc" : {u"\0" : 1}}]):TypeError:('expected string without null bytes',) +! l.extend([{"abc" : {"\0" : 1}}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : Mapping({%s : 1})}]) +! l.extend([{"abc" : Mapping({1 : 1})}]):TypeError:('object must be string',) +! l.extend([{"abc" : Mapping({u"\0" : 1})}]):TypeError:('expected string without null bytes',) +! l.extend([{"abc" : Mapping({"\0" : 1})}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : FailingIter()}]):TypeError:('unable to convert to vim structure',) +! l.extend([{"abc" : FailingIterNext()}]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : None}]):TypeError:('unable to convert to vim structure',) +! l.extend([{"abc" : {"": 1}}]):ValueError:('empty keys are not allowed',) +! l.extend([{"abc" : {u"": 1}}]):ValueError:('empty keys are not allowed',) +! l.extend([{"abc" : FailingMapping()}]):NotImplementedError:() +! l.extend([{"abc" : FailingMappingKey()}]):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) +! l.extend([Mapping({1 : 1})]):TypeError:('object must be string',) +! l.extend([Mapping({u"\0" : 1})]):TypeError:('expected string without null bytes',) +! l.extend([Mapping({"\0" : 1})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : {%s : 1}})]) +! l.extend([Mapping({"abc" : {1 : 1}})]):TypeError:('object must be string',) +! l.extend([Mapping({"abc" : {u"\0" : 1}})]):TypeError:('expected string without null bytes',) +! l.extend([Mapping({"abc" : {"\0" : 1}})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : Mapping({%s : 1})})]) +! l.extend([Mapping({"abc" : Mapping({1 : 1})})]):TypeError:('object must be string',) +! l.extend([Mapping({"abc" : Mapping({u"\0" : 1})})]):TypeError:('expected string without null bytes',) +! l.extend([Mapping({"abc" : Mapping({"\0" : 1})})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : FailingIter()})]):TypeError:('unable to convert to vim structure',) +! l.extend([Mapping({"abc" : FailingIterNext()})]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : None})]):TypeError:('unable to convert to vim structure',) +! l.extend([Mapping({"abc" : {"": 1}})]):ValueError:('empty keys are not allowed',) +! l.extend([Mapping({"abc" : {u"": 1}})]):ValueError:('empty keys are not allowed',) +! l.extend([Mapping({"abc" : FailingMapping()})]):NotImplementedError:() +! l.extend([Mapping({"abc" : FailingMappingKey()})]):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using l.extend([%s]) +! l.extend([FailingIter()]):TypeError:('unable to convert to vim structure',) +! l.extend([FailingIterNext()]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([%s]) +! l.extend([None]):TypeError:('unable to convert to vim structure',) +! l.extend([{"": 1}]):ValueError:('empty keys are not allowed',) +! l.extend([{u"": 1}]):ValueError:('empty keys are not allowed',) +! l.extend([FailingMapping()]):NotImplementedError:() +! l.extend([FailingMappingKey()]):NotImplementedError:() + <<< Finished + >> ListSetattr +! del l.locked:AttributeError:('cannot delete vim.List attributes',) +! l.locked = FailingTrue():NotImplementedError:() +! l.xxx = True:AttributeError:('cannot set this attribute',) + > Function + >> FunctionConstructor +! vim.Function("123"):ValueError:('unnamed function does not exist',) +! vim.Function("xxx_non_existent_function_xxx"):ValueError:('function does not exist',) + vim.Function("xxx#non#existent#function#xxx"):NOT FAILED + >> FunctionCall + >>> Testing StringToChars using f({%s : 1}) +! f({1 : 1}):TypeError:('object must be string',) +! f({u"\0" : 1}):TypeError:('expected string without null bytes',) +! f({"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using f({"abc" : {%s : 1}}) +! f({"abc" : {1 : 1}}):TypeError:('object must be string',) +! f({"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) +! f({"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using f({"abc" : Mapping({%s : 1})}) +! f({"abc" : Mapping({1 : 1})}):TypeError:('object must be string',) +! f({"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) +! f({"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using f({"abc" : %s}) +! f({"abc" : FailingIter()}):TypeError:('unable to convert to vim structure',) +! f({"abc" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using f({"abc" : %s}) +! f({"abc" : None}):TypeError:('unable to convert to vim structure',) +! f({"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) +! f({"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! f({"abc" : FailingMapping()}):NotImplementedError:() +! f({"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) +! f(Mapping({1 : 1})):TypeError:('object must be string',) +! f(Mapping({u"\0" : 1})):TypeError:('expected string without null bytes',) +! f(Mapping({"\0" : 1})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : {%s : 1}})) +! f(Mapping({"abc" : {1 : 1}})):TypeError:('object must be string',) +! f(Mapping({"abc" : {u"\0" : 1}})):TypeError:('expected string without null bytes',) +! f(Mapping({"abc" : {"\0" : 1}})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : Mapping({%s : 1})})) +! f(Mapping({"abc" : Mapping({1 : 1})})):TypeError:('object must be string',) +! f(Mapping({"abc" : Mapping({u"\0" : 1})})):TypeError:('expected string without null bytes',) +! f(Mapping({"abc" : Mapping({"\0" : 1})})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : FailingIter()})):TypeError:('unable to convert to vim structure',) +! f(Mapping({"abc" : FailingIterNext()})):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : None})):TypeError:('unable to convert to vim structure',) +! f(Mapping({"abc" : {"": 1}})):ValueError:('empty keys are not allowed',) +! f(Mapping({"abc" : {u"": 1}})):ValueError:('empty keys are not allowed',) +! f(Mapping({"abc" : FailingMapping()})):NotImplementedError:() +! f(Mapping({"abc" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using f(%s) +! f(FailingIter()):TypeError:('unable to convert to vim structure',) +! f(FailingIterNext()):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using f(%s) +! f(None):TypeError:('unable to convert to vim structure',) +! f({"": 1}):ValueError:('empty keys are not allowed',) +! f({u"": 1}):ValueError:('empty keys are not allowed',) +! f(FailingMapping()):NotImplementedError:() +! f(FailingMappingKey()):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using fd(self={%s : 1}) +! fd(self={1 : 1}):TypeError:('object must be string',) +! fd(self={u"\0" : 1}):TypeError:('expected string without null bytes',) +! fd(self={"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : {%s : 1}}) +! fd(self={"abc" : {1 : 1}}):TypeError:('object must be string',) +! fd(self={"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) +! fd(self={"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : Mapping({%s : 1})}) +! fd(self={"abc" : Mapping({1 : 1})}):TypeError:('object must be string',) +! fd(self={"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) +! fd(self={"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using fd(self={"abc" : %s}) +! fd(self={"abc" : FailingIter()}):TypeError:('unable to convert to vim structure',) +! fd(self={"abc" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using fd(self={"abc" : %s}) +! fd(self={"abc" : None}):TypeError:('unable to convert to vim structure',) +! fd(self={"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) +! fd(self={"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! fd(self={"abc" : FailingMapping()}):NotImplementedError:() +! fd(self={"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) +! fd(self=Mapping({1 : 1})):TypeError:('object must be string',) +! fd(self=Mapping({u"\0" : 1})):TypeError:('expected string without null bytes',) +! fd(self=Mapping({"\0" : 1})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : {%s : 1}})) +! fd(self=Mapping({"abc" : {1 : 1}})):TypeError:('object must be string',) +! fd(self=Mapping({"abc" : {u"\0" : 1}})):TypeError:('expected string without null bytes',) +! fd(self=Mapping({"abc" : {"\0" : 1}})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : Mapping({%s : 1})})) +! fd(self=Mapping({"abc" : Mapping({1 : 1})})):TypeError:('object must be string',) +! fd(self=Mapping({"abc" : Mapping({u"\0" : 1})})):TypeError:('expected string without null bytes',) +! fd(self=Mapping({"abc" : Mapping({"\0" : 1})})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : FailingIter()})):TypeError:('unable to convert to vim structure',) +! fd(self=Mapping({"abc" : FailingIterNext()})):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : None})):TypeError:('unable to convert to vim structure',) +! fd(self=Mapping({"abc" : {"": 1}})):ValueError:('empty keys are not allowed',) +! fd(self=Mapping({"abc" : {u"": 1}})):ValueError:('empty keys are not allowed',) +! fd(self=Mapping({"abc" : FailingMapping()})):NotImplementedError:() +! fd(self=Mapping({"abc" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using fd(self=%s) +! fd(self=FailingIter()):TypeError:('unable to convert object to vim dictionary',) +! fd(self=FailingIterNext()):TypeError:('unable to convert object to vim dictionary',) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=%s) +! fd(self=None):TypeError:('unable to convert object to vim dictionary',) +! fd(self={"": 1}):ValueError:('empty keys are not allowed',) +! fd(self={u"": 1}):ValueError:('empty keys are not allowed',) +! fd(self=FailingMapping()):NotImplementedError:() +! fd(self=FailingMappingKey()):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyMapping using fd(self=%s) +! fd(self=[]):TypeError:('unable to convert object to vim dictionary',) + <<< Finished + > TabPage + >> TabPageAttr +! vim.current.tabpage.xxx:AttributeError:('xxx',) + > TabList + >> TabListItem +! vim.tabpages[1000]:IndexError:('no such tab page',) + > Window + >> WindowAttr +! vim.current.window.xxx:AttributeError:('xxx',) + >> WindowSetattr +! vim.current.window.buffer = 0:TypeError:('readonly attribute',) +! vim.current.window.cursor = (100000000, 100000000):error:('cursor position outside buffer',) +! vim.current.window.cursor = True:TypeError:('argument must be 2-item sequence, not bool',) +! vim.current.window.height = "abc":TypeError:('an integer is required',) +! vim.current.window.width = "abc":TypeError:('an integer is required',) +! vim.current.window.xxxxxx = True:AttributeError:('xxxxxx',) + > WinList + >> WinListItem +! vim.windows[1000]:IndexError:('no such window',) + > Buffer + >> StringToLine (indirect) +! vim.current.buffer[0] = "\na":error:('string cannot contain newlines',) + >> SetBufferLine (indirect) +! vim.current.buffer[0] = True:TypeError:('bad argument type for built-in operation',) + >> SetBufferLines (indirect) +! vim.current.buffer[:] = True:TypeError:('bad argument type for built-in operation',) +! vim.current.buffer[:] = ["\na", "bc"]:error:('string cannot contain newlines',) + >> InsertBufferLines (indirect) +! vim.current.buffer.append(None):TypeError:('bad argument type for built-in operation',) +! vim.current.buffer.append(["\na", "bc"]):error:('string cannot contain newlines',) +! vim.current.buffer.append("\nbc"):error:('string cannot contain newlines',) + >> RBItem +! vim.current.buffer[100000000]:IndexError:('line number out of range',) + >> RBAsItem +! vim.current.buffer[100000000] = "":IndexError:('line number out of range',) + >> BufferAttr +! vim.current.buffer.xxx:AttributeError:('xxx',) + >> BufferSetattr +! vim.current.buffer.name = True:TypeError:('object must be string',) +! vim.current.buffer.xxx = True:AttributeError:('xxx',) + >> BufferMark +! vim.current.buffer.mark(0):TypeError:('must be string, not int',) +! vim.current.buffer.mark("abc"):ValueError:('mark name must be a single character',) +! vim.current.buffer.mark("!"):error:('invalid mark name',) + >> BufferRange +! vim.current.buffer.range(1, 2, 3):TypeError:('function takes exactly 2 arguments (3 given)',) + > BufMap + >> BufMapItem +! vim.buffers[None]:TypeError:('key must be integer',) +! vim.buffers[100000000]:KeyError:(100000000,) + > Current + >> CurrentGetattr +! vim.current.xxx:AttributeError:('xxx',) + >> CurrentSetattr +! vim.current.line = True:TypeError:('bad argument type for built-in operation',) +! vim.current.buffer = True:TypeError:('expected vim.Buffer object',) +! vim.current.window = True:TypeError:('expected vim.Window object',) +! vim.current.tabpage = True:TypeError:('expected vim.TabPage object',) +! vim.current.xxx = True:AttributeError:('xxx',) + 2,xx + before + after +! vim.command("throw 'abc'"):error:('abc',) +! Exe("throw 'def'"):error:('def',) +! vim.eval("Exe('throw ''ghi''')"):error:('ghi',) +! vim.eval("Exe('echoerr ''jkl''')"):error:('Vim(echoerr):jkl',) +! vim.eval("Exe('xxx_non_existent_command_xxx')"):error:('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',) +! vim.bindeval("Exe('xxx_non_existent_command_xxx')"):error:('Vim:E492: Not an editor command: xxx_non_existent_command_xxx',) +*** ../vim-7.3.1172/src/version.c 2013-06-12 14:20:15.000000000 +0200 +--- src/version.c 2013-06-12 14:22:25.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1173, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +168. You have your own domain name. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From eabdb9d2590d5ebc7be36b891cdb8d5788b0f599 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:00 +0200 Subject: [PATCH 1066/3340] - patchlevel 1174 --- 7.3.1174 | 835 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 835 insertions(+) create mode 100644 7.3.1174 diff --git a/7.3.1174 b/7.3.1174 new file mode 100644 index 00000000..c7a01569 --- /dev/null +++ b/7.3.1174 @@ -0,0 +1,835 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1174 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1174 +Problem: Python 2 and 3 use different ways to load modules. +Solution: Use the same method. (ZyX) +Files: runtime/doc/if_pyth.txt, src/if_py_both.h, src/if_python3.c, + src/if_python.c + + +*** ../vim-7.3.1173/runtime/doc/if_pyth.txt 2013-06-12 14:20:15.000000000 +0200 +--- runtime/doc/if_pyth.txt 2013-06-12 14:33:12.000000000 +0200 +*************** +*** 315,321 **** + {rtp}/python2 (or python3) and {rtp}/pythonx (for both python versions) for + each {rtp} found in 'runtimepath'. + +! Implementation for python 2 is similar to the following, but written in C: > + + from imp import find_module, load_module + import vim +--- 315,321 ---- + {rtp}/python2 (or python3) and {rtp}/pythonx (for both python versions) for + each {rtp} found in 'runtimepath'. + +! Implementation is similar to the following, but written in C: > + + from imp import find_module, load_module + import vim +*************** +*** 344,359 **** + # matter for python which object has find_module function attached to as + # an attribute. + class VimPathFinder(object): + def find_module(cls, fullname, path=None): + try: + return VimModuleLoader(_find_module(fullname, fullname, path or vim._get_paths())) + except ImportError: + return None +- find_module = classmethod(find_module) + + def load_module(cls, fullname, path=None): + return _find_module(fullname, fullname, path or vim._get_paths()) +- load_module = classmethod(load_module) + + def hook(path): + if path == vim.VIM_SPECIAL_PATH: +--- 344,359 ---- + # matter for python which object has find_module function attached to as + # an attribute. + class VimPathFinder(object): ++ @classmethod + def find_module(cls, fullname, path=None): + try: + return VimModuleLoader(_find_module(fullname, fullname, path or vim._get_paths())) + except ImportError: + return None + ++ @classmethod + def load_module(cls, fullname, path=None): + return _find_module(fullname, fullname, path or vim._get_paths()) + + def hook(path): + if path == vim.VIM_SPECIAL_PATH: +*************** +*** 363,392 **** + + sys.path_hooks.append(hook) + +- Implementation for python 3 is cleaner: code is similar to the following, but, +- again, written in C: > +- +- from importlib.machinery import PathFinder +- import sys +- +- class Finder(PathFinder): +- @classmethod +- def find_module(cls, fullname): +- # see vim._get_paths below +- new_path = _get_paths() +- +- # super().find_module is also a class method +- # super() is not used because this variant is easier to implement +- # in C +- return PathFinder.find_module(fullname, new_path) +- +- def path_hook(path): +- if path == VIM_SPECIAL_PATH: +- return Finder +- raise ImportError +- +- sys.path_hooks.append(path_hook) +- + vim.VIM_SPECIAL_PATH *python-VIM_SPECIAL_PATH* + String constant used in conjunction with vim path hook. If path hook + installed by vim is requested to handle anything but path equal to +--- 363,368 ---- +*************** +*** 402,409 **** + You should not be using any of these directly except for vim.path_hook + in case you need to do something with sys.meta_path. It is not + guaranteed that any of the objects will exist in the future vim +! versions. In fact, find_module methods do not exists +! in python3. + + vim._get_paths *python-_get_paths* + Methods returning a list of paths which will be searched for by path +--- 378,384 ---- + You should not be using any of these directly except for vim.path_hook + in case you need to do something with sys.meta_path. It is not + guaranteed that any of the objects will exist in the future vim +! versions. + + vim._get_paths *python-_get_paths* + Methods returning a list of paths which will be searched for by path +*** ../vim-7.3.1173/src/if_py_both.h 2013-06-12 14:20:15.000000000 +0200 +--- src/if_py_both.h 2013-06-12 14:35:42.000000000 +0200 +*************** +*** 60,65 **** +--- 60,70 ---- + static PyObject *vim_module; + static PyObject *vim_special_path_object; + ++ static PyObject *py_find_module; ++ static PyObject *py_load_module; ++ ++ static PyObject *VimError; ++ + /* + * obtain a lock on the Vim data structures + */ +*************** +*** 393,400 **** + return 0; + } + + +! static PyObject *VimError; + + /* Check to see whether a Vim error has been reported, or a keyboard + * interrupt has been detected. +--- 398,431 ---- + return 0; + } + ++ typedef struct ++ { ++ PyObject_HEAD ++ PyObject *module; ++ } LoaderObject; ++ static PyTypeObject LoaderType; ++ ++ static void ++ LoaderDestructor(LoaderObject *self) ++ { ++ Py_DECREF(self->module); ++ DESTRUCTOR_FINISH(self); ++ } ++ ++ static PyObject * ++ LoaderLoadModule(LoaderObject *self, PyObject *args UNUSED) ++ { ++ PyObject *r = self->module; + +! Py_INCREF(r); +! return r; +! } +! +! static struct PyMethodDef LoaderMethods[] = { +! /* name, function, calling, doc */ +! {"load_module", (PyCFunction)LoaderLoadModule, METH_VARARGS, ""}, +! { NULL, NULL, 0, NULL} +! }; + + /* Check to see whether a Vim error has been reported, or a keyboard + * interrupt has been detected. +*************** +*** 925,930 **** +--- 956,1105 ---- + return r; + } + ++ static PyObject * ++ call_load_module(char *name, int len, PyObject *find_module_result) ++ { ++ PyObject *fd, *pathname, *description; ++ ++ if (!PyTuple_Check(find_module_result) ++ || PyTuple_GET_SIZE(find_module_result) != 3) ++ { ++ PyErr_SetString(PyExc_TypeError, ++ _("expected 3-tuple as imp.find_module() result")); ++ return NULL; ++ } ++ ++ if (!(fd = PyTuple_GET_ITEM(find_module_result, 0)) ++ || !(pathname = PyTuple_GET_ITEM(find_module_result, 1)) ++ || !(description = PyTuple_GET_ITEM(find_module_result, 2))) ++ { ++ PyErr_SetString(PyExc_RuntimeError, ++ _("internal error: imp.find_module returned tuple with NULL")); ++ return NULL; ++ } ++ ++ return PyObject_CallFunction(py_load_module, ++ "s#OOO", name, len, fd, pathname, description); ++ } ++ ++ static PyObject * ++ find_module(char *fullname, char *tail, PyObject *new_path) ++ { ++ PyObject *find_module_result; ++ PyObject *module; ++ char *dot; ++ ++ if ((dot = (char *) vim_strchr((char_u *) tail, '.'))) ++ { ++ /* ++ * There is a dot in the name: call find_module recursively without the ++ * first component ++ */ ++ PyObject *newest_path; ++ int partlen = (int) (dot - 1 - tail); ++ ++ if (!(find_module_result = PyObject_CallFunction(py_find_module, ++ "s#O", tail, partlen, new_path))) ++ return NULL; ++ ++ if (!(module = call_load_module( ++ fullname, ++ ((int) (tail - fullname)) + partlen, ++ find_module_result))) ++ { ++ Py_DECREF(find_module_result); ++ return NULL; ++ } ++ ++ Py_DECREF(find_module_result); ++ ++ if (!(newest_path = PyObject_GetAttrString(module, "__path__"))) ++ { ++ Py_DECREF(module); ++ return NULL; ++ } ++ ++ Py_DECREF(module); ++ ++ module = find_module(fullname, dot + 1, newest_path); ++ ++ Py_DECREF(newest_path); ++ ++ return module; ++ } ++ else ++ { ++ if (!(find_module_result = PyObject_CallFunction(py_find_module, ++ "sO", tail, new_path))) ++ return NULL; ++ ++ if (!(module = call_load_module( ++ fullname, ++ STRLEN(fullname), ++ find_module_result))) ++ { ++ Py_DECREF(find_module_result); ++ return NULL; ++ } ++ ++ Py_DECREF(find_module_result); ++ ++ return module; ++ } ++ } ++ ++ static PyObject * ++ FinderFindModule(PyObject *self, PyObject *args) ++ { ++ char *fullname; ++ PyObject *module; ++ PyObject *new_path; ++ LoaderObject *loader; ++ ++ if (!PyArg_ParseTuple(args, "s", &fullname)) ++ return NULL; ++ ++ if (!(new_path = Vim_GetPaths(self))) ++ return NULL; ++ ++ module = find_module(fullname, fullname, new_path); ++ ++ Py_DECREF(new_path); ++ ++ if (!module) ++ { ++ Py_INCREF(Py_None); ++ return Py_None; ++ } ++ ++ if (!(loader = PyObject_NEW(LoaderObject, &LoaderType))) ++ { ++ Py_DECREF(module); ++ return NULL; ++ } ++ ++ loader->module = module; ++ ++ return (PyObject *) loader; ++ } ++ ++ static PyObject * ++ VimPathHook(PyObject *self UNUSED, PyObject *args) ++ { ++ char *path; ++ ++ if (PyArg_ParseTuple(args, "s", &path) ++ && STRCMP(path, vim_special_path) == 0) ++ { ++ Py_INCREF(vim_module); ++ return vim_module; ++ } ++ ++ PyErr_Clear(); ++ PyErr_SetNone(PyExc_ImportError); ++ return NULL; ++ } ++ + /* + * Vim module - Definitions + */ +*************** +*** 938,946 **** + {"chdir", (PyCFunction)VimChdir, METH_VARARGS|METH_KEYWORDS, "Change directory"}, + {"fchdir", (PyCFunction)VimFchdir, METH_VARARGS|METH_KEYWORDS, "Change directory"}, + {"foreach_rtp", VimForeachRTP, METH_VARARGS, "Call given callable for each path in &rtp"}, +- #if PY_MAJOR_VERSION < 3 + {"find_module", FinderFindModule, METH_VARARGS, "Internal use only, returns loader object for any input it receives"}, +- #endif + {"path_hook", VimPathHook, METH_VARARGS, "Hook function to install in sys.path_hooks"}, + {"_get_paths", (PyCFunction)Vim_GetPaths, METH_NOARGS, "Get &rtp-based additions to sys.path"}, + { NULL, NULL, 0, NULL} +--- 1113,1119 ---- +*************** +*** 5188,5208 **** + } CurrentObject; + static PyTypeObject CurrentType; + +- #if PY_MAJOR_VERSION >= 3 +- typedef struct +- { +- PyObject_HEAD +- } FinderObject; +- static PyTypeObject FinderType; +- #else +- typedef struct +- { +- PyObject_HEAD +- PyObject *module; +- } LoaderObject; +- static PyTypeObject LoaderType; +- #endif +- + static void + init_structs(void) + { +--- 5361,5366 ---- +*************** +*** 5418,5423 **** +--- 5576,5589 ---- + OptionsType.tp_traverse = (traverseproc)OptionsTraverse; + OptionsType.tp_clear = (inquiry)OptionsClear; + ++ vim_memset(&LoaderType, 0, sizeof(LoaderType)); ++ LoaderType.tp_name = "vim.Loader"; ++ LoaderType.tp_basicsize = sizeof(LoaderObject); ++ LoaderType.tp_flags = Py_TPFLAGS_DEFAULT; ++ LoaderType.tp_doc = "vim message object"; ++ LoaderType.tp_methods = LoaderMethods; ++ LoaderType.tp_dealloc = (destructor)LoaderDestructor; ++ + #if PY_MAJOR_VERSION >= 3 + vim_memset(&vimmodule, 0, sizeof(vimmodule)); + vimmodule.m_name = "vim"; +*************** +*** 5448,5458 **** + PYTYPE_READY(FunctionType); + PYTYPE_READY(OptionsType); + PYTYPE_READY(OutputType); +- #if PY_MAJOR_VERSION >= 3 +- PYTYPE_READY(FinderType); +- #else + PYTYPE_READY(LoaderType); +- #endif + return 0; + } + +--- 5614,5620 ---- +*************** +*** 5576,5586 **** + {"List", (PyObject *)&ListType}, + {"Function", (PyObject *)&FunctionType}, + {"Options", (PyObject *)&OptionsType}, +! #if PY_MAJOR_VERSION >= 3 +! {"Finder", (PyObject *)&FinderType}, +! #else +! {"Loader", (PyObject *)&LoaderType}, +! #endif + }; + + typedef int (*object_adder)(PyObject *, const char *, PyObject *); +--- 5738,5744 ---- + {"List", (PyObject *)&ListType}, + {"Function", (PyObject *)&FunctionType}, + {"Options", (PyObject *)&OptionsType}, +! {"_Loader", (PyObject *)&LoaderType}, + }; + + typedef int (*object_adder)(PyObject *, const char *, PyObject *); +*************** +*** 5604,5609 **** +--- 5762,5768 ---- + int i; + PyObject *other_module; + PyObject *attr; ++ PyObject *imp; + + for (i = 0; i < (int)(sizeof(numeric_constants) + / sizeof(struct numeric_constant)); +*************** +*** 5671,5685 **** + + ADD_OBJECT(m, "VIM_SPECIAL_PATH", vim_special_path_object); + +! #if PY_MAJOR_VERSION >= 3 +! ADD_OBJECT(m, "_PathFinder", path_finder); +! ADD_CHECKED_OBJECT(m, "_find_module", +! (py_find_module = PyObject_GetAttrString(path_finder, +! "find_module"))); +! #else + ADD_OBJECT(m, "_find_module", py_find_module); + ADD_OBJECT(m, "_load_module", py_load_module); +- #endif + + return 0; + } +--- 5830,5855 ---- + + ADD_OBJECT(m, "VIM_SPECIAL_PATH", vim_special_path_object); + +! if (!(imp = PyImport_ImportModule("imp"))) +! return -1; +! +! if (!(py_find_module = PyObject_GetAttrString(imp, "find_module"))) +! { +! Py_DECREF(imp); +! return -1; +! } +! +! if (!(py_load_module = PyObject_GetAttrString(imp, "load_module"))) +! { +! Py_DECREF(py_find_module); +! Py_DECREF(imp); +! return -1; +! } +! +! Py_DECREF(imp); +! + ADD_OBJECT(m, "_find_module", py_find_module); + ADD_OBJECT(m, "_load_module", py_load_module); + + return 0; + } +*** ../vim-7.3.1173/src/if_python3.c 2013-06-10 21:27:18.000000000 +0200 +--- src/if_python3.c 2013-06-12 14:36:00.000000000 +0200 +*************** +*** 175,180 **** +--- 175,181 ---- + # define PyObject_HasAttrString py3_PyObject_HasAttrString + # define PyObject_SetAttrString py3_PyObject_SetAttrString + # define PyObject_CallFunctionObjArgs py3_PyObject_CallFunctionObjArgs ++ # define _PyObject_CallFunction_SizeT py3__PyObject_CallFunction_SizeT + # define PyObject_Call py3_PyObject_Call + # define PyEval_GetLocals py3_PyEval_GetLocals + # define PyEval_GetGlobals py3_PyEval_GetGlobals +*************** +*** 296,301 **** +--- 297,303 ---- + static int (*py3_PyObject_HasAttrString)(PyObject *, const char *); + static PyObject* (*py3_PyObject_SetAttrString)(PyObject *, const char *, PyObject *); + static PyObject* (*py3_PyObject_CallFunctionObjArgs)(PyObject *, ...); ++ static PyObject* (*py3__PyObject_CallFunction_SizeT)(PyObject *, char *, ...); + static PyObject* (*py3_PyObject_Call)(PyObject *, PyObject *, PyObject *); + static PyObject* (*py3_PyEval_GetGlobals)(); + static PyObject* (*py3_PyEval_GetLocals)(); +*************** +*** 458,463 **** +--- 460,466 ---- + {"PyObject_HasAttrString", (PYTHON_PROC*)&py3_PyObject_HasAttrString}, + {"PyObject_SetAttrString", (PYTHON_PROC*)&py3_PyObject_SetAttrString}, + {"PyObject_CallFunctionObjArgs", (PYTHON_PROC*)&py3_PyObject_CallFunctionObjArgs}, ++ {"_PyObject_CallFunction_SizeT", (PYTHON_PROC*)&py3__PyObject_CallFunction_SizeT}, + {"PyObject_Call", (PYTHON_PROC*)&py3_PyObject_Call}, + {"PyEval_GetGlobals", (PYTHON_PROC*)&py3_PyEval_GetGlobals}, + {"PyEval_GetLocals", (PYTHON_PROC*)&py3_PyEval_GetLocals}, +*************** +*** 740,748 **** + + static struct PyModuleDef vimmodule; + +- static PyObject *path_finder; +- static PyObject *py_find_module = NULL; +- + #define PY_CAN_RECURSE + + /* +--- 743,748 ---- +*************** +*** 1603,1672 **** + #endif + + static PyObject * +- VimPathHook(PyObject *self UNUSED, PyObject *args) +- { +- char *path; +- +- if (PyArg_ParseTuple(args, "s", &path) +- && STRCMP(path, vim_special_path) == 0) +- { +- Py_INCREF(&FinderType); +- return (PyObject *) &FinderType; +- } +- +- PyErr_Clear(); +- PyErr_SetNone(PyExc_ImportError); +- return NULL; +- } +- +- static PyObject * +- FinderFindModule(PyObject *cls UNUSED, PyObject *fullname) +- { +- PyObject *new_path; +- PyObject *r; +- +- if (!(new_path = Vim_GetPaths(NULL))) +- return NULL; +- +- /* call find_module of the super() class */ +- r = PyObject_CallFunctionObjArgs(py_find_module, fullname, new_path, NULL); +- +- Py_DECREF(new_path); +- +- return r; +- } +- +- static struct PyMethodDef FinderMethods[] = { +- {"find_module", FinderFindModule, METH_CLASS|METH_O, ""}, +- {NULL, NULL, 0, NULL} +- }; +- +- static PyObject * + Py3Init_vim(void) + { + /* The special value is removed from sys.path in Python3_Init(). */ + static wchar_t *(argv[2]) = {L"/must>not&exist/foo", NULL}; +- PyObject *importlib_machinery; +- +- if (!(importlib_machinery = PyImport_ImportModule("importlib.machinery"))) +- return NULL; +- +- if (!(path_finder = PyObject_GetAttrString(importlib_machinery, +- "PathFinder"))) +- { +- Py_DECREF(importlib_machinery); +- return NULL; +- } +- +- Py_DECREF(importlib_machinery); +- +- vim_memset(&FinderType, 0, sizeof(FinderObject)); +- FinderType.tp_name = "vim.Finder"; +- FinderType.tp_basicsize = sizeof(FinderObject); +- FinderType.tp_base = (PyTypeObject *) path_finder; +- FinderType.tp_flags = Py_TPFLAGS_DEFAULT; +- FinderType.tp_doc = "Vim finder class, for use with path hook"; +- FinderType.tp_methods = FinderMethods; + + if (init_types()) + return NULL; +--- 1603,1612 ---- +*** ../vim-7.3.1173/src/if_python.c 2013-06-12 14:20:15.000000000 +0200 +--- src/if_python.c 2013-06-12 14:35:49.000000000 +0200 +*************** +*** 752,763 **** + static PyObject *ListGetattr(PyObject *, char *); + static PyObject *FunctionGetattr(PyObject *, char *); + +- static PyObject *FinderFindModule(PyObject *, PyObject *); +- static PyObject *VimPathHook(PyObject *, PyObject *); +- +- static PyObject *py_find_module; +- static PyObject *py_load_module; +- + #ifndef Py_VISIT + # define Py_VISIT(obj) visit(obj, arg) + #endif +--- 752,757 ---- +*************** +*** 1382,1585 **** + } + #endif + +- static void +- LoaderDestructor(LoaderObject *self) +- { +- Py_DECREF(self->module); +- DESTRUCTOR_FINISH(self); +- } +- +- static PyObject * +- LoaderLoadModule(LoaderObject *self, PyObject *args UNUSED) +- { +- PyObject *r = self->module; +- +- Py_INCREF(r); +- return r; +- } +- +- static struct PyMethodDef LoaderMethods[] = { +- /* name, function, calling, doc */ +- {"load_module", (PyCFunction)LoaderLoadModule, METH_VARARGS, ""}, +- { NULL, NULL, 0, NULL} +- }; +- +- static PyObject * +- call_load_module(char *name, int len, PyObject *find_module_result) +- { +- PyObject *fd, *pathname, *description; +- +- if (!PyTuple_Check(find_module_result) +- || PyTuple_GET_SIZE(find_module_result) != 3) +- { +- PyErr_SetString(PyExc_TypeError, +- _("expected 3-tuple as imp.find_module() result")); +- return NULL; +- } +- +- if (!(fd = PyTuple_GET_ITEM(find_module_result, 0)) +- || !(pathname = PyTuple_GET_ITEM(find_module_result, 1)) +- || !(description = PyTuple_GET_ITEM(find_module_result, 2))) +- { +- PyErr_SetString(PyExc_RuntimeError, +- _("internal error: imp.find_module returned tuple with NULL")); +- return NULL; +- } +- +- return PyObject_CallFunction(py_load_module, +- "s#OOO", name, len, fd, pathname, description); +- } +- +- static PyObject * +- find_module(char *fullname, char *tail, PyObject *new_path) +- { +- PyObject *find_module_result; +- PyObject *module; +- char *dot; +- +- if ((dot = (char *) vim_strchr((char_u *) tail, '.'))) +- { +- /* +- * There is a dot in the name: call find_module recursively without the +- * first component +- */ +- PyObject *newest_path; +- int partlen = (int) (dot - 1 - tail); +- +- if (!(find_module_result = PyObject_CallFunction(py_find_module, +- "s#O", tail, partlen, new_path))) +- return NULL; +- +- if (!(module = call_load_module( +- fullname, +- ((int) (tail - fullname)) + partlen, +- find_module_result))) +- { +- Py_DECREF(find_module_result); +- return NULL; +- } +- +- Py_DECREF(find_module_result); +- +- if (!(newest_path = PyObject_GetAttrString(module, "__path__"))) +- { +- Py_DECREF(module); +- return NULL; +- } +- +- Py_DECREF(module); +- +- module = find_module(fullname, dot + 1, newest_path); +- +- Py_DECREF(newest_path); +- +- return module; +- } +- else +- { +- if (!(find_module_result = PyObject_CallFunction(py_find_module, +- "sO", tail, new_path))) +- return NULL; +- +- if (!(module = call_load_module( +- fullname, +- STRLEN(fullname), +- find_module_result))) +- { +- Py_DECREF(find_module_result); +- return NULL; +- } +- +- Py_DECREF(find_module_result); +- +- return module; +- } +- } +- +- static PyObject * +- FinderFindModule(PyObject *self, PyObject *args) +- { +- char *fullname; +- PyObject *module; +- PyObject *new_path; +- LoaderObject *loader; +- +- if (!PyArg_ParseTuple(args, "s", &fullname)) +- return NULL; +- +- if (!(new_path = Vim_GetPaths(self))) +- return NULL; +- +- module = find_module(fullname, fullname, new_path); +- +- Py_DECREF(new_path); +- +- if (!module) +- { +- Py_INCREF(Py_None); +- return Py_None; +- } +- +- if (!(loader = PyObject_NEW(LoaderObject, &LoaderType))) +- { +- Py_DECREF(module); +- return NULL; +- } +- +- loader->module = module; +- +- return (PyObject *) loader; +- } +- +- static PyObject * +- VimPathHook(PyObject *self UNUSED, PyObject *args) +- { +- char *path; +- +- if (PyArg_ParseTuple(args, "s", &path) +- && STRCMP(path, vim_special_path) == 0) +- { +- Py_INCREF(vim_module); +- return vim_module; +- } +- +- PyErr_Clear(); +- PyErr_SetNone(PyExc_ImportError); +- return NULL; +- } +- + static int + PythonMod_Init(void) + { + /* The special value is removed from sys.path in Python_Init(). */ + static char *(argv[2]) = {"/must>not&exist/foo", NULL}; +- PyObject *imp; +- +- if (!(imp = PyImport_ImportModule("imp"))) +- return -1; +- +- if (!(py_find_module = PyObject_GetAttrString(imp, "find_module"))) +- { +- Py_DECREF(imp); +- return -1; +- } +- +- if (!(py_load_module = PyObject_GetAttrString(imp, "load_module"))) +- { +- Py_DECREF(py_find_module); +- Py_DECREF(imp); +- return -1; +- } +- +- Py_DECREF(imp); +- +- vim_memset(&LoaderType, 0, sizeof(LoaderType)); +- LoaderType.tp_name = "vim.Loader"; +- LoaderType.tp_basicsize = sizeof(LoaderObject); +- LoaderType.tp_flags = Py_TPFLAGS_DEFAULT; +- LoaderType.tp_doc = "vim message object"; +- LoaderType.tp_methods = LoaderMethods; +- LoaderType.tp_dealloc = (destructor)LoaderDestructor; + + if (init_types()) + return -1; +--- 1376,1386 ---- +*** ../vim-7.3.1173/src/version.c 2013-06-12 14:26:20.000000000 +0200 +--- src/version.c 2013-06-12 14:35:25.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1174, + /**/ + +-- +"Hit any key to continue" is very confusing when you have two keyboards. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 645e3c0b1c2da05961cd33bad620d17473b00d04 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:01 +0200 Subject: [PATCH 1067/3340] - patchlevel 1175 --- 7.3.1175 | 99 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 99 insertions(+) create mode 100644 7.3.1175 diff --git a/7.3.1175 b/7.3.1175 new file mode 100644 index 00000000..37235f3a --- /dev/null +++ b/7.3.1175 @@ -0,0 +1,99 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1175 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1175 +Problem: Using isalpha() and isalnum() can be slow. +Solution: Use range checks. (Mike Williams) +Files: src/ex_docmd.c, src/macros.h + + +*** ../vim-7.3.1174/src/ex_docmd.c 2013-06-08 18:19:39.000000000 +0200 +--- src/ex_docmd.c 2013-06-12 16:50:50.000000000 +0200 +*************** +*** 3120,3126 **** + for (j = 0; p[j] != NUL; ++j) + if (p[j] != cmdmods[i].name[j]) + break; +! if (!isalpha(p[j]) && j >= cmdmods[i].minlen + && (p == cmd || cmdmods[i].has_count)) + return j + (int)(p - cmd); + } +--- 3120,3126 ---- + for (j = 0; p[j] != NUL; ++j) + if (p[j] != cmdmods[i].name[j]) + break; +! if (!ASCII_ISALPHA(p[j]) && j >= cmdmods[i].minlen + && (p == cmd || cmdmods[i].has_count)) + return j + (int)(p - cmd); + } +*** ../vim-7.3.1174/src/macros.h 2013-06-12 14:10:23.000000000 +0200 +--- src/macros.h 2013-06-12 17:07:32.000000000 +0200 +*************** +*** 99,104 **** +--- 99,109 ---- + # define MB_TOUPPER(c) TOUPPER_LOC(c) + #endif + ++ /* Use our own isdigit() replacement, because on MS-Windows isdigit() returns ++ * non-zero for superscript 1. Also avoids that isdigit() crashes for numbers ++ * below 0 and above 255. */ ++ #define VIM_ISDIGIT(c) ((unsigned)(c) - '0' < 10) ++ + /* Like isalpha() but reject non-ASCII characters. Can't be used with a + * special key (negative value). */ + #ifdef EBCDIC +*************** +*** 107,123 **** + # define ASCII_ISLOWER(c) islower(c) + # define ASCII_ISUPPER(c) isupper(c) + #else +- # define ASCII_ISALPHA(c) ((c) < 0x7f && isalpha(c)) +- # define ASCII_ISALNUM(c) ((c) < 0x7f && isalnum(c)) + # define ASCII_ISLOWER(c) ((unsigned)(c) - 'a' < 26) + # define ASCII_ISUPPER(c) ((unsigned)(c) - 'A' < 26) + #endif + +- /* Use our own isdigit() replacement, because on MS-Windows isdigit() returns +- * non-zero for superscript 1. Also avoids that isdigit() crashes for numbers +- * below 0 and above 255. */ +- #define VIM_ISDIGIT(c) ((unsigned)(c) - '0' < 10) +- + /* macro version of chartab(). + * Only works with values 0-255! + * Doesn't work for UTF-8 mode with chars >= 0x80. */ +--- 112,123 ---- + # define ASCII_ISLOWER(c) islower(c) + # define ASCII_ISUPPER(c) isupper(c) + #else + # define ASCII_ISLOWER(c) ((unsigned)(c) - 'a' < 26) + # define ASCII_ISUPPER(c) ((unsigned)(c) - 'A' < 26) ++ # define ASCII_ISALPHA(c) (ASCII_ISUPPER(c) || ASCII_ISLOWER(c)) ++ # define ASCII_ISALNUM(c) (ASCII_ISALPHA(c) || VIM_ISDIGIT(c)) + #endif + + /* macro version of chartab(). + * Only works with values 0-255! + * Doesn't work for UTF-8 mode with chars >= 0x80. */ +*** ../vim-7.3.1174/src/version.c 2013-06-12 14:40:58.000000000 +0200 +--- src/version.c 2013-06-12 17:05:51.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1175, + /**/ + +-- +"Hit any key to continue" is a lie. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 5a8c973d6fa2bcd1cb5ae470ee775f6deff6b4c8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:02 +0200 Subject: [PATCH 1068/3340] - patchlevel 1176 --- 7.3.1176 | 89 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) create mode 100644 7.3.1176 diff --git a/7.3.1176 b/7.3.1176 new file mode 100644 index 00000000..1e2cd6b7 --- /dev/null +++ b/7.3.1176 @@ -0,0 +1,89 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1176 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1176 +Problem: Compiler warnings on 64 bit system. +Solution: Add type casts. (Mike Williams) +Files: src/eval.c, src/if_py_both.h + + +*** ../vim-7.3.1175/src/eval.c 2013-06-12 13:37:36.000000000 +0200 +--- src/eval.c 2013-06-12 18:06:33.000000000 +0200 +*************** +*** 10980,10986 **** + * also work, but some plugins depend on the name being printable + * text. */ + sprintf(sid_buf, "%ld_", (long)current_SID); +! rettv->vval.v_string = alloc(STRLEN(sid_buf) + STRLEN(s + 2) + 1); + if (rettv->vval.v_string != NULL) + { + STRCPY(rettv->vval.v_string, sid_buf); +--- 10980,10987 ---- + * also work, but some plugins depend on the name being printable + * text. */ + sprintf(sid_buf, "%ld_", (long)current_SID); +! rettv->vval.v_string = +! alloc((int)(STRLEN(sid_buf) + STRLEN(s + 2) + 1)); + if (rettv->vval.v_string != NULL) + { + STRCPY(rettv->vval.v_string, sid_buf); +*** ../vim-7.3.1175/src/if_py_both.h 2013-06-12 14:40:58.000000000 +0200 +--- src/if_py_both.h 2013-06-12 18:10:27.000000000 +0200 +*************** +*** 992,998 **** + if ((dot = (char *) vim_strchr((char_u *) tail, '.'))) + { + /* +! * There is a dot in the name: call find_module recursively without the + * first component + */ + PyObject *newest_path; +--- 992,998 ---- + if ((dot = (char *) vim_strchr((char_u *) tail, '.'))) + { + /* +! * There is a dot in the name: call find_module recursively without the + * first component + */ + PyObject *newest_path; +*************** +*** 1035,1041 **** + + if (!(module = call_load_module( + fullname, +! STRLEN(fullname), + find_module_result))) + { + Py_DECREF(find_module_result); +--- 1035,1041 ---- + + if (!(module = call_load_module( + fullname, +! (int)STRLEN(fullname), + find_module_result))) + { + Py_DECREF(find_module_result); +*** ../vim-7.3.1175/src/version.c 2013-06-12 17:12:19.000000000 +0200 +--- src/version.c 2013-06-12 18:07:10.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1176, + /**/ + +-- +Living in Hollywood is like living in a bowl of granola. What ain't +fruits and nuts is flakes. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From db86b05ac87a13cece9edfaa7d00f8cf296eb95d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:03 +0200 Subject: [PATCH 1069/3340] - patchlevel 1177 --- 7.3.1177 | 99 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 99 insertions(+) create mode 100644 7.3.1177 diff --git a/7.3.1177 b/7.3.1177 new file mode 100644 index 00000000..43090783 --- /dev/null +++ b/7.3.1177 @@ -0,0 +1,99 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1177 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1177 +Problem: Wasting memory on padding. +Solution: Reorder struct fields. (Dominique Pelle) +Files: src/structs.h, src/fileio.c + + +*** ../vim-7.3.1176/src/structs.h 2013-06-06 14:55:16.000000000 +0200 +--- src/structs.h 2013-06-12 19:21:02.000000000 +0200 +*************** +*** 1180,1191 **** + */ + struct dictvar_S + { + int dv_refcount; /* reference count */ +- hashtab_T dv_hashtab; /* hashtab that refers to the items */ + int dv_copyID; /* ID used by deepcopy() */ + dict_T *dv_copydict; /* copied dict used by deepcopy() */ +- char dv_lock; /* zero, VAR_LOCKED, VAR_FIXED */ +- char dv_scope; /* zero, VAR_SCOPE, VAR_DEF_SCOPE */ + dict_T *dv_used_next; /* next dict in used dicts list */ + dict_T *dv_used_prev; /* previous dict in used dicts list */ + }; +--- 1180,1191 ---- + */ + struct dictvar_S + { ++ char dv_lock; /* zero, VAR_LOCKED, VAR_FIXED */ ++ char dv_scope; /* zero, VAR_SCOPE, VAR_DEF_SCOPE */ + int dv_refcount; /* reference count */ + int dv_copyID; /* ID used by deepcopy() */ ++ hashtab_T dv_hashtab; /* hashtab that refers to the items */ + dict_T *dv_copydict; /* copied dict used by deepcopy() */ + dict_T *dv_used_next; /* next dict in used dicts list */ + dict_T *dv_used_prev; /* previous dict in used dicts list */ + }; +*** ../vim-7.3.1176/src/fileio.c 2013-06-08 18:19:39.000000000 +0200 +--- src/fileio.c 2013-06-12 19:23:35.000000000 +0200 +*************** +*** 7614,7629 **** + + typedef struct AutoPat + { +- int group; /* group ID */ + char_u *pat; /* pattern as typed (NULL when pattern + has been removed) */ +- int patlen; /* strlen() of pat */ + regprog_T *reg_prog; /* compiled regprog for pattern */ +- char allow_dirs; /* Pattern may match whole path */ +- char last; /* last pattern for apply_autocmds() */ + AutoCmd *cmds; /* list of commands to do */ + struct AutoPat *next; /* next AutoPat in AutoPat list */ + int buflocal_nr; /* !=0 for buffer-local AutoPat */ + } AutoPat; + + static struct event_name +--- 7614,7629 ---- + + typedef struct AutoPat + { + char_u *pat; /* pattern as typed (NULL when pattern + has been removed) */ + regprog_T *reg_prog; /* compiled regprog for pattern */ + AutoCmd *cmds; /* list of commands to do */ + struct AutoPat *next; /* next AutoPat in AutoPat list */ ++ int group; /* group ID */ ++ int patlen; /* strlen() of pat */ + int buflocal_nr; /* !=0 for buffer-local AutoPat */ ++ char allow_dirs; /* Pattern may match whole path */ ++ char last; /* last pattern for apply_autocmds() */ + } AutoPat; + + static struct event_name +*** ../vim-7.3.1176/src/version.c 2013-06-12 18:13:31.000000000 +0200 +--- src/version.c 2013-06-12 19:20:19.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1177, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +174. You know what a listserv is. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 85da6099a685840b7fd404441d0627b74fac9937 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:04 +0200 Subject: [PATCH 1070/3340] - patchlevel 1178 --- 7.3.1178 | 378 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 378 insertions(+) create mode 100644 7.3.1178 diff --git a/7.3.1178 b/7.3.1178 new file mode 100644 index 00000000..d6f1586d --- /dev/null +++ b/7.3.1178 @@ -0,0 +1,378 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1178 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1178 +Problem: Can't put all Vim config files together in one directory. +Solution: Load ~/.vim/vimrc if ~/.vimrc does not exist. (Lech Lorens) +Files: runtime/doc/gui.txt, runtime/doc/starting.txt, src/gui.c, + src/main.c, src/os_amiga.h, src/os_dos.h, src/os_unix.h + + +*** ../vim-7.3.1177/runtime/doc/gui.txt 2010-08-15 21:57:17.000000000 +0200 +--- runtime/doc/gui.txt 2013-06-12 20:11:13.000000000 +0200 +*************** +*** 93,102 **** + terminal version. + + Recommended place for your personal GUI initializations: +! Unix $HOME/.gvimrc +! OS/2 $HOME/.gvimrc or $VIM/.gvimrc +! MS-DOS and Win32 $HOME/_gvimrc or $VIM/_gvimrc +! Amiga s:.gvimrc or $VIM/.gvimrc + + There are a number of options which only have meaning in the GUI version of + Vim. These are 'guicursor', 'guifont', 'guipty' and 'guioptions'. They are +--- 93,108 ---- + terminal version. + + Recommended place for your personal GUI initializations: +! Unix $HOME/.gvimrc or $HOME/.vim/gvimrc +! OS/2 $HOME/.gvimrc, $HOME/vimfiles/gvimrc +! or $VIM/.gvimrc +! MS-DOS and Win32 $HOME/_gvimrc, $HOME/vimfiles/gvimrc +! or $VIM/_gvimrc +! Amiga s:.gvimrc, home:.gvimrc, home:vimfiles:gvimrc +! or $VIM/.gvimrc +! +! The personal initialization files are searched in the order specified above +! and only the first one that is found is read. + + There are a number of options which only have meaning in the GUI version of + Vim. These are 'guicursor', 'guifont', 'guipty' and 'guioptions'. They are +*** ../vim-7.3.1177/runtime/doc/starting.txt 2010-08-15 21:57:15.000000000 +0200 +--- runtime/doc/starting.txt 2013-06-12 20:31:45.000000000 +0200 +*************** +*** 95,108 **** + (normally not installed) + view vim -R Start in read-only mode (see |-R|). *view* + gvim vim -g Start the GUI (see |gui|). *gvim* +! gex vim -eg Start the GUI in Ex mode. *gex* +! gview vim -Rg Start the GUI in read-only mode. *gview* + rvim vim -Z Like "vim", but in restricted mode (see |-Z|) *rvim* +! rview vim -RZ Like "view", but in restricted mode. *rview* +! rgvim vim -gZ Like "gvim", but in restricted mode. *rgvim* +! rgview vim -RgZ Like "gview", but in restricted mode. *rgview* + evim vim -y Easy Vim: set 'insertmode' (see |-y|) *evim* +! eview vim -yR Like "evim" in read-only mode *eview* + vimdiff vim -d Start in diff mode |diff-mode| + gvimdiff vim -gd Start in diff mode |diff-mode| + +--- 95,108 ---- + (normally not installed) + view vim -R Start in read-only mode (see |-R|). *view* + gvim vim -g Start the GUI (see |gui|). *gvim* +! gex vim -eg Start the GUI in Ex mode. *gex* +! gview vim -Rg Start the GUI in read-only mode. *gview* + rvim vim -Z Like "vim", but in restricted mode (see |-Z|) *rvim* +! rview vim -RZ Like "view", but in restricted mode. *rview* +! rgvim vim -gZ Like "gvim", but in restricted mode. *rgvim* +! rgview vim -RgZ Like "gview", but in restricted mode. *rgview* + evim vim -y Easy Vim: set 'insertmode' (see |-y|) *evim* +! eview vim -yR Like "evim" in read-only mode *eview* + vimdiff vim -d Start in diff mode |diff-mode| + gvimdiff vim -gd Start in diff mode |diff-mode| + +*************** +*** 751,761 **** + file, but "exrc" is what Vi always used, "vimrc" is a Vim specific + name. Also see |vimrc-intro|. + +! Recommended place for your personal initializations: +! Unix $HOME/.vimrc +! OS/2 $HOME/.vimrc or $VIM/.vimrc (or _vimrc) +! MS-DOS and Win32 $HOME/_vimrc or $VIM/_vimrc +! Amiga s:.vimrc or $VIM/.vimrc + + If Vim was started with "-u filename", the file "filename" is used. + All following initializations until 4. are skipped. +--- 757,777 ---- + file, but "exrc" is what Vi always used, "vimrc" is a Vim specific + name. Also see |vimrc-intro|. + +! Places for your personal initializations: +! Unix $HOME/.vimrc or $HOME/.vim/vimrc +! OS/2 $HOME/.vimrc, $HOME/vimfiles/vimrc +! or $VIM/.vimrc (or _vimrc) +! MS-Windows $HOME/_vimrc, $HOME/vimfiles/vimrc +! or $VIM/_vimrc +! Amiga s:.vimrc, home:.vimrc, home:vimfiles:vimrc +! or $VIM/.vimrc +! +! The files are searched in the order specified above and only the first +! one that is found is read. +! +! RECOMMENDATION: Put all your Vim configuration stuff in the +! $HOME/.vim/ directory ($HOME/vimfiles/ for MS-Windows). That makes it +! easy to copy it to another system. + + If Vim was started with "-u filename", the file "filename" is used. + All following initializations until 4. are skipped. +*************** +*** 785,796 **** + - The environment variable VIMINIT (see also |compatible-default|) (*) + The value of $VIMINIT is used as an Ex command line. + - The user vimrc file(s): +! "$HOME/.vimrc" (for Unix and OS/2) (*) +! "s:.vimrc" (for Amiga) (*) +! "home:.vimrc" (for Amiga) (*) +! "$VIM/.vimrc" (for OS/2 and Amiga) (*) +! "$HOME/_vimrc" (for MS-DOS and Win32) (*) +! "$VIM/_vimrc" (for MS-DOS and Win32) (*) + Note: For Unix, OS/2 and Amiga, when ".vimrc" does not exist, + "_vimrc" is also tried, in case an MS-DOS compatible file + system is used. For MS-DOS and Win32 ".vimrc" is checked +--- 801,815 ---- + - The environment variable VIMINIT (see also |compatible-default|) (*) + The value of $VIMINIT is used as an Ex command line. + - The user vimrc file(s): +! "$HOME/.vimrc" (for Unix and OS/2) (*) +! "$HOME/.vim/vimrc" (for Unix and OS/2) (*) +! "s:.vimrc" (for Amiga) (*) +! "home:.vimrc" (for Amiga) (*) +! "home:vimfiles:vimrc" (for Amiga) (*) +! "$VIM/.vimrc" (for OS/2 and Amiga) (*) +! "$HOME/_vimrc" (for MS-DOS and Win32) (*) +! "$HOME/vimfiles/vimrc" (for MS-DOS and Win32) (*) +! "$VIM/_vimrc" (for MS-DOS and Win32) (*) + Note: For Unix, OS/2 and Amiga, when ".vimrc" does not exist, + "_vimrc" is also tried, in case an MS-DOS compatible file + system is used. For MS-DOS and Win32 ".vimrc" is checked +*** ../vim-7.3.1177/src/gui.c 2013-06-08 18:19:40.000000000 +0200 +--- src/gui.c 2013-06-12 20:09:44.000000000 +0200 +*************** +*** 547,556 **** + && do_source((char_u *)USR_GVIMRC_FILE2, TRUE, + DOSO_GVIMRC) == FAIL + #endif + ) + { +! #ifdef USR_GVIMRC_FILE3 +! (void)do_source((char_u *)USR_GVIMRC_FILE3, TRUE, DOSO_GVIMRC); + #endif + } + +--- 547,560 ---- + && do_source((char_u *)USR_GVIMRC_FILE2, TRUE, + DOSO_GVIMRC) == FAIL + #endif ++ #ifdef USR_GVIMRC_FILE3 ++ && do_source((char_u *)USR_GVIMRC_FILE3, TRUE, ++ DOSO_GVIMRC) == FAIL ++ #endif + ) + { +! #ifdef USR_GVIMRC_FILE4 +! (void)do_source((char_u *)USR_GVIMRC_FILE4, TRUE, DOSO_GVIMRC); + #endif + } + +*************** +*** 593,598 **** +--- 597,606 ---- + && fullpathcmp((char_u *)USR_GVIMRC_FILE3, + (char_u *)GVIMRC_FILE, FALSE) != FPC_SAME + #endif ++ #ifdef USR_GVIMRC_FILE4 ++ && fullpathcmp((char_u *)USR_GVIMRC_FILE4, ++ (char_u *)GVIMRC_FILE, FALSE) != FPC_SAME ++ #endif + ) + do_source((char_u *)GVIMRC_FILE, TRUE, DOSO_GVIMRC); + +*** ../vim-7.3.1177/src/main.c 2013-05-11 13:56:12.000000000 +0200 +--- src/main.c 2013-06-12 20:09:44.000000000 +0200 +*************** +*** 2981,2986 **** +--- 2981,2990 ---- + && do_source((char_u *)USR_VIMRC_FILE3, TRUE, + DOSO_VIMRC) == FAIL + #endif ++ #ifdef USR_VIMRC_FILE4 ++ && do_source((char_u *)USR_VIMRC_FILE4, TRUE, ++ DOSO_VIMRC) == FAIL ++ #endif + && process_env((char_u *)"EXINIT", FALSE) == FAIL + && do_source((char_u *)USR_EXRC_FILE, FALSE, DOSO_NONE) == FAIL) + { +*** ../vim-7.3.1177/src/os_amiga.h 2012-11-20 16:53:34.000000000 +0100 +--- src/os_amiga.h 2013-06-12 20:09:44.000000000 +0200 +*************** +*** 158,164 **** + # define USR_VIMRC_FILE2 "home:.vimrc" + #endif + #ifndef USR_VIMRC_FILE3 +! # define USR_VIMRC_FILE3 "$VIM/.vimrc" + #endif + #ifndef EVIM_FILE + # define EVIM_FILE "$VIMRUNTIME/evim.vim" +--- 158,167 ---- + # define USR_VIMRC_FILE2 "home:.vimrc" + #endif + #ifndef USR_VIMRC_FILE3 +! # define USR_VIMRC_FILE3 "home:vimfiles:vimrc" +! #endif +! #ifndef USR_VIMRC_FILE4 +! # define USR_VIMRC_FILE4 "$VIM/.vimrc" + #endif + #ifndef EVIM_FILE + # define EVIM_FILE "$VIMRUNTIME/evim.vim" +*************** +*** 171,177 **** + # define USR_GVIMRC_FILE2 "home:.gvimrc" + #endif + #ifndef USR_GVIMRC_FILE3 +! # define USR_GVIMRC_FILE3 "$VIM/.gvimrc" + #endif + + #ifdef FEAT_VIMINFO +--- 174,183 ---- + # define USR_GVIMRC_FILE2 "home:.gvimrc" + #endif + #ifndef USR_GVIMRC_FILE3 +! # define USR_GVIMRC_FILE3 "home:vimfiles:gvimrc" +! #endif +! #ifndef USR_GVIMRC_FILE4 +! # define USR_GVIMRC_FILE4 "$VIM/.gvimrc" + #endif + + #ifdef FEAT_VIMINFO +*** ../vim-7.3.1177/src/os_dos.h 2010-08-15 21:57:27.000000000 +0200 +--- src/os_dos.h 2013-06-12 20:09:44.000000000 +0200 +*************** +*** 20,26 **** + # define USR_VIMRC_FILE "$HOME\\_vimrc" + #endif + #ifndef USR_VIMRC_FILE2 +! # define USR_VIMRC_FILE2 "$VIM\\_vimrc" + #endif + #ifndef EVIM_FILE + # define EVIM_FILE "$VIMRUNTIME\\evim.vim" +--- 20,29 ---- + # define USR_VIMRC_FILE "$HOME\\_vimrc" + #endif + #ifndef USR_VIMRC_FILE2 +! # define USR_VIMRC_FILE2 "$HOME\\vimfiles\\vimrc" +! #endif +! #ifndef USR_VIMRC_FILE3 +! # define USR_VIMRC_FILE3 "$VIM\\_vimrc" + #endif + #ifndef EVIM_FILE + # define EVIM_FILE "$VIMRUNTIME\\evim.vim" +*************** +*** 41,47 **** + # define USR_GVIMRC_FILE "$HOME\\_gvimrc" + # endif + # ifndef USR_GVIMRC_FILE2 +! # define USR_GVIMRC_FILE2 "$VIM\\_gvimrc" + # endif + # ifndef SYS_MENU_FILE + # define SYS_MENU_FILE "$VIMRUNTIME\\menu.vim" +--- 44,53 ---- + # define USR_GVIMRC_FILE "$HOME\\_gvimrc" + # endif + # ifndef USR_GVIMRC_FILE2 +! # define USR_GVIMRC_FILE2 "$HOME\\vimfiles\\gvimrc" +! # endif +! # ifndef USR_GVIMRC_FILE3 +! # define USR_GVIMRC_FILE3 "$VIM\\_gvimrc" + # endif + # ifndef SYS_MENU_FILE + # define SYS_MENU_FILE "$VIMRUNTIME\\menu.vim" +*** ../vim-7.3.1177/src/os_unix.h 2012-11-20 16:53:34.000000000 +0100 +--- src/os_unix.h 2013-06-12 20:09:44.000000000 +0200 +*************** +*** 294,304 **** + # endif + #endif + +! #if !defined(USR_VIMRC_FILE2) && defined(OS2) +! # define USR_VIMRC_FILE2 "$VIM/.vimrc" + #endif +! #if !defined(USR_VIMRC_FILE2) && defined(VMS) +! # define USR_VIMRC_FILE2 "sys$login:_vimrc" + #endif + + #ifndef USR_GVIMRC_FILE +--- 294,317 ---- + # endif + #endif + +! +! #if !defined(USR_EXRC_FILE2) +! # ifdef OS2 +! # define USR_VIMRC_FILE2 "$HOME/vimfiles/vimrc" +! # else +! # ifdef VMS +! # define USR_VIMRC_FILE2 "sys$login:vimfiles:vimrc" +! # else +! # define USR_VIMRC_FILE2 "~/.vim/vimrc" +! # endif +! # endif +! #endif +! +! #if !defined(USR_VIMRC_FILE3) && defined(OS2) +! # define USR_VIMRC_FILE3 "$VIM/.vimrc" + #endif +! #if !defined(USR_VIMRC_FILE3) && defined(VMS) +! # define USR_VIMRC_FILE3 "sys$login:_vimrc" + #endif + + #ifndef USR_GVIMRC_FILE +*************** +*** 309,317 **** + # endif + #endif + + #ifdef VMS +! # ifndef USR_GVIMRC_FILE2 +! # define USR_GVIMRC_FILE2 "sys$login:_gvimrc" + # endif + #endif + +--- 322,342 ---- + # endif + #endif + ++ #ifndef USR_GVIMRC_FILE2 ++ # ifdef OS2 ++ # define USR_GVIMRC_FILE2 "$HOME/vimfiles/gvimrc" ++ # else ++ # ifdef VMS ++ # define USR_GVIMRC_FILE2 "sys$login:vimfiles:gvimrc" ++ # else ++ # define USR_GVIMRC_FILE2 "~/.vim/gvimrc" ++ # endif ++ # endif ++ #endif ++ + #ifdef VMS +! # ifndef USR_GVIMRC_FILE3 +! # define USR_GVIMRC_FILE3 "sys$login:_gvimrc" + # endif + #endif + +*** ../vim-7.3.1177/src/version.c 2013-06-12 19:52:11.000000000 +0200 +--- src/version.c 2013-06-12 20:34:25.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1178, + /**/ + +-- +If Microsoft would build a car... +... the oil, water temperature, and alternator warning lights would +all be replaced by a single "General Protection Fault" warning light. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9316c503d03c475a2d96f6c900e6603ac97aa6f2 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:05 +0200 Subject: [PATCH 1071/3340] - patchlevel 1179 --- 7.3.1179 | 122 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 122 insertions(+) create mode 100644 7.3.1179 diff --git a/7.3.1179 b/7.3.1179 new file mode 100644 index 00000000..e5530110 --- /dev/null +++ b/7.3.1179 @@ -0,0 +1,122 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1179 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1179 +Problem: When a global mapping starts with the same characters as a + buffer-local mapping Vim waits for a character to be typed to find + out whether the global mapping is to be used. (Andy Wokula) +Solution: Use the local mapping without waiting. (Michael Henry) +Files: runtime/doc/map.txt, src/getchar.c + + +*** ../vim-7.3.1178/runtime/doc/map.txt 2013-06-08 15:24:41.000000000 +0200 +--- runtime/doc/map.txt 2013-06-12 20:50:01.000000000 +0200 +*************** +*** 107,112 **** +--- 107,114 ---- + :cmapc[lear] |mapmode-c| *:cmapc* *:cmapclear* + Remove ALL mappings for the modes where the map + command applies. {not in Vi} ++ Use the argument to remove buffer-local ++ mappings |:map-| + Warning: This also removes the default mappings. + + :map |mapmode-nvo| +*************** +*** 173,178 **** +--- 175,181 ---- + :mapclear + Local mappings are also cleared when a buffer is deleted, but not when it is + unloaded. Just like local option values. ++ Also see |map-precedence|. + + *:map-* *:map-silent* + To define a mapping which will not be echoed on the command line, add +*************** +*** 644,649 **** +--- 655,672 ---- + you type slowly, or your system is slow, reset the 'timeout' option. Then you + might want to set the 'ttimeout' option. + ++ *map-precedence* ++ Buffer-local mappings (defined using |:map-|) take precedence over ++ global mappings. When a buffer-local mapping is the same as a global mapping, ++ Vim will use the buffer-local mapping. In addition, Vim will use a complete ++ buffer-local mapping immediately, even if a longer global mapping has the ++ buffer-local mapping as a prefix. For example, given the following two ++ mappings: > ++ :map \a :echo "Local \a" ++ :map \abc :echo "Global \abc" ++ The buffer-local mapping \a will be used immediately. Vim will not wait for ++ more characters to see if the user might be typing \abc. ++ + *map-keys-fails* + There are situations where key codes might not be recognized: + - Vim can only read part of the key code. Mostly this is only the first +*** ../vim-7.3.1178/src/getchar.c 2013-05-06 05:50:22.000000000 +0200 +--- src/getchar.c 2013-06-12 20:52:49.000000000 +0200 +*************** +*** 1924,1929 **** +--- 1924,1930 ---- + mapblock_T *mp; + #ifdef FEAT_LOCALMAP + mapblock_T *mp2; ++ int expecting_global_mappings; + #endif + mapblock_T *mp_match; + int mp_match_len = 0; +*************** +*** 2105,2110 **** +--- 2106,2112 ---- + /* First try buffer-local mappings. */ + mp = curbuf->b_maphash[MAP_HASH(local_State, c1)]; + mp2 = maphash[MAP_HASH(local_State, c1)]; ++ expecting_global_mappings = (mp && mp2); + if (mp == NULL) + { + mp = mp2; +*************** +*** 2128,2133 **** +--- 2130,2145 ---- + #endif + (mp = mp->m_next)) + { ++ #ifdef FEAT_LOCALMAP ++ if (expecting_global_mappings && mp2 == NULL) ++ { ++ /* This is the first global mapping. If we've ++ * got a complete buffer-local match, use it. */ ++ if (mp_match) ++ break; ++ expecting_global_mappings = FALSE; ++ } ++ #endif + /* + * Only consider an entry if the first character + * matches and it is for the current state. +*** ../vim-7.3.1178/src/version.c 2013-06-12 20:35:46.000000000 +0200 +--- src/version.c 2013-06-12 20:56:36.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1179, + /**/ + +-- +If Apple would build a car... +... it would be powered by the sun, be reliable, five times +as fast and twice as easy to drive; but would only run on +five percent of the roads. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 619ee44f12e0e73c71515b9ab9a475b0b3e3eb6f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:06 +0200 Subject: [PATCH 1072/3340] - patchlevel 1180 --- 7.3.1180 | 68 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 7.3.1180 diff --git a/7.3.1180 b/7.3.1180 new file mode 100644 index 00000000..715ad0ae --- /dev/null +++ b/7.3.1180 @@ -0,0 +1,68 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1180 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1180 +Problem: When current directory changes, path from cscope may no longer be + valid. (AS Budden) +Solution: Always store the absolute path. (Christian Brabandt) +Files: src/if_cscope.c + + +*** ../vim-7.3.1179/src/if_cscope.c 2013-05-29 19:17:55.000000000 +0200 +--- src/if_cscope.c 2013-06-12 21:15:37.000000000 +0200 +*************** +*** 539,550 **** +--- 539,565 ---- + char *fname2 = NULL; + char *ppath = NULL; + int i; ++ #ifdef FEAT_MODIFY_FNAME ++ int len; ++ int usedlen = 0; ++ char_u *fbuf = NULL; ++ #endif + + /* get the filename (arg1), expand it, and try to stat it */ + if ((fname = (char *)alloc(MAXPATHL + 1)) == NULL) + goto add_err; + + expand_env((char_u *)arg1, (char_u *)fname, MAXPATHL); ++ #ifdef FEAT_MODIFY_FNAME ++ len = (int)STRLEN(fname); ++ fbuf = (char_u *)fname; ++ (void)modify_fname((char_u *)":p", &usedlen, ++ (char_u **)&fname, &fbuf, &len); ++ if (fname == NULL) ++ goto add_err; ++ fname = (char *)vim_strnsave((char_u *)fname, len); ++ vim_free(fbuf); ++ #endif + ret = stat(fname, &statbuf); + if (ret < 0) + { +*** ../vim-7.3.1179/src/version.c 2013-06-12 21:00:18.000000000 +0200 +--- src/version.c 2013-06-12 21:05:27.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1180, + /**/ + +-- +If Microsoft would build a car... +... Occasionally, executing a maneuver such as a left turn +would cause your car to shut down and refuse to restart, in +which case you would have to reinstall the engine. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a9a4a4c949e0b68b03c496719d594e1012d6f85a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:07 +0200 Subject: [PATCH 1073/3340] - patchlevel 1181 --- 7.3.1181 | 100 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 100 insertions(+) create mode 100644 7.3.1181 diff --git a/7.3.1181 b/7.3.1181 new file mode 100644 index 00000000..4ee86151 --- /dev/null +++ b/7.3.1181 @@ -0,0 +1,100 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1181 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1181 +Problem: Wrong error message for 1.0[0]. +Solution: Check for funcref and float separately. (Yasuhiro Matsumoto) +Files: src/eval.c + + +*** ../vim-7.3.1180/src/eval.c 2013-06-12 18:13:31.000000000 +0200 +--- src/eval.c 2013-06-12 22:06:30.000000000 +0200 +*************** +*** 112,117 **** +--- 112,118 ---- + static char *e_letwrong = N_("E734: Wrong variable type for %s="); + static char *e_nofunc = N_("E130: Unknown function: %s"); + static char *e_illvar = N_("E461: Illegal variable name: %s"); ++ static char *e_float_as_string = N_("E806: using Float as a String"); + + static dictitem_T globvars_var; /* variable used for g: */ + #define globvarht globvardict.dv_hashtab +*************** +*** 5268,5283 **** + char_u *s; + char_u *key = NULL; + +! if (rettv->v_type == VAR_FUNC +! #ifdef FEAT_FLOAT +! || rettv->v_type == VAR_FLOAT +! #endif +! ) + { + if (verbose) + EMSG(_("E695: Cannot index a Funcref")); + return FAIL; + } + + if (**arg == '.') + { +--- 5269,5288 ---- + char_u *s; + char_u *key = NULL; + +! if (rettv->v_type == VAR_FUNC) + { + if (verbose) + EMSG(_("E695: Cannot index a Funcref")); + return FAIL; + } ++ #ifdef FEAT_FLOAT ++ else if (rettv->v_type == VAR_FLOAT) ++ { ++ if (verbose) ++ EMSG(_(e_float_as_string)); ++ return FAIL; ++ } ++ #endif + + if (**arg == '.') + { +*************** +*** 20085,20091 **** + break; + #ifdef FEAT_FLOAT + case VAR_FLOAT: +! EMSG(_("E806: using Float as a String")); + break; + #endif + case VAR_STRING: +--- 20090,20096 ---- + break; + #ifdef FEAT_FLOAT + case VAR_FLOAT: +! EMSG(_(e_float_as_string)); + break; + #endif + case VAR_STRING: +*** ../vim-7.3.1180/src/version.c 2013-06-12 21:25:04.000000000 +0200 +--- src/version.c 2013-06-12 22:08:02.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1181, + /**/ + +-- +The CIA drives around in cars with the "Intel inside" logo. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 78d1401eccc469e19cf6177c6a74cfc62ef9d899 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:08 +0200 Subject: [PATCH 1074/3340] - patchlevel 1182 --- 7.3.1182 | 588 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 588 insertions(+) create mode 100644 7.3.1182 diff --git a/7.3.1182 b/7.3.1182 new file mode 100644 index 00000000..eb3a2983 --- /dev/null +++ b/7.3.1182 @@ -0,0 +1,588 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1182 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1182 +Problem: 'backupcopy' default on MS-Windows does not work for hard and soft + links. +Solution: Check for links. (David Pope, Ken Takata) +Files: src/fileio.c, src/os_win32.c, src/proto/os_win32.pro + + +*** ../vim-7.3.1181/src/fileio.c 2013-06-12 19:52:11.000000000 +0200 +--- src/fileio.c 2013-06-12 22:31:34.000000000 +0200 +*************** +*** 3780,3791 **** + } + } + +- # ifdef UNIX + /* + * Break symlinks and/or hardlinks if we've been asked to. + */ + if ((bkc_flags & BKC_BREAKSYMLINK) || (bkc_flags & BKC_BREAKHARDLINK)) + { + int lstat_res; + + lstat_res = mch_lstat((char *)fname, &st); +--- 3780,3791 ---- + } + } + + /* + * Break symlinks and/or hardlinks if we've been asked to. + */ + if ((bkc_flags & BKC_BREAKSYMLINK) || (bkc_flags & BKC_BREAKHARDLINK)) + { ++ # ifdef UNIX + int lstat_res; + + lstat_res = mch_lstat((char *)fname, &st); +*************** +*** 3801,3808 **** + && st_old.st_nlink > 1 + && (lstat_res != 0 || st.st_ino == st_old.st_ino)) + backup_copy = FALSE; + } +- #endif + + #endif + +--- 3801,3818 ---- + && st_old.st_nlink > 1 + && (lstat_res != 0 || st.st_ino == st_old.st_ino)) + backup_copy = FALSE; ++ # else ++ # if defined(WIN32) ++ /* Symlinks. */ ++ if ((bkc_flags & BKC_BREAKSYMLINK) && mch_is_symbolic_link(fname)) ++ backup_copy = FALSE; ++ ++ /* Hardlinks. */ ++ if ((bkc_flags & BKC_BREAKHARDLINK) && mch_is_hard_link(fname)) ++ backup_copy = FALSE; ++ # endif ++ # endif + } + + #endif + +*** ../vim-7.3.1181/src/os_win32.c 2013-06-07 19:17:12.000000000 +0200 +--- src/os_win32.c 2013-06-12 22:39:53.000000000 +0200 +*************** +*** 78,83 **** +--- 78,93 ---- + # endif + #endif + ++ /* ++ * Reparse Point ++ */ ++ #ifndef FILE_ATTRIBUTE_REPARSE_POINT ++ # define FILE_ATTRIBUTE_REPARSE_POINT 0x00000400 ++ #endif ++ #ifndef IO_REPARSE_TAG_SYMLINK ++ # define IO_REPARSE_TAG_SYMLINK 0xA000000C ++ #endif ++ + /* Record all output and all keyboard & mouse input */ + /* #define MCH_WRITE_DUMP */ + +*************** +*** 219,224 **** +--- 229,238 ---- + static char *vimrun_path = "vimrun "; + #endif + ++ static int win32_getattrs(char_u *name); ++ static int win32_setattrs(char_u *name, int attrs); ++ static int win32_set_archive(char_u *name); ++ + #ifndef FEAT_GUI_W32 + static int suppress_winsize = 1; /* don't fiddle with console */ + #endif +*************** +*** 2623,2679 **** + /* + * get file permissions for `name' + * -1 : error +! * else FILE_ATTRIBUTE_* defined in winnt.h + */ + long + mch_getperm(char_u *name) + { +! #ifdef FEAT_MBYTE +! if (enc_codepage >= 0 && (int)GetACP() != enc_codepage) +! { +! WCHAR *p = enc_to_utf16(name, NULL); +! long n; + +! if (p != NULL) +! { +! n = (long)GetFileAttributesW(p); +! vim_free(p); +! if (n >= 0 || GetLastError() != ERROR_CALL_NOT_IMPLEMENTED) +! return n; +! /* Retry with non-wide function (for Windows 98). */ +! } +! } +! #endif +! return (long)GetFileAttributes((char *)name); + } + + + /* + * set file permission for `name' to `perm' + */ + int + mch_setperm( + char_u *name, + long perm) + { +! perm |= FILE_ATTRIBUTE_ARCHIVE; /* file has changed, set archive bit */ + #ifdef FEAT_MBYTE + if (enc_codepage >= 0 && (int)GetACP() != enc_codepage) + { +! WCHAR *p = enc_to_utf16(name, NULL); +! long n; + + if (p != NULL) + { +! n = (long)SetFileAttributesW(p, perm); + vim_free(p); +! if (n || GetLastError() != ERROR_CALL_NOT_IMPLEMENTED) +! return n ? OK : FAIL; + /* Retry with non-wide function (for Windows 98). */ + } + } + #endif +! return SetFileAttributes((char *)name, perm) ? OK : FAIL; + } + + /* +--- 2637,2690 ---- + /* + * get file permissions for `name' + * -1 : error +! * else mode_t + */ + long + mch_getperm(char_u *name) + { +! struct stat st; +! int n; + +! n = mch_stat(name, &st); +! return n == 0 ? (int)st.st_mode : -1; + } + + + /* + * set file permission for `name' to `perm' ++ * ++ * return FAIL for failure, OK otherwise + */ + int + mch_setperm( + char_u *name, + long perm) + { +! long n; + #ifdef FEAT_MBYTE ++ WCHAR *p; + if (enc_codepage >= 0 && (int)GetACP() != enc_codepage) + { +! p = enc_to_utf16(name, NULL); + + if (p != NULL) + { +! n = _wchmod(p, perm); + vim_free(p); +! if (n == -1 && GetLastError() != ERROR_CALL_NOT_IMPLEMENTED) +! return FAIL; + /* Retry with non-wide function (for Windows 98). */ + } + } ++ if (p == NULL) + #endif +! n = _chmod(name, perm); +! if (n == -1) +! return FAIL; +! +! win32_set_archive(name); +! +! return OK; + } + + /* +*************** +*** 2682,2730 **** + void + mch_hide(char_u *name) + { +! int perm; +! #ifdef FEAT_MBYTE +! WCHAR *p = NULL; +! +! if (enc_codepage >= 0 && (int)GetACP() != enc_codepage) +! p = enc_to_utf16(name, NULL); +! #endif + +! #ifdef FEAT_MBYTE +! if (p != NULL) +! { +! perm = GetFileAttributesW(p); +! if (perm < 0 && GetLastError() == ERROR_CALL_NOT_IMPLEMENTED) +! { +! /* Retry with non-wide function (for Windows 98). */ +! vim_free(p); +! p = NULL; +! } +! } +! if (p == NULL) +! #endif +! perm = GetFileAttributes((char *)name); +! if (perm >= 0) +! { +! perm |= FILE_ATTRIBUTE_HIDDEN; +! #ifdef FEAT_MBYTE +! if (p != NULL) +! { +! if (SetFileAttributesW(p, perm) == 0 +! && GetLastError() == ERROR_CALL_NOT_IMPLEMENTED) +! { +! /* Retry with non-wide function (for Windows 98). */ +! vim_free(p); +! p = NULL; +! } +! } +! if (p == NULL) +! #endif +! SetFileAttributes((char *)name, perm); +! } +! #ifdef FEAT_MBYTE +! vim_free(p); +! #endif + } + + /* +--- 2693,2704 ---- + void + mch_hide(char_u *name) + { +! int attrs = win32_getattrs(name); +! if (attrs == -1) +! return; + +! attrs |= FILE_ATTRIBUTE_HIDDEN; +! win32_setattrs(name, attrs); + } + + /* +*************** +*** 2734,2740 **** + int + mch_isdir(char_u *name) + { +! int f = mch_getperm(name); + + if (f == -1) + return FALSE; /* file does not exist at all */ +--- 2708,2714 ---- + int + mch_isdir(char_u *name) + { +! int f = win32_getattrs(name); + + if (f == -1) + return FALSE; /* file does not exist at all */ +*************** +*** 2770,2776 **** + * Return TRUE if file "fname" has more than one link. + */ + int +! mch_is_linked(char_u *fname) + { + BY_HANDLE_FILE_INFORMATION info; + +--- 2744,2750 ---- + * Return TRUE if file "fname" has more than one link. + */ + int +! mch_is_hard_link(char_u *fname) + { + BY_HANDLE_FILE_INFORMATION info; + +*************** +*** 2779,2784 **** +--- 2753,2826 ---- + } + + /* ++ * Return TRUE if file "fname" is a symbolic link. ++ */ ++ int ++ mch_is_symbolic_link(char_u *fname) ++ { ++ HANDLE hFind; ++ int res = FALSE; ++ WIN32_FIND_DATAA findDataA; ++ DWORD fileFlags = 0, reparseTag = 0; ++ #ifdef FEAT_MBYTE ++ WCHAR *wn = NULL; ++ WIN32_FIND_DATAW findDataW; ++ ++ if (enc_codepage >= 0 && (int)GetACP() != enc_codepage) ++ wn = enc_to_utf16(fname, NULL); ++ if (wn != NULL) ++ { ++ hFind = FindFirstFileW(wn, &findDataW); ++ vim_free(wn); ++ if (hFind == INVALID_HANDLE_VALUE ++ && GetLastError() == ERROR_CALL_NOT_IMPLEMENTED) ++ { ++ /* Retry with non-wide function (for Windows 98). */ ++ hFind = FindFirstFile(fname, &findDataA); ++ if (hFind != INVALID_HANDLE_VALUE) ++ { ++ fileFlags = findDataA.dwFileAttributes; ++ reparseTag = findDataA.dwReserved0; ++ } ++ } ++ else ++ { ++ fileFlags = findDataW.dwFileAttributes; ++ reparseTag = findDataW.dwReserved0; ++ } ++ } ++ #else ++ hFind = FindFirstFile(fname, &findDataA); ++ if (hFind != INVALID_HANDLE_VALUE) ++ { ++ fileFlags = findDataA.dwFileAttributes; ++ reparseTag = findDataA.dwReserved0; ++ } ++ #endif ++ ++ if (hFind != INVALID_HANDLE_VALUE) ++ FindClose(hFind); ++ ++ if ((fileFlags & FILE_ATTRIBUTE_REPARSE_POINT) ++ && reparseTag == IO_REPARSE_TAG_SYMLINK) ++ res = TRUE; ++ ++ return res; ++ } ++ ++ /* ++ * Return TRUE if file "fname" has more than one link or if it is a symbolic ++ * link. ++ */ ++ int ++ mch_is_linked(char_u *fname) ++ { ++ if (mch_is_hard_link(fname) || mch_is_symbolic_link(fname)) ++ return TRUE; ++ return FALSE; ++ } ++ ++ /* + * Get the by-handle-file-information for "fname". + * Returns FILEINFO_OK when OK. + * returns FILEINFO_ENC_FAIL when enc_to_utf16() failed. +*************** +*** 2842,2847 **** +--- 2884,2975 ---- + } + + /* ++ * get file attributes for `name' ++ * -1 : error ++ * else FILE_ATTRIBUTE_* defined in winnt.h ++ */ ++ static ++ int ++ win32_getattrs(char_u *name) ++ { ++ int attr; ++ #ifdef FEAT_MBYTE ++ WCHAR *p = NULL; ++ ++ if (enc_codepage >= 0 && (int)GetACP() != enc_codepage) ++ p = enc_to_utf16(name, NULL); ++ ++ if (p != NULL) ++ { ++ attr = GetFileAttributesW(p); ++ if (attr < 0 && GetLastError() == ERROR_CALL_NOT_IMPLEMENTED) ++ { ++ /* Retry with non-wide function (for Windows 98). */ ++ vim_free(p); ++ p = NULL; ++ } ++ } ++ if (p == NULL) ++ #endif ++ attr = GetFileAttributes((char *)name); ++ #ifdef FEAT_MBYTE ++ vim_free(p); ++ #endif ++ return attr; ++ } ++ ++ /* ++ * set file attributes for `name' to `attrs' ++ * ++ * return -1 for failure, 0 otherwise ++ */ ++ static ++ int ++ win32_setattrs(char_u *name, int attrs) ++ { ++ int res; ++ #ifdef FEAT_MBYTE ++ WCHAR *p = NULL; ++ ++ if (enc_codepage >= 0 && (int)GetACP() != enc_codepage) ++ p = enc_to_utf16(name, NULL); ++ ++ if (p != NULL) ++ { ++ res = SetFileAttributesW(p, attrs); ++ if (res == FALSE ++ && GetLastError() == ERROR_CALL_NOT_IMPLEMENTED) ++ { ++ /* Retry with non-wide function (for Windows 98). */ ++ vim_free(p); ++ p = NULL; ++ } ++ } ++ if (p == NULL) ++ #endif ++ res = SetFileAttributes((char *)name, attrs); ++ #ifdef FEAT_MBYTE ++ vim_free(p); ++ #endif ++ return res ? 0 : -1; ++ } ++ ++ /* ++ * Set archive flag for "name". ++ */ ++ static ++ int ++ win32_set_archive(char_u *name) ++ { ++ int attrs = win32_getattrs(name); ++ if (attrs == -1) ++ return -1; ++ ++ attrs |= FILE_ATTRIBUTE_ARCHIVE; ++ return win32_setattrs(name, attrs); ++ } ++ ++ /* + * Return TRUE if file or directory "name" is writable (not readonly). + * Strange semantics of Win32: a readonly directory is writable, but you can't + * delete a file. Let's say this means it is writable. +*************** +*** 2849,2858 **** + int + mch_writable(char_u *name) + { +! int perm = mch_getperm(name); + +! return (perm != -1 && (!(perm & FILE_ATTRIBUTE_READONLY) +! || (perm & FILE_ATTRIBUTE_DIRECTORY))); + } + + /* +--- 2977,2986 ---- + int + mch_writable(char_u *name) + { +! int attrs = win32_getattrs(name); + +! return (attrs != -1 && (!(attrs & FILE_ATTRIBUTE_READONLY) +! || (attrs & FILE_ATTRIBUTE_DIRECTORY))); + } + + /* +*************** +*** 5012,5024 **** + #ifdef FEAT_MBYTE + WCHAR *wn = NULL; + int n; + + if (enc_codepage >= 0 && (int)GetACP() != enc_codepage) + { + wn = enc_to_utf16(name, NULL); + if (wn != NULL) + { +- SetFileAttributesW(wn, FILE_ATTRIBUTE_NORMAL); + n = DeleteFileW(wn) ? 0 : -1; + vim_free(wn); + if (n == 0 || GetLastError() != ERROR_CALL_NOT_IMPLEMENTED) +--- 5140,5155 ---- + #ifdef FEAT_MBYTE + WCHAR *wn = NULL; + int n; ++ #endif + ++ win32_setattrs(name, FILE_ATTRIBUTE_NORMAL); ++ ++ #ifdef FEAT_MBYTE + if (enc_codepage >= 0 && (int)GetACP() != enc_codepage) + { + wn = enc_to_utf16(name, NULL); + if (wn != NULL) + { + n = DeleteFileW(wn) ? 0 : -1; + vim_free(wn); + if (n == 0 || GetLastError() != ERROR_CALL_NOT_IMPLEMENTED) +*************** +*** 5027,5033 **** + } + } + #endif +- SetFileAttributes(name, FILE_ATTRIBUTE_NORMAL); + return DeleteFile(name) ? 0 : -1; + } + +--- 5158,5163 ---- +*** ../vim-7.3.1181/src/proto/os_win32.pro 2012-11-20 16:56:49.000000000 +0100 +--- src/proto/os_win32.pro 2013-06-12 22:29:53.000000000 +0200 +*************** +*** 21,26 **** +--- 21,28 ---- + void mch_hide __ARGS((char_u *name)); + int mch_isdir __ARGS((char_u *name)); + int mch_mkdir __ARGS((char_u *name)); ++ int mch_is_hard_link __ARGS((char_u *fname)); ++ int mch_is_symbolic_link __ARGS((char_u *fname)); + int mch_is_linked __ARGS((char_u *fname)); + int win32_fileinfo __ARGS((char_u *fname, BY_HANDLE_FILE_INFORMATION *info)); + int mch_writable __ARGS((char_u *name)); +*** ../vim-7.3.1181/src/version.c 2013-06-12 22:08:54.000000000 +0200 +--- src/version.c 2013-06-12 22:40:29.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1182, + /**/ + +-- +If Microsoft would build a car... +... You'd have to press the "Start" button to turn the engine off. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d72e275dbdaf312bfb442160f79d3faa611d90be Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:09 +0200 Subject: [PATCH 1075/3340] - patchlevel 1183 --- 7.3.1183 | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 7.3.1183 diff --git a/7.3.1183 b/7.3.1183 new file mode 100644 index 00000000..633ac812 --- /dev/null +++ b/7.3.1183 @@ -0,0 +1,47 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1183 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1183 +Problem: Python tests 86 and 87 fail. +Solution: Add "empty" files. (ZyX) +Files: src/testdir/python_before/before_1.py, + src/testdir/python_before/before_2.py + + +*** ../vim-7.3.1182/src/testdir/python_before/before_1.py 2013-06-13 19:26:45.000000000 +0200 +--- src/testdir/python_before/before_1.py 2013-06-13 19:20:01.000000000 +0200 +*************** +*** 0 **** +--- 1 ---- ++ # empty file +*** ../vim-7.3.1182/src/testdir/python_before/before_2.py 2013-06-13 19:26:45.000000000 +0200 +--- src/testdir/python_before/before_2.py 2013-06-13 19:20:12.000000000 +0200 +*************** +*** 0 **** +--- 1 ---- ++ # empty file +*** ../vim-7.3.1182/src/version.c 2013-06-12 22:41:30.000000000 +0200 +--- src/version.c 2013-06-13 19:26:23.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1183, + /**/ + +-- +Wizards had always known that the act of observation changed the thing that +was observed, and sometimes forgot that it also changed the observer too. + Terry Pratchett - Interesting times + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From eac4b359a43f77356da07345f2cabac4780b3ed7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:10 +0200 Subject: [PATCH 1076/3340] - patchlevel 1184 --- 7.3.1184 | 65 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 7.3.1184 diff --git a/7.3.1184 b/7.3.1184 new file mode 100644 index 00000000..cb016efa --- /dev/null +++ b/7.3.1184 @@ -0,0 +1,65 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1184 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1184 +Problem: Highlighting is sometimes wrong. (Axel Bender) +Solution: Fetch regline again when returning from recursive regmatch. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1183/src/regexp_nfa.c 2013-06-11 22:44:03.000000000 +0200 +--- src/regexp_nfa.c 2013-06-13 19:32:31.000000000 +0200 +*************** +*** 4495,4501 **** + int **listids; + { + char_u *save_reginput = reginput; +- char_u *save_regline = regline; + int save_reglnum = reglnum; + int save_nfa_match = nfa_match; + int save_nfa_listid = nfa_listid; +--- 4495,4500 ---- +*************** +*** 4633,4640 **** + + /* restore position in input text */ + reginput = save_reginput; +- regline = save_regline; + reglnum = save_reglnum; + nfa_match = save_nfa_match; + nfa_endp = save_nfa_endp; + nfa_listid = save_nfa_listid; +--- 4632,4640 ---- + + /* restore position in input text */ + reginput = save_reginput; + reglnum = save_reglnum; ++ if (REG_MULTI) ++ regline = reg_getline(reglnum); + nfa_match = save_nfa_match; + nfa_endp = save_nfa_endp; + nfa_listid = save_nfa_listid; +*** ../vim-7.3.1183/src/version.c 2013-06-13 19:27:13.000000000 +0200 +--- src/version.c 2013-06-13 19:32:57.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1184, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +183. You move your coffeemaker next to your computer. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e388b8e28638c01d92725dce74d9a876344614ac Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:11 +0200 Subject: [PATCH 1077/3340] - patchlevel 1185 --- 7.3.1185 | 101 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 101 insertions(+) create mode 100644 7.3.1185 diff --git a/7.3.1185 b/7.3.1185 new file mode 100644 index 00000000..c209994e --- /dev/null +++ b/7.3.1185 @@ -0,0 +1,101 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1185 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1185 +Problem: New regexp engine: no match with ^ after \n. (SungHyun Nam) +Solution: Fix it, add a test. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1184/src/regexp_nfa.c 2013-06-13 19:47:03.000000000 +0200 +--- src/regexp_nfa.c 2013-06-13 20:10:23.000000000 +0200 +*************** +*** 3936,3944 **** + case NFA_BOL: + case NFA_BOF: + /* "^" won't match past end-of-line, don't bother trying. +! * Except when we are going to the next line for a look-behind +! * match. */ + if (reginput > regline + && (nfa_endp == NULL + || !REG_MULTI + || reglnum == nfa_endp->se_u.pos.lnum)) +--- 3936,3945 ---- + case NFA_BOL: + case NFA_BOF: + /* "^" won't match past end-of-line, don't bother trying. +! * Except when at the end of the line, or when we are going to the +! * next line for a look-behind match. */ + if (reginput > regline ++ && *reginput != NUL + && (nfa_endp == NULL + || !REG_MULTI + || reglnum == nfa_endp->se_u.pos.lnum)) +*** ../vim-7.3.1184/src/testdir/test64.in 2013-06-10 16:35:11.000000000 +0200 +--- src/testdir/test64.in 2013-06-13 20:01:36.000000000 +0200 +*************** +*** 480,485 **** +--- 480,491 ---- + :.yank + y$Gop:" + :" ++ :" Check a pattern with a line break and ^ and $ ++ /^Abc: ++ /a\n^b$\n^c/e ++ :.yank ++ Gop:" ++ :" + :" Check a pattern with a look beind crossing a line boundary + /^Behind: + /\(<\_[xy]\+\)\@3<=start +*************** +*** 555,560 **** +--- 561,571 ---- + xjk + lmn + ++ Abc: ++ a ++ b ++ c ++ + Behind: + asdfasdAc 7 + ghi + ++ c ++ + xxstart3 + + thexE thE thExethe +*** ../vim-7.3.1184/src/version.c 2013-06-13 19:47:03.000000000 +0200 +--- src/version.c 2013-06-13 20:11:36.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1185, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +185. You order fast food over the Internet + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a121ed55bab26ca02d339dcd8fbce8246f6c5a04 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:12 +0200 Subject: [PATCH 1078/3340] - patchlevel 1186 --- 7.3.1186 | 68 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 7.3.1186 diff --git a/7.3.1186 b/7.3.1186 new file mode 100644 index 00000000..870095e6 --- /dev/null +++ b/7.3.1186 @@ -0,0 +1,68 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.11 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1186 +Problem: Python 3: test 87 may crash. +Solution: Use _PyArg_Parse_SizeT instead of PyArg_Parse. (Jun Takimoto) +Files: src/if_python3.c + + +*** ../vim-7.3.1185/src/if_python3.c 2013-06-12 14:40:58.000000000 +0200 +--- src/if_python3.c 2013-06-13 20:44:48.000000000 +0200 +*************** +*** 425,437 **** + {"PySys_SetArgv", (PYTHON_PROC*)&py3_PySys_SetArgv}, + {"Py_SetPythonHome", (PYTHON_PROC*)&py3_Py_SetPythonHome}, + {"Py_Initialize", (PYTHON_PROC*)&py3_Py_Initialize}, +- # ifndef PY_SSIZE_T_CLEAN +- {"PyArg_ParseTuple", (PYTHON_PROC*)&py3_PyArg_ParseTuple}, +- {"Py_BuildValue", (PYTHON_PROC*)&py3_Py_BuildValue}, +- # else + {"_PyArg_ParseTuple_SizeT", (PYTHON_PROC*)&py3_PyArg_ParseTuple}, + {"_Py_BuildValue_SizeT", (PYTHON_PROC*)&py3_Py_BuildValue}, +- # endif + {"PyMem_Free", (PYTHON_PROC*)&py3_PyMem_Free}, + {"PyMem_Malloc", (PYTHON_PROC*)&py3_PyMem_Malloc}, + {"PyList_New", (PYTHON_PROC*)&py3_PyList_New}, +--- 425,432 ---- +*************** +*** 488,494 **** + {"PyEval_InitThreads", (PYTHON_PROC*)&py3_PyEval_InitThreads}, + {"PyEval_RestoreThread", (PYTHON_PROC*)&py3_PyEval_RestoreThread}, + {"PyEval_SaveThread", (PYTHON_PROC*)&py3_PyEval_SaveThread}, +! {"PyArg_Parse", (PYTHON_PROC*)&py3_PyArg_Parse}, + {"Py_IsInitialized", (PYTHON_PROC*)&py3_Py_IsInitialized}, + {"_PyObject_NextNotImplemented", (PYTHON_PROC*)&py3__PyObject_NextNotImplemented}, + {"_Py_NoneStruct", (PYTHON_PROC*)&py3__Py_NoneStruct}, +--- 483,489 ---- + {"PyEval_InitThreads", (PYTHON_PROC*)&py3_PyEval_InitThreads}, + {"PyEval_RestoreThread", (PYTHON_PROC*)&py3_PyEval_RestoreThread}, + {"PyEval_SaveThread", (PYTHON_PROC*)&py3_PyEval_SaveThread}, +! {"_PyArg_Parse_SizeT", (PYTHON_PROC*)&py3_PyArg_Parse}, + {"Py_IsInitialized", (PYTHON_PROC*)&py3_Py_IsInitialized}, + {"_PyObject_NextNotImplemented", (PYTHON_PROC*)&py3__PyObject_NextNotImplemented}, + {"_Py_NoneStruct", (PYTHON_PROC*)&py3__Py_NoneStruct}, +*** ../vim-7.3.1185/src/version.c 2013-06-13 20:19:35.000000000 +0200 +--- src/version.c 2013-06-13 20:45:49.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1186, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +188. You purchase a laptop so you can surf while sitting on the can. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 06926148022a1089ce87788c970c10745b336845 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:13 +0200 Subject: [PATCH 1079/3340] - patchlevel 1187 --- 7.3.1187 | 81 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 7.3.1187 diff --git a/7.3.1187 b/7.3.1187 new file mode 100644 index 00000000..614cb864 --- /dev/null +++ b/7.3.1187 @@ -0,0 +1,81 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1187 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1187 (after 7.3.1170) +Problem: "s:" is recognized but "" is not. (ZyX) +Solution: Translate "" like "s:". +Files: src/eval.c + + +*** ../vim-7.3.1186/src/eval.c 2013-06-12 22:08:54.000000000 +0200 +--- src/eval.c 2013-06-13 21:15:58.000000000 +0200 +*************** +*** 10976,10996 **** + EMSG2(_("E700: Unknown function: %s"), s); + else + { +! if (STRNCMP(s, "s:", 2) == 0) + { + char sid_buf[25]; + +! /* Expand s: into nr_, so that the function can also be +! * called from another script. Using trans_function_name() would +! * also work, but some plugins depend on the name being printable +! * text. */ + sprintf(sid_buf, "%ld_", (long)current_SID); + rettv->vval.v_string = +! alloc((int)(STRLEN(sid_buf) + STRLEN(s + 2) + 1)); + if (rettv->vval.v_string != NULL) + { + STRCPY(rettv->vval.v_string, sid_buf); +! STRCAT(rettv->vval.v_string, s + 2); + } + } + else +--- 10976,10997 ---- + EMSG2(_("E700: Unknown function: %s"), s); + else + { +! if (STRNCMP(s, "s:", 2) == 0 || STRNCMP(s, "", 5) == 0) + { + char sid_buf[25]; ++ int off = *s == 's' ? 2 : 5; + +! /* Expand s: and into nr_, so that the function can +! * also be called from another script. Using trans_function_name() +! * would also work, but some plugins depend on the name being +! * printable text. */ + sprintf(sid_buf, "%ld_", (long)current_SID); + rettv->vval.v_string = +! alloc((int)(STRLEN(sid_buf) + STRLEN(s + off) + 1)); + if (rettv->vval.v_string != NULL) + { + STRCPY(rettv->vval.v_string, sid_buf); +! STRCAT(rettv->vval.v_string, s + off); + } + } + else +*** ../vim-7.3.1186/src/version.c 2013-06-13 20:57:44.000000000 +0200 +--- src/version.c 2013-06-13 21:18:28.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1187, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +189. You put your e-mail address in the upper left-hand corner of envelopes. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7aac4b5648bd1bac15d7b95c27ffcf832f0c5147 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:14 +0200 Subject: [PATCH 1080/3340] - patchlevel 1188 --- 7.3.1188 | 61 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 7.3.1188 diff --git a/7.3.1188 b/7.3.1188 new file mode 100644 index 00000000..ccd40475 --- /dev/null +++ b/7.3.1188 @@ -0,0 +1,61 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1188 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1188 +Problem: Newline characters messing up error message. +Solution: Remove the newlines. (Kazunobu Kuriyama) +Files: src/gui_x11.c + + +*** ../vim-7.3.1187/src/gui_x11.c 2010-11-16 15:04:51.000000000 +0100 +--- src/gui_x11.c 2013-06-13 21:54:39.000000000 +0200 +*************** +*** 2197,2208 **** + if ( xfs[i]->max_bounds.width != 2 * min_width + && xfs[i]->max_bounds.width != min_width) + { +! EMSG2(_("E253: Fontset name: %s\n"), base_name); +! EMSG2(_("Font0: %s\n"), font_name[min_font_idx]); +! EMSG2(_("Font1: %s\n"), font_name[i]); +! EMSGN(_("Font%ld width is not twice that of font0\n"), i); +! EMSGN(_("Font0 width: %ld\n"), xfs[min_font_idx]->max_bounds.width); +! EMSGN(_("Font1 width: %ld\n\n"), xfs[i]->max_bounds.width); + return FAIL; + } + } +--- 2197,2208 ---- + if ( xfs[i]->max_bounds.width != 2 * min_width + && xfs[i]->max_bounds.width != min_width) + { +! EMSG2(_("E253: Fontset name: %s"), base_name); +! EMSG2(_("Font0: %s"), font_name[min_font_idx]); +! EMSG2(_("Font1: %s"), font_name[i]); +! EMSGN(_("Font%ld width is not twice that of font0"), i); +! EMSGN(_("Font0 width: %ld"), xfs[min_font_idx]->max_bounds.width); +! EMSGN(_("Font1 width: %ld"), xfs[i]->max_bounds.width); + return FAIL; + } + } +*** ../vim-7.3.1187/src/version.c 2013-06-13 21:24:01.000000000 +0200 +--- src/version.c 2013-06-13 21:56:02.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1188, + /**/ + +-- +I'm in shape. Round IS a shape. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 09ac723700aca10f16a2ee1ac266c6e2f6582c2f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:15 +0200 Subject: [PATCH 1081/3340] - patchlevel 1189 --- 7.3.1189 | 75 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 75 insertions(+) create mode 100644 7.3.1189 diff --git a/7.3.1189 b/7.3.1189 new file mode 100644 index 00000000..7e6918a6 --- /dev/null +++ b/7.3.1189 @@ -0,0 +1,75 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1189 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1189 (after 7.3.1185) +Problem: Highlighting is still wrong sometimes. (Dominique Pelle) +Solution: Also restore reginput properly. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1188/src/regexp_nfa.c 2013-06-13 20:19:35.000000000 +0200 +--- src/regexp_nfa.c 2013-06-13 22:52:38.000000000 +0200 +*************** +*** 4495,4501 **** + regsubs_T *m; + int **listids; + { +! char_u *save_reginput = reginput; + int save_reglnum = reglnum; + int save_nfa_match = nfa_match; + int save_nfa_listid = nfa_listid; +--- 4495,4501 ---- + regsubs_T *m; + int **listids; + { +! int save_reginput_col = (int)(reginput - regline); + int save_reglnum = reglnum; + int save_nfa_match = nfa_match; + int save_nfa_listid = nfa_listid; +*************** +*** 4632,4641 **** + } + + /* restore position in input text */ +- reginput = save_reginput; + reglnum = save_reglnum; + if (REG_MULTI) + regline = reg_getline(reglnum); + nfa_match = save_nfa_match; + nfa_endp = save_nfa_endp; + nfa_listid = save_nfa_listid; +--- 4632,4641 ---- + } + + /* restore position in input text */ + reglnum = save_reglnum; + if (REG_MULTI) + regline = reg_getline(reglnum); ++ reginput = regline + save_reginput_col; + nfa_match = save_nfa_match; + nfa_endp = save_nfa_endp; + nfa_listid = save_nfa_listid; +*** ../vim-7.3.1188/src/version.c 2013-06-13 21:57:16.000000000 +0200 +--- src/version.c 2013-06-13 22:53:34.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1189, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +194. Your business cards contain your e-mail and home page address. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a24f9a50024c7ded99d07d030f7ec175e8ea9331 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Fri, 14 Jun 2013 00:29:17 +0200 Subject: [PATCH 1082/3340] - patchlevel 1189 --- README.patches | 80 ++++++++++++++++++++++++ vim.spec | 165 ++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 244 insertions(+), 1 deletion(-) diff --git a/README.patches b/README.patches index 923bf048..f5acb110 100644 --- a/README.patches +++ b/README.patches @@ -1139,3 +1139,83 @@ Individual patches for Vim 7.3: 2325 7.3.1107 compiler warnings for unused variables 1327 7.3.1108 error message for os.fchdir() 4969 7.3.1109 building on MS-Windows doesn't see changes in if_py_both.h + 23743 7.3.1110 new regexp matching: Using \@= and the like can be slow + 16934 7.3.1111 nfa_recognize_char_class() implementation is inefficient + 7450 7.3.1112 new regexp engine: \%V not supported + 8095 7.3.1113 new regexp engine: \%'m not supported + 1807 7.3.1114 (after 7.3.1110) can't build without the syntax feature + 8246 7.3.1115 users don't like cursor line number with 'relativenumber' set + 2461 7.3.1116 can't build without Visual mode + 8737 7.3.1117 new regexp engine: \%[abc] not supported + 4590 7.3.1118 match failure rate is not very specific + 6657 7.3.1119 flags in 'cpo' are searched for several times + 2736 7.3.1120 crash when regexp logging is enabled + 3151 7.3.1121 new regexp engine: adding states that are not used + 13428 7.3.1122 new regexp engine: \@> not supported + 1613 7.3.1123 can't build tiny Vim on MS-Windows + 1336 7.3.1124 Python: Crash on MS-Windows when os.fchdir() is not available + 3014 7.3.1125 error for using \%V in a pattern in tiny Vim + 1392 7.3.1126 compiler warning for uninitialized variable + 2533 7.3.1127 no error for using empty \%[] + 7328 7.3.1128 every failure in the NFA engine is a syntax error + 21365 7.3.1129 can't see what pattern in syntax highlighting is slow + 6016 7.3.1130 (after 7.3.1129) can't build with anything but huge features + 5173 7.3.1131 new regexp engine is a bit slow + 2704 7.3.1132 crash when debugging regexp + 8763 7.3.1133 new regexp engine is a bit slow + 2048 7.3.1134 running test 49 takes a long time + 2020 7.3.1135 compiler warning for unused argument + 1465 7.3.1136 ":func Foo" does not show attributes + 26955 7.3.1137 new regexp engine: collections are slow + 16357 7.3.1138 new regexp engine: neglist no longer used + 14897 7.3.1139 new regexp engine: negated flag is hardly used + 5298 7.3.1140 new regexp engine: can skip expensive match + 2548 7.3.1141 Win32: Check for available memory is not reliable + 1347 7.3.1142 memory leak in ":syntime report" + 1646 7.3.1143 when mapping NUL it is displayed as an X + 2557 7.3.1144 "RO" is not translated everywhere + 4036 7.3.1145 new regexp engine: addstate() is called very often + 10156 7.3.1146 new regexp engine: look-behind followed by zero-width fails + 4905 7.3.1147 new regexp engine: regstart is only used to find first match + 5345 7.3.1148 no command line completion for ":syntime" + 41306 7.3.1149 new regexp engine: Matching plain text could be faster + 10878 7.3.1150 new regexpengine: Slow for look-behind match without a width + 5073 7.3.1151 new regexp engine: Slow for look-behind plus zero-width match + 1795 7.3.1152 In tiny build ireg_icombine is undefined + 25686 7.3.1153 new regexp engine: look-behind matches can be very expensive + 2966 7.3.1154 new regexp_nfa engine: Uneccessary code + 1446 7.3.1155 MS-DOS: "make test" uses external rmdir command + 2852 7.3.1156 compiler warnings + 5289 7.3.1157 new regexp engine fails on "\(\" is not + 2131 7.3.1188 newline characters messing up error message + 2305 7.3.1189 (after 7.3.1185) highlighting is still wrong sometimes diff --git a/vim.spec b/vim.spec index c0559cb6..dcbfb751 100644 --- a/vim.spec +++ b/vim.spec @@ -18,7 +18,7 @@ #used for pre-releases: %define beta %{nil} %define vimdir vim73%{?beta} -%define patchlevel 1109 +%define patchlevel 1189 Summary: The VIM editor URL: http://www.vim.org/ @@ -1165,6 +1165,86 @@ Patch1106: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1106 Patch1107: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1107 Patch1108: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1108 Patch1109: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1109 +Patch1110: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1110 +Patch1111: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1111 +Patch1112: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1112 +Patch1113: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1113 +Patch1114: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1114 +Patch1115: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1115 +Patch1116: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1116 +Patch1117: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1117 +Patch1118: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1118 +Patch1119: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1119 +Patch1120: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1120 +Patch1121: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1121 +Patch1122: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1122 +Patch1123: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1123 +Patch1124: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1124 +Patch1125: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1125 +Patch1126: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1126 +Patch1127: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1127 +Patch1128: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1128 +Patch1129: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1129 +Patch1130: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1130 +Patch1131: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1131 +Patch1132: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1132 +Patch1133: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1133 +Patch1134: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1134 +Patch1135: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1135 +Patch1136: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1136 +Patch1137: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1137 +Patch1138: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1138 +Patch1139: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1139 +Patch1140: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1140 +Patch1141: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1141 +Patch1142: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1142 +Patch1143: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1143 +Patch1144: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1144 +Patch1145: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1145 +Patch1146: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1146 +Patch1147: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1147 +Patch1148: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1148 +Patch1149: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1149 +Patch1150: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1150 +Patch1151: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1151 +Patch1152: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1152 +Patch1153: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1153 +Patch1154: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1154 +Patch1155: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1155 +Patch1156: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1156 +Patch1157: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1157 +Patch1158: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1158 +Patch1159: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1159 +Patch1160: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1160 +Patch1161: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1161 +Patch1162: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1162 +Patch1163: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1163 +Patch1164: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1164 +Patch1165: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1165 +Patch1166: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1166 +Patch1167: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1167 +Patch1168: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1168 +Patch1169: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1169 +Patch1170: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1170 +Patch1171: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1171 +Patch1172: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1172 +Patch1173: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1173 +Patch1174: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1174 +Patch1175: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1175 +Patch1176: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1176 +Patch1177: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1177 +Patch1178: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1178 +Patch1179: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1179 +Patch1180: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1180 +Patch1181: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1181 +Patch1182: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1182 +Patch1183: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1183 +Patch1184: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1184 +Patch1185: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1185 +Patch1186: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1186 +Patch1187: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1187 +Patch1188: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1188 +Patch1189: ftp://ftp.vim.org/pub/vim/patches/7.3/7.3.1189 Patch3000: vim-7.3-syntax.patch Patch3002: vim-7.1-nowarnings.patch @@ -2421,6 +2501,86 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %patch1107 -p0 %patch1108 -p0 %patch1109 -p0 +%patch1110 -p0 +%patch1111 -p0 +%patch1112 -p0 +%patch1113 -p0 +%patch1114 -p0 +%patch1115 -p0 +%patch1116 -p0 +%patch1117 -p0 +%patch1118 -p0 +%patch1119 -p0 +%patch1120 -p0 +%patch1121 -p0 +%patch1122 -p0 +%patch1123 -p0 +%patch1124 -p0 +%patch1125 -p0 +%patch1126 -p0 +%patch1127 -p0 +%patch1128 -p0 +%patch1129 -p0 +%patch1130 -p0 +%patch1131 -p0 +%patch1132 -p0 +%patch1133 -p0 +%patch1134 -p0 +%patch1135 -p0 +%patch1136 -p0 +%patch1137 -p0 +%patch1138 -p0 +%patch1139 -p0 +%patch1140 -p0 +%patch1141 -p0 +%patch1142 -p0 +%patch1143 -p0 +%patch1144 -p0 +%patch1145 -p0 +%patch1146 -p0 +%patch1147 -p0 +%patch1148 -p0 +%patch1149 -p0 +%patch1150 -p0 +%patch1151 -p0 +%patch1152 -p0 +%patch1153 -p0 +%patch1154 -p0 +%patch1155 -p0 +%patch1156 -p0 +%patch1157 -p0 +%patch1158 -p0 +%patch1159 -p0 +%patch1160 -p0 +%patch1161 -p0 +%patch1162 -p0 +%patch1163 -p0 +%patch1164 -p0 +%patch1165 -p0 +%patch1166 -p0 +%patch1167 -p0 +%patch1168 -p0 +%patch1169 -p0 +%patch1170 -p0 +%patch1171 -p0 +%patch1172 -p0 +%patch1173 -p0 +%patch1174 -p0 +%patch1175 -p0 +%patch1176 -p0 +%patch1177 -p0 +%patch1178 -p0 +%patch1179 -p0 +%patch1180 -p0 +%patch1181 -p0 +%patch1182 -p0 +%patch1183 -p0 +%patch1184 -p0 +%patch1185 -p0 +%patch1186 -p0 +%patch1187 -p0 +%patch1188 -p0 +%patch1189 -p0 # install spell files @@ -2916,6 +3076,9 @@ rm -rf %{buildroot} %{_datadir}/icons/hicolor/*/apps/* %changelog +* Fri Jun 14 2013 Karsten Hopp 7.3.1189-1 +- patchlevel 1189 + * Tue Jun 04 2013 Karsten Hopp 7.3.1109-1 - patchlevel 1109 From aaf5df21b7df8ec8a46c0afafec691f5a576ae61 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:35:49 +0200 Subject: [PATCH 1083/3340] - patchlevel 1190 --- 7.3.1190 | 66 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) create mode 100644 7.3.1190 diff --git a/7.3.1190 b/7.3.1190 new file mode 100644 index 00000000..0d3fec3c --- /dev/null +++ b/7.3.1190 @@ -0,0 +1,66 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1190 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1190 +Problem: Compiler warning for parentheses. (Christian Wellenbrock) +Solution: Change #ifdef. +Files: src/ex_docmd.c + + +*** ../vim-7.3.1189/src/ex_docmd.c 2013-06-12 17:12:19.000000000 +0200 +--- src/ex_docmd.c 2013-06-14 19:08:10.000000000 +0200 +*************** +*** 8568,8578 **** + break; + + default: /* CMD_rshift or CMD_lshift */ +! if ((eap->cmdidx == CMD_rshift) + #ifdef FEAT_RIGHTLEFT +! ^ curwin->w_p_rl + #endif +! ) + oa.op_type = OP_RSHIFT; + else + oa.op_type = OP_LSHIFT; +--- 8568,8580 ---- + break; + + default: /* CMD_rshift or CMD_lshift */ +! if ( + #ifdef FEAT_RIGHTLEFT +! (eap->cmdidx == CMD_rshift) ^ curwin->w_p_rl +! #else +! eap->cmdidx == CMD_rshift + #endif +! ) + oa.op_type = OP_RSHIFT; + else + oa.op_type = OP_LSHIFT; +*** ../vim-7.3.1189/src/version.c 2013-06-13 22:59:25.000000000 +0200 +--- src/version.c 2013-06-14 19:14:40.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1190, + /**/ + +-- +Some of the well known MS-Windows errors: + ETIME Wrong time, wait a little while + ECRASH Try again... + EDETECT Unable to detect errors + EOVER You lost! Play another game? + ENOCLUE Eh, what did you want? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b5df1239cb33cfcdaa661ad490c89462ca4f1f27 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:35:50 +0200 Subject: [PATCH 1084/3340] - patchlevel 1191 --- 7.3.1191 | 311 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 311 insertions(+) create mode 100644 7.3.1191 diff --git a/7.3.1191 b/7.3.1191 new file mode 100644 index 00000000..1cf878ea --- /dev/null +++ b/7.3.1191 @@ -0,0 +1,311 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1191 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1191 +Problem: Backreference to previous line doesn't work. (Lech Lorens) +Solution: Implement looking in another line. +Files: src/regexp.c, src/regexp_nfa.c, src/testdir/test64.in, + src/testdir/test64.ok + + +*** ../vim-7.3.1190/src/regexp.c 2013-06-08 18:19:39.000000000 +0200 +--- src/regexp.c 2013-06-14 20:23:33.000000000 +0200 +*************** +*** 3519,3524 **** +--- 3519,3525 ---- + *(pp) = (savep)->se_u.ptr; } + + static int re_num_cmp __ARGS((long_u val, char_u *scan)); ++ static int match_with_backref __ARGS((linenr_T start_lnum, colnr_T start_col, linenr_T end_lnum, colnr_T end_col, int *bytelen)); + static int regmatch __ARGS((char_u *prog)); + static int regrepeat __ARGS((char_u *p, long maxcount)); + +*************** +*** 4979,4987 **** + case BACKREF + 9: + { + int len; +- linenr_T clnum; +- colnr_T ccol; +- char_u *p; + + no = op - BACKREF; + cleanup_subexpr(); +--- 4980,4985 ---- +*************** +*** 5023,5089 **** + { + /* Messy situation: Need to compare between two + * lines. */ +! ccol = reg_startpos[no].col; +! clnum = reg_startpos[no].lnum; +! for (;;) +! { +! /* Since getting one line may invalidate +! * the other, need to make copy. Slow! */ +! if (regline != reg_tofree) +! { +! len = (int)STRLEN(regline); +! if (reg_tofree == NULL +! || len >= (int)reg_tofreelen) +! { +! len += 50; /* get some extra */ +! vim_free(reg_tofree); +! reg_tofree = alloc(len); +! if (reg_tofree == NULL) +! { +! status = RA_FAIL; /* outof memory!*/ +! break; +! } +! reg_tofreelen = len; +! } +! STRCPY(reg_tofree, regline); +! reginput = reg_tofree +! + (reginput - regline); +! regline = reg_tofree; +! } +! +! /* Get the line to compare with. */ +! p = reg_getline(clnum); +! if (clnum == reg_endpos[no].lnum) +! len = reg_endpos[no].col - ccol; +! else +! len = (int)STRLEN(p + ccol); +! +! if (cstrncmp(p + ccol, reginput, &len) != 0) +! { +! status = RA_NOMATCH; /* doesn't match */ +! break; +! } +! if (clnum == reg_endpos[no].lnum) +! break; /* match and at end! */ +! if (reglnum >= reg_maxline) +! { +! status = RA_NOMATCH; /* text too short */ +! break; +! } +! +! /* Advance to next line. */ +! reg_nextline(); +! ++clnum; +! ccol = 0; +! if (got_int) +! { +! status = RA_FAIL; +! break; +! } +! } +! +! /* found a match! Note that regline may now point +! * to a copy of the line, that should not matter. */ + } + } + } +--- 5021,5032 ---- + { + /* Messy situation: Need to compare between two + * lines. */ +! status = match_with_backref( +! reg_startpos[no].lnum, +! reg_startpos[no].col, +! reg_endpos[no].lnum, +! reg_endpos[no].col, +! NULL); + } + } + } +*************** +*** 6505,6510 **** +--- 6448,6522 ---- + return val == n; + } + ++ /* ++ * Check whether a backreference matches. ++ * Returns RA_FAIL, RA_NOMATCH or RA_MATCH. ++ * If "bytelen" is not NULL, it is set to the bytelength of the whole match. ++ */ ++ static int ++ match_with_backref(start_lnum, start_col, end_lnum, end_col, bytelen) ++ linenr_T start_lnum; ++ colnr_T start_col; ++ linenr_T end_lnum; ++ colnr_T end_col; ++ int *bytelen; ++ { ++ linenr_T clnum = start_lnum; ++ colnr_T ccol = start_col; ++ int len; ++ char_u *p; ++ ++ if (bytelen != NULL) ++ *bytelen = 0; ++ for (;;) ++ { ++ /* Since getting one line may invalidate the other, need to make copy. ++ * Slow! */ ++ if (regline != reg_tofree) ++ { ++ len = (int)STRLEN(regline); ++ if (reg_tofree == NULL || len >= (int)reg_tofreelen) ++ { ++ len += 50; /* get some extra */ ++ vim_free(reg_tofree); ++ reg_tofree = alloc(len); ++ if (reg_tofree == NULL) ++ return RA_FAIL; /* out of memory!*/ ++ reg_tofreelen = len; ++ } ++ STRCPY(reg_tofree, regline); ++ reginput = reg_tofree + (reginput - regline); ++ regline = reg_tofree; ++ } ++ ++ /* Get the line to compare with. */ ++ p = reg_getline(clnum); ++ if (clnum == end_lnum) ++ len = end_col - ccol; ++ else ++ len = (int)STRLEN(p + ccol); ++ ++ if (cstrncmp(p + ccol, reginput, &len) != 0) ++ return RA_NOMATCH; /* doesn't match */ ++ if (bytelen != NULL) ++ *bytelen += len; ++ if (clnum == end_lnum) ++ break; /* match and at end! */ ++ if (reglnum >= reg_maxline) ++ return RA_NOMATCH; /* text too short */ ++ ++ /* Advance to next line. */ ++ reg_nextline(); ++ ++clnum; ++ ccol = 0; ++ if (got_int) ++ return RA_FAIL; ++ } ++ ++ /* found a match! Note that regline may now point to a copy of the line, ++ * that should not matter. */ ++ return RA_MATCH; ++ } + + #ifdef BT_REGEXP_DUMP + +*** ../vim-7.3.1190/src/regexp_nfa.c 2013-06-13 22:59:25.000000000 +0200 +--- src/regexp_nfa.c 2013-06-14 20:19:59.000000000 +0200 +*************** +*** 4367,4380 **** + if (sub->list.multi[subidx].start.lnum < 0 + || sub->list.multi[subidx].end.lnum < 0) + goto retempty; +! /* TODO: line breaks */ +! len = sub->list.multi[subidx].end.col +! - sub->list.multi[subidx].start.col; +! if (cstrncmp(regline + sub->list.multi[subidx].start.col, +! reginput, &len) == 0) + { +! *bytelen = len; +! return TRUE; + } + } + else +--- 4367,4393 ---- + if (sub->list.multi[subidx].start.lnum < 0 + || sub->list.multi[subidx].end.lnum < 0) + goto retempty; +! if (sub->list.multi[subidx].start.lnum == reglnum +! && sub->list.multi[subidx].end.lnum == reglnum) + { +! len = sub->list.multi[subidx].end.col +! - sub->list.multi[subidx].start.col; +! if (cstrncmp(regline + sub->list.multi[subidx].start.col, +! reginput, &len) == 0) +! { +! *bytelen = len; +! return TRUE; +! } +! } +! else +! { +! if (match_with_backref( +! sub->list.multi[subidx].start.lnum, +! sub->list.multi[subidx].start.col, +! sub->list.multi[subidx].end.lnum, +! sub->list.multi[subidx].end.col, +! bytelen) == RA_MATCH) +! return TRUE; + } + } + else +*** ../vim-7.3.1190/src/testdir/test64.in 2013-06-13 20:19:35.000000000 +0200 +--- src/testdir/test64.in 2013-06-14 20:01:56.000000000 +0200 +*************** +*** 486,491 **** +--- 486,497 ---- + :.yank + Gop:" + :" ++ :" Check using a backref matching in a previous line ++ /^Backref: ++ /\v.*\/(.*)\n.*\/\1$ ++ :.yank ++ Gop:" ++ :" + :" Check a pattern with a look beind crossing a line boundary + /^Behind: + /\(<\_[xy]\+\)\@3<=start +*************** +*** 566,571 **** +--- 572,584 ---- + b + c + ++ Backref: ++ ./Dir1/Dir2/zyxwvuts.txt ++ ./Dir1/Dir2/abcdefgh.bat ++ ++ ./Dir1/Dir2/file1.txt ++ ./OtherDir1/OtherDir2/file1.txt ++ + Behind: + asdfasd Date: Thu, 4 Jul 2013 15:35:51 +0200 Subject: [PATCH 1085/3340] - patchlevel 1192 --- 7.3.1192 | 192 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 192 insertions(+) create mode 100644 7.3.1192 diff --git a/7.3.1192 b/7.3.1192 new file mode 100644 index 00000000..30c40c33 --- /dev/null +++ b/7.3.1192 @@ -0,0 +1,192 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1192 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1192 +Problem: Valgrind reports errors when using backreferences. (Dominique + Pelle) +Solution: Do not check the end of submatches. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1191/src/regexp_nfa.c 2013-06-14 20:31:20.000000000 +0200 +--- src/regexp_nfa.c 2013-06-14 21:09:14.000000000 +0200 +*************** +*** 3612,3618 **** + } + + /* +! * Return TRUE if "sub1" and "sub2" have the same positions. + */ + static int + sub_equal(sub1, sub2) +--- 3612,3618 ---- + } + + /* +! * Return TRUE if "sub1" and "sub2" have the same start positions. + */ + static int + sub_equal(sub1, sub2) +*************** +*** 3621,3630 **** + { + int i; + int todo; +! linenr_T s1, e1; +! linenr_T s2, e2; +! char_u *sp1, *ep1; +! char_u *sp2, *ep2; + + todo = sub1->in_use > sub2->in_use ? sub1->in_use : sub2->in_use; + if (REG_MULTI) +--- 3621,3630 ---- + { + int i; + int todo; +! linenr_T s1; +! linenr_T s2; +! char_u *sp1; +! char_u *sp2; + + todo = sub1->in_use > sub2->in_use ? sub1->in_use : sub2->in_use; + if (REG_MULTI) +*************** +*** 3632,3664 **** + for (i = 0; i < todo; ++i) + { + if (i < sub1->in_use) +- { + s1 = sub1->list.multi[i].start.lnum; +- e1 = sub1->list.multi[i].end.lnum; +- } + else +- { + s1 = 0; +- e1 = 0; +- } + if (i < sub2->in_use) +- { + s2 = sub2->list.multi[i].start.lnum; +- e2 = sub2->list.multi[i].end.lnum; +- } + else +- { + s2 = 0; +! e2 = 0; +! } +! if (s1 != s2 || e1 != e2) + return FALSE; + if (s1 != 0 && sub1->list.multi[i].start.col + != sub2->list.multi[i].start.col) + return FALSE; +- if (e1 != 0 && sub1->list.multi[i].end.col +- != sub2->list.multi[i].end.col) +- return FALSE; + } + } + else +--- 3632,3649 ---- + for (i = 0; i < todo; ++i) + { + if (i < sub1->in_use) + s1 = sub1->list.multi[i].start.lnum; + else + s1 = 0; + if (i < sub2->in_use) + s2 = sub2->list.multi[i].start.lnum; + else + s2 = 0; +! if (s1 != s2) + return FALSE; + if (s1 != 0 && sub1->list.multi[i].start.col + != sub2->list.multi[i].start.col) + return FALSE; + } + } + else +*************** +*** 3666,3691 **** + for (i = 0; i < todo; ++i) + { + if (i < sub1->in_use) +- { + sp1 = sub1->list.line[i].start; +- ep1 = sub1->list.line[i].end; +- } + else +- { + sp1 = NULL; +- ep1 = NULL; +- } + if (i < sub2->in_use) +- { + sp2 = sub2->list.line[i].start; +- ep2 = sub2->list.line[i].end; +- } + else +- { + sp2 = NULL; +! ep2 = NULL; +! } +! if (sp1 != sp2 || ep1 != ep2) + return FALSE; + } + } +--- 3651,3664 ---- + for (i = 0; i < todo; ++i) + { + if (i < sub1->in_use) + sp1 = sub1->list.line[i].start; + else + sp1 = NULL; + if (i < sub2->in_use) + sp2 = sub2->list.line[i].start; + else + sp2 = NULL; +! if (sp1 != sp2) + return FALSE; + } + } +*************** +*** 3735,3742 **** + if (thread->state->id == state->id + && sub_equal(&thread->subs.norm, &subs->norm) + #ifdef FEAT_SYN_HL +! && (!nfa_has_zsubexpr || +! sub_equal(&thread->subs.synt, &subs->synt)) + #endif + ) + return TRUE; +--- 3708,3715 ---- + if (thread->state->id == state->id + && sub_equal(&thread->subs.norm, &subs->norm) + #ifdef FEAT_SYN_HL +! && (!nfa_has_zsubexpr +! || sub_equal(&thread->subs.synt, &subs->synt)) + #endif + ) + return TRUE; +*** ../vim-7.3.1191/src/version.c 2013-06-14 20:31:20.000000000 +0200 +--- src/version.c 2013-06-14 21:14:28.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1192, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +202. You're amazed to find out Spam is a food. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From ce2993c2996fd13fd8742c4de6aeacf5f136870c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:35:52 +0200 Subject: [PATCH 1086/3340] - patchlevel 1193 --- 7.3.1193 | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 7.3.1193 diff --git a/7.3.1193 b/7.3.1193 new file mode 100644 index 00000000..3f730ff3 --- /dev/null +++ b/7.3.1193 @@ -0,0 +1,60 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1193 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1193 +Problem: fail_if_missing not used for Python 3. +Solution: Give an error when Python 3 can't be configured. (Andrei Olsen) +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.1192/src/configure.in 2013-06-11 20:53:24.000000000 +0200 +--- src/configure.in 2013-06-14 21:19:40.000000000 +0200 +*************** +*** 1229,1234 **** +--- 1229,1237 ---- + AC_MSG_RESULT(too old) + fi + fi ++ if test "$fail_if_missing" = "yes" -a "$python3_ok" != "yes"; then ++ AC_MSG_ERROR([could not configure python3]) ++ fi + fi + + AC_SUBST(PYTHON3_CONFDIR) +*** ../vim-7.3.1192/src/auto/configure 2013-06-11 20:53:24.000000000 +0200 +--- src/auto/configure 2013-06-14 21:19:43.000000000 +0200 +*************** +*** 5826,5831 **** +--- 5826,5834 ---- + $as_echo "too old" >&6; } + fi + fi ++ if test "$fail_if_missing" = "yes" -a "$python3_ok" != "yes"; then ++ as_fn_error "could not configure python3" "$LINENO" 5 ++ fi + fi + + +*** ../vim-7.3.1192/src/version.c 2013-06-14 21:15:21.000000000 +0200 +--- src/version.c 2013-06-14 21:20:51.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1193, + /**/ + +-- +$ echo pizza > /dev/oven + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From fee1a86073bfdb847d263ad2fa3f4fe57bc34cd7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:35:53 +0200 Subject: [PATCH 1087/3340] - patchlevel 1194 --- 7.3.1194 | 74 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 7.3.1194 diff --git a/7.3.1194 b/7.3.1194 new file mode 100644 index 00000000..30dda299 --- /dev/null +++ b/7.3.1194 @@ -0,0 +1,74 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1194 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1194 +Problem: Yaml highlighting is slow. +Solution: Tune the estimation of pattern failure chance. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1193/src/regexp_nfa.c 2013-06-14 21:15:21.000000000 +0200 +--- src/regexp_nfa.c 2013-06-14 22:14:17.000000000 +0200 +*************** +*** 4686,4691 **** +--- 4686,4703 ---- + /* empty match works always */ + return 0; + ++ case NFA_START_INVISIBLE: ++ case NFA_START_INVISIBLE_FIRST: ++ case NFA_START_INVISIBLE_NEG: ++ case NFA_START_INVISIBLE_NEG_FIRST: ++ case NFA_START_INVISIBLE_BEFORE: ++ case NFA_START_INVISIBLE_BEFORE_FIRST: ++ case NFA_START_INVISIBLE_BEFORE_NEG: ++ case NFA_START_INVISIBLE_BEFORE_NEG_FIRST: ++ case NFA_START_PATTERN: ++ /* recursive regmatch is expensive, use low failure chance */ ++ return 5; ++ + case NFA_BOL: + case NFA_EOL: + case NFA_BOF: +*************** +*** 5264,5270 **** + skip_lid = nextlist->id; + #endif + } +! else if(state_in_list(thislist, + t->state->out1->out->out, &t->subs)) + { + skip = t->state->out1->out->out; +--- 5276,5282 ---- + skip_lid = nextlist->id; + #endif + } +! else if (state_in_list(thislist, + t->state->out1->out->out, &t->subs)) + { + skip = t->state->out1->out->out; +*** ../vim-7.3.1193/src/version.c 2013-06-14 21:22:33.000000000 +0200 +--- src/version.c 2013-06-14 22:26:49.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1194, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +206. You religiously respond immediately to e-mail, while ignoring + your growing pile of snail mail. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 819eec24f0218130b699a28fe7c5351546092d8f Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:35:54 +0200 Subject: [PATCH 1088/3340] - patchlevel 1195 --- 7.3.1195 | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 7.3.1195 diff --git a/7.3.1195 b/7.3.1195 new file mode 100644 index 00000000..8c29402a --- /dev/null +++ b/7.3.1195 @@ -0,0 +1,53 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1195 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1195 +Problem: Compiler warning for unitialized variable. (Tony Mechelynck) +Solution: Set the length to the matching backref. +Files: src/regexp.c + + +*** ../vim-7.3.1194/src/regexp.c 2013-06-14 20:31:20.000000000 +0200 +--- src/regexp.c 2013-06-14 22:46:22.000000000 +0200 +*************** +*** 5026,5032 **** + reg_startpos[no].col, + reg_endpos[no].lnum, + reg_endpos[no].col, +! NULL); + } + } + } +--- 5026,5032 ---- + reg_startpos[no].col, + reg_endpos[no].lnum, + reg_endpos[no].col, +! &len); + } + } + } +*** ../vim-7.3.1194/src/version.c 2013-06-14 22:33:47.000000000 +0200 +--- src/version.c 2013-06-14 22:42:13.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1195, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +208. Your goals for the future are obtaining an T1 connection and + a 130 gig hard drive. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 227cd3cd75634baf6640878b4a696462f31ed17a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:35:55 +0200 Subject: [PATCH 1089/3340] - patchlevel 1196 --- 7.3.1196 | 267 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 267 insertions(+) create mode 100644 7.3.1196 diff --git a/7.3.1196 b/7.3.1196 new file mode 100644 index 00000000..61bb1484 --- /dev/null +++ b/7.3.1196 @@ -0,0 +1,267 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1196 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1196 +Problem: Old regexp engine does not match pattern with backref correctly. + (Dominique Pelle) +Solution: Fix setting status. Test multi-line patterns better. +Files: src/regexp.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1195/src/regexp.c 2013-06-14 22:48:50.000000000 +0200 +--- src/regexp.c 2013-06-15 14:09:21.000000000 +0200 +*************** +*** 5021,5032 **** + { + /* Messy situation: Need to compare between two + * lines. */ +! status = match_with_backref( + reg_startpos[no].lnum, + reg_startpos[no].col, + reg_endpos[no].lnum, + reg_endpos[no].col, + &len); + } + } + } +--- 5021,5035 ---- + { + /* Messy situation: Need to compare between two + * lines. */ +! int r = match_with_backref( + reg_startpos[no].lnum, + reg_startpos[no].col, + reg_endpos[no].lnum, + reg_endpos[no].col, + &len); ++ ++ if (r != RA_MATCH) ++ status = r; + } + } + } +*** ../vim-7.3.1195/src/testdir/test64.in 2013-06-14 20:31:20.000000000 +0200 +--- src/testdir/test64.in 2013-06-15 15:05:03.000000000 +0200 +*************** +*** 377,382 **** +--- 377,383 ---- + :call add(tl, [2, '\(\i\+\) \1', 'xgoo goox', 'goo goo', 'goo']) + :call add(tl, [2, '\(a\)\(b\)\(c\)\(dd\)\(e\)\(f\)\(g\)\(h\)\(i\)\1\2\3\4\5\6\7\8\9', 'xabcddefghiabcddefghix', 'abcddefghiabcddefghi', 'a', 'b', 'c', 'dd', 'e', 'f', 'g', 'h', 'i']) + :call add(tl, [2, '\(\d*\)a \1b', ' a b ', 'a b', '']) ++ :call add(tl, [2, '^.\(.\).\_..\1.', "aaa\naaa\nb", "aaa\naaa", 'a']) + :" + :"""" Look-behind with limit + :call add(tl, [2, '<\@<=span.', 'xxspanxx +! :" This only works on a buffer line, not with expression evaluation +! /^Find this +! /\%#=0\<\(\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\.\)\{3\}\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\> +! y$Gop:" +! /^Find this +! /\%#=1\<\(\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\.\)\{3\}\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\> +! y$Gop:" +! /^Find this +! /\%#=2\<\(\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\.\)\{3\}\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\> +! y$Gop:" + :" + :" Check that using a pattern on two lines doesn't get messed up by using + :" matchstr() with \ze in between. +--- 454,501 ---- + :endfor + :unlet t tl e l + :" ++ :"""""" multi-line tests ++ :let tl = [] ++ :" ++ :"""" back references ++ :call add(tl, [2, '^.\(.\).\_..\1.', ['aaa', 'aaa', 'b'], ['XX', 'b']]) ++ :call add(tl, [2, '\v.*\/(.*)\n.*\/\1$', ['./Dir1/Dir2/zyxwvuts.txt', './Dir1/Dir2/abcdefgh.bat', '', './Dir1/Dir2/file1.txt', './OtherDir1/OtherDir2/file1.txt'], ['./Dir1/Dir2/zyxwvuts.txt', './Dir1/Dir2/abcdefgh.bat', '', 'XX']]) ++ :" ++ :"""" line breaks ++ :call add(tl, [2, '\S.*\nx', ['abc', 'def', 'ghi', 'xjk', 'lmn'], ['abc', 'def', 'XXjk', 'lmn']]) ++ :" + :" Check that \_[0-9] matching EOL does not break a following \> +! :call add(tl, [2, '\<\(\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\.\)\{3\}\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\>', ['', 'localnet/192.168.0.1', ''], ['', 'localnet/XX', '']]) +! :" +! :" Check a pattern with a line break and ^ and $ +! :call add(tl, [2, 'a\n^b$\n^c', ['a', 'b', 'c'], ['XX']]) +! :" +! :"""" Run the multi-line tests +! :" +! :$put ='multi-line tests' +! :for t in tl +! : let re = t[0] +! : let pat = t[1] +! : let before = t[2] +! : let after = t[3] +! : for engine in [0, 1, 2] +! : if engine == 2 && re == 0 || engine == 1 && re ==1 +! : continue +! : endif +! : let ®expengine = engine +! : new +! : call setline(1, before) +! : exe '%s/' . pat . '/XX/' +! : let result = getline(1, '$') +! : q! +! : if result != after +! : $put ='ERROR: pat: \"' . pat . '\", text: \"' . string(before) . '\", expected: \"' . string(after) . '\", got: \"' . string(result) . '\"' +! : else +! : $put ='OK ' . engine . ' - ' . pat +! : endif +! : endfor +! :endfor +! :unlet t tl + :" + :" Check that using a pattern on two lines doesn't get messed up by using + :" matchstr() with \ze in between. +*************** +*** 474,497 **** + :.+1,.+2yank + Gop:" + :" +- :" Check a pattern with a line break matches in the right position. +- /^Multiline +- /\S.*\nx +- :.yank +- y$Gop:" +- :" +- :" Check a pattern with a line break and ^ and $ +- /^Abc: +- /a\n^b$\n^c/e +- :.yank +- Gop:" +- :" +- :" Check using a backref matching in a previous line +- /^Backref: +- /\v.*\/(.*)\n.*\/\1$ +- :.yank +- Gop:" +- :" + :" Check a pattern with a look beind crossing a line boundary + /^Behind: + /\(<\_[xy]\+\)\@3<=start +--- 506,511 ---- +*************** +*** 553,584 **** + :/\%#=1^Results/,$wq! test.out + ENDTEST + +- Find this: +- localnet/192.168.0.1 +- + Substitute here: + Ta 5 + Ac 7 + +- Multiline: +- abc +- def +- ghi +- xjk +- lmn +- +- Abc: +- a +- b +- c +- +- Backref: +- ./Dir1/Dir2/zyxwvuts.txt +- ./Dir1/Dir2/abcdefgh.bat +- +- ./Dir1/Dir2/file1.txt +- ./OtherDir1/OtherDir2/file1.txt +- + Behind: + asdfasdTa 5 + Ac 7 +- ghi +- +- c +- +- ./Dir1/Dir2/file1.txt + + xxstart3 + +--- 913,937 ---- + OK 0 - [0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12} + OK 1 - [0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12} + OK 2 - [0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12} +! multi-line tests +! OK 0 - ^.\(.\).\_..\1. +! OK 1 - ^.\(.\).\_..\1. +! OK 2 - ^.\(.\).\_..\1. +! OK 0 - \v.*\/(.*)\n.*\/\1$ +! OK 1 - \v.*\/(.*)\n.*\/\1$ +! OK 2 - \v.*\/(.*)\n.*\/\1$ +! OK 0 - \S.*\nx +! OK 1 - \S.*\nx +! OK 2 - \S.*\nx +! OK 0 - \<\(\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\.\)\{3\}\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\> +! OK 1 - \<\(\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\.\)\{3\}\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\> +! OK 2 - \<\(\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\.\)\{3\}\(25\_[0-5]\|2\_[0-4]\_[0-9]\|\_[01]\?\_[0-9]\_[0-9]\?\)\> +! OK 0 - a\n^b$\n^c +! OK 1 - a\n^b$\n^c +! OK 2 - a\n^b$\n^c + + Ta 5 + Ac 7 + + xxstart3 + +*** ../vim-7.3.1195/src/version.c 2013-06-14 22:48:50.000000000 +0200 +--- src/version.c 2013-06-15 14:12:46.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1196, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +213. Your kids start referring to you as "that guy in front of the monitor." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9891cc8fcf17a04f86e26688f53f9585e5054cb9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:35:56 +0200 Subject: [PATCH 1090/3340] - patchlevel 1197 --- 7.3.1197 | 192 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 192 insertions(+) create mode 100644 7.3.1197 diff --git a/7.3.1197 b/7.3.1197 new file mode 100644 index 00000000..00fef808 --- /dev/null +++ b/7.3.1197 @@ -0,0 +1,192 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1197 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1197 +Problem: ":wviminfo!" does not write history previously read from a viminfo + file. (Roland Eggner) +Solution: When not merging history write all entries. +Files: src/ex_cmds.c, src/ex_getln.c, src/proto/ex_getln.pro + + +*** ../vim-7.3.1196/src/ex_cmds.c 2013-06-08 18:19:39.000000000 +0200 +--- src/ex_cmds.c 2013-06-15 16:16:33.000000000 +0200 +*************** +*** 1722,1732 **** + } + + /* +! * write_viminfo() -- Write the viminfo file. The old one is read in first so +! * that effectively a merge of current info and old info is done. This allows +! * multiple vims to run simultaneously, without losing any marks etc. If +! * forceit is TRUE, then the old file is not read in, and only internal info is +! * written to the file. -- webb + */ + void + write_viminfo(file, forceit) +--- 1722,1732 ---- + } + + /* +! * Write the viminfo file. The old one is read in first so that effectively a +! * merge of current info and old info is done. This allows multiple vims to +! * run simultaneously, without losing any marks etc. +! * If "forceit" is TRUE, then the old file is not read in, and only internal +! * info is written to the file. + */ + void + write_viminfo(file, forceit) +*************** +*** 2047,2052 **** +--- 2047,2053 ---- + int count = 0; + int eof = FALSE; + vir_T vir; ++ int merge = FALSE; + + if ((vir.vir_line = alloc(LSIZE)) == NULL) + return; +*************** +*** 2058,2066 **** + if (fp_in != NULL) + { + if (flags & VIF_WANT_INFO) + eof = read_viminfo_up_to_marks(&vir, + flags & VIF_FORCEIT, fp_out != NULL); +! else + /* Skip info, find start of marks */ + while (!(eof = viminfo_readline(&vir)) + && vir.vir_line[0] != '>') +--- 2059,2070 ---- + if (fp_in != NULL) + { + if (flags & VIF_WANT_INFO) ++ { + eof = read_viminfo_up_to_marks(&vir, + flags & VIF_FORCEIT, fp_out != NULL); +! merge = TRUE; +! } +! else if (flags != 0) + /* Skip info, find start of marks */ + while (!(eof = viminfo_readline(&vir)) + && vir.vir_line[0] != '>') +*************** +*** 2079,2085 **** + write_viminfo_search_pattern(fp_out); + write_viminfo_sub_string(fp_out); + #ifdef FEAT_CMDHIST +! write_viminfo_history(fp_out); + #endif + write_viminfo_registers(fp_out); + #ifdef FEAT_EVAL +--- 2083,2089 ---- + write_viminfo_search_pattern(fp_out); + write_viminfo_sub_string(fp_out); + #ifdef FEAT_CMDHIST +! write_viminfo_history(fp_out, merge); + #endif + write_viminfo_registers(fp_out); + #ifdef FEAT_EVAL +*** ../vim-7.3.1196/src/ex_getln.c 2013-06-08 18:19:39.000000000 +0200 +--- src/ex_getln.c 2013-06-15 16:23:57.000000000 +0200 +*************** +*** 6003,6008 **** +--- 6003,6011 ---- + #endif + + #if (defined(FEAT_VIMINFO) && defined(FEAT_CMDHIST)) || defined(PROTO) ++ /* ++ * Buffers for history read from a viminfo file. Only valid while reading. ++ */ + static char_u **viminfo_history[HIST_COUNT] = {NULL, NULL, NULL, NULL}; + static int viminfo_hisidx[HIST_COUNT] = {0, 0, 0, 0}; + static int viminfo_hislen[HIST_COUNT] = {0, 0, 0, 0}; +*************** +*** 6184,6192 **** + } + } + + void +! write_viminfo_history(fp) + FILE *fp; + { + int i; + int type; +--- 6187,6202 ---- + } + } + ++ /* ++ * Write history to viminfo file in "fp". ++ * When "merge" is TRUE merge history lines with a previously read viminfo ++ * file, data is in viminfo_history[]. ++ * When "merge" is FALSE just write all history lines. Used for ":wviminfo!". ++ */ + void +! write_viminfo_history(fp, merge) + FILE *fp; ++ int merge; + { + int i; + int type; +*************** +*** 6236,6242 **** + p = round == 1 ? history[type][i].hisstr + : viminfo_history[type] == NULL ? NULL + : viminfo_history[type][i]; +! if (p != NULL && (round == 2 || !history[type][i].viminfo)) + { + --num_saved; + fputc(hist_type2char(type, TRUE), fp); +--- 6246,6254 ---- + p = round == 1 ? history[type][i].hisstr + : viminfo_history[type] == NULL ? NULL + : viminfo_history[type][i]; +! if (p != NULL && (round == 2 +! || !merge +! || !history[type][i].viminfo)) + { + --num_saved; + fputc(hist_type2char(type, TRUE), fp); +*** ../vim-7.3.1196/src/proto/ex_getln.pro 2013-04-14 23:19:32.000000000 +0200 +--- src/proto/ex_getln.pro 2013-06-15 16:20:46.000000000 +0200 +*************** +*** 51,57 **** + void prepare_viminfo_history __ARGS((int asklen, int writing)); + int read_viminfo_history __ARGS((vir_T *virp, int writing)); + void finish_viminfo_history __ARGS((void)); +! void write_viminfo_history __ARGS((FILE *fp)); + void cmd_pchar __ARGS((int c, int offset)); + int cmd_gchar __ARGS((int offset)); + char_u *script_get __ARGS((exarg_T *eap, char_u *cmd)); +--- 51,57 ---- + void prepare_viminfo_history __ARGS((int asklen, int writing)); + int read_viminfo_history __ARGS((vir_T *virp, int writing)); + void finish_viminfo_history __ARGS((void)); +! void write_viminfo_history __ARGS((FILE *fp, int merge)); + void cmd_pchar __ARGS((int c, int offset)); + int cmd_gchar __ARGS((int offset)); + char_u *script_get __ARGS((exarg_T *eap, char_u *cmd)); +*** ../vim-7.3.1196/src/version.c 2013-06-15 15:09:44.000000000 +0200 +--- src/version.c 2013-06-15 16:13:55.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1197, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +216. Your pet rock leaves home. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1db855955de91e282ad25abf1cc48b3cb5b77d1c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:35:56 +0200 Subject: [PATCH 1091/3340] - patchlevel 1198 --- 7.3.1198 | 91 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 91 insertions(+) create mode 100644 7.3.1198 diff --git a/7.3.1198 b/7.3.1198 new file mode 100644 index 00000000..e2237b2a --- /dev/null +++ b/7.3.1198 @@ -0,0 +1,91 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1198 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1198 +Problem: Build error when using Perl 5.18.0 and dynamic loading. +Solution: Change #ifdefs for Perl_croak_xs_usage. (Ike Devolder) +Files: src/if_perl.xs + + +*** ../vim-7.3.1197/src/if_perl.xs 2013-05-06 04:21:35.000000000 +0200 +--- src/if_perl.xs 2013-06-15 16:42:45.000000000 +0200 +*************** +*** 67,72 **** +--- 67,76 ---- + # define PERL5101_OR_LATER + #endif + ++ #if (PERL_REVISION == 5) && (PERL_VERSION >= 18) ++ # define PERL5180_OR_LATER ++ #endif ++ + #ifndef pTHX + # define pTHX void + # define pTHX_ +*************** +*** 127,135 **** +--- 131,141 ---- + # define perl_free dll_perl_free + # define Perl_get_context dll_Perl_get_context + # define Perl_croak dll_Perl_croak ++ # ifndef PERL5180_OR_LATER + # ifdef PERL5101_OR_LATER + # define Perl_croak_xs_usage dll_Perl_croak_xs_usage + # endif ++ # endif + # ifndef PROTO + # define Perl_croak_nocontext dll_Perl_croak_nocontext + # define Perl_call_argv dll_Perl_call_argv +*************** +*** 242,250 **** +--- 248,258 ---- + static int (*perl_parse)(PerlInterpreter*, XSINIT_t, int, char**, char**); + static void* (*Perl_get_context)(void); + static void (*Perl_croak)(pTHX_ const char*, ...); ++ #ifndef PERL5180_OR_LATER + #ifdef PERL5101_OR_LATER + static void (*Perl_croak_xs_usage)(pTHX_ const CV *const, const char *const params); + #endif ++ #endif + static void (*Perl_croak_nocontext)(const char*, ...); + static I32 (*Perl_dowantarray)(pTHX); + static void (*Perl_free_tmps)(pTHX); +*************** +*** 362,370 **** +--- 370,380 ---- + {"perl_parse", (PERL_PROC*)&perl_parse}, + {"Perl_get_context", (PERL_PROC*)&Perl_get_context}, + {"Perl_croak", (PERL_PROC*)&Perl_croak}, ++ #ifndef PERL5180_OR_LATER + #ifdef PERL5101_OR_LATER + {"Perl_croak_xs_usage", (PERL_PROC*)&Perl_croak_xs_usage}, + #endif ++ #endif + {"Perl_croak_nocontext", (PERL_PROC*)&Perl_croak_nocontext}, + {"Perl_dowantarray", (PERL_PROC*)&Perl_dowantarray}, + {"Perl_free_tmps", (PERL_PROC*)&Perl_free_tmps}, +*** ../vim-7.3.1197/src/version.c 2013-06-15 16:31:41.000000000 +0200 +--- src/version.c 2013-06-15 16:42:08.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1198, + /**/ + +-- +I noticed my daughter's Disney-net password on a sticky note: +"MickeyMinnieGoofyPluto". I asked her why it was so long. +"Because they say it has to have at least four characters." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 181767ddc7f0790222562d1d025a7c472d59f4a3 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:35:57 +0200 Subject: [PATCH 1092/3340] - patchlevel 1199 --- 7.3.1199 | 124 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 124 insertions(+) create mode 100644 7.3.1199 diff --git a/7.3.1199 b/7.3.1199 new file mode 100644 index 00000000..515ec3af --- /dev/null +++ b/7.3.1199 @@ -0,0 +1,124 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1199 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1199 +Problem: When evaluating 'foldexpr' causes an error this is silently + ignored and evaluation is retried every time. +Solution: Set emsg_silent instead of emsg_off. Stop evaluating 'foldexpr' is + it is causing errors. (Christian Brabandt) +Files: src/fold.c + + +*** ../vim-7.3.1198/src/fold.c 2012-08-29 15:22:14.000000000 +0200 +--- src/fold.c 2013-06-15 16:57:24.000000000 +0200 +*************** +*** 1930,1937 **** + char_u *buf; + { + char_u *text = NULL; +- + #ifdef FEAT_EVAL + if (*wp->w_p_fdt != NUL) + { + char_u dashes[MAX_LEVEL + 2]; +--- 1930,1951 ---- + char_u *buf; + { + char_u *text = NULL; + #ifdef FEAT_EVAL ++ /* an error occurred when evaluating 'fdt' setting */ ++ static int got_fdt_error = FALSE; ++ int save_did_emsg = did_emsg; ++ static win_T *last_wp = NULL; ++ static linenr_T last_lnum = 0; ++ ++ if (last_wp != wp || last_wp == NULL ++ || last_lnum > lnum || last_lnum == 0) ++ /* window changed, try evaluating foldtext setting once again */ ++ got_fdt_error = FALSE; ++ ++ if (!got_fdt_error) ++ /* a previous error should not abort evaluating 'foldexpr' */ ++ did_emsg = FALSE; ++ + if (*wp->w_p_fdt != NUL) + { + char_u dashes[MAX_LEVEL + 2]; +*************** +*** 1952,1970 **** + dashes[level] = NUL; + set_vim_var_string(VV_FOLDDASHES, dashes, -1); + set_vim_var_nr(VV_FOLDLEVEL, (long)level); +- save_curwin = curwin; +- curwin = wp; +- curbuf = wp->w_buffer; + +! ++emsg_off; +! text = eval_to_string_safe(wp->w_p_fdt, NULL, + was_set_insecurely((char_u *)"foldtext", OPT_LOCAL)); +! --emsg_off; + +! curwin = save_curwin; +! curbuf = curwin->w_buffer; + set_vim_var_string(VV_FOLDDASHES, NULL, -1); + + if (text != NULL) + { + /* Replace unprintable characters, if there are any. But +--- 1966,1997 ---- + dashes[level] = NUL; + set_vim_var_string(VV_FOLDDASHES, dashes, -1); + set_vim_var_nr(VV_FOLDLEVEL, (long)level); + +! /* skip evaluating foldtext on errors */ +! if (!got_fdt_error) +! { +! save_curwin = curwin; +! curwin = wp; +! curbuf = wp->w_buffer; +! +! ++emsg_silent; /* handle exceptions, but don't display errors */ +! text = eval_to_string_safe(wp->w_p_fdt, NULL, + was_set_insecurely((char_u *)"foldtext", OPT_LOCAL)); +! --emsg_silent; +! +! if (text == NULL || did_emsg) +! got_fdt_error = TRUE; + +! curwin = save_curwin; +! curbuf = curwin->w_buffer; +! } +! last_lnum = lnum; +! last_wp = wp; + set_vim_var_string(VV_FOLDDASHES, NULL, -1); + ++ if (!did_emsg && save_did_emsg) ++ did_emsg = save_did_emsg; ++ + if (text != NULL) + { + /* Replace unprintable characters, if there are any. But +*** ../vim-7.3.1198/src/version.c 2013-06-15 16:47:31.000000000 +0200 +--- src/version.c 2013-06-15 16:53:16.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1199, + /**/ + +-- +'Psychologist' -- Someone who looks at everyone else when +an attractive woman enters the room. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 50665cfa2f399f778b983abb7decfc213aed2c1a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:35:58 +0200 Subject: [PATCH 1093/3340] - patchlevel 1200 --- 7.3.1200 | 101 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 101 insertions(+) create mode 100644 7.3.1200 diff --git a/7.3.1200 b/7.3.1200 new file mode 100644 index 00000000..883b8f36 --- /dev/null +++ b/7.3.1200 @@ -0,0 +1,101 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1200 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1200 +Problem: When calling setline() from Insert mode, using CTRL-R =, undo does + not work properly. (Israel Chauca) +Solution: Sync undo after evaluating the expression. (Christian Brabandt) +Files: src/edit.c, src/testdir/test61.in, src/testdir/test61.ok + + +*** ../vim-7.3.1199/src/edit.c 2013-06-08 18:19:39.000000000 +0200 +--- src/edit.c 2013-06-15 17:31:18.000000000 +0200 +*************** +*** 8126,8135 **** + --no_mapping; + + #ifdef FEAT_EVAL +! /* +! * Don't call u_sync() while getting the expression, +! * evaluating it or giving an error message for it! +! */ + ++no_u_sync; + if (regname == '=') + { +--- 8126,8133 ---- + --no_mapping; + + #ifdef FEAT_EVAL +! /* Don't call u_sync() while typing the expression or giving an error +! * message for it. Only call it explicitly. */ + ++no_u_sync; + if (regname == '=') + { +*************** +*** 8142,8147 **** +--- 8140,8148 ---- + if (im_on) + im_set_active(TRUE); + # endif ++ if (regname == '=') ++ /* sync undo, so the effect of e.g., setline() can be undone */ ++ u_sync(TRUE); + } + if (regname == NUL || !valid_yank_reg(regname, FALSE)) + { +*** ../vim-7.3.1199/src/testdir/test61.in 2010-09-14 12:47:30.000000000 +0200 +--- src/testdir/test61.in 2013-06-15 17:25:53.000000000 +0200 +*************** +*** 84,89 **** +--- 84,99 ---- + ggO---:0put b + ggO---:0put a + ggO---:w >>test.out ++ :so small.vim ++ :set nocp ++ :enew! ++ oa ++ :set ul=100 ++ ob ++ :set ul=100 ++ o1a2=setline('.','1234') ++ ++ uu:%w >>test.out + :qa! + ENDTEST + +*** ../vim-7.3.1199/src/testdir/test61.ok 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test61.ok 2013-06-15 17:25:53.000000000 +0200 +*************** +*** 41,43 **** +--- 41,46 ---- + two + two + three ++ ++ a ++ b +*** ../vim-7.3.1199/src/version.c 2013-06-15 17:06:31.000000000 +0200 +--- src/version.c 2013-06-15 17:39:37.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1200, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +217. Your sex life has drastically improved...so what if it's only cyber-sex! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8b7bd2a28cd3ed2f4f9bbd72ad8e6f846175f533 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:35:59 +0200 Subject: [PATCH 1094/3340] - patchlevel 1201 --- 7.3.1201 | 70 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 7.3.1201 diff --git a/7.3.1201 b/7.3.1201 new file mode 100644 index 00000000..c3ebc5d6 --- /dev/null +++ b/7.3.1201 @@ -0,0 +1,70 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1201 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1201 +Problem: When a startup script creates a preview window, it probably + becomes the current window. +Solution: Make another window the current one. (Christian Brabandt) +Files: src/main.c + + +*** ../vim-7.3.1200/src/main.c 2013-06-12 20:35:46.000000000 +0200 +--- src/main.c 2013-06-15 21:46:31.000000000 +0200 +*************** +*** 2816,2822 **** + # ifdef FEAT_AUTOCMD + --autocmd_no_enter; + # endif +! win_enter(firstwin, FALSE); /* back to first window */ + # ifdef FEAT_AUTOCMD + --autocmd_no_leave; + # endif +--- 2816,2840 ---- + # ifdef FEAT_AUTOCMD + --autocmd_no_enter; + # endif +! #if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX) +! /* +! * Avoid making a preview window the current window. +! */ +! if (firstwin->w_p_pvw) +! { +! win_T *win; +! +! for (win = firstwin; win != NULL; win = win->w_next) +! if (!win->w_p_pvw) +! { +! firstwin = win; +! break; +! } +! } +! #endif +! /* make the first window the current window */ +! win_enter(firstwin, FALSE); +! + # ifdef FEAT_AUTOCMD + --autocmd_no_leave; + # endif +*** ../vim-7.3.1200/src/version.c 2013-06-15 17:54:36.000000000 +0200 +--- src/version.c 2013-06-15 21:48:57.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1201, + /**/ + +-- +How do I set the laser printer to stun? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3aea9f65dda3fe3e7aa772518ea1196b3b879d8e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:00 +0200 Subject: [PATCH 1095/3340] - patchlevel 1202 --- 7.3.1202 | 59 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.1202 diff --git a/7.3.1202 b/7.3.1202 new file mode 100644 index 00000000..16af909d --- /dev/null +++ b/7.3.1202 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1202 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1202 (after 7.3.660) +Problem: Tags are not found in case-folded tags file. (Darren cole, Issue + 90) +Solution: Take into account that when case folding was used for the tags + file "!rm" sorts before the "!_TAG" header lines. +Files: src/tag.c + + +*** ../vim-7.3.1201/src/tag.c 2013-06-08 18:19:40.000000000 +0200 +--- src/tag.c 2013-06-15 22:26:26.000000000 +0200 +*************** +*** 1797,1803 **** + */ + if (state == TS_START) + { +! if (STRNCMP(lbuf, "!_TAG_", 6) == 0) + { + /* + * Read header line. +--- 1797,1808 ---- + */ + if (state == TS_START) + { +! /* The header ends when the line sorts below "!_TAG_". +! * There may be non-header items before the header though, +! * e.g. "!" itself. When case is folded lower case letters +! * sort before "_". */ +! if (STRNCMP(lbuf, "!_TAG_", 6) <= 0 +! || (lbuf[0] == '!' && ASCII_ISLOWER(lbuf[1]))) + { + /* + * Read header line. +*** ../vim-7.3.1201/src/version.c 2013-06-15 21:54:11.000000000 +0200 +--- src/version.c 2013-06-15 22:24:58.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1202, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +220. Your wife asks for sex and you tell her where to find you on IRC. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7023ea5b4765d4f0a6de036ab45e48bc8064b43e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:01 +0200 Subject: [PATCH 1096/3340] - patchlevel 1203 --- 7.3.1203 | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 7.3.1203 diff --git a/7.3.1203 b/7.3.1203 new file mode 100644 index 00000000..9dead07a --- /dev/null +++ b/7.3.1203 @@ -0,0 +1,50 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1203 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1203 +Problem: Matches from matchadd() might be highlighted incorrectly when they + are at a fixed position and inserting lines. (John Szakmeister) +Solution: Redraw all lines below a change if there are highlighted matches. + (idea by Christian Brabandt) +Files: src/screen.c + + +*** ../vim-7.3.1202/src/screen.c 2013-06-08 18:19:40.000000000 +0200 +--- src/screen.c 2013-06-15 22:57:25.000000000 +0200 +*************** +*** 1638,1643 **** +--- 1638,1647 ---- + # endif + syntax_check_changed(lnum))) + #endif ++ #ifdef FEAT_SEARCH_EXTRA ++ /* match in fixed position might need redraw */ ++ || wp->w_match_head != NULL ++ #endif + ))))) + { + #ifdef FEAT_SEARCH_EXTRA +*** ../vim-7.3.1202/src/version.c 2013-06-15 22:26:46.000000000 +0200 +--- src/version.c 2013-06-15 22:59:43.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1203, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +221. Your wife melts your keyboard in the oven. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a904b7264c808768127242fbf24f7ae700e82aba Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:02 +0200 Subject: [PATCH 1097/3340] - patchlevel 1204 --- 7.3.1204 | 289 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 289 insertions(+) create mode 100644 7.3.1204 diff --git a/7.3.1204 b/7.3.1204 new file mode 100644 index 00000000..7d07fae5 --- /dev/null +++ b/7.3.1204 @@ -0,0 +1,289 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1204 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1204 +Problem: Calling gettabwinvar() in 'tabline' cancels Visual mode. (Hirohito + Higashi) +Solution: Don't always use goto_tabpage_tp(). +Files: src/window.c, src/proto/window.pro, src/eval.c, src/if_py_both.h + + +*** ../vim-7.3.1203/src/window.c 2013-06-08 18:19:40.000000000 +0200 +--- src/window.c 2013-06-16 14:08:52.000000000 +0200 +*************** +*** 3774,3780 **** + /* We would like doing the TabEnter event first, but we don't have a + * valid current window yet, which may break some commands. + * This triggers autocommands, thus may make "tp" invalid. */ +! win_enter_ext(tp->tp_curwin, FALSE, TRUE, trigger_enter_autocmds, trigger_leave_autocmds); + prevwin = next_prevwin; + + last_status(FALSE); /* status line may appear or disappear */ +--- 3774,3781 ---- + /* We would like doing the TabEnter event first, but we don't have a + * valid current window yet, which may break some commands. + * This triggers autocommands, thus may make "tp" invalid. */ +! win_enter_ext(tp->tp_curwin, FALSE, TRUE, +! trigger_enter_autocmds, trigger_leave_autocmds); + prevwin = next_prevwin; + + last_status(FALSE); /* status line may appear or disappear */ +*************** +*** 6575,6588 **** + * Set "win" to be the curwin and "tp" to be the current tab page. + * restore_win() MUST be called to undo. + * No autocommands will be executed. + * Returns FAIL if switching to "win" failed. + */ + int +! switch_win(save_curwin, save_curtab, win, tp) + win_T **save_curwin; + tabpage_T **save_curtab; + win_T *win; + tabpage_T *tp; + { + # ifdef FEAT_AUTOCMD + block_autocmds(); +--- 6576,6592 ---- + * Set "win" to be the curwin and "tp" to be the current tab page. + * restore_win() MUST be called to undo. + * No autocommands will be executed. ++ * When "no_display" is TRUE the display won't be affected, no redraw is ++ * triggered, another tabpage access is limited. + * Returns FAIL if switching to "win" failed. + */ + int +! switch_win(save_curwin, save_curtab, win, tp, no_display) + win_T **save_curwin; + tabpage_T **save_curtab; + win_T *win; + tabpage_T *tp; ++ int no_display; + { + # ifdef FEAT_AUTOCMD + block_autocmds(); +*************** +*** 6592,6598 **** + if (tp != NULL) + { + *save_curtab = curtab; +! goto_tabpage_tp(tp, FALSE, FALSE); + } + if (!win_valid(win)) + { +--- 6596,6611 ---- + if (tp != NULL) + { + *save_curtab = curtab; +! if (no_display) +! { +! curtab->tp_firstwin = firstwin; +! curtab->tp_lastwin = lastwin; +! curtab = tp; +! firstwin = curtab->tp_firstwin; +! lastwin = curtab->tp_lastwin; +! } +! else +! goto_tabpage_tp(tp, FALSE, FALSE); + } + if (!win_valid(win)) + { +*************** +*** 6609,6623 **** + + /* + * Restore current tabpage and window saved by switch_win(), if still valid. + */ + void +! restore_win(save_curwin, save_curtab) + win_T *save_curwin; + tabpage_T *save_curtab; + { + # ifdef FEAT_WINDOWS + if (save_curtab != NULL && valid_tabpage(save_curtab)) +! goto_tabpage_tp(save_curtab, FALSE, FALSE); + if (win_valid(save_curwin)) + { + curwin = save_curwin; +--- 6622,6650 ---- + + /* + * Restore current tabpage and window saved by switch_win(), if still valid. ++ * When "no_display" is TRUE the display won't be affected, no redraw is ++ * triggered. + */ + void +! restore_win(save_curwin, save_curtab, no_display) + win_T *save_curwin; + tabpage_T *save_curtab; ++ int no_display; + { + # ifdef FEAT_WINDOWS + if (save_curtab != NULL && valid_tabpage(save_curtab)) +! { +! if (no_display) +! { +! curtab->tp_firstwin = firstwin; +! curtab->tp_lastwin = lastwin; +! curtab = save_curtab; +! firstwin = curtab->tp_firstwin; +! lastwin = curtab->tp_lastwin; +! } +! else +! goto_tabpage_tp(save_curtab, FALSE, FALSE); +! } + if (win_valid(save_curwin)) + { + curwin = save_curwin; +*** ../vim-7.3.1203/src/proto/window.pro 2013-05-17 16:03:53.000000000 +0200 +--- src/proto/window.pro 2013-06-16 13:48:18.000000000 +0200 +*************** +*** 70,77 **** + void check_lnums __ARGS((int do_curwin)); + void make_snapshot __ARGS((int idx)); + void restore_snapshot __ARGS((int idx, int close_curwin)); +! int switch_win __ARGS((win_T **save_curwin, tabpage_T **save_curtab, win_T *win, tabpage_T *tp)); +! void restore_win __ARGS((win_T *save_curwin, tabpage_T *save_curtab)); + void switch_buffer __ARGS((buf_T **save_curbuf, buf_T *buf)); + void restore_buffer __ARGS((buf_T *save_curbuf)); + int win_hasvertsplit __ARGS((void)); +--- 70,77 ---- + void check_lnums __ARGS((int do_curwin)); + void make_snapshot __ARGS((int idx)); + void restore_snapshot __ARGS((int idx, int close_curwin)); +! int switch_win __ARGS((win_T **save_curwin, tabpage_T **save_curtab, win_T *win, tabpage_T *tp, int no_display)); +! void restore_win __ARGS((win_T *save_curwin, tabpage_T *save_curtab, int no_display)); + void switch_buffer __ARGS((buf_T **save_curbuf, buf_T *buf)); + void restore_buffer __ARGS((buf_T *save_curbuf)); + int win_hasvertsplit __ARGS((void)); +*** ../vim-7.3.1203/src/eval.c 2013-06-13 21:24:01.000000000 +0200 +--- src/eval.c 2013-06-16 14:03:15.000000000 +0200 +*************** +*** 11952,11958 **** + { + /* Set curwin to be our win, temporarily. Also set the tabpage, + * otherwise the window is not valid. */ +! switch_win(&oldcurwin, &oldtabpage, win, tp); + + if (*varname == '&') /* window-local-option */ + { +--- 11952,11958 ---- + { + /* Set curwin to be our win, temporarily. Also set the tabpage, + * otherwise the window is not valid. */ +! switch_win(&oldcurwin, &oldtabpage, win, tp, TRUE); + + if (*varname == '&') /* window-local-option */ + { +*************** +*** 11972,11978 **** + } + + /* restore previous notion of curwin */ +! restore_win(oldcurwin, oldtabpage); + } + + if (!done && argvars[off + 2].v_type != VAR_UNKNOWN) +--- 11972,11978 ---- + } + + /* restore previous notion of curwin */ +! restore_win(oldcurwin, oldtabpage, TRUE); + } + + if (!done && argvars[off + 2].v_type != VAR_UNKNOWN) +*************** +*** 16775,16781 **** + if (win != NULL && varname != NULL && varp != NULL) + { + #ifdef FEAT_WINDOWS +! if (switch_win(&save_curwin, &save_curtab, win, tp) == FAIL) + return; + #endif + +--- 16775,16781 ---- + if (win != NULL && varname != NULL && varp != NULL) + { + #ifdef FEAT_WINDOWS +! if (switch_win(&save_curwin, &save_curtab, win, tp, TRUE) == FAIL) + return; + #endif + +*************** +*** 16804,16810 **** + } + + #ifdef FEAT_WINDOWS +! restore_win(save_curwin, save_curtab); + #endif + } + } +--- 16804,16810 ---- + } + + #ifdef FEAT_WINDOWS +! restore_win(save_curwin, save_curtab, TRUE); + #endif + } + } +*** ../vim-7.3.1203/src/if_py_both.h 2013-06-12 18:13:31.000000000 +0200 +--- src/if_py_both.h 2013-06-16 13:54:21.000000000 +0200 +*************** +*** 2706,2712 **** + { + case SREQ_WIN: + if (switch_win(&save_curwin, &save_curtab, (win_T *)from, +! win_find_tabpage((win_T *)from)) == FAIL) + { + if (VimTryEnd()) + return -1; +--- 2702,2708 ---- + { + case SREQ_WIN: + if (switch_win(&save_curwin, &save_curtab, (win_T *)from, +! win_find_tabpage((win_T *)from), FALSE) == FAIL) + { + if (VimTryEnd()) + return -1; +*************** +*** 2714,2720 **** + return -1; + } + r = set_option_value_err(key, numval, stringval, opt_flags); +! restore_win(save_curwin, save_curtab); + if (r == FAIL) + return -1; + break; +--- 2710,2716 ---- + return -1; + } + r = set_option_value_err(key, numval, stringval, opt_flags); +! restore_win(save_curwin, save_curtab, FALSE); + if (r == FAIL) + return -1; + break; +*** ../vim-7.3.1203/src/version.c 2013-06-15 23:00:26.000000000 +0200 +--- src/version.c 2013-06-16 13:44:37.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1204, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +224. You set up your own Web page. You set up a Web page for each + of your kids... and your pets. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 33ad875b6e2401dca84e3ea0d784f504577b2371 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:03 +0200 Subject: [PATCH 1098/3340] - patchlevel 1205 --- 7.3.1205 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.1205 diff --git a/7.3.1205 b/7.3.1205 new file mode 100644 index 00000000..623aa55b --- /dev/null +++ b/7.3.1205 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1205 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1205 +Problem: logtalk.dict is not removed on uninstall. +Solution: Remove the file. (Kazunobu Kuriyama) +Files: src/Makefile + + +*** ../vim-7.3.1204/src/Makefile 2013-05-21 13:30:17.000000000 +0200 +--- src/Makefile 2013-06-16 14:13:15.000000000 +0200 +*************** +*** 2311,2317 **** + -rm -rf $(DEST_COMP) + -rm -f $(DEST_PRINT)/*.ps + -rmdir $(DEST_HELP) $(DEST_PRINT) $(DEST_COL) $(DEST_SYN) $(DEST_IND) +! -rm -rf $(DEST_FTP)/*.vim $(DEST_FTP)/README.txt + -rm -f $(DEST_AUTO)/*.vim $(DEST_AUTO)/README.txt $(DEST_AUTO)/xml/*.vim + -rm -f $(DEST_PLUG)/*.vim $(DEST_PLUG)/README.txt + -rmdir $(DEST_FTP) $(DEST_AUTO)/xml $(DEST_AUTO) $(DEST_PLUG) $(DEST_RT) +--- 2311,2317 ---- + -rm -rf $(DEST_COMP) + -rm -f $(DEST_PRINT)/*.ps + -rmdir $(DEST_HELP) $(DEST_PRINT) $(DEST_COL) $(DEST_SYN) $(DEST_IND) +! -rm -rf $(DEST_FTP)/*.vim $(DEST_FTP)/README.txt $(DEST_FTP)/logtalk.dict + -rm -f $(DEST_AUTO)/*.vim $(DEST_AUTO)/README.txt $(DEST_AUTO)/xml/*.vim + -rm -f $(DEST_PLUG)/*.vim $(DEST_PLUG)/README.txt + -rmdir $(DEST_FTP) $(DEST_AUTO)/xml $(DEST_AUTO) $(DEST_PLUG) $(DEST_RT) +*** ../vim-7.3.1204/src/version.c 2013-06-16 14:18:20.000000000 +0200 +--- src/version.c 2013-06-16 14:19:23.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1205, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +225. You sign up for free subscriptions for all the computer magazines + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 1fa1a78003e5d6f7e7693dc23e23801b938d423a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:04 +0200 Subject: [PATCH 1099/3340] - patchlevel 1206 --- 7.3.1206 | 138 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 138 insertions(+) create mode 100644 7.3.1206 diff --git a/7.3.1206 b/7.3.1206 new file mode 100644 index 00000000..ab40f7d9 --- /dev/null +++ b/7.3.1206 @@ -0,0 +1,138 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1206 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1206 +Problem: Inconsistent function argument declarations. +Solution: Use ANSI style. +Files: src/if_py_both.h + + +*** ../vim-7.3.1205/src/if_py_both.h 2013-06-16 14:18:20.000000000 +0200 +--- src/if_py_both.h 2013-06-16 14:24:51.000000000 +0200 +*************** +*** 1278,1284 **** + } + + static dict_T * +! py_dict_alloc() + { + dict_T *r; + +--- 1278,1284 ---- + } + + static dict_T * +! py_dict_alloc(void) + { + dict_T *r; + +*************** +*** 1545,1551 **** + } + + static PyInt +! DictionaryAssItem(DictionaryObject *self, PyObject *keyObject, PyObject *valObject) + { + char_u *key; + typval_T tv; +--- 1545,1552 ---- + } + + static PyInt +! DictionaryAssItem( +! DictionaryObject *self, PyObject *keyObject, PyObject *valObject) + { + char_u *key; + typval_T tv; +*************** +*** 2669,2679 **** + } + + static int +! set_option_value_err(key, numval, stringval, opt_flags) +! char_u *key; +! int numval; +! char_u *stringval; +! int opt_flags; + { + char_u *errmsg; + +--- 2670,2676 ---- + } + + static int +! set_option_value_err(char_u *key, int numval, char_u *stringval, int opt_flags) + { + char_u *errmsg; + +*************** +*** 2688,2700 **** + } + + static int +! set_option_value_for(key, numval, stringval, opt_flags, opt_type, from) +! char_u *key; +! int numval; +! char_u *stringval; +! int opt_flags; +! int opt_type; +! void *from; + { + win_T *save_curwin = NULL; + tabpage_T *save_curtab = NULL; +--- 2685,2697 ---- + } + + static int +! set_option_value_for( +! char_u *key, +! int numval, +! char_u *stringval, +! int opt_flags, +! int opt_type, +! void *from) + { + win_T *save_curwin = NULL; + tabpage_T *save_curtab = NULL; +*************** +*** 5619,5625 **** + } + + static int +! init_sys_path() + { + PyObject *path; + PyObject *path_hook; +--- 5616,5622 ---- + } + + static int +! init_sys_path(void) + { + PyObject *path; + PyObject *path_hook; +*** ../vim-7.3.1205/src/version.c 2013-06-16 14:20:10.000000000 +0200 +--- src/version.c 2013-06-16 14:25:11.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1206, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +226. You sit down at the computer right after dinner and your spouse + says "See you in the morning." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a565d0c3b792e7bceb42faff48d3b2d848128934 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:04 +0200 Subject: [PATCH 1100/3340] - patchlevel 1207 --- 7.3.1207 | 74 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 7.3.1207 diff --git a/7.3.1207 b/7.3.1207 new file mode 100644 index 00000000..ad8757c0 --- /dev/null +++ b/7.3.1207 @@ -0,0 +1,74 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1207 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1207 +Problem: New regexp engine: no match found on "#if FOO". (Lech Lorens) +Solution: When adding a state gets skipped don't adjust the index. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1206/src/regexp_nfa.c 2013-06-14 22:33:47.000000000 +0200 +--- src/regexp_nfa.c 2013-06-16 15:38:15.000000000 +0200 +*************** +*** 4210,4215 **** +--- 4210,4217 ---- + + /* re-order to put the new state at the current position */ + count = l->n - tlen; ++ if (count == 0) ++ return; /* no state got added */ + if (count == 1) + { + /* overwrite the current state */ +*** ../vim-7.3.1206/src/testdir/test64.in 2013-06-15 15:09:44.000000000 +0200 +--- src/testdir/test64.in 2013-06-16 15:38:04.000000000 +0200 +*************** +*** 408,413 **** +--- 408,415 ---- + :"""" Requiring lots of states. + :call add(tl, [2, '[0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12}', " 12345678-1234-1234-1234-123456789012 ", "12345678-1234-1234-1234-123456789012", "1234-"]) + :" ++ :"""" Skip adding state twice ++ :call add(tl, [2, '^\%(\%(^\s*#\s*if\>\|#\s*if\)\)\(\%>1c.*$\)\@=', "#if FOO", "#if", ' FOO']) + :" + :"""" Run the tests + :" +*** ../vim-7.3.1206/src/testdir/test64.ok 2013-06-15 15:09:44.000000000 +0200 +--- src/testdir/test64.ok 2013-06-16 15:38:22.000000000 +0200 +*************** +*** 913,918 **** +--- 913,921 ---- + OK 0 - [0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12} + OK 1 - [0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12} + OK 2 - [0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12} ++ OK 0 - ^\%(\%(^\s*#\s*if\>\|#\s*if\)\)\(\%>1c.*$\)\@= ++ OK 1 - ^\%(\%(^\s*#\s*if\>\|#\s*if\)\)\(\%>1c.*$\)\@= ++ OK 2 - ^\%(\%(^\s*#\s*if\>\|#\s*if\)\)\(\%>1c.*$\)\@= + multi-line tests + OK 0 - ^.\(.\).\_..\1. + OK 1 - ^.\(.\).\_..\1. +*** ../vim-7.3.1206/src/version.c 2013-06-16 14:25:53.000000000 +0200 +--- src/version.c 2013-06-16 15:42:05.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1207, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +228. You spend Saturday night making the counter on your home page + pass that 2000 mark. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 21b16a522e64cabd4d477818e19a5f15c804e5ac Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:05 +0200 Subject: [PATCH 1101/3340] - patchlevel 1208 --- 7.3.1208 | 74 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 7.3.1208 diff --git a/7.3.1208 b/7.3.1208 new file mode 100644 index 00000000..0e351893 --- /dev/null +++ b/7.3.1208 @@ -0,0 +1,74 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1208 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1208 +Problem: Compiler warnings on MS-Windows. +Solution: Add type cast. Move variable declaration. (Mike Williams) +Files: src/option.c, src/os_mswin.c + + +*** ../vim-7.3.1207/src/option.c 2013-06-08 18:19:40.000000000 +0200 +--- src/option.c 2013-06-16 15:59:00.000000000 +0200 +*************** +*** 3181,3187 **** + if (opt_idx >= 0) + { + #if !defined(HAVE_AVAIL_MEM) && !defined(HAVE_TOTAL_MEM) +! if ((long)options[opt_idx].def_val[VI_DEFAULT] > n + || (long)options[opt_idx].def_val[VI_DEFAULT] == 0L) + #endif + options[opt_idx].def_val[VI_DEFAULT] = (char_u *)n; +--- 3181,3187 ---- + if (opt_idx >= 0) + { + #if !defined(HAVE_AVAIL_MEM) && !defined(HAVE_TOTAL_MEM) +! if ((long)options[opt_idx].def_val[VI_DEFAULT] > (long)n + || (long)options[opt_idx].def_val[VI_DEFAULT] == 0L) + #endif + options[opt_idx].def_val[VI_DEFAULT] = (char_u *)n; +*** ../vim-7.3.1207/src/os_mswin.c 2013-05-06 04:21:35.000000000 +0200 +--- src/os_mswin.c 2013-06-16 15:59:41.000000000 +0200 +*************** +*** 1897,1903 **** + HWND sender = (HWND)wParam; + COPYDATASTRUCT reply; + char_u *res; +- char_u winstr[30]; + int retval; + char_u *str; + char_u *tofree; +--- 1897,1902 ---- +*************** +*** 1970,1975 **** +--- 1969,1976 ---- + #ifdef FEAT_AUTOCMD + else if (data->dwData == COPYDATA_REPLY) + { ++ char_u winstr[30]; ++ + sprintf((char *)winstr, PRINTF_HEX_LONG_U, (long_u)sender); + apply_autocmds(EVENT_REMOTEREPLY, winstr, str, + TRUE, curbuf); +*** ../vim-7.3.1207/src/version.c 2013-06-16 15:43:43.000000000 +0200 +--- src/version.c 2013-06-16 15:57:31.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1208, + /**/ + +-- +Get a life? What is the URL where it can be downloaded? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 062a71634054332314e7dffd21a5ab4e223d67ce Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:06 +0200 Subject: [PATCH 1102/3340] - patchlevel 1209 --- 7.3.1209 | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 7.3.1209 diff --git a/7.3.1209 b/7.3.1209 new file mode 100644 index 00000000..fe4dd5be --- /dev/null +++ b/7.3.1209 @@ -0,0 +1,45 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1209 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1209 +Problem: No completion for ":tabdo". +Solution: Add tabdo to the list of modifiers. (Dominique Pelle) +Files: src/ex_docmd.c + + +*** ../vim-7.3.1208/src/ex_docmd.c 2013-06-14 19:15:52.000000000 +0200 +--- src/ex_docmd.c 2013-06-16 16:11:32.000000000 +0200 +*************** +*** 3603,3608 **** +--- 3603,3609 ---- + case CMD_sandbox: + case CMD_silent: + case CMD_tab: ++ case CMD_tabdo: + case CMD_topleft: + case CMD_verbose: + case CMD_vertical: +*** ../vim-7.3.1208/src/version.c 2013-06-16 16:01:20.000000000 +0200 +--- src/version.c 2013-06-16 16:12:14.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1209, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +232. You start conversations with, "Have you gotten an ISDN line?" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 8622e0c76d56c716c724513c341ac705a91665d5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:07 +0200 Subject: [PATCH 1103/3340] - patchlevel 1210 --- 7.3.1210 | 69 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.1210 diff --git a/7.3.1210 b/7.3.1210 new file mode 100644 index 00000000..33492efd --- /dev/null +++ b/7.3.1210 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1210 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1210 (after 7.3.1182) +Problem: 'backupcopy' default on MS-Windows is wrong when 'encoding' equals + the current codepage. +Solution: Change the #else block. (Ken Takata) +Files: src/os_win32.c + + +*** ../vim-7.3.1209/src/os_win32.c 2013-06-12 22:41:30.000000000 +0200 +--- src/os_win32.c 2013-06-16 16:29:34.000000000 +0200 +*************** +*** 2789,2802 **** + reparseTag = findDataW.dwReserved0; + } + } +! #else +! hFind = FindFirstFile(fname, &findDataA); +! if (hFind != INVALID_HANDLE_VALUE) + { +! fileFlags = findDataA.dwFileAttributes; +! reparseTag = findDataA.dwReserved0; + } +- #endif + + if (hFind != INVALID_HANDLE_VALUE) + FindClose(hFind); +--- 2789,2804 ---- + reparseTag = findDataW.dwReserved0; + } + } +! else +! #endif + { +! hFind = FindFirstFile(fname, &findDataA); +! if (hFind != INVALID_HANDLE_VALUE) +! { +! fileFlags = findDataA.dwFileAttributes; +! reparseTag = findDataA.dwReserved0; +! } + } + + if (hFind != INVALID_HANDLE_VALUE) + FindClose(hFind); +*** ../vim-7.3.1209/src/version.c 2013-06-16 16:13:59.000000000 +0200 +--- src/version.c 2013-06-16 16:31:14.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1210, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +233. You start dreaming about web pages...in html. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b937bf16ed825ee4a81ea800f1955e1ec9b73558 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:08 +0200 Subject: [PATCH 1104/3340] - patchlevel 1211 --- 7.3.1211 | 235 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 235 insertions(+) create mode 100644 7.3.1211 diff --git a/7.3.1211 b/7.3.1211 new file mode 100644 index 00000000..9a8dc88e --- /dev/null +++ b/7.3.1211 @@ -0,0 +1,235 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1211 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1211 +Problem: MS-Windows: When 'encoding' differs from the current codepage + ":hardcopy" does not work properly. +Solution: Use TextOutW() and SetDlgItemTextW(). (Ken Takata) +Files: src/os_mswin.c, src/vim.rc + + +*** ../vim-7.3.1210/src/os_mswin.c 2013-06-16 16:01:20.000000000 +0200 +--- src/os_mswin.c 2013-06-16 16:41:11.000000000 +0200 +*************** +*** 1045,1050 **** +--- 1045,1073 ---- + #define IDC_PRINTTEXT2 402 + #define IDC_PROGRESS 403 + ++ #if !defined(FEAT_MBYTE) || defined(WIN16) ++ # define vimSetDlgItemText(h, i, s) SetDlgItemText(h, i, s) ++ #else ++ static BOOL ++ vimSetDlgItemText(HWND hDlg, int nIDDlgItem, char_u *s) ++ { ++ WCHAR *wp = NULL; ++ BOOL ret; ++ ++ if (enc_codepage >= 0 && (int)GetACP() != enc_codepage) ++ { ++ wp = enc_to_utf16(s, NULL); ++ } ++ if (wp != NULL) ++ { ++ ret = SetDlgItemTextW(hDlg, nIDDlgItem, wp); ++ vim_free(wp); ++ return ret; ++ } ++ return SetDlgItemText(hDlg, nIDDlgItem, s); ++ } ++ #endif ++ + /* + * Convert BGR to RGB for Windows GDI calls + */ +*************** +*** 1096,1113 **** + { + SendDlgItemMessage(hDlg, i, WM_SETFONT, (WPARAM)hfont, 1); + if (GetDlgItemText(hDlg,i, buff, sizeof(buff))) +! SetDlgItemText(hDlg,i, _(buff)); + } + SendDlgItemMessage(hDlg, IDCANCEL, + WM_SETFONT, (WPARAM)hfont, 1); + if (GetDlgItemText(hDlg,IDCANCEL, buff, sizeof(buff))) +! SetDlgItemText(hDlg,IDCANCEL, _(buff)); + } + #endif + SetWindowText(hDlg, szAppName); + if (prt_name != NULL) + { +! SetDlgItemText(hDlg, IDC_PRINTTEXT2, (LPSTR)prt_name); + vim_free(prt_name); + prt_name = NULL; + } +--- 1119,1136 ---- + { + SendDlgItemMessage(hDlg, i, WM_SETFONT, (WPARAM)hfont, 1); + if (GetDlgItemText(hDlg,i, buff, sizeof(buff))) +! vimSetDlgItemText(hDlg,i, _(buff)); + } + SendDlgItemMessage(hDlg, IDCANCEL, + WM_SETFONT, (WPARAM)hfont, 1); + if (GetDlgItemText(hDlg,IDCANCEL, buff, sizeof(buff))) +! vimSetDlgItemText(hDlg,IDCANCEL, _(buff)); + } + #endif + SetWindowText(hDlg, szAppName); + if (prt_name != NULL) + { +! vimSetDlgItemText(hDlg, IDC_PRINTTEXT2, (LPSTR)prt_name); + vim_free(prt_name); + prt_name = NULL; + } +*************** +*** 1565,1571 **** + SetAbortProc(prt_dlg.hDC, AbortProc); + #endif + wsprintf(szBuffer, _("Printing '%s'"), gettail(psettings->jobname)); +! SetDlgItemText(hDlgPrint, IDC_PRINTTEXT1, (LPSTR)szBuffer); + + vim_memset(&di, 0, sizeof(DOCINFO)); + di.cbSize = sizeof(DOCINFO); +--- 1588,1594 ---- + SetAbortProc(prt_dlg.hDC, AbortProc); + #endif + wsprintf(szBuffer, _("Printing '%s'"), gettail(psettings->jobname)); +! vimSetDlgItemText(hDlgPrint, IDC_PRINTTEXT1, (LPSTR)szBuffer); + + vim_memset(&di, 0, sizeof(DOCINFO)); + di.cbSize = sizeof(DOCINFO); +*************** +*** 1599,1605 **** + mch_print_begin_page(char_u *msg) + { + if (msg != NULL) +! SetDlgItemText(hDlgPrint, IDC_PROGRESS, (LPSTR)msg); + return (StartPage(prt_dlg.hDC) > 0); + } + +--- 1622,1628 ---- + mch_print_begin_page(char_u *msg) + { + if (msg != NULL) +! vimSetDlgItemText(hDlgPrint, IDC_PROGRESS, (LPSTR)msg); + return (StartPage(prt_dlg.hDC) > 0); + } + +*************** +*** 1628,1637 **** + int + mch_print_text_out(char_u *p, int len) + { +! #ifdef FEAT_PROPORTIONAL_FONTS + SIZE sz; + #endif + + TextOut(prt_dlg.hDC, prt_pos_x + prt_left_margin, + prt_pos_y + prt_top_margin, p, len); + #ifndef FEAT_PROPORTIONAL_FONTS +--- 1651,1691 ---- + int + mch_print_text_out(char_u *p, int len) + { +! #if defined(FEAT_PROPORTIONAL_FONTS) || (defined(FEAT_MBYTE) && !defined(WIN16)) + SIZE sz; + #endif ++ #if defined(FEAT_MBYTE) && !defined(WIN16) ++ WCHAR *wp = NULL; ++ int wlen = len; + ++ if (enc_codepage >= 0 && (int)GetACP() != enc_codepage) ++ { ++ wp = enc_to_utf16(p, &wlen); ++ } ++ if (wp != NULL) ++ { ++ int ret = FALSE; ++ ++ TextOutW(prt_dlg.hDC, prt_pos_x + prt_left_margin, ++ prt_pos_y + prt_top_margin, wp, wlen); ++ GetTextExtentPoint32W(prt_dlg.hDC, wp, wlen, &sz); ++ vim_free(wp); ++ prt_pos_x += (sz.cx - prt_tm.tmOverhang); ++ /* This is wrong when printing spaces for a TAB. */ ++ if (p[len] != NUL) ++ { ++ wlen = MB_PTR2LEN(p + len); ++ wp = enc_to_utf16(p + len, &wlen); ++ if (wp != NULL) ++ { ++ GetTextExtentPoint32W(prt_dlg.hDC, wp, 1, &sz); ++ ret = (prt_pos_x + prt_left_margin + sz.cx > prt_right_margin); ++ vim_free(wp); ++ } ++ } ++ return ret; ++ } ++ #endif + TextOut(prt_dlg.hDC, prt_pos_x + prt_left_margin, + prt_pos_y + prt_top_margin, p, len); + #ifndef FEAT_PROPORTIONAL_FONTS +*************** +*** 1947,1954 **** + reply.cbData = (DWORD)STRLEN(res) + 1; + + serverSendEnc(sender); +! retval = (int)SendMessage(sender, WM_COPYDATA, (WPARAM)message_window, +! (LPARAM)(&reply)); + vim_free(res); + return retval; + +--- 2001,2008 ---- + reply.cbData = (DWORD)STRLEN(res) + 1; + + serverSendEnc(sender); +! retval = (int)SendMessage(sender, WM_COPYDATA, +! (WPARAM)message_window, (LPARAM)(&reply)); + vim_free(res); + return retval; + +*** ../vim-7.3.1210/src/vim.rc 2010-08-15 21:57:30.000000000 +0200 +--- src/vim.rc 2013-06-16 16:37:33.000000000 +0200 +*************** +*** 116,123 **** + FONT 8, "Helv" + BEGIN + DEFPUSHBUTTON "Cancel", IDCANCEL, 85, 60, 40, 14 +! CTEXT "Printing",IDC_PRINTTEXT1,23,15,157,8 +! CTEXT " ",IDC_PRINTTEXT2,23,25,157,8 +! CTEXT "Initializing...",IDC_PROGRESS,24,38,157,8 + GROUPBOX "",IDC_BOX1,19,9,170,47 + END +--- 116,123 ---- + FONT 8, "Helv" + BEGIN + DEFPUSHBUTTON "Cancel", IDCANCEL, 85, 60, 40, 14 +! CTEXT "Printing",IDC_PRINTTEXT1,23,15,157,9 +! CTEXT " ",IDC_PRINTTEXT2,23,25,157,9 +! CTEXT "Initializing...",IDC_PROGRESS,24,38,157,9 + GROUPBOX "",IDC_BOX1,19,9,170,47 + END +*** ../vim-7.3.1210/src/version.c 2013-06-16 16:34:53.000000000 +0200 +--- src/version.c 2013-06-16 16:39:19.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1211, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +235. You start naming your kids Pascal, COBOL, Algol and Fortran. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 92f4317f72095be047df96ea3f24e8837832cb2c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:09 +0200 Subject: [PATCH 1105/3340] - patchlevel 1212 --- 7.3.1212 | 122 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 122 insertions(+) create mode 100644 7.3.1212 diff --git a/7.3.1212 b/7.3.1212 new file mode 100644 index 00000000..1417b5cd --- /dev/null +++ b/7.3.1212 @@ -0,0 +1,122 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1212 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1212 +Problem: "make test" on MS-Windows does not report failure like Unix does. +Solution: Make it work like on Unix. (Taro Muraoka) +Files: src/testdir/Make_dos.mak + + +*** ../vim-7.3.1211/src/testdir/Make_dos.mak 2013-06-09 17:52:42.000000000 +0200 +--- src/testdir/Make_dos.mak 2013-06-16 16:52:22.000000000 +0200 +*************** +*** 40,62 **** + + .SUFFIXES: .in .out + +! nongui: fixff $(SCRIPTS16) $(SCRIPTS) +! echo ALL DONE + +! small: +! echo ALL DONE + +! gui: fixff $(SCRIPTS16) $(SCRIPTS) $(SCRIPTS_GUI) +! echo ALL DONE + +! win32: fixff $(SCRIPTS16) $(SCRIPTS) $(SCRIPTS32) +! echo ALL DONE + + fixff: + -$(VIMPROG) -u dos.vim --noplugin "+argdo set ff=dos|upd" +q *.in *.ok + -$(VIMPROG) -u dos.vim --noplugin "+argdo set ff=unix|upd" +q \ + dotest.in test60.ok test71.ok test74.ok + + clean: + -del *.out + -if exist test.ok del test.ok +--- 40,64 ---- + + .SUFFIXES: .in .out + +! nongui: fixff $(SCRIPTS16) $(SCRIPTS) report + +! small: report + +! gui: fixff $(SCRIPTS16) $(SCRIPTS) $(SCRIPTS_GUI) report + +! win32: fixff $(SCRIPTS16) $(SCRIPTS) $(SCRIPTS32) report + + fixff: + -$(VIMPROG) -u dos.vim --noplugin "+argdo set ff=dos|upd" +q *.in *.ok + -$(VIMPROG) -u dos.vim --noplugin "+argdo set ff=unix|upd" +q \ + dotest.in test60.ok test71.ok test74.ok + ++ report: ++ @echo "" ++ @echo Test results: ++ @IF EXIST test.log ( type test.log & echo TEST FAILURE & exit /b 1 ) \ ++ ELSE ( ECHO ALL DONE ) ++ + clean: + -del *.out + -if exist test.ok del test.ok +*************** +*** 67,81 **** + -if exist lua.vim del lua.vim + -del X* + -if exist viminfo del viminfo + + .in.out: + copy $*.ok test.ok + $(VIMPROG) -u dos.vim -U NONE --noplugin -s dotest.in $*.in +! diff test.out $*.ok +! -if exist $*.out del $*.out +! rename test.out $*.out + -del X* + -del X*.* + -del test.ok + -rd /s /q Xfind + -if exist viminfo del viminfo +--- 69,86 ---- + -if exist lua.vim del lua.vim + -del X* + -if exist viminfo del viminfo ++ -del test.log + + .in.out: + copy $*.ok test.ok + $(VIMPROG) -u dos.vim -U NONE --noplugin -s dotest.in $*.in +! @diff test.out $*.ok & if errorlevel 1 (echo $* FAILED >> test.log ) \ +! else ( del /F $*.out & rename test.out $*.out ) + -del X* + -del X*.* + -del test.ok + -rd /s /q Xfind + -if exist viminfo del viminfo ++ ++ nolog: ++ -del test.log +*** ../vim-7.3.1211/src/version.c 2013-06-16 16:41:42.000000000 +0200 +--- src/version.c 2013-06-16 16:54:02.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1212, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +236. You start saving URL's in your digital watch. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 31d045c188703297a619fe1c923601b2d4c6b1d7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:10 +0200 Subject: [PATCH 1106/3340] - patchlevel 1213 --- 7.3.1213 | 287 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 287 insertions(+) create mode 100644 7.3.1213 diff --git a/7.3.1213 b/7.3.1213 new file mode 100644 index 00000000..fc498722 --- /dev/null +++ b/7.3.1213 @@ -0,0 +1,287 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1213 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1213 +Problem: Can't build with small features and Python. +Solution: Adjust #ifdefs. +Files: src/eval.c, src/buffer.c, src/window.c + + +*** ../vim-7.3.1212/src/eval.c 2013-06-16 14:18:20.000000000 +0200 +--- src/eval.c 2013-06-16 17:24:32.000000000 +0200 +*************** +*** 112,118 **** +--- 112,120 ---- + static char *e_letwrong = N_("E734: Wrong variable type for %s="); + static char *e_nofunc = N_("E130: Unknown function: %s"); + static char *e_illvar = N_("E461: Illegal variable name: %s"); ++ #ifdef FEAT_FLOAT + static char *e_float_as_string = N_("E806: using Float as a String"); ++ #endif + + static dictitem_T globvars_var; /* variable used for g: */ + #define globvarht globvardict.dv_hashtab +*************** +*** 11882,11888 **** + static win_T * + find_win_by_nr(vp, tp) + typval_T *vp; +! tabpage_T *tp; /* NULL for current tab page */ + { + #ifdef FEAT_WINDOWS + win_T *wp; +--- 11884,11890 ---- + static win_T * + find_win_by_nr(vp, tp) + typval_T *vp; +! tabpage_T *tp UNUSED; /* NULL for current tab page */ + { + #ifdef FEAT_WINDOWS + win_T *wp; +*************** +*** 11932,11938 **** + win_T *win, *oldcurwin; + char_u *varname; + dictitem_T *v; +! tabpage_T *tp, *oldtabpage; + int done = FALSE; + + #ifdef FEAT_WINDOWS +--- 11934,11941 ---- + win_T *win, *oldcurwin; + char_u *varname; + dictitem_T *v; +! tabpage_T *tp = NULL; +! tabpage_T *oldtabpage; + int done = FALSE; + + #ifdef FEAT_WINDOWS +*************** +*** 16683,16706 **** + typval_T *argvars; + typval_T *rettv; + { + tabpage_T *save_curtab; + char_u *varname, *tabvarname; + typval_T *varp; +- tabpage_T *tp; + + rettv->vval.v_number = 0; + + if (check_restricted() || check_secure()) + return; + + tp = find_tabpage((int)get_tv_number_chk(&argvars[0], NULL)); + varname = get_tv_string_chk(&argvars[1]); + varp = &argvars[2]; + +! if (tp != NULL && varname != NULL && varp != NULL) + { + save_curtab = curtab; + goto_tabpage_tp(tp, FALSE, FALSE); + + tabvarname = alloc((unsigned)STRLEN(varname) + 3); + if (tabvarname != NULL) +--- 16686,16719 ---- + typval_T *argvars; + typval_T *rettv; + { ++ #ifdef FEAT_WINDOWS + tabpage_T *save_curtab; ++ tabpage_T *tp; ++ #endif + char_u *varname, *tabvarname; + typval_T *varp; + + rettv->vval.v_number = 0; + + if (check_restricted() || check_secure()) + return; + ++ #ifdef FEAT_WINDOWS + tp = find_tabpage((int)get_tv_number_chk(&argvars[0], NULL)); ++ #endif + varname = get_tv_string_chk(&argvars[1]); + varp = &argvars[2]; + +! if (varname != NULL && varp != NULL +! #ifdef FEAT_WINDOWS +! && tp != NULL +! #endif +! ) + { ++ #ifdef FEAT_WINDOWS + save_curtab = curtab; + goto_tabpage_tp(tp, FALSE, FALSE); ++ #endif + + tabvarname = alloc((unsigned)STRLEN(varname) + 3); + if (tabvarname != NULL) +*************** +*** 16711,16719 **** +--- 16724,16734 ---- + vim_free(tabvarname); + } + ++ #ifdef FEAT_WINDOWS + /* Restore current tabpage */ + if (valid_tabpage(save_curtab)) + goto_tabpage_tp(save_curtab, FALSE, FALSE); ++ #endif + } + } + +*************** +*** 16757,16763 **** + char_u *varname, *winvarname; + typval_T *varp; + char_u nbuf[NUMBUFLEN]; +! tabpage_T *tp; + + if (check_restricted() || check_secure()) + return; +--- 16772,16778 ---- + char_u *varname, *winvarname; + typval_T *varp; + char_u nbuf[NUMBUFLEN]; +! tabpage_T *tp = NULL; + + if (check_restricted() || check_secure()) + return; +*** ../vim-7.3.1212/src/buffer.c 2013-06-08 18:19:39.000000000 +0200 +--- src/buffer.c 2013-06-16 17:14:14.000000000 +0200 +*************** +*** 984,989 **** +--- 984,993 ---- + + return errormsg; + } ++ #endif /* FEAT_LISTCMDS */ ++ ++ #if defined(FEAT_LISTCMDS) || defined(FEAT_PYTHON) \ ++ || defined(FEAT_PYTHON3) || defined(PROTO) + + /* + * Implementation of the commands for the buffer list. +*************** +*** 1364,1371 **** + + return OK; + } +! +! #endif /* FEAT_LISTCMDS */ + + /* + * Set current buffer to "buf". Executes autocommands and closes current +--- 1368,1374 ---- + + return OK; + } +! #endif + + /* + * Set current buffer to "buf". Executes autocommands and closes current +*** ../vim-7.3.1212/src/window.c 2013-06-16 14:18:20.000000000 +0200 +--- src/window.c 2013-06-16 17:25:11.000000000 +0200 +*************** +*** 6582,6592 **** + */ + int + switch_win(save_curwin, save_curtab, win, tp, no_display) +! win_T **save_curwin; +! tabpage_T **save_curtab; +! win_T *win; +! tabpage_T *tp; +! int no_display; + { + # ifdef FEAT_AUTOCMD + block_autocmds(); +--- 6582,6592 ---- + */ + int + switch_win(save_curwin, save_curtab, win, tp, no_display) +! win_T **save_curwin UNUSED; +! tabpage_T **save_curtab UNUSED; +! win_T *win UNUSED; +! tabpage_T *tp UNUSED; +! int no_display UNUSED; + { + # ifdef FEAT_AUTOCMD + block_autocmds(); +*************** +*** 6627,6635 **** + */ + void + restore_win(save_curwin, save_curtab, no_display) +! win_T *save_curwin; +! tabpage_T *save_curtab; +! int no_display; + { + # ifdef FEAT_WINDOWS + if (save_curtab != NULL && valid_tabpage(save_curtab)) +--- 6627,6635 ---- + */ + void + restore_win(save_curwin, save_curtab, no_display) +! win_T *save_curwin UNUSED; +! tabpage_T *save_curtab UNUSED; +! int no_display UNUSED; + { + # ifdef FEAT_WINDOWS + if (save_curtab != NULL && valid_tabpage(save_curtab)) +*************** +*** 6906,6914 **** + } + + int +! get_tab_number(tabpage_T *tp) + { + int i = 1; + tabpage_T *t; + + for (t = first_tabpage; t != NULL && t != tp; t = t->tp_next) +--- 6906,6915 ---- + } + + int +! get_tab_number(tabpage_T *tp UNUSED) + { + int i = 1; ++ # ifdef FEAT_WINDOWS + tabpage_T *t; + + for (t = first_tabpage; t != NULL && t != tp; t = t->tp_next) +*************** +*** 6917,6922 **** +--- 6918,6924 ---- + if (t == NULL) + return 0; + else ++ # endif + return i; + } + #endif +*** ../vim-7.3.1212/src/version.c 2013-06-16 16:57:43.000000000 +0200 +--- src/version.c 2013-06-16 17:30:40.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1213, + /**/ + +-- +You can tune a file system, but you can't tuna fish + -- man tunefs + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 29404f60a4a55c45088595f3b68a874b42879c2e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:11 +0200 Subject: [PATCH 1107/3340] - patchlevel 1214 --- 7.3.1214 | 76 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 7.3.1214 diff --git a/7.3.1214 b/7.3.1214 new file mode 100644 index 00000000..c70443b8 --- /dev/null +++ b/7.3.1214 @@ -0,0 +1,76 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1214 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1214 +Problem: Missing declaration for init_users() and realloc_post_list(). + (Salman Halim) +Solution: Add the declarations. +Files: src/misc1.c, src/regexp_nfa.c + + +*** ../vim-7.3.1213/src/misc1.c 2013-06-08 18:19:40.000000000 +0200 +--- src/misc1.c 2013-06-16 22:46:01.000000000 +0200 +*************** +*** 16,21 **** +--- 16,22 ---- + + static char_u *vim_version_dir __ARGS((char_u *vimdir)); + static char_u *remove_tail __ARGS((char_u *p, char_u *pend, char_u *name)); ++ static void init_users __ARGS((void)); + static int copy_indent __ARGS((int size, char_u *src)); + + /* All user names (for ~user completion as done by shell). */ +*************** +*** 4487,4493 **** + * Done only once and then cached. + */ + static void +! init_users() { + static int lazy_init_done = FALSE; + + if (lazy_init_done) +--- 4488,4495 ---- + * Done only once and then cached. + */ + static void +! init_users() +! { + static int lazy_init_done = FALSE; + + if (lazy_init_done) +*** ../vim-7.3.1213/src/regexp_nfa.c 2013-06-16 15:43:43.000000000 +0200 +--- src/regexp_nfa.c 2013-06-16 22:46:35.000000000 +0200 +*************** +*** 273,278 **** +--- 273,279 ---- + static int nfa_get_reganch __ARGS((nfa_state_T *start, int depth)); + static int nfa_get_regstart __ARGS((nfa_state_T *start, int depth)); + static char_u *nfa_get_match_text __ARGS((nfa_state_T *start)); ++ static int realloc_post_list __ARGS((void)); + static int nfa_recognize_char_class __ARGS((char_u *start, char_u *end, int extra_newl)); + static int nfa_emit_equi_class __ARGS((int c)); + static int nfa_regatom __ARGS((void)); +*** ../vim-7.3.1213/src/version.c 2013-06-16 17:32:33.000000000 +0200 +--- src/version.c 2013-06-16 22:45:31.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1214, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +239. You think "surfing" is something you do on dry land. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a5cd6f72e4d26e5b34e3fbaa421655e2f2567b4d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:12 +0200 Subject: [PATCH 1108/3340] - patchlevel 1215 --- 7.3.1215 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 7.3.1215 diff --git a/7.3.1215 b/7.3.1215 new file mode 100644 index 00000000..3cd3df13 --- /dev/null +++ b/7.3.1215 @@ -0,0 +1,48 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1215 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1215 +Problem: Compiler warning for function not defined. +Solution: Add #ifdef. +Files: src/misc1.c + + +*** ../vim-7.3.1214/src/misc1.c 2013-06-16 22:49:09.000000000 +0200 +--- src/misc1.c 2013-06-17 19:19:27.000000000 +0200 +*************** +*** 16,22 **** +--- 16,24 ---- + + static char_u *vim_version_dir __ARGS((char_u *vimdir)); + static char_u *remove_tail __ARGS((char_u *p, char_u *pend, char_u *name)); ++ #if defined(FEAT_CMDL_COMPL) + static void init_users __ARGS((void)); ++ #endif + static int copy_indent __ARGS((int size, char_u *src)); + + /* All user names (for ~user completion as done by shell). */ +*** ../vim-7.3.1214/src/version.c 2013-06-16 22:49:09.000000000 +0200 +--- src/version.c 2013-06-17 19:20:16.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1215, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +242. You turn down a better-paying job because it doesn't come with + a free e-mail account. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 18efeec5422fe957ddd58cb388381134fa312c67 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:12 +0200 Subject: [PATCH 1109/3340] - patchlevel 1216 --- 7.3.1216 | 119 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 119 insertions(+) create mode 100644 7.3.1216 diff --git a/7.3.1216 b/7.3.1216 new file mode 100644 index 00000000..91eda39e --- /dev/null +++ b/7.3.1216 @@ -0,0 +1,119 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1216 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1216 +Problem: Configure can't find Motif on Ubuntu. +Solution: Search for libXm in /usr/lib/*-linux-gnu. +Files: src/configure.in, src/auto/configure + + +*** ../vim-7.3.1215/src/configure.in 2013-06-14 21:22:33.000000000 +0200 +--- src/configure.in 2013-06-17 20:15:13.000000000 +0200 +*************** +*** 2277,2284 **** + dnl Remove "-L" from before $GUI_LIB_LOC if it's there + GUI_LIB_LOC="`echo $GUI_LIB_LOC|sed 's%-L%%g'`" + + AC_MSG_CHECKING(for location of Motif GUI libs) +! gui_libs="`echo $x_libraries|sed 's%/[^/][^/]*$%%'` `echo "$gui_XXX" | sed s/XXX/lib/g` `echo "$GUI_INC_LOC" | sed s/include/lib/` $GUI_LIB_LOC" + GUI_LIB_LOC= + for try in $gui_libs; do + for libtry in "$try"/libXm.a "$try"/libXm.so* "$try"/libXm.sl "$try"/libXm.dylib; do +--- 2277,2286 ---- + dnl Remove "-L" from before $GUI_LIB_LOC if it's there + GUI_LIB_LOC="`echo $GUI_LIB_LOC|sed 's%-L%%g'`" + ++ dnl Ubuntu has libXm.so in /usr/lib/i386-linux-gnu and elsewhere. The ++ dnl linker will figure out which one to use, we only check if one exists. + AC_MSG_CHECKING(for location of Motif GUI libs) +! gui_libs="`echo $x_libraries|sed 's%/[^/][^/]*$%%'` `echo "$gui_XXX" | sed s/XXX/lib/g` /usr/lib/i386-linux-gnu /usr/lib/x86_64-linux-gnu `echo "$GUI_INC_LOC" | sed s/include/lib/` $GUI_LIB_LOC" + GUI_LIB_LOC= + for try in $gui_libs; do + for libtry in "$try"/libXm.a "$try"/libXm.so* "$try"/libXm.sl "$try"/libXm.dylib; do +*************** +*** 2289,2295 **** + done + if test -n "$GUI_LIB_LOC"; then + dnl Remove /usr/lib, it causes trouble on some systems +! if test "$GUI_LIB_LOC" = /usr/lib; then + GUI_LIB_LOC= + AC_MSG_RESULT(in default path) + else +--- 2291,2299 ---- + done + if test -n "$GUI_LIB_LOC"; then + dnl Remove /usr/lib, it causes trouble on some systems +! if test "$GUI_LIB_LOC" = /usr/lib \ +! -o "$GUI_LIB_LOC" = /usr/lib/i386-linux-gnu \ +! -o "$GUI_LIB_LOC" = /usr/lib/x86_64-linux-gnu; then + GUI_LIB_LOC= + AC_MSG_RESULT(in default path) + else +*** ../vim-7.3.1215/src/auto/configure 2013-06-14 21:22:33.000000000 +0200 +--- src/auto/configure 2013-06-17 20:15:17.000000000 +0200 +*************** +*** 8346,8354 **** + + GUI_LIB_LOC="`echo $GUI_LIB_LOC|sed 's%-L%%g'`" + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking for location of Motif GUI libs" >&5 + $as_echo_n "checking for location of Motif GUI libs... " >&6; } +! gui_libs="`echo $x_libraries|sed 's%/^/^/*$%%'` `echo "$gui_XXX" | sed s/XXX/lib/g` `echo "$GUI_INC_LOC" | sed s/include/lib/` $GUI_LIB_LOC" + GUI_LIB_LOC= + for try in $gui_libs; do + for libtry in "$try"/libXm.a "$try"/libXm.so* "$try"/libXm.sl "$try"/libXm.dylib; do +--- 8346,8354 ---- + + GUI_LIB_LOC="`echo $GUI_LIB_LOC|sed 's%-L%%g'`" + +! { $as_echo "$as_me:${as_lineno-$LINENO}: checking for location of Motif GUI libs" >&5 + $as_echo_n "checking for location of Motif GUI libs... " >&6; } +! gui_libs="`echo $x_libraries|sed 's%/^/^/*$%%'` `echo "$gui_XXX" | sed s/XXX/lib/g` /usr/lib/i386-linux-gnu /usr/lib/x86_64-linux-gnu `echo "$GUI_INC_LOC" | sed s/include/lib/` $GUI_LIB_LOC" + GUI_LIB_LOC= + for try in $gui_libs; do + for libtry in "$try"/libXm.a "$try"/libXm.so* "$try"/libXm.sl "$try"/libXm.dylib; do +*************** +*** 8358,8364 **** + done + done + if test -n "$GUI_LIB_LOC"; then +! if test "$GUI_LIB_LOC" = /usr/lib; then + GUI_LIB_LOC= + { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default path" >&5 + $as_echo "in default path" >&6; } +--- 8358,8366 ---- + done + done + if test -n "$GUI_LIB_LOC"; then +! if test "$GUI_LIB_LOC" = /usr/lib \ +! -o "$GUI_LIB_LOC" = /usr/lib/i386-linux-gnu \ +! -o "$GUI_LIB_LOC" = /usr/lib/x86_64-linux-gnu; then + GUI_LIB_LOC= + { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default path" >&5 + $as_echo "in default path" >&6; } +*** ../vim-7.3.1215/src/version.c 2013-06-17 19:26:29.000000000 +0200 +--- src/version.c 2013-06-17 20:06:50.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1216, + /**/ + +-- +Married is a three ring circus: +First comes the engagement ring. +Then comes the wedding ring. +Then comes the suffering. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d9a6c535273618e845eba56aef878e32c55f3016 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:13 +0200 Subject: [PATCH 1110/3340] - patchlevel 1217 --- 7.3.1217 | 93 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 93 insertions(+) create mode 100644 7.3.1217 diff --git a/7.3.1217 b/7.3.1217 new file mode 100644 index 00000000..089af79c --- /dev/null +++ b/7.3.1217 @@ -0,0 +1,93 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1217 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1217 +Problem: New regexp engine: Can't handle \%[[ao]]. (Yukihiro Nakadaira) +Solution: Support nested atoms inside \%[]. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1216/src/regexp_nfa.c 2013-06-16 22:49:09.000000000 +0200 +--- src/regexp_nfa.c 2013-06-17 21:27:03.000000000 +0200 +*************** +*** 1150,1162 **** + int n; + + /* \%[abc] */ +! for (n = 0; (c = getchr()) != ']'; ++n) + { + if (c == NUL) + EMSG2_RET_FAIL(_(e_missing_sb), + reg_magic == MAGIC_ALL); +! EMIT(c); + } + if (n == 0) + EMSG2_RET_FAIL(_(e_empty_sb), + reg_magic == MAGIC_ALL); +--- 1150,1165 ---- + int n; + + /* \%[abc] */ +! for (n = 0; (c = peekchr()) != ']'; ++n) + { + if (c == NUL) + EMSG2_RET_FAIL(_(e_missing_sb), + reg_magic == MAGIC_ALL); +! /* recursive call! */ +! if (nfa_regatom() == FAIL) +! return FAIL; + } ++ getchr(); /* get the ] */ + if (n == 0) + EMSG2_RET_FAIL(_(e_empty_sb), + reg_magic == MAGIC_ALL); +*** ../vim-7.3.1216/src/testdir/test64.in 2013-06-16 15:43:43.000000000 +0200 +--- src/testdir/test64.in 2013-06-17 21:21:35.000000000 +0200 +*************** +*** 366,371 **** +--- 366,372 ---- + :call add(tl, [2, '\%[bar]x', 'barxx', 'barx']) + :call add(tl, [2, '\%[bar]x', 'bxx', 'bx']) + :call add(tl, [2, '\%[bar]x', 'xxx', 'x']) ++ :call add(tl, [2, 'b\%[[ao]r]', 'bar bor', 'bar']) + :" + :"""" Alternatives, must use first longest match + :call add(tl, [2, 'goo\|go', 'google', 'goo']) +*** ../vim-7.3.1216/src/testdir/test64.ok 2013-06-16 15:43:43.000000000 +0200 +--- src/testdir/test64.ok 2013-06-17 21:27:09.000000000 +0200 +*************** +*** 836,841 **** +--- 836,844 ---- + OK 0 - \%[bar]x + OK 1 - \%[bar]x + OK 2 - \%[bar]x ++ OK 0 - b\%[[ao]r] ++ OK 1 - b\%[[ao]r] ++ OK 2 - b\%[[ao]r] + OK 0 - goo\|go + OK 1 - goo\|go + OK 2 - goo\|go +*** ../vim-7.3.1216/src/version.c 2013-06-17 20:27:13.000000000 +0200 +--- src/version.c 2013-06-17 21:20:10.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1217, + /**/ + + +-- +Marriage isn't a word. It's a sentence. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 342b1257d09e652ceacd09a9a44976efbcb54f7a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:14 +0200 Subject: [PATCH 1111/3340] - patchlevel 1218 --- 7.3.1218 | 91 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 91 insertions(+) create mode 100644 7.3.1218 diff --git a/7.3.1218 b/7.3.1218 new file mode 100644 index 00000000..96293618 --- /dev/null +++ b/7.3.1218 @@ -0,0 +1,91 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1218 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1218 +Problem: "make test" on MS-Windows does not clean all temporary files and + gives some unneccessary message. +Solution: Clean the right files. Create .failed files. (Ken Takata) +Files: src/testdir/Make_dos.mak + + +*** ../vim-7.3.1217/src/testdir/Make_dos.mak 2013-06-16 16:57:43.000000000 +0200 +--- src/testdir/Make_dos.mak 2013-06-17 21:49:44.000000000 +0200 +*************** +*** 61,66 **** +--- 61,67 ---- + + clean: + -del *.out ++ -del *.failed + -if exist test.ok del test.ok + -if exist small.vim del small.vim + -if exist tiny.vim del tiny.vim +*************** +*** 68,85 **** + -if exist mzscheme.vim del mzscheme.vim + -if exist lua.vim del lua.vim + -del X* + -if exist viminfo del viminfo + -del test.log + + .in.out: + copy $*.ok test.ok + $(VIMPROG) -u dos.vim -U NONE --noplugin -s dotest.in $*.in +! @diff test.out $*.ok & if errorlevel 1 (echo $* FAILED >> test.log ) \ +! else ( del /F $*.out & rename test.out $*.out ) + -del X* +- -del X*.* + -del test.ok +! -rd /s /q Xfind + -if exist viminfo del viminfo + + nolog: +--- 69,90 ---- + -if exist mzscheme.vim del mzscheme.vim + -if exist lua.vim del lua.vim + -del X* ++ -if exist Xdir1 rd /s /q Xdir1 ++ -if exist Xfind rd /s /q Xfind + -if exist viminfo del viminfo + -del test.log + + .in.out: ++ -if exist $*.failed del $*.failed + copy $*.ok test.ok + $(VIMPROG) -u dos.vim -U NONE --noplugin -s dotest.in $*.in +! @diff test.out $*.ok & if errorlevel 1 \ +! ( move /y test.out $*.failed & echo $* FAILED >> test.log ) \ +! else ( move /y test.out $*.out ) + -del X* + -del test.ok +! -if exist Xdir1 rd /s /q Xdir1 +! -if exist Xfind rd /s /q Xfind + -if exist viminfo del viminfo + + nolog: +*** ../vim-7.3.1217/src/version.c 2013-06-17 21:33:36.000000000 +0200 +--- src/version.c 2013-06-17 21:52:02.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1218, + /**/ + +-- +"After a few years of marriage a man can look right at a woman +without seeing her and a woman can see right through a man +without looking at him." + - Helen Rowland + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From e14784531155f4ead40674c482d7c72c0241e762 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:15 +0200 Subject: [PATCH 1112/3340] - patchlevel 1219 --- 7.3.1219 | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 7.3.1219 diff --git a/7.3.1219 b/7.3.1219 new file mode 100644 index 00000000..ed654cb6 --- /dev/null +++ b/7.3.1219 @@ -0,0 +1,58 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1219 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1219 +Problem: No test for using []] inside \%[]. +Solution: Add a test. +Files: src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1218/src/testdir/test64.in 2013-06-17 21:33:36.000000000 +0200 +--- src/testdir/test64.in 2013-06-17 21:59:47.000000000 +0200 +*************** +*** 367,372 **** +--- 367,373 ---- + :call add(tl, [2, '\%[bar]x', 'bxx', 'bx']) + :call add(tl, [2, '\%[bar]x', 'xxx', 'x']) + :call add(tl, [2, 'b\%[[ao]r]', 'bar bor', 'bar']) ++ :call add(tl, [2, 'b\%[[]]r]', 'b]r bor', 'b]r']) + :" + :"""" Alternatives, must use first longest match + :call add(tl, [2, 'goo\|go', 'google', 'goo']) +*** ../vim-7.3.1218/src/testdir/test64.ok 2013-06-17 21:33:36.000000000 +0200 +--- src/testdir/test64.ok 2013-06-17 21:59:51.000000000 +0200 +*************** +*** 839,844 **** +--- 839,847 ---- + OK 0 - b\%[[ao]r] + OK 1 - b\%[[ao]r] + OK 2 - b\%[[ao]r] ++ OK 0 - b\%[[]]r] ++ OK 1 - b\%[[]]r] ++ OK 2 - b\%[[]]r] + OK 0 - goo\|go + OK 1 - goo\|go + OK 2 - goo\|go +*** ../vim-7.3.1218/src/version.c 2013-06-17 21:53:33.000000000 +0200 +--- src/version.c 2013-06-17 22:03:18.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1219, + /**/ + +-- +If you're sending someone Styrofoam, what do you pack it in? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6710e6dd08a36dc8d7e1b1d14eed58039b18c49d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:16 +0200 Subject: [PATCH 1113/3340] - patchlevel 1220 --- 7.3.1220 | 211 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 211 insertions(+) create mode 100644 7.3.1220 diff --git a/7.3.1220 b/7.3.1220 new file mode 100644 index 00000000..e1d8c818 --- /dev/null +++ b/7.3.1220 @@ -0,0 +1,211 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1220 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1220 +Problem: MS-Windows: When using wide font italic and bold are not included. +Solution: Support wide-bold, wide-italic and wide-bold-italic. (Ken Takata, + Taro Muraoka) +Files: src/gui.c, src/gui.h, src/gui_w48.c + + +*** ../vim-7.3.1219/src/gui.c 2013-06-12 20:35:46.000000000 +0200 +--- src/gui.c 2013-06-17 22:22:49.000000000 +0200 +*************** +*** 410,415 **** +--- 410,423 ---- + gui.fontset = NOFONTSET; + # endif + #endif ++ #ifdef FEAT_MBYTE ++ gui.wide_font = NOFONT; ++ # ifndef FEAT_GUI_GTK ++ gui.wide_bold_font = NOFONT; ++ gui.wide_ital_font = NOFONT; ++ gui.wide_boldital_font = NOFONT; ++ # endif ++ #endif + + #ifdef FEAT_MENU + # ifndef FEAT_GUI_GTK +*************** +*** 1012,1017 **** +--- 1020,1030 ---- + gui.wide_font = font; + # ifdef FEAT_GUI_MSWIN + gui_mch_wide_font_changed(); ++ # else ++ /* ++ * TODO: setup wide_bold_font, wide_ital_font and wide_boldital_font to ++ * support those fonts for 'guifontwide'. ++ */ + # endif + return OK; + } +*************** +*** 2180,2185 **** +--- 2193,2201 ---- + guicolor_T sp_color; + #if !defined(MSWIN16_FASTTEXT) && !defined(FEAT_GUI_GTK) + GuiFont font = NOFONT; ++ # ifdef FEAT_MBYTE ++ GuiFont wide_font = NOFONT; ++ # endif + # ifdef FEAT_XFONTSET + GuiFontset fontset = NOFONTSET; + # endif +*************** +*** 2269,2274 **** +--- 2285,2307 ---- + } + else + font = gui.norm_font; ++ ++ # ifdef FEAT_MBYTE ++ /* ++ * Choose correct wide_font by font. wide_font should be set with font ++ * at same time in above block. But it will make many "ifdef" nasty ++ * blocks. So we do it here. ++ */ ++ if (font == gui.boldital_font && gui.wide_boldital_font) ++ wide_font = gui.wide_boldital_font; ++ else if (font == gui.bold_font && gui.wide_bold_font) ++ wide_font = gui.wide_bold_font; ++ else if (font == gui.ital_font && gui.wide_ital_font) ++ wide_font = gui.wide_ital_font; ++ else if (font == gui.norm_font && gui.wide_font) ++ wide_font = gui.wide_font; ++ # endif ++ + } + # ifdef FEAT_XFONTSET + if (fontset != NOFONTSET) +*************** +*** 2407,2413 **** + # ifdef FEAT_XFONTSET + && fontset == NOFONTSET + # endif +! && gui.wide_font != NOFONT) + curr_wide = TRUE; + else + curr_wide = FALSE; +--- 2440,2446 ---- + # ifdef FEAT_XFONTSET + && fontset == NOFONTSET + # endif +! && wide_font != NOFONT) + curr_wide = TRUE; + else + curr_wide = FALSE; +*************** +*** 2441,2447 **** + if (thislen > 0) + { + if (prev_wide) +! gui_mch_set_font(gui.wide_font); + gui_mch_draw_string(gui.row, scol, s + start, thislen, + draw_flags); + if (prev_wide) +--- 2474,2480 ---- + if (thislen > 0) + { + if (prev_wide) +! gui_mch_set_font(wide_font); + gui_mch_draw_string(gui.row, scol, s + start, thislen, + draw_flags); + if (prev_wide) +*** ../vim-7.3.1219/src/gui.h 2013-01-23 13:40:54.000000000 +0100 +--- src/gui.h 2013-06-17 22:22:49.000000000 +0200 +*************** +*** 311,317 **** + # endif + #endif + #ifdef FEAT_MBYTE +! GuiFont wide_font; /* 'guifontwide' font */ + #endif + #ifdef FEAT_XFONTSET + GuiFontset fontset; /* set of fonts for multi-byte chars */ +--- 311,322 ---- + # endif + #endif + #ifdef FEAT_MBYTE +! GuiFont wide_font; /* Normal 'guifontwide' font */ +! # ifndef FEAT_GUI_GTK +! GuiFont wide_bold_font; /* Bold 'guifontwide' font */ +! GuiFont wide_ital_font; /* Italic 'guifontwide' font */ +! GuiFont wide_boldital_font; /* Bold-Italic 'guifontwide' font */ +! # endif + #endif + #ifdef FEAT_XFONTSET + GuiFontset fontset; /* set of fonts for multi-byte chars */ +*** ../vim-7.3.1219/src/gui_w48.c 2013-05-06 04:21:35.000000000 +0200 +--- src/gui_w48.c 2013-06-17 22:22:49.000000000 +0200 +*************** +*** 3123,3131 **** +--- 3123,3165 ---- + void + gui_mch_wide_font_changed() + { ++ # ifndef MSWIN16_FASTTEXT ++ LOGFONT lf; ++ # endif ++ + # ifdef FEAT_MBYTE_IME + update_im_font(); + # endif ++ ++ # ifndef MSWIN16_FASTTEXT ++ gui_mch_free_font(gui.wide_ital_font); ++ gui.wide_ital_font = NOFONT; ++ gui_mch_free_font(gui.wide_bold_font); ++ gui.wide_bold_font = NOFONT; ++ gui_mch_free_font(gui.wide_boldital_font); ++ gui.wide_boldital_font = NOFONT; ++ ++ if (gui.wide_font ++ && GetObject((HFONT)gui.wide_font, sizeof(lf), &lf)) ++ { ++ if (!lf.lfItalic) ++ { ++ lf.lfItalic = TRUE; ++ gui.wide_ital_font = get_font_handle(&lf); ++ lf.lfItalic = FALSE; ++ } ++ if (lf.lfWeight < FW_BOLD) ++ { ++ lf.lfWeight = FW_BOLD; ++ gui.wide_bold_font = get_font_handle(&lf); ++ if (!lf.lfItalic) ++ { ++ lf.lfItalic = TRUE; ++ gui.wide_boldital_font = get_font_handle(&lf); ++ } ++ } ++ } ++ # endif + } + #endif + +*** ../vim-7.3.1219/src/version.c 2013-06-17 22:04:34.000000000 +0200 +--- src/version.c 2013-06-17 22:24:18.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1220, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +243. You unsuccessfully try to download a pizza from www.dominos.com. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 62cc40df385a1c35d1431e82d10f882ac9ec8fbc Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:17 +0200 Subject: [PATCH 1114/3340] - patchlevel 1221 --- 7.3.1221 | 220 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 220 insertions(+) create mode 100644 7.3.1221 diff --git a/7.3.1221 b/7.3.1221 new file mode 100644 index 00000000..2af249a9 --- /dev/null +++ b/7.3.1221 @@ -0,0 +1,220 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1221 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1221 +Problem: When build flags change "make distclean" run into a configure + error. +Solution: When CFLAGS changes delete auto/config.cache. Also avoid adding + duplicate text to flags. +Files: src/Makefile, src/configure.in, src/auto/configure + + +*** ../vim-7.3.1220/src/Makefile 2013-06-16 14:20:10.000000000 +0200 +--- src/Makefile 2013-06-18 23:04:56.000000000 +0200 +*************** +*** 1655,1660 **** +--- 1656,1666 ---- + # sure configure is run when it's needed. + # + config auto/config.mk: auto/configure config.mk.in config.h.in ++ if test -f auto/config.cache && \ ++ grep '^ac_cv_env_CFLAGS_value=' auto/config.cache > /dev/null && \ ++ ! grep -x -F 'ac_cv_env_CFLAGS_value=$(CFLAGS)' auto/config.cache > /dev/null; then \ ++ rm auto/config.cache; \ ++ fi + GUI_INC_LOC="$(GUI_INC_LOC)" GUI_LIB_LOC="$(GUI_LIB_LOC)" \ + CC="$(CC)" CPPFLAGS="$(CPPFLAGS)" CFLAGS="$(CFLAGS)" \ + LDFLAGS="$(LDFLAGS)" $(CONF_SHELL) srcdir="$(srcdir)" \ +*** ../vim-7.3.1220/src/configure.in 2013-06-17 20:27:13.000000000 +0200 +--- src/configure.in 2013-06-18 23:04:56.000000000 +0200 +*************** +*** 776,781 **** +--- 776,782 ---- + ldflags_save=$LDFLAGS + CFLAGS="$CFLAGS $perlcppflags" + LIBS="$LIBS $perllibs" ++ perlldflags=`echo "$perlldflags" | sed -e 's/^ *//g'` + LDFLAGS="$perlldflags $LDFLAGS" + AC_TRY_LINK(,[ ], + AC_MSG_RESULT(yes); perl_ok=yes, +*************** +*** 789,795 **** + PERL_CFLAGS=`echo "$perlcppflags" | sed -e 's/-pipe //' -e 's/-W[[^ ]]*//'` + fi + if test "X$perlldflags" != "X"; then +! LDFLAGS="$perlldflags $LDFLAGS" + fi + PERL_LIBS=$perllibs + PERL_SRC="auto/if_perl.c if_perlsfio.c" +--- 790,798 ---- + PERL_CFLAGS=`echo "$perlcppflags" | sed -e 's/-pipe //' -e 's/-W[[^ ]]*//'` + fi + if test "X$perlldflags" != "X"; then +! if test "X`echo \"$LDFLAGS\" | grep -F -e \"$perlldflags\"`" = "X"; then +! LDFLAGS="$perlldflags $LDFLAGS" +! fi + fi + PERL_LIBS=$perllibs + PERL_SRC="auto/if_perl.c if_perlsfio.c" +*************** +*** 1546,1552 **** + dnl configure, so strip these flags first (if present) + rubyldflags=`echo "$rubyldflags" | sed -e 's/-arch\ ppc//' -e 's/-arch\ i386//' -e 's/-arch\ x86_64//'` + if test "X$rubyldflags" != "X"; then +! LDFLAGS="$rubyldflags $LDFLAGS" + fi + fi + RUBY_SRC="if_ruby.c" +--- 1549,1557 ---- + dnl configure, so strip these flags first (if present) + rubyldflags=`echo "$rubyldflags" | sed -e 's/-arch\ ppc//' -e 's/-arch\ i386//' -e 's/-arch\ x86_64//'` + if test "X$rubyldflags" != "X"; then +! if test "X`echo \"$LDFLAGS\" | grep -F -e \"$rubyldflags\"`" = "X"; then +! LDFLAGS="$rubyldflags $LDFLAGS" +! fi + fi + fi + RUBY_SRC="if_ruby.c" +*************** +*** 3719,3725 **** + dnl And undefine it first to avoid a warning. + AC_MSG_CHECKING(whether we need -D_FORTIFY_SOURCE=1) + if test "$gccmajor" -gt "3"; then +! CFLAGS=`echo "$CFLAGS" | sed -e 's/-Wp,-D_FORTIFY_SOURCE=.//g' -e 's/-D_FORTIFY_SOURCE=.//g' -e 's/$/ -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1/'` + AC_MSG_RESULT(yes) + else + AC_MSG_RESULT(no) +--- 3724,3730 ---- + dnl And undefine it first to avoid a warning. + AC_MSG_CHECKING(whether we need -D_FORTIFY_SOURCE=1) + if test "$gccmajor" -gt "3"; then +! CFLAGS=`echo "$CFLAGS" | sed -e 's/ *-Wp,-D_FORTIFY_SOURCE=.//g' -e 's/ *-D_FORTIFY_SOURCE=.//g' -e 's/ *-U_FORTIFY_SOURCE//g' -e 's/$/ -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1/'` + AC_MSG_RESULT(yes) + else + AC_MSG_RESULT(no) +*************** +*** 3734,3740 **** + LINK_AS_NEEDED= + # Check if linker supports --as-needed and --no-as-needed options + if $CC -Wl,--help 2>/dev/null | grep as-needed > /dev/null; then +! LDFLAGS="$LDFLAGS -Wl,--as-needed" + LINK_AS_NEEDED=yes + fi + if test "$LINK_AS_NEEDED" = yes; then +--- 3739,3745 ---- + LINK_AS_NEEDED= + # Check if linker supports --as-needed and --no-as-needed options + if $CC -Wl,--help 2>/dev/null | grep as-needed > /dev/null; then +! LDFLAGS=`echo "$LDFLAGS" | sed -e 's/ *-Wl,--as-needed//g' | sed -e 's/$/ -Wl,--as-needed/'` + LINK_AS_NEEDED=yes + fi + if test "$LINK_AS_NEEDED" = yes; then +*** ../vim-7.3.1220/src/auto/configure 2013-06-17 20:27:13.000000000 +0200 +--- src/auto/configure 2013-06-18 23:27:35.000000000 +0200 +*************** +*** 5133,5138 **** +--- 5133,5139 ---- + ldflags_save=$LDFLAGS + CFLAGS="$CFLAGS $perlcppflags" + LIBS="$LIBS $perllibs" ++ perlldflags=`echo "$perlldflags" | sed -e 's/^ *//g'` + LDFLAGS="$perlldflags $LDFLAGS" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ +*************** +*** 5162,5168 **** + PERL_CFLAGS=`echo "$perlcppflags" | sed -e 's/-pipe //' -e 's/-W[^ ]*//'` + fi + if test "X$perlldflags" != "X"; then +! LDFLAGS="$perlldflags $LDFLAGS" + fi + PERL_LIBS=$perllibs + PERL_SRC="auto/if_perl.c if_perlsfio.c" +--- 5163,5171 ---- + PERL_CFLAGS=`echo "$perlcppflags" | sed -e 's/-pipe //' -e 's/-W[^ ]*//'` + fi + if test "X$perlldflags" != "X"; then +! if test "X`echo \"$LDFLAGS\" | grep -F -e \"$perlldflags\"`" = "X"; then +! LDFLAGS="$perlldflags $LDFLAGS" +! fi + fi + PERL_LIBS=$perllibs + PERL_SRC="auto/if_perl.c if_perlsfio.c" +*************** +*** 6454,6460 **** + if test "X$rubyldflags" != "X"; then + rubyldflags=`echo "$rubyldflags" | sed -e 's/-arch\ ppc//' -e 's/-arch\ i386//' -e 's/-arch\ x86_64//'` + if test "X$rubyldflags" != "X"; then +! LDFLAGS="$rubyldflags $LDFLAGS" + fi + fi + RUBY_SRC="if_ruby.c" +--- 6457,6465 ---- + if test "X$rubyldflags" != "X"; then + rubyldflags=`echo "$rubyldflags" | sed -e 's/-arch\ ppc//' -e 's/-arch\ i386//' -e 's/-arch\ x86_64//'` + if test "X$rubyldflags" != "X"; then +! if test "X`echo \"$LDFLAGS\" | grep -F -e \"$rubyldflags\"`" = "X"; then +! LDFLAGS="$rubyldflags $LDFLAGS" +! fi + fi + fi + RUBY_SRC="if_ruby.c" +*************** +*** 12690,12696 **** + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_FORTIFY_SOURCE=1" >&5 + $as_echo_n "checking whether we need -D_FORTIFY_SOURCE=1... " >&6; } + if test "$gccmajor" -gt "3"; then +! CFLAGS=`echo "$CFLAGS" | sed -e 's/-Wp,-D_FORTIFY_SOURCE=.//g' -e 's/-D_FORTIFY_SOURCE=.//g' -e 's/$/ -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1/'` + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 + $as_echo "yes" >&6; } + else +--- 12695,12701 ---- + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_FORTIFY_SOURCE=1" >&5 + $as_echo_n "checking whether we need -D_FORTIFY_SOURCE=1... " >&6; } + if test "$gccmajor" -gt "3"; then +! CFLAGS=`echo "$CFLAGS" | sed -e 's/ *-Wp,-D_FORTIFY_SOURCE=.//g' -e 's/ *-D_FORTIFY_SOURCE=.//g' -e 's/ *-U_FORTIFY_SOURCE//g' -e 's/$/ -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1/'` + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 + $as_echo "yes" >&6; } + else +*************** +*** 12705,12711 **** + LINK_AS_NEEDED= + # Check if linker supports --as-needed and --no-as-needed options + if $CC -Wl,--help 2>/dev/null | grep as-needed > /dev/null; then +! LDFLAGS="$LDFLAGS -Wl,--as-needed" + LINK_AS_NEEDED=yes + fi + if test "$LINK_AS_NEEDED" = yes; then +--- 12710,12716 ---- + LINK_AS_NEEDED= + # Check if linker supports --as-needed and --no-as-needed options + if $CC -Wl,--help 2>/dev/null | grep as-needed > /dev/null; then +! LDFLAGS=`echo "$LDFLAGS" | sed -e 's/ *-Wl,--as-needed//g' | sed -e 's/$/ -Wl,--as-needed/'` + LINK_AS_NEEDED=yes + fi + if test "$LINK_AS_NEEDED" = yes; then +*** ../vim-7.3.1220/src/version.c 2013-06-17 22:43:18.000000000 +0200 +--- src/version.c 2013-06-18 23:18:45.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1221, + /**/ + + +-- +hundred-and-one symptoms of being an internet addict: +251. You've never seen your closest friends who usually live WAY too far away. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From f359e14d1f16cb41510ab67b296c94f3b534cdde Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:18 +0200 Subject: [PATCH 1115/3340] - patchlevel 1222 --- 7.3.1222 | 70 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 7.3.1222 diff --git a/7.3.1222 b/7.3.1222 new file mode 100644 index 00000000..5e6fc848 --- /dev/null +++ b/7.3.1222 @@ -0,0 +1,70 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1222 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1222 +Problem: Cannot execute some tests from the src directly. +Solution: Add missing targets. +Files: src/Makefile + + +*** ../vim-7.3.1221/src/Makefile 2013-06-18 23:31:41.000000000 +0200 +--- src/Makefile 2013-06-19 20:05:45.000000000 +0200 +*************** +*** 1867,1882 **** + done + + # Run individual test, assuming that Vim was already compiled. +! test1 test2 test3 test4 test5 test6 test7 test8 test9 test10 \ +! test11 test12 test13 test14 test15 test16 test17 test18 test19 \ +! test21 test22 test23 test24 test25 test26 test27 test28 test29 \ +! test31 test32 test33 test34 test35 test36 test37 test38 test39 \ +! test41 test42 test43 test44 test45 test46 test47 test48 test49 \ +! test51 test52 test53 test54 test55 test56 test57 test58 test59 \ +! test61 test62 test63 test64 test65 test66 test67 test68 test69 \ +! test71 test72 test73 test74 test75 test76 test77 test78 test79 \ +! test81 test82 test83 test84 test85 test86 test87 test88 test89 \ +! test91 test92 test93 test94 test95 test96 test97 test98 test99: + cd testdir; rm $@.out; $(MAKE) -f Makefile $@.out VIMPROG=../$(VIMTARGET) + + testclean: +--- 1868,1883 ---- + done + + # Run individual test, assuming that Vim was already compiled. +! test1 test2 test3 test4 test5 test6 test7 test8 test9 \ +! test10 test11 test12 test13 test14 test15 test16 test17 test18 test19 \ +! test20 test21 test22 test23 test24 test25 test26 test27 test28 test29 \ +! test30 test31 test32 test33 test34 test35 test36 test37 test38 test39 \ +! test40 test41 test42 test43 test44 test45 test46 test47 test48 test49 \ +! test50 test51 test52 test53 test54 test55 test56 test57 test58 test59 \ +! test60 test61 test62 test63 test64 test65 test66 test67 test68 test69 \ +! test70 test71 test72 test73 test74 test75 test76 test77 test78 test79 \ +! test80 test81 test82 test83 test84 test85 test86 test87 test88 test89 \ +! test90 test91 test92 test93 test94 test95 test96 test97 test98 test99: + cd testdir; rm $@.out; $(MAKE) -f Makefile $@.out VIMPROG=../$(VIMTARGET) + + testclean: +*** ../vim-7.3.1221/src/version.c 2013-06-18 23:31:41.000000000 +0200 +--- src/version.c 2013-06-19 20:11:01.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1222, + /**/ + +-- +If VIM were a woman, I'd marry her. Slim, organized, helpful +and beautiful; what's not to like? --David A. Rogers + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0fb978cf8b10800a5c54a8d2b5456eed5d62a8b6 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:19 +0200 Subject: [PATCH 1116/3340] - patchlevel 1223 --- 7.3.1223 | 262 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 262 insertions(+) create mode 100644 7.3.1223 diff --git a/7.3.1223 b/7.3.1223 new file mode 100644 index 00000000..be6e89bd --- /dev/null +++ b/7.3.1223 @@ -0,0 +1,262 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1223 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1223 +Problem: Tests fail on MS-Windows. +Solution: Avoid depending on OS version. Use DOS commands instead of Unix + commands. (Taro Muraoka, Ken Takata) +Files: src/testdir/test17.in, src/testdir/test50.in, + src/testdir/test71.in, src/testdir/test77.in + + +*** ../vim-7.3.1222/src/testdir/test17.in 2012-07-25 13:46:25.000000000 +0200 +--- src/testdir/test17.in 2013-06-19 21:01:57.000000000 +0200 +*************** +*** 9,14 **** +--- 9,21 ---- + :else + : set isfname=@,48-57,/,.,-,_,+,,,$,:,~,{,} + :endif ++ :function! DeleteDirectory(dir) ++ : if has("win16") || has("win32") || has("win64") || has("dos16") || has("dos32") ++ : exec "silent !rmdir /Q /S " . a:dir ++ : else ++ : exec "silent !rm -rf " . a:dir ++ : endif ++ :endfun + :if has("unix") + :let $CDIR = "." + /CDIR +*************** +*** 20,25 **** +--- 27,37 ---- + :endif + /TDIR + :endif ++ :" Dummy writing for making that sure gf doesn't fail even if the current ++ :" file is modified. It can be occurred when executing the following command ++ :" directly on Windows without fixing the 'fileformat': ++ :" > nmake -f Make_dos.mak test17.out ++ :w! test.out + gf + :w! test.out + :brewind +*************** +*** 31,40 **** + STARTTEST + :" check for 'include' without \zs or \ze + :lang C +! :!rm -f ./Xbase.a +! :!rm -rf ./Xdir1 +! :!mkdir -p Xdir1/dir2 +! :e Xdir1/dir2/foo.a + i#include "bar.a" + :w + :e Xdir1/dir2/bar.a +--- 43,53 ---- + STARTTEST + :" check for 'include' without \zs or \ze + :lang C +! :call delete("./Xbase.a") +! :call DeleteDirectory("Xdir1") +! :!mkdir Xdir1 +! :!mkdir "Xdir1/dir2" +! :e! Xdir1/dir2/foo.a + i#include "bar.a" + :w + :e Xdir1/dir2/bar.a +*************** +*** 55,69 **** + + STARTTEST + :" check for 'include' with \zs and \ze +! :!rm -f ./Xbase.b +! :!rm -rf ./Xdir1 +! :!mkdir -p Xdir1/dir2 + :let &include='^\s*%inc\s*/\zs[^/]\+\ze' + :function! DotsToSlashes() + : return substitute(v:fname, '\.', '/', 'g') . '.b' + :endfunction + :let &includeexpr='DotsToSlashes()' +! :e Xdir1/dir2/foo.b + i%inc /bar/ + :w + :e Xdir1/dir2/bar.b +--- 68,83 ---- + + STARTTEST + :" check for 'include' with \zs and \ze +! :call delete("./Xbase.b") +! :call DeleteDirectory("Xdir1") +! :!mkdir Xdir1 +! :!mkdir "Xdir1/dir2" + :let &include='^\s*%inc\s*/\zs[^/]\+\ze' + :function! DotsToSlashes() + : return substitute(v:fname, '\.', '/', 'g') . '.b' + :endfunction + :let &includeexpr='DotsToSlashes()' +! :e! Xdir1/dir2/foo.b + i%inc /bar/ + :w + :e Xdir1/dir2/bar.b +*************** +*** 84,92 **** + + STARTTEST + :" check for 'include' with \zs and no \ze +! :!rm -f ./Xbase.c +! :!rm -rf ./Xdir1 +! :!mkdir -p Xdir1/dir2 + :let &include='^\s*%inc\s*\%([[:upper:]][^[:space:]]*\s\+\)\?\zs\S\+\ze' + :function! StripNewlineChar() + : if v:fname =~ '\n$' +--- 98,107 ---- + + STARTTEST + :" check for 'include' with \zs and no \ze +! :call delete("./Xbase.c") +! :call DeleteDirectory("Xdir1") +! :!mkdir Xdir1 +! :!mkdir "Xdir1/dir2" + :let &include='^\s*%inc\s*\%([[:upper:]][^[:space:]]*\s\+\)\?\zs\S\+\ze' + :function! StripNewlineChar() + : if v:fname =~ '\n$' +*************** +*** 95,101 **** + : return v:fname + :endfunction + :let &includeexpr='StripNewlineChar()' +! :e Xdir1/dir2/foo.c + i%inc bar.c + :w + :e Xdir1/dir2/bar.c +--- 110,116 ---- + : return v:fname + :endfunction + :let &includeexpr='StripNewlineChar()' +! :e! Xdir1/dir2/foo.c + i%inc bar.c + :w + :e Xdir1/dir2/bar.c +*************** +*** 115,120 **** +--- 130,139 ---- + :checkpath! + :redir END + :brewind ++ :" replace "\" to "/" for Windows ++ :e test.out ++ :%s#\\#/#g ++ :w + :q + ENDTEST + +*** ../vim-7.3.1222/src/testdir/test50.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test50.in 2013-06-19 20:03:18.000000000 +0200 +*************** +*** 33,39 **** + " This could change for CygWin to //cygdrive/c + let dir1='c:/x.x.y' + if filereadable(dir1) || isdirectory(dir1) +! call confirm( "'".dir1."' exists, cannot run test" ) + return + endif + let file1=dir1.'/zz.y.txt' +--- 33,39 ---- + " This could change for CygWin to //cygdrive/c + let dir1='c:/x.x.y' + if filereadable(dir1) || isdirectory(dir1) +! echo "FATAL: '".dir1."' exists, cannot run test" + return + endif + let file1=dir1.'/zz.y.txt' +*************** +*** 41,53 **** + let dir2=dir1.'/VimIsTheGreatestSinceSlicedBread' + let file2=dir2.'/z.txt' + let nofile2=dir2.'/zz.txt' +! let resdir1='c:/XX2235~1.Y' + let resfile1=resdir1.'/ZZY~1.TXT' + let resnofile1=resdir1.'/z.y.txt' + let resdir2=resdir1.'/VIMIST~1' + let resfile2=resdir2.'/z.txt' + let resnofile2=resdir2.'/zz.txt' +- call MakeDir( dir1 ) + call MakeDir( dir2 ) + call MakeFile( file1 ) + call MakeFile( file2 ) +--- 41,58 ---- + let dir2=dir1.'/VimIsTheGreatestSinceSlicedBread' + let file2=dir2.'/z.txt' + let nofile2=dir2.'/zz.txt' +! call MakeDir( dir1 ) +! let resdir1 = substitute(fnamemodify(dir1, ':p:8'), '\\$', '', '') +! if resdir1 !~ '\V\^c:/XX\x\x\x\x~1.Y\$' +! echo "FATAL: unexpected short name: " . resdir1 +! echo "INFO: please report your OS to vim-dev" +! return +! endif + let resfile1=resdir1.'/ZZY~1.TXT' + let resnofile1=resdir1.'/z.y.txt' + let resdir2=resdir1.'/VIMIST~1' + let resfile2=resdir2.'/z.txt' + let resnofile2=resdir2.'/zz.txt' + call MakeDir( dir2 ) + call MakeFile( file1 ) + call MakeFile( file2 ) +*** ../vim-7.3.1222/src/testdir/test71.in 2010-08-15 21:57:29.000000000 +0200 +--- src/testdir/test71.in 2013-06-19 20:09:12.000000000 +0200 +*************** +*** 8,14 **** + :let cm0_bytes = getline('.', '.') + :/^start of cm=blowfish bytes/+1 + :let cm1_bytes = getline('.', '.') +! :bwipe + :call append(0, text_lines) + :$d + :X +--- 8,14 ---- + :let cm0_bytes = getline('.', '.') + :/^start of cm=blowfish bytes/+1 + :let cm1_bytes = getline('.', '.') +! :bwipe! + :call append(0, text_lines) + :$d + :X +*** ../vim-7.3.1222/src/testdir/test77.in 2012-04-30 11:34:20.000000000 +0200 +--- src/testdir/test77.in 2013-06-19 20:03:54.000000000 +0200 +*************** +*** 23,28 **** +--- 23,29 ---- + :w! Xtest + :r !cksum Xtest + :s/\s/ /g ++ :set fileformat& + :.w! test.out + :qa! + ENDTEST +*** ../vim-7.3.1222/src/version.c 2013-06-19 20:11:44.000000000 +0200 +--- src/version.c 2013-06-19 21:03:21.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1223, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +255. You work for a newspaper and your editor asks you to write an + article about Internet addiction...in the "first person." + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From a1ee54bc577322990d2ebaf49277a36c06bbe72b Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:20 +0200 Subject: [PATCH 1117/3340] - patchlevel 1224 --- 7.3.1224 | 105 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 105 insertions(+) create mode 100644 7.3.1224 diff --git a/7.3.1224 b/7.3.1224 new file mode 100644 index 00000000..8da1fc06 --- /dev/null +++ b/7.3.1224 @@ -0,0 +1,105 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1224 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1224 +Problem: Clang gives warnings on xxd. +Solution: Change how to use part of a string. (Dominique Pelle) Also avoid + warning for return not reached. +Files: src/xxd/xxd.c, src/regexp_nfa.c + +*** ../vim-7.3.1223/src/xxd/xxd.c 2013-02-26 14:14:01.000000000 +0100 +--- src/xxd/xxd.c 2013-06-21 18:23:53.000000000 +0200 +*************** +*** 722,728 **** + while ((length < 0 || p < length) && (c = getc(fp)) != EOF) + { + if (fprintf(fpo, (hexx == hexxa) ? "%s0x%02x" : "%s0X%02X", +! (p % cols) ? ", " : ",\n "+2*!p, c) < 0) + die(3); + p++; + } +--- 722,728 ---- + while ((length < 0 || p < length) && (c = getc(fp)) != EOF) + { + if (fprintf(fpo, (hexx == hexxa) ? "%s0x%02x" : "%s0X%02X", +! (p % cols) ? ", " : &",\n "[2*!p], c) < 0) + die(3); + p++; + } +*************** +*** 731,737 **** + + if (p && fputs("\n", fpo) == EOF) + die(3); +! if (fputs("};\n" + 3 * (fp == stdin), fpo) == EOF) + die(3); + + if (fp != stdin) +--- 731,737 ---- + + if (p && fputs("\n", fpo) == EOF) + die(3); +! if (fputs(&"};\n"[3 * (fp == stdin)], fpo) == EOF) + die(3); + + if (fp != stdin) +*** ../vim-7.3.1223/src/regexp_nfa.c 2013-06-17 21:33:36.000000000 +0200 +--- src/regexp_nfa.c 2013-06-21 18:29:43.000000000 +0200 +*************** +*** 2611,2617 **** + if (depth > 4) + return -1; + +! for (;;) + { + switch (state->c) + { +--- 2611,2617 ---- + if (depth > 4) + return -1; + +! while (state != NULL) + { + switch (state->c) + { +*************** +*** 2810,2816 **** + state = state->out; + } + +! /* unrecognized */ + return -1; + } + +--- 2810,2816 ---- + state = state->out; + } + +! /* unrecognized, "cannot happen" */ + return -1; + } + +*** ../vim-7.3.1223/src/version.c 2013-06-19 21:17:26.000000000 +0200 +--- src/version.c 2013-06-21 18:25:09.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1224, + /**/ + +-- +Two fish in a tank. One says to the other: +"Do you know how to drive this thing?" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0d0bb766ecaf27c4ee3f920edccd208f49831795 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:20 +0200 Subject: [PATCH 1118/3340] - patchlevel 1225 --- 7.3.1225 | 69 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.1225 diff --git a/7.3.1225 b/7.3.1225 new file mode 100644 index 00000000..823c16b9 --- /dev/null +++ b/7.3.1225 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1225 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1225 +Problem: Compiler warnings when building with Motif. +Solution: Change set_label() argument. (Kazunobu Kuriyama) +Files: src/gui_motif.c + + +*** ../vim-7.3.1224/src/gui_motif.c 2013-05-06 04:21:35.000000000 +0200 +--- src/gui_motif.c 2013-06-22 12:54:44.000000000 +0200 +*************** +*** 3653,3659 **** + static void + set_label(w, label) + Widget w; +! char_u *label; + { + XmString str; + char_u *p, *next; +--- 3653,3659 ---- + static void + set_label(w, label) + Widget w; +! char *label; + { + XmString str; + char_u *p, *next; +*************** +*** 3662,3668 **** + if (!w) + return; + +! p = vim_strsave(label); + if (p == NULL) + return; + for (next = p; *next; ++next) +--- 3662,3668 ---- + if (!w) + return; + +! p = vim_strsave((char_u *)label); + if (p == NULL) + return; + for (next = p; *next; ++next) +*** ../vim-7.3.1224/src/version.c 2013-06-21 18:31:16.000000000 +0200 +--- src/version.c 2013-06-22 12:59:52.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1225, + /**/ + +-- +hundred-and-one symptoms of being an internet addict: +10E. You start counting in hex. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 790b100a27477b555c9f425c4be223608e65e69d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:21 +0200 Subject: [PATCH 1119/3340] - patchlevel 1226 --- 7.3.1226 | 232 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 232 insertions(+) create mode 100644 7.3.1226 diff --git a/7.3.1226 b/7.3.1226 new file mode 100644 index 00000000..c506ae5b --- /dev/null +++ b/7.3.1226 @@ -0,0 +1,232 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1226 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1226 +Problem: Python: duplicate code. +Solution: Share code between OutputWrite() and OutputWritelines(). (ZyX) +Files: src/if_py_both.h, src/testdir/test86.ok, src/testdir/test87.ok + + +*** ../vim-7.3.1225/src/if_py_both.h 2013-06-16 14:25:53.000000000 +0200 +--- src/if_py_both.h 2013-06-23 12:46:03.000000000 +0200 +*************** +*** 281,295 **** + } + } + +! static PyObject * +! OutputWrite(OutputObject *self, PyObject *args) + { +! Py_ssize_t len = 0; +! char *str = NULL; +! int error = self->error; + +! if (!PyArg_ParseTuple(args, "et#", ENC_OPT, &str, &len)) +! return NULL; + + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); +--- 281,295 ---- + } + } + +! static int +! write_output(OutputObject *self, PyObject *string) + { +! Py_ssize_t len = 0; +! char *str = NULL; +! int error = self->error; + +! if (!PyArg_Parse(string, "et#", ENC_OPT, &str, &len)) +! return -1; + + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); +*************** +*** 298,341 **** + Py_END_ALLOW_THREADS + PyMem_Free(str); + + Py_INCREF(Py_None); + return Py_None; + } + + static PyObject * +! OutputWritelines(OutputObject *self, PyObject *args) + { +- PyObject *seq; + PyObject *iterator; + PyObject *item; +- int error = self->error; +- +- if (!PyArg_ParseTuple(args, "O", &seq)) +- return NULL; + + if (!(iterator = PyObject_GetIter(seq))) + return NULL; + + while ((item = PyIter_Next(iterator))) + { +! char *str = NULL; +! PyInt len; +! +! if (!PyArg_Parse(item, "et#", ENC_OPT, &str, &len)) + { +- PyErr_SetString(PyExc_TypeError, _("writelines() requires list of strings")); + Py_DECREF(iterator); + Py_DECREF(item); + return NULL; + } + Py_DECREF(item); +- +- Py_BEGIN_ALLOW_THREADS +- Python_Lock_Vim(); +- writer((writefn)(error ? emsg : msg), (char_u *)str, len); +- Python_Release_Vim(); +- Py_END_ALLOW_THREADS +- PyMem_Free(str); + } + + Py_DECREF(iterator); +--- 298,334 ---- + Py_END_ALLOW_THREADS + PyMem_Free(str); + ++ return 0; ++ } ++ ++ static PyObject * ++ OutputWrite(OutputObject *self, PyObject *string) ++ { ++ if (write_output(self, string)) ++ return NULL; ++ + Py_INCREF(Py_None); + return Py_None; + } + + static PyObject * +! OutputWritelines(OutputObject *self, PyObject *seq) + { + PyObject *iterator; + PyObject *item; + + if (!(iterator = PyObject_GetIter(seq))) + return NULL; + + while ((item = PyIter_Next(iterator))) + { +! if (write_output(self, item)) + { + Py_DECREF(iterator); + Py_DECREF(item); + return NULL; + } + Py_DECREF(item); + } + + Py_DECREF(iterator); +*************** +*** 360,367 **** + + static struct PyMethodDef OutputMethods[] = { + /* name, function, calling, doc */ +! {"write", (PyCFunction)OutputWrite, METH_VARARGS, ""}, +! {"writelines", (PyCFunction)OutputWritelines, METH_VARARGS, ""}, + {"flush", (PyCFunction)OutputFlush, METH_NOARGS, ""}, + {"__dir__", (PyCFunction)OutputDir, METH_NOARGS, ""}, + { NULL, NULL, 0, NULL} +--- 353,360 ---- + + static struct PyMethodDef OutputMethods[] = { + /* name, function, calling, doc */ +! {"write", (PyCFunction)OutputWrite, METH_O, ""}, +! {"writelines", (PyCFunction)OutputWritelines, METH_O, ""}, + {"flush", (PyCFunction)OutputFlush, METH_NOARGS, ""}, + {"__dir__", (PyCFunction)OutputDir, METH_NOARGS, ""}, + { NULL, NULL, 0, NULL} +*************** +*** 3009,3015 **** + return NULL; + } + +! /* Window object + */ + + typedef struct +--- 3002,3009 ---- + return NULL; + } + +! /* +! * Window object + */ + + typedef struct +*** ../vim-7.3.1225/src/testdir/test86.ok 2013-06-12 14:26:20.000000000 +0200 +--- src/testdir/test86.ok 2013-06-23 12:43:55.000000000 +0200 +*************** +*** 444,450 **** + sys.stdout.write(None):TypeError:('coercing to Unicode: need string or buffer, NoneType found',) + >> OutputWriteLines + sys.stdout.writelines(None):TypeError:("'NoneType' object is not iterable",) +! sys.stdout.writelines([1]):TypeError:('writelines() requires list of strings',) + > VimCommand + vim.command(1):TypeError:('must be string, not int',) + > VimToPython +--- 444,450 ---- + sys.stdout.write(None):TypeError:('coercing to Unicode: need string or buffer, NoneType found',) + >> OutputWriteLines + sys.stdout.writelines(None):TypeError:("'NoneType' object is not iterable",) +! sys.stdout.writelines([1]):TypeError:('coercing to Unicode: need string or buffer, int found',) + > VimCommand + vim.command(1):TypeError:('must be string, not int',) + > VimToPython +*** ../vim-7.3.1225/src/testdir/test87.ok 2013-06-12 14:20:15.000000000 +0200 +--- src/testdir/test87.ok 2013-06-23 12:44:00.000000000 +0200 +*************** +*** 433,439 **** + sys.stdout.write(None):(, TypeError("Can't convert 'NoneType' object to str implicitly",)) + >> OutputWriteLines + sys.stdout.writelines(None):(, TypeError("'NoneType' object is not iterable",)) +! sys.stdout.writelines([1]):(, TypeError('writelines() requires list of strings',)) + >>> Testing *Iter* using sys.stdout.writelines(%s) + sys.stdout.writelines(FailingIter()):(, NotImplementedError()) + sys.stdout.writelines(FailingIterNext()):(, NotImplementedError()) +--- 433,439 ---- + sys.stdout.write(None):(, TypeError("Can't convert 'NoneType' object to str implicitly",)) + >> OutputWriteLines + sys.stdout.writelines(None):(, TypeError("'NoneType' object is not iterable",)) +! sys.stdout.writelines([1]):(, TypeError("Can't convert 'int' object to str implicitly",)) + >>> Testing *Iter* using sys.stdout.writelines(%s) + sys.stdout.writelines(FailingIter()):(, NotImplementedError()) + sys.stdout.writelines(FailingIterNext()):(, NotImplementedError()) +*** ../vim-7.3.1225/src/version.c 2013-06-22 13:00:14.000000000 +0200 +--- src/version.c 2013-06-23 12:45:35.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1226, + /**/ + +-- + We're knights of the round table + We dance whene'er we're able + We do routines and chorus scenes + With footwork impeccable. + We dine well here in Camelot + We eat ham and jam and spam a lot. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2e13ad9629fcdca586db53131aa7474b46ec1d7a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:22 +0200 Subject: [PATCH 1120/3340] - patchlevel 1227 --- 7.3.1227 | 602 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 602 insertions(+) create mode 100644 7.3.1227 diff --git a/7.3.1227 b/7.3.1227 new file mode 100644 index 00000000..2f8271b1 --- /dev/null +++ b/7.3.1227 @@ -0,0 +1,602 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1227 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1227 +Problem: Inconsistent string conversion. +Solution: Use 'encoding' instead of utf-8. Use METH_O in place of + METH_VARARGS where appropriate. (ZyX) +Files: src/if_py_both.h, src/testdir/test86.ok, src/testdir/test87.ok + + +*** ../vim-7.3.1226/src/if_py_both.h 2013-06-23 12:51:27.000000000 +0200 +--- src/if_py_both.h 2013-06-23 12:57:34.000000000 +0200 +*************** +*** 466,486 **** + */ + + static PyObject * +! VimCommand(PyObject *self UNUSED, PyObject *args) + { +! char *cmd; +! PyObject *result; + +! if (!PyArg_ParseTuple(args, "s", &cmd)) + return NULL; + +- PyErr_Clear(); +- + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + + VimTryStart(); +! do_cmdline_cmd((char_u *)cmd); + update_screen(VALID); + + Python_Release_Vim(); +--- 466,485 ---- + */ + + static PyObject * +! VimCommand(PyObject *self UNUSED, PyObject *string) + { +! char_u *cmd; +! PyObject *result; +! PyObject *todecref; + +! if (!(cmd = StringToChars(string, &todecref))) + return NULL; + + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + + VimTryStart(); +! do_cmdline_cmd(cmd); + update_screen(VALID); + + Python_Release_Vim(); +*************** +*** 491,498 **** + else + result = Py_None; + +- + Py_XINCREF(result); + return result; + } + +--- 490,497 ---- + else + result = Py_None; + + Py_XINCREF(result); ++ Py_XDECREF(todecref); + return result; + } + +*************** +*** 641,661 **** + static PyObject * + VimEval(PyObject *self UNUSED, PyObject *args) + { +! char *expr; + typval_T *our_tv; + PyObject *result; +! PyObject *lookup_dict; + +! if (!PyArg_ParseTuple(args, "s", &expr)) + return NULL; + + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + VimTryStart(); +! our_tv = eval_expr((char_u *)expr, NULL); + Python_Release_Vim(); + Py_END_ALLOW_THREADS + + if (VimTryEnd()) + return NULL; + +--- 640,667 ---- + static PyObject * + VimEval(PyObject *self UNUSED, PyObject *args) + { +! char_u *expr; + typval_T *our_tv; ++ PyObject *string; ++ PyObject *todecref; + PyObject *result; +! PyObject *lookup_dict; + +! if (!PyArg_ParseTuple(args, "O", &string)) +! return NULL; +! +! if (!(expr = StringToChars(string, &todecref))) + return NULL; + + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + VimTryStart(); +! our_tv = eval_expr(expr, NULL); + Python_Release_Vim(); + Py_END_ALLOW_THREADS + ++ Py_XDECREF(todecref); ++ + if (VimTryEnd()) + return NULL; + +*************** +*** 688,709 **** + static PyObject *ConvertToPyObject(typval_T *); + + static PyObject * +! VimEvalPy(PyObject *self UNUSED, PyObject *args) + { +- char *expr; + typval_T *our_tv; + PyObject *result; + +! if (!PyArg_ParseTuple(args, "s", &expr)) + return NULL; + + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + VimTryStart(); +! our_tv = eval_expr((char_u *)expr, NULL); + Python_Release_Vim(); + Py_END_ALLOW_THREADS + + if (VimTryEnd()) + return NULL; + +--- 694,718 ---- + static PyObject *ConvertToPyObject(typval_T *); + + static PyObject * +! VimEvalPy(PyObject *self UNUSED, PyObject *string) + { + typval_T *our_tv; + PyObject *result; ++ char_u *expr; ++ PyObject *todecref; + +! if (!(expr = StringToChars(string, &todecref))) + return NULL; + + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + VimTryStart(); +! our_tv = eval_expr(expr, NULL); + Python_Release_Vim(); + Py_END_ALLOW_THREADS + ++ Py_XDECREF(todecref); ++ + if (VimTryEnd()) + return NULL; + +*************** +*** 724,743 **** + } + + static PyObject * +! VimStrwidth(PyObject *self UNUSED, PyObject *args) + { +! char *expr; + +! if (!PyArg_ParseTuple(args, "s", &expr)) + return NULL; + +- return PyLong_FromLong( + #ifdef FEAT_MBYTE +! mb_string2cells((char_u *)expr, (int)STRLEN(expr)) + #else +! STRLEN(expr) + #endif +! ); + } + + static PyObject * +--- 733,756 ---- + } + + static PyObject * +! VimStrwidth(PyObject *self UNUSED, PyObject *string) + { +! char_u *str; +! PyObject *todecref; +! int result; + +! if (!(str = StringToChars(string, &todecref))) + return NULL; + + #ifdef FEAT_MBYTE +! result = mb_string2cells(str, (int)STRLEN(str)); + #else +! result = STRLEN(str); + #endif +! +! Py_XDECREF(todecref); +! +! return PyLong_FromLong(result); + } + + static PyObject * +*************** +*** 840,852 **** + } + + static PyObject * +! VimForeachRTP(PyObject *self UNUSED, PyObject *args) + { + map_rtp_data data; + +! if (!PyArg_ParseTuple(args, "O", &data.callable)) +! return NULL; +! + data.result = NULL; + + do_in_runtimepath(NULL, FALSE, &map_rtp_callback, &data); +--- 853,863 ---- + } + + static PyObject * +! VimForeachRTP(PyObject *self UNUSED, PyObject *callable) + { + map_rtp_data data; + +! data.callable = callable; + data.result = NULL; + + do_in_runtimepath(NULL, FALSE, &map_rtp_callback, &data); +*************** +*** 1099,1111 **** + + static struct PyMethodDef VimMethods[] = { + /* name, function, calling, documentation */ +! {"command", VimCommand, METH_VARARGS, "Execute a Vim ex-mode command" }, + {"eval", VimEval, METH_VARARGS, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, METH_VARARGS, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, METH_VARARGS, "Screen string width, counts as having width 1"}, + {"chdir", (PyCFunction)VimChdir, METH_VARARGS|METH_KEYWORDS, "Change directory"}, + {"fchdir", (PyCFunction)VimFchdir, METH_VARARGS|METH_KEYWORDS, "Change directory"}, +! {"foreach_rtp", VimForeachRTP, METH_VARARGS, "Call given callable for each path in &rtp"}, + {"find_module", FinderFindModule, METH_VARARGS, "Internal use only, returns loader object for any input it receives"}, + {"path_hook", VimPathHook, METH_VARARGS, "Hook function to install in sys.path_hooks"}, + {"_get_paths", (PyCFunction)Vim_GetPaths, METH_NOARGS, "Get &rtp-based additions to sys.path"}, +--- 1110,1122 ---- + + static struct PyMethodDef VimMethods[] = { + /* name, function, calling, documentation */ +! {"command", VimCommand, METH_O, "Execute a Vim ex-mode command" }, + {"eval", VimEval, METH_VARARGS, "Evaluate an expression using Vim evaluator" }, +! {"bindeval", VimEvalPy, METH_O, "Like eval(), but returns objects attached to vim ones"}, +! {"strwidth", VimStrwidth, METH_O, "Screen string width, counts as having width 1"}, + {"chdir", (PyCFunction)VimChdir, METH_VARARGS|METH_KEYWORDS, "Change directory"}, + {"fchdir", (PyCFunction)VimFchdir, METH_VARARGS|METH_KEYWORDS, "Change directory"}, +! {"foreach_rtp", VimForeachRTP, METH_O, "Call given callable for each path in &rtp"}, + {"find_module", FinderFindModule, METH_VARARGS, "Internal use only, returns loader object for any input it receives"}, + {"path_hook", VimPathHook, METH_VARARGS, "Hook function to install in sys.path_hooks"}, + {"_get_paths", (PyCFunction)Vim_GetPaths, METH_NOARGS, "Get &rtp-based additions to sys.path"}, +*************** +*** 1733,1739 **** + { + PyObject *object; + +! if (!PyArg_Parse(args, "(O)", &object)) + return NULL; + + if (PyObject_HasAttrString(object, "keys")) +--- 1744,1750 ---- + { + PyObject *object; + +! if (!PyArg_ParseTuple(args, "O", &object)) + return NULL; + + if (PyObject_HasAttrString(object, "keys")) +*************** +*** 1877,1889 **** + } + + static PyObject * +! DictionaryHasKey(DictionaryObject *self, PyObject *args) + { +- PyObject *keyObject; +- +- if (!PyArg_ParseTuple(args, "O", &keyObject)) +- return NULL; +- + return _DictionaryItem(self, keyObject, DICT_FLAG_RETURN_BOOL); + } + +--- 1888,1895 ---- + } + + static PyObject * +! DictionaryHasKey(DictionaryObject *self, PyObject *keyObject) + { + return _DictionaryItem(self, keyObject, DICT_FLAG_RETURN_BOOL); + } + +*************** +*** 1914,1920 **** + {"get", (PyCFunction)DictionaryGet, METH_VARARGS, ""}, + {"pop", (PyCFunction)DictionaryPop, METH_VARARGS, ""}, + {"popitem", (PyCFunction)DictionaryPopItem, METH_NOARGS, ""}, +! {"has_key", (PyCFunction)DictionaryHasKey, METH_VARARGS, ""}, + {"__dir__", (PyCFunction)DictionaryDir, METH_NOARGS, ""}, + { NULL, NULL, 0, NULL} + }; +--- 1920,1926 ---- + {"get", (PyCFunction)DictionaryGet, METH_VARARGS, ""}, + {"pop", (PyCFunction)DictionaryPop, METH_VARARGS, ""}, + {"popitem", (PyCFunction)DictionaryPopItem, METH_NOARGS, ""}, +! {"has_key", (PyCFunction)DictionaryHasKey, METH_O, ""}, + {"__dir__", (PyCFunction)DictionaryDir, METH_NOARGS, ""}, + { NULL, NULL, 0, NULL} + }; +*************** +*** 2434,2444 **** + return NULL; + } + +! if (!PyArg_ParseTuple(args, "s", &name)) + return NULL; + + self = FunctionNew(subtype, name); + + return self; + } + +--- 2440,2452 ---- + return NULL; + } + +! if (!PyArg_ParseTuple(args, "et", "ascii", &name)) + return NULL; + + self = FunctionNew(subtype, name); + ++ PyMem_Free(name); ++ + return self; + } + +*************** +*** 4383,4402 **** + } + + static PyObject * +! BufferMark(BufferObject *self, PyObject *args) + { + pos_T *posp; +! char *pmark; +! char mark; + buf_T *savebuf; + + if (CheckBuffer(self)) + return NULL; + +! if (!PyArg_ParseTuple(args, "s", &pmark)) + return NULL; + +! if (STRLEN(pmark) != 1) + { + PyErr_SetString(PyExc_ValueError, + _("mark name must be a single character")); +--- 4391,4411 ---- + } + + static PyObject * +! BufferMark(BufferObject *self, PyObject *pmarkObject) + { + pos_T *posp; +! char_u *pmark; +! char_u mark; + buf_T *savebuf; ++ PyObject *todecref; + + if (CheckBuffer(self)) + return NULL; + +! if (!(pmark = StringToChars(pmarkObject, &todecref))) + return NULL; + +! if (pmark[0] == '\0' || pmark[1] != '\0') + { + PyErr_SetString(PyExc_ValueError, + _("mark name must be a single character")); +*************** +*** 4404,4409 **** +--- 4413,4421 ---- + } + + mark = *pmark; ++ ++ Py_XDECREF(todecref); ++ + VimTryStart(); + switch_buffer(&savebuf, self->buf); + posp = getmark(mark, FALSE); +*************** +*** 4461,4467 **** + static struct PyMethodDef BufferMethods[] = { + /* name, function, calling, documentation */ + {"append", (PyCFunction)BufferAppend, METH_VARARGS, "Append data to Vim buffer" }, +! {"mark", (PyCFunction)BufferMark, METH_VARARGS, "Return (row,col) representing position of named mark" }, + {"range", (PyCFunction)BufferRange, METH_VARARGS, "Return a range object which represents the part of the given buffer between line numbers s and e" }, + {"__dir__", (PyCFunction)BufferDir, METH_NOARGS, ""}, + { NULL, NULL, 0, NULL} +--- 4473,4479 ---- + static struct PyMethodDef BufferMethods[] = { + /* name, function, calling, documentation */ + {"append", (PyCFunction)BufferAppend, METH_VARARGS, "Append data to Vim buffer" }, +! {"mark", (PyCFunction)BufferMark, METH_O, "Return (row,col) representing position of named mark" }, + {"range", (PyCFunction)BufferRange, METH_VARARGS, "Return a range object which represents the part of the given buffer between line numbers s and e" }, + {"__dir__", (PyCFunction)BufferDir, METH_NOARGS, ""}, + { NULL, NULL, 0, NULL} +*** ../vim-7.3.1226/src/testdir/test86.ok 2013-06-23 12:51:27.000000000 +0200 +--- src/testdir/test86.ok 2013-06-23 12:57:34.000000000 +0200 +*************** +*** 446,459 **** + sys.stdout.writelines(None):TypeError:("'NoneType' object is not iterable",) + sys.stdout.writelines([1]):TypeError:('coercing to Unicode: need string or buffer, int found',) + > VimCommand +! vim.command(1):TypeError:('must be string, not int',) + > VimToPython + > VimEval +! vim.eval(1):TypeError:('must be string, not int',) + > VimEvalPy +! vim.bindeval(1):TypeError:('must be string, not int',) + > VimStrwidth +! vim.strwidth(1):TypeError:('must be string, not int',) + > Dictionary + >> DictionaryConstructor + vim.Dictionary("abc"):ValueError:('expected sequence element of size 2',) +--- 446,459 ---- + sys.stdout.writelines(None):TypeError:("'NoneType' object is not iterable",) + sys.stdout.writelines([1]):TypeError:('coercing to Unicode: need string or buffer, int found',) + > VimCommand +! vim.command(1):TypeError:('object must be string',) + > VimToPython + > VimEval +! vim.eval(1):TypeError:('object must be string',) + > VimEvalPy +! vim.bindeval(1):TypeError:('object must be string',) + > VimStrwidth +! vim.strwidth(1):TypeError:('object must be string',) + > Dictionary + >> DictionaryConstructor + vim.Dictionary("abc"):ValueError:('expected sequence element of size 2',) +*************** +*** 683,689 **** + >> DictionaryPopItem + d.popitem(1, 2):TypeError:('popitem() takes no arguments (2 given)',) + >> DictionaryHasKey +! d.has_key():TypeError:('function takes exactly 1 argument (0 given)',) + > List + >> ListConstructor + vim.List(1, 2):TypeError:('function takes at most 1 argument (2 given)',) +--- 683,689 ---- + >> DictionaryPopItem + d.popitem(1, 2):TypeError:('popitem() takes no arguments (2 given)',) + >> DictionaryHasKey +! d.has_key():TypeError:('has_key() takes exactly one argument (0 given)',) + > List + >> ListConstructor + vim.List(1, 2):TypeError:('function takes at most 1 argument (2 given)',) +*************** +*** 1065,1071 **** + vim.current.buffer.name = True:TypeError:('object must be string',) + vim.current.buffer.xxx = True:AttributeError:('xxx',) + >> BufferMark +! vim.current.buffer.mark(0):TypeError:('must be string, not int',) + vim.current.buffer.mark("abc"):ValueError:('mark name must be a single character',) + vim.current.buffer.mark("!"):error:('invalid mark name',) + >> BufferRange +--- 1065,1071 ---- + vim.current.buffer.name = True:TypeError:('object must be string',) + vim.current.buffer.xxx = True:AttributeError:('xxx',) + >> BufferMark +! vim.current.buffer.mark(0):TypeError:('object must be string',) + vim.current.buffer.mark("abc"):ValueError:('mark name must be a single character',) + vim.current.buffer.mark("!"):error:('invalid mark name',) + >> BufferRange +*** ../vim-7.3.1226/src/testdir/test87.ok 2013-06-23 12:51:27.000000000 +0200 +--- src/testdir/test87.ok 2013-06-23 12:57:34.000000000 +0200 +*************** +*** 439,452 **** + sys.stdout.writelines(FailingIterNext()):(, NotImplementedError()) + <<< Finished + > VimCommand +! vim.command(1):(, TypeError('must be str, not int',)) + > VimToPython + > VimEval +! vim.eval(1):(, TypeError('must be str, not int',)) + > VimEvalPy +! vim.bindeval(1):(, TypeError('must be str, not int',)) + > VimStrwidth +! vim.strwidth(1):(, TypeError('must be str, not int',)) + > Dictionary + >> DictionaryConstructor + vim.Dictionary("abc"):(, ValueError('expected sequence element of size 2',)) +--- 439,452 ---- + sys.stdout.writelines(FailingIterNext()):(, NotImplementedError()) + <<< Finished + > VimCommand +! vim.command(1):(, TypeError('object must be string',)) + > VimToPython + > VimEval +! vim.eval(1):(, TypeError('object must be string',)) + > VimEvalPy +! vim.bindeval(1):(, TypeError('object must be string',)) + > VimStrwidth +! vim.strwidth(1):(, TypeError('object must be string',)) + > Dictionary + >> DictionaryConstructor + vim.Dictionary("abc"):(, ValueError('expected sequence element of size 2',)) +*************** +*** 680,686 **** + >> DictionaryPopItem + d.popitem(1, 2):(, TypeError('popitem() takes no arguments (2 given)',)) + >> DictionaryHasKey +! d.has_key():(, TypeError('function takes exactly 1 argument (0 given)',)) + > List + >> ListConstructor + vim.List(1, 2):(, TypeError('function takes at most 1 argument (2 given)',)) +--- 680,686 ---- + >> DictionaryPopItem + d.popitem(1, 2):(, TypeError('popitem() takes no arguments (2 given)',)) + >> DictionaryHasKey +! d.has_key():(, TypeError('has_key() takes exactly one argument (0 given)',)) + > List + >> ListConstructor + vim.List(1, 2):(, TypeError('function takes at most 1 argument (2 given)',)) +*************** +*** 1074,1080 **** + vim.current.buffer.name = True:(, TypeError('object must be string',)) + vim.current.buffer.xxx = True:(, AttributeError('xxx',)) + >> BufferMark +! vim.current.buffer.mark(0):(, TypeError('must be str, not int',)) + vim.current.buffer.mark("abc"):(, ValueError('mark name must be a single character',)) + vim.current.buffer.mark("!"):(, error('invalid mark name',)) + >> BufferRange +--- 1074,1080 ---- + vim.current.buffer.name = True:(, TypeError('object must be string',)) + vim.current.buffer.xxx = True:(, AttributeError('xxx',)) + >> BufferMark +! vim.current.buffer.mark(0):(, TypeError('object must be string',)) + vim.current.buffer.mark("abc"):(, ValueError('mark name must be a single character',)) + vim.current.buffer.mark("!"):(, error('invalid mark name',)) + >> BufferRange +*** ../vim-7.3.1226/src/version.c 2013-06-23 12:51:27.000000000 +0200 +--- src/version.c 2013-06-23 12:56:45.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1227, + /**/ + +-- + We're knights of the Round Table + Our shows are formidable + But many times + We're given rhymes + That are quite unsingable + We're opera mad in Camelot + We sing from the diaphragm a lot. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 951116566a25b573c3e4f9db97e53124ca98d7f5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:23 +0200 Subject: [PATCH 1121/3340] - patchlevel 1228 --- 7.3.1228 | 359 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 359 insertions(+) create mode 100644 7.3.1228 diff --git a/7.3.1228 b/7.3.1228 new file mode 100644 index 00000000..9fc1cd8f --- /dev/null +++ b/7.3.1228 @@ -0,0 +1,359 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1228 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1228 +Problem: Python: various inconsistencies and problems. +Solution: StringToLine now supports both bytes() and unicode() objects. + Make function names consistant. Fix memory leak fixed in + StringToLine. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c + + +*** ../vim-7.3.1227/src/if_py_both.h 2013-06-23 13:00:40.000000000 +0200 +--- src/if_py_both.h 2013-06-23 13:08:18.000000000 +0200 +*************** +*** 18,24 **** + #endif + + #ifdef FEAT_MBYTE +! # define ENC_OPT p_enc + #else + # define ENC_OPT "latin1" + #endif +--- 18,24 ---- + #endif + + #ifdef FEAT_MBYTE +! # define ENC_OPT ((char *)p_enc) + #else + # define ENC_OPT "latin1" + #endif +*************** +*** 92,119 **** + StringToChars(PyObject *object, PyObject **todecref) + { + char_u *p; +- PyObject *bytes = NULL; + + if (PyBytes_Check(object)) + { + +! if (PyString_AsStringAndSize(object, (char **) &p, NULL) == -1) +! return NULL; +! if (p == NULL) + return NULL; + + *todecref = NULL; + } + else if (PyUnicode_Check(object)) + { +! bytes = PyUnicode_AsEncodedString(object, (char *)ENC_OPT, NULL); +! if (bytes == NULL) +! return NULL; + +! if(PyString_AsStringAndSize(bytes, (char **) &p, NULL) == -1) + return NULL; +! if (p == NULL) + return NULL; + + *todecref = bytes; + } +--- 92,120 ---- + StringToChars(PyObject *object, PyObject **todecref) + { + char_u *p; + + if (PyBytes_Check(object)) + { + +! if (PyBytes_AsStringAndSize(object, (char **) &p, NULL) == -1 +! || p == NULL) + return NULL; + + *todecref = NULL; + } + else if (PyUnicode_Check(object)) + { +! PyObject *bytes; + +! if (!(bytes = PyUnicode_AsEncodedString(object, ENC_OPT, NULL))) + return NULL; +! +! if(PyBytes_AsStringAndSize(bytes, (char **) &p, NULL) == -1 +! || p == NULL) +! { +! Py_DECREF(bytes); + return NULL; ++ } + + *todecref = bytes; + } +*************** +*** 133,138 **** +--- 134,140 ---- + + if (!(string = PyString_FromString(s))) + return -1; ++ + if (PyList_Append(list, string)) + { + Py_DECREF(string); +*************** +*** 534,543 **** + } + + if (our_tv->v_type == VAR_STRING) +- { + result = PyString_FromString(our_tv->vval.v_string == NULL + ? "" : (char *)our_tv->vval.v_string); +- } + else if (our_tv->v_type == VAR_NUMBER) + { + char buf[NUMBUFLEN]; +--- 536,543 ---- +*************** +*** 3385,3406 **** + static char * + StringToLine(PyObject *obj) + { +! const char *str; +! char *save; +! PyObject *bytes; +! PyInt len; +! PyInt i; +! char *p; + +! if (obj == NULL || !PyString_Check(obj)) + { +! PyErr_BadArgument(); +! return NULL; + } + +! bytes = PyString_AsBytes(obj); /* for Python 2 this does nothing */ +! str = PyString_AsString(bytes); +! len = PyString_Size(bytes); + + /* + * Error checking: String must not contain newlines, as we +--- 3385,3415 ---- + static char * + StringToLine(PyObject *obj) + { +! char *str; +! char *save; +! PyObject *bytes = NULL; +! Py_ssize_t len; +! PyInt i; +! char *p; + +! if (PyBytes_Check(obj)) + { +! if (PyBytes_AsStringAndSize(obj, &str, &len) == -1 +! || str == NULL) +! return NULL; + } ++ else if (PyUnicode_Check(obj)) ++ { ++ if (!(bytes = PyUnicode_AsEncodedString(obj, ENC_OPT, NULL))) ++ return NULL; + +! if(PyBytes_AsStringAndSize(bytes, &str, &len) == -1 +! || str == NULL) +! { +! Py_DECREF(bytes); +! return NULL; +! } +! } + + /* + * Error checking: String must not contain newlines, as we +*************** +*** 3439,3445 **** + } + + save[i] = '\0'; +! PyString_FreeBytes(bytes); /* Python 2 does nothing here */ + + return save; + } +--- 3448,3454 ---- + } + + save[i] = '\0'; +! Py_XDECREF(bytes); /* Python 2 does nothing here */ + + return save; + } +*************** +*** 3568,3577 **** + + return OK; + } +! else if (PyString_Check(line)) + { +! char *save = StringToLine(line); +! buf_T *savebuf; + + if (save == NULL) + return FAIL; +--- 3577,3586 ---- + + return OK; + } +! else if (PyBytes_Check(line) || PyUnicode_Check(line)) + { +! char *save = StringToLine(line); +! buf_T *savebuf; + + if (save == NULL) + return FAIL; +*************** +*** 3821,3827 **** + /* First of all, we check the type of the supplied Python object. + * It must be a string or a list, or the call is in error. + */ +! if (PyString_Check(lines)) + { + char *str = StringToLine(lines); + buf_T *savebuf; +--- 3830,3836 ---- + /* First of all, we check the type of the supplied Python object. + * It must be a string or a list, or the call is in error. + */ +! if (PyBytes_Check(lines) || PyUnicode_Check(lines)) + { + char *str = StringToLine(lines); + buf_T *savebuf; +*************** +*** 5254,5260 **** + { + char_u *result; + +! if (PyString_AsStringAndSize(obj, (char **) &result, NULL) == -1) + return -1; + if (result == NULL) + return -1; +--- 5263,5269 ---- + { + char_u *result; + +! if (PyBytes_AsStringAndSize(obj, (char **) &result, NULL) == -1) + return -1; + if (result == NULL) + return -1; +*************** +*** 5269,5279 **** + PyObject *bytes; + char_u *result; + +! bytes = PyUnicode_AsEncodedString(obj, (char *)ENC_OPT, NULL); + if (bytes == NULL) + return -1; + +! if(PyString_AsStringAndSize(bytes, (char **) &result, NULL) == -1) + return -1; + if (result == NULL) + return -1; +--- 5278,5288 ---- + PyObject *bytes; + char_u *result; + +! bytes = PyUnicode_AsEncodedString(obj, ENC_OPT, NULL); + if (bytes == NULL) + return -1; + +! if(PyBytes_AsStringAndSize(bytes, (char **) &result, NULL) == -1) + return -1; + if (result == NULL) + return -1; +*** ../vim-7.3.1227/src/if_python3.c 2013-06-13 20:57:44.000000000 +0200 +--- src/if_python3.c 2013-06-23 13:08:18.000000000 +0200 +*************** +*** 84,96 **** + + #define PyInt Py_ssize_t + #define PyString_Check(obj) PyUnicode_Check(obj) +- #define PyString_AsBytes(obj) PyUnicode_AsEncodedString(obj, (char *)ENC_OPT, CODEC_ERROR_HANDLER) +- #define PyString_FreeBytes(obj) Py_XDECREF(bytes) +- #define PyString_AsString(obj) PyBytes_AsString(obj) +- #define PyString_Size(obj) PyBytes_GET_SIZE(bytes) + #define PyString_FromString(repr) PyUnicode_FromString(repr) + #define PyString_FromFormat PyUnicode_FromFormat +- #define PyString_AsStringAndSize(obj, buffer, len) PyBytes_AsStringAndSize(obj, buffer, len) + #define PyInt_Check(obj) PyLong_Check(obj) + #define PyInt_FromLong(i) PyLong_FromLong(i) + #define PyInt_AsLong(obj) PyLong_AsLong(obj) +--- 84,91 ---- +*************** +*** 357,363 **** + # endif + static PyObject* (*py3_PyUnicode_AsEncodedString)(PyObject *unicode, const char* encoding, const char* errors); + static char* (*py3_PyBytes_AsString)(PyObject *bytes); +! static int (*py3_PyBytes_AsStringAndSize)(PyObject *bytes, char **buffer, int *length); + static PyObject* (*py3_PyBytes_FromString)(char *str); + static PyObject* (*py3_PyFloat_FromDouble)(double num); + static double (*py3_PyFloat_AsDouble)(PyObject *); +--- 352,358 ---- + # endif + static PyObject* (*py3_PyUnicode_AsEncodedString)(PyObject *unicode, const char* encoding, const char* errors); + static char* (*py3_PyBytes_AsString)(PyObject *bytes); +! static int (*py3_PyBytes_AsStringAndSize)(PyObject *bytes, char **buffer, Py_ssize_t *length); + static PyObject* (*py3_PyBytes_FromString)(char *str); + static PyObject* (*py3_PyFloat_FromDouble)(double num); + static double (*py3_PyFloat_AsDouble)(PyObject *); +*** ../vim-7.3.1227/src/if_python.c 2013-06-12 14:40:58.000000000 +0200 +--- src/if_python.c 2013-06-23 13:08:18.000000000 +0200 +*************** +*** 68,79 **** + #undef main /* Defined in python.h - aargh */ + #undef HAVE_FCNTL_H /* Clash with os_win32.h */ + +! #define PyBytes_FromString PyString_FromString +! #define PyBytes_Check PyString_Check +! +! /* No-op conversion functions, use with care! */ +! #define PyString_AsBytes(obj) (obj) +! #define PyString_FreeBytes(obj) + + #if !defined(FEAT_PYTHON) && defined(PROTO) + /* Use this to be able to generate prototypes without python being used. */ +--- 68,76 ---- + #undef main /* Defined in python.h - aargh */ + #undef HAVE_FCNTL_H /* Clash with os_win32.h */ + +! #define PyBytes_FromString PyString_FromString +! #define PyBytes_Check PyString_Check +! #define PyBytes_AsStringAndSize PyString_AsStringAndSize + + #if !defined(FEAT_PYTHON) && defined(PROTO) + /* Use this to be able to generate prototypes without python being used. */ +*** ../vim-7.3.1227/src/version.c 2013-06-23 13:00:40.000000000 +0200 +--- src/version.c 2013-06-23 13:07:40.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1228, + /**/ + +-- + In war we're tough and able. + Quite indefatigable + Between our quests + We sequin vests + And impersonate Clark Gable + It's a busy life in Camelot. + I have to push the pram a lot. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 68ba2436c7eb304554aeaf9f09847895dd868886 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:24 +0200 Subject: [PATCH 1122/3340] - patchlevel 1229 --- 7.3.1229 | 1572 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1572 insertions(+) create mode 100644 7.3.1229 diff --git a/7.3.1229 b/7.3.1229 new file mode 100644 index 00000000..ef4c8ec2 --- /dev/null +++ b/7.3.1229 @@ -0,0 +1,1572 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1229 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1229 +Problem: Python: not so easy to delete/restore translating. +Solution: Make macros do translation of exception messages. (ZyX) + Note: this breaks translations! +Files: src/if_py_both.h, src/if_python3.c + + +*** ../vim-7.3.1228/src/if_py_both.h 2013-06-23 13:11:14.000000000 +0200 +--- src/if_py_both.h 2013-06-23 13:19:01.000000000 +0200 +*************** +*** 26,35 **** + + static const char *vim_special_path = "_vim_path_"; + + #define PyErr_SetVim(str) PyErr_SetString(VimError, str) + +! #define RAISE_NO_EMPTY_KEYS PyErr_SetString(PyExc_ValueError, \ +! _("empty keys are not allowed")) + + #define INVALID_BUFFER_VALUE ((buf_T *)(-1)) + #define INVALID_WINDOW_VALUE ((win_T *)(-1)) +--- 26,37 ---- + + static const char *vim_special_path = "_vim_path_"; + ++ #define PyErr_SET_STRING(exc, str) PyErr_SetString(exc, _(str)) + #define PyErr_SetVim(str) PyErr_SetString(VimError, str) ++ #define PyErr_SET_VIM(str) PyErr_SET_STRING(VimError, str) + +! #define RAISE_NO_EMPTY_KEYS PyErr_SET_STRING(PyExc_ValueError, \ +! "empty keys are not allowed") + + #define INVALID_BUFFER_VALUE ((buf_T *)(-1)) + #define INVALID_WINDOW_VALUE ((win_T *)(-1)) +*************** +*** 120,126 **** + } + else + { +! PyErr_SetString(PyExc_TypeError, _("object must be string")); + return NULL; + } + +--- 122,128 ---- + } + else + { +! PyErr_SET_STRING(PyExc_TypeError, "object must be string"); + return NULL; + } + +*************** +*** 212,219 **** + { + if (val == NULL) + { +! PyErr_SetString(PyExc_AttributeError, +! _("can't delete OutputObject attributes")); + return -1; + } + +--- 214,221 ---- + { + if (val == NULL) + { +! PyErr_SET_STRING(PyExc_AttributeError, +! "can't delete OutputObject attributes"); + return -1; + } + +*************** +*** 221,227 **** + { + if (!PyInt_Check(val)) + { +! PyErr_SetString(PyExc_TypeError, _("softspace must be an integer")); + return -1; + } + +--- 223,229 ---- + { + if (!PyInt_Check(val)) + { +! PyErr_SET_STRING(PyExc_TypeError, "softspace must be an integer"); + return -1; + } + +*************** +*** 229,235 **** + return 0; + } + +! PyErr_SetString(PyExc_AttributeError, _("invalid attribute")); + return -1; + } + +--- 231,237 ---- + return 0; + } + +! PyErr_SET_STRING(PyExc_AttributeError, "invalid attribute"); + return -1; + } + +*************** +*** 667,673 **** + + if (our_tv == NULL) + { +! PyErr_SetVim(_("invalid expression")); + return NULL; + } + +--- 669,675 ---- + + if (our_tv == NULL) + { +! PyErr_SET_VIM("invalid expression"); + return NULL; + } + +*************** +*** 718,724 **** + + if (our_tv == NULL) + { +! PyErr_SetVim(_("invalid expression")); + return NULL; + } + +--- 720,726 ---- + + if (our_tv == NULL) + { +! PyErr_SET_VIM("invalid expression"); + return NULL; + } + +*************** +*** 790,796 **** + if (VimTryEnd()) + return NULL; + +! PyErr_SetVim(_("failed to change directory")); + return NULL; + } + +--- 792,798 ---- + if (VimTryEnd()) + return NULL; + +! PyErr_SET_VIM("failed to change directory"); + return NULL; + } + +*************** +*** 968,975 **** + if (!PyTuple_Check(find_module_result) + || PyTuple_GET_SIZE(find_module_result) != 3) + { +! PyErr_SetString(PyExc_TypeError, +! _("expected 3-tuple as imp.find_module() result")); + return NULL; + } + +--- 970,977 ---- + if (!PyTuple_Check(find_module_result) + || PyTuple_GET_SIZE(find_module_result) != 3) + { +! PyErr_SET_STRING(PyExc_TypeError, +! "expected 3-tuple as imp.find_module() result"); + return NULL; + } + +*************** +*** 977,984 **** + || !(pathname = PyTuple_GET_ITEM(find_module_result, 1)) + || !(description = PyTuple_GET_ITEM(find_module_result, 2))) + { +! PyErr_SetString(PyExc_RuntimeError, +! _("internal error: imp.find_module returned tuple with NULL")); + return NULL; + } + +--- 979,986 ---- + || !(pathname = PyTuple_GET_ITEM(find_module_result, 1)) + || !(description = PyTuple_GET_ITEM(find_module_result, 2))) + { +! PyErr_SET_STRING(PyExc_RuntimeError, +! "internal error: imp.find_module returned tuple with NULL"); + return NULL; + } + +*************** +*** 1349,1356 **** + { + if (val == NULL) + { +! PyErr_SetString(PyExc_AttributeError, +! _("cannot delete vim.Dictionary attributes")); + return -1; + } + +--- 1351,1358 ---- + { + if (val == NULL) + { +! PyErr_SET_STRING(PyExc_AttributeError, +! "cannot delete vim.Dictionary attributes"); + return -1; + } + +*************** +*** 1358,1364 **** + { + if (self->dict->dv_lock == VAR_FIXED) + { +! PyErr_SetString(PyExc_TypeError, _("cannot modify fixed dictionary")); + return -1; + } + else +--- 1360,1366 ---- + { + if (self->dict->dv_lock == VAR_FIXED) + { +! PyErr_SET_STRING(PyExc_TypeError, "cannot modify fixed dictionary"); + return -1; + } + else +*************** +*** 1375,1381 **** + } + else + { +! PyErr_SetString(PyExc_AttributeError, _("cannot set this attribute")); + return -1; + } + } +--- 1377,1383 ---- + } + else + { +! PyErr_SET_STRING(PyExc_AttributeError, "cannot set this attribute"); + return -1; + } + } +*************** +*** 1457,1463 **** + { + if (dict->dv_lock) + { +! PyErr_SetVim(_("dict is locked")); + Py_DECREF(r); + return NULL; + } +--- 1459,1465 ---- + { + if (dict->dv_lock) + { +! PyErr_SET_VIM("dict is locked"); + Py_DECREF(r); + return NULL; + } +*************** +*** 1508,1515 **** + if ((*dii)->ht->ht_array != (*dii)->ht_array || + (*dii)->ht->ht_used != (*dii)->ht_used) + { +! PyErr_SetString(PyExc_RuntimeError, +! _("hashtab changed during iteration")); + return NULL; + } + +--- 1510,1517 ---- + if ((*dii)->ht->ht_array != (*dii)->ht_array || + (*dii)->ht->ht_used != (*dii)->ht_used) + { +! PyErr_SET_STRING(PyExc_RuntimeError, +! "hashtab changed during iteration"); + return NULL; + } + +*************** +*** 1560,1566 **** + + if (dict->dv_lock) + { +! PyErr_SetVim(_("dict is locked")); + return -1; + } + +--- 1562,1568 ---- + + if (dict->dv_lock) + { +! PyErr_SET_VIM("dict is locked"); + return -1; + } + +*************** +*** 1615,1621 **** + Py_XDECREF(todecref); + vim_free(di); + dictitem_free(di); +! PyErr_SetVim(_("failed to add key to dictionary")); + return -1; + } + } +--- 1617,1623 ---- + Py_XDECREF(todecref); + vim_free(di); + dictitem_free(di); +! PyErr_SET_VIM("failed to add key to dictionary"); + return -1; + } + } +*************** +*** 1723,1729 **** + + if (dict->dv_lock) + { +! PyErr_SetVim(_("dict is locked")); + return NULL; + } + +--- 1725,1731 ---- + + if (dict->dv_lock) + { +! PyErr_SET_VIM("dict is locked"); + return NULL; + } + +*************** +*** 1779,1786 **** + { + Py_DECREF(iterator); + Py_DECREF(fast); +! PyErr_SetString(PyExc_ValueError, +! _("expected sequence element of size 2")); + return NULL; + } + +--- 1781,1788 ---- + { + Py_DECREF(iterator); + Py_DECREF(fast); +! PyErr_SET_STRING(PyExc_ValueError, +! "expected sequence element of size 2"); + return NULL; + } + +*************** +*** 1823,1829 **** + { + Py_DECREF(iterator); + dictitem_free(di); +! PyErr_SetVim(_("failed to add key to dictionary")); + return NULL; + } + } +--- 1825,1831 ---- + { + Py_DECREF(iterator); + dictitem_free(di); +! PyErr_SET_VIM("failed to add key to dictionary"); + return NULL; + } + } +*************** +*** 2021,2028 **** + + if (kwargs) + { +! PyErr_SetString(PyExc_TypeError, +! _("list constructor does not accept keyword arguments")); + return NULL; + } + +--- 2023,2030 ---- + + if (kwargs) + { +! PyErr_SET_STRING(PyExc_TypeError, +! "list constructor does not accept keyword arguments"); + return NULL; + } + +*************** +*** 2077,2089 **** + + if (index >= ListLength(self)) + { +! PyErr_SetString(PyExc_IndexError, _("list index out of range")); + return NULL; + } + li = list_find(self->list, (long) index); + if (li == NULL) + { +! PyErr_SetVim(_("internal error: failed to get vim list item")); + return NULL; + } + return ConvertToPyObject(&li->li_tv); +--- 2079,2091 ---- + + if (index >= ListLength(self)) + { +! PyErr_SET_STRING(PyExc_IndexError, "list index out of range"); + return NULL; + } + li = list_find(self->list, (long) index); + if (li == NULL) + { +! PyErr_SET_VIM("internal error: failed to get vim list item"); + return NULL; + } + return ConvertToPyObject(&li->li_tv); +*************** +*** 2196,2207 **** + + if (l->lv_lock) + { +! PyErr_SetVim(_("list is locked")); + return -1; + } + if (index>length || (index==length && obj==NULL)) + { +! PyErr_SetString(PyExc_IndexError, _("list index out of range")); + return -1; + } + +--- 2198,2209 ---- + + if (l->lv_lock) + { +! PyErr_SET_VIM("list is locked"); + return -1; + } + if (index>length || (index==length && obj==NULL)) + { +! PyErr_SET_STRING(PyExc_IndexError, "list index out of range"); + return -1; + } + +*************** +*** 2222,2228 **** + if (list_append_tv(l, &tv) == FAIL) + { + clear_tv(&tv); +! PyErr_SetVim(_("failed to add item to list")); + return -1; + } + } +--- 2224,2230 ---- + if (list_append_tv(l, &tv) == FAIL) + { + clear_tv(&tv); +! PyErr_SET_VIM("failed to add item to list"); + return -1; + } + } +*************** +*** 2250,2256 **** + + if (l->lv_lock) + { +! PyErr_SetVim(_("list is locked")); + return -1; + } + +--- 2252,2258 ---- + + if (l->lv_lock) + { +! PyErr_SET_VIM("list is locked"); + return -1; + } + +*************** +*** 2263,2269 **** + li = list_find(l, (long) first); + if (li == NULL) + { +! PyErr_SetVim(_("internal error: no vim list item")); + return -1; + } + if (last > first) +--- 2265,2271 ---- + li = list_find(l, (long) first); + if (li == NULL) + { +! PyErr_SET_VIM("internal error: no vim list item"); + return -1; + } + if (last > first) +*************** +*** 2296,2302 **** + if (list_insert_tv(l, &v, li) == FAIL) + { + clear_tv(&v); +! PyErr_SetVim(_("internal error: failed to add item to list")); + return -1; + } + clear_tv(&v); +--- 2298,2304 ---- + if (list_insert_tv(l, &v, li) == FAIL) + { + clear_tv(&v); +! PyErr_SET_VIM("internal error: failed to add item to list"); + return -1; + } + clear_tv(&v); +*************** +*** 2313,2319 **** + + if (l->lv_lock) + { +! PyErr_SetVim(_("list is locked")); + return NULL; + } + +--- 2315,2321 ---- + + if (l->lv_lock) + { +! PyErr_SET_VIM("list is locked"); + return NULL; + } + +*************** +*** 2347,2354 **** + { + if (val == NULL) + { +! PyErr_SetString(PyExc_AttributeError, +! _("cannot delete vim.List attributes")); + return -1; + } + +--- 2349,2356 ---- + { + if (val == NULL) + { +! PyErr_SET_STRING(PyExc_AttributeError, +! "cannot delete vim.List attributes"); + return -1; + } + +*************** +*** 2356,2362 **** + { + if (self->list->lv_lock == VAR_FIXED) + { +! PyErr_SetString(PyExc_TypeError, _("cannot modify fixed list")); + return -1; + } + else +--- 2358,2364 ---- + { + if (self->list->lv_lock == VAR_FIXED) + { +! PyErr_SET_STRING(PyExc_TypeError, "cannot modify fixed list"); + return -1; + } + else +*************** +*** 2373,2379 **** + } + else + { +! PyErr_SetString(PyExc_AttributeError, _("cannot set this attribute")); + return -1; + } + } +--- 2375,2381 ---- + } + else + { +! PyErr_SET_STRING(PyExc_AttributeError, "cannot set this attribute"); + return -1; + } + } +*************** +*** 2408,2415 **** + { + if (!translated_function_exists(name)) + { +! PyErr_SetString(PyExc_ValueError, +! _("unnamed function does not exist")); + return NULL; + } + self->name = vim_strsave(name); +--- 2410,2417 ---- + { + if (!translated_function_exists(name)) + { +! PyErr_SET_STRING(PyExc_ValueError, +! "unnamed function does not exist"); + return NULL; + } + self->name = vim_strsave(name); +*************** +*** 2420,2426 **** + vim_strchr(name, AUTOLOAD_CHAR) == NULL)) + == NULL) + { +! PyErr_SetString(PyExc_ValueError, _("function does not exist")); + return NULL; + } + +--- 2422,2428 ---- + vim_strchr(name, AUTOLOAD_CHAR) == NULL)) + == NULL) + { +! PyErr_SET_STRING(PyExc_ValueError, "function does not exist"); + return NULL; + } + +*************** +*** 2435,2442 **** + + if (kwargs) + { +! PyErr_SetString(PyExc_TypeError, +! _("function constructor does not accept keyword arguments")); + return NULL; + } + +--- 2437,2444 ---- + + if (kwargs) + { +! PyErr_SET_STRING(PyExc_TypeError, +! "function constructor does not accept keyword arguments"); + return NULL; + } + +*************** +*** 2513,2519 **** + else if (error != OK) + { + result = NULL; +! PyErr_SetVim(_("failed to run function")); + } + else + result = ConvertToPyObject(&rettv); +--- 2515,2521 ---- + else if (error != OK) + { + result = NULL; +! PyErr_SET_VIM("failed to run function"); + } + else + result = ConvertToPyObject(&rettv); +*************** +*** 2658,2671 **** + } + else + { +! PyErr_SetString(PyExc_RuntimeError, +! _("unable to get option value")); + return NULL; + } + } + else + { +! PyErr_SetVim("Internal error: unknown option type. Should not happen"); + return NULL; + } + } +--- 2660,2673 ---- + } + else + { +! PyErr_SET_STRING(PyExc_RuntimeError, +! "unable to get option value"); + return NULL; + } + } + else + { +! PyErr_SET_VIM("internal error: unknown option type"); + return NULL; + } + } +*************** +*** 2708,2714 **** + { + if (VimTryEnd()) + return -1; +! PyErr_SetVim("Problem while switching windows."); + return -1; + } + r = set_option_value_err(key, numval, stringval, opt_flags); +--- 2710,2716 ---- + { + if (VimTryEnd()) + return -1; +! PyErr_SET_VIM("problem while switching windows"); + return -1; + } + r = set_option_value_err(key, numval, stringval, opt_flags); +*************** +*** 2768,2782 **** + { + if (self->opt_type == SREQ_GLOBAL) + { +! PyErr_SetString(PyExc_ValueError, +! _("unable to unset global option")); + Py_XDECREF(todecref); + return -1; + } + else if (!(flags & SOPT_GLOBAL)) + { +! PyErr_SetString(PyExc_ValueError, _("unable to unset option " +! "without global value")); + Py_XDECREF(todecref); + return -1; + } +--- 2770,2783 ---- + { + if (self->opt_type == SREQ_GLOBAL) + { +! PyErr_SET_STRING(PyExc_ValueError, "unable to unset global option"); + Py_XDECREF(todecref); + return -1; + } + else if (!(flags & SOPT_GLOBAL)) + { +! PyErr_SET_STRING(PyExc_ValueError, "unable to unset option " +! "without global value"); + Py_XDECREF(todecref); + return -1; + } +*************** +*** 2813,2819 **** + val = PyLong_AsLong(valObject); + else + { +! PyErr_SetString(PyExc_TypeError, _("object must be integer")); + Py_XDECREF(todecref); + return -1; + } +--- 2814,2820 ---- + val = PyLong_AsLong(valObject); + else + { +! PyErr_SET_STRING(PyExc_TypeError, "object must be integer"); + Py_XDECREF(todecref); + return -1; + } +*************** +*** 2862,2868 **** + { + if (self->tab == INVALID_TABPAGE_VALUE) + { +! PyErr_SetVim(_("attempt to refer to deleted tab page")); + return -1; + } + +--- 2863,2869 ---- + { + if (self->tab == INVALID_TABPAGE_VALUE) + { +! PyErr_SET_VIM("attempt to refer to deleted tab page"); + return -1; + } + +*************** +*** 3006,3012 **** + if (n == 0) + return TabPageNew(tp); + +! PyErr_SetString(PyExc_IndexError, _("no such tab page")); + return NULL; + } + +--- 3007,3013 ---- + if (n == 0) + return TabPageNew(tp); + +! PyErr_SET_STRING(PyExc_IndexError, "no such tab page"); + return NULL; + } + +*************** +*** 3028,3034 **** + { + if (self->win == INVALID_WINDOW_VALUE) + { +! PyErr_SetVim(_("attempt to refer to deleted window")); + return -1; + } + +--- 3029,3035 ---- + { + if (self->win == INVALID_WINDOW_VALUE) + { +! PyErr_SET_VIM("attempt to refer to deleted window"); + return -1; + } + +*************** +*** 3194,3200 **** + + if (strcmp(name, "buffer") == 0) + { +! PyErr_SetString(PyExc_TypeError, _("readonly attribute")); + return -1; + } + else if (strcmp(name, "cursor") == 0) +--- 3195,3201 ---- + + if (strcmp(name, "buffer") == 0) + { +! PyErr_SET_STRING(PyExc_TypeError, "readonly attribute"); + return -1; + } + else if (strcmp(name, "cursor") == 0) +*************** +*** 3207,3213 **** + + if (lnum <= 0 || lnum > self->win->w_buffer->b_ml.ml_line_count) + { +! PyErr_SetVim(_("cursor position outside buffer")); + return -1; + } + +--- 3208,3214 ---- + + if (lnum <= 0 || lnum > self->win->w_buffer->b_ml.ml_line_count) + { +! PyErr_SET_VIM("cursor position outside buffer"); + return -1; + } + +*************** +*** 3370,3376 **** + if (n == 0) + return WindowNew(w, self->tabObject? self->tabObject->tab: curtab); + +! PyErr_SetString(PyExc_IndexError, _("no such window")); + return NULL; + } + +--- 3371,3377 ---- + if (n == 0) + return WindowNew(w, self->tabObject? self->tabObject->tab: curtab); + +! PyErr_SET_STRING(PyExc_IndexError, "no such window"); + return NULL; + } + +*************** +*** 3424,3430 **** + --len; + else + { +! PyErr_SetVim(_("string cannot contain newlines")); + return NULL; + } + } +--- 3425,3431 ---- + --len; + else + { +! PyErr_SET_VIM("string cannot contain newlines"); + return NULL; + } + } +*************** +*** 3557,3565 **** + VimTryStart(); + + if (u_savedel((linenr_T)n, 1L) == FAIL) +! PyErr_SetVim(_("cannot save undo information")); + else if (ml_delete((linenr_T)n, FALSE) == FAIL) +! PyErr_SetVim(_("cannot delete line")); + else + { + if (buf == savebuf) +--- 3558,3566 ---- + VimTryStart(); + + if (u_savedel((linenr_T)n, 1L) == FAIL) +! PyErr_SET_VIM("cannot save undo information"); + else if (ml_delete((linenr_T)n, FALSE) == FAIL) +! PyErr_SET_VIM("cannot delete line"); + else + { + if (buf == savebuf) +*************** +*** 3593,3604 **** + + if (u_savesub((linenr_T)n) == FAIL) + { +! PyErr_SetVim(_("cannot save undo information")); + vim_free(save); + } + else if (ml_replace((linenr_T)n, (char_u *)save, FALSE) == FAIL) + { +! PyErr_SetVim(_("cannot replace line")); + vim_free(save); + } + else +--- 3594,3605 ---- + + if (u_savesub((linenr_T)n) == FAIL) + { +! PyErr_SET_VIM("cannot save undo information"); + vim_free(save); + } + else if (ml_replace((linenr_T)n, (char_u *)save, FALSE) == FAIL) + { +! PyErr_SET_VIM("cannot replace line"); + vim_free(save); + } + else +*************** +*** 3653,3666 **** + switch_buffer(&savebuf, buf); + + if (u_savedel((linenr_T)lo, (long)n) == FAIL) +! PyErr_SetVim(_("cannot save undo information")); + else + { + for (i = 0; i < n; ++i) + { + if (ml_delete((linenr_T)lo, FALSE) == FAIL) + { +! PyErr_SetVim(_("cannot delete line")); + break; + } + } +--- 3654,3667 ---- + switch_buffer(&savebuf, buf); + + if (u_savedel((linenr_T)lo, (long)n) == FAIL) +! PyErr_SET_VIM("cannot save undo information"); + else + { + for (i = 0; i < n; ++i) + { + if (ml_delete((linenr_T)lo, FALSE) == FAIL) + { +! PyErr_SET_VIM("cannot delete line"); + break; + } + } +*************** +*** 3721,3727 **** + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)(lo-1), (linenr_T)hi) == FAIL) +! PyErr_SetVim(_("cannot save undo information")); + + /* If the size of the range is reducing (ie, new_len < old_len) we + * need to delete some old_len. We do this at the start, by +--- 3722,3728 ---- + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)(lo-1), (linenr_T)hi) == FAIL) +! PyErr_SET_VIM("cannot save undo information"); + + /* If the size of the range is reducing (ie, new_len < old_len) we + * need to delete some old_len. We do this at the start, by +*************** +*** 3732,3738 **** + for (i = 0; i < old_len - new_len; ++i) + if (ml_delete((linenr_T)lo, FALSE) == FAIL) + { +! PyErr_SetVim(_("cannot delete line")); + break; + } + extra -= i; +--- 3733,3739 ---- + for (i = 0; i < old_len - new_len; ++i) + if (ml_delete((linenr_T)lo, FALSE) == FAIL) + { +! PyErr_SET_VIM("cannot delete line"); + break; + } + extra -= i; +*************** +*** 3748,3754 **** + if (ml_replace((linenr_T)(lo+i), (char_u *)array[i], FALSE) + == FAIL) + { +! PyErr_SetVim(_("cannot replace line")); + break; + } + } +--- 3749,3755 ---- + if (ml_replace((linenr_T)(lo+i), (char_u *)array[i], FALSE) + == FAIL) + { +! PyErr_SET_VIM("cannot replace line"); + break; + } + } +*************** +*** 3766,3772 **** + if (ml_append((linenr_T)(lo + i - 1), + (char_u *)array[i], 0, FALSE) == FAIL) + { +! PyErr_SetVim(_("cannot insert line")); + break; + } + vim_free(array[i]); +--- 3767,3773 ---- + if (ml_append((linenr_T)(lo + i - 1), + (char_u *)array[i], 0, FALSE) == FAIL) + { +! PyErr_SET_VIM("cannot insert line"); + break; + } + vim_free(array[i]); +*************** +*** 3843,3851 **** + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)n, (linenr_T)(n+1)) == FAIL) +! PyErr_SetVim(_("cannot save undo information")); + else if (ml_append((linenr_T)n, (char_u *)str, 0, FALSE) == FAIL) +! PyErr_SetVim(_("cannot insert line")); + else + appended_lines_mark((linenr_T)n, 1L); + +--- 3844,3852 ---- + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)n, (linenr_T)(n+1)) == FAIL) +! PyErr_SET_VIM("cannot save undo information"); + else if (ml_append((linenr_T)n, (char_u *)str, 0, FALSE) == FAIL) +! PyErr_SET_VIM("cannot insert line"); + else + appended_lines_mark((linenr_T)n, 1L); + +*************** +*** 3894,3900 **** + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)n, (linenr_T)(n + 1)) == FAIL) +! PyErr_SetVim(_("cannot save undo information")); + else + { + for (i = 0; i < size; ++i) +--- 3895,3901 ---- + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)n, (linenr_T)(n + 1)) == FAIL) +! PyErr_SET_VIM("cannot save undo information"); + else + { + for (i = 0; i < size; ++i) +*************** +*** 3902,3908 **** + if (ml_append((linenr_T)(n + i), + (char_u *)array[i], 0, FALSE) == FAIL) + { +! PyErr_SetVim(_("cannot insert line")); + + /* Free the rest of the lines */ + while (i < size) +--- 3903,3909 ---- + if (ml_append((linenr_T)(n + i), + (char_u *)array[i], 0, FALSE) == FAIL) + { +! PyErr_SET_VIM("cannot insert line"); + + /* Free the rest of the lines */ + while (i < size) +*************** +*** 3955,3961 **** + { + if (self->buf == INVALID_BUFFER_VALUE) + { +! PyErr_SetVim(_("attempt to refer to deleted buffer")); + return -1; + } + +--- 3956,3962 ---- + { + if (self->buf == INVALID_BUFFER_VALUE) + { +! PyErr_SET_VIM("attempt to refer to deleted buffer"); + return -1; + } + +*************** +*** 3976,3982 **** + + if (n < 0 || n > end - start) + { +! PyErr_SetString(PyExc_IndexError, _("line number out of range")); + return NULL; + } + +--- 3977,3983 ---- + + if (n < 0 || n > end - start) + { +! PyErr_SET_STRING(PyExc_IndexError, "line number out of range"); + return NULL; + } + +*************** +*** 4026,4032 **** + + if (n < 0 || n > end - start) + { +! PyErr_SetString(PyExc_IndexError, _("line number out of range")); + return -1; + } + +--- 4027,4033 ---- + + if (n < 0 || n > end - start) + { +! PyErr_SET_STRING(PyExc_IndexError, "line number out of range"); + return -1; + } + +*************** +*** 4098,4104 **** + + if (n < 0 || n > max) + { +! PyErr_SetString(PyExc_IndexError, _("line number out of range")); + return NULL; + } + +--- 4099,4105 ---- + + if (n < 0 || n > max) + { +! PyErr_SET_STRING(PyExc_IndexError, "line number out of range"); + return NULL; + } + +*************** +*** 4381,4387 **** + + if (r == FAIL) + { +! PyErr_SetVim(_("failed to rename buffer")); + return -1; + } + return 0; +--- 4382,4388 ---- + + if (r == FAIL) + { +! PyErr_SET_VIM("failed to rename buffer"); + return -1; + } + return 0; +*************** +*** 4416,4423 **** + + if (pmark[0] == '\0' || pmark[1] != '\0') + { +! PyErr_SetString(PyExc_ValueError, +! _("mark name must be a single character")); + return NULL; + } + +--- 4417,4424 ---- + + if (pmark[0] == '\0' || pmark[1] != '\0') + { +! PyErr_SET_STRING(PyExc_ValueError, +! "mark name must be a single character"); + return NULL; + } + +*************** +*** 4434,4440 **** + + if (posp == NULL) + { +! PyErr_SetVim(_("invalid mark name")); + return NULL; + } + +--- 4435,4441 ---- + + if (posp == NULL) + { +! PyErr_SET_VIM("invalid mark name"); + return NULL; + } + +*************** +*** 4529,4535 **** + bnr = PyLong_AsLong(keyObject); + else + { +! PyErr_SetString(PyExc_TypeError, _("key must be integer")); + return NULL; + } + +--- 4530,4536 ---- + bnr = PyLong_AsLong(keyObject); + else + { +! PyErr_SET_STRING(PyExc_TypeError, "key must be integer"); + return NULL; + } + +*************** +*** 4667,4673 **** + + if (value->ob_type != &BufferType) + { +! PyErr_SetString(PyExc_TypeError, _("expected vim.Buffer object")); + return -1; + } + +--- 4668,4674 ---- + + if (value->ob_type != &BufferType) + { +! PyErr_SET_STRING(PyExc_TypeError, "expected vim.Buffer object"); + return -1; + } + +*************** +*** 4680,4686 **** + { + if (VimTryEnd()) + return -1; +! PyErr_SetVim(_("failed to switch to given buffer")); + return -1; + } + +--- 4681,4687 ---- + { + if (VimTryEnd()) + return -1; +! PyErr_SET_VIM("failed to switch to given buffer"); + return -1; + } + +*************** +*** 4692,4698 **** + + if (value->ob_type != &WindowType) + { +! PyErr_SetString(PyExc_TypeError, _("expected vim.Window object")); + return -1; + } + +--- 4693,4699 ---- + + if (value->ob_type != &WindowType) + { +! PyErr_SET_STRING(PyExc_TypeError, "expected vim.Window object"); + return -1; + } + +*************** +*** 4702,4709 **** + + if (!count) + { +! PyErr_SetString(PyExc_ValueError, +! _("failed to find window in the current tab page")); + return -1; + } + +--- 4703,4710 ---- + + if (!count) + { +! PyErr_SET_STRING(PyExc_ValueError, +! "failed to find window in the current tab page"); + return -1; + } + +*************** +*** 4713,4720 **** + { + if (VimTryEnd()) + return -1; +! PyErr_SetString(PyExc_RuntimeError, +! _("did not switch to the specified window")); + return -1; + } + +--- 4714,4721 ---- + { + if (VimTryEnd()) + return -1; +! PyErr_SET_STRING(PyExc_RuntimeError, +! "did not switch to the specified window"); + return -1; + } + +*************** +*** 4724,4730 **** + { + if (value->ob_type != &TabPageType) + { +! PyErr_SetString(PyExc_TypeError, _("expected vim.TabPage object")); + return -1; + } + +--- 4725,4731 ---- + { + if (value->ob_type != &TabPageType) + { +! PyErr_SET_STRING(PyExc_TypeError, "expected vim.TabPage object"); + return -1; + } + +*************** +*** 4737,4744 **** + { + if (VimTryEnd()) + return -1; +! PyErr_SetString(PyExc_RuntimeError, +! _("did not switch to the specified tab page")); + return -1; + } + +--- 4738,4745 ---- + { + if (VimTryEnd()) + return -1; +! PyErr_SET_STRING(PyExc_RuntimeError, +! "did not switch to the specified tab page"); + return -1; + } + +*************** +*** 5005,5011 **** + clear_tv(&di->di_tv); + vim_free(di); + dict_unref(dict); +! PyErr_SetVim(_("failed to add key to dictionary")); + return -1; + } + } +--- 5006,5012 ---- + clear_tv(&di->di_tv); + vim_free(di); + dict_unref(dict); +! PyErr_SET_VIM("failed to add key to dictionary"); + return -1; + } + } +*************** +*** 5107,5113 **** + Py_DECREF(iterator); + dictitem_free(di); + dict_unref(dict); +! PyErr_SetVim(_("failed to add key to dictionary")); + return -1; + } + } +--- 5108,5114 ---- + Py_DECREF(iterator); + dictitem_free(di); + dict_unref(dict); +! PyErr_SET_VIM("failed to add key to dictionary"); + return -1; + } + } +*************** +*** 5215,5222 **** + r = convert_dl(obj, tv, pymap_to_tv, lookup_dict); + else + { +! PyErr_SetString(PyExc_TypeError, +! _("unable to convert object to vim dictionary")); + r = -1; + } + Py_DECREF(lookup_dict); +--- 5216,5223 ---- + r = convert_dl(obj, tv, pymap_to_tv, lookup_dict); + else + { +! PyErr_SET_STRING(PyExc_TypeError, +! "unable to convert object to vim dictionary"); + r = -1; + } + Py_DECREF(lookup_dict); +*************** +*** 5325,5332 **** + return convert_dl(obj, tv, pymap_to_tv, lookup_dict); + else + { +! PyErr_SetString(PyExc_TypeError, +! _("unable to convert to vim structure")); + return -1; + } + return 0; +--- 5326,5333 ---- + return convert_dl(obj, tv, pymap_to_tv, lookup_dict); + else + { +! PyErr_SET_STRING(PyExc_TypeError, +! "unable to convert to vim structure"); + return -1; + } + return 0; +*************** +*** 5337,5343 **** + { + if (tv == NULL) + { +! PyErr_SetVim(_("NULL reference passed")); + return NULL; + } + switch (tv->v_type) +--- 5338,5344 ---- + { + if (tv == NULL) + { +! PyErr_SET_VIM("NULL reference passed"); + return NULL; + } + switch (tv->v_type) +*************** +*** 5362,5368 **** + Py_INCREF(Py_None); + return Py_None; + default: +! PyErr_SetVim(_("internal error: invalid value type")); + return NULL; + } + } +--- 5363,5369 ---- + Py_INCREF(Py_None); + return Py_None; + default: +! PyErr_SET_VIM("internal error: invalid value type"); + return NULL; + } + } +*** ../vim-7.3.1228/src/if_python3.c 2013-06-23 13:11:14.000000000 +0200 +--- src/if_python3.c 2013-06-23 13:25:51.000000000 +0200 +*************** +*** 1169,1175 **** + } + else + { +! PyErr_SetString(PyExc_TypeError, _("index must be int or slice")); + return NULL; + } + } +--- 1169,1175 ---- + } + else + { +! PyErr_SET_STRING(PyExc_TypeError, "index must be int or slice"); + return NULL; + } + } +*************** +*** 1203,1209 **** + } + else + { +! PyErr_SetString(PyExc_TypeError, _("index must be int or slice")); + return -1; + } + } +--- 1203,1209 ---- + } + else + { +! PyErr_SET_STRING(PyExc_TypeError, "index must be int or slice"); + return -1; + } + } +*************** +*** 1285,1291 **** + } + else + { +! PyErr_SetString(PyExc_TypeError, _("index must be int or slice")); + return NULL; + } + } +--- 1285,1291 ---- + } + else + { +! PyErr_SET_STRING(PyExc_TypeError, "index must be int or slice"); + return NULL; + } + } +*************** +*** 1312,1318 **** + } + else + { +! PyErr_SetString(PyExc_TypeError, _("index must be int or slice")); + return -1; + } + } +--- 1312,1318 ---- + } + else + { +! PyErr_SET_STRING(PyExc_TypeError, "index must be int or slice"); + return -1; + } + } +*************** +*** 1491,1497 **** + } + else + { +! PyErr_SetString(PyExc_TypeError, _("index must be int or slice")); + return NULL; + } + } +--- 1491,1497 ---- + } + else + { +! PyErr_SET_STRING(PyExc_TypeError, "index must be int or slice"); + return NULL; + } + } +*************** +*** 1515,1521 **** + } + else + { +! PyErr_SetString(PyExc_TypeError, _("index must be int or slice")); + return -1; + } + } +--- 1515,1521 ---- + } + else + { +! PyErr_SET_STRING(PyExc_TypeError, "index must be int or slice"); + return -1; + } + } +*** ../vim-7.3.1228/src/version.c 2013-06-23 13:11:14.000000000 +0200 +--- src/version.c 2013-06-23 13:12:35.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1229, + /**/ + +-- +There is a fine line between courage and foolishness. +Unfortunately, it's not a fence. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 04684c3711698534efce763656ed6c9909d6c5aa Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:26 +0200 Subject: [PATCH 1123/3340] - patchlevel 1230 --- 7.3.1230 | 3406 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 3406 insertions(+) create mode 100644 7.3.1230 diff --git a/7.3.1230 b/7.3.1230 new file mode 100644 index 00000000..d275d09c --- /dev/null +++ b/7.3.1230 @@ -0,0 +1,3406 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1230 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1230 +Problem: Python: Exception messages are not clear. +Solution: Make exception messages more verbose. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c, + src/testdir/test86.ok, src/testdir/test87.ok + + +*** ../vim-7.3.1229/src/if_py_both.h 2013-06-23 13:28:11.000000000 +0200 +--- src/if_py_both.h 2013-06-23 13:31:16.000000000 +0200 +*************** +*** 29,37 **** +--- 29,53 ---- + #define PyErr_SET_STRING(exc, str) PyErr_SetString(exc, _(str)) + #define PyErr_SetVim(str) PyErr_SetString(VimError, str) + #define PyErr_SET_VIM(str) PyErr_SET_STRING(VimError, str) ++ #define PyErr_FORMAT(exc, str, tail) PyErr_Format(exc, _(str), tail) ++ #define PyErr_VIM_FORMAT(str, tail) PyErr_FORMAT(VimError, str, tail) ++ ++ #define Py_TYPE_NAME(obj) (obj->ob_type->tp_name == NULL \ ++ ? "(NULL)" \ ++ : obj->ob_type->tp_name) + + #define RAISE_NO_EMPTY_KEYS PyErr_SET_STRING(PyExc_ValueError, \ + "empty keys are not allowed") ++ #define RAISE_LOCKED(type) PyErr_SET_VIM(_(type " is locked")) ++ #define RAISE_LOCKED_DICTIONARY RAISE_LOCKED("dictionary") ++ #define RAISE_LOCKED_LIST RAISE_LOCKED("list") ++ #define RAISE_UNDO_FAIL PyErr_SET_VIM("cannot save undo information") ++ #define RAISE_LINE_FAIL(act) PyErr_SET_VIM("cannot " act " line") ++ #define RAISE_KEY_ADD_FAIL(key) \ ++ PyErr_VIM_FORMAT("failed to add key '%s' to dictionary", key) ++ #define RAISE_INVALID_INDEX_TYPE(idx) \ ++ PyErr_FORMAT(PyExc_TypeError, "index must be int or slice, not %s", \ ++ Py_TYPE_NAME(idx)); + + #define INVALID_BUFFER_VALUE ((buf_T *)(-1)) + #define INVALID_WINDOW_VALUE ((win_T *)(-1)) +*************** +*** 122,128 **** + } + else + { +! PyErr_SET_STRING(PyExc_TypeError, "object must be string"); + return NULL; + } + +--- 138,150 ---- + } + else + { +! PyErr_FORMAT(PyExc_TypeError, +! #if PY_MAJOR_VERSION < 3 +! "expected str() or unicode() instance, but got %s" +! #else +! "expected bytes() or str() instance, but got %s" +! #endif +! , Py_TYPE_NAME(object)); + return NULL; + } + +*************** +*** 231,237 **** + return 0; + } + +! PyErr_SET_STRING(PyExc_AttributeError, "invalid attribute"); + return -1; + } + +--- 253,259 ---- + return 0; + } + +! PyErr_FORMAT(PyExc_AttributeError, "invalid attribute: %s", name); + return -1; + } + +*************** +*** 967,977 **** + { + PyObject *fd, *pathname, *description; + +! if (!PyTuple_Check(find_module_result) +! || PyTuple_GET_SIZE(find_module_result) != 3) + { +! PyErr_SET_STRING(PyExc_TypeError, +! "expected 3-tuple as imp.find_module() result"); + return NULL; + } + +--- 989,1007 ---- + { + PyObject *fd, *pathname, *description; + +! if (!PyTuple_Check(find_module_result)) + { +! PyErr_FORMAT(PyExc_TypeError, +! "expected 3-tuple as imp.find_module() result, but got %s", +! Py_TYPE_NAME(find_module_result)); +! return NULL; +! } +! if (PyTuple_GET_SIZE(find_module_result) != 3) +! { +! PyErr_FORMAT(PyExc_TypeError, +! "expected 3-tuple as imp.find_module() result, but got " +! "tuple of size %d", +! (int) PyTuple_GET_SIZE(find_module_result)); + return NULL; + } + +*************** +*** 1377,1383 **** + } + else + { +! PyErr_SET_STRING(PyExc_AttributeError, "cannot set this attribute"); + return -1; + } + } +--- 1407,1413 ---- + } + else + { +! PyErr_FORMAT(PyExc_AttributeError, "cannot set attribute %s", name); + return -1; + } + } +*************** +*** 1459,1465 **** + { + if (dict->dv_lock) + { +! PyErr_SET_VIM("dict is locked"); + Py_DECREF(r); + return NULL; + } +--- 1489,1495 ---- + { + if (dict->dv_lock) + { +! RAISE_LOCKED_DICTIONARY; + Py_DECREF(r); + return NULL; + } +*************** +*** 1562,1568 **** + + if (dict->dv_lock) + { +! PyErr_SET_VIM("dict is locked"); + return -1; + } + +--- 1592,1598 ---- + + if (dict->dv_lock) + { +! RAISE_LOCKED_DICTIONARY; + return -1; + } + +*************** +*** 1614,1623 **** + + if (dict_add(dict, di) == FAIL) + { +- Py_XDECREF(todecref); + vim_free(di); + dictitem_free(di); +! PyErr_SET_VIM("failed to add key to dictionary"); + return -1; + } + } +--- 1644,1653 ---- + + if (dict_add(dict, di) == FAIL) + { + vim_free(di); + dictitem_free(di); +! RAISE_KEY_ADD_FAIL(key); +! Py_XDECREF(todecref); + return -1; + } + } +*************** +*** 1725,1731 **** + + if (dict->dv_lock) + { +! PyErr_SET_VIM("dict is locked"); + return NULL; + } + +--- 1755,1761 ---- + + if (dict->dv_lock) + { +! RAISE_LOCKED_DICTIONARY; + return NULL; + } + +*************** +*** 1781,1788 **** + { + Py_DECREF(iterator); + Py_DECREF(fast); +! PyErr_SET_STRING(PyExc_ValueError, +! "expected sequence element of size 2"); + return NULL; + } + +--- 1811,1820 ---- + { + Py_DECREF(iterator); + Py_DECREF(fast); +! PyErr_FORMAT(PyExc_ValueError, +! "expected sequence element of size 2, " +! "but got sequence of size %d", +! PySequence_Fast_GET_SIZE(fast)); + return NULL; + } + +*************** +*** 1823,1831 **** + + if (dict_add(dict, di) == FAIL) + { + Py_DECREF(iterator); + dictitem_free(di); +- PyErr_SET_VIM("failed to add key to dictionary"); + return NULL; + } + } +--- 1855,1863 ---- + + if (dict_add(dict, di) == FAIL) + { ++ RAISE_KEY_ADD_FAIL(di->di_key); + Py_DECREF(iterator); + dictitem_free(di); + return NULL; + } + } +*************** +*** 2085,2091 **** + li = list_find(self->list, (long) index); + if (li == NULL) + { +! PyErr_SET_VIM("internal error: failed to get vim list item"); + return NULL; + } + return ConvertToPyObject(&li->li_tv); +--- 2117,2125 ---- + li = list_find(self->list, (long) index); + if (li == NULL) + { +! /* No more suitable format specifications in python-2.3 */ +! PyErr_VIM_FORMAT("internal error: failed to get vim list item %d", +! (int) index); + return NULL; + } + return ConvertToPyObject(&li->li_tv); +*************** +*** 2198,2204 **** + + if (l->lv_lock) + { +! PyErr_SET_VIM("list is locked"); + return -1; + } + if (index>length || (index==length && obj==NULL)) +--- 2232,2238 ---- + + if (l->lv_lock) + { +! RAISE_LOCKED_LIST; + return -1; + } + if (index>length || (index==length && obj==NULL)) +*************** +*** 2252,2258 **** + + if (l->lv_lock) + { +! PyErr_SET_VIM("list is locked"); + return -1; + } + +--- 2286,2292 ---- + + if (l->lv_lock) + { +! RAISE_LOCKED_LIST; + return -1; + } + +*************** +*** 2265,2271 **** + li = list_find(l, (long) first); + if (li == NULL) + { +! PyErr_SET_VIM("internal error: no vim list item"); + return -1; + } + if (last > first) +--- 2299,2305 ---- + li = list_find(l, (long) first); + if (li == NULL) + { +! PyErr_VIM_FORMAT("internal error: no vim list item %d", (int)first); + return -1; + } + if (last > first) +*************** +*** 2315,2321 **** + + if (l->lv_lock) + { +! PyErr_SET_VIM("list is locked"); + return NULL; + } + +--- 2349,2355 ---- + + if (l->lv_lock) + { +! RAISE_LOCKED_LIST; + return NULL; + } + +*************** +*** 2375,2381 **** + } + else + { +! PyErr_SET_STRING(PyExc_AttributeError, "cannot set this attribute"); + return -1; + } + } +--- 2409,2415 ---- + } + else + { +! PyErr_FORMAT(PyExc_AttributeError, "cannot set attribute %s", name); + return -1; + } + } +*************** +*** 2410,2417 **** + { + if (!translated_function_exists(name)) + { +! PyErr_SET_STRING(PyExc_ValueError, +! "unnamed function does not exist"); + return NULL; + } + self->name = vim_strsave(name); +--- 2444,2451 ---- + { + if (!translated_function_exists(name)) + { +! PyErr_FORMAT(PyExc_ValueError, +! "unnamed function %s does not exist", name); + return NULL; + } + self->name = vim_strsave(name); +*************** +*** 2422,2428 **** + vim_strchr(name, AUTOLOAD_CHAR) == NULL)) + == NULL) + { +! PyErr_SET_STRING(PyExc_ValueError, "function does not exist"); + return NULL; + } + +--- 2456,2462 ---- + vim_strchr(name, AUTOLOAD_CHAR) == NULL)) + == NULL) + { +! PyErr_FORMAT(PyExc_ValueError, "function %s does not exist", name); + return NULL; + } + +*************** +*** 2515,2521 **** + else if (error != OK) + { + result = NULL; +! PyErr_SET_VIM("failed to run function"); + } + else + result = ConvertToPyObject(&rettv); +--- 2549,2555 ---- + else if (error != OK) + { + result = NULL; +! PyErr_VIM_FORMAT("failed to run function %s", (char *)name); + } + else + result = ConvertToPyObject(&rettv); +*************** +*** 2770,2783 **** + { + if (self->opt_type == SREQ_GLOBAL) + { +! PyErr_SET_STRING(PyExc_ValueError, "unable to unset global option"); + Py_XDECREF(todecref); + return -1; + } + else if (!(flags & SOPT_GLOBAL)) + { +! PyErr_SET_STRING(PyExc_ValueError, "unable to unset option " +! "without global value"); + Py_XDECREF(todecref); + return -1; + } +--- 2804,2819 ---- + { + if (self->opt_type == SREQ_GLOBAL) + { +! PyErr_FORMAT(PyExc_ValueError, +! "unable to unset global option %s", key); + Py_XDECREF(todecref); + return -1; + } + else if (!(flags & SOPT_GLOBAL)) + { +! PyErr_FORMAT(PyExc_ValueError, +! "unable to unset option %s " +! "which does not have global value", key); + Py_XDECREF(todecref); + return -1; + } +*************** +*** 3195,3201 **** + + if (strcmp(name, "buffer") == 0) + { +! PyErr_SET_STRING(PyExc_TypeError, "readonly attribute"); + return -1; + } + else if (strcmp(name, "cursor") == 0) +--- 3231,3237 ---- + + if (strcmp(name, "buffer") == 0) + { +! PyErr_SET_STRING(PyExc_TypeError, "readonly attribute: buffer"); + return -1; + } + else if (strcmp(name, "cursor") == 0) +*************** +*** 3558,3566 **** + VimTryStart(); + + if (u_savedel((linenr_T)n, 1L) == FAIL) +! PyErr_SET_VIM("cannot save undo information"); + else if (ml_delete((linenr_T)n, FALSE) == FAIL) +! PyErr_SET_VIM("cannot delete line"); + else + { + if (buf == savebuf) +--- 3594,3602 ---- + VimTryStart(); + + if (u_savedel((linenr_T)n, 1L) == FAIL) +! RAISE_UNDO_FAIL; + else if (ml_delete((linenr_T)n, FALSE) == FAIL) +! RAISE_LINE_FAIL("delete"); + else + { + if (buf == savebuf) +*************** +*** 3594,3605 **** + + if (u_savesub((linenr_T)n) == FAIL) + { +! PyErr_SET_VIM("cannot save undo information"); + vim_free(save); + } + else if (ml_replace((linenr_T)n, (char_u *)save, FALSE) == FAIL) + { +! PyErr_SET_VIM("cannot replace line"); + vim_free(save); + } + else +--- 3630,3641 ---- + + if (u_savesub((linenr_T)n) == FAIL) + { +! RAISE_UNDO_FAIL; + vim_free(save); + } + else if (ml_replace((linenr_T)n, (char_u *)save, FALSE) == FAIL) + { +! RAISE_LINE_FAIL("replace"); + vim_free(save); + } + else +*************** +*** 3654,3667 **** + switch_buffer(&savebuf, buf); + + if (u_savedel((linenr_T)lo, (long)n) == FAIL) +! PyErr_SET_VIM("cannot save undo information"); + else + { + for (i = 0; i < n; ++i) + { + if (ml_delete((linenr_T)lo, FALSE) == FAIL) + { +! PyErr_SET_VIM("cannot delete line"); + break; + } + } +--- 3690,3703 ---- + switch_buffer(&savebuf, buf); + + if (u_savedel((linenr_T)lo, (long)n) == FAIL) +! RAISE_UNDO_FAIL; + else + { + for (i = 0; i < n; ++i) + { + if (ml_delete((linenr_T)lo, FALSE) == FAIL) + { +! RAISE_LINE_FAIL("delete"); + break; + } + } +*************** +*** 3722,3728 **** + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)(lo-1), (linenr_T)hi) == FAIL) +! PyErr_SET_VIM("cannot save undo information"); + + /* If the size of the range is reducing (ie, new_len < old_len) we + * need to delete some old_len. We do this at the start, by +--- 3758,3764 ---- + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)(lo-1), (linenr_T)hi) == FAIL) +! RAISE_UNDO_FAIL; + + /* If the size of the range is reducing (ie, new_len < old_len) we + * need to delete some old_len. We do this at the start, by +*************** +*** 3733,3739 **** + for (i = 0; i < old_len - new_len; ++i) + if (ml_delete((linenr_T)lo, FALSE) == FAIL) + { +! PyErr_SET_VIM("cannot delete line"); + break; + } + extra -= i; +--- 3769,3775 ---- + for (i = 0; i < old_len - new_len; ++i) + if (ml_delete((linenr_T)lo, FALSE) == FAIL) + { +! RAISE_LINE_FAIL("delete"); + break; + } + extra -= i; +*************** +*** 3749,3755 **** + if (ml_replace((linenr_T)(lo+i), (char_u *)array[i], FALSE) + == FAIL) + { +! PyErr_SET_VIM("cannot replace line"); + break; + } + } +--- 3785,3791 ---- + if (ml_replace((linenr_T)(lo+i), (char_u *)array[i], FALSE) + == FAIL) + { +! RAISE_LINE_FAIL("replace"); + break; + } + } +*************** +*** 3767,3773 **** + if (ml_append((linenr_T)(lo + i - 1), + (char_u *)array[i], 0, FALSE) == FAIL) + { +! PyErr_SET_VIM("cannot insert line"); + break; + } + vim_free(array[i]); +--- 3803,3809 ---- + if (ml_append((linenr_T)(lo + i - 1), + (char_u *)array[i], 0, FALSE) == FAIL) + { +! RAISE_LINE_FAIL("insert"); + break; + } + vim_free(array[i]); +*************** +*** 3844,3852 **** + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)n, (linenr_T)(n+1)) == FAIL) +! PyErr_SET_VIM("cannot save undo information"); + else if (ml_append((linenr_T)n, (char_u *)str, 0, FALSE) == FAIL) +! PyErr_SET_VIM("cannot insert line"); + else + appended_lines_mark((linenr_T)n, 1L); + +--- 3880,3888 ---- + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)n, (linenr_T)(n+1)) == FAIL) +! RAISE_UNDO_FAIL; + else if (ml_append((linenr_T)n, (char_u *)str, 0, FALSE) == FAIL) +! RAISE_LINE_FAIL("insert"); + else + appended_lines_mark((linenr_T)n, 1L); + +*************** +*** 3895,3901 **** + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)n, (linenr_T)(n + 1)) == FAIL) +! PyErr_SET_VIM("cannot save undo information"); + else + { + for (i = 0; i < size; ++i) +--- 3931,3937 ---- + switch_buffer(&savebuf, buf); + + if (u_save((linenr_T)n, (linenr_T)(n + 1)) == FAIL) +! RAISE_UNDO_FAIL; + else + { + for (i = 0; i < size; ++i) +*************** +*** 3903,3909 **** + if (ml_append((linenr_T)(n + i), + (char_u *)array[i], 0, FALSE) == FAIL) + { +! PyErr_SET_VIM("cannot insert line"); + + /* Free the rest of the lines */ + while (i < size) +--- 3939,3945 ---- + if (ml_append((linenr_T)(n + i), + (char_u *)array[i], 0, FALSE) == FAIL) + { +! RAISE_LINE_FAIL("insert"); + + /* Free the rest of the lines */ + while (i < size) +*************** +*** 4668,4674 **** + + if (value->ob_type != &BufferType) + { +! PyErr_SET_STRING(PyExc_TypeError, "expected vim.Buffer object"); + return -1; + } + +--- 4704,4712 ---- + + if (value->ob_type != &BufferType) + { +! PyErr_FORMAT(PyExc_TypeError, +! "expected vim.Buffer object, but got %s", +! Py_TYPE_NAME(value)); + return -1; + } + +*************** +*** 4681,4687 **** + { + if (VimTryEnd()) + return -1; +! PyErr_SET_VIM("failed to switch to given buffer"); + return -1; + } + +--- 4719,4725 ---- + { + if (VimTryEnd()) + return -1; +! PyErr_VIM_FORMAT("failed to switch to buffer %d", count); + return -1; + } + +*************** +*** 4693,4699 **** + + if (value->ob_type != &WindowType) + { +! PyErr_SET_STRING(PyExc_TypeError, "expected vim.Window object"); + return -1; + } + +--- 4731,4739 ---- + + if (value->ob_type != &WindowType) + { +! PyErr_FORMAT(PyExc_TypeError, +! "expected vim.Window object, but got %s", +! Py_TYPE_NAME(value)); + return -1; + } + +*************** +*** 4725,4731 **** + { + if (value->ob_type != &TabPageType) + { +! PyErr_SET_STRING(PyExc_TypeError, "expected vim.TabPage object"); + return -1; + } + +--- 4765,4773 ---- + { + if (value->ob_type != &TabPageType) + { +! PyErr_FORMAT(PyExc_TypeError, +! "expected vim.TabPage object, but got %s", +! Py_TYPE_NAME(value)); + return -1; + } + +*************** +*** 5003,5012 **** + + if (dict_add(dict, di) == FAIL) + { + clear_tv(&di->di_tv); + vim_free(di); + dict_unref(dict); +- PyErr_SET_VIM("failed to add key to dictionary"); + return -1; + } + } +--- 5045,5054 ---- + + if (dict_add(dict, di) == FAIL) + { ++ RAISE_KEY_ADD_FAIL(di->di_key); + clear_tv(&di->di_tv); + vim_free(di); + dict_unref(dict); + return -1; + } + } +*************** +*** 5105,5114 **** + + if (dict_add(dict, di) == FAIL) + { + Py_DECREF(iterator); + dictitem_free(di); + dict_unref(dict); +- PyErr_SET_VIM("failed to add key to dictionary"); + return -1; + } + } +--- 5147,5156 ---- + + if (dict_add(dict, di) == FAIL) + { ++ RAISE_KEY_ADD_FAIL(di->di_key); + Py_DECREF(iterator); + dictitem_free(di); + dict_unref(dict); + return -1; + } + } +*************** +*** 5216,5223 **** + r = convert_dl(obj, tv, pymap_to_tv, lookup_dict); + else + { +! PyErr_SET_STRING(PyExc_TypeError, +! "unable to convert object to vim dictionary"); + r = -1; + } + Py_DECREF(lookup_dict); +--- 5258,5266 ---- + r = convert_dl(obj, tv, pymap_to_tv, lookup_dict); + else + { +! PyErr_FORMAT(PyExc_TypeError, +! "unable to convert %s to vim dictionary", +! Py_TYPE_NAME(obj)); + r = -1; + } + Py_DECREF(lookup_dict); +*************** +*** 5326,5333 **** + return convert_dl(obj, tv, pymap_to_tv, lookup_dict); + else + { +! PyErr_SET_STRING(PyExc_TypeError, +! "unable to convert to vim structure"); + return -1; + } + return 0; +--- 5369,5377 ---- + return convert_dl(obj, tv, pymap_to_tv, lookup_dict); + else + { +! PyErr_FORMAT(PyExc_TypeError, +! "unable to convert %s to vim structure", +! Py_TYPE_NAME(obj)); + return -1; + } + return 0; +*************** +*** 5338,5344 **** + { + if (tv == NULL) + { +! PyErr_SET_VIM("NULL reference passed"); + return NULL; + } + switch (tv->v_type) +--- 5382,5388 ---- + { + if (tv == NULL) + { +! PyErr_SET_VIM("internal error: NULL reference passed"); + return NULL; + } + switch (tv->v_type) +*** ../vim-7.3.1229/src/if_python3.c 2013-06-23 13:28:11.000000000 +0200 +--- src/if_python3.c 2013-06-23 13:31:16.000000000 +0200 +*************** +*** 122,127 **** +--- 122,128 ---- + # define PyDict_SetItemString py3_PyDict_SetItemString + # define PyErr_BadArgument py3_PyErr_BadArgument + # define PyErr_Clear py3_PyErr_Clear ++ # define PyErr_Format py3_PyErr_Format + # define PyErr_PrintEx py3_PyErr_PrintEx + # define PyErr_NoMemory py3_PyErr_NoMemory + # define PyErr_Occurred py3_PyErr_Occurred +*************** +*** 337,342 **** +--- 338,344 ---- + static void* (*py3_PyMem_Malloc)(size_t); + static int (*py3_Py_IsInitialized)(void); + static void (*py3_PyErr_Clear)(void); ++ static PyObject* (*py3_PyErr_Format)(PyObject *, const char *, ...); + static void (*py3_PyErr_PrintEx)(int); + static PyObject*(*py3__PyObject_Init)(PyObject *, PyTypeObject *); + static iternextfunc py3__PyObject_NextNotImplemented; +*************** +*** 485,490 **** +--- 487,493 ---- + {"_Py_FalseStruct", (PYTHON_PROC*)&py3__Py_FalseStruct}, + {"_Py_TrueStruct", (PYTHON_PROC*)&py3__Py_TrueStruct}, + {"PyErr_Clear", (PYTHON_PROC*)&py3_PyErr_Clear}, ++ {"PyErr_Format", (PYTHON_PROC*)&py3_PyErr_Format}, + {"PyErr_PrintEx", (PYTHON_PROC*)&py3_PyErr_PrintEx}, + {"PyObject_Init", (PYTHON_PROC*)&py3__PyObject_Init}, + {"PyModule_AddObject", (PYTHON_PROC*)&py3_PyModule_AddObject}, +*************** +*** 1169,1175 **** + } + else + { +! PyErr_SET_STRING(PyExc_TypeError, "index must be int or slice"); + return NULL; + } + } +--- 1172,1178 ---- + } + else + { +! RAISE_INVALID_INDEX_TYPE(idx); + return NULL; + } + } +*************** +*** 1203,1209 **** + } + else + { +! PyErr_SET_STRING(PyExc_TypeError, "index must be int or slice"); + return -1; + } + } +--- 1206,1212 ---- + } + else + { +! RAISE_INVALID_INDEX_TYPE(idx); + return -1; + } + } +*************** +*** 1285,1291 **** + } + else + { +! PyErr_SET_STRING(PyExc_TypeError, "index must be int or slice"); + return NULL; + } + } +--- 1288,1294 ---- + } + else + { +! RAISE_INVALID_INDEX_TYPE(idx); + return NULL; + } + } +*************** +*** 1312,1318 **** + } + else + { +! PyErr_SET_STRING(PyExc_TypeError, "index must be int or slice"); + return -1; + } + } +--- 1315,1321 ---- + } + else + { +! RAISE_INVALID_INDEX_TYPE(idx); + return -1; + } + } +*************** +*** 1491,1497 **** + } + else + { +! PyErr_SET_STRING(PyExc_TypeError, "index must be int or slice"); + return NULL; + } + } +--- 1494,1500 ---- + } + else + { +! RAISE_INVALID_INDEX_TYPE(idx); + return NULL; + } + } +*************** +*** 1515,1521 **** + } + else + { +! PyErr_SET_STRING(PyExc_TypeError, "index must be int or slice"); + return -1; + } + } +--- 1518,1524 ---- + } + else + { +! RAISE_INVALID_INDEX_TYPE(idx); + return -1; + } + } +*** ../vim-7.3.1229/src/if_python.c 2013-06-23 13:11:14.000000000 +0200 +--- src/if_python.c 2013-06-23 13:31:16.000000000 +0200 +*************** +*** 160,165 **** +--- 160,166 ---- + # define PyErr_BadArgument dll_PyErr_BadArgument + # define PyErr_NewException dll_PyErr_NewException + # define PyErr_Clear dll_PyErr_Clear ++ # define PyErr_Format dll_PyErr_Format + # define PyErr_PrintEx dll_PyErr_PrintEx + # define PyErr_NoMemory dll_PyErr_NoMemory + # define PyErr_Occurred dll_PyErr_Occurred +*************** +*** 301,306 **** +--- 302,308 ---- + static int(*dll_PyErr_BadArgument)(void); + static PyObject *(*dll_PyErr_NewException)(char *, PyObject *, PyObject *); + static void(*dll_PyErr_Clear)(void); ++ static PyObject*(*dll_PyErr_Format)(PyObject *, const char *, ...); + static void(*dll_PyErr_PrintEx)(int); + static PyObject*(*dll_PyErr_NoMemory)(void); + static PyObject*(*dll_PyErr_Occurred)(void); +*************** +*** 473,478 **** +--- 475,481 ---- + {"PyErr_BadArgument", (PYTHON_PROC*)&dll_PyErr_BadArgument}, + {"PyErr_NewException", (PYTHON_PROC*)&dll_PyErr_NewException}, + {"PyErr_Clear", (PYTHON_PROC*)&dll_PyErr_Clear}, ++ {"PyErr_Format", (PYTHON_PROC*)&dll_PyErr_Format}, + {"PyErr_PrintEx", (PYTHON_PROC*)&dll_PyErr_PrintEx}, + {"PyErr_NoMemory", (PYTHON_PROC*)&dll_PyErr_NoMemory}, + {"PyErr_Occurred", (PYTHON_PROC*)&dll_PyErr_Occurred}, +*** ../vim-7.3.1229/src/testdir/test86.ok 2013-06-23 13:00:40.000000000 +0200 +--- src/testdir/test86.ok 2013-06-23 13:44:43.000000000 +0200 +*************** +*** 439,544 **** + >> OutputSetattr + del sys.stdout.softspace:AttributeError:("can't delete OutputObject attributes",) + sys.stdout.softspace = []:TypeError:('softspace must be an integer',) +! sys.stdout.attr = None:AttributeError:('invalid attribute',) + >> OutputWrite + sys.stdout.write(None):TypeError:('coercing to Unicode: need string or buffer, NoneType found',) + >> OutputWriteLines + sys.stdout.writelines(None):TypeError:("'NoneType' object is not iterable",) + sys.stdout.writelines([1]):TypeError:('coercing to Unicode: need string or buffer, int found',) + > VimCommand +! vim.command(1):TypeError:('object must be string',) + > VimToPython + > VimEval +! vim.eval(1):TypeError:('object must be string',) + > VimEvalPy +! vim.bindeval(1):TypeError:('object must be string',) + > VimStrwidth +! vim.strwidth(1):TypeError:('object must be string',) + > Dictionary + >> DictionaryConstructor +! vim.Dictionary("abc"):ValueError:('expected sequence element of size 2',) + >> DictionarySetattr + del d.locked:AttributeError:('cannot delete vim.Dictionary attributes',) + d.locked = FailingTrue():NotImplementedError:() + vim.vvars.locked = False:TypeError:('cannot modify fixed dictionary',) +! d.scope = True:AttributeError:('cannot set this attribute',) +! d.xxx = True:AttributeError:('cannot set this attribute',) + >> _DictionaryItem + d.get("a", 2, 3):TypeError:('function takes at most 2 arguments (3 given)',) + >>> Testing StringToChars using d.get(%s) +! d.get(1):TypeError:('object must be string',) + d.get(u"\0"):TypeError:('expected string without null bytes',) + d.get("\0"):TypeError:('expected string without null bytes',) + <<< Finished + d.pop("a"):KeyError:('a',) +! dl.pop("a"):error:('dict is locked',) + >> DictionaryIterNext + for i in ned: ned["a"] = 1:RuntimeError:('hashtab changed during iteration',) + >> DictionaryAssItem +! dl["b"] = 1:error:('dict is locked',) + >>> Testing StringToChars using d[%s] = 1 +! d[1] = 1:TypeError:('object must be string',) + d[u"\0"] = 1:TypeError:('expected string without null bytes',) + d["\0"] = 1:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d["a"] = {%s : 1} +! d["a"] = {1 : 1}:TypeError:('object must be string',) + d["a"] = {u"\0" : 1}:TypeError:('expected string without null bytes',) + d["a"] = {"\0" : 1}:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : {%s : 1}} +! d["a"] = {"abc" : {1 : 1}}:TypeError:('object must be string',) + d["a"] = {"abc" : {u"\0" : 1}}:TypeError:('expected string without null bytes',) + d["a"] = {"abc" : {"\0" : 1}}:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : Mapping({%s : 1})} +! d["a"] = {"abc" : Mapping({1 : 1})}:TypeError:('object must be string',) + d["a"] = {"abc" : Mapping({u"\0" : 1})}:TypeError:('expected string without null bytes',) + d["a"] = {"abc" : Mapping({"\0" : 1})}:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : FailingIter()}:TypeError:('unable to convert to vim structure',) + d["a"] = {"abc" : FailingIterNext()}:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : None}:TypeError:('unable to convert to vim structure',) + d["a"] = {"abc" : {"": 1}}:ValueError:('empty keys are not allowed',) + d["a"] = {"abc" : {u"": 1}}:ValueError:('empty keys are not allowed',) + d["a"] = {"abc" : FailingMapping()}:NotImplementedError:() + d["a"] = {"abc" : FailingMappingKey()}:NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) +! d["a"] = Mapping({1 : 1}):TypeError:('object must be string',) + d["a"] = Mapping({u"\0" : 1}):TypeError:('expected string without null bytes',) + d["a"] = Mapping({"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : {%s : 1}}) +! d["a"] = Mapping({"abc" : {1 : 1}}):TypeError:('object must be string',) + d["a"] = Mapping({"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) + d["a"] = Mapping({"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : Mapping({%s : 1})}) +! d["a"] = Mapping({"abc" : Mapping({1 : 1})}):TypeError:('object must be string',) + d["a"] = Mapping({"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) + d["a"] = Mapping({"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : FailingIter()}):TypeError:('unable to convert to vim structure',) + d["a"] = Mapping({"abc" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : None}):TypeError:('unable to convert to vim structure',) + d["a"] = Mapping({"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) + d["a"] = Mapping({"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) + d["a"] = Mapping({"abc" : FailingMapping()}):NotImplementedError:() + d["a"] = Mapping({"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d["a"] = %s +! d["a"] = FailingIter():TypeError:('unable to convert to vim structure',) + d["a"] = FailingIterNext():NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = %s +! d["a"] = None:TypeError:('unable to convert to vim structure',) + d["a"] = {"": 1}:ValueError:('empty keys are not allowed',) + d["a"] = {u"": 1}:ValueError:('empty keys are not allowed',) + d["a"] = FailingMapping():NotImplementedError:() +--- 439,544 ---- + >> OutputSetattr + del sys.stdout.softspace:AttributeError:("can't delete OutputObject attributes",) + sys.stdout.softspace = []:TypeError:('softspace must be an integer',) +! sys.stdout.attr = None:AttributeError:('invalid attribute: attr',) + >> OutputWrite + sys.stdout.write(None):TypeError:('coercing to Unicode: need string or buffer, NoneType found',) + >> OutputWriteLines + sys.stdout.writelines(None):TypeError:("'NoneType' object is not iterable",) + sys.stdout.writelines([1]):TypeError:('coercing to Unicode: need string or buffer, int found',) + > VimCommand +! vim.command(1):TypeError:('expected str() or unicode() instance, but got int',) + > VimToPython + > VimEval +! vim.eval(1):TypeError:('expected str() or unicode() instance, but got int',) + > VimEvalPy +! vim.bindeval(1):TypeError:('expected str() or unicode() instance, but got int',) + > VimStrwidth +! vim.strwidth(1):TypeError:('expected str() or unicode() instance, but got int',) + > Dictionary + >> DictionaryConstructor +! vim.Dictionary("abc"):ValueError:('expected sequence element of size 2, but got sequence of size 1',) + >> DictionarySetattr + del d.locked:AttributeError:('cannot delete vim.Dictionary attributes',) + d.locked = FailingTrue():NotImplementedError:() + vim.vvars.locked = False:TypeError:('cannot modify fixed dictionary',) +! d.scope = True:AttributeError:('cannot set attribute scope',) +! d.xxx = True:AttributeError:('cannot set attribute xxx',) + >> _DictionaryItem + d.get("a", 2, 3):TypeError:('function takes at most 2 arguments (3 given)',) + >>> Testing StringToChars using d.get(%s) +! d.get(1):TypeError:('expected str() or unicode() instance, but got int',) + d.get(u"\0"):TypeError:('expected string without null bytes',) + d.get("\0"):TypeError:('expected string without null bytes',) + <<< Finished + d.pop("a"):KeyError:('a',) +! dl.pop("a"):error:('dictionary is locked',) + >> DictionaryIterNext + for i in ned: ned["a"] = 1:RuntimeError:('hashtab changed during iteration',) + >> DictionaryAssItem +! dl["b"] = 1:error:('dictionary is locked',) + >>> Testing StringToChars using d[%s] = 1 +! d[1] = 1:TypeError:('expected str() or unicode() instance, but got int',) + d[u"\0"] = 1:TypeError:('expected string without null bytes',) + d["\0"] = 1:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d["a"] = {%s : 1} +! d["a"] = {1 : 1}:TypeError:('expected str() or unicode() instance, but got int',) + d["a"] = {u"\0" : 1}:TypeError:('expected string without null bytes',) + d["a"] = {"\0" : 1}:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : {%s : 1}} +! d["a"] = {"abc" : {1 : 1}}:TypeError:('expected str() or unicode() instance, but got int',) + d["a"] = {"abc" : {u"\0" : 1}}:TypeError:('expected string without null bytes',) + d["a"] = {"abc" : {"\0" : 1}}:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : Mapping({%s : 1})} +! d["a"] = {"abc" : Mapping({1 : 1})}:TypeError:('expected str() or unicode() instance, but got int',) + d["a"] = {"abc" : Mapping({u"\0" : 1})}:TypeError:('expected string without null bytes',) + d["a"] = {"abc" : Mapping({"\0" : 1})}:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : FailingIter()}:TypeError:('unable to convert FailingIter to vim structure',) + d["a"] = {"abc" : FailingIterNext()}:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : None}:TypeError:('unable to convert NoneType to vim structure',) + d["a"] = {"abc" : {"": 1}}:ValueError:('empty keys are not allowed',) + d["a"] = {"abc" : {u"": 1}}:ValueError:('empty keys are not allowed',) + d["a"] = {"abc" : FailingMapping()}:NotImplementedError:() + d["a"] = {"abc" : FailingMappingKey()}:NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) +! d["a"] = Mapping({1 : 1}):TypeError:('expected str() or unicode() instance, but got int',) + d["a"] = Mapping({u"\0" : 1}):TypeError:('expected string without null bytes',) + d["a"] = Mapping({"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : {%s : 1}}) +! d["a"] = Mapping({"abc" : {1 : 1}}):TypeError:('expected str() or unicode() instance, but got int',) + d["a"] = Mapping({"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) + d["a"] = Mapping({"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : Mapping({%s : 1})}) +! d["a"] = Mapping({"abc" : Mapping({1 : 1})}):TypeError:('expected str() or unicode() instance, but got int',) + d["a"] = Mapping({"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) + d["a"] = Mapping({"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) + d["a"] = Mapping({"abc" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : None}):TypeError:('unable to convert NoneType to vim structure',) + d["a"] = Mapping({"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) + d["a"] = Mapping({"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) + d["a"] = Mapping({"abc" : FailingMapping()}):NotImplementedError:() + d["a"] = Mapping({"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d["a"] = %s +! d["a"] = FailingIter():TypeError:('unable to convert FailingIter to vim structure',) + d["a"] = FailingIterNext():NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = %s +! d["a"] = None:TypeError:('unable to convert NoneType to vim structure',) + d["a"] = {"": 1}:ValueError:('empty keys are not allowed',) + d["a"] = {u"": 1}:ValueError:('empty keys are not allowed',) + d["a"] = FailingMapping():NotImplementedError:() +*************** +*** 550,601 **** + d.update(FailingMapping()):NotImplementedError:() + d.update([FailingIterNext()]):NotImplementedError:() + >>> Testing StringToChars using d.update({%s : 1}) +! d.update({1 : 1}):TypeError:('object must be string',) + d.update({u"\0" : 1}):TypeError:('expected string without null bytes',) + d.update({"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : {%s : 1}}) +! d.update({"abc" : {1 : 1}}):TypeError:('object must be string',) + d.update({"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) + d.update({"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : Mapping({%s : 1})}) +! d.update({"abc" : Mapping({1 : 1})}):TypeError:('object must be string',) + d.update({"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) + d.update({"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d.update({"abc" : %s}) +! d.update({"abc" : FailingIter()}):TypeError:('unable to convert to vim structure',) + d.update({"abc" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update({"abc" : %s}) +! d.update({"abc" : None}):TypeError:('unable to convert to vim structure',) + d.update({"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) + d.update({"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) + d.update({"abc" : FailingMapping()}):NotImplementedError:() + d.update({"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) +! d.update(Mapping({1 : 1})):TypeError:('object must be string',) + d.update(Mapping({u"\0" : 1})):TypeError:('expected string without null bytes',) + d.update(Mapping({"\0" : 1})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : {%s : 1}})) +! d.update(Mapping({"abc" : {1 : 1}})):TypeError:('object must be string',) + d.update(Mapping({"abc" : {u"\0" : 1}})):TypeError:('expected string without null bytes',) + d.update(Mapping({"abc" : {"\0" : 1}})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : Mapping({%s : 1})})) +! d.update(Mapping({"abc" : Mapping({1 : 1})})):TypeError:('object must be string',) + d.update(Mapping({"abc" : Mapping({u"\0" : 1})})):TypeError:('expected string without null bytes',) + d.update(Mapping({"abc" : Mapping({"\0" : 1})})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : FailingIter()})):TypeError:('unable to convert to vim structure',) + d.update(Mapping({"abc" : FailingIterNext()})):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : None})):TypeError:('unable to convert to vim structure',) + d.update(Mapping({"abc" : {"": 1}})):ValueError:('empty keys are not allowed',) + d.update(Mapping({"abc" : {u"": 1}})):ValueError:('empty keys are not allowed',) + d.update(Mapping({"abc" : FailingMapping()})):NotImplementedError:() +--- 550,601 ---- + d.update(FailingMapping()):NotImplementedError:() + d.update([FailingIterNext()]):NotImplementedError:() + >>> Testing StringToChars using d.update({%s : 1}) +! d.update({1 : 1}):TypeError:('expected str() or unicode() instance, but got int',) + d.update({u"\0" : 1}):TypeError:('expected string without null bytes',) + d.update({"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : {%s : 1}}) +! d.update({"abc" : {1 : 1}}):TypeError:('expected str() or unicode() instance, but got int',) + d.update({"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) + d.update({"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : Mapping({%s : 1})}) +! d.update({"abc" : Mapping({1 : 1})}):TypeError:('expected str() or unicode() instance, but got int',) + d.update({"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) + d.update({"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d.update({"abc" : %s}) +! d.update({"abc" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) + d.update({"abc" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update({"abc" : %s}) +! d.update({"abc" : None}):TypeError:('unable to convert NoneType to vim structure',) + d.update({"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) + d.update({"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) + d.update({"abc" : FailingMapping()}):NotImplementedError:() + d.update({"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) +! d.update(Mapping({1 : 1})):TypeError:('expected str() or unicode() instance, but got int',) + d.update(Mapping({u"\0" : 1})):TypeError:('expected string without null bytes',) + d.update(Mapping({"\0" : 1})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : {%s : 1}})) +! d.update(Mapping({"abc" : {1 : 1}})):TypeError:('expected str() or unicode() instance, but got int',) + d.update(Mapping({"abc" : {u"\0" : 1}})):TypeError:('expected string without null bytes',) + d.update(Mapping({"abc" : {"\0" : 1}})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : Mapping({%s : 1})})) +! d.update(Mapping({"abc" : Mapping({1 : 1})})):TypeError:('expected str() or unicode() instance, but got int',) + d.update(Mapping({"abc" : Mapping({u"\0" : 1})})):TypeError:('expected string without null bytes',) + d.update(Mapping({"abc" : Mapping({"\0" : 1})})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : FailingIter()})):TypeError:('unable to convert FailingIter to vim structure',) + d.update(Mapping({"abc" : FailingIterNext()})):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : None})):TypeError:('unable to convert NoneType to vim structure',) + d.update(Mapping({"abc" : {"": 1}})):ValueError:('empty keys are not allowed',) + d.update(Mapping({"abc" : {u"": 1}})):ValueError:('empty keys are not allowed',) + d.update(Mapping({"abc" : FailingMapping()})):NotImplementedError:() +*************** +*** 613,680 **** + d.update(FailingMappingKey()):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update(((%s, 0),)) +! d.update(((1, 0),)):TypeError:('object must be string',) + d.update(((u"\0", 0),)):TypeError:('expected string without null bytes',) + d.update((("\0", 0),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update((("a", {%s : 1}),)) +! d.update((("a", {1 : 1}),)):TypeError:('object must be string',) + d.update((("a", {u"\0" : 1}),)):TypeError:('expected string without null bytes',) + d.update((("a", {"\0" : 1}),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : {%s : 1}}),)) +! d.update((("a", {"abc" : {1 : 1}}),)):TypeError:('object must be string',) + d.update((("a", {"abc" : {u"\0" : 1}}),)):TypeError:('expected string without null bytes',) + d.update((("a", {"abc" : {"\0" : 1}}),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : Mapping({%s : 1})}),)) +! d.update((("a", {"abc" : Mapping({1 : 1})}),)):TypeError:('object must be string',) + d.update((("a", {"abc" : Mapping({u"\0" : 1})}),)):TypeError:('expected string without null bytes',) + d.update((("a", {"abc" : Mapping({"\0" : 1})}),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : FailingIter()}),)):TypeError:('unable to convert to vim structure',) + d.update((("a", {"abc" : FailingIterNext()}),)):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : None}),)):TypeError:('unable to convert to vim structure',) + d.update((("a", {"abc" : {"": 1}}),)):ValueError:('empty keys are not allowed',) + d.update((("a", {"abc" : {u"": 1}}),)):ValueError:('empty keys are not allowed',) + d.update((("a", {"abc" : FailingMapping()}),)):NotImplementedError:() + d.update((("a", {"abc" : FailingMappingKey()}),)):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) +! d.update((("a", Mapping({1 : 1})),)):TypeError:('object must be string',) + d.update((("a", Mapping({u"\0" : 1})),)):TypeError:('expected string without null bytes',) + d.update((("a", Mapping({"\0" : 1})),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : {%s : 1}})),)) +! d.update((("a", Mapping({"abc" : {1 : 1}})),)):TypeError:('object must be string',) + d.update((("a", Mapping({"abc" : {u"\0" : 1}})),)):TypeError:('expected string without null bytes',) + d.update((("a", Mapping({"abc" : {"\0" : 1}})),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : Mapping({%s : 1})})),)) +! d.update((("a", Mapping({"abc" : Mapping({1 : 1})})),)):TypeError:('object must be string',) + d.update((("a", Mapping({"abc" : Mapping({u"\0" : 1})})),)):TypeError:('expected string without null bytes',) + d.update((("a", Mapping({"abc" : Mapping({"\0" : 1})})),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : FailingIter()})),)):TypeError:('unable to convert to vim structure',) + d.update((("a", Mapping({"abc" : FailingIterNext()})),)):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : None})),)):TypeError:('unable to convert to vim structure',) + d.update((("a", Mapping({"abc" : {"": 1}})),)):ValueError:('empty keys are not allowed',) + d.update((("a", Mapping({"abc" : {u"": 1}})),)):ValueError:('empty keys are not allowed',) + d.update((("a", Mapping({"abc" : FailingMapping()})),)):NotImplementedError:() + d.update((("a", Mapping({"abc" : FailingMappingKey()})),)):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d.update((("a", %s),)) +! d.update((("a", FailingIter()),)):TypeError:('unable to convert to vim structure',) + d.update((("a", FailingIterNext()),)):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", %s),)) +! d.update((("a", None),)):TypeError:('unable to convert to vim structure',) + d.update((("a", {"": 1}),)):ValueError:('empty keys are not allowed',) + d.update((("a", {u"": 1}),)):ValueError:('empty keys are not allowed',) + d.update((("a", FailingMapping()),)):NotImplementedError:() +--- 613,680 ---- + d.update(FailingMappingKey()):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update(((%s, 0),)) +! d.update(((1, 0),)):TypeError:('expected str() or unicode() instance, but got int',) + d.update(((u"\0", 0),)):TypeError:('expected string without null bytes',) + d.update((("\0", 0),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update((("a", {%s : 1}),)) +! d.update((("a", {1 : 1}),)):TypeError:('expected str() or unicode() instance, but got int',) + d.update((("a", {u"\0" : 1}),)):TypeError:('expected string without null bytes',) + d.update((("a", {"\0" : 1}),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : {%s : 1}}),)) +! d.update((("a", {"abc" : {1 : 1}}),)):TypeError:('expected str() or unicode() instance, but got int',) + d.update((("a", {"abc" : {u"\0" : 1}}),)):TypeError:('expected string without null bytes',) + d.update((("a", {"abc" : {"\0" : 1}}),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : Mapping({%s : 1})}),)) +! d.update((("a", {"abc" : Mapping({1 : 1})}),)):TypeError:('expected str() or unicode() instance, but got int',) + d.update((("a", {"abc" : Mapping({u"\0" : 1})}),)):TypeError:('expected string without null bytes',) + d.update((("a", {"abc" : Mapping({"\0" : 1})}),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : FailingIter()}),)):TypeError:('unable to convert FailingIter to vim structure',) + d.update((("a", {"abc" : FailingIterNext()}),)):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : None}),)):TypeError:('unable to convert NoneType to vim structure',) + d.update((("a", {"abc" : {"": 1}}),)):ValueError:('empty keys are not allowed',) + d.update((("a", {"abc" : {u"": 1}}),)):ValueError:('empty keys are not allowed',) + d.update((("a", {"abc" : FailingMapping()}),)):NotImplementedError:() + d.update((("a", {"abc" : FailingMappingKey()}),)):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) +! d.update((("a", Mapping({1 : 1})),)):TypeError:('expected str() or unicode() instance, but got int',) + d.update((("a", Mapping({u"\0" : 1})),)):TypeError:('expected string without null bytes',) + d.update((("a", Mapping({"\0" : 1})),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : {%s : 1}})),)) +! d.update((("a", Mapping({"abc" : {1 : 1}})),)):TypeError:('expected str() or unicode() instance, but got int',) + d.update((("a", Mapping({"abc" : {u"\0" : 1}})),)):TypeError:('expected string without null bytes',) + d.update((("a", Mapping({"abc" : {"\0" : 1}})),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : Mapping({%s : 1})})),)) +! d.update((("a", Mapping({"abc" : Mapping({1 : 1})})),)):TypeError:('expected str() or unicode() instance, but got int',) + d.update((("a", Mapping({"abc" : Mapping({u"\0" : 1})})),)):TypeError:('expected string without null bytes',) + d.update((("a", Mapping({"abc" : Mapping({"\0" : 1})})),)):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : FailingIter()})),)):TypeError:('unable to convert FailingIter to vim structure',) + d.update((("a", Mapping({"abc" : FailingIterNext()})),)):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : None})),)):TypeError:('unable to convert NoneType to vim structure',) + d.update((("a", Mapping({"abc" : {"": 1}})),)):ValueError:('empty keys are not allowed',) + d.update((("a", Mapping({"abc" : {u"": 1}})),)):ValueError:('empty keys are not allowed',) + d.update((("a", Mapping({"abc" : FailingMapping()})),)):NotImplementedError:() + d.update((("a", Mapping({"abc" : FailingMappingKey()})),)):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d.update((("a", %s),)) +! d.update((("a", FailingIter()),)):TypeError:('unable to convert FailingIter to vim structure',) + d.update((("a", FailingIterNext()),)):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", %s),)) +! d.update((("a", None),)):TypeError:('unable to convert NoneType to vim structure',) + d.update((("a", {"": 1}),)):ValueError:('empty keys are not allowed',) + d.update((("a", {u"": 1}),)):ValueError:('empty keys are not allowed',) + d.update((("a", FailingMapping()),)):NotImplementedError:() +*************** +*** 689,751 **** + vim.List(1, 2):TypeError:('function takes at most 1 argument (2 given)',) + vim.List(a=1):TypeError:('list constructor does not accept keyword arguments',) + >>> Testing StringToChars using vim.List([{%s : 1}]) +! vim.List([{1 : 1}]):TypeError:('object must be string',) + vim.List([{u"\0" : 1}]):TypeError:('expected string without null bytes',) + vim.List([{"\0" : 1}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : {%s : 1}}]) +! vim.List([{"abc" : {1 : 1}}]):TypeError:('object must be string',) + vim.List([{"abc" : {u"\0" : 1}}]):TypeError:('expected string without null bytes',) + vim.List([{"abc" : {"\0" : 1}}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : Mapping({%s : 1})}]) +! vim.List([{"abc" : Mapping({1 : 1})}]):TypeError:('object must be string',) + vim.List([{"abc" : Mapping({u"\0" : 1})}]):TypeError:('expected string without null bytes',) + vim.List([{"abc" : Mapping({"\0" : 1})}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : FailingIter()}]):TypeError:('unable to convert to vim structure',) + vim.List([{"abc" : FailingIterNext()}]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : None}]):TypeError:('unable to convert to vim structure',) + vim.List([{"abc" : {"": 1}}]):ValueError:('empty keys are not allowed',) + vim.List([{"abc" : {u"": 1}}]):ValueError:('empty keys are not allowed',) + vim.List([{"abc" : FailingMapping()}]):NotImplementedError:() + vim.List([{"abc" : FailingMappingKey()}]):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) +! vim.List([Mapping({1 : 1})]):TypeError:('object must be string',) + vim.List([Mapping({u"\0" : 1})]):TypeError:('expected string without null bytes',) + vim.List([Mapping({"\0" : 1})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : {%s : 1}})]) +! vim.List([Mapping({"abc" : {1 : 1}})]):TypeError:('object must be string',) + vim.List([Mapping({"abc" : {u"\0" : 1}})]):TypeError:('expected string without null bytes',) + vim.List([Mapping({"abc" : {"\0" : 1}})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : Mapping({%s : 1})})]) +! vim.List([Mapping({"abc" : Mapping({1 : 1})})]):TypeError:('object must be string',) + vim.List([Mapping({"abc" : Mapping({u"\0" : 1})})]):TypeError:('expected string without null bytes',) + vim.List([Mapping({"abc" : Mapping({"\0" : 1})})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : FailingIter()})]):TypeError:('unable to convert to vim structure',) + vim.List([Mapping({"abc" : FailingIterNext()})]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : None})]):TypeError:('unable to convert to vim structure',) + vim.List([Mapping({"abc" : {"": 1}})]):ValueError:('empty keys are not allowed',) + vim.List([Mapping({"abc" : {u"": 1}})]):ValueError:('empty keys are not allowed',) + vim.List([Mapping({"abc" : FailingMapping()})]):NotImplementedError:() + vim.List([Mapping({"abc" : FailingMappingKey()})]):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using vim.List([%s]) +! vim.List([FailingIter()]):TypeError:('unable to convert to vim structure',) + vim.List([FailingIterNext()]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([%s]) +! vim.List([None]):TypeError:('unable to convert to vim structure',) + vim.List([{"": 1}]):ValueError:('empty keys are not allowed',) + vim.List([{u"": 1}]):ValueError:('empty keys are not allowed',) + vim.List([FailingMapping()]):NotImplementedError:() +--- 689,751 ---- + vim.List(1, 2):TypeError:('function takes at most 1 argument (2 given)',) + vim.List(a=1):TypeError:('list constructor does not accept keyword arguments',) + >>> Testing StringToChars using vim.List([{%s : 1}]) +! vim.List([{1 : 1}]):TypeError:('expected str() or unicode() instance, but got int',) + vim.List([{u"\0" : 1}]):TypeError:('expected string without null bytes',) + vim.List([{"\0" : 1}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : {%s : 1}}]) +! vim.List([{"abc" : {1 : 1}}]):TypeError:('expected str() or unicode() instance, but got int',) + vim.List([{"abc" : {u"\0" : 1}}]):TypeError:('expected string without null bytes',) + vim.List([{"abc" : {"\0" : 1}}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : Mapping({%s : 1})}]) +! vim.List([{"abc" : Mapping({1 : 1})}]):TypeError:('expected str() or unicode() instance, but got int',) + vim.List([{"abc" : Mapping({u"\0" : 1})}]):TypeError:('expected string without null bytes',) + vim.List([{"abc" : Mapping({"\0" : 1})}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : FailingIter()}]):TypeError:('unable to convert FailingIter to vim structure',) + vim.List([{"abc" : FailingIterNext()}]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : None}]):TypeError:('unable to convert NoneType to vim structure',) + vim.List([{"abc" : {"": 1}}]):ValueError:('empty keys are not allowed',) + vim.List([{"abc" : {u"": 1}}]):ValueError:('empty keys are not allowed',) + vim.List([{"abc" : FailingMapping()}]):NotImplementedError:() + vim.List([{"abc" : FailingMappingKey()}]):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) +! vim.List([Mapping({1 : 1})]):TypeError:('expected str() or unicode() instance, but got int',) + vim.List([Mapping({u"\0" : 1})]):TypeError:('expected string without null bytes',) + vim.List([Mapping({"\0" : 1})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : {%s : 1}})]) +! vim.List([Mapping({"abc" : {1 : 1}})]):TypeError:('expected str() or unicode() instance, but got int',) + vim.List([Mapping({"abc" : {u"\0" : 1}})]):TypeError:('expected string without null bytes',) + vim.List([Mapping({"abc" : {"\0" : 1}})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : Mapping({%s : 1})})]) +! vim.List([Mapping({"abc" : Mapping({1 : 1})})]):TypeError:('expected str() or unicode() instance, but got int',) + vim.List([Mapping({"abc" : Mapping({u"\0" : 1})})]):TypeError:('expected string without null bytes',) + vim.List([Mapping({"abc" : Mapping({"\0" : 1})})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : FailingIter()})]):TypeError:('unable to convert FailingIter to vim structure',) + vim.List([Mapping({"abc" : FailingIterNext()})]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : None})]):TypeError:('unable to convert NoneType to vim structure',) + vim.List([Mapping({"abc" : {"": 1}})]):ValueError:('empty keys are not allowed',) + vim.List([Mapping({"abc" : {u"": 1}})]):ValueError:('empty keys are not allowed',) + vim.List([Mapping({"abc" : FailingMapping()})]):NotImplementedError:() + vim.List([Mapping({"abc" : FailingMappingKey()})]):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using vim.List([%s]) +! vim.List([FailingIter()]):TypeError:('unable to convert FailingIter to vim structure',) + vim.List([FailingIterNext()]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([%s]) +! vim.List([None]):TypeError:('unable to convert NoneType to vim structure',) + vim.List([{"": 1}]):ValueError:('empty keys are not allowed',) + vim.List([{u"": 1}]):ValueError:('empty keys are not allowed',) + vim.List([FailingMapping()]):NotImplementedError:() +*************** +*** 759,821 **** + >> ListAssSlice + ll[1:100] = "abc":error:('list is locked',) + >>> Testing StringToChars using l[:] = [{%s : 1}] +! l[:] = [{1 : 1}]:TypeError:('object must be string',) + l[:] = [{u"\0" : 1}]:TypeError:('expected string without null bytes',) + l[:] = [{"\0" : 1}]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : {%s : 1}}] +! l[:] = [{"abc" : {1 : 1}}]:TypeError:('object must be string',) + l[:] = [{"abc" : {u"\0" : 1}}]:TypeError:('expected string without null bytes',) + l[:] = [{"abc" : {"\0" : 1}}]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : Mapping({%s : 1})}] +! l[:] = [{"abc" : Mapping({1 : 1})}]:TypeError:('object must be string',) + l[:] = [{"abc" : Mapping({u"\0" : 1})}]:TypeError:('expected string without null bytes',) + l[:] = [{"abc" : Mapping({"\0" : 1})}]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : FailingIter()}]:TypeError:('unable to convert to vim structure',) + l[:] = [{"abc" : FailingIterNext()}]:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : None}]:TypeError:('unable to convert to vim structure',) + l[:] = [{"abc" : {"": 1}}]:ValueError:('empty keys are not allowed',) + l[:] = [{"abc" : {u"": 1}}]:ValueError:('empty keys are not allowed',) + l[:] = [{"abc" : FailingMapping()}]:NotImplementedError:() + l[:] = [{"abc" : FailingMappingKey()}]:NotImplementedError:() + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] +! l[:] = [Mapping({1 : 1})]:TypeError:('object must be string',) + l[:] = [Mapping({u"\0" : 1})]:TypeError:('expected string without null bytes',) + l[:] = [Mapping({"\0" : 1})]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : {%s : 1}})] +! l[:] = [Mapping({"abc" : {1 : 1}})]:TypeError:('object must be string',) + l[:] = [Mapping({"abc" : {u"\0" : 1}})]:TypeError:('expected string without null bytes',) + l[:] = [Mapping({"abc" : {"\0" : 1}})]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : Mapping({%s : 1})})] +! l[:] = [Mapping({"abc" : Mapping({1 : 1})})]:TypeError:('object must be string',) + l[:] = [Mapping({"abc" : Mapping({u"\0" : 1})})]:TypeError:('expected string without null bytes',) + l[:] = [Mapping({"abc" : Mapping({"\0" : 1})})]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : FailingIter()})]:TypeError:('unable to convert to vim structure',) + l[:] = [Mapping({"abc" : FailingIterNext()})]:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : None})]:TypeError:('unable to convert to vim structure',) + l[:] = [Mapping({"abc" : {"": 1}})]:ValueError:('empty keys are not allowed',) + l[:] = [Mapping({"abc" : {u"": 1}})]:ValueError:('empty keys are not allowed',) + l[:] = [Mapping({"abc" : FailingMapping()})]:NotImplementedError:() + l[:] = [Mapping({"abc" : FailingMappingKey()})]:NotImplementedError:() + <<< Finished + >>> Testing *Iter* using l[:] = [%s] +! l[:] = [FailingIter()]:TypeError:('unable to convert to vim structure',) + l[:] = [FailingIterNext()]:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [%s] +! l[:] = [None]:TypeError:('unable to convert to vim structure',) + l[:] = [{"": 1}]:ValueError:('empty keys are not allowed',) + l[:] = [{u"": 1}]:ValueError:('empty keys are not allowed',) + l[:] = [FailingMapping()]:NotImplementedError:() +--- 759,821 ---- + >> ListAssSlice + ll[1:100] = "abc":error:('list is locked',) + >>> Testing StringToChars using l[:] = [{%s : 1}] +! l[:] = [{1 : 1}]:TypeError:('expected str() or unicode() instance, but got int',) + l[:] = [{u"\0" : 1}]:TypeError:('expected string without null bytes',) + l[:] = [{"\0" : 1}]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : {%s : 1}}] +! l[:] = [{"abc" : {1 : 1}}]:TypeError:('expected str() or unicode() instance, but got int',) + l[:] = [{"abc" : {u"\0" : 1}}]:TypeError:('expected string without null bytes',) + l[:] = [{"abc" : {"\0" : 1}}]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : Mapping({%s : 1})}] +! l[:] = [{"abc" : Mapping({1 : 1})}]:TypeError:('expected str() or unicode() instance, but got int',) + l[:] = [{"abc" : Mapping({u"\0" : 1})}]:TypeError:('expected string without null bytes',) + l[:] = [{"abc" : Mapping({"\0" : 1})}]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : FailingIter()}]:TypeError:('unable to convert FailingIter to vim structure',) + l[:] = [{"abc" : FailingIterNext()}]:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : None}]:TypeError:('unable to convert NoneType to vim structure',) + l[:] = [{"abc" : {"": 1}}]:ValueError:('empty keys are not allowed',) + l[:] = [{"abc" : {u"": 1}}]:ValueError:('empty keys are not allowed',) + l[:] = [{"abc" : FailingMapping()}]:NotImplementedError:() + l[:] = [{"abc" : FailingMappingKey()}]:NotImplementedError:() + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] +! l[:] = [Mapping({1 : 1})]:TypeError:('expected str() or unicode() instance, but got int',) + l[:] = [Mapping({u"\0" : 1})]:TypeError:('expected string without null bytes',) + l[:] = [Mapping({"\0" : 1})]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : {%s : 1}})] +! l[:] = [Mapping({"abc" : {1 : 1}})]:TypeError:('expected str() or unicode() instance, but got int',) + l[:] = [Mapping({"abc" : {u"\0" : 1}})]:TypeError:('expected string without null bytes',) + l[:] = [Mapping({"abc" : {"\0" : 1}})]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : Mapping({%s : 1})})] +! l[:] = [Mapping({"abc" : Mapping({1 : 1})})]:TypeError:('expected str() or unicode() instance, but got int',) + l[:] = [Mapping({"abc" : Mapping({u"\0" : 1})})]:TypeError:('expected string without null bytes',) + l[:] = [Mapping({"abc" : Mapping({"\0" : 1})})]:TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : FailingIter()})]:TypeError:('unable to convert FailingIter to vim structure',) + l[:] = [Mapping({"abc" : FailingIterNext()})]:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : None})]:TypeError:('unable to convert NoneType to vim structure',) + l[:] = [Mapping({"abc" : {"": 1}})]:ValueError:('empty keys are not allowed',) + l[:] = [Mapping({"abc" : {u"": 1}})]:ValueError:('empty keys are not allowed',) + l[:] = [Mapping({"abc" : FailingMapping()})]:NotImplementedError:() + l[:] = [Mapping({"abc" : FailingMappingKey()})]:NotImplementedError:() + <<< Finished + >>> Testing *Iter* using l[:] = [%s] +! l[:] = [FailingIter()]:TypeError:('unable to convert FailingIter to vim structure',) + l[:] = [FailingIterNext()]:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [%s] +! l[:] = [None]:TypeError:('unable to convert NoneType to vim structure',) + l[:] = [{"": 1}]:ValueError:('empty keys are not allowed',) + l[:] = [{u"": 1}]:ValueError:('empty keys are not allowed',) + l[:] = [FailingMapping()]:NotImplementedError:() +*************** +*** 823,885 **** + <<< Finished + >> ListConcatInPlace + >>> Testing StringToChars using l.extend([{%s : 1}]) +! l.extend([{1 : 1}]):TypeError:('object must be string',) + l.extend([{u"\0" : 1}]):TypeError:('expected string without null bytes',) + l.extend([{"\0" : 1}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : {%s : 1}}]) +! l.extend([{"abc" : {1 : 1}}]):TypeError:('object must be string',) + l.extend([{"abc" : {u"\0" : 1}}]):TypeError:('expected string without null bytes',) + l.extend([{"abc" : {"\0" : 1}}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : Mapping({%s : 1})}]) +! l.extend([{"abc" : Mapping({1 : 1})}]):TypeError:('object must be string',) + l.extend([{"abc" : Mapping({u"\0" : 1})}]):TypeError:('expected string without null bytes',) + l.extend([{"abc" : Mapping({"\0" : 1})}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : FailingIter()}]):TypeError:('unable to convert to vim structure',) + l.extend([{"abc" : FailingIterNext()}]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : None}]):TypeError:('unable to convert to vim structure',) + l.extend([{"abc" : {"": 1}}]):ValueError:('empty keys are not allowed',) + l.extend([{"abc" : {u"": 1}}]):ValueError:('empty keys are not allowed',) + l.extend([{"abc" : FailingMapping()}]):NotImplementedError:() + l.extend([{"abc" : FailingMappingKey()}]):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) +! l.extend([Mapping({1 : 1})]):TypeError:('object must be string',) + l.extend([Mapping({u"\0" : 1})]):TypeError:('expected string without null bytes',) + l.extend([Mapping({"\0" : 1})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : {%s : 1}})]) +! l.extend([Mapping({"abc" : {1 : 1}})]):TypeError:('object must be string',) + l.extend([Mapping({"abc" : {u"\0" : 1}})]):TypeError:('expected string without null bytes',) + l.extend([Mapping({"abc" : {"\0" : 1}})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : Mapping({%s : 1})})]) +! l.extend([Mapping({"abc" : Mapping({1 : 1})})]):TypeError:('object must be string',) + l.extend([Mapping({"abc" : Mapping({u"\0" : 1})})]):TypeError:('expected string without null bytes',) + l.extend([Mapping({"abc" : Mapping({"\0" : 1})})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : FailingIter()})]):TypeError:('unable to convert to vim structure',) + l.extend([Mapping({"abc" : FailingIterNext()})]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : None})]):TypeError:('unable to convert to vim structure',) + l.extend([Mapping({"abc" : {"": 1}})]):ValueError:('empty keys are not allowed',) + l.extend([Mapping({"abc" : {u"": 1}})]):ValueError:('empty keys are not allowed',) + l.extend([Mapping({"abc" : FailingMapping()})]):NotImplementedError:() + l.extend([Mapping({"abc" : FailingMappingKey()})]):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using l.extend([%s]) +! l.extend([FailingIter()]):TypeError:('unable to convert to vim structure',) + l.extend([FailingIterNext()]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([%s]) +! l.extend([None]):TypeError:('unable to convert to vim structure',) + l.extend([{"": 1}]):ValueError:('empty keys are not allowed',) + l.extend([{u"": 1}]):ValueError:('empty keys are not allowed',) + l.extend([FailingMapping()]):NotImplementedError:() +--- 823,885 ---- + <<< Finished + >> ListConcatInPlace + >>> Testing StringToChars using l.extend([{%s : 1}]) +! l.extend([{1 : 1}]):TypeError:('expected str() or unicode() instance, but got int',) + l.extend([{u"\0" : 1}]):TypeError:('expected string without null bytes',) + l.extend([{"\0" : 1}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : {%s : 1}}]) +! l.extend([{"abc" : {1 : 1}}]):TypeError:('expected str() or unicode() instance, but got int',) + l.extend([{"abc" : {u"\0" : 1}}]):TypeError:('expected string without null bytes',) + l.extend([{"abc" : {"\0" : 1}}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : Mapping({%s : 1})}]) +! l.extend([{"abc" : Mapping({1 : 1})}]):TypeError:('expected str() or unicode() instance, but got int',) + l.extend([{"abc" : Mapping({u"\0" : 1})}]):TypeError:('expected string without null bytes',) + l.extend([{"abc" : Mapping({"\0" : 1})}]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : FailingIter()}]):TypeError:('unable to convert FailingIter to vim structure',) + l.extend([{"abc" : FailingIterNext()}]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : None}]):TypeError:('unable to convert NoneType to vim structure',) + l.extend([{"abc" : {"": 1}}]):ValueError:('empty keys are not allowed',) + l.extend([{"abc" : {u"": 1}}]):ValueError:('empty keys are not allowed',) + l.extend([{"abc" : FailingMapping()}]):NotImplementedError:() + l.extend([{"abc" : FailingMappingKey()}]):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) +! l.extend([Mapping({1 : 1})]):TypeError:('expected str() or unicode() instance, but got int',) + l.extend([Mapping({u"\0" : 1})]):TypeError:('expected string without null bytes',) + l.extend([Mapping({"\0" : 1})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : {%s : 1}})]) +! l.extend([Mapping({"abc" : {1 : 1}})]):TypeError:('expected str() or unicode() instance, but got int',) + l.extend([Mapping({"abc" : {u"\0" : 1}})]):TypeError:('expected string without null bytes',) + l.extend([Mapping({"abc" : {"\0" : 1}})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : Mapping({%s : 1})})]) +! l.extend([Mapping({"abc" : Mapping({1 : 1})})]):TypeError:('expected str() or unicode() instance, but got int',) + l.extend([Mapping({"abc" : Mapping({u"\0" : 1})})]):TypeError:('expected string without null bytes',) + l.extend([Mapping({"abc" : Mapping({"\0" : 1})})]):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : FailingIter()})]):TypeError:('unable to convert FailingIter to vim structure',) + l.extend([Mapping({"abc" : FailingIterNext()})]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : None})]):TypeError:('unable to convert NoneType to vim structure',) + l.extend([Mapping({"abc" : {"": 1}})]):ValueError:('empty keys are not allowed',) + l.extend([Mapping({"abc" : {u"": 1}})]):ValueError:('empty keys are not allowed',) + l.extend([Mapping({"abc" : FailingMapping()})]):NotImplementedError:() + l.extend([Mapping({"abc" : FailingMappingKey()})]):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using l.extend([%s]) +! l.extend([FailingIter()]):TypeError:('unable to convert FailingIter to vim structure',) + l.extend([FailingIterNext()]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([%s]) +! l.extend([None]):TypeError:('unable to convert NoneType to vim structure',) + l.extend([{"": 1}]):ValueError:('empty keys are not allowed',) + l.extend([{u"": 1}]):ValueError:('empty keys are not allowed',) + l.extend([FailingMapping()]):NotImplementedError:() +*************** +*** 888,1028 **** + >> ListSetattr + del l.locked:AttributeError:('cannot delete vim.List attributes',) + l.locked = FailingTrue():NotImplementedError:() +! l.xxx = True:AttributeError:('cannot set this attribute',) + > Function + >> FunctionConstructor +! vim.Function("123"):ValueError:('unnamed function does not exist',) +! vim.Function("xxx_non_existent_function_xxx"):ValueError:('function does not exist',) + vim.Function("xxx#non#existent#function#xxx"):NOT FAILED + >> FunctionCall + >>> Testing StringToChars using f({%s : 1}) +! f({1 : 1}):TypeError:('object must be string',) + f({u"\0" : 1}):TypeError:('expected string without null bytes',) + f({"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using f({"abc" : {%s : 1}}) +! f({"abc" : {1 : 1}}):TypeError:('object must be string',) + f({"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) + f({"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using f({"abc" : Mapping({%s : 1})}) +! f({"abc" : Mapping({1 : 1})}):TypeError:('object must be string',) + f({"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) + f({"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using f({"abc" : %s}) +! f({"abc" : FailingIter()}):TypeError:('unable to convert to vim structure',) + f({"abc" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using f({"abc" : %s}) +! f({"abc" : None}):TypeError:('unable to convert to vim structure',) + f({"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) + f({"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) + f({"abc" : FailingMapping()}):NotImplementedError:() + f({"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) +! f(Mapping({1 : 1})):TypeError:('object must be string',) + f(Mapping({u"\0" : 1})):TypeError:('expected string without null bytes',) + f(Mapping({"\0" : 1})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : {%s : 1}})) +! f(Mapping({"abc" : {1 : 1}})):TypeError:('object must be string',) + f(Mapping({"abc" : {u"\0" : 1}})):TypeError:('expected string without null bytes',) + f(Mapping({"abc" : {"\0" : 1}})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : Mapping({%s : 1})})) +! f(Mapping({"abc" : Mapping({1 : 1})})):TypeError:('object must be string',) + f(Mapping({"abc" : Mapping({u"\0" : 1})})):TypeError:('expected string without null bytes',) + f(Mapping({"abc" : Mapping({"\0" : 1})})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : FailingIter()})):TypeError:('unable to convert to vim structure',) + f(Mapping({"abc" : FailingIterNext()})):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : None})):TypeError:('unable to convert to vim structure',) + f(Mapping({"abc" : {"": 1}})):ValueError:('empty keys are not allowed',) + f(Mapping({"abc" : {u"": 1}})):ValueError:('empty keys are not allowed',) + f(Mapping({"abc" : FailingMapping()})):NotImplementedError:() + f(Mapping({"abc" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using f(%s) +! f(FailingIter()):TypeError:('unable to convert to vim structure',) + f(FailingIterNext()):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using f(%s) +! f(None):TypeError:('unable to convert to vim structure',) + f({"": 1}):ValueError:('empty keys are not allowed',) + f({u"": 1}):ValueError:('empty keys are not allowed',) + f(FailingMapping()):NotImplementedError:() + f(FailingMappingKey()):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using fd(self={%s : 1}) +! fd(self={1 : 1}):TypeError:('object must be string',) + fd(self={u"\0" : 1}):TypeError:('expected string without null bytes',) + fd(self={"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : {%s : 1}}) +! fd(self={"abc" : {1 : 1}}):TypeError:('object must be string',) + fd(self={"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) + fd(self={"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : Mapping({%s : 1})}) +! fd(self={"abc" : Mapping({1 : 1})}):TypeError:('object must be string',) + fd(self={"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) + fd(self={"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using fd(self={"abc" : %s}) +! fd(self={"abc" : FailingIter()}):TypeError:('unable to convert to vim structure',) + fd(self={"abc" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using fd(self={"abc" : %s}) +! fd(self={"abc" : None}):TypeError:('unable to convert to vim structure',) + fd(self={"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) + fd(self={"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) + fd(self={"abc" : FailingMapping()}):NotImplementedError:() + fd(self={"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) +! fd(self=Mapping({1 : 1})):TypeError:('object must be string',) + fd(self=Mapping({u"\0" : 1})):TypeError:('expected string without null bytes',) + fd(self=Mapping({"\0" : 1})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : {%s : 1}})) +! fd(self=Mapping({"abc" : {1 : 1}})):TypeError:('object must be string',) + fd(self=Mapping({"abc" : {u"\0" : 1}})):TypeError:('expected string without null bytes',) + fd(self=Mapping({"abc" : {"\0" : 1}})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : Mapping({%s : 1})})) +! fd(self=Mapping({"abc" : Mapping({1 : 1})})):TypeError:('object must be string',) + fd(self=Mapping({"abc" : Mapping({u"\0" : 1})})):TypeError:('expected string without null bytes',) + fd(self=Mapping({"abc" : Mapping({"\0" : 1})})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : FailingIter()})):TypeError:('unable to convert to vim structure',) + fd(self=Mapping({"abc" : FailingIterNext()})):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : None})):TypeError:('unable to convert to vim structure',) + fd(self=Mapping({"abc" : {"": 1}})):ValueError:('empty keys are not allowed',) + fd(self=Mapping({"abc" : {u"": 1}})):ValueError:('empty keys are not allowed',) + fd(self=Mapping({"abc" : FailingMapping()})):NotImplementedError:() + fd(self=Mapping({"abc" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using fd(self=%s) +! fd(self=FailingIter()):TypeError:('unable to convert object to vim dictionary',) +! fd(self=FailingIterNext()):TypeError:('unable to convert object to vim dictionary',) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=%s) +! fd(self=None):TypeError:('unable to convert object to vim dictionary',) + fd(self={"": 1}):ValueError:('empty keys are not allowed',) + fd(self={u"": 1}):ValueError:('empty keys are not allowed',) + fd(self=FailingMapping()):NotImplementedError:() + fd(self=FailingMappingKey()):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyMapping using fd(self=%s) +! fd(self=[]):TypeError:('unable to convert object to vim dictionary',) + <<< Finished + > TabPage + >> TabPageAttr +--- 888,1028 ---- + >> ListSetattr + del l.locked:AttributeError:('cannot delete vim.List attributes',) + l.locked = FailingTrue():NotImplementedError:() +! l.xxx = True:AttributeError:('cannot set attribute xxx',) + > Function + >> FunctionConstructor +! vim.Function("123"):ValueError:('unnamed function 123 does not exist',) +! vim.Function("xxx_non_existent_function_xxx"):ValueError:('function xxx_non_existent_function_xxx does not exist',) + vim.Function("xxx#non#existent#function#xxx"):NOT FAILED + >> FunctionCall + >>> Testing StringToChars using f({%s : 1}) +! f({1 : 1}):TypeError:('expected str() or unicode() instance, but got int',) + f({u"\0" : 1}):TypeError:('expected string without null bytes',) + f({"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using f({"abc" : {%s : 1}}) +! f({"abc" : {1 : 1}}):TypeError:('expected str() or unicode() instance, but got int',) + f({"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) + f({"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using f({"abc" : Mapping({%s : 1})}) +! f({"abc" : Mapping({1 : 1})}):TypeError:('expected str() or unicode() instance, but got int',) + f({"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) + f({"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using f({"abc" : %s}) +! f({"abc" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) + f({"abc" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using f({"abc" : %s}) +! f({"abc" : None}):TypeError:('unable to convert NoneType to vim structure',) + f({"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) + f({"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) + f({"abc" : FailingMapping()}):NotImplementedError:() + f({"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) +! f(Mapping({1 : 1})):TypeError:('expected str() or unicode() instance, but got int',) + f(Mapping({u"\0" : 1})):TypeError:('expected string without null bytes',) + f(Mapping({"\0" : 1})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : {%s : 1}})) +! f(Mapping({"abc" : {1 : 1}})):TypeError:('expected str() or unicode() instance, but got int',) + f(Mapping({"abc" : {u"\0" : 1}})):TypeError:('expected string without null bytes',) + f(Mapping({"abc" : {"\0" : 1}})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : Mapping({%s : 1})})) +! f(Mapping({"abc" : Mapping({1 : 1})})):TypeError:('expected str() or unicode() instance, but got int',) + f(Mapping({"abc" : Mapping({u"\0" : 1})})):TypeError:('expected string without null bytes',) + f(Mapping({"abc" : Mapping({"\0" : 1})})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : FailingIter()})):TypeError:('unable to convert FailingIter to vim structure',) + f(Mapping({"abc" : FailingIterNext()})):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : None})):TypeError:('unable to convert NoneType to vim structure',) + f(Mapping({"abc" : {"": 1}})):ValueError:('empty keys are not allowed',) + f(Mapping({"abc" : {u"": 1}})):ValueError:('empty keys are not allowed',) + f(Mapping({"abc" : FailingMapping()})):NotImplementedError:() + f(Mapping({"abc" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using f(%s) +! f(FailingIter()):TypeError:('unable to convert FailingIter to vim structure',) + f(FailingIterNext()):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using f(%s) +! f(None):TypeError:('unable to convert NoneType to vim structure',) + f({"": 1}):ValueError:('empty keys are not allowed',) + f({u"": 1}):ValueError:('empty keys are not allowed',) + f(FailingMapping()):NotImplementedError:() + f(FailingMappingKey()):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using fd(self={%s : 1}) +! fd(self={1 : 1}):TypeError:('expected str() or unicode() instance, but got int',) + fd(self={u"\0" : 1}):TypeError:('expected string without null bytes',) + fd(self={"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : {%s : 1}}) +! fd(self={"abc" : {1 : 1}}):TypeError:('expected str() or unicode() instance, but got int',) + fd(self={"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) + fd(self={"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : Mapping({%s : 1})}) +! fd(self={"abc" : Mapping({1 : 1})}):TypeError:('expected str() or unicode() instance, but got int',) + fd(self={"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) + fd(self={"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using fd(self={"abc" : %s}) +! fd(self={"abc" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) + fd(self={"abc" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using fd(self={"abc" : %s}) +! fd(self={"abc" : None}):TypeError:('unable to convert NoneType to vim structure',) + fd(self={"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) + fd(self={"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) + fd(self={"abc" : FailingMapping()}):NotImplementedError:() + fd(self={"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) +! fd(self=Mapping({1 : 1})):TypeError:('expected str() or unicode() instance, but got int',) + fd(self=Mapping({u"\0" : 1})):TypeError:('expected string without null bytes',) + fd(self=Mapping({"\0" : 1})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : {%s : 1}})) +! fd(self=Mapping({"abc" : {1 : 1}})):TypeError:('expected str() or unicode() instance, but got int',) + fd(self=Mapping({"abc" : {u"\0" : 1}})):TypeError:('expected string without null bytes',) + fd(self=Mapping({"abc" : {"\0" : 1}})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : Mapping({%s : 1})})) +! fd(self=Mapping({"abc" : Mapping({1 : 1})})):TypeError:('expected str() or unicode() instance, but got int',) + fd(self=Mapping({"abc" : Mapping({u"\0" : 1})})):TypeError:('expected string without null bytes',) + fd(self=Mapping({"abc" : Mapping({"\0" : 1})})):TypeError:('expected string without null bytes',) + <<< Finished + >>> Testing *Iter* using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : FailingIter()})):TypeError:('unable to convert FailingIter to vim structure',) + fd(self=Mapping({"abc" : FailingIterNext()})):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : None})):TypeError:('unable to convert NoneType to vim structure',) + fd(self=Mapping({"abc" : {"": 1}})):ValueError:('empty keys are not allowed',) + fd(self=Mapping({"abc" : {u"": 1}})):ValueError:('empty keys are not allowed',) + fd(self=Mapping({"abc" : FailingMapping()})):NotImplementedError:() + fd(self=Mapping({"abc" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using fd(self=%s) +! fd(self=FailingIter()):TypeError:('unable to convert FailingIter to vim dictionary',) +! fd(self=FailingIterNext()):TypeError:('unable to convert FailingIterNext to vim dictionary',) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=%s) +! fd(self=None):TypeError:('unable to convert NoneType to vim dictionary',) + fd(self={"": 1}):ValueError:('empty keys are not allowed',) + fd(self={u"": 1}):ValueError:('empty keys are not allowed',) + fd(self=FailingMapping()):NotImplementedError:() + fd(self=FailingMappingKey()):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyMapping using fd(self=%s) +! fd(self=[]):TypeError:('unable to convert list to vim dictionary',) + <<< Finished + > TabPage + >> TabPageAttr +*************** +*** 1034,1040 **** + >> WindowAttr + vim.current.window.xxx:AttributeError:('xxx',) + >> WindowSetattr +! vim.current.window.buffer = 0:TypeError:('readonly attribute',) + vim.current.window.cursor = (100000000, 100000000):error:('cursor position outside buffer',) + vim.current.window.cursor = True:TypeError:('argument must be 2-item sequence, not bool',) + vim.current.window.height = "abc":TypeError:('an integer is required',) +--- 1034,1040 ---- + >> WindowAttr + vim.current.window.xxx:AttributeError:('xxx',) + >> WindowSetattr +! vim.current.window.buffer = 0:TypeError:('readonly attribute: buffer',) + vim.current.window.cursor = (100000000, 100000000):error:('cursor position outside buffer',) + vim.current.window.cursor = True:TypeError:('argument must be 2-item sequence, not bool',) + vim.current.window.height = "abc":TypeError:('an integer is required',) +*************** +*** 1062,1071 **** + >> BufferAttr + vim.current.buffer.xxx:AttributeError:('xxx',) + >> BufferSetattr +! vim.current.buffer.name = True:TypeError:('object must be string',) + vim.current.buffer.xxx = True:AttributeError:('xxx',) + >> BufferMark +! vim.current.buffer.mark(0):TypeError:('object must be string',) + vim.current.buffer.mark("abc"):ValueError:('mark name must be a single character',) + vim.current.buffer.mark("!"):error:('invalid mark name',) + >> BufferRange +--- 1062,1071 ---- + >> BufferAttr + vim.current.buffer.xxx:AttributeError:('xxx',) + >> BufferSetattr +! vim.current.buffer.name = True:TypeError:('expected str() or unicode() instance, but got bool',) + vim.current.buffer.xxx = True:AttributeError:('xxx',) + >> BufferMark +! vim.current.buffer.mark(0):TypeError:('expected str() or unicode() instance, but got int',) + vim.current.buffer.mark("abc"):ValueError:('mark name must be a single character',) + vim.current.buffer.mark("!"):error:('invalid mark name',) + >> BufferRange +*************** +*** 1079,1087 **** + vim.current.xxx:AttributeError:('xxx',) + >> CurrentSetattr + vim.current.line = True:TypeError:('bad argument type for built-in operation',) +! vim.current.buffer = True:TypeError:('expected vim.Buffer object',) +! vim.current.window = True:TypeError:('expected vim.Window object',) +! vim.current.tabpage = True:TypeError:('expected vim.TabPage object',) + vim.current.xxx = True:AttributeError:('xxx',) + 2,xx + before +--- 1079,1087 ---- + vim.current.xxx:AttributeError:('xxx',) + >> CurrentSetattr + vim.current.line = True:TypeError:('bad argument type for built-in operation',) +! vim.current.buffer = True:TypeError:('expected vim.Buffer object, but got bool',) +! vim.current.window = True:TypeError:('expected vim.Window object, but got bool',) +! vim.current.tabpage = True:TypeError:('expected vim.TabPage object, but got bool',) + vim.current.xxx = True:AttributeError:('xxx',) + 2,xx + before +*** ../vim-7.3.1229/src/testdir/test87.ok 2013-06-23 13:00:40.000000000 +0200 +--- src/testdir/test87.ok 2013-06-23 13:31:16.000000000 +0200 +*************** +*** 428,434 **** + >> OutputSetattr + del sys.stdout.softspace:(, AttributeError("can't delete OutputObject attributes",)) + sys.stdout.softspace = []:(, TypeError('softspace must be an integer',)) +! sys.stdout.attr = None:(, AttributeError('invalid attribute',)) + >> OutputWrite + sys.stdout.write(None):(, TypeError("Can't convert 'NoneType' object to str implicitly",)) + >> OutputWriteLines +--- 428,434 ---- + >> OutputSetattr + del sys.stdout.softspace:(, AttributeError("can't delete OutputObject attributes",)) + sys.stdout.softspace = []:(, TypeError('softspace must be an integer',)) +! sys.stdout.attr = None:(, AttributeError('invalid attribute: attr',)) + >> OutputWrite + sys.stdout.write(None):(, TypeError("Can't convert 'NoneType' object to str implicitly",)) + >> OutputWriteLines +*************** +*** 439,537 **** + sys.stdout.writelines(FailingIterNext()):(, NotImplementedError()) + <<< Finished + > VimCommand +! vim.command(1):(, TypeError('object must be string',)) + > VimToPython + > VimEval +! vim.eval(1):(, TypeError('object must be string',)) + > VimEvalPy +! vim.bindeval(1):(, TypeError('object must be string',)) + > VimStrwidth +! vim.strwidth(1):(, TypeError('object must be string',)) + > Dictionary + >> DictionaryConstructor +! vim.Dictionary("abc"):(, ValueError('expected sequence element of size 2',)) + >> DictionarySetattr + del d.locked:(, AttributeError('cannot delete vim.Dictionary attributes',)) + d.locked = FailingTrue():(, NotImplementedError()) + vim.vvars.locked = False:(, TypeError('cannot modify fixed dictionary',)) +! d.scope = True:(, AttributeError('cannot set this attribute',)) +! d.xxx = True:(, AttributeError('cannot set this attribute',)) + >> _DictionaryItem + d.get("a", 2, 3):(, TypeError('function takes at most 2 arguments (3 given)',)) + >>> Testing StringToChars using d.get(%s) +! d.get(1):(, TypeError('object must be string',)) + d.get(b"\0"):(, TypeError('expected bytes with no null',)) + d.get("\0"):(, TypeError('expected bytes with no null',)) + <<< Finished + d.pop("a"):(, KeyError('a',)) +! dl.pop("a"):(, error('dict is locked',)) + >> DictionaryIterNext + for i in ned: ned["a"] = 1:(, RuntimeError('hashtab changed during iteration',)) + >> DictionaryAssItem +! dl["b"] = 1:(, error('dict is locked',)) + >>> Testing StringToChars using d[%s] = 1 +! d[1] = 1:(, TypeError('object must be string',)) + d[b"\0"] = 1:(, TypeError('expected bytes with no null',)) + d["\0"] = 1:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = {%s : 1} +! d["a"] = {1 : 1}:(, TypeError('object must be string',)) + d["a"] = {b"\0" : 1}:(, TypeError('expected bytes with no null',)) + d["a"] = {"\0" : 1}:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : {%s : 1}} +! d["a"] = {"abc" : {1 : 1}}:(, TypeError('object must be string',)) + d["a"] = {"abc" : {b"\0" : 1}}:(, TypeError('expected bytes with no null',)) + d["a"] = {"abc" : {"\0" : 1}}:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : Mapping({%s : 1})} +! d["a"] = {"abc" : Mapping({1 : 1})}:(, TypeError('object must be string',)) + d["a"] = {"abc" : Mapping({b"\0" : 1})}:(, TypeError('expected bytes with no null',)) + d["a"] = {"abc" : Mapping({"\0" : 1})}:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : FailingIter()}:(, TypeError('unable to convert to vim structure',)) + d["a"] = {"abc" : FailingIterNext()}:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : None}:(, TypeError('unable to convert to vim structure',)) + d["a"] = {"abc" : {b"": 1}}:(, ValueError('empty keys are not allowed',)) + d["a"] = {"abc" : {"": 1}}:(, ValueError('empty keys are not allowed',)) + d["a"] = {"abc" : FailingMapping()}:(, NotImplementedError()) + d["a"] = {"abc" : FailingMappingKey()}:(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) +! d["a"] = Mapping({1 : 1}):(, TypeError('object must be string',)) + d["a"] = Mapping({b"\0" : 1}):(, TypeError('expected bytes with no null',)) + d["a"] = Mapping({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : {%s : 1}}) +! d["a"] = Mapping({"abc" : {1 : 1}}):(, TypeError('object must be string',)) + d["a"] = Mapping({"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) + d["a"] = Mapping({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : Mapping({%s : 1})}) +! d["a"] = Mapping({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) + d["a"] = Mapping({"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) + d["a"] = Mapping({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) + d["a"] = Mapping({"abc" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : None}):(, TypeError('unable to convert to vim structure',)) + d["a"] = Mapping({"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + d["a"] = Mapping({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) + d["a"] = Mapping({"abc" : FailingMapping()}):(, NotImplementedError()) + d["a"] = Mapping({"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d["a"] = %s +! d["a"] = FailingIter():(, TypeError('unable to convert to vim structure',)) + d["a"] = FailingIterNext():(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = %s +! d["a"] = None:(, TypeError('unable to convert to vim structure',)) + d["a"] = {b"": 1}:(, ValueError('empty keys are not allowed',)) + d["a"] = {"": 1}:(, ValueError('empty keys are not allowed',)) + d["a"] = FailingMapping():(, NotImplementedError()) +--- 439,537 ---- + sys.stdout.writelines(FailingIterNext()):(, NotImplementedError()) + <<< Finished + > VimCommand +! vim.command(1):(, TypeError('expected bytes() or str() instance, but got int',)) + > VimToPython + > VimEval +! vim.eval(1):(, TypeError('expected bytes() or str() instance, but got int',)) + > VimEvalPy +! vim.bindeval(1):(, TypeError('expected bytes() or str() instance, but got int',)) + > VimStrwidth +! vim.strwidth(1):(, TypeError('expected bytes() or str() instance, but got int',)) + > Dictionary + >> DictionaryConstructor +! vim.Dictionary("abc"):(, ValueError('expected sequence element of size 2, but got sequence of size 1',)) + >> DictionarySetattr + del d.locked:(, AttributeError('cannot delete vim.Dictionary attributes',)) + d.locked = FailingTrue():(, NotImplementedError()) + vim.vvars.locked = False:(, TypeError('cannot modify fixed dictionary',)) +! d.scope = True:(, AttributeError('cannot set attribute scope',)) +! d.xxx = True:(, AttributeError('cannot set attribute xxx',)) + >> _DictionaryItem + d.get("a", 2, 3):(, TypeError('function takes at most 2 arguments (3 given)',)) + >>> Testing StringToChars using d.get(%s) +! d.get(1):(, TypeError('expected bytes() or str() instance, but got int',)) + d.get(b"\0"):(, TypeError('expected bytes with no null',)) + d.get("\0"):(, TypeError('expected bytes with no null',)) + <<< Finished + d.pop("a"):(, KeyError('a',)) +! dl.pop("a"):(, error('dictionary is locked',)) + >> DictionaryIterNext + for i in ned: ned["a"] = 1:(, RuntimeError('hashtab changed during iteration',)) + >> DictionaryAssItem +! dl["b"] = 1:(, error('dictionary is locked',)) + >>> Testing StringToChars using d[%s] = 1 +! d[1] = 1:(, TypeError('expected bytes() or str() instance, but got int',)) + d[b"\0"] = 1:(, TypeError('expected bytes with no null',)) + d["\0"] = 1:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = {%s : 1} +! d["a"] = {1 : 1}:(, TypeError('expected bytes() or str() instance, but got int',)) + d["a"] = {b"\0" : 1}:(, TypeError('expected bytes with no null',)) + d["a"] = {"\0" : 1}:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : {%s : 1}} +! d["a"] = {"abc" : {1 : 1}}:(, TypeError('expected bytes() or str() instance, but got int',)) + d["a"] = {"abc" : {b"\0" : 1}}:(, TypeError('expected bytes with no null',)) + d["a"] = {"abc" : {"\0" : 1}}:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = {"abc" : Mapping({%s : 1})} +! d["a"] = {"abc" : Mapping({1 : 1})}:(, TypeError('expected bytes() or str() instance, but got int',)) + d["a"] = {"abc" : Mapping({b"\0" : 1})}:(, TypeError('expected bytes with no null',)) + d["a"] = {"abc" : Mapping({"\0" : 1})}:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : FailingIter()}:(, TypeError('unable to convert FailingIter to vim structure',)) + d["a"] = {"abc" : FailingIterNext()}:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : None}:(, TypeError('unable to convert NoneType to vim structure',)) + d["a"] = {"abc" : {b"": 1}}:(, ValueError('empty keys are not allowed',)) + d["a"] = {"abc" : {"": 1}}:(, ValueError('empty keys are not allowed',)) + d["a"] = {"abc" : FailingMapping()}:(, NotImplementedError()) + d["a"] = {"abc" : FailingMappingKey()}:(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) +! d["a"] = Mapping({1 : 1}):(, TypeError('expected bytes() or str() instance, but got int',)) + d["a"] = Mapping({b"\0" : 1}):(, TypeError('expected bytes with no null',)) + d["a"] = Mapping({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : {%s : 1}}) +! d["a"] = Mapping({"abc" : {1 : 1}}):(, TypeError('expected bytes() or str() instance, but got int',)) + d["a"] = Mapping({"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) + d["a"] = Mapping({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({"abc" : Mapping({%s : 1})}) +! d["a"] = Mapping({"abc" : Mapping({1 : 1})}):(, TypeError('expected bytes() or str() instance, but got int',)) + d["a"] = Mapping({"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) + d["a"] = Mapping({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) + d["a"] = Mapping({"abc" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : None}):(, TypeError('unable to convert NoneType to vim structure',)) + d["a"] = Mapping({"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + d["a"] = Mapping({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) + d["a"] = Mapping({"abc" : FailingMapping()}):(, NotImplementedError()) + d["a"] = Mapping({"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d["a"] = %s +! d["a"] = FailingIter():(, TypeError('unable to convert FailingIter to vim structure',)) + d["a"] = FailingIterNext():(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = %s +! d["a"] = None:(, TypeError('unable to convert NoneType to vim structure',)) + d["a"] = {b"": 1}:(, ValueError('empty keys are not allowed',)) + d["a"] = {"": 1}:(, ValueError('empty keys are not allowed',)) + d["a"] = FailingMapping():(, NotImplementedError()) +*************** +*** 547,598 **** + d.update(FailingIterNext()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update({%s : 1}) +! d.update({1 : 1}):(, TypeError('object must be string',)) + d.update({b"\0" : 1}):(, TypeError('expected bytes with no null',)) + d.update({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : {%s : 1}}) +! d.update({"abc" : {1 : 1}}):(, TypeError('object must be string',)) + d.update({"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) + d.update({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : Mapping({%s : 1})}) +! d.update({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) + d.update({"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) + d.update({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update({"abc" : %s}) +! d.update({"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) + d.update({"abc" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update({"abc" : %s}) +! d.update({"abc" : None}):(, TypeError('unable to convert to vim structure',)) + d.update({"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + d.update({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) + d.update({"abc" : FailingMapping()}):(, NotImplementedError()) + d.update({"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) +! d.update(Mapping({1 : 1})):(, TypeError('object must be string',)) + d.update(Mapping({b"\0" : 1})):(, TypeError('expected bytes with no null',)) + d.update(Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : {%s : 1}})) +! d.update(Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) + d.update(Mapping({"abc" : {b"\0" : 1}})):(, TypeError('expected bytes with no null',)) + d.update(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : Mapping({%s : 1})})) +! d.update(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) + d.update(Mapping({"abc" : Mapping({b"\0" : 1})})):(, TypeError('expected bytes with no null',)) + d.update(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert to vim structure',)) + d.update(Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) + d.update(Mapping({"abc" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) + d.update(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) + d.update(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) +--- 547,598 ---- + d.update(FailingIterNext()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update({%s : 1}) +! d.update({1 : 1}):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update({b"\0" : 1}):(, TypeError('expected bytes with no null',)) + d.update({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : {%s : 1}}) +! d.update({"abc" : {1 : 1}}):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update({"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) + d.update({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update({"abc" : Mapping({%s : 1})}) +! d.update({"abc" : Mapping({1 : 1})}):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update({"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) + d.update({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update({"abc" : %s}) +! d.update({"abc" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) + d.update({"abc" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update({"abc" : %s}) +! d.update({"abc" : None}):(, TypeError('unable to convert NoneType to vim structure',)) + d.update({"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + d.update({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) + d.update({"abc" : FailingMapping()}):(, NotImplementedError()) + d.update({"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) +! d.update(Mapping({1 : 1})):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update(Mapping({b"\0" : 1})):(, TypeError('expected bytes with no null',)) + d.update(Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : {%s : 1}})) +! d.update(Mapping({"abc" : {1 : 1}})):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update(Mapping({"abc" : {b"\0" : 1}})):(, TypeError('expected bytes with no null',)) + d.update(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({"abc" : Mapping({%s : 1})})) +! d.update(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update(Mapping({"abc" : Mapping({b"\0" : 1})})):(, TypeError('expected bytes with no null',)) + d.update(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert FailingIter to vim structure',)) + d.update(Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : None})):(, TypeError('unable to convert NoneType to vim structure',)) + d.update(Mapping({"abc" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) + d.update(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) + d.update(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) +*************** +*** 610,677 **** + d.update(FailingMappingKey()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update(((%s, 0),)) +! d.update(((1, 0),)):(, TypeError('object must be string',)) + d.update(((b"\0", 0),)):(, TypeError('expected bytes with no null',)) + d.update((("\0", 0),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", {%s : 1}),)) +! d.update((("a", {1 : 1}),)):(, TypeError('object must be string',)) + d.update((("a", {b"\0" : 1}),)):(, TypeError('expected bytes with no null',)) + d.update((("a", {"\0" : 1}),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : {%s : 1}}),)) +! d.update((("a", {"abc" : {1 : 1}}),)):(, TypeError('object must be string',)) + d.update((("a", {"abc" : {b"\0" : 1}}),)):(, TypeError('expected bytes with no null',)) + d.update((("a", {"abc" : {"\0" : 1}}),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : Mapping({%s : 1})}),)) +! d.update((("a", {"abc" : Mapping({1 : 1})}),)):(, TypeError('object must be string',)) + d.update((("a", {"abc" : Mapping({b"\0" : 1})}),)):(, TypeError('expected bytes with no null',)) + d.update((("a", {"abc" : Mapping({"\0" : 1})}),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : FailingIter()}),)):(, TypeError('unable to convert to vim structure',)) + d.update((("a", {"abc" : FailingIterNext()}),)):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : None}),)):(, TypeError('unable to convert to vim structure',)) + d.update((("a", {"abc" : {b"": 1}}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", {"abc" : {"": 1}}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", {"abc" : FailingMapping()}),)):(, NotImplementedError()) + d.update((("a", {"abc" : FailingMappingKey()}),)):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) +! d.update((("a", Mapping({1 : 1})),)):(, TypeError('object must be string',)) + d.update((("a", Mapping({b"\0" : 1})),)):(, TypeError('expected bytes with no null',)) + d.update((("a", Mapping({"\0" : 1})),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : {%s : 1}})),)) +! d.update((("a", Mapping({"abc" : {1 : 1}})),)):(, TypeError('object must be string',)) + d.update((("a", Mapping({"abc" : {b"\0" : 1}})),)):(, TypeError('expected bytes with no null',)) + d.update((("a", Mapping({"abc" : {"\0" : 1}})),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : Mapping({%s : 1})})),)) +! d.update((("a", Mapping({"abc" : Mapping({1 : 1})})),)):(, TypeError('object must be string',)) + d.update((("a", Mapping({"abc" : Mapping({b"\0" : 1})})),)):(, TypeError('expected bytes with no null',)) + d.update((("a", Mapping({"abc" : Mapping({"\0" : 1})})),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : FailingIter()})),)):(, TypeError('unable to convert to vim structure',)) + d.update((("a", Mapping({"abc" : FailingIterNext()})),)):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : None})),)):(, TypeError('unable to convert to vim structure',)) + d.update((("a", Mapping({"abc" : {b"": 1}})),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", Mapping({"abc" : {"": 1}})),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", Mapping({"abc" : FailingMapping()})),)):(, NotImplementedError()) + d.update((("a", Mapping({"abc" : FailingMappingKey()})),)):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d.update((("a", %s),)) +! d.update((("a", FailingIter()),)):(, TypeError('unable to convert to vim structure',)) + d.update((("a", FailingIterNext()),)):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", %s),)) +! d.update((("a", None),)):(, TypeError('unable to convert to vim structure',)) + d.update((("a", {b"": 1}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", {"": 1}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", FailingMapping()),)):(, NotImplementedError()) +--- 610,677 ---- + d.update(FailingMappingKey()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update(((%s, 0),)) +! d.update(((1, 0),)):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update(((b"\0", 0),)):(, TypeError('expected bytes with no null',)) + d.update((("\0", 0),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", {%s : 1}),)) +! d.update((("a", {1 : 1}),)):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update((("a", {b"\0" : 1}),)):(, TypeError('expected bytes with no null',)) + d.update((("a", {"\0" : 1}),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : {%s : 1}}),)) +! d.update((("a", {"abc" : {1 : 1}}),)):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update((("a", {"abc" : {b"\0" : 1}}),)):(, TypeError('expected bytes with no null',)) + d.update((("a", {"abc" : {"\0" : 1}}),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", {"abc" : Mapping({%s : 1})}),)) +! d.update((("a", {"abc" : Mapping({1 : 1})}),)):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update((("a", {"abc" : Mapping({b"\0" : 1})}),)):(, TypeError('expected bytes with no null',)) + d.update((("a", {"abc" : Mapping({"\0" : 1})}),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : FailingIter()}),)):(, TypeError('unable to convert FailingIter to vim structure',)) + d.update((("a", {"abc" : FailingIterNext()}),)):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : None}),)):(, TypeError('unable to convert NoneType to vim structure',)) + d.update((("a", {"abc" : {b"": 1}}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", {"abc" : {"": 1}}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", {"abc" : FailingMapping()}),)):(, NotImplementedError()) + d.update((("a", {"abc" : FailingMappingKey()}),)):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) +! d.update((("a", Mapping({1 : 1})),)):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update((("a", Mapping({b"\0" : 1})),)):(, TypeError('expected bytes with no null',)) + d.update((("a", Mapping({"\0" : 1})),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : {%s : 1}})),)) +! d.update((("a", Mapping({"abc" : {1 : 1}})),)):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update((("a", Mapping({"abc" : {b"\0" : 1}})),)):(, TypeError('expected bytes with no null',)) + d.update((("a", Mapping({"abc" : {"\0" : 1}})),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({"abc" : Mapping({%s : 1})})),)) +! d.update((("a", Mapping({"abc" : Mapping({1 : 1})})),)):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update((("a", Mapping({"abc" : Mapping({b"\0" : 1})})),)):(, TypeError('expected bytes with no null',)) + d.update((("a", Mapping({"abc" : Mapping({"\0" : 1})})),)):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : FailingIter()})),)):(, TypeError('unable to convert FailingIter to vim structure',)) + d.update((("a", Mapping({"abc" : FailingIterNext()})),)):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : None})),)):(, TypeError('unable to convert NoneType to vim structure',)) + d.update((("a", Mapping({"abc" : {b"": 1}})),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", Mapping({"abc" : {"": 1}})),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", Mapping({"abc" : FailingMapping()})),)):(, NotImplementedError()) + d.update((("a", Mapping({"abc" : FailingMappingKey()})),)):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d.update((("a", %s),)) +! d.update((("a", FailingIter()),)):(, TypeError('unable to convert FailingIter to vim structure',)) + d.update((("a", FailingIterNext()),)):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", %s),)) +! d.update((("a", None),)):(, TypeError('unable to convert NoneType to vim structure',)) + d.update((("a", {b"": 1}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", {"": 1}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", FailingMapping()),)):(, NotImplementedError()) +*************** +*** 690,752 **** + vim.List(FailingIterNext()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using vim.List([{%s : 1}]) +! vim.List([{1 : 1}]):(, TypeError('object must be string',)) + vim.List([{b"\0" : 1}]):(, TypeError('expected bytes with no null',)) + vim.List([{"\0" : 1}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : {%s : 1}}]) +! vim.List([{"abc" : {1 : 1}}]):(, TypeError('object must be string',)) + vim.List([{"abc" : {b"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + vim.List([{"abc" : {"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : Mapping({%s : 1})}]) +! vim.List([{"abc" : Mapping({1 : 1})}]):(, TypeError('object must be string',)) + vim.List([{"abc" : Mapping({b"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + vim.List([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : FailingIter()}]):(, TypeError('unable to convert to vim structure',)) + vim.List([{"abc" : FailingIterNext()}]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : None}]):(, TypeError('unable to convert to vim structure',)) + vim.List([{"abc" : {b"": 1}}]):(, ValueError('empty keys are not allowed',)) + vim.List([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) + vim.List([{"abc" : FailingMapping()}]):(, NotImplementedError()) + vim.List([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) +! vim.List([Mapping({1 : 1})]):(, TypeError('object must be string',)) + vim.List([Mapping({b"\0" : 1})]):(, TypeError('expected bytes with no null',)) + vim.List([Mapping({"\0" : 1})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : {%s : 1}})]) +! vim.List([Mapping({"abc" : {1 : 1}})]):(, TypeError('object must be string',)) + vim.List([Mapping({"abc" : {b"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + vim.List([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : Mapping({%s : 1})})]) +! vim.List([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('object must be string',)) + vim.List([Mapping({"abc" : Mapping({b"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + vim.List([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : FailingIter()})]):(, TypeError('unable to convert to vim structure',)) + vim.List([Mapping({"abc" : FailingIterNext()})]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : None})]):(, TypeError('unable to convert to vim structure',)) + vim.List([Mapping({"abc" : {b"": 1}})]):(, ValueError('empty keys are not allowed',)) + vim.List([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) + vim.List([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) + vim.List([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using vim.List([%s]) +! vim.List([FailingIter()]):(, TypeError('unable to convert to vim structure',)) + vim.List([FailingIterNext()]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([%s]) +! vim.List([None]):(, TypeError('unable to convert to vim structure',)) + vim.List([{b"": 1}]):(, ValueError('empty keys are not allowed',)) + vim.List([{"": 1}]):(, ValueError('empty keys are not allowed',)) + vim.List([FailingMapping()]):(, NotImplementedError()) +--- 690,752 ---- + vim.List(FailingIterNext()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using vim.List([{%s : 1}]) +! vim.List([{1 : 1}]):(, TypeError('expected bytes() or str() instance, but got int',)) + vim.List([{b"\0" : 1}]):(, TypeError('expected bytes with no null',)) + vim.List([{"\0" : 1}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : {%s : 1}}]) +! vim.List([{"abc" : {1 : 1}}]):(, TypeError('expected bytes() or str() instance, but got int',)) + vim.List([{"abc" : {b"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + vim.List([{"abc" : {"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([{"abc" : Mapping({%s : 1})}]) +! vim.List([{"abc" : Mapping({1 : 1})}]):(, TypeError('expected bytes() or str() instance, but got int',)) + vim.List([{"abc" : Mapping({b"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + vim.List([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : FailingIter()}]):(, TypeError('unable to convert FailingIter to vim structure',)) + vim.List([{"abc" : FailingIterNext()}]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : None}]):(, TypeError('unable to convert NoneType to vim structure',)) + vim.List([{"abc" : {b"": 1}}]):(, ValueError('empty keys are not allowed',)) + vim.List([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) + vim.List([{"abc" : FailingMapping()}]):(, NotImplementedError()) + vim.List([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) +! vim.List([Mapping({1 : 1})]):(, TypeError('expected bytes() or str() instance, but got int',)) + vim.List([Mapping({b"\0" : 1})]):(, TypeError('expected bytes with no null',)) + vim.List([Mapping({"\0" : 1})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : {%s : 1}})]) +! vim.List([Mapping({"abc" : {1 : 1}})]):(, TypeError('expected bytes() or str() instance, but got int',)) + vim.List([Mapping({"abc" : {b"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + vim.List([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({"abc" : Mapping({%s : 1})})]) +! vim.List([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('expected bytes() or str() instance, but got int',)) + vim.List([Mapping({"abc" : Mapping({b"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + vim.List([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : FailingIter()})]):(, TypeError('unable to convert FailingIter to vim structure',)) + vim.List([Mapping({"abc" : FailingIterNext()})]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : None})]):(, TypeError('unable to convert NoneType to vim structure',)) + vim.List([Mapping({"abc" : {b"": 1}})]):(, ValueError('empty keys are not allowed',)) + vim.List([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) + vim.List([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) + vim.List([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using vim.List([%s]) +! vim.List([FailingIter()]):(, TypeError('unable to convert FailingIter to vim structure',)) + vim.List([FailingIterNext()]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([%s]) +! vim.List([None]):(, TypeError('unable to convert NoneType to vim structure',)) + vim.List([{b"": 1}]):(, ValueError('empty keys are not allowed',)) + vim.List([{"": 1}]):(, ValueError('empty keys are not allowed',)) + vim.List([FailingMapping()]):(, NotImplementedError()) +*************** +*** 764,826 **** + l[:] = FailingIterNext()::(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l[:] = [{%s : 1}] +! l[:] = [{1 : 1}]:(, TypeError('object must be string',)) + l[:] = [{b"\0" : 1}]:(, TypeError('expected bytes with no null',)) + l[:] = [{"\0" : 1}]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : {%s : 1}}] +! l[:] = [{"abc" : {1 : 1}}]:(, TypeError('object must be string',)) + l[:] = [{"abc" : {b"\0" : 1}}]:(, TypeError('expected bytes with no null',)) + l[:] = [{"abc" : {"\0" : 1}}]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : Mapping({%s : 1})}] +! l[:] = [{"abc" : Mapping({1 : 1})}]:(, TypeError('object must be string',)) + l[:] = [{"abc" : Mapping({b"\0" : 1})}]:(, TypeError('expected bytes with no null',)) + l[:] = [{"abc" : Mapping({"\0" : 1})}]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : FailingIter()}]:(, TypeError('unable to convert to vim structure',)) + l[:] = [{"abc" : FailingIterNext()}]:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : None}]:(, TypeError('unable to convert to vim structure',)) + l[:] = [{"abc" : {b"": 1}}]:(, ValueError('empty keys are not allowed',)) + l[:] = [{"abc" : {"": 1}}]:(, ValueError('empty keys are not allowed',)) + l[:] = [{"abc" : FailingMapping()}]:(, NotImplementedError()) + l[:] = [{"abc" : FailingMappingKey()}]:(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] +! l[:] = [Mapping({1 : 1})]:(, TypeError('object must be string',)) + l[:] = [Mapping({b"\0" : 1})]:(, TypeError('expected bytes with no null',)) + l[:] = [Mapping({"\0" : 1})]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : {%s : 1}})] +! l[:] = [Mapping({"abc" : {1 : 1}})]:(, TypeError('object must be string',)) + l[:] = [Mapping({"abc" : {b"\0" : 1}})]:(, TypeError('expected bytes with no null',)) + l[:] = [Mapping({"abc" : {"\0" : 1}})]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : Mapping({%s : 1})})] +! l[:] = [Mapping({"abc" : Mapping({1 : 1})})]:(, TypeError('object must be string',)) + l[:] = [Mapping({"abc" : Mapping({b"\0" : 1})})]:(, TypeError('expected bytes with no null',)) + l[:] = [Mapping({"abc" : Mapping({"\0" : 1})})]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : FailingIter()})]:(, TypeError('unable to convert to vim structure',)) + l[:] = [Mapping({"abc" : FailingIterNext()})]:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : None})]:(, TypeError('unable to convert to vim structure',)) + l[:] = [Mapping({"abc" : {b"": 1}})]:(, ValueError('empty keys are not allowed',)) + l[:] = [Mapping({"abc" : {"": 1}})]:(, ValueError('empty keys are not allowed',)) + l[:] = [Mapping({"abc" : FailingMapping()})]:(, NotImplementedError()) + l[:] = [Mapping({"abc" : FailingMappingKey()})]:(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using l[:] = [%s] +! l[:] = [FailingIter()]:(, TypeError('unable to convert to vim structure',)) + l[:] = [FailingIterNext()]:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [%s] +! l[:] = [None]:(, TypeError('unable to convert to vim structure',)) + l[:] = [{b"": 1}]:(, ValueError('empty keys are not allowed',)) + l[:] = [{"": 1}]:(, ValueError('empty keys are not allowed',)) + l[:] = [FailingMapping()]:(, NotImplementedError()) +--- 764,826 ---- + l[:] = FailingIterNext()::(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l[:] = [{%s : 1}] +! l[:] = [{1 : 1}]:(, TypeError('expected bytes() or str() instance, but got int',)) + l[:] = [{b"\0" : 1}]:(, TypeError('expected bytes with no null',)) + l[:] = [{"\0" : 1}]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : {%s : 1}}] +! l[:] = [{"abc" : {1 : 1}}]:(, TypeError('expected bytes() or str() instance, but got int',)) + l[:] = [{"abc" : {b"\0" : 1}}]:(, TypeError('expected bytes with no null',)) + l[:] = [{"abc" : {"\0" : 1}}]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [{"abc" : Mapping({%s : 1})}] +! l[:] = [{"abc" : Mapping({1 : 1})}]:(, TypeError('expected bytes() or str() instance, but got int',)) + l[:] = [{"abc" : Mapping({b"\0" : 1})}]:(, TypeError('expected bytes with no null',)) + l[:] = [{"abc" : Mapping({"\0" : 1})}]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : FailingIter()}]:(, TypeError('unable to convert FailingIter to vim structure',)) + l[:] = [{"abc" : FailingIterNext()}]:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : None}]:(, TypeError('unable to convert NoneType to vim structure',)) + l[:] = [{"abc" : {b"": 1}}]:(, ValueError('empty keys are not allowed',)) + l[:] = [{"abc" : {"": 1}}]:(, ValueError('empty keys are not allowed',)) + l[:] = [{"abc" : FailingMapping()}]:(, NotImplementedError()) + l[:] = [{"abc" : FailingMappingKey()}]:(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] +! l[:] = [Mapping({1 : 1})]:(, TypeError('expected bytes() or str() instance, but got int',)) + l[:] = [Mapping({b"\0" : 1})]:(, TypeError('expected bytes with no null',)) + l[:] = [Mapping({"\0" : 1})]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : {%s : 1}})] +! l[:] = [Mapping({"abc" : {1 : 1}})]:(, TypeError('expected bytes() or str() instance, but got int',)) + l[:] = [Mapping({"abc" : {b"\0" : 1}})]:(, TypeError('expected bytes with no null',)) + l[:] = [Mapping({"abc" : {"\0" : 1}})]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({"abc" : Mapping({%s : 1})})] +! l[:] = [Mapping({"abc" : Mapping({1 : 1})})]:(, TypeError('expected bytes() or str() instance, but got int',)) + l[:] = [Mapping({"abc" : Mapping({b"\0" : 1})})]:(, TypeError('expected bytes with no null',)) + l[:] = [Mapping({"abc" : Mapping({"\0" : 1})})]:(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : FailingIter()})]:(, TypeError('unable to convert FailingIter to vim structure',)) + l[:] = [Mapping({"abc" : FailingIterNext()})]:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : None})]:(, TypeError('unable to convert NoneType to vim structure',)) + l[:] = [Mapping({"abc" : {b"": 1}})]:(, ValueError('empty keys are not allowed',)) + l[:] = [Mapping({"abc" : {"": 1}})]:(, ValueError('empty keys are not allowed',)) + l[:] = [Mapping({"abc" : FailingMapping()})]:(, NotImplementedError()) + l[:] = [Mapping({"abc" : FailingMappingKey()})]:(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using l[:] = [%s] +! l[:] = [FailingIter()]:(, TypeError('unable to convert FailingIter to vim structure',)) + l[:] = [FailingIterNext()]:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [%s] +! l[:] = [None]:(, TypeError('unable to convert NoneType to vim structure',)) + l[:] = [{b"": 1}]:(, ValueError('empty keys are not allowed',)) + l[:] = [{"": 1}]:(, ValueError('empty keys are not allowed',)) + l[:] = [FailingMapping()]:(, NotImplementedError()) +*************** +*** 832,894 **** + l.extend(FailingIterNext()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l.extend([{%s : 1}]) +! l.extend([{1 : 1}]):(, TypeError('object must be string',)) + l.extend([{b"\0" : 1}]):(, TypeError('expected bytes with no null',)) + l.extend([{"\0" : 1}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : {%s : 1}}]) +! l.extend([{"abc" : {1 : 1}}]):(, TypeError('object must be string',)) + l.extend([{"abc" : {b"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + l.extend([{"abc" : {"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : Mapping({%s : 1})}]) +! l.extend([{"abc" : Mapping({1 : 1})}]):(, TypeError('object must be string',)) + l.extend([{"abc" : Mapping({b"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + l.extend([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : FailingIter()}]):(, TypeError('unable to convert to vim structure',)) + l.extend([{"abc" : FailingIterNext()}]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : None}]):(, TypeError('unable to convert to vim structure',)) + l.extend([{"abc" : {b"": 1}}]):(, ValueError('empty keys are not allowed',)) + l.extend([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) + l.extend([{"abc" : FailingMapping()}]):(, NotImplementedError()) + l.extend([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) +! l.extend([Mapping({1 : 1})]):(, TypeError('object must be string',)) + l.extend([Mapping({b"\0" : 1})]):(, TypeError('expected bytes with no null',)) + l.extend([Mapping({"\0" : 1})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : {%s : 1}})]) +! l.extend([Mapping({"abc" : {1 : 1}})]):(, TypeError('object must be string',)) + l.extend([Mapping({"abc" : {b"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + l.extend([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : Mapping({%s : 1})})]) +! l.extend([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('object must be string',)) + l.extend([Mapping({"abc" : Mapping({b"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + l.extend([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : FailingIter()})]):(, TypeError('unable to convert to vim structure',)) + l.extend([Mapping({"abc" : FailingIterNext()})]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : None})]):(, TypeError('unable to convert to vim structure',)) + l.extend([Mapping({"abc" : {b"": 1}})]):(, ValueError('empty keys are not allowed',)) + l.extend([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) + l.extend([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) + l.extend([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using l.extend([%s]) +! l.extend([FailingIter()]):(, TypeError('unable to convert to vim structure',)) + l.extend([FailingIterNext()]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([%s]) +! l.extend([None]):(, TypeError('unable to convert to vim structure',)) + l.extend([{b"": 1}]):(, ValueError('empty keys are not allowed',)) + l.extend([{"": 1}]):(, ValueError('empty keys are not allowed',)) + l.extend([FailingMapping()]):(, NotImplementedError()) +--- 832,894 ---- + l.extend(FailingIterNext()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l.extend([{%s : 1}]) +! l.extend([{1 : 1}]):(, TypeError('expected bytes() or str() instance, but got int',)) + l.extend([{b"\0" : 1}]):(, TypeError('expected bytes with no null',)) + l.extend([{"\0" : 1}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : {%s : 1}}]) +! l.extend([{"abc" : {1 : 1}}]):(, TypeError('expected bytes() or str() instance, but got int',)) + l.extend([{"abc" : {b"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + l.extend([{"abc" : {"\0" : 1}}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([{"abc" : Mapping({%s : 1})}]) +! l.extend([{"abc" : Mapping({1 : 1})}]):(, TypeError('expected bytes() or str() instance, but got int',)) + l.extend([{"abc" : Mapping({b"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + l.extend([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : FailingIter()}]):(, TypeError('unable to convert FailingIter to vim structure',)) + l.extend([{"abc" : FailingIterNext()}]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : None}]):(, TypeError('unable to convert NoneType to vim structure',)) + l.extend([{"abc" : {b"": 1}}]):(, ValueError('empty keys are not allowed',)) + l.extend([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) + l.extend([{"abc" : FailingMapping()}]):(, NotImplementedError()) + l.extend([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) +! l.extend([Mapping({1 : 1})]):(, TypeError('expected bytes() or str() instance, but got int',)) + l.extend([Mapping({b"\0" : 1})]):(, TypeError('expected bytes with no null',)) + l.extend([Mapping({"\0" : 1})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : {%s : 1}})]) +! l.extend([Mapping({"abc" : {1 : 1}})]):(, TypeError('expected bytes() or str() instance, but got int',)) + l.extend([Mapping({"abc" : {b"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + l.extend([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({"abc" : Mapping({%s : 1})})]) +! l.extend([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('expected bytes() or str() instance, but got int',)) + l.extend([Mapping({"abc" : Mapping({b"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + l.extend([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : FailingIter()})]):(, TypeError('unable to convert FailingIter to vim structure',)) + l.extend([Mapping({"abc" : FailingIterNext()})]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : None})]):(, TypeError('unable to convert NoneType to vim structure',)) + l.extend([Mapping({"abc" : {b"": 1}})]):(, ValueError('empty keys are not allowed',)) + l.extend([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) + l.extend([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) + l.extend([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using l.extend([%s]) +! l.extend([FailingIter()]):(, TypeError('unable to convert FailingIter to vim structure',)) + l.extend([FailingIterNext()]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([%s]) +! l.extend([None]):(, TypeError('unable to convert NoneType to vim structure',)) + l.extend([{b"": 1}]):(, ValueError('empty keys are not allowed',)) + l.extend([{"": 1}]):(, ValueError('empty keys are not allowed',)) + l.extend([FailingMapping()]):(, NotImplementedError()) +*************** +*** 897,1030 **** + >> ListSetattr + del l.locked:(, AttributeError('cannot delete vim.List attributes',)) + l.locked = FailingTrue():(, NotImplementedError()) +! l.xxx = True:(, AttributeError('cannot set this attribute',)) + > Function + >> FunctionConstructor +! vim.Function("123"):(, ValueError('unnamed function does not exist',)) +! vim.Function("xxx_non_existent_function_xxx"):(, ValueError('function does not exist',)) + vim.Function("xxx#non#existent#function#xxx"):NOT FAILED + >> FunctionCall + >>> Testing StringToChars using f({%s : 1}) +! f({1 : 1}):(, TypeError('object must be string',)) + f({b"\0" : 1}):(, TypeError('expected bytes with no null',)) + f({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f({"abc" : {%s : 1}}) +! f({"abc" : {1 : 1}}):(, TypeError('object must be string',)) + f({"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) + f({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f({"abc" : Mapping({%s : 1})}) +! f({"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) + f({"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) + f({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using f({"abc" : %s}) +! f({"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) + f({"abc" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using f({"abc" : %s}) +! f({"abc" : None}):(, TypeError('unable to convert to vim structure',)) + f({"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + f({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) + f({"abc" : FailingMapping()}):(, NotImplementedError()) + f({"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) +! f(Mapping({1 : 1})):(, TypeError('object must be string',)) + f(Mapping({b"\0" : 1})):(, TypeError('expected bytes with no null',)) + f(Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : {%s : 1}})) +! f(Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) + f(Mapping({"abc" : {b"\0" : 1}})):(, TypeError('expected bytes with no null',)) + f(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : Mapping({%s : 1})})) +! f(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) + f(Mapping({"abc" : Mapping({b"\0" : 1})})):(, TypeError('expected bytes with no null',)) + f(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert to vim structure',)) + f(Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) + f(Mapping({"abc" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) + f(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) + f(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) + f(Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using f(%s) +! f(FailingIter()):(, TypeError('unable to convert to vim structure',)) + f(FailingIterNext()):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using f(%s) +! f(None):(, TypeError('unable to convert to vim structure',)) + f({b"": 1}):(, ValueError('empty keys are not allowed',)) + f({"": 1}):(, ValueError('empty keys are not allowed',)) + f(FailingMapping()):(, NotImplementedError()) + f(FailingMappingKey()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using fd(self={%s : 1}) +! fd(self={1 : 1}):(, TypeError('object must be string',)) + fd(self={b"\0" : 1}):(, TypeError('expected bytes with no null',)) + fd(self={"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : {%s : 1}}) +! fd(self={"abc" : {1 : 1}}):(, TypeError('object must be string',)) + fd(self={"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) + fd(self={"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : Mapping({%s : 1})}) +! fd(self={"abc" : Mapping({1 : 1})}):(, TypeError('object must be string',)) + fd(self={"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) + fd(self={"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using fd(self={"abc" : %s}) +! fd(self={"abc" : FailingIter()}):(, TypeError('unable to convert to vim structure',)) + fd(self={"abc" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self={"abc" : %s}) +! fd(self={"abc" : None}):(, TypeError('unable to convert to vim structure',)) + fd(self={"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + fd(self={"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) + fd(self={"abc" : FailingMapping()}):(, NotImplementedError()) + fd(self={"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) +! fd(self=Mapping({1 : 1})):(, TypeError('object must be string',)) + fd(self=Mapping({b"\0" : 1})):(, TypeError('expected bytes with no null',)) + fd(self=Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : {%s : 1}})) +! fd(self=Mapping({"abc" : {1 : 1}})):(, TypeError('object must be string',)) + fd(self=Mapping({"abc" : {b"\0" : 1}})):(, TypeError('expected bytes with no null',)) + fd(self=Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : Mapping({%s : 1})})) +! fd(self=Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('object must be string',)) + fd(self=Mapping({"abc" : Mapping({b"\0" : 1})})):(, TypeError('expected bytes with no null',)) + fd(self=Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert to vim structure',)) + fd(self=Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : None})):(, TypeError('unable to convert to vim structure',)) + fd(self=Mapping({"abc" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) + fd(self=Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) + fd(self=Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) + fd(self=Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using fd(self=%s) +! fd(self=FailingIter()):(, TypeError('unable to convert object to vim dictionary',)) +! fd(self=FailingIterNext()):(, TypeError('unable to convert object to vim dictionary',)) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=%s) +! fd(self=None):(, TypeError('unable to convert object to vim dictionary',)) + fd(self={b"": 1}):(, ValueError('empty keys are not allowed',)) + fd(self={"": 1}):(, ValueError('empty keys are not allowed',)) + fd(self=FailingMapping()):(, NotImplementedError()) +--- 897,1030 ---- + >> ListSetattr + del l.locked:(, AttributeError('cannot delete vim.List attributes',)) + l.locked = FailingTrue():(, NotImplementedError()) +! l.xxx = True:(, AttributeError('cannot set attribute xxx',)) + > Function + >> FunctionConstructor +! vim.Function("123"):(, ValueError('unnamed function 123 does not exist',)) +! vim.Function("xxx_non_existent_function_xxx"):(, ValueError('function xxx_non_existent_function_xxx does not exist',)) + vim.Function("xxx#non#existent#function#xxx"):NOT FAILED + >> FunctionCall + >>> Testing StringToChars using f({%s : 1}) +! f({1 : 1}):(, TypeError('expected bytes() or str() instance, but got int',)) + f({b"\0" : 1}):(, TypeError('expected bytes with no null',)) + f({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f({"abc" : {%s : 1}}) +! f({"abc" : {1 : 1}}):(, TypeError('expected bytes() or str() instance, but got int',)) + f({"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) + f({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f({"abc" : Mapping({%s : 1})}) +! f({"abc" : Mapping({1 : 1})}):(, TypeError('expected bytes() or str() instance, but got int',)) + f({"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) + f({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using f({"abc" : %s}) +! f({"abc" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) + f({"abc" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using f({"abc" : %s}) +! f({"abc" : None}):(, TypeError('unable to convert NoneType to vim structure',)) + f({"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + f({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) + f({"abc" : FailingMapping()}):(, NotImplementedError()) + f({"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) +! f(Mapping({1 : 1})):(, TypeError('expected bytes() or str() instance, but got int',)) + f(Mapping({b"\0" : 1})):(, TypeError('expected bytes with no null',)) + f(Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : {%s : 1}})) +! f(Mapping({"abc" : {1 : 1}})):(, TypeError('expected bytes() or str() instance, but got int',)) + f(Mapping({"abc" : {b"\0" : 1}})):(, TypeError('expected bytes with no null',)) + f(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using f(Mapping({"abc" : Mapping({%s : 1})})) +! f(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('expected bytes() or str() instance, but got int',)) + f(Mapping({"abc" : Mapping({b"\0" : 1})})):(, TypeError('expected bytes with no null',)) + f(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert FailingIter to vim structure',)) + f(Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : None})):(, TypeError('unable to convert NoneType to vim structure',)) + f(Mapping({"abc" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) + f(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) + f(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) + f(Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using f(%s) +! f(FailingIter()):(, TypeError('unable to convert FailingIter to vim structure',)) + f(FailingIterNext()):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using f(%s) +! f(None):(, TypeError('unable to convert NoneType to vim structure',)) + f({b"": 1}):(, ValueError('empty keys are not allowed',)) + f({"": 1}):(, ValueError('empty keys are not allowed',)) + f(FailingMapping()):(, NotImplementedError()) + f(FailingMappingKey()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using fd(self={%s : 1}) +! fd(self={1 : 1}):(, TypeError('expected bytes() or str() instance, but got int',)) + fd(self={b"\0" : 1}):(, TypeError('expected bytes with no null',)) + fd(self={"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : {%s : 1}}) +! fd(self={"abc" : {1 : 1}}):(, TypeError('expected bytes() or str() instance, but got int',)) + fd(self={"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) + fd(self={"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self={"abc" : Mapping({%s : 1})}) +! fd(self={"abc" : Mapping({1 : 1})}):(, TypeError('expected bytes() or str() instance, but got int',)) + fd(self={"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) + fd(self={"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using fd(self={"abc" : %s}) +! fd(self={"abc" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) + fd(self={"abc" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self={"abc" : %s}) +! fd(self={"abc" : None}):(, TypeError('unable to convert NoneType to vim structure',)) + fd(self={"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + fd(self={"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) + fd(self={"abc" : FailingMapping()}):(, NotImplementedError()) + fd(self={"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) +! fd(self=Mapping({1 : 1})):(, TypeError('expected bytes() or str() instance, but got int',)) + fd(self=Mapping({b"\0" : 1})):(, TypeError('expected bytes with no null',)) + fd(self=Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : {%s : 1}})) +! fd(self=Mapping({"abc" : {1 : 1}})):(, TypeError('expected bytes() or str() instance, but got int',)) + fd(self=Mapping({"abc" : {b"\0" : 1}})):(, TypeError('expected bytes with no null',)) + fd(self=Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({"abc" : Mapping({%s : 1})})) +! fd(self=Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('expected bytes() or str() instance, but got int',)) + fd(self=Mapping({"abc" : Mapping({b"\0" : 1})})):(, TypeError('expected bytes with no null',)) + fd(self=Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) + <<< Finished + >>> Testing *Iter* using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert FailingIter to vim structure',)) + fd(self=Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : None})):(, TypeError('unable to convert NoneType to vim structure',)) + fd(self=Mapping({"abc" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) + fd(self=Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) + fd(self=Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) + fd(self=Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using fd(self=%s) +! fd(self=FailingIter()):(, TypeError('unable to convert FailingIter to vim dictionary',)) +! fd(self=FailingIterNext()):(, TypeError('unable to convert FailingIterNext to vim dictionary',)) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=%s) +! fd(self=None):(, TypeError('unable to convert NoneType to vim dictionary',)) + fd(self={b"": 1}):(, ValueError('empty keys are not allowed',)) + fd(self={"": 1}):(, ValueError('empty keys are not allowed',)) + fd(self=FailingMapping()):(, NotImplementedError()) +*************** +*** 1043,1049 **** + >> WindowAttr + vim.current.window.xxx:(, AttributeError("'vim.window' object has no attribute 'xxx'",)) + >> WindowSetattr +! vim.current.window.buffer = 0:(, TypeError('readonly attribute',)) + vim.current.window.cursor = (100000000, 100000000):(, error('cursor position outside buffer',)) + vim.current.window.cursor = True:(, TypeError('argument must be 2-item sequence, not bool',)) + vim.current.window.height = "abc":(, TypeError('an integer is required',)) +--- 1043,1049 ---- + >> WindowAttr + vim.current.window.xxx:(, AttributeError("'vim.window' object has no attribute 'xxx'",)) + >> WindowSetattr +! vim.current.window.buffer = 0:(, TypeError('readonly attribute: buffer',)) + vim.current.window.cursor = (100000000, 100000000):(, error('cursor position outside buffer',)) + vim.current.window.cursor = True:(, TypeError('argument must be 2-item sequence, not bool',)) + vim.current.window.height = "abc":(, TypeError('an integer is required',)) +*************** +*** 1071,1080 **** + >> BufferAttr + vim.current.buffer.xxx:(, AttributeError("'vim.buffer' object has no attribute 'xxx'",)) + >> BufferSetattr +! vim.current.buffer.name = True:(, TypeError('object must be string',)) + vim.current.buffer.xxx = True:(, AttributeError('xxx',)) + >> BufferMark +! vim.current.buffer.mark(0):(, TypeError('object must be string',)) + vim.current.buffer.mark("abc"):(, ValueError('mark name must be a single character',)) + vim.current.buffer.mark("!"):(, error('invalid mark name',)) + >> BufferRange +--- 1071,1080 ---- + >> BufferAttr + vim.current.buffer.xxx:(, AttributeError("'vim.buffer' object has no attribute 'xxx'",)) + >> BufferSetattr +! vim.current.buffer.name = True:(, TypeError('expected bytes() or str() instance, but got bool',)) + vim.current.buffer.xxx = True:(, AttributeError('xxx',)) + >> BufferMark +! vim.current.buffer.mark(0):(, TypeError('expected bytes() or str() instance, but got int',)) + vim.current.buffer.mark("abc"):(, ValueError('mark name must be a single character',)) + vim.current.buffer.mark("!"):(, error('invalid mark name',)) + >> BufferRange +*************** +*** 1088,1096 **** + vim.current.xxx:(, AttributeError("'vim.currentdata' object has no attribute 'xxx'",)) + >> CurrentSetattr + vim.current.line = True:(, TypeError('bad argument type for built-in operation',)) +! vim.current.buffer = True:(, TypeError('expected vim.Buffer object',)) +! vim.current.window = True:(, TypeError('expected vim.Window object',)) +! vim.current.tabpage = True:(, TypeError('expected vim.TabPage object',)) + vim.current.xxx = True:(, AttributeError('xxx',)) + 3,xx + before +--- 1088,1096 ---- + vim.current.xxx:(, AttributeError("'vim.currentdata' object has no attribute 'xxx'",)) + >> CurrentSetattr + vim.current.line = True:(, TypeError('bad argument type for built-in operation',)) +! vim.current.buffer = True:(, TypeError('expected vim.Buffer object, but got bool',)) +! vim.current.window = True:(, TypeError('expected vim.Window object, but got bool',)) +! vim.current.tabpage = True:(, TypeError('expected vim.TabPage object, but got bool',)) + vim.current.xxx = True:(, AttributeError('xxx',)) + 3,xx + before +*** ../vim-7.3.1229/src/version.c 2013-06-23 13:28:11.000000000 +0200 +--- src/version.c 2013-06-23 13:30:05.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1230, + /**/ + +-- +MAN: You don't frighten us, English pig-dog! Go and boil your bottoms, + son of a silly person. I blow my nose on you, so-called Arthur-king, + you and your silly English K...kaniggets. + He puts hands to his ears and blows a raspberry. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From c6fc01a7b1896d0ec190e3f5ee67ab73deb4ffb5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:27 +0200 Subject: [PATCH 1124/3340] - patchlevel 1231 --- 7.3.1231 | 678 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 678 insertions(+) create mode 100644 7.3.1231 diff --git a/7.3.1231 b/7.3.1231 new file mode 100644 index 00000000..13c2bc3a --- /dev/null +++ b/7.3.1231 @@ -0,0 +1,678 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1231 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1231 +Problem: Python: use of numbers not consistent. +Solution: Add support for Number protocol. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c, + src/testdir/test86.ok, src/testdir/test87.ok + + +*** ../vim-7.3.1230/src/if_py_both.h 2013-06-23 13:46:36.000000000 +0200 +--- src/if_py_both.h 2013-06-23 14:15:25.000000000 +0200 +*************** +*** 151,156 **** +--- 151,245 ---- + return (char_u *) p; + } + ++ #define NUMBER_LONG 1 ++ #define NUMBER_INT 2 ++ #define NUMBER_NATURAL 4 ++ #define NUMBER_UNSIGNED 8 ++ ++ static int ++ NumberToLong(PyObject *obj, long *result, int flags) ++ { ++ #if PY_MAJOR_VERSION < 3 ++ if (PyInt_Check(obj)) ++ { ++ *result = PyInt_AsLong(obj); ++ if (PyErr_Occurred()) ++ return -1; ++ } ++ else ++ #endif ++ if (PyLong_Check(obj)) ++ { ++ *result = PyLong_AsLong(obj); ++ if (PyErr_Occurred()) ++ return -1; ++ } ++ else if (PyNumber_Check(obj)) ++ { ++ PyObject *num; ++ ++ if (!(num = PyNumber_Long(obj))) ++ return -1; ++ ++ *result = PyLong_AsLong(num); ++ ++ Py_DECREF(num); ++ ++ if (PyErr_Occurred()) ++ return -1; ++ } ++ else ++ { ++ PyErr_FORMAT(PyExc_TypeError, ++ #if PY_MAJOR_VERSION < 3 ++ "expected int(), long() or something supporting " ++ "coercing to long(), but got %s" ++ #else ++ "expected int() or something supporting coercing to int(), " ++ "but got %s" ++ #endif ++ , Py_TYPE_NAME(obj)); ++ return -1; ++ } ++ ++ if (flags & NUMBER_INT) ++ { ++ if (*result > INT_MAX) ++ { ++ PyErr_SET_STRING(PyExc_OverflowError, ++ "value is too large to fit into C int type"); ++ return -1; ++ } ++ else if (*result < INT_MIN) ++ { ++ PyErr_SET_STRING(PyExc_OverflowError, ++ "value is too small to fit into C int type"); ++ return -1; ++ } ++ } ++ ++ if (flags & NUMBER_NATURAL) ++ { ++ if (*result <= 0) ++ { ++ PyErr_SET_STRING(PyExc_ValueError, ++ "number must be greater then zero"); ++ return -1; ++ } ++ } ++ else if (flags & NUMBER_UNSIGNED) ++ { ++ if (*result < 0) ++ { ++ PyErr_SET_STRING(PyExc_ValueError, ++ "number must be greater or equal to zero"); ++ return -1; ++ } ++ } ++ ++ return 0; ++ } ++ + static int + add_string(PyObject *list, char *s) + { +*************** +*** 243,255 **** + + if (strcmp(name, "softspace") == 0) + { +! if (!PyInt_Check(val)) +! { +! PyErr_SET_STRING(PyExc_TypeError, "softspace must be an integer"); + return -1; +- } +- +- self->softspace = PyInt_AsLong(val); + return 0; + } + +--- 332,339 ---- + + if (strcmp(name, "softspace") == 0) + { +! if (NumberToLong(val, &(self->softspace), NUMBER_UNSIGNED)) + return -1; + return 0; + } + +*************** +*** 2839,2861 **** + } + else if (flags & SOPT_NUM) + { +! int val; + +! #if PY_MAJOR_VERSION < 3 +! if (PyInt_Check(valObject)) +! val = PyInt_AsLong(valObject); +! else +! #endif +! if (PyLong_Check(valObject)) +! val = PyLong_AsLong(valObject); +! else + { +- PyErr_SET_STRING(PyExc_TypeError, "object must be integer"); + Py_XDECREF(todecref); + return -1; + } + +! r = set_option_value_for(key, val, NULL, opt_flags, + self->opt_type, self->from); + } + else +--- 2923,2937 ---- + } + else if (flags & SOPT_NUM) + { +! long val; + +! if (NumberToLong(valObject, &val, NUMBER_INT)) + { + Py_XDECREF(todecref); + return -1; + } + +! r = set_option_value_for(key, (int) val, NULL, opt_flags, + self->opt_type, self->from); + } + else +*************** +*** 3265,3274 **** + } + else if (strcmp(name, "height") == 0) + { +! int height; + win_T *savewin; + +! if (!PyArg_Parse(val, "i", &height)) + return -1; + + #ifdef FEAT_GUI +--- 3341,3350 ---- + } + else if (strcmp(name, "height") == 0) + { +! long height; + win_T *savewin; + +! if (NumberToLong(val, &height, NUMBER_INT)) + return -1; + + #ifdef FEAT_GUI +*************** +*** 3278,3284 **** + curwin = self->win; + + VimTryStart(); +! win_setheight(height); + curwin = savewin; + if (VimTryEnd()) + return -1; +--- 3354,3360 ---- + curwin = self->win; + + VimTryStart(); +! win_setheight((int) height); + curwin = savewin; + if (VimTryEnd()) + return -1; +*************** +*** 3288,3297 **** + #ifdef FEAT_VERTSPLIT + else if (strcmp(name, "width") == 0) + { +! int width; + win_T *savewin; + +! if (!PyArg_Parse(val, "i", &width)) + return -1; + + #ifdef FEAT_GUI +--- 3364,3373 ---- + #ifdef FEAT_VERTSPLIT + else if (strcmp(name, "width") == 0) + { +! long width; + win_T *savewin; + +! if (NumberToLong(val, &width, NUMBER_INT)) + return -1; + + #ifdef FEAT_GUI +*************** +*** 3301,3307 **** + curwin = self->win; + + VimTryStart(); +! win_setwidth(width); + curwin = savewin; + if (VimTryEnd()) + return -1; +--- 3377,3383 ---- + curwin = self->win; + + VimTryStart(); +! win_setwidth((int) width); + curwin = savewin; + if (VimTryEnd()) + return -1; +*************** +*** 4555,4576 **** + BufMapItem(PyObject *self UNUSED, PyObject *keyObject) + { + buf_T *b; +! int bnr; + +! #if PY_MAJOR_VERSION < 3 +! if (PyInt_Check(keyObject)) +! bnr = PyInt_AsLong(keyObject); +! else +! #endif +! if (PyLong_Check(keyObject)) +! bnr = PyLong_AsLong(keyObject); +! else +! { +! PyErr_SET_STRING(PyExc_TypeError, "key must be integer"); + return NULL; +- } + +! b = buflist_findnr(bnr); + + if (b) + return BufferNew(b); +--- 4631,4642 ---- + BufMapItem(PyObject *self UNUSED, PyObject *keyObject) + { + buf_T *b; +! long bnr; + +! if (NumberToLong(keyObject, &bnr, NUMBER_INT|NUMBER_NATURAL)) + return NULL; + +! b = buflist_findnr((int) bnr); + + if (b) + return BufferNew(b); +*************** +*** 5345,5356 **** +--- 5411,5426 ---- + { + tv->v_type = VAR_NUMBER; + tv->vval.v_number = (varnumber_T) PyInt_AsLong(obj); ++ if (PyErr_Occurred()) ++ return -1; + } + #endif + else if (PyLong_Check(obj)) + { + tv->v_type = VAR_NUMBER; + tv->vval.v_number = (varnumber_T) PyLong_AsLong(obj); ++ if (PyErr_Occurred()) ++ return -1; + } + else if (PyDict_Check(obj)) + return convert_dl(obj, tv, pydict_to_tv, lookup_dict); +*************** +*** 5367,5372 **** +--- 5437,5454 ---- + return convert_dl(obj, tv, pyseq_to_tv, lookup_dict); + else if (PyMapping_Check(obj)) + return convert_dl(obj, tv, pymap_to_tv, lookup_dict); ++ else if (PyNumber_Check(obj)) ++ { ++ PyObject *num; ++ ++ if (!(num = PyNumber_Long(obj))) ++ return -1; ++ ++ tv->v_type = VAR_NUMBER; ++ tv->vval.v_number = (varnumber_T) PyLong_AsLong(num); ++ ++ Py_DECREF(num); ++ } + else + { + PyErr_FORMAT(PyExc_TypeError, +*** ../vim-7.3.1230/src/if_python3.c 2013-06-23 13:46:36.000000000 +0200 +--- src/if_python3.c 2013-06-23 14:15:25.000000000 +0200 +*************** +*** 160,165 **** +--- 160,166 ---- + # define PyMapping_Keys py3_PyMapping_Keys + # define PyIter_Next py3_PyIter_Next + # define PyObject_GetIter py3_PyObject_GetIter ++ # define PyObject_Repr py3_PyObject_Repr + # define PyObject_GetItem py3_PyObject_GetItem + # define PyObject_IsTrue py3_PyObject_IsTrue + # define PyModule_GetDict py3_PyModule_GetDict +*************** +*** 211,216 **** +--- 212,219 ---- + # define PyType_Type (*py3_PyType_Type) + # define PySlice_Type (*py3_PySlice_Type) + # define PyFloat_Type (*py3_PyFloat_Type) ++ # define PyNumber_Check (*py3_PyNumber_Check) ++ # define PyNumber_Long (*py3_PyNumber_Long) + # define PyBool_Type (*py3_PyBool_Type) + # define PyErr_NewException py3_PyErr_NewException + # ifdef Py_DEBUG +*************** +*** 310,315 **** +--- 313,319 ---- + static PyObject* (*py3_PyDict_New)(void); + static PyObject* (*py3_PyIter_Next)(PyObject *); + static PyObject* (*py3_PyObject_GetIter)(PyObject *); ++ static PyObject* (*py3_PyObject_Repr)(PyObject *); + static PyObject* (*py3_PyObject_GetItem)(PyObject *, PyObject *); + static int (*py3_PyObject_IsTrue)(PyObject *); + static PyObject* (*py3_Py_BuildValue)(char *, ...); +*************** +*** 365,370 **** +--- 369,376 ---- + static PyTypeObject* py3_PySlice_Type; + static PyTypeObject* py3_PyFloat_Type; + static PyTypeObject* py3_PyBool_Type; ++ static int (*py3_PyNumber_Check)(PyObject *); ++ static PyObject* (*py3_PyNumber_Long)(PyObject *); + static PyObject* (*py3_PyErr_NewException)(char *name, PyObject *base, PyObject *dict); + static PyObject* (*py3_PyCapsule_New)(void *, char *, PyCapsule_Destructor); + static void* (*py3_PyCapsule_GetPointer)(PyObject *, char *); +*************** +*** 399,404 **** +--- 405,411 ---- + static PyObject *p3imp_PyExc_ValueError; + static PyObject *p3imp_PyExc_RuntimeError; + static PyObject *p3imp_PyExc_ImportError; ++ static PyObject *p3imp_PyExc_OverflowError; + + # define PyExc_AttributeError p3imp_PyExc_AttributeError + # define PyExc_IndexError p3imp_PyExc_IndexError +*************** +*** 408,413 **** +--- 415,421 ---- + # define PyExc_ValueError p3imp_PyExc_ValueError + # define PyExc_RuntimeError p3imp_PyExc_RuntimeError + # define PyExc_ImportError p3imp_PyExc_ImportError ++ # define PyExc_OverflowError p3imp_PyExc_OverflowError + + /* + * Table of name to function pointer of python. +*************** +*** 469,474 **** +--- 477,483 ---- + {"PyMapping_Keys", (PYTHON_PROC*)&py3_PyMapping_Keys}, + {"PyIter_Next", (PYTHON_PROC*)&py3_PyIter_Next}, + {"PyObject_GetIter", (PYTHON_PROC*)&py3_PyObject_GetIter}, ++ {"PyObject_Repr", (PYTHON_PROC*)&py3_PyObject_Repr}, + {"PyObject_GetItem", (PYTHON_PROC*)&py3_PyObject_GetItem}, + {"PyObject_IsTrue", (PYTHON_PROC*)&py3_PyObject_IsTrue}, + {"PyLong_FromLong", (PYTHON_PROC*)&py3_PyLong_FromLong}, +*************** +*** 518,523 **** +--- 527,534 ---- + {"PySlice_Type", (PYTHON_PROC*)&py3_PySlice_Type}, + {"PyFloat_Type", (PYTHON_PROC*)&py3_PyFloat_Type}, + {"PyBool_Type", (PYTHON_PROC*)&py3_PyBool_Type}, ++ {"PyNumber_Check", (PYTHON_PROC*)&py3_PyNumber_Check}, ++ {"PyNumber_Long", (PYTHON_PROC*)&py3_PyNumber_Long}, + {"PyErr_NewException", (PYTHON_PROC*)&py3_PyErr_NewException}, + # ifdef Py_DEBUG + {"_Py_NegativeRefcount", (PYTHON_PROC*)&py3__Py_NegativeRefcount}, +*************** +*** 672,677 **** +--- 683,689 ---- + p3imp_PyExc_ValueError = PyDict_GetItemString(exdict, "ValueError"); + p3imp_PyExc_RuntimeError = PyDict_GetItemString(exdict, "RuntimeError"); + p3imp_PyExc_ImportError = PyDict_GetItemString(exdict, "ImportError"); ++ p3imp_PyExc_OverflowError = PyDict_GetItemString(exdict, "OverflowError"); + Py_XINCREF(p3imp_PyExc_AttributeError); + Py_XINCREF(p3imp_PyExc_IndexError); + Py_XINCREF(p3imp_PyExc_KeyError); +*************** +*** 680,685 **** +--- 692,698 ---- + Py_XINCREF(p3imp_PyExc_ValueError); + Py_XINCREF(p3imp_PyExc_RuntimeError); + Py_XINCREF(p3imp_PyExc_ImportError); ++ Py_XINCREF(p3imp_PyExc_OverflowError); + Py_XDECREF(exmod); + } + #endif /* DYNAMIC_PYTHON3 */ +*** ../vim-7.3.1230/src/if_python.c 2013-06-23 13:46:36.000000000 +0200 +--- src/if_python.c 2013-06-23 14:15:25.000000000 +0200 +*************** +*** 220,225 **** +--- 220,226 ---- + # define PyObject_CallFunctionObjArgs dll_PyObject_CallFunctionObjArgs + # define PyObject_CallFunction dll_PyObject_CallFunction + # define PyObject_Call dll_PyObject_Call ++ # define PyObject_Repr dll_PyObject_Repr + # define PyString_AsString dll_PyString_AsString + # define PyString_AsStringAndSize dll_PyString_AsStringAndSize + # define PyString_FromString dll_PyString_FromString +*************** +*** 233,238 **** +--- 234,241 ---- + # define PyFloat_AsDouble dll_PyFloat_AsDouble + # define PyFloat_FromDouble dll_PyFloat_FromDouble + # define PyFloat_Type (*dll_PyFloat_Type) ++ # define PyNumber_Check dll_PyNumber_Check ++ # define PyNumber_Long dll_PyNumber_Long + # define PyImport_AddModule (*dll_PyImport_AddModule) + # define PySys_SetObject dll_PySys_SetObject + # define PySys_GetObject dll_PySys_GetObject +*************** +*** 360,365 **** +--- 363,369 ---- + static PyObject* (*dll_PyObject_CallFunctionObjArgs)(PyObject *, ...); + static PyObject* (*dll_PyObject_CallFunction)(PyObject *, char *, ...); + static PyObject* (*dll_PyObject_Call)(PyObject *, PyObject *, PyObject *); ++ static PyObject* (*dll_PyObject_Repr)(PyObject *); + static char*(*dll_PyString_AsString)(PyObject *); + static int(*dll_PyString_AsStringAndSize)(PyObject *, char **, int *); + static PyObject*(*dll_PyString_FromString)(const char *); +*************** +*** 372,377 **** +--- 376,383 ---- + static double(*dll_PyFloat_AsDouble)(PyObject *); + static PyObject*(*dll_PyFloat_FromDouble)(double); + static PyTypeObject* dll_PyFloat_Type; ++ static int(*dll_PyNumber_Check)(PyObject *); ++ static PyObject*(*dll_PyNumber_Long)(PyObject *); + static int(*dll_PySys_SetObject)(char *, PyObject *); + static PyObject *(*dll_PySys_GetObject)(char *); + static int(*dll_PySys_SetArgv)(int, char **); +*************** +*** 440,445 **** +--- 446,452 ---- + static PyObject *imp_PyExc_ValueError; + static PyObject *imp_PyExc_RuntimeError; + static PyObject *imp_PyExc_ImportError; ++ static PyObject *imp_PyExc_OverflowError; + + # define PyExc_AttributeError imp_PyExc_AttributeError + # define PyExc_IndexError imp_PyExc_IndexError +*************** +*** 449,454 **** +--- 456,462 ---- + # define PyExc_ValueError imp_PyExc_ValueError + # define PyExc_RuntimeError imp_PyExc_RuntimeError + # define PyExc_ImportError imp_PyExc_ImportError ++ # define PyExc_OverflowError imp_PyExc_OverflowError + + /* + * Table of name to function pointer of python. +*************** +*** 533,538 **** +--- 541,547 ---- + {"PyObject_CallFunctionObjArgs", (PYTHON_PROC*)&dll_PyObject_CallFunctionObjArgs}, + {"PyObject_CallFunction", (PYTHON_PROC*)&dll_PyObject_CallFunction}, + {"PyObject_Call", (PYTHON_PROC*)&dll_PyObject_Call}, ++ {"PyObject_Repr", (PYTHON_PROC*)&dll_PyObject_Repr}, + {"PyString_AsString", (PYTHON_PROC*)&dll_PyString_AsString}, + {"PyString_AsStringAndSize", (PYTHON_PROC*)&dll_PyString_AsStringAndSize}, + {"PyString_FromString", (PYTHON_PROC*)&dll_PyString_FromString}, +*************** +*** 545,550 **** +--- 554,561 ---- + {"PyFloat_AsDouble", (PYTHON_PROC*)&dll_PyFloat_AsDouble}, + {"PyFloat_FromDouble", (PYTHON_PROC*)&dll_PyFloat_FromDouble}, + {"PyImport_AddModule", (PYTHON_PROC*)&dll_PyImport_AddModule}, ++ {"PyNumber_Check", (PYTHON_PROC*)&dll_PyNumber_Check}, ++ {"PyNumber_Long", (PYTHON_PROC*)&dll_PyNumber_Long}, + {"PySys_SetObject", (PYTHON_PROC*)&dll_PySys_SetObject}, + {"PySys_GetObject", (PYTHON_PROC*)&dll_PySys_GetObject}, + {"PySys_SetArgv", (PYTHON_PROC*)&dll_PySys_SetArgv}, +*************** +*** 722,727 **** +--- 733,739 ---- + imp_PyExc_ValueError = PyDict_GetItemString(exdict, "ValueError"); + imp_PyExc_RuntimeError = PyDict_GetItemString(exdict, "RuntimeError"); + imp_PyExc_ImportError = PyDict_GetItemString(exdict, "ImportError"); ++ imp_PyExc_OverflowError = PyDict_GetItemString(exdict, "OverflowError"); + Py_XINCREF(imp_PyExc_AttributeError); + Py_XINCREF(imp_PyExc_IndexError); + Py_XINCREF(imp_PyExc_KeyError); +*************** +*** 730,735 **** +--- 742,748 ---- + Py_XINCREF(imp_PyExc_ValueError); + Py_XINCREF(imp_PyExc_RuntimeError); + Py_XINCREF(imp_PyExc_ImportError); ++ Py_XINCREF(imp_PyExc_OverflowError); + Py_XDECREF(exmod); + } + #endif /* DYNAMIC_PYTHON */ +*** ../vim-7.3.1230/src/testdir/test86.ok 2013-06-23 13:46:36.000000000 +0200 +--- src/testdir/test86.ok 2013-06-23 14:15:25.000000000 +0200 +*************** +*** 438,444 **** + > Output + >> OutputSetattr + del sys.stdout.softspace:AttributeError:("can't delete OutputObject attributes",) +! sys.stdout.softspace = []:TypeError:('softspace must be an integer',) + sys.stdout.attr = None:AttributeError:('invalid attribute: attr',) + >> OutputWrite + sys.stdout.write(None):TypeError:('coercing to Unicode: need string or buffer, NoneType found',) +--- 438,444 ---- + > Output + >> OutputSetattr + del sys.stdout.softspace:AttributeError:("can't delete OutputObject attributes",) +! sys.stdout.softspace = []:TypeError:('expected int(), long() or something supporting coercing to long(), but got list',) + sys.stdout.attr = None:AttributeError:('invalid attribute: attr',) + >> OutputWrite + sys.stdout.write(None):TypeError:('coercing to Unicode: need string or buffer, NoneType found',) +*************** +*** 1037,1044 **** + vim.current.window.buffer = 0:TypeError:('readonly attribute: buffer',) + vim.current.window.cursor = (100000000, 100000000):error:('cursor position outside buffer',) + vim.current.window.cursor = True:TypeError:('argument must be 2-item sequence, not bool',) +! vim.current.window.height = "abc":TypeError:('an integer is required',) +! vim.current.window.width = "abc":TypeError:('an integer is required',) + vim.current.window.xxxxxx = True:AttributeError:('xxxxxx',) + > WinList + >> WinListItem +--- 1037,1044 ---- + vim.current.window.buffer = 0:TypeError:('readonly attribute: buffer',) + vim.current.window.cursor = (100000000, 100000000):error:('cursor position outside buffer',) + vim.current.window.cursor = True:TypeError:('argument must be 2-item sequence, not bool',) +! vim.current.window.height = "abc":TypeError:('expected int(), long() or something supporting coercing to long(), but got str',) +! vim.current.window.width = "abc":TypeError:('expected int(), long() or something supporting coercing to long(), but got str',) + vim.current.window.xxxxxx = True:AttributeError:('xxxxxx',) + > WinList + >> WinListItem +*************** +*** 1072,1078 **** + vim.current.buffer.range(1, 2, 3):TypeError:('function takes exactly 2 arguments (3 given)',) + > BufMap + >> BufMapItem +! vim.buffers[None]:TypeError:('key must be integer',) + vim.buffers[100000000]:KeyError:(100000000,) + > Current + >> CurrentGetattr +--- 1072,1078 ---- + vim.current.buffer.range(1, 2, 3):TypeError:('function takes exactly 2 arguments (3 given)',) + > BufMap + >> BufMapItem +! vim.buffers[None]:TypeError:('expected int(), long() or something supporting coercing to long(), but got NoneType',) + vim.buffers[100000000]:KeyError:(100000000,) + > Current + >> CurrentGetattr +*** ../vim-7.3.1230/src/testdir/test87.ok 2013-06-23 13:46:36.000000000 +0200 +--- src/testdir/test87.ok 2013-06-23 14:15:25.000000000 +0200 +*************** +*** 427,433 **** + > Output + >> OutputSetattr + del sys.stdout.softspace:(, AttributeError("can't delete OutputObject attributes",)) +! sys.stdout.softspace = []:(, TypeError('softspace must be an integer',)) + sys.stdout.attr = None:(, AttributeError('invalid attribute: attr',)) + >> OutputWrite + sys.stdout.write(None):(, TypeError("Can't convert 'NoneType' object to str implicitly",)) +--- 427,433 ---- + > Output + >> OutputSetattr + del sys.stdout.softspace:(, AttributeError("can't delete OutputObject attributes",)) +! sys.stdout.softspace = []:(, TypeError('expected int() or something supporting coercing to int(), but got list',)) + sys.stdout.attr = None:(, AttributeError('invalid attribute: attr',)) + >> OutputWrite + sys.stdout.write(None):(, TypeError("Can't convert 'NoneType' object to str implicitly",)) +*************** +*** 1046,1053 **** + vim.current.window.buffer = 0:(, TypeError('readonly attribute: buffer',)) + vim.current.window.cursor = (100000000, 100000000):(, error('cursor position outside buffer',)) + vim.current.window.cursor = True:(, TypeError('argument must be 2-item sequence, not bool',)) +! vim.current.window.height = "abc":(, TypeError('an integer is required',)) +! vim.current.window.width = "abc":(, TypeError('an integer is required',)) + vim.current.window.xxxxxx = True:(, AttributeError('xxxxxx',)) + > WinList + >> WinListItem +--- 1046,1053 ---- + vim.current.window.buffer = 0:(, TypeError('readonly attribute: buffer',)) + vim.current.window.cursor = (100000000, 100000000):(, error('cursor position outside buffer',)) + vim.current.window.cursor = True:(, TypeError('argument must be 2-item sequence, not bool',)) +! vim.current.window.height = "abc":(, TypeError('expected int() or something supporting coercing to int(), but got str',)) +! vim.current.window.width = "abc":(, TypeError('expected int() or something supporting coercing to int(), but got str',)) + vim.current.window.xxxxxx = True:(, AttributeError('xxxxxx',)) + > WinList + >> WinListItem +*************** +*** 1081,1087 **** + vim.current.buffer.range(1, 2, 3):(, TypeError('function takes exactly 2 arguments (3 given)',)) + > BufMap + >> BufMapItem +! vim.buffers[None]:(, TypeError('key must be integer',)) + vim.buffers[100000000]:(, KeyError(100000000,)) + > Current + >> CurrentGetattr +--- 1081,1087 ---- + vim.current.buffer.range(1, 2, 3):(, TypeError('function takes exactly 2 arguments (3 given)',)) + > BufMap + >> BufMapItem +! vim.buffers[None]:(, TypeError('expected int() or something supporting coercing to int(), but got NoneType',)) + vim.buffers[100000000]:(, KeyError(100000000,)) + > Current + >> CurrentGetattr +*** ../vim-7.3.1230/src/version.c 2013-06-23 13:46:36.000000000 +0200 +--- src/version.c 2013-06-23 14:13:45.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1231, + /**/ + +-- +MAN: Fetchez la vache! +GUARD: Quoi? +MAN: Fetchez la vache! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bc8f749a94572345d13f5318adcd57fe8c171ec4 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:28 +0200 Subject: [PATCH 1125/3340] - patchlevel 1232 --- 7.3.1232 | 2562 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 2562 insertions(+) create mode 100644 7.3.1232 diff --git a/7.3.1232 b/7.3.1232 new file mode 100644 index 00000000..5cf35f87 --- /dev/null +++ b/7.3.1232 @@ -0,0 +1,2562 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1232 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1232 +Problem: Python: inconsistencies in variable names. +Solution: Rename variables. (ZyX) +Files: src/eval.c, src/if_py_both.h + + +*** ../vim-7.3.1231/src/eval.c 2013-06-16 17:32:33.000000000 +0200 +--- src/eval.c 2013-06-23 14:29:13.000000000 +0200 +*************** +*** 3228,3234 **** + void *fi_void; + char_u *arg; + { +! forinfo_T *fi = (forinfo_T *)fi_void; + int result; + listitem_T *item; + +--- 3228,3234 ---- + void *fi_void; + char_u *arg; + { +! forinfo_T *fi = (forinfo_T *)fi_void; + int result; + listitem_T *item; + +*** ../vim-7.3.1231/src/if_py_both.h 2013-06-23 14:16:53.000000000 +0200 +--- src/if_py_both.h 2013-06-23 14:29:13.000000000 +0200 +*************** +*** 107,134 **** + * Use Py_XDECREF to decrement reference count. + */ + static char_u * +! StringToChars(PyObject *object, PyObject **todecref) + { +! char_u *p; + +! if (PyBytes_Check(object)) + { + +! if (PyBytes_AsStringAndSize(object, (char **) &p, NULL) == -1 +! || p == NULL) + return NULL; + + *todecref = NULL; + } +! else if (PyUnicode_Check(object)) + { + PyObject *bytes; + +! if (!(bytes = PyUnicode_AsEncodedString(object, ENC_OPT, NULL))) + return NULL; + +! if(PyBytes_AsStringAndSize(bytes, (char **) &p, NULL) == -1 +! || p == NULL) + { + Py_DECREF(bytes); + return NULL; +--- 107,134 ---- + * Use Py_XDECREF to decrement reference count. + */ + static char_u * +! StringToChars(PyObject *obj, PyObject **todecref) + { +! char_u *str; + +! if (PyBytes_Check(obj)) + { + +! if (PyBytes_AsStringAndSize(obj, (char **) &str, NULL) == -1 +! || str == NULL) + return NULL; + + *todecref = NULL; + } +! else if (PyUnicode_Check(obj)) + { + PyObject *bytes; + +! if (!(bytes = PyUnicode_AsEncodedString(obj, ENC_OPT, NULL))) + return NULL; + +! if(PyBytes_AsStringAndSize(bytes, (char **) &str, NULL) == -1 +! || str == NULL) + { + Py_DECREF(bytes); + return NULL; +*************** +*** 144,154 **** + #else + "expected bytes() or str() instance, but got %s" + #endif +! , Py_TYPE_NAME(object)); + return NULL; + } + +! return (char_u *) p; + } + + #define NUMBER_LONG 1 +--- 144,154 ---- + #else + "expected bytes() or str() instance, but got %s" + #endif +! , Py_TYPE_NAME(obj)); + return NULL; + } + +! return (char_u *) str; + } + + #define NUMBER_LONG 1 +*************** +*** 263,297 **** + { + PyMethodDef *method; + char **attr; +! PyObject *r; + +! if (!(r = PyList_New(0))) + return NULL; + + if (self) + for (method = self->ob_type->tp_methods ; method->ml_name != NULL ; ++method) +! if (add_string(r, (char *) method->ml_name)) + { +! Py_DECREF(r); + return NULL; + } + + for (attr = attributes ; *attr ; ++attr) +! if (add_string(r, *attr)) + { +! Py_DECREF(r); + return NULL; + } + + #if PY_MAJOR_VERSION < 3 +! if (add_string(r, "__members__")) + { +! Py_DECREF(r); + return NULL; + } + #endif + +! return r; + } + + /* Output buffer management +--- 263,297 ---- + { + PyMethodDef *method; + char **attr; +! PyObject *ret; + +! if (!(ret = PyList_New(0))) + return NULL; + + if (self) + for (method = self->ob_type->tp_methods ; method->ml_name != NULL ; ++method) +! if (add_string(ret, (char *) method->ml_name)) + { +! Py_DECREF(ret); + return NULL; + } + + for (attr = attributes ; *attr ; ++attr) +! if (add_string(ret, *attr)) + { +! Py_DECREF(ret); + return NULL; + } + + #if PY_MAJOR_VERSION < 3 +! if (add_string(ret, "__members__")) + { +! Py_DECREF(ret); + return NULL; + } + #endif + +! return ret; + } + + /* Output buffer management +*************** +*** 321,329 **** + } + + static int +! OutputSetattr(OutputObject *self, char *name, PyObject *val) + { +! if (val == NULL) + { + PyErr_SET_STRING(PyExc_AttributeError, + "can't delete OutputObject attributes"); +--- 321,329 ---- + } + + static int +! OutputSetattr(OutputObject *self, char *name, PyObject *valObject) + { +! if (valObject == NULL) + { + PyErr_SET_STRING(PyExc_AttributeError, + "can't delete OutputObject attributes"); +*************** +*** 332,338 **** + + if (strcmp(name, "softspace") == 0) + { +! if (NumberToLong(val, &(self->softspace), NUMBER_UNSIGNED)) + return -1; + return 0; + } +--- 332,338 ---- + + if (strcmp(name, "softspace") == 0) + { +! if (NumberToLong(valObject, &(self->softspace), NUMBER_UNSIGNED)) + return -1; + return 0; + } +*************** +*** 518,527 **** + static PyObject * + LoaderLoadModule(LoaderObject *self, PyObject *args UNUSED) + { +! PyObject *r = self->module; + +! Py_INCREF(r); +! return r; + } + + static struct PyMethodDef LoaderMethods[] = { +--- 518,527 ---- + static PyObject * + LoaderLoadModule(LoaderObject *self, PyObject *args UNUSED) + { +! PyObject *ret = self->module; + +! Py_INCREF(ret); +! return ret; + } + + static struct PyMethodDef LoaderMethods[] = { +*************** +*** 579,585 **** + VimCommand(PyObject *self UNUSED, PyObject *string) + { + char_u *cmd; +! PyObject *result; + PyObject *todecref; + + if (!(cmd = StringToChars(string, &todecref))) +--- 579,585 ---- + VimCommand(PyObject *self UNUSED, PyObject *string) + { + char_u *cmd; +! PyObject *ret; + PyObject *todecref; + + if (!(cmd = StringToChars(string, &todecref))) +*************** +*** 596,608 **** + Py_END_ALLOW_THREADS + + if (VimTryEnd()) +! result = NULL; + else +! result = Py_None; + +! Py_XINCREF(result); + Py_XDECREF(todecref); +! return result; + } + + /* +--- 596,608 ---- + Py_END_ALLOW_THREADS + + if (VimTryEnd()) +! ret = NULL; + else +! ret = Py_None; + +! Py_XINCREF(ret); + Py_XDECREF(todecref); +! return ret; + } + + /* +*************** +*** 615,621 **** + static PyObject * + VimToPython(typval_T *our_tv, int depth, PyObject *lookup_dict) + { +! PyObject *result; + PyObject *newObj; + char ptrBuf[sizeof(void *) * 2 + 3]; + +--- 615,621 ---- + static PyObject * + VimToPython(typval_T *our_tv, int depth, PyObject *lookup_dict) + { +! PyObject *ret; + PyObject *newObj; + char ptrBuf[sizeof(void *) * 2 + 3]; + +*************** +*** 623,630 **** + if (depth > 100) + { + Py_INCREF(Py_None); +! result = Py_None; +! return result; + } + + /* Check if we run into a recursive loop. The item must be in lookup_dict +--- 623,630 ---- + if (depth > 100) + { + Py_INCREF(Py_None); +! ret = Py_None; +! return ret; + } + + /* Check if we run into a recursive loop. The item must be in lookup_dict +*************** +*** 636,650 **** + our_tv->v_type == VAR_LIST ? (void *)our_tv->vval.v_list + : (void *)our_tv->vval.v_dict); + +! if ((result = PyDict_GetItemString(lookup_dict, ptrBuf))) + { +! Py_INCREF(result); +! return result; + } + } + + if (our_tv->v_type == VAR_STRING) +! result = PyString_FromString(our_tv->vval.v_string == NULL + ? "" : (char *)our_tv->vval.v_string); + else if (our_tv->v_type == VAR_NUMBER) + { +--- 636,650 ---- + our_tv->v_type == VAR_LIST ? (void *)our_tv->vval.v_list + : (void *)our_tv->vval.v_dict); + +! if ((ret = PyDict_GetItemString(lookup_dict, ptrBuf))) + { +! Py_INCREF(ret); +! return ret; + } + } + + if (our_tv->v_type == VAR_STRING) +! ret = PyString_FromString(our_tv->vval.v_string == NULL + ? "" : (char *)our_tv->vval.v_string); + else if (our_tv->v_type == VAR_NUMBER) + { +*************** +*** 652,658 **** + + /* For backwards compatibility numbers are stored as strings. */ + sprintf(buf, "%ld", (long)our_tv->vval.v_number); +! result = PyString_FromString((char *) buf); + } + # ifdef FEAT_FLOAT + else if (our_tv->v_type == VAR_FLOAT) +--- 652,658 ---- + + /* For backwards compatibility numbers are stored as strings. */ + sprintf(buf, "%ld", (long)our_tv->vval.v_number); +! ret = PyString_FromString((char *) buf); + } + # ifdef FEAT_FLOAT + else if (our_tv->v_type == VAR_FLOAT) +*************** +*** 660,666 **** + char buf[NUMBUFLEN]; + + sprintf(buf, "%f", our_tv->vval.v_float); +! result = PyString_FromString((char *) buf); + } + # endif + else if (our_tv->v_type == VAR_LIST) +--- 660,666 ---- + char buf[NUMBUFLEN]; + + sprintf(buf, "%f", our_tv->vval.v_float); +! ret = PyString_FromString((char *) buf); + } + # endif + else if (our_tv->v_type == VAR_LIST) +*************** +*** 671,682 **** + if (list == NULL) + return NULL; + +! if (!(result = PyList_New(0))) + return NULL; + +! if (PyDict_SetItemString(lookup_dict, ptrBuf, result)) + { +! Py_DECREF(result); + return NULL; + } + +--- 671,682 ---- + if (list == NULL) + return NULL; + +! if (!(ret = PyList_New(0))) + return NULL; + +! if (PyDict_SetItemString(lookup_dict, ptrBuf, ret)) + { +! Py_DECREF(ret); + return NULL; + } + +*************** +*** 684,696 **** + { + if (!(newObj = VimToPython(&curr->li_tv, depth + 1, lookup_dict))) + { +! Py_DECREF(result); + return NULL; + } +! if (PyList_Append(result, newObj)) + { + Py_DECREF(newObj); +! Py_DECREF(result); + return NULL; + } + Py_DECREF(newObj); +--- 684,696 ---- + { + if (!(newObj = VimToPython(&curr->li_tv, depth + 1, lookup_dict))) + { +! Py_DECREF(ret); + return NULL; + } +! if (PyList_Append(ret, newObj)) + { + Py_DECREF(newObj); +! Py_DECREF(ret); + return NULL; + } + Py_DECREF(newObj); +*************** +*** 706,717 **** + if (our_tv->vval.v_dict == NULL) + return NULL; + +! if (!(result = PyDict_New())) + return NULL; + +! if (PyDict_SetItemString(lookup_dict, ptrBuf, result)) + { +! Py_DECREF(result); + return NULL; + } + +--- 706,717 ---- + if (our_tv->vval.v_dict == NULL) + return NULL; + +! if (!(ret = PyDict_New())) + return NULL; + +! if (PyDict_SetItemString(lookup_dict, ptrBuf, ret)) + { +! Py_DECREF(ret); + return NULL; + } + +*************** +*** 724,735 **** + di = dict_lookup(hi); + if (!(newObj = VimToPython(&di->di_tv, depth + 1, lookup_dict))) + { +! Py_DECREF(result); + return NULL; + } +! if (PyDict_SetItemString(result, (char *)hi->hi_key, newObj)) + { +! Py_DECREF(result); + Py_DECREF(newObj); + return NULL; + } +--- 724,735 ---- + di = dict_lookup(hi); + if (!(newObj = VimToPython(&di->di_tv, depth + 1, lookup_dict))) + { +! Py_DECREF(ret); + return NULL; + } +! if (PyDict_SetItemString(ret, (char *)hi->hi_key, newObj)) + { +! Py_DECREF(ret); + Py_DECREF(newObj); + return NULL; + } +*************** +*** 739,748 **** + else + { + Py_INCREF(Py_None); +! result = Py_None; + } + +! return result; + } + + static PyObject * +--- 739,748 ---- + else + { + Py_INCREF(Py_None); +! ret = Py_None; + } + +! return ret; + } + + static PyObject * +*************** +*** 752,758 **** + typval_T *our_tv; + PyObject *string; + PyObject *todecref; +! PyObject *result; + PyObject *lookup_dict; + + if (!PyArg_ParseTuple(args, "O", &string)) +--- 752,758 ---- + typval_T *our_tv; + PyObject *string; + PyObject *todecref; +! PyObject *ret; + PyObject *lookup_dict; + + if (!PyArg_ParseTuple(args, "O", &string)) +*************** +*** 782,791 **** + /* Convert the Vim type into a Python type. Create a dictionary that's + * used to check for recursive loops. */ + if (!(lookup_dict = PyDict_New())) +! result = NULL; + else + { +! result = VimToPython(our_tv, 1, lookup_dict); + Py_DECREF(lookup_dict); + } + +--- 782,791 ---- + /* Convert the Vim type into a Python type. Create a dictionary that's + * used to check for recursive loops. */ + if (!(lookup_dict = PyDict_New())) +! ret = NULL; + else + { +! ret = VimToPython(our_tv, 1, lookup_dict); + Py_DECREF(lookup_dict); + } + +*************** +*** 796,802 **** + Python_Release_Vim(); + Py_END_ALLOW_THREADS + +! return result; + } + + static PyObject *ConvertToPyObject(typval_T *); +--- 796,802 ---- + Python_Release_Vim(); + Py_END_ALLOW_THREADS + +! return ret; + } + + static PyObject *ConvertToPyObject(typval_T *); +*************** +*** 805,811 **** + VimEvalPy(PyObject *self UNUSED, PyObject *string) + { + typval_T *our_tv; +! PyObject *result; + char_u *expr; + PyObject *todecref; + +--- 805,811 ---- + VimEvalPy(PyObject *self UNUSED, PyObject *string) + { + typval_T *our_tv; +! PyObject *ret; + char_u *expr; + PyObject *todecref; + +*************** +*** 830,843 **** + return NULL; + } + +! result = ConvertToPyObject(our_tv); + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + free_tv(our_tv); + Python_Release_Vim(); + Py_END_ALLOW_THREADS + +! return result; + } + + static PyObject * +--- 830,843 ---- + return NULL; + } + +! ret = ConvertToPyObject(our_tv); + Py_BEGIN_ALLOW_THREADS + Python_Lock_Vim(); + free_tv(our_tv); + Python_Release_Vim(); + Py_END_ALLOW_THREADS + +! return ret; + } + + static PyObject * +*************** +*** 845,888 **** + { + char_u *str; + PyObject *todecref; +! int result; + + if (!(str = StringToChars(string, &todecref))) + return NULL; + + #ifdef FEAT_MBYTE +! result = mb_string2cells(str, (int)STRLEN(str)); + #else +! result = STRLEN(str); + #endif + + Py_XDECREF(todecref); + +! return PyLong_FromLong(result); + } + + static PyObject * + _VimChdir(PyObject *_chdir, PyObject *args, PyObject *kwargs) + { +! PyObject *r; + PyObject *newwd; + PyObject *todecref; + char_u *new_dir; + + if (_chdir == NULL) + return NULL; +! if (!(r = PyObject_Call(_chdir, args, kwargs))) + return NULL; + + if (!(newwd = PyObject_CallFunctionObjArgs(py_getcwd, NULL))) + { +! Py_DECREF(r); + return NULL; + } + + if (!(new_dir = StringToChars(newwd, &todecref))) + { +! Py_DECREF(r); + Py_DECREF(newwd); + return NULL; + } +--- 845,888 ---- + { + char_u *str; + PyObject *todecref; +! int len; + + if (!(str = StringToChars(string, &todecref))) + return NULL; + + #ifdef FEAT_MBYTE +! len = mb_string2cells(str, (int)STRLEN(str)); + #else +! len = STRLEN(str); + #endif + + Py_XDECREF(todecref); + +! return PyLong_FromLong(len); + } + + static PyObject * + _VimChdir(PyObject *_chdir, PyObject *args, PyObject *kwargs) + { +! PyObject *ret; + PyObject *newwd; + PyObject *todecref; + char_u *new_dir; + + if (_chdir == NULL) + return NULL; +! if (!(ret = PyObject_Call(_chdir, args, kwargs))) + return NULL; + + if (!(newwd = PyObject_CallFunctionObjArgs(py_getcwd, NULL))) + { +! Py_DECREF(ret); + return NULL; + } + + if (!(new_dir = StringToChars(newwd, &todecref))) + { +! Py_DECREF(ret); + Py_DECREF(newwd); + return NULL; + } +*************** +*** 891,897 **** + + if (vim_chdir(new_dir)) + { +! Py_DECREF(r); + Py_DECREF(newwd); + Py_XDECREF(todecref); + +--- 891,897 ---- + + if (vim_chdir(new_dir)) + { +! Py_DECREF(ret); + Py_DECREF(newwd); + Py_XDECREF(todecref); + +*************** +*** 909,919 **** + + if (VimTryEnd()) + { +! Py_DECREF(r); + return NULL; + } + +! return r; + } + + static PyObject * +--- 909,919 ---- + + if (VimTryEnd()) + { +! Py_DECREF(ret); + return NULL; + } + +! return ret; + } + + static PyObject * +*************** +*** 1052,1071 **** + static PyObject * + Vim_GetPaths(PyObject *self UNUSED) + { +! PyObject *r; + +! if (!(r = PyList_New(0))) + return NULL; + +! do_in_runtimepath(NULL, FALSE, &map_finder_callback, r); + + if (PyErr_Occurred()) + { +! Py_DECREF(r); + return NULL; + } + +! return r; + } + + static PyObject * +--- 1052,1071 ---- + static PyObject * + Vim_GetPaths(PyObject *self UNUSED) + { +! PyObject *ret; + +! if (!(ret = PyList_New(0))) + return NULL; + +! do_in_runtimepath(NULL, FALSE, &map_finder_callback, ret); + + if (PyErr_Occurred()) + { +! Py_DECREF(ret); + return NULL; + } + +! return ret; + } + + static PyObject * +*************** +*** 1400,1415 **** + static dict_T * + py_dict_alloc(void) + { +! dict_T *r; + +! if (!(r = dict_alloc())) + { + PyErr_NoMemory(); + return NULL; + } +! ++r->dv_refcount; + +! return r; + } + + static PyObject * +--- 1400,1415 ---- + static dict_T * + py_dict_alloc(void) + { +! dict_T *ret; + +! if (!(ret = dict_alloc())) + { + PyErr_NoMemory(); + return NULL; + } +! ++ret->dv_refcount; + +! return ret; + } + + static PyObject * +*************** +*** 1461,1469 **** + } + + static int +! DictionarySetattr(DictionaryObject *self, char *name, PyObject *val) + { +! if (val == NULL) + { + PyErr_SET_STRING(PyExc_AttributeError, + "cannot delete vim.Dictionary attributes"); +--- 1461,1469 ---- + } + + static int +! DictionarySetattr(DictionaryObject *self, char *name, PyObject *valObject) + { +! if (valObject == NULL) + { + PyErr_SET_STRING(PyExc_AttributeError, + "cannot delete vim.Dictionary attributes"); +*************** +*** 1479,1485 **** + } + else + { +! int istrue = PyObject_IsTrue(val); + if (istrue == -1) + return -1; + else if (istrue) +--- 1479,1485 ---- + } + else + { +! int istrue = PyObject_IsTrue(valObject); + if (istrue == -1) + return -1; + else if (istrue) +*************** +*** 1513,1519 **** + { + PyObject *keyObject; + PyObject *defObject = ((flags & DICT_FLAG_NONE_DEFAULT)? Py_None : NULL); +! PyObject *r; + char_u *key; + dictitem_T *di; + dict_T *dict = self->dict; +--- 1513,1519 ---- + { + PyObject *keyObject; + PyObject *defObject = ((flags & DICT_FLAG_NONE_DEFAULT)? Py_None : NULL); +! PyObject *ret; + char_u *key; + dictitem_T *di; + dict_T *dict = self->dict; +*************** +*** 1566,1572 **** + + di = dict_lookup(hi); + +! if (!(r = ConvertToPyObject(&di->di_tv))) + return NULL; + + if (flags & DICT_FLAG_POP) +--- 1566,1572 ---- + + di = dict_lookup(hi); + +! if (!(ret = ConvertToPyObject(&di->di_tv))) + return NULL; + + if (flags & DICT_FLAG_POP) +*************** +*** 1574,1580 **** + if (dict->dv_lock) + { + RAISE_LOCKED_DICTIONARY; +! Py_DECREF(r); + return NULL; + } + +--- 1574,1580 ---- + if (dict->dv_lock) + { + RAISE_LOCKED_DICTIONARY; +! Py_DECREF(ret); + return NULL; + } + +*************** +*** 1582,1588 **** + dictitem_free(di); + } + +! return r; + } + + static PyObject * +--- 1582,1588 ---- + dictitem_free(di); + } + +! return ret; + } + + static PyObject * +*************** +*** 1595,1607 **** + DictionaryContains(DictionaryObject *self, PyObject *keyObject) + { + PyObject *rObj = _DictionaryItem(self, keyObject, DICT_FLAG_RETURN_BOOL); +! int r; + +! r = (rObj == Py_True); + + Py_DECREF(Py_True); + +! return r; + } + + typedef struct +--- 1595,1607 ---- + DictionaryContains(DictionaryObject *self, PyObject *keyObject) + { + PyObject *rObj = _DictionaryItem(self, keyObject, DICT_FLAG_RETURN_BOOL); +! int ret; + +! ret = (rObj == Py_True); + + Py_DECREF(Py_True); + +! return ret; + } + + typedef struct +*************** +*** 1616,1622 **** + static PyObject * + DictionaryIterNext(dictiterinfo_T **dii) + { +! PyObject *r; + + if (!(*dii)->todo) + return NULL; +--- 1616,1622 ---- + static PyObject * + DictionaryIterNext(dictiterinfo_T **dii) + { +! PyObject *ret; + + if (!(*dii)->todo) + return NULL; +*************** +*** 1634,1643 **** + + --((*dii)->todo); + +! if (!(r = PyBytes_FromString((char *) (*dii)->hi->hi_key))) + return NULL; + +! return r; + } + + static PyObject * +--- 1634,1643 ---- + + --((*dii)->todo); + +! if (!(ret = PyBytes_FromString((char *) (*dii)->hi->hi_key))) + return NULL; + +! return ret; + } + + static PyObject * +*************** +*** 1753,1778 **** + dict_T *dict = self->dict; + long_u todo = dict->dv_hashtab.ht_used; + Py_ssize_t i = 0; +! PyObject *r; + hashitem_T *hi; + PyObject *newObj; + +! r = PyList_New(todo); + for (hi = dict->dv_hashtab.ht_array; todo > 0; ++hi) + { + if (!HASHITEM_EMPTY(hi)) + { + if (!(newObj = hiconvert(hi))) + { +! Py_DECREF(r); + return NULL; + } +! PyList_SET_ITEM(r, i, newObj); + --todo; + ++i; + } + } +! return r; + } + + static PyObject * +--- 1753,1778 ---- + dict_T *dict = self->dict; + long_u todo = dict->dv_hashtab.ht_used; + Py_ssize_t i = 0; +! PyObject *ret; + hashitem_T *hi; + PyObject *newObj; + +! ret = PyList_New(todo); + for (hi = dict->dv_hashtab.ht_array; todo > 0; ++hi) + { + if (!HASHITEM_EMPTY(hi)) + { + if (!(newObj = hiconvert(hi))) + { +! Py_DECREF(ret); + return NULL; + } +! PyList_SET_ITEM(ret, i, newObj); + --todo; + ++i; + } + } +! return ret; + } + + static PyObject * +*************** +*** 1807,1813 **** + { + PyObject *keyObject; + PyObject *valObject; +! PyObject *r; + + if (!(keyObject = dict_key(hi))) + return NULL; +--- 1807,1813 ---- + { + PyObject *keyObject; + PyObject *valObject; +! PyObject *ret; + + if (!(keyObject = dict_key(hi))) + return NULL; +*************** +*** 1818,1829 **** + return NULL; + } + +! r = Py_BuildValue("(OO)", keyObject, valObject); + + Py_DECREF(keyObject); + Py_DECREF(valObject); + +! return r; + } + + static PyObject * +--- 1818,1829 ---- + return NULL; + } + +! ret = Py_BuildValue("(OO)", keyObject, valObject); + + Py_DECREF(keyObject); + Py_DECREF(valObject); + +! return ret; + } + + static PyObject * +*************** +*** 1858,1876 **** + } + else + { +! PyObject *object; + +! if (!PyArg_ParseTuple(args, "O", &object)) + return NULL; + +! if (PyObject_HasAttrString(object, "keys")) +! return DictionaryUpdate(self, NULL, object); + else + { + PyObject *iterator; + PyObject *item; + +! if (!(iterator = PyObject_GetIter(object))) + return NULL; + + while ((item = PyIter_Next(iterator))) +--- 1858,1876 ---- + } + else + { +! PyObject *obj; + +! if (!PyArg_ParseTuple(args, "O", &obj)) + return NULL; + +! if (PyObject_HasAttrString(obj, "keys")) +! return DictionaryUpdate(self, NULL, obj); + else + { + PyObject *iterator; + PyObject *item; + +! if (!(iterator = PyObject_GetIter(obj))) + return NULL; + + while ((item = PyIter_Next(iterator))) +*************** +*** 1974,1980 **** + DictionaryPopItem(DictionaryObject *self) + { + hashitem_T *hi; +! PyObject *r; + PyObject *valObject; + dictitem_T *di; + +--- 1974,1980 ---- + DictionaryPopItem(DictionaryObject *self) + { + hashitem_T *hi; +! PyObject *ret; + PyObject *valObject; + dictitem_T *di; + +*************** +*** 1993,1999 **** + if (!(valObject = ConvertToPyObject(&di->di_tv))) + return NULL; + +! if (!(r = Py_BuildValue("(" Py_bytes_fmt "O)", hi->hi_key, valObject))) + { + Py_DECREF(valObject); + return NULL; +--- 1993,1999 ---- + if (!(valObject = ConvertToPyObject(&di->di_tv))) + return NULL; + +! if (!(ret = Py_BuildValue("(" Py_bytes_fmt "O)", hi->hi_key, valObject))) + { + Py_DECREF(valObject); + return NULL; +*************** +*** 2002,2008 **** + hash_remove(&self->dict->dv_hashtab, hi); + dictitem_free(di); + +! return r; + } + + static PyObject * +--- 2002,2008 ---- + hash_remove(&self->dict->dv_hashtab, hi); + dictitem_free(di); + +! return ret; + } + + static PyObject * +*************** +*** 2075,2090 **** + static list_T * + py_list_alloc() + { +! list_T *r; + +! if (!(r = list_alloc())) + { + PyErr_NoMemory(); + return NULL; + } +! ++r->lv_refcount; + +! return r; + } + + static int +--- 2075,2090 ---- + static list_T * + py_list_alloc() + { +! list_T *ret; + +! if (!(ret = list_alloc())) + { + PyErr_NoMemory(); + return NULL; + } +! ++ret->lv_refcount; + +! return ret; + } + + static int +*************** +*** 2272,2288 **** + static PyObject * + ListIterNext(listiterinfo_T **lii) + { +! PyObject *r; + + if (!((*lii)->lw.lw_item)) + return NULL; + +! if (!(r = ConvertToPyObject(&((*lii)->lw.lw_item->li_tv)))) + return NULL; + + (*lii)->lw.lw_item = (*lii)->lw.lw_item->li_next; + +! return r; + } + + static PyObject * +--- 2272,2288 ---- + static PyObject * + ListIterNext(listiterinfo_T **lii) + { +! PyObject *ret; + + if (!((*lii)->lw.lw_item)) + return NULL; + +! if (!(ret = ConvertToPyObject(&((*lii)->lw.lw_item->li_tv)))) + return NULL; + + (*lii)->lw.lw_item = (*lii)->lw.lw_item->li_next; + +! return ret; + } + + static PyObject * +*************** +*** 2319,2325 **** + RAISE_LOCKED_LIST; + return -1; + } +! if (index>length || (index==length && obj==NULL)) + { + PyErr_SET_STRING(PyExc_IndexError, "list index out of range"); + return -1; +--- 2319,2325 ---- + RAISE_LOCKED_LIST; + return -1; + } +! if (index > length || (index == length && obj == NULL)) + { + PyErr_SET_STRING(PyExc_IndexError, "list index out of range"); + return -1; +*************** +*** 2463,2471 **** + } + + static int +! ListSetattr(ListObject *self, char *name, PyObject *val) + { +! if (val == NULL) + { + PyErr_SET_STRING(PyExc_AttributeError, + "cannot delete vim.List attributes"); +--- 2463,2471 ---- + } + + static int +! ListSetattr(ListObject *self, char *name, PyObject *valObject) + { +! if (valObject == NULL) + { + PyErr_SET_STRING(PyExc_AttributeError, + "cannot delete vim.List attributes"); +*************** +*** 2481,2487 **** + } + else + { +! int istrue = PyObject_IsTrue(val); + if (istrue == -1) + return -1; + else if (istrue) +--- 2481,2487 ---- + } + else + { +! int istrue = PyObject_IsTrue(valObject); + if (istrue == -1) + return -1; + else if (istrue) +*************** +*** 2599,2605 **** + typval_T rettv; + dict_T *selfdict = NULL; + PyObject *selfdictObject; +! PyObject *result; + int error; + + if (ConvertFromPyObject(argsObject, &args) == -1) +--- 2599,2605 ---- + typval_T rettv; + dict_T *selfdict = NULL; + PyObject *selfdictObject; +! PyObject *ret; + int error; + + if (ConvertFromPyObject(argsObject, &args) == -1) +*************** +*** 2629,2649 **** + Py_END_ALLOW_THREADS + + if (VimTryEnd()) +! result = NULL; + else if (error != OK) + { +! result = NULL; + PyErr_VIM_FORMAT("failed to run function %s", (char *)name); + } + else +! result = ConvertToPyObject(&rettv); + + clear_tv(&args); + clear_tv(&rettv); + if (selfdict != NULL) + clear_tv(&selfdicttv); + +! return result; + } + + static PyObject * +--- 2629,2649 ---- + Py_END_ALLOW_THREADS + + if (VimTryEnd()) +! ret = NULL; + else if (error != OK) + { +! ret = NULL; + PyErr_VIM_FORMAT("failed to run function %s", (char *)name); + } + else +! ret = ConvertToPyObject(&rettv); + + clear_tv(&args); + clear_tv(&rettv); + if (selfdict != NULL) + clear_tv(&selfdicttv); + +! return ret; + } + + static PyObject * +*************** +*** 2761,2770 **** + } + else if (flags & SOPT_BOOL) + { +! PyObject *r; +! r = numval ? Py_True : Py_False; +! Py_INCREF(r); +! return r; + } + else if (flags & SOPT_NUM) + return PyInt_FromLong(numval); +--- 2761,2770 ---- + } + else if (flags & SOPT_BOOL) + { +! PyObject *ret; +! ret = numval ? Py_True : Py_False; +! Py_INCREF(ret); +! return ret; + } + else if (flags & SOPT_NUM) + return PyInt_FromLong(numval); +*************** +*** 2772,2780 **** + { + if (stringval) + { +! PyObject *r = PyBytes_FromString((char *) stringval); + vim_free(stringval); +! return r; + } + else + { +--- 2772,2780 ---- + { + if (stringval) + { +! PyObject *ret = PyBytes_FromString((char *) stringval); + vim_free(stringval); +! return ret; + } + else + { +*************** +*** 2817,2823 **** + win_T *save_curwin = NULL; + tabpage_T *save_curtab = NULL; + buf_T *save_curbuf = NULL; +! int r = 0; + + VimTryStart(); + switch (opt_type) +--- 2817,2823 ---- + win_T *save_curwin = NULL; + tabpage_T *save_curtab = NULL; + buf_T *save_curbuf = NULL; +! int set_ret = 0; + + VimTryStart(); + switch (opt_type) +*************** +*** 2831,2854 **** + PyErr_SET_VIM("problem while switching windows"); + return -1; + } +! r = set_option_value_err(key, numval, stringval, opt_flags); +! restore_win(save_curwin, save_curtab, FALSE); +! if (r == FAIL) +! return -1; + break; + case SREQ_BUF: + switch_buffer(&save_curbuf, (buf_T *)from); +! r = set_option_value_err(key, numval, stringval, opt_flags); + restore_buffer(save_curbuf); +- if (r == FAIL) +- return -1; + break; + case SREQ_GLOBAL: +! r = set_option_value_err(key, numval, stringval, opt_flags); +! if (r == FAIL) +! return -1; + break; + } + return VimTryEnd(); + } + +--- 2831,2850 ---- + PyErr_SET_VIM("problem while switching windows"); + return -1; + } +! set_ret = set_option_value_err(key, numval, stringval, opt_flags); +! restore_win(save_curwin, save_curtab, TRUE); + break; + case SREQ_BUF: + switch_buffer(&save_curbuf, (buf_T *)from); +! set_ret = set_option_value_err(key, numval, stringval, opt_flags); + restore_buffer(save_curbuf); + break; + case SREQ_GLOBAL: +! set_ret = set_option_value_err(key, numval, stringval, opt_flags); + break; + } ++ if (set_ret == FAIL) ++ return -1; + return VimTryEnd(); + } + +*************** +*** 2858,2864 **** + char_u *key; + int flags; + int opt_flags; +! int r = 0; + PyObject *todecref; + + if (self->Check(self->from)) +--- 2854,2860 ---- + char_u *key; + int flags; + int opt_flags; +! int ret = 0; + PyObject *todecref; + + if (self->Check(self->from)) +*************** +*** 2916,2924 **** + int istrue = PyObject_IsTrue(valObject); + + if (istrue == -1) +! r = -1; + else +! r = set_option_value_for(key, istrue, NULL, + opt_flags, self->opt_type, self->from); + } + else if (flags & SOPT_NUM) +--- 2912,2920 ---- + int istrue = PyObject_IsTrue(valObject); + + if (istrue == -1) +! ret = -1; + else +! ret = set_option_value_for(key, istrue, NULL, + opt_flags, self->opt_type, self->from); + } + else if (flags & SOPT_NUM) +*************** +*** 2931,2954 **** + return -1; + } + +! r = set_option_value_for(key, (int) val, NULL, opt_flags, + self->opt_type, self->from); + } + else + { +! char_u *val; + PyObject *todecref; + + if ((val = StringToChars(valObject, &todecref))) +! r = set_option_value_for(key, 0, val, opt_flags, + self->opt_type, self->from); + else +! r = -1; + } + + Py_XDECREF(todecref); + +! return r; + } + + static PyMappingMethods OptionsAsMapping = { +--- 2927,2950 ---- + return -1; + } + +! ret = set_option_value_for(key, (int) val, NULL, opt_flags, + self->opt_type, self->from); + } + else + { +! char_u *val; + PyObject *todecref; + + if ((val = StringToChars(valObject, &todecref))) +! ret = set_option_value_for(key, 0, val, opt_flags, + self->opt_type, self->from); + else +! ret = -1; + } + + Py_XDECREF(todecref); + +! return ret; + } + + static PyMappingMethods OptionsAsMapping = { +*************** +*** 3027,3040 **** + static PyObject * + TabPageAttrValid(TabPageObject *self, char *name) + { +! PyObject *r; + + if (strcmp(name, "valid") != 0) + return NULL; + +! r = ((self->tab == INVALID_TABPAGE_VALUE) ? Py_False : Py_True); +! Py_INCREF(r); +! return r; + } + + static PyObject * +--- 3023,3036 ---- + static PyObject * + TabPageAttrValid(TabPageObject *self, char *name) + { +! PyObject *ret; + + if (strcmp(name, "valid") != 0) + return NULL; + +! ret = ((self->tab == INVALID_TABPAGE_VALUE) ? Py_False : Py_True); +! Py_INCREF(ret); +! return ret; + } + + static PyObject * +*************** +*** 3243,3256 **** + static PyObject * + WindowAttrValid(WindowObject *self, char *name) + { +! PyObject *r; + + if (strcmp(name, "valid") != 0) + return NULL; + +! r = ((self->win == INVALID_WINDOW_VALUE) ? Py_False : Py_True); +! Py_INCREF(r); +! return r; + } + + static PyObject * +--- 3239,3252 ---- + static PyObject * + WindowAttrValid(WindowObject *self, char *name) + { +! PyObject *ret; + + if (strcmp(name, "valid") != 0) + return NULL; + +! ret = ((self->win == INVALID_WINDOW_VALUE) ? Py_False : Py_True); +! Py_INCREF(ret); +! return ret; + } + + static PyObject * +*************** +*** 3300,3306 **** + } + + static int +! WindowSetattr(WindowObject *self, char *name, PyObject *val) + { + if (CheckWindow(self)) + return -1; +--- 3296,3302 ---- + } + + static int +! WindowSetattr(WindowObject *self, char *name, PyObject *valObject) + { + if (CheckWindow(self)) + return -1; +*************** +*** 3315,3321 **** + long lnum; + long col; + +! if (!PyArg_Parse(val, "(ll)", &lnum, &col)) + return -1; + + if (lnum <= 0 || lnum > self->win->w_buffer->b_ml.ml_line_count) +--- 3311,3317 ---- + long lnum; + long col; + +! if (!PyArg_Parse(valObject, "(ll)", &lnum, &col)) + return -1; + + if (lnum <= 0 || lnum > self->win->w_buffer->b_ml.ml_line_count) +*************** +*** 3344,3350 **** + long height; + win_T *savewin; + +! if (NumberToLong(val, &height, NUMBER_INT)) + return -1; + + #ifdef FEAT_GUI +--- 3340,3346 ---- + long height; + win_T *savewin; + +! if (NumberToLong(valObject, &height, NUMBER_INT)) + return -1; + + #ifdef FEAT_GUI +*************** +*** 3367,3373 **** + long width; + win_T *savewin; + +! if (NumberToLong(val, &width, NUMBER_INT)) + return -1; + + #ifdef FEAT_GUI +--- 3363,3369 ---- + long width; + win_T *savewin; + +! if (NumberToLong(valObject, &width, NUMBER_INT)) + return -1; + + #ifdef FEAT_GUI +*************** +*** 3584,3608 **** + static PyObject * + GetBufferLineList(buf_T *buf, PyInt lo, PyInt hi) + { +! PyInt i; +! PyInt n = hi - lo; +! PyObject *list = PyList_New(n); + + if (list == NULL) + return NULL; + + for (i = 0; i < n; ++i) + { +! PyObject *str = LineToString((char *)ml_get_buf(buf, (linenr_T)(lo+i), FALSE)); + + /* Error check - was the Python string creation OK? */ +! if (str == NULL) + { + Py_DECREF(list); + return NULL; + } + +! PyList_SET_ITEM(list, i, str); + } + + /* The ownership of the Python list is passed to the caller (ie, +--- 3580,3605 ---- + static PyObject * + GetBufferLineList(buf_T *buf, PyInt lo, PyInt hi) + { +! PyInt i; +! PyInt n = hi - lo; +! PyObject *list = PyList_New(n); + + if (list == NULL) + return NULL; + + for (i = 0; i < n; ++i) + { +! PyObject *string = LineToString( +! (char *)ml_get_buf(buf, (linenr_T)(lo+i), FALSE)); + + /* Error check - was the Python string creation OK? */ +! if (string == NULL) + { + Py_DECREF(list); + return NULL; + } + +! PyList_SET_ITEM(list, i, string); + } + + /* The ownership of the Python list is passed to the caller (ie, +*************** +*** 3662,3668 **** + */ + if (line == Py_None || line == NULL) + { +! buf_T *savebuf; + + PyErr_Clear(); + switch_buffer(&savebuf, buf); +--- 3659,3665 ---- + */ + if (line == Py_None || line == NULL) + { +! buf_T *savebuf; + + PyErr_Clear(); + switch_buffer(&savebuf, buf); +*************** +*** 3747,3753 **** + * is set to the change in the buffer length. + */ + static int +! SetBufferLineList(buf_T *buf, PyInt lo, PyInt hi, PyObject *list, PyInt *len_change) + { + /* First of all, we check the type of the supplied Python object. + * There are three cases: +--- 3744,3755 ---- + * is set to the change in the buffer length. + */ + static int +! SetBufferLineList( +! buf_T *buf, +! PyInt lo, +! PyInt hi, +! PyObject *list, +! PyInt *len_change) + { + /* First of all, we check the type of the supplied Python object. + * There are three cases: +*************** +*** 4124,4130 **** + } + + static PyInt +! RBAsItem(BufferObject *self, PyInt n, PyObject *val, PyInt start, PyInt end, PyInt *new_end) + { + PyInt len_change; + +--- 4126,4138 ---- + } + + static PyInt +! RBAsItem( +! BufferObject *self, +! PyInt n, +! PyObject *valObject, +! PyInt start, +! PyInt end, +! PyInt *new_end) + { + PyInt len_change; + +*************** +*** 4143,4149 **** + return -1; + } + +! if (SetBufferLine(self->buf, n+start, val, &len_change) == FAIL) + return -1; + + if (new_end) +--- 4151,4157 ---- + return -1; + } + +! if (SetBufferLine(self->buf, n+start, valObject, &len_change) == FAIL) + return -1; + + if (new_end) +*************** +*** 4153,4159 **** + } + + static PyInt +! RBAsSlice(BufferObject *self, PyInt lo, PyInt hi, PyObject *val, PyInt start, PyInt end, PyInt *new_end) + { + PyInt size; + PyInt len_change; +--- 4161,4174 ---- + } + + static PyInt +! RBAsSlice( +! BufferObject *self, +! PyInt lo, +! PyInt hi, +! PyObject *valObject, +! PyInt start, +! PyInt end, +! PyInt *new_end) + { + PyInt size; + PyInt len_change; +*************** +*** 4180,4186 **** + hi = size; + + if (SetBufferLineList(self->buf, lo + start, hi + start, +! val, &len_change) == FAIL) + return -1; + + if (new_end) +--- 4195,4201 ---- + hi = size; + + if (SetBufferLineList(self->buf, lo + start, hi + start, +! valObject, &len_change) == FAIL) + return -1; + + if (new_end) +*************** +*** 4191,4197 **** + + + static PyObject * +! RBAppend(BufferObject *self, PyObject *args, PyInt start, PyInt end, PyInt *new_end) + { + PyObject *lines; + PyInt len_change; +--- 4206,4217 ---- + + + static PyObject * +! RBAppend( +! BufferObject *self, +! PyObject *args, +! PyInt start, +! PyInt end, +! PyInt *new_end) + { + PyObject *lines; + PyInt len_change; +*************** +*** 4438,4451 **** + static PyObject * + BufferAttrValid(BufferObject *self, char *name) + { +! PyObject *r; + + if (strcmp(name, "valid") != 0) + return NULL; + +! r = ((self->buf == INVALID_BUFFER_VALUE) ? Py_False : Py_True); +! Py_INCREF(r); +! return r; + } + + static PyObject * +--- 4458,4471 ---- + static PyObject * + BufferAttrValid(BufferObject *self, char *name) + { +! PyObject *ret; + + if (strcmp(name, "valid") != 0) + return NULL; + +! ret = ((self->buf == INVALID_BUFFER_VALUE) ? Py_False : Py_True); +! Py_INCREF(ret); +! return ret; + } + + static PyObject * +*************** +*** 4475,4483 **** + + if (strcmp(name, "name") == 0) + { +! char_u *val; + aco_save_T aco; +! int r; + PyObject *todecref; + + if (!(val = StringToChars(valObject, &todecref))) +--- 4495,4503 ---- + + if (strcmp(name, "name") == 0) + { +! char_u *val; + aco_save_T aco; +! int ren_ret; + PyObject *todecref; + + if (!(val = StringToChars(valObject, &todecref))) +*************** +*** 4486,4498 **** + VimTryStart(); + /* Using aucmd_*: autocommands will be executed by rename_buffer */ + aucmd_prepbuf(&aco, self->buf); +! r = rename_buffer(val); + aucmd_restbuf(&aco); + Py_XDECREF(todecref); + if (VimTryEnd()) + return -1; + +! if (r == FAIL) + { + PyErr_SET_VIM("failed to rename buffer"); + return -1; +--- 4506,4518 ---- + VimTryStart(); + /* Using aucmd_*: autocommands will be executed by rename_buffer */ + aucmd_prepbuf(&aco, self->buf); +! ren_ret = rename_buffer(val); + aucmd_restbuf(&aco); + Py_XDECREF(todecref); + if (VimTryEnd()) + return -1; + +! if (ren_ret == FAIL) + { + PyErr_SET_VIM("failed to rename buffer"); + return -1; +*************** +*** 4677,4703 **** + BufMapIterNext(PyObject **buffer) + { + PyObject *next; +! PyObject *r; + + if (!*buffer) + return NULL; + +! r = *buffer; + +! if (CheckBuffer((BufferObject *)(r))) + { + *buffer = NULL; + return NULL; + } + +! if (!((BufferObject *)(r))->buf->b_next) + next = NULL; +! else if (!(next = BufferNew(((BufferObject *)(r))->buf->b_next))) + return NULL; + *buffer = next; + /* Do not increment reference: we no longer hold it (decref), but whoever + * on other side will hold (incref). Decref+incref = nothing. */ +! return r; + } + + static PyObject * +--- 4697,4723 ---- + BufMapIterNext(PyObject **buffer) + { + PyObject *next; +! PyObject *ret; + + if (!*buffer) + return NULL; + +! ret = *buffer; + +! if (CheckBuffer((BufferObject *)(ret))) + { + *buffer = NULL; + return NULL; + } + +! if (!((BufferObject *)(ret))->buf->b_next) + next = NULL; +! else if (!(next = BufferNew(((BufferObject *)(ret))->buf->b_next))) + return NULL; + *buffer = next; + /* Do not increment reference: we no longer hold it (decref), but whoever + * on other side will hold (incref). Decref+incref = nothing. */ +! return ret; + } + + static PyObject * +*************** +*** 4755,4765 **** + } + + static int +! CurrentSetattr(PyObject *self UNUSED, char *name, PyObject *value) + { + if (strcmp(name, "line") == 0) + { +! if (SetBufferLine(curbuf, (PyInt)curwin->w_cursor.lnum, value, NULL) == FAIL) + return -1; + + return 0; +--- 4775,4786 ---- + } + + static int +! CurrentSetattr(PyObject *self UNUSED, char *name, PyObject *valObject) + { + if (strcmp(name, "line") == 0) + { +! if (SetBufferLine(curbuf, (PyInt)curwin->w_cursor.lnum, valObject, +! NULL) == FAIL) + return -1; + + return 0; +*************** +*** 4768,4784 **** + { + int count; + +! if (value->ob_type != &BufferType) + { + PyErr_FORMAT(PyExc_TypeError, + "expected vim.Buffer object, but got %s", +! Py_TYPE_NAME(value)); + return -1; + } + +! if (CheckBuffer((BufferObject *)(value))) + return -1; +! count = ((BufferObject *)(value))->buf->b_fnum; + + VimTryStart(); + if (do_buffer(DOBUF_GOTO, DOBUF_FIRST, FORWARD, count, 0) == FAIL) +--- 4789,4805 ---- + { + int count; + +! if (valObject->ob_type != &BufferType) + { + PyErr_FORMAT(PyExc_TypeError, + "expected vim.Buffer object, but got %s", +! Py_TYPE_NAME(valObject)); + return -1; + } + +! if (CheckBuffer((BufferObject *)(valObject))) + return -1; +! count = ((BufferObject *)(valObject))->buf->b_fnum; + + VimTryStart(); + if (do_buffer(DOBUF_GOTO, DOBUF_FIRST, FORWARD, count, 0) == FAIL) +*************** +*** 4795,4811 **** + { + int count; + +! if (value->ob_type != &WindowType) + { + PyErr_FORMAT(PyExc_TypeError, + "expected vim.Window object, but got %s", +! Py_TYPE_NAME(value)); + return -1; + } + +! if (CheckWindow((WindowObject *)(value))) + return -1; +! count = get_win_number(((WindowObject *)(value))->win, firstwin); + + if (!count) + { +--- 4816,4832 ---- + { + int count; + +! if (valObject->ob_type != &WindowType) + { + PyErr_FORMAT(PyExc_TypeError, + "expected vim.Window object, but got %s", +! Py_TYPE_NAME(valObject)); + return -1; + } + +! if (CheckWindow((WindowObject *)(valObject))) + return -1; +! count = get_win_number(((WindowObject *)(valObject))->win, firstwin); + + if (!count) + { +*************** +*** 4815,4822 **** + } + + VimTryStart(); +! win_goto(((WindowObject *)(value))->win); +! if (((WindowObject *)(value))->win != curwin) + { + if (VimTryEnd()) + return -1; +--- 4836,4843 ---- + } + + VimTryStart(); +! win_goto(((WindowObject *)(valObject))->win); +! if (((WindowObject *)(valObject))->win != curwin) + { + if (VimTryEnd()) + return -1; +*************** +*** 4829,4848 **** + } + else if (strcmp(name, "tabpage") == 0) + { +! if (value->ob_type != &TabPageType) + { + PyErr_FORMAT(PyExc_TypeError, + "expected vim.TabPage object, but got %s", +! Py_TYPE_NAME(value)); + return -1; + } + +! if (CheckTabPage((TabPageObject *)(value))) + return -1; + + VimTryStart(); +! goto_tabpage_tp(((TabPageObject *)(value))->tab, TRUE, TRUE); +! if (((TabPageObject *)(value))->tab != curtab) + { + if (VimTryEnd()) + return -1; +--- 4850,4869 ---- + } + else if (strcmp(name, "tabpage") == 0) + { +! if (valObject->ob_type != &TabPageType) + { + PyErr_FORMAT(PyExc_TypeError, + "expected vim.TabPage object, but got %s", +! Py_TYPE_NAME(valObject)); + return -1; + } + +! if (CheckTabPage((TabPageObject *)(valObject))) + return -1; + + VimTryStart(); +! goto_tabpage_tp(((TabPageObject *)(valObject))->tab, TRUE, TRUE); +! if (((TabPageObject *)(valObject))->tab != curtab) + { + if (VimTryEnd()) + return -1; +*************** +*** 4934,4940 **** + + for (lnum = RangeStart; lnum <= RangeEnd; ++lnum) + { +! PyObject *line, *linenr, *ret; + + #ifdef PY_CAN_RECURSE + *pygilstate = PyGILState_Ensure(); +--- 4955,4963 ---- + + for (lnum = RangeStart; lnum <= RangeEnd; ++lnum) + { +! PyObject *line; +! PyObject *linenr; +! PyObject *ret; + + #ifdef PY_CAN_RECURSE + *pygilstate = PyGILState_Ensure(); +*************** +*** 4990,4999 **** + #endif + ) + { +! PyObject *r; + +! r = PyRun_String((char *) cmd, Py_eval_input, globals, globals); +! if (r == NULL) + { + if (PyErr_Occurred() && !msg_silent) + PyErr_PrintEx(0); +--- 5013,5022 ---- + #endif + ) + { +! PyObject *run_ret; + +! run_ret = PyRun_String((char *) cmd, Py_eval_input, globals, globals); +! if (run_ret == NULL) + { + if (PyErr_Occurred() && !msg_silent) + PyErr_PrintEx(0); +*************** +*** 5001,5009 **** + } + else + { +! if (ConvertFromPyObject(r, rettv) == -1) + EMSG(_("E859: Failed to convert returned python object to vim value")); +! Py_DECREF(r); + } + PyErr_Clear(); + } +--- 5024,5032 ---- + } + else + { +! if (ConvertFromPyObject(run_ret, rettv) == -1) + EMSG(_("E859: Failed to convert returned python object to vim value")); +! Py_DECREF(run_ret); + } + PyErr_Clear(); + } +*************** +*** 5306,5312 **** + ConvertFromPyMapping(PyObject *obj, typval_T *tv) + { + PyObject *lookup_dict; +! int r; + + if (!(lookup_dict = PyDict_New())) + return -1; +--- 5329,5335 ---- + ConvertFromPyMapping(PyObject *obj, typval_T *tv) + { + PyObject *lookup_dict; +! int ret; + + if (!(lookup_dict = PyDict_New())) + return -1; +*************** +*** 5316,5349 **** + tv->v_type = VAR_DICT; + tv->vval.v_dict = (((DictionaryObject *)(obj))->dict); + ++tv->vval.v_dict->dv_refcount; +! r = 0; + } + else if (PyDict_Check(obj)) +! r = convert_dl(obj, tv, pydict_to_tv, lookup_dict); + else if (PyMapping_Check(obj)) +! r = convert_dl(obj, tv, pymap_to_tv, lookup_dict); + else + { + PyErr_FORMAT(PyExc_TypeError, + "unable to convert %s to vim dictionary", + Py_TYPE_NAME(obj)); +! r = -1; + } + Py_DECREF(lookup_dict); +! return r; + } + + static int + ConvertFromPyObject(PyObject *obj, typval_T *tv) + { + PyObject *lookup_dict; +! int r; + + if (!(lookup_dict = PyDict_New())) + return -1; +! r = _ConvertFromPyObject(obj, tv, lookup_dict); + Py_DECREF(lookup_dict); +! return r; + } + + static int +--- 5339,5372 ---- + tv->v_type = VAR_DICT; + tv->vval.v_dict = (((DictionaryObject *)(obj))->dict); + ++tv->vval.v_dict->dv_refcount; +! ret = 0; + } + else if (PyDict_Check(obj)) +! ret = convert_dl(obj, tv, pydict_to_tv, lookup_dict); + else if (PyMapping_Check(obj)) +! ret = convert_dl(obj, tv, pymap_to_tv, lookup_dict); + else + { + PyErr_FORMAT(PyExc_TypeError, + "unable to convert %s to vim dictionary", + Py_TYPE_NAME(obj)); +! ret = -1; + } + Py_DECREF(lookup_dict); +! return ret; + } + + static int + ConvertFromPyObject(PyObject *obj, typval_T *tv) + { + PyObject *lookup_dict; +! int ret; + + if (!(lookup_dict = PyDict_New())) + return -1; +! ret = _ConvertFromPyObject(obj, tv, lookup_dict); + Py_DECREF(lookup_dict); +! return ret; + } + + static int +*************** +*** 5371,5384 **** + } + else if (PyBytes_Check(obj)) + { +! char_u *result; + +! if (PyBytes_AsStringAndSize(obj, (char **) &result, NULL) == -1) + return -1; +! if (result == NULL) + return -1; + +! if (set_string_copy(result, tv) == -1) + return -1; + + tv->v_type = VAR_STRING; +--- 5394,5407 ---- + } + else if (PyBytes_Check(obj)) + { +! char_u *str; + +! if (PyBytes_AsStringAndSize(obj, (char **) &str, NULL) == -1) + return -1; +! if (str == NULL) + return -1; + +! if (set_string_copy(str, tv) == -1) + return -1; + + tv->v_type = VAR_STRING; +*************** +*** 5386,5403 **** + else if (PyUnicode_Check(obj)) + { + PyObject *bytes; +! char_u *result; + + bytes = PyUnicode_AsEncodedString(obj, ENC_OPT, NULL); + if (bytes == NULL) + return -1; + +! if(PyBytes_AsStringAndSize(bytes, (char **) &result, NULL) == -1) + return -1; +! if (result == NULL) + return -1; + +! if (set_string_copy(result, tv)) + { + Py_XDECREF(bytes); + return -1; +--- 5409,5426 ---- + else if (PyUnicode_Check(obj)) + { + PyObject *bytes; +! char_u *str; + + bytes = PyUnicode_AsEncodedString(obj, ENC_OPT, NULL); + if (bytes == NULL) + return -1; + +! if(PyBytes_AsStringAndSize(bytes, (char **) &str, NULL) == -1) + return -1; +! if (str == NULL) + return -1; + +! if (set_string_copy(str, tv)) + { + Py_XDECREF(bytes); + return -1; +*************** +*** 5852,5858 **** + + static struct numeric_constant { + char *name; +! int value; + } numeric_constants[] = { + {"VAR_LOCKED", VAR_LOCKED}, + {"VAR_FIXED", VAR_FIXED}, +--- 5875,5881 ---- + + static struct numeric_constant { + char *name; +! int val; + } numeric_constants[] = { + {"VAR_LOCKED", VAR_LOCKED}, + {"VAR_FIXED", VAR_FIXED}, +*************** +*** 5862,5868 **** + + static struct object_constant { + char *name; +! PyObject *value; + } object_constants[] = { + {"buffers", (PyObject *)(void *)&TheBufferMap}, + {"windows", (PyObject *)(void *)&TheWindowList}, +--- 5885,5891 ---- + + static struct object_constant { + char *name; +! PyObject *valObject; + } object_constants[] = { + {"buffers", (PyObject *)(void *)&TheBufferMap}, + {"windows", (PyObject *)(void *)&TheWindowList}, +*************** +*** 5889,5898 **** + + #define ADD_CHECKED_OBJECT(m, name, obj) \ + { \ +! PyObject *value = obj; \ +! if (!value) \ + return -1; \ +! ADD_OBJECT(m, name, value); \ + } + + static int +--- 5912,5921 ---- + + #define ADD_CHECKED_OBJECT(m, name, obj) \ + { \ +! PyObject *valObject = obj; \ +! if (!valObject) \ + return -1; \ +! ADD_OBJECT(m, name, valObject); \ + } + + static int +*************** +*** 5907,5923 **** + / sizeof(struct numeric_constant)); + ++i) + ADD_CHECKED_OBJECT(m, numeric_constants[i].name, +! PyInt_FromLong(numeric_constants[i].value)); + + for (i = 0; i < (int)(sizeof(object_constants) + / sizeof(struct object_constant)); + ++i) + { +! PyObject *value; + +! value = object_constants[i].value; +! Py_INCREF(value); +! ADD_OBJECT(m, object_constants[i].name, value); + } + + if (!(VimError = PyErr_NewException("vim.error", NULL, NULL))) +--- 5930,5946 ---- + / sizeof(struct numeric_constant)); + ++i) + ADD_CHECKED_OBJECT(m, numeric_constants[i].name, +! PyInt_FromLong(numeric_constants[i].val)); + + for (i = 0; i < (int)(sizeof(object_constants) + / sizeof(struct object_constant)); + ++i) + { +! PyObject *valObject; + +! valObject = object_constants[i].valObject; +! Py_INCREF(valObject); +! ADD_OBJECT(m, object_constants[i].name, valObject); + } + + if (!(VimError = PyErr_NewException("vim.error", NULL, NULL))) +*** ../vim-7.3.1231/src/version.c 2013-06-23 14:16:53.000000000 +0200 +--- src/version.c 2013-06-23 14:27:07.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1232, + /**/ + +-- +Ten bugs in the hand is better than one as yet undetected. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 40865eba49a2b2981d43a7b6b644b0c4bafcc13d Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:30 +0200 Subject: [PATCH 1126/3340] - patchlevel 1233 --- 7.3.1233 | 3829 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 3829 insertions(+) create mode 100644 7.3.1233 diff --git a/7.3.1233 b/7.3.1233 new file mode 100644 index 00000000..eede8af2 --- /dev/null +++ b/7.3.1233 @@ -0,0 +1,3829 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1233 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1233 +Problem: Various Python problems. +Solution: Fix VimTryEnd. Crash with debug build and PYTHONDUMPREFS=1. Memory + leaks in StringToLine(), BufferMark() and convert_dl. (ZyX) +Files: src/if_py_both.h, src/testdir/test86.in, src/testdir/test86.ok, + src/testdir/test87.in, src/testdir/test87.ok + + +*** ../vim-7.3.1232/src/if_py_both.h 2013-06-23 14:30:42.000000000 +0200 +--- src/if_py_both.h 2013-06-23 14:34:17.000000000 +0200 +*************** +*** 544,563 **** + VimTryEnd(void) + { + --trylevel; + if (got_int) + { + PyErr_SetNone(PyExc_KeyboardInterrupt); +! return 1; + } + else if (!did_throw) +! return 0; + else if (PyErr_Occurred()) +! return 1; + else + { + PyErr_SetVim((char *) current_exception->value); + discard_current_exception(); +! return 1; + } + } + +--- 544,573 ---- + VimTryEnd(void) + { + --trylevel; ++ /* Without this it stops processing all subsequent VimL commands and ++ * generates strange error messages if I e.g. try calling Test() in a cycle */ ++ did_emsg = FALSE; ++ /* Keyboard interrupt should be preferred over anything else */ + if (got_int) + { ++ did_throw = got_int = FALSE; + PyErr_SetNone(PyExc_KeyboardInterrupt); +! return -1; + } + else if (!did_throw) +! return (PyErr_Occurred() ? -1 : 0); +! /* Python exception is preferred over vim one; unlikely to occur though */ + else if (PyErr_Occurred()) +! { +! did_throw = FALSE; +! return -1; +! } +! /* Finally transform VimL exception to python one */ + else + { + PyErr_SetVim((char *) current_exception->value); + discard_current_exception(); +! return -1; + } + } + +*************** +*** 2649,2655 **** + static PyObject * + FunctionRepr(FunctionObject *self) + { +! return PyString_FromFormat("", self->name); + } + + static struct PyMethodDef FunctionMethods[] = { +--- 2659,2672 ---- + static PyObject * + FunctionRepr(FunctionObject *self) + { +! #ifdef Py_TRACE_REFS +! /* For unknown reason self->name may be NULL after calling +! * Finalize */ +! return PyString_FromFormat("", +! (self->name == NULL ? "" : (char *) self->name)); +! #else +! return PyString_FromFormat("", (char *) self->name); +! #endif + } + + static struct PyMethodDef FunctionMethods[] = { +*************** +*** 3534,3539 **** +--- 3551,3557 ---- + else + { + PyErr_SET_VIM("string cannot contain newlines"); ++ Py_XDECREF(bytes); + return NULL; + } + } +*************** +*** 3545,3550 **** +--- 3563,3569 ---- + if (save == NULL) + { + PyErr_NoMemory(); ++ Py_XDECREF(bytes); + return NULL; + } + +*************** +*** 4551,4556 **** +--- 4570,4576 ---- + { + PyErr_SET_STRING(PyExc_ValueError, + "mark name must be a single character"); ++ Py_XDECREF(todecref); + return NULL; + } + +*************** +*** 5298,5303 **** +--- 5318,5326 ---- + tv->v_type = VAR_UNKNOWN; + return -1; + } ++ ++ Py_DECREF(capsule); ++ + if (py_to_tv(obj, tv, lookup_dict) == -1) + { + tv->v_type = VAR_UNKNOWN; +*************** +*** 5378,5390 **** + tv->vval.v_dict = (((DictionaryObject *)(obj))->dict); + ++tv->vval.v_dict->dv_refcount; + } +! else if (obj->ob_type == &ListType) + { + tv->v_type = VAR_LIST; + tv->vval.v_list = (((ListObject *)(obj))->list); + ++tv->vval.v_list->lv_refcount; + } +! else if (obj->ob_type == &FunctionType) + { + if (set_string_copy(((FunctionObject *) (obj))->name, tv) == -1) + return -1; +--- 5401,5413 ---- + tv->vval.v_dict = (((DictionaryObject *)(obj))->dict); + ++tv->vval.v_dict->dv_refcount; + } +! else if (PyType_IsSubtype(obj->ob_type, &ListType)) + { + tv->v_type = VAR_LIST; + tv->vval.v_list = (((ListObject *)(obj))->list); + ++tv->vval.v_list->lv_refcount; + } +! else if (PyType_IsSubtype(obj->ob_type, &FunctionType)) + { + if (set_string_copy(((FunctionObject *) (obj))->name, tv) == -1) + return -1; +*** ../vim-7.3.1232/src/testdir/test86.in 2013-06-12 14:26:20.000000000 +0200 +--- src/testdir/test86.in 2013-06-23 14:34:17.000000000 +0200 +*************** +*** 11,18 **** + :set noswapfile + :if !has('python') | e! test.ok | wq! test.out | endif + :lang C +- :py import vim + :fun Test() + :let l = [] + :py l=vim.bindeval('l') + :py f=vim.bindeval('function("strlen")') +--- 11,18 ---- + :set noswapfile + :if !has('python') | e! test.ok | wq! test.out | endif + :lang C + :fun Test() ++ :py import vim + :let l = [] + :py l=vim.bindeval('l') + :py f=vim.bindeval('function("strlen")') +*************** +*** 58,63 **** +--- 58,66 ---- + : $put =string(key) . ' : ' . string(Val) + : unlet key Val + :endfor ++ :py del dk ++ :py del di ++ :py del dv + :" + :" removing items with del + :py del l[2] +*************** +*** 176,187 **** + :unlockvar! l + :" + :" Function calls +! :function New(...) +! :return ['NewStart']+a:000+['NewEnd'] +! :endfunction +! :function DictNew(...) dict +! :return ['DictNewStart']+a:000+['DictNewEnd', self] +! :endfunction + :let l=[function('New'), function('DictNew')] + :py l=vim.bindeval('l') + :py l.extend(list(l[0](1, 2, 3))) +--- 179,190 ---- + :unlockvar! l + :" + :" Function calls +! :fun New(...) +! : return ['NewStart']+a:000+['NewEnd'] +! :endfun +! :fun DictNew(...) dict +! : return ['DictNewStart']+a:000+['DictNewEnd', self] +! :endfun + :let l=[function('New'), function('DictNew')] + :py l=vim.bindeval('l') + :py l.extend(list(l[0](1, 2, 3))) +*************** +*** 211,216 **** +--- 214,220 ---- + : $put ='[0.0, 0.0]' + :endif + :let messages=[] ++ :delfunction DictNew + py < 8 # check if the background thread is working ++ :py del time ++ :py del threading + :$put =string(l) + :" + :" settrace +*************** +*** 333,338 **** +--- 342,349 ---- + EOF + :py sys.settrace(traceit) + :py trace_main() ++ :py del traceit ++ :py del trace_main + :py sys.settrace(None) + :$put =string(l) + :" +*************** +*** 363,369 **** + :" + :" Vars + :let g:foo = 'bac' +! :let w:abc = 'def' + :let b:baz = 'bar' + :let t:bar = 'jkl' + :try +--- 374,380 ---- + :" + :" Vars + :let g:foo = 'bac' +! :let w:abc3 = 'def' + :let b:baz = 'bar' + :let t:bar = 'jkl' + :try +*************** +*** 372,378 **** + : put =pyeval('vim.vvars[''exception'']') + :endtry + :put =pyeval('vim.vars[''foo'']') +! :put =pyeval('vim.current.window.vars[''abc'']') + :put =pyeval('vim.current.buffer.vars[''baz'']') + :put =pyeval('vim.current.tabpage.vars[''bar'']') + :" +--- 383,389 ---- + : put =pyeval('vim.vvars[''exception'']') + :endtry + :put =pyeval('vim.vars[''foo'']') +! :put =pyeval('vim.current.window.vars[''abc3'']') + :put =pyeval('vim.current.buffer.vars[''baz'']') + :put =pyeval('vim.current.tabpage.vars[''bar'']') + :" +*************** +*** 420,435 **** + vim.command('let exc=' + repr(sys.exc_type.__name__)) + return 0 + EOF +! :function E(s) + : python e(vim.eval('a:s')) +! :endfunction +! :function Ev(s) + : let r=pyeval('ev(vim.eval("a:s"))') + : if exists('exc') + : throw exc + : endif + : return r +! :endfunction + :py gopts1=vim.options + :py wopts1=vim.windows[2].options + :py wopts2=vim.windows[0].options +--- 431,446 ---- + vim.command('let exc=' + repr(sys.exc_type.__name__)) + return 0 + EOF +! :fun E(s) + : python e(vim.eval('a:s')) +! :endfun +! :fun Ev(s) + : let r=pyeval('ev(vim.eval("a:s"))') + : if exists('exc') + : throw exc + : endif + : return r +! :endfun + :py gopts1=vim.options + :py wopts1=vim.windows[2].options + :py wopts2=vim.windows[0].options +*************** +*** 444,450 **** + :let lst+=[['operatorfunc', 'A', 'B', 'C', 2, 0, 1, 0 ]] + :let lst+=[['number', 0, 1, 1, 0, 1, 0, 1 ]] + :let lst+=[['numberwidth', 2, 3, 5, -100, 0, 0, 1 ]] +! :let lst+=[['colorcolumn', '+1', '+2', '+3', 'abc', 0, 0, 1 ]] + :let lst+=[['statusline', '1', '2', '4', 0, 0, 1, 1 ]] + :let lst+=[['autoindent', 0, 1, 1, 2, 1, 0, 2 ]] + :let lst+=[['shiftwidth', 0, 2, 1, 3, 0, 0, 2 ]] +--- 455,461 ---- + :let lst+=[['operatorfunc', 'A', 'B', 'C', 2, 0, 1, 0 ]] + :let lst+=[['number', 0, 1, 1, 0, 1, 0, 1 ]] + :let lst+=[['numberwidth', 2, 3, 5, -100, 0, 0, 1 ]] +! :let lst+=[['colorcolumn', '+1', '+2', '+3', 'abc4', 0, 0, 1 ]] + :let lst+=[['statusline', '1', '2', '4', 0, 0, 1, 1 ]] + :let lst+=[['autoindent', 0, 1, 1, 2, 1, 0, 2 ]] + :let lst+=[['shiftwidth', 0, 2, 1, 3, 0, 0, 2 ]] +*************** +*** 494,503 **** +--- 505,531 ---- + : endfor + : call RecVars(oname) + :endfor ++ :delfunction RecVars ++ :delfunction E ++ :delfunction Ev ++ :py del ev ++ :py del e + :only + :for buf in g:bufs[1:] + : execute 'bwipeout!' buf + :endfor ++ :py del gopts1 ++ :py del wopts1 ++ :py del wopts2 ++ :py del wopts3 ++ :py del bopts1 ++ :py del bopts2 ++ :py del bopts3 ++ :py del oval1 ++ :py del oval2 ++ :py del oval3 ++ :py del oname ++ :py del invval + :" + :" Test buffer object + :vnew +*************** +*** 517,523 **** + # Tests BufferAppend and BufferItem + cb.append(b[0]) + # Tests BufferSlice and BufferAssSlice +! cb.append('abc') # Will be overwritten + cb[-1:] = b[:-2] + # Test BufferLength and BufferAssSlice + cb.append('def') # Will not be overwritten +--- 545,551 ---- + # Tests BufferAppend and BufferItem + cb.append(b[0]) + # Tests BufferSlice and BufferAssSlice +! cb.append('abc5') # Will be overwritten + cb[-1:] = b[:-2] + # Test BufferLength and BufferAssSlice + cb.append('def') # Will not be overwritten +*************** +*** 541,553 **** + cb.append(b.name[-11:].replace(os.path.sep, '/')) + cb.name = old_name + cb.append(cb.name[-17:].replace(os.path.sep, '/')) + # Test CheckBuffer + for _b in vim.buffers: + if _b is not cb: + vim.command('bwipeout! ' + str(_b.number)) + del _b + cb.append('valid: b:%s, cb:%s' % (repr(b.valid), repr(cb.valid))) +! for expr in ('b[1]','b[:] = ["A", "B"]','b[:]','b.append("abc")', 'b.name = "!"'): + try: + exec(expr) + except vim.error: +--- 569,582 ---- + cb.append(b.name[-11:].replace(os.path.sep, '/')) + cb.name = old_name + cb.append(cb.name[-17:].replace(os.path.sep, '/')) ++ del old_name + # Test CheckBuffer + for _b in vim.buffers: + if _b is not cb: + vim.command('bwipeout! ' + str(_b.number)) + del _b + cb.append('valid: b:%s, cb:%s' % (repr(b.valid), repr(cb.valid))) +! for expr in ('b[1]','b[:] = ["A", "B"]','b[:]','b.append("abc6")', 'b.name = "!"'): + try: + exec(expr) + except vim.error: +*************** +*** 557,562 **** +--- 586,592 ---- + # Should not happen in any case + cb.append('No exception for ' + expr) + vim.command('cd .') ++ del b + EOF + :augroup BUFS + : autocmd! +*************** +*** 598,603 **** +--- 628,634 ---- + # Check indexing: vim.buffers[number].number == number + cb.append(str(b.number) + ':' + repr(vim.buffers[b.number]) + '=' + repr(b)) + prevnum = b.number ++ del prevnum + + cb.append(str(len(vim.buffers))) + +*************** +*** 621,626 **** +--- 652,659 ---- + next(i4) + except StopIteration: + cb.append('StopIteration') ++ del i4 ++ del bnums + EOF + :" + :" Test vim.{tabpage,window}list and vim.{tabpage,window} objects +*************** +*** 663,669 **** +--- 696,706 ---- + raise ValueError + except Exception: + cb.append('!!!!!! Error while getting attribute ' + attr + ': ' + sys.exc_type.__name__) ++ del aval ++ del attr + w.cursor = (len(w.buffer), 0) ++ del W ++ del Cursor + cb.append('Number of windows in current tab page: ' + str(len(vim.windows))) + if list(vim.windows) != list(vim.current.tabpage.windows): + cb.append('!!!!!! Windows differ') +*************** +*** 676,681 **** +--- 713,719 ---- + cb.append('Current tab page: ' + repr(vim.current.tabpage)) + cb.append('Current window: ' + repr(vim.current.window) + ': ' + H(vim.current.window) + ' is ' + H(vim.current.tabpage.window)) + cb.append('Current buffer: ' + repr(vim.current.buffer) + ': ' + H(vim.current.buffer) + ' is ' + H(vim.current.window.buffer)+ ' is ' + H(vim.current.tabpage.window.buffer)) ++ del H + # Assigning: fails + try: + vim.current.window = vim.tabpages[0].window +*************** +*** 687,692 **** +--- 725,731 ---- + setattr(vim.current, attr, None) + except TypeError: + cb.append('Type error at assigning None to vim.current.' + attr) ++ del attr + + # Assigning: success + vim.current.tabpage = vim.tabpages[-2] +*************** +*** 702,709 **** +--- 741,753 ---- + for b in vim.buffers: + if b is not cb: + vim.command('bwipeout! ' + str(b.number)) ++ del b + cb.append('w.valid: ' + repr([w.valid for w in ws])) + cb.append('t.valid: ' + repr([t.valid for t in ts])) ++ del w ++ del t ++ del ts ++ del ws + EOF + :tabonly! + :only! +*************** +*** 722,727 **** +--- 766,773 ---- + ('vim.current.tabpage', 'TabPage'), + ): + cb.append(expr + ':' + attr + ':' + repr(type(eval(expr)) is getattr(vim, attr))) ++ del expr ++ del attr + EOF + :" + :" Test __dir__() method +*************** +*** 747,761 **** + :$put =string(pyeval('vim.Dictionary(a=1)')) + :$put =string(pyeval('vim.Dictionary(((''a'', 1),))')) + :$put =string(pyeval('vim.List()')) +! :$put =string(pyeval('vim.List(iter(''abc''))')) + :$put =string(pyeval('vim.Function(''tr'')')) + :" + :" Test stdout/stderr + :redir => messages +! :py sys.stdout.write('abc') ; sys.stdout.write('def') +! :py sys.stderr.write('abc') ; sys.stderr.write('def') +! :py sys.stdout.writelines(iter('abc')) +! :py sys.stderr.writelines(iter('abc')) + :redir END + :$put =string(substitute(messages, '\d\+', '', 'g')) + :" Test subclassing +--- 793,807 ---- + :$put =string(pyeval('vim.Dictionary(a=1)')) + :$put =string(pyeval('vim.Dictionary(((''a'', 1),))')) + :$put =string(pyeval('vim.List()')) +! :$put =string(pyeval('vim.List(iter(''abc7''))')) + :$put =string(pyeval('vim.Function(''tr'')')) + :" + :" Test stdout/stderr + :redir => messages +! :py sys.stdout.write('abc8') ; sys.stdout.write('def') +! :py sys.stderr.write('abc9') ; sys.stderr.write('def') +! :py sys.stdout.writelines(iter('abcA')) +! :py sys.stderr.writelines(iter('abcB')) + :redir END + :$put =string(substitute(messages, '\d\+', '', 'g')) + :" Test subclassing +*************** +*** 776,782 **** + return [super(DupList, self).__getitem__(idx)] * 2 + + dl = DupList() +! dl2 = DupList(iter('abc')) + dl.extend(dl2[0]) + + class DupFun(vim.Function): +--- 822,828 ---- + return [super(DupList, self).__getitem__(idx)] * 2 + + dl = DupList() +! dl2 = DupList(iter('abcC')) + dl.extend(dl2[0]) + + class DupFun(vim.Function): +*************** +*** 789,794 **** +--- 835,853 ---- + :$put =string(pyeval('dl')) + :$put =string(pyeval('dl2')) + :$put =string(pyeval('df(2)')) ++ :$put =string(pyeval('dl') is# pyeval('dl')) ++ :$put =string(pyeval('dd') is# pyeval('dd')) ++ :$put =string(pyeval('df')) ++ :delfunction Put ++ py << EOF ++ del DupDict ++ del DupList ++ del DupFun ++ del dd ++ del dl ++ del dl2 ++ del df ++ EOF + :" + :" Test chdir + py << EOF +*************** +*** 802,807 **** +--- 861,867 ---- + os.chdir('testdir') + cb.append(fnamemodify('.', ':p:h:t')) + cb.append(vim.eval('@%')) ++ del fnamemodify + EOF + :" + :" Test errors +*************** +*** 828,838 **** + else: + cb.append(expr + ':NOT FAILED') + d = vim.Dictionary() +! ned = vim.Dictionary(foo='bar', baz='abc') + dl = vim.Dictionary(a=1) + dl.locked = True + l = vim.List() +! ll = vim.List('abc') + ll.locked = True + f = vim.Function('string') + fd = vim.Function('F') +--- 888,898 ---- + else: + cb.append(expr + ':NOT FAILED') + d = vim.Dictionary() +! ned = vim.Dictionary(foo='bar', baz='abcD') + dl = vim.Dictionary(a=1) + dl.locked = True + l = vim.List() +! ll = vim.List('abcE') + ll.locked = True + f = vim.Function('string') + fd = vim.Function('F') +*************** +*** 869,879 **** + # pydict_to_tv + stringtochars_test(expr % '{%s : 1}') + if recurse: +! convertfrompyobject_test(expr % '{"abc" : %s}', False) + # pymap_to_tv + stringtochars_test(expr % 'Mapping({%s : 1})') + if recurse: +! convertfrompyobject_test(expr % 'Mapping({"abc" : %s})', False) + # pyseq_to_tv + iter_test(expr) + return subexpr_test(expr, 'ConvertFromPyObject', ( +--- 929,939 ---- + # pydict_to_tv + stringtochars_test(expr % '{%s : 1}') + if recurse: +! convertfrompyobject_test(expr % '{"abcF" : %s}', False) + # pymap_to_tv + stringtochars_test(expr % 'Mapping({%s : 1})') + if recurse: +! convertfrompyobject_test(expr % 'Mapping({"abcG" : %s})', False) + # pyseq_to_tv + iter_test(expr) + return subexpr_test(expr, 'ConvertFromPyObject', ( +*************** +*** 916,922 **** + raise NotImplementedError + + def keys(self): +! return list("abc") + + class FailingMapping(object): + def __getitem__(self): +--- 976,982 ---- + raise NotImplementedError + + def keys(self): +! return list("abcH") + + class FailingMapping(object): + def __getitem__(self): +*************** +*** 958,964 **** + ee('vim.strwidth(1)') + cb.append("> Dictionary") + cb.append(">> DictionaryConstructor") +! ee('vim.Dictionary("abc")') + ##! Not checked: py_dict_alloc failure + cb.append(">> DictionarySetattr") + ee('del d.locked') +--- 1018,1024 ---- + ee('vim.strwidth(1)') + cb.append("> Dictionary") + cb.append(">> DictionaryConstructor") +! ee('vim.Dictionary("abcI")') + ##! Not checked: py_dict_alloc failure + cb.append(">> DictionarySetattr") + ee('del d.locked') +*************** +*** 973,978 **** +--- 1033,1039 ---- + ee('dl.pop("a")') + cb.append(">> DictionaryIterNext") + ee('for i in ned: ned["a"] = 1') ++ del i + cb.append(">> DictionaryAssItem") + ee('dl["b"] = 1') + stringtochars_test('d[%s] = 1') +*************** +*** 1002,1008 **** + ee('ll[1] = 2') + ee('l[1000] = 3') + cb.append(">> ListAssSlice") +! ee('ll[1:100] = "abc"') + #iter_test('l[:] = %s') + convertfrompyobject_test('l[:] = [%s]') + cb.append(">> ListConcatInPlace") +--- 1063,1069 ---- + ee('ll[1] = 2') + ee('l[1000] = 3') + cb.append(">> ListAssSlice") +! ee('ll[1:100] = "abcJ"') + #iter_test('l[:] = %s') + convertfrompyobject_test('l[:] = [%s]') + cb.append(">> ListConcatInPlace") +*************** +*** 1033,1040 **** + ee('vim.current.window.buffer = 0') + ee('vim.current.window.cursor = (100000000, 100000000)') + ee('vim.current.window.cursor = True') +! ee('vim.current.window.height = "abc"') +! ee('vim.current.window.width = "abc"') + ee('vim.current.window.xxxxxx = True') + cb.append("> WinList") + cb.append(">> WinListItem") +--- 1094,1101 ---- + ee('vim.current.window.buffer = 0') + ee('vim.current.window.cursor = (100000000, 100000000)') + ee('vim.current.window.cursor = True') +! ee('vim.current.window.height = "abcK"') +! ee('vim.current.window.width = "abcL"') + ee('vim.current.window.xxxxxx = True') + cb.append("> WinList") + cb.append(">> WinListItem") +*************** +*** 1044,1050 **** + ee('vim.current.buffer[0] = "\\na"') + cb.append(">> SetBufferLine (indirect)") + ee('vim.current.buffer[0] = True') +! cb.append(">> SetBufferLines (indirect)") + ee('vim.current.buffer[:] = True') + ee('vim.current.buffer[:] = ["\\na", "bc"]') + cb.append(">> InsertBufferLines (indirect)") +--- 1105,1111 ---- + ee('vim.current.buffer[0] = "\\na"') + cb.append(">> SetBufferLine (indirect)") + ee('vim.current.buffer[0] = True') +! cb.append(">> SetBufferLineList (indirect)") + ee('vim.current.buffer[:] = True') + ee('vim.current.buffer[:] = ["\\na", "bc"]') + cb.append(">> InsertBufferLines (indirect)") +*************** +*** 1062,1068 **** + ee('vim.current.buffer.xxx = True') + cb.append(">> BufferMark") + ee('vim.current.buffer.mark(0)') +! ee('vim.current.buffer.mark("abc")') + ee('vim.current.buffer.mark("!")') + cb.append(">> BufferRange") + ee('vim.current.buffer.range(1, 2, 3)') +--- 1123,1129 ---- + ee('vim.current.buffer.xxx = True') + cb.append(">> BufferMark") + ee('vim.current.buffer.mark(0)') +! ee('vim.current.buffer.mark("abcM")') + ee('vim.current.buffer.mark("!")') + cb.append(">> BufferRange") + ee('vim.current.buffer.range(1, 2, 3)') +*************** +*** 1079,1085 **** +--- 1140,1167 ---- + ee('vim.current.window = True') + ee('vim.current.tabpage = True') + ee('vim.current.xxx = True') ++ del d ++ del ned ++ del dl ++ del l ++ del ll ++ del f ++ del fd ++ del fdel ++ del subexpr_test ++ del stringtochars_test ++ del Mapping ++ del convertfrompyobject_test ++ del convertfrompymapping_test ++ del iter_test ++ del FailingTrue ++ del FailingIter ++ del FailingIterNext ++ del FailingMapping ++ del FailingMappingKey ++ del FailingList + EOF ++ :delfunction F + :" + :" Test import + py << EOF +*************** +*** 1093,1098 **** +--- 1175,1184 ---- + cb.append(before.dir) + import after + cb.append(after.dir) ++ del before ++ del after ++ del d ++ del ddir + EOF + :" + :" Test exceptions +*************** +*** 1101,1118 **** + :endfun + py << EOF + Exe = vim.bindeval('function("Exe")') +! ee('vim.command("throw \'abc\'")') + ee('Exe("throw \'def\'")') + ee('vim.eval("Exe(\'throw \'\'ghi\'\'\')")') + ee('vim.eval("Exe(\'echoerr \'\'jkl\'\'\')")') + ee('vim.eval("Exe(\'xxx_non_existent_command_xxx\')")') + ee('vim.bindeval("Exe(\'xxx_non_existent_command_xxx\')")') + EOF + :endfun + :" +! :call Test() + :" +! :delfunc Test + :call garbagecollect(1) + :" + :/^start:/,$wq! test.out +--- 1187,1234 ---- + :endfun + py << EOF + Exe = vim.bindeval('function("Exe")') +! ee('vim.command("throw \'abcN\'")') + ee('Exe("throw \'def\'")') + ee('vim.eval("Exe(\'throw \'\'ghi\'\'\')")') + ee('vim.eval("Exe(\'echoerr \'\'jkl\'\'\')")') + ee('vim.eval("Exe(\'xxx_non_existent_command_xxx\')")') + ee('vim.bindeval("Exe(\'xxx_non_existent_command_xxx\')")') ++ del Exe ++ EOF ++ :delfunction Exe ++ :" ++ :" Cleanup ++ py << EOF ++ del cb ++ del ee ++ del sys ++ del os ++ del vim + EOF + :endfun + :" +! :fun RunTest() +! :let checkrefs = !empty($PYTHONDUMPREFS) +! :let start = getline(1, '$') +! :for i in range(checkrefs ? 10 : 1) +! : if i != 0 +! : %d _ +! : call setline(1, start) +! : endif +! : call Test() +! : if i == 0 +! : let result = getline(1, '$') +! : endif +! :endfor +! :if checkrefs +! : %d _ +! : call setline(1, result) +! :endif +! :endfun + :" +! :call RunTest() +! :delfunction RunTest +! :delfunction Test + :call garbagecollect(1) + :" + :/^start:/,$wq! test.out +*** ../vim-7.3.1232/src/testdir/test86.ok 2013-06-23 14:16:53.000000000 +0200 +--- src/testdir/test86.ok 2013-06-23 14:34:17.000000000 +0200 +*************** +*** 68,74 **** + dl : locked:1;scope:0 + v: : locked:2;scope:1 + g: : locked:0;scope:2 +! d:{'abc': 1} + dl:{'def': 1} + l : locked:0 + ll : locked:1 +--- 68,74 ---- + dl : locked:1;scope:0 + v: : locked:2;scope:1 + g: : locked:0;scope:2 +! d:{'abc2': 1} + dl:{'def': 1} + l : locked:0 + ll : locked:1 +*************** +*** 202,213 **** + B: 1:3 2:5 3:2 4:8 + >>> colorcolumn + p/gopts1! KeyError +! inv: 'abc'! KeyError + gopts1! KeyError + p/wopts1: '' +! inv: 'abc'! error + p/bopts1! KeyError +! inv: 'abc'! KeyError + bopts1! KeyError + bopts2! KeyError + bopts3! KeyError +--- 202,213 ---- + B: 1:3 2:5 3:2 4:8 + >>> colorcolumn + p/gopts1! KeyError +! inv: 'abc4'! KeyError + gopts1! KeyError + p/wopts1: '' +! inv: 'abc4'! error + p/bopts1! KeyError +! inv: 'abc4'! KeyError + bopts1! KeyError + bopts2! KeyError + bopts3! KeyError +*************** +*** 415,434 **** + {'a': 1} + {'a': 1} + [] +! ['a', 'b', 'c'] + function('tr') + ' + abcdef + line : + abcdef +! abc + line : +! abc' + ['a', 'dup_a'] + ['a', 'a'] +! ['a', 'b', 'c'] + [2, 2] + [2, 2] + testdir + test86.in + src +--- 415,437 ---- + {'a': 1} + {'a': 1} + [] +! ['a', 'b', 'c', '7'] + function('tr') + ' + abcdef + line : + abcdef +! abcA + line : +! abcB' + ['a', 'dup_a'] + ['a', 'a'] +! ['a', 'b', 'c', 'C'] + [2, 2] + [2, 2] ++ 1 ++ 1 ++ function('Put') + testdir + test86.in + src +*************** +*** 456,462 **** + vim.strwidth(1):TypeError:('expected str() or unicode() instance, but got int',) + > Dictionary + >> DictionaryConstructor +! vim.Dictionary("abc"):ValueError:('expected sequence element of size 2, but got sequence of size 1',) + >> DictionarySetattr + del d.locked:AttributeError:('cannot delete vim.Dictionary attributes',) + d.locked = FailingTrue():NotImplementedError:() +--- 459,465 ---- + vim.strwidth(1):TypeError:('expected str() or unicode() instance, but got int',) + > Dictionary + >> DictionaryConstructor +! vim.Dictionary("abcI"):ValueError:('expected sequence element of size 2, but got sequence of size 1',) + >> DictionarySetattr + del d.locked:AttributeError:('cannot delete vim.Dictionary attributes',) + d.locked = FailingTrue():NotImplementedError:() +*************** +*** 486,537 **** + d["a"] = {u"\0" : 1}:TypeError:('expected string without null bytes',) + d["a"] = {"\0" : 1}:TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using d["a"] = {"abc" : {%s : 1}} +! d["a"] = {"abc" : {1 : 1}}:TypeError:('expected str() or unicode() instance, but got int',) +! d["a"] = {"abc" : {u"\0" : 1}}:TypeError:('expected string without null bytes',) +! d["a"] = {"abc" : {"\0" : 1}}:TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using d["a"] = {"abc" : Mapping({%s : 1})} +! d["a"] = {"abc" : Mapping({1 : 1})}:TypeError:('expected str() or unicode() instance, but got int',) +! d["a"] = {"abc" : Mapping({u"\0" : 1})}:TypeError:('expected string without null bytes',) +! d["a"] = {"abc" : Mapping({"\0" : 1})}:TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : FailingIter()}:TypeError:('unable to convert FailingIter to vim structure',) +! d["a"] = {"abc" : FailingIterNext()}:NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : None}:TypeError:('unable to convert NoneType to vim structure',) +! d["a"] = {"abc" : {"": 1}}:ValueError:('empty keys are not allowed',) +! d["a"] = {"abc" : {u"": 1}}:ValueError:('empty keys are not allowed',) +! d["a"] = {"abc" : FailingMapping()}:NotImplementedError:() +! d["a"] = {"abc" : FailingMappingKey()}:NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) + d["a"] = Mapping({1 : 1}):TypeError:('expected str() or unicode() instance, but got int',) + d["a"] = Mapping({u"\0" : 1}):TypeError:('expected string without null bytes',) + d["a"] = Mapping({"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using d["a"] = Mapping({"abc" : {%s : 1}}) +! d["a"] = Mapping({"abc" : {1 : 1}}):TypeError:('expected str() or unicode() instance, but got int',) +! d["a"] = Mapping({"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) +! d["a"] = Mapping({"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using d["a"] = Mapping({"abc" : Mapping({%s : 1})}) +! d["a"] = Mapping({"abc" : Mapping({1 : 1})}):TypeError:('expected str() or unicode() instance, but got int',) +! d["a"] = Mapping({"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) +! d["a"] = Mapping({"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! d["a"] = Mapping({"abc" : FailingIterNext()}):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : None}):TypeError:('unable to convert NoneType to vim structure',) +! d["a"] = Mapping({"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) +! d["a"] = Mapping({"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! d["a"] = Mapping({"abc" : FailingMapping()}):NotImplementedError:() +! d["a"] = Mapping({"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d["a"] = %s + d["a"] = FailingIter():TypeError:('unable to convert FailingIter to vim structure',) +--- 489,540 ---- + d["a"] = {u"\0" : 1}:TypeError:('expected string without null bytes',) + d["a"] = {"\0" : 1}:TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using d["a"] = {"abcF" : {%s : 1}} +! d["a"] = {"abcF" : {1 : 1}}:TypeError:('expected str() or unicode() instance, but got int',) +! d["a"] = {"abcF" : {u"\0" : 1}}:TypeError:('expected string without null bytes',) +! d["a"] = {"abcF" : {"\0" : 1}}:TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using d["a"] = {"abcF" : Mapping({%s : 1})} +! d["a"] = {"abcF" : Mapping({1 : 1})}:TypeError:('expected str() or unicode() instance, but got int',) +! d["a"] = {"abcF" : Mapping({u"\0" : 1})}:TypeError:('expected string without null bytes',) +! d["a"] = {"abcF" : Mapping({"\0" : 1})}:TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using d["a"] = {"abcF" : %s} +! d["a"] = {"abcF" : FailingIter()}:TypeError:('unable to convert FailingIter to vim structure',) +! d["a"] = {"abcF" : FailingIterNext()}:NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using d["a"] = {"abcF" : %s} +! d["a"] = {"abcF" : None}:TypeError:('unable to convert NoneType to vim structure',) +! d["a"] = {"abcF" : {"": 1}}:ValueError:('empty keys are not allowed',) +! d["a"] = {"abcF" : {u"": 1}}:ValueError:('empty keys are not allowed',) +! d["a"] = {"abcF" : FailingMapping()}:NotImplementedError:() +! d["a"] = {"abcF" : FailingMappingKey()}:NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) + d["a"] = Mapping({1 : 1}):TypeError:('expected str() or unicode() instance, but got int',) + d["a"] = Mapping({u"\0" : 1}):TypeError:('expected string without null bytes',) + d["a"] = Mapping({"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using d["a"] = Mapping({"abcG" : {%s : 1}}) +! d["a"] = Mapping({"abcG" : {1 : 1}}):TypeError:('expected str() or unicode() instance, but got int',) +! d["a"] = Mapping({"abcG" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) +! d["a"] = Mapping({"abcG" : {"\0" : 1}}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using d["a"] = Mapping({"abcG" : Mapping({%s : 1})}) +! d["a"] = Mapping({"abcG" : Mapping({1 : 1})}):TypeError:('expected str() or unicode() instance, but got int',) +! d["a"] = Mapping({"abcG" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) +! d["a"] = Mapping({"abcG" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using d["a"] = Mapping({"abcG" : %s}) +! d["a"] = Mapping({"abcG" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! d["a"] = Mapping({"abcG" : FailingIterNext()}):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abcG" : %s}) +! d["a"] = Mapping({"abcG" : None}):TypeError:('unable to convert NoneType to vim structure',) +! d["a"] = Mapping({"abcG" : {"": 1}}):ValueError:('empty keys are not allowed',) +! d["a"] = Mapping({"abcG" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! d["a"] = Mapping({"abcG" : FailingMapping()}):NotImplementedError:() +! d["a"] = Mapping({"abcG" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d["a"] = %s + d["a"] = FailingIter():TypeError:('unable to convert FailingIter to vim structure',) +*************** +*** 554,605 **** + d.update({u"\0" : 1}):TypeError:('expected string without null bytes',) + d.update({"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using d.update({"abc" : {%s : 1}}) +! d.update({"abc" : {1 : 1}}):TypeError:('expected str() or unicode() instance, but got int',) +! d.update({"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) +! d.update({"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using d.update({"abc" : Mapping({%s : 1})}) +! d.update({"abc" : Mapping({1 : 1})}):TypeError:('expected str() or unicode() instance, but got int',) +! d.update({"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) +! d.update({"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using d.update({"abc" : %s}) +! d.update({"abc" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! d.update({"abc" : FailingIterNext()}):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update({"abc" : %s}) +! d.update({"abc" : None}):TypeError:('unable to convert NoneType to vim structure',) +! d.update({"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) +! d.update({"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! d.update({"abc" : FailingMapping()}):NotImplementedError:() +! d.update({"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) + d.update(Mapping({1 : 1})):TypeError:('expected str() or unicode() instance, but got int',) + d.update(Mapping({u"\0" : 1})):TypeError:('expected string without null bytes',) + d.update(Mapping({"\0" : 1})):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using d.update(Mapping({"abc" : {%s : 1}})) +! d.update(Mapping({"abc" : {1 : 1}})):TypeError:('expected str() or unicode() instance, but got int',) +! d.update(Mapping({"abc" : {u"\0" : 1}})):TypeError:('expected string without null bytes',) +! d.update(Mapping({"abc" : {"\0" : 1}})):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using d.update(Mapping({"abc" : Mapping({%s : 1})})) +! d.update(Mapping({"abc" : Mapping({1 : 1})})):TypeError:('expected str() or unicode() instance, but got int',) +! d.update(Mapping({"abc" : Mapping({u"\0" : 1})})):TypeError:('expected string without null bytes',) +! d.update(Mapping({"abc" : Mapping({"\0" : 1})})):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : FailingIter()})):TypeError:('unable to convert FailingIter to vim structure',) +! d.update(Mapping({"abc" : FailingIterNext()})):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : None})):TypeError:('unable to convert NoneType to vim structure',) +! d.update(Mapping({"abc" : {"": 1}})):ValueError:('empty keys are not allowed',) +! d.update(Mapping({"abc" : {u"": 1}})):ValueError:('empty keys are not allowed',) +! d.update(Mapping({"abc" : FailingMapping()})):NotImplementedError:() +! d.update(Mapping({"abc" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d.update(%s) + d.update(FailingIter()):NotImplementedError:() +--- 557,608 ---- + d.update({u"\0" : 1}):TypeError:('expected string without null bytes',) + d.update({"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using d.update({"abcF" : {%s : 1}}) +! d.update({"abcF" : {1 : 1}}):TypeError:('expected str() or unicode() instance, but got int',) +! d.update({"abcF" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) +! d.update({"abcF" : {"\0" : 1}}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using d.update({"abcF" : Mapping({%s : 1})}) +! d.update({"abcF" : Mapping({1 : 1})}):TypeError:('expected str() or unicode() instance, but got int',) +! d.update({"abcF" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) +! d.update({"abcF" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using d.update({"abcF" : %s}) +! d.update({"abcF" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! d.update({"abcF" : FailingIterNext()}):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update({"abcF" : %s}) +! d.update({"abcF" : None}):TypeError:('unable to convert NoneType to vim structure',) +! d.update({"abcF" : {"": 1}}):ValueError:('empty keys are not allowed',) +! d.update({"abcF" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! d.update({"abcF" : FailingMapping()}):NotImplementedError:() +! d.update({"abcF" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) + d.update(Mapping({1 : 1})):TypeError:('expected str() or unicode() instance, but got int',) + d.update(Mapping({u"\0" : 1})):TypeError:('expected string without null bytes',) + d.update(Mapping({"\0" : 1})):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using d.update(Mapping({"abcG" : {%s : 1}})) +! d.update(Mapping({"abcG" : {1 : 1}})):TypeError:('expected str() or unicode() instance, but got int',) +! d.update(Mapping({"abcG" : {u"\0" : 1}})):TypeError:('expected string without null bytes',) +! d.update(Mapping({"abcG" : {"\0" : 1}})):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using d.update(Mapping({"abcG" : Mapping({%s : 1})})) +! d.update(Mapping({"abcG" : Mapping({1 : 1})})):TypeError:('expected str() or unicode() instance, but got int',) +! d.update(Mapping({"abcG" : Mapping({u"\0" : 1})})):TypeError:('expected string without null bytes',) +! d.update(Mapping({"abcG" : Mapping({"\0" : 1})})):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using d.update(Mapping({"abcG" : %s})) +! d.update(Mapping({"abcG" : FailingIter()})):TypeError:('unable to convert FailingIter to vim structure',) +! d.update(Mapping({"abcG" : FailingIterNext()})):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update(Mapping({"abcG" : %s})) +! d.update(Mapping({"abcG" : None})):TypeError:('unable to convert NoneType to vim structure',) +! d.update(Mapping({"abcG" : {"": 1}})):ValueError:('empty keys are not allowed',) +! d.update(Mapping({"abcG" : {u"": 1}})):ValueError:('empty keys are not allowed',) +! d.update(Mapping({"abcG" : FailingMapping()})):NotImplementedError:() +! d.update(Mapping({"abcG" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d.update(%s) + d.update(FailingIter()):NotImplementedError:() +*************** +*** 622,673 **** + d.update((("a", {u"\0" : 1}),)):TypeError:('expected string without null bytes',) + d.update((("a", {"\0" : 1}),)):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using d.update((("a", {"abc" : {%s : 1}}),)) +! d.update((("a", {"abc" : {1 : 1}}),)):TypeError:('expected str() or unicode() instance, but got int',) +! d.update((("a", {"abc" : {u"\0" : 1}}),)):TypeError:('expected string without null bytes',) +! d.update((("a", {"abc" : {"\0" : 1}}),)):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", {"abc" : Mapping({%s : 1})}),)) +! d.update((("a", {"abc" : Mapping({1 : 1})}),)):TypeError:('expected str() or unicode() instance, but got int',) +! d.update((("a", {"abc" : Mapping({u"\0" : 1})}),)):TypeError:('expected string without null bytes',) +! d.update((("a", {"abc" : Mapping({"\0" : 1})}),)):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : FailingIter()}),)):TypeError:('unable to convert FailingIter to vim structure',) +! d.update((("a", {"abc" : FailingIterNext()}),)):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : None}),)):TypeError:('unable to convert NoneType to vim structure',) +! d.update((("a", {"abc" : {"": 1}}),)):ValueError:('empty keys are not allowed',) +! d.update((("a", {"abc" : {u"": 1}}),)):ValueError:('empty keys are not allowed',) +! d.update((("a", {"abc" : FailingMapping()}),)):NotImplementedError:() +! d.update((("a", {"abc" : FailingMappingKey()}),)):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) + d.update((("a", Mapping({1 : 1})),)):TypeError:('expected str() or unicode() instance, but got int',) + d.update((("a", Mapping({u"\0" : 1})),)):TypeError:('expected string without null bytes',) + d.update((("a", Mapping({"\0" : 1})),)):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using d.update((("a", Mapping({"abc" : {%s : 1}})),)) +! d.update((("a", Mapping({"abc" : {1 : 1}})),)):TypeError:('expected str() or unicode() instance, but got int',) +! d.update((("a", Mapping({"abc" : {u"\0" : 1}})),)):TypeError:('expected string without null bytes',) +! d.update((("a", Mapping({"abc" : {"\0" : 1}})),)):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", Mapping({"abc" : Mapping({%s : 1})})),)) +! d.update((("a", Mapping({"abc" : Mapping({1 : 1})})),)):TypeError:('expected str() or unicode() instance, but got int',) +! d.update((("a", Mapping({"abc" : Mapping({u"\0" : 1})})),)):TypeError:('expected string without null bytes',) +! d.update((("a", Mapping({"abc" : Mapping({"\0" : 1})})),)):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : FailingIter()})),)):TypeError:('unable to convert FailingIter to vim structure',) +! d.update((("a", Mapping({"abc" : FailingIterNext()})),)):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : None})),)):TypeError:('unable to convert NoneType to vim structure',) +! d.update((("a", Mapping({"abc" : {"": 1}})),)):ValueError:('empty keys are not allowed',) +! d.update((("a", Mapping({"abc" : {u"": 1}})),)):ValueError:('empty keys are not allowed',) +! d.update((("a", Mapping({"abc" : FailingMapping()})),)):NotImplementedError:() +! d.update((("a", Mapping({"abc" : FailingMappingKey()})),)):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d.update((("a", %s),)) + d.update((("a", FailingIter()),)):TypeError:('unable to convert FailingIter to vim structure',) +--- 625,676 ---- + d.update((("a", {u"\0" : 1}),)):TypeError:('expected string without null bytes',) + d.update((("a", {"\0" : 1}),)):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using d.update((("a", {"abcF" : {%s : 1}}),)) +! d.update((("a", {"abcF" : {1 : 1}}),)):TypeError:('expected str() or unicode() instance, but got int',) +! d.update((("a", {"abcF" : {u"\0" : 1}}),)):TypeError:('expected string without null bytes',) +! d.update((("a", {"abcF" : {"\0" : 1}}),)):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", {"abcF" : Mapping({%s : 1})}),)) +! d.update((("a", {"abcF" : Mapping({1 : 1})}),)):TypeError:('expected str() or unicode() instance, but got int',) +! d.update((("a", {"abcF" : Mapping({u"\0" : 1})}),)):TypeError:('expected string without null bytes',) +! d.update((("a", {"abcF" : Mapping({"\0" : 1})}),)):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using d.update((("a", {"abcF" : %s}),)) +! d.update((("a", {"abcF" : FailingIter()}),)):TypeError:('unable to convert FailingIter to vim structure',) +! d.update((("a", {"abcF" : FailingIterNext()}),)):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update((("a", {"abcF" : %s}),)) +! d.update((("a", {"abcF" : None}),)):TypeError:('unable to convert NoneType to vim structure',) +! d.update((("a", {"abcF" : {"": 1}}),)):ValueError:('empty keys are not allowed',) +! d.update((("a", {"abcF" : {u"": 1}}),)):ValueError:('empty keys are not allowed',) +! d.update((("a", {"abcF" : FailingMapping()}),)):NotImplementedError:() +! d.update((("a", {"abcF" : FailingMappingKey()}),)):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) + d.update((("a", Mapping({1 : 1})),)):TypeError:('expected str() or unicode() instance, but got int',) + d.update((("a", Mapping({u"\0" : 1})),)):TypeError:('expected string without null bytes',) + d.update((("a", Mapping({"\0" : 1})),)):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using d.update((("a", Mapping({"abcG" : {%s : 1}})),)) +! d.update((("a", Mapping({"abcG" : {1 : 1}})),)):TypeError:('expected str() or unicode() instance, but got int',) +! d.update((("a", Mapping({"abcG" : {u"\0" : 1}})),)):TypeError:('expected string without null bytes',) +! d.update((("a", Mapping({"abcG" : {"\0" : 1}})),)):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", Mapping({"abcG" : Mapping({%s : 1})})),)) +! d.update((("a", Mapping({"abcG" : Mapping({1 : 1})})),)):TypeError:('expected str() or unicode() instance, but got int',) +! d.update((("a", Mapping({"abcG" : Mapping({u"\0" : 1})})),)):TypeError:('expected string without null bytes',) +! d.update((("a", Mapping({"abcG" : Mapping({"\0" : 1})})),)):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using d.update((("a", Mapping({"abcG" : %s})),)) +! d.update((("a", Mapping({"abcG" : FailingIter()})),)):TypeError:('unable to convert FailingIter to vim structure',) +! d.update((("a", Mapping({"abcG" : FailingIterNext()})),)):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abcG" : %s})),)) +! d.update((("a", Mapping({"abcG" : None})),)):TypeError:('unable to convert NoneType to vim structure',) +! d.update((("a", Mapping({"abcG" : {"": 1}})),)):ValueError:('empty keys are not allowed',) +! d.update((("a", Mapping({"abcG" : {u"": 1}})),)):ValueError:('empty keys are not allowed',) +! d.update((("a", Mapping({"abcG" : FailingMapping()})),)):NotImplementedError:() +! d.update((("a", Mapping({"abcG" : FailingMappingKey()})),)):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d.update((("a", %s),)) + d.update((("a", FailingIter()),)):TypeError:('unable to convert FailingIter to vim structure',) +*************** +*** 693,744 **** + vim.List([{u"\0" : 1}]):TypeError:('expected string without null bytes',) + vim.List([{"\0" : 1}]):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using vim.List([{"abc" : {%s : 1}}]) +! vim.List([{"abc" : {1 : 1}}]):TypeError:('expected str() or unicode() instance, but got int',) +! vim.List([{"abc" : {u"\0" : 1}}]):TypeError:('expected string without null bytes',) +! vim.List([{"abc" : {"\0" : 1}}]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using vim.List([{"abc" : Mapping({%s : 1})}]) +! vim.List([{"abc" : Mapping({1 : 1})}]):TypeError:('expected str() or unicode() instance, but got int',) +! vim.List([{"abc" : Mapping({u"\0" : 1})}]):TypeError:('expected string without null bytes',) +! vim.List([{"abc" : Mapping({"\0" : 1})}]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : FailingIter()}]):TypeError:('unable to convert FailingIter to vim structure',) +! vim.List([{"abc" : FailingIterNext()}]):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : None}]):TypeError:('unable to convert NoneType to vim structure',) +! vim.List([{"abc" : {"": 1}}]):ValueError:('empty keys are not allowed',) +! vim.List([{"abc" : {u"": 1}}]):ValueError:('empty keys are not allowed',) +! vim.List([{"abc" : FailingMapping()}]):NotImplementedError:() +! vim.List([{"abc" : FailingMappingKey()}]):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) + vim.List([Mapping({1 : 1})]):TypeError:('expected str() or unicode() instance, but got int',) + vim.List([Mapping({u"\0" : 1})]):TypeError:('expected string without null bytes',) + vim.List([Mapping({"\0" : 1})]):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using vim.List([Mapping({"abc" : {%s : 1}})]) +! vim.List([Mapping({"abc" : {1 : 1}})]):TypeError:('expected str() or unicode() instance, but got int',) +! vim.List([Mapping({"abc" : {u"\0" : 1}})]):TypeError:('expected string without null bytes',) +! vim.List([Mapping({"abc" : {"\0" : 1}})]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using vim.List([Mapping({"abc" : Mapping({%s : 1})})]) +! vim.List([Mapping({"abc" : Mapping({1 : 1})})]):TypeError:('expected str() or unicode() instance, but got int',) +! vim.List([Mapping({"abc" : Mapping({u"\0" : 1})})]):TypeError:('expected string without null bytes',) +! vim.List([Mapping({"abc" : Mapping({"\0" : 1})})]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : FailingIter()})]):TypeError:('unable to convert FailingIter to vim structure',) +! vim.List([Mapping({"abc" : FailingIterNext()})]):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : None})]):TypeError:('unable to convert NoneType to vim structure',) +! vim.List([Mapping({"abc" : {"": 1}})]):ValueError:('empty keys are not allowed',) +! vim.List([Mapping({"abc" : {u"": 1}})]):ValueError:('empty keys are not allowed',) +! vim.List([Mapping({"abc" : FailingMapping()})]):NotImplementedError:() +! vim.List([Mapping({"abc" : FailingMappingKey()})]):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using vim.List([%s]) + vim.List([FailingIter()]):TypeError:('unable to convert FailingIter to vim structure',) +--- 696,747 ---- + vim.List([{u"\0" : 1}]):TypeError:('expected string without null bytes',) + vim.List([{"\0" : 1}]):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using vim.List([{"abcF" : {%s : 1}}]) +! vim.List([{"abcF" : {1 : 1}}]):TypeError:('expected str() or unicode() instance, but got int',) +! vim.List([{"abcF" : {u"\0" : 1}}]):TypeError:('expected string without null bytes',) +! vim.List([{"abcF" : {"\0" : 1}}]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using vim.List([{"abcF" : Mapping({%s : 1})}]) +! vim.List([{"abcF" : Mapping({1 : 1})}]):TypeError:('expected str() or unicode() instance, but got int',) +! vim.List([{"abcF" : Mapping({u"\0" : 1})}]):TypeError:('expected string without null bytes',) +! vim.List([{"abcF" : Mapping({"\0" : 1})}]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using vim.List([{"abcF" : %s}]) +! vim.List([{"abcF" : FailingIter()}]):TypeError:('unable to convert FailingIter to vim structure',) +! vim.List([{"abcF" : FailingIterNext()}]):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using vim.List([{"abcF" : %s}]) +! vim.List([{"abcF" : None}]):TypeError:('unable to convert NoneType to vim structure',) +! vim.List([{"abcF" : {"": 1}}]):ValueError:('empty keys are not allowed',) +! vim.List([{"abcF" : {u"": 1}}]):ValueError:('empty keys are not allowed',) +! vim.List([{"abcF" : FailingMapping()}]):NotImplementedError:() +! vim.List([{"abcF" : FailingMappingKey()}]):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) + vim.List([Mapping({1 : 1})]):TypeError:('expected str() or unicode() instance, but got int',) + vim.List([Mapping({u"\0" : 1})]):TypeError:('expected string without null bytes',) + vim.List([Mapping({"\0" : 1})]):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using vim.List([Mapping({"abcG" : {%s : 1}})]) +! vim.List([Mapping({"abcG" : {1 : 1}})]):TypeError:('expected str() or unicode() instance, but got int',) +! vim.List([Mapping({"abcG" : {u"\0" : 1}})]):TypeError:('expected string without null bytes',) +! vim.List([Mapping({"abcG" : {"\0" : 1}})]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using vim.List([Mapping({"abcG" : Mapping({%s : 1})})]) +! vim.List([Mapping({"abcG" : Mapping({1 : 1})})]):TypeError:('expected str() or unicode() instance, but got int',) +! vim.List([Mapping({"abcG" : Mapping({u"\0" : 1})})]):TypeError:('expected string without null bytes',) +! vim.List([Mapping({"abcG" : Mapping({"\0" : 1})})]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using vim.List([Mapping({"abcG" : %s})]) +! vim.List([Mapping({"abcG" : FailingIter()})]):TypeError:('unable to convert FailingIter to vim structure',) +! vim.List([Mapping({"abcG" : FailingIterNext()})]):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using vim.List([Mapping({"abcG" : %s})]) +! vim.List([Mapping({"abcG" : None})]):TypeError:('unable to convert NoneType to vim structure',) +! vim.List([Mapping({"abcG" : {"": 1}})]):ValueError:('empty keys are not allowed',) +! vim.List([Mapping({"abcG" : {u"": 1}})]):ValueError:('empty keys are not allowed',) +! vim.List([Mapping({"abcG" : FailingMapping()})]):NotImplementedError:() +! vim.List([Mapping({"abcG" : FailingMappingKey()})]):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using vim.List([%s]) + vim.List([FailingIter()]):TypeError:('unable to convert FailingIter to vim structure',) +*************** +*** 757,814 **** + ll[1] = 2:error:('list is locked',) + l[1000] = 3:IndexError:('list index out of range',) + >> ListAssSlice +! ll[1:100] = "abc":error:('list is locked',) + >>> Testing StringToChars using l[:] = [{%s : 1}] + l[:] = [{1 : 1}]:TypeError:('expected str() or unicode() instance, but got int',) + l[:] = [{u"\0" : 1}]:TypeError:('expected string without null bytes',) + l[:] = [{"\0" : 1}]:TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using l[:] = [{"abc" : {%s : 1}}] +! l[:] = [{"abc" : {1 : 1}}]:TypeError:('expected str() or unicode() instance, but got int',) +! l[:] = [{"abc" : {u"\0" : 1}}]:TypeError:('expected string without null bytes',) +! l[:] = [{"abc" : {"\0" : 1}}]:TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using l[:] = [{"abc" : Mapping({%s : 1})}] +! l[:] = [{"abc" : Mapping({1 : 1})}]:TypeError:('expected str() or unicode() instance, but got int',) +! l[:] = [{"abc" : Mapping({u"\0" : 1})}]:TypeError:('expected string without null bytes',) +! l[:] = [{"abc" : Mapping({"\0" : 1})}]:TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : FailingIter()}]:TypeError:('unable to convert FailingIter to vim structure',) +! l[:] = [{"abc" : FailingIterNext()}]:NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : None}]:TypeError:('unable to convert NoneType to vim structure',) +! l[:] = [{"abc" : {"": 1}}]:ValueError:('empty keys are not allowed',) +! l[:] = [{"abc" : {u"": 1}}]:ValueError:('empty keys are not allowed',) +! l[:] = [{"abc" : FailingMapping()}]:NotImplementedError:() +! l[:] = [{"abc" : FailingMappingKey()}]:NotImplementedError:() + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] + l[:] = [Mapping({1 : 1})]:TypeError:('expected str() or unicode() instance, but got int',) + l[:] = [Mapping({u"\0" : 1})]:TypeError:('expected string without null bytes',) + l[:] = [Mapping({"\0" : 1})]:TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using l[:] = [Mapping({"abc" : {%s : 1}})] +! l[:] = [Mapping({"abc" : {1 : 1}})]:TypeError:('expected str() or unicode() instance, but got int',) +! l[:] = [Mapping({"abc" : {u"\0" : 1}})]:TypeError:('expected string without null bytes',) +! l[:] = [Mapping({"abc" : {"\0" : 1}})]:TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using l[:] = [Mapping({"abc" : Mapping({%s : 1})})] +! l[:] = [Mapping({"abc" : Mapping({1 : 1})})]:TypeError:('expected str() or unicode() instance, but got int',) +! l[:] = [Mapping({"abc" : Mapping({u"\0" : 1})})]:TypeError:('expected string without null bytes',) +! l[:] = [Mapping({"abc" : Mapping({"\0" : 1})})]:TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : FailingIter()})]:TypeError:('unable to convert FailingIter to vim structure',) +! l[:] = [Mapping({"abc" : FailingIterNext()})]:NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : None})]:TypeError:('unable to convert NoneType to vim structure',) +! l[:] = [Mapping({"abc" : {"": 1}})]:ValueError:('empty keys are not allowed',) +! l[:] = [Mapping({"abc" : {u"": 1}})]:ValueError:('empty keys are not allowed',) +! l[:] = [Mapping({"abc" : FailingMapping()})]:NotImplementedError:() +! l[:] = [Mapping({"abc" : FailingMappingKey()})]:NotImplementedError:() + <<< Finished + >>> Testing *Iter* using l[:] = [%s] + l[:] = [FailingIter()]:TypeError:('unable to convert FailingIter to vim structure',) +--- 760,817 ---- + ll[1] = 2:error:('list is locked',) + l[1000] = 3:IndexError:('list index out of range',) + >> ListAssSlice +! ll[1:100] = "abcJ":error:('list is locked',) + >>> Testing StringToChars using l[:] = [{%s : 1}] + l[:] = [{1 : 1}]:TypeError:('expected str() or unicode() instance, but got int',) + l[:] = [{u"\0" : 1}]:TypeError:('expected string without null bytes',) + l[:] = [{"\0" : 1}]:TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using l[:] = [{"abcF" : {%s : 1}}] +! l[:] = [{"abcF" : {1 : 1}}]:TypeError:('expected str() or unicode() instance, but got int',) +! l[:] = [{"abcF" : {u"\0" : 1}}]:TypeError:('expected string without null bytes',) +! l[:] = [{"abcF" : {"\0" : 1}}]:TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using l[:] = [{"abcF" : Mapping({%s : 1})}] +! l[:] = [{"abcF" : Mapping({1 : 1})}]:TypeError:('expected str() or unicode() instance, but got int',) +! l[:] = [{"abcF" : Mapping({u"\0" : 1})}]:TypeError:('expected string without null bytes',) +! l[:] = [{"abcF" : Mapping({"\0" : 1})}]:TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using l[:] = [{"abcF" : %s}] +! l[:] = [{"abcF" : FailingIter()}]:TypeError:('unable to convert FailingIter to vim structure',) +! l[:] = [{"abcF" : FailingIterNext()}]:NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using l[:] = [{"abcF" : %s}] +! l[:] = [{"abcF" : None}]:TypeError:('unable to convert NoneType to vim structure',) +! l[:] = [{"abcF" : {"": 1}}]:ValueError:('empty keys are not allowed',) +! l[:] = [{"abcF" : {u"": 1}}]:ValueError:('empty keys are not allowed',) +! l[:] = [{"abcF" : FailingMapping()}]:NotImplementedError:() +! l[:] = [{"abcF" : FailingMappingKey()}]:NotImplementedError:() + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] + l[:] = [Mapping({1 : 1})]:TypeError:('expected str() or unicode() instance, but got int',) + l[:] = [Mapping({u"\0" : 1})]:TypeError:('expected string without null bytes',) + l[:] = [Mapping({"\0" : 1})]:TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using l[:] = [Mapping({"abcG" : {%s : 1}})] +! l[:] = [Mapping({"abcG" : {1 : 1}})]:TypeError:('expected str() or unicode() instance, but got int',) +! l[:] = [Mapping({"abcG" : {u"\0" : 1}})]:TypeError:('expected string without null bytes',) +! l[:] = [Mapping({"abcG" : {"\0" : 1}})]:TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using l[:] = [Mapping({"abcG" : Mapping({%s : 1})})] +! l[:] = [Mapping({"abcG" : Mapping({1 : 1})})]:TypeError:('expected str() or unicode() instance, but got int',) +! l[:] = [Mapping({"abcG" : Mapping({u"\0" : 1})})]:TypeError:('expected string without null bytes',) +! l[:] = [Mapping({"abcG" : Mapping({"\0" : 1})})]:TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using l[:] = [Mapping({"abcG" : %s})] +! l[:] = [Mapping({"abcG" : FailingIter()})]:TypeError:('unable to convert FailingIter to vim structure',) +! l[:] = [Mapping({"abcG" : FailingIterNext()})]:NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abcG" : %s})] +! l[:] = [Mapping({"abcG" : None})]:TypeError:('unable to convert NoneType to vim structure',) +! l[:] = [Mapping({"abcG" : {"": 1}})]:ValueError:('empty keys are not allowed',) +! l[:] = [Mapping({"abcG" : {u"": 1}})]:ValueError:('empty keys are not allowed',) +! l[:] = [Mapping({"abcG" : FailingMapping()})]:NotImplementedError:() +! l[:] = [Mapping({"abcG" : FailingMappingKey()})]:NotImplementedError:() + <<< Finished + >>> Testing *Iter* using l[:] = [%s] + l[:] = [FailingIter()]:TypeError:('unable to convert FailingIter to vim structure',) +*************** +*** 827,878 **** + l.extend([{u"\0" : 1}]):TypeError:('expected string without null bytes',) + l.extend([{"\0" : 1}]):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using l.extend([{"abc" : {%s : 1}}]) +! l.extend([{"abc" : {1 : 1}}]):TypeError:('expected str() or unicode() instance, but got int',) +! l.extend([{"abc" : {u"\0" : 1}}]):TypeError:('expected string without null bytes',) +! l.extend([{"abc" : {"\0" : 1}}]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using l.extend([{"abc" : Mapping({%s : 1})}]) +! l.extend([{"abc" : Mapping({1 : 1})}]):TypeError:('expected str() or unicode() instance, but got int',) +! l.extend([{"abc" : Mapping({u"\0" : 1})}]):TypeError:('expected string without null bytes',) +! l.extend([{"abc" : Mapping({"\0" : 1})}]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : FailingIter()}]):TypeError:('unable to convert FailingIter to vim structure',) +! l.extend([{"abc" : FailingIterNext()}]):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : None}]):TypeError:('unable to convert NoneType to vim structure',) +! l.extend([{"abc" : {"": 1}}]):ValueError:('empty keys are not allowed',) +! l.extend([{"abc" : {u"": 1}}]):ValueError:('empty keys are not allowed',) +! l.extend([{"abc" : FailingMapping()}]):NotImplementedError:() +! l.extend([{"abc" : FailingMappingKey()}]):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) + l.extend([Mapping({1 : 1})]):TypeError:('expected str() or unicode() instance, but got int',) + l.extend([Mapping({u"\0" : 1})]):TypeError:('expected string without null bytes',) + l.extend([Mapping({"\0" : 1})]):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using l.extend([Mapping({"abc" : {%s : 1}})]) +! l.extend([Mapping({"abc" : {1 : 1}})]):TypeError:('expected str() or unicode() instance, but got int',) +! l.extend([Mapping({"abc" : {u"\0" : 1}})]):TypeError:('expected string without null bytes',) +! l.extend([Mapping({"abc" : {"\0" : 1}})]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using l.extend([Mapping({"abc" : Mapping({%s : 1})})]) +! l.extend([Mapping({"abc" : Mapping({1 : 1})})]):TypeError:('expected str() or unicode() instance, but got int',) +! l.extend([Mapping({"abc" : Mapping({u"\0" : 1})})]):TypeError:('expected string without null bytes',) +! l.extend([Mapping({"abc" : Mapping({"\0" : 1})})]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : FailingIter()})]):TypeError:('unable to convert FailingIter to vim structure',) +! l.extend([Mapping({"abc" : FailingIterNext()})]):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : None})]):TypeError:('unable to convert NoneType to vim structure',) +! l.extend([Mapping({"abc" : {"": 1}})]):ValueError:('empty keys are not allowed',) +! l.extend([Mapping({"abc" : {u"": 1}})]):ValueError:('empty keys are not allowed',) +! l.extend([Mapping({"abc" : FailingMapping()})]):NotImplementedError:() +! l.extend([Mapping({"abc" : FailingMappingKey()})]):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using l.extend([%s]) + l.extend([FailingIter()]):TypeError:('unable to convert FailingIter to vim structure',) +--- 830,881 ---- + l.extend([{u"\0" : 1}]):TypeError:('expected string without null bytes',) + l.extend([{"\0" : 1}]):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using l.extend([{"abcF" : {%s : 1}}]) +! l.extend([{"abcF" : {1 : 1}}]):TypeError:('expected str() or unicode() instance, but got int',) +! l.extend([{"abcF" : {u"\0" : 1}}]):TypeError:('expected string without null bytes',) +! l.extend([{"abcF" : {"\0" : 1}}]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using l.extend([{"abcF" : Mapping({%s : 1})}]) +! l.extend([{"abcF" : Mapping({1 : 1})}]):TypeError:('expected str() or unicode() instance, but got int',) +! l.extend([{"abcF" : Mapping({u"\0" : 1})}]):TypeError:('expected string without null bytes',) +! l.extend([{"abcF" : Mapping({"\0" : 1})}]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using l.extend([{"abcF" : %s}]) +! l.extend([{"abcF" : FailingIter()}]):TypeError:('unable to convert FailingIter to vim structure',) +! l.extend([{"abcF" : FailingIterNext()}]):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using l.extend([{"abcF" : %s}]) +! l.extend([{"abcF" : None}]):TypeError:('unable to convert NoneType to vim structure',) +! l.extend([{"abcF" : {"": 1}}]):ValueError:('empty keys are not allowed',) +! l.extend([{"abcF" : {u"": 1}}]):ValueError:('empty keys are not allowed',) +! l.extend([{"abcF" : FailingMapping()}]):NotImplementedError:() +! l.extend([{"abcF" : FailingMappingKey()}]):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) + l.extend([Mapping({1 : 1})]):TypeError:('expected str() or unicode() instance, but got int',) + l.extend([Mapping({u"\0" : 1})]):TypeError:('expected string without null bytes',) + l.extend([Mapping({"\0" : 1})]):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using l.extend([Mapping({"abcG" : {%s : 1}})]) +! l.extend([Mapping({"abcG" : {1 : 1}})]):TypeError:('expected str() or unicode() instance, but got int',) +! l.extend([Mapping({"abcG" : {u"\0" : 1}})]):TypeError:('expected string without null bytes',) +! l.extend([Mapping({"abcG" : {"\0" : 1}})]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using l.extend([Mapping({"abcG" : Mapping({%s : 1})})]) +! l.extend([Mapping({"abcG" : Mapping({1 : 1})})]):TypeError:('expected str() or unicode() instance, but got int',) +! l.extend([Mapping({"abcG" : Mapping({u"\0" : 1})})]):TypeError:('expected string without null bytes',) +! l.extend([Mapping({"abcG" : Mapping({"\0" : 1})})]):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using l.extend([Mapping({"abcG" : %s})]) +! l.extend([Mapping({"abcG" : FailingIter()})]):TypeError:('unable to convert FailingIter to vim structure',) +! l.extend([Mapping({"abcG" : FailingIterNext()})]):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using l.extend([Mapping({"abcG" : %s})]) +! l.extend([Mapping({"abcG" : None})]):TypeError:('unable to convert NoneType to vim structure',) +! l.extend([Mapping({"abcG" : {"": 1}})]):ValueError:('empty keys are not allowed',) +! l.extend([Mapping({"abcG" : {u"": 1}})]):ValueError:('empty keys are not allowed',) +! l.extend([Mapping({"abcG" : FailingMapping()})]):NotImplementedError:() +! l.extend([Mapping({"abcG" : FailingMappingKey()})]):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using l.extend([%s]) + l.extend([FailingIter()]):TypeError:('unable to convert FailingIter to vim structure',) +*************** +*** 900,951 **** + f({u"\0" : 1}):TypeError:('expected string without null bytes',) + f({"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using f({"abc" : {%s : 1}}) +! f({"abc" : {1 : 1}}):TypeError:('expected str() or unicode() instance, but got int',) +! f({"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) +! f({"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using f({"abc" : Mapping({%s : 1})}) +! f({"abc" : Mapping({1 : 1})}):TypeError:('expected str() or unicode() instance, but got int',) +! f({"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) +! f({"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using f({"abc" : %s}) +! f({"abc" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! f({"abc" : FailingIterNext()}):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using f({"abc" : %s}) +! f({"abc" : None}):TypeError:('unable to convert NoneType to vim structure',) +! f({"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) +! f({"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! f({"abc" : FailingMapping()}):NotImplementedError:() +! f({"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) + f(Mapping({1 : 1})):TypeError:('expected str() or unicode() instance, but got int',) + f(Mapping({u"\0" : 1})):TypeError:('expected string without null bytes',) + f(Mapping({"\0" : 1})):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using f(Mapping({"abc" : {%s : 1}})) +! f(Mapping({"abc" : {1 : 1}})):TypeError:('expected str() or unicode() instance, but got int',) +! f(Mapping({"abc" : {u"\0" : 1}})):TypeError:('expected string without null bytes',) +! f(Mapping({"abc" : {"\0" : 1}})):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using f(Mapping({"abc" : Mapping({%s : 1})})) +! f(Mapping({"abc" : Mapping({1 : 1})})):TypeError:('expected str() or unicode() instance, but got int',) +! f(Mapping({"abc" : Mapping({u"\0" : 1})})):TypeError:('expected string without null bytes',) +! f(Mapping({"abc" : Mapping({"\0" : 1})})):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : FailingIter()})):TypeError:('unable to convert FailingIter to vim structure',) +! f(Mapping({"abc" : FailingIterNext()})):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : None})):TypeError:('unable to convert NoneType to vim structure',) +! f(Mapping({"abc" : {"": 1}})):ValueError:('empty keys are not allowed',) +! f(Mapping({"abc" : {u"": 1}})):ValueError:('empty keys are not allowed',) +! f(Mapping({"abc" : FailingMapping()})):NotImplementedError:() +! f(Mapping({"abc" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using f(%s) + f(FailingIter()):TypeError:('unable to convert FailingIter to vim structure',) +--- 903,954 ---- + f({u"\0" : 1}):TypeError:('expected string without null bytes',) + f({"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using f({"abcF" : {%s : 1}}) +! f({"abcF" : {1 : 1}}):TypeError:('expected str() or unicode() instance, but got int',) +! f({"abcF" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) +! f({"abcF" : {"\0" : 1}}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using f({"abcF" : Mapping({%s : 1})}) +! f({"abcF" : Mapping({1 : 1})}):TypeError:('expected str() or unicode() instance, but got int',) +! f({"abcF" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) +! f({"abcF" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using f({"abcF" : %s}) +! f({"abcF" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! f({"abcF" : FailingIterNext()}):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using f({"abcF" : %s}) +! f({"abcF" : None}):TypeError:('unable to convert NoneType to vim structure',) +! f({"abcF" : {"": 1}}):ValueError:('empty keys are not allowed',) +! f({"abcF" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! f({"abcF" : FailingMapping()}):NotImplementedError:() +! f({"abcF" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) + f(Mapping({1 : 1})):TypeError:('expected str() or unicode() instance, but got int',) + f(Mapping({u"\0" : 1})):TypeError:('expected string without null bytes',) + f(Mapping({"\0" : 1})):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using f(Mapping({"abcG" : {%s : 1}})) +! f(Mapping({"abcG" : {1 : 1}})):TypeError:('expected str() or unicode() instance, but got int',) +! f(Mapping({"abcG" : {u"\0" : 1}})):TypeError:('expected string without null bytes',) +! f(Mapping({"abcG" : {"\0" : 1}})):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using f(Mapping({"abcG" : Mapping({%s : 1})})) +! f(Mapping({"abcG" : Mapping({1 : 1})})):TypeError:('expected str() or unicode() instance, but got int',) +! f(Mapping({"abcG" : Mapping({u"\0" : 1})})):TypeError:('expected string without null bytes',) +! f(Mapping({"abcG" : Mapping({"\0" : 1})})):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using f(Mapping({"abcG" : %s})) +! f(Mapping({"abcG" : FailingIter()})):TypeError:('unable to convert FailingIter to vim structure',) +! f(Mapping({"abcG" : FailingIterNext()})):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using f(Mapping({"abcG" : %s})) +! f(Mapping({"abcG" : None})):TypeError:('unable to convert NoneType to vim structure',) +! f(Mapping({"abcG" : {"": 1}})):ValueError:('empty keys are not allowed',) +! f(Mapping({"abcG" : {u"": 1}})):ValueError:('empty keys are not allowed',) +! f(Mapping({"abcG" : FailingMapping()})):NotImplementedError:() +! f(Mapping({"abcG" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using f(%s) + f(FailingIter()):TypeError:('unable to convert FailingIter to vim structure',) +*************** +*** 963,1014 **** + fd(self={u"\0" : 1}):TypeError:('expected string without null bytes',) + fd(self={"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using fd(self={"abc" : {%s : 1}}) +! fd(self={"abc" : {1 : 1}}):TypeError:('expected str() or unicode() instance, but got int',) +! fd(self={"abc" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) +! fd(self={"abc" : {"\0" : 1}}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using fd(self={"abc" : Mapping({%s : 1})}) +! fd(self={"abc" : Mapping({1 : 1})}):TypeError:('expected str() or unicode() instance, but got int',) +! fd(self={"abc" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) +! fd(self={"abc" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using fd(self={"abc" : %s}) +! fd(self={"abc" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! fd(self={"abc" : FailingIterNext()}):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using fd(self={"abc" : %s}) +! fd(self={"abc" : None}):TypeError:('unable to convert NoneType to vim structure',) +! fd(self={"abc" : {"": 1}}):ValueError:('empty keys are not allowed',) +! fd(self={"abc" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! fd(self={"abc" : FailingMapping()}):NotImplementedError:() +! fd(self={"abc" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) + fd(self=Mapping({1 : 1})):TypeError:('expected str() or unicode() instance, but got int',) + fd(self=Mapping({u"\0" : 1})):TypeError:('expected string without null bytes',) + fd(self=Mapping({"\0" : 1})):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using fd(self=Mapping({"abc" : {%s : 1}})) +! fd(self=Mapping({"abc" : {1 : 1}})):TypeError:('expected str() or unicode() instance, but got int',) +! fd(self=Mapping({"abc" : {u"\0" : 1}})):TypeError:('expected string without null bytes',) +! fd(self=Mapping({"abc" : {"\0" : 1}})):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using fd(self=Mapping({"abc" : Mapping({%s : 1})})) +! fd(self=Mapping({"abc" : Mapping({1 : 1})})):TypeError:('expected str() or unicode() instance, but got int',) +! fd(self=Mapping({"abc" : Mapping({u"\0" : 1})})):TypeError:('expected string without null bytes',) +! fd(self=Mapping({"abc" : Mapping({"\0" : 1})})):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : FailingIter()})):TypeError:('unable to convert FailingIter to vim structure',) +! fd(self=Mapping({"abc" : FailingIterNext()})):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : None})):TypeError:('unable to convert NoneType to vim structure',) +! fd(self=Mapping({"abc" : {"": 1}})):ValueError:('empty keys are not allowed',) +! fd(self=Mapping({"abc" : {u"": 1}})):ValueError:('empty keys are not allowed',) +! fd(self=Mapping({"abc" : FailingMapping()})):NotImplementedError:() +! fd(self=Mapping({"abc" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using fd(self=%s) + fd(self=FailingIter()):TypeError:('unable to convert FailingIter to vim dictionary',) +--- 966,1017 ---- + fd(self={u"\0" : 1}):TypeError:('expected string without null bytes',) + fd(self={"\0" : 1}):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using fd(self={"abcF" : {%s : 1}}) +! fd(self={"abcF" : {1 : 1}}):TypeError:('expected str() or unicode() instance, but got int',) +! fd(self={"abcF" : {u"\0" : 1}}):TypeError:('expected string without null bytes',) +! fd(self={"abcF" : {"\0" : 1}}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using fd(self={"abcF" : Mapping({%s : 1})}) +! fd(self={"abcF" : Mapping({1 : 1})}):TypeError:('expected str() or unicode() instance, but got int',) +! fd(self={"abcF" : Mapping({u"\0" : 1})}):TypeError:('expected string without null bytes',) +! fd(self={"abcF" : Mapping({"\0" : 1})}):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using fd(self={"abcF" : %s}) +! fd(self={"abcF" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! fd(self={"abcF" : FailingIterNext()}):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using fd(self={"abcF" : %s}) +! fd(self={"abcF" : None}):TypeError:('unable to convert NoneType to vim structure',) +! fd(self={"abcF" : {"": 1}}):ValueError:('empty keys are not allowed',) +! fd(self={"abcF" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! fd(self={"abcF" : FailingMapping()}):NotImplementedError:() +! fd(self={"abcF" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) + fd(self=Mapping({1 : 1})):TypeError:('expected str() or unicode() instance, but got int',) + fd(self=Mapping({u"\0" : 1})):TypeError:('expected string without null bytes',) + fd(self=Mapping({"\0" : 1})):TypeError:('expected string without null bytes',) + <<< Finished +! >>> Testing StringToChars using fd(self=Mapping({"abcG" : {%s : 1}})) +! fd(self=Mapping({"abcG" : {1 : 1}})):TypeError:('expected str() or unicode() instance, but got int',) +! fd(self=Mapping({"abcG" : {u"\0" : 1}})):TypeError:('expected string without null bytes',) +! fd(self=Mapping({"abcG" : {"\0" : 1}})):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing StringToChars using fd(self=Mapping({"abcG" : Mapping({%s : 1})})) +! fd(self=Mapping({"abcG" : Mapping({1 : 1})})):TypeError:('expected str() or unicode() instance, but got int',) +! fd(self=Mapping({"abcG" : Mapping({u"\0" : 1})})):TypeError:('expected string without null bytes',) +! fd(self=Mapping({"abcG" : Mapping({"\0" : 1})})):TypeError:('expected string without null bytes',) +! <<< Finished +! >>> Testing *Iter* using fd(self=Mapping({"abcG" : %s})) +! fd(self=Mapping({"abcG" : FailingIter()})):TypeError:('unable to convert FailingIter to vim structure',) +! fd(self=Mapping({"abcG" : FailingIterNext()})):NotImplementedError:() +! <<< Finished +! >>> Testing ConvertFromPyObject using fd(self=Mapping({"abcG" : %s})) +! fd(self=Mapping({"abcG" : None})):TypeError:('unable to convert NoneType to vim structure',) +! fd(self=Mapping({"abcG" : {"": 1}})):ValueError:('empty keys are not allowed',) +! fd(self=Mapping({"abcG" : {u"": 1}})):ValueError:('empty keys are not allowed',) +! fd(self=Mapping({"abcG" : FailingMapping()})):NotImplementedError:() +! fd(self=Mapping({"abcG" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using fd(self=%s) + fd(self=FailingIter()):TypeError:('unable to convert FailingIter to vim dictionary',) +*************** +*** 1037,1044 **** + vim.current.window.buffer = 0:TypeError:('readonly attribute: buffer',) + vim.current.window.cursor = (100000000, 100000000):error:('cursor position outside buffer',) + vim.current.window.cursor = True:TypeError:('argument must be 2-item sequence, not bool',) +! vim.current.window.height = "abc":TypeError:('expected int(), long() or something supporting coercing to long(), but got str',) +! vim.current.window.width = "abc":TypeError:('expected int(), long() or something supporting coercing to long(), but got str',) + vim.current.window.xxxxxx = True:AttributeError:('xxxxxx',) + > WinList + >> WinListItem +--- 1040,1047 ---- + vim.current.window.buffer = 0:TypeError:('readonly attribute: buffer',) + vim.current.window.cursor = (100000000, 100000000):error:('cursor position outside buffer',) + vim.current.window.cursor = True:TypeError:('argument must be 2-item sequence, not bool',) +! vim.current.window.height = "abcK":TypeError:('expected int(), long() or something supporting coercing to long(), but got str',) +! vim.current.window.width = "abcL":TypeError:('expected int(), long() or something supporting coercing to long(), but got str',) + vim.current.window.xxxxxx = True:AttributeError:('xxxxxx',) + > WinList + >> WinListItem +*************** +*** 1048,1054 **** + vim.current.buffer[0] = "\na":error:('string cannot contain newlines',) + >> SetBufferLine (indirect) + vim.current.buffer[0] = True:TypeError:('bad argument type for built-in operation',) +! >> SetBufferLines (indirect) + vim.current.buffer[:] = True:TypeError:('bad argument type for built-in operation',) + vim.current.buffer[:] = ["\na", "bc"]:error:('string cannot contain newlines',) + >> InsertBufferLines (indirect) +--- 1051,1057 ---- + vim.current.buffer[0] = "\na":error:('string cannot contain newlines',) + >> SetBufferLine (indirect) + vim.current.buffer[0] = True:TypeError:('bad argument type for built-in operation',) +! >> SetBufferLineList (indirect) + vim.current.buffer[:] = True:TypeError:('bad argument type for built-in operation',) + vim.current.buffer[:] = ["\na", "bc"]:error:('string cannot contain newlines',) + >> InsertBufferLines (indirect) +*************** +*** 1066,1072 **** + vim.current.buffer.xxx = True:AttributeError:('xxx',) + >> BufferMark + vim.current.buffer.mark(0):TypeError:('expected str() or unicode() instance, but got int',) +! vim.current.buffer.mark("abc"):ValueError:('mark name must be a single character',) + vim.current.buffer.mark("!"):error:('invalid mark name',) + >> BufferRange + vim.current.buffer.range(1, 2, 3):TypeError:('function takes exactly 2 arguments (3 given)',) +--- 1069,1075 ---- + vim.current.buffer.xxx = True:AttributeError:('xxx',) + >> BufferMark + vim.current.buffer.mark(0):TypeError:('expected str() or unicode() instance, but got int',) +! vim.current.buffer.mark("abcM"):ValueError:('mark name must be a single character',) + vim.current.buffer.mark("!"):error:('invalid mark name',) + >> BufferRange + vim.current.buffer.range(1, 2, 3):TypeError:('function takes exactly 2 arguments (3 given)',) +*************** +*** 1086,1092 **** + 2,xx + before + after +! vim.command("throw 'abc'"):error:('abc',) + Exe("throw 'def'"):error:('def',) + vim.eval("Exe('throw ''ghi''')"):error:('ghi',) + vim.eval("Exe('echoerr ''jkl''')"):error:('Vim(echoerr):jkl',) +--- 1089,1095 ---- + 2,xx + before + after +! vim.command("throw 'abcN'"):error:('abcN',) + Exe("throw 'def'"):error:('def',) + vim.eval("Exe('throw ''ghi''')"):error:('ghi',) + vim.eval("Exe('echoerr ''jkl''')"):error:('Vim(echoerr):jkl',) +*** ../vim-7.3.1232/src/testdir/test87.in 2013-06-12 14:20:15.000000000 +0200 +--- src/testdir/test87.in 2013-06-23 14:34:17.000000000 +0200 +*************** +*** 5,12 **** + :set noswapfile + :if !has('python3') | e! test.ok | wq! test.out | endif + :lang C +- :py3 import vim + :fun Test() + :let l = [] + :py3 l=vim.bindeval('l') + :py3 f=vim.bindeval('function("strlen")') +--- 5,12 ---- + :set noswapfile + :if !has('python3') | e! test.ok | wq! test.out | endif + :lang C + :fun Test() ++ :py3 import vim + :let l = [] + :py3 l=vim.bindeval('l') + :py3 f=vim.bindeval('function("strlen")') +*************** +*** 51,56 **** +--- 51,59 ---- + : $put =string(key) . ' : ' . string(Val) + : unlet key Val + :endfor ++ :py3 del dk ++ :py3 del di ++ :py3 del dv + :" + :" removing items with del + :py3 del l[2] +*************** +*** 169,180 **** + :unlockvar! l + :" + :" Function calls +! :function New(...) +! :return ['NewStart']+a:000+['NewEnd'] +! :endfunction +! :function DictNew(...) dict +! :return ['DictNewStart']+a:000+['DictNewEnd', self] +! :endfunction + :let l=[function('New'), function('DictNew')] + :py3 l=vim.bindeval('l') + :py3 l.extend(list(l[0](1, 2, 3))) +--- 172,183 ---- + :unlockvar! l + :" + :" Function calls +! :fun New(...) +! : return ['NewStart']+a:000+['NewEnd'] +! :endfun +! :fun DictNew(...) dict +! : return ['DictNewStart']+a:000+['DictNewEnd', self] +! :endfun + :let l=[function('New'), function('DictNew')] + :py3 l=vim.bindeval('l') + :py3 l.extend(list(l[0](1, 2, 3))) +*************** +*** 204,210 **** + : $put ='[0.0, 0.0]' + :endif + :let messages=[] +! :py3 < 8 # check if the background thread is working ++ :py3 del time ++ :py3 del threading + :$put =string(l) + :" + :" settrace +*************** +*** 326,337 **** + EOF + :py3 sys.settrace(traceit) + :py3 trace_main() + :py3 sys.settrace(None) + :$put =string(l) + :" + :" Vars + :let g:foo = 'bac' +! :let w:abc = 'def' + :let b:baz = 'bar' + :let t:bar = 'jkl' + :try +--- 335,348 ---- + EOF + :py3 sys.settrace(traceit) + :py3 trace_main() ++ :py3 del traceit ++ :py3 del trace_main + :py3 sys.settrace(None) + :$put =string(l) + :" + :" Vars + :let g:foo = 'bac' +! :let w:abc3 = 'def' + :let b:baz = 'bar' + :let t:bar = 'jkl' + :try +*************** +*** 340,346 **** + : put =py3eval('vim.vvars[''exception'']') + :endtry + :put =py3eval('vim.vars[''foo'']') +! :put =py3eval('vim.current.window.vars[''abc'']') + :put =py3eval('vim.current.buffer.vars[''baz'']') + :put =py3eval('vim.current.tabpage.vars[''bar'']') + :" +--- 351,357 ---- + : put =py3eval('vim.vvars[''exception'']') + :endtry + :put =py3eval('vim.vars[''foo'']') +! :put =py3eval('vim.current.window.vars[''abc3'']') + :put =py3eval('vim.current.buffer.vars[''baz'']') + :put =py3eval('vim.current.tabpage.vars[''bar'']') + :" +*************** +*** 388,403 **** + vim.command('let exc=' + repr(e.__class__.__name__)) + return 0 + EOF +! :function E(s) + : python3 e(vim.eval('a:s')) +! :endfunction +! :function Ev(s) + : let r=py3eval('ev(vim.eval("a:s"))') + : if exists('exc') + : throw exc + : endif + : return r +! :endfunction + :py3 gopts1=vim.options + :py3 wopts1=vim.windows[2].options + :py3 wopts2=vim.windows[0].options +--- 399,414 ---- + vim.command('let exc=' + repr(e.__class__.__name__)) + return 0 + EOF +! :fun E(s) + : python3 e(vim.eval('a:s')) +! :endfun +! :fun Ev(s) + : let r=py3eval('ev(vim.eval("a:s"))') + : if exists('exc') + : throw exc + : endif + : return r +! :endfun + :py3 gopts1=vim.options + :py3 wopts1=vim.windows[2].options + :py3 wopts2=vim.windows[0].options +*************** +*** 412,418 **** + :let lst+=[['operatorfunc', 'A', 'B', 'C', 2, 0, 1, 0 ]] + :let lst+=[['number', 0, 1, 1, 0, 1, 0, 1 ]] + :let lst+=[['numberwidth', 2, 3, 5, -100, 0, 0, 1 ]] +! :let lst+=[['colorcolumn', '+1', '+2', '+3', 'abc', 0, 0, 1 ]] + :let lst+=[['statusline', '1', '2', '4', 0, 0, 1, 1 ]] + :let lst+=[['autoindent', 0, 1, 1, 2, 1, 0, 2 ]] + :let lst+=[['shiftwidth', 0, 2, 1, 3, 0, 0, 2 ]] +--- 423,429 ---- + :let lst+=[['operatorfunc', 'A', 'B', 'C', 2, 0, 1, 0 ]] + :let lst+=[['number', 0, 1, 1, 0, 1, 0, 1 ]] + :let lst+=[['numberwidth', 2, 3, 5, -100, 0, 0, 1 ]] +! :let lst+=[['colorcolumn', '+1', '+2', '+3', 'abc4', 0, 0, 1 ]] + :let lst+=[['statusline', '1', '2', '4', 0, 0, 1, 1 ]] + :let lst+=[['autoindent', 0, 1, 1, 2, 1, 0, 2 ]] + :let lst+=[['shiftwidth', 0, 2, 1, 3, 0, 0, 2 ]] +*************** +*** 462,471 **** +--- 473,499 ---- + : endfor + : call RecVars(oname) + :endfor ++ :delfunction RecVars ++ :delfunction E ++ :delfunction Ev ++ :py3 del ev ++ :py3 del e + :only + :for buf in g:bufs[1:] + : execute 'bwipeout!' buf + :endfor ++ :py3 del gopts1 ++ :py3 del wopts1 ++ :py3 del wopts2 ++ :py3 del wopts3 ++ :py3 del bopts1 ++ :py3 del bopts2 ++ :py3 del bopts3 ++ :py3 del oval1 ++ :py3 del oval2 ++ :py3 del oval3 ++ :py3 del oname ++ :py3 del invval + :" + :" Test buffer object + :vnew +*************** +*** 485,491 **** + # Tests BufferAppend and BufferItem + cb.append(b[0]) + # Tests BufferSlice and BufferAssSlice +! cb.append('abc') # Will be overwritten + cb[-1:] = b[:-2] + # Test BufferLength and BufferAssSlice + cb.append('def') # Will not be overwritten +--- 513,519 ---- + # Tests BufferAppend and BufferItem + cb.append(b[0]) + # Tests BufferSlice and BufferAssSlice +! cb.append('abc5') # Will be overwritten + cb[-1:] = b[:-2] + # Test BufferLength and BufferAssSlice + cb.append('def') # Will not be overwritten +*************** +*** 509,521 **** + cb.append(b.name[-11:].replace(os.path.sep, '/')) + cb.name = old_name + cb.append(cb.name[-17:].replace(os.path.sep, '/')) + # Test CheckBuffer + for _b in vim.buffers: + if _b is not cb: + vim.command('bwipeout! ' + str(_b.number)) + del _b + cb.append('valid: b:%s, cb:%s' % (repr(b.valid), repr(cb.valid))) +! for expr in ('b[1]','b[:] = ["A", "B"]','b[:]','b.append("abc")'): + try: + exec(expr) + except vim.error: +--- 537,550 ---- + cb.append(b.name[-11:].replace(os.path.sep, '/')) + cb.name = old_name + cb.append(cb.name[-17:].replace(os.path.sep, '/')) ++ del old_name + # Test CheckBuffer + for _b in vim.buffers: + if _b is not cb: + vim.command('bwipeout! ' + str(_b.number)) + del _b + cb.append('valid: b:%s, cb:%s' % (repr(b.valid), repr(cb.valid))) +! for expr in ('b[1]','b[:] = ["A", "B"]','b[:]','b.append("abc6")'): + try: + exec(expr) + except vim.error: +*************** +*** 525,530 **** +--- 554,560 ---- + # Should not happen in any case + cb.append('No exception for ' + expr) + vim.command('cd .') ++ del b + EOF + :" + :" Test vim.buffers object +*************** +*** 558,563 **** +--- 588,594 ---- + # Check indexing: vim.buffers[number].number == number + cb.append(str(b.number) + ':' + repr(vim.buffers[b.number]) + '=' + repr(b)) + prevnum = b.number ++ del prevnum + + cb.append(str(len(vim.buffers))) + +*************** +*** 581,586 **** +--- 612,619 ---- + next(i4) + except StopIteration: + cb.append('StopIteration') ++ del i4 ++ del bnums + EOF + :" + :" Test vim.{tabpage,window}list and vim.{tabpage,window} objects +*************** +*** 622,628 **** +--- 655,665 ---- + raise ValueError + except Exception as e: + cb.append('!!!!!! Error while getting attribute ' + attr + ': ' + e.__class__.__name__) ++ del aval ++ del attr + w.cursor = (len(w.buffer), 0) ++ del W ++ del Cursor + cb.append('Number of windows in current tab page: ' + str(len(vim.windows))) + if list(vim.windows) != list(vim.current.tabpage.windows): + cb.append('!!!!!! Windows differ') +*************** +*** 635,640 **** +--- 672,678 ---- + cb.append('Current tab page: ' + repr(vim.current.tabpage)) + cb.append('Current window: ' + repr(vim.current.window) + ': ' + H(vim.current.window) + ' is ' + H(vim.current.tabpage.window)) + cb.append('Current buffer: ' + repr(vim.current.buffer) + ': ' + H(vim.current.buffer) + ' is ' + H(vim.current.window.buffer)+ ' is ' + H(vim.current.tabpage.window.buffer)) ++ del H + # Assigning: fails + try: + vim.current.window = vim.tabpages[0].window +*************** +*** 646,651 **** +--- 684,690 ---- + setattr(vim.current, attr, None) + except TypeError: + cb.append('Type error at assigning None to vim.current.' + attr) ++ del attr + + # Assigning: success + vim.current.tabpage = vim.tabpages[-2] +*************** +*** 661,668 **** +--- 700,712 ---- + for b in vim.buffers: + if b is not cb: + vim.command('bwipeout! ' + str(b.number)) ++ del b + cb.append('w.valid: ' + repr([w.valid for w in ws])) + cb.append('t.valid: ' + repr([t.valid for t in ts])) ++ del w ++ del t ++ del ts ++ del ws + EOF + :tabonly! + :only! +*************** +*** 681,686 **** +--- 725,732 ---- + ('vim.current.tabpage', 'TabPage'), + ): + cb.append(expr + ':' + attr + ':' + repr(type(eval(expr)) is getattr(vim, attr))) ++ del expr ++ del attr + EOF + :" + :" Test __dir__() method +*************** +*** 706,720 **** + :$put =string(py3eval('vim.Dictionary(a=1)')) + :$put =string(py3eval('vim.Dictionary(((''a'', 1),))')) + :$put =string(py3eval('vim.List()')) +! :$put =string(py3eval('vim.List(iter(''abc''))')) + :$put =string(py3eval('vim.Function(''tr'')')) + :" + :" Test stdout/stderr + :redir => messages +! :py3 sys.stdout.write('abc') ; sys.stdout.write('def') +! :py3 sys.stderr.write('abc') ; sys.stderr.write('def') +! :py3 sys.stdout.writelines(iter('abc')) +! :py3 sys.stderr.writelines(iter('abc')) + :redir END + :$put =string(substitute(messages, '\d\+', '', 'g')) + :" Test subclassing +--- 752,766 ---- + :$put =string(py3eval('vim.Dictionary(a=1)')) + :$put =string(py3eval('vim.Dictionary(((''a'', 1),))')) + :$put =string(py3eval('vim.List()')) +! :$put =string(py3eval('vim.List(iter(''abc7''))')) + :$put =string(py3eval('vim.Function(''tr'')')) + :" + :" Test stdout/stderr + :redir => messages +! :py3 sys.stdout.write('abc8') ; sys.stdout.write('def') +! :py3 sys.stderr.write('abc9') ; sys.stderr.write('def') +! :py3 sys.stdout.writelines(iter('abcA')) +! :py3 sys.stderr.writelines(iter('abcB')) + :redir END + :$put =string(substitute(messages, '\d\+', '', 'g')) + :" Test subclassing +*************** +*** 735,741 **** + return [super(DupList, self).__getitem__(idx)] * 2 + + dl = DupList() +! dl2 = DupList(iter('abc')) + dl.extend(dl2[0]) + + class DupFun(vim.Function): +--- 781,787 ---- + return [super(DupList, self).__getitem__(idx)] * 2 + + dl = DupList() +! dl2 = DupList(iter('abcC')) + dl.extend(dl2[0]) + + class DupFun(vim.Function): +*************** +*** 748,753 **** +--- 794,812 ---- + :$put =string(py3eval('dl')) + :$put =string(py3eval('dl2')) + :$put =string(py3eval('df(2)')) ++ :$put =string(py3eval('dl') is# py3eval('dl')) ++ :$put =string(py3eval('dd') is# py3eval('dd')) ++ :$put =string(py3eval('df')) ++ :delfunction Put ++ py3 << EOF ++ del DupDict ++ del DupList ++ del DupFun ++ del dd ++ del dl ++ del dl2 ++ del df ++ EOF + :" + :" Test chdir + py3 << EOF +*************** +*** 761,766 **** +--- 820,826 ---- + os.chdir('testdir') + cb.append(str(fnamemodify('.', ':p:h:t'))) + cb.append(vim.eval('@%')) ++ del fnamemodify + EOF + :" + :" Test errors +*************** +*** 784,794 **** + cb.append(expr + '::' + repr((e.__class__, e))) + + d = vim.Dictionary() +! ned = vim.Dictionary(foo='bar', baz='abc') + dl = vim.Dictionary(a=1) + dl.locked = True + l = vim.List() +! ll = vim.List('abc') + ll.locked = True + f = vim.Function('string') + fd = vim.Function('F') +--- 844,854 ---- + cb.append(expr + '::' + repr((e.__class__, e))) + + d = vim.Dictionary() +! ned = vim.Dictionary(foo='bar', baz='abcD') + dl = vim.Dictionary(a=1) + dl.locked = True + l = vim.List() +! ll = vim.List('abcE') + ll.locked = True + f = vim.Function('string') + fd = vim.Function('F') +*************** +*** 825,835 **** + # pydict_to_tv + stringtochars_test(expr % '{%s : 1}') + if recurse: +! convertfrompyobject_test(expr % '{"abc" : %s}', False) + # pymap_to_tv + stringtochars_test(expr % 'Mapping({%s : 1})') + if recurse: +! convertfrompyobject_test(expr % 'Mapping({"abc" : %s})', False) + # pyseq_to_tv + iter_test(expr) + return subexpr_test(expr, 'ConvertFromPyObject', ( +--- 885,895 ---- + # pydict_to_tv + stringtochars_test(expr % '{%s : 1}') + if recurse: +! convertfrompyobject_test(expr % '{"abcF" : %s}', False) + # pymap_to_tv + stringtochars_test(expr % 'Mapping({%s : 1})') + if recurse: +! convertfrompyobject_test(expr % 'Mapping({"abcG" : %s})', False) + # pyseq_to_tv + iter_test(expr) + return subexpr_test(expr, 'ConvertFromPyObject', ( +*************** +*** 872,878 **** + raise NotImplementedError + + def keys(self): +! return list("abc") + + class FailingMapping(object): + def __getitem__(self): +--- 932,938 ---- + raise NotImplementedError + + def keys(self): +! return list("abcH") + + class FailingMapping(object): + def __getitem__(self): +*************** +*** 914,920 **** + ee('vim.strwidth(1)') + cb.append("> Dictionary") + cb.append(">> DictionaryConstructor") +! ee('vim.Dictionary("abc")') + ##! Not checked: py_dict_alloc failure + cb.append(">> DictionarySetattr") + ee('del d.locked') +--- 974,980 ---- + ee('vim.strwidth(1)') + cb.append("> Dictionary") + cb.append(">> DictionaryConstructor") +! ee('vim.Dictionary("abcI")') + ##! Not checked: py_dict_alloc failure + cb.append(">> DictionarySetattr") + ee('del d.locked') +*************** +*** 929,934 **** +--- 989,995 ---- + ee('dl.pop("a")') + cb.append(">> DictionaryIterNext") + ee('for i in ned: ned["a"] = 1') ++ del i + cb.append(">> DictionaryAssItem") + ee('dl["b"] = 1') + stringtochars_test('d[%s] = 1') +*************** +*** 958,964 **** + ee('ll[1] = 2') + ee('l[1000] = 3') + cb.append(">> ListAssSlice") +! ee('ll[1:100] = "abc"') + iter_test('l[:] = %s') + convertfrompyobject_test('l[:] = [%s]') + cb.append(">> ListConcatInPlace") +--- 1019,1025 ---- + ee('ll[1] = 2') + ee('l[1000] = 3') + cb.append(">> ListAssSlice") +! ee('ll[1:100] = "abcJ"') + iter_test('l[:] = %s') + convertfrompyobject_test('l[:] = [%s]') + cb.append(">> ListConcatInPlace") +*************** +*** 989,996 **** + ee('vim.current.window.buffer = 0') + ee('vim.current.window.cursor = (100000000, 100000000)') + ee('vim.current.window.cursor = True') +! ee('vim.current.window.height = "abc"') +! ee('vim.current.window.width = "abc"') + ee('vim.current.window.xxxxxx = True') + cb.append("> WinList") + cb.append(">> WinListItem") +--- 1050,1057 ---- + ee('vim.current.window.buffer = 0') + ee('vim.current.window.cursor = (100000000, 100000000)') + ee('vim.current.window.cursor = True') +! ee('vim.current.window.height = "abcK"') +! ee('vim.current.window.width = "abcL"') + ee('vim.current.window.xxxxxx = True') + cb.append("> WinList") + cb.append(">> WinListItem") +*************** +*** 1000,1006 **** + ee('vim.current.buffer[0] = "\\na"') + cb.append(">> SetBufferLine (indirect)") + ee('vim.current.buffer[0] = True') +! cb.append(">> SetBufferLines (indirect)") + ee('vim.current.buffer[:] = True') + ee('vim.current.buffer[:] = ["\\na", "bc"]') + cb.append(">> InsertBufferLines (indirect)") +--- 1061,1067 ---- + ee('vim.current.buffer[0] = "\\na"') + cb.append(">> SetBufferLine (indirect)") + ee('vim.current.buffer[0] = True') +! cb.append(">> SetBufferLineList (indirect)") + ee('vim.current.buffer[:] = True') + ee('vim.current.buffer[:] = ["\\na", "bc"]') + cb.append(">> InsertBufferLines (indirect)") +*************** +*** 1018,1024 **** + ee('vim.current.buffer.xxx = True') + cb.append(">> BufferMark") + ee('vim.current.buffer.mark(0)') +! ee('vim.current.buffer.mark("abc")') + ee('vim.current.buffer.mark("!")') + cb.append(">> BufferRange") + ee('vim.current.buffer.range(1, 2, 3)') +--- 1079,1085 ---- + ee('vim.current.buffer.xxx = True') + cb.append(">> BufferMark") + ee('vim.current.buffer.mark(0)') +! ee('vim.current.buffer.mark("abcM")') + ee('vim.current.buffer.mark("!")') + cb.append(">> BufferRange") + ee('vim.current.buffer.range(1, 2, 3)') +*************** +*** 1035,1041 **** +--- 1096,1123 ---- + ee('vim.current.window = True') + ee('vim.current.tabpage = True') + ee('vim.current.xxx = True') ++ del d ++ del ned ++ del dl ++ del l ++ del ll ++ del f ++ del fd ++ del fdel ++ del subexpr_test ++ del stringtochars_test ++ del Mapping ++ del convertfrompyobject_test ++ del convertfrompymapping_test ++ del iter_test ++ del FailingTrue ++ del FailingIter ++ del FailingIterNext ++ del FailingMapping ++ del FailingMappingKey ++ del FailingList + EOF ++ :delfunction F + :" + :" Test import + py3 << EOF +*************** +*** 1049,1054 **** +--- 1131,1140 ---- + cb.append(before.dir) + import after + cb.append(after.dir) ++ del before ++ del after ++ del d ++ del ddir + EOF + :" + :" Test exceptions +*************** +*** 1057,1074 **** + :endfun + py3 << EOF + Exe = vim.bindeval('function("Exe")') +! ee('vim.command("throw \'abc\'")') + ee('Exe("throw \'def\'")') + ee('vim.eval("Exe(\'throw \'\'ghi\'\'\')")') + ee('vim.eval("Exe(\'echoerr \'\'jkl\'\'\')")') + ee('vim.eval("Exe(\'xxx_non_existent_command_xxx\')")') + ee('vim.bindeval("Exe(\'xxx_non_existent_command_xxx\')")') + EOF + :endfun + :" +! :call Test() + :" +! :delfunc Test + :call garbagecollect(1) + :" + :/^start:/,$wq! test.out +--- 1143,1190 ---- + :endfun + py3 << EOF + Exe = vim.bindeval('function("Exe")') +! ee('vim.command("throw \'abcN\'")') + ee('Exe("throw \'def\'")') + ee('vim.eval("Exe(\'throw \'\'ghi\'\'\')")') + ee('vim.eval("Exe(\'echoerr \'\'jkl\'\'\')")') + ee('vim.eval("Exe(\'xxx_non_existent_command_xxx\')")') + ee('vim.bindeval("Exe(\'xxx_non_existent_command_xxx\')")') ++ del Exe ++ EOF ++ :delfunction Exe ++ :" ++ :" Cleanup ++ py3 << EOF ++ del cb ++ del ee ++ del sys ++ del os ++ del vim + EOF + :endfun + :" +! :fun RunTest() +! :let checkrefs = !empty($PYTHONDUMPREFS) +! :let start = getline(1, '$') +! :for i in range(checkrefs ? 10 : 1) +! : if i != 0 +! : %d _ +! : call setline(1, start) +! : endif +! : call Test() +! : if i == 0 +! : let result = getline(1, '$') +! : endif +! :endfor +! :if checkrefs +! : %d _ +! : call setline(1, result) +! :endif +! :endfun + :" +! :call RunTest() +! :delfunction RunTest +! :delfunction Test + :call garbagecollect(1) + :" + :/^start:/,$wq! test.out +*** ../vim-7.3.1232/src/testdir/test87.ok 2013-06-23 14:16:53.000000000 +0200 +--- src/testdir/test87.ok 2013-06-23 14:34:17.000000000 +0200 +*************** +*** 68,74 **** + dl : locked:1;scope:0 + v: : locked:2;scope:1 + g: : locked:0;scope:2 +! d:{'abc': 1} + dl:{'def': 1} + l : locked:0 + ll : locked:1 +--- 68,74 ---- + dl : locked:1;scope:0 + v: : locked:2;scope:1 + g: : locked:0;scope:2 +! d:{'abc2': 1} + dl:{'def': 1} + l : locked:0 + ll : locked:1 +*************** +*** 191,202 **** + B: 1:3 2:5 3:2 4:8 + >>> colorcolumn + p/gopts1! KeyError +! inv: 'abc'! KeyError + gopts1! KeyError + p/wopts1: b'' +! inv: 'abc'! error + p/bopts1! KeyError +! inv: 'abc'! KeyError + bopts1! KeyError + bopts2! KeyError + bopts3! KeyError +--- 191,202 ---- + B: 1:3 2:5 3:2 4:8 + >>> colorcolumn + p/gopts1! KeyError +! inv: 'abc4'! KeyError + gopts1! KeyError + p/wopts1: b'' +! inv: 'abc4'! error + p/bopts1! KeyError +! inv: 'abc4'! KeyError + bopts1! KeyError + bopts2! KeyError + bopts3! KeyError +*************** +*** 404,423 **** + {'a': 1} + {'a': 1} + [] +! ['a', 'b', 'c'] + function('tr') + ' + abcdef + line : + abcdef +! abc + line : +! abc' + ['a', 'dup_a'] + ['a', 'a'] +! ['a', 'b', 'c'] + [2, 2] + [2, 2] + b'testdir' + test87.in + b'src' +--- 404,426 ---- + {'a': 1} + {'a': 1} + [] +! ['a', 'b', 'c', '7'] + function('tr') + ' + abcdef + line : + abcdef +! abcA + line : +! abcB' + ['a', 'dup_a'] + ['a', 'a'] +! ['a', 'b', 'c', 'C'] + [2, 2] + [2, 2] ++ 1 ++ 1 ++ function('Put') + b'testdir' + test87.in + b'src' +*************** +*** 449,455 **** + vim.strwidth(1):(, TypeError('expected bytes() or str() instance, but got int',)) + > Dictionary + >> DictionaryConstructor +! vim.Dictionary("abc"):(, ValueError('expected sequence element of size 2, but got sequence of size 1',)) + >> DictionarySetattr + del d.locked:(, AttributeError('cannot delete vim.Dictionary attributes',)) + d.locked = FailingTrue():(, NotImplementedError()) +--- 452,458 ---- + vim.strwidth(1):(, TypeError('expected bytes() or str() instance, but got int',)) + > Dictionary + >> DictionaryConstructor +! vim.Dictionary("abcI"):(, ValueError('expected sequence element of size 2, but got sequence of size 1',)) + >> DictionarySetattr + del d.locked:(, AttributeError('cannot delete vim.Dictionary attributes',)) + d.locked = FailingTrue():(, NotImplementedError()) +*************** +*** 479,530 **** + d["a"] = {b"\0" : 1}:(, TypeError('expected bytes with no null',)) + d["a"] = {"\0" : 1}:(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using d["a"] = {"abc" : {%s : 1}} +! d["a"] = {"abc" : {1 : 1}}:(, TypeError('expected bytes() or str() instance, but got int',)) +! d["a"] = {"abc" : {b"\0" : 1}}:(, TypeError('expected bytes with no null',)) +! d["a"] = {"abc" : {"\0" : 1}}:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d["a"] = {"abc" : Mapping({%s : 1})} +! d["a"] = {"abc" : Mapping({1 : 1})}:(, TypeError('expected bytes() or str() instance, but got int',)) +! d["a"] = {"abc" : Mapping({b"\0" : 1})}:(, TypeError('expected bytes with no null',)) +! d["a"] = {"abc" : Mapping({"\0" : 1})}:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : FailingIter()}:(, TypeError('unable to convert FailingIter to vim structure',)) +! d["a"] = {"abc" : FailingIterNext()}:(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d["a"] = {"abc" : %s} +! d["a"] = {"abc" : None}:(, TypeError('unable to convert NoneType to vim structure',)) +! d["a"] = {"abc" : {b"": 1}}:(, ValueError('empty keys are not allowed',)) +! d["a"] = {"abc" : {"": 1}}:(, ValueError('empty keys are not allowed',)) +! d["a"] = {"abc" : FailingMapping()}:(, NotImplementedError()) +! d["a"] = {"abc" : FailingMappingKey()}:(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) + d["a"] = Mapping({1 : 1}):(, TypeError('expected bytes() or str() instance, but got int',)) + d["a"] = Mapping({b"\0" : 1}):(, TypeError('expected bytes with no null',)) + d["a"] = Mapping({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using d["a"] = Mapping({"abc" : {%s : 1}}) +! d["a"] = Mapping({"abc" : {1 : 1}}):(, TypeError('expected bytes() or str() instance, but got int',)) +! d["a"] = Mapping({"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! d["a"] = Mapping({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d["a"] = Mapping({"abc" : Mapping({%s : 1})}) +! d["a"] = Mapping({"abc" : Mapping({1 : 1})}):(, TypeError('expected bytes() or str() instance, but got int',)) +! d["a"] = Mapping({"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! d["a"] = Mapping({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! d["a"] = Mapping({"abc" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abc" : %s}) +! d["a"] = Mapping({"abc" : None}):(, TypeError('unable to convert NoneType to vim structure',)) +! d["a"] = Mapping({"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) +! d["a"] = Mapping({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! d["a"] = Mapping({"abc" : FailingMapping()}):(, NotImplementedError()) +! d["a"] = Mapping({"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d["a"] = %s + d["a"] = FailingIter():(, TypeError('unable to convert FailingIter to vim structure',)) +--- 482,533 ---- + d["a"] = {b"\0" : 1}:(, TypeError('expected bytes with no null',)) + d["a"] = {"\0" : 1}:(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using d["a"] = {"abcF" : {%s : 1}} +! d["a"] = {"abcF" : {1 : 1}}:(, TypeError('expected bytes() or str() instance, but got int',)) +! d["a"] = {"abcF" : {b"\0" : 1}}:(, TypeError('expected bytes with no null',)) +! d["a"] = {"abcF" : {"\0" : 1}}:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d["a"] = {"abcF" : Mapping({%s : 1})} +! d["a"] = {"abcF" : Mapping({1 : 1})}:(, TypeError('expected bytes() or str() instance, but got int',)) +! d["a"] = {"abcF" : Mapping({b"\0" : 1})}:(, TypeError('expected bytes with no null',)) +! d["a"] = {"abcF" : Mapping({"\0" : 1})}:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d["a"] = {"abcF" : %s} +! d["a"] = {"abcF" : FailingIter()}:(, TypeError('unable to convert FailingIter to vim structure',)) +! d["a"] = {"abcF" : FailingIterNext()}:(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d["a"] = {"abcF" : %s} +! d["a"] = {"abcF" : None}:(, TypeError('unable to convert NoneType to vim structure',)) +! d["a"] = {"abcF" : {b"": 1}}:(, ValueError('empty keys are not allowed',)) +! d["a"] = {"abcF" : {"": 1}}:(, ValueError('empty keys are not allowed',)) +! d["a"] = {"abcF" : FailingMapping()}:(, NotImplementedError()) +! d["a"] = {"abcF" : FailingMappingKey()}:(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) + d["a"] = Mapping({1 : 1}):(, TypeError('expected bytes() or str() instance, but got int',)) + d["a"] = Mapping({b"\0" : 1}):(, TypeError('expected bytes with no null',)) + d["a"] = Mapping({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using d["a"] = Mapping({"abcG" : {%s : 1}}) +! d["a"] = Mapping({"abcG" : {1 : 1}}):(, TypeError('expected bytes() or str() instance, but got int',)) +! d["a"] = Mapping({"abcG" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! d["a"] = Mapping({"abcG" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d["a"] = Mapping({"abcG" : Mapping({%s : 1})}) +! d["a"] = Mapping({"abcG" : Mapping({1 : 1})}):(, TypeError('expected bytes() or str() instance, but got int',)) +! d["a"] = Mapping({"abcG" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! d["a"] = Mapping({"abcG" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d["a"] = Mapping({"abcG" : %s}) +! d["a"] = Mapping({"abcG" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! d["a"] = Mapping({"abcG" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abcG" : %s}) +! d["a"] = Mapping({"abcG" : None}):(, TypeError('unable to convert NoneType to vim structure',)) +! d["a"] = Mapping({"abcG" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) +! d["a"] = Mapping({"abcG" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! d["a"] = Mapping({"abcG" : FailingMapping()}):(, NotImplementedError()) +! d["a"] = Mapping({"abcG" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d["a"] = %s + d["a"] = FailingIter():(, TypeError('unable to convert FailingIter to vim structure',)) +*************** +*** 551,602 **** + d.update({b"\0" : 1}):(, TypeError('expected bytes with no null',)) + d.update({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using d.update({"abc" : {%s : 1}}) +! d.update({"abc" : {1 : 1}}):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update({"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! d.update({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update({"abc" : Mapping({%s : 1})}) +! d.update({"abc" : Mapping({1 : 1})}):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update({"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! d.update({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d.update({"abc" : %s}) +! d.update({"abc" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update({"abc" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update({"abc" : %s}) +! d.update({"abc" : None}):(, TypeError('unable to convert NoneType to vim structure',)) +! d.update({"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) +! d.update({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! d.update({"abc" : FailingMapping()}):(, NotImplementedError()) +! d.update({"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) + d.update(Mapping({1 : 1})):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update(Mapping({b"\0" : 1})):(, TypeError('expected bytes with no null',)) + d.update(Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using d.update(Mapping({"abc" : {%s : 1}})) +! d.update(Mapping({"abc" : {1 : 1}})):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update(Mapping({"abc" : {b"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! d.update(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update(Mapping({"abc" : Mapping({%s : 1})})) +! d.update(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update(Mapping({"abc" : Mapping({b"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! d.update(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update(Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update(Mapping({"abc" : %s})) +! d.update(Mapping({"abc" : None})):(, TypeError('unable to convert NoneType to vim structure',)) +! d.update(Mapping({"abc" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) +! d.update(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! d.update(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) +! d.update(Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d.update(%s) + d.update(FailingIter()):(, NotImplementedError()) +--- 554,605 ---- + d.update({b"\0" : 1}):(, TypeError('expected bytes with no null',)) + d.update({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using d.update({"abcF" : {%s : 1}}) +! d.update({"abcF" : {1 : 1}}):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update({"abcF" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! d.update({"abcF" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update({"abcF" : Mapping({%s : 1})}) +! d.update({"abcF" : Mapping({1 : 1})}):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update({"abcF" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! d.update({"abcF" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d.update({"abcF" : %s}) +! d.update({"abcF" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update({"abcF" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update({"abcF" : %s}) +! d.update({"abcF" : None}):(, TypeError('unable to convert NoneType to vim structure',)) +! d.update({"abcF" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) +! d.update({"abcF" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! d.update({"abcF" : FailingMapping()}):(, NotImplementedError()) +! d.update({"abcF" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) + d.update(Mapping({1 : 1})):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update(Mapping({b"\0" : 1})):(, TypeError('expected bytes with no null',)) + d.update(Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using d.update(Mapping({"abcG" : {%s : 1}})) +! d.update(Mapping({"abcG" : {1 : 1}})):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update(Mapping({"abcG" : {b"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! d.update(Mapping({"abcG" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update(Mapping({"abcG" : Mapping({%s : 1})})) +! d.update(Mapping({"abcG" : Mapping({1 : 1})})):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update(Mapping({"abcG" : Mapping({b"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! d.update(Mapping({"abcG" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d.update(Mapping({"abcG" : %s})) +! d.update(Mapping({"abcG" : FailingIter()})):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update(Mapping({"abcG" : FailingIterNext()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update(Mapping({"abcG" : %s})) +! d.update(Mapping({"abcG" : None})):(, TypeError('unable to convert NoneType to vim structure',)) +! d.update(Mapping({"abcG" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) +! d.update(Mapping({"abcG" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! d.update(Mapping({"abcG" : FailingMapping()})):(, NotImplementedError()) +! d.update(Mapping({"abcG" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d.update(%s) + d.update(FailingIter()):(, NotImplementedError()) +*************** +*** 619,670 **** + d.update((("a", {b"\0" : 1}),)):(, TypeError('expected bytes with no null',)) + d.update((("a", {"\0" : 1}),)):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using d.update((("a", {"abc" : {%s : 1}}),)) +! d.update((("a", {"abc" : {1 : 1}}),)):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update((("a", {"abc" : {b"\0" : 1}}),)):(, TypeError('expected bytes with no null',)) +! d.update((("a", {"abc" : {"\0" : 1}}),)):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", {"abc" : Mapping({%s : 1})}),)) +! d.update((("a", {"abc" : Mapping({1 : 1})}),)):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update((("a", {"abc" : Mapping({b"\0" : 1})}),)):(, TypeError('expected bytes with no null',)) +! d.update((("a", {"abc" : Mapping({"\0" : 1})}),)):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : FailingIter()}),)):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update((("a", {"abc" : FailingIterNext()}),)):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update((("a", {"abc" : %s}),)) +! d.update((("a", {"abc" : None}),)):(, TypeError('unable to convert NoneType to vim structure',)) +! d.update((("a", {"abc" : {b"": 1}}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", {"abc" : {"": 1}}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", {"abc" : FailingMapping()}),)):(, NotImplementedError()) +! d.update((("a", {"abc" : FailingMappingKey()}),)):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) + d.update((("a", Mapping({1 : 1})),)):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update((("a", Mapping({b"\0" : 1})),)):(, TypeError('expected bytes with no null',)) + d.update((("a", Mapping({"\0" : 1})),)):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using d.update((("a", Mapping({"abc" : {%s : 1}})),)) +! d.update((("a", Mapping({"abc" : {1 : 1}})),)):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update((("a", Mapping({"abc" : {b"\0" : 1}})),)):(, TypeError('expected bytes with no null',)) +! d.update((("a", Mapping({"abc" : {"\0" : 1}})),)):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", Mapping({"abc" : Mapping({%s : 1})})),)) +! d.update((("a", Mapping({"abc" : Mapping({1 : 1})})),)):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update((("a", Mapping({"abc" : Mapping({b"\0" : 1})})),)):(, TypeError('expected bytes with no null',)) +! d.update((("a", Mapping({"abc" : Mapping({"\0" : 1})})),)):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : FailingIter()})),)):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update((("a", Mapping({"abc" : FailingIterNext()})),)):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abc" : %s})),)) +! d.update((("a", Mapping({"abc" : None})),)):(, TypeError('unable to convert NoneType to vim structure',)) +! d.update((("a", Mapping({"abc" : {b"": 1}})),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", Mapping({"abc" : {"": 1}})),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", Mapping({"abc" : FailingMapping()})),)):(, NotImplementedError()) +! d.update((("a", Mapping({"abc" : FailingMappingKey()})),)):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d.update((("a", %s),)) + d.update((("a", FailingIter()),)):(, TypeError('unable to convert FailingIter to vim structure',)) +--- 622,673 ---- + d.update((("a", {b"\0" : 1}),)):(, TypeError('expected bytes with no null',)) + d.update((("a", {"\0" : 1}),)):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using d.update((("a", {"abcF" : {%s : 1}}),)) +! d.update((("a", {"abcF" : {1 : 1}}),)):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update((("a", {"abcF" : {b"\0" : 1}}),)):(, TypeError('expected bytes with no null',)) +! d.update((("a", {"abcF" : {"\0" : 1}}),)):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", {"abcF" : Mapping({%s : 1})}),)) +! d.update((("a", {"abcF" : Mapping({1 : 1})}),)):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update((("a", {"abcF" : Mapping({b"\0" : 1})}),)):(, TypeError('expected bytes with no null',)) +! d.update((("a", {"abcF" : Mapping({"\0" : 1})}),)):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d.update((("a", {"abcF" : %s}),)) +! d.update((("a", {"abcF" : FailingIter()}),)):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update((("a", {"abcF" : FailingIterNext()}),)):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update((("a", {"abcF" : %s}),)) +! d.update((("a", {"abcF" : None}),)):(, TypeError('unable to convert NoneType to vim structure',)) +! d.update((("a", {"abcF" : {b"": 1}}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", {"abcF" : {"": 1}}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", {"abcF" : FailingMapping()}),)):(, NotImplementedError()) +! d.update((("a", {"abcF" : FailingMappingKey()}),)):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) + d.update((("a", Mapping({1 : 1})),)):(, TypeError('expected bytes() or str() instance, but got int',)) + d.update((("a", Mapping({b"\0" : 1})),)):(, TypeError('expected bytes with no null',)) + d.update((("a", Mapping({"\0" : 1})),)):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using d.update((("a", Mapping({"abcG" : {%s : 1}})),)) +! d.update((("a", Mapping({"abcG" : {1 : 1}})),)):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update((("a", Mapping({"abcG" : {b"\0" : 1}})),)):(, TypeError('expected bytes with no null',)) +! d.update((("a", Mapping({"abcG" : {"\0" : 1}})),)):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using d.update((("a", Mapping({"abcG" : Mapping({%s : 1})})),)) +! d.update((("a", Mapping({"abcG" : Mapping({1 : 1})})),)):(, TypeError('expected bytes() or str() instance, but got int',)) +! d.update((("a", Mapping({"abcG" : Mapping({b"\0" : 1})})),)):(, TypeError('expected bytes with no null',)) +! d.update((("a", Mapping({"abcG" : Mapping({"\0" : 1})})),)):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using d.update((("a", Mapping({"abcG" : %s})),)) +! d.update((("a", Mapping({"abcG" : FailingIter()})),)):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update((("a", Mapping({"abcG" : FailingIterNext()})),)):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abcG" : %s})),)) +! d.update((("a", Mapping({"abcG" : None})),)):(, TypeError('unable to convert NoneType to vim structure',)) +! d.update((("a", Mapping({"abcG" : {b"": 1}})),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", Mapping({"abcG" : {"": 1}})),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", Mapping({"abcG" : FailingMapping()})),)):(, NotImplementedError()) +! d.update((("a", Mapping({"abcG" : FailingMappingKey()})),)):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d.update((("a", %s),)) + d.update((("a", FailingIter()),)):(, TypeError('unable to convert FailingIter to vim structure',)) +*************** +*** 694,745 **** + vim.List([{b"\0" : 1}]):(, TypeError('expected bytes with no null',)) + vim.List([{"\0" : 1}]):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using vim.List([{"abc" : {%s : 1}}]) +! vim.List([{"abc" : {1 : 1}}]):(, TypeError('expected bytes() or str() instance, but got int',)) +! vim.List([{"abc" : {b"\0" : 1}}]):(, TypeError('expected bytes with no null',)) +! vim.List([{"abc" : {"\0" : 1}}]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using vim.List([{"abc" : Mapping({%s : 1})}]) +! vim.List([{"abc" : Mapping({1 : 1})}]):(, TypeError('expected bytes() or str() instance, but got int',)) +! vim.List([{"abc" : Mapping({b"\0" : 1})}]):(, TypeError('expected bytes with no null',)) +! vim.List([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : FailingIter()}]):(, TypeError('unable to convert FailingIter to vim structure',)) +! vim.List([{"abc" : FailingIterNext()}]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using vim.List([{"abc" : %s}]) +! vim.List([{"abc" : None}]):(, TypeError('unable to convert NoneType to vim structure',)) +! vim.List([{"abc" : {b"": 1}}]):(, ValueError('empty keys are not allowed',)) +! vim.List([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) +! vim.List([{"abc" : FailingMapping()}]):(, NotImplementedError()) +! vim.List([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) + vim.List([Mapping({1 : 1})]):(, TypeError('expected bytes() or str() instance, but got int',)) + vim.List([Mapping({b"\0" : 1})]):(, TypeError('expected bytes with no null',)) + vim.List([Mapping({"\0" : 1})]):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using vim.List([Mapping({"abc" : {%s : 1}})]) +! vim.List([Mapping({"abc" : {1 : 1}})]):(, TypeError('expected bytes() or str() instance, but got int',)) +! vim.List([Mapping({"abc" : {b"\0" : 1}})]):(, TypeError('expected bytes with no null',)) +! vim.List([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using vim.List([Mapping({"abc" : Mapping({%s : 1})})]) +! vim.List([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('expected bytes() or str() instance, but got int',)) +! vim.List([Mapping({"abc" : Mapping({b"\0" : 1})})]):(, TypeError('expected bytes with no null',)) +! vim.List([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : FailingIter()})]):(, TypeError('unable to convert FailingIter to vim structure',)) +! vim.List([Mapping({"abc" : FailingIterNext()})]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using vim.List([Mapping({"abc" : %s})]) +! vim.List([Mapping({"abc" : None})]):(, TypeError('unable to convert NoneType to vim structure',)) +! vim.List([Mapping({"abc" : {b"": 1}})]):(, ValueError('empty keys are not allowed',)) +! vim.List([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) +! vim.List([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) +! vim.List([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using vim.List([%s]) + vim.List([FailingIter()]):(, TypeError('unable to convert FailingIter to vim structure',)) +--- 697,748 ---- + vim.List([{b"\0" : 1}]):(, TypeError('expected bytes with no null',)) + vim.List([{"\0" : 1}]):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using vim.List([{"abcF" : {%s : 1}}]) +! vim.List([{"abcF" : {1 : 1}}]):(, TypeError('expected bytes() or str() instance, but got int',)) +! vim.List([{"abcF" : {b"\0" : 1}}]):(, TypeError('expected bytes with no null',)) +! vim.List([{"abcF" : {"\0" : 1}}]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using vim.List([{"abcF" : Mapping({%s : 1})}]) +! vim.List([{"abcF" : Mapping({1 : 1})}]):(, TypeError('expected bytes() or str() instance, but got int',)) +! vim.List([{"abcF" : Mapping({b"\0" : 1})}]):(, TypeError('expected bytes with no null',)) +! vim.List([{"abcF" : Mapping({"\0" : 1})}]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using vim.List([{"abcF" : %s}]) +! vim.List([{"abcF" : FailingIter()}]):(, TypeError('unable to convert FailingIter to vim structure',)) +! vim.List([{"abcF" : FailingIterNext()}]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using vim.List([{"abcF" : %s}]) +! vim.List([{"abcF" : None}]):(, TypeError('unable to convert NoneType to vim structure',)) +! vim.List([{"abcF" : {b"": 1}}]):(, ValueError('empty keys are not allowed',)) +! vim.List([{"abcF" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) +! vim.List([{"abcF" : FailingMapping()}]):(, NotImplementedError()) +! vim.List([{"abcF" : FailingMappingKey()}]):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) + vim.List([Mapping({1 : 1})]):(, TypeError('expected bytes() or str() instance, but got int',)) + vim.List([Mapping({b"\0" : 1})]):(, TypeError('expected bytes with no null',)) + vim.List([Mapping({"\0" : 1})]):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using vim.List([Mapping({"abcG" : {%s : 1}})]) +! vim.List([Mapping({"abcG" : {1 : 1}})]):(, TypeError('expected bytes() or str() instance, but got int',)) +! vim.List([Mapping({"abcG" : {b"\0" : 1}})]):(, TypeError('expected bytes with no null',)) +! vim.List([Mapping({"abcG" : {"\0" : 1}})]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using vim.List([Mapping({"abcG" : Mapping({%s : 1})})]) +! vim.List([Mapping({"abcG" : Mapping({1 : 1})})]):(, TypeError('expected bytes() or str() instance, but got int',)) +! vim.List([Mapping({"abcG" : Mapping({b"\0" : 1})})]):(, TypeError('expected bytes with no null',)) +! vim.List([Mapping({"abcG" : Mapping({"\0" : 1})})]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using vim.List([Mapping({"abcG" : %s})]) +! vim.List([Mapping({"abcG" : FailingIter()})]):(, TypeError('unable to convert FailingIter to vim structure',)) +! vim.List([Mapping({"abcG" : FailingIterNext()})]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using vim.List([Mapping({"abcG" : %s})]) +! vim.List([Mapping({"abcG" : None})]):(, TypeError('unable to convert NoneType to vim structure',)) +! vim.List([Mapping({"abcG" : {b"": 1}})]):(, ValueError('empty keys are not allowed',)) +! vim.List([Mapping({"abcG" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) +! vim.List([Mapping({"abcG" : FailingMapping()})]):(, NotImplementedError()) +! vim.List([Mapping({"abcG" : FailingMappingKey()})]):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using vim.List([%s]) + vim.List([FailingIter()]):(, TypeError('unable to convert FailingIter to vim structure',)) +*************** +*** 758,764 **** + ll[1] = 2:(, error('list is locked',)) + l[1000] = 3:(, IndexError('list index out of range',)) + >> ListAssSlice +! ll[1:100] = "abc":(, error('list is locked',)) + >>> Testing *Iter* using l[:] = %s + l[:] = FailingIter():(, NotImplementedError()) + l[:] = FailingIterNext()::(, NotImplementedError()) +--- 761,767 ---- + ll[1] = 2:(, error('list is locked',)) + l[1000] = 3:(, IndexError('list index out of range',)) + >> ListAssSlice +! ll[1:100] = "abcJ":(, error('list is locked',)) + >>> Testing *Iter* using l[:] = %s + l[:] = FailingIter():(, NotImplementedError()) + l[:] = FailingIterNext()::(, NotImplementedError()) +*************** +*** 768,819 **** + l[:] = [{b"\0" : 1}]:(, TypeError('expected bytes with no null',)) + l[:] = [{"\0" : 1}]:(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using l[:] = [{"abc" : {%s : 1}}] +! l[:] = [{"abc" : {1 : 1}}]:(, TypeError('expected bytes() or str() instance, but got int',)) +! l[:] = [{"abc" : {b"\0" : 1}}]:(, TypeError('expected bytes with no null',)) +! l[:] = [{"abc" : {"\0" : 1}}]:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l[:] = [{"abc" : Mapping({%s : 1})}] +! l[:] = [{"abc" : Mapping({1 : 1})}]:(, TypeError('expected bytes() or str() instance, but got int',)) +! l[:] = [{"abc" : Mapping({b"\0" : 1})}]:(, TypeError('expected bytes with no null',)) +! l[:] = [{"abc" : Mapping({"\0" : 1})}]:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : FailingIter()}]:(, TypeError('unable to convert FailingIter to vim structure',)) +! l[:] = [{"abc" : FailingIterNext()}]:(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l[:] = [{"abc" : %s}] +! l[:] = [{"abc" : None}]:(, TypeError('unable to convert NoneType to vim structure',)) +! l[:] = [{"abc" : {b"": 1}}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [{"abc" : {"": 1}}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [{"abc" : FailingMapping()}]:(, NotImplementedError()) +! l[:] = [{"abc" : FailingMappingKey()}]:(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] + l[:] = [Mapping({1 : 1})]:(, TypeError('expected bytes() or str() instance, but got int',)) + l[:] = [Mapping({b"\0" : 1})]:(, TypeError('expected bytes with no null',)) + l[:] = [Mapping({"\0" : 1})]:(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using l[:] = [Mapping({"abc" : {%s : 1}})] +! l[:] = [Mapping({"abc" : {1 : 1}})]:(, TypeError('expected bytes() or str() instance, but got int',)) +! l[:] = [Mapping({"abc" : {b"\0" : 1}})]:(, TypeError('expected bytes with no null',)) +! l[:] = [Mapping({"abc" : {"\0" : 1}})]:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l[:] = [Mapping({"abc" : Mapping({%s : 1})})] +! l[:] = [Mapping({"abc" : Mapping({1 : 1})})]:(, TypeError('expected bytes() or str() instance, but got int',)) +! l[:] = [Mapping({"abc" : Mapping({b"\0" : 1})})]:(, TypeError('expected bytes with no null',)) +! l[:] = [Mapping({"abc" : Mapping({"\0" : 1})})]:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : FailingIter()})]:(, TypeError('unable to convert FailingIter to vim structure',)) +! l[:] = [Mapping({"abc" : FailingIterNext()})]:(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abc" : %s})] +! l[:] = [Mapping({"abc" : None})]:(, TypeError('unable to convert NoneType to vim structure',)) +! l[:] = [Mapping({"abc" : {b"": 1}})]:(, ValueError('empty keys are not allowed',)) +! l[:] = [Mapping({"abc" : {"": 1}})]:(, ValueError('empty keys are not allowed',)) +! l[:] = [Mapping({"abc" : FailingMapping()})]:(, NotImplementedError()) +! l[:] = [Mapping({"abc" : FailingMappingKey()})]:(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using l[:] = [%s] + l[:] = [FailingIter()]:(, TypeError('unable to convert FailingIter to vim structure',)) +--- 771,822 ---- + l[:] = [{b"\0" : 1}]:(, TypeError('expected bytes with no null',)) + l[:] = [{"\0" : 1}]:(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using l[:] = [{"abcF" : {%s : 1}}] +! l[:] = [{"abcF" : {1 : 1}}]:(, TypeError('expected bytes() or str() instance, but got int',)) +! l[:] = [{"abcF" : {b"\0" : 1}}]:(, TypeError('expected bytes with no null',)) +! l[:] = [{"abcF" : {"\0" : 1}}]:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l[:] = [{"abcF" : Mapping({%s : 1})}] +! l[:] = [{"abcF" : Mapping({1 : 1})}]:(, TypeError('expected bytes() or str() instance, but got int',)) +! l[:] = [{"abcF" : Mapping({b"\0" : 1})}]:(, TypeError('expected bytes with no null',)) +! l[:] = [{"abcF" : Mapping({"\0" : 1})}]:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using l[:] = [{"abcF" : %s}] +! l[:] = [{"abcF" : FailingIter()}]:(, TypeError('unable to convert FailingIter to vim structure',)) +! l[:] = [{"abcF" : FailingIterNext()}]:(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l[:] = [{"abcF" : %s}] +! l[:] = [{"abcF" : None}]:(, TypeError('unable to convert NoneType to vim structure',)) +! l[:] = [{"abcF" : {b"": 1}}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [{"abcF" : {"": 1}}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [{"abcF" : FailingMapping()}]:(, NotImplementedError()) +! l[:] = [{"abcF" : FailingMappingKey()}]:(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] + l[:] = [Mapping({1 : 1})]:(, TypeError('expected bytes() or str() instance, but got int',)) + l[:] = [Mapping({b"\0" : 1})]:(, TypeError('expected bytes with no null',)) + l[:] = [Mapping({"\0" : 1})]:(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using l[:] = [Mapping({"abcG" : {%s : 1}})] +! l[:] = [Mapping({"abcG" : {1 : 1}})]:(, TypeError('expected bytes() or str() instance, but got int',)) +! l[:] = [Mapping({"abcG" : {b"\0" : 1}})]:(, TypeError('expected bytes with no null',)) +! l[:] = [Mapping({"abcG" : {"\0" : 1}})]:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l[:] = [Mapping({"abcG" : Mapping({%s : 1})})] +! l[:] = [Mapping({"abcG" : Mapping({1 : 1})})]:(, TypeError('expected bytes() or str() instance, but got int',)) +! l[:] = [Mapping({"abcG" : Mapping({b"\0" : 1})})]:(, TypeError('expected bytes with no null',)) +! l[:] = [Mapping({"abcG" : Mapping({"\0" : 1})})]:(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using l[:] = [Mapping({"abcG" : %s})] +! l[:] = [Mapping({"abcG" : FailingIter()})]:(, TypeError('unable to convert FailingIter to vim structure',)) +! l[:] = [Mapping({"abcG" : FailingIterNext()})]:(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abcG" : %s})] +! l[:] = [Mapping({"abcG" : None})]:(, TypeError('unable to convert NoneType to vim structure',)) +! l[:] = [Mapping({"abcG" : {b"": 1}})]:(, ValueError('empty keys are not allowed',)) +! l[:] = [Mapping({"abcG" : {"": 1}})]:(, ValueError('empty keys are not allowed',)) +! l[:] = [Mapping({"abcG" : FailingMapping()})]:(, NotImplementedError()) +! l[:] = [Mapping({"abcG" : FailingMappingKey()})]:(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using l[:] = [%s] + l[:] = [FailingIter()]:(, TypeError('unable to convert FailingIter to vim structure',)) +*************** +*** 836,887 **** + l.extend([{b"\0" : 1}]):(, TypeError('expected bytes with no null',)) + l.extend([{"\0" : 1}]):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using l.extend([{"abc" : {%s : 1}}]) +! l.extend([{"abc" : {1 : 1}}]):(, TypeError('expected bytes() or str() instance, but got int',)) +! l.extend([{"abc" : {b"\0" : 1}}]):(, TypeError('expected bytes with no null',)) +! l.extend([{"abc" : {"\0" : 1}}]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l.extend([{"abc" : Mapping({%s : 1})}]) +! l.extend([{"abc" : Mapping({1 : 1})}]):(, TypeError('expected bytes() or str() instance, but got int',)) +! l.extend([{"abc" : Mapping({b"\0" : 1})}]):(, TypeError('expected bytes with no null',)) +! l.extend([{"abc" : Mapping({"\0" : 1})}]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : FailingIter()}]):(, TypeError('unable to convert FailingIter to vim structure',)) +! l.extend([{"abc" : FailingIterNext()}]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l.extend([{"abc" : %s}]) +! l.extend([{"abc" : None}]):(, TypeError('unable to convert NoneType to vim structure',)) +! l.extend([{"abc" : {b"": 1}}]):(, ValueError('empty keys are not allowed',)) +! l.extend([{"abc" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) +! l.extend([{"abc" : FailingMapping()}]):(, NotImplementedError()) +! l.extend([{"abc" : FailingMappingKey()}]):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) + l.extend([Mapping({1 : 1})]):(, TypeError('expected bytes() or str() instance, but got int',)) + l.extend([Mapping({b"\0" : 1})]):(, TypeError('expected bytes with no null',)) + l.extend([Mapping({"\0" : 1})]):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using l.extend([Mapping({"abc" : {%s : 1}})]) +! l.extend([Mapping({"abc" : {1 : 1}})]):(, TypeError('expected bytes() or str() instance, but got int',)) +! l.extend([Mapping({"abc" : {b"\0" : 1}})]):(, TypeError('expected bytes with no null',)) +! l.extend([Mapping({"abc" : {"\0" : 1}})]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l.extend([Mapping({"abc" : Mapping({%s : 1})})]) +! l.extend([Mapping({"abc" : Mapping({1 : 1})})]):(, TypeError('expected bytes() or str() instance, but got int',)) +! l.extend([Mapping({"abc" : Mapping({b"\0" : 1})})]):(, TypeError('expected bytes with no null',)) +! l.extend([Mapping({"abc" : Mapping({"\0" : 1})})]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : FailingIter()})]):(, TypeError('unable to convert FailingIter to vim structure',)) +! l.extend([Mapping({"abc" : FailingIterNext()})]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l.extend([Mapping({"abc" : %s})]) +! l.extend([Mapping({"abc" : None})]):(, TypeError('unable to convert NoneType to vim structure',)) +! l.extend([Mapping({"abc" : {b"": 1}})]):(, ValueError('empty keys are not allowed',)) +! l.extend([Mapping({"abc" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) +! l.extend([Mapping({"abc" : FailingMapping()})]):(, NotImplementedError()) +! l.extend([Mapping({"abc" : FailingMappingKey()})]):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using l.extend([%s]) + l.extend([FailingIter()]):(, TypeError('unable to convert FailingIter to vim structure',)) +--- 839,890 ---- + l.extend([{b"\0" : 1}]):(, TypeError('expected bytes with no null',)) + l.extend([{"\0" : 1}]):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using l.extend([{"abcF" : {%s : 1}}]) +! l.extend([{"abcF" : {1 : 1}}]):(, TypeError('expected bytes() or str() instance, but got int',)) +! l.extend([{"abcF" : {b"\0" : 1}}]):(, TypeError('expected bytes with no null',)) +! l.extend([{"abcF" : {"\0" : 1}}]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l.extend([{"abcF" : Mapping({%s : 1})}]) +! l.extend([{"abcF" : Mapping({1 : 1})}]):(, TypeError('expected bytes() or str() instance, but got int',)) +! l.extend([{"abcF" : Mapping({b"\0" : 1})}]):(, TypeError('expected bytes with no null',)) +! l.extend([{"abcF" : Mapping({"\0" : 1})}]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using l.extend([{"abcF" : %s}]) +! l.extend([{"abcF" : FailingIter()}]):(, TypeError('unable to convert FailingIter to vim structure',)) +! l.extend([{"abcF" : FailingIterNext()}]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l.extend([{"abcF" : %s}]) +! l.extend([{"abcF" : None}]):(, TypeError('unable to convert NoneType to vim structure',)) +! l.extend([{"abcF" : {b"": 1}}]):(, ValueError('empty keys are not allowed',)) +! l.extend([{"abcF" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) +! l.extend([{"abcF" : FailingMapping()}]):(, NotImplementedError()) +! l.extend([{"abcF" : FailingMappingKey()}]):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) + l.extend([Mapping({1 : 1})]):(, TypeError('expected bytes() or str() instance, but got int',)) + l.extend([Mapping({b"\0" : 1})]):(, TypeError('expected bytes with no null',)) + l.extend([Mapping({"\0" : 1})]):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using l.extend([Mapping({"abcG" : {%s : 1}})]) +! l.extend([Mapping({"abcG" : {1 : 1}})]):(, TypeError('expected bytes() or str() instance, but got int',)) +! l.extend([Mapping({"abcG" : {b"\0" : 1}})]):(, TypeError('expected bytes with no null',)) +! l.extend([Mapping({"abcG" : {"\0" : 1}})]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using l.extend([Mapping({"abcG" : Mapping({%s : 1})})]) +! l.extend([Mapping({"abcG" : Mapping({1 : 1})})]):(, TypeError('expected bytes() or str() instance, but got int',)) +! l.extend([Mapping({"abcG" : Mapping({b"\0" : 1})})]):(, TypeError('expected bytes with no null',)) +! l.extend([Mapping({"abcG" : Mapping({"\0" : 1})})]):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using l.extend([Mapping({"abcG" : %s})]) +! l.extend([Mapping({"abcG" : FailingIter()})]):(, TypeError('unable to convert FailingIter to vim structure',)) +! l.extend([Mapping({"abcG" : FailingIterNext()})]):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using l.extend([Mapping({"abcG" : %s})]) +! l.extend([Mapping({"abcG" : None})]):(, TypeError('unable to convert NoneType to vim structure',)) +! l.extend([Mapping({"abcG" : {b"": 1}})]):(, ValueError('empty keys are not allowed',)) +! l.extend([Mapping({"abcG" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) +! l.extend([Mapping({"abcG" : FailingMapping()})]):(, NotImplementedError()) +! l.extend([Mapping({"abcG" : FailingMappingKey()})]):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using l.extend([%s]) + l.extend([FailingIter()]):(, TypeError('unable to convert FailingIter to vim structure',)) +*************** +*** 909,960 **** + f({b"\0" : 1}):(, TypeError('expected bytes with no null',)) + f({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using f({"abc" : {%s : 1}}) +! f({"abc" : {1 : 1}}):(, TypeError('expected bytes() or str() instance, but got int',)) +! f({"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! f({"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using f({"abc" : Mapping({%s : 1})}) +! f({"abc" : Mapping({1 : 1})}):(, TypeError('expected bytes() or str() instance, but got int',)) +! f({"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! f({"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using f({"abc" : %s}) +! f({"abc" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! f({"abc" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using f({"abc" : %s}) +! f({"abc" : None}):(, TypeError('unable to convert NoneType to vim structure',)) +! f({"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) +! f({"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! f({"abc" : FailingMapping()}):(, NotImplementedError()) +! f({"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) + f(Mapping({1 : 1})):(, TypeError('expected bytes() or str() instance, but got int',)) + f(Mapping({b"\0" : 1})):(, TypeError('expected bytes with no null',)) + f(Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using f(Mapping({"abc" : {%s : 1}})) +! f(Mapping({"abc" : {1 : 1}})):(, TypeError('expected bytes() or str() instance, but got int',)) +! f(Mapping({"abc" : {b"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! f(Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using f(Mapping({"abc" : Mapping({%s : 1})})) +! f(Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('expected bytes() or str() instance, but got int',)) +! f(Mapping({"abc" : Mapping({b"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! f(Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert FailingIter to vim structure',)) +! f(Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using f(Mapping({"abc" : %s})) +! f(Mapping({"abc" : None})):(, TypeError('unable to convert NoneType to vim structure',)) +! f(Mapping({"abc" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) +! f(Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! f(Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) +! f(Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using f(%s) + f(FailingIter()):(, TypeError('unable to convert FailingIter to vim structure',)) +--- 912,963 ---- + f({b"\0" : 1}):(, TypeError('expected bytes with no null',)) + f({"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using f({"abcF" : {%s : 1}}) +! f({"abcF" : {1 : 1}}):(, TypeError('expected bytes() or str() instance, but got int',)) +! f({"abcF" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! f({"abcF" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using f({"abcF" : Mapping({%s : 1})}) +! f({"abcF" : Mapping({1 : 1})}):(, TypeError('expected bytes() or str() instance, but got int',)) +! f({"abcF" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! f({"abcF" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using f({"abcF" : %s}) +! f({"abcF" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! f({"abcF" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using f({"abcF" : %s}) +! f({"abcF" : None}):(, TypeError('unable to convert NoneType to vim structure',)) +! f({"abcF" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) +! f({"abcF" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! f({"abcF" : FailingMapping()}):(, NotImplementedError()) +! f({"abcF" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) + f(Mapping({1 : 1})):(, TypeError('expected bytes() or str() instance, but got int',)) + f(Mapping({b"\0" : 1})):(, TypeError('expected bytes with no null',)) + f(Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using f(Mapping({"abcG" : {%s : 1}})) +! f(Mapping({"abcG" : {1 : 1}})):(, TypeError('expected bytes() or str() instance, but got int',)) +! f(Mapping({"abcG" : {b"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! f(Mapping({"abcG" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using f(Mapping({"abcG" : Mapping({%s : 1})})) +! f(Mapping({"abcG" : Mapping({1 : 1})})):(, TypeError('expected bytes() or str() instance, but got int',)) +! f(Mapping({"abcG" : Mapping({b"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! f(Mapping({"abcG" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using f(Mapping({"abcG" : %s})) +! f(Mapping({"abcG" : FailingIter()})):(, TypeError('unable to convert FailingIter to vim structure',)) +! f(Mapping({"abcG" : FailingIterNext()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using f(Mapping({"abcG" : %s})) +! f(Mapping({"abcG" : None})):(, TypeError('unable to convert NoneType to vim structure',)) +! f(Mapping({"abcG" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) +! f(Mapping({"abcG" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! f(Mapping({"abcG" : FailingMapping()})):(, NotImplementedError()) +! f(Mapping({"abcG" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using f(%s) + f(FailingIter()):(, TypeError('unable to convert FailingIter to vim structure',)) +*************** +*** 972,1023 **** + fd(self={b"\0" : 1}):(, TypeError('expected bytes with no null',)) + fd(self={"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using fd(self={"abc" : {%s : 1}}) +! fd(self={"abc" : {1 : 1}}):(, TypeError('expected bytes() or str() instance, but got int',)) +! fd(self={"abc" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! fd(self={"abc" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using fd(self={"abc" : Mapping({%s : 1})}) +! fd(self={"abc" : Mapping({1 : 1})}):(, TypeError('expected bytes() or str() instance, but got int',)) +! fd(self={"abc" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! fd(self={"abc" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using fd(self={"abc" : %s}) +! fd(self={"abc" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! fd(self={"abc" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using fd(self={"abc" : %s}) +! fd(self={"abc" : None}):(, TypeError('unable to convert NoneType to vim structure',)) +! fd(self={"abc" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) +! fd(self={"abc" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! fd(self={"abc" : FailingMapping()}):(, NotImplementedError()) +! fd(self={"abc" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) + fd(self=Mapping({1 : 1})):(, TypeError('expected bytes() or str() instance, but got int',)) + fd(self=Mapping({b"\0" : 1})):(, TypeError('expected bytes with no null',)) + fd(self=Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using fd(self=Mapping({"abc" : {%s : 1}})) +! fd(self=Mapping({"abc" : {1 : 1}})):(, TypeError('expected bytes() or str() instance, but got int',)) +! fd(self=Mapping({"abc" : {b"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! fd(self=Mapping({"abc" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using fd(self=Mapping({"abc" : Mapping({%s : 1})})) +! fd(self=Mapping({"abc" : Mapping({1 : 1})})):(, TypeError('expected bytes() or str() instance, but got int',)) +! fd(self=Mapping({"abc" : Mapping({b"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! fd(self=Mapping({"abc" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : FailingIter()})):(, TypeError('unable to convert FailingIter to vim structure',)) +! fd(self=Mapping({"abc" : FailingIterNext()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using fd(self=Mapping({"abc" : %s})) +! fd(self=Mapping({"abc" : None})):(, TypeError('unable to convert NoneType to vim structure',)) +! fd(self=Mapping({"abc" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) +! fd(self=Mapping({"abc" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! fd(self=Mapping({"abc" : FailingMapping()})):(, NotImplementedError()) +! fd(self=Mapping({"abc" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using fd(self=%s) + fd(self=FailingIter()):(, TypeError('unable to convert FailingIter to vim dictionary',)) +--- 975,1026 ---- + fd(self={b"\0" : 1}):(, TypeError('expected bytes with no null',)) + fd(self={"\0" : 1}):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using fd(self={"abcF" : {%s : 1}}) +! fd(self={"abcF" : {1 : 1}}):(, TypeError('expected bytes() or str() instance, but got int',)) +! fd(self={"abcF" : {b"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! fd(self={"abcF" : {"\0" : 1}}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using fd(self={"abcF" : Mapping({%s : 1})}) +! fd(self={"abcF" : Mapping({1 : 1})}):(, TypeError('expected bytes() or str() instance, but got int',)) +! fd(self={"abcF" : Mapping({b"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! fd(self={"abcF" : Mapping({"\0" : 1})}):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using fd(self={"abcF" : %s}) +! fd(self={"abcF" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! fd(self={"abcF" : FailingIterNext()}):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using fd(self={"abcF" : %s}) +! fd(self={"abcF" : None}):(, TypeError('unable to convert NoneType to vim structure',)) +! fd(self={"abcF" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) +! fd(self={"abcF" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! fd(self={"abcF" : FailingMapping()}):(, NotImplementedError()) +! fd(self={"abcF" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) + fd(self=Mapping({1 : 1})):(, TypeError('expected bytes() or str() instance, but got int',)) + fd(self=Mapping({b"\0" : 1})):(, TypeError('expected bytes with no null',)) + fd(self=Mapping({"\0" : 1})):(, TypeError('expected bytes with no null',)) + <<< Finished +! >>> Testing StringToChars using fd(self=Mapping({"abcG" : {%s : 1}})) +! fd(self=Mapping({"abcG" : {1 : 1}})):(, TypeError('expected bytes() or str() instance, but got int',)) +! fd(self=Mapping({"abcG" : {b"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! fd(self=Mapping({"abcG" : {"\0" : 1}})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing StringToChars using fd(self=Mapping({"abcG" : Mapping({%s : 1})})) +! fd(self=Mapping({"abcG" : Mapping({1 : 1})})):(, TypeError('expected bytes() or str() instance, but got int',)) +! fd(self=Mapping({"abcG" : Mapping({b"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! fd(self=Mapping({"abcG" : Mapping({"\0" : 1})})):(, TypeError('expected bytes with no null',)) +! <<< Finished +! >>> Testing *Iter* using fd(self=Mapping({"abcG" : %s})) +! fd(self=Mapping({"abcG" : FailingIter()})):(, TypeError('unable to convert FailingIter to vim structure',)) +! fd(self=Mapping({"abcG" : FailingIterNext()})):(, NotImplementedError()) +! <<< Finished +! >>> Testing ConvertFromPyObject using fd(self=Mapping({"abcG" : %s})) +! fd(self=Mapping({"abcG" : None})):(, TypeError('unable to convert NoneType to vim structure',)) +! fd(self=Mapping({"abcG" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) +! fd(self=Mapping({"abcG" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! fd(self=Mapping({"abcG" : FailingMapping()})):(, NotImplementedError()) +! fd(self=Mapping({"abcG" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using fd(self=%s) + fd(self=FailingIter()):(, TypeError('unable to convert FailingIter to vim dictionary',)) +*************** +*** 1046,1053 **** + vim.current.window.buffer = 0:(, TypeError('readonly attribute: buffer',)) + vim.current.window.cursor = (100000000, 100000000):(, error('cursor position outside buffer',)) + vim.current.window.cursor = True:(, TypeError('argument must be 2-item sequence, not bool',)) +! vim.current.window.height = "abc":(, TypeError('expected int() or something supporting coercing to int(), but got str',)) +! vim.current.window.width = "abc":(, TypeError('expected int() or something supporting coercing to int(), but got str',)) + vim.current.window.xxxxxx = True:(, AttributeError('xxxxxx',)) + > WinList + >> WinListItem +--- 1049,1056 ---- + vim.current.window.buffer = 0:(, TypeError('readonly attribute: buffer',)) + vim.current.window.cursor = (100000000, 100000000):(, error('cursor position outside buffer',)) + vim.current.window.cursor = True:(, TypeError('argument must be 2-item sequence, not bool',)) +! vim.current.window.height = "abcK":(, TypeError('expected int() or something supporting coercing to int(), but got str',)) +! vim.current.window.width = "abcL":(, TypeError('expected int() or something supporting coercing to int(), but got str',)) + vim.current.window.xxxxxx = True:(, AttributeError('xxxxxx',)) + > WinList + >> WinListItem +*************** +*** 1057,1063 **** + vim.current.buffer[0] = "\na":(, error('string cannot contain newlines',)) + >> SetBufferLine (indirect) + vim.current.buffer[0] = True:(, TypeError('bad argument type for built-in operation',)) +! >> SetBufferLines (indirect) + vim.current.buffer[:] = True:(, TypeError('bad argument type for built-in operation',)) + vim.current.buffer[:] = ["\na", "bc"]:(, error('string cannot contain newlines',)) + >> InsertBufferLines (indirect) +--- 1060,1066 ---- + vim.current.buffer[0] = "\na":(, error('string cannot contain newlines',)) + >> SetBufferLine (indirect) + vim.current.buffer[0] = True:(, TypeError('bad argument type for built-in operation',)) +! >> SetBufferLineList (indirect) + vim.current.buffer[:] = True:(, TypeError('bad argument type for built-in operation',)) + vim.current.buffer[:] = ["\na", "bc"]:(, error('string cannot contain newlines',)) + >> InsertBufferLines (indirect) +*************** +*** 1075,1081 **** + vim.current.buffer.xxx = True:(, AttributeError('xxx',)) + >> BufferMark + vim.current.buffer.mark(0):(, TypeError('expected bytes() or str() instance, but got int',)) +! vim.current.buffer.mark("abc"):(, ValueError('mark name must be a single character',)) + vim.current.buffer.mark("!"):(, error('invalid mark name',)) + >> BufferRange + vim.current.buffer.range(1, 2, 3):(, TypeError('function takes exactly 2 arguments (3 given)',)) +--- 1078,1084 ---- + vim.current.buffer.xxx = True:(, AttributeError('xxx',)) + >> BufferMark + vim.current.buffer.mark(0):(, TypeError('expected bytes() or str() instance, but got int',)) +! vim.current.buffer.mark("abcM"):(, ValueError('mark name must be a single character',)) + vim.current.buffer.mark("!"):(, error('invalid mark name',)) + >> BufferRange + vim.current.buffer.range(1, 2, 3):(, TypeError('function takes exactly 2 arguments (3 given)',)) +*************** +*** 1095,1101 **** + 3,xx + before + after +! vim.command("throw 'abc'"):(, error('abc',)) + Exe("throw 'def'"):(, error('def',)) + vim.eval("Exe('throw ''ghi''')"):(, error('ghi',)) + vim.eval("Exe('echoerr ''jkl''')"):(, error('Vim(echoerr):jkl',)) +--- 1098,1104 ---- + 3,xx + before + after +! vim.command("throw 'abcN'"):(, error('abcN',)) + Exe("throw 'def'"):(, error('def',)) + vim.eval("Exe('throw ''ghi''')"):(, error('ghi',)) + vim.eval("Exe('echoerr ''jkl''')"):(, error('Vim(echoerr):jkl',)) +*** ../vim-7.3.1232/src/version.c 2013-06-23 14:30:42.000000000 +0200 +--- src/version.c 2013-06-23 14:32:12.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1233, + /**/ + +-- +ARTHUR: Right! Knights! Forward! + ARTHUR leads a charge toward the castle. Various shots of them battling on, + despite being hit by a variety of farm animals. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 6a8140d00c9ca32a384e51fbf417d5a5b4480371 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:31 +0200 Subject: [PATCH 1127/3340] - patchlevel 1234 --- 7.3.1234 | 1283 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1283 insertions(+) create mode 100644 7.3.1234 diff --git a/7.3.1234 b/7.3.1234 new file mode 100644 index 00000000..ac14dda9 --- /dev/null +++ b/7.3.1234 @@ -0,0 +1,1283 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1234 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1234 (after 7.3.1229) +Problem: Python: Strings are not marked for translation. +Solution: Add N_() where appropriate. (ZyX) +Files: src/if_py_both.h + + +*** ../vim-7.3.1233/src/if_py_both.h 2013-06-23 14:37:00.000000000 +0200 +--- src/if_py_both.h 2013-06-23 16:00:03.000000000 +0200 +*************** +*** 37,52 **** + : obj->ob_type->tp_name) + + #define RAISE_NO_EMPTY_KEYS PyErr_SET_STRING(PyExc_ValueError, \ +! "empty keys are not allowed") +! #define RAISE_LOCKED(type) PyErr_SET_VIM(_(type " is locked")) +! #define RAISE_LOCKED_DICTIONARY RAISE_LOCKED("dictionary") +! #define RAISE_LOCKED_LIST RAISE_LOCKED("list") +! #define RAISE_UNDO_FAIL PyErr_SET_VIM("cannot save undo information") +! #define RAISE_LINE_FAIL(act) PyErr_SET_VIM("cannot " act " line") + #define RAISE_KEY_ADD_FAIL(key) \ +! PyErr_VIM_FORMAT("failed to add key '%s' to dictionary", key) + #define RAISE_INVALID_INDEX_TYPE(idx) \ +! PyErr_FORMAT(PyExc_TypeError, "index must be int or slice, not %s", \ + Py_TYPE_NAME(idx)); + + #define INVALID_BUFFER_VALUE ((buf_T *)(-1)) +--- 37,53 ---- + : obj->ob_type->tp_name) + + #define RAISE_NO_EMPTY_KEYS PyErr_SET_STRING(PyExc_ValueError, \ +! N_("empty keys are not allowed")) +! #define RAISE_LOCKED_DICTIONARY PyErr_SET_VIM(N_("dictionary is locked")) +! #define RAISE_LOCKED_LIST PyErr_SET_VIM(N_("list is locked")) +! #define RAISE_UNDO_FAIL PyErr_SET_VIM(N_("cannot save undo information")) +! #define RAISE_DELETE_LINE_FAIL PyErr_SET_VIM(N_("cannot delete line")) +! #define RAISE_INSERT_LINE_FAIL PyErr_SET_VIM(N_("cannot insert line")) +! #define RAISE_REPLACE_LINE_FAIL PyErr_SET_VIM(N_("cannot replace line")) + #define RAISE_KEY_ADD_FAIL(key) \ +! PyErr_VIM_FORMAT(N_("failed to add key '%s' to dictionary"), key) + #define RAISE_INVALID_INDEX_TYPE(idx) \ +! PyErr_FORMAT(PyExc_TypeError, N_("index must be int or slice, not %s"), \ + Py_TYPE_NAME(idx)); + + #define INVALID_BUFFER_VALUE ((buf_T *)(-1)) +*************** +*** 140,148 **** + { + PyErr_FORMAT(PyExc_TypeError, + #if PY_MAJOR_VERSION < 3 +! "expected str() or unicode() instance, but got %s" + #else +! "expected bytes() or str() instance, but got %s" + #endif + , Py_TYPE_NAME(obj)); + return NULL; +--- 141,149 ---- + { + PyErr_FORMAT(PyExc_TypeError, + #if PY_MAJOR_VERSION < 3 +! N_("expected str() or unicode() instance, but got %s") + #else +! N_("expected bytes() or str() instance, but got %s") + #endif + , Py_TYPE_NAME(obj)); + return NULL; +*************** +*** 192,202 **** + { + PyErr_FORMAT(PyExc_TypeError, + #if PY_MAJOR_VERSION < 3 +! "expected int(), long() or something supporting " +! "coercing to long(), but got %s" + #else +! "expected int() or something supporting coercing to int(), " +! "but got %s" + #endif + , Py_TYPE_NAME(obj)); + return -1; +--- 193,203 ---- + { + PyErr_FORMAT(PyExc_TypeError, + #if PY_MAJOR_VERSION < 3 +! N_("expected int(), long() or something supporting " +! "coercing to long(), but got %s") + #else +! N_("expected int() or something supporting coercing to int(), " +! "but got %s") + #endif + , Py_TYPE_NAME(obj)); + return -1; +*************** +*** 207,219 **** + if (*result > INT_MAX) + { + PyErr_SET_STRING(PyExc_OverflowError, +! "value is too large to fit into C int type"); + return -1; + } + else if (*result < INT_MIN) + { + PyErr_SET_STRING(PyExc_OverflowError, +! "value is too small to fit into C int type"); + return -1; + } + } +--- 208,220 ---- + if (*result > INT_MAX) + { + PyErr_SET_STRING(PyExc_OverflowError, +! N_("value is too large to fit into C int type")); + return -1; + } + else if (*result < INT_MIN) + { + PyErr_SET_STRING(PyExc_OverflowError, +! N_("value is too small to fit into C int type")); + return -1; + } + } +*************** +*** 223,229 **** + if (*result <= 0) + { + PyErr_SET_STRING(PyExc_ValueError, +! "number must be greater then zero"); + return -1; + } + } +--- 224,230 ---- + if (*result <= 0) + { + PyErr_SET_STRING(PyExc_ValueError, +! N_("number must be greater then zero")); + return -1; + } + } +*************** +*** 232,238 **** + if (*result < 0) + { + PyErr_SET_STRING(PyExc_ValueError, +! "number must be greater or equal to zero"); + return -1; + } + } +--- 233,239 ---- + if (*result < 0) + { + PyErr_SET_STRING(PyExc_ValueError, +! N_("number must be greater or equal to zero")); + return -1; + } + } +*************** +*** 326,332 **** + if (valObject == NULL) + { + PyErr_SET_STRING(PyExc_AttributeError, +! "can't delete OutputObject attributes"); + return -1; + } + +--- 327,333 ---- + if (valObject == NULL) + { + PyErr_SET_STRING(PyExc_AttributeError, +! N_("can't delete OutputObject attributes")); + return -1; + } + +*************** +*** 337,343 **** + return 0; + } + +! PyErr_FORMAT(PyExc_AttributeError, "invalid attribute: %s", name); + return -1; + } + +--- 338,344 ---- + return 0; + } + +! PyErr_FORMAT(PyExc_AttributeError, N_("invalid attribute: %s"), name); + return -1; + } + +*************** +*** 785,791 **** + + if (our_tv == NULL) + { +! PyErr_SET_VIM("invalid expression"); + return NULL; + } + +--- 786,792 ---- + + if (our_tv == NULL) + { +! PyErr_SET_VIM(N_("invalid expression")); + return NULL; + } + +*************** +*** 836,842 **** + + if (our_tv == NULL) + { +! PyErr_SET_VIM("invalid expression"); + return NULL; + } + +--- 837,843 ---- + + if (our_tv == NULL) + { +! PyErr_SET_VIM(N_("invalid expression")); + return NULL; + } + +*************** +*** 908,914 **** + if (VimTryEnd()) + return NULL; + +! PyErr_SET_VIM("failed to change directory"); + return NULL; + } + +--- 909,915 ---- + if (VimTryEnd()) + return NULL; + +! PyErr_SET_VIM(N_("failed to change directory")); + return NULL; + } + +*************** +*** 1086,1100 **** + if (!PyTuple_Check(find_module_result)) + { + PyErr_FORMAT(PyExc_TypeError, +! "expected 3-tuple as imp.find_module() result, but got %s", + Py_TYPE_NAME(find_module_result)); + return NULL; + } + if (PyTuple_GET_SIZE(find_module_result) != 3) + { + PyErr_FORMAT(PyExc_TypeError, +! "expected 3-tuple as imp.find_module() result, but got " +! "tuple of size %d", + (int) PyTuple_GET_SIZE(find_module_result)); + return NULL; + } +--- 1087,1101 ---- + if (!PyTuple_Check(find_module_result)) + { + PyErr_FORMAT(PyExc_TypeError, +! N_("expected 3-tuple as imp.find_module() result, but got %s"), + Py_TYPE_NAME(find_module_result)); + return NULL; + } + if (PyTuple_GET_SIZE(find_module_result) != 3) + { + PyErr_FORMAT(PyExc_TypeError, +! N_("expected 3-tuple as imp.find_module() result, but got " +! "tuple of size %d"), + (int) PyTuple_GET_SIZE(find_module_result)); + return NULL; + } +*************** +*** 1104,1110 **** + || !(description = PyTuple_GET_ITEM(find_module_result, 2))) + { + PyErr_SET_STRING(PyExc_RuntimeError, +! "internal error: imp.find_module returned tuple with NULL"); + return NULL; + } + +--- 1105,1111 ---- + || !(description = PyTuple_GET_ITEM(find_module_result, 2))) + { + PyErr_SET_STRING(PyExc_RuntimeError, +! N_("internal error: imp.find_module returned tuple with NULL")); + return NULL; + } + +*************** +*** 1476,1482 **** + if (valObject == NULL) + { + PyErr_SET_STRING(PyExc_AttributeError, +! "cannot delete vim.Dictionary attributes"); + return -1; + } + +--- 1477,1483 ---- + if (valObject == NULL) + { + PyErr_SET_STRING(PyExc_AttributeError, +! N_("cannot delete vim.Dictionary attributes")); + return -1; + } + +*************** +*** 1484,1490 **** + { + if (self->dict->dv_lock == VAR_FIXED) + { +! PyErr_SET_STRING(PyExc_TypeError, "cannot modify fixed dictionary"); + return -1; + } + else +--- 1485,1492 ---- + { + if (self->dict->dv_lock == VAR_FIXED) + { +! PyErr_SET_STRING(PyExc_TypeError, +! N_("cannot modify fixed dictionary")); + return -1; + } + else +*************** +*** 1501,1507 **** + } + else + { +! PyErr_FORMAT(PyExc_AttributeError, "cannot set attribute %s", name); + return -1; + } + } +--- 1503,1509 ---- + } + else + { +! PyErr_FORMAT(PyExc_AttributeError, N_("cannot set attribute %s"), name); + return -1; + } + } +*************** +*** 1635,1641 **** + (*dii)->ht->ht_used != (*dii)->ht_used) + { + PyErr_SET_STRING(PyExc_RuntimeError, +! "hashtab changed during iteration"); + return NULL; + } + +--- 1637,1643 ---- + (*dii)->ht->ht_used != (*dii)->ht_used) + { + PyErr_SET_STRING(PyExc_RuntimeError, +! N_("hashtab changed during iteration")); + return NULL; + } + +*************** +*** 1906,1913 **** + Py_DECREF(iterator); + Py_DECREF(fast); + PyErr_FORMAT(PyExc_ValueError, +! "expected sequence element of size 2, " +! "but got sequence of size %d", + PySequence_Fast_GET_SIZE(fast)); + return NULL; + } +--- 1908,1915 ---- + Py_DECREF(iterator); + Py_DECREF(fast); + PyErr_FORMAT(PyExc_ValueError, +! N_("expected sequence element of size 2, " +! "but got sequence of size %d"), + PySequence_Fast_GET_SIZE(fast)); + return NULL; + } +*************** +*** 2150,2156 **** + if (kwargs) + { + PyErr_SET_STRING(PyExc_TypeError, +! "list constructor does not accept keyword arguments"); + return NULL; + } + +--- 2152,2158 ---- + if (kwargs) + { + PyErr_SET_STRING(PyExc_TypeError, +! N_("list constructor does not accept keyword arguments")); + return NULL; + } + +*************** +*** 2205,2218 **** + + if (index >= ListLength(self)) + { +! PyErr_SET_STRING(PyExc_IndexError, "list index out of range"); + return NULL; + } + li = list_find(self->list, (long) index); + if (li == NULL) + { + /* No more suitable format specifications in python-2.3 */ +! PyErr_VIM_FORMAT("internal error: failed to get vim list item %d", + (int) index); + return NULL; + } +--- 2207,2220 ---- + + if (index >= ListLength(self)) + { +! PyErr_SET_STRING(PyExc_IndexError, N_("list index out of range")); + return NULL; + } + li = list_find(self->list, (long) index); + if (li == NULL) + { + /* No more suitable format specifications in python-2.3 */ +! PyErr_VIM_FORMAT(N_("internal error: failed to get vim list item %d"), + (int) index); + return NULL; + } +*************** +*** 2331,2337 **** + } + if (index > length || (index == length && obj == NULL)) + { +! PyErr_SET_STRING(PyExc_IndexError, "list index out of range"); + return -1; + } + +--- 2333,2339 ---- + } + if (index > length || (index == length && obj == NULL)) + { +! PyErr_SET_STRING(PyExc_IndexError, N_("list index out of range")); + return -1; + } + +*************** +*** 2352,2358 **** + if (list_append_tv(l, &tv) == FAIL) + { + clear_tv(&tv); +! PyErr_SET_VIM("failed to add item to list"); + return -1; + } + } +--- 2354,2360 ---- + if (list_append_tv(l, &tv) == FAIL) + { + clear_tv(&tv); +! PyErr_SET_VIM(N_("failed to add item to list")); + return -1; + } + } +*************** +*** 2393,2399 **** + li = list_find(l, (long) first); + if (li == NULL) + { +! PyErr_VIM_FORMAT("internal error: no vim list item %d", (int)first); + return -1; + } + if (last > first) +--- 2395,2402 ---- + li = list_find(l, (long) first); + if (li == NULL) + { +! PyErr_VIM_FORMAT(N_("internal error: no vim list item %d"), +! (int)first); + return -1; + } + if (last > first) +*************** +*** 2426,2432 **** + if (list_insert_tv(l, &v, li) == FAIL) + { + clear_tv(&v); +! PyErr_SET_VIM("internal error: failed to add item to list"); + return -1; + } + clear_tv(&v); +--- 2429,2435 ---- + if (list_insert_tv(l, &v, li) == FAIL) + { + clear_tv(&v); +! PyErr_SET_VIM(N_("internal error: failed to add item to list")); + return -1; + } + clear_tv(&v); +*************** +*** 2478,2484 **** + if (valObject == NULL) + { + PyErr_SET_STRING(PyExc_AttributeError, +! "cannot delete vim.List attributes"); + return -1; + } + +--- 2481,2487 ---- + if (valObject == NULL) + { + PyErr_SET_STRING(PyExc_AttributeError, +! N_("cannot delete vim.List attributes")); + return -1; + } + +*************** +*** 2486,2492 **** + { + if (self->list->lv_lock == VAR_FIXED) + { +! PyErr_SET_STRING(PyExc_TypeError, "cannot modify fixed list"); + return -1; + } + else +--- 2489,2495 ---- + { + if (self->list->lv_lock == VAR_FIXED) + { +! PyErr_SET_STRING(PyExc_TypeError, N_("cannot modify fixed list")); + return -1; + } + else +*************** +*** 2503,2509 **** + } + else + { +! PyErr_FORMAT(PyExc_AttributeError, "cannot set attribute %s", name); + return -1; + } + } +--- 2506,2512 ---- + } + else + { +! PyErr_FORMAT(PyExc_AttributeError, N_("cannot set attribute %s"), name); + return -1; + } + } +*************** +*** 2539,2545 **** + if (!translated_function_exists(name)) + { + PyErr_FORMAT(PyExc_ValueError, +! "unnamed function %s does not exist", name); + return NULL; + } + self->name = vim_strsave(name); +--- 2542,2548 ---- + if (!translated_function_exists(name)) + { + PyErr_FORMAT(PyExc_ValueError, +! N_("unnamed function %s does not exist"), name); + return NULL; + } + self->name = vim_strsave(name); +*************** +*** 2550,2556 **** + vim_strchr(name, AUTOLOAD_CHAR) == NULL)) + == NULL) + { +! PyErr_FORMAT(PyExc_ValueError, "function %s does not exist", name); + return NULL; + } + +--- 2553,2560 ---- + vim_strchr(name, AUTOLOAD_CHAR) == NULL)) + == NULL) + { +! PyErr_FORMAT(PyExc_ValueError, +! N_("function %s does not exist"), name); + return NULL; + } + +*************** +*** 2566,2572 **** + if (kwargs) + { + PyErr_SET_STRING(PyExc_TypeError, +! "function constructor does not accept keyword arguments"); + return NULL; + } + +--- 2570,2576 ---- + if (kwargs) + { + PyErr_SET_STRING(PyExc_TypeError, +! N_("function constructor does not accept keyword arguments")); + return NULL; + } + +*************** +*** 2643,2649 **** + else if (error != OK) + { + ret = NULL; +! PyErr_VIM_FORMAT("failed to run function %s", (char *)name); + } + else + ret = ConvertToPyObject(&rettv); +--- 2647,2653 ---- + else if (error != OK) + { + ret = NULL; +! PyErr_VIM_FORMAT(N_("failed to run function %s"), (char *)name); + } + else + ret = ConvertToPyObject(&rettv); +*************** +*** 2796,2808 **** + else + { + PyErr_SET_STRING(PyExc_RuntimeError, +! "unable to get option value"); + return NULL; + } + } + else + { +! PyErr_SET_VIM("internal error: unknown option type"); + return NULL; + } + } +--- 2800,2812 ---- + else + { + PyErr_SET_STRING(PyExc_RuntimeError, +! N_("unable to get option value")); + return NULL; + } + } + else + { +! PyErr_SET_VIM(N_("internal error: unknown option type")); + return NULL; + } + } +*************** +*** 2845,2851 **** + { + if (VimTryEnd()) + return -1; +! PyErr_SET_VIM("problem while switching windows"); + return -1; + } + set_ret = set_option_value_err(key, numval, stringval, opt_flags); +--- 2849,2855 ---- + { + if (VimTryEnd()) + return -1; +! PyErr_SET_VIM(N_("problem while switching windows")); + return -1; + } + set_ret = set_option_value_err(key, numval, stringval, opt_flags); +*************** +*** 2902,2916 **** + if (self->opt_type == SREQ_GLOBAL) + { + PyErr_FORMAT(PyExc_ValueError, +! "unable to unset global option %s", key); + Py_XDECREF(todecref); + return -1; + } + else if (!(flags & SOPT_GLOBAL)) + { + PyErr_FORMAT(PyExc_ValueError, +! "unable to unset option %s " +! "which does not have global value", key); + Py_XDECREF(todecref); + return -1; + } +--- 2906,2920 ---- + if (self->opt_type == SREQ_GLOBAL) + { + PyErr_FORMAT(PyExc_ValueError, +! N_("unable to unset global option %s"), key); + Py_XDECREF(todecref); + return -1; + } + else if (!(flags & SOPT_GLOBAL)) + { + PyErr_FORMAT(PyExc_ValueError, +! N_("unable to unset option %s " +! "which does not have global value"), key); + Py_XDECREF(todecref); + return -1; + } +*************** +*** 2988,2994 **** + { + if (self->tab == INVALID_TABPAGE_VALUE) + { +! PyErr_SET_VIM("attempt to refer to deleted tab page"); + return -1; + } + +--- 2992,2998 ---- + { + if (self->tab == INVALID_TABPAGE_VALUE) + { +! PyErr_SET_VIM(N_("attempt to refer to deleted tab page")); + return -1; + } + +*************** +*** 3132,3138 **** + if (n == 0) + return TabPageNew(tp); + +! PyErr_SET_STRING(PyExc_IndexError, "no such tab page"); + return NULL; + } + +--- 3136,3142 ---- + if (n == 0) + return TabPageNew(tp); + +! PyErr_SET_STRING(PyExc_IndexError, N_("no such tab page")); + return NULL; + } + +*************** +*** 3154,3160 **** + { + if (self->win == INVALID_WINDOW_VALUE) + { +! PyErr_SET_VIM("attempt to refer to deleted window"); + return -1; + } + +--- 3158,3164 ---- + { + if (self->win == INVALID_WINDOW_VALUE) + { +! PyErr_SET_VIM(N_("attempt to refer to deleted window")); + return -1; + } + +*************** +*** 3320,3326 **** + + if (strcmp(name, "buffer") == 0) + { +! PyErr_SET_STRING(PyExc_TypeError, "readonly attribute: buffer"); + return -1; + } + else if (strcmp(name, "cursor") == 0) +--- 3324,3330 ---- + + if (strcmp(name, "buffer") == 0) + { +! PyErr_SET_STRING(PyExc_TypeError, N_("readonly attribute: buffer")); + return -1; + } + else if (strcmp(name, "cursor") == 0) +*************** +*** 3333,3339 **** + + if (lnum <= 0 || lnum > self->win->w_buffer->b_ml.ml_line_count) + { +! PyErr_SET_VIM("cursor position outside buffer"); + return -1; + } + +--- 3337,3343 ---- + + if (lnum <= 0 || lnum > self->win->w_buffer->b_ml.ml_line_count) + { +! PyErr_SET_VIM(N_("cursor position outside buffer")); + return -1; + } + +*************** +*** 3496,3502 **** + if (n == 0) + return WindowNew(w, self->tabObject? self->tabObject->tab: curtab); + +! PyErr_SET_STRING(PyExc_IndexError, "no such window"); + return NULL; + } + +--- 3500,3506 ---- + if (n == 0) + return WindowNew(w, self->tabObject? self->tabObject->tab: curtab); + +! PyErr_SET_STRING(PyExc_IndexError, N_("no such window")); + return NULL; + } + +*************** +*** 3550,3556 **** + --len; + else + { +! PyErr_SET_VIM("string cannot contain newlines"); + Py_XDECREF(bytes); + return NULL; + } +--- 3554,3560 ---- + --len; + else + { +! PyErr_SET_VIM(N_("string cannot contain newlines")); + Py_XDECREF(bytes); + return NULL; + } +*************** +*** 3688,3694 **** + if (u_savedel((linenr_T)n, 1L) == FAIL) + RAISE_UNDO_FAIL; + else if (ml_delete((linenr_T)n, FALSE) == FAIL) +! RAISE_LINE_FAIL("delete"); + else + { + if (buf == savebuf) +--- 3692,3698 ---- + if (u_savedel((linenr_T)n, 1L) == FAIL) + RAISE_UNDO_FAIL; + else if (ml_delete((linenr_T)n, FALSE) == FAIL) +! RAISE_DELETE_LINE_FAIL; + else + { + if (buf == savebuf) +*************** +*** 3727,3733 **** + } + else if (ml_replace((linenr_T)n, (char_u *)save, FALSE) == FAIL) + { +! RAISE_LINE_FAIL("replace"); + vim_free(save); + } + else +--- 3731,3737 ---- + } + else if (ml_replace((linenr_T)n, (char_u *)save, FALSE) == FAIL) + { +! RAISE_REPLACE_LINE_FAIL; + vim_free(save); + } + else +*************** +*** 3794,3800 **** + { + if (ml_delete((linenr_T)lo, FALSE) == FAIL) + { +! RAISE_LINE_FAIL("delete"); + break; + } + } +--- 3798,3804 ---- + { + if (ml_delete((linenr_T)lo, FALSE) == FAIL) + { +! RAISE_DELETE_LINE_FAIL; + break; + } + } +*************** +*** 3866,3872 **** + for (i = 0; i < old_len - new_len; ++i) + if (ml_delete((linenr_T)lo, FALSE) == FAIL) + { +! RAISE_LINE_FAIL("delete"); + break; + } + extra -= i; +--- 3870,3876 ---- + for (i = 0; i < old_len - new_len; ++i) + if (ml_delete((linenr_T)lo, FALSE) == FAIL) + { +! RAISE_DELETE_LINE_FAIL; + break; + } + extra -= i; +*************** +*** 3882,3888 **** + if (ml_replace((linenr_T)(lo+i), (char_u *)array[i], FALSE) + == FAIL) + { +! RAISE_LINE_FAIL("replace"); + break; + } + } +--- 3886,3892 ---- + if (ml_replace((linenr_T)(lo+i), (char_u *)array[i], FALSE) + == FAIL) + { +! RAISE_REPLACE_LINE_FAIL; + break; + } + } +*************** +*** 3900,3906 **** + if (ml_append((linenr_T)(lo + i - 1), + (char_u *)array[i], 0, FALSE) == FAIL) + { +! RAISE_LINE_FAIL("insert"); + break; + } + vim_free(array[i]); +--- 3904,3910 ---- + if (ml_append((linenr_T)(lo + i - 1), + (char_u *)array[i], 0, FALSE) == FAIL) + { +! RAISE_INSERT_LINE_FAIL; + break; + } + vim_free(array[i]); +*************** +*** 3979,3985 **** + if (u_save((linenr_T)n, (linenr_T)(n+1)) == FAIL) + RAISE_UNDO_FAIL; + else if (ml_append((linenr_T)n, (char_u *)str, 0, FALSE) == FAIL) +! RAISE_LINE_FAIL("insert"); + else + appended_lines_mark((linenr_T)n, 1L); + +--- 3983,3989 ---- + if (u_save((linenr_T)n, (linenr_T)(n+1)) == FAIL) + RAISE_UNDO_FAIL; + else if (ml_append((linenr_T)n, (char_u *)str, 0, FALSE) == FAIL) +! RAISE_INSERT_LINE_FAIL; + else + appended_lines_mark((linenr_T)n, 1L); + +*************** +*** 4036,4042 **** + if (ml_append((linenr_T)(n + i), + (char_u *)array[i], 0, FALSE) == FAIL) + { +! RAISE_LINE_FAIL("insert"); + + /* Free the rest of the lines */ + while (i < size) +--- 4040,4046 ---- + if (ml_append((linenr_T)(n + i), + (char_u *)array[i], 0, FALSE) == FAIL) + { +! RAISE_INSERT_LINE_FAIL; + + /* Free the rest of the lines */ + while (i < size) +*************** +*** 4089,4095 **** + { + if (self->buf == INVALID_BUFFER_VALUE) + { +! PyErr_SET_VIM("attempt to refer to deleted buffer"); + return -1; + } + +--- 4093,4099 ---- + { + if (self->buf == INVALID_BUFFER_VALUE) + { +! PyErr_SET_VIM(N_("attempt to refer to deleted buffer")); + return -1; + } + +*************** +*** 4110,4116 **** + + if (n < 0 || n > end - start) + { +! PyErr_SET_STRING(PyExc_IndexError, "line number out of range"); + return NULL; + } + +--- 4114,4120 ---- + + if (n < 0 || n > end - start) + { +! PyErr_SET_STRING(PyExc_IndexError, N_("line number out of range")); + return NULL; + } + +*************** +*** 4166,4172 **** + + if (n < 0 || n > end - start) + { +! PyErr_SET_STRING(PyExc_IndexError, "line number out of range"); + return -1; + } + +--- 4170,4176 ---- + + if (n < 0 || n > end - start) + { +! PyErr_SET_STRING(PyExc_IndexError, N_("line number out of range")); + return -1; + } + +*************** +*** 4250,4256 **** + + if (n < 0 || n > max) + { +! PyErr_SET_STRING(PyExc_IndexError, "line number out of range"); + return NULL; + } + +--- 4254,4260 ---- + + if (n < 0 || n > max) + { +! PyErr_SET_STRING(PyExc_IndexError, N_("line number out of range")); + return NULL; + } + +*************** +*** 4533,4539 **** + + if (ren_ret == FAIL) + { +! PyErr_SET_VIM("failed to rename buffer"); + return -1; + } + return 0; +--- 4537,4543 ---- + + if (ren_ret == FAIL) + { +! PyErr_SET_VIM(N_("failed to rename buffer")); + return -1; + } + return 0; +*************** +*** 4569,4575 **** + if (pmark[0] == '\0' || pmark[1] != '\0') + { + PyErr_SET_STRING(PyExc_ValueError, +! "mark name must be a single character"); + Py_XDECREF(todecref); + return NULL; + } +--- 4573,4579 ---- + if (pmark[0] == '\0' || pmark[1] != '\0') + { + PyErr_SET_STRING(PyExc_ValueError, +! N_("mark name must be a single character")); + Py_XDECREF(todecref); + return NULL; + } +*************** +*** 4587,4593 **** + + if (posp == NULL) + { +! PyErr_SET_VIM("invalid mark name"); + return NULL; + } + +--- 4591,4597 ---- + + if (posp == NULL) + { +! PyErr_SET_VIM(N_("invalid mark name")); + return NULL; + } + +*************** +*** 4812,4818 **** + if (valObject->ob_type != &BufferType) + { + PyErr_FORMAT(PyExc_TypeError, +! "expected vim.Buffer object, but got %s", + Py_TYPE_NAME(valObject)); + return -1; + } +--- 4816,4822 ---- + if (valObject->ob_type != &BufferType) + { + PyErr_FORMAT(PyExc_TypeError, +! N_("expected vim.Buffer object, but got %s"), + Py_TYPE_NAME(valObject)); + return -1; + } +*************** +*** 4826,4832 **** + { + if (VimTryEnd()) + return -1; +! PyErr_VIM_FORMAT("failed to switch to buffer %d", count); + return -1; + } + +--- 4830,4836 ---- + { + if (VimTryEnd()) + return -1; +! PyErr_VIM_FORMAT(N_("failed to switch to buffer %d"), count); + return -1; + } + +*************** +*** 4839,4845 **** + if (valObject->ob_type != &WindowType) + { + PyErr_FORMAT(PyExc_TypeError, +! "expected vim.Window object, but got %s", + Py_TYPE_NAME(valObject)); + return -1; + } +--- 4843,4849 ---- + if (valObject->ob_type != &WindowType) + { + PyErr_FORMAT(PyExc_TypeError, +! N_("expected vim.Window object, but got %s"), + Py_TYPE_NAME(valObject)); + return -1; + } +*************** +*** 4851,4857 **** + if (!count) + { + PyErr_SET_STRING(PyExc_ValueError, +! "failed to find window in the current tab page"); + return -1; + } + +--- 4855,4861 ---- + if (!count) + { + PyErr_SET_STRING(PyExc_ValueError, +! N_("failed to find window in the current tab page")); + return -1; + } + +*************** +*** 4862,4868 **** + if (VimTryEnd()) + return -1; + PyErr_SET_STRING(PyExc_RuntimeError, +! "did not switch to the specified window"); + return -1; + } + +--- 4866,4872 ---- + if (VimTryEnd()) + return -1; + PyErr_SET_STRING(PyExc_RuntimeError, +! N_("did not switch to the specified window")); + return -1; + } + +*************** +*** 4873,4879 **** + if (valObject->ob_type != &TabPageType) + { + PyErr_FORMAT(PyExc_TypeError, +! "expected vim.TabPage object, but got %s", + Py_TYPE_NAME(valObject)); + return -1; + } +--- 4877,4883 ---- + if (valObject->ob_type != &TabPageType) + { + PyErr_FORMAT(PyExc_TypeError, +! N_("expected vim.TabPage object, but got %s"), + Py_TYPE_NAME(valObject)); + return -1; + } +*************** +*** 4888,4894 **** + if (VimTryEnd()) + return -1; + PyErr_SET_STRING(PyExc_RuntimeError, +! "did not switch to the specified tab page"); + return -1; + } + +--- 4892,4898 ---- + if (VimTryEnd()) + return -1; + PyErr_SET_STRING(PyExc_RuntimeError, +! N_("did not switch to the specified tab page")); + return -1; + } + +*************** +*** 5371,5377 **** + else + { + PyErr_FORMAT(PyExc_TypeError, +! "unable to convert %s to vim dictionary", + Py_TYPE_NAME(obj)); + ret = -1; + } +--- 5375,5381 ---- + else + { + PyErr_FORMAT(PyExc_TypeError, +! N_("unable to convert %s to vim dictionary"), + Py_TYPE_NAME(obj)); + ret = -1; + } +*************** +*** 5498,5504 **** + else + { + PyErr_FORMAT(PyExc_TypeError, +! "unable to convert %s to vim structure", + Py_TYPE_NAME(obj)); + return -1; + } +--- 5502,5508 ---- + else + { + PyErr_FORMAT(PyExc_TypeError, +! N_("unable to convert %s to vim structure"), + Py_TYPE_NAME(obj)); + return -1; + } +*************** +*** 5510,5516 **** + { + if (tv == NULL) + { +! PyErr_SET_VIM("internal error: NULL reference passed"); + return NULL; + } + switch (tv->v_type) +--- 5514,5520 ---- + { + if (tv == NULL) + { +! PyErr_SET_VIM(N_("internal error: NULL reference passed")); + return NULL; + } + switch (tv->v_type) +*************** +*** 5535,5541 **** + Py_INCREF(Py_None); + return Py_None; + default: +! PyErr_SET_VIM("internal error: invalid value type"); + return NULL; + } + } +--- 5539,5545 ---- + Py_INCREF(Py_None); + return Py_None; + default: +! PyErr_SET_VIM(N_("internal error: invalid value type")); + return NULL; + } + } +*** ../vim-7.3.1233/src/version.c 2013-06-23 14:37:00.000000000 +0200 +--- src/version.c 2013-06-23 14:41:34.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1234, + /**/ + +-- + Bravely bold Sir Robin, rode forth from Camelot, + He was not afraid to die, Oh Brave Sir Robin, + He was not at all afraid to be killed in nasty ways + Brave, brave, brave, brave Sir Robin. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7504542e7324e6bdb739bd095962cb9085030149 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:32 +0200 Subject: [PATCH 1128/3340] - patchlevel 1235 --- 7.3.1235 | 63 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 7.3.1235 diff --git a/7.3.1235 b/7.3.1235 new file mode 100644 index 00000000..7ccde9fd --- /dev/null +++ b/7.3.1235 @@ -0,0 +1,63 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1235 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1235 +Problem: In insert mode CTRL-] is not inserted, on the command-line it is. +Solution: Don't insert CTRL-] on the command line. (Yukihiro Nakadaira) +Files: src/ex_getln.c + + +*** ../vim-7.3.1234/src/ex_getln.c 2013-06-15 16:31:41.000000000 +0200 +--- src/ex_getln.c 2013-06-23 16:12:03.000000000 +0200 +*************** +*** 1700,1712 **** + * We come here if we have a normal character. + */ + +! if (do_abbr && (IS_SPECIAL(c) || !vim_iswordc(c)) && ccheck_abbr( + #ifdef FEAT_MBYTE + /* Add ABBR_OFF for characters above 0x100, this is + * what check_abbr() expects. */ + (has_mbyte && c >= 0x100) ? (c + ABBR_OFF) : + #endif +! c)) + goto cmdline_changed; + + /* +--- 1700,1712 ---- + * We come here if we have a normal character. + */ + +! if (do_abbr && (IS_SPECIAL(c) || !vim_iswordc(c)) && (ccheck_abbr( + #ifdef FEAT_MBYTE + /* Add ABBR_OFF for characters above 0x100, this is + * what check_abbr() expects. */ + (has_mbyte && c >= 0x100) ? (c + ABBR_OFF) : + #endif +! c) || c == Ctrl_RSB)) + goto cmdline_changed; + + /* +*** ../vim-7.3.1234/src/version.c 2013-06-23 16:04:04.000000000 +0200 +--- src/version.c 2013-06-23 16:12:50.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1235, + /**/ + +-- +Error:015 - Unable to exit Windows. Try the door. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0ee68529903151ff760010a1e53e85ff2da6481e Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:33 +0200 Subject: [PATCH 1129/3340] - patchlevel 1236 --- 7.3.1236 | 2992 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 2992 insertions(+) create mode 100644 7.3.1236 diff --git a/7.3.1236 b/7.3.1236 new file mode 100644 index 00000000..8b5182f3 --- /dev/null +++ b/7.3.1236 @@ -0,0 +1,2992 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1236 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1236 +Problem: Python: WindowSetattr() missing support for NUMBER_UNSIGNED. +Solution: Add NUMBER_UNSIGNED, add more tests. Various fixes. (ZyX) +Files: src/if_py_both.h, src/if_python3.c, src/if_python.c, + src/testdir/pythonx/failing.py, + src/testdir/pythonx/failing_import.py, src/testdir/test86.in, + src/testdir/test86.ok, src/testdir/test87.in, + src/testdir/test87.ok, src/testdir/pythonx/topmodule/__init__.py, + src/testdir/pythonx/topmodule/submodule/__init__.py, + src/testdir/pythonx/topmodule/submodule/subsubmodule/__init__.py, + src/testdir/pythonx/topmodule/submodule/subsubmodule/subsubsubmodule.py + + +*** ../vim-7.3.1235/src/if_py_both.h 2013-06-23 16:04:04.000000000 +0200 +--- src/if_py_both.h 2013-06-23 16:27:37.000000000 +0200 +*************** +*** 1611,1617 **** + + ret = (rObj == Py_True); + +! Py_DECREF(Py_True); + + return ret; + } +--- 1611,1617 ---- + + ret = (rObj == Py_True); + +! Py_DECREF(rObj); + + return ret; + } +*************** +*** 1910,1916 **** + PyErr_FORMAT(PyExc_ValueError, + N_("expected sequence element of size 2, " + "but got sequence of size %d"), +! PySequence_Fast_GET_SIZE(fast)); + return NULL; + } + +--- 1910,1916 ---- + PyErr_FORMAT(PyExc_ValueError, + N_("expected sequence element of size 2, " + "but got sequence of size %d"), +! (int) PySequence_Fast_GET_SIZE(fast)); + return NULL; + } + +*************** +*** 2435,2440 **** +--- 2435,2444 ---- + clear_tv(&v); + } + Py_DECREF(iterator); ++ ++ if (PyErr_Occurred()) ++ return -1; ++ + return 0; + } + +*************** +*** 3361,3367 **** + long height; + win_T *savewin; + +! if (NumberToLong(valObject, &height, NUMBER_INT)) + return -1; + + #ifdef FEAT_GUI +--- 3365,3371 ---- + long height; + win_T *savewin; + +! if (NumberToLong(valObject, &height, NUMBER_INT|NUMBER_UNSIGNED)) + return -1; + + #ifdef FEAT_GUI +*************** +*** 3384,3390 **** + long width; + win_T *savewin; + +! if (NumberToLong(valObject, &width, NUMBER_INT)) + return -1; + + #ifdef FEAT_GUI +--- 3388,3394 ---- + long width; + win_T *savewin; + +! if (NumberToLong(valObject, &width, NUMBER_INT|NUMBER_UNSIGNED)) + return -1; + + #ifdef FEAT_GUI +*************** +*** 3518,3524 **** + char *str; + char *save; + PyObject *bytes = NULL; +! Py_ssize_t len; + PyInt i; + char *p; + +--- 3522,3528 ---- + char *str; + char *save; + PyObject *bytes = NULL; +! Py_ssize_t len = 0; + PyInt i; + char *p; + +*************** +*** 5483,5488 **** +--- 5487,5493 ---- + #endif + else if (PyObject_HasAttrString(obj, "keys")) + return convert_dl(obj, tv, pymap_to_tv, lookup_dict); ++ /* PyObject_GetIter can create built-in iterator for any sequence object */ + else if (PyIter_Check(obj) || PySequence_Check(obj)) + return convert_dl(obj, tv, pyseq_to_tv, lookup_dict); + else if (PyMapping_Check(obj)) +*************** +*** 5930,5940 **** + {"_Loader", (PyObject *)&LoaderType}, + }; + +- typedef int (*object_adder)(PyObject *, const char *, PyObject *); +- typedef PyObject *(*attr_getter)(PyObject *, const char *); +- + #define ADD_OBJECT(m, name, obj) \ +! if (add_object(m, name, obj)) \ + return -1; + + #define ADD_CHECKED_OBJECT(m, name, obj) \ +--- 5935,5942 ---- + {"_Loader", (PyObject *)&LoaderType}, + }; + + #define ADD_OBJECT(m, name, obj) \ +! if (PyModule_AddObject(m, name, obj)) \ + return -1; + + #define ADD_CHECKED_OBJECT(m, name, obj) \ +*************** +*** 5946,5952 **** + } + + static int +! populate_module(PyObject *m, object_adder add_object, attr_getter get_attr) + { + int i; + PyObject *other_module; +--- 5948,5954 ---- + } + + static int +! populate_module(PyObject *m) + { + int i; + PyObject *other_module; +*************** +*** 5990,5996 **** + if (!(py_chdir = PyObject_GetAttrString(other_module, "chdir"))) + return -1; + ADD_OBJECT(m, "_chdir", py_chdir); +! if (!(attr = get_attr(m, "chdir"))) + return -1; + if (PyObject_SetAttrString(other_module, "chdir", attr)) + { +--- 5992,5998 ---- + if (!(py_chdir = PyObject_GetAttrString(other_module, "chdir"))) + return -1; + ADD_OBJECT(m, "_chdir", py_chdir); +! if (!(attr = PyObject_GetAttrString(m, "chdir"))) + return -1; + if (PyObject_SetAttrString(other_module, "chdir", attr)) + { +*************** +*** 6002,6008 **** + if ((py_fchdir = PyObject_GetAttrString(other_module, "fchdir"))) + { + ADD_OBJECT(m, "_fchdir", py_fchdir); +! if (!(attr = get_attr(m, "fchdir"))) + return -1; + if (PyObject_SetAttrString(other_module, "fchdir", attr)) + { +--- 6004,6010 ---- + if ((py_fchdir = PyObject_GetAttrString(other_module, "fchdir"))) + { + ADD_OBJECT(m, "_fchdir", py_fchdir); +! if (!(attr = PyObject_GetAttrString(m, "fchdir"))) + return -1; + if (PyObject_SetAttrString(other_module, "fchdir", attr)) + { +*** ../vim-7.3.1235/src/if_python3.c 2013-06-23 14:16:53.000000000 +0200 +--- src/if_python3.c 2013-06-23 16:26:40.000000000 +0200 +*************** +*** 1623,1629 **** + if ((vim_module = PyModule_Create(&vimmodule)) == NULL) + return NULL; + +! if (populate_module(vim_module, PyModule_AddObject, PyObject_GetAttrString)) + return NULL; + + if (init_sys_path()) +--- 1623,1629 ---- + if ((vim_module = PyModule_Create(&vimmodule)) == NULL) + return NULL; + +! if (populate_module(vim_module)) + return NULL; + + if (init_sys_path()) +*** ../vim-7.3.1235/src/if_python.c 2013-06-23 14:16:53.000000000 +0200 +--- src/if_python.c 2013-06-23 16:26:40.000000000 +0200 +*************** +*** 1404,1411 **** + vim_module = Py_InitModule4("vim", VimMethods, (char *)NULL, + (PyObject *)NULL, PYTHON_API_VERSION); + +! if (populate_module(vim_module, PyModule_AddObject, +! PyObject_GetAttrString)) + return -1; + + if (init_sys_path()) +--- 1404,1410 ---- + vim_module = Py_InitModule4("vim", VimMethods, (char *)NULL, + (PyObject *)NULL, PYTHON_API_VERSION); + +! if (populate_module(vim_module)) + return -1; + + if (init_sys_path()) +*** ../vim-7.3.1235/src/testdir/pythonx/failing.py 2013-06-23 16:35:21.000000000 +0200 +--- src/testdir/pythonx/failing.py 2013-06-23 16:22:10.000000000 +0200 +*************** +*** 0 **** +--- 1 ---- ++ raise NotImplementedError +*** ../vim-7.3.1235/src/testdir/pythonx/failing_import.py 2013-06-23 16:35:21.000000000 +0200 +--- src/testdir/pythonx/failing_import.py 2013-06-23 16:22:10.000000000 +0200 +*************** +*** 0 **** +--- 1 ---- ++ raise ImportError +*** ../vim-7.3.1235/src/testdir/test86.in 2013-06-23 14:37:00.000000000 +0200 +--- src/testdir/test86.in 2013-06-23 16:26:40.000000000 +0200 +*************** +*** 216,221 **** +--- 216,222 ---- + :let messages=[] + :delfunction DictNew + py < -1: + msg = msg.replace('TypeError:(\'iteration over non-sequence\',)', + 'TypeError:("\'NoneType\' object is not iterable",)') + if expr == 'fd(self=[])': + # HACK: PyMapping_Check changed meaning + msg = msg.replace('AttributeError:(\'keys\',)', +! 'TypeError:(\'unable to convert object to vim dictionary\',)') + cb.append(expr + ':' + msg) + else: + cb.append(expr + ':NOT FAILED') +--- 881,896 ---- + if expr.find('None') > -1: + msg = msg.replace('TypeError:(\'iteration over non-sequence\',)', + 'TypeError:("\'NoneType\' object is not iterable",)') ++ if expr.find('FailingNumber') > -1: ++ msg = msg.replace(', not \'FailingNumber\'', '').replace('"', '\'') ++ msg = msg.replace('TypeError:(\'iteration over non-sequence\',)', ++ 'TypeError:("\'FailingNumber\' object is not iterable",)') ++ if msg.find('(\'\'') > -1 or msg.find('(\'can\'t') > -1: ++ msg = msg.replace('(\'', '("').replace('\',)', '",)') + if expr == 'fd(self=[])': + # HACK: PyMapping_Check changed meaning + msg = msg.replace('AttributeError:(\'keys\',)', +! 'TypeError:(\'unable to convert list to vim dictionary\',)') + cb.append(expr + ':' + msg) + else: + cb.append(expr + ':NOT FAILED') +*************** +*** 942,947 **** +--- 949,955 ---- + '{u"": 1}', # Same, but with unicode object + 'FailingMapping()', # + 'FailingMappingKey()', # ++ 'FailingNumber()', # + )) + + def convertfrompymapping_test(expr): +*************** +*** 956,1021 **** + 'FailingIterNext()', + )) + + class FailingTrue(object): + def __nonzero__(self): +! raise NotImplementedError + + class FailingIter(object): + def __iter__(self): +! raise NotImplementedError + + class FailingIterNext(object): + def __iter__(self): + return self + + def next(self): +! raise NotImplementedError + + class FailingMappingKey(object): + def __getitem__(self, item): +! raise NotImplementedError + + def keys(self): + return list("abcH") + + class FailingMapping(object): + def __getitem__(self): +! raise NotImplementedError + + def keys(self): +! raise NotImplementedError + + class FailingList(list): + def __getitem__(self, idx): + if i == 2: +! raise NotImplementedError + else: + return super(FailingList, self).__getitem__(idx) + + cb.append("> Output") + cb.append(">> OutputSetattr") + ee('del sys.stdout.softspace') +! ee('sys.stdout.softspace = []') + ee('sys.stdout.attr = None') + cb.append(">> OutputWrite") + ee('sys.stdout.write(None)') + cb.append(">> OutputWriteLines") + ee('sys.stdout.writelines(None)') + ee('sys.stdout.writelines([1])') +! #iter_test('sys.stdout.writelines(%s)') + cb.append("> VimCommand") +! ee('vim.command(1)') + #! Not checked: vim->python exceptions translating: checked later + cb.append("> VimToPython") + #! Not checked: everything: needs errors in internal python functions + cb.append("> VimEval") +! ee('vim.eval(1)') + #! Not checked: everything: needs errors in internal python functions + cb.append("> VimEvalPy") +! ee('vim.bindeval(1)') + #! Not checked: vim->python exceptions translating: checked later + cb.append("> VimStrwidth") +! ee('vim.strwidth(1)') + cb.append("> Dictionary") + cb.append(">> DictionaryConstructor") + ee('vim.Dictionary("abcI")') +--- 964,1067 ---- + 'FailingIterNext()', + )) + ++ def number_test(expr, natural=False, unsigned=False): ++ if natural: ++ unsigned = True ++ return subexpr_test(expr, 'NumberToLong', ( ++ '[]', ++ 'None', ++ ) + (unsigned and ('-1',) or ()) ++ + (natural and ('0',) or ())) ++ + class FailingTrue(object): + def __nonzero__(self): +! raise NotImplementedError('bool') + + class FailingIter(object): + def __iter__(self): +! raise NotImplementedError('iter') + + class FailingIterNext(object): + def __iter__(self): + return self + + def next(self): +! raise NotImplementedError('next') + + class FailingMappingKey(object): + def __getitem__(self, item): +! raise NotImplementedError('getitem:mappingkey') + + def keys(self): + return list("abcH") + + class FailingMapping(object): + def __getitem__(self): +! raise NotImplementedError('getitem:mapping') + + def keys(self): +! raise NotImplementedError('keys') + + class FailingList(list): + def __getitem__(self, idx): + if i == 2: +! raise NotImplementedError('getitem:list') + else: + return super(FailingList, self).__getitem__(idx) + ++ class NoArgsCall(object): ++ def __call__(self): ++ pass ++ ++ class FailingCall(object): ++ def __call__(self, path): ++ raise NotImplementedError('call') ++ ++ class FailingNumber(object): ++ def __int__(self): ++ raise NotImplementedError('int') ++ + cb.append("> Output") + cb.append(">> OutputSetattr") + ee('del sys.stdout.softspace') +! number_test('sys.stdout.softspace = %s', unsigned=True) +! number_test('sys.stderr.softspace = %s', unsigned=True) + ee('sys.stdout.attr = None') + cb.append(">> OutputWrite") + ee('sys.stdout.write(None)') + cb.append(">> OutputWriteLines") + ee('sys.stdout.writelines(None)') + ee('sys.stdout.writelines([1])') +! iter_test('sys.stdout.writelines(%s)') + cb.append("> VimCommand") +! stringtochars_test('vim.command(%s)') +! ee('vim.command("", 2)') + #! Not checked: vim->python exceptions translating: checked later + cb.append("> VimToPython") + #! Not checked: everything: needs errors in internal python functions + cb.append("> VimEval") +! stringtochars_test('vim.eval(%s)') +! ee('vim.eval("", FailingTrue())') + #! Not checked: everything: needs errors in internal python functions + cb.append("> VimEvalPy") +! stringtochars_test('vim.bindeval(%s)') +! ee('vim.eval("", 2)') + #! Not checked: vim->python exceptions translating: checked later + cb.append("> VimStrwidth") +! stringtochars_test('vim.strwidth(%s)') +! cb.append("> VimForeachRTP") +! ee('vim.foreach_rtp(None)') +! ee('vim.foreach_rtp(NoArgsCall())') +! ee('vim.foreach_rtp(FailingCall())') +! ee('vim.foreach_rtp(int, 2)') +! cb.append('> import') +! old_rtp = vim.options['rtp'] +! vim.options['rtp'] = os.getcwd().replace(',', '\\,').replace('\\', '\\\\') +! ee('import xxx_no_such_module_xxx') +! ee('import failing_import') +! ee('import failing') +! vim.options['rtp'] = old_rtp +! del old_rtp + cb.append("> Dictionary") + cb.append(">> DictionaryConstructor") + ee('vim.Dictionary("abcI")') +*************** +*** 1043,1049 **** + cb.append(">>> iter") + ee('d.update(FailingMapping())') + ee('d.update([FailingIterNext()])') +! #iter_test('d.update(%s)') + convertfrompyobject_test('d.update(%s)') + stringtochars_test('d.update(((%s, 0),))') + convertfrompyobject_test('d.update((("a", %s),))') +--- 1089,1095 ---- + cb.append(">>> iter") + ee('d.update(FailingMapping())') + ee('d.update([FailingIterNext()])') +! iter_test('d.update(%s)') + convertfrompyobject_test('d.update(%s)') + stringtochars_test('d.update(((%s, 0),))') + convertfrompyobject_test('d.update((("a", %s),))') +*************** +*** 1055,1061 **** + cb.append(">> ListConstructor") + ee('vim.List(1, 2)') + ee('vim.List(a=1)') +! #iter_test('vim.List(%s)') + convertfrompyobject_test('vim.List([%s])') + cb.append(">> ListItem") + ee('l[1000]') +--- 1101,1107 ---- + cb.append(">> ListConstructor") + ee('vim.List(1, 2)') + ee('vim.List(a=1)') +! iter_test('vim.List(%s)') + convertfrompyobject_test('vim.List([%s])') + cb.append(">> ListItem") + ee('l[1000]') +*************** +*** 1064,1073 **** + ee('l[1000] = 3') + cb.append(">> ListAssSlice") + ee('ll[1:100] = "abcJ"') +! #iter_test('l[:] = %s') + convertfrompyobject_test('l[:] = [%s]') + cb.append(">> ListConcatInPlace") +! #iter_test('l.extend(%s)') + convertfrompyobject_test('l.extend([%s])') + cb.append(">> ListSetattr") + ee('del l.locked') +--- 1110,1119 ---- + ee('l[1000] = 3') + cb.append(">> ListAssSlice") + ee('ll[1:100] = "abcJ"') +! iter_test('l[:] = %s') + convertfrompyobject_test('l[:] = [%s]') + cb.append(">> ListConcatInPlace") +! iter_test('l.extend(%s)') + convertfrompyobject_test('l.extend([%s])') + cb.append(">> ListSetattr") + ee('del l.locked') +*************** +*** 1094,1107 **** + ee('vim.current.window.buffer = 0') + ee('vim.current.window.cursor = (100000000, 100000000)') + ee('vim.current.window.cursor = True') +! ee('vim.current.window.height = "abcK"') +! ee('vim.current.window.width = "abcL"') + ee('vim.current.window.xxxxxx = True') + cb.append("> WinList") + cb.append(">> WinListItem") + ee('vim.windows[1000]') + cb.append("> Buffer") + cb.append(">> StringToLine (indirect)") + ee('vim.current.buffer[0] = "\\na"') + cb.append(">> SetBufferLine (indirect)") + ee('vim.current.buffer[0] = True') +--- 1140,1154 ---- + ee('vim.current.window.buffer = 0') + ee('vim.current.window.cursor = (100000000, 100000000)') + ee('vim.current.window.cursor = True') +! number_test('vim.current.window.height = %s', unsigned=True) +! number_test('vim.current.window.width = %s', unsigned=True) + ee('vim.current.window.xxxxxx = True') + cb.append("> WinList") + cb.append(">> WinListItem") + ee('vim.windows[1000]') + cb.append("> Buffer") + cb.append(">> StringToLine (indirect)") ++ ee('vim.current.buffer[0] = u"\\na"') + ee('vim.current.buffer[0] = "\\na"') + cb.append(">> SetBufferLine (indirect)") + ee('vim.current.buffer[0] = True') +*************** +*** 1129,1136 **** + ee('vim.current.buffer.range(1, 2, 3)') + cb.append("> BufMap") + cb.append(">> BufMapItem") +- ee('vim.buffers[None]') + ee('vim.buffers[100000000]') + cb.append("> Current") + cb.append(">> CurrentGetattr") + ee('vim.current.xxx') +--- 1176,1183 ---- + ee('vim.current.buffer.range(1, 2, 3)') + cb.append("> BufMap") + cb.append(">> BufMapItem") + ee('vim.buffers[100000000]') ++ number_test('vim.buffers[%s]', natural=True) + cb.append("> Current") + cb.append(">> CurrentGetattr") + ee('vim.current.xxx') +*************** +*** 1154,1165 **** +--- 1201,1216 ---- + del convertfrompyobject_test + del convertfrompymapping_test + del iter_test ++ del number_test + del FailingTrue + del FailingIter + del FailingIterNext + del FailingMapping + del FailingMappingKey + del FailingList ++ del NoArgsCall ++ del FailingCall ++ del FailingNumber + EOF + :delfunction F + :" +*************** +*** 1168,1173 **** +--- 1219,1234 ---- + sys.path.insert(0, os.path.join(os.getcwd(), 'python_before')) + sys.path.append(os.path.join(os.getcwd(), 'python_after')) + vim.options['rtp'] = os.getcwd().replace(',', '\\,').replace('\\', '\\\\') ++ l = [] ++ def callback(path): ++ l.append(path[-len('/testdir'):]) ++ vim.foreach_rtp(callback) ++ cb.append(repr(l)) ++ del l ++ def callback(path): ++ return path[-len('/testdir'):] ++ cb.append(repr(vim.foreach_rtp(callback))) ++ del callback + from module import dir as d + from modulex import ddir + cb.append(d + ',' + ddir) +*************** +*** 1175,1184 **** +--- 1236,1254 ---- + cb.append(before.dir) + import after + cb.append(after.dir) ++ import topmodule as tm ++ import topmodule.submodule as tms ++ import topmodule.submodule.subsubmodule.subsubsubmodule as tmsss ++ cb.append(tm.__file__.replace('.pyc', '.py')[-len('modulex/topmodule/__init__.py'):]) ++ cb.append(tms.__file__.replace('.pyc', '.py')[-len('modulex/topmodule/submodule/__init__.py'):]) ++ cb.append(tmsss.__file__.replace('.pyc', '.py')[-len('modulex/topmodule/submodule/subsubmodule/subsubsubmodule.py'):]) + del before + del after + del d + del ddir ++ del tm ++ del tms ++ del tmsss + EOF + :" + :" Test exceptions +*************** +*** 1232,1237 **** +--- 1302,1308 ---- + :call garbagecollect(1) + :" + :/^start:/,$wq! test.out ++ :" vim: et ts=4 isk-=\: + :call getchar() + ENDTEST + +*** ../vim-7.3.1235/src/testdir/test86.ok 2013-06-23 14:37:00.000000000 +0200 +--- src/testdir/test86.ok 2013-06-23 16:29:45.000000000 +0200 +*************** +*** 441,468 **** + > Output + >> OutputSetattr + del sys.stdout.softspace:AttributeError:("can't delete OutputObject attributes",) + sys.stdout.softspace = []:TypeError:('expected int(), long() or something supporting coercing to long(), but got list',) + sys.stdout.attr = None:AttributeError:('invalid attribute: attr',) + >> OutputWrite + sys.stdout.write(None):TypeError:('coercing to Unicode: need string or buffer, NoneType found',) + >> OutputWriteLines + sys.stdout.writelines(None):TypeError:("'NoneType' object is not iterable",) + sys.stdout.writelines([1]):TypeError:('coercing to Unicode: need string or buffer, int found',) + > VimCommand + vim.command(1):TypeError:('expected str() or unicode() instance, but got int',) + > VimToPython + > VimEval + vim.eval(1):TypeError:('expected str() or unicode() instance, but got int',) + > VimEvalPy + vim.bindeval(1):TypeError:('expected str() or unicode() instance, but got int',) + > VimStrwidth + vim.strwidth(1):TypeError:('expected str() or unicode() instance, but got int',) + > Dictionary + >> DictionaryConstructor + vim.Dictionary("abcI"):ValueError:('expected sequence element of size 2, but got sequence of size 1',) + >> DictionarySetattr + del d.locked:AttributeError:('cannot delete vim.Dictionary attributes',) +! d.locked = FailingTrue():NotImplementedError:() + vim.vvars.locked = False:TypeError:('cannot modify fixed dictionary',) + d.scope = True:AttributeError:('cannot set attribute scope',) + d.xxx = True:AttributeError:('cannot set attribute xxx',) +--- 441,509 ---- + > Output + >> OutputSetattr + del sys.stdout.softspace:AttributeError:("can't delete OutputObject attributes",) ++ >>> Testing NumberToLong using sys.stdout.softspace = %s + sys.stdout.softspace = []:TypeError:('expected int(), long() or something supporting coercing to long(), but got list',) ++ sys.stdout.softspace = None:TypeError:('expected int(), long() or something supporting coercing to long(), but got NoneType',) ++ sys.stdout.softspace = -1:ValueError:('number must be greater or equal to zero',) ++ <<< Finished ++ >>> Testing NumberToLong using sys.stderr.softspace = %s ++ sys.stderr.softspace = []:TypeError:('expected int(), long() or something supporting coercing to long(), but got list',) ++ sys.stderr.softspace = None:TypeError:('expected int(), long() or something supporting coercing to long(), but got NoneType',) ++ sys.stderr.softspace = -1:ValueError:('number must be greater or equal to zero',) ++ <<< Finished + sys.stdout.attr = None:AttributeError:('invalid attribute: attr',) + >> OutputWrite + sys.stdout.write(None):TypeError:('coercing to Unicode: need string or buffer, NoneType found',) + >> OutputWriteLines + sys.stdout.writelines(None):TypeError:("'NoneType' object is not iterable",) + sys.stdout.writelines([1]):TypeError:('coercing to Unicode: need string or buffer, int found',) ++ >>> Testing *Iter* using sys.stdout.writelines(%s) ++ sys.stdout.writelines(FailingIter()):NotImplementedError:('iter',) ++ sys.stdout.writelines(FailingIterNext()):NotImplementedError:('next',) ++ <<< Finished + > VimCommand ++ >>> Testing StringToChars using vim.command(%s) + vim.command(1):TypeError:('expected str() or unicode() instance, but got int',) ++ vim.command(u"\0"):TypeError:('expected string without null bytes',) ++ vim.command("\0"):TypeError:('expected string without null bytes',) ++ <<< Finished ++ vim.command("", 2):TypeError:('command() takes exactly one argument (2 given)',) + > VimToPython + > VimEval ++ >>> Testing StringToChars using vim.eval(%s) + vim.eval(1):TypeError:('expected str() or unicode() instance, but got int',) ++ vim.eval(u"\0"):TypeError:('expected string without null bytes',) ++ vim.eval("\0"):TypeError:('expected string without null bytes',) ++ <<< Finished ++ vim.eval("", FailingTrue()):TypeError:('function takes exactly 1 argument (2 given)',) + > VimEvalPy ++ >>> Testing StringToChars using vim.bindeval(%s) + vim.bindeval(1):TypeError:('expected str() or unicode() instance, but got int',) ++ vim.bindeval(u"\0"):TypeError:('expected string without null bytes',) ++ vim.bindeval("\0"):TypeError:('expected string without null bytes',) ++ <<< Finished ++ vim.eval("", 2):TypeError:('function takes exactly 1 argument (2 given)',) + > VimStrwidth ++ >>> Testing StringToChars using vim.strwidth(%s) + vim.strwidth(1):TypeError:('expected str() or unicode() instance, but got int',) ++ vim.strwidth(u"\0"):TypeError:('expected string without null bytes',) ++ vim.strwidth("\0"):TypeError:('expected string without null bytes',) ++ <<< Finished ++ > VimForeachRTP ++ vim.foreach_rtp(None):TypeError:("'NoneType' object is not callable",) ++ vim.foreach_rtp(NoArgsCall()):TypeError:('__call__() takes exactly 1 argument (2 given)',) ++ vim.foreach_rtp(FailingCall()):NotImplementedError:('call',) ++ vim.foreach_rtp(int, 2):TypeError:('foreach_rtp() takes exactly one argument (2 given)',) ++ > import ++ import xxx_no_such_module_xxx:ImportError:('No module named xxx_no_such_module_xxx',) ++ import failing_import:ImportError:('No module named failing_import',) ++ import failing:ImportError:('No module named failing',) + > Dictionary + >> DictionaryConstructor + vim.Dictionary("abcI"):ValueError:('expected sequence element of size 2, but got sequence of size 1',) + >> DictionarySetattr + del d.locked:AttributeError:('cannot delete vim.Dictionary attributes',) +! d.locked = FailingTrue():NotImplementedError:('bool',) + vim.vvars.locked = False:TypeError:('cannot modify fixed dictionary',) + d.scope = True:AttributeError:('cannot set attribute scope',) + d.xxx = True:AttributeError:('cannot set attribute xxx',) +*************** +*** 501,514 **** + <<< Finished + >>> Testing *Iter* using d["a"] = {"abcF" : %s} + d["a"] = {"abcF" : FailingIter()}:TypeError:('unable to convert FailingIter to vim structure',) +! d["a"] = {"abcF" : FailingIterNext()}:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = {"abcF" : %s} + d["a"] = {"abcF" : None}:TypeError:('unable to convert NoneType to vim structure',) + d["a"] = {"abcF" : {"": 1}}:ValueError:('empty keys are not allowed',) + d["a"] = {"abcF" : {u"": 1}}:ValueError:('empty keys are not allowed',) +! d["a"] = {"abcF" : FailingMapping()}:NotImplementedError:() +! d["a"] = {"abcF" : FailingMappingKey()}:NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) + d["a"] = Mapping({1 : 1}):TypeError:('expected str() or unicode() instance, but got int',) +--- 542,556 ---- + <<< Finished + >>> Testing *Iter* using d["a"] = {"abcF" : %s} + d["a"] = {"abcF" : FailingIter()}:TypeError:('unable to convert FailingIter to vim structure',) +! d["a"] = {"abcF" : FailingIterNext()}:NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = {"abcF" : %s} + d["a"] = {"abcF" : None}:TypeError:('unable to convert NoneType to vim structure',) + d["a"] = {"abcF" : {"": 1}}:ValueError:('empty keys are not allowed',) + d["a"] = {"abcF" : {u"": 1}}:ValueError:('empty keys are not allowed',) +! d["a"] = {"abcF" : FailingMapping()}:NotImplementedError:('keys',) +! d["a"] = {"abcF" : FailingMappingKey()}:NotImplementedError:('getitem:mappingkey',) +! d["a"] = {"abcF" : FailingNumber()}:TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) + d["a"] = Mapping({1 : 1}):TypeError:('expected str() or unicode() instance, but got int',) +*************** +*** 527,557 **** + <<< Finished + >>> Testing *Iter* using d["a"] = Mapping({"abcG" : %s}) + d["a"] = Mapping({"abcG" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! d["a"] = Mapping({"abcG" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abcG" : %s}) + d["a"] = Mapping({"abcG" : None}):TypeError:('unable to convert NoneType to vim structure',) + d["a"] = Mapping({"abcG" : {"": 1}}):ValueError:('empty keys are not allowed',) + d["a"] = Mapping({"abcG" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! d["a"] = Mapping({"abcG" : FailingMapping()}):NotImplementedError:() +! d["a"] = Mapping({"abcG" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d["a"] = %s + d["a"] = FailingIter():TypeError:('unable to convert FailingIter to vim structure',) +! d["a"] = FailingIterNext():NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = %s + d["a"] = None:TypeError:('unable to convert NoneType to vim structure',) + d["a"] = {"": 1}:ValueError:('empty keys are not allowed',) + d["a"] = {u"": 1}:ValueError:('empty keys are not allowed',) +! d["a"] = FailingMapping():NotImplementedError:() +! d["a"] = FailingMappingKey():NotImplementedError:() + <<< Finished + >> DictionaryUpdate + >>> kwargs + >>> iter +! d.update(FailingMapping()):NotImplementedError:() +! d.update([FailingIterNext()]):NotImplementedError:() + >>> Testing StringToChars using d.update({%s : 1}) + d.update({1 : 1}):TypeError:('expected str() or unicode() instance, but got int',) + d.update({u"\0" : 1}):TypeError:('expected string without null bytes',) +--- 569,605 ---- + <<< Finished + >>> Testing *Iter* using d["a"] = Mapping({"abcG" : %s}) + d["a"] = Mapping({"abcG" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! d["a"] = Mapping({"abcG" : FailingIterNext()}):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abcG" : %s}) + d["a"] = Mapping({"abcG" : None}):TypeError:('unable to convert NoneType to vim structure',) + d["a"] = Mapping({"abcG" : {"": 1}}):ValueError:('empty keys are not allowed',) + d["a"] = Mapping({"abcG" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! d["a"] = Mapping({"abcG" : FailingMapping()}):NotImplementedError:('keys',) +! d["a"] = Mapping({"abcG" : FailingMappingKey()}):NotImplementedError:('getitem:mappingkey',) +! d["a"] = Mapping({"abcG" : FailingNumber()}):TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing *Iter* using d["a"] = %s + d["a"] = FailingIter():TypeError:('unable to convert FailingIter to vim structure',) +! d["a"] = FailingIterNext():NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = %s + d["a"] = None:TypeError:('unable to convert NoneType to vim structure',) + d["a"] = {"": 1}:ValueError:('empty keys are not allowed',) + d["a"] = {u"": 1}:ValueError:('empty keys are not allowed',) +! d["a"] = FailingMapping():NotImplementedError:('keys',) +! d["a"] = FailingMappingKey():NotImplementedError:('getitem:mappingkey',) +! d["a"] = FailingNumber():TypeError:('long() argument must be a string or a number',) + <<< Finished + >> DictionaryUpdate + >>> kwargs + >>> iter +! d.update(FailingMapping()):NotImplementedError:('keys',) +! d.update([FailingIterNext()]):NotImplementedError:('next',) +! >>> Testing *Iter* using d.update(%s) +! d.update(FailingIter()):NotImplementedError:('iter',) +! d.update(FailingIterNext()):NotImplementedError:('next',) +! <<< Finished + >>> Testing StringToChars using d.update({%s : 1}) + d.update({1 : 1}):TypeError:('expected str() or unicode() instance, but got int',) + d.update({u"\0" : 1}):TypeError:('expected string without null bytes',) +*************** +*** 569,582 **** + <<< Finished + >>> Testing *Iter* using d.update({"abcF" : %s}) + d.update({"abcF" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! d.update({"abcF" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update({"abcF" : %s}) + d.update({"abcF" : None}):TypeError:('unable to convert NoneType to vim structure',) + d.update({"abcF" : {"": 1}}):ValueError:('empty keys are not allowed',) + d.update({"abcF" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! d.update({"abcF" : FailingMapping()}):NotImplementedError:() +! d.update({"abcF" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) + d.update(Mapping({1 : 1})):TypeError:('expected str() or unicode() instance, but got int',) +--- 617,631 ---- + <<< Finished + >>> Testing *Iter* using d.update({"abcF" : %s}) + d.update({"abcF" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! d.update({"abcF" : FailingIterNext()}):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using d.update({"abcF" : %s}) + d.update({"abcF" : None}):TypeError:('unable to convert NoneType to vim structure',) + d.update({"abcF" : {"": 1}}):ValueError:('empty keys are not allowed',) + d.update({"abcF" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! d.update({"abcF" : FailingMapping()}):NotImplementedError:('keys',) +! d.update({"abcF" : FailingMappingKey()}):NotImplementedError:('getitem:mappingkey',) +! d.update({"abcF" : FailingNumber()}):TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) + d.update(Mapping({1 : 1})):TypeError:('expected str() or unicode() instance, but got int',) +*************** +*** 595,619 **** + <<< Finished + >>> Testing *Iter* using d.update(Mapping({"abcG" : %s})) + d.update(Mapping({"abcG" : FailingIter()})):TypeError:('unable to convert FailingIter to vim structure',) +! d.update(Mapping({"abcG" : FailingIterNext()})):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update(Mapping({"abcG" : %s})) + d.update(Mapping({"abcG" : None})):TypeError:('unable to convert NoneType to vim structure',) + d.update(Mapping({"abcG" : {"": 1}})):ValueError:('empty keys are not allowed',) + d.update(Mapping({"abcG" : {u"": 1}})):ValueError:('empty keys are not allowed',) +! d.update(Mapping({"abcG" : FailingMapping()})):NotImplementedError:() +! d.update(Mapping({"abcG" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d.update(%s) +! d.update(FailingIter()):NotImplementedError:() +! d.update(FailingIterNext()):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update(%s) + d.update(None):TypeError:("'NoneType' object is not iterable",) + d.update({"": 1}):ValueError:('empty keys are not allowed',) + d.update({u"": 1}):ValueError:('empty keys are not allowed',) +! d.update(FailingMapping()):NotImplementedError:() +! d.update(FailingMappingKey()):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update(((%s, 0),)) + d.update(((1, 0),)):TypeError:('expected str() or unicode() instance, but got int',) +--- 644,670 ---- + <<< Finished + >>> Testing *Iter* using d.update(Mapping({"abcG" : %s})) + d.update(Mapping({"abcG" : FailingIter()})):TypeError:('unable to convert FailingIter to vim structure',) +! d.update(Mapping({"abcG" : FailingIterNext()})):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using d.update(Mapping({"abcG" : %s})) + d.update(Mapping({"abcG" : None})):TypeError:('unable to convert NoneType to vim structure',) + d.update(Mapping({"abcG" : {"": 1}})):ValueError:('empty keys are not allowed',) + d.update(Mapping({"abcG" : {u"": 1}})):ValueError:('empty keys are not allowed',) +! d.update(Mapping({"abcG" : FailingMapping()})):NotImplementedError:('keys',) +! d.update(Mapping({"abcG" : FailingMappingKey()})):NotImplementedError:('getitem:mappingkey',) +! d.update(Mapping({"abcG" : FailingNumber()})):TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing *Iter* using d.update(%s) +! d.update(FailingIter()):NotImplementedError:('iter',) +! d.update(FailingIterNext()):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using d.update(%s) + d.update(None):TypeError:("'NoneType' object is not iterable",) + d.update({"": 1}):ValueError:('empty keys are not allowed',) + d.update({u"": 1}):ValueError:('empty keys are not allowed',) +! d.update(FailingMapping()):NotImplementedError:('keys',) +! d.update(FailingMappingKey()):NotImplementedError:('getitem:mappingkey',) +! d.update(FailingNumber()):TypeError:("'FailingNumber' object is not iterable",) + <<< Finished + >>> Testing StringToChars using d.update(((%s, 0),)) + d.update(((1, 0),)):TypeError:('expected str() or unicode() instance, but got int',) +*************** +*** 637,650 **** + <<< Finished + >>> Testing *Iter* using d.update((("a", {"abcF" : %s}),)) + d.update((("a", {"abcF" : FailingIter()}),)):TypeError:('unable to convert FailingIter to vim structure',) +! d.update((("a", {"abcF" : FailingIterNext()}),)):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", {"abcF" : %s}),)) + d.update((("a", {"abcF" : None}),)):TypeError:('unable to convert NoneType to vim structure',) + d.update((("a", {"abcF" : {"": 1}}),)):ValueError:('empty keys are not allowed',) + d.update((("a", {"abcF" : {u"": 1}}),)):ValueError:('empty keys are not allowed',) +! d.update((("a", {"abcF" : FailingMapping()}),)):NotImplementedError:() +! d.update((("a", {"abcF" : FailingMappingKey()}),)):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) + d.update((("a", Mapping({1 : 1})),)):TypeError:('expected str() or unicode() instance, but got int',) +--- 688,702 ---- + <<< Finished + >>> Testing *Iter* using d.update((("a", {"abcF" : %s}),)) + d.update((("a", {"abcF" : FailingIter()}),)):TypeError:('unable to convert FailingIter to vim structure',) +! d.update((("a", {"abcF" : FailingIterNext()}),)):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", {"abcF" : %s}),)) + d.update((("a", {"abcF" : None}),)):TypeError:('unable to convert NoneType to vim structure',) + d.update((("a", {"abcF" : {"": 1}}),)):ValueError:('empty keys are not allowed',) + d.update((("a", {"abcF" : {u"": 1}}),)):ValueError:('empty keys are not allowed',) +! d.update((("a", {"abcF" : FailingMapping()}),)):NotImplementedError:('keys',) +! d.update((("a", {"abcF" : FailingMappingKey()}),)):NotImplementedError:('getitem:mappingkey',) +! d.update((("a", {"abcF" : FailingNumber()}),)):TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) + d.update((("a", Mapping({1 : 1})),)):TypeError:('expected str() or unicode() instance, but got int',) +*************** +*** 663,687 **** + <<< Finished + >>> Testing *Iter* using d.update((("a", Mapping({"abcG" : %s})),)) + d.update((("a", Mapping({"abcG" : FailingIter()})),)):TypeError:('unable to convert FailingIter to vim structure',) +! d.update((("a", Mapping({"abcG" : FailingIterNext()})),)):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abcG" : %s})),)) + d.update((("a", Mapping({"abcG" : None})),)):TypeError:('unable to convert NoneType to vim structure',) + d.update((("a", Mapping({"abcG" : {"": 1}})),)):ValueError:('empty keys are not allowed',) + d.update((("a", Mapping({"abcG" : {u"": 1}})),)):ValueError:('empty keys are not allowed',) +! d.update((("a", Mapping({"abcG" : FailingMapping()})),)):NotImplementedError:() +! d.update((("a", Mapping({"abcG" : FailingMappingKey()})),)):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using d.update((("a", %s),)) + d.update((("a", FailingIter()),)):TypeError:('unable to convert FailingIter to vim structure',) +! d.update((("a", FailingIterNext()),)):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", %s),)) + d.update((("a", None),)):TypeError:('unable to convert NoneType to vim structure',) + d.update((("a", {"": 1}),)):ValueError:('empty keys are not allowed',) + d.update((("a", {u"": 1}),)):ValueError:('empty keys are not allowed',) +! d.update((("a", FailingMapping()),)):NotImplementedError:() +! d.update((("a", FailingMappingKey()),)):NotImplementedError:() + <<< Finished + >> DictionaryPopItem + d.popitem(1, 2):TypeError:('popitem() takes no arguments (2 given)',) +--- 715,741 ---- + <<< Finished + >>> Testing *Iter* using d.update((("a", Mapping({"abcG" : %s})),)) + d.update((("a", Mapping({"abcG" : FailingIter()})),)):TypeError:('unable to convert FailingIter to vim structure',) +! d.update((("a", Mapping({"abcG" : FailingIterNext()})),)):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abcG" : %s})),)) + d.update((("a", Mapping({"abcG" : None})),)):TypeError:('unable to convert NoneType to vim structure',) + d.update((("a", Mapping({"abcG" : {"": 1}})),)):ValueError:('empty keys are not allowed',) + d.update((("a", Mapping({"abcG" : {u"": 1}})),)):ValueError:('empty keys are not allowed',) +! d.update((("a", Mapping({"abcG" : FailingMapping()})),)):NotImplementedError:('keys',) +! d.update((("a", Mapping({"abcG" : FailingMappingKey()})),)):NotImplementedError:('getitem:mappingkey',) +! d.update((("a", Mapping({"abcG" : FailingNumber()})),)):TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing *Iter* using d.update((("a", %s),)) + d.update((("a", FailingIter()),)):TypeError:('unable to convert FailingIter to vim structure',) +! d.update((("a", FailingIterNext()),)):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", %s),)) + d.update((("a", None),)):TypeError:('unable to convert NoneType to vim structure',) + d.update((("a", {"": 1}),)):ValueError:('empty keys are not allowed',) + d.update((("a", {u"": 1}),)):ValueError:('empty keys are not allowed',) +! d.update((("a", FailingMapping()),)):NotImplementedError:('keys',) +! d.update((("a", FailingMappingKey()),)):NotImplementedError:('getitem:mappingkey',) +! d.update((("a", FailingNumber()),)):TypeError:('long() argument must be a string or a number',) + <<< Finished + >> DictionaryPopItem + d.popitem(1, 2):TypeError:('popitem() takes no arguments (2 given)',) +*************** +*** 691,696 **** +--- 745,754 ---- + >> ListConstructor + vim.List(1, 2):TypeError:('function takes at most 1 argument (2 given)',) + vim.List(a=1):TypeError:('list constructor does not accept keyword arguments',) ++ >>> Testing *Iter* using vim.List(%s) ++ vim.List(FailingIter()):NotImplementedError:('iter',) ++ vim.List(FailingIterNext()):NotImplementedError:('next',) ++ <<< Finished + >>> Testing StringToChars using vim.List([{%s : 1}]) + vim.List([{1 : 1}]):TypeError:('expected str() or unicode() instance, but got int',) + vim.List([{u"\0" : 1}]):TypeError:('expected string without null bytes',) +*************** +*** 708,721 **** + <<< Finished + >>> Testing *Iter* using vim.List([{"abcF" : %s}]) + vim.List([{"abcF" : FailingIter()}]):TypeError:('unable to convert FailingIter to vim structure',) +! vim.List([{"abcF" : FailingIterNext()}]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([{"abcF" : %s}]) + vim.List([{"abcF" : None}]):TypeError:('unable to convert NoneType to vim structure',) + vim.List([{"abcF" : {"": 1}}]):ValueError:('empty keys are not allowed',) + vim.List([{"abcF" : {u"": 1}}]):ValueError:('empty keys are not allowed',) +! vim.List([{"abcF" : FailingMapping()}]):NotImplementedError:() +! vim.List([{"abcF" : FailingMappingKey()}]):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) + vim.List([Mapping({1 : 1})]):TypeError:('expected str() or unicode() instance, but got int',) +--- 766,780 ---- + <<< Finished + >>> Testing *Iter* using vim.List([{"abcF" : %s}]) + vim.List([{"abcF" : FailingIter()}]):TypeError:('unable to convert FailingIter to vim structure',) +! vim.List([{"abcF" : FailingIterNext()}]):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([{"abcF" : %s}]) + vim.List([{"abcF" : None}]):TypeError:('unable to convert NoneType to vim structure',) + vim.List([{"abcF" : {"": 1}}]):ValueError:('empty keys are not allowed',) + vim.List([{"abcF" : {u"": 1}}]):ValueError:('empty keys are not allowed',) +! vim.List([{"abcF" : FailingMapping()}]):NotImplementedError:('keys',) +! vim.List([{"abcF" : FailingMappingKey()}]):NotImplementedError:('getitem:mappingkey',) +! vim.List([{"abcF" : FailingNumber()}]):TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) + vim.List([Mapping({1 : 1})]):TypeError:('expected str() or unicode() instance, but got int',) +*************** +*** 734,758 **** + <<< Finished + >>> Testing *Iter* using vim.List([Mapping({"abcG" : %s})]) + vim.List([Mapping({"abcG" : FailingIter()})]):TypeError:('unable to convert FailingIter to vim structure',) +! vim.List([Mapping({"abcG" : FailingIterNext()})]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([Mapping({"abcG" : %s})]) + vim.List([Mapping({"abcG" : None})]):TypeError:('unable to convert NoneType to vim structure',) + vim.List([Mapping({"abcG" : {"": 1}})]):ValueError:('empty keys are not allowed',) + vim.List([Mapping({"abcG" : {u"": 1}})]):ValueError:('empty keys are not allowed',) +! vim.List([Mapping({"abcG" : FailingMapping()})]):NotImplementedError:() +! vim.List([Mapping({"abcG" : FailingMappingKey()})]):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using vim.List([%s]) + vim.List([FailingIter()]):TypeError:('unable to convert FailingIter to vim structure',) +! vim.List([FailingIterNext()]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([%s]) + vim.List([None]):TypeError:('unable to convert NoneType to vim structure',) + vim.List([{"": 1}]):ValueError:('empty keys are not allowed',) + vim.List([{u"": 1}]):ValueError:('empty keys are not allowed',) +! vim.List([FailingMapping()]):NotImplementedError:() +! vim.List([FailingMappingKey()]):NotImplementedError:() + <<< Finished + >> ListItem + l[1000]:IndexError:('list index out of range',) +--- 793,819 ---- + <<< Finished + >>> Testing *Iter* using vim.List([Mapping({"abcG" : %s})]) + vim.List([Mapping({"abcG" : FailingIter()})]):TypeError:('unable to convert FailingIter to vim structure',) +! vim.List([Mapping({"abcG" : FailingIterNext()})]):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([Mapping({"abcG" : %s})]) + vim.List([Mapping({"abcG" : None})]):TypeError:('unable to convert NoneType to vim structure',) + vim.List([Mapping({"abcG" : {"": 1}})]):ValueError:('empty keys are not allowed',) + vim.List([Mapping({"abcG" : {u"": 1}})]):ValueError:('empty keys are not allowed',) +! vim.List([Mapping({"abcG" : FailingMapping()})]):NotImplementedError:('keys',) +! vim.List([Mapping({"abcG" : FailingMappingKey()})]):NotImplementedError:('getitem:mappingkey',) +! vim.List([Mapping({"abcG" : FailingNumber()})]):TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing *Iter* using vim.List([%s]) + vim.List([FailingIter()]):TypeError:('unable to convert FailingIter to vim structure',) +! vim.List([FailingIterNext()]):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([%s]) + vim.List([None]):TypeError:('unable to convert NoneType to vim structure',) + vim.List([{"": 1}]):ValueError:('empty keys are not allowed',) + vim.List([{u"": 1}]):ValueError:('empty keys are not allowed',) +! vim.List([FailingMapping()]):NotImplementedError:('keys',) +! vim.List([FailingMappingKey()]):NotImplementedError:('getitem:mappingkey',) +! vim.List([FailingNumber()]):TypeError:('long() argument must be a string or a number',) + <<< Finished + >> ListItem + l[1000]:IndexError:('list index out of range',) +*************** +*** 761,766 **** +--- 822,831 ---- + l[1000] = 3:IndexError:('list index out of range',) + >> ListAssSlice + ll[1:100] = "abcJ":error:('list is locked',) ++ >>> Testing *Iter* using l[:] = %s ++ l[:] = FailingIter():NotImplementedError:('iter',) ++ l[:] = FailingIterNext():NotImplementedError:('next',) ++ <<< Finished + >>> Testing StringToChars using l[:] = [{%s : 1}] + l[:] = [{1 : 1}]:TypeError:('expected str() or unicode() instance, but got int',) + l[:] = [{u"\0" : 1}]:TypeError:('expected string without null bytes',) +*************** +*** 778,791 **** + <<< Finished + >>> Testing *Iter* using l[:] = [{"abcF" : %s}] + l[:] = [{"abcF" : FailingIter()}]:TypeError:('unable to convert FailingIter to vim structure',) +! l[:] = [{"abcF" : FailingIterNext()}]:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [{"abcF" : %s}] + l[:] = [{"abcF" : None}]:TypeError:('unable to convert NoneType to vim structure',) + l[:] = [{"abcF" : {"": 1}}]:ValueError:('empty keys are not allowed',) + l[:] = [{"abcF" : {u"": 1}}]:ValueError:('empty keys are not allowed',) +! l[:] = [{"abcF" : FailingMapping()}]:NotImplementedError:() +! l[:] = [{"abcF" : FailingMappingKey()}]:NotImplementedError:() + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] + l[:] = [Mapping({1 : 1})]:TypeError:('expected str() or unicode() instance, but got int',) +--- 843,857 ---- + <<< Finished + >>> Testing *Iter* using l[:] = [{"abcF" : %s}] + l[:] = [{"abcF" : FailingIter()}]:TypeError:('unable to convert FailingIter to vim structure',) +! l[:] = [{"abcF" : FailingIterNext()}]:NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [{"abcF" : %s}] + l[:] = [{"abcF" : None}]:TypeError:('unable to convert NoneType to vim structure',) + l[:] = [{"abcF" : {"": 1}}]:ValueError:('empty keys are not allowed',) + l[:] = [{"abcF" : {u"": 1}}]:ValueError:('empty keys are not allowed',) +! l[:] = [{"abcF" : FailingMapping()}]:NotImplementedError:('keys',) +! l[:] = [{"abcF" : FailingMappingKey()}]:NotImplementedError:('getitem:mappingkey',) +! l[:] = [{"abcF" : FailingNumber()}]:TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] + l[:] = [Mapping({1 : 1})]:TypeError:('expected str() or unicode() instance, but got int',) +*************** +*** 804,830 **** + <<< Finished + >>> Testing *Iter* using l[:] = [Mapping({"abcG" : %s})] + l[:] = [Mapping({"abcG" : FailingIter()})]:TypeError:('unable to convert FailingIter to vim structure',) +! l[:] = [Mapping({"abcG" : FailingIterNext()})]:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abcG" : %s})] + l[:] = [Mapping({"abcG" : None})]:TypeError:('unable to convert NoneType to vim structure',) + l[:] = [Mapping({"abcG" : {"": 1}})]:ValueError:('empty keys are not allowed',) + l[:] = [Mapping({"abcG" : {u"": 1}})]:ValueError:('empty keys are not allowed',) +! l[:] = [Mapping({"abcG" : FailingMapping()})]:NotImplementedError:() +! l[:] = [Mapping({"abcG" : FailingMappingKey()})]:NotImplementedError:() + <<< Finished + >>> Testing *Iter* using l[:] = [%s] + l[:] = [FailingIter()]:TypeError:('unable to convert FailingIter to vim structure',) +! l[:] = [FailingIterNext()]:NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [%s] + l[:] = [None]:TypeError:('unable to convert NoneType to vim structure',) + l[:] = [{"": 1}]:ValueError:('empty keys are not allowed',) + l[:] = [{u"": 1}]:ValueError:('empty keys are not allowed',) +! l[:] = [FailingMapping()]:NotImplementedError:() +! l[:] = [FailingMappingKey()]:NotImplementedError:() + <<< Finished + >> ListConcatInPlace + >>> Testing StringToChars using l.extend([{%s : 1}]) + l.extend([{1 : 1}]):TypeError:('expected str() or unicode() instance, but got int',) + l.extend([{u"\0" : 1}]):TypeError:('expected string without null bytes',) +--- 870,902 ---- + <<< Finished + >>> Testing *Iter* using l[:] = [Mapping({"abcG" : %s})] + l[:] = [Mapping({"abcG" : FailingIter()})]:TypeError:('unable to convert FailingIter to vim structure',) +! l[:] = [Mapping({"abcG" : FailingIterNext()})]:NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abcG" : %s})] + l[:] = [Mapping({"abcG" : None})]:TypeError:('unable to convert NoneType to vim structure',) + l[:] = [Mapping({"abcG" : {"": 1}})]:ValueError:('empty keys are not allowed',) + l[:] = [Mapping({"abcG" : {u"": 1}})]:ValueError:('empty keys are not allowed',) +! l[:] = [Mapping({"abcG" : FailingMapping()})]:NotImplementedError:('keys',) +! l[:] = [Mapping({"abcG" : FailingMappingKey()})]:NotImplementedError:('getitem:mappingkey',) +! l[:] = [Mapping({"abcG" : FailingNumber()})]:TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing *Iter* using l[:] = [%s] + l[:] = [FailingIter()]:TypeError:('unable to convert FailingIter to vim structure',) +! l[:] = [FailingIterNext()]:NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [%s] + l[:] = [None]:TypeError:('unable to convert NoneType to vim structure',) + l[:] = [{"": 1}]:ValueError:('empty keys are not allowed',) + l[:] = [{u"": 1}]:ValueError:('empty keys are not allowed',) +! l[:] = [FailingMapping()]:NotImplementedError:('keys',) +! l[:] = [FailingMappingKey()]:NotImplementedError:('getitem:mappingkey',) +! l[:] = [FailingNumber()]:TypeError:('long() argument must be a string or a number',) + <<< Finished + >> ListConcatInPlace ++ >>> Testing *Iter* using l.extend(%s) ++ l.extend(FailingIter()):NotImplementedError:('iter',) ++ l.extend(FailingIterNext()):NotImplementedError:('next',) ++ <<< Finished + >>> Testing StringToChars using l.extend([{%s : 1}]) + l.extend([{1 : 1}]):TypeError:('expected str() or unicode() instance, but got int',) + l.extend([{u"\0" : 1}]):TypeError:('expected string without null bytes',) +*************** +*** 842,855 **** + <<< Finished + >>> Testing *Iter* using l.extend([{"abcF" : %s}]) + l.extend([{"abcF" : FailingIter()}]):TypeError:('unable to convert FailingIter to vim structure',) +! l.extend([{"abcF" : FailingIterNext()}]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([{"abcF" : %s}]) + l.extend([{"abcF" : None}]):TypeError:('unable to convert NoneType to vim structure',) + l.extend([{"abcF" : {"": 1}}]):ValueError:('empty keys are not allowed',) + l.extend([{"abcF" : {u"": 1}}]):ValueError:('empty keys are not allowed',) +! l.extend([{"abcF" : FailingMapping()}]):NotImplementedError:() +! l.extend([{"abcF" : FailingMappingKey()}]):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) + l.extend([Mapping({1 : 1})]):TypeError:('expected str() or unicode() instance, but got int',) +--- 914,928 ---- + <<< Finished + >>> Testing *Iter* using l.extend([{"abcF" : %s}]) + l.extend([{"abcF" : FailingIter()}]):TypeError:('unable to convert FailingIter to vim structure',) +! l.extend([{"abcF" : FailingIterNext()}]):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([{"abcF" : %s}]) + l.extend([{"abcF" : None}]):TypeError:('unable to convert NoneType to vim structure',) + l.extend([{"abcF" : {"": 1}}]):ValueError:('empty keys are not allowed',) + l.extend([{"abcF" : {u"": 1}}]):ValueError:('empty keys are not allowed',) +! l.extend([{"abcF" : FailingMapping()}]):NotImplementedError:('keys',) +! l.extend([{"abcF" : FailingMappingKey()}]):NotImplementedError:('getitem:mappingkey',) +! l.extend([{"abcF" : FailingNumber()}]):TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) + l.extend([Mapping({1 : 1})]):TypeError:('expected str() or unicode() instance, but got int',) +*************** +*** 868,896 **** + <<< Finished + >>> Testing *Iter* using l.extend([Mapping({"abcG" : %s})]) + l.extend([Mapping({"abcG" : FailingIter()})]):TypeError:('unable to convert FailingIter to vim structure',) +! l.extend([Mapping({"abcG" : FailingIterNext()})]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([Mapping({"abcG" : %s})]) + l.extend([Mapping({"abcG" : None})]):TypeError:('unable to convert NoneType to vim structure',) + l.extend([Mapping({"abcG" : {"": 1}})]):ValueError:('empty keys are not allowed',) + l.extend([Mapping({"abcG" : {u"": 1}})]):ValueError:('empty keys are not allowed',) +! l.extend([Mapping({"abcG" : FailingMapping()})]):NotImplementedError:() +! l.extend([Mapping({"abcG" : FailingMappingKey()})]):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using l.extend([%s]) + l.extend([FailingIter()]):TypeError:('unable to convert FailingIter to vim structure',) +! l.extend([FailingIterNext()]):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([%s]) + l.extend([None]):TypeError:('unable to convert NoneType to vim structure',) + l.extend([{"": 1}]):ValueError:('empty keys are not allowed',) + l.extend([{u"": 1}]):ValueError:('empty keys are not allowed',) +! l.extend([FailingMapping()]):NotImplementedError:() +! l.extend([FailingMappingKey()]):NotImplementedError:() + <<< Finished + >> ListSetattr + del l.locked:AttributeError:('cannot delete vim.List attributes',) +! l.locked = FailingTrue():NotImplementedError:() + l.xxx = True:AttributeError:('cannot set attribute xxx',) + > Function + >> FunctionConstructor +--- 941,971 ---- + <<< Finished + >>> Testing *Iter* using l.extend([Mapping({"abcG" : %s})]) + l.extend([Mapping({"abcG" : FailingIter()})]):TypeError:('unable to convert FailingIter to vim structure',) +! l.extend([Mapping({"abcG" : FailingIterNext()})]):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([Mapping({"abcG" : %s})]) + l.extend([Mapping({"abcG" : None})]):TypeError:('unable to convert NoneType to vim structure',) + l.extend([Mapping({"abcG" : {"": 1}})]):ValueError:('empty keys are not allowed',) + l.extend([Mapping({"abcG" : {u"": 1}})]):ValueError:('empty keys are not allowed',) +! l.extend([Mapping({"abcG" : FailingMapping()})]):NotImplementedError:('keys',) +! l.extend([Mapping({"abcG" : FailingMappingKey()})]):NotImplementedError:('getitem:mappingkey',) +! l.extend([Mapping({"abcG" : FailingNumber()})]):TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing *Iter* using l.extend([%s]) + l.extend([FailingIter()]):TypeError:('unable to convert FailingIter to vim structure',) +! l.extend([FailingIterNext()]):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([%s]) + l.extend([None]):TypeError:('unable to convert NoneType to vim structure',) + l.extend([{"": 1}]):ValueError:('empty keys are not allowed',) + l.extend([{u"": 1}]):ValueError:('empty keys are not allowed',) +! l.extend([FailingMapping()]):NotImplementedError:('keys',) +! l.extend([FailingMappingKey()]):NotImplementedError:('getitem:mappingkey',) +! l.extend([FailingNumber()]):TypeError:('long() argument must be a string or a number',) + <<< Finished + >> ListSetattr + del l.locked:AttributeError:('cannot delete vim.List attributes',) +! l.locked = FailingTrue():NotImplementedError:('bool',) + l.xxx = True:AttributeError:('cannot set attribute xxx',) + > Function + >> FunctionConstructor +*************** +*** 915,928 **** + <<< Finished + >>> Testing *Iter* using f({"abcF" : %s}) + f({"abcF" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! f({"abcF" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using f({"abcF" : %s}) + f({"abcF" : None}):TypeError:('unable to convert NoneType to vim structure',) + f({"abcF" : {"": 1}}):ValueError:('empty keys are not allowed',) + f({"abcF" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! f({"abcF" : FailingMapping()}):NotImplementedError:() +! f({"abcF" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) + f(Mapping({1 : 1})):TypeError:('expected str() or unicode() instance, but got int',) +--- 990,1004 ---- + <<< Finished + >>> Testing *Iter* using f({"abcF" : %s}) + f({"abcF" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! f({"abcF" : FailingIterNext()}):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using f({"abcF" : %s}) + f({"abcF" : None}):TypeError:('unable to convert NoneType to vim structure',) + f({"abcF" : {"": 1}}):ValueError:('empty keys are not allowed',) + f({"abcF" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! f({"abcF" : FailingMapping()}):NotImplementedError:('keys',) +! f({"abcF" : FailingMappingKey()}):NotImplementedError:('getitem:mappingkey',) +! f({"abcF" : FailingNumber()}):TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) + f(Mapping({1 : 1})):TypeError:('expected str() or unicode() instance, but got int',) +*************** +*** 941,965 **** + <<< Finished + >>> Testing *Iter* using f(Mapping({"abcG" : %s})) + f(Mapping({"abcG" : FailingIter()})):TypeError:('unable to convert FailingIter to vim structure',) +! f(Mapping({"abcG" : FailingIterNext()})):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using f(Mapping({"abcG" : %s})) + f(Mapping({"abcG" : None})):TypeError:('unable to convert NoneType to vim structure',) + f(Mapping({"abcG" : {"": 1}})):ValueError:('empty keys are not allowed',) + f(Mapping({"abcG" : {u"": 1}})):ValueError:('empty keys are not allowed',) +! f(Mapping({"abcG" : FailingMapping()})):NotImplementedError:() +! f(Mapping({"abcG" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using f(%s) + f(FailingIter()):TypeError:('unable to convert FailingIter to vim structure',) +! f(FailingIterNext()):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using f(%s) + f(None):TypeError:('unable to convert NoneType to vim structure',) + f({"": 1}):ValueError:('empty keys are not allowed',) + f({u"": 1}):ValueError:('empty keys are not allowed',) +! f(FailingMapping()):NotImplementedError:() +! f(FailingMappingKey()):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using fd(self={%s : 1}) + fd(self={1 : 1}):TypeError:('expected str() or unicode() instance, but got int',) +--- 1017,1043 ---- + <<< Finished + >>> Testing *Iter* using f(Mapping({"abcG" : %s})) + f(Mapping({"abcG" : FailingIter()})):TypeError:('unable to convert FailingIter to vim structure',) +! f(Mapping({"abcG" : FailingIterNext()})):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using f(Mapping({"abcG" : %s})) + f(Mapping({"abcG" : None})):TypeError:('unable to convert NoneType to vim structure',) + f(Mapping({"abcG" : {"": 1}})):ValueError:('empty keys are not allowed',) + f(Mapping({"abcG" : {u"": 1}})):ValueError:('empty keys are not allowed',) +! f(Mapping({"abcG" : FailingMapping()})):NotImplementedError:('keys',) +! f(Mapping({"abcG" : FailingMappingKey()})):NotImplementedError:('getitem:mappingkey',) +! f(Mapping({"abcG" : FailingNumber()})):TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing *Iter* using f(%s) + f(FailingIter()):TypeError:('unable to convert FailingIter to vim structure',) +! f(FailingIterNext()):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using f(%s) + f(None):TypeError:('unable to convert NoneType to vim structure',) + f({"": 1}):ValueError:('empty keys are not allowed',) + f({u"": 1}):ValueError:('empty keys are not allowed',) +! f(FailingMapping()):NotImplementedError:('keys',) +! f(FailingMappingKey()):NotImplementedError:('getitem:mappingkey',) +! f(FailingNumber()):TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing StringToChars using fd(self={%s : 1}) + fd(self={1 : 1}):TypeError:('expected str() or unicode() instance, but got int',) +*************** +*** 978,991 **** + <<< Finished + >>> Testing *Iter* using fd(self={"abcF" : %s}) + fd(self={"abcF" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! fd(self={"abcF" : FailingIterNext()}):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using fd(self={"abcF" : %s}) + fd(self={"abcF" : None}):TypeError:('unable to convert NoneType to vim structure',) + fd(self={"abcF" : {"": 1}}):ValueError:('empty keys are not allowed',) + fd(self={"abcF" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! fd(self={"abcF" : FailingMapping()}):NotImplementedError:() +! fd(self={"abcF" : FailingMappingKey()}):NotImplementedError:() + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) + fd(self=Mapping({1 : 1})):TypeError:('expected str() or unicode() instance, but got int',) +--- 1056,1070 ---- + <<< Finished + >>> Testing *Iter* using fd(self={"abcF" : %s}) + fd(self={"abcF" : FailingIter()}):TypeError:('unable to convert FailingIter to vim structure',) +! fd(self={"abcF" : FailingIterNext()}):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self={"abcF" : %s}) + fd(self={"abcF" : None}):TypeError:('unable to convert NoneType to vim structure',) + fd(self={"abcF" : {"": 1}}):ValueError:('empty keys are not allowed',) + fd(self={"abcF" : {u"": 1}}):ValueError:('empty keys are not allowed',) +! fd(self={"abcF" : FailingMapping()}):NotImplementedError:('keys',) +! fd(self={"abcF" : FailingMappingKey()}):NotImplementedError:('getitem:mappingkey',) +! fd(self={"abcF" : FailingNumber()}):TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) + fd(self=Mapping({1 : 1})):TypeError:('expected str() or unicode() instance, but got int',) +*************** +*** 1004,1017 **** + <<< Finished + >>> Testing *Iter* using fd(self=Mapping({"abcG" : %s})) + fd(self=Mapping({"abcG" : FailingIter()})):TypeError:('unable to convert FailingIter to vim structure',) +! fd(self=Mapping({"abcG" : FailingIterNext()})):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=Mapping({"abcG" : %s})) + fd(self=Mapping({"abcG" : None})):TypeError:('unable to convert NoneType to vim structure',) + fd(self=Mapping({"abcG" : {"": 1}})):ValueError:('empty keys are not allowed',) + fd(self=Mapping({"abcG" : {u"": 1}})):ValueError:('empty keys are not allowed',) +! fd(self=Mapping({"abcG" : FailingMapping()})):NotImplementedError:() +! fd(self=Mapping({"abcG" : FailingMappingKey()})):NotImplementedError:() + <<< Finished + >>> Testing *Iter* using fd(self=%s) + fd(self=FailingIter()):TypeError:('unable to convert FailingIter to vim dictionary',) +--- 1083,1097 ---- + <<< Finished + >>> Testing *Iter* using fd(self=Mapping({"abcG" : %s})) + fd(self=Mapping({"abcG" : FailingIter()})):TypeError:('unable to convert FailingIter to vim structure',) +! fd(self=Mapping({"abcG" : FailingIterNext()})):NotImplementedError:('next',) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=Mapping({"abcG" : %s})) + fd(self=Mapping({"abcG" : None})):TypeError:('unable to convert NoneType to vim structure',) + fd(self=Mapping({"abcG" : {"": 1}})):ValueError:('empty keys are not allowed',) + fd(self=Mapping({"abcG" : {u"": 1}})):ValueError:('empty keys are not allowed',) +! fd(self=Mapping({"abcG" : FailingMapping()})):NotImplementedError:('keys',) +! fd(self=Mapping({"abcG" : FailingMappingKey()})):NotImplementedError:('getitem:mappingkey',) +! fd(self=Mapping({"abcG" : FailingNumber()})):TypeError:('long() argument must be a string or a number',) + <<< Finished + >>> Testing *Iter* using fd(self=%s) + fd(self=FailingIter()):TypeError:('unable to convert FailingIter to vim dictionary',) +*************** +*** 1021,1028 **** + fd(self=None):TypeError:('unable to convert NoneType to vim dictionary',) + fd(self={"": 1}):ValueError:('empty keys are not allowed',) + fd(self={u"": 1}):ValueError:('empty keys are not allowed',) +! fd(self=FailingMapping()):NotImplementedError:() +! fd(self=FailingMappingKey()):NotImplementedError:() + <<< Finished + >>> Testing ConvertFromPyMapping using fd(self=%s) + fd(self=[]):TypeError:('unable to convert list to vim dictionary',) +--- 1101,1109 ---- + fd(self=None):TypeError:('unable to convert NoneType to vim dictionary',) + fd(self={"": 1}):ValueError:('empty keys are not allowed',) + fd(self={u"": 1}):ValueError:('empty keys are not allowed',) +! fd(self=FailingMapping()):NotImplementedError:('keys',) +! fd(self=FailingMappingKey()):NotImplementedError:('getitem:mappingkey',) +! fd(self=FailingNumber()):TypeError:('unable to convert FailingNumber to vim dictionary',) + <<< Finished + >>> Testing ConvertFromPyMapping using fd(self=%s) + fd(self=[]):TypeError:('unable to convert list to vim dictionary',) +*************** +*** 1040,1053 **** + vim.current.window.buffer = 0:TypeError:('readonly attribute: buffer',) + vim.current.window.cursor = (100000000, 100000000):error:('cursor position outside buffer',) + vim.current.window.cursor = True:TypeError:('argument must be 2-item sequence, not bool',) +! vim.current.window.height = "abcK":TypeError:('expected int(), long() or something supporting coercing to long(), but got str',) +! vim.current.window.width = "abcL":TypeError:('expected int(), long() or something supporting coercing to long(), but got str',) + vim.current.window.xxxxxx = True:AttributeError:('xxxxxx',) + > WinList + >> WinListItem + vim.windows[1000]:IndexError:('no such window',) + > Buffer + >> StringToLine (indirect) + vim.current.buffer[0] = "\na":error:('string cannot contain newlines',) + >> SetBufferLine (indirect) + vim.current.buffer[0] = True:TypeError:('bad argument type for built-in operation',) +--- 1121,1143 ---- + vim.current.window.buffer = 0:TypeError:('readonly attribute: buffer',) + vim.current.window.cursor = (100000000, 100000000):error:('cursor position outside buffer',) + vim.current.window.cursor = True:TypeError:('argument must be 2-item sequence, not bool',) +! >>> Testing NumberToLong using vim.current.window.height = %s +! vim.current.window.height = []:TypeError:('expected int(), long() or something supporting coercing to long(), but got list',) +! vim.current.window.height = None:TypeError:('expected int(), long() or something supporting coercing to long(), but got NoneType',) +! vim.current.window.height = -1:ValueError:('number must be greater or equal to zero',) +! <<< Finished +! >>> Testing NumberToLong using vim.current.window.width = %s +! vim.current.window.width = []:TypeError:('expected int(), long() or something supporting coercing to long(), but got list',) +! vim.current.window.width = None:TypeError:('expected int(), long() or something supporting coercing to long(), but got NoneType',) +! vim.current.window.width = -1:ValueError:('number must be greater or equal to zero',) +! <<< Finished + vim.current.window.xxxxxx = True:AttributeError:('xxxxxx',) + > WinList + >> WinListItem + vim.windows[1000]:IndexError:('no such window',) + > Buffer + >> StringToLine (indirect) ++ vim.current.buffer[0] = u"\na":error:('string cannot contain newlines',) + vim.current.buffer[0] = "\na":error:('string cannot contain newlines',) + >> SetBufferLine (indirect) + vim.current.buffer[0] = True:TypeError:('bad argument type for built-in operation',) +*************** +*** 1075,1082 **** + vim.current.buffer.range(1, 2, 3):TypeError:('function takes exactly 2 arguments (3 given)',) + > BufMap + >> BufMapItem +- vim.buffers[None]:TypeError:('expected int(), long() or something supporting coercing to long(), but got NoneType',) + vim.buffers[100000000]:KeyError:(100000000,) + > Current + >> CurrentGetattr + vim.current.xxx:AttributeError:('xxx',) +--- 1165,1177 ---- + vim.current.buffer.range(1, 2, 3):TypeError:('function takes exactly 2 arguments (3 given)',) + > BufMap + >> BufMapItem + vim.buffers[100000000]:KeyError:(100000000,) ++ >>> Testing NumberToLong using vim.buffers[%s] ++ vim.buffers[[]]:TypeError:('expected int(), long() or something supporting coercing to long(), but got list',) ++ vim.buffers[None]:TypeError:('expected int(), long() or something supporting coercing to long(), but got NoneType',) ++ vim.buffers[-1]:ValueError:('number must be greater then zero',) ++ vim.buffers[0]:ValueError:('number must be greater then zero',) ++ <<< Finished + > Current + >> CurrentGetattr + vim.current.xxx:AttributeError:('xxx',) +*************** +*** 1086,1094 **** +--- 1181,1194 ---- + vim.current.window = True:TypeError:('expected vim.Window object, but got bool',) + vim.current.tabpage = True:TypeError:('expected vim.TabPage object, but got bool',) + vim.current.xxx = True:AttributeError:('xxx',) ++ ['/testdir'] ++ '/testdir' + 2,xx + before + after ++ pythonx/topmodule/__init__.py ++ pythonx/topmodule/submodule/__init__.py ++ pythonx/topmodule/submodule/subsubmodule/subsubsubmodule.py + vim.command("throw 'abcN'"):error:('abcN',) + Exe("throw 'def'"):error:('def',) + vim.eval("Exe('throw ''ghi''')"):error:('ghi',) +*** ../vim-7.3.1235/src/testdir/test87.in 2013-06-23 14:37:00.000000000 +0200 +--- src/testdir/test87.in 2013-06-23 16:26:40.000000000 +0200 +*************** +*** 290,296 **** + :" threading + :let l = [0] + :py3 l=vim.bindeval('l') +! :py3 < Output") + cb.append(">> OutputSetattr") + ee('del sys.stdout.softspace') +! ee('sys.stdout.softspace = []') + ee('sys.stdout.attr = None') + cb.append(">> OutputWrite") + ee('sys.stdout.write(None)') +--- 913,980 ---- + 'FailingIterNext()', + )) + ++ def number_test(expr, natural=False, unsigned=False): ++ if natural: ++ unsigned = True ++ return subexpr_test(expr, 'NumberToLong', ( ++ '[]', ++ 'None', ++ ) + (('-1',) if unsigned else ()) ++ + (('0',) if natural else ())) ++ + class FailingTrue(object): + def __bool__(self): +! raise NotImplementedError('bool') + + class FailingIter(object): + def __iter__(self): +! raise NotImplementedError('iter') + + class FailingIterNext(object): + def __iter__(self): + return self + + def __next__(self): +! raise NotImplementedError('next') + + class FailingMappingKey(object): + def __getitem__(self, item): +! raise NotImplementedError('getitem:mappingkey') + + def keys(self): + return list("abcH") + + class FailingMapping(object): + def __getitem__(self): +! raise NotImplementedError('getitem:mapping') + + def keys(self): +! raise NotImplementedError('keys') + + class FailingList(list): + def __getitem__(self, idx): + if i == 2: +! raise NotImplementedError('getitem:list') + else: + return super(FailingList, self).__getitem__(idx) + ++ class NoArgsCall(object): ++ def __call__(self): ++ pass ++ ++ class FailingCall(object): ++ def __call__(self, path): ++ raise NotImplementedError('call') ++ ++ class FailingNumber(object): ++ def __int__(self): ++ raise NotImplementedError('int') ++ + cb.append("> Output") + cb.append(">> OutputSetattr") + ee('del sys.stdout.softspace') +! number_test('sys.stdout.softspace = %s', unsigned=True) +! number_test('sys.stderr.softspace = %s', unsigned=True) + ee('sys.stdout.attr = None') + cb.append(">> OutputWrite") + ee('sys.stdout.write(None)') +*************** +*** 960,977 **** + ee('sys.stdout.writelines([1])') + iter_test('sys.stdout.writelines(%s)') + cb.append("> VimCommand") +! ee('vim.command(1)') + #! Not checked: vim->python exceptions translating: checked later + cb.append("> VimToPython") + #! Not checked: everything: needs errors in internal python functions + cb.append("> VimEval") +! ee('vim.eval(1)') + #! Not checked: everything: needs errors in internal python functions + cb.append("> VimEvalPy") +! ee('vim.bindeval(1)') + #! Not checked: vim->python exceptions translating: checked later + cb.append("> VimStrwidth") +! ee('vim.strwidth(1)') + cb.append("> Dictionary") + cb.append(">> DictionaryConstructor") + ee('vim.Dictionary("abcI")') +--- 983,1016 ---- + ee('sys.stdout.writelines([1])') + iter_test('sys.stdout.writelines(%s)') + cb.append("> VimCommand") +! stringtochars_test('vim.command(%s)') +! ee('vim.command("", 2)') + #! Not checked: vim->python exceptions translating: checked later + cb.append("> VimToPython") + #! Not checked: everything: needs errors in internal python functions + cb.append("> VimEval") +! stringtochars_test('vim.eval(%s)') +! ee('vim.eval("", FailingTrue())') + #! Not checked: everything: needs errors in internal python functions + cb.append("> VimEvalPy") +! stringtochars_test('vim.bindeval(%s)') +! ee('vim.eval("", 2)') + #! Not checked: vim->python exceptions translating: checked later + cb.append("> VimStrwidth") +! stringtochars_test('vim.strwidth(%s)') +! cb.append("> VimForeachRTP") +! ee('vim.foreach_rtp(None)') +! ee('vim.foreach_rtp(NoArgsCall())') +! ee('vim.foreach_rtp(FailingCall())') +! ee('vim.foreach_rtp(int, 2)') +! cb.append('> import') +! old_rtp = vim.options['rtp'] +! vim.options['rtp'] = os.getcwd().replace(',', '\\,').replace('\\', '\\\\') +! ee('import xxx_no_such_module_xxx') +! ee('import failing_import') +! ee('import failing') +! vim.options['rtp'] = old_rtp +! del old_rtp + cb.append("> Dictionary") + cb.append(">> DictionaryConstructor") + ee('vim.Dictionary("abcI")') +*************** +*** 1050,1057 **** + ee('vim.current.window.buffer = 0') + ee('vim.current.window.cursor = (100000000, 100000000)') + ee('vim.current.window.cursor = True') +! ee('vim.current.window.height = "abcK"') +! ee('vim.current.window.width = "abcL"') + ee('vim.current.window.xxxxxx = True') + cb.append("> WinList") + cb.append(">> WinListItem") +--- 1089,1096 ---- + ee('vim.current.window.buffer = 0') + ee('vim.current.window.cursor = (100000000, 100000000)') + ee('vim.current.window.cursor = True') +! number_test('vim.current.window.height = %s', unsigned=True) +! number_test('vim.current.window.width = %s', unsigned=True) + ee('vim.current.window.xxxxxx = True') + cb.append("> WinList") + cb.append(">> WinListItem") +*************** +*** 1059,1064 **** +--- 1098,1104 ---- + cb.append("> Buffer") + cb.append(">> StringToLine (indirect)") + ee('vim.current.buffer[0] = "\\na"') ++ ee('vim.current.buffer[0] = b"\\na"') + cb.append(">> SetBufferLine (indirect)") + ee('vim.current.buffer[0] = True') + cb.append(">> SetBufferLineList (indirect)") +*************** +*** 1085,1092 **** + ee('vim.current.buffer.range(1, 2, 3)') + cb.append("> BufMap") + cb.append(">> BufMapItem") +- ee('vim.buffers[None]') + ee('vim.buffers[100000000]') + cb.append("> Current") + cb.append(">> CurrentGetattr") + ee('vim.current.xxx') +--- 1125,1132 ---- + ee('vim.current.buffer.range(1, 2, 3)') + cb.append("> BufMap") + cb.append(">> BufMapItem") + ee('vim.buffers[100000000]') ++ number_test('vim.buffers[%s]', natural=True) + cb.append("> Current") + cb.append(">> CurrentGetattr") + ee('vim.current.xxx') +*************** +*** 1110,1121 **** +--- 1150,1165 ---- + del convertfrompyobject_test + del convertfrompymapping_test + del iter_test ++ del number_test + del FailingTrue + del FailingIter + del FailingIterNext + del FailingMapping + del FailingMappingKey + del FailingList ++ del NoArgsCall ++ del FailingCall ++ del FailingNumber + EOF + :delfunction F + :" +*************** +*** 1124,1129 **** +--- 1168,1183 ---- + sys.path.insert(0, os.path.join(os.getcwd(), 'python_before')) + sys.path.append(os.path.join(os.getcwd(), 'python_after')) + vim.options['rtp'] = os.getcwd().replace(',', '\\,').replace('\\', '\\\\') ++ l = [] ++ def callback(path): ++ l.append(os.path.relpath(path)) ++ vim.foreach_rtp(callback) ++ cb.append(repr(l)) ++ del l ++ def callback(path): ++ return os.path.relpath(path) ++ cb.append(repr(vim.foreach_rtp(callback))) ++ del callback + from module import dir as d + from modulex import ddir + cb.append(d + ',' + ddir) +*************** +*** 1131,1140 **** +--- 1185,1203 ---- + cb.append(before.dir) + import after + cb.append(after.dir) ++ import topmodule as tm ++ import topmodule.submodule as tms ++ import topmodule.submodule.subsubmodule.subsubsubmodule as tmsss ++ cb.append(tm.__file__[-len('modulex/topmodule/__init__.py'):]) ++ cb.append(tms.__file__[-len('modulex/topmodule/submodule/__init__.py'):]) ++ cb.append(tmsss.__file__[-len('modulex/topmodule/submodule/subsubmodule/subsubsubmodule.py'):]) + del before + del after + del d + del ddir ++ del tm ++ del tms ++ del tmsss + EOF + :" + :" Test exceptions +*************** +*** 1188,1193 **** +--- 1251,1257 ---- + :call garbagecollect(1) + :" + :/^start:/,$wq! test.out ++ :" vim: et ts=4 isk-=\: + :call getchar() + ENDTEST + +*** ../vim-7.3.1235/src/testdir/test87.ok 2013-06-23 14:37:00.000000000 +0200 +--- src/testdir/test87.ok 2013-06-23 16:26:40.000000000 +0200 +*************** +*** 430,436 **** +--- 430,445 ---- + > Output + >> OutputSetattr + del sys.stdout.softspace:(, AttributeError("can't delete OutputObject attributes",)) ++ >>> Testing NumberToLong using sys.stdout.softspace = %s + sys.stdout.softspace = []:(, TypeError('expected int() or something supporting coercing to int(), but got list',)) ++ sys.stdout.softspace = None:(, TypeError('expected int() or something supporting coercing to int(), but got NoneType',)) ++ sys.stdout.softspace = -1:(, ValueError('number must be greater or equal to zero',)) ++ <<< Finished ++ >>> Testing NumberToLong using sys.stderr.softspace = %s ++ sys.stderr.softspace = []:(, TypeError('expected int() or something supporting coercing to int(), but got list',)) ++ sys.stderr.softspace = None:(, TypeError('expected int() or something supporting coercing to int(), but got NoneType',)) ++ sys.stderr.softspace = -1:(, ValueError('number must be greater or equal to zero',)) ++ <<< Finished + sys.stdout.attr = None:(, AttributeError('invalid attribute: attr',)) + >> OutputWrite + sys.stdout.write(None):(, TypeError("Can't convert 'NoneType' object to str implicitly",)) +*************** +*** 438,461 **** + sys.stdout.writelines(None):(, TypeError("'NoneType' object is not iterable",)) + sys.stdout.writelines([1]):(, TypeError("Can't convert 'int' object to str implicitly",)) + >>> Testing *Iter* using sys.stdout.writelines(%s) +! sys.stdout.writelines(FailingIter()):(, NotImplementedError()) +! sys.stdout.writelines(FailingIterNext()):(, NotImplementedError()) + <<< Finished + > VimCommand + vim.command(1):(, TypeError('expected bytes() or str() instance, but got int',)) + > VimToPython + > VimEval + vim.eval(1):(, TypeError('expected bytes() or str() instance, but got int',)) + > VimEvalPy + vim.bindeval(1):(, TypeError('expected bytes() or str() instance, but got int',)) + > VimStrwidth + vim.strwidth(1):(, TypeError('expected bytes() or str() instance, but got int',)) + > Dictionary + >> DictionaryConstructor + vim.Dictionary("abcI"):(, ValueError('expected sequence element of size 2, but got sequence of size 1',)) + >> DictionarySetattr + del d.locked:(, AttributeError('cannot delete vim.Dictionary attributes',)) +! d.locked = FailingTrue():(, NotImplementedError()) + vim.vvars.locked = False:(, TypeError('cannot modify fixed dictionary',)) + d.scope = True:(, AttributeError('cannot set attribute scope',)) + d.xxx = True:(, AttributeError('cannot set attribute xxx',)) +--- 447,498 ---- + sys.stdout.writelines(None):(, TypeError("'NoneType' object is not iterable",)) + sys.stdout.writelines([1]):(, TypeError("Can't convert 'int' object to str implicitly",)) + >>> Testing *Iter* using sys.stdout.writelines(%s) +! sys.stdout.writelines(FailingIter()):(, NotImplementedError('iter',)) +! sys.stdout.writelines(FailingIterNext()):(, NotImplementedError('next',)) + <<< Finished + > VimCommand ++ >>> Testing StringToChars using vim.command(%s) + vim.command(1):(, TypeError('expected bytes() or str() instance, but got int',)) ++ vim.command(b"\0"):(, TypeError('expected bytes with no null',)) ++ vim.command("\0"):(, TypeError('expected bytes with no null',)) ++ <<< Finished ++ vim.command("", 2):(, TypeError('command() takes exactly one argument (2 given)',)) + > VimToPython + > VimEval ++ >>> Testing StringToChars using vim.eval(%s) + vim.eval(1):(, TypeError('expected bytes() or str() instance, but got int',)) ++ vim.eval(b"\0"):(, TypeError('expected bytes with no null',)) ++ vim.eval("\0"):(, TypeError('expected bytes with no null',)) ++ <<< Finished ++ vim.eval("", FailingTrue()):(, TypeError('function takes exactly 1 argument (2 given)',)) + > VimEvalPy ++ >>> Testing StringToChars using vim.bindeval(%s) + vim.bindeval(1):(, TypeError('expected bytes() or str() instance, but got int',)) ++ vim.bindeval(b"\0"):(, TypeError('expected bytes with no null',)) ++ vim.bindeval("\0"):(, TypeError('expected bytes with no null',)) ++ <<< Finished ++ vim.eval("", 2):(, TypeError('function takes exactly 1 argument (2 given)',)) + > VimStrwidth ++ >>> Testing StringToChars using vim.strwidth(%s) + vim.strwidth(1):(, TypeError('expected bytes() or str() instance, but got int',)) ++ vim.strwidth(b"\0"):(, TypeError('expected bytes with no null',)) ++ vim.strwidth("\0"):(, TypeError('expected bytes with no null',)) ++ <<< Finished ++ > VimForeachRTP ++ vim.foreach_rtp(None):(, TypeError("'NoneType' object is not callable",)) ++ vim.foreach_rtp(NoArgsCall()):(, TypeError('__call__() takes exactly 1 positional argument (2 given)',)) ++ vim.foreach_rtp(FailingCall()):(, NotImplementedError('call',)) ++ vim.foreach_rtp(int, 2):(, TypeError('foreach_rtp() takes exactly one argument (2 given)',)) ++ > import ++ import xxx_no_such_module_xxx:(, ImportError('No module named xxx_no_such_module_xxx',)) ++ import failing_import:(, ImportError('No module named failing_import',)) ++ import failing:(, ImportError('No module named failing',)) + > Dictionary + >> DictionaryConstructor + vim.Dictionary("abcI"):(, ValueError('expected sequence element of size 2, but got sequence of size 1',)) + >> DictionarySetattr + del d.locked:(, AttributeError('cannot delete vim.Dictionary attributes',)) +! d.locked = FailingTrue():(, NotImplementedError('bool',)) + vim.vvars.locked = False:(, TypeError('cannot modify fixed dictionary',)) + d.scope = True:(, AttributeError('cannot set attribute scope',)) + d.xxx = True:(, AttributeError('cannot set attribute xxx',)) +*************** +*** 494,507 **** + <<< Finished + >>> Testing *Iter* using d["a"] = {"abcF" : %s} + d["a"] = {"abcF" : FailingIter()}:(, TypeError('unable to convert FailingIter to vim structure',)) +! d["a"] = {"abcF" : FailingIterNext()}:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = {"abcF" : %s} + d["a"] = {"abcF" : None}:(, TypeError('unable to convert NoneType to vim structure',)) + d["a"] = {"abcF" : {b"": 1}}:(, ValueError('empty keys are not allowed',)) + d["a"] = {"abcF" : {"": 1}}:(, ValueError('empty keys are not allowed',)) +! d["a"] = {"abcF" : FailingMapping()}:(, NotImplementedError()) +! d["a"] = {"abcF" : FailingMappingKey()}:(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) + d["a"] = Mapping({1 : 1}):(, TypeError('expected bytes() or str() instance, but got int',)) +--- 531,545 ---- + <<< Finished + >>> Testing *Iter* using d["a"] = {"abcF" : %s} + d["a"] = {"abcF" : FailingIter()}:(, TypeError('unable to convert FailingIter to vim structure',)) +! d["a"] = {"abcF" : FailingIterNext()}:(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = {"abcF" : %s} + d["a"] = {"abcF" : None}:(, TypeError('unable to convert NoneType to vim structure',)) + d["a"] = {"abcF" : {b"": 1}}:(, ValueError('empty keys are not allowed',)) + d["a"] = {"abcF" : {"": 1}}:(, ValueError('empty keys are not allowed',)) +! d["a"] = {"abcF" : FailingMapping()}:(, NotImplementedError('keys',)) +! d["a"] = {"abcF" : FailingMappingKey()}:(, NotImplementedError('getitem:mappingkey',)) +! d["a"] = {"abcF" : FailingNumber()}:(, NotImplementedError('int',)) + <<< Finished + >>> Testing StringToChars using d["a"] = Mapping({%s : 1}) + d["a"] = Mapping({1 : 1}):(, TypeError('expected bytes() or str() instance, but got int',)) +*************** +*** 520,553 **** + <<< Finished + >>> Testing *Iter* using d["a"] = Mapping({"abcG" : %s}) + d["a"] = Mapping({"abcG" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! d["a"] = Mapping({"abcG" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abcG" : %s}) + d["a"] = Mapping({"abcG" : None}):(, TypeError('unable to convert NoneType to vim structure',)) + d["a"] = Mapping({"abcG" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + d["a"] = Mapping({"abcG" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! d["a"] = Mapping({"abcG" : FailingMapping()}):(, NotImplementedError()) +! d["a"] = Mapping({"abcG" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d["a"] = %s + d["a"] = FailingIter():(, TypeError('unable to convert FailingIter to vim structure',)) +! d["a"] = FailingIterNext():(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = %s + d["a"] = None:(, TypeError('unable to convert NoneType to vim structure',)) + d["a"] = {b"": 1}:(, ValueError('empty keys are not allowed',)) + d["a"] = {"": 1}:(, ValueError('empty keys are not allowed',)) +! d["a"] = FailingMapping():(, NotImplementedError()) +! d["a"] = FailingMappingKey():(, NotImplementedError()) + <<< Finished + >> DictionaryUpdate + >>> kwargs + >>> iter +! d.update(FailingMapping()):(, NotImplementedError()) +! d.update([FailingIterNext()]):(, NotImplementedError()) + >>> Testing *Iter* using d.update(%s) +! d.update(FailingIter()):(, NotImplementedError()) +! d.update(FailingIterNext()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update({%s : 1}) + d.update({1 : 1}):(, TypeError('expected bytes() or str() instance, but got int',)) +--- 558,593 ---- + <<< Finished + >>> Testing *Iter* using d["a"] = Mapping({"abcG" : %s}) + d["a"] = Mapping({"abcG" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! d["a"] = Mapping({"abcG" : FailingIterNext()}):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = Mapping({"abcG" : %s}) + d["a"] = Mapping({"abcG" : None}):(, TypeError('unable to convert NoneType to vim structure',)) + d["a"] = Mapping({"abcG" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + d["a"] = Mapping({"abcG" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! d["a"] = Mapping({"abcG" : FailingMapping()}):(, NotImplementedError('keys',)) +! d["a"] = Mapping({"abcG" : FailingMappingKey()}):(, NotImplementedError('getitem:mappingkey',)) +! d["a"] = Mapping({"abcG" : FailingNumber()}):(, NotImplementedError('int',)) + <<< Finished + >>> Testing *Iter* using d["a"] = %s + d["a"] = FailingIter():(, TypeError('unable to convert FailingIter to vim structure',)) +! d["a"] = FailingIterNext():(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using d["a"] = %s + d["a"] = None:(, TypeError('unable to convert NoneType to vim structure',)) + d["a"] = {b"": 1}:(, ValueError('empty keys are not allowed',)) + d["a"] = {"": 1}:(, ValueError('empty keys are not allowed',)) +! d["a"] = FailingMapping():(, NotImplementedError('keys',)) +! d["a"] = FailingMappingKey():(, NotImplementedError('getitem:mappingkey',)) +! d["a"] = FailingNumber():(, NotImplementedError('int',)) + <<< Finished + >> DictionaryUpdate + >>> kwargs + >>> iter +! d.update(FailingMapping()):(, NotImplementedError('keys',)) +! d.update([FailingIterNext()]):(, NotImplementedError('next',)) + >>> Testing *Iter* using d.update(%s) +! d.update(FailingIter()):(, NotImplementedError('iter',)) +! d.update(FailingIterNext()):(, NotImplementedError('next',)) + <<< Finished + >>> Testing StringToChars using d.update({%s : 1}) + d.update({1 : 1}):(, TypeError('expected bytes() or str() instance, but got int',)) +*************** +*** 566,579 **** + <<< Finished + >>> Testing *Iter* using d.update({"abcF" : %s}) + d.update({"abcF" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update({"abcF" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update({"abcF" : %s}) + d.update({"abcF" : None}):(, TypeError('unable to convert NoneType to vim structure',)) + d.update({"abcF" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + d.update({"abcF" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! d.update({"abcF" : FailingMapping()}):(, NotImplementedError()) +! d.update({"abcF" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) + d.update(Mapping({1 : 1})):(, TypeError('expected bytes() or str() instance, but got int',)) +--- 606,620 ---- + <<< Finished + >>> Testing *Iter* using d.update({"abcF" : %s}) + d.update({"abcF" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update({"abcF" : FailingIterNext()}):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using d.update({"abcF" : %s}) + d.update({"abcF" : None}):(, TypeError('unable to convert NoneType to vim structure',)) + d.update({"abcF" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + d.update({"abcF" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! d.update({"abcF" : FailingMapping()}):(, NotImplementedError('keys',)) +! d.update({"abcF" : FailingMappingKey()}):(, NotImplementedError('getitem:mappingkey',)) +! d.update({"abcF" : FailingNumber()}):(, NotImplementedError('int',)) + <<< Finished + >>> Testing StringToChars using d.update(Mapping({%s : 1})) + d.update(Mapping({1 : 1})):(, TypeError('expected bytes() or str() instance, but got int',)) +*************** +*** 592,616 **** + <<< Finished + >>> Testing *Iter* using d.update(Mapping({"abcG" : %s})) + d.update(Mapping({"abcG" : FailingIter()})):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update(Mapping({"abcG" : FailingIterNext()})):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update(Mapping({"abcG" : %s})) + d.update(Mapping({"abcG" : None})):(, TypeError('unable to convert NoneType to vim structure',)) + d.update(Mapping({"abcG" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) + d.update(Mapping({"abcG" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! d.update(Mapping({"abcG" : FailingMapping()})):(, NotImplementedError()) +! d.update(Mapping({"abcG" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d.update(%s) +! d.update(FailingIter()):(, NotImplementedError()) +! d.update(FailingIterNext()):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update(%s) + d.update(None):(, TypeError("'NoneType' object is not iterable",)) + d.update({b"": 1}):(, ValueError('empty keys are not allowed',)) + d.update({"": 1}):(, ValueError('empty keys are not allowed',)) +! d.update(FailingMapping()):(, NotImplementedError()) +! d.update(FailingMappingKey()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update(((%s, 0),)) + d.update(((1, 0),)):(, TypeError('expected bytes() or str() instance, but got int',)) +--- 633,659 ---- + <<< Finished + >>> Testing *Iter* using d.update(Mapping({"abcG" : %s})) + d.update(Mapping({"abcG" : FailingIter()})):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update(Mapping({"abcG" : FailingIterNext()})):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using d.update(Mapping({"abcG" : %s})) + d.update(Mapping({"abcG" : None})):(, TypeError('unable to convert NoneType to vim structure',)) + d.update(Mapping({"abcG" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) + d.update(Mapping({"abcG" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! d.update(Mapping({"abcG" : FailingMapping()})):(, NotImplementedError('keys',)) +! d.update(Mapping({"abcG" : FailingMappingKey()})):(, NotImplementedError('getitem:mappingkey',)) +! d.update(Mapping({"abcG" : FailingNumber()})):(, NotImplementedError('int',)) + <<< Finished + >>> Testing *Iter* using d.update(%s) +! d.update(FailingIter()):(, NotImplementedError('iter',)) +! d.update(FailingIterNext()):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using d.update(%s) + d.update(None):(, TypeError("'NoneType' object is not iterable",)) + d.update({b"": 1}):(, ValueError('empty keys are not allowed',)) + d.update({"": 1}):(, ValueError('empty keys are not allowed',)) +! d.update(FailingMapping()):(, NotImplementedError('keys',)) +! d.update(FailingMappingKey()):(, NotImplementedError('getitem:mappingkey',)) +! d.update(FailingNumber()):(, TypeError("'FailingNumber' object is not iterable",)) + <<< Finished + >>> Testing StringToChars using d.update(((%s, 0),)) + d.update(((1, 0),)):(, TypeError('expected bytes() or str() instance, but got int',)) +*************** +*** 634,647 **** + <<< Finished + >>> Testing *Iter* using d.update((("a", {"abcF" : %s}),)) + d.update((("a", {"abcF" : FailingIter()}),)):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update((("a", {"abcF" : FailingIterNext()}),)):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", {"abcF" : %s}),)) + d.update((("a", {"abcF" : None}),)):(, TypeError('unable to convert NoneType to vim structure',)) + d.update((("a", {"abcF" : {b"": 1}}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", {"abcF" : {"": 1}}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", {"abcF" : FailingMapping()}),)):(, NotImplementedError()) +! d.update((("a", {"abcF" : FailingMappingKey()}),)):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) + d.update((("a", Mapping({1 : 1})),)):(, TypeError('expected bytes() or str() instance, but got int',)) +--- 677,691 ---- + <<< Finished + >>> Testing *Iter* using d.update((("a", {"abcF" : %s}),)) + d.update((("a", {"abcF" : FailingIter()}),)):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update((("a", {"abcF" : FailingIterNext()}),)):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", {"abcF" : %s}),)) + d.update((("a", {"abcF" : None}),)):(, TypeError('unable to convert NoneType to vim structure',)) + d.update((("a", {"abcF" : {b"": 1}}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", {"abcF" : {"": 1}}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", {"abcF" : FailingMapping()}),)):(, NotImplementedError('keys',)) +! d.update((("a", {"abcF" : FailingMappingKey()}),)):(, NotImplementedError('getitem:mappingkey',)) +! d.update((("a", {"abcF" : FailingNumber()}),)):(, NotImplementedError('int',)) + <<< Finished + >>> Testing StringToChars using d.update((("a", Mapping({%s : 1})),)) + d.update((("a", Mapping({1 : 1})),)):(, TypeError('expected bytes() or str() instance, but got int',)) +*************** +*** 660,684 **** + <<< Finished + >>> Testing *Iter* using d.update((("a", Mapping({"abcG" : %s})),)) + d.update((("a", Mapping({"abcG" : FailingIter()})),)):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update((("a", Mapping({"abcG" : FailingIterNext()})),)):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abcG" : %s})),)) + d.update((("a", Mapping({"abcG" : None})),)):(, TypeError('unable to convert NoneType to vim structure',)) + d.update((("a", Mapping({"abcG" : {b"": 1}})),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", Mapping({"abcG" : {"": 1}})),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", Mapping({"abcG" : FailingMapping()})),)):(, NotImplementedError()) +! d.update((("a", Mapping({"abcG" : FailingMappingKey()})),)):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using d.update((("a", %s),)) + d.update((("a", FailingIter()),)):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update((("a", FailingIterNext()),)):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", %s),)) + d.update((("a", None),)):(, TypeError('unable to convert NoneType to vim structure',)) + d.update((("a", {b"": 1}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", {"": 1}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", FailingMapping()),)):(, NotImplementedError()) +! d.update((("a", FailingMappingKey()),)):(, NotImplementedError()) + <<< Finished + >> DictionaryPopItem + d.popitem(1, 2):(, TypeError('popitem() takes no arguments (2 given)',)) +--- 704,730 ---- + <<< Finished + >>> Testing *Iter* using d.update((("a", Mapping({"abcG" : %s})),)) + d.update((("a", Mapping({"abcG" : FailingIter()})),)):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update((("a", Mapping({"abcG" : FailingIterNext()})),)):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", Mapping({"abcG" : %s})),)) + d.update((("a", Mapping({"abcG" : None})),)):(, TypeError('unable to convert NoneType to vim structure',)) + d.update((("a", Mapping({"abcG" : {b"": 1}})),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", Mapping({"abcG" : {"": 1}})),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", Mapping({"abcG" : FailingMapping()})),)):(, NotImplementedError('keys',)) +! d.update((("a", Mapping({"abcG" : FailingMappingKey()})),)):(, NotImplementedError('getitem:mappingkey',)) +! d.update((("a", Mapping({"abcG" : FailingNumber()})),)):(, NotImplementedError('int',)) + <<< Finished + >>> Testing *Iter* using d.update((("a", %s),)) + d.update((("a", FailingIter()),)):(, TypeError('unable to convert FailingIter to vim structure',)) +! d.update((("a", FailingIterNext()),)):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using d.update((("a", %s),)) + d.update((("a", None),)):(, TypeError('unable to convert NoneType to vim structure',)) + d.update((("a", {b"": 1}),)):(, ValueError('empty keys are not allowed',)) + d.update((("a", {"": 1}),)):(, ValueError('empty keys are not allowed',)) +! d.update((("a", FailingMapping()),)):(, NotImplementedError('keys',)) +! d.update((("a", FailingMappingKey()),)):(, NotImplementedError('getitem:mappingkey',)) +! d.update((("a", FailingNumber()),)):(, NotImplementedError('int',)) + <<< Finished + >> DictionaryPopItem + d.popitem(1, 2):(, TypeError('popitem() takes no arguments (2 given)',)) +*************** +*** 689,696 **** + vim.List(1, 2):(, TypeError('function takes at most 1 argument (2 given)',)) + vim.List(a=1):(, TypeError('list constructor does not accept keyword arguments',)) + >>> Testing *Iter* using vim.List(%s) +! vim.List(FailingIter()):(, NotImplementedError()) +! vim.List(FailingIterNext()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using vim.List([{%s : 1}]) + vim.List([{1 : 1}]):(, TypeError('expected bytes() or str() instance, but got int',)) +--- 735,742 ---- + vim.List(1, 2):(, TypeError('function takes at most 1 argument (2 given)',)) + vim.List(a=1):(, TypeError('list constructor does not accept keyword arguments',)) + >>> Testing *Iter* using vim.List(%s) +! vim.List(FailingIter()):(, NotImplementedError('iter',)) +! vim.List(FailingIterNext()):(, NotImplementedError('next',)) + <<< Finished + >>> Testing StringToChars using vim.List([{%s : 1}]) + vim.List([{1 : 1}]):(, TypeError('expected bytes() or str() instance, but got int',)) +*************** +*** 709,722 **** + <<< Finished + >>> Testing *Iter* using vim.List([{"abcF" : %s}]) + vim.List([{"abcF" : FailingIter()}]):(, TypeError('unable to convert FailingIter to vim structure',)) +! vim.List([{"abcF" : FailingIterNext()}]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([{"abcF" : %s}]) + vim.List([{"abcF" : None}]):(, TypeError('unable to convert NoneType to vim structure',)) + vim.List([{"abcF" : {b"": 1}}]):(, ValueError('empty keys are not allowed',)) + vim.List([{"abcF" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) +! vim.List([{"abcF" : FailingMapping()}]):(, NotImplementedError()) +! vim.List([{"abcF" : FailingMappingKey()}]):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) + vim.List([Mapping({1 : 1})]):(, TypeError('expected bytes() or str() instance, but got int',)) +--- 755,769 ---- + <<< Finished + >>> Testing *Iter* using vim.List([{"abcF" : %s}]) + vim.List([{"abcF" : FailingIter()}]):(, TypeError('unable to convert FailingIter to vim structure',)) +! vim.List([{"abcF" : FailingIterNext()}]):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([{"abcF" : %s}]) + vim.List([{"abcF" : None}]):(, TypeError('unable to convert NoneType to vim structure',)) + vim.List([{"abcF" : {b"": 1}}]):(, ValueError('empty keys are not allowed',)) + vim.List([{"abcF" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) +! vim.List([{"abcF" : FailingMapping()}]):(, NotImplementedError('keys',)) +! vim.List([{"abcF" : FailingMappingKey()}]):(, NotImplementedError('getitem:mappingkey',)) +! vim.List([{"abcF" : FailingNumber()}]):(, NotImplementedError('int',)) + <<< Finished + >>> Testing StringToChars using vim.List([Mapping({%s : 1})]) + vim.List([Mapping({1 : 1})]):(, TypeError('expected bytes() or str() instance, but got int',)) +*************** +*** 735,759 **** + <<< Finished + >>> Testing *Iter* using vim.List([Mapping({"abcG" : %s})]) + vim.List([Mapping({"abcG" : FailingIter()})]):(, TypeError('unable to convert FailingIter to vim structure',)) +! vim.List([Mapping({"abcG" : FailingIterNext()})]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([Mapping({"abcG" : %s})]) + vim.List([Mapping({"abcG" : None})]):(, TypeError('unable to convert NoneType to vim structure',)) + vim.List([Mapping({"abcG" : {b"": 1}})]):(, ValueError('empty keys are not allowed',)) + vim.List([Mapping({"abcG" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) +! vim.List([Mapping({"abcG" : FailingMapping()})]):(, NotImplementedError()) +! vim.List([Mapping({"abcG" : FailingMappingKey()})]):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using vim.List([%s]) + vim.List([FailingIter()]):(, TypeError('unable to convert FailingIter to vim structure',)) +! vim.List([FailingIterNext()]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([%s]) + vim.List([None]):(, TypeError('unable to convert NoneType to vim structure',)) + vim.List([{b"": 1}]):(, ValueError('empty keys are not allowed',)) + vim.List([{"": 1}]):(, ValueError('empty keys are not allowed',)) +! vim.List([FailingMapping()]):(, NotImplementedError()) +! vim.List([FailingMappingKey()]):(, NotImplementedError()) + <<< Finished + >> ListItem + l[1000]:(, IndexError('list index out of range',)) +--- 782,808 ---- + <<< Finished + >>> Testing *Iter* using vim.List([Mapping({"abcG" : %s})]) + vim.List([Mapping({"abcG" : FailingIter()})]):(, TypeError('unable to convert FailingIter to vim structure',)) +! vim.List([Mapping({"abcG" : FailingIterNext()})]):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([Mapping({"abcG" : %s})]) + vim.List([Mapping({"abcG" : None})]):(, TypeError('unable to convert NoneType to vim structure',)) + vim.List([Mapping({"abcG" : {b"": 1}})]):(, ValueError('empty keys are not allowed',)) + vim.List([Mapping({"abcG" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) +! vim.List([Mapping({"abcG" : FailingMapping()})]):(, NotImplementedError('keys',)) +! vim.List([Mapping({"abcG" : FailingMappingKey()})]):(, NotImplementedError('getitem:mappingkey',)) +! vim.List([Mapping({"abcG" : FailingNumber()})]):(, NotImplementedError('int',)) + <<< Finished + >>> Testing *Iter* using vim.List([%s]) + vim.List([FailingIter()]):(, TypeError('unable to convert FailingIter to vim structure',)) +! vim.List([FailingIterNext()]):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using vim.List([%s]) + vim.List([None]):(, TypeError('unable to convert NoneType to vim structure',)) + vim.List([{b"": 1}]):(, ValueError('empty keys are not allowed',)) + vim.List([{"": 1}]):(, ValueError('empty keys are not allowed',)) +! vim.List([FailingMapping()]):(, NotImplementedError('keys',)) +! vim.List([FailingMappingKey()]):(, NotImplementedError('getitem:mappingkey',)) +! vim.List([FailingNumber()]):(, NotImplementedError('int',)) + <<< Finished + >> ListItem + l[1000]:(, IndexError('list index out of range',)) +*************** +*** 763,770 **** + >> ListAssSlice + ll[1:100] = "abcJ":(, error('list is locked',)) + >>> Testing *Iter* using l[:] = %s +! l[:] = FailingIter():(, NotImplementedError()) +! l[:] = FailingIterNext()::(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l[:] = [{%s : 1}] + l[:] = [{1 : 1}]:(, TypeError('expected bytes() or str() instance, but got int',)) +--- 812,819 ---- + >> ListAssSlice + ll[1:100] = "abcJ":(, error('list is locked',)) + >>> Testing *Iter* using l[:] = %s +! l[:] = FailingIter():(, NotImplementedError('iter',)) +! l[:] = FailingIterNext():(, NotImplementedError('next',)) + <<< Finished + >>> Testing StringToChars using l[:] = [{%s : 1}] + l[:] = [{1 : 1}]:(, TypeError('expected bytes() or str() instance, but got int',)) +*************** +*** 783,796 **** + <<< Finished + >>> Testing *Iter* using l[:] = [{"abcF" : %s}] + l[:] = [{"abcF" : FailingIter()}]:(, TypeError('unable to convert FailingIter to vim structure',)) +! l[:] = [{"abcF" : FailingIterNext()}]:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [{"abcF" : %s}] + l[:] = [{"abcF" : None}]:(, TypeError('unable to convert NoneType to vim structure',)) + l[:] = [{"abcF" : {b"": 1}}]:(, ValueError('empty keys are not allowed',)) + l[:] = [{"abcF" : {"": 1}}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [{"abcF" : FailingMapping()}]:(, NotImplementedError()) +! l[:] = [{"abcF" : FailingMappingKey()}]:(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] + l[:] = [Mapping({1 : 1})]:(, TypeError('expected bytes() or str() instance, but got int',)) +--- 832,846 ---- + <<< Finished + >>> Testing *Iter* using l[:] = [{"abcF" : %s}] + l[:] = [{"abcF" : FailingIter()}]:(, TypeError('unable to convert FailingIter to vim structure',)) +! l[:] = [{"abcF" : FailingIterNext()}]:(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [{"abcF" : %s}] + l[:] = [{"abcF" : None}]:(, TypeError('unable to convert NoneType to vim structure',)) + l[:] = [{"abcF" : {b"": 1}}]:(, ValueError('empty keys are not allowed',)) + l[:] = [{"abcF" : {"": 1}}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [{"abcF" : FailingMapping()}]:(, NotImplementedError('keys',)) +! l[:] = [{"abcF" : FailingMappingKey()}]:(, NotImplementedError('getitem:mappingkey',)) +! l[:] = [{"abcF" : FailingNumber()}]:(, NotImplementedError('int',)) + <<< Finished + >>> Testing StringToChars using l[:] = [Mapping({%s : 1})] + l[:] = [Mapping({1 : 1})]:(, TypeError('expected bytes() or str() instance, but got int',)) +*************** +*** 809,838 **** + <<< Finished + >>> Testing *Iter* using l[:] = [Mapping({"abcG" : %s})] + l[:] = [Mapping({"abcG" : FailingIter()})]:(, TypeError('unable to convert FailingIter to vim structure',)) +! l[:] = [Mapping({"abcG" : FailingIterNext()})]:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abcG" : %s})] + l[:] = [Mapping({"abcG" : None})]:(, TypeError('unable to convert NoneType to vim structure',)) + l[:] = [Mapping({"abcG" : {b"": 1}})]:(, ValueError('empty keys are not allowed',)) + l[:] = [Mapping({"abcG" : {"": 1}})]:(, ValueError('empty keys are not allowed',)) +! l[:] = [Mapping({"abcG" : FailingMapping()})]:(, NotImplementedError()) +! l[:] = [Mapping({"abcG" : FailingMappingKey()})]:(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using l[:] = [%s] + l[:] = [FailingIter()]:(, TypeError('unable to convert FailingIter to vim structure',)) +! l[:] = [FailingIterNext()]:(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [%s] + l[:] = [None]:(, TypeError('unable to convert NoneType to vim structure',)) + l[:] = [{b"": 1}]:(, ValueError('empty keys are not allowed',)) + l[:] = [{"": 1}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [FailingMapping()]:(, NotImplementedError()) +! l[:] = [FailingMappingKey()]:(, NotImplementedError()) + <<< Finished + >> ListConcatInPlace + >>> Testing *Iter* using l.extend(%s) +! l.extend(FailingIter()):(, NotImplementedError()) +! l.extend(FailingIterNext()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l.extend([{%s : 1}]) + l.extend([{1 : 1}]):(, TypeError('expected bytes() or str() instance, but got int',)) +--- 859,890 ---- + <<< Finished + >>> Testing *Iter* using l[:] = [Mapping({"abcG" : %s})] + l[:] = [Mapping({"abcG" : FailingIter()})]:(, TypeError('unable to convert FailingIter to vim structure',)) +! l[:] = [Mapping({"abcG" : FailingIterNext()})]:(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [Mapping({"abcG" : %s})] + l[:] = [Mapping({"abcG" : None})]:(, TypeError('unable to convert NoneType to vim structure',)) + l[:] = [Mapping({"abcG" : {b"": 1}})]:(, ValueError('empty keys are not allowed',)) + l[:] = [Mapping({"abcG" : {"": 1}})]:(, ValueError('empty keys are not allowed',)) +! l[:] = [Mapping({"abcG" : FailingMapping()})]:(, NotImplementedError('keys',)) +! l[:] = [Mapping({"abcG" : FailingMappingKey()})]:(, NotImplementedError('getitem:mappingkey',)) +! l[:] = [Mapping({"abcG" : FailingNumber()})]:(, NotImplementedError('int',)) + <<< Finished + >>> Testing *Iter* using l[:] = [%s] + l[:] = [FailingIter()]:(, TypeError('unable to convert FailingIter to vim structure',)) +! l[:] = [FailingIterNext()]:(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using l[:] = [%s] + l[:] = [None]:(, TypeError('unable to convert NoneType to vim structure',)) + l[:] = [{b"": 1}]:(, ValueError('empty keys are not allowed',)) + l[:] = [{"": 1}]:(, ValueError('empty keys are not allowed',)) +! l[:] = [FailingMapping()]:(, NotImplementedError('keys',)) +! l[:] = [FailingMappingKey()]:(, NotImplementedError('getitem:mappingkey',)) +! l[:] = [FailingNumber()]:(, NotImplementedError('int',)) + <<< Finished + >> ListConcatInPlace + >>> Testing *Iter* using l.extend(%s) +! l.extend(FailingIter()):(, NotImplementedError('iter',)) +! l.extend(FailingIterNext()):(, NotImplementedError('next',)) + <<< Finished + >>> Testing StringToChars using l.extend([{%s : 1}]) + l.extend([{1 : 1}]):(, TypeError('expected bytes() or str() instance, but got int',)) +*************** +*** 851,864 **** + <<< Finished + >>> Testing *Iter* using l.extend([{"abcF" : %s}]) + l.extend([{"abcF" : FailingIter()}]):(, TypeError('unable to convert FailingIter to vim structure',)) +! l.extend([{"abcF" : FailingIterNext()}]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([{"abcF" : %s}]) + l.extend([{"abcF" : None}]):(, TypeError('unable to convert NoneType to vim structure',)) + l.extend([{"abcF" : {b"": 1}}]):(, ValueError('empty keys are not allowed',)) + l.extend([{"abcF" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) +! l.extend([{"abcF" : FailingMapping()}]):(, NotImplementedError()) +! l.extend([{"abcF" : FailingMappingKey()}]):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) + l.extend([Mapping({1 : 1})]):(, TypeError('expected bytes() or str() instance, but got int',)) +--- 903,917 ---- + <<< Finished + >>> Testing *Iter* using l.extend([{"abcF" : %s}]) + l.extend([{"abcF" : FailingIter()}]):(, TypeError('unable to convert FailingIter to vim structure',)) +! l.extend([{"abcF" : FailingIterNext()}]):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([{"abcF" : %s}]) + l.extend([{"abcF" : None}]):(, TypeError('unable to convert NoneType to vim structure',)) + l.extend([{"abcF" : {b"": 1}}]):(, ValueError('empty keys are not allowed',)) + l.extend([{"abcF" : {"": 1}}]):(, ValueError('empty keys are not allowed',)) +! l.extend([{"abcF" : FailingMapping()}]):(, NotImplementedError('keys',)) +! l.extend([{"abcF" : FailingMappingKey()}]):(, NotImplementedError('getitem:mappingkey',)) +! l.extend([{"abcF" : FailingNumber()}]):(, NotImplementedError('int',)) + <<< Finished + >>> Testing StringToChars using l.extend([Mapping({%s : 1})]) + l.extend([Mapping({1 : 1})]):(, TypeError('expected bytes() or str() instance, but got int',)) +*************** +*** 877,905 **** + <<< Finished + >>> Testing *Iter* using l.extend([Mapping({"abcG" : %s})]) + l.extend([Mapping({"abcG" : FailingIter()})]):(, TypeError('unable to convert FailingIter to vim structure',)) +! l.extend([Mapping({"abcG" : FailingIterNext()})]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([Mapping({"abcG" : %s})]) + l.extend([Mapping({"abcG" : None})]):(, TypeError('unable to convert NoneType to vim structure',)) + l.extend([Mapping({"abcG" : {b"": 1}})]):(, ValueError('empty keys are not allowed',)) + l.extend([Mapping({"abcG" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) +! l.extend([Mapping({"abcG" : FailingMapping()})]):(, NotImplementedError()) +! l.extend([Mapping({"abcG" : FailingMappingKey()})]):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using l.extend([%s]) + l.extend([FailingIter()]):(, TypeError('unable to convert FailingIter to vim structure',)) +! l.extend([FailingIterNext()]):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([%s]) + l.extend([None]):(, TypeError('unable to convert NoneType to vim structure',)) + l.extend([{b"": 1}]):(, ValueError('empty keys are not allowed',)) + l.extend([{"": 1}]):(, ValueError('empty keys are not allowed',)) +! l.extend([FailingMapping()]):(, NotImplementedError()) +! l.extend([FailingMappingKey()]):(, NotImplementedError()) + <<< Finished + >> ListSetattr + del l.locked:(, AttributeError('cannot delete vim.List attributes',)) +! l.locked = FailingTrue():(, NotImplementedError()) + l.xxx = True:(, AttributeError('cannot set attribute xxx',)) + > Function + >> FunctionConstructor +--- 930,960 ---- + <<< Finished + >>> Testing *Iter* using l.extend([Mapping({"abcG" : %s})]) + l.extend([Mapping({"abcG" : FailingIter()})]):(, TypeError('unable to convert FailingIter to vim structure',)) +! l.extend([Mapping({"abcG" : FailingIterNext()})]):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([Mapping({"abcG" : %s})]) + l.extend([Mapping({"abcG" : None})]):(, TypeError('unable to convert NoneType to vim structure',)) + l.extend([Mapping({"abcG" : {b"": 1}})]):(, ValueError('empty keys are not allowed',)) + l.extend([Mapping({"abcG" : {"": 1}})]):(, ValueError('empty keys are not allowed',)) +! l.extend([Mapping({"abcG" : FailingMapping()})]):(, NotImplementedError('keys',)) +! l.extend([Mapping({"abcG" : FailingMappingKey()})]):(, NotImplementedError('getitem:mappingkey',)) +! l.extend([Mapping({"abcG" : FailingNumber()})]):(, NotImplementedError('int',)) + <<< Finished + >>> Testing *Iter* using l.extend([%s]) + l.extend([FailingIter()]):(, TypeError('unable to convert FailingIter to vim structure',)) +! l.extend([FailingIterNext()]):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using l.extend([%s]) + l.extend([None]):(, TypeError('unable to convert NoneType to vim structure',)) + l.extend([{b"": 1}]):(, ValueError('empty keys are not allowed',)) + l.extend([{"": 1}]):(, ValueError('empty keys are not allowed',)) +! l.extend([FailingMapping()]):(, NotImplementedError('keys',)) +! l.extend([FailingMappingKey()]):(, NotImplementedError('getitem:mappingkey',)) +! l.extend([FailingNumber()]):(, NotImplementedError('int',)) + <<< Finished + >> ListSetattr + del l.locked:(, AttributeError('cannot delete vim.List attributes',)) +! l.locked = FailingTrue():(, NotImplementedError('bool',)) + l.xxx = True:(, AttributeError('cannot set attribute xxx',)) + > Function + >> FunctionConstructor +*************** +*** 924,937 **** + <<< Finished + >>> Testing *Iter* using f({"abcF" : %s}) + f({"abcF" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! f({"abcF" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using f({"abcF" : %s}) + f({"abcF" : None}):(, TypeError('unable to convert NoneType to vim structure',)) + f({"abcF" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + f({"abcF" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! f({"abcF" : FailingMapping()}):(, NotImplementedError()) +! f({"abcF" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) + f(Mapping({1 : 1})):(, TypeError('expected bytes() or str() instance, but got int',)) +--- 979,993 ---- + <<< Finished + >>> Testing *Iter* using f({"abcF" : %s}) + f({"abcF" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! f({"abcF" : FailingIterNext()}):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using f({"abcF" : %s}) + f({"abcF" : None}):(, TypeError('unable to convert NoneType to vim structure',)) + f({"abcF" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + f({"abcF" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! f({"abcF" : FailingMapping()}):(, NotImplementedError('keys',)) +! f({"abcF" : FailingMappingKey()}):(, NotImplementedError('getitem:mappingkey',)) +! f({"abcF" : FailingNumber()}):(, NotImplementedError('int',)) + <<< Finished + >>> Testing StringToChars using f(Mapping({%s : 1})) + f(Mapping({1 : 1})):(, TypeError('expected bytes() or str() instance, but got int',)) +*************** +*** 950,974 **** + <<< Finished + >>> Testing *Iter* using f(Mapping({"abcG" : %s})) + f(Mapping({"abcG" : FailingIter()})):(, TypeError('unable to convert FailingIter to vim structure',)) +! f(Mapping({"abcG" : FailingIterNext()})):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using f(Mapping({"abcG" : %s})) + f(Mapping({"abcG" : None})):(, TypeError('unable to convert NoneType to vim structure',)) + f(Mapping({"abcG" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) + f(Mapping({"abcG" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! f(Mapping({"abcG" : FailingMapping()})):(, NotImplementedError()) +! f(Mapping({"abcG" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using f(%s) + f(FailingIter()):(, TypeError('unable to convert FailingIter to vim structure',)) +! f(FailingIterNext()):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using f(%s) + f(None):(, TypeError('unable to convert NoneType to vim structure',)) + f({b"": 1}):(, ValueError('empty keys are not allowed',)) + f({"": 1}):(, ValueError('empty keys are not allowed',)) +! f(FailingMapping()):(, NotImplementedError()) +! f(FailingMappingKey()):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using fd(self={%s : 1}) + fd(self={1 : 1}):(, TypeError('expected bytes() or str() instance, but got int',)) +--- 1006,1032 ---- + <<< Finished + >>> Testing *Iter* using f(Mapping({"abcG" : %s})) + f(Mapping({"abcG" : FailingIter()})):(, TypeError('unable to convert FailingIter to vim structure',)) +! f(Mapping({"abcG" : FailingIterNext()})):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using f(Mapping({"abcG" : %s})) + f(Mapping({"abcG" : None})):(, TypeError('unable to convert NoneType to vim structure',)) + f(Mapping({"abcG" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) + f(Mapping({"abcG" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! f(Mapping({"abcG" : FailingMapping()})):(, NotImplementedError('keys',)) +! f(Mapping({"abcG" : FailingMappingKey()})):(, NotImplementedError('getitem:mappingkey',)) +! f(Mapping({"abcG" : FailingNumber()})):(, NotImplementedError('int',)) + <<< Finished + >>> Testing *Iter* using f(%s) + f(FailingIter()):(, TypeError('unable to convert FailingIter to vim structure',)) +! f(FailingIterNext()):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using f(%s) + f(None):(, TypeError('unable to convert NoneType to vim structure',)) + f({b"": 1}):(, ValueError('empty keys are not allowed',)) + f({"": 1}):(, ValueError('empty keys are not allowed',)) +! f(FailingMapping()):(, NotImplementedError('keys',)) +! f(FailingMappingKey()):(, NotImplementedError('getitem:mappingkey',)) +! f(FailingNumber()):(, NotImplementedError('int',)) + <<< Finished + >>> Testing StringToChars using fd(self={%s : 1}) + fd(self={1 : 1}):(, TypeError('expected bytes() or str() instance, but got int',)) +*************** +*** 987,1000 **** + <<< Finished + >>> Testing *Iter* using fd(self={"abcF" : %s}) + fd(self={"abcF" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! fd(self={"abcF" : FailingIterNext()}):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self={"abcF" : %s}) + fd(self={"abcF" : None}):(, TypeError('unable to convert NoneType to vim structure',)) + fd(self={"abcF" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + fd(self={"abcF" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! fd(self={"abcF" : FailingMapping()}):(, NotImplementedError()) +! fd(self={"abcF" : FailingMappingKey()}):(, NotImplementedError()) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) + fd(self=Mapping({1 : 1})):(, TypeError('expected bytes() or str() instance, but got int',)) +--- 1045,1059 ---- + <<< Finished + >>> Testing *Iter* using fd(self={"abcF" : %s}) + fd(self={"abcF" : FailingIter()}):(, TypeError('unable to convert FailingIter to vim structure',)) +! fd(self={"abcF" : FailingIterNext()}):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self={"abcF" : %s}) + fd(self={"abcF" : None}):(, TypeError('unable to convert NoneType to vim structure',)) + fd(self={"abcF" : {b"": 1}}):(, ValueError('empty keys are not allowed',)) + fd(self={"abcF" : {"": 1}}):(, ValueError('empty keys are not allowed',)) +! fd(self={"abcF" : FailingMapping()}):(, NotImplementedError('keys',)) +! fd(self={"abcF" : FailingMappingKey()}):(, NotImplementedError('getitem:mappingkey',)) +! fd(self={"abcF" : FailingNumber()}):(, NotImplementedError('int',)) + <<< Finished + >>> Testing StringToChars using fd(self=Mapping({%s : 1})) + fd(self=Mapping({1 : 1})):(, TypeError('expected bytes() or str() instance, but got int',)) +*************** +*** 1013,1026 **** + <<< Finished + >>> Testing *Iter* using fd(self=Mapping({"abcG" : %s})) + fd(self=Mapping({"abcG" : FailingIter()})):(, TypeError('unable to convert FailingIter to vim structure',)) +! fd(self=Mapping({"abcG" : FailingIterNext()})):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=Mapping({"abcG" : %s})) + fd(self=Mapping({"abcG" : None})):(, TypeError('unable to convert NoneType to vim structure',)) + fd(self=Mapping({"abcG" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) + fd(self=Mapping({"abcG" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! fd(self=Mapping({"abcG" : FailingMapping()})):(, NotImplementedError()) +! fd(self=Mapping({"abcG" : FailingMappingKey()})):(, NotImplementedError()) + <<< Finished + >>> Testing *Iter* using fd(self=%s) + fd(self=FailingIter()):(, TypeError('unable to convert FailingIter to vim dictionary',)) +--- 1072,1086 ---- + <<< Finished + >>> Testing *Iter* using fd(self=Mapping({"abcG" : %s})) + fd(self=Mapping({"abcG" : FailingIter()})):(, TypeError('unable to convert FailingIter to vim structure',)) +! fd(self=Mapping({"abcG" : FailingIterNext()})):(, NotImplementedError('next',)) + <<< Finished + >>> Testing ConvertFromPyObject using fd(self=Mapping({"abcG" : %s})) + fd(self=Mapping({"abcG" : None})):(, TypeError('unable to convert NoneType to vim structure',)) + fd(self=Mapping({"abcG" : {b"": 1}})):(, ValueError('empty keys are not allowed',)) + fd(self=Mapping({"abcG" : {"": 1}})):(, ValueError('empty keys are not allowed',)) +! fd(self=Mapping({"abcG" : FailingMapping()})):(, NotImplementedError('keys',)) +! fd(self=Mapping({"abcG" : FailingMappingKey()})):(, NotImplementedError('getitem:mappingkey',)) +! fd(self=Mapping({"abcG" : FailingNumber()})):(, NotImplementedError('int',)) + <<< Finished + >>> Testing *Iter* using fd(self=%s) + fd(self=FailingIter()):(, TypeError('unable to convert FailingIter to vim dictionary',)) +*************** +*** 1030,1037 **** + fd(self=None):(, TypeError('unable to convert NoneType to vim dictionary',)) + fd(self={b"": 1}):(, ValueError('empty keys are not allowed',)) + fd(self={"": 1}):(, ValueError('empty keys are not allowed',)) +! fd(self=FailingMapping()):(, NotImplementedError()) +! fd(self=FailingMappingKey()):(, NotImplementedError()) + <<< Finished + >>> Testing ConvertFromPyMapping using fd(self=%s) + fd(self=[]):(, AttributeError('keys',)) +--- 1090,1098 ---- + fd(self=None):(, TypeError('unable to convert NoneType to vim dictionary',)) + fd(self={b"": 1}):(, ValueError('empty keys are not allowed',)) + fd(self={"": 1}):(, ValueError('empty keys are not allowed',)) +! fd(self=FailingMapping()):(, NotImplementedError('keys',)) +! fd(self=FailingMappingKey()):(, NotImplementedError('getitem:mappingkey',)) +! fd(self=FailingNumber()):(, TypeError('unable to convert FailingNumber to vim dictionary',)) + <<< Finished + >>> Testing ConvertFromPyMapping using fd(self=%s) + fd(self=[]):(, AttributeError('keys',)) +*************** +*** 1049,1056 **** + vim.current.window.buffer = 0:(, TypeError('readonly attribute: buffer',)) + vim.current.window.cursor = (100000000, 100000000):(, error('cursor position outside buffer',)) + vim.current.window.cursor = True:(, TypeError('argument must be 2-item sequence, not bool',)) +! vim.current.window.height = "abcK":(, TypeError('expected int() or something supporting coercing to int(), but got str',)) +! vim.current.window.width = "abcL":(, TypeError('expected int() or something supporting coercing to int(), but got str',)) + vim.current.window.xxxxxx = True:(, AttributeError('xxxxxx',)) + > WinList + >> WinListItem +--- 1110,1125 ---- + vim.current.window.buffer = 0:(, TypeError('readonly attribute: buffer',)) + vim.current.window.cursor = (100000000, 100000000):(, error('cursor position outside buffer',)) + vim.current.window.cursor = True:(, TypeError('argument must be 2-item sequence, not bool',)) +! >>> Testing NumberToLong using vim.current.window.height = %s +! vim.current.window.height = []:(, TypeError('expected int() or something supporting coercing to int(), but got list',)) +! vim.current.window.height = None:(, TypeError('expected int() or something supporting coercing to int(), but got NoneType',)) +! vim.current.window.height = -1:(, ValueError('number must be greater or equal to zero',)) +! <<< Finished +! >>> Testing NumberToLong using vim.current.window.width = %s +! vim.current.window.width = []:(, TypeError('expected int() or something supporting coercing to int(), but got list',)) +! vim.current.window.width = None:(, TypeError('expected int() or something supporting coercing to int(), but got NoneType',)) +! vim.current.window.width = -1:(, ValueError('number must be greater or equal to zero',)) +! <<< Finished + vim.current.window.xxxxxx = True:(, AttributeError('xxxxxx',)) + > WinList + >> WinListItem +*************** +*** 1058,1063 **** +--- 1127,1133 ---- + > Buffer + >> StringToLine (indirect) + vim.current.buffer[0] = "\na":(, error('string cannot contain newlines',)) ++ vim.current.buffer[0] = b"\na":(, error('string cannot contain newlines',)) + >> SetBufferLine (indirect) + vim.current.buffer[0] = True:(, TypeError('bad argument type for built-in operation',)) + >> SetBufferLineList (indirect) +*************** +*** 1084,1091 **** + vim.current.buffer.range(1, 2, 3):(, TypeError('function takes exactly 2 arguments (3 given)',)) + > BufMap + >> BufMapItem +- vim.buffers[None]:(, TypeError('expected int() or something supporting coercing to int(), but got NoneType',)) + vim.buffers[100000000]:(, KeyError(100000000,)) + > Current + >> CurrentGetattr + vim.current.xxx:(, AttributeError("'vim.currentdata' object has no attribute 'xxx'",)) +--- 1154,1166 ---- + vim.current.buffer.range(1, 2, 3):(, TypeError('function takes exactly 2 arguments (3 given)',)) + > BufMap + >> BufMapItem + vim.buffers[100000000]:(, KeyError(100000000,)) ++ >>> Testing NumberToLong using vim.buffers[%s] ++ vim.buffers[[]]:(, TypeError('expected int() or something supporting coercing to int(), but got list',)) ++ vim.buffers[None]:(, TypeError('expected int() or something supporting coercing to int(), but got NoneType',)) ++ vim.buffers[-1]:(, ValueError('number must be greater then zero',)) ++ vim.buffers[0]:(, ValueError('number must be greater then zero',)) ++ <<< Finished + > Current + >> CurrentGetattr + vim.current.xxx:(, AttributeError("'vim.currentdata' object has no attribute 'xxx'",)) +*************** +*** 1095,1103 **** +--- 1170,1183 ---- + vim.current.window = True:(, TypeError('expected vim.Window object, but got bool',)) + vim.current.tabpage = True:(, TypeError('expected vim.TabPage object, but got bool',)) + vim.current.xxx = True:(, AttributeError('xxx',)) ++ ['.'] ++ '.' + 3,xx + before + after ++ pythonx/topmodule/__init__.py ++ pythonx/topmodule/submodule/__init__.py ++ pythonx/topmodule/submodule/subsubmodule/subsubsubmodule.py + vim.command("throw 'abcN'"):(, error('abcN',)) + Exe("throw 'def'"):(, error('def',)) + vim.eval("Exe('throw ''ghi''')"):(, error('ghi',)) +*** ../vim-7.3.1235/src/testdir/pythonx/topmodule/__init__.py 1970-01-01 01:00:00.000000000 +0100 +--- src/testdir/pythonx/topmodule/__init__.py 2013-06-23 16:23:50.000000000 +0200 +*************** +*** 0 **** +--- 1 ---- ++ # +*** ../vim-7.3.1235/src/testdir/pythonx/topmodule/submodule/__init__.py 1970-01-01 01:00:00.000000000 +0100 +--- src/testdir/pythonx/topmodule/submodule/__init__.py 2013-06-23 16:23:50.000000000 +0200 +*************** +*** 0 **** +--- 1 ---- ++ # +*** ../vim-7.3.1235/src/testdir/pythonx/topmodule/submodule/subsubmodule/__init__.py 1970-01-01 01:00:00.000000000 +0100 +--- src/testdir/pythonx/topmodule/submodule/subsubmodule/__init__.py 2013-06-23 16:23:51.000000000 +0200 +*************** +*** 0 **** +--- 1 ---- ++ # +*** ../vim-7.3.1235/src/testdir/pythonx/topmodule/submodule/subsubmodule/subsubsubmodule.py 1970-01-01 01:00:00.000000000 +0100 +--- src/testdir/pythonx/topmodule/submodule/subsubmodule/subsubsubmodule.py 2013-06-23 16:23:51.000000000 +0200 +*************** +*** 0 **** +--- 1 ---- ++ # +*** ../vim-7.3.1235/src/version.c 2013-06-23 16:16:13.000000000 +0200 +--- src/version.c 2013-06-23 16:35:04.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1236, + /**/ + +-- +Microsoft: "Windows NT 4.0 now has the same user-interface as Windows 95" + Windows 95: "Press CTRL-ALT-DEL to reboot" +Windows NT 4.0: "Press CTRL-ALT-DEL to login" + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2e50f6941e580adf6aa08d396c0c848cabe24c5a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:34 +0200 Subject: [PATCH 1130/3340] - patchlevel 1237 --- 7.3.1237 | 89 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) create mode 100644 7.3.1237 diff --git a/7.3.1237 b/7.3.1237 new file mode 100644 index 00000000..bf257403 --- /dev/null +++ b/7.3.1237 @@ -0,0 +1,89 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1237 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1237 +Problem: Python: non-import errors not handled correctly. +Solution: Let non-ImportError exceptions pass the finder. (ZyX) +Files: src/if_py_both.h, src/testdir/test86.ok, src/testdir/test87.ok + + +*** ../vim-7.3.1236/src/if_py_both.h 2013-06-23 16:35:32.000000000 +0200 +--- src/if_py_both.h 2013-06-23 16:38:39.000000000 +0200 +*************** +*** 1199,1204 **** +--- 1199,1212 ---- + + if (!module) + { ++ if (PyErr_Occurred()) ++ { ++ if (PyErr_ExceptionMatches(PyExc_ImportError)) ++ PyErr_Clear(); ++ else ++ return NULL; ++ } ++ + Py_INCREF(Py_None); + return Py_None; + } +*** ../vim-7.3.1236/src/testdir/test86.ok 2013-06-23 16:35:32.000000000 +0200 +--- src/testdir/test86.ok 2013-06-23 16:38:39.000000000 +0200 +*************** +*** 497,503 **** + > import + import xxx_no_such_module_xxx:ImportError:('No module named xxx_no_such_module_xxx',) + import failing_import:ImportError:('No module named failing_import',) +! import failing:ImportError:('No module named failing',) + > Dictionary + >> DictionaryConstructor + vim.Dictionary("abcI"):ValueError:('expected sequence element of size 2, but got sequence of size 1',) +--- 497,503 ---- + > import + import xxx_no_such_module_xxx:ImportError:('No module named xxx_no_such_module_xxx',) + import failing_import:ImportError:('No module named failing_import',) +! import failing:NotImplementedError:() + > Dictionary + >> DictionaryConstructor + vim.Dictionary("abcI"):ValueError:('expected sequence element of size 2, but got sequence of size 1',) +*** ../vim-7.3.1236/src/testdir/test87.ok 2013-06-23 16:35:32.000000000 +0200 +--- src/testdir/test87.ok 2013-06-23 16:38:39.000000000 +0200 +*************** +*** 486,492 **** + > import + import xxx_no_such_module_xxx:(, ImportError('No module named xxx_no_such_module_xxx',)) + import failing_import:(, ImportError('No module named failing_import',)) +! import failing:(, ImportError('No module named failing',)) + > Dictionary + >> DictionaryConstructor + vim.Dictionary("abcI"):(, ValueError('expected sequence element of size 2, but got sequence of size 1',)) +--- 486,492 ---- + > import + import xxx_no_such_module_xxx:(, ImportError('No module named xxx_no_such_module_xxx',)) + import failing_import:(, ImportError('No module named failing_import',)) +! import failing:(, NotImplementedError()) + > Dictionary + >> DictionaryConstructor + vim.Dictionary("abcI"):(, ValueError('expected sequence element of size 2, but got sequence of size 1',)) +*** ../vim-7.3.1236/src/version.c 2013-06-23 16:35:32.000000000 +0200 +--- src/version.c 2013-06-23 16:38:20.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1237, + /**/ + +-- +This is an airconditioned room, do not open Windows. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 9fa34d16dd37614d2af9cd8d51196e7edfde1171 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:35 +0200 Subject: [PATCH 1131/3340] - patchlevel 1238 --- 7.3.1238 | 79 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 79 insertions(+) create mode 100644 7.3.1238 diff --git a/7.3.1238 b/7.3.1238 new file mode 100644 index 00000000..636f0f81 --- /dev/null +++ b/7.3.1238 @@ -0,0 +1,79 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1238 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1238 +Problem: Crash in Python interface on 64 bit machines. +Solution: Change argument type of PyString_AsStringAndSize. (Taro Muraoka, + Jun Takimoto) +Files: src/if_python.c + + +*** ../vim-7.3.1237/src/if_python.c 2013-06-23 16:35:32.000000000 +0200 +--- src/if_python.c 2013-06-24 20:30:38.000000000 +0200 +*************** +*** 329,335 **** + static PyTypeObject* dll_PyLong_Type; + static PyObject*(*dll_PyList_GetItem)(PyObject *, PyInt); + static int(*dll_PyList_Append)(PyObject *, PyObject *); +! static int(*dll_PyList_Insert)(PyObject *, int, PyObject *); + static PyObject*(*dll_PyList_New)(PyInt size); + static int(*dll_PyList_SetItem)(PyObject *, PyInt, PyObject *); + static PyInt(*dll_PyList_Size)(PyObject *); +--- 329,335 ---- + static PyTypeObject* dll_PyLong_Type; + static PyObject*(*dll_PyList_GetItem)(PyObject *, PyInt); + static int(*dll_PyList_Append)(PyObject *, PyObject *); +! static int(*dll_PyList_Insert)(PyObject *, PyInt, PyObject *); + static PyObject*(*dll_PyList_New)(PyInt size); + static int(*dll_PyList_SetItem)(PyObject *, PyInt, PyObject *); + static PyInt(*dll_PyList_Size)(PyObject *); +*************** +*** 365,371 **** + static PyObject* (*dll_PyObject_Call)(PyObject *, PyObject *, PyObject *); + static PyObject* (*dll_PyObject_Repr)(PyObject *); + static char*(*dll_PyString_AsString)(PyObject *); +! static int(*dll_PyString_AsStringAndSize)(PyObject *, char **, int *); + static PyObject*(*dll_PyString_FromString)(const char *); + static PyObject*(*dll_PyString_FromFormat)(const char *, ...); + static PyObject*(*dll_PyString_FromStringAndSize)(const char *, PyInt); +--- 365,371 ---- + static PyObject* (*dll_PyObject_Call)(PyObject *, PyObject *, PyObject *); + static PyObject* (*dll_PyObject_Repr)(PyObject *); + static char*(*dll_PyString_AsString)(PyObject *); +! static int(*dll_PyString_AsStringAndSize)(PyObject *, char **, PyInt *); + static PyObject*(*dll_PyString_FromString)(const char *); + static PyObject*(*dll_PyString_FromFormat)(const char *, ...); + static PyObject*(*dll_PyString_FromStringAndSize)(const char *, PyInt); +*** ../vim-7.3.1237/src/version.c 2013-06-23 16:40:34.000000000 +0200 +--- src/version.c 2013-06-24 20:26:29.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1238, + /**/ + +-- + When danger reared its ugly head, + He bravely turned his tail and fled + Yes, Brave Sir Robin turned about + And gallantly he chickened out + Bravely taking to his feet + He beat a very brave retreat + Bravest of the brave Sir Robin + Petrified of being dead + Soiled his pants then brave Sir Robin + Turned away and fled. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7fe819ece8d84043c60384fa2a7603dac9b65de9 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:36 +0200 Subject: [PATCH 1132/3340] - patchlevel 1239 --- 7.3.1239 | 105 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 105 insertions(+) create mode 100644 7.3.1239 diff --git a/7.3.1239 b/7.3.1239 new file mode 100644 index 00000000..d13654ce --- /dev/null +++ b/7.3.1239 @@ -0,0 +1,105 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1239 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1239 +Problem: Can't build with Python and MSVC10. +Solution: Move #if outside of macro. (Taro Muraoka) +Files: src/if_py_both.h + + +*** ../vim-7.3.1238/src/if_py_both.h 2013-06-23 16:40:34.000000000 +0200 +--- src/if_py_both.h 2013-06-24 21:21:03.000000000 +0200 +*************** +*** 139,151 **** + } + else + { +- PyErr_FORMAT(PyExc_TypeError, + #if PY_MAJOR_VERSION < 3 +! N_("expected str() or unicode() instance, but got %s") + #else +! N_("expected bytes() or str() instance, but got %s") + #endif +- , Py_TYPE_NAME(obj)); + return NULL; + } + +--- 139,153 ---- + } + else + { + #if PY_MAJOR_VERSION < 3 +! PyErr_FORMAT(PyExc_TypeError, +! N_("expected str() or unicode() instance, but got %s"), +! Py_TYPE_NAME(obj)); + #else +! PyErr_FORMAT(PyExc_TypeError, +! N_("expected bytes() or str() instance, but got %s"), +! Py_TYPE_NAME(obj)); + #endif + return NULL; + } + +*************** +*** 191,205 **** + } + else + { +- PyErr_FORMAT(PyExc_TypeError, + #if PY_MAJOR_VERSION < 3 + N_("expected int(), long() or something supporting " +! "coercing to long(), but got %s") + #else + N_("expected int() or something supporting coercing to int(), " +! "but got %s") + #endif +- , Py_TYPE_NAME(obj)); + return -1; + } + +--- 193,209 ---- + } + else + { + #if PY_MAJOR_VERSION < 3 ++ PyErr_FORMAT(PyExc_TypeError, + N_("expected int(), long() or something supporting " +! "coercing to long(), but got %s"), +! Py_TYPE_NAME(obj)); + #else ++ PyErr_FORMAT(PyExc_TypeError, + N_("expected int() or something supporting coercing to int(), " +! "but got %s"), +! Py_TYPE_NAME(obj)); + #endif + return -1; + } + +*** ../vim-7.3.1238/src/version.c 2013-06-24 20:32:54.000000000 +0200 +--- src/version.c 2013-06-24 21:19:04.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1239, + /**/ + +-- + GALAHAD hurries to the door and pushes through it. As he leaves the room + we CUT TO the reverse to show that he is now in a room full of bathing + and romping GIRLIES, all innocent, wide-eyed and beautiful. They smile + enchantingly at him as he tries to keep walking without being diverted by + the lovely sights assaulting his eyeballs. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2849452719591acdc1d9c8d11a845d5feea4e696 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:37 +0200 Subject: [PATCH 1133/3340] - patchlevel 1240 --- 7.3.1240 | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 7.3.1240 diff --git a/7.3.1240 b/7.3.1240 new file mode 100644 index 00000000..003aaf7b --- /dev/null +++ b/7.3.1240 @@ -0,0 +1,56 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1240 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1240 +Problem: Memory leak in findfile(). +Solution: Free the memory. (Christian Brabandt) +Files: src/eval.c + + +*** ../vim-7.3.1239/src/eval.c 2013-06-23 14:30:42.000000000 +0200 +--- src/eval.c 2013-06-24 22:12:41.000000000 +0200 +*************** +*** 10448,10454 **** + { + do + { +! if (rettv->v_type == VAR_STRING) + vim_free(fresult); + fresult = find_file_in_path_option(first ? fname : NULL, + first ? (int)STRLEN(fname) : 0, +--- 10448,10454 ---- + { + do + { +! if (rettv->v_type == VAR_STRING || rettv->v_type == VAR_LIST) + vim_free(fresult); + fresult = find_file_in_path_option(first ? fname : NULL, + first ? (int)STRLEN(fname) : 0, +*** ../vim-7.3.1239/src/version.c 2013-06-24 21:21:52.000000000 +0200 +--- src/version.c 2013-06-24 22:09:30.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1240, + /**/ + +-- +DINGO: You must spank her well and after you have spanked her you + may deal with her as you like and then ... spank me. +AMAZING: And spank me! +STUNNER: And me. +LOVELY: And me. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 3df14d798a8d660a8ca9a6ba8343999b63fb9d00 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:38 +0200 Subject: [PATCH 1134/3340] - patchlevel 1241 --- 7.3.1241 | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 7.3.1241 diff --git a/7.3.1241 b/7.3.1241 new file mode 100644 index 00000000..2af539b9 --- /dev/null +++ b/7.3.1241 @@ -0,0 +1,51 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1241 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1241 (after 7.3.1236) +Problem: Some test files missing from the distribution. +Solution: Update the list of files. +Files: Filelist + + +*** ../vim-7.3.1240/Filelist 2013-06-12 14:20:15.000000000 +0200 +--- Filelist 2013-06-24 22:21:10.000000000 +0200 +*************** +*** 87,92 **** +--- 87,96 ---- + src/testdir/python2/*.py \ + src/testdir/python3/*.py \ + src/testdir/pythonx/*.py \ ++ src/testdir/pythonx/topmodule/__init__.py \ ++ src/testdir/pythonx/topmodule/submodule/__init__.py \ ++ src/testdir/pythonx/topmodule/submodule/subsubmodule/__init__.py \ ++ src/testdir/pythonx/topmodule/submodule/subsubmodule/subsubsubmodule.py \ + src/testdir/python_after/*.py \ + src/testdir/python_before/*.py \ + src/proto.h \ +*** ../vim-7.3.1240/src/version.c 2013-06-24 22:17:27.000000000 +0200 +--- src/version.c 2013-06-24 22:23:24.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1241, + /**/ + +-- +DINGO: And after the spanking ... the oral sex. +GALAHAD: Oh, dear! Well, I... +GIRLS: The oral sex ... The oral sex. +GALAHAD: Well, I suppose I could stay a BIT longer. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0b4355219bf825a58255aca868347578e10eb331 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:38 +0200 Subject: [PATCH 1135/3340] - patchlevel 1242 --- 7.3.1242 | 78 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) create mode 100644 7.3.1242 diff --git a/7.3.1242 b/7.3.1242 new file mode 100644 index 00000000..025dfff0 --- /dev/null +++ b/7.3.1242 @@ -0,0 +1,78 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1242 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1242 +Problem: No failure when trying to use a number as a string. +Solution: Give an error when StringToLine() is called with an instance of + the wrong type. (Jun Takimoto) +Files: src/if_py_both.h + + +*** ../vim-7.3.1241/src/if_py_both.h 2013-06-24 21:21:52.000000000 +0200 +--- src/if_py_both.h 2013-06-24 22:30:51.000000000 +0200 +*************** +*** 3549,3561 **** + if (!(bytes = PyUnicode_AsEncodedString(obj, ENC_OPT, NULL))) + return NULL; + +! if(PyBytes_AsStringAndSize(bytes, &str, &len) == -1 + || str == NULL) + { + Py_DECREF(bytes); + return NULL; + } + } + + /* + * Error checking: String must not contain newlines, as we +--- 3549,3574 ---- + if (!(bytes = PyUnicode_AsEncodedString(obj, ENC_OPT, NULL))) + return NULL; + +! if (PyBytes_AsStringAndSize(bytes, &str, &len) == -1 + || str == NULL) + { + Py_DECREF(bytes); + return NULL; + } + } ++ else ++ { ++ #if PY_MAJOR_VERSION < 3 ++ PyErr_FORMAT(PyExc_TypeError, ++ N_("expected str() or unicode() instance, but got %s"), ++ Py_TYPE_NAME(obj)); ++ #else ++ PyErr_FORMAT(PyExc_TypeError, ++ N_("expected bytes() or str() instance, but got %s"), ++ Py_TYPE_NAME(obj)); ++ #endif ++ return NULL; ++ } + + /* + * Error checking: String must not contain newlines, as we +*** ../vim-7.3.1241/src/version.c 2013-06-24 22:23:51.000000000 +0200 +--- src/version.c 2013-06-24 22:32:19.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1242, + /**/ + +-- +A successful man is one who makes more money than his wife can spend. +A successful woman is one who can find such a man. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From bcd0f083d8e21cf5614778f30354b04018c7649a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:39 +0200 Subject: [PATCH 1136/3340] - patchlevel 1243 --- 7.3.1243 | 156 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 156 insertions(+) create mode 100644 7.3.1243 diff --git a/7.3.1243 b/7.3.1243 new file mode 100644 index 00000000..0009e933 --- /dev/null +++ b/7.3.1243 @@ -0,0 +1,156 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1243 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1243 +Problem: New regexp engine: back references in look-behind match don't + work. (Lech Lorens) +Solution: Copy the submatches before a recursive match. Also fix + function prototypes. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1242/src/regexp_nfa.c 2013-06-21 18:31:16.000000000 +0200 +--- src/regexp_nfa.c 2013-06-26 12:32:19.000000000 +0200 +*************** +*** 290,299 **** + #endif + static int *re2post __ARGS((void)); + static nfa_state_T *alloc_state __ARGS((int c, nfa_state_T *out, nfa_state_T *out1)); + static nfa_state_T *post2nfa __ARGS((int *postfix, int *end, int nfa_calc_size)); + static void nfa_postprocess __ARGS((nfa_regprog_T *prog)); + static int check_char_class __ARGS((int class, int c)); +- static void st_error __ARGS((int *postfix, int *end, int *p)); + static void nfa_save_listids __ARGS((nfa_regprog_T *prog, int *list)); + static void nfa_restore_listids __ARGS((nfa_regprog_T *prog, int *list)); + static int nfa_re_num_cmp __ARGS((long_u val, int op, long_u pos)); +--- 290,300 ---- + #endif + static int *re2post __ARGS((void)); + static nfa_state_T *alloc_state __ARGS((int c, nfa_state_T *out, nfa_state_T *out1)); ++ static void st_error __ARGS((int *postfix, int *end, int *p)); ++ static int nfa_max_width __ARGS((nfa_state_T *startstate, int depth)); + static nfa_state_T *post2nfa __ARGS((int *postfix, int *end, int nfa_calc_size)); + static void nfa_postprocess __ARGS((nfa_regprog_T *prog)); + static int check_char_class __ARGS((int class, int c)); + static void nfa_save_listids __ARGS((nfa_regprog_T *prog, int *list)); + static void nfa_restore_listids __ARGS((nfa_regprog_T *prog, int *list)); + static int nfa_re_num_cmp __ARGS((long_u val, int op, long_u pos)); +*************** +*** 3469,3474 **** +--- 3470,3476 ---- + #ifdef ENABLE_LOG + static void log_subsexpr __ARGS((regsubs_T *subs)); + static void log_subexpr __ARGS((regsub_T *sub)); ++ static char *pim_info __ARGS((nfa_pim_T *pim)); + + static void + log_subsexpr(subs) +*************** +*** 3508,3514 **** + } + + static char * +! pim_info(nfa_pim_T *pim) + { + static char buf[30]; + +--- 3510,3517 ---- + } + + static char * +! pim_info(pim) +! nfa_pim_T *pim; + { + static char buf[30]; + +*************** +*** 3532,3537 **** +--- 3535,3541 ---- + static void copy_sub __ARGS((regsub_T *to, regsub_T *from)); + static void copy_sub_off __ARGS((regsub_T *to, regsub_T *from)); + static int sub_equal __ARGS((regsub_T *sub1, regsub_T *sub2)); ++ static int match_backref __ARGS((regsub_T *sub, int subidx, int *bytelen)); + static int has_state_with_pos __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs)); + static int state_in_list __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs)); + static void addstate __ARGS((nfa_list_T *l, nfa_state_T *state, regsubs_T *subs, nfa_pim_T *pim, int off)); +*************** +*** 4319,4326 **** + return FAIL; + } + +- static int match_backref __ARGS((regsub_T *sub, int subidx, int *bytelen)); +- + /* + * Check for a match with subexpression "subidx". + * Return TRUE if it matches. +--- 4323,4328 ---- +*************** +*** 5195,5200 **** +--- 5197,5206 ---- + || t->state->c == NFA_START_INVISIBLE_BEFORE_FIRST + || t->state->c == NFA_START_INVISIBLE_BEFORE_NEG_FIRST) + { ++ /* Copy submatch info for the recursive call, so that ++ * \1 can be matched. */ ++ copy_sub_off(&m->norm, &t->subs.norm); ++ + /* + * First try matching the invisible match, then what + * follows. +*** ../vim-7.3.1242/src/testdir/test64.in 2013-06-17 22:04:34.000000000 +0200 +--- src/testdir/test64.in 2013-06-26 12:31:31.000000000 +0200 +*************** +*** 380,385 **** +--- 380,388 ---- + :call add(tl, [2, '\(a\)\(b\)\(c\)\(dd\)\(e\)\(f\)\(g\)\(h\)\(i\)\1\2\3\4\5\6\7\8\9', 'xabcddefghiabcddefghix', 'abcddefghiabcddefghi', 'a', 'b', 'c', 'dd', 'e', 'f', 'g', 'h', 'i']) + :call add(tl, [2, '\(\d*\)a \1b', ' a b ', 'a b', '']) + :call add(tl, [2, '^.\(.\).\_..\1.', "aaa\naaa\nb", "aaa\naaa", 'a']) ++ :call add(tl, [2, '^.*\.\(.*\)/.\+\(\1\)\@ Date: Thu, 4 Jul 2013 15:36:40 +0200 Subject: [PATCH 1137/3340] - patchlevel 1244 --- 7.3.1244 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 7.3.1244 diff --git a/7.3.1244 b/7.3.1244 new file mode 100644 index 00000000..00cf1a93 --- /dev/null +++ b/7.3.1244 @@ -0,0 +1,54 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1244 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1244 +Problem: MS-Windows: confirm() dialog text may not fit. +Solution: Use GetTextWidthEnc() instead of GetTextWidth(). (Yasuhiro + Matsumoto) +Files: src/gui_w32.c + + +*** ../vim-7.3.1243/src/gui_w32.c 2013-05-06 04:21:35.000000000 +0200 +--- src/gui_w32.c 2013-06-26 12:55:32.000000000 +0200 +*************** +*** 3216,3222 **** + if (l == 1 && vim_iswhite(*pend) + && textWidth > maxDialogWidth * 3 / 4) + last_white = pend; +! textWidth += GetTextWidth(hdc, pend, l); + if (textWidth >= maxDialogWidth) + { + /* Line will wrap. */ +--- 3216,3222 ---- + if (l == 1 && vim_iswhite(*pend) + && textWidth > maxDialogWidth * 3 / 4) + last_white = pend; +! textWidth += GetTextWidthEnc(hdc, pend, l); + if (textWidth >= maxDialogWidth) + { + /* Line will wrap. */ +*** ../vim-7.3.1243/src/version.c 2013-06-26 12:42:38.000000000 +0200 +--- src/version.c 2013-06-26 12:56:47.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1244, + /**/ + +-- +The psychic said, "God bless you." I said, "I didn't sneeze." She +looked deep into my eyes and said, "You will, eventually." And, damn +if she wasn't right. Two days later, I sneezed. --Ellen Degeneres + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 578049dfcab12705d3779c9465627412c22aa4ab Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:41 +0200 Subject: [PATCH 1138/3340] - patchlevel 1245 --- 7.3.1245 | 70 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 7.3.1245 diff --git a/7.3.1245 b/7.3.1245 new file mode 100644 index 00000000..ceef5343 --- /dev/null +++ b/7.3.1245 @@ -0,0 +1,70 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1245 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1245 +Problem: MS-Windows: confirm() dialog text may still not fit. +Solution: Use GetTextWidthEnc() instead of GetTextWidth() in two more + places. (Yasuhiro Matsumoto) +Files: src/gui_w32.c + + +*** ../vim-7.3.1244/src/gui_w32.c 2013-06-26 12:58:28.000000000 +0200 +--- src/gui_w32.c 2013-06-26 13:13:43.000000000 +0200 +*************** +*** 3282,3288 **** + pend = vim_strchr(pstart, DLG_BUTTON_SEP); + if (pend == NULL) + pend = pstart + STRLEN(pstart); // Last button name. +! textWidth = GetTextWidth(hdc, pstart, (int)(pend - pstart)); + if (textWidth < minButtonWidth) + textWidth = minButtonWidth; + textWidth += dlgPaddingX; /* Padding within button */ +--- 3282,3288 ---- + pend = vim_strchr(pstart, DLG_BUTTON_SEP); + if (pend == NULL) + pend = pstart + STRLEN(pstart); // Last button name. +! textWidth = GetTextWidthEnc(hdc, pstart, (int)(pend - pstart)); + if (textWidth < minButtonWidth) + textWidth = minButtonWidth; + textWidth += dlgPaddingX; /* Padding within button */ +*************** +*** 3307,3313 **** + pend = vim_strchr(pstart, DLG_BUTTON_SEP); + if (pend == NULL) + pend = pstart + STRLEN(pstart); // Last button name. +! textWidth = GetTextWidth(hdc, pstart, (int)(pend - pstart)); + textWidth += dlgPaddingX; /* Padding within button */ + textWidth += DLG_VERT_PADDING_X * 2; /* Padding around button */ + if (textWidth > dlgwidth) +--- 3307,3313 ---- + pend = vim_strchr(pstart, DLG_BUTTON_SEP); + if (pend == NULL) + pend = pstart + STRLEN(pstart); // Last button name. +! textWidth = GetTextWidthEnc(hdc, pstart, (int)(pend - pstart)); + textWidth += dlgPaddingX; /* Padding within button */ + textWidth += DLG_VERT_PADDING_X * 2; /* Padding around button */ + if (textWidth > dlgwidth) +*** ../vim-7.3.1244/src/version.c 2013-06-26 12:58:28.000000000 +0200 +--- src/version.c 2013-06-26 13:14:19.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1245, + /**/ + +-- +TALL KNIGHT OF NI: Ni! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 97b84af85bd8c493e52da331f4e0f91bea532f20 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:42 +0200 Subject: [PATCH 1139/3340] - patchlevel 1246 --- 7.3.1246 | 135 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 135 insertions(+) create mode 100644 7.3.1246 diff --git a/7.3.1246 b/7.3.1246 new file mode 100644 index 00000000..22f426bc --- /dev/null +++ b/7.3.1246 @@ -0,0 +1,135 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1246 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1246 +Problem: When setting 'winfixheight' and resizing the window causes the + window layout to be wrong. +Solution: Add frame_check_height() and frame_check_width() (Yukihiro + Nakadaira) +Files: src/window.c + + +*** ../vim-7.3.1245/src/window.c 2013-06-16 17:32:33.000000000 +0200 +--- src/window.c 2013-06-26 13:51:25.000000000 +0200 +*************** +*** 66,71 **** +--- 66,76 ---- + static int check_snapshot_rec __ARGS((frame_T *sn, frame_T *fr)); + static win_T *restore_snapshot_rec __ARGS((frame_T *sn, frame_T *fr)); + ++ static int frame_check_height __ARGS((frame_T *topfrp, int height)); ++ #ifdef FEAT_VERTSPLIT ++ static int frame_check_width __ARGS((frame_T *topfrp, int width)); ++ #endif ++ + #endif /* FEAT_WINDOWS */ + + static win_T *win_alloc __ARGS((win_T *after, int hidden)); +*************** +*** 4749,4755 **** + /* First try setting the heights of windows with 'winfixheight'. If + * that doesn't result in the right height, forget about that option. */ + frame_new_height(topframe, h, FALSE, TRUE); +! if (topframe->fr_height != h) + frame_new_height(topframe, h, FALSE, FALSE); + + (void)win_comp_pos(); /* recompute w_winrow and w_wincol */ +--- 4754,4760 ---- + /* First try setting the heights of windows with 'winfixheight'. If + * that doesn't result in the right height, forget about that option. */ + frame_new_height(topframe, h, FALSE, TRUE); +! if (!frame_check_height(topframe, h)) + frame_new_height(topframe, h, FALSE, FALSE); + + (void)win_comp_pos(); /* recompute w_winrow and w_wincol */ +*************** +*** 4783,4789 **** + /* First try setting the widths of windows with 'winfixwidth'. If that + * doesn't result in the right width, forget about that option. */ + frame_new_width(topframe, (int)Columns, FALSE, TRUE); +! if (topframe->fr_width != Columns) + frame_new_width(topframe, (int)Columns, FALSE, FALSE); + + (void)win_comp_pos(); /* recompute w_winrow and w_wincol */ +--- 4788,4794 ---- + /* First try setting the widths of windows with 'winfixwidth'. If that + * doesn't result in the right width, forget about that option. */ + frame_new_width(topframe, (int)Columns, FALSE, TRUE); +! if (!frame_check_width(topframe, Columns)) + frame_new_width(topframe, (int)Columns, FALSE, FALSE); + + (void)win_comp_pos(); /* recompute w_winrow and w_wincol */ +*************** +*** 6922,6924 **** +--- 6927,6974 ---- + return i; + } + #endif ++ ++ /* ++ * Return TRUE if "topfrp" and its children are at the right height. ++ */ ++ static int ++ frame_check_height(topfrp, height) ++ frame_T *topfrp; ++ int height; ++ { ++ frame_T *frp; ++ ++ if (topfrp->fr_height != height) ++ return FALSE; ++ ++ if (topfrp->fr_layout == FR_ROW) ++ for (frp = topfrp->fr_child; frp != NULL; frp = frp->fr_next) ++ if (frp->fr_height != height) ++ return FALSE; ++ ++ return TRUE; ++ } ++ ++ #ifdef FEAT_VERTSPLIT ++ /* ++ * Return TRUE if "topfrp" and its children are at the right width. ++ */ ++ static int ++ frame_check_width(topfrp, width) ++ frame_T *topfrp; ++ int width; ++ { ++ frame_T *frp; ++ ++ if (topfrp->fr_width != width) ++ return FALSE; ++ ++ if (topfrp->fr_layout == FR_COL) ++ for (frp = topfrp->fr_child; frp != NULL; frp = frp->fr_next) ++ if (frp->fr_width != width) ++ return FALSE; ++ ++ return TRUE; ++ } ++ #endif ++ +*** ../vim-7.3.1245/src/version.c 2013-06-26 13:16:13.000000000 +0200 +--- src/version.c 2013-06-26 13:47:56.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1246, + /**/ + +-- +Back up my hard drive? I can't find the reverse switch! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From d68559b97024a8c232a3514823129bd0a4e13d99 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:43 +0200 Subject: [PATCH 1140/3340] - patchlevel 1247 --- 7.3.1247 | 135 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 135 insertions(+) create mode 100644 7.3.1247 diff --git a/7.3.1247 b/7.3.1247 new file mode 100644 index 00000000..83499c7a --- /dev/null +++ b/7.3.1247 @@ -0,0 +1,135 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1247 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1247 +Problem: New regexp engine: '[ ]\@!\p\%([ ]\@!\p\)*:' does not always match. +Solution: When there is a PIM add a duplicate state that starts at another + position. +Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1246/src/regexp_nfa.c 2013-06-26 12:42:38.000000000 +0200 +--- src/regexp_nfa.c 2013-06-26 17:54:31.000000000 +0200 +*************** +*** 3642,3655 **** + if (i < sub1->in_use) + s1 = sub1->list.multi[i].start.lnum; + else +! s1 = 0; + if (i < sub2->in_use) + s2 = sub2->list.multi[i].start.lnum; + else +! s2 = 0; + if (s1 != s2) + return FALSE; +! if (s1 != 0 && sub1->list.multi[i].start.col + != sub2->list.multi[i].start.col) + return FALSE; + } +--- 3642,3655 ---- + if (i < sub1->in_use) + s1 = sub1->list.multi[i].start.lnum; + else +! s1 = -1; + if (i < sub2->in_use) + s2 = sub2->list.multi[i].start.lnum; + else +! s2 = -1; + if (s1 != s2) + return FALSE; +! if (s1 != -1 && sub1->list.multi[i].start.col + != sub2->list.multi[i].start.col) + return FALSE; + } +*************** +*** 3931,3938 **** + if (state->lastlist[nfa_ll_index] == l->id) + { + /* This state is already in the list, don't add it again, +! * unless it is an MOPEN that is used for a backreference. */ +! if (!nfa_has_backref) + { + skip_add: + #ifdef ENABLE_LOG +--- 3931,3939 ---- + if (state->lastlist[nfa_ll_index] == l->id) + { + /* This state is already in the list, don't add it again, +! * unless it is an MOPEN that is used for a backreference or +! * when there is a PIM. */ +! if (!nfa_has_backref && pim == NULL) + { + skip_add: + #ifdef ENABLE_LOG +*************** +*** 3949,3957 **** + goto skip_add; + } + +! /* When there are backreferences the number of states may be (a +! * lot) bigger than anticipated. */ +! if (nfa_has_backref && l->n == l->len) + { + int newlen = l->len * 3 / 2 + 50; + +--- 3950,3958 ---- + goto skip_add; + } + +! /* When there are backreferences or PIMs the number of states may +! * be (a lot) bigger than anticipated. */ +! if (l->n == l->len) + { + int newlen = l->len * 3 / 2 + 50; + +*** ../vim-7.3.1246/src/testdir/test64.in 2013-06-26 12:42:38.000000000 +0200 +--- src/testdir/test64.in 2013-06-26 16:43:19.000000000 +0200 +*************** +*** 338,343 **** +--- 338,344 ---- + :call add(tl, [2, '^\%(.*bar\)\@!.*\zsfoo', ' bar foo ']) + :call add(tl, [2, '^\%(.*bar\)\@!.*\zsfoo', ' foo bar ']) + :call add(tl, [2, '^\%(.*bar\)\@!.*\zsfoo', ' foo xxx ', 'foo']) ++ :call add(tl, [2, '[ ]\@!\p\%([ ]\@!\p\)*:', 'implicit mappings:', 'mappings:']) + :" + :"""" Combining different tests and features + :call add(tl, [2, '[[:alpha:]]\{-2,6}', '787abcdiuhsasiuhb4', 'ab']) +*** ../vim-7.3.1246/src/testdir/test64.ok 2013-06-26 12:42:38.000000000 +0200 +--- src/testdir/test64.ok 2013-06-26 17:33:11.000000000 +0200 +*************** +*** 770,775 **** +--- 770,778 ---- + OK 0 - ^\%(.*bar\)\@!.*\zsfoo + OK 1 - ^\%(.*bar\)\@!.*\zsfoo + OK 2 - ^\%(.*bar\)\@!.*\zsfoo ++ OK 0 - [ ]\@!\p\%([ ]\@!\p\)*: ++ OK 1 - [ ]\@!\p\%([ ]\@!\p\)*: ++ OK 2 - [ ]\@!\p\%([ ]\@!\p\)*: + OK 0 - [[:alpha:]]\{-2,6} + OK 1 - [[:alpha:]]\{-2,6} + OK 2 - [[:alpha:]]\{-2,6} +*** ../vim-7.3.1246/src/version.c 2013-06-26 14:04:37.000000000 +0200 +--- src/version.c 2013-06-26 17:30:26.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1247, + /**/ + +-- +FATHER: One day, lad, all this will be yours ... +PRINCE: What - the curtains? + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 91e38da86f11c84269cbb875d0489221c773a7be Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:44 +0200 Subject: [PATCH 1141/3340] - patchlevel 1248 --- 7.3.1248 | 286 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 286 insertions(+) create mode 100644 7.3.1248 diff --git a/7.3.1248 b/7.3.1248 new file mode 100644 index 00000000..dbfeff2a --- /dev/null +++ b/7.3.1248 @@ -0,0 +1,286 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1248 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1248 +Problem: Still have old hacking code for Input Method. +Solution: Add 'imactivatefunc' and 'imstatusfunc' as a generic solution to + Input Method activation. (Yukihiro Nakadaira) +Files: runtime/doc/options.txt, src/fileio.c, src/mbyte.c, src/option.c, + src/option.h, src/proto/fileio.pro + + +*** ../vim-7.3.1247/runtime/doc/options.txt 2013-06-04 22:13:45.000000000 +0200 +--- runtime/doc/options.txt 2013-06-26 19:00:28.000000000 +0200 +*************** +*** 3937,3942 **** +--- 3993,4018 ---- + Can be overruled by using "\c" or "\C" in the pattern, see + |/ignorecase|. + ++ *'imactivatefunc'* *'imaf'* ++ 'imactivatefunc' 'imaf' string (default "") ++ global ++ {not in Vi} ++ {only available when compiled with |+xim| and ++ |+GUI_GTK|} ++ This option specifies a function that will be called to ++ activate/inactivate Input Method. ++ ++ Example: > ++ function ImActivateFunc(active) ++ if a:active ++ ... do something ++ else ++ ... do something ++ endif ++ " return value is not used ++ endfunction ++ set imactivatefunc=ImActivateFunc ++ < + *'imactivatekey'* *'imak'* + 'imactivatekey' 'imak' string (default "") + global +*************** +*** 4033,4038 **** +--- 4109,4132 ---- + The value 0 may not work correctly with Athena and Motif with some XIM + methods. Use 'imdisable' to disable XIM then. + ++ *'imstatusfunc'* *'imsf'* ++ 'imstatusfunc' 'imsf' string (default "") ++ global ++ {not in Vi} ++ {only available when compiled with |+xim| and ++ |+GUI_GTK|} ++ This option specifies a function that is called to obtain the status ++ of Input Method. It must return a positive number when IME is active. ++ ++ Example: > ++ function ImStatusFunc() ++ let is_active = ...do something ++ return is_active ? 1 : 0 ++ endfunction ++ set imstatusfunc=ImStatusFunc ++ < ++ NOTE: This function is invoked very often. Keep it fast. ++ + *'include'* *'inc'* + 'include' 'inc' string (default "^\s*#\s*include") + global or local to buffer |global-local| +*** ../vim-7.3.1247/src/fileio.c 2013-06-12 22:41:30.000000000 +0200 +--- src/fileio.c 2013-06-26 18:41:39.000000000 +0200 +*************** +*** 9572,9577 **** +--- 9572,9583 ---- + # endif + } + ++ int ++ is_autocmd_blocked() ++ { ++ return autocmd_blocked != 0; ++ } ++ + /* + * Find next autocommand pattern that matches. + */ +*** ../vim-7.3.1247/src/mbyte.c 2013-05-06 04:21:35.000000000 +0200 +--- src/mbyte.c 2013-06-26 19:10:41.000000000 +0200 +*************** +*** 4447,4453 **** + { + int was_active; + +! was_active = !!im_is_active; + im_is_active = (active && !p_imdisable); + + if (im_is_active != was_active) +--- 4447,4453 ---- + { + int was_active; + +! was_active = !!im_get_status(); + im_is_active = (active && !p_imdisable); + + if (im_is_active != was_active) +*************** +*** 5071,5114 **** + { + if (xic != NULL) + { +- /* +- * The third-party imhangul module (and maybe others too) ignores +- * gtk_im_context_reset() or at least doesn't reset the active state. +- * Thus sending imactivatekey would turn it off if it was on before, +- * which is clearly not what we want. Fortunately we can work around +- * that for imhangul by sending GDK_Escape, but I don't know if it +- * works with all IM modules that support an activation key :/ +- * +- * An alternative approach would be to destroy the IM context and +- * recreate it. But that means loading/unloading the IM module on +- * every mode switch, which causes a quite noticeable delay even on +- * my rather fast box... +- * * +- * Moreover, there are some XIM which cannot respond to +- * im_synthesize_keypress(). we hope that they reset by +- * xim_shutdown(). +- */ +- if (im_activatekey_keyval != GDK_VoidSymbol && im_is_active) +- im_synthesize_keypress(GDK_Escape, 0U); +- + gtk_im_context_reset(xic); + +- /* +- * HACK for Ami: This sequence of function calls makes Ami handle +- * the IM reset graciously, without breaking loads of other stuff. +- * It seems to force English mode as well, which is exactly what we +- * want because it makes the Ami status display work reliably. +- */ +- gtk_im_context_set_use_preedit(xic, FALSE); +- + if (p_imdisable) + im_shutdown(); + else + { +- gtk_im_context_set_use_preedit(xic, TRUE); + xim_set_focus(gui.in_focus); + +! if (im_activatekey_keyval != GDK_VoidSymbol) + { + if (im_is_active) + { +--- 5071,5095 ---- + { + if (xic != NULL) + { + gtk_im_context_reset(xic); + + if (p_imdisable) + im_shutdown(); + else + { + xim_set_focus(gui.in_focus); + +! if (p_imaf[0] != NUL) +! { +! char_u *argv[1]; +! +! if (im_is_active) +! argv[0] = (char_u *)"1"; +! else +! argv[0] = (char_u *)"0"; +! (void)call_func_retnr(p_imaf, 1, argv, FALSE); +! } +! else if (im_activatekey_keyval != GDK_VoidSymbol) + { + if (im_is_active) + { +*************** +*** 5268,5273 **** +--- 5249,5268 ---- + int + im_get_status(void) + { ++ if (p_imsf[0] != NUL) ++ { ++ int is_active; ++ ++ /* FIXME: Don't execute user function in unsafe situation. */ ++ if (exiting || is_autocmd_blocked()) ++ return FALSE; ++ /* FIXME: :py print 'xxx' is shown duplicate result. ++ * Use silent to avoid it. */ ++ ++msg_silent; ++ is_active = call_func_retnr(p_imsf, 0, NULL, FALSE); ++ --msg_silent; ++ return (is_active > 0); ++ } + return im_is_active; + } + +*** ../vim-7.3.1247/src/option.c 2013-06-16 16:01:20.000000000 +0200 +--- src/option.c 2013-06-26 18:41:39.000000000 +0200 +*************** +*** 1425,1430 **** +--- 1425,1439 ---- + {"ignorecase", "ic", P_BOOL|P_VI_DEF, + (char_u *)&p_ic, PV_NONE, + {(char_u *)FALSE, (char_u *)0L} SCRIPTID_INIT}, ++ {"imactivatefunc","imaf",P_STRING|P_VI_DEF|P_SECURE, ++ # if defined(FEAT_EVAL) && defined(FEAT_XIM) && defined(FEAT_GUI_GTK) ++ (char_u *)&p_imaf, PV_NONE, ++ {(char_u *)"", (char_u *)NULL} ++ # else ++ (char_u *)NULL, PV_NONE, ++ {(char_u *)NULL, (char_u *)0L} ++ # endif ++ SCRIPTID_INIT}, + {"imactivatekey","imak",P_STRING|P_VI_DEF, + #if defined(FEAT_XIM) && defined(FEAT_GUI_GTK) + (char_u *)&p_imak, PV_NONE, +*************** +*** 1467,1472 **** +--- 1476,1490 ---- + {(char_u *)B_IMODE_NONE, (char_u *)0L} + #endif + SCRIPTID_INIT}, ++ {"imstatusfunc","imse",P_STRING|P_VI_DEF|P_SECURE, ++ # if defined(FEAT_EVAL) && defined(FEAT_XIM) && defined(FEAT_GUI_GTK) ++ (char_u *)&p_imsf, PV_NONE, ++ {(char_u *)"", (char_u *)NULL} ++ # else ++ (char_u *)NULL, PV_NONE, ++ {(char_u *)NULL, (char_u *)0L} ++ # endif ++ SCRIPTID_INIT}, + {"include", "inc", P_STRING|P_ALLOCED|P_VI_DEF, + #ifdef FEAT_FIND_ID + (char_u *)&p_inc, PV_INC, +*** ../vim-7.3.1247/src/option.h 2013-05-19 19:16:25.000000000 +0200 +--- src/option.h 2013-06-26 18:41:39.000000000 +0200 +*************** +*** 558,563 **** +--- 558,565 ---- + EXTERN int p_ic; /* 'ignorecase' */ + #if defined(FEAT_XIM) && defined(FEAT_GUI_GTK) + EXTERN char_u *p_imak; /* 'imactivatekey' */ ++ EXTERN char_u *p_imaf; /* 'imactivatefunc' */ ++ EXTERN char_u *p_imsf; /* 'imstatusfunc' */ + #endif + #ifdef USE_IM_CONTROL + EXTERN int p_imcmdline; /* 'imcmdline' */ +*** ../vim-7.3.1247/src/proto/fileio.pro 2013-03-19 13:33:18.000000000 +0100 +--- src/proto/fileio.pro 2013-06-26 18:45:49.000000000 +0200 +*************** +*** 49,54 **** +--- 49,55 ---- + int has_insertcharpre __ARGS((void)); + void block_autocmds __ARGS((void)); + void unblock_autocmds __ARGS((void)); ++ int is_autocmd_blocked __ARGS((void)); + char_u *getnextac __ARGS((int c, void *cookie, int indent)); + int has_autocmd __ARGS((event_T event, char_u *sfname, buf_T *buf)); + char_u *get_augroup_name __ARGS((expand_T *xp, int idx)); +*** ../vim-7.3.1247/src/version.c 2013-06-26 18:16:55.000000000 +0200 +--- src/version.c 2013-06-26 19:12:37.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1248, + /**/ + +-- +I'd like to meet the man who invented sex and see what he's working on now. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 393d41899c60e6912e731c00b28cb262ade56741 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:45 +0200 Subject: [PATCH 1142/3340] - patchlevel 1249 --- 7.3.1249 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 7.3.1249 diff --git a/7.3.1249 b/7.3.1249 new file mode 100644 index 00000000..8fcd38f6 --- /dev/null +++ b/7.3.1249 @@ -0,0 +1,54 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1249 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1249 +Problem: Modeline not recognized when using "Vim" instead of "vim". +Solution: Also accept "Vim". +Files: src/buffer.c + + +*** ../vim-7.3.1248/src/buffer.c 2013-06-16 17:32:33.000000000 +0200 +--- src/buffer.c 2013-06-26 19:52:58.000000000 +0200 +*************** +*** 5096,5102 **** + if ((prev != -1 && STRNCMP(s, "ex:", (size_t)3) == 0) + || STRNCMP(s, "vi:", (size_t)3) == 0) + break; +! if (STRNCMP(s, "vim", 3) == 0) + { + if (s[3] == '<' || s[3] == '=' || s[3] == '>') + e = s + 4; +--- 5096,5103 ---- + if ((prev != -1 && STRNCMP(s, "ex:", (size_t)3) == 0) + || STRNCMP(s, "vi:", (size_t)3) == 0) + break; +! /* Accept both "vim" and "Vim". */ +! if ((s[0] == 'v' || s[0] == 'V') && s[1] == 'i' && s[2] == 'm') + { + if (s[3] == '<' || s[3] == '=' || s[3] == '>') + e = s + 4; +*** ../vim-7.3.1248/src/version.c 2013-06-26 19:17:58.000000000 +0200 +--- src/version.c 2013-06-26 19:53:37.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1249, + /**/ + +-- +CONCORDE: Message for you, sir. + He falls forward revealing the arrow with the note. + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 0734a76fdad476ccfa9568eb8a7f439817ade231 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:46 +0200 Subject: [PATCH 1143/3340] - patchlevel 1250 --- 7.3.1250 | 106 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 106 insertions(+) create mode 100644 7.3.1250 diff --git a/7.3.1250 b/7.3.1250 new file mode 100644 index 00000000..1aa1500e --- /dev/null +++ b/7.3.1250 @@ -0,0 +1,106 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1250 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1250 +Problem: Python tests fail on MS-Windows. +Solution: Change backslashes to slashes. (Taro Muraoka) +Files: src/testdir/test86.in, src/testdir/test87.in + + +*** ../vim-7.3.1249/src/testdir/test86.in 2013-06-23 16:35:32.000000000 +0200 +--- src/testdir/test86.in 2013-06-26 21:43:04.000000000 +0200 +*************** +*** 1221,1232 **** + vim.options['rtp'] = os.getcwd().replace(',', '\\,').replace('\\', '\\\\') + l = [] + def callback(path): +! l.append(path[-len('/testdir'):]) + vim.foreach_rtp(callback) + cb.append(repr(l)) + del l + def callback(path): +! return path[-len('/testdir'):] + cb.append(repr(vim.foreach_rtp(callback))) + del callback + from module import dir as d +--- 1221,1232 ---- + vim.options['rtp'] = os.getcwd().replace(',', '\\,').replace('\\', '\\\\') + l = [] + def callback(path): +! l.append(path[-len('/testdir'):].replace(os.path.sep, '/')) + vim.foreach_rtp(callback) + cb.append(repr(l)) + del l + def callback(path): +! return path[-len('/testdir'):].replace(os.path.sep, '/') + cb.append(repr(vim.foreach_rtp(callback))) + del callback + from module import dir as d +*************** +*** 1239,1247 **** + import topmodule as tm + import topmodule.submodule as tms + import topmodule.submodule.subsubmodule.subsubsubmodule as tmsss +! cb.append(tm.__file__.replace('.pyc', '.py')[-len('modulex/topmodule/__init__.py'):]) +! cb.append(tms.__file__.replace('.pyc', '.py')[-len('modulex/topmodule/submodule/__init__.py'):]) +! cb.append(tmsss.__file__.replace('.pyc', '.py')[-len('modulex/topmodule/submodule/subsubmodule/subsubsubmodule.py'):]) + del before + del after + del d +--- 1239,1247 ---- + import topmodule as tm + import topmodule.submodule as tms + import topmodule.submodule.subsubmodule.subsubsubmodule as tmsss +! cb.append(tm.__file__.replace('.pyc', '.py').replace(os.path.sep, '/')[-len('modulex/topmodule/__init__.py'):]) +! cb.append(tms.__file__.replace('.pyc', '.py').replace(os.path.sep, '/')[-len('modulex/topmodule/submodule/__init__.py'):]) +! cb.append(tmsss.__file__.replace('.pyc', '.py').replace(os.path.sep, '/')[-len('modulex/topmodule/submodule/subsubmodule/subsubsubmodule.py'):]) + del before + del after + del d +*** ../vim-7.3.1249/src/testdir/test87.in 2013-06-23 16:35:32.000000000 +0200 +--- src/testdir/test87.in 2013-06-26 21:44:25.000000000 +0200 +*************** +*** 1188,1196 **** + import topmodule as tm + import topmodule.submodule as tms + import topmodule.submodule.subsubmodule.subsubsubmodule as tmsss +! cb.append(tm.__file__[-len('modulex/topmodule/__init__.py'):]) +! cb.append(tms.__file__[-len('modulex/topmodule/submodule/__init__.py'):]) +! cb.append(tmsss.__file__[-len('modulex/topmodule/submodule/subsubmodule/subsubsubmodule.py'):]) + del before + del after + del d +--- 1188,1196 ---- + import topmodule as tm + import topmodule.submodule as tms + import topmodule.submodule.subsubmodule.subsubsubmodule as tmsss +! cb.append(tm.__file__.replace(os.path.sep, '/')[-len('modulex/topmodule/__init__.py'):]) +! cb.append(tms.__file__.replace(os.path.sep, '/')[-len('modulex/topmodule/submodule/__init__.py'):]) +! cb.append(tmsss.__file__.replace(os.path.sep, '/')[-len('modulex/topmodule/submodule/subsubmodule/subsubsubmodule.py'):]) + del before + del after + del d +*** ../vim-7.3.1249/src/version.c 2013-06-26 20:04:28.000000000 +0200 +--- src/version.c 2013-06-26 21:44:00.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1250, + /**/ + +-- +You were lucky to have a LAKE! There were a hundred and sixty of +us living in a small shoebox in the middle of the road. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 11b6e4c53b448d3e145b4df29c102f31a7b5dc27 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:47 +0200 Subject: [PATCH 1144/3340] - patchlevel 1251 --- 7.3.1251 | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 7.3.1251 diff --git a/7.3.1251 b/7.3.1251 new file mode 100644 index 00000000..b3f37cb1 --- /dev/null +++ b/7.3.1251 @@ -0,0 +1,52 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1251 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1251 +Problem: Test 61 messes up viminfo. +Solution: Specify a separate viminfo file. +Files: src/testdir/test61.in + + +*** ../vim-7.3.1250/src/testdir/test61.in 2013-06-15 17:54:36.000000000 +0200 +--- src/testdir/test61.in 2013-06-26 21:54:00.000000000 +0200 +*************** +*** 85,91 **** + ggO---:0put a + ggO---:w >>test.out + :so small.vim +! :set nocp + :enew! + oa + :set ul=100 +--- 85,91 ---- + ggO---:0put a + ggO---:w >>test.out + :so small.vim +! :set nocp viminfo+=nviminfo + :enew! + oa + :set ul=100 +*** ../vim-7.3.1250/src/version.c 2013-06-26 21:49:46.000000000 +0200 +--- src/version.c 2013-06-26 21:54:43.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1251, + /**/ + +-- +Yah, well, we had to carve our electrons out of driftwood we'd +find. In the winter. Uphill. Both ways. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 16888110eaa4bf2ae920c32730842b51a07afdd5 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:47 +0200 Subject: [PATCH 1145/3340] - patchlevel 1252 --- 7.3.1252 | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 7.3.1252 diff --git a/7.3.1252 b/7.3.1252 new file mode 100644 index 00000000..7de9eefd --- /dev/null +++ b/7.3.1252 @@ -0,0 +1,55 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1252 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1252 +Problem: Gvim does not find the toolbar bitmap files in ~/vimfiles/bitmaps + if the corresponding menu command contains additional characters + like the shortcut marker '&' or if you use a non-english locale. +Solution: Use menu->en_dname or menu->dname. (Martin Gieseking) +Files: src/gui_w32.c + + +*** ../vim-7.3.1251/src/gui_w32.c 2013-06-26 13:16:13.000000000 +0200 +--- src/gui_w32.c 2013-06-27 22:01:03.000000000 +0200 +*************** +*** 4163,4169 **** + * didn't exist or wasn't specified, try the menu name + */ + if (hbitmap == NULL +! && (gui_find_bitmap(menu->name, fname, "bmp") == OK)) + hbitmap = LoadImage( + NULL, + fname, +--- 4163,4171 ---- + * didn't exist or wasn't specified, try the menu name + */ + if (hbitmap == NULL +! && (gui_find_bitmap(menu->en_dname != NULL +! ? menu->en_dname +! : menu->dname, fname, "bmp") == OK)) + hbitmap = LoadImage( + NULL, + fname, +*** ../vim-7.3.1251/src/version.c 2013-06-26 21:56:33.000000000 +0200 +--- src/version.c 2013-06-27 20:33:18.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1252, + /**/ + +-- +Why doesn't Tarzan have a beard? + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 39750733f934ba6a0bc4acdea73286ef6d697918 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:48 +0200 Subject: [PATCH 1146/3340] - patchlevel 1253 --- 7.3.1253 | 74 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 7.3.1253 diff --git a/7.3.1253 b/7.3.1253 new file mode 100644 index 00000000..f7dbf8db --- /dev/null +++ b/7.3.1253 @@ -0,0 +1,74 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1253 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1253 (after 7.3.1200) +Problem: Still undo problem after using CTRL-R = setline(). (Hirohito + Higashi) +Solution: Set the ins_need_undo flag. +Files: src/edit.c + + +*** ../vim-7.3.1252/src/edit.c 2013-06-15 17:54:36.000000000 +0200 +--- src/edit.c 2013-06-27 22:21:08.000000000 +0200 +*************** +*** 8134,8148 **** + # ifdef USE_IM_CONTROL + int im_on = im_get_status(); + # endif + regname = get_expr_register(); + # ifdef USE_IM_CONTROL + /* Restore the Input Method. */ + if (im_on) + im_set_active(TRUE); + # endif +! if (regname == '=') +! /* sync undo, so the effect of e.g., setline() can be undone */ +! u_sync(TRUE); + } + if (regname == NUL || !valid_yank_reg(regname, FALSE)) + { +--- 8134,8150 ---- + # ifdef USE_IM_CONTROL + int im_on = im_get_status(); + # endif ++ /* Sync undo, so the effect of e.g., setline() can be undone. */ ++ u_sync(TRUE); ++ ins_need_undo = TRUE; ++ + regname = get_expr_register(); + # ifdef USE_IM_CONTROL + /* Restore the Input Method. */ + if (im_on) + im_set_active(TRUE); + # endif +! Insstart = curwin->w_cursor; + } + if (regname == NUL || !valid_yank_reg(regname, FALSE)) + { +*** ../vim-7.3.1252/src/version.c 2013-06-27 22:01:56.000000000 +0200 +--- src/version.c 2013-06-27 22:13:02.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1253, + /**/ + +-- + LAUNCELOT leaps into SHOT with a mighty cry and runs the GUARD through and + hacks him to the floor. Blood. Swashbuckling music (perhaps). + LAUNCELOT races through into the castle screaming. +SECOND SENTRY: Hey! + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 28c3372dc91880aaebefdad60ce457533a4de03a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:49 +0200 Subject: [PATCH 1147/3340] - patchlevel 1254 --- 7.3.1254 | 59 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 7.3.1254 diff --git a/7.3.1254 b/7.3.1254 new file mode 100644 index 00000000..bcb30052 --- /dev/null +++ b/7.3.1254 @@ -0,0 +1,59 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1254 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1254 (after 7.3.1252) +Problem: Can't build without the multi-lang feature. (John Marriott) +Solution: Add #ifdef. +Files: src/gui_w32.c + + +*** ../vim-7.3.1253/src/gui_w32.c 2013-06-27 22:01:56.000000000 +0200 +--- src/gui_w32.c 2013-06-27 22:26:31.000000000 +0200 +*************** +*** 4163,4171 **** + * didn't exist or wasn't specified, try the menu name + */ + if (hbitmap == NULL +! && (gui_find_bitmap(menu->en_dname != NULL +! ? menu->en_dname +! : menu->dname, fname, "bmp") == OK)) + hbitmap = LoadImage( + NULL, + fname, +--- 4163,4173 ---- + * didn't exist or wasn't specified, try the menu name + */ + if (hbitmap == NULL +! && (gui_find_bitmap( +! #ifdef FEAT_MULTI_LANG +! menu->en_dname != NULL ? menu->en_dname : +! #endif +! menu->dname, fname, "bmp") == OK)) + hbitmap = LoadImage( + NULL, + fname, +*** ../vim-7.3.1253/src/version.c 2013-06-27 22:21:19.000000000 +0200 +--- src/version.c 2013-06-27 22:27:16.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1254, + /**/ + +-- +PRINCE: He's come to rescue me, father. +LAUNCELOT: (embarrassed) Well, let's not jump to conclusions ... + "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From b999bb711a5ddfa273871bd22ae0f023282ac7d7 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:50 +0200 Subject: [PATCH 1148/3340] - patchlevel 1255 --- 7.3.1255 | 69 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 7.3.1255 diff --git a/7.3.1255 b/7.3.1255 new file mode 100644 index 00000000..728bb45f --- /dev/null +++ b/7.3.1255 @@ -0,0 +1,69 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1255 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1255 +Problem: Clang warnings when building with Athena. +Solution: Add type casts. (Dominique Pelle) +Files: src/gui_at_fs.c + + +*** ../vim-7.3.1254/src/gui_at_fs.c 2010-08-15 21:57:28.000000000 +0200 +--- src/gui_at_fs.c 2013-06-27 22:31:35.000000000 +0200 +*************** +*** 2591,2597 **** + (XtCallbackProc)SFvFloatSliderMovedCallback, + (XtPointer)(long_u)n); + XtAddCallback(selFileVScrolls[n], XtNscrollProc, +! (XtCallbackProc)SFvAreaSelectedCallback, (XtPointer)n); + + selFileHScrolls[n] = XtVaCreateManagedWidget("selFileHScroll", + #ifdef FEAT_GUI_NEXTAW +--- 2591,2597 ---- + (XtCallbackProc)SFvFloatSliderMovedCallback, + (XtPointer)(long_u)n); + XtAddCallback(selFileVScrolls[n], XtNscrollProc, +! (XtCallbackProc)SFvAreaSelectedCallback, (XtPointer)(long_u)n); + + selFileHScrolls[n] = XtVaCreateManagedWidget("selFileHScroll", + #ifdef FEAT_GUI_NEXTAW +*************** +*** 2616,2622 **** + (XtCallbackProc)SFhSliderMovedCallback, + (XtPointer)(long_u)n); + XtAddCallback(selFileHScrolls[n], XtNscrollProc, +! (XtCallbackProc)SFhAreaSelectedCallback, (XtPointer)n); + } + + selFileOK = XtVaCreateManagedWidget("selFileOK", +--- 2616,2622 ---- + (XtCallbackProc)SFhSliderMovedCallback, + (XtPointer)(long_u)n); + XtAddCallback(selFileHScrolls[n], XtNscrollProc, +! (XtCallbackProc)SFhAreaSelectedCallback, (XtPointer)(long_u)n); + } + + selFileOK = XtVaCreateManagedWidget("selFileOK", +*** ../vim-7.3.1254/src/version.c 2013-06-27 22:29:35.000000000 +0200 +--- src/version.c 2013-06-27 22:32:26.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1255, + /**/ + +-- +A vacation is a period of travel during which you find that you +took twice as many clothes and half as much money as you needed. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 2116af8760a38bfbbb6d52d8ad31341996597f36 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:51 +0200 Subject: [PATCH 1149/3340] - patchlevel 1256 --- 7.3.1256 | 151 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 151 insertions(+) create mode 100644 7.3.1256 diff --git a/7.3.1256 b/7.3.1256 new file mode 100644 index 00000000..3cd589cb --- /dev/null +++ b/7.3.1256 @@ -0,0 +1,151 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1256 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1256 +Problem: Can't build without eval or autocmd feature. +Solution: Add #ifdefs. +Files: src/mbyte.c, src/window.c + + +*** ../vim-7.3.1255/src/mbyte.c 2013-06-26 19:17:58.000000000 +0200 +--- src/mbyte.c 2013-06-28 19:53:43.000000000 +0200 +*************** +*** 5079,5084 **** +--- 5079,5085 ---- + { + xim_set_focus(gui.in_focus); + ++ # ifdef FEAT_EVAL + if (p_imaf[0] != NUL) + { + char_u *argv[1]; +*************** +*** 5089,5095 **** + argv[0] = (char_u *)"0"; + (void)call_func_retnr(p_imaf, 1, argv, FALSE); + } +! else if (im_activatekey_keyval != GDK_VoidSymbol) + { + if (im_is_active) + { +--- 5090,5098 ---- + argv[0] = (char_u *)"0"; + (void)call_func_retnr(p_imaf, 1, argv, FALSE); + } +! else +! # endif +! if (im_activatekey_keyval != GDK_VoidSymbol) + { + if (im_is_active) + { +*************** +*** 5249,5260 **** + int + im_get_status(void) + { + if (p_imsf[0] != NUL) + { + int is_active; + + /* FIXME: Don't execute user function in unsafe situation. */ +! if (exiting || is_autocmd_blocked()) + return FALSE; + /* FIXME: :py print 'xxx' is shown duplicate result. + * Use silent to avoid it. */ +--- 5252,5268 ---- + int + im_get_status(void) + { ++ # ifdef FEAT_EVAL + if (p_imsf[0] != NUL) + { + int is_active; + + /* FIXME: Don't execute user function in unsafe situation. */ +! if (exiting +! # ifdef FEAT_AUTOCMD +! || is_autocmd_blocked() +! # endif +! ) + return FALSE; + /* FIXME: :py print 'xxx' is shown duplicate result. + * Use silent to avoid it. */ +*************** +*** 5263,5268 **** +--- 5271,5277 ---- + --msg_silent; + return (is_active > 0); + } ++ # endif + return im_is_active; + } + +*** ../vim-7.3.1255/src/window.c 2013-06-26 14:04:37.000000000 +0200 +--- src/window.c 2013-06-28 19:50:44.000000000 +0200 +*************** +*** 53,62 **** + static void frame_append __ARGS((frame_T *after, frame_T *frp)); + static void frame_insert __ARGS((frame_T *before, frame_T *frp)); + static void frame_remove __ARGS((frame_T *frp)); +! #ifdef FEAT_VERTSPLIT + static void win_goto_ver __ARGS((int up, long count)); + static void win_goto_hor __ARGS((int left, long count)); +! #endif + static void frame_add_height __ARGS((frame_T *frp, int n)); + static void last_status_rec __ARGS((frame_T *fr, int statusline)); + +--- 53,62 ---- + static void frame_append __ARGS((frame_T *after, frame_T *frp)); + static void frame_insert __ARGS((frame_T *before, frame_T *frp)); + static void frame_remove __ARGS((frame_T *frp)); +! # ifdef FEAT_VERTSPLIT + static void win_goto_ver __ARGS((int up, long count)); + static void win_goto_hor __ARGS((int left, long count)); +! # endif + static void frame_add_height __ARGS((frame_T *frp, int n)); + static void last_status_rec __ARGS((frame_T *fr, int statusline)); + +*************** +*** 6928,6933 **** +--- 6928,6934 ---- + } + #endif + ++ #ifdef FEAT_WINDOWS + /* + * Return TRUE if "topfrp" and its children are at the right height. + */ +*************** +*** 6948,6953 **** +--- 6949,6955 ---- + + return TRUE; + } ++ #endif + + #ifdef FEAT_VERTSPLIT + /* +*** ../vim-7.3.1255/src/version.c 2013-06-27 22:35:58.000000000 +0200 +--- src/version.c 2013-06-28 19:54:22.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1256, + /**/ + +-- +Q: How does a UNIX Guru do Sex ? +A: unzip;strip;touch;finger;mount;fsck;more;yes;umount;sleep + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 7765606b873c8c1bd16ebbea9ce43321a163cee8 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:52 +0200 Subject: [PATCH 1150/3340] - patchlevel 1257 --- 7.3.1257 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 7.3.1257 diff --git a/7.3.1257 b/7.3.1257 new file mode 100644 index 00000000..477f4d26 --- /dev/null +++ b/7.3.1257 @@ -0,0 +1,54 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1257 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1257 +Problem: With GNU gettext() ":lang de_DE.utf8" does not always result in + German messages. +Solution: Clear the $LANGUAGE environment variable. +Files: src/ex_cmds2.c + + +*** ../vim-7.3.1256/src/ex_cmds2.c 2013-06-10 21:27:18.000000000 +0200 +--- src/ex_cmds2.c 2013-06-28 20:14:53.000000000 +0200 +*************** +*** 4261,4266 **** +--- 4261,4269 ---- + if (what == LC_ALL) + { + vim_setenv((char_u *)"LANG", name); ++ ++ /* Clear $LANGUAGE because GNU gettext uses it. */ ++ vim_setenv((char_u *)"LANGUAGE", (char_u *)""); + # ifdef WIN32 + /* Apparently MS-Windows printf() may cause a crash when + * we give it 8-bit text while it's expecting text in the +*** ../vim-7.3.1256/src/version.c 2013-06-28 20:16:50.000000000 +0200 +--- src/version.c 2013-06-28 20:18:08.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1257, + /**/ + + +-- + [clop clop] +GUARD #1: Halt! Who goes there? +ARTHUR: It is I, Arthur, son of Uther Pendragon, from the castle of + Camelot. King of the Britons, defeator of the Saxons, sovereign of + all England! +GUARD #1: Pull the other one! + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 4353923dbcd6c19c09e4dba4e9fc4ef7e2a13e37 Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:53 +0200 Subject: [PATCH 1151/3340] - patchlevel 1258 --- 7.3.1258 | 62 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 7.3.1258 diff --git a/7.3.1258 b/7.3.1258 new file mode 100644 index 00000000..e9067ee0 --- /dev/null +++ b/7.3.1258 @@ -0,0 +1,62 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1258 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1258 +Problem: Using submatch() may crash Vim. (Ingo Karkat) +Solution: Restore the number of subexpressions used. +Files: src/regexp_nfa.c + + +*** ../vim-7.3.1257/src/regexp_nfa.c 2013-06-26 18:16:55.000000000 +0200 +--- src/regexp_nfa.c 2013-06-28 22:59:38.000000000 +0200 +*************** +*** 5198,5203 **** +--- 5198,5205 ---- + || t->state->c == NFA_START_INVISIBLE_BEFORE_FIRST + || t->state->c == NFA_START_INVISIBLE_BEFORE_NEG_FIRST) + { ++ int in_use = m->norm.in_use; ++ + /* Copy submatch info for the recursive call, so that + * \1 can be matched. */ + copy_sub_off(&m->norm, &t->subs.norm); +*************** +*** 5231,5236 **** +--- 5233,5239 ---- + add_here = TRUE; + add_state = t->state->out1->out; + } ++ m->norm.in_use = in_use; + } + else + { +*** ../vim-7.3.1257/src/version.c 2013-06-28 20:36:26.000000000 +0200 +--- src/version.c 2013-06-28 23:00:55.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1258, + /**/ + + +-- +GUARD #1: What, ridden on a horse? +ARTHUR: Yes! +GUARD #1: You're using coconuts! +ARTHUR: What? +GUARD #1: You've got two empty halves of coconut and you're bangin' 'em + together. + The Quest for the Holy Grail (Monty Python) + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 015046aefce763c80b35823023cde8f62fbad43c Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:54 +0200 Subject: [PATCH 1152/3340] - patchlevel 1259 --- 7.3.1259 | 86 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 7.3.1259 diff --git a/7.3.1259 b/7.3.1259 new file mode 100644 index 00000000..f1c6a6d1 --- /dev/null +++ b/7.3.1259 @@ -0,0 +1,86 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1259 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1259 +Problem: No test for patch 7.3.1258 +Solution: Add a test entry. +Files: src/testdir/test64.in, src/testdir/test64.ok + + +*** ../vim-7.3.1258/src/testdir/test64.in 2013-06-26 18:16:55.000000000 +0200 +--- src/testdir/test64.in 2013-06-29 12:02:33.000000000 +0200 +*************** +*** 384,389 **** +--- 384,390 ---- + :call add(tl, [2, '^.*\.\(.*\)/.\+\(\1\)\@ Date: Thu, 4 Jul 2013 15:36:55 +0200 Subject: [PATCH 1153/3340] - patchlevel 1260 --- 7.3.1260 | 125 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 125 insertions(+) create mode 100644 7.3.1260 diff --git a/7.3.1260 b/7.3.1260 new file mode 100644 index 00000000..4661b316 --- /dev/null +++ b/7.3.1260 @@ -0,0 +1,125 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1260 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1260 +Problem: User completion does not get the whole command line in the command + line window. +Solution: Pass on the whole command line. (Daniel Thau) +Files: src/ex_getln.c, src/structs.h + + +*** ../vim-7.3.1259/src/ex_getln.c 2013-06-23 16:16:13.000000000 +0200 +--- src/ex_getln.c 2013-06-29 12:53:30.000000000 +0200 +*************** +*** 3729,3734 **** +--- 3729,3735 ---- + #if defined(FEAT_USR_CMDS) && defined(FEAT_EVAL) && defined(FEAT_CMDL_COMPL) + xp->xp_arg = NULL; + #endif ++ xp->xp_line = NULL; + } + + /* +*************** +*** 4378,4383 **** +--- 4379,4389 ---- + int old_char = NUL; + char_u *nextcomm; + ++ /* Store the string here so that call_user_expand_func() can get to them ++ * easily. */ ++ xp->xp_line = str; ++ xp->xp_col = col; ++ + /* + * Avoid a UMR warning from Purify, only save the character if it has been + * written before. +*************** +*** 4952,4978 **** + void *ret; + struct cmdline_info save_ccline; + +! if (xp->xp_arg == NULL || xp->xp_arg[0] == '\0') + return NULL; + *num_file = 0; + *file = NULL; + +! if (ccline.cmdbuff == NULL) + { +- /* Completion from Insert mode, pass fake arguments. */ +- keep = 0; +- sprintf((char *)num, "%d", (int)STRLEN(xp->xp_pattern)); +- args[1] = xp->xp_pattern; +- } +- else +- { +- /* Completion on the command line, pass real arguments. */ + keep = ccline.cmdbuff[ccline.cmdlen]; + ccline.cmdbuff[ccline.cmdlen] = 0; +- sprintf((char *)num, "%d", ccline.cmdpos); +- args[1] = ccline.cmdbuff; + } + args[0] = vim_strnsave(xp->xp_pattern, xp->xp_pattern_len); + args[2] = num; + + /* Save the cmdline, we don't know what the function may do. */ +--- 4958,4977 ---- + void *ret; + struct cmdline_info save_ccline; + +! if (xp->xp_arg == NULL || xp->xp_arg[0] == '\0' || xp->xp_line == NULL) + return NULL; + *num_file = 0; + *file = NULL; + +! if (ccline.cmdbuff != NULL) + { + keep = ccline.cmdbuff[ccline.cmdlen]; + ccline.cmdbuff[ccline.cmdlen] = 0; + } ++ + args[0] = vim_strnsave(xp->xp_pattern, xp->xp_pattern_len); ++ args[1] = xp->xp_line; ++ sprintf((char *)num, "%d", xp->xp_col); + args[2] = num; + + /* Save the cmdline, we don't know what the function may do. */ +*** ../vim-7.3.1259/src/structs.h 2013-06-12 19:52:11.000000000 +0200 +--- src/structs.h 2013-06-29 12:47:03.000000000 +0200 +*************** +*** 493,498 **** +--- 493,500 ---- + int xp_numfiles; /* number of files found by + file name completion */ + char_u **xp_files; /* list of files */ ++ char_u *xp_line; /* text being completed */ ++ int xp_col; /* cursor position in line */ + } expand_T; + + /* values for xp_backslash */ +*** ../vim-7.3.1259/src/version.c 2013-06-29 12:10:22.000000000 +0200 +--- src/version.c 2013-06-29 12:41:08.000000000 +0200 +*************** +*** 730,731 **** +--- 730,733 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 1260, + /**/ + +-- +This is the polymorph virus! Follow these instructions carefully: +1. Send this message to everybody you know. +2. Format your harddisk. +Thank you for your cooperation in spreading the most powerful virus ever! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// From 748f1e15fd82e485c5353709d663c348668264dd Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Thu, 4 Jul 2013 15:36:55 +0200 Subject: [PATCH 1154/3340] - patchlevel 1261 --- 7.3.1261 | 329 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 329 insertions(+) create mode 100644 7.3.1261 diff --git a/7.3.1261 b/7.3.1261 new file mode 100644 index 00000000..55f4d77d --- /dev/null +++ b/7.3.1261 @@ -0,0 +1,329 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.3.1261 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.3.1261 (after patch 7.3.1179) +Problem: A buffer-local language mapping from a keymap stops a global + insert mode mapping from working. (Ron Aaron) +Solution: Do not wait for more characters to be typed only when the mapping + was defined with . +Files: runtime/doc/map.txt, src/eval.c, src/getchar.c, + src/testdir/test75.in, src/testdir/test75.ok + + +*** ../vim-7.3.1260/runtime/doc/map.txt 2013-06-12 21:00:18.000000000 +0200 +--- runtime/doc/map.txt 2013-06-29 13:55:01.000000000 +0200 +*************** +*** 159,167 **** + + 1.2 SPECIAL ARGUMENTS *:map-arguments* + +! "", "", "", "