I needed a hash-container to take advantage of constant-time searches so I came to unordered_set. Unfortunately the std::unordered_set requires c++11 enabled which more than quadruples my compile times (gcc), and I would have to write a hash function for std::pair.
Fortunately boost::unordered_set does not require c++11 and it is already able to hash std::pair.
My question now is, I want to search for pairs in no particular order, ie std::pair(5,3) should be considered equal to std::pair(3,5).
Must I define both 1) a hash function that hashes to the same value for both cases? and 2) an equality function that returns true for both cases?
Foregoing this solution, I could just insert both pairs and do 2 searches instead.