On 30/11/14 20:48 +, Jonathan Wakely wrote:
I think we also need this to make __numpunct_cache and
__moneypunct_cache exception-safe. If we set _M_allocated=true at the
start of the _M_cache functions and then an allocation throws we will
delete[] the memory allocated in _M_cache, but then th
Finally, does anyone know why we don't use the stored size in the
facet virtual functions that return strings? e.g.
virtual string
do_grouping() const
{ return _M_data->_M_grouping; }
We could save the cost of a strlen call:
virtual string
do_grouping() const
{ ret
I think we also need this to make __numpunct_cache and
__moneypunct_cache exception-safe. If we set _M_allocated=true at the
start of the _M_cache functions and then an allocation throws we will
delete[] the memory allocated in _M_cache, but then the cache's
destructor will see _M_allocated==true