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

Unified Diff: src/compiler/operator.h

Issue 543743002: Remove deprecated PrintableUnique. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 3 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/compiler/node-matchers.h ('k') | src/compiler/raw-machine-assembler.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/operator.h
diff --git a/src/compiler/operator.h b/src/compiler/operator.h
index 67f38ede43f162b4692624d480d9e1e730922438..bb318d846df189d4e9fc1aeff968e6ac9f8f9472 100644
--- a/src/compiler/operator.h
+++ b/src/compiler/operator.h
@@ -178,32 +178,26 @@ struct StaticParameterTraits<double> {
}
};
-// Specialization for static parameters of type {PrintableUnique<Object>}.
+// Specialization for static parameters of type {Unique<Object>}.
template <>
-struct StaticParameterTraits<PrintableUnique<Object> > {
- static OStream& PrintTo(OStream& os, PrintableUnique<Object> val) { // NOLINT
- return os << val.string();
+struct StaticParameterTraits<Unique<Object> > {
+ static OStream& PrintTo(OStream& os, Unique<Object> val) { // NOLINT
+ return os << Brief(*val.handle());
}
- static int HashCode(PrintableUnique<Object> a) {
+ static int HashCode(Unique<Object> a) {
return static_cast<int>(a.Hashcode());
}
- static bool Equals(PrintableUnique<Object> a, PrintableUnique<Object> b) {
- return a == b;
- }
+ static bool Equals(Unique<Object> a, Unique<Object> b) { return a == b; }
};
-// Specialization for static parameters of type {PrintableUnique<Name>}.
+// Specialization for static parameters of type {Unique<Name>}.
template <>
-struct StaticParameterTraits<PrintableUnique<Name> > {
- static OStream& PrintTo(OStream& os, PrintableUnique<Name> val) { // NOLINT
- return os << val.string();
- }
- static int HashCode(PrintableUnique<Name> a) {
- return static_cast<int>(a.Hashcode());
- }
- static bool Equals(PrintableUnique<Name> a, PrintableUnique<Name> b) {
- return a == b;
+struct StaticParameterTraits<Unique<Name> > {
+ static OStream& PrintTo(OStream& os, Unique<Name> val) { // NOLINT
+ return os << Brief(*val.handle());
}
+ static int HashCode(Unique<Name> a) { return static_cast<int>(a.Hashcode()); }
+ static bool Equals(Unique<Name> a, Unique<Name> b) { return a == b; }
};
#if DEBUG
@@ -212,15 +206,15 @@ struct StaticParameterTraits<PrintableUnique<Name> > {
template <>
struct StaticParameterTraits<Handle<Object> > {
static OStream& PrintTo(OStream& os, Handle<Object> val) { // NOLINT
- UNREACHABLE(); // Should use PrintableUnique<Object> instead
+ UNREACHABLE(); // Should use Unique<Object> instead
return os;
}
static int HashCode(Handle<Object> a) {
- UNREACHABLE(); // Should use PrintableUnique<Object> instead
+ UNREACHABLE(); // Should use Unique<Object> instead
return 0;
}
static bool Equals(Handle<Object> a, Handle<Object> b) {
- UNREACHABLE(); // Should use PrintableUnique<Object> instead
+ UNREACHABLE(); // Should use Unique<Object> instead
return false;
}
};
@@ -267,7 +261,7 @@ class Operator1 : public Operator {
};
// Type definitions for operators with specific types of parameters.
-typedef Operator1<PrintableUnique<Name> > NameOperator;
+typedef Operator1<Unique<Name> > NameOperator;
// Helper to extract parameters from Operator1<*> operator.
« no previous file with comments | « src/compiler/node-matchers.h ('k') | src/compiler/raw-machine-assembler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698