diff options
-rw-r--r-- | src/memline.c | 17 | ||||
-rw-r--r-- | src/version.c | 2 |
2 files changed, 11 insertions, 8 deletions
diff --git a/src/memline.c b/src/memline.c index af3e2f443..0a947f927 100644 --- a/src/memline.c +++ b/src/memline.c @@ -3566,6 +3566,15 @@ adjust_text_props_for_delete( ml_delete(linenr_T lnum, int message) { ml_flush_line(curbuf); + if (lnum < 1 || lnum > curbuf->b_ml.ml_line_count) + return FAIL; + +#ifdef FEAT_EVAL + // When inserting above recorded changes: flush the changes before changing + // the text. + may_invoke_listeners(curbuf, lnum, lnum + 1, -1); +#endif + return ml_delete_int(curbuf, lnum, message); } @@ -3590,14 +3599,6 @@ ml_delete_int(buf_T *buf, linenr_T lnum, int message) int textprop_save_len; #endif - if (lnum < 1 || lnum > buf->b_ml.ml_line_count) - return FAIL; - -#ifdef FEAT_EVAL - // When inserting above recorded changes: flush the changes before changing - // the text. - may_invoke_listeners(buf, lnum, lnum + 1, -1); -#endif if (lowest_marked && lowest_marked > lnum) lowest_marked--; diff --git a/src/version.c b/src/version.c index 74a16fe36..6c6550b09 100644 --- a/src/version.c +++ b/src/version.c @@ -778,6 +778,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 1711, +/**/ 1710, /**/ 1709, |