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

Unified Diff: runtime/vm/class_finalizer.cc

Issue 1310463005: - Ensure that HandleScope is initialized with a thread. (Remove (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Address review comments Created 5 years, 4 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
« no previous file with comments | « runtime/vm/bootstrap.cc ('k') | runtime/vm/coverage.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/class_finalizer.cc
diff --git a/runtime/vm/class_finalizer.cc b/runtime/vm/class_finalizer.cc
index 48bbfce06007ed60f492df4c8deced0f39e93f39..b9f1fcbd925bb92d73f5fd80da713c96d4cda48d 100644
--- a/runtime/vm/class_finalizer.cc
+++ b/runtime/vm/class_finalizer.cc
@@ -116,9 +116,10 @@ static void CollectImmediateSuperInterfaces(
// a) when bootstrap process completes (VerifyBootstrapClasses).
// b) after the user classes are loaded (dart_api).
bool ClassFinalizer::ProcessPendingClasses() {
- Isolate* isolate = Isolate::Current();
+ Thread* thread = Thread::Current();
+ Isolate* isolate = thread->isolate();
ASSERT(isolate != NULL);
- HANDLESCOPE(isolate);
+ HANDLESCOPE(thread);
ObjectStore* object_store = isolate->object_store();
const Error& error = Error::Handle(isolate, object_store->sticky_error());
if (!error.IsNull()) {
@@ -2227,7 +2228,8 @@ void ClassFinalizer::ApplyMixinMembers(const Class& cls) {
void ClassFinalizer::FinalizeTypesInClass(const Class& cls) {
- HANDLESCOPE(Isolate::Current());
+ Thread* thread = Thread::Current();
+ HANDLESCOPE(thread);
if (cls.is_type_finalized()) {
return;
}
@@ -2360,7 +2362,8 @@ void ClassFinalizer::FinalizeTypesInClass(const Class& cls) {
void ClassFinalizer::FinalizeClass(const Class& cls) {
- HANDLESCOPE(Isolate::Current());
+ Thread* thread = Thread::Current();
+ HANDLESCOPE(thread);
if (cls.is_finalized()) {
return;
}
@@ -2990,7 +2993,8 @@ void ClassFinalizer::CheckForLegalConstClass(const Class& cls) {
void ClassFinalizer::PrintClassInformation(const Class& cls) {
- HANDLESCOPE(Isolate::Current());
+ Thread* thread = Thread::Current();
+ HANDLESCOPE(thread);
const String& class_name = String::Handle(cls.Name());
ISL_Print("class '%s'", class_name.ToCString());
const Library& library = Library::Handle(cls.library());
« no previous file with comments | « runtime/vm/bootstrap.cc ('k') | runtime/vm/coverage.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698