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

Unified Diff: mojo/public/cpp/bindings/lib/template_util.h

Issue 622593002: mojo: Allow circular dependencies between structs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 years, 2 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 | « mojo/public/cpp/bindings/lib/bindings_internal.h ('k') | mojo/public/cpp/bindings/struct_ptr.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/public/cpp/bindings/lib/template_util.h
diff --git a/mojo/public/cpp/bindings/lib/template_util.h b/mojo/public/cpp/bindings/lib/template_util.h
index 599126691ed2252aced902c3859d70ccc8c27b15..c4b83440918e395c9040e4291b8e53feedb97bdf 100644
--- a/mojo/public/cpp/bindings/lib/template_util.h
+++ b/mojo/public/cpp/bindings/lib/template_util.h
@@ -21,6 +21,9 @@ typedef IntegralConstant<bool, false> FalseType;
template <class T> struct IsConst : FalseType {};
template <class T> struct IsConst<const T> : TrueType {};
+template <class T> struct IsPointer : FalseType {};
+template <class T> struct IsPointer<T*> : TrueType {};
+
template<bool B, typename T = void>
struct EnableIf {};
@@ -83,6 +86,9 @@ template<typename Base, typename Derived> struct IsBaseOf {
!IsSame<Base const, void const>::value;
};
+template<class T> struct RemovePointer{};
viettrungluu 2014/10/06 23:08:40 nit: space before "{}"
qsr 2014/10/07 08:56:12 Done.
+template<class T> struct RemovePointer<T*> { typedef T type; };
+
} // namespace internal
} // namespace mojo
« no previous file with comments | « mojo/public/cpp/bindings/lib/bindings_internal.h ('k') | mojo/public/cpp/bindings/struct_ptr.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698