Fix parsing of newline between 'async' and 'function' (#8698)

This commit is contained in:
Brian Ng
2018-09-16 22:09:23 -05:00
committed by GitHub
parent aa33303112
commit 9b4b436e1f
10 changed files with 285 additions and 13 deletions

View File

@@ -21,6 +21,8 @@ export function isNewLine(code: number): boolean {
}
}
export const skipWhiteSpace = /(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g;
// https://tc39.github.io/ecma262/#sec-white-space
export function isWhitespace(code: number): boolean {
switch (code) {