Got rid of most using directives. Ported tests to python.
[invirt/third/libt4.git] / rpc / marshall.h
index 8592e4b..08b6aaa 100644 (file)
@@ -122,7 +122,7 @@ tuple_marshall_imp(marshall & m, tuple<Args...> & t, tuple_indices<Indices...>)
     // to be evaluated in order.  Order matters because the elements must be
     // serialized consistently!  The empty struct resulting from construction
     // is discarded.
-    (void)pass{(m << get<Indices>(t))...};
+    (void)pass{(m << std::get<Indices>(t))...};
     return m;
 }
 
@@ -133,7 +133,7 @@ operator<<(marshall & m, tuple<Args...> && t) {
 
 template <class... Args, size_t... Indices> inline unmarshall &
 tuple_unmarshall_imp(unmarshall & u, tuple<Args & ...> t, tuple_indices<Indices...>) {
-    (void)pass{(u >> get<Indices>(t))...};
+    (void)pass{(u >> std::get<Indices>(t))...};
     return u;
 }
 
@@ -182,22 +182,22 @@ operator>>(unmarshall & u, A & x) {
 
 // std::pair<A, B>
 template <class A, class B> inline marshall &
-operator<<(marshall & m, const pair<A,B> & d) {
+operator<<(marshall & m, const std::pair<A,B> & d) {
     return m << d.first << d.second;
 }
 
 template <class A, class B> inline unmarshall &
-operator>>(unmarshall & u, pair<A,B> & d) {
+operator>>(unmarshall & u, std::pair<A,B> & d) {
     return u >> d.first >> d.second;
 }
 
 // std::map<A, B>
 template <class A, class B> inline unmarshall &
-operator>>(unmarshall & u, map<A,B> & x) {
+operator>>(unmarshall & u, std::map<A,B> & x) {
     uint32_t n = u._grab<uint32_t>();
     x.clear();
     while (n--)
-        x.emplace(u._grab<pair<A,B>>());
+        x.emplace(u._grab<std::pair<A,B>>());
     return u;
 }
 
@@ -221,12 +221,12 @@ inline unmarshall & operator>>(unmarshall & u, string & s) {
 // Marshalling for strongly-typed enums
 //
 
-template <class E> typename enable_if<is_enum<E>::value, marshall>::type &
+template <class E> typename enable_if<std::is_enum<E>::value, marshall>::type &
 operator<<(marshall & m, E e) {
     return m << from_enum(e);
 }
 
-template <class E> typename enable_if<is_enum<E>::value, unmarshall>::type &
+template <class E> typename enable_if<std::is_enum<E>::value, unmarshall>::type &
 operator>>(unmarshall & u, E & e) {
     e = to_enum<E>(u._grab<enum_type_t<E>>());
     return u;