1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00

sys/cpp11-compat: Add braces around mutex initializer

Fixes Clang warning/error:

    In file included from .../riot/sys/cpp11-compat/thread.cpp:26:
    In file included from .../riot/sys/cpp11-compat/include/riot/thread.hpp:39:
    .../riot/sys/cpp11-compat/include/riot/mutex.hpp:47:45: error:
     suggest braces around initialization of subobject [-Werror,-Wmissing-braces]
      inline constexpr mutex() noexcept : m_mtx{0} {}
                                                ^
                                                {}
    1 error generated.
This commit is contained in:
Joakim Nohlgård 2016-06-01 16:21:18 +02:00
parent 73739cb7c8
commit 92370e846d

View File

@ -44,7 +44,7 @@ class mutex {
public:
using native_handle_type = mutex_t*;
inline constexpr mutex() noexcept : m_mtx{0} {}
inline constexpr mutex() noexcept : m_mtx{{0}} {}
~mutex();
void lock();