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

Unified Diff: src/factory.cc

Issue 1144183004: [strong] Refactor ObjectStrength into a replacement for strong boolean args (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: cl feedback and rebase 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/factory.h ('k') | src/globals.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/factory.cc
diff --git a/src/factory.cc b/src/factory.cc
index 4aca8854565c06b97d33fd11a9783313b3434613..a16e6fba05edbc7c63e16b54ca3d541531d85c43 100644
--- a/src/factory.cc
+++ b/src/factory.cc
@@ -1609,11 +1609,11 @@ Handle<JSObject> Factory::NewJSObjectFromMap(
Handle<JSArray> Factory::NewJSArray(ElementsKind elements_kind,
- ObjectStrength strength,
+ Strength strength,
PretenureFlag pretenure) {
Map* map = isolate()->get_initial_js_array_map(elements_kind, strength);
if (map == nullptr) {
- DCHECK(strength == WEAK);
+ DCHECK(strength == Strength::WEAK);
Context* native_context = isolate()->context()->native_context();
JSFunction* array_function = native_context->array_function();
map = array_function->initial_map();
@@ -1623,7 +1623,7 @@ Handle<JSArray> Factory::NewJSArray(ElementsKind elements_kind,
Handle<JSArray> Factory::NewJSArray(ElementsKind elements_kind, int length,
- int capacity, ObjectStrength strength,
+ int capacity, Strength strength,
ArrayStorageAllocationMode mode,
PretenureFlag pretenure) {
Handle<JSArray> array = NewJSArray(elements_kind, strength, pretenure);
@@ -1634,8 +1634,7 @@ Handle<JSArray> Factory::NewJSArray(ElementsKind elements_kind, int length,
Handle<JSArray> Factory::NewJSArrayWithElements(Handle<FixedArrayBase> elements,
ElementsKind elements_kind,
- int length,
- ObjectStrength strength,
+ int length, Strength strength,
PretenureFlag pretenure) {
DCHECK(length <= elements->length());
Handle<JSArray> array = NewJSArray(elements_kind, strength, pretenure);
« no previous file with comments | « src/factory.h ('k') | src/globals.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698