|
1 | | -*eval.txt* For Vim version 7.4. Last change: 2016 Jan 16 |
| 1 | +*eval.txt* For Vim version 7.4. Last change: 2016 Jan 17 |
2 | 2 |
|
3 | 3 |
|
4 | 4 | VIM REFERENCE MANUAL by Bram Moolenaar |
@@ -1950,6 +1950,7 @@ nextnonblank( {lnum}) Number line nr of non-blank line >= {lnum} |
1950 | 1950 | nr2char( {expr}[, {utf8}]) String single char with ASCII/UTF8 value {expr} |
1951 | 1951 | or( {expr}, {expr}) Number bitwise OR |
1952 | 1952 | pathshorten( {expr}) String shorten directory names in a path |
| 1953 | +perleval( {expr}) any evaluate |Perl| expression |
1953 | 1954 | pow( {x}, {y}) Float {x} to the power of {y} |
1954 | 1955 | prevnonblank( {lnum}) Number line nr of non-blank line <= {lnum} |
1955 | 1956 | printf( {fmt}, {expr1}...) String format text |
@@ -4778,6 +4779,17 @@ pathshorten({expr}) *pathshorten()* |
4778 | 4779 | < ~/.v/a/myfile.vim ~ |
4779 | 4780 | It doesn't matter if the path exists or not. |
4780 | 4781 |
|
| 4782 | +perleval({expr}) *perleval()* |
| 4783 | + Evaluate Perl expression {expr} in scalar context and return |
| 4784 | + its result converted to Vim data structures. If value can't be |
| 4785 | + converted, it returned as string Perl representation. |
| 4786 | + Note: If you want a array or hash, {expr} must returns an |
| 4787 | + reference of it. |
| 4788 | + Example: > |
| 4789 | + :echo perleval('[1 .. 4]') |
| 4790 | +< [1, 2, 3, 4] |
| 4791 | + {only available when compiled with the |+perl| feature} |
| 4792 | + |
4781 | 4793 | pow({x}, {y}) *pow()* |
4782 | 4794 | Return the power of {x} to the exponent {y} as a |Float|. |
4783 | 4795 | {x} and {y} must evaluate to a |Float| or a |Number|. |
|
0 commit comments