clover: Add a simple compat::pair.
authorEdB <edb+mesa@sigluy.net>
Wed, 8 Oct 2014 22:06:48 +0000 (01:06 +0300)
committerFrancisco Jerez <currojerez@riseup.net>
Mon, 20 Oct 2014 07:33:02 +0000 (10:33 +0300)
std::pair is not c++98/c++11 safe.

Reviewed-by: Francisco Jerez <currojerez@riseup.net>
src/gallium/state_trackers/clover/util/compat.hpp

index eaae8c02940b0ab9f4c5d6843f7a6f0be62ab5e7..a52a6af7a4610669ef80b9092d78b7f78c10a69b 100644 (file)
@@ -412,6 +412,15 @@ namespace clover {
          mutable vector<char> v;
       };
 
+      template<typename T, typename S>
+      struct pair {
+         pair(T first, S second) :
+            first(first), second(second) {}
+
+         S first;
+         T second;
+      };
+
       class exception {
       public:
          exception() {}