[llvm] r198793 - Add missing definitions of key_type and value_type to DenseSet.

Matt Arsenault Matthew.Arsenault at amd.com
Wed Jan 8 13:38:05 PST 2014


Author: arsenm
Date: Wed Jan  8 15:38:04 2014
New Revision: 198793

URL: http://llvm.org/viewvc/llvm-project?rev=198793&view=rev
Log:
Add missing definitions of key_type and value_type to DenseSet.

This matches std::set and allows using DenseSet with the functions
in SetOperations.h

Modified:
    llvm/trunk/include/llvm/ADT/DenseSet.h

Modified: llvm/trunk/include/llvm/ADT/DenseSet.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/ADT/DenseSet.h?rev=198793&r1=198792&r2=198793&view=diff
==============================================================================
--- llvm/trunk/include/llvm/ADT/DenseSet.h (original)
+++ llvm/trunk/include/llvm/ADT/DenseSet.h Wed Jan  8 15:38:04 2014
@@ -27,6 +27,9 @@ class DenseSet {
   typedef DenseMap<ValueT, char, ValueInfoT> MapTy;
   MapTy TheMap;
 public:
+  typedef ValueT key_type;
+  typedef ValueT value_type;
+
   DenseSet(const DenseSet &Other) : TheMap(Other.TheMap) {}
   explicit DenseSet(unsigned NumInitBuckets = 0) : TheMap(NumInitBuckets) {}
 





More information about the llvm-commits mailing list