Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Merge pull request #20 from raiph/patch-1
Bugfix: make "safe" char offset actually safe
  • Loading branch information
jnthn committed Apr 30, 2014
2 parents 30c8475 + 5ace022 commit 4230f5b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/Debugger/UI/CommandLine.pm
Expand Up @@ -98,8 +98,8 @@ my class SourceFile {
@lines.map: {
state $line = 0;
NEXT $line++;
my $safe_start_pos = [min] $start_line_pos, .chars - 1;
my $safe_end_pos = [min] $end_line_pos, .chars - 1;
my $safe_start_pos = [min] $start_line_pos, .chars;
my $safe_end_pos = [min] $end_line_pos, .chars;
my $rendered = colored('| ', 'blue');
if $line == 0 && $line == @lines.end {
$rendered ~= .substr(0, $safe_start_pos);
Expand Down

0 comments on commit 4230f5b

Please sign in to comment.