Mercurial > vim
view src/typemap @ 23054:df0548b649c1 v8.2.2073
patch 8.2.2073: Vim9: for with unpack only works for local variables
Commit: https://github.com/vim/vim/commit/4b8a065145bb53762b869cd6b8e55b7ad7341761
Author: Bram Moolenaar <Bram@vim.org>
Date: Tue Dec 1 16:30:44 2020 +0100
patch 8.2.2073: Vim9: for with unpack only works for local variables
Problem: Vim9: for with unpack only works for local variables.
Solution: Recognize different destinations.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Tue, 01 Dec 2020 16:45:04 +0100 |
parents | dec4338a7da2 |
children |
line wrap: on
line source
TYPEMAP VIWIN T_VIOBJNOMUNGE VIBUF T_VIOBJNOMUNGE INPUT T_VIOBJNOMUNGE if (sv_isa($arg, \"${ntype}\")) { IV tmp = SvIV((SV*)SvRV($arg)); $var = INT2PTR($type, tmp); if (!tmp) croak(\"$ntype no longer exists\"); } else croak(\"$var is not of type ${ntype}\")