Merge pull request #63 from IngoHeimbach/fix/cwd-dependency

Transform filenames to absolute paths when reading debugger locations
This commit is contained in:
Idan Arye 2018-06-25 17:52:05 +03:00 committed by GitHub
commit 15addb7427
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 4 additions and 4 deletions

View File

@ -128,7 +128,7 @@ function! vebugger#gdb#_readWhere(pipeName,line,readResult,debugger)
let l:matches=matchlist(a:line,'\v^\*stopped.*fullname\=\"([^"]+)\",line\=\"(\d+)"')
if 2<len(l:matches)
let l:file=l:matches[1]
let l:file=fnamemodify(l:file,':~:.')
let l:file=fnamemodify(l:file,':p')
let a:readResult.std.location={
\'file':(l:file),
\'line':str2nr(l:matches[2])}

View File

@ -116,7 +116,7 @@ function! vebugger#jdb#_readWhere(pipeName,line,readResult,debugger)
if 4<len(l:matches)
let l:frameNumber=str2nr(l:matches[1])
let l:file=s:findFolderFromStackTrace(a:debugger.state.jdb.srcpath,l:matches[2],l:frameNumber).'/'.l:matches[3]
let l:file=fnamemodify(l:file,':~:.')
let l:file=fnamemodify(l:file,':p')
if 1==l:frameNumber " first stackframe is the current location
let a:readResult.std.location={
\'file':(l:file),

View File

@ -60,7 +60,7 @@ function! vebugger#lldb#_readWhere(pipeName,line,readResult,debugger)
let l:matches=matchlist(a:line,'\v^where:\s([^:]+):(\d+)')
if 2<len(l:matches)
let l:file=l:matches[1]
let l:file=fnamemodify(l:file,':~:.')
let l:file=fnamemodify(l:file,':p')
let a:readResult.std.location={
\'file':(l:file),
\'line':str2nr(l:matches[2])}

View File

@ -95,7 +95,7 @@ function! vebugger#mdbg#_readWhere(pipeName,line,readResult,debugger)
if 3<len(l:matches)
let l:frameNumber=str2nr(l:matches[1])
let l:file=s:findFilePath(a:debugger.state.mdbg.srcpath,l:matches[3],l:matches[2])
let l:file=fnamemodify(l:file,':~:.')
let l:file=fnamemodify(l:file,':p')
if 0==l:frameNumber " first stackframe is the current location
let a:readResult.std.location={
\'file':(l:file),