Remove input and length from state (#9646)
This commit is contained in:
@@ -23,9 +23,6 @@ type TopicContextState = {
|
||||
|
||||
export default class State {
|
||||
strict: boolean;
|
||||
input: string;
|
||||
length: number;
|
||||
|
||||
curLine: number;
|
||||
|
||||
// And, if locations are used, the {line, column} object
|
||||
@@ -33,13 +30,10 @@ export default class State {
|
||||
startLoc: Position;
|
||||
endLoc: Position;
|
||||
|
||||
init(options: Options, input: string): void {
|
||||
init(options: Options): void {
|
||||
this.strict =
|
||||
options.strictMode === false ? false : options.sourceType === "module";
|
||||
|
||||
this.input = input;
|
||||
this.length = input.length;
|
||||
|
||||
this.curLine = options.startLine;
|
||||
this.startLoc = this.endLoc = this.curPosition();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user