# HG changeset patch # User Bram Moolenaar # Date 1621338303 -7200 # Node ID 0ef7bb28f2c321e72e43de61d8cb08c3e1f82185 # Parent 9cf4f1cd73e30296537d4ee2210f9fdafac4275c patch 8.2.2865: skipping over function body fails Commit: https://github.com/vim/vim/commit/d87c21a918d8d611750f22d68fc638bf7a79b1d5 Author: Bram Moolenaar Date: Tue May 18 13:40:33 2021 +0200 patch 8.2.2865: skipping over function body fails Problem: Skipping over function body fails. Solution: Do not define the function when skipping. diff --git a/src/userfunc.c b/src/userfunc.c --- a/src/userfunc.c +++ b/src/userfunc.c @@ -4014,7 +4014,10 @@ define_function(exarg_T *eap, char_u *na // Save the starting line number. sourcing_lnum_top = SOURCING_LNUM; - if (get_function_body(eap, &newlines, line_arg, &line_to_free) == FAIL) + // Do not define the function when getting the body fails and when + // skipping. + if (get_function_body(eap, &newlines, line_arg, &line_to_free) == FAIL + || eap->skip) goto erret; /* diff --git a/src/version.c b/src/version.c --- a/src/version.c +++ b/src/version.c @@ -751,6 +751,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 2865, +/**/ 2864, /**/ 2863,