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

Unified Diff: test/cctest/test-debug.cc

Issue 12300018: Made Isolate a mandatory parameter for everything Handle-related. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Fixed CreateCode calls. Be nicer to MIPS. Created 7 years, 10 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 | « test/cctest/test-compiler.cc ('k') | test/cctest/test-disasm-ia32.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-debug.cc
diff --git a/test/cctest/test-debug.cc b/test/cctest/test-debug.cc
index d1158e544e7374033a7affb62cb109fb5e885ea1..d837eac74bfd200fba27106c29697ccdb95fd942 100644
--- a/test/cctest/test-debug.cc
+++ b/test/cctest/test-debug.cc
@@ -143,7 +143,8 @@ class DebugLocalContext {
inline v8::Context* operator*() { return *context_; }
inline bool IsReady() { return !context_.IsEmpty(); }
void ExposeDebug() {
- v8::internal::Isolate* isolate = v8::internal::Isolate::Current();
+ v8::internal::Isolate* isolate =
+ reinterpret_cast<v8::internal::Isolate*>(context_->GetIsolate());
v8::internal::Debug* debug = isolate->debug();
// Expose the debug context global object in the global object for testing.
debug->Load();
@@ -155,8 +156,9 @@ class DebugLocalContext {
Handle<v8::internal::String> debug_string =
FACTORY->LookupOneByteSymbol(STATIC_ASCII_VECTOR("debug"));
SetProperty(isolate, global, debug_string,
- Handle<Object>(debug->debug_context()->global_proxy()), DONT_ENUM,
- ::v8::internal::kNonStrictMode);
+ Handle<Object>(debug->debug_context()->global_proxy(), isolate),
+ DONT_ENUM,
+ ::v8::internal::kNonStrictMode);
}
private:
@@ -198,10 +200,11 @@ static bool HasDebugInfo(v8::Handle<v8::Function> fun) {
// number.
static int SetBreakPoint(Handle<v8::internal::JSFunction> fun, int position) {
static int break_point = 0;
- v8::internal::Debug* debug = v8::internal::Isolate::Current()->debug();
+ v8::internal::Isolate* isolate = fun->GetIsolate();
+ v8::internal::Debug* debug = isolate->debug();
debug->SetBreakPoint(
fun,
- Handle<Object>(v8::internal::Smi::FromInt(++break_point)),
+ Handle<Object>(v8::internal::Smi::FromInt(++break_point), isolate),
&position);
return break_point;
}
@@ -282,9 +285,10 @@ static int SetScriptBreakPointByNameFromJS(const char* script_name,
// Clear a break point.
static void ClearBreakPoint(int break_point) {
- v8::internal::Debug* debug = v8::internal::Isolate::Current()->debug();
+ v8::internal::Isolate* isolate = v8::internal::Isolate::Current();
+ v8::internal::Debug* debug = isolate->debug();
debug->ClearBreakPoint(
- Handle<Object>(v8::internal::Smi::FromInt(break_point)));
+ Handle<Object>(v8::internal::Smi::FromInt(break_point), isolate));
}
« no previous file with comments | « test/cctest/test-compiler.cc ('k') | test/cctest/test-disasm-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698