Skip to content

Commit

Permalink
REFACT: Extract complex expression into variable
Browse files Browse the repository at this point in the history
  • Loading branch information
LucHermitte committed Aug 28, 2024
1 parent f0f27ab commit 6d1210a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions autoload/lh/marker.vim
Original file line number Diff line number Diff line change
Expand Up @@ -298,9 +298,9 @@ function! s:DoSelect(emo, emc, delete, position, mode) abort " {{{2
call search('\V'.substitute(a:emc, '.$', '\\zs\0', ''))
" call confirm(matchstr(getline('.'), se). "\n".se, "&Ok", 1 )
if s:Select_or_Echo() " select! {{{4
let is_not_empty = matchstr(getline('.'),'\V\%'.c.'c'.a:emo.'\zs\.\{-}\ze'.a:emc)!= ''
if !a:delete &&
\ (s:Select_Empty_Mark() ||
\ (matchstr(getline('.'),'\V\%'.c.'c'.a:emo.'\zs\.\{-}\ze'.a:emc)!= ''))
\ (s:Select_Empty_Mark() || is_not_empty)
" Case: Marker containing a tag, e.g.: «tag»
" Treatment: The marker is selected, going into SELECT-mode
return mode_prefix.select."\<c-g>"
Expand Down

0 comments on commit 6d1210a

Please sign in to comment.