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

Unified Diff: src/contexts.cc

Issue 2028983002: Introduce IsUndefined(Isolate*) and IsTheHole(Isolate*) (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fixing wrongly wrapped lines Created 4 years, 7 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
Index: src/contexts.cc
diff --git a/src/contexts.cc b/src/contexts.cc
index 392a3ccaa01c336ffdc044ed63dac8794c9144e1..52652e9a4eb0ceac6c61a59bb6891c03959e5156 100644
--- a/src/contexts.cc
+++ b/src/contexts.cc
@@ -484,9 +484,10 @@ void Context::RemoveOptimizedFunction(JSFunction* function) {
DCHECK(IsNativeContext());
Object* element = get(OPTIMIZED_FUNCTIONS_LIST);
JSFunction* prev = NULL;
- while (!element->IsUndefined()) {
+ Isolate* isolate = function->GetIsolate();
+ while (!element->IsUndefined(isolate)) {
JSFunction* element_function = JSFunction::cast(element);
- DCHECK(element_function->next_function_link()->IsUndefined() ||
+ DCHECK(element_function->next_function_link()->IsUndefined(isolate) ||
element_function->next_function_link()->IsJSFunction());
if (element_function == function) {
if (prev == NULL) {
@@ -555,7 +556,7 @@ Object* Context::DeoptimizedCodeListHead() {
Handle<Object> Context::ErrorMessageForCodeGenerationFromStrings() {
Isolate* isolate = GetIsolate();
Handle<Object> result(error_message_for_code_gen_from_strings(), isolate);
- if (!result->IsUndefined()) return result;
+ if (!result->IsUndefined(isolate)) return result;
return isolate->factory()->NewStringFromStaticChars(
"Code generation from strings disallowed for this context");
}
« no previous file with comments | « src/compiler/js-graph.cc ('k') | src/crankshaft/hydrogen.cc » ('j') | src/debug/debug.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698