81c2858
To: vim-dev@vim.org
81c2858
Subject: Patch 7.2.176
81c2858
Fcc: outbox
81c2858
From: Bram Moolenaar <Bram@moolenaar.net>
81c2858
Mime-Version: 1.0
81c2858
Content-Type: text/plain; charset=UTF-8
81c2858
Content-Transfer-Encoding: 8bit
81c2858
------------
81c2858
81c2858
Patch 7.2.176
81c2858
Problem:    Exceptions for splint are not useful.
81c2858
Solution:   Remove the S_SPLINT_S ifdefs.
81c2858
Files:	    src/edit.c, src/ex_cmds.c, src/ex_docmd.c, src/os_unix.c,
81c2858
	    src/os_unix.h, src/os_unixx.h, src/structs.h, src/term.h
81c2858
81c2858
81c2858
*** ../vim-7.2.175/src/edit.c	2009-05-15 21:31:11.000000000 +0200
81c2858
--- src/edit.c	2009-05-16 16:18:35.000000000 +0200
81c2858
***************
81c2858
*** 69,79 ****
81c2858
      compl_T	*cp_prev;
81c2858
      char_u	*cp_str;	/* matched text */
81c2858
      char	cp_icase;	/* TRUE or FALSE: ignore case */
81c2858
- #ifdef S_SPLINT_S  /* splint can't handle array of pointers */
81c2858
-     char_u	**cp_text;	/* text for the menu */
81c2858
- #else
81c2858
      char_u	*(cp_text[CPT_COUNT]);	/* text for the menu */
81c2858
- #endif
81c2858
      char_u	*cp_fname;	/* file containing the match, allocated when
81c2858
  				 * cp_flags has FREE_FNAME */
81c2858
      int		cp_flags;	/* ORIGINAL_TEXT, CONT_S_IPOS or FREE_FNAME */
81c2858
--- 69,75 ----
81c2858
***************
81c2858
*** 3835,3845 ****
81c2858
      char_u	*word;
81c2858
      int		icase = FALSE;
81c2858
      int		adup = FALSE;
81c2858
- #ifdef S_SPLINT_S  /* splint doesn't parse array of pointers correctly */
81c2858
-     char_u	**cptext;
81c2858
- #else
81c2858
      char_u	*(cptext[CPT_COUNT]);
81c2858
- #endif
81c2858
  
81c2858
      if (tv->v_type == VAR_DICT && tv->vval.v_dict != NULL)
81c2858
      {
81c2858
--- 3831,3837 ----
81c2858
*** ../vim-7.2.175/src/ex_cmds.c	2009-05-15 21:31:11.000000000 +0200
81c2858
--- src/ex_cmds.c	2009-05-16 16:18:56.000000000 +0200
81c2858
***************
81c2858
*** 5776,5785 ****
81c2858
  {
81c2858
      char_u	*s, *d;
81c2858
      int		i;
81c2858
- #ifdef S_SPLINT_S  /* splint doesn't understand array of pointers */
81c2858
-     static char **mtable;
81c2858
-     static char **rtable;
81c2858
- #else
81c2858
      static char *(mtable[]) = {"*", "g*", "[*", "]*", ":*",
81c2858
  			       "/*", "/\\*", "\"*", "**",
81c2858
  			       "/\\(\\)",
81c2858
--- 5776,5781 ----
81c2858
***************
81c2858
*** 5794,5800 ****
81c2858
  			       "/\\\\?", "/\\\\z(\\\\)", "\\\\=", ":s\\\\=",
81c2858
  			       "\\[count]", "\\[quotex]", "\\[range]",
81c2858
  			       "\\[pattern]", "\\\\bar", "/\\\\%\\$"};
81c2858
- #endif
81c2858
      int flags;
81c2858
  
81c2858
      d = IObuff;		    /* assume IObuff is long enough! */
81c2858
--- 5790,5795 ----
81c2858
*** ../vim-7.2.175/src/ex_docmd.c	2009-05-15 21:31:11.000000000 +0200
81c2858
--- src/ex_docmd.c	2009-05-16 16:19:26.000000000 +0200
81c2858
***************
81c2858
*** 9395,9407 ****
81c2858
  {
81c2858
      int		len;
81c2858
      int		i;
81c2858
! #ifdef S_SPLINT_S  /* splint can't handle array of pointers */
81c2858
!     static char **spec_str;
81c2858
!     static char *(nospec_str[])
81c2858
! #else
81c2858
!     static char *(spec_str[])
81c2858
! #endif
81c2858
! 	= {
81c2858
  		    "%",
81c2858
  #define SPEC_PERC   0
81c2858
  		    "#",
81c2858
--- 9395,9401 ----
81c2858
  {
81c2858
      int		len;
81c2858
      int		i;
81c2858
!     static char *(spec_str[]) = {
81c2858
  		    "%",
81c2858
  #define SPEC_PERC   0
81c2858
  		    "#",
81c2858
*** ../vim-7.2.175/src/os_unix.c	2009-05-15 21:31:11.000000000 +0200
81c2858
--- src/os_unix.c	2009-05-16 16:20:00.000000000 +0200
81c2858
***************
81c2858
*** 199,207 ****
81c2858
  #endif
81c2858
  
81c2858
  #ifndef SIG_ERR
81c2858
! # ifndef S_SPLINT_S
81c2858
! #  define SIG_ERR	((RETSIGTYPE (*)())-1)
81c2858
! # endif
81c2858
  #endif
81c2858
  
81c2858
  /* volatile because it is used in signal handler sig_winch(). */
81c2858
--- 199,205 ----
81c2858
  #endif
81c2858
  
81c2858
  #ifndef SIG_ERR
81c2858
! # define SIG_ERR	((RETSIGTYPE (*)())-1)
81c2858
  #endif
81c2858
  
81c2858
  /* volatile because it is used in signal handler sig_winch(). */
81c2858
***************
81c2858
*** 443,451 ****
81c2858
  
81c2858
  #if defined(HAVE_TOTAL_MEM) || defined(PROTO)
81c2858
  # ifdef HAVE_SYS_RESOURCE_H
81c2858
! #  ifndef S_SPLINT_S  /* splint crashes on bits/resource.h */
81c2858
! #   include <sys/resource.h>
81c2858
! #  endif
81c2858
  # endif
81c2858
  # if defined(HAVE_SYS_SYSCTL_H) && defined(HAVE_SYSCTL)
81c2858
  #  include <sys/sysctl.h>
81c2858
--- 441,447 ----
81c2858
  
81c2858
  #if defined(HAVE_TOTAL_MEM) || defined(PROTO)
81c2858
  # ifdef HAVE_SYS_RESOURCE_H
81c2858
! #  include <sys/resource.h>
81c2858
  # endif
81c2858
  # if defined(HAVE_SYS_SYSCTL_H) && defined(HAVE_SYSCTL)
81c2858
  #  include <sys/sysctl.h>
81c2858
*** ../vim-7.2.175/src/os_unix.h	2009-05-15 21:31:11.000000000 +0200
81c2858
--- src/os_unix.h	2009-05-16 16:17:22.000000000 +0200
81c2858
***************
81c2858
*** 53,61 ****
81c2858
  #endif
81c2858
  
81c2858
  #ifdef HAVE_UNISTD_H
81c2858
! # ifndef S_SPLINT_S  /* splint crashes on bits/confname.h */
81c2858
! #  include <unistd.h>
81c2858
! # endif
81c2858
  #endif
81c2858
  
81c2858
  #ifdef HAVE_LIBC_H
81c2858
--- 53,59 ----
81c2858
  #endif
81c2858
  
81c2858
  #ifdef HAVE_UNISTD_H
81c2858
! # include <unistd.h>
81c2858
  #endif
81c2858
  
81c2858
  #ifdef HAVE_LIBC_H
81c2858
*** ../vim-7.2.175/src/structs.h	2009-05-13 20:47:07.000000000 +0200
81c2858
--- src/structs.h	2009-05-16 16:17:51.000000000 +0200
81c2858
***************
81c2858
*** 1646,1656 ****
81c2858
  #endif
81c2858
  #ifdef FEAT_DIFF
81c2858
      diff_T	    *tp_first_diff;
81c2858
- # ifdef S_SPLINT_S  /* splint doesn't understand the array of pointers */
81c2858
-     buf_T	    **tp_diffbuf;
81c2858
- # else
81c2858
      buf_T	    *(tp_diffbuf[DB_COUNT]);
81c2858
- # endif
81c2858
      int		    tp_diff_invalid;	/* list of diffs is outdated */
81c2858
  #endif
81c2858
      frame_T	    *tp_snapshot;    /* window layout snapshot */
81c2858
--- 1646,1652 ----
81c2858
*** ../vim-7.2.175/src/term.h	2009-05-13 18:54:14.000000000 +0200
81c2858
--- src/term.h	2009-05-16 16:20:06.000000000 +0200
81c2858
***************
81c2858
*** 96,106 ****
81c2858
   * - there should be code in term.c to obtain the value from the termcap
81c2858
   */
81c2858
  
81c2858
- #ifdef S_SPLINT_S  /* splint doesn't understand array of pointers */
81c2858
- extern char_u **term_strings;    /* current terminal strings */
81c2858
- #else
81c2858
  extern char_u *(term_strings[]);    /* current terminal strings */
81c2858
- #endif
81c2858
  
81c2858
  /*
81c2858
   * strings used for terminal
81c2858
--- 96,102 ----
81c2858
*** ../vim-7.2.175/src/version.c	2009-05-16 16:15:39.000000000 +0200
81c2858
--- src/version.c	2009-05-16 16:34:10.000000000 +0200
81c2858
***************
81c2858
*** 678,679 ****
81c2858
--- 678,681 ----
81c2858
  {   /* Add new patch number below this line */
81c2858
+ /**/
81c2858
+     176,
81c2858
  /**/
81c2858
81c2858
-- 
81c2858
Corn oil comes from corn and olive oil comes from olives, so where
81c2858
does baby oil come from?
81c2858
81c2858
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
81c2858
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
81c2858
\\\        download, build and distribute -- http://www.A-A-P.org        ///
81c2858
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///