comparison runtime/doc/eval.txt @ 2152:b9e314fe473f

Updated runtime files.
author Bram Moolenaar <bram@zimbu.org>
date Fri, 14 May 2010 23:24:24 +0200
parents f63ace015c63
children 7c8c7c95a865
comparison
equal deleted inserted replaced
2151:ae22c450546c 2152:b9e314fe473f
1 *eval.txt* For Vim version 7.2. Last change: 2010 Mar 10 1 *eval.txt* For Vim version 7.2. Last change: 2010 May 14
2 2
3 3
4 VIM REFERENCE MANUAL by Bram Moolenaar 4 VIM REFERENCE MANUAL by Bram Moolenaar
5 5
6 6
65 Conversion from a Number to a String is by making the ASCII representation of 65 Conversion from a Number to a String is by making the ASCII representation of
66 the Number. Examples: > 66 the Number. Examples: >
67 Number 123 --> String "123" 67 Number 123 --> String "123"
68 Number 0 --> String "0" 68 Number 0 --> String "0"
69 Number -1 --> String "-1" 69 Number -1 --> String "-1"
70 70 *octal*
71 Conversion from a String to a Number is done by converting the first digits 71 Conversion from a String to a Number is done by converting the first digits
72 to a number. Hexadecimal "0xf9" and Octal "017" numbers are recognized. If 72 to a number. Hexadecimal "0xf9" and Octal "017" numbers are recognized. If
73 the String doesn't start with digits, the result is zero. Examples: > 73 the String doesn't start with digits, the result is zero. Examples: >
74 String "456" --> Number 456 74 String "456" --> Number 456
75 String "6bar" --> Number 6 75 String "6bar" --> Number 6
1018 \n newline <NL> 1018 \n newline <NL>
1019 \r return <CR> 1019 \r return <CR>
1020 \t tab <Tab> 1020 \t tab <Tab>
1021 \\ backslash 1021 \\ backslash
1022 \" double quote 1022 \" double quote
1023 \<xxx> Special key named "xxx". e.g. "\<C-W>" for CTRL-W. 1023 \<xxx> Special key named "xxx". e.g. "\<C-W>" for CTRL-W. This is for use
1024 in mappings, the 0x80 byte is escaped. Don't use <Char-xxxx> to get a
1025 utf-8 character, use \uxxxx as mentioned above.
1024 1026
1025 Note that "\xff" is stored as the byte 255, which may be invalid in some 1027 Note that "\xff" is stored as the byte 255, which may be invalid in some
1026 encodings. Use "\u00ff" to store character 255 according to the current value 1028 encodings. Use "\u00ff" to store character 255 according to the current value
1027 of 'encoding'. 1029 of 'encoding'.
1028 1030
4942 If the "filename" and "bufnr" entries are not present or 4944 If the "filename" and "bufnr" entries are not present or
4943 neither the "lnum" or "pattern" entries are present, then the 4945 neither the "lnum" or "pattern" entries are present, then the
4944 item will not be handled as an error line. 4946 item will not be handled as an error line.
4945 If both "pattern" and "lnum" are present then "pattern" will 4947 If both "pattern" and "lnum" are present then "pattern" will
4946 be used. 4948 be used.
4949 If you supply an empty {list}, the quickfix list will be
4950 cleared.
4947 Note that the list is not exactly the same as what 4951 Note that the list is not exactly the same as what
4948 |getqflist()| returns. 4952 |getqflist()| returns.
4949 4953
4950 If {action} is set to 'a', then the items from {list} are 4954 If {action} is set to 'a', then the items from {list} are
4951 added to the existing quickfix list. If there is no existing 4955 added to the existing quickfix list. If there is no existing
6826 And to get a beep: > 6830 And to get a beep: >
6827 :exe "normal \<Esc>" 6831 :exe "normal \<Esc>"
6828 < 6832 <
6829 *:exe* *:execute* 6833 *:exe* *:execute*
6830 :exe[cute] {expr1} .. Executes the string that results from the evaluation 6834 :exe[cute] {expr1} .. Executes the string that results from the evaluation
6831 of {expr1} as an Ex command. Multiple arguments are 6835 of {expr1} as an Ex command.
6832 concatenated, with a space in between. {expr1} is 6836 Multiple arguments are concatenated, with a space in
6833 used as the processed command, command line editing 6837 between. To avoid the extra space use the "."
6834 keys are not recognized. 6838 operator to concatenate strings into one argument.
6839 {expr1} is used as the processed command, command line
6840 editing keys are not recognized.
6835 Cannot be followed by a comment. 6841 Cannot be followed by a comment.
6836 Examples: > 6842 Examples: >
6837 :execute "buffer " nextbuf 6843 :execute "buffer" nextbuf
6838 :execute "normal " count . "w" 6844 :execute "normal" count . "w"
6839 < 6845 <
6840 ":execute" can be used to append a command to commands 6846 ":execute" can be used to append a command to commands
6841 that don't accept a '|'. Example: > 6847 that don't accept a '|'. Example: >
6842 :execute '!ls' | echo "theend" 6848 :execute '!ls' | echo "theend"
6843 6849