Skip to content

Commit 86c7def

Browse files
tokenUnterminated -> tokenIsUnterminated
1 parent 0e122b5 commit 86c7def

1 file changed

Lines changed: 9 additions & 9 deletions

File tree

src/compiler/scanner.ts

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -471,7 +471,7 @@ module ts {
471471
var token: SyntaxKind;
472472
var tokenValue: string;
473473
var precedingLineBreak: boolean;
474-
var tokenUnterminated: boolean;
474+
var tokenIsUnterminated: boolean;
475475

476476
function error(message: DiagnosticMessage): void {
477477
if (onError) {
@@ -555,7 +555,7 @@ module ts {
555555
while (true) {
556556
if (pos >= len) {
557557
result += text.substring(start, pos);
558-
tokenUnterminated = true;
558+
tokenIsUnterminated = true;
559559
error(Diagnostics.Unterminated_string_literal);
560560
break;
561561
}
@@ -573,7 +573,7 @@ module ts {
573573
}
574574
if (isLineBreak(ch)) {
575575
result += text.substring(start, pos);
576-
tokenUnterminated = true;
576+
tokenIsUnterminated = true;
577577
error(Diagnostics.Unterminated_string_literal);
578578
break;
579579
}
@@ -597,7 +597,7 @@ module ts {
597597
while (true) {
598598
if (pos >= len) {
599599
contents += text.substring(start, pos);
600-
tokenUnterminated = true;
600+
tokenIsUnterminated = true;
601601
error(Diagnostics.Unterminated_template_literal);
602602
resultingToken = startedWithBacktick ? SyntaxKind.NoSubstitutionTemplateLiteral : SyntaxKind.TemplateTail;
603603
break;
@@ -761,7 +761,7 @@ module ts {
761761
function scan(): SyntaxKind {
762762
startPos = pos;
763763
precedingLineBreak = false;
764-
tokenUnterminated = false;
764+
tokenIsUnterminated = false;
765765
while (true) {
766766
tokenPos = pos;
767767
if (pos >= len) {
@@ -918,7 +918,7 @@ module ts {
918918
continue;
919919
}
920920
else {
921-
tokenUnterminated = !commentClosed;
921+
tokenIsUnterminated = !commentClosed;
922922
return token = SyntaxKind.MultiLineCommentTrivia;
923923
}
924924
}
@@ -1076,14 +1076,14 @@ module ts {
10761076
// If we reach the end of a file, or hit a newline, then this is an unterminated
10771077
// regex. Report error and return what we have so far.
10781078
if (p >= len) {
1079-
tokenUnterminated = true;
1079+
tokenIsUnterminated = true;
10801080
error(Diagnostics.Unterminated_regular_expression_literal)
10811081
break;
10821082
}
10831083

10841084
var ch = text.charCodeAt(p);
10851085
if (isLineBreak(ch)) {
1086-
tokenUnterminated = true;
1086+
tokenIsUnterminated = true;
10871087
error(Diagnostics.Unterminated_regular_expression_literal)
10881088
break;
10891089
}
@@ -1176,7 +1176,7 @@ module ts {
11761176
hasPrecedingLineBreak: () => precedingLineBreak,
11771177
isIdentifier: () => token === SyntaxKind.Identifier || token > SyntaxKind.LastReservedWord,
11781178
isReservedWord: () => token >= SyntaxKind.FirstReservedWord && token <= SyntaxKind.LastReservedWord,
1179-
isUnterminated: () => tokenUnterminated,
1179+
isUnterminated: () => tokenIsUnterminated,
11801180
reScanGreaterToken,
11811181
reScanSlashToken,
11821182
reScanTemplateToken,

0 commit comments

Comments
 (0)