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

Unified Diff: src/objects/literal-objects.h

Issue 2811183005: Do not use new struct type where unnecessary. (Closed)
Patch Set: rebase Created 3 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 | « src/objects-printer.cc ('k') | test/cctest/interpreter/bytecode_expectations/ArrayLiterals.golden » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects/literal-objects.h
diff --git a/src/objects/literal-objects.h b/src/objects/literal-objects.h
index fdd321e74e6cf8f9f8a441f6cd86eedcb75d46cb..40bf70d602c50fb963d2945a8c3d4359dea90778 100644
--- a/src/objects/literal-objects.h
+++ b/src/objects/literal-objects.h
@@ -40,20 +40,15 @@ class BoilerplateDescription : public FixedArray {
// Pair of {ElementsKind} and an array of constant values for {ArrayLiteral}
// expressions. Used to communicate with the runtime for literal boilerplate
// creation within the {Runtime_CreateArrayLiteral} method.
-class ConstantElementsPair : public Struct {
+class ConstantElementsPair : public Tuple2 {
public:
DECL_INT_ACCESSORS(elements_kind)
DECL_ACCESSORS(constant_values, FixedArrayBase)
DECLARE_CAST(ConstantElementsPair)
- // Dispatched behavior.
- DECLARE_PRINTER(ConstantElementsPair)
- DECLARE_VERIFIER(ConstantElementsPair)
-
- static const int kElementsKindOffset = HeapObject::kHeaderSize;
- static const int kConstantValuesOffset = kElementsKindOffset + kPointerSize;
- static const int kSize = kConstantValuesOffset + kPointerSize;
+ static const int kElementsKindOffset = kValue1Offset;
+ static const int kConstantValuesOffset = kValue2Offset;
private:
DISALLOW_IMPLICIT_CONSTRUCTORS(ConstantElementsPair);
« no previous file with comments | « src/objects-printer.cc ('k') | test/cctest/interpreter/bytecode_expectations/ArrayLiterals.golden » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698