Index: src/api.cc |
diff --git a/src/api.cc b/src/api.cc |
index aee9e3a469eae454a9fdc7b241142050044a730a..073ee2a9cff38ce9d2dd5f910d95007295a4e100 100644 |
--- a/src/api.cc |
+++ b/src/api.cc |
@@ -5410,6 +5410,7 @@ v8::Local<v8::Object> Context::Global() { |
i::Handle<i::Context> context = Utils::OpenHandle(this); |
i::Isolate* isolate = context->GetIsolate(); |
i::Handle<i::Object> global(context->global_proxy(), isolate); |
+ ASSERT(!i::Handle<i::JSGlobalProxy>::cast(global)->IsDetached()); |
return Utils::ToLocal(i::Handle<i::JSObject>::cast(global)); |
} |
@@ -5422,16 +5423,6 @@ void Context::DetachGlobal() { |
} |
-void Context::ReattachGlobal(Handle<Object> global_object) { |
- i::Handle<i::Context> context = Utils::OpenHandle(this); |
- i::Isolate* isolate = context->GetIsolate(); |
- ENTER_V8(isolate); |
- i::Handle<i::JSGlobalProxy> global_proxy = |
- i::Handle<i::JSGlobalProxy>::cast(Utils::OpenHandle(*global_object)); |
- isolate->bootstrapper()->ReattachGlobal(context, global_proxy); |
-} |
- |
- |
void Context::AllowCodeGenerationFromStrings(bool allow) { |
i::Handle<i::Context> context = Utils::OpenHandle(this); |
i::Isolate* isolate = context->GetIsolate(); |