From 0b6548a2820faaf6c59cda4fbc75ba81e1d6084a Mon Sep 17 00:00:00 2001 From: Max Kellermann <max@duempel.org> Date: Mon, 11 Nov 2013 08:26:16 +0100 Subject: util/RefCount: no "constexpr" with libc++ Not supported by libc++. --- src/util/RefCount.hxx | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/util') diff --git a/src/util/RefCount.hxx b/src/util/RefCount.hxx index 9a45a585b..dff850036 100644 --- a/src/util/RefCount.hxx +++ b/src/util/RefCount.hxx @@ -42,7 +42,12 @@ class RefCount { std::atomic_uint n; public: - constexpr RefCount():n(1) {} +#ifndef _LIBCPP_VERSION + /* the "constexpr" is missing in libc++'s "atomic" + implementation */ + constexpr +#endif + RefCount():n(1) {} void Increment() { ++n; -- cgit v1.2.3