Skip to content

Commit f32c5cd

Browse files
committed
patch 7.4.1080
Problem: VS2015 has a function HandleToLong() that is shadowed by the macro that Vim defines. Solution: Do not define HandleToLong() for MSVC version 1400 and later. (Mike Williams)
1 parent b86a343 commit f32c5cd

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

src/gui_w32.c

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1769,9 +1769,11 @@ gui_mch_init(void)
17691769
#endif
17701770

17711771
#ifdef FEAT_EVAL
1772-
# ifndef HandleToLong
1773-
/* HandleToLong() only exists in compilers that can do 64 bit builds */
1774-
# define HandleToLong(h) ((long)(h))
1772+
# if !defined(_MSC_VER) || (_MSC_VER < 1400)
1773+
/* Define HandleToLong for old MS and non-MS compilers if not defined. */
1774+
# ifndef HandleToLong
1775+
# define HandleToLong(h) ((long)(h))
1776+
# endif
17751777
# endif
17761778
/* set the v:windowid variable */
17771779
set_vim_var_nr(VV_WINDOWID, HandleToLong(s_hwnd));

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -741,6 +741,8 @@ static char *(features[]) =
741741

742742
static int included_patches[] =
743743
{ /* Add new patch number below this line */
744+
/**/
745+
1080,
744746
/**/
745747
1079,
746748
/**/

0 commit comments

Comments
 (0)