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

Side by Side Diff: src/debug/debug.cc

Issue 2628093003: [serializer] change internal field callbacks to take data pointer. (Closed)
Patch Set: Created 3 years, 11 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 unified diff | Download patch
« no previous file with comments | « src/api.cc ('k') | src/snapshot/deserializer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/debug/debug.h" 5 #include "src/debug/debug.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #include "src/api.h" 9 #include "src/api.h"
10 #include "src/arguments.h" 10 #include "src/arguments.h"
(...skipping 448 matching lines...) Expand 10 before | Expand all | Expand 10 after
459 459
460 // Create the debugger context. 460 // Create the debugger context.
461 HandleScope scope(isolate_); 461 HandleScope scope(isolate_);
462 ExtensionConfiguration no_extensions; 462 ExtensionConfiguration no_extensions;
463 // TODO(yangguo): we rely on the fact that first context snapshot is usable 463 // TODO(yangguo): we rely on the fact that first context snapshot is usable
464 // as debug context. This dependency is gone once we remove 464 // as debug context. This dependency is gone once we remove
465 // debug context completely. 465 // debug context completely.
466 static const int kFirstContextSnapshotIndex = 0; 466 static const int kFirstContextSnapshotIndex = 0;
467 Handle<Context> context = isolate_->bootstrapper()->CreateEnvironment( 467 Handle<Context> context = isolate_->bootstrapper()->CreateEnvironment(
468 MaybeHandle<JSGlobalProxy>(), v8::Local<ObjectTemplate>(), &no_extensions, 468 MaybeHandle<JSGlobalProxy>(), v8::Local<ObjectTemplate>(), &no_extensions,
469 kFirstContextSnapshotIndex, nullptr, DEBUG_CONTEXT); 469 kFirstContextSnapshotIndex, v8::DeserializeInternalFieldsCallback(),
470 DEBUG_CONTEXT);
470 471
471 // Fail if no context could be created. 472 // Fail if no context could be created.
472 if (context.is_null()) return false; 473 if (context.is_null()) return false;
473 474
474 debug_context_ = Handle<Context>::cast( 475 debug_context_ = Handle<Context>::cast(
475 isolate_->global_handles()->Create(*context)); 476 isolate_->global_handles()->Create(*context));
476 477
477 feature_tracker()->Track(DebugFeatureTracker::kActive); 478 feature_tracker()->Track(DebugFeatureTracker::kActive);
478 479
479 return true; 480 return true;
(...skipping 2073 matching lines...) Expand 10 before | Expand all | Expand 10 after
2553 logger_->DebugEvent("Put", message.text()); 2554 logger_->DebugEvent("Put", message.text());
2554 } 2555 }
2555 2556
2556 void LockingCommandMessageQueue::Clear() { 2557 void LockingCommandMessageQueue::Clear() {
2557 base::LockGuard<base::Mutex> lock_guard(&mutex_); 2558 base::LockGuard<base::Mutex> lock_guard(&mutex_);
2558 queue_.Clear(); 2559 queue_.Clear();
2559 } 2560 }
2560 2561
2561 } // namespace internal 2562 } // namespace internal
2562 } // namespace v8 2563 } // namespace v8
OLDNEW
« no previous file with comments | « src/api.cc ('k') | src/snapshot/deserializer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698