Patch 8.0.1681
Problem:    The format attribute fails with MinGW. (John Marriott)
Solution:   Don't use the format attribute with MinGW.
Files:      src/vim.h, src/proto.h, src/channel.c


*** ../vim-8.0.1680/src/vim.h   2018-04-08 13:07:18.738034830 +0200
--- src/vim.h   2018-04-10 12:37:59.380931164 +0200
***************
*** 2085,2090 ****
--- 2085,2094 ----
  typedef struct stat stat_T;
  #endif
  
+ #if defined(__GNUC__) && !defined(__MINGW32__)
+ # define USE_PRINTF_FORMAT_ATTRIBUTE
+ #endif
+ 
  typedef enum
  {
      ASSERT_EQUAL,
*** ../vim-8.0.1680/src/proto.h 2018-04-08 13:07:18.738034830 +0200
--- src/proto.h 2018-04-10 12:40:16.328013170 +0200
***************
*** 120,126 ****
  _RTLENTRYF
  #  endif
  vim_snprintf_add(char *, size_t, char *, ...)
! #ifdef __GNUC__
      __attribute__((format(printf, 3, 4)))
  #endif
      ;
--- 120,126 ----
  _RTLENTRYF
  #  endif
  vim_snprintf_add(char *, size_t, char *, ...)
! #ifdef USE_PRINTF_FORMAT_ATTRIBUTE
      __attribute__((format(printf, 3, 4)))
  #endif
      ;
***************
*** 130,136 ****
  _RTLENTRYF
  #  endif
  vim_snprintf(char *, size_t, char *, ...)
! #ifdef __GNUC__
      __attribute__((format(printf, 3, 4)))
  #endif
      ;
--- 130,136 ----
  _RTLENTRYF
  #  endif
  vim_snprintf(char *, size_t, char *, ...)
! #ifdef USE_PRINTF_FORMAT_ATTRIBUTE
      __attribute__((format(printf, 3, 4)))
  #endif
      ;
***************
*** 223,229 ****
  
  /* Not generated automatically, to add extra attribute. */
  void ch_log(channel_T *ch, const char *fmt, ...)
! #ifdef __GNUC__
      __attribute__((format(printf, 2, 3)))
  #endif
      ;
--- 223,229 ----
  
  /* Not generated automatically, to add extra attribute. */
  void ch_log(channel_T *ch, const char *fmt, ...)
! #ifdef USE_PRINTF_FORMAT_ATTRIBUTE
      __attribute__((format(printf, 2, 3)))
  #endif
      ;
*** ../vim-8.0.1680/src/channel.c       2018-04-08 12:38:22.194293134 +0200
--- src/channel.c       2018-04-10 12:39:38.300268193 +0200
***************
*** 179,186 ****
  
      static void
  ch_error(channel_T *ch, const char *fmt, ...)
! #ifdef __GNUC__
! __attribute__((format(printf, 2, 3)))
  #endif
      ;
  
--- 179,186 ----
  
      static void
  ch_error(channel_T *ch, const char *fmt, ...)
! #ifdef USE_PRINTF_FORMAT_ATTRIBUTE
!     __attribute__((format(printf, 2, 3)))
  #endif
      ;
  
*** ../vim-8.0.1680/src/version.c       2018-04-10 12:04:23.378053554 +0200
--- src/version.c       2018-04-10 12:41:34.819486569 +0200
***************
*** 764,765 ****
--- 764,767 ----
  {   /* Add new patch number below this line */
+ /**/
+     1681,
  /**/

-- 
hundred-and-one symptoms of being an internet addict:
140. You'd rather catch a score on the web than watch the game as
     it is being played on tv.

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui