mirror of
https://github.com/fmtlib/fmt.git
synced 2024-12-26 00:21:13 +00:00
Add noexcept
This commit is contained in:
parent
7175bd8ae6
commit
23b8c24da4
10
fmt/format.h
10
fmt/format.h
@ -591,23 +591,23 @@ class basic_buffer {
|
||||
|
||||
/**
|
||||
\rst
|
||||
Increases the buffer capacity to hold at least *size* elements updating
|
||||
Increases the buffer capacity to hold at least *capacity* elements updating
|
||||
``ptr_`` and ``capacity_``.
|
||||
\endrst
|
||||
*/
|
||||
virtual void grow(std::size_t size) = 0;
|
||||
virtual void grow(std::size_t capacity) = 0;
|
||||
|
||||
public:
|
||||
virtual ~basic_buffer() {}
|
||||
|
||||
/** Returns the size of this buffer. */
|
||||
std::size_t size() const { return size_; }
|
||||
std::size_t size() const FMT_NOEXCEPT { return size_; }
|
||||
|
||||
/** Returns the capacity of this buffer. */
|
||||
std::size_t capacity() const { return capacity_; }
|
||||
std::size_t capacity() const FMT_NOEXCEPT { return capacity_; }
|
||||
|
||||
/** Returns a pointer to the buffer data. */
|
||||
const T *data() const { return ptr_; }
|
||||
const T *data() const FMT_NOEXCEPT { return ptr_; }
|
||||
|
||||
/**
|
||||
Resizes the buffer. If T is a POD type new elements may not be initialized.
|
||||
|
Loading…
Reference in New Issue
Block a user