[llvm-commits] [llvm] r172455 - /llvm/trunk/include/llvm/ADT/StringMap.h

Argyrios Kyrtzidis akyrtzi at gmail.com
Mon Jan 14 11:41:09 PST 2013


Author: akirtzidis
Date: Mon Jan 14 13:41:09 2013
New Revision: 172455

URL: http://llvm.org/viewvc/llvm-project?rev=172455&view=rev
Log:
[ADT/StringMap] Add a constructor in StringMap that accepts both an
initial size and an allocator.

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

Modified: llvm/trunk/include/llvm/ADT/StringMap.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/ADT/StringMap.h?rev=172455&r1=172454&r2=172455&view=diff
==============================================================================
--- llvm/trunk/include/llvm/ADT/StringMap.h (original)
+++ llvm/trunk/include/llvm/ADT/StringMap.h Mon Jan 14 13:41:09 2013
@@ -237,6 +237,9 @@
   explicit StringMap(AllocatorTy A)
     : StringMapImpl(static_cast<unsigned>(sizeof(MapEntryTy))), Allocator(A) {}
 
+  StringMap(unsigned InitialSize, AllocatorTy A)
+    : StringMapImpl(InitialSize), Allocator(A) {}
+
   StringMap(const StringMap &RHS)
     : StringMapImpl(static_cast<unsigned>(sizeof(MapEntryTy))) {
     assert(RHS.empty() &&





More information about the llvm-commits mailing list