Mercurial > vim
comparison runtime/doc/usr_41.txt @ 23573:e2e2cc5d0856
Update runtime files.
Commit: https://github.com/vim/vim/commit/82be4849eed0b8fbee45bc8da99b685ec89af59a
Author: Bram Moolenaar <Bram@vim.org>
Date: Mon Jan 11 19:40:15 2021 +0100
Update runtime files.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Mon, 11 Jan 2021 19:45:05 +0100 |
parents | 87671ccc6c6b |
children | 510088f8c66f |
comparison
equal
deleted
inserted
replaced
23572:b35e568d74e6 | 23573:e2e2cc5d0856 |
---|---|
1 *usr_41.txt* For Vim version 8.2. Last change: 2020 Dec 19 | 1 *usr_41.txt* For Vim version 8.2. Last change: 2021 Jan 08 |
2 | 2 |
3 VIM USER MANUAL - by Bram Moolenaar | 3 VIM USER MANUAL - by Bram Moolenaar |
4 | 4 |
5 Write a Vim script | 5 Write a Vim script |
6 | 6 |
120 starts with a zero. "017" is decimal 15. A binary number starts with "0b" or | 120 starts with a zero. "017" is decimal 15. A binary number starts with "0b" or |
121 "0B". For example "0b101" is decimal 5. Careful: don't put a zero before a | 121 "0B". For example "0b101" is decimal 5. Careful: don't put a zero before a |
122 decimal number, it will be interpreted as an octal number! | 122 decimal number, it will be interpreted as an octal number! |
123 The ":echo" command always prints decimal numbers. Example: > | 123 The ":echo" command always prints decimal numbers. Example: > |
124 | 124 |
125 :echo 0x7f 036 | 125 :echo 0x7f 0o36 |
126 < 127 30 ~ | 126 < 127 30 ~ |
127 | 127 |
128 A number is made negative with a minus sign. This also works for hexadecimal, | 128 A number is made negative with a minus sign. This also works for hexadecimal, |
129 octal and binary numbers. A minus sign is also used for subtraction. Compare | 129 octal and binary numbers. A minus sign is also used for subtraction. Compare |
130 this with the previous example: > | 130 this with the previous example: > |
131 | 131 |
132 :echo 0x7f -036 | 132 :echo 0x7f -0o36 |
133 < 97 ~ | 133 < 97 ~ |
134 | 134 |
135 White space in an expression is ignored. However, it's recommended to use it | 135 White space in an expression is ignored. However, it's recommended to use it |
136 for separating items, to make the expression easier to read. For example, to | 136 for separating items, to make the expression easier to read. For example, to |
137 avoid the confusion with a negative number above, put a space between the | 137 avoid the confusion with a negative number above, put a space between the |
138 minus sign and the following number: > | 138 minus sign and the following number: > |
139 | 139 |
140 :echo 0x7f - 036 | 140 :echo 0x7f - 0o36 |
141 | 141 |
142 ============================================================================== | 142 ============================================================================== |
143 *41.2* Variables | 143 *41.2* Variables |
144 | 144 |
145 A variable name consists of ASCII letters, digits and the underscore. It | 145 A variable name consists of ASCII letters, digits and the underscore. It |