Problem: Crash after using "g:" in a for loop.
Solution: Increment the reference count. (closes #7892)
assert_equal('some', get(t:, 'some_var', 'xxx'))
assert_equal('xxx', get(t:, 'no_var', 'xxx'))
unlet t:some_var
+
+ # check using g: in a for loop more than DO_NOT_FREE_CNT times
+ for i in range(100000)
+ if has_key(g:, 'does-not-exist')
+ endif
+ endfor
enddef
def Test_expr7_parens()
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 2549,
/**/
2548,
/**/
tv->v_type = VAR_DICT;
tv->v_lock = 0;
tv->vval.v_dict = d;
+ ++d->dv_refcount;
++ectx.ec_stack.ga_len;
}
break;