mirror of
https://github.com/zsh-users/zsh-syntax-highlighting.git
synced 2025-12-04 21:56:45 +01:00
brackets: Use idiomatic set check
This commit is contained in:
parent
9dcfacc4a5
commit
1f77ed8369
1 changed files with 1 additions and 1 deletions
|
|
@ -91,7 +91,7 @@ _zsh_highlight_highlighter_brackets_paint()
|
|||
# If cursor is on a bracket, then highlight corresponding bracket, if any.
|
||||
if [[ $WIDGET != zle-line-finish ]]; then
|
||||
pos=$((CURSOR + 1))
|
||||
if [[ -n $levelpos[$pos] ]] && [[ -n $matching[$pos] ]]; then
|
||||
if (( $+levelpos[$pos] )) && (( $+matching[$pos] )); then
|
||||
local -i otherpos=$matching[$pos]
|
||||
_zsh_highlight_add_highlight $((otherpos - 1)) $otherpos cursor-matchingbracket
|
||||
fi
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue