projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9004c8a
)
Implement new SmallVector::data() methods.
author
Jay Foad
<jay.foad@gmail.com>
Thu, 21 May 2009 09:00:37 +0000
(09:00 +0000)
committer
Jay Foad
<jay.foad@gmail.com>
Thu, 21 May 2009 09:00:37 +0000
(09:00 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72209
91177308
-0d34-0410-b5e6-
96231b3b80d8
include/llvm/ADT/SmallVector.h
patch
|
blob
|
history
diff --git
a/include/llvm/ADT/SmallVector.h
b/include/llvm/ADT/SmallVector.h
index bf4960ad1445a6e6c3093bfb06824d0ff4f94442..de5648fe8527074bcd5b2e0da5cdfcc227da0787 100644
(file)
--- a/
include/llvm/ADT/SmallVector.h
+++ b/
include/llvm/ADT/SmallVector.h
@@
-374,6
+374,16
@@
public:
return I;
}
+ /// data - Return a pointer to the vector's buffer, even if empty().
+ pointer data() {
+ return pointer(Begin);
+ }
+
+ /// data - Return a pointer to the vector's buffer, even if empty().
+ const_pointer data() const {
+ return const_pointer(Begin);
+ }
+
const SmallVectorImpl &operator=(const SmallVectorImpl &RHS);
bool operator==(const SmallVectorImpl &RHS) const {