Mesa (master): clover/util: Allow using key_equals with pair-like objects other than std::pair.

Francisco Jerez currojerez at kemper.freedesktop.org
Mon Oct 20 07:43:38 UTC 2014


Module: Mesa
Branch: master
Commit: 5583459655d61c9619284987e0272417db5daab3
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=5583459655d61c9619284987e0272417db5daab3

Author: Francisco Jerez <currojerez at riseup.net>
Date:   Thu Oct  9 01:02:19 2014 +0300

clover/util: Allow using key_equals with pair-like objects other than std::pair.

---

 src/gallium/state_trackers/clover/util/functional.hpp |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/gallium/state_trackers/clover/util/functional.hpp b/src/gallium/state_trackers/clover/util/functional.hpp
index fb2877a..ed69155 100644
--- a/src/gallium/state_trackers/clover/util/functional.hpp
+++ b/src/gallium/state_trackers/clover/util/functional.hpp
@@ -332,9 +332,9 @@ namespace clover {
       key_equals_t(T &&x) : x(x) {
       }
 
-      template<typename S>
+      template<typename P>
       bool
-      operator()(const std::pair<T, S> &p) const {
+      operator()(const P &p) const {
          return p.first == x;
       }
 




More information about the mesa-commit mailing list