comparison src/evalvars.c @ 22409:5736172d64a6 v8.2.1753

patch 8.2.1753: Vim9: crash when using import at script level Commit: https://github.com/vim/vim/commit/f6a44f714a383a69db05cb47e26abffd966cd6a5 Author: Bram Moolenaar <Bram@vim.org> Date: Sun Sep 27 13:51:14 2020 +0200 patch 8.2.1753: Vim9: crash when using import at script level Problem: Vim9: crash when using import at script level. Solution: Give a "not implemented yet" error. (closes https://github.com/vim/vim/issues/7026)
author Bram Moolenaar <Bram@vim.org>
date Sun, 27 Sep 2020 14:00:04 +0200
parents a9fb7efa31d6
children 66d1131a7eff
comparison
equal deleted inserted replaced
22408:001318b6f357 22409:5736172d64a6
2484 { 2484 {
2485 rettv->v_type = VAR_FUNC; 2485 rettv->v_type = VAR_FUNC;
2486 rettv->vval.v_string = vim_strsave(import->imp_funcname); 2486 rettv->vval.v_string = vim_strsave(import->imp_funcname);
2487 } 2487 }
2488 } 2488 }
2489 else if (import->imp_all)
2490 {
2491 emsg("Sorry, 'import * as X' not implemented yet");
2492 ret = FAIL;
2493 }
2489 else 2494 else
2490 { 2495 {
2491 scriptitem_T *si = SCRIPT_ITEM(import->imp_sid); 2496 scriptitem_T *si = SCRIPT_ITEM(import->imp_sid);
2492 svar_T *sv = ((svar_T *)si->sn_var_vals.ga_data) 2497 svar_T *sv = ((svar_T *)si->sn_var_vals.ga_data)
2493 + import->imp_var_vals_idx; 2498 + import->imp_var_vals_idx;