ICU-21174 Add a const version of MaybeStackVector::getAlias().

(Also makes a tiny tweak to appendAll() documentation.)
This commit is contained in:
Hugo van der Merwe 2020-06-19 14:10:17 +02:00 committed by Hugo
parent 4d428cb8f3
commit 3fca290880

View File

@ -779,6 +779,10 @@ public:
return this->fPool.getAlias(); return this->fPool.getAlias();
} }
const T *const *getAlias() const {
return this->fPool.getAlias();
}
/** /**
* Array item access (read-only). * Array item access (read-only).
* No index bounds check. * No index bounds check.
@ -800,7 +804,7 @@ public:
} }
/** /**
* Append all the items from another MaybeStackVector to this one. * Append copies of all the items from another MaybeStackVector to this one.
*/ */
void appendAll(const MaybeStackVector& other, UErrorCode& status) { void appendAll(const MaybeStackVector& other, UErrorCode& status) {
for (int32_t i = 0; i < other.fCount; i++) { for (int32_t i = 0; i < other.fCount; i++) {