• R/O
  • SSH

vim: Commit

Mirror of the Vim source from https://github.com/vim/vim


Commit MetaInfo

Revision609b351cb58fd13301c1280657106dd673decf51 (tree)
Time2019-09-16 04:15:04
AuthorBram Moolenaar <Bram@vim....>
CommiterBram Moolenaar

Log Message

patch 8.1.2043: not sufficient testing for quoted numbers

Commit: https://github.com/vim/vim/commit/ea8dcf8346f488786023fd03ec1c013cda243040
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Sep 15 21:12:22 2019 +0200

patch 8.1.2043: not sufficient testing for quoted numbers
Problem: Not sufficient testing for quoted numbers.
Solution: Add a few more test cases.

Change Summary

Incremental Difference

diff -r a9cfacd90bc1 -r 609b351cb58f src/testdir/test_eval_stuff.vim
--- a/src/testdir/test_eval_stuff.vim Sun Sep 15 21:15:03 2019 +0200
+++ b/src/testdir/test_eval_stuff.vim Sun Sep 15 21:15:04 2019 +0200
@@ -200,6 +200,9 @@
200200 call assert_equal(64, 0b1'00'00'00)
201201 call assert_equal(1048576, 0x10'00'00)
202202 call assert_equal(1000000, 1'000'000)
203+ call assert_equal("1234", execute("echo 1'234")->trim())
204+ call assert_equal('1 234', execute("echo 1''234")->trim())
205+ call assert_fails("echo 1'''234", 'E115:')
203206 endfunc
204207
205208 scriptversion 1
diff -r a9cfacd90bc1 -r 609b351cb58f src/testdir/test_functions.vim
--- a/src/testdir/test_functions.vim Sun Sep 15 21:15:03 2019 +0200
+++ b/src/testdir/test_functions.vim Sun Sep 15 21:15:04 2019 +0200
@@ -161,6 +161,7 @@
161161 call assert_equal(256, str2nr("1'0000'0000", 2, 1))
162162 call assert_equal(262144, str2nr("1'000'000", 8, 1))
163163 call assert_equal(1000000, str2nr("1'000'000", 10, 1))
164+ call assert_equal(1000, str2nr("1'000''000", 10, 1))
164165 call assert_equal(65536, str2nr("1'00'00", 16, 1))
165166
166167 call assert_equal(0, str2nr('0x10'))
diff -r a9cfacd90bc1 -r 609b351cb58f src/version.c
--- a/src/version.c Sun Sep 15 21:15:03 2019 +0200
+++ b/src/version.c Sun Sep 15 21:15:04 2019 +0200
@@ -758,6 +758,8 @@
758758 static int included_patches[] =
759759 { /* Add new patch number below this line */
760760 /**/
761+ 2043,
762+/**/
761763 2042,
762764 /**/
763765 2041,
Show on old repository browser