[llvm-commits] CVS: llvm/include/llvm/ADT/SmallVector.h
Dan Gohman
djg at cray.com
Thu Jun 28 13:27:46 PDT 2007
Changes in directory llvm/include/llvm/ADT:
SmallVector.h updated: 1.30 -> 1.31
---
Log message:
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.
---
Diffs of the changes: (+1 -1)
SmallVector.h | 2 +-
1 files changed, 1 insertion(+), 1 deletion(-)
Index: llvm/include/llvm/ADT/SmallVector.h
diff -u llvm/include/llvm/ADT/SmallVector.h:1.30 llvm/include/llvm/ADT/SmallVector.h:1.31
--- llvm/include/llvm/ADT/SmallVector.h:1.30 Thu May 17 15:01:40 2007
+++ llvm/include/llvm/ADT/SmallVector.h Thu Jun 28 15:27:24 2007
@@ -442,7 +442,7 @@
SmallVector() : SmallVectorImpl<T>(NumTsAvailable) {
}
- SmallVector(unsigned Size, const T &Value)
+ SmallVector(unsigned Size, const T &Value = T())
: SmallVectorImpl<T>(NumTsAvailable) {
this->reserve(Size);
while (Size--)
More information about the llvm-commits
mailing list