comparison src/evalfunc.c @ 20665:6ff992bf4c82 v8.2.0886

patch 8.2.0886: cannot use octal numbers in scriptversion 4 Commit: https://github.com/vim/vim/commit/c17e66c5c0acd5038f1eb3d7b3049b64bb6ea30b Author: Bram Moolenaar <Bram@vim.org> Date: Tue Jun 2 21:38:22 2020 +0200 patch 8.2.0886: cannot use octal numbers in scriptversion 4 Problem: Cannot use octal numbers in scriptversion 4. Solution: Add the "0o" notation. (Ken Takata, closes https://github.com/vim/vim/issues/5304)
author Bram Moolenaar <Bram@vim.org>
date Tue, 02 Jun 2020 21:45:03 +0200
parents 1fa0ace0ba65
children 1af1d8ff2aa8
comparison
equal deleted inserted replaced
20664:2ee305469487 20665:6ff992bf4c82
7735 if (*p == '+' || *p == '-') 7735 if (*p == '+' || *p == '-')
7736 p = skipwhite(p + 1); 7736 p = skipwhite(p + 1);
7737 switch (base) 7737 switch (base)
7738 { 7738 {
7739 case 2: what |= STR2NR_BIN + STR2NR_FORCE; break; 7739 case 2: what |= STR2NR_BIN + STR2NR_FORCE; break;
7740 case 8: what |= STR2NR_OCT + STR2NR_FORCE; break; 7740 case 8: what |= STR2NR_OCT + STR2NR_OOCT + STR2NR_FORCE; break;
7741 case 16: what |= STR2NR_HEX + STR2NR_FORCE; break; 7741 case 16: what |= STR2NR_HEX + STR2NR_FORCE; break;
7742 } 7742 }
7743 vim_str2nr(p, NULL, NULL, what, &n, NULL, 0, FALSE); 7743 vim_str2nr(p, NULL, NULL, what, &n, NULL, 0, FALSE);
7744 // Text after the number is silently ignored. 7744 // Text after the number is silently ignored.
7745 if (isneg) 7745 if (isneg)