patch 8.2.1613: Vim9: cannot pass "true" to prop_type_add()
Problem: Vim9: cannot pass "true" to prop_type_add().
Solution: Use tv_get_bool(). (closes #6850)
diff --git a/src/textprop.c b/src/textprop.c
index c291a29..639c5df 100644
--- a/src/textprop.c
+++ b/src/textprop.c
@@ -1007,7 +1007,7 @@
di = dict_find(dict, (char_u *)"combine", -1);
if (di != NULL)
{
- if (tv_get_number(&di->di_tv))
+ if (tv_get_bool(&di->di_tv))
prop->pt_flags |= PT_FLAG_COMBINE;
else
prop->pt_flags &= ~PT_FLAG_COMBINE;
@@ -1020,7 +1020,7 @@
di = dict_find(dict, (char_u *)"start_incl", -1);
if (di != NULL)
{
- if (tv_get_number(&di->di_tv))
+ if (tv_get_bool(&di->di_tv))
prop->pt_flags |= PT_FLAG_INS_START_INCL;
else
prop->pt_flags &= ~PT_FLAG_INS_START_INCL;
@@ -1029,7 +1029,7 @@
di = dict_find(dict, (char_u *)"end_incl", -1);
if (di != NULL)
{
- if (tv_get_number(&di->di_tv))
+ if (tv_get_bool(&di->di_tv))
prop->pt_flags |= PT_FLAG_INS_END_INCL;
else
prop->pt_flags &= ~PT_FLAG_INS_END_INCL;