# HG changeset patch # User Bram Moolenaar # Date 1582662604 -3600 # Node ID 020056c2fd39069b4254ab17ac2b273bce378e52 # Parent 25f44b7a51b19e7bff0898298f4526693ed55d36 patch 8.2.0315: build failure on HP-UX system Commit: https://github.com/vim/vim/commit/c593bec4120f122e8a9129ec461968f1bd214435 Author: Bram Moolenaar Date: Tue Feb 25 21:26:49 2020 +0100 patch 8.2.0315: build failure on HP-UX system Problem: Build failure on HP-UX system. Solution: Use LONG_LONG_MIN instead of LLONG_MIN. Add type casts for switch statement. (John Marriott) diff --git a/src/json.c b/src/json.c --- a/src/json.c +++ b/src/json.c @@ -194,7 +194,7 @@ json_encode_item(garray_T *gap, typval_T switch (val->v_type) { case VAR_BOOL: - switch (val->vval.v_number) + switch ((long)val->vval.v_number) { case VVAL_FALSE: ga_concat(gap, (char_u *)"false"); break; case VVAL_TRUE: ga_concat(gap, (char_u *)"true"); break; @@ -202,7 +202,7 @@ json_encode_item(garray_T *gap, typval_T break; case VAR_SPECIAL: - switch (val->vval.v_number) + switch ((long)val->vval.v_number) { case VVAL_NONE: if ((options & JSON_JS) != 0 && (options & JSON_NO_NONE) == 0) diff --git a/src/structs.h b/src/structs.h --- a/src/structs.h +++ b/src/structs.h @@ -1279,9 +1279,15 @@ typedef long_u hash_T; // Type for hi_h #else typedef long long varnumber_T; typedef unsigned long long uvarnumber_T; -# define VARNUM_MIN LLONG_MIN -# define VARNUM_MAX LLONG_MAX -# define UVARNUM_MAX ULLONG_MAX +# ifdef LLONG_MIN +# define VARNUM_MIN LLONG_MIN +# define VARNUM_MAX LLONG_MAX +# define UVARNUM_MAX ULLONG_MAX +# else +# define VARNUM_MIN LONG_LONG_MIN +# define VARNUM_MAX LONG_LONG_MAX +# define UVARNUM_MAX ULONG_LONG_MAX +# endif #endif typedef double float_T; diff --git a/src/version.c b/src/version.c --- a/src/version.c +++ b/src/version.c @@ -739,6 +739,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 315, +/**/ 314, /**/ 313,