refactor: split locationParser into ParserErrors and error message (#11653)

This commit is contained in:
Huáng Jùnliàng
2020-05-30 15:05:42 -04:00
committed by GitHub
parent 15d6da076a
commit b5c4a46a69
13 changed files with 82 additions and 78 deletions

View File

@@ -9,7 +9,7 @@ import * as charCodes from "charcodes";
import { isIdentifierStart, isIdentifierChar } from "../util/identifier";
import { types as tt, keywords as keywordTypes, type TokenType } from "./types";
import { type TokContext, types as ct } from "./context";
import LocationParser, { Errors } from "../parser/location";
import ParserErrors, { Errors } from "../parser/error";
import { SourceLocation } from "../util/location";
import {
lineBreak,
@@ -110,7 +110,7 @@ export class Token {
// ## Tokenizer
export default class Tokenizer extends LocationParser {
export default class Tokenizer extends ParserErrors {
// Forward-declarations
// parser/util.js
/*::