From: Bram Moolenaar Date: Sun, 22 Mar 2020 19:13:39 +0000 (+0100) Subject: patch 8.2.0429: no warning when test checks for option that never exists X-Git-Tag: v8.2.0429 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=c5a8fdc42dbd304598b2d73db754c7b97665b182;p=vim patch 8.2.0429: no warning when test checks for option that never exists Problem: No warning when test checks for option that never exists. Solution: In tests check that the option can exist. --- diff --git a/src/testdir/check.vim b/src/testdir/check.vim index 0bbe7caf9..d01dd81dd 100644 --- a/src/testdir/check.vim +++ b/src/testdir/check.vim @@ -17,6 +17,9 @@ endfunc " Command to check for the presence of a working option. command -nargs=1 CheckOption call CheckOption() func CheckOption(name) + if !exists('&' .. a:name) + throw 'Checking for non-existent option ' .. a:name + endif if !exists('+' .. a:name) throw 'Skipped: ' .. a:name .. ' option not supported' endif diff --git a/src/version.c b/src/version.c index e27b77351..17918de3a 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 */ +/**/ + 429, /**/ 428, /**/