Karsten Hopp 0299a0
To: vim-dev@vim.org
Karsten Hopp 0299a0
Subject: Patch 7.1.178
Karsten Hopp 0299a0
Fcc: outbox
Karsten Hopp 0299a0
From: Bram Moolenaar <Bram@moolenaar.net>
Karsten Hopp 0299a0
Mime-Version: 1.0
Karsten Hopp 0299a0
Content-Type: text/plain; charset=ISO-8859-1
Karsten Hopp 0299a0
Content-Transfer-Encoding: 8bit
Karsten Hopp 0299a0
------------
Karsten Hopp 0299a0
Karsten Hopp 0299a0
Patch 7.1.178
Karsten Hopp 0299a0
Problem:    "%" doesn't work on "/* comment *//* comment */".
Karsten Hopp 0299a0
Solution:   Don't handle the "//" in "*//*" as a C++ comment. (Markus
Karsten Hopp 0299a0
	    Heidelberg)
Karsten Hopp 0299a0
Files:	    src/search.c
Karsten Hopp 0299a0
Karsten Hopp 0299a0
Karsten Hopp 0299a0
*** ../vim-7.1.177/src/search.c	Wed Aug  8 22:48:16 2007
Karsten Hopp 0299a0
--- src/search.c	Mon Dec 10 21:21:17 2007
Karsten Hopp 0299a0
***************
Karsten Hopp 0299a0
*** 2319,2325 ****
Karsten Hopp 0299a0
  #endif
Karsten Hopp 0299a0
      while ((p = vim_strchr(p, '/')) != NULL)
Karsten Hopp 0299a0
      {
Karsten Hopp 0299a0
! 	if (p[1] == '/')
Karsten Hopp 0299a0
  	    break;
Karsten Hopp 0299a0
  	++p;
Karsten Hopp 0299a0
      }
Karsten Hopp 0299a0
--- 2319,2327 ----
Karsten Hopp 0299a0
  #endif
Karsten Hopp 0299a0
      while ((p = vim_strchr(p, '/')) != NULL)
Karsten Hopp 0299a0
      {
Karsten Hopp 0299a0
! 	/* accept a double /, unless it's preceded with * and followed by *,
Karsten Hopp 0299a0
! 	 * because * / / * is an end and start of a C comment */
Karsten Hopp 0299a0
! 	if (p[1] == '/' && (p == line || p[-1] != '*' || p[2] != '*'))
Karsten Hopp 0299a0
  	    break;
Karsten Hopp 0299a0
  	++p;
Karsten Hopp 0299a0
      }
Karsten Hopp 0299a0
*** ../vim-7.1.177/src/version.c	Tue Jan  1 14:16:42 2008
Karsten Hopp 0299a0
--- src/version.c	Tue Jan  1 15:41:33 2008
Karsten Hopp 0299a0
***************
Karsten Hopp 0299a0
*** 668,669 ****
Karsten Hopp 0299a0
--- 668,671 ----
Karsten Hopp 0299a0
  {   /* Add new patch number below this line */
Karsten Hopp 0299a0
+ /**/
Karsten Hopp 0299a0
+     178,
Karsten Hopp 0299a0
  /**/
Karsten Hopp 0299a0
Karsten Hopp 0299a0
-- 
Karsten Hopp 0299a0
I'd like to meet the man who invented sex and see what he's working on now.
Karsten Hopp 0299a0
Karsten Hopp 0299a0
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
Karsten Hopp 0299a0
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
Karsten Hopp 0299a0
\\\        download, build and distribute -- http://www.A-A-P.org        ///
Karsten Hopp 0299a0
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///