Just use a using directive in SmallMapVector instead of inheriting from MapVector...
authorMichael Gottesman <mgottesman@apple.com>
Thu, 1 Jan 2015 08:05:41 +0000 (08:05 +0000)
committerMichael Gottesman <mgottesman@apple.com>
Thu, 1 Jan 2015 08:05:41 +0000 (08:05 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@225059 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/ADT/MapVector.h

index 0727383310a0cf49b607f1f34673b9bf2d1a4529..b10db611484af53a091fa219102e37e335b2f010 100644 (file)
@@ -185,12 +185,9 @@ void MapVector<KeyT, ValueT, MapType, VectorType>::remove_if(Function Pred) {
 /// \brief A MapVector that performs no allocations if smaller than a certain
 /// size.
 template <typename KeyT, typename ValueT, unsigned N>
-class SmallMapVector
-    : public MapVector<KeyT, ValueT, SmallDenseMap<KeyT, unsigned, N>,
-                       SmallVector<std::pair<KeyT, ValueT>, N>> {
-public:
-  SmallMapVector() {}
-};
+using SmallMapVector =
+  MapVector<KeyT, ValueT, SmallDenseMap<KeyT, unsigned, N>,
+            SmallVector<std::pair<KeyT, ValueT>, N>>;
 
 } // end namespace llvm