File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
fast_io_hosted/threads/mutex Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -49,8 +49,7 @@ struct basic_general_io_lockable_nonmovable
49
49
}
50
50
else
51
51
{
52
- ::std::destroy_at (__builtin_addressof(handle));
53
- ::std::construct_at (__builtin_addressof(handle), ::std::forward<Args>(args)...);
52
+ this ->handle = T (::std::forward<Args>(args)...);
54
53
}
55
54
}
56
55
constexpr void close () noexcept (noexcept (handle.close()))
Original file line number Diff line number Diff line change @@ -37,7 +37,8 @@ using native_mutex =
37
37
;
38
38
39
39
template <typename Mutex>
40
- using basic_mutex_movable = ::fast_io::basic_general_mutex_movable<Mutex, ::fast_io::native_global_allocator>;
40
+ using basic_mutex_movable = ::std::conditional_t <::std::movable<Mutex>, Mutex,
41
+ ::fast_io::basic_general_mutex_movable<Mutex, ::fast_io::native_global_allocator>>;
41
42
using native_mutex_movable = ::fast_io::basic_mutex_movable<native_mutex>;
42
43
43
44
template <typename T>
You can’t perform that action at this time.
0 commit comments