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

Unified Diff: src/json-stringifier.h

Issue 1194943004: Get rid of JSArray::Expand and friends (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 6 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/elements.cc ('k') | src/jsregexp.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/json-stringifier.h
diff --git a/src/json-stringifier.h b/src/json-stringifier.h
index 482d7920d3dcce0007e29c8b6bec970fe37fb248..1ba99c1e9ac5439753a3422fffae296ac3e08c9a 100644
--- a/src/json-stringifier.h
+++ b/src/json-stringifier.h
@@ -280,9 +280,8 @@ BasicJsonStringifier::Result BasicJsonStringifier::StackPush(
}
}
}
- JSArray::EnsureSize(stack_, length + 1);
+ JSArray::SetLength(stack_, length + 1);
FixedArray::cast(stack_->elements())->set(length, *object);
- stack_->set_length(Smi::FromInt(length + 1));
return SUCCESS;
}
« no previous file with comments | « src/elements.cc ('k') | src/jsregexp.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698