Skip to content

Commit 2a4dc99

Browse files
committed
Indicate actual line num. for breakpoint
1 parent d0a7956 commit 2a4dc99

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/backend/mi2/mi2.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -397,7 +397,7 @@ export class MI2 extends EventEmitter implements IBackend {
397397
}
398398
else if (parseInt(match) !== 0) {
399399
location += '-t -i ' + parseInt(match) + ' ';
400-
}
400+
}
401401
}
402402
}
403403

@@ -411,6 +411,10 @@ export class MI2 extends EventEmitter implements IBackend {
411411
this.sendCommand(`break-insert ${location}`).then((result) => {
412412
if (result.resultRecords.resultClass === 'done') {
413413
const bkptNum = parseInt(result.result('bkpt.number'));
414+
if (breakpoint.line !== undefined) {
415+
const line = result.result('bkpt.line');
416+
breakpoint.line = line ? parseInt(line) : breakpoint.line;
417+
}
414418
breakpoint.number = bkptNum;
415419

416420
if (breakpoint.condition) {

0 commit comments

Comments
 (0)