home *** CD-ROM | disk | FTP | other *** search
/ vim.ftp.fu-berlin.de / 2015-02-03.vim.ftp.fu-berlin.de.tar / vim.ftp.fu-berlin.de / patches / 6.2.405 < prev    next >
Encoding:
Internet Message Format  |  2004-03-25  |  2.4 KB

  1. To: vim-dev@vim.org
  2. Subject: Patch 6.2.405
  3. Fcc: outbox
  4. From: Bram Moolenaar <Bram@moolenaar.net>
  5. Mime-Version: 1.0
  6. Content-Type: text/plain; charset=ISO-8859-1
  7. Content-Transfer-Encoding: 8bit
  8. ------------
  9.  
  10. Patch 6.2.405
  11. Problem:    Cannot map zero without breaking the count before a command.
  12.         (Benji Fisher)
  13. Solution:   Disable mapping zero when entering a count.
  14. Files:        src/getchar.c, src/globals.h, src/normal.c
  15.  
  16.  
  17. *** ../vim-6.2.404/src/getchar.c    Tue Mar 23 21:23:28 2004
  18. --- src/getchar.c    Fri Mar 26 21:50:04 2004
  19. ***************
  20. *** 1841,1846 ****
  21. --- 1841,1847 ----
  22.               max_mlen = 0;
  23.               c1 = typebuf.tb_buf[typebuf.tb_off];
  24.               if (no_mapping == 0 && maphash_valid
  25. +                 && (no_zero_mapping == 0 || c1 != '0')
  26.                   && (typebuf.tb_maplen == 0
  27.                   || (p_remap
  28.                       && typebuf.tb_noremap[typebuf.tb_off]
  29. *** ../vim-6.2.404/src/globals.h    Mon Mar  8 12:27:39 2004
  30. --- src/globals.h    Fri Mar 26 21:49:27 2004
  31. ***************
  32. *** 754,759 ****
  33. --- 759,765 ----
  34.   EXTERN int    Exec_reg INIT(= FALSE);    /* TRUE when executing a register */
  35.   
  36.   EXTERN int    no_mapping INIT(= FALSE);   /* currently no mapping allowed */
  37. + EXTERN int    no_zero_mapping INIT(= 0);  /* mapping zero not allowed */
  38.   EXTERN int    allow_keys INIT(= FALSE);   /* allow key codes when no_mapping
  39.                            * is set */
  40.   EXTERN int    no_u_sync INIT(= 0);    /* Don't call u_sync() */
  41. *** ../vim-6.2.404/src/normal.c    Thu Mar 18 12:20:26 2004
  42. --- src/normal.c    Fri Mar 26 21:49:10 2004
  43. ***************
  44. *** 685,694 ****
  45. --- 685,696 ----
  46.           ++no_mapping;
  47.           ++allow_keys;        /* no mapping for nchar, but keys */
  48.           }
  49. +         ++no_zero_mapping;        /* don't map zero here */
  50.           c = safe_vgetc();
  51.   #ifdef FEAT_LANGMAP
  52.           LANGMAP_ADJUST(c, TRUE);
  53.   #endif
  54. +         --no_zero_mapping;
  55.           if (ctrl_w)
  56.           {
  57.           --no_mapping;
  58. *** ../vim-6.2.404/src/version.c    Fri Mar 26 14:25:07 2004
  59. --- src/version.c    Fri Mar 26 22:00:33 2004
  60. ***************
  61. *** 639,640 ****
  62. --- 639,642 ----
  63.   {   /* Add new patch number below this line */
  64. + /**/
  65. +     405,
  66.   /**/
  67.  
  68. -- 
  69. hundred-and-one symptoms of being an internet addict:
  70. 159. You get excited whenever discussing your hard drive.
  71.  
  72.  /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
  73. ///        Sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
  74. \\\              Project leader for A-A-P -- http://www.A-A-P.org        ///
  75.  \\\  Buy at Amazon and help AIDS victims -- http://ICCF.nl/click1.html ///
  76.