mirror of
https://github.com/fmtlib/fmt.git
synced 2024-12-25 15:21:54 +00:00
Added clear() to basic_buffer
This commit is contained in:
parent
60c662b3a7
commit
e5c93108e6
@ -379,6 +379,11 @@ class basic_buffer {
|
|||||||
size_ = new_size;
|
size_ = new_size;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Clears this buffer. */
|
||||||
|
void clear() {
|
||||||
|
size_ = 0;
|
||||||
|
}
|
||||||
|
|
||||||
/** Reserves space to store at least *capacity* elements. */
|
/** Reserves space to store at least *capacity* elements. */
|
||||||
void reserve(std::size_t new_capacity) {
|
void reserve(std::size_t new_capacity) {
|
||||||
if (new_capacity > capacity_)
|
if (new_capacity > capacity_)
|
||||||
|
Loading…
Reference in New Issue
Block a user