Adding support for srcpath as string or list
This commit is contained in:
parent
4230773e7e
commit
5865e3b28e
@ -87,7 +87,7 @@ function! s:findFolderFromStackTrace(src,nameFromStackTrace,frameNumber)
|
||||
endif
|
||||
|
||||
" If no such tag was found, try to find it using the src path.
|
||||
for l:one_path in split(a:src, ':')
|
||||
for l:one_path in vebugger#util#listify(a:src)
|
||||
let l:path=l:one_path
|
||||
for l:dirname in split(a:nameFromStackTrace,'\.')
|
||||
let l:nextPath=l:path.'/'.fnameescape(l:dirname)
|
||||
|
@ -115,3 +115,12 @@ function! vebugger#util#isPathAbsolute(path)
|
||||
return a:path[0]=~'\v^[/~$]' "Absolute paths in Linux start with ~(home),/(root dir) or $(environment variable)
|
||||
endif
|
||||
endfunction
|
||||
|
||||
function! vebugger#util#listify(stringOrList)
|
||||
if type(a:stringOrList) == type([])
|
||||
return copy(a:stringOrList) " so it could safely be modified by map&filter
|
||||
else
|
||||
return [a:stringOrList]
|
||||
endif
|
||||
endfunction
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user