]> granicus.if.org Git - vim/commitdiff
updated for version 7.4.237 v7.4.237
authorBram Moolenaar <Bram@vim.org>
Wed, 2 Apr 2014 10:12:08 +0000 (12:12 +0200)
committerBram Moolenaar <Bram@vim.org>
Wed, 2 Apr 2014 10:12:08 +0000 (12:12 +0200)
Problem:    When some patches was not included has("patch-7.4.123") may return
            true falsely.
Solution:   Check for the specific patch number.

runtime/doc/eval.txt
src/eval.c
src/version.c

index 66b3038e26f52b514c96cc3f47d7ccf88487cebd..007c7f7469262e4e58c2b9a64e81625d889f1d2e 100644 (file)
@@ -1682,7 +1682,7 @@ v:version Version number of Vim: Major version number times 100 plus
                is 501.  Read-only.  "version" also works, for backwards
                compatibility.
                Use |has()| to check if a certain patch was included, e.g.: >
-                       if has("patch123")
+                       if has("patch-7.4.123")
 <              Note that patch numbers are specific to the version, thus both
                version 5.0 and 5.1 may have a patch 123, but these are
                completely different.
index 042afca3695e696940d868fa1e9390b7f622879a..05f91b303e3584ff21d2f9d7907fbe60597ed794 100644 (file)
@@ -12647,14 +12647,13 @@ f_has(argvars, rettv)
            {
                int major = atoi((char *)name + 6);
                int minor = atoi((char *)name + 8);
-               int patch = atoi((char *)name + 10);
 
                /* Expect "patch-9.9.01234". */
                n = (major < VIM_VERSION_MAJOR
                     || (major == VIM_VERSION_MAJOR
                         && (minor < VIM_VERSION_MINOR
                             || (minor == VIM_VERSION_MINOR
-                                && patch <= highest_patch()))));
+                                && has_patch(atoi((char *)name + 10))))));
            }
            else
                n = has_patch(atoi((char *)name + 5));
index 6b63fbc5a657fcc8af05184c3503a552eb59d7af..7d3bde9ce4a91ccc7c2a823a4544494ee870970f 100644 (file)
@@ -734,6 +734,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    237,
 /**/
     236,
 /**/