off by one

This commit is contained in:
Oliver Schneider 2016-01-30 13:40:40 +01:00
parent c511d362fc
commit 54927ac57f

View File

@ -518,7 +518,7 @@ impl EmitterWriter {
};
let lo = self.cm.lookup_char_pos(sp.lo);
let hi = self.cm.lookup_char_pos(sp.hi);
let elide_sp = (hi.line - lo.line) > MAX_SP_LINES;
let elide_sp = (hi.line - lo.line) >= MAX_SP_LINES;
let line_num = line.line_index + 1;
if !(lo.line <= line_num && hi.line >= line_num) {