Karsten Hopp 791da1
To: vim_dev@googlegroups.com
Karsten Hopp 791da1
Subject: Patch 7.4.145
Karsten Hopp 791da1
Fcc: outbox
Karsten Hopp 791da1
From: Bram Moolenaar <Bram@moolenaar.net>
Karsten Hopp 791da1
Mime-Version: 1.0
Karsten Hopp 791da1
Content-Type: text/plain; charset=UTF-8
Karsten Hopp 791da1
Content-Transfer-Encoding: 8bit
Karsten Hopp 791da1
------------
Karsten Hopp 791da1
Karsten Hopp 791da1
Patch 7.4.145
Karsten Hopp 791da1
Problem:    getregtype() does not return zero for unknown register.
Karsten Hopp 791da1
Solution:   Adjust documention: return empty string for unknown register.
Karsten Hopp 791da1
	    Check the register name to be valid. (Yukihiro Nakadaira)
Karsten Hopp 791da1
Files:	    runtime/doc/eval.txt, src/ops.c
Karsten Hopp 791da1
Karsten Hopp 791da1
Karsten Hopp 791da1
*** ../vim-7.4.144/runtime/doc/eval.txt	2013-11-09 01:44:38.000000000 +0100
Karsten Hopp 791da1
--- runtime/doc/eval.txt	2014-01-14 12:24:35.000000000 +0100
Karsten Hopp 791da1
***************
Karsten Hopp 791da1
*** 3459,3465 ****
Karsten Hopp 791da1
  		    "v"			for |characterwise| text
Karsten Hopp 791da1
  		    "V"			for |linewise| text
Karsten Hopp 791da1
  		    "<CTRL-V>{width}"	for |blockwise-visual| text
Karsten Hopp 791da1
! 		    0			for an empty or unknown register
Karsten Hopp 791da1
  		<CTRL-V> is one character with value 0x16.
Karsten Hopp 791da1
  		If {regname} is not specified, |v:register| is used.
Karsten Hopp 791da1
  
Karsten Hopp 791da1
--- 3460,3466 ----
Karsten Hopp 791da1
  		    "v"			for |characterwise| text
Karsten Hopp 791da1
  		    "V"			for |linewise| text
Karsten Hopp 791da1
  		    "<CTRL-V>{width}"	for |blockwise-visual| text
Karsten Hopp 791da1
! 		    ""			for an empty or unknown register
Karsten Hopp 791da1
  		<CTRL-V> is one character with value 0x16.
Karsten Hopp 791da1
  		If {regname} is not specified, |v:register| is used.
Karsten Hopp 791da1
  
Karsten Hopp 791da1
*** ../vim-7.4.144/src/ops.c	2013-11-21 14:39:58.000000000 +0100
Karsten Hopp 791da1
--- src/ops.c	2014-01-14 12:28:33.000000000 +0100
Karsten Hopp 791da1
***************
Karsten Hopp 791da1
*** 6240,6246 ****
Karsten Hopp 791da1
      regname = may_get_selection(regname);
Karsten Hopp 791da1
  #endif
Karsten Hopp 791da1
  
Karsten Hopp 791da1
!     /* Should we check for a valid name? */
Karsten Hopp 791da1
      get_yank_register(regname, FALSE);
Karsten Hopp 791da1
  
Karsten Hopp 791da1
      if (y_current->y_array != NULL)
Karsten Hopp 791da1
--- 6240,6248 ----
Karsten Hopp 791da1
      regname = may_get_selection(regname);
Karsten Hopp 791da1
  #endif
Karsten Hopp 791da1
  
Karsten Hopp 791da1
!     if (regname != NUL && !valid_yank_reg(regname, FALSE))
Karsten Hopp 791da1
!         return MAUTO;
Karsten Hopp 791da1
! 
Karsten Hopp 791da1
      get_yank_register(regname, FALSE);
Karsten Hopp 791da1
  
Karsten Hopp 791da1
      if (y_current->y_array != NULL)
Karsten Hopp 791da1
*** ../vim-7.4.144/src/version.c	2014-01-14 12:18:41.000000000 +0100
Karsten Hopp 791da1
--- src/version.c	2014-01-14 12:26:13.000000000 +0100
Karsten Hopp 791da1
***************
Karsten Hopp 791da1
*** 740,741 ****
Karsten Hopp 791da1
--- 740,743 ----
Karsten Hopp 791da1
  {   /* Add new patch number below this line */
Karsten Hopp 791da1
+ /**/
Karsten Hopp 791da1
+     145,
Karsten Hopp 791da1
  /**/
Karsten Hopp 791da1
Karsten Hopp 791da1
-- 
Karsten Hopp 791da1
hundred-and-one symptoms of being an internet addict:
Karsten Hopp 791da1
151. You find yourself engaged to someone you've never actually met,
Karsten Hopp 791da1
     except through e-mail.
Karsten Hopp 791da1
Karsten Hopp 791da1
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
Karsten Hopp 791da1
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
Karsten Hopp 791da1
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
Karsten Hopp 791da1
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///