(response: DebugProtocol.StackTraceResponse, args: DebugProtocol.StackTraceArguments)
| 285 | } |
| 286 | |
| 287 | protected stackTraceRequest(response: DebugProtocol.StackTraceResponse, args: DebugProtocol.StackTraceArguments): void { |
| 288 | this.miDebugger.getStack(args.startFrame, args.levels, args.threadId).then(stack => { |
| 289 | const ret: StackFrame[] = []; |
| 290 | stack.forEach(element => { |
| 291 | let source = undefined; |
| 292 | let path = element.file; |
| 293 | if (path) { |
| 294 | if (this.isSSH) { |
| 295 | // convert ssh path to local path |
| 296 | path = this.sourceFileMap.toLocalPath(path); |
| 297 | } else if (process.platform === "win32") { |
| 298 | if (path.startsWith("\\cygdrive\\") || path.startsWith("/cygdrive/")) { |
| 299 | path = path[10] + ":" + path.substring(11); // replaces /cygdrive/c/foo/bar.txt with c:/foo/bar.txt |
| 300 | } |
| 301 | } |
| 302 | source = new Source(element.fileName, path); |
| 303 | } |
| 304 | |
| 305 | ret.push(new StackFrame( |
| 306 | this.threadAndLevelToFrameId(args.threadId, element.level), |
| 307 | element.function + "@" + element.address, |
| 308 | source, |
| 309 | element.line, |
| 310 | 0)); |
| 311 | }); |
| 312 | response.body = { |
| 313 | stackFrames: ret |
| 314 | }; |
| 315 | this.sendResponse(response); |
| 316 | }, err => { |
| 317 | this.sendErrorResponse(response, 12, `Failed to get Stack Trace: ${err.toString()}`); |
| 318 | }); |
| 319 | } |
| 320 | |
| 321 | protected configurationDoneRequest(response: DebugProtocol.ConfigurationDoneResponse, args: DebugProtocol.ConfigurationDoneArguments): void { |
| 322 | const promises: Thenable<any>[] = []; |
nothing calls this directly
no test coverage detected