summaryrefslogtreecommitdiff
path: root/src/ReplayGainMode.hxx
diff options
context:
space:
mode:
authorMax Kellermann <max@musicpd.org>2017-05-08 14:48:58 +0200
committerMax Kellermann <max@musicpd.org>2017-05-08 17:25:06 +0200
commit788e3b31e1ab8243386339eaf136ede18f015d55 (patch)
tree3f9c7e44c1e522be9e1e64ed918c15b1b8101466 /src/ReplayGainMode.hxx
parent71f0ed8b7499011b53f90998ebfbd3250fd80948 (diff)
*: remove "pure" and "const" attributes from throwing functions
The "pure" and "const" attributes are not so well-defined, and a recent clang version implements an optimization which pushes the definition's boundary beyond what I believed it was. clang now assumes that functions declared "pure" cannot throw exceptions, even if they lack the "noexcept" specification. When compiled with this new clang version, MPD will crash randomly if an exception happens to get thrown by such as "pure" function (https://github.com/MusicPlayerDaemon/MPD/issues/41). This commit removes all such misplaced "pure" and "const" attributes, closing #41.
Diffstat (limited to 'src/ReplayGainMode.hxx')
-rw-r--r--src/ReplayGainMode.hxx1
1 files changed, 0 insertions, 1 deletions
diff --git a/src/ReplayGainMode.hxx b/src/ReplayGainMode.hxx
index 37b76f16f..885151704 100644
--- a/src/ReplayGainMode.hxx
+++ b/src/ReplayGainMode.hxx
@@ -42,7 +42,6 @@ ToString(ReplayGainMode mode) noexcept;
* Parse a string to a #ReplayGainMode. Throws std::runtime_error on
* error.
*/
-gcc_pure
ReplayGainMode
FromString(const char *s);