I have a question about this code in DoGrep().
It masks almost all exceptions and makes it look like the search found nothing.
Was this the intent? It makes it very hard to spot problems that manifest as exceptions.
My guess is that the intent was to say something like if v:exception == 'E480'
catch
if v:exception != 'E480'
call s:WarnNoMatches(a:pattern)
try
" go to the last error list on no matches
if g:EasyGrepWindow == 0
silent colder
else
silent lolder
endif
catch
endtry
else
call EasyGrep#Error("FIXME: exception not caught ".v:exception)
endif
let failed = 1
endtry
I don't really remember what the intent was there -- I'm guessing I just implemented a WAR (poorly) for an issue I was seeing at the time. Your fix is more robust than the previous code.
I have a question about this code in DoGrep(). It masks almost all exceptions and makes it look like the search found nothing. Was this the intent? It makes it very hard to spot problems that manifest as exceptions. My guess is that the intent was to say something like
if v:exception == 'E480'