From: Dan Gohman Date: Thu, 28 Jun 2007 20:27:24 +0000 (+0000) Subject: Add a default parameter to a SmallVector constructor to allow it to X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=8b42bcdd1ad6f3f908d062b189fbc2a6449fae83;p=oota-llvm.git Add a default parameter to a SmallVector constructor to allow it to be called with just an initial length value, just like in std::vector. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37779 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/ADT/SmallVector.h b/include/llvm/ADT/SmallVector.h index 5fcb2b93065..bb8cef4ce8a 100644 --- a/include/llvm/ADT/SmallVector.h +++ b/include/llvm/ADT/SmallVector.h @@ -442,7 +442,7 @@ public: SmallVector() : SmallVectorImpl(NumTsAvailable) { } - SmallVector(unsigned Size, const T &Value) + SmallVector(unsigned Size, const T &Value = T()) : SmallVectorImpl(NumTsAvailable) { this->reserve(Size); while (Size--)