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

Unified Diff: test/unittests/compiler/graph-unittest.cc

Issue 819103002: [turbofan] Minor cleanup to reduce code duplication. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 6 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/unittests/compiler/graph-unittest.h ('k') | test/unittests/compiler/js-builtin-reducer-unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/unittests/compiler/graph-unittest.cc
diff --git a/test/unittests/compiler/graph-unittest.cc b/test/unittests/compiler/graph-unittest.cc
index 2cfd23a125d0d2e1795f84f996d1d9b0ef50086c..95432587a825f947f42616c8067c86bff7a03f17 100644
--- a/test/unittests/compiler/graph-unittest.cc
+++ b/test/unittests/compiler/graph-unittest.cc
@@ -4,8 +4,6 @@
#include "test/unittests/compiler/graph-unittest.h"
-#include <ostream> // NOLINT(readability/streams)
-
#include "src/compiler/node-properties-inl.h"
#include "test/unittests/compiler/node-test-utils.h"
@@ -93,6 +91,20 @@ Matcher<Node*> GraphTest::IsTrueConstant() {
Unique<HeapObject>::CreateImmovable(factory()->true_value()));
}
+
+TypedGraphTest::TypedGraphTest(int num_parameters)
+ : GraphTest(num_parameters), typer_(graph(), MaybeHandle<Context>()) {}
+
+
+TypedGraphTest::~TypedGraphTest() {}
+
+
+Node* TypedGraphTest::Parameter(Type* type, int32_t index) {
+ Node* node = GraphTest::Parameter(index);
+ NodeProperties::SetBounds(node, Bounds(type));
+ return node;
+}
+
} // namespace compiler
} // namespace internal
} // namespace v8
« no previous file with comments | « test/unittests/compiler/graph-unittest.h ('k') | test/unittests/compiler/js-builtin-reducer-unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698