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

Unified Diff: src/runtime.cc

Issue 3274008: Get gcc to check that we don't ignore return values of functions that can... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 10 years, 4 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 | « src/parser.cc ('k') | src/stub-cache.h » ('j') | src/utils.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/runtime.cc
===================================================================
--- src/runtime.cc (revision 5365)
+++ src/runtime.cc (working copy)
@@ -98,7 +98,7 @@
static StaticResource<StringInputBuffer> runtime_string_input_buffer;
-static Object* DeepCopyBoilerplate(JSObject* boilerplate) {
+NOIGNORE static Object* DeepCopyBoilerplate(JSObject* boilerplate) {
StackLimitCheck check;
if (check.HasOverflowed()) return Top::StackOverflow();
@@ -980,7 +980,9 @@
context->set(index, *initial_value);
}
} else {
- Handle<JSObject>::cast(holder)->SetElement(index, *initial_value);
+ // The holder is an arguments object.
+ Handle<JSObject> arguments(Handle<JSObject>::cast(holder));
+ SetElement(arguments, index, initial_value);
}
} else {
// Slow case: The property is not in the FixedArray part of the context.
@@ -1238,7 +1240,8 @@
} else {
// The holder is an arguments object.
ASSERT((attributes & READ_ONLY) == 0);
- Handle<JSObject>::cast(holder)->SetElement(index, *value);
+ Handle<JSObject> arguments(Handle<JSObject>::cast(holder));
+ SetElement(arguments, index, value);
}
return *value;
}
@@ -4105,7 +4108,8 @@
if (result.IsProperty() &&
(result.type() == FIELD || result.type() == NORMAL
|| result.type() == CONSTANT_FUNCTION)) {
- obj->DeleteProperty(name, JSObject::NORMAL_DELETION);
+ Object* ok = obj->DeleteProperty(name, JSObject::NORMAL_DELETION);
+ if (ok->IsFailure()) return ok;
}
return obj->DefineAccessor(name, flag_setter->value() == 0, fun, attr);
}
« no previous file with comments | « src/parser.cc ('k') | src/stub-cache.h » ('j') | src/utils.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698