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

Unified Diff: test/unittests/interpreter/bytecode-array-builder-unittest.cc

Issue 2581683003: Introduce {ConstantElementsPair} struct for type safety. (Closed)
Patch Set: Rebased. Created 4 years 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 | « test/cctest/interpreter/bytecode_expectations/SuperCallAndSpread.golden ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/unittests/interpreter/bytecode-array-builder-unittest.cc
diff --git a/test/unittests/interpreter/bytecode-array-builder-unittest.cc b/test/unittests/interpreter/bytecode-array-builder-unittest.cc
index d7bdbb33725b20c13e7acdfa1798c9ddb4c8ca02..7f56a6420de1a97c5af3b803d63ad0f41bdda1e2 100644
--- a/test/unittests/interpreter/bytecode-array-builder-unittest.cc
+++ b/test/unittests/interpreter/bytecode-array-builder-unittest.cc
@@ -125,7 +125,9 @@ TEST_F(BytecodeArrayBuilderTest, AllBytecodesGenerated) {
// Emit literal creation operations.
builder.CreateRegExpLiteral(factory->NewStringFromStaticChars("a"), 0, 0)
- .CreateArrayLiteral(factory->NewFixedArray(1), 0, 0)
+ .CreateArrayLiteral(factory->NewConstantElementsPair(
+ FAST_ELEMENTS, factory->empty_fixed_array()),
+ 0, 0)
.CreateObjectLiteral(factory->NewFixedArray(1), 0, 0, reg);
// Call operations.
@@ -329,9 +331,12 @@ TEST_F(BytecodeArrayBuilderTest, AllBytecodesGenerated) {
builder.CreateClosure(1000, NOT_TENURED);
// Emit wide variant of literal creation operations.
- builder.CreateRegExpLiteral(factory->NewStringFromStaticChars("wide_literal"),
- 0, 0)
- .CreateArrayLiteral(factory->NewFixedArray(2), 0, 0)
+ builder
+ .CreateRegExpLiteral(factory->NewStringFromStaticChars("wide_literal"), 0,
+ 0)
+ .CreateArrayLiteral(factory->NewConstantElementsPair(
+ FAST_ELEMENTS, factory->empty_fixed_array()),
+ 0, 0)
.CreateObjectLiteral(factory->NewFixedArray(2), 0, 0, reg);
// Emit load and store operations for module variables.
« no previous file with comments | « test/cctest/interpreter/bytecode_expectations/SuperCallAndSpread.golden ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698