diff options
author | Max Kellermann <max@musicpd.org> | 2017-05-08 14:44:49 +0200 |
---|---|---|
committer | Max Kellermann <max@musicpd.org> | 2017-05-08 14:44:49 +0200 |
commit | 71f0ed8b7499011b53f90998ebfbd3250fd80948 (patch) | |
tree | e9c2f66fbef231858f46d878864199d46e6ce21c /src/MusicChunk.cxx | |
parent | ac2e4e593d407e41db49fdb9ae2da6bc1557f618 (diff) |
*: add "noexcept" to many, many function prototypes
This eliminates some overhead, because the compiler doesn't need to
consider these functions throwing.
Diffstat (limited to 'src/MusicChunk.cxx')
-rw-r--r-- | src/MusicChunk.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/MusicChunk.cxx b/src/MusicChunk.cxx index 55a9f98b1..581974ae4 100644 --- a/src/MusicChunk.cxx +++ b/src/MusicChunk.cxx @@ -31,7 +31,7 @@ MusicChunk::~MusicChunk() #ifndef NDEBUG bool -MusicChunk::CheckFormat(const AudioFormat other_format) const +MusicChunk::CheckFormat(const AudioFormat other_format) const noexcept { assert(other_format.IsValid()); @@ -41,7 +41,7 @@ MusicChunk::CheckFormat(const AudioFormat other_format) const WritableBuffer<void> MusicChunk::Write(const AudioFormat af, - SongTime data_time, uint16_t _bit_rate) + SongTime data_time, uint16_t _bit_rate) noexcept { assert(CheckFormat(af)); assert(length == 0 || audio_format.IsValid()); @@ -64,7 +64,7 @@ MusicChunk::Write(const AudioFormat af, } bool -MusicChunk::Expand(const AudioFormat af, size_t _length) +MusicChunk::Expand(const AudioFormat af, size_t _length) noexcept { const size_t frame_size = af.GetFrameSize(); |