Bugfix for StartOfLine() (actually Context.stringBefore())
This commit is contained in:
@@ -483,6 +483,7 @@ rr.StartOfLine = function() {
|
|||||||
/**
|
/**
|
||||||
* @type {rr.StartOfLine_}
|
* @type {rr.StartOfLine_}
|
||||||
* @const
|
* @const
|
||||||
|
* @private
|
||||||
*/
|
*/
|
||||||
rr.StartOfLine.cache_ = new rr.StartOfLine_();
|
rr.StartOfLine.cache_ = new rr.StartOfLine_();
|
||||||
}
|
}
|
||||||
@@ -674,7 +675,7 @@ rr.Context.prototype.stringBefore = function(numChars) {
|
|||||||
numChars += start;
|
numChars += start;
|
||||||
start = 0;
|
start = 0;
|
||||||
}
|
}
|
||||||
return this.input.slice(start, numChars);
|
return this.input.slice(start, start + numChars);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user