Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(614)

Unified Diff: runtime/vm/object.cc

Issue 2511883002: VM: [Kernel] Relax assertion in Script::GetTokenLocation(). (Closed)
Patch Set: Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: runtime/vm/object.cc
diff --git a/runtime/vm/object.cc b/runtime/vm/object.cc
index 2c652cc8fbbb4419308d774dfffada242fc75bc3..ccd7f25336eb8ac0355e8d39ec991b23466daed9 100644
--- a/runtime/vm/object.cc
+++ b/runtime/vm/object.cc
@@ -8856,7 +8856,8 @@ void Script::GetTokenLocation(TokenPosition token_pos,
Zone* zone = Thread::Current()->zone();
const TokenStream& tkns = TokenStream::Handle(zone, tokens());
if (tkns.IsNull()) {
- ASSERT(Dart::snapshot_kind() == Snapshot::kAppNoJIT);
+ ASSERT((Dart::snapshot_kind() == Snapshot::kAppNoJIT) ||
+ (url() == Symbols::KernelScriptUri().raw()));
*line = -1;
if (column != NULL) {
*column = -1;

Powered by Google App Engine
This is Rietveld 408576698