view src/typemap @ 16028:8ad2cda3757d v8.1.1019

patch 8.1.1019: Lua: may garbage collect function reference in use commit https://github.com/vim/vim/commit/4eefe47ea4b6bf958617e924f52bc7a409cfb0ed Author: Bram Moolenaar <Bram@vim.org> Date: Tue Mar 19 21:59:19 2019 +0100 patch 8.1.1019: Lua: may garbage collect function reference in use Problem: Lua: may garbage collect function reference in use. Solution: Keep the function name instead of the typeval. Make luaV_setref() handle funcref objects. (Ozaki Kiichi, closes #4127)
author Bram Moolenaar <Bram@vim.org>
date Tue, 19 Mar 2019 22:00:07 +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}\")