Skip to content

Commit

Permalink
debugger: show current line, fix for nodejs#6150
Browse files Browse the repository at this point in the history
  • Loading branch information
rlidwka committed Sep 28, 2013
1 parent 2e13d0c commit 8828ca9
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion lib/_debugger.js
Original file line number Diff line number Diff line change
Expand Up @@ -1152,8 +1152,15 @@ Interface.prototype.list = function(delta) {
} else {
line = lines[i];
}

var prefixChar = ' ';
if (current) {
prefixChar = '>';
} else if (breakpoint) {
prefixChar = '*';
}

self.print(leftPad(lineno, breakpoint && '*') + ' ' + line);
self.print(leftPad(lineno, prefixChar) + ' ' + line);
}
self.resume();
});
Expand Down

0 comments on commit 8828ca9

Please sign in to comment.