| Index: pkg/front_end/lib/src/fasta/scanner/array_based_scanner.dart
|
| diff --git a/pkg/front_end/lib/src/fasta/scanner/array_based_scanner.dart b/pkg/front_end/lib/src/fasta/scanner/array_based_scanner.dart
|
| index 1eb5ffb39151ac09fb1dfd829ca73ee356586dcb..756dea6601276417e187645441de0b2c9c766fe7 100644
|
| --- a/pkg/front_end/lib/src/fasta/scanner/array_based_scanner.dart
|
| +++ b/pkg/front_end/lib/src/fasta/scanner/array_based_scanner.dart
|
| @@ -17,7 +17,7 @@ import '../../scanner/token.dart'
|
| TokenType,
|
| TokenWithComment;
|
|
|
| -import 'token.dart' show StringToken;
|
| +import '../../scanner/token.dart' as analyzer show StringToken;
|
|
|
| import 'token_constants.dart'
|
| show
|
| @@ -222,11 +222,19 @@ abstract class ArrayBasedScanner extends AbstractScanner {
|
| appendToken(token);
|
| }
|
|
|
| + @override
|
| void appendSubstringToken(TokenType type, int start, bool asciiOnly,
|
| [int extraOffset = 0]) {
|
| appendToken(createSubstringToken(type, start, asciiOnly, extraOffset));
|
| }
|
|
|
| + @override
|
| + void appendSyntheticSubstringToken(
|
| + TokenType type, int start, bool asciiOnly, String closingQuotes) {
|
| + appendToken(
|
| + createSyntheticSubstringToken(type, start, asciiOnly, closingQuotes));
|
| + }
|
| +
|
| /**
|
| * Returns a new substring from the scan offset [start] to the current
|
| * [scanOffset] plus the [extraOffset]. For example, if the current
|
| @@ -236,10 +244,21 @@ abstract class ArrayBasedScanner extends AbstractScanner {
|
| * Note that [extraOffset] can only be used if the covered character(s) are
|
| * known to be ASCII.
|
| */
|
| - StringToken createSubstringToken(TokenType type, int start, bool asciiOnly,
|
| + analyzer.StringToken createSubstringToken(
|
| + TokenType type, int start, bool asciiOnly,
|
| [int extraOffset = 0]);
|
|
|
| /**
|
| + * Returns a new synthetic substring from the scan offset [start]
|
| + * to the current [scanOffset] plus the [closingQuotes].
|
| + * The [closingQuotes] are appended to the unterminated string
|
| + * literal's lexeme but the returned token's length will *not* include
|
| + * those closing quotes so as to be true to the original source.
|
| + */
|
| + analyzer.StringToken createSyntheticSubstringToken(
|
| + TokenType type, int start, bool asciiOnly, String closingQuotes);
|
| +
|
| + /**
|
| * This method is called to discard '<' from the "grouping" stack.
|
| *
|
| * [PartialParser.skipExpression] relies on the fact that we do not
|
|
|