Patch 7.4.2029
Problem: printf() does not work with 64 bit numbers.
Solution: use the "L" length modifier. (Ken Takata)
Files: src/message.c, src/testdir/test_expr.vim
*** ../vim-7.4.2028/src/message.c 2016-07-09 17:05:49.207222368 +0200
--- src/message.c 2016-07-12 20:43:52.719215878 +0200
***************
*** 4198,4203 ****
--- 4198,4212 ----
default: break;
}
+ # if defined(FEAT_EVAL) && defined(FEAT_NUM64)
+ switch (fmt_spec)
+ {
+ case 'd': case 'u': case 'o': case 'x': case 'X':
+ if (tvs != NULL && length_modifier == '\0')
+ length_modifier = 'L';
+ }
+ # endif
+
/* get parameter value, do initial processing */
switch (fmt_spec)
{
*** ../vim-7.4.2028/src/testdir/test_expr.vim 2016-07-01 23:13:57.384275299
+0200
--- src/testdir/test_expr.vim 2016-07-12 21:10:17.892243082 +0200
***************
*** 129,131 ****
--- 129,137 ----
call assert_equal("abcdefgi", &cpo)
set cpo&vim
endfunc
+
+ function Test_printf_64bit()
+ if has('num64')
+ call assert_equal("123456789012345", printf('%d', 123456789012345))
+ endif
+ endfunc
*** ../vim-7.4.2028/src/version.c 2016-07-11 23:19:01.518779538 +0200
--- src/version.c 2016-07-12 21:11:08.919508500 +0200
***************
*** 760,761 ****
--- 760,763 ----
{ /* Add new patch number below this line */
+ /**/
+ 2029,
/**/
--
The software said it requires Windows 95 or better, so I installed Linux.
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.