| Index: lib/compiler/implementation/source_map_builder.dart
|
| diff --git a/lib/compiler/implementation/source_map_builder.dart b/lib/compiler/implementation/source_map_builder.dart
|
| index f82b275ab173248a5d650a18df913418307dc23b..0b081ac69b32be759a1c436ca910b256fff260b0 100644
|
| --- a/lib/compiler/implementation/source_map_builder.dart
|
| +++ b/lib/compiler/implementation/source_map_builder.dart
|
| @@ -155,7 +155,7 @@ class SourceFileLocation {
|
| int line;
|
|
|
| SourceFileLocation(this.sourceFile, this.token) {
|
| - assert(token.charOffset < sourceFile.text.length);
|
| + assert(isValid());
|
| }
|
|
|
| String getSourceUrl() => sourceFile.filename;
|
| @@ -171,4 +171,6 @@ class SourceFileLocation {
|
| if (token.isIdentifier()) return token.slowToString();
|
| return null;
|
| }
|
| +
|
| + bool isValid() => token.charOffset < sourceFile.text.length;
|
| }
|
|
|