Remove HandleScope default ctor.

BUG=chromium:236173
R=bmeurer@chromium.org, svenpanne@chromium.org

Review URL: https://codereview.chromium.org/23530045

Patch from Marja Hölttä <marja@chromium.org>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16605 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 24a0cabd
...@@ -748,9 +748,6 @@ template <class T, class M> class Persistent { ...@@ -748,9 +748,6 @@ template <class T, class M> class Persistent {
*/ */
class V8_EXPORT HandleScope { class V8_EXPORT HandleScope {
public: public:
// TODO(svenpanne) Deprecate me when Chrome is fixed!
HandleScope();
HandleScope(Isolate* isolate); HandleScope(Isolate* isolate);
~HandleScope(); ~HandleScope();
......
...@@ -706,11 +706,6 @@ Local<Value> V8::GetEternal(Isolate* v8_isolate, int index) { ...@@ -706,11 +706,6 @@ Local<Value> V8::GetEternal(Isolate* v8_isolate, int index) {
// --- H a n d l e s --- // --- H a n d l e s ---
HandleScope::HandleScope() {
Initialize(reinterpret_cast<Isolate*>(i::Isolate::Current()));
}
HandleScope::HandleScope(Isolate* isolate) { HandleScope::HandleScope(Isolate* isolate) {
Initialize(isolate); Initialize(isolate);
} }
......
...@@ -3422,7 +3422,7 @@ TEST(DeferredHandles) { ...@@ -3422,7 +3422,7 @@ TEST(DeferredHandles) {
CcTest::InitializeVM(); CcTest::InitializeVM();
Isolate* isolate = Isolate::Current(); Isolate* isolate = Isolate::Current();
Heap* heap = isolate->heap(); Heap* heap = isolate->heap();
v8::HandleScope scope; v8::HandleScope scope(reinterpret_cast<v8::Isolate*>(isolate));
v8::ImplementationUtilities::HandleScopeData* data = v8::ImplementationUtilities::HandleScopeData* data =
isolate->handle_scope_data(); isolate->handle_scope_data();
Handle<Object> init(heap->empty_string(), isolate); Handle<Object> init(heap->empty_string(), isolate);
......
...@@ -572,7 +572,7 @@ intptr_t ShortLivingIsolate() { ...@@ -572,7 +572,7 @@ intptr_t ShortLivingIsolate() {
v8::Isolate* isolate = v8::Isolate::New(); v8::Isolate* isolate = v8::Isolate::New();
{ v8::Isolate::Scope isolate_scope(isolate); { v8::Isolate::Scope isolate_scope(isolate);
v8::Locker lock(isolate); v8::Locker lock(isolate);
v8::HandleScope handle_scope; v8::HandleScope handle_scope(isolate);
v8::Local<v8::Context> context = v8::Context::New(isolate); v8::Local<v8::Context> context = v8::Context::New(isolate);
CHECK(!context.IsEmpty()); CHECK(!context.IsEmpty());
} }
......
...@@ -324,11 +324,11 @@ void DoLoopCancelTerminate(const v8::FunctionCallbackInfo<v8::Value>& args) { ...@@ -324,11 +324,11 @@ void DoLoopCancelTerminate(const v8::FunctionCallbackInfo<v8::Value>& args) {
// Test that a single thread of JavaScript execution can terminate // Test that a single thread of JavaScript execution can terminate
// itself and then resume execution. // itself and then resume execution.
TEST(TerminateCancelTerminateFromThreadItself) { TEST(TerminateCancelTerminateFromThreadItself) {
v8::HandleScope scope; v8::Isolate* isolate = v8::Isolate::GetCurrent();
v8::HandleScope scope(isolate);
v8::Handle<v8::ObjectTemplate> global = v8::Handle<v8::ObjectTemplate> global =
CreateGlobalTemplate(TerminateCurrentThread, DoLoopCancelTerminate); CreateGlobalTemplate(TerminateCurrentThread, DoLoopCancelTerminate);
v8::Handle<v8::Context> context = v8::Handle<v8::Context> context = v8::Context::New(isolate, NULL, global);
v8::Context::New(v8::Isolate::GetCurrent(), NULL, global);
v8::Context::Scope context_scope(context); v8::Context::Scope context_scope(context);
CHECK(!v8::V8::IsExecutionTerminating()); CHECK(!v8::V8::IsExecutionTerminating());
v8::Handle<v8::String> source = v8::Handle<v8::String> source =
...@@ -336,4 +336,3 @@ TEST(TerminateCancelTerminateFromThreadItself) { ...@@ -336,4 +336,3 @@ TEST(TerminateCancelTerminateFromThreadItself) {
// Check that execution completed with correct return value. // Check that execution completed with correct return value.
CHECK(v8::Script::Compile(source)->Run()->Equals(v8_str("completed"))); CHECK(v8::Script::Compile(source)->Run()->Equals(v8_str("completed")));
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment