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

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

Issue 228233002: Fix more MUST_USE_RESULT warnings. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 8 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-heap.cc
diff --git a/test/cctest/test-heap.cc b/test/cctest/test-heap.cc
index 7647a6ee0d0720d437065b81f0982f4b323182a5..47c85c224314c0c912d0d5b5b2dd2c0ec8535890 100644
--- a/test/cctest/test-heap.cc
+++ b/test/cctest/test-heap.cc
@@ -779,7 +779,7 @@ TEST(JSArray) {
CHECK(array->HasFastSmiOrObjectElements());
// array[length] = name.
- JSReceiver::SetElement(array, 0, name, NONE, SLOPPY);
+ JSReceiver::SetElement(array, 0, name, NONE, SLOPPY).Check();
CHECK_EQ(Smi::FromInt(1), array->length());
CHECK_EQ(*i::Object::GetElement(isolate, array, 0), *name);
@@ -794,7 +794,7 @@ TEST(JSArray) {
CHECK(array->HasDictionaryElements()); // Must be in slow mode.
// array[length] = name.
- JSReceiver::SetElement(array, int_length, name, NONE, SLOPPY);
+ JSReceiver::SetElement(array, int_length, name, NONE, SLOPPY).Check();
uint32_t new_int_length = 0;
CHECK(array->length()->ToArrayIndex(&new_int_length));
CHECK_EQ(static_cast<double>(int_length), new_int_length - 1);
@@ -824,8 +824,8 @@ TEST(JSObjectCopy) {
JSReceiver::SetProperty(obj, first, one, NONE, SLOPPY).Check();
JSReceiver::SetProperty(obj, second, two, NONE, SLOPPY).Check();
- JSReceiver::SetElement(obj, 0, first, NONE, SLOPPY);
- JSReceiver::SetElement(obj, 1, second, NONE, SLOPPY);
+ JSReceiver::SetElement(obj, 0, first, NONE, SLOPPY).Check();
+ JSReceiver::SetElement(obj, 1, second, NONE, SLOPPY).Check();
// Make the clone.
Handle<JSObject> clone = JSObject::Copy(obj);
@@ -843,8 +843,8 @@ TEST(JSObjectCopy) {
JSReceiver::SetProperty(clone, first, two, NONE, SLOPPY).Check();
JSReceiver::SetProperty(clone, second, one, NONE, SLOPPY).Check();
- JSReceiver::SetElement(clone, 0, second, NONE, SLOPPY);
- JSReceiver::SetElement(clone, 1, first, NONE, SLOPPY);
+ JSReceiver::SetElement(clone, 0, second, NONE, SLOPPY).Check();
+ JSReceiver::SetElement(clone, 1, first, NONE, SLOPPY).Check();
CHECK_EQ(*i::Object::GetElement(isolate, obj, 1),
*i::Object::GetElement(isolate, clone, 0));
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698