diff --git a/src/version.c b/src/version.c index 3686a1d51b..de0565a80f 100644 --- a/src/version.c +++ b/src/version.c @@ -738,6 +738,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 494, /**/ 493, /**/ diff --git a/src/vim9compile.c b/src/vim9compile.c index ce1ca76c24..92d1362797 100644 --- a/src/vim9compile.c +++ b/src/vim9compile.c @@ -3767,7 +3767,8 @@ compile_assignment(char_u *arg, exarg_T *eap, cmdidx_T cmdidx, cctx_T *cctx) goto theend; stack = &cctx->ctx_type_stack; - stacktype = ((type_T **)stack->ga_data)[stack->ga_len - 1]; + stacktype = stack->ga_len == 0 ? &t_void + : ((type_T **)stack->ga_data)[stack->ga_len - 1]; if (idx >= 0 && (is_decl || !has_type)) { lvar = ((lvar_T *)cctx->ctx_locals.ga_data) + idx;