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

Unified Diff: runtime/vm/isolate.cc

Issue 2070873002: Bug fixes for hot reload (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: fix an error message Created 4 years, 6 months 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/isolate.cc
diff --git a/runtime/vm/isolate.cc b/runtime/vm/isolate.cc
index 69578c907a7b7c0dd3a8a199571669f312369e78..536922684293e909d8239a2bf5debdb4bb4bcbde 100644
--- a/runtime/vm/isolate.cc
+++ b/runtime/vm/isolate.cc
@@ -813,6 +813,7 @@ Isolate::Isolate(const Dart_IsolateFlags& api_flags)
tag_table_(GrowableObjectArray::null()),
deoptimized_code_array_(GrowableObjectArray::null()),
sticky_error_(Error::null()),
+ sticky_reload_error_(Error::null()),
background_compiler_(NULL),
background_compiler_disabled_depth_(0),
pending_service_extension_calls_(GrowableObjectArray::null()),
@@ -1066,11 +1067,6 @@ void Isolate::ReportReloadError(const Error& error) {
}
-void Isolate::OnStackReload() {
- ReloadSources();
-}
-
-
void Isolate::ReloadSources(bool test_mode) {
ASSERT(!IsReloading());
has_attempted_reload_ = true;
@@ -1090,6 +1086,10 @@ void Isolate::DoneFinalizing() {
// context on the isolate so that it can be used by unit tests.
return;
}
+ if (reload_context_->has_error()) {
+ // Remember the reload error.
+ sticky_reload_error_ = reload_context_->error();
+ }
if (!reload_context_->has_error()) {
reload_context_->ReportSuccess();
}
@@ -1752,6 +1752,9 @@ void Isolate::VisitObjectPointers(ObjectPointerVisitor* visitor,
visitor->VisitPointer(
reinterpret_cast<RawObject**>(&sticky_error_));
+ visitor->VisitPointer(
+ reinterpret_cast<RawObject**>(&sticky_reload_error_));
+
// Visit the pending service extension calls.
visitor->VisitPointer(
reinterpret_cast<RawObject**>(&pending_service_extension_calls_));
@@ -2005,6 +2008,11 @@ void Isolate::clear_sticky_error() {
}
+void Isolate::clear_sticky_reload_error() {
+ sticky_reload_error_ = Error::null();
+}
+
+
void Isolate::set_pending_service_extension_calls(
const GrowableObjectArray& value) {
pending_service_extension_calls_ = value.raw();
« no previous file with comments | « runtime/vm/isolate.h ('k') | runtime/vm/isolate_reload_test.cc » ('j') | runtime/vm/service.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698