|
template<class _Tp , class _Alloc >
Definition at line 607 of file _string.c. Referenced by _String_base< _Tp, _Alloc >::_String_base(). {
if ((__n <= (max_size() + 1)) && (__n > 0)) {
#if defined (_STLP_USE_SHORT_STRING_OPTIM)
if (__n > _DEFAULT_SIZE) {
this->_M_start_of_storage._M_data = _M_start_of_storage.allocate(__n, __n);
this->_M_finish = this->_M_start_of_storage._M_data;
this->_M_buffers._M_end_of_storage = this->_M_start_of_storage._M_data + __n;
}
#else
this->_M_start_of_storage._M_data = _M_start_of_storage.allocate(__n, __n);
this->_M_finish = this->_M_start_of_storage._M_data;
this->_M_end_of_storage = this->_M_start_of_storage._M_data + __n;
#endif
} else {
this->_M_throw_length_error();
}
}
|