Home
last modified time | relevance | path

Searched refs:newCap (Results 1 – 8 of 8) sorted by relevance

/external/chromium_org/third_party/icu/source/common/
Duvectr64.cpp132 int32_t newCap = capacity * 2; in expandCapacity() local
133 if (newCap < minimumCapacity) { in expandCapacity()
134 newCap = minimumCapacity; in expandCapacity()
136 if (maxCapacity > 0 && newCap > maxCapacity) { in expandCapacity()
137 newCap = maxCapacity; in expandCapacity()
139 if (newCap > (int32_t)(INT32_MAX / sizeof(int64_t))) { // integer overflow check in expandCapacity()
144 int64_t* newElems = (int64_t *)uprv_realloc(elements, sizeof(int64_t)*newCap); in expandCapacity()
151 capacity = newCap; in expandCapacity()
Duvectr32.cpp214 int32_t newCap = capacity * 2; in expandCapacity() local
215 if (newCap < minimumCapacity) { in expandCapacity()
216 newCap = minimumCapacity; in expandCapacity()
218 if (maxCapacity > 0 && newCap > maxCapacity) { in expandCapacity()
219 newCap = maxCapacity; in expandCapacity()
221 if (newCap > (int32_t)(INT32_MAX / sizeof(int32_t))) { // integer overflow check in expandCapacity()
226 int32_t* newElems = (int32_t *)uprv_realloc(elements, sizeof(int32_t)*newCap); in expandCapacity()
233 capacity = newCap; in expandCapacity()
Duvector.cpp338 int32_t newCap = capacity * 2; in ensureCapacity() local
339 if (newCap < minimumCapacity) { in ensureCapacity()
340 newCap = minimumCapacity; in ensureCapacity()
342 if (newCap > (int32_t)(INT32_MAX / sizeof(UHashTok))) { // integer overflow check in ensureCapacity()
347 UHashTok* newElems = (UHashTok *)uprv_realloc(elements, sizeof(UHashTok)*newCap); in ensureCapacity()
354 capacity = newCap; in ensureCapacity()
/external/icu4c/common/
Duvectr64.cpp132 int32_t newCap = capacity * 2; in expandCapacity() local
133 if (newCap < minimumCapacity) { in expandCapacity()
134 newCap = minimumCapacity; in expandCapacity()
136 if (maxCapacity > 0 && newCap > maxCapacity) { in expandCapacity()
137 newCap = maxCapacity; in expandCapacity()
139 if (newCap > (int32_t)(INT32_MAX / sizeof(int64_t))) { // integer overflow check in expandCapacity()
144 int64_t* newElems = (int64_t *)uprv_realloc(elements, sizeof(int64_t)*newCap); in expandCapacity()
151 capacity = newCap; in expandCapacity()
Duvectr32.cpp214 int32_t newCap = capacity * 2; in expandCapacity() local
215 if (newCap < minimumCapacity) { in expandCapacity()
216 newCap = minimumCapacity; in expandCapacity()
218 if (maxCapacity > 0 && newCap > maxCapacity) { in expandCapacity()
219 newCap = maxCapacity; in expandCapacity()
221 if (newCap > (int32_t)(INT32_MAX / sizeof(int32_t))) { // integer overflow check in expandCapacity()
226 int32_t* newElems = (int32_t *)uprv_realloc(elements, sizeof(int32_t)*newCap); in expandCapacity()
233 capacity = newCap; in expandCapacity()
Duvector.cpp339 int32_t newCap = capacity * 2; in ensureCapacity() local
340 if (newCap < minimumCapacity) { in ensureCapacity()
341 newCap = minimumCapacity; in ensureCapacity()
343 if (newCap > (int32_t)(INT32_MAX / sizeof(UElement))) { // integer overflow check in ensureCapacity()
348 UElement* newElems = (UElement *)uprv_realloc(elements, sizeof(UElement)*newCap); in ensureCapacity()
355 capacity = newCap; in ensureCapacity()
/external/lzma/CPP/Common/
DDynamicBuffer.h20 size_t newCap = this->_capacity + delta; in GrowLength() local
21 if (newCap < delta) in GrowLength()
22 newCap = this->_capacity + size; in GrowLength()
23 SetCapacity(newCap); in GrowLength()
/external/antlr/antlr-3.4/runtime/Delphi/Sources/Antlr3.Runtime/
DAntlr.Runtime.Tools.pas573 newCap: Integer;
582 newCap := 4;
583 while newCap < ACapacity do
584 newCap := newCap shl 1;
585 Rehash(newCap);
591 newCap: Integer;
593 newCap := Length(FItems) * 2;
594 if newCap = 0 then
595 newCap := 4;
596 Rehash(newCap);