Blob Blame History Raw
To: vim-dev@vim.org
Subject: Patch 7.0.056
Fcc: outbox
From: Bram Moolenaar <Bram@moolenaar.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
------------

Patch 7.0.056
Problem:    "#!something" gives an error message.
Solution:   Ignore this line, so that it can be used in an executable Vim
            script.
Files:      src/ex_docmd.c


*** ../vim-7.0.055/src/ex_docmd.c	Sat May 13 12:36:18 2006
--- src/ex_docmd.c	Thu Aug 10 23:50:32 2006
***************
*** 1709,1714 ****
--- 1712,1721 ----
       */
      save_cmdmod = cmdmod;
      vim_memset(&cmdmod, 0, sizeof(cmdmod));
+ 
+     /* "#!anything" is handled like a comment. */
+     if ((*cmdlinep)[0] == '#' && (*cmdlinep)[1] == '!')
+ 	goto doend;
  
      /*
       * Repeat until no more command modifiers are found.
*** ../vim-7.0.055/src/version.c	Wed Aug 16 16:24:58 2006
--- src/version.c	Wed Aug 16 17:05:35 2006
***************
*** 668,669 ****
--- 668,671 ----
  {   /* Add new patch number below this line */
+ /**/
+     56,
  /**/

-- 
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/ \\\
\\\        download, build and distribute -- http://www.A-A-P.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///