| Index: pkg/front_end/lib/src/fasta/quote.dart
|
| diff --git a/pkg/front_end/lib/src/fasta/quote.dart b/pkg/front_end/lib/src/fasta/quote.dart
|
| index a0624144952c7ac9f67c17a7aacb6dad5b94138d..3d9c60375a0e1c0d84241414d17a1d824de13387 100644
|
| --- a/pkg/front_end/lib/src/fasta/quote.dart
|
| +++ b/pkg/front_end/lib/src/fasta/quote.dart
|
| @@ -130,10 +130,12 @@ String unescapeLastStringPart(String last, Quote quote) {
|
|
|
| String unescapeString(String string) {
|
| Quote quote = analyzeQuote(string);
|
| - return unescape(
|
| - string.substring(firstQuoteLength(string, quote),
|
| - string.length - lastQuoteLength(quote)),
|
| - quote);
|
| + int startIndex = firstQuoteLength(string, quote);
|
| + if (startIndex == string.length) {
|
| + return '';
|
| + }
|
| + int endIndex = string.length - lastQuoteLength(quote);
|
| + return unescape(string.substring(startIndex, endIndex), quote);
|
| }
|
|
|
| String unescape(String string, Quote quote) {
|
|
|