mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
eval: ll_range,ll_empty2 members are bool
This commit is contained in:
parent
bea99729dd
commit
f9c0af0180
@ -2121,9 +2121,10 @@ char_u *get_lval(char_u *const name, typval_T *const rettv,
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
lp->ll_range = TRUE;
|
lp->ll_range = true;
|
||||||
} else
|
} else {
|
||||||
lp->ll_range = FALSE;
|
lp->ll_range = false;
|
||||||
|
}
|
||||||
|
|
||||||
if (*p != ']') {
|
if (*p != ']') {
|
||||||
if (!quiet) {
|
if (!quiet) {
|
||||||
@ -2240,12 +2241,10 @@ char_u *get_lval(char_u *const name, typval_T *const rettv,
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
// May need to find the item or absolute index for the second
|
||||||
* May need to find the item or absolute index for the second
|
// index of a range.
|
||||||
* index of a range.
|
// When no index given: "lp->ll_empty2" is true.
|
||||||
* When no index given: "lp->ll_empty2" is TRUE.
|
// Otherwise "lp->ll_n2" is set to the second index.
|
||||||
* Otherwise "lp->ll_n2" is set to the second index.
|
|
||||||
*/
|
|
||||||
if (lp->ll_range && !lp->ll_empty2) {
|
if (lp->ll_range && !lp->ll_empty2) {
|
||||||
lp->ll_n2 = (long)tv_get_number(&var2); // Is number or string.
|
lp->ll_n2 = (long)tv_get_number(&var2); // Is number or string.
|
||||||
tv_clear(&var2);
|
tv_clear(&var2);
|
||||||
|
@ -56,8 +56,8 @@ typedef struct lval_S {
|
|||||||
///< isn't NULL it's the Dict to which to add the item.
|
///< isn't NULL it's the Dict to which to add the item.
|
||||||
listitem_T *ll_li; ///< The list item or NULL.
|
listitem_T *ll_li; ///< The list item or NULL.
|
||||||
list_T *ll_list; ///< The list or NULL.
|
list_T *ll_list; ///< The list or NULL.
|
||||||
int ll_range; ///< TRUE when a [i:j] range was used.
|
bool ll_range; ///< true when a [i:j] range was used.
|
||||||
int ll_empty2; ///< Second index is empty: [i:].
|
bool ll_empty2; ///< Second index is empty: [i:].
|
||||||
long ll_n1; ///< First index for list.
|
long ll_n1; ///< First index for list.
|
||||||
long ll_n2; ///< Second index for list range.
|
long ll_n2; ///< Second index for list range.
|
||||||
dict_T *ll_dict; ///< The Dictionary or NULL.
|
dict_T *ll_dict; ///< The Dictionary or NULL.
|
||||||
|
Loading…
Reference in New Issue
Block a user