fix: vvlua_partial

This commit is contained in:
Jakub Łuczyński
2020-02-11 13:08:32 +01:00
parent 1e0a9b2690
commit 3c413f1523
2 changed files with 9 additions and 3 deletions

View File

@@ -8249,10 +8249,16 @@ static void check_vars(const char *name, size_t len)
}
}
/// check if special v:lua value for calling lua functions
bool is_luafunc(partial_T *partial)
{
return partial == vvlua_partial;
}
/// check if special v:lua value for calling lua functions
static bool tv_is_luafunc(typval_T *tv)
{
return tv->v_type == VAR_PARTIAL && tv->vval.v_partial == vvlua_partial;
return tv->v_type == VAR_PARTIAL && is_luafunc(tv->vval.v_partial);
}
/// check the function name after "v:lua."