1
0
forked from aniani/vim

patch 8.2.4669: in compiled code len('string') is not inlined

Problem:    In compiled code len('string') is not inlined.
Solution:   Compute the length at compile time if possible. (closes #10065)
This commit is contained in:
LemonBoy
2022-04-02 21:59:06 +01:00
committed by Bram Moolenaar
parent 0dac1ab579
commit 58f331a05f
5 changed files with 23 additions and 5 deletions

View File

@@ -90,7 +90,6 @@ static void f_interrupt(typval_T *argvars, typval_T *rettv);
static void f_invert(typval_T *argvars, typval_T *rettv);
static void f_islocked(typval_T *argvars, typval_T *rettv);
static void f_last_buffer_nr(typval_T *argvars, typval_T *rettv);
static void f_len(typval_T *argvars, typval_T *rettv);
static void f_libcall(typval_T *argvars, typval_T *rettv);
static void f_libcallnr(typval_T *argvars, typval_T *rettv);
static void f_line(typval_T *argvars, typval_T *rettv);
@@ -7019,7 +7018,7 @@ f_last_buffer_nr(typval_T *argvars UNUSED, typval_T *rettv)
/*
* "len()" function
*/
static void
void
f_len(typval_T *argvars, typval_T *rettv)
{
switch (argvars[0].v_type)